Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
Code Computer Vision
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Container Registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
PolySTAR
RoboMaster
Computer Vision
Code Computer Vision
Commits
98387ddc
Commit
98387ddc
authored
4 years ago
by
Mathieu Beligon
Browse files
Options
Downloads
Patches
Plain Diff
[filter] (size) Add SizeObjectsFilter
parent
49635732
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/polystar/target_pipeline/objects_filters/size_filter.py
+12
-0
12 additions, 0 deletions
src/polystar/target_pipeline/objects_filters/size_filter.py
with
12 additions
and
0 deletions
src/polystar/target_pipeline/objects_filters/size_filter.py
0 → 100644
+
12
−
0
View file @
98387ddc
from
dataclasses
import
dataclass
from
polystar.models.roco_object
import
ROCOObject
from
polystar.target_pipeline.objects_filters.objects_filter_abc
import
ObjectsFilterABC
@dataclass
class
SmallObjectFilter
(
ObjectsFilterABC
):
min_size
:
int
def
validate_single
(
self
,
obj
:
ROCOObject
)
->
bool
:
return
obj
.
box
.
area
>=
self
.
min_size
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment