- Windows users only: install Windows Subsystem for Linux to get access to a Unix-like terminal.
- Install Python 3.9 from the official website or from your package manager.
- Download AMFinder sources from Github, and extract the archive.
- Move to the
amf
folder. - Open a terminal, run
export PYTHON=<path>
, replacing<path>
with the path to Python 3.9. - Run
./install.sh
. If needed, add executable permissions with:chmod +x install.sh
. Should the variablePYTHON
not be set, the script will use the output ofwhich python3
instead.
Important: Before using amf
for training or prediction (see next section), you will need to activate its Python virtual environment. To that end, open a terminal in the amf
directory and run the command source amfenv/bin/activate
to activate the virtual environment. Your terminal prompt will change to (amfenv) $
. Once you are done with amf
, you can deactivate the environment by running the command deactivate
.
Note: old processors may lack AVX and AVX2 processor instructions and may fail to run Tensorflow. If you encounter such error, you need to download and build Tensorflow from sources. Instructions can be found on the Tensorflow website.
Note: As a graphical interface, amfbrowser
cannot be installed on a
text-based system such as an HPC. Ready-to-use binaries are available. Windows
users can use the linux version once Windows Subsystem for Linux
(WSL) has been
activated.
-
Download and install OPAM from the official webwsite or from your package manager.
-
Open a terminal in the
amfbrowser
folder and run the command:export OPAM=<path>
, replacing<path>
with the path to the opam program. Then, run the command./install.sh
to installamfbrowser
dependencies and compileamfbrowser.exe
. Should the variableOPAM
not be set, the script will use the output ofwhich opam
. If needed, add executable permissions to the installation file with:chmod +x install.sh
. Follow the instructions on the screen and reply yes to the questions asked during opam installation and configuration.
Note: You may need to install development packages such as libgtk2.0-dev
and libgtksourceview2.0-dev
. Users with miniconda or similar tool suite installed may encounter problems if their PATH
variable has been altered. You may have to temporarily mask miniconda directory from your PATH
variable by running PATH=<modified_path> opam install ...
.
Same as Linux, but you will need Homebrew to install OPAM.
amfbrowser
can be installed and run on Windows 10 after activation of
Windows Subsystem for Linux (WSL).
-
Activate Windows Subsystem for Linux (WSL). Then, go to Windows App store and install a Linux distribution (Ubuntu and Debian are recommended, but others should work too).
-
Install an OCaml build system based on the
brew
package manager:
$ sudo apt update
$ sudo apt upgrade
$ sudo apt autoclean
$ sudo apt install curl build-essential git
$ sh -c "$(curl -fsSL https://raw.githubusercontent.com/Linuxbrew/install/master/install.sh)"
$ test -d ~/.linuxbrew && eval $(~/.linuxbrew/bin/brew shellenv)
$ test -d /home/linuxbrew/.linuxbrew && eval $(/home/linuxbrew/.linuxbrew/bin/brew shellenv)
$ test -r ~/.bash_profile && echo "eval \$($(brew --prefix)/bin/brew shellenv)" >> ~/.bash_profile
$ echo "eval \$($(brew --prefix)/bin/brew shellenv)" >> ~/.profile
$ brew install gpatch opam gtk+ cairo
-
Follow the Linux installation instructions. You may have to edit the file
install.sh
with a text editor and uncomment the option--disable-sandboxing
. -
Install a X server (for instance, Xming) and configure
bash
to tell GUIs to use the local X server by runningexport DISPLAY=localhost:0.0
. This variable has to be set for each session. As an alternative, you can save the variable in your session configuration file by running:echo "export DISPLAY=localhost:0.0" >> ~/.bashrc
and reload the configuration (. ~/.bashrc
). The new variable with then be automatically set and does not have to be redefined manually.