Skip to content
TheChatArchiveThe Chat Archive
gpt-4.1-mini-2025-04-14· OpenAIAi2 WildChat-4.8M (AI2)

create commit message "SegmentationTrtWrapper::prepareOutput(std::vector<cv::Mat>&…

  1. User

    create commit message "SegmentationTrtWrapper::prepareOutput(std::vectorcv::Mat& images)

     if (toPublishImagesWithSegmentedObjects_)
     {
    
    •  if (numImg % 2 == 0)
      
    •  if (numImg < sizeOutMsgs)
       {
         maskArray_->image.emplace_back(std::move(*msg));
       }
      

    "

  2. Assistant

    fix(SegmentationTrtWrapper): update prepareOutput to correctly handle maskArray images

    Changed condition from if (numImg % 2 == 0) to if (numImg < sizeOutMsgs) in prepareOutput to ensure proper handling of images when publishing segmented object masks. This prevents skipping valid images and aligns mask array population with the expected output message size.