Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
Paddle
提交
9f47aac9
P
Paddle
项目概览
PaddlePaddle
/
Paddle
大约 1 年 前同步成功
通知
2299
Star
20931
Fork
5422
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1423
列表
看板
标记
里程碑
合并请求
543
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1,423
Issue
1,423
列表
看板
标记
里程碑
合并请求
543
合并请求
543
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
9f47aac9
编写于
12月 22, 2022
作者:
H
HongyuJia
提交者:
GitHub
12月 22, 2022
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix custom operator testcase CI error (#49270)
上级
1172df96
变更
1
显示空白变更内容
内联
并排
Showing
1 changed file
with
9 addition
and
6 deletion
+9
-6
python/paddle/fluid/tests/custom_op/utils.py
python/paddle/fluid/tests/custom_op/utils.py
+9
-6
未找到文件。
python/paddle/fluid/tests/custom_op/utils.py
浏览文件 @
9f47aac9
...
@@ -14,21 +14,24 @@
...
@@ -14,21 +14,24 @@
import
os
import
os
import
sys
import
sys
from
distutils.sysconfig
import
get_python_lib
from
site
import
getsitepackages
from
paddle.utils.cpp_extension.extension_utils
import
IS_WINDOWS
from
paddle.utils.cpp_extension.extension_utils
import
IS_WINDOWS
IS_MAC
=
sys
.
platform
.
startswith
(
'darwin'
)
IS_MAC
=
sys
.
platform
.
startswith
(
'darwin'
)
site_packages_path
=
get_python_lib
()
# Note(Aurelius84): We use `add_test` in Cmake to config how to run unittest in CI.
# Note(Aurelius84): We use `add_test` in Cmake to config how to run unittest in CI.
# `PYTHONPATH` will be set as `build/python/paddle` that will make no way to find
# `PYTHONPATH` will be set as `build/python/paddle` that will make no way to find
# paddle include directory. Because the following path is generated after installing
# paddle include directory. Because the following path is generated after installing
# PaddlePaddle whl. So here we specific `include_dirs` to avoid errors in CI.
# PaddlePaddle whl. So here we specific `include_dirs` to avoid errors in CI.
paddle_includes
=
[
paddle_includes
=
[]
os
.
path
.
join
(
site_packages_path
,
'paddle'
,
'include'
),
for
site_packages_path
in
getsitepackages
():
os
.
path
.
join
(
site_packages_path
,
'paddle'
,
'include'
,
'third_party'
),
paddle_includes
.
append
(
]
os
.
path
.
join
(
site_packages_path
,
'paddle'
,
'include'
)
)
paddle_includes
.
append
(
os
.
path
.
join
(
site_packages_path
,
'paddle'
,
'include'
,
'third_party'
)
)
# Test for extra compile args
# Test for extra compile args
extra_cc_args
=
[
'-w'
,
'-g'
]
if
not
IS_WINDOWS
else
[
'/w'
]
extra_cc_args
=
[
'-w'
,
'-g'
]
if
not
IS_WINDOWS
else
[
'/w'
]
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录