enthought / enthought/mayavi

Figures upside-down in headless mode

Open
#94 2 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Python
Stars
1.4k
Forks
316
Avg merge
7h 44m
Merged PRs (30d)
5

Description

When I use mayavi 4.3.0 (Enthought Canopy) in headless mode, figures saved using `mayavi.mlab.savefig` are upside-down. E.g.:

```
import numpy
from mayavi.mlab import *
s = numpy.abs(numpy.random.random((3, 3)))
barchart(s)
savefig('test.png')
```

if saved as "test.py" and running it using

```
python test.py
```

gives the correct figure

![test_ok](https://f.cloud.github.com/assets/647005/1748671/af19bd92-64d4-11e3-8aca-33f50893633b.png)

However, if I use

```
DISPLAY=:1 xvfb-run -f /tmp/xauthority-tmp --auto-servernum \
-s "-screen 0 1280x1024x24 -noreset" python test.py
```

the figure is upside-down:

![test_canopy](https://f.cloud.github.com/assets/647005/1748676/eb8cc42c-64d4-11e3-8e97-1c139c2439e2.png)

The figures are not upside-down when I use mayavi 4.2.0 shipped with EPD-7.3.1, so it seems to be a problem with either mayavi or VTK.

CC @agramfort @dengemann @Eric89GXL

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.