forked from mindspore-Ecosystem/mindspore
!4022 [MD] Fix Execution Tree Output
Merge pull request !4022 from nhussain/print_op_fix
This commit is contained in:
commit
13c63f0289
|
@ -212,8 +212,6 @@ Status BarrierOp::getNextTensorRow(TensorRow *new_row) {
|
|||
|
||||
// A function that prints info about the Operator
|
||||
void BarrierOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <BarrierOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
|
@ -135,8 +135,6 @@ Status BatchOp::operator()() {
|
|||
}
|
||||
|
||||
void BatchOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -207,8 +207,6 @@ BuildVocabOp::Builder::Builder()
|
|||
|
||||
// A print method typically used for debugging
|
||||
void BuildVocabOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -22,8 +22,6 @@ namespace mindspore {
|
|||
namespace dataset {
|
||||
// A print method typically used for debugging
|
||||
void CacheBase::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -28,9 +28,7 @@
|
|||
namespace mindspore {
|
||||
namespace dataset {
|
||||
CacheMergeOp::~CacheMergeOp() = default;
|
||||
void CacheMergeOp::Print(std::ostream &out, bool show_all)
|
||||
const { // Always show the id and name as first line regardless if this is summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
void CacheMergeOp::Print(std::ostream &out, bool show_all) const {
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -42,8 +42,6 @@ ConcatOp::ConcatOp(int32_t op_connector_size) : PipelineOp(op_connector_size), c
|
|||
|
||||
// A function that prints info about the Operator
|
||||
void ConcatOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this is summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
|
@ -222,7 +222,10 @@ void DatasetOp::Print(std::ostream &out, bool show_all) const {
|
|||
// When show_all is true, we display more detailed output for the op.
|
||||
// Derived printers should show their own header info, then call base class printer, followed by
|
||||
// derived-specific items.
|
||||
// For now, the base class doesn't have any summary info to show so it's a no-op in that case.
|
||||
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
|
||||
if (show_all) {
|
||||
// The detailed display will show common base class info of the op. Allow the derived class to print
|
||||
// it's own id and name though as the first line.
|
||||
|
@ -239,8 +242,6 @@ void DatasetOp::Print(std::ostream &out, bool show_all) const {
|
|||
if (sampler_) {
|
||||
sampler_->Print(out, show_all);
|
||||
}
|
||||
} else {
|
||||
out << Name() << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -307,8 +307,6 @@ Status DeviceQueueOp::SendDataToCPU() {
|
|||
}
|
||||
|
||||
void DeviceQueueOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
|
@ -42,8 +42,6 @@ EpochCtrlOp::~EpochCtrlOp() {}
|
|||
|
||||
// A print method typically used for debugging
|
||||
void EpochCtrlOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
|
@ -90,8 +90,6 @@ Status FilterOp::ValidateInColumns(const std::vector<std::string> *input_columns
|
|||
|
||||
// A print method typically used for debugging.
|
||||
void FilterOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -82,8 +82,6 @@ int32_t MapOp::num_consumers() const {
|
|||
|
||||
// A print method typically used for debugging
|
||||
void MapOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -51,8 +51,6 @@ ProjectOp::ProjectOp(const std::vector<std::string> &columns_to_project)
|
|||
: PipelineOp(0), columns_to_project_(columns_to_project) {}
|
||||
|
||||
void ProjectOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
|
@ -141,8 +141,6 @@ Status RenameOp::ComputeColMap() {
|
|||
// prints rename
|
||||
void RenameOp::Print(std::ostream &out, // In: The output stream to print to
|
||||
bool show_all) const { // In: T/F if it should print everything
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
|
@ -53,8 +53,6 @@ RepeatOp::~RepeatOp() {}
|
|||
|
||||
// A print method typically used for debugging
|
||||
void RepeatOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
|
@ -100,8 +100,6 @@ Status ShuffleOp::SelfReset() {
|
|||
|
||||
// A print method typically used for debugging
|
||||
void ShuffleOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
|
@ -58,8 +58,6 @@ SkipOp::~SkipOp() {}
|
|||
|
||||
// A print method typically used for debugging
|
||||
void SkipOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
|
@ -386,8 +386,6 @@ Status CelebAOp::LoadTensorRow(row_id_type row_id, const std::pair<std::string,
|
|||
}
|
||||
|
||||
void CelebAOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <CelebAOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -217,8 +217,6 @@ Status CifarOp::LoadBuffer(const std::vector<int64_t> &keys, std::unique_ptr<Dat
|
|||
}
|
||||
|
||||
void CifarOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <CifarOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -311,8 +311,6 @@ Status ClueOp::WorkerEntry(int32_t worker_id) {
|
|||
|
||||
// A print method typically used for debugging
|
||||
void ClueOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <ClueOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -188,8 +188,6 @@ Status CocoOp::operator()() {
|
|||
}
|
||||
|
||||
void CocoOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <CocoOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -512,8 +512,6 @@ Status CsvOp::WorkerEntry(int32_t worker_id) {
|
|||
|
||||
// A print method typically used for debugging
|
||||
void CsvOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <CsvOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -61,8 +61,6 @@ GeneratorOp::GeneratorOp(py::function generator_function, std::vector<std::strin
|
|||
GeneratorOp::~GeneratorOp() { this->Dealloc(); }
|
||||
|
||||
void GeneratorOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <GeneratorOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
|
@ -228,8 +228,6 @@ Status ImageFolderOp::LoadBuffer(const std::vector<int64_t> &keys, std::unique_p
|
|||
}
|
||||
|
||||
void ImageFolderOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <ImageFolderOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -217,8 +217,6 @@ Status ManifestOp::LoadBuffer(const std::vector<int64_t> &keys, std::unique_ptr<
|
|||
}
|
||||
|
||||
void ManifestOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <ManifestOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -196,8 +196,6 @@ MindRecordOp::~MindRecordOp() {}
|
|||
|
||||
// A print method typically used for debugging
|
||||
void MindRecordOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <MindRecordOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -181,8 +181,6 @@ Status MnistOp::LoadBuffer(const std::vector<int64_t> &keys, std::unique_ptr<Dat
|
|||
}
|
||||
|
||||
void MnistOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <MnistOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -91,8 +91,6 @@ RandomDataOp::RandomDataOp(int32_t num_workers, int32_t op_connector_size, int64
|
|||
|
||||
// A print method typically used for debugging
|
||||
void RandomDataOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <RandomDataOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -98,8 +98,6 @@ TextFileOp::TextFileOp(int32_t num_workers, int64_t rows_per_buffer, int64_t tot
|
|||
|
||||
// A print method typically used for debugging
|
||||
void TextFileOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <TextFileOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -158,8 +158,6 @@ TFReaderOp::TFReaderOp(int32_t num_workers, int32_t worker_connector_size, int64
|
|||
|
||||
// A print method typically used for debugging
|
||||
void TFReaderOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <TFReaderOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -166,8 +166,6 @@ Status VOCOp::operator()() {
|
|||
}
|
||||
|
||||
void VOCOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <VOCOp>:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
ParallelOp::Print(out, show_all);
|
||||
|
|
|
@ -53,8 +53,6 @@ TakeOp::TakeOp(int32_t count, int32_t op_connector_size)
|
|||
|
||||
// A print method typically used for debugging
|
||||
void TakeOp::Print(std::ostream &out, bool show_all) const {
|
||||
// Always show the id and name as first line regardless if this summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
|
@ -208,8 +208,6 @@ Status ZipOp::drainPipeline() {
|
|||
// A function that prints info about the Operator
|
||||
void ZipOp::Print(std::ostream &out, // In: The output stream to print to
|
||||
bool show_all) const { // In: T/F if it should print everything
|
||||
// Always show the id and name as first line regardless if this is summary or detailed print
|
||||
out << "(" << std::setw(2) << operator_id_ << ") <" << Name() << ">:";
|
||||
if (!show_all) {
|
||||
// Call the super class for displaying any common 1-liner info
|
||||
PipelineOp::Print(out, show_all);
|
||||
|
|
Loading…
Reference in New Issue