onnxruntime/onnxruntime/test/shared_lib
Arne H Juul 605a84ffc9
remove unused and confusing float16 constants (#21999)
### Description
Remove unused and confusing special constants in MLFloat16 and BFloat16
types.

### Motivation and Context
While looking at adding a specialization for std::numeric_limits for the
16-bit floating point types, I found that there are various special
constants in those types that are confusing or just wrong.

MLFLoat16::Epsilon is not an epsilon at all, but approximates "e". Looks
like a copy-paste bug.
BFloat16::Epsilon does not correspond to `numeric_limits::epsilon()`,
nor even to the C# Float.Epsilon.
Instead, it corresponds to `numeric_limits::min()` which was really
confusing to me.

The "MinValue" constants does correspond to the C# `Float.MinValue`
constant, but this is C++ so it would be better renamed to "LowestValue"
since it corresponds to `numeric_limits::lowest()`. As it was unused
except for some unit tests I have replaced it with the equivalent
`MaxValue.Negate()` here.

There's also an unused `kSignaling_NaNBits` constant which is just wrong
(has the same value as `kPositiveInfinityBits` instead of a NaN).
2024-09-05 22:00:48 -07:00
..
cuda_ops.cu
custom_op_utils.cc Create a new C API KernelContext_GetAllocator() for Custom Op scenario (#15591) 2023-04-23 21:54:35 -07:00
custom_op_utils.h Update ruff and clang-format versions (#21479) 2024-07-24 11:50:11 -07:00
fns_candy_style_transfer.c
onnx_protobuf.h
rocm_ops.hip EP context for custom op (#16454) 2023-08-16 13:03:40 -07:00
test_allocator.cc Run clang-format in CI (#15524) 2023-04-18 09:26:58 -07:00
test_fixture.h Run clang-format in CI (#15524) 2023-04-18 09:26:58 -07:00
test_inference.cc Remove references to the outdated CUDA EP factory method (#21549) 2024-07-29 21:59:16 -07:00
test_io_types.cc Run clang-format in CI (#15524) 2023-04-18 09:26:58 -07:00
test_model_loading.cc Remove references to the outdated CUDA EP factory method (#21549) 2024-07-29 21:59:16 -07:00
test_nontensor_types.cc remove unused and confusing float16 constants (#21999) 2024-09-05 22:00:48 -07:00
test_ort_format_models.cc Enable Address Sanitizer in CI (#19073) 2024-01-12 07:24:40 -08:00
test_run_options.cc
test_session_options.cc Add new SessionOptions config entry to disable specific transformers and rules (#20135) 2024-04-02 16:33:05 -07:00
utils.cc
utils.h