pub struct LayoutModelConfig {
pub model_name: String,
pub num_classes: usize,
pub class_labels: HashMap<usize, String>,
pub model_type: String,
pub input_size: Option<(u32, u32)>,
}Expand description
Configuration for layout detection models.
Fields§
§model_name: StringModel name
num_classes: usizeNumber of classes
class_labels: HashMap<usize, String>Class label mapping (class_id -> label string)
model_type: StringModel type (e.g., “picodet”, “rtdetr”, “pp-doclayout”)
input_size: Option<(u32, u32)>Optional fixed input image size (height, width)
Implementations§
Source§impl LayoutModelConfig
impl LayoutModelConfig
Sourcepub fn picodet_layout_1x() -> LayoutModelConfig
pub fn picodet_layout_1x() -> LayoutModelConfig
Create configuration for PicoDet layout 1x model (5 classes).
Sourcepub fn picodet_layout_1x_table() -> LayoutModelConfig
pub fn picodet_layout_1x_table() -> LayoutModelConfig
Create configuration for PicoDet layout 1x table-only model.
Sourcepub fn picodet_s_layout_3cls() -> LayoutModelConfig
pub fn picodet_s_layout_3cls() -> LayoutModelConfig
Create configuration for PicoDet-S layout 3 class model.
Sourcepub fn picodet_l_layout_3cls() -> LayoutModelConfig
pub fn picodet_l_layout_3cls() -> LayoutModelConfig
Create configuration for PicoDet-L layout 3 class model.
Sourcepub fn picodet_s_layout_17cls() -> LayoutModelConfig
pub fn picodet_s_layout_17cls() -> LayoutModelConfig
Create configuration for PicoDet-S layout 17 class model.
Sourcepub fn picodet_l_layout_17cls() -> LayoutModelConfig
pub fn picodet_l_layout_17cls() -> LayoutModelConfig
Create configuration for PicoDet-L layout 17 class model.
Sourcepub fn rtdetr_h_layout_3cls() -> LayoutModelConfig
pub fn rtdetr_h_layout_3cls() -> LayoutModelConfig
Create configuration for RT-DETR-H layout 3 class model.
Sourcepub fn rtdetr_h_layout_17cls() -> LayoutModelConfig
pub fn rtdetr_h_layout_17cls() -> LayoutModelConfig
Create configuration for RT-DETR-H layout 17 class model.
Sourcepub fn pp_docblocklayout() -> LayoutModelConfig
pub fn pp_docblocklayout() -> LayoutModelConfig
Create configuration for PP-DocBlockLayout model (1 class: Region). This model uses 640x640 input size and only detects generic regions.
Sourcepub fn pp_doclayout_s() -> LayoutModelConfig
pub fn pp_doclayout_s() -> LayoutModelConfig
Create configuration for PP-DocLayout-S model (23 classes).
Sourcepub fn pp_doclayout_m() -> LayoutModelConfig
pub fn pp_doclayout_m() -> LayoutModelConfig
Create configuration for PP-DocLayout-M model (23 classes).
Sourcepub fn pp_doclayout_l() -> LayoutModelConfig
pub fn pp_doclayout_l() -> LayoutModelConfig
Create configuration for PP-DocLayout-L model (23 classes).
Sourcepub fn pp_doclayout_plus_l() -> LayoutModelConfig
pub fn pp_doclayout_plus_l() -> LayoutModelConfig
Create configuration for PP-DocLayout-plus-L model (20 classes).
Sourcepub fn pp_doclayoutv2() -> LayoutModelConfig
pub fn pp_doclayoutv2() -> LayoutModelConfig
Create configuration for PP-DocLayoutV2 model (25 classes).
Sourcepub fn pp_doclayoutv3() -> LayoutModelConfig
pub fn pp_doclayoutv3() -> LayoutModelConfig
Create configuration for PP-DocLayoutV3 model (25 classes).
Trait Implementations§
Source§impl Clone for LayoutModelConfig
impl Clone for LayoutModelConfig
Source§fn clone(&self) -> LayoutModelConfig
fn clone(&self) -> LayoutModelConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for LayoutModelConfig
impl RefUnwindSafe for LayoutModelConfig
impl Send for LayoutModelConfig
impl Sync for LayoutModelConfig
impl Unpin for LayoutModelConfig
impl UnwindSafe for LayoutModelConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.