Commit 255d9883 authored by Fang Yuedong's avatar Fang Yuedong
Browse files

fix the crash when the path to psf/fd data is not given

parent 0ca58f1d
......@@ -21,8 +21,10 @@ def config_dir(config, work_dir=None, data_dir=None):
# Object catalog direcotry
path_dict["cat_dir"] = os.path.join(path_dict["data_dir"], config["input_path"]["cat_dir"])
# PSF data directory
path_dict["psf_dir"] = os.path.join(path_dict["data_dir"], config["psf_setting"]["psf_dir"])
path_dict["fd_path"] = os.path.join(path_dict["data_dir"], config["psf_setting"]["fd_path"])
if config["psf_setting"]["psf_model"] == "Interp":
path_dict["psf_dir"] = os.path.join(path_dict["data_dir"], config["psf_setting"]["psf_dir"])
if config["ins_effects"]["field_dist"] == True:
path_dict["fd_path"] = os.path.join(path_dict["data_dir"], config["psf_setting"]["fd_path"])
return path_dict
......
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