Skip to content
Snippets Groups Projects
Commit 24cd0f26 authored by Jörn Künsemöller's avatar Jörn Künsemöller
Browse files

Task #11035 - full support for optional min/max duration, min/max start/end...

Task #11035 - full support for optional min/max duration, min/max start/end times, and station selections on trigger type 1 with working tests.
parent b4d1a386
No related branches found
No related tags found
No related merge requests found
Showing
with 801 additions and 53 deletions
...@@ -5302,7 +5302,9 @@ SAS/SpecificationServices/test/t_telescope_model_xml_generator_type1.in_xml/tele ...@@ -5302,7 +5302,9 @@ SAS/SpecificationServices/test/t_telescope_model_xml_generator_type1.in_xml/tele
SAS/SpecificationServices/test/t_telescope_model_xml_generator_type1.py -text SAS/SpecificationServices/test/t_telescope_model_xml_generator_type1.py -text
SAS/SpecificationServices/test/t_telescope_model_xml_generator_type1.run -text SAS/SpecificationServices/test/t_telescope_model_xml_generator_type1.run -text
SAS/SpecificationServices/test/t_telescope_model_xml_generator_type1.sh -text SAS/SpecificationServices/test/t_telescope_model_xml_generator_type1.sh -text
SAS/SpecificationServices/test/t_translation_service.in_xml/telescope_model_xml_generator_type1-minmax.xml -text
SAS/SpecificationServices/test/t_translation_service.in_xml/telescope_model_xml_generator_type1.xml -text SAS/SpecificationServices/test/t_translation_service.in_xml/telescope_model_xml_generator_type1.xml -text
SAS/SpecificationServices/test/t_translation_service.in_xml/type-1-lofar-minmax.xml -text
SAS/SpecificationServices/test/t_translation_service.in_xml/type-1-lofar.xml -text SAS/SpecificationServices/test/t_translation_service.in_xml/type-1-lofar.xml -text
SAS/SpecificationServices/test/t_translation_service.py -text SAS/SpecificationServices/test/t_translation_service.py -text
SAS/SpecificationServices/test/t_translation_service.run -text SAS/SpecificationServices/test/t_translation_service.run -text
......
...@@ -40,6 +40,7 @@ class LofarXMLToMomXMLModelTranslator(object): ...@@ -40,6 +40,7 @@ class LofarXMLToMomXMLModelTranslator(object):
model = TelescopeModel() model = TelescopeModel()
model.start_time = self._get_start_time(doc) model.start_time = self._get_start_time(doc)
model.end_time = self._get_start_time(doc)
model.min_start_time = self._get_min_start_time(doc) model.min_start_time = self._get_min_start_time(doc)
model.max_end_time = self._get_max_end_time(doc) model.max_end_time = self._get_max_end_time(doc)
model.duration = self._get_duration(doc) model.duration = self._get_duration(doc)
...@@ -50,7 +51,7 @@ class LofarXMLToMomXMLModelTranslator(object): ...@@ -50,7 +51,7 @@ class LofarXMLToMomXMLModelTranslator(object):
model.calibrator_ra = self._get_calibrator_ra(doc) model.calibrator_ra = self._get_calibrator_ra(doc)
model.calibrator_dec = self._get_calibrator_dec(doc) model.calibrator_dec = self._get_calibrator_dec(doc)
model.trigger_id = self._get_trigger_id(doc) model.trigger_id = self._get_trigger_id(doc)
model.station_selection, model.station_list_mom = self._get_station_selection_and_list(doc) model.station_selection, model.custom_station_list = self._get_station_selection_and_list(doc)
model.outer_foldername = self._get_outer_foldername(doc) model.outer_foldername = self._get_outer_foldername(doc)
model.inner_foldername = self._get_inner_foldername(doc) model.inner_foldername = self._get_inner_foldername(doc)
...@@ -86,7 +87,7 @@ class LofarXMLToMomXMLModelTranslator(object): ...@@ -86,7 +87,7 @@ class LofarXMLToMomXMLModelTranslator(object):
return None return None
def _get_min_duration(self, doc): def _get_min_duration(self, doc):
min_duration = doc.xpath('/spec:specification/activity/observation/timeWindowSpecification/minDuration', min_duration = doc.xpath('/spec:specification/activity/observation/timeWindowSpecification/duration/minimumDuration',
namespaces={"spec": "http://www.astron.nl/LofarSpecification"}) namespaces={"spec": "http://www.astron.nl/LofarSpecification"})
if min_duration: if min_duration:
...@@ -95,7 +96,7 @@ class LofarXMLToMomXMLModelTranslator(object): ...@@ -95,7 +96,7 @@ class LofarXMLToMomXMLModelTranslator(object):
return None return None
def _get_max_duration(self, doc): def _get_max_duration(self, doc):
max_duration = doc.xpath('/spec:specification/activity/observation/timeWindowSpecification/maxDuration', max_duration = doc.xpath('/spec:specification/activity/observation/timeWindowSpecification/duration/maximumDuration',
namespaces={"spec": "http://www.astron.nl/LofarSpecification"}) namespaces={"spec": "http://www.astron.nl/LofarSpecification"})
if max_duration: if max_duration:
...@@ -107,15 +108,22 @@ class LofarXMLToMomXMLModelTranslator(object): ...@@ -107,15 +108,22 @@ class LofarXMLToMomXMLModelTranslator(object):
durations = doc.xpath('/spec:specification/activity/observation/timeWindowSpecification/duration/duration', durations = doc.xpath('/spec:specification/activity/observation/timeWindowSpecification/duration/duration',
namespaces={"spec": "http://www.astron.nl/LofarSpecification"}) namespaces={"spec": "http://www.astron.nl/LofarSpecification"})
if durations:
return durations[0].text return durations[0].text
else:
return None
def _get_station_selection(self, doc): def _get_station_selection_and_list(self, doc):
"""
Parses the station selection specificatoon and returns a dict with resource groups and min values as well as
a list of station names parsed from the custom station set. These custom stations are also already included
in the resourcegroup dictionary with minimum value 1.
"""
selections = doc.xpath('/spec:specification/activity/observation/stationSelectionSpecification/stationSelection', selections = doc.xpath('/spec:specification/activity/observation/stationSelectionSpecification/stationSelection',
namespaces={"spec": "http://www.astron.nl/LofarSpecification"}) namespaces={"spec": "http://www.astron.nl/LofarSpecification"})
station_selection = {} station_selection = {}
station_list = [] station_list = []
print selections
for selection in selections: for selection in selections:
station_set = selection.xpath("stationSet")[0].text station_set = selection.xpath("stationSet")[0].text
if station_set == "Custom": if station_set == "Custom":
......
...@@ -155,6 +155,7 @@ class TelescopeModelXMLGeneratorType1(object): ...@@ -155,6 +155,7 @@ class TelescopeModelXMLGeneratorType1(object):
stations.remove(station) stations.remove(station)
# add new ones # add new ones
if station_list:
for stationname in station_list: for stationname in station_list:
station = etree.Element('station', name=stationname) station = etree.Element('station', name=stationname)
stations.append(station) stations.append(station)
......
...@@ -59,6 +59,10 @@ ...@@ -59,6 +59,10 @@
<enableSuperterp>false</enableSuperterp> <enableSuperterp>false</enableSuperterp>
<numberOfBitsPerSample>8</numberOfBitsPerSample> <numberOfBitsPerSample>8</numberOfBitsPerSample>
<stationSelectionSpecification> <stationSelectionSpecification>
<stationSelection>
<stationSet>INTERNATIONAL</stationSet>
<minimumConstraint>3</minimumConstraint>
</stationSelection>
<stationSelection> <stationSelection>
<stationSet>Custom</stationSet> <stationSet>Custom</stationSet>
<stations> <stations>
......
...@@ -83,6 +83,10 @@ ...@@ -83,6 +83,10 @@
<enableSuperterp>false</enableSuperterp> <enableSuperterp>false</enableSuperterp>
<numberOfBitsPerSample>8</numberOfBitsPerSample> <numberOfBitsPerSample>8</numberOfBitsPerSample>
<stationSelectionSpecification> <stationSelectionSpecification>
<stationSelection>
<stationSet>INTERNATIONAL</stationSet>
<minimumConstraint>3</minimumConstraint>
</stationSelection>
<stationSelection> <stationSelection>
<stationSet>Custom</stationSet> <stationSet>Custom</stationSet>
<stations> <stations>
...@@ -130,8 +134,16 @@ ...@@ -130,8 +134,16 @@
<timeWindowSpecification> <timeWindowSpecification>
<timeFrame>UT</timeFrame> <timeFrame>UT</timeFrame>
<startTime>2016-11-23T15:21:44</startTime> <startTime>2016-11-23T15:21:44</startTime>
<!--
<minStartTime>2017-05-23T15:21:44</minStartTime>
<maxEndTime>2017-11-23T15:21:44</maxEndTime>
-->
<duration> <duration>
<duration>PT3600S</duration> <duration>PT3600S</duration>
<!--
<minimumDuration>PT100S</minimumDuration>
<maximumDuration>PT2000S</maximumDuration>
-->
</duration> </duration>
</timeWindowSpecification> </timeWindowSpecification>
</observation> </observation>
......
...@@ -113,8 +113,12 @@ class TestLofarXMLToMomXMLModelTranslator(unittest.TestCase): ...@@ -113,8 +113,12 @@ class TestLofarXMLToMomXMLModelTranslator(unittest.TestCase):
def test_generateModel_should_return_model_filled_with_station_selection(self): def test_generateModel_should_return_model_filled_with_station_selection(self):
translator = LofarXMLToMomXMLModelTranslator() translator = LofarXMLToMomXMLModelTranslator()
model = translator.generate_model(self.lofar_spec) model = translator.generate_model(self.lofar_spec)
self.assertEqual(model.station_selection, None) # todo: add sth to trigger that we can evaluate expected = {"CS001": 1, "CS002": 1, "CS003": 1, "CS004": 1, "CS005": 1, "CS006": 1, "CS007": 1, "CS011": 1,
"CS013": 1, "CS017": 1, "CS021": 1, "CS024": 1, "CS026": 1, "CS028": 1, "CS030": 1, "CS031": 1,
"CS032": 1, "CS101": 1, "CS103": 1, "CS201": 1, "CS301": 1, "CS302": 1, "CS401": 1, "CS501": 1,
"RS106": 1, "RS205": 1, "RS208": 1, "RS210": 1, "RS305": 1, "RS306": 1, "RS307": 1, "RS310": 1,
"RS406": 1, "RS407": 1, "RS409": 1, "RS503": 1, "RS508": 1, "RS509": 1, 'INTERNATIONAL': '3'}
self.assertEqual(model.station_selection, expected)
def test_generate_model_should_return_model_filled_with_correct_foldernames(self): def test_generate_model_should_return_model_filled_with_correct_foldernames(self):
translator = LofarXMLToMomXMLModelTranslator() translator = LofarXMLToMomXMLModelTranslator()
......
<lofar:project xmlns:mom2="http://www.astron.nl/MoM2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:lofar="http://www.astron.nl/MoM2-Lofar" xsi:schemaLocation="http://www.astron.nl/MoM2-Lofar ../ResponsiveTelescope-9893/SAS/SpecificationServices/xsd/LofarMoM2.xsd">
<version>2.17.0</version>
<template version="2.17.0" author="Alwin de Jong,Adriaan Renting" changedBy="Adriaan Renting">
<description>XML Template generator version 2.17.0</description>
</template>
<name>test-lofar</name>
<children>
<item index="0">
<lofar:folder topology_parent="false" update_folder="true">
<name>TARGET_A</name>
<description>First target</description>
<children>
<item index="0">
<lofar:folder topology_parent="true" update_folder="false">
<topology>0</topology>
<name>AARTFAAC-TRIGGERED</name>
<description>Triggered observation by AARTFAAC (Preprocessing)</description>
<children>
<item index="0">
<lofar:observation>
<name>Target/1/TO</name>
<description>Target/1/TO (Target Observation)</description>
<topology>B0.1.T</topology>
<predecessor_topology/>
<currentStatus>
<mom2:approvedStatus/>
</currentStatus>
<lofar:observationAttributes>
<name>Target/1/TO</name>
<projectName>test-lofar</projectName>
<instrument>Beam Observation</instrument>
<defaultTemplate>BeamObservation</defaultTemplate>
<tbbPiggybackAllowed>true</tbbPiggybackAllowed>
<aartfaacPiggybackAllowed>true</aartfaacPiggybackAllowed>
<userSpecification>
<correlatedData>true</correlatedData>
<coherentStokesData>false</coherentStokesData>
<incoherentStokesData>false</incoherentStokesData>
<antenna>LBA Outer</antenna>
<clock mode="200 MHz"/>
<instrumentFilter>30-90 MHz</instrumentFilter>
<integrationInterval>2.0</integrationInterval>
<channelsPerSubband>64</channelsPerSubband>
<coherentDedisperseChannels>false</coherentDedisperseChannels>
<tiedArrayBeams>
<flyseye>false</flyseye>
</tiedArrayBeams>
<stokes/>
<stationSet>Custom</stationSet>
<stations>
<station name="CS001"/><station name="CS002"/><station name="CS003"/><station name="CS004"/><station name="CS005"/><station name="CS006"/><station name="CS007"/><station name="CS011"/><station name="CS013"/><station name="CS017"/><station name="CS021"/><station name="CS024"/><station name="CS026"/><station name="CS028"/><station name="CS030"/><station name="CS031"/><station name="CS032"/><station name="CS101"/><station name="CS103"/><station name="CS201"/><station name="CS301"/><station name="CS302"/><station name="CS401"/><station name="CS501"/><station name="RS106"/><station name="RS205"/><station name="RS208"/><station name="RS210"/><station name="RS305"/><station name="RS306"/><station name="RS307"/><station name="RS310"/><station name="RS406"/><station name="RS407"/><station name="RS409"/><station name="RS503"/><station name="RS508"/><station name="RS509"/></stations>
<timeFrame>UT</timeFrame>
<startTime/>
<endTime>2016-11-23T16:21:44</endTime>
<duration/>
<bypassPff>false</bypassPff>
<enableSuperterp>false</enableSuperterp>
<numberOfBitsPerSample>8</numberOfBitsPerSample>
<misc>{"timeWindow": {"minStartTime": "2017-05-23T15:21:44", "maxEndTime": "2017-11-23T15:21:44", "maxDuration": "PT7200S", "minDuration": "PT1600S"}, "stationSelection": [{"resourceGroup": "CS401", "min": 1}, {"resourceGroup": "RS509", "min": 1}, {"resourceGroup": "RS210", "min": 1}, {"resourceGroup": "RS208", "min": 1}, {"resourceGroup": "CS007", "min": 1}, {"resourceGroup": "CS501", "min": 1}, {"resourceGroup": "RS503", "min": 1}, {"resourceGroup": "RS106", "min": 1}, {"resourceGroup": "RS406", "min": 1}, {"resourceGroup": "CS103", "min": 1}, {"resourceGroup": "CS017", "min": 1}, {"resourceGroup": "CS005", "min": 1}, {"resourceGroup": "CS013", "min": 1}, {"resourceGroup": "INTERNATIONAL", "min": "3"}, {"resourceGroup": "RS310", "min": 1}, {"resourceGroup": "CS031", "min": 1}, {"resourceGroup": "RS305", "min": 1}, {"resourceGroup": "RS307", "min": 1}, {"resourceGroup": "RS205", "min": 1}, {"resourceGroup": "RS409", "min": 1}, {"resourceGroup": "CS301", "min": 1}, {"resourceGroup": "CS302", "min": 1}, {"resourceGroup": "CS028", "min": 1}, {"resourceGroup": "RS508", "min": 1}, {"resourceGroup": "RS407", "min": 1}, {"resourceGroup": "CS003", "min": 1}, {"resourceGroup": "CS024", "min": 1}, {"resourceGroup": "CS001", "min": 1}, {"resourceGroup": "CS026", "min": 1}, {"resourceGroup": "CS021", "min": 1}, {"resourceGroup": "CS006", "min": 1}, {"resourceGroup": "CS030", "min": 1}, {"resourceGroup": "CS004", "min": 1}, {"resourceGroup": "CS032", "min": 1}, {"resourceGroup": "CS101", "min": 1}, {"resourceGroup": "CS002", "min": 1}, {"resourceGroup": "CS201", "min": 1}, {"resourceGroup": "RS306", "min": 1}, {"resourceGroup": "CS011", "min": 1}], "trigger_id": 1}</misc>
</userSpecification>
</lofar:observationAttributes>
<children>
<item index="0">
<lofar:measurement xsi:type="lofar:BFMeasurementType">
<name>Target</name>
<description>Target</description>
<topology>B0.1.T.SAP000</topology>
<currentStatus>
<mom2:approvedStatus/>
</currentStatus>
<lofar:bfMeasurementAttributes>
<measurementType>Target</measurementType>
<specification>
<targetName>Target</targetName>
<ra>204.648425</ra>
<dec>-0.172222222222</dec>
<equinox>J2000</equinox>
<duration>PT0S</duration>
<subbandsSpecification>
<subbands>160..399</subbands>
</subbandsSpecification>
<tiedArrayBeams>
<flyseye>false</flyseye>
<nrTabRings>0</nrTabRings>
<tabRingSize>0</tabRingSize>
<tiedArrayBeamList/>
</tiedArrayBeams>
</specification>
</lofar:bfMeasurementAttributes>
<resultDataProducts>
<item>
<lofar:uvDataProduct>
<name>B0.1.T.SAP000.uv.dps</name>
<topology>B0.1.T.SAP000.uv.dps</topology>
<status>no_data</status>
<storageCluster>
<name>CEP4</name>
<partition>/data/projects/</partition>
</storageCluster>
</lofar:uvDataProduct>
</item>
</resultDataProducts>
</lofar:measurement>
</item>
<item index="0">
<lofar:measurement xsi:type="lofar:BFMeasurementType">
<name>Calibrator</name>
<description>Calibrator</description>
<topology>B0.1.T.SAP001</topology>
<currentStatus>
<mom2:approvedStatus/>
</currentStatus>
<lofar:bfMeasurementAttributes>
<measurementType>Calibration</measurementType>
<specification>
<targetName>Calibrator</targetName>
<ra>123.400291667</ra>
<dec>48.2173833333</dec>
<equinox>J2000</equinox>
<duration>PT0S</duration>
<subbandsSpecification>
<subbands>160..399</subbands>
</subbandsSpecification>
<tiedArrayBeams>
<flyseye>false</flyseye>
<nrTabRings>0</nrTabRings>
<tabRingSize>0</tabRingSize>
<tiedArrayBeamList/>
</tiedArrayBeams>
</specification>
</lofar:bfMeasurementAttributes>
<resultDataProducts>
<item>
<lofar:uvDataProduct>
<name>B0.1.T.SAP001.uv.dps</name>
<topology>B0.1.T.SAP001.uv.dps</topology>
<status>no_data</status>
<storageCluster>
<name>CEP4</name>
<partition>/data/projects/</partition>
</storageCluster>
</lofar:uvDataProduct>
</item>
</resultDataProducts>
</lofar:measurement>
</item>
</children>
</lofar:observation>
</item>
<item index="0">
<lofar:pipeline xsi:type="lofar:AveragingPipelineType">
<topology>B0.1.CPT</topology>
<predecessor_topology>B0.1.T</predecessor_topology>
<name>Calibrator/1/CPT</name>
<description>Calibrator/1/CPT (Preprocessing)</description>
<processingCluster>
<name>CEP4</name>
<partition>cpu</partition>
<numberOfTasks>24</numberOfTasks>
<minRAMPerTask unit="byte">1000000000</minRAMPerTask>
<minScratchPerTask unit="byte">100000000</minScratchPerTask>
<maxDurationPerTask>PT600S</maxDurationPerTask>
<numberOfCoresPerTask>20</numberOfCoresPerTask>
<runSimultaneous>true</runSimultaneous>
</processingCluster>
<currentStatus>
<mom2:approvedStatus/>
</currentStatus>
<lofar:averagingPipelineAttributes>
<misc>{"timeWindow": {"minStartTime": "2017-05-23T15:21:44", "maxEndTime": "2017-11-23T15:21:44", "maxDuration": "PT7200S", "minDuration": "PT1600S"}, "stationSelection": [{"resourceGroup": "CS401", "min": 1}, {"resourceGroup": "RS509", "min": 1}, {"resourceGroup": "RS210", "min": 1}, {"resourceGroup": "RS208", "min": 1}, {"resourceGroup": "CS007", "min": 1}, {"resourceGroup": "CS501", "min": 1}, {"resourceGroup": "RS503", "min": 1}, {"resourceGroup": "RS106", "min": 1}, {"resourceGroup": "RS406", "min": 1}, {"resourceGroup": "CS103", "min": 1}, {"resourceGroup": "CS017", "min": 1}, {"resourceGroup": "CS005", "min": 1}, {"resourceGroup": "CS013", "min": 1}, {"resourceGroup": "INTERNATIONAL", "min": "3"}, {"resourceGroup": "RS310", "min": 1}, {"resourceGroup": "CS031", "min": 1}, {"resourceGroup": "RS305", "min": 1}, {"resourceGroup": "RS307", "min": 1}, {"resourceGroup": "RS205", "min": 1}, {"resourceGroup": "RS409", "min": 1}, {"resourceGroup": "CS301", "min": 1}, {"resourceGroup": "CS302", "min": 1}, {"resourceGroup": "CS028", "min": 1}, {"resourceGroup": "RS508", "min": 1}, {"resourceGroup": "RS407", "min": 1}, {"resourceGroup": "CS003", "min": 1}, {"resourceGroup": "CS024", "min": 1}, {"resourceGroup": "CS001", "min": 1}, {"resourceGroup": "CS026", "min": 1}, {"resourceGroup": "CS021", "min": 1}, {"resourceGroup": "CS006", "min": 1}, {"resourceGroup": "CS030", "min": 1}, {"resourceGroup": "CS004", "min": 1}, {"resourceGroup": "CS032", "min": 1}, {"resourceGroup": "CS101", "min": 1}, {"resourceGroup": "CS002", "min": 1}, {"resourceGroup": "CS201", "min": 1}, {"resourceGroup": "RS306", "min": 1}, {"resourceGroup": "CS011", "min": 1}], "trigger_id": 1}</misc>
<defaultTemplate>Preprocessing Pipeline</defaultTemplate>
<duration>PT7200S</duration>
<demixingParameters>
<averagingFreqStep>16</averagingFreqStep>
<averagingTimeStep>1</averagingTimeStep>
<demixFreqStep>16</demixFreqStep>
<demixTimeStep>5</demixTimeStep>
</demixingParameters>
<flaggingStrategy>LBAdefault</flaggingStrategy>
</lofar:averagingPipelineAttributes>
<usedDataProducts>
<item>
<lofar:uvDataProduct topology="B0.1.T.SAP001.uv.dps"/>
</item>
</usedDataProducts>
<resultDataProducts>
<item>
<lofar:uvDataProduct>
<name>B0.1.CPT.uv.dps</name>
<topology>B0.1.CPT.uv.dps</topology>
<status>no_data</status>
<storageCluster>
<name>CEP4</name>
<partition>/data/projects/</partition>
</storageCluster>
</lofar:uvDataProduct>
</item>
</resultDataProducts>
</lofar:pipeline>
</item>
<item index="0">
<lofar:pipeline xsi:type="lofar:AveragingPipelineType">
<topology>B0.1.PT0</topology>
<predecessor_topology>B0.1.T</predecessor_topology>
<name>Target/1.0/TP</name>
<description>Target/1.0/TP (Preprocessing)</description>
<processingCluster>
<name>CEP4</name>
<partition>cpu</partition>
<numberOfTasks>24</numberOfTasks>
<minRAMPerTask unit="byte">1000000000</minRAMPerTask>
<minScratchPerTask unit="byte">100000000</minScratchPerTask>
<maxDurationPerTask>PT600S</maxDurationPerTask>
<numberOfCoresPerTask>20</numberOfCoresPerTask>
<runSimultaneous>true</runSimultaneous>
</processingCluster>
<currentStatus>
<mom2:approvedStatus/>
</currentStatus>
<lofar:averagingPipelineAttributes>
<misc>{"timeWindow": {"minStartTime": "2017-05-23T15:21:44", "maxEndTime": "2017-11-23T15:21:44", "maxDuration": "PT7200S", "minDuration": "PT1600S"}, "stationSelection": [{"resourceGroup": "CS401", "min": 1}, {"resourceGroup": "RS509", "min": 1}, {"resourceGroup": "RS210", "min": 1}, {"resourceGroup": "RS208", "min": 1}, {"resourceGroup": "CS007", "min": 1}, {"resourceGroup": "CS501", "min": 1}, {"resourceGroup": "RS503", "min": 1}, {"resourceGroup": "RS106", "min": 1}, {"resourceGroup": "RS406", "min": 1}, {"resourceGroup": "CS103", "min": 1}, {"resourceGroup": "CS017", "min": 1}, {"resourceGroup": "CS005", "min": 1}, {"resourceGroup": "CS013", "min": 1}, {"resourceGroup": "INTERNATIONAL", "min": "3"}, {"resourceGroup": "RS310", "min": 1}, {"resourceGroup": "CS031", "min": 1}, {"resourceGroup": "RS305", "min": 1}, {"resourceGroup": "RS307", "min": 1}, {"resourceGroup": "RS205", "min": 1}, {"resourceGroup": "RS409", "min": 1}, {"resourceGroup": "CS301", "min": 1}, {"resourceGroup": "CS302", "min": 1}, {"resourceGroup": "CS028", "min": 1}, {"resourceGroup": "RS508", "min": 1}, {"resourceGroup": "RS407", "min": 1}, {"resourceGroup": "CS003", "min": 1}, {"resourceGroup": "CS024", "min": 1}, {"resourceGroup": "CS001", "min": 1}, {"resourceGroup": "CS026", "min": 1}, {"resourceGroup": "CS021", "min": 1}, {"resourceGroup": "CS006", "min": 1}, {"resourceGroup": "CS030", "min": 1}, {"resourceGroup": "CS004", "min": 1}, {"resourceGroup": "CS032", "min": 1}, {"resourceGroup": "CS101", "min": 1}, {"resourceGroup": "CS002", "min": 1}, {"resourceGroup": "CS201", "min": 1}, {"resourceGroup": "RS306", "min": 1}, {"resourceGroup": "CS011", "min": 1}], "trigger_id": 1}</misc>
<defaultTemplate>Preprocessing Pipeline</defaultTemplate>
<duration>PT7200S</duration>
<demixingParameters>
<averagingFreqStep>16</averagingFreqStep>
<averagingTimeStep>1</averagingTimeStep>
<demixFreqStep>16</demixFreqStep>
<demixTimeStep>5</demixTimeStep>
<demixIfNeeded>CygA</demixIfNeeded>
</demixingParameters>
<flaggingStrategy>LBAdefault</flaggingStrategy>
</lofar:averagingPipelineAttributes>
<usedDataProducts>
<item>
<lofar:uvDataProduct topology="B0.1.T.SAP000.uv.dps"/>
</item>
</usedDataProducts>
<resultDataProducts>
<item>
<lofar:uvDataProduct>
<name>B0.1.PT0.uv.dps</name>
<topology>B0.1.PT0.uv.dps</topology>
<status>no_data</status>
<storageCluster>
<name>CEP4</name>
<partition>/data/projects/</partition>
</storageCluster>
</lofar:uvDataProduct>
</item>
</resultDataProducts>
</lofar:pipeline>
</item>
</children>
</lofar:folder>
</item>
</children>
</lofar:folder>
</item>
</children>
</lofar:project>
\ No newline at end of file
...@@ -48,45 +48,7 @@ ...@@ -48,45 +48,7 @@
<stokes/> <stokes/>
<stationSet>Custom</stationSet> <stationSet>Custom</stationSet>
<stations> <stations>
<station name="CS001"/> <station name="CS001"/><station name="CS002"/><station name="CS003"/><station name="CS004"/><station name="CS005"/><station name="CS006"/><station name="CS007"/><station name="CS011"/><station name="CS013"/><station name="CS017"/><station name="CS021"/><station name="CS024"/><station name="CS026"/><station name="CS028"/><station name="CS030"/><station name="CS031"/><station name="CS032"/><station name="CS101"/><station name="CS103"/><station name="CS201"/><station name="CS301"/><station name="CS302"/><station name="CS401"/><station name="CS501"/><station name="RS106"/><station name="RS205"/><station name="RS208"/><station name="RS210"/><station name="RS305"/><station name="RS306"/><station name="RS307"/><station name="RS310"/><station name="RS406"/><station name="RS407"/><station name="RS409"/><station name="RS503"/><station name="RS508"/><station name="RS509"/></stations>
<station name="CS002"/>
<station name="CS003"/>
<station name="CS004"/>
<station name="CS005"/>
<station name="CS006"/>
<station name="CS007"/>
<station name="CS011"/>
<station name="CS013"/>
<station name="CS017"/>
<station name="CS021"/>
<station name="CS024"/>
<station name="CS026"/>
<station name="CS028"/>
<station name="CS030"/>
<station name="CS031"/>
<station name="CS032"/>
<station name="CS101"/>
<station name="CS103"/>
<station name="CS201"/>
<station name="CS301"/>
<station name="CS302"/>
<station name="CS401"/>
<station name="CS501"/>
<station name="RS106"/>
<station name="RS205"/>
<station name="RS208"/>
<station name="RS210"/>
<station name="RS305"/>
<station name="RS306"/>
<station name="RS307"/>
<station name="RS310"/>
<station name="RS406"/>
<station name="RS407"/>
<station name="RS409"/>
<station name="RS503"/>
<station name="RS508"/>
<station name="RS509"/>
</stations>
<timeFrame>UT</timeFrame> <timeFrame>UT</timeFrame>
<startTime>2016-11-23T15:21:44</startTime> <startTime>2016-11-23T15:21:44</startTime>
<endTime>2016-11-23T16:21:44</endTime> <endTime>2016-11-23T16:21:44</endTime>
...@@ -94,7 +56,7 @@ ...@@ -94,7 +56,7 @@
<bypassPff>false</bypassPff> <bypassPff>false</bypassPff>
<enableSuperterp>false</enableSuperterp> <enableSuperterp>false</enableSuperterp>
<numberOfBitsPerSample>8</numberOfBitsPerSample> <numberOfBitsPerSample>8</numberOfBitsPerSample>
<misc>{"trigger_id": 1}</misc> <misc>{"stationSelection": [{"resourceGroup": "CS401", "min": 1}, {"resourceGroup": "RS509", "min": 1}, {"resourceGroup": "RS210", "min": 1}, {"resourceGroup": "RS208", "min": 1}, {"resourceGroup": "CS007", "min": 1}, {"resourceGroup": "CS501", "min": 1}, {"resourceGroup": "RS503", "min": 1}, {"resourceGroup": "RS106", "min": 1}, {"resourceGroup": "RS406", "min": 1}, {"resourceGroup": "CS103", "min": 1}, {"resourceGroup": "CS017", "min": 1}, {"resourceGroup": "CS005", "min": 1}, {"resourceGroup": "CS013", "min": 1}, {"resourceGroup": "RS310", "min": 1}, {"resourceGroup": "CS031", "min": 1}, {"resourceGroup": "RS305", "min": 1}, {"resourceGroup": "RS307", "min": 1}, {"resourceGroup": "RS205", "min": 1}, {"resourceGroup": "RS409", "min": 1}, {"resourceGroup": "CS301", "min": 1}, {"resourceGroup": "CS302", "min": 1}, {"resourceGroup": "CS028", "min": 1}, {"resourceGroup": "RS508", "min": 1}, {"resourceGroup": "RS407", "min": 1}, {"resourceGroup": "CS003", "min": 1}, {"resourceGroup": "CS002", "min": 1}, {"resourceGroup": "CS001", "min": 1}, {"resourceGroup": "CS026", "min": 1}, {"resourceGroup": "CS021", "min": 1}, {"resourceGroup": "CS006", "min": 1}, {"resourceGroup": "CS030", "min": 1}, {"resourceGroup": "CS004", "min": 1}, {"resourceGroup": "CS032", "min": 1}, {"resourceGroup": "CS101", "min": 1}, {"resourceGroup": "CS024", "min": 1}, {"resourceGroup": "CS201", "min": 1}, {"resourceGroup": "RS306", "min": 1}, {"resourceGroup": "CS011", "min": 1}], "trigger_id": 1}</misc>
</userSpecification> </userSpecification>
</lofar:observationAttributes> </lofar:observationAttributes>
<children> <children>
...@@ -205,7 +167,7 @@ ...@@ -205,7 +167,7 @@
<mom2:approvedStatus/> <mom2:approvedStatus/>
</currentStatus> </currentStatus>
<lofar:averagingPipelineAttributes> <lofar:averagingPipelineAttributes>
<misc>{"trigger_id": 1}</misc> <misc>{"stationSelection": [{"resourceGroup": "CS401", "min": 1}, {"resourceGroup": "RS509", "min": 1}, {"resourceGroup": "RS210", "min": 1}, {"resourceGroup": "RS208", "min": 1}, {"resourceGroup": "CS007", "min": 1}, {"resourceGroup": "CS501", "min": 1}, {"resourceGroup": "RS503", "min": 1}, {"resourceGroup": "RS106", "min": 1}, {"resourceGroup": "RS406", "min": 1}, {"resourceGroup": "CS103", "min": 1}, {"resourceGroup": "CS017", "min": 1}, {"resourceGroup": "CS005", "min": 1}, {"resourceGroup": "CS013", "min": 1}, {"resourceGroup": "RS310", "min": 1}, {"resourceGroup": "CS031", "min": 1}, {"resourceGroup": "RS305", "min": 1}, {"resourceGroup": "RS307", "min": 1}, {"resourceGroup": "RS205", "min": 1}, {"resourceGroup": "RS409", "min": 1}, {"resourceGroup": "CS301", "min": 1}, {"resourceGroup": "CS302", "min": 1}, {"resourceGroup": "CS028", "min": 1}, {"resourceGroup": "RS508", "min": 1}, {"resourceGroup": "RS407", "min": 1}, {"resourceGroup": "CS003", "min": 1}, {"resourceGroup": "CS002", "min": 1}, {"resourceGroup": "CS001", "min": 1}, {"resourceGroup": "CS026", "min": 1}, {"resourceGroup": "CS021", "min": 1}, {"resourceGroup": "CS006", "min": 1}, {"resourceGroup": "CS030", "min": 1}, {"resourceGroup": "CS004", "min": 1}, {"resourceGroup": "CS032", "min": 1}, {"resourceGroup": "CS101", "min": 1}, {"resourceGroup": "CS024", "min": 1}, {"resourceGroup": "CS201", "min": 1}, {"resourceGroup": "RS306", "min": 1}, {"resourceGroup": "CS011", "min": 1}], "trigger_id": 1}</misc>
<defaultTemplate>Preprocessing Pipeline</defaultTemplate> <defaultTemplate>Preprocessing Pipeline</defaultTemplate>
<duration>PT7200S</duration> <duration>PT7200S</duration>
<demixingParameters> <demixingParameters>
...@@ -256,7 +218,7 @@ ...@@ -256,7 +218,7 @@
<mom2:approvedStatus/> <mom2:approvedStatus/>
</currentStatus> </currentStatus>
<lofar:averagingPipelineAttributes> <lofar:averagingPipelineAttributes>
<misc>{"trigger_id": 1}</misc> <misc>{"stationSelection": [{"resourceGroup": "CS401", "min": 1}, {"resourceGroup": "RS509", "min": 1}, {"resourceGroup": "RS210", "min": 1}, {"resourceGroup": "RS208", "min": 1}, {"resourceGroup": "CS007", "min": 1}, {"resourceGroup": "CS501", "min": 1}, {"resourceGroup": "RS503", "min": 1}, {"resourceGroup": "RS106", "min": 1}, {"resourceGroup": "RS406", "min": 1}, {"resourceGroup": "CS103", "min": 1}, {"resourceGroup": "CS017", "min": 1}, {"resourceGroup": "CS005", "min": 1}, {"resourceGroup": "CS013", "min": 1}, {"resourceGroup": "RS310", "min": 1}, {"resourceGroup": "CS031", "min": 1}, {"resourceGroup": "RS305", "min": 1}, {"resourceGroup": "RS307", "min": 1}, {"resourceGroup": "RS205", "min": 1}, {"resourceGroup": "RS409", "min": 1}, {"resourceGroup": "CS301", "min": 1}, {"resourceGroup": "CS302", "min": 1}, {"resourceGroup": "CS028", "min": 1}, {"resourceGroup": "RS508", "min": 1}, {"resourceGroup": "RS407", "min": 1}, {"resourceGroup": "CS003", "min": 1}, {"resourceGroup": "CS002", "min": 1}, {"resourceGroup": "CS001", "min": 1}, {"resourceGroup": "CS026", "min": 1}, {"resourceGroup": "CS021", "min": 1}, {"resourceGroup": "CS006", "min": 1}, {"resourceGroup": "CS030", "min": 1}, {"resourceGroup": "CS004", "min": 1}, {"resourceGroup": "CS032", "min": 1}, {"resourceGroup": "CS101", "min": 1}, {"resourceGroup": "CS024", "min": 1}, {"resourceGroup": "CS201", "min": 1}, {"resourceGroup": "RS306", "min": 1}, {"resourceGroup": "CS011", "min": 1}], "trigger_id": 1}</misc>
<defaultTemplate>Preprocessing Pipeline</defaultTemplate> <defaultTemplate>Preprocessing Pipeline</defaultTemplate>
<duration>PT7200S</duration> <duration>PT7200S</duration>
<demixingParameters> <demixingParameters>
......
<spec:specification xmlns:base="http://www.astron.nl/LofarBase" xmlns:spec="http://www.astron.nl/LofarSpecification" xmlns:trigger="http://www.astron.nl/LofarTrigger" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><version>2.20</version>
<projectReference>
<ProjectCode>LC7_030</ProjectCode>
</projectReference>
<userName>veen</userName>
<comment>comment</comment>
<generatorName>Jan David Mol</generatorName>
<generatorVersion>0.0</generatorVersion>
<!-- folders -->
<container>
<temporaryIdentifier>
<source>0</source>
<identifier>100</identifier>
</temporaryIdentifier>
<addToExistingContainer>false</addToExistingContainer>
<folder>
<name>TARGET_A</name>
<description>First target</description>
<topology>0</topology>
</folder>
</container>
<container>
<temporaryIdentifier>
<source>0</source>
<identifier>101</identifier>
</temporaryIdentifier>
<addToExistingContainer>false</addToExistingContainer>
<folder>
<name>AARTFAAC-TRIGGERED</name>
<description>Triggered observation by AARTFAAC (Preprocessing)</description>
<topology>0</topology>
</folder>
</container>
<!-- observation -->
<activity>
<temporaryIdentifier>
<source>0</source>
<identifier>200</identifier>
<description>0</description>
</temporaryIdentifier>
<observation>
<name>Target/1/TO</name>
<description>Target/1/TO (Target Observation)</description>
<instrument>Beam Observation</instrument>
<defaultTemplate>BeamObservation</defaultTemplate>
<tbbPiggybackAllowed>true</tbbPiggybackAllowed>
<aartfaacPiggybackAllowed>true</aartfaacPiggybackAllowed>
<correlatedData>true</correlatedData>
<coherentStokesData>false</coherentStokesData>
<incoherentStokesData>false</incoherentStokesData>
<antenna>LBA Outer</antenna>
<clock units="MHz">200</clock>
<instrumentFilter>30-90 MHz</instrumentFilter>
<integrationInterval>2.0</integrationInterval>
<channelsPerSubband>64</channelsPerSubband>
<bypassPff>false</bypassPff>
<enableSuperterp>false</enableSuperterp>
<numberOfBitsPerSample>8</numberOfBitsPerSample>
<stationSelectionSpecification>
<stationSelection>
<stationSet>INTERNATIONAL</stationSet>
<minimumConstraint>3</minimumConstraint>
</stationSelection>
<stationSelection>
<stationSet>Custom</stationSet>
<stations>
<station><name>CS001</name></station>
<station><name>CS002</name></station>
<station><name>CS003</name></station>
<station><name>CS004</name></station>
<station><name>CS005</name></station>
<station><name>CS006</name></station>
<station><name>CS007</name></station>
<station><name>CS011</name></station>
<station><name>CS013</name></station>
<station><name>CS017</name></station>
<station><name>CS021</name></station>
<station><name>CS024</name></station>
<station><name>CS026</name></station>
<station><name>CS028</name></station>
<station><name>CS030</name></station>
<station><name>CS031</name></station>
<station><name>CS032</name></station>
<station><name>CS101</name></station>
<station><name>CS103</name></station>
<station><name>CS201</name></station>
<station><name>CS301</name></station>
<station><name>CS302</name></station>
<station><name>CS401</name></station>
<station><name>CS501</name></station>
<station><name>RS106</name></station>
<station><name>RS205</name></station>
<station><name>RS208</name></station>
<station><name>RS210</name></station>
<station><name>RS305</name></station>
<station><name>RS306</name></station>
<station><name>RS307</name></station>
<station><name>RS310</name></station>
<station><name>RS406</name></station>
<station><name>RS407</name></station>
<station><name>RS409</name></station>
<station><name>RS503</name></station>
<station><name>RS508</name></station>
<station><name>RS509</name></station>
</stations>
</stationSelection>
</stationSelectionSpecification>
<timeWindowSpecification>
<timeFrame>UT</timeFrame>
<minStartTime>2017-05-23T15:21:44</minStartTime>
<maxEndTime>2017-11-23T15:21:44</maxEndTime>
<duration>
<minimumDuration>PT1600S</minimumDuration>
<maximumDuration>PT7200S</maximumDuration>
</duration>
</timeWindowSpecification>
</observation>
<status>approved</status>
<qualityOfService>LATENCY</qualityOfService>
<priority>1010</priority>
<triggerId><source>MoM</source><identifier>1</identifier></triggerId></activity>
<!-- SAP 0 -->
<activity>
<temporaryIdentifier>
<source>0</source>
<identifier>300</identifier>
<description>0</description>
</temporaryIdentifier>
<measurement xsi:type="base:BeamMeasurement">
<name>Target</name>
<description>Target</description>
<ra>204.648425</ra>
<dec>-0.172222222222</dec>
<equinox>J2000</equinox>
<subbandsSpecification>
<subbands>160..399</subbands>
</subbandsSpecification>
<measurementType>Target</measurementType>
</measurement>
<status>approved</status>
<qualityOfService>LATENCY</qualityOfService>
<priority>1010</priority>
<triggerId><source>MoM</source><identifier>1</identifier></triggerId></activity>
<!-- SAP 1 -->
<activity>
<temporaryIdentifier>
<source>0</source>
<identifier>301</identifier>
<description>0</description>
</temporaryIdentifier>
<measurement xsi:type="base:BeamMeasurement">
<name>Calibrator</name>
<description>Calibrator</description>
<ra>123.400291667</ra>
<dec>48.2173833333</dec>
<equinox>J2000</equinox>
<subbandsSpecification>
<subbands>160..339</subbands>
</subbandsSpecification>
<measurementType>Calibration</measurementType>
</measurement>
<status>approved</status>
<qualityOfService>LATENCY</qualityOfService>
<priority>1010</priority>
<triggerId><source>MoM</source><identifier>1</identifier></triggerId></activity>
<!-- Calibrator Averaging Pipeline -->
<activity>
<temporaryIdentifier>
<source>0</source>
<identifier>201</identifier>
<description>0</description>
</temporaryIdentifier>
<pipeline xsi:type="base:AveragingPipeline">
<name>Calibrator/1/CPT</name>
<description>Calibrator/1/CPT (Preprocessing)</description>
<processingCluster>
<name>CEP4</name>
<partition>cpu</partition>
<numberOfTasks>24</numberOfTasks>
<minRAMPerTask unit="byte">1000000000</minRAMPerTask>
<minScratchPerTask unit="byte">100000000</minScratchPerTask>
<maxDurationPerTask>PT600S</maxDurationPerTask>
<numberOfCoresPerTask>20</numberOfCoresPerTask>
<runSimultaneous>true</runSimultaneous>
</processingCluster>
<defaultTemplate>Preprocessing Pipeline</defaultTemplate>
<demixingParameters>
<averagingFreqStep>16</averagingFreqStep>
<averagingTimeStep>1</averagingTimeStep>
<demixFreqStep>16</demixFreqStep>
<demixTimeStep>5</demixTimeStep>
<demixAlways/>
<demixIfNeeded/>
<ignoreTarget>false</ignoreTarget>
</demixingParameters>
<flaggingStrategy>LBAdefault</flaggingStrategy>
</pipeline>
<status>approved</status>
<qualityOfService>LATENCY</qualityOfService>
<priority>1010</priority>
<triggerId><source>MoM</source><identifier>1</identifier></triggerId></activity>
<!-- Target Averaging Pipeline -->
<activity>
<temporaryIdentifier>
<source>0</source>
<identifier>202</identifier>
<description>0</description>
</temporaryIdentifier>
<pipeline xsi:type="base:AveragingPipeline">
<name>Calibrator/1/CPT</name>
<description>Calibrator/1/CPT (Preprocessing)</description>
<processingCluster>
<name>CEP4</name>
<partition>cpu</partition>
<numberOfTasks>24</numberOfTasks>
<minRAMPerTask unit="byte">1000000000</minRAMPerTask>
<minScratchPerTask unit="byte">100000000</minScratchPerTask>
<maxDurationPerTask>PT600S</maxDurationPerTask>
<numberOfCoresPerTask>20</numberOfCoresPerTask>
<runSimultaneous>true</runSimultaneous>
</processingCluster>
<defaultTemplate>Preprocessing Pipeline</defaultTemplate>
<demixingParameters>
<averagingFreqStep>16</averagingFreqStep>
<averagingTimeStep>1</averagingTimeStep>
<demixFreqStep>16</demixFreqStep>
<demixTimeStep>5</demixTimeStep>
<demixAlways/>
<demixIfNeeded/>
<ignoreTarget>false</ignoreTarget>
</demixingParameters>
<flaggingStrategy>LBAdefault</flaggingStrategy>
</pipeline>
<status>approved</status>
<qualityOfService>LATENCY</qualityOfService>
<priority>1010</priority>
<triggerId><source>MoM</source><identifier>1</identifier></triggerId></activity>
<!-- SAP 0 data products -->
<entity>
<temporaryIdentifier>
<source>0</source>
<identifier>400</identifier>
</temporaryIdentifier>
<dataproductType>UVDataProduct</dataproductType>
<storageCluster>
<name>CEP4</name>
<partition>/data/projects/</partition>
</storageCluster>
</entity>
<!-- SAP 1 data products -->
<entity>
<temporaryIdentifier>
<source>0</source>
<identifier>401</identifier>
</temporaryIdentifier>
<dataproductType>UVDataProduct</dataproductType>
<storageCluster>
<name>CEP4</name>
<partition>/data/projects/</partition>
</storageCluster>
</entity>
<!-- Calibrator Pipeline dataproducts -->
<entity>
<temporaryIdentifier>
<source>0</source>
<identifier>402</identifier>
</temporaryIdentifier>
<dataproductType>UVDataProduct</dataproductType>
<storageCluster>
<name>CEP4</name>
<partition>/data/projects/</partition>
</storageCluster>
</entity>
<!-- Target Pipeline dataproducts -->
<entity>
<temporaryIdentifier>
<source>0</source>
<identifier>403</identifier>
</temporaryIdentifier>
<dataproductType>UVDataProduct</dataproductType>
<storageCluster>
<name>CEP4</name>
<partition>/data/projects/</partition>
</storageCluster>
</entity>
<!-- folder 101 is child of folder 100 -->
<relation xsi:type="spec:ChildRelation">
<parent>
<source>0</source>
<identifier>100</identifier>
</parent>
<child>
<source>0</source>
<identifier>101</identifier>
</child>
<type>folder-folder</type>
</relation>
<!-- observation 200 is child of folder 101 -->
<relation xsi:type="spec:ChildRelation">
<parent>
<source>0</source>
<identifier>101</identifier>
</parent>
<child>
<source>0</source>
<identifier>200</identifier>
</child>
<type>folder-activity</type>
</relation>
<!-- measurements 300 is a child of observation 200 -->
<relation xsi:type="spec:ChildRelation">
<parent>
<source>0</source>
<identifier>200</identifier>
</parent>
<child>
<source>0</source>
<identifier>300</identifier>
</child>
<type>observation-measurement</type>
</relation>
<!-- measurement 301 is a child of observation 200 -->
<relation xsi:type="spec:ChildRelation">
<parent>
<source>0</source>
<identifier>200</identifier>
<description>0</description>
</parent>
<child>
<source>0</source>
<identifier>301</identifier>
<description>0</description>
</child>
<type>observation-measurement</type>
</relation>
<!-- dataproducts 400 are output of measurement 300 -->
<relation xsi:type="spec:ActivityEntityRelation">
<entity>
<source>0</source>
<identifier>400</identifier>
</entity>
<activity>
<source>0</source>
<identifier>300</identifier>
</activity>
<type>producer</type>
</relation>
<!-- dataproducts 401 are output of measurement 301 -->
<relation xsi:type="spec:ActivityEntityRelation">
<entity>
<source>0</source>
<identifier>401</identifier>
</entity>
<activity>
<source>0</source>
<identifier>301</identifier>
</activity>
<type>producer</type>
</relation>
<!-- SAP 1 is the calibrator for SAP 0 -->
<relation xsi:type="spec:TwinRelation">
<first>
<source>0</source>
<identifier>301</identifier>
</first>
<second>
<source>0</source>
<identifier>300</identifier>
</second>
<type>calibrator-target</type>
</relation>
<!-- dataproducts 401 are input for pipeline 201 -->
<relation xsi:type="spec:ActivityEntityRelation">
<entity>
<source>0</source>
<identifier>401</identifier>
</entity>
<activity>
<source>0</source>
<identifier>201</identifier>
</activity>
<type>user</type>
</relation>
<!-- dataproducts 402 are output of pipeline 201 -->
<relation xsi:type="spec:ActivityEntityRelation">
<entity>
<source>0</source>
<identifier>402</identifier>
</entity>
<activity>
<source>0</source>
<identifier>201</identifier>
</activity>
<type>producer</type>
</relation>
<!-- pipeline 201 is child of folder 101 -->
<relation xsi:type="spec:ChildRelation">
<parent>
<source>0</source>
<identifier>101</identifier>
</parent>
<child>
<source>0</source>
<identifier>201</identifier>
</child>
<type>folder-activity</type>
</relation>
<!-- dataproducts 400 are input for pipeline 202 -->
<relation xsi:type="spec:ActivityEntityRelation">
<entity>
<source>0</source>
<identifier>400</identifier>
</entity>
<activity>
<source>0</source>
<identifier>202</identifier>
</activity>
<type>user</type>
</relation>
<!-- pipeline 202 is child of folder 101 -->
<relation xsi:type="spec:ChildRelation">
<parent>
<source>0</source>
<identifier>101</identifier>
</parent>
<child>
<source>0</source>
<identifier>202</identifier>
</child>
<type>folder-activity</type>
</relation>
<!-- dataproducts 403 are output of pipeline 202 -->
<relation xsi:type="spec:ActivityEntityRelation">
<entity>
<source>0</source>
<identifier>403</identifier>
</entity>
<activity>
<source>0</source>
<identifier>202</identifier>
</activity>
<type>producer</type>
</relation>
</spec:specification>
...@@ -32,9 +32,15 @@ class TestSpecificationTranslationHandler(unittest.TestCase): ...@@ -32,9 +32,15 @@ class TestSpecificationTranslationHandler(unittest.TestCase):
lofar_file_handler = open("t_translation_service.in_xml/type-1-lofar.xml", "r") lofar_file_handler = open("t_translation_service.in_xml/type-1-lofar.xml", "r")
cls.xml = lofar_file_handler.read() cls.xml = lofar_file_handler.read()
lofar_file_handler_minmax = open("t_translation_service.in_xml/type-1-lofar-minmax.xml", "r")
cls.xml_minmax = lofar_file_handler_minmax.read()
mom_file_handler = open("t_translation_service.in_xml/telescope_model_xml_generator_type1.xml", "r") mom_file_handler = open("t_translation_service.in_xml/telescope_model_xml_generator_type1.xml", "r")
cls.expected_momxml = mom_file_handler.read() cls.expected_momxml = mom_file_handler.read()
mom_file_handler_minmax = open("t_translation_service.in_xml/telescope_model_xml_generator_type1-minmax.xml", "r")
cls.expected_momxml_minmax = mom_file_handler_minmax.read()
def setUp(self): def setUp(self):
validationrpc_patcher = mock.patch('lofar.specificationservices.translation_service.validationrpc') validationrpc_patcher = mock.patch('lofar.specificationservices.translation_service.validationrpc')
self.addCleanup(validationrpc_patcher.stop) self.addCleanup(validationrpc_patcher.stop)
...@@ -59,6 +65,13 @@ class TestSpecificationTranslationHandler(unittest.TestCase): ...@@ -59,6 +65,13 @@ class TestSpecificationTranslationHandler(unittest.TestCase):
self.assertEqual(momxml["mom-specification"], self.expected_momxml) self.assertEqual(momxml["mom-specification"], self.expected_momxml)
def test_specification_to_momspecification_should_return_expected_mom_xml_with_constraints(self):
handler = SpecificationTranslationHandler()
momxml_minmax = handler.specification_to_momspecification(self.xml_minmax)
self.assertEqual(momxml_minmax["mom-specification"], self.expected_momxml_minmax)
if __name__ == '__main__': if __name__ == '__main__':
unittest.main() unittest.main()
...@@ -134,8 +134,16 @@ ...@@ -134,8 +134,16 @@
<timeWindowSpecification> <timeWindowSpecification>
<timeFrame>UT</timeFrame> <timeFrame>UT</timeFrame>
<startTime>2016-11-23T15:21:44</startTime> <startTime>2016-11-23T15:21:44</startTime>
<!--
<minStartTime>2017-05-23T15:21:44</minStartTime>
<maxEndTime>2017-11-23T15:21:44</maxEndTime>
-->
<duration> <duration>
<duration>PT3600S</duration> <duration>PT3600S</duration>
<!--
<minimumDuration>PT1600S</minimumDuration>
<maximumDuration>PT7200S</maximumDuration>
-->
</duration> </duration>
</timeWindowSpecification> </timeWindowSpecification>
</observation> </observation>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment