pingwizard 1.0.0__tar.gz → 1.0.0a2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pingwizard-1.0.0 → pingwizard-1.0.0a2}/PKG-INFO +1 -3
- pingwizard-1.0.0a2/README.md +2 -0
- {pingwizard-1.0.0 → pingwizard-1.0.0a2}/pingwizard/__main__.py +1 -7
- {pingwizard-1.0.0 → pingwizard-1.0.0a2}/pingwizard/gui_wizard.py +5 -22
- pingwizard-1.0.0a2/pingwizard/version.py +1 -0
- {pingwizard-1.0.0 → pingwizard-1.0.0a2}/pingwizard.egg-info/PKG-INFO +1 -3
- {pingwizard-1.0.0 → pingwizard-1.0.0a2}/pingwizard.egg-info/SOURCES.txt +1 -3
- {pingwizard-1.0.0 → pingwizard-1.0.0a2}/setup.py +0 -1
- pingwizard-1.0.0/README.md +0 -4
- pingwizard-1.0.0/pingwizard/assets/PINGMapper_Logo_small.png +0 -0
- pingwizard-1.0.0/pingwizard/create_shortcut.py +0 -79
- pingwizard-1.0.0/pingwizard/version.py +0 -1
- {pingwizard-1.0.0 → pingwizard-1.0.0a2}/LICENSE +0 -0
- {pingwizard-1.0.0 → pingwizard-1.0.0a2}/pingwizard/__init__.py +0 -0
- {pingwizard-1.0.0 → pingwizard-1.0.0a2}/pingwizard.egg-info/dependency_links.txt +0 -0
- {pingwizard-1.0.0 → pingwizard-1.0.0a2}/pingwizard.egg-info/top_level.txt +0 -0
- {pingwizard-1.0.0 → pingwizard-1.0.0a2}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: pingwizard
|
|
3
|
-
Version: 1.0.
|
|
3
|
+
Version: 1.0.0a2
|
|
4
4
|
Summary: Light-weight interface for running PING ecosystem (PINGMapper, etc.)
|
|
5
5
|
Author: Cameron Bodine
|
|
6
6
|
Author-email: bodine.cs@gmail.email
|
|
@@ -23,5 +23,3 @@ License-File: LICENSE
|
|
|
23
23
|
|
|
24
24
|
# PINGWizard
|
|
25
25
|
Light-weight interface for running PING ecosystem (PINGMapper, etc.)
|
|
26
|
-
|
|
27
|
-
[)](https://pypi.org/project/pingwizard/)
|
|
@@ -11,11 +11,7 @@ SCRIPT_DIR = os.path.dirname(os.path.abspath(__file__))
|
|
|
11
11
|
PACKAGE_DIR = os.path.dirname(SCRIPT_DIR)
|
|
12
12
|
|
|
13
13
|
# Logo's
|
|
14
|
-
|
|
15
|
-
pingmapper_logo_name = "PINGMapper_Logo_small.png"
|
|
16
|
-
pingmapper_logo = os.path.join(env_dir, 'pingmapper_config', pingmapper_logo_name)
|
|
17
|
-
if not os.path.isfile(pingmapper_logo):
|
|
18
|
-
pingmapper_logo = os.path.join(SCRIPT_DIR, "assets", pingmapper_logo_name)
|
|
14
|
+
pingmapper_logo = os.path.join(SCRIPT_DIR, "assets", "pingmapper_logo_small.png")
|
|
19
15
|
|
|
20
16
|
def wizard():
|
|
21
17
|
|
|
@@ -24,6 +20,9 @@ def wizard():
|
|
|
24
20
|
# Save the original sys.argv
|
|
25
21
|
original_argv = sys.argv
|
|
26
22
|
|
|
23
|
+
# For running pingmapper
|
|
24
|
+
module_name = "pingmapper"
|
|
25
|
+
|
|
27
26
|
##########################
|
|
28
27
|
# Define the layout blocks
|
|
29
28
|
|
|
@@ -35,7 +34,7 @@ def wizard():
|
|
|
35
34
|
pm_title = sg.Text("PINGMapper", font=("Helvetica", 16), justification="center")
|
|
36
35
|
|
|
37
36
|
## Description
|
|
38
|
-
pm_desc = sg.Text("PINGMapper - Open-source interface for processing recreation-grade side scan sonar datasets and reproducibly mapping benthic habitat.", font=("Helvetica",
|
|
37
|
+
pm_desc = sg.Text("PINGMapper - Open-source interface for processing recreation-grade side scan sonar datasets and reproducibly mapping benthic habitat.", font=("Helvetica", 12), justification="left", size=(30, 5))
|
|
39
38
|
|
|
40
39
|
## Logo
|
|
41
40
|
pm_logo = sg.Image(pingmapper_logo, size=(200, 120))
|
|
@@ -50,9 +49,6 @@ def wizard():
|
|
|
50
49
|
pm_test_single_btn = sg.Button("Small\nDataset", key="test", button_color="navy", size=(10, 2))
|
|
51
50
|
pm_test_batch_btn = sg.Button("Large\nDataset", key="test_large", size=(10, 2))
|
|
52
51
|
|
|
53
|
-
## Update Installation Buttons
|
|
54
|
-
pm_install_text = sg.Text("Update\nPINGMapper", font=("Helvetica", 10, "bold"),size=(11, 2))
|
|
55
|
-
pm_install_btn = sg.Button("Update", key="pinginstaller", button_color="darkorange", size=(10, 2))
|
|
56
52
|
|
|
57
53
|
|
|
58
54
|
#############
|
|
@@ -68,7 +64,6 @@ def wizard():
|
|
|
68
64
|
# [pm_desc],
|
|
69
65
|
[pm_gui_text, sg.VerticalSeparator(), pm_gui_btn, pm_batch_gui_btn],
|
|
70
66
|
[pm_test_text, sg.VerticalSeparator(), pm_test_single_btn, pm_test_batch_btn],
|
|
71
|
-
[pm_install_text, sg.VerticalSeparator(), pm_install_btn],
|
|
72
67
|
[sg.HorizontalSeparator()],
|
|
73
68
|
[sg.HorizontalSeparator()],
|
|
74
69
|
[exit_btn],
|
|
@@ -85,39 +80,28 @@ def wizard():
|
|
|
85
80
|
event, values = window.read()
|
|
86
81
|
if event == "exit_pingwizard" or event == "Submit":
|
|
87
82
|
break
|
|
88
|
-
|
|
89
83
|
|
|
90
84
|
# Launch PINGMapper GUI
|
|
91
85
|
if event == "launch_pingmapper_gui":
|
|
92
86
|
print("Launching PINGMapper GUI...")
|
|
93
87
|
# Set the arguments for the PINGMapper GUI
|
|
94
|
-
module_name = "pingmapper"
|
|
95
88
|
module_args = ["gui"]
|
|
96
89
|
|
|
97
90
|
elif event == "launch_pingmapper_batch_gui":
|
|
98
91
|
print("Launching PINGMapper Batch GUI...")
|
|
99
92
|
# Set the arguments for the PINGMapper Batch GUI
|
|
100
|
-
module_name = "pingmapper"
|
|
101
93
|
module_args = ["gui_batch"]
|
|
102
94
|
|
|
103
95
|
elif event == "test":
|
|
104
96
|
print("Testing PINGMapper...")
|
|
105
97
|
# Set the arguments for the PINGMapper GUI
|
|
106
|
-
module_name = "pingmapper"
|
|
107
98
|
module_args = ["test"]
|
|
108
99
|
|
|
109
100
|
elif event == "test_large":
|
|
110
101
|
print("Testing PINGMapper Batch...")
|
|
111
102
|
# Set the arguments for the PINGMapper Batch GUI
|
|
112
|
-
module_name = "pingmapper"
|
|
113
103
|
module_args = ["test_large"]
|
|
114
104
|
|
|
115
|
-
elif event == "pinginstaller":
|
|
116
|
-
print("Updating PINGMapper...")
|
|
117
|
-
# Set the arguments for the PINGMapper Batch GUI
|
|
118
|
-
module_name = "pinginstaller"
|
|
119
|
-
module_args = []
|
|
120
|
-
|
|
121
105
|
sys.argv = [module_name, *module_args]
|
|
122
106
|
|
|
123
107
|
runpy.run_module(module_name, run_name="__main__")
|
|
@@ -129,5 +113,4 @@ def wizard():
|
|
|
129
113
|
sys.exit()
|
|
130
114
|
|
|
131
115
|
if __name__ == "__main__":
|
|
132
|
-
|
|
133
116
|
wizard()
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = '1.0.0-alpha.2'
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: pingwizard
|
|
3
|
-
Version: 1.0.
|
|
3
|
+
Version: 1.0.0a2
|
|
4
4
|
Summary: Light-weight interface for running PING ecosystem (PINGMapper, etc.)
|
|
5
5
|
Author: Cameron Bodine
|
|
6
6
|
Author-email: bodine.cs@gmail.email
|
|
@@ -23,5 +23,3 @@ License-File: LICENSE
|
|
|
23
23
|
|
|
24
24
|
# PINGWizard
|
|
25
25
|
Light-weight interface for running PING ecosystem (PINGMapper, etc.)
|
|
26
|
-
|
|
27
|
-
[)](https://pypi.org/project/pingwizard/)
|
|
@@ -3,11 +3,9 @@ README.md
|
|
|
3
3
|
setup.py
|
|
4
4
|
pingwizard/__init__.py
|
|
5
5
|
pingwizard/__main__.py
|
|
6
|
-
pingwizard/create_shortcut.py
|
|
7
6
|
pingwizard/gui_wizard.py
|
|
8
7
|
pingwizard/version.py
|
|
9
8
|
pingwizard.egg-info/PKG-INFO
|
|
10
9
|
pingwizard.egg-info/SOURCES.txt
|
|
11
10
|
pingwizard.egg-info/dependency_links.txt
|
|
12
|
-
pingwizard.egg-info/top_level.txt
|
|
13
|
-
pingwizard/assets/PINGMapper_Logo_small.png
|
|
11
|
+
pingwizard.egg-info/top_level.txt
|
|
@@ -16,7 +16,6 @@ setup(
|
|
|
16
16
|
long_description=LONG_DESCRIPTION,
|
|
17
17
|
long_description_content_type='text/markdown',
|
|
18
18
|
packages=find_packages(),
|
|
19
|
-
data_files=[("pingmapper_config", ["pingwizard/assets/PINGMapper_Logo_small.png"])],
|
|
20
19
|
classifiers=[
|
|
21
20
|
"Development Status :: 3 - Alpha",
|
|
22
21
|
"Programming Language :: Python :: 3",
|
pingwizard-1.0.0/README.md
DELETED
|
Binary file
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
import os, sys
|
|
3
|
-
import platform
|
|
4
|
-
import subprocess
|
|
5
|
-
|
|
6
|
-
from pathlib import Path
|
|
7
|
-
home_path = os.path.join(Path.home())
|
|
8
|
-
|
|
9
|
-
def windows_shortcut(conda_base: str, conda_env: str, f: str):
|
|
10
|
-
|
|
11
|
-
to_write = "set conda_base={}\n".format(conda_base)+\
|
|
12
|
-
"""set conda_env="{}"\n""".format(conda_env)+\
|
|
13
|
-
"\n"+\
|
|
14
|
-
'''call %conda_base%\\Scripts\\activate %conda_env%\n\n'''+\
|
|
15
|
-
"call conda env list\n\n"+\
|
|
16
|
-
"echo Launching PINGWizard\n"+\
|
|
17
|
-
"python -m pingwizard\n"+\
|
|
18
|
-
"pause"
|
|
19
|
-
|
|
20
|
-
print('\n\n', to_write)
|
|
21
|
-
|
|
22
|
-
with open(f, 'w') as f:
|
|
23
|
-
f.write(to_write)
|
|
24
|
-
|
|
25
|
-
return
|
|
26
|
-
|
|
27
|
-
def linux_shortcut(conda_base: str, conda_env: str, f: str):
|
|
28
|
-
|
|
29
|
-
to_write = "#!/bin/bash\n"+\
|
|
30
|
-
"""conda_base="{}"\n""".format(conda_base)+\
|
|
31
|
-
"""conda_env="{}"\n""".format(conda_env)+\
|
|
32
|
-
"\n"+\
|
|
33
|
-
'''source $conda_base/bin/activate $conda_env\n'''+\
|
|
34
|
-
"\n"+\
|
|
35
|
-
"echo Launching PINGWizard\n"+\
|
|
36
|
-
"python -m pingwizard\n"
|
|
37
|
-
|
|
38
|
-
print('\n\n', to_write)
|
|
39
|
-
|
|
40
|
-
with open(f, 'w') as file:
|
|
41
|
-
file.write(to_write)
|
|
42
|
-
|
|
43
|
-
# Make executable
|
|
44
|
-
subprocess.run('''chmod u+x "{}"'''.format(f), shell=True)
|
|
45
|
-
|
|
46
|
-
# Print instructions
|
|
47
|
-
print('\n\nLaunch PINGWizard from the console by passing')
|
|
48
|
-
print(f)
|
|
49
|
-
print('OR')
|
|
50
|
-
print('./PINGWizard.sh')
|
|
51
|
-
print('after navigating console to Desktop.\n\n')
|
|
52
|
-
|
|
53
|
-
pass
|
|
54
|
-
|
|
55
|
-
def create_shortcut():
|
|
56
|
-
|
|
57
|
-
# Get ping Environment Path
|
|
58
|
-
conda_env = os.environ['CONDA_PREFIX']
|
|
59
|
-
|
|
60
|
-
# Get Conda base path from ping environment path
|
|
61
|
-
conda_base = conda_env.split('envs')[0]
|
|
62
|
-
|
|
63
|
-
# Reset conda_env
|
|
64
|
-
conda_env = 'ping'
|
|
65
|
-
|
|
66
|
-
# Make the file
|
|
67
|
-
if "Windows" in platform.system():
|
|
68
|
-
# Set file_path
|
|
69
|
-
file_path = os.path.join(home_path, "Desktop", "PINGWizard.bat")
|
|
70
|
-
windows_shortcut(conda_base=conda_base, conda_env=conda_env, f=file_path)
|
|
71
|
-
|
|
72
|
-
else:
|
|
73
|
-
# Set file_path
|
|
74
|
-
file_path = os.path.join(home_path, "Desktop", "PINGWizard.sh")
|
|
75
|
-
linux_shortcut(conda_base=conda_base, conda_env=conda_env, f=file_path)
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
if __name__ == "__main__":
|
|
79
|
-
create_shortcut()
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = '1.0.0'
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|