\section{Introduction}
\label{S:1}
Breast cancer is amongst the most diagnosed cancers~\citep{ausStats2017,cancerStats17} affecting women worldwide~\citep{desantis2015international,torre2015global}.
One of the most effective ways of increasing the survival rate for this disease is based on early detection~\citep{saadatmand2015influence,welch2016breast}.
Screening programs aim to provide such early detection by diagnosing at-risk, asymptomatic patients, allowing for an early intervention and treatment.
The most widely employed image modality for population-based breast screening is mammography. High risk patients are also recommended to undergo screening with dynamically contrast enhanced magnetic resonance imaging (DCE-MRI)~\citep{mainiero2017acr,smith2017cancer}. DCE-MRI is known to increase the sensitivity, compared to mammography, especially in young patients that have denser breasts~\citep	{kriege2004efficacy}.

However, the diagnosis and interpretation of DCE-MRI is a challenging and time consuming task that involves the interpretation of large amounts of data~\citep{behrens2007computer} and is prone to high inter-observer variability~\citep{grimm2015interobserver,lehman2013accuracy}.
Computer-aided diagnosis (CAD) systems are designed to reduce the analysis time~\citep{gubern2016automated,wood2005computer},  increase sensitivity~\citep{Vreemann2018}
and specificity~\citep{meinel2007breast}, and serve as a second (automated) reader~\citep{shimauchi2011evaluation}.
Designing such systems is challenging due to the variability in location, appearance~\citep{levman2009effect}, size and shape~\citep{song2016progress}, and the low signal-to-noise ratio~\citep{kousi2015quality} of lesions.
In general, such CAD systems can be categorised as pre-hoc or post-hoc, depending on how the processing stages are organised, as explained below.

Fully automated pre-hoc CAD methods for breast screening~\citep{amit2017hybrid,dalmics2018fully,gubern2015automated} from DCE-MRI compute the confidence score of malignancy of a breast using the following two-stage sequential approach: 1) detection of suspicious lesions, and 2) classification of the detected lesions.
During detection (i.e., first stage), the algorithm localises benign and malignant lesions, and possibly false positive detections, in the image, which are then classified as malignant or non-malignant in the second stage.  Four important challenges arise with this pre-hoc approach.
Firstly, the modelling of the detector requires strong labels, i.e., precise voxel-wise annotation of lesions (see Fig.~\ref{fig:preAndPost} for an example of different types of annotations). Strong annotation is expensive because it requires experts to label a relatively large number of training volumes;  in addition, given the difficulties involved in such manual labelling process, this annotation may contain noise (this happens partly because experts are generally not trained to provide such precise annotations in regular practice).
Secondly, the classifier may be trained using incorrect
manually annotated lesion class labels. Such manual annotation is usually produced by biopsy analysis, but if there are benign and malignant lesions jointly present in the same breast, this analysis may not determine the correct association.
Thirdly, apart from rare exceptions that need large annotated training sets~\citep{ribli2018detecting}, pre-hoc diagnosis systems are generally trained in a two-stage process~\citep{gubern2015automated,mcclymont2015computer}. This pipeline is not the optimal way to maximise classification diagnosis performance because the final classification depends on the detection, but the detection optimality does not warrant classification optimality.
Finally, the fourth challenge is that the classification accuracy is limited by the detector performance, where it is impossible for the classifier to recover from a missing lesion detection because it can not be classified.

\begin{figure}[t]
\begin{tabular}{ccc}
\subfloat[]{\includegraphics[width = 1.5in]{3M.png}\label{img1}} &
\hspace{0.1in}
\subfloat[]{\includegraphics[width = 1.5in, height = 1.47in]{3Mc.png}\label{img2}}&
\hspace{0.1in}
\subfloat[]{\includegraphics[width = 1.5in]{3Mw.png}\label{img3}}
\end{tabular}
\caption{Example of a DCE-MRI breast image and annotation types.
Image (\ref{img1}) shows a slice of a breast DCE-MRI volume.
Image (\ref{img2}) shows the same slice with the strong annotations: lesion delineation classification as malignant.
Image (\ref{img3}) shows the weak annotation (i.e., whole image) of the same breast volume as malignant. }
\label{fig:preAndPost}
\end{figure}

An alternative approach that is starting to gain traction~\citep{esteva2017dermatologist,maicas2018training,wang2017chestx} reverses these stages. The first stage aims to classify the whole breast scan directly, followed by a second stage that localizes regions in the scan that can explain the classification

-- for instance, if the first stage outputs a malignant diagnosis, then the second stage aims to find malignant lesions in the scan. We term this a {\em post-hoc} approach. %
This approach is of special interest for the problem of breast screening from DCE-MRI because the whole-scan diagnosis can, for example, analyse regions other than lesions that may contain relevant information for the diagnosis~\citep{kostopoulos2017computer}.
The main advantage of these systems compared to pre-hoc systems is the possibility of using scan-level labels (referred to as weak labels in the rest of the paper). Such labels are already present in many Picture Archiving and Communication Systems (PACS) or can be automatically extracted from radiology reports~\citep{wang2017chestx}, eliminating almost completely the effort needed for the manual annotation described above for the pre-hoc approach.
Also, the use of scan-level labels overcomes the limitations in annotations required by pre-hoc approaches. Firstly, there is no need for lesion delineation avoiding such costly process. Secondly, the incorrect labelling of lesions explained above is reduced as the most likely lesion to be malignant is biopsied and therefore the label is more likely to be correct --there is no need to associate labels with lesions).
The main challenge of post-hoc systems resides in highlighting the scan regions that can justify a particular classification (e.g., in the case of a malignant classification, it is expected that the regions represent the malignant areas of the scan), given that such manual annotation is not available.  This challenge is important for the deployment of post-hoc systems in clinical practice~\citep{caruana2015intelligible}.

In this paper, we propose a new post-hoc method and a
systematic comparison between pre-hoc and post-hoc approaches for breast screening from DCE-MRI. We aim to answer the following research questions: 1) which approach should be chosen if the goal is to optimally classify a whole scan in terms of malignant or non-malignant findings, and 2) how accurate is the localisation of malignant lesions produced by post-hoc approaches when compared with the localisation of malignant lesions produced by pre-hoc methods.
The pre-hoc system considered in this paper is based on our recent detection model~\citep{maicas2017deep} that achieves state-of-the-art (SOTA) lesion localisation, while reducing the inference time needed by traditional exhaustive search methods.
For the post-hoc system, we rely on our recently proposed approach based on meta-learning~\citep{maicas2018training} that holds the SOTA performance for the problem of breast screening from DCE-MRI. Decision interpretation is based on our recent 1-class saliency detector~\citep{maicas2018lesion}, especially designed for the weakly supervised lesion localisation problem after performing volume diagnosis.
See Fig.~\ref{fig:intro} for an overview of the pre-hoc and post-hoc pipelines.

Experiments on a breast DCE-MRI dataset containing 117 patients and 141 lesions show that the post-hoc system achieves better malignancy classification accuracy than the pre-hoc method. In terms of lesion localisation, the post-hoc approach shows less accurate performance compared to the pre-hoc system, which we infer that is mostly due to the weak annotation used in the training phase of the post-hoc method.

\begin{figure}[h]
\centering\includegraphics[width=1.\linewidth]{FigureMethods.png}
\caption{Pre-hoc and post-hoc approaches for breast screening. \textbf{a)} The pre-hoc approach first localises lesions in the input breast volume (e.g., detections in orange), and then these lesions are classified to decide about their malignancy (e.g., red indicates positive and blue means negative malignancy classification). Finally, the breast volume is diagnosed according to the classification scores of the lesions.
\textbf{b)} The post-hoc approach first diagnoses the input breast volume (e.g., red means positive malignancy classification). If the diagnosis is positive, then malignant lesions are localised in the breast (e.g., detections in orange).}
\label{fig:intro}
\end{figure}

\section{Literature Review}
\label{S:2}

\subsection{Pre-hoc Approaches}

Pre-hoc approaches are assumed to contain two sequential stages: 1) detection of regions of interest (ROI) containing suspicious tissue, and 2) classification of ROIs into malignant or not malignant (benign and/or false positive) tissue.

Traditional pre-hoc approaches for breast screening from breast DCE-MRI were based on manual~\citep{agner2014computerized,gallego2015improving,mus2017time,soares20133d} or semi-automated~\citep{chen2006fuzzy,dalmics2016computer,meinel2007breast,milenkovic2017textural,platel2014automated} ROI detection.
In addition, the classification in these traditional approaches was based on support vector machine (SVM), random forest, or artificial neural network models, using hand-designed features (e.g., dynamic, morphological, textural or multifractal)~\citep{dalmics2016computer,meinel2007breast,milenkovic2017textural,platel2014automated}.

Aiming at reducing user intervention to reduce the number of ROIs~\citep{liu2017total}, pre-hoc systems evolved to be fully automated.
Such automated pre-hoc approaches generally employed an exhaustive search method
or clustering to detect ROIs in the scan using hand-designed features~\citep{gubern2015automated,mcclymont2015computer,renz2012detection,wang2014robust}. The classification of ROIs into false positive, benign or malignant findings is then performed with a new set of hand-designed features extracted from the ROIs~\citep{gubern2015automated,mcclymont2015computer,renz2012detection,wang2014robust}.
These fully automated methods generally suffer from two issues: 1) the sub-optimality of hand-designed features needed at both ROI localization and ROI classification, and 2) the high computational cost of the exhaustive search to detect ROIs.

Both limitations have been addressed after the introduction of deep learning methodologies~\citep{krizhevsky2012imagenet} in the field of medical image analysis.
Initially, feature sub-optimality was addressed either for ROI detection~\citep{maicas2017globally,maicas2017deep} or classification~\citep{amit2017classification,amit2017hybrid,rasti2017breast},
but it was recently solved for both detection and classification~\citep{dalmics2018fully}.
~\cite{dalmics2018fully} also reduced the inference time of the exhaustive search by directly computing a segmentation map from the scan using a U-net~\citep{ronneberger2015u}.

Although each step of the pipeline has been individually optimized, there is no guarantee that the full pipeline is optimal in terms of classification accuracy. This was addressed with the formation of large datasets that has enabled the use of SOTA one-stage detection and classification computer vision techniques, such as Faster R-CNN~\citep{ren2015faster} or Mask RCNN~\citep{he2017mask}. The main advantage of these methods lies in the optimality of the end-to-end training, effectively merging the detection and classification tasks~\citep{dalmics2018fully}.
For example,~\cite{ribli2018detecting} applied Faster R-CNN to detect tumours from mammograms and they showed that this approach is quite efficient in terms of inference time. However, Faster R-CNN generalises poorly, which means that the training set must contain a large annotated set of ROIs and, at the same time, be rich enough to comprise all possible lesion  variations.
Besides the need for large datasets, which are difficult to acquire for DCE-MRI breast screening,  these systems suffer from the need for strong annotations (i.e., the accurate delineation of the lesions).
~\cite{li2018thoracic} partially addressed this issue by developing a semi-supervised system, alleviating the need of lesion annotations. However, a large number of annotated images (880) is still required to train the system.

\subsection{Post-hoc Approaches}

Post-hoc systems aim to overcome the need for strong annotations by training models with only scan-level labels (i.e., weak labels). This is especially useful for the problem of breast screening, where the analysis of adjacent regions to lesions may be important~\citep{kostopoulos2017computer}.  In addition, the classification accuracy of post-hoc systems are not constrained by the lesion detection, which is the case in pre-hoc systems.

Several post-hoc systems have been proposed~\citep{wang2017chestx,zhu2017deep}.
For instance,
~\cite{wang2017chestx} use a deep learning model to produce classification scores from whole scans and
~\cite{zhu2017deep} propose a deep multiple instance learning.
However, these approaches still require large datasets to achieve good performance.
This issue was addressed by
~\cite{maicas2018training}, who proposed a new meta-learning methodology to learn from a small number of annotated training images. Their work established a new SOTA classification accuracy for breast screening from DCE-MRI.

The main challenge for post-hoc models arises from the fact that they do not use manually annotated ROIs for training, which makes the ROI localisation (and delineation) a hard task.  Such ROI localisation is important for explaining the classification made by the CAD system in clinical settings (e.g., for a scan classified as malignant, doctors are likely to know where the lesions are located). Solving this lesion localisation problem is a research problem that is being actively investigated in the field~\citep{dubost2017gp,feng2017discriminative,maicas2018lesion,wang2017zoom,yang2017joint}.
The approach proposed by
~\cite{maicas2018lesion} achieves SOTA detection performance by properly defining saliency for the problem of weakly supervised lesion localisation, which assures that salient regions represent malignant lesions in the image.

However, the literature does not provide any studies comparing pre and post-hoc diagnosis approaches. The main reason for this absence of comparison among the methods described in this literature review is that such analysis is not straightforward due to~\citep{maicas2017deep}: 1) the lack of publicly available datasets that can be used to compare new approaches to the current state-of-the-art, 2) the criteria to decide if an ROI is a true positive detection, and 3) the criteria to decide if lesions labelled as the challenging BIRADS=3 should be included into the benign category~\citep{gubern2015automated}.
In addition, not all assessments of pre-hoc fully automated methodologies consider false positives in the diagnostic stage as they only differentiate between benign and malignant~\citep{mcclymont2015computer}.
We propose to compare both types of automated approaches for the problem of breast screening from breast DCE-MRI. With the use of a common dataset and well-defined criteria to satisfy the issues described above, we investigate which approach performs better for breast diagnosis and lesion localisation.

\section{Methods}
\label{S:3}
This section provides a formal description of the dataset in Sec. \ref{sec:dataset}, the pre-hoc method in Sec. \ref{sec:pre-hoc}, and the post-hoc approach in Sec. \ref{sec:pos-hoc}.

\subsection{Dataset}
\label{sec:dataset}

Let {\scriptsize ${\cal D} = \left \{ \left ( \mathbf{b}_i, \mathbf{x}_i, \mathbf{t}_i, \{ \mathbf{s}_i^{(j)} \}_{j = 1}^M, \{ \mathbf{l}_i^{(j)} \}_{j = 1}^M, \mathbf{y}_i\right )_i \right \}_{i \in \{1,...,|{\cal D}| \},\mathbf{b}_i \in \{ \text{left},\text{right} \}}$} denote the 3D DCE-MRI dataset, where
$\mathbf{b}_i \in \{ \text{left},\text{right} \}$ specifies the left or right breast of the $i^{th}$ patient;
$\mathbf{x}_i,\mathbf{t}_i:\Omega \rightarrow \mathbb R$ represent the first 3D DCE-MRI subtraction volume and the T1-weighted MRI volume used for preprocessing, respectively, with $\Omega\in\mathbb {R}^3$ representing the volume lattice of size $w\times h\times d$;
$\mathbf{s}_i^{(j)}:\Omega \rightarrow \{0,1\}$ is the voxelwise annotation of the $j^{th}$ lesion present in the breast $\mathbf{b}_i$ ($\mathbf{s}_i^{(j)}(\omega)=1$ indicates the presence of lesion in voxel $\omega \in \Omega$, and $\mathbf{s}_i^{(j)}(\omega)=0$ denotes the absence of lesion);
$\{ \mathbf{l}_i^{(j)} \}_{j = 1}^M \in \{ 0,1 \}$ indicates the classification of lesion $j$ as benign or malignant, respectively;
and  $\mathbf{y}_i$ is a scan-level label with the following values: $\mathbf{y}_i = 0$ if there is no lesion in breast $\mathbf{b}_i$, $\mathbf{y}_i = 1$ if all the lesion(s) in breast $\mathbf{b}_i$ are benign or $\mathbf{y}_i = 2$ if there is at least one malignant lesion.
The dataset is patient-wise split into train $\mathcal{T}$, validation $\mathcal{V}$ and test $\mathcal{U}$ sets, such that images of each patient only belong to one of the sets.
Note that the voxelwise lesion annotations $\{ \mathbf{s}_i^{(j)} \}_{j = 1}^M \text{ and } \{ \mathbf{l}_i^{(j)} \}_{j = 1}^M$ are not employed during the training of the post-hoc system -- they are only used to train and test the pre-hoc system and in the quantification of the results for both systems.
Finally, the motivation behind the use of the first subtraction image $\mathbf{x}$ lies in the reduction of cost and time for image acquisition and analysis~\citep{gilbert2018personalised,mango2015abbreviated}.

\subsection{Pre-hoc Method}\label{sec:pre-hoc}

Our proposed pre-hoc approach is based on the following steps:
\begin{enumerate}
\item \textbf{Lesion detection} (Sec.~\ref{sec:pre-hoc-training-inference}): an attention mechanism based on deep reinforcement learning (DRL)~\citep{mnih2015human} searches for lesions using a method that analyses large portions of the breast volume and iteratively focuses the search on the appropriate regions of the input volume.
\item \textbf{Lesion diagnosis} (Sec.~\ref{sec:classification}): a state-of-the-art deep learning classifier~\citep{huang2017densely} analyses the lesions detected in the previous step in order to classify them as malignant or non-malignant (note that non-malignant regions are represented by benign lesions or normal tissue, i.e. false positive detections).
The confidence score of malignancy for the breast volume is defined as the maximum probability of malignancy among the detected lesions.
\end{enumerate}

\subsubsection{Lesion Detection}\label{sec:pre-hoc-training-inference}

We propose an attention model that is capable of reducing the inference time of previous methods for lesion detection~\citep{gubern2015automated,mcclymont2014fully} in pre-hoc systems.
This attention mechanism searches for lesions by progressively transforming relatively large initial bounding volumes (BV) ({\em i.e.} sub-regions of the {\em MRI volume}) into smaller regions containing a more focused view of potential lesions~\citep{maicas2017deep}.
The transformation process is guided by a policy $\pi$ that indicates how to optimally change the current BV to detect a lesion. The policy is represented by a deep neural network, called deep Q-net (DQN), that receives as input an embedding vector $\mathbf{o} \in \mathbb R^{O}$ of the current BV and outputs a measurement (i.e., the Q-value $(Q)$), representing the optimality associated with each of the possible transformations to find a lesion. See Figure~\ref{fig:RLprocess} for a block diagram of this process.
The aim of the learning phase is to model such policy, i.e., find the optimal parameters of the DQN. The inference exploits the policy to detect the lesions present in a breast DCE-MRI volume.

\begin{figure}[h]
\centering\includegraphics[width=1.\linewidth]{RL_Figure.png}
\caption{Overview of the proposed lesion detection method. The bounding volume of the current observation is extracted from the input breast volume and fed to the 3D ResNet to obtain the embedding of the observation. The embedding is then forwarded through the Q-net to obtain the Q-values for each of the actions.}
\label{fig:RLprocess}
\end{figure}

The training process of the DQN follows that of a traditional Markov Decision Process (MDP), which models a sequence of decisions to accomplish a goal from an initial state. At every time step, the current BV, represented by the observations $\mathbf{o}$, will be transformed by an action $a$, yielding a reward $r$ -- this reward indicates the effectiveness of the the chosen transformation for detecting a lesion.
The goal is to learn what actions should be applied to transform the current observation to another one with larger Dice coefficient measured with respect to the target lesion. In an MDP set-up, this translates into choosing the action that maximizes the expected sum of discounted future rewards~\citep{mnih2015human}: $R_t = \sum_{t'=t}^T \gamma^{t'-t} r_{t'}$, where $\gamma \in (0,1)$ is a discount factor.

Let $Q^{\star}(\mathbf{o},a)$ be the optimal Action-Value Function representing the expected sum of discounted future rewards by choosing action $a$ to transform the observation $\mathbf{o}$.  The optimal Action-Value function follows the policy $\pi$, as in:
\begin{equation}
Q^{\star}(\mathbf{o},a) = \max_{\pi} \mathbb{E}[R_t|\mathbf{o}_t=\mathbf{o},a_t=a,\pi].
\label{eq:training_Q1}
\end{equation}
Intuitively, $Q^{\star}(.)$ represents the {\em quality} of performing the action $a$ given the current observation $\mathbf{o}$ to achieve the final goal.  Therefore, the goal of the training process is to learn $Q^{\star}(.)$, which  maximizes the commulative sum of expected discounted rewards.

The optimal $Q^{\star}(\mathbf{o},a)$ can be computed iteratively using the {\em Bellman} equation and the Q-Learning algorithm ~\citep{Sut1998}:
\begin{equation}
Q_{i+1}(\mathbf{o}_t,a_t) = \displaystyle{\mathop{\mathbb{E}}}_{\mathbf{o}_{t+1}}\Bigl[r_t+\gamma \max_{a_{t+1}} Q(\mathbf{o}_{t+1},a_{t+1})|\mathbf{o}_t,a_t\Bigr].\label{eq:bellman}
\end{equation}

However, since it is impractical to compute $Q(\mathbf{o}_t,a_t)$ due to the large size of the observation-action space, a DQN function approximator, represented by $Q(\mathbf{o},a,\bm{\theta})$, can be used.
The weights $\bm{\theta}$ of the DQN $Q(\mathbf{o}_t,a_t,\bm{\theta}_t)$ can be learned by minimizing the mean square error of the Bellman equation:
{\small\begin{equation}
L(\bm{\theta}_t) = \mathbb{E}_{(\mathbf{o}_t,a_t,r_t,\mathbf{o}_{t+1})~\sim~U(\mathcal{E})} \Bigl[\Bigl(\underbrace{r_t + \gamma \max_{a_{t+1}}Q(\mathbf{o}_{t+1},a_{t+1};\bm{\theta}_t^-)}_{\rm target} - Q(\mathbf{o}_t,a_t;\bm{\theta}_t) \Bigr)^2 \Bigr],
\label{eq:Loss}
\end{equation}}where $\bm{\theta}_t$ are the parameters of the DQN at iteration $t$, $\bm{\theta}_t^-$ are the weights of the target network (defined below) used to compute the target value at iteration $t$,
and $U(\mathcal{E})$ is a batch of experiences uniformly sampled from the experience replay memory $\mathbf{\mathcal{E}}_t$ (also defined below).
The target network is used to compute the target values for each update of the weights of the DQN.
The architecture of this target network is the same as that of the DQN and its parameters $\bm{\theta}_t^{-}$ contain the weights of the DQN at a previous iteration of the optimization process. The weights $\bm{\theta}_t^{-}$ are updated after every iteration through the entire training set from the parameters $\bm{\theta}_t$ at the iteration $t-1$ and maintained constant between updates: $\bm{\theta}_t^- = \bm{\theta}_{t-1}$.
The experience-replay memory $\mathcal{E}_t=\{e_1,...,e_t\}$  stores previous experiences denoted by $e_t=\{\mathbf{o}_t,a_t,r_t, \mathbf{o}_{t+1} \}$, where each $e_t$ is collected at time step $t$ by choosing the action $a_t$ to transform from $\mathbf{o}_t$ into $\mathbf{o}_{t+1}$, yielding the reward $r_t$.
We describe in the next paragraphs how to obtain the observations, to choose the actions and to compute the reward function.

The embedding $\mathbf{o}$ of the current BV is computed as:
\begin{equation}
\mathbf{o} = f_{ResNet}({\bf x}(\bf b) , \mathbf{\theta_{ResNet}} )\label{eq:BB}
\end{equation}
where ${\bf b} = [b_x, b_y,b_z,b_w,b_h,b_d]\in\mathbb{R}^{6}$ is a bounding volume, with the triplets $(b_x, b_y,b_z)$ and $(b_w,b_h,b_d)$ denoting the top-left-front and the lower-right-back corners of the bounding volume, respectively; the DCE-MRI
data is represented by ${\bf x}$; and $f_{ResNet}(.)$ represents a 3D Residual Network (ResNet)~\citep{he2016deep}.
The training of the 3D ResNet in \eqref{eq:BB} relies on a binary loss function that differentiates between input bounding volumes with and without lesions.
The dataset to train this 3D ResNet is built by sampling random BVs that are labelled as positive if the Dice Coefficient with a ground truth lesion is larger than 0.6, and negative otherwise.
Note that the training of the 3D ResNet with a potentially infinite number of BVs from different scales, sizes and locations allows us to obtain a rich collection of BVs without the need for a large training set.

The set ${\cal A}=\{l_{x}^{+},l_{x}^{-},l_{y}^{+},l_{y}^{-},l_{z}^{+},l_{z}^{-},s^{+},s^{-},w \}$ represents the actions to modify the current BV, where $\{l,s,w\}$ represent the translation, scale and trigger (to terminate the search for lesions) actions, respectively;
the subscripts $\{x,y,z\}$  denote the horizontal, vertical and depth translation, and the superscripts $\{+,-\}$ represent the positive/negative translation or up/down scaling.

The reward function depends on the improvement in the lesion localisation process after selecting a specific action.
For action $a \in {\cal A}\setminus \{w\}$, we measure the improvement in terms of the variation of the {\em Dice coefficient} after applying action $a$ to transform the observation $\mathbf{o}_{t}$ to $\mathbf{o}_{t+1}$:
\begin{equation}
r(\mathbf{o}_t,a,\mathbf{o}_{t+1}) = sign( d(\mathbf{o}_{t+1},\mathbf{s}) - d(\mathbf{o}_t,\mathbf{s})),
\label{eq:reward}
\end{equation}
where $d(.)$ is the Dice coefficient between the bounding volume $\mathbf{o}$  and the ground truth $\mathbf{s}$.
The intuition behind (\ref{eq:reward}) is that the reward is positive if the Dice coefficient from observation $\mathbf{o}_t$ to observation $\mathbf{o}_{t+1}$ increases, and the reward is negative otherwise.
The quantization in (\ref{eq:reward}) avoids a deterioration of the training convergence due to small changes in $d(.)$~\citep{caicedo2015active}.

The reward for the trigger action, $a=w$, is defined as:
\begin{equation}
r(\mathbf{o}_t,a,\mathbf{o}_{t+1}) =
\begin{cases}+\eta  & {\rm if}\;\; d(\mathbf{o}_{t+1},\mathbf{s}) \geq \tau_w\\
		-\eta & {\rm otherwise}
\end{cases}\label{eq:reward_trigger}
\end{equation}
where $\eta > 1$ encourages the trigger action to finalize the search for lesions if the Dice coefficient with the ground truth $\mathbf{s}$ is larger than a pre-defined threshold $\tau_w$.

Actions during the training process are selected according to a modified $\epsilon$-greedy strategy to balance {\em exploration} and {\em exploitation}~\citep{maicas2017deep}:  with probability $\epsilon$, a random  action will be explored, and with probability $1-\epsilon$, the action will be chosen from the current policy.
During {\em exploration},
with probability $\kappa$, a random action is selected, and with probability $1 - \kappa$, a random action from the actions that will produce a positive reward is selected.
During  {\em exploitation},
the action is selected according to the current policy: $a_t=\arg\max_{a_t}Q(\mathbf{o}_t,a_t; \bm{\theta}_t)$.
The training process starts with $\epsilon=1$, which decreases linearly, transitioning from pure exploration to mostly exploitation following the current policy as the model learns to detect lesions.

During \textbf{inference},
we exploit the learned policy to detect lesions. In practice, we propose several initial bounding volumes covering different relatively large portions of the DCE-MRI volume.
Each initialization is processed independently and is iteratively transformed according to the action $a^{\star}_t$ indicated by the optimal action-value function:
\begin{equation}
a^{\star}_t = \arg\max_{a_t} Q(\mathbf{o}_t,a_t; \bm{\theta}^{\star}).
\end{equation}
where $\bm{\theta}^{\star}$ represents the parameter vector of the trained DQN model learned with \eqref{eq:Loss}.

We define the set of detected lesions as $\mathcal{D}^{pre} = \{ \mathcal{D}_i^{pre}\}_{i=1}^{|\mathcal{D}^{pre}|}$,
where $\mathcal{D}_i^{pre}$ represents the $i^{th}$ bounding volume, when the trigger action is selected to stop the inference process. If the trigger action is not selected after 20 iterations, the search for a lesion is stopped yielding no detection.

\subsubsection{Lesion diagnosis}\label{sec:classification}

The detected lesions in $\mathcal{D}^{pre}$, formed during the lesion localization stage, are classified in terms of their malignancy.
This binary classification is performed with a 3D DenseNet~\citep{huang2017densely}, trained using the detections from the training set to differentiate normal tissue and benign lesions (i.e., negative diagnoses) from malignant lesions (positive diagnosis).
During inference, each detection $\mathcal{D}_i^{pre}$ is fed through the 3D DenseNet to obtain its probability of malignancy.
Finally, the confidence score of malignancy of a breast  is defined as the maximum of the  malignancy probabilities computed from all the detected regions in such breast.
The confidence score of malignancy for the breast volume with no detections is set to zero.

\subsection{Post-hoc Method}\label{sec:pos-hoc}

Our proposed post-hoc approach is characterised by the following steps:
\begin{enumerate}
\item \textbf{Diagnosis} (Sec.~\ref{sec:VolDiagnose}): the classifier outputs the probability that a breast DCE-MRI volume contains a malignant lesion. Given the small training dataset, the model is first meta-trained with a teacher-student curriculum learning strategy to learn to solve several tasks. Then, the classifier is fine-tuned to solve the breast screening diagnosis task.
\item \textbf{Lesion Localization} (Sec.~\ref{sec:VolInterpretation}): the detector is weakly-trained to localise malignant lesions on breast DCE-MRI volumes that have been positively classified in the diagnosis stage above.  This lesion localisation process can be used to interpret the decision from the diagnosis stage.
\end{enumerate}

\subsubsection{Breast Volume Diagnosis}
\label{sec:VolDiagnose}

Meta-training aims to learn a model that can solve new given tasks (classification problems) as opposed to traditional classifiers that solve a specific classification problem. Traditionally, models for solving new tasks have been achieved by fine-tuning pre-trained models~\citep{tajbakhsh2016convolutional}. However, these pre-trained models are rarely available for 3D volumes and large datasets are still required. These limitations can be overcome by including a meta-training phase before training, where the model is presented with several classification tasks that need to be solved, where each task has a small training set. Eventually, the model learns to solve new tasks that contain small training sets.

As noted in our previous work~\citep{maicas2018training}, the order in which to present classification tasks during meta-training influences the ability of the model to solve new tasks. Therefore, we propose to use the teacher-student curriculum learning strategy~\citep{matiisen2017teacher} that has been shown to outperform other strategies~\citep{maicas2018training}.

We propose to  meta-train the model to solve several related classification tasks, each containing a relatively small number of training images instead of training a classifier to distinguish volumes with any malignant findings from others containing no malignant lesions.
Firstly, during the meta-training phase, our model learns to solve different tasks that are formed from our breast DCE-MRI datasets. The tasks to be presented to the model are selected via the teacher-student curriculum learning strategy and contain a small training set.
Secondly, the training phase is similar to that of any traditional classifier and solves the breast screening task using the samples available from the training set. The difference in our approach lies in the employment of the meta-trained model as the initialization for the training process.
As a result, when the meta-trained model is fine-tuned on the breast screening task with the small training set, it is able to efficiently and effectively classify previously unseen volumes containing malignant findings~\citep{maicas2018training}.
Finally, the inference phase (or breast diagnosis) consists of feeding the input volumes to the classifier to estimate the probability that they contain a malignant finding.
See Figure~\ref{fig:mlprocess} for an overview of the volume diagnosis process.

\begin{figure}[h]
\centering\includegraphics[width=1.\linewidth]{MLprocess.png}
\caption{Volume diagnosis process. Firstly, the model is meta-trained on several related classification tasks. Secondly, the model is trained in the breast screening task. Finally, the model is tested on the breast screening task.}
\label{fig:mlprocess}
\end{figure}

During \textbf{meta-training},  the model is meta-trained to solve the following five classification tasks:
\begin{enumerate}
\item $K_1:$ findings (lesions) versus no findings,
\item $K_2:$ malignant findings versus no findings,
\item $K_3:$ benign findings versus no findings,
\item $K_4:$ benign findings versus malignant findings,
\item $K_5:$ malignant findings versus no malignant findings (i.e., breast screening).
\end{enumerate}

Let $K= \cup_{i=1}^5  K_i $, where each task $K_i$ is associated with a dataset $\mathcal{D}_i$ that contains the volumes from the training set that are relevant for the task $K_i$. We define the meta-training set $\mathcal{D} = \cup_{i=1}^5  \mathcal{D}_i $.

Let the model to be meta-trained be defined by $g_{\theta}$ and the meta-update step be indexed by $t$. For each meta-update, a meta-batch $\mathcal{K}_t$ of tasks is sampled and contains $|\mathcal{K}_{t}|$ tasks from $K$ (see bellow for a description of the task sampling method). For each of the tasks $K_j \in \mathcal{K}_t$,  $N=N^{tr} + N^{val}$ volume-label samples are sampled from the corresponding meta-training set $\mathcal{D}_j$ to form $\mathcal{D}_j^{tr}$.
Let $\mathcal{D}_j^{tr}$ contain $N^{tr}$ samples that will be used as training set and $\mathcal{D}_j^{val}$ contain $N^{val}$ samples that will be used as validation set during the $t^{th}$ meta-update for the $j^{th}$ task.

For every task $K_j \in \mathcal{K}_t$ in the meta-batch, the model is trained with $\mathcal{D}_j^{tr}$ to adapt to the task by performing several gradient descent updates. For simplicity, the adaptation of the model with one gradient descent update is defined by:
\begin{equation}
\theta_{j}^{\prime(t)} = \theta^{(t)} -
\alpha \frac{\partial \mathcal{L}_{K_j} \left( g_{\theta^{(t)}} \left ( \mathcal{D}_j^{tr} \right) \right) }{\partial \theta},
\label{eq:innerUpdt}
\end{equation}
where $\theta^{(t)}$ are the parameters of the model at meta-iteration $t$,
$\mathcal{L}_{K_j} (g_{\theta^{(t)}} \left ( \mathcal{D}_j^{tr} \right)) $ is the cross-entropy loss computed from $\mathcal{D}_j^{tr}$ for task ${K_j}$,
$\alpha$ is the learning rate for model adaptation, and
$\theta_{j}^{\prime(t)}$ are the adapted parameters after performing model adaptation for task ${K_j}$.

The adapted models $g_{\theta_{j}^{\prime(t)}}$ are subsequently evaluated with the validation pairs $\mathcal{D}_j^{val}$ of the corresponding task. The loss produced by the validation set on each of the tasks is used to compute the meta-gradient associated to each task. Finally, the model parameters $\theta$ are updated using the average of the meta-gradients associated to each of the tasks in the meta-batch:
\begin{equation}
\theta^{(t+1)} = \theta^{(t)} - \beta  \mathlarger{\sum_{K_j \in \mathcal{K}_m}} \frac{ \partial \mathcal{L}_{K_j} \left(
g_{\theta_j^{\prime(t)}}\left( \mathcal{D}_j^{val} \right)\right )}{\partial \theta},
\label{eq:metaUpdt}
\end{equation}
where $\beta$ is the meta-learning rate and
$\mathcal{L}_{K_j} \left( g_{\theta_j^{\prime(t)}}\left( \mathcal{D}_j^{val} \right)\right )$ is the cross entropy loss of the validation volumes in $\mathcal{D}_j^{val}$ for task ${K_j}$.
This procedure is repeated for  $M$ meta-iterations, as shown in Alg.~\ref{alg:meta-training}.
\begin{algorithm}
\caption{Overview of the meta-training procedure presented in~\citep{maicas2018training}}\label{alg:metatraining}
\begin{algorithmic}[]
\footnotesize{
\Procedure{Meta-train}{$\{K_1 \ldots K_5\}$, $\{\mathcal{D}_1 \ldots \mathcal{D}_5\}$, model $g_{\theta}$}
\State Initialise parameters $\theta$ from  $g_{\theta}$
	\For{$t=1\;\; to \;\; T$}
    \State \textbf{Sample} meta-batch $\mathcal{K}_{t}$ by sampling $|\mathcal{K}_{t}|$ tasks from $\{K_1 \ldots K_5\}$
        \For{each task $K_j \in \text{meta-batch }\mathcal{K}_t$}
		\State \textbf{Adapt} model using (\ref{eq:innerUpdt}) with samples from $\mathcal{D}_j^{tr}$
        \State \textbf{Evaluate} adapted model using with samples from $\mathcal{D}_j^{val}$
		\EndFor\label{endEveryTask}
	\State \textbf{Meta-update} model parameters with (\ref{eq:metaUpdt})
	\EndFor\label{endMetaUpdate}
\EndProcedure
}
\end{algorithmic}
\label{alg:meta-training}
\end{algorithm}

The breast screening \textbf{training} process is initialised by the meta-trained model.  Using the entire training set  $\mathcal{T}$, the model adapts to the breast screening task by performing several gradient descent updates, similarly to the training of a traditional deep learning classifier. We use the validation set $\mathcal{V}$ for model selection.
The \textbf{inference} of the model is similar to that of any standard classifier and consists of feeding the testing volume through the network to obtain the probability of malignancy
of each of the input volumes. The confidence score of malignancy corresponds to the probability of malignant output by the classifier.

During the \textbf{meta-learning process}, the \textbf{task sampling} process to form a meta-batch of tasks depends on the past observed performance improvements of the model in each of the tasks. This has been shown to outperform other alternative approaches~\citep{maicas2018training}.
A partially observable Markov decision process (POMDP) solved using reinforcement learning with Thompson Sampling can model such an approach. A POMDP is characterized by observations, actions, and rewards. In our set-up, we define an observation $O_{K_j}$
as the variation in the area under the receiving operating characteristic curve (AUC) of the adapted model $\theta_{j}^{\prime(t)}$ compared to the initial AUC before the model  $\theta^{(t)}$  was adapted to the task $K_j \in \mathcal{K}_t$ -- in both cases, the AUC is measured using the sampled validation set $\mathcal{D}_j^{val}$. The actions correspond to sampling a particular task. The reward is defined as the difference between the current and previous observations during the last time that the task was sampled.
The goal is to decide which action to apply, i.e. which task should be sampled for the next meta-training iteration. We use Thompson sampling to decide the next task to be sampled, which allows us to balance between sampling new tasks, and sampling tasks for which the improvement of performance is currently higher (similar to the exploration-exploitation dilemma in reinforcement learning)~\citep{matiisen2017teacher}.

Let $\mathcal{B}_j$ be a buffer of recent rewards for task $K_j$ -- this buffer stores the last $B$ rewards for this task.
To perform Thompson sampling, a random recent reward $R_{\mathcal{B}_j} \in \mathcal{B}_j$ is uniformly sampled. The next task $K_j$ to be included in the meta-batch $\mathcal{K}_{t}$ of iteration $t$ is selected with $j = \arg\max_i |R_{\mathcal{B}_i}|$. This process is repeated for $|\mathcal{K}_{t}|$ times to form $\mathcal{K}_{t}$.
The intuition behind this is that for tasks where performance is increasing rapidly (i.e. yielding higher rewards) they will be sampled more frequently until mastered (i.e. the reward will tend to zero as the variation in AUC after adaptation will tend to be smaller in consecutive iterations). Then, a different task will be sampled more frequently. However, if the model reduces the performance in the previously mastered task, it will be sampled again more frequently because the absolute value of the reward will tend to be higher again.

\subsubsection{Malignant Region Localization}
\label{sec:VolInterpretation}

A breast volume is diagnosed as malignant in the previous step if its confidence score of malignancy is higher than the equal error rate (EER) of the proposed classifier on the validation set.
The EER as threshold is chosen to avoid any preference between sensitivity and specificity.
For positively classified volumes, we aim to generate a saliency map represented by a binary mask indicating the localization of lesions that can explain the decision made by the classifier; while for negatively
classified volumes, no salient region is produced. Therefore, we propose a 1-class saliency detector~\citep{maicas2018lesion} that has been specifically designed to satisfy these conditions.

Our 1-class saliency detector is modelled with a weakly-supervised training process to detect salient regions in positively classified volumes, where these regions denote malignant lesions. The detector follows an encoder-decoder architecture that generates a mask $\mathbf{m}:\Omega \rightarrow [0,1]$ of the same size as the input volume, where this mask localizes the most salient regions of the input volume that are involved in the positive classification.
The encoder is the classifier from Sec.~\ref{sec:VolDiagnose}, which produces the diagnosis. The decoder up-samples the output from the encoder to the original resolution from the lowest resolution feature maps by concatenating four blocks of feature map resize, convolution layer, batch normalization layer and ReLU activation~\citep{zeiler2014visualizing}. Skip connections are used to connect corresponding layers of the same resolution in the encoder and decoder.
During training, the parameters of the encoder are fixed and the parameters of the decoder are updated using the gradient corresponding to the following loss for each volume $\mathbf{x}_i$:
\begin{equation}
\ell_i(\mathbf{m})= \lambda_1 \ell_{TV}(\mathbf{m}) + \lambda_2 \ell_{A}(\mathbf{m}) - y_i \lambda_3  \ell_{P}(\mathbf{m},\mathbf{x}_i) + y_i \lambda_4 \ell_{D}(1-\mathbf{m},\mathbf{x}_i),
\label{eq:PostweakLocLoss}
\end{equation}
where
$\ell_{TV}$ measures the total variation of the mask forcing the boundary of salient regions to be relatively smooth,
$\ell_{A}$ measures the area of the salient regions and aims to reduce the total area of regions,
$\ell_{P}$ measures the confidence in the classification of the input volume  $\mathbf{x}_i$ masked with $\mathbf{m}$, and
$\ell_{D}$ measures the confidence in the classification of the input volume  $\mathbf{x}_i$ masked with the inverse of the generated mask, i.e $(1 - \mathbf{m} )$.

By \textbf{training} the mask generator model with the loss function~\eqref{eq:PostweakLocLoss}, there is an explicit relationship between saliency and malignant lesions~\citep{maicas2018lesion}. By setting $y_i=0$ for negative volumes, they are forced to have no salient regions. For positives volumes, salient regions are forced to have the following characteristics: 1) be small and smooth, 2) when used to mask the input volume, the classification result is positive; and 3) when its inverse is used to mask the input volume, the classification result is negative.
During \textbf{inference}, volumes diagnosed as positive are fed forward through the decoder to produce a mask, where each voxel has values in $[0,1]$. This mask is thresholded at $\zeta$ to obtain the malignant lesions.

\section{Experiments}
\label{S:4}

In this section, we describe the dataset and experimental set-up used to assess the proposed methods for the problems of breast screening and malignant lesion detection.

\subsection{Dataset}

Our methods are evaluated with a dataset containing MRI scans from 117 patients. The dataset is patient-wise split into training, validation and test sets using the same split as previous approaches~\citep{maicas2017deep,maicas2018training,maicas2018lesion}. The training set contains scans from 45 patients, where these scans show 38 malignant lesions and 19 benign lesions -- the scans also show that 29 of the patients have at least one malignant lesion while 16 only have benign lesion(s).
The validation set has scans from 13 patients, with 11 malignant and 4 benign lesions
-- these scans show that 9 of the patients have at least one malignant lesion while 4 patients have only benign lesion(s). The test set contains scans from 59 patients, with  46 malignant and 23 benign lesions -- the scans show that 37 of the patients have at least one malignant lesion while 22 have only benign lesion(s).
The characterization of each lesion was confirmed with a biopsy.
Every patient has at least one lesion, but not every breast contains lesions.
There are 42, 13, and 58 breasts with no lesions in the training, validation and testing sets, respectively. Likewise, 18, 4, and 22 breasts contain only benign lesions (i.e. are considered ``benign'') and 30, 9, and 38 contain at least one malignant lesions (i.e. are considered ``malignant'').
For the breast screening problem, ``Malignant'' breasts are considered positive while ``benign'' and breasts with no lesions are considered negative.
The MRI dataset~\citep{mcclymont2014fully} contains T1-weighted and two dynamic contrast enhanced (pre-contrast and first post-contrast) volumes for each patient acquired with a 1.5 Tesla GE Signa HDxt scanner.
The   T1-weighted   anatomical   volumes  were acquired  without  fat  suppression and with an acquisition matrix of $512 \times 512$.
The DCE-MRI images are based on T1-weighted volumes with fat suppression, with an  acquisition matrix of $360 \times 360$ and a slice thickness of 1 mm. Firstly, a pre-contrast volume was acquired before a contrast agent was injected. The first post-contrast volume was acquired after a delay of 45 seconds after the acquisition of the pre-contrast. The first subtraction volume is formed by subtracting the pre-contrast volume to the first post-contrast volume.
Both T1-weighted and DCE-MRI were acquired axially.

The dataset was preprocessed using the T1-weighted volume to segment the breast region from the chest wall using Hayton's method~\citep{hayton1997analysis,mcclymont2014fully}. This involves removing the pectoral muscle which may produce false positive detections.  In addition, the breast region was divided into left and right breasts by splitting the volume in halves, as the breast region was initially centred.
Each breast volume was resized to a size of $100\times 100 \times 50$ voxels. Note that we operate the proposed methods breast-wise.

\subsection{Experimental Set-up}

The aim of the experiments is to assess our pre-hoc and post-hoc approaches in terms of their performance for diagnosing malignancy and localising malignant lesions from breast DCE-MRI.
Firstly, we individually evaluate the components of our proposed pre-hoc and post-hoc methods.
Secondly, we compare the performance of both approaches in terms of diagnosis accuracy and malignant lesion localisation.
Note that in every localisation evaluation we consider a region to be true positive if the Dice coefficient measured  between a candidate region and the ground truth lesion is at least 0.2~\citep{maicas2017deep,maicas2018lesion}.

\subsubsection{Pre-hoc System}

The lesion detection step in the pre-hoc approach is evaluated in terms of the free response operating characteristic (FROC) curve measured patient-wisely (as in previous detection works~\citep{gubern2015automated,maicas2017deep,maicas2018lesion}), which compares the true positive rate (TPR) against the number of false positive detections per patient (FPP). We also measure the inference time in a computer with the following configuration: Intel Core i7, 12 GB of RAM and a GPU Nvidia Titan X 12 GB.
As in previous diagnosis work~\citep{maicas2017deep}, the diagnosis step in the pre-hoc method is evaluated in terms of the area under the receiving operation characteristic curve (AUC), which compares true positive diagnosis rate against false positive diagnosis rate. The AUC is measured breast-wise in two different scenarios: 1) all the breasts in the testing set are considered, and 2) only breasts with at least one detected region are considered.

The \textbf{lesion detection} uses a 3D ResNet trained from scratch with random bounding volumes sampled from the training volumes. More specifically, we sample 8000 positive and 8000 negative patches that are resized to $100\times100\times50$ (the input size to the 3D ResNet). The choice of the input size of the ResNet is $100\times100\times50$ so that every lesion is visible -- some tiny lesions disappear at finer resolutions.
The architecture of the 3D ResNet~\citep{he2016deep} comprises 5 Residual Blocks~\citep{huang2016deep}, each of them preceded by a convolutional layer.
After the last residual block, the model contains two additional convolutional layers and a fully connected (FC) layer.
The embedding of the observation ``$\mathbf{o}$'' is the output of the second to last convolutional layer, before the FC layer and it has 2304 dimensions.

The DQN is a 2-layer multi-layer perceptron, with each layer containing 512 nodes. It outputs the $Q$-value for 9 actions: translation by one third of the size of the observation in the positive or negative direction on each of the dimensions (i.e. 6 actions), scaling by one sixth of the size of the observation and is applied in every dimension (i.e. 2 actions) and the trigger action. The reward value for the trigger action has been empirically defined as $\eta=10$ if $\tau_w=0.2$ (i.e., the Dice coefficient is at least 0.2 during the trigger action), and the discount factor is $\gamma = 0.9$.
The DQN is trained with batches of 100 experiences from the experience replay memory $\mathcal{E}$, which can store $10000$ experiences. We use Adam optimizer~\citep{kingma2014adam} with a learning rate of $10^{-6}$.

During training, the model is initialized with one centred large observation covering 75\% of the input breast volume.
During inference, the lesion detection algorithm is launched from 13 different initializations in order to increase the chances of finding all possible lesions present in a breast.
In addition to the same initialization used during training, eight initializations are placed in each of the eight $50\times50\times25$ corner volumes, and four $50\times50\times25$ initializations are placed centred between the previous 8 initializations.
The balance between exploration and exploitation during training is given by $\epsilon$, which decreases linearly from $\epsilon = 1$ to $\epsilon = 0.1$ after 300 epochs, and by $\kappa = 0.5$.

Detected regions are resized to $24\times24\times12$, which is the median value of the size of all detections in the training set.
The \textbf{lesion diagnosis} uses a 3D DenseNet~\citep{huang2017densely} composed of three dense blocks of two dense layers each.
Each dense layer comprises a batch normalization, ReLu and a convolutional layer.
In the particular DenseNet implementation used in this paper, we use a compression of 0.5 and a growth rate of 6.
Global average pooling of $6\times6\times3$ is applied after the last dense block and before the fully connected layer.
The DenseNet is optimized with stochastic gradient descent with a learning rate of 0.01.
The dataset used to train the 3D DenseNet is composed of all detections obtained from the training set. Model selection is performed using the detections from the validation set based on the breast-wise AUC for breast screening.
Note that detections that correspond to malignant lesions are labelled as positive while detections that correspond to benign lesions or false positives are labelled as negative.

\subsubsection{Post-hoc System}
\label{sec:densetOptimised}

The \textbf{diagnosis} step in the post-hoc approach is evaluated with the breast-wise AUC.
The malignant lesion localization step in the post-hoc approach is evaluated in terms of FROC curve patient-wise
under two different scenarios: 1) all the patients in the test set are considered to compute the FROC (A), and 2) only the number of patients that had at least one breast diagnosed as malignant (+), such that the performance of the 1-class saliency detector can be isolated.

The breast volume  diagnosis meta-training algorithm uses as the underlying model a 3D DenseNet~\citep{huang2017densely}.
The architecture was decided based on the optimization of a 3D DenseNet (trained with the training set $\mathcal{T}$) to achieve the best results for the breast screening task on the validation set $\mathcal{V}$ and consists of 5 dense blocks with 2 dense layers each. Each dense layer comprises a batch normalization, ReLu and convolutional layer, where compression was 0.5 and growth rate 6. No data augmentation or dropout were used since they did not improve the performance of this 3D model.
For meta-training, the learning rate is $\alpha = 0.01$ and the meta-learning rate is $\beta = 0.001$. The number of gradient descent steps during adaptation is 5 and the number of meta-iterations is $M=3000$.
The meta-batch size contained $|\mathcal{K}_{t}| = 5$ tasks,
where each task had $N^{tr} = 4$ samples for training and $ N^{val} = 4$ for validation. Each buffer $\mathcal{B}_j$  stored 40 recent rewards.

The localisation of \textbf{malignant lesions} in positively classified volumes is achieved by thresholding the generated saliency map at $\zeta = 0.8$ -- this threshold was decided based on the detection performance in the validation set.
The parameters for training the 1-class saliency detector in~\eqref{eq:PostweakLocLoss} are: $\lambda_1 = 0.1$, $\lambda_2 = 3$, $\lambda_3 = 1 $, and $\lambda_4 = 2.5$.

\subsubsection{Comparison Between Pre- and Post-Hoc}

Using the set-up described above for pre-hoc and post-hoc approaches, we compare the performance of both methods.
We evaluate diagnosis breast-wisely and patient-wisely in terms of the area under the receiving operation characteristic curve (AUC).
We also evaluate the performance of malignant lesion localisation for each approach patient-wisely using the FROC curve as in previous works~\citep{gubern2015automated,maicas2017deep,maicas2018lesion}.
Note that the TPR for malignant lesion localization breast-wisely is the same as patient-wisely, while the FPR breast-wisely is the same as the one for patient-wisely divided by two.
For the post-hoc method, we also plot the two scenarios (A) and (+), explained above.

\subsubsection{Experimental Results for the Pre-hoc System}

We compare the performance of our \textbf{lesion detection} step against an improved version of exhaustive search, namely a multi-scale cascade based on deep learning features~\citep{maicas2017globally}, and a mean-shift clustering method followed by structured learning~\citep{mcclymont2014fully} (note that only one operating point is available for this approach), which is evaluated on the same dataset using a different training and testing data split.
Figure~\ref{fig:PreDet} shows the FROC curve with the detection results and Table~\ref{tab:preDetTimes} contains the inference times per patient needed by each of the methods.

\begin{figure}[h]
\centering\includegraphics[width=0.6\linewidth]{preDet.png}
\caption{FROC curve per patient for the lesion detection step of our pre-hoc method, labelled as DQN, where the information in brackets refers to the number of initialisations per breast used during the inference process.  MS-SL refers to the mean-shift structured learning approach, and Cascade denotes the multi-scale cascade method based on deep learning features.}
\label{fig:PreDet}
\end{figure}

\begin{table}[]
\begin{tabular}{l|c|}
\cline{2-2}
 & \multicolumn{1}{l|}{\textbf{Inference Time Per Patient}} \\ \hline
\multicolumn{1}{|l|}{\textbf{DQN ( 13 Initializations )}} & $92 \pm 21 s$ \\ \hline
\multicolumn{1}{|l|}{\textbf{MS-SL}} & $164 \pm 137 s$ \\ \hline
\multicolumn{1}{|l|}{\textbf{Cascade}} & $\mathcal{O}(60) min$ \\ \hline
\end{tabular}
\caption{Inference time per patient of our proposed pre-hoc detection method (DQN using 13 initializations per breast), the MS-SL (mean-shift structured learning), and the multi-scale cascade baselines.}
\label{tab:preDetTimes}
\end{table}

The \textbf{diagnosis} of breast volumes, based on the classification of the detected regions, achieves an AUC of 0.85, if all volumes in the test dataset are considered.

\subsubsection{Experimental Results for the Post-hoc System}

We evaluate the performance of our post-hoc diagnosis against three state-of-the-art classifiers.
The first baseline is the 3D DenseNet~\citep{huang2017densely} that has been optimized to solve the breast screening problem (as explained in Sec.~\ref{sec:densetOptimised}).
The second baseline is the same 3D DenseNet fine-tuned using a multiple instance learning (MIL) set-up~\citep{zhu2017deep}, which holds the state-of-the-art for the breast screening problem from mammography.
Finally, we compare against a 3D DenseNet trained from scratch using multi-task learning~\citep{xue2018full}, such that the model is jointly trained to solve all the tasks defined in Sec.~\ref{sec:VolDiagnose}.
See Table~\ref{tab:PostDiagnosis} for the AUC diagnosis results.

\begin{table}
\centering
\begin{tabular}{|l|c|}
\hline
\textbf{Baseline} & \textbf{AUC}                                  \\
\hline
Meta-Training\textbf{(Ours)}         & \textbf{0.90 }                   \\
\hline
Multi-task~\citep{xue2018full}         & 0.85                    \\
\hline
MIL~\citep{zhu2017deep}               & 0.85                                      \\
\hline
DenseNet~\citep{huang2017densely}          & 0.83                                           \\
\hline
\end{tabular}
\caption{Breast-wise AUC for diagnosis in post-hoc systems. Our proposed post-hoc diagnosis method based on meta-training is labelled as Meta-Training, while the baseline based on multiple instance learning is labelled as MIL and the one based on multi-task learning is denoted as Multi-task.}
\label{tab:PostDiagnosis}
\end{table}

Our 1-class saliency detector specially designed to \textbf{detect malignant lesions} in positively classified volumes is compared against the following baselines: CAM~\citep{zhou2016learning}, and Grad-CAM and Guided Grad-CAM~\citep{selvaraju2017grad}.
Figure~\ref{fig:PostDet} shows the FROC curves for our proposed methods and baselines in each of the two scenarios (A) and (+).

\begin{figure}[h]
\centering\includegraphics[width=0.6\linewidth]{postDet.png}
\caption{Patient-wise FROC curves for post-hoc malignant lesion detection, where our method is denoted as 1-Class Saliency. Baselines are denoted as CAM~\citep{zhou2016learning}, and Grad-CAM and Guided Grad-CAM~\citep{selvaraju2017grad}. For each method, we present two scenarios: (A) all the volumes in the test set are considered to compute the FROC, and (+) only positively classified volumes are considered.}
\label{fig:PostDet}
\end{figure}

\subsubsection{Experimental Results for the Comparison Between Pre- and Post-Hoc}

Table~\ref{tab:fullDiagnosis} contains the AUC for the malignancy diagnosis measured breast-wise and patient-wise for the pre-hoc and post-hoc approaches. Figure~\ref{fig:fullDiag} shows the ROC curves used in the computation of the AUC in Table~\ref{tab:fullDiagnosis}.
Figure~\ref{fig:fullDet} shows the FROC curves for malignant lesion detection of pre-hoc and  post-hoc ( (A) and (+) ) methods.
Figures~\ref{fig:examplesFullCorrect},~\ref{fig:examplesFullPre},  and~\ref{fig:examplesFullPost} display examples of breast diagnosis and lesion localizations obtained from the proposed pre-hoc and post-hoc methods, where both methods correctly performed diagnosis (Fig.~\ref{fig:examplesFullCorrect}), only the pre-hoc method correctly diagnosed the breast (Fig.~\ref{fig:examplesFullPre}), and only the post-hoc method correctly diagnosed the breast (Fig.~\ref{fig:examplesFullPost}).

\begin{table}[]
\centering
\begin{tabular}{c|c|c|}
\cline{2-3}
\multicolumn{1}{l|}{}              & Pre-Hoc & Post-Hoc \\ \hline
\multicolumn{1}{|c|}{Breast-wise}  &   0.85  &     \textbf{0.90} \\ \hline
\multicolumn{1}{|c|}{Patient-wise} &   0.81  &     \textbf{0.91} \\ \hline
\end{tabular}
\caption{AUC comparing the diagnosis performance between pre-hoc and post-hoc measured breast-wise and patient-wise.}
\label{tab:fullDiagnosis}
\end{table}

\begin{figure}[h]
\centering\includegraphics[width=0.6\linewidth]{rocs.png}
\caption{ROC curves for malignancy diagnosis of pre-hoc and post-hoc full pipelines measures breast and patient-wise. }
\label{fig:fullDiag}
\end{figure}

\begin{figure}[h]
\centering\includegraphics[width=0.6\linewidth]{fullDet.png}
\caption{Patient-wise FROC curve for malignant lesion detection of pre-hoc and post-hoc full pipeline methods. For the post-hoc method, we present two scenarios the two scenarios (A) and (+).}
\label{fig:fullDet}
\end{figure}

\begin{figure}[h]
\centering
\subfloat[]{\includegraphics[width=0.3\linewidth]{45L82__gt_.png}\label{img11}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{45L82__pre_.png}\label{img11}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{45L82__post_.png}\label{img12}}\\
\subfloat[]{\includegraphics[width=0.3\linewidth]{57L114_GT_.png}\label{img21}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{57L114__pre_.png}\label{img21}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{57L114.png}\label{img22}}\\
\caption{Example of two correct diagnosis by both pre-hoc and post-hoc full pipeline methods. Left column is the ground truth, middle column is the result of the pre-hoc method and right column is the result of the post-hoc method. Red image frames indicate malignant diagnosis, green frames indicate non-malignant diagnosis. Detections in red indicates TP malignant detections, yellow detections indicate FP malignant detections, detections in green indicate benign lesions.
\textbf{First row:} pre-hoc and post-hoc correct positive diagnosis with the malignant lesion detected.
\textbf{Second row:} pre-hoc and post-hoc correct negative diagnosis where the pre-hoc method correctly classified as negative a detected benign lesion and the post-hoc method did not localize any malignant lesion}
\label{fig:examplesFullCorrect}
\end{figure}

\begin{figure}[h]
\centering
\subfloat[]{\includegraphics[width=0.3\linewidth]{17R111__GT_.png}\label{img31}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{17R111__pre_.png}\label{img31}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{17R111__post_.png}\label{img32}}\\
\subfloat[]{\includegraphics[width=0.3\linewidth]{19R45__gt_.png}\label{img41}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{19R45__pre_.png}\label{img41}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{19R45__post_.png}\label{img42}}\\
\caption{Example of two correct diagnosis by the pre-hoc system, but wrongly diagnosed by the post-hoc method. Left column is the ground truth, middle column is the result of the pre-hoc method and right column is the result of the post-hoc method. Red image frames indicate malignant diagnosis, green frames indicate non-malignant diagnosis. Detections in red indicate TP malignant detections, yellow detections indicate FP malignant detections, detection in blue indicates a ROI detection correctly classified as negative (non-malignant).
\textbf{First row:} correct positive diagnosis by the pre-hoc method with the malignant lesion correctly detected but incorrect non-malignant diagnosis by the post-hoc method.
\textbf{Second row:} correct negative diagnosis by the pre-hoc method, but incorrect positive diagnosis by the post-hoc system -- yielding the potential malignant regions in the rectangles shown in yellow.
\label{fig:examplesFullPre}
\end{figure}

\begin{figure}[h]
\centering
\subfloat[]{\includegraphics[width=0.3\linewidth]{25R103__gt_.png}\label{img51}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{25R103__pre_.png}\label{img51}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{25R103__post_.png}\label{img52}}\\
\subfloat[]{\includegraphics[width=0.3\linewidth]{58R66__GT_.png}\label{img61}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{58R66__pre_.png}\label{img61}}\hspace{0.07in}
\subfloat[]{\includegraphics[width=0.3\linewidth]{58R66__post_.png}\label{img62}}\\
\caption{Example of two incorrect diagnosis by the pre-hoc, but correctly diagnosed by the post-hoc method. Left column is the ground truth, middle column is the result of the pre-hoc method and right column is the result of the post-hoc method. Red image frames indicate malignant diagnosis, green frames indicate non-malignant diagnosis. Detections in red indicate TP malignant detections, yellow detections indicate FP malignant detections, detection in green indicates a benign ROI detection.
\textbf{First Row:} the pre-hoc system incorrectly diagnoses as negative, while post-hoc system correctly diagnoses as positive and yields the malignant lesion.
\textbf{Second row:} the post-hoc method correctly diagnoses as negative, but pre-hoc incorrectly diagnoses as positive due to the wrong positive classification of a detected lesion}
\label{fig:examplesFullPost}
\end{figure}

\section{Discussion}
\label{S:5}

The localization step in the pre-hoc method achieves similar accuracy to the baseline methods. As shown in Figure~\ref{fig:PreDet}, the TPR and FPR directly depends on the number of initializations used by the reinforcement learning algorithm.
In addition, the performance of our localization step is very similar to the baseline based on a multi-scale cascade using exhaustive search with deep features. However, multi-scale cascade (164s) and clustering+structure learning (several hours) methods require large inference times compared to our attention model (92s) as shown in Table~\ref{tab:preDetTimes}.

The post-hoc diagnosis step improves over several baseline methods, as shown in Table~\ref{tab:PostDiagnosis}.
These baseline methods are based on a DenseNet~\citep{huang2017densely}, specifically optimised for the breast screening classification, and on extensions derived from multiple instance learning~\citep{zhu2017deep} and multi-task learning~\citep{xue2018full}.
These results show that meta-training the model to solve tasks with small training sets is an important step to improve the learning of methods when only small datasets are available. Baseline approaches~\citep{huang2017densely,xue2018full} only show a limited improvement over the DenseNet baseline.

The localization step in our post-hoc method benefits from our definition of saliency, as shown in Figure.~\ref{fig:PostDet}.  In contrast, baseline methods show activations that do not correlate well with the target classification. In addition, baseline methods, such as CAM~\citep{zhou2016learning} and Grad-Cam~\citep{selvaraju2017grad}, suffer from the low resolution of the activation feature maps, despite the improvement achieved by Guided Grad-Cam~\citep{selvaraju2017grad}.
Measuring results only on positively classified volumes ( (+) curves in Figure~\ref{fig:PostDet}) discounts the mistakes made by the diagnosis step and provides an evaluation that isolates the lesion detection ( (A) curves in Figure~\ref{fig:PostDet}).
Note that there is no straightforward comparison between the localization steps in post-hoc methodologies (that only detects malignant lesions) and the localization step in pre-hoc methodologies (that detects benign and malignant lesions). Such malignant lesion detection comparison only makes sense in terms of the full pre-hoc and post-hoc pipelines, which is detailed below.

In terms of the full pipeline, we observe in Table~\ref{tab:fullDiagnosis} and Figure~\ref{fig:fullDiag} that the post-hoc system has a higher classification AUC than the pre-hoc for breast screening from breast DCE-MRI. The difference between these two methods is higher when measured patient-wise compared to breast-wise. It seems reasonable to think that the reason behind such discrepancy is an effect of the missed detections in pre-hoc. In difficult (small and low contrast lesions) cases with missed detections, the confidence score of malignancy of a breast is considered 0. While this effect is smaller when the AUC is measured breast-wise (as there are 118 samples of breasts), it is larger when measured patient-wise (59 samples of patients). Furthermore, the better results of the post-hoc method suggest that the analysis of the whole image allows it to find indications for malignancy that are located in other areas of the image~\citep{kostopoulos2017computer}.

Regarding the localization of malignant lesions, the pre-hoc system achieves better accuracy, compared with the post-hoc.
This suggests that the strong annotations used to train the pre-hoc method gives it an advantage for the localisation of lesions, when compared with the weak annotation used to train the post-hoc approach. This issue is exemplified in Figure~\ref{fig:examplesFullCorrect} (Row 1), where although both approaches present a correct diagnosis, the post-hoc method yields a higher number of false positive malignant lesion detections. A similar behaviour can be seen in Figure~\ref{fig:examplesFullPre} (Row 2), where the post-hoc produces an incorrect diagnosis and additionally yields two false positive detections.
In addition, the detection step for the pre-hoc system is mainly designed to achieve good performance when only a small training set is available. On the contrary, the malignant lesion localization step in the post-hoc approach is not particularly focused on being able to perform well from a small dataset. This difference in design focus is likely to be influencing the detection results too.
Finally, it is worth noting that the FROC for the post-hoc approach (Post-hoc (A) curve in Fig.~\ref{fig:fullDet}) is affected by the diagnosis process. However, if we remove the effect of the diagnosis step and consider the performance of malignant lesion localization in positively classified volumes, we observe a closer performance compared to the pre-hoc method, even though the post-hoc system is trained with weak annotations.

\section{Limitations and Future Work}
\label{S:6}

The main limitation of our work comes from the small dataset available. In addition to a larger test set, we aim to increase our dataset to include patients where no lesions are found in order to better recreate the scenario of a screening population. Ideally, this dataset will contain scanners from different vendors too.
Another limitation of this work involves the lack of cross-validation experiments. This decision is justified to allow a fair comparison with other works~\citep{maicas2017globally,maicas2017deep,maicas2018training,maicas2018lesion,mcclymont2014fully} on the same dataset.

Future work involves the improvement of the malignant lesion localization in post-hoc methodologies by designing a new method specifically for the small training set available.
We believe that the Lesion localization step in pre-hoc approaches could also be improved in terms of inference time and accuracy. As noted in~\citep{maicas2017deep}, improvements in running time can be achieved by running the different initializations of the detection algorithm in parallel and by optimizing the resizing operation of the current bounding volume.
In addition, the use of a U-net~\citep{ronneberger2015u} would allow the implementation of a faster segmentation map maintaining the detection accuracy.
Finally, it would be interesting to design a method that could diagnose based on the combined analysis of MRI and mammography.

\section{Conclusion}
\label{S:7}

We introduced and compared two different approaches for breast screening from breast DCE-MRI: pre-hoc and post-hoc methods.
The pre-hoc method localizes suspicious regions (benign and malignant lesions) using an attention model based on deep reinforcement learning.
Detected regions were subsequently classified into malignant or non-malignant lesions using a 3D DenseNet.
The post-hoc method diagnoses a DCE-MRI breast volume using a classifier that, before being trained to solve the breast screening task, has been  meta-trained to solve several breast-related tasks where only small training sets are available.
Malignant regions are then localized with a 1-class saliency detector specifically designed for post-hoc systems that perform diagnosis.
Results showed that the post-hoc method can achieve better performance for malignancy diagnosis, whereas the pre-hoc method could more precisely localize malignant lesions. However, this improvement of the pre-hoc detection method relies on the employment of  strong annotations during the training process.
On the other hand, post-hoc  methods only use weak labels during the training phase and outperforms pre-hoc methods in diagnosis, which is the main aim of a breast screening system.
In conclusion, we believe that future research should focus on the development and improvement of post-hoc diagnosis methods.

We would like to thank Nvidia for the donation of a TitanXp that supported this work.

\bibliographystyle{model2-names.bst}\biboptions{authoryear
\section*{References