Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
platy-browser-data
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
Container Registry
Model registry
Operate
Environments
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
Kimberly Isobel Meechan
platy-browser-data
Commits
5a93369a
Commit
5a93369a
authored
5 years ago
by
Constantin Pape
Browse files
Options
Downloads
Patches
Plain Diff
Add skeleton script for making initial version
parent
c44a8fea
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
README.md
+5
-0
5 additions, 0 deletions
README.md
make_initial_version.py
+9
-0
9 additions, 0 deletions
make_initial_version.py
update_platy_browser.py
+13
-5
13 additions, 5 deletions
update_platy_browser.py
with
27 additions
and
5 deletions
README.md
+
5
−
0
View file @
5a93369a
...
...
@@ -2,3 +2,8 @@
## Generating new version of segmentations and attributes
## Semantic versioning
[
semantic versioning
](
https://semver.org/
)
This diff is collapsed.
Click to expand it.
make_initial_version.py
0 → 100644
+
9
−
0
View file @
5a93369a
import
os
def
make_initial_version
():
pass
if
__name__
==
'
__main__
'
:
make_initial_version
()
This diff is collapsed.
Click to expand it.
update_platy_browser.py
+
13
−
5
View file @
5a93369a
...
...
@@ -92,9 +92,12 @@ def make_attributes(folder, new_folder,
# TODO check for errors
def
make_release
(
tag
):
def
make_release
(
tag
,
description
=
''
):
call
([
'
git
'
,
'
commit
'
,
'
-m
'
,
'
Automatic platybrowser update
'
])
call
([
'
git
'
,
'
tag
'
,
tag
])
if
description
==
''
:
call
([
'
git
'
,
'
tag
'
,
tag
])
else
:
call
([
'
git
'
,
'
-m
'
,
description
,
'
tag
'
,
tag
])
# TODO autopush ???
# call(['git', 'push', 'origin', 'master', '--tags'])
...
...
@@ -103,7 +106,8 @@ def make_release(tag):
def
update_platy_browser
(
update_cell_segmentation
=
False
,
update_nucleus_segmentation
=
False
,
update_cell_tables
=
False
,
update_nucleus_tables
=
False
):
update_nucleus_tables
=
False
,
description
=
''
):
"""
Generate new version of platy-browser derived data.
Arguments:
...
...
@@ -113,6 +117,7 @@ def update_platy_browser(update_cell_segmentation=False,
segmentation is not update, but the tables should be updated.
update_nucleus_tables: Update the nucleus tables. This needs to be specified if the nucleus
segmentation is not updated, but the tables should be updated.
description: Optional descrption for release message.
"""
# check inputs
...
...
@@ -146,7 +151,7 @@ def update_platy_browser(update_cell_segmentation=False,
copy_static_files
(
folder
,
new_folder
)
# make new release
make_release
(
new_tag
)
make_release
(
new_tag
,
description
)
def
str2bool
(
v
):
...
...
@@ -178,9 +183,12 @@ if __name__ == '__main__':
default
=
False
,
help
=
table_help_str
(
"
cell
"
))
parser
.
add_argument
(
'
--update_nucleus_tables
'
,
type
=
str2bool
,
default
=
False
,
help
=
table_help_str
(
"
nucleus
"
))
parser
.
add_argument
(
'
--description
'
,
type
=
str
,
default
=
''
,
help
=
"
Optional description for release message
"
)
args
=
parser
.
parse_args
()
update_platy_browser
(
args
.
update_cell_segmentation
,
args
.
update_nucleus_segmentation
,
args
.
update_cell_tables
,
args
.
update_nucleus_tables
)
args
.
update_nucleus_tables
,
args
.
description
)
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