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
sec23
korte
pymagglobal
Commits
1a154eb5
Commit
1a154eb5
authored
Jul 20, 2020
by
Stefan Mauerberger
Browse files
Use non-blocking draw()
parent
ce249be1
Changes
2
Hide whitespace changes
Inline
Side-by-side
pymagglobal/__main__.py
View file @
1a154eb5
...
@@ -32,6 +32,7 @@ import argparse
...
@@ -32,6 +32,7 @@ import argparse
from
.
import
commands
from
.
import
commands
from
pymagglobal
import
models
from
pymagglobal
import
models
from
pymagglobal
import
__version__
from
pymagglobal
import
__version__
from
matplotlib
import
pyplot
as
plt
class
ListModelsAction
(
argparse
.
Action
):
class
ListModelsAction
(
argparse
.
Action
):
...
@@ -202,6 +203,8 @@ def main():
...
@@ -202,6 +203,8 @@ def main():
# call the respective function, specified using .set_defaults(func=...)
# call the respective function, specified using .set_defaults(func=...)
args
.
func
(
args
)
args
.
func
(
args
)
if
not
args
.
no_show
:
plt
.
show
()
if
__name__
==
'__main__'
:
if
__name__
==
'__main__'
:
...
...
pymagglobal/commands.py
View file @
1a154eb5
...
@@ -174,7 +174,7 @@ def master_curve(args):
...
@@ -174,7 +174,7 @@ def master_curve(args):
else
:
else
:
axs
[
it
].
set_xlabel
(
utils
.
nicelabel
(
args
.
t_label
))
axs
[
it
].
set_xlabel
(
utils
.
nicelabel
(
args
.
t_label
))
fig
.
tight_layout
(
rect
=
[
0
,
0.03
,
1
,
0.95
])
fig
.
tight_layout
(
rect
=
[
0
,
0.03
,
1
,
0.95
])
plt
.
sho
w
()
plt
.
dra
w
()
def
dipole_series
(
args
):
def
dipole_series
(
args
):
...
@@ -220,7 +220,7 @@ def dipole_series(args):
...
@@ -220,7 +220,7 @@ def dipole_series(args):
else
:
else
:
ax
.
set_xlabel
(
utils
.
nicelabel
(
args
.
t_label
))
ax
.
set_xlabel
(
utils
.
nicelabel
(
args
.
t_label
))
fig
.
tight_layout
()
fig
.
tight_layout
()
plt
.
sho
w
()
plt
.
dra
w
()
def
coefficients
(
args
):
def
coefficients
(
args
):
...
@@ -353,4 +353,4 @@ def maps(args):
...
@@ -353,4 +353,4 @@ def maps(args):
fig
.
colorbar
(
cm
.
ScalarMappable
(
norm
=
norm
,
cmap
=
cmaps
[
it
]),
fig
.
colorbar
(
cm
.
ScalarMappable
(
norm
=
norm
,
cmap
=
cmaps
[
it
]),
cax
=
colax
,
cax
=
colax
,
orientation
=
'horizontal'
)
orientation
=
'horizontal'
)
plt
.
sho
w
()
plt
.
dra
w
()
Stefan Mauerberger
@mauerber
mentioned in issue
#7 (closed)
·
Jul 22, 2020
mentioned in issue
#7 (closed)
mentioned in issue #7
Toggle commit list
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