1702
Comment:
|
4647
|
Deletions are marked like this. | Additions are marked like this. |
Line 1: | Line 1: |
= !!! UNDER CONSTRUCTION !!! = | = Anaconda based Build, All Platforms = |
Line 3: | Line 3: |
= All platforms = The following instructions will work with cmake changes introduced in https://github.com/cryoem/eman2/pull/65. |
Note that even with a source build it may be difficult to get this working on systems with very old operating system installs. We normally try to support OS versions 6-7 years old. Please report any problems. |
Line 9: | Line 7: |
1. Download and install [[https://www.continuum.io/downloads | Anaconda2]] or [[https://conda.io/miniconda.html | Miniconda2]]. | There are two approaches you can use for the installation. One uses 'Miniconda' and the other uses full 'Anaconda'. Miniconda is a much smaller (~30 MB) install, provides everything EMAN2 needs, and can be expanded with more packages as you like. Anaconda is a much more complete environment (~300 MB), including useful tools such as the Jupyter notebook, but will require the use of a conda environment to make EMAN2 work properly at present. |
Line 11: | Line 9: |
1. Checkout EMAN2 code from [[https://github.com/cryoem/eman2 | GitHub:cryoem/eman2]]. {{{ |
=== Miniconda2 === 1. Download and install [[https://conda.io/miniconda.html | Miniconda2]] - make sure you don't get the Python3 version 1. Make sure that you have added miniconda2/bin as the first element in your PATH, and that you do not have LD_LIBRARY_PATH or PYTHONPATH set in your shell. If you need these settings for other software, you can still try to proceed, and hope they do not conflict with Miniconda. Alternatively, you may set up a shell script or alias to make these environment changes on demand when you want to use EMAN2/miniconda. 1. Checkout EMAN2 code from [[https://github.com/cryoem/eman2 | GitHub:cryoem/eman2]]. {{{ |
Line 15: | Line 16: |
}}} 1. Install dependencies {{{ conda install eman-deps -c cryoem -c defaults -c conda-forge # Mac OSX conda install eman-deps="*"="np18*" -c cryoem -c defaults -c conda-forge # Linux }}} 1. Create a build directory (out-of-source builds are recommended). {{{ cd <build-directory> cmake -DENABLE_CONDA=ON <path-to-eman2-source> # on linux, also add -DENABLE_OPTIMIZE_MACHINE=ON }}} * If conda is not found in PATH, set CONDA_ROOT to your conda environment directory. It could be the main installation or an environment. This step most likely will be needed only if you use '''cmake-gui'''. * If you set CONDA_ROOT to an environment, make sure to delete any cmake variables that cmake already found, variables like EMAN_INSTALL_PREFIX, EMAN_PREFIX, *_LIBRARY or similar, *_INCLUDE_PATH or similar. * Rerun cmake. 1. Build EMAN2 {{{ make -j make install }}} 1. You may also wish to run {{{ make test # if everything passes you are fine, if there are failures, you are welcome to ask make test-verbose # verbose test output to help to identify specific failures |
|
Line 17: | Line 41: |
1. Optionally, activate an existing conda environment, e.g. `source activate eman-env`. Skip this step, if you don't understand this statement. However, if you already use anaconda, you may get package conflicts when you install eman dependencies in the next step. In that case, you need to install eman and its dependencies in its own conda environment. 1. Install dependencies {{{ conda install eman-deps -c cryoem -c defaults -c conda-forge }}} Listing the channels explicitly can be avoided by specifying them in $HOME/.condarc, see conda documentation for more details, https://conda.io/docs/using/index.html. 1. Out-of-source builds are recommended, so work in a directory outside of eman2 source (this is generally true, not EMAN2-specific). Note '''cmake''', not '''--( ccmake )--'''. CMake will automatically find the dependencies. If you want to change any of the CMake values, then use '''cmake-gui''' or '''ccmake'''. {{{ |
=== Anaconda2 === 1. Download and install [[https://www.continuum.io/downloads | Anaconda2]] - make sure you don't get the Python3 version 1. Make sure that you have added anaconda2/bin as the first element in your PATH, and that you do not have LD_LIBRARY_PATH or PYTHONPATH set in your shell. If you need these settings for other software, you can still try to proceed, and hope they do not conflict with Miniconda. Alternatively, you may set up a shell script or alias to make these environment changes on demand when you want to use EMAN2/miniconda. 1. Checkout EMAN2 code from [[https://github.com/cryoem/eman2 | GitHub:cryoem/eman2]]. {{{ cd <some-path-to-keep-eman2-source> git clone https://github.com/cryoem/eman2.git }}} 1. Install dependencies {{{ conda create -n eman-env eman-deps -c cryoem -c defaults -c conda-forge # Mac conda create -n eman-env eman-deps="*"="np18*" -c cryoem -c defaults -c conda-forge # Linux source activate eman-env }}} 1. Note that you will need to run {{{ source activate eman-env }}} once in each shell before being able to run EMAN2 commands. 1. Create a build directory (out-of-source builds are recommended). {{{ |
Line 26: | Line 59: |
cmake <some-path-to-keep-eman2-source> -DENABLE_CONDA=ON make -j # "make" should pick up the number of available processors, make -j4 # but you may specify the number if you like |
cmake -DENABLE_CONDA=ON <path-to-eman2-source> # on linux, also add -DENABLE_OPTIMIZE_MACHINE=ON }}} * If conda is not found in PATH, set CONDA_ROOT to your conda environment directory. It could be the main installation or an environment. This step most likely will be needed only if you use '''cmake-gui'''. * If you set CONDA_ROOT to an environment, make sure to delete any cmake variables that cmake already found, variables like EMAN_INSTALL_PREFIX, EMAN_PREFIX, *_LIBRARY or similar, *_INCLUDE_PATH or similar. * Rerun cmake. 1. Build EMAN2 {{{ make -j |
Line 30: | Line 68: |
}}} | }}} 1. You may also wish to run {{{ make test # if everything passes you are fine, if there are failures, you are welcome to ask make test-verbose # verbose test output to help to identify specific failures }}} |
Anaconda based Build, All Platforms
Note that even with a source build it may be difficult to get this working on systems with very old operating system installs. We normally try to support OS versions 6-7 years old. Please report any problems.
Mac OS X, Linux
There are two approaches you can use for the installation. One uses 'Miniconda' and the other uses full 'Anaconda'. Miniconda is a much smaller (~30 MB) install, provides everything EMAN2 needs, and can be expanded with more packages as you like. Anaconda is a much more complete environment (~300 MB), including useful tools such as the Jupyter notebook, but will require the use of a conda environment to make EMAN2 work properly at present.
Miniconda2
Download and install Miniconda2 - make sure you don't get the Python3 version
- Make sure that you have added miniconda2/bin as the first element in your PATH, and that you do not have LD_LIBRARY_PATH or PYTHONPATH set in your shell. If you need these settings for other software, you can still try to proceed, and hope they do not conflict with Miniconda. Alternatively, you may set up a shell script or alias to make these environment changes on demand when you want to use EMAN2/miniconda.
Checkout EMAN2 code from GitHub:cryoem/eman2.
cd <some-path-to-keep-eman2-source> git clone https://github.com/cryoem/eman2.git
- Install dependencies
conda install eman-deps -c cryoem -c defaults -c conda-forge # Mac OSX conda install eman-deps="*"="np18*" -c cryoem -c defaults -c conda-forge # Linux
- Create a build directory (out-of-source builds are recommended).
cd <build-directory> cmake -DENABLE_CONDA=ON <path-to-eman2-source> # on linux, also add -DENABLE_OPTIMIZE_MACHINE=ON
If conda is not found in PATH, set CONDA_ROOT to your conda environment directory. It could be the main installation or an environment. This step most likely will be needed only if you use cmake-gui.
- If you set CONDA_ROOT to an environment, make sure to delete any cmake variables that cmake already found, variables like EMAN_INSTALL_PREFIX, EMAN_PREFIX, *_LIBRARY or similar, *_INCLUDE_PATH or similar.
- Rerun cmake.
Build EMAN2
make -j make install
- You may also wish to run
make test # if everything passes you are fine, if there are failures, you are welcome to ask make test-verbose # verbose test output to help to identify specific failures
Anaconda2
Download and install Anaconda2 - make sure you don't get the Python3 version
- Make sure that you have added anaconda2/bin as the first element in your PATH, and that you do not have LD_LIBRARY_PATH or PYTHONPATH set in your shell. If you need these settings for other software, you can still try to proceed, and hope they do not conflict with Miniconda. Alternatively, you may set up a shell script or alias to make these environment changes on demand when you want to use EMAN2/miniconda.
Checkout EMAN2 code from GitHub:cryoem/eman2.
cd <some-path-to-keep-eman2-source> git clone https://github.com/cryoem/eman2.git
- Install dependencies
conda create -n eman-env eman-deps -c cryoem -c defaults -c conda-forge # Mac conda create -n eman-env eman-deps="*"="np18*" -c cryoem -c defaults -c conda-forge # Linux source activate eman-env
Note that you will need to run source activate eman-env once in each shell before being able to run EMAN2 commands.
- Create a build directory (out-of-source builds are recommended).
cd <build-directory> cmake -DENABLE_CONDA=ON <path-to-eman2-source> # on linux, also add -DENABLE_OPTIMIZE_MACHINE=ON
If conda is not found in PATH, set CONDA_ROOT to your conda environment directory. It could be the main installation or an environment. This step most likely will be needed only if you use cmake-gui.
- If you set CONDA_ROOT to an environment, make sure to delete any cmake variables that cmake already found, variables like EMAN_INSTALL_PREFIX, EMAN_PREFIX, *_LIBRARY or similar, *_INCLUDE_PATH or similar.
- Rerun cmake.
Build EMAN2
make -j make install
- You may also wish to run
make test # if everything passes you are fine, if there are failures, you are welcome to ask make test-verbose # verbose test output to help to identify specific failures