Skip to content

Commit

Permalink
Merge pull request #28 from LSSTDESC/eac/docs
Browse files Browse the repository at this point in the history
Eac/docs
  • Loading branch information
sschmidt23 authored Feb 17, 2025
2 parents 736c1fb + 1ad8f77 commit e3cef07
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 10 deletions.
9 changes: 5 additions & 4 deletions src/rail/estimation/algos/cc_yaw.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,11 +111,12 @@ class YawCacheCreate(
The cache can be constructed from input files or tabular data in memory.
Column names for sky coordinates are required, redshifts and per-object
weights are optional. One out of three patch create methods must be
specified:
1. Splitting the data into predefined patches (from ASCII file or an
specified:
#. Splitting the data into predefined patches (from ASCII file or an
existing cache instance, linked as optional stage input).
2. Splitting the data based on a column with patch indices.
3. Generating approximately equal size patches using k-means clustering of
#. Splitting the data based on a column with patch indices.
#. Generating approximately equal size patches using k-means clustering of
objects positions (preferably randoms if provided).
**Note:** The cache directory must be deleted manually when it is no longer
Expand Down
15 changes: 9 additions & 6 deletions src/rail/pipelines/estimation/plot_output.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,12 @@
import pickle
import os

with open(os.path.join("data", "output_summarize.pkl"), "rb") as f:
ncc = pickle.load(f)
ncc.to_files(os.path.join("data", "output"))
ax = ncc.plot(indicate_zero=True)
ax.set_xlabel("Redshift")
ax.figure.savefig(os.path.join("data", "checkplot.png"))

if __name__ == '__main__':

with open(os.path.join("data", "output_summarize.pkl"), "rb") as f:
ncc = pickle.load(f)
ncc.to_files(os.path.join("data", "output"))
ax = ncc.plot(indicate_zero=True)
ax.set_xlabel("Redshift")
ax.figure.savefig(os.path.join("data", "checkplot.png"))

0 comments on commit e3cef07

Please sign in to comment.