Skip to content

Commit

Permalink
[fleet_executor] Dist model bug fixer (#39207)
Browse files Browse the repository at this point in the history
  • Loading branch information
FeixLiu authored Jan 26, 2022
1 parent 55d6b87 commit 02d3f23
Showing 1 changed file with 12 additions and 8 deletions.
20 changes: 12 additions & 8 deletions paddle/fluid/distributed/fleet_executor/dist_model.cc
Original file line number Diff line number Diff line change
Expand Up @@ -487,21 +487,25 @@ bool DistModel::PrepareFeedAndFetch() {
if (feeds_.size() == 0) {
LOG(ERROR) << "Feed ops are needed for the first pp stage.";
return false;
}
} else {
if (feeds_.size() > 0) {
LOG(WARNING) << "Feed op is found in the non-first stage of pp.";
} else {
LOG(WARNING) << "No feed ops in non-first pp stage.";
LOG(INFO) << "No feed ops in non-first pp stage.";
}
} else if (feeds_.size() > 0) {
LOG(WARNING) << "Feed op is found in the non-first stage of pp.";
}
if (IsPPLastStage(config_)) {
if (fetches_.size() == 0) {
LOG(ERROR) << "Fetch op is needed for the last pp stage.";
return false;
LOG(WARNING) << "No fetch op was found in the last pp stage. Make sure "
"the result has been sent to frist pp stage.";
}
} else {
if (fetches_.size() > 0) {
LOG(WARNING) << "Fetch op is found in the non-last stage of pp.";
} else {
LOG(WARNING) << "No fetch op in non-last pp stage.";
LOG(INFO) << "No fetch op in non-last pp stage.";
}
} else if (fetches_.size() > 0) {
LOG(WARNING) << "Fetch op is found in the non-last stage of pp.";
}
}
return true;
Expand Down

0 comments on commit 02d3f23

Please sign in to comment.