-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathDockerfile-train
54 lines (40 loc) · 1.7 KB
/
Dockerfile-train
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
FROM ubuntu:latest
RUN apt-get update && apt-get install -y --no-install-recommends \
apt-utils wget unzip build-essential cmake pkg-config \
libjpeg-dev libtiff5-dev libjasper-dev libpng12-dev \
libavcodec-dev libavformat-dev libswscale-dev libv4l-dev \
libxvidcore-dev libx264-dev \
libgtk2.0-dev libgtk-3-dev \
libatlas-base-dev gfortran \
python3-dev python3-pip python-pip python3-h5py \
python3-numpy python3-matplotlib python3-scipy python3-pandas
WORKDIR foocars
COPY . .
# https://github.com/samjabrahams/tensorflow-on-raspberry-pi/releases
#RUN wget https://github.com/samjabrahams/tensorflow-on-raspberry-pi/releases/download/v1.1.0/tensorflow-1.1.0-cp34-cp34m-linux_armv7l.whl
# RUN cp tensorflow-1.1.0-cp34-cp34m-linux_armv7l.whl tensorflow-1.1.0-cp35-cp35m-linux_armv7l.whl
#
#RUN pip3 install tensorflow-1.1.0-cp34-cp34m-linux_armv7l.whl
#RUN pip3 install mock
# Enable command line Arduino via platformio
RUN pip install platformio
# Enable pic32 compiler execution
RUN ln -s /lib/arm-linux-gnueabihf/ld-linux.so.3 /lib/ld-linux.so.3
RUN pio platform install microchippic32
# Enable and compile a default program
WORKDIR /foocars/arduino/MOTTOServoDataSampleDelay
RUN pio lib install 944
RUN pio run
RUN pio device list
WORKDIR /foocars
RUN pip3 install -r requirements.txt
# TODO no longer run as service but as a car script ottoLogger.py for example
# Set up the raspberry pi services
WORKDIR /usr/local/bin
RUN ln -s /foocars/services/ottoMicroLogger.py
RUN ln -s /foocars/services/ottoMicroLogger.service
RUN systemctl enable /foocars/services/ottoMicroLogger.service
# TODO: Enable USB Flash drive code
# TODO: upload Arduino code to car
# TODO: add default weigths
RUN echo "Done"