Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
SVLT
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
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
ALMF
SVLT
Commits
978adaf9
Commit
978adaf9
authored
8 months ago
by
Christopher Randolph Rhodes
Browse files
Options
Downloads
Patches
Plain Diff
Added docstring
parent
6f12d7e9
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
model_server/base/roiset.py
+8
-1
8 additions, 1 deletion
model_server/base/roiset.py
with
8 additions
and
1 deletion
model_server/base/roiset.py
+
8
−
1
View file @
978adaf9
...
...
@@ -775,10 +775,17 @@ class RoiSet(object):
def
acc_obj_ids
(
self
):
return
make_object_ids_from_df
(
self
.
_df
,
self
.
acc_raw
.
shape_dict
)
# TODO: add docstring
# TODO: make this work with obj det dataset
@staticmethod
def
deserialize
(
acc_raw
:
GenericImageDataAccessor
,
where
:
Path
,
prefix
=
''
):
"""
Create an RoiSet object from saved files and an image accessor
:param acc_raw: accessor to image that contains ROIs
:param where: path to directory containing RoiSet serialization files, namely dataframe.csv and a subdirectory
named tight_patch_masks
:param prefix: starting prefix of patch mask filenames
:return:
"""
df
=
pd
.
read_csv
(
where
/
'
dataframe
'
/
(
prefix
+
'
.csv
'
))[[
'
label
'
,
'
zi
'
,
'
y0
'
,
'
y1
'
,
'
x0
'
,
'
x1
'
]]
def
_read_binary_mask
(
r
):
...
...
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