Giter Site home page Giter Site logo

modelr's Introduction

Welcome to modelr server

Apache 2 license PyPI downloads PyPI version GitHub issues

This is the documentation for the back-end modelr server software. Modelr server was a Google-Charts-like API for geophysics; there is no longer a live instance. Submit tasks via a URL, or go to https://localhost:8081/plot.jpeg for a set of forms.

Run:

  • python setup.py install
  • modelr-server -p 8081 --local True

Example:

https://localhost:8081/plot.jpeg?script=wedge_spatial.py&theta=0&f=25&colourmap=Greys&base1=variable-density&overlay1=none&base2=earth-model&overlay2=wiggle&opacity=0.5&Rock0=3000.0%2C1600.0%2C2500.0%2C%0A%09%20%2050.0%2C%2050.0%2C%2050.0&Rock1=2770.0%2C1780.0%2C2185.0%2C%0A%09%20%2050.0%2C%2050.0%2C%2050.0&Rock2=3000.0%2C1600.0%2C2500.0%2C%0A%09%20%2050.0%2C%2050.0%2C%2050.0&tslice=0.15&scale=1.0%2C99&type=scenario

Prerequisites

You will need to generate a cert file on the server:

openssl req -newkey rsa:2048 -new -nodes -x509 -days 3650 -keyout key.pem -out cert.pem

You will need scientific python (numpy, scipy, matplotlib). Other python packages that will be automatically installed during setup:

  • bruges
  • pypng
  • requests
  • jinja2
  • svgwrite
  • cairo

Links

Authors

modelr's People

Contributors

ben-bougher avatar epsalt avatar evanbianco avatar kwinkunks avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

modelr's Issues

Depth conversion

Will want a way to convert between time and depth domains. Make model in depth, serve the seismic in time, and vice versa.

Attributes

Option to see attributes other than amplitude — envelope, inst freq, inst phase, semblance, specdecomp, cosine of phase.

User defined angle range for gradient in stochastic_avo.py

James Wanstall requests to allow the user to set the angle range for the gradient computation for stochastic AVO.

Current default is: 50 on the master branch, 30 on the develop branch (needs to be deployed ASAP).

This could be relatively easily inserted as a new text box, keeping the default as 30, say.

refer to line 448 on stochastic_avo.py on the develop branch

Instantaneous slices

See a line chart of amplitude, say, across a section. Or a timeslice through a volume. Might also want other attributes, such as freq, phase, etc.

Fix ImageMagick vulnerability

I have already put the /etc/ImageMagick/policy.xml instructions in place in the server:

<policymap>
  <policy domain="coder" rights="none" pattern="EPHEMERAL" />
  <policy domain="coder" rights="none" pattern="URL" />
  <policy domain="coder" rights="none" pattern="HTTPS" />
  <policy domain="coder" rights="none" pattern="MVG" />
  <policy domain="coder" rights="none" pattern="MSL" />
</policymap>

But we still need to do the other thing: check the bytes at the start of an image.

From https://imagetragick.com/ ...

Verify that all image files begin with the expected "magic bytes" corresponding to the image file types you support before sending them to ImageMagick for processing.

The first few bytes of a file can often used to identify the type of file. Some examples are GIF images, which start with the hex bytes "47 49 46 38", and JPEG images, which start with "FF D8". This list on Wikipedia has the magic bytes for most common file types.

Vary rocks

I'd like to be able to vary rock properties across a model, just like I can vary space (wedge), frequency, or reflection angle. Probably the most elegant way to do this would be to define one rock for the left-hand side, and another rock for the right — the rock properties would then vary linearly between the two sides.

Return table or list of elastic parameters as JSON

Specifically for the 2 and 3 rock scenario cases, it's become more apparent that we need to return not only the input Vp, Vs, and Density used in the modeling, but also elastic parameters as well.

Perhaps as a table, but as a list at least

Rprop0: RockProperties(vp=3240.0, rho=2340.0, vs=1620.0)

Include units as well.

Section model priority in carousel

When clicking on the thumbnail of a model from the Dashboard / Section Models tab, the image that is shown in the carousel isn't necessarily the same as the one that was clicked on. I think, it defaults to the last picture that was uploaded.

Optimize smoothness of synthetic model by decimating number of traces

For our current synthetic section dimensions, the max number of traces in the spatial section should be around 100 or so. Any more than this and we see excessive jitteryness that isn't seen on other seismic models. We might need to make this an argument for the user, but we should be able to treat it as an adapative parameter based on input and display dimensions.

Add Borfeld approximation

There is code for two Bortfeld approximations (2-termand 3-term) in the agilegeo library, but it is not available in modelr (eg in body_lab.py). Should be easy to fix.

User request: set gain on image plots

James Wantsall requests to set gain on synthetic models of low reflectivity contrast.

Slider from 0 to 2 (1 being no gain), or text box from minimum color to max color?

Sort Rocks by order of appearance

When uploading a picture, it would be easiest to select the rocks from the dropdown list if they were sorted from top to bottom (or in order of first appearance).

Rock name ID, and / or discriminate or filter rocks for scenario dropdowns

We need a way to filter or annotate the rock names in the dropdown selector for scenarios and the model building. If I, say, have a rock called "Shale" in "My Rock", and rock called "Shale" in "Public Rocks", then there is no way to tell them apart other than inferring from their order in the list.

Another thing to do would be to have a staging area of a scenario specific set list of rocks, to better categorize rocks during the workflow.

Stack single-offset sections

Currently, we are showing single-offset stacks of of the spatial cross-section. I anticipate that users will want to create "range-limited stacks", and "full-offset stacks". For instance, a near-offset stack and a far-offset stack are useful for Shuey type intercept and gradient computations.

I can think of two potential design solutions for the interface:

  1. replace the offset angle slider with two sliders: first offset angle, and last offset angle. Make them so that first can't be bigger than last. First equal to last is the situation we currently have.
  2. place two blue circles on the sliders, if that is at all possible. Prevent them from crossing (if needed).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.