Skip to content

Commit

Permalink
Merge pull request cositools#113 from Yong2Sheng/fast_ts_map_galactic
Browse files Browse the repository at this point in the history
Fit TS map using galactic PsiChi
  • Loading branch information
ckarwin authored Jan 27, 2024
2 parents 6b01250 + 3370813 commit 1fb874e
Show file tree
Hide file tree
Showing 10 changed files with 1,505 additions and 364 deletions.
195 changes: 135 additions & 60 deletions cosipy/spacecraftfile/SpacecraftFile.py

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion cosipy/ts_map/fast_norm_fit.py
Original file line number Diff line number Diff line change
Expand Up @@ -240,4 +240,4 @@ def solve(self, data, bkg, unit_excess):
#Assumed to be a numerical error
ts = 0

return (ts, norm, norm_err, failed)
return (ts, norm, norm_err, failed, iteration)
401 changes: 345 additions & 56 deletions cosipy/ts_map/fast_ts_fit.py

Large diffs are not rendered by default.

247 changes: 0 additions & 247 deletions docs/tutorials/Parallel_TS_map_computation.ipynb

This file was deleted.

15 changes: 15 additions & 0 deletions docs/tutorials/ts_map/Crab_bkg_galactic_inputs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#----------#
# Data I/O:

# data files available on the COSI Sharepoint: https://drive.google.com/drive/folders/1UdLfuLp9Fyk4dNussn1wt7WEOsTWrlQ6
data_file: "/zfs/astrohe/yong/COSI/cosipy_workshop2023/DC2/Data/Sources/crab_3months_unbinned_data.fits.gz" # full path
ori_file: "" # full path
unbinned_output: 'fits' # 'fits' or 'hdf5'
time_bins: 0.5 # time bin size in seconds. Takes int, float, or list of bin edges.
energy_bins: [100, 158.489, 251.189, 398.107, 630.957, 1000, 1584.89, 2511.89, 3981.07, 6309.57, 10000] # Takes list. Needs to match response.
phi_pix_size: 5 # binning of Compton scattering anlge [deg]
nside: 8 # healpix binning of psi chi local
scheme: 'ring' # healpix binning of psi chi local
tmin: 1835487300.0 # Min time cut in seconds.
tmax: 1843467255.0 # Max time cut in seconds.
#----------#
7 changes: 7 additions & 0 deletions docs/tutorials/ts_map/GRB_Orientation.ori
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Type OrientationsGalactic
OG 1835481433.0 53.30823215719789 51.00102125784474 -36.69176784280211 51.00102125784474
OG 1835481433.5 53.30823215719789 51.00102125784474 -36.69176784280211 51.00102125784474
OG 1835481434.0 53.25629494101732 51.035133117383225 -36.74370505898268 51.035133117383225
OG 1835481434.5 53.25629494101732 51.035133117383225 -36.74370505898268 51.035133117383225
OG 1835481435.0 53.20436773279772 51.0692916774301 -36.79563226720228 51.0692916774301
# EN
1,002 changes: 1,002 additions & 0 deletions docs/tutorials/ts_map/Parallel_TS_map_computation_DC2.ipynb

Large diffs are not rendered by default.

0 comments on commit 1fb874e

Please sign in to comment.