Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
model_server
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
Christopher Randolph Rhodes
model_server
Commits
0ba95284
Commit
0ba95284
authored
1 year ago
by
Christopher Randolph Rhodes
Browse files
Options
Downloads
Patches
Plain Diff
Allow parameterization of 3D patch projection
parent
8a5486aa
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
extensions/chaeo/products.py
+2
-1
2 additions, 1 deletion
extensions/chaeo/products.py
with
2 additions
and
1 deletion
extensions/chaeo/products.py
+
2
−
1
View file @
0ba95284
...
...
@@ -37,6 +37,7 @@ def export_patches_from_zstack(
pad_to
:
int
=
256
,
make_3d
:
bool
=
False
,
prefix
=
'
patch
'
,
projector
=
lambda
x
:
np
.
max
(
x
,
axis
=
3
,
keepdims
=
True
),
**
kwargs
):
assert
stack
.
chroma
==
1
,
'
Expecting monochromatic image data
'
...
...
@@ -51,7 +52,7 @@ def export_patches_from_zstack(
if
make_3d
:
patch
=
stack
.
data
[
sl
]
else
:
patch
=
np
.
max
(
stack
.
data
[
sl
]
,
axis
=
3
,
keepdims
=
True
)
patch
=
projector
(
stack
.
data
[
sl
])
assert
len
(
patch
.
shape
)
==
4
assert
patch
.
shape
[
2
]
==
stack
.
chroma
...
...
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