mirror of
https://github.com/NicolasBohn/NexQuant.git
synced 2026-08-05 11:07:43 +00:00
example workflow code for model implementation (#17)
* upload example code for model implementation * Refactor Model Implement * add export --------- Co-authored-by: Young <afe.young@gmail.com>
This commit is contained in:
@@ -1,13 +1,21 @@
|
||||
from abc import ABC, abstractmethod
|
||||
from typing import List
|
||||
from typing import List, Sequence
|
||||
|
||||
from rdagent.core.task import (
|
||||
BaseTask,
|
||||
TaskImplementation,
|
||||
)
|
||||
|
||||
class TaskGenerator(ABC):
|
||||
@abstractmethod
|
||||
def generate(self, *args, **kwargs) -> List[TaskImplementation]:
|
||||
def generate(self, task_l: Sequence[BaseTask]) -> Sequence[TaskImplementation]:
|
||||
"""
|
||||
Task Generator should take in a sequence of tasks.
|
||||
|
||||
Because the schedule of different tasks is crucial for the final performance
|
||||
due to it affects the learning process.
|
||||
|
||||
"""
|
||||
raise NotImplementedError("generate method is not implemented.")
|
||||
|
||||
def collect_feedback(self, feedback_obj_l: List[object]):
|
||||
|
||||
Reference in New Issue
Block a user