File size: 3,068 Bytes
faeda5e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
Perceiving Systems Mesh Package
===============================

This package contains core functions for manipulating meshes and visualizing them.
It requires ``Python 3.5+`` and is supported on Linux and macOS operating systems.

The ``Mesh`` processing libraries support several of our projects such as
* [CoMA: Convolutional Mesh Encoders for Generating 3D Faces](http://coma.is.tue.mpg.de/)
* [FLAME: Learning a model of facial shape and expression from 4D scans](http://flame.is.tue.mpg.de/)
* [MANO: Modeling and Capturing Hands and Bodies Together](http://mano.is.tue.mpg.de/)
* [SMPL: A Skinned Multi-Person Linear Model](http://smpl.is.tue.mpg.de/)
* [VOCA: Voice Operated Character Animation](https://github.com/TimoBolkart/voca)
* [RingNet: 3D Face Shape and Expression Reconstruction from an Image](https://github.com/soubhiksanyal/RingNet)

Requirements
------------

You first need to install the `Boost <http://www.boost.org>`_ libraries.
You can compile your own local version. 

On Windows/MSVC, you must download and compile it yourself.

On Linux you can simply install it via:

```
$ sudo apt-get install libboost-dev
```

On macOS:

```
$ brew install boost
```

Installation
------------

First, create a dedicated Python virtual environment and activate it:

```
$ python3 -m venv --copies my_venv
$ source my_venv/bin/activate
```

#### Linux/MacOS
You should then compile and install the ``psbody-mesh`` package using the Makefile.
If you are using the system-wide ``Boost`` libraries:

```
$ make all
```

or the libraries locally installed:

```
$ BOOST_ROOT=/path/to/boost/libraries make all
```

#### Windows 
Since Makefile and the linux commands in it does not work on Windows, run the command below instead:
(remember to replace <path_to_your_boost> with your path to boost)
```
pip install --no-deps --install-option="--boost-location=<path_to_your_boost>" --verbose --no-cache-dir .
```

Note on MeshViewer: Windows users need a special version of PyOpenGL to use the MeshViewer, because the one automatically installed via PYPI does not include the required DLL.

please download the unofficial PyOpenGL wheel file from [here](https://www.lfd.uci.edu/~gohlke/pythonlibs/#pyopengl), uninstall the original version and install the new one by commands below:

```
pip uninstall pyOpenGL
pip install <the-name-of-your-wheel-file>
```

Testing
-------

To run the tests, simply do:

#### Linux/MacOS

```
$ make tests
```

#### Windows 

```
python -m unittest -v
```

Documentation
-------------

A detailed documentation can be compiled using the Makefile:

```
$ make documentation
```

License
-------
Please refer for LICENSE.txt for using this software. The software is compiled using CGAL sources following the license in CGAL_LICENSE.pdf

Acknowledgments
---------------

We thank the external contribution from the following people:
* [Kenneth Chaney](https://github.com/k-chaney)  ([PR #5](https://github.com/MPI-IS/mesh/pull/5))
* [Dávid Komorowicz](https://github.com/Dawars) ([PR #8](https://github.com/MPI-IS/mesh/pull/8))