|
|
# Setup
|
|
|
## Table of Contents
|
|
|
1.[Introduction](manual#introduction)
|
|
|
|
|
|
2.[Setup](manual-setup)
|
|
|
1.[Setup](manual-setup)
|
|
|
- [General setup](manual-setup#general-setup)
|
|
|
- [Installation instructions](manual-setup#installation-instructions)
|
|
|
- [Python, pip and Qt](manual-setup#python-pip-and-qt)
|
|
|
- [Requirements](manual-setup#requirements)
|
|
|
- [Caffe](manual-setup#caffe)
|
|
|
- [Launching Barista](manual-setup#launching-barista)
|
|
|
- [Caffe Path Request](manual-setup#caffe-path-request)
|
|
|
- [Configure Caffe Root](manual-setup#configure-caffe-root)
|
|
|
- [Caffe Path Configuration](manual-setup#caffe-path-configuration)
|
|
|
- [Per-Project Caffe Path](manual-setup#per-project-caffe-path)
|
|
|
- [Caffe Root for Precompiled Packages](manual-setup#caffe-root-for-precompiled-packages)
|
|
|
|
|
|
3.[Overview](manual-overview)
|
|
|
2.[Overview](manual-overview)
|
|
|
|
|
|
4.[Network creation](manual-network)
|
|
|
3.[Network creation](manual-network)
|
|
|
|
|
|
5.[Network training](manual-training)
|
|
|
4.[Network training](manual-training)
|
|
|
|
|
|
6.[Miscellaneous](manual-miscellaneous)
|
|
|
5.[Miscellaneous](manual-miscellaneous)
|
|
|
|
|
|
|
|
|
## General Setup
|
|
|
- MainProgrammingLanguage: Python (2.x)
|
|
|
- GUI: PyQt 5.x
|
|
|
- Deep-Learning-Framework: Caffe
|
|
|
- OS: **Linux** (other operation systems might work, but aren't tested intensively)
|
|
|
- If you still want to install Caffe on **MacOS** follow this guide: http://installing-caffe-the-right-way.wikidot.com/start **Attention:** CUDA 9 is not compatible with XCode 9 at this moment so you have to use an older XCode version (e.g. 8.3.3)
|
|
|
- OS: **Linux** (**MacOS** and **Windows** support is experimental.)
|
|
|
|
|
|
**Note for MacOS X**: If you still want to install Caffe on MacOS follow this guide: http://installing-caffe-the-right-way.wikidot.com/start **Attention:** CUDA 9 is not compatible with XCode 9 at the time of writing so you have to use an older XCode version (e.g. 8.3.3). If you have problems with tcmalloc-Error when running Barista, try to disable leveldb-support in makefile.config in caffe root folder:
|
|
|
USE_LEVELDB := 0.
|
|
|
Please also notice the known bug when having qtmultimedia installed (see [here](manual-miscellaneous))
|
|
|
|
|
|
|
|
|
## Installation Instructions
|
|
|
Note that, this tutorial is aimed to describe an installation on Ubuntu 16.04 x86. However, it should be adoptable to further operation systems quite intuitively.
|
|
|
Note: this tutorial is aimed to describe an installation on Ubuntu 16.04 x86. The installation process on other operating systems may differ in some points (especially usage of the system package manager, in this case `apt-get`).
|
|
|
|
|
|
### Python, pip and Qt
|
|
|
Barista is written in Python 2. So first of all, install Python and the package manager pip, which is needed to install other Python modules:
|
|
|
Barista is written in Python 2. So first of all install Python and the (python) package manager pip, which is needed to install other Python modules:
|
|
|
|
|
|
`$ sudo apt-get install python python-pip`
|
|
|
`$ sudo apt-get install python python-pip`
|
|
|
|
|
|
|
|
|
PyQt is needed for Baristas GUI. To install it, run:
|
|
|
|
|
|
`$ sudo aptitude install python-pyqt5 qt5-default`
|
|
|
`$ sudo apt-get install python-pyqt5 qt5-default`
|
|
|
|
|
|
## Requirements
|
|
|
There are a number of Python modules that need to be installed in order to run Barista. All of them can be easily installed by using the requirements file which is located in the Barista root Folder. The command to install all requirements is as follows:
|
... | ... | @@ -49,27 +51,27 @@ There are a number of Python modules that need to be installed in order to run B |
|
|
`$ pip install -r /path/to/requirements.txt`
|
|
|
|
|
|
### Caffe
|
|
|
Of course, you need a working installation of caffe. For a detailed description see [the official website](http://caffe.berkeleyvision.org/installation.html).
|
|
|
Of course, you need a working installation of caffe. For a detailed description see [the official website](http://caffe.berkeleyvision.org/installation.html). Although there is now an apt package available for Ubuntu >= 17.04, it is advisable to download and **build** the most current version **from source**.
|
|
|
|
|
|
## Launching Barista
|
|
|
Finally, you can run Barista from its root directory by using the main.py:
|
|
|
|
|
|
`$ python main.py`
|
|
|
|
|
|
## Caffe Path Request
|
|
|
On your first start of Barista, it will ask you to add a valid Caffe path. The following window will open and with a click on the file-button in the right bottom corner you will be able to select a Caffe path from your working directory.
|
|
|
## Caffe Path Configuration
|
|
|
On your first start of Barista, it will ask you to add a valid Caffe path (i.e., the path to a local checkout of the caffe repository, in the following referred to as the **Caffe Path**). The following window will open and with a click on the file-button in the right bottom corner you will be able to select a Caffe path from your working directory.
|
|
|
|
|
|
![Screenshot_from_2017-11-23_13-31-43](/uploads/95ab4f541191ded76e79d856032caeaa/Screenshot_from_2017-11-23_13-31-43.png)
|
|
|
|
|
|
After you have done this, select "Save and start Barista" and Barista saves the given path, so you won't have to set it again the next time you start the program.
|
|
|
The window to select or create a new project will open right away.
|
|
|
|
|
|
## Configure Caffe Root
|
|
|
There are two existing Caffe root paths that can be used. One is saved in Baristas settings, the other is saved in the projects settings. For both paths, the default setting is to save nothing. The Caffe paths can be changed by using the entry "Settings -> Change Caffe Path" in the menu bar. If the Caffe Project path exists, it is used for training. If it does not exists, the default path form the settings is used. After changing the path, the program needs to be restarted.
|
|
|
## Per-project Caffe Path
|
|
|
There are two existing Caffe paths that can be used. One is saved globally in Baristas settings, while the other is saved per project. An empty per-project path (which is the default) makes Barista use the global setting. Both Caffe paths (global and the path of the current project) can be changed by using the entry "Settings -> Change Caffe Path" in the menu bar. After changing a path, Barista (currently) needs to be restarted.
|
|
|
|
|
|
## Caffe Root for Precompiled Packages
|
|
|
Some distributions conveniently offer precompiled packages for caffe.
|
|
|
Unfortunately, Barista currently still requires a "caffe root" path.
|
|
|
Although it is advised to clone the latest version of caffe and building it locally, Barista can use precompiled versions of caffe with some additional work.
|
|
|
Using symbolic links, we can create a dummy "caffe root" folder structure that resembles that of a source folder, but only contains the paths required by Barista.
|
|
|
The tree structure of such a folder should look as follows:
|
|
|
|
... | ... | |