generated from felixm/defaultpy
Start to implement prediction
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
import logging
|
||||
import sys
|
||||
|
||||
from rich.logging import RichHandler
|
||||
|
||||
from toldg.process import process_csv_files, process_ldg_files
|
||||
from toldg.train import train
|
||||
from toldg.utils import load_config, remove_if_exists, write_meta
|
||||
|
||||
|
||||
@@ -18,10 +20,13 @@ def init_logging():
|
||||
def main():
|
||||
init_logging()
|
||||
config = load_config()
|
||||
remove_if_exists(config.output_file)
|
||||
write_meta(config)
|
||||
process_ldg_files(config)
|
||||
process_csv_files(config)
|
||||
if len(sys.argv) > 2 and sys.argv[2] == "train":
|
||||
train(config)
|
||||
else:
|
||||
remove_if_exists(config.output_file)
|
||||
write_meta(config)
|
||||
process_ldg_files(config)
|
||||
process_csv_files(config)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
||||
Reference in New Issue
Block a user