Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
BaiXuePrincess
Paddle
提交
dc455617
P
Paddle
项目概览
BaiXuePrincess
/
Paddle
与 Fork 源项目一致
Fork自
PaddlePaddle / Paddle
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
dc455617
编写于
11月 10, 2020
作者:
T
tianshuo78520a
提交者:
GitHub
11月 10, 2020
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Update version docker (#28314)
上级
546b1c1d
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
54 addition
and
27 deletion
+54
-27
tools/dockerfile/ubuntu16_dev.sh
tools/dockerfile/ubuntu16_dev.sh
+54
-27
未找到文件。
tools/dockerfile/ubuntu16_dev.sh
浏览文件 @
dc455617
#!/bin/bash
# Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
docker_name
=
$1
function
ref_whl
(){
if
[[
${
WITH_GPU
}
==
"ON"
]]
;
then
...
...
@@ -20,48 +35,59 @@ function ref_whl(){
if
[[
${
gcc_version
}
==
"8.2.0"
]]
;
then
ref_gcc
=
_gcc8.2
fi
if
[[
${
ref_CUDA_MAJOR
}
==
"10"
]]
;
then
ref_version
=
.post100
elif
[[
${
ref_CUDA_MAJOR
}
==
"10.1"
]]
;
then
ref_version
=
.post101
elif
[[
${
ref_CUDA_MAJOR
}
==
"10.2"
]]
;
then
ref_version
=
""
elif
[[
${
ref_CUDA_MAJOR
}
==
"9"
]]
;
then
ref_version
=
.post90
fi
ref_web
=
"https://paddle-wheel.bj.bcebos.com/
${
PADDLE_BRANCH
}
-
${
ref_gpu
}
-
${
ref_mkl
}${
ref_gcc
}
"
if
[[
${
PADDLE_
BRANCH
}
==
"0.0.0"
&&
${
WITH_GPU
}
==
"ON"
]]
;
then
ref_paddle_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp27-cp27mu-linux_x86_64
.whl
ref_paddle3_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp35-cp35m-linux_x86_64
.whl
ref_paddle36_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp36-cp36m-linux_x86_64
.whl
ref_paddle37_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp37-cp37m-linux_x86_64
.whl
ref_paddle38_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp38-cp38-linux_x86_64
.whl
if
[[
${
PADDLE_
VERSION
}
==
"0.0.0"
&&
${
WITH_GPU
}
==
"ON"
]]
;
then
ref_paddle_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp27-cp27mu-linux_x86_64
.whl
ref_paddle3_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp35-cp35m-linux_x86_64
.whl
ref_paddle36_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp36-cp36m-linux_x86_64
.whl
ref_paddle37_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp37-cp37m-linux_x86_64
.whl
ref_paddle38_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp38-cp38-linux_x86_64
.whl
else
ref_paddle_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp27-cp27mu-linux_x86_64
.whl
ref_paddle3_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp35-cp35m-linux_x86_64
.whl
ref_paddle36_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp36-cp36m-linux_x86_64
.whl
ref_paddle37_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp37-cp37m-linux_x86_64
.whl
ref_paddle38_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp38-cp38-linux_x86_64
.whl
ref_paddle_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp27-cp27mu-linux_x86_64
.whl
ref_paddle3_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp35-cp35m-linux_x86_64
.whl
ref_paddle36_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp36-cp36m-linux_x86_64
.whl
ref_paddle37_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp37-cp37m-linux_x86_64
.whl
ref_paddle38_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp38-cp38-linux_x86_64
.whl
fi
if
[[
${
PADDLE_
BRANCH
}
!=
"0.0.0"
&&
${
WITH_GPU
}
==
"ON"
]]
;
then
ref_paddle_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
.post
${
ref_CUDA_MAJOR
}${
CUDNN_MAJOR
}
-cp27-cp27mu-linux_x86_64
.whl
ref_paddle3_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
.post
${
ref_CUDA_MAJOR
}${
CUDNN_MAJOR
}
-cp35-cp35m-linux_x86_64
.whl
ref_paddle36_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
.post
${
ref_CUDA_MAJOR
}${
CUDNN_MAJOR
}
-cp36-cp36m-linux_x86_64
.whl
ref_paddle37_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
.post
${
ref_CUDA_MAJOR
}${
CUDNN_MAJOR
}
-cp37-cp37m-linux_x86_64
.whl
ref_paddle38_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
.post
${
ref_CUDA_MAJOR
}${
CUDNN_MAJOR
}
-cp38-cp38-linux_x86_64
.whl
if
[[
${
PADDLE_
VERSION
}
!=
"0.0.0"
&&
${
WITH_GPU
}
==
"ON"
]]
;
then
ref_paddle_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}${
ref_version
}
-cp27-cp27mu-linux_x86_64
.whl
ref_paddle3_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}${
ref_version
}
-cp35-cp35m-linux_x86_64
.whl
ref_paddle36_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}${
ref_version
}
-cp36-cp36m-linux_x86_64
.whl
ref_paddle37_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}${
ref_version
}
-cp37-cp37m-linux_x86_64
.whl
ref_paddle38_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}${
ref_version
}
-cp38-cp38-linux_x86_64
.whl
else
ref_paddle_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp27-cp27mu-linux_x86_64
.whl
ref_paddle3_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp35-cp35m-linux_x86_64
.whl
ref_paddle36_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp36-cp36m-linux_x86_64
.whl
ref_paddle37_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp37-cp37m-linux_x86_64
.whl
ref_paddle38_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
BRANCH
}
-cp38-cp38-linux_x86_64
.whl
ref_paddle_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp27-cp27mu-linux_x86_64
.whl
ref_paddle3_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp35-cp35m-linux_x86_64
.whl
ref_paddle36_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp36-cp36m-linux_x86_64
.whl
ref_paddle37_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp37-cp37m-linux_x86_64
.whl
ref_paddle38_whl
=
paddlepaddle
${
install_gpu
}
-
${
PADDLE_
VERSION
}
-cp38-cp38-linux_x86_64
.whl
fi
}
function
install_whl
(){
dockerfile_line
=
`
wc
-l
Dockerfile.tmp|awk
'{print $1}'
`
sed
-i
"
${
dockerfile_line
}
i RUN wget
${
ref_web
}
/
${
ref_paddle_whl
}
&& pip install
${
ref_paddle_whl
}
&& rm -f
${
ref_paddle_whl
}
"
Dockerfile.tmp
sed
-i
"
${
dockerfile_line
}
i RUN wget
${
ref_web
}
/
${
ref_paddle3_whl
}
&& pip3.5 install
${
ref_paddle3_whl
}
&& rm -f
${
ref_paddle3_whl
}
"
Dockerfile.tmp
sed
-i
"
${
dockerfile_line
}
i RUN wget
${
ref_web
}
/
${
ref_paddle36_whl
}
&& pip3.6 install
${
ref_paddle36_whl
}
&& rm -f
${
ref_paddle36_whl
}
"
Dockerfile.tmp
sed
-i
"
${
dockerfile_line
}
i RUN wget
${
ref_web
}
/
${
ref_paddle37_whl
}
&& pip3.7 install
${
ref_paddle37_whl
}
&& rm -f
${
ref_paddle37_whl
}
"
Dockerfile.tmp
sed
-i
"
${
dockerfile_line
}
i RUN wget
${
ref_web
}
/
${
ref_paddle38_whl
}
&& pip3.8 install
${
ref_paddle38_whl
}
&& rm -f
${
ref_paddle38_whl
}
"
Dockerfile.tmp
sed
-i
"
${
dockerfile_line
}
i RUN wget
-q
${
ref_web
}
/
${
ref_paddle_whl
}
&& pip install
${
ref_paddle_whl
}
&& rm -f
${
ref_paddle_whl
}
"
Dockerfile.tmp
sed
-i
"
${
dockerfile_line
}
i RUN wget
-q
${
ref_web
}
/
${
ref_paddle3_whl
}
&& pip3.5 install
${
ref_paddle3_whl
}
&& rm -f
${
ref_paddle3_whl
}
"
Dockerfile.tmp
sed
-i
"
${
dockerfile_line
}
i RUN wget
-q
${
ref_web
}
/
${
ref_paddle36_whl
}
&& pip3.6 install
${
ref_paddle36_whl
}
&& rm -f
${
ref_paddle36_whl
}
"
Dockerfile.tmp
sed
-i
"
${
dockerfile_line
}
i RUN wget
-q
${
ref_web
}
/
${
ref_paddle37_whl
}
&& pip3.7 install
${
ref_paddle37_whl
}
&& rm -f
${
ref_paddle37_whl
}
"
Dockerfile.tmp
sed
-i
"
${
dockerfile_line
}
i RUN wget
-q
${
ref_web
}
/
${
ref_paddle38_whl
}
&& pip3.8 install
${
ref_paddle38_whl
}
&& rm -f
${
ref_paddle38_whl
}
"
Dockerfile.tmp
}
function
install_gcc
(){
if
[
"
${
gcc_version
}
"
==
"8.2.0"
]
;
then
sed
-i
's#<install_gcc>#WORKDIR /usr/bin \
...
...
@@ -86,6 +112,7 @@ function make_dockerfile(){
sed
"s/<baseimg>/
${
docker_name
}
/g"
tools/dockerfile/Dockerfile.ubuntu
>
Dockerfile.tmp
}
function
main
(){
make_dockerfile
install_gcc
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录