diff --git a/tf_adapter/util/npu_ops_identifier.cc b/tf_adapter/util/npu_ops_identifier.cc index d998841c2f80d35a9ff8c452120c61d28264b2e6..2ece2d4b82bcbee4712f8cc65e74c7686e866062 100644 --- a/tf_adapter/util/npu_ops_identifier.cc +++ b/tf_adapter/util/npu_ops_identifier.cc @@ -26,6 +26,7 @@ #include "tf_adapter/util/generate_report.h" #include "tf_adapter/util/npu_attrs.h" #include "mmpa/mmpa_api.h" +#include "register/register_base.h" using json = nlohmann::json; @@ -84,7 +85,7 @@ bool NpuOpsIdentifier::IsNewOppPathStruct(const std::string &opp_path) { void NpuOpsIdentifier::GetCustomOpPathFromCustomOppPath(std::vector &custom_ops_json_path_vec) { ADP_LOG(INFO) << "Start to get custom ops json path from ASCEND_CUSTOM_OPP_PATH schedule."; custom_ops_json_path_vec.clear(); - const char *const custom_opp_path_env = std::getenv("ASCEND_CUSTOM_OPP_PATH"); + const char *const custom_opp_path_env = aclGetCustomOpLibPath(); if (custom_opp_path_env == nullptr) { ADP_LOG(INFO) << "env ASCEND_CUSTOM_OPP_PATH is not defined."; return;