Closed NicoloParmiggiani closed 3 months ago
Hi @NicoloParmiggiani, I just tested this and things ran fine for me. I'm using the same cosipy version (v0.0.2a5). Specifically, I ran the following two cells (I believe this is where you have the error, but let me know otherwise):
%%capture
# 3-month unbinned Crab data ~619.22 MB
fetch_wasabi_file("COSI-SMEX/DC2/Data/Sources/Crab_DC2_3months_unbinned_data.fits.gz")
# Here is the code I used to bin the Crab data if you want to generate it by yourself.
from cosipy import BinnedData
# "Crab_bkg_galactic_inputs.yaml" can be used for both Crab and background binning since the only useful information in the yaml file is the binning of CDS
analysis = BinnedData("Crab_bkg_galactic_inputs.yaml")
analysis.get_binned_data(unbinned_data = "Crab_DC2_3months_unbinned_data.fits.gz",
make_binning_plots=False,
output_name = "Crab_galactic_CDS_binned",
psichi_binning = "galactic")
# After you generate the binned data files, it should be saved to the same directory of this notebook
I think your error might be due to the fits file not being successfully downloaded from wasabi. I've seen similar problems before, where the download gets interrupted for some reason. In this case there is no indication that the download failed (which indeed is problematic). Can you check the file size of Crab_DC2_3months_unbinned_data.fits.gz (should be ~584 MB), and also check that it can be opened ok? Re-downloading the file might resolve the issue. Please let me know if the problem still persists.
Hi @ckarwin,
your suggestion solved the issue, thanks.
The file was only 300 MB more or less. I removed and downloaded it again.
Nicolò
Hello,
in this notebook https://github.com/cositools/cosipy/blob/main/docs/tutorials/ts_map/Parallel_TS_map_computation_DC2.ipynb
I have an error in the step "Getting the binned Crab data" of example 3:
I am using cosipy v0.0.2a5