akanz1/klib

[BUG] - Plots not showing up in Jupyter Notebooks on Mac M1

dhmo1900 opened this issue · 5 comments

Describe the bug

Plots not showing up in jupyter notebooks on mac m1

To Reproduce
Steps to reproduce the behavior:

  1. Install the library on a fresh conda enviroment (on macbook air M1, big sur)
  2. run the jupyter notebook
  3. import data from seaborn
  4. Plot the charts (the corr_mat does show up).

Expected behavior
The plots should show up as per the library homepage.

Screenshots
image

Desktop (please complete the following information):

  • OS: Mac Big Sur
  • Browser: Chrome/VS Code + Jupyter Notebooks

Thanks for filing this issue @dhmo1900 I'll have a look later today but it might take a few weeks until i have my own M1 to debug / test what is going on. Might be related to some dependency. In the meantime you can keep an eye on the following links, which might resolve this issue in the near future.

jupyterlab/jupyterlab#12164

https://stackoverflow.com/questions/70466222/m1-mac-python-assertion-failure-and-crashes-when-using-osx-as-backend-in-matplo

And for completeness / reminder to myself: matplotlib/matplotlib#22545 (in case the issue comes from mpl and not from jupyter/ipython)

Hi @akanz1 , I can confirm that the library works fine in Windows.

Hi @akanz1, well, well!! Update!! I had been trying to use many such libraries in a single, dedicated environment for all EDA work. This included Autoviz, SweetViz, Pandas-Profiling etc. Don't know what was wrong, but I created a completely new conda environment and first installed Klib before any of these libraries. I suspect there are some dependency clashes which might have led to this issue in the first place. I can confirm that as of now, all works fine on Mac M1. For complete details, here are the main libraries and their versions:

Python: 3.10.4
Pandas: 1.4.2
Numpy: 1.21.6
MatplotLib: 3.5.2
Seaborn: 0.11.2
Bokeh: 2.4.2
Plotly: 5.7.0
KLib: 1.0.1
Autoviz: 0.0.85
Sweetviz: 2.1.3
D-tale: 2.4.0
Pandas-Profiling: 3.2.0

Also, for jupyter notebooks, there could be some corruption of the ipywidgets and nbextentions. Fresh enviroment solves many of these problems.

(Hardware details in the original bug report).

Hope this helps. Thanks.

@dhmo1900 It might be that in your previous environment you did not get the latest dependencies since some of the other libraries might limit how far dependencies can be upgraded.

Glad to hear it works!