Giter Site home page Giter Site logo

tutorials-2018's Introduction

tutorials-2018

Tutorials for 2018 from The Leading Edge column, which started in February 2014. Repos for previous issues.

Most of the tutorials contain Jupyter Notebooks. They can be opened and read (but not actually run) right here in GitHub, or you can install the Notebook software (e.g. with conda install jupyter), then clone this repo, and start a notebook server in the tutorials-2018 directory.

For more in-depth hints on getting started, see Hall, M (2016). A user guide to the geophysical tutorials. The Leading Edge 35 (2), 190–191, doi: 10.1190/tle35020190.1.

January 2018

February 2018

April 2018

June 2018

August 2018


The content of the articles and of the notebooks is © the author(s) and openly licensed CC-BY-SA. The code is © the author(s) and openly licensed under the terms of the Apache License 2, or under the terms specified by the author, if any.

Questions? Get in touch!

tutorials-2018's People

Contributors

gganssle avatar jesperdramsch avatar kwinkunks avatar mloubout avatar navjotk avatar philippwitte avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

tutorials-2018's Issues

Image Format

Hi! Sir, I meet a problem that because of work needs I have to transform *.segy to *.png. So, How should I do it?

Acoustic wave equation is not self-adjoint

I've been following these very exciting tutorials. The aim for simplicity is superb as it translates the equations to "human-readable'' implementations.

I propose an amendment for one statement of your last tutorial and it's corresponding implementation.

The acoustic wave equation is self-adjoint only if the background model is constant (which is not a very exciting medium).

If we think about the wave equation without absorbing boundaries we need to implement the following
steps at each time:

  1. apply Laplacian operator to u[x,z]
  2. scale output 1. by v^2[x,z]
  3. Add source term
  4. Do time-stepping

In adjoint mode, we need to perform this process in backward order:

  1. Do time-stepping (self-adjoint)
  2. Add source term
  3. Scale 2. by v^2[x,z]
  4. apply laplacian to output from 3.

Only if v^2[x,z] is constant, you can interchange 4. and 3.

In terms of matrices, steps 3. and 4. of the forward operator can be represented by: C=VL, with V being a diagonal matrix with the squared velocity in its diagonal, and L being the Laplacian operator. In adjoint mode, we need to apply C^t= LV (L and V are self-adjoint).

So, the adjoint equation is;

To test if your forward and adjoint implementation is correct you can do the dot-product test

I hope this point helps,

Cheers,
Esteban

AttributeError: 'int' object has no attribute 'is_Mul'

Hello,

I’ve been trying to run the adjoin modeling example, but I encountered the following error. I was wondering if you could advise me how to solve it.
The error is:

Traceback (most recent call last):
File "/FWI/adjoint.py", line 48, in
stencil_v = Eq(v.backward, solve(pde, v.backward)[0])
File "
/.conda/envs/devito/lib/python3.10/site-packages/sympy/solvers/solvers.py", line 1038, in solve
if fi.is_constant():
File "/.conda/envs/devito/lib/python3.10/site-packages/sympy/core/expr.py", line 628, in is_constant
expr = expr.simplify()
File "
/.conda/envs/devito/lib/python3.10/site-packages/sympy/core/basic.py", line 1763, in simplify
return simplify(self, **kwargs)
File "/.conda/envs/devito/lib/python3.10/site-packages/sympy/simplify/simplify.py", line 746, in simplify
expr = short.xreplace(hollow_mul)
File "
/.conda/envs/devito/lib/python3.10/site-packages/sympy/core/basic.py", line 1183, in xreplace
value, _ = self._xreplace(rule)
File "/.conda/envs/devito/lib/python3.10/site-packages/sympy/core/basic.py", line 1198, in _xreplace
a_xr = _xreplace(rule)
File "
/.conda/envs/devito/lib/python3.10/site-packages/sympy/core/basic.py", line 1198, in _xreplace
a_xr = _xreplace(rule)
File "/local/devito/devito/finite_differences/derivative.py", line 225, in _xreplace
return self._new_from_self(subs=subs), True
File "
/local/devito/devito/finite_differences/derivative.py", line 202, in _new_from_self
return Derivative(expr, *self.dims, **_kwargs)
File "/local/devito/devito/finite_differences/derivative.py", line 107, in new
obj._ppsubs = as_tuple(frozendict(i) for i in kwargs.get("subs", []))
File "
/local/devito/devito/tools/utils.py", line 49, in as_tuple
t = tuple(item)
File "/local/devito/devito/finite_differences/derivative.py", line 107, in
obj._ppsubs = as_tuple(frozendict(i) for i in kwargs.get("subs", []))
File "/local/devito/devito/tools/data_structures.py", line 456, in init
self._dict = self.dict_cls(*args, **kwargs)
File "
/.conda/envs/devito/lib/python3.10/site-packages/sympy/core/rules.py", line 57, in getitem
if self._filter(key):
File "~/.conda/envs/devito/lib/python3.10/site-packages/sympy/simplify/simplify.py", line 741, in
x.is_Mul and
AttributeError: 'int' object has no attribute 'is_Mul'

Thank you,

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.