fix parallel do hard coded empty var name (#8469)

yu239-patch-1
Yang Yang(Tony) 7 years ago committed by GitHub
parent 633756ad13
commit 3c2cafbe1d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -256,7 +256,7 @@ class ParallelDoGradOp : public framework::OperatorBase {
}
}
for (auto &s : Outputs(framework::GradVarName(kParameters))) {
if (s == "@EMPTY@") {
if (s == framework::kEmptyVarName) {
continue;
}
VLOG(3) << "Moving " << s;
@ -270,7 +270,7 @@ class ParallelDoGradOp : public framework::OperatorBase {
const std::vector<framework::Scope *> &sub_scopes,
const platform::PlaceList &places) const {
for (auto &s : Outputs(framework::GradVarName(kParameters))) {
if (s == "@EMPTY@") {
if (s == framework::kEmptyVarName) {
continue;
}
VLOG(3) << "Accumulating " << s;

Loading…
Cancel
Save