Skip to content

Commit

Permalink
Merge pull request #57 from simonsobs/issue_56
Browse files Browse the repository at this point in the history
Initial rearranging of files
  • Loading branch information
tskisner authored Apr 27, 2020
2 parents 2a33996 + 9eeba84 commit 43a239e
Show file tree
Hide file tree
Showing 44 changed files with 533 additions and 770 deletions.
2 changes: 1 addition & 1 deletion pipelines/toast_bin_so3g.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
import toast.tod
import toast.pipeline_tools as toast_tools

from sotodlib.data.toast_load import load_data
from sotodlib.io.toast_load import load_data


def main():
Expand Down
4 changes: 2 additions & 2 deletions pipelines/toast_so_example.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
import toast.map as tm
import toast.tod as tt

from sotodlib.hardware import get_example, sim_telescope_detectors
from sotodlib.data.toast_load import load_data
from sotodlib.sim_hardware import get_example, sim_telescope_detectors
from sotodlib.io.toast_load import load_data


def binned_map(data, npix, subnpix, out="."):
Expand Down
4 changes: 1 addition & 3 deletions pipelines/toast_so_sim.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,10 @@

import toast.pipeline_tools as toast_tools

import sotodlib.pipeline_tools as so_tools
import sotodlib.utils.pipeline_tools as so_tools

import numpy as np

import sotodlib.hardware

import warnings

warnings.filterwarnings("ignore")
Expand Down
4 changes: 1 addition & 3 deletions pipelines/toast_so_tf.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,10 @@

import toast.pipeline_tools as toast_tools

import sotodlib.pipeline_tools as so_tools
import sotodlib.utils.pipeline_tools as so_tools

import numpy as np

import sotodlib.hardware

import warnings

warnings.filterwarnings("ignore")
Expand Down
10 changes: 6 additions & 4 deletions sotodlib/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) 2018-2019 Simons Observatory.
# Copyright (c) 2018-2020 Simons Observatory.
# Full license can be found in the top level "LICENSE" file.
"""Simons Observatory TOD Simulation and Processing.
Expand All @@ -8,9 +8,11 @@
Contents:
* db: database access for detector properties, observations, etc.
* toast: tools specifically for working with the external TOAST package.
* scripts: commandline entry points.
* core: Container classes for data, metadata, etc.
* io: Code for reading / writing data.
* utils: General utility functions and data helper functions.
* scripts: Commandline entry points.
* Top level packages for actual data processing.
"""

Expand Down
11 changes: 10 additions & 1 deletion sotodlib/core/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,13 @@
# Copyright (c) 2018-2020 Simons Observatory.
# Full license can be found in the top level "LICENSE" file.
"""Simons Observatory core routines.
This module has containers and in-memory structures for data and metadata.
"""
from .context import Context

from .axisman import AxisManager
from .axisman import IndexAxis, OffsetAxis, LabelAxis

from .context import Context
from .hardware import Hardware
10 changes: 5 additions & 5 deletions sotodlib/core/context.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import yaml
import os

from .. import metadata
from . import metadata


class Context(odict):
Expand Down Expand Up @@ -77,11 +77,11 @@ def reload(self, load_list='all'):
"""
# Metadata support databases.
for key, cls in [('detdb', metadata.DetDB),
('obsdb', metadata.ObsDB),
('obsfiledb', metadata.ObsFileDB)]:
for key, cls in [('detdb', metadata.DetDb),
('obsdb', metadata.ObsDb),
('obsfiledb', metadata.ObsFileDb)]:
if (load_list == 'all' or key in load_list) and key in self:
# E.g. self.detdb = DetDB.from_file(self['detdb']
# E.g. self.detdb = DetDb.from_file(self['detdb']
db = cls.from_file(self[key])
setattr(self, key, db)
# The metadata loader.
Expand Down
File renamed without changes.
Loading

0 comments on commit 43a239e

Please sign in to comment.