This C++/Python library is a chemical space exploration software. It is based on the Molpher program which implements a method called molecular morphing. This method uses stochastic optimization to traverse chemical space between two molecules. It can be used to sample unexplored areas that might contain new bioactive compounds with increased probability. The purpose of the library is to make molecular morphing more accessible and flexible and to provide good basis for further experimentation in this area. See the official website for additional information and usage examples.
The library is actively developed and a lot of new features are planned for the future. The long-term goal is to make Molpher-lib a universal and easy-to-use de novo drug design framework with possibilities that go beyond molecular morphing. If this seems interesting to you, you can take a look at the documentation to get an idea of what the library is currently capable of as well as what features are planned for future releases. Ideas, comments or feature requests are more than welcome and can be submitted to the issue tracker. You can also subscribe to the RSS feed for updates. If you want to know what is new in the current version, you can look at the changelog.
At the moment, the library is only intended for use on 64-bit Linux systems. However, development for other platforms is also a priority. If you manage to compile the library on a different platform, consider making a pull request or comment on the issue tracker. Any help is much appreciated.
Molpher-lib is distributed as a conda package. At the moment, this is the preferred way to install and use the library. All you need to do is just either get the full Anaconda distribution or its lightweight variant, Miniconda. It is essentially a Python distribution, package manager and virtual environment in one and makes setting up a development environment for your project very easy. After installing Anaconda/Miniconda you can run the following in the Linux terminal:
conda install -c lich molpher-libThis will automatically download the latest version of the library and install everything to the currently active environment (for more information on environments and the conda command see Conda Test Drive).
Installing from source is a little bit more elaborate because Molpher-lib contains a lot of C++ code that needs to be compiled first. This process is described here in detail, but in the simplest case the following should work:
git clone https://github.com/lich-uct/molpher-lib.git
ROOT_DIR=`pwd`/molpher-lib
cd $ROOT_DIR/deps
./build_deps.sh --all # this might take a while, but you can bypass this if you already have Boost and RDKit compiled somewhere (see https://lich-uct.github.io/molpher-lib/)
cd $ROOT_DIR
mkdir build # the name of the directory does not matter here
cd build
cmake ..
make molpher_install_python
# optionally the python package can be tested:
cd $ROOT_DIR
python setup.py testThe make target above builds the library and installs everything to $ROOT_DIR/dist. This is the default value for the CMAKE_INSTALL_PREFIX variable and it can be changed doing cmake .. -DCMAKE_INSTALL_PREFIX=custom/install/directory/ instead of just plain cmake ... This folder can be anywhere on the user's system provided that the following variables are set during runtime:
export PYTHONPATH=$CMAKE_INSTALL_PREFIX/lib/pythonX.Y/site-packages # replace X.Y with your Python version
export LD_LIBRARY_PATH=$CMAKE_INSTALL_PREFIX/libThe molpher package should now be importable from Python.
If you want to use the Python package right after the build, you can do so by just adding the $ROOT_DIR/src/python folder to PYTHONPATH like so:
export PYTHONPATH=$ROOT_DIR/src/pythonThis installation process was only tested on Debian 8.5 so experience on other Linux flavors may be different. If you run into problems, report them to the issue tracker and hopefully someone will be able to help.