forked from numpy/numpy
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request numpy#14048 from r-devulap/transcendental-accuracy…
…-tests BUG, TEST: Adding validation test suite to validate float32 exp
- Loading branch information
Showing
7 changed files
with
1,787 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
Steps to validate transcendental functions: | ||
1) Add a file 'umath-validation-set-<ufuncname>', where ufuncname is name of | ||
the function in NumPy you want to validate | ||
2) The file should contain 4 columns: dtype,input,expected output,ulperror | ||
a. dtype: one of np.float16, np.float32, np.float64 | ||
b. input: floating point input to ufunc in hex. Example: 0x414570a4 | ||
represents 12.340000152587890625 | ||
c. expected output: floating point output for the corresponding input in hex. | ||
This should be computed using a high(er) precision library and then rounded to | ||
same format as the input. | ||
d. ulperror: expected maximum ulp error of the function. This | ||
should be same across all rows of the same dtype. Otherwise, the function is | ||
tested for the maximum ulp error among all entries of that dtype. | ||
3) Add file umath-validation-set-<ufuncname> to the test file test_umath_accuracy.py | ||
which will then validate your ufunc. |
Oops, something went wrong.