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

feat(docs): add half-precision training section in using_simulator docs #678

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

PabloCarmona
Copy link
Collaborator

Related issues

#623
#677

Description

  • New section in docs to explain how configure half-precision training.
  • A new example with code to enable half-precision training.

@PabloCarmona PabloCarmona added documentation Improvements or additions to documentation enhancement New feature or request labels Aug 12, 2024
@PabloCarmona PabloCarmona self-assigned this Aug 12, 2024
jubueche
jubueche previously approved these changes Aug 12, 2024
Signed-off-by: Pablo Carmona Gonzalez <pablocarmonagonzalez@gmail.com>
Signed-off-by: Pablo Carmona Gonzalez <pablocarmonagonzalez@gmail.com>
@PabloCarmona PabloCarmona marked this pull request as ready for review August 14, 2024 14:18
@PabloCarmona
Copy link
Collaborator Author

@coreylammie @anu-pub Take a look at it and let me know what you think, thanks!

@jubueche
Copy link
Collaborator

Compilation is currently not working for the half precision type. To reproduce:
Torch version and CUDA: 2.3.0+cu121
AIHWKIT: Current master (6bcc9d6cd9e6210f113a01fa49b16dad7e09761d).
Compilation script:

export COMPILER=/gpfs/u/software/npl/gcc/9.3.0/1/
export CXX=$COMPILER/bin/g++
export CC=$COMPILER/bin/gcc
export MKLROOT=$CONDA_PREFIX
export LD_LIBRARY_PATH=$COMPILER/lib64:$COMPILER/lib:${LD_LIBRARY_PATH}
export CUDA_VERSION=12.1
export CUDA_HOME=/usr/local/cuda-${CUDA_VERSION}
export CUDA_TOOLKIT_ROOT_DIR=${CUDA_HOME}
export CUDA_LIB_PATH=${CUDA_HOME}/lib
export CUDA_INCLUDE_DIRS=${CUDA_HOME}/include
export RPU_CUDA_ARCHITECTURS="70;80"
export PATH=${CUDA_HOME}/bin:$COMPILER/bin:${PATH}
export CMAKE_ROOT=/usr/lib64/cmake/
export CMAKE_PREFIX_PATH=$CONDA_PREFIX
cd ~/scratch/public_aihwkit
make build_inplace_cuda flags="-DRPU_CUDA_ARCHITECTURES='70;80' -DRPU_USE_FP16=ON"

Error:

[1/80] Building CXX object CMakeFiles/RPU_CPU.dir/src/rpucuda/dense_bit_line_maker.cpp.o
FAILED: CMakeFiles/RPU_CPU.dir/src/rpucuda/dense_bit_line_maker.cpp.o 
/gpfs/u/software/npl/gcc/9.3.0/1/bin/g++ -DRPU_TORCH_CUDA_BUFFERS -DRPU_USE_CUDA -DRPU_USE_FP16 -DRPU_USE_MKL -DRPU_USE_WITH_TORCH -D_GLIBCXX_USE_CXX11_ABI=0 -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/include/python3.10 -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/pybind11/include -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/torch/include -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/torch/include/torch/csrc/api/include -isystem /gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/include -isystem /usr/local/cuda-12.1/targets/x86_64-linux/include -isystem /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda -isystem /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/cuda -fopenmp -Wall -Wno-narrowing -Wno-strict-overflow -g -std=gnu++17 -fPIC -MD -MT CMakeFiles/RPU_CPU.dir/src/rpucuda/dense_bit_line_maker.cpp.o -MF CMakeFiles/RPU_CPU.dir/src/rpucuda/dense_bit_line_maker.cpp.o.d -o CMakeFiles/RPU_CPU.dir/src/rpucuda/dense_bit_line_maker.cpp.o -c /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp: In instantiation of ‘int* RPU::DenseBitLineMaker<T>::makeCoincidences(const T*, int, int&, const T*, int, int&, RPU::RNG<T>*, T, T, const RPU::PulsedUpdateMetaParameter<T>&) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:365:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:286:5: error: conversion from ‘int’ to ‘__half’ is ambiguous
  286 |   T A = 0;
      |     ^
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:287:5: error: conversion from ‘int’ to ‘__half’ is ambiguous
  287 |   T B = 0;
      |     ^
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp: In instantiation of ‘void RPU::DenseBitLineMaker<T>::generateCoincidences(int*, const int*, int, const int*, int, int) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:365:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:192:10: error: call of overloaded ‘__half(const int&)’ is ambiguous
  192 |   T bl = (T)BL;
      |          ^~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:195:12: error: call of overloaded ‘__half(const int&)’ is ambiguous
  195 |     T dc = (T)d_counts[i];
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:197:10: error: no match for ‘operator/=’ (operand types are ‘__half’ and ‘__half’)
  197 |       dc /= bl;
      |       ~~~^~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:200:55: error: call of overloaded ‘__half(const int&)’ is ambiguous
  200 |         coincidences[idx++] = (int)RPU_ROUNDFUNF(dc * (T)x_counts[j]);
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp: In instantiation of ‘void RPU::DenseBitLineMaker<T>::generateCoincidencesDetI(int*, const T*, int, const T*, int, int) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:365:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:257:10: error: no match for ‘operator*=’ (operand types are ‘__half’ and ‘const int’)
  257 |       dc *= BL;
      |       ~~~^~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp: In instantiation of ‘void RPU::DenseBitLineMaker<T>::generateCountsMean(int*, const T*, int, int, int&, T, RPU::RNG<T>*, int, T, bool, T) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:365:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:165:29: error: operands to ?: have different types ‘float’ and ‘const __half’
  165 |     T v_value = lr < (T)0.0 ? -v[j_v] : v[j_v];
      |                 ~~~~~~~~~~~~^~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:165:29: note:   and each type can be converted to the other
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:168:31: error: no matching function for call to ‘getDiscretizedValue(float, const __half&, const bool&, RPU::RNG<__half>&)’
  168 |     T pp = getDiscretizedValue((T)fabsf((T)v_value) * p, res, sto_round, *rng);
      |            ~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:178:10: note: candidate: ‘template<class T, class RNGClass> T RPU::getDiscretizedValue(T, T, bool, RNGClass&)’
  178 | inline T getDiscretizedValue(T value, T res, bool sto_round, RNGClass &rng) {
      |          ^~~~~~~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:178:10: note:   template argument deduction/substitution failed:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:168:31: note:   deduced conflicting types for parameter ‘T’ (‘float’ and ‘__half’)
  168 |     T pp = getDiscretizedValue((T)fabsf((T)v_value) * p, res, sto_round, *rng);
      |            ~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:176:45: error: call of overloaded ‘__half(const int&)’ is ambiguous
  176 |     int ntimes = MAX(MIN((int)RPU_ROUNDFUNF((T)BL * pp), BL), 0);
      |                                             ^~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:22: note: in definition of macro ‘MAX’
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                      ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:176:22: note: in expansion of macro ‘MIN’
  176 |     int ntimes = MAX(MIN((int)RPU_ROUNDFUNF((T)BL * pp), BL), 0);
      |                      ^~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:176:45: error: call of overloaded ‘__half(const int&)’ is ambiguous
  176 |     int ntimes = MAX(MIN((int)RPU_ROUNDFUNF((T)BL * pp), BL), 0);
      |                                             ^~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:22: note: in definition of macro ‘MAX’
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                      ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:176:22: note: in expansion of macro ‘MIN’
  176 |     int ntimes = MAX(MIN((int)RPU_ROUNDFUNF((T)BL * pp), BL), 0);
      |                      ^~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:176:45: error: call of overloaded ‘__half(const int&)’ is ambiguous
  176 |     int ntimes = MAX(MIN((int)RPU_ROUNDFUNF((T)BL * pp), BL), 0);
      |                                             ^~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:35: note: in definition of macro ‘MAX’
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                   ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:176:22: note: in expansion of macro ‘MIN’
  176 |     int ntimes = MAX(MIN((int)RPU_ROUNDFUNF((T)BL * pp), BL), 0);
      |                      ^~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:176:45: error: call of overloaded ‘__half(const int&)’ is ambiguous
  176 |     int ntimes = MAX(MIN((int)RPU_ROUNDFUNF((T)BL * pp), BL), 0);
      |                                             ^~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:35: note: in definition of macro ‘MAX’
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                   ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:176:22: note: in expansion of macro ‘MIN’
  176 |     int ntimes = MAX(MIN((int)RPU_ROUNDFUNF((T)BL * pp), BL), 0);
      |                      ^~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp: In instantiation of ‘void RPU::DenseBitLineMaker<T>::generateDetImplicit(T*, const T*, int, int, int&, T, RPU::RNG<T>*, int, T, bool, T) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:365:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:231:29: error: operands to ?: have different types ‘float’ and ‘const __half’
  231 |     T v_value = lr < (T)0.0 ? -v[j_v] : v[j_v];
      |                 ~~~~~~~~~~~~^~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:231:29: note:   and each type can be converted to the other
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:241:38: error: operands to ?: have different types ‘__half’ and ‘float’
  241 |     pcounts[j] = (v_value >= (T)0.0) ? pp : -pp;
      |                  ~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/dense_bit_line_maker.cpp:241:38: note:   and each type can be converted to the other
[2/80] Building CXX object CMakeFiles/RPU_CPU.dir/src/rpucuda/math_util.cpp.o
FAILED: CMakeFiles/RPU_CPU.dir/src/rpucuda/math_util.cpp.o 
/gpfs/u/software/npl/gcc/9.3.0/1/bin/g++ -DRPU_TORCH_CUDA_BUFFERS -DRPU_USE_CUDA -DRPU_USE_FP16 -DRPU_USE_MKL -DRPU_USE_WITH_TORCH -D_GLIBCXX_USE_CXX11_ABI=0 -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/include/python3.10 -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/pybind11/include -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/torch/include -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/torch/include/torch/csrc/api/include -isystem /gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/include -isystem /usr/local/cuda-12.1/targets/x86_64-linux/include -isystem /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda -isystem /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/cuda -fopenmp -Wall -Wno-narrowing -Wno-strict-overflow -g -std=gnu++17 -fPIC -MD -MT CMakeFiles/RPU_CPU.dir/src/rpucuda/math_util.cpp.o -MF CMakeFiles/RPU_CPU.dir/src/rpucuda/math_util.cpp.o.d -o CMakeFiles/RPU_CPU.dir/src/rpucuda/math_util.cpp.o -c /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.cpp
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.cpp: In function ‘void RPU::math::scal(int, T, T*, int) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.cpp:171:12: error: no match for ‘operator*=’ (operand types are ‘half_t’ {aka ‘__half’} and ‘const half_t’ {aka ‘const __half’})
  171 |     X[i_x] *= alpha;
      |     ~~~~~~~^~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.cpp: In function ‘T RPU::math::nrm2(int, const T*, int) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.cpp:192:15: error: no match for ‘operator+=’ (operand types are ‘half_t’ {aka ‘__half’} and ‘float’)
  192 |     nrm_value += x * x;
      |     ~~~~~~~~~~^~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.cpp: In instantiation of ‘void RPU::math::makeBias(T*, const T*, int, int, bool) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.cpp:396:90:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.cpp:375:24: error: call of overloaded ‘__half(int)’ is ambiguous
  375 |       x_with_bias[i] = (T)1;
      |                        ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
[3/80] Building CXX object CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu_dynamic_transfer_device.cpp.o
FAILED: CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu_dynamic_transfer_device.cpp.o 
/gpfs/u/software/npl/gcc/9.3.0/1/bin/g++ -DRPU_TORCH_CUDA_BUFFERS -DRPU_USE_CUDA -DRPU_USE_FP16 -DRPU_USE_MKL -DRPU_USE_WITH_TORCH -D_GLIBCXX_USE_CXX11_ABI=0 -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/include/python3.10 -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/pybind11/include -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/torch/include -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/torch/include/torch/csrc/api/include -isystem /gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/include -isystem /usr/local/cuda-12.1/targets/x86_64-linux/include -isystem /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda -isystem /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/cuda -fopenmp -Wall -Wno-narrowing -Wno-strict-overflow -g -std=gnu++17 -fPIC -MD -MT CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu_dynamic_transfer_device.cpp.o -MF CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu_dynamic_transfer_device.cpp.o.d -o CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu_dynamic_transfer_device.cpp.o -c /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h: In instantiation of ‘void RPU::DynamicTransferRPUDeviceMetaParameter<T>::initDefaults() [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:103:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:67:46: error: ambiguous overload for ‘operator=’ (operand types are ‘__half’ and ‘bool’)
   67 |   void initDefaults() { this->in_chop_random = false; };
      |                         ~~~~~~~~~~~~~~~~~~~~~^~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:218:33: note: candidate: ‘__half& __half::operator=(float)’
  218 |     __CUDA_HOSTDEVICE__ __half &operator=(const float f) { __x = __float2half(f).__x; return *this; }
      |                                 ^~~~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:221:33: note: candidate: ‘__half& __half::operator=(double)’
  221 |     __CUDA_HOSTDEVICE__ __half &operator=(const double f) { __x = __double2half(f).__x; return *this; }
      |                                 ^~~~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half& __half::operator=(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half& __half::operator=(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp: In instantiation of ‘void RPU::DynamicTransferRPUDevice<T>::readAndUpdate(int, int, T, const T*, int, T, int, int) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:515:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:257:59: error: call of overloaded ‘__half(const unsigned int&)’ is ambiguous
  257 |   const T sample_momentum = (T)MIN(par.tail_weightening / (T)n_samples, (T)1.0);
      |                                                           ^~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:22: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                      ^
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:257:59: error: call of overloaded ‘__half(const unsigned int&)’ is ambiguous
  257 |   const T sample_momentum = (T)MIN(par.tail_weightening / (T)n_samples, (T)1.0);
      |                                                           ^~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:35: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                                   ^
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:268:21: error: call of overloaded ‘__half(const unsigned int&)’ is ambiguous
  268 |     lr_scale /= MIN((T)current_sample, (T)1.0 / from_weight_granularity);
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:22: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                      ^
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:268:21: error: call of overloaded ‘__half(const unsigned int&)’ is ambiguous
  268 |     lr_scale /= MIN((T)current_sample, (T)1.0 / from_weight_granularity);
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:35: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                                   ^
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:272:18: error: call of overloaded ‘__half(const int&)’ is ambiguous
  272 |   T buffer_cap = (T)max_steps * par.buffer_cap;
      |                  ^~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:304:45: error: operands to ?: have different types ‘float’ and ‘__half’
  304 |     dw = (in_chop != this->out_chopper_[j]) ? -dw : dw;
      |          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:304:45: note:   and each type can be converted to the other
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:305:11: error: no match for ‘operator+=’ (operand types are ‘__half’ and ‘float’)
  305 |     omega += dw * lr_scale;
      |     ~~~~~~^~~~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:311:15: error: no match for ‘operator*=’ (operand types are ‘__half’ and ‘const __half’)
  311 |         omega *= momentum;
      |         ~~~~~~^~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:313:15: error: no match for ‘operator-=’ (operand types are ‘__half’ and ‘float’)
  313 |         omega -= ((T)1.0 - momentum) * n_steps;
      |         ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: error: operands to ?: have different types ‘__half’ and ‘float’
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:22: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                      ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:315:23: note: in expansion of macro ‘MAX’
  315 |           omega = MIN(MAX(omega, -buffer_cap), buffer_cap);
      |                       ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: note:   and each type can be converted to the other
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:22: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                      ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:315:23: note: in expansion of macro ‘MAX’
  315 |           omega = MIN(MAX(omega, -buffer_cap), buffer_cap);
      |                       ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: error: operands to ?: have different types ‘__half’ and ‘float’
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:35: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                                   ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:315:23: note: in expansion of macro ‘MAX’
  315 |           omega = MIN(MAX(omega, -buffer_cap), buffer_cap);
      |                       ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: note:   and each type can be converted to the other
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:35: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                                   ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:315:23: note: in expansion of macro ‘MAX’
  315 |           omega = MIN(MAX(omega, -buffer_cap), buffer_cap);
      |                       ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp: In instantiation of ‘T RPU::DynamicTransferRPUDevice<T>::getPulseCountLearningRate(T, int, const RPU::PulsedUpdateMetaParameter<T>&) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:515:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:362:12: error: no match for ‘operator*=’ (operand types are ‘__half’ and ‘__half’)
  362 |   count_lr *= count_lr_scale_;
      |   ~~~~~~~~~^~~~~~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp: In instantiation of ‘void RPU::DynamicTransferRPUDevice<T>::populate(const RPU::DynamicTransferRPUDeviceMetaParameter<T>&, RPU::RealWorldRNG<T>*) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:515:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:181:3: error: conversion from ‘int’ to ‘const value_type’ {aka ‘const __half’} is ambiguous
  181 |   running_mean_.resize((size_t)this->size_, 0);
      |   ^~~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
In file included from /gpfs/u/software/npl/gcc/9.3.0/1/include/c++/9.3.0/vector:67,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:20,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/software/npl/gcc/9.3.0/1/include/c++/9.3.0/bits/stl_vector.h:954:54: note:   initializing argument 2 of ‘void std::vector<_Tp, _Alloc>::resize(std::vector<_Tp, _Alloc>::size_type, const value_type&) [with _Tp = __half; _Alloc = std::allocator<__half>; std::vector<_Tp, _Alloc>::size_type = long unsigned int; std::vector<_Tp, _Alloc>::value_type = __half]’
  954 |       resize(size_type __new_size, const value_type& __x)
      |                                    ~~~~~~~~~~~~~~~~~~^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:182:3: error: conversion from ‘int’ to ‘const value_type’ {aka ‘const __half’} is ambiguous
  182 |   past_mean_.resize((size_t)this->size_, 0);
      |   ^~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
In file included from /gpfs/u/software/npl/gcc/9.3.0/1/include/c++/9.3.0/vector:67,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:20,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/software/npl/gcc/9.3.0/1/include/c++/9.3.0/bits/stl_vector.h:954:54: note:   initializing argument 2 of ‘void std::vector<_Tp, _Alloc>::resize(std::vector<_Tp, _Alloc>::size_type, const value_type&) [with _Tp = __half; _Alloc = std::allocator<__half>; std::vector<_Tp, _Alloc>::size_type = long unsigned int; std::vector<_Tp, _Alloc>::value_type = __half]’
  954 |       resize(size_type __new_size, const value_type& __x)
      |                                    ~~~~~~~~~~~~~~~~~~^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:187:14: error: call of overloaded ‘__half(int)’ is ambiguous
  187 |   T period = (T)par.getInSize() * (T)fabsf(par.transfer_every) * (T)par.getNumInChopSamples();
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:187:66: error: call of overloaded ‘__half(unsigned int)’ is ambiguous
  187 |   T period = (T)par.getInSize() * (T)fabsf(par.transfer_every) * (T)par.getNumInChopSamples();
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: error: operands to ?: have different types ‘float’ and ‘__half’
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:22: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                      ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:193:11: note: in expansion of macro ‘MAX’
  193 |       MIN(MAX((w_max - weight_granularity) * par.experimental_feedback_target, weight_granularity),
      |           ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: note:   and each type can be converted to the other
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:22: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                      ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:193:11: note: in expansion of macro ‘MAX’
  193 |       MIN(MAX((w_max - weight_granularity) * par.experimental_feedback_target, weight_granularity),
      |           ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: error: operands to ?: have different types ‘float’ and ‘__half’
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:35: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                                   ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:193:11: note: in expansion of macro ‘MAX’
  193 |       MIN(MAX((w_max - weight_granularity) * par.experimental_feedback_target, weight_granularity),
      |           ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: note:   and each type can be converted to the other
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:35: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                                   ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:193:11: note: in expansion of macro ‘MAX’
  193 |       MIN(MAX((w_max - weight_granularity) * par.experimental_feedback_target, weight_granularity),
      |           ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:196:30: error: call of overloaded ‘__half(const int&)’ is ambiguous
  196 |   v[FEEDBACK_MOD] = period * (T)par.experimental_feedback_mod;
      |                              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h: In instantiation of ‘RPU::ChoppedTransferRPUDeviceMetaParameter<T>::ChoppedTransferRPUDeviceMetaParameter() [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:43:86:   required from ‘RPU::DynamicTransferRPUDeviceMetaParameter<T>::DynamicTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:103:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:31:5: error: conversion from ‘bool’ to ‘__half’ is ambiguous
   31 |   T in_chop_random = true;  // random or regular
      |     ^~~~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h: In instantiation of ‘RPU::ChoppedTransferRPUDeviceMetaParameter<T>::ChoppedTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:48:63:   required from ‘RPU::DynamicTransferRPUDeviceMetaParameter<T>::DynamicTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:103:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:31:5: error: conversion from ‘bool’ to ‘__half’ is ambiguous
   31 |   T in_chop_random = true;  // random or regular
      |     ^~~~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h: In instantiation of ‘RPU::ChoppedTransferRPUDeviceMetaParameter<T>::ChoppedTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:55:83:   required from ‘RPU::DynamicTransferRPUDeviceMetaParameter<T>::DynamicTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:103:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:31:5: error: conversion from ‘bool’ to ‘__half’ is ambiguous
   31 |   T in_chop_random = true;  // random or regular
      |     ^~~~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h: In instantiation of ‘RPU::IOMetaParameter<__half>::IOMetaParameter()’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:82:35:   required from ‘RPU::TransferRPUDeviceMetaParameter<T>::TransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:46:80:   required from ‘RPU::BufferedTransferRPUDeviceMetaParameter<T>::BufferedTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:45:87:   required from ‘RPU::ChoppedTransferRPUDeviceMetaParameter<T>::ChoppedTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:43:86:   required from ‘RPU::DynamicTransferRPUDeviceMetaParameter<T>::DynamicTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:103:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:86:16: error: call of overloaded ‘__half(int)’ is ambiguous
   86 |   T _out_res = (T)0;
      |                ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h: In instantiation of ‘constexpr RPU::PulsedUpdateMetaParameter<__half>::PulsedUpdateMetaParameter()’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:82:35:   required from ‘RPU::TransferRPUDeviceMetaParameter<T>::TransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:46:80:   required from ‘RPU::BufferedTransferRPUDeviceMetaParameter<T>::BufferedTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:45:87:   required from ‘RPU::ChoppedTransferRPUDeviceMetaParameter<T>::ChoppedTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:43:86:   required from ‘RPU::DynamicTransferRPUDeviceMetaParameter<T>::DynamicTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:103:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:267:11: error: call of overloaded ‘__half(int)’ is ambiguous
  267 |   T res = (T)0; // this is taken to be in the range 0..1 as positive and negative phases are done
      |           ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:270:22: error: call of overloaded ‘__half(int)’ is ambiguous
  270 |   T x_res_implicit = (T)0; // in case of implicit pulsing. Assumes range 0..1
      |                      ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:271:22: error: call of overloaded ‘__half(int)’ is ambiguous
  271 |   T d_res_implicit = (T)0;
      |                      ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h: In instantiation of ‘RPU::IOMetaParameter<__half>::IOMetaParameter()’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:84:54:   required from ‘RPU::TransferRPUDeviceMetaParameter<T>::TransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:51:56:   required from ‘RPU::BufferedTransferRPUDeviceMetaParameter<T>::BufferedTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:50:64:   required from ‘RPU::ChoppedTransferRPUDeviceMetaParameter<T>::ChoppedTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:48:63:   required from ‘RPU::DynamicTransferRPUDeviceMetaParameter<T>::DynamicTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:103:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:86:16: error: call of overloaded ‘__half(int)’ is ambiguous
   86 |   T _out_res = (T)0;
      |                ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h: In instantiation of ‘constexpr RPU::PulsedUpdateMetaParameter<__half>::PulsedUpdateMetaParameter()’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:84:54:   required from ‘RPU::TransferRPUDeviceMetaParameter<T>::TransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:51:56:   required from ‘RPU::BufferedTransferRPUDeviceMetaParameter<T>::BufferedTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:50:64:   required from ‘RPU::ChoppedTransferRPUDeviceMetaParameter<T>::ChoppedTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:48:63:   required from ‘RPU::DynamicTransferRPUDeviceMetaParameter<T>::DynamicTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:103:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:267:11: error: call of overloaded ‘__half(int)’ is ambiguous
  267 |   T res = (T)0; // this is taken to be in the range 0..1 as positive and negative phases are done
      |           ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:270:22: error: call of overloaded ‘__half(int)’ is ambiguous
  270 |   T x_res_implicit = (T)0; // in case of implicit pulsing. Assumes range 0..1
      |                      ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:271:22: error: call of overloaded ‘__half(int)’ is ambiguous
  271 |   T d_res_implicit = (T)0;
      |                      ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_device.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h: In instantiation of ‘constexpr RPU::DriftParameter<__half>::DriftParameter()’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:171:25:   required from ‘RPU::SimpleMetaParameter<T>::SimpleMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_simple_device.h:56:30:   required from ‘RPU::PulsedRPUDeviceMetaParameterBase<T>::PulsedRPUDeviceMetaParameterBase() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_vector_device.h:34:33:   required from ‘RPU::VectorRPUDeviceMetaParameter<T>::VectorRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:82:35:   required from ‘RPU::TransferRPUDeviceMetaParameter<T>::TransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:46:80:   required from ‘RPU::BufferedTransferRPUDeviceMetaParameter<T>::BufferedTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:45:87:   required from ‘RPU::ChoppedTransferRPUDeviceMetaParameter<T>::ChoppedTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:43:86:   required from ‘RPU::DynamicTransferRPUDeviceMetaParameter<T>::DynamicTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:103:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h:33:16: error: call of overloaded ‘__half(int)’ is ambiguous
   33 |   T wg_ratio = (T)1; // (wmax-wmin)/(gmax-gmin)
      |                ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_device.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h:34:16: error: call of overloaded ‘__half(int)’ is ambiguous
   34 |   T g_offset = (T)0; // gmin
      |                ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_device.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h:35:16: error: call of overloaded ‘__half(int)’ is ambiguous
   35 |   T w_offset = (T)0; // w(gmin), i.e. to what value gmin is mapped to in w-space
      |                ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:18,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_vector_device.h: In instantiation of ‘T RPU::VectorRPUDeviceMetaParameter<T>::calcWeightGranularity() const [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_vector_device.h:93:5:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_vector_device.h:96:67: error: call of overloaded ‘__half(std::vector<std::unique_ptr<RPU::PulsedRPUDeviceMetaParameterBase<__half>, std::default_delete<RPU::PulsedRPUDeviceMetaParameterBase<__half> > >, std::allocator<std::unique_ptr<RPU::PulsedRPUDeviceMetaParameterBase<__half>, std::default_delete<RPU::PulsedRPUDeviceMetaParameterBase<__half> > > > >::size_type)’ is ambiguous
   96 |       weight_granularity += vec_par[k]->calcWeightGranularity() / (T)vec_par.size();
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:18,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_vector_device.h: In instantiation of ‘T RPU::VectorRPUDeviceMetaParameter<T>::calcNumStates() const [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_vector_device.h:100:5:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_vector_device.h:103:51: error: call of overloaded ‘__half(std::vector<std::unique_ptr<RPU::PulsedRPUDeviceMetaParameterBase<__half>, std::default_delete<RPU::PulsedRPUDeviceMetaParameterBase<__half> > >, std::allocator<std::unique_ptr<RPU::PulsedRPUDeviceMetaParameterBase<__half>, std::default_delete<RPU::PulsedRPUDeviceMetaParameterBase<__half> > > > >::size_type)’ is ambiguous
  103 |       num_states += vec_par[k]->calcNumStates() / (T)vec_par.size();
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_chopped_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_dynamic_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
[4/80] Building CXX object CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu.cpp.o
FAILED: CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu.cpp.o 
/gpfs/u/software/npl/gcc/9.3.0/1/bin/g++ -DRPU_TORCH_CUDA_BUFFERS -DRPU_USE_CUDA -DRPU_USE_FP16 -DRPU_USE_MKL -DRPU_USE_WITH_TORCH -D_GLIBCXX_USE_CXX11_ABI=0 -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/include/python3.10 -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/pybind11/include -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/torch/include -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/torch/include/torch/csrc/api/include -isystem /gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/include -isystem /usr/local/cuda-12.1/targets/x86_64-linux/include -isystem /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda -isystem /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/cuda -fopenmp -Wall -Wno-narrowing -Wno-strict-overflow -g -std=gnu++17 -fPIC -MD -MT CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu.cpp.o -MF CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu.cpp.o.d -o CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu.cpp.o -c /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h: In instantiation of ‘constexpr RPU::DriftParameter<__half>::DriftParameter()’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:171:25:   required from ‘RPU::SimpleMetaParameter<T>::SimpleMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:217:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h:33:16: error: call of overloaded ‘__half(int)’ is ambiguous
   33 |   T wg_ratio = (T)1; // (wmax-wmin)/(gmax-gmin)
      |                ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h:34:16: error: call of overloaded ‘__half(int)’ is ambiguous
   34 |   T g_offset = (T)0; // gmin
      |                ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h:35:16: error: call of overloaded ‘__half(int)’ is ambiguous
   35 |   T w_offset = (T)0; // w(gmin), i.e. to what value gmin is mapped to in w-space
      |                ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h: In instantiation of ‘void RPU::DriftParameter<T>::printToStream(std::stringstream&) const [with T = __half; std::stringstream = std::basic_stringstream<char>]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:219:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h:80:21: error: call of overloaded ‘__half(int)’ is ambiguous
   80 |     if (wg_ratio != (T)1 || g_offset != (T)0 || w_offset != (T)0) {
      |                     ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h:80:41: error: call of overloaded ‘__half(int)’ is ambiguous
   80 |     if (wg_ratio != (T)1 || g_offset != (T)0 || w_offset != (T)0) {
      |                                         ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:17,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/weight_drifter.h:80:61: error: call of overloaded ‘__half(int)’ is ambiguous
   80 |     if (wg_ratio != (T)1 || g_offset != (T)0 || w_offset != (T)0) {
      |                                                             ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp: In instantiation of ‘void RPU::RPUSimple<T>::applyWeightUpdate(T*) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1765:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1447:10: error: no match for ‘operator+=’ (operand types are ‘__half’ and ‘__half’)
 1447 |     w[i] += dw;
      |     ~~~~~^~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp: In instantiation of ‘void RPU::RPUSimple<T>::decayWeights(T, bool) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1765:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1557:38: error: operands to ?: have different types ‘float’ and ‘__half’
 1557 |   T decay_rate = (lifetime > (T)1.0) ? ((T)1.0 / lifetime) : (T)0.0;
      |                  ~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1557:38: note:   and each type can be converted to the other
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1569:14: error: no match for ‘operator*=’ (operand types are ‘__half’ and ‘__half’)
 1569 |         w[i] *= (i % this->x_size_ == last_col) ? (T)1.0 : decay_scale;
      |         ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp: In instantiation of ‘void RPU::RPUSimple<T>::clipWeights(T) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1765:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: error: operands to ?: have different types ‘__half’ and ‘float’
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:22: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                      ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1594:18: note: in expansion of macro ‘MAX’
 1594 |       w[i] = MIN(MAX(w[i], -clip), clip);
      |                  ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: note:   and each type can be converted to the other
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:22: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                      ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1594:18: note: in expansion of macro ‘MAX’
 1594 |       w[i] = MIN(MAX(w[i], -clip), clip);
      |                  ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: error: operands to ?: have different types ‘__half’ and ‘float’
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:35: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                                   ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1594:18: note: in expansion of macro ‘MAX’
 1594 |       w[i] = MIN(MAX(w[i], -clip), clip);
      |                  ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: note:   and each type can be converted to the other
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                                ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:29:35: note: in definition of macro ‘MIN’
   29 | #define MIN(a, b) (((a) < (b)) ? (a) : (b))
      |                                   ^
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1594:18: note: in expansion of macro ‘MAX’
 1594 |       w[i] = MIN(MAX(w[i], -clip), clip);
      |                  ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp: In instantiation of ‘void RPU::RPUSimple<T>::diffuseWeights() [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1765:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1615:12: error: no match for ‘operator+=’ (operand types are ‘__half’ and ‘float’)
 1615 |       w[i] += diffusion * rng_->sampleGauss();
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp: In instantiation of ‘void RPU::RPUSimple<T>::diffuseWeightsPink() [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1765:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1686:27: error: call of overloaded ‘__half(int)’ is ambiguous
 1686 |     T last_noise_value = ((T)__builtin_popcountll(fls));
      |                          ~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1718:22: error: call of overloaded ‘__half(int)’ is ambiguous
 1718 |     T noise_value = ((T)__builtin_popcountll(fls));
      |                     ~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1720:10: error: no match for ‘operator+=’ (operand types are ‘__half’ and ‘float’)
 1720 |     w[j] += amp * (noise_value - last_noise_value);
      |     ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp: In instantiation of ‘void RPU::RPUSimple<T>::copyIndexedInput(T*, const T*, int, const int*, int, int, int, bool, int, const int*) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1765:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:893:33: error: call of overloaded ‘__half(int&)’ is ambiguous
  893 |                               ? (T)j_shifted
      |                                 ^~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:905:33: error: call of overloaded ‘__half(int&)’ is ambiguous
  905 |                               ? (T)j_shifted
      |                                 ^~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:925:33: error: call of overloaded ‘__half(int&)’ is ambiguous
  925 |                               ? (T)j_shifted
      |                                 ^~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:934:33: error: call of overloaded ‘__half(int&)’ is ambiguous
  934 |                               ? (T)j_shifted
      |                                 ^~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp: In instantiation of ‘void RPU::RPUSimple<T>::copyIndexedOutput(T*, const T*, int, const int*, int, int, int, bool, int, const int*) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1765:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:978:69: error: no match for ‘operator+=’ (operand types are ‘__half’ and ‘const __half’)
  978 |           out_tensor[(j_shifted - 2) + i_dim3 * output_matrix_size] += src_tensor[idx];
      |           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:989:68: error: no match for ‘operator+=’ (operand types are ‘__half’ and ‘const __half’)
  989 |           out_tensor[(j_shifted - 2) + i / M * output_matrix_size] += src_tensor[idx];
      |           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1007:69: error: no match for ‘operator+=’ (operand types are ‘__half’ and ‘const __half’)
 1007 |           out_tensor[(j_shifted - 2) + i_dim3 * output_matrix_size] += src_tensor[idx];
      |           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu.cpp:1014:70: error: no match for ‘operator+=’ (operand types are ‘__half’ and ‘const __half’)
 1014 |           out_tensor[(j_shifted - 2) + idx / M * output_matrix_size] += src_tensor[idx];
      |           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~
[6/80] Building CXX object CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu_buffered_transfer_device.cpp.o
FAILED: CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu_buffered_transfer_device.cpp.o 
/gpfs/u/software/npl/gcc/9.3.0/1/bin/g++ -DRPU_TORCH_CUDA_BUFFERS -DRPU_USE_CUDA -DRPU_USE_FP16 -DRPU_USE_MKL -DRPU_USE_WITH_TORCH -D_GLIBCXX_USE_CXX11_ABI=0 -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/include/python3.10 -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/pybind11/include -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/torch/include -I/gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/lib/python3.10/site-packages/torch/include/torch/csrc/api/include -isystem /gpfs/u/home/ANFM/ANFMbchl/scratch/miniconda3/envs/torch-nightly/include -isystem /usr/local/cuda-12.1/targets/x86_64-linux/include -isystem /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda -isystem /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/cuda -fopenmp -Wall -Wno-narrowing -Wno-strict-overflow -g -std=gnu++17 -fPIC -MD -MT CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu_buffered_transfer_device.cpp.o -MF CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu_buffered_transfer_device.cpp.o.d -o CMakeFiles/RPU_CPU.dir/src/rpucuda/rpu_buffered_transfer_device.cpp.o -c /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp: In instantiation of ‘T RPU::BufferedTransferRPUDeviceMetaParameter<T>::getTransferLR(int, int, T) const [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:70:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:60:14: error: no match for ‘operator*=’ (operand types are ‘__half’ and ‘float’)
   60 |     lr_gamma *= this->gamma_vec[from_device_idx] / this->gamma_vec[to_device_idx];
      |     ~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp: In instantiation of ‘void RPU::BufferedTransferRPUDevice<T>::readAndUpdate(int, int, T, const T*, int, T, int, int) [with T = __half]’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:325:16:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:177:17: error: call of overloaded ‘__half(const int&)’ is ambiguous
  177 |   T max_steps = (T)this->transfer_pwu_->getUpPar().desired_BL;
      |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:199:13: error: no match for ‘operator+=’ (operand types are ‘__half’ and ‘float’)
  199 |       omega += v_out[j] * lr_abs;
      |       ~~~~~~^~~~~~~~~~~~~~~~~~~~
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: error: operands to ?: have different types ‘__half’ and ‘float’
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                   ~~~~~~~~~~~~~^~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:201:19: note: in expansion of macro ‘MAX’
  201 |       T n_steps = MAX(MIN((T)truncf(omega / buffer_granularity), max_steps), -max_steps);
      |                   ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:32:32: note:   and each type can be converted to the other
   32 | #define MAX(a, b) (((a) > (b)) ? (a) : (b))
      |                   ~~~~~~~~~~~~~^~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:201:19: note: in expansion of macro ‘MAX’
  201 |       T n_steps = MAX(MIN((T)truncf(omega / buffer_granularity), max_steps), -max_steps);
      |                   ^~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:204:41: error: operands to ?: have different types ‘float’ and ‘__half’
  204 |         fp_w[i_w] = (n_steps != (T)0.0) ? omega * par.momentum : omega;
      |                     ~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:204:41: note:   and each type can be converted to the other
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:207:33: error: operands to ?: have different types ‘float’ and ‘__half’
  207 |             (n_steps != (T)0.0) ? omega - sub_momentum * n_steps * buffer_granularity : omega;
      |             ~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:207:33: note:   and each type can be converted to the other
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h: In instantiation of ‘RPU::IOMetaParameter<__half>::IOMetaParameter()’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:82:35:   required from ‘RPU::TransferRPUDeviceMetaParameter<T>::TransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:46:80:   required from ‘RPU::BufferedTransferRPUDeviceMetaParameter<T>::BufferedTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:70:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:86:16: error: call of overloaded ‘__half(int)’ is ambiguous
   86 |   T _out_res = (T)0;
      |                ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h: In instantiation of ‘constexpr RPU::PulsedUpdateMetaParameter<__half>::PulsedUpdateMetaParameter()’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:82:35:   required from ‘RPU::TransferRPUDeviceMetaParameter<T>::TransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:46:80:   required from ‘RPU::BufferedTransferRPUDeviceMetaParameter<T>::BufferedTransferRPUDeviceMetaParameter() [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:70:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:267:11: error: call of overloaded ‘__half(int)’ is ambiguous
  267 |   T res = (T)0; // this is taken to be in the range 0..1 as positive and negative phases are done
      |           ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:270:22: error: call of overloaded ‘__half(int)’ is ambiguous
  270 |   T x_res_implicit = (T)0; // in case of implicit pulsing. Assumes range 0..1
      |                      ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:271:22: error: call of overloaded ‘__half(int)’ is ambiguous
  271 |   T d_res_implicit = (T)0;
      |                      ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h: In instantiation of ‘RPU::IOMetaParameter<__half>::IOMetaParameter()’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:84:54:   required from ‘RPU::TransferRPUDeviceMetaParameter<T>::TransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:51:56:   required from ‘RPU::BufferedTransferRPUDeviceMetaParameter<T>::BufferedTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:70:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:86:16: error: call of overloaded ‘__half(int)’ is ambiguous
   86 |   T _out_res = (T)0;
      |                ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h: In instantiation of ‘constexpr RPU::PulsedUpdateMetaParameter<__half>::PulsedUpdateMetaParameter()’:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:84:54:   required from ‘RPU::TransferRPUDeviceMetaParameter<T>::TransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:51:56:   required from ‘RPU::BufferedTransferRPUDeviceMetaParameter<T>::BufferedTransferRPUDeviceMetaParameter(const RPU::PulsedRPUDeviceMetaParameterBase<T>&, int) [with T = __half]’
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:70:17:   required from here
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:267:11: error: call of overloaded ‘__half(int)’ is ambiguous
  267 |   T res = (T)0; // this is taken to be in the range 0..1 as positive and negative phases are done
      |           ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:270:22: error: call of overloaded ‘__half(int)’ is ambiguous
  270 |   T x_res_implicit = (T)0; // in case of implicit pulsing. Assumes range 0..1
      |                      ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:215:25: note: candidate: ‘__half::__half(double)’
  215 |     __CUDA_HOSTDEVICE__ __half(const double f) { __x = __double2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:214:25: note: candidate: ‘__half::__half(float)’
  214 |     __CUDA_HOSTDEVICE__ __half(const float f) { __x = __float2half(f).__x;  }
      |                         ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(const __half&)’
  192 | struct __CUDA_ALIGN__(2) __half {
      |                          ^~~~~~
/usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.hpp:192:26: note: candidate: ‘constexpr __half::__half(__half&&)’
In file included from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:
/gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_pulsed_meta_parameter.h:271:22: error: call of overloaded ‘__half(int)’ is ambiguous
  271 |   T d_res_implicit = (T)0;
      |                      ^~~~
In file included from /usr/local/cuda-12.1/targets/x86_64-linux/include/cuda_fp16.h:4019,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/utility_functions.h:35,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/math_util.h:16,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rng.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_forward_backward_pass.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.h:15,
                 from /gpfs/u/scratch/ANFM/ANFMbchl/public_aihwkit/src/rpucuda/rpu_buffered_transfer_device.cpp:13:

@jubueche
Copy link
Collaborator

@maljoras I think this is something that you could maybe easily fix. Or you could tell me how I could resolve it.

dataset = datasets.MNIST("data", train=True, download=True, transform=transform)
train_loader = torch.utils.data.DataLoader(dataset, batch_size=32)

model = model.to(device=device, dtype=torch.bfloat16)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this also work with other tiles that TorchInference? I had added a HALF type, like in the above: rpu_config.runtime.data_type = RPUDataType.HALF
because the HALF could either be bfloat16 of float16 depending on the compilation options.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There also a runtime.data_type.as_torch() or something function to convert it to the corresponding torch type, see https://github.com/IBM/aihwkit/blob/master/src/aihwkit/simulator/parameters/enums.py#L23

@maljoras
Copy link
Collaborator

maljoras commented Aug 25, 2024

Yes, one has to enable the FP16 auto-conversion during the compilation if I remember correctly. You have to make sure that __CUDA_NO_HALF_CONVERSIONS__ is NOT defined. See https://docs.nvidia.com/cuda/cuda-math-api/group__CUDA__MATH__INTRINSIC__HALF.html#group__CUDA__MATH__INTRINSIC__HALF

@maljoras
Copy link
Collaborator

You could try to set additionally -DRPU_PARAM_FP16=ON. Maybe I set a compiler directive wrongly somewhere. I remember that with this flag it was working fine.

@maljoras
Copy link
Collaborator

You might also want to use bfloat as default FP16 type (with -DRPU_BFLOAT_AS_FP16=ON)

@maljoras
Copy link
Collaborator

maljoras commented Aug 25, 2024

Actually, could also be related to the rather old compiler you are using? One way to go about it might to change each conversion (T) var_or_number to static_cast<T>(var_or_number) . But as far as I remember it compiled fine last time I checked. However, CPU version of fp16 had some problems still, that's why I mentioned it to be experimental.

@jubueche
Copy link
Collaborator

jubueche commented Aug 26, 2024

I suspect the compiler version to be the problem. Do you know what compiler version worked? On the system I using to check this it is not working.
This is my GCC compiler version:

Not searching for unused variables given on the command line.
-- The C compiler identification is GNU 9.3.0
-- The CXX compiler identification is GNU 9.3.0

Regarding the other things you mentioned: I tried -DRPU_BFLOAT_AS_FP16=ON and -DRPU_PARAM_FP16=ON and this and didn't help. __CUDA_NO_HALF_CONVERSIONS__ also did not change anything.

@kaoutar55
Copy link
Collaborator

@jubueche have you tried a different compiler version? what is the status on this testing?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants