Skip to content

pentyum/statmorph_csst

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

statmorph_csst

Introduction

statmorph for CSST, optimized by cython

URL:GiteeGithub

Installation

Clone this repo and enter the statmorph_csst directory

Execute ./build.sh

Usage

  1. Enter the src directory and execute python3 main.py
  2. Execute python3 main.py -h for help
SExtractor-Statmorph_csst 简化合并版使用说明
        -C, --config=The config file, whose default is config.properties. 配置同样可以通过命令行设置,通过命令行设置的的参数会覆盖配置文件中的参数
        -j, --threads=并行进程数量,若为0则为CPU核心数量-1(若为单核则为1)
        -i, --image_file=原始图像文件(未扣除背景),双图像模式中指用来探测源的图像文件(深度越深,PSF越大越好),若跳过SExtractor可以不需要
        -y, --measure_file=双图像模式中用于测量的图像文件(未扣除背景),若不指定(为null)则为单图像模式,若跳过SExtractor 可以不需要
        -w, --wht_file=权重图像文件,若跳过SExtractor可以不需要
        -o, --save_file=形态学参数输出文件名,若不指定则默认为image_file的文件名(不包括后缀).txt,双图像模式则还包括measure_file
        -p, --run_percentage=运行全部源数量的百分比,100表示全部运行
        -l, --run_specified_label=仅运行指定编号的源,若为0则运行全部源
        -s, --sextractor_work_dir=The work dir of SExtractor to save the output file. If it is not defined, use the file_name without the extension (e.g. .fits) of image_file as the default. 双图像模式下默认文件名还会包括measure_file,如果跳过sextractor,那么必须指定该项
        -k, --skip_sextractor Whether to use the result generated by SExtractor directly. The SExtractor work dir must contain the three image files of subback.fits,segmap.fits,noise.fits and the catalog file of catalog.txt. The catalog should contain at least the following three columns: `NUMBER`, `MAG_AUTO`, and `CLASS_STAR`, where `NUMBER` means the label in segmap.
        -X, --sextractor_command=The command to run SExtractor, whose default is source-extractor. If you install SExtractor in a non-traditional way, it may be necessary to modify it. 
        -D, --sextractor_detect_minarea
        -T, --sextractor_detect_thresh
        -A, --sextractor_analysis_thresh
        -B, --sextractor_deblend_nthresh
        -M, --sextractor_deblend_mincont
        -S, --sextractor_back_size
        -F, --sextractor_back_filtersize
        -P, --sextractor_backphoto_thick
        -r, --stamp_catalog 如果填写则进入stamp模式,每个星系具有独立的stamp的fits文件,而不是从segmap中创建,stamp_catalog文件必须包含label,image_file_name,image_hdu_index,(noise_file_name,noise_hdu_index,cmp_file_name,cmp_hdu_index)列 ,如果不指定hdu_index,则默认为0。指定该项后,image_file、measure_file、wht_file、sextractor_work_dir、skip_sextractor将全部失效。
        -a, --output_image_dir=输出示意图的文件夹,若为null则不输出示意图
        -f, --ignore_mag_fainter_than=忽略测量视星等比该星等更高的源
        -t, --ignore_class_star_greater_than=忽略测量像恒星指数大于该值的源
        -n, --center_file=预定义的星系中心文件,用于取代星系质心和不对称中心。需要列centroid_x,centroid_y,asymmetry_center_x,asymmetry_center_y
        -c, --calc_cas Whether to measure CAS
        -g, --calc_g_m20 Whether to measure Gini,M20
        -x, --calc_shape_asymmetry Whether to measure shape_asymmetry,依赖CAS和G_M20
        -d, --calc_mid Whether to measure MID
        -u, --calc_multiplicity Whether to measure multiplicity
        -e, --calc_color_dispersion Whether to measure color_dispersion
        -m, --image_compare_file=The background-subtracted image file to compare in the measurement of color_dispersion. It should be null if not measure.
        -b, --calc_g2 Whether to measure G2
        -v, --use_vanilla 是否使用vanilla版
        -h, --help show this help

Configuration

The default configuration file is src/config.properties. The contents is the same as the arguments on command line, but the arguments on the command line will overwrite the configuration file.

We can use -C to modify the path of the configuration file.

Update

Enter the src directory and execute ./update.sh.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published