m3dev / gokart

Gokart solves reproducibility, task dependencies, constraints of good code, and ease of use for Machine Learning Pipeline.
https://gokart.readthedocs.io/en/latest/
MIT License
318 stars 57 forks source link

Bugfix: task_info should accept generator #279

Closed Hi-king closed 2 years ago

Hi-king commented 2 years ago

solves #278

TaskOnKart.requires() can be written as generator

Task:
  def requires():
     for ... in ...:
        yield SubTas()

but task_info_formatter is too strict requires() to be List or Tuple.

This PR loosen the constraint to request typing.Iterable.

e-mon commented 2 years ago

LGTM

hirosassa commented 2 years ago

LGTM👍Thanks!

mski-iksm commented 2 years ago

@Hi-king LGTM! Thank you for cool bugfix!