-
-
Save chkoar/09e9070a03a3d6d3a68b0dc3407cdd5c to your computer and use it in GitHub Desktop.
Target formatter for Prefect
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from dask.base import tokenize | |
class TargetFormatter: | |
def __init__(self, *args): | |
self.args = args | |
def __call__(self, **kwargs): | |
args = self.args + ("task_name",) | |
ret = [kwargs.get(x) for x in args] | |
return tokenize(ret) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment