-->

Welcome to our Coding with python Page!!! hier you find various code with PHP, Python, AI, Cyber, etc ... Electricity, Energy, Nuclear Power

Thursday 5 July 2018

Python | How do I import modules in pycharm?

Go into File → Settings → Project Settings → Project Interpreter.
Then press configure interpreter, and navigate to the "Paths" tab.
pycharm path tab
Press the + button in the Paths area. You can put the path to the module you'd like it to recognize.

But I don't know the path..

Open the python interpreter where you can import the module.
>> import gnuradio
>> gnuradio.__file__
"path/to/gnuradio"
Most commonly you'll have a folder structure like this:
foobarbaz/
  gnuradio/
    __init__.py
    other_file.py
You want to add foobarbaz to the path here.

No comments:

Post a Comment

Thanks for your comments

Rank

seo