Skip to content

Commit

Permalink
Merge branch 'master' into GPU
Browse files Browse the repository at this point in the history
  • Loading branch information
tclements committed Mar 30, 2020
2 parents 9867d74 + 587242b commit 38fe275
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 3 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/CompatHelper.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: CompatHelper

on:
schedule:
- cron: '00 00 * * *'

jobs:
CompatHelper:
runs-on: ubuntu-latest
steps:
- uses: julia-actions/setup-julia@latest
with:
version: 1.3
- name: Pkg.add("CompatHelper")
run: julia -e 'using Pkg; Pkg.add("CompatHelper")'
- name: CompatHelper.main()
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: julia -e 'using CompatHelper; CompatHelper.main()'
11 changes: 11 additions & 0 deletions .github/workflows/TagBot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: TagBot
on:
schedule:
- cron: 0 * * * *
jobs:
TagBot:
runs-on: ubuntu-latest
steps:
- uses: JuliaRegistries/TagBot@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ StatsBase = "2913bbd2-ae8a-5f71-8c99-4fb6c76f3a91"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[compat]
AWSCore = "0.6.8"
AWSS3 = "0.6.8"
AWSCore = "0.6"
AWSS3 = "0.6"
Adapt = "1.0.1"
CSV = "0.5,0.6"
CUDAnative = "3.0"
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ process_raw!(S1,fs)
process_raw!(S2,fs)
R = RawData.([S1,S2],cc_len,cc_step)
detrend!.(R)
taper!(R)
taper!.(R)
bandpass!.(R,freqmin,freqmax,zerophase=true)
FFT = compute_fft.(R)
whiten!.(FFT,freqmin,freqmax)
Expand Down
7 changes: 7 additions & 0 deletions src/VelocityChange/Stretching.jl
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,13 @@ function stretching(ref::AbstractArray,cur::AbstractArray,t::AbstractArray,
dv = 100. * dtfiner[argmax(CCfiner)]
cc = maximum(CCfiner) # Maximum correlation coefficient of the refined analysis

# due to CubicSplineInterpolation, cc can be more than 1, causing an error when computing sqrt(1-X^2).
if cc > 1.0
cc = 1.0
elseif cc < -1.0
cc = -1.0
end

# Error computation based on Weaver, R., C. Hadziioannou, E. Larose, and M.
# Campillo (2011), On the precision of noise-correlation interferometry,
# Geophys. J. Int., 185(3), 1384?1392
Expand Down

0 comments on commit 38fe275

Please sign in to comment.