A thought about making implementation easier, specifically for very simple transformations/functions.
The general idea is to make a decorator or class that can take in a function and "modularize" it without worrying about boilerplate code for things like configurations, saving/loading.
I'm not exactly sure how this would work, but if you have a simple transformation or plot, you could create a module with something like
In this example, the configuration would simply be the kwargs passed to my_transform and the run() or transform() function in the module class would simply call my_transform(). I'm not sure if this can really be done in a decorator, or if it needs to be a special class that takes a function for the __init__()...
This might not be a good idea, just wanted to document it somewhere...
A thought about making implementation easier, specifically for very simple transformations/functions.
The general idea is to make a decorator or class that can take in a function and "modularize" it without worrying about boilerplate code for things like configurations, saving/loading.
I'm not exactly sure how this would work, but if you have a simple transformation or plot, you could create a module with something like
In this example, the configuration would simply be the kwargs passed to my_transform and the
run()
ortransform()
function in the module class would simply callmy_transform()
. I'm not sure if this can really be done in a decorator, or if it needs to be a special class that takes a function for the__init__()
...This might not be a good idea, just wanted to document it somewhere...