Skip to main content

Spatial Uncertainty Research Framework

Project description

Spatial Uncertainty Research Framework

image

What is SURF?

'SURF' is a Python package for performing spatial uncertainty analysis uisng random fields and machine leaning.

Examples

The example below shows how to train a neural network on a data set, and use it to predict.

    import surf.spatialModel as m
    from surf.NN import SpatialNeuroNet

    #---------------------------------------
    # 1. Prepare your data
    #---------------------------------------

    # ... see SURF.ET-AI.py 

    #---------------------------------------
    # 2. Train the neural network
    #---------------------------------------
    
    nn = SpatialNeuroNet(rawData = data, numNei = 20)
    nn.build_model()
    nn.train()

    #---------------------------------------
    # 3. Predict
    #---------------------------------------

    unkown_point = [x, y] # define a point  
    predicted = nn.predict(unkown_point) # predict

The example below shows how to define a spatial model for a data set, and insert it into random field to predict.

    from surf.rf import SK
    import surf.spatialModel as m

    #---------------------------------------
    # 1. Prepare your data
    #---------------------------------------

    # ... see SURF.ET.py 

    #---------------------------------------
    # 2. Define spatial model 
    #---------------------------------------

    colLength = 0.1
    sill = np.var( data[:,2] )
    cov = m.cov( m.exponential, ( colLength, sill ) )

    #---------------------------------------
    # 3. Predict
    #---------------------------------------
    
    unkown_point = [x, y] # define a point  
    predicted_mu, predicted_std = SK( data, cov, unkown_point, N=100 )

Application examples

BRAILS

Soft-Story Detection

License

'SURF' is distributed under the BSD 3-Clause license.

Acknowledgement

This material is based upon work supported by the National Science Foundation under Grant No. 1612843. Any opinions, findings, and conclusions or recommendations expressed in this material are those of the authors and do not necessarily reflect the views of the National Science Foundation.

Contact

Charles Wang, NHERI SimCenter, University of California, Berkeley, c_w@berkeley.edu

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for pySURF, version 0.2.2
Filename, size File type Python version Upload date Hashes
Filename, size pySURF-0.2.2.tar.gz (1.9 MB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page