slimgroup / JUDI.jl

Julia Devito inversion.
https://slimgroup.github.io/JUDI.jl
MIT License
96 stars 30 forks source link

Photo operator #60

Closed rafaelorozco closed 2 years ago

rafaelorozco commented 3 years ago

Draft PR, still need to think about what I want to do about my amplitudes.

Right now I divide the initial pressure distribution by m:

waveutils.py

            u.data[0] = np.array(init_dist[0] / m.data)
            u.data[1] = np.array(init_dist[1] / m.data)

To match the division that happens in adjoint src data injection:

            geom_expr += src.inject(field=u_n, expr=-src.dt*dt**2/m)

This allows adjoint test to pass but changes data amplitudes in forward pass wrt to kwave. I will make a separate repo with data examples to share and study this further.

Also, need a cleaner way to "activate" judiPDEinitial.jl operator that doesnt make use of judiInitial.jl operator.

codecov[bot] commented 3 years ago

Codecov Report

Merging #60 (98f9a9e) into master (762706f) will decrease coverage by 3.04%. The diff coverage is 58.87%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #60      +/-   ##
==========================================
- Coverage   83.41%   80.36%   -3.05%     
==========================================
  Files          35       39       +4     
  Lines        2321     2445     +124     
==========================================
+ Hits         1936     1965      +29     
- Misses        385      480      +95     
Impacted Files Coverage Δ
src/TimeModeling/TimeModeling.jl 100.00% <ø> (ø)
src/TimeModeling/Types/judiVector.jl 91.13% <0.00%> (-3.25%) :arrow_down:
src/TimeModeling/Types/judiInitialValue.jl 30.43% <30.43%> (ø)
src/TimeModeling/LinearOperators/judiInitial.jl 46.66% <46.66%> (ø)
src/TimeModeling/LinearOperators/judiPDEinitial.jl 62.50% <62.50%> (ø)
src/TimeModeling/Modeling/python_interface.jl 83.33% <78.94%> (-4.67%) :arrow_down:
...odeling/Modeling/initial_value_interface_serial.jl 83.33% <83.33%> (ø)
src/TimeModeling/LinearOperators/judiPDE.jl 59.82% <100.00%> (+0.18%) :arrow_up:
src/TimeModeling/Utils/auxiliaryFunctions.jl 79.46% <100.00%> (-2.64%) :arrow_down:
src/TimeModeling/Utils/seismic_preconditioners.jl 68.46% <0.00%> (-10.77%) :arrow_down:
... and 12 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 762706f...98f9a9e. Read the comment docs.

mloubout commented 2 years ago

So I think we decided this should go in its on package right? So should probably be closed