-
Notifications
You must be signed in to change notification settings - Fork 30
/
Copy pathDockerfile
41 lines (30 loc) · 1.25 KB
/
Dockerfile
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
FROM azul/zulu-openjdk:11 as build
RUN apt-get update && apt-get -y install curl
WORKDIR /work
COPY mill build.sc ./
ADD common ./common
ADD tools ./tools
ADD compiler ./compiler
ADD emulator ./emulator
ADD rtl ./rtl
RUN ls -la
RUN ./mill '{rtl,compiler,emulator}.assembly'
FROM azul/zulu-openjdk:11 as models
WORKDIR /work
RUN apt-get update && apt-get -y install wget
RUN wget https://github.com/tensil-ai/tensil-models/archive/main.tar.gz && tar xf main.tar.gz
FROM azul/zulu-openjdk:11
RUN mkdir -p /demo/models
RUN mkdir -p /demo/models/data
COPY --from=models /work/tensil-models-main/resnet20v2_cifar.* /demo/models/
COPY --from=models /work/tensil-models-main/resnet50v2_imagenet.* /demo/models/
COPY --from=models /work/tensil-models-main/yolov4_tiny_192.* /demo/models/
COPY --from=models /work/tensil-models-main/yolov4_tiny_416.* /demo/models/
COPY --from=models /work/tensil-models-main/data/* /demo/models/data/
RUN mkdir -p /demo/arch
COPY ./arch/* /demo/arch/
RUN mkdir -p /opt/tensil
COPY --from=build /work/out/rtl/assembly.dest/out.jar /opt/tensil/rtl.jar
COPY --from=build /work/out/compiler/assembly.dest/out.jar /opt/tensil/compiler.jar
COPY --from=build /work/out/emulator/assembly.dest/out.jar /opt/tensil/emulator.jar
COPY ./docker/bin/* /usr/bin/