Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
bob.bio.vein
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
bob
bob.bio.vein
Commits
0a6b3b74
Commit
0a6b3b74
authored
Jul 06, 2017
by
André Anjos
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
If sample does not have roi, then returns only image
parent
98f7c7ac
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
5 deletions
+10
-5
bob/bio/vein/database/fv3d.py
bob/bio/vein/database/fv3d.py
+10
-5
No files found.
bob/bio/vein/database/fv3d.py
View file @
0a6b3b74
...
...
@@ -40,12 +40,17 @@ class File(BioFile):
image
=
super
(
File
,
self
).
load
(
*
args
,
**
kwargs
)
image
=
numpy
.
rot90
(
image
,
3
)
roi
=
self
.
__f
.
roi
()
# calculates the 90 degrees anti-clockwise rotated RoI points
w
,
h
=
image
.
shape
roi
=
[(
x
,
h
-
y
)
for
(
y
,
x
)
in
roi
]
mask
=
poly_to_mask
(
image
.
shape
,
roi
)
if
not
self
.
has_roi
():
return
image
else
:
roi
=
self
.
__f
.
roi
()
# calculates the 90 degrees anti-clockwise rotated RoI points
w
,
h
=
image
.
shape
roi
=
[(
x
,
h
-
y
)
for
(
y
,
x
)
in
roi
]
mask
=
poly_to_mask
(
image
.
shape
,
roi
)
return
AnnotatedArray
(
image
,
metadata
=
dict
(
mask
=
mask
,
roi
=
roi
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment