Skip to content

Commit 381bea0

Browse files
committed
fix test_analysis_predictor
test=develop
1 parent d8425e0 commit 381bea0

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

paddle/fluid/inference/api/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ if(WITH_TESTING)
3737
ARGS --word2vec_dirname=${WORD2VEC_MODEL_DIR} --book_dirname=${PYTHON_TESTS_DIR}/book)
3838
set_tests_properties(test_api_impl PROPERTIES DEPENDS test_image_classification)
3939
endif()
40-
cc_test(test_analysis_predictor SRCS analysis_predictor_tester.cc DEPS analysis_predictor ${inference_deps} paddle_inference_api
41-
ARGS --dirname=${PYTHON_TESTS_DIR}/book)
40+
cc_test(test_analysis_predictor SRCS analysis_predictor_tester.cc DEPS analysis_predictor ${inference_deps}
41+
ARGS --dirname=${WORD2VEC_MODEL_DIR})
4242

4343
if(WITH_GPU AND TENSORRT_FOUND)
4444
cc_library(paddle_inference_tensorrt_subgraph_engine

paddle/fluid/inference/api/analysis_predictor_tester.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ using contrib::AnalysisConfig;
2424

2525
TEST(AnalysisPredictor, ZeroCopy) {
2626
AnalysisConfig config;
27-
config.model_dir = FLAGS_dirname + "/word2vec.inference.model";
27+
config.model_dir = FLAGS_dirname;
2828
config.use_feed_fetch_ops = false;
2929

3030
auto predictor = CreatePaddlePredictor<AnalysisConfig>(config);

0 commit comments

Comments
 (0)