This commit is contained in:
2026-07-08 10:07:39 +02:00
parent eb8060fc05
commit a118a975c1
20 changed files with 287 additions and 22 deletions

View File

@@ -24,18 +24,7 @@ class Model(ABC):
pass
'''
Have to have a new param here as mode, for example it would be base, or retrain
param mode = "base" or "retrain"
that way I can save time it takes to train and retrain.
file would be solved with Util functions
log_file = Path(f"reports/{mode}/{self.__class__.__name__}/time_metrics.txt")
Util._initialize_log_file(log_file):
strt = time.perf_counter()
end = time.perf_counter()
and then save logs
execution_time = end -strt
Util.log_metric(log_file, execution_time: float):
'''
def train(self, epochs, loader, rate, mode = "retrain"):
criterion = nn.CrossEntropyLoss()