protected override StageResult Init() { Contract.Requires(InputFile != null && TrainingFile != null && TestFile != null); if (!InputFile.CheckExistsAndReportError(L)) { return(StageResult.INPUT_ERROR); } if (TrainingFile.Exists && !OverwriteOutputFile) { Error("The training data file {0} exists but the overwrite option was not specified.", TrainingFile.FullName); return(StageResult.OUTPUT_ERROR); } else if (TrainingFile.Exists) { Warn("Training data file {0} exists and will be overwritten.", TrainingFile.FullName); } if (TestFile.Exists && !OverwriteOutputFile) { Error("The test data file {0} exists but the overwrite option was not specified.", TestFile.FullName); return(StageResult.OUTPUT_ERROR); } else if (TestFile.Exists) { Warn("Test data file {0} exists and will be overwritten.", TestFile.FullName); } return(StageResult.SUCCESS); }
protected override StageResult Init() { if (!InputFile.CheckExistsAndReportError(L)) { return(StageResult.INPUT_ERROR); } WriterOptions.Add("RecordLimitSize", RecordLimitSize); return(StageResult.SUCCESS); }