Commit 07fb3c3c authored by BO ZHANG's avatar BO ZHANG 🏀
Browse files

added quitck_dataset method

parent 0d36e3fe
......@@ -305,6 +305,43 @@ class CsstMbiDataManager:
print(dm.l1_detector(detector, post="img.fits"))
return dm
@staticmethod
def quick_dataset(hostname="dandelion", ver_sim="C5.2", dir_l1=".", exposure_id=100):
""" quick dataset generator
Parameters
----------
hostname:
{dandelion, ubuntu}
ver_sim:
{"C5.2"}
dir_l1:
output directory
exposure_id:
21-154 for C5.2
Returns
-------
CsstMbiDataManager
the MBI data manager instance
"""
if hostname == "dandelion":
# dandelion node
dir_l0 = "/nfsdata/share/csst_simulation_data/Cycle-5-SimuData/multipleBandsImaging/CSST_shearOFF/" \
"MSC_{:07d}/".format(exposure_id)
path_aux = "/data/L1Pipeline/msc/ref/MSC_{}_*_{:02d}_combine.fits"
dir_pcref = "/data/L1Pipeline/msc/gaia_dr3/"
elif hostname == "ubuntu":
# PMO node
dir_l0 = "/share/simudata/CSSOSDataProductsSims/data/CSSTSimImage_C5/NGP_AstrometryON_shearOFF/" \
"MSC_{:07d}/".format(exposure_id)
path_aux = "/data/sim_data/MSC_0000100/ref/MSC_{}_*_{:02d}_combine.fits"
dir_pcref = "/home/user/L1Pipeline/msc/gaia_dr3/"
else:
raise ValueError("@DM: invalid hostname! valid values are {dandelion, ubuntu}")
return CsstMbiDataManager(ver_sim=ver_sim, dir_l0=dir_l0, dir_l1=dir_l1, dir_pcref=dir_pcref, path_aux=path_aux)
if __name__ == "__main__":
# test C3
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment