How to run PyCharm OnDemand
How to run PyCharm OnDemand
- You must have an account to access the Grid. Submit a ticket to request a new account.
- To connect to the Grid OnDemand, you must use the Wayne State University Virtual Private Network (VPN). If you do already have the VPN configured, download and set up Palo Alto GlobalProtect to connect. Note: If you have a desktop with a static IP, you can request to have it approved by emailing us at hpc@wayne.edu.
- Open a browser window for Chrome or Firefox (OnDemand is only supported through these browsers) and go to ondemand.grid.wayne.edu.
- On the homepage, click Login to OnDemand. You will be prompted with a login window. Enter your AccessID and password. Click Sign In.
- You should now be logged on to the OnDemand dashboard. Go to the Interactive Apps menu and select PyCharm.
- Adjust the default options if desired and click Launch. Note: More is not always better, e.g. higher core count systems often have slower CPU core speeds. If your application is unable to utilize multiple threads, it will be a waste of resources and run your application on slower cores.
- Wait for your resources to be allocated. Once the job starts, the button Launch PyCharmwill appear. Click Launch PyCharm. A new tab will open launching PyCharm.
How to create a PyCharm project
The first time you run PyCharm you need to configure the PyCharm interpreter with python 3.7 because PyCharm defaults to the Grids base interpreter.
- On the welcome screen, select New Project.
- Set the interpreter type to Custom environment. The first time you launch PyCharm, set the environment to Generate new, set the type to Virtualenv, and set the base python to /usr/bin/python3.6. Once this is done, click Create. Note: Despite it saying the base python is 3.6, it will update to the 3.7 interpreter.
- Now that 3.7 is configured, for future projects please choose the Custom environment interpreter, and set the environment to Select existing. There you will be able to select Python 3.7.3 for your python path. Lastly, select Create.
How to create a python file in a PyCharm project
- In the Project tool window, right-click the root project folder. Click New and then click Python File.
- Enter the name of your python file and start coding.
How to open an existing project
There are two ways to open an existing project.
- Click a recent project displayed on the welcome screen or;
- Click Open, open your project path, click Ok, and then click Trust Project.
How to use Conda Environment in PyCharm Project
- List all of your Conda environments on the grid with the command Conda info --envs and then copy the directory you want.
- On the welcome screen, select New Project.
- Set the interpreter type to Custom environment, set the environment to Select existing, and set the type to Python, and then paste the Conda environment path you copied into the python path and add /bin/python to the end of it. Click Create.