2.1 – Alternative Installation Instructions

The recommended Anaconda based installation may not work for all users depending on the system and use constraints. The following instructions have worked in the past, but we no longer regularly test them. Use Anaconda/miniconda if you can. If you can’t, start here, and if you still have installation problems, please let us know!

Windows 10 (and likely 7 & 8)
  1. Download Python from https://www.python.org/downloads/
    1. Don’t click on either button at the top of the screen – these are links 32bit versions
    2. Select the latest Python 3.6.x (or the latest 2.7.x version if you prefer) from the table lower on the page
    3. Download the Windows x86-64 executable installer
    4. Double-click the installer
    5. In the install options:
      1. Choose “Install for all users”
      2. Add Python.exe to path
  2. Go to http://www.lfd.uci.edu/~gohlke/pythonlibs/ and download the following packages (use the latest …-cp36- (or 2.7 version in the case of installing with Python 2.7.x) …_amd64 version of each package)
    1. numpy
    2. scipy
    3. opencv
    4. matplotlib
    5. pandas
  3. Open an administrator cmd.exe session
    1. Press the Windows key to bring up start menu (or click on it)
    2. Type in cmd
    3. Right-click on the “command prompt” start menu entry and select Run As Administrator
  4. In the command prompt, type cd c:\Users\hedricklab\Downloads (substitute your username for hedricklab)
  5. Run “pip install xx” where xx is each of the packages downloaded in step 2. Installation order matters slightly, use the order in Step 2 to be safe.
  6. Run “pip install requests” to try and get one more package that might be necessary for Argus, depending on your exact setup
  7. If you see an error like “numpy‑1.11.3+mkl‑cp35‑cp35m‑win_amd64.whl is not a supported wheel on this platform.” or similar try python -m pip install --upgrade pip from the command prompt – this will upgrade pip. After that finishes, try the failed install again.
  8. Keep your command window open and download the _p3 versions of argus_gui, argus, and python-sba:
  9. Unzip the packages and use the Administrator command window from step 3 to run python setup.py install in all three folders
  10. Finally, install argus_gui with easy_install (more reliable for updated packages) : “easy_install argus-gui”
  11. At this point the Argus python environment is fully setup, but Argus also depends on an external program called ffmpeg to handle some video encoding operations.  If you don’t already have ffmpeg installed, please follow these instructions, including the bit about enabling it on the command line: http://www.wikihow.com/Install-FFmpeg-on-Windows
  12. At this point you should have Argus and ffmpeg installed
  13. Start Argus by browsing in Windows Explorer to C:\Python35\Scripts and double-clicking on Argus_win.
  14. If Argus doesn’t start please try the following commands from the cmd.exe terminal:
    1. pip install requests
    2. pip install pyglet==1.3.2

.

For Mac OS 10.12 (Sierra), 10.13 (High Sierra), 10.14 (Mojave) without Anaconda
  1. Install the Homebrew package manager by running the following command in a terminal window:
    • /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
  2. Close your terminal window and let the MacOS App Store apply any updates to Xcode or Command Line Tools
  3. Open a new terminal and run the following commands
    1. brew install python3  (installs the main python environment)
    2. brew install ffmpeg scipy  (installs Python packages required by Argus from homebrew recipes)
    3. pip3 install requests pyglet==1.3.2 opencv-contrib-python==3.4.5.20 (installs Python packages required by Argus from the main Python repository)
    4. pip3 install argus sba==1.6.8pypi argus_gui (installs Argus packages from the main Python repository)
  4. At this point you should have Python and Argus installed. To start Argus, type argus  in your terminal window.
    1. You should see a small window appear with icons for launching each of the 6 main Argus tools.
    2. For an easier way to start Argus (as long as you’ve followed the instructions above!):
      1. open Script Editor from Applications > Utilities
      2. Enter do shell script "/usr/local/bin/argus" 
      3. Save the file
        1. name it Argus
        2. select a location of your choosing
        3. with File Format as type Application
      4. Double-clicking on that new “application” will open the main Argus window
  5. Please contact us if you run into problems so we can help you and refine these instructions!

 

Here's a recipe for installing the latest Argus in Anaconda on MacOS El Capitan (10.11.5), last updated 2018-05-31

This recipe may also be useful for installing on other older MacOS architectures that are no longer well supported by the latest & greatest Python variants.

  1. Download minimal Anaconda, aka miniconda from Continuum. Except in unusual circumstances you’ll want the latest 64bit Python 3.x installer. You can also use the full Anaconda environment though the download is much larger and installs many packages not needed for Argus. If you use the full Anaconda installer, you can jump down to argus installation below.
  2. To install Miniconda, open a Terminal window, and change directories into your downloads folder:
    1. cd ~/Downloads
    2. Then install (you might need to change the text to match what you downloaded).
    3. bash Miniconda3-latest-MacOSX-x86_64.sh 
    4. Agree to the default options
    5. Close that terminal window, and open a new one.
  3. In that window enter the following commands:
    1. conda config --add channels conda-forge (adds the conda-forge package source as the first place to look)
    2. conda install python=3.5 (yes, downgrade python for better compatibility)
    3. conda install matplotlib pandas scipy future decorator Pillow imageio pmw tqdm psutil audioread moviepy opencv pykalman pyglet=1.3.2 requests (installs Python packages required by Argus from the conda and conda-forge repositories)
    4. Try:
      1. python3
      2. import cv2
      3. if you don’t get an error, congrats, opencv is installed and your environment is mostly ready. Quit python with quit(), and go to step 7
      4. If you get an error that ends with something like libopencv_core…dylib, Reason: image not found
        1. Quit python with quit()
        2. conda install openblas=0.2.19
        3. python3
        4. import cv2
        5. if you don’t get an error, congrats, opencv is installed. Quit python with quit()
    5. pip install pygarrayimage texttable (installs Python packages required by Argus from the main Python repository)
    6. Don’t close your terminal window yet!
  4. Download the following three zip archives from the Argus development repository and unzip them if necessary:
    1. argus
    2. python-sba
    3. argus_gui
  5. Use the terminal window to change directories to the downloaded folders,  and then run python3 setup.py install, e.g.
    1. cd ~/Downloads/devangel77b-python-sba-badf3e670bee/
    2. python3 setup.py install
    3. cd ~/Downloads/devangel77b-argus-df9e3c27d8d2/
    4. python3 setup.py install
    5. cd ~/Downloads/kilmoretrout-argus_gui-07b82175f266
    6. python3 setup.py install
  6. At this point if you have not seen any error messages you should have Anaconda and Argus installed.  Close the terminal window, and open a new one. To test the installation, in your terminal window type:
    1. argus and hit enter.
    2. You should see small window appear with icons for launching each of the 6 main Argus tools
    3. Please contact us if you run into problems so we can help you and refine these instructions!

.

Here's a recipe for installing the latest Argus 2.1 in Anaconda on MacOS Sierra (10.12.6), last updated 2017-11-06

Note that as of 2018-06-19 changes to the Tkinter build associated with Anaconda Python 3.5 mean that Argus-clicker is non-functional in Anaconda for all MacOS except 10.11. We suggest you try a homebrew-based install as described in the main install page.

  1. Download minimal Anaconda, aka miniconda from Continuum. Except in unusual circumstances you’ll want the latest 64bit Python 3.x installer. You can also use the full Anaconda environment though the download is much larger and installs many packages not needed for Argus. If you use the full Anaconda installer, you can jump down to argus installation below.
  2. To install Miniconda, open a Terminal window, and change directories into your downloads folder:
    1. cd ~/Downloads
    2. Then install (you might need to change the text to match what you downloaded).
    3. bash Miniconda3-latest-MacOSX-x86_64.sh 
    4. Agree to the default options
    5. Close that terminal window, and open a new one.
  3. In that window enter the following commands:
    1. conda update --all  (this updates all the installed Anaconda packages)
    2. conda config --add channels conda-forge (adds the conda-forge package source as the first place to look)
    3. conda install python=3.5 (yes, downgrade python for better compatibility with opencv)
    4. conda install matplotlib pandas scipy future decorator Pillow imageio pmw tqdm psutil audioread moviepy (installs Python packages required by Argus from the conda and conda-forge repositories)
    5. conda install opencv
    6. Try:
      1. python3
      2. import cv2
      3. if you don’t get an error, congrats, opencv is installed. Quit python with quit(), and go to step 7
      4. If you get an error that ends with something like libopencv_core…dylib, Reason: image not found
        1. Quit python with quit()
        2. conda install openblas=0.2.19
        3. python3
        4. import cv2
        5. if you don’t get an error, congrats, opencv is installed. Quit python with quit()
    7. pip install pykalman pyglet=1.3.2 pygarrayimage texttable requests (installs Python packages required by Argus from the main Python repository)
    8. Don’t close your terminal window yet!
  4. Download the following three zip archives from the Argus development repository:
    1. argus
    2. python-sba
    3. argus_gui
  5. Use the terminal window to change directories to the downloaded folders,  and then run python3 setup.py install, e.g.
    1. cd ~/Downloads/devangel77b-python-sba-badf3e670bee/
    2. python3 setup.py install
    3. cd ~/Downloads/devangel77b-argus-df9e3c27d8d2/
    4. python3 setup.py install
    5. cd ~/Downloads/kilmoretrout-argus_gui-07b82175f266
    6. python3 setup.py install
  6. At this point if you have not seen any error messages you should have Anaconda and Argus installed.  Close the terminal window, and open a new one. To test the installation, in your terminal window type:
    1. argus and hit enter.
    2. You should see small window appear with icons for launching each of the 6 main Argus tools
    3. Please contact us if you run into problems so we can help you and refine these instructions!
Ubuntu 14.04
  1. Install prerequisite packages for OpenCV.  Open terminal and use apt-get to accomplish this:
    1. sudo apt-get update
    2. sudo apt-get upgrade
    3. sudo apt-get install build-essential cmake git pkg-config
      sudo apt-get install libjpeg8-dev libtiff4-dev libjasper-dev libpng12-dev
      sudo apt-get install libavcodec-dev libavformat-dev libswscale-dev libv4l-dev libgtk2.0-dev libatlas-base-dev gfortran
  2. Install Python 3 and pip, then install some basic packages with pip:
    1. sudo apt-get install python3 python3-pip ('python python-pip' in the 2.7.x case)
    2. sudo pip3 install numpy scipy matplotlib (simply 'pip' in the Python 2.7.x case)
  3. Get opencv and opencv_contrib from the following repositories: https://github.com/Itseez/opencvhttps://github.com/itseez/opencv_contrib
  4. Extract them as opencv and opencv_contrib to your home folder.
  5. Run:
    cd ~/opencv
    mkdir build
    cd build
    cmake -D CMAKE_BUILD_TYPE=RELEASE \
    -D CMAKE_INSTALL_PREFIX=/usr/local \
    -D INSTALL_C_EXAMPLES=ON \
    -D INSTALL_PYTHON_EXAMPLES=ON \
    -D OPENCV_EXTRA_MODULES_PATH=~/opencv_contrib/modules \
    -D BUILD_EXAMPLES=ON ..
    sudo make -j4
    sudo make install
  6. Download argus and python-sba, Argus supporting packages:
    https://bitbucket.org/devangel77b/python-sba/get/python-sba_p3.zip
  7. https://bitbucket.org/kilmoretrout/argus_gui/get/argus_gui_p3.zip
    https://bitbucket.org/devangel77b/argus/get/argus_p3.zip
  8. Unpack the zip files and run sudo python3 setup.py install (python2.7): sudo python setup.py install) inside the resulting folders
  9. Finally, install argus-gui with ‘easy_install argus-gui’.
  10. If Argus doesn’t run please try the following two additional commands:
    1. pip install requests
    2. pip install pyglet==1.3.2
.
Ubuntu 16.04 & 18.04

These command-line instructions are designed to facilitate installing Argus in a user-specific Python virtual environment. If you don’t want to do this just skip steps 2 & 3 and run all other steps with sudo. The two Ubuntu versions differ slightly in the details – 16.04 gets Python 3.5, 18.04 gets Python 3.6 but the basic install recipe works in both cases.

  1. As an administrator: sudo apt-get install python3-pip python3-venv python3-tk ffmpeg libatlas3-base
  2. As a user: python3 -m venv ~/argus_env
  3. As a user: source ~/argus_env/bin/activate
  4. As a user or with sudo if skipping steps 2 & 3: pip3 install –upgrade pip
  5. As a user or with sudo if skipping steps 2 & 3: pip3 install opencv-contrib-python
  6. As a user or with sudo if skipping steps 2 & 3: pip3 install numpy pandas python-dateutil pytz matplotlib tornado singledispatch six certifi pyparsing nose pyglet==1.3.2 moviepy decorator imageio tqdm Pmw texttable pygarrayimage audioread psutil scipy pykalman requests
  7. As a user or with sudo if skipping steps 2 & 3: pip3 install argus sba==1.6.8pypi argus_gui
  8. As an administrator & with your specific paths [likely changes in magenta]: sudo cp /home/whatever/argus_env/lib/python3.5/site-packages/argus_gui_version/argus_gui/resources/*so /usr/local/lib/
  9. As an administrator: sudo ldconfig

To start argus from a fresh terminal:

  1. source ~/argus_env/bin/activate
  2. ~/argus_env/bin/Argus

 

Potential Problems and Solutions:

After following all of the directions above, you may still run in to problems.  We have run into many and provide some of our solutions here:

All Platforms:

If your installations seemed to go well, but Argus will not start, starting Argus from within Python may fix the issue, or at least provide more information about what is wrong.  From your command line :

python
import argus_gui as ag

Then open one of the GUI windows with one of the following (capitalization pattern matters):

ag.ClickerGUI()
ag.WandGUI()
ag.syncGUI()
ag.dwarpGUI()
ag.calibrateGUI()
ag.patternsGUI()

And use the GUI as you normally would. That may trigger an additional software installation, or you may see error print back to the command line. If it gives an error, please copy and paste the text of that command window, along with details of your operating system when you contact us.

 

Updating Argus:

The Argus package goes through regular maintenance and bug fixes, and occasional feature updates. 

To update to the most stable version, open your command line or terminal, and enter the following one line at a time:

pip install --upgrade git+https://github.com/kilmoretrout/argus_gui.git

IF you are comfortable on the command line, you can also access test branches available at the GitHub repo by adding @branchname to the end of the git path above e.g.:

pip install --upgrade git+https://github.com/kilmoretrout/argus_gui.git@featureBranch