Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
UW-Glance
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
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
Eva Schiffer
UW-Glance
Commits
1ab9cb25
Commit
1ab9cb25
authored
3 years ago
by
Eva Schiffer
Browse files
Options
Downloads
Patches
Plain Diff
better selection of default nav variables in the GUI
parent
5b0e3db4
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
pyglance/glance/gui_constants.py
+2
-2
2 additions, 2 deletions
pyglance/glance/gui_constants.py
pyglance/glance/gui_model.py
+6
-4
6 additions, 4 deletions
pyglance/glance/gui_model.py
with
8 additions
and
6 deletions
pyglance/glance/gui_constants.py
+
2
−
2
View file @
1ab9cb25
...
...
@@ -69,8 +69,8 @@ DATA_FORMS = [SIMPLE_2D,
ONLY_1D
]
# the default names that the model will try to select for the latitude and longitude
DEFAULT_LONGITUDE
=
'
pixel_longitude
'
DEFAULT_LATITUDE
=
'
pixel_latitude
'
DEFAULT_LONGITUDE
S
=
[
'
pixel_longitude
'
,
'
longitude
'
,
'
Longitude
'
,]
DEFAULT_LATITUDE
S
=
[
'
pixel_latitude
'
,
'
latitude
'
,
'
Latitude
'
,]
# the number of bins to use for histograms
DEFAULT_NUM_BINS
=
50
...
...
This diff is collapsed.
Click to expand it.
pyglance/glance/gui_model.py
+
6
−
4
View file @
1ab9cb25
...
...
@@ -242,10 +242,12 @@ class GlanceGUIModel (object) :
# set the longitude and latitude names, using the defaults if they exist
self
.
fileData
[
filePrefix
].
latitude
=
tempVariable
self
.
fileData
[
filePrefix
].
longitude
=
tempVariable
if
DEFAULT_LATITUDE
in
variableList
:
self
.
fileData
[
filePrefix
].
latitude
=
DEFAULT_LATITUDE
if
DEFAULT_LONGITUDE
in
variableList
:
self
.
fileData
[
filePrefix
].
longitude
=
DEFAULT_LONGITUDE
for
temp_lat_name
in
DEFAULT_LATITUDES
:
if
temp_lat_name
in
variableList
:
self
.
fileData
[
filePrefix
].
latitude
=
temp_lat_name
for
temp_lon_name
in
DEFAULT_LONGITUDES
:
if
temp_lon_name
in
variableList
:
self
.
fileData
[
filePrefix
].
longitude
=
temp_lon_name
# make sure the longitude and latitude are loaded into our local cache
# TODO, it would be good to background this task at some point
...
...
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