File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -624,13 +624,13 @@ namespace TRT {
624624 }
625625
626626 for (int i = 0 ; i < net_num_output; ++i){
627- auto input = network->getOutput (i);
628- auto input_dims = input ->getDimensions ();
629- input_dims .d [0 ] = 1 ;
630- profile->setDimensions (input ->getName (), nvinfer1::OptProfileSelector::kMIN , input_dims );
631- profile->setDimensions (input ->getName (), nvinfer1::OptProfileSelector::kOPT , input_dims );
632- input_dims .d [0 ] = maxBatchSize;
633- profile->setDimensions (input ->getName (), nvinfer1::OptProfileSelector::kMAX , input_dims );
627+ auto output = network->getOutput (i);
628+ auto output_dims = output ->getDimensions ();
629+ output_dims .d [0 ] = 1 ;
630+ profile->setDimensions (output ->getName (), nvinfer1::OptProfileSelector::kMIN , output_dims );
631+ profile->setDimensions (output ->getName (), nvinfer1::OptProfileSelector::kOPT , output_dims );
632+ output_dims .d [0 ] = maxBatchSize;
633+ profile->setDimensions (output ->getName (), nvinfer1::OptProfileSelector::kMAX , output_dims );
634634 }
635635 config->addOptimizationProfile (profile);
636636
You can’t perform that action at this time.
0 commit comments