Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
EBVCubeVisualizerPlugin
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
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
no67wuwu
EBVCubeVisualizerPlugin
Commits
77a4b779
Commit
77a4b779
authored
2 years ago
by
Emmanuel Oceguera Conchas
Browse files
Options
Downloads
Patches
Plain Diff
the groups od the groups and the attibutes has been added
parent
485693f1
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
netCDF_visualizer_funtionality.py
+19
-14
19 additions, 14 deletions
netCDF_visualizer_funtionality.py
with
19 additions
and
14 deletions
netCDF_visualizer_funtionality.py
+
19
−
14
View file @
77a4b779
...
@@ -139,39 +139,44 @@ class maskAndFuntionality (BASE, WIDGET):
...
@@ -139,39 +139,44 @@ class maskAndFuntionality (BASE, WIDGET):
#we set the top of the tree that it is the name od the file
#we set the top of the tree that it is the name od the file
self
.
tree_data
.
addTopLevelItem
(
top_level
)
self
.
tree_data
.
addTopLevelItem
(
top_level
)
"""
we show
the variables of the file
in the QTreeWidgetite
"""
#we get
the variables of the file
and show then as well as the long name in the tree
for
i
in
range
(
len
(
ncFileVariablesName
)):
for
i
in
range
(
len
(
ncFileVariablesName
)):
child
=
QTreeWidgetItem
([
ncFileVariablesName
[
i
]])
child
=
QTreeWidgetItem
([
ncFileVariablesName
[
i
]
,
ncFile
.
variables
[
ncFileVariablesName
[
i
]].
long_name
])
top_level
.
addChild
(
child
)
top_level
.
addChild
(
child
)
#we show the groups of the file in the QTreeWidgetite
#we show the groups of the file in the QTreeWidgetite
for
i
in
range
(
len
(
ncFileGroupsName
)):
for
i
in
range
(
len
(
ncFileGroupsName
)):
child
=
QTreeWidgetItem
([
ncFileGroupsName
[
i
]])
child
=
QTreeWidgetItem
([
ncFileGroupsName
[
i
],
ncFileGroupsName
[
i
]])
top_level
.
addChild
(
child
)
top_level
.
addChild
(
child
)
#we get the groups of the groups
#we get the groups of the groups
ncFileGroupsName2
=
list
(
ncFile
.
groups
[
ncFileGroupsName
[
i
]].
groups
.
keys
())
ncFileGroupsName2
=
list
(
ncFile
.
groups
[
ncFileGroupsName
[
i
]].
groups
.
keys
())
#we show the groups of the groups in the QTreeWidgetite
#we show the groups of the groups in the QTreeWidgetite
for
j
in
range
(
len
(
ncFileGroupsName2
)):
for
j
in
range
(
len
(
ncFileGroupsName2
)):
child2
=
QTreeWidgetItem
([
ncFileGroupsName2
[
j
]])
child2
=
QTreeWidgetItem
([
ncFileGroupsName2
[
j
],
ncFileGroupsName2
[
j
]])
child
.
addChild
(
child2
)
child
.
addChild
(
child2
)
#we get the variables of the groups of the groups
#we get the variables of the groups of the groups
ncFileVariablesName2
=
list
(
ncFile
.
groups
[
ncFileGroupsName
[
i
]].
groups
[
ncFileGroupsName2
[
j
]].
variables
.
keys
())
ncFileVariablesName2
=
list
(
ncFile
.
groups
[
ncFileGroupsName
[
i
]].
groups
[
ncFileGroupsName2
[
j
]].
variables
.
keys
())
#we show the variables of the groups of the groups in the QTreeWidgetite
#we show the variables of the groups of the groups in the QTreeWidgetite an set the lon name of the variables
for
k
in
range
(
len
(
ncFileVariablesName2
)):
for
k
in
range
(
len
(
ncFileVariablesName2
)):
child3
=
QTreeWidgetItem
([
ncFileVariablesName2
[
k
]])
child3
=
QTreeWidgetItem
([
ncFileVariablesName2
[
k
]])
child2
.
addChild
(
child3
)
child2
.
addChild
(
child3
)
#we get the variables of the groups
#we get the variables of the groups
ncFileGroupsVariablesName
=
list
(
ncFile
.
groups
[
ncFileGroupsName
[
i
]].
variables
.
keys
())
ncFileGroupsVariablesName
=
list
(
ncFile
.
groups
[
ncFileGroupsName
[
i
]].
variables
.
keys
())
#we show the variables of the groups in the QTreeWidgetite
#we show the variables of the groups in the QTreeWidgetite and set the long name of the variables
for
j
in
range
(
len
(
ncFileGroupsVariablesName
)):
for
j
in
range
(
len
(
ncFileGroupsVariablesName
)):
child2
=
QTreeWidgetItem
([
ncFileGroupsVariablesName
[
j
],
ncFileGroupsVariablesLongName
[
j
]])
longNameVariables
=
ncFile
.
groups
[
ncFileGroupsName
[
i
]].
variables
[
ncFileGroupsVariablesName
[
j
]].
long_name
child
.
addChild
(
child2
)
child4
=
QTreeWidgetItem
([
ncFileGroupsVariablesName
[
j
],
longNameVariables
])
#we get the long name of the variables
child
.
addChild
(
child4
)
ncFileGroupsVariablesLongName
=
list
(
ncFile
.
groups
[
ncFileGroupsName
[
i
]].
variables
[
ncFileGroupsVariablesName
[
j
]].
long_name
)
#we show the long name of the variables in the QTreeWidgetite
for
j
in
range
(
len
(
ncFileGroupsVariablesLongName
)):
child2
=
QTreeWidgetItem
([
ncFileGroupsVariablesLongName
[
j
]])
child
.
addChild
(
child2
)
...
...
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