%APN3_PROCEEDINGS_FORM%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% TEMPLATE.TEX -- APN3 (2003) ASP Conference Proceedings template.
%
% Derived from ADASS VIII (98) ASP Conference Proceedings template
% Updated by N. Manset for ADASS IX (99), F. Primini for ADASS 2000,
% D.Bohlender for ADASS 2001, and H. Payne for ADASS XII and LaTeX2e.
%
% Use this template to create your proceedings paper in LaTeX format
% by following the instructions given below.  Much of the input will
% be enclosed by braces (i.e., { }).  The percent sign, "%", denotes
% the start of a comment; text after it will be ignored by LaTeX.
% You might also notice in some of the examples below the use of "\ "
% after a period; this prevents LaTeX from interpreting the period as
% the end of a sentence and putting extra space after it.
%
% You should check your paper by processing it with LaTeX.  For
% details about how to run LaTeX as well as how to print out the User
% Guide, consult the README file.  You should also consult the sample
% LaTeX papers, sample1.tex and sample2.tex, for examples of including
% figures, html links, special symbols, and other advanced features.
%
% If you do not have access to the LaTeX software or a laser printer
% at your site, you can still prepare your paper following the
% instructions in the User Guide.  In such cases, the editors will
% process the file and make any necessary editorial adjustments.
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
\documentclass[11pt,twoside]{article}  % Leave intact
\usepackage{adassconf}
\usepackage{amsmath}
\usepackage{graphicx}

% If you have the old LaTeX 2.09, and not the current LaTeX2e, comment
% out the \documentclass and \usepackage lines above and uncomment
% the following:

%\documentstyle[11pt,twoside,adassconf]{article}

\begin{document}   % Leave intact

%-----------------------------------------------------------------------
%               Paper ID Code
%-----------------------------------------------------------------------
% Enter the proper paper identification code.  The ID code for your
% paper is the session number associated with your presentation as
% published in the official conference proceedings.  You can
% find this number locating your abstract in the printed proceedings
% that you received at the meeting or on-line at the conference web
% site; the ID code is the letter/number sequence proceeding the title
% of your presentation.
%
% This will not appear in your paper; however, it allows different
% papers in the proceedings to cross-reference each other.  Note that
% you should only have one \paperID, and it should not include a
% trailing period.
%
% EXAMPLE: \paperID{O4-1}
% EXAMPLE: \paperID{P7-7}
%

\paperID{P7-7}
%%%% ID=P7-7

%-----------------------------------------------------------------------
%                   Paper Title
%-----------------------------------------------------------------------
% Enter the title of the paper.
%
% EXAMPLE: \title{A Breakthrough in Astronomical Software Development}
%
% If your title is so long as to fill the page header when you print it,
% then please supply a short form as a \titlemark.
%
% EXAMPLE:
%  \title{Rapid Development for Distributed Computing, with Implications
%         for the Virtual Observatory}
%  \titlemark{Rapid Development for Distributed Computing}
%

\title{Automated Identification of Spectra in Schmidt Plates}
\titlemark{Automated Identification of Spectra in Schmidt Plates}

%-----------------------------------------------------------------------
%                 Authors of Paper
%-----------------------------------------------------------------------
% Enter the authors followed by their affiliations.  The \author and
% \affil commands may appear multiple times as necessary (see example
% below).  List each author by giving the first name or initials first
% followed by the last name.  Authors with the same affiliations
% should grouped together.
%
% EXAMPLE: \author{Raymond Plante, Doug Roberts,
%                  R.\ M.\ Crutcher\altaffilmark{1}}
%          \affil{National Center for Supercomputing Applications,
%                 University of Illinois Urbana-Champaign, Urbana, IL
%                 61801}
%          \author{Tom Troland}
%          \affil{University of Kentucky}
%
%          \altaffiltext{1}{Astronomy Department, UIUC}
%
% In this example, the first three authors, "Plante", "Roberts", and
% "Crutcher" are affiliated with "NCSA".  "Crutcher" has an alternate
% affiliation with the "Astronomy Department".  The fourth author,
% "Troland", is affiliated with "University of Kentucky"

\author{Raquel D\'iaz, J.\ Guichard, O.\ Cardona, L.\ Altamirano}
\affil{Instituto Nacional de Astrof\'isica \'Optica y
Electr\'onica}

%-----------------------------------------------------------------------
%            Contact Information
%-----------------------------------------------------------------------
% This information will not appear in the paper but will be used by
% the editors in case you need to be contacted concerning your
% submission.  Enter your name as the contact along with your email
% address.
%
% EXAMPLE:  \contact{Dennis Crabtree}
%           \email{crabtree@cfht.hawaii.edu}
%

\contact{Raquel D�az}
\email{raqueld@inaoep.mx}

%-----------------------------------------------------------------------
%             Author Index Specification
%-----------------------------------------------------------------------
% Specify how each author name should appear in the author index.  The
% \paindex{ } should be used to indicate the primary author, and the
% \aindex for all other co-authors.  You MUST use the following
% syntax:
%
% SYNTAX:  \aindex{Lastname, F. M.}
%
% where F is the first initial and M is the second initial (if
% used).  This guarantees that authors that appear in multiple papers
% will appear only once in the author index.
%
% EXAMPLE: \paindex{Crabtree, D.}
%          \aindex{Manset, N.}
%          \aindex{Veillet, C.}
%
% NOTE: this information is also used to build the author list that
% appears in the table of contents.  Authors will be listed in the order
% of the \paindex and \aindex commmands.
%

\paindex{Diaz@D\'iaz, R.} \aindex{Guichard, J.} \aindex{Cardona, O.}
\aindex{Altamirano, L.}  % Remove this line if there is only one author

%-----------------------------------------------------------------------
%             Author list for page header
%-----------------------------------------------------------------------
% Please supply a list of author last names for the page header. in
% one of these formats:
%
% EXAMPLES:
% \authormark{Lastname}
% \authormark{Lastname1 \& Lastname2}
% \authormark{Lastname1, Lastname2, ... \& LastnameN}
% \authormark{Lastname et al.}
%
% Use the "et al." form in the case of seven or more authors, or if
% the preferred form is too long to fit in the header.

\authormark{D\'iaz et al. }

%-----------------------------------------------------------------------
%           Subject Index keywords
%-----------------------------------------------------------------------
% Enter a comma separated list of up to 6 keywords describing your
% paper.  These will NOT be printed as part of your paper; however,
% they will be used to generate the subject index for the proceedings.
% There is no standard list; however, you can consult the indices
% for past proceedings (http://adass.org/adass/proceedings/).
%
% EXAMPLE:  \keywords{visualization, astronomy: radio, parallel
%                     computing, AIPS++, Galactic Center}
%
% In this example, the author noticed that "radio astronomy" appeared
% in the ADASS VII Index as "astronomy" being the major keyword and
% "radio" as the minor keyword.  The colon is used to introduce another
% level into the index.

\keywords{automated identification, plates: Schmidt}

%-----------------------------------------------------------------------
%                  Abstract
%-----------------------------------------------------------------------
% Type abstract in the space below.  Consult the User Guide and Latex
% Information file for a list of supported macros (e.g. for typesetting
% special symbols). Do not leave a blank line between \begin{abstract}
% and the start of your text.

\begin{abstract}          % Leave intact
% Place the text of your abstract here - NO BLANK LINES
We present the first results of a system for automatic analysis of
astronomical images from digitized plates. This system will
automatically identify spectral lines in low resolution spectra
employing image processing and analysis. We propose to carrying
out an identification of spectral lines with minimum human
intervention, considering factors such as type of emulsion,
objective prism, telescope characteristics, etc. Our pursuing goal
is to obtain totally automatic software for the identification of
the spectra and its lines (emission /absorption). In this work we
present the first results of the automatic segmentation and the
calculated spectra in 1-D.
\end{abstract}

%-----------------------------------------------------------------------
%                 Main Body
%-----------------------------------------------------------------------
% Place the text for the main body of the paper here.  You should use
% the \section command to label the various sections; use of
% \subsection is optional.  Significant words in section titles should
% be capitalized.  Sections and subsections will be numbered
% automatically.
%
% EXAMPLE:  \section{Introduction}
%           ...
%           \subsection{Our View of the World}
%           ...
%           \section{A New Approach}
%
% It is recommended that you look at the sample papers, sample1.tex
% and sample2.tex, for examples for formatting references, footnotes,
% figures, equations, html links, lists, and other special features.

\section{Introduction}
INAOE has a great collection of astronomical plates taken with the
Tonantzintla Schmidt Camera between 1941 to 1995, there are
altogether 15686 photographic plates of three different types,
4484 are spectral type, 8432 are direct type and 2540 are direct
of three images type (Tepanecatl, et. al. 2002). There are also
different types of emulsions (mainly the Series 103a of Kodak
Spectroscopy Plates). This work is focused in the spectral plates
only. The Tonantzintla Schmidt Camera has the following features:
Focal length 231.4 cm, Focal relation 3.2, Plate scale 95
arcsec/mm, Correcting plate 66.4 cm. Mirror 76.20 cm. The
objective prism 3.96 degrees with dispersion of 1533 \AA/mm
between $H_\beta$ and $H_\gamma$; 954 \AA/mm between $H_\gamma$
and $H_\delta$; and 626 \AA/mm between $H_\delta$ and
$H_\epsilon$ (Haro, 1956). The plates have a size of 8x8 inches
and they cover a 5x5 degree square.

Our objective is to develop an algorithm of  optimal and robust
segmentation of stellar spectra on spectral plate images with the
purpose of identifying its spectral lines in an automatic form.
People inside and outside of INAOE are interested in analyzing
this information in an automatic form. For such a task we have the
works  by Borra et. al. 1998, and Zamorano et. al. 1990 as a
basis. In figure 1 we show a flow chart with the processes
necessary to obtain our goal.

\section{Algorithm and Plate Digitization}
For plate digitization an  EPSON Expression 1680 Professional
Firewire scanner is used which is able to scan a full photographic
plate in a few minutes, it has a resolution of 1600 dpi which
correspond to a pixel size of 20 microns using the transparency
(positive) mode. The dynamic range is 8 bit (gray scale of 256
values, spanning the range 0 (dark) to 256 (white)). We get images
of 12600 x 12600 pixels with a size of about 150 MB.  Each
spectrum has approximate dimensions of 350 pixels in length and  8
pixels in width.


\begin{figure}[h]
\begin{center}
\includegraphics[width=9.0cm]{P7-7_1.eps}
\caption{Processes for the automatic identification of spectral
lines.}
\end{center}
\end{figure}

\subsection{Background Identification and Characteristic Curve}
After the digitization we have  images containing both sky,
spectra and spurious objets. The aim of this step is to rawly
identify the spectra and sky regions. We use a segmentation
process for this goal and later  extract the properties of the
resulting regions (Awcock, 1996; Lira, 2002).

The next step  is to obtain the mean sky level or background
identification from the image. This value is calculated by summing
all the pixels forming the region considered  as sky and divided
by the total number.  Taking the sky level as a constant gray
value, the program creates a new image with this value,
subtracting it from the original and creating an image without the
sky contributions but with all the spectral objects, including the
spurious ones.


To obtain the characteristic curve is a complicated task because
we do not have sensitometric spots in our photographic plates.
This implies that we cannot construct a characteristic curve
taking  as a base the densities and the noise associated with them
as is normally done. We considered an alternative way of obtaining
this curve directly from the same plate using all it properties,
because the  characteristic emulsions such as class, exposition
time and development conditions can be different among plates. In
consequence, we obtained as a result of this process a
look-up-table (lut) for each image and modified the image using
this table. We are also analyzing the idea of using stellar
spectra to construct a characteristic curve for each image
(Stienon, 1972). This technique basically involves the use of
spectra of several stars whose monochromatic magnitude differences
are known.


\subsection{Selection and Shape Analysis of the Spectra}

At this point we have a linearized image without sky
contributions, then we applied filters for contrast improvement
and image smoothing   with the purpose of emphasizing the spectra
on the plate and  eliminating the noise. After this a thresholding
segmentation is made, obtaining regions corresponding to each
spectrum. Characteristics  such as position (X,Y), area, diameter,
length of the contour, direction, ellipticity  and anisometry are
extracted. A second process of selection must be made using the
calculated characteristics to eliminate spurious objects (arrows
and/or annotations on the plate) that were not eliminated with the
previous criteria. The objects truncated by the edges of the plate
are eliminated too (Borra 1987 and 1988). Hartmann�s formula was
used in order to know the  spectra length for each type of
emulsion (Sawyer 1948).

Once the spectra that we are interest in are identified, the first
step for their extraction  in 1-D is to find their exact area and
center, with the purpose of considering only lines near to the
spectral center and avoiding lines very near the edges. We repeat
the process for the columns too. This analysis is made in the same
way that IRAF does in the routine of APALL. The average
intensities are stored in a text file which is drawn later to show
the spectra in 1-D.The graphics at this point show only values of
intensity for each point without wavelength calibration.


\section{Results}
We presented the first results of the automatic segmentation and
the calculated spectra in 1-D. The results obtained are comparable
with those in the 1-D spectra using IRAF. The selection of objects
is made with greater precision and in a shorter time than by
visual inspection. The processing time for a whole plate is about
10 min. The results are show in figures 2  and 3. The first tests
were done with plates that have a 103a-O emulsion, it has a rank
of effective sensitivity from  250 to  550 nm, and it allows us to
make an identification of lines with greater clarity in the blue
region of the electromagnetic spectrum. More information about
this is available in http://www.inaoep.mx/$\sim$raqueld/


\begin{figure}[h]
\begin{center}
\includegraphics[width=6cm]{P7-7_2.eps}
\caption{Segmentation of an image by different methods. a) Objects
selected with our method. b) Objects selected with SExtractor.
Note the automatic elimination of unwanted regions (small spectra
and observation notes). }
\end{center}
\end{figure}


\begin{figure}[h]
\begin{center}
\includegraphics[width=9cm]{P7-7_3.eps}
\caption{First results 1-D spectrums. a) Objects analyzed without
any process. b) Objects analyzed with our method. c) Section of
the digitized plate.}
\end{center}
\end{figure}

\section{Future Work}
Currently it is possible to identify the spectral lines by visual
inspection  in 1-D spectra;  we are working  in the process of
automatic identification. We plan to produce a process that
automatically identifies lines in spectra (emission /absorption).
The algorithm should be applied to plates with a different
exposition time and different  class emulsion in order to work
with all the spectral plates of  INAOE`s collection.





%-----------------------------------------------------------------------
%                 References
%-----------------------------------------------------------------------
% List your references below within the reference environment
% (i.e. between the \begin{references} and \end{references} tags).
% Each new reference should begin with a \reference command which sets
% up the proper indentation.  Observe the following order when listing
% bibliographical information for each reference:  author name(s),
% publication year, journal name, volume, and page number for
% articles.  Note that many journal names are available as macros; see
% the User Guide listing "macro-ized" journals.


%
% EXAMPLE:  \reference Hagiwara, K., \& Zeppenfeld, D.\  1986,
%                Nucl.Phys., 274, 1
%           \reference H\'enon, M.\  1961, Ann.d'Ap., 24, 369
%           \reference King, I.\ R.\  1966, \aj, 71, 276
%           \reference King, I.\ R.\  1975, in Dynamics of Stellar
%                Systems, ed.\ A.\ Hayli (Dordrecht: Reidel), 99
%           \reference Tody, D.\  1998, \adassvii, 146
%           \reference Zacharias, N.\ \& Zacharias, M.\ 2003,
%                \adassxii, \paperref{P7.6}
%
% Note the following tricks used in the example above:
%
%   o  \& is used to format an ampersand symbol (&).
%   o  \'e puts an accent agu over the letter e.  See the User Guide
%      and the sample files for details on formatting special
%      characters.
%   o  "\ " after a period prevents LaTeX from interpreting the period
%      as an end of a sentence.
%   o  \aj is a macro that expands to "Astron. J."  See the User Guide
%      for a full list of journal macros
%   o  \adassvii is a macro that expands to the full title, editor,
%      and publishing information for the ADASS VII conference
%      proceedings.  Such macros are defined for ADASS conferences I
%      through XI.
%   o  When referencing a paper in the current volume, use the
%      \adassxii and \paperref macros.  The argument to \paperref is
%      the paper ID code for the paper you are referencing.  See the
%      note in the "Paper ID Code" section above for details on how to
%      determine the paper ID code for the paper you reference.
%
\begin{references}
\reference Awcock, G.W., et al., 1996, Aplied Image Processing, ,
Ed. McGrawHill, Inc.
\reference Borra, E.F., et al., 1987, PASP, 99, 535B
\reference Borra, E.F., et al., 1988, PASP, 100, 1276
\reference Eastman Kodak Spectroscopy, 1973, P-315
\reference Haro, G. 1956,Bol.Obs. Tonantzintla Tacubaya 14, 8
\reference Lira, 2002, Introducci\'on al tratamiento digital de
im\'agenes, F.C.E. 
\reference Sawyer, R.A, 1948, Experimental Spectroscopy, Prentice -Hall, Inc, p.58
\reference Stienon, F.M., 1972, A.A.S.P.B., 5, 17
\reference Tepanecatl, S., et al., 2002, Internal Report INAOE,
No.227
 \reference Zamorano J., et al.,1990, Ap\& SS, 170, 353
\end{references}

% Do not place any material after the references section

\end{document}  % Leave intact
