mirror of
https://github.com/microsoft/qlib.git
synced 2026-07-03 02:50:58 +08:00
28 lines
654 B
Python
28 lines
654 B
Python
import abc
|
|
import typing
|
|
|
|
|
|
class TaskGen(metaclass=abc.ABCMeta):
|
|
@abc.abstractmethod
|
|
def __call__(self, *args, **kwargs) -> typing.List[dict]:
|
|
"""
|
|
generate
|
|
|
|
Parameters
|
|
----------
|
|
args, kwargs:
|
|
The info for generating tasks
|
|
Example 1):
|
|
input: a specific task template
|
|
output: rolling version of the tasks
|
|
Example 2):
|
|
input: a specific task template
|
|
output: a set of tasks with different losses
|
|
|
|
Returns
|
|
-------
|
|
typing.List[dict]:
|
|
A list of tasks
|
|
"""
|
|
pass
|