# Dihedral angle prediction using generative adversarial networks

Hyeongki Kim

## Abstract

Several dihedral angles prediction methods were developed for protein
structure prediction and their other applications. However, distribution of
predicted angles would not be similar to that of real angles. To address this
we employed generative adversarial networks (GAN) which showed promising
results in image generation tasks. Generative adversarial networks are
composed of two adversarially trained networks: a discriminator and a
generator. A discriminator is trained to distinguish between samples from a
dataset and generated samples while a generator is trained to generate
realistic samples.

Although the discriminator of GANs is trained to estimate density, the
explicit density of the model is not tractable. On the other hand, noise-
contrastive estimation (NCE) was introduced to estimate a normalization
constant of an unnormalized statistical model and thus the density function.

In this thesis, we introduce noise-contrastive estimation generative
adversarial networks (NCE-GAN) which enables explicit density estimation of
the generative adversarial networks by feeding noise samples from a known
distribution, like noise-contrastive estimation, and adding a corresponding
class for the discriminator. We analyzed the minibatch discrimination and new
loss for the generator is proposed. We also propose residue-wise variants of
auxiliary classifier GAN (AC-GAN) and Semi-supervised GAN to handle sequence
information in a window.

In our experiment, the conditional generative adversarial network (C-GAN), AC-
GAN and Semi-supervised GAN were compared. And experiments done with improved
conditions were invested.

We identified a phenomenon of AC-GAN that distribution of its predicted angles
is composed of unusual clusters. The distribution of the predicted angles of
Semi-supervised GAN was most similar to the Ramachandran plot. We found that
adding the output of the NCE as an additional input of the discriminator is
helpful to stabilize the training of the GANs and to capture the detailed
structures. However, using the newly proposed loss in the generator were only
helpful in C-GAN and AC-GAN. Adding regression loss to the object of the
generator and using predicted angles by regression loss only model as an
additional input of the generator could improve the conditional generation
performance of the C-GAN and AC-GAN.

###### Table of contents

  1. Abstract
  2. I Introduction
    1. I.1 Protein structure
      1. I.1.1 Protein and amino acids
      2. I.1.2 Protein structure
    2. I.2 Deep learning
      1. I.2.1 Artificial neural network
    3. I.3 Deep learning for protein structure prediction
      1. I.3.1 Secondary structure prediction methods
      2. I.3.2 Dihedral angle prediction methods
      3. I.3.3 Other structure prediction methods
    4. I.4 Generative adversarial networks
      1. I.4.1 Introduction
      2. I.4.2 Problems and suggested solutions for training of generative adversarial networks
      3. I.4.3 Metrics for generative adversarial networks
      4. I.4.4 Conditional generative adversarial networks (C-GAN)
      5. I.4.5 Auxiliary classifier generative adversarial networks (AC-GAN)
      6. I.4.6 Semi-supervised generative adversarial networks (Semi-supervised GAN)
    5. I.5 Noise-contrastive estimation
  3. II Materials and methods
    1. II.1 Dataset
    2. II.2 Utilized models in the experiments
    3. II.3 Architecture of neural networks
    4. II.4 Comparison of conditional generative adversarial netowrk methods and suggested improvements
    5. II.5 Estimating density of GAN models by combing with NCE
    6. II.6 Analysis on minibatch discrimination
    7. II.7 Residue-wise variants of AC-GAN and Semi-supervised GAN
    8. II.8 Evaluation
  4. III Results
    1. III.1 Comparison of various GAN methods for dihedral angle prediction
      1. III.1.1 Without regression loss
      2. III.1.2 Without regression loss and using predicted density by NCE
      3. III.1.3 Without regression loss, using predicted density by NCE and minibatch-wise loss in generators
      4. III.1.4 With regression loss, using predicted density by NCE and minibatch-wise loss in generators
      5. III.1.5 With regression loss, using predicted density by NCE, minibatch-wise loss in generators and predicted angles by regression model
  5. IV Discussion
  6. Appendices
    1. A.1 Generating samples using NCE-GAN when target distribution is given
    2. A.2 Experiment of minibatch discrimination for density estimation

##  Chapter I Introduction

###  I.1 Protein structure

####  I.1.1 Protein and amino acids

Protein is one of the macromolecules that have a diverse role in living
organisms.

An amino acid, which is a building block (also called monomer) of a protein,
contains an asymmetric carbon atom called the alpha carbon at the center of
its structure (see figure I.1 left). It has four different partners: an amino
group, a carboxyl group, a hydrogen atom, and a variable R group. The R group
is also called the side chain of the amino acid [1].

The side chain of an amino acid determines characteristics of that amino acid
(see figure I.2). One group of amino acids have non-polar side chains and they
are hydrophobic. Another group of amino acids have polar side chains and they
are hydrophilic. Acidic amino acids have generally negatively charged side
chains. Basic amino acids have generally positively charged side chains.
Acidic and basic amino acids are also hydrophilic because they contain
electronically charged side chains [1].

Covalently bonded chains (also called polymer) of many amino acids are called
polypeptide. The covalent bond between amino acids is called a peptide bond
(see figure I.1 right). The peptide bond is formed when an amino group of a
amino acid and a carboxyl group of another amino acid bind together through
dehydration reaction [1].

Figure I.1: Left: Structure of an amino acid from [2], right: formation of a
peptide bond modified from [2].  Figure I.2: Table of 20 common amino acids
from [3]. Aliphatic and aromatic amino acids are hydrophoic.

####  I.1.2 Protein structure

Protein structure can be explained by four level hierarchical structure:
primary structure, secondary structure, tertiary structure, and quaternary
structure [1]. (see figure I.3)

Figure I.3: 4 level hierarchical structure of a protein from [2]. Hemoglobin
is shown in this example.

The primary structure indicates the amino acids sequence of a protein. The
sequence of a protein is determined by genetic information. DNA information is
turned into messenger RNA (mRNA) by transcription process. Polypeptide chain
is synthesized by ribosome using mRNA as a template. This process is called
translation [1].

Weak hydrogen bonds between closely positioned polypeptide backbone form
certain patterns. These patterns are called secondary structure. There are 3
broad groups of these shapes: $\alpha$-helix, $\beta$-pleated sheet and loops
[1].

The overall shape of a polypeptide is referred to as its tertiary structure.
Tertiary structure is formed by interaction between side chains in the
polypeptide. These interactions include hydrophobic interaction, van der Waals
interactions, ionic bonds between polar amino acids and disulfide bridge [1].

Often more than one polypeptide subunit aggregated together to form one
protein. The quaternary structure indicates protein structure that is consist
of multiple polypeptides [1].

X-ray crystallography and nuclear magnetic resonance (NMR) are the mainly used
experimental determination methods for protein structure. Determined
structures of proteins can be accessible via Protein Data Bank (PDB) [4] which
is an archive of biological macromolecular structural data.

Dihedral angles, or often called torsion angles, are defined by three
consecutive bonds among four atoms. The backbone structure of a protein
ignores the side chains of the protein and it is determined by three dihedral
angles: $\phi$, $\psi$ and $\omega$. $\phi$ is determined by the atoms $C-N-
C_{alpha}-C$ and $\psi$ is determined by the atoms $N-C_{alpha}-C-N$.
Likewise, $\omega$ is determined by the atoms $C_{alpha}-C-N-C_{alpha}$.
$\omega$ angle is approximately planar (either 0∘ or 180∘) because of its
partial double bond character. As trans-configuration of two side chains are
favored, most $\omega$ angles are close to 180∘ [5].

Ramachandran et al [6, 7] provided analysis on favored and disallowed regions
of $\phi$, $\psi$ angles based on steric constraints and concluded that almost
3/4 of the space is unavailable for dihedral angles [5]. Figure I.4 shows
$\phi$, $\psi$ angles of the test set II.1 used in the experiments.

Figure I.4: Ramachandran plot of the test set II.1 used in the experiments.
Allowed regions of $\phi$, $\psi$ angles are labeled.
$\beta_{S}$: extended conformation of residues in $\beta$-sheets [8],
$\beta_{P}$: polyproline II conformation region [8],
$\zeta$: the region near (-2.3,1.4) = (${-130}^{\circ}$, ${80}^{\circ}$) that
is preferentially populated in pre-Proline [9, 8, 10],
$\gamma$: $\gamma$-turn conformation [9], $\gamma^{\prime}$: mirror image
region of $\gamma$ region [9],
$\alpha$: right-handed $\alpha$ helical region, $\alpha_{L}$: left-handed
$\alpha$ helical region, $\beta_{PR}$: reflection of $\beta_{P}$ region [8].

###  I.2 Deep learning

####  I.2.1 Artificial neural network

A neuron is a biological information processing unit of a brain. It receives
signals from other neurons through its dendrites and electronic signals can be
sent along the axon. If collected signals are higher than a certain threshold,
the neuron can fire signals and neurotransmitter will send the information to
other neurons through the synapse [11].

Artificial neuron is a mathematical information processing unit that is
inspired by biological neuron. It gets input (column) vector $x$ and this
information is collected by multiplying with some weight matrix $W$ and adding
some bias vector $b$. Bias term can also be integrated into weight by setting
$\tilde{W}=[b\quad W]$ and $\tilde{x}=\left[\begin{matrix}1\\\
x\end{matrix}\right]$. Activation function $f$ is then applied to the
collected information $Wx+b$ and the output of the neuron will be $f(Wx+b)$.
Most of the time, nonlinear function is used for activation function [12]. In
the case of the perceptron, activation function is the Heaviside step
function.

Figure I.5: Left: A cartoon drawing of a biological neuron, right:
corresponding mathematical model. Images from [11].

A multilayer perceptron (MLP) is a feedforward neural network which contains
at least one hidden layer. Feedforward neural network indicates a neural
network which has no loop. MLP can be used to optimize classifier or
regression problem. Backpropagation is used for training of the MLP.

Figure I.6: architecture of a multilayer perceptron network

Backpropagation method repeats forward pass and backward pass to optimize the
objective function.

Forward pass: Input signals and current parameters (weights and biases) are
used to output the prediction. Thereafter, loss (object) function is
calculated using the outputs and the corresponding labels (label of the
autoencoder network is the input itself).
Backward pass: Updates parameters to minimize the loss function in reverse
order. Variants of gradient descent algorithm such as resilient
backpropagation (RProp) [13] or adaptive moments (Adam) algorithm [14] can be
used for this process [12].

Since derivative of activation function is multiplied several times as the
network has more layers, vanishing gradient problem happens when the
multilayer perceptron is too deep.

Commonly used traditional activation functions in deep learning include
sigmoid function $\frac{1}{(1+e^{-x})}$ and hyperbolic tangent
$\tanh(x)=\frac{2}{(1+e^{-2x})}-1$ (sometimes called bipolar sigmoid).

Rectified linear unit (ReLU) which can be formulated as:

$\displaystyle f(x)=\begin{cases}x\text{ if }x\geq 0\\\ 0\text{
otherwise}\end{cases}$ (I.1)

is non-saturated activation function [15]. Using non-saturated activation
function is advantageous as it helps to prevent vanishing gradient problem,
and hence it enables to avoid networks converge to a bad local minimum [16].
However, using ReLU could lead to lack of activation in some neurons because
their gradient update will always be zero [16]. To alleviate this problem
leaky rectified linear unit (LReLU) was suggested with the following formula
for a fixed $a\in(1,\infty)$ [16].

$\displaystyle f(x)=\begin{cases}x\text{ if }x\geq 0\\\ \frac{x}{a}\text{
otherwise}\end{cases}$ (I.2)

Empirical comparison of rectified linear units showed that LReLU outperforms
ReLU when $a=5.5$ [17].

One problem of rectified linear units is that they are not bounded and
sometimes we require boundedness to solve some regression tasks. We explain
another activation function called softsign which can be formulated as [18]:

$\displaystyle f(x)=\frac{x}{1+|x|}$ (I.3)

Derivative of softsign activation function approaches zero more slowly than
tanh function [18] and experimental results show that softsign function become
less saturated than sigmoid and hyperbolic tangent [19].

###  I.3 Deep learning for protein structure prediction

Protein sequence information can be relatively cheaply obtained through
automated procedures, but the determination of protein structure is labor-
intensive and costly [20]. Thus, computational prediction of protein three-
dimensional structure for given sequence information is important.

Currently predicted one-dimensional structural properties can be classified
into two subclasses: Local structural properties mean structural features that
only depend on locally connected residues. Examples of this category are
secondary structure and backbone torsion angles. Global structural properties
could also depend on structural neighbors that are not necessarily their
neighbors in term of their sequence positions. Global structural properties
include solvent exposure properties like solvent accessible surface area
(ASA), residue coordination (contact) number, residue contact order, and
residue depth [21].

####  I.3.1 Secondary structure prediction methods

First generation secondary structure prediction methods utilized statistical
propensities of amino acid. Second generation methods used the sliding window
to take into account their neighboring residues. The third generation
techniques used evolutionary information derived from multiple sequence
alignment [22, 23].

####  I.3.2 Dihedral angle prediction methods

Because of bond distances between neighboring $C_{\alpha}$ atoms are almost
fixed and $\omega$ angle is almost fixed, torsion angles $\phi$, $\psi$ can
represent the backbone structure of a protein [24, 5].

DESTRUCT is the first publication that predicted real value dihedral angles.
It reported Pearson’s correlation coefficient (PCC) of $\psi$ angle. Both
three-state secondary structure and $\psi$ dihedral angle were predicted using
iterative cascade-correlation neural network [5].

Real-SPINE is the first method dedicated to dihedral angle prediction [5, 25].
Position specific scoring matrix (PSSM) calculated by PSI-BLAST [26], one
parameter which describes nonexistence of the amino acids near the terminus of
the chain, seven representative amino-acid properties (PP) [27] and predicted
secondary structures by SPINE [28] were used as inputs [25]. To minimize the
impact of the periodicity of the angles, their improved work applied shifting
transformation on both $\phi$, $\psi$ angles so that probabilities of the
shifted angles are close to zero around boundary angles [29].

To avoid predicting angles in the sterically forbidden regions, SPINE-X and
SPINE-XI were suggested. The idea of the SPINE-X is that as both $\phi$ and
$\psi$ have a bimodal distribution, split the prediction process into two
phase. First, each angle is classified into two states (peak I and peak II),
and then the real-value prediction is done from the peak. However, predicted
angles are too narrowly distributed. In SPINE-XI, they applied conditional
random field (CRF) model and it improved both angle distribution and
prediction accuracy [5, 30].

SPIDER predicted $\theta$ and $\tau$ angles rather than $\phi$ and $\psi$
angles [5, 31]. Such representation is possible because distance between
neighbouring $C_{\alpha}$ atoms are almost fixed ($3.8\mathring{A}$). They
also suggested another periodicity handling method that predicts sine and
cosine transformed value of angles and indirectly calculating the angles by
the following formula (I.4) [31].

$\displaystyle x=\tan^{-1}[\frac{\sin(x)}{\cos(x)}]$ (I.4)

SPIDER2, improved work of SPIDER, could improve the prediction of the
secondary structure (SS) and torsion angles ($\theta$, $\tau$, $\phi$, $\psi$)
by iteratively using predicted SS, angles and solvent accessible surface area
(ASA) results [5, 32].

Figure I.7: The general architecture of the SPIDER2 method. Image is from
[32].

Previously explained methods for angle prediction used the sliding window to
make predictions. Recently, SPIDER3 utilized bidirectional recurrent neural
networks (BRNNs) with long short-term memory (LSTM) cells to capture non-local
interactions [33]. Iterative learning is also used as the previous work [32].
Inputs of the model composed of seven physio-chemical properties (PP) [27],
PSSM from PSI-BLAST [26], and 30-dimensional hidden Markov model sequence
profiles from HHBlits [34]. Their model predicted SS, ASA, backbone angles
($\theta$, $\tau$, $\phi$, $\psi$), Half-Sphere Exposure (HSE) [35] and
Contact Number (CN).

####  I.3.3 Other structure prediction methods

Recently, RaptorX-Contact [36] ranked 1st in CASP12 contact prediction [37].
RaptorX-Contact used deep residual neural network [38] for contact prediction
by concatenating evolutionary coupling and sequence conservation information.
This method also scored high quality in contact-assisted protein folding.

###  I.4 Generative adversarial networks

####  I.4.1 Introduction

Generative adversarial network (GAN) is a framework for training a generative
model [39]. It has been successfully applied to image generation tasks like
text to image generation [40, 41, 42, 43], image-to-image translation [44]
which includes domain transfer [45, 46], image super-resolution [47], image
inpainting [48]. It has also been used to improve the semi-supervised learning
performance [49, 50, 51]. From these successful applications of GAN framework,
we investigated applying this approach in protein dihedral angle prediction.

A generative adversarial network is composed of two adversarial networks: a
generator $G$ tries to generate samples which look realistic using random
noise $z$ as input and a discriminator $D$ tries to estimate the probability
that samples are coming from the data set rather than the generative model
$G$, i.e., $p(S=real|x)$ where $S$ refers to source and $x$ refers to input
[39].

Input noise $p_{z}(z)$ is mapped to data space $G(z;\theta_{g})$ by the
generative model $G$ whose parameters are $\theta_{g}$. And the output of the
discriminator $D(x;\theta_{d})$ is the probability that $x$ is coming from the
data rather than the generator’s distribution $p_{g}$ [39].

During the training of the GAN, both $G$ and $D$ are trained simultaneously
[39].

The training process can be considered as playing a two-player minimax game
with the following objective function $V(D,G)$ [39]:

$\displaystyle\underset{G}{\min}\,\underset{D}{\max}\,V(D,G)=\mathbb{E}_{x\sim
p_{data}(x)}[\log{D(x)}]+\mathbb{E}_{z\sim p_{z}(z)}[\log{(1-D(G(z)))}]$ (I.5)

Figure I.8: Architecture of the generative adversarial network

Any differentiable function can model the networks [39].

####  I.4.2 Problems and suggested solutions for training of generative
adversarial networks

As explained in [52], the generator is not guaranteed to converge on its
optimal solution when the object function of it is non-convex.

One problem is instability occurring during the training of GANs. And another
problem is mode collapse which means the generator only generates highly
probable similar samples to fool the discriminator. Once mode collapse occurs,
the discriminator is trained to classify such a mode as coming from the
generator. However, it cannot easily distinguish samples from real data if
such a mode is actually highly probable in the data distribution [51].

Feature matching is introduced to resolve the instability of GAN training by
changing the object of the generator. The generator tries to match the
statistics of features on an intermediate layer. The expected value of the
features on an intermediate layer is used in the suggested paper, and thus the
new object for the generator is $\left\|\mathbb{E}_{x\sim
p_{data}(x)}f(x)-\mathbb{E}_{z\sim p_{z}(z)}f(G(z))\right\|$ (where $f(x)$
denotes the activation on an intermediate layer of a discriminator) [51]. On
the other hand, McGAN matches mean and covariance feature statistics [53].

Minibatch discrimination is introduced to circumvent mode collapse. Minibatch
discrimination uses a discriminator that also takes into account the
combination of samples rather than only discriminating each sample separately.
In their implementation of minibatch discrimination, the activation of an
intermediate layer of a discriminator $f(x_{i})\in\mathbb{R}^{A}$ is
multiplied by a tensor $T\in\mathbb{R}^{A\times B\times C}$ which results in a
matrix $M_{i}\in\mathbb{R}^{B\times C}$. Then the negative exponential of the
$L_{1}$ distance between the rows of the matrix across samples
$i\in\left\\{1,\dots,n\right\\}$ is computed which results
$c_{b}(x_{i},x_{j})=exp(-\left\|M_{i,b}-M_{j,b}\right\|_{L1})\in\mathbb{R}$.
The output $o(x_{i})$ of the minibatch layer for sample $x_{i}$ is then
calculated as follows [51].

$\displaystyle o(x_{i})_{b}$
$\displaystyle=\sum_{j=1}^{n}{c_{b}(x_{i},x_{j})}\in\mathbb{R}$ $\displaystyle
o(x_{i})$
$\displaystyle=\left[o(x_{i})_{1},\dots,o(x_{i})_{B}\right]\in\mathbb{R}^{B},\,o(X)\in\mathbb{R}^{n\times
B}$

Then intermediate activation $f(x_{i})$ and minibatch output $o(x_{i})$ are
concatenated to be fed to the next layer of the discriminator. The
discriminator is then outputting whether a sample cames from the data set or
from the generator like the usual GANs except it can use $o(x_{i})$ as side
information. They could generate visually appealing images by this process
[51].

####  I.4.3 Metrics for generative adversarial networks

Several evaluation measures were used for evaluation of generative adversarial
networks. We will explain some metrics that do not require human annotators.

Parzen window-based log-likelihood estimation is used to evaluate the
performance of a model since the arrival of the generative adversarial
networks [39]. The density of the data is estimated by Parzen window density
estimation using generated samples only or by also adding some training
samples, and then log-likelihood is calculated for test data. Parzen window
estimation cannot capture true log-likelihood of the model when the dimension
of the data is high even if a large data set is fed [54]. Hence, Parzen window
estimation based measure may not be the best measure for high dimensional
data.

Inception score
$exp(\mathbb{E}_{\boldsymbol{x}}KL(p(y|\boldsymbol{x})\parallel p(y)))$ is a
measure of GANs when corresponding label $y$ exists for $\boldsymbol{x}$.
Inception model [55] is trained to get the conditional label distribution
$p(y|\boldsymbol{x})$. It assumes samples that contain meaningful information
should have a conditional label distribution $p(y|\boldsymbol{x})$ with low
entropy and marginal distribution $\int{p(y|\boldsymbol{x}=G(z))dz}$ should
have high entropy as we expect good generator to generate diverse samples
[51]. Higher inception score indicates better performance of the generator.
However, as noted in [56] one can make a generator that achieves nearly
optimal Inception score by outputting adversarial examples 111Adversarial
examples are perturbated images after applying small perturbation on the input
images to change model’s prediction [57], and thus it should only be used as a
rough guide to evaluate the performance of GANs [51, 56].

Diversity of the generated images can be measured by mean multi-scale
structural similarity (MS-SSIM) [58]. MS-SSIM is a variant of single scale
structural similarity [59]. Higher MS-SSIM values mean images are perceptually
similar. Samples from classes that are high in diversity are expected to have
low mean MS-SSIM scores [58].

Generative adversarial metric (GAM) is introduced to measure the comparative
strength of GANs. Let that there are two Generative adversarial networks
$M_{1}=\left\\{(G_{1},D_{1})\right\\},\,M_{2}=\left\\{(G_{2},D_{2})\right\\}$
where $G_{1}$ and $D_{1}$ are adversarially trained and same for the $G_{2}$
and $D_{2}$. At test time, the following two ratios are calculated to compare
their strength [60].

$\displaystyle
r_{test}=\frac{\epsilon(D_{1}(x_{test}))}{\epsilon(D_{2}(x_{test}))}\text{ and
}r_{sample}=\frac{\epsilon(D_{1}(G_{2}(z)))}{\epsilon(D_{2}(G_{1}(z)))}$ (I.6)

where $\epsilon(.)$ is the classification error rate, and $x_{test}$ is the
test set. They proposed to judge the winning model considering sample ratio
$r_{sample}$ and test ratio $r_{test}$ as follows:

$\displaystyle\text{Winner}=\begin{cases}M_{1}\text{ if }r_{sample}<1\text{
and }r_{test}\simeq 1\\\ M_{2}\text{ if }r_{sample}>1\text{ and
}r_{test}\simeq 1\\\ \text{Tie otherwise}\end{cases}$ (I.7)

The reason for also using the $r_{test}$ is due to the possibility of biased
sample ratio $r_{sample}$. For example, one of the discriminators could be
overfitted on the training data [60].

####  I.4.4 Conditional generative adversarial networks (C-GAN)

Conditional generative adversarial network (C-GAN) generates samples by
putting additional information $y$ into both generator and discriminator of a
GAN [61]. $y$ could be class labels [61] or text embedding [42] or images
[44].

Training process can be considered as playing two-player minimax game with the
following objective function $V(D,G)$ [61]:

$\displaystyle\underset{G}{\min}\,\underset{D}{\max}\,V(D,G)=\mathbb{E}_{x\sim
p_{data}(x)}[\log{D(x|y)}]+\mathbb{E}_{z\sim p_{z}(z)}[\log{(1-D(G(z|y)))}]$
(I.8)

Architecture of the conditional generative adversarial network is depicted in
figure I.9(a).

####  I.4.5 Auxiliary classifier generative adversarial networks (AC-GAN)

In auxiliary classifier generative adversarial networks (AC-GAN), architecture
of the generator will be same as the C-GAN except the fact that additional
information $y$ should be a categorial class label $c$. Unlike conditional
generative adversarial network, the discriminator of AC-GAN only gets samples
and estimates both a probability distribution over sources $p(S|X)$ and a
probability distribution over the class labels $p(C|X)$ [58].

The object function is composed of two parts: the log-likelihood of the
correct source, $L_{S}$, and the log-likelihood of the correct class, $L_{C}$.
Note that $X_{fake}=G(c,z)$ [58].

$\displaystyle L_{S}=\mathbb{E}[\log p(S=real\,|\,X_{real})]+\mathbb{E}[\log
p(S=fake\,|\,X_{fake})]$ (I.9) $\displaystyle L_{C}=\mathbb{E}[\log
p(C=c\,|\,X_{real})]+\mathbb{E}[\log p(C=c\,|\,X_{fake})]$ (I.10)

The discriminator $D$ maximizes $L_{S}+L_{C}$ and the generator $G$ maximizes
$L_{C}-L_{S}$ during the training [58].

The discriminator maximize $\mathbb{E}[\log
p(S=real\,|\,X_{real})]+\mathbb{E}[\log
p(C=c\,|\,X_{real})]=\mathbb{E}[\log(p(S=real\,|\,X_{real})p(C=c\,|\,X_{real}))]$
for $X_{real}$ and $\mathbb{E}[\log p(S=fake\,|\,X_{fake})]+\mathbb{E}[\log
p(C=c\,|\,X_{fake})]=\mathbb{E}[\log(p(S=fake\,|\,X_{fake})p(C=c\,|\,X_{fake}))]$
for $X_{fake}$. This can be interpreted as the discriminator assuming
predicted classes and sources are conditionally independent on the inputs.

Architecture of the auxiliary classifier generative adversarial network is
depicted in figure I.9(b).

####  I.4.6 Semi-supervised generative adversarial networks (Semi-supervised
GAN)

We focus on the semi-supervised generative adversarial network whose
discriminator $D$ outputs $N+1$ classes when there are $N$ possible classes
for data [51, 49]. Output of the discriminator $p_{model}(c|\boldsymbol{x})$
indicates the probability that $\boldsymbol{x}$ is coming from the
corresponding class $[Class-1,\,Class-2,\,...,\,Class-N,\,Fake]$ [49].

Training loss of the discriminator is consist of two parts: the classification
loss for labeled data, $L_{supervised}$, and unsupervised loss
$L_{unsupervised}$ which is equivalent to standard GAN loss [51].

$\displaystyle L_{supervised}=-$
$\displaystyle\mathbb{E}_{\boldsymbol{x},c\sim
p_{data}(\boldsymbol{x},c)}[\log p_{model}(c|\boldsymbol{x},c<N+1)]$ (I.11)
$\displaystyle L_{unsupervised}=-$
$\displaystyle\left\\{\mathbb{E}_{\boldsymbol{x}\sim
p_{data}(x)}[\log(1-p_{model}(c=N+1|\boldsymbol{x}))]\right.$ $\displaystyle+$
$\displaystyle\left.\mathbb{E}_{z\sim p_{z}(z)}[\log
p_{model}(c=N+1|G(z))]\right\\}$ (I.12)

The discriminator $D$ minimizes $L_{supervised}+L_{unsupervised}$ and the
generator $G$ minimizes $\mathbb{E}_{z\sim p_{z}(z)}[\log
p_{model}(c=N+1|G(z))]$ during training [51].

Analysis of semi-supervised generative adversarial network showed that
theoretically we need a complement generator which generates complement
samples in the feature space to improve the performance of the classifier
[50].

When we compare the discriminators of AC-GAN with Semi-supervised GAN, we
notice that unlike the discriminator of the former model, Semi-supervised GAN
has a discriminator that is combined with the classifier. Because of this
discriminator and the classifier interact each other and as a result, they
would help to improve their counterpart [49]. From this reasoning, we
hypothesized that we might be able to improve the generating performance of
the AC-GAN by combining the classifier and the discriminator.

(a) Conditional generative adversarial network (C-GAN)

(b) Auxiliary classifier generative adversarial network (AC-GAN)

(c) Semi-supervised generative adversarial network (Semi-supervised GAN)

Figure I.9: Comparsion of generative adversarial network architectures. Dashed
lines indicate correspondence relation between data and its label. Some
samples would not have corresponding labels in the Semi-supervised GAN

###  I.5 Noise-contrastive estimation

Noise-contrastive estimation (NCE) is introduced to estimate the probability
distribution of data by estimating parameters of unnormalized models [62].

Unknown probability density function of data $p_{data}(u)$ can be modeled by a
model $p_{model}(u;\theta)$ where $\theta=\left\\{\alpha,c\right\\}$ denotes
the vector of parameters and $c$ is a negative logarithm of the normalization
parameter, i.e., $c=-\ln(\int{p_{model}(u;\alpha)du)}$ and thus
$p_{model}(u;\theta)=e^{c}\,p_{model}(u;\alpha)$ for an unnormalized model
$p_{model}(u;\alpha)$ [62].

Let’s say $X=\left\\{x_{1},\dots,x_{T}\right\\}$ is the set of the observed
data and $Y=\left\\{y_{1},\dots,y_{T}\right\\}$ is the set of the samples
drawn from the known noise distribution $p_{noise}$. Noise-contrastive
estimation optimizes the parameter vector $\theta$ to maximize the following
object function:

$\displaystyle
J_{T}(\theta)=\frac{1}{2T}\sum_{t}{\ln[h(x_{t};\theta)]+\ln[1-h(y_{t};\theta)]}$
(I.13)

where $h(u;\theta)=\frac{1}{1+exp(-G(u;\theta))}$ and $G(u;\theta)=\ln
p_{model}(u;\theta)-\ln p_{noise}(u)$ [62].

This method is similar to GAN in that it is trained to discriminate samples
from two distributions. However, the generative model itself is trained to
discriminate and NCE uses fixed noise distribution comparision while GANs use
a generator which keeps changing [39]. Another important difference is that
NCE can output the estimated density of the data as we use known noise
distribution to compare while this is not possible for the generative
adversarial networks due to lack of known distribution.

##  Chapter II Materials and methods

###  II.1 Dataset

We obtained our dataset via a similar process to that described in [31],
however the dataset is different. Proteins with less than $25\%$ sequence
similarity, high resolution ($<2.0\mathring{A}$), sequence length between 40
and 700 and R-value better (smaller) than 0.25 were retained by PISCES [63].
Biopython library [64] was used to parse sequences and DSSP [65] was used for
dihedral angle calculation. Only 20 standard amino acids were considered and
window size 17 like SPIDER2 [32] was used to get sequence fragments. 4590
protein chains and 1190 protein chains were obtained for training and test
set, respectively. 845521 fragments and 298878 fragments were obtained for
training and test set, respectively. To reduce computation time, only a
randomly selected sample of 25000 fragments were used for most of the testing
except for predicting angles for each central amino acid and calculation of
the conditional log-likelihoods.

###  II.2 Utilized models in the experiments

The regression model, which predicts $\phi$, $\psi$ angles, using only
regression loss which is shown in equation II.1 [31], was used as a baseline
model for the angle prediction.

$\displaystyle{L}_{\text{Regression}}$
$\displaystyle=\mathbb{E}[\left(\cos{({\phi}_{real})}-\cos{({\phi}_{predicted})}\right)^{2}+\left(\sin{({\phi}_{real})}-\sin{({\phi}_{predicted})}\right)^{2}$
$\displaystyle+\left(\cos{({\psi}_{real})}-\cos{({\psi}_{predicted})}\right)^{2}+\left(\sin{({\psi}_{real})}-\sin{({\psi}_{predicted})}\right)^{2}]$
(II.1)

Noise-contrastive estimation (NCE) model was used as a baseline model for
density estimation. As we don’t need to generate samples from NCE model, we
used usual deep learning classifier for density estimation. Noise samples for
density estimation were drawn from a uniform distribution.

Three generative adversarial network models; conditional generative
adversarial network (C-GAN), auxiliary classifier generative adversarial
network (AC-GAN) and semi-supervised generative adversarial network (Semi-
supervised GAN), were used in order to compare their characters and to see the
changes result from possible improvements. NCE-GANs, which will be introduced
in section II.5, were used in the generative models to track the estimated
densities. Residue-wise AC-GAN and Residue-wise Semi-supervised GAN, which
will be introduced in section II.7, were used in AC-GAN and Semi-supervised
GAN to utilize all sequence information in a window.

###  II.3 Architecture of neural networks

We used the same architectures for regression model and the generators. The
common architecture was a multi-layered perceptron composed of 3 hidden layers
and 150 neurons for each layer as the architecture of SPIDER [31]. We made
predictions using one-hot encoded sequence information as input and no input
noise was added in the generators as we are doing deterministic angle
prediction, but predicted angles were added in some of the experiments. Leaky
rectifier linear unit (LReLu) with a=5 [16] was used as activation function
except for the output activation function. Ranges for predicted $\phi$, $\psi$
angles were $(-\pi,\pi)$. $\pi$ was multiplied to fit the range after softsign
activation function was applied to the output layer. No normalization was used
for both input and output of the generators except when predicted angles by
regression model were added in some of the experiments. Scaling was applied
when predicted angles are fed into the generators. And only $\phi,\psi$ angles
in the central residue of the window were predicted for window size 17.
Shifted angle method [29] was used to handle the periodicity of angles. $\phi$
was shifted $\pi$ ($90^{\circ}$) and $\psi$ was shifted around $-1.40$
($-80.2^{\circ}$) by calculating proper shift from training data.

Like the regression model and the generators, multi-layered perceptron
composed of 3 hidden layers and 150 neurons for each layer were used in the
discriminators which also include NCE model. This implies weights of the
auxiliary classifier and the discriminators were shared for AC-GAN, and also
the weights of the classifier and the discriminator of the Semi-supervised GAN
were shared. Shifted real $\phi$, $\psi$ angles and noise samples were fed
into the noise-contrastive estimation (NCE) model. Sequence information and
scaled angle information were concatenated, and this combined information was
fed into the discriminator of the C-GAN. Only angle information was fed into
the discriminators of AC-GAN and Semi-supervised GAN except some experiments.
NCE-GAN structure, which will be described in section II.5, was used in the
discriminators of GANs for evaluation. Note that, in some of the experiments,
the output of the NCE model was also fed into GAN-discriminators. NCE model
predicts whether it got the input from the real angles or the noise samples
and it also outputs predicted sequence information like Residue-wise Semi-
supervised GAN, which will be introduced in section II.7.

We used Tensorflow library to train our models [66]. Batch size was 64 and
Adam weight optimization method [14] was used.

###  II.4 Comparison of conditional generative adversarial netowrk methods and
suggested improvements

To find a model whose Ramachandran plot of a predicted angles looks realistic,
three generative adversarial networks models (conditional GAN, AC-GAN and
Semi-supervised GAN) were implemented and the results were compared. Note that
NCE-GAN in section II.5 were used for all models to compare their
performances.

In the first experiment, to check the problems of original setting and to
compare the results with experiments done with improved condition, we did not
add regression loss in the generators and noise class ignoring method, which
will be explained in section II.5, was used for training loss of the
generators.

As can be seen in the result of the first experiment III.1.1, training of the
discriminators was not stable and estimated $p_{model}(x|real)$ of Semi-
supervised GAN did not show detailed shape of the Ramachandran plot. In the
second experiment, in an effort to stabilize the training of the
discriminator, we added predicted density estimation by NCE model as an
additional input of the discriminators. This idea is similar to [32, 42] in a
way that we are using predicted information as an additional input of the
generators. NCE model was pre-trained for 50000 iterations before training of
the generative models started. One thing to be considered when using the
predicted information as an input is that in order to prevent the generator
generating NAN values. Hence, we penalized generating angles in regions near
the prediction boundary even though we still encountered NaN values sometimes.
The other settings were same with the first experiment.

To see the effects of minibatch-wise generation, which will be explained in
section II.6, we used minibatch-wise loss in the generators of the third
experiment. Loss of C-GAN and AC-GAN generators were replaced by minibatch-
wise loss. As the discriminator and the classifier was combined in Semi-
supervised GAN, minibatch-wise loss was added to the loss of Semi-supervised
generator. The other settings were same with the second experiment.

In all of the three experiments, MSE and MAE values of the generative models
were much higher than regression model. However, reduction of MAE values are
necessary for accurate structure prediction. Hence, in the fourth experiment,
we added regression loss (II.1) in the loss of the generators in an attempt to
reduce the MSEs and MAEs. The other settings were same with the third
experiment.

To further reduce the MSE and MAE values, in the last experiment, we used
predicted results by regression model as an additional inputs of the
generative model like the idea of improving performance by stacking results
[32, 42]. Regression model was pre-trained for 50000 iterations before
training of the generative models started. The other settings were same with
the fourth experiment.

###  II.5 Estimating density of GAN models by combing with NCE

Data distribution $p_{data}$ and distribution of the generated samples $p_{G}$
are intractable in generative adversarial nets as we don’t know the density
function of either. That’s why methods like Parzen window score and Inception
score [51] are used to measure the performance of the generative adversarial
models. However, we can estimate their density function simply by adding
samples from known noise distribution and adding noise distribution class to
the discriminator. (Note that noise samples to be discriminated from real
samples and fake samples are different from noise samples which will be fed
into the generator to generate fake samples.) If an additional class is added,
the output of the discriminator will be $[real,\,fake,\,noise]$. The idea is
used with the noise-contrastive estimation [62]. We call this model as noise-
contrastive estimation generative adversarial networks or simply NCE-GAN. NCE-
GAN can also be applied to AC-GAN and Semi-supervised GAN. Architecture of the
noise-contrastive estimation generative adversarial network is depicted in
figure II.1.

The discriminator of the NCE-GAN maximizes the following:

$\displaystyle\mathbb{E}[\log p_{model}(S=real|x_{real})]+\mathbb{E}[\log
p_{model}(S=fake|x_{fake})]+\mathbb{E}[\log p_{model}(S=noise|x_{noise})]$
(II.2)

where $x_{real}$ is a sample from the data set, $x_{fake}$ is a sample
generated by the generator and $x_{noise}$ is a sample drawn from noise
distribution.

The generator is trained to maximize the $\mathbb{E}[\log
p_{model}(S=real|x_{fake})]$.

Figure II.1: Architecture of the noise-contrastive estimation generative
adversarial network. Noise samples to be discriminated $X_{noise}$ should have
same shape with the data samples $X_{real}$ while this is not necessary for
noise samples which will be fed into the generator $Z_{noise}$.

This model has some advantages over other GANs. We can generate samples when
target distribution is given without requiring another model [50] (see
appendix A.1 for details). As we can estimate both densities we can easily
measure the log-likelihood of the models and numerically estimated Kullback-
Leibler (KL) divergence between data and samples of generator distribution.
This would tell us how well the generator mimics estimated real data
distribution. And feeding fixed noise samples to the discriminator could
possibly stabilize the training of the discriminator.

However as the discriminator also distinguish samples from noise distribution,
the generator will be effected by this. For example, once mode collapse occurs
in the generator and if routes to go to other modes are surrounded by noise
samples, then it will not easy for the the generator to get out of the mode
collapse. Hence, other methods need be applied to resolve this problem. One
method involves defining the object function of the generator as if there is
no the noise class in the discriminator. Let
$[l_{real}(x),\,l_{fake}(x),\,l_{noise}(x)]$ be an output of the discriminator
before applying exponentiation and normalization (It is sometimes called a
logit of a softmax classifier.). In this case, usual object function for the
generator will be
$\mathbb{E}[\log\frac{e^{l_{real}(x_{fake})}}{e^{l_{real}(x_{fake})}+e^{l_{fake}(x_{fake})}+e^{l_{noise}(x_{fake})}}]$.
If we ignore the noise class, the object function of the generator will be
$\mathbb{E}[\log\frac{e^{l_{real}(x_{fake})}}{e^{l_{real}(x_{fake})}+e^{l_{fake}(x_{fake})}}]$.
Another way to handle this problem is generating samples by taking into
account the samples in a batch. This method is explained in section II.6.

We now describe density estimation for each $c$ when training of NCE-GAN is
finished. We think about a case where the discriminator classifies its input
into some classes whose distribution is unknown and where there is also one
noise class. The classes of unknown distributions can include classes of real
data and a class for samples generated by an adversarial generator. We explain
how can we estimate density function for a class $c$ when we know the noise
distribution $p(x|C=noise)$. $p(x|C=noise)$ should be nonzero whenever
$p(x|C=c^{\prime})$ is nonzero for all class $c^{\prime}\neq noise$ [62]. We
assume we know all prior probabilities for each class $c$, i.e., $p(C=c)$ is
known and class probabilities are represented by softmax function, i.e.,
$p_{model}(C=c|x)=\frac{\exp(l_{c}(x))}{\sum_{c^{\prime}}{\exp(l_{c^{\prime}}(x))}}$.
And we assume the discriminator can classify samples well even though the
generator was not fixed during training process. In other words,
$p_{model}(C=c|x)\approx p(C=c|x)$. We also asssume $p_{model}(C=c)\approx
p(C=c)$.

By Bayes’ theorem, $p(x|C=c)=\frac{p(C=c|x)p(x)}{p(C=c)}$ holds.

By reformulating the formula and focusing on the noise class of the model we
get:

$\displaystyle
p_{model}(x)=\frac{p_{model}(x|C=noise)p_{model}(C=noise)}{p_{model}(C=noise|x)}$
(II.3)

Note that we can estimate $p_{model}(x)$ if we substitute $p_{model}(C=noise)$
with $p(C=noise)$ and $p_{model}(C=noise|x)$ with $p(C=noise|x)$ in the right
hand side of the equation (II.3).

Then for each class $c$:

$\displaystyle p_{model}(x|C=c)=$
$\displaystyle\frac{p_{model}(C=c|x)p_{model}(x)}{p_{model}(C=c)}$ (II.4)
$\displaystyle=$
$\displaystyle\frac{p_{model}(C=c|x)p_{model}(x|C=noise)p_{model}(C=noise)}{p_{model}(C=c)p_{model}(C=noise|x)}\,(\because\text{equation
\ref{eq:model noise class}})$ (II.5) $\displaystyle=$
$\displaystyle\frac{\frac{\exp(l_{c}(x))}{\sum_{c^{\prime}}{\exp(l_{c^{\prime}}(x))}}p_{model}(x|C=noise)p_{model}(C=noise)}{p_{model}(C=c)\frac{\exp(l_{noise}(x))}{\sum_{c^{\prime}}{\exp(l_{c^{\prime}}(x))}}}\,(\because\text{softmax
representation})$ (II.6) $\displaystyle=$ $\displaystyle
p_{model}(x|C=noise)\frac{\exp(l_{c}(x))}{\exp(l_{noise}(x))}\frac{p_{model}(C=noise)}{p_{model}(C=c)}$
(II.7)

We can set $\exp(l_{noise}(x))=p(x|C=noise)$ and then we get more simplified
formula:

$\displaystyle p_{model}(x|C=c)$
$\displaystyle=\exp(l_{c}(x))\frac{p_{model}(x|C=noise)}{p(x|C=noise)}\frac{p_{model}(C=noise)}{p_{model}(C=c)}$
(II.8)
$\displaystyle\approx\exp(l_{c}(x))\frac{p_{model}(C=noise)}{p_{model}(C=c)}\,(\because
p_{model}(C=noise|x)\approx p(C=noise|x))$ (II.9)
$\displaystyle\approx\exp(l_{c}(x))\frac{p(C=noise)}{p(C=c)}\,(\because
p_{model}(C=c)\approx p(C=c))$ (II.10)

As we know all terms in the right hand side of equation (II.10), we can
estimate density function for each class $c$.

###  II.6 Analysis on minibatch discrimination

Even though suggested minibatch discrimination method enabled the generator to
successfully generate visually appealing images [51], this method will
encounter two problems when density estimation is needed.

First, although their discriminator outputs a single number for each sample
[51], the outputs of a batch will be dependent on the other samples in the
batch and thus such result can not be used for density estimation. Applying
minibatch discrimination to the noise-contrastive estimation [62] shows this
problem (see appendix A.2 for details). In terms of density estimation, adding
minibatch information into the discriminator would be a cheating behaviour. To
prevent this problem in density estimation the discriminator should not get
batch information.

Second, as the discriminator models closeness [51] it requires $O(n^{2})$
computation time and memory. And this is unwanted when evaluation of large
number of test samples is needed. The following analysis explains mini-batch
discrimination might not help the discriminator to correctly classify a
minibatch samples, and thus $O(n^{2})$ computation complexity would be
unnecessary for the discriminator. It is important to note that this doesn’t
mean mini-batch discrimination can not help the generator.

If we think about vanilla GANs [39]:

$\displaystyle p_{model}(S=real|x)$ $\displaystyle\approx p(S=real|x)$ (II.11)
$\displaystyle=\frac{p(x|real)p(S=real)}{p(x)}\,(\because\text{Bayes'
theorem})$ (II.12)
$\displaystyle=\frac{p(x|real)}{p(x|real)+p(x|fake)}\,(\because
p(S=real)=p(S=fake))$ (II.13)
$\displaystyle=\frac{1}{1+\frac{p(x|fake)}{p(x|real)}}$ (II.14)
$\displaystyle=\frac{1}{1+\exp(-\ln(\frac{p(x|real)}{p(x|fake)}))}$ (II.15)
$\displaystyle=\text{sigmoid}(\ln(\frac{p(x|S=real)}{p(x|S=fake)}))$ (II.16)

By applying logit function which is the inverse of the sigmoid function:

$\displaystyle\ln(\frac{p(x|S=real)}{p(x|S=fake)})\approx\text{logit}(p_{model}(S=real|x))$
(II.17)

If we think about samples of mini-batch $x_{1},\dots x_{n}$ which are assumed
to be satisfy i.i.d. (Independently identically distributed) condition:

$\displaystyle p_{model}(S=real|x_{1},\dots x_{n})$ $\displaystyle\approx
p(S=real|x_{1},\dots x_{n})$ (II.18)
$\displaystyle=\text{sigmoid}(\ln(\frac{p(x_{1},\dots
x_{n}|S=real)}{p(x_{1},\dots x_{n}|S=fake)}))$ (II.19) $\displaystyle($
$\displaystyle\because\text{By similar process done in equation \ref{eq:real
class Bayes's theorm}-\ref{eq:sigmoid ln}})$
$\displaystyle=\text{sigmoid}(\ln(\frac{\prod_{i=1}^{n}{p(x_{i}|S=real)}}{\prod_{i=1}^{n}{p(x_{i}|S=fake)}}))$
(II.20) $\displaystyle\,($ $\displaystyle\because\text{ i.i.d. condition})$
$\displaystyle=\text{sigmoid}(\sum_{i=1}^{n}\ln(\frac{p(x_{i}|S=real)}{p(x_{i}|S=fake)}))$
(II.21)
$\displaystyle\approx\text{sigmoid}(\sum_{i=1}^{n}\text{logit}(p_{model}(S=real|x_{i})))$
(II.22) $\displaystyle($ $\displaystyle\because\text{By equation \ref{eq:ln
logit}})$

The equation (II.22) indicates that if the discriminator learned to correctly
classify the real source of each sample, then the discriminator can also
correctly classify a mini-batch of samples. And thus, we doubt the minibatch
discrimination help the discriminator to correctly classify a minibatch
samples. However, this doesn’t necessary mean this can not help the generator
to generate realistic samples.

The success of minibatch discrimination [51] in generating visually appealing
samples could be explained by the fact their minibatch discriminator does
point-wise discrimination also using minibatch information. Their
discriminator could learn point-wise information and the corresponding
generator could get minibatch-wise feedback.

Stabilizing property of feature matching [51] can also be explained similarly.
In feature matching, the discriminator is trained by point-wise discrimination
while the generator is trained to follow statistics of the data samples which
can be considered as one form of minibatch information.

We propose a new loss of a generator which takes into account minibatch
samples.

Let $[l_{real}(x),\,l_{fake}(x)]$ be a output of the discriminator before
applying exponentiation and normalization when there are only two classes
$[real,\,fake]$.

We maximize the following formula II.23 rather than maximizing
$\mathbb{E}[\ln(p_{model}(S=real|G(z)))]$
$=\mathbb{E}[\ln(\frac{\exp(l_{real}(G(z)))}{\exp(l_{real}(G(z)))+\exp(l_{fake}(G(z)))})]$
in suggested object of a generator in [39].

$\displaystyle\ln(\frac{\exp(\mathbb{E}[l_{real}(G(z))])}{\exp(\mathbb{E}[l_{real}(G(z))])+\exp(\mathbb{E}[l_{fake}(G(z))])})$
(II.23)

We explain why maximizing II.23 in the generator make the generator to take
into account minibatch samples.

As
$p_{model}(S=s|x)=\frac{\exp(l_{s}(x))}{\exp(l_{real}(x))+\exp(l_{fake}(x))}$,
we get:

$\displaystyle\exp(l_{s}(x))=p_{model}(S=s|x)(\exp(l_{real}(x))+\exp(l_{fake}(x)))$
(II.24)

If we think about generated samples of mini-batch $G(z_{1}),\dots G(z_{n})$
which satisfy i.i.d. condition:

$\displaystyle\frac{\exp(\frac{1}{n}\sum_{i=1}^{n}(l_{real}(G(z_{i}))))}{\exp(\frac{1}{n}\sum_{i=1}^{n}(l_{real}(G(z_{i}))))+\exp(\frac{1}{n}\sum_{i=1}^{n}(l_{fake}(G(z_{i}))))}$
$\displaystyle=$
$\displaystyle\frac{\prod_{i=1}^{n}\exp(l_{real}(G(z_{i})))^{\frac{1}{n}}}{\prod_{i=1}^{n}\exp(l_{real}(G(z_{i})))^{\frac{1}{n}}+\prod_{i=1}^{n}\exp(l_{fake}(G(z_{i})))^{\frac{1}{n}}}$
(II.25) $\displaystyle=$
$\displaystyle\frac{\prod_{i=1}^{n}[p_{model}(S=real|G(z_{i}))(*)]^{\frac{1}{n}}}{\prod_{i=1}^{n}[p_{model}(S=real|G(z_{i}))(*)]^{\frac{1}{n}}+\prod_{i=1}^{n}[p_{model}(S=fake|G(z_{i}))(*)]^{\frac{1}{n}}}$
$\displaystyle(\text{where
}(*)=\exp(l_{real}(G(z_{i})))+\exp(l_{fake}(G(z_{i})))\,)$ $\displaystyle\,($
$\displaystyle\because\text{ By equation }\ref{exp logit})$ (II.26)
$\displaystyle=$
$\displaystyle\frac{\prod_{i=1}^{n}[p_{model}(S=real|G(z_{i}))]^{\frac{1}{n}}}{\prod_{i=1}^{n}[p_{model}(S=real|G(z_{i}))]^{\frac{1}{n}}+\prod_{i=1}^{n}[p_{model}(S=fake|G(z_{i}))]^{\frac{1}{n}}}$
(II.27) $\displaystyle=$
$\displaystyle\frac{\prod_{i=1}^{n}[\frac{p_{model}(G(z_{i})|real)p_{model}(S=real)}{p_{model}(G(z_{i}))}]^{\frac{1}{n}}}{\prod_{i=1}^{n}[\frac{p_{model}(G(z_{i})|real)p_{model}(S=real)}{p_{model}(G(z_{i}))}]^{\frac{1}{n}}+\prod_{i=1}^{n}[\frac{p_{model}(G(z_{i})|fake)p_{model}(S=fake)}{p_{model}(G(z_{i}))}]^{\frac{1}{n}}}$
$\displaystyle\,($ $\displaystyle\because\text{ By Bayes's theorem })$ (II.28)
$\displaystyle=$
$\displaystyle\frac{p_{model}(S=real)\prod_{i=1}^{n}[p_{model}(G(z_{i})|real)]^{\frac{1}{n}}}{p_{model}(S=real)\prod_{i=1}^{n}[p_{model}(G(z_{i})|real)]^{\frac{1}{n}}+p_{model}(S=fake)\prod_{i=1}^{n}[p_{model}(G(z_{i})|fake)]^{\frac{1}{n}}}$
(II.29) $\displaystyle=$
$\displaystyle\frac{p_{model}(S=real)(p_{model}(G(z_{1}),\dots
G(z_{n})|real)^{\frac{1}{n}})}{\begin{multlined}\left\\{p_{model}(S=real)(p_{model}(G(z_{1}),\dots
G(z_{n})|real)^{\frac{1}{n}})\right.\\\
\left.\qquad\qquad\qquad+p_{model}(S=fake)(p_{model}(G(z_{1}),\dots
G(z_{n})|fake)^{\frac{1}{n}})\right\\}\end{multlined}\left\\{p_{model}(S=real)(p_{model}(G(z_{1}),\dots
G(z_{n})|real)^{\frac{1}{n}})\right.\\\
\left.\qquad\qquad\qquad+p_{model}(S=fake)(p_{model}(G(z_{1}),\dots
G(z_{n})|fake)^{\frac{1}{n}})\right\\}}$ (II.32) $\displaystyle\,($
$\displaystyle\because\text{ i.i.d. condition})$ (II.33) $\displaystyle=$
$\displaystyle\frac{(**)}{(**)+1}\,(\text{where
}(**)=\frac{p_{model}(S=real)(p_{model}(G(z_{1}),\dots
G(z_{n})|real)^{\frac{1}{n}})}{p_{model}(S=fake)(p_{model}(G(z_{1}),\dots
G(z_{n})|fake)^{\frac{1}{n}})}\,)$ (II.34)

Maximizing II.23 is equivalent to maximizing (**) in II.34. Maximizing (**)
can be interpreted as generating samples considering minibatch samples. We
call II.23 as a minibatch-wise loss of the generator. We speculated that using
minibatch-wise loss in the generator might help the generator to improve its
performance and experiment III.1.3 was done to check this hypothesis. We used
the following loss in the experiment as we are using NCE-GAN structure.

$\displaystyle\ln(\frac{\exp(\mathbb{E}[l_{real}(G(z))])}{\exp(\mathbb{E}[l_{real}(G(z))])+\exp(\mathbb{E}[l_{fake}(G(z))])+\exp(\mathbb{E}[l_{noise}(G(z))])})$
(II.35)

###  II.7 Residue-wise variants of AC-GAN and Semi-supervised GAN

As we want to utilize all sequence information in a window, the discriminator
for AC-GAN and Semi-supervised GAN should be able to handle sequence
information. To do that we modified AC-GAN and Semi-supervised GAN so that
they output corresponding sequence information for the dihedral angles. We
call the modified versions as Residue-wise AC-GAN and Residue-wise Semi-
supervised GAN, respectively.

In the Residue-wise AC-GAN, the classifier outputs corresponding sequence
information for given input angles residue-wise. Similarly, in Residue-wise
Semi-supervised GAN, the discriminator outputs sequence information for real
angles residue-wise and fake labels for generated angles by the generator.
Note that even though we named Residue-wise Semi-supervised GAN due to its
origin of structure, we don’t feed unlabelled angles (samples) in our
experiments as it’s unlikely to have angle information without sequence
information (labels).

One problem of making the Semi-supervised discriminator to handle residue-wise
information is that we want to have only one output about
$p_{model}(C=fake|x)$ for each input $x$. (The same problem occurs when we
also use NCE-GAN and add a class for noise samples as shown in the figure
II.2. The class for noise samples can also be handled by a similar process.).
We can make the discriminator do that with the following process.

First, we residue-wise normalize the sequence prediction. And the normalized
result is multiplied by $p_{model}(C=real|x)$ which is the estimated
probability that input $x$ is real. On the other hand, $p_{model}(C=fake|x)$,
the estimated probability that input $x$ is fake, is replicated $window\,size$
times. And then both results are concatenated. This process can also be
applied to handle multi labelled data and sequence information whose window
size is not fixed, for example, a discriminator which use recurrent neural
network.

(a) Residue-wise ACGAN

(b) Residue-wise Semi-supervised GAN

Figure II.2: Residue-wise variants of ACGAN and Semi-supervised GAN. Note that
these figures show the situations where NCE-GANs were used. Dashed lines
indicate correspondence relation between data and its label.

###  II.8 Evaluation

To check the regression performance of the models MSE (mean square error) of
cosine and sine values of angles and MAE (mean absolute error) of $\phi$ and
$\psi$ angles, which can be calculated by equation (II.1), were reported. Note
that $\min(d,2\pi-d)$ was used for calculation of MAE to handle periodicity,
where $d$ is the absolute difference.

To measure the performance of the discriminator’s density estimation, mean
log-likelihood (LL) were reported for both AC-GAN and Semi-supervised GAN
using equation (II.10). Note that C-GAN can not calculate likelihood, so mean
logarithm of $p_{\text{\tiny C-GAN}}(x,y|S=real)$ was reported. As right hand
side of the (II.10) is an approximation, its integration might not be 1 and
this could affect the estimated mean log-likelihood. To resolve this problem,
$\int\exp(l_{real}(x))\frac{p(C=noise)}{p(C=real)}dx$ was estimated by Monte
Carlo integration [67] and inverse of this was multiplied by the previously
estimated density.

To measure the generation performance of the generators, mean log-likelihood
(LL) for generated class were reported for both AC-GAN and Semi-supervised GAN
using equation (II.10). Note that C-GAN can not calculate likelihood, so mean
logarithm of $p_{\text{\tiny C-GAN}}(x,y|S=fake)$ was reported. The same
approach was applied to correct the integration of the estimated density.

To measure the conditional density estimation performance of the
discriminators, weighted mean conditional log-likelihood (CLL) were reported
for both AC-GAN and Semi-supervised GAN along central amino acids.
$p(Center=c)$ was estimated from training data like
$\hat{p}(Center=c)=\frac{\text{number of fragments whose central amino acid is
c}}{\text{total number of fragments}}$. Conditional likelihood
$p_{model}(x|Center=c,S=real)$ of the Semi-supervised GAN can be estimated
using equation (II.10). However, we need different formula for AC-GAN.
Remember that the discriminator of the AC-GAN assumes predicted classes and
sources are conditionally independent on the inputs as explained in I.4.5.
$p_{model}(Center=c,S=s)=p_{model}(Center=c)p_{model}(S=s)$ is also assumed as
$p(Center=c,S=s)=p(Center=c)p(S=s)$.

$\displaystyle p_{model}(x|{}$ $\displaystyle
Center=c,S=real)=\frac{p_{model}(x,Center=c,S=real)}{p_{model}(Center=c,S=real)}$
(II.36) $\displaystyle=$
$\displaystyle\frac{p_{model}(x,S=real|Center=c)p_{model}(Center=c)}{p_{model}(Center=c,S=real)}$
(II.37) $\displaystyle=$
$\displaystyle\frac{p_{model}(S=real|x,Center=c)p_{model}(x|Center=c)p_{model}(Center=c)}{p_{model}(Center=c,S=real)}$
(II.38) $\displaystyle=$
$\displaystyle\frac{p_{model}(S=real|x)p_{model}(x|Center=c)p_{model}(Center=c)}{p_{model}(Center=c)p_{model}(S=real)}$
$\displaystyle\,($ $\displaystyle\because\text{ conditional independence and
assumption on prior})$ (II.39) $\displaystyle=$
$\displaystyle\frac{p_{model}(S=real|x)p_{model}(x|Center=c)}{p_{model}(S=real)}$
(II.40)

We estimated $p_{model}(x|Center=c,S=real)$ in AC-GAN by equation (II.40).
$p_{model}(S=real)=\frac{1}{3}$ is assumed and the previously explained
approach is applied for estimation of $p_{model}(x|Center=c)$.

To measure the conditional generation performance of the generator, weighted
mean conditional log-likelihood (CLL) were reported only for AC-GAN by same
method mentioned in the previous paragraph. As Semi-supervised GAN does not
have a conditional model for generated samples, we could not report this
measure. One can use structure proposed in the future work section of [49] to
measure this performance.

To measure the distribution mimicking performance of the generators, Kullback-
Leibler (KL) divergence were reported for AC-GAN and Semi-supervised GAN.
$p_{model}(x|real)$ and $p_{model}(x|fake)$ are estimated by (II.10) and
integration correcting method were applied for both. Monte Carlo integration
[67] is applied for KL divergence estimation.

MSE, MAE values, LL and KL divergences were checked every 200th iteration and
CLL values were checked every 2000th iteration of training in order to create
training plots which show trends of the training.

##  Chapter III Results

###  III.1 Comparison of various GAN methods for dihedral angle prediction

####  III.1.1 Without regression loss

As mentioned in section II.4, in this experiment, we did not add regression
loss in the generators and noise class ignoring method was used for training
loss of the generators.

When we see MSE (mean square errors) of cosine and sine values of angles and
MAE (mean absolute errors) of $\phi$ and $\psi$ angles in figure III.1, we can
see training of C-GAN is unstable compared to other models. Figure III.2 (a),
(d) also show this trend. MSEs and MAEs of generative models were much higher
than regression model. Also see table III.1.

In table III.1 and figure III.2 (a), noise-contrastive estimator got the best
performance in terms of mean log-likelihood and weighted mean conditional log-
likelihood. This might indicate that adversarially trained discriminators
(density estimators) get confused when they learn density of the real data
distribution because of instability originating from the adversarial training.
However, despite the instability, adversarial training can help the density
estimation of the real data if the discriminator has to estimate high-
dimensional data such as image data.

In table III.1, although it could just be a result of the random behaviour, it
seems AC-GAN performs better than Semi-supervised GAN in terms of KL
(Kullback-Leibler) divergence and mean log-likelihood (LL) for the generated
samples. However, caution is needed when comparing these results because loss,
as defined for AC-GAN, is defined as the summation of the classification and
discrimination losses and this assumes predicted classes and sources are
conditionally independent on the inputs as mentioned in I.4.5. If such
assumptions do not hold, the discriminator may not capture the actual density
of the generated samples, especially when some weights of the discriminator
and the classifier are shared, as in our case. This is explained in the next
paragraph.

When we compared Ramachandran plots based on predicted angles in figure III.3,
the distribution of generated samples of C-GAN was similar to those of the
regression model. The distribution of generated samples of AC-GAN and Semi-
supervised GAN were roughly similar to that of real angles. However, the
distribution of predicted angles in AC-GAN is composed of some clusters, which
do not exist in the real angle distribution, and was less smooth. Such
clusters did not show in the estimated density plot of generated samples fig.
III.4 (bottom left) in AC-GAN. This is possibly because it did not have a
fixed generator, but it could also be because the independence assumption
mentioned in the previous paragraph does not hold. If we see the estimated
density plots for each amino acid, even though we have to be careful in
analysing estimated densities of AC-GAN, we can observe that AC-GAN’s
conditional densities for each amino acids are highly peaked compare to real
angle distribution. This is shown in table of plots III.2. These peaks might
correspond to the clusters which occur in figure III.3. These clusters can
also be explained by analysis of AC-GAN [68]. They showed that if joint
distribution of data and label contains points in decision boundary of the
classifier, AC-GAN will down-samples those points. From their analysis we
hypothesis that the regions the generator fails to generate are the places
where decision boundaries are located.

In figure III.3 (bottom right), distributions of predicted angles in Semi-
supervised GAN did not show the two separated regions $\zeta$ and
$\gamma^{\prime}$. Figure III.4 (middle right) shows this was because the
discriminator could not capture the two separated regions. The distributions
of predicted angles of Semi-supervised GAN also shows distribution of
predicted angles in $\alpha_{L}$ region is wrongly positioned (distribution is
parallel to $\psi$ axis and too narrowly distributed), but this is not shown
in estimated density plot of generated samples III.4 (bottom right). This can
be explained by the instability originating from adversarial training. This
can be checked by training more iterations in the discriminator after
finishing the training of the generator. Another possible reason is over-
fitting of the generator. To check over-fitting of the generator, one can plot
the predicted angles using training sequence information. However, we did not
invest either of these possible reasons.

When we compared Ramachandran plots based on predicted angles for each central
amino acids in the table of figures III.2, the generative models only
generated samples in $\alpha_{L}$ among $\alpha$ and $\alpha_{L}$ regions for
central amino acid Glycine, while the regression model could generate samples
in both regions. AC-GAN generated samples in narrower regions than C-GAN and
Semi-supervised GAN for some amino acids. This will make the distribution of
the generated angles of AC-GAN composed of unusual clusters.

| Regression | NCE | C-GAN | AC-GAN | Semi-supervised GAN
---|---|---|---|---|---
MSE | $\boldsymbol{0.3508}$ | - | 0.4925 | 0.5043 | 0.4770
Phi MAE | $\boldsymbol{26.3873}$ | - | 30.836 | 33.3909 | 33.3042
Psi MAE | $\boldsymbol{51.6076}$ | - | 68.6832 | 69.0326 | 64.8486
LL | - | -$\boldsymbol{1.2174}$ | -1.4372∗ | -1.2392 | -1.2362
CLL | - | -$\boldsymbol{0.9184}$ | - | -0.9702 | -1.0637
KL divergence | - | - | - | $\boldsymbol{0.005981}$ | 0.006797
LL (generated) | - | - | -1.9650∗ | -$\boldsymbol{1.2433}$ | -1.2522
CLL (generated) | - | - | - | -0.9656 | -
Table III.1: Comparision of MSEs, MAEs, mean log-likelihood, weighted mean
conditional log-likelihood along the middle amino acids and Kullback-Leibler
divergence between $p_{model}(x|S=real)$ and $p_{model}(x|S=fake)$ where $x$
indicates dihedral angles. The result of the first experiment after 50000
iterations.
$\ast$ Note that LL for C-GAN is not actually a mean log-likelihood, but
$p_{model}(x,y|S=real)$ where $y$ indicates sequence information. Likewise, LL
(generated) for C-GAN indicates $p_{model}(x,y|S=fake)$.

(a) Test mean square errors of cosine and sine values of angles

(b) Test mean absolute errors of phi angle

(c) Test mean absolute errors of psi angle

Figure III.1: The regression errors of the first experiment.
Black line: Regression model, Red line: Conditional GANs, Green line: AC-GANs,
Blue line: Semi-supervised GANs. The x-axis indicates the number of
iterations.

(a) Mean log-likelihood

(b) Weighted mean conditional log-likelihood along the middle amino acids

(c) Kullback-Leibler divergence between
$p_{model}(x|S=real)$ and $p_{model}(x|S=fake)$

(d) Mean log-likelihood for generated samples

(e) Weighted mean conditional log-likelihood along the middle amino acids for
generated samples

Figure III.2: The generation metrics of the first experiment.
Black line: NCE model, Red line: Conditional GANs, Green line: AC-GANs, Blue
line: Semi-supervised GANs. The x-axis indicates the number of iterations.
$\ast$ Red line in (a): $p_{model}(x,y|S=real)$, red line in (d):
$p_{model}(x,y|S=fake)$,
black and blue line in (e): Weighted mean conditional log-likelihood for real
data (not the generated data). They are depicted only for comparison.

Figure III.3: Ramachandran plot of test angles and plots using predicted
angles for the first experiment.
Top: real angles,
middle left: predicted angles by using regression model, middle right:
predicted angles by using C-GAN,
bottom left: predicted angles by using AC-GAN, bottom right: predicted angles
by using Semi-supervised GAN

Figure III.4: Estimated density plots for the first experiment. Note that
square root were applied on the estimated densities of angles for better
visualization.
Top: $p_{\text{\tiny NCE}}(x|S=real)$,
middle left: $p_{\text{\tiny AC-GAN}}(x|S=real)$, middle right:
$p_{\text{\tiny Semi-supervised GAN}}(x|S=real)$,
bottom left: $p_{\text{\tiny AC-GAN}}(x|S=fake)$, bottom right: $p_{\text{\tiny Semi-supervised GAN}}(x|S=fake)$ |  Aspartate (D) |  Cysteine (C) |  Glycine (G) |  Histidine (H) |  Serine (S)
---|---|---|---|---|---
Real angles |  |  |  |  |
Density estimation by NCE |  |  |  |  |
Density estimation by AC-GAN |  |  |  |  |
Density estimation by Semi-supervised GAN |  |  |  |  |
Predicted angles by regression model |  |  |  |  |
Predicted angles by C-GAN |  |  |  |  |
Predicted angles by AC-GAN |  |  |  |  |
Predicted angles by Semi-supervised GAN |  |  |  |  |
Table III.2: Table of real angles, estimated densities
$p_{model}(x|Center=c,S=real)$ and predicted angles plots for some central
amino acids for the first experiment. Plotted real angles are from the test
set and predicted angles are predicted by sequences in the test set. Plots of
amino acid whose estimated density plot of AC-GAN is highly peaked compared to
real angles are included. Plots of Glycine are also included due to its unique
distribution [6, 7, 5] and the difference of the predicted angles among the 4
prediction models.

####  III.1.2 Without regression loss and using predicted density by NCE

Training of the discriminators was not stable and estimated
$p_{model}(x|real)$ of Semi-supervised GAN did not capture the detailed shape
of the Ramachandran plot in the previous experiment III.1.1. As mentioned in
section II.4, we added predicted density estimation by NCE model as an
additional input of the discriminators in this experiment in an effort to
resolve mentioned issues.

When we see MSE of cosine and sine values of angles and MAE of $\phi$ and
$\psi$ angles in figure III.5, we can see training of C-GAN become more stable
compared to not putting predicted density information III.1. Figure III.6 (a)
shows training of $p_{model}(x,y|S=real)$ was not only stabilized, but also
trained faster. Similar trend was observed in figure III.6 (d) except for
early 10000 iterations of weight updates.

Table III.3 shows both $p_{model}(x,y|S=real)$ and $p_{model}(x,y|S=fake)$ for
C-GAN were improved. MSE and MAE values were slightly reduced for both AC-GAN
and Semi-supervised GAN. Mean log-likelihood (LL) for both real and generated
data were increased in AC-GAN and Semi-supervised GAN. KL-divergence between
estimated real data and generated sample distribution were reduced for both
AC-GAN and Semi-supervised GAN. This is also shown in figure III.6 (c).

Figures in III.7 show more realistic angle distributions except that the C-GAN
failed to generate angles in the $\alpha_{L}$ region. For example C-GAN seems
to capture two different region $\beta_{S}$ and $\beta_{P}$ which was not
observed in III.3 (middle right). Although distribution of predicted angles in
$\alpha_{L}$ region for Semi-supervised GAN seems to be somewhat vertically
squeezed, both AC-GAN and Semi-supervised GAN could generate more believable
angles in the $\alpha_{L}$ region than the results of the previous section and
the Semi-supervised GAN seems to capture $\zeta$ and $\gamma^{\prime}$
regions. In general, the discriminator of the Semi-supervised GAN could
capture these two regions shown in figure III.8 (middle right). It should be
noted generated samples from the AC-GAN contain some unusual clusters and
figure III.8 (bottom left) could not capture this phenomenon.

When we compared Ramachandran plots based on predicted angles for each central
amino acids in the table of figures III.4, AC-GAN and Semi-supervised GAN only
generated samples in $\alpha_{L}$ and C-GAN only generated samples in $\alpha$
among $\alpha$ and $\alpha_{L}$ regions for central amino acid Glycine. AC-GAN
generated samples in narrow regions like the first experiment. Contours of
distributions of generated angles of Semi-supervised GAN were well matched
with these of real angles.

| Regression | NCE | C-GAN | AC-GAN | Semi-supervised GAN
---|---|---|---|---|---
MSE | $\boldsymbol{0.3517}$ | - | 0.5282 | 0.4929 | 0.4644
Phi MAE | $\boldsymbol{26.5431}$ | - | 35.2343 | 31.8829 | 30.8688
Psi MAE | $\boldsymbol{51.6854}$ | - | 71.0663 | 68.2798 | 63.9015
LL | - | -$\boldsymbol{1.2074}$ | -1.0072∗ | -1.2209 | -1.2290
CLL | - | -$\boldsymbol{0.9188}$ | - | -1.0754 | -1.0100
KL divergence | - | - | - | 0.004449 | $\boldsymbol{0.002294}$
LL (generated) | - | - | -1.6494∗ | -1.2276 | -$\boldsymbol{1.2273}$
CLL (generated) | - | - | - | -1.0221 | -
Table III.3: Comparision of MSEs, MAEs, mean log-likelihood, weighted mean
conditional log-likelihood along the middle amino acids and Kullback-Leibler
divergence between $p_{model}(x|S=real)$ and $p_{model}(x|S=fake)$ where $x$
indicates dihedral angles. The result of the second experiment after 50000
iterations.
$\ast$ Note that LL for C-GAN is not actually a mean log-likelihood, but
$p_{model}(x,y|S=real)$. Likewise, LL (generated) for C-GAN indicates
$p_{model}(x,y|S=fake)$.

(a) Test mean square errors of cosine and sine values of angles

(b) Test mean absolute errors of phi angle

(c) Test mean absolute errors of psi angle

Figure III.5: The regression errors of the second experiment.
Black line: Regression model, Red line: Conditional GANs, Green line: AC-GANs,
Blue line: Semi-supervised GANs. The x-axis indicates the number of
iterations.

(a) Mean log-likelihood

(b) Weighted mean conditional log-likelihood along the middle amino acids

(c) Kullback-Leibler divergence between
$p_{model}(x|S=real)$ and $p_{model}(x|S=fake)$

(d) Mean log-likelihood for generated samples

(e) Weighted mean conditional log-likelihood along the middle amino acids for
generated samples

Figure III.6: The generation metrics of the second experiment.
Black line: NCE model, Red line: Conditional GANs, Green line: AC-GANs, Blue
line: Semi-supervised GANs. The x-axis indicates the number of iterations.
$\ast$ Red line in (a): $p_{model}(x,y|S=real)$, red line in (d):
$p_{model}(x,y|S=fake)$,
black and blue line in (e): Weighted mean conditional log-likelihood for real
data (not the generated data). They are depicted only for comparison.

Figure III.7: Ramachandran plot of test angles and plots using predicted
angles for the second experiment.
Top: real angles,
middle left: predicted angles by using regression model, middle right:
predicted angles by using C-GAN,
bottom left: predicted angles by using AC-GAN, bottom right: predicted angles
by using Semi-supervised GAN

Figure III.8: Estimated density plots for the second experiment. Note that
square root were applied on the estimated densities of angles for better
visualization.
Top: $p_{\text{\tiny NCE}}(x|S=real)$,
middle left: $p_{\text{\tiny AC-GAN}}(x|S=real)$, middle right:
$p_{\text{\tiny Semi-supervised GAN}}(x|S=real)$,
bottom left: $p_{\text{\tiny AC-GAN}}(x|S=fake)$, bottom right: $p_{\text{\tiny Semi-supervised GAN}}(x|S=fake)$ |  Aspartate (D) |  Cysteine (C) |  Glycine (G) |  Histidine (H) |  Serine (S)
---|---|---|---|---|---
Real angles |  |  |  |  |
Density estimation by NCE |  |  |  |  |
Density estimation by AC-GAN |  |  |  |  |
Density estimation by Semi-supervised GAN |  |  |  |  |
Predicted angles by regression model |  |  |  |  |
Predicted angles by C-GAN |  |  |  |  |
Predicted angles by AC-GAN |  |  |  |  |
Predicted angles by Semi-supervised GAN |  |  |  |  |
Table III.4: Table of real angles, estimated densities
$p_{model}(x|Center=c,S=real)$ and predicted angles plots for some central
amino acids for the second experiment. Plotted real angles are from the test
set and predicted angles are predicted by sequences in the test set. Same 5
chosen amino acids are depicted as in figure III.2.

####  III.1.3 Without regression loss, using predicted density by NCE and
minibatch-wise loss in generators

As mentioned in section II.4, we used minibatch-wise loss in the generators of
this experiment to see the effects of minibatch-wise generation loss.

When we see MSE value and MAE of $\phi$ and $\psi$ angles in figure III.9, we
can see training of C-GAN becoming more stable in the early 10000 iterations
of weight updates. This is also confirmed in figure III.10. This indicates
using minibatch-wise loss stabilize training of the C-GAN generator.

Table III.5 shows both $p_{model}(x,y|S=real)$ and $p_{model}(x,y|S=fake)$ for
C-GAN were improved. This would be because the generation performance of the
generator $p_{model}(x,y|S=fake)$ is improved and $p_{model}(x,y|S=real)$
might also be improved because of this. LL and CLL for both real and generated
data were slightly increased in AC-GAN except for CLL of the generated data.
However, KL divergence increased in AC-GAN as also shown in figure III.10.
Semi-supervised GAN got worse result in terms of all reported evaluation
metrics.

Figure III.11 show C-GAN could generate more samples in the $\alpha_{L}$
region and the AC-GAN seems to be get better at generating angles in regions
$\zeta$ and $\gamma^{\prime}$. Semi-supervised GAN got worse shape in the
$\beta_{S}$ and $\beta_{P}$ as shown in figure III.11 (bottom right). This
indicates using minibatch-wise loss in the loss of the Semi-supervised
generator does not improve its generation performance. Hence, different
approach to the Semi-supervised generator would be needed, or it might be
better to use the non-minibatch-wise loss in its generator.

When we compared Ramachandran plots based on predicted angles for each central
amino acids in the table of figures III.6, C-GAN generated samples in both
$\alpha$ and $\alpha_{L}$ regions for central amino acid Glycine. AC-GAN
generated samples in narrow regions like the first experiment. Contours of
distributions of generated angles of Semi-supervised GAN got worse at matching
with these of real angles.

| Regression | NCE | C-GAN | AC-GAN | Semi-supervised GAN
---|---|---|---|---|---
MSE | $\boldsymbol{0.3487}$ | - | 0.5388 | 0.4922 | 0.4836
Phi MAE | $\boldsymbol{26.2408}$ | - | 34.5151 | 31.6593 | 32.1611
Psi MAE | $\boldsymbol{51.4794}$ | - | 73.9974 | 67.8315 | 66.4762
LL | - | -$\boldsymbol{1.2088}$ | -0.9483∗ | -1.2179 | -1.2376
CLL | - | -$\boldsymbol{0.9131}$ | - | -1.0467 | -1.0197
KL divergence | - | - | - | 0.02048 | $\boldsymbol{0.007591}$
LL (generated) | - | - | -1.3046∗ | –$\boldsymbol{1.2214}$ | -1.2453
CLL (generated) | - | - | - | -1.0554 | -
Table III.5: Comparision of MSEs, MAEs, mean log-likelihood, weighted mean
conditional log-likelihood along the middle amino acids and Kullback-Leibler
divergence between $p_{model}(x|S=real)$ and $p_{model}(x|S=fake)$ where $x$
indicates dihedral angles. The result of the third experiment after 50000
iterations.
$\ast$ Note that LL for C-GAN is not actually a mean log-likelihood, but
$p_{model}(x,y|S=real)$. Likewise, LL (generated) for C-GAN indicates
$p_{model}(x,y|S=fake)$.

(a) Test mean square errors of cosine and sine values of angles

(b) Test mean absolute errors of phi angle

(c) Test mean absolute errors of psi angle

Figure III.9: The regression errors of the third experiment.
Black line: Regression model, Red line: Conditional GANs, Green line: AC-GANs,
Blue line: Semi-supervised GANs. The x-axis indicates the number of
iterations.

(a) Mean log-likelihood

(b) Weighted mean conditional log-likelihood along the middle amino acids

(c) Kullback-Leibler divergence between
$p_{model}(x|S=real)$ and $p_{model}(x|S=fake)$

(d) Mean log-likelihood for generated samples

(e) Weighted mean conditional log-likelihood along the middle amino acids for
generated samples

Figure III.10: The generation metrics of the third experiment.
Black line: NCE model, Red line: Conditional GANs, Green line: AC-GANs, Blue
line: Semi-supervised GANs. The x-axis indicates the number of iterations.
$\ast$ Red line in (a): $p_{model}(x,y|S=real)$, red line in (d):
$p_{model}(x,y|S=fake)$,
black and blue line in (e): Weighted mean conditional log-likelihood for real
data (not the generated data). They are depicted only for comparison.

Figure III.11: Ramachandran plot of test angles and plots using predicted
angles for the third experiment.
Top: real angles,
middle left: predicted angles by using regression model, middle right:
predicted angles by using C-GAN,
bottom left: predicted angles by using AC-GAN, bottom right: predicted angles
by using Semi-supervised GAN

Figure III.12: Estimated density plots for the third experiment. Note that
square root were applied on the estimated densities of angles for better
visualization.
Top: $p_{\text{\tiny NCE}}(x|S=real)$,
middle left: $p_{\text{\tiny AC-GAN}}(x|S=real)$, middle right:
$p_{\text{\tiny Semi-supervised GAN}}(x|S=real)$,
bottom left: $p_{\text{\tiny AC-GAN}}(x|S=fake)$, bottom right: $p_{\text{\tiny Semi-supervised GAN}}(x|S=fake)$ |  Aspartate (D) |  Cysteine (C) |  Glycine (G) |  Histidine (H) |  Serine (S)
---|---|---|---|---|---
Real angles |  |  |  |  |
Density estimation by NCE |  |  |  |  |
Density estimation by AC-GAN |  |  |  |  |
Density estimation by Semi-supervised GAN |  |  |  |  |
Predicted angles by regression model |  |  |  |  |
Predicted angles by C-GAN |  |  |  |  |
Predicted angles by AC-GAN |  |  |  |  |
Predicted angles by Semi-supervised GAN |  |  |  |  |
Table III.6: Table of real angles, estimated densities
$p_{model}(x|Center=c,S=real)$ and predicted angles plots for some central
amino acids for the third experiment. Plotted real angles are from the test
set and predicted angles are predicted by sequences in the test set. Same 5
chosen amino acids are depicted as in figure III.2.

####  III.1.4 With regression loss, using predicted density by NCE and
minibatch-wise loss in generators

We got high MSE and MAE values in the generators of previous experiments. As
mentioned in II.4, in this experiment, we added regression loss (II.1) in the
loss of the generators to reduce these errors in the generators.

In table III.7, MSE and MAE values of all generative models were reduced.
$p_{model}(x,y|S=fake)$ of C-GAN was improved and $p_{model}(x,y|S=real)$ was
also increased probably due to improved stability of the generator as shown in
III.13. Weighted mean conditional log-likelihood (CLL) of generated samples in
AC-GAN was improved. This might be because of increased conditional generation
performance due to added regression loss. However, mean log-likelihood (LL) of
generated samples in AC-GAN was decreased. This might be because the generator
put less effort in generating realistic samples due to added loss.

It appears that LL of both real and generated samples increased and CLL
decreased slightly in Semi-supervised GAN. However, it was not clear whether
this change was due to added loss or just random fluctuation. KL divergence of
the Semi-supervised GAN seems to be reduced in the table III.7, however when
we considered figure III.14 (c), this was due to random fluctuation and it
seems KL divergence got higher compared to previous experiment III.10 (c).

When distribution of predicted angles considered in figure III.15, C-GAN could
generate more samples in $\alpha_{L}$ region and distribution of predicted
angles of AC-GAN is smoothed probably because predicted points were more
likely to be located in the region between clusters to reduce regression loss.
The shape of $\beta_{S}$ and $\beta_{P}$ recovered slightly in Semi-supervised
GAN.

When we compared Ramachandran plots based on predicted angles for each central
amino acids in the table of figures III.8, all generative models generated
samples in both $\alpha$ and $\alpha_{L}$ regions for central amino acid
Glycine. In the result of AC-GAN, there were more number of predicted angles
in the region between clusters.

| Regression | NCE | C-GAN | AC-GAN | Semi-supervised GAN
---|---|---|---|---|---
MSE | $\boldsymbol{0.3496}$ | - | 0.4513 | 0.4011 | 0.4032
Phi MAE | $\boldsymbol{26.2809}$ | - | 30.3906 | 28.2837 | 29.1065
Psi MAE | $\boldsymbol{51.4477}$ | - | 62.8351 | 56.3453 | 56.2262
LL | - | -$\boldsymbol{1.2072}$ | -0.9146∗ | -1.2174 | -1.2307
CLL | - | -0.9169 | - | -$\boldsymbol{0.8845}$ | -1.0205
KL divergence | - | - | - | 0.01348 | $\boldsymbol{0.005088}$
LL (generated) | - | - | -1.1773∗ | -$\boldsymbol{1.2327}$ | -1.2351
CLL (generated) | - | - | - | -0.9232 | -
Table III.7: Comparision of MSEs, MAEs, mean log-likelihood, weighted mean
conditional log-likelihood along the middle amino acids and Kullback-Leibler
divergence between $p_{model}(x|S=real)$ and $p_{model}(x|S=fake)$ where $x$
indicates dihedral angles. The result of the fourth experiment after 50000
iterations.
$\ast$ Note that LL for C-GAN is not actually a mean log-likelihood, but
$p_{model}(x,y|S=real)$. Likewise, LL (generated) for C-GAN indicates
$p_{model}(x,y|S=fake)$.

(a) Test mean square errors of cosine and sine values of angles

(b) Test mean absolute errors of phi angle

(c) Test mean absolute errors of psi angle

Figure III.13: The regression errors of the fourth experiment.
Black line: Regression model, Red line: Conditional GANs, Green line: AC-GANs,
Blue line: Semi-supervised GANs. x-axis indicates number of iterations.

(a) Mean log-likelihood

(b) Weighted mean conditional log-likelihood along the middle amino acids

(c) Kullback-Leibler divergence between
$p_{model}(x|S=real)$ and $p_{model}(x|S=fake)$

(d) Mean log-likelihood for generated samples

(e) Weighted mean conditional log-likelihood along the middle amino acids for
generated samples

Figure III.14: The generation metrics of the fourth experiment.
Black line: NCE model, Red line: Conditional GANs, Green line: AC-GANs, Blue
line: Semi-supervised GANs. The x-axis indicates the number of iterations.
$\ast$ Red line in (a): $p_{model}(x,y|S=real)$, red line in (d):
$p_{model}(x,y|S=fake)$,
black and blue line in (e): Weighted mean conditional log-likelihood for real
data (not the generated data). They are depicted only for comparison.

Figure III.15: Ramachandran plot of test angles and plots using predicted
angles for the fourth experiment.
Top: real angles,
middle left: predicted angles by using regression model, middle right:
predicted angles by using C-GAN,
bottom left: predicted angles by using AC-GAN, bottom right: predicted angles
by using Semi-supervised GAN

Figure III.16: Estimated density plots for the fourth experiment. Note that
square root were applied on the estimated densities of angles for better
visualization.
Top: $p_{\text{\tiny NCE}}(x|S=real)$,
middle left: $p_{\text{\tiny AC-GAN}}(x|S=real)$, middle right:
$p_{\text{\tiny Semi-supervised GAN}}(x|S=real)$,
bottom left: $p_{\text{\tiny AC-GAN}}(x|S=fake)$, bottom right: $p_{\text{\tiny Semi-supervised GAN}}(x|S=fake)$ |  Aspartate (D) |  Cysteine (C) |  Glycine (G) |  Histidine (H) |  Serine (S)
---|---|---|---|---|---
Real angles |  |  |  |  |
Density estimation by NCE |  |  |  |  |
Density estimation by AC-GAN |  |  |  |  |
Density estimation by Semi-supervised GAN |  |  |  |  |
Predicted angles by regression model |  |  |  |  |
Predicted angles by C-GAN |  |  |  |  |
Predicted angles by AC-GAN |  |  |  |  |
Predicted angles by Semi-supervised GAN |  |  |  |  |
Table III.8: Table of real angles, estimated densities
$p_{model}(x|Center=c,S=real)$ and predicted angle plots for some central
amino acids for the fourth experiment. Plotted real angles are from the test
set and predicted angles are predicted by sequences in the test set. Same 5
chosen amino acids are depicted as in figure III.2.

####  III.1.5 With regression loss, using predicted density by NCE, minibatch-
wise loss in generators and predicted angles by regression model

We still got high MSE and MAE values in the generators of the previous
experiment. As mentioned in II.4, we used predicted results by regression
model as an additional inputs of the generators in this experiment in order to
further reduce these errors.

In table III.9, MSE and MAE values of all generative models were further
improved. $p_{model}(x,y|S=fake)$ of C-GAN was improved. Weighted mean
conditional log-likelihood (CLL) of generated samples in AC-GAN is also
improved.

In figure III.19, it seems shape of $\beta_{S}$ regions of the C-GAN got
worse. Figure III.19 (bottom left) shows the smoothening effect of AC-GAN was
lessened. This is probably because the generator is more focus on reducing
generative loss as it can easily reduce the regression loss by using predicted
angle information. The shape of the $\beta_{S}$ and $\beta_{P}$ region in
Semi-supervised GAN appears to be worse.

When we compared Ramachandran plots based on predicted angles for each central
amino acids in the table of figures III.10, all generative models generated
samples in both $\alpha$ and $\alpha_{L}$ regions for central amino acid
Glycine.

| Regression | NCE | C-GAN | AC-GAN | Semi-supervised GAN
---|---|---|---|---|---
MSE | $\boldsymbol{0.3504}$ | - | 0.3823 | 0.3701 | 0.3678
Phi MAE | $\boldsymbol{26.6377}$ | - | 28.6309 | 27.7239 | 27.5119
Psi MAE | $\boldsymbol{51.4816}$ | - | 53.6731 | 51.5171 | 51.6804
LL | - | -$\boldsymbol{1.2095}$ | -0.9789∗ | -1.2233 | -1.2301
CLL | - | -$\boldsymbol{0.9107}$ | - | -0.9540 | -1.0351
KL divergence | - | - | - | 0.01684 | $\boldsymbol{0.01157}$
LL (generated) | - | - | -1.0525∗ | -$\boldsymbol{1.2262}$ | -1.2448
CLL (generated) | - | - | - | -0.9140 | -
Table III.9: Comparision of MSEs, MAEs, mean log-likelihood, weighted mean
conditional log-likelihood along the middle amino acids and Kullback-Leibler
divergence between $p_{model}(x|S=real)$ and $p_{model}(x|S=fake)$ where $x$
indicates dihedral angles. The result of the fifth experiment after 50000
iterations.
$\ast$ Note that LL for C-GAN is not actually a mean log-likelihood, but
$p_{model}(x,y|S=real)$. Likewise, LL (generated) for C-GAN indicates
$p_{model}(x,y|S=fake)$.

(a) Test mean square errors of cosine and sine values of angles

(b) Test mean absolute errors of phi angle

(c) Test mean absolute errors of psi angle

Figure III.17: The regression errors of the fifth experiment.
Black line: Regression model, Red line: Conditional GANs, Green line: AC-GANs,
Blue line: Semi-supervised GANs. The x-axis indicates the number of
iterations.

(a) Mean log-likelihood

(b) Weighted mean conditional log-likelihood along the middle amino acids

(c) Kullback-Leibler divergence between
$p_{model}(x|S=real)$ and $p_{model}(x|S=fake)$

(d) Mean log-likelihood for generated samples

(e) Weighted mean conditional log-likelihood along the middle amino acids for
generated samples

Figure III.18: The generation metrics of the fifth experiment.
Black line: NCE model, Red line: Conditional GANs, Green line: AC-GANs, Blue
line: Semi-supervised GANs. The x-axis indicates the number of iterations.
$\ast$ Red line in (a): $p_{model}(x,y|S=real)$, red line in (d):
$p_{model}(x,y|S=fake)$,
black and blue line in (e): Weighted mean conditional log-likelihood for real
data (not the generated data). They are depicted only for comparison.

Figure III.19: Ramachandran plot of test angles and plots using predicted
angles for the fifth experiment.
Top: real angles,
middle left: predicted angles by using regression model, middle right:
predicted angles by using C-GAN,
bottom left: predicted angles by using AC-GAN, bottom right: predicted angles
by using Semi-supervised GAN

Figure III.20: Estimated density plots for the fifth experiment. Note that
square root were applied on the estimated densities of angles for better
visualization.
Top: $p_{\text{\tiny NCE}}(x|S=real)$,
middle left: $p_{\text{\tiny AC-GAN}}(x|S=real)$, middle right:
$p_{\text{\tiny Semi-supervised GAN}}(x|S=real)$,
bottom left: $p_{\text{\tiny AC-GAN}}(x|S=fake)$, bottom right: $p_{\text{\tiny Semi-supervised GAN}}(x|S=fake)$ |  Aspartate (D) |  Cysteine (C) |  Glycine (G) |  Histidine (H) |  Serine (S)
---|---|---|---|---|---
Real angles |  |  |  |  |
Density estimation by NCE |  |  |  |  |
Density estimation by AC-GAN |  |  |  |  |
Density estimation by Semi-supervised GAN |  |  |  |  |
Predicted angles by regression model |  |  |  |  |
Predicted angles by C-GAN |  |  |  |  |
Predicted angles by AC-GAN |  |  |  |  |
Predicted angles by Semi-supervised GAN |  |  |  |  |
Table III.10: Table of real angles, estimated densities
$p_{model}(x|Center=c,S=real)$ and predicted angles plots for some central
amino acids for the fifth experiment. Plotted real angles are from the test
set and predicted angles are predicted by sequences in the test set. Same 5
chosen amino acids are depicted as in figure III.2.

##  Chapter IV Discussion

In this thesis, we investigated dihedral angle prediction using three
conditional generative adversarial models: C-GAN, AC-GAN and Semi-supervised
GAN. We compared their characteristics and examined possible improvements.

When we compare the distributions of predicted angles, C-GAN was poor at
capturing details of the Ramachandran plot, AC-GAN suffered from generating
angles composed of unusual clusters and Semi-supervised GAN generated angles
similar to the Ramachandran plot even though it could not generate angles in
the $\zeta$ and $\gamma^{\prime}$ regions separately in some experiments. So,
we advise using Semi-supervised GAN for conditional generation of samples. We
found that adding predicted density estimation by NCE model as an additional
input of the discriminators can stabilize GAN training and help generating
realistic angles. Minibatch-wise generation loss was only helpful in the
training of C-GAN and AC-GAN, but not Semi-supervised GAN. Adding regression
loss to the generators and adding predicted angles by regression model as an
additional input of the generator was helpful improving conditional generation
performances in C-GAN and AC-GAN addition to the MSE, MAE values.

This work is only focused on dihedral angle prediction using a window based
method. Future works need to also predict secondary structure and solvent
exposures. One can exploit bidirectional recurrent neural networks for this.
The generator will output predicted angles and solvent exposures. Using
predicted angles, secondary structure and solvent exposures by existing
programs as an additional input of the generator would aid the generator to
reduce the errors. Likewise, adding predicted secondary structure as an
additional input of the discriminator would help the discriminator to
stabilize training and one can make the discriminator to also output the
predicted secondary structure.

## Appendices

###  A.1 Generating samples using NCE-GAN when target distribution is given

We can generate samples using NCE-GAN when target distribution is given by
simply changing the training process.

The discriminator of the NCE-GAN will only get generated samples $x_{fake}$
and noise samples $x_{noise}$ as input because we do not have data samples
$x_{real}$. Then it outputs corresponding predicted labels for both generated
samples and noise samples. It also minimizes the estimated Kullback-Leibler
(KL) divergence between estimated target density of the discriminator and
target distribution. Remember that we can estimate $p_{model}(x|C=target)$ by
equation (II.10). KL divergence will be estimated using numerical integration
methods.

The generator tries to generate samples so that their estimated classes, which
the discriminator predicts, match the target classes.

One problem with this method is that $p_{model}(C=target)$ will approach zero
as no data samples are fed into the discriminator. Further research would be
needed to handle this problem.

The following two examples A.1, A.2 show NCE-GAN can generate target samples.

(a) Target density

(b) Estimated density of target distribution

(c) Estimated density of generated distribution

(d) Generated samples

(e) Estimated Kullback-Leibler divergence

Figure A.1: Generation of ring example [69] by described method. Note that
black line in (e) indicates KL divergence between real target density and
generated distribution. Blue line in (e) indicates estimated KL divergence
between estimated target density and generated distribution. Minibatch-wise
loss is used for training of the generator.

(a) Target density

(b) Estimated density of target distribution

(c) Estimated density of generated distribution

(d) Generated samples

(e) Estimated Kullback-Leibler divergence

Figure A.2: Generation of sine example by described method. Note that black
line in (e) indicates KL divergence between real target density and generated
distribution. Blue line in (e) indicates estimated KL divergence between
estimated target density and generated distribution. Minibatch-wise loss is
used for training of the generator.

###  A.2 Experiment of minibatch discrimination for density estimation

(a) Estimated density using noise-contrastive estimation

(b) Estimated density using noise-contrastive estimation with minibatch
discrimination

Figure A.3: Contour plots of estimated density of dihedral angles after 50000 iterations of mini-batch gradient updating. Noise samples are uniformly drawn from $(-\pi,\pi)^{2}$. Note that we also used batch size $64$ to calculate density estimation in (b). In other words, batch size $64$ is used for both training and test phase for (b). Estimated density for (b) is close to zero across all regions. Square root were applied on the estimated densities of angles for better visualization. Discriminator |  Estimated integration of estimated density function |  LL for uniform (noise) samples |  LL for test samples
---|---|---|---
Vanilla
discriminator |  0.9848 |  -7.6532 |  -1.2810
Suggested
minibatch
discriminator |  0.0001099 |  -18.9252 |  9.3477
Table A.1: Monte Carlo integration method [67] was used to estimate the
integration of the estimated density function. Remember that integration of
probability density function should be 1. LL indicates mean log-likelihood.

From table A.1 we can notice that mean log-likelihood when minibatch
discrimination is used (9.3477) is quite high compared to the result when the
usual discriminator is used (-1.2810). However, if we consider other results
like the small estimated integration of the estimated density function
(0.0001099), small mean log-likelihood for noise samples (-18.9252) and poor
estimated density plot in figure A.3 (b), we can explain that high performance
on log-likelihood was due to cheating, i.e., batch information is used to
estimate the likelihood of the test samples.

## References

  * [1] Neil A Campbell et al.  “Campbell Biology”  Pearson, 2014, pp. 75–788081336
  * [2] OpenStax  “Organic Compounds Essential to Human Functioning” License: Creative Commons Attribution License (by 4.0). License date: January 30  In _OpenStax CNX_ , 2017  URL: http://cnx.org/contents/6773536c-3efb-44c9-8ace-78fafdce27e1@8
  * [3] OpenStax Biology AP Courses  “Proteins” License: Creative Commons Attribution License (by 4.0). License date: October 11  In _OpenStax CNX_ , 2017  URL: http://cnx.org/contents/bf17f4df-605c-4388-88c2-25b0f000b0ed@4
  * [4] Helen M Berman et al.  “The protein data bank”  In _Acta Crystallographica Section D: Biological Crystallography_ 58.6 International Union of Crystallography, 2002, pp. 899–907
  * [5] Olav Zimmermann  “Backbone Dihedral Angle Prediction”  In _Prediction of Protein Secondary Structure_ New York, NY: Springer New York, 2017, pp. 65–82  DOI: 10.1007/978-1-4939-6406-2_7
  * [6] Gopalasamudram Narayana Ramachandran, Chandrasekharan Ramakrishnan and V Sasisekharan  “Stereochemistry of polypeptide chain configurations”  In _Journal of molecular biology_ 7.1 Academic Press, 1963, pp. 95–99
  * [7] GN t Ramachandran and V Sasisekharan  “Conformation of polypeptides and proteins”  In _Advances in protein chemistry_ 23 Elsevier, 1968, pp. 283–437
  * [8] Bosco K Ho and Robert Brasseur  “The Ramachandran plots of glycine and pre-proline”  In _BMC structural biology_ 5.1 BioMed Central, 2005, pp. 14
  * [9] Simon C Lovell et al.  “Structure validation by C$\alpha$ geometry: $\phi$, $\psi$ and C$\beta$ deviation”  In _Proteins: Structure, Function, and Bioinformatics_ 50.3 Wiley Online Library, 2003, pp. 437–450
  * [10] P Andrew Karplus  “Experimentally observed conformation-dependent geometry and hidden strain in proteins”  In _Protein Science_ 5.7 Wiley Online Library, 1996, pp. 1406–1420
  * [11] “Course materials and notes for Stanford class CS231n: Convolutional Neural Networks for Visual Recognition.” [Online; accessed 1-February-2018]  URL: http://cs231n.github.io/neural-networks-1/
  * [12] Christian Igel  “Neural Networks”, University Lecture, 2016
  * [13] Martin Riedmiller and Heinrich Braun  “A direct adaptive method for faster backpropagation learning: The RPROP algorithm”  In _Neural Networks, 1993., IEEE International Conference on_ , 1993, pp. 586–591  IEEE
  * [14] Diederik P Kingma and Jimmy Ba  “Adam: A method for stochastic optimization”  In _arXiv preprint arXiv:1412.6980_ , 2014
  * [15] Vinod Nair and Geoffrey E. Hinton  “Rectified Linear Units Improve Restricted Boltzmann Machines”  In _Proceedings of the 27th International Conference on International Conference on Machine Learning_ , ICML’10  Haifa, Israel: Omnipress, 2010, pp. 807–814  URL: http://dl.acm.org/citation.cfm?id=3104322.3104425
  * [16] Andrew L Maas, Awni Y Hannun and Andrew Y Ng  “Rectifier nonlinearities improve neural network acoustic models”  In _Proc. icml_ 30.1, 2013, pp. 3
  * [17] B. Xu, N. Wang, T. Chen and M. Li  “Empirical Evaluation of Rectified Activations in Convolutional Network”  In _ArXiv e-prints_ , 2015  arXiv:1505.00853 [cs.LG]
  * [18] James Bergstra, Guillaume Desjardins, Pascal Lamblin and Yoshua Bengio  “Quadratic Polynomials Learn Better Image Features”, 2009
  * [19] Xavier Glorot and Yoshua Bengio  “Understanding the difficulty of training deep feedforward neural networks”  In _Proceedings of the Thirteenth International Conference on Artificial Intelligence and Statistics_ 9, Proceedings of Machine Learning Research  Chia Laguna Resort, Sardinia, Italy: PMLR, 2010, pp. 249–256  URL: http://proceedings.mlr.press/v9/glorot10a.html
  * [20] Eshel Faraggi and Andrzej Kloczkowski  “Accurate Prediction of One-Dimensional Protein Structure Features Using SPINE-X”  In _Prediction of Protein Secondary Structure_ Springer, 2017, pp. 45–53
  * [21] Yaoqi Zhou and Eshel Faraggi  “Prediction of One-Dimensional Structural Properties Of Proteins by Integrated Neural Networks”  In _Introduction to Protein Structure Prediction_ John Wiley & Sons, Inc., 2010, pp. 46  DOI: 10.1002/9780470882207.ch4
  * [22] Yuedong Yang et al.  “Sixty-five years of the long march in protein secondary structure prediction: the final stretch?”  In _Briefings in Bioinformatics_ , 2016
  * [23] Qian Jiang, Xin Jin, Shin-Jye Lee and Shaowen Yao  “Protein secondary structure prediction: A survey of the state of the art”  In _Journal of Molecular Graphics and Modelling_ 76, 2017, pp. 379–402  DOI: https://doi.org/10.1016/j.jmgm.2017.07.015
  * [24] Haiou Li et al.  “Deep learning methods for protein torsion angle prediction”  In _BMC Bioinformatics_ 18.1, 2017, pp. 417  DOI: 10.1186/s12859-017-1834-2
  * [25] Ofer Dor and Yaoqi Zhou  “Real-SPINE: An integrated system of neural networks for real-value prediction of protein structural properties”  In _PROTEINS: Structure, Function, and Bioinformatics_ 68.1 Wiley Online Library, 2007, pp. 76–81
  * [26] Stephen F Altschul et al.  “Gapped BLAST and PSI-BLAST: a new generation of protein database search programs”  In _Nucleic acids research_ 25.17 Oxford University Press, 1997, pp. 3389–3402
  * [27] Jens Meiler, Michael Müller, Anita Zeidler and Felix Schmäschke  “Generation and evaluation of dimension-reduced amino acid parameter representations by artificial neural networks”  In _Molecular modeling annual_ 7.9 Springer, 2001, pp. 360–369
  * [28] Ofer Dor and Yaoqi Zhou  “Achieving 80% ten-fold cross-validated accuracy for secondary structure prediction by large-scale training”  In _Proteins: Structure, Function, and Bioinformatics_ 66.4 Wiley Online Library, 2007, pp. 838–845
  * [29] Bin Xue, Ofer Dor, Eshel Faraggi and Yaoqi Zhou  “Real-value prediction of backbone torsion angles”  In _Proteins: Structure, Function, and Bioinformatics_ 72.1 Wiley Subscription Services, Inc., A Wiley Company, 2008, pp. 427–433  DOI: 10.1002/prot.21940
  * [30] Eshel Faraggi, Yuedong Yang, Shesheng Zhang and Yaoqi Zhou  “Predicting Continuous Local Structure and the Effect of Its Substitution for Secondary Structure in Fragment-Free Protein Structure Prediction”  In _Structure_ 17.11, 2009, pp. 1515–1527  DOI: https://doi.org/10.1016/j.str.2009.09.006
  * [31] James Lyons et al.  “Predicting backbone C alpha angles and dihedrals from protein sequences by stacked sparse auto-encoder deep neural network”  In _Journal of Computational Chemistry_ 35.28, 2014, pp. 2040–2046  DOI: 10.1002/jcc.23718
  * [32] Rhys Heffernan et al.  “Improving prediction of secondary structure, local backbone angles, and solvent accessible surface area of proteins by iterative deep learning” License: Creative Commons Attribution 4.0 International License.  In _Scientific reports_ 5 Nature Publishing Group, 2015, pp. 11476
  * [33] Rhys Heffernan, Yuedong Yang, Kuldip Paliwal and Yaoqi Zhou  “Capturing non-local interactions by long short-term memory bidirectional recurrent neural networks for improving prediction of protein secondary structure, backbone angles, contact numbers and solvent accessibility”  In _Bioinformatics_ 33.18 Oxford University Press, 2017, pp. 2842–2849
  * [34] Michael Remmert, Andreas Biegert, Andreas Hauser and Johannes Söding  “HHblits: lightning-fast iterative protein sequence searching by HMM-HMM alignment”  In _Nature methods_ 9.2 Nature Publishing Group, 2012, pp. 173
  * [35] Thomas Hamelryck  “An amino acid has two sides: a new 2D measure provides a different view of solvent exposure”  In _Proteins: Structure, Function, and Bioinformatics_ 59.1 Wiley Online Library, 2005, pp. 38–48
  * [36] Sheng Wang et al.  “Accurate de novo prediction of protein contact map by ultra-deep learning model”  In _PLoS computational biology_ 13.1 Public Library of Science, 2017, pp. e1005324
  * [37] Joerg Schaarschmidt, Bohdan Monastyrskyy, Andriy Kryshtafovych and Alexandre M.J.J. Bonvin  “Assessment of contact predictions in CASP12: Co-evolution and deep learning coming of age”  In _Proteins: Structure, Function, and Bioinformatics_ 86, 2018, pp. 51–66  DOI: 10.1002/prot.25407
  * [38] Kaiming He, Xiangyu Zhang, Shaoqing Ren and Jian Sun  “Deep residual learning for image recognition”  In _Proceedings of the IEEE conference on computer vision and pattern recognition_ , 2016, pp. 770–778
  * [39] I.. Goodfellow et al.  “Generative Adversarial Networks”  In _ArXiv e-prints_ , 2014  arXiv:1406.2661v1 [stat.ML]
  * [40] Scott E Reed et al.  “Learning what and where to draw”  In _Advances in Neural Information Processing Systems_ , 2016, pp. 217–225
  * [41] Scott Reed et al.  “Generative adversarial text to image synthesis”  In _arXiv preprint arXiv:1605.05396_ , 2016
  * [42] H. Zhang et al.  “StackGAN: Text to Photo-realistic Image Synthesis with Stacked Generative Adversarial Networks”  In _ArXiv e-prints_ , 2016  arXiv:1612.03242v1 [cs.CV]
  * [43] A. Dash et al.  “TAC-GAN - Text Conditioned Auxiliary Classifier Generative Adversarial Network”  In _ArXiv e-prints_ , 2017  arXiv:1703.06412v2 [cs.CV]
  * [44] P. Isola, J.-Y. Zhu, T. Zhou and A.. Efros  “Image-to-Image Translation with Conditional Adversarial Networks”  In _ArXiv e-prints_ , 2016  arXiv:1611.07004v1 [cs.CV]
  * [45] Taeksoo Kim et al.  “Learning to discover cross-domain relations with generative adversarial networks”  In _arXiv preprint arXiv:1703.05192_ , 2017
  * [46] Yunjey Choi et al.  “StarGAN: Unified Generative Adversarial Networks for Multi-Domain Image-to-Image Translation”  In _arXiv preprint arXiv:1711.09020_ , 2017
  * [47] Christian Ledig et al.  “Photo-realistic single image super-resolution using a generative adversarial network”  In _arXiv preprint_ , 2016
  * [48] Deepak Pathak et al.  “Context encoders: Feature learning by inpainting”  In _Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition_ , 2016, pp. 2536–2544
  * [49] A. Odena  “Semi-Supervised Learning with Generative Adversarial Networks”  In _ArXiv e-prints_ , 2016  arXiv:1606.01583v2 [stat.ML]
  * [50] Z. Dai et al.  “Good Semi-supervised Learning that Requires a Bad GAN”  In _ArXiv e-prints_ , 2017  arXiv:1705.09783v2 [cs.LG]
  * [51] T. Salimans et al.  “Improved Techniques for Training GANs”  In _ArXiv e-prints_ , 2016  arXiv:1606.03498v1 [cs.LG]
  * [52] I.. Goodfellow  “On distinguishability criteria for estimating generative models”  In _ArXiv e-prints_ , 2014  arXiv:1412.6515v4 [stat.ML]
  * [53] Y. Mroueh, T. Sercu and V. Goel  “McGan: Mean and Covariance Feature Matching GAN”  In _ArXiv e-prints_ , 2017  arXiv:1702.08398 [cs.LG]
  * [54] L. Theis, A. van den Oord and M. Bethge  “A note on the evaluation of generative models”  In _ArXiv e-prints_ , 2015  arXiv:1511.01844v3 [stat.ML]
  * [55] C. Szegedy et al.  “Rethinking the Inception Architecture for Computer Vision”  In _ArXiv e-prints_ , 2015  arXiv:1512.00567 [cs.CV]
  * [56] S. Barratt and R. Sharma  “A Note on the Inception Score”  In _ArXiv e-prints_ , 2018  arXiv:1801.01973 [stat.ML]
  * [57] C. Szegedy et al.  “Intriguing properties of neural networks”  In _ArXiv e-prints_ , 2013  arXiv:1312.6199v4 [cs.CV]
  * [58] A. Odena, C. Olah and J. Shlens  “Conditional Image Synthesis With Auxiliary Classifier GANs”  In _ArXiv e-prints_ , 2016  arXiv:1610.09585v3 [stat.ML]
  * [59] Z. Wang, E.. Simoncelli and A.. Bovik  “Multiscale structural similarity for image quality assessment”  In _The Thrity-Seventh Asilomar Conference on Signals, Systems Computers, 2003_ 2, 2003, pp. 1398–1402 Vol.2  DOI: 10.1109/ACSSC.2003.1292216
  * [60] D. Jiwoong Im, C. Dongjoo Kim, H. Jiang and R. Memisevic  “Generating images with recurrent adversarial networks”  In _ArXiv e-prints_ , 2016  arXiv:1602.05110v5 [cs.LG]
  * [61] M. Mirza and S. Osindero  “Conditional Generative Adversarial Nets”  In _ArXiv e-prints_ , 2014  arXiv:1411.1784v1 [cs.LG]
  * [62] Michael Gutmann and Aapo Hyvärinen  “Noise-contrastive estimation: A new estimation principle for unnormalized statistical models”  In _Proceedings of the Thirteenth International Conference on Artificial Intelligence and Statistics_ 9, Proceedings of Machine Learning Research  Chia Laguna Resort, Sardinia, Italy: PMLR, 2010, pp. 297–304  URL: http://proceedings.mlr.press/v9/gutmann10a.html
  * [63] Guoli Wang and Roland L Dunbrack Jr  “PISCES: a protein sequence culling server”  In _Bioinformatics_ 19.12 Oxford University Press, 2003, pp. 1589–1591
  * [64] Peter JA Cock et al.  “Biopython: freely available Python tools for computational molecular biology and bioinformatics”  In _Bioinformatics_ 25.11 Oxford University Press, 2009, pp. 1422–1423
  * [65] Wolfgang Kabsch and Christian Sander  “Dictionary of protein secondary structure: pattern recognition of hydrogen-bonded and geometrical features”  In _Biopolymers_ 22.12 Wiley Online Library, 1983, pp. 2577–2637
  * [66] Martín Abadi et al.  “Tensorflow: Large-scale machine learning on heterogeneous distributed systems”  In _arXiv preprint arXiv:1603.04467_ , 2016
  * [67] Stefan Weinzierl  “Introduction to monte carlo methods”  In _arXiv preprint hep-ph/0006269_ , 2000
  * [68] Rui Shu, Hung Bui and Stefano Ermon  “AC-GAN Learns a Biased Distribution”
  * [69] Luke Metz, Ben Poole, David Pfau and Jascha Sohl-Dickstein  “Unrolled generative adversarial networks”  In _arXiv preprint arXiv:1611.02163_ , 2016