gagan3012 commited on
Commit
bd5eb97
·
1 Parent(s): 2e56d23
Files changed (2) hide show
  1. params.yml +1 -1
  2. src/models/model.py +6 -6
params.yml CHANGED
@@ -6,7 +6,7 @@ model_name: t5-small
6
  learning_rate: 1e-4
7
  epochs: 5
8
  source_dir: src
9
- model_dir: models/models/
10
  metric: rouge
11
  split: 0.02
12
  use_gpu: True
 
6
  learning_rate: 1e-4
7
  epochs: 5
8
  source_dir: src
9
+ model_dir: models
10
  metric: rouge
11
  split: 0.02
12
  use_gpu: True
src/models/model.py CHANGED
@@ -327,12 +327,12 @@ class Summarization:
327
  learning_rate=learning_rate, adam_epsilon=adam_epsilon, weight_decay=weight_decay
328
  )
329
 
330
- # MLlogger = MLFlowLogger(experiment_name="Summarization",
331
- # tracking_uri="https://dagshub.com/gagan3012/summarization.mlflow")\
332
 
333
- WandLogger = WandbLogger(project="summarization-dagshub")
334
 
335
- # logger = DAGsHubLogger(metrics_path='reports/training_metrics.txt')
336
 
337
  early_stop_callback = (
338
  [
@@ -351,7 +351,7 @@ class Summarization:
351
  gpus = -1 if use_gpu and torch.cuda.is_available() else 0
352
 
353
  trainer = Trainer(
354
- logger=[WandLogger],
355
  callbacks=early_stop_callback,
356
  max_epochs=max_epochs,
357
  gpus=gpus,
@@ -398,7 +398,7 @@ class Summarization:
398
 
399
  def save_model(
400
  self,
401
- model_dir="../../models"
402
  ):
403
  """
404
  Save model to dir
 
327
  learning_rate=learning_rate, adam_epsilon=adam_epsilon, weight_decay=weight_decay
328
  )
329
 
330
+ MLlogger = MLFlowLogger(experiment_name="Summarization",
331
+ tracking_uri="https://dagshub.com/gagan3012/summarization.mlflow")
332
 
333
+ # WandLogger = WandbLogger(project="summarization-dagshub")
334
 
335
+ #logger = DAGsHubLogger(metrics_path='reports/training_metrics.txt')
336
 
337
  early_stop_callback = (
338
  [
 
351
  gpus = -1 if use_gpu and torch.cuda.is_available() else 0
352
 
353
  trainer = Trainer(
354
+ logger=[MLlogger],
355
  callbacks=early_stop_callback,
356
  max_epochs=max_epochs,
357
  gpus=gpus,
 
398
 
399
  def save_model(
400
  self,
401
+ model_dir="models"
402
  ):
403
  """
404
  Save model to dir