OpenPathView / OPV_Tasks

GNU General Public License v3.0
0 stars 2 forks source link

Open Path View Tasks

All needed tasks to stich a panorama and more. Based on the hugin stiching chain.

Requirements

This tasks requireded hugin's libraries and more. We have automated the deployment of these requirements in our Ansible scripts. But you can also deploy the dependencies manually.

Automated deployment with Ansible

Use our playbook and deployment scripts available in OPV_Ansible.

Manually building the environnement

APIs

Install and run the needed APIs :

Host configuration

We will use opv_master, we have DB_Rest and the DirectoryManager on this machine. You might set it in your /etc/hosts file.

Dependencies

You will need to install :

apt-get install imagemagick hugin

Hugin Script Interface (HSI) module

You also need to have the Hugin Script Interface python module. It should be install by default with hugin but migth by install for the wrong version of python. To check it (outside your venv) :

$ python3.5
Python 3.5.2 (default, Nov 17 2016, 17:05:23)
[GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import hsi

If you don't have it ... dam you are about to recompile hugin ! To wrap your HSI in the good python version, follow the instructions here.

If you have it installed on your system, you need to add it to your python virtual env, the easiest way to do so his to make a symbolic link from your system dist-packages/hsi.py module to venv dist-packages. Follow this :

(global) $ python3.5 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))"  # get you global dist-package path
/usr/lib/python3/dist-packages
(venv) $ python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))"  # get you venv dist-package path
/home/benjamin/Documents/OpenPathView/code/OPV_Tasks/.venv/OPV_Tasks/lib/python3.5/site-packages
(vent) $ ln -s /usr/lib/python3/dist-packages/hsi.py /home/benjamin/Documents/OpenPathView/code/OPV_Tasks/.venv/OPV_Tasks/lib/python3.5/site-packages/ # make symbolic link
(vent) $ ln -s /usr/lib/python3/dist-packages/_hsi.so /home/benjamin/Documents/OpenPathView/code/OPV_Tasks/.venv/OPV_Tasks/lib/python3.5/site-packages/ # make symbolic link

Install

cd OPV_Tasks
python setup.py install

Using opv-task

You migth need some data to play with it, use OPV_importdata to import our test set.

# Get the help
opv-task -h
# Stitch a panorama lot 130 / id malette 15
opv-task makeall '{"id_lot": 130, "id_malette": 15 }' --db-rest=http://opv_master:5000 --dir-manager=http://opv_master:5005

License

Copyright (C) 2017 Open Path View, Maison Du Libre
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License along
with this program. If not, see http://www.gnu.org/licenses/.