Commit a2961b74 authored by Tiago de Freitas Pereira's avatar Tiago de Freitas Pereira
Browse files

Preparing deploy

parent b7a395c5
Pipeline #4061 failed with stage
in 9 minutes and 37 seconds
# This build file heavily uses template features from YAML so it is generic
# enough for any Bob project. Don't modify it unless you know what you're
# doing.
# Definition of our build pipeline
stages:
- build
- test
- docs
- wheels
- deploy
# ---------
# Templates
# ---------
# Template for the build stage
# Needs to run on all supported architectures, platforms and python versions
.build_template: &build_job
stage: build
before_script:
- git clean -ffdx
- mkdir _ci
- curl --silent "https://gitlab.idiap.ch/bob/bob.admin/raw/master/gitlab/install.sh" > _ci/install.sh
- chmod 755 _ci/install.sh
- ./_ci/install.sh _ci #updates
- ./_ci/before_build.sh
script:
- ./_ci/build.sh
after_script:
- ./_ci/after_build.sh
artifacts:
expire_in: 1 week
paths:
- _ci/
- dist/
- sphinx/
# Template for the test stage - re-installs from uploaded wheels
# Needs to run on all supported architectures, platforms and python versions
.test_template: &test_job
stage: test
before_script:
- ./_ci/install.sh _ci #updates
- ./_ci/before_test.sh
script:
- ./_ci/test.sh
after_script:
- ./_ci/after_test.sh
# Template for the wheel uploading stage
# Needs to run against one supported architecture, platform and python version
.wheels_template: &wheels_job
stage: wheels
environment: intranet
only:
- master
- /^v\d+\.\d+\.\d+([abc]\d*)?$/ # PEP-440 compliant version (tags)
before_script:
- ./_ci/install.sh _ci #updates
- ./_ci/before_wheels.sh
script:
- ./_ci/wheels.sh
after_script:
- ./_ci/after_wheels.sh
# Template for (latest) documentation upload stage
# Only one real job needs to do this
.docs_template: &docs_job
stage: docs
environment: intranet
only:
- master
before_script:
- ./_ci/install.sh _ci #updates
- ./_ci/before_docs.sh
script:
- ./_ci/docs.sh
after_script:
- ./_ci/after_docs.sh
# Template for the deployment stage - re-installs from uploaded wheels
# Needs to run on a single architecture only
# Will deploy your package to PyPI and other required services
# Only runs for tags
.deploy_template: &deploy_job
stage: deploy
environment: internet
only:
- /^v\d+\.\d+\.\d+([abc]\d*)?$/ # PEP-440 compliant version (tags)
except:
- branches
before_script:
- ./_ci/install.sh _ci #updates
- ./_ci/before_deploy.sh
script:
- ./_ci/deploy.sh
after_script:
- ./_ci/after_deploy.sh
# -------------
# Build Targets
# -------------
# Linux + Python 2.7: Builds, tests, uploads wheel and deploys (if needed)
build_linux_27:
<<: *build_job
variables: &linux_27_build_variables
PYTHON_VERSION: "2.7"
WHEEL_TAG: "py27"
tags:
- conda-linux
test_linux_27:
<<: *test_job
variables: *linux_27_build_variables
dependencies:
- build_linux_27
tags:
- conda-linux
wheels_linux_27:
<<: *wheels_job
variables: *linux_27_build_variables
dependencies:
- build_linux_27
tags:
- conda-linux
deploy_linux_27:
<<: *deploy_job
variables: *linux_27_build_variables
dependencies:
- build_linux_27
tags:
- conda-linux
# Linux + Python 3.4: Builds and tests
build_linux_34:
<<: *build_job
variables: &linux_34_build_variables
PYTHON_VERSION: "3.4"
WHEEL_TAG: "py3"
tags:
- conda-linux
test_linux_34:
<<: *test_job
variables: *linux_34_build_variables
dependencies:
- build_linux_34
tags:
- conda-linux
# Linux + Python 3.5: Builds, tests and uploads wheel
build_linux_35:
<<: *build_job
variables: &linux_35_build_variables
PYTHON_VERSION: "3.5"
WHEEL_TAG: "py3"
tags:
- conda-linux
test_linux_35:
<<: *test_job
variables: *linux_35_build_variables
dependencies:
- build_linux_35
tags:
- conda-linux
wheels_linux_35:
<<: *wheels_job
variables: *linux_35_build_variables
dependencies:
- build_linux_35
tags:
- conda-linux
docs_linux_35:
<<: *docs_job
variables: *linux_35_build_variables
dependencies:
- build_linux_35
tags:
- conda-linux
# Mac OSX + Python 2.7: Builds and tests
build_macosx_27:
<<: *build_job
variables: &macosx_27_build_variables
PYTHON_VERSION: "2.7"
WHEEL_TAG: "py27"
tags:
- conda-macosx
test_macosx_27:
<<: *test_job
variables: *macosx_27_build_variables
dependencies:
- build_macosx_27
tags:
- conda-macosx
# Mac OSX + Python 3.4: Builds and tests
build_macosx_34:
<<: *build_job
variables: &macosx_34_build_variables
PYTHON_VERSION: "3.4"
WHEEL_TAG: "py3"
tags:
- conda-macosx
test_macosx_34:
<<: *test_job
variables: *macosx_34_build_variables
dependencies:
- build_macosx_34
tags:
- conda-macosx
# Mac OSX + Python 3.5: Builds and tests
build_macosx_35:
<<: *build_job
variables: &macosx_35_build_variables
PYTHON_VERSION: "3.5"
WHEEL_TAG: "py3"
tags:
- conda-macosx
test_macosx_35:
<<: *test_job
variables: *macosx_35_build_variables
dependencies:
- build_macosx_35
tags:
- conda-macosx
language: python
env:
global:
- secure: MTnYx1wJLTvPLBpY4O2Ia8P7RDXA7ICqqCUA6PsE03pSBzhtgXHm41/klnj96FB9EWIHcz4jWjPplgPBeVs+VCyn0NJberi/DVQsSs3KcVroKykVxIduWbvjbmx29QE3Id8RpPOuOr8pmBzeFVzwu7c2vthGjl7H9eJfKU1BphI=
- secure: MwVYyHzysBxqcaHroOIv09T/ufww8pLG2ZIYGbFEfj4gumPpOIGcn0mFjnFqyQZykK2Epv3Yy0q6ChunhJuIYCv9jpGbMg5oBwV5KnMeyxXeB8EqcRsP+XSEn6Q+TXfZV0K/pjoBEM9uktJWS6EYFjTIEU0eZPgzsxmXrAG/UBI=
- BOB_UPLOAD_WHEEL=1
matrix:
include:
- python: 2.7
env:
- BOB_DOCUMENTATION_SERVER=https://www.idiap.ch/software/bob/docs/latest/bioidiap/%s/master
- python: 3.3
- python: 3.4
- python: 3.5
before_install:
- sudo add-apt-repository -y ppa:biometrics/bob
- sudo apt-get update -qq
- sudo apt-get install -qq --force-yes wget git-core pkg-config cmake python-dev python-support liblapack-dev libatlas-base-dev libblitz1-dev libavformat-dev libavcodec-dev libswscale-dev libboost-all-dev libmatio-dev libjpeg8-dev libnetpbm10-dev libpng12-dev libtiff4-dev libgif-dev libhdf5-serial-dev libfftw3-dev texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended libsvm-dev libvl-dev dvipng python-numpy python-scipy dvipng libopencv-dev gfortran libsox-dev
- pip install --find-links https://www.idiap.ch/software/bob/wheels/travis/ --egg --use-wheel sphinx nose numpy matplotlib coverage cpp-coveralls scipy nose-exclude
- pip install --find-links https://www.idiap.ch/software/bob/wheels/travis/ --egg --use-wheel --pre -r requirements.txt coveralls
install:
- python bootstrap-buildout.py
- CPPFLAGS=--coverage LDFLAGS=--coverage ./bin/buildout buildout:debug=false buildout:develop=. buildout:extensions=bob.buildout buildout:auto-checkout=
script:
#- ./bin/python -c 'import pkg_resources; from bob.utils import get_config; print(get_config())'
- ./bin/coverage run --source=bob ./bin/nosetests bob bob.ip bob.learn.activation bob.learn.mlp bob.learn.libsvm bob.learn.linear bob.learn.em bob.io bob.blitz bob.ap bob.core bob.math bob.sp bob.measure -sv --first-package-wins
#- ./bin/sphinx-build -b doctest doc sphinx
- ./bin/sphinx-build -b html doc sphinx
after_success:
#- cpp-coveralls --build-root=`pwd` --exclude=src --exclude-pattern=".*Compiler.*" --dump=cpp_cov.json
#- coveralls --merge=cpp_cov.json
- wget https://raw.githubusercontent.com/bioidiap/bob.extension/master/scripts/upload-{sphinx,wheel}.sh
- chmod a+x upload-sphinx.sh upload-wheel.sh
- ./upload-sphinx.sh
- ./upload-wheel.sh
......@@ -6,11 +6,11 @@
.. image:: http://img.shields.io/badge/docs-stable-yellow.png
:target: http://pythonhosted.org/bob/index.html
.. image:: http://img.shields.io/badge/docs-latest-orange.png
:target: https://www.idiap.ch/software/bob/docs/latest/idiap/bob/master/index.html
.. image:: https://travis-ci.org/bioidiap/bob.learn.em.svg?branch=master
:target: https://travis-ci.org/idiap/bob?branch=master
.. image:: https://img.shields.io/badge/github-master-0000c0.png
:target: https://github.com/idiap/bob/tree/master
:target: https://www.idiap.ch/software/bob/docs/latest/bob/bob/master/index.html
.. image:: https://gitlab.idiap.ch/bob/bob/badges/master/build.svg
:target: https://gitlab.idiap.ch/bob/bob/commits/master
.. image:: https://img.shields.io/badge/gitlab-project-0000c0.svg
:target: https://gitlab.idiap.ch/bob/bob/commits/master
.. image:: http://img.shields.io/pypi/v/bob.png
:target: https://pypi.python.org/pypi/bob
.. image:: http://img.shields.io/pypi/dm/bob.png
......@@ -28,86 +28,16 @@ both efficient and reduce development time. It is composed of a reasonably
large number of `packages`_ that implement tools for image, audio & video
processing, machine learning and pattern recognition.
If just want to use Bob's functionalities on your experiments, you are **not**
supposed to install this package on your machine, but rather `create your own
personalised work environment
<https://github.com/idiap/bob/wiki/Installation>`_ depending on your needs, by
collecting individual sub-packages based on your requirements.
If you are developing Bob packages which are supposed to built along side our
`nightly build system <https://www.idiap.ch/software/bob/buildbot/waterfall>`_,
please read on.
Installation
------------
.. note::
If you are reading this page through our GitHub portal and not through PyPI,
note **the development tip of the package may not be stable** or become
unstable in a matter of moments.
Go to `http://pypi.python.org/pypi/bob
<http://pypi.python.org/pypi/bob>`_ to download the latest
stable version of this package.
There are 2 options you can follow to get this package installed and
operational on your computer: you can use automatic installers like `pip
<http://pypi.python.org/pypi/pip/>`_ (or `easy_install
<http://pypi.python.org/pypi/setuptools>`_) or manually download, unpack and
use `zc.buildout <http://pypi.python.org/pypi/zc.buildout>`_ to create a
virtual work environment just for this package.
Using an automatic installer
============================
Using ``pip`` is the easiest (shell commands are marked with a ``$`` signal)::
$ pip install bob
You can also do the same with ``easy_install``::
$ easy_install bob
This will download and install this package plus any other required
dependencies. It will also verify if the version of Bob you have installed
is compatible.
This scheme works well with virtual environments by `virtualenv
<http://pypi.python.org/pypi/virtualenv>`_ or if you have root access to your
machine. Otherwise, we recommend you use the next option.
Using ``zc.buildout``
=====================
Follow our `installation`_ instructions. Then, using the Python interpreter
provided by the distribution, bootstrap and buildout this package::
Download the latest version of this package from `PyPI
<http://pypi.python.org/pypi/bob>`_ and unpack it in your
working area. The installation of the toolkit itself uses `buildout
<http://www.buildout.org/>`_. You don't need to understand its inner workings
to use this package. Here is a recipe to get you started::
$ python bootstrap-buildout.py
$ ./bin/buildout
These 2 commands should download and install all non-installed dependencies and
get you a fully operational test and development environment.
.. note::
As per-usual, make sure all external `dependencies`_ are installed on your host
before trying to compile the whole of Bob.
Documentation
-------------
You can generate the documentation for all packages in this container, after
installation, using Sphinx::
$ ./bin/sphinx-build . sphinx
This shall place in the directory ``sphinx``, the current version for the
documentation of the package.
For the maintainers
-------------------
......@@ -125,17 +55,14 @@ Adding a dependency package
* contains a README clearly indicating how to install the package (including
external dependencies required). Also, please add package badges for the
build status and coverage as shown in other packages (even if your package
is not yet integrated to Travis or Coveralls).
build status and coverage as shown in other packages.
* Has unit tests.
* Is integrated with Travis-CI, and correctly tests on that platform (i.e.
* Is integrated with Gitlab-CI and correctly tests on that platform (i.e.
it builds, it tests fine and a documentation can be constructed and tested
w/o errors)
* Is integrated with Coveralls for reporting test coverage
If you don't know how to do this, ask for information on the bob-devel
mailing list.
......@@ -145,14 +72,14 @@ Updating the dependencies
If you want to update the version of the dependency packages, run the following commands::
$ ./bin/get_versions.py > requirements.txt
$ ./bin/python ./bob/script/get_versions.py > requirements.txt
$ git commit requirements.txt -m "Update requeriments" && git push
Removing a dependency package
=============================
To remove a package on bob, just append the package name in the file ('requirements.txt').
To remove a package on bob, just remove the package name in the file ('requirements.txt').
.. External References
......@@ -164,4 +91,5 @@ Removing a dependency package
.. _wiki: https://github.com/idiap/bob/wiki
.. _bug tracker: https://github.com/idiap/bob/issues
.. _dependencies: https://github.com/idiap/bob/wiki/Dependencies
.. _installation: https://gitlab.idiap.ch/bob/bob/wikis/Installation
bob.extension == 2.2.1
bob.blitz == 2.0.9
bob.core == 2.1.3
bob.io.base == 2.0.10
bob.sp == 2.0.5
bob.ap == 2.0.5
bob.math == 2.0.4
bob.measure == 2.1.2
bob.db.base == 2.0.6
bob.io.audio == 2.0.1
bob.io.image == 2.1.1
bob.io.video == 2.0.10
bob.io.matlab == 2.0.5
bob.ip.base == 2.0.10
bob.ip.color == 2.0.5
bob.ip.draw == 2.0.4
bob.ip.gabor == 2.0.5
bob.learn.activation == 2.0.5
bob.learn.libsvm == 2.0.6
bob.learn.linear == 2.0.8
bob.learn.mlp == 2.1
bob.learn.em == 2.0.9
bob.learn.boosting == 2.0.7
bob.blitz == 2.0.10
bob.core == 2.1.4
bob.io.base == 2.0.11
bob.sp == 2.0.6
bob.ap == 2.1
bob.math == 2.0.5
bob.measure == 2.1.3
bob.db.base == 2.1
bob.io.audio == 2.0.2
bob.io.image == 2.1.3
bob.io.video == 2.0.11
bob.io.matlab == 2.0.6
bob.ip.base == 2.0.12
bob.ip.color == 2.0.6
bob.ip.draw == 2.0.5
bob.ip.gabor == 2.0.6
bob.learn.activation == 2.0.6
bob.learn.libsvm == 2.0.8
bob.learn.linear == 2.0.9
bob.learn.mlp == 2.1.2
bob.learn.em == 2.0.10
bob.learn.boosting == 2.0.9
bob.db.verification.utils == 2.0.8
bob.db.iris == 2.0.4
bob.db.wine == 2.0.4
bob.db.mnist == 2.0.4
bob.db.atnt == 2.0.4
bob.ip.facedetect == 2.0.8
bob.ip.optflow.hornschunck == 2.0.7
bob.ip.optflow.liu == 2.0.6
bob.db.iris == 2.0.6
bob.db.wine == 2.0.6
bob.db.mnist == 2.0.6
bob.db.atnt == 2.0.6
bob.ip.facedetect == 2.0.10
bob.ip.optflow.hornschunck == 2.0.9
bob.ip.optflow.liu == 2.0.8
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment