mirror of
https://github.com/webclinic017/drift.git
synced 2026-08-17 12:58:20 +00:00
fix(Evaluation): correlation test should work on a per asset level, not per model level (#142)
* fix(Evaluation): correlation test should work on a per asset level, not per model level * fix(Evaluation): correlations series initalized correctly * fix(Reporting): don't name the run after the incorrectly supposed model_type * fix(Reporting): put back send_report_to_wandb() into its original place * fix(CI): sending reports again in comment
This commit is contained in:
+4
-5
@@ -9,7 +9,7 @@ def launch_wandb(project_name:str, default_config:dict, sweep:bool=False):
|
||||
raise Exception("Wandb can not be initalized, the environment variable WANDB_API_KEY is missing (can also use .env file)")
|
||||
|
||||
elif sweep:
|
||||
wandb.init(project=project_name, config = default_config)
|
||||
wandb.init(project=project_name, config = default_config)
|
||||
return wandb
|
||||
else:
|
||||
wandb.init(project=project_name, config = default_config, reinit=True)
|
||||
@@ -33,13 +33,12 @@ def register_config_with_wandb(wandb: Optional[object], model_config:dict, train
|
||||
def send_report_to_wandb(results: pd.DataFrame, wandb:Optional[object], project_name: str, model_name: str):
|
||||
if wandb is None: return
|
||||
|
||||
run = wandb.init(project=project_name, config={"model_type": model_name}, reinit=True)
|
||||
wandb.run.name = model_name+ "-" + wandb.run.id
|
||||
wandb.run.save()
|
||||
run = wandb.run
|
||||
run.save()
|
||||
|
||||
mean_results = weighted_average(results, 'no_of_samples')
|
||||
for key, value in mean_results.iteritems():
|
||||
run.log({"model_type": model_name, key: value })
|
||||
run.log({ key: value })
|
||||
|
||||
run.finish()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user