fix bf16 check when preprocessing data (#1140)
Browse files
src/axolotl/utils/config.py
CHANGED
@@ -182,7 +182,11 @@ def validate_config(cfg):
|
|
182 |
if not cfg.bf16 and not cfg.bfloat16:
|
183 |
LOG.info("bf16 support detected, but not enabled for this configuration.")
|
184 |
else:
|
185 |
-
if
|
|
|
|
|
|
|
|
|
186 |
raise ValueError(
|
187 |
"bf16 requested, but AMP is not supported on this GPU. Requires Ampere series or above."
|
188 |
)
|
|
|
182 |
if not cfg.bf16 and not cfg.bfloat16:
|
183 |
LOG.info("bf16 support detected, but not enabled for this configuration.")
|
184 |
else:
|
185 |
+
if (
|
186 |
+
not cfg.merge_lora
|
187 |
+
and not cfg.is_preprocess
|
188 |
+
and (cfg.bf16 is True or cfg.bfloat16 is True)
|
189 |
+
):
|
190 |
raise ValueError(
|
191 |
"bf16 requested, but AMP is not supported on this GPU. Requires Ampere series or above."
|
192 |
)
|