diff options
author | Kevin Petit <kevin.petit@arm.com> | 2024-01-23 19:09:40 +0000 |
---|---|---|
committer | Kevin Petit <kevin.petit@arm.com> | 2024-01-23 19:10:11 +0000 |
commit | 56d9ecef3b85e4d0cf87d25d38e1772bff1f4a1b (patch) | |
tree | 30fb4044d2c037c6d329b6f4c43a15e32ad6c829 /pseudocode/operators/tables/SIGMOID.tosac | |
parent | f9fcb61e143bde28fd14bcbbdb97120f5afdbfb7 (diff) | |
download | specification-56d9ecef3b85e4d0cf87d25d38e1772bff1f4a1b.tar.gz |
pseudocode: replace C-style casts with static_cast
Change-Id: Ic362e5cbc607d1b7560c09326fcebcba606454ce
Signed-off-by: Kevin Petit <kevin.petit@arm.com>
Diffstat (limited to 'pseudocode/operators/tables/SIGMOID.tosac')
-rw-r--r-- | pseudocode/operators/tables/SIGMOID.tosac | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pseudocode/operators/tables/SIGMOID.tosac b/pseudocode/operators/tables/SIGMOID.tosac index dad1e1d..c13d5ee 100644 --- a/pseudocode/operators/tables/SIGMOID.tosac +++ b/pseudocode/operators/tables/SIGMOID.tosac @@ -8,7 +8,7 @@ // by a licensing agreement from ARM Limited. int16_t sigmoid_reference(int16_t x) { // input x range is -256 to + 256 inclusive - fp64_t v = (fp64_t)x / (fp64_t)16; + fp64_t v = static_cast<fp64_t>(x) / static_cast<fp64_t>(16); v = 1.0/(1.0 + exp(-v)); return round_to_nearest_int(32768.0 * v); } |