This commit is contained in:
HappyZ 2018-02-08 15:48:02 -06:00
parent 5471f77e89
commit 2f59bb1b99
2 changed files with 4 additions and 3 deletions

View File

@ -176,6 +176,7 @@ def deriveLocation(args, results):
def plotLocation(loc):
handler = None
try:
import matplotlib.pyplot as plt
handler = plt.scatter(loc[0], loc[1])
plt.pause(0.01)
except Exception:

View File

@ -201,13 +201,13 @@ def wrapper(args):
try:
import matplotlib.pyplot as plt
from libLocalization import plotLocation
args['plot'] = False
handler = None
fig = plt.figure()
plt.ion()
plt.xlim([-100, 500])
plt.ylim([-10, 500])
plt.xlim([-200, 500])
plt.ylim([-10, 1000])
except Exception:
args['plot'] = False
print('Cannot plot because lacking matplotlib!')
with Measurement(
args['interface'],