Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Sebastian Heimann
grond
Commits
bbcc64f0
Commit
bbcc64f0
authored
Mar 24, 2017
by
Marius Isken
Browse files
Fixing waveform plots for joint
parent
85ded1f3
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/plot.py
View file @
bbcc64f0
...
...
@@ -919,6 +919,7 @@ def plot_spectrum(
def
plot_dtrace_vline
(
axes
,
t
,
space
,
**
kwargs
):
axes
.
plot
([
t
,
t
],
[
-
1.0
-
space
,
-
1.0
],
**
kwargs
)
def
draw_fits_figures_statics
(
ds
,
model
,
plt
):
from
matplotlib
import
ticker
from
pyrocko.orthodrome
import
latlon_to_ne_numpy
...
...
@@ -1006,11 +1007,11 @@ def draw_fits_figures(ds, model, plt):
problem
=
model
.
problem
for
target
in
problem
.
targets
:
for
target
in
problem
.
waveform_
targets
:
target
.
set_dataset
(
ds
)
target_index
=
dict
(
(
target
,
i
)
for
(
i
,
target
)
in
enumerate
(
problem
.
targets
))
(
target
,
i
)
for
(
i
,
target
)
in
enumerate
(
problem
.
waveform_
targets
))
gms
=
problem
.
global_misfits
(
model
.
misfits
)
isort
=
num
.
argsort
(
gms
)
...
...
@@ -1034,7 +1035,7 @@ def draw_fits_figures(ds, model, plt):
ms
,
ns
,
results
=
problem
.
evaluate
(
xbest
,
result_mode
=
'full'
)
dtraces
=
[]
for
target
,
result
in
zip
(
problem
.
targets
,
results
):
for
target
,
result
in
zip
(
problem
.
waveform_
targets
,
results
):
if
isinstance
(
result
,
gf
.
SeismosizerError
):
dtraces
.
append
(
None
)
continue
...
...
@@ -1121,7 +1122,7 @@ def draw_fits_figures(ds, model, plt):
tr
.
ydata
/=
max
(
abs
(
dmin
),
abs
(
dmax
))
cg_to_targets
=
gather
(
problem
.
targets
,
problem
.
waveform_
targets
,
lambda
t
:
(
t
.
super_group
,
t
.
group
,
t
.
codes
[
3
]),
filter
=
lambda
t
:
t
in
target_to_result
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment