Skip to content

Commit

Permalink
Send warning to stderr to avoid messing up module printing
Browse files Browse the repository at this point in the history
  • Loading branch information
hunhoffe committed Oct 4, 2024
1 parent b19c326 commit 58708ac
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion python/extras/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ def __init__(*args, **kwargs):
except:
# Numpy doesn't support bfloat16 at this time. Using hacky extension of np.float16 as a placeholder, for now.
print(
"Warning! bfloat16 python package not available, so using placeholder bfloat16 type"
"Warning! bfloat16 python package not available, so using placeholder bfloat16 type",
file=sys.stderr,
)
bfloat16 = _pseudo_bfloat16

Expand Down

0 comments on commit 58708ac

Please sign in to comment.