@@ -52,7 +52,6 @@ def nanotron(
52
52
53
53
from lighteval .config .lighteval_config import FullNanotronConfig , LightEvalConfig
54
54
from lighteval .logging .evaluation_tracker import EvaluationTracker
55
- from lighteval .logging .hierarchical_logger import htrack_block
56
55
from lighteval .pipeline import ParallelismManager , Pipeline , PipelineParameters
57
56
from lighteval .utils .imports import NO_NANOTRON_ERROR_MSG , is_nanotron_available
58
57
from lighteval .utils .utils import EnvConfig
@@ -62,22 +61,20 @@ def nanotron(
62
61
if not is_nanotron_available ():
63
62
raise ImportError (NO_NANOTRON_ERROR_MSG )
64
63
65
- with htrack_block ("Load nanotron config" ):
66
- # Create nanotron config
67
- if not checkpoint_config_path .endswith (".yaml" ):
68
- raise ValueError ("The checkpoint path should point to a YAML file" )
69
-
70
- model_config = get_config_from_file (
71
- checkpoint_config_path ,
72
- config_class = Config ,
73
- model_config_class = None ,
74
- skip_unused_config_keys = True ,
75
- skip_null_keys = True ,
76
- )
77
-
78
- # We are getting an type error, because the get_config_from_file is not correctly typed,
79
- lighteval_config : LightEvalConfig = get_config_from_file (lighteval_config_path , config_class = LightEvalConfig ) # type: ignore
80
- nanotron_config = FullNanotronConfig (lighteval_config , model_config )
64
+ if not checkpoint_config_path .endswith (".yaml" ):
65
+ raise ValueError ("The checkpoint path should point to a YAML file" )
66
+
67
+ model_config = get_config_from_file (
68
+ checkpoint_config_path ,
69
+ config_class = Config ,
70
+ model_config_class = None ,
71
+ skip_unused_config_keys = True ,
72
+ skip_null_keys = True ,
73
+ )
74
+
75
+ # We are getting an type error, because the get_config_from_file is not correctly typed,
76
+ lighteval_config : LightEvalConfig = get_config_from_file (lighteval_config_path , config_class = LightEvalConfig ) # type: ignore
77
+ nanotron_config = FullNanotronConfig (lighteval_config , model_config )
81
78
82
79
evaluation_tracker = EvaluationTracker (
83
80
output_dir = lighteval_config .logging .output_dir ,
0 commit comments