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
bf6ad1f1
Commit
bf6ad1f1
authored
1 year ago
by
Christopher Randolph Rhodes
Browse files
Options
Downloads
Patches
Plain Diff
Logged ilastik events
parent
b66b851c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
2 merge requests
!16
Completed (de)serialization of RoiSet
,
!9
Session exposes a python log
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
model_server/extensions/ilastik/router.py
+3
-0
3 additions, 0 deletions
model_server/extensions/ilastik/router.py
with
3 additions
and
0 deletions
model_server/extensions/ilastik/router.py
+
3
−
0
View file @
bf6ad1f1
...
...
@@ -25,9 +25,11 @@ def load_ilastik_model(model_class: ilm.IlastikModel, project_file: str, duplica
if
not
duplicate
:
existing_model_id
=
session
.
find_param_in_loaded_models
(
'
project_file
'
,
project_file
,
is_path
=
True
)
if
existing_model_id
is
not
None
:
session
.
log_info
(
f
'
An ilastik model from
{
project_file
}
already existing exists; did not load a duplicate
'
)
return
{
'
model_id
'
:
existing_model_id
}
try
:
result
=
session
.
load_model
(
model_class
,
{
'
project_file
'
:
project_file
})
session
.
log_info
(
f
'
Loaded ilastik model
{
result
}
from
{
project_file
}
'
)
except
(
FileNotFoundError
,
ParameterExpectedError
):
raise
HTTPException
(
status_code
=
404
,
...
...
@@ -60,6 +62,7 @@ def infer_px_then_ob_maps(px_model_id: str, ob_model_id: str, input_filename: st
channel
=
channel
,
mip
=
mip
,
)
session
.
log_info
(
f
'
Completed pixel and object classification of
{
input_filename
}
'
)
except
AssertionError
:
raise
HTTPException
(
f
'
Incompatible models
{
px_model_id
}
and/or
{
ob_model_id
}
'
)
return
record
\ No newline at end of file
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