Use default matplotlib engine and use pause for animation
This commit is contained in:
@ -13,8 +13,6 @@
|
|||||||
from __future__ import print_function
|
from __future__ import print_function
|
||||||
import sys
|
import sys
|
||||||
sys.path.append("./pizza")
|
sys.path.append("./pizza")
|
||||||
import matplotlib
|
|
||||||
matplotlib.use('tkagg')
|
|
||||||
import matplotlib.pyplot as plt
|
import matplotlib.pyplot as plt
|
||||||
|
|
||||||
# parse command line
|
# parse command line
|
||||||
@ -79,7 +77,8 @@ while ntimestep < nsteps:
|
|||||||
ax = plt.gca()
|
ax = plt.gca()
|
||||||
ax.relim()
|
ax.relim()
|
||||||
ax.autoscale_view(True, True, True)
|
ax.autoscale_view(True, True, True)
|
||||||
fig.canvas.draw()
|
plt.pause(0.001)
|
||||||
|
|
||||||
|
|
||||||
lmp.command("run 0 pre no post yes")
|
lmp.command("run 0 pre no post yes")
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user