bugfix fstart before path
This commit is contained in:
parent
5890e905fc
commit
288bbe13d7
@ -91,7 +91,7 @@ class Survey(object):
|
|||||||
#fileending = '.sg2'
|
#fileending = '.sg2'
|
||||||
if fend == None:
|
if fend == None:
|
||||||
fend = '_pickle.dat'
|
fend = '_pickle.dat'
|
||||||
obsfile = fstart + os.path.join(self._obsdir, str(shotnumber)) + fend
|
obsfile = os.path.join(self._obsdir, fstart + str(shotnumber)) + fend
|
||||||
if obsfile not in shot_dict.keys():
|
if obsfile not in shot_dict.keys():
|
||||||
shot_dict[shotnumber] = []
|
shot_dict[shotnumber] = []
|
||||||
shot_dict[shotnumber] = seismicshot.SeismicShot(obsfile)
|
shot_dict[shotnumber] = seismicshot.SeismicShot(obsfile)
|
||||||
|
@ -97,7 +97,7 @@ def setDynamicFittedSNR(shot_dict, shiftdist=30, shiftSNR=100, p1=0.004, p2=-0.0
|
|||||||
for shot in shot_dict.values():
|
for shot in shot_dict.values():
|
||||||
for traceID in shot.getTraceIDlist(): ### IMPROVE
|
for traceID in shot.getTraceIDlist(): ### IMPROVE
|
||||||
dist = shot.getDistance(traceID) + shiftdist
|
dist = shot.getDistance(traceID) + shiftdist
|
||||||
snrthreshold = (1 / (fit_fn(dist) ** 2)) - shiftSNR * np.exp(-0.05 * dist)
|
snrthreshold = snr_fit_func(fit_fn, dist, shiftSNR)
|
||||||
if snrthreshold < minSNR:
|
if snrthreshold < minSNR:
|
||||||
print('WARNING: SNR threshold %s lower %s. Set SNR threshold to %s.'
|
print('WARNING: SNR threshold %s lower %s. Set SNR threshold to %s.'
|
||||||
% (snrthreshold, minSNR, minSNR))
|
% (snrthreshold, minSNR, minSNR))
|
||||||
@ -106,6 +106,10 @@ def setDynamicFittedSNR(shot_dict, shiftdist=30, shiftSNR=100, p1=0.004, p2=-0.0
|
|||||||
shot.setSNRthreshold(traceID, snrthreshold)
|
shot.setSNRthreshold(traceID, snrthreshold)
|
||||||
print("setDynamicFittedSNR: Finished setting of fitted SNR-threshold")
|
print("setDynamicFittedSNR: Finished setting of fitted SNR-threshold")
|
||||||
|
|
||||||
|
def snr_fit_func(fit_fn, dist, shiftSNR):
|
||||||
|
import numpy as np
|
||||||
|
snrthreshold = (1 / (fit_fn(dist) ** 2)) - shiftSNR * np.exp(-0.05 * dist)
|
||||||
|
return snrthreshold
|
||||||
|
|
||||||
def setConstantSNR(shot_dict, snrthreshold=2.5):
|
def setConstantSNR(shot_dict, snrthreshold=2.5):
|
||||||
"""
|
"""
|
||||||
|
Loading…
Reference in New Issue
Block a user