Closed CasperStaahl closed 1 year ago
If we want to be even more crazy we define a little language such that you could write something like:
--pipline=warp_perspective->{remove_foreground, idealize_colors)->inpainter
But that is probably taking it too far 🙃
For backburner: If we expand on "color_idealize modes", use strategy pattern
Thought about this issue today, and had these two conversations with ChatGPT4:
My general idea is to remove the
Pipeline
class, and instead create a function:This function should make use of the monoid pattern from Haskell (see second conversation with GPT), plus another function. This means that `pipeline_builder would mainly use 4 different functions explained below to compose the pipeline.
append
andconcat
are self explanatory, Merge would take two Pipelines and and function for how they should merge (Image -> Image -> Image
) and return the mergedPipeline
. Split would split the pipeline in two.