# Mode Angular Degree Identification in Subgiant Stars with Convolutional
Neural Networks based on Power Spectrum

Minghao Du1, Shaolan Bi1, Xianfei Zhang1, Yaguang Li2,3,1, Tanda Li4,3 and
Ruijie Shi1
1Department of Astronomy, Beijing Normal University, Beijing 100875, China
2Sydney Institute for Astronomy (SIfA), School of Physics, University of
Sydney, NSW 2006, Australia
3Stellar Astrophysics Centre, Department of Physics and Astronomy, Aarhus
University, Ny Munkegade 120, DK-8000 Aarhus C, Denmark
4School of Physics and Astronomy, University of Birmingham, Birmingham, B15
2TT, United Kingdom
<EMAIL_ADDRESS><EMAIL_ADDRESS>
(Accepted XXX. Received YYY; in original form ZZZ)

###### Abstract

Identifying the angular degrees $l$ of oscillation modes is essential for
asteroseismology and depends on visual tagging before fitting power spectra in
a so-called peakbagging analysis. In oscillating subgiants, radial ($l=0$)
mode frequencies distributed linearly in frequency, while non-radial ($l\geq
1$) modes are p-g mixed modes that having a complex distribution in frequency,
which increased the difficulty of identifying $l$. In this study, we trained a
1D convolutional neural network to perform this task using smoothed
oscillation spectra. By training simulation data and fine-tuning the pre-
trained network, we achieved a 95 per cent accuracy on _Kepler_ data.

###### keywords:

asteroseismology – methods: data analysis – techniques: image processing –
stars: statistics

††pubyear: 2019††pagerange: Mode Angular Degree Identification in Subgiant
Stars with Convolutional Neural Networks based on Power Spectrum –Mode Angular
Degree Identification in Subgiant Stars with Convolutional Neural Networks
based on Power Spectrum

##  1 Introduction

Thanks to space missions such as _CoRoT_ (Baglin et al., 2006) and _Kepler_
(Borucki et al., 2010), a large number of precise photometric observations
have been conducted for asteroseismic studies. Asteroseismology has been
demonstrated as a powerful tool to investigate stellar interiors (e.g. Chaplin
et al., 2011; Miglio et al., 2012).

Solar-like oscillating main-sequence stars oscillate in pressure (p) modes
(Appourchaux et al., 2010). According to the asymptotic theories (Tassoul,
1980; Gough, 1986), the p-mode frequencies of same $l$ are approximately
equally spaced in frequency. The spacing, denoted by $\Delta\nu$, is the so-
called large separation. As central hydrogen exhausted, stars evolve into
subgiants and later red giants, which show non-ridial ($l\geq 1$) oscillations
of p-g mixed modes and radial oscillations ($l=0$) p modes. These mixed modes,
coupled from g modes in the core and p modes in the envelope, do not follow
regular spacings neither in frequency nor period and produce a more
complicated power spectrum (Unno et al., 1979). A common tool to identify
mixed modes is to make $\acute{e}$chelle diagrams, which slice the power
spectrum into segments of equal length and stacked them upon each other. If
the length of the segments equals to $\Delta\nu$, the p modes will align
nearly vertically. Such is not the case for the mixed modes. Fig. 1 shows
typical $\acute{e}$chelle diagrams of a main-sequence star, a subgiant and a
red-giant-branch star observed by _Kepler_. In the typical ascending red giant
branch stars and main-sequence stars, modes with same $l$-degrees have similar
abscissa. Therefore, the mode identification assigning $l$ can take advantage
of unsupervised cluster algorithms. However, modes in subgiants can not be
automatically classified with such simplicity. The Bayesian multi-model
fitting approach that models the stellar power spectral density with a mixture
of Lorentzian profiles for as many oscillation modes as one intends to fit was
widely applied to main-sequence stars and red-giant-branch stars. (e.g.
Benomar et al., 2009; Kallinger et al., 2010; Lund et al., 2017; Vrard et al.,
2018). This method calculated the Bayesian factor and has only tested a small
number of subgiants (e.g. Benomar et al., 2012). For accurate mode
identification of subgiants, visual check based on the characteristics in the
$\acute{e}$chelle diagrams (Bedding & Kjeldsen, 2010) is always necessary, but
time costly. Thus, a more efficient algorithm is needed to deal with a large
amount of data. The ensemble asteroseismology of red giants has been conducted
for Kepler observations (Huber et al., 2010; Mosser et al., 2012; Vrard et
al., 2016; Yu et al., 2018). However, the studies for subgiants and main-
sequence stars require an increase of the current sample size. With the
arrival of space missions like TESS (Ricker et al., 2010) and PLATO (Rauer et
al., 2016), more data for asteroseismic analysis would be available.

Individual frequencies are important parameters for asteroseismic analysis.
They can constrain the stellar models (Aguirre et al., 2017) to accurately
measure the fundamental stellar parameters, for example, mass, radius and age
(Chaplin et al., 2013; Silva Aguirre et al., 2015; Ge et al., 2014). The
frequencies can also reveal the interior of the stars such as rotational
profiles and convective mixing(Benomar et al., 2013, 2014).

Figure 1: Typical $\acute{e}$chelle diagrams of three stars including a main-
sequence stars KIC 6225718 (left panel, Aguirre et al., 2017), a subgiant KIC
5955122 (middle panel, Appourchaux et al., 2012) and a red-giant-branch star
KIC 9970396 (right panel, Li et al., 2017). The circles represent $l=0$ modes,
the squares $l=1$, the upward triangles $l=2$, and the downward triangles
$l=3$. The $l=1$ modes in the subgiant (KIC $5955122$) shows a more
complicated distribution than that in the main-sequence star and red-giant-
branch star.

End-to-end pipelines that extract the global oscillation parameters, mean
large separation $\Delta\nu$ and frequency of maximum power $\nu_{\rm{max}}$
have been built and well developed (e.g. Huber et al., 2009; Mosser &
Appourchaux, 2009; Hekker et al., 2010; Mathur et al., 2010; Kallinger et al.,
2010; García et al., 2014; Stello et al., 2017). In this study, we focus on
building an algorithm to automatically perform mode identifications based on
power spectra. Here, we choose a deep machine learning algorithm to due to its
high accuracy, efficiency and great capability on processing high-dimensional
data (i.e. frequency spectra). Deep learning methods have been proved useful
on astronomy studies (e.g. light curve, frequency spectrum and stellar
spectrum) including classifying evolutionary stage (Hon et al., 2017, 2018a),
detecting oscillations (Hon et al., 2018b) on frequency spectrum, determining
stellar parameters on spectroscopic spectrum (Zhang et al., 2019) and
generating the solar magnetogram (Kim et al., 2019).

In this paper, we firstly construct labelled simulated frequency spectra with
different $l$-degrees as images that contain spatial structure for deep
convolutional neural networks to extract features for training a pre-trained
model, and thereafter fine-tune the pre-trained model using half of the
_Kepler_ observed data to improve the performance of classifier. Finally, we
use the rest of the _Kepler_ observed data to test our model. We finally
provide an effective and efficient classifier that identifies the $l$-degrees
in subgiant stars.

##  2 Methods

In this section, we describe how we built the training set and the test set
for deep learning, followed by an introduction of deep convolutional neural
networks. Then, we illustrate the detail structure of our classifiers used to
assign $l$-degrees. We consider l=0,1,2 modes in this work. Note that l=3
modes are not considered because they constitute a small proportion of Kepler
data.

Ideally, applying big observed data to train the model would be the best
choice. Li et al. (2020) calculated the power spectra of subgiants with good
signal-to-noise ratios observed by _Kepler_ and identified about 1000
oscillation modes. However, the number of their sample is insufficient to
train a deep learning model. Therefore, we used simulated data to achieve a
pre-trained model and then used half part of the _Kepler_ observed data to
fine-tune the pre-trained model. The rest half part of observed data was used
to carry out the test.

###  2.1 Constructing simulated power spectra

####  2.1.1 Oscillation frequencies

We simulated oscillation mode frequencies using the p-mode asymptotic theory
(Tassoul, 1980; Gough, 1986) and a p-g mode coupling model proposed by
Deheuvels & Michel (2010, hereafter D10). We first produced $l=0,1$ and $2$ p
mode frequencies according to asymptotic relation111In subgiants, uncoupled
$l=0$ and 2 p modes are not observable. All $l\geq 1$ modes have a mixed
character. Here we refer the $l=0$ and 2 p modes as the pure pressure modes
assuming there is no coupling from the core.. Then we produced the $l=1$ p-g
mixed mode frequencies using the coupling model. Note that l=2 modes in
subgiants are also p-g mixed modes, but they have weaker coupling (Dupret et
al., 2009). Therefore we expect the frequencies of l=2 mixed modes still
roughly follow the p mode asymptotic relation.

Firstly, we constructed $l=0,1$ and $2$ p modes in nine radial orders around
$\nu_{\rm max}$. These modes follow the asymptotic relation (Mosser et al.,
2012):

$\nu_{n_{\rm p},l}=\Delta\nu(n_{\rm p}+\frac{l}{2}+\epsilon-
d_{0l}+\frac{\alpha_{\rm curv}}{2}[n_{\rm p}-n_{\rm max}]^{2})\\\ ,$ (1)

where $n_{\rm p}$ is the p-mode radial order and $l$ is the angular degree.
$\Delta\nu$ is the large separation and we here took $\Delta\nu$=30$\mu$Hz as
a fixed value for reasons that are illustrated in Section. 2.2. The small
separation $d_{0,l}$ is a function of $\Delta\nu$. The item with $\alpha_{\rm
curv}$ in the formula denotes the curvature pattern in $\acute{e}$chelle
diagram, in which the constant $\alpha_{\rm curv}$ represents the mean
curvature of the p-mode oscillation pattern. $n_{\rm max}=\nu_{\rm
max}/\Delta\nu$ and we here considered the fifth radial mode as $n_{\rm max}$.
$\epsilon$ was treated as a fixed value because it does not affect the
relative positions between modes.

The mean curvature $\alpha_{\rm curv}$ have a value of about 0.008 based on
the red giants of _Kepler_ observation (Mosser et al., 2012) and in our work,
we used the following $C_{\rm curv}$ to recreate the curvature pattern,

$C_{\rm curv}=\frac{30}{11-10(\frac{n_{\rm p}-n_{\rm max}}{10})^{2}}\mu{\rm
Hz}\\\ ,$ (2)

where $n_{\rm p}=1$ to $9$ and $n_{\rm max}=5$.

Thus, $l=0$ modes frequencies with asymptotic relation are

$\nu_{n_{\rm p},0}=n_{\rm p}+\epsilon+C_{\rm curv}\\\ .$ (3)

Then the frequencies of $l=2$ modes are calculated using $d_{02}$, which is
the mean distance between $l=0$ ridge and its parallel $l=2$ ridge.

$\nu_{n_{\rm p},2}=n_{\rm p}+1+\epsilon-d_{02}+C_{\rm curv}\\\ .$ (4)

The frequencies $l=1$ p modes conform to the relation of small separation
$d_{01}$ of $l=1$ modes from the midpoint of adjacent $l=0$ modes.

$\nu_{n_{\rm p},1}=(\nu_{n_{\rm p},0}+\nu_{n_{\rm
p}+1,0})/2+d_{01}(\nu_{n_{\rm p}+1,0}-\nu_{n_{\rm p},0})+C_{\rm curv}\\\ .$
(5)

Here, we used the result of Bedding et al. (2010) that $d_{02}=0.125$ and set
$d_{01}$ as a free parameter range from 0.01 to 0.04.

Then we produced the p-g mixed modes of $l=1$ modes. D10 extent the analogy of
p-g mixed modes proposed by Christensen-Dalsgaard (1997). By writing the
displacement of each oscillator as $y_{i}(t)=c_{i}\rm{exp}(-i\omega t)$ and
solving an eigenvalue problem $AC=\omega^{2}C$ with

$A=\begin{bmatrix}\omega_{1}^{2}&0&\dots&0&-\alpha\\\
0&\omega_{2}^{2}&0&\vdots&-\alpha\\\ \vdots&&\ddots&&\vdots\\\
0&\dots&&\omega_{n-1}^{2}&-\alpha\\\
-\alpha&\dots&\dots&-\alpha&\omega_{n}^{2}\end{bmatrix}$

, and $C=[c_{1},\dots,c_{n}]$. We can calculate the eigenfrequencies of the
system. In the matrix, $[\omega_{1},\dots,\omega_{n-1}]$ represented p modes
that we have calculate above. $\alpha$ is the so-called coupling term between
the two oscillators. $\omega_{n}$ stood for a g mode. We assumed that the
frequency of this g mode $\omega_{n}=\omega_{n-1}+c$ where $c$ is a free
parameter that have four values, which represent that a g mode close to the
previous frequency encountered with other p modes. Finally, we have 10 $l=1$
p-g mixed modes (9 p modes coupling with 1 g mode).

As stars evolve, multiple g modes can be coupled with p modes within the
observable range. Here We only used one g mode to produce frequencies for
simplicity. The total free parameters to construct the mode frequencies are
{$\alpha$, $\omega_{n}$, $d_{01}$}. In particular, $\alpha$ was adopted from
0.2 to 0.5 with a step of 0.01.

Figure 2: The $\acute{e}$chelle diagrams with different free parameters,
$\alpha$, $c$ and $d_{01}$. The three panels from left to right varies
$\alpha$, $c$ and $d_{01}$, respectively with the two other parameters fixed.
The symbols are the same as Fig 1.

Table 1 summarized the configuration of free parameters used to simulate mode
frequencies. In total, we produced $4\times 4\times 30=480$ power spectra that
represented 480 subgiants. Fig. 2 shows simulated frequencies on the
$\acute{e}$chelle diagrams with some configurations of $\alpha$, $c$ and
$d_{01}$. For a set of parameter combinations, there are 9 $l=0$ modes, 10
$l=1$ modes, and 9 $l=2$ modes, respectively, so there are 28 modes in total.
Therefore, we achieved $480\times 28=13440$ individual frequencies for a given
effective temperature $T_{\rm{eff}}$ which will introduced in Section. 2.1.2.

Table 1: Free parameters for simulating mode frequencies Parameter | Range | Step | Sample number
---|---
$\alpha$ | $0.2\sim 0.5\;|\;0.01\;|\;30$
$c$ |  $0.1\sim 0.4$ | 0.1 | 4
$d_{01}$ | $0.01\sim 0.04\;|\;0.01\;|\;4$

In addition, using the frequencies of the stellar models is also a good choice
and we have tested its performance. We chose the S4TESS catalog data (Ball et
al., 2018) and models calculated by ourselves and they have showed the similar
result. For the data of Ball et al. (2018), they calculated the frequencies
using MESA (Paxton et al., 2010) and GYRE (Townsend & Teitler, 2013). We
selected 1222 subgiant stars based on effective temperature and $\Delta\nu$
and used the oscillation parameters they calculated based on stellar model.
The result is not better than the method described above in this section. The
main possible reason is the surface effect of the stellar models that effect
the distribution of frequencies.

####  2.1.2 Power spectra

In reality, oscillation are detected at hundred $\mu$Hz to one thousand
$\mu$Hz. For subgiant stars, the range of oscillation covers about a few
hundred $\mu$Hz. From the sample of Li et al. (2020), we found a mean range of
about 600 $\mu$Hz at about $\nu_{\rm max}$=300$\mu$Hz. Thus, the parameters in
this work were scaled to fit the frequency range.

We write the power spectrum as

$P(\nu)=L(\nu)\cdot w(\nu)$ (6)

where $L(\nu)$ is a sum of Lorentzian profile that approximate the stochastic
excitation of oscillation modes for well resolved modes. And $w(\nu)$ is a
chi-square distribution with degree of freedom of two. The Lorentzian profiles
can be described with three parameters height $H$, frequency centroid
$\nu_{0}$ and line widths $\Gamma$

$L(\nu)=\frac{H}{(\frac{\nu-\nu_{0}}{\Gamma})^{2}+1}$ (7)

where frequency centroids were calculated as described in section 2.1.1.
Because we would min-max normalize the power spectrum to build the training
set, the absolute height $H$ of each mode is not essential. Therefore, we used
the relative height equation for each order. Salabert et al. (2011) measured
the relative height of solar modes. However, Benomar et al. (2013) found that
relative heights in subgiants are different from the sun. The $l=1$ relative
heights have a larger range. The $l=2$ relative heights are higher than in the
sun. We here used the measurements from Benomar et al. (2013)

$H_{l=0}:H_{l=1}:H_{l=2}\approx 1:1.6:0.65$ (8)

The heights of oscillation modes on a same power spectrum are modified by a
Gaussian profile centered at $\nu_{\rm max}$, with a width of $\sigma$ and a
height of $H_{0}$. The centroid $\nu_{\rm max}$ represents frequency of
maximum power. Therefore, the height of modes nearby $\nu_{\rm max}$ is
relatively higher than those far from $\nu_{\rm max}$. Thus, we firstly
assigned the height of $l=0$ modes based on Gaussian profile, and then
calculated the height of $l=1$ and $l=2$ modes using Equation 8.

The line widths $\Gamma$ at $\nu_{\rm max}$ are related to stellar effective
temperature $T_{\rm eff}$ (Appourchaux et al., 2012). We here used a 2
parameter relation derived using Li et al. (2020) data for a subgiant sample.

$\Gamma_{\rm{max}}=a\times(\frac{T_{\rm eff}}{5777K})^{b}$ (9)

Although the line widths $\Gamma$ vary with frequency, we here didn’t take
into account because it failed to improve the accuracy of the model. We
assigned $T_{\rm eff}$ with four values ranged from 5200K to 6400K in a step
of 400K as shown in Fig 3. The total free parameters to simulate the power
spectrum are listed in Table 2. With four effective temperature we selected,
the total number of simulated oscillation modes is $13440\times 4=53760$.

Table 2: Free parameters for simulating the power spectrum. Gaussian distribution random number $\mathcal{N}$ is applied to produce tiny difference on the basis of conform to overall relations. Parameter | Range | Step
---|---
$T_{\rm eff}$ |  $5200K\sim 6400K$ | $400K$
$H_{1}$ | $\mathcal{N}(1.6,0.1)$
$H_{2}$ | $\mathcal{N}(0.65,0.1)$
$\Gamma_{\rm{max}}:a$ | $\mathcal{N}(1.47,0.17)$
$\Gamma_{\rm{max}}:b$ | $\mathcal{N}(8.18,4.96)$
Figure 3: Simulated power spectra with four configurations of $T_{\rm eff}$,
which changes the line widths.

###  2.2 Data sets

We first smoothed the simulated power spectra and _Kepler_ spectra using a
1$\mu$Hz wide boxcar (moving average) to demonstrate features more clearly. We
found that the non-smoothed power spectrum increased the difficulty of
training the convolutional neural networks.

Then, we segmented the power spectra into 2-$\Delta\nu$-wide clips centred on
the oscillation mode as shown in Fig. 4, which compares spectral image
representations between $l=0,1$ and $2$. Each sample is a $(1000,)$ 1-D array
by linear interpolation. Since each sample is segmented into the same
2-$\Delta\nu$-wide 1D clips, we can fixed the $\Delta\nu=30\mu\rm{Hz}$ and
changed other parameters ($\alpha$, c, $d_{01}$, $\Gamma$ and height ratio) to
recreate characteristics of subgiant stars’ power spectra because
characteristic are scaled to the same wide range. The main purpose of
simplifying the model is to reduce the difficulty of training.

The training set is composed of 53760 oscillation modes produced from
simulated spectra and 500 oscillation modes from the _Kepler_ sample. We used
the former pre-trained model which can be considered as a base model upon
which can be applied for optimization observed data from _Kepler_ , $K2$ and
_TESS_. This so-called fine-tuning technique (Tajbakhsh et al., 2016) was
applied in our work because our simulated training subset can not replace real
observation data. We fine-tuning the pre-trained model and produce the final
model.

The remaining 569 individual frequencies made up the test set. For both the
training set and test set, we min-max normalized the power spectrum of each
star before segmenting due to the standard data processing in machine learning
tasks.

Generally, a validation set is necessary for training the model and searching
the most adaptive hyper-parameters. Here we simply randomly selected 10% of
the training set sample.

Figure 4: Segmented oscillation spectra for three samples. Each sample has
1000 points and covers $2$$\Delta\nu$ range. In the middle of array, the black
dash lines indicate target modes to be classified which corresponds $l=0,1,2$
from top to bottom.

###  2.3 Convolutional neural networks

Artificial neural networks are common tools for solving for solving different
kinds of problems especially for image processing and nature language
processing. The artificial neural network is a mathematical representation
inspired by biological neutron networks. Through mathematical algebra
calculation, data flow in from the input layer and output the result from the
last layer neurons. The input vector is $x=[x_{0},x_{1},\dots,x_{d}]$ which is
the data we considered, and each neuron performed the calculation:
$z=w^{T}x+b$, where $w=[w_{1},\dots,w_{d}]$ are weights and $b$ are biases,
which are coefficients iteratively updated during the model training.

The input vector is linear as described above. To solve non-linear problems,
an activation function is needed. In this study, we used the _Relu_ activation
function as a rectified linear unit, whose form is $f(x)=\max(0,x)$. This
function is proved to learn the patterns and features efficiently in image
processing tasks (Nair & Hinton, 2010).

The convolutional neural network is a kind of feedforward neural networks with
local connection, weight sharing and other characteristics which are great
advantages compared with full connection neural networks. Local receptive
field is one of the important ideas of convolutional neural networks, which is
reflected in the form of _convolution kernel_ in mathematical form and is also
called _filter_. Convolutional operation of _filter_ and previous layer
outputs the feature maps, which receives information within a small neighbored
area of the previous layer and could extract elementary visual features. The
filter slides in stride number and shares a single weight vector and a bias
vector. In general, a convolutional layer always computes more than one
feature maps with multiple filters and weight vectors. We write the output as:

$z^{({\rm lay})}=w^{({\rm lay})}\otimes a^{({\rm lay}-1)}+b^{({\rm lay})}$
(10)

where ${\rm lay}$ means the layer number and $a$ is the convolutional kernel,
whose size is a hyper-parameter.

The objective of the convolutional neural network is to learn a particular set
of weights from a training set that minimizes the error in approximating a
ground truth y with a predicted output $\hat{y}$. Our study, a three class
classification task with labels $0,1,2$. We used a normalized exponential
function known as the _softmax_ function (Liu et al., 2016) at the output
layer to decide the class:

$p(y=c|x)=\frac{e^{w_{c}^{T}x}}{\sum_{c=1}^{C}{e^{w_{c}^{T}x}}}\,$ (11)

which defines the score of class $c$ out of $c=3$ classes. The decision
function is,

$\hat{y}=\rm{argmax}\ p(y=c|x)$ (12)

The _softmax_ function plays a role of the regression model considering it as
a probability.

An error function is needed among machine learning models. For our
classification task, we adopted the _cross-entropy_ (Shore & Johnson, 1980) to
connect a true value $\hat{y}$ and a predicted value $y$,

$E(y,\hat{y})=-\frac{1}{n}[y_{i}\log\hat{y_{i}}+(1-y_{i})\log(1-\hat{y_{i}})]$
(13)

where $n$ corresponds to the sample number. In order to minimize the error
$E(y,\hat{y})$, a gradient descent algorithm was chosen. We used back-
propagation (BP) algorithm (Hecht-Nielsen, 1992) defines error pass back to
update the parameters, and other forms of artificial neural networks follow
this approach (LeCun et al., 1995). In our work, we select _Adagrad_ as the
optimizer, an adaptive gradient algorithm from the improvement of stochastic
gradient descent (SGD) algorithm (Duchi et al., 2011). This optimizer speeds
up the training and shortens the training time compared with SGD. After many
iterations, the error function become smaller due to the effect of optimizer.
Finally, the weight $w$ become stable and we obtained the classifier that
could conduct classification tasks on test set and unclassified set.

The difficulty of building a useful neural network is to find a suitable
structure and to find appropriate hyper-parameters, such as the size of
filters, the number of filters and strides, etc. The architecture we applied
is a classic convolutional neural network structure, which is similar to
_AlexNet_ that contains _convolutional_ layers, _maxpooling_ layers and
_dropout_ layers (Krizhevsky et al., 2012). Among them, _d_ ropout layers are
to prevent overfitting problems by randomly manually set a percentage output
to zero (Srivastava et al., 2014) which is a hyper-parameter. We took this
percentage value to 0.5, which showed good performance. Apart from these
layers, we used full connection layers to combine the features extracted from
the former layers together. The hyper-parameters optimization is always time
consuming. We used the grid search approach to find the most suitable hyper
parameters for our task. Fig. 5 shows our classifier architecture.

Figure 5: The construction of convolutional neural network illustrating the
property of each layer and indicating the hyper-parameters applied to layers

We constructed the convolutional neural network with the deep learning
framework Keras (Chollet et al., 2015) whose backend is Tensorflow (Abadi et
al., 2016). Using Hyperas python
module222https://github.com/maxpumperla/hyperas, we found the optimal hyper-
parameters. We used the filter size 64/16, filter number 16/16 and strides 3/1
for convolutional layers. The size of two fully-connected layers are both
1024. With a typical CPU in personal computer, predicting one thousand targets
takes within one second.

###  2.4 Fine-tuning the pre-trained network

In order to make the classifier we modelled above more adaptive to the
_Kepler_ observation data, we used half of the _Kepler_ data to re-train and
fine-tune the model. We first freeze the pattern extraction layers of two
successions convolutional layers, max-pooling layers and dropout layers. And
we just trained the fully connected layers whose role is to combine the
patterns extracted using upper layers and find the most probable
classification result. During the fine-tuning procedure, our base model
rapidly converged and improved performance on real observed _Kepler_ data,
which reflected that the simulation data has the similar characteristics of
observed data.

The fine-tuning model improved the accuracy of the base model to about 95%.

##  3 Results

###  3.1 Classifier performance

In our work, we trained two classification models. One was trained from all
simulated data, which we call the pre-trained models. The other one is a fine-
tuned model that combined the observation data with the pre-trained model. We
here first used the confusion matrix in Table 3 and Table 4 to show the
classification results of the two models separately.

Table 3: Confusion matrix of pre-trained model on the test set Actual Predicted | $l=0$ | $l=1$ | $l=2$
---|---|---|---
$l=0$ | 307 | 34 | 6
$l=1$ | 51 | 406 | 10
$l=2$ | 14 | 19 | 222
Table 4: Confusion matrix of fine-tuning the pre-trained model on the test set Actual Predicted | $l=0$ | $l=1$ | $l=2$
---|---|---|---
$l=0$ | 172 | 6 | 4
$l=1$ | 8 | 231 | 7
$l=2$ | 1 | 2 | 138

Based on the above confusion matrices, we have several indicators to evaluate
our results. Each classification result is labelled with _True Positive, False
Positive, True Negative and False Negative_ , which are commonly used in data
science area. The definitions are:

  1. 1.

True Positive (TP): The true class of a sample is $l$ and the model correctly
predicts the class $l$..

  2. 2.

False Positive (FP): The true class of a sample is other, and the model
incorrectly predicts it to be category $l$.

  3. 3.

True Negative (TN): The true class of a sample is $l$, and the model
incorrectly predicts it to be another class.

  4. 4.

False Negative (FN): The real class of a sample is other classes, and the
model is also predicted to be other classes. And we usually do not pay
attention to this indicator

We report several metrics calculated for the test set as follows:

Accuracy=$\rm{\frac{TP+TN}{TP+FP+TN+FN}}$

Precision=$\rm{\frac{TP}{TP+FP}}$

Recall=$\rm{\frac{TP}{TP+FN}}$

The accuracy shows the ratio of corrected classified sample and the total
sample. The Precision is the fraction of relevant instances among the
retrieved instances, while Recall (also known as sensitivity) is the fraction
of the total amount of relevant instances that were actually retrieved. Table
5 shows the result.

Table 5: Matrix performance on the test set Model | Pre-trained model | Fine-tuned model
---|---|---
Validation set accuracy | 98.9% | 92%
Test set accuracy | 87.5% | 95.1%
| Precision | Recall | Precision | Recall
$l=0$ | 82.5% | 88.5% | 95.0% | 94.5%
$l=1$ | 88.4% | 87.0% | 96.7% | 93.9%
$l=2$ | 93.2% | 87.1% | 92.6% | 97.9%

###  3.2 Performance analysis

The performance of the base model is not perfect on _Kepler_ data. The likely
reason is that the simulation data are a little different from observable
data. Firstly, simulation data have high signal-to-noise ratio (S/N), whereas
the S/N of _Kepler_ data covered a large range as shown in Fig. 7. However,
adding low S/N ratio samples to the training samples will greatly increase the
difficulty of training the model. The definition of S/N here is a local value
that divided the height of target mode by the median of the (1000,) array as
showed in Fig. 6. Fig 7 shows that most mis-classified samples are low S/N.
The accuracy for sample S/N<3 and S/N>3 is 81% and 90.5%, respectively.
Secondly, we took approximation during simulation. For example, in our
simulation, the relations of relative height between different $l$ degree
modes are very strong prior assumption. However, 69% low S/N false predicted
samples are the modes less than 0.8$\nu_{\rm max}$ as shown in Fig 8. These
modes are affected by the background contributed to granulation and facula and
white noise, therefore they become obscuring for machine to extract features.
The difference like this between the simulation data and observed data is
reduced by fine-tuning the pre-trained network that improves the classifier’s
performance.

Figure 6: The bottom panel shows the normalized power spectra of KIC 11771760
which is one of our test set sample. The left orange rectangular covers the
lower S/N modes and the right blue rectangular covers the higher S/N modes
that corresponds two samples in our test set. The upper two panels demonstrate
the range of this two rectangular. The horizontal grey dashed line represents
the median of the array and the vertical dashed grey line indicates the target
mode. Dividing the target mode height by the median of the sample to get the
S/N ratio. Figure 7: The S/N distribution of _Kepler_ sample tested on pre-
trained model. The inset figure shows the distribution of mis-identified
sample. The blue solid line represents the cumulative distribution function
and left violet triangle indicated the point of 60% volume that corresponds to
a region below S/N=3 Figure 8: The S/N distribution of modes vs the distance
to $\nu_{\rm max}$.

At the same time, the performance on the test set is expected to differ from
the training set because the two have different parameter distributions. The
fine-tuning model can reduce the difference between these two sets and
improved the performance on classifying low S/N modes. However, we should
still take care of the results of low S/N modes because most of the mis-
classified samples still concentrated in this area.

The fine-tuned model have a 95 per cent accuracy. $l=1$ modes have a relative
high precision 96.7% than $l=0$ and $l=2$ modes, which means that modes
predicted as $l=1$ are most credible. On the contrary, $l=2$ modes have a
higher recall compared with $l=1$ modes and the lowest precision, that is to
say, they are not easy to be predicted wrong, but other modes are easily
predicted as $l=2$. Fig. 9 and Fig. 10 show the distribution of true predicted
and false predicted samples with corresponding S/N. The $l=0,1$ mis-classified
modes focus at the lower S/N range. Only a small number of high S/N $l=1$
modes are mis-classified because they are very closed to $l=0$ modes within
1$\mu$Hz and always predicted as $l=2$ modes. The corresponding $l=0$ modes
are correctly identified. However, this leads to an increased probability that
the $l=0$ mode in other locations is identified wrong. In conclusion, the
classification of $l=0,1$ modes with good S/N of a threshold can be trusted.
And the predicted $l=2$ modes should be carefully treated. Unfortunately,
there is no way to warn of possible mistakes.

Figure 9: The S/N distributions of modes predicted as $l=0,1,2$ (from left to
right) tested using the fine-tuned model.  Figure 10: The classification
result of the fine-tuned model plotted on the scaled $\acute{e}$chelle
diagram. The symbols indicate mode in the test set, with symbol size
proportional to S/N. The filled symbols are mis-classified modes, with the red
circles showing $l=0$ modes, green squares $l=1$ and yellow triangles $l=2$.

###  3.3 Usage of models

In order to make use of future _TESS_ and _PLATO_ data and to identify the
angular degree of subgiant stars to conduct further ensemble asteroseismology,
we suggest the following procedure:

  1. 1.

Obtain the power spectra, mode frequencies and global oscillation parameters
($\Delta\nu$ and $\nu_{\rm max}$) of subgiant stars.

  2. 2.

Prepare the data as illustrated in section 2.2.

  3. 3.

Use fine-tuned model to identify the angular degree of modes.

Considering that data will be released gradually, we can use the fine-tuned
model with initially. When the data is big enough, we can also train a new
model entirely based on observation data. We estimated that three to four
thousand accurate labelled sample is enough for a reliable model according to
test we conducted on _Kepler_ data which means we need an additional
observation of about 100 subgiants.

##  4 Conclusion

We have applied a convolutional neural network to perform the identification
of subgiants’ oscillation modes. We used smoothed segmented power spectra as
samples, whose patterns are learned by the convolutional neural networks
model. Test on _Kepler_ data demonstrated a 99% cross-validation accuracy and
an 87% accuracy. By fine-tuning the model, the accuracy on test set improves
to 95%. Note that it is difficult to perform accurate classification on low
signal to noise ratio modes. With future bigger data, more accurate labelled
data are available and the model could be update or trained entirely with
observation data.

Most of samples in our test set are early type subgiant stars, therefore, the
effect of the model we trained has been tested on early-type subgiant stars.
Its performance on late type subgiant stars needs more samples to test.
Appourchaux (2020) proposed a new method to automate the identification of
mixed dipole modes for subgiant stars and their method work well on late type
subgiant stars.

The method in this work can also provide reference for the mode identification
of red giant branch stars and red clump stars. The biggest challenge for
classify the modes of red giants is rotation splitting. The current model
ignored the rotation effect to the power spectrum. However, it’s normal in red
giants. In the future, a 2D model perform on $\acute{e}$chellediagram maybe a
good choice.

## Acknowledgements

This work is supported by the Joint Research Fund in Astronomy (U2031203 and
U1631236) under cooperative agreement between the National Natural Science
Foundation of China (NSFC) and Chinese Academy of Sciences (CAS). This work
has also received funding from the European Research Council (ERC) under the
European Union’s Horizon 2020 research and innovation programme (CartographY
GA. 804752). We would also like to thank Jie, Yu and group at The Beijing
Normal University for discussions.

##  5 Data availability

Data available on request.

## References

  * Abadi et al. (2016) Abadi M., et al., 2016, in 12th $\\{$USENIX$\\}$ Symposium on Operating Systems Design and Implementation ($\\{$OSDI$\\}$ 16). pp 265–283
  * Aguirre et al. (2017) Aguirre V. S., et al., 2017, The Astrophysical Journal, 835, 173
  * Appourchaux (2020) Appourchaux T., 2020, Online Material p, 2
  * Appourchaux et al. (2010) Appourchaux T., et al., 2010, The Astronomy and Astrophysics Review, 18, 197
  * Appourchaux et al. (2012) Appourchaux T., et al., 2012, Astronomy & Astrophysics, 537, A134
  * Baglin et al. (2006) Baglin A., et al., 2006, in 36th COSPAR Scientific assembly.
  * Ball et al. (2018) Ball W. H., Chaplin W. J., Schofield M., Miglio A., Bossini D., Davies G. R., Girardi L., 2018, The Astrophysical Journal Supplement Series, 239, 34
  * Bedding & Kjeldsen (2010) Bedding T. R., Kjeldsen H., 2010, arXiv preprint arXiv:1001.5038
  * Bedding et al. (2010) Bedding T. R., et al., 2010, The Astrophysical Journal Letters, 713, L176
  * Benomar et al. (2009) Benomar O., Appourchaux T., Baudin F., 2009, Astronomy & Astrophysics, 506, 15
  * Benomar et al. (2012) Benomar O., Baudin F., Chaplin W., Elsworth Y., Appourchaux T., 2012, Monthly Notices of the Royal Astronomical Society, 420, 2178
  * Benomar et al. (2013) Benomar O., et al., 2013, The Astrophysical Journal, 767, 158
  * Benomar et al. (2014) Benomar O., et al., 2014, The Astrophysical Journal Letters, 781, L29
  * Borucki et al. (2010) Borucki W. J., et al., 2010, Science, 327, 977
  * Chaplin et al. (2011) Chaplin W. J., et al., 2011, Science, 332, 213
  * Chaplin et al. (2013) Chaplin W., et al., 2013, The Astrophysical Journal Supplement Series, 210, 1
  * Chollet et al. (2015) Chollet F., et al., 2015, Keras
  * Christensen-Dalsgaard (1997) Christensen-Dalsgaard J., 1997, Lecture Notes on Stellar Oscillations
  * Deheuvels & Michel (2010) Deheuvels S., Michel E., 2010, Astrophysics and Space Science
  * Duchi et al. (2011) Duchi J., Hazan E., Singer Y., 2011, Journal of machine learning research, 12, 2121
  * Dupret et al. (2009) Dupret M.-A., et al., 2009, Astronomy & Astrophysics, 506, 57
  * García et al. (2014) García R., et al., 2014, Astronomy & Astrophysics, 568, A10
  * Ge et al. (2014) Ge Z., Bi S., Li T., Liu K., Tian Z., Yang W., Liu Z., Yu J., 2014, Monthly Notices of the Royal Astronomical Society, 447, 680
  * Gough (1986) Gough D., 1986, in Hydrodynamic and Magnetodynamic Problems in the Sun and Stars. p. 117
  * Hecht-Nielsen (1992) Hecht-Nielsen R., 1992, in , Neural networks for perception. Elsevier, pp 65–93
  * Hekker et al. (2010) Hekker S., et al., 2010, Monthly Notices of the Royal Astronomical Society, 402, 2049
  * Hon et al. (2017) Hon M., Stello D., Yu J., 2017, Monthly Notices of the Royal Astronomical Society, 469, 4578
  * Hon et al. (2018a) Hon M., Stello D., Yu J., 2018a, Monthly Notices of the Royal Astronomical Society, 476, 3233
  * Hon et al. (2018b) Hon M., Stello D., Zinn J. C., 2018b, The Astrophysical Journal, 859, 64
  * Huber et al. (2009) Huber D., Stello D., Bedding T. R., Chaplin W. J., Arentoft T., Quirion P.-O., Kjeldsen H., 2009, arXiv preprint arXiv:0910.2764
  * Huber et al. (2010) Huber D., et al., 2010, The Astrophysical Journal, 723, 1607
  * Kallinger et al. (2010) Kallinger T., et al., 2010, Astronomy & Astrophysics, 522, A1
  * Kim et al. (2019) Kim T., et al., 2019, Nature Astronomy, 3, 397
  * Krizhevsky et al. (2012) Krizhevsky A., Sutskever I., Hinton G. E., 2012, in Advances in neural information processing systems. pp 1097–1105
  * LeCun et al. (1995) LeCun Y., Bengio Y., et al., 1995, The handbook of brain theory and neural networks, 3361, 1995
  * Li et al. (2017) Li T., Bedding T. R., Huber D., Ball W. H., Stello D., Murphy S. J., Bland-Hawthorn J., 2017, Monthly Notices of the Royal Astronomical Society, 475, 981
  * Li et al. (2020) Li Y., Bedding T. R., Li T., Bi S., Stello D., Zhou Y., White T. R., 2020, Monthly Notices of the Royal Astronomical Society, 495, 2363
  * Liu et al. (2016) Liu W., Wen Y., Yu Z., Yang M., 2016, in ICML. p. 7
  * Lund et al. (2017) Lund M. N., et al., 2017, The Astrophysical Journal, 835, 172
  * Mathur et al. (2010) Mathur S., et al., 2010, Astronomy & Astrophysics, 511, A46
  * Miglio et al. (2012) Miglio A., et al., 2012, Monthly Notices of the Royal Astronomical Society, 429, 423
  * Mosser & Appourchaux (2009) Mosser B., Appourchaux T., 2009, Astronomy & Astrophysics, 508, 877
  * Mosser et al. (2012) Mosser B., et al., 2012, Astronomy & Astrophysics, 540, A143
  * Nair & Hinton (2010) Nair V., Hinton G. E., 2010, in Proceedings of the 27th international conference on machine learning (ICML-10). pp 807–814
  * Paxton et al. (2010) Paxton B., Bildsten L., Dotter A., Herwig F., Lesaffre P., Timmes F., 2010, The Astrophysical Journal Supplement Series, 192, 3
  * Rauer et al. (2016) Rauer H., Aerts C., Cabrera J., Team P., et al., 2016, Astronomische Nachrichten, 337, 961
  * Ricker et al. (2010) Ricker G. R., et al., 2010, in Bulletin of the American Astronomical Society. p. 459
  * Salabert et al. (2011) Salabert D., Ballot J., Garcia R. A., 2011, Astronomy & Astrophysics, 528, A25
  * Shore & Johnson (1980) Shore J., Johnson R., 1980, IEEE Transactions on information theory, 26, 26
  * Silva Aguirre et al. (2015) Silva Aguirre V., et al., 2015, Monthly Notices of the Royal Astronomical Society, 452, 2127
  * Srivastava et al. (2014) Srivastava N., Hinton G., Krizhevsky A., Sutskever I., Salakhutdinov R., 2014, The journal of machine learning research, 15, 1929
  * Stello et al. (2017) Stello D., et al., 2017, The Astrophysical Journal, 835, 83
  * Tajbakhsh et al. (2016) Tajbakhsh N., Shin J. Y., Gurudu S. R., Hurst R. T., Kendall C. B., Gotway M. B., Liang J., 2016, IEEE transactions on medical imaging, 35, 1299
  * Tassoul (1980) Tassoul M., 1980, The Astrophysical Journal Supplement Series, 43, 469
  * Townsend & Teitler (2013) Townsend R., Teitler S., 2013, Monthly Notices of the Royal Astronomical Society, 435, 3406
  * Unno et al. (1979) Unno W., Osaki Y., Ando H., Shibahashi H., 1979, Tokyo, University of Tokyo Press; Forest Grove, Ore., ISBS, Inc., 1979. 330 p.
  * Vrard et al. (2016) Vrard M., Mosser B., Samadi R., 2016, Astronomy & Astrophysics, 588, A87
  * Vrard et al. (2018) Vrard M., Kallinger T., Mosser B., Barban C., Baudin F., Belkacem K., Cunha M., 2018, Astronomy & Astrophysics, 616, A94
  * Yu et al. (2018) Yu J., Huber D., Bedding T. R., Stello D., Hon M., Murphy S. J., Khanna S., 2018, The Astrophysical Journal Supplement Series, 236, 42
  * Zhang et al. (2019) Zhang X., Zhao G., Yang C., Wang Q., Zuo W., 2019, Publications of the Astronomical Society of the Pacific, 131, 094202