Skip to content

Commit a75c823

Browse files
Copilotnjzjz
andcommitted
fix(pt): resolve duplicate symbol compilation error in DeepTensorPT createNlistTensor function
Co-authored-by: njzjz <9496702+njzjz@users.noreply.github.com>
1 parent 7313b88 commit a75c823

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

source/api_cc/src/DeepTensorPT.cc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@
1414

1515
using namespace deepmd;
1616

17-
torch::Tensor createNlistTensor(const std::vector<std::vector<int>>& data) {
17+
static torch::Tensor createNlistTensor(
18+
const std::vector<std::vector<int>>& data) {
1819
size_t total_size = 0;
1920
for (const auto& row : data) {
2021
total_size += row.size();

0 commit comments

Comments
 (0)