Commit ecff75dea5193a4c127c23b4a85b48d30ab8b7ef
1 parent
45e07c6d
删除aclrtSetDevice
Showing
1 changed file
with
0 additions
and
7 deletions
src/ai_platform/MultiSourceProcess.cpp
@@ -118,8 +118,6 @@ int CMultiSourceProcess::InitAlgorthim(tsl_aiplatform_param vptParam){ | @@ -118,8 +118,6 @@ int CMultiSourceProcess::InitAlgorthim(tsl_aiplatform_param vptParam){ | ||
118 | vparam.threshold = 0.4; | 118 | vparam.threshold = 0.4; |
119 | vparam.model_dir = models_dir; | 119 | vparam.model_dir = models_dir; |
120 | 120 | ||
121 | - aclrtSetDevice(m_devId); | ||
122 | - | ||
123 | int ret = vpt_process.init(vparam); | 121 | int ret = vpt_process.init(vparam); |
124 | if (ret < 0){ | 122 | if (ret < 0){ |
125 | return ret; | 123 | return ret; |
@@ -706,7 +704,6 @@ bool CMultiSourceProcess::finish_task(const string taskID, const bool delete_sna | @@ -706,7 +704,6 @@ bool CMultiSourceProcess::finish_task(const string taskID, const bool delete_sna | ||
706 | int CMultiSourceProcess::algorthim_process_thread(){ | 704 | int CMultiSourceProcess::algorthim_process_thread(){ |
707 | LOG_INFO("algorthim_process_thread start..."); | 705 | LOG_INFO("algorthim_process_thread start..."); |
708 | 706 | ||
709 | - ACL_CALL(aclrtSetDevice(m_devId), ACL_SUCCESS, 1); | ||
710 | aclrtContext ctx; | 707 | aclrtContext ctx; |
711 | ACL_CALL(aclrtCreateContext(&ctx, m_devId), ACL_SUCCESS, 1); | 708 | ACL_CALL(aclrtCreateContext(&ctx, m_devId), ACL_SUCCESS, 1); |
712 | 709 | ||
@@ -762,9 +759,6 @@ int CMultiSourceProcess::algorthim_process_thread(){ | @@ -762,9 +759,6 @@ int CMultiSourceProcess::algorthim_process_thread(){ | ||
762 | } | 759 | } |
763 | } | 760 | } |
764 | } | 761 | } |
765 | - | ||
766 | - | ||
767 | - | ||
768 | } | 762 | } |
769 | 763 | ||
770 | m_RgbDataList.pop_front(); | 764 | m_RgbDataList.pop_front(); |
@@ -811,7 +805,6 @@ int CMultiSourceProcess::algorthim_process_thread(){ | @@ -811,7 +805,6 @@ int CMultiSourceProcess::algorthim_process_thread(){ | ||
811 | } | 805 | } |
812 | 806 | ||
813 | aclrtDestroyContext(ctx); | 807 | aclrtDestroyContext(ctx); |
814 | - aclrtResetDevice(m_devId); | ||
815 | LOG_INFO("algorthim_process_thread exit."); | 808 | LOG_INFO("algorthim_process_thread exit."); |
816 | 809 | ||
817 | return 0; | 810 | return 0; |