Anaconda has already been installed. To use it, type
use conda
There are some pre-installed conda environment available, you can check available conda environment by typing
conda env list
For example, you will see a conda environment named ml
. However, there are some problems with these pre-installed environment at the moment. For example, PyTorch in the ml
environment cannot detect GPUs available in the workstation. So please create your own environment as follows.
(MUST DO) Before creating your own environment, we first need to specify where new Python packages will be downloaded. Packages are downloaded and stored in the user's HOME directory by default. Following the similar suggestion for CCR, we want to download those packages in the local space (i.e., /data/
directory that has 2 TB storage space). To do so, simply typing:
conda config --add pkgs_dirs /data/shared/ce-kaihangs_puser/pkgs
where /data/shared/ce-kaihangs_puser/pkgs
is the path where all packages will be downloaded and stored. The path /data/shared/ce-kaihangs_puser
is a shared directory that all members in the Shi Group have access to. Because Python packages will take up a lot of space, your HOME directory (with 16 GB space) would be filled up quickly by default. So, this step is a must-do.
Now, it’s time to create a new conda environment. To create a new environment with name my_env
, type
conda create -p $env_path
where $env_path
is the environment's directory (e.g. /data/users/kaihangs/conda/my_env
). Since your HOME directory only has 16 GB space, I highly recommend that you install new conda environment in your own folder under /data/users/
; there we have 2 TB storage space.
To activate the conda environment:
conda activate $env_path
Replace $env_path
in the command with the actual path of your new environment (e.g., /data/users/kaihangs/conda/my_env
).
To install Python in your environment:
conda install python
Then, future Python packages will be installed to your conda folder, e.g., /data/users/kaihangs/conda/my_env
. Python installation files are archived and stored in the shared directory above: /data/shared/ce-kaihangs_puser/pkgs
.
To connect your local VS Code to the workstation, you can use the “SSH” function in the VS Code. The “SSH” function in VS Code basically allows the VS Code to connect to the remote machine through SSH and no tunnel is needed. To use “SSH” (for first-time user):
Open “Extensions” → Type “ssh” in the search bar and click “Remote - SSH” → Install the extension.
Click “Remote Explorer” → Add new SSH remote by clicking “+” sign
Type ssh your_UBIT_name[@qilin.eng.buffalo.edu](<mailto:[email protected]>)
in the pop-up bar. Replace your_UBIT_name
with your UBIT name. Then choose the first option to store this address to the config file. Then click “Connect” in the pop-up window at the bottom right corner.
Now a new window should open. Select “Linux”. Then type in your UBIT password.
Now you should be connected! 📶
By default, you are in your HOME directory (e.g., /eng/home/kaihangs
). You can click “Open folder” to select the address you want to go. Once you change the address, you may need to type in your UBIT password again.