Update _utils.py

This commit is contained in:
Daniel Han 2024-11-25 22:33:18 -08:00
commit 0b431c3317

View file

@ -1192,7 +1192,7 @@ for j, function in enumerate(functions):
try: exec(f"EMPTY_LOGITS.{function} = warn_logits_error", globals(), locals())
except: continue
else:
exec(f"def raise_{j}: print({function})", globals(), locals())
exec(f"def raise_{j}(*args, **kwargs): print({function})", globals(), locals())
try: exec(f"EMPTY_LOGITS.{function} = raise_{j}", globals(), locals())
except: continue
pass