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
csst-pipeline
msc
sextractor
Commits
40833b3b
Commit
40833b3b
authored
Mar 07, 2023
by
Emmanuel Bertin
Browse files
Merge branch 'Pearsons' into doc
parents
1a9b70b3
f66d6f79
Changes
5
Hide whitespace changes
Inline
Side-by-side
configure.ac
View file @
40833b3b
...
...
@@ -7,7 +7,7 @@
#
# This file part of: SExtractor
#
# Copyright: (C) 2002-2023 IAP/CNRS/SorbonneU
# Copyright: (C) 2002-2023
CFHT/
IAP/CNRS/SorbonneU
#
# License: GNU General Public License
#
...
...
@@ -22,7 +22,7 @@
# You should have received a copy of the GNU General Public License
# along with SExtractor. If not, see <http://www.gnu.org/licenses/>.
#
# Last modified:
26
/0
2
/2023
# Last modified:
07
/0
3
/2023
#
#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
...
...
@@ -31,7 +31,7 @@ define([AC_CACHE_LOAD],)
define([AC_CACHE_SAVE],)
# This is your standard AstrOmatic source code...
AC_INIT([SExtractor],[2.2
7.1
],[astromatic@astromatic.iap.fr],
AC_INIT([SExtractor],[2.2
8.0
],[astromatic@astromatic.iap.fr],
[sextractor],[http://astromatic.net/software/sextractor])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_AUX_DIR(autoconf)
...
...
doc/src/conf.py
View file @
40833b3b
...
...
@@ -16,27 +16,32 @@
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
#
import
os
,
sys
sys
.
path
.
insert
(
0
,
os
.
path
.
abspath
(
'.'
))
# import os
# import sys
# sys.path.insert(0, os.path.abspath('.'))
import
sphinx_rtd_theme
import
adsarxiv
# -- General configuration ---------------------------------------------------
# -- General configuration ------------------------------------------------
# If your documentation needs a minimal Sphinx version, state it here.
#
# needs_sphinx = '1.0'
# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions
=
[
'sphinx
contrib.bibte
x'
,
'sphinx.ext.
githubpages
'
,
#
'sphinx
.ext.intersphin
x',
#
'sphinx.ext.
todo
',
'sphinx.ext.mathjax'
,
'sphinx.ext.todo'
,
'sphinxcontrib.bibtex'
,
'sphinx.ext.githubpages'
]
# Add any paths that contain templates here, relative to this directory.
templates_path
=
[
'
../theme
'
]
templates_path
=
[
'
_templates
'
]
# The suffix(es) of source filenames.
# You can specify multiple suffix as a list of string:
...
...
@@ -54,7 +59,7 @@ master_doc = 'index'
# General information about the project.
project
=
u
'SExtractor'
filename
=
'sextractor'
copyright
=
u
'2017
-2023, CFHT/IAP/CNRS/SorbonneU
'
copyright
=
u
'2017
, IAP/CNRS/UPMC
'
author
=
u
'E. Bertin'
# The version info for the project you're documenting, acts as replacement for
...
...
@@ -62,9 +67,16 @@ author = u'E. Bertin'
# built documents.
#
# The short X.Y version.
version
=
'2.2
7.1
'
version
=
'2.2
8.0
'
# The full version, including alpha/beta/rc tags.
release
=
'2.27.1'
release
=
'2.28.0'
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
#
# This is also used if you do content translation via gettext catalogs.
# Usually you set "language" from the command line for these cases.
language
=
None
# There are two options for replacing |today|: either, you set today to some
# non-false value, then it is used:
...
...
@@ -78,7 +90,21 @@ today = 'Tue Mar 07 2023'
# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This patterns also effect to html_static_path and html_extra_path
exclude_patterns
=
[
'global.rst'
,
'keys.rst'
,
'macro.rst'
,
'roles.rst'
]
exclude_patterns
=
[
'global.rst'
,
'keys.rst'
,
'roles.rst'
]
# The reST default role (used for this markup: `text`) to use for all
# documents.
#
# default_role = None
# If true, '()' will be appended to :func: etc. cross-reference text.
#
# add_function_parentheses = True
# If true, the current module name will be prepended to all description
# unit titles (such as .. function::).
#
# add_module_names = True
# If true, sectionauthor and moduleauthor directives will be shown in the
# output. They are ignored by default.
...
...
@@ -88,17 +114,53 @@ exclude_patterns = ['global.rst','keys.rst','macro.rst','roles.rst']
# The name of the Pygments (syntax highlighting) style to use.
pygments_style
=
'sphinx'
numfig
=
True
# A list of ignored prefixes for module index sorting.
# modindex_common_prefix = []
# If true, keep warnings as "system message" paragraphs in the built documents.
# keep_warnings = False
# If true, `todo` and `todoList` produce output, else they produce nothing.
todo_include_todos
=
True
smartquotes
=
Fals
e
numfig
=
Tru
e
# -- Options for HTML output ----------------------------------------------
---
# -- Options for HTML output ----------------------------------------------
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
html_theme
=
'sphinx_rtd_theme'
# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
#
# html_theme_options = {}
# Add any paths that contain custom themes here, relative to this directory.
html_theme_path
=
[
sphinx_rtd_theme
.
get_html_theme_path
()]
# The name for this set of Sphinx documents.
# "<project> v<release> documentation" by default.
#
# html_title = u'SExtractor v2.28.0'
# A shorter title for the navigation bar. Default is the same as html_title.
#
# html_short_title = None
# The name of an image file (relative to this directory) to place at the top
# of the sidebar.
#
# html_logo = None
# The name of an image file (relative to this directory) to use as a favicon of
# the docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
# pixels large.
#
# html_favicon = None
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
...
...
@@ -106,7 +168,49 @@ html_static_path = ['../theme']
# Trick for having ReadTheDocs read custom theme changes
def
setup
(
app
):
app
.
add_css_file
(
"css/custom.css"
)
app
.
add_stylesheet
(
"css/custom.css"
)
# Add any extra paths that contain custom files (such as robots.txt or
# .htaccess) here, relative to this directory. These files are copied
# directly to the root of the documentation.
#
# html_extra_path = []
# If not None, a 'Last updated on:' timestamp is inserted at every page
# bottom, using the given strftime format.
# The empty string is equivalent to '%b %d, %Y'.
#
# html_last_updated_fmt = None
# If true, SmartyPants will be used to convert quotes and dashes to
# typographically correct entities.
#
# html_use_smartypants = True
# Custom sidebar templates, maps document names to template names.
#
# html_sidebars = {}
# Additional templates that should be rendered to pages, maps page names to
# template names.
#
# html_additional_pages = {}
# If false, no module index is generated.
#
# html_domain_indices = True
# If false, no index is generated.
#
# html_use_index = True
# If true, the index is split into individual pages for each letter.
#
# html_split_index = False
# If true, links to the reST sources are added to the pages.
#
html_show_sourcelink
=
False
# If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
#
...
...
@@ -114,9 +218,39 @@ html_show_sphinx = False
# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
#
html_show_copyright
=
True
# html_show_copyright = True
# If true, an OpenSearch description file will be output, and all pages will
# contain a <link> tag referring to it. The value of this option must be the
# base URL from which the finished HTML is served.
#
# html_use_opensearch = ''
# This is the file name suffix for HTML files (e.g. ".xhtml").
# html_file_suffix = None
# Language to be used for generating the HTML full-text search index.
# Sphinx supports the following languages:
# 'da', 'de', 'en', 'es', 'fi', 'fr', 'hu', 'it', 'ja'
# 'nl', 'no', 'pt', 'ro', 'ru', 'sv', 'tr', 'zh'
#
# html_search_language = 'en'
# -- Options for LaTeX output ------------------------------------------------
# A dictionary with options for the search language support, empty by default.
# 'ja' uses this config value.
# 'zh' user can custom change `jieba` dictionary path.
#
# html_search_options = {'type': 'default'}
# The name of a javascript file (relative to the configuration directory) that
# implements a search results scorer. If empty, the default will be used.
#
# html_search_scorer = 'scorer.js'
# Output file base name for HTML help builder.
htmlhelp_basename
=
filename
+
'doc'
# -- Options for LaTeX output ---------------------------------------------
latex_elements
=
{
# The paper size ('letterpaper' or 'a4paper').
...
...
@@ -129,10 +263,7 @@ latex_elements = {
# Additional stuff for the LaTeX preamble.
#
'preamble'
:
r
'''
\usepackage{amssymb}
\newcommand{\DUrolecredits}{\footnotesize\color{lightgray}\newline}
'''
,
'preamble'
:
'\usepackage{amssymb}'
,
# Latex figure (float) alignment
#
...
...
@@ -180,7 +311,7 @@ latex_show_urls = 'footnote'
# latex_domain_indices = True
# -- Options for manual page output ---------------------------------------
---
# -- Options for manual page output ---------------------------------------
# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
...
...
@@ -194,7 +325,7 @@ man_pages = [
# man_show_urls = False
# -- Options for Texinfo output -------------------------------------------
---
# -- Options for Texinfo output -------------------------------------------
# Grouping the document tree into Texinfo files. List of tuples
# (source start file, target name, title, author,
...
...
@@ -222,7 +353,7 @@ texinfo_documents = [
# texinfo_no_detailmenu = False
# -- Options for Epub output ----------------------------------------------
---
# -- Options for Epub output ----------------------------------------------
# Bibliographic Dublin Core info.
epub_title
=
project
...
...
@@ -306,13 +437,74 @@ epub_exclude_files = ['search.html']
#
# epub_use_index = True
# -- Extension configurations ------------------------------------------------
# -- Options for todo extension ----------------------------------------------
# If true, `todo` and `todoList` produce output, else they produce nothing.
todo_include_todos
=
True
# -- Options for pybtex ------------------------------------------------------
bibtex_bibfiles
=
[
'references.bib'
]
# Example configuration for intersphinx: refer to the Python standard library.
intersphinx_mapping
=
{
'https://docs.python.org/'
:
None
}
# -- Options for pybtex ----------------------------------------------
from
pybtex.style.formatting.unsrt
import
Style
as
UnsrtStyle
,
date
,
pages
,
toplevel
from
pybtex.style.template
import
*
# ... and anything else needed
from
pybtex.plugin
import
register_plugin
class
ADSArxivStyle
(
UnsrtStyle
):
def
format_article
(
self
,
e
):
volume_and_pages
=
first_of
[
# volume and pages, with optional issue number
optional
[
join
[
field
(
'volume'
),
optional
[
'('
,
field
(
'number'
),
')'
],
':'
,
pages
],
],
# pages only
words
[
'pages'
,
pages
],
]
myurl
=
first_of
[
optional_field
(
'adsurl'
),
join
[
'http://arxiv.org/abs/'
,
optional_field
(
'eprint'
)],
optional_field
(
'url'
),
optional
[
join
[
'http://dx.doi.org/'
,
field
(
'doi'
)]]
]
template
=
toplevel
[
self
.
format_names
(
'author'
),
href
[
myurl
,
self
.
format_title
(
e
,
'title'
)]
\
if
len
(
myurl
.
format_data
(
e
))
>
0
\
else
tag
(
'strong'
)
[
self
.
format_title
(
e
,
'title'
)],
sentence
(
capfirst
=
False
)
[
tag
(
'emph'
)
[
field
(
'journal'
)],
optional
[
volume_and_pages
],
field
(
'year'
)],
sentence
(
capfirst
=
False
)
[
optional_field
(
'note'
)
],
]
return
template
.
format_data
(
e
)
def
format_inproceedings
(
self
,
e
):
myurl
=
first_of
[
optional_field
(
'adsurl'
),
optional
[
join
[
'http://arxiv.org/abs/'
,
field
(
'eprint'
)]],
optional_field
(
'url'
),
optional
[
join
[
'http://dx.doi.org/'
,
field
(
'doi'
)]]
]
template
=
toplevel
[
sentence
[
self
.
format_names
(
'author'
)],
href
[
myurl
,
self
.
format_title
(
e
,
'title'
)]
\
if
len
(
myurl
.
format_data
(
e
))
>
0
\
else
tag
(
'strong'
)
[
self
.
format_title
(
e
,
'title'
)],
words
[
'In'
,
sentence
(
capfirst
=
False
)
[
optional
[
self
.
format_editor
(
e
,
as_sentence
=
False
)
],
self
.
format_btitle
(
e
,
'booktitle'
,
as_sentence
=
False
),
self
.
format_volume_and_series
(
e
,
as_sentence
=
False
),
optional
[
pages
],
],
self
.
format_address_organization_publisher_date
(
e
),
],
sentence
(
capfirst
=
False
)
[
optional_field
(
'note'
)
],
]
return
template
.
format_data
(
e
)
register_plugin
(
'pybtex.style.formatting'
,
'adsarxiv'
,
ADSArxivStyle
)
src/back.c
View file @
40833b3b
...
...
@@ -673,7 +673,7 @@ float backguess(backstruct *bkg, float *mean, float *sigma)
{
LONG
*
histo
,
*
hilow
,
*
hihigh
,
*
histot
;
unsigned
long
lowsum
,
highsum
,
sum
;
double
ftemp
,
mea
,
sig
,
sig1
,
med
,
dpix
;
double
ftemp
,
mea
,
meafac
,
sig
,
sig1
,
med
,
medfac
,
dpix
;
int
i
,
n
,
lcut
,
hcut
,
nlevelsm1
,
pix
;
/* Leave here if the mesh is already classified as `bad' */
...
...
@@ -689,6 +689,8 @@ float backguess(backstruct *bkg, float *mean, float *sigma)
sig
=
10
.
0
*
nlevelsm1
;
sig1
=
1
.
0
;
medfac
=
prefs
.
back_pearsons
;
meafac
=
prefs
.
back_pearsons
-
1
.
0
;
mea
=
med
=
bkg
->
mean
;
for
(
n
=
100
;
n
--
&&
(
sig
>=
0
.
1
)
&&
(
fabs
(
sig
/
sig1
-
1
.
0
)
>
EPS
);)
{
...
...
@@ -725,7 +727,7 @@ float backguess(backstruct *bkg, float *mean, float *sigma)
*
mean
=
fabs
(
sig
)
>
0
.
0
?
(
fabs
(
bkg
->
sigma
/
(
sig
*
bkg
->
qscale
)
-
1
)
<
0
.
0
?
bkg
->
qzero
+
mea
*
bkg
->
qscale
:
(
fabs
((
mea
-
med
)
/
sig
)
<
0
.
3
?
bkg
->
qzero
+
(
2
.
5
*
med
-
1
.
5
*
mea
)
*
bkg
->
qscale
bkg
->
qzero
+
(
medfac
*
med
-
meafac
*
mea
)
*
bkg
->
qscale
:
bkg
->
qzero
+
med
*
bkg
->
qscale
))
:
bkg
->
qzero
+
mea
*
bkg
->
qscale
;
...
...
src/preflist.h
View file @
40833b3b
...
...
@@ -22,7 +22,7 @@
* You should have received a copy of the GNU General Public License
* along with SExtractor. If not, see <http://www.gnu.org/licenses/>.
*
* Last modified:
15/07/2020
* Last modified:
07/03/2023
*
*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
...
...
@@ -61,6 +61,7 @@
{
"BACK_FILTERSIZE"
,
P_INTLIST
,
prefs
.
backfsize
,
1
,
11
,
0
.
0
,
0
.
0
,
{
""
},
1
,
2
,
&
prefs
.
nbackfsize
},
{
"BACK_FILTTHRESH"
,
P_FLOAT
,
&
prefs
.
backfthresh
,
0
,
0
,
0
.
0
,
BIG
},
{
"BACK_PEARSONS"
,
P_FLOAT
,
&
prefs
.
back_pearsons
,
0
,
0
,
1
.
0
,
BIG
},
{
"BACKPHOTO_THICK"
,
P_INT
,
&
prefs
.
pback_size
,
1
,
256
},
{
"BACKPHOTO_TYPE"
,
P_KEY
,
&
prefs
.
pback_type
,
0
,
0
,
0
.
0
,
0
.
0
,
{
"GLOBAL"
,
"LOCAL"
,
""
}},
...
...
@@ -261,6 +262,9 @@ char *default_prefs[] =
" "
,
"*BACK_TYPE AUTO # AUTO or MANUAL"
,
"*BACK_VALUE 0.0 # Default background value in MANUAL mode"
,
"*BACK_PEARSONS 2.5 # Pearson's factor P >= 1 with"
,
"* # (mean - mode) ~ P * (mean - median)"
,
"* # Legacy value is 2.5, but 3.5 is more accurate"
,
"BACK_SIZE 64 # Background mesh: <size> or <width>,<height>"
,
"BACK_FILTERSIZE 3 # Background filter: <size> or <width>,<height>"
,
" "
,
...
...
src/prefs.h
View file @
40833b3b
...
...
@@ -7,7 +7,7 @@
*
* This file part of: SExtractor
*
* Copyright: (C) 1993-202
0
IAP/CNRS/SorbonneU
* Copyright: (C) 1993-202
3
IAP/CNRS/SorbonneU
*
* License: GNU General Public License
*
...
...
@@ -22,7 +22,7 @@
* You should have received a copy of the GNU General Public License
* along with SExtractor. If not, see <http://www.gnu.org/licenses/>.
*
* Last modified:
15/07/2020
* Last modified:
07/03/2023
*
*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
...
...
@@ -136,6 +136,7 @@ typedef struct
int
backfsize
[
2
];
/* bkgnd filt. size */
int
nbackfsize
;
/* nb of params */
double
backfthresh
;
/* bkgnd fil. thresh */
double
back_pearsons
;
/* Pearson's factor */
enum
{
GLOBAL
,
LOCAL
}
pback_type
;
/* phot. bkgnd type */
int
pback_size
;
/* rect. ann. width */
/*----- memory */
...
...
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