@@ -11,10 +11,10 @@ namespace converters {
11
11
namespace impl {
12
12
namespace {
13
13
14
- auto interpolate_registrations = RegisterNodeConversionPatterns()
14
+ auto interpolate_registrations TRTORCH_UNUSED = RegisterNodeConversionPatterns()
15
15
.pattern({
16
16
" aten::upsample_nearest1d(Tensor self, int[1] output_size, float? scales=None) -> (Tensor)" ,
17
- [](ConversionCtx* ctx, const torch::jit::Node*n, args& args) -> bool {
17
+ [](ConversionCtx* ctx, const torch::jit::Node* n, args& args) -> bool {
18
18
auto in = args[0 ].ITensor ();
19
19
auto in_shape = util::toVec (in->getDimensions ());
20
20
@@ -37,7 +37,7 @@ auto interpolate_registrations = RegisterNodeConversionPatterns()
37
37
auto layer_output = ctx->AssociateValueAndTensor (n->outputs ()[0 ], resize_layer->getOutput (0 ));
38
38
LOG_DEBUG (" Output tensor shape: " << layer_output->getDimensions ());
39
39
} else {
40
- LOG_DEBUG ( " scale factor parameter not supported yet. " );
40
+ TRTORCH_THROW_ERROR ( " Unable to retrieve all node inputs for node: " << util::node_info (n) << " \n Scale factor parameter not supported yet" );
41
41
}
42
42
43
43
return true ;
@@ -67,14 +67,14 @@ auto interpolate_registrations = RegisterNodeConversionPatterns()
67
67
auto layer_output = ctx->AssociateValueAndTensor (n->outputs ()[0 ], resize_layer->getOutput (0 ));
68
68
LOG_DEBUG (" Output tensor shape: " << layer_output->getDimensions ());
69
69
} else {
70
- LOG_DEBUG ( " scale factor parameters not supported yet. " );
70
+ TRTORCH_THROW_ERROR ( " Unable to retrieve all node inputs for node: " << util::node_info (n) << " \n Scale factor parameter not supported yet" );
71
71
}
72
72
73
73
return true ;
74
74
}
75
75
}).pattern({
76
76
" aten::upsample_nearest3d(Tensor self, int[3] output_size, float? scales_d=None, float? scales_h=None, float? scales_w=None) -> (Tensor)" ,
77
- [](ConversionCtx* ctx, const torch::jit::Node*n, args& args) -> bool {
77
+ [](ConversionCtx* ctx, const torch::jit::Node* n, args& args) -> bool {
78
78
auto in = args[0 ].ITensor ();
79
79
auto in_shape = util::toVec (in->getDimensions ());
80
80
@@ -97,7 +97,7 @@ auto interpolate_registrations = RegisterNodeConversionPatterns()
97
97
auto layer_output = ctx->AssociateValueAndTensor (n->outputs ()[0 ], resize_layer->getOutput (0 ));
98
98
LOG_DEBUG (" Output tensor shape: " << layer_output->getDimensions ());
99
99
} else {
100
- LOG_DEBUG ( " scale factor parameters not supported yet. " );
100
+ TRTORCH_THROW_ERROR ( " Unable to retrieve all node inputs for node: " << util::node_info (n) << " \n Scale factor parameter not supported yet" );
101
101
}
102
102
103
103
return true ;
0 commit comments