JanusReader 0.2.0__tar.gz → 0.3.0__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.
- {JanusReader-0.2.0 → JanusReader-0.3.0}/PKG-INFO +1 -1
- {JanusReader-0.2.0 → JanusReader-0.3.0}/pyproject.toml +1 -1
- {JanusReader-0.2.0 → JanusReader-0.3.0}/src/JanusReader/janusReader.py +39 -6
- {JanusReader-0.2.0 → JanusReader-0.3.0}/src/JanusReader.egg-info/PKG-INFO +1 -1
- {JanusReader-0.2.0 → JanusReader-0.3.0}/README.md +0 -0
- {JanusReader-0.2.0 → JanusReader-0.3.0}/setup.cfg +0 -0
- {JanusReader-0.2.0 → JanusReader-0.3.0}/src/JanusReader/__init__.py +0 -0
- {JanusReader-0.2.0 → JanusReader-0.3.0}/src/JanusReader/exceptions.py +0 -0
- {JanusReader-0.2.0 → JanusReader-0.3.0}/src/JanusReader/vicar_head.py +0 -0
- {JanusReader-0.2.0 → JanusReader-0.3.0}/src/JanusReader.egg-info/SOURCES.txt +0 -0
- {JanusReader-0.2.0 → JanusReader-0.3.0}/src/JanusReader.egg-info/dependency_links.txt +0 -0
- {JanusReader-0.2.0 → JanusReader-0.3.0}/src/JanusReader.egg-info/requires.txt +0 -0
- {JanusReader-0.2.0 → JanusReader-0.3.0}/src/JanusReader.egg-info/top_level.txt +0 -0
|
@@ -83,7 +83,39 @@ class AcquisitionParameter:
|
|
|
83
83
|
tb.add_row("Multifilter","", str(self.multifilter))
|
|
84
84
|
return tb
|
|
85
85
|
|
|
86
|
-
|
|
86
|
+
class OnBoardProcessing:
|
|
87
|
+
|
|
88
|
+
def __init__(self,proc):
|
|
89
|
+
self.badPixelCorrection = int(getValue(
|
|
90
|
+
proc, 'juice_janus:bad_pixel_correction'))
|
|
91
|
+
self.badPixelMapName = getValue(
|
|
92
|
+
proc, 'juice_janus:bad_pixel_map_name')
|
|
93
|
+
self.badPixelCount = int(getValue(proc, 'juice_janus:bad_pixel_count'))
|
|
94
|
+
self.dnsuCorrection = int(getValue(proc, 'juice_janus:dsnu_correction'))
|
|
95
|
+
self.dnsuMapName = getValue(proc, 'juice_janus:dsnu_map_name')
|
|
96
|
+
self.spikeMaximumValue = int(
|
|
97
|
+
getValue(proc, 'juice_janus:spike_maximum_value'))
|
|
98
|
+
self.spikeDistance = int(getValue(proc, 'juice_janus:spike_distance'))
|
|
99
|
+
self.spikeCount = int(getValue(proc, 'juice_janus:spike_count'))
|
|
100
|
+
|
|
101
|
+
def Show(self):
|
|
102
|
+
tb = Table(expand=False, show_header=False,
|
|
103
|
+
show_lines=False, box=box.SIMPLE_HEAD,
|
|
104
|
+
title="Onboard Processing", title_style="italic yellow")
|
|
105
|
+
tb.add_column(style='yellow', justify='left')
|
|
106
|
+
tb.add_column()
|
|
107
|
+
tb.add_column()
|
|
108
|
+
tb.add_row("Bad Pixels Correction", "",str(self.badPixelCorrection))
|
|
109
|
+
tb.add_row("Bad Pixel Map Name","", self.badPixelMapName)
|
|
110
|
+
tb.add_row("Bad Pixel Count","", str(self.badPixelCount))
|
|
111
|
+
tb.add_section()
|
|
112
|
+
tb.add_row("DSNU Correction", "", str(self.dnsuCorrection))
|
|
113
|
+
tb.add_row("DSNU Map Name","", self.dnsuMapName)
|
|
114
|
+
tb.add_section()
|
|
115
|
+
tb.add_row("Spike Maximum Value", "", str(self.spikeMaximumValue))
|
|
116
|
+
tb.add_row("Spike Distance","", str(self.spikeDistance))
|
|
117
|
+
tb.add_row("Spike Distance","", str(self.spikeDistance))
|
|
118
|
+
return tb
|
|
87
119
|
|
|
88
120
|
class JanusReader:
|
|
89
121
|
"""Reader of the JANUS Data File
|
|
@@ -185,7 +217,8 @@ class JanusReader:
|
|
|
185
217
|
|
|
186
218
|
acqPar = getElement(idObs, "juice_janus:Acquisition_Properties")
|
|
187
219
|
self.AcquisitionParameter=AcquisitionParameter(acqPar)
|
|
188
|
-
|
|
220
|
+
obProc = getElement(idObs, "juice_janus:Onboard_Processing")
|
|
221
|
+
self.onBoardProcessing=OnBoardProcessing(obProc)
|
|
189
222
|
self.onGroundProcessing=None
|
|
190
223
|
self.HK=None
|
|
191
224
|
self.Downsamplig=None
|
|
@@ -204,7 +237,7 @@ class JanusReader:
|
|
|
204
237
|
|
|
205
238
|
|
|
206
239
|
# if self.Format == "HALF":
|
|
207
|
-
if self.
|
|
240
|
+
if self.level.lower()=='raw':
|
|
208
241
|
with open(self.fileName, 'rb') as f:
|
|
209
242
|
f.seek(self.Offset)
|
|
210
243
|
self.image=np.reshape(np.frombuffer(f.read(), dtype=np.uint16),(self.Lines,self.Samples))
|
|
@@ -243,7 +276,7 @@ class JanusReader:
|
|
|
243
276
|
tb.add_row("Pointing Mode", "", self.pointingMode)
|
|
244
277
|
tb.add_row("Observation Identifier", "", self.obsIdentifier)
|
|
245
278
|
tb.add_section()
|
|
246
|
-
tb.add_row("On Board processing", "",str(self.onBoardProcessing))
|
|
279
|
+
# tb.add_row("On Board processing", "",str(self.onBoardProcessing))
|
|
247
280
|
tb.add_row("On Ground Processing","",str(self.onGroundProcessing))
|
|
248
281
|
tb.add_row("HK","",str(self.HK))
|
|
249
282
|
tb.add_row("Downsampling","",str(self.Downsamplig))
|
|
@@ -251,9 +284,9 @@ class JanusReader:
|
|
|
251
284
|
tb.add_row("On Board Compression","",str(self.onBoardCompression))
|
|
252
285
|
tb.add_row("SubFrame","",str(self.subFrame))
|
|
253
286
|
tb.add_row("Header","", str(self.Header))
|
|
254
|
-
tb.add_row("Image","",str(self.image))
|
|
287
|
+
# tb.add_row("Image","",str(self.image))
|
|
255
288
|
if all:
|
|
256
|
-
col = Columns([tb, self.AcquisitionParameter.Show()],expand=False)
|
|
289
|
+
col = Columns([tb, self.AcquisitionParameter.Show(), self.onBoardProcessing.Show()],expand=False)
|
|
257
290
|
else:
|
|
258
291
|
col = tb
|
|
259
292
|
self.console.print(Panel(col ,title=f"Label for {self.fileName.name}", border_style='yellow', expand=False))
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|