Skip to content

Commit 0c99cd7

Browse files
committed
fix errors in sequence_padding_test
1 parent bf99396 commit 0c99cd7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

paddle/fluid/operators/math/sequence_padding_test.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ void TestSequencePadding(const paddle::framework::LoD& lod,
4141
if (paddle::platform::is_cpu_place(*place)) {
4242
seq = cpu_seq;
4343
} else {
44-
TensorCopy(cpu_seq, *place, *context, &seq);
44+
TensorCopySync(cpu_seq, *place, &seq);
4545
seq.set_lod(lod);
4646
}
4747

@@ -64,7 +64,7 @@ void TestSequencePadding(const paddle::framework::LoD& lod,
6464
if (paddle::platform::is_cpu_place(*place)) {
6565
cpu_seq_back = seq_back;
6666
} else {
67-
TensorCopy(seq_back, paddle::platform::CPUPlace(), *context, &cpu_seq_back);
67+
TensorCopySync(seq_back, paddle::platform::CPUPlace(), &cpu_seq_back);
6868
cpu_seq_back.set_lod(lod);
6969
}
7070

0 commit comments

Comments
 (0)