From 9b27e8d32942fd8ccc101a953e23565cc0b3395b Mon Sep 17 00:00:00 2001 From: Chun Cai Date: Tue, 19 Mar 2024 11:24:18 +0800 Subject: [PATCH 1/2] migrate existed conda build workflow to conda-forge --- unidock/conda/conda_build_config.yaml | 8 --- unidock/conda/meta.yaml | 75 --------------------------- 2 files changed, 83 deletions(-) delete mode 100644 unidock/conda/conda_build_config.yaml delete mode 100644 unidock/conda/meta.yaml diff --git a/unidock/conda/conda_build_config.yaml b/unidock/conda/conda_build_config.yaml deleted file mode 100644 index 99ac936..0000000 --- a/unidock/conda/conda_build_config.yaml +++ /dev/null @@ -1,8 +0,0 @@ -cuda_compiler: cuda-nvcc # Required for compiler('cuda') -channel_sources: conda-forge # Required for compiler('cxx') - -# nvcc requires a compatible gcc version. See https://gist.github.com/ax3l/9489132#nvcc -# If you are using CUDA 11, the following settings are recommended: -# cuda_compiler: nvcc -# cxx_compiler_version: 10 -# cuda_compiler_version: 11 diff --git a/unidock/conda/meta.yaml b/unidock/conda/meta.yaml deleted file mode 100644 index 000e6e0..0000000 --- a/unidock/conda/meta.yaml +++ /dev/null @@ -1,75 +0,0 @@ -{% set version = os.popen('git describe --tags --abbrev=0').read().strip('\n').lstrip('v').replace('-', '_') %} - -# This script is used for building a conda package for Uni-Dock. -# CUDA Toolkit is required. -# If you are using CUDA Toolkit 11.x, check conda_build_config.yaml for instructions. - -# conda build . -c conda-forge - -package: - name: unidock - version: {{ version }} - -# By default it builds the source codes from the local directory. -# To build the release version from GitHub, -# comment out the 'path' line and uncomment the 'git_url' and 'git_rev' line, -# and replace {{ version }} with the release version number. - -source: - path: ../.. # Root dir of Uni-Dock - # git_url: https://github.com/dptech-corp/Uni-Dock.git - # git_rev: {{ version }} - -build: - skip: true # [not linux] - - # ${CMAKE_ARGS} applys restrictions for CMake to search libs under conda building env. - # See https://conda-forge.org/docs/maintainer/knowledge_base.html#using-cmake . - # https://docs.conda.io/projects/conda-build/en/stable/user-guide/environment-variables.html#environment-variables-set-during-the-build-process - script: | - cd unidock - mkdir conda_build && cd conda_build - cmake ${CMAKE_ARGS} ${SRC_DIR}/unidock - make unidock -j$CPU_COUNT - make install - - string: {{ GIT_BUILD_STR }} - number: {{ GIT_DESCRIBE_NUMBER }} - -requirements: - build: - - {{ compiler('cxx') }} - - {{ compiler('cuda') }} # https://conda-forge.org/docs/maintainer/knowledge_base.html#cuda-builds - - cmake - - host: - - libboost-devel - - libcurand-dev - - run: - - libboost - - -test: - commands: - # Dry run to verify dynamic libs are present. - - unidock --version - -about: - home: https://github.com/dptech-corp/Uni-Dock - doc_url: https://github.com/dptech-corp/Uni-Dock - dev_url: https://github.com/dptech-corp/Uni-Dock - license: LGPL-3.0 - license_family: LGPL - license_file: unidock/LICENSE - summary: A GPU-accelerated molecular docking program - description: > - Uni-Dock is a GPU-accelerated molecular docking program developed by DP Technology. - It supports various scoring functions including vina, vinardo, and ad4. - Uni-Dock achieves more than 1000-fold speed-up on V100 GPU with high-accuracy, - compared with the AutoDock Vina running in single CPU core. - The paper has been accepted by JCTC (doi: 10.1021/acs.jctc.2c01145). - -extra: - recipe-maintainers: - - caic99 From 0d5499a697f2b7de2af5f606bed53edd83b88057 Mon Sep 17 00:00:00 2001 From: Chun Cai Date: Tue, 19 Mar 2024 11:31:55 +0800 Subject: [PATCH 2/2] Add instructions on fetching unidock by conda-forge --- unidock/README.md | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/unidock/README.md b/unidock/README.md index 5c378a0..c84c02b 100644 --- a/unidock/README.md +++ b/unidock/README.md @@ -13,6 +13,23 @@ The [paper](https://pubs.acs.org/doi/10.1021/acs.jctc.2c01145) has been accepted Uni-Dock officially supports NVIDIA GPUs with [compute capability](https://en.wikipedia.org/wiki/CUDA#GPUs_supported) >= 7.0 on Linux platform. The performance is not guaranteed on legacy GPU models. To build Uni-Dock with a customized compute capability, please change the `CMAKE_CUDA_ARCHITECTURES` variable in `CMakeLists.txt` to the corresponding value. +### Installing by Conda + +Conda is a package management system with a separated environment, not requiring system privileges. +You can refer to [DeepModeling conda FAQ](https://docs.deepmodeling.com/faq/conda.html) for how to setup a conda environment. +A pre-built Uni-Dock binary with all requirements is available at [conda-forge](https://anaconda.org/conda-forge/unidock). + +```bash +# Install +# We recommend installing Uni-Dock in a new environment to avoid potential conflicts: +conda create -n unidock_env unidock -c conda-forge +# Run +conda activate unidock +unidock --help +# Update +conda update -n unidock_env unidock -c conda-forge +``` + ### Building from source 1. Install dependencies @@ -55,13 +72,6 @@ cd ./build/ make clang-format ``` -### Using binary - -Please download the latest binary of Uni-Dock at the assets tab of [the Release page](https://github.com/dptech-corp/Uni-Dock/releases). -Executable `unidock` to dock. - -After downloading, please make sure that the path to `unidock` is in your `PATH` environment variable. - ## Usage ### Example