在docker容器中进行qat量化训练,经过浮点模型训练,融合算子后,转为qat_model训练时,显示RuntimeError: nvrtc: error: invalid value for --gpu-architecture (-arch)报错。
nvrtc compilation failed:
#define NAN __int_as_float(0x7fffffff)
#define POS_INFINITY __int_as_float(0x7f800000)
#define NEG_INFINITY __int_as_float(0xff800000)
template
__device__ T maximum(T a, T b) {
return isnan(a) ? a : (a > b ? a : b);
}
template
__device__ T minimum(T a, T b) {
return isnan(a) ? a : (a < b ? a : b);
}
extern “C” __global__
void fused_neg_max(float* tmax_val_1, float* tmin_val_1, float* aten_max) {
{
float v = __ldg(tmin_val_1 + 0ll);
float v_1 = __ldg(tmax_val_1 + 0ll);
aten_max[0ll] = maximum(0.f - v,v_1);
}
}
这看起来像是cuda torch版本不对应。但是我查看所有版本是对应的如下图,这是什么问题导致的?