Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when clearing axes during thread #26

Open
danielsk78 opened this issue Dec 29, 2020 · 1 comment
Open

Error when clearing axes during thread #26

danielsk78 opened this issue Dec 29, 2020 · 1 comment

Comments

@danielsk78
Copy link
Collaborator

The sandbox right now is using the animation way of matplotlib to plot. In the geoelectrics module, to do the animation we need to clear the axes and repaint everything. Initially it works but the figure starts to jump or some other things are not shown.
Is this related to issue #3 ?

@danielsk78
Copy link
Collaborator Author

New error appearing!

29/12/20 - 18:44:18 - tornado.application - ERROR - Exception in callback functools.partial(<bound method IOLoop._discard_future_result of <tornado.platform.asyncio.AsyncIOMainLoop object at 0x000001908D370E88>>, <Task finished coro=<_needs_document_lock.<locals>._needs_document_lock_wrapper() done, defined at C:\Users\danie\.conda\envs\pg\lib\site-packages\bokeh\server\session.py:51> exception=IndexError('list index out of range')>)
Traceback (most recent call last):
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\tornado\ioloop.py", line 743, in _run_callback
    ret = callback()
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\tornado\ioloop.py", line 767, in _discard_future_result
    future.result()
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\bokeh\server\session.py", line 67, in _needs_document_lock_wrapper
    result = func(self, *args, **kwargs)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\bokeh\server\session.py", line 195, in with_document_locked
    return func(*args, **kwargs)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\bokeh\document\document.py", line 1183, in wrapper
    return doc._with_self_as_curdoc(invoke)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\bokeh\document\document.py", line 1169, in _with_self_as_curdoc
    return f()
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\bokeh\document\document.py", line 1182, in invoke
    return f(*args, **kwargs)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\bokeh\document\document.py", line 972, in remove_then_invoke
    return callback(*args, **kwargs)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\panel\pane\base.py", line 153, in _update_object
    self._update(old_model)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\panel\pane\markup.py", line 50, in _update
    model.update(**self._get_properties())
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\panel\pane\image.py", line 93, in _get_properties
    data = self._img()
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\panel\pane\plot.py", line 159, in _img
    self.object.canvas.print_figure(b, bbox_inches=bbox_inches)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\backend_bases.py", line 2217, in print_figure
    **kwargs)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\backend_bases.py", line 1639, in wrapper
    return func(*args, **kwargs)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\backends\backend_agg.py", line 509, in print_png
    FigureCanvasAgg.draw(self)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\backends\backend_agg.py", line 407, in draw
    self.figure.draw(self.renderer)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\artist.py", line 41, in draw_wrapper
    return draw(artist, renderer, *args, **kwargs)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\figure.py", line 1864, in draw
    renderer, self, artists, self.suppressComposite)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\image.py", line 131, in _draw_list_compositing_images
    a.draw(renderer)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\artist.py", line 41, in draw_wrapper
    return draw(artist, renderer, *args, **kwargs)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\cbook\deprecation.py", line 411, in wrapper
    return func(*inner_args, **inner_kwargs)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\axes\_base.py", line 2707, in draw
    self._update_title_position(renderer)
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\axes\_base.py", line 2636, in _update_title_position
    if (ax.xaxis.get_ticks_position() in ['top', 'unknown']
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\axis.py", line 2207, in get_ticks_position
    self._get_ticks_position()]
  File "C:\Users\danie\.conda\envs\pg\lib\site-packages\matplotlib\axis.py", line 1892, in _get_ticks_position
    major = self.majorTicks[0]
IndexError: list index out of range

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant