Skip to content

Commit d54494b

Browse files
authored
cleanup test=develop (#15347)
1 parent fe8f28c commit d54494b

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

paddle/fluid/framework/details/execution_strategy.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,10 @@ struct ExecutionStrategy {
2525
size_t num_threads_{0};
2626
bool use_cuda_{true};
2727
bool allow_op_delay_{false};
28-
size_t num_iteration_per_drop_scope_{1};
28+
// If we set this to 1, we will delete all variables when finish a batch. and
29+
// this will loss 15%+ performance.
30+
// Please be aware about this parameters.
31+
size_t num_iteration_per_drop_scope_{100};
2932
ExecutorType type_{kDefault};
3033
bool dry_run_{false};
3134
};

paddle/fluid/operators/distributed/variable_response.cc

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,8 +117,9 @@ bool VariableResponse::CopyLodTensorData(
117117
tensor->mutable_data(ctx.GetPlace(), ToVarType(meta_.data_type()));
118118

119119
VLOG(6) << "Tensor.memory_size = " << tensor->memory_size()
120-
<< ", Buffer Size = " << length;
121-
PADDLE_ENFORCE_EQ(tensor->memory_size(), static_cast<unsigned int>(length));
120+
<< ", Buffer Size = " << length << ", dims:" << dims
121+
<< ", numel:" << tensor->numel();
122+
PADDLE_ENFORCE_GE(tensor->memory_size(), static_cast<unsigned int>(length));
122123
return ReadRaw(input, ctx, tensor->place(), tensor_data, length);
123124
}
124125

0 commit comments

Comments
 (0)