Skip to content
Discussion options

You must be logged in to vote

I had a chat with Chat GPT and it proposed me this approach:

import importlib

PIL = importlib.import_module('PIL.Image')

and it worked. Then I tried doing it like this:

import PIL.Image

and it worked too! Hope it will help anyone!

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by JohnScience
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants