Setup working environment on a new machine
Recently I replaced my old laptop with a new one. This post records the steps to install some neccessary packages on the new machine after the operating system (Ubuntu 20.04.3) is installed.
Update apt source
The first step is to add a new source for package installation. This is done in the following two steps.
- Add the following lines to the file: /etc/apt/source.list (this source is suitable for mainland China. One should use a different source depending on locations).
deb http://mirrors.aliyun.com/ubuntu/ focal main restricted
deb http://mirrors.aliyun.com/ubuntu/ focal-updates main restricted
deb http://mirrors.aliyun.com/ubuntu/ focal universe
deb http://mirrors.aliyun.com/ubuntu/ focal-updates universe
deb http://mirrors.aliyun.com/ubuntu/ focal multiverse
deb http://mirrors.aliyun.com/ubuntu/ focal-updates multiverse
deb http://mirrors.aliyun.com/ubuntu/ focal-backports main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ focal-security main restricted
deb http://mirrors.aliyun.com/ubuntu/ focal-security universe
deb http://mirrors.aliyun.com/ubuntu/ focal-security multiverse
deb http://mirrors.aliyun.com/ubuntu/ focal main restricted
- Run the command to update the source
sudo apt update
Configuration files
I have copied the following configuration files from my old laptop.
- ~/.bashrc
- ~/.gitconfig and ~/.git-credentials
- ~/.vimrc
- the files config and known_hosts under the directory ~/.ssh
Some general softwares
- Install Git, Subversion, Make, Vim, g++:
sudo apt install git subversion make
sudo apt install vim
sudo apt install g++
- Install Latex, Okular, pdftk:
sudo apt install texlive-full
sudo apt install okular
sudo apt install pdftk
-
Google Chrome:
First download the deb package from the official website. Then run
sudo dpkg -i google-chrome-stable_current_amd64.deb
Also install the vimium plugin.
sudo apt install ibus ibus-clutter ibus-gtk ibus-gtk3
sudo apt install ibus-pinyin
Packages for scientific computing
-
Miniconda: for package management.
-
Python packages: numpy, scipy, matplotlib, jupyter nootbook, and pytorch.
conda install numpy
conda install scipy
conda install matplotlib
conda install jupyter notebook
conda install pytorch torchvision torchaudio -c pytorch
- MPICH: library for parallel computing.
sudo apt install mpich
- OpenMM: library for molecular simulation, and the OpenMM PyTorch Plugin that allows the use of forces defined by PyTorch.
conda install -c conda-forge openmm
conda install -c conda-forge openmm-torch
- Libconfig: library for processing configuration files, installed from source.
- CMake: tools for library building, installed from source.
- FFTW: package for Fast Fourier Transform, installed from source.
- Ranlib.c.tar.gz: codes for random number generator, installed from source.