Data Formats
TOAST has a built-in data format for storing compressed time ordered data on disk in one or more HDF5 files.
toast.ops.SaveHDF5
Bases: Operator
Operator which saves observations to HDF5.
This creates a file for each observation.
Source code in toast/ops/save_hdf5.py
139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 |
|
API = Int(0, help='Internal interface version for this operator')
class-attribute
instance-attribute
compress_detdata = Bool(False, help='If True, use FLAC to compress detector signal')
class-attribute
instance-attribute
compress_precision = Int(None, allow_none=True, help='Number of significant digits to retain in detdata compression')
class-attribute
instance-attribute
config = Dict({}, help='Write this job config to the file')
class-attribute
instance-attribute
detdata = List([defaults.det_data, defaults.det_flags], help='Only save this list of detdata objects')
class-attribute
instance-attribute
detdata_float32 = Bool(False, help='If True, convert any float64 detector data to float32 on write.')
class-attribute
instance-attribute
detdata_in_place = Bool(False, help='If True, all compressed detector data will be decompressed and written over the input data.')
class-attribute
instance-attribute
force_serial = Bool(False, help='Use serial HDF5 operations, even if parallel support available')
class-attribute
instance-attribute
intervals = List([], help='Only save this list of intervals objects')
class-attribute
instance-attribute
meta = List([], allow_none=True, help='Only save this list of meta objects')
class-attribute
instance-attribute
shared = List([], help='Only save this list of shared objects')
class-attribute
instance-attribute
times = Unicode(defaults.times, help='Observation shared key for timestamps')
class-attribute
instance-attribute
verify = Bool(False, help='If True, immediately load data back in and verify')
class-attribute
instance-attribute
volume = Unicode('toast_out_hdf5', allow_none=True, help='Top-level directory for the data volume')
class-attribute
instance-attribute
__init__(**kwargs)
Source code in toast/ops/save_hdf5.py
199 200 |
|
_exec(data, detectors=None, **kwargs)
Source code in toast/ops/save_hdf5.py
202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 |
|
_finalize(data, **kwargs)
Source code in toast/ops/save_hdf5.py
364 365 |
|
_provides()
Source code in toast/ops/save_hdf5.py
386 387 |
|
_requires()
Source code in toast/ops/save_hdf5.py
367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 |
|
toast.ops.LoadHDF5
Bases: Operator
Operator which loads HDF5 data files into observations.
This operator expects a top-level volume directory.
Source code in toast/ops/load_hdf5.py
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 |
|
API = Int(0, help='Internal interface version for this operator')
class-attribute
instance-attribute
detdata = List([defaults.det_data, defaults.det_flags], help='Only load this list of detdata objects')
class-attribute
instance-attribute
files = List([], help='Override `volume` and load a list of files')
class-attribute
instance-attribute
force_serial = Bool(False, help='Use serial HDF5 operations, even if parallel support available')
class-attribute
instance-attribute
intervals = List([], help='Only load this list of intervals objects')
class-attribute
instance-attribute
meta = List([], help='Only load this list of meta objects')
class-attribute
instance-attribute
pattern = Unicode('obs_.*_.*\\.h5', help='Regexp pattern to match files against')
class-attribute
instance-attribute
process_rows = Int(None, allow_none=True, help='The size of the rectangular process grid in the detector direction.')
class-attribute
instance-attribute
shared = List([], help='Only load this list of shared objects')
class-attribute
instance-attribute
sort_by_size = Bool(False, help='If True, sort observations by size before load balancing')
class-attribute
instance-attribute
volume = Unicode(None, allow_none=True, help='Top-level directory containing the data volume')
class-attribute
instance-attribute
__init__(**kwargs)
Source code in toast/ops/load_hdf5.py
70 71 |
|
_exec(data, detectors=None, **kwargs)
Source code in toast/ops/load_hdf5.py
73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 |
|
_finalize(data, **kwargs)
Source code in toast/ops/load_hdf5.py
176 177 |
|
_provides()
Source code in toast/ops/load_hdf5.py
182 183 |
|
_requires()
Source code in toast/ops/load_hdf5.py
179 180 |
|
toast.ops.SaveSpt3g
Bases: Operator
Operator which saves observations to SPT3G frame files.
This creates a directory for each observation, and writes framefiles with a target size.
Source code in toast/ops/save_spt3g.py
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 |
|
API = Int(0, help='Internal interface version for this operator')
class-attribute
instance-attribute
directory = Unicode('spt3g_data', help='Top-level export directory')
class-attribute
instance-attribute
framefile_mb = Float(100.0, help='Target frame file size in MB')
class-attribute
instance-attribute
gzip = Bool(False, help='If True, gzip compress the frame files')
class-attribute
instance-attribute
obs_export = Instance(klass=object, allow_none=True, help='Export class to create frames from an observation')
class-attribute
instance-attribute
purge = Bool(False, help='If True, delete observation data as it is saved')
class-attribute
instance-attribute
__init__(**kwargs)
Source code in toast/ops/save_spt3g.py
65 66 67 68 |
|
_check_export(proposal)
Source code in toast/ops/save_spt3g.py
52 53 54 55 56 57 58 59 60 61 62 63 |
|
_exec(data, detectors=None, **kwargs)
Source code in toast/ops/save_spt3g.py
70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 |
|
_finalize(data, **kwargs)
Source code in toast/ops/save_spt3g.py
149 150 |
|
_provides()
Source code in toast/ops/save_spt3g.py
155 156 |
|
_requires()
Source code in toast/ops/save_spt3g.py
152 153 |
|
toast.ops.LoadSpt3g
Bases: Operator
Operator which loads SPT3G data files into observations.
This operator expects a top-level data directory.
Source code in toast/ops/load_spt3g.py
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 |
|
API = Int(0, help='Internal interface version for this operator')
class-attribute
instance-attribute
directory = Unicode(None, allow_none=True, help='Top-level directory of observations')
class-attribute
instance-attribute
obs_import = Instance(klass=object, allow_none=True, help='Import class to create observations from frame files')
class-attribute
instance-attribute
__init__(**kwargs)
Source code in toast/ops/load_spt3g.py
62 63 64 65 |
|
_check_import(proposal)
Source code in toast/ops/load_spt3g.py
49 50 51 52 53 54 55 56 57 58 59 60 |
|
_exec(data, detectors=None, **kwargs)
Source code in toast/ops/load_spt3g.py
67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 |
|
_finalize(data, **kwargs)
Source code in toast/ops/load_spt3g.py
139 140 |
|
_provides()
Source code in toast/ops/load_spt3g.py
145 146 |
|
_requires()
Source code in toast/ops/load_spt3g.py
142 143 |
|