Skip to content

Commit

Permalink
Merge branch 'op2func_refactor' of https://github.com/chenwhql/Paddle
Browse files Browse the repository at this point in the history
…into op2func_refactor
  • Loading branch information
chenwhql committed Oct 26, 2021
2 parents 558a848 + 3276897 commit 72910fa
Show file tree
Hide file tree
Showing 118 changed files with 9,519 additions and 2,682 deletions.
2 changes: 1 addition & 1 deletion cmake/external/xpu.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ ELSE ()
ENDIF()

SET(XPU_BASE_URL_WITHOUT_DATE "https://baidu-kunlun-product.cdn.bcebos.com/KL-SDK/klsdk-dev")
SET(XPU_BASE_URL "${XPU_BASE_URL_WITHOUT_DATE}/20210921")
SET(XPU_BASE_URL "${XPU_BASE_URL_WITHOUT_DATE}/20211020")
SET(XPU_XRE_URL "${XPU_BASE_URL}/${XPU_XRE_DIR_NAME}.tar.gz" CACHE STRING "" FORCE)
SET(XPU_XDNN_URL "${XPU_BASE_URL}/${XPU_XDNN_DIR_NAME}.tar.gz" CACHE STRING "" FORCE)
SET(XPU_XCCL_URL "${XPU_BASE_URL_WITHOUT_DATE}/20210623/${XPU_XCCL_DIR_NAME}.tar.gz" CACHE STRING "" FORCE)
Expand Down
5 changes: 3 additions & 2 deletions cmake/operators.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,8 @@ function(op_library TARGET)
"fusion_transpose_flatten_concat_op" "fusion_conv_inception_op"
"sync_batch_norm_op" "sparse_attention_op" "dgc_op" "fused_fc_elementwise_layernorm_op"
"skip_layernorm_op" "multihead_matmul_op" "fusion_group_op" "fused_bn_activation_op" "fused_embedding_eltwise_layernorm_op" "fusion_gru_op" "fusion_lstm_op"
"fused_bn_add_activation_op" "fused_attention_op" "resnet_unit_op")
"fused_bn_add_activation_op" "fused_attention_op" "resnet_unit_op" "fused_feedforward_op")

if ("${TARGET}" STREQUAL "${manual_pybind_op}")
set(pybind_flag 1)
endif()
Expand Down Expand Up @@ -298,7 +299,7 @@ function(op_library TARGET)
file(APPEND ${pybind_file} "USE_OP_DEVICE_KERNEL(${TARGET}, CUDNN);\n")
endif()

if (WITH_XPU AND ${xpu_cc_srcs_len} GREATER 0)
if (WITH_XPU AND ${pybind_flag} EQUAL 0 AND ${xpu_cc_srcs_len} GREATER 0)
file(APPEND ${pybind_file} "USE_OP_DEVICE_KERNEL(${TARGET}, XPU);\n")
endif()

Expand Down
1 change: 1 addition & 0 deletions cmake/third_party.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -363,6 +363,7 @@ endif (WITH_LITE)
if (WITH_CINN)
message(STATUS "Compile Paddle with CINN.")
include(external/cinn)
add_definitions(-DPADDLE_WITH_CINN)
endif (WITH_CINN)

if (WITH_CRYPTO)
Expand Down
9 changes: 0 additions & 9 deletions paddle/fluid/distributed/ps.proto
Original file line number Diff line number Diff line change
Expand Up @@ -119,13 +119,11 @@ message TableParameter {

message TableAccessorParameter {
optional string accessor_class = 1;
// optional SparseSGDRuleParameter sparse_sgd_param = 2;
optional uint32 fea_dim = 4 [ default = 11 ];
optional uint32 embedx_dim = 5 [ default = 8 ];
optional uint32 embedx_threshold = 6 [ default = 10 ];
optional CtrAccessorParameter ctr_accessor_param = 7;
repeated TableAccessorSaveParameter table_accessor_save_param = 8;
// optional SparseCommonSGDRuleParameter sparse_commonsgd_param = 9;
optional SparseCommonSGDRuleParameter embed_sgd_param = 10;
optional SparseCommonSGDRuleParameter embedx_sgd_param = 11;
}
Expand Down Expand Up @@ -182,13 +180,6 @@ message TableAccessorSaveParameter {
optional string deconverter = 3;
}

// message SparseSGDRuleParameter {
// optional double learning_rate = 1 [default = 0.05];
// optional double initial_g2sum = 2 [default = 3.0];
// optional double initial_range = 3 [default = 0.0001];
// repeated float weight_bounds = 4;
//}

message SparseCommonSGDRuleParameter {
optional string name = 1;
optional SparseNaiveSGDRuleParameter naive = 2;
Expand Down
5 changes: 3 additions & 2 deletions paddle/fluid/distributed/table/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@ cc_library(tensor_table SRCS tensor_table.cc DEPS eigen3 ps_framework_proto exec
set_source_files_properties(table.cc PROPERTIES COMPILE_FLAGS ${DISTRIBUTE_COMPILE_FLAGS})

set_source_files_properties(sparse_sgd_rule.cc PROPERTIES COMPILE_FLAGS ${DISTRIBUTE_COMPILE_FLAGS})
set_source_files_properties(ctr_accessor.cc PROPERTIES COMPILE_FLAGS ${DISTRIBUTE_COMPILE_FLAGS})
cc_library(sparse_sgd_rule SRCS sparse_sgd_rule.cc DEPS ${TABLE_DEPS} ps_framework_proto)
cc_library(ctr_accessor SRCS ctr_accessor.cc DEPS ${TABLE_DEPS} ps_framework_proto sparse_sgd_rule)


cc_library(table SRCS table.cc DEPS common_table tensor_accessor tensor_table ps_framework_proto string_helper device_context gflags glog boost sparse_sgd_rule)
cc_library(table SRCS table.cc DEPS common_table tensor_accessor tensor_table ps_framework_proto string_helper device_context gflags glog boost ctr_accessor)
Loading

1 comment on commit 72910fa

@paddle-bot-old
Copy link

@paddle-bot-old paddle-bot-old bot commented on 72910fa Oct 26, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🕵️ CI failures summary

🔍 PR: #34425 Commit ID: 72910fa contains failed CI.

🔹 Failed: PR-CI-APPROVAL

approve_failed
2021-10-26 17:36:43 正在保存至: “bk.txt”
2021-10-26 17:36:43 0K 100% 4.03M=0s
2021-10-26 17:36:43 2021-10-26 17:36:43 (4.03 MB/s) - 已保存 “bk.txt” [5/5])
2021-10-26 17:36:51 ****************
2021-10-26 17:36:51 0. You must have one RD (lanxianghit (Recommend), phlrain or luotao1) approval for changing the FLAGS, which manages the environment variables.
2021-10-26 17:36:51 1. You must have Dianhai approval for change 20+ files or add than 1000+ lines of content.
2021-10-26 17:36:51 2. You must have one RD (XiaoguangHu01,chenwhql,zhiqiu,Xreki,luotao1) approval for paddle/fluid/framework/operator.h, which manages the underlying code for fluid.
2021-10-26 17:36:51 3. You must have one RD (zhiqiu (Recommend) , phlrain) approval for the changes of paddle/fluid/pybind/op_function_generator.cc, which manages the logic of automatic generating op functions for dygraph.
2021-10-26 17:36:51 4. You must have one RD (XiaoguangHu01,chenwhql,zhiqiu,Xreki,luotao1) approval for the usage of const_cast.
2021-10-26 17:36:51 5. You must have one RD (Avin0323(Recommend) or zhouwei25 or wanghuancoder or luotao1) approval for modifying unity_build_rule.cmake which the rules of Unity Build.
2021-10-26 17:36:51 There are 6 approved errors.
2021-10-26 17:36:51 ****************
2021-10-26 17:36:51 + EXCODE=6
2021-10-26 17:36:51 + echo 'EXCODE: 6'
2021-10-26 17:36:51 EXCODE: 6
2021-10-26 17:36:51 + echo 'ipipe_log_param_EXCODE: 6'
2021-10-26 17:36:51 ipipe_log_param_EXCODE: 6
2021-10-26 17:36:51 + exit 6

🔹 Failed: PR-CI-Windows

test_failed
2021-10-26 19:48:45 The following tests FAILED:
2021-10-26 19:48:45 1068 - test_fuse_all_reduce_pass (Failed)
2021-10-26 19:48:45 Errors while running CTest
2021-10-26 19:48:45 =========================================
2021-10-26 19:48:45 There are more than 10 failed unit tests, so no unit test retry!!!
2021-10-26 19:48:45 =========================================
2021-10-26 19:48:45 1068 - test_fuse_all_reduce_pass (Failed)
2021-10-26 19:48:45 39 - lodtensor_printer_test (Timeout)
2021-10-26 19:48:45 52 - data_type_test (Timeout)
2021-10-26 19:48:45 56 - eigen_test (Timeout)
2021-10-26 19:48:45 69 - program_desc_test (Timeout)
2021-10-26 19:48:45 70 - op_version_registry_test (Timeout)
2021-10-26 19:48:45 82 - selected_rows_test (Timeout)
2021-10-26 19:48:45 83 - op_kernel_type_test (Timeout)
2021-10-26 19:48:45 96 - graph_helper_test (Timeout)
2021-10-26 19:48:45 97 - graph_to_program_pass_test (Timeout)
2021-10-26 19:48:45 104 - test_seqpool_concat_fuse_pass (Timeout)
2021-10-26 19:48:45 118 - test_cudnn_placement_pass (Timeout)
2021-10-26 19:48:45 120 - test_conv_bias_mkldnn_fuse_pass (Timeout)
2021-10-26 19:48:45 121 - test_conv_activation_mkldnn_fuse_pass (Timeout)
2021-10-26 19:48:45 123 - test_conv_elementwise_add_mkldnn_fuse_pass (Timeout)

🔹 Failed: PR-CI-OP-benchmark

Unknown Failed
2021-10-26 21:42:37 [tools/test_ci_op_benchmark.sh:271] [ERROR] Missing test script of "mean"(paddle/fluid/operators/mean_op.cu) in benchmark.
2021-10-26 21:42:37 + for op_name in '${!CHANGE_OP_MAP[@]}'
2021-10-26 21:42:37 + '[' -z '' ']'
2021-10-26 21:42:37 + exit_code=8
2021-10-26 21:42:37 + LOG '[ERROR] Missing test script of "fill_any_like"(paddle/fluid/operators/fill_any_like_op.cu) in benchmark.'
2021-10-26 21:42:37 + echo '[tools/test_ci_op_benchmark.sh:271] [ERROR] Missing test script of "fill_any_like"(paddle/fluid/operators/fill_any_like_op.cu) in benchmark.'
2021-10-26 21:42:37 [tools/test_ci_op_benchmark.sh:271] [ERROR] Missing test script of "fill_any_like"(paddle/fluid/operators/fill_any_like_op.cu) in benchmark.
2021-10-26 21:42:37 + for op_name in '${!CHANGE_OP_MAP[@]}'
2021-10-26 21:42:37 + '[' -z matmul,matmul,matmul.json,True ']'
2021-10-26 21:42:37 + '[' 8 -ne 0 ']'
2021-10-26 21:42:37 + LOG '[INFO] See https://github.com/PaddlePaddle/Paddle/wiki/PR-CI-OP-benchmark-Manual for details.'
2021-10-26 21:42:37 + echo '[tools/test_ci_op_benchmark.sh:275] [INFO] See https://github.com/PaddlePaddle/Paddle/wiki/PR-CI-OP-benchmark-Manual for details.'
2021-10-26 21:42:37 [tools/test_ci_op_benchmark.sh:275] [INFO] See https://github.com/PaddlePaddle/Paddle/wiki/PR-CI-OP-benchmark-Manual for details.
2021-10-26 21:42:37 + LOG '[INFO] Or you can apply for one RD (Avin0323(Recommend), Xreki, luotao1) approval to pass this PR.'
2021-10-26 21:42:37 + echo '[tools/test_ci_op_benchmark.sh:276] [INFO] Or you can apply for one RD (Avin0323(Recommend), Xreki, luotao1) approval to pass this PR.'
2021-10-26 21:42:37 [tools/test_ci_op_benchmark.sh:276] [INFO] Or you can apply for one RD (Avin0323(Recommend), Xreki, luotao1) approval to pass this PR.
2021-10-26 21:42:37 + exit 8
2021-10-26 21:42:37 {build code state=8}
2021-10-26 21:42:47 kill agent BUILD_CODE_FAIL

🔹 Failed: PR-CI-Py3

test_failed
2021-10-26 22:57:46 The following tests FAILED:
2021-10-26 22:57:46 1276 - test_dist_mnist_gradient_merge (Failed)
2021-10-26 22:57:46 1331 - test_fuse_all_reduce_pass (Failed)
2021-10-26 22:57:46 1331 - test_fuse_all_reduce_pass (Failed)
2021-10-26 22:57:46 + EXCODE=8
2021-10-26 22:57:46 + echo 'EXCODE: 8'
2021-10-26 22:57:46 EXCODE: 8
2021-10-26 22:57:46 + echo 'ipipe_log_param_EXCODE: 8'
2021-10-26 22:57:46 ipipe_log_param_EXCODE: 8
2021-10-26 22:57:46 + [[ 8 -eq 0 ]]
2021-10-26 22:57:46 + set +x
2021-10-26 22:57:46 Sorry, some tests failed.
2021-10-26 22:57:46 + exit 8
2021-10-26 22:57:46 {build code state=8}

Please sign in to comment.