pub enum MergeMode {
KeepBest,
Union,
}Expand description
What the tiled-detection merge emits for a group of boxes the match metric has joined.
Measured on the Ocean Cleanup ADIS 4K validation set (TOP2-836), the
enclosing union cost about 0.05 AP50 on every frame (whole frame: 0.491
AP50 with plain NMS, 0.437 after the union merge, 0.490 with keep-best;
28-tile pipeline: 0.500 keep-best vs 0.442 union), so Self::KeepBest
is the default. See the module docs.
Variants§
KeepBest
Keep the group’s highest-scoring box — its coordinates and its score — and drop the boxes it matched. Greedy NMS under the configured metric. Default.
The kept box is never grown, rescored or relabelled. It is emitted
canonicalized, which every box
entering the merge is, so it differs from the input only for a
degenerate input box whose min exceeded its max.
Union
Replace the group with its enclosing union carrying the group’s max
score: the original GREEDYNMM merge (ModelPack metrics/tiled.py
before merge_mode). Opt-in; inflates boxes and costs mAP.
Trait Implementations§
impl Copy for MergeMode
impl Eq for MergeMode
impl StructuralPartialEq for MergeMode
Auto Trait Implementations§
impl Freeze for MergeMode
impl RefUnwindSafe for MergeMode
impl Send for MergeMode
impl Sync for MergeMode
impl Unpin for MergeMode
impl UnsafeUnpin for MergeMode
impl UnwindSafe for MergeMode
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.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 more