Skip to content

cbi-society/cheminfo_tutorial_20241028_pub

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cheminfo_tutorial_20241028

cheminfomratics handson @ CBI2024年大会

Breaf introduction

This is the material for cheminformatics hands-on session at CBI2024

Participants requirements

  • Basic skill of python programming
  • Basic knowledge of cheminfomratics
  • Unfortunately it's difficult to support pure Windows os. The code will be tested on Linux, Mac OS and Windows WSL.

Prerequreiment

  • Install anaconda or mambaforge
  • Install REINVENT ver4
  • Install Autodock Vina
  • Install Gypsum-DL
  • Install Maize-contrib ver 0.5.5

INSTALL

The following example uses conda for package management, but it is possible to use mamba instead. mamba is a C++ re-implementation of the conda package manager, which is faster than conda but has problems with the build process in some environments.

FOR Ubuntu24.04

REINVENT4

$ git clone https://github.com/MolecularAI/REINVENT4.git
$ cd REINVENT4
$ conda create --name reinvent4 python=3.10
$ conda activate reinvent4
$ pip install -r requirements-linux-64.lock
$ pip install --no-deps .
  • Optional:
    • if you want to use AMD GPUs please check original repo's README

Autodock Vina

The example put vina on /opt/vina but you can put vina any place.

$ wget https://github.com/ccsb-scripps/AutoDock-Vina/releases/download/v1.2.5/vina_1.2.5_linux_x86_64
$ sudo mkdir -p /opt/vina/bin/
$ sudo mv vina_1.2.5_linux_x86_64 /opt/vina/bin
$ sudo chmod a+x /opt/vina/bin/vina_1.2.5_linux_x86_64
$ sudo ln -s /opt/vina/bin/vina_1.2.5_linux_x86_64 /opt/vina/bin/vina
$ export PATH=/opt/vina/bin/:$PATH

Gypsum-DL

if you don't have mpi, remove mpi4py from the following command.

$ sudo apt install openmpi-bin
$ conda create --name gypsum python=3.10
$ conda activate gypsum
$ conda install -c conda-forge rdkit numpy scipy mpi4py
$ git clone https://github.com/durrantlab/gypsum_dl.git

Maize-contrib

$ git clone https://github.com/cbi-society/maize-contrib.git
$ cd maize-contrib
$ conda env create -f env-users.yml
$ conda activate maize
$ pip install --no-deps ./
$ conda install -c conda-forge pymol-open-source jupyter

FOR MacOS 14.61(M3)

Set the directory to be used for the hands-on session.

$ cd ~
$ mkdir CBI
$ cd CBI

REINVENT4

$ git clone https://github.com/Mishima-syk/REINVENT4.git
$ cd REINVENT4
$ conda create --name reinvent4 python=3.11
$ conda activate reinvent4
$ pip install -r requirements-macOS.lock
$ pip install --no-deps .

Autodock Vina

$ wget https://vina.scripps.edu/wp-content/uploads/sites/55/2020/12/autodock_vina_1_1_2_mac_64bit.tar.gz
$ tar xvfz autodock_vina_1_1_2_mac_64bit.tar.gz
$ sudo mkdir -p /opt/vina/bin/
$ sudo mv autodock_vina_1_1_2_mac_catalina_64bit/bin/vina /opt/vina/bin/.

Gypsum-DL

$ sudo apt info openmpi-bin
$ conda create --name gypsum python=3.10
$ conda activate gypsum
$ conda install -c conda-forge rdkit numpy scipy
$ git clone https://github.com/durrantlab/gypsum_dl.git

Maize-contrib & Maize

$ git clone https://github.com/cbi-society/maize-contrib.git
$ cd maize-contrib
$ conda env create -f env-users.yml
$ conda activate maize
$ pip install --no-deps .
$ cd ..
$ git clone https://github.com/Mishima-syk/maize.git
$ cd maize
$ pip install --no-deps .
$ conda install -c conda-forge pymol-open-source jupyter

FOR Windows 11

NOTE

  • Following code run on WSL2. Not pure windows environment.
  • WSL users should install pymol in another environment because WSL doesn't have GUI interface.
  • To avoid error, I recommend to run following command before installing other packages.
# https://uwanosora22.hatenablog.com/entry/2022/03/15/125128
$ git config --global http.version HTTP/1.1
# https://web-survivor.com/useful/git-error-curl/
$ git config --global http.postBuffer 524288000

REINVENT4

$ git clone https://github.com/MolecularAI/REINVENT4.git
$ cd REINVENT4
$ conda create --name reinvent4 python=3.10
$ conda activate reinvent4
$ pip install -r requirements-linux-64.lock
$ pip install --no-deps .

Autodock Vina

The example put vina on /opt/vina but you can put vina any place.

$ wget https://github.com/ccsb-scripps/AutoDock-Vina/releases/download/v1.2.5/vina_1.2.5_linux_x86_64
$ sudo mkdir -p /opt/vina/bin/
$ sudo mv vina_1.2.5_linux_x86_64 /opt/vina/bin
$ sudo chmod a+x /opt/vina/bin/vina_1.2.5_linux_x86_64
$ sudo ln -s /opt/vina/bin/vina_1.2.5_linux_x86_64 /opt/vina/bin/vina
$ export PATH=/opt/vina/bin/:$PATH

Gypsum-DL

if you don't have mpi, remove mpi4py from the following command.

$ sudo apt install openmpi-bin
$ conda create --name gypsum python=3.10
$ conda activate gypsum
$ conda install -c conda-forge rdkit numpy scipy mpi4py
$ git clone https://github.com/durrantlab/gypsum_dl.git

Maize-contrib

$ git clone https://github.com/cbi-society/maize-contrib.git
$ cd maize-contrib
$ conda env create -f env-users.yml
$ conda activate maize
$ pip install --no-deps ./
$ conda install -c conda-forge jupyter

Reference & Link

IMPORTANT Pre-requirements

  • ./data以下にて配布しているxx_tmpl.tomlファイルはテンプレートファイルです。これを以下の手順に沿って各自の環境に書き換えて下さい。当日作業する場合、時間がかかりハンズオンについていけなくなる懸念があります。
  • Please modify following toml files before participating hands-on training
  • {put your environment here!} part should be changed as your own environment value.
  • modified files should be saved as name without '_tmpl'
    • ./data/maize_tmpl.toml
    • ./data/genai/transfer_learning_tmpl.toml
    • ./data/genai/sampling_tmpl.toml
    • ./data/genai/TL_sampling_tmpl.toml
  • To run the code, XDG_CONFIG_HOME variable should be set and the directory should contain maize.toml which is modefied above procedure. The procedure is shown below.
export XDG_CONFIG_HOME="{where your maize.toml placed}":$XDG_CONFIG_HOME

IMPORTANT2 XDG_CONFIG_HOMEがうまく設定できない場合

  • setenv.py内の'{where your maize.toml placed}'をご自身のmaize.tomlをおいた絶対Pathに置き換え、各ノートブックの一番最初に以下の一行を加えてください。
import setenv

Misc

  • maize cofiguration file

    • By default Config will look for a configuration file named maize.toml in $XDG_CONFIG_HOME (usually at ~/.config/,) detail
    • The repo provides example maize.toml for SBDD WF. We will configure it in this handson training ;-)
    $ echo $XDG_CONFIG_HOME
    /home/iwatobipen/.config
    $ cat /home/iwatobipen/.config/maize.toml
    # maize global configuration file example
    # Where to save temporary files and all workflow directories
    scratch = "/tmp"
  • Tested OS

    • Ubuntu24.04
    • Ubuntu22.04
    • CentOS
    • MacOS M1
    • MacOS M2
    • MacOS14 M3
    • WSL on Windows11

Author

  • Kazufumi Ohkawa
  • Koichiro Arai
  • Natsumi Miyano
  • Kazutoshi Takahashi
  • Takayuki Serizawa

注意事項

  • 利用しているパッケージはいずれも更新が頻繁にかかります。本リポジトリはCBI学会2024年大会チュートリアル用に各パッケージをフォークし作成しました。
  • 今後フォーク元のコードの更新を継続的に追従し更新する保証はいたしません。
  • プロダクションにあたっては、オリジナルのリポジトリを利用し最新の環境を構築されることをお勧めいたします。
  • 本マテリアルに関する質問や、議論につきましてはIssue、Discussionに投稿してください。

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages