Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Bo Zhang
csst
Commits
c4de819d
Commit
c4de819d
authored
Apr 29, 2022
by
BO ZHANG
🏀
Browse files
integrated position calibration from Jundan Nie
parent
f4cb375b
Changes
10
Hide whitespace changes
Inline
Side-by-side
csst/msc/astrometry.py
View file @
c4de819d
from
..core.processor
import
CsstProcessor
import
os
import
time
from
functools
import
partial
from
multiprocessing
import
Pool
from
subprocess
import
Popen
import
healpy
as
hp
import
numpy
as
np
from
astropy
import
table
from
astropy
import
units
as
u
from
astropy.coordinates
import
SkyCoord
from
astropy.io
import
fits
from
astropy.wcs
import
WCS
from
..
import
PACKAGE_PATH
from
..core.processor
import
CsstProcessor
CONFIG_SCAMP
=
PACKAGE_PATH
+
"/msc/
config/test.txt
"
path_config
=
PACKAGE_PATH
+
"/msc/
astrometry_config/
"
class
CsstProcMscPositionCalibration
(
CsstProcessor
):
def
prepare
(
self
,
**
args
):
# prepare the environment
# for example, if you make use of some third-party software like SEXTRACTOR,
# do your preparation here.
pass
def
run
(
self
,
data
,
*
args
,
**
kwargs
):
# run your pipeline here
# make sure that your input raw should be a child class instance of CsstData.
pass
def
cleanup
(
self
,
**
kwargs
):
# clean up environment
pass
def
join_data
(
self
,
img_list
,
wht_list
,
flg_list
,
path_output
):
"""
Prepare data for running scamp; Combine all image data, weight files, flag files to their one frame.
Parameters
----------
img_list:
image files to join together, e.g.,MSC_210304093000_0000000_06_img.fits
wht_list:
weith files to join together, e.g.,MSC_210304093000_0000000_06_img.fits
flg_list:
flag files to join together, e.g.,e.g.,MSC_210304093000_0000000_06_flg.fits
path_output:
the output dir for the joined file.
Returns
-------
The joined multi-extension file(not stacked), weight, flag files.
e.g., MSC_210304093000_0000000_img.fits,MSC_210304093000_0000000_wht.fits, MSC_210304093000_0000000_flg.fits.
"""
img_prefix
=
img_list
[
0
][
0
].
header
[
'FILENAME'
][
0
:
-
7
]
output_imgnm
=
path_output
+
img_prefix
+
'_img.fits'
hdul_img
=
fits
.
HDUList
()
for
i
in
range
(
0
,
len
(
img_list
)):
h0
=
fits
.
PrimaryHDU
(
header
=
img_list
[
i
][
0
].
header
)
h1
=
fits
.
ImageHDU
(
data
=
img_list
[
i
][
1
].
data
,
header
=
img_list
[
i
][
1
].
header
)
hdul_img
.
append
(
h0
)
hdul_img
.
append
(
h1
)
hdul_img
.
writeto
(
output_imgnm
,
overwrite
=
True
)
output_whtnm
=
path_output
+
img_prefix
+
'_wht.fits'
hdul_wht
=
fits
.
HDUList
()
for
i
in
range
(
0
,
len
(
wht_list
)):
h0
=
fits
.
PrimaryHDU
(
header
=
wht_list
[
i
][
0
].
header
)
h1
=
fits
.
ImageHDU
(
data
=
wht_list
[
i
][
1
].
data
,
header
=
wht_list
[
i
][
1
].
header
)
hdul_wht
.
append
(
h0
)
hdul_wht
.
append
(
h1
)
hdul_wht
.
writeto
(
output_whtnm
,
overwrite
=
True
)
output_flgnm
=
path_output
+
img_prefix
+
'_flg.fits'
hdul_flg
=
fits
.
HDUList
()
for
i
in
range
(
0
,
len
(
flg_list
)):
h0
=
fits
.
PrimaryHDU
(
header
=
flg_list
[
i
][
0
].
header
)
h1
=
fits
.
ImageHDU
(
data
=
flg_list
[
i
][
1
].
data
,
header
=
flg_list
[
i
][
1
].
header
)
hdul_flg
.
append
(
h0
)
hdul_flg
.
append
(
h1
)
hdul_flg
.
writeto
(
output_flgnm
,
overwrite
=
True
)
def
run_sextractor
(
self
,
fn_list
,
path_output
):
"""
Run sextractor
Parameters
----------
fn_list:
file name list, e.g.,MSC_210304093000_0000000_06_img.fits...
config_sextractor:
the path for sextractor configuration file.
path_output:
the current working dir
Returns
-------
The photometric catalog, with position and flux, e.g.,MSC_210304093000_0000000_06_img.acat
"""
fn
=
fn_list
config_sextractor
=
path_config
+
"new_csst_realtime.no.weight.sex"
sex_comd1
=
'sex -c '
+
config_sextractor
+
' '
sex_comd2
=
fn
+
' -CATALOG_NAME '
+
fn
[
0
:
-
5
]
+
'.acat'
sex_comd3
=
' -PARAMETERS_NAME '
+
path_config
+
'csst_realtime.param'
+
' -FILTER_NAME '
+
path_config
+
'csst_realtime.conv'
+
' -STARNNW_NAME '
+
path_config
+
'csst_realtime.nnw'
sex_comd
=
sex_comd1
+
sex_comd2
+
sex_comd3
print
(
sex_comd
)
p
=
Popen
(
sex_comd
,
shell
=
True
)
p
.
wait
()
def
combine_catalog
(
self
,
img_list
,
path_output
):
"""
Combine the sextractor catalog together
Parameters
-----------
img_list:
image list, in table format
path_output:
the output dir
Returns
-------
The combined catalog,e.g., MSC_210304093000_0000000.acat.fits
"""
fn
=
path_output
+
img_list
[
0
][
0
].
header
[
'FILENAME'
][
0
:
-
7
]
output_catnm
=
str
(
fn
+
'.acat.fits'
)
hdul
=
fits
.
HDUList
()
if
len
(
img_list
)
==
18
:
for
i
in
range
(
0
,
len
(
img_list
)):
image_prefix
=
img_list
[
i
][
0
].
header
[
'FILENAME'
]
cat_nm
=
path_output
+
image_prefix
+
'.acat'
cat_i
=
fits
.
open
(
cat_nm
)
hdul
.
append
(
cat_i
[
0
])
hdul
.
append
(
cat_i
[
1
])
hdul
.
append
(
cat_i
[
2
])
hdul
.
writeto
(
output_catnm
,
overwrite
=
True
)
else
:
print
(
'the length of file list in not equal to 18, needs to check'
)
def
run_scamp
(
self
,
img_list
,
path_output
):
"""
Run scamp
Parameters
---------
img_list:
to join a file 'image_prefix+.acat.fits', e.g.,MSC_210304093000_0000000.acat.fits
config_scamp:
the config file path for scamp
Returns
-------
Image header updated with WCS keywords, MSC_210304093000_0000000.acat.head.
"""
image_prefix
=
(
img_list
[
0
][
0
].
header
)[
'FILENAME'
][
0
:
-
7
]
config_scamp
=
path_config
+
"default2.scamp"
scamp_comd
=
'scamp '
+
image_prefix
+
'.acat.fits -ASTREFCAT_NAME= '
+
'ref.cat
\
-MERGEDOUTCAT_NAME '
+
'merged.cat -FULLOUTCAT_NAME '
+
'full.cat
\
-c '
+
config_scamp
print
(
scamp_comd
)
p
=
Popen
(
scamp_comd
,
shell
=
True
)
p
.
wait
()
def
convert_hdu_to_ldac
(
self
,
hdu
):
"""
Convert an hdu table to a fits_ldac table (format used by astromatic suite)
def
test_dir
():
print
(
CONFIG_SCAMP
)
\ No newline at end of file
Parameters
----------
hdu:
`astropy.io.fits.BinTableHDU` or `astropy.io.fits.TableHDU`
HDUList to convert to fits_ldac HDUList
Returns
-------
tbl1:
`astropy.io.fits.BinTableHDU`
Header info for fits table (LDAC_IMHEAD)
tbl2:
`astropy.io.fits.BinTableHDU`
Data table (LDAC_OBJECTS)
"""
tblhdr
=
np
.
array
([
hdu
[
1
].
header
.
tostring
()])
col1
=
fits
.
Column
(
name
=
'Field Header Card'
,
array
=
tblhdr
,
format
=
'13200A'
)
cols
=
fits
.
ColDefs
([
col1
])
tbl1
=
fits
.
BinTableHDU
.
from_columns
(
cols
)
tbl1
.
header
[
'TDIM1'
]
=
'(80, {0})'
.
format
(
len
(
hdu
[
1
].
header
))
tbl1
.
header
[
'EXTNAME'
]
=
'LDAC_IMHEAD'
dcol
=
fits
.
ColDefs
(
hdu
[
1
].
data
)
tbl2
=
fits
.
BinTableHDU
.
from_columns
(
dcol
)
tbl2
.
header
[
'EXTNAME'
]
=
'LDAC_OBJECTS'
return
tbl1
,
tbl2
def
get_refcat
(
self
,
img_list
,
path_gaia
,
search_radius
,
silent
=
True
):
"""
Get reference catalog for scamp. The reference cat is GAIA EDR3.
Parameters
----------
image_prefix:
a image to get its reference catalog, e.g.,MSC_210304093000_0000000_img.fits.
Usually the center of the image is the wcs parameters CRVAL1,CRVAL1.
search_radius:
circle radius for searching, units: degree. e.g., 2 degree for a 1x1 deg^2 image.
For large ccd size, use larger radius. csst, r=3 deg.
path_gaia: directory of the reference catalog.
Returns
-------
outcat:
filename of the cross matched catalog.
This catalog is used as a reference catalog for running scamp.
e.g.,MSC_210304093000_0000000.gaialac.fits
"""
image_prefix
=
(
img_list
[
0
][
0
].
header
)[
'FILENAME'
][
0
:
-
7
]
fname
=
image_prefix
+
'_img.fits'
gaianame
=
image_prefix
+
'.gaia.fits'
gaialacnm
=
image_prefix
+
'.gaialac.fits'
outcat
=
gaianame
hdu
=
fits
.
open
(
fname
)
header1
=
hdu
[
0
].
header
header2
=
hdu
[
1
].
header
deltatime
=
0.00
ra
=
float
(
header2
[
'CRVAL1'
])
dec
=
float
(
header2
[
'CRVAL2'
])
c
=
SkyCoord
(
ra
,
dec
,
unit
=
(
u
.
deg
,
u
.
deg
))
print
(
'ra, dec ra.deg dec.deg= '
,
ra
,
dec
,
c
.
ra
.
deg
,
c
.
dec
.
deg
)
ra
=
c
.
ra
.
deg
dec
=
c
.
dec
.
deg
c
=
SkyCoord
(
ra
,
dec
,
unit
=
(
u
.
deg
,
u
.
deg
))
phi
=
c
.
ra
.
deg
/
(
180.
/
np
.
pi
)
theta
=
(
90.
-
c
.
dec
.
deg
)
/
(
180
/
np
.
pi
)
vec
=
hp
.
ang2vec
(
theta
,
phi
)
list1
=
hp
.
query_disc
(
nside
=
32
,
vec
=
vec
,
radius
=
np
.
radians
(
search_radius
))
if
-
1
in
list1
:
list1
.
remove
(
-
1
)
ipring
=
np
.
array
(
list1
)
pix
=
np
.
unique
(
ipring
)
npix
=
pix
.
size
print
(
ipring
,
'ipring'
,
pix
,
'pix'
,
npix
,
'npix'
)
dt
=
np
.
dtype
(
[(
'ra'
,
'>f8'
),
(
'dec'
,
'>f8'
),
(
'ra_error'
,
'>f8'
),
(
'dec_error'
,
'>f8'
),
(
'phot_g_mean_mag'
,
'>f8'
),
(
'pmra'
,
'>f8'
),
(
'pmra_error'
,
'>f8'
),
(
'pmdec'
,
'>f8'
),
(
'pmdec_error'
,
'>f8'
)])
refcat
=
table
.
Table
(
dtype
=
dt
)
for
i
in
pix
:
print
(
'i= %5.5d'
%
i
,
path_gaia
)
fname
=
path_gaia
+
'healpix-'
+
'%5.5d'
%
i
+
'.fits'
print
(
'fname='
,
fname
)
if
not
silent
:
print
(
'Reading '
,
fname
)
d
=
table
.
Table
.
read
(
fname
)
refcat
=
[
refcat
,
d
]
refcat
=
table
.
vstack
(
refcat
,
join_type
=
'inner'
)
refcat
.
rename_column
(
'ra'
,
'X_WORLD'
)
refcat
.
rename_column
(
'dec'
,
'Y_WORLD'
)
print
(
'delta_time between obs_cat and ref_cat:'
,
deltatime
)
mask
=
(
refcat
[
'pmdec'
]
!=
refcat
[
'pmdec'
])
refcat
[
'pmdec'
][
mask
]
=
0
mask
=
(
refcat
[
'pmra'
]
!=
refcat
[
'pmra'
])
refcat
[
'pmra'
][
mask
]
=
0
refcat
[
'X_WORLD'
]
=
refcat
[
'X_WORLD'
]
+
deltatime
*
refcat
[
'pmra'
]
/
np
.
cos
(
refcat
[
'Y_WORLD'
]
/
180.
*
np
.
pi
)
/
3600.0
/
1000.0
refcat
[
'Y_WORLD'
]
=
refcat
[
'Y_WORLD'
]
+
deltatime
*
refcat
[
'pmdec'
]
/
3600.0
/
1000.0
refcat
[
'ra_error'
]
=
refcat
[
'ra_error'
]
/
1000.0
/
3600.0
refcat
[
'dec_error'
]
=
refcat
[
'dec_error'
]
/
1000.0
/
3600.0
refcat
.
rename_column
(
'ra_error'
,
'ERRA_WORLD'
)
refcat
.
rename_column
(
'dec_error'
,
'ERRB_WORLD'
)
refcat
.
rename_column
(
'phot_g_mean_mag'
,
'MAG'
)
if
outcat
:
refcat
.
write
(
outcat
,
format
=
'fits'
,
overwrite
=
True
)
if
os
.
path
.
isfile
(
gaianame
):
print
(
'exist'
)
hdu
=
fits
.
open
(
gaianame
)
hdu1
=
self
.
convert_hdu_to_ldac
(
hdu
)
hdup
=
fits
.
PrimaryHDU
()
hdu
=
hdu1
[
0
]
tbhdu
=
hdu1
[
1
]
thdulist
=
fits
.
HDUList
([
hdup
,
hdu
,
tbhdu
])
if
os
.
path
.
isfile
(
gaialacnm
):
os
.
remove
(
gaialacnm
)
thdulist
.
writeto
(
gaialacnm
)
print
(
'##################### end #####################'
)
return
gaialacnm
def
rewrite_wcs_head
(
self
,
head
):
"""
Rewrite the WCS head from Scamp to the standard fits header
Parameters
----------
head: scamp head file names
Returns
-------
wcshead: a new head file in fits format
"""
wcshead
=
head
+
'.fits'
f
=
open
(
head
,
'r'
)
f1
=
open
(
wcshead
,
'w'
)
a
=
''
i
=
0
for
v
in
f
.
readlines
():
sp
=
''
asp
=
''
i
+=
1
if
len
(
v
)
<=
81
:
sp
=
' '
*
(
81
-
len
(
v
))
if
'END'
in
v
:
asp
=
' '
*
80
*
(
36
-
i
%
36
)
i
=
i
+
(
36
-
i
%
36
)
# print(i)
a
=
a
+
v
+
sp
+
asp
f1
.
write
(
a
.
replace
(
'
\n
'
,
''
))
f1
.
close
()
f
.
close
()
return
wcshead
def
check_astrometry
(
self
,
img_list
,
path_output
):
"""
Check position calibration quality
Parameters
------------
img_list:
list of images, in table format
path_output:
work dir
Returns
-------
ccdraoff:
ra difference between observed catalog and reference catalog
ccddecoff:
dec difference between observed catalog and reference catalog
ccdraoff_med,ccddecoff_med:
median of the ra or dec difference
ccdraoff_rms,ccddecoff_rms:
rms of the ra or dec difference
"""
print
(
'############## check the astrometry quality and save files ################'
)
r1
=
[]
d1
=
[]
image_prefix
=
(
img_list
[
0
][
0
].
header
)[
'FILENAME'
][
0
:
-
7
]
fn
=
path_output
+
image_prefix
wcshead
=
self
.
rewrite_wcs_head
(
fn
+
'.acat.head'
)
acat
=
fits
.
open
(
fn
+
'.acat.fits'
)
acat_change
=
str
(
fn
+
'.acat.change.fits'
)
cat_suffix
=
'.acat'
hdul
=
fits
.
HDUList
()
if
len
(
img_list
)
==
18
:
for
i
in
range
(
0
,
len
(
img_list
)):
wcshdr
=
fits
.
getheader
(
wcshead
,
i
,
ignore_missing_simple
=
True
)
# read headers and change to RA---TPV,DEC--TPV for wcs_transfer package
wcshdr
[
'CTYPE1'
]
=
'RA---TPV'
wcshdr
[
'CTYPE2'
]
=
'DEC--TPV'
w
=
WCS
(
wcshdr
)
# print(wcshdr)
cat_nm
=
path_output
+
(
img_list
[
i
][
0
].
header
)[
'FILENAME'
]
+
cat_suffix
cat_i
=
fits
.
open
(
cat_nm
)
sexcat
=
cat_i
[
2
].
data
ra_sex
=
sexcat
[
'ALPHA_J2000'
]
dec_sex
=
sexcat
[
'DELTA_J2000'
]
x
=
sexcat
[
'XWIN_IMAGE'
]
y
=
sexcat
[
'YWIN_IMAGE'
]
r
,
d
=
w
.
all_pix2world
(
x
,
y
,
0
)
# convert xwin,ywin to ra,de
sexcat
[
'ALPHA_J2000'
]
=
r
sexcat
[
'DELTA_J2000'
]
=
d
cat_i
[
2
].
data
=
sexcat
hdul
.
append
(
cat_i
[
0
])
hdul
.
append
(
cat_i
[
1
])
hdul
.
append
(
cat_i
[
2
])
r1
=
np
.
hstack
((
r1
,
r
))
d1
=
np
.
hstack
((
d1
,
d
))
obsc
=
SkyCoord
(
ra
=
r1
*
u
.
degree
,
dec
=
d1
*
u
.
degree
)
tmp_cat
=
np
.
zeros
((
len
(
obsc
),
2
))
tmp_cat
[:,
0
]
=
obsc
.
ra
tmp_cat
[:,
1
]
=
obsc
.
dec
np
.
savetxt
(
path_output
+
'scamp_coord.txt'
,
tmp_cat
,
fmt
=
"%.10f %.10f"
,
delimiter
=
"
\n
"
)
hdul
.
writeto
(
acat_change
,
overwrite
=
True
)
# update the cat with new ra,dec (from 1st scamp wcs.)
else
:
print
(
'the length of fitslist is not equal to 18,needs to check'
)
def
write_headers
(
self
,
img_list
):
"""
Wrtie history to header
"""
head_suffix
=
img_list
[
0
][
0
].
header
[
'FILENAME'
][
0
:
-
7
]
+
'.acat.head.fits'
hdul2
=
fits
.
open
(
head_suffix
,
ignore_missing_simple
=
True
)
if
len
(
img_list
)
==
18
:
for
i
in
range
(
0
,
len
(
img_list
)):
fits_nm
=
img_list
[
i
][
0
].
header
[
'FILENAME'
]
+
'.head'
hdul1
=
fits
.
open
(
fits_nm
,
mode
=
'update'
,
ignore_missing_simple
=
True
)
hdr
=
hdul1
[
0
].
header
hdr2
=
hdul2
[
i
].
header
hdr
.
extend
(
hdr2
,
unique
=
True
,
update
=
True
)
WCS_S
=
0
WCS_V
=
'2.0.4'
WCS_P
=
'default.scamp'
WCS_TOL
=
time
.
strftime
(
'%Y-%m-%d %H:%M:%S %p'
)
hdr
.
set
(
'WCS_S'
,
'0'
,
'0=done'
)
hdr
.
set
(
'WCS_V'
,
WCS_V
,
'Version of WCS calibration'
)
hdr
.
set
(
'WCS_P'
,
WCS_P
,
'Configure file name of WCS'
)
hdr
.
set
(
'WCS_TOL'
,
WCS_TOL
,
'Time of last wcs calibration'
)
# hdul1.flush()
# hdul1.close()
else
:
print
(
'The total number of the fits files is not 18.'
)
def
prepare
(
self
,
path_gaia
,
path_output
,
search_radius
=
2.0
):
self
.
path_gaia
=
path_gaia
self
.
path_output
=
path_output
self
.
search_radius
=
search_radius
def
run
(
self
,
img_list
,
wht_list
,
flg_list
,
fn_list
,
path_gaia
,
path_output
,
search_radius
):
print
(
'preparing files for position calibration....'
)
self
.
join_data
(
img_list
,
wht_list
,
flg_list
,
path_output
=
path_output
)
print
(
'################## run sextractor ###################'
)
p
=
Pool
()
prod_x
=
partial
(
self
.
run_sextractor
,
path_output
=
path_output
)
result
=
p
.
map
(
prod_x
,
fn_list
)
p
.
close
()
p
.
join
()
print
(
'################## sextractor done ###################'
)
print
(
'############### combine sextractor catalog ###############'
)
self
.
combine_catalog
(
img_list
,
path_output
)
print
(
'############### get reference catalog ###############3'
)
refcat
=
self
.
get_refcat
(
img_list
,
path_gaia
=
path_gaia
,
search_radius
=
search_radius
,
silent
=
True
)
Popen
(
'cp '
+
refcat
+
' ref.cat'
,
shell
=
True
)
print
(
'############### run scamp ##################'
)
self
.
run_scamp
(
img_list
,
path_output
=
path_output
)
print
(
'################ scamp done #################'
)
print
(
'Checking astrometry quality....'
)
self
.
check_astrometry
(
img_list
,
path_output
)
print
(
'################ updating headers.... #############'
)
self
.
write_headers
(
img_list
)
print
(
'#### Position calibration process done ####'
)
def
cleanup
(
self
,
img_list
,
path_output
):
# clean up environment
image_prefix
=
img_list
[
0
][
0
].
header
[
'FILENAME'
][
0
:
-
7
]
for
i
in
range
(
0
,
len
(
img_list
)):
fn
=
img_list
[
i
][
0
].
header
[
'FILENAME'
]
+
'.acat'
if
os
.
path
.
isfile
(
path_output
+
fn
):
os
.
remove
(
path_output
+
fn
)
if
os
.
path
.
isfile
(
path_output
+
image_prefix
+
'.gaia.fits'
):
os
.
remove
(
path_output
+
image_prefix
+
'.gaia.fits'
)
if
os
.
path
.
isfile
(
path_output
+
image_prefix
+
'.gaialac.fits'
):
os
.
remove
(
path_output
+
image_prefix
+
'.gaialac.fits'
)
if
os
.
path
.
isfile
(
path_output
+
'scamp.xml'
):
os
.
remove
(
path_output
+
'scamp.xml'
)
if
os
.
path
.
isfile
(
path_output
+
'full_1.cat'
):
os
.
remove
(
path_output
+
'full_1.cat'
)
if
os
.
path
.
isfile
(
path_output
+
'merged_1.cat'
):
os
.
remove
(
path_output
+
'merged_1.cat'
)
if
os
.
path
.
isfile
(
path_output
+
image_prefix
+
'_img.fits.back'
):
os
.
remove
(
path_output
+
image_prefix
+
'_img.fits.back'
)
if
os
.
path
.
isfile
(
path_output
+
image_prefix
+
'_wht.fits'
):
os
.
remove
(
path_output
+
image_prefix
+
'_wht.fits'
)
if
os
.
path
.
isfile
(
path_output
+
image_prefix
+
'_flg.fits'
):
os
.
remove
(
path_output
+
image_prefix
+
'_flg.fits'
)
csst/msc/astrometry_config/csst_realtime.conv
0 → 100644
View file @
c4de819d
CONV NORM
# 5x5 convolution mask of a gaussian PSF with FWHM = 2.5 pixels.
0.034673 0.119131 0.179633 0.119131 0.034673
0.119131 0.409323 0.617200 0.409323 0.119131
0.179633 0.617200 0.930649 0.617200 0.179633
0.119131 0.409323 0.617200 0.409323 0.119131
0.034673 0.119131 0.179633 0.119131 0.034673
csst/msc/astrometry_config/csst_realtime.nnw
0 → 100644
View file @
c4de819d
NNW
# Neural Network Weights for the SExtractor star/galaxy classifier (V1.3)
# inputs: 9 for profile parameters + 1 for seeing.
# outputs: ``Stellarity index'' (0.0 to 1.0)
# Seeing FWHM range: from 0.025 to 5.5'' (images must have 1.5 < FWHM < 5 pixels)
# Optimized for Moffat profiles with 2<= beta <= 4.
3 10 10 1
-1.56604e+00 -2.48265e+00 -1.44564e+00 -1.24675e+00 -9.44913e-01 -5.22453e-01 4.61342e-02 8.31957e-01 2.15505e+00 2.64769e-01
3.03477e+00 2.69561e+00 3.16188e+00 3.34497e+00 3.51885e+00 3.65570e+00 3.74856e+00 3.84541e+00 4.22811e+00 3.27734e+00
-3.22480e-01 -2.12804e+00 6.50750e-01 -1.11242e+00 -1.40683e+00 -1.55944e+00 -1.84558e+00 -1.18946e-01 5.52395e-01 -4.36564e-01 -5.30052e+00
4.62594e-01 -3.29127e+00 1.10950e+00 -6.01857e-01 1.29492e-01 1.42290e+00 2.90741e+00 2.44058e+00 -9.19118e-01 8.42851e-01 -4.69824e+00
-2.57424e+00 8.96469e-01 8.34775e-01 2.18845e+00 2.46526e+00 8.60878e-02 -6.88080e-01 -1.33623e-02 9.30403e-02 1.64942e+00 -1.01231e+00
4.81041e+00 1.53747e+00 -1.12216e+00 -3.16008e+00 -1.67404e+00 -1.75767e+00 -1.29310e+00 5.59549e-01 8.08468e-01 -1.01592e-02 -7.54052e+00
1.01933e+01 -2.09484e+01 -1.07426e+00 9.87912e-01 6.05210e-01 -6.04535e-02 -5.87826e-01 -7.94117e-01 -4.89190e-01 -8.12710e-02 -2.07067e+01
-5.31793e+00 7.94240e+00 -4.64165e+00 -4.37436e+00 -1.55417e+00 7.54368e-01 1.09608e+00 1.45967e+00 1.62946e+00 -1.01301e+00 1.13514e-01
2.20336e-01 1.70056e+00 -5.20105e-01 -4.28330e-01 1.57258e-03 -3.36502e-01 -8.18568e-02 -7.16163e+00 8.23195e+00 -1.71561e-02 -1.13749e+01
3.75075e+00 7.25399e+00 -1.75325e+00 -2.68814e+00 -3.71128e+00 -4.62933e+00 -2.13747e+00 -1.89186e-01 1.29122e+00 -7.49380e-01 6.71712e-01
-8.41923e-01 4.64997e+00 5.65808e-01 -3.08277e-01 -1.01687e+00 1.73127e-01 -8.92130e-01 1.89044e+00 -2.75543e-01 -7.72828e-01 5.36745e-01
-3.65598e+00 7.56997e+00 -3.76373e+00 -1.74542e+00 -1.37540e-01 -5.55400e-01 -1.59195e-01 1.27910e-01 1.91906e+00 1.42119e+00 -4.35502e+00
-1.70059e+00 -3.65695e+00 1.22367e+00 -5.74367e-01 -3.29571e+00 2.46316e+00 5.22353e+00 2.42038e+00 1.22919e+00 -9.22250e-01 -2.32028e+00
0.00000e+00
1.00000e+00
csst/msc/astrometry_config/csst_realtime.param
0 → 100755
View file @
c4de819d
NUMBER #Running object number
#MAG_APER(1) #Fixed aperture magnitude vector [mag]
#MAGERR_APER(1) #RMS error vector for fixed aperture mag. [mag]
MAG_APER #Fixed aperture magnitude vector [mag]
MAGERR_APER #RMS error vector for fixed aperture mag. [mag]
MAG_AUTO #Kron-like elliptical aperture magnitude [mag]
MAGERR_AUTO #RMS error for AUTO magnitude [mag]
MAG_PETRO #Petrosian-like elliptical aperture magnitude [mag]
MAGERR_PETRO #RMS error for PETROsian magnitude [mag]
FLUX_AUTO #Flux of AUTO
FLUXERR_AUTO #RMS error for AUTO flux
SNR_WIN #Gaussian-weighted SNR
KRON_RADIUS #Kron apertures in units of A or B
PETRO_RADIUS #Petrosian apertures in units of A or B
X_IMAGE #Object position along x [pixel]
Y_IMAGE #Object position along y [pixel]
ALPHA_J2000 #Right ascension of barycenter (J2000) [deg]
DELTA_J2000 #Declination of barycenter (J2000) [deg]
X2_IMAGE #Variance along x [pixel**2]
Y2_IMAGE #Variance along y [pixel**2]
A_IMAGE #Profile RMS along major axis [pixel]
B_IMAGE #Profile RMS along minor axis [pixel]
THETA_IMAGE #Position angle (CCW/x) [deg]
ERRX2_IMAGE #Variance of position along x [pixel**2]
ERRY2_IMAGE #Variance of position along y [pixel**2]
ERRA_IMAGE #RMS position error along major axis [pixel]
ERRB_IMAGE #RMS position error along minor axis [pixel]
ERRTHETA_IMAGE #Error ellipse position angle (CCW/x) [deg]
XWIN_IMAGE #Windowed position estimate along x [pixel]
YWIN_IMAGE #Windowed position estimate along y [pixel]
ALPHAWIN_J2000 #Windowed right ascension (J2000) [deg]
DELTAWIN_J2000 #windowed declination (J2000) [deg]
X2WIN_IMAGE #Windowed variance along x [pixel**2]
Y2WIN_IMAGE #Windowed variance along y [pixel**2]
AWIN_IMAGE #Windowed profile RMS along major axis [pixel]
BWIN_IMAGE #Windowed profile RMS along minor axis [pixel]
THETAWIN_IMAGE #Windowed position angle (CCW/x) [deg]
ERRX2WIN_IMAGE #Variance of windowed pos along x [pixel**2]
ERRY2WIN_IMAGE #Variance of windowed pos along y [pixel**2]
ERRAWIN_IMAGE #RMS windowed pos error along major axis [pixel]
ERRBWIN_IMAGE #RMS windowed pos error along minor axis [pixel]
ERRAWIN_WORLD
ERRBWIN_WORLD
ERRTHETAWIN_IMAGE #Windowed error ellipse pos angle (CCW/x) [deg]
ERRTHETAWIN_J2000
FLAGS #Extraction flags
#IMAFLAGS_ISO #FLAG-image flags OR'ed over the iso. profile
#NIMAFLAGS_ISO
FWHM_IMAGE #FWHM assuming a gaussian core [pixel]
#ELONGATION #A_IMAGE/B_IMAGE
ELLIPTICITY #1 - B_IMAGE/A_IMAGE
CLASS_STAR #S/G classifier output
csst/msc/astrometry_config/csst_realtime.sex
0 → 100755
View file @
c4de819d
# Default configuration file for SExtractor 2.12.4
# EB 2010-10-10
#
#-------------------------------- Catalog ------------------------------------
CATALOG_NAME test.fits # name of the output catalog
CATALOG_TYPE FITS_LDAC # NONE,ASCII,ASCII_HEAD, ASCII_SKYCAT,
# ASCII_VOTABLE, FITS_1.0 or FITS_LDAC
PARAMETERS_NAME /line17/wfst/prog/config/wfst_realtime.param # name of the file containing catalog contents
#------------------------------- Extraction ----------------------------------
DETECT_TYPE CCD # CCD (linear) or PHOTO (with gamma correction)
DETECT_MINAREA 3 # min. # of pixels above threshold
DETECT_MAXAREA 0 # max. # of pixels above threshold (0=unlimited)
THRESH_TYPE RELATIVE # threshold type: RELATIVE (in sigmas)
# or ABSOLUTE (in ADUs)
DETECT_THRESH 3 # <sigmas> or <threshold>,<ZP> in mag.arcsec-2
ANALYSIS_THRESH 3 # <sigmas> or <threshold>,<ZP> in mag.arcsec-2
FILTER Y # apply filter for detection (Y or N)?
FILTER_NAME /line17/wfst/prog/config/wfst_realtime.conv # name of the file containing the filter
DEBLEND_NTHRESH 64 # Number of deblending sub-thresholds
DEBLEND_MINCONT 0.0005 # Minimum contrast parameter for deblending
CLEAN Y # Clean spurious detections? (Y or N)?
CLEAN_PARAM 0.5 # Cleaning efficiency
MASK_TYPE CORRECT # type of detection MASKing: can be one of
# NONE, BLANK or CORRECT
#-------------------------------- WEIGHTing ----------------------------------
WEIGHT_TYPE MAP_WEIGHT # type of WEIGHTing: NONE, BACKGROUND,
# MAP_RMS, MAP_VAR or MAP_WEIGHT
WEIGHT_IMAGE weight.fits # weight-map filename
#------------------------------ Photometry -----------------------------------
# similiar to BASS, use D=36 pixel to do flux calibration, d~=12arsec
PHOT_APERTURES 10
#PHOT_APERTURES 32 # MAG_APER aperture diameter(s) in pixels
PHOT_AUTOPARAMS 2.5, 3.5 # MAG_AUTO parameters: <Kron_fact>,<min_radius>
PHOT_PETROPARAMS 2.0, 3.5 # MAG_PETRO parameters: <Petrosian_fact>,
# <min_radius>
PHOT_AUTOAPERS 0.0,0.0 # <estimation>,<measurement> minimum apertures
# for MAG_AUTO and MAG_PETRO
SATUR_LEVEL 65535.0 # level (in ADUs) at which arises saturation
SATUR_KEY safSATURATE # keyword for saturation level (in ADUs)
MAG_ZEROPOINT 0.0 # magnitude zero-point
MAG_GAMMA 7.0 # gamma of emulsion (for photographic scans)
GAIN 1.0 # detector gain in e-/ADU
GAIN_KEY asdfGAIN # keyword for detector gain in e-/ADU
PIXEL_SCALE 0 # size of pixel in arcsec (0=use FITS WCS info)
#------------------------- Star/Galaxy Separation ----------------------------
SEEING_FWHM 1.2 # stellar FWHM in arcsec
STARNNW_NAME /line17/wfst/prog/config/wfst_realtime.nnw # Neural-Network_Weight table filename
#------------------------------ Background -----------------------------------
BACK_TYPE AUTO # AUTO or MANUAL
BACK_VALUE 0.0 # Default background value in MANUAL mode
BACK_SIZE 256 # Background mesh: <size> or <width>,<height>
BACK_FILTERSIZE 3 # Background filter: <size> or <width>,<height>
BACKPHOTO_TYPE LOCAL # can be GLOBAL or LOCAL
BACKPHOTO_THICK 24 # thickness (pix) of background rectangular aperture for LOCAL
#------------------------------ Check Image ----------------------------------
CHECKIMAGE_TYPE NONE # can be NONE, BACKGROUND, BACKGROUND_RMS,
# MINIBACKGROUND, MINIBACK_RMS, -BACKGROUND,
# FILTERED, OBJECTS, -OBJECTS, SEGMENTATION,
# or APERTURES
CHECKIMAGE_NAME check.fits # Filename for the check-image
#--------------------- Memory (change with caution!) -------------------------
MEMORY_OBJSTACK 3000 # number of objects in stack
MEMORY_PIXSTACK 300000 # number of pixels in stack
MEMORY_BUFSIZE 1024 # number of lines in buffer
#------------------------------- ASSOCiation ---------------------------------
ASSOC_NAME sky.list # name of the ASCII file to ASSOCiate
ASSOC_DATA 2,3,4 # columns of the data to replicate (0=all)
ASSOC_PARAMS 2,3,4 # columns of xpos,ypos[,mag]
ASSOC_RADIUS 2.0 # cross-matching radius (pixels)
ASSOC_TYPE NEAREST # ASSOCiation method: FIRST, NEAREST, MEAN,
# MAG_MEAN, SUM, MAG_SUM, MIN or MAX
ASSOCSELEC_TYPE MATCHED # ASSOC selection type: ALL, MATCHED or -MATCHED
#----------------------------- Miscellaneous ---------------------------------
VERBOSE_TYPE NORMAL # can be QUIET, NORMAL or FULL
HEADER_SUFFIX .head # Filename extension for additional headers
WRITE_XML N # Write XML file (Y/N)?
XML_NAME sex.xml # Filename for XML output
csst/msc/astrometry_config/default.param
0 → 100644
View file @
c4de819d
#NUMBER Running object number
#EXT_NUMBER FITS extension number
#FLUX_ISO Isophotal flux [count]
#FLUXERR_ISO RMS error for isophotal flux [count]
#MAG_ISO Isophotal magnitude [mag]
#MAGERR_ISO RMS error for isophotal magnitude [mag]
#FLUX_ISOCOR Corrected isophotal flux [count]
#FLUXERR_ISOCOR RMS error for corrected isophotal flux [count]
#MAG_ISOCOR Corrected isophotal magnitude [mag]
#MAGERR_ISOCOR RMS error for corrected isophotal magnitude [mag]
#FLUX_APER Flux vector within fixed circular aperture(s) [count]
#FLUXERR_APER RMS error vector for aperture flux(es) [count]
#MAG_APER Fixed aperture magnitude vector [mag]
#MAGERR_APER RMS error vector for fixed aperture mag. [mag]
#FLUX_AUTO Flux within a Kron-like elliptical aperture [count]
#FLUXERR_AUTO RMS error for AUTO flux [count]
#MAG_AUTO Kron-like elliptical aperture magnitude [mag]
#MAGERR_AUTO RMS error for AUTO magnitude [mag]
#FLUX_PETRO Flux within a Petrosian-like elliptical aperture [count]
#FLUXERR_PETRO RMS error for PETROsian flux [count]
#MAG_PETRO Petrosian-like elliptical aperture magnitude [mag]
#MAGERR_PETRO RMS error for PETROsian magnitude [mag]
#FLUX_BEST Best of FLUX_AUTO and FLUX_ISOCOR [count]
#FLUXERR_BEST RMS error for BEST flux [count]
#MAG_BEST Best of MAG_AUTO and MAG_ISOCOR [mag]
#MAGERR_BEST RMS error for MAG_BEST [mag]
#FLUX_WIN Gaussian-weighted flux [count]
#FLUXERR_WIN RMS error for WIN flux [count]
#MAG_WIN Gaussian-weighted magnitude [mag]
#MAGERR_WIN RMS error for MAG_WIN [mag]
#SNR_WIN Gaussian-weighted SNR
#FLUX_SOMFIT Flux derived from SOM fit [count]
#FLUXERR_SOMFIT RMS error for SOMFIT flux [count]
#MAG_SOMFIT Magnitude derived from SOM fit [mag]
#MAGERR_SOMFIT Magnitude error derived from SOM fit [mag]
#ERROR_SOMFIT Reduced Chi-square error of the SOM fit
#VECTOR_SOMFIT Position vector of the winning SOM node
#KRON_RADIUS Kron apertures in units of A or B
#PETRO_RADIUS Petrosian apertures in units of A or B
#BACKGROUND Background at centroid position [count]
#THRESHOLD Detection threshold above background [count]
#FLUX_MAX Peak flux above background [count]
#ISOAREA_IMAGE Isophotal area above Analysis threshold [pixel**2]
#ISOAREAF_IMAGE Isophotal area (filtered) above Detection threshold [pixel**2]
#XMIN_IMAGE Minimum x-coordinate among detected pixels [pixel]
#YMIN_IMAGE Minimum y-coordinate among detected pixels [pixel]
#XMAX_IMAGE Maximum x-coordinate among detected pixels [pixel]
#YMAX_IMAGE Maximum y-coordinate among detected pixels [pixel]
#XPEAK_IMAGE x-coordinate of the brightest pixel [pixel]
#YPEAK_IMAGE y-coordinate of the brightest pixel [pixel]
#XPEAK_FOCAL Focal-plane x coordinate of the brightest pixel
#YPEAK_FOCAL Focal-plane y coordinate of the brightest pixel
#XPEAK_WORLD World-x coordinate of the brightest pixel [deg]
#YPEAK_WORLD World-y coordinate of the brightest pixel [deg]
#ALPHAPEAK_SKY Right ascension of brightest pix (native) [deg]
#DELTAPEAK_SKY Declination of brightest pix (native) [deg]
#ALPHAPEAK_J2000 Right ascension of brightest pix (J2000) [deg]
#DELTAPEAK_J2000 Declination of brightest pix (J2000) [deg]
#ALPHAPEAK_B1950 Right ascension of brightest pix (B1950) [deg]
#DELTAPEAK_B1950 Declination of brightest pix (B1950) [deg]
#X_IMAGE Object position along x [pixel]
#Y_IMAGE Object position along y [pixel]
#X_IMAGE_DBL Object position along x (double precision) [pixel]
#Y_IMAGE_DBL Object position along y (double precision) [pixel]
#X_FOCAL Barycenter position along focal-plane x axis
#Y_FOCAL Barycenter position along focal-plane y axis
#X_WORLD Barycenter position along world x axis [deg]
#Y_WORLD Barycenter position along world y axis [deg]
#X_MAMA Barycenter position along MAMA x axis [m**(-6)]
#Y_MAMA Barycenter position along MAMA y axis [m**(-6)]
#ALPHA_SKY Right ascension of barycenter (native) [deg]
#DELTA_SKY Declination of barycenter (native) [deg]
#ALPHA_J2000 Right ascension of barycenter (J2000) [deg]
#DELTA_J2000 Declination of barycenter (J2000) [deg]
#ALPHA_B1950 Right ascension of barycenter (B1950) [deg]
#DELTA_B1950 Declination of barycenter (B1950) [deg]
#X2_IMAGE Variance along x [pixel**2]
#Y2_IMAGE Variance along y [pixel**2]
#XY_IMAGE Covariance between x and y [pixel**2]
#X2_WORLD Variance along X-WORLD (alpha) [deg**2]
#Y2_WORLD Variance along Y-WORLD (delta) [deg**2]
#XY_WORLD Covariance between X-WORLD and Y-WORLD [deg**2]
#CXX_IMAGE Cxx object ellipse parameter [pixel**(-2)]
#CYY_IMAGE Cyy object ellipse parameter [pixel**(-2)]
#CXY_IMAGE Cxy object ellipse parameter [pixel**(-2)]
#CXX_WORLD Cxx object ellipse parameter (WORLD units) [deg**(-2)]
#CYY_WORLD Cyy object ellipse parameter (WORLD units) [deg**(-2)]
#CXY_WORLD Cxy object ellipse parameter (WORLD units) [deg**(-2)]
#A_IMAGE Profile RMS along major axis [pixel]
#B_IMAGE Profile RMS along minor axis [pixel]
#THETA_IMAGE Position angle (CCW/x) [deg]
#A_WORLD Profile RMS along major axis (world units) [deg]
#B_WORLD Profile RMS along minor axis (world units) [deg]
#THETA_WORLD Position angle (CCW/world-x) [deg]
#THETA_SKY Position angle (east of north) (native) [deg]
#THETA_J2000 Position angle (east of north) (J2000) [deg]
#THETA_B1950 Position angle (east of north) (B1950) [deg]
#ERRX2_IMAGE Variance of position along x [pixel**2]
#ERRY2_IMAGE Variance of position along y [pixel**2]
#ERRXY_IMAGE Covariance of position between x and y [pixel**2]
#ERRX2_WORLD Variance of position along X-WORLD (alpha) [deg**2]
#ERRY2_WORLD Variance of position along Y-WORLD (delta) [deg**2]
#ERRXY_WORLD Covariance of position X-WORLD/Y-WORLD [deg**2]
#ERRCXX_IMAGE Cxx error ellipse parameter [pixel**(-2)]
#ERRCYY_IMAGE Cyy error ellipse parameter [pixel**(-2)]
#ERRCXY_IMAGE Cxy error ellipse parameter [pixel**(-2)]
#ERRCXX_WORLD Cxx error ellipse parameter (WORLD units) [deg**(-2)]
#ERRCYY_WORLD Cyy error ellipse parameter (WORLD units) [deg**(-2)]
#ERRCXY_WORLD Cxy error ellipse parameter (WORLD units) [deg**(-2)]
#ERRA_IMAGE RMS position error along major axis [pixel]
#ERRB_IMAGE RMS position error along minor axis [pixel]
#ERRTHETA_IMAGE Error ellipse position angle (CCW/x) [deg]
#ERRA_WORLD World RMS position error along major axis [deg]
#ERRB_WORLD World RMS position error along minor axis [deg]
#ERRTHETA_WORLD Error ellipse pos. angle (CCW/world-x) [deg]
#ERRTHETA_SKY Native error ellipse pos. angle (east of north) [deg]
#ERRTHETA_J2000 J2000 error ellipse pos. angle (east of north) [deg]
#ERRTHETA_B1950 B1950 error ellipse pos. angle (east of north) [deg]
#XWIN_IMAGE Windowed position estimate along x [pixel]
#YWIN_IMAGE Windowed position estimate along y [pixel]
#XWIN_FOCAL Windowed position along focal-plane x axis
#YWIN_FOCAL Windowed position along focal-plane y axis
#XWIN_WORLD Windowed position along world x axis [deg]
#YWIN_WORLD Windowed position along world y axis [deg]
#ALPHAWIN_SKY Windowed right ascension (native) [deg]
#DELTAWIN_SKY Windowed declination (native) [deg]
#ALPHAWIN_J2000 Windowed right ascension (J2000) [deg]
#DELTAWIN_J2000 windowed declination (J2000) [deg]
#ALPHAWIN_B1950 Windowed right ascension (B1950) [deg]
#DELTAWIN_B1950 Windowed declination (B1950) [deg]
#X2WIN_IMAGE Windowed variance along x [pixel**2]
#Y2WIN_IMAGE Windowed variance along y [pixel**2]
#XYWIN_IMAGE Windowed covariance between x and y [pixel**2]
#X2WIN_WORLD Windowed variance along X-WORLD (alpha) [deg**2]
#Y2WIN_WORLD Windowed variance along Y-WORLD (delta) [deg**2]
#XYWIN_WORLD Windowed covariance between X-WORLD and Y-WORLD [deg**2]
#CXXWIN_IMAGE Windowed Cxx object ellipse parameter [pixel**(-2)]
#CYYWIN_IMAGE Windowed Cyy object ellipse parameter [pixel**(-2)]
#CXYWIN_IMAGE Windowed Cxy object ellipse parameter [pixel**(-2)]
#CXXWIN_WORLD Windowed Cxx object ellipse parameter (WORLD units) [deg**(-2)]
#CYYWIN_WORLD Windowed Cyy object ellipse parameter (WORLD units) [deg**(-2)]
#CXYWIN_WORLD Windowed Cxy object ellipse parameter (WORLD units) [deg**(-2)]
#AWIN_IMAGE Windowed profile RMS along major axis [pixel]
#BWIN_IMAGE Windowed profile RMS along minor axis [pixel]
#THETAWIN_IMAGE Windowed position angle (CCW/x) [deg]
#AWIN_WORLD Windowed profile RMS along major axis (world units) [deg]
#BWIN_WORLD Windowed profile RMS along minor axis (world units) [deg]
#THETAWIN_WORLD Windowed position angle (CCW/world-x) [deg]
#THETAWIN_SKY Windowed position angle (east of north) (native) [deg]
#THETAWIN_J2000 Windowed position angle (east of north) (J2000) [deg]
#THETAWIN_B1950 Windowed position angle (east of north) (B1950) [deg]
#ERRX2WIN_IMAGE Variance of windowed pos along x [pixel**2]
#ERRY2WIN_IMAGE Variance of windowed pos along y [pixel**2]
#ERRXYWIN_IMAGE Covariance of windowed pos between x and y [pixel**2]
#ERRX2WIN_WORLD Variance of windowed pos along X-WORLD (alpha) [deg**2]
#ERRY2WIN_WORLD Variance of windowed pos along Y-WORLD (delta) [deg**2]
#ERRXYWIN_WORLD Covariance of windowed pos X-WORLD/Y-WORLD [deg**2]
#ERRCXXWIN_IMAGE Cxx windowed error ellipse parameter [pixel**(-2)]
#ERRCYYWIN_IMAGE Cyy windowed error ellipse parameter [pixel**(-2)]
#ERRCXYWIN_IMAGE Cxy windowed error ellipse parameter [pixel**(-2)]
#ERRCXXWIN_WORLD Cxx windowed error ellipse parameter (WORLD units) [deg**(-2)]
#ERRCYYWIN_WORLD Cyy windowed error ellipse parameter (WORLD units) [deg**(-2)]
#ERRCXYWIN_WORLD Cxy windowed error ellipse parameter (WORLD units) [deg**(-2)]
#ERRAWIN_IMAGE RMS windowed pos error along major axis [pixel]
#ERRBWIN_IMAGE RMS windowed pos error along minor axis [pixel]
#ERRTHETAWIN_IMAGE Windowed error ellipse pos angle (CCW/x) [deg]
#ERRAWIN_WORLD World RMS windowed pos error along major axis [deg]
#ERRBWIN_WORLD World RMS windowed pos error along minor axis [deg]
#ERRTHETAWIN_WORLD Windowed error ellipse pos. angle (CCW/world-x) [deg]
#ERRTHETAWIN_SKY Native windowed error ellipse pos. angle (east of north) [deg]
#ERRTHETAWIN_J2000 J2000 windowed error ellipse pos. angle (east of north) [deg]
#ERRTHETAWIN_B1950 B1950 windowed error ellipse pos. angle (east of north) [deg]
#NITER_WIN Number of iterations for WIN centering
#MU_THRESHOLD Analysis threshold above background [mag * arcsec**(-2)]
#MU_MAX Peak surface brightness above background [mag * arcsec**(-2)]
#ISOAREA_WORLD Isophotal area above Analysis threshold [deg**2]
#ISOAREAF_WORLD Isophotal area (filtered) above Detection threshold [deg**2]
#ISO0 Isophotal area at level 0 [pixel**2]
#ISO1 Isophotal area at level 1 [pixel**2]
#ISO2 Isophotal area at level 2 [pixel**2]
#ISO3 Isophotal area at level 3 [pixel**2]
#ISO4 Isophotal area at level 4 [pixel**2]
#ISO5 Isophotal area at level 5 [pixel**2]
#ISO6 Isophotal area at level 6 [pixel**2]
#ISO7 Isophotal area at level 7 [pixel**2]
#FLAGS Extraction flags
#FLAGS_WEIGHT Weighted extraction flags
#FLAGS_WIN Flags for WINdowed parameters
#IMAFLAGS_ISO FLAG-image flags OR'ed over the iso. profile
#NIMAFLAGS_ISO Number of flagged pixels entering IMAFLAGS_ISO
#NLOWWEIGHT_ISO Nb of pixels with low weight over the iso. profile
#NLOWDWEIGHT_ISO Nb of pixels with low det. weight over the iso. profile
#FWHM_IMAGE FWHM assuming a gaussian core [pixel]
#FWHM_WORLD FWHM assuming a gaussian core [deg]
#ELONGATION A_IMAGE/B_IMAGE
#ELLIPTICITY 1 - B_IMAGE/A_IMAGE
#POLAR_IMAGE (A_IMAGE^2 - B_IMAGE^2)/(A_IMAGE^2 + B_IMAGE^2)
#POLAR_WORLD (A_WORLD^2 - B_WORLD^2)/(A_WORLD^2 + B_WORLD^2)
#POLARWIN_IMAGE (AWIN^2 - BWIN^2)/(AWIN^2 + BWIN^2)
#POLARWIN_WORLD (AWIN^2 - BWIN^2)/(AWIN^2 + BWIN^2)
#CLASS_STAR S/G classifier output
#VIGNET Pixel data around detection [count]
#VIGNET_SHIFT Pixel data around detection, corrected for shift [count]
#VECTOR_ASSOC ASSOCiated parameter vector
#NUMBER_ASSOC Number of ASSOCiated IDs
#THRESHOLDMAX Maximum threshold possible for detection [count]
#FLUX_GROWTH Cumulated growth-curve [count]
#FLUX_GROWTHSTEP Step for growth-curves [pixel]
#MAG_GROWTH Cumulated magnitude growth-curve [mag]
#MAG_GROWTHSTEP Step for growth-curves [pixel]
#FLUX_RADIUS Fraction-of-light radii [pixel]
#FWHMPSF_IMAGE FWHM of the local PSF model [pixel]
#FWHMPSF_WORLD FWHM of the local PSF model (world units) [deg]
#XPSF_IMAGE X coordinate from PSF-fitting [pixel]
#YPSF_IMAGE Y coordinate from PSF-fitting [pixel]
#XPSF_WORLD PSF position along world x axis [deg]
#YPSF_WORLD PSF position along world y axis [deg]
#ALPHAPSF_SKY Right ascension of the fitted PSF (native) [deg]
#DELTAPSF_SKY Declination of the fitted PSF (native) [deg]
#ALPHAPSF_J2000 Right ascension of the fitted PSF (J2000) [deg]
#DELTAPSF_J2000 Declination of the fitted PSF (J2000) [deg]
#ALPHAPSF_B1950 Right ascension of the fitted PSF (B1950) [deg]
#DELTAPSF_B1950 Declination of the fitted PSF (B1950) [deg]
#FLUX_PSF Flux from PSF-fitting [count]
#FLUXERR_PSF RMS flux error for PSF-fitting [count]
#MAG_PSF Magnitude from PSF-fitting [mag]
#MAGERR_PSF RMS magnitude error from PSF-fitting [mag]
#NITER_PSF Number of iterations for PSF-fitting
#CHI2_PSF Reduced chi2 from PSF-fitting
#ERRX2PSF_IMAGE Variance of PSF position along x [pixel**2]
#ERRY2PSF_IMAGE Variance of PSF position along y [pixel**2]
#ERRXYPSF_IMAGE Covariance of PSF position between x and y [pixel**2]
#ERRX2PSF_WORLD Variance of PSF position along X-WORLD (alpha) [deg**2]
#ERRY2PSF_WORLD Variance of PSF position along Y-WORLD (delta) [deg**2]
#ERRXYPSF_WORLD Covariance of PSF position X-WORLD/Y-WORLD [deg**2]
#ERRCXXPSF_IMAGE Cxx PSF error ellipse parameter [pixel**(-2)]
#ERRCYYPSF_IMAGE Cyy PSF error ellipse parameter [pixel**(-2)]
#ERRCXYPSF_IMAGE Cxy PSF error ellipse parameter [pixel**(-2)]
#ERRCXXPSF_WORLD Cxx PSF error ellipse parameter (WORLD units) [deg**(-2)]
#ERRCYYPSF_WORLD Cyy PSF error ellipse parameter (WORLD units) [deg**(-2)]
#ERRCXYPSF_WORLD Cxy PSF error ellipse parameter (WORLD units) [deg**(-2)]
#ERRAPSF_IMAGE PSF RMS position error along major axis [pixel]
#ERRBPSF_IMAGE PSF RMS position error along minor axis [pixel]
#ERRTHETAPSF_IMAGE PSF error ellipse position angle (CCW/x) [deg]
#ERRAPSF_WORLD World PSF RMS position error along major axis [pixel]
#ERRBPSF_WORLD World PSF RMS position error along minor axis [pixel]
#ERRTHETAPSF_WORLD PSF error ellipse pos. angle (CCW/world-x) [deg]
#ERRTHETAPSF_SKY Native PSF error ellipse pos. angle (east of north) [deg]
#ERRTHETAPSF_J2000 J2000 PSF error ellipse pos. angle (east of north) [deg]
#ERRTHETAPSF_B1950 B1950 PSF error ellipse pos. angle (east of north) [deg]
#DURATION_ANALYSIS Duration of analysis for this source [s]
#VECTOR_MODEL Model-fitting coefficients
#VECTOR_MODELERR Model-fitting coefficient uncertainties
#MATRIX_MODELERR Model-fitting covariance matrix
#CHI2_MODEL Reduced Chi2 of the fit
#FLAGS_MODEL Model-fitting flags
#NITER_MODEL Number of iterations for model-fitting
#FLUX_MODEL Flux from model-fitting [count]
#FLUXERR_MODEL RMS error on model-fitting flux [count]
#MAG_MODEL Magnitude from model-fitting [mag]
#MAGERR_MODEL RMS error on model-fitting magnitude [mag]
#FLUX_HYBRID Hybrid flux from model-fitting [count]
#FLUXERR_HYBRID RMS error on hybrid flux [count]
#MAG_HYBRID Hybrid magnitude from model-fitting [mag]
#MAGERR_HYBRID RMS error on hybrid magnitude [mag]
#FLUX_MAX_MODEL Peak model flux above background [count]
#FLUX_EFF_MODEL Effective model flux above background [count]
#FLUX_MEAN_MODEL Mean effective model flux above background [count]
#MU_MAX_MODEL Peak model surface brightness above background [mag * arcsec**(-2)]
#MU_EFF_MODEL Effective model surface brightness above background [mag * arcsec**(-2)]
#MU_MEAN_MODEL Mean effective model surface brightness above background [mag * arcsec**(-2)]
#XMODEL_IMAGE X coordinate from model-fitting [pixel]
#YMODEL_IMAGE Y coordinate from model-fitting [pixel]
#XFOCAL_WORLD Fitted position along focal-plane x axis
#YFOCAL_WORLD Fitted position along focal-plane y axis
#XMODEL_WORLD Fitted position along world x axis [deg]
#YMODEL_WORLD Fitted position along world y axis [deg]
#ALPHAMODEL_SKY Fitted position along right ascension (native) [deg]
#DELTAMODEL_SKY Fitted position along declination (native) [deg]
#ALPHAMODEL_J2000 Fitted position along right ascension (J2000) [deg]
#DELTAMODEL_J2000 Fitted position along declination (J2000) [deg]
#ALPHAMODEL_B1950 Fitted position along right ascension (B1950) [deg]
#DELTAMODEL_B1950 Fitted position along declination (B1950) [deg]
#ERRX2MODEL_IMAGE Variance of fitted position along x [pixel**2]
#ERRY2MODEL_IMAGE Variance of fitted position along y [pixel**2]
#ERRXYMODEL_IMAGE Covariance of fitted position between x and y [pixel**2]
#ERRX2MODEL_WORLD Variance of fitted position along X-WORLD (alpha) [deg**2]
#ERRY2MODEL_WORLD Variance of fitted position along Y-WORLD (delta) [deg**2]
#ERRXYMODEL_WORLD Covariance of fitted position X-WORLD/Y-WORLD [deg**2]
#ERRCXXMODEL_IMAGE Cxx error ellipse parameter of fitted position [pixel**(-2)]
#ERRCYYMODEL_IMAGE Cyy error ellipse parameter of fitted position [pixel**(-2)]
#ERRCXYMODEL_IMAGE Cxy error ellipse parameter of fitted position [pixel**(-2)]
#ERRCXXMODEL_WORLD Cxx fitted error ellipse parameter (WORLD units) [deg**(-2)]
#ERRCYYMODEL_WORLD Cyy fitted error ellipse parameter (WORLD units) [deg**(-2)]
#ERRCXYMODEL_WORLD Cxy fitted error ellipse parameter (WORLD units) [deg**(-2)]
#ERRAMODEL_IMAGE RMS error of fitted position along major axis [pixel]
#ERRBMODEL_IMAGE RMS error of fitted position along minor axis [pixel]
#ERRTHETAMODEL_IMAGE Error ellipse pos.angle of fitted position (CCW/x) [deg]
#ERRAMODEL_WORLD World RMS error of fitted position along major axis [deg]
#ERRBMODEL_WORLD World RMS error of fitted position along minor axis [deg]
#ERRTHETAMODEL_WORLD Error ellipse pos.angle of fitted position (CCW/world-x) [deg]
#ERRTHETAMODEL_SKY Native fitted error ellipse pos. angle (east of north) [deg]
#ERRTHETAMODEL_J2000 J2000 fitted error ellipse pos. angle (east of north) [deg]
#ERRTHETAMODEL_B1950 B1950 fitted error ellipse pos. angle (east of north) [deg]
#X2MODEL_IMAGE Variance along x from model-fitting [pixel**2]
#Y2MODEL_IMAGE Variance along y from model-fitting [pixel**2]
#XYMODEL_IMAGE Covariance between x and y from model-fitting [pixel**2]
#ELLIP1MODEL_IMAGE Ellipticity component from model-fitting
#ELLIP2MODEL_IMAGE Ellipticity component from model-fitting
#POLAR1MODEL_IMAGE Ellipticity component (quadratic) from model-fitting
#POLAR2MODEL_IMAGE Ellipticity component (quadratic) from model-fitting
#ELLIP1ERRMODEL_IMAGE Ellipticity component std.error from model-fitting
#ELLIP2ERRMODEL_IMAGE Ellipticity component std.error from model-fitting
#ELLIPCORRMODEL_IMAGE Corr.coeff between ellip.components from model-fitting
#POLAR1ERRMODEL_IMAGE Polarisation component std.error from model-fitting
#POLAR2ERRMODEL_IMAGE Polarisation component std.error from model-fitting
#POLARCORRMODEL_IMAGE Corr.coeff between polar. components from fitting
#X2MODEL_WORLD Variance along X-WORLD (alpha) from model-fitting [deg**2]
#Y2MODEL_WORLD Variance along Y_WORLD (delta) from model-fitting [deg**2]
#XYMODEL_WORLD Covariance between X-WORLD and Y-WORLD from model-fitting [deg**2]
#ELLIP1MODEL_WORLD Ellipticity component from model-fitting
#ELLIP2MODEL_WORLD Ellipticity component from model-fitting
#POLAR1MODEL_WORLD Polarisation component from model-fitting
#POLAR2MODEL_WORLD Polarisation component from model-fitting
#ELLIP1ERRMODEL_WORLD Ellipticity component std.error from model-fitting
#ELLIP2ERRMODEL_WORLD Ellipticity component std.error from model-fitting
#ELLIPCORRMODEL_WORLD Corr.coeff between ellip.components from model-fitting
#POLAR1ERRMODEL_WORLD Polarisation component std.error from model-fitting
#POLAR2ERRMODEL_WORLD Polarisation component std.error from model-fitting
#POLARCORRMODEL_WORLD Corr.coeff between polar. components from fitting
#CXXMODEL_IMAGE Cxx ellipse parameter from model-fitting [pixel**(-2)]
#CYYMODEL_IMAGE Cyy ellipse parameter from model-fittinh [pixel**(-2)]
#CXYMODEL_IMAGE Cxy ellipse parameter from model-fitting [pixel**(-2)]
#CXXMODEL_WORLD Cxx ellipse parameter (WORLD) from model-fitting [deg**(-2)]
#CYYMODEL_WORLD Cyy ellipse parameter (WORLD) from model-fitting [deg**(-2)]
#CXYMODEL_WORLD Cxy ellipse parameter (WORLD) from model-fitting [deg**(-2)]
#AMODEL_IMAGE Model RMS along major axis [pixel]
#BMODEL_IMAGE Model RMS along minor axis [pixel]
#THETAMODEL_IMAGE Model position angle (CCW/x) [deg]
#AMODEL_WORLD Model RMS along major axis (WORLD units) [deg]
#BMODEL_WORLD Model RMS along minor axis (WORLD units) [deg]
#THETAMODEL_WORLD Model position angle (CCW/WORLD-x) [deg]
#THETAMODEL_SKY Model position angle (east of north) (native) [deg]
#THETAMODEL_J2000 Model position angle (east of north) (J2000) [deg]
#THETAMODEL_B1950 Model position angle (east of north) (B1950) [deg]
#SPREAD_MODEL Spread parameter from model-fitting
#SPREADERR_MODEL Spread parameter error from model-fitting
#NOISEAREA_MODEL Equivalent noise area of the fitted model [pixel**2]
#FLUX_BACKOFFSET Background offset from fitting [count]
#FLUXERR_BACKOFFSET RMS error on fitted background offset [count]
#FLUX_POINTSOURCE Point source flux from fitting [count]
#FLUXERR_POINTSOURCE RMS error on fitted point source total flux [count]
#FLUXRATIO_POINTSOURCE Point-source flux-to-total ratio from fitting
#FLUXRATIOERR_POINTSOURCE RMS error on point-source flux-to-total ratio
#MAG_POINTSOURCE Point source total magnitude from fitting [mag]
#MAGERR_POINTSOURCE RMS error on fitted point source total magnitude [mag]
#FLUX_SPHEROID Spheroid total flux from fitting [count]
#FLUXERR_SPHEROID RMS error on fitted spheroid total flux [count]
#MAG_SPHEROID Spheroid total magnitude from fitting [mag]
#MAGERR_SPHEROID RMS error on fitted spheroid total magnitude [mag]
#FLUX_MAX_SPHEROID Peak spheroid flux above background [count]
#FLUX_EFF_SPHEROID Effective spheroid flux above background [count]
#FLUX_MEAN_SPHEROID Mean effective spheroid flux above background [count]
#MU_MAX_SPHEROID Peak spheroid surface brightness above background [mag * arcsec**(-2)]
#MU_EFF_SPHEROID Effective spheroid surface brightness above background [mag * arcsec**(-2)]
#MU_MEAN_SPHEROID Mean effective spheroid surface brightness above backgrou [mag * arcsec**(-2)]
#FLUXRATIO_SPHEROID Spheroid flux-to-total ratio from fitting
#FLUXRATIOERR_SPHEROID RMS error on spheroid flux-to-total ratio
#SPHEROID_REFF_IMAGE Spheroid effective radius from fitting [pixel]
#SPHEROID_REFFERR_IMAGE RMS error on fitted spheroid effective radius [pixel]
#SPHEROID_REFF_WORLD Spheroid effective radius from fitting [deg]
#SPHEROID_REFFERR_WORLD RMS error on fitted spheroid effective radius [deg]
#SPHEROID_ASPECT_IMAGE Spheroid aspect ratio from fitting
#SPHEROID_ASPECTERR_IMAGE RMS error on fitted spheroid aspect ratio
#SPHEROID_ASPECT_WORLD Spheroid aspect ratio from fitting
#SPHEROID_ASPECTERR_WORLD RMS error on fitted spheroid aspect ratio
#SPHEROID_THETA_IMAGE Spheroid position angle (CCW/x) from fitting [deg]
#SPHEROID_THETAERR_IMAGE RMS error on spheroid position angle [deg]
#SPHEROID_THETA_WORLD Spheroid position angle (CCW/world-x) [deg]
#SPHEROID_THETAERR_WORLD RMS error on spheroid position angle [deg]
#SPHEROID_THETA_SKY Spheroid position angle (east of north, native) [deg]
#SPHEROID_THETA_J2000 Spheroid position angle (east of north, J2000) [deg]
#SPHEROID_THETA_B1950 Spheroid position angle (east of north, B1950) [deg]
#SPHEROID_SERSICN Spheroid Sersic index from fitting
#SPHEROID_SERSICNERR RMS error on fitted spheroid Sersic index
#FLUX_DISK Disk total flux from fitting [count]
#FLUXERR_DISK RMS error on fitted disk total flux [count]
#MAG_DISK Disk total magnitude from fitting [mag]
#MAGERR_DISK RMS error on fitted disk total magnitude [mag]
#FLUX_MAX_DISK Peak disk flux above background [count]
#FLUX_EFF_DISK Effective disk flux above background [count]
#FLUX_MEAN_DISK Mean effective disk flux above background [count]
#MU_MAX_DISK Peak disk surface brightness above background [mag * arcsec**(-2)]
#MU_EFF_DISK Effective disk surface brightness above background [mag * arcsec**(-2)]
#MU_MEAN_DISK Mean effective disk surface brightness above background [mag * arcsec**(-2)]
#FLUXRATIO_DISK Disk flux-to-total ratio from fitting
#FLUXRATIOERR_DISK RMS error on disk flux-to-total ratio
#DISK_SCALE_IMAGE Disk scalelength from fitting [pixel]
#DISK_SCALEERR_IMAGE RMS error on fitted disk scalelength [pixel]
#DISK_SCALE_WORLD Disk scalelength from fitting (world coords) [deg]
#DISK_SCALEERR_WORLD RMS error on fitted disk scalelength (world coords) [deg]
#DISK_ASPECT_IMAGE Disk aspect ratio from fitting
#DISK_ASPECTERR_IMAGE RMS error on fitted disk aspect ratio
#DISK_ASPECT_WORLD Disk aspect ratio from fitting
#DISK_ASPECTERR_WORLD RMS error on disk aspect ratio
#DISK_INCLINATION Disk inclination from fitting [deg]
#DISK_INCLINATIONERR RMS error on disk inclination from fitting [deg]
#DISK_THETA_IMAGE Disk position angle (CCW/x) from fitting [deg]
#DISK_THETAERR_IMAGE RMS error on fitted disk position angle [deg]
#DISK_THETA_WORLD Disk position angle (CCW/world-x) [deg]
#DISK_THETAERR_WORLD RMS error on disk position angle [deg]
#DISK_THETA_SKY Disk position angle (east of north, native) [deg]
#DISK_THETA_J2000 Disk position angle (east of north, J2000) [deg]
#DISK_THETA_B1950 Disk position angle (east of north, B1950) [deg]
#CHI2_DETMODEL Reduced Chi2 of the det. model fit to measurement image
#FLAGS_DETMODEL Detection model-fitting flags
#NITER_DETMODEL Number of iterations for detection model-fitting
#FLUX_DETMODEL Flux from detection model-fitting [count]
#FLUXERR_DETMODEL RMS error on detection model-fitting flux [count]
#MAG_DETMODEL Magnitude from detection model-fitting [mag]
#MAGERR_DETMODEL RMS error on detection model-fitting magnitude [mag]
csst/msc/astrometry_config/default2.scamp
0 → 100755
View file @
c4de819d
# Default configuration file for SCAMP 2.0.4
# EB 2016-11-04
#
#----------------------------- Field grouping ---------------------------------
FGROUP_RADIUS 2.0 # Max dist (deg) between field groups
#---------------------------- Reference catalogs ------------------------------
REF_SERVER cocat1.u-strasbg.fr # Internet addresses of catalog servers
REF_PORT 80 # Ports to connect to catalog servers
CDSCLIENT_EXEC aclient_cgi # CDSclient executable
ASTREF_CATALOG FILE # NONE, FILE, USNO-A1,USNO-A2,USNO-B1,
# GSC-1.3,GSC-2.2,GSC-2.3,
# TYCHO-2, UCAC-1,UCAC-2,UCAC-3,UCAC-4,
# NOMAD-1, PPMX, CMC-14, 2MASS, DENIS-3,
# SDSS-R3,SDSS-R5,SDSS-R6,SDSS-R7,
# SDSS-R8, SDSS-R9
ASTREF_BAND DEFAULT # Photom. band for astr.ref.magnitudes
# or DEFAULT, BLUEST, or REDDEST
ASTREFCAT_NAME ref.cat # Local astrometric reference catalogs
ASTREFCENT_KEYS X_WORLD,Y_WORLD # Local ref.cat. centroid parameters
ASTREFERR_KEYS ERRA_WORLD, ERRB_WORLD , ERRTHETA_WORLD
# Local ref.cat. err. ellipse params
ASTREFMAG_KEY MAG # Local ref.cat. magnitude parameter
ASTREFMAGERR_KEY MAGERR # Local ref.cat. mag. error parameter
ASTREFOBSDATE_KEY OBSDATE # Local ref.cat. obs. date parameter
ASTREFMAG_LIMITS -99,99 # Select magnitude range in ASTREF_BAND
SAVE_REFCATALOG Y # Save ref catalogs in FITS-LDAC format?
REFOUT_CATPATH ./ # Save path for reference catalogs
#--------------------------- Merged output catalogs ---------------------------
MERGEDOUTCAT_TYPE FITS_LDAC # NONE, ASCII_HEAD, ASCII, FITS_LDAC
MERGEDOUTCAT_NAME merged.cat # Merged output catalog filename
#--------------------------- Full output catalogs ---------------------------
FULLOUTCAT_TYPE FITS_LDAC # NONE, ASCII_HEAD, ASCII, FITS_LDAC
FULLOUTCAT_NAME full.cat # Full output catalog filename
#----------------------------- Pattern matching -------------------------------
MATCH Y # Do pattern-matching (Y/N) ?
MATCH_NMAX 0 # Max.number of detections for MATCHing
# (0=auto)
PIXSCALE_MAXERR 2.0 # Max scale-factor uncertainty
POSANGLE_MAXERR 2.0 # Max position-angle uncertainty (deg)
POSITION_MAXERR 2.0 # Max positional uncertainty (arcmin)
MATCH_RESOL 0 # Matching resolution (arcsec); 0=auto
MATCH_FLIPPED Y # Allow matching with flipped axes?
MOSAIC_TYPE FIX_FOCALPLANE # UNCHANGED, SAME_CRVAL, SHARE_PROJAXIS,
# FIX_FOCALPLANE or LOOSE
FIXFOCALPLANE_NMIN 1 # Min number of dets for FIX_FOCALPLANE
#---------------------------- Cross-identification ----------------------------
CROSSID_RADIUS 2.0 # Cross-id initial radius (arcsec)
#---------------------------- Astrometric solution ----------------------------
SOLVE_ASTROM Y # Compute astrometric solution (Y/N) ?
PROJECTION_TYPE TAN # SAME, TPV or TAN
ASTRINSTRU_KEY FILTER,QRUNID # FITS keyword(s) defining the astrom
STABILITY_TYPE EXPOSURE # EXPOSURE, PRE-DISTORTED or INSTRUMENT
CENTROID_KEYS XWIN_IMAGE,YWIN_IMAGE # Cat. parameters for centroiding
CENTROIDERR_KEYS ERRAWIN_IMAGE,ERRBWIN_IMAGE,ERRTHETAWIN_IMAGE
# Cat. params for centroid err ellipse
DISTORT_KEYS XWIN_IMAGE,YWIN_IMAGE # Cat. parameters or FITS keywords
DISTORT_GROUPS 1,1 # Polynom group for each context key
DISTORT_DEGREES 2 # Polynom degree for each group
FOCDISTORT_DEGREE 1 # Polynom degree for focal plane coords
ASTREF_WEIGHT 1000000.0 # Relative weight of ref.astrom.ca
ASTRACCURACY_TYPE SIGMA-PIXEL # SIGMA-PIXEL, SIGMA-ARCSEC,
# or TURBULENCE-ARCSEC
ASTRACCURACY_KEY ASTRACCU # FITS keyword for ASTR_ACCURACY param.
ASTR_ACCURACY 0.00000001 # Astrom. uncertainty floor parameter
ASTRCLIP_NSIGMA 3 # Astrom. clipping threshold in sigmas
COMPUTE_PARALLAXES N # Compute trigonom. parallaxes (Y/N)?
COMPUTE_PROPERMOTIONS N # Compute proper motions (Y/N)?
CORRECT_COLOURSHIFTS N # Correct for colour shifts (Y/N)?
INCLUDE_ASTREFCATALOG N # Include ref.cat in prop.motions (Y/N)?
ASTR_FLAGSMASK 0x00fc # Astrometry rejection mask on SEx FLAGS
ASTR_IMAFLAGSMASK 0x0 # Astrometry rejection mask on IMAFLAGS
#---------------------------- Photometric solution ----------------------------
SOLVE_PHOTOM Y # Compute photometric solution (Y/N) ?
MAGZERO_OUT 0.0 # Magnitude zero-point(s) in output
MAGZERO_INTERR 0.01 # Internal mag.zero-point accuracy
MAGZERO_REFERR 0.03 # Photom.field mag.zero-point accuracy
PHOTINSTRU_KEY FILTER # FITS keyword(s) defining the photom.
MAGZERO_KEY PHOT_C # FITS keyword for the mag zero-point
EXPOTIME_KEY EXPTIME # FITS keyword for the exposure time (s)
AIRMASS_KEY AIRMASS # FITS keyword for the airmass
EXTINCT_KEY PHOT_K # FITS keyword for the extinction coeff
PHOTOMFLAG_KEY PHOTFLAG # FITS keyword for the photometry flag
PHOTFLUX_KEY FLUX_AUTO # Catalog param. for the flux measurement
PHOTFLUXERR_KEY FLUXERR_AUTO # Catalog parameter for the flux error
PHOTCLIP_NSIGMA 3.0 # Photom.clipping threshold in sigmas
PHOT_ACCURACY 1e-3 # Photometric uncertainty floor (frac.)
PHOT_FLAGSMASK 0x00fc # Photometry rejection mask on SEx FLAGS
PHOT_IMAFLAGSMASK 0x0 # Photometry rejection mask on IMAFLAGS
#------------------------------- Check-plots ----------------------------------
CHECKPLOT_CKEY SCAMPCOL # FITS keyword for PLPLOT field colour
CHECKPLOT_DEV PS # NULL, XWIN, TK, PS, PSC, XFIG, PNG,
# JPEG, AQT, PDF or SVG
CHECKPLOT_RES 0 # Check-plot resolution (0 = default)
CHECKPLOT_ANTIALIAS Y # Anti-aliasing using convert (Y/N) ?
CHECKPLOT_TYPE FGROUPS,DISTORTION,ASTR_INTERROR2D,ASTR_INTERROR1D,ASTR_REFERROR2D,ASTR_REFERROR1D,ASTR_CHI2,PHOT_ERROR
CHECKPLOT_NAME fgroups,distort,astr_interror2d,astr_interror1d,astr_referror2d,astr_referror1d,astr_chi2,psphot_error # Check-plot filename(s)
#------------------------------- Check-images ---------------------------------
CHECKIMAGE_TYPE AS_PAIR # NONE, AS_PAIR, AS_REFPAIR, or AS_XCORR
CHECKIMAGE_NAME check.fits # Check-image filename(s)
#------------------------------ Miscellaneous ---------------------------------
SN_THRESHOLDS 10.0,100.0 # S/N thresholds (in sigmas) for all and
# high-SN sample
FWHM_THRESHOLDS 0.0,100.0 # FWHM thresholds (in pixels) for sources
ELLIPTICITY_MAX 0.5 # Max. source ellipticity
FLAGS_MASK 0x00f0 # Global rejection mask on SEx FLAGS
WEIGHTFLAGS_MASK 0x00ff # Global rejec. mask on SEx FLAGS_WEIGHT
IMAFLAGS_MASK 0x0 # Global rejec. mask on SEx IMAFLAGS_ISO
AHEADER_GLOBAL scamp.abcdhead # Filename of the global INPUT header
AHEADER_SUFFIX .ahead # Filename extension for additional
# INPUT headers
HEADER_SUFFIX .head # Filename extension for OUTPUT headers
HEADER_TYPE NORMAL # NORMAL or FOCAL_PLANE
VERBOSE_TYPE NORMAL # QUIET, NORMAL, LOG or FULL
WRITE_XML N # Write XML file (Y/N)?
XML_NAME scamp.xml # Filename for XML output
XSL_URL file:///usr/local/share/scamp/scamp.xsl
# Filename for XSL style-sheet
NTHREADS 0 # Number of simultaneous threads for
# the SMP version of SCAMP
# 0 = automatic
csst/msc/astrometry_config/new_csst_realtime.no.weight.sex
0 → 100644
View file @
c4de819d
# Default configuration file for SExtractor 2.19.5
# EB 2016-08-21
#
#-------------------------------- Catalog ------------------------------------
CATALOG_NAME test.fits # name of the output catalog
CATALOG_TYPE FITS_LDAC # NONE,ASCII,ASCII_HEAD, ASCII_SKYCAT,
# ASCII_VOTABLE, FITS_1.0 or FITS_LDAC
PARAMETERS_NAME ./csst_realtime.param # name of the file containing catalog contents
#------------------------------- Extraction ----------------------------------
DETECT_TYPE CCD # CCD (linear) or PHOTO (with gamma correction)
DETECT_MINAREA 15 # min. # of pixels above threshold
DETECT_MAXAREA 0 # max. # of pixels above threshold (0=unlimited)
THRESH_TYPE RELATIVE # threshold type: RELATIVE (in sigmas)
# or ABSOLUTE (in ADUs)
DETECT_THRESH 3 # <sigmas> or <threshold>,<ZP> in mag.arcsec-2
ANALYSIS_THRESH 3 # <sigmas> or <threshold>,<ZP> in mag.arcsec-2
FILTER Y # apply filter for detection (Y or N)?
FILTER_NAME ./csst_realtime.conv # name of the file containing the filter
FILTER_THRESH # Threshold[s] for retina filtering
DEBLEND_NTHRESH 64 # Number of deblending sub-thresholds
DEBLEND_MINCONT 0.0005 # Minimum contrast parameter for deblending
CLEAN Y # Clean spurious detections? (Y or N)?
CLEAN_PARAM 0.5 # Cleaning efficiency
MASK_TYPE CORRECT # type of detection MASKing: can be one of
# NONE, BLANK or CORRECT
#-------------------------------- FLAGging -----------------------------------
FLAG_IMAGE flag.fits # filename for an input FLAG-image
FLAG_TYPE OR # flag pixel combination: OR, AND, MIN, MAX
# or MOST
#------------------------------ Photometry -----------------------------------
PHOT_APERTURES 10 # MAG_APER aperture diameter(s) in pixels
PHOT_AUTOPARAMS 2.5, 3.5 # MAG_AUTO parameters: <Kron_fact>,<min_radius>
PHOT_PETROPARAMS 2.0, 3.5 # MAG_PETRO parameters: <Petrosian_fact>,
# <min_radius>
PHOT_AUTOAPERS 0.0,0.0 # <estimation>,<measurement> minimum apertures
# for MAG_AUTO and MAG_PETRO
PHOT_FLUXFRAC 0.5 # flux fraction[s] used for FLUX_RADIUS
SATUR_LEVEL 65535.0 # level (in ADUs) at which arises saturation
SATUR_KEY safSATURATE # keyword for saturation level (in ADUs)
MAG_ZEROPOINT 0.0 # magnitude zero-point
MAG_GAMMA 7.0 # gamma of emulsion (for photographic scans)
GAIN 1.0 # detector gain in e-/ADU
GAIN_KEY asdfGAIN # keyword for detector gain in e-/ADU
PIXEL_SCALE 0 # size of pixel in arcsec (0=use FITS WCS info)
#------------------------- Star/Galaxy Separation ----------------------------
SEEING_FWHM 1.2 # stellar FWHM in arcsec
STARNNW_NAME ./csst_realtime.nnw # Neural-Network_Weight table filename
#------------------------------ Background -----------------------------------
BACK_TYPE AUTO # AUTO or MANUAL
BACK_VALUE 0.0 # Default background value in MANUAL mode
BACK_SIZE 256 # Background mesh: <size> or <width>,<height>
BACK_FILTERSIZE 3 # Background filter: <size> or <width>,<height>
BACKPHOTO_TYPE LOCAL # can be GLOBAL or LOCAL
BACKPHOTO_THICK 24 # thickness of the background LOCAL annulus
BACK_FILTTHRESH 0.0 # Threshold above which the background-
# map filter operates
#------------------------------ Check Image ----------------------------------
CHECKIMAGE_TYPE NONE # can be NONE, BACKGROUND, BACKGROUND_RMS,
# MINIBACKGROUND, MINIBACK_RMS, -BACKGROUND,
# FILTERED, OBJECTS, -OBJECTS, SEGMENTATION,
# or APERTURES
CHECKIMAGE_NAME check.fits # Filename for the check-image
#--------------------- Memory (change with caution!) -------------------------
MEMORY_OBJSTACK 3000 # number of objects in stack
MEMORY_PIXSTACK 300000 # number of pixels in stack
MEMORY_BUFSIZE 1024 # number of lines in buffer
#------------------------------- ASSOCiation ---------------------------------
ASSOC_NAME sky.list # name of the ASCII file to ASSOCiate
ASSOC_DATA 2,3,4 # columns of the data to replicate (0=all)
ASSOC_PARAMS 2,3,4 # columns of xpos,ypos[,mag]
ASSOCCOORD_TYPE PIXEL # ASSOC coordinates: PIXEL or WORLD
ASSOC_RADIUS 2.0 # cross-matching radius (pixels)
ASSOC_TYPE NEAREST # ASSOCiation method: FIRST, NEAREST, MEAN,
# MAG_MEAN, SUM, MAG_SUM, MIN or MAX
ASSOCSELEC_TYPE MATCHED # ASSOC selection type: ALL, MATCHED or -MATCHED
#----------------------------- Miscellaneous ---------------------------------
VERBOSE_TYPE NORMAL # can be QUIET, NORMAL or FULL
HEADER_SUFFIX .abcdhead # Filename extension for additional headers
WRITE_XML N # Write XML file (Y/N)?
XML_NAME sex.xml # Filename for XML output
XSL_URL file:///usr/local/share/sextractor/sextractor.xsl
# Filename for XSL style-sheet
NTHREADS 1 # 1 single thread
FITS_UNSIGNED N # Treat FITS integer values as unsigned (Y/N)?
INTERP_MAXXLAG 16 # Max. lag along X for 0-weight interpolation
INTERP_MAXYLAG 16 # Max. lag along Y for 0-weight interpolation
INTERP_TYPE ALL # Interpolation type: NONE, VAR_ONLY or ALL
#--------------------------- Experimental Stuff -----------------------------
PSF_NAME default.psf # File containing the PSF model
PSF_NMAX 1 # Max.number of PSFs fitted simultaneously
PATTERN_TYPE RINGS-HARMONIC # can RINGS-QUADPOLE, RINGS-OCTOPOLE,
# RINGS-HARMONICS or GAUSS-LAGUERRE
SOM_NAME default.som # File containing Self-Organizing Map weights
csst/msc/pipeline.py
View file @
c4de819d
# def do_one_exposure():
import
glob
import
os
from
csst.msc.astrometry
import
CsstProcMscPositionCalibration
from
csst.msc.data
import
CsstMscImgData
from
csst.msc.instrument
import
CsstMscInstrumentProc
HOSTNAME
=
os
.
uname
()[
1
]
if
HOSTNAME
==
"tulip"
:
# on Tulip
DIR_TEST
=
"/share/Cycle-3-SimuData/multipleBandsImaging/CSST_shearOFF/MSC_0000020/"
#
MSC_MS_210525220000_100000020_06_raw.fits
DIR_TEST
=
"/share/Cycle-3-SimuData/multipleBandsImaging/CSST_shearOFF/MSC_0000020/"
# MSC_MS_210525220000_100000020_06_raw.fits
PATH_BIAS
=
"/share/HDD7/csstpipeline/ref/MSC_CLB_210525200000_100000016_{:02d}_combine.fits"
PATH_DARK
=
"/share/HDD7/csstpipeline/ref/MSC_CLD_210525202000_100000016_{:02d}_combine.fits"
PATH_FLAT
=
"/share/HDD7/csstpipeline/ref/MSC_CLF_210525201000_100000016_{:02d}_combine.fits"
...
...
@@ -20,26 +25,24 @@ elif HOSTNAME == "Dandelion":
PATH_DARK
=
"/home/csstpipeline/L1Pipeline/msc/ref/MSC_CLD_210525202000_100000016_{:02d}_combine.fits"
PATH_FLAT
=
"/home/csstpipeline/L1Pipeline/msc/ref/MSC_CLF_210525201000_100000016_{:02d}_combine.fits"
# working directory
DIR_WORK
=
"/home/csstpipeline/L1Pipeline/msc/work"
DIR_WORK
=
"/home/csstpipeline/L1Pipeline/msc/work
/
"
# gaia catalog directory (for position calibration)
DIR_GAIA_CATALOG
=
""
DIR_GAIA_CATALOG
=
"
/home/csstpipeline/L1Pipeline/msc/gaia_dr3/
"
else
:
raise
ValueError
(
"Invalid HOSTNAME {}!"
.
format
(
HOSTNAME
))
os
.
chdir
(
DIR_WORK
)
CCD_ID_LIST
=
[
6
,
7
,
8
,
9
,
11
,
12
,
13
,
14
,
15
,
16
,
17
,
18
,
19
,
20
,
22
,
23
,
24
,
25
]
import
glob
from
csst.msc.data
import
CsstMscImgData
from
csst.msc.instrument
import
CsstMscInstrumentProc
# from astropy.io import fits
os
.
chdir
(
DIR_WORK
)
for
i_ccd
in
range
(
6
,
26
):
if
i_ccd
in
[
10
,
21
]:
continue
# i_ccd = 6
img_list
=
[]
wht_list
=
[]
flg_list
=
[]
fn_list
=
[]
for
i_ccd
in
CCD_ID_LIST
:
print
(
"processing CCD {}"
.
format
(
i_ccd
))
fp_raw
=
glob
.
glob
(
"{}/MSC_MS_*{:02}_raw.fits"
.
format
(
DIR_TEST
,
i_ccd
))
fp_raw
=
glob
.
glob
(
"{}/MSC_MS_*
_
{:02}_raw.fits"
.
format
(
DIR_TEST
,
i_ccd
))
assert
len
(
fp_raw
)
==
1
fp_raw
=
fp_raw
[
0
]
...
...
@@ -54,29 +57,46 @@ for i_ccd in range(6, 26):
instProc
.
prepare
(
n_jobs
=
2
)
img
,
wht
,
flg
=
instProc
.
run
(
raw
,
bias
,
dark
,
flat
)
instProc
.
cleanup
()
fp_img
=
img
[
0
].
header
[
"FILENAME"
]
+
'.fits'
# append img, wht, flg list
img_list
.
append
(
img
)
wht_list
.
append
(
wht
)
flg_list
.
append
(
flg
)
fn_list
.
append
(
fp_img
)
# save img, wht, flg to somewhere
img
.
writeto
(
"{}/{}.fits"
.
format
(
DIR_WORK
,
img
.
get_keyword
(
"FILENAME"
)),
overwrite
=
True
)
wht
.
writeto
(
"{}/{}.fits"
.
format
(
DIR_WORK
,
wht
.
get_keyword
(
"FILENAME"
)),
overwrite
=
True
)
flg
.
writeto
(
"{}/{}.fits"
.
format
(
DIR_WORK
,
flg
.
get_keyword
(
"FILENAME"
)),
overwrite
=
True
)
# save header
img
[
1
].
header
.
totextfile
(
"{}/{}.head"
.
format
(
DIR_WORK
,
img
.
get_keyword
(
"FILENAME"
).
replace
(
".fits"
,
""
)),
overwrite
=
True
)
img
[
1
].
header
.
tofile
(
"{}/{}.head"
.
format
(
DIR_WORK
,
img
.
get_keyword
(
"FILENAME"
).
replace
(
".fits"
,
""
)),
overwrite
=
True
)
"""
how to use CssMscImgData:
img = CsstMscImgData.read(filename)
img = CsstMscImgData.read(filename)
"""
# TODO: position calibration
from
csst.msc.astrometry
import
CsstProcMscPositionCalibration
# position calibration
pcProc
=
CsstProcMscPositionCalibration
()
pcProc
.
prepare
(
search_radius
=
2.
,)
cat
=
pcProc
.
run
(
data_list
)
pcProc
.
cleanup
()
if
img_list
:
pcProc
.
run
(
img_list
,
wht_list
,
flg_list
,
fn_list
,
DIR_GAIA_CATALOG
,
DIR_WORK
,
2.0
)
else
:
for
i_ccd
in
range
(
6
,
26
):
if
i_ccd
in
[
10
,
21
]:
continue
fp_img
=
glob
.
glob
(
"{}/MSC_MS_*_{:02}_img.fits"
.
format
(
DIR_WORK
,
i_ccd
))
fp_wht
=
glob
.
glob
(
"{}/MSC_MS_*_{:02}_wht.fits"
.
format
(
DIR_WORK
,
i_ccd
))
fp_flg
=
glob
.
glob
(
"{}/MSC_MS_*_{:02}_flg.fits"
.
format
(
DIR_WORK
,
i_ccd
))
fp_img
=
fp_img
[
0
]
fp_wht
=
fp_wht
[
0
]
fp_flg
=
fp_flg
[
0
]
img
=
CsstMscImgData
.
read
(
fp_img
)
wht
=
CsstMscImgData
.
read
(
fp_wht
)
flg
=
CsstMscImgData
.
read
(
fp_flg
)
img_list
.
append
(
img
)
wht_list
.
append
(
wht
)
flg_list
.
append
(
flg
)
fn_list
.
append
(
fp_img
)
pcProc
.
run
(
img_list
,
wht_list
,
flg_list
,
fn_list
,
DIR_GAIA_CATALOG
,
DIR_WORK
,
2.0
)
pcProc
.
cleanup
(
img_list
,
DIR_WORK
)
setup.py
View file @
c4de819d
...
...
@@ -28,9 +28,12 @@ setuptools.setup(
package_dir
=
{
'csst'
:
'csst'
},
include_package_data
=
False
,
package_data
=
{
""
:
[
"LICENSE"
,
"README.md"
],
"csst"
:
[
"msc/config/*"
,
"csst"
:
[
"msc/
astrometry_
config/*"
,
"msc/deepcr_model/*"
]},
requires
=
[
'numpy'
,
'scipy'
,
'astropy'
],
# install_requires=['sphinx>=4.2.0',
# 'numpy>=1.22.0',
# 'scipy', 'matplotlib',
# 'astropy', 'healpy', 'ccdproc', 'deepCR'],
python_requires
=
'>=3.7'
,
)
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment