Skip to content

module 'PIL.Image' has no attribute 'ANTIALIAS' #8

Description

@MaxFremen

when installing from pip:

... code from README.MD ...

In [2]: plt.show()
---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
Cell In[2], line 1
----> 1 plt.show()

File ~/anaconda3/envs/dzm-audio/lib/python3.10/site-packages/matplotlib/pyplot.py:527, in show(*args, **kwargs)
    483 """
    484 Display all open figures.
    485
   (...)
    524 explicitly there.
    525 """
    526 _warn_if_gui_out_of_main_thread()
--> 527 return _get_backend_mod().show(*args, **kwargs)

File ~/anaconda3/envs/dzm-audio/lib/python3.10/site-packages/drawilleplot/__init__.py:30, in show()
     28         canvas = manager.canvas
     29         canvas.draw()
---> 30         string = canvas.to_txt()
     31         print(string)
     32         # display(HTML("<div style=\"font-size:2px; line-height:90%;\"><tt>" + string + "</tt></div>"))
     33 finally:
     34     #if close and Gcf.get_all_fig_managers():
     35     #    matplotlib.pyplot.close('all')

File ~/anaconda3/envs/dzm-audio/lib/python3.10/site-packages/drawilleplot/__init__.py:66, in FigureCanvasDrawill
e.to_txt(self, sep, tw, invert, threshold)
     64 w = tw
     65 h = int(h * ratio)
---> 66 i = i.resize((w, h), Image.ANTIALIAS)
     68 i = i.convert(mode="L")
     70 can = Canvas()

AttributeError: module 'PIL.Image' has no attribute 'ANTIALIAS'

No issues when installing from repo though.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions