Skip to content

Commit

Permalink
Merge pull request #2383 from cta-observatory/update_dev_docs
Browse files Browse the repository at this point in the history
Update doc structure and dev guide
  • Loading branch information
kosack authored Sep 6, 2023
2 parents 20f2032 + cfc144a commit 9c2d0d2
Show file tree
Hide file tree
Showing 101 changed files with 740 additions and 658 deletions.
7 changes: 5 additions & 2 deletions ctapipe/calib/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
# Licensed under a 3-clause BSD style license - see LICENSE.rst
"""
Calibration
Module for calibration code
"""
from .camera import CameraCalibrator, GainSelector

__all__ = ["CameraCalibrator", "GainSelector"]
__all__ = [
"CameraCalibrator",
"GainSelector",
]
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,13 @@ CameraCalibrator
The primary class in this module is the `~ctapipe.calib.camera.calibrator.CameraCalibrator`. This class handles
two data level transition stages for the event:

* R1 -> DL0 (:ref:`image_reducers`)
* DL0 -> DL1 (:ref:`image_charge_extractors`)
* R1 DL0 (:ref:`image_reducers`)
* DL0 DL1 (:ref:`image_charge_extractors`)

The class takes a ctapipe event container, and fills the
next data level containers with the calibrated information.

See the `CTA High-Level Data Model Definitions SYS-QA/160517
<https://jama.cta-observatory.org/perspective.req?projectId=6&docId=26528>`_ document (CTA internal) for information about the
See the `CTA Top-Level Data Model Definitions <https://redmine.cta-observatory.org/dmsf/files/16325/view>`_ document (CTA internal) for information about the
different data levels.


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,32 +13,19 @@ Introduction

This module include all the functions and classes needed for the Calibration of CTA data.

It consists in four main sub-modules:

* :ref:`calib_camera`

* Array Calibration

* Atmosphere Calibration

* Pointing Calibration
Currently, only code related to :ref:`calib_camera` is implemented here.

For more information on where you should implement your code, please have a look to the README.rst files inside each directory.


Getting Started
===============

TODO: add examples.

Submodules
==========

.. toctree::
:maxdepth: 1
:glob:

index_*
camera



Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ they can be transformed to and from any other `astropy.coordinates` frame, like

The three different coordinate frames are shown here:

.. plot:: ctapipe_api/coordinates/plot_camera_frames.py
.. plot:: api-reference/coordinates/plot_camera_frames.py


The `CameraFrame` is used internally in ``ctapipe`` and comes from ``sim_telarray``.
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ with `numpy` operations, since it is quite speed-efficient.
Examples
--------

.. plot:: ctapipe_api/instrument/camerageometry_example.py
.. plot:: api-reference/instrument/camerageometry_example.py
:include-source:


Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file removed docs/cameras.png
Binary file not shown.
26 changes: 20 additions & 6 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,19 @@ def setup(app):
# These links are ignored in the checks, necessary due to broken intersphinx for
# these
nitpick_ignore = [
# needed for building the docs with python 3.11 locally.
# we use the lowest supported version on readthedocs, so that is what we use the intersphinx
# link above
("py:class", "enum.StrEnum"),
# these are coming from traitlets:
("py:class", "t.Union"),
("py:class", "t.Any"),
("py:class", "t.Dict"),
("py:class", "t.Optional"),
("py:class", "t.Type"),
("py:class", "t.List"),
("py:class", "t.Tuple"),
("py:class", "Config"),
("py:class", "traitlets.config.configurable.Configurable"),
("py:class", "traitlets.traitlets.HasTraits"),
("py:class", "traitlets.traitlets.HasDescriptors"),
Expand All @@ -126,6 +139,7 @@ def setup(app):
("py:class", "astropy.table.table.Table"),
("py:class", "eventio.simtel.simtelfile.SimTelFile"),
("py:class", "ctapipe.compat.StrEnum"),
("py:class", "ctapipe.compat.StrEnum"),
]


Expand Down Expand Up @@ -196,19 +210,19 @@ def setup(app):
json_url = "https://ctapipe.readthedocs.io/en/latest/_static/switcher.json"

# Define the version we use for matching in the version switcher.
version_match = os.environ.get("READTHEDOCS_VERSION")
version_match = os.getenv("READTHEDOCS_VERSION")
# If READTHEDOCS_VERSION doesn't exist, we're not on RTD
# If it is an integer, we're in a PR build and the version isn't correct.
if not version_match or version_match.isdigit():
# For local development, infer the version to match from the package.
if "dev" in release or "rc" in release:
version_match = "latest"
# We want to keep the relative reference if we are in dev mode
# but we want the whole url if we are effectively in a released version
json_url = "_static/switcher.json"
else:
version_match = release

# We want to keep the relative reference when on a pull request or locally
json_url = "_static/switcher.json"


# -- Options for HTML output ----------------------------------------------

Expand All @@ -222,8 +236,8 @@ def setup(app):
# documentation.
html_theme_options = {
"logo": {
"image_light": "ctapipe_logo.webp",
"image_dark": "ctapipe_logo_dark.webp",
"image_light": "_static/ctapipe_logo.webp",
"image_dark": "_static/ctapipe_logo_dark.webp",
"alt_text": "ctapipe",
},
"github_url": "https://github.com/cta-observatory/ctapipe",
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,43 +1,42 @@
****************************
Ctapipe Enhancment Proposals
****************************
*****************************
ctapipe Enhancement Proposals
*****************************

CEPs (Ctapipe Enhancment Proposals) are short documents proposing and describing
CEPs (ctapipe Enhancment Proposals) are short documents proposing and describing
a major addition or change to ctapipe. See :ref:`cep-001` for further information.

Below is a list of merged CEPs, i.e. the ones that are finalised,
with status "accepted" or "rejected" or "withdrawn".
The ones with "draft" status, i.e. that are under discussion,
can be found on Github as `pull requests with the "CEP" label`_ .
can be found on GitHub as `pull requests with the "CEP" label`_ .


Accepted CEPs
=============
.. toctree::
:maxdepth: 1
:maxdepth: 1
:glob:

accepted/*

Proposed CEPs
=============
..
..
toctree::
:maxdepth: 1
:maxdepth: 1
:glob:
proposed/*

Rejected CEPs
=============

..
..
toctree::
:maxdepth: 1
:maxdepth: 1
:glob:
rejected/*


.. _pull requests with the "cep" label: https://github.com/cta-observatory/ctapipe/issues?q=label%3ACEP

File renamed without changes.
File renamed without changes.
Loading

0 comments on commit 9c2d0d2

Please sign in to comment.