ppwwyyxx / speaker-recognition

A Speaker Recognition System
Apache License 2.0
675 stars 276 forks source link

Dockerfile to build speaker-recognition easily #28

Closed qacollective closed 7 years ago

qacollective commented 7 years ago

This helps build a self contained image containing the speaker-recognition solution that can then be instantiated into a running container in seconds. Containers can be either persistent or throw-away. I did this while setting up my own environment containing your software, so I hope this helps you or the users of this project in the future.

There is more help inside the Dockerfile itself.

ppwwyyxx commented 7 years ago

Thanks a lot!

hudsantos commented 7 years ago

I've try to build this image. Awesome! Worked fine. Here goes my suggestions: We are gonna need to inform users to install tzdata before. Otherwise:

dpkg-query: package 'tzdata' is not installed and no information is available
Use dpkg --info (= dpkg-deb --info) to examine archive files,
and dpkg --contents (= dpkg-deb --contents) to list their contents.
/usr/sbin/dpkg-reconfigure: tzdata is not installed
The command '/bin/sh -c rm /etc/localtime && echo "Australia/Sydney" > /etc/timezone && dpkg-reconfigure -f noninteractive tzdata' returned a non-zero code: 1

So: RUN apt-get install -y tzdata I also didn't get this filename: __etc__apt__sources.list It is important? The problem during build:

Step 3/11 : COPY __etc__apt__sources.list /etc/apt/sources.list
lstat __etc__apt__sources.list: no such file or directory

Another issue: ImportError: No module named scipy.linalg So, before pip install scipy, we need to: apt-get install python-scipy In my case I've commented both lines (RUN one and COPY one), added python-scipy together with nano and sudo on apt-get install -y command, and build worked fine. It's also interesting to add command line on how to build, in the same directory of Dockerfile: $ docker build -t <docker-hub-username>/<image-name> . ** Note the dot "." at the end of the line. That is very important.

hudsantos commented 7 years ago

I am preparing to pull request this changes ok? In a few hours I am going to do that.