Skip to content

Commit e5636b7

Browse files
authored
add comments
1 parent add33c4 commit e5636b7

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

book/hackathon/soundfx2024/synthspitz/SConstruct

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ import numpy as np
33
import m8r
44
import matplotlib.pyplot as plt
55

6+
# function to generate the synthetic traces (Fig 1a in Spitz., 1991)
7+
# the function create the gather as numpy array and writes into an RSF file
68

79
def generateSynthetic(source=None, target=None, env=None):
810
nx = 27
@@ -48,14 +50,21 @@ def generateSynthetic(source=None, target=None, env=None):
4850

4951
Command('synthetic1.rsf', None, action=Action(generateSynthetic))
5052

53+
# Above function creates gather with spikes only, need to convolve with a source wavelet
54+
# Convolving with a ricker wavelet
55+
5156
Flow('synthetic', 'synthetic1.rsf', 'ricker1 freq=.1 | noise seed=2024 var=1e-6')
5257

5358
Plot('synthetic', 'synthetic', 'wiggle transp=y yreverse=y title=Before poly=y zplot=.25 parallel2=y d1num=0.5 label1=Time label2=Trace unit1=s unit2= wheretitle=t wherexlabel=b')
5459

60+
# F-K spectrum of the gather
61+
5562
Flow('synthFK','synthetic','spectra2')
5663

5764
Result('synthFK','synthFK','window max1=125 | wiggle transp=y yreverse=n xreverse=y screenwd=5 screenht=10 wanttitle=n poly=y plcip=100 parallel2=y d1num=0.5')
5865

66+
# trace interpolation using the FX domain (Fig 1b in Spitz., 1991)
67+
5968
Flow('synthInt','synthetic','spitz verb=y')
6069

6170
Plot('synthInt', 'wiggle transp=y yreverse=y title=After poly=y zplot=.25 parallel2=y d1num=0.5 label1=Time label2=Trace unit1=s unit2= wheretitle=t wherexlabel=b')
@@ -72,6 +81,7 @@ Plot('synthIntFK-grey','synthIntFK','window max1=125 | grey transp=y yreverse=n
7281

7382
Result('FK', 'synthFK-grey synthIntFK-grey','SideBySideAniso')
7483

84+
# function to generate the gather with curved events (Fig 3a in Spitz., 1991)
7585

7686
def generateSynthetic2(source=None, target=None, env=None):
7787
nx = 48
@@ -169,4 +179,4 @@ Result('synthetic2','Fig/synth2.vpl Fig/synthInt2.vpl','SideBySideAniso')
169179
# Result('synthInt2ns', 'wiggle transp=y yreverse=y screenwd=5 screenht=10 wanttitle=n poly=y zplot=.25 parallel2=y d1num=0.5')
170180

171181

172-
End()
182+
End()

0 commit comments

Comments
 (0)