Currently, logic to manage pipeline output directory is split and duplicated between Pipeline and PipelineOutput. To avoid potential drift between these two, we want to centralize the relevant logic. Specifically, we could update PipelineOutput to be a single authoritative interface to create, validate, and interact with output directory structure; and have Pipeline to use PipelineOutput for operations related to output directory. PipelineOutput could be relocated to pipeline.py along with Pipeline (its current location in models.py is confusing anyway).
Currently, logic to manage pipeline output directory is split and duplicated between
PipelineandPipelineOutput. To avoid potential drift between these two, we want to centralize the relevant logic. Specifically, we could updatePipelineOutputto be a single authoritative interface to create, validate, and interact with output directory structure; and havePipelineto usePipelineOutputfor operations related to output directory.PipelineOutputcould be relocated topipeline.pyalong withPipeline(its current location inmodels.pyis confusing anyway).