Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

max_finite_val default value #295

Open
haowang5128 opened this issue Jul 3, 2024 · 0 comments
Open

max_finite_val default value #295

haowang5128 opened this issue Jul 3, 2024 · 0 comments

Comments

@haowang5128
Copy link

Hi,
I notice that convert_np_to_float16(np_array, min_positive_val=1e-7, max_finite_val=1e4) has 1e4 as the default value for max_finite_val, however the max value for float16 is 65504. Onnxruntime repo also has 65504 for their version of convert_np_to_float16.
https://github.com/microsoft/onnxruntime/blob/main/onnxruntime/python/tools/transformers/float16.py#L40

Could someone please to explain to me why setting 1e4 as max_finite_val?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant