Skip to content

Commit c85d7fd

Browse files
committed
Install fixed ggplot
Upstream does not merge the fix yhat/ggpy#668
1 parent a797ada commit c85d7fd

File tree

2 files changed

+16
-3
lines changed

2 files changed

+16
-3
lines changed

Dockerfile

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ RUN apt-get install -y libfreetype6-dev && \
127127
RUN pip install ibis-framework && \
128128
pip install mxnet && \
129129
pip install gluonnlp && \
130-
pip install gluoncv && \
130+
pip install gluoncv && \
131131
/tmp/clean-layer.sh
132132

133133
# scikit-learn dependencies
@@ -375,7 +375,7 @@ RUN pip install bcolz && \
375375
pip install allennlp && \
376376
# b/149359379 remove once allennlp 1.0 is released which won't cause a spacy downgrade.
377377
pip install spacy==2.2.3 && python -m spacy download en && python -m spacy download en_core_web_lg && \
378-
apt-get install -y ffmpeg && \
378+
apt-get install -y ffmpeg && \
379379
/tmp/clean-layer.sh
380380

381381
###########
@@ -408,7 +408,8 @@ RUN pip install flashtext && \
408408
pip install tensorflow_hub && \
409409
pip install jieba && \
410410
pip install git+https://github.com/SauceCat/PDPbox && \
411-
pip install ggplot && \
411+
# ggplot is broken and main repo does not merge and release https://github.com/yhat/ggpy/pull/668
412+
pip install https://github.com/hbasria/ggpy/archive/0.11.5.zip && \
412413
pip install cesium && \
413414
pip install rgf_python && \
414415
# b/145404107: latest version force specific version of numpy and torch.

tests/test_ggplot.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import unittest
2+
import os.path
3+
4+
from ggplot import *
5+
6+
class TestGgplot(unittest.TestCase):
7+
8+
def test_plot(self):
9+
p = ggplot(aes(x='mpg'), data=mtcars) + geom_histogram()
10+
p.save("myplot.png")
11+
12+
self.assertTrue(os.path.isfile("myplot.png"))

0 commit comments

Comments
 (0)