phzwart / dlsia

Deep Learning for Scientific Image Analysis
Other
11 stars 2 forks source link

add a Trainer class #3

Closed xiaoyachong closed 5 months ago

xiaoyachong commented 5 months ago

I add a Trainer() class in DLSIA and integrate DVC with it.

In train_scripts.py, the Trainer() class is defined as:

class Trainer():
     def _ _init_ _(self, **args):
          # initialization
     def train_one_epoch(self, ...):

     def save_dvc(self, ...):

     def train_segmentation(self, ...):
           ...
           for epoch in range(NUM_EPOCHS):
                 ....
                 self.train_one_epoch()
                 self.save_dvc()
                 ....