ReUseX  0.0.5
3D Point Cloud Processing for Building Reuse
Loading...
Searching...
No Matches
reusex::vision::tensor_rt::TensorRTData Struct Reference

#include <Data.hpp>

Inheritance diagram for reusex::vision::tensor_rt::TensorRTData:
Collaboration diagram for reusex::vision::tensor_rt::TensorRTData:

Public Types

using Vec = std::array<int64_t, 32>
using Prompt = std::pair<std::shared_ptr<Vec>, std::shared_ptr<Vec>>

Static Public Member Functions

static const std::vector< std::string > & default_prompt_text_list ()
 Returns the plain text of the built-in default prompt list so callers can merge it with extra prompts (e.g.

Public Attributes

cv::Mat image
std::vector< Sam3PromptUnit > prompts
float confidence_threshold = 0.5f
bool label_by_prompt_index = false
 Input: write each detection's prompt position (0..N-1 in prompts) as its label value instead of the model's per-text cache id.
bool select_box_instances = false
 Input: for a prompt with boxes or points, keep only the detections they select (vision::sam3_detection_selected; a point keeps the one object under it).
bool geometry_prompts_used = false
 Output (on forward() results): true when the loaded engines take geometry, i.e.

Additional Inherited Members

Public Member Functions inherited from reusex::vision::IData
virtual ~IData ()=default

Detailed Description

Definition at line 22 of file Data.hpp.

Member Typedef Documentation

◆ Prompt

using reusex::vision::tensor_rt::TensorRTData::Prompt = std::pair<std::shared_ptr<Vec>, std::shared_ptr<Vec>>

Definition at line 25 of file Data.hpp.

◆ Vec

using reusex::vision::tensor_rt::TensorRTData::Vec = std::array<int64_t, 32>

Definition at line 24 of file Data.hpp.

Member Function Documentation

◆ default_prompt_text_list()

const std::vector< std::string > & reusex::vision::tensor_rt::TensorRTData::default_prompt_text_list ( )
inlinestatic

Returns the plain text of the built-in default prompt list so callers can merge it with extra prompts (e.g.

glass classes) without including this backend-specific header.

Definition at line 87 of file Data.hpp.

Member Data Documentation

◆ confidence_threshold

float reusex::vision::tensor_rt::TensorRTData::confidence_threshold = 0.5f

Definition at line 62 of file Data.hpp.

◆ geometry_prompts_used

bool reusex::vision::tensor_rt::TensorRTData::geometry_prompts_used = false

Output (on forward() results): true when the loaded engines take geometry, i.e.

prompt boxes (and points) were fed to SAM3. False means they were ignored by the model and only the text drove the detections.

Definition at line 82 of file Data.hpp.

◆ image

cv::Mat reusex::vision::tensor_rt::TensorRTData::image

Definition at line 27 of file Data.hpp.

◆ label_by_prompt_index

bool reusex::vision::tensor_rt::TensorRTData::label_by_prompt_index = false

Input: write each detection's prompt position (0..N-1 in prompts) as its label value instead of the model's per-text cache id.

Set by the single-image callers (segment_image, segment_panorama), whose callers map label k to prompt k. Left false by the annotate dataset, whose class map relies on the cache-id numbering. See sam3_label_value().

Definition at line 69 of file Data.hpp.

◆ prompts

std::vector<Sam3PromptUnit> reusex::vision::tensor_rt::TensorRTData::prompts
Initial value:
= {
Sam3PromptUnit("wall"),
Sam3PromptUnit("floor"),
Sam3PromptUnit("ceiling"),
Sam3PromptUnit("column"),
Sam3PromptUnit("beam"),
Sam3PromptUnit("door"),
Sam3PromptUnit("door frame"),
Sam3PromptUnit("window"),
Sam3PromptUnit("staircase"),
Sam3PromptUnit("railing"),
Sam3PromptUnit("radiator"),
Sam3PromptUnit("pipe"),
Sam3PromptUnit("duct"),
Sam3PromptUnit("electrical outlet"),
Sam3PromptUnit("ceiling light"),
Sam3PromptUnit("sink"),
Sam3PromptUnit("cabinet"),
Sam3PromptUnit("shelf"),
}

Definition at line 36 of file Data.hpp.

◆ select_box_instances

bool reusex::vision::tensor_rt::TensorRTData::select_box_instances = false

Input: for a prompt with boxes or points, keep only the detections they select (vision::sam3_detection_selected; a point keeps the one object under it).

SAM3 treats a box as an exemplar and returns every similar object in the image; the single-image selection callers (segment_image) want the object the geometry points at. Points are only fed to the model when this is set. Left false by the annotate dataset.

Definition at line 77 of file Data.hpp.


The documentation for this struct was generated from the following file:
  • libs/reusex/include/vision/tensor_rt/Data.hpp