Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
Pytorch-Encoding
Commits
1c4e4a34
Unverified
Commit
1c4e4a34
authored
May 10, 2020
by
Hang Zhang
Committed by
GitHub
May 10, 2020
Browse files
master doc build & pypi release (#276)
parent
b8d83b0d
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
40 additions
and
6 deletions
+40
-6
.github/workflows/pypi_release.yml
.github/workflows/pypi_release.yml
+32
-0
.github/workflows/sphix_build_master.yml
.github/workflows/sphix_build_master.yml
+1
-1
experiments/segmentation/test.py
experiments/segmentation/test.py
+2
-1
setup.py
setup.py
+5
-4
No files found.
.github/workflows/pypi_release.yml
0 → 100644
View file @
1c4e4a34
# This workflows will upload a Python Package using Twine when a release is created
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
name
:
Pypi Release
on
:
release
:
types
:
[
created
]
jobs
:
deploy
:
runs-on
:
ubuntu-18.04
steps
:
-
uses
:
actions/checkout@master
-
name
:
Set up Python
uses
:
actions/setup-python@v1
with
:
python-version
:
'
3.7'
-
name
:
Install dependencies
run
:
|
python -m pip install --upgrade pip
pip install setuptools wheel twine pypandoc
-
name
:
Build and publish
env
:
TWINE_USERNAME
:
${{ secrets.pypi_username }}
TWINE_PASSWORD
:
${{ secrets.pypi_password }}
RELEASE
:
1
run
:
|
python setup.py sdist bdist_wheel
twine upload dist/* --verbose
.github/workflows/sphix_build_master.yml
View file @
1c4e4a34
...
@@ -43,7 +43,7 @@ jobs:
...
@@ -43,7 +43,7 @@ jobs:
# https://github.com/marketplace/actions/github-pages
# https://github.com/marketplace/actions/github-pages
-
name
:
Deploy
-
name
:
Deploy
if
:
success()
if
:
success()
uses
:
crazy-max/ghaction-github-pages@
master
uses
:
crazy-max/ghaction-github-pages@
v1
env
:
env
:
GITHUB_TOKEN
:
${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN
:
${{ secrets.GITHUB_TOKEN }}
with
:
with
:
...
...
experiments/segmentation/test.py
View file @
1c4e4a34
...
@@ -178,6 +178,7 @@ def test(args):
...
@@ -178,6 +178,7 @@ def test(args):
outname
=
os
.
path
.
splitext
(
impath
)[
0
]
+
'.png'
outname
=
os
.
path
.
splitext
(
impath
)[
0
]
+
'.png'
mask
.
save
(
os
.
path
.
join
(
outdir
,
outname
))
mask
.
save
(
os
.
path
.
join
(
outdir
,
outname
))
if
args
.
eval
:
print
(
'pixAcc: %.4f, mIoU: %.4f'
%
(
pixAcc
,
mIoU
))
print
(
'pixAcc: %.4f, mIoU: %.4f'
%
(
pixAcc
,
mIoU
))
class
ReturnFirstClosure
(
object
):
class
ReturnFirstClosure
(
object
):
...
...
setup.py
View file @
1c4e4a34
...
@@ -18,6 +18,7 @@ cwd = os.path.dirname(os.path.abspath(__file__))
...
@@ -18,6 +18,7 @@ cwd = os.path.dirname(os.path.abspath(__file__))
version
=
'1.2.0'
version
=
'1.2.0'
try
:
try
:
if
not
os
.
getenv
(
'RELEASE'
):
from
datetime
import
date
from
datetime
import
date
today
=
date
.
today
()
today
=
date
.
today
()
day
=
today
.
strftime
(
"b%Y%m%d"
)
day
=
today
.
strftime
(
"b%Y%m%d"
)
...
...
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