could not convert ‘Double’ from ‘c10::ScalarType’ to ‘<type error>’ AT_PRIVATE_CASE_TYPE(at::ScalarType::Double, double, __VA_ARGS__)
See original GitHub issueGetting few errors while building latest from source;
======================================= site-packages/torch/include/ATen/Dispatch.h:15:17:`` error: switch quantity not an integer switch (TYPE) { \ ^ /maskrcnn_benchmark/csrc/cpu/ROIAlign_cpu.cpp:242:3: note: in expansion of macro ‘AT_DISPATCH_FLOATING_TYPES’ AT_DISPATCH_FLOATING_TYPES(input.type(), “ROIAlign_forward”, [&] { ^~~~~~~~~~~~~~~~~~~~~~~~~~ /python3.7/site-packages/torch/include/ATen/Dispatch.h:16:44: error: could not convert ‘Double’ from ‘c10::ScalarType’ to ‘<type error>’ AT_PRIVATE_CASE_TYPE(at::ScalarType::Double, double, VA_ARGS) \ ^ /python3.7/site-packages/torch/include/ATen/Dispatch.h:8:8: note: in definition of macro ‘AT_PRIVATE_CASE_TYPE’ case enum_type: { \ ^~~~~~~~~ /maskrcnn_benchmark/csrc/cpu/ROIAlign_cpu.cpp:242:3: note: in expansion of macro ‘AT_DISPATCH_FLOATING_TYPES’ AT_DISPATCH_FLOATING_TYPES(input.type(), “ROIAlign_forward”, [&] { ^~~~~~~~~~~~~~~~~~~~~~~~~~ /python3.7/site-packages/torch/include/ATen/Dispatch.h:17:44: error: could not convert ‘Float’ from ‘c10::ScalarType’ to ‘<type error>’ AT_PRIVATE_CASE_TYPE(at::ScalarType::Float, float, VA_ARGS) \ ^ /python3.7/site-packages/torch/include/ATen/Dispatch.h:8:8: note: in definition of macro ‘AT_PRIVATE_CASE_TYPE’ case enum_type: { \ ^~~~~~~~~ /maskrcnn_benchmark/csrc/cpu/ROIAlign_cpu.cpp:242:3: note: in expansion of macro ‘AT_DISPATCH_FLOATING_TYPES’ AT_DISPATCH_FLOATING_TYPES(input.type(), “ROIAlign_forward”, [&] { ^~~~~~~~~~~~~~~~~~~~~~~~~~ /python3.7/site-packages/torch/include/c10/core/Device.h:5:0, from /python3.7/site-packages/torch/include/c10/core/Allocator.h:6, from/python3.7/site-packages/torch/include/ATen/ATen.h:3, from /python3.7/site-packages/torch/include/torch/csrc/api/include/torch/types.h:3, from python3.7/site-packages/torch/include/torch/script.h:3, from /maskrcnn_benchmark/csrc/cpu/vision.h:3, from /maskrcnn_benchmark/csrc/cpu/ROIAlign_cpu.cpp:2: /python3.7/site-packages/torch/include/ATen/Dispatch.h:19:51: error: ‘toString’ was not declared in this scope AT_ERROR(#NAME, " not implemented for ‘", toString(TYPE), "’“); \ ^ /python3.7/site-packages/torch/include/c10/util/Exception.h:134:88: note: in definition of macro ‘AT_ERROR’ throw ::c10::Error({func, FILE, static_cast<uint32_t>(LINE)}, ::c10::str(VA_ARGS)) ^~~~~~~~~~~ /maskrcnn_benchmark/csrc/cpu/ROIAlign_cpu.cpp:242:3: note: in expansion of macro ‘AT_DISPATCH_FLOATING_TYPES’ AT_DISPATCH_FLOATING_TYPES(input.type(), “ROIAlign_forward”, [&] { ^~~~~~~~~~~~~~~~~~~~~~~~~~ /python3.7/site-packages/torch/include/ATen/Dispatch.h:19:51: note: suggested alternatives: AT_ERROR(#NAME, " not implemented for '”, toString(TYPE), “'”); \ ^ /python3.7/site-packages/torch/include/c10/util/Exception.h:134:88: note: in definition of macro ‘AT_ERROR’ throw ::c10::Error({func, FILE, static_cast<uint32_t>(LINE)}, ::c10::str(VA_ARGS)) ^~~~~~~~~~~ /maskrcnn_benchmark/csrc/cpu/ROIAlign_cpu.cpp:242:3: note: in expansion of macro ‘AT_DISPATCH_FLOATING_TYPES’ AT_DISPATCH_FLOATING_TYPES(input.type(), “ROIAlign_forward”, [&] { ^~~~~~~~~~~~~~~~~~~~~~~~~~
Issue Analytics
- State:
- Created 5 years ago
- Comments:10 (3 by maintainers)
Top GitHub Comments
Yes, now we need to use PyTorch master if we use last maskrcnn-benchmark
I see what’s going on, I have not been using PyTorch nightly but
1.0.1
instead. Using the following commit seems to work even without nightly:git checkout 90080e60cc4a9252d019f475af044c9d4119b09b