diff --git a/AXOL1TL_v1/GTADModel_emulator_v1.cpp b/AXOL1TL_v1/GTADModel_emulator_v1.cpp index e39bbde..530a3c8 100644 --- a/AXOL1TL_v1/GTADModel_emulator_v1.cpp +++ b/AXOL1TL_v1/GTADModel_emulator_v1.cpp @@ -24,8 +24,8 @@ class GTADModel_emulator_v1 : public hls4mlEmulator::Model { { for (int i = 0; i < N_INPUT_1_1; i++) { - unscaled_t tmp0 = unscaled[i] - ad_offsets[i]; - input_t tmp1 = tmp0 >> ad_shift[i]; + unscaled_t tmp0 = unscaled[i] - hls4ml_axol1tl_v1::ad_offsets[i]; + input_t tmp1 = tmp0 >> hls4ml_axol1tl_v1::ad_shift[i]; scaled[i] = tmp1; } } diff --git a/AXOL1TL_v1/scales.h b/AXOL1TL_v1/scales.h index 51b24f1..262acdd 100644 --- a/AXOL1TL_v1/scales.h +++ b/AXOL1TL_v1/scales.h @@ -4,6 +4,7 @@ #include "NN/GTADModel_v1.h" //N_INPUT_1_1=AD_NNNINPUTS +namespace hls4ml_axol1tl_v1{ typedef ap_fixed<5,5> ad_shift_t; typedef ap_fixed<10,9> ad_offset_t; @@ -19,5 +20,5 @@ static const ad_offset_t ad_offsets[N_INPUT_1_1] = { 12., 0.5, 34., 10., 0.5, 33., 8.5, 0., 32., 7., 0.5, 29., 5., 0.5, 24., 3., 0., 15., 0., 0., 0., 0., 0., 0.}; - +} #endif diff --git a/AXOL1TL_v3/GTADModel_emulator_v3.cpp b/AXOL1TL_v3/GTADModel_emulator_v3.cpp index 8ef9361..bc685b3 100644 --- a/AXOL1TL_v3/GTADModel_emulator_v3.cpp +++ b/AXOL1TL_v3/GTADModel_emulator_v3.cpp @@ -26,8 +26,8 @@ class GTADModel_emulator_v3 : public hls4mlEmulator::Model { { for (int i = 0; i < N_INPUT_1_1; i++) { - unscaled_t tmp0 = unscaled[i] - ad_offsets[i]; - input_t tmp1 = tmp0 >> ad_shift[i]; + unscaled_t tmp0 = unscaled[i] - hls4ml_axol1tl_v3::ad_offsets[i]; + input_t tmp1 = tmp0 >> hls4ml_axol1tl_v3::ad_shift[i]; scaled[i] = tmp1; } }