Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
LOFAR
Manage
Activity
Members
Labels
Plan
Issues
Wiki
Jira issues
Open Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review 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
RadioObservatory
LOFAR
Commits
f9a76a88
Commit
f9a76a88
authored
4 years ago
by
Jorrit Schaap
Browse files
Options
Downloads
Patches
Plain Diff
TMSS-183
: minor fixes
parent
957567dc
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
SAS/TMSS/src/tmss/tmssapp/adapters/parset.py
+3
-2
3 additions, 2 deletions
SAS/TMSS/src/tmss/tmssapp/adapters/parset.py
SAS/TMSS/src/tmss/tmssapp/populate.py
+2
-2
2 additions, 2 deletions
SAS/TMSS/src/tmss/tmssapp/populate.py
with
5 additions
and
4 deletions
SAS/TMSS/src/tmss/tmssapp/adapters/parset.py
+
3
−
2
View file @
f9a76a88
...
...
@@ -29,10 +29,11 @@ def _convert_to_parset_for_observationcontrol_schema(subtask: models.Subtask) ->
parset
=
dict
()
# parameterset has no proper assignment operators, so take detour via dict...
parset
[
"
Observation.ObsID
"
]
=
subtask
.
pk
parset
[
"
Observation.momID
"
]
=
-
1
# Needed by MACScheduler
parset
[
"
Observation.otdbID
"
]
=
-
1
# Needed by MACScheduler; should/can this be the same as subtask.pk?
parset
[
"
Observation.momID
"
]
=
0
# Needed by MACScheduler
parset
[
"
Observation.otdbID
"
]
=
0
# Needed by MACScheduler; should/can this be the same as subtask.pk?
parset
[
"
Observation.processType
"
]
=
subtask
.
specifications_template
.
type
.
value
.
capitalize
()
parset
[
"
Observation.processSubtype
"
]
=
"
Beam Observation
"
# TODO: where to derive the processSubtype from?
parset
[
"
Observation.Campaign.name
"
]
=
"
TMSS_test
"
#toDo: replace by project name
parset
[
"
Observation.startTime
"
]
=
formatDatetime
(
subtask
.
start_time
)
parset
[
"
Observation.stopTime
"
]
=
formatDatetime
(
subtask
.
stop_time
)
parset
[
"
Observation.VirtualInstrument.minimalNrStations
"
]
=
1
# maybe not mandatory?
...
...
This diff is collapsed.
Click to expand it.
SAS/TMSS/src/tmss/tmssapp/populate.py
+
2
−
2
View file @
f9a76a88
...
...
@@ -189,7 +189,7 @@ def _populate_example_data():
subtask_template
=
models
.
SubtaskTemplate
.
objects
.
get
(
name
=
'
observationcontrol schema
'
)
specifications_doc
=
{
"
stations
"
:
{
"
station_list
"
:
[
"
CS021
"
],
"
stations
"
:
{
"
station_list
"
:
[
"
RS106
"
],
"
antenna_set
"
:
"
HBA_DUAL_INNER
"
,
"
filter
"
:
"
HBA_110_190
"
,
"
analog_pointing
"
:
{
"
direction_type
"
:
"
J2000
"
,
...
...
@@ -212,7 +212,7 @@ def _populate_example_data():
subtask_output
=
models
.
SubtaskOutput
.
objects
.
create
(
**
SubtaskOutput_test_data
(
subtask
=
subtask
))
for
sb_nr
in
specifications_doc
[
'
stations
'
][
'
digital_pointings
'
][
0
][
'
subbands
'
]:
models
.
Dataproduct
.
objects
.
create
(
**
Dataproduct_test_data
(
producer
=
subtask_output
,
directory
=
"
CEP4:/data/test-projects/L%d/uv/
"
%
(
subtask
.
id
,),
directory
=
"
CEP4:/data/test-projects/
TMSS_test/
L%d/uv/
"
%
(
subtask
.
id
,),
filename
=
"
L%d_SB%03d_uv.MS
"
%
(
subtask
.
id
,
sb_nr
)))
except
ImportError
:
pass
...
...
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