Closed ziyiyin97 closed 3 years ago
Merging #50 (94664f7) into master (f22170d) will increase coverage by
0.03%
. The diff coverage is84.84%
.
@@ Coverage Diff @@
## master #50 +/- ##
==========================================
+ Coverage 76.84% 76.88% +0.03%
==========================================
Files 33 33
Lines 2626 2643 +17
==========================================
+ Hits 2018 2032 +14
- Misses 608 611 +3
Impacted Files | Coverage Δ | |
---|---|---|
src/TimeModeling/TimeModeling.jl | 100.00% <ø> (ø) |
|
src/TimeModeling/judiVector.jl | 86.60% <84.84%> (-0.17%) |
:arrow_down: |
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 f22170d...94664f7. Read the comment docs.
Thanks for the feedback! Based on our discussion, I only leave the time derivative/integration and report exception on other dimensions because receivers might not be uniform spaced. Also fix the tests.
Thanks for your feedback. Fix cumsum/diff on 2nd (receiver) to be non-dimensional, e.g. sample interval = 1.
Thanks for your suggestions! To make it clean,
lmul!, rmul!, ldiv!, rdiv!
functions for judiVector so that they could be easily deployed for cumsum
.*
and /
operations so that they don't have either to loop over shots or to allocate extra memory.test_judiVector.jl
.Great suggestions! I've modified the error messages for +-*/ operations.
Division by zero is classified as a DivideError()
Operations with OOC object is classified as a DomainError()
.
ldiv!, rdiv!
are not supported in Julia 1.1 version. Thus, switch to a try/catch
framework.
Modified ldiv, rdiv
functions for judiVector. Also remove test_wavefield.jl
file from src/TimeModeling/
folder since I don't think it is used anywhere.
Use selectdim
in diff
which makes it cleaner with dimensions and avoids extra space allocation
Modify tests for lmul, rmul, ldiv, rdiv
to be more explicit.
I gave a second thought to the implementation of cumsum and diff on judiVector and I thought they should be dimensional, just like what norm and inner product do. So, depending on integration along time or along receivers, I multiply the term
dt
ordrec
to the cumsum result. Similarly, in the case of differentiation, I divide by the termdt
ordrec
.Also, there was a problem on diff function while dims=2. I fix that in this PR and add more associated tests to thoroughly test every case.
Appreciate any advice and review!