# localcolabfold **Repository Path**: xinuozhineng/localcolabfold ## Basic Information - **Project Name**: localcolabfold - **Description**: No description available - **Primary Language**: Unknown - **License**: MIT - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2022-01-31 - **Last Updated**: 2022-03-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # LocalColabFold [ColabFold](https://colab.research.google.com/github/sokrypton/ColabFold/blob/main/AlphaFold2.ipynb) on your local PC (or macOS). See also [ColabFold repository](https://github.com/sokrypton/ColabFold). ## Advantages of LocalColabFold - **Structure inference and relaxation will be accelerated if your PC has Nvidia GPU and CUDA drivers.** - **No Time out (90 minutes and 12 hours)** - **No GPU limitations** - **NOT necessary to prepare the large database required for native AlphaFold2**. ## New Updates - 09Dec2021, version 1.2.0-beta released. easy-to-use updater scripts added. See [How to update](#how-to-update). - 04Dec2021, LocalColabFold is now compatible with the latest [pip installable ColabFold](https://github.com/sokrypton/ColabFold#running-locally). In this repository, I will provide a script to install ColabFold with some external parameter files to perform relaxation with AMBER. The weight parameters of AlphaFold and AlphaFold-Multimer will be downloaded automatically at your first run. ## Installation ### For Linux 1. Make sure `curl`, `git`, and `wget` commands are already installed on your PC. If not present, you need install them at first. For Ubuntu, type `sudo apt -y install curl git wget`. 2. Make sure your Cuda compiler driver is **11.1 or later** (If you don't have a GPU or don't plan to use a GPU, you can skip this section) :
$ nvcc --version nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2020 NVIDIA Corporation Built on Mon_Oct_12_20:09:46_PDT_2020 Cuda compilation tools, release 11.1, V11.1.105 Build cuda_11.1.TC455_06.29190527_0DO NOT use `nvidia-smi` to check the version.
$ gcc --version gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0 Copyright (C) 2019 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.If the version is 4.8.5 or older (e.g. CentOS 7), install a new one and add `PATH` to it. 1. Download `install_colabbatch_linux.sh` from this repository:
$ wget https://raw.githubusercontent.com/YoshitakaMo/localcolabfold/main/install_colabbatch_linux.shand run it in the directory where you want to install:
$ bash install_colabbatch_linux.shAbout 5 minutes later, `colabfold_batch` directory will be created. Do not move this directory after the installation. Keep the network unblocked. And **check the log** output to see if there are any errors. If you find errors in the output log, the easiest way is to check the network and delete the colabfold_batch directory, then re-run the installation script. 2. Add environment variable PATH:
# For bash or zshIt is recommended to add this export command to \~/.bashrc and restart bash (\~/.bashrc will be executed every time bash is started) 3. To run the prediction, type
# e.g. export PATH="/home/moriwaki/Desktop/colabfold_batch/bin:\$PATH"
export PATH="/bin:\$PATH"
colabfold_batch --amber --templates --num-recycle 3 inputfile outputdir/The result files will be created in the `outputdir`. Just use cpu to run the prediction, type
colabfold_batch --amber --templates --num-recycle 3 inputfile outputdir/ --cpuTo run the AlphaFold2-multimer, type
colabfold_batch --amber --templates --num-recycle 3 --model-type AlphaFold2-multimer inputfile outputdir/The inputfile can be in csv format like this
id,sequence Complex,\replace \:\ :\ :\
$ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"2. Install `wget`, `gnu-sed`, [HH-suite](https://github.com/soedinglab/hh-suite) and [kalign](https://github.com/TimoLassmann/kalign) using Homebrew:
$ brew install wget gnu-sed3. Download `install_colabbatch_intelmac.sh` from this repository:
\$ brew install brewsci/bio/hh-suite brewsci/bio/kalign
$ wget https://raw.githubusercontent.com/YoshitakaMo/localcolabfold/main/install_colabbatch_intelmac.shand run it in the directory where you want to install:
$ bash install_colabbatch_intelmac.shAbout 5 minutes later, `colabfold_batch` directory will be created. Do not move this directory after the installation. 4. The rest procedure is the same as "For Linux". #### For Mac with Apple Silicon (M1 chip) **Note: This installer is experimental because most of the dependent packages are not fully tested on Apple Silicon Mac.** 1. Install [Homebrew](https://brew.sh/index_ja) if not present:
$ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"1. Install several commands using Homebrew (currently kalign can't be installed, but no effects):
$ brew install wget cmake gnu-sed1. Install `miniforge` command using Homebrew:
$ brew install brewsci/bio/hh-suite
$ brew install --cask miniforge1. Download `install_colabbatch_M1mac.sh` from this repository:
$ wget https://raw.githubusercontent.com/YoshitakaMo/localcolabfold/main/install_colabbatch_M1mac.shand run it in the directory where you want to install:
$ bash install_colabbatch_M1mac.shAbout 5 minutes later, `colabfold_batch` directory will be created. Do not move this directory after the installation. **You can ignore the installation errors that appear along the way**. 2. The rest procedure is the same as "For Linux". A Warning message appeared when you run the prediction: ``` You are using an experimental build of OpenMM v7.5.1. This is NOT SUITABLE for production! It has not been properly tested on this platform and we cannot guarantee it provides accurate results. ``` This message is due to Apple Silicon, but I think we can ignore it. ## How to update Because [ColabFold](https://github.com/sokrypton/ColabFold) is still a work in progress, the localcolabfold should be also updated frequently to use the latest features. I will provide an easy-to-use update script. To update your localcolabfold, simply type in the `colabfold_batch` directory: ```bash $ ./update_linux.sh . # if Linux $ ./update_intelmac.sh . # if Intel Mac $ ./update_M1mac.sh . # if M1 Mac ``` Or, if you have already installed localcolabfold before, please download the updater from this repository and execute it. ```bash # set your OS. Select one of the following variables {linux,intelmac,M1mac} $ OS=linux # if Linux $ wget https://raw.githubusercontent.com/YoshitakaMo/localcolabfold/main/update_${OS}.sh $ chmod +x update_${OS}.sh $ ./update_${OS}.sh /path/to/your/colabfold_batch ``` ## FAQ - What else do I need to do before installation? Do I need sudo privileges? - No, except for installation of `curl` and `wget` commands. - Do I need to prepare the large database such as PDB70, BFD, Uniclust30, MGnify...? - **No. it is not necessary.** Generation of MSA is performed by the MMseqs2 web server, just as implemented in ColabFold. - Are the pLDDT score and PAE figures available? - Yes, they will be generated just like the ColabFold. - Is it possible to predict homooligomers and complexes? - Yes, the format of input sequence is the same as ColabFold. See `query_sequence:` and its use of [ColabFold: AlphaFold2 using MMseqs2](https://colab.research.google.com/github/sokrypton/ColabFold/blob/main/AlphaFold2.ipynb). - Is it possible to create MSA by jackhmmer? - **No, it is not currently supported**. - I want to use multiple GPUs to perform the prediction. - **AlphaFold and ColabFold does not support multiple GPUs**. Only One GPU can model your protein. - I got an error message `CUDA_ERROR_ILLEGAL_ADDRESS: an illegal memory access was encountered`. - You may not have updated to CUDA 11.1 or later. Please check the version of Cuda compiler with `nvcc --version` command, not `nvidia-smi`. - Is this available on Windows 10? - You can run LocalColabFold on your Windows 10 with [WSL2](https://docs.microsoft.com/en-us/windows/wsl/install-win10). - (New!)I want to use a custom MSA file in the format of a3m. - **ColabFold can accept various input files now**. See the help messsage. You can set your own A3M file, a fasta file that contains multiple sequences (in FASTA format), or a directory that contains multiple fasta files. ## Tutorials & Presentations - ColabFold Tutorial presented at the Boston Protein Design and Modeling Club. [[video]](https://www.youtube.com/watch?v=Rfw7thgGTwI) [[slides]](https://docs.google.com/presentation/d/1mnffk23ev2QMDzGZ5w1skXEadTe54l8-Uei6ACce8eI). ## Acknowledgments - The original colabfold was first created by Sergey Ovchinnikov ([@sokrypton](https://twitter.com/sokrypton)), Milot Mirdita ([@milot_mirdita](https://twitter.com/milot_mirdita)) and Martin Steinegger ([@thesteinegger](https://twitter.com/thesteinegger)). ## How do I reference this work? - Mirdita M, Schütze K, Moriwaki Y, Heo L, Ovchinnikov S and Steinegger M. ColabFold - Making protein folding accessible to all.