question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

NotImplementedError: MatplotlibGridBackend does not implement displaying grids in 3D

See original GitHub issue

Hi,

When trying to plot a 3D property (RHO, Wavefunction, etc.), I am getting the following error:

---------------------------------------------------------------------------
NotImplementedError                       Traceback (most recent call last)
/tmp/ipykernel_19369/1433050745.py in <module>
----> 1 plot.update_settings(axes="xyz")

~/.local/lib/python3.9/site-packages/sisl/viz/configurable.py in update_settings(self, *args, **kwargs)
    435             # the available kwargs for the plot class and provide more help to the user
    436             def update_settings(self, *args, **kwargs):
--> 437                 return self._update_settings(*args, **kwargs)
    438 
    439             update_settings.__doc__ = f"Updates the settings of this plot.\n\nDocs for {new_cls.__name__}:\n\n{get_configurable_docstring(new_cls)}"

~/.local/lib/python3.9/site-packages/sisl/viz/configurable.py in _update_settings(self, run_updates, **kwargs)
    556             #Do things after updating the settings
    557             if len(self.settings_history.last_updated) > 0 and run_updates:
--> 558                 self._run_updates(self.settings_history.last_updated)
    559 
    560         return self

~/.local/lib/python3.9/site-packages/sisl/viz/configurable.py in _run_updates(self, for_keys)
    584         # Execute the functions that we need to execute.
    585         for f_name in func_names:
--> 586             getattr(self, f_name)()
    587 
    588         return self

~/.local/lib/python3.9/site-packages/sisl/viz/plotutils.py in apply_to_all_plots(obj, children_sel, *args, **kwargs)
    827         else:
    828 
--> 829             return method(obj, *args, **kwargs)
    830 
    831     return apply_to_all_plots

~/.local/lib/python3.9/site-packages/sisl/viz/configurable.py in func(obj, *args, **kwargs)
    886             def func(obj, *args, **kwargs):
    887                 getattr(obj, method_name)(**kwargs, **extra_kwargs)
--> 888                 return method(obj, *args, **kwargs)
    889 
    890         elif when == 'after':

~/.local/lib/python3.9/site-packages/sisl/viz/plot.py in set_data(self, update_fig, **kwargs)
   1113 
   1114         if update_fig:
-> 1115             self.get_figure()
   1116 
   1117         return self

~/.local/lib/python3.9/site-packages/sisl/viz/configurable.py in f_default_setting_args(self, *args, **kwargs)
    967                     pass
    968 
--> 969         return f(self, *args, **kwargs)
    970 
    971     return f_default_setting_args

~/.local/lib/python3.9/site-packages/sisl/viz/plot.py in get_figure(self, backend, clear_fig, **kwargs)
   1142             self.clear()
   1143 
-> 1144         self.draw(getattr(self, "_for_backend", None))
   1145 
   1146         call_method_if_present(self, '_after_get_figure')

~/.local/lib/python3.9/site-packages/sisl/viz/backends/templates/_plots/grid.py in draw(self, backend_info)
     24         drawing_func = getattr(self, f"draw_{backend_info['ndim']}D")
     25 
---> 26         drawing_func(backend_info)
     27 
     28         if backend_info["geom_plot"] is not None:

~/.local/lib/python3.9/site-packages/sisl/viz/backends/matplotlib/_plots/grid.py in draw_3D(self, backend_info, **kwargs)
     46     def draw_3D(self, backend_info, **kwargs):
     47         # This will basically raise the NotImplementedError
---> 48         super().draw_3D(backend_info, **kwargs)
     49 
     50         # The following code is just here as reference of how this MIGHT

~/.local/lib/python3.9/site-packages/sisl/viz/backends/templates/_plots/grid.py in draw_3D(self, backend_info, **kwargs)
     39     def draw_3D(self, backend_info, **kwargs):
     40         """Should draw all the isosurfaces of the grid in 3D"""
---> 41         raise NotImplementedError(f"{self.__class__.__name__} does not implement displaying grids in 3D")
     42 
     43 GridPlot.backends.register_template(GridBackend)

NotImplementedError: MatplotlibGridBackend does not implement displaying grids in 3D

I installed SISL using CONDA.

Version details

print(sys.version): 3.9.9 | packaged by conda-forge | (main, Dec 20 2021, 02:40:17)  [GCC 9.4.0]
print(sisl.__version__): 0.11.1.dev507+gb0511912

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
icampscommented, Jan 17, 2022

Thanks @pfebrer . I will go through this issue to search what is happening because I install jupyter in each of my environments 😭.

1reaction
zerothicommented, Jan 17, 2022

Great you found a solution!

Read more comments on GitHub >

github_iconTop Results From Across the Web

About Grids in 3D Views - Revit - Autodesk Knowledge Network
When working in a 3D view, you can display and modify grids for the model. To change the visibility of grids in a...
Read more >
Display FAQ - ETABS - Technical Knowledge Base
Answer: Non-orthogonal grids are available through Edit > Grid Data. Select the grid system and the option to Convert to General System, ...
Read more >
Display or hide axes grid lines - MATLAB grid - MathWorks
To determine the class, use the class function. If you do not specify the target, then the grid function affects the graphics object...
Read more >
RAM Structural System 3D Viewer Grid Not Showing
We have some of our RAM models where the grid does not show up in views that rely on the 3D viewer and...
Read more >
Grid Lines
Each axis in a graph can include or exclude major and minor grid lines. ... Use of the WebFOCUS grid setting (SET GRID...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found