diff --git a/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/69e4999c-0dda-47a8-bf21-e7202be93717_content_list.json b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/69e4999c-0dda-47a8-bf21-e7202be93717_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..72e046a29fecc07b978949b2fae7ea4c003bf3e4
--- /dev/null
+++ b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/69e4999c-0dda-47a8-bf21-e7202be93717_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:337aa7eab31cdc8339f7c4b39c1cabb80c286d489f919e8ba2f801b6a91ce06a
+size 77300
diff --git a/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/69e4999c-0dda-47a8-bf21-e7202be93717_model.json b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/69e4999c-0dda-47a8-bf21-e7202be93717_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..ad6679b3074c068af94b81d924c5a4356bdc29c6
--- /dev/null
+++ b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/69e4999c-0dda-47a8-bf21-e7202be93717_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7c53356ccc8658ce1118e83007651c2a07267d65b6c5914fd09a17b84811d30c
+size 92781
diff --git a/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/69e4999c-0dda-47a8-bf21-e7202be93717_origin.pdf b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/69e4999c-0dda-47a8-bf21-e7202be93717_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..22985ae91d3a70e0fe063f1d90ba8ff23f93069c
--- /dev/null
+++ b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/69e4999c-0dda-47a8-bf21-e7202be93717_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:dc07e8dd876b17f58b9556d33975134c831504d21b180b4c33380dc7b7b51996
+size 3577324
diff --git a/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/full.md b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..f7ba79bd25122158a34872051f22805380f57680
--- /dev/null
+++ b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/full.md
@@ -0,0 +1,326 @@
+# Draft-and-Revise: Effective Image Generation with Contextual RQ-Transformer
+
+Doyup Lee*
+
+Kakao Brain
+
+doyup.lee@kakaobrain.com
+
+Chiheon Kim*
+
+Kakao Brain
+
+chiheon.kim@kakaobrain.com
+
+Saehoon Kim
+
+Kakao Brain
+
+shkim@kakaobrain.com
+
+Minsu Cho
+
+POSTECH
+
+mscho@postech.ac.kr
+
+Wook-Shin Han†
+
+POSTECH
+
+wshan@dblab.postech.ac.kr
+
+# Abstract
+
+Although autoregressive models have achieved promising results on image generation, their unidirectional generation process prevents the resultant images from fully reflecting global contexts. To address the issue, we propose an effective image generation framework of Draft-and-Revise with Contextual RQ-transformer to consider global contexts during the generation process. As a generalized VQ-VAE, RQ-VAE first represents a high-resolution image as a sequence of discrete code stacks. After code stacks in the sequence are randomly masked, Contextual RQ-Transformer is trained to infill the masked code stacks based on the unmasked contexts of the image. Then, we propose the two-phase decoding, Draft-and-Revise, for Contextual RQ-Transformer to generate an image, while fully exploiting the global contexts of the image during the generation process. Specifically, in the draft phase, our model first focuses on generating diverse images despite rather low quality. Then, in the revise phase, the model iteratively improves the quality of images, while preserving the global contexts of generated images. In experiments, our method achieves state-of-the-art results on conditional image generation. We also validate that the Draft-and-Revise decoding can achieve high performance by effectively controlling the quality-diversity trade-off in image generation.
+
+# 1 Introduction
+
+Learning discrete representations of images enables autoregressive (AR) models to achieve promising results on image generation. Here, an image is encoded into a feature map, which is represented as a sequence of discrete codes [13, 33] or code stacks [23]. Then, an AR model generates a sequence of codes in the raster scan order and decodes the codes into an image. Consequently, AR models show high performance and scalability on large-scale datasets [13, 23, 26].
+
+Despite the promising results of AR models, we pos
+
+tulate that the ability of AR models is limited due to the lack of considering global contexts in the generation process. Specifically, since AR models generate images by sequentially predicting the
+
+
+Figure 1: Examples of image inpainting by an AR model (middle) and ours (right).
+
+next code and attending to only precedent codes generated, they neither exploit the later part of the generated image nor consider the global contexts during generation. For example, Figure 1 (middle) shows that an AR model fails to generate a coherent image, when it is asked to inpaint the masked region of Figure 1 (left) with a school bus. Such a failure is due to the inability of AR models to refer to the context of traffic lane on the right side of the masked region.
+
+To address this issue, we propose an effective image generation framework, Draft-and-Revise, with a contextual transformer to exploit the global contexts of images. Given a randomly masked image, the contextual transformer is first trained to infill the masks by bidirectional self-attention similarities similarly to BERT [8]. To fully leverage the contextual prediction in generation, we propose Draft-and-Revise decoding which has two phases, draft and revise, imitating the image generation process of a human expert who draws a draft first and iteratively revises the draft to improve its quality. In the draft phase, the model first infills an empty image to generate a draft image with diverse contents despite the rather low-quality. In the revise phase, the visual quality of the draft is iteratively improved, while the global contexts of the draft are preserved and exploited. Consequently, our Draft-and-Revise with contextual transformer effectively generates high-quality images with diverse contents.
+
+We use residual-quantized VAE (RQ-VAE) [23] to implement our image generation framework, since RQ-VAE generalizes vector-quantized VAE (VQ-VAE) [33] by representing an image as a sequence of code stacks instead of a sequence of codes. Then, we propose Contextual RQ-Transformer as a contextual transformer for masked code stack modeling of RQ-VAE. Specifically, given a sequence of randomly masked code stacks, Contextual RQ-Transformer first uses a bidirectional transformer to capture the global contexts of unmasked code stacks. Based on the global contexts, the masked code stacks are predicted in parallel, while the codes in each masked code stack are sequentially predicted. In experiments, our Draft-and-Revise framework with Contextual RQ-Transformer achieves state-of-the-art results on conditional image generation and remarkable improvements on image inpainting. In addition, we demonstrate that Draft-and-Revise decoding can effectively control the quality-diversity trade-off in image generation to achieve high performance.
+
+The main contributions of this paper are summarized as follows. 1) We propose an intuitive and powerful framework, Contextual RQ-Transformer, for masked code stack modeling of RQ-VAE based on a bidirectional transformer. 2) We propose a novel two-phase decoding, Draft-and-Revise, for bidirectional transformers to fully exploit the global contexts during image generation and achieve state-of-the-art results on class- and text-conditional image generation benchmarks. 3) An extensive ablation study validates the effectiveness of Draft-and-Revise decoding on controlling the quality-diversity trade-off and its capability to generate high-quality images with diverse contents.
+
+# 2 Related Work
+
+Discrete Representation for Image Generation By representing an image as a sequence of codes, VQ-VAE [33] becomes an important part for high-resolution image generation [6, 10, 15, 23, 26, 33], but suffers from low quality of reconstructed images. However, VQGAN [13] significantly improves the perceptual quality of reconstructed images by adding the adversarial and perceptual losses into the training objective of VQ-VAE. As a generalized approach of VQ-VAE and VQGAN, RQ-VAE [23] represents an image as a sequence of code stacks, which consists of ordered codes, and reduces the sequence length, while preserving the reconstruction quality. Then, RQ-Transformer [23] achieves high performance with lower computational costs on generating high-resolution images. However, as an AR model of RQ-VAE, RQ-Transformer cannot capture the global contexts of generated images.
+
+Generation Tasks with Bidirectional Transformers To overcome the limitation of AR models on unidirectional architecture, bidirectional transformers have been studied for generative tasks. After a bidirectional transformer is trained to infill a random mask as the masked token modeling of BERT [8], an effective decoding method has been proposed for bidirectional transformers to generate texts [14, 30], images [6, 35], or videos [16]. For image generation, M6-UFC [35] first incorporates the masked token modeling in the codes of VQGAN [13] for image generation. MaskGIT [6] proposes the confidence-based decoding to achieve high performance on ImageNet [7]. Similar to M6-UFC [35] and MaskGIT [6], we also incorporate the masked token modeling of RQ-VAE in a bidirectional transformer for image generation. However, instead of the confidence-based decoding [6, 35], we propose a novel two-phase decoding for a bidirectional transformer to achieve state-of-the-art performance and validate its effectiveness. Recently, discrete diffusion models [1, 4, 12, 15] also uses
+
+
+Tokenizing (RQ-VAE)
+
+
+Random Masking
+
+
+Contextual RQ-Transformer
+
+
+Draft-and-Revise Decoding
+
+
+Figure 2: The overview of Draft-and-Revise framework with Contextual RQ-Transformer. Our framework exploits global contexts of images to generate high-quality images with diverse contents.
+
+bidirectional transformers to generate an image, and the training with an absorbing state [1] is also the same to infill randomly masked sequence [4, 6]. However, different from the reverse process of diffusion models, our decoding method has explicit two phases to generate high-quality images with diverse contents.
+
+# 3 Draft-and-Revise Framework for Effective Image Generation
+
+In this section, we propose our Draft-and-Revise framework for effective image generation using bidirectional contexts of images. We first review RQ-VAE [23] as a generalization of VQ-VAE. Then, we propose Contextual RQ-Transformer which is trained to infill a randomly masked sequence of code stacks of RQ-VAE by understanding bidirectional contexts of unmasked parts in the sequence. Lastly, we propose draft-and-revise decoding for a bidirectional transformer to effectively generate high-quality images exploiting global contexts of images. Figure 2 provides the overview of our proposed framework, including Contextual RQ-Transformer and Draft-and-Revise decoding.
+
+# 3.1 Residual-Quantized Variational Autoencoder (RQ-VAE)
+
+RQ-VAE [23] represents an image as a sequence of code stacks. Let a codebook $\mathcal{C} = \{(k, \mathbf{e}(k))\}_{k \in [K]}$ include pairs of a code $k$ and its code embedding $\mathbf{e}(k) \in \mathbb{R}^{n_z}$ , where $K = |\mathcal{C}|$ is the codebook size and $n_z$ is the dimensionality of $\mathbf{e}(k)$ . Given a vector $\mathbf{z} \in \mathbb{R}^{n_z}$ , $\mathcal{Q}(\mathbf{z}; \mathcal{C})$ is defined as the code of $\mathbf{z}$ :
+
+$$
+\mathcal {Q} (\mathbf {z}; \mathcal {C}) = \underset {k} {\arg \min } \| \mathbf {z} - \mathbf {e} (k) \| _ {2} ^ {2}. \tag {1}
+$$
+
+Then, RQ with depth $D$ represents a vector as a code stack which consists of $D$ codes:
+
+$$
+\mathcal {R Q} (\mathbf {z}; \mathcal {C}, D) = \left(k _ {1}, \dots , k _ {D}\right) \in [ K ] ^ {D}, \tag {2}
+$$
+
+where $k_{d}$ is the $d$ -th code of $\mathbf{z}$ . Specifically, RQ first initializes the 0-th residual vector as $\mathbf{r}_0 = \mathbf{z}$ , and then recursively discretizes a residual vector $\mathbf{r}_{d-1}$ and computes the next residual vector $\mathbf{r}_d$ as
+
+$$
+k _ {d} = \mathcal {Q} \left(\mathbf {r} _ {d - 1}; \mathcal {C}\right), \quad \mathbf {r} _ {d} = \mathbf {r} _ {d - 1} - \mathbf {e} \left(k _ {d}\right), \tag {3}
+$$
+
+for $d \in [D]$ . Finally, $\mathbf{z}$ is approximated by the sum of the $D$ code embeddings $\hat{\mathbf{z}} := \sum_{d=1}^{D} \mathbf{e}(k_d)$ . We remark that RQ is a generalized version of VQ, as RQ with $D = 1$ is equivalent to VQ. For $D > 1$ , RQ conducts a finer approximation of $\mathbf{z}$ as the quantization errors are sequentially reduced as $d$ increases. Here, the coarse-to-fine approximation ensures the $D$ codes to be sequentially dependent.
+
+RQ-VAE represents an image as a map of code stacks. Specifically, a given image $\mathbf{X}$ is first converted to a low-resolution feature map $\mathbf{Z} = E(\mathbf{X}) \in \mathbb{R}^{H \times W \times n_z}$ , and then each feature vector $\mathbf{Z}_{hw}$ at spatial position $(h, w)$ is discretized into a code stack by RQ with depth $D$ . As a result, we get a map of code stacks $\mathbf{S} \in [K]^{H \times W \times D}$ . Further details of RQ-VAE are referred to Appendix.
+
+# 3.2 Contextual Transformer for Image Generation with Global Contexts
+
+As a bidirectional transformer for RQ-VAE, we propose Contextual RQ-Transformer for image generation based on a contextual understanding of images. First, we adopt the pretraining of BERT [8] to formulate a masked code stack modeling of RQ-VAE. Then, we introduce how Contextual RQ-Transformer infills the randomly masked code stacks after reading the given contextual information.
+
+# 3.2.1 Masked Code Stack Modeling of RQ-VAE
+
+By adopting the pretraining of BERT [8], we formulate the masked code stack modeling of RQ-VAE with a contextual transformer to generate an image by iterative mask-infilling as non-AR models [14]. We first convert the map $\mathbf{S} \in [K]^{H \times W \times D}$ into a sequence of code stacks $\mathbf{S}' \in [K]^{N \times D}$ using the raster-scan ordering, where $N = HW$ and $\mathbf{S}_n' = (\mathbf{S}_{n1}', \dots, \mathbf{S}_{nD}') \in [K]^D$ for $n \in [N]$ . We denote $\mathbf{S}'$ as $\mathbf{S}$ for the brevity of notation. A mask vector $\mathbf{m}$ is defined as a binary vector $\mathbf{m} \in \{0, 1\}^N$ to indicate the spatial positions to be masked. Then, the masked sequence $\mathbf{S}_{\backslash \mathbf{m}}$ of $\mathbf{S}$ by $\mathbf{m}$ is defined as
+
+$$
+\left(\mathbf {S} _ {\backslash \mathbf {m}}\right) _ {n} = \left\{ \begin{array}{l l} \mathbf {S} _ {n} & \text {i f} \mathbf {m} _ {n} = 0 \\ {[ \mathrm {M A S K} ] ^ {D}} & \text {i f} \mathbf {m} _ {n} = 1 \end{array} , \right. \tag {4}
+$$
+
+where $[\mathbf{MASK}]$ is a mask token to substitute for $\mathbf{S}_{nd}$ if $\mathbf{m}_n = 1$ . Given a random mask vector $\mathbf{m} \sim q(\mathbf{m})$ , the masked code stacks given $\mathbf{S}_{\backslash \mathbf{m}}$ are modeled as
+
+$$
+\prod_ {n: \mathbf {m} _ {n} = 1} p (\mathbf {S} _ {n} | \mathbf {S} _ {\backslash \mathbf {m}}) = \prod_ {n: \mathbf {m} _ {n} = 1} \prod_ {d = 1} ^ {D} p \left(\mathbf {S} _ {n d} | \mathbf {S} _ {n, < d}, \mathbf {S} _ {\backslash \mathbf {m}}\right), \tag {5}
+$$
+
+where $q(\mathbf{m})$ is a mask distribution where the masking portion $\sum_{n=1}^{N} \mathbf{m}_i / N$ in (0, 1] as well as the masking positions are randomly chosen. Instead of fixing the portion to $15\%$ as in BERT, training a model with a random masking portion from (0, 1] enables the model to generate new images based on various masking patterns including $\mathbf{m}_n = 1$ for all $n$ . We explain the details of $q(\mathbf{m})$ in Section 3.2.3.
+
+The left-hand side of Eq. 5 implies that all masked code stacks can be decoded in parallel based on the contexts of $\mathbf{S}_{\backslash \mathbf{m}}$ . If $D = 1$ , Eq. 5 becomes equivalent to conventional masked token modeling of texts [8] and images [6, 16] where a single token at each masked position is predicted. For $D > 1$ , the $D$ codes of $\mathbf{S}_n$ are autoregressively predicted, as they are sequentially computed in Eq. 3 for a coarse-to-fine approximation and hence well-suited for an AR prediction. We show that the effectiveness of our framework is generalizable regardless of $D$ in Appendix B. In addition, the parallel decoding can control the trade-off between the quality and sampling speed of image generation.
+
+# 3.2.2 Contextual RQ-Transformer
+
+We modify the previous RQ-Transformer [23] for masked code stack modeling with bidirectional contexts in Eq. 5. Contextual RQ-Transformer consists of Bidirectional Spatial Transformer and Depth Transformer: Bidirectional Spatial Transformer understands contextual information in the unmasked code stacks using bidirectional self-attention, and Depth Transformer infills the masked code stacks in parallel, by autoregressively predicting the $D$ codes at each position.
+
+Bidirectional Spatial Transformer Given a masked sequence of code stacks $\mathbf{S}_{\backslash \mathbf{m}}$ , bidirectional spatial transformer first embeds the masked sequence $\mathbf{S}_{\backslash \mathbf{m}}$ using the code embeddings of RQ-VAE as
+
+$$
+\mathbf {u} _ {n} = \mathrm {P E} _ {N} (n) + \left\{ \begin{array}{l l} \sum_ {d = 1} ^ {D} \mathbf {e} \left(\mathbf {S} _ {n d}\right) & \text {i f} \mathbf {m} _ {n} = 0 \\ \mathbf {e} _ {[ \text {M A S K} ]} & \text {i f} \mathbf {m} _ {n} = 1 \end{array} , \right. \tag {6}
+$$
+
+where $\mathrm{PE}_N(n)$ is an embedding for position $n$ , and $\mathbf{e}_{[\mathrm{MASK}]} \in \mathbb{R}^{n_z}$ is a mask embedding. Then, the bidirectional self-attention blocks, $f_{\theta}^{\mathrm{spatial}}$ , extracts the context vector $\mathbf{h}_n$ to predict a code stack $\mathbf{S}_n$ ,
+
+$$
+\left(\mathbf {h} _ {1}, \dots , \mathbf {h} _ {N}\right) = f _ {\theta} ^ {\text {s p a t i a l}} \left(\mathbf {u} _ {1}, \dots , \mathbf {u} _ {N}\right). \tag {7}
+$$
+
+Depth Transformer The code stack at a masked position $\mathbf{S}_n = (\mathbf{S}_{n1},\dots ,\mathbf{S}_{nD})$ is autoregressively predicted. The input of depth transformer $(\mathbf{v}_{nd})_{d = 1}^{D}$ is defined as
+
+$$
+\mathbf {v} _ {n d} = \mathrm {P E} _ {D} (d) + \left\{ \begin{array}{l l} \mathbf {h} _ {n} & \text {i f} d = 1 \\ \sum_ {d ^ {\prime} = 1} ^ {d - 1} \mathbf {e} \left(\mathbf {S} _ {n d ^ {\prime}}\right) & \text {i f} d > 1 \end{array} \right. \tag {8}
+$$
+
+Algorithm 1 UPDATE of S
+Require: A sequence of code stacks S, a partition $\Pi = (\mathbf{m}^1,\dots ,\mathbf{m}^T)$ , a model $\theta$ 1: for $t = 1,\dots ,T$ do 2: Sample $\mathbf{S}_n\sim p_\theta (\mathbf{S}_n|\mathbf{S}_{\backslash \mathbf{m}^t})$ $\forall n:\mathbf{m}_n^t = 1$ update the codes at masked positions 3: end for 4: return S
+Algorithm 2 Draft-and-Revise decoding
+Require: Partition sampling distributions $p_{\mathrm{draft}}$ and $p_{\mathrm{rev}}$ , the number of revision iterations M /* draft phase \*/ 1: $\mathbf{S}^{\mathrm{empty}}\gets ([\mathrm{MASK}],\dots ,[\mathrm{MASK}])^N$ ▷initialize empty code map 2: Sample $\Pi \sim p(\Pi ;T_{\mathrm{draft}})$ 3: $\mathbf{S}^{\mathrm{draft}}\gets \mathrm{UPDATE}(\mathbf{S}^{\mathrm{empty}},\Pi ;\theta)$ generate a draft code map /* revision phase \*/ 4: $\mathbf{S}^{0}\gets \mathbf{S}^{\mathrm{draft}}$ 5: for $m = 1,\dots ,M$ do 6: Sample $\Pi \sim p(\Pi ;T_{\mathrm{revise}})$ 7: $\mathbf{S}^{m}\gets \mathrm{UPDATE}(\mathbf{S}^{m - 1},\Pi ;\theta)$ iteratively revise the code map 8: end for 9: return $\mathbf{S}^{M}$
+
+where $\mathrm{PE}_D(d)$ is the positional embedding for depth $d$ . Then, depth transformer $f_{\theta}^{\mathrm{depth}}$ , which consists of causal attention blocks, outputs the logit $\mathbf{p}_{nd}$ to predict the $d$ -th code $\mathbf{S}_{nd}$ at position $n$ as
+
+$$
+\mathbf {p} _ {n d} = f _ {\theta} ^ {\mathrm {d e p t h}} \left(\mathbf {v} _ {n 1}, \dots , \mathbf {v} _ {n d}\right) \quad \text {a n d} \quad p _ {\theta} \left(\mathbf {S} _ {n d} = k | \mathbf {S} _ {n, < d}, \mathbf {S} _ {\backslash \mathbf {m}}\right) = \operatorname {s o f t m a x} \left(\mathbf {p} _ {n d}\right) _ {k}. \qquad (9)
+$$
+
+We remark that the architecture of Contextual RQ-Transformer subsumes bidirectional transformers. Specifically, RQ-Transformer with the depth $D = 1$ is equivalent to a bidirectional transformer since the depth transformer becomes a multilayer perceptron with layer normalization [2].
+
+# 3.2.3 Training of Contextual RQ-Transformer
+
+For the training of Contextual RQ-Transformer, let us define a mask distribution $q(\mathbf{m})$ with a mask scheduling function $\gamma$ . Following previous approaches [6, 14, 16], the scheduling function $\gamma$ is chosen to be decreasing and to satisfy $\gamma(0) = 1$ and $\gamma(1) = 0$ . Then, a mask $\mathbf{m} \sim q(\mathbf{m})$ is specified as
+
+$$
+r \sim \operatorname {U n i f} ([ 0, 1)) \quad \text {a n d} \quad \mathbf {m} \sim \operatorname {U n i f} (\{\mathbf {m}: | \mathbf {m} | = \lceil \gamma (r) \cdot N \rceil \}), \tag {10}
+$$
+
+where $|\mathbf{m}| = \sum_{n\in [N]}\mathbf{m}_n$ is the count of masked positions. Finally, the training objective of Contextual RQ-Transformer is to minimize the negative log-likelihood of masked code stacks:
+
+$$
+\mathcal {L} = \mathbb {E} _ {\mathbf {m} \sim q (\mathbf {m})} \left[ \mathbb {E} _ {\mathbf {S}} \left[ \sum_ {n: \mathbf {m} _ {n} = 1} ^ {D} \sum_ {d = 1} ^ {D} - \log p _ {\theta} \left(\mathbf {S} _ {n d} \mid \mathbf {S} _ {n, < d}, \mathbf {S} _ {\backslash \mathbf {m}}\right) \right] \right]. \tag {11}
+$$
+
+# 3.3 Draft-and-Revise: Two-Phase Decoding with Global Contexts of Generated Images
+
+We propose a novel decoding algorithm, Draft-and-Revise, for Contextual RQ-Transformer to effectively generate high-quality images with diverse visual contents. We remark that our effective decoding method is required for bidirectional transformers to fully exploit the global contexts of images and achieve high performance of image generation. Here, we introduce the details of our Draft-and-Revise decoding and then explain how the two-phase decoding of Draft-and-Revise can effectively control the quality-diversity trade-off of generated images.
+
+We define a partition $\Pi = (\mathbf{m}^1, \dots, \mathbf{m}^T)$ as a collection of pairwise disjoint $T$ mask vectors to cover all spatial positions, where $\sum_{t=1}^{T} \mathbf{m}_n^t = 1$ for all $n \in [N]$ . A partition $\Pi$ is sampled from the distribution $p(\Pi; T)$ , which is the uniform distribution over all balanced partitions with size $T$ :
+
+$$
+p (\boldsymbol {\Pi}; T) = \operatorname {U n i f} \left(\left\{\boldsymbol {\Pi} = \left(\mathbf {m} ^ {1}, \dots , \mathbf {m} ^ {T}\right): | \mathbf {m} ^ {t} | = \frac {N}{T} \forall t \in [ T ] \right\}\right). \tag {12}
+$$
+
+Table 1: FIDs, ISs, Precisions, and Recalls for class-conditional generation on ImageNet [7]. † denotes the use of pretrained classifier for rejection sampling, gradient guidance, or training.
+
+
| Params | H × W × D | FID↓ | IS↑ | Precision↑ | Recall↑ |
| BigGAN-deep [5] | 112M | - | 6.95 | 202.6 | 0.87 | 0.23 |
| StyleGAN-XL†[29] | 166M | - | 2.3 | 262.1 | 0.78 | 0.53 |
| ADM [9] | 554M | - | 10.94 | 101.0 | 0.69 | 0.63 |
| ADM-G†[9] | 608M | - | 4.59 | 186.7 | 0.82 | 0.52 |
| ImageBART [12] | 3.5B | 16×16×1 | 21.19 | 61.6 | - | - |
| VQ-Diffusion [15] | 518M | 16×16×1 | 11.89 | - | - | - |
| LDM-8 [27] | 395M | 32×32 | 15.51 | 79.03 | 0.65 | 0.63 |
| LDM-8-G†[27] | 506M | 32×32 | 7.76 | 209.52 | 0.84 | 0.35 |
| MaskGIT [6] | 227M | 16×16×1 | 6.18 | 182.1 | 0.80 | 0.51 |
| VQ-GAN [13] | 1.4B | 16×16×1 | 15.78 | 74.3 | - | - |
| RQ-Transformer [23] | 1.4B | 8×8×4 | 8.71 | 119.0 | 0.71 | 0.58 |
| RQ-Transformer [23] | 3.8B | 8×8×4 | 7.55 | 134.0 | 0.73 | 0.58 |
| RQ-Transformer†[23] | 3.8B | 8×8×4 | 3.80 | 323.7 | 0.82 | 0.50 |
| Contextual RQ-Transformer | 333M | 8×8×4 | 5.45 | 172.6 | 0.81 | 0.49 |
| Contextual RQ-Transformer | 821M | 8×8×4 | 3.45 | 221.9 | 0.82 | 0.52 |
| Contextual RQ-Transformer | 1.4B | 8×8×4 | 3.41 | 224.6 | 0.79 | 0.54 |
| Validation Data | - | - | 1.62 | 234.0 | 0.75 | 0.67 |
+
+We first define a procedure UPDATE(S, II) to update the sequence S as described in Algorithm 1, which updates $\mathbf{S}_n$ with $\mathbf{m}_n^t = 1$ for $t \in [T]$ . Then, Draft-and-Revise decoding in Algorithm 2 generates a draft from the empty sequence of code stacks and improves the quality of the draft.
+
+Draft phase In the draft phase, our model gradually infills the empty sequence of code stacks to generate a draft image, considering the global contexts of filled code stacks. Let $\mathbf{S}^{\mathrm{empty}}$ be an empty sequence of code stacks with $\mathbf{S}_n^{\mathrm{empty}} = [\mathbf{MASK}]^D$ for all $n$ . Given a partition size $T_{\mathrm{draft}}$ , our model generates a draft image as
+
+$$
+\mathbf {S} ^ {\text {d r a f}} = \operatorname {U P D A T E} \left(\mathbf {S} ^ {\text {e m p t y}}, \boldsymbol {\Pi}; \theta\right) \quad \text {w h e r e} \quad \boldsymbol {\Pi} \sim p (\boldsymbol {\Pi}; T _ {\text {d r a f}}). \tag {13}
+$$
+
+Revise phase The generated draft $\mathbf{S}^{\mathrm{draft}}$ is repeatedly revised to improve the visual quality of the image, while preserving the overall structure of the draft. Given a partition size $T_{\mathrm{revise}}$ and the number of updates $M$ , the draft $\mathbf{S}^{0} = \mathbf{S}^{\mathrm{draft}}$ is repeatedly updated $M$ times as
+
+$$
+\mathbf {S} ^ {m} = \operatorname {U P D A T E} \left(\mathbf {S} ^ {m - 1}, \boldsymbol {\Pi}; \theta\right) \quad \text {w h e r e} \quad \boldsymbol {\Pi} \sim p (\boldsymbol {\Pi}; T _ {\text {r e v i s e}}) \quad \text {f o r} m = 1, \dots , M. \tag {14}
+$$
+
+Note that Draft-and-Revise is not a tailored method, since we can adopt any mask-infilling-based generation method [4, 6] for UPDATE in Algorithm 1. For example, confidence-based decoding [6, 16], which iteratively updates S from high-confidence to low-confidence predictions, can be used for UPDATE. However, we find that confidence-based decoding generates low-diversity images with oversimplified contents, since a model tends to predict simple visual patterns with high confidence. In addition, confidence-based decoding often leads to biased unmasking patterns, which are not used in training. We attach the detailed discussion about confidence-based decoding in Appendix C. Thus, we use a uniformly random partition $\Pi$ in UPDATE as the most simplified rule, leaving investigations on sophisticated update methods as future work.
+
+We postulate that our Draft-and-Revise can generate high-quality images with diverse contents by explicitly dividing two phases. Specifically, a model first generates draft images with diverse visual contents despite the rather low quality of drafts. After semantically diverse images are generated as drafts, we use sampling strategies such as temperature scaling [19] and classifier-free guidance [20] in the revise phase to improve the visual quality of the drafts, while preserving the major semantic contents in drafts. Thus, our method can improve the performance of image generation by effectively controlling the quality-diversity trade-off. In addition, we emphasize that the two-phased decoding is intuitive and resembles the image generation process of human experts, who repeatedly refine their works to improve the quality after determining the overall contents first.
+
+
+Figure 3: The examples of generated $256 \times 256$ images of our model trained on (Top) ImageNet and (Bottom) CC-3M. The used text conditions are "Sunset over the skyline of a {beach, city}.", "an avocado {in the desert, on the seashore}.", and "a painting of a {dog, cat} with sunglasses."
+
+# 4 Experiments
+
+In this section, we show that our Draft-and-Revise with Contextual RQ-Transformer can outperform previous approaches for class- and text-conditional image generation. In addition, we conduct an extensive ablation study to understand the effects of Draft-and-Revise decoding on the quality and diversity of generated images, and the sampling speed. We use the publicly released RQ-VAE [23] to represent a $256 \times 256$ resolution of images as $8 \times 8 \times 4$ codes. For a fair comparison, we make Contextual RQ-Transformer have the same model size as the previous RQ-Transformer [23]. For training, the quarter-period of cosine is used as the mask scheduling function $\gamma$ in Eq. 10 following the previous studies [6, 24]. We include the implementation details in Appendix.
+
+# 4.1 Class-conditional Image Generation
+
+We train Contextual RQ-Transformer with 333M, 821M, and 1.4B parameters on ImageNet [7] for class-conditional image generation. For Draft-and-Revise decoding, we use $T_{\mathrm{draft}} = 64$ , $T_{\mathrm{revise}} = 2$ , and $M = 2$ . We use temperature scaling [19] and classifier-free guidance [20] only in the revise phase, while none of the strategies are applied in the draft phase. Fréchet Inception Distance (FID) [18], Inception Score (IS) [28], and Precision and Recall [22] are used for evaluation measures.
+
+Table 1 shows that Contextual RQ-Transformer significantly outperforms the previous approaches. Notably, Contextual RQ-Transformer with 333M parameters outperforms RQ-Transformers with 1.4B and 3.8B parameters on all evaluation measures, despite having only about $4.2 \times$ and $11.4 \times$ fewer parameters. In addition, the performance is improved as the number of parameters increases to 821M and 1.4B. Our model with 333M parameters is competitive with MaskGIT [6], and hence we conduct additional analysis on the effect of confidence-based decoding in Appendix C. Contextual RQ-Transformer can achieve the lower FID score without a pretrained classifier than ADM-G and 3.8B parameters of RQ-Transformer with the use of pretrained classifier. StyleGAN-XL also uses a pretrained classifier during both training and image generation and achieves the lowest FID in Table 1. However, our model with 1.4B parameters has higher precision and recall than StyleGAN-XL, implying that our model generates images of better fidelity and diversity without a pretrained classifier. Our high performance without a classifier is remarkable, since the gradient guidance and rejection sampling are the tailored techniques to the model-based evaluation metrics in Table 1. Considering that the performance is marginally improved as the number of parameters increases from 821M to 1.4B, an improved RQ-VAE can boost the performance of Contextual RQ-Transformer, since the reconstruction quality determines the best results of generated images.
+
+# 4.2 Text-conditional Image Generation
+
+We train our model with 333M and 654M parameters on CC-3M [32] for text-to-image (T2I) generation as described in Appendix A. A text condition is encoded into 32 tokens using Byte Pair Encoding [31, 34]. We report CLIP-score [25] with ViT-B/32 [11] as the correspondence between texts and images.
+
+
+(a)
+
+
+(b)
+
+
+(c)
+
+
+Figure 4: Ablation study of Draft-and-Revise decoding. (a) FIDs with the partition sizes of the draft phase $T_{\mathrm{draft}}$ . (b) Precision and recall with the revision iterations $M$ . (c) FID with $T_{\mathrm{revise}}$ .
+Figure 5: Examples of generated images in the draft phase (left) and revise phases at each iteration $M = 1,2,3,4,5$ . The draft images are generated with $T_{\mathrm{draft}} = 8$ (top) and $T_{\mathrm{draft}} = 64$ (bottom).
+
+Contextual RQ-Transformer in Table 2 outperforms the previous T2I generation models. Contextual RQ-Transformer with 333M parameters achieves better FID than RQ-Transformer with 654M parameters, and outperforms ImageBART and LDM-4, although our model has $12\times$ fewer parameters than ImageBART. When we increase the number of parameters to 654M, our model achieves state-of-the-art FID on CC3M. In Figure 3, our model generates images with unseen texts in CC-3M.
+
+Table 2: FIDs and CLIP scores [25] on the validation dataset of CC-3M [32] for T2I generation.
+
+ | Params | FID↓ | CLIP-s↑ |
| VQ-GAN [13] | 600M | 28.86 | 0.20 |
| ImageBART [12] | 2.8B | 22.61 | 0.23 |
| LDM-4 [27] | 645M | 17.01 | 0.24 |
| RQ-Transformer [23] | 654M | 12.33 | 0.26 |
| Ours | 333M | 10.44 | 0.26 |
| Ours | 654M | 9.80 | 0.26 |
+
+# 4.3 Conditional Image Inpainting
+
+We conduct conditional image inpainting where a model infills a masked area according to the given condition and contexts. Figure 1 shows the example of image inpainting by RQ-Transformer (middle) and Contextual RQ-Transformer (right), when the class-condition is school bus. RQ-Transformer cannot attend to the right and bottom sides of the masked area and fails to generate a coherent image with given contexts. However, our model can complete the image to be coherent with given contexts by exploiting global contexts. We attach more examples of image inpainting in Appendix.
+
+# 4.4 Ablation Study on Draft-and-Revise
+
+We conduct an extensive ablation study to demonstrate the effectiveness of Draft-and-Revise decoding of our framework. We use Contextual RQ-Transformer with 821M parameters trained on ImageNet.
+
+Quality improvement of draft images in the revise phase Figure 4(a) shows the effects of $T_{\mathrm{draft}}$ on draft images and their quality improvement in the revised phase with $T_{\mathrm{revise}} = 2$ and $M = 2$ .
+
+In the draft phase, FID is improved as $T_{\mathrm{draft}}$ increases from 4 to 64. At each inference, Contextual RQ-Transformer generates $N / T_{\mathrm{draft}}$ code stacks in parallel, starting with the empty sequence. Thus, the model with a large $T_{\mathrm{draft}}$ generates a small number of code stacks at each inference and can avoid generating incoherent code stacks in the early stage of the draft phase. Although FIDs in the draft phase are worse due to low precision, we intend to increase the diversity of generated images, since the precision is significantly improved in the revise phase as shown in Figure 4(b).
+
+Effect of revision iteration $M$ and partition size $T_{\text{revise}}$ in the revise phase Figure 4(b) shows the effects of the number of updates $M$ in the revise phase on the quality and diversity of generated images. Since the quality-diversity trade-off exists as the updates are repeated, we select $M = 2$ as the default hyperparameter to balance the precision and recall, considering that the increase of precision starts to slow down. Interestingly, Figure 5 shows that the overall contents remain unchanged even after $M > 2$ . Thus, we claim that Draft-and-Revise decoding does not harm the perceptual diversity of generated images throughout the revise phase despite the consistent deterioration of recall.
+
+Figure 4(c) shows the effects of $T_{\mathrm{revise}}$ on the quality of generated images. The FIDs are significantly improved in the revise phase regardless of the choice of $T_{\mathrm{revise}}$ , but increasing $T_{\mathrm{revise}}$ slightly deteriorates FIDs. We remark that some code stacks of a draft can be erroneous due to its low quality, and a model with large $T_{\mathrm{revise}}$ slowly updates a small number of code stacks at once in the revise phase. Therefore, the updates with large $T_{\mathrm{revise}}$ can be more influenced by the erroneous code stacks. Although $T_{\mathrm{revise}} = 2$ updates half of an image at once, our draft-and-revise decoding successfully improves the quality of generated images, while preserving the global contexts of drafts, as shown in Figure 5. The study on self-supervised learning [17] also reports similar results, where a masked auto-encoder reconstructs the global contexts of an image after masking half of the image.
+
+Quality-diversity control of Draft-and-Revise Our Draft-and-Revise decoding can effectively control the quality-diversity trade-off in generated images. Table 3 shows FID, precision (P), and recall (R) according to the use of classifier-free guidance [20] with a scale of 1.8, while applying temperature scaling with 0.8 only to the revise phase. Contextual RQ-Transformer without the guidance already outperforms RQ-Transformer with 3.8B parameters and demonstrates the effectiveness of our framework. When the guidance is used for both draft and
+
+revise phases, the precision dramatically increases but the recall decreases to 0.33. Consequently, FID becomes worse due to the lack of diversity in generated images. However, when the guidance is applied only to the revise phase, our model achieves the lowest FID, as the quality and diversity are well-balanced. Thus, the explicitly separated two phases of Draft-and-Revise can effectively control the issue of quality-diversity trade-off by generating diverse drafts and then improving their quality.
+
+Table 3: The effects of classifier-free guidance on the image generation.
+
+| Draft | Revise | FID | P | R |
| | 5.78 | 0.72 | 0.58 |
| ✓ | 3.45 | 0.82 | 0.52 |
| ✓ | ✓ | 8.90 | 0.92 | 0.33 |
+
+Trade-off between quality and sampling speed Table 4 shows that our framework can control the trade-off between the quality and sampling speed according to $T_{\mathrm{draft}}$ after we fix $T_{\mathrm{revise}} = 2$ and $M = 2$ . We generate 5,000 samples with batch size of 100 as the previous study [23]. Contextual RQ-Transformer with $T_{\mathrm{draft}} = 8$ outperforms both FID and sampling speed of VQGAN and RQ-Transformer with 1.4B parameters. Although the sampling speed becomes slow with increased $T_{\mathrm{draft}}$ , the FID scores are consistently improved. We remark that the sampling speed with $T_{\mathrm{draft}} = 64$ is about $3\times$ slower than RQ-Transformer, but our model outperforms 3.8B parameters of RQ-Transformer with rejec
+
+tion sampling in Table 1. The results show that our framework has inexpensive costs to generate high-quality images, considering that rejection sampling requires generating up to $20\times$ more samples.
+
+Table 4: Comparison of FID and the sampling speed of image generation.
+
+ | FID | s/sample |
| VQGAN | 15.78 | 0.16 |
| RQ-Transformer | 8.71 | 0.04 |
| Contextual RQ-Transformer |
| \(T_{\text{draft}}=8\) | 5.41 | 0.03 |
| \(T_{\text{draft}}=32\) | 3.73 | 0.06 |
| \(T_{\text{draft}}=64\) | 3.45 | 0.10 |
+
+# 5 Conclusion
+
+In this study, we have proposed Draft-and-Revise for an effective image generation framework with Contextual RQ-Transformer. After an image is represented as a sequence of code stacks, Contextual RQ-Transformer is trained to infill a randomly masked sequence. Then, Draft-and-Revise decoding is used to generate high-quality images by first generating a draft image with diverse contents and then improving its visual quality based on the global contexts of the draft. Consequently, we can achieve state-of-the-art results on ImageNet and CC-3M, demonstrating the effectiveness of our framework.
+
+Our study has two main limitations to be further explored. Firstly, Draft-and-Revise decoding always updates all code stacks in the revise phase, although some code stacks might not need an update. In future work, a selective method can be developed to improve the efficiency of the revise phase by a sophisticated approach. Secondly, our generative model is not validated on various downstream tasks. Since masked token modeling is successful self-supervised learning for texts [8] and images [3, 17], a unified model for both generative and discriminative tasks [21] is worth exploration for future work.
+
+# 6 Acknowledgements
+
+This work was supported by Institute of Information & communications Technology Planning & Evaluation(IITP) grant funded by the Korea government(MSIT) (No.2018-0-01398: Development of a Conversational, Self-tuning DBMS, 35%; No.2021-0-00537: Visual Common Sense, 30%) and the National Research Foundation of Korea(NRF) grant funded by the Korea government(MSIT) (No. NRF-2021R1A2B5B03001551, 35%)
+
+# References
+
+[1] Jacob Austin, Daniel D Johnson, Jonathan Ho, Daniel Tarlow, and Rianne van den Berg. Structured denoising diffusion models in discrete state-spaces. Advances in Neural Information Processing Systems, 34:17981-17993, 2021.
+[2] Jimmy Lei Ba, Jamie Ryan Kiros, and Geoffrey E Hinton. Layer normalization. arXiv preprint arXiv:1607.06450, 2016.
+[3] Hangbo Bao, Li Dong, Songhao Piao, and Furu Wei. BEit: BERT pre-training of image transformers. In International Conference on Learning Representations, 2022.
+[4] Sam Bond-Taylor, Peter Hessey, Hiroshi Sasaki, Toby P Breckon, and Chris G Willcocks. Unleashing transformers: Parallel token prediction with discrete absorbing diffusion for fast high-resolution image generation from vector-quantized codes. arXiv preprint arXiv:2111.12701, 2021.
+[5] Andrew Brock, Jeff Donahue, and Karen Simonyan. Large scale GAN training for high fidelity natural image synthesis. In International Conference on Learning Representations, 2019.
+[6] Huiwen Chang, Han Zhang, Lu Jiang, Ce Liu, and William T. Freeman. Maskgit: Masked generative image transformer. In The IEEE Conference on Computer Vision and Pattern Recognition (CVPR), June 2022.
+[7] Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. Imagenet: A large-scale hierarchical image database. In 2009 IEEE conference on computer vision and pattern recognition, pages 248–255. IEEE, 2009.
+[8] Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. Bert: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171–4186, 2019.
+[9] Prafulla Dhariwal and Alexander Nichol. Diffusion models beat gans on image synthesis. Advances in Neural Information Processing Systems, 34, 2021.
+
+[10] Ming Ding, Zhuoyi Yang, Wenyi Hong, Wendi Zheng, Chang Zhou, Da Yin, Junyang Lin, Xu Zou, Zhou Shao, Hongxia Yang, et al. Cogview: Mastering text-to-image generation via transformers. Advances in Neural Information Processing Systems, 34, 2021.
+[11] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, et al. An image is worth 16x16 words: Transformers for image recognition at scale. arXiv preprint arXiv:2010.11929, 2020.
+[12] Patrick Esser, Robin Rombach, Andreas Blattmann, and Bjorn Ommer. Imagebart: Bidirectional context with multinomial diffusion for autoregressive image synthesis. Advances in Neural Information Processing Systems, 34, 2021.
+[13] Patrick Esser, Robin Rombach, and Bjorn Ommer. Taming transformers for high-resolution image synthesis. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 12873-12883, 2021.
+[14] Marjan Ghazvininejad, Omer Levy, Yinhan Liu, and Luke Zettlemoyer. Mask-predict: Parallel decoding of conditional masked language models. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 6112-6121, 2019.
+[15] Shuyang Gu, Dong Chen, Jianmin Bao, Fang Wen, Bo Zhang, Dongdong Chen, Lu Yuan, and Baining Guo. Vector quantized diffusion model for text-to-image synthesis. In The IEEE Conference on Computer Vision and Pattern Recognition (CVPR), June 2022.
+[16] Ligong Han, Jian Ren, Hsin-Ying Lee, Francesco Barbieri, Kyle Olszewski, Shervin Minaee, Dimitris Metaxas, and Sergey Tulyakov. Show me what and tell me how: Video synthesis via multimodal conditioning. In The IEEE Conference on Computer Vision and Pattern Recognition (CVPR), June 2022.
+[17] Kaiming He, Xinlei Chen, Saining Xie, Yanghao Li, Piotr Dólár, and Ross Girshick. Masked autoencoders are scalable vision learners. arXiv preprint arXiv:2111.06377, 2021.
+[18] Martin Heusel, Hubert Ramsauer, Thomas Unterthiner, Bernhard Nessler, and Sepp Hochreiter. Gans trained by a two time-scale update rule converge to a local nash equilibrium. Advances in neural information processing systems, 30, 2017.
+[19] Geoffrey Hinton, Oriol Vinyals, Jeff Dean, et al. Distilling the knowledge in a neural network. arXiv preprint arXiv:1503.02531, 2(7), 2015.
+[20] Jonathan Ho and Tim Salimans. Classifier-free diffusion guidance. In NeurIPS 2021 Workshop on Deep Generative Models and Downstream Applications, 2021.
+[21] Saehoon Kim, Sungwoong Kim, and Juho Lee. Hybrid generative-contrastive representation learning. arXiv preprint arXiv:2106.06162, 2021.
+[22] Tuomas Kynkänniemi, Tero Karras, Samuli Laine, Jaakko Lehtinen, and Timo Aila. Improved precision and recall metric for assessing generative models. In H. Wallach, H. Larochelle, A. Beygelzimer, F. d'Alché-Buc, E. Fox, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 32. Curran Associates, Inc., 2019.
+[23] Doyup Lee, Chiheon Kim, Saehoon Kim, Minsu Cho, and Wook-Shin Han. Autoregressive image generation using residual quantization. In The IEEE Conference on Computer Vision and Pattern Recognition (CVPR), June 2022.
+[24] Alexander Quinn Nichol and Prafulla Dhariwal. Improved denoising diffusion probabilistic models. In International Conference on Machine Learning, pages 8162-8171. PMLR, 2021.
+[25] Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, Gretchen Krueger, and Ilya Sutskever. Learning transferable visual models from natural language supervision. In Marina Meila and Tong Zhang, editors, Proceedings of the 38th International Conference on Machine Learning, volume 139 of Proceedings of Machine Learning Research, pages 8748-8763. PMLR, 18-24 Jul 2021.
+
+[26] Aditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray, Chelsea Voss, Alec Radford, Mark Chen, and Ilya Sutskever. Zero-shot text-to-image generation. In Marina Meila and Tong Zhang, editors, Proceedings of the 38th International Conference on Machine Learning, volume 139 of Proceedings of Machine Learning Research, pages 8821-8831. PMLR, 18-24 Jul 2021.
+[27] Robin Rombach, Andreas Blattmann, Dominik Lorenz, Patrick Esser, and Björn Ommer. High-resolution image synthesis with latent diffusion models, 2021.
+[28] Tim Salimans, Ian Goodfellow, Wojciech Zaremba, Vicki Cheung, Alec Radford, Xi Chen, and Xi Chen. Improved techniques for training gans. In D. Lee, M. Sugiyama, U. Luxburg, I. Guyon, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 29. Curran Associates, Inc., 2016.
+[29] Axel Sauer, Katja Schwarz, and Andreas Geiger. Stylegan-xl: Scaling stylegan to large diverse datasets. arXiv preprint arXiv:2202.00273, 2022.
+[30] Nikolay Savinov, Junyoung Chung, Mikolaj Binkowski, Erich Elsen, and Aaron van den Oord. Step-unrolled denoising autoencoders for text generation. In International Conference on Learning Representations, 2022.
+[31] Rico Senrich, Barry Haddow, and Alexandra Birch. Neural machine translation of rare words with subword units. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1715-1725, 2016.
+[32] Piyush Sharma, Nan Ding, Sebastian Goodman, and Radu Soricut. Conceptual captions: A cleaned, hypernymed, image alt-text dataset for automatic image captioning. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 2556–2565, Melbourne, Australia, July 2018. Association for Computational Linguistics.
+[33] Aaron van den Oord, Oriol Vinyals, and koray kavukcuoglu. Neural discrete representation learning. In I. Guyon, U. V. Luxburg, S. Bengio, H. Wallach, R. Fergus, S. Vishwanathan, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 30. Curran Associates, Inc., 2017.
+[34] Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierrick Cistac, Tim Rault, Rémi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander M. Rush. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45, Online, October 2020. Association for Computational Linguistics.
+[35] Zhu Zhang, Jianxin Ma, Chang Zhou, Rui Men, Zhikang Li, Ming Ding, Jie Tang, Jingren Zhou, and Hongxia Yang. UFC-BERT: Unifying multi-modal controls for conditional image synthesis. In A. Beygelzimer, Y. Dauphin, P. Liang, and J. Wortman Vaughan, editors, Advances in Neural Information Processing Systems, 2021.
\ No newline at end of file
diff --git a/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/images.zip b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..6df968cb0739cb730bafeac2bdb5510f4eca2fb5
--- /dev/null
+++ b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:00ad02b71ecb7af546fa896c6cbaa4a9a304e5eec1293be2d80a3560001da0da
+size 502407
diff --git a/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/layout.json b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..d71cb8704cbdd48726e41119aa3b1d0e554d4681
--- /dev/null
+++ b/draftandreviseeffectiveimagegenerationwithcontextualrqtransformer/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6ae9d7d7971b0b30b59c249fad1c3f06daed06d0d62080ac2d9df65748243161
+size 434228
diff --git a/drawingoutofdistributionwithneurosymbolicgenerativemodels/005c4d28-ffc7-46e2-81d4-52d16d0e294e_content_list.json b/drawingoutofdistributionwithneurosymbolicgenerativemodels/005c4d28-ffc7-46e2-81d4-52d16d0e294e_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..0380b1239a0da917c0e1f83f8a105fe6cb349748
--- /dev/null
+++ b/drawingoutofdistributionwithneurosymbolicgenerativemodels/005c4d28-ffc7-46e2-81d4-52d16d0e294e_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:433c59c59af53e1c7d1a79a27612dc4b1359b59412cce5edc7fbec0ef5a443be
+size 65386
diff --git a/drawingoutofdistributionwithneurosymbolicgenerativemodels/005c4d28-ffc7-46e2-81d4-52d16d0e294e_model.json b/drawingoutofdistributionwithneurosymbolicgenerativemodels/005c4d28-ffc7-46e2-81d4-52d16d0e294e_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..4b3cd5172b9654ddd2d8535e14e8b7237893fbda
--- /dev/null
+++ b/drawingoutofdistributionwithneurosymbolicgenerativemodels/005c4d28-ffc7-46e2-81d4-52d16d0e294e_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bbdb3aad97605af8d133a98134f942fff6de43fe21153eb58b5a7da5b51cf291
+size 77714
diff --git a/drawingoutofdistributionwithneurosymbolicgenerativemodels/005c4d28-ffc7-46e2-81d4-52d16d0e294e_origin.pdf b/drawingoutofdistributionwithneurosymbolicgenerativemodels/005c4d28-ffc7-46e2-81d4-52d16d0e294e_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..07584377f1c71a611e66b808661fe0aadaab3470
--- /dev/null
+++ b/drawingoutofdistributionwithneurosymbolicgenerativemodels/005c4d28-ffc7-46e2-81d4-52d16d0e294e_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:69979fddd8e6665df7e574a09c8e09e71ac4db51e4afeb4745684709e24929d8
+size 4266154
diff --git a/drawingoutofdistributionwithneurosymbolicgenerativemodels/full.md b/drawingoutofdistributionwithneurosymbolicgenerativemodels/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..a3be5bf6e521ca5811f8e1ae66f5580d289fb109
--- /dev/null
+++ b/drawingoutofdistributionwithneurosymbolicgenerativemodels/full.md
@@ -0,0 +1,245 @@
+# Drawing out of Distribution with Neuro-Symbolic Generative Models
+
+Yichao Liang $^{1,2}$ , Joshua B. Tenenbaum $^{2}$ , Tuan Anh Le $^{*,3}$ & N. Siddharth $^{*,4}$
+
+1University of Oxford, 2MIT, 3Google, 4University of Edinburgh
+
+# Abstract
+
+Learning general-purpose representations from perceptual inputs is a hallmark of human intelligence. For example, people can write out numbers or characters, or even draw doodles, by characterizing these tasks as different instantiations of the same generic underlying process—compositional arrangements of different forms of pen strokes. Crucially, learning to do one task, say writing, implies reasonable competence at another, say drawing, on account of this shared process. We present Drawing out of Distribution (DooD), a neuro-symbolic generative model of stroke-based drawing that can learn such general-purpose representations. In contrast to prior work, DooD operates directly on images, requires no supervision or expensive test-time inference, and performs unsupervised amortised inference with a symbolic stroke model that better enables both interpretability and generalization. We evaluate DooD on its ability to generalise across both data and tasks. We first perform zero-shot transfer from one dataset (e.g. MNIST) to another (e.g. Quickdraw), across five different datasets, and show that DooD clearly outperforms different baselines. An analysis of the learnt representations further highlights the benefits of adopting a symbolic stroke model. We then adopt a subset of the Omniglot challenge tasks, and evaluate its ability to generate new exemplars (both unconditionally and conditionally), and perform one-shot classification, showing that DooD matches the state of the art. Taken together, we demonstrate that DooD does indeed capture general-purpose representations across both data and task, and takes a further step towards building general and robust concept-learning systems.
+
+# 1 Introduction
+
+Humans can learn representations of data that are general-purpose and meaningful. Being general-purpose permits effective reuse when characterizing novel observations, and being meaningful facilitates tasks like generating or classifying observations. Key to this is a generic process for characterizing observations—inferring what features are relevant and how they compose to generate the observations [9, 13, 33]. For example, when observing handwritten numbers, we learn to characterise them as sequential compositions (how) of different pen strokes (what). This is general-purpose as it allows characterizing novel observations, say doodles instead of numbers, simply as novel compositions of previously learnt pen strokes. It is also meaningful since pen-strokes themselves are symbolic and interpretable.
+
+
+Figure 1: DooD trained on MNIST generalises to other data with no extra training. Each column denotes a target and its step-by-step reconstruction.
+
+Current computational approaches capture important aspects of generalizability, but none of these is simultaneously efficient, reliable, interpretable, and unsupervised [25]. At one end, symbolic approaches like Lake et al. [24] attribute generalization to an explicit hierarchical composition process involving sub-strokes, strokes, and characters, and build concomitant models that demonstrate human-like generalization abilities across different tasks. At the other end, neural approaches like deep generative models [9, 18, 29] and deep meta-learning [11, 32, 34] favour scalable learning from raw
+
+
+Figure 2: The generative model sequentially samples both an image location $(l_{t})$ and a corresponding stroke $(s_t)$ at that location. The rendered stroke $x_{t}$ is composited onto intermediate rendering $x_{< t}$ to produce $x_{\leq t}$ . A binary on/off variable $(o_{t})$ determines when to continue drawing. Differentiable rendering $(\delta \bar{R})$ and differentiable affine transformations via Spatial Transformer Networks (STNs) [20] enables gradient-based learning. The recognition model conditions on a residual $\Delta x_{t} = x - x_{< t}$ to sample where to draw next $(l_{t})$ and what to draw next $(s_{t})$ , and whether to continue drawing $(o_{t})$ . Both models are autoregressive via two (shared) RNNs with hidden states $h_t^s$ and $h_t^l$ .
+
+
+
+
+
+perceptual data, unfettered by explicit representational biases such as strokes and their compositions. Each comes with its own shortcomings—symbolic approaches typically need additional supervision or data processing along with expensive special-purpose inference, and neural approaches fail to generalise well and don't capture interpretable representations. Neuro-symbolic approaches [10] seek to make the best of both worlds by judiciously combining neural processing of raw perceptual inputs with symbolic processing of extracted features, but typically involve a different set of trade-offs.
+
+We present Drawing out of Distribution (DooD), a neuro-symbolic generative model of stroke-based drawing that can learn general-purpose representations (Fig. 1). Our model operates directly on images, requires no supervision, pre-processing, or expensive test-time inference, and performs efficient amortised inference with a symbolic stroke model that helps with both interpretability and generalization, setting us apart from the current state-of-the-art in neuro-symbolic approaches [10, 17]. We evaluate on two axes (a) generalization across data, which measures how well the learnt representations can be reused to characterise out-of-distribution data, and (b) generalization across task, where we measure how useful the learnt representations are for auxiliary tasks drawn from the Omniglot challenge set [24]. We show that DooD significantly outperforms baselines on generalization across datasets, highlighting the quality of the learnt representations as a factor, and on generalization across tasks, show that it outperforms neural models, while being competitive against SOTA neuro-symbolic models without requiring additional support such as supervision or data augmentation.
+
+# 2 Method
+
+The framework for DooD involves a generative model over sequences of strokes and their layouts, a recognition model that conditions on a given observation to predict where to place what strokes, and an amortised variational-inference learning setup that uses these models to estimate an evidence lower bound (ELBO) as the objective.
+
+# 2.1 Generative Model
+
+Conceptually, the model can be seen as drawing a figure over a sequence of steps, building up to the final image (as seen in Fig. 1). At each step $t$ the model identifies a region of the image canvas to draw in, puts down Bezier curve control points within that region, renders the curve in a differentiable manner, and then composites this rendered stroke over the previously rendered canvas. We refer to these as the layout, stroke, rendering, and compositing modules respectively (elaborated below).
+
+The model sits on a substrate of recurrent neural networks (RNNs), one each for the layout and stroke modules, with hidden states $h_t^l$ and $h_t^s$ respectively. The complete setup is depicted in Fig. 2 along with example values (images) for the different variables involved. See Appendix B for details.
+
+Formally, the generative model defines a joint distribution over an image $x$ composed over $T$ steps, with latent variables $l_{t}$ and $s_t$ that characterise a stroke's location and form, and a binary latent variable $o_{t}$ that determines stopping, as
+
+$$
+\begin{array}{l} p (x, l _ {\leq T}, s _ {\leq T}, o _ {\leq T + 1}) \\ = \left(\prod_ {t = 1} ^ {T} p _ {\text {o n}} \left(o _ {t} \mid x _ {< t}\right) p _ {\text {s t r o k e}} \left(s _ {t} \mid l _ {t}, \tilde {x} _ {< t}, h _ {t} ^ {s}\right) p _ {\text {l a y o u t}} \left(l _ {t} \mid x _ {< t}, h _ {t} ^ {l}\right)\right) p _ {\text {c o m p}} \left(x \mid x _ {\leq T}\right) p _ {\text {o n}} \left(o _ {T + 1} \mid x _ {\leq T}\right), \tag {1} \\ \end{array}
+$$
+
+where terminal step $T$ is the last $t$ where $o_{t} = 1$ , $x_{t}$ the rendered stroke given $(s_{t},l_{t})$ , $x_{| MNIST .134 ± .013 | EMNIST .137 ± .006 | KMNIST .123 ± .020 | QuickDraw .084 ± .009 | Omniglot (DooD) .051 ± .007 | Omniglot (GNS[10]) .133 ± .007 | Omniglot (True) .025 ± .004 |
| 7 9 8 | # | # | # | # | H | # |
| 2 5 7 | # | # | # | # | L | # |
| 2 1 4 | # | # | # | # | O | # |
| 2 7 0 | # | # | # | # | d | # |
+
+Figure 6: DooD generates high quality unconditional character samples for all datasets which are visually indistinguishable from the real characters as it successfully captures the layout of strokes and their forms. Omniglot samples are compared to GNS [10] and real samples. Numbers denote Fréchet inception distance (FID), with smaller being better (mean $\pm 1$ std. over 5 runs).
+
+
+Figure 7: Given a target image of a handwritten Omniglot character, our model produces realistic new exemplars by inferring an explicit stroke-based representation.
+
+
+Figure 8: Given a partially drawn character, our model can generate a realistic distribution over its completions by sampling from the generative model conditioned on the image of the partial character.
+
+our recognition model, and produce different exemplars by sampling and rendering different token variables given this type variable. Distinctly from [10, 24], the parameters of the token model are not learned through supervision but simply set to a sensible value by examining the noise level in the output - any learned statistics can be straightforwardly plugged in.
+
+DooD generates realistic new exemplars of complex QuickDraw drawings and Omniglot characters (Fig. 7) thanks to the accurate inference and the ability to add noise to explicitly parametrised strokes. While we can add an equivalent token model for AIR by (i) adding a Gaussian noise to the uninterpretable feature vector representing each part and (ii) applying a Gaussian affine transformation to the rendered image, the new exemplars are not as realistic both because of worse inference and the hard-to-control variations of the part vectors. GNS generates realistic conditional samples, but notably still makes unnatural samples in multiple instances (e.g., in column 1, 3 the detachments of strokes) despite having a hierarchical model learned with multi-levels of supervision.
+
+Partial completion. As with inferring an entire figure in the previous case, we can interpret conditional generation in a slightly different way as well—where the condition is an initialization of a number, character, or figure, and the model tries to extend/complete it as best it can (Fig. 8). To do this, we first employ the recognition model over the partial figure to compute the hidden states of the shared recurrent networks. Next, starting with these computed states, we set the canvas-so-far $x_{| Model | DA | ES | 2W | Accuracy |
| AIR | X | X | X | 14.5% |
| DooD | X | X | X | 73.5% |
| VHE[18] | ✓ | ✓ | X | 81.3% |
| GNS[10] | X | ✓ | ✓ | 94.3% |
| BPL[24] | X | ✓ | ✓ | 96.7% |
+
+without requiring additional forms of support such as data augmentation, supervision for strokes, or more complex ways of computing the classification score such as two-way scoring (predicting $\hat{c} = \arg \max_c\frac{p(x^{(c)}|x^{(T)})}{p(x^{(c)})} p(x^{(T)}|x^{(c)}))$
+
+# 4 Related Work
+
+Our work takes inspiration from Lake et al. [24]'s symbolic generative modelling approach which hypothesises that the human ability to generalise comes from our causal and compositional understanding that characters are generated by composing substrokes into strokes, strokes into characters and rendering characters to images. As a result, Lake et al. [24] demonstrate human-like generalization on a wide range of tasks. However, it is trained using stroke sequences, and inference is performed using expensive MCMC sampling.
+
+We combine features of neuro-symbolic generative models and deep generative models to be able to generalise well across tasks while using amortised inference and being unsupervised. From neuro-symbolic models, we share key features of Feinman and Lake [10]'s model like (i) using the canvas-so-far in the generative model and adopt a similar feature in the recognition model like Ellis et al. [8], (ii) parametrizing parts as splines and using a differentiable spline renderer, (iii) extending the model to have a type-token hierarchy for generating new exemplars and performing one-shot classification. Our model can be seen as an extension of [10] that learns directly from images and uses a recognition model for amortised inference. Like Hewitt et al. [17], we learn how to infer a stroke sequence directly from images using a differentiable renderer but infer strokes directly instead of learning a stroke bank and use a more flexible parametrization of strokes based on a differentiable spline renderer, leading to a more accurate model.
+
+Similar to deep generative modelling approaches like [9, 14, 23, 29], we use attention to focus on parts of the canvas we want to generate to or recognise, and more generally exploit the compositionality of objects from which allows neural networks to learn simpler and hence more generalizable mappings. To be able to train our model from unsupervised images, we adopt the NVIL control variate [28] used by Eslami et al. [9] to be able to train a model with a discrete stop-drawing latent variable. This family of models, along with deep meta-learning approaches [11, 32, 34], is easier to learn due to the lack of symbolic variables and results in a fast amortised recognition model. However, the lack of strong inductive biases leads to poor and unreliable generalization [25]. We also share idea with other works combining deep learning and explicit stroke modelling [1, 12, 15, 27], but we focus on learning a principled generative model which allows tackling tasks like one-shot classification and generating new exemplars, in addition to conditional and unconditional sampling.
+
+# 5 Conclusion
+
+We demonstrated that DooD generalises across datasets and across tasks thanks to an explicit symbolic parametrization of strokes and execution guidance. This allows us to train on one dataset such as MNIST and generalise to a more complex, out-of-distribution dataset such as Omniglot. Given a compositional representation and an associated learned sequential prior, DooD can be applied to additional tasks in the Omniglot challenge like generating new exemplars and one-shot classification by extending it to have a type-token hierarchy. Our model produces realistic new exemplars without blur and artefacts unlike deep generative models.
+
+More broadly, DooD is an example of a system that successfully combines symbolic generative models to achieve generalization and deep learning models to handle raw perceptual data and perform fast amortised inference while being learned from unsupervised data. We believe these principles can be useful for building fast, reliable and robust learning systems going beyond stroke-based data.
+
+Acknowledgements We thank Rob Zinkov for his contribution to the early versions of the renderer; Reuben Feinman, Luke Hewitt, Kevin Ellis for their thoughtful comments on the manuscript; and Reuben's prompt support in running the GNS model. NS was in part supported by the Turing 2.0 'Enabling Advanced Autonomy' project, funded by the EPSRC and the Alan Turing Institute.
+
+# References
+
+[1] E. Aksan, T. Deselaers, A. Tagliasacchi, and O. Hilliges. Cose: Compositional stroke embeddings. Advances in Neural Information Processing Systems, 33:10041-10052, 2020.
+[2] S. Bowman, L. Vilnis, O. Vinyals, A. Dai, R. Jozefowicz, and S. Bengio. Generating sentences from a continuous space. In Proceedings of The 20th SIGNLL Conference on Computational Natural Language Learning, pages 10-21, 2016.
+[3] Y. Burda, R. Grosse, and R. Salakhutdinov. Importance weighted autoencoders. arXiv preprint arXiv:1509.00519, 2015.
+[4] C. P. Burgess, L. Matthew, N. Watters, R. Kabra, I. Higgins, M. Botvinick, and A. Lerchner. Monet: Unsupervised scene decomposition and representation, 2019. URL https://arxiv.org/abs/1901.11390.
+[5] J. Chung, K. Kastner, L. Dinh, K. Goel, A. C. Courville, and Y. Bengio. A recurrent latent variable model for sequential data. Advances in neural information processing systems, 28: 2980-2988, 2015.
+[6] T. Clanuwat, M. Bober-Irizar, A. Kitamoto, A. Lamb, K. Yamamoto, and D. Ha. Deep learning for classical japanese literature. arXiv preprint arXiv:1812.01718, 2018.
+[7] G. Cohen, S. Afshar, J. Tapson, and A. Van Schaik. Emmist: Extending mnist to handwritten letters. In 2017 International Joint Conference on Neural Networks (IJCNN), pages 2921-2926. IEEE, 2017.
+[8] K. Ellis, M. Nye, Y. Pu, F. Sosa, J. Tenenbaum, and A. Solar-Lezama. Write, execute, assess: Program synthesis with a repl. Advances in Neural Information Processing Systems, 32, 2019.
+[9] S. Eslami, N. Heess, T. Weber, Y. Tassa, D. Szepesvari, G. E. Hinton, et al. Attend, infer, repeat: Fast scene understanding with generative models. Advances in Neural Information Processing Systems, 29:3225-3233, 2016.
+[10] R. Feinman and B. M. Lake. Learning task-general representations with generative neurosymbolic modeling. arXiv preprint arXiv:2006.14448, 2020.
+[11] C. Finn, P. Abbeel, and S. Levine. Model-agnostic meta-learning for fast adaptation of deep networks. In International conference on machine learning, pages 1126–1135. PMLR, 2017.
+[12] Y. Ganin, T. Kulkarni, I. Babuschkin, S. A. Eslami, and O. Vinyals. Synthesizing programs for images using reinforced adversarial learning. In International Conference on Machine Learning, pages 1666-1675. PMLR, 2018.
+[13] M. A. Goodale and A. D. Milner. Separate visual pathways for perception and action. Trends in neurosciences, 15(1):20-25, 1992.
+[14] K. Gregor, I. Danihelka, A. Graves, D. Rezende, and D. Wierstra. Draw: A recurrent neural network for image generation. In International Conference on Machine Learning, pages 1462-1471. PMLR, 2015.
+[15] D. Ha and D. Eck. A neural representation of sketch drawings. arXiv preprint arXiv:1704.03477, 2017.
+[16] M. Heusel, H. Ramsauer, T. Unterthiner, B. Nessler, and S. Hochreiter. Gans trained by a two time-scale update rule converge to a local nash equilibrium. Advances in neural information processing systems, 30, 2017.
+[17] L. Hewitt, T. A. Le, and J. Tenenbaum. Learning to learn generative programs with memoised wake-sleep. In Conference on Uncertainty in Artificial Intelligence, pages 1278-1287. PMLR, 2020.
+[18] L. B. Hewitt, M. I. Nye, A. Gane, T. Jaakkola, and J. B. Tenenbaum. The variational homoen-coder: Learning to learn high capacity generative models from few examples. arXiv preprint arXiv:1807.08919, 2018.
+
+[19] I. Higgins, L. Matthey, A. Pal, C. Burgess, X. Glorot, M. Botvinick, S. Mohamed, and A. Lerchner. beta-VAE: Learning basic visual concepts with a constrained variational framework. In Proceedings of the International Conference on Learning Representations, 2016.
+[20] M. Jaderberg, K. Simonyan, A. Zisserman, et al. Spatial transformer networks. Advances in neural information processing systems, 28, 2015.
+[21] D. P. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014.
+[22] D. P. Kingma and M. Welling. Auto-encoding variational bayes. arXiv preprint arXiv:1312.6114, 2013.
+[23] A. Kosiorek, S. Sabour, Y. W. Teh, and G. E. Hinton. Stacked capsule autoencoders. Advances in neural information processing systems, 32, 2019.
+[24] B. M. Lake, R. Salakhutdinov, and J. B. Tenenbaum. Human-level concept learning through probabilistic program induction. Science, 350(6266):1332-1338, 2015.
+[25] B. M. Lake, R. Salakhutdinov, and J. B. Tenenbaum. The omniglot challenge: a 3-year progress report. Current Opinion in Behavioral Sciences, 29:97-104, 2019.
+[26] Y. LeCun. The mnist database of handwritten digits. http://yann.lecun.com/exdb/mnist/, 1998.
+[27] J. F. Mellor, E. Park, Y. Ganin, I. Babuschkin, T. Kulkarni, D. Rosenbaum, A. Ballard, T. Weber, O. Vinyals, and S. Eslami. Unsupervised doodling and painting with improved spiral. arXiv preprint arXiv:1910.01007, 2019.
+[28] A. Mnih and K. Gregor. Neural variational inference and learning in belief networks. In International Conference on Machine Learning, pages 1791-1799. PMLR, 2014.
+[29] D. Rezende, I. Danihelka, K. Gregor, D. Wierstra, et al. One-shot generalization in deep generative models. In International conference on machine learning, pages 1521-1529. PMLR, 2016.
+[30] P. J. Rousseeuw. Silhouettes: a graphical aid to the interpretation and validation of cluster analysis. Journal of computational and applied mathematics, 20:53-65, 1987.
+[31] J. Schulman, N. Heess, T. Weber, and P. Abbeel. Gradient estimation using stochastic computation graphs. arXiv preprint arXiv:1506.05254, 2015.
+[32] J. Snell, K. Swersky, and R. Zemel. Prototypical networks for few-shot learning. Advances in neural information processing systems, 30, 2017.
+[33] J. Tenenbaum and W. Freeman. Separating style and content. Advances in neural information processing systems, 9, 1996.
+[34] O. Vinyals, C. Blundell, T. Lillicrap, D. Wierstra, et al. Matching networks for one shot learning. Advances in neural information processing systems, 29, 2016.
\ No newline at end of file
diff --git a/drawingoutofdistributionwithneurosymbolicgenerativemodels/images.zip b/drawingoutofdistributionwithneurosymbolicgenerativemodels/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..54de4feac833d55d9b73a52dee9e5108766a4ace
--- /dev/null
+++ b/drawingoutofdistributionwithneurosymbolicgenerativemodels/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3bc90e4275a30240309f01559be3eb6609f4bd401c5c399619c4bf45f5afc309
+size 606148
diff --git a/drawingoutofdistributionwithneurosymbolicgenerativemodels/layout.json b/drawingoutofdistributionwithneurosymbolicgenerativemodels/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..87b0a9d6389b02b119e72afcb4b227fb138167fc
--- /dev/null
+++ b/drawingoutofdistributionwithneurosymbolicgenerativemodels/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:41bfe0d6d91a5ecd9f9424e4f2fc18592cabc45d9fc36410098f29c59abcf934
+size 312046
diff --git a/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/b7e19046-19b1-47d6-85d0-e1ea6fd3dc21_content_list.json b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/b7e19046-19b1-47d6-85d0-e1ea6fd3dc21_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..562d0d2c277f892ffc72a561dac6ecc6881079b5
--- /dev/null
+++ b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/b7e19046-19b1-47d6-85d0-e1ea6fd3dc21_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bd861d7ebbce09bf8419aabc88f74d61167c9983508c4fb884e9be60090c1742
+size 84990
diff --git a/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/b7e19046-19b1-47d6-85d0-e1ea6fd3dc21_model.json b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/b7e19046-19b1-47d6-85d0-e1ea6fd3dc21_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..41861f1cf194a41bab8a39aae256633a2ac64880
--- /dev/null
+++ b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/b7e19046-19b1-47d6-85d0-e1ea6fd3dc21_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f4bc47800e46355e329f036dfd90443b52f4fca968090220d4c884222ce708bd
+size 110630
diff --git a/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/b7e19046-19b1-47d6-85d0-e1ea6fd3dc21_origin.pdf b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/b7e19046-19b1-47d6-85d0-e1ea6fd3dc21_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..42ba4d8af4a34ddb4666179550bbf8fef54d0a39
--- /dev/null
+++ b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/b7e19046-19b1-47d6-85d0-e1ea6fd3dc21_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e738a21e4ce421f597f624a3a7724631b3754017e663077e7d4b52034bfbb775
+size 627811
diff --git a/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/full.md b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..3d3fce439cd6073a651aba9e1c88ce658ae727eb
--- /dev/null
+++ b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/full.md
@@ -0,0 +1,298 @@
+# DreamShard: Generalizable Embedding Table Placement for Recommender Systems
+
+Daochen Zha $^{1}$ Louis Feng $^{2}$ Qiaoyu Tan $^{3}$ Zirui Liu $^{1}$ Kwei-Herng Lai $^{1}$ Bhargav Bhushanam $^{2}$ Yuandong Tian $^{2}$ Arun Kejariwal $^{2}$ Xia Hu $^{1}$
+
+$^{1}$ Rice University $^{2}$ Meta Platforms, Inc. $^{3}$ Texas A&M University
+
+{daochen.zha,Zirui.Liu,khlai,Xia.Hu}@rice.edu
+
+{lofe, bbhushanam, yuandong, akejariwal}@fb.com
+
+qytan@tamu.edu
+
+# Abstract
+
+We study embedding table placement for distributed recommender systems, which aims to partition and place the tables on multiple hardware devices (e.g., GPUs) to balance the computation and communication costs. Although prior work has explored learning-based approaches for the device placement of computational graphs, embedding table placement remains to be a challenging problem because of 1) the operation fusion of embedding tables, and 2) the generalizability requirement on unseen placement tasks with different numbers of tables and/or devices. To this end, we present DreamShard, a reinforcement learning (RL) approach for embedding table placement. DreamShard achieves the reasoning of operation fusion and generalizability with 1) a cost network to directly predict the costs of the fused operation, and 2) a policy network that is efficiently trained on an estimated Markov decision process (MDP) without real GPU execution, where the states and the rewards are estimated with the cost network. Equipped with sum and max representation reductions, the two networks can directly generalize to any unseen tasks with different numbers of tables and/or devices without finetuning. Extensive experiments show that DreamShard substantially outperforms the existing human expert and RNN-based strategies with up to $19\%$ speedup over the strongest baseline on large-scale synthetic tables and our production tables. The code is available at https://github.com/daochenzha/dreamshard.
+
+# 1 Introduction
+
+Embedding learning is a commonly used technique to deal with categorical features in deep recommendation models by mapping sparse features into dense vectors [1, 2, 3, 4, 5]. However, the embedding tables can be extremely large due to the large feature sizes [6]. For example, in the YouTube recommendation model, a single categorical feature contains tens of millions of video IDs [7]; the Meta recommendation model demands multi-terabyte memory [8]. Distributed training has been adopted to place the tables on multiple hardware devices such as GPUs [3, 6, 9, 10, 11]. However, even with distributed training, the embedding tables are often still the efficiency bottlenecks. For instance, embedding lookup is shown to dominate the training throughput in the Meta recommendation model [8]. In our internal production model, which has hundreds of tables, embedding lookup accounts for $48\%$ and $65\%$ of the total computation and communication costs, respectively.
+
+How the embedding tables are placed can significantly impact the costs. Figure 1 shows the traces of different placement strategies on a task of placing 50 tables on 4 devices. Typically, embedding lookup consists of four stages. In the forward pass, the sparse indices are mapped into dense vectors (forward computation), which are then sent to the target devices (forward communication).
+
+In the backward pass, the gradients of the embedding vectors are sent back from the target devices (backward communication) and applied to the embedding vectors (backward computation). The tables will easily lead to imbalances if not carefully partitioned. The random placement in Figure 1a is bottlenecked by GPU2 with a 56.6 milliseconds latency, while the more balanced placements in Figure 1b and 1c significantly reduce the costs to 42.8 and 35.95 milliseconds, respectively. This work asks: given a set of embedding tables, how can we identify the best placement of the tables to balance the costs?
+
+Device placement is essentially a partition problem, which is one of the classical NP-hard combinatorial optimization problems [12]. A recent line of research uses reinforcement learning (RL) for device placement of computational graphs [13, 14, 15, 16, 17, 18, 19, 20]. For example, [13] proposed to train an RNN controller with content-based attention to predict the placement. Other studies advanced [13] in different ways, such as using hierarchical models [14], more sophisticated RL algorithms [15], and graph neural networks [16].
+
+However, embedding table placement remains to be an open and challenging problem due to the operation fusion [21] of tables and the generalizability requirement. 1) Modern embedding implementations (e.g., FBGEMM [22]), use a single operation to subsume multiple tables for acceleration. The speedup of the fused operation over the sum of the single-table operation costs is not constant and depends on the characteristics of the fused tables (e.g., table dimensions). Our analysis finds that the speedups vary significantly across different table
+
+
+
+
+(a) Random placement
+
+
+(b) The existing best human expert strategy
+(c) DreamShard
+Figure 1: Visualization of random placement, the existing best human expert strategy, and DreamShard on a task of placing 50 tables on 4 GPUs. The dense computations and communications are omitted in the traces because they do not have an imbalance issue. We provide more visualizations in Appendix L.
+
+combinations, ranging from 1X to 3X (Figure 12 in Appendix A.3.2). Thus, we not only need to reason about cost balance but also how the tables should be fused to maximize the speedup. 2) In real-world scenarios, the adopted embedding tables and the available devices can change frequently (e.g., machine learning engineers/researchers may conduct concurrent experiments with various table combinations and numbers of devices). Thus, a practical algorithm should generalize to tasks with unseen tables, different numbers of tables, and different numbers of devices. It is non-trivial to achieve this with the existing device placement approaches.
+
+To this end, we introduce DreamShard, an RL approach for embedding table placement. DreamShard achieves the reasoning of operation fusion and generalizability with two novel ideas. 1) It learns a cost network to directly predict the costs of the fused operations. Specifically, the network takes as input the table features (e.g., table dimension) of each single-table and outputs the computation and communication costs. 2) It trains a policy network by interacting with an estimated Markov decision process (MDP) without real GPU execution, where the states and the rewards are estimated by the predictions of the cost network. Equipped with sum reductions for the table representations and max reductions for the device representations, the two networks can directly generalize to unseen placement tasks with different numbers of tables and/or devices without fine-tuning.
+
+Extensive experiments show that DreamShard outperforms the existing human expert and RNN-based [13] strategies on open-sourced synthetic tables [23] and our production tables, achieving up to $19\%$ speedup over the strongest baseline. Moreover, it can generalize to unseen tasks that have different numbers of tables and/or devices with negligible performance drop ( $< 0.5$ milliseconds). Additionally, its inference is very efficient. It can place hundreds of tables in less than one second.
+
+# 2 Generalizable Embedding Table Placement Problem
+
+The embedding table placement problem seeks a device placement1 of all the tables such that the overall cost (in terms of execution time) is minimized (we provide a background for the distributed training of recommendation models in Appendix A.1). Consider $M$ embedding tables $\{\mathbf{e}_1, \mathbf{e}_2, \dots, \mathbf{e}_M\}$ and $D$ devices, where $\mathbf{e}_i \in \mathbb{R}^N$ denotes the table features that characterize the embedding lookup patterns. In our work, we use 21 table features, including hash size, dimension, table size, pooling factor, and distribution (their definitions are provided in Appendix A.2). A placement $\mathbf{a} = [a_1, a_2, \dots, a_M]$ , where $a_i \in \{1, 2, \dots, D\}$ , assigns each table to a device. Let $c(\mathbf{a})$ denote the cost measured on GPUs. The goal of embedding table placement is to find the $\mathbf{a}$ such that $c(\mathbf{a})$ is minimized. Due to the NP-hardness of the partition problem [12], identifying the exact solution demands extensive computational overhead. Thus, the state-of-the-art algorithms often approximate the optimal partition via sampling with RL [24, 13]. However, sampling remains expensive because obtaining $c(\mathbf{a})$ requires running operations on GPUs. Given that the embedding tables and the available devices can frequently change, we wish to approximate the best $\mathbf{a}$ without GPU execution.
+
+Motivated by this, we study the generalizable embedding table placement (GETP) problem. Let $\mathcal{E}$ be the space of all the embedding tables. A placement task can be denoted as $T_{i} = (\mathcal{E}_{i},D_{i})$ , where $\mathcal{E}_i\subseteq \mathcal{E}$ is a set of tables, and $D_{i}$ is the number of devices. Given $N_{\mathrm{train}}$ training tasks $\mathcal{T}_{\mathrm{train}} = \{T_1,T_2,\dots,T_{N_{\mathrm{train}}}\}$ , and $N_{\mathrm{test}}$ testing tasks $\mathcal{T}_{\mathrm{test}} = \{T_1,T_2,\dots,T_{N_{\mathrm{test}}}\}$ , the goal is to train a placement policy based on $\mathcal{T}_{\mathrm{train}}$ (GPU execution is allowed during training) such that the learned policy can minimize the costs for the tasks in $\mathcal{T}_{\mathrm{test}}$ without GPU execution.
+
+# 3 DreamShard Framework
+
+We present DreamShard, an RL framework based on estimated MDP, to tackle the GETP problem. An overview of the framework is shown in Figure 2. The key idea is to formulate the table placement process as an MDP (Section 3.1) and train a cost network to estimate its states and rewards (Section 3.2). A policy network with a tailored generalizable network architecture is trained by efficiently interacting with the estimated MDP (Section 3.3). The two networks are updated iteratively to improve the state/reward estimation and the placement policy.
+
+
+Figure 2: DreamShard framework. The agent interacts with the estimated MDP, which is trained with the cost data collected from GPUs.
+
+# 3.1 MDP Formulation
+
+Given embedding tables $\{\mathbf{e}_1, \mathbf{e}_2, \dots, \mathbf{e}_M\}$ and $D$ devices, we aim to generate a placement $\mathbf{a} = [a_1, a_2, \dots, a_M]$ . The key idea is to place the tables one by one at each step, where the state characterizes the tables that have been placed so far, the action is the device ID, and the reward represents the execution time on GPUs. Specifically, at a step $t$ , the state $s_t = \{s_{t,d}\}_{d=1}^D$ is all the table features of the tables placed on all the devices, where $s_{t,d} = \{\mathbf{e}_i | i \in \mathcal{P}_d\}$ denotes all the table features corresponding to device $d$ ( $\mathcal{P}_d$ is the set of table IDs that have been placed on device $d$ ). We further augment the raw features with cost features which are obtained by collecting the operation computation and communication times from GPUs (Appendix A.3 provides a comprehensive analysis of the cost features). Formally, the augmented state is defined as $\widetilde{s}_t = \{s_t, \{\mathbf{q}_{t,d}\}_{d=1}^D\}$ , where $\mathbf{q}_{t,d} \in \mathbb{R}^3$ has three elements representing forward computation time, backward computation time, and backward communication time for the current operation in device $d$ (we provide detailed explanations of why forward communication time is excluded in Appendix A.4). We find that the augmented cost features can significantly boost the performance, evidenced by the ablations in Table 3. The action $a_t \in \mathcal{A}_t$ is an integer specifying the device ID, where $\mathcal{A}_t$ is the set of legal actions at step $t$ . A device ID is considered legal if placing the current table on the corresponding device does not cause a memory explosion. The reward $r_t$ is 0 for all the intermediate steps, and the reward at the final step $M$ is the negative of the cost, i.e., $r_M = -c(\mathbf{a})$ , which encourages the agent to achieve lower cost.
+
+
+Figure 3: MDP formulation of embedding table placement.
+
+
+Figure 4: DreamShard's cost network (left) and policy network (right).
+
+
+
+The procedure is illustrated for an example task of placing 8 tables $\{\mathbf{e}_1,\mathbf{e}_2,\dots,\mathbf{e}_8\}$ on 2 devices in Figure 3. At step 0, no table has been placed so $s_0 = \{\{\},\{\}\}$ and the augmented state $\widetilde{s}_0 = \{s_0,\{\mathbf{q}_{0,0},\mathbf{q}_{0,1}\}\}$ , where both $\mathbf{q}_{0,0}$ and $\mathbf{q}_{0,1}$ are zero vectors (i.e., $[0,0,0]$ ) since all the computation and communication times are 0 as well. Then the action $a_0 = 1$ makes the MDP transit to the next state $s_1 = \{\{\mathbf{e}_1\},\{\}\}$ with its corresponding augmented state $\widetilde{s}_1 = \{s_1,\{\mathbf{q}_{1,0},\mathbf{q}_{1,1}\}\}$ , where $\mathbf{q}_{1,0}$ becomes a non-zero vector containing the computation and communication costs by running $\{\mathbf{e}_1\}$ and $\{\}$ on GPUs. We repeat the above process, and finally at step 8, we have $s_8 = \{\{\mathbf{e}_1,\mathbf{e}_4,\mathbf{e}_7,\mathbf{e}_8\},\{\mathbf{e}_2,\mathbf{e}_3,\mathbf{e}_5,\mathbf{e}_6\}\}$ . The corresponding $\mathbf{q}_{8,1}$ , and $\mathbf{q}_{8,2}$ are the measured times of running $\{\mathbf{e}_1,\mathbf{e}_4,\mathbf{e}_7,\mathbf{e}_8\}$ and $\{\mathbf{e}_2,\mathbf{e}_3,\mathbf{e}_5,\mathbf{e}_6\}$ on two devices. The action sequence $\mathbf{a} = [a_1,a_2,\dots,a_8]$ is the generated placement, which is then evaluated on GPUs to obtain the reward.
+
+Discussion 1. The MDP enjoys two desirable properties. 1) The legal action $\mathcal{A}_t$ can guarantee that the generated placement satisfies the memory constraints. 2) The one-by-one placement enables the agent to be generalized across different numbers of tables. For example, an agent trained on an MDP with very few tables can be applied to another MDP with more tables by simply executing more steps.
+
+Discussion 2. A straightforward idea to solve the MDP is to greedily place the current table on the device with the lowest cost at each step, where the cost function can be one of or a combination of the state features (e.g., the sum of the table dimensions, or the sum of all the cost features). However, greedy heuristics are often sub-optimal. Thus, we seek a learning-based algorithm to explore various placement possibilities and make comprehensive decisions based on all the state features.
+
+# 3.2 Learning an Estimated MDP
+
+Interacting with the above MDP is computationally expensive since obtaining the cost features and the reward requires GPU execution. Motivated by world models [25, 26], we build an estimated MDP by approximating the cost features and the reward with a cost network. Let $f_{\mathrm{cost}}$ denote the cost network. $f_{\mathrm{cost}}$ takes as input the raw table features $s_t$ , and predicts cost features $\{\mathbf{q}_{t,d}\}_{d=1}^D$ and the overall cost $c(\mathbf{a})$ . $f_{\mathrm{cost}}$ is trained with mean squared error (MSE) loss using the cost data collected from the GPUs. Once trained, it can predict the cost features or the reward with a single forward pass without GPU execution. However, it is non-trivial to design the architecture of $f_{\mathrm{cost}}$ because it needs
+
+Algorithm 1 Training of DreamShard
+1: Input: Training tasks $\mathcal{T}_{\text{train}}$ , the number of data collection steps $N_{\text{collect}}$ , the number of cost network update steps $N_{\text{cost}}$ , the batch size for updating the cost network $N_{\text{batch}}$ , the number RL update steps $N_{\text{RL}}$ , the number of considered episodes in each RL update $N_{\text{episode}}$
+2: Initialize a cost network, a policy network, and a buffer
+3: for iteration = 1, 2, ... until convergence do
+4: for step = 1, 2, ... $N_{\text{collect}}$ do ▷ Collect cost data from GPUs
+5: Randomly sample a training task from $\mathcal{T}_{\text{train}}$
+6: Generate a placement by interacting with the estimated MDP using the policy network
+7: Evaluate the placement on the hardware and store the collected cost data to the buffer
+8: end for
+9: for step = 1, 2, ... $N_{\text{cost}}$ do ▷ Update the cost network (no GPU execution)
+10: Randomly sample $N_{\text{batch}}$ cost data from the buffer
+11: Update the cost network based on MSE loss (Eq. 1 in Appendix B.4.1)
+12: end for
+13: for step = 1, 2, ... $N_{\text{RL}}$ do ▷ Update the policy network (no GPU execution)
+14: Randomly sample a training task from $\mathcal{T}_{\text{train}}$
+15: Collect $N_{\text{episode}}$ episodes by interacting with the estimated MDP using the policy network
+16: Update the policy network based on the policy gradient loss (Eq. 2 in Appendix B.4.1)
+17: end for
+18: end for
+
+to accommodate different numbers of devices (i.e., $s_t$ can have variable sizes), and different numbers of tables in each device (i.e., $s_{t,d}$ can have variable lengths).
+
+The left-hand side of Figure 4 shows DreamShard's generalizable design of $f_{\mathrm{cost}}$ , which is based on two key ideas. First, it uses a shared MLP to map raw table features into table representations. For any unseen tables, this MLP can be directly applied to extract table representations. Second, it enables a fixed-dimension representation for each device with sum reductions (i.e., the element-wise sum of the table representations in the device), and similarly for the overall representation across devices with max reductions (Appendix B.3 compares different reduction choices and finds that this sum-max combination leads to the most accurate prediction). The reduced representations are then followed by multiple MLP heads for cost predictions. For unseen tasks with different numbers of tables and/or devices, the reductions will always lead to fixed-dimension device/overall representations, so that the prediction heads can be directly applied. Appendix B.1 provides more details.
+
+# 3.3 Training the Policy Network on the Estimated MDP
+
+Generalizable policy network architecture. Let $\pi$ be the policy network. $\pi$ maps the augmented state $\widetilde{s}_t = \{s_t,\{\mathbf{q}_{t,d}\}_{d = 1}^D\}$ to action $a_{t}$ , i.e., $a_{t} = \pi (\widetilde{s}_{t})$ . $\pi$ also adopts a generalizable design, shown in the right-hand side of Figure 4. Like $f_{\mathrm{cost}}$ , $\pi$ uses a shared MLP and sum reductions to produce a fixed-dimension representation, which is then concatenated with the cost features to obtain the device representation. To accommodate the potentially variable action space (i.e., the number of available devices may vary), a shared MLP will process each device representation separately to obtain a confidence score, followed by a Softmax layer to produce action probabilities. This design allows $\pi$ to generalize across different numbers of devices. Appendix B.2 provides more details.
+
+Training and inference. Algorithm 1 summarizes the training procedure of DreamShard, which iteratively executes the following: 1) collect cost data from GPUs based on the placements generated by the current policy, 2) update the cost network with the previously collected cost data, and 3) update the policy network by interacting with the current estimated MDP. Throughout the training process, the estimated MDP gradually becomes more accurate, and the resultant policy network tends to generate better placements. Appendix B.4.2 provides more details of the training procedure. For the inference, the trained cost network and policy network can be directly applied to unseen tasks to generate placements without GPU execution, which is summarized by Algorithm 2 in Appendix B.4.3.
+
+# 4 Experiments
+
+Our experiments aim to answer the following research questions. RQ1: How does DreamShard compare with the existing human expert and RL-based placement strategies? RQ2: Can DreamShard generalize to placement tasks with different numbers of tables and/or devices? RQ3: How efficient is the training of DreamShard? RQ4: How do the hyperparameters influence the performance of DreamShard? RQ5: How does each component of DreamShard contribute to the performance? RQ6: How accurate is the estimated MDP and to what extent can it accelerate the training and inference?
+
+# 4.1 Experimental Setup
+
+Datasets. Academic recommendation datasets are often too small to enable a meaningful evaluation because the cost will always be very small no matter how the tables are placed. Thus, we use two industrial-scale datasets. DLRM $^2$ is a large-scale synthetic dataset with 856 tables, recently released by Meta. It shares memory access reuse patterns similar to those arising in Meta production workloads. Prod is an internal large-scale dataset for production recommendation models. It has a similar scale as DLRM. The main difference is that DLRM only has a fixed dimension for all the tables, while Prod is more challenging with diverse table dimensions, ranging from 4 to 768. For reproducibility, we mainly focus on the DLRM dataset since it is open-sourced. We only report the main results on the Prod dataset for verification purposes. We provide more details in Appendix C.
+
+Baselines. We compare DreamShard against human expert strategies from previous work [27, 8, 28], including size-based, dim-based, lookup-based, size-lookup-based greedy balancing strategies. We also include an RNN-based RL algorithm [13], which uses RNN architecture to map operators to devices. Since the feature extraction layers of the RNN-based method were designed for other operations instead of embedding tables, for a fair comparison, we adapt [13] by making it have the same feature extraction layers as in DreamShard. We provide more details in Appendix D.
+
+Configurations. To evaluate the generalizability of DreamShard, we randomly divide the tables into a training pool $\mathcal{E}^{\mathrm{train}}$ and a testing pool $\mathcal{E}^{\mathrm{test}}$ . The two pools have the same number of tables but they are not overlapped. A sharding task $T_{i}$ is constructed by randomly sampling a subset of $|\mathcal{E}_i|$ tables from a pool, where the number of tables $|\mathcal{E}_i| \in \{10, 20, 30, 40, 50, 60, 70, 80, 90, 100\}$ for the DLRM dataset, and $|\mathcal{E}_i| \in \{20, 40, 80\}$ for the Prod dataset. For all the experiments, we randomly sample 50 training and 50 testing tasks from $\mathcal{E}^{\mathrm{train}}$ and $\mathcal{E}^{\mathrm{test}}$ , respectively. DreamShard is trained on the training tasks and will be evaluated on unseen tables in the testing tasks. We denote placement tasks with different numbers of tables and devices using the format of dataset-num_tables (num Devices). For example, DLRM-30 (4) suggests that there are 30 tables sampled from the DLRM dataset in each training/testing task with 4 available devices. We provide more details in Appendix E.
+
+Implementation Details. We use the same hyperparameters for all the experiments with $N_{\mathrm{collect}} = 10$ , $N_{\mathrm{cost}} = 300$ , $N_{\mathrm{batch}} = 64$ , $N_{\mathrm{RL}} = 10$ , $N_{\mathrm{episode}} = 10$ , 10 training iterations, and an entropy weight of 0.001 in the policy gradient. 2080 Ti GPUs and V100 GPUs are used for the DLRM (except that we use V100 for experiments with 8 GPUs) and Prod datasets, respectively. All the experiments are run 5 times, and we report the mean and the standard deviation. Appendix B provides more details.
+
+# 4.2 Results and Analysis
+
+Evaluation of DreamShard against baselines (RQ1). We perform qualitative and quantitative comparisons of DreamShard against the baselines. Qualitatively, Figure 1 visualizes the traces of DreamShard and the baselines on one of the tasks from DLRM-50 (4). DreamShard achieves significant better overall cost than the best baseline (35.95 vs. 42.8) with 1) a better balance of forward and backward commutation workloads, and 2) less communication time, possibly due to a better balance of table dimensions. Quantitatively, Table 1 presents comprehensive evaluations on tasks with different numbers of tables and devices on the DLRM and the Prod datasets. Observations: 1) DreamShard outperforms the baselines on all the tasks. 2) DreamShard shows strong generalizability on unseen tables, achieving the same level of performance on all the testing and training tasks. 3) DreamShard appears to be more advantageous on harder tasks. Specifically, DreamShard achieves more improvement over the baselines on tasks with more tables/devices on the Prod dataset. In particular, DreamShard achieves $19\%$ improvement over the strongest baseline on Prod-80 (8). 4)
+
+Table 1: Overall cost comparison in milliseconds and relative speedups over random placement, averaged over 50 different randomly sampled tasks. The placement tasks are denoted as datasetnum_tables (num/devices). For example, DLRM-30 (4) suggests that 30 tables are sampled from the DLRM dataset for each task with 4 GPUs. More results are provided in Appendix F.
+
+| Task | No strategy | Human Experts | RL |
| Random | Size-based | Dim-based | Lookup-based | Size-lookup-based | RNN-based | DreamShard |
| DLRM-20 (4) | Train | 24.0±0.6 | 22.7±0.0 (+5.7%) | 21.3±0.0 (+12.7%) | 19.1±0.0 (+25.7%) | 19.1±0.0 (+25.7%) | 22.4±0.5 (+7.1%) | 18.6±0.2 (+29.0%) |
| Test | 23.0±0.5 | 21.7±0.0 (+6.0%) | 19.9±0.0 (+15.6%) | 18.3±0.0 (+25.7%) | 18.4±0.0 (+25.0%) | 20.9±0.3 (+10.0%) | 17.6±0.2 (+30.7%) |
| DLRM-40 (4) | Train | 41.3±0.2 | 39.6±0.0 (+4.3%) | 37.4±0.1 (+10.4%) | 33.6±0.0 (+22.9%) | 33.6±0.1 (+22.9%) | 39.2±0.7 (+5.4%) | 32.8±0.3 (+25.9%) |
| Test | 41.1±0.5 | 40.3±0.0 (+2.0%) | 37.3±0.0 (+10.2%) | 33.0±0.1 (+24.5%) | 33.2±0.0 (+23.8%) | 39.2±1.1 (+4.8%) | 32.4±0.3 (+26.9%) |
| DLRM-60 (4) | Train | 57.7±0.8 | 56.6±0.1 (+1.9%) | 52.9±0.0 (+9.1%) | 49.2±0.1 (+17.3%) | 49.3±0.0 (+17.0%) | 55.5±0.9 (+4.0%) | 47.6±0.4 (+21.2%) |
| Test | 58.1±0.6 | 59.6±0.1 (-2.5%) | 53.7±0.0 (+8.2%) | 48.7±0.2 (+19.3%) | 49.1±0.1 (+18.3%) | 56.0±0.7 (+3.8%) | 47.9±0.7 (+21.3%) |
| DLRM-80 (4) | Train | 75.7±1.0 | 76.0±0.0 (-0.4%) | 70.0±0.3 (+8.1%) | 64.8±0.0 (+16.8%) | 65.3±0.1 (+15.9%) | 73.2±2.7 (+3.4%) | 62.2±0.2 (+21.7%) |
| Test | 74.5±0.8 | 77.7±0.2 (-4.1%) | 69.9±0.4 (+6.6%) | 64.1±0.2 (+16.2%) | 65.1±0.0 (+14.4%) | 72.9±2.4 (+2.2%) | 62.7±0.3 (+18.8%) |
| DLRM-100 (4) | Train | 91.8±1.7 | 94.1±0.3 (-2.4%) | 86.7±0.3 (+5.9%) | 81.2±0.4 (+13.1%) | 82.2±0.2 (+11.7%) | 94.5±10.7 (-2.9%) | 78.4±0.6 (+17.1%) |
| Test | 94.5±6.5 | 95.4±0.0 (-0.9%) | 84.7±0.4 (+11.6%) | 79.5±0.3 (+18.9%) | 80.8±0.3 (+17.0%) | 94.8±13.0 (-0.3%) | 77.8±0.8 (+21.5%) |
| DLRM-40 (8) | Train | 15.6±0.4 | 14.1±0.0 (+10.6%) | 13.4±0.1 (+16.4%) | 9.8±0.0 (+59.2%) | 9.9±0.0 (+57.6%) | 16.2±0.8 (-3.7%) | 9.8±0.6 (+59.2%) |
| Test | 15.2±0.2 | 14.5±0.0 (+4.8%) | 13.2±0.0 (+15.2%) | 9.5±0.0 (+60.0%) | 9.5±0.0 (+60.0%) | 16.0±1.1 (-5.0%) | 9.4±0.5 (+61.7%) |
| DLRM-80 (8) | Train | 25.0±0.2 | 24.0±0.0 (+4.2%) | 21.7±0.0 (+15.2%) | 17.1±0.0 (+46.2%) | 17.5±0.0 (+42.9%) | 51.4±3.9 (-51.4%) | 16.1±0.3 (+55.3%) |
| Test | 25.2±1.3 | 25.6±0.5 (-1.6%) | 20.8±0.0 (+21.2%) | 16.7±0.2 (+50.9%) | 16.9±0.1 (+49.1%) | 53.4±4.6 (-52.8%) | 16.1±0.4 (+56.5%) |
| DLRM-120 (8) | Train | 34.0±0.3 | 32.3±0.0 (+5.3%) | 29.8±0.0 (+14.1%) | 24.5±0.0 (+38.8%) | 25.3±0.0 (+34.4%) | 58.6±2.7 (-42.0%) | 23.3±0.2 (+45.9%) |
| Test | 33.5±0.5 | 35.0±0.0 (-4.3%) | 29.2±0.0 (+14.7%) | 23.7±0.0 (+41.4%) | 24.5±0.0 (+36.7%) | 58.7±3.1 (-42.9%) | 22.8±0.2 (+46.9%) |
| DLRM-160 (8) | Train | 42.8±0.3 | 41.6±0.0 (+2.9%) | 39.0±0.0 (+9.7%) | 32.0±0.0 (+33.7%) | 32.7±0.0 (+30.9%) | 58.3±3.5 (-26.6%) | 30.3±0.2 (+41.3%) |
| Test | 41.1±0.0 | 42.4±0.0 (-3.1%) | 36.4±0.0 (+12.9%) | 30.8±0.0 (+33.4%) | 31.6±0.0 (+30.1%) | 59.3±5.4 (-30.7%) | 29.6±0.2 (+38.9%) |
| DLRM-200 (8) | Train | 51.5±1.2 | 48.2±0.0 (+6.8%) | 48.0±0.0 (+7.3%) | 38.9±0.0 (+32.4%) | 39.9±0.0 (+29.1%) | 68.7±2.4 (-25.0%) | 37.2±0.2 (+38.4%) |
| Test | 50.7±0.2 | 50.8±0.0 (-0.2%) | 44.8±0.0 (+13.2%) | 38.0±0.0 (+33.4%) | 38.6±0.0 (+31.3%) | 70.4±2.8 (-28.0%) | 36.4±0.3 (+39.3%) |
| Prod-20 (2) | Train | 41.3±0.7 | 43.4±0.0 (-4.8%) | 37.0±0.0 (+11.6%) | 44.2±0.0 (-6.6%) | 45.8±0.0 (-9.8%) | 38.0±0.3 (+8.7%) | 36.3±0.3 (+13.8%) |
| Test | 42.8±0.4 | 46.1±0.0 (-7.2%) | 39.5±0.0 (+8.4%) | 45.9±0.0 (-6.8%) | 45.7±0.0 (-6.3%) | 39.3±0.6 (+8.9%) | 37.5±0.2 (+14.1%) |
| Prod-40 (4) | Train | 35.1±0.3 | 39.4±0.0 (-10.9%) | 31.3±0.0 (+12.1%) | 36.4±0.0 (-3.6%) | 38.8±0.0 (-9.5%) | 33.9±2.5 (+3.5%) | 28.3±0.3 (+24.0%) |
| Test | 38.3±0.3 | 43.6±0.0 (-12.2%) | 33.5±0.0 (+14.3%) | 37.4±0.0 (+2.4%) | 40.1±0.0 (-4.5%) | 36.7±2.8 (+4.4%) | 30.4±0.7 (+26.0%) |
| Prod-80 (8) | Train | 43.2±0.2 | 44.3±0.0 (-2.5%) | 39.0±0.0 (+10.8%) | 43.7±0.0 (-1.1%) | 49.3±0.0 (-12.4%) | 56.6±6.8 (-23.7%) | 33.6±0.9 (+28.6%) |
| Test | 47.7±0.4 | 53.9±0.0 (-11.5%) | 41.9±0.0 (+13.8%) | 46.1±0.0 (+3.5%) | 49.6±0.0 (-3.8%) | 62.5±4.2 (-23.7%) | 35.2±0.8 (+35.5%) |
+
+Table 2: Generalization performance of DreamShard on target tasks w.r.t. to different numbers of tables (top) and devices (bottom), averaged over 50 randomly sampled tasks. Appendix G provides the results of more challenging tasks, such as mixed table-wise and device-wise transferring scenarios.
+
+| Source Task → Target Task | Random | Best baseline strategy | DreamShard (trained on target task) | DreamShard (trained on source task) |
| DLRM-20 (4) → DLRM-100 (4) | 94.5±6.5 | 79.5±0.3 (+18.9%) | 77.8±0.8 (+21.5%) | 77.9±0.4 (+21.3%) |
| DLRM-40 (4) → DLRM-80 (4) | 74.5±0.8 | 64.1±0.2 (+16.2%) | 62.7±0.3 (+18.8%) | 62.7±0.5 (+18.8%) |
| DLRM-80 (4) → DLRM-40 (4) | 41.1±0.5 | 33.0±0.1 (+24.5%) | 32.4±0.3 (+26.9%) | 32.4±0.2 (+26.9%) |
| DLRM-100 (4) → DLRM-20 (4) | 23.0±0.5 | 18.3±0.0 (+25.7%) | 17.6±0.2 (+30.7%) | 17.7±0.3 (+29.9%) |
| DLRM-20 (4) → DLRM-20 (2) | 29.9±0.4 | 26.0±0.0 (+15.0%) | 25.8±0.2 (+15.9%) | 25.8±0.1 (+15.9%) |
| DLRM-40 (4) → DLRM-40 (2) | 58.6±0.7 | 52.4±0.0 (+11.8%) | 51.9±0.1 (+12.9%) | 52.0±0.3 (+12.7%) |
| DLRM-20 (2) → DLRM-20 (4) | 23.0±0.5 | 18.3±0.0 (+25.7%) | 17.6±0.2 (+30.7%) | 17.8±0.3 (+29.2%) |
| DLRM-40 (2) → DLRM-40 (4) | 41.1±0.5 | 33.0±0.1 (+24.5%) | 32.4±0.3 (+26.9%) | 32.6±0.3 (+26.1%) |
+
+RNN-based method is only better than the random strategy on tasks with few tables/devices, but is worse on harder tasks. A possible reason is that RNN-based algorithm does not have a cost network, and using RL alone could lead to unstable performance. 5) Lookup-based strategy is the best baseline on the DLRM dataset, while dim-based strategy is better on the Prod dataset. A potential reason is that the tables in the Prob dataset have very diverse table dimensions, while the tables in the DLRM dataset have the same dimension. As such, the dimensions on Prod tasks can more easily become imbalanced, leading to poor communication efficiency. Dim-based strategy can better balance the dimensions, which leads to a better overall performance. DreamShard outperforms the baselines on both the DLRM and the Prod datasets, showing its flexibility in dealing with different scenarios.
+
+Analysis of generalizability (RQ2). In Table 2, we directly apply a DreamShard model trained from one task to another task without any fine-tuning (the rightmost column), where the source and the target tasks have different numbers of tables and/or devices. DreamShard shows negligible performance drop, suggesting that it is generalizable across different numbers of tables and/or devices.
+
+
+Figure 5: Performance $(\downarrow)$ of DreamShard on the DLRM-50 (4) datasets w.r.t. the numbers of iterations (left) and running time (right). Curves for other tasks are in Appendix H.
+
+
+Figure 6: Impacts of the number of RL update steps $N_{RL}$ (left) and cost network update steps $N_{\mathrm{cost}}$ (right) on the DLRM-50 (4) dataset. Curves for other tasks are in Appendix I.
+
+Table 3: Ablation study of DreamShard. Results on other tasks are in Appendix J.
+
+| Task | w/o dim | w/o hash size | w/o pooling factor | w/o table size | w/o distribution | w/o cost | w/ RNN | DreamShard |
| DLRM-50 (4) | Train | 40.8±0.4 | 40.7±0.1 | 46.3±0.3 | 40.8±0.4 | 40.6±0.2 | 47.5±1.2 | 40.5±0.2 | 40.4±0.5 |
| Test | 40.9±0.6 | 40.6±0.3 | 47.2±0.1 | 40.6±0.7 | 40.5±0.2 | 46.3±0.1 | 40.5±0.1 | 40.4±0.6 |
+
+Analysis of training efficiency (RQ3). Figure 5 plots the performance of DreamShard w.r.t. the number of iterations and running time in seconds on four 1080Ti GPUs. The training of DreamShard is highly efficient. On DLRM-50 (4), it can achieve strong performance in less than 5 iterations or 200 seconds. Note that we only need to re-train or fine-tune DreamShard when the table pools have significant changes. Once trained, it only needs a forward pass for inference.
+
+Hyperparameter study (RQ4). We study the impacts of two key hyperparameters: 1) $N_{\mathrm{RL}}$ , which controls the RL update frequency, and 2) $N_{\mathrm{cost}}$ , which determines the cost network update frequency. We vary one of them with the other fixed, shown in Figure 6. Increasing $N_{\mathrm{RL}}$ or $N_{\mathrm{cost}}$ will both lead to improvement, suggesting that both the cost network and the policy network need to be sufficiently trained. However, when $N_{\mathrm{RL}}$ and $N_{\mathrm{cost}}$ are large enough, increasing them will not bring more improvement. Considering that larger values will lead to more computational costs, we set $N_{\mathrm{RL}} = 10$ or $N_{\mathrm{cost}} = 300$ as a trade-off between the performance and the training efficiency.
+
+Ablation study (RQ5). We study the importance of each table feature and check whether the RNN architecture helps, with the following ablations. 1) We remove each of the features in the state. 2) We add an RNN upon the device representation in the policy network. We makes several observations from the results in Table 3. 1) Cost features play a significant role, which demonstrates the effectiveness of our proposed augmented state. 2) The most contributing table features are the pooling factor and the dimension, which aligns with our intuitions since these two features are the determining factors of computation and communication workloads. 3) Using more features leads to consistently good performance. 4) While the policy makes decisions sequentially, RNN does not provide clear benefits. This is why we have kept the architecture simple with only MLP in DreamShard.
+
+Study of the estimated MDP (RQ6). First, we study how many data points are required to train an accurate cost network, and how accurate the cost network needs to be to enable a strong policy. Specifically, we randomly sample 10,000 cost data points from the DLRM-50 (4) dataset. Then we use $20\%$ for testing, and vary the size of the training data to train the cost network. Further, we fully train a policy network with 100 iterations based on each of the trained cost networks. We make two observations from the results in Figure 7. 1) As expected, more data points lead to a more accurate cost network. 2) Interestingly, after around 100 data points, the policy network does not keep improving even though the cost network becomes more accurate. Thus, we only need a sufficiently (but not perfectly) accurate cost estimation to achieve the best performance. This also partially explains why DreamShard can generalize: even though the cost network could be not very accurate on unseen tables, DreamShard can still find strong placements with the policy network. Second, we study the necessity of the estimated MDP. We consider a variant that obtains the cost features and rewards directly from GPUs, shown in Figure 8. Using the estimated MDP can make the training and the inference orders of magnitudes faster, while achieving the same level of performance. In particular, the inference time is less than one second even with a hundred tables.
+
+
+Figure 7: MSE of the cost network w.r.t. the number of training data points collected from GPUs (left), and the corresponding performance of a fully trained policy network based on the trained cost network (right) on the DLRM-50 (4) dataset.
+
+
+Figure 8: Training curves w/ or w/o the estimated MDP on DLRM-50 (4) dataset (left), and their inference times w.r.t. the number of tables (right). Using cost network to estimate the MDP leads orders of magnitudes faster training and inference.
+
+
+
+
+
+# 5 Related Work
+
+**Embedding tables.** Embedding tables are commonly used to deal with sparse features in recommendation models [1, 2, 3, 4, 5, 29, 30, 31]. However, the extremely large embedding tables are often the storage and efficiency bottlenecks [6, 7, 8, 3, 6, 9, 10, 11, 32]. To our knowledge, the only two studies that target the embedding table placement problem are RecShard [27] and our previous work AutoShard [33]. RecShard approaches table placement at a per-row granularity through exploitation of the underlying feature distributions. RecShard leverages these distributions, along with characteristics of the training system, to shard embedding tables across a tiered memory hierarchy using a mixed integer linear program, with more frequent rows placed in GPU HBM and the remaining placed in CPU DRAM. In contrast, our work develops a neural cost network for cost estimation and an RL-based optimization algorithm, and focuses on sharding across a single memory layer as opposed to a tiered memory hierarchy. AutoShard also leverages RL for embedding table sharding. However, it only balances the computational costs, which will lead to sub-optimal solutions since communication also accounts for significant costs. In addition, our DreamShard is more efficient in training than AutoShard due to the design of the estimated MDP. Another line of work focuses on reducing the embedding table sizes [34, 35, 36, 37, 38, 39, 40], which is orthogonal to our work since DreamShard is also applicable to compressed tables.
+
+Device placement optimization. The existing device placement techniques can be mainly grouped into two categories: RL-based algorithms, and cost modeling methods. 1) RL-based algorithms treat the device placement as a black box and optimize the cost objective in a trial-and-error fashion [13, 14, 15, 16, 17, 18, 19, 20]. Unfortunately, these methods are computationally expensive and often require training from scratch on unseen tasks. While Placeto [16] shows generalizability on computational graphs with graph embeddings, it can not deal with various table combinations since there is no graph structure, and it can not handle different numbers of devices. 2) Cost modeling methods build a cost model to reflect the real performance and adopt offline algorithms (e.g., scheduling, and dynamic programming) to optimize the placement [41, 42, 43, 44, 45]. However, the cost model could be inaccurate. In particular, they can not deal with the operation fusion of embedding tables. Whereas, DreamShard combines the advances of RL with a neural cost model for accurate cost prediction.
+
+Deep RL. Deep RL has recently made significant progress in games [46, 47, 48, 49, 50, 51, 52, 53, 54]. Our work is related to using RL to optimize machine learning model designs, such as neural architecture search [55, 56, 57, 58, 59], data augmentation [60], data sampling [61, 62], pipeline search [63, 64, 65]. However, these methods often only focus on one task and can not generalize to unseen tasks. Our work is related to meta-learning [66, 67, 68]. Instead of performing meta-learning for machine learning tasks, we focus on machine learning system design. Our work is also related to solving combinational optimization problems with RL [24, 69]. Unlike the above studies, we show that RL can tackle a practical problem of embedding table placement and the learned policy is generalizable.
+
+# 6 Conclusions and Future Work
+
+We present DreamShard for embedding table placement in recommender systems. We formulate the problem as an MDP which places the tables one by one at each step. Then we leverage RL to
+
+solve the MDP. To accelerate the training and the inference, we build an estimated MDP by training a cost network to approximate the state features (i.e., computation and communication times) and the reward (i.e., the overall cost), leading to orders of magnitudes faster training and inference speeds. Extensive experiments on the open-sourced DLRM dataset and our production dataset demonstrate the superiority of DreamShard over the existing algorithms. Moreover, DreamShard shows strong generalizability, making it a desirable choice in real-world applications. In the future, we will extend DreamShard to tiered memory hierarchy and large-scale training clusters with complex topologies.
+
+# Acknowledgements
+
+The work is, in part, supported by NSF (#IIS-2224843). The views and conclusions in this paper are those of the authors and should not be interpreted as representing any funding agencies. We would also like to thank the helpful feedback from the anonymous reviewers.
+
+# References
+
+[1] Shuai Zhang, Lina Yao, Aixin Sun, and Yi Tay. Deep learning based recommender system: A survey and new perspectives. ACM Computing Surveys (CSUR), 52(1):1-38, 2019.
+[2] Heng-Tze Cheng, Levent Koc, Jeremiah Harmsen, Tal Shaked, Tushar Chandra, Hrishi Aradhye, Glen Anderson, Greg Corrado, Wei Chai, Mustafa Ispir, et al. Wide & deep learning for recommender systems. In DLRS Workshop, 2016.
+[3] Maxim Naumov, Dheevatsa Mudigere, Hao-Jun Michael Shi, Jianyu Huang, Narayanan Sundaraman, Jongsoo Park, Xiaodong Wang, Udit Gupta, Carole-Jean Wu, Alisson G Azzolini, et al. Deep learning recommendation model for personalization and recommendation systems. arXiv preprint arXiv:1906.00091, 2019.
+[4] Xiangnan He, Lizi Liao, Hanwang Zhang, Liqiang Nie, Xia Hu, and Tat-Seng Chua. Neural collaborative filtering. In WWW, 2017.
+[5] Weiping Song, Chence Shi, Zhiping Xiao, Zhijian Duan, Yewen Xu, Ming Zhang, and Jian Tang. Autoint: Automatic feature interaction learning via self-attentive neural networks. In CIKM, 2019.
+[6] Weijie Zhao, Deping Xie, Ronglai Jia, Yulei Qian, Ruiquan Ding, Mingming Sun, and Ping Li. Distributed hierarchicalgpu parameter server for massive scale deep learning ads systems. In MLSys, 2020.
+[7] Paul Covington, Jay Adams, and Emre Sargin. Deep neural networks for youtube recommendations. In RecSys, 2016.
+[8] Bilge Acun, Matthew Murphy, Xiaodong Wang, Jade Nie, Carole-Jean Wu, and Kim Hazelwood. Understanding training efficiency of deep learning recommendation models at scale. In HPCA, 2021.
+[9] Amazon dsstne: Deep scalable sparse tensor network engine. https://github.com/amazon-archives/amazon-dsstne.
+[10] Udit Gupta, Carole-Jean Wu, Xiaodong Wang, Maxim Naumov, Brandon Reagen, David Brooks, Bradford Cottel, Kim Hazelwood, Mark Hempstead, Bill Jia, et al. The architectural implications of facebook's dnn-based personalized recommendation. In HPCA, 2020.
+[11] Maxim Naumov, John Kim, Dheevatsa Mudigere, Srinivas Sridharan, Xiaodong Wang, Whitney Zhao, Serhat Yilmaz, Changkyu Kim, Hector Yuen, Mustafa Ozdal, et al. Deep learning training in facebook data centers: Design of scale-up and scale-out systems. arXiv preprint arXiv:2003.09518, 2020.
+[12] Wikipedia. Partition problem — Wikipedia, the free encyclopedia. http://en.wikipedia.org/w/index.php?title=Partition%20problem&oldid=1085673119, 2022. [Online; accessed 05-May-2022].
+[13] Azalia Mirhoseini, Hieu Pham, Quoc V Le, Benoit Steiner, Rasmus Larsen, Yuefeng Zhou, Naveen Kumar, Mohammad Norouzi, Samy Bengio, and Jeff Dean. Device placement optimization with reinforcement learning. In ICML, 2017.
+
+[14] Azalia Mirhoseini, Anna Goldie, Hieu Pham, Benoit Steiner, Quoc V Le, and Jeff Dean. A hierarchical model for device placement. In ICLR, 2018.
+[15] Yuanxiang Gao, Li Chen, and Baochun Li. Spotlight: Optimizing device placement for training deep neural networks. In ICML, 2018.
+[16] Ravichandra Addanki, Shaileshh Bojla Venkatakrishnan, Shreyan Gupta, Hongzi Mao, and Mohammad Alizadeh. Placeto: learning generalizable device placement algorithms for distributed machine learning. In NeurIPS, 2019.
+[17] Yanqi Zhou, Sudip Roy, Amirali Abdolrashidi, Daniel Wong, Peter C Ma, Qiumin Xu, Ming Zhong, Hanxiao Liu, Anna Goldie, Azalia Mirhoseini, et al. Gdp: Generalized device placement for dataflow graphs. arXiv preprint arXiv:1910.01578, 2019.
+[18] Aditya Paliwal, Felix Gimeno, Vinod Nair, Yujia Li, Miles Lubin, Pushmeet Kohli, and Oriol Vinyals. Reinforced genetic algorithm learning for optimizing computation graphs. In ICLR, 2019.
+[19] Yuanxiang Gao, Li Chen, and Baochun Li. Post: Device placement with cross-entropy minimization and proximal policy optimization. In NeurIPS, 2018.
+[20] Anna Goldie and Azalia Mirhoseini. Placement optimization with deep reinforcement learning. In ISPD, 2020.
+[21] Wei Niu, Jiexiong Guan, Yanzhi Wang, Gagan Agrawal, and Bin Ren. Dnnfusion: accelerating deep neural networks execution with advanced operator fusion. In PLDI, 2021.
+[22] Daya Khudia, Jianyu Huang, Protonu Basu, Summer Deng, Haixin Liu, Jongsoo Park, and Mikhail Smelyanskiy. Fbgemm: Enabling high-performance low-precision deep learning inference. arXiv preprint arXiv:2101.05615, 2021.
+[23] github. Embedding lookup synthetic dataset, 2021.
+[24] Irwan Bello, Hieu Pham, Quoc V Le, Mohammad Norouzi, and Samy Bengio. Neural combinatorial optimization with reinforcement learning. arXiv preprint arXiv:1611.09940, 2016.
+[25] David Ha and Jürgen Schmidhuber. World models. arXiv preprint arXiv:1803.10122, 2018.
+[26] Danijar Hafner, Timothy Lillicrap, Jimmy Ba, and Mohammad Norouzi. Dream to control: Learning behaviors by latent imagination. In ICLR, 2019.
+[27] Geet Sethi, Bilge Acun, Niket Agarwal, Christos Kozyrakis, Caroline Trippel, and Carole-Jean Wu. Recshard: Statistical feature-based memory optimization for industry-scale neural recommendation. In ASPLOS, 2022.
+[28] Michael Lui, Yavuz Yetim, Özgür Özkan, Zhuoran Zhao, Shin-Yeh Tsai, Carole-Jean Wu, and Mark Hempstead. Understanding capacity-driven scale-out neural recommendation inference. In ISPASS, 2021.
+[29] Jizhe Wang, Pipei Huang, Huan Zhao, Zhibo Zhang, Binqiang Zhao, and Dik Lun Lee. Billion-scale commodity embedding for e-commerce recommendation in alibaba. In KDD, 2018.
+[30] Fuzheng Zhang, Nicholas Jing Yuan, Defu Lian, Xing Xie, and Wei-Ying Ma. Collaborative knowledge base embedding for recommender systems. In KDD, 2016.
+[31] Weijie Zhao, Jingyuan Zhang, Deping Xie, Yulei Qian, Ronglai Jia, and Ping Li. ABox: Ctr prediction model training on a single node. In CIKM, 2019.
+[32] Xiangru Lian, Binhang Yuan, Xuefeng Zhu, Yulong Wang, Yongjun He, Honghuan Wu, Lei Sun, Haodong Lyu, Chengjun Liu, Xing Dong, et al. Persia: A hybrid system scaling deep learning based recommenders up to 100 trillion parameters. arXiv preprint arXiv:2111.05897, 2021.
+[33] Daochen Zha, Louis Feng, Bhargav Bhushanam, Dhruv Choudhary, Jade Nie, Yuandong Tian, Jay Chae, Yinbin Ma, Arun Kejariwal, and Xia Hu. Autoshard: Automated embedding table sharding for recommender systems. In KDD, 2022.
+[34] Caojin Zhang, Yicun Liu, Yuanpu Xie, Sofia Ira Ktena, Alykhan Tejani, Akshay Gupta, Pranay Kumar Myana, Deepak Dilipkumar, Suvadip Paul, Ikuhiro Ihara, et al. Model size reduction using frequency based double hashing for recommender systems. In RecSys, 2020.
+
+[35] Hao-Jun Michael Shi, Dheevatsa Mudigere, Maxim Naumov, and Jiyan Yang. Compositional embeddings using complementary partitions for memory-efficient recommendation systems. In KDD, 2020.
+[36] Xiangyu Zhao, Chong Wang, Ming Chen, Xudong Zheng, Xiaobing Liu, and Jiliang Tang. Autoemb: Automated embedding dimensionality search in streaming recommendations. In SIGIR, 2020.
+[37] Manas R Joglekar, Cong Li, Mei Chen, Taibai Xu, Xiaoming Wang, Jay K Adams, Pranav Khaitan, Jiahui Liu, and Quoc V Le. Neural input search for large scale recommendation models. In KDD, 2020.
+[38] Siyi Liu, Chen Gao, Yihong Chen, Depeng Jin, and Yong Li. Learnable embedding sizes for recommender systems. In ICLR, 2021.
+[39] Wang-Cheng Kang, Derek Zhiyuan Cheng, Ting Chen, Xinyang Yi, Dong Lin, Lichan Hong, and Ed H Chi. Learning multi-granular quantized embeddings for large-vocab categorical features in recommender systems. In WWW, 2020.
+[40] Wang-Cheng Kang, Derek Zhiyuan Cheng, Tiansheng Yao, Xinyang Yi, Ting Chen, Lichan Hong, and Ed H Chi. Learning to embed categorical features without embedding tables for recommendation. In KDD, 2021.
+[41] Eugene L Lawler, Jan Karel Lenstra, Alexander HG Rinnooy Kan, and David B Shmoys. Sequencing and scheduling: Algorithms and complexity. *Handbooks in operations research and management science*, 4:445–522, 1993.
+[42] Zhihao Jia, Matei Zaharia, and Alex Aiken. Beyond data and model parallelism for deep neural networks. In $MLSys$ , 2019.
+[43] Zhihao Jia, Sina Lin, Charles R Qi, and Alex Aiken. Exploring hidden dimensions in parallelizing convolutional neural networks. In ICML, 2018.
+[44] Deepak Narayanan, Aaron Harlap, Amar Phanishayee, Vivek Seshadri, Nikhil R Devanur, Gregory R Ganger, Phillip B Gibbons, and Matei Zaharia. Pipedream: generalized pipeline parallelism for dnn training. In SOSP, 2019.
+[45] Jakub M Tarnawski, Amar Phanishayee, Nikhil Devanur, Divya Mahajan, and Fanny Nina Paravecino. Efficient algorithms for device placement of dnn graph operators. In NeurIPS, 2020.
+[46] Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Alex Graves, Ioannis Antonoglou, Daan Wierstra, and Martin Riedmiller. Playing atari with deep reinforcement learning. arXiv preprint arXiv:1312.5602, 2013.
+[47] David Silver, Julian Schrittwieser, Karen Simonyan, Ioannis Antonoglou, Aja Huang, Arthur Guez, Thomas Hubert, Lucas Baker, Matthew Lai, Adrian Bolton, et al. Mastering the game of go without human knowledge. nature, 550(7676):354-359, 2017.
+[48] Daochen Zha, Jingru Xie, Wenye Ma, Sheng Zhang, Xiangru Lian, Xia Hu, and Ji Liu. Douzero: Mastering doudizhu with self-play deep reinforcement learning. In ICML, 2021.
+[49] John Schulman, Filip Wolski, Prafulla Dhariwal, Alec Radford, and Oleg Klimov. Proximal policy optimization algorithms. arXiv preprint arXiv:1707.06347, 2017.
+[50] Daochen Zha, Kwei-Herng Lai, Kaixiong Zhou, and Xia Hu. Simplifying deep reinforcement learning via self-supervision. arXiv preprint arXiv:2106.05526, 2021.
+[51] Timothy P Lillicrap, Jonathan J Hunt, Alexander Pritzel, Nicolas Heess, Tom Erez, Yuval Tassa, David Silver, and Daan Wierstra. Continuous control with deep reinforcement learning. In ICLR, 2016.
+[52] Marcin Andrychowicz, Filip Wolski, Alex Ray, Jonas Schneider, Rachel Fong, Peter Welinder, Bob McGrew, Josh Tobin, OpenAI Pieter Abbeel, and Wojciech Zaremba. Hindsight experience replay. NeurIPS, 2017.
+[53] Daochen Zha, Wenye Ma, Lei Yuan, Xia Hu, and Ji Liu. Rank the episodes: A simple approach for exploration in procedurally-generated environments. In ICLR, 2021.
+[54] Daochen Zha, Kwei-Herng Lai, Songyi Huang, Yuanpu Cao, Keerthana Reddy, Juan Vargas, Alex Nguyen, Ruzhe Wei, Junyu Guo, and Xia Hu. Rlcard: a platform for reinforcement learning in card games. In IJCAI, 2021.
+
+[55] Barret Zoph and Quoc V Le. Neural architecture search with reinforcement learning. In ICLR, 2017.
+[56] Yicheng Wang, Xiaotian Han, Chia-Yuan Chang, Daochen Zha, Ulisses Braga-Neto, and Xia Hu. Auto-pinn: Understanding and optimizing physics-informed neural architecture. arXiv preprint arXiv:2205.13748, 2022.
+[57] Yuening Li, Zhengzhang Chen, Daochen Zha, Kaixiong Zhou, Haifeng Jin, Haifeng Chen, and Xia Hu. Automated anomaly detection via curiosity-guided search and self-imitation learning. IEEE Transactions on Neural Networks and Learning Systems, 2021.
+[58] Hieu Pham, Melody Guan, Barret Zoph, Quoc Le, and Jeff Dean. Efficient neural architecture search via parameters sharing. In ICML, 2018.
+[59] Yuening Li, Zhengzhang Chen, Daochen Zha, Kaixiong Zhou, Haifeng Jin, Haifeng Chen, and Xia Hu. Autood: Neural architecture search for outlier detection. In ICDE, 2021.
+[60] Ekin D Cubuk, Barret Zoph, Dandelion Mane, Vijay Vasudevan, and Quoc V Le. Autoaugment: Learning augmentation policies from data. arXiv preprint arXiv:1805.09501, 2018.
+[61] Daochen Zha, Kwei-Herng Lai, Mingyang Wan, and Xia Hu. Meta-aad: Active anomaly detection with deep reinforcement learning. In ICDM, 2020.
+[62] Daochen Zha, Kwei-Herng Lai, Qiaoyu Tan, Sirui Ding, Na Zou, and Xia Hu. Towards automated imbalanced learning with deep hierarchical reinforcement learning. In CIKM, 2022.
+[63] Iddo Drori, Yamuna Krishnamurthy, Remi Rampin, Raoni de Paula Lourenco, Jorge Piazentin Ono, Kyunghyun Cho, Claudio Silva, and Juliana Freire. Alphad3m: Machine learning pipeline synthesis. arXiv preprint arXiv:2111.02508, 2021.
+[64] Daochen Zha, Zaid Pervaiz Bhat, Yi-Wei Chen, Yicheng Wang, Sirui Ding, Anmoll Kumar Jain, Mohammad Qazim Bhat, Kwei-Herng Lai, Jiaben Chen, et al. Autovideo: An automated video action recognition system. In IJCAI, 2022.
+[65] Kwei-Herng Lai, Daochen Zha, Guanchu Wang, Junjie Xu, Yue Zhao, Devesh Kumar, Yile Chen, Purav Zumkhawaka, Minyang Wan, Diego Martinez, et al. Tods: An automated time series outlier detection system. In AAAI, 2021.
+[66] Chelsea Finn, Pieter Abbeel, and Sergey Levine. Model-agnostic meta-learning for fast adaptation of deep networks. In ICML, 2017.
+[67] Yue Zhao, Ryan Rossi, and Leman Akoglu. Automatic unsupervised outlier model selection. NeurIPS, 2021.
+[68] Yue Zhao and Leman Akoglu. Towards unsupervised hpo for outlier detection. arXiv preprint arXiv:2208.11727, 2022.
+[69] Thomas Barrett, William Clements, Jakob Foerster, and Alex Lvovsky. Exploratory combinatorial optimization with reinforcement learning. In AAAI, 2020.
+[70] Guorui Zhou, Na Mou, Ying Fan, Qi Pi, Weijie Bian, Chang Zhou, Xiaogiang Zhu, and Kun Gai. Deep interest evolution network for click-through rate prediction. In AAAI, 2019.
+[71] David C Liu, Stephanie Rogers, Raymond Shiau, Dmitry Kislyuk, Kevin C Ma, Zhigang Zhong, Jenny Liu, and Yushi Jing. Related pins at pinterest: The evolution of a real-world recommender system. In WWW, 2017.
+[72] Carlos A Gomez-Uribe and Neil Hunt. The netflix recommender system: Algorithms, business value, and innovation. ACM Transactions on Management Information Systems (TMIS), 6(4):1-19, 2015.
+[73] Ronald J Williams. Simple statistical gradient-following algorithms for connectionist reinforcement learning. Machine learning, 8(3):229-256, 1992.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] We have described the limitations in the future work.
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] Our work does have any potential negative societal impacts to our knowledge.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] The datasets are public. All the codes will be open-sourced.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] We provide all the details in the appendix.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] We have run all the experiments five times. The mean and the standard deviation are reported.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] We have described the hardware in the appendix.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [No] But it is mentioned in the link we provided.
+(c) Did you include any new assets either in the supplemental material or as a URL? [No]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [Yes]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/images.zip b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..5b63d1f29ba27c5f017f3e373873969403a2646f
--- /dev/null
+++ b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f800b8e1a24eca2e3956c439ad654304dce39d0cb0f3d8700c903aa12cda59c8
+size 541298
diff --git a/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/layout.json b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..fb0c1e2f914482e5c81c7e2ed9d62f07369efd4f
--- /dev/null
+++ b/dreamshardgeneralizableembeddingtableplacementforrecommendersystems/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1e54022019d1e3d80284ad5c3964cb449ac61ff79c49afb1c889d6ffc8390a1d
+size 458943
diff --git a/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/91a0e411-0419-4d5c-bce3-b3bc7a6abb08_content_list.json b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/91a0e411-0419-4d5c-bce3-b3bc7a6abb08_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..13dc62b894a61c84c98517d58402452b8fbf8b5a
--- /dev/null
+++ b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/91a0e411-0419-4d5c-bce3-b3bc7a6abb08_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:494a36e22981f83935b421385d1bb45a6fdcee8b1af512a9f1f0bd2bbca9af2b
+size 84262
diff --git a/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/91a0e411-0419-4d5c-bce3-b3bc7a6abb08_model.json b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/91a0e411-0419-4d5c-bce3-b3bc7a6abb08_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..9943b0342fefbca10d4083cf5c3cf5eba7899644
--- /dev/null
+++ b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/91a0e411-0419-4d5c-bce3-b3bc7a6abb08_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ceb447e46c742434d957f00ded658a1319c1079cc34aae91a441eb1b10861f33
+size 106157
diff --git a/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/91a0e411-0419-4d5c-bce3-b3bc7a6abb08_origin.pdf b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/91a0e411-0419-4d5c-bce3-b3bc7a6abb08_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..d7729e6f6bb46df5272275acbeab5b1f02b8667b
--- /dev/null
+++ b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/91a0e411-0419-4d5c-bce3-b3bc7a6abb08_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a9e9f84c9a0fcb0a9a9234c1e31374c85d6108488e95da149b50d845906c95e8
+size 520449
diff --git a/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/full.md b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..bd0e791c6fef8d92664089f251bf0449b2b3006f
--- /dev/null
+++ b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/full.md
@@ -0,0 +1,301 @@
+# DropCov: A Simple yet Effective Method for Improving Deep Architectures
+
+Qilong Wang $^{1,3}$ , Mingze Gao $^{1}$ , Zhaolin Zhang $^{1}$ , Jiangtao Xie $^{2}$ , Peihua Li $^{2}$ , Qinghua Hu $^{1,3,*}$
+
+$^{1}$ Tianjin University, China, $^{2}$ Dalian University of Technology, China, $^{3}$ Haihe Laboratory of Information Technology Application Innovation, Tianjin, China qlwang@tju.edu.cn, gaomingze@tju.edu.cn, zzl9@tju.edu.cn jiangtaoxie@mail.dlut.edu.cn, peihuali@dlut.edu.cn, huqinghua@tju.edu.cn
+
+# Abstract
+
+Previous works show global covariance pooling (GCP) has great potential to improve deep architectures especially on visual recognition tasks, where post-normalization of GCP plays a very important role in final performance. Although several post-normalization strategies have been studied, these methods pay more close attention to effect of normalization on covariance representations rather than the whole GCP networks, and their effectiveness requires further understanding. Meanwhile, existing effective post-normalization strategies (e.g., matrix power normalization) usually suffer from high computational complexity (e.g., $O(d^3)$ for $d$ -dimensional inputs). To handle above issues, this work first analyzes the effect of post-normalization from the perspective of training GCP networks. Particularly, we for the first time show that effective post-normalization can make a good trade-off between representation decorrelation and information preservation for GCP, which are crucial to alleviate over-fitting and increase representation ability of deep GCP networks, respectively. Based on this finding, we can improve existing post-normalization methods with some small modifications, providing further support to our observation. Furthermore, this finding encourages us to propose a novel pre-normalization method for GCP (namely DropCov), which develops an adaptive channel dropout on features right before GCP, aiming to reach trade-off between representation decorrelation and information preservation in a more efficient way. Our DropCov only has a linear complexity of $O(d)$ , while being free for inference. Extensive experiments on various benchmarks (i.e., ImageNet-1K, ImageNet-C, ImageNet-A, Stylized-ImageNet, and iNat2017) show our DropCov is superior to the counterparts in terms of efficiency and effectiveness, and provides a simple yet effective method to improve performance of deep architectures involving both deep convolutional neural networks (CNNs) and vision transformers (ViTs).
+
+# 1 Introduction
+
+Global covariance pooling (GCP) has shown remarkable potential to improve performance of deep architectures in a variety of tasks, especially visual recognition [31, 23, 29, 30, 8, 48, 36, 47, 51]. One of core differences among various deep GCP methods is post-normalization for covariance representations, which plays a crucial role in final performance. The existing post-normalization approaches can be roughly categorized into element-wise post-normalization methods [31, 25, 2] and structure-wise ones [23, 29, 28, 25, 36, 47], which concentrate on normalizing entries and
+
+eigenvalues of covariance matrices, respectively. Some researches (e.g., [30]) perform two kinds of normalizations simultaneously. Although several post-normalization strategies have been studied, behavior of different approaches seem vary significantly and there is a lack of an intuitive and unified interpretation. Therefore, the true mechanism lying behind these post-normalization methods (especially under deep architectures) is still an open problem.
+
+Existing works understand the effect of post-normalization methods of GCP from different aspects. Specifically, [31, 25] claim that their element-wise normalization strategies can suppress the burstiness of covariance representations as in the classical bag-of-words [37] or actually perform a kind of whitening on representations. $\mathrm{DeepO}_2\mathrm{P}$ [23] and MPN-COV [29] develop post-normalization methods to exploit geometry of covariances by considering the fact that space of covariance forms a Riemannian manifold [1, 34]. Besides, MPN-COV shows that matrix square-root (sqrt) normalization accounts for a robust covariance estimation [45], while [30] claims spectral normalization compensates for burstiness of eigenvalues and shows effectiveness of matrix sqrt normalization via empirical comparisons. Although many efforts are made, the aforementioned researches try to explain why GCP works by studying how post-normalizations affect covariance representations, which lack a full view on the whole GCP networks. Therefore, this work analyzes effect of post-normalization approaches on optimizing deep GCP networks. Particularly, by taking matrix power normalization [29] as an example, we find that post-normalization tries to handle a paradox between representation decorrelation and information preservation for GCP, which are crucial to alleviate over-fitting and increase representation ability of deep GCP networks, respectively. Particularly, effective post-normalization approaches can achieve a good trade-off, and so lead to a better performance. Based on this finding, we introduce some modified versions of existing post-normalization methods (e.g., adaptive power normalization for MPN-COV, I-LogM for $\mathrm{DeepO}_2\mathrm{P}$ , and linear transformation for B-CNN [31]), which achieve further improvement, providing support to our observation.
+
+Another issue of existing post-normalization methods is high computational complexity. Particularly, effective structure-wise post-normalization strategies usually involve singular value decomposition (SVD) of covariance matrices or sequential matrix multiplications, resulting in the computational complexity of $O(d^3)$ for $d$ -dimensional inputs. Inspired by finding above, this paper proposes an efficient pre-normalization method for GCP (namely DropCov) based on dropout [26], as it has the natural ability to perform feature decorrelation [4] and reduce over-fitting of training neural networks [26]. Specifically, our DropCov develops an adaptive channel dropout on features right before computation of covariance representations, where probability of dropout is adaptively decided by seeking a good trade-off between representation decorrelation and information preservation. Compared to existing post-normalization methods, our DropCov achieves superior or competitive performance with a linear computational complexity of $O(d)$ , while it is only used for training.
+
+To verify the effectiveness of our proposed DropCov, we conduct experiments using various deep architectures including CNNs [17] and vision transformers (ViT) [43, 32, 50] on ImageNet-1K [7], ImageNet-C [18], ImageNet-A [19], Stylized-ImageNet [13], and long-tailed iNat2017 [20]. The contributions of this work are summarized as follows: (1) To our best knowledge, this work for the first time analyzes the effect of post-normalization on GCP from the perspective of optimizing neural networks, and we show that effective post-normalization methods can make a good trade-off between representation decorrelation (w.r.t over-fitting reduction) and information preservation (w.r.t increase of representation ability) for GCP (w.r.t deep GCP networks); (2) Based on our finding, we make some small modifications to existing post-normalization methods (Sec. 2.2), e.g., adaptive power normalization and I-LogM & linear transformation. The comparisons in Sec. 5.2 show our modifications can bring further improvement, giving support on our observation; (3) Profiting from our finding, we propose a novel DropCov method by developing an adaptive channel dropout as pre-normalization of GCP, which has a linear complexity of $O(d)$ and is only used for training. Extensive experiments show our DropCov is superior or competitive to existing post-normalization approaches and provides a simple yet effective method to improve deep architectures.
+
+# 2 Effect of Post-normalization on Deep GCP Networks
+
+In this section, we first analyze the effect of post-normalization on optimizing deep GCP networks by taking matrix power normalization as an example. To further verify our finding, we spread it to existing post-normalization approaches, and make some modifications according to our observations.
+
+
+(a) Convergence curves of various $\alpha$
+
+
+(b) Generalization vs. representation ability
+Figure 1: Results of GCP networks with matrix power normalization (MPN) using the backbone of ResNet-18 ( $d = 128$ ) on ImageNet-1K. (a) Convergence curves of various $\alpha \in (0,1]$ ; (b) Comparison of generalization and representation abilities for various $\alpha$ . From them we can see that larger values of $\alpha$ result in higher training accuracies indicated by blue solid line in (b), w.r.t better representation or approximation ability, but suffer from heavier over-fitting (w.r.t worse generalization), aka larger differences of training accuracy over test one indicated by $\Delta$ . In contrast, smaller values of $\alpha$ have better generalization (aka smaller $\Delta$ ), while obtaining lower classification accuracies (w.r.t weaker representation ability). Particularly, $\alpha = 0.5$ achieves the best trade-off and so leads the best results.
+
+# 2.1 How Does Matrix Power Normalization Impact GCP
+
+Matrix Power Normalization Both previous works [47, 36] and our experiments show structure-wise post-normalization methods are generally superior to element-wise ones, where matrix power normalization (MPN) usually performs the most competitively. Let $\mathbf{X} \in \mathbb{R}^{N \times d}$ be $N$ $d$ -dimensional features with zero-mean those outputted by the last convolution layer of deep CNNs or the last transformer block of ViT (i.e., final word tokens), GCP computes $\mathbf{X}^T\mathbf{X}$ with post-normalization to generate a covariance representation $\mathbf{Z}$ . Specifically, GCP with MPN is calculated as
+
+$$
+\mathbf {Z} = \left(\mathbf {X} ^ {T} \mathbf {X}\right) ^ {\alpha} = \mathbf {U} \boldsymbol {\Lambda} ^ {\alpha} \mathbf {U} ^ {T}, \tag {1}
+$$
+
+where $\mathbf{Z} \in \mathbb{R}^{d \times d}$ is used for final classification. $\alpha > 0$ is a parameter of power. $\mathbf{U}$ and $\boldsymbol{\Lambda}$ are the matrix of eigenvectors and the diagonal matrix of eigenvalues of $\mathbf{X}^T\mathbf{X}$ , respectively.
+
+Effect of Power For MPN, power $\alpha$ has a significant effect on the final results. Previous works [29, 30] conduct empirical comparison of $\alpha$ , and choose the best one (e.g., $\alpha = 0.5$ ). However, the effect brought by $\alpha$ is still not very clear. In this work, we first analyze the effect of $\alpha \in (0,1]$ on optimizing deep GCP networks. It is clear from Eqn. (1) that $\alpha$ has the following effect on GCP from the mathematical perspective:
+
+$$
+\left\{ \begin{array}{l} \mathbf {Z} \longmapsto \mathbf {I}, \quad \text {i f} \quad \alpha \longmapsto 0: \text {R e p r e s e n t a t i o n D e c o r r e l a t i o n} \\ \mathbf {Z} \longmapsto \mathbf {X} ^ {T} \mathbf {X}, \quad \text {i f} \quad \alpha \longmapsto 1: \text {I n f o r m a t i o n P r e s e r v a t i o n} \end{array} \right. \tag {2}
+$$
+
+Specifically, when $\alpha \longmapsto 0$ , the normalized representation $\mathbf{Z}$ will be decorrelated and tend to be an identity matrix $\mathbf{I}$ . Such representation decorrelation can help optimization of neural networks [27, 22, 4] (in particular for combating over-fitting [5]), which, however, will lead to information loss for $\mathbf{X}^T\mathbf{X}$ , hurting representation ability of covariances. Particularly, $\mathbf{Z}$ with MPN of $\alpha = 0$ becomes an identity matrix, and the information lying in $\mathbf{X}^T\mathbf{X}$ completely loses. When $\alpha \longmapsto 1$ , information of $\mathbf{X}^T\mathbf{X}$ will be gradually preserved, maintaining the correlations as characterized in the covariance matrices, which makes training of neural networks difficult (e.g., over-fitting). To further verify above observation, we conduct experiments using ResNet-18 on ImageNet-1K (more results can refer to supplementary materials). By observing Figs. 1(a) and 1(b), we draw the following conclusion:
+
+- When $\alpha < 0.5$ , post-normalization (i.e., MPN) tends to decorrelate representation. According to red line of Fig. 1(b), smaller values of $\alpha$ reduce over-fitting more significantly and have better generalization (aka smaller differences of training accuracy over test one [3, 5]). Meantime, indicated by blue lines of Fig. 1(b), smaller $\alpha$ leads lower accuracies (w.r.t weaker representation or approximation ability [35, 47]) due to information loss.
+
+- When $\alpha > 0.5$ , post-normalization (i.e., MPN) tends to preserve information. The training accuracies (w.r.t representation or approximation ability) of deep GCP networks indicated by blue solid line of Fig. 1(b) increase along values of $\alpha$ enlarge, but heavier over-fitting (aka larger values of $\Delta$ ) occur because effect of representation decorrelation decreases.
+
+According to Eqn. (2) and above observation, we have
+
+Corollary 1. Effective post-normalization (e.g., matrix power normalization (MPN) with $0 < \alpha \leq 1$ ) can achieve a good trade-off between representation decorrelation and information preservation for GCP, which are crucial to alleviate over-fitting and increase representation ability of deep GCP networks, respectively. Particularly, MPN with $\alpha = 0.5$ achieves the best trade-off for $\alpha \in (0,1]$ (without considering other factors), which is proved to be the widely used choice of $\alpha$ [29, 30].
+
+The Corollary 1 illuminates the effect of MPN on deep GCP networks from the perspective of model training, and gives an intuitive explanation about the choice of parameter $\alpha$ .
+
+# 2.2 Extension of Corollary 1 to Existing Post-normalization Methods
+
+To further verify Corollary 1, we extend it to analyze behavior of existing post-normalization. Accompanied by these analyses, we can improve previous methods with some small modifications.
+
+Adaptive Power Normalization (APN) Above all, Corollary 1 shows MPN with $\alpha = 0.5$ is the best trade-off for $\alpha \in (0,1]$ if no other factor is considered. To further verify the effect of trade-off, we propose an adaptive power normalization (APN) by considering the effect of inputs (i.e., eigenvalues $\Lambda$ of covariances). Specifically, we formulate the trade-off between representation decorrelation and information preservation as the following objective function:
+
+$$
+\min _ {\alpha} \log \left(\frac {\lambda_ {m a x} ^ {\alpha}}{\lambda_ {m i n} ^ {\alpha}}\right), \quad s. t. \max _ {\alpha} \sum_ {i} \frac {\lambda_ {i} ^ {\alpha}}{\sum_ {i} \lambda_ {i} ^ {\alpha}} \log \left(\frac {\lambda_ {i} ^ {\alpha}}{\sum_ {i} \lambda_ {i} ^ {\alpha}}\right), \tag {3}
+$$
+
+where $\lambda_{max}$ and $\lambda_{min}$ are maximum and minimum of $\Lambda$ , respectively. Particularly, we minimize the ratio of $\lambda_{max}^{\alpha}$ to $\lambda_{min}^{\alpha}$ (in logarithmic coordinates) to enforce representation decorrelation. Here, smaller values of the objective function indicate stronger decorrelation, and $\alpha = 0$ achieves minimum (i.e., zero). On the other hand, we maximize negative entropy of normalized eigenvalues to keep discrepancy among eigenvalues and so preserve information, which achieves maximum value (i.e., zero) for $\alpha \rightarrow +\infty$ . By considering that previous works [29, 30] show relation between performance and $\alpha$ is generally convex, we exploit a grid search strategy to obtain a suboptimal solution for $\alpha \in (0,1]$ with the interval of $0.01^{2}$ . However, $\lambda_{min}$ is usually nearby zero, leading to computational instability. Therefore, we optimize the objective function (3) as
+
+$$
+\min _ {\alpha} \left[ \underbrace {\alpha \left(\log \left(\lambda_ {m a x}\right) - \log \left(\max \left(C , \lambda_ {m i n}\right)\right)\right)} _ {\text {r e p r e s e n t a t i o n d e c o r r e l a t i o n}} - \tau \sum_ {i = 1} ^ {K} \left(\lambda_ {i} ^ {\alpha} / \sum_ {i = 1} ^ {K} \lambda_ {i} ^ {\alpha}\right) \log \left(\lambda_ {i} ^ {\alpha} / \sum_ {i = 1} ^ {K} \lambda_ {i} ^ {\alpha}\right) \right], \tag {4}
+$$
+
+where we set minimum of $\lambda_{min}$ to a constant $C$ (e.g., 1e-2), and compute the entropy using Top-K eigenvalues. $\tau$ is a balance parameter, which is set to 1.2. Note that Eqn. (4) is computed efficiently for small $K$ ( $K \leq 3$ in our work) using about a hundred trials, given the eigenvalues $\Lambda$ .
+
+MPN with $\alpha > 1$ Theoretically, $\alpha$ of MPN could be larger than one, which, however, violates the principle of representation decorrelation. Meanwhile, it disrupts equilibrium between eigenvalues, hurting information inherent in covariances. As illustrated in Fig. 2, MPN with $\alpha = 2$ suffers from heavy over-fitting, and is clearly worse than one with $\alpha = 0.5$ .
+
+Matrix Logarithm Normalization (LogM) LogM [23] is one another popular structure-wise postnormalization. Mathematically, logarithm has similar behavior with power function of $\alpha = 0.3$ when eigenvalues $\lambda > 1$ , but reverses amplitudes of eigenvalues $\lambda < 1$ (i.e., neither decorrelation nor information preservation). However, small eigenvalues frequently occur in deep models [29], especially for large feature dimension $(d)$ . Accordingly, as shown in Fig. 2, LogM achieves similar
+
+results with MPN of $\alpha = 0.3$ for $d = 128$ . For $d = 256$ , GCP network with LogM fails to converge due to side effect brought by small eigenvalues ( $\lambda < 1$ ). Therefore, we modified LogM with a shift operation (namely I-LogM) to make all inputs of LogM be larger than one, i.e., $\log (\lambda_i)\longrightarrow \epsilon \log ((\lambda_i + \epsilon) / \epsilon)$ . Our I-LogM brings promising gains when $d = 256$ (see Sec. 5.2 and Table 6).
+
+Element-wise Normalization (EwN) EwN could be roughly written in a unified formulation: $\beta \frac{f(\mathbf{z}) - \mu}{\|f(\mathbf{z}) - \mu\|_{*}} + \gamma$ , where $\mathbf{z}$ is vectorization of $\mathbf{X}^T\mathbf{X}$ . $f$ is a mapping function and $\|\mathbf{a}\|_*$ indicates a certain norm of $\mathbf{a}$ . $\beta$ and $\gamma$ perform a linear transformation (LT). Particularly, for element-wise power normalization (EPN) [31], $f$ is a signed power function and $\mu = 0$ . $\|\mathbf{a}\|_*$ is a $\ell_2$ norm, and no LT is performed. For LN [2], $f$ is an identity mapping and $\mu$ is mean of $f(\mathbf{z})$ . $\|\mathbf{a}\|_*$ is a $\ell_2$ norm. According to above formulation and Corollary 1, EwN performs representation decorrelation based on zero-mean (i.e., $f(\mathbf{z}) - \mu$ ) and standardization (i.e., normalized by $\|f(\mathbf{z}) - \mu\|_*$ ), while LT
+
+
+Figure 2: Results of $\alpha >1$ & LogM
+
+operation aims to recover information. Compared to MPN, element-wise normalization lacks an effective mechanism to balance representation decorrelation and information preservation. Particularly, as shown in Sec. 5.2, EPN does not work well, since only representation decorrelation is performed. Therefore, we introduce a LT for EPN, and it achieves promising improvement (see Table 6).
+
+# 3 DropCov: A Simple yet Effective Normalization
+
+# 3.1 Normalizing GCP via Dropout
+
+Corollary 1 shows the core effect of effective post-normalization (e.g., MPN) lies in a good trade-off between representation decorrelation and information preservation for optimizing deep GCP networks. However, MPN suffers from high computational complexity (i.e., $O(d^{3})$ of $d$ -dimensional features), especially for high-dimensional inputs. Previous works [41, 5, 4] show that dropout can reduce correlation among features. Therefore, one question is naturally raised up: Could we use efficient dropout to perform representation decorrelation for GCP? Given probability $\rho$ of dropout, $\rho \rightarrow 1$ leading to sparser, less correlated features but more information loss. On the contrary, $\rho \rightarrow 0$ preserves more information while performing less decorrelation. Above observations show consistence with Corollary 1. However, there exist two issues to apply dropout for normalizing GCP: (1) how to perform dropout and (2) how to choose probability $\rho$ of dropout. A naive method is to perform dropout with a fixed $\rho$ after covariance representations (as compared in Table 2), but it has several limitations: first, dropout after covariance representations will break their structures (e.g., row $i$ of covariance means correlations among $i$ -th channel and all ones); second, fixed $\rho$ hardly achieves trade-off between representation decorrelation and information preservation; third, complexity of such strategy is quadratic to feature dimension $d$ (i.e., $O(d^{2})$ ), and is still high for large $d$ .
+
+# 3.2 Pre-Normalization via Adaptive Channel Dropout (ACD)
+
+To handle above issues, this work proposes a pre-normalization method (namely DropCov) by performing channel dropout with an adaptive probability $\rho$ on features $\mathbf{X}$ before GCP, which aims to reach a good trade-off between representation decorrelation and information preservation. Since DropCov performs representation decorrelation via an adaptive dropout operation on channel features before GCP, it can maintain structure of covariance representations, while having a more efficient, linear computational complexity of $O(d)$ . To reach the trade-off with adaptive probability $\rho$ , we compute it by considering two factors: (1) feature dimension $(d)$ and (2) relationship between feature correlation and feature importance. Then, we have
+
+$$
+\rho = 1 - \frac {D}{\log (d)} \left(\frac {\boldsymbol {\omega} ^ {T} \boldsymbol {\pi}}{\| \boldsymbol {\omega} \| \| \boldsymbol {\pi} \|}\right), \tag {5}
+$$
+
+$$
+\boldsymbol {\omega} = \sigma (\mathrm {C 1 D} _ {3} (\operatorname {G A P} (\mathbf {X})), \quad \boldsymbol {\pi} = \operatorname {S U M} _ {\operatorname {r o w}} (\mathbf {X} ^ {T} \mathbf {X}),
+$$
+
+where $\omega$ and $\pi$ represent feature importance and feature correlation, respectively. $D$ is a scaling parameter, which is set to 10 throughout all experiments. Since self-attention mechanisms [21, 46] are
+
+Table 1: Comparison of our DropCov with close related works in terms of formulation, computational complexity of post-normalization and usage mode. Please refer to Sec. 4 for the details of symbols.
+
+ | Method | Formulation | Complexity | Train | Infer. |
| Element-wise Post-Norm. | B-CNN [31] | \(\ell_{2}(sqrt(V(X^{T}X)))\) | \(O(d^{2})\) | ✓ | ✓ |
| SigmE [25] | \(2/(1+e^{-\beta \cdot V(X^{T}X)})-1\) | \(O(d^{2})\) | ✓ | ✓ |
| LN [2] | \(\beta \odot (V(X^{T}X)-\mu)/\sigma) \oplus \gamma\) | \(O(d^{2})\) | ✓ | ✓ |
| Structure-wise Post-Norm. | DeepO2P [23] | \(V(LogM(X^{T}X))\) | \(O(d^{3})\) | ✓ | ✓ |
| MPN-COV [29] | \(V((X^{T}X)^{\alpha})\) | \(O(d^{3})\) | ✓ | ✓ |
| IB-CNN [30] | \(\ell_{2}(sqrt(V(X^{T}X)^{1/2}))\) | \(O(d^{3})\) | ✓ | ✓ |
| iSQRT-COV [28] | \(V(\approx (X^{T}X)^{1/2})\) | \(O(d^{3})\) | ✓ | ✓ |
| MaxExp [25] | \(I-(I-X^{T}X/(X^{T}X+\varepsilon))^{\alpha}\) | \(O(d^{3})\) | ✓ | ✓ |
| Ours | DropCov | \(V(Y^{T}Y)\), \(Y=\delta_{\rho}(X)\) | \(O(d)\) | ✓ | × |
+
+*: Note $\beta$ and $\varepsilon$ are parameters. $\odot$ and $\oplus$ indicate element-wise multiplication and addition, respectively.
+
+usually used to search important features, we measure feature importance by modifying a light-weight channel attention module [46], which involves global average pooling (GAP), a 1D convolution with kernel size of 3 $(\mathrm{C1D}_3)$ , and softmax function $(\sigma)$ . As covariance $\mathbf{X}^T\mathbf{X}$ naturally characterizes correlation among different features, we compute feature correlation by summarizing the elements along row of $\mathbf{X}^T\mathbf{X}$ (i.e., $\mathrm{SUM}_{\mathrm{row}}(\mathbf{X}^T\mathbf{X})$ ). Note that we restrict $\rho$ of Eqn. (5) belongs to $(0,1)$ .
+
+As for Eqn. (5), we adaptively decide probability $\rho$ of channel dropout for reaching a good trade-off between representation decorrelation and information preservation, where $\frac{D}{\log(d)}$ and inner product of $\langle \pmb{\omega}, \pmb{\pi} \rangle$ are designed to consider effect of feature dimension $(d)$ and relationship between feature correlation and feature importance, respectively. In particular, larger feature dimension $d$ usually requires larger dropout probability $\rho$ . Meanwhile, feature correlation (i.e., $\pi$ ) and feature importance (i.e., $\omega$ ) are closely related to representation decorrelation and information preservation, respectively. Clearly, larger feature correlation results in stronger representation correlation, while features with larger channel weights contain more important information. Therefore, relationship between feature correlation and feature importance is good indicator to perform channel dropout. Intuitively, if feature correlation is closely related to (i.e., seriously decoupled with) feature importance, it is hard to select features for reaching a good trade-off between representation decorrelation and information preservation, and so we need to carefully adopt dropout for channel features under the random setting, leading to a small $\rho$ . Otherwise, we can perform dropout more safely to achieve a trade-off, and adopt a large $\rho$ . Note that we show behavior of $\rho$ during training in supplementary materials. Based on Eqn. (5), our DropCov is achieved by
+
+$$
+\mathbf {z} = \mathbf {V} \left(\mathbf {Y} ^ {T} \mathbf {Y}\right), \mathbf {Y} = \delta_ {\rho} (\mathbf {X}), \tag {6}
+$$
+
+where $\delta_{\rho}$ is a channel dropout operation with the probability of $\rho$ . $\mathbf{V}$ is a vectorization operation followed by triangulation, leading to a $d(d + 1) / 2$ -dimensional covariance representation $\mathbf{z}$ . Note that our DropCov (6) is only adopted to train GCP networks, which can be easily implemented by standard back-propagation. During inference stage, we simply use $\mathrm{V}(\mathbf{X}^T\mathbf{X})$ for final classification.
+
+# 4 Related Works
+
+In this section, we review some works closely related to our DropCov. Table 1 gives a detailed comparison of our DropCov with existing post-normalization methods in terms of formulation, computational complexity of post-normalization and usage mode. For element-wise post-normalization methods, B-CNN $^3$ [31] performs element-wise signed square-root (sqrt) followed by a $\ell_2$ normalization on covariance representations. [25] proposes to use some surrogate functions (e.g., SigmE) to handle issue of negative evidence inherent in power function. Layer normalization (LN) [2] is proposed to normalize each feature with its mean ( $\mu$ ) and variance ( $\gamma$ ) followed by a linear transformation. Since these
+
+methods perform normalization on each element of covariance representations, they have the computational complexity of $O(d^{2})$ for $d$ -dimensional features $\mathbf{X}$ . For structure-wise post-normalization methods, $\mathrm{DeepO}_2\mathrm{P}$ and MPN-COV [29] perform matrix logarithm (LogM) and matrix power function for covariance representations, respectively. IB-CNN [30] combines matrix square-root normalization with element-wise one, while iSQRT-COV [28] proposes an approximate matrix square-root normalization via fast iterative matrix multiplications. Song et al. further analyze the effect of iSQRT-COV [38] and develop a faster variant [39]. [25] introduces several spectral power functions (e.g., MaxExp) for normalizing covariance matrices. These structure-wise approaches involve SVD of covariances or sequential matrix multiplications, having the computational complexity of $O(d^{3})$ . ReDro [36] proposes a relation dropout scheme to divide a large-sized covariance into a group of small-sized ones, aiming to mitigate the computational issue of matrix normalization [29, 30, 28, 11]. ReDro reduces computational complexity of structure-wise approaches from $O(d^{3})$ to $O(d^{3} / G^{2})$ , where $G$ is the number of groups. Besides, all existing works perform post-normalization methods during both training and inference (Infer.) stages. Different from aforementioned works, our DropCov performs adaptive channel dropout $\delta$ on features $\mathbf{X}$ right before GCP, which has a linear complexity $O(d)$ and is free during inference stage. Experimental results in Sec. 5.3 show our DropCov with much less computational complexity is superior or competitive to previous works.
+
+# 5 Experiments
+
+In this section, we conduct experiments to evaluate effectiveness of our DropCov in improving deep architectures on image classification tasks. Specifically, we first describe implementation details, and then make ablation study on ImageNet-1K (IN-1K) [7] using backbone of ResNet-18. Additionally, we apply our DropCov to both ResNets [17] and ViT models [43, 32, 50], while comparing them on several benchmarks (i.e., IN-1K, ImageNet-C (IN-C) [18], ImageNet-A (IN-A) [19] and Stylized-ImageNet (Sty.-IN) [13]) to assess generalization and robustness of our DropCov. Finally, we assess generalization of DropCov models by transferring them to long-tailed species classification [20].
+
+Table 2: Comparisons (% in Top-1 accuracy) of adaptive normalization methods with the fixed ones using ResNet-18 on ImageNet-1K.
+
+| Method | d = 64 | d = 128 | d = 256 |
| DropElement (ρ = 0.5) | 73.4 | 74.6 | 74.0 |
| DropChannel (ρ = 0.5) | 70.1 | 73.1 | 75.1 |
| ACD (Ours) | 73.5 | 75.0 | 75.2 |
| MPN (α = 0.5) | 73.1 | 74.4 | 74.9 |
| APN (Ours) | 73.3 | 74.5 | 75.0 |
+
+Table 4: Comparisons (% in Top-1 accuracy) of various dropout variants using ResNet-18 on ImageNet-1K.
+
+| Method | dim=64 | dim=256 |
| Maxout [15] | 72.1 | 73.7 |
| Dropconnect [44] | 70.6 | 72.5 |
| Decov [5] | 72.7 | 74.0 |
| Maxdropout [9] | 72.0 | 70.1 |
| DropBlock [14] | 72.3 | 74.1 |
| ACD(Ours) | 73.5 | 75.2 |
+
+Table 3: Comparisons (% in Top-1 accuracy) of several specific dropout strategies using ResNet-18 on ImageNet-1K.
+
+| Method | d = 64 | d = 256 |
| Element Channel | Element Channel |
| Large (ρ = 0.5) | 72.2 | 71.3 | 71.4 | 70.9 |
| Small (ρ = 0.5) | 68.4 | 71.2 | 66.4 | 71.5 |
| Uniform (ρ = 0.5) | 72.8 | 72.1 | 74.0 | 74.4 |
| ACD (Ours) | 73.5 | 75.2 |
+
+Table 5: Comparisons (% in Top-1 accuracy) of DropElement and DropChannel with various drop rates $(\rho)$ using ResNet-18 on ImageNet-1K.
+
+ | Channel Dropout | Element Dropout |
| ρ | dim = 64 | dim = 256 | dim = 64 | dim = 256 |
| 0.1 | 72.5 | 71.9 | 72.3 | 70.8 |
| 0.3 | 72.8 | 74.7 | 72.8 | 72.3 |
| 0.5 | 70.1 | 75.1 | 73.4 | 74.0 |
| 0.7 | 65.7 | 72.1 | 72.1 | 74.2 |
| 0.9 | 20.5 | 54.7 | 68.2 | 73.8 |
| ACD (Ours) | 73.5 | 75.2 | 73.5 | 75.2 |
+
+# 5.1 Implementation Details
+
+In this work, we apply our DropCov to several ResNets [17] and ViT models [43, 32, 50]. Specifically, we construct DropCov models based on ResNet following exactly the same schemes in [29, 47]. Given a CNN backbone, we first introduce a $1 \times 1$ convolution after the last convolution layer for reducing dimension of features to $d$ , and then replace the original GAP by our DropCov followed by
+
+a fully-connected (FC) layer and softmax for classification. All models are optimized using the same hyper-parameter settings and data augmentations as suggested in [17, 29], where stochastic gradient descent (SGD) with initial learning rate $(lr)$ of 0.1 is used to train the networks within 100 epochs and $lr$ is decayed by 10 every 30 epochs. We combine DropCov with ViT models as in [49], where one FC layer is employed to reduce dimension of final word tokens, and our DropCov replaces GAP and classification token for Swin Transformers [32] and DeiT/T2T-ViT [43, 50], respectively. These models are trained by using the same hyper-parameter settings in [43, 32, 50]. All programs run a sever equipped with eight Nvidia RTX 3090 GPUs and 128G RAM. Source code (e.g., PyTorch [33], PaddlePaddle and Mindspace) will be available at https://github.com/mingzeG/DropCov.
+
+# 5.2 Ablation Study
+
+In this subsection, we conduct experiments on ImageNet-1K using lightweight ResNet-18 to assess effect of adaptive probability $\rho$ of dropout on our method, while compare with several dropout strategies, and finally assess effect of our modifications on existing post-normalization approaches.
+
+Fixed $\rho$ vs. ACD. Our DropCov performs pre-normalization for GCP by using an adaptive channel dropout (ACD) method, which automatically determines probability $\rho$ of dropout by considering trade-off between representation decorrelation and information preservation. We compare with two kinds of baseline dropout methods using fixed $\rho = 0.5$ , i.e., element-wise dropout for covariance representations (DropElement) and channel dropout for input features (DropChannel). As shown in the upper part of Table 2, our ACD achieves the best results for various feature dimensions $(d)$ and clearly outperforms the naive DropElement in Sec. 3.1. Besides, we compare with DropElement and DropChannel with various dropout ratios. As compared in Table 5, our ACD is superior to DropElement and DropChannel for all dropout ratios. Particularly, the best dropout ratios are quite different for two methods and various feature dimensions. In contrast, our ACD can adaptively determine probability $\rho$ of dropout by balancing representation decorrelation and information preservation, while always achieving the best performance, clearly verifying ACD can achieve a better trade-off.
+
+Comparison of Various Dropout Strategies. To verify the effectiveness of our ACD, we compare with several dropout strategies. First, we perform element-wise (Element) dropout on some specific entries of covariance with $\rho = 0.5$ . Specifically, we rank all entries of covariance in a descending order, and then perform dropout on top/bottom/uniform half of the ordered entries (namely Large/Small/Uniform). We adopt similar strategies to feature channels (Channel), where channel indicators are decided by attention module of our ACD. Note that 'Element' dropout preforms dropout on elements of covariance representations based on values of elements $([\mathbf{X}^T\bar{\mathbf{X}}]_{ij})$ , which indicates correlation between $i$ -th channel and $j$ -th channel. Therefore, it only considers feature correlation. For 'Channel' dropout, it preforms dropout on feature channels based on their weights, which are obtained by attention module of ACD (i.e., $\omega$ ). Therefore, it only considers feature importance. Based on above discussion, 'Element' and 'Channel' dropout methods can be regarded as special cases of ACD, where only feature correlation or feature importance are considered, respectively. As compared in Table 3, uniform dropout clearly outperforms those only focus on largest and smallest entries, indicating equilibrium of feature correlation or importance is crucial to final performance. Furthermore, our ACD is superior to uniform dropout by a clear margin. Besides, we compare with several existing Dropout variants, including Maxout [15], DropConnect [44], Decov [5], maxdropout [9] and DropBlock [14]. As shown in Table 4, our ACD clearly outperforms them. Although these methods can prevent overfitting, they are not good at making a balance between representation decorrelation and information preservation. These results further demonstrate the effectiveness of our ACD.
+
+Effect of Modifications. According to Corollary 1, we make several modifications to existing post-normalization approaches. Beyond MPN, we propose an APN method by considering eigenvalues $\Lambda$ of inputs (see Eqns. (3) and(4)). The results are compared in the bottom part of Table 2, where our APN determines $\alpha$ by considering effect of inputs while average values of $\alpha$ are 0.53, 0.49 and 0.45 for $d = 256$ , $d = 128$ and $d = 64$ , respectively. Clearly, average values of $\alpha$ achieved by APN are nearby 0.5, which further account for why 0.5 is the widely used choice of $\alpha$ for MPN. Besides, APN brings $0.1\% \sim 0.2\%$ gains over MPN with $\alpha = 0.5$ by considering effect of inputs. We would like to clarify they are non-trivial gains on ImageNet over strong MPN, and the recent works [38, 40] also bring similar gains ( $0.1\% \sim 0.3\%$ ) over MPN. Besides, as discussed in Sec.2.2, we introduce an I-LogM and a linear transform (LT) based on BN [22] for improving LogM normalization (DeepO $_2$ P)
+
+Table 6: Comparison of DropCov with several post-normalization in terms of Top-1 accuracy (Acc.) and running speed using ResNet-18 on ImageNet-1K. $\star$ : According to Sec.2.2 and Corollary 1, we modify B-CNN and IB-CNN with a linear transform (LT), while modifying $\mathrm{DeepO}_2\mathrm{P}$ with I-LogM.
+
+| Method | d = 64 | d = 256 |
| Top-1 Acc. (%) | Train (μs) | Test (μs) | Top-1 Acc. (%) | Train (μs) | Test (μs) |
| Plain GCP | 71.1 | 3.45 | 1.04 | 70.0 | 35.08 | 11.89 |
| B-CNN [31] | 38.3 | 4.31 | 1.23 | 41.1 | 44.97 | 14.38 |
| B-CNN + LT* | 68.3 | 4.45 | 1.28 | 73.2 | 47.37 | 15.24 |
| LN [2] | 71.7 | 4.10 | 1.13 | 70.2 | 40.79 | 13.59 |
| DeepO2P [23] | 70.1 | 922.50 | 910.95 | Not Converge | 9731.71 | 9638.71 |
| I-LogM* | 71.2 | 922.53 | 910.98 | 72.0 | 9732.46 | 9639.65 |
| MPN-COV [29] | 73.1 | 925.16 | 913.87 | 74.9 | 9735.11 | 9642.43 |
| iSQRT-COV [28] | 73.4 | 12.35 | 4.94 | 75.2 | 193.65 | 77.46 |
| IB-CNN [30] | Not Converge | 13.93 | 5.16 | 36.1 | 202.38 | 80.55 |
| IB-CNN + LT* | 70.0 | 14.16 | 5.21 | 72.8 | 207.48 | 82.98 |
| DropCov (Ours) | 73.5 | 3.54 | 1.04 | 75.2 | 36.20 | 11.89 |
+
+: Note we compute running speed $(\mu s)$ of single GCP module with post-normalization on a 2080Ti GPU. The original ResNet-18 with GAP achieves $70.2\%$ in Top-1 accuracy.
+
+and element-wise post-normalization (i.e., B-CNN and IB-CNN), respectively. As shown in Table 6, $\mathrm{DeepO}_2\mathrm{P}$ performs poorly troubled by small eigenvalues (especially for $d = 256$ ), while our I-LogM obtains promising gains for both low- and high-dimensional features. Furthermore, B-CNN and IB-CNN achieve very unsatisfied results; in contrast, our simple modification brings significant improvement for B-CNN and IB-CNN. Above results clearly verify our finding in Corollary 1.
+
+# 5.3 Comparisons with Counterparts
+
+Here, we conduct experiments on ImageNet-1K using ResNet-18 for comparing with existing post-normalization methods in terms of Top-1 accuracy and running speed, including B-CNN [31], LN [2], DeepO $_2$ P [23], MPN-COV [29] with $\alpha = 0.5$ , iSQRT-COV [28] and IB-CNN [30]. The results of all compared methods are listed in Table 6, where we can see that our DropCov outperforms plain GCP (i.e., GCP without normalization) by $2.4\%$ ( $5.2\%$ ) for $d = 64$ ( $d = 256$ ) with similar running time. Compared with element-wise post-normalization (i.e., LN, B-CNN and IB-CNN), our DropCov achieves significant performance gains while requiring less running time. For structure-wise post-normalization, our DropCov is remarkably superior to matrix logarithm normalization (DeepO $_2$ P) in terms of both accuracy and running speed. Meanwhile, DropCov is superior or comparable to MPN-COV and iSQRT-COV using much less running time, especially during inference stage. Above results show our DropCov performs better or on par with the counterparts in terms of efficiency and effectiveness, providing an very promising normalization method for deep GCP networks.
+
+# 5.4 Comparisons with Various Deep Architectures
+
+CNNs. Here we apply our DropCov with $d = 128$ to various CNNs, including ResNet-34, ResNet-50 and ResNet-101. Meanwhile, we compare DropCov with the original CNNs on IN-1K, IN-C, IN-A and Sty.-IN. As shown in the upper part of Table 7, DropCov respectively brings about $2.6\%$ , $2.2\%$ and $1.8\%$ gains over ResNet-34, ResNet-50 and ResNet-101 on IN-1K, while showing stronger robustness on IN-C, IN-A and Sty.-IN. Particularly, DropCov with ResNet-50 and ResNet-101 are respectively superior to the original ResNet-101 and ResNet-152, but having less model complexity.
+
+ViT. For ViT models, we apply our DropCov with $d = 128$ to DeiT-S [43], Swin-T [32] and T2T-ViT-14 [50], and compare the original models as well as ConViT [6]. As shown in the bottom part of Table 7, DropCov brings about $2.6\%$ , $1.3\%$ and $1.2\%$ gains over DeiT-S, Swin-T and T2T-ViT-14 on IN-1K, respectively. Meanwhile, it shows stronger robustness on IN-C, IN-A and Sty.-IN. Particularly, DropCov with DeiT-S is superior to DeiT-B and ConViT-B, but having less model complexity. Above results show our DropCov provides a simple yet effective method to improve deep architectures, and deep architectures with DropCov achieve better trade-off between accuracy and model complexity.
+
+Table 7: Comparison of our DropCov with various ResNet and ViT models on four datasets, where results in terms of mCE and Top-1 accuracy (\%) are reported on IN-C and reminding ones, receptively.
+
+| Method | Params. | FLOPs | IN-1K (↑) | IN-C (↓) | IN-A (↑) | Sty.-IN (↑) |
| ResNet-34 [17] | 21.8 M | 3.66 G | 74.19 | 77.9 | 1.63 | 7.59 |
| ResNet-50 [17] | 25.6 M | 3.86 G | 76.02 | 76.7 | 2.47 | 7.15 |
| ResNet-101 [17] | 44.6 M | 7.57 G | 77.67 | 70.3 | 4.15 | 9.51 |
| ResNet-152 [17] | 60.2 M | 11.28 G | 78.13 | 69.3 | 5.98 | 10.09 |
| ResNet-34+DropCov (Ours) | 29.6 M | 5.56 G | 76.81(2.62) | 71.1(6.8) | 3.45(1.82) | 11.16(3.57) |
| ResNet-50+DropCov (Ours) | 32.0 M | 6.19 G | 78.19(2.17) | 69.8(6.9) | 5.08(2.61) | 9.90(2.75) |
| ResNet-101+DropCov (Ours) | 51.0 M | 9.90 G | 79.51(1.84) | 65.8(4.5) | 7.54(3.39) | 11.41(1.90) |
| DeiT-S [43] | 22.1 M | 4.6 G | 79.8 | 54.6 | 18.9 | 14.91 |
| Swin-T [32] | 28.3 M | 4.5 G | 81.2 | 62.0 | 21.6 | 13.40 |
| T2T-ViT-14 [50] | 21.5 M | 5.2 G | 81.5 | 53.2 | 23.9 | 15.80 |
| DeiT-B [43] | 86.6 M | 17.6 G | 82.0 | 48.5 | 27.4 | 17.94 |
| ConViT-B [6] | 86.5 M | 17.7 G | 82.4 | 46.9 | 29.0 | 19.67 |
| DeiT-S+DropCov (Ours) | 25.6 M | 5.5 G | 82.4(2.6) | 52.6(2.0) | 31.2(12.3) | 17.10(2.19) |
| Swin-T+DropCov (Ours) | 31.6 M | 6.0 G | 82.5(1.3) | 54.8(7.2) | 33.1(11.5) | 14.13(0.73) |
| T2T-ViT-14+DropCov (Ours) | 24.9 M | 5.4 G | 82.7(1.2) | 52.1(1.1) | 31.7(7.8) | 18.81(3.01) |
+
+# 5.5 Comparisons on Long-tailed Benchmark
+
+Finally, we transfer our DropCov models to iNat2017 [20], and compare with several deep architectures, i.e., ResNet-101, ResNet-152, Inception V3 (IncV3) [42] with SE [21] as well as the recently proposed ViT [10] and TransFG [16]. Specifically, we perform fine-tuning of our DropCov models with backbones of ResNet-101 and DeiT-S on iNat2017, namely DropCov (ResNet-101) and DropCov (DeiT-S). As shown in Table 8, our DropCov (ResNet-101) obtains $5.5\%$ gains over the original ResNet-101, while outperforming ResNet-152 and IncV3 SE. Besides, our DropCov (DeiT-S) respectively outperforms ViT-B and TransFG by $3.7\%$ and
+
+Table 8: Comparisons (%) on iNat2017.
+
+| Method | Top-1 | Top-5 |
| ResNet-101 | 62.4 | 84.1 |
| ResNet-152 | 64.2 | 85.5 |
| IncV3 SE | 66.3 | 86.7 |
| ViT-B_16 (IN-21K) [10] | 68.7 | N/A |
| TransFG (IN-21K) [16] | 71.7 | N/A |
| DropCov (ResNet-101) | 67.9 | 87.3 |
| DropCov (DeiT-S) | 72.4 | 90.3 |
+
+$0.7\%$ , which are pre-trained on ImageNet-21K. The results clearly verify generalization of DropCov.
+
+# 6 Conclusion
+
+In this paper, we first analyze the effect of post-normalization on GCP from the perspective of optimizing deep GCP networks. Particularly, we find that effective post-normalization methods have a good ability to balance representation decorrelation and information preservation, which can reduce over-fitting and increase representation ability of deep GCP networks, respectively. According to our finding, we introduce some strategies to improve existing normalization methods, further verifying our finding. More importantly, we propose a novel pre-normalization for GCP (namely DropCov) based on adaptive channel dropout, which achieves very competitive performance with a linear complexity and training-only mode. Extensive experiments identify that our DropCov provides a simple yet effective solution to improve existing deep architectures on image classification tasks.
+
+GCP normally produces a high-dimensional covariance representation, bringing a certain amount of computational cost, but our work makes use of high-dimensional GCP more flexible. Meanwhile, our DropCov can achieve clear gains for low-dimensional GCP with little extra computational cost (refer to Table 6). Additionally, our DropCov is potentially applicable to compact GCP methods [12, 24] and encourages exploration of other effective dropout strategies, which will be studied in future work.
+
+# Acknowledgment
+
+The work was sponsored by National Natural Science Foundation of China (Grant No.s 62276186, 61925602, 61971086 and 61732011), CCF-Baidu Open Fund (NO.2021PP15002000), CAAIXSJLJJ-2022-010C and Haihe Lab of ITAI (NO. 22HHXCJC00002).
+
+# References
+
+[1] V. Arsigny, P. Fillard, X. Pennec, and N. Ayache. Fast and simple calculus on tensors in the Log-Euclidean framework. In MICCAI, 2005.
+[2] L. J. Ba, J. R. Kiros, and G. E. Hinton. Layer normalization. CoRR, abs/1607.06450, 2016.
+[3] C. M. Bishop. Pattern recognition and machine learning, 5th Edition. Information science and statistics. Springer, 2007.
+[4] G. Chen, P. Chen, Y. Shi, C. Hsieh, B. Liao, and S. Zhang. Rethinking the usage of batch normalization and Dropout in the training of deep neural networks. CoRR, abs/1905.05928, 2019.
+[5] M. Cogswell, F. Ahmed, R. B. Girshick, L. Zitnick, and D. Batra. Reducing overfitting in deep networks by decorrelating representations. In ICLR, 2016.
+[6] S. d'Ascoli, H. Touvron, M. L. Leavitt, A. S. Morcos, G. Biroli, and L. Sagun. ConViT: Improving vision transformers with soft convolutional inductive biases. In ICML, 2021.
+[7] J. Deng, W. Dong, R. Socher, L.-J. Li, K. Li, and L. Fei-Fei. ImageNet: A large-scale hierarchical image database. In CVPR, 2009.
+[8] A. Diba, V. Sharma, and L. Van Gool. Deep temporal linear encoding networks. In CVPR, 2017.
+[9] C. F. G. dos Santos, D. Colombo, M. Roder, and J. P. Papa. Maxdropout: Deep neural network regularization based on maximum output values. In ICPR, 2020.
+[10] A. Dosovitskiy, L. Beyer, A. Kolesnikov, D. Weissenborn, X. Zhai, T. Unterthiner, M. Dehghani, M. Minderer, G. Heigold, S. Gelly, et al. An image is worth 16x16 words: Transformers for image recognition at scale. In ICLR, 2021.
+[11] M. Engin, L. Wang, L. Zhou, and X. Liu. DeepKSPD: Learning kernel-matrix-based SPD representation for fine-grained image recognition. In ECCV, 2018.
+[12] Y. Gao, O. Beijbom, N. Zhang, and T. Darrell. Compact bilinear pooling. In CVPR, 2016.
+[13] R. Geirhos, P. Rubisch, C. Michaelis, M. Bethge, F. A. Wichmann, and W. Brendel. ImageNet-trained CNNs are biased towards texture; increasing shape bias improves accuracy and robustness. In ICLR, 2019.
+[14] G. Ghiasi, T. Lin, and Q. V. Le. DropBlock: A regularization method for convolutional networks. In NeurIPS, 2018.
+[15] I. J. Goodfellow, D. Warde-Farley, M. Mirza, A. C. Courville, and Y. Bengio. Maxout networks. In ICML, 2013.
+[16] J. He, J.-N. Chen, S. Liu, A. Kortylewski, C. Yang, Y. Bai, C. Wang, and A. Yuille. TransFG: A transformer architecture for fine-grained recognition. In AAAI, 2022.
+[17] K. He, X. Zhang, S. Ren, and J. Sun. Deep residual learning for image recognition. In CVPR, 2016.
+[18] D. Hendrycks and T. G. Dietterich. Benchmarking neural network robustness to common corruptions and perturbations. In ICLR, 2019.
+[19] D. Hendrycks, K. Zhao, S. Basart, J. Steinhardt, and D. Song. Natural adversarial examples. In CVPR, 2021.
+[20] G. V. Horn, O. M. Aodha, Y. Song, Y. Cui, C. Sun, A. Shepard, H. Adam, P. Perona, and S. J. Belongie. The iNaturalist species classification and detection dataset. In CVPR, 2018.
+[21] J. Hu, L. Shen, S. Albanie, G. Sun, and E. Wu. Squeeze-and-excitation networks. IEEE Trans. Pattern Anal. Mach. Intell., 42(8):2011-2023, 2020.
+[22] S. Ioffe and C. Szegedy. Batch Normalization: Accelerating deep network training by reducing internal covariate shift. In ICML, 2015.
+[23] C. Ionescu, O. Vantzos, and C. Sminchisescu. Matrix backpropagation for deep networks with structured layers. In ICCV, 2015.
+[24] S. Kong and C. C. Fowlkes. Low-rank bilinear pooling for fine-grained classification. In CVPR, 2017.
+[25] P. Koniusz, H. Zhang, and F. Porikli. A deeper look at power normalizations. In CVPR, 2018.
+[26] A. Krizhevsky, I. Sutskever, and G. E. Hinton. ImageNet classification with deep convolutional neural networks. In NIPS, 2012.
+[27] Y. LeCun, I. Kanter, and S. A. Solla. Second order properties of error surfaces. In NIPS, 1990.
+[28] P. Li, J. Xie, Q. Wang, and Z. Gao. Towards faster training of global covariance pooling networks by iterative matrix square root normalization. In CVPR, 2018.
+[29] P. Li, J. Xie, Q. Wang, and W. Zuo. Is second-order information helpful for large-scale visual recognition? In ICCV, 2017.
+[30] T. Lin and S. Maji. Improved bilinear pooling with CNNs. In BMVC, 2017.
+[31] T. Lin, A. RoyChowdhury, and S. Maji. Bilinear CNN models for fine-grained visual recognition. In ICCV, 2015.
+[32] Z. Liu, Y. Lin, Y. Cao, H. Hu, Y. Wei, Z. Zhang, S. Lin, and B. Guo. Swin transformer: Hierarchical vision transformer using shifted windows. In ICCV, 2021.
+[33] A. Paszke, S. Gross, F. Massa, A. Lerer, J. Bradbury, G. Chanan, T. Killeen, Z. Lin, N. Gimelshein, L. Antiga, A. Desmaison, A. Köpf, E. Z. Yang, Z. DeVito, M. Raison, A. Tejani, S. Chilamkurthy, B. Steiner, L. Fang, J. Bai, and S. Chintala. Pytorch: An imperative style, high-performance deep learning library. In NeurlPS, 2019.
+
+[34] X. Pennec, P. Fillard, and N. Ayache. A Riemannian framework for tensor computing. *IJCV*, 66(1):41-66, 2006.
+[35] T. Poggio, A. Banburski, and Q. Liao. Theoretical issues in deep networks. Proceedings of the National Academy of Sciences (PNAS), 117(48):30039-30045, 2020.
+[36] S. Rahman, L. Wang, C. Sun, and L. Zhou. ReDro: Efficiently learning large-sized SPD visual representation. In ECCV, 2020.
+[37] J. Sánchez, F. Perronnin, T. Mensink, and J. Verbeek. Image classification with the Fisher Vector: Theory and practice. IJCV, 105(3):222-245, 2013.
+[38] Y. Song, N. Sebe, and W. Wang. Why approximate matrix square root outperforms accurate SVD in global covariance pooling? In ICCV, 2021.
+[39] Y. Song, N. Sebe, and W. Wang. Fast differentiable matrix square root. In ICLR, 2022.
+[40] Y. Song, N. Sebe, and W. Wang. Improving covariance conditioning of the SVD meta-layer by orthogonality. In ECCV, 2022.
+[41] N. Srivastava, G. E. Hinton, A. Krizhevsky, I. Sutskever, and R. Salakhutdinov. Dropout: a simple way to prevent neural networks from overfitting. J. Mach. Learn. Res., 15(1):1929-1958, 2014.
+[42] C. Szegedy, V. Vanhoucke, S. Ioffe, J. Shlens, and Z. Wojna. Rethinking the inception architecture for computer vision. In CVPR, 2016.
+[43] H. Touvron, M. Cord, M. Douze, F. Massa, A. Sablayrolles, and H. Jégou. Training data-efficient image transformers & distillation through attention. In ICML, 2021.
+[44] L. Wan, M. D. Zeiler, S. Zhang, Y. LeCun, and R. Fergus. Regularization of neural networks using dropconnect. In ICML, 2013.
+[45] Q. Wang, P. Li, W. Zuo, and L. Zhang. RAID-G: Robust estimation of approximate infinite dimensional Gaussian with application to material recognition. In CVPR, 2016.
+[46] Q. Wang, B. Wu, P. Zhu, P. Li, W. Zuo, and Q. Hu. ECA-Net: Efficient channel attention for deep convolutional neural networks. In CVPR, 2020.
+[47] Q. Wang, J. Xie, W. Zuo, L. Zhang, and P. Li. Deep CNNs meet global covariance pooling: Better representation and generalization. IEEE TPAMI, 43(8), 2020.
+[48] T. Winterbottom, S. Xiao, A. McLean, and N. A. Moubayed. Trying bilinear pooling in Video-QA. arXiv preprint arXiv:2012.10285, 2020.
+[49] J. Xie, R. Zeng, Q. Wang, Z. Zhou, and P. Li. So-ViT: Mind visual tokens for vision transformer. CoRR, abs/2104.10935, 2021.
+[50] L. Yuan, Y. Chen, T. Wang, W. Yu, Y. Shi, Z.-H. Jiang, F. E. Tay, J. Feng, and S. Yan. Tokens-to-Token ViT: Training vision transformers from scratch on ImageNet. In ICCV, 2021.
+[51] J. Zhang, L. Wang, L. Zhou, and W. Li. Beyond Covariance: SICE and kernel based visual feature representation. Int. J. Comput. Vis., 129(2):300-320, 2021.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes] See Abstract and Section 1.
+(b) Did you describe the limitations of your work? [Yes] See Section 6.
+(c) Did you discuss any potential negative societal impacts of your work? [No]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] See Section 5.1 and Supplemental Material.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Section 5.1 and Supplemental Material.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] We share the same settings with compared methods.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Section 5.1.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] See Section 5.
+(b) Did you mention the license of the assets? [No] All of them are publicly available.
+(c) Did you include any new assets either in the supplemental material or as a URL? [No] We use publicly available datasets.
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [No] All of them are publicly available.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [No] We use publicly available datasets.
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/images.zip b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..e2c7929b134ac03927be535e6b39600d3ef2f16b
--- /dev/null
+++ b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1598c1554184102ef5d4e168fb29716ef5be482914cce115d6064023f44c3a61
+size 458499
diff --git a/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/layout.json b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..8840d101eb7cb0e13ba62f6e85af87400282c6d2
--- /dev/null
+++ b/dropcovasimpleyeteffectivemethodforimprovingdeeparchitectures/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:973a341258530099dd7229314b21dfad3d2d50e3f95e784ab1d724526bcf941b
+size 525961
diff --git a/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/93b11b1a-5d67-437e-801d-520aeff5c6bc_content_list.json b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/93b11b1a-5d67-437e-801d-520aeff5c6bc_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..ecee4a569b8202aea84ef991bf48198a10697c8d
--- /dev/null
+++ b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/93b11b1a-5d67-437e-801d-520aeff5c6bc_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d06edabff97105de4f9d1d15589aff83c732e80abae2aa8efcc92ee687467620
+size 89731
diff --git a/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/93b11b1a-5d67-437e-801d-520aeff5c6bc_model.json b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/93b11b1a-5d67-437e-801d-520aeff5c6bc_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..03827f0d0f45ba793aa5232a8431320c0428bfde
--- /dev/null
+++ b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/93b11b1a-5d67-437e-801d-520aeff5c6bc_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d4a8cf4733eb0011c7e67884f1c8376b994e8806a6a4706c2786ea12e4740be3
+size 116371
diff --git a/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/93b11b1a-5d67-437e-801d-520aeff5c6bc_origin.pdf b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/93b11b1a-5d67-437e-801d-520aeff5c6bc_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..dfb751a73cf5568ece218d9e1cac87b293e399d2
--- /dev/null
+++ b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/93b11b1a-5d67-437e-801d-520aeff5c6bc_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1ea27f21cef6fcdc4bb3bc1131335ed90ebfc4e776ae71b312ca1b3d4da07594
+size 635564
diff --git a/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/full.md b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..b523f4ab61af851d25aeb7de8d53dad3e8f4f973
--- /dev/null
+++ b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/full.md
@@ -0,0 +1,327 @@
+# DualCoOp: Fast Adaptation to Multi-Label Recognition with Limited Annotations
+
+Ximeng Sun $^{1}$ Ping Hu $^{1}$ Kate Saenko $^{1,2}$
+
+$^{1}$ Boston University, $^{2}$ MIT-IBM Watson AI Lab, IBM Research
+
+{sunxm,pinghu,saenko}@bu.edu
+
+# Abstract
+
+Solving multi-label recognition (MLR) for images in the low-label regime is a challenging task that has many real-world applications. Recent work learns an alignment between textual and visual spaces to compensate for insufficient image labels, but loses accuracy because of the limited amount of available MLR annotations. In this work, we utilize the strong alignment of textual and visual features pretrained with millions of auxiliary image-text pairs and propose Dual Context Optimization (DualCoOp) as a unified framework for partial-label MLR and zero-shot MLR. DualCoOp encodes positive and negative contexts with class names as part of the linguistic input (i.e. prompts). Since DualCoOp only introduces a very light learnable overhead upon the pretrained vision-language framework, it can quickly adapt to multi-label recognition tasks that have limited annotations and even unseen classes. Experiments on standard multi-label recognition benchmarks across two challenging low-label settings demonstrate the advantages of our approach over state-of-the-art methods. Project page: https://cs-people.bu.edu/sunxm/DualCoOp/project.htm1
+
+# 1 Introduction
+
+Image recognition has become a very popular and successful research area in recent years, due to the development of large-scale datasets [12, 28] and advanced model architectures [14, 19, 38, 54]. However, the majority of image recognition approaches have focused on single-label prediction, which ignores the intrinsic multi-label nature of images. Unlike single-label recognition [14, 19, 38, 54], multi-label image recognition aims to recognize all semantic labels present in an image [10, 11, 35, 37, 52, 66, 61], providing a more comprehensive understanding and benefiting applications like image retrieval, video analysis, and recommendation systems.
+
+Multi-label recognition typically deals with images of complex scenes and diverse objects. Collecting multi-label annotations becomes difficult to scale up, for two reasons: (i) annotating images with the full semantic label set is laborious and (ii) samples of particular categories can be hard to find. The first challenge can be addressed by multi-label recognition with partial labels, where merely some of the categories are annotated for each training image. Recent works proposed solutions to partial-label MLR based on semi-supervised learning [24, 41], normalized training objectives [15], or label correlations [8, 21, 46]. The second setting involves zero-shot MLR, where novel unseen categories are recognized by transferring knowledge from seen categories, with solutions like principal image features [3, 69], knowledge graphs [29], and attention mechanisms [22, 44]. Despite significant progress on the two settings, existing approaches are not designed to handle both at once. We propose to unify these settings as limited-annotation MLR and design a solution that can handle practical scenarios with either partial or missing labels.
+
+Successful solutions to the above problems transfer knowledge from fully-annotated categories to partially-labeled and novel categories by learning an alignment between images and category
+
+
+Figure 1: A conceptual comparison of previous multi-label recognition (MLR) methods and our approach. In Partial-Label MLR (a) and Zero-Shot MLR (b), previous works learn to model and align the visual and textual inputs as well as explore the correlation between the target label with all/seen labels depending on the limited semantic annotations available on the dataset, which leads to sub-optimal performance and complex model architectures. In contrast, we propose a unified framework to tackle both limited-annotation tasks (c). We rely on the modeling and alignment of visual and textual inputs contained a large-scale pretrained vision-language model, and only learn a pair of positive and negative prompts to this model.
+
+names [8, 46, 69]. Recently, vision-language pretraining models are bridging the visual-textual gap via large-scale pretraining, e.g., CLIP [47] is trained with 400 million image-text pairs. In this work, we draw inspiration from the recent success of prompt learning for such models [20, 25, 40, 48, 70, 72]. Prompt learning provides a convenient way to transfer pretrained vision-language models to other tasks. It designs additional textured or learnable prompt tokens for textual input to "inform" the model about downstream tasks and avoids finetuning the entire model which can be inefficient and data-hungry. By doing so, recent works like CoOp [71] have demonstrated CLIP's remarkable generalisation to various zero-shot image tasks [20, 47, 72]. However, these methods mainly focus on matching each image with a single label, hence they are not able to handle the multi-label setting.
+
+To adapt the knowledge learned in CLIP to multi-label image recognition, we propose the DualCoOp framework. As shown in Fig. 1 (c), DualCoOp learns a pair of differentiable prompts to provide positive and negative contexts for the target class. Instead of using hand-crafted thresholding to determine positive labels [51], the dual prompts naturally result in a positive and a negative classifier, so the existence of the target class in the image can be easily decided by comparing their scores. Unlike prior models, shown in Fig. 1 (a)(b), we avoid fine-tuning the full vision-language model and only learn the prompts, which are much smaller compared to the entire model. Therefore, our simple framework achieves much higher efficiency when adapting to different datasets. Additionally, we modify the attention mechanism of CLIP to better model spatial information in images, improving its ability to recognize multiple objects in MLR. With these design choices, we achieve a unified framework for addressing the general challenges of multi-label recognition with limited annotations.
+
+We summarize our contributions as follows:
+
+- We propose DualCoOp to quickly adapt powerful vision-language models to solve multi-label recognition tasks using limited annotations.
+- We propose dual (positive and negative) prompts to drastically reduce the number of learnable parameters, and improve the spatial modeling of the visual encoder to better distinguish multiple objects.
+- We conduct extensive experiments on partial-label MLR (on MS-COCO [34] and VOC2007 [16]) and zero-shot MLR (on MS-COCO and NUS-WIDE [11]). Notably, DualCoOp improves mAP by $6.8\%$ with $10\%$ of labels on VOC2007, and F1-score at Top-3 Prediction by $10.8\%$ for zero-shot MLR on NUS-WIDE.
+
+# 2 Related Works
+
+Multi-Label Recognition with Limited Annotations. Multi-label image recognition has drawn increasing attention in past years. One straightforward solution to this problem is to individually learn a binary classifier for each category [36, 43, 57], which however does not consider correlations
+
+among labels. Hence, recent works have focused on incorporating semantic dependencies among labels via graph neural networks [10, 11, 61] or RNN/LSTM [35, 59, 62, 66]. Some work also considers the spatial distribution of labels in the image, and exploits object proposals [33, 37, 60] or attention mechanism [52, 62, 73] as a regularization to rectify the prediction. However, despite achieving significant progress, these methods require a large-scale and complete annotated dataset to train models [27, 34]. This limits their application to more practical scenarios where data is partially annotated for training [4, 6, 41, 55, 56, 64] and unseen (zero-shot) categories may appear during testing [7, 18, 29, 42, 69].
+
+With partially labeled data, where merely some labels of each sample are known, Mahajan et al. [41] and Joulin et al. [24] attempt to use web supervision to automatically generate the pseudo labels, which unfortunately leads to poor performance as the web supervision is noisy and incomplete [67]. To avoid external noise, Durand et al. [15] exploit the proportion of annotated samples for different labels and propose a normalized BCE loss to train models based on the given partial labels. More recent works explicitly transfer information from known labels to complement unknown labels by utilizing category-specific feature blending [46] or label co-occurrences [8] at both instance-level and prototype-level.
+
+Unlike partial annotation of the same label set for training and testing, zero-shot multi-label image recognition needs to handle novel categories during testing, hence inspiring a different route based on a joint visual-label embedding space [7, 22, 42, 44, 69]. Zhang et al. [69] propose to find a principal direction that ranks related labels first in the joint embedding space optimized via a tailored zero-shot ranking loss. Cohen et al. [3] further improve the idea by learning multiple principal vectors to support the semantic diversity. Huynh et al. [22] consider the spatial regularization and propose a shared multi-attention model and obviate the need for explicit region proposals [50]. Narayan et al. [44] propose to enhance the region-based features so as to minimize inter-class feature entanglement.
+
+Though significant progress has been made in each of the directions, existing methods still require a lot of MLR data and complex architectures/losses. Our approach reduces the need for hard-to-get MLR data by pretraining on unsupervised text-image pairs. While it may seem unfair to compare existing MLR methods with ones based on such pretraining, we point out that the pretraining data is unsupervised and thus easier to obtain. We also provide experiments comparing Dua1Co0p to baselines using the same pretraining. Importantly, previous methods are designed for only one task, hence have limitations in practical applications. In contrast, our proposed framework can be easily adapted with small data and can address both partial and zero-shot tasks at the same time.
+
+Prompt Learning for Vision-Language Models. Vision-Language Models [23, 47] based on contrastive learning have demonstrated impressive ability to learn generic visual representations. As a milestone, CLIP [47] is trained with 400 million curated image-text pairs, and shows remarkable transfer capability for over 30 classification datasets. With such powerful vision-language models, several follow-ups [17, 63, 65, 68] have been proposed to explore the training strategies for training downstream classification tasks. Instead of fine-tuning the entire model [13, 19], which may damage the learned representation space, recent approaches adopt the prompt-based paradigm that formalizes NLP tasks as masked language modeling (prompt templates) [30, 32, 53]. Zhou et al. [71] propose to tune prompts for downstream classification tasks, and further introduce input-conditional prompts for better generalization ability [72]. Lu et al. [39] learn the distribution of diverse prompts to handle the varying visual representations. Huang et al. [20] generate pseudo labels for images to learn prompts in an unsupervised way. Though achieving promising improvements for downstream tasks, these methods address the multi-class zero-shot image recognition, assuming each image has one label, hence lacking the ability to handle the multi-label setting. In this paper, we present a novel framework to efficiently transfer VLMs to address multi-label image recognition with limited annotations.
+
+# 3 Method
+
+Problem Definition. We formally define multi-label recognition with limited annotations as follows: Consider $M$ as the set of categories which describe objects or attributes in images. Given a training image $I$ , the existence of a category $m \in M$ can be positive, negative or unknown, corresponding to the label $y_{m} = 1, -1$ or 0 respectively. During inference, we predict each label of interest for an input image.
+
+
+Figure 2: Illustration of our proposed approach. DualCoOp learns a pair of positive and negative prompts to quickly adapt powerful pretrained vision-text encoders to the MLR task. For each class, two prompts generate two contrastive (positive and negative) textual embeddings as the input to the text encoder. Furthermore, we propose Class-Specific Region Feature Aggregation to first project each region's feature to the textual space and then aggregate the spatial logits by the magnitude of class-specific semantic responses. During training, we apply the ASL loss [51] to optimize learnable prompts while keeping other network components frozen. During inference, we compare the positive and negative logits to make a prediction for each class.
+
+Many existing MLR problems fit into this broad definition. In this paper, we consider the settings with partial or missing labels: (1) Partial-label MLR [8, 15, 46], in which only a subset of labels are known (+1 or -1) for each training image and we are interested in predicting all existing labels during inference. (2) Zero-shot MLR [3, 22, 49], in which each label is either known (seen) or unknown (unseen) for all images during training and we are interested in predicting either all labels or only unknown (unseen) labels during inference. In this paper, we propose a unified setting that includes both scenarios, which we call limited-annotation MLR.
+
+Approach Overview. To compensate for insufficient or missing image labels, it is important to learn how the meanings of category names are related to each other, so that we can transfer knowledge between related categories. This is usually done by learning an alignment between the visual and textual spaces. However, our dataset is too limited to learn a broad and generalizable mapping. We propose to instead leverage the strong alignment of visual and textual feature spaces learned by large-scale vision-language pretraining (CLIP [48]) with a light-weight learnable overhead which quickly adapts to the MLR task with limited semantic annotations. Figure 2 provides an overview of our proposed approach. Dua1Co0p learns a pair of "prompt" contexts in the form of two learnable sequences of word vectors, to provide positive and negative contexts of a given category name $m$ . This generates positive and negative textual features $(F_{t}^{m})_{+}$ and $(F_{t}^{m})_{-}$ that are fed into the pretrained text encoder. Furthermore, to better recognize multiple objects, which can be located at different locations in the image, the spatial aggregation step is modified. We first compute the similarity score of each projected visual feature $F_{v}^{i}$ at location $i$ with $(F_{t}^{m})_{+} / (F_{t}^{m})_{-}$ to obtain prediction logits over regions. For each class, we perform aggregation of all spatial logits, in which the weight for each logit is determined by its relative magnitude. We call this Class-Specific Region Feature Aggregation. During training, we optimize the learnable prompts via the ASL loss [51] while keeping all other network components frozen. During inference, we directly compare the final positive and negative logits to make a prediction for each label $y_{m}$ .
+
+Dual Learnable Prompts. Instead of learning a single prompt for a class [71], we propose Dual Context Optimization (DualCo0p) which learns two contrastive prompts' contexts for each class. The learnable part in dual prompts carries positive and negative contextual surroundings individually and can be optimized end-to-end from data via binary classification loss. Specifically, we define the pair of prompts given to the text encoder as follows:
+
+$$
+\operatorname {P r o m p t} ^ {+} = \left[ V _ {1} ^ {+}, V _ {2} ^ {+}, \dots , V _ {N ^ {+}} ^ {+}, \mathrm {C L S} \right], \tag {1}
+$$
+
+$$
+\text {P r o m p t} ^ {-} = \left[ V _ {1} ^ {-}, V _ {2} ^ {-}, \dots , V _ {N ^ {-}} ^ {-}, \mathrm {C L S} \right] \tag {2}
+$$
+
+where each $V$ is a learnable word embedding vector (e.g. with dimension 512 in CLIP [48]) and CLS is the given category name. $N^{+}$ and $N^{-}$ are the numbers of word tokens learned in the positive and
+
+negative prompts respectively. For simplicity, we set $N^{+} = N^{-}$ in our experiments. We learn a pair of positive and negative prompts for each class (i.e. class-specific prompt pair) when solving MLR with partial labels, and learn a pair of prompts shared for all classes in zero-shot MLR. With a pair of prompts, we compute the binary classification output $p$ with the following form:
+
+$$
+p = \frac {\exp \left(< A \left(E _ {v} (I)\right) , E _ {t} \left(\text {P r o m p t} ^ {+}\right) > / \tau\right)}{\exp \left(< A \left(E _ {v} (I)\right) , E _ {t} \left(\text {P r o m p t} ^ {+}\right) > / \tau\right) + \exp \left(< A \left(E _ {v} (I)\right) , E _ {t} \left(\text {P r o m p t} ^ {-}\right) > / \tau\right)}, \tag {3}
+$$
+
+where $< \cdot, \cdot >$ represents cosine similarity and $p$ is the predicted probability for a given (image, label) pair as positive example. $E_v(\cdot)$ and $E_t(\cdot)$ are the visual and textual encoders from the vision-language pretraining. $A(\cdot)$ is our new aggregation function to adaptively reduce the spatial dimension of visual features for each class, which will be discussed next.
+
+Class-Specific Region Feature Aggregation. In multi-label image recognition, it is common that multiple objects appear in different regions of the image. Pooling to produce a single image-level feature vector for all classes gives sub-optimal performance since spatial information is reduced and different objects are mixed. In this work, we reformulate the last multi-headed attention pooling layer of the visual encoder in CLIP [48] and apply class-specific pooling to adaptively aggregate region features in the multi-label setting. The original attention pooling layer in CLIP pools the visual feature map first, and then projects the global feature vector into text space as follows:
+
+$$
+\begin{array}{l} \operatorname {A t t n P o o l} (x) = \operatorname {P r o j} _ {v \rightarrow t} (\sum_ {i} \operatorname {s o f t m a x} (\frac {q (\bar {x}) k (x _ {i}) ^ {T}}{C}) \cdot v (x _ {i})) \\ = \sum_ {i} \operatorname {s o f t m a x} \left(\frac {q (\bar {x}) k (x _ {i}) ^ {T}}{C}\right) \cdot \operatorname {P r o j} _ {v \rightarrow t} (v (x _ {i})) = \operatorname {P o o l} \left(\operatorname {P r o j} _ {v \rightarrow t} (v (x _ {i}))\right), \\ \end{array}
+$$
+
+where $q, v$ and $k$ are independent linear embedding layers and $x = E_v(I)$ is the output feature map of the visual encoder. By removing the pooling operation, we can project the visual feature $x_i$ of each region $i$ to the textual space [70]:
+
+$$
+F _ {v} ^ {i} = \operatorname {P r o j} _ {v \rightarrow t} (v \left(x _ {i}\right)). \tag {4}
+$$
+
+For each region $i$ and each class $m$ , we compute cosine similarity between $F_{v}^{i}$ and $(F_{t}^{m})^{+} = E_{t}(\mathrm{Prompt}^{+})$ as $S_{i,m}^{+} = < F_{v}^{i}, (F_{t}^{m})^{+}>$ , and compute $S_{i,m}^{-}$ in the same way. In order to make a single prediction for the whole image, we aggregate $S_{i,m}^{+}$ and $S_{i,m}^{-}$ into $S_{m}^{+}$ and $S_{m}^{-}$ according to the magnitude of $S_{i,m}^{+}$ , i.e.:
+
+$$
+S _ {m} ^ {+} = A \left(S _ {i, m} ^ {+}\right) = \sum_ {i} \left(\operatorname {s o f t m a x} \left(S _ {i, m} ^ {+}\right) \cdot S _ {i, m} ^ {+}\right), \tag {5}
+$$
+
+$$
+S _ {m} ^ {-} = A \left(S _ {i, m} ^ {-}\right) = \sum_ {i} \left(\operatorname {s o f t m a x} \left(S _ {i, m} ^ {+}\right) \cdot S _ {i, m} ^ {-}\right). \tag {6}
+$$
+
+Notably, we do not introduce any new parameters in our re-formulation of the spatial aggregation function. All parameters used to project visual features to the textual space are inherited from the original multi-headed attention pooling layer in CLIP.
+
+**Optimization.** We apply the Asymmetric Loss (ASL) [51] to handle the inherent positive-negative imbalance in the optimization of multi-label recognition. Specially, we compute losses for a positive (image, label) pair $\mathcal{L}_{+}$ and a negative (image, label) pair $\mathcal{L}_{-}$ as follows:
+
+$$
+\mathcal {L} _ {+} = (1 - p) ^ {\gamma_ {+}} \log (p), \tag {7}
+$$
+
+$$
+\mathcal {L} _ {-} = \left(p _ {c}\right) ^ {\gamma_ {-}} \log \left(1 - p _ {c}\right), \tag {8}
+$$
+
+where $p_c = \max(p - c, 0)$ is the probability for negative examples shifted by hard thresholding via the margin $c$ . We set the hyper-parameters $\gamma_{-} \geq \gamma_{+}$ , so that ASL down-weighs and hard-thresholds easy negative samples. The pair of learnable prompts are updated by back-propagating ASL through the frozen text encoder.
+
+# 4 Experiments
+
+# 4.1 Multi-Label Recognition with Partial Labels
+
+Datasets. We conduct experiments on MS-COCO [34], VOC2007 [16] and BigEarth [5] to evaluate multi-label recognition with partial labels. MS-COCO [34] contains 80 common object categories
+
+Table 1: Multi-label Recognition on MS-COCO and VOC2007 with partial labels. DualCoOp achieves the best performance over all SOTA methods. * indicates previous models using weights pretrained by CLIP [47]
+
+| Methods | #P | 10% | 20% | 30% | 40% | 50% | 60% | 70% | 80% | 90% | Avg. |
| MS-COCO [34] |
| SSGRL [9] | 64.7M | 62.5 | 70.5 | 73.2 | 74.5 | 76.3 | 76.5 | 77.1 | 77.9 | 78.4 | 74.1 |
| GCN-ML [10] | 44.9M | 63.8 | 70.9 | 72.8 | 74.0 | 76.7 | 77.1 | 77.3 | 78.3 | 78.6 | 74.4 |
| KGGR [7] | ≥ 25M | 66.6 | 71.4 | 73.8 | 76.7 | 77.5 | 77.9 | 78.4 | 78.7 | 79.1 | 75.6 |
| Curriculum labeling [15] | ≥ 38M | 26.7 | 31.8 | 51.5 | 65.4 | 70.0 | 71.9 | 74.0 | 77.4 | 78.0 | 60.7 |
| Patial BCE [15] | ≥ 38M | 61.6 | 70.5 | 74.1 | 76.3 | 77.2 | 77.7 | 78.2 | 78.4 | 78.5 | 74.7 |
| SST [8] | 33.5M | 68.1 | 73.5 | 75.9 | 77.3 | 78.1 | 78.9 | 79.2 | 79.6 | 79.9 | 76.7 |
| SST* | 33.5M | 69.1 | 78.5 | 79.3 | 79.9 | 80.1 | 80.5 | 81.1 | 80.7 | 80.7 | 78.9 |
| SARB [46] | 29.6M | 71.2 | 75.0 | 77.1 | 78.3 | 78.9 | 79.6 | 79.8 | 80.5 | 80.5 | 77.9 |
| SARB* | 29.6M | 75.5 | 78.5 | 79.0 | 79.5 | 80.4 | 80.2 | 80.8 | 80.6 | 80.8 | 79.4 |
| DualCoOp (ours) | 1.3M | 78.7 | 80.9 | 81.7 | 82.0 | 82.5 | 82.7 | 82.8 | 83.0 | 83.1 | 81.9 |
| PASCAL VOC 2007 [16] |
| SSGRL [9] | 66.6M | 77.7 | 87.6 | 89.9 | 90.7 | 91.4 | 91.8 | 91.9 | 92.2 | 92.2 | 89.5 |
| GCN-ML [10] | 44.9M | 74.5 | 87.4 | 89.7 | 90.7 | 91.0 | 91.3 | 91.5 | 91.8 | 92.0 | 88.9 |
| KGGR [7] | ≥ 25M | 81.3 | 88.1 | 89.9 | 90.4 | 91.2 | 91.3 | 91.5 | 91.6 | 91.8 | 89.7 |
| Curriculum labeling [15] | ≥ 38M | 44.7 | 76.8 | 88.6 | 90.2 | 90.7 | 91.1 | 91.6 | 91.7 | 91.9 | 84.1 |
| Patial BCE [15] | ≥ 38M | 80.7 | 88.4 | 89.9 | 90.7 | 91.2 | 91.8 | 92.3 | 92.4 | 92.5 | 90.0 |
| SST [8] | 32.4M | 81.5 | 89.0 | 90.3 | 91.0 | 91.6 | 92.0 | 92.5 | 92.6 | 92.7 | 90.4 |
| SARB [46] | 29.6M | 83.5 | 88.6 | 90.7 | 91.4 | 91.9 | 92.2 | 92.6 | 92.8 | 92.9 | 90.7 |
| DualCoOp (ours) | 0.3M | 90.3 | 92.2 | 92.8 | 93.3 | 93.6 | 93.9 | 94.0 | 94.1 | 94.2 | 93.2 |
+
+and we use the official train2014 (82K images) and val2014 (40K images) splits for training and test. VOC2007 [16] contains 20 object categories and we use the official trainval (5K images) and test (5K images) splits for training and test. Furthermore, since CLIP pretraining data is not publicly available and it is plausible that CLIP pretraining data covers many coarse and fine-grained visual domains since it performs well in the zero-shot evaluation for many downstream tasks, we also experiment on a Remote Sensing Image dataset BigEarth [5], whose domain is far from the domains of the datasets in the mainstream papers (i.e. PASCAL VOC, MS-COCO, and NUS-WIDE). To create the training set with partial labels, we randomly mask out labels from the fully annotated training set1 and use the remaining labels for training by following standard practice [8, 15, 46]. In this work, we vary the proportion of kept labels from $10\%$ to $90\%$ [8, 46].
+
+Evaluation. On all datasets, we follow [8, 15, 46] to report the mean average precision (mAP) for each proportion of labels available for optimization (from $10\%$ to $90\%$ ) and its average value for all proportions. We count the learnable parameters (#P) of each baseline and Dua1Co0p to measure the complexity of optimization2. We also report the per-class and the average overall precision (CP and OP), recall (CR and OR), and F1 (CF1 and OF1) of Dua1Co0p under different proportions of labels for training in the supplementary material due to the page limit.
+
+Implementation. We adopt ResNet-101 [19] as the visual encoder in all baselines and DualCoOp for input resolution $448 \times 448$ , and use the same Transformer [48, 58] in CLIP [47] as the text encoder. The visual and text encoders are initialized from the CLIP pretrained model and kept frozen during optimization. For each class/label, we learn two independent context vectors with 16 context tokens $(N = 16)$ following [71], which is the only learnable part in DualCoOp. We use the SGD optimizer with an initial rate of 0.002 which is decayed by the cosine annealing rule. We train context vectors for 50 epochs with a batch-size 32/8/32 for MS-COCO/VOC2007/BigEarth, respectively. For ASL loss, we choose $\gamma_{+} = 1$ , $\gamma_{-} = 2$ and $c = 0.05$ via validation. Training is done with one RTX A6000.
+
+Baselines. To evaluate the effectiveness of DualCoOp, we compare with the following baselines: (1).SSGRL [9], GCN-ML [10] and KGGR [7] adopt graph neural networks to model label dependencies. We follow [8] to report their performance in the partial-label setting. (2). Curriculum labeling [15] and SST [8] generate pseudo labels for unknown labels. (3). Partial BCE [15] uses a normalized BCE loss to better exploit partial labels. (4). SARB [46] blends category-specific representation across different images to transfer information of known labels to complement unknown labels.
+
+Table 2: Comparison between SARB and DualCoOp. Both use parameters pretrained by CLIP [47].
+
+| Method | 10% | 30% | 50% | 70% | 90% | Avg. |
| SARB* | 77.2 | 83.6 | 87.4 | 91.6 | 93.5 | 86.7 |
| DualCoOp | 88.2 | 93.1 | 93.7 | 94.2 | 94.7 | 92.8 |
+
+Table 3: Computations Cost Comparison between SARB [46] and DualCoOp. * indicates previous models using weights pretrained by CLIP [47]
+
+| Methods | Training Latency (ms/img) | Training Memory (GB/img) | Testing Latency (ms/img) | Testing Memory (GB/img) | Avg. mAP (%) |
| SARB* | 4.7 | 0.21 | 4.0 | 0.13 | 79.4 |
| DualCoOp | 5.3 | 0.22 | 4.0 | 0.06 | 81.9 |
+
+Results. Table 1 shows the comparison of mAP between DualCoOp and all baselines optimized with $10\%$ to $90\%$ of labels. For the two most recent works (SST [8] and SARB [46]), we further substitute the ImageNet pretrained weights [19] with the CLIP pretrained weights [47] when initializing of their visual encoders, which results in $\mathrm{SST}^*$ and $\mathrm{SARB}^*$ in Table 1. Since we learn class-specific prompts, DualCoOp on MS-COCO adopts more learnable parameters than VOC2007. Our proposed DualCoOp achieves the best performance across all proportions of labels available during the training with the smallest learnable overhead (1.3M vs. 29.6M in $\mathrm{SARB}^*$ on MS-COCO and 0.3M vs. 29.6M in $\mathrm{SARB}^*$ on VOC2007). Notably, DualCoOp yields a great improvement over the second-best method, $3.2\%$ on MS-COCO and $6.8\%$ on VOC2007, especially when only providing $10\%$ of labels during the training. This indicates that DualCoOp can quickly adapt to the multi-label recognition task with a few labels. On BigEarth, we compare DualCoOp with the strong baseline SARB. Table 2 shows that DualCoOp consistently improves over SARB by $11.0\%$ when only providing $10\%$ of labels and $6.1\%$ for average performance which proves DualCoOp boosts the performance in various visual domains by taking advantage of the powerful vision-language pretraining.
+
+Full Label Training. On MS-COCO, we use $100\%$ of training labels and finetune the visual encoder, DualCoOp achieves $85.2\%$ mAP, outperforming previous SOTA approaches like ASL [51] ( $85.0\%$ mAP) and CSRA [74] ( $83.5\%$ mAP) with the same ResNet-101 backbone. Without finetuning the visual encoder, we notice that our performance drops to $83.2\%$ mAP, which is still comparable to the performance of ASL and CSRA. Such a performance drop may be due to the noise in the image-text pairs used for pre-training the CLIP model and the misalignment of the objectives between the pre-training task and MLR task. This also shows that it is non-trivial to address the MLR task with the pretrained CLIP model, even though it is pre-trained with larger-scale data.
+
+Computational Cost. We compare the computational cost between DualCoOp and SARB [46] in terms of training/testing latency and memory (see Table 3) using the same device (one Nvidia A100 GPU). For the current multi-label recognition task, the categories are pre-set before inference, (i.e. we already know which class we would like to consider during inference.) In this case, we compute the text features for each class from the learned prompts and the class name ahead of the inference. Then we use the pre-computed text features to predict each image during the test. Since the text features are pre-computed (very light-weighted computing overhead), the text encoder is not executed during inference. For inference, the latency time and memory consumption of DualCoOp are the same as other baselines when using the same backbone for the image encoder. During training, CLIP-based methods slightly raise latency time and memory consumption since image and text encoders are both executed during the forward, and only prompts are updated in DualCoOp.
+
+# 4.2 Zero-shot Multi-Label Recognition
+
+Datasets. Following [3, 22], we conduct experiments on MS-COCO [34] and NUS-WIDE [11] to perform zero-shot multi-label recognition. On MS-COCO, we follow [2, 3] to split the dataset into 48 seen classes and 17 unseen classes. NUS-WIDE [11] dataset includes 270K images. Following [3, 22] we use 81 human-annotated categories as unseen classes and an additional set of 925 labels obtained from Flickr tags as seen classes.
+
+Evaluation. We follow [3] and report precision, recall, and F1 score at Top-3 predictions in each image on MS-COCO. We also follow [3, 22] to report mAP over all categories as well as precision, recall, and F1 score at Top-3 and Top-5 predictions in each image on NUS-WIDE. We evaluate all
+
+Table 4: Zero-Shot Multi-Label Recognition on MS-COCO[34]. DualCoOp achieves the best F1 score in both ZSL and GZSL settings.
+
+| Methods | #P | ZSL | GZSL |
| P | R | F1 | P | R | F1 |
| CONSE [45] | - | 11.4 | 28.3 | 16.2 | 23.8 | 28.8 | 26.1 |
| Fast0Tag [69] | 0.61M | 24.7 | 61.4 | 25.3 | 38.5 | 46.5 | 42.1 |
| Deep0Tag [49] | ≥ 23M | 26.5 | 65.9 | 37.8 | 43.2 | 52.2 | 47.3 |
| SDL (M=2) [3] | 30.6M | 26.3 | 65.3 | 37.5 | 59.0 | 60.8 | 59.9 |
| DualCoOp (ours) | 0.02M | 35.3 | 87.6 | 50.3 | 58.4 | 68.1 | 62.9 |
+
+Table 5: Zero-Shot Multi-label Recognition on NUS-WIDE [11]. DualCoOp achieves the best F1 score over all SOTA methods at Top-3/Top-5 predictions in both ZSL and GZSL settings.
+
+| Methods | #P | Top-3 | Top-5 | mAP |
| P | R | F1 | P | R | F1 |
| Zero-Shot Learning (ZSL) |
| CONSE [45] | - | 17.5 | 28.0 | 21.6 | 13.9 | 37.0 | 20.2 | 9.4 |
| LabelEM [1] | - | 15.6 | 25.0 | 19.2 | 13.4 | 35.7 | 19.5 | 7.1 |
| Fast0Tag [69] | 0.61M | 22.6 | 36.2 | 27.8 | 18.2 | 48.4 | 26.4 | 15.1 |
| One Attention per Label [26] | ≥ 12.8M | 20.9 | 33.5 | 25.8 | 16.2 | 43.2 | 23.6 | 10.4 |
| LESAM (M=10) [22] | ≥ 0.45M | 25.7 | 41.1 | 31.6 | 19.7 | 52.5 | 28.7 | 19.4 |
| BiAM [44] | 3.8M | - | - | 33.1 | - | - | 30.7 | 26.3 |
| SDL (M=7) [3] | 33.6M | 24.2 | 41.3 | 30.5 | 18.8 | 53.4 | 27.8 | 25.9 |
| DualCoOp (ours) | 0.02M | 37.3 | 46.2 | 41.3 | 28.7 | 59.3 | 38.7 | 43.6 |
| Generalized Zero-Shot Learning (GZSL) |
| CONSE [45] | - | 11.5 | 5.1 | 7.0 | 9.6 | 7.1 | 8.1 | 2.1 |
| LabelEM [1] | - | 15.5 | 6.8 | 9.5 | 13.4 | 9.8 | 11.3 | 2.2 |
| Fast0Tag [69] | 0.61M | 18.8 | 8.3 | 11.5 | 15.9 | 11.7 | 13.5 | 3.7 |
| One Attention per Label [26] | ≥ 12.8M | 17.9 | 7.9 | 10.9 | 15.6 | 11.5 | 13.2 | 3.7 |
| LESAM (M=10) [22] | ≥ 0.45M | 23.6 | 10.4 | 14.4 | 19.8 | 14.6 | 16.8 | 5.6 |
| BiAM [44] | 3.8M | - | - | 16.1 | - | - | 19.0 | 9.3 |
| SDL (M=7) [3] | 33.6M | 27.7 | 13.9 | 18.5 | 23.0 | 19.3 | 21.0 | 12.1 |
| DualCoOp (ours) | 0.02M | 31.9 | 13.9 | 19.4 | 26.2 | 19.1 | 22.1 | 12.0 |
+
+methods with both zero-shot setting (test only on unseen classes) and generalized zero-shot setting (test on both seen and unseen classes).
+
+Implementation. We adopt ResNet-50 [19] similar to [3] as the visual encoder in DualCoOp for input resolution 224. Instead of learning class-specific prompts, we learn the class-agnostic context vectors with 64 context tokens $(\mathrm{N} = 64)$ for all classes, which is the only learnable part in DualCoOp. We optimize context vectors for 50 epochs with a batch-size 32/192 for MS-COCO/NUS-WIDE, respectively. During inference, we combine the learnt pair of context vectors with the class name for each class (either base class or novel class) and compute the text features. Other implementation details are the same as in Sec. 4.1
+
+Baselines. To evaluate the effectiveness of DualCoOp in the zero-shot setting, we compare with the following baselines: (1). CONSE [45] adopts an ensemble of classifiers for unseen classes. (2). LabelEM [1] learns a joint image-label embedding. (3). Fast0Tag [69] and SDL [3] estimate one or multiple diverse principal directions of the input images. (4). Deep0Tag [49] and LESA [22] estimate the relevant regions via region proposals and attention techniques respectively. (5). BiAM [44] enhances the region-based features to minimize inter-class feature entanglement.
+
+Results. Table 4-5 shows the comparison between DualCoOp and all SOTA methods of zero-shot learning and generalized zero-shot learning on MS-COCO and NUS-WIDE datasets. DualCoOp achieves the best F1 score in all cases with a very light learnable overhead (0.02M) and improves the performance of zero-shot learning (unseen labels) with a significant margin: F1 score improves by 12.5 @Top-3 on MS-COCO, and by 10.8 @Top-3 and 10.9 @Top-5 on NUS-WIDE. This shows the power of exploiting the pretrained alignment of textual and visual spaces in CLIP via DualCoOp to solve multi-label recognition.
+
+# 4.3 Ablation Studies
+
+Effectiveness of Text Supervision. To show the effectiveness of text supervision from label space, we compare the model learned with discrete label space ("Discrete Label") with four methods (SST [8], SARB [46], CoOp [71] and DualCoOp) which introduce the textual space to utilize the contextual correlation of labels in Table 6. We find that methods with text supervision usually perform better
+
+Table 6: Comparison among methods on MS-COCO using partial labels with the same initialization. All methods use parameters pretrained by CLIP [47].
+
+| Method | Text Supervision | 10% | 30% | 50% | 70% | 90% |
| Discrete Label | ✘ | 70.6 | 75.1 | 76.5 | 77.3 | 78.0 |
| SST | ✓ | 69.1 | 79.3 | 80.1 | 81.1 | 80.7 |
| SARB | ✓ | 75.5 | 79.0 | 80.4 | 80.8 | 80.8 |
| CoOp | ✓ | 63.0 | 68.5 | 69.2 | 71.5 | 75.0 |
| DualCoOp | ✓ | 78.4 | 81.0 | 82.0 | 82.5 | 82.8 |
+
+Table 7: Ablation on Linguistic Inputs for Zero-Shot Learning of MS-COCO.
+
+| Linguistic Input | #P | ZSL | GZSL |
| P | R | F1 | P | R | F1 |
| M0 | Contextless Classname | 0 | 5.2 | 12.9 | 7.4 | 3.5 | 4.1 | 3.8 |
| M1 | Hand-crafted Pos./Neg. Templates + ClassName | 0 | 25.6 | 63.6 | 36.5 | 31.0 | 36.2 | 33.4 |
| M2 | Pos. Learnable Prompt + ClassName (N=64) | 0.01M | 31.2 | 77.5 | 44.5 | 55.7 | 65.0 | 60.0 |
| M3 | Neg. Learnable Prompt + ClassName (N=64) | 0.01M | 9.3 | 23.0 | 13.2 | 2.6 | 3.0 | 2.8 |
| M4 | Dual Learnable Prompts + ClassName (N=64) | 0.02M | 35.3 | 87.6 | 50.3 | 58.4 | 68.1 | 62.9 |
| M5 | Dual Learnable Prompts + ClassName (N=32) | 0.01M | 35.8 | 88.9 | 51.0 | 57.4 | 67.0 | 61.9 |
+
+than the method only using discrete labels. However, when the semantic annotations are limited, text supervision sometimes yields worse performance (e.g. mAP of SST is $1.5\%$ lower than Discrete Labels with only $10\%$ of labels). CoOp [71] utilizes the visual-textual alignment. However, with the original multi-head attention and single positive prompt, it yields worse performance than Discrete Labels. To better utilize the well-pretrained alignment, DualCoOp learns dual context pairs and adopts class-specific region feature aggregation, which leads to great performance (e.g. $7.8\%$ higher than Discrete Labels with $10\%$ of labels) and quickly adapts to the dataset even with limited labels.
+
+Ablation of Prompt Design. We compare our proposed dual learnable prompts with two hand-crafted prompts and one prompt learning method on the MS-COCO dataset with the zero-shot setting (see Table 7). Hand-crafted prompts can use either contextless class names [31] or manually designed prompt templates. In our experiments, we carefully choose the positive and negative prompt templates as "a photo of a [classname]" and "a photo without a [classname]". In contrast with performing the binary classification for each class with dual learnable prompts as the input, we also experiment with learning a single prompt of positive or negative contexts and use a chosen threshold (0.5 in our experiment) to make the prediction for each class. As we can see, the single positive prompt learning method (M2) performs better than non-learnable methods (M0 and M1), and a single negative learnable prompt (M3) achieves much worse accuracy than its positive counterpart (M2). However, when we include both positive and negative prompts, dual prompts (M4) performs even better than a single prompt, which indicates that DualCoOp learns complementary and beneficial information in the dual prompt pair. M4 also outperforms M2 in terms of mAP with both ZSL (77.53% vs. 64.74%) and GZSL (69.8% vs. 63.1%). To keep the same amount of learnable parameters as in single prompt settings, we also halve the token size (M5), and find that DualCoOp still outperforms two single prompts in M2 and M3 by large gaps, demonstrating the effectiveness of our dual-prompt design.
+
+Multi-Headed Attention vs. Class-Specific Region Aggregation. In Table 8, we compare the adaptive ability of these two visual aggregation methods when training/testing with a larger resolution (see Table 8), which is crucial in multi-label recognition as spatial details matter. For a fair comparison, we only replace the class-specific region aggregation in DualCoOp with the original multi-headed attention layer in CLIP [48] at the end of the visual encoder. We adaptively resize the input feature map to match the input dimension of the multi-headed attention layer.
+
+Table 8: Comparison between multi-headed attention and class-specific feature aggregation on MS-COCO
+
+| Visual Aggregation | Finetune. | Train Res. | Test Res. | 10% | 30% | 50% | 70% | 90% |
| Multi-Headed Attention | X | 224 | 224 | 70.4 | 74.1 | 74.8 | 75.4 | 75.7 |
| X | 224 | 448 | 65.9 | 70.2 | 71.2 | 72.0 | 72.1 |
| X | 448 | 448 | 72.1 | 75.5 | 76.5 | 77.1 | 77.3 |
| ✓ | 448 | 448 | 74.1 | 77.6 | 78.2 | 78.5 | 78.4 |
| Class-Specific Feature Aggregation (DualCoOp) | X | 224 | 224 | 73.1 | 76.4 | 77.7 | 78.2 | 78.4 |
| X | 224 | 448 | 76.0 | 78.1 | 79.5 | 80.3 | 80.5 |
| X | 448 | 448 | 78.4 | 81.1 | 82.0 | 82.5 | 82.8 |
| ✓(Aggre. Func.) | 448 | 448 | 79.4 | 82.2 | 83.1 | 83.7 | 84.0 |
| ✓(Image Enc.) | 448 | 448 | 57.8 | 69.0 | 73.7 | 80.9 | 84.2 |
+
+As shown in Table 8, multi-headed attention is bonded to the pre-training image resolution (224 in CLIP), while our class-specific region aggregation benefits from the increased input resolution either during training or in inference. Our class-specific feature aggregation uses original weights, but actually performs better than finetuning the original multi-headed attention layer.
+
+Ablation of Finetuning DualCoOp. To better examine the effectiveness of finetuning for DualCoOp, we have implemented two different finetuning mechanisms for DualCoOp: (1). only finetune the weights in Class-Specific Region Feature Aggregation, (2). finetune all weights in the CLIP image-encoder. As shown in Table 8, finetuning aggregation function can stably improve the performance over the non-finetuning setting with different amounts of labels available. However, finetuning the entire visual encoder does not always outperform the non-finetuning baseline, especially under limited annotations ( $\leq 70\%$ labels).
+
+
+Figure 3: Comparison among different aggregations on MS-COCO using partial labels.
+
+Ablation of Aggregation Function. We experiment with
+
+different functions to aggregate the regional logits for each class in Fig. 3. We compute final logits in three ways: (1) taking the average of logits at all spatial locations ("Ave"), (2) taking the region with the largest positive logit ("Max"), and (3) generating aggregating weights for all spatial locations via a softmax function over the positive logits ("Ours"). "Max" performs better than "Ave", which indicates the regional feature is more informative than the global feature in multi-label recognition. Furthermore, by taking account of both the regional and the global features, "Ours" gives the best performance.
+
+# 5 Conclusion
+
+In this paper, we propose a unified framework, DualCo0p, for two types of multi-label recognition with limited annotations: partial-label and zero-shot. DualCo0p utilizes powerful vision-language pretraining obtained from a web-scale dataset. By introducing a lightweight learnable overhead, it can quickly adapt to solve multi-label recognition after receiving a small amount of labels. In DualCo0p, we learn a pair of positive and negative prompts followed by the target class name as the linguistic input. Furthermore, to better aggregate visual region features for each class, we reformulate the original visual attention in the pretraining model as a class-specific region feature aggregation. We conduct extensive experiments for both partial-label MLR and Zero-Shot MLR across MS-COCO, VOC2007, and NUS-WIDE datasets, showing the efficacy of our proposed approach over state-of-the-art methods.
+
+Limitations. Since the vision-language pretraining adopts a large Transformer-based language model and all labels need to be feed-forward through the text encoder, the large language model limits the size of the label set. Also, compared to training the model with both seen and unseen labels, we still get worse performance for the zero-shot unseen classes even though we have used 400M auxiliary samples in the pretraining. This highlights the difficulty of zero-shot MLR.
+
+Negative Societal Impacts. Negative impacts of our research are difficult to predict, however, they are likely to be the usual pitfalls associated with deep learning models. These include susceptibility to adversarial attacks and data poisoning, dataset bias, and lack of interpretability. Other risks associated with the deployment of computer vision systems include privacy violations when images are captured without consent, or used to track individuals for profit, or increased automation resulting in job losses. While we believe that these issues should be mitigated, they are beyond the scope of this paper. Furthermore, we should be cautious of potential failures of the approach which could impact the performance/user experience of any high-level AI systems based on our research.
+
+# Acknowledgement
+
+This work is supported by NSF and DARPA LwLL. It reflects the opinions and conclusions of its authors, but not necessarily the funding agents.
+
+# References
+
+[1] Zeynep Akata, Florent Perronnin, Zaid Harchaoui, and Cordelia Schmid. Label-embedding for image classification. IEEE Trans. on PAMI, 38(7):1425–1438, 2015.
+[2] Ankan Bansal, Karan Sikka, Gaurav Sharma, Rama Chellappa, and Ajay Divakaran. Zero-shot object detection. In ECCV, 2018.
+[3] Avi Ben-Cohen, Nadav Zamir, Emanuel Ben-Baruch, Itamar Friedman, and Lihi Zelnik-Manor. Semantic diversity learning for zero-shot multi-label classification. In ICCV, 2021.
+[4] Serhat Selcuk Bucak, Rong Jin, and Anil K Jain. Multi-label learning with incomplete class assignments. In CVPR, 2011.
+[5] Bindita Chaudhuri, Begum Demir, Subbasis Chaudhuri, and Lorenzo Bruzzone. Multilabel remote sensing image retrieval using a semisupervised graph-theoretic method. IEEE Transactions on Geoscience and Remote Sensing, 56(2):1144-1158, 2018.
+[6] Minmin Chen, Alice Zheng, and Kilian Weinberger. Fast image tagging. In ICML, 2013.
+[7] Tianshui Chen, Liang Lin, Xiaolu Hui, Riquan Chen, and Hefeng Wu. Knowledge-guided multi-label few-shot learning for general image recognition. IEEE Trans. on PAMI, 2020.
+[8] Tianshui Chen, Tao Pu, Hefeng Wu, Yuan Xie, and Liang Lin. Structured semantic transfer for multi-label recognition with partial labels. 2022.
+[9] Tianshui Chen, Muxin Xu, Xiaolu Hui, Hefeng Wu, and Liang Lin. Learning semantic-specific graph representation for multi-label image recognition. In ICCV, 2019.
+[10] Zhao-Min Chen, Xiu-Shen Wei, Peng Wang, and Yanwen Guo. Multi-label image recognition with graph convolutional networks. In CVPR, 2019.
+[11] Tat-Seng Chua, Jinhui Tang, Richang Hong, Haojie Li, Zhiping Luo, and Yantao Zheng. Nus-wide: a real-world web image database from national university ofsingapore. In ICIVR, 2009.
+[12] Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. Imagenet: A large-scale hierarchical image database. In CVPR. IEEE, 2009.
+[13] Li Dong, Nan Yang, Wenhui Wang, Furu Wei, Xiaodong Liu, Yu Wang, Jianfeng Gao, Ming Zhou, and Hsiao-Wuen Hon. Unified language model pre-training for natural language understanding and generation. NeurIPS, 2019.
+[14] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, et al. An image is worth 16x16 words: Transformers for image recognition at scale. arXiv preprint arXiv:2010.11929, 2020.
+[15] Thibaut Durand, Nazanin Mehrasa, and Greg Mori. Learning a deep convnet for multi-label classification with partial labels. In CVPR, 2019.
+[16] Mark Everingham, Luc Van Gool, Christopher KI Williams, John Winn, and Andrew Zisserman. The pascal visual object classes (voc) challenge. IJCV, 88(2):303-338, 2010.
+[17] Peng Gao, Shijie Geng, Renrui Zhang, Teli Ma, Rongyao Fang, Yongfeng Zhang, Hongsheng Li, and Yu Qiao. Clip-adapter: Better vision-language models with feature adapters. arXiv preprint arXiv:2110.04544, 2021.
+[18] Akshita Gupta, Sanath Narayan, Salman Khan, Fahad Shahbaz Khan, Ling Shao, and Joost van de Weijer. Generative multi-label zero-shot learning. arXiv preprint arXiv:2101.11606, 2021.
+[19] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In CVPR, 2016.
+[20] Tony Huang, Jack Chu, and Fangyun Wei. Unsupervised prompt learning for vision-language models. arXiv preprint arXiv:2204.03649, 2022.
+[21] Dat Huynh and Ehsan Elhamifar. Interactive multi-label cnn learning with partial labels. In CVPR, 2020.
+[22] Dat Huynh and Ehsan Elhamifar. A shared multi-attention framework for multi-label zero-shot learning. In CVPR, 2020.
+
+[23] Chao Jia, Yinfei Yang, Ye Xia, Yi-Ting Chen, Zarana Parekh, Hieu Pham, Quoc Le, Yun-Hsuan Sung, Zhen Li, and Tom Duerig. Scaling up visual and vision-language representation learning with noisy text supervision. In ICML, 2021.
+[24] Armand Joulin, Laurens van der Maaten, Allan Jabri, and Nicolas Vasilache. Learning visual features from large weakly supervised data. In ECCV, 2016.
+[25] Chen Ju, Tengda Han, Kunhao Zheng, Ya Zhang, and Weidi Xie. Prompting visual-language models for efficient video understanding. arXiv preprint arXiv:2112.04478, 2021.
+[26] Jin-Hwa Kim, Jaehyun Jun, and Byoung-Tak Zhang. Bilinear Attention Networks. In NIPS, 2018.
+[27] Ranjay Krishna, Yuke Zhu, Oliver Groth, Justin Johnson, Kenji Hata, Joshua Kravitz, Stephanie Chen, Yannis Kalantidis, Li-Jia Li, David A Shamma, et al. Visual genome: Connecting language and vision using crowdsourced dense image annotations. IJCV, 123(1):32-73, 2017.
+[28] Alina Kuznetsova, Hassan Rom, Neil Alldrin, Jasper Uijlings, Ivan Krasin, Jordi Pont-Tuset, Shahab Kamali, Stefan Popov, Matteo Malloci, Alexander Kolesnikov, et al. The open images dataset v4. IJCV, 128(7):1956-1981, 2020.
+[29] Chung-Wei Lee, Wei Fang, Chih-Kuan Yeh, and Yu-Chiang Frank Wang. Multi-label zero-shot learning with structured knowledge graphs. In CVPR, 2018.
+[30] Brian Lester, Rami Al-Rfou, and Noah Constant. The power of scale for parameter-efficient prompt tuning. arXiv preprint arXiv:2104.08691, 2021.
+[31] Ang Li, Allan Jabri, Armand Joulin, and Laurens Van Der Maaten. Learning visual n-grams from web data. In ICCV, 2017.
+[32] Xiang Lisa Li and Percy Liang. Prefix-tuning: Optimizing continuous prompts for generation. arXiv preprint arXiv:2101.00190, 2021.
+[33] Yining Li, Chen Huang, Chen Change Loy, and Xiaou Tang. Human attribute recognition by deep hierarchical contexts. In ECCV, 2016.
+[34] Tsung-Yi Lin, Michael Maire, Serge Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dólar, and C Lawrence Zitnick. Microsoft coco: Common objects in context. In ECCV, 2014.
+[35] Feng Liu, Tao Xiang, Timothy M Hospedales, Wankou Yang, and Changyin Sun. Semantic regularisation for recurrent image annotation. In CVPR, 2017.
+[36] Weiwei Liu and Ivor Tsang. On the optimality of classifier chain for multi-label classification. NIPS, 28, 2015.
+[37] Yongcheng Liu, Lu Sheng, Jing Shao, Junjie Yan, Shiming Xiang, and Chunhong Pan. Multi-label image classification via knowledge distillation from weakly-supervised detection. In ACM MM, 2018.
+[38] Ze Liu, Yutong Lin, Yue Cao, Han Hu, Yixuan Wei, Zheng Zhang, Stephen Lin, and Baining Guo. Swin transformer: Hierarchical vision transformer using shifted windows. In ICCV, 2021.
+[39] Yuning Lu, Jianzhuang Liu, Yonggang Zhang, Yajing Liu, and Xinmei Tian. Prompt distribution learning. arXiv preprint arXiv:2205.03340, 2022.
+[40] Timo Lüddecke and Alexander S. Ecker. Prompt-based multi-modal image segmentation. arXiv preprint arXiv:2112.10003, 2021.
+[41] Dhruv Mahajan, Ross Girshick, Vignesh Ramanathan, Kaiming He, Manohar Paluri, Yixuan Li, Ashwin Bharambe, and Laurens Van Der Maaten. Exploring the limits of weakly supervised pretraining. In ECCV, 2018.
+[42] Thomas Mensink, Efstratios Gavves, and Cees GM Snoek. Costa: Co-occurrence statistics for zero-shot classification. In CVPR, 2014.
+[43] Ishan Misra, C Lawrence Zitnick, Margaret Mitchell, and Ross Girshick. Seeing through the human reporting bias: Visual classifiers from noisy human-centric labels. In CVPR, 2016.
+[44] Sanath Narayan, Akshita Gupta, Salman Khan, Fahad Shahbaz Khan, Ling Shao, and Mubarak Shah. Discriminative region-based multi-label zero-shot learning. In ICCV, 2021.
+
+[45] Mohammad Norouzi, Tomas Mikolov, Samy Bengio, Yoram Singer, Jonathon Shlens, Andrea Frome, Greg S Corrado, and Jeffrey Dean. Zero-shot learning by convex combination of semantic embeddings. arXiv preprint arXiv:1312.5650, 2013.
+[46] Tao Pu, Tianshui Chen, Hefeng Wu, and Liang Lin. Semantic-aware representation blending for multi-label image recognition with partial labels. In AAAI, 2022.
+[47] Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, et al. Learning transferable visual models from natural language supervision. In ICML, 2021.
+[48] Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, Ilya Sutskever, et al. Language models are unsupervised multitask learners. OpenAI blog, 2019.
+[49] Shafin Rahman and Salman Khan. Deep multiple instance learning for zero-shot image tagging. In ACCV, 2018.
+[50] Shafin Rahman, Salman Khan, and Nick Barnes. Deep0tag: Deep multiple instance learning for zero-shot image tagging. IEEE Trans. on MM, 22(1):242-255, 2019.
+[51] Tal Ridnik, Emanuel Ben-Baruch, Nadav Zamir, Asaf Noy, Itamar Friedman, Matan Protter, and Lihi Zelnik-Manor. Asymmetric loss for multi-label classification. In ICCV, 2021.
+[52] Nikolaos Sarafianos, Xiang Xu, and Ioannis A Kakadiaris. Deep imbalanced attribute classification using visual attention aggregation. In ECCV, 2018.
+[53] Taylor Shin, Yasaman Razeghi, Robert L Logan IV, Eric Wallace, and Sameer Singh. Autoprompt: Eliciting knowledge from language models with automatically generated prompts. arXiv preprint arXiv:2010.15980, 2020.
+[54] Karen Simonyan and Andrew Zisserman. Very deep convolutional networks for large-scale image recognition. arXiv preprint arXiv:1409.1556, 2014.
+[55] Chen Sun, Abhinav Shrivastava, Saurabh Singh, and Abhinav Gupta. Revisiting unreasonable effectiveness of data in deep learning era. In ICCV, 2017.
+[56] Yu-Yin Sun, Yin Zhang, and Zhi-Hua Zhou. Multi-label learning with weak label. In AAAI, 2010.
+[57] Grigorios Tsoumakas and Ioannis Katakis. Multi-label classification: An overview. International Journal of Data Warehousing and Mining, 3(3):1-13, 2007.
+[58] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. NIPS, 2017.
+[59] Jiang Wang, Yi Yang, Junhua Mao, Zhiheng Huang, Chang Huang, and Wei Xu. Cnn-rnn: A unified framework for multi-label image classification. In CVPR, 2016.
+[60] Meng Wang, Changzhi Luo, Richang Hong, Jinhui Tang, and Jiashi Feng. Beyond object proposals: Random crop pooling for multi-label image recognition. IEEE Trans on IP, 25(12):5678-5688, 2016.
+[61] Ya Wang, Dongliang He, Fu Li, Xiang Long, Zhichao Zhou, Jinwen Ma, and Shilei Wen. Multi-label classification with label graph superimposing. In AAAI, 2020.
+[62] Zhouxia Wang, Tianshui Chen, Guanbin Li, Ruijia Xu, and Liang Lin. Multi-label image recognition by recurrently discovering attentional regions. In ICCV, 2017.
+[63] Mitchell Wortsman, Gabriel Ilharco, Mike Li, Jong Wook Kim, Hannaneh Hajishirzi, Ali Farhadi, Hongseok Namkoong, and Ludwig Schmidt. Robust fine-tuning of zero-shot models. arXiv preprint arXiv:2109.01903, 2021.
+[64] Ming-Kun Xie and Sheng-Jun Huang. Partial multi-label learning. In AAAI, 2018.
+[65] Yuan Yao, Ao Zhang, Zhengyan Zhang, Zhiyuan Liu, Tat-Seng Chua, and Maosong Sun. Cpt: Colorful prompt tuning for pre-trained vision-language models. arXiv preprint arXiv:2109.11797, 2021.
+[66] Vacit Oguz Yazici, Abel Gonzalez-Garcia, Arnau Ramisa, Bartlomiej Twardowski, and Joost van de Weijer. Orderless recurrent models for multi-label classification. In CVPR, 2020.
+[67] Chiyuan Zhang, Samy Bengio, Moritz Hardt, Benjamin Recht, and Oriol Vinyals. Understanding deep learning (still) requires rethinking generalization. Communications of the ACM, 64(3):107-115, 2021.
+
+[68] Renrui Zhang, Rongyao Fang, Peng Gao, Wei Zhang, Kunchang Li, Jifeng Dai, Yu Qiao, and Hongsheng Li. Tip-adapter: Training-free clip-adapter for better vision-language modeling. arXiv preprint arXiv:2111.03930, 2021.
+[69] Yang Zhang, Boqing Gong, and Mubarak Shah. Fast zero-shot image tagging. In CVPR, 2016.
+[70] Chong Zhou, Chen Change Loy, and Bo Dai. Denseclip: Extract free dense labels from clip. arXiv preprint arXiv:2112.01071, 2021.
+[71] Kaiyang Zhou, Jingkang Yang, Chen Change Loy, and Ziwei Liu. Learning to prompt for vision-language models. arXiv preprint arXiv:2109.01134, 2021.
+[72] Kaiyang Zhou, Jingkang Yang, Chen Change Loy, and Ziwei Liu. Conditional prompt learning for vision-language models. arXiv preprint arXiv:2203.05557, 2022.
+[73] Feng Zhu, Hongsheng Li, Wanli Ouyang, Nenghai Yu, and Xiaogang Wang. Learning spatial regularization with image-level supervisions for multi-label image classification. In CVPR, 2017.
+[74] Ke Zhu and Jianxin Wu. Residual attention: A simple but effective method for multi-label recognition. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 184-193, 2021.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] Please refer to the limitations in the conclusion
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] Please refer to the Negative Societal Impacts. in the conclusion
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] Please check our project page included in the abstract and https://github.com/sunxm2357/DualCoOp for our code. We use public datasets which can downloaded directly and provide the details for the hyperparameters in the training see Sec. 4
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] Please check implementation details in Sec. 4
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] Please check implementation details in Sec. 4
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [N/A]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/images.zip b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..296d18e1695da8d8169408e8f7affe7b88ba85bc
--- /dev/null
+++ b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:37bffb13ae9186422d8dec96b06dae79a87d06d95bb0a69fa6168fa7229f2b96
+size 593811
diff --git a/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/layout.json b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..20105025b10e43e378ac74e2befa69397f4f3807
--- /dev/null
+++ b/dualcoopfastadaptationtomultilabelrecognitionwithlimitedannotations/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3f9623fd68ac6940a3da233ff0aa69cee505e91bf4a5c884cd1ea4cb30157f67
+size 424042
diff --git a/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/5b1c0314-65cc-4c15-ad5e-c31a6e0ab1b5_content_list.json b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/5b1c0314-65cc-4c15-ad5e-c31a6e0ab1b5_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..125ea9cb63ed3fe144bfaab970f5375febf70ed2
--- /dev/null
+++ b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/5b1c0314-65cc-4c15-ad5e-c31a6e0ab1b5_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6a3d1e937a136b5791759d61ef9cc7813267b0b008025c9ebac375fde9f4bf84
+size 88880
diff --git a/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/5b1c0314-65cc-4c15-ad5e-c31a6e0ab1b5_model.json b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/5b1c0314-65cc-4c15-ad5e-c31a6e0ab1b5_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..10963d16d26b190b043d0f0d8a558d60202ac852
--- /dev/null
+++ b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/5b1c0314-65cc-4c15-ad5e-c31a6e0ab1b5_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b549d592b518aa0376ac80fc405ad5cbd72b7810fd0ce3b0433b58c3ae9f58ec
+size 109897
diff --git a/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/5b1c0314-65cc-4c15-ad5e-c31a6e0ab1b5_origin.pdf b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/5b1c0314-65cc-4c15-ad5e-c31a6e0ab1b5_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..4e6d6c8369029d609c91882a4bacc282ceb796b9
--- /dev/null
+++ b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/5b1c0314-65cc-4c15-ad5e-c31a6e0ab1b5_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:95f64f2fcd37573a1c37614b6b5fc69783309ffe0918b996910461e7778e4ce8
+size 1647357
diff --git a/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/full.md b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..4e2e3c1ec54df4404adab7c8973ea1caf093b7ec
--- /dev/null
+++ b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/full.md
@@ -0,0 +1,370 @@
+# Dual-Curriculum Contrastive Multi-Instance Learning for Cancer Prognosis Analysis with Whole Slide Images
+
+Chao Tu $^{1,2,3}$ , Yu Zhang $^{1,2,3,*}$ , Zhenyuan Ning $^{1,2,3,*}$
+
+$^{1}$ School of Biomedical Engineering, $^{2}$ Guangdong Provincial Key Laboratory of Medical Image Processing, $^{3}$ Guangdong Province Engineering Laboratory for Medical Imaging and Diagnostic Technology, Southern Medical University, Guangzhou 510515, China {tchaoc17@smu.edu.cn, yuzhang@smu.edu.cn, jonnyning@foxmail.com} *Corresponding authors.
+
+# Abstract
+
+The multi-instance learning (MIL) has advanced cancer prognosis analysis with whole slide images (WSIs). However, current MIL methods for WSI analysis still confront unique challenges. Previous methods typically generate instance representations via a pre-trained model or a model trained by the instances with bag-level annotations, which, however, may not generalize well to the downstream task due to the introduction of excessive label noises and the lack of fine-grained information across multi-magnification WSIs. Additionally, existing methods generally aggregate instance representations as bag ones for prognosis prediction and have no consideration of intra-bag redundancy and inter-bag discrimination. To address these issues, we propose a dual-curriculum contrastive MIL method for cancer prognosis analysis with WSIs. The proposed method consists of two curriculums, i.e., saliency-guided weakly-supervised instance encoding with cross-scale tiles and contrastive-enhanced soft-bag prognosis inference. Extensive experiments on three public datasets demonstrate that our method outperforms state-of-the-art methods in this field. The code is available at https://github.com/YuZhang-SMU/CancerPrognosis-Analysis/tree/main/DC_MIL%20Code.
+
+# 1 Introduction
+
+Cancer prognosis analysis is of great significance for risk-benefit assessment and clinical decision [1]. Computational whole slide image (WSI), which entails the quantitative profiling of spatial patterns and tumor microenvironments in tissue slides, has advanced the application of deep learning in cancer prognosis analysis [2, 3]. However, deep learning in WSIs is often hindered by the gigapixel size and the lack of pixel-level annotations [4]. Recently, multi-instance learning (MIL) methods have attracted increasing attention to performing inference in a weakly-supervised manner and have been successfully applied to WSI analysis [5, 6, 7].
+
+In general, the MIL consists of two stages, i.e., instance encoding stage and instance aggregation stage [8, 9]. In the encoding stage, several methods have utilized the pre-trained model (e.g., ResNet on ImageNet) to extract instance representations in an unsupervised way (i.e., without the reference of outcome labels) [10, 11, 12]. However, recent studies have demonstrated that the pre-trained model may not generalize well to the downstream tasks as it is task-agnostic1 and inclined to overfit
+
+the pretraining objective [13, 14, 15]. Alternatively, some work directly assigned each instance the bag-level annotation (i.e., the survival time of patient) for network training, which introduces task-specific supervision and improves model's generalisability [16, 17, 18]. Actually, the prognosis evaluation is primarily and comprehensively determined by certain representative regions, yet those regions might only occupy a small portion of WSI [17]. As a result, the strong supervision on all instances, especially on prognosis-irrelevant tiles, will introduce excessive label noises and limit model's performance [19, 20]. For alleviating this issue, a feasible way is to supervise the instance encoding in a weak and easy-to-hard manner. On the other hand, existing methods often generate mono-scale instance representations [11, 21] or typically concatenate multi-scale information from multi-magnification WSIs [22, 23], which may cause feature redundancy and ignore fine-grained details across multi-magnification images.
+
+In the aggregation stage, most previous studies aggregated instance representations within a bag for prognosis estimation by certain fusion strategies (e.g., pooling operation and attention mechanism) [24, 25]. However, it may overwhelm prognosis-relevant information, cause intra-bag redundancy, and reduce inter-bag discrimination, if many instances from irrelevant regions are enrolled [12, 26]. To address the aforementioned issues, we arm MIL with a dual-curriculum strategy and propose a dual-curriculum contrastive MIL method for cancer prognosis analysis with WSIs. The proposed method consists of two easy-to-hard curriculums, i.e., saliency-guided weakly-supervised instance encoding with cross-scale tiles and contrastive-enhanced soft-bag prognosis inference. The main contributions are summarized as follows:
+
+1) We present a dual-curriculum contrastive MIL method which includes two easy-to-hard curriculums. We first conduct a preliminary task to learn instance representations by considering risk stratification status (degraded from survival time) as annotation, followed by the prognosis inference with survival time as supervision.
+2) We design the first curriculum of saliency-guided weakly-supervised instance encoding with cross-scale tiles. It is supervised by relatively weak annotations so as to reduce label noises and maintain prognosis-related guidance. Additionally, to imitate the reviewing procedure of pathologists, we leverage the low-magnification saliency map to guide the encoding of high-magnification instances for exploring fine-grained information across multi-magnification WSIs.
+3) We develop the second curriculum of contrastive-enhanced soft-bag prognosis inference. Instead of enrolling all instances, we adaptively identify and integrate representative instances within a bag (as the soft-bag) for prognosis inference and leverage the constrained self-attention strategy to obtain extra sparseness for soft-bag representations, which can help reduce intra-bag redundancy in both instance and feature levels. Meanwhile, we improve the Cox loss with two-tier contrastive learning for enhancing intra-bag and inter-bag discrimination.
+4) We evaluate the proposed method on three public cancer datasets, and extensive experiments demonstrate its superiority in cancer prognosis analysis with WSIs.
+
+# 2 Related Work
+
+# 2.1 WSI-based Cancer Prognosis Model
+
+In recent years, many methods, especially convolutional neural networks (CNNs), have been developed for cancer prognosis evaluation with WSIs [27, 28, 29]. Due to the gigapixel size of WSI, some methods took small-size ROIs selectively sampled from WSIs as network's input for training and inference, in which all ROIs were assigned with patient-level outcome labels [30, 31]. However, these methods generally require prior knowledge from pathologists, which is experience-dependent and may suffer from high inter-observer variation. Therefore, current researches have proposed to crop the entire WSI into many tiles for model's input so as to make full use of available information contained by WSI [10, 32, 33]. However, these methods often confront the lack of tile-level annotations and may result in a sub-optimal solution. To this end, MIL methods have been introduced to perform cancer prognosis analysis in a weakly-supervised manner and have shown promising performance in this field [5, 28].
+
+# 2.2 Multi-instance Learning in WSI Analysis
+
+The MIL methods in WSI analysis can be roughly divided into two categories according to the way instances are leveraged in the model [12, 17]. The one infers bag-level prediction from instance-level probabilities via average pooling, maximum pooling, or other ensemble strategies [34, 35]. By comparison, the other one, referred to as the bag embedding method, aggregates instance representations as bag ones, upon which a model is constructed for bag-level prediction [36, 37]. The former is simple and straightforward but empirically proven to be inferior to the latter in terms of generalization performance. Therefore, the bag embedding method has attracted extensive attention in WSI analysis [17]. For example, Courtiol et al. [6] developed a MIL method based on CNN, called MesoNet, to accurately predict the overall survival of mesothelioma patients with WSIs. Yao et al. [5] proposed a deep attention multi-instance survival model to efficiently learn features from WSIs and fuse them for prognosis prediction. Our method essentially belongs to the bag embedding method. Different from previous work, the proposed method consists of two easy-to-hard curriculums, comprehensively considering fine-grained information across multi-magnification WSIs, intra-bag redundancy, and inter-bag discrimination.
+
+# 3 Method
+
+# 3.1 Problem Formulation
+
+Denote the triplet $\{\mathbf{X}_n, \mathbf{T}_n, \delta_n\}_{n=1}^N$ as the dataset consisting of $N$ patients, where $\mathbf{X}_n$ is the $n$ -th patient with one or more WSIs, and $\mathbf{T}_n$ and $\delta_n$ are respectively its observed survival time and event indicator (viz. equals to 1 and 0 for uncensored and censored samples, respectively). Prognosis analysis is an ordinal regression task that models time-to-event distribution, which is formulated as
+
+$$
+\hat {\mathbf {T}} _ {n} = \mathbb {S} (\mathbf {X} _ {n}), \tag {1}
+$$
+
+where $\mathbb{S}$ and $\hat{\mathbf{T}}_n$ denote the prognosis inference function and the estimated survival time, respectively. In practice, it is difficult to directly feed the WSI into the model due to its gigapixel size. Accordingly, many studies [10, 32, 33] have cropped the WSI into a large amount of tiles and generated a bag $\mathbf{X}_n = \{\mathbf{x}_{n,i}\}_{i = 1}^{N_n}$ that contains $N_{n}$ instances (tiles) for the $n$ -th patient. Then, MIL is leveraged to construct the prognosis model as follows:
+
+$$
+\hat {\mathbf {T}} _ {n} = \mathbb {S} (\mathbb {A} \left\{\mathbb {E} \left(\mathbf {x} _ {n, i}\right): \mathbf {x} _ {n, i} \in \mathbf {X} _ {n} \right\}), \tag {2}
+$$
+
+where $\mathbb{E}$ is an instance encoding function that extracts feature representation for each instance, and $\mathbb{A}$ is a permutation-invariant instance aggregation function that pools the instance representations into the bag ones. However, previous studies [10, 11, 12, 16, 17, 18] typically generate instance representations via a pre-trained model or a model trained by the instances with bag-level annotations, which may not generalize well to the downstream task. As a result, we decompose the model into two easy-to-hard curriculums, including (1) Curriculum I (C-I): instance encoding (via $\mathbb{E}$ ) during preliminary risk stratification (via $\mathbb{C}$ , a risk stratification function), and (2) Curriculum II (C-II): prognosis inference (via $\mathbb{S}$ ) after instance aggregation (via $\mathbb{A}$ ). Formally, the optimization process can be formulated as
+
+$$
+\left\{ \begin{array}{l} \mathrm {C - I}: \hat {\mathbb {E}}, \hat {\mathbb {C}} = \arg \min _ {\mathbb {E}, \mathbb {C}} \sum_ {n = 1} ^ {N} \dagger (\mathbf {Y} _ {n} = = 1 \| 0) \sum_ {i = 1} ^ {N _ {n}} [ \mathbb {C} \{\mathbb {E} (\mathbf {x} _ {n, i}): \mathbf {x} _ {n, i} \in \mathbf {X} _ {n} \}, \mathbf {Y} _ {n} ] _ {\mathcal {L} _ {1}} \\ \mathrm {C - I I}: \hat {\mathbb {S}}, \hat {\mathbb {A}} = \arg \min _ {\mathbb {S}, \mathbb {A}} \sum_ {n = 1} ^ {N} [ \mathbb {S} (\mathbb {A} \{\hat {\mathbb {E}} (\mathbf {x} _ {n, i}): \mathbf {x} _ {n, i} \in \mathbf {X} _ {n} \}), \mathbf {T} _ {n}, \boldsymbol {\delta} _ {n} ] _ {\mathcal {L} _ {\mathrm {I I}}} \end{array} , \right. \tag {3}
+$$
+
+where $\dagger(\cdot)$ outputs 1 (0) if true (false), and $\mathcal{L}_{\mathrm{I}}$ and $\mathcal{L}_{\mathrm{II}}$ denote the loss functions for C-I and C-II, respectively. The risk stratification status $\mathbf{Y}_n$ is determined by $\{\mathbf{T}_n, \pmb{\delta}_n\}$ with a three-year time threshold (denoted as $\mathbf{T}_r$ ) as follows:
+
+$$
+\mathbf {Y} _ {n} = \left\{ \begin{array}{l l} 1 & , \mathbf {T} _ {n} \leq \mathbf {T} _ {r} \& \& \delta_ {n} = = 1 \\ 0 & , \mathbf {T} _ {n} > \mathbf {T} _ {r} \\ - & , \text {o t h e r s} \end{array} . \right. \tag {4}
+$$
+
+
+Figure 1: The pipeline of the proposed dual-curriculum contrastive MIL method for cancer prognosis analysis with WSIs. The left is saliency-guided weakly-supervised instance encoding with cross-scale tiles (Curriculum I), while the right one is contrastive-enhanced soft-bag prognosis inference (Curriculum II).
+
+# 3.2 Curriculum I: Saliency-guided Weakly-supervised Instance Encoding with Cross-scale Tiles
+
+In this section, we introduce the first curriculum of saliency-guided weakly-supervised instance encoding with cross-scale tiles, as shown in Figure 1. Given the input instance with $S$ magnifications $\{\mathbf{x}_{n,i}^s\}_{s=1}^S$ ( $S = 3$ in this work), the proposed method contains $S$ branches and each branch takes different-magnification tiles as input, which aims to explore multi-scale information from multi-magnification images. For the $s$ -th branch, it mainly consists of a feature extractor $\mathbb{F}^s$ , a feature aggregator $\mathbb{G}^s$ and a classifier $\mathbb{C}^s$ . And $\{\mathbb{F}^s\}_{s=1}^S$ and $\{\mathbb{G}^s\}_{s=1}^S$ form $\mathbb{E}$ , while $\{\mathbb{C}^s\}_{s=1}^S$ constitute $\mathbb{C}$ in Eq.(3). The feature extractor $\mathbb{F}^s$ contains $s$ residual modules with the parameters $\{\pmb{\theta}_{\mathbb{F}^s}^1, \dots, \pmb{\theta}_{\mathbb{F}^s}\}$ , and the first $s-1$ modules share the same architecture with $\mathbb{F}^{s-1}$ if $s > 1$ . Figure 2 illustrates the architecture details. Different from previous studies [22, 23] that separately feed $\{\mathbf{x}_{n,i}^s\}_{s=1}^S$ into the network and ignore fine-grained details across multi-magnification images, we encourage the network to focus on salient regions by utilizing the prior knowledge of the $(s-1)$ -th branch to highlight the input $\mathbf{x}_{n,i}^s$ , which can be formulated as
+
+$$
+\hat {\mathbf {x}} _ {n, i} ^ {s} = \left\{ \begin{array}{l l} \mathbf {x} _ {n, i} ^ {s} & , s = 1 \\ \mathbf {m} _ {n, i} ^ {s - 1} \otimes \mathbf {x} _ {n, i} ^ {s} & , s > 1 \end{array} , \right. \tag {5}
+$$
+
+where $\otimes$ denotes the element-wise multiplication operator, and $\mathbf{m}_{n,i}^{s-1}$ is the salient mask indicating high-risk regions. For convenience, we introduce how to acquire $\mathbf{m}_{n,i}^{s}$ , which is easily generalized to $\mathbf{m}_{n,i}^{s-1}$ . Specifically, $\mathbf{m}_{n,i}^{s}$ is computed by Class Activation Map [38] as follows:
+
+$$
+\mathbf {m} _ {n, i} ^ {s} = \boldsymbol {\omega} ^ {s} \odot \mathbb {F} ^ {s} \left(\hat {\mathbf {x}} _ {n, i} ^ {s}\right), \tag {6}
+$$
+
+where $\odot$ is the channel-wise multiplication operator, and $\omega^s$ indicates the importance of channel of feature maps for risk stratification prediction in the $s$ -th branch. To obtain $\omega^s$ , we first generate an instance embedding vector $\mathbf{z}_{n,i}^s$ by
+
+$$
+\mathbf {z} _ {n, i} ^ {s} = \mathbb {G} ^ {s} \left(\mathbb {F} ^ {s} \left(\hat {\mathbf {x}} _ {n, i} ^ {s}\right)\right), \tag {7}
+$$
+
+where $\mathbb{G}^s$ is a feature aggregator that performs channel-direction attention (as shown in Figure 2).
+
+Incorporating comprehensive information from current and previous branches, we subsequently feed instance embeddings $\{\mathbf{z}_{n,i}^j\}_{j=1}^s$ into the classifier $\mathbb{C}^s$ for predicting the high-risk probability $\mathbf{p}_{n,i}^s$ , which is computed by
+
+$$
+\mathbf {p} _ {n, i} ^ {s} = \mathbb {C} ^ {s} \left(\left\{\mathbf {z} _ {n, i} ^ {j} \right\} _ {j = 1} ^ {s}\right) = \phi \left(\overline {{\boldsymbol {\omega}}} ^ {s} \times \left[ \mathbf {z} _ {n, i} ^ {1}, \dots , \mathbf {z} _ {n, i} ^ {s - 1} \right] ^ {T} + \boldsymbol {\omega} ^ {s} \times \left[ \mathbf {z} _ {n, i} ^ {s} \right] ^ {T}\right), \tag {8}
+$$
+
+
+
+
+Figure 2: The detailed architectures of some modules in the model. The first row shows the architectures of feature extractor $\mathbb{F}$ , feature aggregator $\mathbb{G}$ and classifier $\mathbb{C}$ in Curriculum I, while the second row illustrates the architectures of soft-bag learning model $\mathbb{B}$ , the constrained self-attention module $\mathbb{D}$ and contrastive-enhanced prognosis inference function $\mathbb{S}$ in Curriculum II.
+
+where $\mathbb{C}^s$ is implemented by a linear layer with the parameters $\{\overline{\omega}^s, \omega^s\}$ (as shown in Figure 2), and $\phi$ and $T$ denote softmax activation function and transposition operation, respectively.
+
+We introduce a hierarchical transfer strategy to leverage the prior from different-magnification images, accelerate network convergence, and maintain the specificity of current branch. Specifically, as shown in Figure 1, the parameter $\theta_{\mathbb{F}^s}^s$ (for any $s$ ) of the $s$ -th module in $\mathbb{F}^s$ is completely learnable and has not any constraints, while $\theta_{\mathbb{F}^s}^{s-1}$ (for $s > 1$ ) is also learnable but constrained to approximate $\theta_{\mathbb{F}^{s-1}}^{s-1}$ by the structural loss $\mathcal{L}_{\Omega}$ as follows:
+
+$$
+\mathcal {L} _ {\Omega} = \left\| \boldsymbol {\theta} _ {\mathbb {F} ^ {s}} ^ {s - 1} - \boldsymbol {\theta} _ {\mathbb {F} ^ {s - 1}} ^ {s - 1} \right\| _ {2}. \tag {9}
+$$
+
+For the remaining parameters $\{\pmb{\theta}_{\mathbb{F}^s}^1,\dots ,\pmb{\theta}_{\mathbb{F}^s}^{s - 2}\}$ (for $s > 2$ ) in $\mathbb{F}^s$ , they are first initialized with $\{\pmb{\theta}_{\mathbb{F}^{s - 1}}^1,\dots ,\pmb{\theta}_{\mathbb{F}^{s - 1}}^{s - 2}\}$ , and then are frozen. Furthermore, we propose a hybrid loss function $\mathcal{L}_{\mathrm{I}}$ that contains two parts, i.e., empirical loss $\mathcal{L}_{\ell}$ and structural loss $\mathcal{L}_{\Omega}$ , to train the network:
+
+$$
+\mathcal {L} _ {1} = \mathcal {L} _ {\ell} + \beta_ {\Omega} \mathcal {L} _ {\Omega}, \tag {10}
+$$
+
+where $\beta_{\Omega}$ is the weight coefficient, and $\mathcal{L}_{\ell}$ is defined as
+
+$$
+\mathcal {L} _ {\ell} = - \frac {1}{N N _ {n}} \sum_ {n = 1} ^ {N} \sum_ {i = 1} ^ {N _ {n}} \mathbf {y} _ {n, i} ^ {s} \log \left(\mathbf {p} _ {n, i} ^ {s}\right) + \left(1 - \mathbf {y} _ {n, i} ^ {s}\right) \log \left(1 - \mathbf {p} _ {n, i} ^ {s}\right), \tag {11}
+$$
+
+where $\mathbf{y}_{n,i}^{s}\in \mathbf{Y}_{n}$ denotes the risk stratification status of the $i$ -th instance in the $n$ -th bag.
+
+Finally, we can obtain the multi-scale instance representation $\mathbf{z}_{n,i}$ for subsequent prognosis inference task by $\mathbf{z}_{n,i} = [\mathbf{z}_{n,i}^{1},\dots ,\mathbf{z}_{n,i}^{S}]$ .
+
+# 3.3 Curriculum II: Contrastive-enhanced Soft-bag Prognosis Inference
+
+In this section, we develop the second curriculum of contrastive-enhanced soft-bag prognosis inference, as shown in Figure 1. Given a set of instance representations from the $n$ -th bag, i.e., $\mathbf{Z}_n = [\mathbf{z}_{n,1};\mathbf{z}_{n,2};\dots ;\mathbf{z}_{n,N_n}]^T\in \mathbb{R}^{N_n\times C}$ , where $C$ denotes the feature dimension, the proposed method mainly consists of a soft-bag learning module $\mathbb{B}$ , a constrained self-attention module $\mathbb{D}$ , a contrastive-enhanced prognosis inference function $\mathbb{S}$ , where $\mathbb{B}$ and $\mathbb{D}$ form $\mathbb{A}$ in Eq.(3).
+
+For the soft-bag learning module $\mathbb{B}$ (as shown in Figure 2), it first learns new bag representation $\mathbf{E}_n\in \mathbb{R}^{N_n\times D}$ (where $\bar{D}$ denotes the feature dimension) from $\mathbf{Z}_n$ via a linear layer. Instead of enrolling all instances, we adaptively identify and integrate representative instances within a bag by introducing the function $\mathbb{H}$ :
+
+$$
+\hat {\mathbf {E}} _ {n} = \mathbb {H} \left(\mathbf {E} _ {n}, \hat {\mathbf {h}} _ {n}\right) = \phi \left(d i a g \left\{\hat {\mathbf {h}} _ {n} \right\} \times \mathbf {W} _ {n}\right) ^ {T} \times \left(d i a g \left\{\hat {\mathbf {h}} _ {n} \right\} \times \mathbf {E} _ {n}\right), \tag {12}
+$$
+
+where $\hat{\mathbf{E}}_n\in \mathbb{R}^{N_B\times D}$ ( $N_{B}$ is the number of selected instances in each bag, and $N_B\ll N_n$ ) is the feature representation of those selected instances, and $\mathbf{W}_n\in \mathbb{R}^{N_n\times N_B}$ denotes the weight matrix
+
+that is generated by feeding $\mathbf{E}_n$ into two linear layers (as shown in Figure 2). And $\hat{\mathbf{h}}_n\in \mathbb{R}^{N_n\times 1}$ is an indicator vector that adaptively selects $N_B$ representative instances and is computed by
+
+$$
+\hat {\mathbf {h}} _ {n} = \arg \max _ {\mathbf {h} _ {n}} \mathbb {S} \left(\mathbb {D} \left(\mathbb {H} \left(\mathbf {E} _ {n}, \mathbf {h} _ {n}\right)\right)\right), \quad s. t. \sum_ {i = 1} ^ {N _ {n}} \mathbf {h} _ {n, i} = N _ {B}. \tag {13}
+$$
+
+The constrained self-attention module $\mathbb{D}$ and contrastive-enhanced prognosis inference function $\mathbb{S}$ are introduced below.
+
+We leverage $\mathbb{D}$ to obtain extra sparseness for soft-bag representations. Given the input $\hat{\mathbf{E}}_n$ , it first linearly projects $\hat{\mathbf{E}}_n$ into three feature spaces (i.e., $\mathbf{Q}_n \in \mathbb{R}^{N_B \times \hat{D}}$ , $\mathbf{K}_n \in \mathbb{R}^{N_B \times \hat{D}}$ , and $\mathbf{V}_n \in \mathbb{R}^{N_B \times \hat{D}}$ , and $\hat{D}$ is the feature dimension) via three mapping matrices (i.e., $\mathbf{W}_Q \in \mathbb{R}^{D \times \hat{D}}$ , $\mathbf{W}_K \in \mathbb{R}^{D \times \hat{D}}$ , and $\mathbf{W}_V \in \mathbb{R}^{D \times \hat{D}}$ ), in which the mapping matrices are constrained by
+
+$$
+\mathcal {L} _ {s} = \left(\| \mathbf {W} _ {Q} \| _ {1} + \| \mathbf {W} _ {K} \| _ {1} + \| \mathbf {W} _ {V} \| _ {1}\right). \tag {14}
+$$
+
+Then, the sparse soft-bag representation $\mathbf{B}_n\in \mathbb{R}^{1\times D_B}$ (where $D_B$ is the feature dimension) can be obtained by the correlation-based activation mechanism [39], as illustrated in Figure 2. It is worth mentioning that the collaboration of $\mathbb{B}$ and $\mathbb{D}$ can significantly help reduce intra-bag redundancy in both instance and feature levels so as to improve model's generalization.
+
+For $\mathbb{S}$ , it takes $\mathbf{B}_n$ as input to infer the relative risk $\hat{\mathbf{T}}_n$ via a linear projection matrix $\mathbf{W}_{\mathbb{S}} \in \mathbb{R}^{D_B \times 1}$ , as shown in Figure 2. In order to boost the ability of soft-bag inference, we perform two-tier contrastive learning (TCL) to enhance intra-bag and inter-bag discrimination. We assume that a bag $\mathbf{B}_n$ is sampled from the distribution $\mathcal{O} = \{\mathcal{O}^+, \mathcal{O}^-\}$ , where the positive source $\mathcal{O}^+$ denotes the distribution of high-hazard samples (i.e., those with survival time $\leq \mathbf{T}_r$ ), while the negative source $\mathcal{O}^-$ presents the distribution of low-hazard samples (i.e., those with survival time $>\mathbf{T}_r$ ). We first focus on inter-bag discrimination. Let $\mathcal{B}_n = \{\mathbf{B}_1, \dots, \mathbf{B}_{N_{B_n}}\} / \mathbf{B}_n$ present the collection of bags (except $\mathbf{B}_n$ ) from the same source $\mathcal{O}^+$ (or $\mathcal{O}^-$ ) as $\mathbf{B}_n$ , where $N_{B_n}$ denotes the number of such bags. We can obtain the representation of $\mathcal{B}_n$ (denoted as $\hat{\mathbf{B}}_n$ ) by merging the representations of all bags in $\mathcal{B}_n$ via an attention function $\mathbb{K}$ (as illustrated in Figure 2). Inspired by [40], inter-bag discrimination can be enhanced by maximally preserving the mutual information between $\mathbf{B}_n$ and $\hat{\mathbf{B}}_n$ as follows:
+
+$$
+\sum_ {n \in [ N ]} \mathbb {I} \left(\mathbf {B} _ {n}, \hat {\mathbf {B}} _ {n}\right) = \sum_ {n \in [ N ]} p \left(\mathbf {B} _ {n}, \hat {\mathbf {B}} _ {n}\right) \log \frac {p \left(\mathbf {B} _ {n} \mid \hat {\mathbf {B}} _ {n}\right)}{p \left(\mathbf {B} _ {n}\right)}. \tag {15}
+$$
+
+According to Eq.(12), partial instances within a bag are adaptively discarded, and the rest remained. However, all instances within the bag belong to homologous tissues sampled from the same patient, which means that it should show potential correlation among these instances. Therefore, similar to Eq.(15), we maximize the following mutual information to improve intra-bag discrimination:
+
+$$
+\sum_ {n \in [ N ]} \mathbb {I} \left(\mathbf {B} _ {n}, \overline {{\mathbf {B}}} _ {n}\right) = \sum_ {n \in [ N ]} p \left(\mathbf {B} _ {n}, \overline {{\mathbf {B}}} _ {n}\right) \log \frac {p \left(\mathbf {B} _ {n} \mid \overline {{\mathbf {B}}} _ {n}\right)}{p \left(\mathbf {B} _ {n}\right)}, \tag {16}
+$$
+
+where $\overline{\mathbf{B}}_n$ is obtained via $\mathbb{K}$ to merge the representations of those discarded instances $\overline{\mathbf{E}}_n$ that has the definition of $\overline{\mathbf{E}}_n = \mathbb{H}(\mathbf{E}_n, \mathbf{1} - \hat{\mathbf{h}}_n)$ , as illustrated in Figure 2. To this end, we propose to jointly maximize Eq.(15) and (16), i.e., $\max \left( \sum_{n \in [N]} \mathbb{I}(\mathbf{B}_n, \hat{\mathbf{B}}_n) + \mathbb{I}(\mathbf{B}_n, \overline{\mathbf{B}}_n) \right)$ , which is formulated by
+
+$$
+\max \left(\sum_ {n \in [ N ]} \log \frac {p \left(\mathbf {B} _ {n} \mid \hat {\mathbf {B}} _ {n}\right)}{p \left(\mathbf {B} _ {n}\right)} + \log \frac {p \left(\mathbf {B} _ {n} \mid \overline {{\mathbf {B}}} _ {n}\right)}{p \left(\mathbf {B} _ {n}\right)}\right) = \max \left(\sum_ {n \in [ N ]} \log \frac {p \left(\mathbf {B} _ {n} \mid \hat {\mathbf {B}} _ {n}\right) p \left(\mathbf {B} _ {n} \mid \overline {{\mathbf {B}}} _ {n}\right)}{p \left(\mathbf {B} _ {n}\right) p \left(\mathbf {B} _ {n}\right)}\right). \tag {17}
+$$
+
+Instead of constructing a generative model $p(\mathbf{B}_n|\hat{\mathbf{B}}_n)p(\mathbf{B}_n|\overline{\mathbf{B}}_n)$ , we leverage a log-bilinear function $\mathbb{L}$ to model the density ratio which preserves the mutual information:
+
+$$
+\begin{array}{l} \mathbb {L} \left(\mathbf {B} _ {n}, \hat {\mathbf {B}} _ {n}, \overline {{\mathbf {B}}} _ {n}\right) = e x p \left(\mathbf {B} _ {n} ^ {T} \mathbf {W} _ {\mathbb {L}} \hat {\mathbf {B}} _ {n}\right) e x p \left(\mathbf {B} _ {n} ^ {T} \mathbf {V} _ {\mathbb {L}} \overline {{\mathbf {B}}} _ {n}\right) (18) \\ = \exp \left(\mathbf {B} _ {n} ^ {T} \mathbf {W} _ {\mathbb {L}} \hat {\mathbf {B}} _ {n} + \mathbf {B} _ {n} ^ {T} \mathbf {V} _ {\mathbb {L}} \overline {{\mathbf {B}}} _ {n}\right) \propto \frac {p \left(\mathbf {B} _ {n} \mid \hat {\mathbf {B}} _ {n}\right) p \left(\mathbf {B} _ {n} \mid \overline {{\mathbf {B}}} _ {n}\right)}{p \left(\mathbf {B} _ {n}\right) p \left(\mathbf {B} _ {n}\right)}, (19) \\ \end{array}
+$$
+
+where $\mathbf{W}_{\mathbb{L}}$ and $\mathbf{V}_{\mathbb{L}}$ are trainable parameters. Motivated by [41], we design the TCL loss based on the InfoNCE function, which has the following definition:
+
+$$
+\mathcal {L} _ {t c l} = - \underline {{\boldsymbol {E}}} \left[ \log \frac {\mathbb {L} \left(\mathbf {B} _ {n} , \hat {\mathbf {B}} _ {n} , \overline {{\mathbf {B}}} _ {n}\right)}{\sum_ {i \in [ N ] , i \neq n} \mathbb {L} \left(\mathbf {B} _ {n} , \hat {\mathbf {B}} _ {i} , \overline {{\mathbf {B}}} _ {i}\right)} \right], \tag {20}
+$$
+
+where $\mathcal{B}$ denotes the collection of all bags. Additionally, we utilize the negative log-partial likelihood of Cox proportional hazard regression model [42] to train the network, which is computed by
+
+$$
+\mathcal {L} _ {c o x} = - \log (\prod_ {n: \boldsymbol {\delta} _ {n} = 1} \frac {e x p (\mathbf {B} _ {n} \mathbf {W} _ {\mathbb {S}})}{\sum_ {j \in R (\mathbf {T} _ {n})} e x p (\mathbf {B} _ {j} \mathbf {W} _ {\mathbb {S}})}) = - \sum_ {n: \boldsymbol {\delta} _ {n} = 1} (\mathbf {B} _ {n} \mathbf {W} _ {\mathbb {S}} - \log (\sum_ {j \in R (\mathbf {T} _ {n})} e x p (\mathbf {B} _ {j} \mathbf {W} _ {\mathbb {S}}))),
+$$
+
+where $\mathbf{W}_{\mathbb{S}}$ is the linear projection matrix in $\mathbb{S}$ , and $R(\mathbf{T}_n) = \{i:\mathbf{T}_i\geq \mathbf{T}_n\}$ is the collection of all samples (including censored and uncensored ones) with survival time being longer than $\mathbf{T}_n$ . Finally, the loss function $\mathcal{L}_{\mathrm{II}}$ for the second curriculum can be defined as
+
+$$
+\mathcal {L} _ {\mathrm {I I}} = \mathcal {L} _ {c o x} + \mathcal {L} _ {t c l} + \beta_ {s} \mathcal {L} _ {s}, \tag {21}
+$$
+
+where $\beta_{s}$ is the weight coefficient.
+
+# 4 Experiments and Results
+
+In this section, we briefly describe datasets, preprocessing, and implementation details, followed by experimental results.
+
+# 4.1 Datasets and Preprocessing
+
+In this work, we evaluated the proposed method on three datasets from The Cancer Genome Atlas (TCGA) database, including colon adenocarcinoma (COAD) $(N = 365)$ , hepatocellular carcinoma (LIHC) $(N = 334)$ , and bladder urothelial carcinoma (BLCA) $(N = 396)$ . Each dataset contained WSIs stained with hematoxylin and eosin (H&E) and clinical information (i.e., survival time and event status). After segmenting tissue areas via the Otsus method, a set of tiles under different magnifications $(20\times, 10\times, 5\times)$ were non-overlappingly sampled from each segmented tissue area, and the window sizes were set to $512\times 512$ , $256\times 256$ , and $128\times 128$ , respectively.
+
+# 4.2 Implementation Details
+
+In our experiments, we adopted the 5-fold cross-validation strategy to comprehensively evaluate our proposed method and the ratio of training and validation sets was set to 4:1. Specifically, we divided the entire dataset into five folds, among which four folds for model training while the remaining one for model evaluation. Notably, the cross-validation strategy was conducted on patient level to prevent data leakage, which means that the WSI of each patient only appeared in one of these subsets. During the training stage, we selected the best model in terms of two specific evaluation metrics for different curriculums. That is, the model with the highest accuracy was selected for Curriculum I, while the model with the highest C-index for Curriculum II. The concordance index (CI), the receiver operating characteristic (ROC) curve, the area under ROC curve (AUC), and Kaplan-Meier (KM) curve were used to assess model's performance. We chose three-year time as threshold for risk stratification status and AUC calculation, which lies on two reasons as follows: 1) Three-year survival time is an important indicator for clinically evaluating the prognosis of patients, especially for three cancer types studied in our work [43, 44, 45]. 2) For the used datasets, using three-year survival time as threshold can make the distribution of positive and negative samples relatively balanced, which is beneficial to network training. We implemented all competing methods using the Pytorch1.9 library on Python3.6. All intensive calculations were offloaded to a 12 GB NVIDIA Pascal Titan X GPU.
+
+Curriculum I. We adopted Adam optimizer with the weight decay of 0.2 for network training. For different magnifications $s \in \{1,2,3\}$ , the learning rate, batch size and epoch number were set to $\{10^{-5}, 3 \times 10^{-6}, 3 \times 10^{-6}\}$ , $\{32,16,16\}$ and $\{50,50,50\}$ , respectively. The weight coefficient $\beta_{\Omega}$ was set to $10^{-5}$ .
+
+Curriculum II. We adopted SGD optimizer with the momentum of 0.9 for network training. The learning rate, batch size and epoch number were set to $10^{-4}$ , 16 and 1000, respectively. The soft-bag size $N_B$ was set to 3 and the weight coefficient $\beta_{s}$ was set to $10^{-3}$ .
+
+Table 1: The results achieved by all competing methods on three datasets (i.e., COAD, LIHC, and BLCA). The boldface denotes the best result.
+
+ | COAD | LIHC | BLCA | Overall |
| CI | AUC | CI | AUC | CI | AUC | CI | AUC |
| WSISA [46] | 0.641±0.027 | 0.673±0.037 | 0.661±0.022 | 0.700±0.071 | 0.639±0.018 | 0.651±0.043 | 0.647 | 0.675 |
| DeepGraphSurv [47] | 0.629±0.054 | 0.639±0.038 | 0.613±0.027 | 0.633±0.047 | 0.620±0.015 | 0.687±0.046 | 0.620 | 0.653 |
| MesoNet [6] | 0.643±0.039 | 0.684±0.052 | 0.629±0.022 | 0.667±0.042 | 0.630±0.021 | 0.648±0.052 | 0.634 | 0.666 |
| DeepAttnMISL [5] | 0.683±0.025 | 0.654±0.045 | 0.672±0.027 | 0.676±0.019 | 0.642±0.020 | 0.661±0.076 | 0.666 | 0.663 |
| Patch-GCN [10] | 0.650±0.013 | 0.562±0.010 | 0.565±0.024 | 0.630±0.061 | 0.571±0.041 | 0.542±0.027 | 0.595 | 0.578 |
| DC_MIL(our) | 0.717±0.012 | 0.754±0.031 | 0.705±0.015 | 0.745±0.012 | 0.672±0.029 | 0.720±0.039 | 0.698 | 0.740 |
+
+
+
+
+
+
+Figure 3: The KM curves with the $p$ -values of all competing methods on three datasets. The farther apart the two curves are, the better the model works.
+
+# 4.3 Comparison with State-of-the-Art Methods
+
+We compared our method with other weakly-supervised methods in cancer prognosis analysis, including clustering approaches [46], graph networks [10, 47], and multi-instance learning methods [5, 6]. Table 1 presents the 5-fold cross-validation results (in terms of CI and AUC) of all competing methods. The KM curves as well as $p$ -values, are provided in Figure 3. We can observe that the proposed method outperforms others in head-to-head comparisons, achieving an overall CI of 0.698 and AUC of 0.740. It may benefit from several potential advantages in DC_MIL: 1) Unlike some methods that leverage the dimension reduction technique [46] or pre-trained model [5, 6, 10, 47], it encodes instances in a weakly-supervised manner so as to reduce label noises and maintain prognosis-related guidance. 2) It utilizes the low-magnification saliency map to guide the encoding of high-magnification instances for exploring fine-grained information across multi-magnification WSIs. 3) It introduces a soft-bag learning method and a constrained self-attention strategy to help reduce intra-bag redundancy in both instance and feature levels, respectively. 4) It equips the Cox loss with two-tier contrastive learning for enhancing intra-bag and inter-bag discrimination. Additionally, we also find that WSISA [46], MesoNet [6], and DeepAttnMISL [5] outperform DeepGraphSurv [47] and Patch-GCN [10], which may owe to the selection of discriminative tiles. More results can refer to Appendix D.
+
+# 4.4 Ablation Study
+
+Ablation on Curriculum I. We validated the efficacy of each crucial component in Curriculum I. From Table 2, we can observe several key points: 1) Compared with pre-trained ResNet-34 (regardless with MM or not), the proposed model shows significant performance improvement, which demonstrates the effectiveness of Curriculum I. 2) The model with MM outperforms the one without MM and gets CI gain of 0.039 and AUC gain of 0.061, which benefits from the utilization
+
+Table 2: The results of ablation experiments on three datasets (i.e., COAD, LIHC, and BLCA). The boldface denotes the best result.
+
+| DC_MIL: C-I + C-II | COAD | LIHC | BLCA |
| MM | SG | HT | C-II | CI | AUC | CI | AUC | CI | AUC |
| X | X | X | ✓ | 0.676±0.031 | 0.696±0.055 | 0.662±0.021 | 0.659±0.032 | 0.640±0.038 | 0.680±0.046 |
| ✓ | X | ✓ | ✓ | 0.692±0.049 | 0.705±0.091 | 0.671±0.045 | 0.720±0.050 | 0.647±0.019 | 0.678±0.037 |
| ✓ | ✓ | X | ✓ | 0.707±0.033 | 0.714±0.061 | 0.699±0.019 | 0.721±0.018 | 0.654±0.016 | 0.700±0.043 |
| PT | w/o | MM | ✓ | 0.642±0.030 | 0.643±0.022 | 0.644±0.030 | 0.640±0.018 | 0.618±0.013 | 0.635±0.028 |
| PT | w/ | MM | ✓ | 0.660±0.017 | 0.683±0.025 | 0.662±0.021 | 0.691±0.036 | 0.633±0.015 | 0.639±0.020 |
| C-I | SB | CSA | TCL | CI | AUC | CI | AUC | CI | AUC |
| ✓ | X | X | X | 0.651±0.020 | 0.697±0.040 | 0.653±0.028 | 0.680±0.022 | 0.621±0.023 | 0.630±0.029 |
| ✓ | ✓ | X | X | 0.670±0.034 | 0.715±0.066 | 0.673±0.031 | 0.717±0.063 | 0.655±0.024 | 0.668±0.033 |
| ✓ | ✓ | X | ✓ | 0.709±0.025 | 0.729±0.063 | 0.693±0.033 | 0.736±0.029 | 0.669±0.017 | 0.696±0.030 |
| ✓ | ✓ | ✓ | X | 0.678±0.031 | 0.721±0.047 | 0.680±0.046 | 0.731±0.044 | 0.659±0.031 | 0.680±0.063 |
| ✓ | ✓ | ✓ | ✓ | 0.717±0.012 | 0.754±0.031 | 0.705±0.015 | 0.745±0.012 | 0.672±0.029 | 0.720±0.039 |
+
+C-I, Curriculum I; MM, multi-magnification strategy; SG, saliency-guided method; HT, hierarchical transfer strategy; PT, pre-trained strategy; C-II, Curriculum II; SB, soft-bag learning; CSA, constrained self-attention module; TCL, two-tier contrastive learning.
+
+of multi-magnification information. 3) The model without SG or FT suffers from performance degradation (average CI drops of 0.028 and 0.011 and AUC drops of 0.039 and 0.028). It indicates that fine-grained information across multi-scale tiles and hierarchical transfer strategy can help significantly improve the performance of model. More results can refer to Appendix D.
+
+Ablation on Curriculum II. We also investigated the efficacy of each key component in Curriculum II. From Table 2, we have the following observations: 1) The baseline method performed prognosis prediction with the Cox model, which achieves average CI of 0.642 and AUC of 0.669. Compared to the baseline method, the model with soft-bag strategy achieves average CI gain of 0.024 and AUC gain of 0.031, which mainly profits by adaptively identifying and integrating the representative instances within a bag. 2) The models with CSA, TCL, and both of them show better performance with average CI gains of 0.006, 0.024, and 0.032 and AUC gains of 0.011, 0.02, and 0.04, respectively, which benefits from the reduction of intra-bag redundancy and the enhancement of intra-bag and inter-bag discrimination. More results can refer to Appendix D.
+
+# 4.5 Parameter Analysis
+
+Influence of the Soft-bag Size $N_B$ . To explore the influence of the soft-bag size $N_B$ , we conducted a set of experiments by varying $N_B$ within the set of $\{1,2,3,4,5\}$ . Note that $N_B = 1$ corresponds to the standard MIL method. From Table 3, we can observe that the model shows the best performance when $N_B$ equals to 3 (for COAD and LIHC) or 4 (for BLAC). It indicates that the top $3\sim 4$ instances are adequate to represent the bag. Besides, the model with $N_B > 1$ works better than the standard MIL method, indicating the effectiveness of the soft-bag strategy for prognosis inference.
+
+Influence of the Magnification Number $S$ . We conducted experiments to investigate the influence of the magnification number $S$ by varying $S$ in the range of $\{1, 2, 3, 4\}$ . Note that $S = 1$ corresponds to the mono-magnification input and $S = 4$ corresponds to the multi-magnification input with $\{20\times, 10\times, 5\times, 2.5\times\}$ . As shown in Table 3, the model's performance is improved as $S$ increases. And the model can achieve the best performance on all datasets and reach a stable state after $S = 3$ .
+
+Influence of the Weight Coefficients $\beta_{\Omega}$ and $\beta_{s}$ . We turned to the influence of the weight coefficients $\beta_{\Omega}$ and $\beta_{s}$ by varying them within the sets of $\{2e - 4,5e - 5,1e - 5,2e - 6\}$ and $\{2e - 2,5e - 3,1e - 3,2e - 4\}$ , respectively. As we can observe from Table 4, the performance of the model fluctuates slightly when both $\beta_{\Omega}$ and $\beta_{s}$ vary, which verifies the robustness of the proposed method to the weight coefficients.
+
+# 4.6 Visualization
+
+This section exhibits the salient maps output by the proposed method for some samples. As illustrated in Figure 4, the model mainly focuses on the fine-grained regions (under $20 \times$ WSIs) that are wrapped by the salient regions under $10 \times$ WSIs, indicating the proposed method can effectively guide the
+
+Table 3: Results (CI) achieved by the proposed model with different $N_B$ and $S$ .
+
+ | NB=1 | NB=2 | NB=3 | NB=4 | NB=5 | S=1 | S=2 | S=3 | S=4 |
| COAD | 0.660 | 0.679 | 0.717 | 0.671 | 0.705 | 0.663 | 0.700 | 0.708 | 0.703 |
| LIHC | 0.631 | 0.691 | 0.705 | 0.704 | 0.705 | 0.667 | 0.686 | 0.703 | 0.697 |
| BLCA | 0.648 | 0.657 | 0.672 | 0.686 | 0.667 | 0.628 | 0.645 | 0.658 | 0.650 |
+
+Table 4: Results (CI) achieved by the proposed model with different weight coefficients ${\beta }_{\Omega }$ and ${\beta }_{s}$ .
+
+ | βΩ=2e-4 | βΩ=5e-5 | βΩ=1e-5 | βΩ=2e-6 | βs=2e-2 | βs=5e-3 | βs=1e-3 | βs=2e-4 |
| COAD | 0.703 | 0.711 | 0.709 | 0.706 | 0.700 | 0.708 | 0.709 | 0.708 |
| LIHC | 0.692 | 0.696 | 0.695 | 0.691 | 0.689 | 0.692 | 0.695 | 0.686 |
| BLCA | 0.669 | 0.672 | 0.672 | 0.671 | 0.667 | 0.672 | 0.672 | 0.670 |
+
+
+
+
+
+
+Low RISK High
+
+
+Figure 4: Visualization of salient maps output by the proposed method. The first column shows the original WSIs, and the second and third columns exhibit the salient maps under $10\times$ and $20\times$ magnifications, respectively.
+
+
+
+
+
+encoding of high-magnification instances so as to encourage the network to focus on more fine-grained information. We have provided more intuitive results and analyses in Appendix D.
+
+# 5 Conclusion
+
+In this paper, we present a dual-curriculum contrastive MIL method for cancer prognosis analysis with WSIs, which contains two easy-to-hard curriculums, i.e., saliency-guided weakly-supervised instance encoding with cross-scale tiles and contrastive-enhanced soft-bag prognosis inference. The proposed network is easy to train in each curriculum and can be applied to gigapixel WSI analysis with good visualization. Besides, the proposed method outperforms state-of-the-art methods in cancer prognosis analysis over three public datasets.
+
+# Acknowledgments
+
+This work was supported in part by the National Natural Science Foundation of China under Grant 61971213 and Grant 61671230, in part by the Basic and Applied Basic Research Foundation of Guangdong Province under Grant 2019A1515010417, and in part by the Guangdong Provincial Key Laboratory of Medical Image Processing under Grant No.2020B1212060039. We would like to express our gratitude to The Cancer Genome Atlas (TCGA) database for the open-source data and to anonymous reviewers for their insightful comments.
+
+# References
+
+[1] Ole-Johan Skrede et al. Deep learning for prediction of colorectal cancer outcome: a discovery and validation study. The Lancet, 395(10221):350-360, 2020.
+[2] Richard Colling et al. Artificial intelligence in digital pathology: a roadmap to routine use in clinical practice. The Journal of Pathology, 249(2):143-150, 2019.
+[3] Chetan L Srinidhi, Ozan Ciga, and Anne L Martel. Deep neural network models for computational histopathology: a survey. Medical Image Analysis, 67:101813, 2021.
+[4] Jana Lipkova et al. Deep learning-enabled assessment of cardiac allograft rejection from endomyocardial biopsies. Nature Medicine, 28(3):575-582, 2022.
+[5] Jiawen Yao, Xinliang Zhu, Jitendra Jonnagaddala, Nicholas Hawkins, and Junzhou Huang. Whole slide images based cancer survival prediction using attention guided deep multiple instance learning networks. Medical Image Analysis, 65:101789, 2020.
+[6] Pierre Courtiol et al. Deep learning-based classification of mesothelioma improves prediction of patient outcome. Nature Medicine, 25(10):1519-1525, 2019.
+[7] Hassan Muhammad et al. Epic-survival: end-to-end part inferred clustering for survival analysis, with prognostic stratification boosting. In Medical Imaging with Deep Learning, 2021.
+[8] Bin Li, Yin Li, and Kevin W Eliceiri. Dual-stream multiple instance learning network for whole slide image classification with self-supervised contrastive learning. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 14318-14328, 2021.
+[9] Gabriele Campanella et al. Clinical-grade computational pathology using weakly supervised deep learning on whole slide images. Nature Medicine, 25(8):1301-1309, 2019.
+[10] Richard J Chen et al. Whole slide images are 2d point clouds: context-aware survival prediction using patch-based graph convolutional networks. In International Conference on Medical Image Computing and Computer-Assisted Intervention, pages 339-349, 2021.
+[11] Ming Y Lu, Drew FK Williamson, Tiffany Y Chen, Richard J Chen, Matteo Barbieri, and Faisal Mahmood. Data-efficient and weakly supervised computational pathology on whole-slide images. Nature Biomedical Engineering, 5(6):555-570, 2021.
+[12] Zhuchen Shao et al. Transmil: transformer based correlated multiple instance learning for whole slide image classification. In Advances in Neural Information Processing Systems, volume 34, 2021.
+[13] Chetan L Srinidhi and Anne L Martel. Improving self-supervised learning with hardness-aware dynamic curriculum learning: an application to digital pathology. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 562-571, 2021.
+[14] Chetan L Srinidhi, Seung Wook Kim, Fu-Der Chen, and Anne L Martel. Self-supervised driven consistency training for annotation efficient histopathology image analysis. Medical Image Analysis, 75:102256, 2022.
+[15] Xueting Yan, Ishan Misra, Abhinav Gupta, Deepti Ghadiyaram, and Dhruv Mahajan. Clusterfit: improving generalization of visual representations. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 6509-6518, 2020.
+[16] Noriaki Hashimoto et al. Multi-scale domain-adversarial multiple-instance cnn for cancer subtype classification with unannotated histopathological images. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 3852-3861, 2020.
+[17] Hongrun Zhang et al. Dtdf-mil: double-tier feature distillation multiple instance learning for histopathology whole slide image classification. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 18802-18812, 2022.
+
+[18] Trung Vu, Phung Lai, Raviv Raich, Anh Pham, Xiaoli Z Fern, and UK Arvind Rao. A novel attribute-based symmetric multiple instance learning for histopathological image analysis. IEEE Transactions on Medical Imaging, 39(10):3125-3136, 2020.
+[19] Pierre Courtiol, Eric W Tramel, Marc Sanselme, and Gilles Wainrib. Classification and disease localization in histopathology using only global labels: a weakly-supervised approach. arXiv preprint arXiv:1802.02212, 2018.
+[20] Weixin Li and Nuno Vasconcelos. Multiple instance learning for soft bags via top instances. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 4277-4285, 2015.
+[21] Wei Shao, Tongxin Wang, Zhi Huang, Zhi Han, Jie Zhang, and Kun Huang. Weakly supervised deep ordinal cox model for survival prediction from whole-slide pathological images. IEEE Transactions on Medical Imaging, 40(12):3739-3747, 2021.
+[22] Nima Hatami, Mohsin Bilal, and Nasir Rajpoot. Deep multi-resolution dictionary learning for histopathology image analysis. arXiv preprint arXiv:2104.00669, 2021.
+[23] Hiroki Tokunaga, Yuki Teramoto, Akihiko Yoshizawa, and Ryoma Bise. Adaptive weighting multi-field-of-view cnn for semantic segmentation in pathology. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 12597-12606, 2019.
+[24] Naofumi Tomita, Behnaz Abdollahi, Jason Wei, Bing Ren, Arief Suriawinata, and Saeed Hassanpour. Attention-based deep neural networks for detection of cancerous and precancerous esophagus tissue on histopathological slides. JAMA Network Open, 2(11):e1914645-e1914645, 2019.
+[25] Nikhil Naik et al. Deep learning-enabled breast cancer hormonal receptor status determination from base-level h&E stains. Nature Communications, 11(1):1-8, 2020.
+[26] Shujun Wang et al. Rmdl: recalibrated multi-instance deep learning for whole slide gastric image classification. Medical Image Analysis, 58:101549, 2019.
+[27] Dmitrii Bychkov et al. Deep learning based tissue analysis predicts outcome in colorectal cancer. Scientific Reports, 8(1):1-11, 2018.
+[28] Richard J Chen et al. Multimodal co-attention transformer for survival prediction in gigapixel whole slide images. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 4015–4025, 2021.
+[29] Charlie Saillard et al. Predicting survival after hepatocellular carcinoma resection using deep learning on histological slides. Hepatology, 72(6):2000-2013, 2020.
+[30] Pooya Mobadersany et al. Predicting cancer outcomes from histology and genomics using convolutional networks. Proceedings of the National Academy of Sciences, 115(13):E2970-E2979, 2018.
+[31] Richard J Chen et al. Pathomic fusion: an integrated framework for fusing histopathology and genomic features for cancer diagnosis and prognosis. IEEE Transactions on Medical Imaging, 2020.
+[32] Shuai Jiang, George J Zanazzi, and Saeed Hassanpour. Predicting prognosis and idh mutation status for patients with lower-grade gliomas using whole slide images. Scientific Reports, 11(1):1-9, 2021.
+[33] David Tellez, Geert Litjens, Jeroen van der Laak, and Francesco Ciompi. Neural image compression for gigapixel histopathology image analysis. IEEE Transactions on Pattern Analysis and Machine Intelligence, 43(2):567-578, 2019.
+[34] Gang Xu et al. Camel: a weakly supervised learning framework for histopathology image segmentation. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 10682-10691, 2019.
+
+[35] Fahdi Kanavati et al. Weakly-supervised learning for lung carcinoma classification using deep learning. Scientific Reports, 10(1):1-11, 2020.
+[36] Chensu Xie et al. Beyond classification: whole slide tissue histopathology analysis by end-to-end part learning. In Medical Imaging with Deep Learning, pages 843-856, 2020.
+[37] Yash Sharma, Aman Shrivastava, Lubaina Ehsan, Christopher A Moskaluk, Sana Syed, and Donald Brown. Cluster-to-conquer: a framework for end-to-end multi-instance learning for whole slide image classification. In Medical Imaging with Deep Learning, pages 682-698, 2021.
+[38] Bolei Zhou, Aditya Khosla, Agata Lapedriza, Aude Oliva, and Antonio Torralba. Learning deep features for discriminative localization. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 2921-2929, 2016.
+[39] Ashish Vaswani et al. Attention is all you need. In Advances in Neural Information Processing Systems, volume 30, 2017.
+[40] Aaron Van den Oord, Yazhe Li, and Oriol Vinyals. Representation learning with contrastive predictive coding. arXiv preprint arXiv:1807.03748, 2018.
+[41] Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey Hinton. A simple framework for contrastive learning of visual representations. In International Conference on Machine Learning, pages 1597-1607, 2020.
+[42] John Fox and Sanford Weisberg. Cox proportional-hazards regression for survival data. An R and S-PLUS Companion to Applied Regression, 2002, 2002.
+[43] Daniel J Sargent et al. Disease-free survival versus overall survival as a primary end point for adjuvant colon cancer studies: individual patient data from 20,898 patients on 18 randomized trials. Journal of Clinical Oncology, 23(34):8664-8670, 2005.
+[44] Josep M Llovet, Andrew Burroughs, and Jordi Bruix. Hepatocellular carcinoma. The Lancet, 362(9399):1907-1917, 2003.
+[45] Ashish M Kamat et al. Bladder cancer. The Lancet, 388(10061):2796-2810, 2016.
+[46] Xinliang Zhu, Jiawen Yao, Feiyun Zhu, and Junzhou Huang. Wsisa: making survival prediction from whole slide histopathological images. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 7234-7242, 2017.
+[47] Ruoyu Li, Jiawen Yao, Xinliang Zhu, Yeqing Li, and Junzhou Huang. Graph cnn for survival analysis on whole slide pathological images. In International Conference on Medical Image Computing and Computer-Assisted Intervention, pages 174–182, 2018.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes] See the claimed contributions in Introduction and Abstract.
+(b) Did you describe the limitations of your work? [Yes] See Appendix.
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] This work has no negative societal impacts.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] We have read it and ensured that our paper conforms to them.
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] See Section 4.1, and the code is available at GitHub.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Section 4.2 and Section 4.5.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] We have used 5-fold cross-validation strategy to evaluate the proposed method and the results with mean and standard deviation are reported.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Section 4.2.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] See Section 4.1.
+(b) Did you mention the license of the assets? [Yes] See Section 4.1. The used datasets are publicly available.
+(c) Did you include any new assets either in the supplemental material or as a URL? [No]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [Yes] See Section 4.1. The used datasets are publicly available. The patient/participant consent has been obtained by the organizer.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes] See Section 4.1. The used datasets are publicly available, but the personally identifiable information is shielded.
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/images.zip b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..3bc22208cb1bf8fc6e04a232e30e4aaf0a9c6d4f
--- /dev/null
+++ b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a307909e5fcb4d824f1c11915176d8a4957bcaa1617e38449e7a94eac780b7f1
+size 700781
diff --git a/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/layout.json b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..aa225093872a4439a0b9aeaf10a852810c234556
--- /dev/null
+++ b/dualcurriculumcontrastivemultiinstancelearningforcancerprognosisanalysiswithwholeslideimages/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f2c4eb631f9014dc1c32a734b58e36400df8bd14b4965fe4c32595a2faf5bf6d
+size 541861
diff --git a/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/43b450fc-7716-499c-9a02-4761f33f68d2_content_list.json b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/43b450fc-7716-499c-9a02-4761f33f68d2_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..02a99b3efb8cd92ff7d92806b43f4343de4d47ca
--- /dev/null
+++ b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/43b450fc-7716-499c-9a02-4761f33f68d2_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2f798a2920967a6e40484baaec170a6d2ad414aaed6a940474fbf2d054a9f83d
+size 89290
diff --git a/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/43b450fc-7716-499c-9a02-4761f33f68d2_model.json b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/43b450fc-7716-499c-9a02-4761f33f68d2_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..ba05f1c630ee024f1d04a162be3258cd605daea8
--- /dev/null
+++ b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/43b450fc-7716-499c-9a02-4761f33f68d2_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e9a2902fca46be12d4d5b4f79e6d3bbf02c82d95bcf51bfefade357e67de4192
+size 115551
diff --git a/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/43b450fc-7716-499c-9a02-4761f33f68d2_origin.pdf b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/43b450fc-7716-499c-9a02-4761f33f68d2_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..2334abc07dee934fdbbe8f0fdeb340d8ccbf9658
--- /dev/null
+++ b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/43b450fc-7716-499c-9a02-4761f33f68d2_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c488b8519775a1083e6cf40557c64607a741817501b36468e52a30e5ea8fe5ba
+size 565959
diff --git a/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/full.md b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..50a17dc8ffcb97a937f15c1baec8bc8516e495af
--- /dev/null
+++ b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/full.md
@@ -0,0 +1,371 @@
+# Dual-discriminative Graph Neural Network for Imbalanced Graph-level Anomaly Detection
+
+Ge Zhang1 Zhenyu Yang1
+
+Jia Wu $^{1*}$ Jian Yang $^{1}$ Xue Shan $^{2}$ Hao Peng $^{3}$ Jianlin Su $^{4}$
+
+Chuan Zhou5 Quan Z. Sheng1 Leman Akoglu6 Charu C. Aggarwal7
+
+$^{1}$ Macquarie University $^{2}$ University of Wollongong $^{3}$ Beihang University
+
+$^{4}$ Zhuiyi Technology $^{5}$ AMSS, Chinese Academy of Sciences
+
+$^{6}$ Carnegie Mellon University $^{7}$ IBM T. J. Watson Research Center
+
+{ge.zhang5, zhenyu.yang3}@students.mq.edu.au,
+
+{jia.wu, jian.yang}@mq.edu.au, sxue@uow.edu.au,
+
+penghao@buaa.edu.cn, bojonesu@wezhuiyi.com, zhouchuan@amss.ac.cn,
+
+michael.sheng@mq.edu.au, lakoglu@andrew.cmu.edu, charu@us.ibm.com
+
+# Abstract
+
+Graph-level anomaly detection aims to distinguish anomalous graphs in a graph dataset from normal graphs. Anomalous graphs represent a very few but essential patterns in the real world. The anomalous property of a graph may be referable to its anomalous attributes of particular nodes and anomalous substructures that refer to a subset of nodes and edges in the graph. In addition, due to the imbalance nature of anomaly problem, anomalous information will be diluted by normal graphs with overwhelming quantities. Various anomaly notions in the attributes and/or substructures and the imbalance nature together make detecting anomalous graphs a non-trivial task. In this paper, we propose a graph neural network for graph-level anomaly detection, namely iGAD. Specifically, an anomalous graph attribute-aware graph convolution and an anomalous graph substructure-aware deep Random Walk Kernel (deep RWK) are welded into a graph neural network to achieve the dual-discriminative ability on anomalous attributes and substructures. Deep RWK in iGAD makes up for the deficiency of graph convolution in distinguishing structural information caused by the simple neighborhood aggregation mechanism. Further, we propose a Point Mutual Information (PMI)-based loss function to target the problems caused by imbalance distributions. PMI-based loss function enables iGAD to capture essential correlation between input graphs and their anomalous/normal properties. We evaluate iGAD on four real-world graph datasets. Extensive experiments demonstrate the superiority of iGAD on the graph-level anomaly detection task.
+
+# 1 Introduction
+
+Graphs have been used as an indispensable tool to describe relational data, such as chemical compounds, transport networks, and social networks. For instance, in a graph that models a chemical compound, nodes represent atoms and edges describe chemical bonds between atoms. Learning graphs to understand the world has been drawing considerable attention in recent years [5, 14, 15, 51]. Given a graph dataset containing a set of graphs, graph-level anomaly detection aims to identify graphs with anomalous information. Generally, these anomalous graphs with special characteristics or functions are the minority in a graph dataset. For example, among all antibody molecules, only
+
+a few of them exhibit anti-cancer activity on a specific type of cancer cell line [55]. Graph-level anomaly detection is a research topic of great practical value, say, it can support cancer drug discovery by identifying molecules with anti-cancer activity from other antibody molecules [48]. Also, the research can help to reveal pathogenic brain mechanisms by distinguishing the brain structures of patients with neurological disorders from healthy individuals [21].
+
+In practice, the attributes of particular nodes are a contributing factor to a graph's anomalous properties. For example, the hydrogen and oxygen atoms at the end of molecules are the key to discriminating between Alcohol and Alkane [45]. Graph substructures can be another factor for a graph's anomalous properties. For instance, pharmacophores composed of some particular substructures can induce molecular toxicity. These graph attributes and substructures that are essential for distinguishing anomalous graphs from normal graphs are regarded as anomalous attributes and anomalous substructures, respectively. Most existing graph mining methods, especially those graph convolution-based models which have achieved state-of-the-art performance [54, 59, 20, 3], focus on the aggregation of neighborhood-structured information. However, the anomalous structure information could be all possible substructures. In addition, anomalous attributes and substructures will be diluted by the information of normal graphs with overwhelming quantities, which is the imbalance nature of the anomaly problem. In summary, various anomaly notions in attributes and/or substructures and the imbalance nature make graph-level anomaly detection an important yet challenging problem.
+
+In this paper, we propose a dual-discriminative graph neural network for imbalanced Graph-level Anomaly Detection (iGAD). Specifically, iGAD investigates a novel anomalous attribute-aware graph convolution. The final node representation is the concatenation of the independent encoding on a node itself and the independent encoding on its neighborhoods from different hops. In this way, the attributes of center nodes can evolve independently over the graph convolution process and the anomalous attributes on particular nodes can get exposure. However, it is intractable to enable graph convolution to be aware of anomalous substructures. Due to the high dependence on neighborhood aggregation, graph convolution can only capture very limited substructures in graphs. Moreover, even the simple substructures such as triangles, graph convolution cannot count them in a graph [3]. RWK [47], as one type of Graph Kernels (GKs), learns graphs by exploring common random walk sequences among all input graphs, which naturally involves the comparison about diverse substructures in different graphs. To embed the information of anomalous substructures into graph representations, we propose to compare random walk sequences of input graphs against anomalous substructures. By modeling anomalous substructures as parameters, they became learnable and can get updated through back-propagation. We entitle this design anomalous substructure-aware deep RWK. In addition, we propose a new loss function to target the imbalance distribution caused by the great difference in the number of normal and anomalous graphs. The newly proposed loss function models the PMI between graphs and their normal/anomalous properties and enables iGAD to capture anomalous information from an imbalanced graph dataset. Welding three designs mentioned above into a graph neural network, the graph-level anomaly detection model iGAD is achieved. We conclude the contributions of iGAD as follows:
+
+- The anomalous attribute-aware graph convolution exposes anomalous attributes by keeping the independent evolution of center node's attributes.
+- Anomalous substructures are modeled as learnable parameters. Substructure-aware deep RWK embeds the information of anomalous substructures into graph representations by comparing the random walk sequences from input graphs and anomalous substructures.
+- The PMI-based loss function addresses issues brought by the imbalance nature of the anomaly problem and enables iGAD to learn anomalous graphs as a minority effectively.
+- Comprehensive experiments demonstrate the effectiveness of iGAD, which outperforms state-of-the-art graph convolution-based graph classification models and graph-level anomaly detection algorithms on four real-world graph datasets. The code is available at https://github.com/graph-level-anomalies/iGAD.
+
+# 2 Related Work
+
+Anomaly Detection. The task aims to identify anomalies that deviate from the majority of samples. Early anomaly detection algorithms use different metrics, such as distance-based [18] and density-
+
+based [7], to measure the deviation degree among samples to detect anomalies. For example, isolation forest-based algorithms [25, 26] identify anomalous by building the binary search tree structure to isolate samples. In addition, anomaly detection algorithms based on one-class classification [40, 39, 37, 63] and autoencoder [2, 64] have also been in the spotlight. For the graph-structured data, most graph anomaly detection algorithms dedicate to detect anomalies (e.g., anomalous nodes [44, 13, 58] and edges [36, 57]) in a single graph [1].
+
+The anomaly notions of graph-level anomalies are more diversified than those of node-level anomalies. For example, node-level anomaly detection methods usually regard nodes that betray network homophily1 as anomalies [44]. However, at the graph level, nodes that can achieve an anomalous graph go far beyond the nodes that do not meet homophily. Node-level anomaly detection methods identify anomaly nodes from a micro perspective (e.g., neighborhood structures) while identifying anomalous graphs needs learning graphs at the macro level. Employing node-level anomaly detection methods to detect graph-level anomalies could capture some anomalies, but only a small part. Moreover, graph-level anomaly detection algorithms need to consider anomaly notions related to graph substructures. Hence, it is necessary to propose anomaly detection methods that are specialized in detecting graph-level anomalies.
+
+Graph-level Anomaly Detection. To the best of our knowledge, there are only several preliminary research on graph-level anomaly detection. Zhao et al. [62] investigate a research question of "should we use the data for the graph classification task to evaluate graph-level anomaly detection models?", followed by which two graph-level anomaly detection algorithms [27, 35] combine Graph Neural Networks (GNNs) with knowledge distillation and one-class classification respectively to detect anomalous graphs.
+
+Graph-level anomaly detection can be regarded as a special case of graph classification. There is a huge gap between the number of graphs belonging to the normal class versus the anomalous ones. But, graph classification algorithms usually assume that the number of graphs in each class is close. GKs [47, 16, 42, 6, 41] used to be the mainstream graph classification methods. Generally, GKs use the kernel function to calculate kernel values (i.e., similarity) between pair-wised graphs. Afterward, an off-the-shelf classifier is applied to the graph similarity matrix to perform the classification task. Graph classification algorithms based on GKs cannot learn graph representations explicitly and be optimized in an end-to-end fashion. In recent years, graph mining practitioners pay more attention to GNNs [8, 11, 4, 38]. GNNs with spatial graph convolution [20, 46, 19] are summarized as message-passing framework (MPNNs) [17, 54, 59, 56, 52]. In general, MPNNs update the representation of each node by iteratively aggregating information coming from their neighbors. To represent a graph, MPNNs apply the readout function or pooling operation on node embeddings. The spatial graph convolution that mix the representation of nodes and their neighborhoods to represent nodes will smooth node attributes [61, 4]. In addition, [31, 28, 60] proved that spatial graph convolution has limited power in distinguishing graph structures. Performing message passing between subgraphs can enable spatial graph convolution to capture more graph structural information. But such a solution exponentially consumes memory resources and computation complexities [3].
+
+Graph classification methods mentioned above are likely to underfit anomalous graphs since they do not have any intrinsic mechanism to target the imbalanced distributions. In iGAD, a novel loss is presented for the imbalanced distributions by modeling PMI. In addition, different from existing graph-level anomaly methods [62, 27, 35] that employ the off-the-shelf MPNNs (e.g., GIN [54]) to represent graphs, iGAD can embed the information of anomalous attributes and substructures into graph representations.
+
+Imbalanced Learning. Learning data with imbalanced distribution can be divided into data- and algorithm-level approaches. The former alleviates the imbalanced distribution of the original data by either under-sampling the majority [49] or over-sampling the minority [9]. However, modifying the original distribution of data will bring a lot of drawbacks inevitably, such as over-fitting and discarding important samples. There are different types of approaches to address the issue at the algorithm level. The typical approaches include employing post-hoc correction [30], aligning data distribution, [53], and modifying the loss function [24, 22]. In the real-world application, considering the different consequences of false-positive identification (e.g., predicting an inactive chemical compound to be
+
+active) and false-negative identification (e.g., predicting a cancer patient as a healthy individual), the situation will be more complicated [33]. In this paper, iGAD introduces PMI to the cross-entropy loss function to solve this problem.
+
+# 3 Preliminaries
+
+Notations. A graph dataset consisting of $N$ graphs can be denoted as $\mathcal{G} = \{G_1, \dots, G_N\}$ , where $G_i = \{V_i, E_i\}$ is an unweighted and undirected graph in $\mathcal{G}$ , $V_i$ and $E_i$ are the node and the edge set, respectively. The topology of $G_i$ can be modeled as an adjacency matrix $\mathbf{A}_i \in \{0, 1\}^{n \times n}$ , where $\mathbf{A}_i(u, v) = 1$ if there is an edge between nodes $u$ and $v$ , otherwise $0$ . $\mathbf{A}_i$ does not consider the self-loop, $\mathbf{A}_i(u, u) = 0, \forall u \in V_i$ . We use $\mathbf{x}_u \in \mathbb{R}^c$ to denote the attribute vector of node $u \in V_i$ . $\mathbf{X}_i \in \mathbb{R}^{n \times c}$ is the attribute matrix of $G_i$ . $G_i' = \{V_i', E_i'\}$ can be regarded as a substructure in $G_i$ , iff $V_i' \subseteq V_i$ and $E_i' \subseteq E_i$ . $\mathcal{Y}$ is the label set of $\mathcal{G}$ . $G_i$ is labeled by $y_i \in \{0, 1\}$ , where 1 represents anomalous and 0 represents normal.
+
+Problem Definition. This paper concentrates on the supervised graph-level anomaly detection problem. Given the training set $\mathcal{T} = \{(G_1, y_1), (G_2, y_2), \ldots\}$ , we aim to train a model to predict the normal/anomalous properties of unseen graphs. $\mathcal{T}$ contains $N_1$ anomalous graphs and $N_0$ normal graphs ( $N_1 \ll N_0$ ). The imbalanced ratio of $\mathcal{T}$ is defined as $\delta$ ( $\delta = \frac{N_1}{N_0 + N_1}$ ).
+
+Spatial Graph Convolution. A graph convolution layer updates node representations by iteratively aggregating information coming from its one-hop neighborhood. The formulation is:
+
+$$
+\mathbf {h} ^ {(k + 1)} (u) = \sigma \left(f _ {\text {C o m b i n e}} \left(\mathbf {h} ^ {(k)} (u), f _ {\text {A G G R E G A T E}} \left(\{\mathbf {h} ^ {(k)} (v), v \in \mathcal {N} (u) \}\right)\right)\right), \mathbf {h} ^ {(0)} (u) = \mathbf {x} _ {u}, \tag {1}
+$$
+
+where $0 \leq k \leq K - 1$ , $\mathcal{N}(u)$ denotes the 1-hop neighborhood of node $u$ . $f_{\mathrm{AGGREGATE}}$ denotes how to aggregate neighbors of node $u$ , and $f_{\mathrm{COMBINE}}$ defines how to combine the immediate representations of node $u$ and its neighbors. $\sigma$ is the activation function. Generally, the final representation of the node $u$ is $\mathbf{h}^{(K)}(u)$ .
+
+Random Walk Kernels (RWK). RWK measures graph similarities by counting common random walk sequences among graphs. There are two graphs $G_{1} = \{V_{1}, E_{1}\}$ and $G_{2} = \{V_{2}, E_{2}\}$ . $G_{\times} = \{V_{\times}, E_{\times}\}$ denotes the direct product graph about $G_{1}$ and $G_{2}$ , where $V_{\times} = \{(u, u') | u \in V_{1}, u' \in V_{2}\}$ and $E_{\times} = \{((u, u'), (v, v')) | (u, v) \in E_{1}, (u', v') \in E_{2}\}$ . Performing random walking on $G_{\times}$ is equivalent to doing random walking on $G_{1}$ and $G_{2}$ simultaneously. The adjacency matrix of direct product graph $\mathbf{A}_{\times}$ can be obtained by the Kronecker product operation $\otimes$ on $\mathbf{A}_{1}$ and $\mathbf{A}_{2}$ , that is $\mathbf{A}_{\times} = \bar{\mathbf{A}}_{1} \otimes \mathbf{A}_{2}$ . The number of $l$ -length common walk sequences between $G_{1}$ and $G_{2}$ is $\kappa^{(l)}(G_{1}, G_{2}) = \mathbf{q}_{\times}^{\top}(\mathbf{A}_{\times})^{l}\mathbf{p}_{\times}$ , where $\mathbf{p}_{\times}$ and $\mathbf{q}_{\times}$ are the vector about the starting and stopping probabilities of random walks on $G_{\times}$ , respectively. The elements in $\mathbf{p}_{\times}$ and $\mathbf{q}_{\times}$ are all ones when there is no prior knowledge. Overall, the RWK about $G_{1}$ and $G_{2}$ can be defined as:
+
+$$
+\mathcal {K} \left(G _ {1}, G _ {2}\right) := \sum_ {l = 0} ^ {\infty} \kappa^ {(l)} \left(G _ {1}, G _ {2}\right). \tag {2}
+$$
+
+# 4 iGAD
+
+In this section, we will describe iGAD in detail (see Figure 1 for an illustration). iGAD contains three key designs: (1) anomalous graph attribute-aware graph convolution; (2) anomalous substructure-aware deep RWK; and (3) PMI-based loss function. The first two designs encode the anomalous information on graph attributes and substructures into graph embeddings. The loss function makes the training on iGAD not completely dominated by normal graphs.
+
+# 4.1 iGAD: Anomalous Attribute-aware Graph Convolution
+
+As aforementioned in Section 1, the attributes of particular nodes can achieve an anomalous graph. The graph convolution which iteratively updates node representations by performing feature transformation on the concatenated information about nodes and their neighborhoods will make node representations over-smoothed [61]. Under such a graph convolution mechanism, only limited anomalous information can be manifest in corresponding node representations. We argue that making each
+
+
+Figure 1: Taking learning the graph $G_{N}$ in a graph dataset as an example, we illustrate the framework of iGAD with three designs. I. Anomalous Attribute-aware Graph Convolution, which concatenates the independent encoding on nodes and their k-hop neighborhoods to represent nodes in $G_{N}$ . To obtain the graph representation $\mathbf{h}_{G_N}^{\mathrm{CONV}}$ , a readout function is applied to all node representations. II. The Anomalous Substructure-aware Deep RWK, which performs random walks on two learnable anomalous substructures (i.e., $S_{1}$ and $S_{2}$ ) and the input graph $G_{N}$ simultaneously. Deep RWK obtains $\mathbf{h}_{G_N}^{\mathrm{KER}}$ based on kernel values $\kappa^{(l)}(G_N,S_m), l = \{1,\dots,L\}$ , $m = \{1,\dots,M\}$ . III. The PMI-based Loss Function. iGAD concatenates $\mathbf{h}_{G_N}^{\mathrm{CONV}}$ and $\mathbf{h}_{G_N}^{\mathrm{KER}}$ to obtain the final graph representation $\mathbf{h}_{G_N}$ . Finally, a MLP is applied to $\mathbf{h}_{G_N}$ to predict $G_{N}$ . The model training is guided by a PMI-based loss function.
+
+node's attributes evolve independently over the graph convolution process is critical for capturing anomalous attributes. To achieve it, anomalous attribute-aware graph convolution concatenates the independent encoding on the node itself and the independent encoding on its $k$ -hop neighborhood $(1 \leq k \leq K)$ to represent each node in a graph. Formally,
+
+$$
+\mathbf {h} _ {u} = f _ {\text {C o m b i n e}} \left(\mathbf {h} ^ {(0)} (u), \mathbf {h} ^ {(1)} (u), \dots , \mathbf {h} ^ {(K)} (u)\right), \tag {3}
+$$
+
+where $\mathbf{h}_u$ is the final node representation of the node $u$ , $\mathbf{h}^{(k)}(u)$ is the representation of node $u$ 's $k$ -hop neighborhood, and $f_{\mathrm{COMBINE}}$ is the concatenation operation. $\mathbf{h}^{(0)}(u)$ and $\mathbf{h}^{(k)}(u)$ are formulated as:
+
+$$
+\mathbf {h} ^ {(0)} (u) = \operatorname {M L P} \left(\mathbf {x} _ {u}\right), \tag {4}
+$$
+
+and
+
+$$
+\mathbf {h} ^ {(k)} (u) = \sigma \left(\mathbf {A} _ {i} \mathbf {H} _ {i} ^ {(k - 1)} \mathbf {W} ^ {(k)}\right) _ {u}, \tag {5}
+$$
+
+respectively, where $\mathbf{H}_i^{(0)} = \mathbf{X}_i$ , MLP denotes a multi-layer perceptron, $\sigma$ represents the activation function, and $\mathbf{W}^{(k)}$ is the trainable weight matrix. To obtain the entire graph representation $\mathbf{h}_{G_i}^{\mathrm{CONV}}$ , we apply the permutation invariant Readout function $\mathcal{R}(\cdot)$ on all nodes in the graph $G_{i}$ . That is,
+
+$$
+\mathbf {h} _ {G _ {i}} ^ {\text {C O N V}} = \mathcal {R} \left(\left\{\mathbf {h} _ {u} \mid u \in V _ {i} \right\}\right), \tag {6}
+$$
+
+where $\mathcal{R}(\cdot)$ can be the sum-based or mean-based global pooling operation.
+
+# 4.2 iGAD: Anomalous Substructure-aware Deep RWK
+
+Generally, the neighborhood aggregation mechanism adopted by existing GNNs only depends on local neighborhood structures to perform message passing [60]), which leads to the deficiency of graph convolution in distinguishing substructures [3, 10]. To make iGAD to be aware of anomalous substructures, we resort to RWK that can explore diverse substructures through random walking sequences. There is a pioneering work [32] that represents graphs by calculating RWK values between input graphs and some substructures. It inspires us to embed information about anomalous substructures into graph representations by performing random walks in input graphs and learnable anomalous substructures simultaneously.
+
+We present an anomalous substructure-aware deep RWK, which models elements in the adjacency matrices of anomalous substructures as learnable parameters. Supposed that $\{S_1,\dots,S_M\}$ is the set
+
+of $M$ anomalous substructures, and the size of $S_{m}$ is $n^{\prime}$ . $\mathbf{P}_m\in \mathbb{R}^{n'\times n'}$ is the adjacency matrix of $S_{m}$ , where the matric element $\mathbf{P}_m(u',v')$ denotes the possibility that an edge exists between nodes $u^{\prime}$ and $v^{\prime}$ in $S_{m}$ . As the adjacency matrix is symmetric, $\mathbf{P}_m$ contains $\frac{n'(n' - 1)}{2}$ parameters. Referring to Eq. 2 and supposing that the starting and the stopping possibilities on each node are all ones, the number of $l$ -length common random walk sequences between the input graph $G_{i}$ and the anomalous substructure $S_{m}$ is:
+
+$$
+\kappa^ {(l)} \left(G _ {i}, S _ {m}\right) = \mathbf {1} ^ {\mathsf {T}} \left(\mathbf {A} _ {i} \otimes \mathbf {P} _ {m}\right) ^ {l} \mathbf {1} = \sum_ {i} \sum_ {j} \left[ \left(\mathbf {P} _ {m}\right) ^ {l} \mathbf {E} \left(\mathbf {A} _ {i}\right) ^ {l} \right] _ {i, j}, \tag {7}
+$$
+
+where $\mathbf{1} \in \mathbb{R}^{n'n}$ is a column vector full of 1, and $\mathbf{E} \in \mathbb{R}^{n' \times n}$ is a matrix in which all elements are 1. The proof of Eq. 7 can be found in Appendix A.1. RWK with infinite random walk lengths will often meet the halting issue [43]. Therefore, iGAD only considers the random walk length from 1 to $L$ . As the size of anomalous substructures $(n')$ is small, optimizing $(\mathbf{P}_m)^l$ is not necessary. The adjacency matrix $\mathbf{A}_i$ is sparse, and we compute $(\mathbf{A}_i)^l$ by the sparse matrix multiplication in PyTorch [34]. That is $(\mathbf{A}_i^s)^l = \mathbf{A}_i^s (\mathbf{A}_i^s \dots (\mathbf{A}_i^s (\mathbf{A}_i))\dots)$ , where $\mathbf{A}_i^s$ is the sparse version of $\mathbf{A}_i$ . Afterward, deep RWK values $\kappa^{(l)}(G_i, S_m)$ about $G_i$ and $S_m$ , $m = \{1,..,M\}$ , $l = \{1,..,L\}$ will be assembled into a vector $\mathbf{a}_{G_i}$ . That is,
+
+$$
+\mathbf {a} _ {G _ {i}} = \left(\kappa^ {(1)} \left(G _ {i}, S _ {1}\right), \dots , \kappa^ {(1)} \left(G _ {i}, S _ {M}\right); \dots ; \kappa^ {(L)} \left(G _ {i}, S _ {1}\right), \dots , \kappa^ {(L)} \left(G _ {i}, S _ {M}\right)\right), \tag {8}
+$$
+
+where $\mathbf{a}_{G_i} \in \mathbb{R}^{ML}$ . The graph representation $\mathbf{h}_{G_i}^{\mathrm{KER}}$ based on deep RWK is:
+
+$$
+\mathbf {h} _ {G _ {i}} ^ {\mathrm {K E R}} = \operatorname {M L P} \left(\mathbf {a} _ {G _ {i}}\right). \tag {9}
+$$
+
+The final graph representation $\mathbf{h}_{G_i}$ for $G_{i} \in \mathcal{G}$ can be obtained by concatenating $\mathbf{h}_{G_i}^{\mathrm{CONV}}$ and $\mathbf{h}_{G_i}^{\mathrm{KER}}$ together. The anomalous attribute-aware graph convolution and anomalous substructure-aware deep RWK are welded into a graph neural network together through $\mathbf{h}_{G_i}$ .
+
+# 4.3 iGAD: PMI-based Loss Function
+
+The number of normal graphs is much more than that of anomalous graphs. Under the imbalance nature of the anomaly problem, normal graphs will dominate model training. Targeting this issue, we propose a new loss function that can model the PMI between input graphs and their anomalous/normal properties. Specifically, we use $f(\mathcal{G};\Theta)$ to denote the proposed model iGAD, where $\Theta$ represents model parameters. Modeling the PMI between the input graph $G_{i}$ and its anomalous/normal properties can be formulated as:
+
+$$
+f _ {y _ {i}} \left(G _ {i}; \Theta\right) \sim \log \frac {P _ {\Theta} \left(G _ {i} , y _ {i}\right)}{P \left(G _ {i}\right) P \left(y _ {i}\right)}, \tag {10}
+$$
+
+where the right part represents the PMI between $G_{i}$ and $y_{i}$ , $P(y_{i})$ is the proportion of anomalous graphs or normal graphs in the training set $\mathcal{T}$ . Compared with most existing loss functions, especially the loss function that models the conditional distribution about $y_{i}$ given $G_{i}$ (i.e., $f_{y_i}(G_i;\Theta)\sim P_\Theta (y_i|G_i)$ ), PMI enables iGAD to give priority to learning the information that reveals the essential correlation between graphs and their labels. Eq. 10 can be reformatted as:
+
+$$
+\log P _ {\Theta} \left(y _ {i} \mid G _ {i}\right) \sim f _ {y _ {i}} \left(G _ {i}, \Theta\right) + \log P \left(y _ {i}\right). \tag {11}
+$$
+
+After softmax normalization, the distribution of $y_{i}$ given $G_{i}$ is formulated as:
+
+$$
+P _ {\Theta} \left(y _ {i} \mid G _ {i}\right) = \frac {e ^ {f _ {y _ {i}} \left(G _ {i} ; \Theta\right) + \log P \left(y _ {i}\right)}}{\sum_ {y _ {i}} e ^ {f _ {y _ {i}} \left(G _ {i} ; \Theta\right) + \log P \left(y _ {i}\right)}}. \tag {12}
+$$
+
+Incorporating $P_{\Theta}(y_i|G_i)$ in to the framework of the cross-entropy loss function, we can obtain the PMI-based loss function $\mathcal{L}$ :
+
+$$
+\mathcal {L} = \frac {1}{N} \sum_ {i = 1} ^ {N} - \log P _ {\Theta} \left(y _ {i} \mid G _ {i}\right). \tag {13}
+$$
+
+Specifically, iGAD predict the graph $G_{i}$ :
+
+Table 1: Statistical information of four real-world datasets. We regard the one-hot encoding of node labels (e.g., carbon (C), nitrogen (N), oxygen (O)) as node attributes.
+
+| DATASET | #GRAPHS (N) | #ANOMALOUS GRAPHS | δ | AVG. #NODES (AVG. n) | AVG. #EDGES (AVG. |E|) | # NODE LABELS (c) | TUMOR |
| SW-620 | 40,532 | 2,411 | 5.95% | 26.05 | 28.08 | 65 | COLON |
| MOLT-4 | 39,765 | 2,904 | 7.90% | 26.07 | 28.13 | 64 | LEUKEMIA |
| MCF-7 | 27,770 | 2,293 | 8.26% | 26.39 | 28.52 | 46 | BREAST |
| PC-3 | 27,509 | 1,568 | 5.70% | 26.35 | 28.49 | 45 | PROSTATE |
+
+$$
+y _ {i} ^ {*} = \left\{ \begin{array}{l l} \underset {y _ {i}} {\operatorname {a r g m a x}} f _ {y _ {i}} \left(G _ {i}; \Theta\right) + \log P \left(y _ {i}\right), & \text {d u r i n g t r a i n i n g .} \\ \underset {y _ {i}} {\operatorname {a r g m a x}} f _ {y _ {i}} ^ {*} \left(G _ {i}; \Theta\right), & \text {d u r i n g t e s t i n g .} \end{array} \right. \tag {14}
+$$
+
+The reason that we use $\operatorname{argmax}_{y_i} f_{y_i}^*(G_i; \Theta)$ to predict a graph in test time can be found in Appendix A.2.
+
+Many other loss functions target the difficulties brought by imbalanced distributions, such as the cost-sensitive loss function that assigns or learns different weights to the majority and the minority samples [29, 50, 12]. Compared with them, the PMI-based loss function does not introduce any new parameters that need to be carefully tuned. It comes in the form of the most widely used cross-entropy loss function and gives prediction results that can achieve maximized PMI between inputs and predictions.
+
+# 4.4 Algorithm Description & Computational Complexity
+
+The pseudocode of iGAD is included in Algorithm 1 in Appendix A.1. We divide graphs in $\mathcal{G}$ into different mini-batches to train iGAD [23]. But for illustrating how iGAD predicts a graph more clearly, the batch size is set as 1 in Algorithm 1. Given the training set, we initialize anomalous substructures and other parameters (Line 1 in Algorithm 1) and calculate the proportion of normal and anomalous graphs (Line 2). For each graph, iGAD learns its graph representation (Lines 3 to 15). Based on the graph representation, a MLP equipped with the PMI-based loss function gives predictions to graphs (Lines 16 and 17). At the back-propagation stage, anomalous substructures and other parameters will get updated. At each epoch, deep RWK performs random walking on input graphs and anomalous substructures that get updated during the previous epoch.
+
+Lemma 1 The computational complexity of iGAD is $\mathcal{O}(n + |E|)$ , where $n$ and $|E|$ are the number of nodes and edges, respectively. (The detailed analysis can be found in Appendix A.3).
+
+# 5 Experiments
+
+In this section, we conduct a series of experiments to study the performance of iGAD on the graph-level anomaly detection task. Specifically, we investigate the following six questions:
+
+Q1. How about the performance of iGAD on the graph-level anomaly detection task?
+Q2. Does iGAD benefit from the PMI-based loss function?
+Q3. How about the performance of the anomalous graph attribute-aware graph convolution in iGAD?
+Q4. How about the performance of iGAD when it utilizes pre-defined anomalous substructures?
+Q5. Can the anomalous substructure-aware deep RWK in iGAD learn anomalous substructures?
+Q6. How does the maximum length of random walk sequences affect the performance of iGAD?
+
+The questions from Q2 to Q4 can be regarded as the ablation study on our three main design elements, they are: (a). cross-entropy loss function versus the proposed PMI-based loss function; (b). general graph convolution versus the proposed graph convolution; (c). RWK versus the proposed deep RWK.
+
+Table 2: Graph-level anomaly detection performance (\%) of five graph classification methods, their GAD variants, iGAD, and iGAD's two variants on four datasets. The value behind $\pm$ denotes the standard deviation (mean $\pm$ std) over different data splits. The best result is highlighted in gray. The description about evaluation metrics AUC, Recall, Recall(A), and $F$ -score is in Appendix B.1.
+
+| DATA | METRICS | GCN | GCN-GAD | GIN | GIN-GAD | DGCNN | DGCNN-GAD | SOPOOL | SOPOOL-GAD | RWGNN | RWGNN-GAD | IGAD-1 | IGAD-2 | IGAD |
| SW-620 | AUC | 74.90±0.74 | 76.48±1.51 | 78.61±2.85 | 76.42±2.80 | 80.06±0.42 | 79.36±1.28 | 75.51±5.06 | 76.89±2.07 | 73.37±0.36 | 74.92±1.97 | 85.40±0.93 | 85.77±0.72 | 85.82±0.69 |
| RECALL | 51.79±0.47 | 69.65±1.39 | 56.62±3.97 | 70.38±2.18 | 56.02±1.16 | 72.65±0.63 | 56.01±2.29 | 69.97±1.69 | 51.43±0.87 | 68.32±1.76 | 78.60±0.97 | 79.08±1.31 | 79.64±0.83 |
| RECALL(A) | 3.78±0.95 | 67.26±1.88 | 14.40±8.57 | 64.11±6.83 | 12.74±2.41 | 67.84±1.78 | 13.28±5.05 | 62.32±6.23 | 3.11±1.82 | 63.82±5.40 | 74.23±3.66 | 73.24±2.52 | 74.27±2.99 |
| F-SCORE | 52.00±0.87 | 52.44±1.32 | 58.47±5.43 | 55.00±2.82 | 58.73±1.64 | 56.11±0.89 | 58.11±2.86 | 55.63±4.78 | 51.31±1.62 | 52.47±3.17 | 61.82±2.22 | 63.36±1.58 | 63.68±1.56 |
| MOT-4 | AUC | 72.55±0.52 | 72.88±0.99 | 75.86±1.60 | 75.43±2.82 | 76.50±0.60 | 77.43±0.73 | 75.11±0.97 | 74.50±1.69 | 71.30±1.23 | 71.51±0.70 | 81.59±1.10 | 82.73±1.12 | 83.59±1.07 |
| RECALL | 51.26±0.54 | 66.84±0.66 | 56.87±6.98 | 69.40±2.47 | 55.35±1.27 | 70.14±0.69 | 55,31±3.74 | 69.12±1.50 | 51.39±1.41 | 65.84±1.27 | 74.97±1.61 | 76.33±1.18 | 76.82±0.82 |
| RECALL(A) | 2.74±1.12 | 67.32±3.04 | 17.71±9.02 | 64.36±7.14 | 11.69±2.87 | 65.76±1.97 | 12.23±9.34 | 63.44±6.55 | 3.18±3.21 | 61.24±3.89 | 68.18±2.72 | 70.54±4.28 | 72.10±2.47 |
| F-SCORE | 50.53±1.03 | 51.25±1.50 | 55.43±6.52 | 55.86±2.01 | 57.33±1.76 | 56.22±1.32 | 56.20±3.64 | 56.02±3.17 | 50.67±2.64 | 52.69±2.60 | 62.22±0.48 | 63.12±1.31 | 63.30±1.17 |
| PC-3 | AUC | 75.36±2.13 | 75.62±1.22 | 78.44±1.67 | 76.95±1.74 | 79.15±1.84 | 78.90±1.70 | 69.37±1.53 | 78.24±1.97 | 76.27±0.86 | 76.10±1.92 | 85.44±1.20 | 85.83±1.02 | 86.04±1.14 |
| RECALL | 50.72±0.59 | 69.46±1.57 | 57.43±4.61 | 71.49±1.27 | 52.88±0.28 | 72.53±1.40 | 56.78±3.79 | 71.44±1.53 | 51.02±1.53 | 69.90±1.74 | 78.31±0.76 | 79.94±0.64 | 79.59±0.41 |
| RECALL(A) | 1.53±1.26 | 65.29±5.69 | 16.31±10.47 | 68.22±6.76 | 6.05±0.57 | 70.06±5.19 | 15.67±8.98 | 69.60±9.54 | 2.17±3.26 | 66.62±3.03 | 70.45±3.29 | 75.35±0.74 | 75.69±1.64 |
| F-SCORE | 49.99±1.63 | 52.76±1.11 | 59.07±4.15 | 54.09±3.04 | 54.01±0.48 | 54.46±1.70 | 57.80±3.74 | 51.76±5.27 | 50.44±2.76 | 52.72±1.54 | 61.17±2.43 | 62.97±1.40 | 63.50±0.73 |
| MCF-7 | AUC | 72.70±1.05 | 73.89±0.99 | 69.54±1.15 | 75.90±1.44 | 76.41±0.81 | 76.83±0.48 | 75.64±2.17 | 76.69±1.33 | 70.47±1.26 | 73.25±1.56 | 83.02±0.46 | 83.49±1.03 | 83.22±0.64 |
| RECALL | 50.42±0.28 | 67.14±1.13 | 57.08±3.82 | 69.40±2.32 | 55.11±1.11 | 70.74±0.63 | 56.82±3.57 | 68.88±1.07 | 52.09±1.06 | 66.99±1.91 | 75.80±0.81 | 76.81±0.97 | 76.77±0.47 |
| RECALL(A) | 0.96±0.63 | 61.79±2.14 | 16.69±9.92 | 59.48±10.14 | 11.07±2.33 | 69.37±3.05 | 15.34±8.20 | 63.92±7.30 | 4.97±5.24 | 57.73±11.16 | 67.67±2.54 | 71.59±2.19 | 73.38±3.59 |
| F-SCORE | 48.76±0.59 | 53.37±1.89 | 58.27±3.20 | 58.71±2.53 | 56.99±1.70 | 55.74±1.54 | 56.82±3.57 | 54.82±3.00 | 51.65±3.46 | 56.06±2.93 | 61.56±1.89 | 63.75±1.18 | 64.70±2.58 |
+
+# 5.1 Experimental Setup
+
+Datasets. SW-610, MOLT-4, PC-3, and MCF-7 are four real-world graph datasets. These datasets are collected from PubChem $^2$ , which records a tremendous amount of chemical compounds and their anti-cancer activity testing results ("active" or "inactive") on different types of cancer cell lines. We regard the chemical compounds with the outcome "active" as anomalous, and "inactive" as normal. For example, the graph dataset SW-620 records 40,532 chemical formulas and their anti-cancer activity testing results on the colon cancer cell line. Chemical compounds that exhibit antibody activity against colon cancer are labeled as anomalous graphs, otherwise normal graphs. The statistical information about these four datasets is shown in Table 1.
+
+Baselines & Experimental Settings. To investigate Q1, we compare iGAD with the following baseline models: (1) GCN[20] + Readout function (abbreviated GCN) and GIN [54]. These two algorithms employ spatial graph convolution to learn node representation and apply the readout function to node representations to obtain graph representations and classify graphs; (2) DGCNN [59] and SOPool [52]. In these two models, spatial graph convolution and the graph pooling operation are employed to downsize graphs and complete the graph classification task; (3) RWGNN [32]. It employs
+
+Table 3: The performance $(\%)$ of two graphlevel anomaly detection methods (i.e., GLocalKD and OCGTL) and iGAD w.r.t. AUC.
+
+| DATA | GLOCALKD | OCGTL | IGAD |
| Sw-620 | 64.14±0.92 | 67.69±0.02 | 85.82±0.69 |
| MOLT-4 | 61.43±1.26 | 57.42±2.38 | 83.59±1.07 |
| PC-3 | 64.79±1.22 | 68.42±1.73 | 86.04±1.14 |
| MCF-7 | 61.43±1.26 | 64.92±1.92 | 83.22±0.64 |
+
+random walk sequences to represent graphs and then classify graphs based on graph representations. All the above baselines are supervised and use the cross-entropy loss function; (4) The graph-level anomaly detection methods GLocalKD [27] and OCGTL [35]. The former adopts random distillation to detect the locally- and globally-anomalous graphs and the latter combines the one-class classification and graph transformation learning to identify anomalous graphs. Both of them only use normal graphs to train models. They learn anomaly scores for graphs to measure each graph' anomaly degree and do not provide any criterion to determine whether a graph is anomalous or not.
+
+For the fairness of experiments and to answer Q2, we also compare iGAD with GCN-GAD, GINGAD, DGCNN-GAD, SOPool-GAD, and RWGNN-GAD. These algorithms are the graph anomaly detection (GAD) variants of GCN, GIN, DGCNN, SOPool, and RWGNN. We replace the cross-entropy loss in these algorithms with the proposed PMI-based loss function. To answer Q3, we consider a variant of iGAD —iGAD-1 that only utilizes the anomalous graph attribute-aware graph convolution to represent graphs and detect anomalous graphs. To answer Q4, we consider the other variant named iGAD-2 in which the random walking performs on input graphs and pre-defined anomalous graph substructures simultaneously. Specifically, we use 3-star, triangle, tailed triangle,
+
+
+
+
+
+
+
+
+
+
+Figure 3: The impact of different maximum random walk length $L$ on the performance of iGAD. The first row reports the performance of iGAD under the setting $M = 5$ and $n' = 8$ . The second row reports the performance of iGAD under the setting $M = 5$ and $n' = 10$ .
+
+
+
+
+
+
+
+and 4-cycle graphlets as pre-defined graph anomalous substructures (see Figure 4 in Appendix B for these substructures). Information about parameter setting and algorithm implementation can be found in Appendix B.1. We report experimental results under 5-fold cross-validation.
+
+# 5.2 Experimental Results
+
+This section answers Q1 - Q6 by A1 - A6, respectively. We put extra experiments in Appendix B.2.
+
+A1. iGAD demonstrates superior performance in identifying graph-level anomalies. Observed from Table 2: 1) Compared with the graph classification baselines GCN, GIN, DGCNN, SOPool, and RWGNN, iGAD demonstrates significant advantages on four real world datasets in terms of all evaluation metrics; 2) iGAD also beats the above baselines' GAD variants, GCN-GAD, GIN-GAD, DGCNN-GAD, SOPool-GAD, and RWGNN-GAD in terms of all evaluation metrics. In addition, as shown in Table 3, iGAD outperforms two graph-level anomaly detection methods GLocalKD and OCGTL concerning AUC.
+
+
+
+A2. PMI-based loss function can capture essential correlations between graphs and their anomalous/normal properties even if the data distribution is imbalanced. As shown in Table 2, compared with GNNs with the cross-entropy loss function (GCN, GIN, DGCNN, SOPOOL, and RWGNN), their GAD variants equipped with the newly
+proposed PMI-based loss function (GCN-GAD, GIN-GAD, DGCNN-GAD, SOPOOL-GAD, and RWGNN-GAD) witness a significant performance improvement regarding Recall and $\text{Recall}(A)$ over all datasets. For example, the value of $\text{Recall}$ and $\text{Recall}(A)$ achieved by DGCNN over the dataset SW-620 are $56.02 \pm 1.16$ and $12.74 \pm 2.41$ respectively. In contrast, $72.65 \pm 0.63$ and $67.84 \pm 1.78$ are reported by DGCNN-GAD. PMI-based loss function can greatly improve GNN-based graph classification model in datasets with highly imbalanced class distributions.
+A3. The anomalous attribute-aware graph convolution can embed anomalous attributes into graph representations and improve graph-level anomaly detection. As shown in Table 2, iGAD-1 significantly outperforms all baseline algorithms on four graph datasets in terms of AUC, Recall, and $F$ -score.
+
+Concerning $Recall(A)$ , on the dataset MCF-7, iGAD-1 has a little performance degradation compared with DGCNN-GAD. Specifically, DGCNN-GAD achieves $69.37_{\pm 3.05}$ on MCF-7, while iGAD-1 gets $67.67_{\pm 2.54}$ . But iGAD-1 beats DGCNN-GAD on other datasets in terms of $Recall(A)$ .
+
+A4. iGAD is also effective when it is equipped with pre-defined anomalous substructures. As shown in Table 2, iGAD-2 demonstrates significant advantages against all baseline models. Moreover, iGAD-2 also beats iGAD-1 concerning all metrics over datasets MOLT-4, PC-3, and MCF-7. iGAD-2 does not outperform than iGAD on all datasets concerning AUC, Recall(A), and $F$ -score. But, on PC-3 and MCF-7, iGAD-2 has a slight lead over iGAD regarding Recall. The experiment results demonstrate that, in most cases, the performance of iGAD equipped with a deep RWK is better than iGAD-2 using pre-defined anomalous substructures and algorithms that do not consider anomalous substructures. Based on the above analysis, we can conclude that comparing the random walk sequences between the input graph and pre-defined substructure can improve graph-level anomaly detection to a certain extent, but the algorithm that can automatically learn the anomalous substructures is better.
+
+A5. The anomalous substructures learned by iGAD are demonstrated in Figure 2. We can observe that anomalous graph substructures on four datasets are composed of the triangle, the tailed triangle, and the 4-cycle graphlets. It explains why iGAD-2 can achieve competitive results compared with iGAD (as shown in Table 2 and A4). We can draw a preliminary conclusion that the graph substructures having the triangle, the tailed triangle, and the 4-cycle graphlets are important for distinguishing anomalous graphs from normal graphs on these four graph datasets.
+
+A6. The performance of iGAD under different maximum random walk lengths $L$ is shown in Figure 3. Under the setting that iGAD with 5 anomalous substructures and each of substructures has 8 nodes, on these four graph datasets SW-620, MOLT-4, PC-3, and MCF-7, iGAD can achieve the highest $F$ -score value when the maximum random walk length ranges from 4 to 8. In addition, when each anomalous substructure contains 10 nodes, iGAD can reach the best $F$ -score score at the maximum random walk length from 5 to 9. The results verify that appropriately increasing the maximum length of random walking can improve the performance of iGAD since more much longer random walk sequences can capture more graph structure information.
+
+Finally, we discuss the limitations of the proposed graph-level anomaly detection model iGAD. In practice, the nodes and/or substructures at a particular position in a graph can also be the reason for the graph's anomalous properties. For example, an Alcohol compound can be obtained by replacing the hydrogen atom at the end of the Alkane compound with a hydroxy group (i.e., -OH). But, iGAD cannot capture the position information of nodes and substructures in graphs. In addition, iGAD is a supervised algorithm. It may not be able to achieve superior performance in identifying the graph-level anomalies that follow the anomaly distributions that have never been exposed in the training graph anomalies. In the future, we will propose specific solutions to this problem.
+
+# 6 Conclusion
+
+This paper proposes a method named iGAD for graph-level anomaly detection. We highlight the challenges brought by imbalanced distributions and various anomaly notions in graph attributes and substructures. In addition, the significant differences between detecting anomalous graphs in a graph dataset and identifying anomalous nodes in a single graph are also introduced in detail. iGAD treats graph-level anomaly detection as a special case of graph classification and learns binary labels for graphs. In iGAD, the anomalous attribute-aware graph convolution and anomalous substructure-aware deep RWK embed graph-level anomaly information into graph representations. A PMI-based loss function guides iGAD to identify anomalous samples from a large number of normal samples. We do extensive experiments on four real-world graph datasets, and iGAD achieves superior performance on the graph-level anomaly detection task.
+
+# Acknowledge
+
+We greatly appreciate the constructive and insightful comments from reviewers. This work is funded by the Australian Research Council Discovery Early Career Researcher Award (ARC DECRA) Project (No. DE200100964) and the NSFC (No. 61872360).
+
+# References
+
+[1] Leman Akoglu, Hanghang Tong, and Danai Koutra. Graph based anomaly detection and description: a survey. Data Min Knowl Discov, 29(3):626-688, 2015.
+[2] Jinwon An and Sungzoon Cho. Variational autoencoder based anomaly detection using reconstruction probability. *Special Lecture on IE*, 2(1):1-18, 2015.
+[3] Muhammet Balcilar, Pierre Héroux, Benoit Gauzere, Pascal Vasseur, Sébastien Adam, and Paul Honeine. Breaking the limits of message passing graph neural networks. In ICML, pages 599–608, 2021.
+[4] Muhammet Balcilar, Guillaume Renton, Pierre Héroux, Benoit Gaizère, Sébastien Adam, and Paul Honeine. Analyzing the expressive power of graph neural networks in a spectral perspective. In ICLR, 2021.
+[5] John Adrian Bondy, Uppaluri Siva Ramachandra Murty, et al. J. Graph Theory Appl., volume 290. Macmillan London, 1976.
+[6] Karsten M Borgwardt and Hans-Peter Kriegel. Shortest-path kernels on graphs. In ICDM, pages 74-81. IEEE, 2005.
+[7] Markus M Breunig, Hans-Peter Kriegel, Raymond T Ng, and Jorg Sander. Lof: identifying density-based local outliers. In SIGMOD, pages 93-104, 2000.
+[8] Joan Bruna, Wojciech Zaremba, Arthur Szlam, and Yann LeCun. Spectral networks and locally connected networks on graphs. arXiv preprint arXiv:1312.6203, 2013.
+[9] Jonathon Byrd and Zachary Lipton. What is the effect of importance weighting in deep learning? In ICML, pages 872-881, 2019.
+[10] Pim de Haan, Taco S Cohen, and Max Welling. Natural graph networks. In NeurIPS, pages 3636-3646, 2020.
+[11] Michael Defferrard, Xavier Bresson, and Pierre Vandergheynst. Convolutional neural networks on graphs with fast localized spectral filtering. In NeurIPS, pages 3837-3845, 2016.
+[12] Jacek P Dmochowski, Paul Sajda, and Lucas C Parra. Maximum likelihood in cost-sensitive learning: Model specification, approximations, and upper bounds. J. Mach. Learn. Res., 11(12), 2010.
+[13] Yingtong Dou, Zhiwei Liu, Li Sun, Yutong Deng, Hao Peng, and Philip S Yu. Enhancing graph neural network-based fraud detectors against camouflaged fraudsters. In CIKM, pages 315-324, 2020.
+[14] David Duvenaud, Dougal Maclaurin, Jorge Aguilera-Iparraguirre, et al. Convolutional networks on graphs for learning molecular fingerprints. In NeurIPS, pages 2224-2232, 2015.
+[15] Alex Fout, Jonathon Byrd, Basir Shariat, et al. Protein interface prediction using graph convolutional networks. In NeurIPS, pages 6530-6539, 2017.
+[16] Thomas Gartner, Peter Flach, and Stefan Wrobel. On graph kernels: Hardness results and efficient alternatives. In Learning theory and kernel machines, pages 129-143. Springer, 2003.
+[17] Justin Gilmer, Samuel S Schoenholz, Patrick F Riley, Oriol Vinyals, and George E Dahl. Neural message passing for quantum chemistry. In ICML, pages 1263-1272, 2017.
+[18] Markus Goldstein and Seiichi Uchida. A comparative evaluation of unsupervised anomaly detection algorithms for multivariate data. PloS one, 11(4):e0152173, 2016.
+[19] Will Hamilton, Zhitao Ying, and Jure Leskovec. Inductive representation learning on large graphs. In NeurIPS, pages 1024–1034, 2017.
+[20] Thomas N. Kipf and Max Welling. Semi-supervised classification with graph convolutional networks. In ICLR, 2017.
+[21] Tommaso Lanciano, Francesco Bonchi, and Aristides Gionis. Explainable classification of brain networks via contrast subgraphs. In KDD, pages 3308-3318, 2020.
+[22] Buyu Li, Yu Liu, and Xiaogang Wang. Gradient harmonized single-stage detector. In AAAI, pages 8577-8584, 2019.
+[23] Mu Li, Tong Zhang, Yuqiang Chen, and Alexander J Smola. Efficient mini-batch training for stochastic optimization. In KDD, pages 661-670, 2014.
+
+[24] Tsung-Yi Lin, Priya Goyal, Ross Girshick, Kaiming He, and Piotr Dólar. Focal loss for dense object detection. In CVPR, pages 2980-2988, 2017.
+[25] Fei Tony Liu, Kai Ming Ting, and Zhi-Hua Zhou. Isolation forest. In ICDM, pages 413-422. IEEE, 2008.
+[26] Fei Tony Liu, Kai Ming Ting, and Zhi-Hua Zhou. Isolation-based anomaly detection. ACM Trans. Knowl. Discov. Data, 6(1):1-39, 2012.
+[27] Rongrong Ma, Guansong Pang, Ling Chen, and Anton van den Hengel. Deep graph-level anomaly detection by glocal knowledge distillation. In WSDM, pages 704-714, 2022.
+[28] Haggai Maron, Heli Ben-Hamu, Hadar Serviansky, and Yaron Lipman. Provably powerful graph networks. In NeurIPS, pages 2153-2164, 2019.
+[29] Hamed Masnadi-Shirazi and Nuno Vasconcelos. Risk minimization, probability elicitation, and cost-sensitive svms. In ICML, pages 759-766, 2010.
+[30] Aditya Krishna Menon, Sadeep Jayasumana, Ankit Singh Rawat, Himanshu Jain, Andreas Veit, and Sanjiv Kumar. Long-tail learning via logit adjustment. In ICLR, 2020.
+[31] Christopher Morris, Martin Ritzert, Matthias Fey, William L Hamilton, Jan Eric Lenssen, Gaurav Rattan, and Martin Grohe. Weisfeiler and leman go neural: Higher-order graph neural networks. In AAAI, pages 4602-4609, 2019.
+[32] Giannis Nikolentzos and Michalis Vazirgiannis. Random walk graph neural networks. In NeurIPS, pages 16211-16222, 2020.
+[33] Shirui Pan, Jia Wu, and Xingquan Zhu. Cogboost: Boosting for fast cost-sensitive graph classification. IEEE Trans. Knowl. Data Eng., 27(11):2933-2946, 2015.
+[34] Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, et al. Pytorch: An imperative style, high-performance deep learning library. NeurIPS, 32, 2019.
+[35] Chen Qiu, Marius Kloft, Stephan Mandt, and Maja Rudolph. Raising the bar in graph-level anomaly detection. In *IJCAI*, pages 2196–2203, 2022.
+[36] Stephen Ranshous, Steve Harenberg, Kshitij Sharma, and Nagiza F Samatova. A scalable approach for outlier detection in edge streams using sketch-based approximations. In SDM, pages 189-197, 2016.
+[37] Lukas Ruff, Robert Vandermeulen, Nico Goernitz, Lucas Deecke, Shoaib Ahmed Siddiqui, Alexander Binder, Emmanuel Müller, and Marius Kloft. Deep one-class classification. In ICML, pages 4393-4402, 2018.
+[38] Saurabh Sawlani, Lingxiao Zhao, and Leman Akoglu. Fast attributed graph embedding via density of states. In ICDM, pages 559-568. IEEE, 2021.
+[39] Bernhard Schölkopf, John C Platt, John Shawe-Taylor, Alex J Smola, and Robert C Williamson. Estimating the support of a high-dimensional distribution. Neural Comput., 13(7):1443-1471, 2001.
+[40] Bernhard Schölkopf, Robert C Williamson, Alex Smola, John Shawe-Taylor, and John Platt. Support vector method for novelty detection. In NeurIPS, pages 582-588, 1999.
+[41] Nino Shervashidze and Karsten Borgwardt. Fast subtree kernels on graphs. In NeurIPS, pages 1660-1668, 2009.
+[42] Nino Shervashidze, SVN Vishwanathan, Tobias Petri, Kurt Mehlhorn, and Karsten Borgwardt. Efficient graphlet kernels for large graph comparison. In AISTATS, pages 488-495, 2009.
+[43] Mahito Sugiyama and Karsten Borgwardt. Halting in random walk kernels. In NeurIPS, pages 1639-1647, 2015.
+[44] Jianheng Tang, Jiajin Li, Ziqi Gao, and Jia Li. Rethinking graph neural networks for anomaly detection. In ICML, pages 21076-21089, 2022.
+[45] Ruo-Chun Tzeng and Shan-Hung Wu. Distributed, egocentric representations of graphs for detecting critical structures. In ICML, pages 6354-6362, 2019.
+[46] Petar Velicković, Guillem Cucurull, Arantxa Casanova, Adriana Romero, Pietro Lio, and Yoshua Bengio. Graph attention networks. In ICLR, 2017.
+
+[47] S Vichy N Vishwanathan, Nicol N Schraudolph, Risi Kondor, and Karsten M Borgwardt. Graph kernels. J. Mach. Learn. Res., 11:1201-1242, 2010.
+[48] H Gerhard Vogel, Wolfgang H Vogel, H Gerhard Vogel, Günter Müller, Jürgen Sandoi, and Bernward A Scholkens. *Drug discovery and evaluation: pharmacological assays*, volume 2. Springer, 1997.
+[49] Byron C Wallace, Kevin Small, Carla E Brodley, and Thomas A Trikalinos. Class imbalance, remix. In ICDM, pages 754-763, 2011.
+[50] Jiaqi Wang, Wenwei Zhang, Yuhang Zang, Yuhang Cao, Jiangmiao Pang, Tao Gong, Kai Chen, Ziwei Liu, Chen Change Loy, and Dahua Lin. Seesaw loss for long-tailed instance segmentation. In CVPR, pages 9695-9704, 2021.
+[51] Shen Wang, Lifang He, Bokai Cao, Chun-Ta Lu, Philip S Yu, and Ann B Ragin. Structural deep brain network mining. In KDD, pages 475-484, 2017.
+[52] Zhengyang Wang and Shuiwang Ji. Second-order pooling for graph neural networks. IEEE Trans. Pattern Anal. Mach. Intell., 2020.
+[53] Gang Wu and Edward Y Chang. Kba: Kernel boundary alignment considering imbalanced data distribution. IEEE Trans. Knowl. Data Eng., 17(6):786-795, 2005.
+[54] Keyulu Xu, Weihua Hu, Jure Leskovec, and Stefanie Jegelka. How powerful are graph neural networks? In ICLR, 2019.
+[55] Xifeng Yan, Hong Cheng, Jiawei Han, and Philip S Yu. Mining significant graph patterns by leap search. In SIGMOD, pages 433-444, 2008.
+[56] Zhitao Ying, Jiaxuan You, Christopher Morris, Xiang Ren, Will Hamilton, and Jure Leskovec. Hierarchical graph representation learning with differentiable pooling. NeurIPS, pages 4805-4815, 2018.
+[57] Ge Zhang, Zhao Li, Jiaming Huang, Jia Wu, Chuan Zhou, Jian Yang, and Jianliang Gao. efraudcom: An e-commerce fraud detection system via competitive graph neural networks. ACM Trans Inf Syst, 40(3):1-29, 2022.
+[58] Ge Zhang, Jia Wu, Jian Yang, Amin Beheshti, Shan Xue, Chuan Zhou, and Quan Z Sheng. Fraud: Fraud detection dual-resistant to graph inconsistency and imbalance. In ICDM, pages 867-876. IEEE, 2021.
+[59] Muhan Zhang, Zhicheng Cui, Marion Neumann, et al. An end-to-end deep learning architecture for graph classification. In AAAI, pages 4438-4445, 2018.
+[60] Muhan Zhang and Pan Li. Nested graph neural networks. In NeurIPS, pages 15734-15747, 2021.
+[61] Lingxiao Zhao and Leman Akoglu. Pairnorm: Tackling oversmoothing in gnns. In ICLR, 2020.
+[62] Lingxiao Zhao and Leman Akoglu. On using classification datasets to evaluate graph outlier detection: Peculiar observations and new insights. *Big Data*, 2021.
+[63] Panpan Zheng, Shuhan Yuan, Xintao Wu, Jun Li, and Aidong Lu. One-class adversarial nets for fraud detection. In AAAI, pages 1286-1293, 2019.
+[64] Bo Zong, Qi Song, Martin Renqiang Min, Wei Cheng, Cristian Lumezanu, Daeki Cho, and Haifeng Chen. Deep autoencoding gaussian mixture model for unsupervised anomaly detection. In ICLR, 2018.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [N/A]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/images.zip b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..e04aef82e7b7b3750da6cecc10f8ec9c1aae6da6
--- /dev/null
+++ b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:dc716234922fc252e3342e8f4d555639cf0a5206b5f0af491d6bdb14b974bc6e
+size 455482
diff --git a/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/layout.json b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..6581c9024d8104572f9ab159de1f51b457fe0c1a
--- /dev/null
+++ b/dualdiscriminativegraphneuralnetworkforimbalancedgraphlevelanomalydetection/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:563908961ba64edde8de1b9ded59553f072c01354bffba1db8437a74f5b83fa3
+size 542757
diff --git a/dungeonsanddataalargescalenethackdataset/21cf6cd0-c8cb-46b3-bf74-fb3b6f182a21_content_list.json b/dungeonsanddataalargescalenethackdataset/21cf6cd0-c8cb-46b3-bf74-fb3b6f182a21_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..1066e610a3790d8c3b4ab4da715fd6f72b835c8e
--- /dev/null
+++ b/dungeonsanddataalargescalenethackdataset/21cf6cd0-c8cb-46b3-bf74-fb3b6f182a21_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7eb81aa1f409da78ad899a363fcd71acec6b283d4e130db5c8b7d12671056a78
+size 85378
diff --git a/dungeonsanddataalargescalenethackdataset/21cf6cd0-c8cb-46b3-bf74-fb3b6f182a21_model.json b/dungeonsanddataalargescalenethackdataset/21cf6cd0-c8cb-46b3-bf74-fb3b6f182a21_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..759070b02d86ffe6bd076cdc6b46e065ca2f800e
--- /dev/null
+++ b/dungeonsanddataalargescalenethackdataset/21cf6cd0-c8cb-46b3-bf74-fb3b6f182a21_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e0dfc3f244740f9ebfb5445b0f07dffdddf82857eda70c305c070f52d7583f9d
+size 111694
diff --git a/dungeonsanddataalargescalenethackdataset/21cf6cd0-c8cb-46b3-bf74-fb3b6f182a21_origin.pdf b/dungeonsanddataalargescalenethackdataset/21cf6cd0-c8cb-46b3-bf74-fb3b6f182a21_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..fd77ab9df9fb3932fe43af6277b65a79bd8d5171
--- /dev/null
+++ b/dungeonsanddataalargescalenethackdataset/21cf6cd0-c8cb-46b3-bf74-fb3b6f182a21_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1344e4ae58cc7eb649d244107ef8460761a667fa1f4d1d805e2d2b6890b62d69
+size 1640056
diff --git a/dungeonsanddataalargescalenethackdataset/full.md b/dungeonsanddataalargescalenethackdataset/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..c7211bc73f43eac41b38335fa2b7d27aeffcb20d
--- /dev/null
+++ b/dungeonsanddataalargescalenethackdataset/full.md
@@ -0,0 +1,320 @@
+# Dungeons and Data: A Large-Scale NetHack Dataset
+
+Eric Hambro*
+
+Meta AI
+
+Roberta Raileanu
+
+Meta AI
+
+Danielle Rothermel
+
+Meta AI
+
+Vegard Mella
+
+Meta AI
+
+Tim Rocktäschel
+
+University College London
+
+Heinrich Kuttler
+
+Inflection $\mathbf{A}\mathbf{I}^{\dagger}$
+
+Naila Murray
+
+Meta AI
+
+# Abstract
+
+Recent breakthroughs in the development of agents to solve challenging sequential decision making problems such as Go [50], StarCraft [58], or DOTA [3], have relied on both simulated environments and large-scale datasets. However, progress on this research has been hindered by the scarcity of open-sourced datasets and the prohibitive computational cost to work with them. Here we present the NetHack Learning Dataset (NLD), a large and highly-scalable dataset of trajectories from the popular game of NetHack, which is both extremely challenging for current methods and very fast to run [23]. NLD consists of three parts: 10 billion state transitions from 1.5 million human trajectories collected on the NAO public NetHack server from 2009 to 2020; 3 billion state-action-score transitions from 100,000 trajectories collected from the symbolic bot winner of the NetHack Challenge 2021; and, accompanying code for users to record, load and stream any collection of such trajectories in a highly compressed form. We evaluate a wide range of existing algorithms including online and offline RL, as well as learning from demonstrations, showing that significant research advances are needed to fully leverage large-scale datasets for challenging sequential decision making tasks.
+
+# 1 Introduction
+
+Recent progress on deep reinforcement learning (RL) methods has led to significant breakthroughs such as training autonomous agents to play Atari [33], Go [50], StarCraft [58], and Dota [3], or to perform complex robotic tasks [24, 44, 26, 35, 16, 41]. In many of these cases, success relied on having access to large-scale datasets of human demonstrations [58, 3, 41, 26]. Without access to such demonstrations, training RL agents to operate effectively in these environments remains challenging due to the hard exploration problem posed by their vast state and action spaces. In addition, having access to a simulator is key for training agents that can discover new strategies not exhibited by human demonstrations. Therefore, training agents using a combination of offline data and online interaction has proven to be a highly successful approach for solving a variety of challenging sequential decision making tasks. However, this requires access to complex simulators and large-scale offline datasets, which tend to be computationally expensive.
+
+The NetHack Learning Environment (NLE) was recently introduced as a testbed for RL, providing an environment which is both extremely challenging [15] and exceptionally fast to simulate [23]. NLE is a stochastic, partially observed, and procedurally generated RL environment based on the popular game of NetHack. Due to its long episodes (i.e. tens or hundreds of thousands of steps) and large state and action spaces, NLE poses a uniquely hard exploration challenge for current RL methods. Thus, one of the most promising research avenues towards progress on NetHack is leveraging human or symbolic-bot demonstrations to bootstrap performance, which also proved successful for StarCraft [58] and Dota [3].
+
+In this paper, we introduce the NetHack Learning Dataset (NLD), an open and accessible dataset for large-scale offline RL and learning from demonstrations. NLD consists of three parts: first, NLD-NA0: a collection of state-only trajectories from 1.5 million human games of NetHack played on nethack.alt.org (NAO) servers between 2009 and 2020; second, NLD-AA: a collection of state-action-score trajectories from 100,000 NLE games played by the symbolic-bot winner of the 2021 NetHack Challenge [15]; third, TtyrecDataset: a highly-scalable tool for efficient training on any NetHack and NLE-generated trajectories and metadata. NLD, in combination with NLE, enables computationally-accessible research in multiple areas including imitation learning, offline RL, learning from sequences of only observations, as well as combining learning from offline data with learning from online interactions. In contrast with other large-scale datasets of demonstrations, NLD is highly efficient in both memory and compute. NLD-NA0 can fit on a $30 hard drive, after being compressed (by a factor of 160) from 38TB to 229GB. In addition, NLD-NA0 can be processed in under 15 hours, achieving a throughput of 288,000 frames per second with only 10 CPUs. NLD's low memory and computational requirements makes large-scale learning from demonstrations more accessible for academic and independent researchers.
+
+To summarize, the key characteristics of NLD are that: it is a scalable dataset of demonstrations (i.e. large and cheap) for a highly-complex sequential decision making challenge; it enables research in multiple areas such as imitation learning, offline RL, learning from observations of demonstrations, learning from both static data and environment interaction; and it has many properties of real-world domains such as partial observability, stochastic dynamics, sparse reward, long trajectories, rich environment, diverse behaviors, and a procedurally generated environment.
+
+In this paper, we make the following core contributions: (i) we introduce NLD-NAO, a large-scale dataset of almost 10 billion state transitions, from 1.5 million NetHack games played by humans; (ii) we also introduce NLD-AA, a large-scale dataset of over 3 billion state-action-score transitions, from 100,000 games played by the symbolic-bot winner of the NeurIPS 2022 NetHack Competition; (iii) we open-source code for users to record, load, and stream any collection of NetHack trajectories in a highly compressed form; and (iv) we show that, while current state-of-the-art methods in offline RL and learning from demonstrations can effectively make use of the dataset, playing NetHack at human-level performance remains an open research challenge.
+
+# 2 Related Work
+
+Offline RL Benchmarks. Recently, there has been a growing interest in developing better offline RL methods [25, 39, 11, 60, 61, 21, 20, 6, 2, 49] which aim to learn from datasets of trajectories. With it, a number of offline RL benchmarks have been released [1, 62, 10, 42, 22, 43]. While these benchmarks focus specifically on offline RL, our datasets enable research on multiple areas including imitation learning, learning from observations only (i.e. without access to actions or rewards), as well as learning from both offline and online interactions. In order to make progress on difficult RL tasks such as NetHack, we will likely need to learn from both human data and environment interaction, as was the case with other challenging games like StarCraft [58] or Dota [3]. In contrast, the tasks proposed in current offline RL benchmarks are much easier and can be solved by training either only online or only offline [10, 62]. In addition, current offline RL benchmarks test agents on the exact same environment where the data was collected. As emphasized by [57], imitation learning algorithms drastically overfit to their environments, so it is essential to evaluate them on new scenarios in order to develop robust methods. In contrast, NLE has long procedurally generated episodes which require both long-term planning and systematic generalization in order to succeed. This is shown in [30], which investigates transfer learning between policies trained on different NLE-based environments.
+
+For many real-world applications such as autonomous driving or robotic manipulation, learning from human data is essential due to safety concerns and time constraints [40,10,8,5,27,52,55,17,38,18]. However, most offline RL benchmarks contain synthetic trajectories generated by either random exploration, pretrained RL agents, or simple hard-coded behaviors [10]. In contrast, one of our datasets consists entirely of human replays, while the other one is generated by the winner of the NetHack Competition at NeurIPS 2022 which is a complex symbolic bot with built-in knowledge of the game. Human data (like the set contained in NLD-NAO) is significantly more diverse and messy than synthetic data, as humans can vary widely in their expertise, optimize for different objectives (such as fun or discovery), have access to external information (such as the NetHack Wiki [34]),
+
+and even have different observation or action spaces than RL agents. Hence, learning directly from human data is essential for making progress on real-world problems in RL.
+
+Large-Scale Human Datasets. A number of large-scale datasets of human replays have been released for StarCraft [59], Dota [3], and MineRL [14]. However, training models on these datasets require massive computational resources, which makes it unfeasible for academic or independent researchers. In contrast, NLD strikes a better balance between scale (i.e. a large number of diverse human demonstrations on a complex task) and efficiency (i.e. cheap to use and fast to run).
+
+For many real-world applications such as robotic manipulation, we only have access to the demonstrator's observations and not their actions [29, 48, 40, 8, 51]. Research on this setting has been slower [9, 56, 7], in part due to the lack of efficient large-scale datasets. While there are some datasets containing only observations, they are either much smaller than NLD [32, 57, 48], too computationally expensive [59, 3], or lack a simulator which prevents learning from online interactions [12, 28, 8].
+
+# 3 Background: The NetHack Learning Environment
+
+The NetHack Learning Environment (NLE) is a gym environment [4] based on the popular " dungeon-crawler" game, NetHack [19]. Despite the visual simplicity, NetHack is widely considered one of the hardest video games in history since it can take years for humans to win the game [54]. Players need to explore the dungeon, manage their resources, as well as learn about the many entities and their dynamics (often by relying on external knowledge sources like the NetHack Wiki [34]). NetHack has a clearly defined goal, namely descend the dungeon, retrieve an amulet, and ascend back to win the game. At the beginning of each game, players are randomly assigned a given multidimensional character defined by role, race, alignment, and gender (which have varying properties and challenges), so they need to master all characters in order to win consistently. Thus, NLE offers a unique set of properties which make it well-positioned to advance research on RL and learning from demonstrations: it is a highly complex environment, containing hundreds of entities with different dynamics; it is procedurally generated, allowing researchers to test generalization; it is partially observed, highly stochastic, and has very long episodes (i.e. one or two orders of magnitude longer than Starcraft II [59]).
+
+Following its release, several works have built on NLE to leverage its complexity in different ways. MiniHack [45] allows researchers to design their own environments to test particular capabilities of RL agents, by leveraging the full set of entities and dynamics from NetHack. The NetHack Challenge [15] was a competition at NeurIPS 2021, which sought to incentivise a showdown between symbolic and deep RL methods on NLE. Symbolic bots decisively outperformed deep RL methods, with the best performing symbolic bots surpassing state-of-the-art deep RL methods by a factor of 5.
+
+# 4 The NetHack Learning Dataset
+
+The NetHack Learning Dataset (NLD) contains three components:
+
+1. NLD-NAO — a directory of ttyrec.bz2 files containing almost 10 billion state trajectories and metadata from 1,500,000 human games of NetHack played on nethack.alt.org.
+2. NLD-AA — a directory of ttyrec3.bz2 files containing over 3 billion state-action-score trajectories and metadata from 100,000 games collected from the winning bot of the NetHack Challenge [15].
+3. TtyrecDataset — a Python class that can scalably load directories of ttyrec.bz2 / ttyrec3.bz2 files and their metadata into numpy arrays.
+
+We are also releasing a new version of the NetHack environment, NLE v0.9.0, which contains new features and ensures compatibility with NLD (see Appendix C).
+
+File Format. The ttyred file format stores sequences of terminal instructions (equivalent to observations in RL), along with the times at which to play them. In NLE v0.9.0, we adapt this format to also store keypress inputs to the terminal (equivalent to actions in RL), and in-game scores over time (equivalent to rewards in RL), allowing a reconstruction of state-action-score trajectories. This
+
+adapted format is known as ttyrec3. The ttyrec.bz2 and ttyrec3.bz2 formats, compressed versions of ttyrec and ttyrec3, are the primary data formats used in NLD. Using TtyrecDataset, these compressed files can be written and read on-the-fly, resulting in data compression ratios of more than 138. The files can be decompressed into the state trajectory on a terminal, by using a terminal emulator and querying its screen. For more details see Appendix D.
+
+Throughout the paper, we refer to a player's input at a given time as either state or observation. However, note that NetHack is partially observed, so the player doesn't have access to the full state of the game. We also sometimes use the terms score and reward interchangeably, since the increment in in-game score is a natural choice for the reward used to train RL agents on NetHack. Similarly, a human's keypress corresponds to an agent's action in the game.
+
+Metadata. NetHack has an optional built-in feature for the logging of game metadata, used for the maintenance of all-time high-score lists. At the end of a game, 26 fields of data are logged to a common xlogfile for posterity. These fields include the character's name, race, role, score, cause of death, maximum dungeon depth, and more. See Appendix E for more details on these fields. With NLE v0.9.0, an xlogfile is generated for all NLE recordings. These files are used to populate all metadata contained in NLD.
+
+State-Action-Score Transitions. As mentioned, NLD-AA contains sequences of state-action-score transitions from symbolic-bot plays, while NLD-NAO contains sequences of state transitions from human plays. These transitions are efficiently processed using the TtyrecDataset. The states consist of: ttychars (the characters at each point on the screen), ttyColors (the colors at each point on the screen), tty_cursor (the location of the cursor on the screen), timestamps (when the state was recorded), and gameids (an identifier for the game in question). Additionally, keypresses and score observations are available for ttyrec3 files, as in the NLD-AA dataset. The states, keypresses, and scores from NLD map directly to an agent's observations, actions, and rewards in NLE. More information about these transitions can be found in Appendix F
+
+API. The TtyrecDataset follows the API of an IteratorDataset defined in PyTorch. This allows for the batched streaming of ttyrec.bz2 / ttyrec3.bz2 files directly into fixed NumPy arrays of a chosen shape. Episodes are read sequentially in chunks defined by the unroll length, batched with a different game per batch index. The order of these games can be shuffled, predetermined or even looped to provide a never-ending dataset. This class allows users to load any state-action-score trajectory recorded from NLE v0.9.0 onwards.
+
+The TtyrecDataset wraps a small sqlite3 database where it stores metadata and the paths to files. This design allows for the simple querying of metadata for any game, along with the dynamic subselection of games streamed from the TtyrecDataset itself. For example, in Figure 1 we generate sub-datasets from NLD-NAO and NLD-AA, selecting trajectories where the player has completed the game ('Ascended') or played a 'Human Monk' character, respectively. Appendix G shows how to load only a subset of trajectories, for example where the player has ascended, or a certain role has been used.
+
+Scalability. The TtyrecDataset is designed to make our large-scale NLD datasets accessible even when the computational resources are limited. To that end, several optimizations are made to improve the memory efficiency and throughput of the data. Most notably, TtyrecDataset streams recordings directly from their compressed ttyrec.bz2 files. This format compresses the 30TB of frame data included in NLD-NAO down to 229GB, which can fit on a $30 SSD[5]. This decompression requires on-the-fly unzipping and terminal emulation. The TtyrecDataset performs these in GIL-released C/C++. This process is fast and trivially parallelizable with Python Threadpool, resulting in throughputs of over 1.7 GB/s on 80 CPUs. This performance allows the processing of almost 10 billion frames of NLD-NAO in 15 hours, with 10 CPUs. See Table [T] for a quantitative description of our two datasets.
+
+# 5 Dataset Analysis
+
+In this section we perform an in-depth analysis of the characteristics of NLD-AA and NLD-NAO.
+
+Table 1: NLD-AA and NLD-NAO in numbers.
+
+ | NLD-AA | NLD-NAO |
| Episodes | 109,545 | 1,511,228 |
| Transitions | 3,481,605,009 | 9,858,127,896 |
| Policies (Players) | 1 | 48,454 |
| Policies Type | symbolic bot | human |
| Transition | (state, action, score) | state |
| Disk Size (Compressed) | 96.7 GB | 229 GB |
| Data Size (Uncompressed) | 13.4 TB | 38.0 TB |
| Compression Ratio | 138 | 166 |
| Mean Epiode Score | 10,105 | 127,218 |
| Median Episode Score | 5,422 | 836 |
| Median Episode Transitions | 28,181 | 1,724.0 |
| Median Episode Game Turns | 20,414 | 3,766 |
| Epoch Time (10 CPUs) | 4h 49m | 14h 37m |
+
+# 5.1 NLD-AA
+
+To our knowledge, AutoAscend is currently the best open-sourced artificial agent for playing NetHack 3.6.6, having achieved first place in the 2021 NeurIPS NetHack Challenge by a considerable margin [15]. AutoAscend is a symbolic bot, forgoing any neural network and instead relying on a priority list of hard-coded subroutines. These subroutines are complex, context dependant, and make significant use of NetHack domain knowledge and all NetHack actions. For instances, the bot keeps track of multiple properties for encountered entities and can even solve challenging puzzles such as Sokoban. A full description of AutoAscend's algorithm and behavior can be found in the NetHack Challenge Report [15].
+
+NLD-AA was generated by running AutoAscend on the NetHackChallenge-v0 [15] task in NLE v0.9.0, utilising its built-in recording feature to generate ttyrec3.bz2 files. It consists of over 3 billion state-action-score transitions, drawn from 100,000 episodes generated by AutoAscend. Of the NLE tasks, NetHackChallenge-v0 most closely reproduces the full game of NetHack 3.6.6, and was introduced in NLE v0.7.0 to grant NetHack Challenge competitors access to the widest possible action space, and force an automated randomisation of the starting character (by race, role, alignment, and gender). By virtue of using ttyrec3.bz2 files, in-game scores and actions (in the form of key presses) are stored along with the states, and metadata about the episodes.
+
+Dataset Skill. The AutoAscend trajectories demonstrate a strong and reliable NetHack player, far exceeding all the deep learning based approaches, but still falling short of an expert human player. NetHack broadly defines a character with less than 2000 score as a 'Beginner'. AutoAscend comfortably surpasses the 'Beginner' classification in more than $75\%$ of games for all roles, and in $95\%$ of games for easier roles like Monk (see Figure 1). Given the high variance nature of NetHack games, and the challenge of playing with the more difficult roles, this is an impressive feat.
+
+Compared to the human players in NLD-NAO, AutoAscend's policy finds itself just within the top $15\%$ of all players when ranked by mean score. When ranked by median score it comes within the top $7\%$ . However, these metrics are somewhat distorted by the long tail of dilettante players who played only a few games. If instead we define a 'competent' human player as one to have ever advanced beyond the Beginner classification, then AutoAscend ranks in the top $33\%$ of players by mean score, and top $15\%$ by median.
+
+The competence of AutoAscend contrasts both with the poor performance of deep RL bots, and with the exceptional performance required to beat the game. As the winning symbolic bot of the NetHack Challenge, AutoAscend beat the winning deep learning bot by almost a factor of 3 in median score, and close to a factor of 5 in mean score. This performance is far outside what deep RL agents can currently achieve, and in some domains NLD-AA may be considered an "expert" dataset. However,
+
+
+Figure 1: Box plots of episode scores (left) and episode turns (right) for NLD-NAO and NLD-AA as well as for their corresponding subsets that contain only winning games ('Ascended') or games played with a 'Human Monk' character, respectively. These plots show the distribution in ability in NLD-NAO is heavy-tailed, along with the typical scores and game length needed to win, well above the median. By comparison, NLD-AA games are competent but not expert, even for easy characters like 'Human Monk'.
+
+when compared to the distribution of winning games (i.e. those that have 'ascended'), both mean and median score are orders of magnitude short.
+
+Dataset Coverage. Thanks to its scale, NLD-AA provides solid coverage of the early-to-mid game of NetHack. NLD-AA also provides good coverage of all possible actions and roles, with episodes that last for tens of thousands of transitions. Nevertheless, the dataset contains many complex and diverse behaviors. For the full breakdown of the symbolic bot's behaviors found in NLD-AA see Appendix E
+
+Dataset Noise. Since all trajectories were generated using NLE, these trajectories have no terminal rendering noise. NLE uses a VT100 emulator to record ttyrec3.bz2 files, and NLD uses the same emulator to load them.
+
+# 5.2 NLD-NAO
+
+The NetHack community has a long history of using public servers, wherein players can play together, stream and rewatch games of NetHack. The nethack.alt.org server, known as NAO is one of the longest running of such servers, having started in 2001, and hosts recordings dating back to 2009. The server attempts to record all games in ttyrec.bz2 format, and hosts them publicly on an S3 bucket. Unlike NLE, NAO offers players the option of saving a game and resuming play later, allowing for games that span multiple sessions, or last potentially days, weeks, months or years.
+
+NLD-NAO was collected by downloading and filtering a dump of ttyrec.bz2 recordings and metadata from NAO. It consists of almost 10 billion state transitions, drawn from approximately 1.5 million games played by just under 50,000 humans of mixed ability. These games were played between 2009 and 2020, and span NetHack versions v3.4.0 to 3.6.6. Since NAO provides no link between episode metadata and available ttyrec recordings, we developed an algorithm to assign and correctly order ttyrec recordings to their corresponding episode metadata, and to filter out trivial or empty games. The full procedure is outlined in Appendix H
+
+Dataset Skill. The NAO trajectories were generated from humans of very different skill levels, ranging from novice to expert, and cover a vast distribution of outcomes. The distributions of episode scores, episode turns, and average player scores are highly Zipfian, with long correlated tails spanning several orders of magnitude. The correlation of these distributions greatly improves the quality of the dataset. While the median episode score does not progress beyond Beginner status, such short episodes contribute relatively few transitions to the overall dataset. The bulk of the transitions comes from medium-to-high scoring games that last a long time. The NLD-NAO dataset therefore combines two desirable properties: it contains a large number of diverse behaviors with varying levels of performance, as well as many good trajectories from expert demonstrators.
+
+Dataset Coverage. Thanks to its size and expert policies, NLD-NAO provides an unparalleled coverage of the game of NetHack. The dataset contains many examples of advanced game sections not yet achievable by symbolic or RL bots, such as descending the dungeon and retrieving the amulet. Most importantly, it includes 22,000 examples of winning the game ("Ascension"), and includes several
+
+```txt
+https://nethackwiki.com/wiki/Public_server
+https://nethackwiki.com/wiki/Nethack.alt.org
+s3://altorg/ttyrec/
+```
+
+examples of doing so with special conducts such as "Nudist" (not wearing any armour). The full distribution of such achievements and conducts can be found in Appendix E.
+
+Dataset Noise. Unlike NLE, NAO does not enforce any fixed terminal type on the player, nor any fixed screen dimensions or configuration. Variations in all these can lead to rendering noise that may include odd symbols or cropped layouts. These types of artefacts are common in real-world applications of learning from demonstrations, which makes NLD a suitable dataset for advancing research in this area. More details about these artefacts, as well as other types of noise (e.g. matching of recordings to players), see Appendix H.
+
+# 6 Experiments
+
+# 6.1 Methods
+
+We demonstrate the utility and challenge of NLD by evaluating algorithms from a range of fields including online RL, offline RL, imitation learning, and learning from demonstrations.
+
+All methods are implemented using the open-source asynchronous RL library moolib [31], allowing for continual evaluation of agents in order to generate training curves (even in the offline RL setting). In addition, all our methods use the same core model architecture, which is based on a popular open-source Sample Factory baseline adapted to only use tty_* observations but still remain fast to run. Unless specified otherwise, all experiments were evaluated with 1024 episodes from NLE's NetHackChallenge-v0 task after training for 1.5B frames. The mean and standard deviation of the episode return was computed over 10 training seeds. Full details about the algorithms and their hyperparameters can be found in Appendix All our implementations will be open-sourced to enable fast research progress.
+
+Online RL. For online RL baselines that do not make use of the NLD datasets, we use Asynchronous Proximal Policy Optimization (APPO) [47, 37] and Deep Q-Networks (DQN-Online). The former is a strong on-policy policy-gradient-based method for NLE, and the latter is a popular off-policy value-based method in the wider literature.
+
+Offline RL. Since NLD-AA contains state-action-reward transitions, we can train a number of offline RL baselines on it. More specifically, we use a Deep Q-Network baseline trained on the dataset (DQN-Offline), as well as two state-of-the-art offline RL methods, Conservative Q-Learning (CQL) [21] and Implicit Q-Learning (IQL) [20]. Note that these methods cannot be trained on NLD-NAO since it doesn't contain actions or rewards.
+
+Learning from Demonstrations. We also evaluate a number of baselines that do not make use of rewards, but instead use state-action or state-only transitions. For NLD-AA, we use Behavioural Cloning (BC), a popular imitation learning method, which trains a policy to match the corresponding actions in the dataset using a supervised learning objective. For NLD-NAO, we use Behavioral Cloning from Observations (BCO) [56] which is a popular baseline for learning from state-only demonstrations. This method performs BC on a learned inverse dynamics model which was trained to predict the action taken given two consecutive states. We then investigate the use of BC and BCO in an online setting by augmenting our APPO baseline in two ways. First, we add the BC or BCO loss between the agent's policy and the expert's action for observations in the dataset resulting in APPO + BC and APPO + BCO respectively. Second, we add a KL-divergence loss between the agent's policy and a pretrained BC(O) model resulting in Kickstarting BC(O), similar to [46]. These methods make use of state and action data but no rewards.
+
+For NLD-AA, we investigate the performance of the above algorithms across two partitions: one with a single character ('Human Monk'), and one with all the characters (i.e. the full dataset). Each of these is evaluated on their corresponding environments. Full details about our experimental setup are available in Appendix I.
+
+# 6.2 Results and Discussion
+
+As Table 2 and Figure 2 show, NLD-AA poses a difficult challenge to modern offline RL algorithms. While CQL is able to use the offline trajectories to outperform both a random policy, IQL, as well as
+
+Table 2: Average episode return across 10 seeds for a number of popular baselines using NLD and / or NLE. First, we evaluate a range of offline RL methods such as DQN-Offline, CQL, IQL and BC trained on NLD-AA and NLD-AA-Monk, as well as BCO trained on NLD-NAO. Second, we evaluate methods that combine offline and online learning such as Kickstarting + BC and APPO + BC trained on NLD-AA and NLD-AA-Monk, as well as Kickstarting + BCO and APPO + BCO trained on NLD-NAO. Finally, we evaluate a few methods that only have access to online interactions from NLE (no external datasets) such as a Random Policy, DQN-Online, and APPO. All evaluations are conducted with NLE's NetHackChallenge-vO task, using Random (@) characters for NLD-AA and NLD-NAO, and a Human Monk character for NLD-AA-Monk. We compare all these to the average episode return in the corresponding datasets. Methods that use both offline and online data outperform all others by a wide margin, but are still significantly worse than humans (by almost two orders of magnitude) and even the symbolic bot (by more than a factor of three). The top online algorithm, APPO, outperforms the top offline approach, BC. These results indicate that NLD poses a substantial challenge to state-of-the-art methods.
+
+ | Character | NLD-AA
+Random | NLD-AA-Monk
+Human Monk | NLD-NAO
+Random |
| offline only | DQN-Offline | 0.0 ± 0.1 | 0.0 ± 0.1 | - |
| CQL | 704 ± 112 | 732 ± 219 | - |
| IQL | 341 ± 40 | 533 ± 178 | - |
| BC(O) | 1220 ± 261 | 1728 ± 615 | 12.5 ± 2.0 |
| offline + online | Kickstarting + BC(O) | 2250 ± 81 | 3907 ± 330 | 502 ± 62 |
| APPO + BC(O) | 2767 ± 284 | 4779 ± 1116 | 1972 ± 180 |
| online only | Random Policy | 0.2 ± 0.2 | 0.4 ± 0.4 | (see col 1) |
| DQN-Online | 159 ± 68 | 247 ± 152 | (see col 1) |
| APPO | 1799 ± 156 | 4006 ± 323 | (see col 1) |
| Dataset Average | 10105 | 17274 | 127356 |
+
+online and offline variants of DQN, it falls short of capturing the average performance of trajectories in the dataset by over an order of magnitude. BC performs better due to the higher quality of the supervised learning signal, which is typically denser and less noisy than the RL one, but it too falls well short of the data generating policy. Prior work has shown that offline RL methods struggle to perform well in stochastic environments [36], and to generalize outside the distribution of state-action pairs in the dataset [13]. These challenges are particularly intensified with NLD, which is highly stochastic, partially observed, procedurally generated, and has a very large state and action space.
+
+Methods that combine offline and online training such as Kickstarting + BC(O) or APPO + BC(O) outperform offline-only methods and outperform or match online-only methods, while also speeding up training. In fact, APPO + BC sets a new state-of-the-art for purely Deep RL on NLE, and would have won first place on the Neural Track at the NetHack Challenge 2021, scoring a median of 2110 and beating the hybrid symbolic-deep RL winner by almost 400 points [15]. Despite being our best method, APPO + BC is still significantly worse than the average performance in the dataset, further emphasizing the difficulty of NLD.
+
+Finally, our results demonstrate the utility of NLD-NAO while highlighting the challenge of learning from sequences of only observations. Our inverse model is trained with trajectories from a random policy, and therefore experiences an extremely small fraction of the entire state-action space. Even so, BCO on NLD-NAO labeled with these actions is able to yield performance that comfortably exceeds that of a random policy. While APPO + BCO performs similarly to APPO, training appears to be much more stable. Thus, using more sophisticated policies for training the inverse model (e.g. a mix between a pretrained RL policy and a random policy or an exploration method that maximizes the diversity of visited states and actions) could further improve performance.
+
+# 7 Conclusion
+
+In this paper, we introduce NLD, a large-scale dataset of demonstrations from NetHack, a complex, stochastic, partially observed, procedurally generated video game. NLD enables research in multiple
+
+
+Figure 2: Mean episode return (with samples plotted) over 10 seeds during training for APPO, APPO + BC(O), and Kickstarting + BC(O) using NLD-AA (left), NLD-AA-Monk (center), and NLD-NAO (right). NLD-AA and NLD-NAO both are evaluated with Random character (@), while NLD-AA-Monk is evaluated with only the Human Monk character. Some sample curves associated with the pure online APPO methods exhibit a behaviour wherein performance appears to plateau, before bursting rapidly to a new performance level. This is a common pattern in NLE and corresponds to an agent learning a new behaviour that greatly unlocks yet more of the game, such as praying when starving or kicking down locked doors. Since NLE is highly procedurally generated with a vast action and state space, it is hard to predict when an agent will encounter sufficient opportunities to "take off" in this way. Such "taking off" phenomena are less visible when learning from NLD, as useful behaviours are present in the data throughout.
+
+
+Environment Steps
+
+
+
+areas such as imitation learning, offline RL, learning from sequences of observations, and learning from both offline data and online interactions. NLD allows researchers to learn from very large datasets of demonstrations without requiring extensive memory or compute resources. We train a number of state-of-the-art methods in online RL (both on-policy and off-policy), offline RL, imitation learning, as well as learning from observation-only sequences. Our results indicate that significant research advances are needed to fully leverage large-scale datasets in order to solve challenging sequential decision making problems.
+
+In many real-world applications such as robotics, it is common to have access to datasets of observations, without corresponding actions or rewards. Thus, one important direction for future research is to learn from trajectories containing only observations. NLD enables this type of research in a safe, cheap, fast, and reproducible environment, while still exhibiting many properties of real-world domains such as partial observability, high stochasticity, and long episodes. Due to NetHack being procedurally generated, in order to consistently win the game, an agent needs to learn a robust policy that generalizes to new scenarios. Our strongest baseline learns from both static data and environment interaction, so a promising avenue for future work is to develop more effective methods that combine offline and online learning. Existing algorithms for offline RL and learning from demonstrations struggle to match the average performance of trajectories in our datasets, suggesting that NLD is a good benchmark to probe the limits of these methods and inspire the development of approaches that are effective in more challenging and realistic domains.
+
+# 8 Acknowledgements
+
+We would like to thank Drew Streib and the NAO maintainers for their work in the NetHack community and their help throughout this project. We would also like to thank Michal Sypetkowski and Maciej Sypetkowski for their work on the AutoAscend bot.
+
+# References
+
+[1] Rishabh Agarwal, Dale Schuurmans, and Mohammad Norouzi. Striving for simplicity in off-policy deep reinforcement learning. ArXiv, abs/1907.04543, 2019.
+[2] Rishabh Agarwal, Dale Schuurmans, and Mohammad Norouzi. An optimistic perspective on offline reinforcement learning. In ICML, 2020.
+
+[3] Christopher Berner, Greg Brockman, Brooke Chan, Vicki Cheung, Przemyslaw Debiak, Christy Dennison, David Farhi, Quirin Fischer, Shariq Hashme, Christopher Hesse, Rafal Jozefowicz, Scott Gray, Catherine Olsson, Jakub W. Pachocki, Michael Petrov, Henrique Ponde de Oliveira Pinto, Jonathan Raiman, Tim Salimans, Jeremy Schlatter, Jonas Schneider, Szymon Sidor, Ilya Sutskever, Jie Tang, Filip Wolski, and Susan Zhang. Dota 2 with large scale deep reinforcement learning. ArXiv, abs/1912.06680, 2019.
+[4] Greg Brockman, Vicki Cheung, Ludwig Pettersson, Jonas Schneider, John Schulman, Jie Tang, and Wojciech Zaremba. Openai gym. arXiv preprint arXiv:1606.01540, 2016.
+[5] Serkan Cabi, Sergio Gomez Colmenarejo, Alexander Novikov, Ksenia Konyushkova, Scott E. Reed, Rae Jeong, Konrad Zolna, Yusuf Aytar, David Budden, Mel Vecerik, Oleg O. Sushkov, David Barker, Jonathan Scholz, Misha Denil, Nando de Freitas, and Ziyun Wang. A framework for data-driven robotics. ArXiv, abs/1909.12200, 2019.
+[6] Ching-An Cheng, Tengyang Xie, Nan Jiang, and Alekh Agarwal. Adversarily trained actor critic for offline reinforcement learning. ArXiv, abs/2202.02446, 2022.
+[7] Samuel Cohen, Brandon Amos, Marc Peter Deisenroth, Mikael Henaff, Eugene Vinitsky, and Denis Yarats. Imitation learning from pixel observations for continuous control. In Deep RL Workshop NeurIPS 2021, 2021.
+[8] Sudeep Dasari, Frederik Ebert, Stephen Tian, Suraj Nair, Bernadette Bucher, Karl Schmeckpeper, Siddharth Singh, Sergey Levine, and Chelsea Finn. Robonet: Large-scale multi-robot learning. ArXiv, abs/1910.11215, 2019.
+[9] Ashley D. Edwards, Himanshu Sahni, Yannick Schroecker, and Charles Lee Isbell. Imitating latent policies from observation. *ArXiv*, abs/1805.07914, 2019.
+[10] Justin Fu, Aviral Kumar, Ofir Nachum, G. Tucker, and Sergey Levine. D4rl: Datasets for deep data-driven reinforcement learning. ArXiv, abs/2004.07219, 2020.
+[11] Scott Fujimoto, David Meger, and Doina Precup. Off-policy deep reinforcement learning without exploration. In ICML, 2019.
+[12] Andreas Geiger, Philip Lenz, Christoph Stiller, and Raquel Urtasun. Vision meets robotics: The kitti dataset. The International Journal of Robotics Research, 32:1231 - 1237, 2013.
+[13] Caglar Gulcehre, Sergio Gomez Colmenarejo, Jakub Sygnowski, Thomas Paine, Konrad Zolna, Yutian Chen, Matthew Hoffman, Razvan Pascanu, Nando de Freitas, et al. Addressing extrapolation error in deep offline reinforcement learning. 2020.
+[14] William H. Guss, Brandon Houghton, Nicholay Topin, Phillip Wang, Cayden Codel, Manuela M. Veloso, and Ruslan Salakhutdinov. Mineral: A large-scale dataset of minecraft demonstrations. ArXiv, abs/1907.13440, 2019.
+[15] Eric Hambro, Sharada Mohanty, Dmitrii Babaev, Minwoo Byeon, Dipam Chakraborty, Edward Grefenstette, Minqi Jiang, Daejin Jo, Anssi Kanervisto, Jongmin Kim, et al. Insights from the neurips 2021 nethack challenge. arXiv preprint arXiv:2203.11889, 2022.
+[16] Nicolas Manfred Otto Heess, TB Dhruva, Srinivasan Sriram, Jay Lemmon, Josh Merel, Greg Wayne, Yuval Tassa, Tom Erez, Ziyun Wang, S. M. Ali Eslami, Martin A. Riedmiller, and David Silver. Emergence of locomotion behaviours in rich environments. ArXiv, abs/1707.02286, 2017.
+[17] James Henderson, Oliver Lemon, and Kallirroi Georgila. Hybrid reinforcement/supervised learning of dialogue policies from fixed data sets. Computational Linguistics, 34:487-511, 2008.
+[18] Natasha Jaques, Asma Ghandeharioun, Judy Hanwen Shen, Craig Ferguson, Ågata Lapedriza, Noah J. Jones, Shixiang Shane Gu, and Rosalind W. Picard. Way off-policy batch deep reinforcement learning of implicit human preferences in dialog. ArXiv, abs/1907.00456, 2019.
+[19] Kenneth Lorber. NetHack Home Page. https://nethack.org, 2020. Accessed: 2020-05-30.
+[20] Ilya Kostrikov, Ashvin Nair, and Sergey Levine. Offline reinforcement learning with implicit q-learning. ArXiv, abs/2110.06169, 2021.
+[21] Aviral Kumar, Aurick Zhou, G. Tucker, and Sergey Levine. Conservative q-learning for offline reinforcement learning. ArXiv, abs/2006.04779, 2020.
+
+[22] Vitaly Kurin, Sebastian Nowozin, Katja Hofmann, Lucas Beyer, and B. Leibe. The atari grand challenge dataset. ArXiv, abs/1705.10998, 2017.
+[23] Heinrich Kuttler, Nantas Nardelli, Alexander H. Miller, Roberta Raileanu, Marco Selvatici, Edward Grefenstette, and Tim Rocktäschel. The nethack learning environment. ArXiv, abs/2006.13760, 2020.
+[24] Joonho Lee, Jemin Hwangbo, Lorenz Wellhausen, Vladlen Koltun, and Marco Hutter. Learning quadrupedal locomotion over challenging terrain. Science Robotics, 5, 2020.
+[25] Sergey Levine, Aviral Kumar, G. Tucker, and Justin Fu. Offline reinforcement learning: Tutorial, review, and perspectives on open problems. ArXiv, abs/2005.01643, 2020.
+[26] Sergey Levine, Peter Pastor, Alex Krizhevsky, and Deirdre Quillen. Learning hand-eye coordination for robotic grasping with deep learning and large-scale data collection. The International Journal of Robotics Research, 37:421 - 436, 2018.
+[27] Lihong Li, Wei Chu, John Langford, and Robert E. Schapire. A contextual-bandit approach to personalized news article recommendation. ArXiv, abs/1003.0146, 2010.
+[28] Jeffrey Mahler, Matthew Matl, Vishal Satish, Michael Danielczuk, Bill DeRose, Stephen McKinley, and Ken Goldberg. Learning ambidextrous robot grasping policies. Science Robotics, 4, 2019.
+[29] Ajay Mandlekar, Danfei Xu, J. Wong, Soroush Nasiriany, Chen Wang, Rohun Kulkarni, Li Fei-Fei, Silvio Savarese, Yuke Zhu, and Roberto Mart'in-Mart'in. What matters in learning from offline human demonstrations for robot manipulation. ArXiv, abs/2108.03298, 2021.
+[30] Michael Matthews, Mikayel Samvelyan, Jack Parker-Holder, Edward Grefenstette, and Tim Rocktäschel. Hierarchical kickstarting for skill transfer in reinforcement learning, 2022.
+[31] Vegard Mella, Eric Hambro, Danielle Rothermel, and Heinrich Kuttler. moolib: A Platform for Distributed RL. 2022.
+[32] Raphael Memmesheimer, Ivanna Mykhalchyshyna, Viktor Seib, and Dietrich Paulus. Simitate: A hybrid imitation learning benchmark. 2019 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), pages 5243-5249, 2019.
+[33] Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Alex Graves, Ioannis Antonoglou, Daan Wierstra, and Martin A. Riedmiller. Playing atari with deep reinforcement learning. *ArXiv*, abs/1312.5602, 2013.
+[34] NetHack Wiki. NetHackWiki. https://nethackwiki.com/, 2020. Accessed: 2020-02-01.
+[35] OpenAI, Ilge Akkaya, Marcin Andrychowicz, Maciek Chogiej, Mateusz Litwin, Bob McGrew, Arthur Petron, Alex Paino, Matthias Plappert, Glenn Powell, Raphael Ribas, Jonas Schneider, Nikolas A. Tezak, Jerry Tworek, Peter Welinder, Lilian Weng, Qiming Yuan, Wojciech Zaremba, and Lei M. Zhang. Solving rubik's cube with a robot hand. ArXiv, abs/1910.07113, 2019.
+[36] Keiran Paster, Sheila McIlraith, and Jimmy Ba. You can't count on luck: Why decision transformers fail in stochastic environments. arXiv preprint arXiv:2205.15967, 2022.
+[37] Aleksei Petrenko, Zhehui Huang, Tushar Kumar, Gaurav Sukhatme, and Vladlen Koltun. Sample factory: Egocentric 3d control from pixels at 100000 fps with asynchronous reinforcement learning. In International Conference on Machine Learning, pages 7652-7662. PMLR, 2020.
+[38] Olivier Pietquin, Matthieu Geist, Senthilkumar Chandramohan, and Hervé Frezza-Buet. Sample-efficient batch reinforcement learning for dialogue management optimization. ACM Trans. Speech Lang. Process., 7:7:1-7:21, 2011.
+[39] Rafael Figueiredo Prudencio, Marcos R.O.A. Maximo, and Esther Luna Colombini. A survey on offline reinforcement learning: Taxonomy, review, and open problems. ArXiv, abs/2203.01387, 2022.
+[40] Rongjun Qin, Songyi Gao, Xingyuan Zhang, Zhen Xu, Shengkai Huang, Zewen Li, Weinan Zhang, and Yang Yu. Neorl: A near real-world benchmark for offline reinforcement learning. ArXiv, abs/2102.00714, 2021.
+[41] Aravind Rajeswaran, Vikash Kumar, Abhishek Gupta, John Schulman, Emanuel Todorov, and Sergey Levine. Learning complex dexterous manipulation with deep reinforcement learning and demonstrations. *ArXiv*, abs/1709.10087, 2018.
+
+[42] Sabela Ramos, Sertan Girgin, L'essonard Hussenot, Damien Vincent, Hanna Yakubovich, Daniel Toyama, Anita Gergely, Piotr Stanczyk, Raphaël Marinier, Jeremiah Harmsen, Olivier Pietquin, and Nikola Momchev. Rlds: an ecosystem to generate, share and use datasets in reinforcement learning. ArXiv, abs/2111.02767, 2021.
+[43] Stéphane Ross, Geoffrey J. Gordon, and J. Andrew Bagnell. A reduction of imitation learning and structured prediction to no-regret online learning. In AISTATS, 2011.
+[44] Andrei A. Rusu, Matej Vecerik, Thomas Rothörl, Nicolas Manfred Otto Heess, Razvan Pascanu, and Raia Hadsell. Sim-to-real robot learning from pixels with progressive nets. ArXiv, abs/1610.04286, 2017.
+[45] Mikayel Samvelyan, Robert Kirk, Vitaly Kurin, Jack Parker-Holder, Minqi Jiang, Eric Hambro, Fabio Petroni, Heinrich Kuttler, Edward Grefenstette, and Tim Rocktäschel. Minihack the planet: A sandbox for open-ended reinforcement learning research. arXiv preprint arXiv:2109.13202, 2021.
+[46] Simon Schmitt, Jonathan J. Hudson, Augustin Zidek, Simon Osindero, Carl Doersch, Wojciech M. Czarnecki, Joel Z. Leibo, Heinrich Kuttler, Andrew Zisserman, Karen Simonyan, and S. M. Ali Eslami. Kickstarting deep reinforcement learning. *ArXiv*, abs/1803.03835, 2018.
+[47] John Schulman, Filip Wolski, Prafulla Dhariwal, Alec Radford, and Oleg Klimov. Proximal policy optimization algorithms. arXiv preprint arXiv:1707.06347, 2017.
+[48] Pratyusha Sharma, Lekha Mohan, Lerrel Pinto, and Abhinav Kumar Gupta. Multiple interactions made easy (mime): Large scale demonstrations data for imitation. In CoRL, 2018.
+[49] Noah Siegel, Jost Tobias Springenberg, Felix Berkenkamp, Abbas Abdelmaleki, Michael Neunert, Thomas Lampe, Roland Hafner, and Martin A. Riedmiller. Keep doing what worked: Behavioral modelling priors for offline reinforcement learning. *ArXiv*, abs/2002.08396, 2020.
+[50] David Silver, Aja Huang, Chris J Maddison, Arthur Guez, Laurent Sifre, George Van Den Driessche, Julian Schrittwieser, Ioannis Antonoglou, Veda Panneershelvam, Marc Lanctot, et al. Mastering the game of go with deep neural networks and tree search. nature, 529(7587):484-489, 2016.
+[51] Bradley C. Stadie, P. Abbeel, and Ilya Sutskever. Third-person imitation learning. *ArXiv*, abs/1703.01703, 2017.
+[52] Alexander L. Strehl, John Langford, Lihong Li, and Sham M. Kakade. Learning from logged implicit exploration data. In NIPS, 2010.
+[53] Michita Imai Takuma Seno. d3rlpy: An offline deep reinforcement library. In NeurIPS 2021 Offline Reinforcement Learning Workshop, December 2021.
+[54] The Telegraph. The 25 hardest video games ever. 2021. Accessed: 2021-05-05.
+[55] Philip S. Thomas, Georgios Theocharous, Mohammad Ghavamzadeh, Ishan Durugkar, and Emma Brunskill. Predictive off-policy policy evaluation for nonstationary decision problems, with applications to digital marketing. In AAAI, 2017.
+[56] Faraz Torabi, Garrett Warnell, and Peter Stone. Behavioral cloning from observation. ArXiv, abs/1805.01954, 2018.
+[57] Sam Toyer, Rohin Shah, Andrew Critch, and Stuart J. Russell. The magical benchmark for robust imitation. ArXiv, abs/2011.00401, 2020.
+[58] Oriol Vinyals, Igor Babuschkin, Wojciech M. Czarnecki, Michael Mathieu, Andrew Dudzik, Junyoung Chung, David H. Choi, Richard Powell, Timo Ewalds, Petko Georgiev, Junhyuk Oh, Dan Horgan, Manuel Kroiss, Ivo Danihelka, Aja Huang, L. Sifre, Trevor Cai, John P. Agapiou, Max Jaderberg, Alexander Sasha Vezhnevets, Rémi Leblond, Tobias Pohlen, Valentin Dalibard, David Budden, Yury Sulsky, James Molloy, Tom Le Paine, Caglar Gulcehre, Ziyun Wang, Tobias Pfaff, Yuhui Wu, Roman Ring, Dani Yogatama, Dario Wünsch, Katrina McKinney, Oliver Smith, Tom Schaul, Timothy P. Lillicrap, Koray Kavukcuoglu, Demis Hassabis, Chris Apps, and David Silver. Grandmaster level in starcraft ii using multi-agent reinforcement learning. Nature, pages 1-5, 2019.
+[59] Oriol Vinyals, Timo Ewalds, Sergey Bartunov, Petko Georgiev, Alexander Sasha Vezhnevets, Michelle Yeo, Alireza Makhzani, Heinrich Kuttler, John P. Agapiou, Julian Schrittwieser, John Quan, Stephen Gaffney, Stig Petersen, Karen Simonyan, Tom Schaul, H. V. Hasselt, David
+
+Silver, Timothy P. Lillicrap, Kevin Calderone, Paul Keet, Anthony Brunasso, David Lawrence, Anders Ekermo, Jacob Repp, and Rodney Tsing. Starcraft ii: A new challenge for reinforcement learning. ArXiv, abs/1708.04782, 2017.
+[60] Yifan Wu, G. Tucker, and Ofir Nachum. Behavior regularized offline reinforcement learning. ArXiv, abs/1911.11361, 2019.
+[61] Chi Zhang, Sanmukh Rao Kuppannagari, and Viktor K. Prasanna. Brac+: Improved behavior regularized actor critic for offline reinforcement learning. In ACML, 2021.
+[62] Caglar Güçehre, Ziyun Wang, Alexander Novikov, Tom Le Paine, Sergio Gomez Colmenarejo, Konrad Zolna, Rishabh Agarwal, Josh Merel, Daniel Jaymin Mankowitz, Cosmin Paduraru, Gabriel Dulac-Arnold, Jerry Zheng Li, Mohammad Norouzi, Matthew D. Hoffman, Nicolas Manfred Otto Heess, and Nando de Freitas. Rl unplugged: A collection of benchmarks for offline reinforcement learning. In NeurIPS, 2020.
+
+# 9 Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See Appendix K
+(c) Did you discuss any potential negative societal impacts of your work? [Yes]. See Appendix $\boxed{L}$ .
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments (e.g. for benchmarks)...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] Code will be supplied with the dataset at the link provided in Appendix A
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Appendix I
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] We report standard deviations across seeds for all results.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Appendix I
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] Although we do not use "assets" per se, we do cite the bot AutoAscend by linking to it and citing the author's own write up in the NetHack Challenge report.[15]
+(b) Did you mention the license of the assets? [Yes] We mention the license of the dataset (same as NLE) in Appendix B
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] This is a dataset paper, so the 'assets' are the data, which is of course linked to in Appendix A.
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A] We do not discuss this in the paper because: 1) some of the data is from an open source bot and 2) the human data is already public and completely anonymous. We did discuss this with the site creator (who collected the data, and put up terms of use) and we obtained his consent, as well as the consent of the creators of the bot.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes] We discuss in Appendix H.3
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
+
+# 10 Datasets Checklist
+
+Include extra information in the appendix. This section will often be part of the supplemental material. Please see the call on the NeurIPS website for links to additional guides on dataset publication.
+
+1. Submission introducing new datasets must include the following in the supplementary materials:
+
+(a) Dataset documentation and intended uses. Recommended documentation frameworks include datasheets for datasets, dataset nutrition labels, data statements for NLP, and accountability frameworks. [We document the code to use the dataset in the repository and provide many references in the Appendices.]
+(b) URL to website/platform where the dataset/benchmark can be viewed and downloaded by the reviewers. [We provide this in Appendix A]
+(c) Author statement that they bear all responsibility in case of violation of rights, etc., and confirmation of the data license. [We provide this in Appendix B and upon submission to OpenReview]
+(d) Hosting, licensing, and maintenance plan. The choice of hosting platform is yours, as long as you ensure access to the data (possibly through a curated interface) and will provide the necessary maintenance. [We provide this in Appendix A]
+
+2. To ensure accessibility, the supplementary materials for datasets must include the following:
+
+(a) Links to access the dataset and its metadata. This can be hidden upon submission if the dataset is not yet publicly available but must be added in the camera-ready version. In select cases, e.g when the data can only be released at a later date, this can be added afterward. Simulation environments should link to (open source) code repositories. [We provide this in Appendix A]
+(b) The dataset itself should ideally use an open and widely used data format. Provide a detailed explanation on how the dataset can be read. For simulation environments, use existing frameworks or explain how they can be used. [We provide example usage, documentation, and detailed specification in how data is stored in several Appendices]
+(c) Long-term preservation: It must be clear that the dataset will be available for a long time, either by uploading to a data repository or by explaining how the authors themselves will ensure this. [We provide a maintenance plan in Appendix A]
+(d) Explicit license: Authors must choose a license, ideally a CC license for datasets, or an open source license for code (e.g. RL environments). [We provide an open license in Appendix B]
+(e) Add structured metadata to a dataset's meta-data page using Web standards (like schema.org and DcAT): This allows it to be discovered and organized by anyone. If you use an existing data repository, this is often done automatically. [We are in the process of building a site to host, but are happy to do this when completed.]
+(f) Highly recommended: a persistent dereferenceable identifier (e.g. a DOI minted by a data repository or a prefix on identifiers.org) for datasets, or a code repository (e.g. GitHub, GitLab,...) for code. If this is not possible or useful, please explain why. [Code and instructions will always live on GitHub].
+
+3. For benchmarks, the supplementary materials must ensure that all results are easily reproducible. Where possible, use a reproducibility framework such as the ML reproducibility checklist, or otherwise guarantee that all results can be easily reproduced, i.e. all necessary datasets, code, and evaluation procedures must be accessible and documented. [We provide access to code for experiments and will tidy and rehost upon release of the dataset.]
+
+4. For papers introducing best practices in creating or curating datasets and benchmarks, the above supplementary materials are not required.
\ No newline at end of file
diff --git a/dungeonsanddataalargescalenethackdataset/images.zip b/dungeonsanddataalargescalenethackdataset/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..699d478fd7bbb1ed3651ebeb22657e66c58a6ae9
--- /dev/null
+++ b/dungeonsanddataalargescalenethackdataset/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:82268bf969ce2b37f887799d789bcf186d246aae2c63c027fb9bed3c7d23e4d6
+size 181866
diff --git a/dungeonsanddataalargescalenethackdataset/layout.json b/dungeonsanddataalargescalenethackdataset/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..d57abe995894970c7173d7ad10544bcc103b2e9f
--- /dev/null
+++ b/dungeonsanddataalargescalenethackdataset/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1fc678a9df86522af96e308b140df4bfe2c86bae261064e7bcf59fa3d7a0bbb1
+size 357059
diff --git a/dynamicfairdivisionwithpartialinformation/bfcf9575-ec57-4370-818d-1572738087d3_content_list.json b/dynamicfairdivisionwithpartialinformation/bfcf9575-ec57-4370-818d-1572738087d3_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..bbab62e36d30cfbc73e325c4860128c7bd47a255
--- /dev/null
+++ b/dynamicfairdivisionwithpartialinformation/bfcf9575-ec57-4370-818d-1572738087d3_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:84b885fe0ebf0726aef63373f6dd7f5d811b93051c4fe4f6ea1841c3a00bc522
+size 79554
diff --git a/dynamicfairdivisionwithpartialinformation/bfcf9575-ec57-4370-818d-1572738087d3_model.json b/dynamicfairdivisionwithpartialinformation/bfcf9575-ec57-4370-818d-1572738087d3_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..1a9a8ec5f122a26bc831c20461ff78191d65bbde
--- /dev/null
+++ b/dynamicfairdivisionwithpartialinformation/bfcf9575-ec57-4370-818d-1572738087d3_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c14275f11319f5d232bdfdd46fdcff2c86a8dfaf397db66c845ad0aebde11965
+size 96501
diff --git a/dynamicfairdivisionwithpartialinformation/bfcf9575-ec57-4370-818d-1572738087d3_origin.pdf b/dynamicfairdivisionwithpartialinformation/bfcf9575-ec57-4370-818d-1572738087d3_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..278bca979fc7b5616d6309a3ee013c2b8437bdf3
--- /dev/null
+++ b/dynamicfairdivisionwithpartialinformation/bfcf9575-ec57-4370-818d-1572738087d3_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3f5f37e203406cd2c19c558419b2e017c3667c00ba9a45df664e1975f7983e04
+size 307123
diff --git a/dynamicfairdivisionwithpartialinformation/full.md b/dynamicfairdivisionwithpartialinformation/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..9cade250fdca286ff14c8214eb6d5a8e597bb5e7
--- /dev/null
+++ b/dynamicfairdivisionwithpartialinformation/full.md
@@ -0,0 +1,297 @@
+# Dynamic Fair Division with Partial Information
+
+Gerdus Benadè
+
+Boston University
+benade@bu.edu
+
+Daniel Halpern
+
+Harvard University dhalpern@g.harvard.edu
+
+Alexandros Psomas
+
+Purdue University
+apsomas@cs.perdue.edu
+
+# Abstract
+
+We consider the fundamental problem of fairly and efficiently allocating $T$ indivisible items among $n$ agents with additive preferences. The items become available over a sequence of rounds, and every item must be allocated immediately and irrevocably before the next one arrives. Previous work shows that when the agents' valuations for the items are drawn from known distributions, it is possible (under mild technical assumptions) to find allocations that are envy-free with high probability and Pareto efficient ex-post.
+
+We study a partial-information setting, where it is possible to elicit ordinal but not cardinal information. When a new item arrives, the algorithm can query each agent for the relative rank of this item with respect to a subset of the past items. When values are drawn from i.i.d. distributions, we give an algorithm that is envy-free and $(1 - \epsilon)$ -welfare-maximizing with high probability. We provide similar guarantees (envy-freeness and a constant approximation to welfare with high probability) even with minimally expressive queries that ask for a comparison to a single previous item. For independent but non-identical agents, we obtain envy-freeness and a constant approximation to Pareto efficiency with high probability. We prove that all our results are asymptotically tight.
+
+# 1 Introduction
+
+We consider the following fundamental problem in fair division. A set of $T$ indivisible items, arriving one at a time, must be allocated among a set of $n$ agents with additive preferences. The value $v_{i,t}$ that agent $i$ has for the item in round $t$ is realized once the item arrives. Each item must be allocated immediately and irrevocably upon arrival, and we ask that the overall allocation is fair and efficient.
+
+Previous work on this problem shows that, despite the uncertainty about future valuations, one can achieve simultaneous fairness and efficiency when agents' values are stochastic. Specifically, when each $v_{i,t}$ is drawn i.i.d. from a distribution $D$ , the simple algorithm that maximizes welfare — each item is allocated to the agent with the highest value — is envy-free with high probability and (obviously) ex-post Pareto efficient [DGK+14, KPW16]. The same guarantee holds for independent and non-identical agents ( $v_{i,t}$ is drawn from an agent-specific distribution $D_i$ ) for the algorithm that maximizes weighted welfare [BG22]. Even when agents' valuations for an item are correlated (but items are independent), Pareto efficiency ex-post is compatible with strong fairness guarantees ("envy-freeness with high probability or envy-freeness up-to-one item ex-post") [ZP20].
+
+Despite the computational simplicity of (most of) the aforementioned algorithms, an unappealing aspect, especially from a practical perspective, is the requirement that agents report an exact numerical value for each item. Eliciting expressive additive valuations can be impractical, e.g., due to agents' cognitive limitations. Motivated by such considerations, a growing body of work in AI studies what can be achieved by algorithms that only elicit ordinal information. This idea originates from [PR06], who defined the notion of distortion to measure the worst-case deterioration of an aggregate cardinal objective (e.g., utilitarian social welfare) due to only having access to preferences of limited expressiveness, particularly ordinal rankings. Recent works
+
+prove bounds on the distortion in the context of many problems in social choice, e.g., voting [CNPS17, GKM17, MSW20, MW19, Kem20a, Kem20b, GHS20], matching [FRFZ14], and participatory budgeting [BNPS21]; see [AFRSV21] for a recent survey.
+
+In this paper, we study the power and limits of eliciting ordinal information in dynamic fair division. The value $v_{i,t}$ of agent $i$ for item $t$ is drawn from an unknown distribution upon arrival, and the algorithm is provided, from each agent, partial ordinal information about this item, e.g., its rank relative to the past items allocated to this agent, or even just a single past item allocated to this agent. Under what distributional assumptions and elicitation constraints, can we simultaneously achieve qualitative fairness and efficiency? We answer these questions.
+
+# 1.1 Our Contribution
+
+We start by establishing a separation between the cardinal setting and our ordinal one. Pareto efficiency alone is trivial (allocate all goods to the same agent) and, in the cardinal setting, it is known that Pareto efficiency ex-post is compatible with envy-freeness with high probability (as long as agents are independent). We prove (Theorem 4) that in our setting, even for the case of two i.i.d. agents and any known distribution, envy-freeness with high probability is incompatible with even a very mild notion of (exact) Pareto efficiency, one-swap-Pareto efficiency, which requires that there is no beneficial one-to-one trade of items between agents (but allows for improvements via many-to-many trades of items).
+
+We proceed to give an essentially matching positive result. For any number of i.i.d. agents and an unknown distribution $D$ , there exists an algorithm (Algorithm 1) that is envy-free with high probability and guarantees a $(1 - \varepsilon)$ -approximation to the optimal utilitarian social welfare (the sum of utilities), for all $\varepsilon > 0$ , with high probability (Theorem 5). When an item arrives, the algorithm learns for each agent $i$ its relative rank compared to a subset of prior items allocated to agent $i$ (but otherwise knows nothing about the underlying numerical valuation). Our algorithm works in epochs. Each epoch has an exploration/sampling phase, where each agent gets a pre-determined number of items, followed by an exploitation/ranking phase, where each fresh item is given to an agent whose empirical quantile is largest. The goal is to make a sublinear number of errors compared to the "ideal" algorithm that allocates each item to the agent with the highest true quantile. The algorithm has to balance the need for sampling, which leads to more accurate empirical quantiles, against the number of inefficient allocations made while sampling. A significant technical barrier is that we cannot fix a target accuracy because the underlying distribution is unknown. That is, for every fixed accuracy for the empirical quantiles, there exists a distribution for which this accuracy is not good enough for even a constant approximation to the optimal welfare. Instead, we need to make our epochs progressively longer, thereby guaranteeing progressively better bounds.
+
+Given this strong positive result, we explore the limits of what we can achieve when further restricting the amount of information available. What if each agent can remember only a single item previously allocated to them, and the fresh item is compared to just this one item? Surprisingly, the aforementioned positive result can almost be recovered even in this very restrictive setting. We prove that there exists an algorithm (Algorithm 2) that is envy-free with high probability and guarantees a $(1 - 1 / e)^{2} - \varepsilon$ approximation to the optimal welfare with high probability, for all $\varepsilon > 0$ (Theorem 9). Our algorithm again proceeds in epochs with gradually increasing exploration and exploitation phases; this time the goal is a sublinear number of differences compared to allocating each item to a uniformly random agent with quantile at least $1 - 1 / n$ , which we prove is envy-free and approximately efficient (Lemmas 2 and 1). When exploring, the algorithm puts a new item in memory, estimates its quantile, and rejects it if not sufficiently close to $1 - 1 / n$ . We need to sample enough to ensure high confidence in the estimated quantile, but also account for the additional sampling since an item's quantile value might be far from $1 - 1 / n$ to begin with; several technical details need to be accounted for. We give a near-matching lower bound: no algorithm with a memory of one item can achieve a 0.999—approximation to the social welfare with high probability; therefore a constant approximation (which Algorithm 2 provides) is all we can hope for.
+
+Finally, we relax the i.i.d. condition and study agents that are independent but not identical; each agent $i$ 's values are drawn from an unknown distribution $D_{i}$ . Even with unbounded memory, we
+
+Table 1: Main Results
+
+| Setting | Possibility | Impossibility |
| Unbounded Memory, i.i.d. | EF + (1 - ε)-welfare (Theorem 5) | EF + PO (Theorem 4) |
| Limited Memory, i.i.d. | EF + .399-welfare (Theorem 9) | .999-welfare (Theorem 8) |
| Unbounded Memory, non-i.i.d. | EF + .367-PO (Theorem 13) | EF + .809-PO (Theorem 12) |
+
+show that it is impossible to get a $\frac{1 + \sqrt{5}}{4} \approx .809$ approximation to Pareto efficiency with probability more than 2/3, even for two agents (Theorem 12). At the same time, we prove that Algorithms 1 and 2 are envy-free and $1/e$ approximately Pareto efficient with high probability! Note that, though both algorithms give the same formal guarantees and Algorithm 2 elicits strictly less information, one might still prefer to use Algorithm 1 since it has significantly shorter exploration phases. A summary of our results can be found in Table 1
+
+We leave the study of correlated agents as an interesting open problem. Finally, we note that beyond stochastic valuations, [BKPP18] show that it is possible to achieve sublinear envy by randomly allocating every item when agents' valuations are adversarily generated (and this is optimal); however, sublinear envy is incompatible with non-trivial efficiency even in the cardinal setting [ZP20].
+
+# 1.2 Related Work
+
+A number of works study fair division under ordinal preferences, e.g., [AGMW15, BEL10, $\mathrm{BBL}^{+}17$ , NNR17], but often these models do not assume an underlying cardinal model and work directly on the ordinal preferences. [ABM16] assume underlying cardinal information and, among other results, bound the approximation ratio of truthful mechanisms that elicit rankings. Closer to our work, [HS21] study rules that have access to the ranking of the top- $k$ items of each agent and bound the ratio of the social welfare of the allocation returned by a rule in the worst case. They also characterize the value of $k$ needed to achieve prominent notions of fairness, namely envy-freeness up to one item (EF1) and approximate maximin share guarantee (MMS), as well as bound the loss in efficiency incurred due to fairness constraints in this setting.
+
+Our work contributes to the growing literature in dynamic fair division [KPS14, AAGW15, FPV15, FPV17, BKPP18, LLL18, HPPZ19, ZP20, GPT21, BKM22, GBI21, VPF21, BGGJ22, BMS22, KS22] (and we note that the welfare-maximizing algorithms of $\left[\mathrm{DGK}^{+}14\right.$ , KPW16, BG22] work in the dynamic setting, even though the their settings are not explicitly dynamic). To the best of our knowledge, we are the first to study imperfect expressivity in a dynamic setting in fair division.
+
+# 2 Preliminaries
+
+A set of $T$ indivisible items/goods, labeled by $\mathcal{G} = \{1,2,\dots ,T\}$ , needs to be allocated to a set of $n$ agents, labeled by $\mathcal{N} = \{1,\ldots ,n\}$ . Agent $i\in \mathcal{N}$ assigns a value $v_{i,t}\in [0,1]$ to item $t\in \mathcal{G}$ . We assume agents have additive valuation functions, so $v_{i}(S) = \sum_{t\in S}v_{i,t}$ for $S\subseteq \mathcal{G}$ . An allocation $A$ is a partition of the items into bundles $A_{1},\ldots ,A_{n}$ , where $A_{i}$ is the set of items assigned to agent $i\in \mathcal{N}$ . Each allocation has an associated utility profile $v(A) = (v_{1}(A_{1}),\dots,v_{n}(A_{n}))$ .
+
+Items arrive online, one per round. The agents' valuations for the item in round $t$ (the $t$ -th item) are realized when the item arrives. Every item is allocated immediately and irrevocably before moving on to the next round. We write $\mathcal{G}^t = \{1,2,\dots ,t\}$ for the set of items that arrived in the first $t$ rounds, and $A_{i}^{t}$ for the allocation of agent $i$ after the $t$ -th item was allocated. We consider two different models which specify how values are generated. In the i.i.d. model, the value of agent $i$ for item $t$ is independently drawn from an unknown distribution $D$ with CDF $F$ , i.e., $v_{i,t}\sim D$ for all $i\in \mathcal{N}$ and $t\in \mathcal{G}$ . In the non-i.i.d. model, the value of item $t$ for agent $i$ is independently drawn from an unknown, agent-dependent distribution $D_{i}$ with CDF $F_{i}$ , i.e., $v_{i,t}\sim D_{i}$ for all $i\in \mathcal{N}$ and $t\in \mathcal{G}$ . We write $X_{i}$ for the random variable for $i$ 's valuation, and $X_{i,t}$ for the random variable for $i$ 's valuation for item $t$ . It is often convenient to work directly with the quantile of an agent's value rather than the value itself; let $Q_{i} = F_{i}(X_{i})$ and $Q_{i,t} = F_{i}(X_{i,t})$ respectively be the random variable denoting the quantile of agent $i$ the associated item. Note that all $Q_{i}$ and $Q_{i,t}$ are i.i.d. and
+
+follow a Unif[0,1] distribution. Unless explicitly stated otherwise, we assume all distributions are continuous (i.e., do not have point masses).
+
+Ordinal information. We assume the realizations $v_{i,t}$ are not available. Instead, our algorithms have access to ordinal information. Specifically, given current item $t$ , the algorithm can access each agent's ranking for $S = \{t\} \cup M$ , $M \subseteq \mathcal{G}^{t-1}$ . The size of $M$ , which we will informally refer to as the memory size, determines the complexity of eliciting information from each agent. In one extreme, agent $i$ compares a new item $t$ to a single item they had previously received, i.e., $M \subseteq A_i^{t-1}, |M| \leq 1$ . In the other extreme, $t$ is compared to all previous items she received, so $M = A_i^{t-1}$ . We write $\sigma_i(S)$ for the ranking of agent $i$ for a subset $S$ of the items, and $\sigma_i^{-1}(S,t)$ for the position of item $t \in S$ with respect to a subset $S$ according to agent $i$ . The highest value item is in position 1 and the lowest in position $|S|$ . For example, if $S = \{1,4\}$ , $v_{i,1} = 1$ and $v_{i,4} = 0.1$ , $\sigma_i(S) = (1 \succ 4)$ , $\sigma_i^{-1}(S,1) = 1$ and $\sigma_i^{-1}(S,4) = 2$ .
+
+Algorithms. An algorithm $\mathcal{A}$ , in each step $t$ , queries each agent for ordinal information with respect to some subset $M$ and then makes a (possibly randomized) allocation decision based on this ordinal information and the history so far. An instance of our problem is parameterized by the number of agents $n$ and the (unknown) value distributions $D_{1}, \ldots, D_{n}$ . Let $\mathcal{E}_{P}(t)$ be the event that some algorithm satisfies property P (e.g., envy-freeness or PO or $\varepsilon$ -welfare) at time $t$ . We are interested in the probability that an algorithm satisfies certain properties in the limit, as the number of rounds tends to infinity, where the randomness is over the random choices of the algorithm as well as the randomness in the valuations.
+
+Definition 1. An algorithm satisfies $P$ with high probability if $\lim_{t\to \infty}\operatorname *{Pr}[\mathcal{E}_P(t)] = 1$ .
+
+Note that this definition of high probability allows for dependency on $n$ and the underlying distributions (i.e., they are treated as constants).
+
+Efficiency notions. An allocation $A$ Pareto dominates an allocation $A'$ , denoted $A \succ A'$ , when $v_{i}(A_{i}) \geq v_{i}(A_{i}')$ for all $i \in \mathcal{N}$ and there exists $j \in \mathcal{N}$ with $v_{j}(A_{j}) > v_{j}(A_{j}')$ . An allocation $A$ is Pareto efficient or Pareto optimal (PO) if there is no feasible (integral) allocation that Pareto dominates it. An allocation $A'$ is in the (one) swap-neighborhood of $A$ when it can be created from $A$ with a single exchange of items between one pair of agents. Formally, there exist $i, j \in \mathcal{N}$ and items $z_{j} \in A_{j}$ and $z_{i} \in A_{i}$ so that $A_{i}' = (A_{i} \setminus \{z_{i}\}) \cup \{z_{j}\}$ , $A_{j}' = (A_{j} \setminus \{z_{j}\}) \cup \{z_{i}\}$ , and $A_{k}' = A_{k}$ for all other agents $k \neq i, j$ . An allocation $A$ is one-swap Pareto optimal (SPO) if it is undominated by any allocation in its swap-neighborhood. We use a notion of approximate efficiency defined by [RF90] according to which an allocation $A$ is $\alpha$ -Pareto efficient when $v(A)/\alpha$ is undominated.
+
+The social welfare of an allocation $A$ is $\mathsf{sw}(A) = \sum_{i\in \mathcal{N}}v_i(A_i)$ . Let allocation $A^{*}$ denote a (social) welfare optimal allocation for which $\mathsf{sw}(A^{*})\geq \mathsf{sw}(A)$ for all feasible allocations $A$ . An allocation provides an $\alpha$ -approximation to welfare if $\mathsf{sw}(A)\geq \alpha \cdot \mathsf{sw}(A^{*})$ .
+
+Fairness notions. We focus on a prominent notion of fairness called envy-freeness. An allocation $A^T = (A_1^T, \ldots, A_n^T)$ of $T$ items is envy-free (EF) when $v_i(A_i^T) \geq v_i(A_j^T)$ for all $i, j \in \mathcal{N}$ , and $c$ -strongly-envy-free ( $c$ -strong-EF) when $v_i(A_i) \geq v_i(A_j) + cT$ .
+
+# 3 Ideal Quantile-based Algorithms.
+
+For our analysis, it will be useful to compare our algorithms with ideal algorithms that know exact quantile values for every item (and, in fact, several of our lower bounds apply to these stronger algorithms too). Two ideal algorithms of interest are (1) quantile maximization, which allocates each item to the agent with the highest quantile value for it, and (2) "q-threshold," which allocates each item uniformly at random among agents whose quantile is at least $q$ (and uniformly at random over all agents, if all quantile values are less than $q$ ).
+
+In the i.i.d. model, quantile maximization is the same as value maximization, and thus envy-free with high probability and ex-post welfare optimal. The property we will use is $c$ -strong envy-freeness, for some distribution-dependent constant $c$ , which we state as Lemma 1. This was essentially proved by [DGK+14]; we provide an alternate proof that also works, essentially unchanged, for the $\frac{n-1}{n}$ -threshold algorithm; it can be found in Appendix A.1. The main idea is that an agent's value for
+
+an item conditioned on them receiving it is strictly larger than their value for an item received by another agent. Combined with the fact that the probability of receiving an item is equal for all agents, standard concentration results ensure each agent strictly prefers their own bundle with high probability.
+
+Lemma 1. [Essentially $[DGK^{+}14]$ .] In the i.i.d. and non-i.i.d. models, the quantile maximization algorithm and the $\frac{n - 1}{n}$ -threshold algorithm are $c$ -strongly-envy-free, with high probability, where the constant $c = \min_{i\in \mathcal{N}}(\mathbb{E}[X_i\mid Q_i\geq 1 / 2] - \mathbb{E}[X_i]) / (4n)$ .
+
+Note that $c$ is strictly positive since our distributions are continuous. In the i.i.d. model, we show that the $\frac{n - 1}{n}$ -threshold algorithm gives a $\left(1 - \frac{1}{e}\right)^2 - \varepsilon$ approximation to welfare (Lemma 2) with high probability.
+
+Next, we prove that the $\frac{n - 1}{n}$ -threshold algorithm guarantees a constant approximation to welfare. The main idea for this proof is that, with constant probability, some agent has a quantile of at least $\frac{n - 1}{n}$ for each item. Additionally, giving an item to an agent with quantile at least $\frac{n - 1}{n}$ generates within a constant factor amount of welfare as giving it to the agent with the highest welfare.
+
+Lemma 2. In the i.i.d. model, the $\frac{n - 1}{n}$ -threshold algorithm guarantees a (1 - $\frac{1}{e}$ )-approximation to welfare, with high probability, for all $\varepsilon > 0$ .
+
+Proof. Let $F$ be the CDF of an arbitrary continuous distribution. The expected contribution of an item to the welfare of the threshold algorithm is at least
+
+$$
+\underset {Q \sim \operatorname {U n i f} [ 0, 1 ]} {\mathbb {E}} \left[ F ^ {- 1} (Q) \mid Q \geq \frac {n - 1}{n} \right] \cdot \Pr_ {\vec {Q} \sim \operatorname {U n i f} [ 0, 1 ] ^ {n}} \left[ \max _ {i \in \mathcal {N}} Q _ {i} \geq \frac {n - 1}{n} \right].
+$$
+
+For the first term we have
+
+$$
+\begin{array}{l} \underset {Q \sim \operatorname {U n i f} [ 0, 1 ]} {\mathbb {E}} \left[ F ^ {- 1} (Q) \mid Q \geq \frac {n - 1}{n} \right] = \underset {Q \sim \operatorname {U n i f} \left[ \frac {n - 1}{n}, 1 \right]} {\mathbb {E}} \left[ F ^ {- 1} (Q) \right] \\ = \left(\int_ {\frac {n - 1}{n}} ^ {1} F ^ {- 1} (q) \cdot f _ {\text {U n i f} \left[ \frac {n - 1}{n}, 1 \right]} (q) \mathrm {d} q\right) \\ = \left(\int_ {\frac {n - 1}{n}} ^ {1} F ^ {- 1} (q) \cdot n \mathrm {d} q\right) \\ \geq^ {(f _ {\operatorname {B e t a} [ n, 1 ]} (x) = n x ^ {n - 1})} \left(\int_ {\frac {n - 1}{n}} ^ {1} F ^ {- 1} (q) \cdot f _ {\operatorname {B e t a} [ n, 1 ]} (q) \mathrm {d} q\right) \\ = \underset {Q \sim \operatorname {B e t a} [ n, 1 ]} {\mathbb {E}} \left[ F ^ {- 1} (Q) \mid Q \geq \frac {n - 1}{n} \right] \cdot \underset {Q \sim \operatorname {B e t a} [ n, 1 ]} {\operatorname * {P r}} \left[ Q \geq \frac {n - 1}{n} \right] \\ \geq \mathbb {E} _ {Q \sim \operatorname {B e t a} [ n, 1 ]} \left[ F ^ {- 1} (Q) \right] \cdot \Pr_ {Q \sim \operatorname {B e t a} [ n, 1 ]} \left[ Q \geq \frac {n - 1}{n} \right] \\ = \underset {\vec {Q} \sim \operatorname {U n i f} [ 0, 1 ] ^ {n}} {\mathbb {E}} \left[ F ^ {- 1} \left(\max _ {i \in \mathcal {N}} Q _ {i}\right) \right] \cdot \underset {\vec {Q} \sim \operatorname {U n i f} [ 0, 1 ] ^ {n}} {\operatorname * {P r}} \left[ \max _ {i \in \mathcal {N}} Q _ {i} \geq \frac {n - 1}{n} \right], \\ \end{array}
+$$
+
+where we used the fact that the maximum of $n$ draws from $U[0,1]$ follows a $\mathrm{Beta}(n,1)$ . The expected contribution to the welfare is thus at least
+
+$$
+\underset {\vec {Q} \sim \mathrm {U n i f} [ 0, 1 ] ^ {n}} {\mathbb {E}} \left[ F ^ {- 1} (\max _ {i \in \mathcal {N}} Q _ {i}) \right] \left(1 - \left(1 - \frac {1}{n}\right) ^ {n}\right) ^ {2} \geq \left(1 - \frac {1}{e}\right) ^ {2} \underset {\vec {Q} \sim \mathrm {U n i f} [ 0, 1 ] ^ {n}} {\mathbb {E}} \left[ F ^ {- 1} (\max _ {i \in \mathcal {N}} Q _ {i}) \right]
+$$
+
+Finally, for any fixed $\varepsilon > 0$ , standard Chernoff bounds tell us that with high probability, the optimal welfare of $T$ items is at most $T \cdot (1 + \varepsilon / 2) \mathbb{E}_{\vec{Q} \sim \mathrm{Unif}[0,1]^n} [F^{-1}(\max_{i \in \mathcal{N}} Q_i)]$ while the welfare of the threshold algorithm is at least $T \cdot (1 - \varepsilon / 2) \left(1 - \frac{1}{e}\right)^2 [\mathbb{E}_{\vec{Q} \sim \mathrm{Unif}[0,1]^n} [F^{-1}(\max_{i \in \mathcal{N}} Q_i)]$ . Indeed, the expected optimal welfare is equal to $T \cdot \mathbb{E}_{\vec{Q} \sim \mathrm{Unif}[0,1]^n} [F^{-1}(\max_{i \in \mathcal{N}} Q_i)]$ , the sum of $T$ i.i.d. random variables with expectation $\mathbb{E}_{\vec{Q} \sim \mathrm{Unif}[0,1]^n} [F^{-1}(\max_{i \in \mathcal{N}} Q_i)]$ . The standard multiplicative
+
+Chernoff bound says that the sum of i.i.d. variables exceeds $(1 + \epsilon /2)$ times its expectation $\mu$ is at most $\exp (-\mu \epsilon^2 /12)$ . Plugging in $\mu = T\cdot \mathbb{E}_{\vec{Q}\sim \mathrm{Unif}[0,1]^n}\left[F^{-1}(\max_{i\in \mathcal{N}}Q_i)\right]$ , we get the desired statement. The statement about the welfare of the threshold algorithm follows similarly. Thus, the algorithm is a
+
+$$
+\left(1 - \frac {1}{e}\right) ^ {2} \cdot (1 - \varepsilon / 2) / (1 + \varepsilon / 2) \geq \left(1 - \frac {1}{e}\right) ^ {2} (1 - \varepsilon) \geq \left(1 - \frac {1}{e}\right) ^ {2} - \varepsilon
+$$
+
+approximation to welfare, with high probability.
+
+
+
+Finally, we prove that both ideal algorithms are approximately efficient. Let $\mathcal{P}^*$ be the following property of an allocation: all items such that exactly one agent has quantile values at least $1 - 1/n$ are in the bundle of this agent. Both ideal algorithms (quantile maximization and $1 - 1/n$ -threshold) satisfy $\mathcal{P}^*$ . We prove that, in the non-i.i.d. model, $\mathcal{P}^*$ implies an almost $1/e$ approximation to efficiency. Our proof uses the fact that there is a (roughly) $1/e$ probability that exactly one agent has the high quantile, so the value of an agent's bundle in an algorithm that satisfies $\mathcal{P}^*$ is, with high probability, a $1/e$ approximation to their value for their $T/n$ most valuable items. Therefore, when considering an alternate allocation $A'$ , the agent in $A'$ that gets at most $T/n$ items cannot be improved upon by more than a $1/e$ factor. The proof can be found in Appendix A.2.
+
+Lemma 3. In the non-i.i.d. model, every algorithm whose allocations satisfy $\mathcal{P}^*$ is $(1/e - \varepsilon)$ -Pareto optimal, with high probability, for all $\varepsilon > 0$ .
+
+# 4 Unbounded Memory in the I.I.D. Model
+
+We explore some fundamental limits of our setting. Efficiency by itself is easy: allocate all items to the same agent. However, in contrast to the cardinal setting, we find one-swap Pareto efficiency is incompatible with envy-freeness with high probability, even for two i.i.d. agents, and even when the underlying distribution is known.
+
+Theorem 4. In the i.i.d. model, even for $n = 2$ agents, there does not exist an algorithm $\mathcal{A}$ which is one-swap Pareto efficient and envy-free with high probability, even when values are sampled according to $D$ , for any continuous, bounded and known value distribution $D$ .
+
+The proof can be found in Appendix B.1. The main idea is the following. As the agents are a priori identical, we can assume without loss of generality that $\mathcal{A}$ gives the first item to agent 1. The proof shows that, with positive probability, this decision becomes an irrevocable "mistake," in the sense that agent 2 really liked the item and agent 1 did not. This mistake will make envy-freeness and one-swap-Pareto efficiency incompatible.
+
+Theorem 4 implies that when we have access to only ordinal information, we need to settle for some approximation to envy-freeness and efficiency. Our main positive result for this section is an algorithm that essentially matches the aforementioned lower bound.
+
+Theorem 5. In the i.i.d. model, Algorithm 1 achieves envy-freeness and a $(1 - \varepsilon)$ approximation to welfare, with high probability, for all $\varepsilon > 0$ .
+
+Algorithm 1 works in epochs: each epoch $k$ has an exploration/sampling phase, where each agent $i$ receives a pre-determined set of items, denoted $G_{i}^{k}$ , irrespective of their valuation. This is followed by an exploitation/ranking phase, where each item is given to the agent with the highest empirical quantile (with respect to items received in the preceding exploration phase, i.e. $G_{i}^{k}$ ). The key idea for the proof is that the exploration phases will ensure nearly all of the items will go to the agent that truly has the highest quantile. Using this, the good properties of the ideal quantile maximization algorithm will carry over to Algorithm 1.
+
+We start with a technical lemma, which gives us a bound on the length of the exploration period we need in each epoch. The following definition will be useful.
+
+Definition 2. A sample of $n \cdot m$ items (where each agent is allocated exactly $m$ items) is $\varepsilon$ -accurate if, with probability at least $1 - \varepsilon$ , the relative rank of a fresh item (with respect to the sample) is highest for the agent with highest quantile value.
+
+Lemma 6. If $\varepsilon, \delta \in (0,1)$ , and $m \in \mathbb{Z}^+$ are such that $\varepsilon > 2n\sqrt{\frac{\ln(2n / \delta)}{2m}}$ , then giving $m$ samples to each agent is $\varepsilon$ -accurate with probability at least $1 - \delta$ .
+
+Algorithm 1: EF + (1 - ε)-Welfare
+for epoch $k = 1\dots$ do Sampling Phase: $(n\cdot k^4$ items) Give the $j$ -th item in this phase to agent $j(\mathrm{mod}~n)$ Ranking Phase: $(k^{8}$ items) for each item $g$ in this phase do Elicit $\sigma_{i}^{-1}(G_{i}^{k}\cup \{g\} ,g)$ for all $i\in \mathcal{N}$ . Allocate $g$ to an agent $j\in \arg \min_{i\in \mathcal{N}}\sigma_i^{-1}(G_i^k\cup \{g\} ,g)$
+
+Proof. We will use the Dvoretzky-Kiefer-Wolffowitz (DKW) inequality [DKW56, Mas90] to show the empirical CDF of sampled quantiles is reasonably close to a uniform distribution with probability $1 - \delta$ . We then show this is sufficient to guarantee $\varepsilon$ -accuracy for the chosen $\varepsilon$ . Let $\hat{F}_i$ be the empirical CDF of the sampled quantiles for agent $i$ , i.e., $\hat{F}_i(q)$ for $q \in [0,1]$ is a random variable that describes the proportion of sampled items with quantile at most $q$ . Note that $\hat{F}_i$ exactly captures agent $i$ 's ranking for a new item: if a fresh item has quantile $q_i$ for agent $i$ and $q_j$ for agent $j$ , then $i$ ranks it higher than $j$ exactly when $\hat{F}_i(q_i) > \hat{F}_j(q_j)$ .
+
+Noting that the CDF for the actual quantile distribution (i.e., the uniform distribution) is the identity on $[0,1]$ , the DKW inequality states that for all $\gamma > 0$ , $\operatorname*{Pr}\left[\sup_{q \in [0,1]} |\hat{F}_i(q) - q| > \gamma \right] \leq 2e^{-2m\gamma^2}$ . We want this condition to hold for all $n$ agents, simultaneously, with probability at least $1 - \delta$ , so we pick $\gamma$ such that $2e^{-2m\gamma^2} \leq \delta / n$ and apply a union bound; it suffices to choose $\gamma = \sqrt{\frac{\ln(2n / \delta)}{2m}}$ .
+
+We now show that the DKW condition $(\sup_{q\in [0,1]}|\hat{F}_i(q) - q|\leq \gamma)$ being satisfied for all agents $i$ is sufficient to guarantee $\varepsilon$ -accuracy. Consider sampling quantiles $Q_{1},\ldots ,Q_{n}$ for a fresh item. Let $i^{\max}\in \operatorname{argmax}_{i\in \mathcal{N}}Q_i$ be a quantile-maximizing agent (technically a random variable). Our goal is to show that with probability at least $1 - \varepsilon$ (with respect to the samples of $Q_{1},\ldots ,Q_{n}$ ) $\hat{F}_{i^{\max}}(Q_{i^{\max}}) > \hat{F}_j(Q_j)$ for all $j\neq i^{\max}$ . This ensures that $i^{\max}$ has the highest empirical rank, and hence receives the item. Let $Q_{(1)},\ldots ,Q_{(n)}$ be the respective order statistics. A key observation is that $Q_{(n)} - Q_{(n - 1)}\sim \mathrm{Beta}[1,n]$ [Gen19]. The PDF of a Beta[1,n] distribution is $f(x) = nx^{n - 1}$ for $x\in [0,1]$ . Since $f(x)\leq n$ , $\operatorname*{Pr}\bigl [Q_{(n)} - Q_{(n - 1)} < \rho \bigr ] < n\rho$ for all $\rho >0$ . Plugging in $\rho = 2\gamma$ , we have $\operatorname*{Pr}\bigl [Q_{(n)} - Q_{(n - 1)}\leq 2\gamma \bigr ] < 2n\gamma$ . We will show that as long as $\varepsilon >2n\gamma$ , $\varepsilon$ -accuracy holds. First, we have $\operatorname*{Pr}\bigl [Q_{(n)} - Q_{(n - 1)} > 2\gamma \bigr ] > 1 - \varepsilon$ . Conditioned on $Q_{(n)} - Q_{(n - 1)} > 2\gamma$ , the item is given to $i^{\max}$ . To see why, observe $Q_{i^{\max}} = Q_{(n)}$ and $Q_{j}\leq Q_{(n - 1)}$ for all $j\neq i^{\max}$ , by definition. Using the DKW inequality condition, it follows that $\hat{F}_{i^{\max}}(Q_{i^{\max}})\geq Q_{i^{\max}} - \gamma >Q_{j} + \gamma \geq \hat{F}_{j}(Q_{j})$ . We conclude that for $\varepsilon >2n\sqrt{\frac{\ln(2n / \delta)}{2m}}$ , $\varepsilon$ -accuracy is satisfied with probability at least $1 - \delta$ .
+
+Using Lemma 6, we can get, for each epoch, a bound on the number of decisions where Algorithm 1 differs from the quantile maximization algorithm.
+
+Lemma 7. The allocation of Algorithm 1 differs from that of the quantile maximization algorithm after $T$ steps by at most $f(T)$ items with high probability, where $f(T) \in O(poly(n) \cdot T^{15/16})$ .
+
+Proof. We start by bounding the accuracy of Algorithm 1 in each epoch $k$ . In epoch $k$ , each agent receives $k^4$ items during the sampling phase. We claim that the sample in epoch $k$ for $k \geq 3n$ is $\varepsilon_k$ -accurate for $\varepsilon_k := 3n / k^{3/2}$ with probability at least $1 - \delta_k$ , for $\delta_k := 2n / e^{2k}$ . Indeed, first note that by the choice of $k$ , we have that $\varepsilon_k, \delta_k \in (0,1)$ . Hence, we just need to show that these values satisfy the inequality of Lemma 6. We have that
+
+$$
+\varepsilon_ {k} = \frac {3 n}{k ^ {3 / 2}} > \frac {2 n}{k ^ {3 / 2}} = 2 n \sqrt {\frac {1}{k ^ {3}}} = 2 n \sqrt {\frac {\ln (e ^ {2 k})}{2 k ^ {4}}} = 2 n \sqrt {\frac {\ln (2 n / \delta_ {k})}{2 k ^ {4}}}.
+$$
+
+Next, fix a time $T$ . Slightly abusing notation, let $k(t) = \min \{K \in \mathbb{N} | \sum_{k=1}^{K} nk^4 + k^8 \geq t\}$ be the function that given an item $t$ returns the epoch item $t$ is in. Notice that $T \geq \sum_{k=1}^{k(T)-1} nk^4 + k^8 \geq$
+
+$(k(T) - 1)^{8}$ , and therefore $k(T) \leq 2T^{1/8}$ . In any run of the algorithm, we can classify every item $t \leq T$ into one of four categories.
+
+1. Item $t$ was allocated in one of the first $3n - 1$ epochs, that is, $k(t) < 3n$ .
+2. Item $t$ was allocated in the sampling phase of epoch $k(t) \geq 3n$ .
+3. Item $t$ was allocated in the ranking phase of epoch $k(t) \geq 3n$ ; the epoch was $\varepsilon_{k(t)}$ -accurate.
+4. Item $t$ was allocated in the ranking phase of epoch $k(t) \geq 3n$ ; the epoch was not $\varepsilon_{k(t)}$ -accurate.
+
+We say an item $t$ was a mistake if it was given to an agent with a non-maximum quantile for it. We show that the number of mistakes in each category are bounded by $3^{10}n^9, 2nT^{5/8}, 9nT^{15/16}$ , and $158n\ln(T)$ respectively, with high probability. This implies that the total number of mistakes is at most the sum of these quantities, which is $O(\mathrm{poly}(n)\cdot T^{15/16})$ , with high probability, via a union bound.
+
+The number of items in the first category is at most
+
+$$
+\sum_ {k = 1} ^ {3 n - 1} k ^ {4} n + k ^ {8} \leq \sum_ {k = 1} ^ {3 n} (3 n) ^ {4} n + (3 n) ^ {8} \leq (3 n) ^ {5} n + (3 n) ^ {9} \leq 3 ^ {1 0} n ^ {9}.
+$$
+
+Hence, the number of mistakes in the first category is also at most $3^{10}n^9$ .
+
+For the second category, since $k(T) \leq 2T^{1/8}$ , we have that the total number of items in the sampling phase is (with probability 1) upper bounded by
+
+$$
+\sum_ {k = 1} ^ {k (T)} n k ^ {4} \leq n k (T) ^ {5} \leq 2 n T ^ {5 / 8}.
+$$
+
+Each item $t$ in the third category has probability $\varepsilon_{k(t)}$ of being a mistake. The expected number of mistakes is therefore at most $\sum_{k = 3n}^{k(T)}\varepsilon_{k(t)}k^8 = \sum_{k = 3n}^{k(T)}3nk^{13 / 2}\leq 3nk(T)^{15 / 2}\leq 8nT^{15 / 16}$ . Using Hoeffding's inequality we get that with high probability the number of mistakes is at most $9nT^{15 / 16}$ , since a deviation of $nT^{15 / 16}$ occurs with probability at most $\exp \left(-2n^{2}T^{15 / 8} / T\right) = \exp \left(-2n^{2}T^{7 / 8}\right)$ .
+
+For the fourth category, the expected number of items is at most $\sum_{k=3n}^{k(T)} \delta_k k^8 = 2n \sum_{k=3n}^{k(T)} \frac{k^8}{e^{2k}} \leq 2n \sum_{k=1}^{\infty} \frac{k^8}{e^{2k}} \leq 158n$ . Using Markov's inequality we have that the number of mistakes is at most $158n \ln(T)$ with probability at least $1 - \ln(T)$ , i.e., with high probability.
+
+Finally, we can prove Theorem 5 as a relatively straightforward consequence of Lemma 7, since the ideal quantile maximization algorithm satisfies nice properties (e.g., Lemma 1). The full proof can be found in Appendix B.2.
+
+# 5 Bounded Memory in the I.I.D. Model
+
+In this section, we are interested in the more ambitious problem of designing dynamic algorithms with even more limited partial information: each agent is allowed to "remember" only a single item. We first show that, in this case, we need to settle for constant approximations of welfare. The main idea of the proof is a difficult value distribution. Agents have essentially one of three values, low, medium, high. The key idea is that no matter what quantile thresholds an algorithm has, it will either be the case that with reasonable probability, the highest value agent has medium value but is indistinguishable from all low value agents, or the highest value agent has high value, but is indistinguishable from all medium or low value agents. In either case, the algorithm will make a mistake with constant probability, and hence cannot guarantee close to optimal welfare. The full proof can be found in Appendix C.1.
+
+Theorem 8. In the i.i.d. model, given a memory of one item per agent, there is no algorithm $\mathcal{A}$ that is .999-welfare maximizing with high probability for all continuous and bounded value distributions.
+
+Algorithm 2: Bounded Memory
+for Epoch $k = 1\dots$ do Sampling Phase: $(k^9$ items) NOTWITHINERROR $\leftarrow \mathcal{N}$ for trial $= 1,\dots ,k^{3}$ do for $i\in \mathrm{NOTWITINERROR}$ do | Allocate the next item to agent $i$ , and update her memory Test $k^6 -|$ NOTWITHINERROR| number of items (for each agent) for $i\in \mathrm{NOTWITINERROR}$ do if Proportion of test items for agent i is within $\pm 1 / k^2$ of $(n - 1) / n$ then | NOTWITHINERROR $\leftarrow$ NOTWITHINERROR\{i}
+Ranking Phase: $(k^{18}$ items) for each item g in this phase do if Some agent i has high signal then Give g to a (uniformly) random such agent else Give g to an agent uniformly at random
+
+Our positive result matches this lower bound up to a constant.
+
+Theorem 9. In the i.i.d. model, given a memory of one item per agent, Algorithm 2 achieves envy-freeness and $a(1 - 1 / e)^2 - \varepsilon$ approximation to welfare, with high probability, for all $\varepsilon > 0$ .
+
+Algorithm 2 works in epochs, similar to Algorithm 1. In each epoch's exploration/sampling phase, it tries to find an item whose quantile is close to the $\frac{n - 1}{n}$ -threshold algorithm. Epoch $k$ makes $k^3$ such attempts, and each candidate item is tested against $k^6$ fresh items to get an estimated quantile. If everything is within the error we can tolerate, the algorithm remembers this item for this epoch; otherwise, the agent has an arbitrary item in memory during this epoch. During the exploitation/ranking phase, Algorithm 2 tries to mimic the $\frac{n - 1}{n}$ -threshold algorithm (instead of the quantile maximization algorithm as Algorithm 1 did), and, in fact, inherits its approximation factor (Lemma 2) exactly.
+
+Our first technical lemma, Lemma 10, gives necessary bounds on the various variables of Algorithm 2 for a sample to be $\varepsilon$ -accurate with respect to the ideal threshold algorithm; see Definition 3. Its proof can be found in Appendix C.2.
+
+Definition 3. A set of $n$ items in memory, one for each agent, is $\varepsilon$ -accurate with respect to $q^*$ if with probability at least $1 - \varepsilon$ , when a fresh item is sampled, the agents with true quantile above $q^*$ are exactly those that value the fresh item more than their item in memory.
+
+Lemma 10. For all $\varepsilon, \delta \in (0,1)$ , if (1) at least $\tau$ trials are done with $\tau \geq \frac{\ln(2n / \delta)}{\varepsilon / (3n)}$ , and (2) at least $\ell$ test items are used per trial for $\ell \geq \frac{18n^2}{\varepsilon^2} \ln \left(\frac{4\tau n}{\delta}\right)$ , and (3) the tolerance for accepting an item is $\varepsilon / (3n)$ , then the items in memory are $\varepsilon$ -accurate (for all agents, simultaneously) with respect to $q^* = \frac{n - 1}{n}$ , with probability at least $1 - \delta$ .
+
+Though Lemmas 6 and 10 resemble each other (and are used in analogous ways), the proofs require different techniques, as the sampling processes are very different. Next, we prove an analogue to Lemma 7: the number of disagreements between Algorithm 2 and the ideal threshold algorithm is sublinear. The proofs of Lemmas 7 and 11 are similar, precisely because Lemma 6 matches Lemma 10. Theorem 9 follows from Lemma 11 as in the i.i.d. case. The proofs of Lemma 11 and Theorem 9 can be found in Appendices C.3 and C.4 respectively.
+
+Lemma 11. The allocation of Algorithm 2 differs from that of the $\frac{n - 1}{n}$ -threshold algorithm after $T$ steps by at most $f(T)$ items with high probability, where $f(T) \in O(poly(n) \cdot T^{17/18})$ .
+
+# 6 The Non-I.I.D. Model
+
+In this section, we study the non-i.i.d. model. We first establish a strong lower bound for the non-i.i.d. model. The following negative result holds even for algorithms that know the associated quantile for every fresh item.
+
+Theorem 12. Even for 2 non-identical agents, there is no algorithm that is $EF$ and $c - PO$ with probability $p$ , for $c > \frac{1 + \sqrt{5}}{4} \approx .809$ and $p > 2/3$ , for all continuous and bounded value distributions.
+
+Here we provide a proof sketch of Theorem 12. The full proof can be found in Appendix D.1.
+
+Proof Sketch. The main idea is that an algorithm, even if it can see the exact quantiles of all items, cannot distinguish between agents having potentially different kinds of distributions. At one extreme end, agents may have nearly identical values for all items. On the other extreme, agents may only care (i.e., have high value) for, say, their top third of items.
+
+Consider the case of two agents. Notice that if both agents have nearly identical values for all items, to be EF, the bundle sizes of both agents must be approximately the same. We can then show that, no matter how an algorithm does this, it must be the case that one agent, say agent 1, receives a significant number of items with quantile outside of their top third does not receive a significant number of items with quantile in their top third.
+
+However, suppose instead the value distributions were such that agent 2 still has nearly identical values for all items, but agent 1 only has high value for their top-third items. In the setting described above, agent 1 would be willing to trade many of their bottom two-third quantile items for the items agent 2 received in their top third. By setting up this trade correctly, both agents total utilities go up by a significant amount. The existence of such a trade violates constant approximations to PO.
+
+Algorithms 1 and 2 are envy-free with high probability, even in the non-i.i.d. model, since envy-freeness is not an "inter-agent" property. Our last result shows that they also give a constant approximation to Pareto efficiency, by combining Lemma 3 with Lemmas 7 and 11. Its proof can be found in Appendix D.2.
+
+Theorem 13. In the non-i.i.d. model, both Algorithm 1 (unbounded memory) and Algorithm 2 (one-item memory) are $EF$ and $(1 / e - \varepsilon)$ -PO, with high probability, for all $\varepsilon > 0$ .
+
+Interestingly, the guarantees for Algorithm 2 in the non-i.i.d. model are only marginally worse compared to the i.i.d. model; the approximation ratio decreases from $(1 - 1 / e)^{2} \approx 0.4$ to $1 / e \approx 0.37$ . Finally, we note that, even though the formal guarantees in Theorem 13 are the same for the two algorithms, and even though Algorithm 2 uses memory size of one, Algorithm 1 has the benefit of much shorter epoch lengths (in addition to better guarantees under the i.i.d. model).
+
+# 7 Conclusion
+
+To conclude, we have analyzed the online fair division problem when agents only reveal partial information. In multiple settings, we have proved tight bounds on what properties are attainable. As for future work, one direction would be to move past the assumption that agent values are drawn independently, as we may not expect this to hold in practice. Additionally, there are many other forms of partial information that could potentially achieve different properties. For example, if agents can compare not just single items but small subsets of items, then it may be possible to achieve stronger results such as arbitrarily good approximations to PO even in the non-i.i.d. setting.
+
+# Acknowledgements
+
+Alexandros Psomas is supported in part by an NSF CAREER award CCF-2144208, a Google Research Scholar Award, and by the Algorand Centres of Excellence program managed by Algorand Foundation. Any opinions, findings, and conclusions or recommendations expressed in this material are those of the author(s) and do not necessarily reflect the views of Algorand Foundation. This material is based upon work supported by the National Science Foundation Graduate Research Fellowship Program under Grant No. DGE1745303.
+
+# References
+
+[AAGW15] Martin Damyanov Aleksandrov, Haris Aziz, Serge Gaspers, and Toby Walsh. Online fair division: Analysing a food bank problem. In Proceedings of the 24th International Joint Conference on Artificial Intelligence (IJCAI), pages 2540-2546, 2015.
+[ABM16] Georgios Amanatidis, Georgios Birmpas, and Evangelos Markakis. On truthful mechanisms for maximin share allocations. In Proceedings of the 25th International Joint Conference on Artificial Intelligence (IJCAI), pages 31-37, 2016.
+[AFRSV21] Elliot Anshelevich, Aris Filos-Ratsikas, Nisarg Shah, and Alexandros A Voudouris. Distortion in social choice problems: the first 15 years and beyond. In Proceedings of the 30th International Joint Conference on Artificial Intelligence (IJCAI), pages 4294-4301, 2021.
+[AGMW15] Haris Aziz, Serge Gaspers, Simon Mackenzie, and Toby Walsh. Fair assignment of indivisible objects under ordinal preferences. Artificial Intelligence, 227:71-92, 2015.
+$\left[\mathrm{BBL}^{+}17\right]$ Dorothea Baumeister, Sylvain Bouveret, Jérôme Lang, Nhan-Tam Nguyen, Trung Thanh Nguyen, Jörg Rothe, and Abdallah Saffidine. Positional scoring-based allocation of indivisible goods. Autonomous Agents and Multi-Agent Systems, 31(3):628-655, 2017.
+[BEL10] Sylvain Bouveret, Ulle Endriss, and Jérôme Lang. Fair division under ordinal preferences: Computing envy-free allocations of indivisible goods. In Proceedings of the 19th European Conference on Artificial Intelligence (ECAI), pages 387-392, 2010.
+[BG22] Yushi Bai and Paul Gölz. Envy-free and pareto-optimal allocations for agents with asymmetric random valuations. In Proceedings of the 32nd International Joint Conference on Artificial Intelligence (IJCAI), 2022. Forthcoming.
+[BGGJ22] Siddhartha Banerjee, Vasilis Gkatzelis, Artur Gorokh, and Billy Jin. Online nash social welfare maximization with predictions. In Proceedings of the 33rd Annual ACM-SIAM Symposium on Discrete Algorithms (SODA), pages 1-19, 2022.
+[BKM22] Siddharth Barman, Arindam Khan, and Arnab Maiti. Universal and tight online algorithms for generalized-mean welfare. In Proceedings of the 36th AAAI Conference on Artificial Intelligence (AAAI), 2022. forthcoming.
+[BKPP18] Gerdus Benade, Aleksandr M Kazachkov, Ariel D Procaccia, and Christos-Alexandros Psomas. How to make envy vanish over time. In Proceedings of the 10th ACM Conference on Economics and Computation (EC), pages 593-610, 2018.
+[BMS22] Anna Bogomolnaia, Hervé Moulin, and Fedor Sandomirskiy. On the fair division of a random object. Management Science, 68(2):1174-1194, 2022.
+[BNPS21] Gerdus Benade, Swaprava Nath, Ariel D Procaccia, and Nisarg Shah. Preference elicitation for participatory budgeting. Management Science, 67(5):2813-2827, 2021.
+[CNPS17] Ioannis Caragiannis, Swaprava Nath, Ariel D Procaccia, and Nisarg Shah. Subset selection via implicit utilitarian voting. Journal of Artificial Intelligence Research, 58:123-152, 2017.
+[DGK+14] John P. Dickerson, Jonathan Goldman, Jeremy Karp, Ariel D Procaccia, and Tuomas Sandholm. The computational rise and fall of fairness. In Proceedings of the 28th AAAI Conference on Artificial Intelligence (AAAI), pages 1405-1411, 2014.
+[DKW56] Aryeh Dvoretzky, Jack Kiefer, and Jacob Wolfowitz. Asymptotic minimax character of the sample distribution function and of the classical multinomial estimator. The Annals of Mathematical Statistics, pages 642-669, 1956.
+
+[FPV15] Eric Friedman, Christos-Alexandros Psomas, and Shai Vardi. Dynamic fair division with minimal disruptions. In Proceedings of the 16th ACM Conference on Economics and Computation (EC), pages 697-713, 2015.
+[FPV17] Eric Friedman, Christos-Alexandros Psomas, and Shai Vardi. Controlled dynamic fair division. In Proceedings of the 18th ACM Conference on Economics and Computation (EC), pages 461-478, 2017.
+[FRFZ14] Aris Filos-Ratsikas, Søren Kristoffer Stil Frederiksen, and Jie Zhang. Social welfare in one-sided matchings: Random priority and beyond. In Proceedings of the 7th International Symposium on Algorithmic Game Theory (SAGT), pages 1-12, 2014.
+[GBI21] Artur Gorokh, Siddhartha Banerjee, and Krishnamurthy Iyer. From monetary to non-monetary mechanism design via artificial currencies. Mathematics of Operations Research, 2021.
+[Gen19] James E Gentle. Computational statistics. Springer, 2019.
+[GHS20] Vasilis Gkatzelis, Daniel Halpern, and Nisarg Shah. Resolving the optimal metric distortion conjecture. In Proceedings of the 61st Symposium on Foundations of Computer Science (FOCS), pages 1427-1438, 2020.
+[GKM17] Ashish Goel, Anilesh K Krishnaswamy, and Kamesh Munagala. Metric distortion of social choice rules: Lower bounds and fairness properties. In Proceedings of the 18th ACM Conference on Economics and Computation (EC), pages 287-304, 2017.
+[GPT21] Vasilis Gkatzelis, Alexandros Psomas, and Xizhi Tan. Fair and efficient online allocations with normalized valuations. In Proceedings of the 35th AAAI Conference on Artificial Intelligence (AAAI), pages 5440-5447, 2021.
+[HPPZ19] Jiafan He, Ariel D Procaccia, Alexandros Psomas, and David Zeng. Achieving a fairer future by changing the past. Proceedings of the 28th International Joint Conference on Artificial Intelligence (IJCAI), pages 343–349, 2019.
+[HS21] Daniel Halpern and Nisarg Shah. Fair and efficient resource allocation with partial information. In Proceedings of the 30th International Joint Conference on Artificial Intelligence (IJCAI), pages 5456-5463, 2021.
+[Kem20a] David Kempe. An analysis framework for metric voting based on lp duality. In Proceedings of the 34th AAAI Conference on Artificial Intelligence (AAAI), pages 2079-2086, 2020.
+[Kem20b] David Kempe. Communication, distortion, and randomness in metric voting. In Proceedings of the 34th AAAI Conference on Artificial Intelligence (AAAI), pages 2087-2094, 2020.
+[KPS14] Ian Kash, Ariel D Procaccia, and Nisarg Shah. No agent left behind: Dynamic fair division of multiple resources. Journal of Artificial Intelligence Research, 51:579-603, 2014.
+[KPW16] David Kurokawa, Ariel D Procaccia, and Junxing Wang. When can the maximin share guarantee be guaranteed? In Proceedings of the 30th AAAI Conference on Artificial Intelligence (AAAI), pages 523-529, 2016.
+[KS22] Yasushi Kawase and Hanna Sumita. Online max-min fair allocation. In Proceedings of the 15th International Symposium on Algorithmic Game Theory (SAGT), pages 526-543, 2022.
+[LLL18] Bo Li, Wenyang Li, and Yingkai Li. Dynamic fair division problem with general valuations. In Proceedings of the 27th International Joint Conference on Artificial Intelligence (IJCAI), pages 375-381, 2018.
+
+[Mas90] Pascal Massart. The tight constant in the Dvoretzky-Kiefer-Wolfowitz inequality. The annals of Probability, pages 1269-1283, 1990.
+[MSW20] Debmalya Mandal, Nisarg Shah, and David P Woodruff. Optimal communication-distortion tradeoff in voting. In Proceedings of the 21st ACM Conference on Economics and Computation (EC), pages 795-813, 2020.
+[MW19] Kamesh Munagala and Kangning Wang. Improved metric distortion for deterministic social choice rules. In Proceedings of the 20th ACM Conference on Economics and Computation (EC), pages 245–262, 2019.
+[NNR17] Nhan-Tam Nguyen, Trung Thanh Nguyen, and Jörg Rothe. Approximate solutions to max-min fair and proportionally fair allocations of indivisible goods. In Proceedings of the 16th International Conference on Autonomous Agents and Multi-Agent Systems (AAMAS), pages 262-271, 2017.
+[PR06] Ariel D. Procaccia and Jeffrey S. Rosenschein. The distortion of cardinal preferences in voting. In Proceedings of the 10th International Workshop on Cooperative Information Agents (CIA), pages 317-331, 2006.
+[RF90] Gunther Ruhe and Bernd Fruhwirth. $\varepsilon$ -optimality for bicriteria programs and its application to minimum cost flows. Computing, 44(1):21-34, 1990.
+[VPF21] Shai Vardi, Alexandros Psomas, and Eric Friedman. Dynamic fair resource division. Mathematics of Operations Research, 2021.
+[ZP20] David Zeng and Alexandros Psomas. Fairness-efficiency tradeoffs in dynamic fair division. In Proceedings of the 21st ACM Conference on Economics and Computation (EC), pages 911-912, 2020.
\ No newline at end of file
diff --git a/dynamicfairdivisionwithpartialinformation/images.zip b/dynamicfairdivisionwithpartialinformation/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..b75d085e2619dfb679789f816907bd15e8e2f4d5
--- /dev/null
+++ b/dynamicfairdivisionwithpartialinformation/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b3c4563398aa0fd4d22ec40af20a52caa8f2260bdee350dd80c326a7c6adcd4a
+size 131337
diff --git a/dynamicfairdivisionwithpartialinformation/layout.json b/dynamicfairdivisionwithpartialinformation/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..cd1c36a1cbf7094bc08cc14214843b511a05cf74
--- /dev/null
+++ b/dynamicfairdivisionwithpartialinformation/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6697b3fa872f8e2f11bec4d66ed83fd039e3c602e1744426a90eb0b5c6c4e71f
+size 614647
diff --git a/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/b8c84421-498e-46d4-bca0-cac56da3d466_content_list.json b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/b8c84421-498e-46d4-bca0-cac56da3d466_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..b7909fcc1c9c9ff14a5b36b3ed53e0641f1476b5
--- /dev/null
+++ b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/b8c84421-498e-46d4-bca0-cac56da3d466_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:73fd64066d3b20156c0016cf3c9f72ba981133b5b5d39a29778d1a628b4f19a2
+size 95672
diff --git a/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/b8c84421-498e-46d4-bca0-cac56da3d466_model.json b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/b8c84421-498e-46d4-bca0-cac56da3d466_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..c9dd2af2163a3e81314482e87400c234f1c7fbe1
--- /dev/null
+++ b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/b8c84421-498e-46d4-bca0-cac56da3d466_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:137e3dac6f3a68f05fa923b913d3315013c519aaf86d63ad0012f4bb5e9bb4c2
+size 131150
diff --git a/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/b8c84421-498e-46d4-bca0-cac56da3d466_origin.pdf b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/b8c84421-498e-46d4-bca0-cac56da3d466_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..cfcf416670e23c50472f7709b4969a3e3418c4f5
--- /dev/null
+++ b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/b8c84421-498e-46d4-bca0-cac56da3d466_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:32622042c9df7087d65bfd87fa20929acb1cb695211aa3fabc079b130579d2de
+size 1514947
diff --git a/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/full.md b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..5d082230051cb6da0eda74e9a0304558071e7c96
--- /dev/null
+++ b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/full.md
@@ -0,0 +1,402 @@
+# Dynamic Graph Neural Networks Under Spatio-Temporal Distribution Shift
+
+Zeyang Zhang $^{1*}$ , Xin Wang $^{1}$ , Ziwei Zhang $^{1}$ , Haoyang Li $^{1}$ , Zhou Qin $^{2}$ , Wenwu Zhu $^{1\dagger}$
+
+$^{1}$ Tsinghua University, $^{2}$ Alibaba Group
+
+zy-zhang20@mails.tsinghua.edu.cn, {xin_wang, zwzhang}@tsinghua.edu.cn,
+
+lihy18@mails.tsinghua.edu.cn, qinzhou.qinzhou@alibaba-inc.com,
+
+wwzhu@tsinghua.edu.cn
+
+# Abstract
+
+Dynamic graph neural networks (DyGNNs) have demonstrated powerful predictive abilities by exploiting graph structural and temporal dynamics. However, the existing DyGNNs fail to handle distribution shifts, which naturally exist in dynamic graphs, mainly because the patterns exploited by DyGNNs may be variant with respect to labels under distribution shifts. In this paper, we propose to handle spatio-temporal distribution shifts in dynamic graphs by discovering and utilizing invariant patterns, i.e., structures and features whose predictive abilities are stable across distribution shifts, which faces two key challenges: 1) How to discover the complex variant and invariant spatio-temporal patterns in dynamic graphs, which involve both time-varying graph structures and node features. 2) How to handle spatio-temporal distribution shifts with the discovered variant and invariant patterns. To tackle these challenges, we propose the Disentangled Intervention-based Dynamic graph Attention networks (DIDA). Our proposed method can effectively handle spatio-temporal distribution shifts in dynamic graphs by discovering and fully utilizing invariant spatio-temporal patterns. Specifically, we first propose a disentangled spatio-temporal attention network to capture the variant and invariant patterns. Then, we design a spatio-temporal intervention mechanism to create multiple interventional distributions by sampling and reassembling variant patterns across neighborhoods and time stamps to eliminate the spurious impacts of variant patterns. Lastly, we propose an invariance regularization term to minimize the variance of predictions in intervened distributions so that our model can make predictions based on invariant patterns with stable predictive abilities and therefore handle distribution shifts. Experiments on three real-world datasets and one synthetic dataset demonstrate the superiority of our method over state-of-the-art baselines under distribution shifts. Our work is the first study of spatio-temporal distribution shifts in dynamic graphs, to the best of our knowledge.
+
+# 1 Introduction
+
+Dynamic graphs widely exist in real-world applications, including financial networks [1, 2], social networks [3, 4], traffic networks [5, 6], etc. Distinct from static graphs, dynamic graphs can represent temporal structure and feature patterns, which are more complex yet common in reality. Dynamic graph neural networks (DyGNNs) have been proposed to tackle highly complex structural and temporal information over dynamic graphs, and have achieved remarkable progress in many predictive tasks [7, 8].
+
+Nevertheless, the existing DyGNNs fail to handle spatio-temporal distribution shifts, which naturally exist in dynamic graphs for various reasons such as survivorship bias [9], selection bias [10, 11], trending [12], etc. For example, in financial networks, external factors like period or market would affect the correlations between the payment flows and transaction illegitimacy [13]. Trends or communities also affect interaction patterns in coauthor networks [14] and recommendation networks [15]. If DyGNNs highly rely on spatio-temporal patterns which are variant under distribution shifts, they will inevitably fail to generalize well to the unseen test distributions.
+
+To address this issue, in this paper, we study the problem of handling spatio-temporal distribution shifts in dynamic graphs through discovering and utilizing invariant patterns, i.e., structures and features whose predictive abilities are stable across distribution shifts, which remain unexplored in the literature. However, this problem is highly non-trivial with the following challenges:
+
+- How to discover the complex variant and invariant spatio-temporal patterns in dynamic graphs, which include both graph structures and node features varying through time?
+- How to handle spatio-temporal distribution shifts in a principled manner with discovered variant and invariant patterns?
+
+To tackle these challenges, we propose a novel DyGNN named Disentangled Intervention-based Dynamic Graph Attention Networks $(\mathbf{DIDA}^3)$ . Our proposed method handles distribution shifts well by discovering and utilizing invariant spatio-temporal patterns with stable predictive abilities. Specifically, we first propose a disentangled spatio-temporal attention network to capture the variant and invariant patterns in dynamic graphs, which enables each node to attend to all its historic neighbors through a disentangled attention message-passing mechanism. Then, inspired by causal inference literatures [16, 17], we propose a spatio-temporal intervention mechanism to create multiple intervened distributions by sampling and reassembling variant patterns across neighborhoods and time, such that spurious impacts of variant patterns can be eliminated. To tackle the challenges that i) variant patterns are highly entangled across nodes and ii) directly generating and mixing up subsets of structures and features to do intervention is computationally expensive, we approximate the intervention process with summarized patterns obtained by the disentangled spatio-temporal attention network instead of original structures and features. Lastly, we propose an invariance regularization term to minimize prediction variance in multiple intervened distributions. In this way, our model can capture and utilize invariant patterns with stable predictive abilities to make predictions under distribution shifts. Extensive experiments on one synthetic dataset and three real-world datasets demonstrate the superiority of our proposed method over state-of-the-art baselines under distribution shifts. The contributions of our work are summarized as follows:
+
+- We propose Disentangled Intervention-based Dynamic Graph Attention Networks (DIDA), which can handle spatio-temporal distribution shifts in dynamic graphs. This is the first study of spatio-temporal distribution shifts in dynamic graphs, to the best of our knowledge.
+- We propose a disentangled spatio-temporal attention network to capture variant and invariant graph patterns. We further design a spatio-temporal intervention mechanism to create multiple intervened distributions and an invariance regularization term based on causal inference theory to enable the model to focus on invariant patterns under distribution shifts.
+- Experiments on three real-world datasets and one synthetic dataset demonstrate the superiority of our method over state-of-the-art baselines.
+
+# 2 Problem Formulation
+
+In this section, we formulate the problem of spatio-temporal distribution shift in dynamic graphs.
+
+Dynamic Graph. Consider a graph $\mathcal{G}$ with the node set $\mathcal{V}$ and the edge set $\mathcal{E}$ . A dynamic graph can be defined as $\mathcal{G} = (\{\mathcal{G}^t\}_{t=1}^T)$ , where $T$ is the number of time stamps, $\mathcal{G}^t = (\mathcal{V}^t, \mathcal{E}^t)$ is the graph slice at time stamp $t$ , $\mathcal{V} = \bigcup_{t=1}^T \mathcal{V}^t$ , $\mathcal{E} = \bigcup_{t=1}^T \mathcal{E}^t$ . For simplicity, a graph slice is also denoted as $\mathcal{G}^t = (\mathbf{X}^t, \mathbf{A}^t)$ , which includes node features and adjacency matrix at time $t$ . We use $\mathbf{G}^t$ to denote a random variable of $\mathcal{G}^t$ .
+
+
+Figure 1: The framework of our proposed method DIDA. (Bottom left) For a given dynamic graph with multiple timestamps, the disentangled dynamic graph attention networks first obtain summarizations of high-order invariant and variant patterns by disentangled spatio-temporal message passing. (Top) Then the spatio-temporal intervention mechanism creates multiple intervened distributions by sampling and reassembling variant patterns across space and time for each node. (Bottom right) Last, invariance loss is calculated by using samples from intervened distributions to optimize the model so that it can focus on invariant patterns to make predictions.
+
+Prediction tasks. For dynamic graphs, the prediction task can be summarized as using past graphs to make predictions, i.e. $p(\mathbf{Y}^t | \mathbf{G}^1, \mathbf{G}^2, \dots, \mathbf{G}^t) = p(\mathbf{Y}^t | \mathbf{G}^{1:t})$ , where label $\mathbf{Y}^t$ can be node properties or occurrence of links between nodes at time $t + 1$ . In this paper, we mainly focus on node-level tasks, which are commonly adopted in dynamic graph literatures [7, 8]. Following [18, 19], we factorize the distribution of graph trajectory into ego-graph trajectories, i.e. $p(\mathbf{Y}^t | \mathbf{G}^{1:t}) = \prod_v p(\mathbf{y}^t | \mathbf{G}_v^{1:t})$ . An ego-graph induced from node $v$ at time $t$ is defined as $\mathcal{G}_v^t = (\mathbf{X}_v^t, \mathbf{A}_v^t)$ where $\mathbf{A}_v^t$ is the adjacency matrix including all edges in node $v$ 's $L$ -hop neighbors at time $t$ , i.e. $\mathcal{N}_v^t$ , and $\mathbf{X}_v^t$ includes the features of nodes in $\mathcal{N}_v^t$ . The optimization objective is to learn an optimal predictor with empirical risk minimization
+
+$$
+\min _ {\theta} \mathbb {E} _ {(y ^ {t}, \mathcal {G} _ {v} ^ {1: t}) \sim p _ {t r} (\mathbf {y} ^ {t}, \mathbf {G} _ {v} ^ {1: t})} \mathcal {L} \left(f _ {\theta} \left(\mathcal {G} _ {v} ^ {1: t}\right), y ^ {t}\right) \tag {1}
+$$
+
+where $f_{\theta}$ is a learnable dynamic graph neural networks. We use $\mathbf{G}_v^{1:t}, \mathbf{y}^t$ to denote the random variable of the ego-graph trajectory and its label, and $\mathcal{G}_v^{1:t}, y^t$ refer to the respective instances.
+
+Spatio-temporal distribution shift. However, the optimal predictor trained with the training distribution may not generalize well to the test distribution when there exists a distribution shift problem. In the literature of dynamic graph, researchers are devoted to capture laws of network dynamics which are stable in systems [20, 21, 22, 23, 24]. Following them, we assume the conditional distribution is the same $p_{tr}(\mathbf{Y}^t | \mathbf{G}^{1:t}) = p_{te}(\mathbf{Y}^t | \mathbf{G}^{1:t})$ , and only consider the covariate shift problem where $p_{tr}(\mathbf{G}^{1:t}) \neq p_{te}(\mathbf{G}^{1:t})$ . Besides temporal distribution shift which naturally exists in time-varying data [25, 12, 26, 27, 28] and structural distribution shift in non-euclidean data [29, 18, 30], there exists a much more complex spatio-temporal distribution shift in dynamic graphs. For example, the distribution of ego-graph trajectories may vary across periods or communities.
+
+# 3 Method
+
+In this section, we propose Disentangled Intervention-based Dynamic Graph Attention Networks (DIDA) to handle spatio-temporal distribution shift in dynamic graphs. First, we propose a disentangled dynamic graph attention network to extract invariant and variant spatio-temporal patterns. Then we propose a spatio-temporal intervention mechanism to create multiple intervened data distributions. Finally, we optimize the model with invariance loss to make predictions relying on invariant patterns.
+
+# 3.1 Handling Spatio-Temporal Distribution Shift
+
+Spatio-Temporal Pattern. In recent decades of development of dynamic graphs, some scholars endeavor to conclude insightful patterns of network dynamics to reflect how real-world networks evolve through time [31, 32, 33, 34]. For example, the laws of triadic closure describe that two nodes with common neighbors (patterns) tend to have future interactions in social networks [35, 36, 23]. Besides structural information, node attributes are also an important part of the patterns, e.g., social interactions can be also affected by gender and age [37]. Instead of manually concluding patterns, we aim at learning the patterns using DyGNNs so that the more complex spatio-temporal patterns with mixed features and structures can be mined in dynamic graphs. Therefore, we define the spatio-temporal pattern used for node-level prediction as a subset of ego-graph trajectory
+
+$$
+P ^ {t} (v) = m _ {v} ^ {t} \left(\mathcal {G} _ {v} ^ {1: t}\right) \tag {2}
+$$
+
+where $m_{v}^{t}(\cdot)$ selects structures and attributes from the ego-graph trajectory. In [23], the pattern can be explained as an open triad with similar neighborhood, and the model tends to make link predictions to close the triad with $\hat{y}_{u,v}^{t} = f_{\theta}(P^{t}(u), P^{t}(v))$ based on the laws of triadic closure [38]. DyGNNs aim at exploiting predictive spatio-temporal patterns to boost prediction ability. However, the predictive power of some patterns may vary across periods or communities due to spatio-temporal distribution shift. Inspired by the causal theory [16, 17], we make the following assumption
+
+Assumption 1 For a given task, there exists a predictor $f(\cdot)$ , for samples $(\mathcal{G}_v^{1:t}, y^t)$ from any distribution, there exists an invariant pattern $P_I^t(v)$ and a variant pattern $P_V^t(v)$ such that $y^t = f(P_I^t(v)) + \epsilon$ and $P_I^t(v) = \mathcal{G}_v^{1:t} \backslash P_V^t(v)$ , i.e., $\mathbf{y}^t \perp \mathbf{P}_V^t(v) \mid \mathbf{P}_I^t(v)$ .
+
+Assumption 1 shows that invariant patterns $\mathbf{P}_I^t (v)$ are sufficiently predictive for label $y^{t}$ and can be exploited across periods and communities without adjusting the predictor, while the influence of variant patterns $\mathbf{P}_V^t (v)$ on $\mathbf{y}^t$ is shielded by the invariant patterns.
+
+Training Objective. Our main idea is that to obtain better generalization ability, the model should rely on invariant patterns instead of variant patterns, as the former is sufficient for prediction while the predictivity of the latter could be variant under distribution shift. Along this, our objective can be transformed to
+
+$$
+\min _ {\theta_ {1}, \theta_ {2}} \mathbb {E} _ {(y ^ {t}, \mathcal {G} _ {v} ^ {1: t}) \sim p _ {t r} (\mathbf {y} ^ {t}, \mathbf {G} _ {v} ^ {1: t})} \mathcal {L} \left(f _ {\theta_ {1}} \left(\tilde {P} _ {I} ^ {t} (v)\right), y ^ {t}\right) \tag {3}
+$$
+
+$$
+s. t \quad \phi_ {\theta_ {2}} \left(\mathcal {G} _ {v} ^ {1: t}\right) = \tilde {P} _ {I} ^ {t} (v), \mathbf {y} ^ {t} \perp \tilde {\mathbf {P}} _ {V} ^ {t} (v) \mid \tilde {\mathbf {P}} _ {I} ^ {t} (v).
+$$
+
+where $f_{\theta_1}(\cdot)$ make predictions based on the invariant patterns, $\phi_{\theta_2}(\cdot)$ aims at finding the invariant patterns. Backed by causal theory[16, 17], it can be transformed into
+
+$$
+\min _ {\theta_ {1}, \theta_ {2}} \mathbb {E} _ {(y ^ {t}, \mathcal {G} _ {v} ^ {1: t}) \sim p _ {t r} (\mathbf {y} ^ {t}, \mathbf {G} _ {v} ^ {1: t})} \mathcal {L} \left(f _ {\theta_ {1}} \left(\phi_ {\theta_ {2}} \left(\mathcal {G} _ {v} ^ {1: t}\right)\right), y ^ {t}\right) + \tag {4}
+$$
+
+$$
+\lambda \operatorname {V a r} _ {s \in S} \left(\mathbb {E} _ {\left(y ^ {t}, \mathcal {G} _ {v} ^ {1: t}\right) \sim p _ {t r} \left(\mathbf {y} ^ {t}, \mathbf {G} _ {v} ^ {1: t} \mid \mathrm {d o} (\mathbf {P} _ {V} ^ {t} = s)\right)} \mathcal {L} \left(f _ {\theta_ {1}} \left(\phi_ {\theta_ {2}} \left(\mathcal {G} _ {v} ^ {1: t}\right)\right), y ^ {t}\right)\right)
+$$
+
+where 'do' denotes do-calculus to intervene the original distribution [39, 17], $S$ denotes the intervention set and $\lambda$ is a balancing hyperparameter. The idea can be informally described that as in Eq. (3), variant patterns $\mathbf{P}_V^t$ have no influence on the label $\mathbf{y}^t$ given the invariant patterns $\mathbf{P}_I^t$ , then the prediction would not be varied if we intervene the variant patterns and keep invariant patterns untouched. More details about the connections between objective Eq.(3) and Eq.(4) can be found in Appendix.
+
+Remark 1 Minimizing the variance term in Eq. (4) help the model to satisfy the constraint of $\mathbf{y}^t\perp \tilde{\mathbf{P}}_V^t (v)\mid \tilde{\mathbf{P}}_I^t (v)$ in Eq. (3), i.e., $p(\mathbf{y}^t\mid \tilde{\mathbf{P}}_I^t (v),\tilde{\mathbf{P}}_V^t (v)) = p(\mathbf{y}^t\mid \tilde{\mathbf{P}}_I^t (v))$
+
+# 3.2 Disentangled Dynamic Graph Attention Networks
+
+Dynamic Neighborhood. To simultaneously consider the spatio-temporal information, we define the dynamic neighborhood as $\mathcal{N}^t(u) = \{v : (u, v) \in \mathcal{E}^t\}$ , which includes all nodes that have interactions with node $u$ at time $t$ .
+
+Disentangled Spatio-temporal Graph Attention Layer. To capture spatio-temporal pattern for each node, we propose a spatio-temporal graph attention to enable each node to attend to its dynamic neighborhood simultaneously. For a node $u$ at time stamp $t$ and its neighbors $v \in \mathcal{N}^{t'}(u), \forall t' \leq t$ , we calculate the Query-Key-Value vectors as:
+
+$$
+\mathbf {q} _ {u} ^ {t} = \mathbf {W} _ {q} \left(\mathbf {h} _ {u} ^ {t} \| \mathrm {T E} (t)\right), \mathbf {k} _ {v} ^ {t ^ {\prime}} = \mathbf {W} _ {k} \left(\mathbf {h} _ {v} ^ {t ^ {\prime}} \| \mathrm {T E} \left(t ^ {\prime}\right)\right), \mathbf {v} _ {v} ^ {t ^ {\prime}} = \mathbf {W} _ {v} \left(\mathbf {h} _ {v} ^ {t ^ {\prime}} \| \mathrm {T E} \left(t ^ {\prime}\right)\right) \tag {5}
+$$
+
+where $\mathbf{h}_u^t$ denotes the representation of node $u$ at the time stamp $t$ , $\mathbf{q}$ , $\mathbf{k}$ , $\mathbf{v}$ represents the query, key and value vector, respectively, and we omit the bias term for brevity. $\mathrm{TE}(t)$ denotes temporal encoding techniques to obtain embeddings of time $t$ so that the time of link occurrence can be considered inherently [40, 41]. Then, we can calculate the attention scores among nodes in the dynamic neighborhood to obtain the structural masks
+
+$$
+\mathbf {m} _ {I} = \operatorname {S o f t m a x} \left(\frac {\mathbf {q} \cdot \mathbf {k} ^ {T}}{\sqrt {d}}\right), \mathbf {m} _ {V} = \operatorname {S o f t m a x} \left(- \frac {\mathbf {q} \cdot \mathbf {k} ^ {T}}{\sqrt {d}}\right) \tag {6}
+$$
+
+where $d$ denotes feature dimension, $\mathbf{m}_I$ and $\mathbf{m}_V$ represent the masks of invariant and variant structural patterns. In this way, dynamic neighbors with higher attention scores in invariant patterns will have lower attention scores in variant ones, which means the invariant and variant patterns have a negative correlation. To capture invariant featural pattern, we adopt a learnable featural mask $\mathbf{m}_f = \mathrm{Softmax}(\mathbf{w}_f)$ to select features from the messages of dynamic neighbors. Then the messages of dynamic neighborhood can be summarized with respective masks,
+
+$$
+\mathbf {z} _ {I} ^ {t} (u) = \operatorname {A g g} _ {I} \left(\mathbf {m} _ {I}, \mathbf {v} \odot \mathbf {m} _ {f}\right) \tag {7}
+$$
+
+$$
+\mathbf {z} _ {V} ^ {t} (u) = \operatorname {A g g} _ {V} (\mathbf {m} _ {V}, \mathbf {v})
+$$
+
+where $\mathrm{Agg}(\cdot)$ denotes aggregating and summarizing messages from dynamic neighborhood. To further disentangle the invariant and variant patterns, we design different aggregation functions $\mathrm{Agg}_I(\cdot)$ and $\mathrm{Agg}_V(\cdot)$ to summarize specific messages from masked dynamic neighborhood respectively. Then the pattern summarizations are added up as hidden embeddings to be fed into subsequent layers.
+
+$$
+\mathbf {h} _ {u} ^ {t} \leftarrow \mathbf {z} _ {I} ^ {t} (u) + \mathbf {z} _ {V} ^ {t} (u) \tag {8}
+$$
+
+Overall Architecture. The overall architecture is a stacking of spatio-temporal graph attention layers. Like classic graph message-passing networks, this enables each node to access high-order dynamic neighborhood indirectly, where $\mathbf{z}_I^t (u)$ and $\mathbf{z}_V^t (u)$ at $l$ -th layer can be a summarization of invariant and variant patterns in $l$ -order dynamic neighborhood. In practice, the attention can be easily extended to multi-head attention [42] to stable the training process and model multi-faceted graph evolution [43].
+
+# 3.3 Spatio-Temporal Intervention Mechanism
+
+Direct Intervention. One way of intervening variant pattern distribution as Eq. (4) is directly generating and altering the variant patterns. However, this is infeasible in practice due to the following reasons: First, since it has to intervene the dynamic neighborhood and features nodewisely, the computational complexity is unbearable. Second, generating variant patterns including time-varying structures and features is another intractable problem.
+
+Approximate Intervention. To tackle the problems mentioned above, we propose to approximate the patterns $\mathbf{P}^t$ with summarized patterns $\mathbf{z}^t$ found in Sec. 3.2. As $\mathbf{z}_I^t (u)$ and $\mathbf{z}_V^t (u)$ act as summarizations of invariant and variant spatio-temporal patterns for node $u$ at time $t$ , we approximate the intervention process by sampling and replacing the variant pattern summarizations instead of altering original structures and features with generated ones. To do spatio-temporal intervention, we collect variant patterns of all nodes at all time, from which we sample one variant pattern to replace the variant patterns of other nodes across time. For example, we can use the variant pattern of node $v$ at time $t_2$ to replace the variant pattern of node $u$ at time $t_1$ as
+
+$$
+\mathbf {z} _ {I} ^ {t _ {1}} (u), \mathbf {z} _ {V} ^ {t _ {1}} (u) \leftarrow \mathbf {z} _ {I} ^ {t _ {1}} (u), \mathbf {z} _ {V} ^ {t _ {2}} (v) \tag {9}
+$$
+
+As the invariant pattern summarization is kept the same, the label should not be changed. Thanks to the disentangled spatio-temporal graph attention, we get variant patterns across neighborhoods and time, which can act as natural intervention samples inside data so that the complexity of the generation problem can also be avoided. By doing Eq. (9) multiple times, we can obtain multiple intervened data distributions for the subsequent optimization.
+
+# 3.4 Optimization with Invariance Loss
+
+Based on the multiple intervened data distributions with different variant patterns, we can next optimize the model to focus on invariant patterns to make predictions. Here, we introduce invariance loss to instantiate Eq. (4). Let $\mathbf{z}_I$ and $\mathbf{z}_V$ be the summarized invariant and variant patterns, we calculate the task loss by only using the invariant patterns
+
+$$
+\mathcal {L} = \ell \left(f \left(\mathbf {z} _ {I}\right), \mathbf {y}\right) \tag {10}
+$$
+
+where $f(\cdot)$ is the predictor. The task loss let the model utilize the invariant patterns to make predictions. Then we calculate the mixed loss as
+
+$$
+\mathcal {L} _ {m} = \ell \left(g \left(\mathbf {z} _ {V}, \mathbf {z} _ {I}\right), \mathbf {y}\right) \tag {11}
+$$
+
+where another predictor $g(\cdot)$ makes predictions using both invariant patterns $\mathbf{z}_V$ and variant patterns $\mathbf{z}_I$ . The mixed loss measure the model's prediction ability when variant patterns are also exposed to the model. Then the invariance loss is calculated by
+
+$$
+\mathcal {L} _ {d o} = \operatorname {V a r} _ {s _ {i} \in S} \left(\mathcal {L} _ {m} | \mathrm {d o} \left(\mathbf {P} _ {V} ^ {t} = s _ {i}\right)\right) \tag {12}
+$$
+
+where 'do' denotes the intervention mechanism as mentioned in Section 3.3. The invariance loss measures the variance of the model's prediction ability under multiple intervened distributions. The final training objective is
+
+$$
+\min _ {\theta} \mathcal {L} + \lambda \mathcal {L} _ {d o} \tag {13}
+$$
+
+where the task loss $\mathcal{L}$ is minimized to exploit invariant patterns while the invariance loss $\mathcal{L}_{do}$ helps the model to discover invariant and variant patterns, and $\lambda$ is a hyperparameter to balance between two objectives. After training, we only adopt invariant patterns to make predictions in the inference stage. The overall algorithm is summarized in Table 1.
+
+# Algorithm 1 Training pipeline for DIDA
+
+Require: Training epochs $L$ , number of intervention samples $S$ , hyperparameter $\lambda$
+
+1: for $l = 1, \dots, L$ do
+2: Obtain $\mathbf{z}_V^t, \mathbf{z}_I^t$ for each node and time as described in Section 3.2
+3: Calculate task loss and mixed loss as Eq. (10) and Eq. (11)
+4: Sample $S$ variant patterns from collections of $\mathbf{z}_V^t$ , to construct intervention set $S$
+5: for $s$ in $S$ do
+6: Replace the nodes' variant pattern summarizations with $s$ as Section 3.3
+7: Calculate mixed loss as Eq. (11)
+8: end for
+9: Calculate invariance loss as Eq. (12)
+10: Update the model according to Eq. (13)
+11: end for
+
+# 4 Experiments
+
+In this section, we conduct extensive experiments to verify that our framework can handle spatiotemporal distribution shifts by discovering and utilizing invariant patterns. More Details of the settings and other results can be found in Appendix.
+
+Baselines. We adopt several representative GNNs and Out-of-Distribution(OOD) generalization methods as our baselines:
+
+- Static GNNs: GAE [44], a representative static GNN with stacking of graph convolutions; VGAE [44] further introduces variational variables into GAE.
+
+- Dynamic GNNs: GCRN [45], a representative dynamic GNN that first adopts a GCN[44] to obtain node embeddings and then a GRU [46] to model the dynamics; EvolveGCN [13] adopts a LSTM[47] or GRU [46] to flexibly evolve the GCN[44] parameters instead of directly learning the temporal node embeddings; DySAT [43] models dynamic graph using structural and temporal self-attention.
+- OOD generalization methods: IRM [48] aims at learning an invariant predictor which minimizes the empirical risks for all training domains; GroupDRO [49] reduces differences in risk across training domains to reduce the model's sensitivity to distributional shifts; V-REx [50] puts more weight on training domains with larger errors when minimizing empirical risk.
+
+# 4.1 Real-world Datasets
+
+Settings. We use 3 real-world dynamic graph datasets, including COLLAB, Yelp and Transaction. We adopt the challenging inductive future link prediction task, where the model exploits past graphs to make link prediction in the next time step. Each dataset can be split into several partial dynamic graphs based on its field information. For brevity, we use 'w/ DS' and 'w/o DS' to represent test data with and without distribution shift respectively. To measure models' performance under spatiotemporal distribution shift, we choose one field as 'w/ DS' and the left others are further split into training, validation and test data ('w/o DS') chronologically. Note that the 'w/o DS' is a merged dynamic graph without field information and 'w/ DS' is unseen during training, which is more practical and challenging in real-world scenarios. More details on their spatio-temporal distribution shifts are provided in Appendix. Here we briefly introduce the real-world datasets as follows
+
+- COLLAB [51] $^4$ is an academic collaboration dataset with papers that were published during 1990-2006. Node and edge represent author and coauthorship respectively. Based on the field of co-authored publication, each edge has the field information including "Data Mining", "Database", "Medical Informatics", "Theory" and "Visualization". The time granularity is year, including 16 time slices in total. We use "Data Mining" as 'w/ DS' and the left as 'w/o DS'.
+- Yelp [43] is a business review dataset, containing customer reviews on business. Node and edge represent customer/business and review behavior respectively. We consider interactions in five categories of business including "Pizza", "American (New) Food", "Coffee & Tea ", "Sushi Bars" and "Fast Food" from January 2019 to December 2020. The time granularity is month, including 24 time slices in total. We use "Pizza" as 'w/ DS' and the left as 'w/o DS'.
+- Transaction6 is a secondary market transaction dataset, which records transaction behaviors of users from 10th April 2022 to 10th May 2022. Node and edge represent user and transaction respectively. The transactions have 4 categories, including "Pants", "Outwears", "Shirts" and "Hoodies". The time granularity is day, including 30 time slices in total. We use "Pants" as 'w/ DS' and the left as 'w/o DS'.
+
+Results. Based on the results on real-world datasets in Table. 1, we have the following observations:
+
+- Baselines fail dramatically under distribution shift: 1) Although DyGNN baselines perform well on test data without distribution shift, their performance drops greatly under distribution shift. In particular, the performance of DySAT, which is the best-performed DyGNN in 'w/o DS', drop by nearly $12\%$ , $12\%$ and $5\%$ in 'w/ DS'. In Yelp and Transaction, GCRN and EGCN even underperform static GNNs, GAE and VGAE. This phenomenon shows that the existing DyGNNs may exploit variant patterns and thus fail to handle distribution shift. 2) Moreover, as generalization baselines are not specially designed to consider spatio-temporal distribution shift in dynamic graphs, they only have limited improvements in Yelp and Transaction. In particular, they rely on ground-truth environment labels to achieve OOD generalization, which are unavailable for real dynamic graphs. The inferior performance indicates that they cannot generalize well without accurate environment labels, which verifies that lacking environmental labels is also a key challenge for handling distribution shifts of dynamic graphs.
+- Our method can better handle distribution shift than the baselines, especially in stronger distribution shift. DIDA improves significantly over all baselines in 'w/ DS' for all datasets. Note that
+
+Table 1: Results(AUC%) of different methods on real-world datasets. The best results are in bold and the second-best results are underlined. 'w/o DS' and 'w/ DS' denote test data with and without distribution shift.
+
+| Model | COLLAB | Yelp | Transaction |
| Test Data | w/o DS | w/ DS | w/o DS | w/ DS | w/o DS | w/ DS |
| GAE | 77.15±0.50 | 74.04±0.75 | 70.67±1.11 | 64.45±5.02 | 71.90±0.32 | 73.44±0.41 |
| VGAE | 86.47±0.04 | 74.95±1.25 | 76.54±0.50 | 65.33±1.43 | 79.31±0.37 | 75.66±0.30 |
| GCRN | 82.78±0.54 | 69.72±0.45 | 68.59±1.05 | 54.68±7.59 | 78.99±0.28 | 71.24±0.35 |
| EGCN | 86.62±0.95 | 76.15±0.91 | 78.21±0.03 | 53.82±2.06 | 73.22±1.11 | 66.49±0.97 |
| DySAT | 88.77±0.23 | 76.59±0.20 | 78.87±0.57 | 66.09±1.42 | 81.55±0.66 | 76.18±0.43 |
| IRM | 87.96±0.90 | 75.42±0.87 | 66.49±10.78 | 56.02±16.08 | 81.65±0.50 | 75.61±0.61 |
| VREx | 88.31±0.32 | 76.24±0.77 | 79.04±0.16 | 66.41±1.87 | 81.72±0.35 | 76.24±0.52 |
| GroupDRO | 88.76±0.12 | 76.33±0.29 | 79.38±0.42 | 66.97±0.61 | 81.50±0.24 | 75.92±0.37 |
| DIDA | 91.97±0.05 | 81.87±0.40 | 78.22±0.40 | 75.92±0.90 | 83.08±0.33 | 77.61±0.59 |
+
+Table 2: Results(AUC%) of different methods on synthetic dataset. The best results are in bold and the second-best results are underlined. Larger $\overline{p}$ denotes higher distribution shift level.
+
+| Model\(\bar{p}\) | 0.4 | 0.6 | 0.8 |
| Split | Train | Test | Train | Test | Train | Test |
| GCRN | 69.60±1.14 | 72.57±0.72 | 74.71±0.17 | 72.29±0.47 | 75.69±0.07 | 67.26±0.22 |
| EGCN | 78.82±1.40 | 69.00±0.53 | 79.47±1.68 | 62.70±1.14 | 81.07±4.10 | 60.13±0.89 |
| DySAT | 84.71±0.80 | 70.24±1.26 | 89.77±0.32 | 64.01±0.19 | 94.02±1.29 | 62.19±0.39 |
| IRM | 85.20±0.07 | 69.40±0.09 | 89.48±0.22 | 63.97±0.37 | 95.02±0.09 | 62.66±0.33 |
| VREx | 84.77±0.84 | 70.44±1.08 | 89.81±0.21 | 63.99±0.21 | 94.06±1.30 | 62.21±0.40 |
| GroupDRO | 84.78±0.85 | 70.30±1.23 | 89.90±0.11 | 64.05±0.21 | 94.08±1.33 | 62.13±0.35 |
| DIDA | 87.92±0.92 | 85.20±0.84 | 91.22±0.59 | 82.89±0.23 | 92.72±2.16 | 72.59±3.31 |
+
+Yelp has stronger temporal distribution shift since COVID-19 happens in the midway, strongly affecting consumers' behavior in business, while DIDA outperforms the most competitive baseline GroupDRO by $9\%$ in 'w/ DS'. In comparison to similar field information in Yelp (all restaurants) and Transaction (all costumes), COLLAB has stronger spatial distribution shift since the fields are more different to each other, while DIDA outperforms the most competitive baseline DySAT by $5\%$ in 'w/ DS'.
+
+# 4.2 Synthetic Dataset
+
+Settings. To evaluate the model's generalization ability under spatio-temporal distribution shift, following [18], we introduce manually designed shifts in dataset COLLAB with all fields merged. Denote original features and structures as $\mathbf{X}_1^t\in \mathbb{R}^{N\times d}$ and $\mathbf{A}^t\in \{0,1\}^{N\times N}$ . For each time $t$ , we uniformly sample $p(t)|\mathcal{E}^{t + 1}|$ positive links and $(1 - p(t))|\mathcal{E}^{t + 1}|$ negative links in $\mathbf{A}^{t + 1}$ . Then they are factorized into variant features $\mathbf{X}_2^t\in \mathbb{R}^{N\times d}$ with property of structural preservation. Two portions of features are concatenated as $\mathbf{X}^t = [\mathbf{X}_1^t,\mathbf{X}_2^t]$ as input node features for training and inference. The sampling probability $p(t) = \mathrm{clip}(\overline{p} +\sigma cos(t),0,1)$ refers to the intensity of shifts, where the variant features $\mathbf{X}_2^t$ constructed with higher $p(t)$ will have stronger correlations with future link $\mathbf{A}^{t + 1}$ . We set $\overline{p}_{test} = 0.1$ , $\sigma_{test} = 0$ , $\sigma_{train} = 0.05$ and vary $\overline{p}_{train}$ in from 0.4 to 0.8 for evaluation. Since the correlations between $\mathbf{X}_2^t$ and label $\mathbf{A}^{t + 1}$ vary through time and neighborhood, patterns include $\mathbf{X}_2^t$ are variant under distribution shifts. As static GNNs can not support time-varying features, we omit their results.
+
+Results. Based on the results on synthetic dataset in Table. 2, we have the following observations:
+
+- Our method can better handle distribution shift than the baselines. Although the baselines achieve high performance when training, their performance drop drastically in the test stage, which
+
+shows that the existing DyGNNs fail to handle distribution shifts. In terms of test results, DIDA consistently outperforms DyGNN baselines by a significantly large margin. In particular, DIDA surpasses the best-performed baseline by nearly $13\% / 10\% / 5\%$ in test results for different shift levels. For the general OOD baselines, they reduce the variance in some cases while their improvements are not significant. Instead, DIDA is specially designed for dynamic graphs and can exploit the invariant spatio-temporal patterns to handle distribution shift.
+
+- Our method can exploit invariant patterns to consistently alleviate harmful effects of variant patterns under different distribution shift levels. As shift level increases, almost all baselines increase in train results and decline in test results. This phenomenon shows that as the relationship between variant patterns and labels goes stronger, the existing DyGNNs become more dependent on the variant patterns when training, causing their failure in test stage. Instead, the rise in train results and drop in test results of DIDA are significantly lower than baselines, which demonstrates that DIDA can exploit invariant patterns and alleviate the harmful effects of variant patterns under distribution shift.
+
+# 4.3 Complexity Analysis
+
+We analyze the computational complexity of DIDA as follows. Denote $|V|$ and $|E|$ as the total number of nodes and edges in the graph, respectively, and $d$ as the dimensionality of the hidden representation. The spatio-temporal aggregation has a time complexity of $O(|E|d + |V|d^2)$ . The disentangled component adds a constant multiplier 2, which does not affect the time complexity of aggregation. Denote $|E_p|$ as the number of edges to predict and $|S|$ as the size of the intervention set. Our intervention mechanism has a time complexity of $O(|E_p||S|d)$ in training, and does not put extra time complexity in inference. Therefore, the overall time complexity of DIDA is $O(|E|d + |V|d^2 + |E_p||S|d)$ . Notice that $|S|$ is a hyper-parameter and is usually set as a small constant. In summary, DIDA has a linear time complexity with respect to the number of nodes and edges, which is on par with the existing dynamic GNNs.
+
+# 4.4 Ablation study
+
+In this section, we conduct ablation studies to verify the effectiveness of the proposed spatio-temporal intervention mechanism and disentangled graph attention in DIDA.
+
+# Spatio-temporal intervention mechanism.
+
+We remove the intervention mechanism mentioned in Sec 3.3. From Figure 2, we can see that without spatio-temporal intervention, the model's performance drop significantly especially in the synthetic dataset, which verifies that our intervention mechanism helps the model to focus on invariant patterns to make predictions.
+
+Disentangled graph attention. We further remove the disentangled attention mentioned in Sec 3.2. From Figure 2, we can see that disentangled attention is a critical component in the model design, especially in Yelp dataset. Moreover, without disentangled module, the model is unable to obtain variant and invariant patterns for the subsequent intervention.
+
+
+Figure 2: Ablation studies on intervention mechanism and disentangled attention, where 'w/o I' denotes removing the spatio-temporal intervention mechanism in DIDA and 'w/o I&D' further removes disentangled attention.
+
+# 5 Related Work
+
+Dynamic Graph Neural Networks. To tackle the complex structural and temporal information in dynamic graphs, considerable research attention has been devoted to dynamic graph neural networks (DyGNNs) [7, 8]. A classic of DyGNNs first adopt a GNN to aggregate structural information for graph at each time, followed by a sequence model like RNN [52, 53, 54, 45] or temporal self-attention [43] to process temporal information. Another classic of DyGNNs first introduce
+
+time-encoding techniques to represent each temporal link as a function of time, followed by a spatial module like GNN or memory module [20, 55, 40, 41] to process structural information. To obtain more fine-grained continuous node embeddings in dynamic graphs, some work further leverages neural interaction processes [56] and ordinary differential equation [57]. DyGNNs have been widely applied in real-world applications, including dynamic anomaly detection [58], event forecasting [59], dynamic recommendation [60], social character prediction [61], user modeling [62], temporal knowledge graph completion [63], etc. In this paper, we consider DyGNNs under spatio-temporal distribution shift, which remains unexplored in dynamic graph neural networks literature.
+
+Out-of-Distribution Generalization. Most existing machine learning methods assume that the testing and training data are independent and identically distributed, which is not guaranteed to hold in many real-world scenarios [64]. In particular, there might be uncontrollable distribution shifts between training and testing data distribution, which may lead to sharp drop of model performance. To solve this problem, Out-of-Distribution (OOD) generalization problem has recently become a central research topic in various areas [65, 64, 66]. Recently, several works attempt to handle distribution shift on graphs [67, 29, 18, 68, 11, 69, 70, 71, 72, 73]. Another classic of OOD methods most related to our works handle distribution shifts on time-series data [25, 26, 12, 27, 28, 74]. Current works consider either only structural distribution shift for static graphs or only temporal distribution shift for time-series data. However, spatio-temporal distribution shifts in dynamic graphs are more complex yet remain unexplored. To the best of our knowledge, this is the first study of spatio-temporal distribution shifts in dynamic graphs.
+
+Disentangled Representation Learning. Disentangled representation learning aims to characterize the multiple latent explanatory factors behind the observed data, where the factors are represented by different vectors [75]. Besides its applications in computer vision [76, 77, 78, 79, 80] and recommendation [81, 82, 83, 84, 85, 86], several disentangled GNNs have proposed to generalize disentangled representation learning in graph data recently. DisenGCN [87] and IPGDN [88] utilize the dynamic routing mechanism to disentangle latent factors for node representations. FactorGCN [89] decomposes the input graph into several interpretable factor graphs. DGCL [90, 91] aim to learn disentangled graph-level representations with self-supervision. Some works factorize deep generative models based on node, edge, static, dynamic factors [92] or spatial, temporal, graph factors [93] to achieve interpretable dynamic graph generation.
+
+# 6 Conclusion
+
+In this paper, we propose Disentangled Intervention-based Dynamic Graph Attention Networks (DIDA) to handle spatio-temporal distribution shift in dynamic graphs. First, we propose a disentangled dynamic graph attention network to capture invariant and variant spatio-temporal patterns. Then, based on the causal inference literature, we design a spatio-temporal intervention mechanism to create multiple intervened distributions and propose an invariance regularization term to help the model focus on invariant patterns under distribution shifts. Extensive experiments on three real-world datasets and one synthetic dataset demonstrate that our method can better handle spatio-temporal distribution shift than state-of-the-art baselines. One limitation is that in this paper we mainly consider dynamic graphs in scenarios of discrete snapshots, and we leave studying spatio-temporal distribution shifts in continuous dynamic graphs for further explorations.
+
+# Acknowledgements
+
+This work was supported in part by the National Key Research and Development Program of China No. 2020AAA0106300, National Natural Science Foundation of China (No. 62250008, 62222209, 62102222, 62206149), China National Postdoctoral Program for Innovative Talents No. BX20220185 and China Postdoctoral Science Foundation No. 2022M711813. All opinions, findings, conclusions and recommendations in this paper are those of the authors and do not necessarily reflect the views of the funding agencies.
+
+# References
+
+[1] Diego C Nascimento, Bruno A Pimentel, Renata MCR Souza, Lilia Costa, Sandro Gonçalves, and Francisco Louzada. Dynamic graph in a symbolic data framework: An account of the causal relation using Covid-19
+
+reports and some reflections on the financial world. Chaos, Solitons & Fractals, 153:111440, 2021.
+[2] Shilei Zhang, Toyotaro Suzumura, and Li Zhang. Dyagraphtrans: Dynamic graph embedding via modified universal transformer networks for financial transaction data. In 2021 IEEE International Conference on Smart Data Services (SMDS), pages 184-191. IEEE, 2021.
+[3] Tanya Y Berger-Wolf and Jared Saia. A framework for analysis of dynamic social networks. In Proceedings of the 12th ACM SIGKDD international conference on Knowledge discovery and data mining, pages 523-528, 2006.
+[4] Derek Greene, Donal Doyle, and Padraig Cunningham. Tracking the evolution of communities in dynamic social networks. In 2010 international conference on advances in social networks analysis and mining, pages 176-183. IEEE, 2010.
+[5] Hao Peng, Bowen Du, Mingsheng Liu, Mingzhe Liu, Shumei Ji, Senzhang Wang, Xu Zhang, and Lifang He. Dynamic graph convolutional network for long-term traffic flow prediction with reinforcement learning. Information Sciences, 578:401-416, 2021.
+[6] Hao Peng, Hongfei Wang, Bowen Du, Md Zakirul Alam Bhuiyan, Hongyuan Ma, Jianwei Liu, Lihong Wang, Zeyu Yang, Linfeng Du, Senzhang Wang, et al. Spatial temporal incidence dynamic graph neural networks for traffic flow forecasting. Information Sciences, 521:277-290, 2020.
+[7] Joakim Skarding, Bogdan Gabrys, and Katarzyna Musial. Foundations and modeling of dynamic networks using dynamic graph neural networks: A survey. IEEE Access, 9:79143-79168, 2021.
+[8] Yuecai Zhu, Fuyuan Lyu, Chengming Hu, Xi Chen, and Xue Liu. Learnable encoder-decoder architecture for dynamic graph: A survey. arXiv preprint arXiv:2203.10480, 2022.
+[9] Stephen J Brown, William Goetzmann, Roger G Ibbotson, and Stephen A Ross. Survivorship bias in performance studies. The Review of Financial Studies, 5(4):553-580, 1992.
+[10] Richard A Berk. An introduction to sample selection bias in sociological data. American sociological review, pages 386-398, 1983.
+[11] Qi Zhu, Natalia Ponomareva, Jiawei Han, and Bryan Perozzi. Shift-robust gnns: Overcoming the limitations of localized graph training data. Advances in Neural Information Processing Systems, 34, 2021.
+[12] Taesung Kim, Jinhee Kim, Yunwon Tae, Cheonbok Park, Jang-Ho Choi, and Jaegul Choo. Reversible instance normalization for accurate time-series forecasting against distribution shift. In International Conference on Learning Representations, 2021.
+[13] Aldo Pareja, Giacomo Domeniconi, Jie Chen, Tengfei Ma, Toyotaro Suzumura, Hiroki Kanzashi, Tim Kaler, Tao Schardl, and Charles Leiserson. Evolvecn: Evolving graph convolutional networks for dynamic graphs. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 5363-5370, 2020.
+[14] Tian Jin, Qiong Wu, Xuan Ou, and Jianjun Yu. Community detection and co-author recommendation in co-author networks. International Journal of Machine Learning and Cybernetics, 12(2):597-609, 2021.
+[15] Wenjie Wang, Xinyu Lin, Fuli Feng, Xiangnan He, Min Lin, and Tat-Seng Chua. Causal representation learning for out-of-distribution recommendation. In Proceedings of the ACM Web Conference 2022, pages 3562-3571, 2022.
+[16] Judea Pearl et al. Models, reasoning and inference. Cambridge, UK: Cambridge University Press, 19:2, 2000.
+[17] Madelyn Glymour, Judea Pearl, and Nicholas P Jewell. Causal inference in statistics: A primer. John Wiley & Sons, 2016.
+[18] Qitian Wu, Hengrui Zhang, Junchi Yan, and David Wipf. Handling distribution shifts on graphs: An invariance perspective. arXiv preprint arXiv:2202.02466, 2022.
+[19] Kexin Huang and Marinka Zitnik. Graph meta learning via local subgraphs. Advances in Neural Information Processing Systems, 33:5862-5874, 2020.
+[20] Yanbang Wang, Yen-Yu Chang, Yunyu Liu, Jure Leskovec, and Pan Li. Inductive representation learning in temporal networks via causal anonymous walks. arXiv preprint arXiv:2101.05974, 2021.
+
+[21] Zhenyu Qiu, Wenbin Hu, Jia Wu, Weiwei Liu, Bo Du, and Xiaohua Jia. Temporal network embedding with high-order nonlinear information. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 5436-5443, 2020.
+[22] Hong Huang, Zixuan Fang, Xiao Wang, Youshan Miao, and Hai Jin. Motif-preserving temporal network embedding. In IJCAI, pages 1237-1243, 2020.
+[23] Lekui Zhou, Yang Yang, Xiang Ren, Fei Wu, and Yueting Zhuang. Dynamic network embedding by modeling triadic closure process. In Proceedings of the AAAI conference on artificial intelligence, volume 32, 2018.
+[24] Rakshit Trivedi, Mehrdad Farajtabar, Prasenjeet Biswal, and Hongyuan Zha. Dyrep: Learning representations over dynamic graphs. In International conference on learning representations, 2019.
+[25] Jean-Christophe Gagnon-Audet, Kartik Ahuja, Mohammad-Javad Darvishi-Bayazi, Guillaume Dumas, and Irina Rish. Woods: Benchmarks for out-of-distribution generalization in time series tasks. arXiv preprint arXiv:2203.09978, 2022.
+[26] Yuntao Du, Jindong Wang, Wenjie Feng, Sinno Pan, Tao Qin, Renjun Xu, and Chongjun Wang. Adarnn: Adaptive learning and forecasting of time series. In Proceedings of the 30th ACM International Conference on Information & Knowledge Management, pages 402-411, 2021.
+[27] Praveen Venkateswaran, Vinod Muthusamy, Vatche Isahagian, and Nalini Venkatasubramanian. Environment agnostic invariant risk minimization for classification of sequential datasets. In Proceedings of the 27th ACM SIGKDD Conference on Knowledge Discovery & Data Mining, pages 1615-1624, 2021.
+[28] Wang Lu, Jindong Wang, Yiqiang Chen, and Xinwei Sun. Diversify to generalize: Learning generalized representations for time series classification. 2021.
+[29] Ying-Xin Wu, Xiang Wang, An Zhang, Xiangnan He, and Tat-Seng Chua. Discovering invariant rationales for graph neural networks. arXiv preprint arXiv:2201.12872, 2022.
+[30] Muong Ding, Kezhi Kong, Jiuhai Chen, John Kirchenbauer, Micah Goldblum, David Wipf, Furong Huang, and Tom Goldstein. A closer look at distribution shifts and out-of-distribution generalization on graphs. 2021.
+[31] Lauri Kovanen, Marton Karsai, Kimmo Kaski, János Kertész, and Jari Saramäki. Temporal motifs in time-dependent networks. Journal of Statistical Mechanics: Theory and Experiment, 2011(11):P11005, 2011.
+[32] Austin R Benson, David F Gleich, and Jure Leskovec. Higher-order organization of complex networks. Science, 353(6295):163-166, 2016.
+[33] Ashwin Paranjape, Austin R Benson, and Jure Leskovec. Motifs in temporal networks. In Proceedings of the tenth ACM international conference on web search and data mining, pages 601-610, 2017.
+[34] Marinka Zitnik, Rok Sosic, Marcus W Feldman, and Jure Leskovec. Evolution of resilience in protein interactomes across the tree of life. Proceedings of the National Academy of Sciences, 116(10):4426-4433, 2019.
+[35] James S Coleman. Foundations of social theory. Harvard university press, 1994.
+[36] Hong Huang, Jie Tang, Lu Liu, JarDer Luo, and Xiaoming Fu. Triadic closure pattern analysis and prediction in social networks. IEEE Transactions on Knowledge and Data Engineering, 27(12):3374-3389, 2015.
+[37] Lauri Kovanen, Kimmo Kaski, János Kertész, and Jari Saramaki. Temporal motifs reveal homophily, gender-specific patterns, and group talk in call sequences. Proceedings of the National Academy of Sciences, 110(45):18070-18075, 2013.
+[38] Georg Simmel. The sociology of georg simmel, volume 92892. Simon and Schuster, 1950.
+[39] Jin Tian, Changsung Kang, and Judea Pearl. A characterization of interventional distributions in semi-Markovian causal models. eScholarship, University of California, 2006.
+[40] Da Xu, Chuanwei Ruan, Evren Korpeoglu, Sushant Kumar, and Kannan Achan. Inductive representation learning on temporal graphs. arXiv preprint arXiv:2002.07962, 2020.
+
+[41] Emanuele Rossi, Ben Chamberlain, Fabrizio Frasca, Davide Eynard, Federico Monti, and Michael Bronstein. Temporal graph networks for deep learning on dynamic graphs. arXiv preprint arXiv:2006.10637, 2020.
+[42] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. Advances in neural information processing systems, 30, 2017.
+[43] Aravind Sankar, Yanhong Wu, Liang Gou, Wei Zhang, and Hao Yang. Dysat: Deep neural representation learning on dynamic graphs via self-attention networks. In Proceedings of the 13th International Conference on Web Search and Data Mining, pages 519–527, 2020.
+[44] Thomas N Kipf and Max Welling. Variational graph auto-encoders. arXiv preprint arXiv:1611.07308, 2016.
+[45] Youngjoo Seo, Michael Defferrard, Pierre Vandergheynst, and Xavier Bresson. Structured sequence modeling with graph convolutional recurrent networks. In International Conference on Neural Information Processing, pages 362-373. Springer, 2018.
+[46] Kyunghyun Cho, Bart van Merrienboer, Caglar Gulçehre, Dzmitry Bahdanau, Fethi Bougares, Holger Schwenk, and Yoshua Bengio. Learning phrase representations using rnn encoder-decoder for statistical machine translation. In EMNLP, 2014.
+[47] Sepp Hochreiter and Jürgen Schmidhuber. Long short-term memory. Neural computation, 9(8):1735-1780, 1997.
+[48] Martin Arjovsky, Léon Bottou, Ishaan Gulrajani, and David Lopez-Paz. Invariant risk minimization. arXiv preprint arXiv:1907.02893, 2019.
+[49] Shiori Sagawa, Pang Wei Koh, Tatsunori B Hashimoto, and Percy Liang. Distributionally robust neural networks for group shifts: On the importance of regularization for worst-case generalization. arXiv preprint arXiv:1911.08731, 2019.
+[50] David Krueger, Ethan Caballero, Joern-Henrik Jacobsen, Amy Zhang, Jonathan Binas, Dinghuai Zhang, Remi Le Priol, and Aaron Courville. Out-of-distribution generalization via risk extrapolation (rex). In International Conference on Machine Learning, pages 5815-5826. PMLR, 2021.
+[51] Jie Tang, Sen Wu, Jimeng Sun, and Hang Su. Cross-domain collaboration recommendation. In KDD'2012, 2012.
+[52] Menglin Yang, Min Zhou, Marcus Kalander, Zengfeng Huang, and Irwin King. Discrete-time temporal network embedding via implicit hierarchical learning in hyperbolic space. In Proceedings of the 27th ACM SIGKDD Conference on Knowledge Discovery & Data Mining, pages 1975-1985, 2021.
+[53] Li Sun, Zhongbao Zhang, Jiawei Zhang, Feiyang Wang, Hao Peng, Sen Su, and Philip S Yu. Hyperbolic variational graph neural network for modeling dynamic graphs. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pages 4375-4383, 2021.
+[54] Ehsan Hajiramezanali, Arman Hasanzadeh, Krishna Narayanan, Nick Duffield, Mingyuan Zhou, and Xiaoning Qian. Variational graph recurrent neural networks. Advances in neural information processing systems, 32, 2019.
+[55] Weilin Cong, Yanhong Wu, Yuandong Tian, Mengting Gu, Yinglong Xia, Mehrdad Mahdavi, and Chuncheng Jason Chen. Dynamic graph representation learning via graph transformer networks. arXiv preprint arXiv:2111.10447, 2021.
+[56] Xiaofu Chang, Xuqin Liu, Jianfeng Wen, Shuang Li, Yanming Fang, Le Song, and Yuan Qi. Continuous-time dynamic graph learning via neural interaction processes. In Proceedings of the 29th ACM International Conference on Information & Knowledge Management, pages 145-154, 2020.
+[57] Zijie Huang, Yizhou Sun, and Wei Wang. Coupled graph ode for learning interacting system dynamics. In KDD, pages 705-715, 2021.
+[58] Lei Cai, Zhengzhang Chen, Chen Luo, Jiaping Gui, Jingchao Ni, Ding Li, and Haifeng Chen. Structural temporal graph neural networks for anomaly detection in dynamic graphs. In Proceedings of the 30th ACM international conference on Information & Knowledge Management, pages 3747-3756, 2021.
+[59] Songgaojun Deng, Huzefa Rangwala, and Yue Ning. Dynamic knowledge graph based multi-event forecasting. In Proceedings of the 26th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining, pages 1585-1595, 2020.
+
+[60] Jiaxuan You, Yichen Wang, Aditya Pal, Pong Eksombatchai, Chuck Rosenberg, and Jure Leskovec. Hierarchical temporal convolutional networks for dynamic recommender systems. In The world wide web conference, pages 2236-2246, 2019.
+[61] Yanbang Wang, Pan Li, Chongyang Bai, and Jure Leskovec. Tedic: Neural modeling of behavioral patterns in dynamic social interaction networks. In Proceedings of the Web Conference 2021, pages 693-705, 2021.
+[62] Haoyang Li, Peng Cui, Chengxi Zang, Tianyang Zhang, Wenwu Zhu, and Yishi Lin. Fates of microscopic social ecosystems: Keep alive or dead? In Proceedings of the 25th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining, pages 668-676, 2019.
+[63] Jiapeng Wu, Meng Cao, Jackie Chi Kit Cheung, and William L Hamilton. Temp: Temporal message passing for temporal knowledge graph completion. arXiv preprint arXiv:2010.03526, 2020.
+[64] Zheyan Shen, Jiashuo Liu, Yue He, Xingxuan Zhang, Renzhe Xu, Han Yu, and Peng Cui. Towards out-of-distribution generalization: A survey. arXiv preprint arXiv:2108.13624, 2021.
+[65] Kaiyang Zhou, Ziwei Liu, Yu Qiao, Tao Xiang, and Chen Change Loy. Domain generalization: A survey. arXiv e-prints, pages arXiv-2103, 2021.
+[66] Huaxiu Yao, Yu Wang, Sai Li, Linjun Zhang, Weixin Liang, James Zou, and Chelsea Finn. Improving out-of-distribution robustness via selective augmentation. In Proceeding of the Thirty-ninth International Conference on Machine Learning, 2022.
+[67] Haoyang Li, Xin Wang, Ziwei Zhang, and Wenwu Zhu. Out-of-distribution generalization on graphs: A survey. arXiv preprint arXiv:2202.07987, 2022.
+[68] Yongqiang Chen, Yonggang Zhang, Han Yang, Kaili Ma, Binghui Xie, Tongliang Liu, Bo Han, and James Cheng. Invariance principle meets out-of-distribution generalization on graphs. arXiv preprint arXiv:2202.05441, 2022.
+[69] Yijian Qin, Xin Wang, Ziwei Zhang, Pengtao Xie, and Wenwu Zhu. Graph neural architecture search under distribution shifts. In International Conference on Machine Learning, pages 18083-18095. PMLR, 2022.
+[70] Haoyang Li, Xin Wang, Ziwei Zhang, and Wenwu Zhu. Ood-gnn: Out-of-distribution generalized graph neural network. IEEE Transactions on Knowledge and Data Engineering, 2022.
+[71] Zeyang Zhang, Ziwei Zhang, Xin Wang, and Wenwu Zhu. Learning to solve travelling salesman problem with hardness-adaptive curriculum. arXiv preprint arXiv:2204.03236, 2022.
+[72] Shaohua Fan, Xiao Wang, Chuan Shi, Peng Cui, and Bai Wang. Generalizing graph neural networks on out-of-distribution graphs. arXiv preprint arXiv:2111.10657, 2021.
+[73] Haoyang Li, Ziwei Zhang, Xin Wang, and Wenwu Zhu. Learning invariant graph representations for out-of-distribution generalization. In Thirty-Sixth Conference on Neural Information Processing Systems, 2022.
+[74] Huaxiu Yao, Caroline Choi, Yoonho Lee, Pang Wei Koh, and Chelsea Finn. Wild-time: A benchmark of in-the-wild distribution shift over time. In Proceedings of the Thirty-sixth Conference on Neural Information Processing Systems Datasets and Benchmarks Track, 2022.
+[75] Yoshua Bengio, Aaron Courville, and Pascal Vincent. Representation learning: A review and new perspectives. IEEE transactions on pattern analysis and machine intelligence, 35(8):1798-1828, 2013.
+[76] Jun-Ting Hsieh, Bingbin Liu, De-An Huang, Li F Fei-Fei, and Juan Carlos Niebles. Learning to decompose and disentangle representations for video prediction. Advances in neural information processing systems, 31, 2018.
+[77] Liqian Ma, Qianru Sun, Stamatios Georgoulis, Luc Van Gool, Bernt Schiele, and Mario Fritz. Disentangled person image generation. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 99-108, 2018.
+[78] Xi Chen, Yan Duan, Rein Houthooft, John Schulman, Ilya Sutskever, and Pieter Abbeel. Infogan: Interpretable representation learning by information maximizing generative adversarial nets. Advances in neural information processing systems, 29, 2016.
+[79] Emily L Denton et al. Unsupervised learning of disentangled representations from video. Advances in neural information processing systems, 30, 2017.
+
+[80] Luan Tran, Xi Yin, and Xiaoming Liu. Disentangled representation learning gan for pose-invariant face recognition. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 1415-1424, 2017.
+[81] Xin Wang, Hong Chen, Yuwei Zhou, Jianxin Ma, and Wenwu Zhu. Disentangled representation learning for recommendation. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2022.
+[82] Hong Chen, Yudong Chen, Xin Wang, Ruobing Xie, Rui Wang, Feng Xia, and Wenwu Zhu. Curriculum disentangled recommendation with noisy multi-feedback. Advances in Neural Information Processing Systems, 34:26924-26936, 2021.
+[83] Xin Wang, Hong Chen, and Wenwu Zhu. Multimodal disentangled representation for recommendation. In 2021 IEEE International Conference on Multimedia and Expo (ICME), pages 1-6. IEEE, 2021.
+[84] Jianxin Ma, Chang Zhou, Hongxia Yang, Peng Cui, Xin Wang, and Wenwu Zhu. Disentangled self-supervision in sequential recommenders. In Proceedings of the 26th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining, pages 483-491, 2020.
+[85] Jianxin Ma, Chang Zhou, Peng Cui, Hongxia Yang, and Wenwu Zhu. Learning disentangled representations for recommendation. Advances in neural information processing systems, 32, 2019.
+[86] Haoyang Li, Xin Wang, Ziwei Zhang, Jianxin Ma, Peng Cui, and Wenwu Zhu. Intention-aware sequential recommendation with structured intent transition. IEEE Transactions on Knowledge and Data Engineering, 2021.
+[87] Jianxin Ma, Peng Cui, Kun Kuang, Xin Wang, and Wenwu Zhu. Disentangled graph convolutional networks. In International conference on machine learning, pages 4212-4221. PMLR, 2019.
+[88] Yanbei Liu, Xiao Wang, Shu Wu, and Zhitao Xiao. Independence promoted graph disentangled networks. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 4916-4923, 2020.
+[89] Yiding Yang, Zunlei Feng, Mingli Song, and Xinchao Wang. Factorizable graph convolutional networks. Advances in Neural Information Processing Systems, 33:20286-20296, 2020.
+[90] Haoyang Li, Xin Wang, Ziwei Zhang, Zehuan Yuan, Hang Li, and Wenwu Zhu. Disentangled contrastive learning on graphs. Advances in Neural Information Processing Systems, 34:21872-21884, 2021.
+[91] Haoyang Li, Ziwei Zhang, Xin Wang, and Wenwu Zhu. Disentangled graph contrastive learning with independence promotion. IEEE Transactions on Knowledge and Data Engineering, 2022.
+[92] Wenbin Zhang, Liming Zhang, Dieter Pfoer, and Liang Zhao. Disentangled dynamic graph deep generation. In Proceedings of the 2021 SIAM International Conference on Data Mining (SDM), pages 738-746. SIAM, 2021.
+[93] Yuanqi Du, Xiaojie Guo, Hengning Cao, Yanfang Ye, and Liang Zhao. Disentangled spatiotemporal graph generative models. arXiv preprint arXiv:2203.00411, 2022.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
+
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [Yes]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/images.zip b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..6e7e74049808440aceb8a53d89c4e3a254a5ad0d
--- /dev/null
+++ b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a942e0850f149f936cf78a3e74475bdf0a6df41bd96bead0c06004dd2d06aa09
+size 353592
diff --git a/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/layout.json b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..c0557ff840b767639dc1ceedebc99b5057de9e70
--- /dev/null
+++ b/dynamicgraphneuralnetworksunderspatiotemporaldistributionshift/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ee407e1c0ed5358ba1fdc87a7f7fe1dd6b50e6c6a4469bfd8b98af8e5fb574e2
+size 554062
diff --git a/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/e6401213-340b-4529-8444-b0fa42142873_content_list.json b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/e6401213-340b-4529-8444-b0fa42142873_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..8f5b2743e190cca4fd202c33c6419d901e05524b
--- /dev/null
+++ b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/e6401213-340b-4529-8444-b0fa42142873_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6ef0ef895ce52bfd4a12f50c19238acac1176e27782ac739b981ffff9d5dd2f5
+size 80829
diff --git a/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/e6401213-340b-4529-8444-b0fa42142873_model.json b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/e6401213-340b-4529-8444-b0fa42142873_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..8a68578efdd529bb738175a522338b394528c33f
--- /dev/null
+++ b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/e6401213-340b-4529-8444-b0fa42142873_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b365e4f41931bb716fba7c8bef8b5c2f4915a3e237a88ec66f98593413a9ddee
+size 102490
diff --git a/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/e6401213-340b-4529-8444-b0fa42142873_origin.pdf b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/e6401213-340b-4529-8444-b0fa42142873_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..4fd86ef031d27a8c7352f3b1e80b8c48f9b9e2cd
--- /dev/null
+++ b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/e6401213-340b-4529-8444-b0fa42142873_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b0e67c3c314c5a23aae9ad2e052f439b0d314bb692ff22e813141dcb98a0c434
+size 2247694
diff --git a/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/full.md b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..c78325596ba4e41ee7ebf68cbd73c4674c8c83d1
--- /dev/null
+++ b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/full.md
@@ -0,0 +1,313 @@
+# Dynamic Inverse Reinforcement Learning for Characterizing Animal Behavior
+
+Zoe C. Ashwood $^{1,2,*}$ Aditi Jha $^{1,3,*}$ Jonathan W. Pillow $^{1}$
+
+1Princeton Neuroscience Institute, Princeton University
+
+$^{2}$ Dept. of Computer Science, Princeton University
+
+$^{3}$ Dept. of Electrical and Computer Engineering, Princeton University
+
+{zashwood, aditijha, pillow}@princeton.edu
+
+# Abstract
+
+Understanding decision-making is a core objective in both neuroscience and psychology, and computational models have often been helpful in the pursuit of this goal. While many models have been developed for characterizing behavior in binary decision-making and bandit tasks, comparatively little work has focused on animal decision-making in more complex tasks, such as navigation through a maze. Inverse reinforcement learning (IRL) is a promising approach for understanding such behavior, as it aims to infer the unknown reward function of an agent from its observed trajectories through state space. However, IRL has yet to be widely applied in neuroscience. One potential reason for this is that existing IRL frameworks assume that an agent's reward function is fixed over time. To address this shortcoming, we introduce dynamic inverse reinforcement learning (DIRL), a novel IRL framework that allows for time-varying intrinsic rewards. Our method parametrizes the unknown reward function as a time-varying linear combination of spatial reward maps (which we refer to as "goal maps"). We develop an efficient inference method for recovering this dynamic reward function from behavioral data. We demonstrate DIRL in simulated experiments and then apply it to a dataset of mice exploring a labyrinth. Our method returns interpretable reward functions for two separate cohorts of mice, and provides a novel characterization of exploratory behavior. We expect DIRL to have broad applicability in neuroscience, and to facilitate the design of biologically-inspired reward functions for training artificial agents.
+
+# 1 Introduction
+
+Characterizing the decision-making behavior of humans and animals is a central goal in neuroscience and psychology [1, 2]. Decision-making tasks such as Two-Alternative Forced Choice (2AFC) and bandit problems have been widely studied [3-7], and previous work has developed a variety of models for behavior in these tasks [1, 7-9]. The classic psychometric curve represents one such model [10], and more recent work has focused on models based on reinforcement learning [1, 8, 11, 12]. Such models allow us to understand and compare the decision-making strategies used by humans and animals, and can also provide a low-dimensional description of behavior that can be regressed against neural data [1, 13].
+
+Although a large literature has focused on models of decision-making in simple 2AFC and bandit tasks, comparatively few papers have sought to model behavior in larger, complex natural environments.
+
+
+Figure 1: Example mouse trajectories in the labyrinth task of Rosenberg et al. [15]. Water-restricted and unrestricted mice moved freely through a 127 node maze environment for 7 hours. Over the course of the night, each mouse completed over 100 such trajectories, which began at the home port (indicated by an image of a house). For the water-restricted mice, a water port existed at the terminal node in the environment that is shaded grey (next to the water drop image).
+
+[14-16]. In a recent study, Rosenberg et al. [15] introduced a novel experimental paradigm involving water-restricted mice navigating a 127-node labyrinth equipped with a water port at one terminal node (Fig. 1). At each node, the mouse could make up to 4 distinct decisions ('stay', 'go left', 'go right', or 'reverse'). Navigation through a maze is a perfect example of complex yet natural decision-making behavior that remains poorly understood. Although reinforcement learning may seem like the natural framework for modeling such goal-driven behavior, the rewards experienced by these mice are not obvious to the experimenter. Indeed, as noted in Rosenberg et al. [15], the observed trajectories indicate that mice are not only motivated by the extrinsic water reward, but also by intrinsic rewards such as their curiosity to explore the environment.
+
+Inverse reinforcement learning (IRL) [17-20] addresses the problem of inferring the unknown reward function of an agent. Given access to the agent's trajectories as it interacts with the environment, IRL identifies the states and actions that the agent finds rewarding. While IRL has found many successes in robotics [21, 22] and healthcare contexts [23-25], existing IRL methods have not found broad application in neuroscience. One plausible reason for this dearth is that IRL methods typically assume that the unknown reward function is fixed over the course of the agent's trajectory. Yet in many real-world decision-making tasks, rewards can change over time. For example: the goals of a mouse, and consequently its intrinsic rewards, can change with time depending on factors such as fatigue, satiation and curiosity. This motivated us to develop an IRL method for characterizing animal decision-making in complex environments such as the labyrinth, in which rewards may vary over time.
+
+Here we propose dynamic inverse reinforcement learning (DIRL), an IRL method that allows for time-varying reward functions. DIRL parametrizes the animal's reward function as a time-varying linear combination of a small number of spatial reward maps, which we refer to as "goal maps". A single goal map is a function specifying the amount of reward at each state in the environment. (Classic IRL methods thus seek to identify a single, fixed goal map.) DIRL posits the existence of multiple goal maps with time-varying weights, which allows the instantaneous reward function to vary in time. For example, a "water" goal map could have high levels of reward at the water port, while an "explore" reward map might have reward evenly dispersed throughout the environment. Time-varying weights then modulate the extent to which each goal map is active at any timestep. We introduce an inference method, which extends a fixed reward IRL framework by Ziebart et al. [20], to allow us to obtain both the goal maps and the time-varying weights from state-trajectory data. Finally, we demonstrate the application of our framework in simulation (gridworld and labyrinth environments), as well as on real mouse decision-making data from Rosenberg et al. [15]. Our method recovers interpretable reward functions for both cohorts of mice studied there, and reveals an "explore" goal map for one of the cohorts. While exploration remains poorly understood in neuroscience [26], our method offers a powerful framework for characterizing exploratory, as well as exploitative behavior from an animal's trajectories alone.
+
+# 2 Related Work
+
+The neuroscientific literature describing models of decision-making is vast, including both normative [1, 8] and descriptive models [9, 10, 27-30]. While some of this work considers models of decision-making that vary over time, most such models have focused on 2AFC or bandit tasks, and do not scale easily to complex decision-making tasks such as navigation. To the best of our knowledge, IRL has found relatively few applications in neuroscience. One exception is Schultheis et al. [31]
+
+which performed inverse optimal control to infer the cost function associated with sensorimotor behavior. Their targeted application—modeling the cost function optimized by a human performing a reaching task—is very different to ours, which results in different assumptions in their work. Another exception is Yamaguchi et al. [32] which described an IRL framework for identifying the thermotactic strategies used by C. elegans. Relative to the work we present here, Yamaguchi et al. [32] assumed a fixed reward function, and was restricted to the case of a linearly-solvable MDP. In Kwon et al. [33], the authors considered the problem of "Inverse Rational Control" and inferred the parameters governing the evolution of an animal's belief state and subjective reward function within a POMDP (partially observed MDP) framework. Finally, while not the main focus of their paper, Reddy [16] used the static IRL framework of Ziebart et al. [19] to infer the rewards optimized by mice navigating in the Rosenberg et al. [15] task.
+
+The literature on IRL [17-20, 34-37] is extensive, but most studies have assumed that the true underlying reward function is fixed over time. Of particular relevance to our work is the Maximum Causal Entropy (MCE) framework of Ziebart et al. [20]. MCE infers a reward function under the assumption that an agent seeks to maximize both discounted future reward and the discounted future entropy of its policy. We also use discounted future entropy to regularize the goal maps in DIRL, making our method an extension of MCE to the case of time-varying rewards.
+
+Finally, the IRL frameworks of Babes-Vroman et al. [38], Choi and Kim [39] and Likmeta et al. [40] pursued a related aim to ours, allowing for multiple agents with differing reward functions. However, these frameworks did not allow for single agents with time-varying rewards. Surana and Srivastava [41] developed a Bayesian non-parametric method that assumed that an agent's trajectory could be partitioned into distinct behavioral states, where each discrete state had a unique reward function; here, we instead consider the case where rewards vary continuously over time.
+
+# 3 DIRL: Dynamic Inverse Reinforcement Learning
+
+# 3.1 The Inverse Reinforcement Learning Problem
+
+Let us consider a Markov Decision Process (MDP), $\mathcal{M} = \{\mathcal{S},\mathcal{A},\mathcal{T},r,\gamma \}$ , where $\mathcal{S}$ is the state space, $\mathcal{A}$ is the action space, $\mathcal{T}:S\times S\times \mathcal{A}\to [0,1]$ represents the probability of transitioning between states when a certain action is taken, $r:S\times \mathcal{A}\rightarrow \mathbb{R}$ is the reward function, specifying the reward obtained from taking action $a\in \mathcal{A}$ in state $s\in S$ , and $\gamma \in [0,1]$ is the discount factor. Inverse reinforcement learning [17-19, 34, 38, 39] aims to infer the unknown reward function $r(s,a)$ when given access to $\{\mathcal{S},\mathcal{A},\mathcal{T},\gamma \}$ and $N$ trajectories of agents navigating in this environment, $\mathcal{D} = \{\zeta_1,\zeta_2,\dots,\zeta_N\}$ . Each trajectory is a sequence of state-action pairs, $\zeta_{i} = \{(s_{1},a_{1}),(s_{2},a_{2}),\ldots \}$ . Typically, IRL frameworks assume that the reward function does not vary over the course of an agent's trajectory. As discussed earlier, this is a severe limitation when applying IRL in neuroscientific settings, where the subjective value of the rewards an animal receives may vary as a function of time, satiety, thirst, fatigue, curiosity, etc. In the following, we introduce an extension of IRL that allows for time-varying reward functions.
+
+# 3.2 DIRL Generative Model: Goal Maps and Time-Varying Weights
+
+Here we extend the MDP defined above by assuming a time-varying reward function: $r_t(a, s)$ . Our goal is to develop methods for inferring this reward function from a set of observed trajectories $\mathcal{D} = \{\zeta_i\}_{i=1}^N$ . Following previous work [17-19, 34, 38, 39], we assume that the reward function depends only on the state $s$ , allowing us to write the dynamic reward function as $r_t(s)$ . However, inferring the reward for every state at every timepoint still requires learning $|\mathcal{S}| \times T$ parameters. We therefore make two assumptions to reduce the number of parameters and make inference tractable: (1) we model the reward function as low rank, parameterized by a small number of goal maps modulated by a set of time-varying weights; and (2) we impose a prior encouraging these weights to vary slowly in time.
+
+In our approach, the time-varying reward function has the following low-rank representation:
+
+$$
+r _ {t} (s) = \sum_ {k = 1} ^ {K} \alpha_ {k, t} u _ {k, s}, \tag {1}
+$$
+
+where $\mathbf{u}_k\in \mathbb{R}^S$ represents the $k$ 'th goal map, and $\alpha_{k,t}\in \mathbb{R}$ is the weight on this goal map at timestep $t$ , and $K$ is the rank of the representation. Each goal map specifies a reward level for each state in
+
+
+Figure 2: DIRL model schematic. We parametrize the time-varying reward function as a linear combination of a small number of spatial goal maps, where the weights on each map can vary over time. A goal map is a map of the environment, indicating the reward available in each state.
+
+the environment, while weight $\alpha_{k,t}$ specifies the contribution of goal map $k$ to the animal's reward function at $t$ .
+
+To impose smoothness over time, we place a Gaussian random walk prior over weight trajectories:
+
+$$
+\alpha_ {k, t} = \alpha_ {k, t - 1} + \epsilon_ {k}; \quad \epsilon_ {k} \sim \mathcal {N} \left(0, \sigma_ {k} ^ {2}\right), \tag {2}
+$$
+
+where $\sigma_k^2$ is a hyperparameter controlling the variance of the weight changes. This prior reflects our belief that the factors influencing an animal's subjective experience of reward (e.g., thirst, hunger, fatigue) vary slowly relative to the timescale of individual decisions. The low-rank assumption reduces the number of parameters specifying the reward function from $(|S| \times T)$ to $(|S| + T)K$ , a massive reduction provided $K \ll \min(|S|, T)$ . The smoothness assumption allows us to further reduce the effective number of parameters, as the weight trajectories $\alpha_{k,t}$ become more correlated with decreasing variance $\sigma_k^2$ [42].
+
+Figure 2 illustrates the resulting generative model using a simplified $3 \times 3$ gridworld. In this example, there are multiple goal maps, one with reward located only at the water port, a second with reward located only at the home state, and a third with reward distributed broadly across states, which is associated with exploratory behavior. Each map has a time-varying weight that determines its contribution to the animal's total reward function at a given moment in time. In this example, the "home" goal map dominates the reward function at the beginning of the session, while the "water" goal map dominates at the end of the session (e.g., reflecting the animal becoming thirsty).
+
+To model decision-making behavior, we assume that animals seek to maximize the discounted expected future reward under a maximum entropy policy [19, 20, 37, 43, 44], given by:
+
+$$
+\pi_ {t} (s, a) = \frac {e ^ {Q ^ {t} (s , a)}}{\sum_ {a ^ {\prime} \in \mathcal {A}} e ^ {Q ^ {t} (s , a ^ {\prime})}} \quad \forall s \in \mathcal {S}, a \in \mathcal {A}, t \in \{1, \dots T \}, \tag {3}
+$$
+
+where $Q^t (s,a)$ is the soft Q-function for state $s$ and action $a$ at time $t$ :
+
+$$
+Q ^ {t} (s, a) = r _ {t} (s) + \gamma \sum_ {s ^ {\prime}} P \left(s ^ {\prime} \mid s, a\right) \log \left(\sum_ {a ^ {\prime}} \exp Q ^ {t} \left(s ^ {\prime}, a ^ {\prime}\right)\right), \tag {4}
+$$
+
+which arises from the reward function by performing soft value iteration [34] (see Supplementary Materials, SM, for further details). This is a common choice of policy in IRL frameworks as it is easily differentiable (unlike maximizing or "greedy" policies), and it has also been widely applied to data from both humans and animals [13, 28]. Note that our formulation does not require a temperature parameter, as this is directly incorporated into the scale of the time-varying weights: larger (smaller) weights give rise to more (less) deterministic policies.
+
+# 3.3 DIRL inference procedure
+
+During inference, our objective is to learn the time-varying weights $\{\pmb{\alpha}_k\}_{k=1}^K$ , as well as the goal maps $\{\mathbf{u}_k\}_{k=1}^K$ from the trajectories of an agent (animal). To do so, we alternately optimize the goal maps and time-varying weights to maximize the log-posterior of the observed trajectories in $\mathcal{D}$ under our model. Let $\mathbf{u} \in \mathbb{R}^{SK}$ be a vector of concatenated goal maps $\{\mathbf{u}_k\}_{k=1}^K$ stacked vertically, and similarly let $\pmb{\alpha} \in \mathbb{R}^{TK}$ contain the concatenated time-varying weights $\{\pmb{\alpha}_k\}_{k=1}^K$ . We, first, initialize the parameters randomly, such that the elements of the goal maps are chosen from $U(0,1)$ and the time-varying weights are Gaussian distributed. We then perform coordinate ascent to iteratively update the time-varying weights and the goal maps while holding the other set of parameters constant.
+
+Concretely, we obtain the goal map updates $\mathbf{u}$ by maximizing the following objective using gradient ascent:
+
+$$
+\mathbf {u} ^ {*} = \arg \max _ {\mathbf {u}} \sum_ {i = 1} ^ {N} \sum_ {\left(s _ {t}, a _ {t}\right) \sim \zeta_ {i}} \log \pi_ {t} \left(s _ {t}, a _ {t}\right) - \lambda \left\| \mathbf {u} \right\| ^ {2} \tag {5}
+$$
+
+where $\pi_t$ is the policy given by Eq. 3 and $\lambda ||\mathbf{u}||^2$ represents an L2 regularizer.
+
+We then update the time-varying weights $\alpha$ by first updating the reward function and policy (Eq. 3) with the new goal maps, $r_t(s) = \sum_k \alpha_{t,k} u_{k,s}^*$ . We then use gradient ascent to perform the optimization:
+
+$$
+\boldsymbol {\alpha} ^ {*} = \arg \max _ {\boldsymbol {\alpha}} \left(\sum_ {i = 1} ^ {N} \sum_ {\left(s _ {t}, a _ {t}\right) \sim \zeta_ {i}} \log \pi_ {t} \left(s _ {t}, a _ {t}\right) - \frac {1}{2} \log | C | - \frac {1}{2} \boldsymbol {\alpha} ^ {\top} C ^ {- 1} \boldsymbol {\alpha}\right). \tag {6}
+$$
+
+The last two terms in this objective correspond to the negative log of the Gaussian prior on $\alpha$ (Eq. 2), where $C^{-1} = D^{\top}\Sigma^{-1}D$ is the inverse prior covariance, with $D$ a block diagonal matrix of $K$ identical $T\times T$ first-order difference matrices (with 1s on the diagonal and -1s on the sub-diagonal), and $\Sigma^{-1}$ is a diagonal matrix with inverse noise-variances $1 / \sigma_k^2$ along the diagonal.
+
+We iteratively update the goal maps and time-varying weights using Eq. 5 and Eq. 6 until convergence. (See Alg. 1 for pseudo-code). We consider the number of goal maps $K$ , the discount factor $\gamma$ , the strength of the goal map prior $\lambda$ , as well as the noise variances associated with the time-varying weights, $\{\sigma_k\}_{k=1}^K$ , to be hyperparameters. To restrict the number of hyperparameters, we set $\sigma_k = \sigma \forall k$ . We then swept across a broad range of values for all hyperparameters (see SM for the full list of values considered) and selected the values that optimized the log-likelihood of a set of held-out trajectories.
+
+# Algorithm 1: DIRL Inference Procedure
+
+Input 1: MDP state and action spaces, transition matrix: $(S, \mathcal{A}, \mathcal{T})$ ;
+
+Input 2: $N$ trajectories, $\mathcal{D}\equiv \{\zeta_i\}_{i = 1}^N$
+
+Input 3: Hyperparameters: no. of goal maps $K$ , noise variances $\{\sigma_k\}$ , discount factor $\gamma$ , strength of goal map prior, $\lambda$ ;
+
+Output: Parameters governing the rewards $\{\mathbf{u}_k,\pmb {\alpha}_k\}_{k = 1}^K$ , where $\mathbf{u}_k\in \mathbb{R}^S,\pmb {\alpha}_k\in \mathbb{R}^T;$
+
+Let $\mathbf{u} = [\mathbf{u}_1, \dots, \mathbf{u}_k]$ , $\pmb{\alpha} = [\pmb{\alpha}_1, \dots, \pmb{\alpha}_k]$ ;
+
+Initialize $\mathbf{u}^0, \pmb{\alpha}^0$ ;
+
+for iter = 1...Niter do
+
+Calculate rewards $r_t(s) = \sum_k\alpha_{k,t}^{\mathrm{iter}}u_{k,s}^{\mathrm{iter}}\forall s\in S,t\in \{1\dots T\}$
+
+Get policy using soft value iteration: $\pi_t(s, a) = \frac{e^{Q^t(s, a)}}{\sum_{a'} e^{Q^t(s, a')} \forall (s, a, t)}$ .
+
+Update $\mathbf{u}^{\mathrm{iter} + 1}$ by maximizing the log-posterior of trajectories (Eq. 5);
+
+Update rewards $r_t(s) = \sum_k \alpha_{k,t}^{\mathrm{iter}} u_{k,s}^{\mathrm{iter + 1}}$ and learn new policy $\pi_t(s, a)$ ;
+
+Update $\alpha^{\mathrm{iter} + 1}$ by maximizing the log-posterior, with noise variances $\{\sigma_k\}$ (Eq. 6);
+
+end
+
+Output $\mathbf{u}^{N_{\mathrm{iter}}},\alpha^{N_{\mathrm{iter}}}$
+
+# 4 Results
+
+# 4.1 Application to a simulated gridworld environment
+
+
+Figure 3: Simulations on a $5 \times 5$ gridworld. (A) Example expert trajectories when the time-varying reward function is obtained using the generative goal maps shown in B and the time-varying weights shown in C. (B) Generative goal maps: the first map has a high reward at the "home state" (upper left), the other has a high reward at the "water state" (bottom center). (C) Time varying weights for the home and water goal maps: solid lines show the generative parameters, while dotted lines show the recovered parameters along with a $95\%$ confidence interval. Error bars are computed via the inverse Hessian of the log-posterior of Eq. 6 at the MAP estimate of the weights. (D) Recovered goal maps. (E) Rewards for the home and water states are shown in red and blue respectively. The average reward for the remaining states is shown in green. Solid lines show the generative rewards, while the dotted lines show the inferred rewards. (F) Held-out test set performance as a function of the number of goal maps. Higher values are better; units are bits per decision.
+
+We first demonstrate our method on simulated trajectories in a $5 \times 5$ gridworld environment, with 5 actions per state (up, down, left, right, stay). We generated two goal maps for this environment: a "home" map and a "water" map, which were rewarding only at the home state and the water state, respectively (Fig. 3B). Corresponding to these goal maps, we also generated time-varying weights (Fig. 3C, solid lines) for 50 timesteps with the random-walk prior of Eq. 2 (for $\sigma_{k} = 2^{-3.5}$ ; this was chosen to provide adequate variation in the reward function during the time period considered). The weight for the water map started high but decreased over time, thus making the water state the most rewarding for the first $\sim 25$ timesteps (Fig. 3E, blue solid line). In contrast, the weight on the home map started small but increased so that the home state became the most rewarding state at the end of the 50 timesteps (Fig. 3E, red solid line). All of the other states in the environment had a constant reward of 0. In order to generate trajectories corresponding to this reward function (Fig. 3E), we used soft value iteration to learn the corresponding optimal time-varying policy (Eq. 3). We then executed this policy in order to obtain 200 trajectories (a similar number to the number of trajectories we have for the real dataset discussed later), two examples of which are shown in Fig. 3A.
+
+Next, we applied our IRL inference method so as to learn the goal maps and time-varying weights from $80\%$ of the generated trajectories. Fig. 3F shows the log-likelihood of the remaining $20\%$ of trajectories as a function of the number of goal maps. The held-out test log-likelihood is equally high for 2 and 3 maps, so we focus on the 2-map solution in order to be able to compare with the generative parameters. It is important to note that we can only recover rewards at each timestep up to an additive constant, as the policy remains unchanged upon the addition of a constant to the rewards. Further, scaling of the goal maps accompanied by an inverse scaling of the time-varying weights also leaves the recovered rewards unchanged. Thus, to compare to the generative parameters, we perform a post hoc processing method to the recovered parameters to handle all such invariances (details in SM). Figures 3C and D show that our method allows us to accurately recover the generative goal maps and time-varying weights from the simulated trajectories. Finally, combining the goal maps and time-varying weights, we are able to accurately match the generative time-varying rewards for
+
+different states in the gridworld (Fig. 3E). We also simulated trajectories in a 127-node labyrinth environment (akin to [15], Fig 1), and confirmed that we were able to recover goal maps and time-varying weights (see SM for details). We focus on the gridworld simulations here to demonstrate the versatility of our approach across environments.
+
+# 4.2 Application of DIRL to real mouse trajectories
+
+Next, we applied our framework to the trajectories of real mice navigating (in the dark) in a 127-node labyrinth environment [15]. In this task, two cohorts of 10 mice moved freely through the labyrinth over the course of 7 hours. The first cohort was water-restricted and the mice were provided with a water port at one of the terminal nodes (shown in gray in Fig. 1). The second cohort was not water-restricted and did not have access to the water port. We show an example trajectory for an animal in each cohort in Fig. 1. Over the course of the night, each animal completed over a hundred such trajectories, with some animals completing many more.
+
+
+water-restricted animals
+
+
+
+
+Figure 4: Inferred time-varying rewards for water-restricted mice. (A) Inferred goal maps for the water-restricted mice: a "water" map and a "home" map. Dots indicate each of the 127 nodes in the labyrinth environment. (B) Recovered time-varying weights for the same animals. Each timestep corresponds to 1 second. (C) Model comparison: comparison of DIRL on held-out trajectories to a random policy, as well as the Maximum Entropy IRL framework of [19] and the Deep Maximum Entropy IRL framework of [34]. Higher test log-likelihood is better; test log-likelihood has units of bits/decision. (D) Inferred time-varying rewards for the home state, the water state, and the average reward for the remaining states.
+
+
+
+# 4.2.1 Inferring interpretable reward functions from water-restricted mice
+
+We began our investigation by applying our method to a subset of trajectories for the water-restricted animals. Here, we anticipated being able to identify the water port as highly rewarding (in contrast to the water-unrestricted animals). Due to the high variability in trajectories across animals and over the course of the 7 hours, and to be able to obtain trajectories corresponding to similar goal maps and with a similar time course, we used an unsupervised clustering algorithm (based on dbscan [45] and using the Levenshtein distance metric; full details are in the SM) to identify similar trajectories. This procedure had the advantageous side effect of excluding the first 25 or so trajectories for each animal: our focus is not on characterizing learning. Overall, we obtained 200 trajectories for this cohort. Each timestep in a trajectory was recorded at a one second interval.
+
+We then fit the goal maps and time-varying weights to 160 of these trajectories, and held out the remaining $20\%$ of trajectories as a validation set. We found that validation log-likelihood began to level off at two maps (Fig. 4C), so we focus on the 2 map solution here. The 3 map solution is
+
+shown in the SM (where the recovered water goal map is simply repeated). Overall, we found that we were, indeed, able to recover a "water" goal map (Fig 4A), with a large reward at the water state and small rewards elsewhere, as well as a "home" goal map with a large reward at the home state. The recovered time-varying varying weights (Fig 4B) for the water map were high at the beginning – the mouse likely entered the labyrinth due to being thirsty – and later on, as satiation and fatigue set in, tailed off. In contrast, the weights corresponding to the home map started low, but increased over time. The final reward function (Fig 4D) reflects the same dynamics: the water state was highly rewarding for the mouse at the start of its trajectory, while the home state became the more rewarding state after $\sim 6$ seconds. The other states in the labyrinth offered only a small intrinsic reward for the mouse throughout the course of its trajectory.
+
+# 4.2.2 'Exploratory' maps inferred from water-unrestricted mice
+
+We then moved on to examining the trajectories of the water-unrestricted cohort. Relative to the water-restricted mice, the goal maps for these mice were not obvious a priori – there were no extrinsic reward locations for this cohort in the labyrinth. We began by applying the same clustering algorithm as for the water-restricted animals (discussed in the SM) and identified 207 trajectories for our analysis.
+
+We fit the time-varying weights and goal maps to $80\%$ of these trajectories, and held out the remaining $20\%$ as a validation set. As we show in Fig. 5C, the validation log-likelihood is best for the 2 map solution. While we recover (Fig 5A) a "home" map once again, a new map – that was not present for the water-restricted animals – also appears. This map is rewarding at many states throughout the maze, but is very unrewarding at the home port, and is very rewarding at a state that is close to the home port (which we refer to as the "explore" state). Hence, when the animal places a positive weight on this map, the mouse wants to leave the home state and venture into the maze. For these reasons, we refer to this map as the "explore" map. The time-varying weights (Fig 5B) for the home map increase with time; this captures the tendency of these animals to go back to the home state towards the end of the trajectory. The weights corresponding to the explore map are positive at the beginning of the trajectory, capturing the exploratory behavior of these animals when they enter the labyrinth. Finally, the inferred rewards (Fig 5D) reveal that, as we would expect for this cohort, the time-varying reward for the water port is almost identical to the average reward function (across all other states in the labyrinth). We can also see that the reward for the home state rises much more rapidly over time than the reward for other states.
+
+# 4.2.3 DIRL outperforms existing IRL approaches
+
+Finally, we compare the performance of our method with two popular IRL frameworks: the maximum entropy IRL framework of Ziebart et al. [19] and the deep maximum entropy IRL framework of Wulfmeier et al. [34]. In comparison to DIRL, these methods learn a static reward function. We use an open-source implementation of these frameworks [46] and infer the reward functions for each of these methods for the two cohorts of mice studied above. Using the retrieved reward functions, we then obtain the corresponding optimal policy and use it to compute the log-likelihood of the validation set of trajectories. In Figures 4C and 5C, we demonstrate that our method dramatically outperforms these existing methods at explaining the held-out trajectories of both water-restricted and unrestricted mouse cohorts. In the SM, we also show that the trajectories generated by DIRL very well resemble the behavior of mice in the labyrinth, as compared to those generated from [19] and [34].
+
+# 5 Discussion
+
+In this work we develop DIRL, a novel inverse reinforcement learning framework for characterizing the behavior of animals during complex decision-making tasks. Our framework infers the time-varying reward functions of animals from their trajectories alone. We validated our framework on simulated data in a gridworld environment, and applied it to two cohorts of 10 mice navigating in a labyrinth [15]. Our method provided distinct and interpretable reward functions for both cohorts: the water-restricted mice assigned a high reward to the water state upon entering the labyrinth, while the water-unrestricted mice were motivated to leave home and explore at the beginning of their trajectories. As time passed and the mice became fatigued, the reward for the home state increased for animals in both cohorts. Our method dramatically outperformed IRL methods with fixed reward
+
+
+A
+recovered goal maps
+
+
+"home"
+
+
+C
+
+
+B
+Figure 5: Inferred time-varying rewards for water-unrestricted mice. (A) Inferred goal maps for this cohort: an "explore" map and a "home" map are returned. Dots indicate each of the 127 nodes in the labyrinth environment. (B) Recovered time-varying weights for the same animals. (C) Model comparison: comparison of DIRL on held-out trajectories to a random policy, as well as the Maximum Entropy IRL framework of [19] and the Deep Maximum Entropy IRL framework of [34]. Higher test log-likelihood is better; test log-likelihood has units of bits/decision. (D) Inferred time-varying rewards for the home state, the water port, the 'explore' state (the highly rewarding state in the 'explore' goal map that is closest to home) and the average reward for the remaining states. Here the average reward line is almost on top of the line corresponding to the water port.
+
+
+
+
+D
+
+functions, as quantified by the log-likelihood of held-out trajectories, indicating a clear need for tailored IRL approaches for neuroscientific applications. Finally, our method is computationally efficient and infers the time-varying reward function from $\sim 4000$ decisions in the 127-node labyrinth environment in 20 minutes on a laptop.
+
+One exciting finding of our work is the discovery of an "explore" goal map for the water-unrestricted mouse cohort. In general, exploration in animals is not well understood [26]. DIRL offers a novel unsupervised approach for characterizing exploration from behavior alone. Future work could build upon the framework we present here in order to provide normative explanations for the nature of the explore map. DIRL could also be used to explore the neural underpinnings of exploration, for example by correlating fluctuations in the inferred time-varying rewards with recorded neural activity. Finally, while we developed DIRL with neuroscientific applications in mind, our framework is general and could be applied in other scientific fields. For example, DIRL could be applicable in healthcare settings, such as those considered in Huyuk et al. [47]. In Huyuk et al. [47], the authors acknowledge that the policies used by healthcare providers to allocate organ donations have varied over time. By applying DIRL to such a dataset, it may be possible to recover the latent goals of policy-makers or medical practitioners when deciding how best to allocate organs to patients.
+
+In addition to the above-mentioned scientific applications, we believe that DIRL also provides future directions for the development of RL algorithms. Relative to animals, it is often challenging to get artificial agents to explore in sparse reward environments [48]. With access to the internal reward function that motivates mice, we hope that our framework may be useful for inspiring better reward functions for training artificial agents to navigate in analogous environments (such as in [49] where artificial agents navigated in an analogous depth-6 binary tree environment). Another valuable future direction could involve developing alternative ways of formulating the problem of IRL with time-varying goals, such as casting our problem as a Hidden-Mode Hidden Markov Model [50] —a type of POMDP— and then performing IRL with POMDPs [51].
+
+We will close by discussing some limitations of our work. Firstly, our framework requires over a hundred trajectories to infer an animal's time-varying reward function. While it may be possible to
+
+reduce this number (with, for example, a careful choice of prior), it is easy to conceive of failure modes where a single decision reveals nothing about the active goal map. In practice, having access to multiple trajectories (or several decisions) can significantly reduce the uncertainty in the recovered time-varying weights and goal maps. Next, our approach may not scale well to high-dimensional state spaces, as we currently learn a separate reward for each state in each goal map. We don't anticipate this being a problem in the neuroscientific applications that we discuss in this work (where the state-space is 127 dimensional) but an extension of our framework could involve learning a low-dimensional representation of each state in the environment via a deep network, and then learning time-varying rewards in this embedding space. This would allow us to scale our approach to higher dimensional state spaces, while also allowing for generalization across states. Finally, our inferred rewards rely on the animal's policy being the Boltzmann policy of Eq. 3. However, assuming this form for the policy is not atypical in applications of reinforcement learning to human or animal decision-making data [13, 28]. Overall, we believe that the advantages of using our method outweigh its limitations, and that we present a new, flexible framework for characterizing animal behavior in complex environments.
+
+# Acknowledgments and Disclosure of Funding
+
+We thank Benjamin Cowley, Nathaniel Daw, Rachit Dubey and Karthik Narasimhan for useful comments and discussions at various points during this project. We thank the anonymous NeurIPS reviewers for their insightful feedback and helpful suggestions for improvement. The mouse in Figure 1 was provided by BioRender. This work was supported by grants from the Simons Collaboration on the Global Brain (SCGB AWD543027), the NIH BRAIN initiative (NS104899 and R01EB026946), and a U19 NIH-NINDS BRAIN Initiative Award (5U19NS104648).
+
+# References
+
+[1] Yael Niv. Reinforcement learning in the brain. Journal of Mathematical Psychology, 53 (3):139-154, June 2009. ISSN 0022-2496. doi: 10.1016/j.jmp.2008.12.005. URL https://www.sciencedirect.com/science/article/pii/S0022249608001181.
+[2] Robert C Wilson and Anne GE Collins. Ten simple rules for the computational modeling of behavioral data. eLife, 8:e49547, November 2019. ISSN 2050-084X. doi: 10.7554/eLife.49547. URL https://doi.org/10.7554/eLife.49547. Publisher: eLife Sciences Publications, Ltd.
+[3] K. H. Britten, M. N. Shadlen, W. T. Newsome, and J. A. Movshon. Responses of neurons in macaque MT to stochastic motion signals. Visual Neuroscience, 10(6):1157-1169, December 1993. ISSN 0952-5238. doi: 10.1017/s0952523800010269.
+[4] Jerome R. Busemeyer and Julie C. Stout. A contribution of cognitive decision models to clinical assessment: decomposing performance on the Bechara gambling task. Psychological assessment, 14(3):253, 2002. Publisher: American Psychological Association.
+[5] Eldad Yechiam, Jerome R. Busemeyer, Julie C. Stout, and Antoine Bechara. Using cognitive models to map relations between neuropsychological disorders and human decision-making deficits. Psychological science, 16(12):973-978, 2005. Publisher: SAGE Publications Sage CA: Los Angeles, CA.
+[6] Joshua I. Gold and Michael N. Shadlen. The neural basis of decision making. Annual Review of Neuroscience, 30:535-574, 2007. ISSN 0147-006X. doi: 10.1146/annurev.neuro.29.051605.113038.
+[7] Matteo Carandini and Anne K. Churchland. Probing perceptual decisions in rodents. Nature Neuroscience, 16(7):824-831, July 2013. ISSN 1546-1726. doi: 10.1038/nn.3410. URL https://www.nature.com/articles/nn.3410. Number: 7 Publisher: Nature Publishing Group.
+[8] Peter Dayan and Nathaniel D. Daw. Decision theory, reinforcement learning, and the brain. Cognitive, Affective, & Behavioral Neuroscience, 8(4):429-453, December 2008. ISSN 1531-135X. doi: 10.3758/CABN.8.4.429. URL https://doi.org/10.3758/CABN.8.4.429.
+
+[9] Laura Busse, Asli Ayaz, Neel T. Dhruv, Steffen Katzner, Aman B. Saleem, Marieke L. Schölvinck, Andrew D. Zaharia, and Matteo Carandini. The detection of visual contrast in the behaving mouse. *The Journal of Neuroscience: The Official Journal of the Society for Neuroscience*, 31(31):11351-11361, August 2011. ISSN 1529-2401. doi: 10.1523/JNEUROSCI.6689-10.2011.
+[10] Felix A. Wichmann and N. Jeremy Hill. The psychometric function: I. Fitting, sampling, and goodness of fit. Perception & Psychophysics, 63(8):1293-1313, November 2001. ISSN 1532-5962. doi: 10.3758/BF03194544. URL https://doi.org/10.3758/BF03194544.
+[11] Nathaniel D. Daw. Trial-by-trial data analysis using computational models. Decision making, affect, and learning: Attention and performance XXIII, 23(1), 2011. Publisher: Oxford University Press Oxford.
+[12] Armin Lak, Emily Hueske, Junya Hirokawa, Paul Masset, Torben Ott, Anne E Urai, Tobias H Donner, Matteo Carandini, Susumu Tonegawa, Naoshige Uchida, and Adam Kepecs. Reinforcement biases subsequent perceptual decisions when confidence is low, a widespread behavioral phenomenon. eLife, 9:e49834, April 2020. ISSN 2050-084X. doi: 10.7554/eLife.49834. URL https://doi.org/10.7554/eLife.49834. Publisher: eLife Sciences Publications, Ltd.
+[13] Charles Findling, Vasilisa Skvortsova, Rémi Dromnelle, Stefano Palminteri, and Valentin Wyart. Computational noise in reward-guided learning drives behavioral variability in volatile environments. Nature neuroscience, 22(12):2066-2077, 2019. Publisher: Nature Publishing Group.
+[14] Dean Mobbs, Pete C. Trimmer, Daniel T. Blumstein, and Peter Dayan. Foraging for foundations in decision neuroscience: insights from ethology. Nature Reviews Neuroscience, 19(7):419-427, July 2018. ISSN 1471-0048. doi: 10.1038/s41583-018-0010-7. URL https://www.nature.com/articles/s41583-018-0010-7. Number: 7 Publisher: Nature Publishing Group.
+[15] Matthew Rosenberg, Tony Zhang, Pietro Perona, and Markus Meister. Mice in a labyrinth show rapid learning, sudden insight, and efficient exploration. eLife, 10:e66175, July 2021. ISSN 2050-084X. doi: 10.7554/eLife.66175. URL https://doi.org/10.7554/eLife.66175. Publisher: eLife Sciences Publications, Ltd.
+[16] Gautam Reddy. Reinforcement waves as a mechanism for discontinuous learning. Technical report, bioRxiv, May 2022. URL https://www.biorxiv.org/content/10.1101/2022.05.06.490910v1. Section: New Results Type: article.
+[17] Andrew Y. Ng and Stuart J. Russell. Algorithms for inverse reinforcement learning. In Icml, volume 1, page 2, 2000.
+[18] Pieter Abbeel and Andrew Y. Ng. Apprenticeship learning via inverse reinforcement learning. In Proceedings of the twenty-first international conference on Machine learning, page 1, 2004.
+[19] Brian D. Ziebart, Andrew Maas, J. Andrew Bagnell, and Anind K. Dey. Maximum entropy inverse reinforcement learning. In Proc. AAAI, pages 1433-1438, 2008.
+[20] Brian D. Ziebart, J. Andrew Bagnell, and Anind K. Dey. Modeling Interaction via the Principle of Maximum Causal Entropy. 2010. URL https://openreview.net/forum?id=BkWMT5Wu-S.
+[21] Pieter Abbeel, Adam Coates, Morgan Quigley, and Andrew Ng. An Application of Reinforcement Learning to Aerobic Helicopter Flight. In Advances in Neural Information Processing Systems, volume 19. MIT Press, 2006. URL https://proceedings.neurips.cc/paper/2006/bitnet/98c39996bf1543e974747a2549b3107c-AAbstract.html.
+[22] Adam Coates, Pieter Abbeel, and Andrew Y. Ng. Learning for control from multiple demonstrations. In Proceedings of the 25th international conference on Machine learning - ICML '08, pages 144-151, Helsinki, Finland, 2008. ACM Press. ISBN 978-1-60558-205-4. doi: 10.1145/1390156.1390175. URL http://portal.acm.org/citation.cfm?doid=1390156.1390175.
+
+[23] Niranjani Prasad, Barbara Engelhardt, and Finale Doshi-Velez. Defining admissible rewards for high-confidence policy evaluation in batch reinforcement learning. In Proceedings of the ACM Conference on Health, Inference, and Learning, pages 1-9, 2020.
+[24] Alex J. Chan and Mihaela van der Schaar. Scalable bayesian inverse reinforcement learning. arXiv preprint arXiv:2102.06483, 2021.
+[25] Aishwarya Mandyam, Didong Li, Diana Cai, Andrew Jones, and Barbara Engelhardt. Efficient Bayesian Inverse Reinforcement Learning via Conditional Kernel Density Estimation. November 2021. URL https://openreview.net/forum?id=7_a6T7RGNpj.
+[26] Robert N Hughes. Intrinsic exploration in animals: motives and measurement. Behavioural Processes, 41(3):213-226, December 1997. ISSN 0376-6357. doi: 10.1016/S0376-6357(97)00055-7. URL https://www.sciencedirect.com/science/article/pii/S0376635797000557.
+[27] Florian Kattner, Aaron Cochrane, and C. Shawn Green. Trial-dependent psychometric functions accounting for perceptual learning in 2-AFC discrimination tasks. Journal of Vision, 17(11):3, September 2017. ISSN 1534-7362. doi: 10.1167/17.11.3.
+[28] Amir Dezfouli, Kristi Griffiths, Fabio Ramos, Peter Dayan, and Bernard W. Balleine. Models that learn how humans learn: The case of decision-making and its disorders. PLOS Computational Biology, 15(6):e1006903, June 2019. ISSN 1553-7358. doi: 10.1371/journal.pcbi.1006903. URL https://journals.plos.org/ploscompbiol/article?id=10.1371/journal.pcbi.1006903. Publisher: Public Library of Science.
+[29] Nicholas A. Roy, Ji Hyun Bak, Athena Akrami, Carlos D. Brody, and Jonathan W. Pillow. Extracting the dynamics of behavior in sensory decision-making experiments. Neuron, 109 (4):597-610.e6, February 2021. ISSN 0896-6273. doi: 10.1016/j.neuron.2020.12.004. URL https://www.sciencedirect.com/science/article/pii/S0896627320309636.
+[30] Zoe C. Ashwood, Nicholas A. Roy, Iris R. Stone, Anne E. Urai, Anne K. Churchland, Alexandre Pouget, and Jonathan W. Pillow. Mice alternate between discrete strategies during perceptual decision-making. Nature Neuroscience, 25(2):201-212, February 2022. ISSN 1546-1726. doi: 10.1038/s41593-021-01007-z. URL https://www.nature.com/articles/s41593-021-01007-z. Number: 2 Publisher: Nature Publishing Group.
+[31] Matthias Schultheis, Dominik Straub, and Constantin A. Rothkopf. Inverse Optimal Control Adapted to the Noise Characteristics of the Human Sensorimotor System. October 2021. doi: 10.48550/arXiv.2110.11130. URL https://arxiv.org/abs/2110.11130v1.
+[32] Shoichiro Yamaguchi, Honda Naoki, Muneki Ikeda, Yuki Tsukada, Shunji Nakano, Ikue Mori, and Shin Ishii. Identification of animal behavioral strategies by inverse reinforcement learning. PLOS Computational Biology, 14(5):e1006122, May 2018. ISSN 1553-7358. doi: 10.1371/journal.pcbi.1006122. URL https://journals.plos.org/ploscompbiol/article?id=10.1371/journal.pcbi.1006122. Publisher: Public Library of Science.
+[33] Minhae Kwon, Saurabh Daptardar, Paul R Schrater, and Xaq Pitkow. Inverse Rational Control with Partially Observable Continuous Nonlinear Dynamics. In Advances in Neural Information Processing Systems, volume 33, pages 7898-7909. Curran Associates, Inc., 2020. URL https://proceedings.nips.cc/paper/2020/bitnet/5a01f0597ac4bdd35c24846734ee9a76-AAbstract.html.
+[34] Markus Wulfmeier, Peter Ondruska, and Ingmar Posner. Maximum entropy deep inverse reinforcement learning. arXiv preprint arXiv:1507.04888, 2015.
+[35] Chelsea Finn, Sergey Levine, and Pieter Abbeel. Guided cost learning: Deep inverse optimal control via policy optimization. In International conference on machine learning, pages 49-58. PMLR, 2016.
+[36] Yunzhu Li, Jiaming Song, and Stefano Ermon. Infogail: Interpretable imitation learning from visual demonstrations. arXiv preprint arXiv:1703.08840, 2017.
+
+[37] Adam Gleave and Sam Toyer. A Primer on Maximum Causal Entropy Inverse Reinforcement Learning, March 2022. URL http://arxiv.org/abs/2203.11409. Number: arXiv:2203.11409 arXiv:2203.11409 [cs].
+[38] Monica Babes-Vroman, Vukosi Marivate, Kaushik Subramanian, and Michael L. Littman. Apprenticeship learning about multiple intentions. In ICML, 2011.
+[39] Jaedeug Choi and Kee-Eung Kim. Nonparametric bayesian inverse reinforcement learning for multiple reward functions. In NIPS, 2012.
+[40] Amarildo Likmeta, Alberto Maria Metelli, Giorgia Ramponi, Andrea Tirinzoni, Matteo Giuliani, and Marcello Restelli. Dealing with multiple experts and non-stationarity in inverse reinforcement learning: an application to real-life problems. Machine Learning, 110(9): 2541-2576, September 2021. ISSN 1573-0565. doi: 10.1007/s10994-020-05939-8. URL https://doi.org/10.1007/s10994-020-05939-8.
+[41] Amit Surana and Kunal Srivastava. Bayesian nonparametric inverse reinforcement learning for switched markov decision processes. In 2014 13th International Conference on Machine Learning and Applications, pages 47-54, 2014. doi: 10.1109/ICMLA.2014.105.
+[42] James S. Hodges and Daniel J. Sargent. Counting degrees of freedom in hierarchical and other richly-parameterised models. Biometrika, 88(2):367-379, 06 2001. ISSN 0006-3444. doi: 10.1093/biomet/88.2.367. URL https://doi.org/10.1093/biomet/88.2.367.
+[43] Tuomas Haarnoja, Haoran Tang, Pieter Abbeel, and Sergey Levine. Reinforcement learning with deep energy-based policies. 2017.
+[44] Divyansh Garg, Shuvam Chakraborty, Chris Cundy, Jiaming Song, and Stefano Ermon. IQ-Learn: Inverse soft-Q Learning for Imitation. arXiv:2106.12142 [cs], December 2021. URL http://arxiv.org/abs/2106.12142. arXiv: 2106.12142.
+[45] Martin Ester, Hans-Peter Kriegel, and Xiaowei Xu. A Density-Based Algorithm for Discovering Clusters in Large Spatial Databases with Noise. page 6, 1996.
+[46] Yiren Lu. IRL-Imitation, 2017. URL https://github.com/yrlu/irl-imitation.
+[47] Alihan Hüyük, Daniel Jarrett, and Mihaela van der Schaar. Inverse Contextual Bandits: Learning How Behavior Evolves over Time. In Proceedings of the 39th International Conference on Machine Learning, pages 9506-9524. PMLR, June 2022. URL https://proceedings.mlrpress/v162/huyuk22a.htm1. ISSN: 2640-3498.
+[48] Deepak Pathak, Pulkit Agrawal, Alexei A. Efros, and Trevor Darrell. Curiosity-driven exploration by self-supervised prediction. In Doina Precup and Yee Whye Teh, editors, Proceedings of the 34th International Conference on Machine Learning, volume 70 of Proceedings of Machine Learning Research, pages 2778-2787. PMLR, 06-11 Aug 2017. URL https://proceedings.mlr.press/v70/pathak17a.html.
+[49] Runzhe Yang, Xingyuan Sun, and Karthik Narasimhan. A Generalized Algorithm for Multi-Objective Reinforcement Learning and Policy Adaptation. arXiv:1908.08342 [cs], November 2019. URL http://arxiv.org/abs/1908.08342. arXiv:1908.08342.
+[50] Samuel P. M. Choi, Dit-Yan Yeung, and Nevin L. Zhang. Hidden-Mode Markov Decision Processes for Nonstationary Sequential Decision Making. In Ron Sun and C. Lee Giles, editors, Sequence Learning: Paradigms, Algorithms, and Applications, Lecture Notes in Computer Science, pages 264–287. Springer, Berlin, Heidelberg, 2001. ISBN 978-3-540-44565-4. doi: 10.1007/3-540-44565-X_12. URL https://doi.org/10.1007/3-540-44565-X_12.
+[51] Jaedeug Choi and Kee-Eung Kim. Inverse Reinforcement Learning in Partially Observable Environments. Journal of Machine Learning Research, 12:691-730, March 2011.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] : please refer to the Discussion section.
+(c) Did you discuss any potential negative societal impacts of your work? [N/A] We do not foresee any negative societal impacts of our work.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] We confirm that we have read through the ethics review guidelines and that our paper conforms to them.
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] We provide the code as a supplemental material. The real data studied in this work is publicly available at https://github.com/markusmeister/Rosenberg-2021-Repository.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See our Methods section, as well as the SM.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] See Figures 2, 3 and 4 for examples of this.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See the Discussion section, as well as the SM.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] We cite the curators of the real-world mouse dataset many times.
+(b) Did you mention the license of the assets? [Yes] In the SM, we make clear that this dataset is publicly available and comes with an MIT open source license.
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We provide our code as a supplemental material.
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/images.zip b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..b8a979ebbf83c9c57fad4b7ed2fc20a728a51385
--- /dev/null
+++ b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f99483a8d05d8c89c8cde211ecf525411db2d8951dcf7f869f387af46f8850e1
+size 289294
diff --git a/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/layout.json b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..6ac3679a1d9be168088f8105369c074603c4aef3
--- /dev/null
+++ b/dynamicinversereinforcementlearningforcharacterizinganimalbehavior/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:35401dd5834e0c38ebf97e6cf69a015f17c90d0b0ad82bec69d847d9102ae778
+size 404908
diff --git a/dynamiclearninginlargematchingmarkets/58c057cf-51a0-431a-ab5f-47b448f840f2_content_list.json b/dynamiclearninginlargematchingmarkets/58c057cf-51a0-431a-ab5f-47b448f840f2_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..2856fd7b5fc228f452c9306edf7be1af28a8a4e6
--- /dev/null
+++ b/dynamiclearninginlargematchingmarkets/58c057cf-51a0-431a-ab5f-47b448f840f2_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2f3ea2c97919260a6aa7c8d341fe47d022de270ad52bf1930821436dd25f1790
+size 75107
diff --git a/dynamiclearninginlargematchingmarkets/58c057cf-51a0-431a-ab5f-47b448f840f2_model.json b/dynamiclearninginlargematchingmarkets/58c057cf-51a0-431a-ab5f-47b448f840f2_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..8560098a759acd153f4bffc6e7d731ebd45b94a6
--- /dev/null
+++ b/dynamiclearninginlargematchingmarkets/58c057cf-51a0-431a-ab5f-47b448f840f2_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:73b4bf52b008447f07a5236fcf3cd53fe37b1c945d6cb24c6b70caf991b0271e
+size 91134
diff --git a/dynamiclearninginlargematchingmarkets/58c057cf-51a0-431a-ab5f-47b448f840f2_origin.pdf b/dynamiclearninginlargematchingmarkets/58c057cf-51a0-431a-ab5f-47b448f840f2_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..4212a84bce913e255cbc5cf9cf571e38b0a6aab9
--- /dev/null
+++ b/dynamiclearninginlargematchingmarkets/58c057cf-51a0-431a-ab5f-47b448f840f2_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c4e19afa4d478f3c0601a12c8ae0d0d462d69daf621f4db063249f0369686d32
+size 719075
diff --git a/dynamiclearninginlargematchingmarkets/full.md b/dynamiclearninginlargematchingmarkets/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..e74c9410478043cac47f202c047d4ae88627523b
--- /dev/null
+++ b/dynamiclearninginlargematchingmarkets/full.md
@@ -0,0 +1,263 @@
+# Dynamic Learning in Large Matching Markets
+
+Anand Kalvit1 and Assaf Zeevi2
+
+Columbia University, New York {akalvit22,assaf}@gsb.columbia.edu
+
+# Abstract
+
+We study a sequential matching problem faced by large centralized platforms where "jobs" must be matched to "workers" subject to uncertainty about worker skill proficiencies. Jobs arrive at discrete times with "job-types" observable upon arrival. To capture the "choice overload" phenomenon, we posit an unlimited supply of workers where each worker is characterized by a vector of attributes (aka "worker-types") drawn from an underlying population-level distribution. The distribution as well as mean payoffs for possible worker-job type-pairs are unobservables and the platform's goal is to sequentially match incoming jobs to workers in a way that maximizes its cumulative payoffs over the planning horizon. We establish lower bounds on the regret of any matching algorithm in this setting and propose a novel rate-optimal learning algorithm that adapts to aforementioned primitives online. Our learning guarantees highlight a distinctive characteristic of the problem: achievable performance only has a second-order dependence on worker-type distributions; we believe this finding may be of interest more broadly.
+
+# 1 Introduction
+
+Background and motivation. The problem of sequentially matching "jobs" to "workers" under uncertainty forms the bedrock of many modern operational settings, especially in the online gig economy, see, e.g., applications such as Amazon Mechanical Turk, TaskRabbit, Jobble, and the likes. A simpler instance of the problem dates back to [13] where it is referred to as the sequential stochastic assignment problem (SSAP). A fundamental issue in such settings is that the platform typically is oblivious (at least initially) to the skill proficiencies of individual workers for specific task categories. This complexity is further compounded by the large number of workers usually present on such platforms, tantamount to prohibitively large experimentation costs associated with acquisition of granular information at the level of an individual worker. This issue is commonly mitigated by exploiting structure in the problem (if any), or by positing distributional assumptions on the population of available workers, e.g., workers may be drawn from some distribution $\mathcal{D}$ satisfying certain context-specific desiderata. Such distributional assumptions are vital to designing efficient algorithms for these systems, and as such, traditional literature has largely relied on the availability of ex ante knowledge of $\mathcal{D}$ or certain key aspects thereof (refer to the literature review in §1.2).
+
+Key research question. An important characteristic of the gig economy is that the population of workers may undergo distributional shifts over the course of the platform's planning horizon. These effects may, many a time, fail to register in a timely manner; as a result, there may be delays in tailoring appropriately the matching algorithm (calibrated typically using available distribution-level information) to the changed environment. This has the potential to cause revenue losses as well as catalyze endogenous worker attrition. Such exigencies necessitate designing algorithms that are agnostic to $\mathcal{D}$ and whose performance is robust to plausible realizations thereof.
+
+The model at a glance. We consider a finite set of possible job-types (denoted by $\mathcal{J}$ ), an assumption we deem appropriate for settings such as those discussed above. In addition, we model workers as exhibiting discrete skill-levels (aka worker-types), indexed by $\{1,\dots,K_j\}$ , w.r.t. each job-type $j\in \mathcal{J}$
+
+and make the simplifying assumption that $(K_{j}: j \in \mathcal{J})$ is known a priori. It is not unreasonable to make this assumption since it is common, in practice, for platforms to deploy pilot experiments prior to the actual matching phase in order to gather sufficient information on key primitives such as the size and stability of low-dimensional sub-population clusters, if any exist; one can therefore safely assume in settings where such structure exists that $(K_{j}: j \in \mathcal{J})$ is well-estimated a priori. Furthermore, assumptions pertaining to the finiteness of the set of possible job-types and segmentation of the population of workers based on discretization of skill levels are de rigueur also in the dynamic matching and the broader operations research literature, see, e.g., [7, 2, 17], etc.
+
+While the demand is constituted by sequential job-arrivals (possibly in batches of stochastic size and composition), we posit availability of an unlimited number of workers on the supply side. The latter feature encapsulates the choice overload phenomenon characteristic of many large market settings where workers are available in a large number relative to the platform's planning horizon. To our best knowledge, extant literature on matching under uncertainty is largely limited to "finite" markets (see the literature review in §1.2), and therefore fails to accommodate this important practical consideration. In our setting, the population of workers, albeit large, is governed by a fixed distribution that controls the proportion of each worker-type. Specifically, the $K_{j}$ distinct worker-types w.r.t. job-type $j$ are distributed according to $\alpha_{j} := (\alpha_{i,j} : i = 1, \dots, K_{j})$ , where $\sum_{i=1}^{K_{j}} \alpha_{i,j} = 1$ . We note that this is one possible model of a matching market that is closer in spirit to SSAP [13] as well as other related formulations thereof; it differs from other models in the matching literature (see §1.2) in that it tries to capture a salient aspect of large markets, viz., choice overload, as opposed to traditional aspects such as competition and congestion best elucidated via conventional "finite" market models.
+
+The platform's goal is to maximize its expected cumulative payoffs over a sequence of $n$ rounds of matching, subject to worker-types w.r.t. job-types and their distributions $\{\alpha_{j} : j \in \mathcal{J}\}$ , as well as mean payoffs for possible worker-job type-pairs being latent attributes. As is the norm in settings with incomplete information and imperfect learning, we reformulate this objective as minimizing the expected cumulative regret relative to an oracle that is privy to aforementioned primitives.
+
+On the complexity of the problem. Even with a unique job-type, say $\mathcal{J} = \{j_0\}$ , and only one job arriving per period, the ensuing allocation problem is challenging to analyze on account of the distribution $\alpha_{j_0}$ and any statistical properties of the rewards being unknown. In the simplest possible formulation, $K_{j_0} = 2$ , and the statistical complexity of the corresponding regret minimization problem is governed by three principal primitives: (i) the sub-optimality gap $\underline{\Delta}_{j_0} > 0$ between the mean rewards of the optimal and inferior worker sub-populations; (ii) the probability $\alpha_{1,j_0}$ of sampling an optimal worker from the population; and (iii) the planning horizon $n$ . One may aptly recognize this as an infinitely many-armed bandit problem (where arms are synonymous to workers) with an arm-reservoir distribution $(\alpha_{1,j_0}, 1 - \alpha_{1,j_0})$ and a mean reward gap of $\underline{\Delta}_{j_0}$ . However, this model differs from the classical literature on infinite-armed bandits in that its arm-reservoir distribution is not endowed with any regularity properties (see the literature review in §1.2), instead we only posit a finite support with cardinality known to the decision maker (in this case, a cardinality of two), absent however, knowledge of the associated probability masses (in this case, $\alpha_{j_0,1}$ and $1 - \alpha_{j_0,1}$ ). In our setting, absence of information on $\alpha_{1,j_0}$ significantly exacerbates the difficulty of analysis as calibrating exploration becomes challenging (on account of a "large" number of arms). In particular, how many arms must one query from the arm-reservoir in order to have at least one optimal arm in the queried set with high probability, is difficult to answer if (a lower bound on) the proportion $\alpha_{1,j_0}$ of optimal arms is unknown. Consequently, any finite consideration set may only contain inferior arms and as a result, any algorithm limited to such a selection will suffer a linear regret. One may contrast this setting with its classical two-armed counterpart with gap $\underline{\Delta}_{j_0}$ , where finiteness of the set of arms (binary action space) makes it possible to design efficient rate-optimal policies. In our setting, on the other hand, it remains a priori unclear if there even exists a policy capable of achieving sub-linear regret. The general matching problem naturally is only harder.
+
+# 1.1 Contributions
+
+In this work, we resolve several foundational questions pertaining to complexity and achievable performance in the matching problem described earlier, and provide a comprehensive understanding of various other aspects thereof. Among other things, we propose an algorithm that achieves a finite-time instance-dependent expected regret of $\mathcal{O}(\log n)$ after $n$ rounds (the big-Oh subsumes problem-dependent scaling factors encapsulating its fundamental complexity), and prove that this
+
+performance cannot be improved w.r.t. $n$ . While the order of regret and complexity of the problem suggests a great degree of similarity to the classical stochastic finite-armed bandit problem, properties of the performance bounds and salient aspects of algorithm design are quite distinct from the latter, as are the key primitives that determine complexity along with the analysis tools needed to study them. In what follows, we will for expositional reasons assume $\mathcal{I} = \{j_0\}$ and a batch size of 1 (jobs arrive one at a time) whenever $|\mathcal{I}| = 1$ . Our theoretical contributions can then be projected along the following axes:
+
+Complexity of regret when $|\mathcal{I}| = 1$ . We establish information-theoretic lower bounds on regret that are order-wise tight (in the horizon $n$ ) in the instance-dependent setting (Theorem 1). In addition, we establish a uniform lower bound on achievable performance (tight in $n$ ) that captures explicitly the scaling behavior w.r.t. the fraction $\alpha_{1,j_0}$ of optimal arms (Theorem 2); this is shown via a novel non-information-theoretic proof based entirely on convex analysis.
+
+Algorithm design and achievable performance. We propose a policy (Algorithm 2) that is rate-optimal (in $n$ ) for the instance-dependent setting. Our policy relies only on knowledge of $K_{j_0}$ , is agnostic to information pertaining to the reward distributions as well as the distribution $(\alpha_{i,j_0} : i = 1, \dots, K_{j_0})$ of worker-types. Furthermore, the upper bound depends on the distribution of worker-types only in sub-logarithmic terms (see below).
+
+Performance bounds for general $\mathcal{J}$ . Aforementioned results for $|\mathcal{J}| = 1$ and unit batch size are then translated to the general (matching) version of the problem described earlier, where $\mathcal{J}$ can be any arbitrary finite set and jobs may arrive in batches of stochastic size and constitution. In the matching problem, we establish that regret is bounded above by $\sum_{j\in \mathcal{J}}(C_1(\pmb {\mu}_j)\log n + C_2(\pmb {\mu}_j,\pmb {\alpha}_j)\log \log n)$ under our policy tailored to this setting, where the constants $C_1(\cdot),C_2(\cdot ,\cdot)$ only depend on their arguments, $\pmb{\mu}_{j}:= (\mu_{i,j}:i = 1,\dots,K_{j})^{\prime \prime}$ and $\pmb{\alpha}_{j}:= (\alpha_{i,j}:i = 1,\dots,K_{j})$ (Theorem 4). When $K_{j} = 2\forall j\in \mathcal{J}$ , we improve this guarantee to $\sum_{j\in \mathcal{J}}(C_1(\pmb {\mu}_j)\log n + C_2(\pmb {\mu}_j,\pmb {\alpha}_j))$ (Theorem 6). It is noteworthy that the upper bounds depend on $\{\alpha_{j}:j\in \mathcal{J}\}$ only in sub-logarithmic terms. We believe this finding may be of interest more broadly.
+
+# 1.2 Literature review
+
+Our work is positioned relative to two major streams of literature; dynamic matching and multi-armed bandits. Below, we briefly survey each of these areas and remark on the distinctions and novelties in our model vis-à-vis the extant body of work.
+
+Dynamic matching under uncertainty. There is a recent line of work on simultaneous learning and matching in bipartite graphs under uncertainty. For a survey of works in this area, see [22, 23, 24, 25, 16, 9, 3], etc. Aforementioned references, by and large, consider an archetypal stable matching problem under uncertainty in preferences where a heterogeneous collection of jobs (represented by nodes on one side of a bipartite graph) must be matched to workers (the other side of the graph) with unknown or noisy preferences over jobs. The matching proceeds iteratively in rounds in a way that meets certain stability criteria at all times as well as ensures that the true preferences are "learnt" at a regret-optimal rate. Cited works, however, differ from our paper fundamentally in that their learning problems are posited over a finite set of workers, which allows for sufficient exploration of each; this would be infeasible in our setting owing to a "large" population thereof.
+
+In contrast, [17] considers a stationary setting where a stream of heterogeneous jobs must dynamically be matched to a policy-dependent steady state population of workers in a way that respects capacity constraints on the supply and demand processes. This paper shares basic similarities with our work in studying a "large" population model of workers. Their key technical innovation, however, lies in the way polytope capacity constraints are handled via an intelligent use of shadow prices to create essentially an unconstrained learning problem that may be solved rate-optimally using conventional heuristics. It is noteworthy that the algorithm proposed in aforementioned reference requires ex ante knowledge of $\{\pmb{\mu}_j, \pmb{\alpha}_j : j \in \mathcal{I}\}$ in addition to other primitives. Our model, on the other hand, has a richer learning component that is challenging to address as it is, absence of capacity constraints notwithstanding. Our primary contribution here lies in establishing fundamental achievability results for this setting and in the design of novel rate-optimal algorithms that adapt to key primitives online.
+
+Multi-armed bandits. Our problem shares structural similarities with infinitely many-armed bandits, modulo heterogeneity and multiplicity of pulls. Infinite-armed bandits involve a fixed reservoir distribution over an uncountable set of arm-types (possible mean rewards) that may be queried arbitrarily often over the horizon of play. These problems trace their roots to [4] which studied the Bernoulli reward setting under a Uniform (on $[0,1]$ ) prior on the mean. Subsequent works have considered more general reservoir distributions, albeit endowed with certain regularity properties, see, e.g., [26, 8, 10], etc. In terms of the statistical complexity of regret minimization, such regularity assumptions are tantamount to the minimal achievable regret being polynomial in the horizon (see above references). In contrast, our model is fundamentally simpler owing to a finite set of arm-types despite also being endowed with infinitely many arms. However, unlike cited works, the decision maker in our setting is completely oblivious to the reservoir distribution (or any property thereof) which substantially exacerbates the difficulty of analysis as well as the hardness of the problem itself.
+
+# 1.3 Organization of the paper
+
+§2 provides a formal description of the problem and §3 contains results pertaining to lower bounds on achievable performance for natural policy classes. §4 deals with design and analysis considerations for rate-optimal policies and also contains our main propositions together with supporting theoretical guarantees. All other discussion (including auxiliary results and proofs) is deferred to the appendix.
+
+# 2 Problem formulation
+
+Job-arrival process. The platform faces an arrival stream of jobs (i.i.d. in time) given by $\{(\Lambda_{j,t}: j \in \mathcal{I}): t = 1,2,\ldots\}$ , where $\mathcal{I}$ is finite and $\Lambda_{j,t}$ is the number of type $j$ jobs arriving at time $t$ . Types and multiplicities of jobs are perfectly observable upon arrival. We assume that there exists some finite constant $M > 0$ satisfying $\mathbb{P}\left(\max_{j \in \mathcal{J}} \sup_{t \geqslant 1} \Lambda_{j,t} \leqslant M\right) = 1$ . We remark that our algorithms do not require knowledge of $M$ ; the assumption only serves to simplify analysis.
+
+Supply of workers. We assume that workers are distributed on the unit interval $[0,1]$ according to some probability distribution $\mathcal{D}$ that is absolutely continuous w.r.t. the Lebesgue measure on $[0,1]$ . Associated with each job-type $j\in \mathcal{J}$ , there exists a permutation $\sigma_{j}:= \{\sigma_{j}(i):i = 1,\dots,K_{j}\}$ of $\{1,\ldots ,K_j\}$ , and a sequence of thresholds $0\eqqcolon \lambda_{0,j} < \lambda_{1,j} < \ldots < \lambda_{K_j - 1,j} < \lambda_{K_j,j}:= 1$ partitioning the unit interval into $K_{j}$ disjoint sub-intervals. We posit a payoff model whereby a worker $x\in (\lambda_{i - 1,j},\lambda_{i,j})$ (for some $i\in \{1,\dots,K_j\}$ ) generates a stochastic reward with mean $\mu_{\sigma_j(i),j}$ upon match with a type $j$ job; it is assumed that the $K_{j}$ mean rewards adhere to the strict order $\mu_{1,j} > \ldots >\mu_{K_j,j}$ . We define $\alpha_{i,j}\coloneqq \mathbb{P}\left(X\in \left(\lambda_{\ell (i,j) - 1,j},\lambda_{\ell (i,j),j}\right)\right)$ , where $X\sim \mathcal{D}$ and $\iota (i,j)\in \{1,\dots,K_j\}$ is the unique element satisfying $\sigma_{j}\left(\iota (i,j)\right) = i$ , as the probability that a worker sampled at random from $\mathcal{D}$ (equivalently, from the population), is $i^{\mathrm{th}}$ best for job-type $j$ (generates mean reward $\mu_{i,j}$ ); such a worker is said to have type $i$ w.r.t. job-type $j$ . Thus, a type 1 worker w.r.t. job-type $j$ is optimal for jobs of type $j$ . Note that the model allows for staggered optimality of worker-types associated with different job-types, as Figure below illustrates.
+
+
+Figure 1: Possible distribution of worker-types for $\mathcal{J} = \{1,2\}$ and $K_{1} = K_{2} = 2$ . The darker shades represent optimal (type 1) workers while the lighter shades represent inferior (type 2) ones w.r.t. each job-type. In this example, no worker can simultaneously be optimal for both job-types.
+
+High-level description of the matching problem. Each arriving job may be matched one-to-one to a worker from the available supply. Each match takes at most one period for execution, a matched worker thus frees up before the next lot of jobs arrives. Matched jobs leave the system upon completion and the platform receives a stochastic reward for each completed job; a job that remains unmatched drops out instantaneously. The platform has information neither on individual
+
+worker-types w.r.t. job-types nor on their supply distribution, however, it has perfect knowledge of $(K_{j}: j \in \mathcal{J})$ . Subject to this premise, the platform must match incoming jobs to workers in a way that maximizes its expected cumulative payoffs over a sequence of $n$ rounds of matches.
+
+Adaptive control. For any job that arrives at time $t$ , the platform can match it to: (i) a worker that has matched before, (ii) a new worker (one without any history of matches) sampled from the population, or (iii) no worker (job is dropped). A policy $\pi \coloneqq (\pi_1(\cdot ,\cdot),\pi_2(\cdot ,\cdot),\dots)$ is an adaptive rule that prescribes the allocation $\pi_t(\cdot ,\cdot)$ at time $t$ . Specifically, $\pi_{t}(j,k)$ denotes the label of the worker (not its type) that gets matched to the $k^{\mathrm{th}}$ job of type $j$ arriving at time $t$ (provided there are at least $k$ job-arrivals of type $j$ at $t$ and the $k^{\mathrm{th}}$ job is not dropped). Upon match, a [0, 1]-valued stochastic reward with mean $\mu_{\kappa_j(\pi_t(j,k)),j}$ is realized, where $\kappa_{j}\left(\pi_{t}(j,k)\right)\in \{1,\ldots ,K_{j}\}$ encodes the type of worker $\pi_t(j,k)$ w.r.t. job-type $j$ . The realized rewards are independent across matches and in time.
+
+Platform's objective. The goal of maximizing the expected cumulative payoffs over $n$ rounds is converted to minimizing the expected regret relative to a clairvoyant policy that prescribes an "optimal" match for each arriving job. We are thus interested in the following optimization problem
+
+$$
+\inf _ {\pi \in \Pi} \mathbb {E} R _ {n} ^ {\pi} := \inf _ {\pi \in \Pi} \mathbb {E} \left[ \sum_ {t = 1} ^ {n} \sum_ {j \in \mathcal {J}: \Lambda_ {j, t} \geqslant 1} \sum_ {k = 1} ^ {\Lambda_ {j, t}} \left(\mu_ {1, j} - \mu_ {\kappa_ {j} \left(\pi_ {t} (j, k)\right), j}\right) \right]. \tag {1}
+$$
+
+Here, $\Pi$ is the class of non-anticipating policies, i.e., $\pi_{t+1}(\cdot, \cdot)$ is adapted to $\mathcal{F}_t$ for all $t \in \{0, 1, \ldots\}$ , where $\mathcal{F}_t := \sigma\left\{(\Lambda_s, \pi_s, r_s): s = 1, \ldots, t\right\}$ denotes the natural filtration at time $t$ . Here, $\Lambda_s := (\Lambda_{j,s}: j \in \mathcal{J})$ , $\pi_s$ is the set of matches implemented at time $s$ and $r_s$ is the set of collected rewards. The expectation in $(\Pi)$ is w.r.t. the randomness in job-arrivals, worker supply, policy, and rewards.
+
+Going forward, we will adopt standard terminology from the multi-armed bandit literature and refer to workers as "arms" and jobs as "pulls" interchangeably.
+
+# 3 Lower bounds for natural policy classes
+
+For a succinct illustration of the statistical complexity of our problem setting, it is conducive to pivot to the paradigmatic case where the arrival stream comprises only of a single job-type (say $j$ ) arriving one at a time, and the population of workers is partitioned into $K_{j} = 2$ clusters with $\alpha_{1,j} \leqslant 1/2$ (recall that this is the proportion of the optimal worker-type). In this case, one anticipates the problem to be at least as hard as the classical two-armed bandit with a mean reward gap of $\underline{\Delta}_{j} := \mu_{1,j} - \mu_{2,j} > 0$ ; this is on account of the infinitely many alternatives available to the decision maker in our setting as opposed to just two. Indeed, we establish this in Theorem via an information-theoretic approach that delicately handles the combinatorial complexity arising due to probabilities over countably many arms (proof is provided in Appendix C). In what follows, an instance of the problem refers to a collection of reward distributions with means $(\mu_{1,j}, \mu_{2,j})$ (and gap $\underline{\Delta}_{j}$ ). We will overload the notation for expected regret slightly to emphasize its instance-dependence.
+
+Theorem 1 (Information-theoretic lower bounds on achievable performance) Suppose that the arrival process comprises only of a single job-type, say $j \in \mathcal{J}$ , arriving one at a time, i.e., $\Lambda_{j,t} = 1$ for $t = 1,2,\ldots$ . Also suppose that $K_{j} = 2$ and $\alpha_{1,j} \leqslant 1/2 - \epsilon$ , where $\epsilon \in (0,1/2)$ is arbitrary. Let $\Pi_{adm}$ denote the class of admissible policies. Then, the following is true under any $\pi \in \Pi_{adm}$ :
+
+(i) For any $\underline{\Delta}_j > 0$ , there exists a problem instance $\nu$ such that $\mathbb{E}R_n^\pi (\nu)\geqslant C\log n / \underline{\Delta}_j$ for $n$ large enough where $C$ is some absolute constant.
+(ii) For any $n \in \mathbb{N}$ , there exists a problem instance $\nu$ such that $\mathbb{E}R_n^\pi(\nu) \geqslant \epsilon C' \sqrt{n}$ , where $C'$ is some absolute constant.
+
+Distinction from classical MAB. Although the above result bears resemblance to classical information-theoretic lower bounds for finite-armed bandits, it is noteworthy that our setting has a fundamentally greater problem complexity that requires a more nuanced analysis vis-à-vis the finite-armed setting. Traditional proofs, as a result, cannot be translated to our setting in a straightforward manner. To see this, note that when $\alpha_{1,j}$ is high, a new worker is very likely to be optimal;
+
+in the limit as $\alpha_{1,j} \to 1$ , the problem becomes degenerate as all policies incur zero expected regret. Thus, the problem cannot be harder than the two-armed bandit with gap $\underline{\Delta}_j$ uniformly over all values of $\alpha_{1,j}$ . While we conjecture $\alpha_{1,j} < 1$ to be a sufficient condition for the existence of $\Omega\left(\log n / \underline{\Delta}_j\right)$ instance-dependent and $\Omega\left(\sqrt{n}\right)$ instance-independent (minimax) lower bounds (modulo $\alpha_{1,j}$ -dependent scaling factors), there are technical challenges due to probabilistic associations over countably many arms. The restriction to $\alpha_{1,j} < 1/2$ and admissible policies is then necessary for tractability of the proof and it remains unclear if this can be generalized further.
+
+Capturing dependence on $\alpha_{j}$ . Although the instance-dependent lower bound in Theorem1 is tight in $n$ as we shall later see, it fails to provide actionable insights vis-à-vis $\alpha_{j}$ . A natural question in our setting is whether and in what manner does the presence of countably many arms (as opposed to finitely many) affect achievable regret. In particular, how does the difficulty associated with finding from the available supply an optimal worker for a given job type (and the dependence on the distribution $\alpha_{j}$ ) come into play. Below, we propose a lower bound that explicitly captures this dependence, albeit with respect to a somewhat restricted policy class.
+
+Theorem 2 ( $\alpha_{j}$ -dependent lower bound) Suppose that the arrival process comprises only of a single job-type, say $j \in \mathcal{J}$ , arriving one at a time, i.e., $\Lambda_{j,t} = 1$ for $t = 1,2,\ldots$ . Also suppose that $\alpha_{1,j} \leqslant 1/2$ . Denote by $\Pi_{m}$ the class of "memoryless" policies under which the decision to match an incoming job to a new worker at any time $t \in \{1,2,\ldots\}$ is independent of $\mathcal{F}_{t-1}$ . Then, for all problem instances $\nu$ with a minimal sub-optimality gap of at least $\underline{\Delta}_j > 0$ , one has
+
+$$
+\liminf_{n\to \infty}\inf_{\pi \in \Pi_{m}}\frac{\mathbb{E}R_{n}^{\pi}(\nu)}{\log n}\geqslant \frac{\underline{\Delta}_{j}}{4\alpha_{1,j}}.
+$$
+
+Discussion. The proof is located in Appendix D! Several comments are in order. (i) The class $\Pi_{\mathfrak{m}}$ , in particular, includes policies that front-load exploration, i.e., sample upfront a pre-specified number of workers from the population and then deploy a regret minimizing algorithm of choice on the set of workers so obtained. This includes several natural approaches to the problem as we shall later see. (ii) The foremost noticeable aspect of Theorem 2 that differs from Theorem 1 is that it provides a uniform lower bound over all instances that are at least $\underline{\Delta}_j$ -separated in the mean reward, as opposed to merely establishing their existence. (iii) The presence of $\underline{\Delta}_j$ in the numerator in Theorem 2 unlike traditional information-theoretic bounds where $\underline{\Delta}_j$ resides in the denominator suggests that while this bound may be vacuous if $\underline{\Delta}_j$ is "small," it certainly becomes most relevant when $\underline{\Delta}_j$ is "well-separated." In that sense, Theorem 1 and 2 provide a tool to separate regimes of $\underline{\Delta}_j$ where one bound captures the dominant effects vis-à-vis the other. (iv) A novelty of Theorem 2 lies in its proof, which differs from classical lower bound proofs in that it is based entirely on ideas from convex analysis as opposed to the information-theoretic and change-of-measure techniques hitherto used in the literature.
+
+Remarks. (i) It is not impossible to avoid $1 / \alpha_{1,j}$ -scaling in the instance-dependent logarithmic regret. We will later show via an upper bound for our algorithm CAB-K that the $\alpha_{1,j}$ -dependence can, in fact, be relegated to sub-logarithmic terms (CAB-K samples new workers from the population adaptively based on the sample-history of onboarded workers and therefore does not belong to $\Pi_{\mathfrak{m}}$ ). Importantly, this will establish a somewhat surprising fact that the instance-dependent logarithmic bound in Theorem 1 is optimal w.r.t. to its dependence on $\alpha_{1,j}$ (the scaling w.r.t. $\underline{\Delta}_j$ , however, may not be best possible as forthcoming upper bounds will suggest). (ii) Theorem 2 holds also for any worker supply where the optimal mean reward w.r.t. job-type $j$ is at least $\underline{\Delta}_j$ -separated from the rest, the nature of the set of possible worker-types (countable or uncountable) notwithstanding.
+
+# 4 Designing adaptive policies for matching
+
+The approach we adopt in this paper directly addresses the fact that there is an unlimited supply of available workers at all times. A natural design then is to tailor sub-routines specific to job-types in $\mathcal{J}$ and instantiate them at the first arrival of each type. Specifically, if jobs of type $j$ arrive at $\{t_1, t_2, \ldots\}$ , then the platform should call the sub-routine specific to job-type $j$ only at aforementioned times, independent of other job-arrivals. This leads to the meta-algorithm MATCH (see Algorithm [1] for the matching problem. In what follows, ALG refers to an arm-allocation rule w.r.t. a fixed job-type that prescribes one arm upon each invocation. ALG can be thought of as a horizon-free sampling strategy for a countably many-armed bandit problem with one pull per period. When multiple jobs (say $L$ ) of the same type (say $j$ ) arrive at the same time, we instantiate (if necessary) new parallel threads of
+
+ALG specific to job-type $j$ so there exist a total of $L$ type $j$ threads when the next lot of jobs arrives. In the following, $L_{j}$ denotes the running count of the number of parallel threads of ALG for type $j$ jobs.
+
+Algorithm 1 MATCH
+1: Input: (i) $\mathcal{J}$ , (ii) $(K_{j}: j \in \mathcal{J})$ , and (iii) ALG.
+2: Initialization: Set $L_{j} = 0$ for each $j \in \mathcal{J}$ .
+3: for $t \in \{1, 2, \ldots\}$ do
+4: for $j \in \mathcal{J}$ do
+5: if $\Lambda_{j,t} \geqslant 1$ then
+6: if $\Lambda_{j,t} \leqslant L_{j}$ then
+7: Match the $\Lambda_{j,t}$ type $j$ jobs to the first $\Lambda_{j,t}$ threads of ALG for type $j$ jobs.
+8: else
+9: Match the first $L_{j}$ type $j$ jobs to the $L_{j}$ available threads of ALG for type $j$ jobs.
+10: Instantiate $\Lambda_{j,t} - L_{j}$ new threads of ALG for the remaining $\Lambda_{j,t} - L_{j}$ jobs.
+11: Update $L_{j} \gets \Lambda_{j,t}$ .
+
+Discussion of MATCH. An immediate observation from Algorithm $\boxed{1}$ is that ALG must be anytime, i.e., it should not depend on the horizon of play since the number of job arrivals (over the platform's planning horizon) of each type is not known a priori. Keeping this objective in mind, we shift our focus to designing an arm-allocation rule ALG w.r.t. a fixed job-type, say type $j$ , that: (i) prescribes one pull per period, (ii) depends only on $K_{j}$ , (iii) is adaptive to the mean reward vector $\mu_{j}$ and the supply distribution $\alpha_{j}$ , and (iv) is horizon-free. Once such an ALG is designed, its composition with MATCH will transfer learning guarantees to the original matching problem.
+
+# 4.1 Shifting focus to adaptive sequential sampling strategies tailored to a specific job-type
+
+Going forward, we will assume that jobs belong to a common fixed type and arrive one at a time. With slight abuse of notation, the supply of available workers is characterized by $K$ worker-types with distinct means $\pmb{\mu} \coloneqq (\mu_{i} : i = 1, \dots, K)$ adhering to $\mu_{1} > \dots > \mu_{K}$ . The maximal and minimal sub-optimality gaps are given by $\bar{\Delta} \coloneqq \mu_{1} - \mu_{K}$ and $\underline{\Delta} \coloneqq \mu_{1} - \mu_{2}$ respectively, and the minimal reward gap is $\delta \coloneqq \min_{1 \leqslant i < i' \leqslant K} (\mu_{i} - \mu_{i'})$ . The distribution of worker-types is denoted by $\alpha \coloneqq (\alpha_{i} : i = 1, \dots, K)$ , where $\alpha_{i}$ is the probability of sampling a type $i$ arm (characterized by mean $\mu_{i}$ ) from the population. The learning horizon is $n$ . The decision maker only knows $K$ and is oblivious to $(\pmb{\mu}, \pmb{\alpha}, n)$ .
+
+The specific setting described above was first studied in [18] for $K = 2$ for which a UCB-styled algorithm with $\mathcal{O}(\log n)$ regret was proposed. The analysis of said algorithm leveraged certain concentration properties of the UCB1 policy [1] that were recently discovered in the context of a two-armed bandit with equal arm-means (see Theorem 4(i) in [18]). Currently, there is no known algorithm for the general setting with $K > 2$ arm-types. We discuss in the appendix why properties of UCB1 critical to $\mathcal{O}(\log n)$ regret in [18] do not hold for $K > 2$ ; consequently, a natural adaptation of their algorithm to $K > 2$ will likely fail to generalize $\mathcal{O}(\log n)$ bounds. To our best knowledge, the general countable-armed bandit (CAB) setting with $K > 2$ types remained open in prior literature.
+
+We close this gap in the literature by proposing a policy CAB-K (see Algorithm 2) that achieves $\mathcal{O}(\log n)$ regret in the general $K$ -typed setting. CAB-K operates based on the Explore-then-Commit principle with adaptive stopping and re-initialization times. It is noteworthy that CAB-K is not horizon-free; in particular, knowledge of the horizon is critical for appropriate calibration of its stopping and re-initialization thresholds. However, this is not a constraining characteristic and we will use a doubling trick dubbed HF (Algorithm 3) to make it horizon-free with an anytime $\mathcal{O}(\log n)$ guarantee.
+
+Discussion of CAB-K. At any time, the algorithm computes two thresholds of $\mathcal{O}\left(\sqrt{m\log m}\right)$ and $\mathcal{O}\left(\sqrt{m\log n}\right)$ for the $\binom{K}{2}$ pairwise-difference-of-reward processes, $m$ being the per-arm sample count. If the envelope of said process is dominated by the former threshold, the concerned pair likely contains arms of the same type (equal means). The explanation stems from the Law of the Iterated Logarithm (see [14], Theorem 8.5.2): the envelope of a zero-drift length- $m$ random walk grows as $\mathcal{O}\left(\sqrt{m\log\log m}\right)$ . In the aforementioned scenario, the algorithm discards the entire consideration
+
+Algorithm 2 CAB-K
+1: Input: Horizon of play $n$
+2: Set budget $T = n$
+3: Initialize new epoch: Query $K$ new arms; call it consideration set $\mathcal{A} = \{1, 2, \dots, K\}$ .
+4: Play each arm in $\mathcal{A}$ once; observe rewards $\{X_{a,1} : a \in \mathcal{A}\}$ .
+5: Update budget: $T \gets T - K$ .
+6: Per-arm sample count $m \gets 1$ .
+7: Generate $\binom{K}{2}$ independent standard Gaussian random variables $\{\mathcal{Z}_{a,b} : a, b \in \mathcal{A}, a < b\}$ .
+8: while $T \geqslant K$ do
+9: if $\exists a, b \in \mathcal{A}, a < b$ s.t. $|\mathcal{Z}_{a,b} + \sum_{k=1}^{m} (X_{a,k} - X_{b,k})| < 4\sqrt{m\log m}$ then
+10: Permanently discard $\mathcal{A}$ and repeat from step (3).
+11: else
+12: if $|\sum_{k=1}^{m} (X_{a,k} - X_{b,k})| \geqslant 4\sqrt{m\log n} \forall a, b \in \mathcal{A}, a < b$ then
+13: Permanently commit to arm $a^* \in \arg \max_{a \in \mathcal{A}} \{\sum_{k=1}^{m} X_{a,k}\}$ .
+14: else
+15: Play each arm in $\mathcal{A}$ once; observe rewards $(X_{1,m+1}, \dots, X_{K,m+1})$ .
+16: $m \gets m + 1$ .
+17: $T \gets T - K$ .
+
+set and ushers in a new epoch. This is done to avoid the possibility of incurring linear regret should an optimal arm be missing from the consideration set (e.g., when all arms are type 2). In the other scenario that all pairwise-difference-of-reward processes dominate $\mathcal{O}\left(\sqrt{m\log n}\right)$ , the consideration set is likely to contain arms of distinct types (no two have equal means) and the algorithm simply commits to the empirically best arm. Lastly, if neither threshold is crossed (signifying insufficient learning), the sample count for each arm is advanced by one, and the entire process repeats.
+
+Reason for introducing the Gaussian corruption. Centered Gaussian noise is added to all pairwise-difference-of-reward processes in step (9) of CAB-K to avoid the possibility of incurring linear regret should the support of the reward distributions be a "very small" subset of $[0,1]$ . To illustrate this point, suppose that $K = 2$ and the rewards associated with the types are deterministic with a gap of $\underline{\Delta} < 2\sqrt{2\log 2}$ . Then, as soon as the algorithm queries a consideration set containing one arm each of the two types and the per-arm count reaches 2, the difference-of-reward statistic will satisfy $\left|\sum_{j=1}^{2}(X_{1,j} - X_{2,j})\right| = 2\underline{\Delta} < 4\sqrt{2\log 2}$ and the consideration set will be discarded. On the other hand, if both arms are of the same type (simultaneously optimal or inferior), the algorithm will still re-initialize as soon as the per-arm count reaches 2. This will force the algorithm to keep querying new arms from the reservoir at rate that is linear in time, which is tantamount to incurring linear regret in the horizon. The addition of centered Gaussian noise hedges against this risk by guaranteeing that the difference-of-reward process essentially has an infinite support at all times even when the reward distributions might be degenerate. This rids the regret of its fragility w.r.t. the support of reward distributions. The next proposition crystallizes this discussion.
+
+Proposition 1 (Persistence of heterogeneous consideration sets) Let $\{X_{a,k}:k = 1,2,\ldots \}$ be a collection of independent samples from an arm of type $a\in \{1,2,\dots,K\} = :A$ and $\{\mathcal{Z}_{a,b}:a,b\in \mathcal{A},a < b\}$ be a collection of $\binom{K}{2}$ independently generated standard Gaussians. Then,
+
+$$
+\mathbb {P} \left(\bigcap_ {m \geqslant 1} \bigcap_ {a, b \in \mathcal {A}, a < b} \left\{\left| \mathcal {Z} _ {a, b} + \sum_ {k = 1} ^ {m} \left(X _ {a, k} - X _ {b, k}\right) \right| \geqslant 4 \sqrt {m \log m} \right\}\right) > \frac {\bar {\Phi} (f (T _ {0}))}{2} =: \beta_ {\delta , K} > 0, \tag {2}
+$$
+
+where $\bar{\Phi}(\cdot)$ is the tail of the standard Gaussian CDF, and $T_0 := \max \left(\left\lceil \left(64 / \delta^2\right) \log^2\left(\frac{64}{\delta^2}\right)\right\rceil, \mathfrak{C}_K\right)$ with $\mathfrak{C}_K := \inf \left\{p \in \mathbb{N}: \sum_{m=p}^{\infty} \frac{1}{m^8} \leqslant \frac{1}{2K^2}\right\}$ . Lastly, $f(x) := x + 4\sqrt{x \log x}$ for all $x \geqslant 1$ .
+
+The proof is provided in Appendix E; this meta-result is key to the upper bound stated in Theorem 3.
+
+Interpretation of $\beta_{\delta, K}$ . First of all, note that $\beta_{\delta, K}$ admits a closed-form characterization in terms of standard functions and satisfies $\beta_{\delta, K} > 0$ for $\delta > 0$ with $\lim_{\delta \to 0} \beta_{\delta, K} = 0$ . Secondly, $\beta_{\delta, K}$ depends exclusively on $\delta$ and $K$ , and represents a lower bound on the probability that CAB-K will never discard a consideration set containing arms of distinct types.
+
+Theorem 3 (Upper bound on the regret of CAB-K) For any horizon of play $n \geqslant 1$ , the expected regret of the policy $\pi$ given by CAB-K is bounded as
+
+$$
+\mathbb {E} R _ {n} ^ {\pi} \leqslant \frac {C K ^ {3} \bar {\Delta}}{\beta_ {\delta , K}} \left(\frac {\log n}{\delta^ {2}} + \frac {1}{K ! \prod_ {i = 1} ^ {K} \alpha_ {i}}\right),
+$$
+
+where $\beta_{\delta ,K}$ is as defined in (2) and $C$ is some absolute constant.
+
+Discussion. The dependence on the minimal reward gap $\delta$ is not an artifact of our analysis but, in fact, reflective of the operating principle of the algorithm. CAB-K keeps querying new consideration sets of size $K$ until it determines with high enough confidence that no two arms have the same type (equal means); this is the genesis of $\delta$ in the upper bound. Importantly, equipped just with knowledge of $K$ , it remains unclear if there exists an alternative strategy that does not rely on assessing pairwise differences among the queried arms. Another prominent feature of the upper bound is its $\mathcal{O}(1)$ -dependence on $\alpha$ . This essentially means that the difficulty associated with sampling an optimal arm from an infinite reservoir containing finitely many arm-types is of a second order, which starkly contrasts the findings in [12]. Cited paper assumes ex ante knowledge of a lower bound on $\alpha_{1}$ (proportion of optimal arms) and posits no structure on sub-optimal arm-types. Under this premise, a first-order difficulty of sampling optimal arms from the reservoir is established (to wit, the logarithmic term depends on $\alpha_{1}$ ). However, whether this would hold also for the subset of problems where the reservoir only contains a finite universe of arm-types (with known cardinality) was left open. Theorem 3 essentially settles this problem. The proof of Theorem 3 is provided in Appendix F
+
+Remarks. (i) Possible improvements. CAB-K, in its present form, indulges in wasteful exploration by discarding entire consideration sets upon re-initialization. It is possible to be parsimonious in this regard and we leave the pursuit of such algorithms to future work. (ii) More on $\beta_{\delta, K}$ . Notice that when $K = 2$ and $\alpha_1 \leqslant 1/2$ , the upper bound in Theorem $\boxed{3}$ assumes the form $C\beta_{\delta, 2}^{-1} (\log n/\delta + \delta / \alpha_1)$ , where $C$ is some absolute constant. Thus, $\beta_{\delta, 2}^{-1}$ captures the relative increase in problem complexity (vis-à-vis the paradigmatic two-armed bandit with gap $\delta$ ) attributable to an unlimited supply of arms of the two types. To what extent may this factor be shaved off remains an interesting open problem. (iii) Comparison with lower bounds. One should also contrast Theorem $\boxed{3}$ with the lower bound in Theorem $\boxed{2}$ by allowing for policies that query the arm-reservoir adaptively, we could achieve a regret performance robust to $\alpha$ (second-order dependence). This also leads to the somewhat remarkable conclusion that the lower bound in Theorem $\boxed{1}$ is optimal w.r.t. its dependence on $\alpha$ . (iv) Anytime guarantees. A horizon-free version of CAB-K may be obtained by passing it to the HF operator given in Algorithm $\boxed{3}$ ; a logarithmic bound for the resulting composition HF(CAB-K) is stated in Theorem $\boxed{8}$ .
+
+# 4.2 Transferring learning guarantees to the matching problem
+
+Theorem 4 (Achievable performance under MATCH $\circ$ HF(CAB-K)) Denote by $\pi$ the composition of MATCH with $HF(CAB - K)$ . Then, its expected regret after any number $n\geqslant 1$ of rounds satisfies
+
+$$
+\mathbb {E} R _ {n} ^ {\pi} \leqslant C M \sum_ {j \in \mathcal {J}} \left[ \frac {K _ {j} ^ {3} \bar {\Delta} _ {j}}{\beta_ {\delta_ {j} , K _ {j}}} \left(\frac {\log n}{\delta_ {j} {} ^ {2}} + \frac {\log \log (n + 2)}{K _ {j} ! \prod_ {i = 1} ^ {K _ {j}} \alpha_ {i , j}}\right) \right],
+$$
+
+where $\beta_{\delta_j,K_j}$ is as defined in (2) with $\delta \gets \delta_j \coloneqq \min_{1 \leqslant i < i' \leqslant K_j} (\mu_{i,j} - \mu_{i',j})$ and $K \gets K_j$ , $\bar{\Delta}_j \coloneqq \mu_{1,j} - \mu_{K_j,j}$ , and $C$ is some absolute constant.
+
+Discussion. The foremost noticeable aspect of Theorem 4 is that achievable regret depends on $\{\alpha_{j}: j \in \mathcal{J}\}$ (collection of worker-type distributions w.r.t. job-types), surprisingly, only through sub-logarithmic terms. Moreover, when $K_{j} = 2 \forall j \in \mathcal{J}$ , we improve this to an $\mathcal{O}(1)$ -dependence (see Theorem 6 in the appendix). We conjecture that the $\mathcal{O}(\log \log n)$ factor in the upper bound can, in fact, be shaved off also for $K_{j} > 2$ ; pursuits in this direction are left to future work. Among other things, characterizing the minimax complexity of this setting remains a challenging open problem in light of the multiplicative factors that appear in Theorem 4 (fundamentally different from finite-armed problems). Numerical experiments showing $\mathcal{O}(\log n)$ achievable regret are provided in the appendix.
+
+# Acknowledgments and Disclosure of Funding
+
+The authors thank the anonymous reviewers for their constructive feedback on the initial version of this paper. The authors declare an absence of any competing interests, financial or otherwise.
+
+# References
+
+[1] AUER, P., CESA-BIANCHI, N., AND FISCHER, P. Finite-time analysis of the multiarmed bandit problem. Machine learning 47, 2-3 (2002), 235-256.
+[2] BANERJEE, S., GOLLAPUDI, S., KOLLIAS, K., AND MUNAGALA, K. Segmenting two-sided markets. In Proceedings of the 26th International Conference on World Wide Web (2017), pp. 63-72.
+[3] BASU, S., SANKARARAMAN, K. A., AND SANKARARAMAN, A. Beyond $\log^2(t)$ regret for decentralized bandits in matching markets. In International Conference on Machine Learning (2021), PMLR, pp. 705-715.
+[4] BERRY, D. A., CHEN, R. W., ZAME, A., HEATH, D. C., SHEPP, L. A., ET AL. Bandit problems with infinitely many arms. The Annals of Statistics 25, 5 (1997), 2103-2116.
+[5] BEssON, L., AND KAUFMANN, E. What doubling tricks can and can't do for multi-armed bandits. arXiv preprint arXiv:1803.06971 (2018).
+[6] BONALD, T., AND PROUTIERE, A. Two-target algorithms for infinite-armed bandits with bernoulli rewards. In Advances in Neural Information Processing Systems (2013), pp. 2184-2192.
+[7] BUI, L., JOHARI, R., AND MANNOR, S. Clustered bandits. arXiv preprint arXiv:1206.4169 (2012).
+[8] CARPENTIER, A., AND VALKO, M. Simple regret for infinitely many armed bandits. In International Conference on Machine Learning (2015), pp. 1133-1141.
+[9] CEN, S. H., AND SHAH, D. Regret, stability, and fairness in matching markets with bandit learners. arXiv preprint arXiv:2102.06246 (2021).
+[10] CHAN, H. P., AND HU, S. Infinite arms bandit: Optimality via confidence bounds. arXiv preprint arXiv:1805.11793 (2018).
+[11] CHAUDHURI, A. R., AND KALYANAKRISHNAN, S. Quantile-regret minimisation in infinitely many-armed bandits. In UAI (2018), pp. 425-434.
+[12] DE HEIDE, R., CHESHIRE, J., MENARD, P., AND CARPENTIER, A. Bandits with many optimal arms. In Advances in Neural Information Processing Systems (2021), vol. 34, pp. 22457-22469.
+[13] DERMAN, C., LIEBERMAN, G. J., AND ROSS, S. M. A sequential stochastic assignment problem. Management Science 18, 7 (1972), 349-355.
+[14] DURRETT, R. Probability: theory and examples, vol. 49. Cambridge university press, 2019.
+[15] HOEFFDING, W. Probability inequalities for sums of bounded random variables. Journal of the American Statistical Association 58, 301 (1963), 13-30.
+[16] JAGADEESAN, M., WEI, A., WANG, Y., JORDAN, M., AND STEINHARDT, J. Learning equilibria in matching markets from bandit feedback. Advances in Neural Information Processing Systems 34 (2021).
+[17] JOHARI, R., KAMBLE, V., AND KANORIA, Y. Matching while learning. Operations Research 69, 2 (2021), 655-681.
+[18] KALVIT, A., AND ZEEVI, A. From finite to countable-armed bandits. In Advances in Neural Information Processing Systems (2020), vol. 33, pp. 8259–8269.
+[19] KALVIT, A., AND ZEEVI, A. A closer look at the worst-case behavior of multi-armed bandit algorithms. In Advances in Neural Information Processing Systems (2021), vol. 34, pp. 8807-8819.
+[20] LAI, T. L., AND ROBBINS, H. Asymptotically efficient adaptive allocation rules. Advances in applied mathematics 6, 1 (1985), 4-22.
+[21] LATTIMORE, T., AND SZEPESVÁRÍ, C. Bandit algorithms. Cambridge University Press, 2020.
+
+[22] LIU, L. T., MANIA, H., AND JORDAN, M. Competing bandits in matching markets. In International Conference on Artificial Intelligence and Statistics (2020), PMLR, pp. 1618-1628.
+[23] LIU, L. T., RUAN, F., MANIA, H., AND JORDAN, M. I. Bandit learning in decentralized matching markets. Journal of Machine Learning Research 22, 211 (2021), 1-34.
+[24] SANKARARAMAN, A., BASU, S., AND SANKARARAMAN, K. A. Dominate or delete: Decentralized competing bandits with uniform valuation. arXiv preprint arXiv:2006.15166 (2020).
+[25] SANKARARAMAN, A., BASU, S., AND SANKARARAMAN, K. A. Dominate or delete: Decentralized competing bandits in serial dictatorship. In International Conference on Artificial Intelligence and Statistics (2021), PMLR, pp. 1252-1260.
+[26] WANG, Y., AUDIBERT, J.-Y., AND MUNOS, R. Algorithms for infinitely many-armed bandits. In Advances in Neural Information Processing Systems (2009), pp. 1729-1736.
+[27] ZHU, Y., AND NOWAK, R. On regret with multiple best arms. Advances in Neural Information Processing Systems 33 (2020), 9050-9060.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes] Full proofs are provided in the appendix.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [N/A]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [N/A]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [N/A]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [N/A]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [N/A]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/dynamiclearninginlargematchingmarkets/images.zip b/dynamiclearninginlargematchingmarkets/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..76991b52caa05616cde863f4c7c0f10b3d7e0e85
--- /dev/null
+++ b/dynamiclearninginlargematchingmarkets/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:15ca14c71815e506eb180a1b39b62d0ad84b179cae3cb8cc7e24cfd54b12c650
+size 52768
diff --git a/dynamiclearninginlargematchingmarkets/layout.json b/dynamiclearninginlargematchingmarkets/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..614af2fa215b919129d18aed082928a1c753acc1
--- /dev/null
+++ b/dynamiclearninginlargematchingmarkets/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9b298a8937761b049a14e374673a4bd59bac828381fe4a55a3be7f38e44d3ac1
+size 552883
diff --git a/dynamicpricingandassortmentunderacontextualmnldemand/a3138576-1a94-4aa7-befe-80c8d3311e9c_content_list.json b/dynamicpricingandassortmentunderacontextualmnldemand/a3138576-1a94-4aa7-befe-80c8d3311e9c_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..6b1bc3149c8cccec3dfcbb142e39a3d217322833
--- /dev/null
+++ b/dynamicpricingandassortmentunderacontextualmnldemand/a3138576-1a94-4aa7-befe-80c8d3311e9c_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:68a237d1007fda4a75cce35d1c39e7b99dbc10c47591dfda35af963bb9956392
+size 90546
diff --git a/dynamicpricingandassortmentunderacontextualmnldemand/a3138576-1a94-4aa7-befe-80c8d3311e9c_model.json b/dynamicpricingandassortmentunderacontextualmnldemand/a3138576-1a94-4aa7-befe-80c8d3311e9c_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..f865a6f8bba522e3d4ded65232a827460e0abbe4
--- /dev/null
+++ b/dynamicpricingandassortmentunderacontextualmnldemand/a3138576-1a94-4aa7-befe-80c8d3311e9c_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1cb40c8b4a5fc548a5eceda1b1013e6b15cf58ee0c90ae6dae8b51361d677296
+size 112583
diff --git a/dynamicpricingandassortmentunderacontextualmnldemand/a3138576-1a94-4aa7-befe-80c8d3311e9c_origin.pdf b/dynamicpricingandassortmentunderacontextualmnldemand/a3138576-1a94-4aa7-befe-80c8d3311e9c_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..3f796d3493024cdc0779476c3a7694582a9122fe
--- /dev/null
+++ b/dynamicpricingandassortmentunderacontextualmnldemand/a3138576-1a94-4aa7-befe-80c8d3311e9c_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fbbda0709965ceb04a581c8b86aad8c1135123186ca7071f4b5c4e6a1ef8bac2
+size 325398
diff --git a/dynamicpricingandassortmentunderacontextualmnldemand/full.md b/dynamicpricingandassortmentunderacontextualmnldemand/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..dcdda2e9cc49b1a77f4c5fc6c2a64e8da373e047
--- /dev/null
+++ b/dynamicpricingandassortmentunderacontextualmnldemand/full.md
@@ -0,0 +1,428 @@
+# Dynamic pricing and assortment under a contextual MNL demand
+
+Vineet Goyal
+
+Columbia University
+
+New York, NY
+
+vgoyal@ieor.columbia.edu
+
+Noemie Perivier
+
+Columbia University
+
+New York, NY
+
+np2708@columbia.edu
+
+# Abstract
+
+We consider dynamic multi-product pricing and assortment problems under an unknown demand over $T$ periods, where in each period, the seller decides on the price for each product or the assortment of products to offer to a customer who chooses according to an unknown Multinomial Logit Model (MNL). Such problems arise in many applications, including online retail and advertising. We propose a randomized dynamic pricing policy based on a variant of the Online Newton Step algorithm (ONS) that achieves a $O(d\sqrt{T}\log (T))$ regret guarantee under an adversarial arrival model. We also present a new optimistic algorithm for the adversarial MNL contextual bandits problem, which achieves a better dependency than the state-of-the-art algorithms in a problem-dependent constant $\kappa_{2}$ (potentially exponentially small). Our regret upper bound scales as $\tilde{O} (d\sqrt{\kappa_2T} +\log (T) / \kappa_2)$ , which gives a stronger bound than the existing $\tilde{O} (d\sqrt{T} /\kappa_{2})$ guarantees.
+
+# 1 Introduction
+
+In this paper, we consider the contextual dynamic pricing and assortment optimization problems faced by a seller who sequentially observes a contextual demand under bandit feedback. The goal is to learn the underlying model parameters in order to maximize the seller's profit. These problems arise in numerous applications, including pricing and product recommendation in online retail, as well as click-through rate predictions for web search results. Sequential learning is especially important in settings involving short selling seasons or where no historical data is available.
+
+Problem formulation. In both the dynamic pricing and assortment problems, we consider a seller who sells a set of $N$ products over a time horizon of $T$ periods. A new customer arrives in each period $t$ and is offered a set of products or prices. In the pricing problem, the customer arrives with a consideration set and the seller has to decide on the prices of the different products in the consideration set. In the assortment problem, the seller selects the subset of products to offer to the customer. In both cases we assume that the customer's purchase decisions are made according to a multinomial logit model (MNL)([32], [28]) which is widely used in modeling customer preferences. In both problems, the objective is to maximize the seller's expected profit, which is equivalent to minimizing its cumulative expected regret (i.e., the difference between the optimal value and the value obtained by following a given policy).
+
+In this paper, we study a feature-based model, where the product utilities are a function of both products and customers features. In particular, we assume that in each period $t$ , the customer's utility for each product $j \in [N]$ can be written under the form $x_{t,j}^{\top}\theta^{*}$ , where $\theta^{*}$ is an unknown model parameter and $x_{t,j} \in \mathbb{R}^d$ is a feature vector, which can be adversarially chosen (see Sections 2.1 and 3.1 for exact definitions of the problems). Furthermore, we allow feature-dependent price sensitivities in our pricing setting and suppose that the price sensitivities can be expressed as $x_{t,j}^{\top}\alpha^{*}$ for some
+
+unknown parameter $\alpha^{*}$ . Typically, the number of products is significantly larger than the number of features ( $d << N$ ). The objective is to learn across the products and obtain a regret upper bound scaling with $d$ instead of $N$ .
+
+Literature review. Non-feature-based dynamic pricing, where the seller sells identical products to the customers over time, was initially investigated by [22] under various assumptions on the demand curve, and has since been extensively studied (see for instance [8], [14], [7] and [15]). We refer the reader to [13] for an in-depth survey of the area. On the other hand, non-feature-based dynamic assortment optimization was first studied by [9] under the assumption of independent demand for the different products. Dynamic assortment under a MNL choice model has been recently considered (see for instance [36], [37] and [39]). In particular, UCB and Thompson sampling-based policies are proposed in [3] and [4]. These policies achieve optimal regrets of $O(\sqrt{NT})$ in the non-feature based setting.
+
+In this paper, we consider feature-based pricing and assortment problems. Feature-based dynamic pricing has recently received a lot of attention. Most of the existing work study a single product pricing setting under various demand models (linear, binary, generalized linear) and assume that the price sensitivity of each product (i.e., the price coefficient in the demand model) is a known constant (see for instance [19], [20], [5], [12], [27], [26], [24] and [33]). In the single product setting, the most related work is [6], which is the first to incorporate contextual information about the customers under the form of feature-dependent price sensitivities. The benefit of this assumption is illustrated on real datasets. [6] considers a high dimensional setting with a sparsity assumption under a generalized demand model and propose a policy with near-optimal regret. However, they assume i.i.d. features, whereas we consider a more specific demand model (MNL model), but with adversarial features. In [21], is considered a multiple product version of the problem, with feature-based price sensitivities and under the assumption that the demand follows a MNL model. In this last work, the features are also assumed to be i.i.d. Our multi-product pricing setting directly extends [21], and captures the single product setting with unknown (and feature-based) price sensitivity and adversarial features under a binary demand model with logistic noise, for which, to the best of our knowledge, no algorithm with near-optimal regret is known yet.
+
+The MNL feature-based dynamic assortment problem is a variant of the contextual generalized linear bandits problem (see for instance [17], [25] and [2]) with a more complicated state space, in which multiple arms are pulled at the same time. UCB and TS based policies have recently been proposed for the MNL contextual dynamic assortment problem (see for instance [31], [30] and [11]). However, these work suffer from a dependency in a problem-dependent constant $\kappa_{2}$ (potentially exponentially small), which captures the 'degree of non-linearity' of the problem.
+
+Another related stream of literature is that of combinatorial bandits (see for instance [10], [23] and [34]), and in particular, top k combinatorial bandits ([35]). In this framework, the agent can pull a subset of arms of cardinality less than $\mathrm{k}$ in each round and the total reward obtained is a function of the individual rewards for the arms played. However, the reward obtained in our setting for each individual arm depends on the whole set of arms played in period $t$ , whereas the rewards are supposed independent in the aforementioned works.
+
+# 1.1 Our contributions.
+
+In this work, we introduce new algorithms for the dynamic contextual pricing and assortment problems. Our main contribution is the following.
+
+Dynamic pricing. We present a dynamic pricing policy for the multi-product MNL model with adversarial contexts and feature-dependent price sensitivities that achieves a $O(d\log (T)\sqrt{T})$ regret bound. This is near-optimal given the $\Omega (\sqrt{T})$ lower bound from [21]. Based on structural properties of the MNL model, and more specifically, on the self-concordant-like property of the MNL log likelihood function, we propose to use a variant of the Online Newton Step method ([18]) to update our estimators of the model parameters. We combine it with a random price shock policy to force exploration.
+
+Closest to our pricing setting is [21], in which the authors design a multi-product dynamic pricing policy under a MNL choice model and feature-dependent price sensitivities. The proposed algorithm achieves a $\tilde{O} (\sqrt{T})$ regret. However, it relies on a bayesian assumption, namely the feature vectors
+
+are drawn i.i.d. from some unknown distribution. Our work considers an adversarial context and uses an ONS method to update the parameters. Note that the connection with the Online Convex Optimization framework has been exploited in the literature (see for example the stochastic online gradient descent in [19] for the single product setting without price sensitivities), however, the problem we consider is more challenging since the presence of feature-dependent price sensitivities implies the existence of uninformative prices (i.e. prices $p$ such that no pricing policy can learn the true model parameters when repeatedly pricing at price $p$ ). Note that all prices are informative in [19]. The link between uninformative prices and the difficulty to design low regret policies was first pointed out by [8], which shows that no algorithm can achieve better regret than $\Omega(\sqrt{T})$ in settings involving such prices. We address this challenge by using appropriate randomized price shocks that force exploration (we note that adding random shocks was first used in the context of dynamic pricing in [29]; however, our work is the first to simultaneously use random price shocks and an ONS based update, and the analysis of our policy differs from the analysis in [29]).
+
+Our results imply a $O(d\log (T))$ regret in the single product setting with adversarial contexts and without price sensitivity considered in [19], under the extra assumption that the noise follows a logistic distribution. This improves over the $O(\sqrt{T})$ regret bound of [19] in this case (note that [19] studies more precisely the effect of drifts in the parameters). Note that in the same setting, but with feature-dependent price coefficients, our results also imply a $\tilde{O} (\sqrt{T})$ regret. We have become aware that a concurrent recent paper [40] also obtained a logarithmic regret for the contextual single product pricing problem without price sensitivity through a variant of the online newton method (for a more general demand model with strictly log-concave noise). We would like to underscore that our theoretical results were obtained independently from this work. Furthermore, the algorithm proposed in [40] uses the exp-concavity parameter in the descent step and the regret upper bound provided scales with this potentially exponentially small constant. By leveraging the self-concordance property of the logistic loss, we design an algorithm which does not use such parameter, which may be better in practical applications. However, our regret upper bound still depends on this constant. We present in Appendix D some numerical comparison between the two algorithms, which confirms that our algorithm achieves a significantly better regret than the one in [40] as the exp-concavity parameter decreases.
+
+In addition to our main contribution, we present a new algorithm for MNL contextual bandits.
+
+MNL contextual bandits. We consider a setting with uniform product revenues and propose a new UCB-based algorithm for the MNL assortment problem with adversarial contexts. Our algorithm achieves a regret bound of order $\tilde{O}(dK\sqrt{T})$ , which is optimal as a function $T$ . One major limitation of the state-of-the-art algorithms for the MNL contextual bandits problem ([31], [30] and [11]) is that the regret bounds scale with a problem dependent constant, which we will refer to as $\kappa_{2}$ (see Section 3 for a formal definition); $\kappa_{2}$ quantifies the level of non-linearity of the model and can be exponentially small even for moderate size instances ([16]). Our regret bound can be expressed as $C_1 d\sqrt{\sum_{t=1}^{T} \kappa_{2,t}^*} + C_2 d^2 \log(T) / \kappa_{2}$ (where $\kappa_{2,t}^* \leq 1$ are problem dependent constants, whose value decreases as the model is further away from the linear model). Therefore, we give a significantly stronger bound than [31], whose regret term of order $\sqrt{T}$ scales with $1 / \kappa_{2}$ . Note that our first-order term improves for small values of $\{\kappa_{2,t}^*\}$ . Moreover, a prior knowledge of the value of $\kappa_{2}$ is often presupposed in the existing algorithms, which may be a major hindrance to their practical implementation. The quantity $\kappa_{2}$ appears for example in the design of the exploration bonuses of the UCB-MNL algorithm of [31]. Our algorithm does not rely on an a priori knowledge of $\kappa_{2}$ . Our policy is based on optimistic parameter search instead of exploration bonuses, as used in [31]. The analysis relies on a concentration result on the MLE estimators, which uses a generalization of the Bernstein-like tail inequality for self-normalized vectorial martingales in [2] and [16], and leverages the self-concordant property of the MNL log loss.
+
+We would like to mention that a similar result is achieved by [16] and [2] in the logistic bandits setting. Our results cannot, however, be derived from these two works since the MNL contextual bandits problem cannot be formulated as a generalized bandits problem [11]. In this work, we show that the techniques from [16] and [2] can be efficiently extended to the MNL bandit setting, which involves overcoming a few technical challenges that are specific to the MNL problem.
+
+Notations. For any vector $x \in \mathbb{R}^d$ and any positive definite matrix $M \in \mathbb{R}^{d \times d}$ , let $||x||_M = \sqrt{x^T M x}$ . Also let $B_p^d(0, W)$ be the $d$ -dimensional ball of radius $W$ under the norm $\ell^p$ . In the special case of the norm $\ell^2$ , we will drop the index and refer to the $d$ -dimensional ball as $B^d(0, W)$ . For two symmetric matrices $A, B \in \mathbb{R}^{d \times d}$ , $A \succeq B$ means that $A - B$ is semi-definite positive. For $n \in \mathbb{N}$ , we use the notation $[n]$ to denote the set $\{1, \dots, n\}$ . When it is not clear from the context, we use a bold font to denote vectors.
+
+# 2 Multi-product dynamic pricing
+
+# 2.1 Model setting and preliminaries
+
+We consider a dynamic pricing problem for a seller with $N$ products represented by feature vectors $x_{1}, x_{2}, \ldots, x_{N} \in \mathbb{R}^{d}$ . In each period $t$ , a customer arrives with context $z_{t} \in \mathbb{R}^{d}$ and a consideration set $S_{t} \subseteq [N]$ , which can be chosen adversarially. For ease of notation, we consider a more general setting where customer features $z_{t}$ and consideration set $S_{t}$ are represented by $|S_{t}|$ adversarially chosen feature vectors $x_{t,1}, \ldots, x_{t,|S_{t}|} \in \mathbb{R}^{d}$ . For all $t \in [T]$ , let $k_{t} = |S_{t}|$ and let $K \leq N$ be an upper bound on $k_{t}$ for all $t$ . We also define $X_{t}$ as the matrix whose rows are $x_{t,j}$ for $j \in [k_{t}]$ and we refer to it as the context at time $t$ . In each period $t$ ,
+
+1. The seller observes $x_{t,1}, \ldots, x_{t,k_t} \in \mathbb{R}^d$ and offers prices $p_{t,j}$ for all $j \in [k_t]$ .
+2. The customer observes the prices, then purchases one single product $j \in [k_t] \cup \{0\}$ . The probability to purchase each product $j$ is given by:
+
+$$
+q _ {t, j} \left(\left(\theta^ {*}, \alpha^ {*}\right), \vec {p _ {t}}\right) = \left\{ \begin{array}{l} \frac {e ^ {x _ {t , j} ^ {\top} \theta^ {*} - x _ {t , j} ^ {\top} \alpha^ {*} p _ {t , j}}}{1 + \sum_ {i = 1} ^ {k _ {t}} e ^ {x _ {t , i} ^ {\top} \theta^ {*} - x _ {t , i} ^ {\top} \alpha^ {*} p _ {t , i}}} \text {i f} j \geq 1 \\ \frac {1}{1 + \sum_ {i = 1} ^ {k _ {t}} e ^ {x _ {t , i} ^ {\top} \theta^ {*} - x _ {t , i} ^ {\top} \alpha^ {*} p _ {t , i}}} \text {i f} j = 0 \end{array} , \right. \tag {1}
+$$
+
+where $\theta^{*},\alpha^{*}\in \mathbb{R}^{d}$ are two model parameters, which are unknown to the policy maker. For all $j\in [k_t],x_{t,j}^{\top}\alpha^{*}$ represents the price sensitivity of customer $t$ for product $j$ . Note that the customer has always the possibility to leave without making any purchase (by selecting product $j = 0$ ).
+
+3. The policy maker observes only the customer's purchase decision. The binary variable $y_{t,j}$ indicates whether the customer has purchased product $j$ at time $t$ .
+
+For brevity, let $\gamma^{*} = (\theta^{*},\alpha^{*})$ and $\tilde{x}_{t,j} = [x_{t,j}, - p_{t,j}x_{t,j}]$ . We can more simply write the utility $u_{t,j} = x_{t,j}^{\top}\theta^{*} - x_{t,j}^{\top}\alpha^{*}p_{t,j}$ associated with each product as $u_{t,j} = \tilde{x}_{t,j}^{\top}\gamma^{*}$ . Also, for each $t$ and for a given estimator $\gamma_t$ of the true parameter at time $t$ , we denote by $q_{t,j}(\gamma_t,\vec{p_t})$ the estimated purchase probability for product $j$ (obtained by replacing $\gamma^{*}$ by $\gamma_{t}$ in (1)).
+
+We make the following assumptions, which are standard in the dynamic pricing literature:
+
+Assumption 2.1. For all $t,j\in [k_t],||x_{t,j}||_2\leq 1$
+
+Assumption 2.2. $||(\theta^{*},\alpha^{*})||_{2}\leq W$ for some known constant $W$
+
+Although the contexts $\{x_{t,j}\}_{t\in [T],j\in [k_t]}$ can be adversarially chosen, we need to slightly restrict the set of feasible contexts to guarantee the positiveness of the price sensitivity for all products. Following [21], we make the following assumption, which implies that the price-sensitivity of each product is not too close to zero. This assumption may be reasonable in practice: when the price of a product goes to infinity, its utility should decrease significantly.
+
+Assumption 2.3. For all $t \in T, j \in [k_t], x_{t,j}^{\top} \alpha^{*} \geq L$ for some known constant $L$ .
+
+Assumption 2.4. The upper bound $K$ on the number of products in each set $S_{t}$ is constant.
+
+Pricing policy and Benchmark. We consider non-anticipating pricing policies $\pi$ , which depend only on the history up to time $t - 1$ , $\mathcal{H}_{t - 1} = (X_1, p_1', y_1, \dots, X_{t - 1}, p_{t - 1}', y_{t - 1})$ , and the current context $X_t$ . The objective is to design a pricing policy so as to minimize the sellers' cumulative expected regret:
+
+$$
+R ^ {\pi} (T) = \sum_ {t = 1} ^ {T} \left[ \sum_ {i = 1} ^ {k _ {t}} q _ {t, i} \left(\gamma^ {*}, \vec {p _ {t} ^ {*}}\right) p _ {t, i} ^ {*} - \mathbb {E} ^ {\pi} \left(\sum_ {i = 1} ^ {k _ {t}} q _ {t, i} \left(\gamma^ {*}, \vec {p _ {t}}\right) p _ {t, i}\right) \right],
+$$
+
+where $p_t^*$ is the optimal vector of prices in period $t$ . The expectation is taken over the random feedback and any source of randomization in the policy.
+
+Let $p_{max} \coloneqq \frac{1 + K\max(W,1)}{L} + \frac{1}{K}$ . We show in Lemma ?? that for the algorithm we propose, the prices posted at each time $t$ satisfy $p_{t,j} \in [0, p_{max}]$ for all $j \in [k_t]$ . Hence we can consider policies $\pi$ that only post prices in $[0, p_{max}]$ .
+
+Finally, we define the following constant, which provides information about how much a feasible demand curve can deviate from the linear model (a smaller $\kappa_{1}$ implies a larger deviation from the linear model).
+
+$$
+\kappa_{1} = \min_{\gamma \in B^{2d}(0,W),t\geq 1,j\in \{1,\ldots k_{t}\} ,\vec{p}\in [0,p_{\max}]^{k_{t}}}q_{t,j}(\gamma ,\vec{p})q_{t,0}(\gamma ,\vec{p}).
+$$
+
+Note that our pricing policy does not directly use the value of $\kappa_{1}$ . However, this constant still appears in our regret bound (see Section 2.2 for more discussion).
+
+# 2.2 Dynamic pricing policy
+
+Our algorithm combines the two following ingredients: a variant of the ONS method and random price shocks. In particular, we maintain estimators of the parameters which are updated in each iteration by using a variant of ONS on the log likelihood. In each step, our algorithm selects a myopic vector of prices based on the current estimators and adds random price shocks to force exploration and avoid uninformative prices.
+
+We first give the details on the update of the parameters. Given our estimator $\gamma_{t}$ of the true parameters at time $t$ , we let $\ell_t$ denote the log loss at time $t$ :
+
+$$
+\ell_ {t, 1} (\gamma_ {t}) = - \sum_ {j = 0} ^ {k _ {t}} y _ {t, j} \log (q _ {t, j} (\gamma_ {t}, \vec {p _ {t}})).
+$$
+
+For a time-dependent sequence of positive regularizers $\{\lambda_t\}_{t\geq 1}$ (the exact value of the regularizers used in our algorithm is given in Theorem 2.5), the estimator obtained before projection after conducting one step of our descent method is:
+
+$$
+\hat {\gamma} _ {t} = \gamma_ {t - 1} - \frac {1}{\mu} H _ {t - 1} ^ {- 1} \nabla \ell_ {t - 1} (\gamma_ {t - 1}),
+$$
+
+where $\mu = \frac{1}{2(1 + (1 + p_{\mathrm{max}})2\sqrt{6K}W)}$ and $H_{t} = \sum_{s = 1}^{t}\nabla^{2}\ell_{s}(\gamma_{s}) + \lambda_{t}I_{d}$ is the regularized Hessian of the negative log likelihood. Note that for the MNL model, $\ell_{t,1}$ is convex (as can be deduced from Lemma ?? 1.), hence $H_{t}\succ 0$ for all $t$ .
+
+Let $B_{t}$ denote the set $B^{2d}(0,W) \cap \{(\theta ,\alpha)\mid x_{t,j}^{\top}\alpha \geq L \text{ for } j\in [k_{t}]\}$ . $B_{t}$ represents the set of parameters which satisfy Assumptions 2.2 and 2.3. We obtain the new estimator $\gamma_{t}$ by projecting $\hat{\gamma}_{t}$ on the feasible set of parameters:
+
+$$
+\gamma_ {t} = \Pi_ {B _ {t}} ^ {H _ {t - 1}} (\hat {\gamma} _ {t}),
+$$
+
+where $\Pi_{B_t}^{H_{t-1}}(y) = \arg \min_{x \in B_t} (x - y)^T H_{t-1}(x - y)$ is the projection relatively to the norm induced by $H_{t-1}$ . As a result, during all the course of the algorithm, our estimator $\gamma_t$ also satisfies the lower and upper boundedness assumptions.
+
+Finally, the seller chooses a perturbation factor $\delta_t = \frac{1}{Wt^{1/4}}$ and computes, independently for each product $j \in [k_t]$ , a random price shock $\Delta p_{t,j}$ which takes value $\delta_t$ with probability $1/2$ and $-\delta_t$ with probability $1/2$ . The seller posts the vector of prices $\vec{p_t}$ which is the sum of the random price shocks and the myopic vector of prices $g(X_t\alpha_t, X_t\theta_t)$ (see Appendix ?? for a formal definition). The pseudo code of our dynamic pricing policy is presented in Algorithm 1.
+
+Running time: The two main computational steps of Algorithm 1 are calculating the inverse of $H_{t}$ and projecting the parameter back in the set of feasible parameters relative to the norm $H_{t}$ . The time complexity of the first step is $O(d^{3})$ , which is reasonable when $d$ is not too large as in the setting we consider. The projection step can also be done efficiently by formulating the problem as a Quadratic Programming problem.
+
+Using an online descent method for the parameters estimation allows us to obtain a low regret algorithm despite the presence of adversarial contexts. We would like to note that based on our current analysis, a simpler online method such as a stochastic online gradient descent (as proposed
+
+Algorithm 1 Online Newton method for multiple product pricing
+Input: Upper bound W on $||(\theta^{*},\alpha^{*})||_{2}$ , lower bound L, sequence of regularizers $\{\lambda_t\}_{t\geq 1}$ . Initialize $\theta_{1},\alpha_{1}\in B_{1}$
+for all $t\geq 1$ do
+ For $j\in [k_t]$ , let $\Delta p_{t,j} = \left\{ \begin{array}{ll} \frac{1}{Wt^{1 / 4}} & \mathrm{w / p}\frac{1}{2}\\ \frac{-1}{Wt^{1 / 4}} & \mathrm{w / p}\frac{1}{2} \end{array} \right.$
+ For $j\in [k_t]$ , set $p_{t,j} = g(X_t\alpha_t,X_t\theta_t)_j + \Delta p_{t,j}$
+ Post prices $\vec{p_t}$
+ Observe feedback $\vec{y_t}$
+ Set $\gamma_{t + 1} = (\theta_{t + 1},\alpha_{t + 1})$ as follows: $\gamma_{t + 1} = \Pi_{B_{t + 1}}^{H_t}\left(\gamma_t - \frac{1}{\mu} H_t^{-1}\nabla \ell_{t,1}(\gamma_t)\right)$
+end for
+
+in [19] for single-product dynamic pricing without price sensitivity) would not allow us to obtain sublinear regret. We would also like to mention that our method is different from the Online Newton Step presented in [18], which is the classic online analogue of the Newton method. The ONS method moves into the direction of $A_{t}^{-1}\nabla \ell_{t,1}$ , where $A_{t}^{-1}$ is an approximation of the inverse of the Hessian. In our case, we move directly into the direction of the inverse of the Hessian multiplied by $\nabla \ell_{t,1}$ , and leverage self-concordant-like properties of the negative log likelihood function of the MNL model to show the convergence of the estimators. This allows us to avoid using the parameter $1 / \kappa_1$ (which corresponds to the exp-concavity parameter $\beta$ in the literature) in the descent step, as is done by the ONS algorithm.
+
+We are ready to present our regret bound.
+
+Theorem 2.5. Setting $\lambda_1 = 1$ , $\lambda_t = d\log(t)$ for all $t \geq 1$ , there is a constant $C$ depending only on $W, L, K$ such that the regret of Algorithm 1 is bounded as:
+
+$$
+R ^ {\pi} (T) \leq C d \log (T) \sqrt {T}.
+$$
+
+The proof of Theorem 2.5 is presented in Appendix ??. We would like to point out that, even though our algorithm does not use the parameter $1 / \kappa_{1}$ , it still appears within the constant $C$ .
+
+Under the assumptions of [19] (single product dynamic pricing with adversarial contexts and constant price sensitivity), and assuming that the noise has a logistic distribution, we can show the following regret bound, which contrasts with the $O(\sqrt{T})$ upper bound established in [19].
+
+Corollary 2.6. If $k_{t} = 1$ for all $t$ , and if the price coefficient is a known constant, then setting $\lambda_{1} = 1$ , $\lambda_{t} = d\log (t)$ for all $t \geq 1$ , and letting $\Delta p_{t,1} = 0$ at each step, there is a constant $C$ depending only on $W$ such that the regret of Algorithm 1 with regularizers $\{\lambda_t\}$ and price shocks $\{\Delta p_{t,1}\}$ is bounded as:
+
+$$
+R ^ {\pi} (T) \leq C d \log (T).
+$$
+
+# 2.3 High level ideas and sketch of the proof.
+
+We provide here the main ideas in the proof of Theorem 2.5. The technical details are presented in Appendix ??. We first follow the classical regret analysis for dynamic pricing policies and decompose the regret between a term due to the error in the estimation of the parameters and a term due to the random price shocks. In particular, we have the following lemma.
+
+Lemma 2.7. There exist constants $C_1, C_2$ depending only on $W, L, K$ , such that:
+
+$$
+R ^ {\pi} (T) \leq \mathbb {E} \left[ C _ {1} C _ {2} \sum_ {t = 1} ^ {T} \sum_ {j = 1} ^ {k _ {t}} \left[ \left(\left(\alpha_ {t} - \alpha^ {*}\right) ^ {T} x _ {t, j}\right) ^ {2} + \left(\left(\theta_ {t} - \theta^ {*}\right) x _ {t, j}\right) ^ {2} \right] + C _ {1} \sum_ {t = 1} ^ {T} \left\| \Delta \vec {p _ {t}} \right\| ^ {2} \right]. \tag {2}
+$$
+
+Since the variances of the random price shocks are $\frac{1}{W^2\sqrt{t}}$ , the second term is $O(\sqrt{T})$ . Therefore, to exhibit a $\tilde{O} (\sqrt{T})$ regret bound, it suffices to focus on upper bounding the first term. Note that it follows from (2) that the regret upper bound does not require the global convergence of the estimators
+
+to the true parameters. We only need to show that they converge sufficiently fast in the directions given by the contexts seen throughout the T periods.
+
+For any sequence of prices $\{\vec{p_t}\}_{t = 1}^T$ , our online descent method allows us to control the convergence of the estimated utilities $u_{t,j} = x_{t,j}^{\top}\theta_{t} - x_{t,j}^{\top}\alpha_{t}p_{t,j}$ to the true utilities $u_{t,j}^{*} = x_{t,j}^{\top}\theta^{*} - x_{t,j}^{\top}\alpha^{*}p_{t,j}$ for each product $j\in [k_t]$ . In particular, we have the following lemma.
+
+Lemma 2.8. There is a constant $\tilde{C}$ depending only on $W, L, K$ such that with probability at least $1 - \frac{\log(T)}{T^2}$ ,
+
+$$
+\sum_ {t = 1} ^ {T} \sum_ {j = 1} ^ {k _ {t}} (x _ {t, j} ^ {\top} (\theta_ {t} - \theta^ {*}) - x _ {t, j} ^ {\top} (\alpha_ {t} - \alpha^ {*}) p _ {t, j}) ^ {2} \leq \tilde {C} d \log (T).
+$$
+
+We present the proof in Appendix ??. Note that the upper bound in Lemma 2.8 is valid for any sequence of prices posted by the seller. However, it is not possible, in general, to derive directly Theorem 2.5 from Lemma 2.8 without an appropriate price experimentation scheme. Suppose at each step we only post the myopic vector of prices $\vec{p_t} = g(X_t\alpha_t,X_t\theta_t)$ . If the prices $\{p_{t,j}\}$ happened to be uninformative (i.e. $x_{t,j}^{\top}(\theta_t - \theta^*) - x_{t,j}^{\top}(\alpha_t - \alpha^*)p_{t,j} = 0$ ), then the left-hand side in Lemma 2.8 would be zero and the bound provided would not be useful. However, adding random price shocks allows us to deviate from uninformative prices and to derive an upper bound on the first term of (2) based on Lemma 2.8. This concludes the proof of Theorem 2.5. If there is a single product $(k_{t} = 1)$ , and there is no price sensitivity (i.e. for all $t$ , the coefficient in front of $p_{t,1}$ is a known constant, that we assume to be 1 without loss of generality), note that from Lemma 2.8, we get $\sum_{t}x_{t}^{T}(\theta_{t} - \theta_{*}) = O(d\log (T))$ . Combining this with (2) and the choice of $\Delta p_{t,1} = 0$ for all $t$ , we immediately obtain Corollary 2.6.
+
+In [19], where no price sensitivity is involved and the utility is simply written under the form $u_{t} = x_{t}^{\top}\theta^{*}$ , the use of a stochastic gradient descent method allows the author to directly obtain a $O(\sqrt{T})$ bound on the sum $\sum_{t=1}^{T}x_{t}^{\top}(\theta_{t} - \theta^{*})^{2}$ . Such a bound, when combined with our random price shocks, would only give us a linear regret. By exploiting the special structure of the MNL function and using our variant of the ONS instead of an online gradient descent, we obtain the stronger $O(\log(T))$ bound of Lemma 2.8.
+
+The proof of Lemma 2.8 is based on a lower and an upper bound on $\sum_{t=1}^{T} \ell_{t,1}(\gamma_t) - \ell_{t,1}(\gamma^*)$ . Both involve $\sum_{t=1}^{T} \sum_{j=1}^{k_t} (x_{t,j}^\top (\theta_t - \theta^*) - x_{t,j}^\top (\alpha_t - \alpha^*) p_{t,j})^2$ . The proof of the lower bound exploits the convexity of $\ell_{t,1}$ and is based on a Bernstein inequality for martingales difference sequences. This is similar to the inequality used in [19]. The main technical hindsight lies in the proof of the upper bound. It mimics the analysis of the Online Newton Step method presented in [18], but relies on the specific structure of the gradient and Hessian of $\ell_{t,1}$ for the MNL model. Moreover, it unically exploits the self concordant-like property of $\ell_{t,1}$ . Let's first recall the definition of a self-concordant-like function.
+
+Definition 2.9 (self-concordant-like functions [38]). A convex function $f \in C^3(\mathbb{R}^n)$ is called a self-concordant-like function if:
+
+$$
+| \phi^ {\prime \prime} (t) | \leq M _ {f} \phi^ {\prime \prime} (t) \| u \| _ {2}
+$$
+
+for $t \in \mathbb{R}$ and $M_f > 0$ , where $\phi(t) \coloneqq f(x + tu)$ for any $x \in \operatorname{dom}(f)$ and $u \in \mathbb{R}^n$ .
+
+By adapting the proof of Lemma 4 in [38], we show in Appendix ?? the following property.
+
+Proposition 2.10. $\ell_{t,1}$ is self-concordant-like with $M_f = (1 + p_{\max}) \sqrt{6|S_t|}$ .
+
+We also detail in Appendix ?? some useful properties satisfied by self-concordant-like functions.
+
+# 3 Improved algorithm for MNL contextual bandits
+
+# 3.1 Problem formulation
+
+We consider the following MNL dynamic assortment optimization problem, also referred as the MNL contextual bandits. In each period $t$ , the seller observes feature vectors $\{x_{t,j}\}_{j=1}^{N} \in \mathbb{R}^d$ . As
+
+before, this represents a combination of customer and product features which can be adversarially chosen. The seller needs to decide on the set $S_{t} \subseteq [N]$ to offer, with $|S_{t}| \leq K$ . Given the offered assortment, the customer purchases one single product $j \in S_{t} \cup \{0\}$ . Each product $j$ is purchased with probability:
+
+$$
+q _ {t, j} \left(S _ {t}, \theta^ {*}\right) = \left\{ \begin{array}{l} \frac {e ^ {x _ {t , j} ^ {\top} \theta^ {*}}}{1 + \sum_ {i \in S _ {t}} e ^ {x _ {t , i} ^ {\top} \theta^ {*}}} \text {i f} j \in S _ {t} \\ \frac {1}{1 + \sum_ {i \in S _ {t}} e ^ {x _ {t , i} ^ {\top} \theta^ {*}}} \text {i f} j = 0 \end{array} \right. \tag {3}
+$$
+
+where $\theta^{*} \in \mathbb{R}^{d}$ is an underlying model parameter. As before, the binary variable $y_{t,j}$ indicates whether the customer has purchased product $j$ at time $t$ . Note that our model encompasses the contextual logistic bandit problem with finitely many arms (which corresponds to the case where $K = 1$ ). The objective is to minimize the cumulative expected regret over the T periods:
+
+$$
+R (T) = \sum_ {t = 1} ^ {T} \left[ \sum_ {j \in S _ {t} ^ {*}} q _ {t, j} \left(S _ {t} ^ {*}, \theta^ {*}\right) - \sum_ {j \in S _ {t}} q _ {t, j} \left(S _ {t}, \theta^ {*}\right) \right],
+$$
+
+where $S_{t}^{*}$ denotes the optimal assortment at time $t$ .
+
+In [31], the authors study a more general model where a reward $r_{t,j} \in [0,1]$ is also revealed for each product at time $t$ . We consider the case of uniform rewards $(r_{t,j} = 1)$ for all products. Maximizing $\sum_{j \in S_t} q_{t,j}(S_t, \theta)$ over all sets $S \subseteq [N]$ of cardinality at most $K$ is now equivalent to selecting the $K$ products which have the highest utility $x_{t,j}^{\top} \theta$ . Hence the set $S_t$ as well as the optimal set $S_t^*$ always contain exactly $K$ products.
+
+Similarly as in the pricing setting, we make the following two assumptions:
+
+Assumption 3.1. For all $t\in [T],j\in [N],||x_{t,j}||_2\leq 1$
+
+Assumption 3.2. $||\theta^{*}||_{2}\leq W$ for some known constant W.
+
+Following [31], we also introduce the following constant, which typically appears in connection to the link function in the generalized linear bandits ([17], [25]).
+
+$$
+\kappa_{2}:= \min_{|S|\leq K,j\in S,t\geq 1}\min_{\| \theta^{*}\| \leq W}q_{t,j}(S,\theta)q_{t,0}(S,\theta) > 0.
+$$
+
+A smaller value of $\kappa_{2}$ can be interpreted as a bigger deviation from the linear model. As mentioned before, the regret bound of the dynamic assortment policies of [31] and [11] exhibit a harmful dependency in $\kappa_{2}$ . Besides, an a priori knowledge of the value of $\kappa_{2}$ is presupposed. Our goal is to design a dynamic assortment policy which does not require prior knowledge of $\kappa_{2}$ and achieves a regret with a better dependency in $\kappa_{2}$ . For all $t\in [T]$ , let $\kappa_{2,t}^{*} = \sum_{j\in S_{t}^{*}}q_{t,j}(S_{t}^{*},\theta^{*})q_{t,0}(S_{t}^{*},\theta^{*})$ . $\kappa_{2,t}^{*}$ represents the degree of non-linearity for the optimal set $S_{t}^{*}$ and depends on the unknown parameter $\theta^{*}$ as well as on the feature vectors present at time $t$ . We show that the $\tilde{O} (\sqrt{T})$ term of our regret bound can be replaced by a $\tilde{O}\left(\sqrt{\sum_{t = 1}^{T}\kappa_{2,t}^{*}}\right)$ term. Note that we always have $\kappa_{2,t}^{*}\leq 1$ hence this is a strict improvement. As a result, a high level of non-linearity at time $t$ induces a smaller $\kappa_{2,t}^{*}$ and positively impacts the regret.
+
+# 3.2 Dynamic assortment policy
+
+We design a tight confidence set for the true parameter $\theta^{*}$ and use it to construct upper confidence bounds on the utility of each product at time $t$ . Our algorithm relies on optimistic parameter search over the confidence interval, as used by [2] in the logistic bandits setting. However, in our setting, the seller's decision at time $t$ involves the choice of multiple products. Hence we cannot build a unique optimistic estimator $\theta_{t}$ as in [2]. The key idea is to do the optimistic parameter search independently for each product, generating a set of parameters $\{\tilde{\theta}_{t,j}\}_{j=1}^{N}$ such that with high probability, $x_{t,j}^{\top} \tilde{\theta}_{t,j}$ is an upper bound on the utility $x_{t,j}^{\top} \theta^{*}$ of product $j$ .
+
+Confidence set. The main ingredient is the design of a confidence set for $\theta^{*}$ . We classically start by computing the maximum likelihood estimator of $\theta^{*}$ . Let $\hat{\theta}_t$ be the unique minimizer of the
+
+following function, for a sequence of time-dependent regularizers $\{\lambda_t\}_{t=1}^T$ (the exact values are given in Theorem 3.4):
+
+$$
+\mathcal {L} _ {t} ^ {\lambda_ {t}} (\theta) = - \sum_ {s = 1} ^ {t - 1} \sum_ {j \in S _ {s}} y _ {s, j} \log (q _ {s, j} (S _ {s}, \theta)) + \frac {\lambda_ {t}}{2} \| \theta \| ^ {2}.
+$$
+
+$\hat{\theta}_t$ satisfies the equation $\nabla \mathcal{L}_t^{\lambda_t}(\theta) = 0$ , where the gradient of $\mathcal{L}_t^{\lambda_t}(\theta)$ is given by: $\nabla \mathcal{L}_t^{\lambda_t}(\theta) = \sum_{s=1}^{t-1} \sum_{j \in S_s} (q_{s,j}(S_s, \theta) - y_{s,j}) x_{s,j} + \lambda_t \hat{\theta}_t$ . Following [2], for all $\delta \in [0,1)$ , we now define a confidence set $C_t(\delta)$ for $\theta^*$ as follows:
+
+$$
+C _ {t} (\delta) := \left\{\theta \in \Theta | \| g _ {t} (\theta) - g _ {t} (\hat {\theta} _ {t}) \| _ {H _ {t} ^ {- 1} (\theta)} \leq \gamma_ {t} (\delta) \right\},
+$$
+
+where $g_{t}(\theta) \coloneqq \sum_{s=1}^{t-1} \sum_{j \in S_{s}} q_{s,j}(S_{s},\theta) x_{s,j} + \lambda_{t}\theta$ , where $H_{t}(\theta)$ is the Hessian of the regularized negative log likelihood evaluated at $\theta$ , i.e.,
+
+$$
+H _ {t} (\theta) := \sum_ {s = 1} ^ {t - 1} \left[ \sum_ {i \in S _ {s}} q _ {s, i} (S _ {s}, \theta) x _ {s, i} x _ {s, i} ^ {T} - \sum_ {i \in S _ {s}} \sum_ {j \in S _ {s}} q _ {s, i} (S _ {s}, \theta) q _ {s, j} (S _ {s}, \theta) x _ {s, i} x _ {s, j} ^ {T} \right] + \lambda_ {t} I _ {d}
+$$
+
+and where
+
+$$
+\gamma_ {t} (\delta) = \sqrt {\lambda_ {t}} (W + \frac {1}{2}) + \frac {2 d}{\sqrt {\lambda_ {t}}} \log \left(\frac {4}{\delta} \left(1 + \frac {2 t K}{d \lambda_ {t}}\right)\right).
+$$
+
+The following proposition is the analogue, in the multi-product setting, of Proposition 1 in [2] and establishes that $C_t(\delta)$ is a confidence set for $\theta^*$ . The details are given in Appendix ??
+
+Proposition 3.3. Let $\delta \in (0,1]$ . Then $\mathbb{P}(\forall t,\theta^{*}\in C_{t}(\delta))\geq 1 - \delta$
+
+The proof of Proposition 3.3 builds upon the new Bernstein-like tail inequality for self-normalized vectorial martingales presented in [16]. However, Theorem 1 in [16] does not directly apply to our setting because of the correlation between the variables $\{\varepsilon_{t,j} \coloneqq y_{t,j} - q_{t,j}(S_t,\theta^*)\}_{j\in S_t}$ induced by the presence of multiple purchase options in period $t$ . We thus present a generalization of Theorem 1 in [16] for the multiple products setting that handles such correlation.
+
+Algorithm. Before describing our algorithm, let's introduce the following notation, which generalizes the choice probabilities given by (3) to the case where the model parameters corresponding to each product are uncorrelated. More precisely, we now consider some estimator $\tilde{\theta} \in \mathbb{R}^{d \times N}$ of the true parameters. For all $j \in [N]$ , $\tilde{\theta}_j$ represents the parameter associated with product $j$ . The estimated probability that item $j$ is purchased at time $t$ if assortment $S \subseteq [N]$ is offered is computed as:
+
+$$
+\tilde {q} _ {t, j} (S, \tilde {\theta}) = \left\{ \begin{array}{l} \frac {e ^ {x _ {t , j} ^ {\top} \tilde {\theta} _ {j}}}{1 + \sum_ {i \in S} e ^ {x _ {t , i} ^ {\top} \tilde {\theta} _ {i}}} \text {i f} j \in S \\ \frac {1}{1 + \sum_ {i \in S} e ^ {x _ {t , i} ^ {\top} \tilde {\theta} _ {i}}} \text {i f} j = 0 \end{array} \right.
+$$
+
+Now, at time $t$ , our algorithm uses the previous contexts and observations to compute the maximum likelihood estimator $\hat{\theta}_t$ as defined above and constructs the confidence set $C_t(\delta)$ . Then, for each product $j \in [N]$ , the algorithm finds an optimistic parameter $\tilde{\theta}_{t,j} = \arg \max_{\theta \in C_t(\delta)} x_{t,j}^\top \theta$ . We offer the set $S_t$ of the K items maximizing the optimistic expected revenue $\tilde{r}_t(S,\tilde{\theta})$ :
+
+$$
+\tilde {r} _ {t} (S, \tilde {\theta}) = \sum_ {j \in S} \tilde {q} _ {t, j} (S, \tilde {\theta}).
+$$
+
+Since we assumed all prices to be unit, this is equivalent to offering the $K$ products with highest $x_{t,j}^{\top}\tilde{\theta}_{t,j}$ . In the case of non-uniform revenues, our algorithm is still valid; however, an extra factor $1 / \kappa_2$ would appear in the regret upper bound with our current analysis. We also note that Algorithm 2 is mainly of theoretical interest, since computing each $\tilde{\theta}_{t,j}$ remains computationally expensive.
+
+We now present the our upper bound on the regret of our policy.
+
+Theorem 3.4. For $\delta = \frac{1}{K^2T^2}$ , $\lambda_1 = 1$ , and $\lambda_t = d\log (tK)$ for all $t\geq 1$ , the regret of Algorithm 2 satisfies, for some constants $\tilde{C}_1$ and $\tilde{C}_2$ that do not depend on $d,K,T$ and that depend only polynomially on $W$ :
+
+$$
+R (T) \leq \tilde {C} _ {1} K d \log (K T) \left(\sqrt {\sum_ {t = 1} ^ {T} \kappa_ {2 , t} ^ {*}}\right) + \frac {\tilde {C} _ {2} d ^ {2} K ^ {4}}{\kappa_ {2}} \log (K T) ^ {2}.
+$$
+
+# Algorithm 2 OFU-MNL
+
+Input: Upper bound K on the size of an assortment, $\delta$ , sequence $\{\lambda_t\}_{t=1}^T$
+
+for all $t\geq 1$ do Observe feature vectors $\{x_{t,1},\dots,x_{t,N}\}$ Set $\hat{\theta}_t = \arg \min \mathcal{L}_t^{\lambda_t}(\theta)$ For $j = 1,\ldots ,N$ set $\tilde{\theta}_{t,j} = \arg \max_{\theta \in C_t(\delta)}x_{t,j}^\top \theta$ Offer set $S_{t} = \arg \max_{|S|\leq K}\tilde{r}_{t}(S,\tilde{\theta})$ Receive feedback $\vec{y_t}$
+end for
+
+# 3.3 High level ideas and sketch of the proof
+
+We first condition on the event that $\theta^{*} \in C_{t}(\delta)$ , for all $t \geq 1$ . Proposition 3.3 shows that this happens with high probability. From Lemma ?? (Appendix ??), we have the following concentration result on the optimistic parameter $\tilde{\theta}_{t,j}$ associated with each product $j \in [N]$ :
+
+$$
+\left\| \theta^ {*} - \tilde {\theta} _ {t, j} \right\| _ {H _ {t} \left(\theta^ {*}\right)} \leq (1 + \sqrt {6 K} W) \gamma_ {t} (\delta). \tag {4}
+$$
+
+Now, using the optimistic choice of assortment made by the algorithm as well as the fact that $x_{t,j}^{\top}\tilde{\theta}_{t,j}$ is an upper bound on the true utility for each product, we can first bound the regret as follows:
+
+$$
+\begin{array}{l} R (T) = \sum_ {t = 1} ^ {T} \left[ \sum_ {j \in S _ {t} ^ {*}} q _ {t, j} \left(S _ {t} ^ {*}, \theta^ {*}\right) - \sum_ {j \in S _ {t}} q _ {t, j} \left(S _ {t}, \theta^ {*}\right) \right] \leq \sum_ {t = 1} ^ {T} \left[ \sum_ {j \in S _ {t}} \tilde {q} _ {t, j} \left(S _ {t}, \tilde {\theta} _ {t}\right) - \sum_ {j \in S _ {t}} \tilde {q} _ {t, j} \left(S _ {t}, \tilde {\theta} ^ {*}\right) \right] \\ \leq \sum_ {t = 1} ^ {T} \sum_ {j \in S _ {t}} q _ {t, j} (S _ {t}, \theta^ {*}) q _ {t, 0} (S _ {t}, \theta^ {*}) x _ {t, j} ^ {\top} (\tilde {\theta} _ {t, j} - \theta^ {*}) + R _ {2} (T) := R _ {1} (T) + R _ {2} (T). \\ \end{array}
+$$
+
+where $R_{2}(T)$ is a second order term which we will prove to be of order $O(d^{2}K^{4}\log (KT)^{2} / \kappa_{2})$ . To show that the first term is of order $O\left(Kd\log (KT)\sqrt{\sum_{t = 1}^{T}\kappa_{2,t}^{*}}\right)$ , we first use the concentration result stated in (4), which implies the following upper bound, for some $C > 0$ :
+
+$$
+R _ {1} (T) \leq C \sqrt {d \log (K T)} \sum_ {t = 1} ^ {T} \sum_ {j \in S _ {t}} \left[ q _ {t, j} \left(S _ {t}, \theta^ {*}\right) q _ {t, 0} \left(S _ {t}, \theta^ {*}\right) | | x _ {t, j} | | _ {H _ {t} \left(\theta^ {*}\right) ^ {- 1}} \right].
+$$
+
+Using that $H_{t}(\theta^{*}) \succeq \kappa_{2}\sum_{s = 1}^{T}\sum_{j\in S_{s}}x_{s,j}x_{s,j}^{\top}$ , we could already show that this term is of order $\tilde{O} (\sqrt{T})$ by applying the Elliptical Potential Lemma from [1]. However, we would then obtain a term with linear dependency in $1 / \kappa_{2}$ . We show that the local information given by the terms $\{q_{t,j}(S_t,\theta^*)q_{t,0}(S_t,\theta^*)\}$ and the self-concordance-like property of the log loss can be used to derive a tighter bound on the above sum. The complete version of the proof is provided in Appendix ??
+
+# 4 Conclusion
+
+In this paper, we study contextual dynamic pricing and assortment optimization problems under a MNL choice model. We present a dynamic pricing policy based on a variant of the Online Newton Step method combined with random price shocks that achieves near-optimal regret for the MNL model with adversarial contexts and feature-dependent price sensitivities. We also propose a new optimistic algorithm for the adversarial MNL contextual bandits problem. Both our algorithms leverage the self-concordant property of the MNL log likelihood function to achieve better dependency on potentially exponentially small parameters than existing algorithms. An interesting research direction would be to extend our results to other choice models, such as the nested logit model, which is another widely used model in the Revenue Management literature.
+
+# References
+
+[1] Yasin Abbasi-yadkori, Dávid Pál, and Csaba Szepesvári. Improved algorithms for linear stochastic bandits. In J. Shawe-Taylor, R. Zemel, P. Bartlett, F. Pereira, and K. Q. Weinberger, editors, Advances in Neural Information Processing Systems, volume 24, pages 2312-2320. Curran Associates, Inc., 2011.
+[2] Marc Abeille, Louis Faury, and Clément Calauzènes. Instance-wise minimax-optimal algorithms for logistic bandits, 2020.
+[3] Shipra Agrawal, Vashist Avadhanula, Vineet Goyal, and Assaf Zeevi. Mnl-bandit: A dynamic learning approach to assortment selection. CoRR, abs/1706.03880, 2017.
+[4] Shipra Agrawal, Vashist Avadhanula, Vineet Goyal, and Assaf Zeevi. Thompson sampling for the mnl-bandit. CoRR, abs/1706.00977, 2017.
+[5] Kareem Amin, Afshin Rostamizadeh, and Umar Syed. Repeated contextual auctions with strategic buyers. In Z. Ghahramani, M. Welling, C. Cortes, N. Lawrence, and K. Q. Weinberger, editors, Advances in Neural Information Processing Systems, volume 27, pages 622-630. Curran Associates, Inc., 2014.
+[6] GahhYi Ban and N. Bora Keskin. Personalized dynamic pricing with machine learning. SSRN Electronic Journal, 01 2017.
+[7] Omar Besbes and Assaf Zeevi. Dynamic pricing without knowing the demand function: Risk bounds and near-optimal algorithms. Operations Research, 57(6):1407-1420, 2009.
+[8] Josef Broder and Paat Rusnevichientong. Dynamic pricing under a general parametric choice model. Operations Research, 60:965-980, 08 2012.
+[9] Felipe Caro and Jérémie Gallien. Dynamic assortment with demand learning for seasonal consumer goods. Management Science, 53(2):276-292, 2007.
+[10] Wei Chen, Yajun Wang, and Yang Yuan. Combinatorial multi-armed bandit: General framework and applications. In Proceedings of the 30th International Conference on Machine Learning, ICML 2013, Atlanta, GA, USA, 16-21 June 2013, volume 28 of JMLR Workshop and Conference Proceedings, pages 151-159. JMLR.org, 2013.
+[11] Xi Chen, Yining Wang, and Yuan Zhou. Dynamic assortment optimization with changing contextual information, 2019.
+[12] Maxime C. Cohen, Ilan Lobel, and Renato Paes Leme. Feature-based dynamic pricing. In EC '16, 2016.
+[13] Arnoud V. Den Boer. Dynamic pricing and learning: Historical origins, current research, and new directions. Surveys in Operations Research and Management Science, 20, 06 2015.
+[14] Arnoud V. Den Boer and Bert Zwart. Mean square convergence rates for maximum quasi-likelihood estimator. Stochastic Systems, 4:375–403, 01 2014.
+[15] Vivek F. Farias and Benjamin Van Roy. Dynamic pricing with a prior on market response. Operations Research, 58(1):16-29, 2010.
+[16] Louis Faury, Marc Abeille, Clément Calauzènes, and Olivier Fercoq. Improved optimistic algorithms for logistic bandits, 2020.
+[17] Sarah Filippi, Olivier Cappe, Aurélien Garivier, and Csaba Szepesvári. Parametric bandits: The generalized linear case. In J. Lafferty, C. Williams, J. Shawe-Taylor, R. Zemel, and A. Culotta, editors, Advances in Neural Information Processing Systems, volume 23, pages 586-594. Curran Associates, Inc., 2010.
+[18] Elad Hazan, Amit Agarwal, and Satyen Kale. Logarithmic regret algorithms for online convex optimization. Mach. Learn., 69(2-3):169-192, 2007.
+
+[19] Adel Javanmard. Perishability of data: Dynamic pricing under varying-coefficient models, 2017.
+[20] Adel Javanmard and Hamid Nazerzadeh. Dynamic pricing in high-dimensions, 2018.
+[21] Adel Javanmard, Hamid Nazerzadeh, and Simeng Shao. Multi-product dynamic pricing in high-dimensions with heterogeneous price sensitivity, 2019.
+[22] Robert Kleinberg and Tom Leighton. The value of knowing a demand curve: Bounds on regret for online posted-price auctions. In Proceedings of the 44th Annual IEEE Symposium on Foundations of Computer Science, FOCS '03, page 594, USA, 2003. IEEE Computer Society.
+[23] Branislav Kveton, Zheng Wen, Azin Ashkan, and Csaba Szepesvári. Tight regret bounds for stochastic combinatorial semi-bandits. CoRR, abs/1410.0949, 2014.
+[24] Renato Paes Leme and Jon Schneider. Contextual search via intrinsic volumes. In Mikkel Thorup, editor, 59th IEEE Annual Symposium on Foundations of Computer Science, FOCS 2018, Paris, France, October 7-9, 2018, pages 268-282. IEEE Computer Society, 2018.
+[25] Lihong Li, Yu Lu, and Dengyong Zhou. Provable optimal algorithms for generalized linear contextual bandits. CoRR, abs/1703.00048, 2017.
+[26] Allen Liu, Renato Paes Leme, and Jon Schneider. Optimal contextual pricing and extensions. In Daniel Marx, editor, Proceedings of the 2021 ACM-SIAM Symposium on Discrete Algorithms, SODA 2021, Virtual Conference, January 10 - 13, 2021, pages 1059-1078. SIAM, 2021.
+[27] Ilan Lobel, Renato Paes Leme, and Adrian Vladu. Multidimensional binary search for contextual decision-making. Oper. Res., 66(5):1346-1361, 2018.
+[28] D. Mcfadden. Modelling the choice of residential location. *Transportation Research Record*, 1977.
+[29] Mila Nambiar, David Simchi-Levi, and He Wang. Dynamic learning and pricing with model misspecification. Management Science, 65(11):4980-5000, 2019.
+[30] Min-hwan Oh and Garud Iyengar. Thompson sampling for multinomial logit contextual bandits. In H. Wallach, H. Larochelle, A. Beygelzimer, F. d'Alché-Buc, E. Fox, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 32, pages 3151-3161. Curran Associates, Inc., 2019.
+[31] Min-hwan Oh and Garud Iyengar. Multinomial logit contextual bandits: Provable optimality and practicality. In Thirty-Fifth AAAI Conference on Artificial Intelligence, AAAI 2021, Thirty-Third Conference on Innovative Applications of Artificial Intelligence, IAAI 2021, The Eleventh Symposium on Educational Advances in Artificial Intelligence, EAAI 2021, Virtual Event, February 2-9, 2021, pages 9205-9213. AAAI Press, 2021.
+[32] R. L. Plackett. The analysis of permutations. Journal of the Royal Statistical Society. Series C (Applied Statistics), 24(2):193-202, 1975.
+[33] Sheng Qiang and Mohsen Bayati. Dynamic pricing with demand covariates, 2016.
+[34] Lijing Qin, Shouyuan Chen, and Xiaoyan Zhu. Contextual combinatorial bandit and its application on diversified online recommendation. In Mohammed Javeed Zaki, Zoran Obradovic, Pang-Ning Tan, Arindam Banerjee, Chandrika Kamath, and Srinivasan Parthasarathy, editors, Proceedings of the 2014 SIAM International Conference on Data Mining, Philadelphia, Pennsylvania, USA, April 24-26, 2014, pages 461-469. SIAM, 2014.
+[35] Idan Rejwan and Yishay Mansour. Combinatorial bandits with full-bandit feedback: Sample complexity and regret minimization. CoRR, abs/1905.12624, 2019.
+[36] Paat Rusmevichientong, Zuo-Jun Max Shen, and David B. Shmoys. Dynamic assortment optimization with a multinomial logit choice model and capacity constraint. Operations Research, 58(6):1666-1680, 2010.
+
+[37] Denis Saure and Assaf Zeevi. Optimal dynamic assortment planning with demand learning. Manufacturing & Service Operations Management, 15(3):387-404, 2013.
+[38] Quoc Tran-Dinh, Yen-Huan Li, and Volkan Cevher. Composite convex minimization involving self-concordant-like cost functions, 2018.
+[39] Yining Wang, Xi Chen, and Yuan Zhou. Near-optimal policies for dynamic multinomial logit assortment selection models. In S. Bengio, H. Wallach, H. Larochelle, K. Grauman, N. Cesa-Bianchi, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 31, pages 3101-3110. Curran Associates, Inc., 2018.
+[40] Jianyu Xu and Yu-Xiang Wang. Logarithmic regret in feature-based dynamic pricing. CoRR, abs/2102.10221, 2021.
+
+# Checklist
+
+The checklist follows the references. Please read the checklist guidelines carefully for information on how to answer these questions. For each question, change the default [TODO] to [Yes], [No], or [N/A]. You are strongly encouraged to include a justification to your answer, either by referencing the appropriate section of your paper or providing a brief inline description. For example:
+
+- Did you include the license to the code and datasets? [Yes] See Section.
+- Did you include the license to the code and datasets? [No] The code and the data are proprietary.
+- Did you include the license to the code and datasets? [N/A]
+
+Please do not modify the questions and only use the provided macros for your answers. Note that the Checklist section does not count towards the page limit. In your paper, please delete this instructions block and only keep the Checklist section heading above along with the questions/answers below.
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential negative societal impacts of your work? [No]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes] See Appendix for the complete proofs.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)?[Yes]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [No]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [N/A]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/dynamicpricingandassortmentunderacontextualmnldemand/images.zip b/dynamicpricingandassortmentunderacontextualmnldemand/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..7c83ba70a6ff752580623fceebae28e19fdcdb1a
--- /dev/null
+++ b/dynamicpricingandassortmentunderacontextualmnldemand/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e1b30902ad562c7d1344b8c3a71cf443377f89b6a355c5e5e030ef963341a722
+size 193867
diff --git a/dynamicpricingandassortmentunderacontextualmnldemand/layout.json b/dynamicpricingandassortmentunderacontextualmnldemand/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..a0bffb4a4cf534bb8c0eda81535bcefb6c4f416c
--- /dev/null
+++ b/dynamicpricingandassortmentunderacontextualmnldemand/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9482ba35085bae38a90b74cb434c832d3560e9b0d50246e60437de8d783533ef
+size 647263
diff --git a/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/58d64748-0e9e-41bf-839e-59dd223ff64c_content_list.json b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/58d64748-0e9e-41bf-839e-59dd223ff64c_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..1f215ee24032ac4d02b9b5ebdc7d165a453c1429
--- /dev/null
+++ b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/58d64748-0e9e-41bf-839e-59dd223ff64c_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a39cb06ce0f691220c91368746479ba39c9cf38d54eb59097437aee50b664ef4
+size 66881
diff --git a/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/58d64748-0e9e-41bf-839e-59dd223ff64c_model.json b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/58d64748-0e9e-41bf-839e-59dd223ff64c_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..43fc506e55253043aa5cf783283a38d214892b5f
--- /dev/null
+++ b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/58d64748-0e9e-41bf-839e-59dd223ff64c_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:04310fbfe7d12a77cc46b2b80d935b90b0f1b962d346578e5c56c54425f90c30
+size 81130
diff --git a/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/58d64748-0e9e-41bf-839e-59dd223ff64c_origin.pdf b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/58d64748-0e9e-41bf-839e-59dd223ff64c_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..0aba99b432d2a9d00f0a7de3ad5f05096702b05a
--- /dev/null
+++ b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/58d64748-0e9e-41bf-839e-59dd223ff64c_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1057c0c4b26ae9b91f81835dcaaa69850a896941a38cc8448cadb7de03bf6814
+size 548847
diff --git a/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/full.md b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..4618ca6d27edb620470c1d4cbd669321a663bc16
--- /dev/null
+++ b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/full.md
@@ -0,0 +1,325 @@
+# Dynamic Pricing with Monotonicity Constraint Under Unknown Parametric Demand Model
+
+Su Jia, Andrew Li, R. Ravi
+
+Tepper School of Business
+
+Carnegie Mellon University
+
+{sjia1,aali1,ravi}@andrew.cmu.edu
+
+# Abstract
+
+We consider a Continuum-Armed Bandit problem with an additional monotonicity constraint (or "markdown" constraint) on the actions selected. This problem faithfully models a natural revenue management problem, called "markdown pricing", where the objective is to adaptively reduce the price over a finite horizon to maximize the expected revenues. Chen ([3]) and Jia et al ([9]) recently showed a tight $T^{3/4}$ regret bound over $T$ rounds under minimal assumptions of unimodality and Lipschitzness in the reward function. This bound shows that markdown pricing is strictly harder than unconstrained dynamic pricing (i.e., without the monotonicity constraint), which admits $T^{2/3}$ regret under the same assumptions ([11]). However, in practice, demand functions are usually assumed to have certain functional forms (e.g. linear or exponential), rendering the demand learning easier and suggesting better regret bounds. In this work we introduce a concept, markdown dimension, that measures the complexity of a parametric family, and present optimal regret bounds that improve upon the previous $T^{3/4}$ bound under this framework.
+
+# 1 Introduction
+
+Dynamic pricing under unknown demand arises naturally for the sale of new products, where the demand function is not available in advance. The seller in this case has to learn the demand function over time and hence faces a learning-vs-earning trade-off. This problem is therefore usually formulated as a Multi-Armed Bandit (MAB) model. Although bandit problems have been well understood theoretically, in practice, however, we rarely see retailers implement such policies. This is a largely because some practical constraints which can potentially cause customer dissatisfaction are overlooked. For example, a price increase may sometimes create a manipulative image of the retailer and negatively impact their ratings. For example, [13] analyzed the online menu prices of a set of restaurants and concluded that "on average, a $1\%$ price increase leads to $3 - 5\%$ decrease in online ratings". Therefore, retailers sometimes implicitly face a monotonicity constraint (which we call "markdown constraint"), which requires that the prices selected be non-increasing. A pricing policy that satisfies such a constraint is usually referred to as markdown pricing policy.
+
+Thus motivated, in this work, we consider the markdown pricing problem with unknown demand, under various assumptions. Although unconstrained dynamic pricing under unknown demand has been extensively studied, little is known about markdown pricing under unknown demand. Recently, [3] and [9] independently showed that unimodality and Lipschitzness in the revenue function (defined as the product of the price and the mean demand) are necessary to achieve sublinear regret. In this setting, any reasonable policy must reduce the price at a moderate rate and stop only when there is sufficient evidence for overshooting the optimal price. By selecting suitable parameters, [3, 9] showed that the above policy is indeed optimal, achieving a tight $T^{3/4}$ regret bound.
+
+However, in practice, it is usually assumed that the demand function has a certain parametric form, such as linear, exponential or logit form. Intuitively, this extra structure enables faster learning rate and suggests better regret bounds. This motivates our first question:
+
+Q1) Can we improve the $T^{3/4}$ regret bound for markdown pricing for parametric demand families?
+
+Noticeably, there is a known separation result between the assumption that the corresponding reward function is Lipschitz and unimodal. In fact, [3, 9] showed a tight $T^{3/4}$ regret bound, which is asymptotically higher than $T^{2/3}$ , the optimal regret bound for unconstrained pricing ([11]) under the same assumptions. This highlights the extra complexity caused by the monotonicity constraint, and motivates the next question:
+
+Q2) Is there still a provable "separation" between markdown and unconstrained pricing under parametric assumptions?
+
+While one can answer the Q1 and Q2 for specific parametric families, we aim at finding a unified framework that captures the hardness of demand learning for a given parametric family. This motivates the following question:
+
+Q3) Can we find a general framework to unify the regret bounds for different categories of families, rather than specific results for specific families?
+
+In this work, we propose such a framework by introducing a concept called markdown dimension. We provide efficient markdown policies for each markdown dimension, which we also show to be best possible, thereby completely settling the problem.
+
+# 1.1 Our Contributions.
+
+In this work, we make the following contributions.
+
+1. New Complexity Measure for Demand Learning. We introduce a new concept called **markdown dimension**, which captures the complexity of performing markdown pricing on a family, answering Q3. Within this framework, we provide a complete settlement of the problem as specified below.
+2. **Markdown Policies with Theoretical Guarantees.** For each finite markdown dimension $d \geq 0$ , we present an efficient markdown pricing policy with sublinear regret. The exploration proceeds in phases of varying lengths. In each phase $j$ , the policies derive a confidence interval $I_{j} \subseteq I_{j-1}$ for the optimal price $p^{*}$ based on observations from evenly spaced prices, which are lower than the prices used in phase $j-1$ . The exploration terminates if there is sufficient evidence that the current price is lower than $p^{*}$ . We show that for $d = 0$ and $d \geq 1$ , our policies achieve regret $O(\log^2 T)$ and $\tilde{O}(T^{\frac{d}{d+1}})$ respectively, settling Q1.
+3. Separation From Unconstrained Pricing: Tight Lower Bounds. We complement our upper bounds with a matching lower bound for each integer $d$ . More precisely, we show an tight $\Omega(\log^2 T)$ lower bound for $d = 0$ , which is lower than the known $O(\log T)$ regret bound without this monotonicity constraint (see [2]). For finite $d \geq 1$ , we show an $\Omega(T^{\frac{d}{d+1}})$ lower bound, which not only matches our upper bound but is also higher than the tight $\tilde{\Theta}(T^{1/2})$ bound without markdown constraint (see [2, 10]). These lower bound results combined settle Q2.
+4. Impact of Smoothness: We go further to refine our bounds and investigate the impact of smoothness of reward function around the optimal price. We consider a sensitivity parameter $s$ , which essentially says that the reward function is only $O(\varepsilon^s)$ suboptimal if the price is at an $\varepsilon$ distance away from the optimal price. For both finite and infinite $d$ , we extend our upper bounds to incorporate $s$ .
+
+As the most basic case, one can verify from Taylor's Theorem that when the demand function is assumed to admit (i) a continuous second derivative, and (ii) an optimal price in the interior of the domain, then $s = 2$ . We highlight our results for $s = 2$ in red in Table 1, where $\Theta$ denotes tight upper and lower bounds.
+
+| Markdown Dimension | Markdown Pricing | Unconstr. Pricing |
| d=0 | Θ(log2T) | Θ(logT) [2] |
| 1 ≤ d < ∞ | Θ(Td/(d+1)) | Θ(√T) [2] |
| d=∞ | Θ(T3/4) [3, 9] | Θ(T2/3) [11] |
+
+Table 1: Regret bounds for $s = 2$ .
+
+# 1.2 Related Work
+
+In the Multi-Armed Bandit (MAB) problem, the player is offered a finite set of arms, with each arm providing a random revenue from an unknown probability distribution specific to that arm. The objective of the player is to maximize the total revenue earned by pulling a sequence of arms (e.g. [12]). Our pricing problem generalizes this framework by using an infinite action space $[0, 1]$ with each price $p$ corresponding to an action whose revenue is drawn from an unknown distribution with mean $R(p)$ . In the Lipschitz Bandit problem (see, e.g., [1]), it is assumed that each $x \in [0, 1]$ corresponds to an arm with mean reward $\mu(x)$ , where $\mu$ is an unknown $L$ -Lipschitz function. For the one-dimensional case, [11] showed a tight $\tilde{\Theta}(T^{2/3})$ regret bound.
+
+Recently there is an emerging line of work on bandits with monotonicity constraint. [3] and [9] recently independently considered the dynamic pricing problem with monotonicity constraint under unknown demand function, and proved nearly-optimal $T^{3/4}$ regret bound assuming the reward function is Lipschitz and unimodal. Moreover, they also showed that these assumptions are indeed minimal, in the sense that no markdown policy achieves $o(T)$ regret without any one of these two assumptions. Motivated by fairness constraints, [8] and [15] considered a general online convex optimization problem where the action sequence is required to be monotone.
+
+Other constraints on the arm sequence motivated by practical problems are also considered in the literature. For example, motivated by the concern that customers are hostile to frequent price changes (see e.g. [5]), [4, 14] and [16] considered pricing policies with a given budget in the number of price changes. Motivated by clinical trials, [6] studied the best arm identification problem when the reward of the arms are monotone and the goal is to identify the arm closest to a threshold.
+
+# 2 Model and Assumptions
+
+We begin by formally stating our model. In this work we assume an unlimited supply of a single product. Given a discrete time horizon of $T$ rounds, in each round $t$ , the policy (representing the "seller") selects a price $p_t$ (the particular interval [0, 1] is without loss of generality, by scaling). The demand $D_t$ in this round is then independently drawn from a fixed distribution with unknown mean $D(p_t)$ , and the policy receives revenue (or reward, which we will use interchangeably) $p_t$ for each unit sold, and hence a total of $p_t \cdot D_t$ revenue in this round. The only constraint the policy must satisfy is the markdown constraint: $p_1 \geq \dots \geq p_T$ with probability 1.
+
+The function $D(p)$ which maps each price $p$ to the mean demand at this price is known as the demand function. For any policy $\pi$ and demand function $D(\cdot)$ , we use $r(\pi, D)$ to denote the expected total reward of $\pi$ under $D$ . Rather than evaluating policies directly in terms of $r(\pi, D)$ , it is more informative (and ubiquitous in the literature on MAB) to measure performance using the notion of regret with respect to a certain idealized benchmark. Specifically, since we assumed unlimited supply, when the true reward function is known, the seller simply always selects a revenue-maximizing price $p_D^* = \arg \max_{p \in [0,1]} p \cdot D(p)$ at each round, and we denote this maximal reward rate to be $r_D^* = \max_{p \in [0,1]} p \cdot D(p)$ . The regret of a policy is then defined with respect to this quantity, and we seek to bound the worst-case value over a given family of demand functions.
+
+Definition 1 (Regret). For any policy $\pi$ and demand function $D$ , define the regret of policy $\pi$ under $D$ as $\operatorname{Reg}(\pi, D) \coloneqq r_D^* \cdot T - r(\pi, D)$ . For any given family $\mathcal{F}$ of demand functions, the worst-case regret (or simply regret) of policy $\pi$ for family $\mathcal{F}$ is $\operatorname{Reg}(\pi, \mathcal{F}) \coloneqq \sup_{D \in \mathcal{F}} \operatorname{Reg}(\pi, D)$ .
+
+# 2.1 Basic Assumptions
+
+Now we state the common assumptions that all of our results rely on. A demand function $D(\cdot)$ is associated with a revenue function (or, reward function) $R(p) = p \cdot D(p)$ . Sometimes it is more convenient to work directly with the revenue functions, in which cases we abuse the notations and denote by $\operatorname{Reg}(\pi, R)$ the regret of under reward function $R$ .
+
+Definition 2 (Optimal Price Mapping). Let $\mathcal{F}$ be a set of functions defined on $S \subseteq \mathbb{R}$ . For any function $R: S \to \mathbb{R}$ , let $M(R)$ be the subset of its global maxima on $S$ . The optimal price mapping $p^*: \mathcal{F} \to S$ is defined as $p^*(R) = \inf M(R)$ .
+
+We first introduce a standard assumption (see e.g. [2]) that the derivative of $R$ vanishes at $p^*(R)$ .
+
+Assumption 1 (First Order Optimality). We assume that every reward function $R$ is differentiable on its domain, and moreover, $R'(p^*(R)) = 0$ .
+
+If, in addition, $R$ is twice continuously-differentiable, then by Taylor expansion around $p^*$ , $|R(p^*) - R(p^* + \varepsilon)| = \frac{1}{2} R''(p^*) \cdot \varepsilon^2 + o(\varepsilon^2)$ . Thus, if a policy overshoots the optimal price by $\varepsilon$ , then only an $O(\varepsilon^2)$ loss is incurred in each round. We next introduce a distributional assumption.
+
+Definition 3 (Subgaussian Random Variable). Define the subgaussian norm of a random variable $X$ as $\| X\|_{\psi_2} \coloneqq \inf \{c > 0:\mathbb{E}[e^{X^2 /c^2}]\leq 2\}$ . Say $X$ is subgaussian if $\| X\|_{\psi_2} < \infty$ .
+
+Assumption 2 (Subgaussian noise). There exists a constant $C_{sg} > 0$ such that under any true demand function and any price $p$ , the random demand $X$ at price $p$ satisfies $\| X\|_{\psi_2}\leq C_{sg}$ .
+
+# 2.2 Warm-up: Markdown Pricing on Linear Demand
+
+To introduce the key concept, markdown dimension, let's take linear demand as a warm-up. Consider $D(x; \theta) = \theta_1 - \theta_2 x$ for $x \in \left[\frac{1}{2}, 1\right]$ and the following natural markdown policy for $\mathcal{F} = \{D(x; \theta) : \theta_1, \theta_2 \in \left[\frac{1}{2}, 1\right]\}$ : collect a number of samples at two prices $p_1, p_2$ close to 1, and denote by $\bar{d}_1, \bar{d}_2$ the empirical mean demands. By the Fundamental Theorem of Algebra, since a degree- $d$ polynomial can be uniquely determined by its value at $d$ distinct points, there is a $\hat{\theta} \in \mathbb{R}^2$ satisfying $D(p_i; \hat{\theta}) = \bar{d}_i$ for $i = 1, 2$ . Finally, select the optimal price of $D(\cdot; \hat{\theta})$ in remaining rounds.
+
+This policy is "robust" in the following sense. Suppose $\bar{d}_i$ deviates from the mean $D(p_i; \theta)$ by $\sim \delta$ , then the estimation error in $\theta$ is $\sim \frac{\delta}{|p_1 - p_2|}$ , i.e., proportional to $\delta$ and inverse proportional to the gap between the two sample prices.
+
+For more complex demand models, the dependence on the "divergence" of the sample prices changes. To characterize such dependence, we introduce the notion of **markdown dimension**. Informally, a parameterized family has markdown dimension $d$ if for any set of $d$ prices at distance $h$ apart, an $O(\delta)$ error on the estimated demands results in an $O\left(\frac{\delta}{h^d}\right)$ estimation error on the model parameter. We make this idea formal in the subsequent sections.
+
+# 2.3 Identifiability and Robust Parametrization
+
+Intuitively, the exploration-exploitation trade-off for markdown pricing becomes harder to manage as the given family becomes more complex. Consider, for example, linear demand functions. If each function takes the form $D(p; c) = 1 + cp$ where only $c \in (0,1)$ is unknown and $p \in [0,1]$ , then the seller simply needs to estimate the price elasticity $c$ by sampling sufficiently many times at $p = 1$ .
+
+In contrast, if the demand function is $D(p; a, b) = a - bp$ where both $a, b$ are unknown, then sampling at one price would not suffice. Rather, one needs to select (at least) two distinct prices, say $p$ and $p'$ , to fit a linear function, thereby facing the following dilemma. Suppose $p < p'$ are far apart, then, $p$ may be far away from the optimal price $p^*$ if $p^*$ is close to $p'$ , resulting in high regret. Otherwise, when $p, p'$ are close-by, the demand learning requires a high volume of samples, which also leads to a high regret.
+
+Thus we reach a natural question: can we introduce a notion of complexity to measure the difficulty of performing markdown pricing on a given family, and then provide tight regret bounds in terms for each level of complexity? In this work, we propose a novel concept of markdown dimension and provide nearly-optimal regret bounds in terms of this complexity metric. The formal definition relies
+
+on two other concepts which we introduce in the next two subsections: the identifiability of a family, and the robustness of a parametrization.
+
+Identifiability Our notion of identifiability generalizes a key property of single-variable polynomials, that every degree- $d$ polynomial can be uniquely determined by its values at any $(d + 1)$ points. To present the formal definition, we first introduce a mapping which, for a fixed subset of prices, assigns each demand function a profile based on its values at those prices.
+
+Definition 4 (Profile Mapping). Consider a set $\mathcal{F}$ of real-valued functions defined on $A \subseteq \mathbb{R}$ . For any $\mathbf{p} = (p_0, p_1, \dots, p_d) \in A^{d+1}$ , the profile-mapping at prices $\mathbf{p}$ is defined as
+
+$$
+\begin{array}{l} \Phi_ {\mathbf {p}}: \mathcal {F} \to \mathbb {R} ^ {d + 1}, \\ D \mapsto \left(D \left(p _ {0}\right), D \left(p _ {1}\right), \dots , D \left(p _ {d}\right)\right). \\ \end{array}
+$$
+
+We may subsequently call $\Phi_{\mathbf{p}}(D)$ the profile of function $D$ at $\mathbf{p}$ .
+
+Informally, a family of functions is said to be $d$ -identifiable, if the graphs of any two functions intersect for at most $d$ times. For example, the family of all degree $d$ polynomials is $d$ -identifiable.
+
+Definition 5 (Identifiability). A family $\mathcal{F}$ of functions defined on $S\subseteq \mathbb{R}$ is $d$ -identifiable, if for any distinct $p_0,p_1,\ldots ,p_d\in S$ , the profile mapping $\Phi_{p_0,\dots ,p_d}$ is injective, i.e. $\mathcal{F}(f)\neq \mathcal{F}(\tilde{f})$ for any distinct $f,\tilde{f}\in \mathcal{F}$
+
+We will soon use the following fact: if a family is $d$ -identifiable, then for any distinct $p_0, p_1, \ldots, p_d$ the inverse profile-mapping $\Phi_{\mathbf{p}}^{-1}: \mathcal{R}_p \to \mathcal{F}$ exists, where $\mathcal{R}_p$ is the range of the mapping $\Phi_{\mathbf{p}}$ .
+
+Robust Parametrization We first formally define a parametrization.
+
+Definition 6 (Parametrization). An order- $m$ parametrization for a family $\mathcal{F}$ of functions is a one-to-one mapping from some set $\Theta \subseteq \mathbb{R}^m$ to $\mathcal{F}$ . Moreover, each $\theta \in \Theta$ is called a parameter.
+
+We use $D(p;\theta)$ to denote the function in $\mathcal{F}$ that parameter $\theta$ corresponds to. For example, for $D(p;\theta_1,\theta_2) = \theta_1 - \theta_2\cdot p$ is a parametrization of the family of linear functions. As a standard assumption (see e.g. [2]), we assume $\Theta$ to be compact, which leads to many favorable properties.
+
+Assumption 3 (Compact Domain). The domain $\Theta$ of the parametrization is compact.
+
+Under this assumption, the demand functions in $\mathcal{F}$ are bounded, and thus we may without loss of generality scale the range (i.e. target space) of those functions to be [0, 1].
+
+Assumption 4 (Smoothness). The mapping $D:[0,1]\times \Theta \to \mathbb{R}$ is twice continuously differentiable. In particular, since $[0,1]\times \Theta$ is compact, under the above assumption, there exist constants $C^{(j)} > 0$ such that $|D^{(j)}(p,\theta)|\leq C^{(j)}$ for any $(p,\theta)\in [0,1]\times \Theta$ and $j = 0,1,2$ .
+
+By abuse of notation, we view the optimal price mapping $p^*$ as being defined on $\Theta$ , rather than on $\mathcal{F}$ as before. Formally, let $M(\theta)$ be the set of global maxima of $R(x; \theta)$ , then $p^*(\theta) = \inf R(x; \theta)$ . For example, for $D(p; \theta_1, \theta_2) = \theta_1 - \theta_2 \cdot p$ one can verify that $p^* = \frac{\theta_1}{2\theta_2}$ . The next assumption allows us to "propagate" the estimation error in $\theta$ to that of $p^*(\theta)$ .
+
+Assumption 5 (Lipschitz Optimal Price Mapping). The optimal price mapping $p^* : \Theta \to [0,1]$ is $C^*$ -Lipschitz for some constant $C^* > 0$ .
+
+This assumption has appeared in the previous literature on parametric demand learning, see e.g. Assumption 1(c) of [2]. Moreover, it is satisfied by many basic demand functions such as linear, exponential and logit demand. For instance, let $D(p;c) = 1 - cp$ where $p,c\in [0,1]$ , then $p^* (c) = \min \{\frac{1}{2c},1\}$ , which is 1-Lipschitz. Nonetheless, this assumption is somewhat unnatural as it is not made on the parametrization directly, we leave it open whether there is an assumption imposed directly on $\mathcal{F}$ that implies this assumption.
+
+The final ingredient for robust parametrization is motivated by a nice property of the natural parametrization $D(p;\theta) = \sum_{j=0}^{d}\theta_{j}p^{j}$ for polynomials. Consider any distinct $p_0, p_1, \ldots, p_d$ , and distinct real numbers $y_0, y_1, \ldots, y_d$ representing, for example, the mean reward at each $p_i$ . We can then uniquely determine a degree- $d$ polynomial by solving the linear equation $V_{\mathbf{p}}\theta = \mathbf{y}$ where
+
+$\theta = (\theta_0, \theta_1, \dots, \theta_d)^T$ , $\mathbf{y} = (y_0, y_1, \dots, y_d)^T$ and $V_{\mathbf{p}} := V(p_0, \dots, p_d)$ is the Vandermonde matrix. One can easily verify that $V_{\mathbf{p}}$ is invertible if and only if $p_i$ 's are distinct, in which case we have $\theta = V_{\mathbf{p}}^{-1}\mathbf{y}$ . Next we consider the effect of a perturbation on $\mathbf{y}$ , in terms of the following separability parameter.
+
+Definition 7 (Separability). For any $\mathbf{p} = (p_0,\dots,p_d)\in \mathbb{R}^{d + 1}$ , define $h(\mathbf{p})\coloneqq \min_{i\neq j}|p_i - p_j|$
+
+To motivate the general definition of robustness, first consider a result specific to polynomials. Recall that $\mathcal{R}_{\mathbf{p}}$ is range of the profile mapping $\Phi_{\mathbf{p}}$ .
+
+Proposition 1 (The Natural Parametrization for Polynomials is Robust). There exist constants $C_1, C_2 > 0$ such that for any $\mathbf{p} \in [0,1]^{d+1}$ with $0 < h(\mathbf{p}) \leq C_1$ , and $\mathbf{y}, \hat{\mathbf{y}} \in \mathcal{R}_{\mathbf{p}}$ with $\| \mathbf{y} - \hat{\mathbf{y}} \|_{\infty} \leq C_1$ , it holds that $\| V_{\mathbf{p}}^{-1}\mathbf{y} - V_{\mathbf{p}}^{-1}\hat{\mathbf{y}} \|_{\infty} \leq C_2 \cdot \| \mathbf{y} - \hat{\mathbf{y}} \|_{\infty} \cdot h(\mathbf{p})^{-d}$ .
+
+More concretely, let $D(p; \theta)$ be the underlying polynomial demand function, then $\mathbf{y} = V_{\mathbf{p}}\theta$ are the mean demands at the prices in $\mathbf{p}$ . Suppose we observe empirical mean demands $\hat{\mathbf{y}} = (\hat{y}_0, \hat{y}_1, \dots, \hat{y}_d)$ at prices $\mathbf{p}$ , then we have a reasonable estimation $\hat{\theta} = V_{\mathbf{p}}^{-1}\hat{\mathbf{y}}$ . Our Proposition 1 can then be viewed as an upper bound on the estimation error $\| \theta - \hat{\theta} \|_{\infty}$ in terms of $h(\mathbf{p})$ and $\mathbf{y} - \hat{\mathbf{y}}$ .
+
+In order to achieve sublinear regret, we need to ensure $h(\mathbf{p}) = o(1)$ as $T \to \infty$ . Moreover, the rate of this convergence crucially affects our regret bounds. Proposition 1 establishes a nice property for polynomials, that the estimation error scales as $h^{-d}$ , as $h \to 0^{+}$ . We introduce robust parametrization by generalizing this property beyond polynomials. Loosely, an order- $d$ parametrization is robust, if the bound in Proposition 1 holds.
+
+Definition 8 (Robust Parametrization). An order- $d$ parametrization $\theta : \Theta \to \mathcal{F}$ is robust, if (1) it satisfies Assumptions 3, 4 and 5, and
+
+(2) there exist constants $C_1, C_2 > 0$ such that for any $\mathbf{p} \in \mathbb{R}^{d+1}$ with $0 < h(\mathbf{p}) \leq C_1$ and any $y, y' \in \mathcal{R}_{\mathbf{p}}$ with $\| \mathbf{y} - \mathbf{y}' \|_{\infty} \leq C_1$ , it holds that $\| \Phi_{\mathbf{p}}^{-1}(\mathbf{y}) - \Phi_{\mathbf{p}}^{-1}(\mathbf{y}') \|_{\infty} \leq C_2 \cdot \| \mathbf{y} - \mathbf{y}' \|_{\infty} \cdot h(\mathbf{p})^{-d}$ . In particular, when $d = 0$ , this inequality simply says $\Phi_{\mathbf{p}}^{-1}$ is $C_2$ -Lipschitz.
+
+# 2.4 Markdown Dimension
+
+Now we are ready to define the markdown dimension.
+
+Definition 9 (Markdown Dimension). The markdown dimension (or simply dimension) for a family $\mathcal{F}$ of functions, denoted $d(\mathcal{F})$ , is the minimum integer $d \geq 0$ such that $\mathcal{F}$ is (i) $d$ -identifiable, and (ii) admits a robust order- $d$ parametrization. If no finite $d$ satisfies the above conditions, then $d(\mathcal{F}) = \infty$ .
+
+We further illustrate our definition by considering the dimensions of some basic families. As the simplest family, one may verify that our definition of 0-dimensional family is equivalent to the separable family as defined in Section 4 of [2]. We provide more concrete examples below. Details can found in Appendix A.
+
+Proposition 2. Let $D(x; \theta) = \sum_{j=0}^{d} \theta_j x^j$ and suppose $\mathcal{F} = \{D(x; \theta) : \theta \in \Theta\}$ satisfies Assumptions 3, 4 and 5. Then, $d(\mathcal{F}) = d$ .
+
+Proposition 3 (0-Dimensional Families). The following families $\mathcal{F}_1, \mathcal{F}_2$ and $\mathcal{F}_3$ are 0-dimensional. (1) [Single-Parameter Linear Demand] Let $D_a(x) = 1 - ax$ for $x \in [\frac{1}{2}, 1]$ and $\mathcal{F}_1 = \{D_a(x) : a \in [\frac{1}{2}, 1]\}$ .
+
+(2) [Exponential Demand] Let $D_{a}(x) = e^{1 - ax}$ for $x \in [\frac{1}{2}, 1]$ and $\mathcal{F}_2 = \left\{D_a(x): a \in [\frac{1}{2}, \frac{3}{4}]\right\}$ .
+
+(3) [Logit Demand] Let $D_{a}(x) = \frac{e^{1 - ax}}{1 + e^{1 - ax}}$ for $x \in [\frac{1}{2}, 1]$ and $\mathcal{F}_3 = \{D_a(x): a \in [\frac{1}{2}, 1]\}$ .
+
+Finally, we observe that by our definition, if a family of functions is not $d$ -identifiable for any $d$ , then $d(\mathcal{F}) = \infty$ . For example, for any $d$ distinct prices, there exist multiple (more precisely, infinitely many) Lipschitz functions having the same values on these $d$ prices.
+
+Proposition 4. Let $\mathcal{F}$ be the set of 1-Lipschitz functions from $[0,1]$ to $[0,1]$ , then $d(\mathcal{F}) = \infty$ .
+
+# 2.5 Sensitivity
+
+Consider the Taylor expansion of a reward function $R(x)$ around an optimal price $p^*$ : $R(p) = R(p^*) + 0 + \frac{1}{2!} R''(p^*)(p - p^*)^2 + \frac{1}{3!} R^{(3)}(p^*)(p - p^*)^3 + \ldots$ . Suppose the first nonzero derivative
+
+is $R^{(k)}(p^*)$ . Then, the higher $k$ , the less sensitive the revenue is to the estimation error in $p^*$ . We capture this aspect in the following notion of sensitivity.
+
+Definition 10 (Sensitivity). A reward function $R$ is $s$ -sensitive if it is $(s + 1)$ -times continuously differentiable with $R^{(1)}(p^*(R)) = \dots = R^{(s - 1)}(p^*(R)) = 0$ and $R^{(s)}(p^*(R)) < 0$ . A family $\mathcal{F}$ of reward functions is called $s$ -sensitive if
+
+(a) every $R\in \mathcal{F}$ is $s$ -sensitive,
+(b) it admits a parametrization $R(x; \theta)$ satisfying Assumptions 3 to 5,
+(c) there is a constant $C_6 > 0$ such that $R^{(s)}(p^* (R))\leq -C_6 < 0$ for any $R\in \mathcal{F}$ , and
+(d) for each $0 \leq j \leq s$ , there exists a constant $C^{(j)}$ s.t. $|R^{(j)}(x; \theta)| \leq C^{(j)}, \forall x \in [0,1], \theta \in \Theta$ .
+
+For example, let $s \geq 3$ and $R(x; \theta) = \theta - |\frac{1}{2} - x|^s$ for $x \in [0,1]$ and any $\theta \in \mathbb{R}$ , then $\{R(x; \theta) : \theta \in [\frac{1}{2}, 1]\}$ is an $s$ -sensitive family. Note that by Taylor's Theorem, $|R(p^* + \varepsilon) - R(p^*)| \leq O(\varepsilon^s)$ . Consequently, if a policy errs by $\varepsilon$ in the optimal price, the regret per round is $O(\varepsilon^s)$ , lower than the per-round regret $O(\varepsilon^2)$ in the basic case. In each of the next three sections, we will first present the regret bounds for the basic case $s = 2$ , and then characterize how this bound improves as $s$ increases.
+
+# 3 Zero-Dimensional Family
+
+We start with the simplest case, 0-dimensional demand functions. As opposed to the optimism in the face of uncertainty in UCB policies, our Cautious Myopic policy (Algorithm 1) adopts conservatism in the face of uncertainty. More precisely, we partition the time horizon into phases where phase $j$ consists of $t_j = \lceil 9^j\log T\rceil$ rounds, and thus in total there are $K = O(\log T - \log \log T)$ phases. In each phase, the policy builds a confidence interval $I_{j}$ for the true parameter using the samples collected in this phase, and sets the price for phase $j + 1$ to be the largest optimal price of any "surviving" parameter $\theta \in I_j$ . We write $t^{(j)}\coloneqq \sum_{k = 0}^{j}t_{k}$ and for convenience $t^{(0)} = 0$ .
+
+Algorithm 1 Cautious Myopic (CM) Policy.
+1: Input: a family $\mathcal{F}$ of demand functions and time horizon $T$ .
+2: $p_1 \gets 1$
+% Initialization
+3: for $j = 1, \dots, K$ do
+4: for $t = t^{(j-1)} + 1, \dots, t^{(j-1)} + t_j$ do
+5: $x_t \gets p_j$
+% Select $p_j$ for $t_j$ times in phase $j$
+6: Observe realized demand $D_t$
+end for
+ $\bar{d}_j = \frac{1}{t_j} \sum_{\tau=1}^{t_j} D_{t^{(j-1)}+\tau}$
+% Empirical mean demand in phase $j$ $\hat{\theta}_j \gets \Phi_{p_j}^{-1}(\bar{d}_j)$
+% Estimate parameter
+ $w_j \gets 4C_2 \cdot C_{sg} \sqrt{\frac{\log T}{t_j}}$
+% Width of the confidence interval
+ $\tilde{p}_{j+1} \gets \max \left\{ p^*(\theta) : |\theta - \hat{\theta}_j| \leq w_j \right\}$
+% Conservative estimation of the optimal price
+ $p_{j+1} \gets \min \left\{ \tilde{p}_{j+1}, p_j \right\}$
+% Ensure monotonicity
+end for
+
+Theorem 1 (Zero-Dimensional Upper Bound). Let $\mathcal{F}$ be any 0-dimensional, $s$ -sensitive family of demand functions. Then the Cautious Myopic (CM) Policy has regret
+
+$$
+\operatorname {R e g} (\operatorname {C M}, \mathcal {F}) = \left\{ \begin{array}{l l} O (\log^ {2} T), & \quad \text {i f} s = 2, \\ O (\log T), & \quad \text {i f} s > 2. \end{array} \right.
+$$
+
+Remark 1. It is worth noting that this bound is asymptotically higher than the $O(\log T)$ upper bound for unconstrained pricing ([2]). Intuitively, this is because the CM policy purposely makes conservative choices of prices to avoid overshooting.
+
+But can we achieve $o(\log^2 T)$ regret by behaving less conservatively? We answer this question negatively, and provide a separation between markdown and unconstrained pricing for dimension 0.
+
+Theorem 2 (Zero-Dimensional Lower Bound). There exists a 0-dimensional 2-sensitive family $\mathcal{F}$ such that for any policy $\pi$ , we have $\operatorname{Reg}(\pi, \mathcal{F}) = \Omega (\log^2 T)$ .
+
+# 4 Finite-Dimensional Family
+
+For dimension $d$ , the learner needs $d + 1$ distinct sample prices, as opposed to just one price when $d = 0$ . This, however, incurs extra regret, since the optimal price may lie between these sample prices. A policy faces the following trade off. If the gap is large, the policy may learn the parameter efficiently, but there is potentially a higher regret due to overshooting, if the true optimal price lies between the sample prices. On the other extreme, if the gap is small, there is less risk of overshooting but a slower rate of learning.
+
+We introduce our Iterative Cautious Myopic (ICM) Policy (Algorithm 2) that hits the sweet spot. The policy consists of $m$ phases. In phase $j \in [m]$ , it selects $p_j, p_j - h, \dots, p_j - dh$ each for $T_j$ times. Based on the observed demands at these prices, the policy computes an estimated optimal price $\hat{p}_j$ and a confidence interval $[L_j, U_j]$ . To determine the initial price $p_{j+1}$ of the next phase, we consider the relationship between the confidence interval $[L_j, U_j]$ and $p_j - dh$ . There are three cases:
+
+1. Good Event. If $p_j - dh > U_j$ , then we get closer to the optimal price by setting $p_{j+1} = U_j$ .
+2. Dangerous Event. If $L_{j} \leq p_{j} - dh \leq U_{j}$ , i.e. the current price is already within the confidence interval, the policy needs to behave conservatively by setting $p_{j+1} = p_{j} - dh$ to prevent from overshooting further.
+3. Overshooting Event. If $L_{j} > p_{j} - dh$ , i.e., the current price has already "overshot", the policy exits the exploration phase and selects the current price in the remaining rounds.
+
+Algorithm 2 Iterative Cautious Myopic (ICM) Policy.
+1: Input: $\mathcal{F},m,\{T_j\}_{j\in [m]},T$
+2: $p_1\gets 1,L_0\gets 0,U_0\gets 1$ Initialization
+3: for $j = 1,2,\ldots m$ do
+4: for $k = 0,1,\dots,d$ do
+5: Select price $p_j - kh$ for $T_{j}$ times and observe $D_{1},\dots,D_{T_{j}}$
+6: $\bar{D}_k\leftarrow \frac{1}{T_j}\sum_{i = 1}^{T_j}D_i$ % Mean demand at $p_j - kh$
+7: end for
+8: $\hat{\theta}\gets \Phi_{p_j,\dots,p_j - dh}^{-1}\left(\bar{D}_0,\dots,\bar{D}_d\right)$ % Estimate the parameter
+9: $w_{j}\gets 2h^{-d}\cdot C_{2}\cdot C_{sg}\sqrt{\frac{d\log T}{T_{j}}}$ % Width of confidence interval
+10: $L_{j}\gets \min \left\{p^{*}(\theta):\left\| \theta -p^{*}(\hat{\theta})\right\|_{2}\leq w_{j}\right\}$ % Lower confidence bound
+11: $U_{j}\gets \max \left\{p^{*}(\theta):\left\| \theta -p^{*}(\hat{\theta})\right\|_{2}\leq w_{j}\right\}$ % Upper confidence bound
+12: if $U_{j} > p_{j} - dh$ then
+13: $p_{j + 1}\gets U_j$ % Good event
+14: end if
+15: if $U_{j}\geq p_{j} - dh\geq L_{j}$ then
+16: $p_{j + 1}\gets p_j - dh$ % Dangerous event
+17: end if
+18: if $p_j - dh < L_j$ then
+19: Break % Overshooting event
+20: end if
+21: end for
+22: Select the current price in every future round % Exploitation
+
+Theorem 3 (Upper Bound for Finite $d \geq 1$ ). Suppose $s = 2$ , then for $h = T^{\frac{m}{m(d + 1) + 1}}$ , $T_{j} = T^{\frac{md + j}{m(d + 1) + 1}}$ and $m = \log T$ , we have $\operatorname{Reg}(\operatorname{ICM},\mathcal{F}) = \tilde{O}\left(T^{\frac{d}{d + 1}}\right)$ . More generally, for any $s \geq 2$ and $m = \tilde{O}(1)$ , there exist $T_{1} < \ldots < T_{m}$ such that $\operatorname{Reg}(\operatorname{ICM},\mathcal{F}) = \tilde{O}\left(T^{\rho(m,s,d)}\right)$ where
+
+$$
+\rho (m, s, d) = \frac {1 + \left(1 + \frac {s}{2} + \ldots + \left(\frac {s}{2}\right) ^ {m - 1}\right) d}{\left(\frac {s}{2}\right) ^ {m} + \left(1 + \frac {s}{2} + \ldots + \left(\frac {s}{2}\right) ^ {m - 1}\right) \cdot (d + 1)}.
+$$
+
+We complement the upper bound with a nearly tight lower bound for $s = 2$ , as stated below.
+
+Theorem 4 (Lower Bound for Finite $d \geq 1$ ). For any $d \geq 2$ , there exists a $d$ -dimensional family $\mathcal{F}$ of demand functions such that for any markdown policy $\pi$ , we have $\operatorname{Reg}(\pi, \mathcal{F}) = \Omega(T^{\frac{d}{d+1}})$ .
+
+In our proof, for each $d \geq 1$ we construct a family of $(d + 1)$ -degree, decreasing polynomial functions - which is also $d$ -dimensional - on which any policy suffers regret $\Omega(T^{\frac{d}{d + 1}})$ .
+
+Remark 2. At first glance, when $d \geq 4$ this result seems to contradict the $T^{3/4}$ upper bound for unimodal, Lipschitz reward family ([3, 9]). This is not a contradiction because the unimodality assumption no longer holds. In fact, a degree- $d$ polynomial with $d \geq 4$ is in general not unimodal.
+
+Remark 3. An interesting case is $d = 1$ . In this case, the revenue function is unimodal, so the $T^{\frac{3}{4}}$ upper bound from [3, 9] applies, but Theorem 3 gives a stronger $T^{\frac{1}{2}}$ upper bound.
+
+We conclude the section by pointing out a limitation of our results. For each $d \geq 1$ , our regret bounds is tight in the exponent of $T$ , however, the constants in the big-O have different dependence on $d$ . In fact, the upper and lower bound become exponentially higher and lower in $d$ respectively as $d$ grows.
+
+# 5 Infinite Dimensional Family
+
+When $d = \infty$ , it is more convenient to work with the reward function $R(x) = x \cdot D(x)$ instead of the demand function. In contrast to unconstrained pricing, there is no markdown policy that achieves $o(T)$ regret on the family of Lipschitz reward functions ([3, 9]), since the reward function may have multiple local maxima. Nonetheless, [3] and [9] showed that if in addition we assume the reward function to be unimodal, then the optimal regret is $T^{3/4}$ . Specifically, the lower bound is established by considering reward functions that may change abruptly at $p^*$ . We next show that the regret bound can be improved if we instead assume the reward function changes smoothly. In spirit, our policy is similar to that of [3] and [9]: reduce the price at uniform speed and terminate when there is sufficient evidence for "overshooting", but we will achieve improved guarantee by choosing a different step size $\Delta$ that decreases in the smoothness $s$ .
+
+Algorithm 3 Uniform Elimination Policy $(\mathrm{UE}_{m,\Delta})$
+1: Input: $T, \Delta, m > 0$
+2: Initialize: $L_{\mathrm{max}} \gets 0, w \gets 2C_{sg}\sqrt{\frac{\log T}{m}}$
+3: for $j = 0, 1, 2, \dots, \lceil \Delta^{-1} \rceil$ do
+4: $x_j \gets 1 - j\Delta$
+5: Select price $x_j$ for the next $m$ rounds and observe rewards $Z_1^j, \dots, Z_m^j$
+6: $\bar{\mu}_j \gets \frac{1}{m}\sum_{i=1}^{m} Z_i^j$
+7: $[L_j, U_j] \gets [\bar{\mu}_j - w, \bar{\mu} + w]$
+8: if $L_j > L_{\mathrm{max}}$ then
+9: $L_{\mathrm{max}} \gets L_j$
+10: end if
+11: if $U_j < L_{\mathrm{max}}$ then
+12: $h \gets j$
+13: Break
+14: end if
+15: end for
+16: Select price $x_h$ in all remaining rounds.
+
+Theorem 5 (Upper Bound for Infinite-Dimensional Family). Let $\mathcal{F}_s^U$ be the family of unimodal, $s$ -sensitive reward functions. For any $s \geq 2$ , there exist $m, \Delta$ with $\mathrm{Reg}(\mathrm{UE}_{m,\Delta}, \mathcal{F}_s^U) = O(T^{\frac{2s + 1}{3s + 1}})$ .
+
+We complement the above upper bound with a matching lower bound for every $s \geq 2$ .
+
+Theorem 6 (Lower Bound for $s$ -Sensitive Family). For any $s \geq 2$ , there is a family $\mathcal{F}$ of $s$ -sensitive unimodal revenue functions such that any markdown policy $\pi$ satisfies $\operatorname{Reg}(\pi, \mathcal{F}) = \Omega(T^{\frac{2s+1}{3s+1}})$ .
+
+Remark 4. As a final remark, we point out that all our results assume $d$ is given. If instead the learner only has known an upper bound $d_{\mathrm{max}}$ on $d$ , then she can simply choose the policy for $d_{\mathrm{max}}$ . We leave it open whether a best-of-all-worlds algorithm exists.
+
+# References
+
+[1] R. Agrawal. The continuum-armed bandit problem. SIAM journal on control and optimization, 33(6):1926-1951, 1995.
+[2] J. Broder and P. Rusmevichientong. Dynamic pricing under a general parametric choice model. Operations Research, 60(4):965-980, 2012.
+[3] N. Chen. Multi-armed bandit requiring monotone arm sequences. Advances in Neural Information Processing Systems, 34, 2021.
+[4] W. C. Cheung, D. Simchi-Levi, and H. Wang. Dynamic pricing and demand learning with limited price experimentation. Operations Research, 65(6):1722-1731, 2017.
+[5] U. M. Dholakia. The risks of changing your prices too often. Harvard Business Review, 2015.
+[6] A. Garivier, P. Menard, L. Rossi, and P. Menard. Thresholding bandit for dose-ranging: The impact of monotonicity. arXiv preprint arXiv:1711.04454, 2017.
+[7] W. Gautschi. On the inverses of vandermonde and confluent vandermonde matrices. i, ii. Numer. Math, 4:117-123, 1962.
+[8] S. Gupta and V. Kamble. Individual fairness in hindsight. In Proceedings of the 2019 ACM Conference on Economics and Computation, pages 805-806, 2019.
+[9] S. Jia, A. Li, and R. Ravi. Markdown pricing under unknown demand. Available at SSRN 3861379, 2021.
+[10] R. Kleinberg and T. Leighton. The value of knowing a demand curve: Bounds on regret for online posted-price auctions. In 44th Annual IEEE Symposium on Foundations of Computer Science, 2003. Proceedings., pages 594-605. IEEE, 2003.
+[11] R. D. Kleinberg. Nearly tight bounds for the continuum-armed bandit problem. In Advances in Neural Information Processing Systems, pages 697–704, 2005.
+[12] T. L. Lai and H. Robbins. Asymptotically efficient adaptive allocation rules. Advances in applied mathematics, 6(1):4-22, 1985.
+[13] M. Luca and O. Reshef. The effect of price on firm reputation. Management Science, 2021.
+[14] G. Perakis and D. Singhvi. Dynamic pricing with unknown non-parametric demand and limited price changes. Available at SSRN 3336949, 2019.
+[15] J. Salem, S. Gupta, and V. Kamble. Taming wild price fluctuations: Monotone stochastic convex optimization with bandit feedback. arXiv preprint arXiv:2103.09287, 2021.
+[16] D. Simchi-Levi and Y. Xu. Phase transitions and cyclic phenomena in bandits with switching constraints. Advances in Neural Information Processing Systems, 32, 2019.
+[17] R. Vershynin. High-dimensional probability: An introduction with applications in data science, volume 47. Cambridge university press, 2018.
+[18] A. Wald and J. Wolfowitz. Optimum character of the sequential probability ratio test. The Annals of Mathematical Statistics, 19(3):326-339, 1948.
\ No newline at end of file
diff --git a/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/images.zip b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..a8f8ff278fce2585abcf4c6dfb85835fb59ca466
--- /dev/null
+++ b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6c14a5a4514f9238e2a8bcdcb73424dcc5b9b6e573c849e7527891fe40221cc7
+size 43714
diff --git a/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/layout.json b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..9f49f0dd8c562064c2df59c39a14577d625db8d6
--- /dev/null
+++ b/dynamicpricingwithmonotonicityconstraintunderunknownparametricdemandmodel/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:136bc810a0ae53f7180db90e0029ce88ac6c2837285d2bb753d5294f955e4c81
+size 645537
diff --git a/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/3de525dd-d849-4626-9619-7de53f2c8b04_content_list.json b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/3de525dd-d849-4626-9619-7de53f2c8b04_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..73e744847a472ee8944d8c5c1342dfcd3ce048b1
--- /dev/null
+++ b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/3de525dd-d849-4626-9619-7de53f2c8b04_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8c103c6f7b6c0257f7c6ea9e4b658b519cd6d05b054ea6b379b85343f104dbcd
+size 80905
diff --git a/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/3de525dd-d849-4626-9619-7de53f2c8b04_model.json b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/3de525dd-d849-4626-9619-7de53f2c8b04_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..d1b710d89f0e315c5a6cc3cc8844f6ef20f48256
--- /dev/null
+++ b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/3de525dd-d849-4626-9619-7de53f2c8b04_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:95e4edfd2f27fa036a6827cf73e40a05772c54fb8c5bc23f7e75ab4c1718dbf8
+size 96812
diff --git a/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/3de525dd-d849-4626-9619-7de53f2c8b04_origin.pdf b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/3de525dd-d849-4626-9619-7de53f2c8b04_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..066b20aa9fda1084ebc71db45ea6dd5850fb8c49
--- /dev/null
+++ b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/3de525dd-d849-4626-9619-7de53f2c8b04_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f3d1e15f35a8374fe1a58c50c8ed3937fb4a38cb37db8ecb4eb904f6adb25e6e
+size 2242799
diff --git a/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/full.md b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..1d2e1c1f616316be19dfb2d05b00304d2d26cf81
--- /dev/null
+++ b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/full.md
@@ -0,0 +1,328 @@
+# Dynamics of SGD with Stochastic Polyak Stepsizes: Truly Adaptive Variants and Convergence to Exact Solution
+
+Antonio Orvieto*
+
+Department of Computer Science, ETH Zürich
+
+Simon Lacoste-Julien†
+
+Mila and DIRO,
+
+Université de Montréal
+
+Nicolas Loizou
+
+AMS and MINDS,
+
+Johns Hopkins University
+
+# Abstract
+
+Recently Loizou et al. [22], proposed and analyzed stochastic gradient descent (SGD) with stochastic Polyak stepsize (SPS). The proposed SPS comes with strong convergence guarantees and competitive performance; however, it has two main drawbacks when it is used in non-over-parameterized regimes: (i) It requires a priori knowledge of the optimal mini-batch losses, which are not available when the interpolation condition is not satisfied (e.g., regularized objectives), and (ii) it guarantees convergence only to a neighborhood of the solution. In this work, we study the dynamics and the convergence properties of SGD equipped with new variants of the stochastic Polyak stepsize and provide solutions to both drawbacks of the original SPS. We first show that a simple modification of the original SPS that uses lower bounds instead of the optimal function values can directly solve issue (i). On the other hand, solving issue (ii) turns out to be more challenging and leads us to valuable insights into the method's behavior. We show that if interpolation is not satisfied, the correlation between SPS and stochastic gradients introduces a bias, which effectively distorts the expectation of the gradient signal near minimizers, leading to non-convergence - even if the stepsize is scaled down during training. To fix this issue, we propose DecSPS, a novel modification of SPS, which guarantees convergence to the exact minimizer - without a priori knowledge of the problem parameters. For strongly-convex optimization problems, DecSPS is the first stochastic adaptive optimization method that converges to the exact solution without restrictive assumptions like bounded iterates/gradients.
+
+# 1 Introduction
+
+We consider the stochastic optimization problem:
+
+$$
+\min _ {x \in \mathbb {R} ^ {d}} \left[ f (x) = \frac {1}{n} \sum_ {i = 1} ^ {n} f _ {i} (x) \right], \tag {1}
+$$
+
+where each $f_{i}$ is convex and lower bounded. We denote by $\mathcal{X}^*$ the non-empty set of optimal points $x^{*}$ of equation (1). We set $f^{*} \coloneqq \min_{x\in \mathbb{R}^{d}}f(x)$ , and $f_{i}^{*} \coloneqq \inf_{x\in \mathbb{R}^{d}}f_{i}(x)$ .
+
+36th Conference on Neural Information Processing Systems (NeurIPS 2022).
+
+In this setting, the algorithm of choice is often Stochastic Gradient Descent (SGD), i.e. $x^{k + 1} = x^k - \gamma_k \nabla f_{\mathcal{S}_k}(x^k)$ , where $\gamma_k > 0$ is the stepsize at iteration $k$ , $\mathcal{S}_k \subseteq [n]$ a random subset of datapoints (minibatch) with cardinality $B$ sampled independently at each iteration $k$ , and $\nabla f_{\mathcal{S}_k}(x) := \frac{1}{B} \sum_{i \in \mathcal{S}_k} \nabla f_i(x)$ is the minibatch gradient.
+
+A careful choice of $\gamma_{k}$ is crucial for most applications [4, 14]. The simplest option is to pick $\gamma_{k}$ to be constant over training, with its value inversely proportional to the Lipschitz constant of the gradient. While this choice yields fast convergence to the neighborhood of a minimizer, two main problems arise: (a) the optimal $\gamma$ depends on (often unknown) problem parameters — hence often requires heavy tuning; and (b) it cannot be guaranteed that $\mathcal{X}^*$ is reached in the limit [13, 16, 15]. A simple fix for the last problem is to allow polynomially decreasing step sizes (second option) [23]: this choice for $\gamma_{k}$ often leads to convergence to $\mathcal{X}^*$ , but hurts the overall algorithm speed. The third option, which became very popular with the rise of deep learning, is to implement an adaptive stepsize. These methods do not commit to a fixed schedule, but instead use the optimization statistics (e.g. gradient history, cost history) to tune the value of $\gamma_{k}$ at each iteration. These step sizes are known to work very well in deep learning [35], and include Adam [19], Adagrad [11], and RMSprop [29].
+
+Ideally, a theoretically grounded adaptive method should yield fast convergence to $\mathcal{X}^*$ without knowledge of problem dependent parameters, such as the gradient Lipshitz constant or the strong convexity constant. As a result, an ideal adaptive method should require very little tuning by the user, while matching the performance of a fine-tuned $\gamma_{k}$ . However, while in practice this is the case for common adaptive methods such as Adam and AdaGrad, the associated convergence rates often rely on strong assumptions — e.g. that the iterates live on a bounded domain, or that gradients are uniformly bounded in norm [11, 32, 31]. While the above assumptions are valid in the constrained setting, they are problematic for problems defined in the whole $\mathbb{R}^d$ .
+
+A promising new direction in the adaptive step sizes literature is based on the idea of Polyak step sizes, introduced by [25] in the context of deterministic convex optimization. Recently [22] successfully adapted Polyak step sizes to the stochastic setting, and provided convergence rates matching fin-tuned SGD — while the algorithm does not require knowledge of the unknown quantities such as the gradient Lipschitz constant. The results especially shines in the overparameterized strongly convex setting, where linear convergence to $x^{*}$ is shown. This result is especially important since, under the same assumption, no such rate exists for AdaGrad (see e.g. [31] for the latest results) or other adaptive step sizes. Moreover, the method was shown to work surprisingly well on deep learning problems, without requiring heavy tuning [22].
+
+Even if the stochastic Polyak stepsize (SPS) [22] comes with strong convergence guarantees, it has two main drawbacks when it is used in non-over-parameterized regimes: (i) It requires a priori knowledge of the optimal mini-batch losses, which are not often available for big batch sizes or regularized objectives (see discussion in §1.1) and (ii) it guarantees convergence only to a neighborhood of the solution. In this work, we study the dynamics and the convergence properties of SGD equipped with new variants of SPS for solving general convex optimization problems. Our new proposed variants provide solutions to both drawbacks of the original SPS.
+
+# 1.1 Background and Technical Preliminaries
+
+The stepsize proposed by [22] is
+
+$$
+\gamma_ {k} = \min \left\{\frac {f _ {\mathcal {S} _ {k}} \left(x ^ {k}\right) - f _ {\mathcal {S} _ {k}} ^ {*}}{c \| \nabla f _ {\mathcal {S} _ {k}} \left(x ^ {k}\right) \| ^ {2}}, \gamma_ {b} \right\}, \quad \left(\mathrm {S P S} _ {\max } \right.
+$$
+
+where $\gamma_{b}, c > 0$ are problem-independent constants, $f_{\mathcal{S}_k} \coloneqq \frac{1}{|\mathcal{S}_k|} \sum_{i \in \mathcal{S}_k} f_i$ , $f_{\mathcal{S}_k}^* = \inf_{x \in \mathbb{R}^d} f_{\mathcal{S}_k}(x)$ .
+
+Dependency on $f_{\mathcal{S}_k}^*$ . Crucially the algorithm requires knowledge of $f_{\mathcal{S}_k}^*$ for every realization of the mini-batch $S_k$ . In the non-regularized overparametrized setting (e.g. neural networks), $f_{\mathcal{S}_k}$ is often zero for every subset $S$ [34]. However, this is not the only setting where $f_{\mathcal{S}}^*$ is computable: e.g., in the regularized logistic loss with batch size 1, it is possible to recover a cheap closed form
+
+expression for each $f_{i}^{*}$ [22]. Unfortunately, if the batch-size is bigger than 1 or the loss becomes more demanding (e.g. cross-entropy), then no such closed-form computation is possible.
+
+Rates and comparison with AdaGrad. In the convex overparametrized setting (more precisely, under the interpolation condition, i.e. $\exists x^{*}\in \mathcal{X}^{*}:\inf_{x\in \mathbb{R}^{d}}f_{S}(x) = f_{S}(x^{*})$ for all $S$ , see also §2), $\mathrm{SPS}_{\mathrm{max}}$ enjoys a convergence speed of $\mathcal{O}(1 / k)$ , without requiring knowledge of the gradient Lipschitz constant or other problem parameters. Recently, [31] showed that the same rate can be achieved for AdaGrad in the same setting. However, there is an important difference: the rate of [31] is technically $\mathcal{O}(dD^2 /k)$ , where $d$ is the problem dimension and $D^2$ is a global bound on the squared distance to the minimizer, which is assumed to be finite. Not only does $\mathrm{SPS}_{\mathrm{max}}$ not have this dimension dependency, which dates back to crucial arguments in the AdaGrad literature [11, 21], but also does not require bounded iterates. While this assumption is satisfied in the constrained setting, it has no reason to hold in the unconstrained scenario. Unfortunately, this is a common problem of all AdaGrad variants: with the exception of [33] (which works in a slightly different scenario), no rate can be provided in the stochastic setting without the bounded iterates/gradients [12] assumption — even after assuming strong convexity. However, in the non-interpolated setting, AdaGrad enjoys a convergence guarantee of $\mathcal{O}(1 / \sqrt{k})$ (with the bounded iterates assumption). A similar rate does not yet exist for SPS, and our work aims at filling this gap.
+
+# 1.2 Main Contributions
+
+As we already mentioned, in the non-interpolated setting $\mathrm{SPS}_{\mathrm{max}}$ has the following issues:
+
+Issue (1): For $B > 1$ (minibatch setting), $\mathrm{SPS}_{\max}$ requires the exact knowledge of $f_{\mathcal{S}}^{*}$ . This is not practical.
+
+Issue (2): $\mathrm{SPS}_{\mathrm{max}}$ guarantees convergence to a neighborhood of the solution. It is not clear how to modify it to yield convergence to the exact minimizer.
+
+Having the above two issues in mind, the main contributions of our work (see also Table 1 for a summary of the main complexity results obtained in this paper) are summarized as follows:
+
+- In §3, we provide a direct solution for Issue (1). We explain how only a lower bound on $f_{S}^{*}$ (trivial if all $f_{i}$ s are non-negative) is required for convergence to a neighborhood of the solution. While this neighborhood is bigger that the one for $\mathrm{SPS}_{\max}$ , our modified version provides a practical baseline for the solution to the second issue.
+- We explain why Issue (2) is highly non-trivial and requires an in-depth study of the bias induced by the interaction between gradients and Polyak stepsizes. Namely, we show that simply multiplying the stepsize of $\mathrm{SPS}_{\mathrm{max}}$ by $1 / \sqrt{k}$ — which would work for vanilla SGD [23] — yields a bias in the solution found by SPS ( $\S 4$ ), regardless of the estimation of $f_{\mathcal{S}}^{*}$ .
+- In §5, we provide a solution to the problem (Issue (2)) by introducing additional structure — as well as the fix to Issue (1) — into the stepsize. We call the new algorithm Decreasing SPS (DecSPS), and provide a convergence guarantee under the bounded domain assumption — matching the standard AdaGrad results.
+- In §5.2 we go one step further and show that, if strong convexity is assumed, iterates are bounded with probability 1 and hence we can remove the bounded iterates assumption. To the best of our knowledge, DecSPS, is the first stochastic adaptive optimization method that converges to the exact solution without assuming strong assumptions like bounded iterates/gradients.
+- In §5.3 we provide extensions of our approach to the non-smooth setting.
+- In §6, we corroborate our theoretical results with experimental testing.
+
+# 2 Background on Stochastic Polyak Stepsize
+
+In this section, we provide a concise overview of the results in [22], and highlight the main assumptions and open questions.
+
+To start, we remind the reader that problem (1) is said to be interpolated if there exists a problem solution $x^{*} \in \mathcal{X}^{*}$ such that $\inf_{x \in \mathbb{R}^d} f_i(x) = f_i(x^{*})$ for all $i \in [n]$ . The degree of interpolation
+
+| Stepsize | Citation | Assumptions | No Knowledge of \( f_{\mathcal{S}}^{*} \) | Exact Convergence | Theorem |
| \( \mathrm {SPS}_{\max } \) | [22] | convex, smooth | ✘ | ✘ | Thm. 1 |
| \( \mathrm {SPS}_{\max }^{\ell } \) | This paper | convex, smooth | ✓ | ✘ | Thm. 2, Cor. 1 |
| DecSPS | This paper | convex, smooth, bounded iterates | ✓ | ✓ | Cor. 2, \( \mathcal{O}(1/\sqrt{K}) \) |
| This paper | strongly-convex, smooth | ✓ | ✓ | Thm. 4, \( \mathcal{O}(1/\sqrt{K}) \) |
| DecSPS-NS | This paper | convex, bounded iterates/grads | ✓ | ✓ | Cor. 3, \( \mathcal{O}(1/\sqrt{K}) \) |
+
+Table 1: Summary of the considered step sizes and the corresponding theoretical results in the non-interpolated setting. The studied quantity in all Theorems, with respect to which all rates are expressed is $\mathbb{E}\left[f(\bar{x}^K) - f(x^*)\right]$ , where $\bar{x}^K = \frac{1}{K}\sum_{k=0}^{K-1}x^k$ . In addition, for all converging methods, we consider the stepsize scaling factor $c_k = \mathcal{O}(\sqrt{k})$ , formally defined in the corresponding sections. For the methods without exact convergence, we show in §4 that any different scaling factor cannot make the algorithm convergent.
+
+at batch size $B$ can be quantified by the following quantity, introduced by [22] and studied also in [31, 9]: fix a batch size $B$ , and let $S \subseteq [n]$ with $|\mathcal{S}| = B$ .
+
+$$
+\sigma_ {B} ^ {2} := \mathbb {E} _ {\mathcal {S}} \left[ f _ {\mathcal {S}} \left(x ^ {*}\right) - f _ {\mathcal {S}} ^ {*} \right] = f \left(x ^ {*}\right) - \mathbb {E} _ {\mathcal {S}} \left[ f _ {\mathcal {S}} ^ {*} \right] \tag {2}
+$$
+
+It is easy to realize that as soon as problem (1) is interpolated, then $\sigma_B^2 = 0$ for each $B\leq n$ . In addition, note that $\sigma_B^2$ is non-increasing as a function of $B$ .
+
+We now comment on the main result from [22].
+
+Theorem 1 (Main result of [22]). Let each $f_{i}$ be $L_{i}$ -smooth convex functions. Then $SGD$ with $SPS_{\mathrm{max}}$ , mini-batch size $B$ , and $c = 1$ , converges as: $\mathbb{E}\left[f(\bar{x}^{K}) - f(x^{*})\right] \leq \frac{\|x^{0} - x^{*}\|^{2}}{\alpha K} + \frac{2\gamma_{b}\sigma_{B}^{2}}{\alpha}$ , where $\alpha = \min \left\{\frac{1}{2cL_{\mathrm{max}}}, \gamma_{b}\right\}$ and $\bar{x}^{K} = \frac{1}{K}\sum_{k=0}^{K-1}x^{k}$ . If in addition $f$ is $\mu$ -strongly convex, then, for any $c \geq 1/2$ , $SGD$ with $SPS_{\mathrm{max}}$ converges as: $\mathbb{E}\|x^{k} - x^{*}\|^{2} \leq (1 - \mu\alpha)^{k}\|x^{0} - x^{*}\|^{2} + \frac{2\gamma_{b}\sigma_{B}^{2}}{\mu\alpha}$ , where again $\alpha = \min \left\{\frac{1}{2cL_{\mathrm{max}}}, \gamma_{b}\right\}$ and $L_{\mathrm{max}} = \max \{L_{i}\}_{i=1}^{n}$ is the maximum smoothness constant.
+
+In the overparametrized setting, the result guarantees convergence to the exact minimizer, without knowledge of the gradient Lipschitz constant (as vanilla SGD would instead require) and without assuming bounded iterates (in contrast to [31]).
+
+As soon as (1) a regularizer is applied to the loss (e.g. $L2$ penalty), or (2) the number of datapoints gets comparable to the dimension, then the problem is not interpolated and $\mathrm{SPS}_{\max}$ only converges to a neighborhood and it gets impractical to compute $f_{\mathcal{S}}^{*}$ — this is the setting we study in this paper. Remark 1 (What if $\| \nabla f_{\mathcal{S}_k} \| = 0$ )? In the rare case that $\| \nabla f_{S_k}(x^k) \|^2 = 0$ , there is no need to evaluate the stepsize. In this scenario, the update direction $\nabla f_{S_k}(x^k) = 0$ and thus the iterate is not updated irrespective of the choice of step-size. If this happens, the user should simply sample a different minibatch. We note that in our experiments (see §6), such event never occurred.
+
+Related work on Polyak stepsize: The classical Polyak stepsize [25] has been successfully used in the analysis of deterministic subgradient methods in different settings [5, 7, 18]. First attempts on providing an efficient variant of the stepsize that works well in the stochastic setting were made in [3, 24]. However, as explained in [22], none of these approaches provide a natural stochastic extension with strong theoretical convergence guarantees, and thus Loizou et al. [22] proposed the stochastic Polyak stepsize $\mathrm{SPS}_{\mathrm{max}}$ as a better alternative. Despite its recent appearance, $\mathrm{SPS}_{\mathrm{max}}$ has already been used and analyzed as a stepsize for SGD for solving structured non-convex problems [15], in combination with other adaptive methods [31], with a moving target [17] and in the update rule of stochastic mirror descent [9]. These extensions are orthogonal to our approach, and we
+
+
+Figure 1: We consider a 100 dim problem with $n = 100$ datapoints where each $f_{i} = \frac{1}{2}(x - x_{i}^{*})^{\top}H_{i}(x - x_{i}^{*}) + f_{i}^{*}$ , with $f_{i}^{*} = 1$ for all $i \in [n]$ and $H_{i}$ a random SPD matrix generated using the standard Gaussian matrix $A_{i} \in \mathbb{R}^{d \times 3d}$ as $H_{i} = A_{i}A_{i}^{\top} / (3d)$ . If $x_{i}^{*} \neq x_{j}^{*}$ for $i \neq j$ , then the problem does not satisfy interpolation (left plot). Instead, if all $x_{i}^{*}$ 's are equal, then the problem is interpolated (central plot). The plot shows the behaviour of $\mathrm{SPS}_{\max}^{\ell} (\gamma_{b} = 2)$ for different choices of the approximated suboptimality $\ell_{i}^{*}$ . We plot (mean and std deviation over 10 runs) the function suboptimality level $f(x) - f(x^{*})$ for different values of $\ell_{i}^{*}$ . Note that, if instead $f_{i}^{*} = 0$ for all $i$ then all the shown algorithms coincide (right plot) and converge to the solution.
+
+
+
+
+
+speculate that our proposed variants can also be used in the above settings. We leave such extensions for future work.
+
+# 3 Removing $f_{\mathcal{S}}^{*}$ from SPS
+
+As motivated in the last sections, computing $f_{\mathcal{S}}^{*}$ in the non-interpolated setting is not practical. In this section, we explore the effect of using a lower bound $\ell_{\mathcal{S}}^{*} \leq f_{\mathcal{S}}^{*}$ instead in the $\mathrm{SPS}_{\mathrm{max}}$ definition.
+
+$$
+\gamma_ {k} = \min \left\{\frac {f _ {\mathcal {S} _ {k}} (x ^ {k}) - \ell_ {\mathcal {S} _ {k}} ^ {*}}{c \| \nabla f _ {\mathcal {S} _ {k}} (x ^ {k}) \| ^ {2}}, \gamma_ {b} \right\}, \qquad (\mathrm {S P S} _ {\max } ^ {\ell})
+$$
+
+Such a lower bound is easy to get for many problems of interest: indeed, for standard regularized regression and classification tasks, the loss is non-negative hence one can pick $\ell_{\mathcal{S}}^{*} = 0$ , for any $\mathcal{S} \subseteq [n]$ .
+
+The obvious question is: what is the effect of estimating $\ell_{\mathcal{S}}^{*}$ on the convergence rates in Thm. 1? We found that the proof of [22] is easy to adapt to this case, by using the following fundamental bound (see also Lemma 3): $\frac{1}{2cL_{\mathcal{S}_k}} \leq \frac{f_{\mathcal{S}_k}(x^k) - f_{\mathcal{S}_k}^*}{c\|\nabla f_{\mathcal{S}_k}(x^k)\|^2} \leq \frac{f_{\mathcal{S}_k}(x^k) - \ell_{\mathcal{S}_k}^*}{c\|\nabla f_{\mathcal{S}_k}(x^k)\|^2}$ .
+
+The following results can be seen as an easy extension of the main result of [22], under a newly defined suboptimality measure:
+
+$$
+\hat {\sigma} _ {B} ^ {2} := \mathbb {E} _ {\mathcal {S} _ {k}} \left[ f _ {\mathcal {S} _ {k}} \left(x ^ {*}\right) - \ell_ {\mathcal {S} _ {k}} ^ {*} \right] = f \left(x ^ {*}\right) - \mathbb {E} _ {\mathcal {S} _ {k}} \left[ \ell_ {\mathcal {S} _ {k}} ^ {*} \right]. \tag {3}
+$$
+
+Theorem 2. Under $SPS_{\mathrm{max}}^{\ell}$ , the same exact rates in Thm. 1 hold (under the corresponding assumptions), after replacing $\sigma_B^2$ with $\hat{\sigma}_B^2$ .
+
+And we also have an easy practical corollary.
+
+Corollary 1. In the context of Thm. 2, assume all $f_{i}$ s are non-negative and estimate $\ell_S^* = 0$ for all $S \subseteq [n]$ . Then the same exact rates in Thm. 1 hold for $SPS_{\mathrm{max}}^{\ell}$ , after replacing $\sigma_B^2$ with $f^{*} = f(x^{*})$ .
+
+A numerical illustration of this result can be found in Fig. 1. In essence, both theory and experiments confirm that, if interpolation is not satisfied, then we have a linear rate until a convergence ball, where the size is optimal under exact knowledge of $f_{S}^{*}$ . Instead, under interpolation, if all the $f_{i}$ s are non-negative and $f^{*} = 0$ , then $\mathrm{SPS}_{\max} = \mathrm{SPS}_{\max}^{\ell}$ . Finally, in the less common case in practice where $f^{*} > 0$ but we still have interpolation, then $\mathrm{SPS}_{\max}$ converges to the exact solution while $\mathrm{SPS}_{\max}^{\ell}$ does not. To conclude $\mathrm{SPS}_{\max}^{\ell}$ does not (of course) work better than $\mathrm{SPS}_{\max}$ , but it is a practical variant which we can use as a baseline in §5 for an adaptive stochastic Polyak stepsize with convergence to the true $x^{*}$ in the non-interpolated setting.
+
+# 4 Bias in the SPS dynamics.
+
+In this section, we study convergence of the standard $\mathrm{SPS}_{\mathrm{max}}$ in the non-interpolated regime, under an additional (decreasing) multiplicative factor, in the most ideal setting: batch size 1, and we have knowledge of each $f_{i}^{*}$ . That is, we consider $\gamma_{k} = \min \left\{\frac{f_{i_{k}}(x^{k}) - f_{i_{k}}^{*}}{c_{k}\|\nabla f_{i_{k}}(x^{k})\|^{2}},\gamma_{b}\right\}$ with $c_{k}\to \infty$ , e.g. $c_{k} = \mathcal{O}(\sqrt{k})$ or $c_{k} = \mathcal{O}(k)$ . We note that, in the SGD case, simply picking e.g. $\gamma_{k} = \gamma_{0} / \sqrt{k + 1}$ would guarantee convergence of $f(x^{k})$ to $f(x^{*})$ , in expectation and with high probability [20, 23]. Therefore, it is natural to expect a similar behavior for SPS, if $1 / c_{k}$ satisfies the usual Robbins-Monro conditions [27]: $\sum_{k = 0}^{\infty}1 / c_k = \infty ,\sum_{k = 0}^{\infty}1 / c_k^2 < \infty$
+
+We show that this is not the case: quite interestingly, $f(x^{k})$ converges to a biased solution due to the correlation between $\nabla f_{i_k}$ and $\gamma_{k}$ . We show this formally, in the case of non-interpolation (otherwise both SGD and SPS do not require a decreasing learning rate).
+
+Counterexample. Consider the following finite-sum setting: $f(x) = \frac{1}{2} f_1(x) + \frac{1}{2} f_2(x)$ with $f_1(x) = \frac{a_1}{2}(x - 1)^2$ , $f_2(x) = \frac{a_2}{2}(x + 1)^2$ . To make the problem interesting, we choose $a_1 = 2$ and $a_2 = 1$ : this introduces asymmetry in the average landscape with respect to the origin. During optimization, we sample $f_1$ and $f_2$ independently and seek convergence to the unique minimizer $x^* = \frac{a_1 - a_2}{a_1 + a_2} = 1/3$ . The first thing we notice is that $x^*$ is not a stationary point for the dynamics under SPS. Indeed note that since $f_i^* = 0$ for $i = 1, 2$ we have (assuming $\gamma_b$ large enough): $\gamma_k \nabla f_{i_k}(x) = \frac{x - 1}{2c_k}$ , if $i_k = 1$ , and $\gamma_k \nabla f_{i_k}(x) = \frac{x + 1}{2c_k}$ if $i_k = 2$ .
+
+Crucially, note that this update is curvature-independent. The expected update is $\mathbb{E}_{i_k}[\gamma_k\nabla f_{i_k}(x)] = \frac{x - 1}{4c_k} +\frac{x + 1}{4c_k} = \frac{1}{2c_k} x$ . Hence, the iterates can only converge to $x = 0$ — because this is the only fixed point for the update rule. The proof naturally extends to the multidimensional setting, an illustration can be found in Fig. 2. No internalization. Internalization
+
+In the same picture, we show how our modified variant of the vanilla stepsize — we call this new algorithm DecSPS, see §5 — instead converges to the correct solution.
+
+Remark 2. SGD with (non-adaptive) stepsize $\gamma_{k}$ instead keeps the curvature, and therefore is able to correctly estimate the average $\mathbb{E}_{i_k}[\gamma_k\nabla f_{i_k}(x)] = \frac{\gamma_k}{2} (a_1 + a_2)\left[x - \frac{a_1 - a_2}{a_1 + a_2}\right]$ precisely because $\gamma_{k}$ is independent from $\nabla f_{i_k}$ . From this we can see that SGD can only converge to the correct stationary point $x^{*} = \frac{a_{1} - a_{2}}{a_{1} + a_{2}}$ because again this is the only fixed point for the update rule.
+
+In the appendix, we go one step further and provide an analysis of the bias of SPS in the one-dimensional quadratic case (Prop. 4). Yet, we expect the precise characterization of the bias phenomenon in the non-quadratic setting to be particularly challenging. We provide additional insights in §D.2. Instead, in the next section, we show how to effectively modify $\gamma_{k}$ to yield convergence to $x^{*}$ without further assumptions.
+
+
+Figure 2: Dynamics of $\mathrm{SPS}_{\mathrm{max}}$ with decreasing multiplicative constant (SGD style) compared with DecSPS. We compared both in the interpolated setting (right) and in the non-interpolated setting (left). In the non-interpolated setting, a simple multiplicative factor introduces a bias in the final solution, as discussed in this section. We consider two dimensional $f_{i} = \frac{1}{2} (x - x_{i}^{*})^{\top}H_{i}(x - x_{i}^{*})$ , for $i = 1,2$ and plot the contour lines of the corresponding landscapes, as well as the average landscape $(f_{1} + f_{2}) / 2$ we seek to minimize. Solution is denoted with a gold star.
+
+# 5 DecSPS: Convergence to the exact solution
+
+We propose the following modification of the vanilla SPS proposed in [22], designed to yield convergence to the exact minimizer while keeping the main adaptiveness properties4. We call it Decreasing SPS (DecSPS), since it combines a steady stepsize decrease with the adaptiveness of SPS.
+
+$$
+\gamma_ {k} := \frac {1}{c _ {k}} \min \left\{\frac {f _ {\mathcal {S} _ {k}} \left(x ^ {k}\right) - \ell_ {\mathcal {S} _ {k}} ^ {*}}{\| \nabla f _ {\mathcal {S} _ {k}} \left(x ^ {k}\right) \| ^ {2}}, c _ {k - 1} \gamma_ {k - 1} \right\}, \tag {DecSPS}
+$$
+
+for $k \in \mathbb{N}$ , where $c_k \neq 0$ for every $k \in \mathbb{N}$ . We set $c_{-1} = c_0$ and $\gamma_{-1} = \gamma_{b} > 0$ (stepsize bound, similar to [22]), to get $\gamma_0 := \frac{1}{c_0} \cdot \min \left\{ \frac{f_{\mathcal{S}_0}(x^0) - \ell_{\mathcal{S}_0}^*}{\|\nabla f_{\mathcal{S}_0}(x^k)\|^2}, c_0 \gamma_b \right\}$ .
+
+Lemma 1. Let each $f_{i}$ be $L_{i}$ smooth and let $(c_k)_{k=0}^{\infty}$ be any non-decreasing positive sequence of real numbers. Under DecSPS, we have $\min \left\{ \frac{1}{2c_kL_{\max}}, \frac{c_0\gamma_b}{c_k} \right\} \leq \gamma_k \leq \frac{c_0\gamma_b}{c_k}$ , and $\gamma_{k-1} \leq \gamma_k$ .
+
+Remark 3. As stated in the last lemma, under the assumption of $c_k$ non-decreasing, $\gamma_k$ is trivially non-increasing since $\gamma_k \leq c_{k-1} \gamma_{k-1} / c_k$ .
+
+The proof can be found in the appendix, and is based on a simple induction argument.
+
+# 5.1 Convergence under bounded iterates
+
+The following result provides a proof of convergence of SGD for the $\gamma_{k}$ sequence defined above.
+
+Theorem 3. Consider SGD with DecSPS and let $(c_k)_{k=0}^{\infty}$ be any non-decreasing sequence such that $c_k \geq 1, \forall k \in \mathbb{N}$ . Assume that each $f_i$ is convex and $L_i$ smooth. We have:
+
+$$
+\mathbb {E} \left[ f \left(\bar {x} ^ {K}\right) - f \left(x ^ {*}\right) \right] \leq \frac {2 c _ {K - 1} \tilde {L} D ^ {2}}{K} + \frac {1}{K} \sum_ {k = 0} ^ {K - 1} \frac {\hat {\sigma} _ {B} ^ {2}}{c _ {k}}, \tag {4}
+$$
+
+where $D^2 \coloneqq \max_{k \in [K-1]} \| x^k - x^* \|^2$ , $\tilde{L} \coloneqq \max \left\{\max_i \{L_i\}, \frac{1}{2c_0 \gamma_b}\right\}$ and $\bar{x}^K = \frac{1}{K} \sum_{k=0}^{K-1} x^k$ .
+
+If $\hat{\sigma}_B^2 = 0$ , then $c_k = 1$ for all $k \in \mathbb{N}$ leads to a rate $\mathcal{O}(\frac{1}{K})$ , well known from [22]. If $\hat{\sigma}_B^2 > 0$ , as for the standard SGD analysis under decreasing step sizes, the choice $c_k = \mathcal{O}(\sqrt{k})$ leads to an optimal asymptotic trade-off between the deterministic and the stochastic terms, hence to the asymptotic rate $\mathcal{O}(1 / \sqrt{k})$ since $\sum_{k=0}^{K-1} \frac{1}{\sqrt{k+1}} \leq 2\sqrt{K}$ . Moreover, picking $c_0 = 1$ minimizes the speed of convergence for the deterministic factor. Under the assumption that $\hat{\sigma}_B^2 \ll \tilde{L}D^2$ (e.g. reasonable distance initialization-solution and $L_{\max} > 1 / \gamma_b$ ), this factor is dominant compared to the factor involving $\hat{\sigma}_B^2$ . For this setting, the rate simplifies as follows.
+
+Corollary 2. Under the setting of Thm. 3, for $c_k = \sqrt{k + 1}$ ( $c_{-1} = c_0$ ) we have
+
+$$
+\mathbb {E} \left[ f \left(\bar {x} ^ {K}\right) - f \left(x ^ {*}\right) \right] \leq \frac {2 \tilde {L} D ^ {2} + 2 \hat {\sigma} _ {B} ^ {2}}{\sqrt {K}}. \tag {5}
+$$
+
+Remark 4 (Beyond bounded iterates). The result above crucially relies on the bounded iterates assumption: $D^2 < \infty$ . To the best of our knowledge, if no further regularity is assumed, modern convergence results for adaptive methods (e.g. variants of AdaGrad) in convex stochastic programming require this assumption, or else require gradients to be globally bounded. To mention a few: [11, 26, 32, 8, 31]. A simple algorithmic fix to this problem is adding a cheap projection step onto a large bounded domain [21]. We can of course include this projection step in DecSPS, and the theorem above will hold with no further modification. Yet we found this to be not necessary: the strong guarantees of SPS in the strongly convex setting [22] let us go one step beyond: in §5.2 we show that, if each $f_i$ is strongly convex (e.g. regularizer is added), then one can bound the iterates globally with probability one, without knowledge of the gradient Lipschitz constant. To the best of our knowledge, no such result exist for AdaGrad — except [30], for the deterministic case.
+
+Remark 5 (Dependency on the problem dimension). In standard results for AdaGrad, a dependency on the problem dimension often appears (e.g. Thm. 1 in [31]). This dependency follows from a bound on the AdaGrad preconditioner that can be found e.g. in Thm. 4 in [21]. In the SPS case no such dependency appears — specifically because the stepsize is lower bounded by $1 / (2c_k L_{\max})$ .
+
+# 5.2 Removing the bounded iterates assumption
+
+We prove that under DecSPS the iterates live in a set of diameter $D_{\mathrm{max}}$ almost surely. This can be done by assuming strong convexity of each $f_{i}$ .
+
+The result uses this alternative definition of neighborhood: $\hat{\sigma}_{B,\max}^2 \coloneqq \max_{\mathcal{S} \subseteq [n], |\mathcal{S}| = B} [f_{\mathcal{S}}(x^*) - \ell_{\mathcal{S}}^*]$ . Note that trivially $\hat{\sigma}_{B,\max}^2 < \infty$ under the assumption that all $f_i$ are lower bounded and $n < \infty$ .
+
+Proposition 1. Let each $f_{i}$ be $\mu_{i}$ -strongly convex and $L_{i}$ -smooth. The iterates of SGD with DecSPS with $c_{k} = \sqrt{k + 1}$ (and $c_{-1} = c_{0}$ ) are such that $\| x^{k} - x^{*}\|^{2} \leq D_{\max}^{2}$ almost surely $\forall k \in \mathbb{N}$ , where $D_{\max}^{2} := \max \left\{\| x^{0} - x^{*}\|^{2}, \frac{2c_{0}\gamma_{b}\hat{\sigma}_{B,\max}^{2}}{\min\left\{\frac{\mu_{\min}}{2L_{\max}},\mu_{\min}\gamma_{b}\right\}}\right\}$ , with $\mu_{\min} = \min_{i \in [n]} \mu_{i}$ and $L_{\max} = \max_{i \in [n]} L_{i}$ .
+
+The proof relies on the variations of constants formula and an induction argument — it is provided in the appendix. We are now ready to state the main theorem for the unconstrained setting, which follows from Prop. 1 and Thm. 3.
+
+Theorem 4. Consider SGD with the DecSPS stepsize $\gamma_{k} := \frac{1}{\sqrt{k + 1}} \cdot \min \left\{\frac{f_{\mathcal{S}_{k}}(x^{k}) - f_{\mathcal{S}_{k}}^{*}}{\|\nabla f_{\mathcal{S}_{k}}(x^{k})\|^{2}}, \gamma_{k - 1}\sqrt{k}\right\}$ , for $k \geq 1$ and $\gamma_{0}$ defined as at the beginning of this section. Let each $f_{i}$ be $\mu_{i}$ -strongly convex and $L_{i}$ -smooth:
+
+$$
+\mathbb {E} \left[ f \left(\bar {x} ^ {K}\right) - f \left(x ^ {*}\right) \right] \leq \frac {2 \tilde {L} D _ {\max } ^ {2} + 2 \hat {\sigma} _ {B} ^ {2}}{\sqrt {K}}. \tag {6}
+$$
+
+Remark 6 (Strong Convexity). The careful reader might notice that, while we assumed strong convexity, our rate is slower than the optimal $\mathcal{O}(1 / K)$ . This is due to the adaptive nature of DecSPS. It is indeed notoriously hard to achieve a convergence rate of $\mathcal{O}(1 / K)$ for adaptive methods in the strongly convex regime. While further investigations will shed light on this interesting problem, we note that the result we provide is somewhat unique in the literature: we are not aware of any adaptive method that enjoys a similar convergence rate without either (a) assuming bounded iterates/gradients or (b) assuming knowledge of the gradient Lipschitz constant or the strong convexity constant.
+
+Remark 7 (Comparison with Vanilla SGD). On a convex problem, the non-asymptotic performance of SGD with a decreasing stepsize $\gamma_{k} = \eta /\sqrt{k}$ strongly depends on the choice of $\eta$ . The optimizer might diverge if $\eta$ is too big for the problem at hand. Indeed, most bounds for SGD, under no access to the gradient Lipschitz constant, display a dependency on the size of the domain and rely on projections after each step. If one applies the method in the unconstrained setting, such convergence rates technically do not hold, and tuning is sometimes necessary to retrieve stability and good performance. Instead, for DecSPS, simply by adding a small regularizer, the method is guaranteed to converge at the non-asymptotic rate we derived even in the unconstrained setting.
+
+# 5.3 Extension to the non-smooth setting
+
+For any $S \subseteq [n]$ , we denote in this section by $g_S(x)$ the subgradient of $f_S$ evaluated at $x$ . We discuss the extension of DecSPS to the non-smooth setting.
+
+A straightforward application of DecSPS leads to a stepsize $\gamma_{k}$ which is no longer lower bounded (see Lemma 1) by the positive quantity $\min \left\{\frac{1}{2c_kL_{\max}},\frac{c_0\gamma_b}{c_k}\right\}$ . Indeed, the gradient Lipschitz constant in the non-smooth case is formally $L_{\mathrm{max}} = \infty$ . Hence, $\gamma_{k}$ prescribed by DecSPS can get arbitrarily small for finite $k$ . One easy solution to the problem is to enforce a lower bound, and adopt a new proof technique. Specifically we propose the following:
+
+$$
+\gamma_ {k} := \frac {1}{c _ {k}} \cdot \min \left\{\max \left\{c _ {0} \gamma_ {\ell}, \frac {f _ {\mathcal {S} _ {k}} \left(x ^ {k}\right) - \ell_ {\mathcal {S} _ {k}} ^ {*}}{\| g _ {\mathcal {S} _ {k}} \left(x ^ {k}\right) \| ^ {2}} \right\}, c _ {k - 1} \gamma_ {k - 1} \right\}, \tag {DecSPS-NS}
+$$
+
+where $c_k \neq 0$ for every $k \geq 0$ , $\gamma_\ell \geq \gamma_b$ is a small positive number and all the other quantities are defined as in DecSPS. In particular, as for DecSPS, we set $c_{-1} = c_0$ and $\gamma_{-1} = \gamma_b$ . Intuitively, $\gamma_k$ is selected to live in the interval $[c_0\gamma_\ell / c_k, c_0\gamma_b / c_k]$ (see proof in §F, appendix), but has subgradient-dependent adaptive value. In addition, this stepsize is enforced to be monotonically decreasing.
+
+Theorem 5. For any non-decreasing positive sequence $(c_k)_{k=0}^{\infty}$ , consider SGD with DecSPS-NS. Assume that each $f_i$ is convex and lower bounded. We have
+
+$$
+\mathbb {E} \left[ f \left(\bar {x} ^ {K}\right) - f \left(x ^ {*}\right) \right] \leq \frac {c _ {K - 1} D ^ {2}}{\gamma_ {\ell} c _ {0} K} + \frac {1}{K} \sum_ {k = 0} ^ {K - 1} \frac {c _ {0} \gamma_ {b} G ^ {2}}{c _ {k}}, \tag {7}
+$$
+
+where $D^2 \coloneqq \max_{k \in [K-1]} \| x^k - x^* \|^2$ and $G^2 \coloneqq \max_{k \in [K-1]} \| g_{\mathcal{S}_k}(x^k) \|^2$ .
+
+One can then easily derive an $\mathcal{O}(1 / \sqrt{k})$ convergence rate. This is presented in $\S \mathrm{F}$ (appendix).
+
+# 6 Numerical Evaluation
+
+We evaluate the performance of DecSPS with $c_k = c_0 \sqrt{k + 1}$ on binary classification tasks, with regularized logistic loss $f(x) = \frac{1}{n} \sum_{i=1}^{n} \log(1 + \exp(y_i \cdot a_i^\top x)) + \frac{\lambda}{2} \|x\|^2$ , where $a_i \in \mathbb{R}^d$ is the feature vector for the $i$ -th datapoint and $y_i \in \{-1,1\}$ is the corresponding binary target.
+
+We study performance on three datasets: (1) a Synthetic Dataset, (2) The A1A dataset [6] and (3) the Breast Cancer dataset [10]. We choose different regularization levels and batch sizes bigger than 1. Details are reported in $\S G$ , and the code is available at https://github.com/aorvieto/DecSPS. At the batch sizes and regularizer levels we choose, the problems do not satisfy interpolation. Indeed, running full batch gradient descent yields $f^{*} > 0$ . While running $\mathrm{SPS}_{\mathrm{max}}$ on these problems (1) does not guarantee convergence to $f^{*}$ and (2) requires full knowledge of the set of optimal function values $\{f_S^*\}_{|S| = B}$ , in DecSPS we can simply pick the lower bound $0 = \ell_S^* \leq f_S^*$ for every $S$ . Supported by Theorems 3 & 4 & 5, we expect SGD with DecSPS to converge to the minimum $f^{*}$ .
+
+Stability of DecSPS. DecSPS has two hyperparameters: the upper bound $\gamma_{b}$ on the first stepsize and the scaling constant $c_{0}$ . While Thm. 5 guarantees convergence for any positive value of these hyperparameters, the result of Thm. 3 suggests that using $c_{0} = 1$ yields the best performance under the assumption that $\hat{\sigma}_{B}^{2} \ll \tilde{L}D^{2}$ (e.g. reasonable distance of initialization from the solution, and $L_{\max} > 1 / \gamma_{b}$ ). In Fig. 3, we show on the synthetic dataset that (1) $c_{0} = 1$ is indeed the best choice in this setting and (2) the performance of SGD with DecSPS is almost independent of $\gamma_{b}$ . Similar findings are reported and commented in Figure 7 (Appendix) for the other datasets. Hence, for all further experiments, we choose the hyperparameters $\gamma_{b} = 10, c_{0} = 1$ .
+
+Comparison with vanilla SGD with decreasing stepsize. We compare the performance of DecSPS against the classical decreasing SGD stepsize $\eta / \sqrt{k + 1}$ , which guarantees convergence to the exact solution at the same asymptotic rate as DecSPS. We show that, while the asymptotics are the same, DecSPS with hyperparameters $c_0 = 1$ , $\gamma_b = 10$ performs competitively to a fine-tuned $\eta$ — where crucially the optimal value of $\eta$ depends on the problem. This behavior is shown on all the considered datasets, and is reported in Figures 4 (Breast and Syn
+
+
+Figure 3: DecSPS $(c_{k} = c_{0}\sqrt{k + 1})$ sensitivity to hyperparameters on the Synthetic Dataset, with $\lambda = 0$ . Repeated 10 times and plotted is mean and std.
+
+
+
+thetic reported in the appendix for space constraints). If lower regularization $(1e - 4,1e - 6)$ is considered, then DecSPS can still match the performance of tuned SGD — but further tuning is needed (see Figure 14. Specifically, since the non-regularized problems do not have strong curvature, we found that DecSPS works best with a much higher $\gamma_{b}$ parameter and $c_{0} = 0.05$ .
+
+DecSPS yields a truly adaptive stepsize. We inspect the value of $\gamma_{k}$ returned by DecSPS, shown in Figures 4 & 8 (in the appendix). Compared to the vanilla SGD stepsize $\eta / \sqrt{k + 1}$ , a crucial difference appears: $\gamma_{k}$ decreases faster than $\mathcal{O}(1 / \sqrt{k})$ . This showcases that, while the factor $\sqrt{k + 1}$
+
+can be found in the formula of DecSPS7, the algorithm structure provides additional adaptation to curvature. Indeed, in (regularized) logistic regression, the local gradient Lipschitz constant increases as we approach the solution. Since the optimal stepsize for steadily-decreasing SGD is $1 / (L\sqrt{k + 1})$ , where $L$ is the global Lipschitz constant [13], it is pretty clear that $\eta$ should be decreased over training for optimal converge (as $L$ effectively increases). This is precisely what DecSPS is doing.
+
+Comparison with AdaGrad stepsizes. Last, we compare DecSPS with another adaptive coordinate-independent stepsize with strong theoretical guarantees: the norm version of AdaGrad (a.k.a. AdaGrad-Norm, AdaNorm), which guarantees the exact solution at the same asymptotic rate as DecSPS [32]. AdaGrad-norm at each iteration updates the scalar $b_{k+1}^2 = b_k^2 + \|\nabla f_{\mathcal{S}_k}(x_k)\|^2$ and then selects the next step as $x_{k+1} = x_k - \frac{\eta}{b_{k+1}} \nabla f_i(x_k)$ . Hence, it has tuning parameters $b_0$ and $\eta$ . In Fig. 4 we show that, on the Breast Cancer dataset, after fixing $b_0 = 0.1$ as recommended in [32] (see their Figure 3), tuning $\eta$ cannot quite match the performance of DecSPS. This behavior is also observed on the other two datasets we consider (see Fig. 9 in the Appendix). Last, in Fig. 10& 11 in the Appendix, we show that further tuning of $b_0$ likely does not yield a substantial improvement.
+
+
+Figure 4: Left: performance of DecSPS, on the A1A Dataset ( $\lambda = 0.01$ ). Right: performance of DecSPS on the Breast Cancer Dataset ( $\lambda = 1e - 1$ ). Further experiments can be found in $\S G$ (appendix).
+
+
+
+
+
+Comparison with Adam and AMSgrad without momentum. In Figures 5&12&13 we compare DecSPS with Adam [19] and AMSgrad [26] on the A1A and Breast Cancer datasets. Results show that DecSPS with the usual hyperparameters is comparable to the fine-tuned version of both these algorithms — which however do not enjoy convergence guarantees in the unbounded domain setting.
+
+
+Figure 5: Left: Performance of Adam (with fixed stepsize and no momentum) and Right: AMSgrad (with sqrt decreasing stepsize and no momentum) compared to DecSPS on the A1A and Breast Cancer dataset, respectively. Plots comparing the performance of Adam with DecSPS on the Breast Cancer Dataset can be found in Figure 13, and plots comparing AMSgrad with DecSPS on the A1A Dataset can be found in Figure 12. Plotted is also the average stepsize (each parameter evolves with a different stepsize).
+
+
+
+
+
+
+
+# 7 Conclusions and Future Work
+
+We provided a practical variant of SPS [22], which converges to the true problem solution without the interpolation assumption in convex stochastic problems — matching the rate of AdaGrad. If in addition, strong convexity is assumed, then we show how, in contrast to current results for AdaGrad, the bounded iterates assumption can be dropped. The main open direction is a proof of a faster rate $\mathcal{O}(1 / K)$ under strong convexity. Other possible extensions of our work include using the proposed new variants of SPS with accelerated methods, studying further the effect of mini-batching and non-uniform sampling of DecSPS, and extensions to the distributed and decentralized settings.
+
+# Acknowledgements
+
+This work was partially supported by the Canada CIFAR AI Chair Program. Simon Lacoste-Julien is a CIFAR Associate Fellow in the Learning in Machines & Brains program.
+
+# References
+
+[1] H. Asi and J. C. Duchi. The importance of better models in stochastic optimization. Proceedings of the National Academy of Sciences, 116(46):22924-22930, 2019.
+[2] H. Asi and J. C. Duchi. Stochastic (approximate) proximal point methods: Convergence, optimality, and adaptivity. SIAM Journal on Optimization, 29(3):2257-2290, 2019.
+[3] L. Berrada, A. Zisserman, and M. P. Kumar. Training neural networks for and by interpolation. In International Conference on Machine Learning, 2020.
+[4] L. Bottou, F. E. Curtis, and J. Nocedal. Optimization methods for large-scale machine learning. Siam Review, 60(2):223-311, 2018.
+[5] S. Boyd, L. Xiao, and A. Mutapcic. Subgradient methods. Lecture Notes of EE392o, Stanford University, Autumn Quarter, 2004:2004-2005, 2003.
+[6] C.-C. Chang. LIBSVM: a library for support vector machines. ACM Transactions on Intelligent Systems and Technology, 2011.
+[7] D. Davis, D. Drusvyatskiy, K. J. MacPhee, and C. Paquette. Subgradient methods for sharp weakly convex functions. Journal of Optimization Theory and Applications, 179(3):962-982, 2018.
+[8] A. Défossez, L. Bottou, F. Bach, and N. Usunier. A simple convergence proof of Adam and Adagrad. arXiv preprint arXiv:2003.02395, 2020.
+[9] R. D'Orazio, N. Loizou, I. Laradji, and I. Mitliagkas. Stochastic mirror descent: Convergence analysis and adaptive variants via the mirror stochastic Polyak stepsize. arXiv preprint arXiv:2110.15412, 2021.
+[10] D. Dua and C. Graff. UCI machine learning repository, 2017. URL http://archive.ics.uci.edu/ml.
+[11] J. Duchi, E. Hazan, and Y. Singer. Adaptive subgradient methods for online learning and stochastic optimization. Journal of Machine Learning Research, 12(7), 2011.
+[12] A. Ene and H. L. Nguyen. Adaptive and universal algorithms for variational inequalities with optimal convergence. arXiv preprint arXiv:2010.07799, 2020.
+[13] S. Ghadimi and G. Lan. Stochastic first-and zeroth-order methods for nonconvex stochastic programming. SIAM Journal on Optimization, 23(4), 2013.
+[14] I. Goodfellow, Y. Bengio, and A. Courville. Deep Learning. MIT press, 2016.
+[15] R. Gower, O. Sebbouh, and N. Loizou. SGD for structured nonconvex functions: Learning rates, minibatching and interpolation. In International Conference on Artificial Intelligence and Statistics, 2021.
+[16] R. M. Gower, N. Loizou, X. Qian, A. Sailanbayev, E. Shulgin, and P. Richtárik. SGD: General analysis and improved rates. In International Conference on Machine Learning, 2019.
+[17] R. M. Gower, A. Defazio, and M. Rabbat. Stochastic Polyak stepsize with a moving target. arXiv preprint arXiv:2106.11851, 2021.
+
+[18] E. Hazan and S. Kakade. Revisiting the Polyak step size. arXiv preprint arXiv:1905.00313, 2019.
+[19] D. P. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv:1412.6980, 2014.
+[20] H. Kushner and G. G. Yin. Stochastic Approximation and Recursive Algorithms and Applications, volume 35. Springer Science & Business Media, 2003.
+[21] K. Y. Levy, A. Yurtsever, and V. Cevher. Online adaptive methods, universality and acceleration. Advances in Neural Information Processing Systems, 31, 2018.
+[22] N. Loizou, S. Vaswani, I. H. Laradji, and S. Lacoste-Julien. Stochastic Polyak step-size for SGD: An adaptive learning rate for fast convergence. In International Conference on Artificial Intelligence and Statistics, 2021.
+[23] A. Nemirovski, A. Juditsky, G. Lan, and A. Shapiro. Robust stochastic approximation approach to stochastic programming. SIAM Journal on Optimization, 19(4):1574-1609, 2009.
+[24] A. M. Oberman and M. Prazeres. Stochastic gradient descent with Polyak's learning rate. arXiv preprint arXiv:1903.08688, 2019.
+[25] B. Polyak. Introduction to Optimization. Inc., Publications Division, New York, 1987.
+[26] S. J. Reddi, S. Kale, and S. Kumar. On the convergence of Adam and beyond. In International Conference on Learning Representations, 2018.
+[27] H. Robbins and S. Monro. A stochastic approximation method. The Annals of Mathematical Statistics, 1951.
+[28] M. Rolinek and G. Martius. L4: Practical loss-based stepsize adaptation for deep learning. Advances in neural information processing systems, 31, 2018.
+[29] T. Tieleman and G. Hinton. Lecture 6.5 - RMSprop, Coursera: Neural networks for machine learning. University of Toronto, Technical Report, 2012.
+[30] C. Traore and E. Pauwels. Sequential convergence of AdaGrad algorithm for smooth convex optimization. Operations Research Letters, 49(4):452-458, 2021.
+[31] S. Vaswani, I. Laradji, F. Kunstner, S. Y. Meng, M. Schmidt, and S. Lacoste-Julien. Adaptive gradient methods converge faster with over-parameterization (but you should do a line-search). arXiv preprint arXiv:2006.06835, 2020.
+[32] R. Ward, X. Wu, and L. Bottou. Adagrad stepsizes: Sharp convergence over nonconvex landscapes. In International Conference on Machine Learning, 2019.
+[33] Y. Xie, X. Wu, and R. Ward. Linear convergence of adaptive stochastic gradient descent. In International Conference on Artificial Intelligence and Statistics, 2020.
+[34] C. Zhang, S. Bengio, M. Hardt, B. Recht, and O. Vinyals. Understanding deep learning (still) requires rethinking generalization. Communications of the ACM, 64(3):107-115, 2021.
+[35] J. Zhang, S. P. Karimireddy, A. Veit, S. Kim, S. Reddi, S. Kumar, and S. Sra. Why are adaptive methods good for attention models? Advances in Neural Information Processing Systems, 33, 2020.
\ No newline at end of file
diff --git a/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/images.zip b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..4c6d8ac4051aeadb14c977dd04d41c98d609173c
--- /dev/null
+++ b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d064db6391af58badea15efa6ef7ce9f72f02d00b46a8e34e7bd75d8ce51f3a3
+size 323199
diff --git a/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/layout.json b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..7afb1430d13c63ed39d8184eab47198a208c577b
--- /dev/null
+++ b/dynamicsofsgdwithstochasticpolyakstepsizestrulyadaptivevariantsandconvergencetoexactsolution/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:24a36b825a9d8037be6e7713addd883bb6b42c7b999663a3fc98822b167a84de
+size 583564
diff --git a/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/0d22d662-c32b-4126-8268-0fede65e4c9d_content_list.json b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/0d22d662-c32b-4126-8268-0fede65e4c9d_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..7be3f6f227e65ad484bc11fc3c45bbb70428d1cc
--- /dev/null
+++ b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/0d22d662-c32b-4126-8268-0fede65e4c9d_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ece18f5c949a1a594cefcb800cee665ef0c3c1fe8320866764d2df4543256c71
+size 86357
diff --git a/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/0d22d662-c32b-4126-8268-0fede65e4c9d_model.json b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/0d22d662-c32b-4126-8268-0fede65e4c9d_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..357281312ae1cd1a12ea60733ee3f61d1568a2e4
--- /dev/null
+++ b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/0d22d662-c32b-4126-8268-0fede65e4c9d_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:817924066bc1fc422ac524926f70abb7393e19c54c8f77387412c3a67050bcff
+size 113673
diff --git a/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/0d22d662-c32b-4126-8268-0fede65e4c9d_origin.pdf b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/0d22d662-c32b-4126-8268-0fede65e4c9d_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..d6dd3b4a3493bf6b03c5874f09da33105446ffa7
--- /dev/null
+++ b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/0d22d662-c32b-4126-8268-0fede65e4c9d_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8948a665ce35a74d6e389837a308e6ba31c94dfca0c5e694eb8fee003d27dba4
+size 1230481
diff --git a/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/full.md b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..42f0d907b9d82a338d52c0496f73d457acf36c42
--- /dev/null
+++ b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/full.md
@@ -0,0 +1,363 @@
+# Dynamic Sparse Network for Time Series Classification: Learning What to “See”
+
+Qiao Xiao $^{1,*}$ , Boqian Wu $^{2,*}$ , Yu Zhang $^{3,4}$ , Shiwei Liu $^{5,1}$ , Mykola Pechenizkiy $^{1}$ , Elena Mocanu $^{2}$ , Decebal Constantin Mocanu $^{1,2}$
+
+1 Eindhoven University of Technology, 2 University of Twente
+
+$^{3}$ Southern University of Science and Technology
+
+$^{4}$ Peng Cheng Laboratory, $^{5}$ University of Texas at Austin
+
+{q.xiao,m.pechenizkiy}@tue.nl
+
+{b.wu,e.mocanu,d.c.mocanu}@utwente.nl
+
+yu.zhang.ust@gmail.com
+
+shiwei.liu@austin.utexas.edu
+
+# Abstract
+
+The receptive field (RF), which determines the region of time series to be "seen" and used, is critical to improve the performance for time series classification (TSC). However, the variation of signal scales across and within time series data, makes it challenging to decide on proper RF sizes for TSC. In this paper, we propose a dynamic sparse network (DSN) with sparse connections for TSC, which can learn to cover various RF without cumbersome hyper-parameters tuning. The kernels in each sparse layer are sparse and can be explored under the constraint regions by dynamic sparse training, which makes it possible to reduce the resource cost. The experimental results show that the proposed DSN model can achieve state-of-art performance on both univariate and multivariate TSC datasets with less than $50\%$ computational cost compared with recent baseline methods, opening the path towards more accurate resource-aware methods for time series analyses. Our code is publicly available at: https://github.com/QiaoXiao7282/DSN.
+
+# 1 Introduction
+
+Time series classification (TSC) as an important research topic in the data mining communities [14], has a wide range of applications from health monitoring [24, 16], and public security [58], to grid energy [41], and remote sensing [43]. In the last decade, neural networks, especially deep neural networks, have achieved competitive or even better performance than traditional TSC approaches (e.g. DTW [46], BOSS [47], COTE [1]) in many cases [56, 14].
+
+However, how to discover and exploit the various scaled signals hidden in time series (TS) is still a significant challenge for TSC tasks [52, 36, 21]. One main reason lies in several variances, like sampling rate and record length, which are natural during time-series collection [47, 31, 5]. Furthermore, the amplitude offset, warping and occlusion of data points are unavoidable (see Figure 1). So determining the optimal scales for feature extraction is difficult but significant in the TSC task. One main solution is to cover as many receptive fields (RF) scales as possible, so it does not ignore any useful signals from the time series inputs [52, 7, 8, 25].
+
+Grounding on the motivation that multiple kernels in combination can capture discriminative patterns despite complex warping, Fawaz et al. [15] tried to ensemble convolutional neural networks with a large number and variety of kernels. Tang et al. [53] have stacked several OS-CNN blocks, each of
+
+which consisted of a list of kernel sizes to cover all scales of RF and achieve better performance on several TSC tasks. In Multi-scale Convolutional Neural Network (MCNN) [4], a grid search was applied to find suitable kernel sizes. Without elaborate setting and fine-grid search, Dempster et al. [7] transformed time series by using random convolutional kernels and then trained a time series classifier. Even though the use of kernels with various sizes can help to extract latent hierarchical features of multiple resolutions, it tends to cause a huge computational problem and overfits the datasets when a limited amount of training data is available [25]. To address this problem, dilated convolution [59] has been used to reduce the computational cost while keeping the receptive field size. Franceschi et al. [17] presented an unsupervised learning model with convolutional kernels for time series feature transformation, in which the dilation factors of kernels increased exponentially layer by layer. To date, there is still an unresolved challenge with hyperparameter selections (e.g. kernel sizes and dilated factors) to capture patterns at different scales. This raises a foundational question: Can we design a scalable method for TSC that achieves a trade-off between computation and performance without cumbersome hyperparameter tuning?
+
+
+(1)
+
+
+(2)
+
+
+(3)
+
+
+(a)
+
+
+(b)
+Figure 1: (a) Toy example illustrates the various time scales characteristic of TS data. Data in (1), (2), and (3) are sampled from three different TS datasets. The sequences with the same color represent the same class. We can find that several sources of variances like phase, warping and offset are common in TS data. (b) The comparison between other methods [53, 25] (shown in b1) and our proposed DSN (shown in b2) for TSC. To cover various RF, DSN does not need to be configured with a series of kernel sizes $k$ .
+
+Inspired by sparse neural network models which can match the performance of dense counterparts with fewer connections [40, 35, 33, 60], we propose a dynamic sparse network (DSN) that is composed of CNN layers with large but dynamic sparse kernel for TSC tasks, which can automatically learn sparse connections in terms of covering various RF. The proposed DSN is trained by a dynamic sparse training (DST) strategy, which makes it possible to reduce the computational cost (e.g. floating-point operations (FLOPs)) for training and inference as well. Different from the traditional dynamic sparse training methods, which explore the connections in a layer-wise manner [40, 34, 13] and can hardly cover smaller RF, we propose a more fine-grained sparse training strategy for TSC. Specifically, the CNN kernels in each layer are split into several groups, each of which is sparse and can be explored under a constraint region during sparse training. In this way, each layer can extract features in a more scalable and diverse way, and then by cascading, the model can cover more various scales of RF. To sum up, our main contributions are:
+
+- We propose a novel dynamic sparse CNN layer with various effective neighbour RF, which can learn to "see" selectively and adaptively for more accurate TSC.
+- By stacking the above dynamic sparse CNN layers, we introduce a novel DSN model natively for TSC, which is trained by DST to reduce computational and memory cost.
+- To bridge the gap between resource awareness and accuracy, we propose a more fine-grained training strategy for DSN, which can more easily cover diverse effective RF for TSC.
+- We perform extensive empirical evaluation on both univariate and multivariate TSC tasks, showing that DSN achieves superior performance in terms of accuracy and resource cost.
+
+# 2 Related Work
+
+# 2.1 Time Series Classification
+
+In the last decade, the success of deep learning encourages researchers to explore and extend its application on TSC tasks [28, 14, 56, 23, 29]. For univariate TSC, deep learning-based models attempt to directly transform raw time series data into low-dimensional feature representation via convolutional or recurrent networks [25, 45, 42]. For multivariate TSC, LSTM and attention layers are often stacked with CNN layers to extract complementary features from TS data [26, 62].
+
+Recently, many works have attempted to extract features in a more scalable manner as TS data is unavoidably composed of signals on various scales [47, 5, 52]. One main solution is to configure suitable kernels of various sizes such that they increase the probability of capturing the proper scales [52, 53, 25]. Rocket-based methods [7, 8, 9] aim to use random kernels with several sizes and dilation factors to cover diverse RF for TSC. Different from these works, our proposed dynamic sparse CNN layer can adaptively learn the various RF with deformable dilation factors and trade-off both computation and performance without cumbersome hyperparameter tuning.
+
+# 2.2 Sparse Training
+
+Recently, the lottery ticket hypothesis has shown that it is possible to train a sparse sub-network to match the performance of its dense counterpart with less computational cost [18]. Rather than iteratively pruning from a dense network [19, 63, 18], recent works try to find an initial mask with one-shot pruning based on gradient information during training [30, 55]. After pruning, the topology of the neural network will be fixed during training. However, this kind of models can hardly match the accuracy achieved by their dense counterparts [38, 55, 51].
+
+Introduced as a new training paradigm before the lottery ticket hypothesis, DST starts from a sparse network and allows the sparse connectivity to be evolved dynamically with a fixed number of parameters throughout training [40, 13, 35, 60, 10]. Nowadays, DST attracts increasing attentions from other research fields such as reinforcement learning [49] and continual learning [48], due to its potential of outperforming dense neural networks training [40, 60, 35]. Different from the traditional DST methods, our proposed DSN is trained with a fine-grained sparse training strategy rather than a traditional layer-wise manner to capture more diverse RF for TSC.
+
+# 2.3 Adaptive Receptive Field
+
+The RF, which can be adaptively changed during the training, has proven to be effective in many domains [54, 44, 57]. The adaptive RF can usually be captured by learning the optimal kernel sizes or the masks of kernels during the course of training [50, 20, 57]. However, neither the kernels nor the masks are sparse, which may cause the huge computational problem when larger RF is needed. Different from these methods, our dynamic sparse CNN layers in DSN can be trained with DST, which can learn to capture variable RF with deformable dilation factors. What's more, the kernels are always sparse during training and inference, which makes it possible to reduce the computational cost.
+
+# 3 The Proposed Model
+
+# 3.1 Problem Definition
+
+Definition 1. (Time Series Classification (TSC)). Given a TS instance $\mathbf{X} = \{\mathbf{X}_1, \dots, \mathbf{X}_n\} \in \mathbb{R}^{n \times m}$ , where $m$ denotes the number of variates and $n$ denotes the number of time steps, TSC aims to accurately predict the class label $y \in \{1, \dots, c\}$ from $c$ classes. When $m$ equals 1, TSC is univariate and otherwise it is multivariate.
+
+Definition 2. (Time Series (TS) Training Set). A training set $\mathcal{D} = \{\left(\mathbf{X}^{(1)},y^{(1)}\right),\ldots ,$ $\left(\mathbf{X}^{(N)},y^{(N)}\right)\}$ consists of $N$ time series instances, where $\mathbf{X}^{(i)}\in \mathbb{R}^{n\times m}$ could either be a univariate or multivariate time series instance with its corresponding label $y^{(i)}\in \{1,\dots ,c\}$
+
+Note that, in our case, all instances have the same number of time steps in a TS dataset. Without the loss of generality, given a training set, we aim to train a CNN classifier with adaptive and various RF with a low resource cost (e.g. memory and computation) for the TSC task.
+
+# 3.2 Dynamic Sparse CNN Layer with Adaptive Receptive Field
+
+A straightforward strategy to cover various RF is to apply multi-sized kernels in each CNN layer, but it has several limitations. Firstly, TS instances from different TS datasets do not have the same length and cycles ${}^{2}$ in most cases, making it difficult to set a fixed kernel configuration for all the datasets even with prior knowledge. Secondly, obtaining a large receptive field commonly requires a large kernel or stacking more layers, which introduces more parameters and thus increases storage and computational costs.
+
+To tackle those challenges, the proposed dynamic sparse CNN layer possesses large but sparse kernels, which are learnable to capture adaptive RF. Specifically, given the input feature map $x^{l} \in \mathbb{R}^{c_{l-1} \times h \times w}$ in the $l$ th layer ( $h$ equals 1 for univariate TSC and $c_{l-1}$ is the number of input channels), and kernel weights $\Theta^{l} \in \mathbb{R}^{c_{l-1} \times c_{l} \times 1 \times k}$ ( $k$ is the kernel size and $c_{l}$ is the number of output channels), the convolution with stride 1 and padding in our proposed dynamic sparse CNN layer is formulated as
+
+$$
+\mathbf {O} _ {j} = \sum_ {0 < i \leq c _ {l - 1}, i \in \mathbb {Z}} \left(\mathbf {I} ^ {l} \left(\Theta^ {l}\right) _ {i, j} \odot \Theta_ {i, j} ^ {l}\right) \cdot x _ {i} ^ {l}, \tag {1}
+$$
+
+where $\mathbf{O}_j\in \mathbb{R}^{h\times w}$ denotes the output feature representation at the $j$ -th output channel, $\mathbb{Z}$ denotes the set of integers, $\mathbf{I}^l (\cdot):\mathbb{R}^{c_{l - 1}\times c_l\times 1\times k}\to \{0,1\}^{c_{l - 1}\times c_l\times 1\times k}$ is an indicator function, $\mathbf{I}^l (\Theta^l)_{i,j}$ indicates activated weights for $\Theta_{i,j}^l\in \mathbb{R}^{1\times k}$ which is the kernel in the $(i,j)$ -th channel, $\odot$ denotes the element-wise product, and $\cdot$ denotes the convolution operator. The indicator function $\mathbf{I}^l (\cdot)$ , which is learned during the training of the proposed DSN, satisfies that $\| \mathbf{I}^l (\cdot)\| _0\leq (1 - S)N_l$ where $0\leq S < 1$ is the sparsity ratio, $\| .\| _0$ denotes the $L_0$ norm and $N_{l} = c_{l - 1}\times c_{l}\times 1\times k$ . When $S > 0$ , the kernel is sparse, and we can use a large $k$ in the dynamic sparse CNN layer to obtain a large RF with reduced computational cost.
+
+Remark. (Effective Neighbour Receptive Field (eNRF) size in the dynamic sparse CNN layer). The receptive field is defined as the region in the input that the feature of a CNN model is looking at. We defined the Neighbour Receptive Field (NRF) as the region considered by each feature in the successive layer. Specifically, the NRF size is equivalent to the kernel size in the standard CNN layer (Considering the case that dilation equals to 1). Differently, the NRF size of the proposed dynamic sparse CNN layer is smaller than the kernel size, when the first or last weight in a kernel is not activated, e.g., $\exists i \in \{1, \dots, c_{l-1}\}$ and $j \in \{1, \dots, c_l\}$ , such that $I^l(\Theta^l)_{i,j,1,1} = 0$ or $I^l(\Theta^l)_{i,j,1,k} = 0$ . As illustrated in Figure 2, we defined the eNRF size $f_{i,j}^l$ of the kernel $\Theta_{i,j}^l$ as the distance between the first activated weight and last activated weight in the $l$ -th CNN layer as
+
+$$
+f _ {i, j} ^ {l} := \left\{ \begin{array}{l l} \max \left(\operatorname {I n d} _ {i, j} ^ {l}\right) - \min \left(\operatorname {I n d} _ {i, j} ^ {l}\right) + 1, & \text {i f} \operatorname {I n d} _ {i, j} ^ {l} \neq \varnothing \\ 0, & \text {o t h e r w i s e} \end{array} , \right. \tag {2}
+$$
+
+where $\operatorname{Ind}_{i,j}^{l}$ denotes the set of indices corresponding to non-zero weights in the kernel $\Theta_{i,j}^{l}$ . Obviously we have $0 \leq f_{i,j}^{l} \leq k$ .
+
+The eNRF size set of $l$ -th dynamic sparse CNN layer is denoted by $\mathbb{F}^{(l)}$ , which satisfies that $0 \leq \min(\mathbb{F}^{(l)})$ and $\max(\mathbb{F}^{(l)}) \leq k$ . Take the case in the Figure 2 as an simple example for $l$ -th layer, then $\mathbb{F}^{(l)} = \{0,1,2,3,4,5,6\}$ . Each dynamic sparse CNN layer is likely to cover various eNRF sizes ranging from 1 to $k$ . When global information is expected, $\mathbf{I}^l(\cdot)$ could activate weights more dispersed to get a larger eNRF and exploit the input features selectively. To capture the local context, a smaller eNRF is expected, thus the activated weights tend to be
+
+
+Figure 2: Illustrations for the eNRF size. The weights with blue color are activated.
+
+concentrated. By taking $k = 5$ as an example, $\mathbf{I}^l (\Theta^l)_{i,j}$ may be [1, 0, 1, 0, 1] for global context, while it may be [0, 0, 1, 1, 0] for local context. In this way, the eNRF can be adaptively adjusted.
+
+# 3.3 Architecture in DSN
+
+The proposed DSN model consists of three sparse CNN modules, each of which composes of a dynamic sparse CNN layer and a $1 \times 1$ CNN layer. Following the stacked sparse CNN modules, there is an additional dynamic sparse CNN layer, two adaptive average pooling layers, and one $1 \times 1$ convolution layer acting as the classifier in the DSN model. The overall architecture is shown in Figure 3.
+
+
+Figure 3: The proposed DSN model (left), which includes several sparse CNN modules (right) followed by a dynamic sparse CNN layer, two adaptive average pooling layers, and one $1 \times 1$ convolution layer.
+
+The set of eNRF sizes $\mathbb{S}^{(l)}$ in the $l$ th sparse CNN module is equal to that in the dynamic sparse CNN layer, since the eNRF size of $1 \times 1$ convolution is constantly equal to 1. $\mathbb{S}^{(l)}$ satisfies that $0 \leq \min(\mathbb{S}^{(l)})$ and $\max(\mathbb{S}^{(l)}) \leq k$ . Then, the set of eNRF sizes for the three successively stacked sparse CNN modules can be described by $\mathbb{R}\mathbb{F}$ as
+
+$$
+\mathbb {R} \mathbb {F} = \left\{\max \left(0, s ^ {(1)} + s ^ {(2)} + s ^ {(3)} - 2\right) \mid s ^ {(i)} \in \mathbb {S} ^ {(i)}, i \in \{1, 2, 3 \} \right\}. \tag {3}
+$$
+
+According to Eq. (3), we can see that stacking multiple sparse CNN modules can increase the size of $\mathbb{R}\mathbb{F}$ linearly, where $l$ th dynamic sparse CNN layer increases by the size of $\mathbb{S}^{(l)}$ . For simplicity, the kernel size in each dynamic sparse CNN layer is consistently set to $k$ in our study. Then, $\mathbb{R}\mathbb{F}$ satisfies that $\max (\mathbb{R}\mathbb{F})\leq 3k - 2$ and $0\leq \min (\mathbb{R}\mathbb{F})$ . Thus, a large $k$ in sparse CNN modules can increase the range of the eNRF sizes for stacked sparse CNN modules.
+
+
+Figure 4: An illustration of the dynamic sparse CNN layer. In a dynamic sparse CNN layer, the kernels are split into $N$ groups, each of which is with sparse connections learned by dynamic sparse training across specific constraint regions. The connections with color indicate non-zero values.
+
+# 3.4 Dynamic Sparse Training for DSN Model
+
+In this section, we present the training strategy to discover the weights required to be activated in order to ensure well-performing RF. That is, we need to study how to update the indicator function $\mathbf{I}^l(\cdot)$ during the training of the proposed DSN.
+
+We sparsely train the proposed DSN model from scratch to keep kernel sparse following the main idea of DST methods [40]. By design, during the training phase, the total number of activated weights must not exceed $N_{l}(1 - S)$ . However, we observe that the tiny eNRF is hard to be captured by DST methods with a layer-wise exploration manner, namely activated weights are discovered layer by layer, especially when the sparsity ratio $S$ is undersized (more analysis in Section 4.5). Motivated by this observation, the kernels in each dynamic sparse CNN layer are divided into different groups, whose corresponding exploration regions are of different sizes as shown in Figure 4. Contrary to the DST methods, in DSN, the exploration of activated weights is separately performed in different kernel groups, which is a more fine-grained strategy. Specifically, the kernel weights $\Theta^{l} \in \mathbb{R}^{c_{l-1} \times c_{l} \times 1 \times k}$ in the $l$ th layer are split into $N$ groups along the output chan
+
+# Algorithm 1 Dynamic Sparse Training for DSN Model
+
+| Input: Dataset D, Network fΘ, Sparsity ratio S
+Exploration regions in layer l: {Rl1,..., RlN}
+Exploration schedule: T, ΔT, α, fdecay |
| 1: θl← initialize activated weights in Θl using S and Rl |
| 2: for t = 1 to T do |
| 3: Sample a batch Bt ~ D |
| 4: Lt = ∑i~Bt L ((fθ(xi), yi) |
| 5: if (t mod ΔT) == 0 then |
| 6: for each layer l = 1 to L do |
| 7: for each group i = 1 to N do |
| 8: u = n(Rl)fdecay(t; α, T) (1 - S) |
| 9: Iprune = ArgTopK(−|θl|, u) |
| 10: Igrow = RandomK(Rl\θl, u) |
| 11: Il(. ) ← Update Il(. ) using Iprune and Igrow |
| 12: θl← Update activated weights Il(Θl) ⊙ Θl |
| 13: end for |
| 14: end for |
| 15: else |
| 16: θ = θ - α∇θLt |
| 17: end if |
| 18: end for |
+
+nel, that is, $\Theta_1^l,\ldots ,\Theta_N^l\in \mathbb{R}^{c_{l - 1}\times \frac{c_l}{N}\times 1\times k}$ with corresponding exploration regions $\mathcal{R}_1^l,\dots ,\mathcal{R}_N^l$ . The exploration region $\mathcal{R}_i^l$ in the $i$ th group of the $l$ th layer is defined as the first $\frac{i\times k}{N}$ positions of each kernel in this group. By taking $k = 6$ and $N = 3$ for example, activated weights in the first group are only within the first two positions of each kernel in $\Theta_1^l$ , while they are within the whole kernel for the last group (as shown in Figure 4). In this way, the various eNRF can be covered, and exploration space can be reduced (more details can be found in Appendix A.1) to improve exploration efficiency.
+
+Given the weight exploration regions $\mathcal{R}_1^l,\dots ,\mathcal{R}_N^l$ and the sparsity ratio $S$ , we train the proposed DSN model as shown in Algorithm 1. The activated weights are explored within the exploration regions and updated every $\Delta_t$ iterations. The fraction of updated weight decays over time according the function $f_{\mathrm{decay}}(t;\alpha ,T)$ , which follows the cosine annealing [11] as
+
+$$
+f _ {d e c a y} (t; \alpha , T) = \frac {\alpha}{2} \left(1 + \cos \left(\frac {t \pi}{T}\right)\right), \tag {4}
+$$
+
+where $\alpha$ is the initial fraction of activated weights updated, $t$ is the current training iteration, and $T$ is the number of training iterations. Thus, during the $t$ th iteration, the number of updated activated weights in the $i$ th group of the $l$ th layer is $n(\mathcal{R}_i^l)f_{\mathrm{decay}}(t;\alpha ,T)(1 - S)$ , where $n(\mathcal{R}_i^l)$ is the number of weights can be explored in region $R_i^l$ . During the update of activated weights, we firstly prune the activated weights determined by $\operatorname{ArgTopK}\left(-\left|\theta_i^l\right|,u\right)$ and then randomly grow new activated weights by $\operatorname{RandomK}\left(\mathcal{R}_i^l\backslash \theta_i^l,u\right)$ , where $\operatorname{ArgTopK}(\mathbf{v},u)$ gives the indices of top $u$ elements with larger values in a vector $\mathbf{v}$ , $\operatorname{RandomK}(\mathbf{v},u)$ outputs the indices of random $u$ elements in a vector $\mathbf{v}$ , and $\mathcal{R}_i^l\backslash \theta_i^l$ denotes the weights within $\mathcal{R}_i^l$ but except $\theta_i^l$ .
+
+The exploration of activated weights is straightforward. Firstly, pruning weights with small magnitudes is intuitive, because the contribution of weights with smaller magnitudes is insignificant or even negligible. Considering the pruning recoverability, we randomly regrow new weights with the same number as the pruned weights to achieve better activated weight exploration. In this way, the exploration of weights is dynamic and of plasticity, compared with the methods of pruning weights before and after training (more explanations about pruning and dynamic sparse training can be found in [22, 39, 32]).
+
+# 4 Experiments
+
+In this section, we evaluate the resource cost and accuracy of the proposed DSN model with recent baseline methods on both univariate and multivariate TSC data.
+
+# 4.1 Datasets and Baselines
+
+The details of each kind of dataset are as follows.
+
+- Univariate TS dataset from UCR 85 archive [3]: This archive consists of 85 univariate TS datasets, which are collected from various domains (e.g. health monitoring and remote sensing), have distinguishable characteristics, and various levels of complexity. The number of instances in the training set varies from 16 to 8926, while their time step resolutions range from 24 to 2709.
+- Three multivariate TS datasets from UCI [12]: The EEG2 dataset contains 1200 instances of 2 categories and 64 variates. The Human Activity Recognition (HAR) dataset consists of 10,299 instances with 6 categories, and the number of variates is 9. The Daily Sport dataset contains 9,120 instances of 19 categories, and its number of variates is 45. The processing of these datasets is the same as in [26].
+
+Univariate TSC baselines: The performance of the following three baseline methods are reported, OS-CNN [52], InceptionTime [25], and ResNet[56], as they are widely used for univariate TSC. Multivariate TSC baselines: Similar with [62], the following three multivariate baselines are selected: OS-CNN, TapNet [62], MLSTM-FCN [26]. To avoid an unfair comparison, we let outside the ensemble methods. However, based on our best knowledge, our performance analysis accounts for most of state-of-the-art methods.
+
+# 4.2 Experimental Settings and Implementation Details
+
+For optimization, we use the Adam optimizer with an initial learning rate of $3 \times 10^{-4}$ , cosine decayed to $10^{-4}$ . Our model is trained for 1,000 epochs with a mini-batch size of 16. As in [25, 26], the best model, which corresponds to the minimum training loss, is used to evaluate performance over the testing sets. Inspired by [25], the kernel sizes $k$ in each dynamic sparse CNN layer are set to 39. The number of kernel groups $N$ in Algorithm 1 is set to 3, which helps to cover the small, medium, and large eNRF. Each setting is repeated five times, and the average results are reported.
+
+# 4.3 Results and Analysis
+
+We show the performance on both univariate and multivariate TSC benchmarks in Table 1-2. For univariate TSC, we can see that our method outperforms the baseline methods in most cases with a smaller number of parameters (e.g. Params $^{3}$ ) and less computation cost (e.g. FLOPs) on UCR 85 archive datasets. For multivariate TSC, our proposed DSN method achieves better performance on EEG2 and HAR datasets, while for Daily Sport, MLSTM-FCN was with $0.46\%$ more accurate. It is worth highlighting that the resource cost (i.e. Params and FLOPs) of our proposed DSN is much smaller than that of baseline methods. Due to the page limitation, the detailed results, including test accuracy and resource cost on each dataset of UCR 85 archive, can be found in Appendix C. More results on UCR 128 [6] and UEA 30 archive [2] can be found in Appendix B.9.
+
+Table 1: Pairwise comparison of test accuracy $(\%)$ and mean resource cost (i.e. Params $(K)\downarrow$ and FLOPs $(M)\downarrow)$ of our method and other univariate TS baseline methods on UCR 85 archive datasets. Note that all the accuracies in comparison are rounded to two decimal places.
+
+| Archive | Methods | Baseline wins | DSN wins | Tie | Params | FLOPs |
| UCR 85 archive | ResNet | 29 | 53 | 3 | 479.20 | 803.38 |
| InceptionTime | 40 | 40 | 5 | 389.34 | 325.49 |
| OS-CNN | 33 | 49 | 3 | 262.14 | 200.12 |
| DSN (ours) | - | - | - | 126.22 | 104.88 |
+
+# 4.4 Sensitivity Analysis
+
+Effect of Sparsity Ratio: From Table 3, we can find out how the sparsity ratio of dynamic sparse CNN layer affects the final test accuracy and the resource cost in multivariate TS datasets. Here,
+
+Table 2: Test accuracy (ACC(%) and resource cost (i.e. Params $(K)\downarrow$ and FLOPs $(M)\downarrow$ ) of different models on three multivariate TS datasets from UCI.
+
+ | Daily Sport | EEG2 | HAR |
| Methods | ACC | Params | FLOPs | ACC | Params | FLOPs | ACC | Params | FLOPs |
| TapNet | 99.56 | 1885.58 | 346.97 | 85.30 | 1369.21 | 780.19 | 93.33 | 1275.78 | 310.61 |
| MLSTM-FCN | 99.65 | 324.77 | 70.59 | 91.00 | 342.51 | 161.53 | 96.71 | 284.97 | 63.38 |
| OS-CNN | 99.30 | 317.05 | 78.01 | 93.03 | 320.34 | 162.04 | 96.37 | 280.39 | 70.98 |
| DSN (ours) | 99.19 | 163.68 | 40.48 | 99.10 | 162.14 | 82.31 | 96.82 | 160.13 | 40.64 |
+
+we analyze the trade-off between test accuracy and the resource cost under various sparsity ratios (i.e. $S \in [50\%, 80\%, 90\%]$ ) and a dense DSN model. Note that the dense model is defined exactly as our DSN model with dense connections along entire kernels. We can see that it is not that the more parameters of the model, the better performance it will achieve. This is mainly because more parameters will lead to overfitting and the proper sparse ratio will easily cover the desired receptive field (more demonstrations can be seen in Appendix B.1). Taking the EEG2 data set as an example, with the decrease of sparse rate, the performance on it drops sharply. We hypothesise that this data set has more expectations for features from small receptive fields (the validation can be found in Appendix B.2). According to the experiments, a $80\%$ sparsity ratio reflects a good trade-off between accuracy and resource cost, which is the default setting for the dynamic sparse CNN layer in our DSN model.
+
+Table 3: Test accuracy (ACC(%) and resource cost (i.e. Params $(K)\downarrow$ and FLOPs $(M)\downarrow$ ) of the proposed DSN model with different sparsity ratios on three multivariate TS datasets from UCI.
+
+ | Daily Sport | EEG2 | HAR |
| Methods | ACC | Params | FLOPs | ACC | Params | FLOPs | ACC | Params | FLOPs |
| Dense | 99.19 | 1059.65 | 262.10 | 89.60 | 1058.11 | 536.17 | 96.06 | 1056.10 | 267.57 |
| S=50% | 99.28 | 370.44 | 91.63 | 96.23 | 368.90 | 187.05 | 96.62 | 366.89 | 93.01 |
| S=80% | 99.19 | 163.68 | 40.48 | 99.10 | 162.14 | 82.31 | 96.82 | 160.13 | 40.64 |
| S=90% | 99.25 | 94.76 | 23.44 | 98.90 | 93.22 | 46.64 | 96.75 | 91.21 | 23.18 |
+
+Effect of Architecture: To show how the architecture of DSN affects the final performance, we adopt the critical difference diagram for a detailed comparison, which is usually used for evaluation in TSC [52, 25]. From Figure 5, we can find that the DSN model with 4 dynamic sparse CNN layers and 177 output channels in each layer performs consistently better than the other structures. The proposed model with more output channels seems to be crucial for preserving the capacity of the network, while requires more parameters and FLOPs compared to other counterparts. This highlights an interesting trade-off between accuracy and computational efficiency. According to the experiments, the DSN model with 4 dynamic sparse CNN layers and 141 output channels in each layer is the trade-off between the performance and resource cost, which is the default setting for our DSN model.
+
+
+Figure 5: The critical difference diagram shows the average rank of the proposed DSN model with different architectures in UCR 85 archive. $\mathrm{DSN}(\mathrm{di - c}j)$ represents the DSN model with $i$ dynamic sparse CNN layers and $j$ output channels in each layer. The smaller average rank corresponds to the better performance of the model.
+
+Effect of Kernel Group: As shown in Figure 6, training DSN without kernel group hampers the capture of small eNRF, which can not guarantee satisfactory performance on the datasets such as EEG2 expecting more local information. With the decrease in sparsity ratio $S$ , the phenomenon that large RF occupies the majority becomes more severe (more demonstrations see in Appendix B.1),
+
+which increases the performance gap between training with group and without it, as shown in Table 4. Grouping the kernels can achieve various RF coverage and adorable accuracy for all datasets.
+
+
+(a)
+
+
+(b)
+Figure 6: The distribution of eNRF sizes in different sparse CNN layers between DSN models training with and without grouping on HAR dataset. The number on y-axis corresponds to the frequency of eNRF sizes.
+
+
+(c)
+
+# 4.5 Ablation Study
+
+Effect of Dynamic Sparse Training: Furthermore, we study the effect of the dynamic sparse training in our DSN method. We conduct ablation studies to compare DSN with its static variant (i.e. $\mathrm{DSN}^{fix}$ ), which fixes its topology during training after activated weights initialization. In other words, the indicator function $\mathbf{I}^l(\cdot)$ in Eq. (1) will not update during the training process. According to the re
+
+Table 4: Average accuracies (%) of the proposed DSN model affected by kernel grouping.
+
+| Sparsity ratio | Methods | Daily Sport | EEG2 | HAR |
| S=60% | DSN w Group | 99.27 | 97.87 | 96.53 |
| DSN w/o Group | 99.23 | 96.77 | 96.87 |
| S=70% | DSN w Group | 99.20 | 98.70 | 97.14 |
| DSN w/o Group | 99.25 | 97.27 | 96.52 |
| S=80% | DSN w Group | 99.19 | 99.10 | 96.82 |
| DSN w/o Group | 99.28 | 98.77 | 96.79 |
+
+sults shown in Figure 7 (a), we can find that the DSN model mostly outperforms the $\mathrm{DSN}^{fix}$ on UCR 85 archive, indicating that what is learned by dynamic sparse training is the suitable activated weights together with their values.
+
+
+(a)
+
+
+(b)
+Figure 7: Accuracy plotting showing how the proposed DSN model is affected by the dynamic sparse training in UCR 85 archive.
+
+
+(c)
+
+# 4.6 Case Study on other DST Method
+
+Likewise, the effectiveness of the proposed DSN method is also analyzed in the presence of other DST methods, such as RigL [13]. Rather than growing weights randomly (as in the line 9 of Algorithm 1), RigL grows them with the highest magnitude gradients. From Figure 7 (c), we can see that growing weights according to gradients (i.e. $\mathrm{DSN}_{\mathrm{grad}}$ ) can outperforms the OS-CNN method in most cases on
+
+
+(a)
+Figure 8: The activated weights in different kernel groups.
+
+
+(b)
+
+
+(c)
+
+
+
+UCR 85 archive. Furthermore, as shown in Figure 7 (b), we can find that $\mathrm{DSN}_{\text{grad}}$ has a similar performance as growing weights randomly (i.e. $\mathrm{DSN}_{\text{rand}}$ ). Note that, $\mathrm{DSN}_{\text{rand}}$ is the main setting of the proposed method in this paper with the reason that we don't need to compute the full gradients at any moment in time. In summary, the proposed DSN with fine-grained sparse strategy can be easily combined with the existing DST techniques, showing the potential for further improvements by merging it with other advanced DST methods in the future.
+
+# 4.7 Visualization of Activated Weights
+
+Figure 8 shows the normalized activated weights of the DSN model after sparse training on HAR dataset. (a), (b) and (c) correspond to the activated weights of the three kernel groups in the first dynamic sparse CNN layer, and each row of the figure represents one kernel. We can see that the weights in each kernel are sparse, and can be activated within the constraint region defined in Section 3.4.
+
+# 5 Conclusions
+
+This paper proposes dynamic sparse network (DSN) to cover diverse effective neighbour receptive field (eNRF) for time series classification (TSC) without the cumbersome hyper-parameters tuning. The proposed DSN can achieve about $2\times$ reduction in memory and computational cost, while achieving superior performance in terms of accuracy on both univariate and multivariate TSC datasets. Furthermore, DSN explores the activated weights in a more fine-grained strategy, which can be easily merged with existing DST techniques, showing a potential for further improvements when combined with advanced technology. DSN provides a feasible solution to bridge the gap between resource awareness and various eNRF coverage for TSC, hoping to inspire other researchers in different fields. It is worthwhile extending DSN to other research domains (e.g. time series forecasting and computer vision). Our DSN model has not yet been executed on real edge devices, and the performance in terms of accuracy and memory footprint on edge devices is not investigated. In the future, we hope to extend our work to other fields and decentralise training on edge devices.
+
+# Acknowledgements
+
+This work has been partly funded by the NWO Perspectief project MEGAMIND. We thank everyone who worked on making the datasets available and their contributions to the TSC community.
+
+# References
+
+[1] Anthony Bagnall, Jason Lines, Jon Hills, and Aaron Bostrom. Time-series classification with cote: the collective of transformation-based ensembles. IEEE Transactions on Knowledge and Data Engineering, 27(9):2522-2535, 2015.
+[2] Anthony J. Bagnall, Hoang Anh Dau, Jason Lines, Michael Flynn, James Large, Aaron Bostrom, Paul Southam, and Eamonn J. Keogh. The UEA multivariate time series classification archive, 2018. CoRR, abs/1811.00075, 2018.
+[3] Yanping Chen, Eamonn Keogh, Bing Hu, Nurjahan Begum, Anthony Bagnall, Abdullah Mueen, and Gustavo Batista. The ucr time series classification archive, July 2015. www.cs.ucr.edu/\~eamonn/time_series_data/.
+[4] Zhicheng Cui, Wenlin Chen, and Yixin Chen. Multi-scale convolutional neural networks for time series classification. arXiv preprint arXiv:1603.06995, 2016.
+[5] Hoang Anh Dau, Anthony Bagnall, Kaveh Kamgar, Chin-Chia Michael Yeh, Yan Zhu, Shaghayegh Gharghabi, Chotirat Ann Ratanamahatana, and Eamonn Keogh. The ucr time series archive. IEEE/CAA Journal of Automatica Sinica, 6(6):1293-1305, 2019.
+[6] Hoang Anh Dau, Eamonn Keogh, Kaveh Kamgar, Chin-Chia Michael Yeh, Yan Zhu, Shaghayegh Gharghabi, Chotirat Ann Ratanamahatana, Yanping, Bing Hu, Nurjahan Begum, Anthony Bagnall, Abdul-lah Mueen, Gustavo Batista, and Hexagon-ML. The ucr time series classification archive, October 2018. https://www.cs.ucr.edu/\~eamonn/time_series_data_2018/.
+[7] Angus Dempster, François Petitjean, and Geoffrey I Webb. Rocket: exceptionally fast and accurate time series classification using random convolutional kernels. Data Mining and Knowledge Discovery, 34(5):1454-1495, 2020.
+
+[8] Angus Dempster, François Petitjean, and Geoffrey I. Webb. ROCKET: exceptionally fast and accurate time series classification using random convolutional kernels. Data Min. Knowl. Discov., 34(5):1454-1495, 2020.
+[9] Angus Dempster, Daniel F. Schmidt, and Geoffrey I. Webb. Minirocket: A very fast (almost) deterministic transform for time series classification. In KDD '21: The 27th ACM SIGKDD Conference on Knowledge Discovery and Data Mining, pages 248-257, 2021.
+[10] Tim Dettmers and Luke Zettlemoyer. Sparse networks from scratch: Faster training without losing performance. arXiv preprint arXiv:1907.04840, 2019.
+[11] Tim Dettmers and Luke Zettlemoyer. Sparse networks from scratch: Faster training without losing performance. CoRR, abs/1907.04840, 2019.
+[12] Dheeru Dua and Casey Graff. UCI machine learning repository, 2017.
+[13] Utku Evci, Trevor Gale, Jacob Menick, Pablo Samuel Castro, and Erich Elsen. Rigging the lottery: Making all tickets winners. In Proceedings of the 37th International Conference on Machine Learning, volume 119, pages 2943-2952. PMLR, 2020.
+[14] Hassan Ismail Fawaz, Germain Forestier, Jonathan Weber, Lhassane Idoumghar, and Pierre-Alain Muller. Deep learning for time series classification: a review. Data Min. Knowl. Discov., 33(4):917-963, 2019.
+[15] Hassan Ismail Fawaz, Germain Forestier, Jonathan Weber, Lhassane Idoumghar, and Pierre-Alain Muller. Deep neural network ensembles for time series classification. In 2019 International Joint Conference on Neural Networks (IJCNN), pages 1-6. IEEE, 2019.
+[16] Germain Forestier, François Petitjean, Pavel Senin, Fabien Despinoy, Arnaud Huaulme, Hassan Ismail Fawaz, Jonathan Weber, Lhassane Idoumghar, Pierre-Alain Muller, and Pierre Jannin. Surgical motion analysis using discriminative interpretable patterns. Artificial intelligence in medicine, 91:3-11, 2018.
+[17] Jean-Yves Franceschi, Aymeric Dieuleveut, and Martin Jaggi. Unsupervised scalable representation learning for multivariate time series. Advances in neural information processing systems, 32, 2019.
+[18] Jonathan Frankle and Michael Carbin. The lottery ticket hypothesis: Finding sparse, trainable neural networks. In International Conference on Learning Representations, 2018.
+[19] Sharath Girish, Shishira R. Maiya, Kamal Gupta, Hao Chen, Larry S. Davis, and Abhinav Shrivastava. The lottery ticket hypothesis for object recognition. In IEEE Conference on Computer Vision and Pattern Recognition, pages 762-771, 2021.
+[20] Shizhong Han, Zibo Meng, Zhiyuan Li, James O'Reilly, Jie Cai, Xiaofeng Wang, and Yan Tong. Optimizing filter size in convolutional neural networks for facial action unit recognition. In 2018 IEEE Conference on Computer Vision and Pattern Recognition, CVPR 2018, pages 5070-5078, 2018.
+[21] Jon Hills, Jason Lines, Edgaras Baranauskas, James Mapp, and Anthony J. Bagnall. Classification of time series by shapelet transformation. Data Min. Knowl. Discov., 28(4):851-881, 2014.
+[22] Torsten Hoefler, Dan Alistarh, Tal Ben-Nun, Nikoli Dryden, and Alexandra Peste. Sparsity in deep learning: Pruning and growth for efficient inference and training in neural networks. J. Mach. Learn. Res., 22(1), jan 2021.
+[23] Seth H Huang, Xu Lingjie, and Jiang Congwei. Residual attention net for superior cross-domain time sequence modeling. arXiv preprint arXiv:2001.04077, 2020.
+[24] Hassan Ismail Fawaz, Germain Forestier, Jonathan Weber, François Petitjean, Lhassane Idoumghar, and Pierre-Alain Muller. Automatic alignment of surgical videos using kinematic data. In Conference on Artificial Intelligence in Medicine in Europe, pages 104-113. Springer, 2019.
+[25] Hassan Ismail Fawaz, Benjamin Lucas, Germain Forestier, Charlotte Pelletier, Daniel F Schmidt, Jonathan Weber, Geoffrey I Webb, Lhassane Idoumghar, Pierre-Alain Muller, and François Petitjean. Inceptiontime: Finding alexnet for time series classification. Data Mining and Knowledge Discovery, 34(6):1936-1962, 2020.
+[26] Fazle Karim, Somshubra Majumdar, Houshang Darabi, and Samuel Harford. Multivariate LSTM-fcts for time series classification. Neural Networks, 116:237-245, 2019.
+[27] Aditya Kusupati, Vivek Ramanujan, Raghav Somani, Mitchell Wortsman, Prateek Jain, Sham M. Kakade, and Ali Farhadi. Soft threshold weight reparameterization for learnable sparsity. In Proceedings of the 37th International Conference on Machine Learning, ICML 2020, volume 119, pages 5544-5555, 2020.
+[28] Martin Längkvist, Lars Karlsson, and Amy Loutfi. A review of unsupervised feature learning and deep learning for time-series modeling. Pattern Recognition Letters, 42:11-24, 2014.
+[29] Dongha Lee, Seonghyeon Lee, and Hwanjo Yu. Learnable dynamic temporal pooling for time series classification. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pages 8288-8296, 2021.
+
+[30] Namhoon Lee, Thalaiyasingam Ajanthan, and Philip H. S. Torr. Snip: single-shot network pruning based on connection sensitivity. In 7th International Conference on Learning Representations, ICLR 2019, 2019.
+[31] Jason Lines, Luke M Davis, Jon Hills, and Anthony Bagnall. A shapelet transform for time series classification. In Proceedings of the 18th ACM SIGKDD international conference on Knowledge discovery and data mining, pages 289-297, 2012.
+[32] Shiwei Liu. Sparse Neural Network Training with In-Time Over-Parameterization. PhD thesis, Mathematics and Computer Science, April 2022. Proofschrift.
+[33] Shiwei Liu, Tianlong Chen, Xiaohan Chen, Zahra Atashgahi, Lu Yin, Huanyu Kou, Li Shen, Mykola Pechenizkiy, Zhangyang Wang, and Decebal Constantin Mocanu. Sparse training via boosting pruning plasticity with neuroregeneration. Advances in Neural Information Processing Systems, 34, 2021.
+[34] Shiwei Liu, Decebal Constantin Mocanu, Yulong Pei, and Mykola Pechenizkiy. Selfish sparse RNN training. In Marina Meila and Tong Zhang, editors, Proceedings of the 38th International Conference on Machine Learning, ICML, volume 139, pages 6893-6904. PMLR, 2021.
+[35] Shiwei Liu, Lu Yin, Decebal Constantin Mocanu, and Mykola Pechenizkiy. Do we actually need dense over-parameterization? in-time over-parameterization in sparse training. In International Conference on Machine Learning, pages 6989-7000. PMLR, 2021.
+[36] Benjamin Lucas, Ahmed Shifaz, Charlotte Pelletier, Lachlan O'Neill, Nayyar Abbas Zaidi, Bart Goethals, François Petitjean, and Geoffrey I. Webb. Proximity forest: an effective and scalable distance-based classifier for time series. Data Min. Knowl. Discov., 33(3):607-635, 2019.
+[37] Matthew Middlehurst, James Large, Michael Flynn, Jason Lines, Aaron Bostrom, and Anthony Bagnall. Hive-cote 2.0: a new meta ensemble for time series classification. Machine Learning, 110(11):3211-3243, 2021.
+[38] Decebal Constantin Mocanu, Elena Mocanu, Phuong H Nguyen, Madeleine Gibescu, and Antonio Liotta. A topological insight into restricted boltzmann machines. Machine Learning, 104(2):243-270, 2016.
+[39] Decebal Constantin Mocanu, Elena Mocanu, Tiago Pinto, Selima Curci, Phuong H. Nguyen, Madeleine Gibescu, Damien Ernst, and Zita A. Vale. Sparse training theory for scalable and efficient agents. In Proceedings of the 20th International Conference on Autonomous Agents and MultiAgent Systems, page 34–38, Richland, SC, 2021. International Foundation for Autonomous Agents and Multiagent Systems.
+[40] Decebal Constantin Mocanu, Elena Mocanu, Peter Stone, Phuong H Nguyen, Madeleine Gibescu, and Antonio Liotta. Scalable training of artificial neural networks with adaptive sparse connectivity inspired by network science. Nature Communications, 9(1):1-12, 2018.
+[41] Elena Mocanu, Decebal Constantin Mocanu, Phuong H Nguyen, Antonio Liotta, Michael E Webber, Madeleine Gibescu, and Johannes G Slootweg. On-line building energy optimization using deep reinforcement learning. IEEE Transactions on Smart Grid, 10(4):3698-3708, 2018.
+[42] Kewei Ouyang, Yi Hou, Shilin Zhou, and Ye Zhang. Convolutional neural network with an elastic matching mechanism for time series classification. Algorithms, 14(7):192, 2021.
+[43] Charlotte Pelletier, Geoffrey I Webb, and François Petitjean. Temporal convolutional neural network for the classification of satellite image time series. Remote Sensing, 11(5):523, 2019.
+[44] Silvia L. Pintea, Nergis Tomen, Stanley F. Goes, Marco Loog, and Jan C. van Gemert. Resolution learning in deep convolutional networks using scale-space theory. IEEE Trans. Image Process., 30:8342-8353, 2021.
+[45] Elahe Rahimian, Soheil Zabihi, Seyed Farokh Atashzar, Amir Asif, and Arash Mohammadi. Xceptiontime: Independent time-window xceptiontime architecture for hand gesture classification. In ICASSP 2020 - 2020 IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP), pages 1304-1308, 2020.
+[46] Thanawin Rakthanmanon, Bilson Campana, Abdullah Mueen, Gustavo Batista, Brandon Westover, Qiang Zhu, Jesin Zakaria, and Eamonn Keogh. Searching and mining trillions of time series subsequences under dynamic time warping. In Proceedings of the 18th ACM SIGKDD international conference on Knowledge discovery and data mining, pages 262-270, 2012.
+[47] Patrick Schäfer. The boss is concerned with time series classification in the presence of noise. Data Mining and Knowledge Discovery, 29(6):1505-1530, 2015.
+[48] Jonathan Schwarz, Siddhant M. Jayakumar, Razvan Pascanu, Peter E. Latham, and Yee Teh. Powerpropagation: A sparsity inducing weight reparameterisation. In Advances in Neural Information Processing Systems 34: Annual Conference on Neural Information Processing Systems 2021, NeurIPS 2021, pages 28889-28903, 2021.
+[49] Ghada Sokar, Elena Mocanu, Decebal Constantin Mocanu, Mykola Pechenizkiy, and Peterk Stone. Dynamic sparse training for deep reinforcement learning. In 31st International Joint Conference on Artificial Intelligence and the 23rd European Conference on Artificial Intelligence, 2022.
+
+[50] Domen Tabernik, Matej Kristan, and Ales Leonardis. Spatially-adaptive filter units for compact and efficient deep neural networks. Int. J. Comput. Vis., 128(8):2049-2067, 2020.
+[51] Hidenori Tanaka, Daniel Kunin, Daniel L Yamins, and Surya Ganguli. Pruning neural networks without any data by iteratively conserving synaptic flow. Advances in Neural Information Processing Systems, 33:6377-6389, 2020.
+[52] Wensi Tang, Guodong Long, Lu Liu, Tianyi Zhou, Michael Blumenstein, and Jing Jiang. Omni-scale cnns: a simple and effective kernel size configuration for time series classification. In International Conference on Learning Representations, 2022.
+[53] Wensi Tang, Guodong Long, Lu Liu, Tianyi Zhou, Jing Jiang, and Michael Blumenstein. Rethinking 1d-cnn for time series classification: A stronger baseline. arXiv preprint arXiv:2002.10061, 2020.
+[54] Nergis Tomen, Silvia-Laura Pintea, and Jan van Gemert. Deep continuous networks. In Proceedings of the 38th International Conference on Machine Learning, ICML 2021, volume 139, pages 10324-10335, 2021.
+[55] Chaoqi Wang, Guodong Zhang, and Roger Grosse. Picking winning tickets before training by preserving gradient flow. In International Conference on Learning Representations, 2019.
+[56] Zhiguang Wang, Weizhong Yan, and Tim Oates. Time series classification from scratch with deep neural networks: A strong baseline. In 2017 International Joint Conference on Neural Networks (IJCNN), pages 1578-1585. IEEE, 2017.
+[57] Zhitong Xiong, Yuan Yuan, Nianhui Guo, and Qi Wang. Variational context-deformable convnets for indoor scene parsing. In 2020 IEEE/CVF Conference on Computer Vision and Pattern Recognition, CVPR 2020, pages 3991-4001. Computer Vision Foundation / IEEE, 2020.
+[58] Fei Yi, Zhiwen Yu, Fuzhen Zhuang, Xiao Zhang, and Hui Xiong. An integrated model for crime prediction using temporal and spatial factors. In 2018 IEEE International Conference on Data Mining (ICDM), pages 1386-1391. IEEE, 2018.
+[59] Fisher Yu and Vladlen Koltun. Multi-scale context aggregation by dilated convolutions. In International Conference on Learning Representations (ICLR), May 2016.
+[60] Geng Yuan, Xiaolong Ma, Wei Niu, Zhengang Li, Zhenglun Kong, Ning Liu, Yifan Gong, Zheng Zhan, Chaoyang He, Qing Jin, et al. Mest: Accurate and fast memory-economic sparse training framework on the edge. Advances in Neural Information Processing Systems, 34, 2021.
+[61] George Zerveas, Srideepika Jayaraman, Dhaval Patel, Anuradha Bhamidipaty, and Carsten Eickhoff. A transformer-based framework for multivariate time series representation learning. In Proceedings of the 27th ACM SIGKDD Conference on Knowledge Discovery & Data Mining, pages 2114–2124, 2021.
+[62] Xuchao Zhang, Yifeng Gao, Jessica Lin, and Chang-Tien Lu. Tapnet: Multivariate time series classification with attentional prototypical network. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 6845-6852, 2020.
+[63] Zhenyu Zhang, Xuxi Chen, Tianlong Chen, and Zhangyang Wang. Efficient lottery ticket finding: Less data is more. In Proceedings of the 38th International Conference on Machine Learning, volume 139, pages 12380–12390. PMLR, 2021.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See Section 5
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] See Section 5
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Section 4.2
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Appendix D
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/images.zip b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..6414f3c1c6f6cbcf44292e5edb2c9f67d54b61c9
--- /dev/null
+++ b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bbf0cb73b4b4d8ebc3dc115bb3213f2f6952eda753bdc1d3cbed2c47e9d53809
+size 453120
diff --git a/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/layout.json b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..54045ef7917a607aaa8553e69a0e0c6e15aed34e
--- /dev/null
+++ b/dynamicsparsenetworkfortimeseriesclassificationlearningwhattosee/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fd166c74967804a7d76d0f11a7be039846f1a34187b4554ed26296ad06d531ba
+size 518212
diff --git a/dynamictensorproductregression/6696092d-15ad-45f1-9942-51812471916f_content_list.json b/dynamictensorproductregression/6696092d-15ad-45f1-9942-51812471916f_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..979c6884968f3b968fa0d1fb523a83d8b73e3673
--- /dev/null
+++ b/dynamictensorproductregression/6696092d-15ad-45f1-9942-51812471916f_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4d78c9b896d38d04afe3a633c8f1638a2b056599b82d55a6c36e0ba40d41c01d
+size 84369
diff --git a/dynamictensorproductregression/6696092d-15ad-45f1-9942-51812471916f_model.json b/dynamictensorproductregression/6696092d-15ad-45f1-9942-51812471916f_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..15870b05ca70da61dcab15964ad9d594158947e8
--- /dev/null
+++ b/dynamictensorproductregression/6696092d-15ad-45f1-9942-51812471916f_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:496de2639aa1d5348a3ca4b9a50a76bdd20a6f2955a83cc3d0d501639b213c1c
+size 112974
diff --git a/dynamictensorproductregression/6696092d-15ad-45f1-9942-51812471916f_origin.pdf b/dynamictensorproductregression/6696092d-15ad-45f1-9942-51812471916f_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..9cb55f713e58476c7f17c8681fbc0718e54c8da2
--- /dev/null
+++ b/dynamictensorproductregression/6696092d-15ad-45f1-9942-51812471916f_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:42910c40e1125e6fcdd791ccb6d132df55bd5cab865b95c0a7e11b1d7291536d
+size 508309
diff --git a/dynamictensorproductregression/full.md b/dynamictensorproductregression/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..c73264e067ad11bc3ea82aee33912797e831df45
--- /dev/null
+++ b/dynamictensorproductregression/full.md
@@ -0,0 +1,396 @@
+# Dynamic Tensor Product Regression
+
+Aravind Reddy*
+
+Zhao Song†
+
+Lichen Zhang†
+
+# Abstract
+
+In this work, we initiate the study of Dynamic Tensor Product Regression. One has matrices $A_{1} \in \mathbb{R}^{n_{1} \times d_{1}}$ , ..., $A_{q} \in \mathbb{R}^{n_{q} \times d_{q}}$ and a label vector $b \in \mathbb{R}^{n_{1} \dots n_{q}}$ , and the goal is to solve the regression problem with the design matrix $A$ being the tensor product of the matrices $A_{1}, A_{2}, \ldots, A_{q}$ i.e. $\min_{x \in \mathbb{R}^{d_{1} \dots d_{q}}} \| (A_{1} \otimes \ldots \otimes A_{q}) x - b \|_{2}$ . At each time step, one matrix $A_{i}$ receives a sparse change, and the goal is to maintain a sketch of the tensor product $A_{1} \otimes \ldots \otimes A_{q}$ so that the regression solution can be updated quickly. Recomputing the solution from scratch for each round is very slow and so it is important to develop algorithms which can quickly update the solution with the new design matrix. Our main result is a dynamic tree data structure where any update to a single matrix can be propagated quickly throughout the tree. We show that our data structure can be used to solve dynamic versions of not only Tensor Product Regression, but also Tensor Product Spline regression (which is a generalization of ridge regression) and for maintaining Low Rank Approximations for the tensor product.
+
+# 1 Introduction
+
+The task of fitting data points to a line is well-known as the least-squares regression problem [Sti81], which has a wide range of applications in signal processing [RGly78], convex optimization [Bub15], network routing [Mad13, Mad16], and training neural networks [BPSW21, SZZ21]. In this work, we study a generalized version of least-squares regression where the design matrix $A$ is a tensor product of $q$ smaller matrices $A_{1} \otimes A_{2} \otimes \ldots \otimes A_{q}$ .
+
+Tensor products have been extensively studied in mathematics and the physical sciences since their introduction more than a century ago by Whitehead and Russell in their Principia Mathematica [WR12]. They have been shown to have a humongous number of applications in several areas of mathematics like applied linear algebra and statistics [VL00]. In particular, machine learning applications include image processing [NK06], multivariate data fitting [GVL13], and natural language processing [PSA21]. Furthermore, regression problems involving tensor products arise in surface fitting and multidimensional density smoothing [EM06], and structured blind deconvolution problems [OY05], among several other applications, as discussed in [DSSW18, $\mathrm{DJS}^{+}19$ ].
+
+Solving tensor product regression in $\ell_2$ norm [DJS+19, FFG22] to a $(1\pm \varepsilon)$ precision takes time $\widetilde{O} (\sum_{i = 1}^{q}\mathrm{nnz}(A_i) + \mathrm{poly}(dq / (\delta \varepsilon)))$ , where each matrix $A_{i}\in \mathbb{R}^{n_{i}\times d_{i}}$ and $d = d_{1}d_{2}\ldots d_{q}$ , and $\mathrm{nnz}(A)$ denotes the number of nonzero entries of $A$ . However, these algorithms are inherently static, meaning that even if there is a sparse (or low-rank) update to a single design matrix $A_{i}$ , it needs to completely recompute the new solution from scratch. In modern machine learning applications, such static algorithms are not practical due to the fact that data points are always evolving and recomputing the solution from scratch every time is computationally too expensive. Hence, it is important to develop efficient dynamic algorithms that can adaptively update the solution. For example, graphs for real-world network data are modeled as the tensor product of a large number of
+
+smaller graphs $\left[\mathrm{LCK}^{+}10\right]$ . Many important problems on these graphs can be solved by regression of the adjacency and Laplacian matrices of these graphs [ST04]. Real-world network data is always time-evolving and so it is crucial to develop dynamic algorithms for solving regression problems where the design matrix is a tensor product of a large number of smaller matrices. Hence, we ask the following question:
+
+Can we design a dynamic data structure for tensor product regression that can handle updates to the design matrix and quickly updates the solution?
+
+We provide a positive answer to the above question.
+
+At the heart of our data structure is a binary tree that can maintain a succinct sketch of $A_{1} \otimes \ldots \otimes A_{q}$ and supports an update to one of the matrices quickly. Such tree structures have been useful in designing efficient sketching algorithms for tensor products of vectors [AKK+20, SWYZ21]. However, the goal of these works has been in reducing the sketching dimension from an exponential dependence on $q$ to a polynomial dependence on $q$ . Their results can be directly generalized to solving tensor product regression statically but not dynamically. In this work, we build upon the tree structure to solve the Dynamic Tensor Product Regression problem and other related dynamic problems like Dynamic Tensor Spline Regression and Dynamic Tensor Low Rank Approximation. Our key observation is that updating the entire tree is efficient when a single leaf of the tree gets an update: specifically, we only need to update the nodes which fall on the path from the leaf to the root.
+
+# Technical Contributions.
+
+- We design a dynamic tree data structure DYNAMIC TENSORTREE that maintains a succinct representation of the tensor product $A_{1} \otimes \ldots \otimes A_{q}$ and supports efficient updates to any of the $A_{i}$ 's.
+- Consequently, we develop a dynamic algorithm for solving Tensor Product Regression, when one of the matrices $A_{i}$ 's is updated and we need to output an estimate of the new solution to the regression problem quickly.
+- We also show that we can use our DYNAMIC TENSORTREE data-structure in a fast dynamic algorithm to solve the Tensor Product Spline Regression problem, which is a generalization of the classic Ridge Regression problem.
+- We also initiate the study of Dynamic Tensor Low Rank Approximation, where the goal is to maintain a low rank approximation (LRA) of the tensor product with dynamic updates, and show how we can use our DYNAMICTENSORTREE data structure to solve this problem.
+
+Roadmap. In section 2, we first discuss some related work. Then, we provide notation, some background for our work, and the main problem formulation in section 3. In section 4, we provide a technical overview of our paper. Following that, we provide our dynamic tree data structure in section 5. We then show how it can be used for Dynamic Tensor Product Regression, Dynamic Tensor Spline Regression, and Dynamic Tensor Low Rank Approximation in section 6. We end with our conclusion and discuss some future directions in section 7.
+
+# 2 Related Work
+
+Sketching. Sketching techniques have many applications in numerical linear algebra, such as linear regression, low-rank approximation [CW13, NN13, MM13, BW14, RSW16, SWZ17, HLW17, $\mathrm{ALS}^{+}18$ , $\mathrm{BBB}^{+}19$ , IVWW19, SWZ19a, SWZ19b, MW21, WY22, CSTZ22], distributed problems [WZ16, BWZ16], reinforcement learning [WZD $^{+}20$ , SSX21], projected gradient descent [XSS21], training over-parameterized neural networks [SYZ21, SZZ21], tensor decomposition [SWZ19c], clustering [EMZ21], cutting plane method [JLSW20], generative adversarial networks [XZZ18], recommender systems [RRS $^{+}22$ ], and linear programming [LSZ19, JSWZ21, SY21].
+
+Dynamic Least-squares Regression. A dynamic version of the ordinary least-squares regression problem (without a tensor product design matrix) was recently studied in [JPW22]. In their model, at each iteration, a new row is prepended to the design matrix $A$ and a new coordinate is prepended
+
+to the vector $b$ . To efficiently maintain the necessary parts of the design matrix and the solution, they make use of a fast leverage score maintenance data structure by [CMP20] and achieve a running time of $\widetilde{O}(\mathrm{nnz}(A^{(T)}) + \mathrm{poly}(d, \varepsilon^{-1}))$ where $T$ is the number of time steps.
+
+Tensor/Kronecker Product Problems. Many machine learning problems involve tensor/Kronecker product computations such as, regression [HLW17, DSSW18, $\mathrm{DJS}^{+}19$ ], low-rank approximation [SWZ19c], fast kernel computation [SWYZ21], semi-definite programming $\left[\mathrm{JKL}^{+}20,\mathrm{HJS}^{+}21\right]$ , and training over-parameterized neural networks [BPSW21, SZZ21]. Apart from solving problems which directly involve tensor/Kronecker products, another line of research focuses on constructing polynomial kernels efficiently so that the computation of various kernel problems can be improved $\left[\mathrm{AKK}^{+}20,\mathrm{SWYZ}21\right]$ .
+
+# 3 Preliminaries
+
+# 3.1 Notation
+
+For any natural number $n$ , we use $[n]$ to denote the set $\{1, 2, \ldots, n\}$ . We use $\mathbb{E}[\cdot]$ to denote expectation of a random variable if it exists. We use $\mathbf{1}[\cdot]$ and $\operatorname{Pr}[\cdot]$ to denote the indicator function and probability of an event respectively. For any natural numbers $a, b, c$ , we use $\mathcal{T}_{\mathrm{mat}}(a, b, c)$ to denote the time it takes to multiply two matrices of sizes $a \times b$ and $b \times c$ . For a vector $x$ , we use $\|x\|_2$ to denote its $\ell_2$ norm. For a matrix $A$ , we use $\|A\|_F$ to denote its Frobenius norm. For a matrix $A$ , we use $A^\top$ to denote the transpose of $A$ . Given two matrices $A \in \mathbb{R}^{n_1 \times d_1}$ and $B \in \mathbb{R}^{n_2 \times d_2}$ , we use $A \otimes B$ to denote their tensor product (which is also referred to as Kronecker product), i.e., $(A \otimes B)_{i_1 + (i_2 - 1) \cdot n_1, j_1 + (j_2 - 1) \cdot d_1} = A_{i_1, j_1} \cdot B_{i_2, j_2}$ . For example, for $2 \times 2$ matrices $A$ and $B$ ,
+
+$$
+\left[ \begin{array}{c c} a _ {1 1} & a _ {1 2} \\ a _ {2 1} & a _ {2 2} \end{array} \right] \otimes B = \left[ \begin{array}{c c} a _ {1 1} B & a _ {1 2} B \\ a _ {2 1} B & a _ {2 2} B \end{array} \right] = \left[ \begin{array}{c c c c} a _ {1 1} b _ {1 1} & a _ {1 1} b _ {1 2} & a _ {1 2} b _ {1 1} & a _ {1 2} b _ {1 2} \\ a _ {1 1} b _ {2 1} & a _ {1 1} b _ {2 2} & a _ {1 2} b _ {2 1} & a _ {1 2} b _ {2 2} \\ a _ {2 1} b _ {1 1} & a _ {2 1} b _ {1 2} & a _ {2 2} b _ {1 1} & a _ {2 2} b _ {1 2} \\ a _ {2 1} b _ {2 1} & a _ {2 1} b _ {2 2} & a _ {2 2} b _ {2 1} & a _ {2 2} b _ {2 2} \end{array} \right]
+$$
+
+We use $\otimes$ to denote tensor product of more than two matrices, i.e., $\bigotimes_{i=1}^{q} A_i = A_1 \otimes A_2 \otimes \dots \otimes A_q$ . For non-negative real numbers $a$ and $b$ , we use $a = (1 \pm \varepsilon)b$ to denote $(1 - \varepsilon) \cdot b \leq a \leq (1 + \varepsilon) \cdot b$ . For a real matrix $A$ , we use $\sigma_i(A)$ to denote its $i$ -th largest singular value. For any function $f$ , we use $\widetilde{O}(f)$ to denote $O(f \mathrm{poly}(\log f))$ .
+
+# 3.2 Problem Formulation
+
+In this section, we define our task. We start with the static version of tensor product regression.
+
+Definition 3.1 (Static version). In the $\ell_2$ Tensor Product Regression problem, we are given matrices $A_{1}, A_{2}, \ldots, A_{q}$ where $A_{i} \in \mathbb{R}^{n_{i} \times d_{i}}$ and $b \in \mathbb{R}^{n_{1} n_{2} \dots n_{q}}$ . Let us define $n := n_{1} n_{2} \dots n_{q}$ and $d := d_{1} d_{2} \dots d_{q}$ . The goal is to output $x \in \mathbb{R}^{d}$ such that we minimize the objective:
+
+$$
+\left\| \left(A _ {1} \otimes A _ {2} \otimes \dots \otimes A _ {q}\right) x - b \right\| _ {2}
+$$
+
+Our dynamic version of $\ell_2$ Tensor Product Regression involves updating one of the matrices $A_{i}$ with an update matrix $B$ . We formally define the problem as follows:
+
+Definition 3.2 (Dynamic version). In the Dynamic $\ell_2$ Tensor Product Regression problem, we are given matrices $A_{1}, A_{2}, \ldots, A_{q}$ where $A_{i} \in \mathbb{R}^{n_{i} \times d_{i}}$ , a sequence $\{(i_{1}, B_{1}), (i_{2}, B_{2}), \ldots, (i_{T}, B_{T})\}$ with $i_{t} \in [q], B_{t} \in \mathbb{R}^{n_{it} \times d_{it}}$ for all $t \in [T]$ , and the goal is to design a data structure with the following procedures:
+
+- INITIALIZIZE: The data structure initializes $A_{1}, \ldots, A_{q}$ and maintains an approximation to $\bigotimes_{i=1}^{q} A_{i}$ .
+- UPDATE: At time step $t$ , given an index $i_t$ and an update matrix $B_t$ , the data-structure needs to update $A_{i_t} \gets A_{i_t} + B_t$ , and maintain an approximation to $A_1 \otimes \ldots \otimes (A_{i_t} + B_t) \otimes \ldots \otimes A_q$ .
+
+- QUERY: The data structure outputs a vector $\widehat{x} \in \mathbb{R}^d$ such that
+
+$$
+\| (\bigotimes_ {i = 1} ^ {q} A _ {i}) \widehat {x} - b \| _ {2} = (1 \pm \varepsilon) \min _ {x \in \mathbb {R} ^ {d}} \| (\bigotimes_ {i = 1} ^ {q} A _ {i}) x - b \| _ {2}.
+$$
+
+Note that although we don't discuss updates to the vector $b$ in our model, they are easy to implement in our data-structure. In addition to the standard regression problem, we also consider the spline regression (which is a generalization of ridge regression) and low rank approximation problems. We will provide the definitions for these problems in their respective sections.
+
+# 4 Technical Overview
+
+The two main design considerations for our data structure are as follows: 1). We want a data structure that stores a sketch of the tensor product, this has the advantage of having a smaller storage space and a faster time to form the tensor product. 2). The update time to one of the matrices $A_{i}$ should be fast, ideally we want to remove the linear dependence on $q$ . With these two goals in mind, we introduce a dynamic tree data structure that satisfies both of them simultaneously, building on the sketch of [AKK+20]. Specifically, we use each leaf of the tree to represent $S_{i}A_{i}$ , a sketch of the base matrix that only has $m$ rows instead of $n$ rows, where $m$ is proportional to the small dimension $d$ . Each internal node represents a sketch of the Tensor product of its two children. To speed up computation, we adapt tensor-typed sketching matrices to avoid the need to explicitly form the Tensor product of the two children. The root of the tree will store a sketch for the tensor product $\bigotimes_{i=1}^{q} A_{i}$ .
+
+We point out that in order for this tree to work, we need to apply an independent sketching matrix to each tree node. Since there are $2q - 1$ nodes in total, we will still have a dependence on $q$ in the initialization phase (which will be dominated by the $d$ term). However, during the update phase, our tree has a clear advantage: if one of the leaves has been updated, we only need to propagate the change along the path to root. Since the height of the tree is at most $O(\log q)$ , we remove the linear dependence on $q$ in the update phase. This is the key insight for obtaining a faster update time using our dynamic data structure. Moreover, the correctness follows naturally from the guarantee of the tree: as shown in $[\mathrm{AKK}^{+}20]$ , the tree itself is an Oblivious Subspace Embedding (OSE) for matrices of proper size, hence, it also preserves the subspace after updating one of the leaves. Figure 1 is an example tree for tensor product of 4 matrices.
+
+
+Figure 1: A tree for sketching the tensor product of 4 matrices $A_{1}, A_{2}, A_{3}$ and $A_{4}$ . The leaves use sketches of type $T_{\mathrm{base}}$ and internal nodes use sketches of type $S_{\mathrm{base}}$ . The algorithm starts to apply $T_{i}$ to each matrix $A_{i}$ , and then propagates them up the tree.
+
+With this data structure, we provide efficient algorithms for dynamic Tensor product regression, dynamic Tensor Spline regression, and dynamic Tensor low rank approximation. For all these problems, we do not explicitly maintain the solutions, rather, we use our tree to quickly update a sketch of the design matrix. In the query phase (when we need to actually solve the regression problems), we use this sketch of updated design matrix to quickly compute the solution.
+
+# 5 Dynamic Tree Data Structure
+
+In this section, we introduce our data structure, which contains INITIALIZE and UPDATE procedures. We'll define task-specific QUERY procedures later. We defer proofs in this section to Appendix B. We start with an outline of Algorithm 1.
+
+Algorithm 1 Our dynamic tree data structure
+1: data structure DYNAMICTENSORTREE $\triangleright$ Theorem 5.1
+2:
+3: members
+4: $J_{k,\ell}\in \mathbb{R}^{m\times d^2\ell}$ for $0\leq \ell \leq \log q$ and $0\le k\le q / 2^{\ell} - 1$ $\triangleright \ell$ is the level of the tree.
+5: end members
+6:
+7: procedure INITIALIZE $(A_{1}\in \mathbb{R}^{n_{1}\times d_{1}},\dots ,A_{q}\in \mathbb{R}^{n_{q}\times d_{q}},m\in \mathbb{N}_{+},C_{\mathrm{base}},T_{\mathrm{base}})$
+8: for $\ell = 0\rightarrow \log q$ do
+9: for $k = 0\to q / 2^{\ell} - 1$ do
+10: if $\ell = 0$ then
+11: Choose a $C_k\in \mathbb{R}^{m\times n_k}$ from $C_\mathrm{base}$ . $\triangleright C_\mathrm{base}$ can be COUNTSKETCH, SRHT or OSNAP.
+12: $J_{k,\ell}\gets C_kA_k$
+13: else
+14: Choose a $T_{k,\ell}\in \mathbb{R}^{m\times m^2}$ from $T_{\mathrm{base}}$ . $\triangleright T_{\mathrm{base}}$ can be TENSORSKETCH or TENSORSRT.
+15: $J_{k,\ell}\gets T_{k,\ell}(J_{2k,\ell -1}\otimes J_{2k + 1,\ell -1})$ $\triangleright$ Sketch of tensor product of its children
+16: end if
+17: end for
+18: end for
+19: end procedure
+20:
+21: procedure UPDATE(i∈[q],B∈ $\mathbb{R}^{n_i\times d_i}$ )
+22: for $\ell = 0\rightarrow \log (q)$ do
+23: if $\ell = 0$ then
+24: $J_{i,0}^{\mathrm{new}}\gets C_iB$
+25: $J_{i,0}\gets J_{i,0} + J_{i,0}^{\mathrm{new}}$
+26: else
+27: $J_{[i / 2^{\ell}],\ell}^{\mathrm{new}}\gets T_{k,\ell}(J_{[i / 2^{\ell -1}],\ell -1}^{\mathrm{new}}\otimes J_{[i / 2^{\ell -1}] + 1,\ell -1})$ $\triangleright$ Sibling is to the left also sometimes
+28: $J_{[i / 2^{\ell}],\ell}\gets J_{[i / 2^{\ell}],\ell} + J_{[i / 2^{\ell}],\ell}^{\mathrm{new}}$ $\triangleright$ Sketch of tensor product of its children
+29: end if
+30: end for
+31: end procedure
+
+Outline of Tree: For simplicity, let us assume that the number of matrices $q$ is a power of 2. Also, let us assume that all the matrices are of the same dimension $n_1 \times d_1$ . The output is a matrix of dimension $m \times d$ where $m = \mathrm{poly}(q, d, \varepsilon^{-2})$ . First, we apply $q$ independent base sketch matrices (such as COUNTSKETCH (Def. A.6), SRHT (Def. A.8)) $\{T_i \in \mathbb{R}^{m \times n_1}, i \in [q]\}$ to each of the matrices $A_1, A_2, \ldots, A_q$ . After this step, all the leaf nodes are of size $m \times d_1$ . Then, we have a tree of height $\log q$ . Let us use $\ell = 0 \to \log q$ to represent the level of the tree nodes where $\ell = 0$ represents the leaves and $\ell = \log q$ represents the root node. Let us use $J_{k,\ell} \in \mathbb{R}^{n \times d^2\ell}$ to denote the matrix stored at the node $k, \ell$ . For leaf nodes, we choose base sketches $T_k \in \mathbb{R}^{m \times n_1}$ and compute $J_{k,0} = T_kA_k$ . At each internal node, we use a sketch for tensor-typed inputs (such as TENSORSKETCH (Def. A.7) or TENSORSRHT (Def. A.5)), apply it to its two children. The sketching matrix $S_i \in \mathbb{R}^{m \times m^2}$ , and it can be applied to its two inputs fast, obtaining a running time of $O(m^2)$ . We inductively compute the tree all the way up to the root for initialization. Note that at the root, we end up with a matrix of size $m \times d$ , which is significantly smaller than the tensor product $n \times d$ .
+
+The running time guarantees of Algorithm 1, which we will prove in Appendix B, are as follows:
+
+Theorem 5.1 (Running time of our main result. Informal version of Theorem B.1). There is an algorithm (Algorithm 1) that has the following procedures:
+
+- INITIALIZER $(A_{1} \in \mathbb{R}^{n_{1} \times d_{1}}, A_{2} \in \mathbb{R}^{n_{2} \times d_{2}}, \ldots, A_{q} \in \mathbb{R}^{n_{q} \times d_{q}}, m \in \mathbb{N}_{+}, C_{\mathrm{base}}, T_{\mathrm{base}})$ : Given matrices $A_{1} \in \mathbb{R}^{n_{1} \times d_{1}}, A_{2} \in \mathbb{R}^{n_{2} \times d_{2}}, \ldots, A_{q} \in \mathbb{R}^{n_{q} \times d_{q}}$ , a sketching dimension $m$ , families of base sketches $C_{\mathrm{base}}$ and $T_{\mathrm{base}}$ , the data-structure pre-processes in time $\widetilde{O}\left(\sum_{i=1}^{q} \mathrm{nmz}(A_{i}) + qmd\right)$ .
+- UPDATE $(i \in [q], B \in \mathbb{R}^{n_i \times d_i})$ : Given a matrix $B$ and an index $i \in [q]$ , the data structure updates the approximation to $A_1 \otimes \ldots \otimes (A_i + B) \otimes \ldots \otimes A_q$ in time $\widetilde{O}(\mathrm{nmz}(B) + md)$ .
+
+Remark 5.2. In our data structure, we only pay the linear $q$ term in INITIALIZATION (which will be dominated by the term $d$ ), since we are maintaining a tree with $2q - 1$ nodes, each node corresponds to a matrix of $m$ rows. In the UPDATE phase, we shave off the linear dependence on $q$ . We also want to point out that the sketching dimension $m$ is typically at least linear on $q$ , however, it only depends on $q$ , the small dimension $d$ and the precision parameter $\varepsilon$ , hence it is far more efficient to use this sketch representation compared to the original tensor product. Also, note that though we only design a data structure for $q$ being a power of 2, it is not hard to generalize to $q$ being an arbitrary positive integer via the technique introduced in [SWYZ21]. We only incur a log $q$ factor by doing so.
+
+The approximation guarantee for our dynamic tree, which follows from $\mathrm{[AKK^{+}20]}$ and for which we provide a brief sketch in Appendix B are as follows:
+
+Theorem 5.3 (Approximation guarantee of our dynamic tree. Informal version of Theorem B.1). Let $\Pi^q$ denote the sketching matrix generated by the dynamic tree, we then have that:
+
+$$
+\| \Pi^ {q} (\bigotimes_ {i = 1} ^ {q} A _ {i}) x \| _ {2} = (1 \pm \varepsilon) \| (\bigotimes_ {i = 1} ^ {q} A _ {i}) x \| _ {2}.
+$$
+
+Choices of parameter $m$ : An important parameter to be chosen is the sketching dimension $m$ . Intuitively, it should depend polynomially on $\varepsilon^{-1}, d, q$ . We list them in the following table.
+
+| Cbase | Tbase | m(dim) | Init time |
| COUNTSKETCH | TENSORSKETCH | ε-2q·dim2·(1/δ) | ∑i=1qnnz(Ai) |
| OSNAP | TENSORSRHT | ε-2q4·dim·log(1/δ) | ∑i=1qnnz(Ai) |
| OSNAP | TENSORSRHT | ε-2q·dim2·log(1/δ) | ∑i=1qnnz(Ai) |
+
+Table 1: How different choices of $C_{\mathrm{base}}$ and $T_{\mathrm{base}}$ affect the sketching dimension $m(\dim)$ and initialization time that depends on the choice of sketch. We note that the sketching dimension $m$ is a function of $\dim$ , the fundamental dimension of the problem. For example, $\dim = d$ for tensor product regression and $\dim = k$ for $k$ -low rank approximation. The sketching dimension corresponds to the problem of computing an $(\varepsilon, \delta, \dim, d, n)$ -OSE.
+
+Robustness against an Adaptive Adversary: An often encountered issue in dynamic algorithms is the presence of an adaptive adversary $\left[\mathrm{BKM}^{+}22\right]$ . Consider a sequence of update pairs $\{(i,B_i)\}_{i=1}^T$ in which the adversary can choose the pair $(i,B_i)$ based on the output of our data structure on $(i-1,B_{i-1})$ . Such an adversary model naturally captures many applications, in which the data structure is used in an iterative process, and the input to the data structure depends on the output from last iteration.
+
+We will now describe how our data structure can be extended to handle an adaptive adversary. We store all initial factor matrices $A_{1}, \ldots, A_{q}$ . During an update, suppose we are given a pair $(i, B_{i})$ . Instead of using the sketching matrices correspond to the $i$ -th leaf during initialization, we instead choose fresh sketching matrices along the path from the leaf to the root. Since the only randomness being used is the sketching matrices along the path, by using fresh randomness, our data structure works against adaptive adversary.
+
+Such modification does not affect the update time too much: during each update, we need to apply the newly-generated base sketch $C_i^{\mathrm{new}}$ to both $A_i$ and $B$ , incurring a time of $\widetilde{O}(\mathrm{nnz}(A_i) + \mathrm{nnz}(B))$ . Along the path, the data structure repeatedly apply $T_{k,\ell}^{\mathrm{new}}$ to its two children, which takes $\widetilde{O}(md)$ time. The overall time is thus
+
+$$
+\widetilde {O} (\mathrm {n n z} (A _ {i}) + \mathrm {n n z} (B) + m d).
+$$
+
+Thus, in later applications of our data structure, we present the runtime without this modification.
+
+# 6 Faster Dynamic Tensor Product Algorithms with Dynamic Tree
+
+In this section, we instantiate the dynamic tree data structure introduced in section 5 for three applications: dynamic tensor product regression, dynamic tensor spline regression, and dynamic tensor low rank approximation.
+
+# 6.1 Dynamic Tensor Product Regression
+
+We present an algorithm (Algorithm. 2) for solving the dynamic Tensor product regression problem. Our algorithm uses the dynamic tree data structure to maintain a sketch of the design matrix and updates it efficiently. Additionally, we maintain a sketch of the label vector $b$ via $\Pi^q b$ . During the query phase, we output the solution using the sketch of the tensor product design matrix and the sketch of the label vector. We have the following guarantees, the proof of which we defer to Appendix C:
+
+Theorem 6.1 (Informal version of Theorem C.1). There is an algorithm (Algorithm 2) for dynamic Tensor product regression problem with the following procedures:
+
+- INITIALIZE $(A_{1} \in \mathbb{R}^{n_{1} \times d_{1}}, A_{2} \in \mathbb{R}^{n_{2} \times d_{2}}, \ldots, A_{q} \in \mathbb{R}^{n_{q} \times d_{q}}, m \in \mathbb{N}_{+}, C_{\mathrm{base}}, T_{\mathrm{base}}, b \in \mathbb{R}^{n_{1} \cdots n_{q}})$ : Given matrices $A_{1} \in \mathbb{R}^{n_{1} \times d_{1}}, A_{2} \in \mathbb{R}^{n_{2} \times d_{2}}, \ldots, A_{q} \in \mathbb{R}^{n_{q} \times d_{q}}$ , a sketching dimension $m$ , families of base sketches $C_{\mathrm{base}}$ , $T_{\mathrm{base}}$ and a label vector $b \in \mathbb{R}^{n_{1} \cdots n_{q}}$ , the data-structure pre-processes in time $\widetilde{O}(\sum_{i=1}^{q} \mathrm{nnz}(A_{i}) + qmd + m \cdot \mathrm{nnz}(b))$ .
+- UPDATE $(i \in [q], B \in \mathbb{R}^{n_i \times d_i})$ : Given a matrix $B$ and an index $i \in [q]$ , the data structure updates the approximation to $A_1 \otimes \ldots \otimes (A_i + B) \otimes \ldots \otimes A_q$ in time $\widetilde{O}(\mathrm{nnz}(B) + md)$ .
+- QUERY: Query outputs an approximate solution $\widehat{x}$ to the Tensor product regression problem where $\|\bigotimes_{i=1}^{q} A_i \widehat{x} - b\|_2 = (1 \pm \varepsilon)\|\bigotimes_{i=1}^{q} A_i x^* - b\|_2$ with probability at least $1 - \delta$ in time $O(m d^{\omega - 1} + d^{\omega})$ where $x^*$ is an optimal solution to the Tensor product regression problem i.e. $x^* = \arg \min_{x \in \mathbb{R}^d} \|\bigotimes_{i=1}^{q} A_i x - b\|_2$ .
+
+To realize the input sparsity time initialize and update time, we can use the combination of OSNAP and TENSORSRHT, which gives a sketching dimension
+
+$$
+m = \varepsilon^ {- 2} q d ^ {2} \log (1 / \delta).
+$$
+
+Hence, the update time is $\widetilde{O} (\mathrm{nnz}(B) + \varepsilon^{-2}qd^3\log (1 / \delta))$ . Compared to the static algorithm [DJS+19], we note that their algorithm is suitable to be modified into dynamic setting, with a running time of $\widetilde{O} (\mathrm{nnz}(A_i) + \mathrm{nnz}(B) + \varepsilon^{-2}(q + d)d / \delta))$ , their algorithm cannot accommodate general dynamic setting due to the $1 / \delta$ dependence in running time. Suppose the length dynamic sequence is at least $d$ , then one requires the failure probability to be at most $\frac{1}{d}$ for union bound. In such scenario, the algorithm of [DJS+19] is strictly worse. [FFG22] improves the dependence on $d$ , yielding a subquadratic update time in the form of $\widetilde{O} ((\mathrm{nnz}(A_i) + \mathrm{nnz}(B) + \varepsilon^{-2}q^2 d_i^\omega + \varepsilon^{-1}d^{2 - \theta})\log (1 / \delta))$ . While their algorithm is more efficient in solving the regression problem, their approach does not scale with the statistical dimension of the problem, and is geared only towards regression, whereas our data structure also handles low rank approximation.
+
+# 6.2 Dynamic Tensor Spline Regression
+
+Spline regression models are a well studied class of regression models [MC01]. In particular, Spline regression problems involving tensor products arise in the context of B-Splines and P-Splines [EM96]. For a very brief but relevant introduction to Spline regression, we refer the reader to [DSSW18]. In this section, we first define the Spline regression problem as it pertains to our sketching application. Algorithm 3, which shows how we can use our DYNAMIC TENSORTREE data structure to solve a dynamic version of the Spline regression problem is provided in Appendix D.
+
+Definition 6.2 (Spline Regression). In the Spline regression problem, given a design matrix $A \in \mathbb{R}^{m \times n}$ , a target vector $x \in \mathbb{R}^n$ , a regularization matrix $L \in \mathbb{R}^{p \times d}$ , and a non-negative penalty coefficient $\lambda \in \mathbb{R}$ , the goal is to optimize
+
+$$
+\min _ {x \in \mathbb {R} ^ {n}} \| A x - b \| _ {2} ^ {2} + \lambda \cdot \| L x \| _ {2} ^ {2} \tag {1}
+$$
+
+Notice that the classic ridge regression problem is a special case of spline regression (when $L = I$ ). In the TENSOR SPLINE REGRESSION problem, we want to solve the Spline regression problem where the design matrix $A$ can be decomposed as the tensor product of multiple smaller matrices i.e. $A = A_{1}\otimes \dots \otimes A_{q}$ . Our DYNAMIC TENSORTREE data structure can be used to solve a dynamic version of TENSOR SPLINE REGRESSION. In our dynamic model, at each time step, the update is of the form $i\in [q],B\in \mathbb{R}^{n_i\times d_i}$ , and the data structure has to update $A_{i}\gets A_{i} + B$ .
+
+Before introducing our main result, we define an important metric to measure the rank of a Spline regression:
+
+Definition 6.3 (Statistical dimension of Splines). For matrix $A \in \mathbb{R}^{n \times d}$ and $L \in \mathbb{R}^{p \times d}$ with $\operatorname{rank}(L) = p$ and $\operatorname{rank}\left(\begin{bmatrix} A \\ L \end{bmatrix}\right) = d$ . Given the generalized singular value decomposition [GVL13] of $(A, L)$ such that $A = U\left[ \begin{array}{cc} \Sigma & 0_{p \times (n - p)} \\ 0_{(n - p) \times p} & I_{d - p} \end{array} \right] RQ^{\top}, L = V\left[ \begin{array}{cc} \Omega & 0_{p \times (n - p)} \end{array} \right] RQ^{\top}$ , where $\Sigma = \operatorname{diag}(\sigma_1, \ldots, \sigma_p), \Omega = \operatorname{diag}(\mu_1, \ldots, \mu_p) \in \mathbb{R}^{p \times p}$ are diagonal matrices. Finally, let $\gamma_i = \sigma_i / \mu_i$ for $i \in [p]$ .
+
+The statistical dimension of the Spline is defined as $\mathfrak{sd}_{\lambda}(A,L) = \sum_{i = 1}^{p}1 / (1 + \lambda /\gamma_i^2) + d - p$
+
+The statistical dimension of the Spline can be much smaller than $d$ , and we will show that the sketching dimension depends on the statistical dimension instead of $d$ .
+
+Let $x^{*}$ denote an optimal solution of the Spline regression problem, i.e.
+
+$$
+x ^ {*} = \underset {x \in \mathbb {R} ^ {n}} {\arg \min } \| A x - b \| _ {2} ^ {2} + \lambda \cdot \| L x \| _ {2} ^ {2}
+$$
+
+and let OPT $\coloneqq \| Ax^{*} - b\|_{2}^{2} + \lambda \cdot \| Lx^{*}\|_{2}^{2}$ . We can compute $x^{*}$ given $A,b,L,\lambda$ by $x^{*} = (A^{\top}A+$ $\lambda L^{\top}L)^{-1}A^{\top}b$ .
+
+Theorem 6.4 (Guarantees for DTSREGRESSION. Informal version of Theorem D.5). There exists an algorithm (Algorithm 3) with the following procedures:
+
+- INITIALIZER $(A_{1} \in \mathbb{R}^{n_{1} \times d_{1}}, \ldots, A_{q} \in \mathbb{R}^{n_{q} \times d_{q}})$ : Given matrices $A_{1} \in \mathbb{R}^{n_{1} \times d_{1}}, \ldots, A_{q} \in \mathbb{R}^{n_{q} \times d_{q}}$ , the data structure pre-processes in time
+
+$$
+\widetilde {O} \left(\sum_ {i = 1} ^ {q} \mathrm {n n z} \left(A _ {i}\right) + q m d + m \cdot \mathrm {n n z} (b)\right).
+$$
+
+- UPDATE $(i \in [q], B \in \mathbb{R}^{n_i \times d_i})$ : Given an index $i \in [q]$ and an update matrix $B \in \mathbb{R}^{n \times d}$ , the data structure updates in time $\widetilde{O}(\mathrm{nnz}(B) + md)$ .
+- QUERY: Let $A$ denote the tensor product $\bigotimes_{i=1}^{q} A_i$ . Query outputs a solution $\widetilde{x} \in \mathbb{R}^n$ with constant probability such that the $\widetilde{x}$ is an $\varepsilon$ approximate to the Tensor Spline Regression problem i.e.
+
+$$
+\left\| A \widetilde {x} - b \right\| _ {2} ^ {2} + \lambda \cdot \left\| L \widetilde {x} \right\| _ {2} ^ {2} \leq (1 + \varepsilon) \cdot \text {O P T}
+$$
+
+where $\mathrm{OPT} = \min_{x\in \mathbb{R}^n}\| Ax - b\| _2^2 +\lambda \cdot \| Lx\| _2^2$ . Query takes time $md^{(\omega -1)} + pd^{(\omega -1)} + d^{\omega}$
+
+We defer the proof of the above theorem to Appendix D.
+
+The sketching dimension $m$ here depends on the statistical dimension of the Spline, which is at most $d$ . To realize the above runtime, one can pick OSNAP and TENSORSHRT, which gives $m = \varepsilon^{-1}q\mathsf{sd}_{\lambda}^{2}(A,L)\log (1 / \delta)$ and an update time $\widetilde{O} (\mathrm{nnz}(B) + \varepsilon^{-1}q\mathsf{sd}_{\lambda}^{2}(A,L)d\log (1 / \delta))$ . The improved dependence on $\varepsilon^{-1}$ comes from using approximate matrix product directly, instead of OSE.
+
+# 6.3 Dynamic Tensor Low Rank Approximation
+
+In this section, we consider a problem studied in [DJS+19]: given matrices $A_{1},\ldots ,A_{q}$ , the goal is to compute a low rank approximation for the tensor product matrix $A_{1}\otimes \ldots \otimes A_{q}\in \mathbb{R}^{n\times d}$ specifically, a rank- $k$ approximation $B\in \mathbb{R}^{n\times d}$ such that
+
+$$
+\left\| B - A \right\| _ {F} \leq (1 + \varepsilon) \mathrm {O P T} _ {k},
+$$
+
+where $\mathrm{OPT}_k = \min_{\mathrm{rank} - k} A' \| A' - A \|_F$ and $A = \bigotimes_{i=1}^q A_i$ . The [DJS+19] algorithm works as follows: they pick $q$ independent COUNTSKETCH matrices [CCFC02] with $O(\varepsilon^{-2} q k^2)$ rows, then apply each sketch matrix $S_i$ to $A_i$ . After that, they form the tensor product $M = \bigotimes_{i=1}^q S_i A_i$ and run SVD on $M = U \Sigma V^\top$ . Finally, they output $B = A U_k^\top U_k$ in factored form (as matrices $A_1, \ldots, A_q, U_k$ ), where $U_k \in \mathbb{R}^{k \times d}$ denotes the top $k$ right singular vectors. By doing so, they achieve an overall running time of
+
+$$
+O \left(\sum_ {i = 1} ^ {q} \operatorname {n n z} \left(A _ {i}\right) + \varepsilon^ {- 2 q} q ^ {q} k ^ {2 q} d ^ {\omega - 1}\right)
+$$
+
+Two central issues around their algorithm are 1). exponential dependence on parameters $\varepsilon^{-1}, q, k$ and 2). the algorithm is inherently static, so a natural way to make it dynamic is to apply $S_{i}$ to the update $B$ , reforming the tensor product of sketches and compute the SVD.
+
+We address these two issues simultaneously by using our tree data structure. For the sketching dimension, we observe it is enough to design a sketch that is $(\varepsilon, \delta, k, d, n)$ -OSE and $(\varepsilon / k, \delta)$ -approximate matrix product, therefore, we can set sketching dimension $m = \varepsilon^{-2} qk^2 \log(1 / \delta)$ . As we will show later, this gives a much improved running time. By using the dynamic tree, we also provide a dynamic algorithm.
+
+Theorem 6.5 (Guarantees for LOWRANKMAINTENANCE. Informal version of Theorem E.3). There exists an algorithm (Algorithm 4) that has the following procedures
+
+- INITIALIZER $(A_{1} \in \mathbb{R}^{n_{1} \times d_{1}}, \ldots, A_{q} \in \mathbb{R}^{n_{q} \times d_{q}})$ : Given matrices $A_{1} \in \mathbb{R}^{n_{1} \times d}, \ldots, A_{q} \in \mathbb{R}^{n_{q} \times d_{q}}$ , the data structure processes in time
+
+$$
+\widetilde {O} \left(\sum_ {i = 1} ^ {q} \operatorname {n n z} \left(A _ {i}\right) + q m d\right).
+$$
+
+- UPDATE $(i \in [q], B \in \mathbb{R}^{n_i \times d_i})$ : Given an index $i \in [q]$ and an update matrix $B \in \mathbb{R}^{n_i \times d_i}$ , the data structure updates the approximation for $A_1 \otimes \ldots \otimes (A_i + B) \otimes \ldots \otimes A_q$ in time $\widetilde{O}(\mathrm{nnz}(B) + md)$ .
+- QUERY: Let $A$ denote the tensor product $\bigotimes_{i=1}^{q} A_i$ . The data structure outputs a rank- $k$ approximation $C$ such that
+
+$$
+\| C - A \| _ {F} \leq (1 + \varepsilon) \min _ {\text {r a n k -} k A ^ {\prime}} \| A ^ {\prime} - A \| _ {F}.
+$$
+
+The time to output $C$ is $\widetilde{O} (md^{\omega -1})$ .
+
+By choosing $m = \varepsilon^{-2}qk^2\log (1 / \delta)$ , we can provide good guarantees for low rank approximation. This gives
+
+- Initialization time in $\widetilde{O}(\sum_{i=1}^{q} \mathrm{nzz}(A_i) + \varepsilon^{-2} qdk^2 \log(1/\delta))$ ;
+- Update time in $\widetilde{O}(\mathrm{nnz}(B) + \varepsilon^{-2} qdk^2 \log(1 / \delta))$ ;
+- Query time in $\widetilde{O} (\varepsilon^{-2}qd^{\omega -1}k^{2}\log (1 / \delta))$
+
+Without using fast matrix multiplication, our algorithm improves upon the prior state-of-the-art $\left[\mathrm{DJS}^{+}19\right]$ on all parameters even in the static setting.
+
+# 7 Conclusion & Future Directions
+
+In this work, we initiate the study of the Dynamic Tensor Regression, Dynamic Tensor Spline Regression, and Dynamic Tensor Low-Rank Approximation problems, and design a tree data structure DYNAMIC TENSORTREE which can be used to provide fast dynamic algorithms for these problems. The problems we study are very interesting and there are a lot of exciting future directions, some of which we discuss below. First, it is unclear whether the algorithms we proposed are optimal and so having lower bounds for the update times would be an important direction. Second, we have focused exclusively on regression problems with the $\ell_2$ norm whereas solving Dynamic Tensor Regression and Dynamic Tensor Spline Regression with respect to the more robust $\ell_1$ -norm as well as for more general $p$ -norms are also very appealing.
+
+# Acknowledgments
+
+We would like to thank all the NeurIPS 2022 reviewers of our paper and also the ICML 2022 reviewers who reviewed an earlier version of this work. Most of this work was done while LZ was at CMU. AR was supported in-part by NSF grants CCF-1652491, CCF-1934931, and CCF-1955351 during the preparation of this manuscript.
+
+# References
+
+[ACW17] Haim Avron, Kenneth L. Clarkson, and David P. Woodruff. Sharper bounds for regularized data fitting. In Approximation, Randomization, and Combinatorial Optimization. Algorithms and Techniques - 20th International Workshop, APPROX 2017 and 21st International Workshop, RANDOM 2017, August 2017.
+$\left[\mathrm{AKK}^{+}20\right]$ Thomas D Ahle, Michael Kapralov, Jakob BT Knudsen, Rasmus Pagh, Ameya Velingker, David P Woodruff, and Amir Zandieh. Oblivious sketching of high-degree polynomial kernels. In Proceedings of the Fourteenth Annual ACM-SIAM Symposium on Discrete Algorithms (SODA), pages 141-160, 2020.
+[ALS+18] Alexandr Andoni, Chengyu Lin, Ying Sheng, Peilin Zhong, and Ruiqi Zhong. Subspace embedding and linear regression with orlicz norm. In International Conference on Machine Learning (ICML), pages 224-233. PMLR, 2018.
+$\left[\mathrm{BBB}^{+}19\right]$ Frank Ban, Vijay Bhattachiprolu, Karl Bringmann, Pavel Kolev, Euiwoong Lee, and David P. Woodruff. A ptas for $\ell_{p}$ -low rank approximation. In Proceedings of the Thirtieth Annual ACM-SIAM Symposium on Discrete Algorithms, SODA '19, page 747-766, 2019.
+$\left[\mathrm{BKM}^{+}22\right]$ Amos Beimel, Haim Kaplan, Yishay Mansour, Kobbi Nissim, Thatchaphol Saranurak, and Uri Stemmer. Dynamic algorithms against an adaptive adversary: Generic constructions and lower bounds. In Proceedings of the 54th Annual ACM SIGACT Symposium on Theory of Computing, pages 1671-1684, 2022.
+[BPSW21] Jan van den Brand, Binghui Peng, Zhao Song, and Omri Weinstein. Training (over-parametrized) neural networks in near-linear time. In ITCS, 2021.
+[Bub15] Sébastien Bubeck. Convex optimization: Algorithms and complexity. Foundations and Trends® in Machine Learning, 8(3-4):231-357, 2015.
+[BW14] Christos Boutsidis and David P Woodruff. Optimal cur matrix decompositions. In Proceedings of the 46th Annual ACM Symposium on Theory of Computing (STOC), 2014.
+[BWZ16] Christos Boutsidis, David P Woodruff, and Peilin Zhong. Optimal principal component analysis in distributed and streaming models. In Proceedings of the forty-eighth annual ACM symposium on Theory of Computing (STOC), pages 236-249, 2016.
+[CCFC02] Moses Charikar, Kevin Chen, and Martin Farach-Colton. Finding frequent items in data streams. In International Colloquium on Automata, Languages, and Programming, pages 693-703. Springer, 2002.
+$\left[\mathrm{CEM}^{+}15\right]$ Michael B Cohen, Sam Elder, Cameron Musco, Christopher Musco, and Madalina Persu. Dimensionality reduction for k-means clustering and low rank approximation. In Proceedings of the forty-seventh annual ACM symposium on Theory of computing, pages 163-172, 2015.
+[CMP20] Michael B. Cohen, Cameron Musco, and Jakub Pachocki. Online row sampling. Theory Comput., 16:Paper No. 15, 25, 2020.
+[CSTZ22] Sitan Chen, Zhao Song, Runzhou Tao, and Ruizhe Zhang. Symmetric sparse boolean matrix factorization and applications. In 13th Innovations in Theoretical Computer Science Conference (ITCS 2022). Schloss Dagstuhl-Leibniz-Zentrum für Informatik, 2022.
+
+[CW13] Kenneth L. Clarkson and David P. Woodruff. Low rank approximation and regression in input sparsity time. In Proceedings of the 45th Annual ACM Symposium on Theory of Computing (STOC), 2013.
+[DJS+19] Huaian Diao, Rajesh Jayaram, Zhao Song, Wen Sun, and David Woodruff. Optimal sketching for kronecker product regression and low rank approximation. Advances in neural information processing systems, 32:4737-4748, 2019.
+[DSSW18] Huaian Diao, Zhao Song, Wen Sun, and David Woodruff. Sketching for kronecker product regression and p-splines. In International Conference on Artificial Intelligence and Statistics, pages 1299-1308. PMLR, 2018.
+[EM96] Paul HC Eilers and Brian D Marx. Flexible smoothing with b-splines and penalties. Statistical science, 11(2):89-121, 1996.
+[EM06] Paul HC Eilers and Brian D Marx. Multidimensional density smoothing with p-splines. In Proceedings of the 21st international workshop on statistical modelling, 2006.
+[EMZ21] Hossein Esfandiari, Vahab Mirrokni, and Peilin Zhong. Almost linear time density level set estimation via dbscan. In AAAI, 2021.
+[FFG22] Matthew Fahrbach, Thomas Fu, and Mehrdad Ghadiri. Subquadratic kronecker regression with applications to tensor decomposition. arXiv preprint arXiv:2209.04876, 2022.
+[GVL13] Gene H. Golub and Charles F. Van Loan. Matrix computations. Johns Hopkins Studies in the Mathematical Sciences. Johns Hopkins University Press, Baltimore, MD, 2013.
+$\left[\mathrm{HJS}^{+}21\right]$ Baihe Huang, Shunhua Jiang, Zhao Song, Runzhou Tao, and Ruizhe Zhang. Solving sdp faster: A robust ipm framework and efficient implementation, 2021.
+[HLW17] Jarvis Haupt, Xingguo Li, and David P Woodruff. Near optimal sketching of low-rank tensor regression. In ICML, 2017.
+[IVWW19] Pitor Indyk, Ali Vakilian, Tal Wagner, and David P Woodruff. Sample-optimal low-rank approximation of distance matrices. In Conference on Learning Theory, pages 1723-1751. PMLR, 2019.
+$\left[\mathrm{JKL}^{+}20\right]$ Haotian Jiang, Tarun Kathuria, Yin Tat Lee, Swati Padmanabhan, and Zhao Song. A faster interior point method for semidefinite programming. In FOCS, 2020.
+[JLSW20] Haotian Jiang, Yin Tat Lee, Zhao Song, and Sam Chiu-wai Wong. An improved cutting plane method for convex optimization, convex-concave games and its applications. In STOC, 2020.
+[JPW22] Shunhua Jiang, Binghui Peng, and Omri Weinstein. Dynamic least-squares regression. arXiv preprint arXiv:2201.00228, 2022.
+[JSWZ21] Shunhua Jiang, Zhao Song, Omri Weinstein, and Hengjie Zhang. Faster dynamic matrix inverse for faster lps. In STOC. arXiv preprint arXiv:2004.07470, 2021.
+$\left[\mathrm{LCK}^{+}10\right]$ Jure Leskovec, Deepayan Chakrabarti, Jon Kleinberg, Christos Faloutsos, and Zoubin Ghahramani. Kronecker graphs: an approach to modeling networks. Journal of Machine Learning Research, 11(2), 2010.
+[LDFU13] Yichao Lu, Paramveer Dhillon, Dean P Foster, and Lyle Ungar. Faster ridge regression via the subsampled randomized hadamard transform. In Advances in neural information processing systems, pages 369-377, 2013.
+[LSZ19] Yin Tat Lee, Zhao Song, and Qiuyi Zhang. Solving empirical risk minimization in the current matrix multiplication time. In COLT, 2019.
+[Mad13] Aleksander Madry. Navigating central path with electrical flows: From flows to matchings, and back. In 2013 IEEE 54th Annual Symposium on Foundations of Computer Science (FOCS), pages 253-262. IEEE, 2013.
+
+[Mad16] Aleksander Madry. Computing maximum flow with augmenting electrical flows. In 2016 IEEE 57th Annual Symposium on Foundations of Computer Science (FOCS), pages 593-602. IEEE, 2016.
+[MC01] L.C. Marsh and D.R. Cormier. Spline Regression Models. Number 137 in Quantitative Applications in the Social Sciences. SAGE Publications, 2001.
+[MM13] Xiangrui Meng and Michael W Mahoney. Low-distortion subspace embeddings in input-sparsity time and applications to robust linear regression. In Proceedings of the forty-fifth annual ACM symposium on Theory of computing (STOC), pages 91-100, 2013.
+[MW21] Arvind V. Mahankali and David P. Woodruff. Optimal $\ell_1$ column subset selection and a fast ptas for low rank approximation. In Proceedings of the Thirty-Second Annual ACM-SIAM Symposium on Discrete Algorithms, SODA '21, page 560-578, 2021.
+[NK06] James G Nagy and Misha Elena Kilmer. Kronecker product approximation for preconditioning in three-dimensional imaging applications. IEEE Transactions on Image Processing, 15(3):604-613, 2006.
+[NN13] Jelani Nelson and Huy L Nguyen. Osnap: Faster numerical linear algebra algorithms via sparser subspace embeddings. In Proceedings of the 54th Annual IEEE Symposium on Foundations of Computer Science (FOCS), 2013.
+[OY05] S. Oh, S. Kwon and J. Yun. A method for structured linear total least norm on blind deconvolution problem. Applied Mathematics and Computing, 19:151-164, 2005.
+[Pag13] Rasmus Pagh. Compressed matrix multiplication. ACM Trans. Comput. Theory, 5(3), aug 2013.
+[PP13] Ninh Pham and Rasmus Pagh. Fast and scalable polynomial kernels via explicit feature maps. In Proceedings of the 19th ACM SIGKDD international conference on Knowledge discovery and data mining, pages 239-247, 2013.
+[PSA21] Aliakbar Panahi, Seyran Saeedi, and Tom Arodz. Shapeshifter: a parameter-efficient transformer using factorized reshaped matrices. Advances in Neural Information Processing Systems, 34, 2021.
+[RGLY78] L. R. Rabiner, B. Go ld, and C. K. Yuen. Theory and application of digital signal processing. IEEE Transactions on Systems, Man, and Cybernetics, 8(2):146-146, 1978.
+$\left[\mathrm{RRS}^{+}22\right]$ Aravind Reddy, Ryan A Rossi, Zhao Song, Anup Rao, Tung Mai, Nedim Lipka, Gang Wu, Eunyee Koh, and Nesreen Ahmed. One-pass algorithms for map inference of nonsymmetric determinantal point processes. In International Conference on Machine Learning, pages 18463-18482. PMLR, 2022.
+[RSW16] Ilya Razenshteyn, Zhao Song, and David P. Woodruff. Weighted low rank approximations with provable guarantees. In Proceedings of the Forty-Eighth Annual ACM Symposium on Theory of Computing, STOC '16, page 250-263, 2016.
+[Sar06] Tamás Sarlós. Improved approximation algorithms for large matrices via random projections. In Proceedings of 47th Annual IEEE Symposium on Foundations of Computer Science (FOCS), 2006.
+[SSX21] Anshumali Shrivastava, Zhao Song, and Zhaozhuo Xu. Sublinear least-squares value iteration via locality sensitive hashing. arXiv preprint arXiv:2105.08285, 2021.
+[ST04] Daniel A Spielman and Shang-Hua Teng. Nearly-linear time algorithms for graph partitioning, graph sparsification, and solving linear systems. In Proceedings of the thirty-sixth annual ACM symposium on Theory of computing, pages 81-90, 2004.
+[Sti81] Stephen M. Stigler. Gauss and the Invention of Least Squares. The Annals of Statistics, 9(3):465-474, 1981.
+
+[SWYZ21] Zhao Song, David P. Woodruff, Zheng Yu, and Lichen Zhang. Fast sketching of polynomial kernels of polynomial degree. In ICML, 2021.
+[SWZ17] Zhao Song, David P Woodruff, and Peilin Zhong. Low rank approximation with entrywise $\ell_1$ -norm error. In Proceedings of the 49th Annual Symposium on the Theory of Computing (STOC), 2017.
+[SWZ19a] Zhao Song, David Woodruff, and Peilin Zhong. Average case column subset selection for entrywise $\ell_1$ -norm loss. Advances in Neural Information Processing Systems (NeurIPS), 32:10111-10121, 2019.
+[SWZ19b] Zhao Song, David Woodruff, and Peilin Zhong. Towards a zero-one law for column subset selection. Advances in Neural Information Processing Systems, 32:6123-6134, 2019.
+[SWZ19c] Zhao Song, David P Woodruff, and Peilin Zhong. Relative error tensor low rank approximation. In SODA. arXiv preprint arXiv:1704.08246, 2019.
+[SY21] Zhao Song and Zheng Yu. Oblivious sketching-based central path method for solving linear programming problems. In 38th International Conference on Machine Learning (ICML), 2021.
+[SYZ21] Zhao Song, Shuo Yang, and Ruizhe Zhang. Does preprocessing help training overparameterized neural networks? Advances in Neural Information Processing Systems (NeurIPS), 34, 2021.
+[SZZ21] Zhao Song, Lichen Zhang, and Ruizhe Zhang. Training multi-layer over-parametrized neural network in subquadratic time. arXiv preprint arXiv:2112.07628, 2021.
+[VL00] Charles F Van Loan. The ubiquitous kronecker product. Journal of computational and applied mathematics, 123(1-2):85-100, 2000.
+[WR12] Alfred North Whitehead and Bertrand Russell. Principia mathematica, volume 2. Cambridge University Press, 1912.
+[WY22] David P Woodruff and Taisuke Yasuda. Improved algorithms for low rank approximation from sparsity. In Proceedings of the 2022 Annual ACM-SIAM Symposium on Discrete Algorithms (SODA), pages 2358-2403. SIAM, 2022.
+[WZ16] David P Woodruff and Peilin Zhong. Distributed low rank approximation of implicit functions of a matrix. In 2016 IEEE 32nd International Conference on Data Engineering (ICDE), pages 847-858. IEEE, 2016.
+[WZD+20] Ruosong Wang, Peilin Zhong, Simon S Du, Russ R Salakhutdinov, and Lin F Yang. Planning with general objective functions: Going beyond total rewards. In Annual Conference on Neural Information Processing Systems (NeurIPS), 2020.
+[XSS21] Zhaozhuo Xu, Zhao Song, and Anshumali Shrivastava. Breaking the linear iteration cost barrier for some well-known conditional gradient methods using maxip data-structures. Advances in Neural Information Processing Systems (NeurIPS), 34, 2021.
+[XZZ18] Chang Xiao, Peilin Zhong, and Changxi Zheng. Bourgan: generative networks with metric embeddings. In Proceedings of the 32nd International Conference on Neural Information Processing Systems (NeurIPS), pages 2275-2286, 2018.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] Please refer to Section 7.
+
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] Our work is theoretical and it provides a dynamic algorithm for tensor product-typed problems. We analyze the runtime complexity of our algorithm, which relates to energy consumption in practice. We do not foresee potential negative societal impact of our work.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes] Please refer to Section 3.2.
+(b) Did you include complete proofs of all theoretical results? [Yes] Please refer to Section B, C, D, and E in the supplementary materials.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [N/A]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [N/A]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [N/A]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [N/A]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [N/A]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/dynamictensorproductregression/images.zip b/dynamictensorproductregression/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..b63deb93b47ebedb62b8e8e10939f45dbba20164
--- /dev/null
+++ b/dynamictensorproductregression/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e67d184e408e58ec6e7da03859cd002b2a7393d5f3860091faa0f64f7bcd47cf
+size 122783
diff --git a/dynamictensorproductregression/layout.json b/dynamictensorproductregression/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..7f10d598e1dccd446fa5508501e83c73303f2967
--- /dev/null
+++ b/dynamictensorproductregression/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:96a9ad86a13f23c8a29a5f5a5f92b4917271af6777da866f6c193e27f3287145
+size 667337
diff --git a/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/371ab424-73a3-4d69-9b96-de0cb256ba34_content_list.json b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/371ab424-73a3-4d69-9b96-de0cb256ba34_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..900da07eeb37e81531baf73bf03096d4d085b273
--- /dev/null
+++ b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/371ab424-73a3-4d69-9b96-de0cb256ba34_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4a76f6dbbd855ffbed9d8d926180f75f54f92bb1aa203f05af764ddf91f45a9d
+size 77769
diff --git a/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/371ab424-73a3-4d69-9b96-de0cb256ba34_model.json b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/371ab424-73a3-4d69-9b96-de0cb256ba34_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..0103583ec0211bbab2cd387b1938c7ac056d12b7
--- /dev/null
+++ b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/371ab424-73a3-4d69-9b96-de0cb256ba34_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7dd8b26fd0fd877a1096c67d5628eecc27abea475bb6dac5f2b57e1236ace6f4
+size 96070
diff --git a/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/371ab424-73a3-4d69-9b96-de0cb256ba34_origin.pdf b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/371ab424-73a3-4d69-9b96-de0cb256ba34_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..22966b5375a4b85bd72b535af1f5b90ecd7090cf
--- /dev/null
+++ b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/371ab424-73a3-4d69-9b96-de0cb256ba34_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9be5c9a4d257fea4ef1febed9bb14dd683ad487dfa6acc1834f1d8094d406483
+size 1536863
diff --git a/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/full.md b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..0811edfdae5e9a092f1c17295eca6037c0b74528
--- /dev/null
+++ b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/full.md
@@ -0,0 +1,298 @@
+# EAGER: Asking and Answering Questions for Automatic Reward Shaping in Language-guided RL
+
+# Thomas Carta
+
+Inria - Flowers team
+Université de Bordeaux
+thomas.carda@inria.fr
+
+# Sylvain Lamprier
+
+ISIR Sorbonne Université
+Univ Angers, LERIA,
+SFR MATHSTIC, F-49000 Angers, France
+sylvain.lamprier@univ-angers.fr
+
+# Pierre-Yves Oudeyer
+
+Inria - Flowers team
+Université de Bordeaux
+Microsoft Research Montreal
+pierre-yves.oudeyer@inria.fr
+
+ISIR Sorbonne Université, Paris, France olivier.sigaud@isir.upmc.fr
+
+# Abstract
+
+Reinforcement learning (RL) in long horizon and sparse reward tasks is notoriously difficult and requires a lot of training steps. A standard solution to speed up the process is to leverage additional reward signals, shaping it to better guide the learning process. In the context of language-conditioned RL, the abstraction and generalisation properties of the language input provide opportunities for more efficient ways of shaping the reward. In this paper, we leverage this idea and propose an automated reward shaping method where the agent extracts auxiliary objectives from the general language goal. These auxiliary objectives use a question generation (QG) and question answering (QA) system: they consist of questions leading the agent to try to reconstruct partial information about the global goal using its own trajectory. When it succeeds, it receives an intrinsic reward proportional to its confidence in its answer. This incentivizes the agent to generate trajectories which unambiguously explain various aspects of the general language goal. Our experimental study shows that this approach, which does not require engineer intervention to design the auxiliary objectives, improves sample efficiency by effectively directing exploration.
+
+# 1 Introduction
+
+One of the main challenges of Reinforcement Learning (RL) research is to train agents able of abstraction, generalisation and communication. Languages, be they natural or formal, afford these desirable properties [11]. Based on this insight, many papers have tried to leverage the abilities of language in RL to enable communication and improve generalisation and sample efficiency [3, 22, 12, 36]. The domain can be subdivided into language-conditioned RL (LC-RL), in which language conditions the formulation of the problem[2, 12], and language-assisted RL, where language helps the agent to learn [15, 10, 1, 9]. In the present paper, we focus on the LC-RL framework where the agent initially receives a language instruction and must act to optimise the corresponding reward function. Unfortunately, the corresponding RL algorithms are sample inefficient, especially due to the fact that the reward function is sparse when it is restricted to completing the goal.
+
+To tackle the reward sparsity issue, one idea is to densify the reward by decomposing the general goal into sub-goals and rewarding them individually. This idea is based on a decomposition principle which
+
+
+Figure 1: During training, the agent uses the goal to generate relevant questions using its question-generation module QG. Then, it attempts at answering them from current trajectories at each step with its question-answering module QA, by looking at the trajectory. When it succeeds, it obtains an intrinsic reward proportional to its confidence in its answer. Then it removes the answered questions from the list of questions. This incentivizes the agent to produce trajectories that enable to reconstruct unambiguously partial information about the general language goal, enabling to shape rewards and guide learning.
+
+hypotheses that a general goal can be decomposed into a set of easier ones. Previous works assume a strict decomposition of the general goal into sub-goals [3, 17]. However, strict decomposition requires that each high-level goal can be reached through an exact series of low-level policies, an assumption which fails when all the primitive actions are not known in advance. More recently, the ELLA method was proposed as a language reward shaping technique that is sample efficient and does not require a strict decomposition: it rewards interesting auxiliary objectives, without requiring rigid ordering and correspondence with sub-goals [23].
+
+However, all these methods suffer from the need for expert input. Indeed, they require task-specific engineering for determining at least one of the following elements: the set of sub-goals or auxiliary objectives, the relevant ones and when they are achieved, and the appropriate reward. While all these points can be addressed more or less easily in simple game-like environments, they get demanding when the environment is more complex. Therefore, it seems desirable to find an alternative reward shaping approach that minimises expert involvement. We would like the agent to generate its own auxiliary objectives and create intrinsic rewards, just like a human would do.
+
+The Natural Language Processing (NLP) field often suffers from the same need of expert input, e.g. for the evaluation of automatic summary tasks. In that context, some successful approaches have developed reference-less metrics [31], [29], based on question generation (QG) and question answering (QA). These techniques assess the quality of a generated text by measuring the quantity of information from the source conserved in the generated text (broadly, how well one can answer questions about the original text using the generated text). These metrics are said reference-less because they do not require a comparison with a man-made example to evaluate the quality of a text.
+
+Contributions In our work, we build on these reference-less metrics to circumvent the need of expert input for generating auxiliary objectives. We adapt it and propose a novel QG/QA framework for RL called EAGER. $^{1}$ In EAGER, an agent reuses the initial language goal sentence to generate a set of questions (QG): each of these self-generated questions defines an auxiliary objective. Here, generating a question consists in masking a word of the initial language goal. Then the agent tries to answer these questions (guess the missing word) only by observing its trajectory so far. When it manages to answer a question correctly (QA) it obtains an intrinsic reward proportional to its confidence in the answer. The QA module is trained using a set of successful example trajectories. If the agent follows a path too different from correct ones at some point in its trajectory, the QA module
+
+will not answer the question correctly, resulting in zero intrinsic reward. The sum of all the intrinsic rewards measures the quality of a trajectory in relation to the given goal. In other words, maximizing this intrinsic reward incentivizes the agent to produce behaviour that unambiguously explains various aspects of the given goal.
+
+To the best of our knowledge, EAGER is the only framework that can automatically 1) generate relevant auxiliary objectives, 2) determine their completion and 3) return the appropriate intrinsic reward. This approach only assumes the agent has access to a dataset of demonstrated behaviours associated to global language commands, which enables it to pre-train its question answering module.
+
+Thus our work brings the following contributions:
+
+- We create a QG/QA metric providing to an agent an information-rich measure of the quality of its trajectory given a goal.
+- We propose the EAGER framework that lets the agent guide its own learning process by generating auxiliary objectives and producing intrinsic rewards without requiring any expert intervention.
+- We show that EAGER retains the good properties of ELLA without requiring task-specific expert knowledge, by leveraging properties of language.
+- We experiment EAGER with the BabyAI platform [7]: we compare our approach against ELLA (SOTA on BabyAI) and RIDE (a non-language based reward shaping approach using intrinsic motivation), showing its robustness and sample efficiency. Furthermore, although we use example trajectories to train the QA, their use is much more parsimonious than training an agent using behavioural cloning [7], as we show in Appendix C.
+
+# 2 Related work
+
+Language-conditioned RL. We place our work in the LC-RL setting, where an agent learns a policy to execute language commands [24, 7, 20, 21]. We reuse the BabyAI platform [7], widely used in this domain as it enables to decouple exploration challenges from perception challenges. It uses a synthetic language exhibiting interesting combinatorial properties with possible conjunction of properties, and procedural generation to avoid overfitting [8]. Here, we consider instruction following agents which receive external instructions and rewards [14, 5, 17].
+
+Language as an abstraction in hierarchical RL. Several approaches leverage language for abstraction in hierarchical RL. One approach uses language for training a low-level instruction-following policy, then learns a high-level policy that generates the sequence of low-level goals [17]. Another one explicitly decomposes high-level tasks into low-level ones as in policy sketches [3]. ELLA [23] also uses language to decompose high-level tasks but relaxes the strict decomposition constraint by replacing sub-goals with auxiliary objectives. We adopt the same flexible framework in our approach but automatise the decomposition.
+
+Language for exploration and reward shaping. Reward shaping is a form of guidance that supplies additional rewards to the agent to direct its learning process. Among approaches studying how language can shape rewards and exploration, LEARN [12] proposes to map intermediate natural language instruction to intermediate rewards. Similarly, [35] enables reward shaping using natural language through a narration-guided method. The high-level tasks are decomposed into low-level tasks and rewarded using narration. ELLA [23] is positioned in the same paradigm but with fewer assumptions about the environment or the structure of the task.
+
+Other approaches assume that an oracle provides language descriptions of environment states which are used as state abstraction to generate novelty intrinsic rewards and guide exploration [25, 34]. This extends classical approaches to intrinsically motivated exploration [4], such as count-based methods [6] or RIDE [28]. Here, we also use language to generate intrinsic rewards, but we do not need language descriptions of states. Besides, other forms of intrinsic motivation systems, such as IMAGINE [10], first learn language-parameterized reward functions through interaction with a social peer, then autonomously use language to generate diverse and novel goals, using the learned reward function for self-supervision.
+
+Asking questions in RL. Beyond reward shaping, some methods consider agents that use language to ask questions to external knowledge sources. In QWA [36], questions are used to identify sub-tasks and prune irrelevant actions. In AFK [19], questions are used to obtain world knowledge that helps completing tasks.
+
+Natural Language Processing One of the sources of QG/QA methods is the thriving field of question generation from natural language processing and information retrieval [16]. Our approach is inspired from text generation methods where QG and QA are used to measure the quality of a generated text without using a human reference [31, 29].
+
+# 3 Problem statement
+
+We set ourselves in the standard framework of LC-RL with an augmented Partial Observation Markov Decision Process [33] $\mathcal{M}$ defined by the tuple $(\mathcal{S},\mathcal{A},\mathcal{Z},\mathcal{T},\mathcal{O},\mathcal{G},\mathcal{V},\mathcal{I},\mathcal{R},\gamma)$ , with $\mathcal{S}$ the state space, $\mathcal{Z}$ the observation space, $\mathcal{A}$ the actions space, $\mathcal{G}$ the goal space, $\mathcal{V}$ the vocabulary of goal instructions. $\mathcal{O}$ stands as the observation function $\mathcal{O}:S\to \mathcal{Z}$ , which maps states to the observations space. $\mathcal{I}$ is the instruction function $\mathcal{I}:\mathcal{G}\rightarrow \mathcal{V}^{size}$ , which maps any goal in $\mathcal{G}$ to the set of language instructions, which correspond to sequences of $isize$ symbols (the empty symbol $\epsilon$ belongs to $\mathcal{V}$ to allow variable instruction sizes). $\mathcal{R}$ is a goal-conditioned state action reward function, with $\mathcal{R}:S\times \mathcal{A}\times \mathcal{G}\to [0,1]$ the extrinsic reward received for some goal $g\in \mathcal{G}$ and $\gamma$ the discount factor. For simplicity, we note in the following $r_t^g = \mathcal{R}(s_t,a_t,g)$ as the reward obtained at step $t$ of any episode with goal $g$ .
+
+At each time step $t$ , the agent receives an observation $o_t \in \mathcal{Z}$ following the observation function $\mathcal{O}: \mathcal{S} \to \mathcal{Z}$ and selects an action $a_t \in \mathcal{A}$ to reach a goal $g \in \mathcal{G}$ , expressed by $\omega^g = \mathcal{I}(g)$ . $\mathcal{T}: \mathcal{S} \times \mathcal{A} \to \mathcal{P}(\mathcal{S})$ is the transition function. Using RL, we search for an optimal goal-conditioned policy $\pi^*$ , such that $\pi^*: \mathcal{S} \times \mathcal{V}^{size} \to \mathcal{A}$ maximises the discounted expected return $R_t^{\pi_g} = \mathbb{E}_{\pi}[\sum_{k=0}^{T} \gamma^k r_{t+k+1}^g]$ . We consider in this work sparse reward problems, where $r(s, a, g)$ returns 1 for any state $s$ such that $d(s, g) \leq \epsilon$ , for a given distance function $d$ and a specified threshold $\epsilon$ , and 0 otherwise. Moreover, we assume a limited number of steps at most $H$ steps. These two conditions result in a hard exploration problem.
+
+To deal with those problems, many methods aim at densifying rewards, by focusing on auxiliary objectives during training, whose accomplishment can help the agent to reach the goal $g$ at hand. In previous work, such as ELLA [23], the selection of relevant objectives required the intervention of an expert (in the form of expert annotations and example trajectories), which can be problematic because new expert trade-offs have to be established for each new environment. Thus, an automated way must be found to recover the relevant auxiliary objectives, measure their completion, and associate the appropriate reward.
+
+Rather than relying on expert knowledge for defining auxiliary objectives, we assume that we have access to a set of trajectories of successful examples coupled to their respective instructions $\{(\tau_0,\omega_0^g),\dots,(\tau_n,\omega_n^g)\}$ , where $\tau_{n} = (o_{i},a_{i})_{i\in [|0,k|]}$ with $k$ the number of steps. For any goal instruction $\omega^g$ , we consider a function $f$ that aims at generating a set of auxiliary goals of $g$ , such that all $g^{\prime}\in f(\omega^{g})$ belong to $\mathcal{G}^g$ , with $\mathcal{G}^g\subset \mathcal{G}$ the set of goals that help training the agent towards $g$ . Then, for a trajectory $\tau$ and any $g^{\prime}\in f(\omega^{g})$ , a function $h$ determines the probability $h(\tau ,g^{\prime})\in [0,1]$ that the auxiliary objective $g^{\prime}$ has been achieved. We train $h$ using the example demonstrations such that we can leverage its generalisation abilities to use $h$ for unseen trajectories.
+
+Please note that Behavioural Cloning methods also rely on the exploitation of expert trajectories, by learning the policy $\pi_{BC}$ that maximises the log-likelihood $\mathcal{L}_{BC}$ :
+
+$$
+\mathcal {L} _ {B C} = \sum_ {i = 0} ^ {n} \log P (\tau_ {i}) \text {w h e r e} \log P (\tau) = \sum_ {j = 0} ^ {k} \log \left(\pi_ {B C} \left(a _ {k} \mid o _ {k}\right) \mathcal {T} \left(s _ {k + 1} \mid s _ {k}, a _ {k}\right)\right).
+$$
+
+However, the latter uses demonstrations to train an agent to copy an expert based on a data set of example trajectories. This technique is only effective when the agent is close enough to the demonstrated examples. A large number of demonstrations are therefore required to cover the space of states that the agent may encounter. Methods such as GAIL [18] can partially circumvent this problem by forcing the agent to stay on known trajectories, but this impairs generalisation. Our method is much more parsimonious in the use of such examples: because it generalises well, the
+
+agent can receive intrinsic rewards even in areas not encountered in the expert demonstrations (see Appendix C).
+
+# 4 Method
+
+In this section, we first introduce EAGER, our automated reward shaping method based on QG/QA, then we present a practical implementation in the context of the BabyAI benchmark. Figure 1 provides a graphical overview of EAGER.
+
+# 4.1 EAGER
+
+We need an automatic evaluation method that is fine-grained enough to rank various trajectories depending on a language instruction. But various successful policies can generate a set of valid trajectories for the same goal. It could be deceiving to rank them based only on their final results, as an overly complex trajectory seems intuitively worse than a simpler one even if the result is the same.
+
+To address this issue, the EAGER framework consists of an agent learning module, a question generation module $QG$ (automatic, but not learned) and a learned question answering module $QA$ . These two modules fulfil the role of the functions $f$ and $h$ defined in Section 3. EAGER is inspired from works like QuestEval [31] and Data-QuestEval [29], developed for natural language generation. For instance, for abstractive summarization, by generating questions from the original text (QG) and trying to answer them using the summary QA, this method measures the quantity of information shared between both texts.
+
+In our work, we draw the analogy with the NLP task with the goal replacing the original text and the trajectory replacing the summary. We use the QG/QA system to verify that a trajectory contains the same level of information as the language instruction, meaning that the goal is contained in the trajectory. As the goal can be contained in a lot of different trajectories, we also favour simple trajectories. If one can easily answer the question, that means the trajectory is simple.
+
+The QG module We assume that the goal linguistic instruction $\omega^g$ of $g\in \mathcal{G}$ is a highly expressive language instruction (e.g Put the red ball next to the blue box, open the red door, ...), containing by themselves enough world knowledge to generate questions by masking words. Thus, the QG module returns a list of $k$ questions $QG_{k}(\omega^{g})$ that can be seen as auxiliary objectives. Each question is formed by masking one word in the linguistic instruction. Crucially, the choice of words to mask can be done automatically without any expert knowledge of the task, or the environment, for instance masking all nouns and adjectives. These questions can be seen as auxiliary objectives guiding the agent during training. Besides, being formulated in natural language, these auxiliary objectives are easily interpreted.
+
+The QA module Let $\tilde{A}$ be the set of possible answers generated automatically from the list of tokens masked by the QG. Thus, $\tilde{A}$ contains $(q,a^{*})$ pairs of questions and expected answers. The QA module returns the probability for all $\tilde{a} \in \tilde{A}$ , that $\tilde{a}$ answers question $q$ , given a trajectory $\tau_{t}$ , where $\tau_{t} = (o_{i},a_{i})_{i\in [|0,t|]}$ are state-action pairs and $t$ the time step. We note $\tilde{a}^{*} = QA(q,\tau_{t})$ the answer greedily generated from the module and $QA(\tilde{a}^{*}|q,\tau_{t})$ the associated probability. The auxiliary objectives from the QG are considered achieved when the QA answers them successfully. In our work, the QA module is pre-trained using full example trajectories generated by a bot, see Section 5.1, without any type of annotations to guide it. Besides, at time step $t$ , there is no guarantee that the trajectories contain enough information to correctly answer a question. Thus we include a «no_answer» token in $\tilde{A}$ to prevent the QA from answering correctly by chance. Moreover, since the QA module takes the whole trajectory, once it has answered a question, it can also answer it at the next step. To avoid giving a reward that does not have direct link to the current step, every time a question $q$ is answered, it is removed from the set of questions: We note $\mathcal{Q}_t$ the active set of questions, the initial set is $\mathcal{Q}_0 = QG_k(\omega^g)$ and once a question is answered, we apply $\mathcal{Q}_t \gets \mathcal{Q}_{t-1} \backslash \{q\}$ .
+
+Architecture of the QA The QA is used to compositionally chain low-level tasks. To do this, it relies on the episodic transformer [27]. This architecture uses multimodal transformers (over language, visual observation, and a list of actions) that have access to the full episode. For any time
+
+step $t$ and any question, a $(x_{1:L}, v_{1:t}, a_{1:t})$ tuple is given as input to the QA module. The language input $x_{1:L}$ is the question, it is a sequence of $L$ tokens with $x_i \in \mathbb{N}$ . The visual input $v_{1:t}$ is the list of observations $v_t \in \mathbb{R}^{W \times H \times 3}$ . Finally, the action input $a_{1:t}$ is a list of discrete actions. As output, the network returns the probability distribution over the set of possible answers $\tilde{\mathcal{A}}$ .
+
+Intrinsic reward The main difficulty in ranking trajectories is that many trajectories can share the same description and thus can answer questions correctly. However, a human assessing several trajectories, with the same extrinsic reward, relatively to the same goal would prioritise the simplest one. To account for this, we make the reward proportional to the confidence in the answer at time step $t$ : $QA(\tilde{a}^{*} \mid q, \tau_{t})$ . An overly complex trajectory being harder to understand for the QA, the answer should be given with less confidence, so it should obtain less reward than a direct and clear trajectory, even with the same number of correct answers.
+
+In this paper, we keep the same desired properties for the shaped reward function as the ones given in ELLA: the reward shaping should not change the optimal policy that prevails before the reward shaping (policy invariance), and the reward should encourage sample efficient exploration based on auxiliary-objectives. Using intrinsic rewards, we modify the global reward from $r$ to $r'$ through a policy invariant transformation [26], which ensures that the new policy $\pi^*$ is optimal for both $\mathcal{M}$ and $\mathcal{M}' = (\mathcal{S}, \mathcal{A}, \mathcal{T}, \mathcal{G}', \gamma)$ . To do so, we ensure that only successful trajectories get the same return with or without the reward shaping by subtracting the shaped reward at the final time step $N$ of a successful trajectory: $r_N' = r_N - \sum_{t \in T_{\mathbb{S}}} \gamma^{t-N} r_t'$ with $r_t' = \lambda \sum_{q \in Q_t} \sum_{\tilde{a}^* \text{is correct answer}} QA(\tilde{a}^* | q, \tau_t)$ , where $T_{\mathbb{S}}$ is the set of time steps where a bonus is applied. $r_t$ is the reward given at time step $t$ , in the case of sparse reward studied here $r_t \neq 0$ only if $t$ corresponds to the last step of a successful trajectory. In ELLA Mirchandani et al. [23] the authors prove that this transformation is policy invariant. Thus, as long as the policy produces unsuccessful trajectories, the agent is guided by the shaping reward. Then once it has learned to successfully complete an instruction, the shaping reward is subtracted at the last step and the agent improves using only the extrinsic reward. Further details are provided in the appendix.
+
+The QA system is pre-trained with successful trajectories, which prevents reward hacking. Indeed, if the agent individually completes the auxiliary objectives without a meaningful trajectory, the QA does not consider the trajectory meaningful and answers: "no_answer", preventing the agent to get rewarded.
+
+Using the above notations and concepts, we can define a metric to measure the adequacy of a trajectory to a goal, that corresponds to our cumulative intrinsic reward over a trajectory $\tau$ of length $N$ , up to a $\lambda$ factor:
+
+$$
+m _ {Q G / Q A} (g, \tau) = \sum_ {t = 0} ^ {N} \sum_ {q \in \mathcal {Q} _ {t}} Q A \left(\tilde {a} ^ {*} \mid q, \tau_ {t}\right) \mathbb {I} [ \tilde {a} ^ {*} \text {c o r r e c t a n s w e r t o q} ]. \tag {1}
+$$
+
+Algorithm Our algorithmic procedure is given in Algorithm 1. At the beginning of an episode, the QG takes the goal and returns a set of questions related to it. Then the QA module is applied at each step over the active set of questions $\mathcal{Q}_t$ . When a question is answered correctly, the shaped reward function returns a bonus $\lambda QA(\tilde{a}^{*} \mid q, \tau_{t})$ , where $\lambda$ is a scaling factor, to the agent and the answered question is removed from the set of active questions.
+
+Then we tune $\lambda$ to ensure that no unsuccessful trajectories can get more reward than a successful one from the optimal policy $\pi^{*}$ . The higher bound for the shaped reward of unsuccessful trajectories is $\lambda k$ and the lower bound for the reward of a successful trajectory is $\gamma^H r_H$ , where $k$ is the number of questions generated by the $QG$ and $H$ is the maximum length of an episode. Thus we obtain
+
+$$
+\lambda < \frac {\gamma^ {H} r _ {H}}{k}. \tag {2}
+$$
+
+Note that by making a less conservative hypothesis, i.e. assuming in the worst case the successful trajectory takes $\mathrm{N} < \mathrm{H}$ steps, we could obtain a higher $\lambda$ leading to faster learning [23].
+
+| Algorithm 1 Automatic auxiliary goal generation and reward shaping using EAGER |
| Input: θ0 initial policy parameters, λ bonus scaling factor, ENV the environment and OPTIMISE an RL optimiser | function QA_SHAPE(Qt, τt, rt) for q in Qt do |
| for k=0,..., nstep do | a* ← QA(q, τt) if a* is correct answer to q |
| ωg, o0, done0 ← ENV.reset() |
| Q0 = {q1, ..., qk} ← QGk(ωg) | then |
| t ← 0 | rt' = rt + λQA(a* | q, τt) |
| while done_t not True do | Q = Q \{q} |
| at ← πθ0(at) | end if |
| ot+1, rt, done t+1 ← ENV(at) | end for |
| rt', Qt+1 ← QA_SHAPE(Qt, τt, rt) | return rt', Q |
| if done t+1 is True then | end function |
| N ← t | |
| r'N ← NEUTRALISE(r'1:N) | function NEUTRALISE(r'1:N) |
| end if | r'N ← r'N - ∑t∈Ts γt-N r' |
| end while | return r'N |
| Update θk+1 ← OPTIMISE(r'1:N) | end function |
| end for | |
+
+# 4.2 A particular instance of the method in the BabyAI framework
+
+We now explain how to adapt the EAGER method to train an RL agent in BabyAI, a language-conditioned environment where the agent has a limited number of steps to complete a language goal. In this environment the agent receives a reward if and only if it finishes the task successfully.
+
+The BabyAI benchmark contains tasks with highly expressive language instructions e.g. Put the red box next to the green key, ...). Thus they are rich enough to generate questions by masking words. In practice, we mask nouns and adjectives: this form of QG is very simple and can be automated using standard NLP techniques, thus it does not require expert knowledge. For instance, for the goal Put the red ball next to the blue box, using the token «question» as a mask we generate 4 questions among which Put the «question» ball next to the blue box.
+
+The environments in our experiments are partially observable. Thus, our agent takes sequences of observations $(o_1,o_2,\dots,o_t)$ as inputs of a recurrent network [13].
+
+# 5 Experiments
+
+# 5.1 Experimental settings
+
+We use the BabyAI [7] platform to run our experiments. This platform relies on a gridworld environment (MiniGrid) to generate a set of complex instructions-following environments. It has been specifically designed for research on grounded language learning and related sample efficiency problems. The gridworld environment is populated with several entities: the agent, boxes, balls, doors, and keys of 6 different colors. These entities are placed in rooms of $8 \times 8$ tiles that are connected by doors that could be locked or closed. The agent can do 6 primitive navigation actions such as forward, toggle, pick up to solve the language instruction (for instance Pick up the red box). It only has access to partial observations of its environment inside which irrelevant objects are randomly added. Moreover, the observations are in a symbolic space using a compact encoding, with 3 input values per grid cell, $^{2}$ $8 \times 8 \times 3$ values in total. When the agent completes the task after $N$ steps, it receives the reward $r_{N} = 1 - 0.9\frac{N}{H}$ , where $H$ is the maximum number of steps. During training, all rewards are scaled up by a factor of 20 to ensure a good propagation of the rewards. If the agent fails, the reward is 0. We focus our tests on tasks of varying complexity: PutNextTo, Unlock and Sequence. The task can also take place in one room local or two rooms Medium.
+
+To train the QA module through supervised learning, we build a dataset of example trajectories associated to language goals using a bot provided in BabyAI, then we generate related questions and
+
+
+
+
+
+
+
+
+Figure 2: Average reward for EAGER and baselines for four tasks, with error regions to indicate standard deviation over four random seeds. For the PutNext-Local and Sequence-Medium tasks, we give an example of possible tasks with environment at time step 0.
+
+
+EAGER ELLA RIDE PPO
+
+
+
+answers. To obtain a QA that can operate on various tasks, we use a mix of the PutNextTo, PickUp, Open, and Sequence tasks for generating training trajectories. This dataset is only used to train the QA, not to bootstrap policy learning. During training, we give as input of the QA the full trajectory — the list of observations and actions — and all the questions generated by the QG and we use the cross-entropy loss over its output distribution to update it. To train the QA to answer: "no_answer" and prevent it from guessing the answer by chance, we randomly associate some trajectories and questions from unrelated goals. For instance, we associate the trajectory from the goal: take the red box next to the blue ball and associate it with the question: take the red «question» next to the blue key generated from the goal take the red box next to the blue key. The QA must learn to pay attention to all the details of the question. It has to see that the trajectory describes an agent taking the red box but placing it next to an object other than the one in the question. Thus the good answer to the question is no_answer and not box.
+
+Moreover, we empirically show in Section 5.4 that the QA is more efficient when it learns from a broad distribution of trajectories for similar tasks. The intuition behind such behaviour is that a QA trained on a narrow distribution of successful bot-generated trajectories will not recognise the noisy trajectories of the agent when it starts training. Thus the QA will too often answer "no_answer", resulting in no intrinsic reward and hurting the reward shaping efficiency. To produce a wider distribution using the given procedural bot, we force the bot to take with a certain probability a random action at each time step and only keep successful noisy trajectories as training examples. More details on the QA pre-training are given in Appendix B.1. All the tasks we use for training the QA and the agent are summarised with examples in Appendix A.
+
+To evaluate our reward shaping framework, we use the Proximal Policy Optimization (PPO) algorithm [30], but our reward shaping method is algorithm agnostic. We compare our framework to PPO without reward shaping, ELLA and RIDE. RIDE [28] is an exploration method that does not use language and addresses sparse reward problem by rewarding impactful change in state. We use Nvidia Tesla V100 with 10 cores to train our model and we use 4 seeds in each experiment.
+
+Figure 2 presents learning curves for EAGER, ELLA and RIDE across 4 environments. Table 1 describes the assumptions and the type of expert knowledge required by the three reward shaping methods. It clearly appears that EAGER requires less expert human intervention than ELLA.
+
+Table 1: All the assumptions and expert knowledge required for RIDE, EAGER, and ELLA
+
+| Method | Number of expert demonstration per task | Human Expert Intervention | Automated parts done by the agent |
| RIDE | 0 | None | Determining if a new state is impacting |
| EAGER | 7.500 noisy bot trajectories (see supplementary Wide distribution of trajectories) | Determining what words are nouns or adjectives | Determining relevant auxiliary objectives Determining auxiliary objectives completion Determining auxiliary objectives associated reward |
| ELLA | 15.000 bot trajectories | Determining the class of relevant auxiliary objectives Determining auxiliary objectives associated reward | Determining relevant auxiliary objectives among the predetermine class Determining auxiliary objectives completion |
+
+# 5.2 How does EAGER perform when sparsity increases?
+
+In the PutNextTo and Unlock tasks, EAGER obtains results better than ELLA (SOTA in BabyAI) without using expert knowledge. It also performs significantly better than RIDE for the tasks PutNext and Sequence and slightly better for Unlock. The better performance of EAGER with respect to RIDE is not surprising as the EAGER agent receives some indications based on example trajectories through the QA module.
+
+For Unlock-Medium, EAGER overcomes a bottleneck. The general goal being Open the «colour» door, the agent has to first pick up the key of the corresponding colour before reaching the door to open it. ELLA rewards picking up keys, via the PICK low-level instruction chosen via expert knowledge. EAGER reaches better performance (see the statistical test in Appendix C) without the need for expert knowledge. Moreover, although this is not its main purpose, EAGER gets a similar or better sample efficiency for most tasks.
+
+# 5.3 How does EAGER perform with a sequence of tasks under a temporal constraint?
+
+The Sequence task adds a temporal constraint by chaining two tasks using 'before' or 'after' together with a high number of instructions (over 1.5M instructions in comparison with PutNext-Medium with 1440 instructions). Moreover both EAGER and ELLA decompose the goal into auxiliary objectives. This decomposition does not retain the temporal constraint, there is no notion of doing one auxiliary objective before another.
+
+Our tests show that EAGER retains strong performance, doing better than RIDE and ELLA. The slow progress of EAGER at the beginning can be attributed to the time when the agent is not good enough to efficiently trigger an intrinsic reward signal from the QA module. Indeed, at the beginning, trajectories are noisy and it is more difficult for the QA to exploit a trajectory with more rooms. As a result, it over-reponds "no_answer" leading to a lesser intrinsic reward.
+
+# 5.4 Is EAGER robust to QA performance?
+
+At first glance, the reliability of the QA looks crucial to our method. However, the QA could be difficult to train in some environments e.g. if you want the QA to learn to answer in a large set of answers from a small number of example trajectories. This is why we tested the robustness of our method using the PutNextTo-Local task with two metrics: the success rate SR of the QA after pre-training and the distribution of example trajectories. For the former, we take the same QA at different training epochs and we determine its SR over a test dataset, then we train the agent using the reward shaping provided by this QA. Figure 3(left) shows the robustness of our method with agents that display similar training curves as soon as $SR > 0.56$ .
+
+In Figure 3(right), we plot the SR of the QA when training the agent. Initially, the QA with a $SR \leq 0.56$ at pre-training time tends to have a higher SR. Indeed, the distribution of answers is less peaked and answers are often correct by chance. On the opposite, the QA with a $SR > 0.56$ answers "no_answer" and obtains no reward. However, in this case, the agent learns faster because it only receives a reward for meaningful answers. For the QA with a $SR \leq 0.56$ , the SR along training first grows then decreases. First, the agent is biased by the intrinsic reward to follow a path that improves
+
+
+Figure 3: Average reward (left) and success rate of the QA (right) for the PutNextTo-Local tasks. The agent are trained with QA having different success rate after pre-training.
+
+
+Figure 4: Average reward in tasks PutNextTo and Sequence for two distributions of bot trajectories used to train QA. A narrow and a wide distribution where noise is added to bot trajectories
+
+the SR, but once the agent learns to complete the trajectory leading to the extrinsic reward, the SR converges to pre-training SR.
+
+As explained in Section 5.1, we added noise to trajectories generated by the bot to compensate for a too narrow trajectory distribution. Figure 4 shows training curves for two environments for QA trained on wide trajectory distribution (WD) and narrow distribution (ND). The reward shaping method trained on (WD) learns faster because they efficiently reward the agent early in training.
+
+# 5.5 How do design choices on the QA module affect EAGER's performance?
+
+In Section 4.1 we made two choices for the QA module and the associated intrinsic reward: first we added a "no_answer" response, second we rewarded each answer by the confidence the agent had in its own answer. To verify the influence of these choices over EAGER's performance, we use the PutNextTo task to compare EAGER against "EAGER \no_answer", "EAGER Simple", and "EAGER Simple \no_answer". "Simple" means that the agent received a binary intrinsic reward (1 for a good answer, 0 otherwise) and "no_answer" means we suppressed the "no_answer" solution. Figure 5 gives the results of these ablations. We can see that both the use of "no_answer" and the non-binary reward independently boost sample efficiency.
+
+
+Figure 5: Average reward in PutNextTo with various ablations of the QA module.
+
+# 6 Conclusion
+
+In this work, we have proposed to leverage the abstraction and generalisation properties of language to build an automatic reward shaping method in the context of long horizon and sparse reward tasks. Our learning agent generates its own questions from the goal and rewards itself for correctly answering them, resulting in an efficient curriculum over auxiliary objectives. This is to be contrasted with ELLA [23] where expert knowledge is required for choosing auxiliary objectives. Besides, we do not call upon an oracle for getting linguistic description of environment states as in [25].
+
+Limitations and Future Work EAGER assumes the QA system was pre-trained using a pre-existing set of example trajectories. Next steps will consist in investigating how to remove this limitation, e.g. by implementing autotelic strategies based on QG/QA learned online. Besides, in this work we tested our method on BabyAI, a 2D environment with synthetic language. In the future, we would like to consider a more complex language, generating more complex questions than the one obtained by masking, and testing our method on more realistic environments with true human instructions, as in the ALFRED dataset [32].
+
+# Acknowledgments and Disclosure of Funding
+
+This work benefited from the use of the Jean Zay supercomputer associated with the Genci grant A0091011996, as well as from the ANR DeepCuriosity AI chair project.
+
+This work has been supported by the Horizon 2020 PILLAR-robots project (grant number 101070381)
+
+# References
+
+[1] Ahmed Akakzia, Cédric Colas, Pierre-Yves Oudeyer, Mohamed Chetouani, and Olivier Sigaud. Grounding language to autonomously-acquired skills via goal generation. arXiv preprint arXiv:2006.07185, 2020.
+[2] Peter Anderson, Qi Wu, Damien Teney, Jake Bruce, Mark Johnson, Niko Sünderhauf, Ian Reid, Stephen Gould, and Anton van den Henge. Vision-and-language navigation: Interpreting visually-grounded navigation instructions in real environments. In CVPR, 2018.
+[3] J. Andreas, D. Klein, and S. Levine. Modular multitask reinforcement learning with policy sketches. In International Conference on Machine Learning (ICML), 2017.
+[4] Arthur Aubret, Laetitia Matignon, and Salima Hassas. A survey on intrinsic motivation in reinforcement learning. arXiv preprint arXiv:1908.06976, 2019.
+[5] Dzmitry Bahdanau, Felix Hill, Jan Leike, Edward Hughes, Arian Hosseini, Pushmeet Kohli, and Edward Grefenstette. Learning to understand goal specifications by modelling reward. In arXiv preprint arXiv:1806.01946, 2018.
+[6] Marc Bellemare, Sriram Srinivasan, Georg Ostrovski, Tom Schaul, David Saxton, and Remi Munos. Unifying count-based exploration and intrinsic motivation. Advances in neural information processing systems, 29, 2016.
+[7] Maxime Chevalier-Boisvert, Dzmitry Bahdanau, Salem Lahlou, Lucas Willems, Chitwan Sahara, Thien Huu Nguyen, and Yoshua Bengio. Babyai: A platform to study the sample efficiency of grounded language learning. In International Conference on Learning Representations (ICLR), 2019.
+[8] K. Cobbe, C. Hesse, J. Hilton, and J. Schulman. Leveraging procedural generation to benchmark reinforcement learning. In International Conference on Machine Learning (ICML), 2020.
+[9] Cédric Colas, Tristan Karch, Olivier Sigaud, and Pierre-Yves Oudeyer. Autotelic agents with intrinsically motivated goal-conditioned reinforcement learning: a short survey. Journal of Artificial Intelligence Research, 2022.
+[10] Cédric Colas, Tristan Karch, Nicolas Lair, Jean-Michel Dussoux, Clément Moulin-Frier, Peter Ford Dominey, and Pierre-Yves Oudeyer. Language as a cognitive tool to imagine goals in curiosity-driven exploration. In Advances in Neural Information Processing Systems (NeurIPS), 2020.
+[11] Alison Gopnik and Andrew Meltzoff. The development of categorization in the second year and its relation to other cognitive and linguistic developments. In Child development, 1987.
+[12] Goyal, Niekum, and Mooney. Using natural language for reward shaping in reinforcement learning. In International Joint Conference on Artificial Intelligence (IJCAI), 2019.
+[13] M. Hausknecht and P. Stone. Deep recurrent q-learning for partially observable mdps. In arXiv preprint arXiv:1507.06527, 2015.
+[14] Karl Moritz Hermann, Felix Hill, Simon Green, Fumin Wang, Ryan Faulkner, Hubert Soyer, David Szepesvari, Wojciech Marian Czarnecki, Max Jaderberg, and Denis Teplyashin. Grounded language learning in a simulated 3d world. In arXiv preprint arXiv:1706.06551, 2017.
+[15] Hengyuan Hu, Denis Yarats, Qucheng Gong, Yuandong Tian, and Mike Lewis. Hierarchical decision making by generating and following natural language instructions. In arXiv preprint arXiv:1906.00744, 2019.
+[16] U. Jain, S. Lazebnik, and A. G. Schwing. Two can play this game: Visual dialog with discriminative question generation and answering. In Proc. CVPR, 2018.
+[17] Y. Jiang, S. S. Gu, K. P. Murphy, and C. Finn. Language as an abstraction for hierarchical deep reinforcement learning. In Advances in Neural Information Processing Systems (NeurIPS), 2019.
+
+[18] Stefano Ermon Jonathan Ho. Generative adversarial imitation learning. In arXiv preprint arXiv:1606.03476v1, 2016.
+[19] Iou-Jen Liu, Xingdi Yuan, Marc-Alexandre Côté, Pierre-Yves Oudeyer, and Alexander G. Schwing. Asking for knowledge: Training rl agents to query external knowledge using language. In International Conference on Machine Learning (ICML), 2022.
+[20] Jelena Luketina, Nantas Nardelli, Gregory Farquhar, Jakob Foerster, Jacob Andreas, Edward Grefenstette, Shimon Whiteson, and Tim Rocktäschel. A survey of reinforcement learning informed by natural language. arXiv preprint arXiv:1906.03926, 2019.
+[21] C. Lynch and P. Sermanet. Grounding language in play. In arXiv preprint arXiv:2005.07648, 2020.
+[22] Hongyuan Mei, Mohit Bansal, and Matthew R. Walter. Listen, attend, and walk: Neural mapping of navigational instructions to action sequences. In Association for the Advancement of Artificial Intelligence (AAAI), 2016.
+[23] Suvir Mirchandani, Siddharth Karamcheti, and Dorsa Sadigh. Ella: Exploration through learned language abstraction. In Advances in Neural Information Processing Systems (NeurIPS), 2021.
+[24] Dipendra Misra, John Langford, and Yoav Artzi. Mapping instructions and visual observations to actions with reinforcement learning. In arXiv preprint arXiv:1704.08795v2, 2017.
+[25] Jesse Mu, Victor Zhong, Roberta Raileanu, Minqi Jiang, Noah Goodman, Tim Rocktäschel, and Edward Grefenstette. Improving intrinsic exploration with language abstractions. In arXiv preprint arXiv:2202.08938v1, 2022.
+[26] A. Y. Ng, D. Harada, and S. Russell. Policy invariance under reward transformations: Theory and application to reward shaping. In International Conference on Machine Learning (ICML), volume 99, pages 278-287, 1999.
+[27] Alexander Pashevich, Cordelia Schmid, and Chen Sun. Episodic transformer for vision-and-language navigation. In arXiv preprint arXiv:2105.06453v2, 2021.
+[28] Roberta Raileanu and Tim Rocktäschel. Ride: Rewarding impact-driven exploration for procedurally-generated environments. In International Conference on Learning Representations (ICLR), 2020.
+[29] Clement Rebuffel, Thomas Scialom, Laure Soulier, Benjamin Piwowarski, Sylvain Lamprier, Jacopo Staiano, Geoffrey Scoutheeten, and Patrick Gallinari. Data-QuestEval: A referenceless metric for data-to-text semantic evaluation. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 8029-8036, Online and Punta Cana, Dominican Republic, November 2021. Association for Computational Linguistics. doi: 10.18653/v1/2021.emnlp-main.633. URL https://aclanthology.org/2021.emnlp-main.633.
+[30] J. Schulman, F. Wolski, P. Dhariwal, A. Radford, and O. Klimov. Proximal policy optimization algorithms. In arXiv preprint arXiv:1707.06347, 2017.
+[31] Thomas Scialom, Paul-Alexis Dray, Patrick Gallinari, Sylvain Lamprier, Benjamin Piwowarski, Jacopo Staiano, and Alex Wang. Questeval: Summarization asks for fact-based evaluation. In arXiv preprint arXiv:2103.12693v2, 2021.
+[32] Mohit Shridhar, Jesse Thomason, Daniel Gordon, Yonatan Bisk, Winson Han, Roozbeh Mottaghi, Luke Zettlemoyer, and Dieter Fox. Alfred: A benchmark for interpreting grounded instructions for everyday tasks. In arXiv preprint arXiv:1912.01734v2, 2019.
+[33] R. S. Sutton and A. G. Barto. Reinforcement Learning: An Introduction. MIT press, 2018.
+[34] Allison C Tam, Neil C Rabinowitz, Andrew K Lampinen, Nicholas A Roy, Stephanie CY Chan, DJ Strouse, Jane X Wang, Andrea Banino, and Felix Hill. Semantic exploration from language abstractions and pretrained representations. arXiv preprint arXiv:2204.05080, 2022.
+
+[35] Nicholas Waytowich, Sean L. Barton, Vernon Lawhern, and Garrett Warnell. A narration-based reward shaping approach using grounded natural language commands. In International Conference on Machine Learning (ICML), 2019.
+[36] Yunqiu Xu, Meng Fang, Ling Chen, Yali Du, Joey Tianyi Zhou, and Chengqi Zhang. Perceiving the world: Question-guided reinforcement learning for text-based games. In arXiv preprint arXiv:2204.09597v2, 2022.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes] See the Method and Experiments Section 4 and 5.
+(b) Did you describe the limitations of your work? [Yes] See the Limitations paragraph of in Section 6
+(c) Did you discuss any potential negative societal impacts of your work? [N/A] We do not foresee major negative societal impacts of this work.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] We do believe our work conforms to them.
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] We give the URL in the introduction.
+(b) Did you specify all training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See the Section 5 and the Appendix
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] We ran our main experiments with multiple random seeds and plotted curves with standard deviations.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See the end of section 5.1
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] We use open-source environments, cited in the code and in the paper text.
+(b) Did you mention the license of the assets? [Yes] We inherit the license in our attached code repository.
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We include the code of our approach
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/images.zip b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..b736e5919f0b01efcbb671b1df5c1c33c7295461
--- /dev/null
+++ b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:14d70be131b5cc61d5901b8310c5335ef1b5b96663f370f24cb1624cd8591136
+size 303160
diff --git a/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/layout.json b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..c292eb072947a1092a165f0b777baedfe8a0dd10
--- /dev/null
+++ b/eageraskingandansweringquestionsforautomaticrewardshapinginlanguageguidedrl/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:33f44c56367ddbd64d16d4851a395fec49dc33b597810bb84e5bd71cf002fe19
+size 409749
diff --git a/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/6e7fe23e-7294-455d-9331-9f81bda58ae7_content_list.json b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/6e7fe23e-7294-455d-9331-9f81bda58ae7_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..c78df74e932f41cddbb91d2f6ba65d026116cd3c
--- /dev/null
+++ b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/6e7fe23e-7294-455d-9331-9f81bda58ae7_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ff98524c95fd5c8c595c4524dad39f59d4e7d89dcae640e0b21e7deadae1c1cd
+size 92472
diff --git a/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/6e7fe23e-7294-455d-9331-9f81bda58ae7_model.json b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/6e7fe23e-7294-455d-9331-9f81bda58ae7_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..a4760df5a2a92cd1827668f6af1bdf03a31f5c62
--- /dev/null
+++ b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/6e7fe23e-7294-455d-9331-9f81bda58ae7_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2e4feb5801cf5aa98a611269d332f2b3a1364912d0d17838ee372761a22ece1e
+size 117440
diff --git a/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/6e7fe23e-7294-455d-9331-9f81bda58ae7_origin.pdf b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/6e7fe23e-7294-455d-9331-9f81bda58ae7_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..86ec4c56caa8bd90a8822e2f1ce31fb55263d06a
--- /dev/null
+++ b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/6e7fe23e-7294-455d-9331-9f81bda58ae7_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2145ae7cc284b87b50630c3f81bbe038d2a9e026893e62d79d2ee9d950305c9c
+size 988449
diff --git a/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/full.md b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..fc15a2b04d41211d361d45ac24d1e12c99229294
--- /dev/null
+++ b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/full.md
@@ -0,0 +1,443 @@
+# Early Stage Convergence and Global Convergence of Training Mildly Parameterized Neural Networks
+
+Mingze Wang
+
+School of Mathematical Sciences
+
+Peking University
+
+Beijing, 100081, P.R. China
+
+mingzewang@stu.pku.edu.cn
+
+Chao Ma
+
+Department of Mathematics
+
+Stanford University
+
+Stanford, CA 94305
+
+chaoma@stanford.edu
+
+# Abstract
+
+The convergence of GD and SGD when training mildly parameterized neural networks starting from random initialization is studied. For a broad range of models and loss functions, including the most commonly used square loss and cross entropy loss, we prove an "early stage convergence" result. We show that the loss is decreased by a significant amount in the early stage of the training, and this decrease is fast. Furthermore, for exponential type loss functions, and under some assumptions on the training data, we show global convergence of GD. Instead of relying on extreme over-parameterization, our study is based on a microscopic analysis of the activation patterns for the neurons, which helps us derive more powerful lower bounds for the gradient. The results on activation patterns, which we call "neuron partition", help build intuitions for understanding the behavior of neural networks' training dynamics, and may be of independent interest.
+
+# 1 Introduction
+
+As deep learning shows its capability in various fields of applications, extensive researches are done to theoretically understand and explain its great success. Among the topics covered by these theoretical studies, the optimization of deep neural networks is one of the most crucial one, especially given the fact that simple optimization algorithms such as Gradient Descent (GD) and Stochastic Gradient Descent (SGD) can easily achieve zero training loss (Zhang et al., 2017), although the loss landscape of training neural networks is highly non-convex (Li et al., 2018; Sun et al., 2020). Existing works attempting to answer the surprising convergence ability usually work in settings that do not align well with realistic practices. For example, the notable Neural Tangent Kernel (NTK) theory (Jacot et al., 2018; Du et al., 2018; 2019; Allen-Zhu et al., 2019b; Zou et al., 2018) shows the global convergence of SGD in highly over-parameterized regime, in which the loss landscape is approximated by a quadratic function. In practice, though, the loss landscape is indeed highly non-convex with spurious local minima and saddle points (Safran and Shamir, 2018; Safran et al., 2021), and the dynamics of neurons show nonlinear behaviors (Ma et al., 2020).
+
+Nevertheless, fast decreasing of the loss value always happens when the network trained is not highly over-parameterized, at least in the early stage of training. It is common that the loss experiences a drastic decreasing at the beginning of the training. In many cases, this decrease of loss even continues until the loss achieves zero, i.e. the optimization algorithm fully converges. In this paper, we study the early stage or full convergence of GD and SGD when under-parameterized or mildly over-parameterized models are trained. Specifically, we answer the following two theoretical questions:
+
+When we train practical-size neural networks by $GD$ or $SGD$ ,
+
+1. Does the fast convergence in the early stage of the training provably exist? If so, how
+
+long will the phenomenon last and how much will loss descend in the early stage?
+
+2. Can the global convergence be proved under some special conditions on loss function and training data?
+
+Our answers to the questions above are roughly summarized in the following main theorems:
+
+Main Theorem 1 (Informal statement of Theorem 4.2 and 4.6). For mildly over-parameterized or under-parameterized two-layer neural networks with quadratic loss or general classification loss (Assumption 4.4), let parameters be trained by $GD$ or SGD started with random initialization. If the learning rate $\eta \leq 0.01$ , then in the first $\Theta(1/\eta)$ iterations, the loss will descend $\Omega(1)$ .
+
+Main Theorem 2 (Informal statement of Theorem 5.2 and 5.3). For mildly over-parameterized or under-parameterized two-layer neural networks with exponential-type loss (Assumption 5.1), let parameters be trained by $GD$ with random initialization and proper learning rate. If data is well-separated (satisfies Assumption 4.1), the loss converges to 0 at exponential rate or arbitrary polynomial rate, depending on the conditions.
+
+In the first main theorem, we demonstrate that the fast convergence in the early stage of training happens under weak conditions. The model does not need to be highly over-parameterized, and the loss function can take quite general forms. In the second main theorem, we further prove the full convergence of GD for exponential-type loss and well-separated dataset. These assumptions on the loss function and training data are close to practice and widely picked by previous theoretical studies (Ji and Telgarsky, 2018; 2020; Phuong and Lampert, 2020; Chatterji et al., 2021b; a; Lyu and Li, 2019; Lyu et al., 2021). "Full convergence" means that our analysis covers all the stages of the training process, starting from initialization to the convergence to zero loss. This is different from existing works which focus on the convergence process after the training accuracy hits $100\%$ (Lyu and Li, 2019; Ji and Telgarsky, 2020; Chatterji et al., 2021b). Moreover, we provide the convergence rate of GD for two classes of neural networks.
+
+During the theoretical analysis, we study the dynamics of neurons in detail and capture the effect of each sample on each neuron. We call our results "neuron partition", which provides a accurate description to the behavior of neurons. With the neuron partition results, we derive a novel gradient lower bound for mildly parameterized neural networks, which is vital for the convergence results. The neuron partition also provides rich intuition for how the convergence happens. When GD or SGD is used with small initialization, the network is initially close to the saddle point at 0, which might be hard for GD to escape. However, neurons will adjust their directions rapidly and enter a good region which contains neither spurious local minima nor saddle points. Then, neurons will keep moving through the right directions for $\Theta(1/\eta)$ iterations, during which the loss descends quickly and significantly. For exponential-type loss and well-separated training data, the second stage will proceed uninterrupted until training is stopped.
+
+# 2 Related Work
+
+Due to the highly non-convex loss landscape (Li et al., 2018; Sun et al., 2020), classical optimization theories such as convex optimization fail to characterize the convergence of training neural networks. Researchers have proposed theories specifically for neural networks. We list some below.
+
+A popular line of works focus on the highly over-parameterized neural networks and derive the "Neural target kernel (NTK)" theory. In the NTK regime (Jacot et al., 2018; Du et al., 2018; 2019; Allen-Zhu et al., 2019a;b; Arora et al., 2019a;b; Daniely, 2017; Zou et al., 2018; Li and Liang, 2018; Chizat et al., 2019; E et al., 2019; 2020), the neural network model is close to a kernel method, leading to the nearly convex optimization landscape. Global convergence is proven in this regime. Besides, for highly over-parameterized neural networks, the mean-field approach (Chizat and Bach, 2018; Mei et al., 2018; 2019) is another line, which analyze the training dynamics by Wasserstein gradient flow.
+
+However, the NTK regime is different from real practical neural networks in several aspects. First, practical neural networks are often mildly over-parameterized rather than highly over-parameterized (Livni et al., 2014). Second, the landscape for practical neural networks is usually more complicated, containing local minima and saddle points (Safran and Shamir, 2018; Safran et al., 2021; Ding et al., 2019). Finally, the empirical superiority of neural networks over kernel methods is obvious. For
+
+example, neural networks can learn single neuron efficiently (Yehudai and Ohad, 2020; Wu, 2022), while kernel methods fail unless the network size is exponentially large with respect to the input dimension (Yehudai and Shamir, 2019).
+
+Furthermore, optimization theories for neural networks beyond the NTK regime has also been studied. Safran and Shamir (2018); Ding et al. (2019) proved that spurious local minima are common in the loss landscape. Safran et al. (2021) pointed out that neither one-point convexity nor Polyak-Łojasiewicz condition holds near the global minimum. In (Lyu and Li, 2019; Ji and Telgarsky, 2020; Chatterji et al., 2021b;a; Zhou et al., 2021), local convergence results are given with cross-entropy loss or some special networks at the late stage of training, i.e. when training loss is small enough. In (Li et al., 2020; Phuong and Lampert, 2020; Lyu et al., 2021; Jentzen and Riekert, 2021; Cheridito et al., 2022), global convergence results are given for some special networks, special data distribution or special target functions.
+
+# 3 Preliminaries
+
+# 3.1 Notations
+
+We use bold letters for vectors or matrices and lowercase letters for scalars, e.g. $\pmb{x} = (x_{1},\dots ,x_{d})^{\top}\in$ $\mathbb{R}^d$ and $\mathbf{P} = (P_{ij})_{m_1\times m_2}\in \mathbb{R}^{m_1\times m_2}$ . We use $\langle \cdot ,\cdot \rangle$ for the standard Euclidean inner product between two vectors, and $\| \cdot \|$ for the $l_{2}$ norm of a vector or the spectral norm of a matrix. We use $a\lesssim b$ to indicate that there exists an absolute constant $c > 0$ such that $a\leq cb$ , and $a\gtrsim b$ is similarly defined. We use standard progressive representation $\mathcal{O},\Omega ,\Theta$ to hide absolute constants. For any positive integer $n$ , let $[n] = \{1,\dots ,n\}$ . Denote by $\mathcal{N}(\boldsymbol {\mu},\boldsymbol {\Sigma})$ the Gaussian distribution with mean $\pmb{\mu}$ and covariance matrix $\pmb{\Sigma}$ , $\mathbb{U}(S)$ the uniform distribution on a set $S$ . Denote by $\mathbb{I}\{E\}$ the indicator function for an event $E$ . For a square matrix $P$ , we use $\lambda_{\mathrm{min}}(\mathbf{P})$ to denote its smallest singular value.
+
+# 3.2 Problem settings
+
+In this paper, we consider supervised learning problems. Let $\mathcal{P}$ be a data distribution on $\mathbb{R}^d\times \mathbb{R}^C$ . We are given $n$ training data $\mathcal{S} = \{(x_i,y_i)\}_{i = 1}^n\subset \mathbb{R}^d\times \mathbb{R}^C$ drawn i.i.d. from $\mathcal{P}$ . Without loss of generality, we assume $\| \pmb {x}\| \leq 1$ for any $(\pmb {x},\pmb {y})$ sampled from $\mathcal{P}$ .
+
+We consider the empirical risk minimization (ERM) problem, which tries to minimize the empirical risk $\mathcal{L}(\cdot)$ with loss function $\ell (\cdot ,\cdot)$ :
+
+$$
+\mathcal {L} (\boldsymbol {\theta}) = \frac {1}{n} \sum_ {i = 1} ^ {n} \ell \left(\boldsymbol {y} _ {i}, \boldsymbol {f} \left(\boldsymbol {x} _ {i}; \boldsymbol {\theta}\right)\right), \tag {1}
+$$
+
+where $\pmb{f}(\pmb{x};\pmb{\theta}) \in \mathbb{R}^{C}$ is the model and $\pmb{\theta}$ represents all parameters of the model. We will give specific forms to the loss function and the model in the analysis in later sections.
+
+We use Gradient Descent (GD) or Stochastic Gradient Descent (SGD) starting from random initialization to solve the ERM problem. The update rules of GD or batch SGD can be written as:
+
+$$
+\mathbf {G D}: \quad \boldsymbol {\theta} (t + 1) = \boldsymbol {\theta} (t) - \eta_ {t} \nabla \mathcal {L} (\boldsymbol {\theta} (t)), \tag {2}
+$$
+
+$$
+\mathbf {S G D}: \quad \boldsymbol {\theta} (t + 1) = \boldsymbol {\theta} (t) - \frac {\eta_ {t}}{B} \sum_ {i \in \mathcal {B} _ {t}} \nabla \ell \left(\boldsymbol {y} _ {i}, f \left(\boldsymbol {x} _ {i}; \boldsymbol {\theta} (t)\right)\right), \tag {3}
+$$
+
+where $\mathcal{B}_t = \{\gamma_{t,1},\dots ,\gamma_{t,B}\}$ is a batch, and $\gamma_{t,1},\dots ,\gamma_{t,B}\stackrel {\mathrm{i.i.d.}}{\sim}\mathbb{U}([n])$ and are independent with $\pmb {\theta}(t)$ . The random initialization will be specified in each theorem.
+
+# 4 Early Stage Convergence
+
+In this section, we state and discuss our main results on the fast convergence in the early stage of training. The models we focus on are mildly over-parameterized or under-parameterized neural networks. As a warm up, in Section 4.1, we study a simple case with binary classification problems and quadratic loss. Then, in Section 4.2, we extend our results to multi-class classification problems with general loss and one-hot labels. We provide discussions to our results in Section 4.3.
+
+# 4.1 Binary classification with quadratic loss
+
+In this subsection, we study the ERM problem (1) with quadratic loss $\ell(y_1, y_2) = \frac{1}{2}(y_1 - y_2)^2$ and the two-layer ReLU neural network model without bias:
+
+$$
+f (\boldsymbol {x}; \boldsymbol {\theta}) = \sum_ {k = 1} ^ {m} a _ {k} \sigma \left(\boldsymbol {b} _ {k} ^ {\top} \boldsymbol {x}\right), \tag {4}
+$$
+
+where $\sigma (z) = \mathrm{ReLU}(z),\pmb {\theta} = (a_1,\dots ,a_m,\pmb {b}_1^\top ,\dots ,\pmb {b}_m^\top)^\top \in \mathbb{R}^{dm + m}$ . We consider the following random initialization
+
+$$
+a _ {k} (0) \stackrel {\text {i . i . d .}} {\sim} \mathbb {U} (\pm 1 / \sqrt {m}), \quad \boldsymbol {b} _ {k} (0) \stackrel {\text {i . i . d .}} {\sim} \mathcal {N} (\boldsymbol {0}, \frac {\kappa^ {2}}{m d} \mathbf {I} _ {d}), \quad \text {f o r} k \in [ n ], \tag {5}
+$$
+
+where $\kappa$ is a constant that controls the initial scale of the first layer.
+
+We focus on the training data with two classes with good separation given by the following assumption.
+
+Assumption 4.1. (i) $n$ is even. $y_{i} = 1$ for $i\in [n / 2]$ ; $y_{i} = -1$ for $i\in [n] - [n / 2]$ . $\pmb{x}_i^\top \pmb{x}_j\geq 0$ for $i,j$ in the same class; $\pmb{x}_i^\top \pmb{x}_j\leq 0$ for $i,j$ in different classes. (ii) There exists a constant $\mu_0 > 0$ , s.t. $\min_{\{i\in [n],\pmb {v}\in \mathbb{R}^d |\pmb{v}^\top \pmb{x}_i\leq 0\}}\max_{\{j\in [n]|\pmb{v}^\top \pmb{x}_j > 0\}}y_i\pmb{x}_i^\top \pmb{x}_jy_j\geq \mu_0.$
+
+For Assumption 4.1 (i), similar assumption has been used in prior works (Phuong and Lampert, 2020). For image classification problems, this assumption can be ensured by a simple transformation on the data due to the non-negative pixels of images. Specifically, given an image dataset consisted of two classes, we just need to replace $\pmb{x}$ with $-\pmb{x}$ for any $(\pmb{x}, y)$ in the second class. Assumption 4.1 (ii) is a technical assumption used in the analysis. It is not a strong addition over Assumption 4.1 (i). For example, if there exists a $(x_0, y_0)$ in the dataset $S$ such that $(-x_0, -y_0)$ is also in $S$ , then the dataset $S$ satisfies Assumption 4.1 (ii) with $\mu_0 = 1$ (the upper bound of $\mu_0$ is 1). Admittedly, this technical assumptions is a limitation of our theory—it restricts its applicability. We will search for the relaxation of this assumption in future works.
+
+Now we state the following result.
+
+Theorem 4.2. Suppose Assumption 4.1 holds. Let $\theta(t)$ be the parameters of model (4) trained by Gradient Descent (2) with quadratic loss. If the width $m = \Omega(\log(n/\delta))$ , the input dimension $d = \Omega(\log m)$ , the learning rate $\eta_t = \eta \leq 0.01$ and the initialization scale $\kappa = \mathcal{O}(\eta \mu_0 / n)$ in (5), then, with probability at least $1 - \delta - 2me^{-2d}$ , the loss will descend $\Omega(1)$ in $T = \Theta\left(\frac{1}{\eta}\right)$ iterations.
+
+From our proof in Appendix A, we have the following corollary with fixed numbers about $\eta, \kappa, m$ instead of progressive expressions.
+
+Corollary 4.3. Suppose Assumption 4.1 holds. Let $\theta(t)$ be the parameters of model (4) trained by Gradient Descent (2) with quadratic loss. Let $\eta = 0.01$ , $\kappa \leq \min\{\eta/2000, \eta \mu_0 / 3n\}$ , $m \geq \max\{144 \log(2n^2/\delta), 4\}$ , and $\gamma_1, \gamma_2 = \Theta(1)$ be constants related with the data distribution defined in (10) in Appendix A. Then, with probability at least $1 - \delta - 2me^{-2d}$ , in $T = 44$ iterations, loss will descend at least $0.193(\gamma_1 - \gamma_2 \sqrt{8 \log(n^2/\delta)/m}) - 0.0111 = \Omega(1 - \sqrt{\log(n/\delta)/m})$ .
+
+Conclusions in Theorem 4.2 show the meaning of "mildly parameterized" in our title. The network does not need to be over-parameterized, i.e. the number of parameters may be smaller than the number of training data. Hence, we pick the term "mildly parameterized" instead of the more widely use "mildly over-parameterized". The former is weaker than the latter.
+
+# 4.2 Multi-class classification with general loss and one-hot labels
+
+In this subsection, we extend the early stage convergence results above to more practical settings. Specifically, we consider classification problem with one-hot labels and the general loss functions that satisfy the following conditions.
+
+Assumption 4.4. The loss function $\ell(\cdot, \cdot)$ can be expressed as $\ell(\pmb{y}_1, \pmb{y}_2) = \tilde{\ell}(\pmb{y}_1^\top \pmb{y}_2)$ such that: (i) $\tilde{\ell}(\cdot)$ is twice differentiable in $\mathbb{R}$ ; (ii) $\tilde{\ell}(\cdot)$ is non-negative and non-increasing in $\mathbb{R}$ ; (iii) there exist $z_0 \in (0, 1]$ , $g_{\min}, g_{\max} > 0$ , $h_{\max} \geq 0$ such that $g_{\min} \leq -\tilde{\ell}'(z) \leq g_{\max}$ and $0 \leq \tilde{\ell}''(z) \leq h_{\max}$ hold for any $z \in [0, z_0]$ .
+
+It is easy to verify that exponential loss $\ell(\pmb{y}_1, \pmb{y}_2) = e^{-\pmb{y}_1^\top \pmb{y}_2}$ ( $z_0 = 1$ , $g_{\min} = \frac{1}{e}$ , $g_{\max} = 1$ , $h_{\max} = 1$ ), logistic loss $\ell(\pmb{y}_1, \pmb{y}_2) = \log (1 + e^{-\pmb{y}_1^\top \pmb{y}_2})$ ( $z_0 = 1$ , $g_{\min} = \frac{1}{e + 1}$ , $g_{\max} = \frac{1}{2}$ , $h_{\max} = \frac{1}{4}$ ) and hinge loss $\ell(\pmb{y}_1, \pmb{y}_2) = \max \{0, 1 - \pmb{y}_1^\top \pmb{y}_2\}$ ( $z_0 = 1$ , $g_{\min} = 1$ , $g_{\max} = 1$ , $h_{\max} = 0$ ) all satisfy the conditions in Assumption 4.4.
+
+On the training data, we impose the following assumption, which is milder than Assumption 4.1.
+
+Assumption 4.5. There exists $s > -1$ s.t. $\langle \pmb{x}_i, \pmb{x}_j \rangle \geq s$ for any $i, j \in [n]$ .
+
+Note that now we do not need any separability of training data, but only require there is no pair of data going into opposite directions. (We can even normalize the data and let $\| \pmb{x} \| < 1 - \epsilon$ for some $\epsilon > 0$ , rather than $\| \pmb{x} \| \leq 1$ . Then, the above assumption naturally holds.) Notably, Assumption 4.5 is more widely applicable than Assumption 4.1 above. It holds for normalized image datasets such as MNIST (LeCun et al., 1998) and CIFAR-10 (Krizhevsky et al., 2009).
+
+For the model, we use the two-layer ReLU neural network model with bias as our prediction model:
+
+$$
+\boldsymbol {f} (\boldsymbol {x}; \boldsymbol {\theta}) = \sum_ {k = 1} ^ {m} \boldsymbol {a} _ {k} \sigma \left(\boldsymbol {b} _ {k} ^ {\top} \boldsymbol {x} + c _ {k}\right), \tag {6}
+$$
+
+where $\sigma (z) = \mathrm{ReLU}(z)$ , $\pmb{a}_k\in \mathbb{R}^C$ and $\pmb{\theta} = (\pmb{a}_1^\top ,\dots ,\pmb{a}_m^\top ,\pmb{b}_1^\top ,\dots ,\pmb{b}_m^\top ,c_1,\dots ,c_m)^\top \in \mathbb{R}^{(d + C + 1)m}$ . We consider random initialization $\pmb {b}_k(0)\stackrel {\mathrm{i.i.d.}}{\sim}\mathcal{N}(\mathbf{0},\frac{\kappa^2}{m(d + 1)}\mathbf{I}_d)$ , $c_{k}(0) = \frac{\kappa}{\sqrt{m(d + 1)}}$ , and $\pmb {a}_k(0) = (1 / \sqrt{m},\dots ,1 / \sqrt{m})^\top$ for $k\in [m]$ , where $\kappa$ is again a constant that controls the initial scale of the first layer.
+
+We show the following convergence result:
+
+Theorem 4.6. Under Assumption 4.4 and 4.5, let $\theta(t)$ be the parameters of model (6) trained by Stochastic Gradient Descent (3). If the width $m = \Omega(1)$ , the input dimension $d = \Omega(\log m)$ , the batch size $B = \Omega(\log m)$ , the learning rate $\eta_t = \eta \leq 0.01$ and the initialization scale $\kappa = \mathcal{O}(\eta / B)$ , then with probability at least $1 - \delta - \mathcal{O}(m e^{-d}) - \mathcal{O}(m 0.17^B)$ , the loss will descend $\Omega(1)$ in $T = \Theta\left(\frac{1}{\eta}\right)$ iterations.
+
+By our analysis in Appendix B, we have the following corollary which gives specific numbers about $\eta, \kappa, m$ instead of progressive expression.
+
+Corollary 4.7. Under the same assumptions as Theorem 4.6, let $\theta(t)$ be the parameters of the model (6) trained by SGD (3). Let $\eta = 0.01$ , $\kappa \leq \min\{\eta/10, \eta/3B\}$ , $m \geq 6$ ; $z_0 = 1$ , $g_{\min} = \frac{1}{2}$ , $g_{\max} = 1$ , $h_{\max} = 1$ (in Assumption 4.4) and $s = 0$ (in Assumption 4.5). Then, with probability at least $1 - \delta - 4me^{-\frac{d + 1}{2}} - m0.17^B$ , in $T = 34$ iterations, loss will descend at least $0.262533 = \Omega(1)$ .
+
+We remark here that the weaker Assumption 4.5 in this subsection compared with the Assumption 4.1 before is made possible by the one-hot labels. For one-hot labels, each label component is non-negative. Hence, neural networks can quickly learn a positive bias, allowing the loss to drop significantly.
+
+# 4.3 Discussion
+
+A large number of classical convergence analysis focus on the late stage of training. For neural networks' optimization, many works focus on the period of training after the loss is smaller enough (Lyu and Li, 2019; Ji and Telgarsky, 2020; Chatterji et al., 2021b; Zhou et al., 2021). However, the early stage is at least as important as the late stage, especially for non-convex problems.
+
+The theoretical results we present in this section demonstrate the fast convergence during the early stage of optimization, i.e. the (short) period of time after the initialization. The two main results, Theorem 4.2 and 4.6, imply that if we train two-layer neural networks by GD or SGD with learning rate $\eta \leq 0.01$ , then the loss will descend significantly $(\Omega(1))$ in the first $T = \Theta(1/\eta)$ iterations.
+
+Our results work under realistic settings. For models, our results hold for mildly over-parameterized and under-parameterized neural networks, because we only need the width $m = \Omega (\log (n / \delta))$ . For loss functions, our results apply for practical losses, such as quadratic loss and cross entropy loss. On the algorithm side, the results work for both GD (2) and SGD (3).
+
+Though both concerning convergence of GD and SGD, our results are essentially different from the NTK theory, especially on the requirement of over-parameterization. Our results only need $m = \Omega (\log (n / \delta))$ , while in the NTK analysis usually assumes that $m$ is polynomial in $n, 1 / \kappa$ or etc, excluding the practical settings. Moreover, from the analysis side, we establish fine-grained analysis of the training dynamics of each neuron, which may be of independent interested. See Section 6 for a summary of our techniques, and Appendix A and B for the detailed proof. Our analysis helps understand how the convergence in the early stage happens. When GD or SGD is used with small initialization, the initial network is close to the saddle point at 0. However, neurons will adjust directions rapidly, and the iterator will enter a good region which contains neither spurious local minima nor saddle points. Then, neurons will keep going towards the right directions for a period of time, during which process the loss will descend fast and significantly.
+
+# 5 Global Convergence
+
+When stronger conditions are imposed on the data distribution and the loss function, we can show global convergence of GD, i.e. starting from any initialization, the GD descends the loss to 0.
+
+For loss functions, we consider the following exponential-type classification loss:
+
+Assumption 5.1. The loss function $\ell(\cdot, \cdot)$ can be expressed as $\ell(\pmb{y}_1, \pmb{y}_2) = \tilde{\ell}(\pmb{y}_1^\top \pmb{y}_2)$ such that: (i) $\tilde{\ell}(\cdot)$ is twice continuously differentiable in $\mathbb{R}$ ; (ii) $\tilde{\ell}(\cdot)$ is positive and non-increasing in $\mathbb{R}$ ; (iii) there exist $g_b > 0$ , $h \geq 0$ s.t. $-\frac{\tilde{\ell}'(z)}{\tilde{\ell}(z)} \leq g_b$ and $0 \leq \frac{\tilde{\ell}''(z)}{\tilde{\ell}(z)} \leq h$ for any $z \in \mathbb{R}$ ; (iv) there exists $g_a > 0$ , s.t. $g_a \leq -\frac{\tilde{\ell}'(z)}{\tilde{\ell}(z)}$ for any $z \geq 0$ .
+
+The similar assumption on exponential-type loss has been used in prior works (Lyu and Li, 2019). It is easy to verify that both exponential loss $\ell(\pmb{y}_1, \pmb{y}_2) = e^{-\pmb{y}_1^\top \pmb{y}_2}$ ( $g_a = g_b = h = 1$ ) and logistic loss $\ell(\pmb{y}_1, \pmb{y}_2) = \log(1 + e^{-\pmb{y}_1^\top \pmb{y}_2})$ ( $g_a = \frac{1}{2}, g_b = 1, h = 1$ ) satisfy the conditions in Assumption 5.1.
+
+Let $V$ be a constant defined as
+
+$$
+V = \frac {1}{1 6} \left(\frac {1}{2} - \sqrt {\frac {8 \log (n ^ {2} / \delta)}{m}}\right) \max \left\{\frac {2}{n} + \frac {n - 2}{n} \gamma , \lambda_ {\min } \left(\mathbf {X} _ {+} ^ {\top} \mathbf {X} _ {+}\right) \wedge \lambda_ {\min } \left(\mathbf {X} _ {-} ^ {\top} \mathbf {X} _ {-}\right) \right\}, \tag {7}
+$$
+
+where $\mathbf{X}_{+} := (\pmb{x}_{1},\dots,\pmb{x}_{\frac{n}{2}}) \in \mathbb{R}^{d \times \frac{n}{2}}$ , $\mathbf{X}_{-} := (\pmb{x}_{\frac{n}{2} + 1},\dots,\pmb{x}_{n}) \in \mathbb{R}^{d \times \frac{n}{2}}$ , and $\gamma := \min_{i,j \text{ in the same class}} \pmb{x}_{i}^{\top} \pmb{x}_{j} \geq 0$ . We have the following convergence theorems in which $V$ controls the convergence speed.
+
+Theorem 5.2. Under Assumption 5.1 and Assumption 4.1, let $\theta(t)$ be the parameters of model (4) trained by Gradient Descent (2) starting from random initialization (5). Let the width $m = \Omega(\log(n/\delta))$ , the initialization scale $\kappa = \mathcal{O}(\eta_0 \mu_0 / n)$ in (5), $V$ be defined in (7), $c$ be a constant in $(0, \frac{1}{6(1 + 2\eta_0)^2 + 2}]$ , the constant $c' > 0$ be sufficiently small, the hitting time $T_0 = \lceil (n \log 2)^{\frac{2}{Vc}} \rceil$ , the parameter $r \in [1, +\infty)$ and the learning rate satisfy
+
+$$
+\left\{ \begin{array}{l l} \eta_ {0} \leq 1 / 2 \sqrt {2}, & f o r t = 0 \\ \eta_ {t} = \frac {c}{t \mathcal {L} (\boldsymbol {\theta} (t))}, & f o r 1 \leq t < T _ {0} \\ \eta_ {t} = \frac {c ^ {\prime}}{\mathcal {L} (\boldsymbol {\theta} (t)) ^ {1 - \frac {1}{2 r}}}, & f o r t \geq T _ {0} \end{array} \right..
+$$
+
+Then, with probability at least $1 - \delta - 2me^{-2d}$ , $GD$ will converge at polynomial rate:
+
+$$
+\left\{ \begin{array}{l} \mathcal {L} (\boldsymbol {\theta} (t)) \leq \frac {\mathcal {L} (\boldsymbol {\theta} (1))}{t ^ {\frac {V _ {c}}{2}}}, \quad 1 \leq t < T _ {0} \\ \mathcal {L} (\boldsymbol {\theta} (t)) = \mathcal {O} \big (\frac {1}{t ^ {r}} \big), \quad t \geq T _ {0} \end{array} \right..
+$$
+
+Theorem 5.3. Under Assumption 5.1 and Assumption 4.1, let $\{\pmb{b}_k(t)\}_{k\in [m]}$ be the input layer parameters of model (4), and we only train this layer by Gradient Descent (2) starting from random initialization (5). Let the width $m = \Omega (\log (n / \delta))$ , the initialization scale $\kappa = \mathcal{O}(\eta_0\mu_0 / n)$ in (5), the constant $V$ be defined in (7), the constant $c\leq \frac{1}{2}$ and the learning rate satisfy
+
+$$
+\left\{ \begin{array}{l l} \eta_ {0} \leq 1 / 2 \sqrt {2}, & f o r t = 0 \\ \eta_ {t} = \frac {c}{\mathcal {L} (\boldsymbol {\theta} (t))}, & f o r t \geq 1 \end{array} \right..
+$$
+
+Then with probability at least $1 - \delta - 2me^{-2d}$ , $GD$ will converge at exponential rate:
+
+$$
+\mathcal {L} (\boldsymbol {\theta} (t)) \leq \left(1 - \frac {V c}{2}\right) ^ {t - 1} \mathcal {L} (\boldsymbol {\theta} (1)), \quad t \geq 1.
+$$
+
+Theorem 5.2 and 5.3 describe the whole training process starting from random initialization to convergence. If all parameters in the network are trained, we obtain the global convergence with arbitrary polynomial rate. On the other hand, if only the input layer parameters $\{b_k\}_{k\in [m]}$ are trained, we can obtain exponential convergence rate. Fixing some layers of the neural network is a common practice for theoretical studies (Chatterji et al., 2021b). The results show that adaptively increasing learning rate helps GD achieve faster convergence. Similar idea has been explored in previous works such as (Lyu and Li, 2019; Chatterji et al., 2021b).
+
+A similar convergence result was proven in (Phuong and Lampert, 2020). where the authors showed a global convergence result of two-layer neural networks trained by Gradient Flow (GF) with cross entropy loss and orthogonal separable data. The main difference between our results and analysis with that in (Phuong and Lampert, 2020) is that we study GD instead of GF. Due to the discretization, GD is more complicated than GF. For example, the balanced property of two layers $(\sum_{k\in [m]}|a_k(t)|^2 -\sum_{k\in [m]}\| \pmb {b}_k(t)\|^2\equiv 0,\forall t\geq 0)$ holds for GF throughout the training, but it does not hold for GD. Dealing with GD requires new analysis techniques and finer analysis, such as the neuron partition results we derive. Another related work is (Lakshminarayanan and Singh, 2020). The neural partition approach in our article shares some similarity with the view of gating networks. In their work, the authors use gating networks to understand the role of depth in training deep ReLU networks. By comparison, we focus more on the characterization of training dynamics of two-layer ReLU networks.
+
+# 6 Proof Sketch and Techniques
+
+# 6.1 Main techniques in the proof of Theorem 4.2
+
+Inspired by the empirical work (Ma et al., 2020), we study the nonlinear behavior of each neuron in the early stage of training. First, we define the hitting time $T$ , and we will study the convergence in the early stage $0 \leq t \leq T$ :
+
+$$
+T := \sup \left\{t \in \mathbb {N}: \max _ {i \in [ n ]} | f (\boldsymbol {x} _ {i}; \boldsymbol {\theta} (s)) | \leq 1, a _ {k} (s) a _ {k} (0) > 0, \forall k \in [ m ], \forall 0 \leq s \leq t + 1 \right\}.
+$$
+
+# 6.1.1 Neuron partition: fine-grained dynamical analysis of each neuron and each sample
+
+During our proof, we conduct fine-grained analysis to the interaction of neurons and samples. Specifically, we characterize the impact of each sample on each neuron, and for each sample classify neurons into four categories according to their effect. We call this analysis "neuron partition".
+
+For the $i$ -th training data $(x_{i},y_{i})$ , we divide all neurons into four categories during training $0\leq t\leq T$ and study them separately. We define the true-living neurons $\mathcal{T}\mathcal{L}_i(t)$ , the true-dead neurons $\mathcal{T}\mathcal{D}_i(t)$ , the false-living neurons $\mathcal{F}\mathcal{L}_i(t)$ and the false-dead neurons $\mathcal{FD}_i(t)$ at time $t$ as:
+
+$$
+\mathcal {T L} _ {i} (t) := \left\{k \in [ m ]: y _ {i} a _ {k} (t) > 0, \boldsymbol {b} _ {k} (t) ^ {\top} \boldsymbol {x} _ {i} > 0 \right\},
+$$
+
+$$
+\mathcal {T D} _ {i} (t) := \left\{k \in [ m ]: y _ {i} a _ {k} (t) > 0, \boldsymbol {b} _ {k} (t) ^ {\top} \boldsymbol {x} _ {i} \leq 0 \right\},
+$$
+
+$$
+\mathcal {F L} _ {i} (t) := \left\{k \in [ m ]: y _ {i} a _ {k} (t) < 0, \boldsymbol {b} _ {k} (t) ^ {\top} \boldsymbol {x} _ {i} > 0 \right\},
+$$
+
+$$
+\mathcal {F D} _ {i} (t) := \left\{k \in [ m ]: y _ {i} a _ {k} (t) < 0, \boldsymbol {b} _ {k} (t) ^ {\top} \boldsymbol {x} _ {i} \leq 0 \right\}.
+$$
+
+It is easy to verify $[m] = \mathcal{T}\mathcal{L}_i(t)\bigcup \mathcal{T}\mathcal{D}_i(t)\bigcup \mathcal{F}\mathcal{L}_i(t)\bigcup \mathcal{F}\mathcal{D}_i(t)$ (see Lemma A.1).
+
+Under a weak assumption on the width of the network, we have the following results for the neuron partition at initialization:
+
+Lemma 6.1 (Informal statement of Lemma A.2). If $m = \Omega (\log (n / \delta))$ , then with high probability, if data $i$ and data $j$ are in the same class, we have card $\bigl (\mathcal{T}\mathcal{L}_i(0)\cap \mathcal{T}\mathcal{L}_j(0)\bigr)\approx \frac{\pi - \operatorname{arccos}(\boldsymbol{x}_i^\top\boldsymbol{x}_j)}{4\pi} m.$
+
+The next important lemma characterizes the evolution of the neuron partition under GD dynamics.
+
+Lemma 6.2 (Informal Lemma A.4). With high probability, for any $i \in [n]$ and $t \leq T$ we have:
+(S1) True-living neurons remain true-living: $\mathcal{T}\mathcal{L}_i(t)\subset \mathcal{T}\mathcal{L}_i(t + 1)$
+(S2) False-dead neurons remain false-dead: $\mathcal{FD}_i(t)\subset \mathcal{FD}_i(t + 1)$
+(S3) True-dead neurons turn true-living in the first step $(t = 0)$ : $\mathcal{T}\mathcal{D}_i(0)\subset \mathcal{T}\mathcal{L}_i(1)$ .
+(S4) False-living neurons turn false-dead in the first step $(t = 0)$ : $\mathcal{FL}_i(0) \subset \mathcal{FD}_i(1)$ .
+(S5) For any $i \in [n]$ , $1 \leq t \leq T$ , $k \in [m]$ and $\pmb{b} \in \overline{\pmb{b}_k(t)\pmb{b}_k(t + 1)}$ , we have $\operatorname{sgn}(\pmb{b}^\top \pmb{x}_i) \equiv \operatorname{sgn}(\pmb{b}_k^\top (1)\pmb{x}_i) \neq 0$ .
+
+To interpret Lemma 6.2, we display the first-step dynamics in Figure 1.
+
+
+(a) $t = 0$
+
+
+(b) $t = 1$
+Figure 1: The first-step dynamics of four neurons which belong to different neuron partitions at $t = 0$ for sample $i$ (with label 1) and sample $j$ (with label $-1$ ). Fig 1(a) and Fig 1(b) depict the directions of each neuron at $t = 0$ and $t = 1$ , respectively. Results in Lemma 6.2 can be visualized: (S1) neuron $1 \in \mathcal{T}\mathcal{L}_i(0)$ and $1 \in \mathcal{T}\mathcal{L}_i(1)$ . (S2) neuron $4 \in \mathcal{F}\mathcal{D}_i(0)$ and $4 \in \mathcal{F}\mathcal{D}_i(1)$ . (S3) neuron $2 \in \mathcal{T}\mathcal{L}_j(0)$ and $2 \in \mathcal{T}\mathcal{L}_j(1)$ . (S4) neuron $2 \in \mathcal{F}\mathcal{L}_i(0)$ and $2 \in \mathcal{F}\mathcal{D}_i(1)$ . (Counterexample) By our Lemma, the first-step dynamics of neuron 3 cannot happen.
+
+# 6.1.2 Estimate of hitting time and parameters
+
+Before the analysis of loss descent, we need to estimate the hitting time $T$ and the speed of change for each $a_{k}, b_{k}$ in the early stage. Our tool is comparing the hitting time $T$ with an exponentially growing hitting time $T_{e}$ (see (12) in Appendix A).
+
+$$
+T _ {e} := \sup \left\{t \in \mathbb {N}: (1 + 2 \eta) ^ {2 (t + 1)} - (1 - 2 \eta) ^ {2 (t + 1)} \lesssim 1; (1 + 2 \eta) ^ {t + 1} \lesssim 1 \right\},
+$$
+
+where the order of magnitude of the two absolute constants hidden by $\lesssim$ is $10^0$ .
+
+Generally speaking, we can prove the following facts.
+
+Lemma 6.3 (Informal Lemma A.7 and A.8). For any sample $i \in [n]$ and $t \leq T_e$ , we have:
+
+(P1) For any $k \in \mathcal{T}\mathcal{L}_i(t)$ , $a_k(t)\mathrm{sgn}(a_k(0))$ is non-decreasing, and $a_k(t)$ , $b_k(t)$ have an exponential upper bound.
+
+(P2) For any $k \in [m]$ , $a_{k}(t)$ has an exponential lower bound.
+
+(P3) $f\big(\pmb {x}_i;\pmb {\theta}(t)\big)$ has an exponential upper bound.
+
+(P4) $T \geq T_e \geq T^* = \Theta(\frac{1}{\eta})$ .
+
+# 6.1.3 Gram matrix and gradient lower bound
+
+The gradient lower bound is usually an important technical component in the analysis of loss descent. Our analysis establishes a novel lower bound for the gradient for mildly parameterized neural networks based on the neuron partition.
+
+If we define the error for sample $i$ at $t$ as $e_i(t) = f(\pmb{x}_i; \pmb{\theta}(t)) - y_i$ , and the Gram matrix at $t$ as $\mathbf{G}(t) = (\nabla f(\pmb{x}_i; \pmb{\theta}(t))^{\top} \nabla f(\pmb{x}_j; \pmb{\theta}(t)))_{(i,j) \in [n] \times [n]}$ . For the analysis of GD, loss descent is
+
+determined by $\| \nabla \mathcal{L}(\pmb {\theta}(t))\|^2 = \sum_{i = 1}^n\sum_{j = 1}^n e_i(t)\mathrm{G}_{i,j}(t)e_j(t)$ . Qualitatively, bigger gradient leads to the faster descent of the loss. To derive a tight lower bound for the gradient, we first derive the following bound for the entries of the Gram matrix:
+
+Lemma 6.4 (Informal Lemma A.9). Under the condition of Theorem 4.2, with high probability, the Gram matrix $\mathbf{G}(t) = \begin{pmatrix} \mathbf{G}_{+}(t) & \mathbf{0}_{\frac{n}{2} \times \frac{n}{2}} \\ \mathbf{0}_{\frac{n}{2} \times \frac{n}{2}} & \mathbf{G}_{-}(t) \end{pmatrix}$ has the following form for any $1 \leq t \leq T$ and $i,j \in [\frac{n}{2}]$ : $G_{+}(t)_{i,j}$ , $G_{-}(t)_{i,j} \gtrsim \boldsymbol{x}_i^\top \boldsymbol{x}_j\left(\frac{\pi - \arccos(\boldsymbol{x}_i^\top \boldsymbol{x}_j)}{4\pi} - \mathcal{O}\left(\sqrt{\frac{\log(n / \delta)}{m}}\right)\right) > 0$ , where the order of magnitude of the absolute constant hidden by $\gtrsim$ is $10^0$ .
+
+Combining the estimate above as well as estimates on parameters and the prediction function, we establish our gradient lower bound.
+
+Lemma 6.5 (Informal Lemma A.10). For any $1 \leq t \leq T^{*}$ , $\| \nabla \mathcal{L}(\pmb{\theta}(t))\| = \Omega \big(1 - (1 + 2\eta)^{2t}\big)$ .
+
+Besides, since we consider GD, the following per-step estimate of loss function (Bubeck et al., 2015) as well as the Hessian upper bound is also useful.
+
+Lemma 6.6 (Informal Lemma A.11 and A.12). For $1 \leq t \leq T^{*} - 1$ , we have $H := \sup_{\pmb{\theta} \text{ along } GD \text{ trajectory}} \left\| \nabla^{2}\mathcal{L}(\pmb{\theta}) \right\| = \mathcal{O}(1)$ and $\mathcal{L}(\pmb{\theta}(t + 1)) \leq \mathcal{L}(\pmb{\theta}(t)) + \langle \nabla \mathcal{L}(\pmb{\theta}(t)), \pmb{\theta}(t + 1) - \pmb{\theta}(t) \rangle +$
+
+$$
+\frac {1}{2} H \left\| \boldsymbol {\theta} (t + 1) - \boldsymbol {\theta} (t) \right\| ^ {2}.
+$$
+
+# 6.2 Proof outline of Theorem 4.2
+
+First, we can estimate the initial neuron partition (Lemma 6.1) at the initialization. Then, we study the dynamics of neuron partition trained by GD (Lemma 6.2), which gives a precise directional characterization about each neuron for each sample. Next, by comparing with an exponentially growing hitting time, we can estimate the hitting time $T$ and the parameters (Lemma 6.3). Combining Lemma 6.1, 6.2 and 6.3, we derive a dynamical lower bound of each element of Gram matrix (Lemma 6.4), which induces our gradient lower bound (Lemma 6.5). Finally, by combining the gradient lower bound (Lemma 6.5) and the loss upper bound (Lemma 6.6), we complete our proof. For more details, please refer to Appendix A.
+
+The proof of Theorem 4.6 is similar to Theorem 4.2 and put into Appendix B.
+
+# 6.3 Proof outline of Theorem 5.2 and 5.3
+
+The proofs of Theorem 5.2 and 5.3 still rely on the dynamical analysis of neuron partition for each sample. First, the estimate of initial neuron partition (Lemma 6.1) also holds, and the dynamical analysis of neuron partition in Lemma 6.2 holds for any $t \geq 1$ (Lemma C.5 and C.6). Second, we can prove that the structure and lower bound of Gram matrix in Lemma 6.4 hold for any $t \geq 1$ (Lemma C.9), which induces the gradient lower bound below. Finally, combining the estimate of gradient lower bound, Hessian upper bound and loss upper bound, we complete our proof. For more details, please refer to Appendix C and D.
+
+Lemma 6.7 (Informal Lemma C.10). Under the condition of Theorem 5.3, with high probability, we have the following lower bound for any $t \geq 1$ : $\|\nabla \mathcal{L}(\pmb{\theta}(t))\| \gtrsim \mathcal{L}(\pmb{\theta}(t))$ , where the absolute constant hidden by $\gtrsim$ is $\sqrt{V}$ , defined in (7).
+
+In Lyu and Li (2019); Chatterji et al. (2021b), gradient lower bounds are derived for the late stage of training when $\mathcal{L}(\pmb{\theta}(t)) < 1/n$ , and take the form $\|\nabla \mathcal{L}(\pmb{\theta}(t))\| \gtrsim \mathcal{L}(\pmb{\theta}(t)) \log \left(1 / \mathcal{L}(\pmb{\theta}(t))\right) / \|\pmb{\theta}(t)\|$ . Our lower bound, instead, works on the whole training process. With this stronger gradient lower bound, we can show the exponential convergence in Theorem 5.3.
+
+Another important technical detail is the stability of GD, i.e., the learning rate should be upper bounded by the quantity related with the top eigenvalue of the Hessian. Our analysis also considered this factor, but implicitly. For global convergence results, the loss function we consider is exponential-type, whose Hessian can be controlled by the loss value. For example, for Theorem 5.2, there exists an absolute constant $C > 0$ , s.t. $\| \nabla^2\mathcal{L}(\pmb {\theta}(t))\| \leq Ct\mathcal{L}(\pmb {\theta}(t))$ for any $t\geq 1$ , please refer to Lemma C.15 in the appendix. Therefore, we can transform the Hessian-controlled learning rate condition into the loss-controlled learning rate condition in Theorem 5.2.
+
+# 7 Experiments
+
+MNIST and CIFAR-10 experiments. As we mentioned in Section 4.2, our theory about early stage convergence applies to a wide range of dataset (Assumption 4.5) such as MNIST and CIFAR-10. We use the two datasets (with normalization) to compare the experimental result with Theorem 4.6. Specifically, we use the first 1000 data in MNIST dataset and the first 1000 data in CIFAR-10 dataset, separately. (The two datasets with normalization $\| \pmb{x}\| = 1$ both satisfy Assumption 4.5.) And we use the two-layer ReLU network with the logistic loss $\ell (\pmb{y}_1,\pmb{y}_2) = \log (1 + \exp (-\pmb{y}_1^\top \pmb{y}_2))$ . $m,\kappa ,\eta$ are chosen by Theorem 4.6. We study the change of our bounds under different network width $m$ and learning rate $\eta$ . All experiments are conducted on a MacBook pro 13" only using CPU. See the code at https://github.com/wMZ9/EarlyStage_Convergence_NeurIPS2022.
+
+Table 1: Results of MNIST and CIFAR-10 experiments. In the first table, we fix $\eta = 0.01$ and change $m$ ; in the second one, we fix $m = 200$ and change $\eta$ .
+
+| m | 100 | 200 | 500 | 1000 |
| Our hitting iteration | 34 |
| Realistic loss descent (CIFAR-10) | 3.45 × 10-1 | 5.34 × 10-1 | 6.11 × 10-1 | 6.53 × 10-1 |
| Realistic loss descent (MINST) | 3.89 × 10-1 | 4.78 × 10-1 | 5.97 × 10-1 | 6.45 × 10-1 |
| Our loss descent bound | 2.63 × 10-1 |
| η | 0.01 | 0.005 | 0.002 | 0.001 |
| Our hitting iteration | 34 | 69 | 173 | 346 |
| Realistic loss descent (CIFAR-10) | 4.89 × 10-1 | 5.34 × 10-1 | 5.43 × 10-1 | 5.37 × 10-1 |
| Realistic loss descent (MINST) | 4.78 × 10-1 | 4.98 × 10-1 | 4.95 × 10-1 | 4.92 × 10-1 |
| Our loss descent bound | 2.63 × 10-1 |
+
+The results in Table 7 show that our loss descent bound (5-th row in each table) is relatively tight, basically in the same order of magnitude as the realistic loss descent (3-rd row and 4-th row in each table). And our loss descent bound does not change with the choice of different datasets.
+
+# 8 Conclusion and Future Work
+
+In this paper, we study the convergence of GD and SGD when training mildly parameterized neural networks. On one hand, we show early stage convergence for a wide range of loss functions, optimization algorithms, and training data distributions. On the other hand, under some assumptions on the loss function and data distribution, we show global convergence of GD. Our analysis can be extended to the minimization of population risk (See Appendix E).
+
+The theoretical understanding of the training of neural networks, especially for neural networks with practical sizes, still has a long way to go. For instance, although the late stage training for exponential loss function is simple and clear, that for other losses is much more complicated. Phenomena like unstable convergence (Wu et al., 2018; Cohen et al., 2021; Ahn et al., 2022; Ma et al., 2022) happen. Better understanding of these phenomena during training is an important direction of future work.
+
+# Acknowledgments and Disclosure of Funding
+
+We thank anonymous reviewers for helpful suggestions. Mingze Wang is supported in part by the National Key Basic Research Program of China: 2015CB856000.
+
+# References
+
+Kwangjun Ahn, Jingzhao Zhang, and Suvrit Sra. Understanding the unstable convergence of gradient descent. arXiv preprint arXiv:2204.01050, 2022.
+Zeyuan Allen-Zhu, Yuanzhi Li, and Yingyu Liang. Learning and generalization in overparameterized neural networks, going beyond two layers. Advances in neural information processing systems, 2019a.
+
+Zeyuan Allen-Zhu, Yuanzhi Li, and Zhao Song. A convergence theory for deep learning via overparameterization. In International Conference on Machine Learning, pages 242-252. PMLR, 2019b.
+Sanjeev Arora, Simon Du, Wei Hu, Zhiyuan Li, and Ruosong Wang. Fine-grained analysis of optimization and generalization for overparameterized two-layer neural networks. In International Conference on Machine Learning, pages 322-332. PMLR, 2019a.
+Sanjeev Arora, Simon S Du, Wei Hu, Zhiyuan Li, Russ R Salakhutdinov, and Ruosong Wang. On exact computation with an infinitely wide neural net. Advances in Neural Information Processing Systems, 32, 2019b.
+Sébastien Bubeck et al. Convex optimization: Algorithms and complexity. Foundations and Trends® in Machine Learning, 8(3-4):231-357, 2015.
+Niladri S Chatterji, Philip M Long, and Peter Bartlett. When does gradient descent with logistic loss interpolate using deep networks with smoothed relu activations? In Conference on Learning Theory, pages 927-1027. PMLR, 2021a.
+Niladri S Chatterji, Philip M Long, and Peter L Bartlett. When does gradient descent with logistic loss find interpolating two-layer networks? Journal of Machine Learning Research, 22(159):1-48, 2021b.
+Patrick Cheridito, Arnulf Jentzen, Adrian Riekert, and Florian Rossmannek. A proof of convergence for gradient descent in the training of artificial neural networks for constant target functions. Journal of Complexity, page 101646, 2022.
+Lenaic Chizat and Francis Bach. On the global convergence of gradient descent for over-parameterized models using optimal transport. Advances in neural information processing systems, 31, 2018.
+Lenaic Chizat, Edouard Oyallon, and Francis Bach. On lazy training in differentiable programming. Advances in Neural Information Processing Systems, 32, 2019.
+Youngmin Cho and Lawrence Saul. Kernel methods for deep learning. Advances in neural information processing systems, 22, 2009.
+Jeremy M Cohen, Simran Kaur, Yuanzhi Li, J Zico Kolter, and Ameet Talwalkar. Gradient descent on neural networks typically occurs at the edge of stability. arXiv preprint arXiv:2103.00065, 2021.
+Amit Daniely. Sgd learns the conjugate kernel class of the network. Advances in Neural Information Processing Systems, 30, 2017.
+Tian Ding, Dawei Li, and Ruoyu Sun. Sub-optimal local minima exist for neural networks with almost all non-linear activations. arXiv preprint arXiv:1911.01413, 2019.
+Simon Du, Jason Lee, Haochuan Li, Liwei Wang, and Xiyu Zhai. Gradient descent finds global minima of deep neural networks. In International conference on machine learning, pages 1675-1685. PMLR, 2019.
+Simon S Du, Xiyu Zhai, Barnabas Poczos, and Aarti Singh. Gradient descent provably optimizes over-parameterized neural networks. arXiv preprint arXiv:1810.02054, 2018.
+Weinan E, Chao Ma, Qingcan Wang, and Lei Wu. Analysis of the gradient descent algorithm for a deep neural network model with skip-connections. arXiv preprint arXiv:1904.05263, 2019.
+Weinan E, Chao Ma, and Lei Wu. A comparative analysis of optimization and generalization properties of two-layer neural network and random feature models under gradient descent dynamics. Science China Mathematics, 63(7):1235, 2020.
+Arthur Jacot, Franck Gabriel, and Clément Hongler. Neural tangent kernel: Convergence and generalization in neural networks. arXiv preprint arXiv:1806.07572, 2018.
+Arnulf Jentzen and Adrian Riekert. A proof of convergence for the gradient descent optimization method with random initializations in the training of neural networks with relu activation for piecewise linear target functions. arXiv preprint arXiv:2108.04620, 2021.
+
+Ziwei Ji and Matus Telgarsky. Gradient descent aligns the layers of deep linear networks. arXiv preprint arXiv:1810.02032, 2018.
+Ziwei Ji and Matus Telgarsky. Directional convergence and alignment in deep learning. Advances in Neural Information Processing Systems, 33:17176-17186, 2020.
+Alex Krizhevsky, Geoffrey Hinton, et al. Learning multiple layers of features from tiny images. 2009.
+Chandrashekar Lakshminarayanan and Amit Vikram Singh. Deep gated networks: A framework to understand training and generalisation in deep learning. arXiv preprint arXiv:2002.03996, 2020.
+Yann LeCun, Léon Bottou, Yoshua Bengio, and Patrick Haffner. Gradient-based learning applied to document recognition. Proceedings of the IEEE, 86(11):2278-2324, 1998.
+Hao Li, Zheng Xu, Gavin Taylor, Christoph Studer, and Tom Goldstein. Visualizing the loss landscape of neural nets. Advances in neural information processing systems, 31, 2018.
+Yuanzhi Li and Yingyu Liang. Learning overparameterized neural networks via stochastic gradient descent on structured data. Advances in Neural Information Processing Systems, 31, 2018.
+Yuanzhi Li and Yang Yuan. Convergence analysis of two-layer neural networks with relu activation. Advances in neural information processing systems, 30, 2017.
+Yuanzhi Li, Tengyu Ma, and Hongyang R Zhang. Learning over-parametrized two-layer neural networks beyond ntk. In Conference on learning theory, pages 2613-2682. PMLR, 2020.
+Roi Livni, Shai Shalev-Shwartz, and Ohad Shamir. On the computational efficiency of training neural networks. Advances in neural information processing systems, 27, 2014.
+Kaifeng Lyu and Jian Li. Gradient descent maximizes the margin of homogeneous neural networks. arXiv preprint arXiv:1906.05890, 2019.
+Kaifeng Lyu, Zhiyuan Li, Runzhe Wang, and Sanjeev Arora. Gradient descent on two-layer nets: Margin maximization and simplicity bias. Advances in Neural Information Processing Systems, 34, 2021.
+Chao Ma, Lei Wu, and Weinan E. The quenching-activation behavior of the gradient descent dynamics for two-layer neural network models. arXiv preprint arXiv:2006.14450, 2020.
+Chao Ma, Lei Wu, and Lexing Ying. The multiscale structure of neural network loss functions: The effect on optimization and origin. arXiv preprint arXiv:2204.11326, 2022.
+Song Mei, Andrea Montanari, and Phan-Minh Nguyen. A mean field view of the landscape of two-layer neural networks. Proceedings of the National Academy of Sciences, 115(33):E7665-E7671, 2018.
+Song Mei, Theodor Misiakiewicz, and Andrea Montanari. Mean-field theory of two-layers neural networks: dimension-free bounds and kernel limit. In Conference on Learning Theory, pages 2388-2464. PMLR, 2019.
+Mary Phuong and Christoph H Lampert. The inductive bias of relu networks on orthogonally separable data. In International Conference on Learning Representations, 2020.
+Itay Safran and Ohad Shamir. Spurious local minima are common in two-layer relu neural networks. In International conference on machine learning, pages 4433-4441. PMLR, 2018.
+Itay M Safran, Gilad Yehudai, and Ohad Shamir. The effects of mild over-parameterization on the optimization landscape of shallow relu neural networks. In Conference on Learning Theory, pages 3889-3934. PMLR, 2021.
+Ruoyu Sun, Dawei Li, Shiyu Liang, Tian Ding, and Rayadurgam Srikant. The global landscape of neural networks: An overview. IEEE Signal Processing Magazine, 37(5):95-108, 2020.
+Yuandong Tian. An analytical formula of population gradient for two-layered relu network and its applications in convergence and critical point analysis. In International conference on machine learning, pages 3404-3413. PMLR, 2017.
+
+Lei Wu. Learning a single neuron for non-monotonic activation functions. arXiv preprint arXiv:2202.08064, 2022.
+Lei Wu, Chao Ma, and Weinan E. How sgd selects the global minima in over-parameterized learning: A dynamical stability perspective. Advances in Neural Information Processing Systems, 31: 8279-8288, 2018.
+Gilad Yehudai and Shamir Ohad. Learning a single neuron with gradient methods. In *Conference on Learning Theory*, pages 3756-3786. PMLR, 2020.
+Gilad Yehudai and Ohad Shamir. On the power and limitations of random features for understanding neural networks. Advances in Neural Information Processing Systems, 32, 2019.
+Chiyuan Zhang, Samy Bengio, Moritz Hardt, Benjamin Recht, and Oriol Vinyals. Understanding deep learning requires rethinking generalization (2016). arXiv preprint arXiv:1611.03530, 2017.
+Kai Zhong, Zhao Song, Prateek Jain, Peter L Bartlett, and Inderjit S Dhillon. Recovery guarantees for one-hidden-layer neural networks. In International conference on machine learning, pages 4140-4149. PMLR, 2017.
+Mo Zhou, Rong Ge, and Chi Jin. A local convergence theory for mildly over-parameterized two-layer neural network. In Conference on Learning Theory, pages 4577-4632. PMLR, 2021.
+Difan Zou, Yuan Cao, Dongruo Zhou, and Quanquan Gu. Stochastic gradient descent optimizes over-parameterized deep relu networks. arXiv preprint arXiv:1811.08888, 2018.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] The global convergence results in Section 5 are built on restrictive assumptions of the loss function and training data.
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes] In Section 3, 4 and 5.
+(b) Did you include complete proofs of all theoretical results? [Yes] In Appendix A, B, C, D, F and G.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] As a URL in Section 7.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] In Section 7.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [N/A]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] In Section 7.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [N/A]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/images.zip b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..90b106c8a482bcf7a5b7097e90b77d855c3871e0
--- /dev/null
+++ b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:94c66a3b84ec95b33303260388c6da126fe240bc7ca44238369b71932b3268b6
+size 217465
diff --git a/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/layout.json b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..a9cfb37bf33006d60dae8d67b620d0c1eafdf693
--- /dev/null
+++ b/earlystageconvergenceandglobalconvergenceoftrainingmildlyparameterizedneuralnetworks/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5313250f0aa1b6bee56ade43a89898f7f3e187e135f11ef5948560304dfe564f
+size 636843
diff --git a/earthformerexploringspacetimetransformersforearthsystemforecasting/7661edab-3117-4ec8-9469-2ea8c3b61edf_content_list.json b/earthformerexploringspacetimetransformersforearthsystemforecasting/7661edab-3117-4ec8-9469-2ea8c3b61edf_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..e868f1c44f9d001a18b91799665b5501ab6b93ef
--- /dev/null
+++ b/earthformerexploringspacetimetransformersforearthsystemforecasting/7661edab-3117-4ec8-9469-2ea8c3b61edf_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3531e41c5c43da063738d2b2c7bddcebe9c95d29fcfade4005dcf45b9f02f80f
+size 89696
diff --git a/earthformerexploringspacetimetransformersforearthsystemforecasting/7661edab-3117-4ec8-9469-2ea8c3b61edf_model.json b/earthformerexploringspacetimetransformersforearthsystemforecasting/7661edab-3117-4ec8-9469-2ea8c3b61edf_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..d8ddee6f4f754c3316418608f3809fade4984ff6
--- /dev/null
+++ b/earthformerexploringspacetimetransformersforearthsystemforecasting/7661edab-3117-4ec8-9469-2ea8c3b61edf_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:00b766a49bb4e2333c728fcda91b7963960ce8d71e745603d95dc5cddb41e922
+size 111793
diff --git a/earthformerexploringspacetimetransformersforearthsystemforecasting/7661edab-3117-4ec8-9469-2ea8c3b61edf_origin.pdf b/earthformerexploringspacetimetransformersforearthsystemforecasting/7661edab-3117-4ec8-9469-2ea8c3b61edf_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..6e7b0ff8aa65f104abdfb77f31f40626bc011fc0
--- /dev/null
+++ b/earthformerexploringspacetimetransformersforearthsystemforecasting/7661edab-3117-4ec8-9469-2ea8c3b61edf_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7059fafc980739d18f06d62e680578205f05cf4aca89a72bda36027042248891
+size 1683473
diff --git a/earthformerexploringspacetimetransformersforearthsystemforecasting/full.md b/earthformerexploringspacetimetransformersforearthsystemforecasting/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..29ae8d355676dfa10f765f7ab7513f7db99ce686
--- /dev/null
+++ b/earthformerexploringspacetimetransformersforearthsystemforecasting/full.md
@@ -0,0 +1,352 @@
+# Earthformer: Exploring Space-Time Transformers for Earth System Forecasting
+
+Zhihan Gao*
+
+Hong Kong University of Science and Technology
+
+zhihan.gao@connect.ust.hk
+
+Xingjian Shi†
+
+Amazon Web Services
+
+xjshi@amazon.com
+
+Hao Wang
+
+Rutgers University
+
+hw488@cs.rutgers.edu
+
+Yi Zhu
+
+Amazon Web Services
+
+yzaws@amazon.com
+
+Yuyang Wang
+
+Amazon Web Services
+
+yuyawang@amazon.com
+
+Mu Li
+
+Amazon Web Services
+
+mli@amazon.com
+
+Dit-Yan Yeung
+
+Hong Kong University of Science and Technology
+
+dyyeung@cse.ust.hk
+
+# Abstract
+
+Conventionally, Earth system (e.g., weather and climate) forecasting relies on numerical simulation with complex physical models and hence is both expensive in computation and demanding on domain expertise. With the explosive growth of spatiotemporal Earth observation data in the past decade, data-driven models that apply Deep Learning (DL) are demonstrating impressive potential for various Earth system forecasting tasks. The Transformer as an emerging DL architecture, despite its broad success in other domains, has limited adoption in this area. In this paper, we propose Earthformer, a space-time Transformer for Earth system forecasting. Earthformer is based on a generic, flexible and efficient space-time attention block, named Cuboid Attention. The idea is to decompose the data into cuboids and apply cuboid-level self-attention in parallel. These cuboids are further connected with a collection of global vectors. We conduct experiments on the MovingMNIST dataset and a newly proposed chaotic $N$ -body MNIST dataset to verify the effectiveness of cuboid attention and figure out the best design of Earthformer. Experiments on two real-world benchmarks about precipitation nowcasting and El Niño/Southern Oscillation (ENSO) forecasting show that Earthformer achieves state-of-the-art performance.
+
+# 1 Introduction
+
+The Earth is a complex system. Variabilities of the Earth system, ranging from regular events like temperature fluctuation to extreme events like drought, hail storm, and El Niño/Southern Oscillation (ENSO), impact our daily life. Among all the consequences, Earth system variabilities can influence crop yields, delay airlines, cause floods and forest fires. Precise and timely forecasting of these variabilities can help people take necessary precautions to avoid crisis, or better utilize natural resources such as wind and solar energy. Thus, improving forecasting models for Earth variabilities (e.g., weather and climate) has a huge socioeconomic impact. Despite its importance, the operational weather and climate forecasting systems have not fundamentally changed for almost 50 years [34]. These operational models, including the state-of-the-art High Resolution Ensemble Forecast (HREF)
+
+
+Figure 1: Example Vertically Integrated Liquid (VIL) observation sequence from the Storm EVent ImageRy (SEVIR) dataset. The observation intensity is mapped to pixel value of the range 0-255. The larger value indicates the higher precipitation intensity.
+
+rainfall nowcasting model used in National Oceanic and Atmospheric Administration (NOAA) [32], rely on meticulous numerical simulation of physical models. Such simulation-based systems inevitably fall short in the ability to incorporate signals from newly emerging geophysical observation systems [12], or take advantage of the Petabytes-scale Earth observation data [43].
+
+As an appealing alternative, deep learning (DL) is offering a new approach for Earth system forecasting [34]. Instead of explicitly incorporating physical rules, DL-based forecasting models are trained on the Earth observation data [36]. By learning from a large amount of observations, DL models are able to figure out the system's intrinsic physical rules and generate predictions that outperform simulation-based models [9]. Such technique has demonstrated success in several applications, including precipitation nowcasting [32, 6] and ENSO forecasting [15]. Because the Earth system is chaotic [21], high-dimensional, and spatiotemporal, designing appropriate DL architecture for modeling the system is particularly challenging. Previous works relied on the combination of Recurrent Neural Networks (RNN) and Convolutional Neural Networks (CNN) [36, 37, 43, 13, 45]. These two architectures impose temporal and spatial inductive biases that help capturing spatiotemporal patterns. However, as a chaotic system, variabilities of the Earth system, such as rainfall and ENSO, are highly sensitive to the system's initial conditions and can respond abruptly to internal changes. It is unclear whether the inductive biases in RNN and CNN models still hold for such complex systems.
+
+On the other hand, recent years have witnessed major breakthroughs in DL brought by the wide adoption of Transformer. The model was originally proposed for natural language processing [42, 7], and later has been extended to computer vision [8, 22], multimodal text-image generation [31], graph learning [52], etc. Transformer relies on the attention mechanism to capture data correlations and is powerful at modeling complex and long-range dependencies, both of which appear in Earth systems (See Fig. 1 for an example of Earth observation data). Despite being suitable for the problem, Transformer sees limited adoption for Earth system forecasting. Naively applying the Transformer architecture is infeasible because the $O(N^2)$ attention mechanism is too computationally expensive for the high-dimensional Earth observation data. How to design a space-time Transformer that is good at predicting the future of the Earth systems is largely an open problem to the community.
+
+In this paper, we propose Earthformer, a space-time Transformer for Earth system forecasting. To better explore the design of space-time attention, we propose Cuboid Attention, which is a generic building block for efficient space-time attention. The idea is to decompose the input tensor to non-overlapping cuboids and apply cuboid-level self-attention in parallel. Since we limit the $O(N^2)$ self-attention inside the local cuboids, the overall complexity is greatly reduced. Different types of correlations can be captured via different cuboid decompositions. By stacking multiple cuboid attention layers with different hyperparameters, we are able to subsume several previously proposed video Transformers [19, 23, 4] as special cases, and also come up with new attention patterns that were not studied before. A limitation of this design is the lack of a mechanism for the local cuboids to communicate with each other. Thus, we introduce a collection of global vectors that attend to all the local cuboids, thereby gathering the overall status of the system. By attending to the global vectors, the local cuboids can grasp the general dynamics of the system and share information with each other.
+
+To verify the effectiveness of cuboid attention and figure out the best design under the Earth system forecasting scenario, we conducted extensive experiments on two synthetic datasets: the MovingMNIST [36] dataset and a newly proposed $N$ -body MNIST dataset. Digits in the $N$ -body MNIST follow the chaotic 3-body motion pattern [25], which makes the dataset not only more challenging than MovingMNIST but also more relevant to Earth system forecasting. The synthetic experiments reveal the following findings: 1) stacking cuboid attention layers with the Axial attention pattern is both efficient and effective, achieving the best overall performance, 2) adding global vectors provide consistent performance gain without increasing the computational cost, 3) adding hierarchy in the encoder-decoder architecture can improve performance. Based on these findings, we figured out the optimal design for Earthformer and made comparisons with other baselines on the SEVIR [43].
+
+benchmark for precipitation nowcasting and the ICAR-ENSO dataset [15] for ENSO forecasting. Experiments show that Earthformer achieves state-of-the-art (SOTA) performance on both tasks.
+
+# 2 Related Work
+
+Deep learning architectures for Earth system forecasting. Conventional DL models for Earth system forecasting are based on CNN and RNN. U-Net with either 2D CNN or 3D CNN have been used for precipitation nowcasting [43], Seasonal Arctic Sea ice prediction [11], and ENSO forecasting [15]. Shi et al. [36] proposed the ConvLSTM network that combines CNN and LSTM for precipitation nowcasting. Wang et al. [45] proposed PredRNN which adds the spatiotemporal memory flow structure to ConvLSTM. To better learn long-term high-level relations, Wang et al. [44] proposed E3D-LSTM that integrates 3D CNN to LSTM. To disentangle PDE dynamics from unknown complementary information, PhyDNet [13] incorporates a new recurrent physical cell to perform PDE-constrained prediction in latent space. Espeholt et al. [9] proposed MetNet-2 that outperforms HREF for forecasting precipitation. The architecture is based on ConvLSTM and dilated CNN. Very recently, there are works that tried to apply Transformer for solving Earth system forecasting problems. Pathak et al. [28] proposed the FourCastNet for global weather forecasting, which is based on Adaptive Fourier Neural Operators (AFNO) [14]. Bai et al. [3] proposed Rainformer for precipitation nowcasting, which is based on an architecture that combines CNN and SwinTransformer [22]. In our experiments, we can see that Earthformer outperforms Rainformer.
+
+Space-time Transformers for video modeling. Inspired by the success of ViT [8] for image classification, space-time Transformer is adopted for improved video understanding. In order to bypass the huge memory consumption brought by joint spatiotemporal attention, several pioneering work proposed efficient alternatives, such as divided attention [4], axial attention [19, 4], factorized encoder [27, 2] and separable attention [54]. Beyond minimal adaptation from ViT, some recent work introduced more prior to the design of space-time transformers, including trajectory [29], multi-scale [23, 11] and multi-view [49]. However, no prior work focuses on exploring the design of space-time Transformers for Earth system forecasting.
+
+Global and local attention in vision Transformers. To make self-attention more efficient in terms of both memory consumption and speed, recent works have adapted the essence of CNN to perform local attention in transformers [16, 52]. HaloNets [41] develops a new self-attention model family consisting of simple local self-attention and convolutional hybrids, which outperform both CNN and vanilla ViT on a range of downstream vision tasks. GLiT [5] introduces a locality module and uses neural architecture search to find an efficient backbone. Focal transformer [51] proposes focal self-attention that can incorporate both fine-grained local and coarse-grained global interactions. However, these architectures are not directly applicable to spatiotemporal forecasting. Besides, they are also different from our design because we keep $K$ global vectors to summarize the statistics of the dynamic system and connect the local cuboids; experiments show that such a global vector design is crucial to successful spatiotemporal forecasting.
+
+# 3 Model
+
+Similar to previous works [36, 43, 3], we formulate Earth system forecasting as a spatiotemporal sequence forecasting problem. The Earth observation data, such as radar echo maps from NEXRAD [17] and climate data from CIMP6 [10], are represented as a spatiotemporal sequence $\left[\mathcal{X}_i\right]_{i=1}^T$ , $\mathcal{X}_i \in \mathbb{R}^{H \times W \times C_{\mathrm{in}}}$ . Based on these observations, the model predicts the $K$ -step-ahead future $\left[\mathcal{Y}_{T+i}\right]_{i=1}^K$ , $\mathcal{Y}_{T+i} \in \mathbb{R}^{H \times W \times C_{\mathrm{out}}}$ . Here, $H, W$ denote the spatial resolution, and $C_{\mathrm{in}}, C_{\mathrm{out}}$ denote the number of measurements available at each space-time coordinate from the input and target sequences, respectively. As illustrated in Fig. 2 our proposed Earthformer is a hierarchical Transformer encoder-decoder based on Cuboid Attention. The input observations are encoded as a hierarchy of hidden states and then decoded to the prediction target. In what follows, we will present the detailed design of cuboid attention and the hierarchical encoder-decoder architecture adopted in Earthformer.
+
+# 3.1 Cuboid Attention
+
+Compared with images and text, spatiotemporal data in Earth systems usually have higher dimensionality. As a consequence, applying Transformers to this task is challenging. For example, for a 3D
+
+
+Figure 2: Illustration of the Earthformer architecture. It is a hierarchical Transformer encoder-decoder based on cuboid attention. The input sequence has length $T$ and the target sequence has length $K$ . "×D" means to stack $D$ cuboid attention blocks with residual connection. "M×" means to have $M$ layers of hierarchies.
+
+
+Figure 3: Illustration of the cuboid attention layer with global vectors.
+
+
+Figure 4: Illustration of cuboid decomposition strategies when the input shape is $(T,H,W) = (6,4,4)$ , and cuboid size $(b_{T},b_{H},b_{W}) = (3,2,2)$ . Cells that have the same color belong to the same cuboid and will attend to each other. shift $= (0,1,1)$ shifts the cuboid decomposition by 1 pixel along height and width dimensions. strategy $=$ "local" means to aggregate contiguous $(b_{T},b_{H},b_{W})$ pixels as a cuboid. strategy $=$ "dilated" means to aggregate pixels every $\lceil \frac{T}{b_T}\rceil (\lceil \frac{H}{b_H}\rceil ,\left\lceil \frac{W}{b_W}\right\rceil)$ steps along time (height, width) dimension. (Best viewed in color).
+
+
+
+
+
+tensor with shape $(T, H, W)$ , the complexity of the vanilla self-attention is $O(T^{2}H^{2}W^{2})$ and can be computationally infeasible. Previous literature proposed various structure-aware space-time attention mechanisms to reduce the complexity [19, 23, 4].
+
+These space-time attention mechanisms share the common design of stacking multiple elementary attention layers that focus on different types of data correlations (e.g., temporal correlation and spatial correlation). Steming from this observation, we propose the generic cuboid attention layer that involves three steps: "decompose", "attend", and "merge".
+
+Decompose. We first decompose the input spatiotemporal tensor $\mathcal{X} \in \mathbb{R}^{T \times H \times W \times C}$ into a sequence of cuboids $\{\pmb{x}^{(n)}\}$ .
+
+$$
+\left\{\boldsymbol {x} ^ {(n)} \right\} = \text {D e c o m p o s e} (\mathcal {X}, \text {c u b o i d _ s i z e , s t r a t e g y , s h i f t}), \tag {1}
+$$
+
+where cuboid_size = $(b_T, b_H, b_W)$ is the size of the local cuboid, strategy $\in \{\text{"local", "dilated"}\}$ controls whether to adopt the local decomposition strategy or the dilated decomposition strategy [4], shift = $(s_T, s_H, s_W)$ is the window shift offset [22]. Fig. 4 provides three examples showing how an input tensor will be decomposed following different hyperparameters of Decompose(\cdot). There are a total number of $\lceil \frac{T}{b_T} \rceil \lceil \frac{H}{b_H} \rceil \lceil \frac{W}{b_W} \rceil$ cuboids in $\{\pmb{x}^{(n)}\}$ . To simplify the notation, we assume that $T, H, W$ are divisible by $b_T, b_H, b_W$ . In the implementation, we pad the input tensor if it is not divisible.
+
+Assume $\pmb{x}^{(n)}$ is the $(n_T, n_H, n_W)$ -th cuboid in $\{\pmb{x}^{(n)}\}$ . The $(i, j, k)$ -th element of $\pmb{x}^{(n)}$ can be mapped to the $(i', j', k')$ -th element of $\mathcal{X}$ via Eqn. 2 if the strategy is "local" or Eqn. 3 if the strategy is "dilated".
+
+$$
+i ^ {\prime} \leftrightarrow s _ {T} + b _ {T} (n _ {T} - 1) + i \mod T
+$$
+
+$$
+i ^ {\prime} \leftrightarrow s _ {T} + b _ {T} (i - 1) + n _ {T} \mod T
+$$
+
+$$
+j ^ {\prime} \leftrightarrow s _ {H} + b _ {H} (n _ {H} - 1) + j \mod H
+$$
+
+(2) $j^{\prime}\leftrightarrow s_{H} + b_{H}(j - 1) + n_{H}\mod H$ (3)
+
+$$
+k ^ {\prime} \leftrightarrow s _ {W} + b _ {W} (n _ {W} - 1) + k \mod W
+$$
+
+$$
+k ^ {\prime} \leftrightarrow s _ {W} + b _ {W} (k - 1) + n _ {W} \mod W
+$$
+
+Since the mapping is bijective, one can then map the elements from $\mathcal{X}$ to $\{\pmb{x}^{(n)}\}$ via the inverse operation.
+
+Attend. After decomposing the input tensor into a sequence of non-overlapping cuboids $\{\pmb{x}^{(n)}\}$ , we apply self-attention within each cuboid in parallel.
+
+$$
+\boldsymbol {x} _ {\text {o u t}} ^ {(n)} = \operatorname {A t t e n t i o n} _ {\Theta} \left(\boldsymbol {x} ^ {(n)}, \boldsymbol {x} ^ {(n)}, \boldsymbol {x} ^ {(n)}\right), 1 \leq n \leq N. \tag {4}
+$$
+
+The query, key, and value matrices $Q$ , $K$ , and $V$ of $\text{Attention}_{\theta}(Q, K, V) = \text{Softmax} \left( (W_Q Q)(W_K K)^T / \sqrt{C} \right) (W_V V)$ are all flattened versions of $x^{(n)}$ , and we unravel the resulting matrix back to a 3D tensor. $W_Q$ , $W_K$ and $W_V$ are linear projection weights and are abbreviated together as $\Theta$ . The self-attention parameter $\Theta$ are shared across all cuboids. The computational complexity of the "attend" step is $O\left( \lceil \frac{T}{b_T} \rceil \lceil \frac{H}{b_H} \rceil \lceil \frac{W}{b_W} \rceil (b_T b_H b_W)^2 \right) \approx O(THW \cdot b_T b_H b_W)$ , which scales linearly with the cuboid size. Since the cuboid size can be much smaller than the size of the input tensor, the layer is more efficient than full attention.
+
+Merge. Merge $(\cdot)$ is the inverse operation of Decompose $(\cdot)$ . The sequence of cuboids obtained after the attention step $\{x_{\mathrm{out}}^{(n)}\}$ are merged back to the original input shape to produce the final output of cuboid attention, as shown in Eqn.5. The mapping follows the same bijections in Eqn.2 and Eqn.3.
+
+$$
+\mathcal {X} _ {\text {o u t}} = \operatorname {M e r g e} \left(\left\{\boldsymbol {x} _ {\text {o u t}} ^ {(n)} \right\} _ {n}, \text {c u b o i d _ s i z e}, \text {s t r a t e g y}, \text {s h i f t}\right). \tag {5}
+$$
+
+We combine the "decompose", "attend" and "merge" steps described in Eqn. 14.5 to construct the generic cuboid attention as in Eqn. 6
+
+$$
+\mathcal {X} _ {\text {o u t}} = \operatorname {C u b A t t n} _ {\Theta} (\mathcal {X}, \text {c u b o i d _ s i z e}, \text {s t r a g e y}, \text {s h i f t}). \tag {6}
+$$
+
+Explore cuboid attention patterns. By stacking multiple cuboid attention layers with different choices of "cuboid_size", "strategy" and "shift", we are able to efficiently explore existing and potentially more effective space-time attention. In this paper, we explore the cuboid attention patterns as listed in Table 1. From the table, we can see that cuboid attention subsumes previously proposed space-time attention methods like axial attention, video swim-Transformer, and divided space-time attention. Also, we manually picked the patterns that are reasonable and not computationally expensive as our search space. The flexibility of cuboid attention allows us to conduct Neural Architecture Search (NAS) to automatically search for a pattern but we will leave it as future work.
+
+# 3.2 Global Vectors
+
+One limitation of the previous formulation is that the cuboids do not communicate with each other. This is undesirable because each cuboid is not capable of understanding the global dynamics of the system. Thus, inspired by the [CLS] token adopted in BERT [7, 53], we propose to introduce a collection of $P$ global vectors $\mathcal{G} \in \mathbb{R}^{P \times C}$ to help cuboids scatter and gather crucial global information. When each cuboid is performing the self-attention, the elements will not only attend to the other elements within the same cuboid but also attend to the global vectors $\mathcal{G}$ . We revise Eqn.4 to Eqn.7 to enable local-global information exchange. We also use Eqn.8 to update the global vectors $\mathcal{G}$ by aggregating the information from all elements of the input tensor $\mathcal{X}$ .
+
+$$
+\boldsymbol {x} _ {\text {o u t}} ^ {(n)} = \operatorname {A t t e n t i o n} _ {\Theta} \left(\boldsymbol {x} ^ {(n)}, \operatorname {C a t} \left(\boldsymbol {x} ^ {(n)}, \mathcal {G}\right), \operatorname {C a t} \left(\boldsymbol {x} ^ {(n)}, \mathcal {G}\right)\right), 1 \leq n \leq N. \tag {7}
+$$
+
+$$
+\mathcal {G} _ {\text {o u t}} = \operatorname {A t t e n t i o n} _ {\Phi} (\mathcal {G}, \operatorname {C a t} (\mathcal {G}, \mathcal {X}), \operatorname {C a t} (\mathcal {G}, \mathcal {X})). \tag {8}
+$$
+
+Table 1: Configurations of the cuboid attention patterns explored in the paper. The input tensor has shape $(T,H,W)$ . If "shift" or "strategy" is not given, we use shift $= (0,0,0)$ and strategy $= \text{"local"}$ by default. When stacking multiple cuboid attention layers, each layer will be coupled with layer normalization layers and feed-forward network as in the Pre-LN Transformer [48]. The first row shows the configuration of the generic cuboid attention.
+
+| Name | Configurations | Values |
| Generic Cuboid Attention | cuboid_size | (T1,H1,W1) → (T2,H2,W2) → ... → (TL,LH,LW) |
| shift | (P1,M1,M1) → (P2,M2,M2) → ... → (PL,ML,ML) |
| strategy | “loc./dil.” → “loc./dil.” → ... → “loc./dil.” |
| Axial | cuboid_size | (T,1,1) → (1,H,1) → (1,1,W) |
| Divided Space-Time | cuboid_size | (T,1,1) → (1,H,W) |
| Video-Swin P × M | cuboid_size | (P,M,M) → (P,M,M) |
| shift | (0,0,0) → (P/2,M/2,M/2) |
| Spatial Local-Dilate-M | cuboid_size | (T,1,1) → (1,M,M) → (1,M,M) |
| strategy | “local” → “local” → “dilated” |
| Axial Space Dilate-M | cuboid_size | (T,1,1) → (1,H/M,1) → (1,H/M,1) → (1,1,W/M) → “local” → “dilated” → “local” → “dilated” → “local” |
+
+Here, $\operatorname{Cat}(\cdot)$ flattens and concatenates its input tensors. By combining Eqn. 1.7.8.5, we abbreviate the overall computation of the cuboid attention layer with global vectors as in Eqn. 9.
+
+$$
+\mathcal {X} _ {\text {o u t}} = \operatorname {C u b A t t n} _ {\Theta} (\mathcal {X}, \mathcal {G}, \text {c u b o i d _ s i z e}, \text {s t r a g e t y}, \text {s h i f t}),
+$$
+
+$$
+\mathcal {G} _ {\text {o u t}} = \operatorname {A t t n} _ {\Phi} ^ {\text {g l o b a l}} (\mathcal {G}, \mathcal {X}). \tag {9}
+$$
+
+The additional complexity caused by the global vectors is approximately $O\left( {THW \cdot P + {P}^{2}}\right)$ . Given that $P$ is usually small (in our experiments, $P$ is at most 8),the computational overhead induced by the global structure is negligible. The architecture of the cuboid attention layer is illustrated in Fig. 3
+
+# 3.3 Hierarchical Encoder-Decoder Architecture
+
+Earthformer adopts a hierarchical encoder-decoder architecture illustrated in Fig. 2. The hierarchical architecture gradually encodes the input sequence to multiple levels of representations and generates the prediction via a coarse-to-fine procedure. Each hierarchy stacks $D$ cuboid attention blocks. The cuboid attention block in the encoder uses one of the patterns described in Table 1 and each cuboid block in the decoder adopts the "Axial" pattern. To reduce the spatial resolution of the input to cuboid attention layers, we include a pair of initial downsampling and upsampling modules that consist of stacked 2D-CNN and Nearest Neighbor Interpolation (NNI) layers. Different from other papers that adopt Transformer for video prediction [19, 30], we generate the predictions in a non-auto-regressive fashion rather than an auto-regressive patch-by-patch fashion. This means that our decoder directly generates the predictions from the initial learned positional embeddings. We also conducted experiments with an auto-regressive decoder based on visual codebook [33]. However, the auto-regressive decoder underperforms the non-auto-regressive decoder in terms of forecasting skill scores. The comparison between non-auto-regressive decoder and auto-regressive decoder is shown in Appendix C.
+
+# 4 Experiments
+
+We first conducted experiments on two synthetic datasets, MovingMNIST and a newly proposed $N$ -body MNIST, to verify the effectiveness of Earthformer and conduct ablation study on our design choices. Results on these two datasets lead to the following findings: 1) Among all patterns listed in Table [1], "Axial" achieves the best overall performance; 2) Global vectors bring consistent performance gain with negligible increase in computational cost; 3) Using a hierarchical coarse-to-fine structure can boost the performance. Based on these findings, we figured out the optimal design of Earthformer and compared it with other state-of-the-art models on two real-world datasets: SEVIR [43] and ICAR-ENSO[2]. On both datasets, Earthformer achieved the best overall performance. The statistics of all the datasets used in the experiments are shown in Table [2]. We normalized the data to the range [0, 1] and trained all the models with the Mean-Squared Error (MSE) loss. More implementation details are shown in Appendix A
+
+Table 2: Statistics of the datasets used in the experiments.
+
+| Dataset | Size | Seq. | Len. | Spatial Resolution |
| train | val | test | in | out | H × W |
| MovingMNIST | 8,100 | 900 | 1,000 | 10 | 10 | 64 × 64 |
| N-body MNIST | 20,000 | 1,000 | 1,000 | 10 | 10 | 64 × 64 |
| SEVIR | 35,718 | 9,060 | 12,159 | 13 | 12 | 384 × 384 |
| ICAR-ENSO | 5,205 | 334 | 1,667 | 12 | 14 | 24 × 48 |
+
+Table 3: Ablation study on the importance of adopting a hierarchical encoder-decoder. We conducted experiments on MovingMNIST. "Depth $D$ " means the model stacks $D$ cuboid attention blocks and there is no hierarchical structure. "Depth $D1, D2$ " means the model stacks $D1$ cuboid attention blocks, applies the pooling layer, and stacks another $D2$ cuboid attention blocks.
+
+| Model | #Param. (M) | GFLOPS | MSE ↓ | Metrics MAE ↓ | SSIM ↑ |
| Depth 2 | 1.4 | 17.9 | 63.80 | 140.6 | 0.8324 |
| Depth 4 | 3.1 | 36.3 | 52.46 | 114.8 | 0.8685 |
| Depth 6 | 4.9 | 54.6 | 50.49 | 110.0 | 0.8738 |
| Depth 8 | 6.6 | 73.0 | 48.04 | 104.6 | 0.8797 |
| Depth 1,1 | 1.4 | 11.5 | 60.99 | 135.7 | 0.8388 |
| Depth 2,2 | 3.1 | 18.9 | 50.41 | 106.9 | 0.8805 |
| Depth 3,3 | 4.9 | 26.3 | 47.69 | 100.1 | 0.8873 |
| Depth 4,4 | 6.6 | 33.7 | 46.91 | 101.5 | 0.8825 |
+
+# 4.1 Experiments on Synthetic Datasets
+
+MovingMNIST. We follow [38] to use the public MovingMNIST dataset. The dataset contains 10,000 sequences. Each sequence shows 2 digits moving inside a $64 \times 64$ frame. We split the dataset to use 8,100 samples for training, 900 samples for validation and 1,000 samples for testing. The task is to predict the future 10 frames for each sequence conditioned on the first 10 frames.
+
+$N$ -body MNIST. The Earth is a complex system in which an extremely large number of variables interact with each other. Compared with the Earth system, the dynamics of the synthetic MovingMNIST dataset, in which the digits move independently with constant speed, is over-simplified. Thus, achieving good performance on MovingMNIST does not imply that the model is capable of modeling complex interactions in the Earth system. On the other hand, the real-world Earth observation data, though experiencing rapid development, are still noisy and may not provide useful insights for model development. Therefore, we extend MovingMNIST to $N$ -body MNIST, where $N$ digits are moving with the $N$ -body motion pattern inside a $64 \times 64$ frame. Each digit has its mass and is subjected to the gravity from other digits. We choose $N = 3$ in the experiments so that the digits will follow the chaotic 3-body motion [25]. The highly non-linear interactions in $N$ -body MNIST make it much more challenging than the original MovingMNIST. We generate 20,000 sequences for training, 1,000 for validation and 1,000 for testing. Perceptual examples of the dataset can be found at the first two rows of Fig. 5 In Appendix D, we demonstrate the chaotic behavior of $N$ -body MNIST.
+
+Hierarchical v.s. non-hierarchical. We choose "Axial" without global vectors as our cuboid attention pattern and compare the performance of non-hierarchical and hierarchical architectures on MovingMNIST. The ablation study on the importance of adopting a hierarchical encoder-decoder is shown in Table 3. We can see that the hierarchical architecture has similar FLOPS with the non-hierarchical architectures while being better in MSE. This observation is consistent as we increase the depth until the performance saturates.
+
+Cuboid pattern search. The design of cuboid attention greatly facilitates the search for optimal space-time attention. We compare the patterns listed in Table $\boxed{1}$ on both MovingMNIST and $N$ -body MNIST to investigate the effectiveness and efficiency of different space-time attention methods on spatiotemporal forecasting tasks. Besides the previously proposed space-time attention methods, we also include new configurations that are reasonable and not computationally expensive in our search space. For each pattern, we also compare the variant that uses global vectors. Results are summarized in Table $\boxed{4}$ . We find that the "Axial" pattern is both effective and efficient and adding global vectors improves performance for all patterns while having similar FLOPS. We thus pick "Axial + global" as the pattern in Earthformer when conducting experiments on real-world datasets.
+
+Table 4: Ablation study of different cuboid attention patterns and the effect of global vectors on MovingMNIST and $N$ -body MNIST. The variant that achieved the best performance is in boldface while the second best is underscored. We also compared the performance of the cuboid attention patterns with and without global vectors and highlight the better one with grey background.
+
+| Model | #Param. (M) | GFLOPS | MovingMNIST | N-body MNIST |
| MSE ↓ | MAE ↓ | SSIM ↑ | MSE ↓ | MAE ↓ | SSIM ↑ |
| Axial | 6.61 | 33.7 | 46.91 | 101.5 | 0.8825 | 15.89 | 41.38 | 0.9510 |
| + global ★ | 7.61 | 34.0 | 41.79 | 92.78 | 0.8961 | 14.82 | 39.93 | 0.9538 |
| DST | 5.70 | 35.2 | 57.43 | 118.6 | 0.8623 | 18.24 | 45.88 | 0.9435 |
| + global | 6.37 | 35.5 | 52.92 | 108.3 | 0.8760 | 17.77 | 45.84 | 0.9433 |
| Video Swin 2x8 | 5.66 | 31.1 | 54.45 | 111.7 | 0.8715 | 19.89 | 49.02 | 0.9374 |
| + global | 6.33 | 31.4 | 52.70 | 108.5 | 0.8766 | 19.53 | 48.43 | 0.9389 |
| Video Swin 10x8 | 5.89 | 39.2 | 63.34 | 125.3 | 0.8525 | 23.35 | 53.17 | 0.9274 |
| + global | 6.56 | 39.4 | 62.15 | 123.4 | 0.8541 | 22.81 | 52.94 | 0.9293 |
| Spatial Local-Global 2 | 6.61 | 33.3 | 59.88 | 122.1 | 0.8572 | 23.24 | 54.63 | 0.9263 |
| + global | 7.61 | 33.7 | 59.42 | 122.9 | 0.8565 | 21.88 | 52.49 | 0.9305 |
| Spatial Local-Global 4 | 6.61 | 33.5 | 58.72 | 118.5 | 0.8600 | 21.02 | 49.82 | 0.9344 |
| + global | 7.61 | 33.9 | 54.84 | 115.5 | 0.8585 | 19.82 | 48.12 | 0.9371 |
| Axial Space Dilate 2 | 8.59 | 41.8 | 50.11 | 104.4 | 0.8814 | 15.97 | 42.19 | 0.9494 |
| + global | 10.30 | 42.4 | 46.86 | 98.95 | 0.8884 | 15.73 | 41.85 | 0.9510 |
| Axial Space Dilate 4 | 8.59 | 41.6 | 47.40 | 99.31 | 0.8865 | 19.49 | 51.04 | 0.9352 |
| + global | 10.30 | 42.2 | 45.11 | 95.98 | 0.8928 | 17.91 | 46.35 | 0.9440 |
+
+Table 5: Comparison of Earthformer with baselines on MovingMNIST and $N$ -body MNIST.
+
+| Model | #Param. (M) | GFLOPS | MovingMNIST | N-body MNIST |
| MSE ↓ | MAE ↓ | SSIM ↑ | MSE ↓ | MAE ↓ | SSIM ↑ |
| UNet [43] | 16.6 | 0.9 | 110.4 | 249.4 | 0.6170 | 38.90 | 94.29 | 0.8260 |
| ConvLSTM [36] | 14.0 | 30.1 | 62.04 | 126.9 | 0.8477 | 32.15 | 72.64 | 0.8886 |
| PredRNN [45] | 23.8 | 232.0 | 52.07 | 108.9 | 0.8831 | 21.76 | 54.32 | 0.9288 |
| PhyDNet [13] | 3.1 | 15.3 | 58.70 | 124.1 | 0.8350 | 28.97 | 78.66 | 0.8206 |
| E3D-LSTM [44] | 12.9 | 302.0 | 55.31 | 101.6 | 0.8821 | 22.98 | 62.52 | 0.9131 |
| Rainformer [3] | 19.2 | 1.2 | 85.83 | 189.2 | 0.7301 | 38.89 | 96.47 | 0.8036 |
| Earthformer w/o global | 6.6 | 33.7 | 46.91 | 101.5 | 0.8825 | 15.89 | 41.38 | 0.9510 |
| Earthformer | 7.6 | 34.0 | 41.79 | 92.78 | 0.8961 | 14.82 | 39.93 | 0.9538 |
+
+Comparison to the state of the art. We evaluate six spatiotemporal forecasting algorithms: UNet [43], ConvLSTM [36], PredRNN [45], PhyDNet [13], E3D-LSTM [44] and Rainformer [3]. The results are in Table 5. Note that the MovingMNIST performance on several papers [13] is obtained by training the model with on-the-fly generated digits while we pre-generate the digits and train all models on a fixed dataset. Comparing the numbers in the table with numbers shown in these papers are not fair. We train all baselines from scratch on both MovingMNIST and $N$ -body MNIST using the default hyperparameters and configurations in their officially released code.
+
+Qualitative results on $N$ -body MNIST. Fig. 5 shows the generation results of different methods on a sample sequence from the $N$ -body MNIST test set. The qualitative example demonstrates that our Earthformer is capable of learning long-range interactions among digits and correctly predicting their future motion trajectories. Also, we can see that Earthformer is able to more accurately predict the position of the digits with the help of global vectors. On the contrary, none of the baseline algorithms that achieved solid performance on MovingMNIST gives the correct and precise position of the digit "0" in the last frame. They either predict incorrect motion trajectories (PredRNN and E3D-LSTM), or generate highly blurry predictions (Rainformer, UNet and PhyDNet) to accommodate the uncertainty about the future.
+
+# 4.2 SEVIR Precipitation Nowcasting
+
+Storm EVent ImageRy (SEVIR) [43] is a spatiotemporally aligned dataset containing over 10,000 weather events. Each event consists of $384\mathrm{km} \times 384\mathrm{km}$ image sequences spanning over 4 hours. Images in SEVIR were sampled and aligned across five different data types: three channels (C02,
+
+
+Figure 5: A set of examples showing the perceptual quality of the predictions on the $N$ -body MNIST test set. From top to bottom: input frames, target frames, predictions by Rainformer [3], UNet [43], ConvLSTM [36], PhyDNet [13], E3D-LSTM [44], PredRNN [45], Earthformer without using global vectors, Earthformer. The results are sorted according to the MSE.
+
+Table 6: Performance comparison on SEVIR. We include Critical Success Index (CSI) besides MSE as evaluation metrics. The CSI, a.k.a intersection over union (IOU), is calculated at different precipitation thresholds and denoted as CSI-thresh.
+
+| Model | #Param. (M) | GFLOPS | Metrics |
| CSI-M ↑ | CSI-219 ↑ | CSI-181 ↑ | CSI-160 ↑ | CSI-133 ↑ | CSI-74 ↑ | CSI-16 ↑ | MSE (10-3) ↓ |
| Persistence | - | - | 0.2613 | 0.0526 | 0.0969 | 0.1278 | 0.2155 | 0.4705 | 0.6047 | 11.5338 |
| UNet [43] | 16.6 | 33 | 0.3593 | 0.0577 | 0.1580 | 0.2157 | 0.3274 | 0.6531 | 0.7441 | 4.1119 |
| ConvLSTM [46] | 14.0 | 527 | 0.4185 | 0.1288 | 0.2482 | 0.2928 | 0.4052 | 0.6793 | 0.7569 | 3.7532 |
| PredRNN [45] | 46.6 | 328 | 0.4080 | 0.1312 | 0.2324 | 0.2767 | 0.3858 | 0.6713 | 0.7507 | 3.9014 |
| PhyDNet [13] | 13.7 | 701 | 0.3940 | 0.1288 | 0.2309 | 0.2708 | 0.3720 | 0.6556 | 0.7059 | 4.8165 |
| E3D-LSTM [44] | 35.6 | 523 | 0.4038 | 0.1239 | 0.2270 | 0.2675 | 0.3825 | 0.6645 | 0.7573 | 4.1702 |
| Rainformer [3] | 184.0 | 170 | 0.3661 | 0.0831 | 0.1670 | 0.2167 | 0.3438 | 0.6585 | 0.7277 | 4.0272 |
| Earthformer w/o global | 13.1 | 257 | 0.4356 | 0.1572 | 0.2716 | 0.3138 | 0.4214 | 0.6859 | 0.7637 | 3.7002 |
| Earthformer | 15.1 | 257 | 0.4419 | 0.1791 | 0.2848 | 0.3232 | 0.4271 | 0.6860 | 0.7513 | 3.6957 |
+
+C09, C13) from the GOES-16 advanced baseline imager, NEXRAD Vertically Integrated Liquid (VIL) mosaics, and GOES-16 Geostationary Lightning Mapper (GLM) flashes. The SEVIR benchmark supports scientific research on multiple meteorological applications including precipitation nowcasting, synthetic radar generation, front detection, etc. We adopt SEVIR for benchmarking precipitation nowcasting, i.e., to predict the future VIL up to 60 minutes (12 frames) given 65 minutes context VIL (13 frames). Fig. $\boxed{[}$ shows an example of VIL observation sequences in SEVIR.
+
+Besides MSE, we also include the Critical Success Index (CSI), which is commonly used in precipitation nowcasting and is defined as CSI = #Hits/#Hits + #Misses + #F.Alarms. To count the #Hits (truth=1, pred=1), #Misses (truth=1, pred=0) and #F.Alarms (truth=0, pred=1), the prediction and the ground-truth are rescaled back to the range 0-255 and binarized at thresholds [16,74,133,160,181,219]. We report CSI at different thresholds and also their mean CSI-M.
+
+SEVIR is much larger than MovingMNIST and $N$ -body MNIST and has higher resolution. We thus slightly adjust the configurations of baselines based on those for MovingMNIST for fair comparison. Detailed configurations are shown in Appendix A. The experiment results are listed in Table 6. Earthformer consistently outperforms baselines on almost all metrics and brings significant performance gain especially at high thresholds like CSI-219, which are more valued by the communities.
+
+Table 7: Performance comparison on ICAR-ENSO. $C$ -Nino3.4-M and $C$ -Nino3.4-WM are the mean and the weighted mean of the correlation skill $C^{\mathrm{Nino}3.4}$ over $K = 12$ forecasting steps. $C$ -Nino3.4-WM assigns more weights to longer-term prediction scores. MSE is calculated between the spatiotemporal SST anomalies prediction and the corresponding ground-truth.
+
+| Model | #Param. (M) | GFLOPS | Metrics |
| C-Nino3.4-M ↑ | C-Nino3.4-WM ↑ | MSE (10-4) ↓ |
| Persistence | - | - | 0.3221 | 0.447 | 4.581 |
| UNet [43] | 12.1 | 0.4 | 0.6926 | 2.102 | 2.868 |
| ConvLSTM [36] | 14.0 | 11.1 | 0.6955 | 2.107 | 2.657 |
| PredRNN [45] | 23.8 | 85.8 | 0.6492 | 1.910 | 3.044 |
| PhyDNet [13] | 3.1 | 5.7 | 0.6646 | 1.965 | 2.708 |
| E3D-LSTM [44] | 12.9 | 99.8 | 0.7040 | 2.125 | 3.095 |
| Rainformer [3] | 19.2 | 1.3 | 0.7106 | 2.153 | 3.043 |
| Earthformer w/o global Earthformer | 6.6 | 23.6 | 0.7239 | 2.214 | 2.550 |
| 7.6 | 23.9 | 0.7329 | 2.259 | 2.546 |
+
+# 4.3 ICAR-ENSO Sea Surface Temperature Anomalies Forecasting
+
+El Niño/Southern Oscillation (ENSO) has a wide range of associations with regional climate extremes and ecosystem impacts. ENSO sea surface temperature (SST) anomalies forecasting for lead times up to one year (12 steps) is a valuable and challenging problem. Nino3.4 index, which is the area-averaged SST anomalies across a certain area $(170^{\circ} - 120^{\circ}\mathrm{W}, 5^{\circ}\mathrm{S} - 5^{\circ}\mathrm{N})$ of the Pacific, serves as a crucial indicator of this climate event. The forecast quality is evaluated by the correlation skill [15] of the three-month-moving-averaged Nino3.4 index $C^{\mathrm{Nino3.4}} = \frac{\sum_{N}(\mathbf{X} - \bar{\mathbf{X}})(\mathbf{Y} - \bar{\mathbf{Y}})}{\sqrt{\sum_{N}(\mathbf{X} - \bar{\mathbf{X}})^{2}\sum_{N}(\mathbf{Y} - \bar{\mathbf{Y}})^{2}} \in \mathbb{R}^{K}$ calculated on the whole test set of size $N$ , where $\mathbf{Y} \in \mathbb{R}^{N \times K}$ is the ground-truth of $K$ -step Nino3.4 index, $\mathbf{X} \in \mathbb{R}^{N \times K}$ is the corresponding prediction of Nino3.4 index.
+
+ICAR-ENSO consists of historical climate observation and stimulation data provided by Institute for Climate and Application Research (ICAR). We forecast the SST anomalies up to 14 steps (2 steps more than one year for calculating three-month-moving-average) given a context of 12 steps of SST anomalies observations. Table compares the performance of our Earthformer with baselines on the ICAR-ENSO dataset. We report the mean correlation skill $C$ -Nino3.4-M = $\frac{1}{K} \sum_{k} C_{k}^{\text{Nino3.4}}$ and the weighted mean correlation skill $C$ -Nino3.4-WM = $\frac{1}{K} \sum_{k} a_{k} \cdot C_{k}^{\text{Nino3.4}}$ over $K = 12$ forecasting steps as well as the MSE between the spatiotemporal SST anomalies prediction and the corresponding ground-truth. We can find that Earthformer consistently outperforms the baselines in all concerned evaluation metrics and that using global vectors further improves the performance.
+
+# 5 Conclusions and Broader Impact
+
+In this paper, we propose Earthformer, a space-time Transformer for Earth system forecasting. Earthformer is based on a generic and efficient building block called Cuboid Attention. It achieves SOTA on MovingMNIST, our newly proposed $N$ -body MNIST, SEVIR, and ICAR-ENSO.
+
+Our work has certain limitations. The first one is that Earthformer is a deterministic model that does not model uncertainty. This may result in predicting the average of all plausible futures, causing the model to generate blurry predictions of low perceptual quality and be lack of valuable small-scale details. In fact, the community lacks appropriate metrics that measure the uncertainty component in Earth system forecasting models. Extending Earthformer to a probabilistic forecasting model can be an exciting future direction. We include more detailed discussions and preliminary experiments about handling uncertainty in Appendix C. The second one is that the model is purely data-driven and does not take advantage of the physical knowledge of the Earth system. Recent studies on adding physical constraints [20, 26] and ensembling the predictions from a data-driven model and a physics-based model [32] imply that it is an active and promising research direction to pursue. We plan to study how to incorporate physical knowledge into Earthformer in the future.
+
+# Acknowledgments and Disclosure of Funding
+
+This work has been made possible by a Research Impact Fund project (R6003-21) and an Innovation and Technology Fund project (ITS/004/21FP) funded by the Hong Kong Government.
+
+# References
+
+[1] Tom R Andersson, J Scott Hosking, María Pérez-Ortiz, Brooks Paige, Andrew Elliott, Chris Russell, Stephen Law, Daniel C Jones, Jeremy Wilkinson, Tony Phillips, et al. Seasonal Arctic sea ice forecasting with probabilistic deep learning. Nature communications, 12(1):1–12, 2021.
+[2] Anurag Arnab, Mostafa Dehghani, Georg Heigold, Chen Sun, Mario Luvcić, and Cordelia Schmid. ViViT: A video vision transformer. In International Conference on Computer Vision (ICCV), 2021.
+[3] Cong Bai, Feng Sun, Jinglin Zhang, Yi Song, and Shengyong Chen. Rainformer: Features extraction balanced network for radar-based precipitation nowcasting. IEEE Geoscience and Remote Sensing Letters, 19:1-5, 2022.
+[4] Gedas Bertasius, Heng Wang, and Lorenzo Torresani. Is space-time attention all you need for video understanding. arXiv preprint arXiv:2102.05095, 2(3):4, 2021.
+[5] Boyu Chen, Peixia Li, Chuming Li, Baopu Li, Lei Bai, Chen Lin, Ming Sun, Junjie Yan, and Wanli Ouyang. GLiT: Neural architecture search for global and local image transformer. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 12-21, 2021.
+[6] Christian Schroeder de Witt, Catherine Tong, Valentina Zantedeschi, Daniele De Martini, Freddie Kalaitzis, Matthew Chantry, Duncan Watson-Parris, and Piotr Bilinski. RainBench: towards global precipitation forecasting from satellite imagery. In AAAI, 2021.
+[7] Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. BERT: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805, 2018.
+[8] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, et al. An image is worth 16x16 words: Transformers for image recognition at scale. arXiv preprint arXiv:2010.11929, 2020.
+[9] Lasse Espeholt, Shreya Agrawal, Casper Sønderby, Manoj Kumar, Jonathan Heek, Carla Bromberg, Cenk Gazen, Jason Hickey, Aaron Bell, and Nal Kalchbrenner. Skillful twelve hour precipitation forecasts using large context neural networks. arXiv preprint arXiv:2111.07470, 2021.
+[10] Veronika Eyring, Sandrine Bony, Gerald A Meehl, Catherine A Senior, Bjorn Stevens, Ronald J Stouffer, and Karl E Taylor. Overview of the coupled model intercomparison project phase 6 (CMIP6) experimental design and organization. Geoscientific Model Development, 9(5):1937-1958, 2016.
+[11] Haoqi Fan, Bo Xiong, Karttikeya Mangalam, Yanghao Li, Zhicheng Yan, Jitendra Malik, and Christoph Feichtenhofer. Multiscale vision transformers. In ICCV, 2021.
+[12] Steven J Goodman, Timothy J Schmit, Jaime Daniels, and Robert J Redmon. The GOES-R series: a new generation of geostationary environmental satellites. Elsevier, 2019.
+[13] Vincent Le Guen and Nicolas Thome. Disentangling physical dynamics from unknown factors for unsupervised video prediction. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 11474-11484, 2020.
+[14] John Guibas, Morteza Mardani, Zongyi Li, Andrew Tao, Anima Anandkumar, and Bryan Catanzaro. Adaptive fourier neural operators: Efficient token mixers for transformers. arXiv preprint arXiv:2111.13587, 2021.
+[15] Yoo-Geun Ham, Jeong-Hwan Kim, and Jing-Jia Luo. Deep learning for multi-year ENSO forecasts. Nature, 573(7775):568-572, 2019.
+[16] Kai Han, An Xiao, Enhua Wu, Jianyuan Guo, Chunjing Xu, and Yunhe Wang. Transformer in transformer. NeurIPS, 2021.
+[17] William H Heiss, David L McGrew, and Dale Sirmans. NEXRAD: next generation weather radar (wsr-88d). Microwave Journal, 33(1):79–89, 1990.
+[18] Dan Hendrycks and Kevin Gimpel. Gaussian error linear units (gelus). arXiv preprint arXiv:1606.08415, 2016.
+
+[19] Jonathan Ho, Nal Kalchbrenner, Dirk Weissenborn, and Tim Salimans. Axial attention in multidimensional transformers. arXiv preprint arXiv:1912.12180, 2019.
+[20] Aditi Krishnapriyan, Amir Gholami, Shandian Zhe, Robert Kirby, and Michael W Mahoney. Characterizing possible failure modes in physics-informed neural networks. Advances in Neural Information Processing Systems, 34:26548-26560, 2021.
+[21] Christophe Letellier. Chaos in nature, volume 94. World Scientific, 2019.
+[22] Ze Liu, Yutong Lin, Yue Cao, Han Hu, Yixuan Wei, Zheng Zhang, Stephen Lin, and Baining Guo. Swin transformer: Hierarchical vision transformer using shifted windows. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 10012-10022, 2021.
+[23] Ze Liu, Jia Ning, Yue Cao, Yixuan Wei, Zheng Zhang, Stephen Lin, and Han Hu. Video swim transformer. arXiv preprint arXiv:2106.13230, 2021.
+[24] Mario Lucic, Karol Kurach, Marcin Michalski, Sylvain Gelly, and Olivier Bousquet. Are GANs created equal? a large-scale study. In NeurIPS, 2018.
+[25] Valtonen MJ, Mauri Valtonen, and Hannu Karttunen. The three-body problem. Cambridge University Press, 2006.
+[26] Geoffrey Négiar, Michael W Mahoney, and Aditi S Krishnapriyan. Learning differentiable solvers for systems with hard constraints. arXiv preprint arXiv:2207.08675, 2022.
+[27] Daniel Neimark, Omri Bar, Maya Zohar, and Dotan Asselmann. Video transformer network. arXiv preprint arXiv:2102.00719, 2021.
+[28] Jaideep Pathak, Shashank Subramanian, Peter Harrington, Sanjeev Raja, Ashesh Chattopadhyay, Morteza Mardani, Thorsten Kurth, David Hall, Zongyi Li, Kamyar Azizzadenesheli, et al. FourCastNet: A global data-driven high-resolution weather model using adaptive fourier neural operators. arXiv preprint arXiv:2202.11214, 2022.
+[29] Mandela Patrick, Dylan Campbell, Yuki M. Asano, Ishan Misra Florian Metze, Christoph Feichtenhofer, Andrea Vedaldi, and João F. Henriques. Keeping your eye on the ball: Trajectory attention in video transformers. In Advances in Neural Information Processing Systems (NeurIPS), 2021.
+[30] Ruslan Rakhimov, Denis Volkhonskiy, Alexey Artemov, Denis Zorin, and Evgeny Burnaev. Latent video transformer. arXiv preprint arXiv:2006.10704, 2020.
+[31] Aditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray, Chelsea Voss, Alec Radford, Mark Chen, and Ilya Sutskever. Zero-shot text-to-image generation. In International Conference on Machine Learning, pages 8821-8831. PMLR, 2021.
+[32] Suman Ravuri, Karel Lenc, Matthew Willson, Dmitry Kangin, Remi Lam, Piotr Mirowski, Megan Fitzsimons, Maria Athanassiadou, Sheleem Kashem, Sam Madge, et al. Skilful precipitation nowcasting using deep generative models of radar. Nature, 597(7878):672-677, 2021.
+[33] Ali Razavi, Aaron Van den Oord, and Oriol Vinyals. Generating diverse high-fidelity images with VQ-VAE-2. Advances in neural information processing systems, 32, 2019.
+[34] Markus Reichstein, Gustau Camps-Valls, Bjorn Stevens, Martin Jung, Joachim Denzler, Nuno Carvalhais, et al. Deep learning and process understanding for data-driven earth system science. Nature, 566(7743):195-204, 2019.
+[35] Tim Salimans, Andrej Karpathy, Xi Chen, and Diederik P. Kingma. PixelCNN++: A PixelCNN implementation with discretized logistic mixture likelihood and other modifications. In ICLR, 2017.
+[36] Xingjian Shi, Zhourong Chen, Hao Wang, Dit-Yan Yeung, Wai-Kin Wong, and Wang-chun Woo. Convolutional LSTM network: A machine learning approach for precipitation nowcasting. In NeurIPS, volume 28, 2015.
+[37] Xingjian Shi, Zhihan Gao, Leonard Lausen, Hao Wang, Dit-Yan Yeung, Wai-kin Wong, and Wang-chun Woo. Deep learning for precipitation nowcasting: A benchmark and a new model. In NeurIPS, volume 30, 2017.
+[38] Nitish Srivastava, Elman Mansimov, and Ruslan Salakhudinov. Unsupervised learning of video representations using LSTMs. In ICML, pages 843-852. PMLR, 2015.
+
+[39] Byron D Tapley, Srinivas Bettadpur, John C Ries, Paul F Thompson, and Michael M Watkins. GRACE measurements of mass variability in the earth system. science, 305(5683):503-505, 2004.
+[40] Aaron Van Den Oord, Oriol Vinyals, et al. Neural discrete representation learning. Advances in neural information processing systems, 30, 2017.
+[41] Ashish Vaswani, Prajit Ramachandran, Aravind Srinivas, Niki Parmar, Blake Hechtman, and Jonathon Shlens. Scaling local self-attention for parameter efficient visual backbones. In CVPR, 2021.
+[42] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. In NeurIPS, volume 30, 2017.
+[43] Mark Veillette, Siddharth Samsi, and Chris Mattioli. SEVIR: A storm event imagery dataset for deep learning applications in radar and satellite meteorology. Advances in Neural Information Processing Systems, 33:22009–22019, 2020.
+[44] Yunbo Wang, Lu Jiang, Ming-Hsuan Yang, Li-Jia Li, Mingsheng Long, and Li Fei-Fei. Eidetic 3D LSTM: A model for video prediction and beyond. In International conference on learning representations, 2018.
+[45] Yunbo Wang, Haixu Wu, Jianjin Zhang, Zhifeng Gao, Jianmin Wang, Philip Yu, and Mingsheng Long. PredRNN: A recurrent neural network for spatiotemporal predictive learning. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2022.
+[46] Dirk Weissenborn, Oscar Täckström, and Jakob Uszkoreit. Scaling autoregressive video models. In International Conference on Learning Representations, 2019.
+[47] Yuxin Wu and Kaiming He. Group normalization. In Proceedings of the European conference on computer vision (ECCV), pages 3-19, 2018.
+[48] Ruibin Xiong, Yunchang Yang, Di He, Kai Zheng, Shuxin Zheng, Chen Xing, Huishuai Zhang, Yanyan Lan, Liwei Wang, and Tieyan Liu. On layer normalization in the transformer architecture. In International Conference on Machine Learning, pages 10524-10533. PMLR, 2020.
+[49] Shen Yan, Xuehan Xiong, Anurag Arnab, Zhichao Lu, Mi Zhang, Chen Sun, and Cordelia Schmid. Multiview transformers for video recognition. In CVPR, 2022.
+[50] Wilson Yan, Yunzhi Zhang, Pieter Abbeel, and Aravind Srinivas. VideoGPT: Video generation using vq-vae and transformers. arXiv preprint arXiv:2104.10157, 2021.
+[51] Jianwei Yang, Chunyuan Li, Pengchuan Zhang, Xiyang Dai, Bin Xiao, Lu Yuan, and Jianfeng Gao. Focal self-attention for local-global interactions in vision transformers. In NeurIPS, 2021.
+[52] Chengxuan Ying, Tianle Cai, Shengjie Luo, Shuxin Zheng, Guolin Ke, Di He, Yanming Shen, and Tie-Yan Liu. Do transformers really perform badly for graph representation? Advances in Neural Information Processing Systems, 34, 2021.
+[53] Manzil Zaheer, Guru Guruganesh, Kumar Avinava Dubey, Joshua Ainslie, Chris Alberti, Santiago Ontonon, Philip Pham, Anirudh Ravula, Qifan Wang, Li Yang, et al. Big bird: Transformers for longer sequences. Advances in Neural Information Processing Systems, 33:17283-17297, 2020.
+[54] Yanyi Zhang, Xinyu Li, Chunhui Liu, Bing Shuai, Yi Zhu, Biagio Brattoli, Hao Chen, Ivan Marsic, and Joseph Tighe. Vidtr: Video transformer without convolutions. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 13577-13587, 2021.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See Section 5.
+(c) Did you discuss any potential negative societal impacts of your work? [No] Exploring Earth system forecasting has no negative societal impacts.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [Yes]
+(c) Did you include any new assets either in the supplemental material or as a URL? [No]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/earthformerexploringspacetimetransformersforearthsystemforecasting/images.zip b/earthformerexploringspacetimetransformersforearthsystemforecasting/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..d53d5ff4e77151bd98fc9a46b9513b81a1cea1e1
--- /dev/null
+++ b/earthformerexploringspacetimetransformersforearthsystemforecasting/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:876a371be3e95a6ffce872002eb0e04cf119dce8b865434ac1141a63580b9a4a
+size 594022
diff --git a/earthformerexploringspacetimetransformersforearthsystemforecasting/layout.json b/earthformerexploringspacetimetransformersforearthsystemforecasting/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..68625b90ffcdf38208e4bf164daa883b586b037e
--- /dev/null
+++ b/earthformerexploringspacetimetransformersforearthsystemforecasting/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6c79e8f717b3620db78eb2b54d76efa5430ab1b41c84df36a79f71d0460f7b08
+size 456072
diff --git a/ecoformerenergysavingattentionwithlinearcomplexity/fb9b7978-b38c-47c6-8a29-701d5a6f34e3_content_list.json b/ecoformerenergysavingattentionwithlinearcomplexity/fb9b7978-b38c-47c6-8a29-701d5a6f34e3_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..bae0d0fb915b2ce8e3d0f8b8148b51027e41486a
--- /dev/null
+++ b/ecoformerenergysavingattentionwithlinearcomplexity/fb9b7978-b38c-47c6-8a29-701d5a6f34e3_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7b8ac2f74a5ac83d7e518d864cd1dc7ec4a0736a071866ae9aea6d26fc6515fd
+size 91054
diff --git a/ecoformerenergysavingattentionwithlinearcomplexity/fb9b7978-b38c-47c6-8a29-701d5a6f34e3_model.json b/ecoformerenergysavingattentionwithlinearcomplexity/fb9b7978-b38c-47c6-8a29-701d5a6f34e3_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..878247f5a65eb6d3a2d2bb3d5f7accdcdb61c414
--- /dev/null
+++ b/ecoformerenergysavingattentionwithlinearcomplexity/fb9b7978-b38c-47c6-8a29-701d5a6f34e3_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b156a92299f7a8f9bb555219182ac811344e28b86aaab1d2273bbc8ab36853f3
+size 117127
diff --git a/ecoformerenergysavingattentionwithlinearcomplexity/fb9b7978-b38c-47c6-8a29-701d5a6f34e3_origin.pdf b/ecoformerenergysavingattentionwithlinearcomplexity/fb9b7978-b38c-47c6-8a29-701d5a6f34e3_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..cbe8944c9a483a8f77672b54eaefd95e3eb75cb4
--- /dev/null
+++ b/ecoformerenergysavingattentionwithlinearcomplexity/fb9b7978-b38c-47c6-8a29-701d5a6f34e3_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:578897e3d22534d856d49ffb10b6164cfe9645c55acbce1f5f659890f31ebc05
+size 426675
diff --git a/ecoformerenergysavingattentionwithlinearcomplexity/full.md b/ecoformerenergysavingattentionwithlinearcomplexity/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..7fd5dbc08d693c280077481ebd881fd905ed8ffc
--- /dev/null
+++ b/ecoformerenergysavingattentionwithlinearcomplexity/full.md
@@ -0,0 +1,352 @@
+# EcoFormer: Energy-Saving Attention with Linear Complexity
+
+Jing Liu* Zizheng Pan* Haoyu He Jianfei Cai Bohan Zhuang†
+
+Department of Data Science & AI, Monash University, Australia
+
+# Abstract
+
+Transformer is a transformative framework for deep learning which models sequential data and has achieved remarkable performance on a wide range of tasks, but with high computational and energy cost. To improve its efficiency, a popular choice is to compress the models via binarization which constrains the floating-point values into binary ones to save resource consumption owing to cheap bitwise operations significantly. However, existing binarization methods only aim at minimizing the information loss for the input distribution statistically, while ignoring the pairwise similarity modeling at the core of the attention mechanism. To this end, we propose a new binarization paradigm customized to high-dimensional softmax attention via kernelized hashing, called EcoFormer, to map the original queries and keys into low-dimensional binary codes in Hamming space. The kernelized hash functions are learned to match the ground-truth similarity relations extracted from the attention map in a self-supervised way. Based on the equivalence between the inner product of binary codes and the Hamming distance as well as the associative property of matrix multiplication, we can approximate the attention in linear complexity by expressing it as a dot-product of binary codes. Moreover, the compact binary representations of queries and keys in EcoFormer enable us to replace most of the expensive multiply-accumulate operations in attention with simple accumulations to save considerable on-chip energy footprint on edge devices. Extensive experiments on both vision and language tasks show that EcoFormer consistently achieves comparable performance with standard attentions while consuming much fewer resources. For example, based on PVTv2-B0 and ImageNet-1K, EcoFormer achieves a $73\%$ reduction in on-chip energy footprint with only a slight performance drop of $0.33\%$ compared to the standard attention. Code is available at https://github.com/ziplab/EcoFormer.
+
+# 1 Introduction
+
+Recently, Transformers [57] have shown rapid and exciting progress in natural language processing (NLP) [15, 14] and computer vision (CV) [17, 56] due to its extraordinary representational power. Compared with convolutional neural networks (CNNs) [30], Transformer models are generally more scalable to massive amounts of data and better at capturing long-dependency global information with less inductive bias, thus achieving better performance in many tasks [26, 38]. However, the efficiency bottlenecks, especially the high energy consumption, greatly hamper the massive deployment of Transformer models to resource-constrained edge devices, such as mobile phones and unmanned aerial vehicles, for solving a variety of real-world applications.
+
+
+Multiply-accumulate
+(a) Attention
+
+
+(b) Kernel-based Linear Attention
+Addition only
+Figure 1: Computational graphs for standard attention (left), kernel-based linear attention (middle) and the proposed EcoFormer based on kernelized hashing (right).
+
+
+(c) EcoFormer
+
+Table 1: Energy cost for different operations (on ${45}\mathrm{\;{nm}}$ CMOS technology) [21, 22, 32].
+
+| Operation | 16-bit FP Add | 16-bit FP Mult | 32-bit FP Add | 32-bit FP Mult |
| Energy (pJ) | 0.4 | 1.1 | 0.9 | 3.7 |
| Area (μm2) | 1,360 | 1,640 | 4,184 | 7,700 |
+
+To reduce the energy consumption, quantization has been actively studied to lower the bit-width representation of network weights [11, 52, 66] and/or activations [25, 68, 67]. With the most aggressive bit-width, binary quantization [49, 2, 46] has attracted much attention since it enables efficient bit-wise operations by representing values with a single bit (e.g., +1 or -1). When we only binarize weights in analogous to BinaryConnect [11], as shown in Table 1, it brings great benefits to dedicated hardware by replacing a large number of energy-hungry multiply-accumulate operations with simple energy-efficient accumulations, which saves significant on-chip area and energy required to run inference with Transformers, making them feasible to be deployed on mobile platforms with limited resources. However, the conventional binarization process typically targets at minimizing quantization errors between the original full-precision data distribution and the quantized Bernoulli distribution statistically. In other words, each token is binarized separately, where the binary representations may not well preserve the original similarity relations among tokens. This motivates us to customize the binarization process to softmax attention, the core mechanism in Transformer that encodes the pairwise similarity between tokens. To this end, we can adapt the well-established hashing methods, to map the high-dimensional queries and keys into compact binary codes (e.g., 16-bits) that are able to preserve the similarity relations in Hamming space. A simple solution is to use the locality-sensitive hashing (LSH) [1] to substitute the binary quantization counterparts.
+
+Nevertheless, another energy bottleneck exists in Transformers. Specially, given a sequence of tokens, the softmax attention obtains the attention weights by computing the inner product between a query token and all key tokens, leading to the quadratic time complexity $\mathcal{O}\left(N^2\right)$ regarding the number of tokens $N$ , as shown in Figure 1 (a). This problem is even worse for a long sequence length $N$ , especially for high resolution images in dense prediction tasks. To reduce the complexity of the softmax attention, some prior works propose to express the attention as a linear dot product of kernelized feature embeddings [45, 9]. With the associative property of matrix multiplication, the attention operation can be approximated in linear complexity $\mathcal{O}(N)$ , as illustrated by Figure 1 (b).
+
+Based on the hashing mechanism and kernel-based formulation of attention, we devise a simple yet effective energy-saving attention, called EcoFormer, which is shown in Figure 1 (c). In particular, we propose to use kernelized hashing with RBF kernel to map the queries and keys to compact binary codes. The resulting codes are valid for similarity preserving based on the good property that the codes' inner product (i.e., Hamming affinity) and Hamming distance have one-to-one correspondence [36]. Thanks to the associative property of the linear dot-product between the binary codes, the kernelized hashing attention is in linear complexity with significant energy saving. Moreover, the pairwise similarity matrix in attention can be directly used to obtain the supervision labels for hash function learning, delivering a novel self-supervised hashing paradigm. By maximizing the Hamming affinity on the similar pairs of tokens and simultaneously minimizing on the dissimilar pairs of tokens, the pairwise similarity relations between tokens can be preserved. With low-dimensional binary queries and keys, we can replace most of the energy-hungry floating-point multiplications in attention with simple additions, which greatly saves the on-chip energy footprint.
+
+To sum up, we make three main contributions: 1) We propose a new binarization paradigm to better preserve the pairwise similarity in softmax attention. In particular, we present EcoFormer, an energy-saving attention with linear complexity powered by kernelized hashing to map the queries and keys into compact binary codes. 2) We learn the kernelized hash functions based on the ground-
+
+truth Hamming affinity extracted from the attention scores in a self-supervised way. 3) Extensive experiments on CIFAR-100, ImageNet-1K and Long Range Arena show that EcoFormer is able to significantly reduce the on-chip energy cost while preserving the accuracy. For example, based on PVTv2-B0 and ImageNet-1K, EcoFormer achieves a $73\%$ reduction in on-chip energy footprint with only a marginal performance drop of $0.33\%$ compared to the standard attention.
+
+# 2 Related Work
+
+Efficient attention mechanisms. To alleviate the quadratic computational cost for vanilla attention with respect to the number of tokens, much work has endeavored developing efficient attention. One line of research performs attention only on the part of the tokens [38, 61, 4, 29, 60, 12, 58, 54]. For instance, Reformer [29], SMYRF [12], Fast Transformers [58] and LHA [54] restrict the attention to the most similar token pairs via hashing and reduces the computational complexity to $\mathcal{O}(N\log N)$ . Linformer [60] approximates the attention with low-rank factorization that reduces the length of the key and value. However, the computational complexity is dependent on the design for reducing tokens. Another line of research speeds up the vanilla attention with kernel-based methods [9, 64, 41, 28, 47]. For example, Performer [9] approximates the softmax operation with orthogonal random features. Nyströmformer [64] and SOFT [41] approximate the full self-attention matrix via matrix decomposition. Although impressive achievements have been achieved, how to develop attention that is highly energy-efficient remains under-explored, as multiplications dominate the on-chip energy consumption. AdderNet variants [8, 53] replace the energy-hungry multiplication-based similarity measurement with the energy-efficient addition-based L1 distance and argue that additions can also provide powerful feature representations. Nevertheless, this heuristic approach brings a drastic performance drop. In contrast, we are from the perspective of binarization and propose to learn kernel-based hash functions using attention scores to map the original features into compact similarity-preserving binary codes in Hamming distance, which is energy-efficient and in linear complexity $\mathcal{O}(N)$ . With the low-dimensional binary queries and keys, our EcoFormer is able to replace most of the multiplications with simple accumulations.
+
+Hashing. Hashing is an efficient nearest neighbor search method by embedding the high-dimensional data into a similarity preserving low-dimensional binary codes, based on the intuition that highly similar data should be assigned the same hash key. Hashing methods can be roughly categorized into data-independent and data-dependent schemes. The former focuses on building random hash functions and locally sensitive hashing (LSH) [19, 7] is arguably the most representative one, which guarantees the sub-linear time similarity search and is followed by non-linear extensions such as hashing with kernels [31] or on manifolds [63]. The latter can be further divided into unsupervised [37, 20, 35], semi-supervised [44, 59] and supervised hashing [36, 71, 65]. When it comes to Transformers, as self-attention encodes the pairwise similarity among tokens, hashing is thus a natural choice to efficiently retrieve similar keys given a query. Reformer is such a pioneering work, which proposes to group similar tokens in a single hash bucket to form sparse self-attention. Our EcoFormer is fundamentally different from Reformer in three aspects: 1) Reformer relies on local attention lookups to reduce the complexity while our EcoFormer is designed from a numerical perspective, where the low-dimensional binary codes are used to save the multiplications; 2) Reformer is built upon LSH with linear mapping, which cannot deal with the kernel-based formulation of attention to scale linearly with the sequence length; 3) Our hash functions are self-supervised by the pairwise affinity labels in attention, which are optimized in conjunction with network parameters and more accurate than unsupervised random projections.
+
+Binary quantization. Binarization, an extreme quantization scheme, seeks to represent the vectors by binary codes. As a result, the computationally heavy matrix multiplications become light-weight bitwise operations (i.e., xnor and popcount), yielding promising memory saving and acceleration. In general, to make binary neural networks [24] reliable in accuracy, current research targets at tackling two main challenges. The first challenge is to minimize the quantization error, basically based on learning the scaling factors [49, 6], parameterizing the quantization range and/or intervals [27, 18], and assembling multiple binary bases [34, 72], etc. Another category of studies focus on solving the non-differentiable optimization problem due to the discretization process via training with regularization [16], knowledge distillation [43, 46], relaxed optimization [23, 3], appending full-precision branches [39, 42] and so on. Apart from CNNs, there are some recent pioneering attempts targeting on binarizing Transformers. For example, BinaryBERT [2] proposes to push Transformer quantization to the limit by weight binarization. BiBERT [46] quantizes both weights,
+
+embeddings and activations of BERT [15] to 1-bit and achieves considerable savings on FLOPs and model size, but still has obvious performance drop. In contrast, we propose to customize the binarization paradigm to softmax attention from the hashing perspective, preserving high-fidelity pairwise similarity information in compact binary codes which are used to deliver linear-complexity, energy-efficient self-attention.
+
+# 3 Preliminaries
+
+# 3.1 Attention Mechanism
+
+Let $\mathbf{X} \in \mathbb{R}^{N \times D}$ be the input sequence into a standard multi-head self-attention (MSA) layer, where $N$ is the length of the input sequence and $D$ is the number of hidden dimensions. A standard MSA layer calculates a sequence of query, key and value vectors with three learnable projection matrices $\mathbf{W}_q$ , $\mathbf{W}_k$ , $\mathbf{W}_v \in \mathbb{R}^{D \times D_p}$ , which can be formulated as
+
+$$
+\left\{\mathbf {q} _ {t} \right\} _ {t = 1} ^ {N} = \mathbf {X} \mathbf {W} _ {q}, \left\{\mathbf {k} _ {t} \right\} _ {t = 1} ^ {N} = \mathbf {X} \mathbf {W} _ {k}, \left\{\mathbf {v} _ {t} \right\} _ {t = 1} ^ {N} = \mathbf {X} \mathbf {W} _ {v}, \tag {1}
+$$
+
+where $D_{p}$ refers to the number of dimensions for each head. For each query vector, the attention output is a weighted-sum over all value vectors as
+
+$$
+\operatorname {A t t e n t i o n} \left(\mathbf {q} _ {t}, \left\{\mathbf {k} _ {i} \right\}, \left\{\mathbf {v} _ {i} \right\}\right) = \sum_ {i} \frac {\exp \left(\mathbf {q} _ {t} \cdot \mathbf {k} _ {i} / \tau\right)}{\sum_ {j} \exp \left(\mathbf {q} _ {t} \cdot \mathbf {k} _ {j} / \tau\right)} \mathbf {v} _ {i}, \tag {2}
+$$
+
+where $\tau$ is the temperature for controlling the flatness of softmax and $\exp (\langle \cdot ,\cdot \rangle)$ is an exponential function. With $N$ token, the computation of attention has a quadratic complexity of $O(N^{2})$ in both space and time, which results in huge computational cost when dealing with long sequences.
+
+# 3.2 Kernel-based Linear Attention
+
+The idea behind kernel-based linear attention is to express the similarity measure in Eq. (2) as a linear dot-product of kernel embeddings, such as polynomial kernel, exponential or RBF kernel. A particular choice is to employ the finite random mapping [48] $\phi (\cdot)$ to approximate the infinite dimensional RBF kernel. Then, according to the theorem from Rahimi [48], the inner product between a pair of transformed vectors $\mathbf{x}$ and $\mathbf{y}$ with $\phi (\cdot)$ can approximate a Gaussian RBF kernel. This gives rise to an unbiased estimation to $\exp (\langle \cdot ,\cdot \rangle)$ in Eq. (2), which can be expressed as
+
+$$
+\begin{array}{l} \exp \left(\mathbf {x} \cdot \mathbf {y} / \sigma^ {2}\right) = \exp \left(\| \mathbf {x} \| ^ {2} / 2 \sigma^ {2} + \| \mathbf {y} \| ^ {2} / 2 \sigma^ {2}\right) \exp \left(- \| \mathbf {x} - \mathbf {y} \| ^ {2} / 2 \sigma^ {2}\right) \\ \approx \exp \left(\| \mathbf {x} \| ^ {2} / 2 \sigma^ {2} + \| \mathbf {y} \| ^ {2} / 2 \sigma^ {2}\right) \phi (\mathbf {\dot {x}}) ^ {\top} \phi (\mathbf {y}). \\ \end{array}
+$$
+
+Assume that the queries and keys are unit vectors, then the attention computation in Eq. (2) can be approximated by
+
+$$
+\begin{array}{l} \operatorname {A t t e n t i o n} \left(\mathbf {q} _ {t}, \left\{\mathbf {k} _ {i} \right\}, \left\{\mathbf {v} _ {i} \right\}\right) \approx \sum_ {i} \frac {\phi \left(\mathbf {q} _ {t}\right) ^ {\top} \phi \left(\mathbf {k} _ {i}\right) \mathbf {v} _ {i}}{\sum_ {j} \phi \left(\mathbf {q} _ {t}\right) ^ {\top} \phi \left(\mathbf {k} _ {j}\right)} (4a) \\ = \frac {\phi (\mathbf {q} _ {t}) ^ {\top} \sum_ {i} \phi (\mathbf {k} _ {i}) \otimes \mathbf {v} _ {i}}{\phi (\mathbf {q} _ {t}) ^ {\top} \sum_ {j} \phi (\mathbf {k} _ {j})}, (4b) \\ \end{array}
+$$
+
+where $\otimes$ refers to the outer product. Recent works have shown that kernel-based linear attentions perform favorably against the original softmax attention on machine translation [45] and protein sequence modeling [9]. However, although the complexity is reduced into linear, the intensive floating-point multiplications in Eq. (4b) still consume a large amount of energy, which can quickly drain the batteries on mobile/edge platforms.
+
+# 3.3 Binary Quantization
+
+Following [49], binary quantization typically estimates the full-precision $\mathbf{u} \in \mathbb{R}^n$ using a binary $\hat{\mathbf{u}} \in \{+1, -1\}^n$ and a scaling factor $\alpha \in \mathbb{R}^+$ such that $\mathbf{u} \approx \alpha \hat{\mathbf{u}}$ holds. To find an accurate estimation, existing methods [49, 42, 34, 2, 46] minimize the quantization error as
+
+$$
+\alpha^ {*}, \hat {\mathbf {u}} ^ {*} = \arg \min \left\| \mathbf {u} - \alpha \hat {\mathbf {u}} \right\|. \tag {5}
+$$
+
+By solving Problem (5), we have $\hat{\mathbf{u}} = \mathrm{sign}(\mathbf{u})$ and $\alpha = \frac{1}{n}\| \mathbf{u}\|_{\ell 1}$ , where $\mathrm{sign}(u)$ returns 1 if $u\geq 0$ and -1 if $u < 0$ . Since the sign function is non-differentiable, the straight-through estimator (STE) [5] is applied to approximate the gradient such as using the gradient of hard tanh [25] or piecewise polynomial function [39].
+
+# 4 Proposed Method
+
+To reduce the energy consumption of self-attention, one may perform binary quantization [46, 2] on the queries $\{\mathbf{q}_t\}_{t=1}^N$ and keys $\{\mathbf{k}_t\}_{t=1}^N$ . In this case, we can replace most of the energy-expensive multiplications with the energy-efficient bit-wise operations. However, existing binary quantization methods only focus on minimizing the quantization error between the original full-precision values and the binary ones as in Eq. (5), which fails to preserve the pairwise semantic similarity between different tokens in attention, leading to performance degradation.
+
+Note that the attention can be seen as applying kernel smoother over pairwise tokens where the kernel scores denote the similarity of the token pairs, as mentioned in Section 3.2. Motivated by this, we propose a new binarization method that applies kernelized hashing with Gaussian RBF to map the original high-dimensional queries/keys to low-dimensional similarity-preserving binary codes in Hamming space. The proposed framework, which we dub EcoFormer, is depicted in Figure 1 (c). To maintain the semantic similarity in attention, we learn the hash functions in a self-supervised manner. By exploiting the associative property of the linear dot-product between binary codes and the equivalence between the code inner products (i.e., Hamming affinity) and the Hamming distances, we are able to approximate the self-attention in linear time with low energy cost. In the following, we first introduce the kernelized hashing attention in Section 4.1 and then show how to learn the hash functions in a self-supervised way in Section 4.2.
+
+# 4.1 Kernelized Hashing Attention
+
+Before applying hash functions, we let the queries $\{\mathbf{q}_t\}_{t=1}^N$ and keys $\{\mathbf{k}_t\}_{t=1}^N$ to be identical following [29, 41]. In this way, we can then apply kernelized hash functions $H: \mathbb{R}^{D_p} \mapsto \{1, -1\}^b$ without explicitly applying transformation $\phi(\cdot)$ mentioned in Section 3.2 to map $\mathbf{q}_i$ and $\mathbf{k}_j$ into $b$ -bit binary codes $H(\mathbf{q}_i)$ and $H(\mathbf{k}_j)$ , respectively (see Section 4.2). In this case, the Hamming distance between them can be defined as
+
+$$
+\mathcal {D} \left(H (\mathbf {q} _ {i}), H (\mathbf {k} _ {j})\right) = \sum_ {r = 1} ^ {b} \mathbb {1} \left\{H _ {r} (\mathbf {q} _ {i}) \neq H _ {r} (\mathbf {k} _ {j}) \right\}, \tag {6}
+$$
+
+where $H_{r}(\cdot)$ is the $r$ -th bit of the binary codes; $\mathbb{1}\{A\}$ is an indicator function that returns 1 if $A$ is satisfied and otherwise returns 0. With $\mathcal{D}(H(\mathbf{q}_i), H(\mathbf{k}_j))$ , the codes inner product between $H(\mathbf{q}_i)$ and $H(\mathbf{k}_j)$ can be formulated as
+
+$$
+\begin{array}{l} H \left(\mathbf {q} _ {i}\right) ^ {\top} H \left(\mathbf {k} _ {j}\right) = \sum_ {r = 1} ^ {b} \mathbb {1} \left\{H _ {r} \left(\mathbf {q} _ {i}\right) = H _ {r} \left(\mathbf {k} _ {j}\right) \right\} - \sum_ {r = 1} ^ {b} \mathbb {1} \left\{H _ {r} \left(\mathbf {q} _ {i}\right) \neq H _ {r} \left(\mathbf {k} _ {j}\right) \right\} \tag {7} \\ = b - 2 \sum_ {r = 1} ^ {b} \mathbb {1} \left\{H _ {r} \left(\mathbf {q} _ {i}\right) \neq H _ {r} \left(\mathbf {k} _ {j}\right) \right\} = b - 2 \mathcal {D} \left(H \left(\mathbf {q} _ {i}\right), H \left(\mathbf {k} _ {j}\right)\right). \\ \end{array}
+$$
+
+Importantly, Eq. (7) shows the equivalence between the Hamming distance and the codes inner product since there is a one-to-one correspondence. By substituting with the hashed queries and keys in Eq. (4a), we can approximate the self-attention as
+
+$$
+\operatorname {A t t e n t i o n} \left(\mathbf {q} _ {t}, \left\{\mathbf {k} _ {i} \right\}, \left\{\mathbf {v} _ {i} \right\}\right) \approx \sum_ {i} \frac {H \left(\mathbf {q} _ {t}\right) ^ {\top} H \left(\mathbf {k} _ {i}\right) \mathbf {v} _ {i}}{\sum_ {j} H \left(\mathbf {q} _ {t}\right) ^ {\top} H \left(\mathbf {k} _ {j}\right)}. \tag {8}
+$$
+
+Note that $H(\mathbf{q}_t)^\top H(\mathbf{k}_j) \in [-b, b]$ . To avoid zero in denominator, we introduce a bias term $2^c$ to each inner product so that $H(\mathbf{q}_t)^\top H(\mathbf{k}_j) + 2^c > 0$ , having no effect on the similarity measure. Here, we can simply set $c$ to $\lceil \log_2(b + 1) \rceil$ where $\lceil u \rceil$ returns the least integer greater than or equal to $u$ . Using the associative property of matrix multiplication, we approximate the self-attention as
+
+$$
+\begin{array}{l} \operatorname {A t t e n t i o n} \left(\mathbf {q} _ {t}, \left\{\mathbf {k} _ {i} \right\}, \left\{\mathbf {v} _ {i} \right\}\right) \approx \sum_ {i} \frac {\left(H \left(\mathbf {q} _ {t}\right) ^ {\top} H \left(\mathbf {k} _ {i}\right) + 2 ^ {c}\right) \mathbf {v} _ {i}}{\sum_ {j} \left(H \left(\mathbf {q} _ {t}\right) ^ {\top} H \left(\mathbf {k} _ {j}\right) + 2 ^ {c}\right)} \tag {9} \\ = \frac {H (\mathbf {q} _ {t}) ^ {\top} \sum_ {i} H (\mathbf {k} _ {i}) \otimes \mathbf {v} _ {i} + \sum_ {i} 2 ^ {c} \mathbf {v} _ {i} ^ {\top}}{H (\mathbf {q} _ {t}) ^ {\top} \sum_ {j} H (\mathbf {k} _ {j}) + 2 ^ {c} N}. \\ \end{array}
+$$
+
+In practice, the multiplications between the binary codes and the full-precision values in Eq. (9) can be replaced by simple additions and subtractions, which greatly reduce the computational overhead in terms of on-chip energy footprint. Moreover, the multiplications with a powers-of-two $2^{c}$ can also be implemented by efficient bit-shift operations. As a result, the only multiplications come from the element-wise divisions between the numerator and denominator.
+
+# 4.2 Self-supervised Hash Function Learning
+
+Given queries $\mathcal{Q} = \{\mathbf{q}_1,\dots ,\mathbf{q}_N\} \subset \mathbb{R}^{D_p}$ , we seek to learn a group of hash functions $h:\mathbb{R}^{D_p}\mapsto$ $\{1, - 1\}$ . Instead of explicitly applying the transformation function $\phi (\cdot)$ mentioned in Section 3.2, we compute the hash functions with a kernel function $\kappa (\mathbf{q}_i,\mathbf{q}_j):\mathbb{R}^{D_p}\times \mathbb{R}^{D_p}\mapsto \mathbb{R}$ . Given $\mathbf{Q} = [\mathbf{q}_1,\dots ,\mathbf{q}_N]^\top \in \mathbb{R}^{N\times D_p}$ , we randomly sample $m$ queries $\mathbf{q}_{(1)},\ldots ,\mathbf{q}_{(m)}$ from $\mathcal{Q}$ as support samples following the kernel-based supervised hashing (KSH) [36] and define a hash function $h$ as
+
+$$
+h (\mathbf {Q}) = \operatorname {s i g n} \left(\sum_ {j = 1} ^ {m} \left(\kappa \left(\mathbf {q} _ {(j)}, \mathbf {Q}\right) - \mu_ {j}\right) a _ {j}\right) = \operatorname {s i g n} \left(\mathbf {g} (\mathbf {Q}) \mathbf {a}\right), \tag {10}
+$$
+
+where $\mathbf{a} = [a_1, \dots, a_m]^\top$ is the weight of $h$ , $\mu_j = \frac{1}{n} \sum_{i=1}^{N} \kappa(\mathbf{q}_{(j)}, \mathbf{q}_i)$ is to normalize the kernel function to zero-mean, and $\mathbf{g}: \mathbb{R}^{D_p} \mapsto \mathbb{R}^m$ is a mapping defined by $\mathbf{g}(\mathbf{Q}) = [\kappa(\mathbf{q}_{(1)}, \mathbf{Q}) - \mu_1, \dots, \kappa(\mathbf{q}_{(m)}, \mathbf{Q}) - \mu_m] \in \mathbb{R}^{N \times m}$ . Then, we define the kernelized hash function $H(\cdot)$ as
+
+$$
+H (\mathbf {Q}) = \left[ h _ {1} (\mathbf {Q}), \dots , h _ {b} (\mathbf {Q}) \right] = \left[ \begin{array}{c} h _ {1} \left(\mathbf {q} _ {1}\right), \dots , h _ {b} \left(\mathbf {q} _ {1}\right) \\ \dots \dots \\ h _ {1} \left(\mathbf {q} _ {N}\right), \dots , h _ {b} \left(\mathbf {q} _ {N}\right) \end{array} \right] = \operatorname {s i g n} \left(\mathbf {g} (\mathbf {Q}) \mathbf {A}\right), \tag {11}
+$$
+
+where $\mathbf{A} = [\mathbf{a}_1, \dots, \mathbf{a}_b] \in \mathbb{R}^{m \times b}$ , and $h_r(\mathbf{Q}) = \mathrm{sign}(\mathbf{g}(\mathbf{Q})\mathbf{a}_r)$ is the hash function for the $r$ -th bit. To guide the learning of the binary codes, we hope that similar token pairs will have the minimal Hamming distance while dissimilar token pairs will have the maximal distance. Nevertheless, directly optimizing the Hamming distance is difficult due to the non-convex and non-smooth formulation in Eq. (6). Utilizing the equivalence between the code inner products and the Hamming distances in Eq. (7), we instead conduct optimization based on the Hamming affinity to minimize the reconstruction error as
+
+$$
+\left. \min _ {\mathbf {A}} \| H (\mathbf {Q}) H (\mathbf {Q}) ^ {\top} - b \mathbf {Y} \right\| _ {F} ^ {2} = \min _ {\mathbf {A}} \left\| \sum_ {r = 1} ^ {b} h _ {r} (\mathbf {Q}) h _ {r} (\mathbf {Q}) ^ {\top} - b \mathbf {Y} \right\| _ {F} ^ {2}, \tag {12}
+$$
+
+where $\| \cdot \| _F$ is the Frobenius norm and $\mathbf{Y}\in \mathbb{R}^{N\times N}$ is the target Hamming affinity matrix. To preserve the similarity relations between queries and keys, we use the attention scores as the self-supervised information to construct $\mathbf{Y}$ . Let $S$ and $\mathcal{U}$ be the similar and dissimilar pairs of tokens. We obtain $S$ and $\mathcal{U}$ by selecting the token pairs with the Top- $l$ largest and smallest attention scores. We then construct pairwise labels $\mathbf{Y}$ as
+
+$$
+\mathbf {Y} _ {i j} = \left\{ \begin{array}{l l} 1, & \left(\mathbf {q} _ {i}, \mathbf {q} _ {j}\right) \in \mathcal {S} \\ - 1, & \left(\mathbf {q} _ {i}, \mathbf {q} _ {j}\right) \in \mathcal {U} \\ 0, & \text {o t h e r w i s e .} \end{array} \right. \tag {13}
+$$
+
+However, Problem (12) is NP-hard. To solve it efficiently, we adapt discrete cyclic coordinate descent to learn binary codes sequentially. Specifically, we only solve $\mathbf{a}_r$ once the previous $\mathbf{a}_1,\dots ,\mathbf{a}_{r - 1}$ have been optimized. Let $\hat{\mathbf{Y}}_{r - 1} = b\mathbf{Y} - \sum_{t = 1}^{r - 1}h_t(\mathbf{Q})h_t(\mathbf{Q})^\top$ be the residual matrix, where $\hat{\mathbf{Y}}_0 = b\mathbf{Y}$ . Then, we can minimize the following objective to obtain $\mathbf{a}_r$
+
+$$
+\min _ {\mathbf {a} _ {r}} \left\| h _ {r} (\mathbf {Q}) h _ {r} (\mathbf {Q}) ^ {\top} - \hat {\mathbf {Y}} _ {r - 1} \right\| _ {F} ^ {2} = \min _ {\mathbf {a} _ {r}} - 2 h _ {r} (\mathbf {Q}) ^ {\top} \hat {\mathbf {Y}} _ {r - 1} h _ {r} (\mathbf {Q}) + C, \tag {14}
+$$
+
+where $C = \left(h_r(\mathbf{Q})^\top h_r(\mathbf{Q})\right)^2 + \mathrm{tr}\left(\hat{\mathbf{Y}}_{r-1}\right)$ is a constant. Note that $\hat{\mathbf{Y}}_{r-1}$ is a symmetric matrix. Therefore, Problem (14) is a standard binary quadratic programming problem, which can be efficiently solved by many existing methods, such as the LBFGS-B solver [69] and block graph cuts [33]. To learn $\mathbf{a}_r$ in conjunction with network parameters, we propose to solve Problem (14) using the gradient-based methods. For the non-differentiable sign function, we use STE [5] to approximate the gradient using hard tanh as mentioned in Section 3.3. Note that learning the hash functions for each epoch is computationally expensive yet unnecessary. We only learn the hash functions per $\tau$ epoch.
+
+Table 2: Main results on ImageNet-1K. The number of multiplications, additions, as well as on-chip energy consumption are calculated based on an image of resolution $224 \times 224$ . The throughput is measured with a mini-batch size of 32 on a single NVIDIA RTX 3090 GPU.
+
+| Model | Method | #Mul. (B) | #Add. (B) | Energy (B pJ) | Throughput (images/s) | Top-1 Acc. (%) |
| PVTv2-B0 [62] | MSA | 2.02 | 1.99 | 9.25 | 850 | 70.77 |
| Ours | 0.54 | 0.56 | 2.49 | 1379 | 70.44 |
| PVTv2-B1 | MSA | 5.02 | 5.00 | 23.07 | 621 | 78.83 |
| Ours | 2.03 | 2.09 | 9.39 | 874 | 78.38 |
| PVTv2-B2 | MSA | 8.64 | 8.60 | 39.71 | 404 | 81.82 |
| Ours | 3.85 | 3.97 | 17.82 | 483 | 81.28 |
| PVTv2-B3 | MSA | 11.86 | 11.82 | 54.56 | 310 | 82.26 |
| Ours | 6.54 | 6.72 | 30.25 | 325 | 81.96 |
| PVTv2-B4 | MSA | 15.97 | 15.93 | 73.43 | 247 | 82.42 |
| Ours | 9.57 | 9.82 | 44.25 | 249 | 81.90 |
| Twins-SVT-S [10] | MSA | 5.96 | 5.91 | 27.36 | 426 | 81.66 |
| Ours | 2.72 | 2.81 | 12.59 | 576 | 80.22 |
+
+# 5 Experiments
+
+# 5.1 Comparisons on ImageNet-1K
+
+To investigate the effectiveness of the proposed method, we conduct experiments on ImageNet-1K [30], a large-scale image classification dataset that contains $\sim 1.2\mathrm{M}$ training images from 1K categories and 50K validation images. We compare our kernelized hashing attention with standard MSA by adapting the two attention approaches into two popular vision Transformer frameworks PVTv2 [62] and Twins [10]. We measure model performance by the Top-1 accuracy. Furthermore, as FLOPs cannot accurately reflect the computational cost in our proposed method, we measure the model complexity by the number of multiplications and additions, separately, as done in [53]. Specifically, we calculate FLOPs following [61], where we count the multiply-accumulate operations for all layers. In this case, each multiply-accumulate operation consists of an addition and a multiplication. We also count the multiplications in the scaling operations. Moreover, we report the on-chip energy consumption according to Table 1 and the throughput with a mini-batch size of 32 on a single NVIDIA RTX 3090 GPU.
+
+Implementation details. All training images are resized to $256 \times 256$ , and $224 \times 224$ patches are randomly cropped from an image or its horizontal flip, with the per-pixel mean subtracted. To obtain the MSA baselines, we first replace the original attention layers in PVTv2 [62] and Twins [10] with standard MSAs and initialize the models with the pretrained weights on ImageNet-1K. Next, we finetune each model on ImageNet-1K with 100 epochs. Based the pretrained MSA weights, we then apply our approach to each model and finetune on ImageNet-1K with 30 epochs. All models in this experiment are trained on 8 V100 GPUs with a total batch size of 256. We set the initial learning rate to $2.5 \times 10^{-5}$ for PVTv2 and $1.25 \times 10^{-4}$ for Twins. We use AdamW optimizer [40] with a cosine decay learning rate scheduler. All other hyperparameters are the same as in PVTv2. Also note that recent hierarchical ViTs [62, 38, 10] have multiple stages to incorporate pyramid feature maps. At the last stage, they usually apply standard MSAs due to the comparably low-resolution feature maps. This design is also adopted in PVTv2 and Twins. Therefore, we follow the common practice and do not modify the attention layers at the last stage. For the hash functions learning, we set the number of support samples $m$ and update interval $\tau$ to 25 and 30, respectively. The hyper-parameter $l$ in constructing pairwise labels $\mathbf{Y}$ is set to 10. We set the hash bit $b$ to 16.
+
+Results analysis. We report the results in Table 2. In general, our baseline MSA has more multiplications than additions. In contrast, our EcoFormer replaces most of the floating-point multiplications in attention with simple additions. Therefore, there are more additions than multiplications in our EcoFormer. Compared to MSA, our method achieves lower computational complexity, less energy consumption and higher throughput with comparable performance. For example, based on PVTv2-B0, our method saves around $73\%$ multiplications and $72\%$ additions, as well as reducing $73\%$ on-chip energy consumption, which demonstrates the energy-efficiency of our approach. With more efficient accumulation implementation, the throughput of our EcoFormer can be further improved. Besides, a larger model comes with a larger proportion of computational and on-chip energy cost dominated by FFNs, as shown in Figure 2. In this case, as our approach focuses on the attention layers, the energy-
+
+
+Figure 2: FLOPs and on-chip energy footprint percentage of attention layers (Attn) and feed-forward layers (FFN) in different variants of PVTv2 with standard MSAs. For a bigger model, FFN takes a larger proportion of the computational cost and on-chip energy footprint.
+
+
+
+saving from larger models is comparably less than smaller models (e.g., PVTv2-B0 vs. PVTv2-B4). Nonetheless, we still reduce significant computational cost and on-chip energy consumption. For example, on PVTv2-B4, we save around $40\%$ on-chip energy consumption. Compared with PVTv2, the performance drop of our method is slightly larger on Twins. One possible reason is that our method may be sensitive to the conditional positional encodings in Twins.
+
+# 5.2 Comparisons on Long Range Arena
+
+To evaluate the performance of different efficient attentions under long-context scenarios, we train our EcoFormer on two tasks, Text and Retrieval from the Long Range Arena (LRA) benchmark [55] following the settings of [70]. Our implementations are based on the released code of [64]. We use the same hyper-parameters $m$ , $\tau$ and $b$ as in ImageNet-1K experiments. We show the results in Table 3. From the table, our EcoFormer achieves comparable performance with much lower on-chip energy consumption. For example, on Text, compared with MSA, our method saves around $94.6\%$ multiplications and $93.7\%$ additions as well as $94.5\%$ on-chip energy consumption, which is more efficient than existing attention mechanisms.
+
+Table 3: Comparisons of different methods on Long Range Arena (LRA). We report the classification accuracy (%) for Text as well as Retrieval and average accuracy across two tasks. * denotes that we obtain the results from the original paper.
+
+| Method | #Mul. (B) | #Add. (B) | Energy (B pJ) | Text (4K) | Retrieval (4K) | Average |
| Transformer | 4.63 | 4.57 | 21.25 | 64.87 | 79.62 | 72.25 |
| Performer [9] | 0.83 | 0.84 | 3.83 | 64.82 | 79.08 | 71.95 |
| Linformer [60] | 0.81 | 0.81 | 3.74 | 57.03 | 78.11 | 67.57 |
| Reformer [29] | 0.54 | 0.54 | 2.49 | 65.19 | 79.46 | 72.33 |
| Combiner* [50] | 0.51 | 0.51 | 2.34 | 64.36 | 56.10 | 60.23 |
| EcoFormer | 0.25 | 0.29 | 1.17 | 64.79 | 78.67 | 71.73 |
+
+# 5.3 Ablation Study
+
+In this section, we evaluate the effectiveness of our EcoFormer by comparing it with different binarization approaches and efficient attention mechanisms. By default, we train each model from scratch on CIFAR-100 with 2 GPUs for 300 epochs. The total batch size is 64. The initial learning rate is $6.25 \times 10^{-6}$ . For the hash functions learning, we set update interval $\tau$ to 300. All the other hyperparameters are the same as in ImageNet-1K experiments.
+
+Table 4: Performance comparisons with different binarization methods on CIFAR-100.
+
+| Model | Method | #Mul. (B) | #Add. (B) | Energy (B pJ) | Top-1 Acc. (%) |
| PVTv2-B0 | FP-EcoFormer | 0.94 | 0.94 | 4.33 | 70.78 |
| Bi-EcoFormer | 0.63 | 0.83 | 3.09 | 70.06 |
| EcoFormer | 0.54 | 0.56 | 2.49 | 71.23 |
| Twins-SVT-S | FP-EcoFormer | 5.96 | 5.91 | 27.36 | 80.04 |
| Bi-EcoFormer | 3.01 | 3.59 | 14.38 | 80.04 |
| EcoFormer | 2.72 | 2.81 | 12.58 | 80.31 |
+
+Quantization vs. hashing. To investigate the effect of different binarization methods, we compare our EcoFormer with the following methods: FP-EcoFormer: Based on EcoFormer, we do not
+
+binarize queries and keys in attentions. Bi-EcoFormer: Relying on EcoFormer, we use the same binary quantization [25] as BinaryBERT [2] and BiBERT [46] to obtain binarized queries and keys instead of our proposed hash functions. For fair comparisons, the attention operations in the compared method are in linear complexity. We apply different methods to PVTv2-B0 and Twins-SVT-S and report the results in Table 4. We observe that our EcoFormer consistently outperforms Bi-EcoFormer on different frameworks. For example, based on PVTv2-B0, our EcoFormer surpasses Bi-EcoFormer by $1.17\%$ in terms of the Top-1 accuracy. Compared with binary quantization, our proposed self-supervised hash functions preserve the pairwise similarity of attention, leading to better performance. Moreover, our EcoFormer does not need to explicitly compute transformation $\phi(\cdot)$ as in Eq. (4b). Therefore, the energy cost of our EcoFormer is lower than Bi-EcoFormer.
+
+Table 5: Performance comparisons with different hash functions regarding PVTv2-B0 on CIFAR-100.
+
+| Method | #Mul. (B) | #Add. (B) | Energy (B pJ) | Top-1 Acc. (%) |
| LSH-EcoFormer | 0.68 | 0.69 | 3.12 | 70.18 |
| KLSH-EcoFormer | 0.54 | 0.56 | 2.49 | 70.66 |
| EcoFormer | 0.54 | 0.56 | 2.49 | 71.23 |
+
+Effect of different hash functions. To investigate the effect of different hash functions, we include the following methods for comparisons: LSH-EcoFormer: Relying on EcoFormer, we use Locality-Sensitive Hashing (LSH) [13] rather than our proposed kernelized hash function. KLSH-EcoFormer: Based on EcoFormer, we replace the proposed hash function with Kernelized Locality-Sensitive Hashing (KLSH) [31]. We report the results in Table 5. We can observe that KLSH-EcoFormer outperforms LSH-EcoFormer by $0.48\%$ in terms of the Top-1 accuracy with less on-chip energy consumption. The reason can be attributed to that LSH is based on random linear projection, which can not deal with the non-linear softmax attention well. Critically, our EcoFormer further improves the performance by $0.57\%$ on the Top-1 accuracy. Compared with random hashing in KLSH, our EcoFormer learns the hash functions with additional self-supervised information. Therefore, our learned binary codes are better at preserving the token similarity.
+
+Table 6: Comparison with other efficient attention methods regarding PVTv2-B0 [62] on CIFAR-100.
+
+| Method | #Mul. (B) | #Add. (B) | Energy (B pJ) | Top-1 Acc. (%) |
| Transformer | 2.02 | 1.99 | 9.25 | 71.44 |
| Performer [9] | 0.94 | 0.94 | 4.33 | 70.78 |
| Linformer [60] | 0.69 | 0.69 | 3.18 | 71.17 |
| Reformer [29] | 1.62 | 1.63 | 7.44 | 70.56 |
| EcoFormer | 0.54 | 0.56 | 2.49 | 71.23 |
+
+Comparing with other efficient attention mechanisms. To compare EcoFormer with different attention mechanisms, we conduct experiments on CIFAR-100 based on PVTv2-B0 in Table 6. In our experiments, we directly replace the attention layers with each compared method in PVTv2-B0 [62]. In general, compared to other efficient attention mechanisms, EcoFormer saves more computations and reduces more on-chip energy consumption while achieving better performance. Particularly, benefiting from the multiplication-saving operations
+
+Table 7: Latency and energy comparisons with different attention methods. We measure the latency and energy of an attention layer with a batch size of 16, a sequence length of 3,136 and an embedding dimension of 32 on a BitFusion [51] simulator.
+
+| Method | Latency (ms) | Energy (pJ) |
| Transformer | 0.0036 | 85,692.18 |
| Performer [9] | 0.0019 | 41,113.64 |
| Linformer [60] | 0.0018 | 45,770.61 |
| Reformer [29] | 0.0024 | 57,305.47 |
| EcoFormer | 0.0010 | 24,990.75 |
+
+and low-dimensional binary queries and keys, EcoFormer saves more on-chip energy than Performer. Also note that since the proposed kernelized hash function $H(\cdot)$ does not need to explicitly apply transformation $\phi(\cdot)$ to the queries and keys as in Eq. (4b), EcoFormer simultaneously reduces more multiplications and additions than Performer. Besides, Linformer achieves competitive results. However, as the size of the learnable low-rank projection parameters depends on the length of the input sequence, Linformer is not scalable to different image resolutions, whereas EcoFormer with sufficient bits is agnostic to the sequence length.
+
+Latency and energy on BitFusion [51]. To show the actual energy consumption and latency, we test different methods on a simulator of BitFusion, a bit-flexible microarchitecture synthesized in 45 nm technology. From Table 7, EcoFormer shows much lower latency and on-chip energy than the other efficient attention methods, which further verifies the advantage of EcoFormer.
+
+Effect of training from scratch on ImageNet-1K. To explore the effect of training from scratch, we apply EcoFormer to PVTv2-B0 and PVTv2-B1. We follow the experimental settings mentioned in Section 5.1 except that we train the model from scratch with 300 epochs. The initial learning rate is set to $2.5 \times 10^{-4}$ . From Table 8, EcoFormer achieves comparable performance while significantly reducing the computational complexity and on-chip energy consumption. The accuracy drop from discretization comes from the gradient approximation for the non-differentiable sign function, which can be mitigated by more advanced optimization methods, such as regularization [16], knowledge distillation [43, 46], relaxed optimization [23, 3], appending full-precision branches [39, 42], etc.
+
+Table 8: Performance comparisons of different methods on ImageNet-1K. All the models are trained from scratch. The number of multiplications, additions, and on-chip energy consumption are calculated based on an image of resolution $224 \times 224$ .
+
+| Model | Method | #Mul. (B) | #Add. (B) | Energy (B pJ) | Top-1 Acc. (%) |
| PVTv2-B0 | MSA | 2.02 | 1.99 | 9.25 | 69.72 |
| Ours | 0.54 | 0.56 | 2.49 | 68.70 |
| PVTv2-B1 | MSA | 5.02 | 5.00 | 23.07 | 78.34 |
| Ours | 2.03 | 2.09 | 9.39 | 77.49 |
+
+Effect of different $m$ . To investigate the effect of different numbers of support samples $m$ , we train EcoFormer with different $m$ based on PVTv2-B0. We report the results on CIFAR-100 in Table 9. As we increase $m$ , the performance becomes better along with the increase in on-chip energy consumption. For example, the model obtained with $m = 15$ outperforms that of $m = 10$ by $0.19\%$ on the Top-1 accuracy with little additional energy cost. We speculate that, with more support samples, we can capture more accurate statistics in Eq. (10) and hence lead to better performance. Since our EcoFormer achieves the best performance with $m = 25$ , we use it by default in our experiments.
+
+Table 9: Performance comparisons with different #support samples $m$ . We report the results of PVTv2-B0 on CIFAR-100.
+
+| m | #Mul. (B) | #Add. (B) | Energy (B pJ) | Top-1 Acc. (%) |
| 10 | 0.53 | 0.55 | 2.46 | 70.73 |
| 15 | 0.53 | 0.56 | 2.47 | 70.92 |
| 20 | 0.53 | 0.56 | 2.48 | 70.81 |
| 25 | 0.54 | 0.56 | 2.49 | 71.23 |
+
+# 6 Conclusion and Future Work
+
+In this paper, we have presented a novel energy-saving attention mechanism with linear complexity to save the vast majority of multiplications from a new binarization perspective, making the deployment of Transformer models at scale feasible on edge devices. We are inspired by the fact that conventional binarization methods are built upon statistical quantization error minimization without considering to preserve the pairwise similarity relations between tokens. To this end, we customize binarization to softmax attention by mapping the original token features into compact binary codes in Hamming space using a set of kernel-based hash functions, where the similarity can be measured by codes dot product. The hash functions for queries/keys are learned to encourage the Hamming affinity of a token pair to be close to the target obtained from the attention scores, in a self-supervised way. Extensive experiments have demonstrated that EcoFormer saves significant on-chip energy footprint while achieving comparable performance with standard attentions on ImageNet-1K, Long Range Arena and CIFAR-100. In terms of the future work, we can further binarize the value vectors in attention, multi-layer perceptrons and non-linearities in Transformer to make it fully binarized for more significant on-chip energy-saving. We may also extend EcoFormer to other NLP tasks such as machine translation and speech analysis tasks to make it more impactful to wider communities.
+
+Limitations and societal impact. We have shown that EcoFormer is more energy-efficient compared to the standard attention. However, in practice, the addition operations between binary codes and floating-point numbers will require specialized GPU kernels (e.g., customized CUDA operators) for further acceleration. Moreover, for the short sequence scenario, our EcoFormer suffers from severe performance drop due to the limited representational capability. Our work potentially brings some negative societal impacts that training large Transformer models requires extensive computations, resulting in financial and environmental costs. A promising solution is to jointly optimize training and inference efficiency.
+
+# References
+
+[1] A. Andoni, P. Indyk, T. Laarhoven, I. Razenshteyn, and L. Schmidt. Practical and optimal lsh for angular distance. In NeurIPS, volume 28, pages 1225-1233, 2015.
+[2] H. Bai, W. Zhang, L. Hou, L. Shang, J. Jin, X. Jiang, Q. Liu, M. Lyu, and I. King. Binarybert: Pushing the limit of bert quantization. In ACL, pages 4334-4348, 2021.
+[3] Y. Bai, Y.-X. Wang, and E. Liberty. Proxquant: Quantized neural networks via proximal operators. In ICLR, pages 1-19, 2019.
+[4] I. Beltagy, M. E. Peters, and A. Cohan. Longformer: The long-document transformer. arXiv preprint arXiv:2004.05150, 2020.
+[5] Y. Bengio. Estimating or propagating gradients through stochastic neurons. arXiv preprint arXiv:1305.2982, 2013.
+[6] A. Bulat and G. Tzimiropoulos. Xnor-net++: Improved binary neural networks. In BMVC, page 62, 2019.
+[7] M. S. Charikar. Similarity estimation techniques from rounding algorithms. In STOC, pages 380-388, 2002.
+[8] H. Chen, Y. Wang, C. Xu, B. Shi, C. Xu, Q. Tian, and C. Xu. Addernet: Do we really need multiplications in deep learning? In CVPR, pages 1468-1477, 2020.
+[9] K. M. Choromanski, V. Likhosherstov, D. Dohan, X. Song, A. Gane, T. Sarlos, P. Hawkins, J. Q. Davis, A. Mohiuddin, L. Kaiser, D. B. Belanger, L. J. Colwell, and A. Weller. Rethinking attention with performers. In ICLR, pages 1-38, 2021.
+[10] X. Chu, Z. Tian, Y. Wang, B. Zhang, H. Ren, X. Wei, H. Xia, and C. Shen. Twins: Revisiting the design of spatial attention in vision transformers. In NeurIPS, pages 9355-9366, 2021.
+[11] M. Courbariaux, Y. Bengio, and J.-P. David. Binaryconnect: Training deep neural networks with binary weights during propagations. In NeurIPS, volume 28, pages 3123-3131, 2015.
+[12] G. Daras, N. Kitaev, A. Odena, and A. G. Dimakis. Smyrf-efficient attention using asymmetric clustering. In NeurIPS, volume 33, pages 6476-6489, 2020.
+[13] M. Datar, N. Immorlica, P. Indyk, and V. S. Mirrokni. Locality-sensitive hashing scheme based on p-stable distributions. In SoCG, pages 253-262, 2004.
+[14] M. Dehghani, S. Gouws, O. Vinyals, J. Uszkoreit, and L. Kaiser. Universal transformers. In ICLR, pages 1-23, 2019.
+[15] J. Devlin, M. Chang, K. Lee, and K. Toutanova. BERT: pre-training of deep bidirectional transformers for language understanding. In J. Burstein, C. Doran, and T. Solorio, editors, *NAACL-HLT*, pages 4171–4186, 2019.
+[16] R. Ding, T.-W. Chin, Z. Liu, and D. Marculescu. Regularizing activation distribution for training binarized deep networks. In CVPR, pages 11408-11417, 2019.
+[17] A. Dosovitskiy, L. Beyer, A. Kolesnikov, D. Weissenborn, X. Zhai, T. Unterthiner, M. Dehghani, M. Minderer, G. Heigold, S. Gelly, J. Uszkoreit, and N. Houlsby. An image is worth 16x16 words: Transformers for image recognition at scale. In ICLR, pages 1-21, 2021.
+[18] S. K. Esser, J. L. McKinstry, D. Bablani, R. Appuswamy, and D. S. Modha. Learned step size quantization. In ICLR, pages 1-12, 2020.
+[19] A. Gionis, P. Indyk, and R. Motwani. Similarity search in high dimensions via hashing. In Vldb, page 518-529, 1999.
+[20] Y. Gong, S. Lazebnik, A. Gordo, and F. Perronnin. Iterative quantization: A procrustean approach to learning binary codes for large-scale image retrieval. TPAMI, 35(12):2916-2929, 2012.
+[21] S. Han, X. Liu, H. Mao, J. Pu, A. Pedram, M. A. Horowitz, and W. J. Dally. Eie: Efficient inference engine on compressed deep neural network. ACM SIGARCH Computer Architecture News, 44(3):243-254, 2016.
+[22] M. Horowitz. 1.1 computing's energy problem (and what we can do about it). In ISSCC, pages 10-14, 2014.
+
+[23] L. Hou and J. T. Kwok. Loss-aware weight quantization of deep networks. In ICLR, pages 1-16, 2018.
+[24] I. Hubara, M. Courbariaux, D. Soudry, R. El-Yaniv, and Y. Bengio. Binarized neural networks. In NeurIPS, pages 4107-4115, 2016.
+[25] I. Hubara, M. Courbariaux, D. Soudry, R. El-Yaniv, and Y. Bengio. Quantized neural networks: Training neural networks with low precision weights and activations. JMLR, 18(1):6869-6898, 2017.
+[26] A. Jaegle, F. Gimeno, A. Brock, O. Vinyals, A. Zisserman, and J. Carreira. Perceiver: General perception with iterative attention. In ICML, pages 4651-4664, 2021.
+[27] S. Jung, C. Son, S. Lee, J. Son, J.-J. Han, Y. Kwak, S. J. Hwang, and C. Choi. Learning to quantize deep networks by optimizing quantization intervals with task loss. In CVPR, pages 4350-4359, 2019.
+[28] A. Katharopoulos, A. Vyas, N. Pappas, and F. Fleuret. Transformers are rnns: Fast autoregressive transformers with linear attention. In ICML, pages 5156-5165, 2020.
+[29] N. Kitaev, L. Kaiser, and A. Levskaya. Reformer: The efficient transformer. In ICLR, pages 1-12, 2020.
+[30] A. Krizhevsky, I. Sutskever, and G. E. Hinton. Imagenet classification with deep convolutional neural networks. In NeurIPS, volume 25, pages 1106-1114, 2012.
+[31] B. Kulis and K. Grauman. Kernelized locality-sensitive hashing. TPAMI, 34(6):1092-1104, 2011.
+[32] X. Lian, Z. Liu, Z. Song, J. Dai, W. Zhou, and X. Ji. High-performance fpga-based cnn accelerator with block-floating-point arithmetic. TVLSI, 27(8):1874-1885, 2019.
+[33] G. Lin, C. Shen, Q. Shi, A. Van den Hengel, and D. Suter. Fast supervised hashing with decision trees for high-dimensional data. In CVPR, pages 1963-1970, 2014.
+[34] X. Lin, C. Zhao, and W. Pan. Towards accurate binary convolutional neural network. In NeurIPS, pages 344-352, 2017.
+[35] W. Liu, C. Mu, S. Kumar, and S.-F. Chang. Discrete graph hashing. In NeurIPS, volume 27, pages 3419-3427, 2014.
+[36] W. Liu, J. Wang, R. Ji, Y.-G. Jiang, and S.-F. Chang. Supervised hashing with kernels. In CVPR, pages 2074-2081, 2012.
+[37] W. Liu, J. Wang, S. Kumar, and S.-F. Chang. Hashing with graphs. In ICML, pages 1-8, 2011.
+[38] Z. Liu, Y. Lin, Y. Cao, H. Hu, Y. Wei, Z. Zhang, S. Lin, and B. Guo. Swin transformer: Hierarchical vision transformer using shifted windows. In ICCV, pages 10012-10022, 2021.
+[39] Z. Liu, B. Wu, W. Luo, X. Yang, W. Liu, and K.-T. Cheng. Bi-real net: Enhancing the performance of 1-bit cnns with improved representational capability and advanced training algorithm. In ECCV, pages 722-737, 2018.
+[40] I. Loshchilov and F. Hutter. Decoupled weight decay regularization. In $ICLR$ , pages 1-18, 2019.
+[41] J. Lu, J. Yao, J. Zhang, X. Zhu, H. Xu, W. Gao, C. Xu, T. Xiang, and L. Zhang. Soft: Softmax-free transformer with linear complexity. In NeurIPS, volume 34, pages 21297-21309, 2021.
+[42] B. Martinez, J. Yang, A. Bulat, and G. Tzimiropoulos. Training binary neural networks with real-to-binary convolutions. In ICLR, pages 1-11, 2020.
+[43] A. Mishra and D. Marr. Apprentice: Using knowledge distillation techniques to improve low-precision network accuracy. In ICLR, pages 1–17, 2018.
+[44] M. Norouzi and D. J. Fleet. Minimal loss hashing for compact binary codes. In ICML, pages 353-360, 2011.
+[45] H. Peng, N. Pappas, D. Yogatama, R. Schwartz, N. Smith, and L. Kong. Random feature attention. In ICLR, pages 1-19, 2021.
+[46] H. Qin, Y. Ding, M. Zhang, Q. YAN, A. Liu, Q. Dang, Z. Liu, and X. Liu. BiBERT: Accurate fully binarized BERT. In ICLR, pages 1-24, 2022.
+[47] Z. Qin, W. Sun, H. Deng, D. Li, Y. Wei, B. Lv, J. Yan, L. Kong, and Y. Zhong. cosformer: Rethinking softmax in attention. In ICLR, pages 1-15, 2022.
+
+[48] A. Rahimi and B. Recht. Random features for large-scale kernel machines. In NeurIPS, volume 20, pages 1177-1184, 2007.
+[49] M. Rastegari, V. Ordonez, J. Redmon, and A. Farhadi. Xnor-net: Imagenet classification using binary convolutional neural networks. In ECCV, pages 525-542, 2016.
+[50] H. Ren, H. Dai, Z. Dai, M. Yang, J. Leskovec, D. Schuurmans, and B. Dai. Combiner: Full attention transformer with sparse computation cost. In NeurIPS, volume 34, pages 22470-22482, 2021.
+[51] H. Sharma, J. Park, N. Suda, L. Lai, B. Chau, V. Chandra, and H. Esmaeilzadeh. Bit fusion: Bit-level dynamically composable architecture for accelerating deep neural network. In ISCA, pages 764-775, 2018.
+[52] S. Shen, Z. Dong, J. Ye, L. Ma, Z. Yao, A. Gholami, M. W. Mahoney, and K. Keutzer. Q-bert: Hessian based ultra low precision quantization of bert. In AAAI, volume 34, pages 8815–8821, 2020.
+[53] H. Shu, J. Wang, H. Chen, L. Li, Y. Yang, and Y. Wang. Adder attention for vision transformer. In NeurIPS, volume 34, pages 19899-19909, 2021.
+[54] Z. Sun, Y. Yang, and S. Yoo. Sparse attention with learning to hash. In ICLR, pages 1-20, 2022.
+[55] Y. Tay, M. Dehghani, S. Abnar, Y. Shen, D. Bahri, P. Pham, J. Rao, L. Yang, S. Ruder, and D. Metzler. Long range arena: A benchmark for efficient transformers. In ICLR, pages 1-19, 2021.
+[56] H. Touvron, M. Cord, M. Douze, F. Massa, A. Sablayrolles, and H. Jégou. Training data-efficient image transformers & distillation through attention. In ICML, pages 10347-10357, 2021.
+[57] A. Vaswani, N. Shazeer, N. Parmar, J. Uszkoreit, L. Jones, A. N. Gomez, L. Kaiser, and I. Polosukhin. Attention is all you need. In NeurIPS, volume 30, pages 5998-6008, 2017.
+[58] A. Vyas, A. Katharopoulos, and F. Fleuret. Fast transformers with clustered attention. In NeurIPS, volume 33, pages 21665-21674, 2020.
+[59] J. Wang, S. Kumar, and S.-F. Chang. Semi-supervised hashing for large-scale search. TPAMI, 34(12):2393-2406, 2012.
+[60] S. Wang, B. Li, M. Khabsa, H. Fang, and H. Ma. Linformer: Self-attention with linear complexity. arXiv preprint arXiv:2006.04768, 2020.
+[61] W. Wang, E. Xie, X. Li, D.-P. Fan, K. Song, D. Liang, T. Lu, P. Luo, and L. Shao. Pyramid vision transformer: A versatile backbone for dense prediction without convolutions. In ICCV, pages 568-578, 2021.
+[62] W. Wang, E. Xie, X. Li, D.-P. Fan, K. Song, D. Liang, T. Lu, P. Luo, and L. Shao. Pvtv2: Improved baselines with pyramid vision transformer. Computational Visual Media, 8(3):415-424, 2022.
+[63] Y. Weiss, A. Torralba, and R. Fergus. Spectral hashing. In NeurIPS, volume 21, pages 1-8, 2008.
+[64] Y. Xiong, Z. Zeng, R. Chakraborty, M. Tan, G. Fung, Y. Li, and V. Singh. Nyströmformer: A nystöm-based algorithm for approximating self-attention. In AAAI, volume 35, page 14138, 2021.
+[65] C. Yan, B. Gong, Y. Wei, and Y. Gao. Deep multi-view enhancement hashing for image retrieval. TPAMI, 43(4):1445-1451, 2020.
+[66] A. H. Zadeh, I. Edo, O. M. Awad, and A. Moshovos. Gobo: Quantizing attention-based nlp models for low latency and energy efficient inference. In MICRO, pages 811-824, 2020.
+[67] O. Zafrir, G. Boudoukh, P. Izsak, and M. Wasserblat. Q8bert: Quantized 8bit bert. In EMC2-NIPS, pages 36-39, 2019.
+[68] S. Zhou, Y. Wu, Z. Ni, X. Zhou, H. Wen, and Y. Zou. Dorefa-net: Training low bitwidth convolutional neural networks with low bitwidth gradients. arXiv preprint arXiv:1606.06160, 2016.
+[69] C. Zhu, R. H. Byrd, P. Lu, and J. Nocedal. Algorithm 778: L-bfgs-b: Fortran subroutines for large-scale bound-constrained optimization. ACM TOMS, 23(4):550-560, 1997.
+[70] C. Zhu, W. Ping, C. Xiao, M. Shoeybi, T. Goldstein, A. Anandkumar, and B. Catanzaro. Long-short transformer: Efficient transformers for language and vision. In NeurIPS, volume 34, pages 17723-17736, 2021.
+[71] B. Zhuang, G. Lin, C. Shen, and I. Reid. Fast training of triplet-based deep binary embedding networks. In CVPR, pages 5955-5964, 2016.
+[72] B. Zhuang, C. Shen, M. Tan, L. Liu, and I. Reid. Structured binary neural network for accurate image classification and semantic segmentation. In CVPR, pages 413-422, 2019.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes] See the abstract and introduction.
+(b) Did you describe the limitations of your work? [Yes] See the conclusion in Section 6.
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] See the conclusion in Section 6.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] We have included the code and instructions needed in the supplemental material.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See the implementation details in Section 5.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] Error bars are not reported because it would be too computationally expensive. We use the same random seed as in recent works for fair comparison.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See the implementation details in Section 5.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] See Section 5.
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] Code is included in the supplementary material.
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [No] We use public datasets.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/ecoformerenergysavingattentionwithlinearcomplexity/images.zip b/ecoformerenergysavingattentionwithlinearcomplexity/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..cdd5fa0d3ac97b42fc8ee5d8d199b955a6d5af96
--- /dev/null
+++ b/ecoformerenergysavingattentionwithlinearcomplexity/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b4a9402aa841a263add0c1a98d7d6b0f67dc4f711f6b1f35e57cf28907191b82
+size 439489
diff --git a/ecoformerenergysavingattentionwithlinearcomplexity/layout.json b/ecoformerenergysavingattentionwithlinearcomplexity/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..af7ee4f461768a890470f3082a4baf1473f5bb41
--- /dev/null
+++ b/ecoformerenergysavingattentionwithlinearcomplexity/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:33abbac19078a4058128ecc2033ae32082434f2281783a196eb7d60690772314
+size 485409
diff --git a/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/ea145f53-feae-48cd-b33a-4613de55dc57_content_list.json b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/ea145f53-feae-48cd-b33a-4613de55dc57_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..b72a39435d1f073e3badd1872c5aa14a7843411c
--- /dev/null
+++ b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/ea145f53-feae-48cd-b33a-4613de55dc57_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fdb9ea776674fb8d1f35bfe44161bc1b029bf4b06665d7b29160fd8d7ede56b3
+size 94381
diff --git a/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/ea145f53-feae-48cd-b33a-4613de55dc57_model.json b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/ea145f53-feae-48cd-b33a-4613de55dc57_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..b653694565d6686da97d5179eacd6a530739a697
--- /dev/null
+++ b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/ea145f53-feae-48cd-b33a-4613de55dc57_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d4a2fb801f3c6e8378ed9195843ba63a2a2b2e0cd6d08a832e7fb04b3098b0af
+size 118984
diff --git a/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/ea145f53-feae-48cd-b33a-4613de55dc57_origin.pdf b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/ea145f53-feae-48cd-b33a-4613de55dc57_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..994ce67c6a2216dc4ed2d3761d9dd7dd8bd518bb
--- /dev/null
+++ b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/ea145f53-feae-48cd-b33a-4613de55dc57_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:dbf9f7a728de569b6df9905ff47a114afcb45f9860583ffcf950f19473251bee
+size 624129
diff --git a/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/full.md b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..af665b4f6053b4045360f9f5875155d172682bf8
--- /dev/null
+++ b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/full.md
@@ -0,0 +1,467 @@
+# EF-BV: A Unified Theory of Error Feedback and Variance Reduction Mechanisms for Biased and Unbiased Compression in Distributed Optimization
+
+Laurent Condat*
+
+KAUST
+
+Kai Yi
+
+KAUST
+
+# Peter Rictárik
+
+King Abdullah University of Science and Technology (KAUST)
+
+Thuwal 23955-6900, Kingdom of Saudi Arabia
+
+# Abstract
+
+In distributed or federated optimization and learning, communication between the different computing units is often the bottleneck and gradient compression is widely used to reduce the number of bits sent within each communication round of iterative methods. There are two classes of compression operators and separate algorithms making use of them. In the case of unbiased random compressors with bounded variance (e.g., rand-k), the DIANA algorithm of Mishchenko et al. (2019), which implements a variance reduction technique for handling the variance introduced by compression, is the current state of the art. In the case of biased and contractive compressors (e.g., top-k), the EF21 algorithm of Richtárik et al. (2021), which instead implements an error-feedback mechanism, is the current state of the art. These two classes of compression schemes and algorithms are distinct, with different analyses and proof techniques. In this paper, we unify them into a single framework and propose a new algorithm, recovering DIANA and EF21 as particular cases. Our general approach works with a new, larger class of compressors, which has two parameters, the bias and the variance, and includes unbiased and biased compressors as particular cases. This allows us to inherit the best of the two worlds: like EF21 and unlike DIANA, biased compressors, like top-k, whose good performance in practice is recognized, can be used. And like DIANA and unlike EF21, independent randomness at the compressors allows to mitigate the effects of compression, with the convergence rate improving when the number of parallel workers is large. This is the first time that an algorithm with all these features is proposed. We prove its linear convergence under certain conditions. Our approach takes a step towards better understanding of two so-far distinct worlds of communication-efficient distributed learning.
+
+# 1 Introduction
+
+In the big data era, the explosion in size and complexity of the data arises in parallel to a shift towards distributed computations (Verbraeken et al., 2021), as modern hardware increasingly relies on the power of uniting many parallel units into one system. For distributed optimization and learning tasks, specific issues arise, such as decentralized data storage. In the modern paradigm of federated learning (Konečný et al., 2016; McMahan et al., 2017; Kairouz et al., 2021; Li et al., 2020a), a potentially huge number of devices, with their owners' data stored on each of them, are involved in the
+
+collaborative process of training a global machine learning model. The goal is to exploit the wealth of useful information lying in the heterogeneous data stored across the network of such devices. But users are increasingly sensitive to privacy concerns and prefer their data to never leave their devices. Thus, the devices have to communicate the right amount of information back and forth with a distant server, for this distributed learning process to work. Communication, which can be costly and slow, is the main bottleneck in this framework. So, it is of primary importance to devise novel algorithmic strategies, which are efficient in terms of computation and communication complexities. A natural and widely used idea is to make use of (lossy) compression, to reduce the size of the communicated messages (Alistarh et al., 2017; Wen et al., 2017; Wangni et al., 2018; Khaled & Richtárik, 2019; Albasyoni et al., 2020; Basu et al., 2020; Dutta et al., 2020; Sattler et al., 2020; Xu et al., 2021).
+
+In this paper, we propose a stochastic gradient descent (SGD)-type method for distributed optimization, which uses possibly biased and randomized compression operators. Our algorithm is variance-reduced (Hanzely & Richtárik, 2019; Gorbunov et al., 2020a; Gower et al., 2020); that is, it converges to the exact solution, with fixed stepsizes, without any restrictive assumption on the functions to minimize.
+
+Problem. We consider the convex optimization problem
+
+$$
+\underset {x \in \mathbb {R} ^ {d}} {\text {m i n i m i z e}} \underbrace {\frac {1}{n} \sum_ {i = 1} ^ {n} f _ {i} (x)} _ {f (x)} + R (x), \tag {1}
+$$
+
+where $d \geq 1$ is the model dimension; $R: \mathbb{R}^d \to \mathbb{R} \cup \{+\infty\}$ is a proper, closed, convex function (Bauschke & Combettes, 2017), whose proximity operator $\mathrm{prox}_{\gamma R}: x \mapsto \arg \min_{y \in \mathbb{R}^d} (\gamma R(y) + \frac{1}{2} \|x - y\|^2)$ is easy to compute, for any $\gamma > 0$ (Parikh & Boyd, 2014; Condat et al., 2022a,b); $n \geq 1$ is the number of functions; each function $f_i: \mathbb{R}^d \to \mathbb{R}$ is convex and $L_i$ -smooth, for some $L_i > 0$ ; that is, $f_i$ is differentiable on $\mathbb{R}^d$ and its gradient $\nabla f_i$ is $L_i$ -Lipschitz continuous: for every $x \in \mathbb{R}^d$ and $x' \in \mathbb{R}^d$ , $\| \nabla f_i(x) - \nabla f_i(x')\| \leq L_i\| x - x'\|$ .
+
+We set $L_{\max} \coloneqq \max_i L_i$ and $\tilde{L} \coloneqq \sqrt{\frac{1}{n} \sum_{i=1}^n L_i^2}$ . The average function $f \coloneqq \frac{1}{n} \sum_{i=1}^n f_i$ is $L$ -smooth, for some $L \leq \tilde{L} \leq L_{\max}$ . A minimizer of $f + R$ is supposed to exist. For any integer $m \geq 1$ , we define the set $\mathcal{I}_m \coloneqq \{1, \ldots, m\}$ .
+
+Algorithms and Prior Work. Distributed proximal SGD solves the problem (1) by iterating $x^{t + 1} \coloneqq \mathrm{prox}_{\gamma R}(x^t - \frac{\gamma}{n}\sum_{i = 1}^n g_i^t)$ , where $\gamma$ is a stepsize and the vectors $g_i^t$ are possibly stochastic estimates of the gradients $\nabla f_i(x^t)$ , which are cheap to compute or communicate. Compression is typically performed by the application of a possibly randomized operator $\mathcal{C} : \mathbb{R}^d \to \mathbb{R}^d$ ; that is, for any $x, \mathcal{C}(x)$ denotes a realization of a random variable, whose probability distribution depends on $x$ . Compressors have the property that it is much easier/faster to transfer $\mathcal{C}(x)$ than the original message $x$ . This can be achieved in several ways, for instance by sparsifying the input vector (Alistarh et al., 2018), or by quantizing its entries (Alistarh et al., 2017; Horváth et al., 2019; Gandikota et al., 2019; Mayekar & Tyagi, 2021; Saha et al., 2021), or via a combination of these and other approaches (Horváth et al., 2019; Albasyoni et al., 2020; Beznosikov et al., 2020). There are two classes of compression operators often studied in the literature: 1) unbiased compression operators, satisfying a variance bound proportional to the squared norm of the input vector, and 2) biased compression operators, whose square distortion is contractive with respect to the squared norm of the input vector; we present these two classes in Sections 2.1 and 2.2, respectively.
+
+Prior work: DIANA with unbiased compressors. An important contribution to the field in the recent years is the variance-reduced SGD-type method called DIANA (Mishchenko et al., 2019), which uses unbiased compressors; it is shown in Fig. 1. DIANA was analyzed and extended in several ways, including bidirectional compression and acceleration, see, e.g., the work of Horváth et al. (2022); Mishchenko et al. (2020); Condat & Richtárik (2022); Philippenko & Dieuleveut (2020); Li et al. (2020b); Gorbunov et al. (2020b), and Gorbunov et al. (2020a); Khaled et al. (2020) for general theories about SGD-type methods, including variants using unbiased compression of (stochastic) gradients.
+
+Prior work: Error feedback with biased contractive compressors. Our understanding of distributed optimization using biased compressors is more limited. The key complication comes from
+
+Table 1: Desirable properties of a distributed compressed gradient descent algorithm converging to an exact solution of (1) and whether they are satisfied by the state-of-the-art algorithms DIANA and EF21 and their currently-known analysis, and the proposed algorithm EF-BV.
+
+ | DIANA | EF21 | EF-BV |
| handles unbiased compressors in U(ω) for any ω ≥ 0 | ✓ | ✓1 | ✓ |
| handles biased contractive compressors in B(α) for any α ∈ (0,1] | X | ✓ | ✓ |
| handles compressors in C(η,ω) for any η ∈ [0,1), ω ≥ 0 | X | ✓1 | ✓ |
| recovers DIANA and EF21 as particular cases | X | X | ✓ |
| the convergence rate improves when n is large | ✓ | X | ✓ |
+
+$^1$ : with pre-scaling with $\lambda < 1$ , so that $\mathcal{C}' = \lambda \mathcal{C} \in \mathbb{B}(\alpha)$ is used instead of $\mathcal{C}$
+
+the fact that their naive use within methods like gradient descent can lead to divergence, as widely observed in practice, see also Example 1 of Beznosikov et al. (2020). Error feedback (EF), also called error compensation, techniques were proposed to fix this issue and obtain convergence, initially as heuristics (Seide et al., 2014). Theoretical advances have been made in the recent years in the analysis of EF, see the discussions and references in Richtárik et al. (2021) and Lin et al. (2022). But the question of whether it is possible to obtain a linearly convergent EF method in the general heterogeneous data setting, relying on biased compressors only, was still an open problem; until last year, 2021, when Richtárik et al. (2021) re-engineered the classical EF mechanism and came up with a new algorithm, called EF21. It was then extended in several ways, including by considering server-side compression, and the support of a regularizer $R$ in (1), by Fatkhullin et al. (2021). EF21 is shown in Fig. 1.
+
+Motivation and challenge. While EF21 resolved an important theoretical problem in the field of distributed optimization with contractive compression, there are still several open questions. In particular, DIANA with independent random compressors has a $\frac{1}{n}$ factor in its iteration complexity; that is, it converges faster when the number $n$ of workers is larger. EF21 does not have this property: its convergence rate does not depend on $n$ . Also, the convergence analysis and proof techniques for the two algorithms are different: the linear convergence analysis of DIANA relies on $\|x^t - x^\star\|^2$ and $\|h_i^t - \nabla f_i(x^\star)\|^2$ tending to zero, where $x^t$ is the estimate of the solution $x^\star$ at iteration $t$ and $h_i^t$ is the control variate maintained at node $i$ , whereas the analysis of EF21 relies on $(f + R)(x^t) - (f + R)(x^\star)$ and $\|h_i^t - \nabla f_i(x^t)\|^2$ tending to zero, and under different assumptions. This work aims at filling this gap. That is, we want to address the following open problem:
+
+Is it possible to design an algorithm, which combines the advantages of DIANA and EF21? That is, such that:
+
+a. It deals with unbiased compressors, biased contractive compressors, and possibly even more.
+b. It recovers DIANA and EF21 as particular cases.
+c. Its convergence rate improves with $n$ large.
+
+Contributions. We answer positively this question and propose a new algorithm, which we name EF-BV, for Error Feedback with Bias-Variance decomposition, which for the first time satisfies the three aforementioned properties. This is illustrated in Tab. 1. More precisely, our contributions are:
+
+1. We propose a new, larger class of compressors, which includes unbiased and biased contractive compressors as particular cases, and has two parameters, the bias $\eta$ and the variance $\omega$ . A third parameter $\omega_{\mathrm{av}}$ describes the resulting variance from the parallel compressors after aggregation, and is key to getting faster convergence with large $n$ , by allowing larger stepsizes than in EF21 in our framework.
+2. We propose a new algorithm, named EF-BV, which exploits the properties of the compressors in the new class using two scaling parameters $\lambda$ and $\nu$ . For particular values of $\lambda$ and $\nu$ , EF21 and DIANA are recovered as particular cases. But by setting the values of $\lambda$ and $\nu$ optimally with respect to $\eta$ , $\omega$ , $\omega_{\mathrm{av}}$ in EF-BV, faster convergence can be obtained.
+3. We prove linear convergence of EF-BV under a Kurdyka-Łojasiewicz condition of $f + R$ , which is weaker than strong convexity of $f + R$ . Even for EF21 and DIANA, this is new.
+
+4. We provide new insights on EF21 and DIANA; for instance, we prove linear convergence of DIANA with biased compressors.
+
+# 2 Compressors and their properties
+
+# 2.1 Unbiased compressors
+
+For every $\omega \geq 0$ , we introduce the set $\mathbb{U}(\omega)$ of unbiased compressors, which are randomized operators of the form $\mathcal{C}:\mathbb{R}^d\to \mathbb{R}^d$ , satisfying
+
+$$
+\mathbb {E} [ \mathcal {C} (x) ] = x \quad \text {a n d} \quad \mathbb {E} [ \| \mathcal {C} (x) - x \| ^ {2} ] \leq \omega \| x \| ^ {2}, \quad \forall x \in \mathbb {R} ^ {d}, \tag {2}
+$$
+
+where $\mathbb{E}[\cdot ]$ denotes the expectation. The smaller $\omega$ , the better, and $\omega = 0$ if and only if $\mathcal{C} = \mathrm{Id}$ , the identity operator, which does not compress. We can remark that if $\mathcal{C}\in \mathbb{U}(\omega)$ is deterministic, then $\mathcal{C} = \mathrm{Id}$ . So, unbiased compressors are random ones. A classical unbiased compressor is rand- $k$ , for some $k\in \mathcal{I}_d$ , which keeps $k$ elements chosen uniformly at random, multiplied by $\frac{d}{k}$ , and sets the other elements to 0. It is easy to see that rand- $k$ belongs to $\mathbb{U}(\omega)$ with $\omega = \frac{d}{k} -1$ (Beznosikov et al., 2020).
+
+# 2.2 Biased contractive compressors
+
+For every $\alpha \in (0,1]$ , we introduce the set $\mathbb{B}(\alpha)$ of biased contractive compressors, which are possibly randomized operators of the form $\mathcal{C}:\mathbb{R}^d\to \mathbb{R}^d$ , satisfying
+
+$$
+\mathbb {E} \left[ \| \mathcal {C} (x) - x \| ^ {2} \right] \leq (1 - \alpha) \| x \| ^ {2}, \quad \forall x \in \mathbb {R} ^ {d}. \tag {3}
+$$
+
+We use the term 'contractive' to reflect the fact that the squared norm in the left hand side of (3) is smaller, in expectation, than the one in the right hand side, since $1 - \alpha < 1$ . This is not the case in (2), where $\omega$ can be arbitrarily large. The larger $\alpha$ , the better, and $\alpha = 1$ if and only if $\mathcal{C} = \mathrm{Id}$ . Biased compressors need not be random: a classical biased and deterministic compressor is top- $k$ , for some $k \in \mathcal{I}_d$ , which keeps the $k$ elements with largest absolute values unchanged and sets the other elements to 0. It is easy to see that top- $k$ belongs to $\mathbb{B}(\alpha)$ with $\alpha = \frac{k}{d}$ (Beznosikov et al., 2020).
+
+# 2.3 New general class of compressors
+
+We refer to Beznosikov et al. (2020), Table 1 in Safaryan et al. (2021), Zhang et al. (2021), Szlendak et al. (2022), for examples of compressors in $\mathbb{U}(\omega)$ or $\mathbb{B}(\alpha)$ , and to Xu et al. (2020) for a system-oriented survey.
+
+In this work, we introduce a new, more general class of compressors, ruled by 2 parameters, to allow for a finer characterization of their properties. Indeed, with any compressor $\mathcal{C}$ , we can do a bias-variance decomposition of the compression error: for every $x\in \mathbb{R}^d$
+
+$$
+\mathbb {E} \left[ \| \mathcal {C} (x) - x \| ^ {2} \right] = \underbrace {\left\| \mathbb {E} [ \mathcal {C} (x) ] - x \right\| ^ {2}} _ {\text {b i a s}} + \underbrace {\mathbb {E} \left[ \left\| \mathcal {C} (x) - \mathbb {E} [ \mathcal {C} (x) ] \right\| ^ {2} \right]} _ {\text {v a r i a n c e}}. \tag {4}
+$$
+
+Therefore, to better characterize the properties of compressors, we propose to parameterize these two parts, instead of only their sum: for every $\eta \in [0,1)$ and $\omega \geq 0$ , we introduce the new class $\mathbb{C}(\eta ,\omega)$ of possibly random and biased operators, which are randomized operators of the form $\mathcal{C}:\mathbb{R}^d\to \mathbb{R}^d$ satisfying, for every $x\in \mathbb{R}^d$ , the two properties:
+
+(i) $\left\| \mathbb{E}[\mathcal{C}(x)] - x\right\| \leq \eta \| x\|$
+(ii) $\mathbb{E}\Big[\big\| \mathcal{C}(x) - \mathbb{E}[\mathcal{C}(x)]\big\| ^2\Big]\leq \omega \| x\| ^2.$
+
+Thus, $\eta$ and $\omega$ control the relative bias and variance of the compressor, respectively. Note that $\omega$ can be arbitrarily large, but the compressors will be scaled in order to control the compression error, as we discuss in Sect. (2.5). On the other hand, we must have $\eta < 1$ , since otherwise, no scaling can keep the compressor's discrepancy under control.
+
+We have the following properties:
+
+1. $\mathbb{C}(\eta, 0)$ is the class of deterministic compressors in $\mathbb{B}(\alpha)$ , with $1 - \alpha = \eta^2$ .
+2. $\mathbb{C}(0,\omega) = \mathbb{U}(\omega)$ , for every $\omega \geq 0$ . In words, if its bias $\eta$ is zero, the compressor is unbiased with relative variance $\omega$ .
+3. Because of the bias-variance decomposition (4), if $\mathcal{C} \in \mathbb{C}(\eta, \omega)$ with $\eta^2 + \omega < 1$ , then $\mathcal{C} \in \mathbb{B}(\alpha)$ with
+
+$$
+1 - \alpha = \eta^ {2} + \omega . \tag {5}
+$$
+
+4. Conversely, if $\mathcal{C} \in \mathbb{B}(\alpha)$ , one easily sees from (4) that there exist $\eta \leq \sqrt{1 - \alpha}$ and $\omega \leq 1 - \alpha$ such that $\mathcal{C} \in \mathbb{C}(\eta, \omega)$ .
+
+Thus, the new class $\mathbb{C}(\eta ,\omega)$ generalizes the two previously known classes $\mathbb{U}(\omega)$ and $\mathbb{B}(\alpha)$ . Actually, for compressors in $\mathbb{U}(\omega)$ and $\mathbb{B}(\alpha)$ , we can just use DIANA and EF21, and our proposed algorithm EF-BV will stand out when the compressors are neither in $\mathbb{U}(\omega)$ nor in $\mathbb{B}(\alpha)$ ; that is why the strictly larger class $\mathbb{C}(\eta ,\omega)$ is needed for our purpose.
+
+We present new compressors in the class $\mathbb{C}(\eta, \omega)$ in Appendix A.
+
+# 2.4 Average variance of several compressors
+
+Given $n$ compressors $\mathcal{C}_i$ , $i \in \mathcal{I}_n$ , we are interested in how they behave in average. Indeed distributed algorithms consist, at every iteration, in compressing vectors in parallel, and then averaging them. Thus, we introduce the average relative variance $\omega_{\mathrm{av}} \geq 0$ of the compressors, such that, for every $x_i \in \mathbb{R}^d$ , $i \in \mathcal{I}_n$ ,
+
+$$
+\mathbb {E} \left[ \left\| \frac {1}{n} \sum_ {i = 1} ^ {n} \left(\mathcal {C} _ {i} \left(x _ {i}\right) - \mathbb {E} \left[ \mathcal {C} _ {i} \left(x _ {i}\right) \right]\right) \right\| ^ {2} \right] \leq \frac {\omega_ {\mathrm {a v}}}{n} \sum_ {i = 1} ^ {n} \| x _ {i} \| ^ {2}. \tag {6}
+$$
+
+When every $\mathcal{C}_i$ is in $\mathbb{C}(\eta, \omega)$ , for some $\eta \in [0,1)$ and $\omega \geq 0$ , then $\omega_{\mathrm{av}} \leq \omega$ ; but $\omega_{\mathrm{av}}$ can be much smaller than $\omega$ , and we will exploit this property in EF-BV. We can also remark that $\frac{1}{n} \sum_{i=1}^{n} \mathcal{C}^i \in \mathbb{C}(\eta, \omega_{\mathrm{av}})$ .
+
+An important property is the following: if the $\mathcal{C}_i$ are mutually independent, since the variance of a sum of random variables is the sum of their variances, then
+
+$$
+\omega_ {\mathrm {a v}} = \frac {\omega}{n}.
+$$
+
+There are other cases where the compressors are dependent but $\omega_{\mathrm{av}}$ is much smaller than $\omega$ . Notably, the following setting can be used to model partial participation of $m$ among $n$ workers at every iteration of a distributed algorithm, for some $m \in \mathcal{I}_n$ , with the $\mathcal{C}_i$ defined jointly as follows: for every $i \in \mathcal{I}_n$ and $x_i \in \mathbb{R}^d$ ,
+
+$$
+\mathcal {C} _ {i} (x _ {i}) = \left\{ \begin{array}{l l} \frac {n}{m} x _ {i} & \text {i f} i \in \Omega \\ 0 & \text {o t h e r w i s e} \end{array} \right.,
+$$
+
+where $\Omega$ is a subset of $\mathcal{I}_n$ of size $m$ chosen uniformly at random. This is sometimes called $m$ -nice sampling (Richtárik & Takáč, 2016; Gower et al., 2021). Then every $\mathcal{C}_i$ belongs to $\mathbb{U}(\omega)$ , with $\omega = \frac{n - m}{m}$ , and, as shown for instance in Qian et al. (2019) and Proposition 1 in Condat & Richtárik (2022), (6) is satisfied with
+
+$$
+\omega_ {\mathrm {a v}} = \frac {n - m}{m (n - 1)} = \frac {\omega}{n - 1} \quad (= 0 \text {i f} n = m = 1).
+$$
+
+# 2.5 Scaling compressors
+
+A compressor $\mathcal{C} \in \mathbb{C}(\eta, \omega)$ does not necessarily belong to $\mathbb{B}(\alpha)$ for any $\alpha \in (0,1]$ , since $\omega$ can be arbitrarily large. Fortunately, the compression error can be kept under control by scaling the compressor; that is, using $\lambda \mathcal{C}$ instead of $\mathcal{C}$ , for some scaling parameter $\lambda \leq 1$ . We have:
+
+Proposition 1. Let $\mathcal{C} \in \mathbb{C}(\eta, \omega)$ , for some $\eta \in [0,1)$ and $\omega \geq 0$ , and $\lambda \in (0,1]$ . Then $\lambda \mathcal{C} \in \mathbb{C}(\eta', \omega')$ with $\omega' = \lambda^2\omega$ and $\eta' = \lambda\eta + 1 - \lambda \in (0,1]$ .
+
+Proof. Let $x \in \mathbb{R}^d$ . Then $\mathbb{E}\left[\left\|\lambda \mathcal{C}(x) - \mathbb{E}[\lambda \mathcal{C}(x)]\right\|^2\right] = \lambda^2 \mathbb{E}\left[\left\|\mathcal{C}(x) - \mathbb{E}[\mathcal{C}(x)]\right\|^2\right] \leq \lambda^2 \omega \|x\|^2$ , and $\left\|\mathbb{E}[\lambda \mathcal{C}(x)] - x\right\| \leq \lambda \left\|\mathbb{E}[\mathcal{C}(x)] - x\right\| + (1 - \lambda)\|x\| \leq (\lambda \eta + 1 - \lambda)\|x\|$ .
+
+So, scaling deteriorates the bias, with $\eta' \geq \eta$ , but linearly, whereas it reduces the variance $\omega$ quadratically. This is key, since the total error factor $(\eta')^2 + \omega'$ can be made smaller than 1 by choosing $\lambda$ sufficiently small:
+
+Proposition 2. Let $\mathcal{C} \in \mathbb{C}(\eta, \omega)$ , for some $\eta \in [0,1)$ and $\omega \geq 0$ . There exists $\lambda \in (0,1]$ such that $\lambda \mathcal{C} \in \mathbb{B}(\alpha)$ , for some $\alpha = 1 - (1 - \lambda + \lambda \eta)^2 - \lambda^2\omega \in (0,1]$ , and the best such $\lambda$ , maximizing $\alpha$ , is
+
+$$
+\lambda^ {\star} = \min \left(\frac {1 - \eta}{(1 - \eta) ^ {2} + \omega}, 1\right).
+$$
+
+Proof. We define the polynomial $P: \lambda \mapsto (1 - \lambda + \lambda \eta)^2 + \lambda^2\omega$ . After Proposition 1 and the discussion in Sect. 2.3, we have to find $\lambda \in (0,1]$ such that $P(\lambda) < 1$ . Then $\lambda C \in \mathbb{B}(\alpha)$ , with $1 - \alpha = P(\lambda)$ . Since $P$ is a strictly convex quadratic function on $[0,1]$ with value 1 and negative derivative $\eta - 1$ at $\lambda = 0$ , its minimum value on $[0,1]$ is smaller than 1 and is attained at $\lambda^\star$ , which either satisfies the first-order condition $0 = P'(\lambda) = -2(1 - \eta) + 2\lambda((1 - \eta)^2 + \omega)$ , or, if this value is larger than 1, is equal to 1.
+
+In particular, if $\eta = 0$ , Proposition 2 recovers Lemma 8 of Richtárik et al. (2021), according to which, for $\mathcal{C} \in \mathbb{U}(\omega)$ , $\lambda^{\star}\mathcal{C} \in \mathbb{B}\left(\frac{1}{\omega + 1}\right)$ , with $\lambda^{\star} = \frac{1}{\omega + 1}$ . For instance, the scaled rand- $k$ compressor, which keeps $k$ elements chosen uniformly at random unchanged and sets the other elements to 0, corresponds to scaling the unbiased rand- $k$ compressor, seen in Sect. 2.1, by $\lambda = \frac{k}{d}$ .
+
+We can remark that scaling is used to mitigate the randomness of a compressor, but cannot be used to reduce its bias: if $\omega = 0$ , $\lambda^{\star} = 1$ .
+
+Our new algorithm EF-BV will have two scaling parameters: $\lambda$ , to mitigate the compression error in the control variates used for variance reduction, just like above, and $\nu$ , to mitigate the error in the stochastic gradient estimate, in a similar way but with $\omega$ replaced by $\omega_{\mathrm{av}}$ , since we have seen in Sect. 2.4 that $\omega_{\mathrm{av}}$ characterizes the randomness after averaging the outputs of several compressors.
+
+# 3 Proposed algorithm EF-BV
+
+We propose the algorithm EF-BV, shown in Fig. 1. It makes use of compressors $\mathcal{C}_i^t\in \mathbb{C}(\eta ,\omega)$ , for some $\eta \in [0,1)$ and $\omega \geq 0$ , and we introduce $\omega_{\mathrm{av}}\leq \omega$ such that (6) is satisfied. That is, for any $x\in \mathbb{R}^d$ , the $\mathcal{C}_i^t (x)$ , for $i\in \mathcal{I}_n$ and $t\geq 0$ , are distinct random variables; their laws might be the same or not, but they all lie in the class $\mathbb{C}(\eta ,\omega)$ . Also, $\mathcal{C}_i^t (x)$ and $\mathcal{C}_{i'}^{t'}(x')$ , for $t\neq t'$ , are independent.
+
+The compressors have the property that if their input is the zero vector, the compression error is zero, so we want to compress vectors that are close to zero, or at least converge to zero, to make the method variance-reduced. That is why each worker maintains a control variate $h_i^t$ , converging, like $\nabla f_i(x^t)$ to $\nabla f_i(x^\star)$ , for some solution $x^\star$ . This way, the difference vectors $\nabla f_i(x^t) - h_i^t$ converge to zero, and these are the vectors that are going to be compressed. Thus, EF-BV takes the form of Distributed proximal SGD, with
+
+$$
+g _ {i} ^ {t} = h _ {i} ^ {t} + \nu \mathcal {C} _ {i} ^ {t} (\nabla f _ {i} (x ^ {t}) - h _ {i} ^ {t}),
+$$
+
+where the scaling parameter $\nu$ will be used to make the compression error, averaged over $i$ , small; that is, to make $g^{t + 1} = \frac{1}{n}\sum_{i = 1}^{n}g_{i}^{t}$ close to $\nabla f(x^t)$ . In parallel, the control variates are updated similarly as
+
+$$
+h _ {i} ^ {t + 1} = h _ {i} ^ {t} + \lambda \mathcal {C} _ {i} ^ {t} (\nabla f _ {i} (x ^ {t}) - h _ {i} ^ {t}),
+$$
+
+where the scaling parameter $\lambda$ is used to make the compression error small, individually for each $i$ ; that is, to make $h_i^{t + 1}$ close to $\nabla f_{i}(x^{t})$ .
+
+# 3.1 EF21 as a particular case of EF-BV
+
+There are two ways to recover EF21 as a particular case of EF-BV:
+
+1. If the compressors $\mathcal{C}_i^t$ are in $\mathbb{B}(\alpha)$ , for some $\alpha \in (0,1]$ , there is no need for scaling the compressors, and we can use EF-BV with $\lambda = \nu = 1$ . Then the variable $h^t$ in EF-BV becomes redundant with the gradient estimate $g^t$ and we can only keep the latter, which yields EF21, as shown in Fig. 1.
+
+Algorithm 1 EF-BV proposed method
+Input: $x^0, h_1^0, \ldots, h_n^0 \in \mathbb{R}^d$ , $h^0 = \frac{1}{n} \sum_{i=1}^{n} h_i^0, \gamma > 0$ , $\lambda \in (0,1]$ , $\nu \in (0,1]$
+for $t = 0,1, \ldots$ do
+ for $i = 1,2,\ldots,n$ in parallel do
+ $d_i^t := C_i^t (\nabla f_i(x^t) - h_i^t)$ $h_i^{t+1} := h_i^t + \lambda d_i^t$
+ send $d_i^t$ to master
+end for
+at master:
+ $d^t := \frac{1}{n} \sum_{i=1}^{n} d_i^t$ $h^{t+1} := h^t + \lambda d^t$ $g^{t+1} := h^t + \nu d^t$ $x^{t+1} := \mathrm{prox}_{\gamma R}(x^t - \gamma g^{t+1})$
+ broadcast $x^{t+1}$ to all workers
+end for
+
+Algorithm 2 EF21 (Richtárik et al., 2021)
+Input: $x^0, h_1^0, \ldots, h_n^0 \in \mathbb{R}^d$ , $h^0 = \frac{1}{n}\sum_{i=1}^{n}h_i^0$ , $\gamma > 0$ ,
+for $t = 0,1,\ldots$ do
+for $i = 1,2,\ldots,n$ in parallel do
+ $d_i^t \coloneqq \mathcal{C}_i^t\left(\nabla f_i(x^t) - h_i^t\right)$ $h_i^{t+1} \coloneqq h_i^t + d_i^t$
+send $d_i^t$ to master
+end for
+at master:
+ $d^t \coloneqq \frac{1}{n}\sum_{i=1}^{n}d_i^t$ $h^{t+1} \coloneqq h^t + d^t$ $g^{t+1} \coloneqq h^t + d^t$ $x^{t+1} \coloneqq \mathrm{prox}_{\gamma R}(x^t - \gamma g^{t+1})$
+broadcast $x^{t+1}$ to all workers
+end for
+
+Algorithm 3 DIANA (Mishchenko et al., 2019)
+Input: $x^0, h_1^0, \ldots, h_n^0 \in \mathbb{R}^d$ , $h^0 = \frac{1}{n}\sum_{i=1}^{n}h_i^0, \gamma > 0$ , $\lambda \in (0,1]$
+for $t = 0,1,\ldots$ do
+for $i = 1,2,\ldots,n$ in parallel do
+ $d_i^t := \mathcal{C}_i^t(\nabla f_i(x^t) - h_i^t)$ $h_i^{t+1} := h_i^t + \lambda d_i^t$
+send $d_i^t$ to master
+end for
+at master:
+ $d^t := \frac{1}{n}\sum_{i=1}^{n}d_i^t$ $h^{t+1} := h^t + \lambda d^t$ $g^{t+1} := h^t + d^t$ $x^{t+1} := \mathrm{prox}_{\gamma R}(x^t - \gamma g^{t+1})$
+broadcast $x^{t+1}$ to all workers
+end for
+
+Figure 1: In the three algorithms, $g^{t+1}$ is an estimate of $\nabla f(x^t)$ , the $h_i^t$ are control variates converging to $\nabla f_i(x^\star)$ , and their average $h^t = \frac{1}{n} \sum_{i=1}^{n} h_i^t$ is maintained and updated by the master. EF21 is a particular case of EF-BV, when $\nu = \lambda = 1$ and the compressors are in $\mathbb{B}(\alpha)$ ; then $g^{t+1}$ is simply equal to $h^{t+1}$ for every $t \geq 0$ . DIANA is a particular case of EF-BV, when $\nu = 1$ and the compressors are in $\mathbb{U}(\omega)$ ; then $g^t$ is an unbiased estimate of $\nabla f(x^t)$ .
+
+2. If the scaled compressors $\lambda \mathcal{C}_i^t$ are in $\mathbb{B}(\alpha)$ , for some $\alpha \in (0,1]$ and $\lambda \in (0,1)$ (see Proposition 2), one can simply use these scaled compressors in EF21. This is equivalent to using EF-BV with the original compressors $\mathcal{C}_i^t$ , the scaling with $\lambda$ taking place inside the algorithm. But we must have $\nu = \lambda$ for this equivalence to hold.
+
+Therefore, we consider thereafter that EF21 corresponds to the particular case of EF-BV with $\nu = \lambda \in (0,1]$ and $\lambda C_i^t\in \mathbb{B}(\alpha)$ , for some $\alpha \in (0,1]$ , and is not only the original algorithm shown in Fig. 1, which has no scaling parameter (but scaling might have been applied beforehand to make the compressors in $\mathbb{B}(\alpha)$ ).
+
+# 3.2 DIANA as a particular case of EF-BV
+
+EF-BV with $\nu = 1$ yields exactly DIANA, as shown in Fig. 1. DIANA was only studied with unbiased compressors $\mathcal{C}_i^t\in \mathbb{U}(\omega)$ , for some $\omega \geq 0$ . In that case, $\mathbb{E}\big[g^{t + 1}\big] = \nabla f(x^t)$ , so that $g^{t + 1}$ is an unbiased stochastic gradient estimate; this is not the case in EF21 and EF-BV, in general. Also, $\lambda = \frac{1}{1 + \omega}$ is the usual choice in DIANA, which is consistent with Proposition 2.
+
+# 4 Linear convergence results
+
+We will prove linear convergence of EF-BV under conditions weaker than strong convexity of $f + R$ .
+
+When $R = 0$ , we will consider the Polyak-Łojasiewicz (PL) condition on $f$ : $f$ is said to satisfy the PL condition with constant $\mu > 0$ if, for every $x \in \mathbb{R}^d$ , $\| \nabla f(x) \|^2 \geq 2\mu(f(x) - f^\star)$ , where $f^\star = f(x^\star)$ , for any minimizer $x^\star$ of $f$ . This holds if, for instance, $f$ is $\mu$ -strongly convex; that is, $f - \frac{\mu}{2} \| \cdot \|^{2}$ is convex. In the general case, we will consider the Kurdyka-Łojasiewicz (KL) condition with exponent $1/2$ (Attouch & Bolte, 2009; Karimi et al., 2016) on $f + R$ : $f + R$ is said to satisfy the KL condition with constant $\mu > 0$ if, for every $x \in \mathbb{R}^d$ and $u \in \partial R(x)$ ,
+
+$$
+\left\| \nabla f (x) + u \right\| ^ {2} \geq 2 \mu (f (x) + R (x) - f ^ {\star} - R ^ {\star}), \tag {7}
+$$
+
+where $f^{\star} = f(x^{\star})$ and $R^{\star} = R(x^{\star})$ , for any minimizer $x^{\star}$ of $f + R$ . This holds if, for instance, $R = 0$ and $f$ satisfies the PL condition with constant $\mu$ , so that the KL condition generalizes the PL
+
+condition to the general case $R \neq 0$ . The KL condition also holds if $f + R$ is $\mu$ -strongly convex (Karimi et al., 2016), for which it is sufficient that $f$ is $\mu$ -strongly convex, or $R$ is $\mu$ -strongly convex.
+
+In the rest of this section, we assume that $\mathcal{C}_i^t\in \mathbb{C}(\eta ,\omega)$ , for some $\eta \in [0,1)$ and $\omega \geq 0$ , and we introduce $\omega_{\mathrm{av}}\leq \omega$ such that (6) is satisfied. According to the discussion in Sect. 2.5 (see also Remark 1 below), we define the optimal values for the scaling parameters $\lambda$ and $\nu$ :
+
+$$
+\lambda^ {\star} := \min \left(\frac {1 - \eta}{(1 - \eta) ^ {2} + \omega}, 1\right), \qquad \nu^ {\star} := \min \left(\frac {1 - \eta}{(1 - \eta) ^ {2} + \omega_ {\mathrm {a v}}}, 1\right).
+$$
+
+Given $\lambda \in (0,1]$ and $\nu \in (0,1]$ , we define for convenience $r := (1 - \lambda + \lambda \eta)^2 + \lambda^2\omega$ , $r_{\mathrm{av}} := (1 - \nu + \nu \eta)^2 + \nu^2\omega_{\mathrm{av}}$ , as well as $s^\star := \sqrt{\frac{1 + r}{2r}} - 1$ and $\theta^\star := s^\star(1 + s^\star)\frac{r}{r_{\mathrm{av}}}$ .
+
+Note that if $r < 1$ , according to Proposition 1 and (5), $\lambda \mathcal{C}_i^t \in \mathbb{B}(\alpha)$ , with $\alpha = 1 - r$ .
+
+Our linear convergence results for EF-BV are the following:
+
+Theorem 1. Suppose that $R = 0$ and $f$ satisfies the PL condition with some constant $\mu > 0$ . In EF-BV, suppose that $\nu \in (0,1], \lambda \in (0,1]$ is such that $r < 1$ , and
+
+$$
+0 < \gamma \leq \frac {1}{L + \tilde {L} \sqrt {\frac {r _ {\mathrm {a v}}}{r}} \frac {1}{s ^ {\star}}}. \tag {8}
+$$
+
+For every $t \geq 0$ , define the Lyapunov function $\Psi^t \coloneqq f(x^t) - f^\star + \frac{\gamma}{2\theta^\star} \frac{1}{n} \sum_{i=1}^{n} \left\| \nabla f_i(x^t) - h_i^t \right\|^2$ , where $f^\star \coloneqq f(x^\star)$ , for any minimizer $x^\star$ of $f$ . Then, for every $t \geq 0$ ,
+
+$$
+\mathbb {E} \left[ \Psi^ {t} \right] \leq \left(\max \left(1 - \gamma \mu , \frac {r + 1}{2}\right)\right) ^ {t} \Psi^ {0}. \tag {9}
+$$
+
+Theorem 2. Suppose that $f + R$ satisfies the KL condition with some constant $\mu > 0$ . In EF-BV, suppose that $\nu \in (0,1]$ , $\lambda \in (0,1]$ is such that $r < 1$ , and
+
+$$
+0 < \gamma \leq \frac {1}{2 L + \tilde {L} \sqrt {\frac {r _ {\mathrm {a v}}}{r}} \frac {1}{s ^ {*}}}. \tag {10}
+$$
+
+$\forall t \geq 0$ , define the Lyapunov function $\Psi^t \coloneqq f(x^t) + R(x^t) - f^\star - R^\star + \frac{\gamma}{2\theta^\star} \frac{1}{n} \sum_{i=1}^{n} \left\| \nabla f_i(x^t) - h_i^t \right\|^2$ ,
+
+where $f^{\star} \coloneqq f(x^{\star})$ and $R^{\star} \coloneqq R(x^{\star})$ , for any minimizer $x^{\star}$ of $f + R$ . Then, for every $t \geq 0$
+
+$$
+\mathbb {E} \left[ \Psi^ {t} \right] \leq \left(\max \left(\frac {1}{1 + \frac {1}{2} \gamma \mu}, \frac {r + 1}{2}\right)\right) ^ {t} \Psi^ {0}. \tag {11}
+$$
+
+Remark 1 (choice of $\lambda, \nu, \gamma$ in EF-BV). In Theorems 1 and 2, the rate is better if $r$ is small and $\gamma$ is large. So, we should take $\gamma$ equal to the upper bound in (8) and (10), since there is no reason to choose it smaller. Also, this upper bound is large if $r$ and $r_{\mathrm{av}}$ are small. As discussed in Sect. 2.5, $r$ and $r_{\mathrm{av}}$ are minimized with $\lambda = \lambda^{\star}$ and $\nu = \nu^{\star}$ (which implies that $r_{\mathrm{av}} \leq r < 1$ ), so this is the recommended choice. Also, with this choice of $\lambda, \nu, \gamma$ , there is no parameter left to tune in the algorithm, which is a nice feature.
+
+Remark 2 (low noise regime). When the compression error tends to zero, i.e. $\eta$ and $\omega$ tend to zero, and we use accordingly $\lambda \rightarrow 1$ , $\nu \rightarrow 1$ , such that $r_{\mathrm{av}} / r$ remains bounded, then $\mathcal{C}_i^t \to \mathrm{Id}$ , $r \to 0$ , and $\frac{1}{s^{\star}} \to 0$ . Hence, EF-BV reverts to proximal gradient descent $x^{t+1} = \operatorname{prox}_{\gamma R}(x^t - \nabla f(x^t))$ .
+
+Remark 3 (high noise regime). When the compression error becomes large, i.e. $\eta \rightarrow 1$ or $\omega \rightarrow +\infty$ , then $r \rightarrow 1$ and $\frac{1}{s^{\star}} \sim \frac{4}{1 - r}$ . Hence, the asymptotic complexity of EF-BV to achieve $\epsilon$ -accuracy, when $\gamma = \Theta\left(\frac{1}{L + \tilde{L} \sqrt{\frac{T_{\mathrm{av}}}{r}} \frac{1}{s^{\star}}}\right)$ , is
+
+$$
+\mathcal {O} \left(\left(\frac {L}{\mu} + \left(\frac {\tilde {L}}{\mu} \sqrt {\frac {r _ {\mathrm {a v}}}{r}} + 1\right) \frac {1}{1 - r}\right) \log \frac {1}{\epsilon}\right). \tag {12}
+$$
+
+# 4.1 Implications for EF21
+
+Let us assume that $\nu = \lambda$ , so that EF-BV reverts to EF21, as explained in Sect. 3.1. Then, if we don't assume the prior knowledge of $\omega_{\mathrm{av}}$ , or equivalently if $\omega_{\mathrm{av}} = \omega$ , Theorem 1 with $r = r_{\mathrm{av}}$ recovers the linear convergence result of EF21 due to Richtárik et al. (2021), up to slightly different constants.
+
+However, in these same conditions, Theorem 2 is new: linear convergence of EF21 with $R \neq 0$ was only shown in Theorem 13 of Fatkhullin et al. (2021), under the assumption that there exists $\mu > 0$ such that for every $x \in \mathbb{R}^d$ , $\frac{1}{\gamma^2} \left\| x - \mathrm{prox}_{\gamma R}(x - \gamma \nabla f(x)) \right\|^2 \geq 2\mu(f(x) + R(x) - f^\star - R^\star)$ . This condition generalizes the PL condition, since it reverts to it when $R = 0$ , but it is different from the KL condition, and it is not clear when it is satisfied, in particular whether it is implied by strong convexity of $f + R$ .
+
+The asymptotic complexity to achieve $\epsilon$ -accuracy of EF21 with $\gamma = \Theta\left(\frac{1}{L + \tilde{L} / s^{\star}}\right)$ is $\mathcal{O}\left(\frac{\tilde{L}}{\mu}\frac{1}{1 - r}\log \frac{1}{\epsilon}\right)$ (where we recall that $1 - r = \alpha$ , with the scaled compressors in $\mathbb{B}(\alpha)$ ). Thus, for a given problem and compressors, the improvement of EF-BV over EF21 is the factor $\sqrt{\frac{T_{\mathrm{av}}}{r}}$ in (12), which can be small if $n$ is large.
+
+Theorems 1 and 2 provide a new insight about EF21: if we exploit the knowledge that $\mathcal{C}_i^t\in \mathbb{C}(\eta ,\omega)$ and the corresponding constant $\omega_{\mathrm{av}}$ , and if $\omega_{\mathrm{av}} < \omega$ , then $r_{\mathrm{av}} < r$ , so that, based on (8) and (10), $\gamma$ can be chosen larger than with the default assumption that $r_{\mathrm{av}} = r$ . As a consequence, convergence will be faster. This illustrates the interest of our new finer parameterization of compressors with $\eta ,\omega$ $\omega_{\mathrm{av}}$ . However, it is only half the battle to make use of the factor $\frac{r_{\mathrm{av}}}{r}$ in EF21: the property $\omega_{\mathrm{av}} < \omega$ is only really exploited if $\nu = \nu^{\star}$ in EF-BV (since $r_{\mathrm{av}}$ is minimized this way). In other words, there is no reason to set $\nu = \lambda$ in EF-BV, when a larger value of $\nu$ is allowed in Theorems 1 and 2 and yields faster convergence.
+
+# 4.2 Implications for DIANA
+
+Let us assume that $\nu = 1$ , so that EF-BV reverts to DIANA, as explained in Sect. 3.2. This choice is allowed in Theorems 1 and 2, so that they provide new convergence results for DIANA. Assuming that the compressors are unbiased, i.e. $\mathcal{C}_i^t \in \mathbb{U}(\omega)$ for some $\omega \geq 0$ , we have the following result on DIANA (Condat & Richtárik, 2022, Theorem 5 with $b = \sqrt{2}$ ):
+
+Proposition 3. Suppose that $f$ is $\mu$ -strongly convex, for some $\mu > 0$ , and that in DIANA, $\lambda = \frac{1}{1 + \omega}$ , $0 < \gamma \leq \frac{1}{L_{\max} + L_{\max}(1 + \sqrt{2})^2\omega_{\mathrm{av}}}$ . For every $t \geq 0$ , define the Lyapunov function $\Phi^t \coloneqq \| x^t - x^\star \|^2 + (2 + \sqrt{2})\gamma^2\omega_{\mathrm{av}}(1 + \omega)\frac{1}{n}\sum_{i=1}^{n}\|\nabla f_i(x^\star) - h_i^t\|^2$ , where $x^\star$ is the minimizer of $f + R$ , which exists and is unique. Then, for every $t \geq 0$ , $\mathbb{E}[\Phi^t] \leq \left(\max\left(1 - \gamma\mu, \frac{\frac{1}{2} + \omega}{1 + \omega}\right)\right)^t\Phi^0$ .
+
+Thus, noting that $r = \frac{\omega}{1 + \omega}$ , so that $\frac{r + 1}{2} = \frac{\frac{1}{2} + \omega}{1 + \omega}$ , the rate is exactly the same as in Theorem 1, but with a different Lyapunov function. Theorems 1 and 2 have the advantage over Proposition 3, that linear convergence is guaranteed under the PL or KL assumptions, which are weaker than strong convexity of $f$ . Also, the constants $L$ and $\tilde{L}$ appear instead of $L_{\mathrm{max}}$ . This shows a better dependence with respect to the problem. However, noting that $r = \frac{\omega}{1 + \omega}$ , $r_{\mathrm{av}} = \omega_{\mathrm{av}}$ , $\frac{1}{s^*} \sim 4\omega$ , the factor $\sqrt{\frac{r_{\mathrm{av}}}{r}} \frac{1}{s^*}$ scales like $\sqrt{\omega_{\mathrm{av}}} \omega$ , which is worse than $\omega_{\mathrm{av}}$ . This means that $\gamma$ can certainly be chosen larger in Proposition 3 than in Theorems 1 and 2, leading to faster convergence.
+
+However, Theorems 1 and 2 bring a major highlight: for the first time, they establish convergence of DIANA, which is EF-BV with $\nu = 1$ , with biased compressors. We state the results in Appendix B, by lack of space. In any case, with biased compressors, it is better to use EF-BV than DIANA: there is no interest in choosing $\nu = 1$ instead of $\nu = \nu^{\star}$ , which minimizes $r_{\mathrm{av}}$ and allows for a larger $\gamma$ , for faster convergence.
+
+Finally, we can remark that for unbiased compressors with $\omega_{\mathrm{av}} \ll 1$ , for instance if $\omega_{\mathrm{av}} \approx \frac{\omega}{n}$ with $n$ larger than $\omega$ , then $\nu^{\star} = \frac{1}{1 + \omega_{\mathrm{av}}} \approx 1$ . Thus, in this particular case, EF-BV with $\nu = \nu^{\star}$ and DIANA are essentially the same algorithm. This is another sign that EF-BV with $\lambda = \lambda^{\star}$ and $\nu = \nu^{\star}$ is a generic and robust choice, since it recovers EF21 and DIANA in settings where these algorithms shine.
+
+# 5 Sublinear convergence in the nonconvex case
+
+In this section, we consider the general nonconvex setting. In (1), every function $f_{i}$ is supposed $L_{i}$ -smooth, for some $L_{i} > 0$ . For simplicity, we suppose that $R = 0$ . As previously, we set $\tilde{L} \coloneqq \sqrt{\frac{1}{n}\sum_{i=1}^{n}L_{i}^{2}}$ . The average function $f \coloneqq \frac{1}{n}\sum_{i=1}^{n}f_{i}$ is $L$ -smooth, for some $L \leq \tilde{L}$ . We also suppose that $f$ is bounded from below; that is, $f^{\inf} \coloneqq \inf_{x\in \mathbb{R}^d}f(x) > -\infty$ .
+
+Given $\lambda \in (0,1]$ and $\nu \in (0,1]$ , we define for convenience $r \coloneqq (1 - \lambda + \lambda \eta)^2 + \lambda^2\omega$ , $r_{\mathrm{av}} \coloneqq (1 - \nu + \nu \eta)^2 + \nu^2\omega_{\mathrm{av}}$ , as well as $s \coloneqq \frac{1}{\sqrt{r}} - 1$ and $\theta \coloneqq s(1 + s)\frac{r}{r_{\mathrm{av}}}$ . Our convergence result is the following:
+
+Theorem 3. In EF-BV, suppose that $\nu \in (0,1],\lambda \in (0,1]$ is such that $r < 1$ , and
+
+$$
+0 < \gamma \leq \frac {1}{L + \tilde {L} \sqrt {\frac {r _ {\mathrm {a v}}}{r}} \frac {1}{s}}. \tag {13}
+$$
+
+For every $t \geq 1$ , let $\hat{x}^t$ be chosen from the iterates $x^0, x^1, \dots, x^{t-1}$ uniformly at random. Then
+
+$$
+\mathbb {E} \left[ \left\| \nabla f (\hat {x} ^ {t}) \right\| ^ {2} \right] \leq \frac {2 \left(f \left(x ^ {0}\right) - f ^ {\inf }\right)}{\gamma t} + \frac {G ^ {0}}{\theta t}, \tag {14}
+$$
+
+where $G^0 \coloneqq \frac{1}{n} \sum_{i=1}^{n} \left\| \nabla f_i(x^0) - h_i^0 \right\|^2$ .
+
+# 6 Experiments
+
+We conducted comprehensive experiments to illustrate the efficiency of EF-BV compared to EF21 (we use biased compressors, so we don't include DIANA in the comparison). The settings and results are detailed in Appendix C and some results are shown in Fig. 2; we can see the speedup obtained with EF-BV, which exploits the randomness of the compressors.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+Figure 2: Experimental results. We plot $f(x^{t}) - f^{\star}$ with respect to the number of bits sent by each node during the learning process, which is proportional to $tk$ . Top row: comp-(1, d/2), overlapping $\xi = 1$ . Middle row: comp-(1, d/2), overlapping $\xi = 2$ . Bottom row: comp-(2, d/2), overlapping $\xi = 1$ .
+
+
+
+
+
+
+
+# References
+
+Albasyoni, A., Safaryan, M., Condat, L., and Richtárik, P. Optimal gradient compression for distributed and federated learning. preprint arXiv:2010.03246, 2020.
+Alistarh, D., Grubic, D., Li, J., Tomioka, R., and Vojnovic, M. QSGD: Communication-efficient SGD via gradient quantization and encoding. In Proc. of 31st Conf. Neural Information Processing Systems (NIPS), pp. 1709-1720, 2017.
+Alistarh, D., Hoefler, T., Johansson, M., Khirirat, S., Konstantinov, N., and Renggli, C. The convergence of sparsified gradient methods. In Proc. of Conf. Neural Information Processing Systems (NeurIPS), 2018.
+Attouch, H. and Bolte, J. On the convergence of the proximal algorithm for nonsmooth functions involving analytic features. Math. Program., 116:5-116, 2009.
+Barnes, L. P., Inan, H. A., Isik, B., and Özgür, A. rTop-k: A statistical estimation approach to distributed SGD. IEEE J. Sel. Areas Inf. Theory, 1(3):897-907, November 2020.
+Basu, D., Data, D., Karakus, C., and Diggavi, S. N. Qsparse-Local-SGD: Distributed SGD With Quantization, Sparsification, and Local Computations. IEEE Journal on Selected Areas in Information Theory, 1(1):217-226, 2020.
+Bauschke, H. H. and Combettes, P. L. Convex Analysis and Monotone Operator Theory in Hilbert Spaces. Springer, New York, 2nd edition, 2017.
+Beznosikov, A., Horváth, S., Richtárik, P., and Safaryan, M. On biased compression for distributed learning. preprint arXiv:2002.12410, 2020.
+Chang, C.-C. and Lin, C.-J. LibSVM: A library for support vector machines. ACM Transactions on Intelligent Systems and Technology (TIST), 2(3):27, 2011.
+Condat, L. and Richtárik, P. MURANA: A generic framework for stochastic variance-reduced optimization. In Proc. of the Mathematical and Scientific Machine Learning (MSML) conference, 2022.
+Condat, L., Kitahara, D., Contreras, A., and Hirabayashi, A. Proximal splitting algorithms for convex optimization: A tour of recent advances, with new twists. SIAM Review, 2022a. to appear.
+Condat, L., Malinovsky, G., and Richtárik, P. Distributed proximal splitting algorithms with rates and acceleration. Frontiers in Signal Processing, 1, January 2022b.
+Dutta, A., Bergou, E. H., Abdelmoniem, A. M., Ho, C. Y., Sahu, A. N., Canini, M., and Kalnis, P. On the discrepancy between the theoretical analysis and practical implementations of compressed communication for distributed deep learning. In Proc. of AAAI Conf. Artificial Intelligence, pp. 3817-3824, 2020.
+Fatkhullin, I., Sokolov, I., Gorbunov, E., Li, Z., and Richtárik, P. EF21 with bells & whistles: Practical algorithmic extensions of modern error feedback. preprint arXiv:2110.03294, 2021.
+Gandikota, V., Kane, D., Maity, R. K., and Mazumdar, A. vqSGD: Vector quantized stochastic gradient descent. preprint arXiv:1911.07971, 2019.
+Gorbunov, E., Hanzely, F., and Richtárik, P. A unified theory of SGD: Variance reduction, sampling, quantization and coordinate descent. In Proc. of 23rd Int. Conf. Artificial Intelligence and Statistics (AISTATS), 2020a.
+Gorbunov, E., Kovalev, D., Makarenko, D., and Richtárik, P. Linearly converging error compensated SGD. In Proc. of 34th Conf. Neural Information Processing Systems (NeurIPS), 2020b.
+Gower, R. M., Schmidt, M., Bach, F., and Richtárik, P. Variance-reduced methods for machine learning. Proc. of the IEEE, 108(11):1968-1983, November 2020.
+Gower, R. M., Richtárik, P., and Bach, F. Stochastic quasi-gradient methods: Variance reduction via Jacobian sketching. Math. Program., 188:135-192, July 2021.
+
+Hanzely, F. and Richtárik, P. One method to rule them all: Variance reduction for data, parameters and many new methods. preprint arXiv:1905.11266, 2019.
+Horváth, S., Ho, C.-Y., Horváth, L., Sahu, A. N., Canini, M., and Richtárik, P. Natural compression for distributed deep learning. preprint arXiv:1905.10988, 2019.
+Horváth, S., Kovalev, D., Mishchenko, K., Stich, S., and Richtárik, P. Stochastic distributed learning with gradient quantization and variance reduction. Optimization Methods and Software, 2022.
+Kairouz, P. et al. Advances and open problems in federated learning. Foundations and Trends in Machine Learning, 14(1-2), 2021.
+Karimi, H., Nutini, J., and Schmidt, M. Linear convergence of gradient and proximal-gradient methods under the Polyak-Lojasiewicz condition. In Frasconi, P., Landwehr, N., Manco, G., and Vreeken, J. (eds.), Machine Learning and Knowledge Discovery in Databases, pp. 795–811, Cham, 2016. Springer International Publishing.
+Khaled, A. and Richtárik, P. Gradient descent with compressed iterates. In NeurIPS Workshop on Federated Learning for Data Privacy and Confidentiality, 2019.
+Khaled, A., Sebbouh, O., Loizou, N., Gower, R. M., and Richtárik, P. Unified analysis of stochastic gradient methods for composite convex and smooth optimization. preprint arXiv:2006.11573, 2020.
+Konečny, J., McMahan, H. B., Yu, F. X., Richtárik, P., Suresh, A. T., and Bacon, D. Federated learning: Strategies for improving communication efficiency. In NIPS Workshop on Private Multi-Party Machine Learning, 2016.
+Li, T., Sahu, A. K., Talwalkar, A., and Smith, V. Federated learning: Challenges, methods, and future directions. IEEE Signal Processing Magazine, 3(37):50-60, 2020a.
+Li, Z., Kovalev, D., Qian, X., and Richtárik, P. Acceleration for compressed gradient descent in distributed and federated optimization. In Proc. of 37th Int. Conf. Machine Learning (ICML), 2020b.
+Lin, C.-Y., Kostina, V., and Hassibi, B. Differentially quantized gradient methods. IEEE Trans. Inf. Theory, 68(9):6078-6097, September 2022.
+Mayekar, P. and Tyagi, H. RATQ: A universal fixed-length quantizer for stochastic optimization. IEEE Trans. Inf. Theory, 67(5):3130-3154, 2021.
+McMahan, H. B., Moore, E., Ramage, D., Hampson, S., and Agüera y Arcas, B. Communication-efficient learning of deep networks from decentralized data. In Proc. of Int. Conf. Artificial Intelligence and Statistics (AISTATS), volume PMLR 54, 2017.
+Mishchenko, K., Gorbunov, E., Takáč, M., and Richtárik, P. Distributed learning with compressed gradient differences. arXiv:1901.09269, 2019.
+Mishchenko, K., Hanzely, F., and Richtárik, P. $99\%$ of worker-master communication in distributed optimization is not needed. In Proc. of 36th Conf. on Uncertainty in Artificial Intelligence (UAI), volume 124, pp. 979-988, 2020.
+Parikh, N. and Boyd, S. Proximal algorithms. Foundations and Trends in Optimization, 3(1):127-239, 2014.
+Philippenko, C. and Dieuleveut, A. Bidirectional compression in heterogeneous settings for distributed or federated learning with partial participation: tight convergence guarantees. arXiv:2006.14591, 2020.
+Qian, X., Sailanbayev, A., Mishchenko, K., and Richtárik, P. MISO is making a comeback with better proofs and rates. arXiv:1906.01474, June 2019.
+Richtárik, P. and Takáč, M. Parallel coordinate descent methods for big data optimization. Math. Program., 156:433-484, 2016.
+
+Richtárik, P., Sokolov, I., and Fatkhullin, I. EF21: A new, simpler, theoretically better, and practically faster error feedback. In Proc. of 35th Conf. Neural Information Processing Systems (NeurIPS), 2021.
+Safaryan, M., Shulgin, E., and Richtárik, P. Uncertainty principle for communication compression in distributed and federated learning and the search for an optimal compressor. Information and Inference: A Journal of the IMA, 2021.
+Saha, R., Pilanci, M., and Goldsmith, A. J. Democratic source coding: An optimal fixed-length quantization scheme for distributed optimization under communication constraints. preprint arXiv:2103.07578, 2021.
+Sattler, F., Wiedemann, S., Müller, K.-R., and Samek, W. Robust and communication-efficient federated learning from non-i.i.d. data. IEEE Trans. Neural Networks and Learning Systems, 31 (9):3400-3413, 2020.
+Seide, F., Fu, H., Droppo, J., Li, G., and Yu, D. 1-bit stochastic gradient descent and application to data-parallel distributed training of speech DNNs. In Proc. of Annual Conf. of Int. Speech Communication Association (Interspeech), 2014.
+Szlendak, R., Tyurin, A., and Richtárik, P. Permutation compressors for provably faster distributed nonconvex optimization. In Proc. of Int. Conf. on Learning Representations (ICLR), 2022.
+Verbraeken, J., Wolting, M., Katzy, J., Kloppenburg, J., Verbelen, T., and Rellermeyer, J. S. A survey on distributed machine learning. ACM Computing Surveys, 53(2):1-33, March 2021.
+Wangni, J., Wang, J., Liu, J., and Zhang, T. Gradient sparsification for communication-efficient distributed optimization. In Proc. of 32nd Conf. Neural Information Processing Systems (NeurIPS), pp. 1306-1316, 2018.
+Wen, W., Xu, C., Yan, F., Wu, C., Wang, Y., Chen, Y., and Li, H. TernGrad: Ternary gradients to reduce communication in distributed deep learning. In Proc. of 31st Conf. Neural Information Processing Systems (NIPS), pp. 1509-1519, 2017.
+Xu, H., Ho, C.-Y., Abdelmoniem, A. M., Dutta, A., Bergou, E. H., Karatsenidis, K., Canini, M., and Kalnis, P. Compressed communication for distributed deep learning: Survey and quantitative evaluation. Technical report, KAUST, 2020.
+Xu, H., Ho, C.-Y., Abdelmoniem, A. M., Dutta, A., Bergou, E. H., Karatsenidis, K., Canini, M., and Kalnis, P. GRACE: A compressed communication framework for distributed machine learning. In Proc. of 41st IEEE Int. Conf. Distributed Computing Systems (ICDCS), 2021.
+Zhang, J., You, K., and Xie, L. Innovation compression for communication-efficient distributed optimization with linear convergence. preprint arXiv:2105.06697, 2021.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [N/A]. This is a theoretical work. There are many open questions on extending the convergence results to other settings, but this is room for future work, not really a limitation.
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [No] We do not provide code but the methods are easy to implement. Existing code for DIANA or EF21 can easily be adapted by changing the step sizes. All the information to reproduce the experiments is provided.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] From our experience there is little influence of the random seed.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/images.zip b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..82adff5d5b71d08675e34a023e2a8e413157bd2e
--- /dev/null
+++ b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e2b60b9458a20d488b5f8ee1a18a5d1366c54ab13e21357571259b09af63553a
+size 248703
diff --git a/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/layout.json b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..2e8f44c87f1ac0c03c41191fd829122a55f03ef2
--- /dev/null
+++ b/efbvaunifiedtheoryoferrorfeedbackandvariancereductionmechanismsforbiasedandunbiasedcompressionindistributedoptimization/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9a9f04a567e8d6fe4618d79eb2a0401f8a6ce40e82044227f9c586ed6788c4e1
+size 838104
diff --git a/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/9fa27463-fae1-4139-8b3b-decc4e7df8a7_content_list.json b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/9fa27463-fae1-4139-8b3b-decc4e7df8a7_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..97b65a949038c1fed42330377158281ce79ba786
--- /dev/null
+++ b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/9fa27463-fae1-4139-8b3b-decc4e7df8a7_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3421c0d8d8e2d93719421d7de19a57442ad190575f2d23ef63d7002e6df0a6c1
+size 80819
diff --git a/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/9fa27463-fae1-4139-8b3b-decc4e7df8a7_model.json b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/9fa27463-fae1-4139-8b3b-decc4e7df8a7_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..21b5e6b3d62785210e92ab7bccf6bec423f0e76d
--- /dev/null
+++ b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/9fa27463-fae1-4139-8b3b-decc4e7df8a7_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c43690b9998ccdf393d55601ec039c6845d2ba92559639a291f17ac75eb00499
+size 102029
diff --git a/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/9fa27463-fae1-4139-8b3b-decc4e7df8a7_origin.pdf b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/9fa27463-fae1-4139-8b3b-decc4e7df8a7_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..26d1c859ad0ba3f5e0e6537b100d383212cce2bb
--- /dev/null
+++ b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/9fa27463-fae1-4139-8b3b-decc4e7df8a7_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2372fb496ecad4cff0d1b0ae65b4f75c3b8b9144f41cba934aaab8b18d53bdba
+size 1232126
diff --git a/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/full.md b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..46fc377b49cab24beb18de94d91400a94ca26d35
--- /dev/null
+++ b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/full.md
@@ -0,0 +1,279 @@
+# Effective Adaptation in Multi-Task Co-Training for Unified Autonomous Driving
+
+Xiwen Liang $^{1*}$ , Yangxin Wu $^{1*}$ , Jianhua Han $^{2}$ , Hang Xu $^{2}$ , Chunjing Xu $^{2}$ , Xiaodan Liang $^{1\dagger}$ $^{1}$ Shenzhen Campus of Sun Yat-Sen University, $^{2}$ Huawei Noah's Ark Lab {liangxw29@mail2, wuyx29@mail2, liangxd9@mail}.sysu.edu.cn, {hanjianhua4, xuHang, xuchunjing}@huawei.com
+
+# Abstract
+
+Aiming towards a holistic understanding of multiple downstream tasks simultaneously, there is a need for extracting features with better transferability. Though many latest self-supervised pre-training methods have achieved impressive performance on various vision tasks under the prevailing pretrain-finetune paradigm, their generalization capacity to multi-task learning scenarios is yet to be explored. In this paper, we extensively investigate the transfer performance of various types of self-supervised methods, e.g., MoCo and SimCLR, on three downstream tasks, including semantic segmentation, drivable area segmentation, and traffic object detection, on the large-scale driving dataset BDD100K. We surprisingly find that their performances are sub-optimal or even lag far behind the single-task baseline, which may be due to the distinctions of training objectives and architectural design lied in the pretrain-finetune paradigm. To overcome this dilemma as well as avoid redesigning the resource-intensive pre-training stage, we propose a simple yet effective pretrain-adapt-finetune paradigm for general multi-task training, where the off-the-shelf pretrained models can be effectively adapted without increasing the training overhead. During the adapt stage, we utilize learnable multi-scale adapters to dynamically adjust the pretrained model weights supervised by multi-task objectives while leaving the pretrained knowledge untouched. Furthermore, we regard the vision-language pre-training model CLIP as a strong complement to the pretrain-adapt-finetune paradigm and propose a novel adapter named LV-Adapter, which incorporates language priors in the multi-task model via task-specific prompting and alignment between visual and textual features. Our experiments demonstrate that the adapt stage significantly improves the overall performance of those off-the-shelf pretrained models and the contextual features generated by LV-Adapter are of general benefits for downstream tasks.
+
+# 1 Introduction
+
+Multi-task learning is a long-studied problem in computer vision and has become an emerging paradigm in autonomous driving [19, 50, 18]. An autonomous vehicle may need to concurrently perform a wide range of perception tasks, e.g., locating the pedestrians and cars, deciding road affordability for driving, as well as detecting the lanes to precipitate a driving action. The joint learning of multiple tasks can not only reduce the training and inference time, but also act as a regularizer that enforces the learning of generalizable representations [6, 19]. Apart from efficiency and simplicity, an all-in-one architecture is argued to have the potential to enhance the robustness of the driving system by implicitly learning the synergy between heterogeneous tasks [19, 45, 40].
+
+
+Figure 1: Our multi-task model takes (a) an RGB image as input and tackles (b) traffic object detection, (c) semantic segmentation, and (d) drivable area segmentation simultaneously.
+
+
+
+
+
+
+
+In the pursuit of the merits of multi-task learning, it is crucial to obtain universal features with great transferability. Recently, many concurrent self-supervised pre-training methods have shown great potential when transferred to different types of vision tasks [47, 49, 44] under the pretrain-finetune paradigm. Despite the impressive performance, their transferability to multi-task learning scenarios is yet to be explored. We argue that the heterogeneity of tasks will introduce a multitude of challenges to train a unified model and it is often not the case that multi-task learning is of universal benefit. Firstly, the widely adopted pretrain-finetune paradigm may lead to degraded performance in multi-task learning due to the misalignment of objectives between pre-training and fine-tuning [12, 16] since most supervised and self-supervised methods are highly specialized for a specific type of objective or task [3, 4, 47, 49]. Secondly, the performance of multi-task learning relies on many non-trivial factors including model architectures, data augmentations, hyperparameters, convergence properties, etc [36, 39]. The specialized techniques catered for a specific type of architecture or task are largely not applicable to a universal architecture since they are prone to fail during generalization. Moreover, due to the labor-intensive process of data annotation, it is hard to collect complete annotations of different granularities for all tasks, which further complicates the situation.
+
+In this paper, we focus on heterogeneous multi-task learning on partially labeled data (HMPL) under the realistic scenario of autonomous driving. We first delve into the representation learning stage of HMPL to reveal the performance degradation of different pre-training methods. We thoroughly examine a wide range of pre-training methods including supervised pre-training (pretrained on ImageNet [33]), classification-oriented methods (e.g., SimCLR [3], MoCo [15]), detection-oriented methods (e.g., DetCo [47]), segmentation-oriented methods (e.g., DenseCL [44]), and vision-language pre-training methods (e.g., CLIP [29]) on three fine-grained tasks on the large-scale driving dataset BDD100K [52], i.e., object detection, semantic segmentation, and drivable area segmentation. Surprisingly, the performance of these methods varies greatly under the same training protocol, especially on the dense prediction task. For example, MoCov2 [4] only gets 12.5 mIoU in semantic segmentation and segmentation-oriented models like DenseCL [44] and DetCo [47] perform unsatisfactorily on dense prediction tasks, which suggests that the misalignment lied in the pretrain-finetune paradigm can lead to prominent performance degradation and there exists much room for improvement.
+
+Given that 'universal' pre-training is still unsolved and redesigning the resource-intensive pre-training scheme comes with great computation overhead, we aim to develop a general approach that can fully harness the knowledge from the off-the-shelf pretrained models and make them amenable to multi-task scenarios via efficient adaptation. We draw inspiration from the recent progress of prompt-based learning in NLP [24, 55, 29, 10], where the language model pretrained on massive amounts of raw text can be adapted to new scenarios with high efficiency by introducing hand-crafted or learnable prompts. Following this philosophy, we propose a simple yet effective pretrain-adapt-finetune paradigm for multi-task transfer learning as a substitute for the dominating pretrain-finetune paradigm in computer vision. Concretely, during the adapt stage, learnable multi-scale adapters with a small amount of parameters are tuned with frozen random initialized task-specific heads to dynamically adapt the knowledge from the pretrained models under the multi-task objectives. Albeit simple, we show that the adapt stage mitigates the gap between pre-training and fine-tuning and significantly improves the overall performance across different pretrained models while being very effective and introducing no extra training overhead.
+
+Apart from the supervised and self-supervised pre-training, Contrastive Language-Image Pre-training (CLIP) [29] manages to learn high-quality visual representation from an enormous amount of noisy image-text pairs. CLIP achieves breakthrough performance in zero-shot image recognition, which indicates that it might have great potential for improving the generality and robustness of multi-task learning. To this end, we propose LV-Adapter to further excavate the linguistic knowledge from CLIP
+
+
+Figure 2: Comparisons of the conventional pretrain-finetune paradigm and our proposed pretrain-adapt-finetune paradigm. The language-guided pretrain-adapt-finetune paradigm further incorporates language priors into multiple downstream tasks.
+
+and enhance the visual representations in the multi-task scenarios. To maximize the correspondence between the dense features and the class-specific concepts, we first learn task-specific prompts in an end-to-end manner. Then we model the language-to-vision adaptation function based on the cross-attention mechanism [43] to incorporate language priors in visual features.
+
+We experimentally verify that our proposed pretrain-adapt-finetune paradigm significantly improves the overall performance of different off-the-shelf pre-training methods. For example, it obtains an absolute improvement by over $40\%$ in semantic segmentation on MoCo-v1/v2, and DenseCL [15, 4, 44], and its superior performance does not rely on extra training costs or sophisticated architectural design. Furthermore, we showcase that our proposed LV-Adapter can serve as an effective complementary approach for multi-task learning. Especially, we experiment on three settings that correspond to different levels of annotation quantity and observe that LV-Adapter brings consistent performance gains on three heterogeneous tasks simultaneously. We hope our work can shed light on the heterogeneous multi-task learning by showing that effective adaptation is of great essence to mitigate the deficiency in the dominating pretrain-finetune paradigm.
+
+# 2 Related Work
+
+Multi-Task Learning Multi-task learning aims to improve efficiency and accuracy through shared information among multiple tasks. MultiNet [41] joints classification, detection and semantic segmentation via a unified architecture. Eigen et al. [8] address depth prediction, surface normal estimation, and semantic labeling. YOLOP [45] leverages CSPDarknet as the backbone and adopts three specific decoders to solve object detection, drivable area segmentation, and lane detection respectively. Standley et al. [36] and Fifty et al. [9] propose to identify proper task groupings for multi-task training instead of naively training all tasks together. In this paper, we focus on developing general and effective approaches for multi-task transfer learning in autonomous driving scenarios. We provide more discussions with several related works in the Appendix.
+
+Pre-training Methods A dominating paradigm in computer vision is to pretrain on a large scale of data, e.g., ImageNet [33], then finetune on target tasks with usually less training data. Recently, researchers are interested in learning visual representations without human supervision. We roughly divided them into three classes, namely, classification-oriented, detection-oriented, and segmentation-oriented methods. Classification-oriented methods typically rely on contrastive learning and online clustering, e.g., SimCLR [3], MoCo [15, 4], and BYOL [14]. Detection-oriented methods like DetCo [47] are specially designed for object detection by conducting contrastive learning between the global image and local patches. Segmentation-oriented methods like PixPro [49] further work on pixel-level correspondence to benefit dense prediction downstream tasks. We show that these methods are sub-optimal for multi-task learning, and we focus on improving the performance of these off-the-shelf methods instead of redesigning the computation-intensive pre-training stage.
+
+Prompting Learning Natural language prompting freezes large-scale pretrained language models and reformulates text input with example or learnable prompts to bridge the gap between pre-training
+
+Table 1: Comparisons of popular multi-task training methods and our proposed LV-Adapter under the Disjoint-normal setting.
+
+| Method | mIoU (SS) | mIoU (DA) | mAP | AP50 | AP75 |
| Zeroing loss [46] | 59.4 | 83.3 | 23.0 | 46.0 | 19.8 |
| Uniform sampler [22] | 59.9 | 83.2 | 24.3 | 47.0 | 21.8 |
| Weighted sampler [22] | 59.8 | 83.2 | 24.2 | 46.9 | 21.4 |
| Round-robin [22] | 60.7 | 83.1 | 24.2 | 47.0 | 21.5 |
| Self-training [12] | 60.3 | 83.1 | 24.9 | 48.1 | 22.2 |
| LV-Adapter (Ours) | 62.2 | 83.7 | 26.4 | 50.5 | 23.7 |
+
+and model tuning efficiently. GPT-3 [1] first introduces in-context learning, prepending hard text prompts for every task before the input. Then many works based on such discrete text prompts have emerged, i.e., designing prompts manually [37, 34] and searching trigger words [35, 11]. Furthermore, recent methods inject learnable soft prompts [21, 26, 53] into the embedding space of the model and achieve impressive performance. In the field of computer vision, CLIP [29] trains on millions of vision-language pairs and demonstrates effective zero-shot classification. CoOp [55], CPT [51], and CLIP-Adapter [10] further tunes fixed CLIP with soft prompts by few-shot supervisions.
+
+# 3 Empirical Study
+
+# 3.1 Heterogeneous Multi-Task Setup
+
+We concentrate on three challenging heterogeneous tasks in autonomous driving, i.e., traffic object detection, semantic segmentation, and drivable area segmentation, on large-scale driving dataset BDD100K [52]. We showcase the input and output of our model in Figure 1. We select the state-of-the-art detector and segmentation decoder head to build up our model. To be specific, we follow the hard-parameter sharing scheme [6] where each task shares the same backbone and has its task-specific head. We outline our model architecture in Figure 2 and elaborate each component in the following.
+
+Backbone & Neck. We adopt the classic ResNet [17] as backbone and FPN [23] as neck to generate multi-scale features. The FPN neck [23] constructs pyramidal features, namely, $\{P_2, P_3, P_4, P_5\}$ , which have strides of $\{4, 8, 16, 32\}$ pixels w.r.t the input image and fixed 256 channels.
+
+Segmentation Head. We implement the decoder for segmentation based on MaskFormer [5]. MaskFormer formulates the segmentation task as a mask classification problem and its head is composed of a fully convolutional pixel decoder and a transformer decoder module. The pixel decoder takes $\{P_2, P_3, P_4, P_5\}$ as input and gradually upsamples the features to produce high resolution per-pixel embeddings $\varepsilon_{\mathrm{pixel}}$ . The transformer decoder module utilizes a fixed set of queries to attend to image features and produces mask embeddings $\varepsilon_{\mathrm{mask}}$ . Then $\varepsilon_{\mathrm{pixel}}$ and $\varepsilon_{\mathrm{mask}}$ is multiplied together to generate prediction masks. We refer the reader to [5] for more details.
+
+Detection Head. We implement our detector based on Sparse R-CNN [38]. The detection pipeline constructs a fixed set of learnable proposal boxes (e.g., 300) which serve as region proposals and are fed into a series of heads for prediction. The dynamic instance interactive head dynamically generates the weights of a convolution filter that attends to the bins in the region proposals and predicts the location and category of object in a cascade manner.
+
+We introduce three settings, i.e., the Disjoint-normal, Disjoint-balance, and Full-setting, corresponding to different levels of annotation quantity in our experiments. For clarity, we defer the detailed descriptions of three settings to Section 5.1. For consistency, we conduct evaluations on the same validation set of BDD100K for different settings above. We mainly work under the Disjoint-normal setting for comparisons between the performance of different pre-training methods as well as ablation studies. And we further verify the efficacy of our proposed methods on the Disjoint-balance and the Full-setting in Section 5.2.
+
+Table 2: Comparisons of different paradigms under the Disjoint-normal setting with ResNet-50 backbone. Orange color indicates the results of our proposed pretrain-adapt-finetune paradigm, while others are results of conventional pretrain-finetune paradigm.
+
+ | Semantic Seg. | Drivable Seg. | Object Detection |
| Type | Model | mIoU | pACC | mIoU | pACC | mAP | AP50 | AP75 |
| Classification-oriented | MoCo-v1 [15] | 17.8 | 48.6 | 70.8 | 92.0 | 25.8 | 49.5 | 23.1 |
| 59.2 | 93.2 | 83.6 | 96.9 | 25.9 | 50.0 | 23.0 |
| MoCo-v2 [4] | 10.3 | 19.8 | 73.4 | 93.5 | 26.0 | 50.1 | 23.2 |
| 61.2 | 93.4 | 83.8 | 96.9 | 26.1 | 50.4 | 23.4 |
| SimCLR [3] | 60.3 | 93.3 | 83.5 | 96.8 | 25.4 | 48.9 | 22.5 |
| 60.1 | 93.2 | 83.5 | 96.8 | 25.2 | 48.9 | 22.3 |
| SwAV [2] | 45.9 | 71.1 | 82.0 | 96.5 | 25.6 | 49.1 | 23.0 |
| 61.1 | 93.3 | 83.1 | 96.7 | 25.6 | 49.3 | 23.1 |
| BYOL [14] | 59.2 | 90.2 | 75.6 | 93.9 | 25.9 | 49.8 | 23.4 |
| 61.7 | 93.4 | 83.5 | 96.8 | 25.7 | 49.4 | 23.1 |
| Detection-oriented | DetCo [47] | 38.1 | 58.5 | 83.2 | 96.7 | 25.9 | 49.7 | 22.9 |
| 61.0 | 93.4 | 83.7 | 96.9 | 26.2 | 50.3 | 23.3 |
| Segmentation-oriented | DenseCL [44] | 20.0 | 40.0 | 73.7 | 93.7 | 26.1 | 50.3 | 23.5 |
| 60.7 | 93.3 | 83.9 | 96.9 | 26.3 | 50.3 | 23.7 |
| Vision-language | CLIP [29] | 54.5 | 91.1 | 74.1 | 93.1 | 26.5 | 50.7 | 23.8 |
| 61.0 | 93.2 | 83.4 | 96.8 | 26.3 | 50.5 | 23.5 |
+
+# 3.2 Multi-Task Learning Baselines
+
+Self-training Based on the available annotations for each task, we trained three single-task teacher models on the labeled data and use them to generate pseudo labels on unlabeled data following [48, 12]. For single-task teacher models, we adopt the same architecture and training schedules of Sparse R-CNN [38] and MaskFormer [5]. For object detection, we use a score threshold of 0.5 to select pseudo box labels. For segmentation, we use the score threshold of 0.3 to select segmentation masks. Pixels with lower scores are assigned with the ignore label. Thereafter, every image has annotations for all tasks and we train a multi-task student model with a weighted sum of all objectives for each task:
+
+$$
+\mathcal {L} _ {\text {t o t a l}} = \alpha_ {\text {d e t}} \mathcal {L} _ {\text {d e t}} + \alpha_ {\text {s e m}} \mathcal {L} _ {\text {s e m}} + \alpha_ {\text {d r i v}} \mathcal {L} _ {\text {d r i v}}, \tag {1}
+$$
+
+where $\mathcal{L}_{\text{det}}, \mathcal{L}_{\text{sem}}, \mathcal{L}_{\text{driv}}$ are losses for object detection, semantic segmentation, and drivable area segmentation, respectively. We include more details in Section 5.1.
+
+Zeroing loss Some works [19, 46] simply zero losses for a particular task if the input image does not have the corresponding annotation.
+
+Batch-level Round-Robin In this scheme [52, 22], each batch consists of samples that have the same type of annotations for a task and different tasks are repeated in a fixed order during training.
+
+Task Scheduling This is a stochastic schedule that the task for each SGD update step is sampled from a distribution [22]. We mainly consider a uniform task sampling schedule that sampled from a uniform distribution, and a weighted task sampling schedule where the sampling weight for a task is proportional to the number of labeled images and training epochs for this task.
+
+Performance Comparison As can be seen in Table 1 and Table 3, these methods surpass single-task teacher model by a clear margin, which indicates that the model benefits from multi-task learning. Among these baselines, self-training achieves satisfactory performance while being conceptually simple, thus we adopt it for the rest experiments in this paper.
+
+
+Figure 3: An overview of our proposed model. We first train three specialized teacher on labeled data to generate pseudo labels for each task. The multi-task model is then trained on both ground-truth and pseudo labels under the language-guided pretrain-adapt-finetune paradigm.
+
+# 3.3 Pretrain-finetune for Multi-Task Learning
+
+In this section, we adopt the identical training protocol and architecture to extensively investigate the performances of different types of pre-training methods, including task-oriented methods and vision-language pre-training, when transferred to the multi-task learning scenario. We revisit the technical details of these different schemes in the Appendix. We report the performance of the aforementioned methods in Table 2, and come to the following observations:
+
+- Only SimCLR achieves decent performance on all three tasks and many methods encounter substantial degradation on pixel-level segmentation tasks. For semantic segmentation, MoCo-v1/v2 and DenseCL achieve the worst mIoU (degrade by $66\% - 83\%$ v.s. ImageNet-pretrained). For drivable area segmentation, MoCo-v1/v2, DenseCL, and CLIP have the worst performance (degrade by nearly $12\%$ v.s. ImageNet-pretrained).
+- The pre-training paradigm does not seem to have an explicit correlation with the downstream performance, and even the task-oriented design in pre-training does not guarantee the transfer performance on the corresponding task type. For example, the segmentation-oriented DenseCL achieves sub-optimal performance on two segmentation tasks.
+
+# 4 Effective Adaptation for Multi-Task Learning
+
+# 4.1 Pretrain, Adapt, then Finetune
+
+We attribute the degraded transferring performance of the state-of-the-art pre-training methods to two critical factors, i.e., optimization gap and architectural gap. Firstly, the high specialization of the pre-training methods and the heterogeneity of downstream tasks result in the optimization gap in the classic pretrain-finetune paradigm. To be specific, the objective for pre-training is usually a type of contrastive loss (e.g., InfoNCE [42]) while the fine-tuning stage is supervised by a weighted sum of several task-specific losses. Secondly, we notice that many models in Table 2 are pretrained with a convolutional head, e.g., Fast R-CNN detector [13] or convolution-based projection head. In contrast, we adopt the transformer-based MaskFormer head for segmentation tasks. The distinctions between convolution and transformer lie in the inductive bias (local v.s. global) and the internal representation structure [30] and we conjecture this plays a non-negligible role in transferring. We further experimentally verify this point in Appendix.
+
+The limited transfer performance presented in Table 2 indicates that the 'universal' pre-training remains unsolved. Instead of redesigning another pre-training scheme that brings vast computation overhead, we aim to efficiently reuse the intact knowledge of these off-the-shelf pre-trained models with minimal modifications to the architecture. We draw inspiration from the recent progress of prompt-based learning, where prompt tuning emerges as a new alternative to fine-tuning. For example, P-Tuning v2 [25] matches the fine-tuning performance by only tuning learnable prompts
+
+while freezing the large-scale language model. Following this philosophy, we propose a simple yet effective pretrain-adapt-finetune paradigm to mitigate the gap between the pre-training and fine-tuning stage. During the adaptation stage, we are given the pretrained model weights (e.g., ResNet-50) inherited from the pre-training stage. We aim to transform the model weights via a small amount of learnable parameters to adapt the knowledge of the pretrained weights towards multi-task scenarios. To this end, we freeze the parameters of the random initialized task-specific heads and the backbone, and tune the parameters of Feature Pyramid Network (FPN) supervised by the multi-task loss function in Equation 1. During fine-tuning, all parameters are activated and updated via gradient descent. We compare different schemes for multi-task learning in Figure 2. This adaptation stage characterizes several critical design choices: (1) This stage bridges the gap between pre-training and fine-tuning by including the pretrained weights and multi-task objectives simultaneously, and the frozen backbone prevents the pretrained weights from being spoiled before the fine-tuning stage. (2) Compared to the single-layer prompt/adapter in P-Tuning [20] and CLIP-Adapter [10], the FPN acts as a multi-scale adapter that is endowed with greater capacity and provides semantically stronger features for fine-grained downstream tasks. (3) Taking FPN as the adapter means that the model architecture for the pretrain-finetune and pretrain-adapt-finetune paradigm is identical and effective adaptation can be achieved without any modification to the architecture. We have experimented with more sophisticated adapters (e.g., scale-aware adapters, lightweight transformers) and observed marginally better results. Hence, we opt for the original architecture above for simplicity. We experimentally verify that our pretrain-adapt-finetune paradigm significantly improves the performance and stability of different kinds of pre-training methods (c.f. Section 5.2) without increasing the total training costs (c.f. Section 5.3).
+
+# 4.2 Language-to-Vision Adapter
+
+From the perspective of transfer learning, CLIP can serve as a complementary scheme to enhance the pretrain-adapt-finetune paradigm, since it can comprehend the concepts in natural language. Basically, the CLIP model excels in aligning the visual and language embeddings and some works [54, 31] claim that the textual features generated by CLIP have meaningful correspondence to the semantic regions in an image. We note that the result of CLIP in Table 2 only reuses the weights of its image encoder and discards the text encoder. Therefore, we take a step further to explicitly exploit the knowledge in the full CLIP model. We pursue to underpin the compatibility between the semantic concepts of each task and the image features and generate semantically stronger contexts for downstream tasks. The resulting model, named LV-Adapter, is outlined in Figure 3, and we elaborate on each ingredient in the followings.
+
+The CLIP model adopts ResNet [17] and BERT [7] as the encoder for image and text, respectively. Formally, we denote the last output feature maps from ResNet stages as $\{\mathbf{x}_i\}_{i=2}^5$ . Attentional pooling and $L_2$ normalization are applied to $\mathbf{x}_5 \in \mathbb{R}^{H_5 W_5 \times C_5}$ to produce the global image feature $\hat{\mathbf{I}}_e \in \mathbb{R}^{1 \times C_5}$ for zero-shot inference, which can be formulated as follows:
+
+$$
+[ \hat {\mathbf {I}} _ {e}, \hat {\mathbf {x}} _ {5} ] = \mathrm {L 2} _ {-} \operatorname {N O R M} (\operatorname {M H S A} (\operatorname {G A P} (\mathbf {x} _ {5}) \oplus \mathbf {x} _ {5})), \tag {2}
+$$
+
+where $\mathrm{GAP}(\cdot)$ denotes global average pooling, $\mathrm{MHSA}(\cdot)$ denotes multi-head self-attention [43], and $\oplus$ denotes concatenation operation. To extract textual features of each class, class-specific prompts are constructed via a generator function and are fed into the text encoder. We denote the normalized output features for $N$ classes as $\hat{\mathbf{T}}_e\in \mathbb{R}^{N\times C}$ , which can be obtained as follow:
+
+$$
+\hat {\mathbf {T}} _ {e} = \mathrm {L 2} \_ \mathrm {N O R M} (\mathrm {T E} (\operatorname {G e n} (\{\mathbf {n} _ {i} \} _ {i = 1} ^ {N}))), \tag {3}
+$$
+
+where $\mathrm{Gen}(\cdot)$ is the generator function of class-specific prompts, TE is the text encoder, and $\{\mathbf{n}_i\}_{i=1}^N$ is the class name embeddings. Though $\hat{\mathbf{T}}_e$ and $\hat{\mathbf{I}}_e$ are well aligned in the image-text contrastive pretraining, they do not preserve any spatial details and are not readily applicable for downstream vision tasks. In contrast, the multi-level features output by FPN are semantically rich in the spatial dimension but are not directly aligned in the pre-training stage. Therefore, we pursue to learn task-specific prompts and propose a Language-to-Vision adapter to enhance the pixel-class correspondence.
+
+Learning Task-Specific Prompts. The original generator function of CLIP outputs hand-crafted prompts using the predefined template, e.g., "a photo of a [CLS]". However, the performance is highly sensitive to the form of the template [29, 55], which may be sub-optimal when transferring to heterogeneous downstream tasks. Hence, we follow CoOp [55] to use learnable textual contexts in
+
+Table 3: Results of single-task baselines and multi-task models with ResNet-50 backbone. SS and DA means semantic segmentation and drivable area segmentation. - indicates inapplicable.
+
+| Setting | Method | mIoU (SS) | mIoU (DA) | mAP | AP50 | AP75 |
| Full | MaskFormer [5] | 57.1 | - | - | - | - |
| MaskFormer [5] | - | 83.9 | - | - | - |
| Sparse R-CNN [38] | - | - | 29.4 | 55.8 | 26.4 |
| Self-training [12] | 61.8 | 84.4 | 30.1 | 56.6 | 27.6 |
| LV-Adapter (Ours) | 63.1 | 84.9 | 31.1 | 58.2 | 28.4 |
| Disjoint-balance | MaskFormer [5] | 57.1 | - | - | - | - |
| MaskFormer [5] | - | 78.1 | - | - | - |
| Sparse R-CNN [38] | - | - | 18.6 | 37.8 | 15.6 |
| Self-training [12] | 59.4 | 80.3 | 22.4 | 44.1 | 19.6 |
| LV-Adapter (Ours) | 61.8 | 80.6 | 24.6 | 47.4 | 21.9 |
| Disjoint-normal | MaskFormer [5] | 57.1 | - | - | - | - |
| MaskFormer [5] | - | 82.0 | - | - | - |
| Sparse R-CNN [38] | - | - | 20.9 | 41.9 | 17.8 |
| Self-training [12] | 60.3 | 83.1 | 24.9 | 48.1 | 22.2 |
| LV-Adapter (Ours) | 62.2 | 83.7 | 26.4 | 50.5 | 23.7 |
+
+prompting for each task. In spite of the inconsistent output formats of the three tasks (4-D box v.s. dense output), they both need to determine the category of boxes or pixels, and we incorporate the class names of each task in prompting. The task-specific prompting can be formulated as follows:
+
+$$
+\tilde {\mathcal {T}} _ {e, i} = \mathrm {L} 2 \_ \text {N O R M} (\mathrm {T E} ([ \mathbf {v} ^ {t}, \mathbf {n} _ {i} ]), \tag {4}
+$$
+
+where $\mathbf{n}_i$ refers to the embeddings of the class name belonging to a specific task, and $\mathbf{v}^t$ is the task-specific learnable contexts and the superscript indicates the task type.
+
+Enhancing Pixel-Class Correspondence. To align the textural features and the dense FPN features, we propose a Language-to-Vision Adapter to incorporate the language priors into the visual features. Formally, we denote the last feature map of $P_{5}$ as $\mathbf{z}_5 \in \mathbb{R}^{H_5 W_5 \times C}$ , and we aim to learn an adapter function $\mathcal{A}_{L \to V}$ to generate language-aware contexts for downstream tasks. We utilize the cross-attention mechanism in Transformer decoder [43] for Language-to-Vision adaptation:
+
+$$
+\mathcal {A} _ {L \rightarrow V} \left(\tilde {\mathcal {T}} _ {e}, \mathbf {z} _ {5}\right) = \operatorname {T r a n s D e c o d e r} \left(q = \mathbf {z} _ {5}, k = \tilde {\mathcal {T}} _ {e}, v = \hat {\mathcal {T}} _ {e}\right), \tag {5}
+$$
+
+where the $q, k, v$ stands for query, key, and value. A single linear fully connected layer is used to adjust the channel number of $\hat{\mathcal{T}}_e$ and we omit it in Equation 5 for simplicity. We denote the output of Equation 5 as $\tilde{\mathbf{z}}_5 \in \mathbb{R}^{H_5 W_5 \times C}$ . After adaptation, we simply substitute $\mathbf{z}_5$ with $\tilde{\mathbf{z}}_5$ to inject linguistic knowledge into the high-level features of FPN and leave the task-specific head design unchanged. We follow the same paradigm described in Section 4.1 when incorporating LV-Adapter: only the adapter module (i.e., LV-Adapter and FPN) is tuned during the adaptation stage. Moreover, we freeze the weights of the CLIP text encoder throughout the paper to preserve the language priors. We verify the efficacy of our LV-Adapter and disentangle the effect of different modules ablation in Section 5.3.
+
+# 5 Experiments
+
+# 5.1 Experiment Settings
+
+In BDD100K, 70k training images are labeled for both object detection and drivable area segmentation, and only 7k training images are labeled for semantic segmentation. These two sets are not disjoint and about 3k images have complete annotations for all three tasks. As is described in [12], data annotation is one of the biggest challenges of training a multi-task model. In real-world scenarios, it is unrealistic to obtain complete types of annotations for all input images, especially in the traffic scene where fine-grained annotations are required. In this paper, we are interested in the performance of multi-task learning with different quantities of annotations. Thus, we mainly consider three scenarios that correspond to three different levels of annotation scarcity, namely, Disjoint-normal, Disjoint-balance,
+
+and Full setting. We mainly work under the Disjoint-normal setting where the annotations of each task are disjoint, and the number of labeled images for each task is in decreasing order as follows: drivable area segmentation (20k), object detection (10k), semantic segmentation (7k). We provide the details of these three settings in the Appendix.
+
+Implementation Details. The training epoch is fixed as 36, syncBN [28] is on, the learning rate at the fine-tuning stage is $2.5 \times 10^{-5}$ , and weight decay is $1 \times 10^{-4}$ . The image scale is $1280 \times$ (720, 600). No other data augmentation is used. We adopt the AdamW [27] optimizer. The warmup iteration is 1000 and the warmup factor is 0.01. For LV-Adapter, the learnable prompts are prepended to the class, and the length of prompts is 16. During the adaptation stage, the learning rate is set to $2.5 \times 10^{-4}$ . The layer of transformer decoder in Equation 5 is 3. All experiments are conducted on servers with 8 Nvidia V100 GPU (32GB) cards and Intel Xeon Platinum 8168 CPU (2.70GHz).
+
+# 5.2 Main Results
+
+We present the results of our proposed paradigm in Table 2. The adapt and finetune epochs of the proposed paradigm in Table 2 are set as 6 and 30 respectively. As can be seen, with the conventional pretrain-finetune paradigm, the performances of the state-of-the-art self-supervised methods are unstable, especially in semantic segmentation and drivable area segmentation. For example, MoCo-v2 only achieves $10.3\mathrm{mIoU}$ on semantic segmentation. In contrast, under the pretrain-adapt-finetune paradigm, MoCo-v2 improves by a large margin in semantic segmentation $(+50.9$ in mIoU). Notably, MoCo-v1/v2 and DenseCL obtain an absolute improvement by over $40\%$ mIoU in semantic segmentation. The results demonstrate that the pretrain-adapt-finetune paradigm significantly improves the overall performance across different types of pretrained models. We also implement experiments with popular convolutional heads, i.e., Faster R-CNN [32] and Semantic FCN [18], as in Appendix D.2. Results show that architecture is a core reason for the degradation. Moreover, we further showcase the efficiency of this paradigm in Section 5.3. We compare the results of our LV-Adapter to single-task baselines and the self-training baseline using the ImageNet pretrained model under three settings in Table 3. It demonstrates that LV-Adapter performs better on all metrics. Therefore, we conclude that the language-guided pretrain-adapt-finetune paradigm can effectively reduce the gap between the pre-training and fine-tuning stage by incorporating the linguistic knowledge to visual features.
+
+# 5.3 Ablation Study
+
+Module design. We compare the performance of different module designs in Table 4 using the pre-trained weights from CLIP. Row #1 refers to the performance of self-training with the pretrain-finetune paradigm using the pretrained weights of the CLIP image encoder. Row #2-#5 refer to the performance of the pretrain-adapt-finetune paradigm and row #3-#5 reuse the pretrained weights of CLIP text encoder. The adapt and finetune epochs for the pretrain-adapt-finetune paradigm are fixed as 1 and 5. The Prompt column refers to naive prompting without alignment between visual and textual features [31]: we compute class-specific textual features by prompting the CLIP text encoder (Equation 4) and compute the class activation maps by computing dot product between the textual features and $\mathbf{z}_5$ after normalization, and the output maps are concatenated to $\mathbf{z}_5$ and a $1\times 1$ convolution layer is used to reduce the number of channel. The V2L column refers to the post-model module in [31], where the image context is used to prompt the language model and language-compatible class activation maps are concatenated back to $\mathbf{z}_5$ . In comparison, our Language-to-Vision Adapter (L2V column) directly incorporates linguistic knowledge into visual features and does not rely on dense activation maps and is thus more lightweight. As can be seen, when retrieving knowledge from pretrained text encoder via continuous prompt, the model improves in semantic segmentation by $0.3\mathrm{mIoU}$ (#2 vs #3). When we adopt the Vision-to-Language Adapter to update the text features, the performance degrades slightly in semantic segmentation (#3 vs #4). In contrast, our proposed LV-Adapter can better extract prior knowledge from CLIP and achieve the best results (+0.4 and +0.2 in mIoU in semantic segmentation and drivable area segmentation respectively).
+
+Number of epochs of the adapt and finetune stage. We compare different configurations of adapt and finetune epochs in Table 5. When adapting with fewer epochs and fixing full epochs as 36, the performance improves gradually and the best configuration is 1 epoch for adapt and 35 epochs for finetune. Since we freeze the backbone and randomly initialized heads during the adapt stage, the number of trainable parameters is moderate. We can also see that with fixed finetune epochs, more
+
+Table 4: Ablation study of the components of our proposed LV-Adapter.
+
+| # | Prompt | V2L | L2V | mIoU (SS) | mIoU (DA) |
| 1 | X | X | X | 54.5 | 74.1 |
| 2 | X | X | X | 61.5 | 83.5 |
| 3 | ✓ | X | X | 61.8 | 83.5 |
| 4 | ✓ | ✓ | X | 61.3 | 83.6 |
| 5 | ✓ | X | ✓ | 62.2 | 83.7 |
+
+Table 5: Comparison of different configurations of adapt and finetune epochs.
+
+| Adapt | Finetune | mIoU (SS) | mIoU (DA) | mAP |
| 12 | 24 | 59.5 | 82.9 | 25.8 |
| 6 | 30 | 61.0 | 83.4 | 26.3 |
| 1 | 35 | 61.5 | 83.5 | 26.4 |
| 6 | 35 | 61.3 | 83.5 | 26.5 |
| 12 | 35 | 61.9 | 83.5 | 26.6 |
+
+adapt epochs have little impact on the results. We hypothesize that fewer adapt stage is enough for the training paradigm since there are few training parameters (only the adapter) during the adapt stage. For a fair comparison with the baseline whose full epochs are 36, we fix the adapt and finetune epochs as 1 and 35 respectively.
+
+# 6 Conclusion
+
+In this paper, we present the first effort on revealing the degradation of state-of-the-art self-supervised models under the multi-task learning scenario in autonomous driving. To reduce the gap between the pre-training and fine-tuning stage, we propose a simple yet highly efficient pretrain-adapt-finetune paradigm, which boosts the performances of different self-supervised pretrained models by a large margin without increasing the overall training overhead. We further utilize the vision-language pre-training model CLIP as a complement to our proposed paradigm and propose LV-Adapter, which incorporates linguistic knowledge into visual features via learning task-specific prompts in a novel fashion. Extensive experiments showcase that (1) the adapt stage is the key to mitigate the deficiency of the dominating pretrain-finetune paradigm in multi-task learning, and (2) the language priors encoded by CLIP are of general benefits for multiple downstream tasks.
+
+# Acknowledgements
+
+We gratefully acknowledge the support of MindSpore2, CANN (Computer Architecture for Neural Networks) and Ascend AI Processor used for this research.
+
+# References
+
+[1] T. B. Brown, B. Mann, N. Ryder, M. Subbiah, J. Kaplan, P. Dhariwal, A. Neelakantan, P. Shyam, G. Sastry, A. Askell, S. Agarwal, A. Herbert-Voss, G. Krueger, T. Henighan, R. Child, A. Ramesh, D. M. Ziegler, J. Wu, C. Winter, C. Hesse, M. Chen, E. Sigler, M. Litwin, S. Gray, B. Chess, J. Clark, C. Berner, S. McCandlish, A. Radford, I. Sutskever, and D. Amodei. Language models are few-shot learners. In Advances in Neural Information Processing Systems (NeurIPS), volume 33, pages 1877–1901, 2020.
+[2] M. Caron, I. Misra, J. Mairal, P. Goyal, P. Bojanowski, and A. Joulin. Unsupervised learning of visual features by contrasting cluster assignments. Advances in Neural Information Processing Systems (NeurIPS), 33:9912-9924, 2020.
+[3] T. Chen, S. Kornblith, M. Norouzi, and G. Hinton. A simple framework for contrastive learning of visual representations. In International Conference on Machine Learning (ICML), pages 1597-1607, 2020.
+[4] X. Chen, H. Fan, R. Girshick, and K. He. Improved baselines with momentum contrastive learning. arXiv:2003.04297, 2020.
+[5] B. Cheng, A. Schwing, and A. Kirillov. Per-pixel classification is not all you need for semantic segmentation. Advances in Neural Information Processing Systems (NeurIPS), 34, 2021.
+[6] M. Crawshaw. Multi-task learning with deep neural networks: A survey. arXiv preprint arXiv:2009.09796, 2020.
+[7] J. Devlin, M.-W. Chang, K. Lee, and K. Toutanova. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805, 2018.
+
+[8] D. Eigen and R. Fergus. Predicting depth, surface normals and semantic labels with a common multi-scale convolutional architecture. In Proceedings of the IEEE International Conference on Computer Vision (ICCV), pages 2650-2658, 2015.
+[9] C. Fifty, E. Amid, Z. Zhao, T. Yu, R. Anil, and C. Finn. Efficiently identifying task groupings for multi-task learning. Advances in Neural Information Processing Systems (NeurIPS), 34, 2021.
+[10] P. Gao, S. Geng, R. Zhang, T. Ma, R. Fang, Y. Zhang, H. Li, and Y. Qiao. Clip-adapter: Better vision-language models with feature adapters. arXiv preprint arXiv:2110.04544, 2021.
+[11] T. Gao, A. Fisch, and D. Chen. Making pre-trained language models better few-shot learners. In Association for Computational Linguistics (ACL), 2021.
+[12] G. Ghiasi, B. Zoph, E. D. Cubuk, Q. V. Le, and T.-Y. Lin. Multi-task self-training for learning general representations. In Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV), pages 8856-8865, 2021.
+[13] R. B. Girshick. Fast r-cnn. pages 1440-1448, 2015.
+[14] J.-B. Grill, F. Strub, F. Altché, C. Tallec, P. Richemond, E. Buchatskaya, C. Doersch, B. Avila Pires, Z. Guo, M. Gheshlaghi Azar, B. Piot, k. kavukcuoglu, R. Munos, and M. Valko. Bootstrap your own latent: a new approach to self-supervised learning. Advances in Neural Information Processing Systems (NeurIPS), 33:21271-21284, 2020.
+[15] K. He, H. Fan, Y. Wu, S. Xie, and R. Girshick. Momentum contrast for unsupervised visual representation learning. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 9729-9738, 2020.
+[16] K. He, R. B. Girshick, and P. Dollar. Rethinking imagenet pre-training. Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV), pages 4917-4926, 2019.
+[17] K. He, X. Zhang, S. Ren, and J. Sun. Deep residual learning for image recognition. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 770-778, 2016.
+[18] A. Kirillov, K. He, R. Girshick, C. Rother, and P. Dollar. Panoptic segmentation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 9404-9413, 2019.
+[19] I. Kokkinos. Ethernet: Training a 'universal' convolutional neural network for low-, mid-, and high-level vision using diverse datasets and limited memory. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 6129-6138, 2017.
+[20] B. Lester, R. Al-Rfou, and N. Constant. The power of scale for parameter-efficient prompt tuning. In Proceedings of the Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 3045-3059, 2021.
+[21] X. L. Li and P. Liang. Prefix-tuning: Optimizing continuous prompts for generation. arXiv preprint arXiv:2101.00190, 2021.
+[22] V. Likhosherstov, A. Arnab, K. Choromanski, M. Lucic, Y. Tay, A. Weller, and M. Dehghani. Polyvit: Co-training vision transformers on images, videos and audio. arXiv preprint arXiv:2111.12993, 2021.
+[23] T.-Y. Lin, P. Dólár, R. Girshick, K. He, B. Hariharan, and S. Belongie. Feature pyramid networks for object detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 936-944, 2017.
+[24] P. Liu, W. Yuan, J. Fu, Z. Jiang, H. Hayashi, and G. Neubig. Pre-train, prompt, and predict: A systematic survey of prompting methods in natural language processing. arXiv preprint arXiv:2107.13586, 2021.
+[25] X. Liu, K. Ji, Y. Fu, Z. Du, Z. Yang, and J. Tang. P-tuning v2: Prompt tuning can be comparable to fine-tuning universally across scales and tasks. arXiv preprint arXiv:2110.07602, 2021.
+[26] X. Liu, Y. Zheng, Z. Du, M. Ding, Y. Qian, Z. Yang, and J. Tang. Gpt understands, too. arXiv preprint arXiv:2103.10385, 2021.
+[27] I. Loshchilov and F. Hutter. Decoupled weight decay regularization. arXiv preprint arXiv:1711.05101, 2017.
+[28] C. Peng, T. Xiao, Z. Li, Y. Jiang, X. Zhang, K. Jia, G. Yu, and J. Sun. Megdet: A large mini-batch object detector. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 6181-6189, 2018.
+
+[29] A. Radford, J. W. Kim, C. Hallacy, A. Ramesh, G. Goh, S. Agarwal, G. Sastry, A. Askell, P. Mishkin, J. Clark, G. Krueger, and I. Sutskever. Learning transferable visual models from natural language supervision. In International Conference on Machine Learning (ICML), pages 8748-8763, 2021.
+[30] M. Raghu, T. Unterthiner, S. Kornblith, C. Zhang, and A. Dosovitskiy. Do vision transformers see like convolutional neural networks? Advances in Neural Information Processing Systems (NeurIPS), 34, 2021.
+[31] Y. Rao, W. Zhao, G. Chen, Y. Tang, Z. Zhu, G. Huang, J. Zhou, and J. Lu. Denseclip: Language-guided dense prediction with context-aware prompting. arXiv preprint arXiv:2112.01518, 2021.
+[32] S. Ren, K. He, R. Girshick, and J. Sun. Faster r-cnn: Towards real-time object detection with region proposal networks. Advances in Neural Information Processing Systems (NeurIPS), 28, 2015.
+[33] O. Russakovsky, J. Deng, H. Su, J. Krause, S. Satheesh, S. Ma, Z. Huang, A. Karpathy, A. Khosla, M. S. Bernstein, A. C. Berg, and L. Fei-Fei. Imagenet large scale visual recognition challenge. International Journal of Computer Vision (IJCV), 115(3):211–252, 2015.
+[34] T. Schick and H. Schütze. It's not just size that matters: Small language models are also few-shot learners. In Proceedings of NAACL, 2021.
+[35] T. Shin, Y. Razeghi, R. L. Logan IV, E. Wallace, and S. Singh. Autoprompt: Eliciting knowledge from language models with automatically generated prompts. arXiv preprint arXiv:2010.15980, 2020.
+[36] T. S. Standley, A. R. Zamir, D. Chen, L. J. Guibas, J. Malik, and S. Savarese. Which tasks should be learned together in multi-task learning? In International Conference on Machine Learning (ICML), pages 9120-9132, 2020.
+[37] F.-K. Sun and C.-I. Lai. Conditioned natural language generation using only unconditioned language model: An exploration. arXiv preprint arXiv:2011.07347, 2020.
+[38] P. Sun, R. Zhang, Y. Jiang, T. Kong, C. Xu, W. Zhan, M. Tomizuka, L. Li, Z. Yuan, C. Wang, and P. Luo. Sparse r-cnn: End-to-end object detection with learnable proposals. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 14454-14463, 2021.
+[39] X. Sun, R. Panda, and R. S. Feris. Adashare: Learning what to share for efficient deep multi-task learning. Advances in Neural Information Processing Systems (NeurIPS), 33:8728-8740, 2020.
+[40] C. Szegedy, W. Zaremba, I. Sutskever, J. Bruna, D. Erhan, I. J. Goodfellow, and R. Fergus. Intriguing properties of neural networks. arXiv preprint arXiv:1312.6199, 2013.
+[41] M. Teichmann, M. Weber, M. Zoellner, R. Cipolla, and R. Urtasun. Multinet: Real-time joint semantic reasoning for autonomous driving. In IEEE Intelligent Vehicles Symposium (IV), pages 1013-1020, 2018.
+[42] A. van den Oord, Y. Li, and O. Vinyals. Representation learning with contrastive predictive coding. arXiv preprint arXiv:1807.03748, 2018.
+[43] A. Vaswani, N. M. Shazeer, N. Parmar, J. Uszkoreit, L. Jones, A. N. Gomez, L. Kaiser, and I. Polosukhin. Attention is all you need. Advances in Neural Information Processing Systems (NeurIPS), 30, 2017.
+[44] X. Wang, R. Zhang, C. Shen, T. Kong, and L. Li. Dense contrastive learning for self-supervised visual pre-training. Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 3023-3032, 2021.
+[45] D. Wu, M. Liao, W. Zhang, and X. Wang. Yolop: You only look once for panoptic driving perception. arXiv preprint arXiv:2108.11250, 2021.
+[46] T. Xiao, Y. Liu, B. Zhou, Y. Jiang, and J. Sun. Unified perceptual parsing for scene understanding. In European Conference on Computer Vision (ECCV), pages 418-434, 2018.
+[47] E. Xie, J. Ding, W. Wang, X. Zhan, H. Xu, Z. Li, and P. Luo. Detco: Unsupervised contrastive learning for object detection. In Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV), pages 8392-8401, 2021.
+[48] Q. Xie, E. H. Hovy, M.-T. Luong, and Q. V. Le. Self-training with noisy student improves imagenet classification. Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 10684-10695, 2020.
+[49] Z. Xie, Y. Lin, Z. Zhang, Y. Cao, S. Lin, and H. Hu. Propagate yourself: Exploring pixel-level consistency for unsupervised visual representation learning. Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 16679-16688, 2021.
+
+[50] Z. Yang, Y. Zhang, J. Yu, J. Cai, and J. Luo. End-to-end multi-modal multi-task vehicle control for self-driving cars with visual perceptions. 24th International Conference on Pattern Recognition (ICPR), pages 2289-2294, 2018.
+[51] Y. Yao, A. Zhang, Z. Zhang, Z. Liu, T.-S. Chua, and M. Sun. Cpt: Colorful prompt tuning for pre-trained vision-language models. arXiv preprint arXiv:2109.11797, 2021.
+[52] F. Yu, H. Chen, X. Wang, W. Xian, Y. Chen, F. Liu, V. Madhavan, and T. Darrell. Bdd100k: A diverse driving dataset for heterogeneous multitask learning. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 2636-2645, 2020.
+[53] Z. Zhong, D. Friedman, and D. Chen. Factual probing is [mask]: Learning vs. learning to recall. arXiv preprint arXiv:2104.05240, 2021.
+[54] C. Zhou, C. C. Loy, and B. Dai. Denseclip: Extract free dense labels from clip. arXiv preprint arXiv:2112.01071, 2021.
+[55] K. Zhou, J. Yang, C. C. Loy, and Z. Liu. Learning to prompt for vision-language models. arXiv preprint arXiv:2109.01134, 2021.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes] See Section Abstract and Introduction.
+(b) Did you describe the limitations of your work? [Yes] See Limitations in Appendix G.
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] See Potential Negative Social Impact in Appendix F.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [No] Code will be released.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Section Experiment Settings and Appendix A.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] Our experiments are quite stable with multiple runs. All results are observed via a fixed seed.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Implementation Details in Section Experiment Setting.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] See Section Reference.
+(b) Did you mention the license of the assets? [No] The dataset used in the paper is publicly released.
+(c) Did you include any new assets either in the supplemental material or as a URL? [No]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [Yes] The dataset used in the paper is publicly released.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes] The dataset used in the paper does not contain personally identifiable information or offensive content.
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/images.zip b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..b7b6e2da26defa878ad4f7c3919b2b9837bb1584
--- /dev/null
+++ b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:44bd2e2c10b3f55dbc643866dd9feb475a61ef34130f57128b71b48f62755e48
+size 448019
diff --git a/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/layout.json b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..aabaf24af4a499f23b99784bd12c73405a55dc09
--- /dev/null
+++ b/effectiveadaptationinmultitaskcotrainingforunifiedautonomousdriving/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:542edef244d595b0570761b5c1e62368c3c2cc2da486265d668ab72fe4fcb3ef
+size 354101
diff --git a/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/ffb85ff0-f8d8-4dfa-aaf8-0e2cd8472349_content_list.json b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/ffb85ff0-f8d8-4dfa-aaf8-0e2cd8472349_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..4dc6bf94bd204c322580de0d9db0bbc870c8f7b2
--- /dev/null
+++ b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/ffb85ff0-f8d8-4dfa-aaf8-0e2cd8472349_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:42a354d0986f42ef5cf8165e455a3bec11dbc874ca61935a2d84ac6e52fcd65e
+size 73088
diff --git a/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/ffb85ff0-f8d8-4dfa-aaf8-0e2cd8472349_model.json b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/ffb85ff0-f8d8-4dfa-aaf8-0e2cd8472349_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..3bad6b1b94e9de8781c0d2f90da03e14937090c4
--- /dev/null
+++ b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/ffb85ff0-f8d8-4dfa-aaf8-0e2cd8472349_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8804f86ff06669d71c9147bb74337e64971e24b184736d85148875c38b6adb79
+size 90746
diff --git a/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/ffb85ff0-f8d8-4dfa-aaf8-0e2cd8472349_origin.pdf b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/ffb85ff0-f8d8-4dfa-aaf8-0e2cd8472349_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..89bf56b8bada740c641a8e55decaba625dec52dd
--- /dev/null
+++ b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/ffb85ff0-f8d8-4dfa-aaf8-0e2cd8472349_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8be20e6d4aa0a6ac488f9686f75e2572e24bc8ccabffcc174927e040d37f62b6
+size 3522940
diff --git a/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/full.md b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..96a01eab368b80d3e2c89d7d4a3389fd443ab059
--- /dev/null
+++ b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/full.md
@@ -0,0 +1,281 @@
+# Effective Backdoor Defense by Exploiting Sensitivity of Poisoned Samples
+
+Weixin Chen $^{1}$ , Baoyuan Wu $^{2*}$ , Haoqian Wang $^{1*}$
+
+$^{1}$ Tsinghua Shenzhen International Graduate School, Tsinghua University
+
+$^{2}$ School of Data Science, Shenzhen Research Institute of Big Data,
+
+The Chinese University of Hong Kong, Shenzhen
+
+chenwx20@mails.tsinghua.edu.cn, wubaoyuan@cuhk.edu.cn,
+
+wanghaoqian@tsinghua.edu.cn
+
+# Abstract
+
+Poisoning-based backdoor attacks are serious threat for training deep models on data from untrustworthy sources. Given a backdoored model, we observe that the feature representations of poisoned samples with trigger are more sensitive to transformations than those of clean samples. It inspires us to design a simple sensitivity metric, called feature consistency towards transformations (FCT), to distinguish poisoned samples from clean samples in the untrustworthy training set. Moreover, we propose two effective backdoor defense methods. Built upon a sample-distinguishment module utilizing the FCT metric, the first method trains a secure model from scratch using a two-stage secure training module. And the second method removes backdoor from a backdoored model with a backdoor removal module which alternatively unlearns the distinguished poisoned samples and relearns the distinguished clean samples. Extensive results on three benchmark datasets demonstrate the superior defense performance against eight types of backdoor attacks, to state-of-the-art backdoor defenses. Codes are available at: https://github.com/SCLBD/Effective_backdoor-defense.
+
+# 1 Introduction
+
+Training deep neural networks (DNNs) often requires a large amount of training data, which is sometimes obtained from a third-party untrustworthy source. However, the untrustworthy data may bring serious security threats. One of the typical threats is the poisoning-based backdoor attack [1], which could inject undesired backdoor—the correlation between trigger(s) and target class(es)—into the model through maliciously poisoning a few training samples. Specifically, as shown in the top left of Fig. 1, each poisoned sample is attached with a trigger (see a small grid patch) at the bottom right corner, and relabeled as a target class. Consequently, the trained backdoored model will predict clean samples very well, but is likely to predict any sample with the trigger to be the target class.
+
+It has been observed in [2] that poisoned samples with triggers are likely to gather together in the feature space of a backdoored model, as shown in the top right of Fig. 1. Note that these poisoned samples contain diverse objects (may be from different source classes), but the information from these objects seems to be ignored by the backdoor model. In other words, the feature representations of poisoned samples are dominated by the triggers, rather than the objects. We conjecture that such a domination is mainly due to the overfitting to the triggers by the backdoor model, since triggers across different poisoned samples are much less diverse than objects. To verify this conjecture, we propose to slightly perturb both poisoned and clean samples, such as
+
+rotation transformation. As shown in the bottom right of Fig. 1, there is no longer gathering of poisoned samples in the feature space, and they are located close to samples of their source classes, i.e., the dominance of triggers over other objects disappears, which verifies the triggers overfitting.
+
+Besides, although the feature representations of clean samples are also affected by transformations, their changes are much smaller than those of poisoned samples. In other words, poisoned samples are more sensitive to transformations than clean samples. It inspires that poisoned samples could be distinguished from clean samples according to the sensitivity to transformations, which is measured by a simple sensitivity metric, called feature consistency towards transformations (FCT). In our experiments, the precision of the distinguished clean and poisoned samples is nearly $100\%$ in most cases, respectively.
+
+
+Figure 1: Poisoned and clean samples from CIFAR-10 [3], and the t-SNE [4] visualization of their feature representations with a backdoored model. As shown in the Union figure, the changes of poisoned samples (from $\cdot$ to $+$ ) are much larger than those of clean samples (from $\cdot$ to $+$ in other colors). Note that we present only three classes for clear illustration.
+
+In this work, we aim to obtain a secure model (i.e., high-performance and without backdoor) based on an untrustworthy training set. To this end, we consider two defense paradigms: one is training a secure model from scratch, while the other is firstly training a backdoorsed model using standard supervised learning, and then removing backdoor from the backdoorsed model. Under paradigm 1, we propose an innovative secure training method, called Distinguishment and Secure Training $(D - ST)$ , which consists of two consecutive modules. The first sample-distinguishment (SD) module splits the whole training set into clean, poisoned and uncertain samples, according to the FCT metric. The second two-stage secure training (ST) module firstly learns the feature extractor via semi-supervised contrastive learning, and then learns the classifier via minimizing a mixed cross-entropy loss. Under paradigm 2, we propose an innovative backdoor removal method, called Distinguishment and Backdoor Removal $(D - BR)$ , which consists of the SD module and a backdoor removal (BR) module. BR module alternatively unlearns the distinguished poisoned samples and learns the distinguished clean samples. Extensive experiments are conducted to verify the superior defense performance of the above two proposed methods, as well as effectiveness of each individual module.
+
+The main contributions of this work are three-folds. (1) We demonstrate the sensitivity of poisoned samples to transformations, which is mainly due to the overfitting to trigger, and propose a simple sensitivity metric to distinguish poisoned samples from clean samples. (2) We propose two effective backdoor defense methods for training a secure model from scratch and removing backdoor from the backdoorsed model, respectively. (3) Extensive experiments on 3 benchmark datasets show the superior performance of the proposed defense methods against 8 widely used backdoor attacks, to 6 state-of-the-art defense methods.
+
+# 2 Related work
+
+Backdoor attack. In poisoning-based backdoor attacks, the attacker attaches a few training samples with trigger(s), and relabel them as target class(es). Existing attacks can be categorized according to a variety of criteria as follows. (1) Size of trigger: Patch-based attacks [1, 5, 6] craft patch-like triggers while in blend-based attacks [7, 8], triggers capture the whole image. (2) Visibility of trigger: Visible attacks [1, 6] design visible but not suspicious triggers while invisible attacks [8, 9, 10] propose invisible and still effective ones. (3) Variability of trigger: Triggers are invariant in sample-agnostic attacks [1, 7, 11] while vary with samples in sample-specific attacks [9, 12]. (4) Label-consistency: If poisoned samples are chosen from samples with target class, then we call these attacks as clean-label attacks [11, 13, 12, 14]. Otherwise, we name them as dirty-label attacks [1, 6, 7, 8]. (5) Number of
+
+
+Figure 2: Framework of two proposed backdoor defense methods for secure training from scratch (paradigm1) and backdoor removal (paradigm2), respectively.
+
+target classes: All2one attacks [1, 6, 7, 8] designate one class as the target class while in all2all attacks [1], poisoned samples are relabeled as the next class. There are also other attacks [15, 16, 17, 18, 19] that require the attacker to control the training process, which are out of scope of this paper. The attack performance of the methods above can be referred to the Backdoorbench [20].
+
+Backdoor defense. In general, there are two types of defense paradigms against poisoning-based backdoor attacks—secure training and backdoor removal. Mainstream defense methods belong to the latter one, which leverage the model properties [21, 22, 23] or the feature space characteristics [24, 5, 25, 26, 27, 28, 29] of a backdoored model, to remove the hidden backdoor. For instance, FP [21] observes that some neurons are activated by poisoned samples while others are by clean samples. AC [24] notices the difference in size between the cluster of clean target samples and that of poisoned samples. So far, there is still few works for the former defense. Secure training attempts to train a secure model from scratch, preventing backdoor inserted during training. The core point lies in how to distinguish poisoned samples from clean samples. The first method DBD [2] uses the loss values, the symmetric cross-entropy loss particularly, to distinguish samples during training while our proposed secure training method, i.e., D-ST, leverages the property that the feature representations of poisoned samples in a backdoored model are more sensitive to transformations than those of clean samples, to distinguish samples in advance of the training.
+
+# 3 Proposed method
+
+# 3.1 Problem formulation
+
+Threat model. In this paper, we consider the threat model of poisoning-based backdoor attacks, where the attacker can manipulate a few samples in the original clean training set $D_{train} = D_c \cup \{(\pmb{x}_i, y_i)\}_{i=1}^{m_p}$ , with $D_c = \{(\pmb{x}_i, y_i)\}_{i=1}^{m_c}$ indicating the unmanipulated subset. For the remaining $m_p$ samples, each sample $\pmb{x}_i \in \mathcal{X}$ is fused with a trigger $\delta$ to form a poisoned sample $\bar{x}_i = \pmb{x}_i \oplus \delta$ with $\oplus$ being the fusion operator. Meanwhile, its label $y_i \in \mathcal{Y}$ is also changed to a target class $t$ . Then, a poisoned training set is constructed, denoted as $\bar{D}_{train} \equiv D_c \cup D_p$ , with $D_p = \{(\bar{x}_i, t)\}_{i=1}^{m_p}$ . When a user downloads $\bar{D}_{train}$ and trains a DNN classifier $g_\theta : \mathcal{X} \to \mathcal{Y}$ based on $\bar{D}_{train}$ using the standard supervised learning algorithm, it may learn a undesired backdoor, i.e., a stable mapping from the trigger $\delta$ to the target class $t$ . Consequently, for any new sample with the trigger $\delta$ , it is likely to be predicted as the target class $t$ . Note that the user does not know which sample is poisoned or clean.
+
+Defense goal. Given the poisoned training set $\bar{D}_{train}$ , the defender aims to obtain a high-performance model $g_{\theta}$ without backdoor, i.e., a secure model. In this work, we consider two different paradigms:
+
+- Paradigm 1: a secure model is directly trained from scratch, as described in Section 3.3.
+- Paradigm 2: a backdoored model is firstly trained using the standard supervised learning, then the backdoor is removed from the backdoored model, as described in Section 3.4.
+
+# 3.2 Sensitivity of poisoned samples
+
+Sensitivity metric. As illustrated in Section 1 and Fig. 1, we have found that the poisoned samples are much more sensitive to transformations than the clean samples in a backdoored model. To accurately measure such a difference, we propose a simple metric, feature consistency towards transformations (FCT). Specifically, given a backdoored model $g_{\theta}$ trained on $\bar{D}_{train}$ with $f_{\theta_e}(\cdot)$ indicating its feature extractor, and a set of transformations $\tau$ (e.g., rotation, scaling, will be specified in experiments), for any sample $x$ (poisoned or clean), the FCT metric is formulated as follows:
+
+$$
+\Delta_ {t r a n s} (\boldsymbol {x}; \tau , f _ {\boldsymbol {\theta} _ {e}}) = \| f _ {\boldsymbol {\theta} _ {e}} (\boldsymbol {x}) - f _ {\boldsymbol {\theta} _ {e}} (\tau (\boldsymbol {x})) \| _ {2} ^ {2}. \tag {1}
+$$
+
+It measures the change of the feature representation due to the transformations $\tau$ . If $\Delta_{trans}(\pmb{x};\tau,f)$ is large, then it means that $\pmb{x}$ is sensitive to $\tau$ , otherwise stable. For clarity, we use $\Delta_{trans}(\pmb{x})$ hereafter.
+
+Sample-distinguishment module. Utilizing FCT, we develop a sample-distinguishment (SD) module. Specifically, we firstly train a backdoored model $g_{\theta}$ based on $\bar{D}_{train}$ using the standard supervised learning algorithm with a few epochs (explained in Appendix A.1). Then, we calculate $\Delta_{trans}(\pmb{x}_i), \forall \pmb{x}_i \in \bar{D}_{train}$ , and plot the histogram. As shown in Fig. 3, where two representative backdoor attacks are evaluated, there is remarkable difference on the distribution between the poisoned and the clean samples in both histograms. It demonstrates that $\Delta_{trans}$ is a good metric to distinguish the poisoned samples from the clean samples in $\bar{D}_{train}$ . Based
+
+
+(a) BadNets
+
+
+(b) Blend
+Figure 3: Distribution of clean and poisoned samples with respect to the FCT metric on CIFAR-10.
+
+on the sensitivity histogram, we set two proportion values $\alpha_{c},\alpha_{p}\in [0,1]$ . The samples with the bottom- $\alpha_{c}$ $\Delta_{trans}$ values are separated to a subset of clean samples $\hat{D}_c$ , while those with the top- $\alpha_{p}$ $\Delta_{trans}$ values are separated into a subset of poisoned samples $\hat{D}_p$ , while the remaining samples are partitioned as an uncertain subset denoted as $\hat{D}_u$ . We have $\bar{D}_{train} = \hat{D}_c\cup \hat{D}_p\cup \hat{D}_u$ . More details are in Algorithm 1 in Appendix A.1
+
+# 3.3 Method for paradigm 1: secure training from scratch
+
+Here, we consider the backdoor defense under paradigm 1. We propose an innovative secure training method, called Distinguishment and Secure Training (D-ST) method. As illustrated in Fig. 2, D-ST consists of the SD module (see above) and a two-stage secure training (ST) module, which is described as follows. Details of the D-ST method are summarized in Algorithm 3 in Appendix A.2..
+
+Stage 1: learning feature extractor via semi-supervised contrastive learning (SS-CTL). Our method is inspired by a recent backdoor defense method called DBD [2], which proposed to learn a good feature extractor $f_{\theta_e}$ based on $\bar{D}_{train}$ using a self-supervised learning algorithm, i.e., contrastive learning (CTL). Consequently, the feature representations of samples with similar appearances will be similar, and poisoned samples with triggers cannot gather together to form the backdoor. Note that all labels have been abandoned in DBD before the extractor learning since there is no way to identify poisoned samples in advance of the learning, leading to the waste of the valuable information contained in clean samples. Fortunately, the proposed SD module could identify some clean samples. Thus, inspired by the supervised contrastive learning (S-CTL) [30], which has shown to learn a feature extractor with better performance than CTL, we propose a novel learning called semi-supervised contrastive learning (SS-CTL), to learn $f_{\theta_e}$ by minimizing the following loss function:
+
+$$
+\begin{array}{l} \mathcal {L} _ {S S - C T L} \left(\boldsymbol {\theta} _ {e}; \bar {D} _ {t r a i n}\right) = \sum \ell_ {C T L} \left(f _ {\boldsymbol {\theta} _ {e}} \left(\tilde {\boldsymbol {x}} _ {\boldsymbol {i}} ^ {(1)}\right), f _ {\boldsymbol {\theta} _ {e}} \left(\tilde {\boldsymbol {x}} _ {\boldsymbol {i}} ^ {(2)}\right)\right) \tag {2} \\ (\boldsymbol {x} _ {i}, y _ {i}) \in \hat {D} _ {p} \cup \hat {D} _ {u} \\ { + } { \sum } { \ell _ { S - C T L } \big ( f _ { \boldsymbol { \theta } _ { e } } ( \tilde { \boldsymbol { x } } _ { i } ^ { ( 1 ) } ) , f _ { \boldsymbol { \theta } _ { e } } ( \tilde { \boldsymbol { x } } _ { i } ^ { ( 2 ) } ) , f _ { \boldsymbol { \theta } _ { e } } ( \tilde { \boldsymbol { x } } _ { j } ^ { ( 1 ) } ) , f _ { \boldsymbol { \theta } _ { e } } ( \tilde { \boldsymbol { x } } _ { j } ^ { ( 2 ) } ) ; y _ { i } , y _ { j } \big ) , } \\ \left\{\left(\boldsymbol {x} _ {i}, y _ {i}\right), \left(\boldsymbol {x} _ {j}, y _ {j}\right) \right\} \subset \hat {D} _ {c} \\ \end{array}
+$$
+
+where the contrastive loss $\ell_{CTL}$ encourages the two augmented versions $\tilde{\pmb{x}}_i^{(1)},\tilde{\pmb{x}}_i^{(2)}$ (e.g., cropping, details are introduced in Appendix C) of a sample $\pmb {x}_i$ to be close in the feature space, while the
+
+supervised contrastive loss $\ell_{S - CTL}$ additionally encourages the feature representations of two clean augmented samples from the same class to be close. In this work, we instantiate $\ell_{CTL}$ as the contrastive loss defined in [31] and $\ell_{S - CTL}$ as the SupCon loss defined in [30].
+
+Stage 2: learning classifier via minimizing the mixed cross-entropy loss. Given the feature extractor $f_{\theta_e}$ learned in stage 1, we then learn the classifier $h_{\theta_c}$ by minimizing the following mixed cross-entropy (MCE) loss:
+
+$$
+\mathcal {L} _ {M C E} \left(\boldsymbol {\theta} _ {c}; \hat {D} _ {c}, \hat {D} _ {p}\right) = \frac {- 1}{| \hat {D} _ {c} |} \sum_ {(\boldsymbol {x}, \boldsymbol {y}) \in \hat {D} _ {c}} \log \left[ h _ {\boldsymbol {\theta} _ {c}} \left(f _ {\boldsymbol {\theta} _ {e}} (\boldsymbol {x})\right) \right] _ {\boldsymbol {y}} + \frac {\lambda_ {p}}{| \hat {D} _ {p} |} \cdot \sum_ {(\boldsymbol {x}, \boldsymbol {y}) \in \hat {D} _ {p}} \log \left[ h _ {\boldsymbol {\theta} _ {c}} \left(f _ {\boldsymbol {\theta} _ {e}} (\boldsymbol {x})\right) \right] _ {\boldsymbol {y}}, \tag {3}
+$$
+
+where the first term is the standard cross-entropy loss defined based on the distinguished clean samples $\hat{D}_c$ , while the second term is the negative cross-entropy loss defined based on the distinguished poisoned samples $\hat{D}_p$ , which is used to eliminate the effect of poisoned samples. $\lambda_p \in \mathbb{R}^+$ is a trade-off parameter between two losses.
+
+# 3.4 Method for paradigm 2: backdoor removal
+
+Here we consider the backdoor defense under paradigm 2. We propose an innovative backdoor removal method, called Distinguishment and Backdoor Removal (D-BR) method. As illustrated in Fig. 2, D-BR consists of the SD module (see Section 3.2) and a backdoor removal (BR) module. The BR module aims to remove the backdoor from the backdoored model, i.e., the backdoor is no longer activated by the trigger, while keeping the high performance on clean samples. To this end, the BR module implements an iterative learning algorithm, which consists of two alternating steps, i.e., unlearning and relearning. The D-BR method is summarized in Algorithm 4 in Appendix A.3.
+
+Unlearning. This step aims to eliminate the effect of the trigger, through unlearning [32] the poisoned samples in $\hat{D}_p$ distinguished by the SD module, as follows:
+
+$$
+\mathcal {L} _ {\text {u n l e a r n}} (\boldsymbol {\theta}; \hat {D} _ {p}) = \frac {1}{| \hat {D} _ {p} |} \sum_ {(\boldsymbol {x}, y) \in \hat {D} _ {p}} \log [ g _ {\boldsymbol {\theta}} (\boldsymbol {x}) ] _ {y}. \tag {4}
+$$
+
+Relearning. After conducting the above unlearning step for one epoch, although the effect of poisoned samples is somewhat eliminated, in experiments we find that the performance on clean samples is also degraded to some extent. Thus, we want to relearn the mapping from the clean objects to the ground-truth classes based on clean samples in $\hat{D}_c$ distinguished by the SD module, as follows:
+
+$$
+\mathcal {L} _ {\text {r e l e a r n}} (\boldsymbol {\theta}; \hat {D} _ {c}) = \frac {1}{| \hat {D} _ {c} |} \sum_ {(\boldsymbol {x}, y) \in \hat {D} _ {c}} - \log [ g _ {\boldsymbol {\theta}} (\boldsymbol {x}) ] _ {y}. \tag {5}
+$$
+
+Note that both unlearning and relearning are run for one epoch in each round.
+
+# 4 Experiments
+
+# 4.1 Experimental settings
+
+Attack configurations. According to the taxonomy described in Section 2, we consider 8 typical poisoning-based backdoor attacks by choosing at least one method from each category, including: BadNets [1] using two attack types (BadNets-all2one, BadNets-all2all), Trojan backdoor attack [6] (Trojan), Blend backdoor attack using two different patterns (Blend-Signal, Blend-Kitty) [7], Clean-label backdoor (CL) [13], Sinusoidal signal backdoor attack (SIG) [11], Sample-specific backdoor attack (SSBA) [9]. We evaluate all attacks on 3 benchmark datasets, CIFAR-10 [3], CIFAR-100 [3] and an ImageNet subset [33, 9], with ResNet-18 [34] as the base model. Poisoning rate is set to $10\%$ in all attacks. Due to the space limit, more implementations details about attacks can be found in Appendix C.3.
+
+Defense configurations. We first compare the proposed D-ST method with DBD [2]. Since studies with this secure-training paradigm are limited, we additionally add 2 baselines for comparison which
+
+are detailed in Section 4.2. We then compare the proposed D-BR method with 5 state-of-the-art methods with the same backdoor-removal paradigm: the standard fine-tuning FT, ANP [22], NAD [35], MCR [36] and ABL [37]. For methods requiring extra clean data, $1\%$ of the clean training samples are provided. Other configurations are set as clarified in the original papers. In summary, we consider 6 state-of-the-art defense methods and 2 additional baselines. More implementations details can be found in Appendix C.4. For our proposed methods, we use $\alpha_{c} = 20\%$ , $\alpha_{p} = 5\%$ and $\tau = \text{rotate + affine}$ in all experiments. Other details can be seen in Appendix C.5.
+
+Evaluation metrics. We evaluate the defense performance adopting two commonly used metrics: accuracy on clean samples (ACC) and attack success rate (ASR), i.e., accuracy of predicting poisoned samples as the target label.
+
+# 4.2 Experimental results
+
+Effectiveness of D-ST method. We first consider paradigm 1—secure training from scratch. Performance of different defense methods against various attacks on CIFAR-10 and CIFAR-100 is demonstrated in Table 1. An ideal defense method is supposed to increase ACC while keep ASR as low as possible. Thus, a larger ACC-ASR indicates a better method. We mark the best result in boldface. Note that we only report results on successful attacks where ASR is higher than $85\%$ .
+
+Table 1: Comparisons of the D-ST method with 3 secure-training defense methods $(\%)$
+
+| Dataset ↓ | Defense → Attack ↓ | Baseline1 | Baseline2 | DBD | D-ST |
| ACC | ASR | ACC | ASR | ACC | ASR | ACC | ASR |
| CIFAR-10 | BN-all2one | 83.54 | 2.60 | 91.32 | 99.91 | 92.75 | 100.00 | 92.77 | 0.03 |
| BN-all2all | 83.95 | 2.72 | 91.59 | 57.39 | 92.95 | 75.21 | 89.22 | 2.05 |
| Trojan | 83.77 | 5.24 | 93.63 | 99.98 | 92.81 | 100.00 | 93.72 | 0.00 |
| Blend-Strip | 85.36 | 99.93 | 94.19 | 100.00 | 94.21 | 99.98 | 93.59 | 0.00 |
| Blend-Kitty | 85.03 | 99.99 | 94.31 | 100.00 | 93.32 | 100.00 | 91.82 | 0.00 |
| SIG | 85.14 | 99.02 | 94.37 | 99.93 | 94.37 | 99.71 | 90.07 | 0.00 |
| CL | 85.79 | 10.76 | 94.58 | 98.87 | 94.32 | 99.87 | 90.46 | 6.40 |
| Avg | 84.65 | 45.75 | 93.43 | 93.73 | 93.53 | 96.40 | 91.66 | 1.21 |
| CIFAR-100 | BN-all2one | 54.48 | 10.41 | 67.62 | 100.00 | 69.08 | 100.00 | 68.43 | 0.12 |
| Trojan | 56.17 | 12.76 | 71.01 | 100.00 | 72.18 | 99.99 | 68.04 | 0.08 |
| Blend-Strip | 58.01 | 99.91 | 72.47 | 99.99 | 71.29 | 99.99 | 67.63 | 0.00 |
| Blend-Kitty | 57.21 | 99.99 | 73.36 | 99.99 | 72.43 | 100.00 | 67.06 | 0.00 |
| Avg | 56.47 | 55.77 | 71.12 | 100.00 | 71.24 | 99.99 | 67.79 | 0.05 |
+
+DBD fails in most attacks on CIFAR-10 and CIFAR-100, probably due to the failure of the symmetric cross-entropy to distinguish samples. By comparison, the good performance reached by D-ST illustrates the accurate distinguishment from the FCT-based SD module. We additionally introduce two feasible baselines without requiring special knowledge. Baseline1 first uses SimCLR [31] to train the feature extractor and then trains the classifier on the poisoned dataset with standard supervised learning. By comparison, Baseline2 leverages S-CTL [30] to train the feature extractor. We focus on discussing the effect of different extractor-training algorithms on defense performance. More discussions are in the later experiments. Baseline 1 reveals that training extractor without labels may result in low ASR ( $<5\% / <20\%$ in some cases on CIFAR-10/CIFAR-100), but will sacrifice ACC definitely (84.65%/56.47% on average). While Baseline 2 demonstrates that training extractor with all labels guarantees high ACC (93.43%/71.12% on average), but also brings high ASR (93.73%/100% on average). By contrast, results of D-ST illustrate the effectiveness of ST module in training the feature extractor in a secure way since ACC is high (91.66%/67.79% on average) and ASR (1.21%/0.05% on average) is extremely low.
+
+Effectiveness of D-BR method. Then, we consider paradigm 2—backdoor removal. Defense performance of different defense methods against various attacks on CIFAR-10 and CIFAR-100 is demonstrated in Table 2. Results on ImageNet is shown in Table 5 in Appendix D.
+
+Results on CIFAR-10. We discover that except for FT and MCR, other selected methods generally reduce ACC markedly. Additionally, they have two common disadvantages. (1) They can not take effect on all attacks. For example, ANP can defend against Trojan and Blend attacks $(\mathrm{ASR} < 1\%)$ while fails in clean-label attacks, i.e. SIG and CL $(\mathrm{ASR} > 10\%)$ . (2) There exists at least one attack that can disable the methods $(\mathrm{ASR} > 50\%)$ . By contrast, the proposed D-BR method overcomes these drawbacks. It not only maintains ACC as large as that of backdoored model, but also reduces ASR to less than $1\%$ on all attacks, verifying the effectiveness of the BR module and the high precision of the distinguishment conducted by the SD module.
+
+Table 2: Comparisons of the D-BR method with 5 backdoor-removal defense methods on CIFAR-10 and CIFAR-100 $(\%)$ . 'Backdoored' refers to the backdoored model. * denotes methods which require a few $(1\%)$ clean training samples.
+
+| Dataset ↓ | Defense → Attack ↓ | Backdoored | FT* | ANP* | NAD* | MCR* | ABL | D-BR |
| ACC | ASR | ACC | ASR | ACC | ASR | ACC | ASR | ACC | ASR | ACC | ASR | ACC | ASR |
| CIFAR-10 | BN-all2one | 91.64 | 100.00 | 88.99 | 66.79 | 90.03 | 10.54 | 84.46 | 2.13 | 94.21 | 8.29 | 89.36 | 0.19 | 92.83 | 0.40 |
| BN-all2all | 92.79 | 88.01 | 90.31 | 4.96 | 86.04 | 1.47 | 84.97 | 1.71 | 92.17 | 2.96 | 79.91 | 78.16 | 92.61 | 0.56 |
| Trojan | 91.91 | 100.00 | 89.86 | 100.00 | 90.89 | 0.81 | 83.29 | 5.04 | 93.90 | 2.58 | 90.18 | 0.23 | 92.21 | 0.76 |
| Blend-Strip | 92.09 | 99.97 | 89.91 | 93.50 | 88.33 | 0.04 | 83.09 | 13.30 | 91.77 | 17.96 | 58.46 | 0.22 | 92.40 | 0.06 |
| Blend-Kitty | 92.69 | 99.99 | 90.47 | 99.31 | 84.07 | 0.01 | 84.54 | 28.96 | 94.42 | 7.49 | 79.20 | 2.27 | 92.11 | 0.14 |
| SIG | 92.88 | 99.69 | 90.81 | 99.87 | 82.43 | 76.32 | 81.00 | 64.72 | 91.82 | 99.04 | 79.94 | 98.84 | 92.73 | 0.24 |
| CL | 93.20 | 93.34 | 90.03 | 77.44 | 72.57 | 10.90 | 84.46 | 2.66 | 92.13 | 72.01 | 84.39 | 0.31 | 92.08 | 0.00 |
| Avg | 92.46 | 97.29 | 90.05 | 77.41 | 84.91 | 14.30 | 83.69 | 16.93 | 92.92 | 30.05 | 80.21 | 25.75 | 92.42 | 0.31 |
| CIFAR-100 | BN-all2one | 71.23 | 99.13 | 70.81 | 66.28 | 65.42 | 0.00 | 69.03 | 11.41 | 73.38 | 0.27 | 66.47 | 0.02 | 72.58 | 0.25 |
| Trojan | 75.75 | 100.00 | 74.21 | 99.94 | 64.52 | 0.03 | 72.11 | 92.21 | 74.51 | 0.12 | 68.12 | 0.00 | 74.52 | 0.00 |
| Blend-Strip | 75.54 | 99.99 | 73.36 | 99.65 | 67.38 | 0.00 | 71.18 | 95.78 | 73.37 | 0.07 | 49.13 | 0.00 | 74.35 | 0.00 |
| Blend-Kitty | 75.18 | 99.97 | 72.93 | 99.96 | 69.03 | 0.00 | 71.73 | 99.93 | 73.93 | 20.60 | 47.05 | 0.00 | 72.00 | 0.01 |
| Avg | 74.43 | 99.77 | 72.83 | 91.46 | 66.59 | 0.01 | 71.01 | 74.83 | 73.80 | 5.27 | 57.69 | 0.01 | 73.36 | 0.07 |
+
+Results on CIFAR-100. Although FT and NAD have a relatively high ACC ( $>68\%$ ), they fail to reduce ASR (91.46% and 74.83% on average). While ANP and ABL can decrease ASR to less than 0.1%, they sacrifice too much ACC (66.59% and 57.69% on average). Among the selected methods, MCR performs the best (ACC = 73.80% on average, $\mathrm{ASR} < 0.5\%$ in three cases), but it still fails to defend against the Blend-Kitty attack (ASR = 20.60%). Note that MCR requires extra clean data. In contrast, D-BR keeps ACC higher than 72%, while reduces ASR to almost 0% without any extra clean data.
+
+# 4.3 Ablation studies
+
+Effectiveness of the SD module. Here, we aim to study the effectiveness of the SD module. Specifically, we will show how our proposed FCT metric, performs better than other metrics, under the backdoor-removal paradigm for illustration. To this end, we select three existing metrics for comparison. Spectral signatures [5] specifies the metric as the correlation with the top singular vector of the covariance matrix of feature representations. DBD [2] assigns symmetric cross-entropy loss as the metric. The metric used in ABL [37] is loss value applied with local gradient ascent. The metric values of clean samples are smaller than those of poisoned samples according to the former two metrics, while larger for the third metric. For fair comparison, we uniformly set $\alpha_{c} = 20\%$ , $\alpha_{p} = 5\%$ . We first apply the metric-replaced SD module on the poisoned training set, and then conduct the BR module based on the distinguished samples. Results are shown in Fig. 4.
+
+
+(a) BadNets
+
+
+(b) Blend
+Figure 4: Test ACC and Test ASR of four metric-replaced D-BR methods on the poisoned CIFAR-10.
+
+
+(c) SIG
+
+
+(d) CL
+
+The height of the blue bar above the orange bar suggests how well the metric could distinguish. As shown in Fig. 4 (a,b,d), orange bars are all higher than blue bars for Spectral signatures and DBD, indicating metrics of which fail to distinguish in BadNets, Blend and CL attacks. In contrast, the metric of ABL is reliable since ABL performs well in most cases except for Blend attack where ASR is $24.72\%$ . By comparison, our proposed FCT metric could distinguish samples stably well, resulting in extremely low ASR $(< 0.5\%)$ on all attacks. We attribute the success to that FCT exploits the sensitivity of poisoned samples, which is mainly due to the overfitting to trigger by the backdoored model that exists in all backdoor attacks we have evaluated in this paper.
+
+Effectiveness of the BR module. Here, we focus on studying the effectiveness of the BR module. Specifically, we aim to show how the iterative learning algorithm consisting of unlearning and relearning performs better than the pure unlearning adopted by [37] or pure relearning. To this
+
+end, we first conduct the SD module, and then apply different learning algorithms. For the three algorithms, we run 20 epochs on CIFAR-10 and record the variations of Test ACC and Test ASR which are illustrated as Fig. 5.
+
+
+
+
+(a) BadNets
+
+
+
+
+(b) Blend
+
+
+
+
+(c) SIG
+Figure 5: Test ACC(top) and Test ASR(bottom) of three learning algorithms on poisoned CIFAR-10.
+
+
+
+
+(d) CL
+
+Although pure unlearning (red lines) effectively decreases ASR, it could hardly maintain ACC, showing a downward trend. The results indicate a strict requirement for choosing the number of unlearning epochs. On the contrary, pure relearning (green lines) can keep ACC stably high, but it takes tiny effect in reducing ASR. By contrast, unlearning + relearning (blue lines) combines their advantages and successfully diminishes ASR while maintains ACC. ACC and ASR steadily converge to high and low values, respectively, validating the effectiveness and the stability of the BR module.
+
+Effectiveness of the ST module. Here, we aim to study the effectiveness of the ST Module. Backdoor can be injected during training the feature extractor $f_{\theta_e}$ and the classifier $h_{\theta_c}$ . The final defense performance of $g_{\theta}$ depends on how well $f_{\theta_e}$ and $h_{\theta_c}$ inhibit backdoor.
+
+Firstly, we want to show how SS-CTL performs better than CTL or S-CTL in training a secure feature extractor $f_{\theta_e}$ . To this end, we train $f_{\theta_e}$ with different learning algorithms and then uniformly leverage $\mathcal{L}_{MCE}$ to train $h_{\theta_e}$ . Training $f_{\theta_e}$ with CTL, as shown in the first row in Table 3, guarantees low ASR, but the low ACC turns into a tradeoff. Note that the low ASR is the joint effort of CTL and $\mathcal{L}_{MCE}$ . And the usage of CTL does not indicate low ASR definitely, but it indeed reduces the possibility of backdoor injection in $f_{\theta_e}$ . The second row illustrates that S-CTL could bring high ACC and the potentially high ASR, as seen in the SIG and CL attacks. Since all labels (including poisoned) are used in this scenario, ACC is reasonably high. Besides, backdoor is already injected into $f_{\theta_e}$ . But due to the inhibition effect of $\mathcal{L}_{MCE}$ , the ASR of $g_{\theta}$ may not be high. For example, in dirty-label attacks, i.e. BadNets, Trojan and Blend attacks, ASR is almost 0%. While in clean-label attacks, i.e. SIG and CL attacks, $\mathcal{L}_{MCE}$ can not withstand the backdoor injected in $f_{\theta_e}$ , so the ASR is almost 100%. Hence, in order to establish a reliable defense module, $f_{\theta_e}$ should be trained in a more secure way. In comparison, the third row demonstrates the superior defense performance of SS-CTL, illustrating that the ST module securely bridges genuinely clean intra-class samples together which are distinguished by the SD module.
+
+Table 3: Performance with ${f}_{{\theta }_{e}}$ trained with three learning algorithms on the poisoned CIFAR-10.
+
+| Attack → fθe ↓ | BN-all2one | BN-all2all | Trojan | Blend-Signal | Blend-Kitty | SIG | CL |
| ACC | ASR | ACC | ASR | ACC | ASR | ACC | ASR | ACC | ASR | ACC | ASR | ACC | ASR |
| CTL | 85.63 | 1.52 | 83.02 | 1.65 | 85.03 | 1.32 | 85.12 | 0.00 | 83.49 | 0.00 | 83.10 | 0.00 | 83.77 | 4.88 |
| S-CTL | 92.98 | 0.00 | 93.73 | 0.73 | 93.80 | 0.00 | 94.09 | 0.00 | 94.18 | 0.00 | 94.51 | 99.77 | 94.67 | 98.34 |
| SS-CTL | 92.77 | 0.03 | 89.22 | 2.05 | 93.72 | 0.00 | 93.59 | 0.00 | 91.82 | 0.00 | 90.07 | 0.00 | 90.46 | 6.40 |
+
+Secondly, we explore how $\mathcal{L}_{MCE}$ affects the defense performance of $h_{\theta_c}$ . For clarity, we denote $\mathcal{L}_1 \equiv \frac{-1}{|\hat{D}_c|} \sum_{(\boldsymbol{x},y) \in \hat{D}_c} \log[h_{\theta_c}(f_{\theta_e}(\boldsymbol{x}))]_y$ and $\mathcal{L}_2 \equiv \frac{1}{|\hat{D}_p|} \cdot \sum_{(\boldsymbol{x},y) \in \hat{D}_p} \log[h_{\theta_c}(f_{\theta_e}(\boldsymbol{x}))]_y$ . We have $\mathcal{L}_{MCE} = \mathcal{L}_1 + \lambda_p \mathcal{L}_2$ . Generally, if knowing clean samples, the defender will train $h_{\theta_c}$ with $\mathcal{L}_1$ . So here, we aim to show how our proposed $\mathcal{L}_2$ and the trade-off parameter $\lambda_p$ affect $h_{\theta_c}$ . To this end, we first fix $f_{\theta_e}$ learned by SS-CTL and then apply $\mathcal{L}_{MCE}$ with $\lambda_p = 0, 0.001, 0.01, 0.1, 1$ on $h_{\theta_c}$ . Results are shown in Fig. 6. In the previous experiments, we adopt $\lambda_p = 0.001$ .
+
+The comparison between $\lambda_p = 0$ and $\lambda_p \neq 0$ in the right figure illustrates that $\mathcal{L}_2$ can effectively reduce ASR. When comparing different $\lambda_p \neq 0$ in the left figure, we discover that as $\lambda_p$ increases, there is a trend of decrease in ACC. We infer that since $\mathcal{L}_2$ drops faster than $\mathcal{L}_1$ , namely unlearning is faster than relearning, adding weights to $\mathcal{L}_2$ makes $h_{\theta_c}$ focus on unlearning instead of relearning, leading to the low ACC. Therefore, we conclude that $\mathcal{L}_2$ helps to inhibit backdoor in
+
+
+Figure 6: Test ACC (left) and Test ASR (right) under various $\lambda_{p}$ on the poisoned CIFAR-10.
+
+$h_{\theta_c}$ , but its weight should not be too large. $\lambda_p = 0.001$ is considered to be an appropriate choice.
+
+In summary, we have empirically validated the effectiveness of each individual module, and shown the flexibility of our method to combine with other existing modules.
+
+Appendix. Due to the space limit, more results and analysis will be presented in Appendix. The overall structure of the Appendix is listed as follows.
+
+- Appendix A: more algorithmic details and analysis on the proposed method.
+- Appendix B: more details on semi-supervised contrastive learning (SS-CTL).
+- Appendix C: more implementation details.
+- Appendix D: results on ImageNet.
+- Appendix E: performance with different data transformations $\tau$ .
+- Appendix F: performance with different proportion values $\alpha_{c},\alpha_{p}$
+- Appendix G: performance with different poisoning rates.
+- Appendix H: performance with different model architectures and feature dimensionalities.
+- Appendix I: complexities of two proposed methods.
+
+# 5 Conclusions
+
+In this paper, we reveal the sensitivity of poisoned samples to transformations and propose a sensitivity metric, called FCT. Besides, we propose three modules—the SD module to distinguish between clean and poisoned samples, the ST module to train a secure model from scratch and the BR module to remove backdoor—which constitute two defense methods, i.e.D-ST and D-BR, to defend under two different defense paradigms. Extensive experiments have demonstrated the effectiveness of each individual module and also the proposed defense methods.
+
+# 6 Broader impact
+
+Poisoning-based backdoor attacks are severe threats to the learning paradigm of learning a DNN model based on the training set from some untrustworthy sources. This work reveals the sensitivity of poisoned samples in the backdoored model, which will help people to better understand the inner mechanism of backdoor attacks. The proposed two effective defense methods can not only significantly mitigate the threat of existing poisoning based backdoor attacks, but also serve as the new baseline for developing more advanced attack methods in future.
+
+# 7 Acknowledgments and disclosure of funding
+
+Baoyuan Wu is supported by the NSFC Fund under grant No.62076213, Shenzhen Science and Technology Program under grant No.RCYX20210609103057050, No.GXWD20201231105722002-20200901175001001, and No.ZDSYS20211021111415025. Haoqian Wang is supported by the NSFC Fund under grant No.61831014, Shenzhen Science and Technology Program under grant No.CJGJZD20200617102601004 and No.JSGG20210802153150005.
+
+# References
+
+[1] Tianyu Gu, Kang Liu, Brendan Dolan-Gavitt, and Siddharth Garg. Badnets: Evaluating backdooring attacks on deep neural networks. IEEE Access, 7:47230-47244, 2019.
+[2] Kunzhe Huang, Yiming Li, Baoyuan Wu, Zhan Qin, and Kui Ren. Backdoor defense via decoupling the training process. In ICLR, 2022.
+[3] Alex Krizhevsky, Geoffrey Hinton, et al. Learning multiple layers of features from tiny images. Technical Report, University of Toronto, 2009.
+[4] Laurens Van der Maaten and Geoffrey Hinton. Visualizing data using t-sne. Journal of machine learning research, 2008.
+[5] Brandon Tran, Jerry Li, and Aleksander Madry. Spectral signatures in backdoor attacks. In NIPS, 2018.
+[6] Yingqi Liu, Shiqing Ma, Yousra Aafer, Wen-Chuan Lee, Juan Zhai, Weihang Wang, and Xiangyu Zhang. Trojaning attack on neural networks. In NDSS, 2017.
+[7] Xinyun Chen, Chang Liu, Bo Li, Kimberly Lu, and Dawn Song. Targeted backdoor attacks on deep learning systems using data poisoning. arXiv preprint arXiv:1712.05526, 2017.
+[8] Yunfei Liu, Xingjun Ma, James Bailey, and Feng Lu. Reflection backdoor: A natural backdoor attack on deep neural networks. In ECCV, 2020.
+[9] Yuezun Li, Yiming Li, Baoyuan Wu, Longkang Li, Ran He, and Siwei Lyu. Invisible backdoor attack with sample-specific triggers. In ICCV, 2021.
+[10] Eugene Bagdasaryan and Vitaly Shmatikov. Blind backdoors in deep learning models. In USENIX, 2021.
+[11] Mauro Barni, Kassem Kallas, and Benedetta Tondi. A new backdoor attack in cnns by training set corruption without label poisoning. In ICIP, 2019.
+[12] Aniruddha Saha, Akshayvarun Subramanya, and Hamed Piriavash. Hidden trigger backdoor attacks. In AAAI, 2020.
+[13] Alexander Turner, Dimitris Tsipras, and Aleksander Madry. Label-consistent backdoor attacks. arXiv preprint arXiv:1912.02771, 2019.
+[14] Shihao Zhao, Xingjun Ma, Xiang Zheng, James Bailey, Jingjing Chen, and Yu-Gang Jiang. Clean-label backdoor attacks on video recognition models. In CVPR, 2020.
+[15] Tuan Anh Nguyen and Anh Tuan Tran. Wanet - imperceptible warping-based backdoor attack. In ICLR, 2021.
+[16] Tuan Anh Nguyen and Anh Tran. Input-aware dynamic backdoor attack. In NIPS, 2020.
+[17] Junyu Lin, Lei Xu, Yingqi Liu, and Xiangyu Zhang. Composite backdoor attack for deep neural network by mixing existing benign features. In CCS, 2020.
+[18] Ahmed Salem, Rui Wen, Michael Backes, Shiqing Ma, and Yang Zhang. Dynamic backdoor attacks against machine learning models. arXiv preprint arXiv:2003.03675, 2020.
+[19] Ilia Shumailov, Zakhar Shumaylov, Dmitry Kazhdan, Yiren Zhao, Nicolas Papernot, Murat A Erdogdu, and Ross J Anderson. Manipulating sgd with data ordering attacks. In NIPS, 2021.
+[20] Baoyuan Wu, Hongrui Chen, Mingda Zhang, Zihao Zhu, Shaokui Wei, Danni Yuan, Chao Shen, and Hongyuan Zha. Backdoorbench: A comprehensive benchmark of backdoor learning. arXiv preprint arXiv:2206.12654, 2022.
+[21] Kang Liu, Brendan Dolan-Gavitt, and Siddharth Garg. Fine-pruning: Defending against backdooring attacks on deep neural networks. In RAID, 2018.
+[22] Dongxian Wu and Yisen Wang. Adversarial neuron pruning purifies backdoored deep models. In NIPS, 2021.
+[23] Kota Yoshida and Takeshi Fujino. Disabling backdoor and identifying poison data by using knowledge distillation in backdoor attacks on deep neural networks. In ACM Workshop, 2020.
+
+[24] Bryant Chen, Wilka Carvalho, Nathalie Baracaldo, Heiko Ludwig, Benjamin Edwards, Taesung Lee, Ian M. Molloy, and Biplav Srivastava. Detecting backdoor attacks on deep neural networks by activation clustering. In AAAI, 2019.
+[25] Ezekiel Soremekun, Sakshi Udeshi, and Sudipta Chattopadhyay. Exposing backdoors in robust machine learning models. arXiv preprint arXiv:2003.00865, 2020.
+[26] Alvin Chan and Yew-Soon Ong. Poison as a cure: Detecting & neutralizing variable-sized backdoor attacks in deep neural networks. arXiv preprint arXiv:1911.08040, 2019.
+[27] Huili Chen, Cheng Fu, Jishen Zhao, and Farinaz Koushanfar. Deepinspect: A black-box trojan detection and mitigation framework for deep neural networks. In IJCAI, 2019.
+[28] Haripriya Harikumar, Vuong Le, Santu Rana, Sourangshu Bhattacharya, Sunil Gupta, and Svetha Venkatesh. Scalable backdoor detection in neural networks. In ECML, 2020.
+[29] Zhen Xiang, David J. Miller, and George Kesidis. Detection of backdoors in trained classifiers without access to the training set. IEEE TNL, 2022.
+[30] Prannay Khosla, Piotr Teterwak, Chen Wang, Aaron Sarna, Yonglong Tian, Phillip Isola, Aaron Maschinot, Ce Liu, and Dilip Krishnan. Supervised contrastive learning. In NIPS, 2020.
+[31] Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey E. Hinton. A simple framework for contrastive learning of visual representations. In ICML, 2020.
+[32] Lucas Bourtoule, Varun Chandrasekaran, Christopher A Choquette-Choo, Hengrui Jia, Adelin Travers, Baiwu Zhang, David Lie, and Nicolas Papernot. Machine unlearning. In IEEE S&P, 2021.
+[33] Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. Imagenet: A large-scale hierarchical image database. In CVPR, 2009.
+[34] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In CVPR, 2016.
+[35] Yige Li, Xixiang Lyu, Nodens Koren, Lingjuan Lyu, Bo Li, and Xingjun Ma. Neural attention distillation: Erasing backdoor triggers from deep neural networks. In ICLR, 2021.
+[36] Pu Zhao, Pin-Yu Chen, Payel Das, Karthikeyan Natesan Ramamurthy, and Xue Lin. Bridging mode connectivity in loss landscapes and adversarial robustness. In ICLR, 2020.
+[37] Yige Li, Xixiang Lyu, Nodens Koren, Lingjuan Lyu, Bo Li, and Xingjun Ma. Anti-backdoor learning: Training clean models on poisoned data. In NIPS, 2021.
+[38] Karen Simonyan and Andrew Zisserman. Very deep convolutional networks for large-scale image recognition. In ICLR, 2015.
+[39] Gao Huang, Zhuang Liu, Laurens Van Der Maaten, and Kilian Q Weinberger. Densely connected convolutional networks. In CVPR, 2017.
\ No newline at end of file
diff --git a/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/images.zip b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..3f9bcbcabb1bd986f95ade3844e4af0e58de52d2
--- /dev/null
+++ b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fa7e104a7fa2991a5fde8ff041a3e6ab54ae9706bb52c95c14303842f7a60bda
+size 459403
diff --git a/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/layout.json b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..7fb82f1ceec3aa20d3701950cdad5e80ac4db186
--- /dev/null
+++ b/effectivebackdoordefensebyexploitingsensitivityofpoisonedsamples/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:97a0c47806e4d6dd3b32a1b54ad183129c7fe743a097b19621a9b7bad835113c
+size 409991
diff --git a/effectivedimensioninbanditproblemsundercensorship/2cedd5dd-818f-4ade-a4e6-f8cd173a19ef_content_list.json b/effectivedimensioninbanditproblemsundercensorship/2cedd5dd-818f-4ade-a4e6-f8cd173a19ef_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..969375ce3d399d7680fbcc7b6c7aff9be83e744d
--- /dev/null
+++ b/effectivedimensioninbanditproblemsundercensorship/2cedd5dd-818f-4ade-a4e6-f8cd173a19ef_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1c97bb7b40c36e70330cd21d30ce837a3f82f4ff619a5eacd43ea282a43f0597
+size 91909
diff --git a/effectivedimensioninbanditproblemsundercensorship/2cedd5dd-818f-4ade-a4e6-f8cd173a19ef_model.json b/effectivedimensioninbanditproblemsundercensorship/2cedd5dd-818f-4ade-a4e6-f8cd173a19ef_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..151c391f3e853f023c510627f9fc2a99bbb49a42
--- /dev/null
+++ b/effectivedimensioninbanditproblemsundercensorship/2cedd5dd-818f-4ade-a4e6-f8cd173a19ef_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a4e8d9d29d02dc67e1e5acac84f233df3c2fafebbb2c01547fcedf31c7778723
+size 111243
diff --git a/effectivedimensioninbanditproblemsundercensorship/2cedd5dd-818f-4ade-a4e6-f8cd173a19ef_origin.pdf b/effectivedimensioninbanditproblemsundercensorship/2cedd5dd-818f-4ade-a4e6-f8cd173a19ef_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..aba328f9b525cd4cdc9db50f28a3da552dd051f4
--- /dev/null
+++ b/effectivedimensioninbanditproblemsundercensorship/2cedd5dd-818f-4ade-a4e6-f8cd173a19ef_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:34389459a66ff47d1a4d3695513576276ffde45f3066e6209f56bec9feaa97bf
+size 694973
diff --git a/effectivedimensioninbanditproblemsundercensorship/full.md b/effectivedimensioninbanditproblemsundercensorship/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..5f286dd5b1213c49a99c42722403325ecba47624
--- /dev/null
+++ b/effectivedimensioninbanditproblemsundercensorship/full.md
@@ -0,0 +1,420 @@
+# Effective Dimension in Bandit Problems under Censorship
+
+Gauthier Guinet *
+
+AWS AI Labs guinetgg@amazon.com
+
+Saurabh Amin†
+
+MIT
+amins@mit.edu
+
+Patrick Jaillet
+
+MIT
+jaillet@mit.edu
+
+# Abstract
+
+In this paper, we study both multi-armed and contextual bandit problems in censored environments. Our goal is to estimate the performance loss due to censorship in the context of classical algorithms designed for uncensored environments. Our main contributions include the introduction of a broad class of censorship models and their analysis in terms of the effective dimension of the problem - a natural measure of its underlying statistical complexity and main driver of the regret bound. In particular, the effective dimension allows us to maintain the structure of the original problem at first order, while embedding it in a bigger space, and thus naturally leads to results analogous to uncensored settings. Our analysis involves a continuous generalization of the Elliptical Potential Inequality, which we believe is of independent interest. We also discover an interesting property of decision-making under censorship: a transient phase during which initial misspecification of censorship is self-corrected at an extra cost; followed by a stationary phase that reflects the inherent slowdown of learning governed by the effective dimension. Our results are useful for applications of sequential decision-making models where the feedback received depends on strategic uncertainty (e.g., agents' willingness to follow a recommendation) and/or random uncertainty (e.g., loss or delay in arrival of information).
+
+# 1 Introduction
+
+Bandit problems are prototypical models of sequential decision-making under uncertainty. They are widely studied due to their applications in recommender systems, online advertising, medical treatment assignment, revenue management, network routing and control [26, 39]. Our work is motivated by settings in which the feedback received by the decision-maker in each round of decision is censored by a stochastic process that depends on the current action as well as past history of feedbacks and actions. For instance, in typical missing data problems, the decision-maker needs to deal with frequent losses of information (or delays in arrival of information) due to exogenous failures such as faulty and/or unreliable communication. Missing observations in dynamical interactions with the environment are a common concern in diverse fields ranging from operations management to health sciences to physical sciences [45, 20, 29]. In other settings, such as AI-driven platforms for health alerts, route guidance, and product recommendations [7, 46], the reception of feedback depends on whether or not the decision (or recommendation) is adopted by strategic agents (e.g. patients, customers or drivers) with private valuations. Thus, from the platform's viewpoint, the adoption behavior of heterogeneous agents can be regarded as a stochastic censorship process.
+
+In static environments, the bias induced by the presence of randomly missing information has been thoroughly studied [29, 33]. However, in online settings, the dynamics of learning and acting are inherently coupled: since censorship mediates current information of the environment, it impacts the outcome of data-driven decision process; this in turn conditions the future decisions and future censored feedback, creating a complex and endogenous joint temporal dependency. Our work contributes to the analysis of such phenomena for a broad classes of decision and censorship models. Importantly, it is the first normative inquiry of how censorship impacts the statistical complexity of bandit problems. We develop an analysis approach that is useful for both estimating the performance loss due to censorship and refining the classical algorithms designed for uncensored environments.
+
+# 1.1 Related Work
+
+Within the extensive bandits literature, well-surveyed in [26, 39], our work is most closely related to stochastic delayed bandits. Initially, this line of work focused on the joint evolution of actions and information in settings where the reception of the latter is delayed [15]. Of particular interest is the packet loss model recently introduced in [24], which provides the regret bound $\mathcal{O}\left(\frac{1}{p} R_T\right)$ where $R_{T}$ is the uncensored regret and $p$ the censorship probability. Analogous results have been shown in the context of Combinatorial Multi-Armed Bandits with probabilistically triggered arms; see for example, [11] and [43]. Our work provides a systematic approach to study more general censorship models, and sheds light on how the impact of coupled feedback and censorship realizations on the expected regret can be evaluated in terms of the effective dimension of the problem.
+
+Importantly, we also tackle the contextual bandit problems, where relatively few results are available on the regret under missing or censored feedback. A notable exception is the work of [42], who focus on a different information structure and obtain a scaling of $1 / p$ (see Remark 4.4). A related contribution by [2] provides both a potential-based analysis of the Upper Confidence Bound algorithm (UCB) for multi-armed bandits and an algorithmic variant leveraging the Kaplan-Meier estimator, although their censorship setting is different than ours. In particular, our results are applicable to settings when delay is significantly large (possibly infinite). This is in contrast to prior results on bandits with delayed information structure which assume either that the delay is constant, upper bounded, has a finite mean, or simply provide regret guarantees that are linear in the cumulative delays up to time $T$ [15, 22, 30, 47, 34]. Under such assumptions on delay, one usually gets a second order additive dependency of the regret in terms of delay parameters, which practically says that delay is benign for bandits. On the other hand, we show that censorship leads to a first order multiplicative dependency on regret and we provide a complete characterization of this dependency for a wide range of bandits and censorship models.
+
+Moreover, the abovementioned works primarily focus on modifying well-known bandit algorithms to account for delays, or propose new delay-robust algorithms which may be difficult to implement in practice; a notable exception includes [44] but it focuses on Thompson Sampling. In our work, we instead focus on estimating the performance loss due to censorship and derive insights on the behavior of well-known UCB class of algorithms [27, 13, 1]. These algorithms are widely used in practice; moreover, their theoretical study has been shown to be useful for analysis of broader class of algorithms (notably Thompson Sampling [3, 36] and Information-Directed Sampling [37, 23]).
+
+On a somewhat related note, the literature on non-stochastic multi-armed bandit problems with delays [32, 9, 21] also tackles multiplicative dependency, although in a different setting than ours. Another related line of work is Partial Monitoring [6, 25] which deals with generic categorization of learnability, rather than a fine-grained analysis of dimensionality in relation to censorship, which is our current focus.
+
+Our work contributes to the Generalized Linear Contextual Bandits literature [16, 28] in two ways: firstly, through the use of these models in a sequential decision-making framework on which the impact of censorship is assessed in Sec. 4. Secondly, by showing that our multi-threshold censorship model $\mathcal{MT}$ induces, at first order, a non-linear structure that closely mirrors such models. Our results provide new tools to study this structure. It is useful to note that the notion of effective dimension has been well-studied in the statistical learning and kernels literature [40, 41] (where it is defined for a Gram matrix $K_{n}$ and regularization $\lambda$ as $d_{\mathrm{eff}}^n (\lambda) = \operatorname {tr}(K_n(K_n + \lambda \mathbb{I}_d)^{-1}))$ . Our work shows that an analogous quantity governs the regret bound of bandit problems in censored settings.
+
+Finally, there is a rich literature on classical missing and censored data problems [29, 33]. Although conditional on the choice of a given action the missing data/censorship process we study is an instance of missing-completely-at-random (MCAR), the online action generating process adds a significant difficulty to the problem: whereas MCAR is typically studied under a well-defined distributional assumption (e.g. i.i.d. generation of action), our problem needs to deal with adaptive (hence non i.i.d.) data generation process with respect to the filtration of past information. In particular, the structure of missing data set results from strong endogenous dependencies with past realization of the censorship (see Sec. 2).
+
+# 1.2 Summary of Results
+
+In Sec. 3, we consider Multi-Armed Bandit (MAB) models and prove that the regret scales as $\tilde{\mathcal{O}}(d_{\text{eff}}\sqrt{T})$ (Thm. 3.1), where $d_{\text{eff}}$ is the effective dimension with value $\sum_{a \in [d]} \frac{1}{p_a}$ . In doing so, we recover and generalize related results from [24, 11] to more complex regularized settings and noise models. In particular, we prove that the effective dimension results from characterizing the so-called censored cumulative potential $\mathbb{V}_{\alpha}$ . Interestingly, we also show that the adaptive nature of censorship on $\mathbb{V}_{\alpha}$ plays only a second order role (Prop. 3.7), that is, impact of censorship can be treated in an offline manner at first order.
+
+Importantly, our study of MAB under censorship instantiates an analysis framework which extends to Linear Contextual Bandits (LCB) (Sec. 4). Our main result provides that regret is still governed by the effective dimension, but now with a dependency of $\tilde{\mathcal{O}} (\sigma \sqrt{d\cdot d_{eff}}\sqrt{T})$ (Thm. 4.1). To the best of our knowledge, these regret bounds provide the first theoretical characterization in LCB with censorship, and contribute to the literature by evaluating the impact of censorship on the performance of UCB-type algorithms. Our second main contribution is identifying the effective dimension for a broad class of multi-threshold models $\mathcal{MT}$ as well as a precise understanding of the dynamic behavior induced by these models (Thm. 4.6). In particular, we find that censorship introduces a two-phase behavior: a transient phase during which the initial censoring misspecification is self-corrected at an additional cost; followed by a stationary phase that reflects the inherent slowdown of learning governed by the effective dimension. In extending our analysis from MAB to LCB, we also develop a continuous generalization of the widely used Elliptical Potential Inequality (Prop. 4.3), which we believe is also of independent interest. Finally, our results (Thm. 3.1 and Prop. 3.2 for MAB and Thm. 4.1 for LCB) suggest that the UCB class of algorithms is indeed a reliable method for stochastic bandits problems under censorship.
+
+# 2 Problem Setup and Background
+
+Bandit Model: We successively consider stochastic multi-armed bandits (Sec. 3) and Linear Contextual Bandits (LCB) (Sec. 4) in censored environments. In both settings, at each round $t \leq T$ , the agent observes an action set $\mathcal{A}_t \subset \mathcal{A}$ . She then selects an action $a_t \in \mathcal{A}_t$ (i.e., an arm) to which a noisy feedback $r(a_t) + \epsilon_t$ is associated, where $r(a_t)$ is a bounded reward and $\epsilon_t$ is an i.i.d. sub-Gaussian noise of pseudo-variance $\sigma^2$ . For action $a$ , the sub-optimality gap at time $t$ is denoted $\Delta_t(a) \triangleq \max_{\tilde{a} \in \mathcal{A}_t} r(\tilde{a}) - r(a)$ , and the maximal gap $\Delta_{\text{max}} \triangleq \max_{a,t} \Delta_t(a)$ . We now recall the specifics of each model:
+
+- MAB: There is a finite number of actions $d$ , enumerated as $\mathcal{A} \triangleq [d]$ , each having a scalar reward $\theta_{a}^{\star}$ . Arms are independent: playing one arm gives no information about the others.
+- LCB: The action set $\mathcal{A}_t$ is a subset of the unit ball $\mathbb{B}_d$ , possibly infinite. Unless explicitly mentioned, the reward is assumed to be linear with respect to a latent unknown vector $\theta^{\star} \in \mathbb{R}^{d}$ , i.e. $r(a) = \langle a, \theta^{\star} \rangle$ . Non-stochastic contexts are modeled by the fact that $\mathcal{A}_t$ is drawn by an oblivious adversary. Here one does not need to rely on the typical i.i.d assumption on their generating process [47, 16].
+
+Information Structure: In the classical uncensored setting, the noisy feedback is immediately observed post-decision and utilized to make decisions in the next round. We introduce the following censorship model: an independent Bernoulli random variable of parameter $p(a_{t})$ denoted as $x_{a_t}$ is drawn after each decision $a_{t}$ and the feedback is observed, i.e., realized, if and only if $x_{a_t} = 1$ ; else the feedback is said to be censored. We recover the uncensored setting when $p(a)\equiv 1$ . Henceforth,
+
+in both finite and linear settings, the Bernoulli parameter corresponding to the censorship probability depends on the action chosen i.e. our model allows the censorship to be heterogeneous across actions. Given that the action chosen at time $t$ is a random variable, $p(a_{t})$ refers to a random variable as well.
+
+# Algorithm 1: Generic UCB
+
+Input: Total time $T$ , Regularization $\lambda$ , Precision $\delta$ for $t = 1, \dots, T$ do
+
+Provide reward estimator $\tilde{r}_t^\lambda$ verifying w.p.
+
+$$
+1 - \delta :
+$$
+
+$$
+\forall a \in \mathcal {A} _ {t}, r (a) \leq \tilde {r} _ {t} ^ {\lambda} (a);
+$$
+
+Play action $a_{t} = \operatorname{argmax}_{a\in A_{t}}\tilde{r}_{t}^{\lambda}(a)$
+
+if $(a_{t},r(a_{t}) + \epsilon_{t})$ is realized i.e. $x_{a_t} = 1$ then
+
+Update $\tilde{r}_t^\lambda$
+
+end
+
+end
+
+Algorithms: To study the impact of censorship on bandit problems, we consider the class of high-probability index algorithms based on the optimism under uncertainty principle, commonly referred as UCB-algorithms. Following [23], Algorithm 1 summarizes the generic UCB design framework. We detail in App.A the specific instances of UCB for MAB (resp. LCB) used in Sec.3 (resp. Sec.4). Moreover, this family of algorithms strongly relies on regularized reward estimators $\tilde{r}_t^{\lambda}$ , where the regularizer is mostly used to prevent an artificial cold-start exploratory phase.
+
+Performance Criterion: The frequentist performance of the agent is measured by the notion of pseudo regret, i.e., the difference between the algorithm's cumulative reward and the best total reward. More formally, we introduce for any policy $\pi \in \Pi$ :
+
+$$
+R (T, \pi) = \sum_ {t = 1} ^ {T} \max _ {a \in \mathcal {A} _ {t}} r (a) - \sum_ {t = 1} ^ {T} r (a _ {t}) = \sum_ {t = 1} ^ {T} \Delta_ {t} (a _ {t}).
+$$
+
+We aim to provide guarantees on $\mathbb{E}[R(T,\pi)]$ with respect to the number of rounds $T$ and quantities that govern the complexity of the problem (for example number of arms, ambient dimension $d$ , parameters of censorship model or smoothness properties of the reward $r$ ). Here, the expectation is with respect to the noise induced by the feedback, the censorship and a possibly randomized policy.
+
+# 2.1 Notations
+
+Transpose of a vector $u$ is denoted by $u^{\top}$ , classical Euclidean inner product by $\langle .,.\rangle$ and trace operator by $\operatorname{Tr}$ . For positive semi-definite matrix $\boldsymbol{\Sigma} \in \mathbb{R}^{d \times d}$ and for any vector $u \in \mathbb{R}^d$ , notation $\|u\|_{\Sigma}$ refers to $\sqrt{u^{\top}\Sigma u}$ . We use notation $\mathbb{I}_d$ to denote the $d \times d$ identity matrix. $\mathbb{B}_d$ is the unit ball in $\mathbb{R}^d$ . $[n]$ is the set of integers $\{1,2,\dots,n\}$ . For a given function $f$ , we note $f^{(i)}$ the $i^{th}$ derivative of $f$ . To avoid confusion with the dimension $d$ , we use $\partial x$ instead of $dx$ to denote an infinitesimal increase of $x$ . We use the asymptotic notations $\sim$ , $\mathcal{O}$ , $\Theta$ and $\tilde{\mathcal{O}}$ ( $\mathcal{O}$ when log factors are removed). Finally, for an event $\mathcal{H}$ , we use $\neg \mathcal{H}$ to denote its complement.
+
+# 3 Multi-Armed Bandits
+
+# 3.1 Effective Dimension and Regret Bounds
+
+The main result of this section is that censorship effectively enlarges the dimension of the problem. We define the effective dimension as $d_{\text{eff}} \triangleq \sum_{a \in [d]} \frac{1}{p_a}$ and our result (Thm. 3.1) shows that, at first order, the regret is guaranteed to be the same as the uncensored problem with $d_{\text{eff}}$ arms instead of $d$ .
+
+Theorem 3.1. Under censorship, the UCB algorithm with regularization $\lambda$ has an instance-independent expected regret of:
+
+$$
+\mathbb {E} \left[ R (T, \pi_ {U C B}) \right] \leq \tilde {\mathcal {O}} \left(\sigma \sqrt {d _ {e f f} T}\right).
+$$
+
+Furthermore, we obtain analogous regret guarantees for instance-dependent cases where, at first order, the uncensored dimension $\sum_{a\neq a^{\star}}\frac{\sigma^{2}}{\Delta_{a}}$ enlarges to $\sum_{a\neq a^{\star}}\frac{\sigma^{2}}{p_a\Delta_a}$ :
+
+Proposition 3.2. For a fixed action set $\mathcal{A}_t\equiv [d]$ and for a-priori known action gap $\Delta_{a}\triangleq \max_{\tilde{a}}\theta_{\tilde{a}}^{\star} - \theta_{a}^{\star}$ , the UCB algorithm with regularization $\lambda$ has the instance-dependent expected regret:
+
+$$
+\mathbb {E} [ R (T, \pi_ {U C B}) ] \leq \mathcal {O} \Big (\log (T) \sum_ {a \neq a ^ {\star}} \frac {1}{p _ {a}} \max \left(\frac {\sigma^ {2}}{\Delta_ {a}}, \Delta_ {a}\right) \Big).
+$$
+
+On one hand, a preliminary understanding of censorship posits an increase of the average "regret per information gain" [23] (as it takes longer on average to get the same amount of information) but does not change the underlying complexity of the problem. One the other hand, our results (Thm. 3.1 and Prop. 3.2) postulate that the censored problem is equivalent at first order to a higher dimensional problem but explored with the same regret per information gain.
+
+The abovementioned results extend to a-priori known heteroskedasticity (see Rem. 3 and 4 in App. B). For this general setting, the effective dimension for instance-independent (resp. dependent) case is given by $\sum_{a} \frac{\sigma_{a}^{2}}{p_{a}}$ (resp. $\sum_{a \neq a^{\star}} \frac{\sigma_{a}^{2}}{p_{a} \Delta_{a}}$ ), where $\sigma_{a}^{2}$ is the variance proxy of arm $a$ . Although the scaling in $\sum_{a} \frac{1}{\Delta_{a} p_{a}}$ was already mentioned in [24] for unregularized setting with homogeneous variance $\sigma^{2}$ and proven to be optimal, our results generalize these findings.
+
+# 3.2 Cumulative Censored Potential
+
+We now provide a proof sketch of Thm. 3.1 and in doing so, we instantiate an analysis framework that will be extended in Sec. 4. This proof consists in the successive elimination of the noise induced by the feedback and censorship. This leads to regret guarantees on a resulting deterministic quantity by characterizing worst-case learning conditions. The first step of the proof is a variant of the classical reduction of the UCB regret to another quantity we refer to as the expected cumulative censored potential. Before stating it, we define at the end of a round $t \in [T]$ , the random number of times an arm $a$ has been pulled as $\tau_{a}(t) \triangleq \sum_{l=1}^{t} \mathbf{1}\{a_{l} = a\}$ . Similarly, the number of times an action $a$ has been realized at the end of round $t$ is denoted $N_{a}(t) \triangleq \sum_{l=1}^{t} \mathbf{1}\{a_{l} = a, x_{a_{l}} = 1\}$ . We then have:
+
+Lemma 3.3. Given an uniform regularization of $\lambda >0$ , the UCB algorithm verifies:
+
+$$
+\mathbb {E} [ R (T, \pi_ {U C B}) ] \leq 2 \sqrt {6 \sigma^ {2} \log (T)} \mathbb {E} [ \mathbb {V} _ {\frac {1}{2}} (T, \pi_ {U C B}) ] + 2 \lambda \| \theta^ {\star} \| _ {\infty} \mathbb {E} [ \mathbb {V} _ {1} (T, \pi_ {U C B}) ] + \frac {2 d \Delta_ {m a x}}{T}
+$$
+
+where, for any $\alpha > 0$ and $\pi \in \Pi$ , the cumulative potential under censorship is given by:
+
+$$
+\mathbb {V} _ {\alpha} (T, \pi) = \sum_ {t = 1} ^ {T} \left(N _ {a _ {t}} (t - 1) + \lambda\right) ^ {- \alpha}.
+$$
+
+Without censorship, the cumulative potential translates the average rate of decay of uncertainty on the reward of different arms and is closely linked to the divergence between the true reward distribution and the empirical distribution of observed rewards [38]. Introducing censorship transforms the classical deterministic decay rate into a stochastic one. For a typical reward distribution, the rate of decay is proportional to a term in $n^{-\alpha}$ or can be upper bounded by such a term (see for e.g. [38]), where $n$ is the number of observed rewards. Therefore, a higher $\alpha$ corresponds to faster learning.
+
+In contrast to the classical non-regularized analysis or to the LCB case of Sec. 4, we observe two different orders of $\alpha$ (1/2 and 1) coming from the use of the $L_{\infty}$ -norm instead of the $L_{2}$ -norm. Taken independently, they lead to respective contributions of $\mathcal{O}(d_{eff} \log(T))$ and $\mathcal{O}(\sqrt{d_{eff} T})$ . Note that by working with a general $\alpha$ , our analysis naturally extends beyond sub-Gaussian noise to more general assumptions about the Laplace transform of noise (e.g., lighter or heavier tails), as discussed in Rem 2. To further study $\mathbb{V}_{\alpha}$ , we introduce the following property:
+
+Proposition 3.4. For all $\alpha >0$ , $\delta \in ]0,1]$ and given $\psi_{\alpha}$ a primitive of $x\mapsto x^{-\alpha}$ , we have:
+
+$$
+\max _ {\pi \in \Pi} \mathbb {E} [ \mathbb {V} _ {\alpha} (T, \pi) ] \leq \frac {d _ {e f f}}{(1 - \delta) ^ {\alpha}} \left[ \psi_ {\alpha} \left(\frac {T}{d _ {e f f}} + \frac {\lambda}{1 - \delta}\right) - \psi_ {\alpha} \left(\frac {\lambda}{1 - \delta}\right) \right] + \frac {2 4 d _ {e f f} \log (T) + d}{\lambda^ {\alpha}} + \frac {4 d _ {e f f}}{\lambda^ {\alpha} \delta^ {2} T ^ {1 2 \delta^ {2}}}.
+$$
+
+The proof of this proposition involves two steps: firstly, we remove the stochastic dependence induced by the censorship through concentration properties (See App. B), and we then solve the resulting policy maximization problem (Lemma 3.5). In the first step, we consider for a given $\delta \in ]0,1]$ the event:
+
+$$
+\mathcal {H} _ {C E N} (\delta) = \left\{\exists a \in [ d ], t \in [ T ], N _ {a} (t) < (1 - \delta) p _ {a} \tau_ {a} (t) \quad \text {a n d} \quad \tau_ {a} (t) \geq T _ {0} (a) \right\},
+$$
+
+where $T_0(a) \triangleq 24\log(T)/p_a + 1$ and claim that $\mathbb{P}(\mathcal{H}_{CEN}(\delta)) \leq \frac{4d_{eff}}{\delta^2} T^{-12\delta^2}$ , improving a result of [24]. Here $\mathcal{H}_{CEN}$ denotes the event where there is a significant gap between the realized and expected
+
+number of observed rewards. We consider its complement in our analysis of the principal order of regret. This allows us to lower bound for each action, the realized number of reward observations by a multiple of the number of times that action was selected, thus eliminating the randomness induced by censoring.
+
+Our second step makes use of the following lemma (also known as a water-filling process in information theory [14]):
+
+Lemma 3.5. For $\psi_{\alpha}$ a primitive of $x\mapsto x^{-\alpha}$ where $\alpha \in ]0,1]$ , regularization $(\lambda_{a})_{a\in [d]}\in (\mathbb{R}_{>0})^{d}$ and censorship vector $(p_a)_{a\in [d]}$ , the solution of the optimization problem:
+
+$$
+\max _ {\tau_ {1}, \dots , \tau_ {d} \geq 0} \sum_ {a \in [ d ]} \frac {1}{p _ {a}} \left(\psi_ {\alpha} \left(p _ {a} \tau_ {a} + \lambda_ {a}\right) - \psi_ {\alpha} (\lambda_ {a})\right) \quad s. t. \quad \sum_ {a \in [ d ]} \tau_ {a} = T
+$$
+
+is given by $\tau_{a}^{\star} = \frac{1}{p_{a}} [C - \lambda_{a}]^{+}$ , where $C$ ensures the total budget constraint $\sum_{a\in [d]}\tau_{a}^{\star} = T$ . In particular, with $\lambda_{eff}\triangleq \frac{1}{d_{eff}}\sum_{a\in [d]}\frac{\lambda_a}{p_a}$ and $\lambda_{a}^{0}\triangleq d_{eff}(\lambda_{a} - \lambda_{eff})$ , the optimal solution is given by $\tau_{a}^{\star}\triangleq \frac{1}{p_{a}d_{eff}} (T - \lambda_{a}^{0})$ for $T\geq \max_{a}\lambda_{a}^{0}$ and the optimal value is $d_{eff}\psi_{\alpha}(\frac{T}{d_{eff}} +\lambda_{eff}) - \sum_{a\in [d]}\frac{1}{p_a}\psi_\alpha (\lambda_a)$ .
+
+For unregularized algorithms, this framework can be easily applied to provide instances-dependent guarantees by adding constraints of type $\tau_{a} \leq f(\Delta_{a})$ within Lemma 3.5. Optimal guarantees under regularization such as the ones given in Prop. 3.2 require however to consider both orders of $\mathbb{V}_{\alpha}$ (1/2 and 1) simultaneously and not independently, leading to slight variations as shown in the proof of Prop. 3.2 Next, we further discuss the properties of $\mathbb{V}_{\alpha}$ given its importance in our analysis.
+
+# 3.3 Evaluating Adaptivity Gain
+
+It is well known that adaptivity is a key feature of sequential decision problems: optimal policies use feedback from previous decisions to decide the next action to take based on the data, and in comparison non-adaptive policies can be quite suboptimal. Somewhat interestingly, the main result of this section is that adaptivity in the context of censoring does not provide a significant advantage to the decision maker. More precisely, being able to observe which decisions have been censored and adapting to this information does not bring more than a second order gain. In proving this result, we quantify and gain insight into the expected performance of policies that are adaptive to the realization of the censorship process, in comparison to a class of non-adaptive (i.e., offline) policies.
+
+In fact, through the introduction of $\mathcal{H}_{CEN}(\delta)$ and for any $\alpha \in [0,1]$ , $\delta \in ]0,1]$ , we showed in Prop. 3.4 the upper bound $\frac{d_{eff}}{(1 - \delta)^{\alpha}}\psi_{\alpha}\left(\frac{T}{d_{eff}} +\frac{\lambda}{1 - \delta}\right)$ for the learning complexity $\max \mathbb{E}[\mathbb{V}_{\alpha}(T,\pi)]$ where the maximum is taken over the class of adaptive policies $\Pi_{adapt}$ , i.e., measurable with respect to the censorship. Note that the exact value of such maximum is notoriously difficult to study due to the adaptive nature of censorship induced by the decision-making process. Next, we introduce $\Pi_{off}$ , the class of policies that are not adaptive with respect to the censorship and we prove that:
+
+Lemma 3.6. For $\alpha \in ]0,1]$ and $\lambda >0$ , we have $\max_{\pi \in \Pi_{off}}\mathbb{E}[\mathbb{V}_{\alpha}(T,\pi)]\sim d_{eff}\psi_{\alpha}(\frac{T}{d_{eff}} +\lambda)$ .
+
+In other words, restricting attention to offline policies is sufficient to obtain the correct scaling. The next step to complete our claim is the asymptotic expansion:
+
+Proposition 3.7. For $\alpha \in ]0,1]$ , by denoting $\gamma_{\alpha}(\mathbf{p}) \triangleq \frac{\alpha}{2d_{eff}^{1 - \alpha}} \sum_{a \in [d]} \frac{1}{p_a} \left( \sum_{\tilde{a} \neq a} \frac{1 - p_{\tilde{a}}}{p_{\tilde{a}}} \right)$ , we have:
+
+$$
+\max _ {\pi \in \Pi_ {a d a p t}} \mathbb {E} [ \mathrm {V} _ {\alpha} (T, \pi) ] - \max _ {\pi \in \Pi_ {o f f}} \mathbb {E} [ \mathrm {V} _ {\alpha} (T, \pi) ] = \gamma_ {\alpha} (\mathbf {p}) \frac {1}{T ^ {\alpha}} + o \left(\frac {1}{T ^ {\alpha}}\right). \quad (\star)
+$$
+
+Moreover, if for a given $\beta \in ]0,1[$ , we introduce $\Pi_{\text{single}}(\beta T)$ the policy class whose censorship information set has a single updating at time $\lfloor \beta T \rfloor$ , we have:
+
+$$
+\max _ {\pi \in \Pi_ {s i n g l e} (\beta T)} \mathbb {E} [ \mathbb {V} _ {\alpha} (T, \pi) ] - \max _ {\pi \in \Pi_ {o f f}} \mathbb {E} [ \mathbb {V} _ {\alpha} (T, \pi) ] = \gamma_ {\alpha} (\mathbf {p}) \frac {\beta}{T ^ {\alpha}} + o \left(\frac {1}{T ^ {\alpha}}\right). \quad (\star \star)
+$$
+
+Thus, $\gamma_{\alpha}(\mathbf{p})$ can be viewed as an adaptivity gain resulting from the continuous correction of the cumulative variance induced by the action selection process. Essentially, it is closely related to
+
+the Jensen Gap of an appropriate random variable and the proof involves the study of the Taylor expansion of the potential function $\psi_{\alpha}$ . $(\star \star)$ tells us that a single observation of the censorship realization is sufficient to obtain a near-optimal gain in adaptivity. We present a proof sketch of Prop. 3.7 in App. B. This shows that censorship in MAB can be treated in an offline manner at first order.
+
+# 4 Contextual Bandit
+
+In this section, we study Linear Contextual Bandits (LCBs) under censorship. The regret analysis for the generic censorship model in Sec. 2 is significantly more complex for LCB than for MAB. This is due to the fact that different actions contribute differently to the information acquisition, leading to a non-linear phenomenon governing the trade-off between reward and information gain (see Sec 4.4).
+
+# 4.1 Multi-threshold Models and Regret Bounds
+
+To address the abovementioned challenge, we now introduce a simple multi-threshold censorship model, which enables a precise regret analysis. In particular, we consider that feedback is censored according to the following action-dependant probability:
+
+$$
+p: a \in \mathbb {B} _ {d} \mapsto \sum_ {j = 0} ^ {k} \mathbf {1} \left\{\sin \left(\phi_ {j}\right) \leq \langle a, u \rangle < \sin \left(\phi_ {j + 1}\right) \right\} p _ {j}, \tag {M7}
+$$
+
+where $(\phi_j)_{j\leq k + 1}$ is an increasing sequence verifying $\phi_0 = -\frac{\pi}{2}$ , $\phi_{k + 1} = \frac{\pi}{2}$ and $u\in \mathbb{R}^d$ is a unit vector. We assume that $(p_j)_{j\leq k}$ is decreasing, i.e. the censorship is increasing with $j$ in direction $u$ . Henceforth, we refer to the interval $[\sin (\phi_j),\sin (\phi_{j + 1})[$ as region $j$ . Note that simple models such as uniform censorship are subsumed by this family (for $k$ equals 0).
+
+The two main features of the multi-threshold model are: the radial aspect (the censorship probability depends on the action through a scalar product with a given vector) and the monotonicity (the censorship is monotone in the value of this scalar product). Note that $\boxed{MT}$ can be seen as a piecewise constant approximation of any Generalized Linear Model (GLM) [31]. Thus, the simplicity of this censorship model is not an inherently limiting factor on the generality of our subsequent results.
+
+Moreover, $\boxed{MT}$ admits a natural behavioral interpretation: Such a distribution can be seen as induced by a population model of heterogeneous random-utility maximizing agents. A single threshold model (i.e. $k$ equals 1) corresponds to a given agent type, and the multi-threshold model naturally results from aggregate responses of heterogeneous population [4].
+
+
+Figure 1: Example of a multi-threshold model for $k = 2$ (Green). Logistic censorship model (Red)
+
+We now state the main result of this section:
+
+Theorem 4.1. For a given multi-threshold censorship model $\mathcal{MT}$ there exists $d_{\mathrm{eff}}$ such that the UCB algorithm with regularization $\lambda$ has an instance-independent expected regret of:
+
+$$
+\mathbb {E} [ R (T, \pi_ {U C B}) ] \leq \tilde {\mathcal {O}} (\sigma \sqrt {d \cdot d _ {e f f}} \sqrt {T}).
+$$
+
+Importantly, note the mapping from the original dimension $d$ to the enlarged $\sqrt{d\cdot d_{eff}}$ , in contrast to the previous dilation $d\mapsto d_{eff}$ for the case of MAB problems. An extension to Generalized Linear Contextual Bandits is provided in App. C.6 where we show that the dimension is governed by $\sqrt{d\cdot d_{eff}}/\kappa$ , with $\kappa$ corresponding to a minimum of the derivative of the link function (encompassing the smoothness of the GLM at its maximum) [28, 16]. We conjecture that this result still holds if we relax the monotonicity property of $\mathcal{MT}$ although it will require some modifications in the proofs of section D. On the other hand, we believe that the radial property is necessary, considering the related literature on GLMs (further discussed in App. C.6) where it appears prominently.
+
+# 4.2 Generalized Cumulative Censored Potential
+
+Analogous to the MAB case, we now introduce for LCB the random matrices corresponding to the effective realization $\mathbb{W}_t^C\triangleq \lambda \mathbb{I}_d + \sum_{n = 1}^t x_{a_t}a_ta_t^\top$ and the expected realization $\mathbb{W}_t\triangleq \lambda \mathbb{I}_d + \sum_{n = 1}^t p(a_t)a_ta_t^\top$ . We also introduce the continuous counterpart of $\mathbb{W}_t$ defined as $\mathbb{W}(t)\triangleq \lambda \mathbb{I}_d + \int_{u = 0}^{t}p(a(u))a(u)a(u)^\top\partial u$ , where $(a(u))_{u\leq T}$ is an integrable deterministic path. We emphasise that the use of continuous counterpart is key in enabling our next results. As in the MAB case, we bound the regret although now using a generalization of $\mathbb{V}_{\alpha}$ :
+
+Lemma 4.2. For all $\delta \in ]0,1]$ , there exists a constant $\tilde{\beta}_{\delta}(T) = \Theta (\sqrt{d\log(T)})$ such that
+
+$$
+\mathbb {E} [ R (T, \pi_ {U C B}) ] \leq 2 \tilde {\beta} _ {\delta} (T) \sqrt {T \mathbb {E} [ \mathbb {V} _ {1} (T , \pi_ {U C B}) ]} + \delta T \Delta_ {m a x},
+$$
+
+where, for $\alpha > 0$ and $\pi \in \Pi$ , the linear extension of the cumulative censored potential is given by:
+
+$$
+\mathbb {V} _ {\alpha} (T, \pi) \triangleq \sum_ {t = 1} ^ {T} \| a _ {t} \| _ {(\mathbb {W} _ {t - 1} ^ {C}) ^ {- \alpha}} ^ {2} = \sum_ {t = 1} ^ {T} \operatorname {T r} ((\mathbb {W} _ {t - 1} ^ {C}) ^ {- \alpha} a _ {t} a _ {t} ^ {\top}).
+$$
+
+The proof idea is analogous (albeit more complex) than in the finite action case (see App. C). In order to get a handle on $\mathbb{V}_{\alpha}$ , we again leverage a two-step approach: first we eliminate the randomness due to censorship (here, we utilize matrix martingale inequalities) and then optimize the resulting deterministic quantity seen through a continuous lens. The first step requires the following result:
+
+Proposition 4.3. For any $\delta \in ]0,1]$ , $\lambda > 0$ , $\alpha > 0$ and policy $\pi \in \Pi$ , we have:
+
+$$
+\mathbb {E} \left[ V _ {\alpha} (T, \pi) \right] \leq \frac {\delta}{\lambda^ {\alpha}} + C (\delta) ^ {\alpha} \operatorname {T r} \left(\int_ {0} ^ {T} \mathbb {W} (t) ^ {- \alpha} a (t) a (t) ^ {\top} \partial t\right),
+$$
+
+where $C(\delta)\triangleq 8(\lambda +1)\max (\log (d / \delta)) / \lambda ,1) / \lambda .$
+
+The key idea of this result is to observe that the telescopic sum on which the classical Elliptical Potential lemma [1358] heavily relies on is, in fact, the discrete approximation of an integral over a matrix path. This critical methodological contribution is further discussed in Rem. [1] and [5].
+
+Remark 1. One way to fully appreciate the generality of this result is to consider the simpler case of classical uncensored environment for which we obtain for $\alpha >0,\alpha \neq 1$ ..
+
+$$
+\sum_ {t = 1} ^ {T} \| a _ {t} \| _ {\mathbb {W} _ {t - 1} ^ {- \alpha}} ^ {2} \leq \left(\frac {\lambda + 1}{\lambda}\right) ^ {\alpha} \frac {\operatorname {T r} \left(\int_ {0} ^ {T} \partial \mathbb {W} (t) ^ {1 - \alpha}\right)}{1 - \alpha} = \left(\frac {\lambda + 1}{\lambda}\right) ^ {\alpha} \frac {\operatorname {T r} (\mathbb {W} _ {T} ^ {1 - \alpha} - \mathbb {W} _ {0} ^ {1 - \alpha})}{1 - \alpha}.
+$$
+
+For $\alpha = 1$ , a similar reasoning is applied using the formula $\operatorname{Tr}(\log(A)) = \log(\det A)$ :
+
+$$
+\sum_ {t = 1} ^ {T} \| a _ {t} \| _ {\mathbb {W} _ {t - 1} ^ {- 1}} ^ {2} \leq \frac {\lambda + 1}{\lambda} \int_ {0} ^ {T} \frac {\partial \log \det (\mathbb {W} (t))}{\partial t} \partial t = \frac {\lambda + 1}{\lambda} \operatorname {T r} (\log \mathbb {W} _ {T} - \log \mathbb {W} _ {0}) = \frac {\lambda + 1}{\lambda} \log \frac {\det \mathbb {W} _ {T}}{\det \mathbb {W} _ {0}}.
+$$
+
+A deeper study of the eigenvalues of $\mathbb{W}_T^{1 - \alpha}$ then yields the worst-case upper bound $d^{\alpha}(d\lambda + T)^{1 - \alpha} / (1 - \alpha)$ for $\alpha < 1$ and $d\lambda^{1 - \alpha} / (\alpha - 1)$ for $\alpha > 1$ , recovering more naturally and extending the results of [8]. Thus, analogous to the water filling process highlighted in the MAB case in Lemma [3.5], we now consider a spectral water-filling process [14] optimizing over the eigenvalues of $\psi_{\alpha}(\mathbb{W}_T)$ with a slight abuse of notations ( $\mathbb{W}_T^{1 - \alpha}$ and $\log \mathbb{W}_T$ in this discussion).
+
+Following Rem $\square$ , for the general censored case the challenge now becomes to identify a suitable matrix operator on which the aforementioned spectral maximization can be performed. By applying Lemma $\square$ we henceforth focus on the case of $\alpha = 1$ for which Prop. $\square$ implies that for any policy:
+
+$$
+\operatorname {T r} \left(\int_ {0} ^ {T} \mathbb {W} (t) ^ {- 1} a (t) a (t) ^ {\top} \partial t\right) = \int_ {0} ^ {T} \frac {1}{p (a (t))} \frac {\partial \log \det (\mathbb {W} (t))}{\partial t} \partial t.
+$$
+
+Next, we focus on maximizing this integral over the policy class $\Pi$ and again recover the notion of effective dimension.
+
+# 4.3 Effective Dimension in Linear Settings
+
+We now highlight immediate properties of the effective dimension, and then present its general study for the multi-threshold model $\mathcal{M}^{\mathcal{T}}$ .
+
+Lemma 4.4. Let us consider an uniform censorship model $p: a \mapsto \bar{p}$ . By leveraging the case of equality in the Arithmetic-Geometric inequality applied to the eigenvalues of $\mathbb{W}_T$ , we then simply deduce the associated effective dimension $d_{\mathrm{eff}} \triangleq d / \bar{p}$ :
+
+$$
+\max _ {\pi \in \Pi} \int_ {0} ^ {T} \frac {1}{\bar {p}} \frac {\partial \log \det (\mathbb {W} (t))}{\partial t} \partial t = d _ {e f f} \log \left(1 + \frac {T}{\lambda d _ {e f f}}\right).
+$$
+
+In fact, the logarithmic scaling of this quantity persists while moving beyond the uniform censorship assumption. This also highlights the importance of the leading dimension factor, crudely upper bounded by $d / p_{min}$ in the next lemma:
+
+Lemma 4.5. For any censorship function $p$ , by introducing lower and upper bounds $(p_{min}, p_{max})$ of $p$ , we have:
+
+$$
+\frac {d}{p _ {m a x}} \log (1 + \frac {p _ {m i n} T}{d \lambda}) \leq \max _ {\pi \in \Pi} \int_ {0} ^ {T} \frac {1}{p (a (t))} \frac {\partial \log \det (\mathbb {W} (t))}{\partial t} \partial t \leq \frac {d}{p _ {m i n}} \log (1 + \frac {p _ {m a x} T}{d \lambda}).
+$$
+
+Related problems in the Generalized Linear Models literature [47, 28, 16] are implicitly solved in the spirit of Lemma 4.5, where a minimum of the derivative of the link function plays the role of $p_{\text{min}}$ above. However, when the function $p$ varies with action $a$ , a more careful analysis is required to derive useful dimensional bounds. Our next major result addresses this gap in the literature by improving the bounds provided in Lemma 4.5.
+
+Theorem 4.6. For a multi-threshold censorship model $\mathcal{MT}$ we have:
+
+$$
+\max _ {\pi \in \Pi} \int_ {0} ^ {T} \frac {1}{p (a (t))} \frac {\partial \log \det (\mathbb {W} (t))}{\partial t} \partial t = d _ {e f f} \log (T) + o (\log (T)), \tag {P}
+$$
+
+where $d_{\text{eff}}$ is the effective dimension. Furthermore, $d_{\text{eff}}$ is characterized by two cases:
+
+- Case 1: Single region $j$ effective dimension $d_{\text{eff}} = \frac{d}{p_j}$ .
+- Case 2: Bi-region $(i,j)$ effective dimension, with $i < j$ :
+
+$$
+d _ {e f f} = \frac {1}{p _ {j}} \left[ (d - 1) \frac {1 - l (i , j)}{\frac {p _ {i}}{p _ {j}} - l (i , j)} + \frac {u (i , j) - 1}{u (i , j) - \frac {p _ {i}}{p _ {j}}} \right] < \frac {d}{p _ {j}}. \tag {D}
+$$
+
+where $l(i,j)\triangleq \frac{\sin^2(\phi_i)}{\sin^2(\phi_j)}$ and $u(i,j)\triangleq \frac{\cos^2(\phi_i)}{\cos^2(\phi_j)}$ .
+
+The implications of these cases are further discussed in Fig 2 in App. D. Notice that a necessary condition for the bi-region $(i,j)$ effective dimension to arise is the constraint on $\frac{p_i}{p_j}$ :
+
+$$
+\max (1, \underbrace {\frac {d l (i , j) u (i , j)}{u (i , j) + (d - 1) l (i , j)}} _ {\triangleq s ^ {\star} (i, j)}) < \frac {p _ {i}}{p _ {j}} < \underbrace {\frac {(d - 1) u (i , j) + l (i , j)}{d}} _ {\triangleq r ^ {\star} (i, j)}
+$$
+
+In the limit $\frac{p_i}{p_j} \to r^\star(i, j)$ , $d_{\text{eff}}$ goes again to $d / p_j$ . We interpret this limiting case as locally hard in the sense that censorship in region $j$ is sufficiently important in comparison to all other regions to impose a maximal effective dimension to the problem, irrespective of the values of $p_i$ , matching Lemma 4.5. On the other hand, for the other limiting case (under additional mild assumptions), we find that $d_{\text{eff}}$ also goes to $d / p_j$ , but now for a uniformly hard reason: that is, censorship is approximately constant and equal to $p_j$ , recovering the Lemma 4.4. Finally, in between these two extremes lies the minimum effective dimension for a given value of $\frac{p_i}{p_j}$ .
+
+# 4.4 Temporal dynamics of $\mathbb{W}(t)$
+
+The proof of Thm. 4.6 requires the characterization of the dynamics of the optimal policy of $(\mathcal{P})$ . Importantly, we discover that the evolution of $\mathbb{W}(t)$ is described by two qualitatively different regimes as outlined next. It turns out that our continuous approach to analyzing cumulative censored potential is an important tool to obtaining this result.
+
+Transient Regime: There exists a decreasing sequence of censorship regions $\{i_1 = k,\dots ,i_l\}$ of length $l\in [k + 1]$ and associated time sequence $\{t_0\triangleq 0,t_1,\ldots ,t_l\}$ such that whenever $t_j\leq t\leq t_{j + 1}$ for a given index $j\leq l - 1$ , the evolution of $\mathbb{W}(t)$ is given by:
+
+$$
+\mathbb {W} (t) = p _ {i _ {j + 1}} (t - t _ {j}) \mathbb {W} _ {i _ {j + 1}} + \mathbb {W} (t _ {j}) = p _ {i _ {j + 1}} (t - t _ {j}) \mathbb {W} _ {i _ {j + 1}} + \sum_ {n = 1} ^ {j} p _ {i _ {n}} (t _ {n} - t _ {n - 1}) \mathbb {W} _ {i _ {n}} + \lambda \mathbb {I} _ {d},
+$$
+
+where $\mathbb{W}_i$ denotes the $d\times d$ diagonal matrix $\mathrm{diag}(\frac{\cos^2(\phi_i)}{d - 1},\dots ,\frac{\cos^2(\phi_i)}{d - 1},\sin^2 (\phi_i))$ . Interestingly, the initial misspecification of censorship is self-corrected during this transient step but at an extra cost. This characterization of transient regime highlights an important consequence of using classical algorithms in censored environments.
+
+Steady State Regime: Post-transient regime, the dynamics of $\mathbb{W}(t)$ enter a steady state regime, where one of the two cases necessarily arises.
+
+- Case 1: Single region $i_{l}$ . This case arises when the last element of the time sequence $t_{l}$ is equal to $+\infty$ and we have the single region evolution for all $t \geq t_{l - 1}$ :
+
+$$
+\mathbb {W} (t) = p _ {i _ {l}} (t - t _ {l - 1}) \mathbb {W} _ {i _ {l}} + \mathbb {W} (t _ {l - 1}) = p _ {i _ {l}} (t - t _ {l - 1}) \mathbb {W} _ {i _ {l}} + \sum_ {n = 1} ^ {l - 1} p _ {i _ {n}} (t _ {n} - t _ {n - 1}) \mathbb {W} _ {i _ {n}} + \lambda \mathbb {I} _ {d}.
+$$
+
+The effective dimension corresponding to this dynamics is $d / p_{i_l}$ , with the following equality for $T \geq t_{l-1}$ :
+
+$$
+\int_ {0} ^ {T} \frac {1}{p (a (t))} \frac {\partial \log \det (\mathbb {W} (t))}{\partial t} \partial t = \frac {1}{p _ {i _ {l}}} \log \det (\mathbb {W} (T)) + \sum_ {n = 1} ^ {l - 1} \left(\frac {1}{p _ {i _ {n}}} - \frac {1}{p _ {i _ {n + 1}}}\right) \log \det \mathbb {W} (t _ {n}).
+$$
+
+- Case 2: Bi-region $(i_{l + 1},i_l)$ . This case arises when the steady-state dynamics of $\mathbb{W}(t)$ span the two regions $(i_{l + 1},i_l)$ with $i_{l + 1} < i_l$ . For all $t\geq t_l$ , we have the evolution:
+
+$$
+\mathbb {W} (t) \propto p _ {i _ {l + 1}} (t + \lambda^ {\star}) \left( \begin{array}{c c} \cos^ {2} (\phi_ {i _ {l}}) (u (i _ {l + 1}, i _ {l}) - \frac {p _ {i _ {l + 1}}}{p _ {i _ {l}}}) \mathbb {I} _ {d - 1} & (0) \\ (0) & \sin^ {2} (\phi_ {i _ {l}}) (\frac {p _ {i _ {l + 1}}}{p _ {j}} - l (i _ {l + 1}, i _ {l})) \end{array} \right).
+$$
+
+where $\lambda^{\star}$ and the proportionality factor are specified in SI. The corresponding effective dimension is given by $(\mathbb{D})$ and the following equality holds for all $T \geq t_l$ :
+
+$$
+\int_ {0} ^ {T} \frac {1}{p (a (t))} \frac {\partial \log \det (\mathbb {W} (t))}{\partial t} \partial t = d _ {e f f} \log (1 + \frac {T - t _ {l}}{t _ {l} + \lambda^ {\star}}) + \sum_ {n = 1} ^ {l} (\frac {1}{p _ {i _ {n}}} - \frac {1}{p _ {i _ {n + 1}}}) \log \det \mathbb {W} (t _ {n}).
+$$
+
+For further discussions on transient and steady state regimes, we refer to Fig.3.4 and 5 in App. D.
+
+# 5 Concluding Remarks
+
+In this work, we demonstrate that the complexity of bandit learning under censorship is governed by the notion of effective dimension. To do so, we developed a novel analysis framework which enables us to precisely estimate this quantity for a broad class of multi-threshold censorship models. An important future work would be to extend our model and approach to Bayesian settings, which will likely provide us with useful insights on the cumulative censored potential $\mathbb{V}_{\alpha}$ , as initiated by [18]. Future work also includes relaxing the Missing Completely at Random (MCAR) property in favor of time-dependent censorship models such as Markov Decision Processes (MDPs). We believe that tools similar to those developed in our potential-based analysis can be applied in this case. Finally, the contributions of our work may be of interest to the recent value alignment literature, where the question of learnability under human-AI interactions is central. [10, 17, 12].
+
+We do not envision any negative societal impacts of our work other than that of bandits algorithms deployed in AI-driven platforms.
+
+# Acknowledgments and Disclosure of Funding
+
+This research project is supported by the AFOSR FA9550-19-1-0263 "Building attack resilience into complex networks" Grant. The authors would like to thank Prem Talwai and the anonymous reviewers for providing insightful comments and suggestions.
+
+# References
+
+[1] Yasin Abbasi-yadkori, Dávid Pál, and Csaba Szepesvári. Improved algorithms for linear stochastic bandits. In J. Shawe-Taylor, R. Zemel, P. Bartlett, F. Pereira, and K.Q. Weinberger, editors, Advances in Neural Information Processing Systems, volume 24. Curran Associates, Inc., 2011.
+[2] Jacob Abernethy, Kareem Amin, and Ruihao Zhu. Threshold bandit, with and without censored feedback. In Proceedings of the 30th International Conference on Neural Information Processing Systems, NIPS'16, page 4896-4904, Red Hook, NY, USA, 2016. Curran Associates Inc.
+[3] Shipra Agrawal and Navin Goyal. Analysis of thompson sampling for the multi-armed bandit problem. In Conference on learning theory, pages 39-1. JMLR Workshop and Conference Proceedings, 2012.
+[4] Victor Aguirregabiria and Pedro mira. Dynamic Discrete Choice Structural Models: A Survey. Technical Report tecipa-297, University of Toronto, Department of Economics, July 2007.
+[5] Sylvain Arlot. Rééchantillonnage et Sélection de modèles. Theses, Université Paris Sud - Paris XI, December 2007.
+[6] Jean-Yves Audibert and Sébastien Bubeck. Regret bounds and minimax policies under partial monitoring. Journal of Machine Learning Research, 11(94):2785-2836, 2010.
+[7] Xueying Bai, Jian Guan, and Hongning Wang. A model-based reinforcement learning with adversarial training for online recommendation. In H. Wallach, H. Larochelle, A. Beygelzimer, F. d'Alché-Buc, E. Fox, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 32. Curran Associates, Inc., 2019.
+[8] Alexandra Carpentier, Claire Vernade, and Yasin Abbasi-Yadkori. The elliptical potential lemma revisited, 2020.
+[9] Nicolo Cesa-Bianchi, Claudio Gentile, Yishay Mansour, and Alberto Minora. Delay and cooperation in nonstochastic bandits. In Vitaly Feldman, Alexander Rakhlin, and Ohad Shamir, editors, 29th Annual Conference on Learning Theory, volume 49 of Proceedings of Machine Learning Research, pages 605-622, Columbia University, New York, New York, USA, 23-26 Jun 2016. PMLR.
+[10] Lawrence Chan, Dylan Hadfield-Menell, Siddhartha Srinivasa, and Anca Dragan. The assistive multi-armed bandit. In Proceedings of the 14th ACM/IEEE International Conference on Human-Robot Interaction, HRI '19, page 354–363. IEEE Press, 2019.
+[11] Wei Chen, Yajun Wang, Yang Yuan, and Qinshi Wang. Combinatorial multi-armed bandit and its extension to probabilistically triggered arms. Journal of Machine Learning Research, 17(50):1-33, 2016.
+[12] Paul Christiano, Jan Leike, Tom B. Brown, Miljan Martic, Shane Legg, and Dario Amodei. Deep reinforcement learning from human preferences, 2017.
+[13] Wei Chu, Lihong Li, Lev Reyzin, and Robert Schapire. Contextual bandits with linear payoff functions. In Proceedings of the Fourteenth International Conference on Artificial Intelligence and Statistics, volume 15 of Proceedings of Machine Learning Research, pages 208-214, Fort Lauderdale, FL, USA, 11-13 Apr 2011. PMLR.
+[14] Thomas M. Cover and Joy A. Thomas. Elements of Information Theory (Wiley Series in Telecommunications and Signal Processing). Wiley-Interscience, USA, 2006.
+
+[15] Miroslav Dudik, Daniel Hsu, Satyen Kale, Nikos Karampatziakis, John Langford, Lev Reyzin, and Tong Zhang. Efficient optimal learning for contextual bandits. arXiv preprint arXiv:1106.2369, 2011.
+[16] Sarah Filippi, Olivier Cappe, Aurélien Garivier, and Csaba Szepesvári. Parametric bandits: The generalized linear case. In J. Lafferty, C. Williams, J. Shawe-Taylor, R. Zemel, and A. Culotta, editors, Advances in Neural Information Processing Systems, volume 23. Curran Associates, Inc., 2010.
+[17] Dylan Hadfield-Menell, Anca Dragan, Pieter Abbeel, and Stuart Russell. Cooperative inverse reinforcement learning, 2016.
+[18] Nima Hamidi and Mohsen Bayati. The randomized elliptical potential lemma with an application to linear thompson sampling, 2021.
+[19] Hoda Heidari, Michael Kearns, and Aaron Roth. Tight policy regret bounds for improving and decaying bandits. In Proceedings of the Twenty-Fifth International Joint Conference on Artificial Intelligence, IJCAI'16, page 1562-1570. AAAI Press, 2016.
+[20] James Honaker and Gary King. What to do about missing values in time series cross-section data. American Journal of Political Science, 54(3):561-581, 2010 2010.
+[21] Shinji Ito, Daisuke Hatano, Hanna Sumita, Kei Takemura, Takuro Fukunaga, Naonori Kakimura, and Ken-Ichi Kawarabayashi. Delay and cooperation in nonstochastic linear bandits. In H. Larochelle, M. Ranzato, R. Hadsell, M. F. Balcan, and H. Lin, editors, Advances in Neural Information Processing Systems, volume 33, pages 4872-4883. Curran Associates, Inc., 2020.
+[22] Pooria Joulani, Andras Gyorgy, and Csaba Szepesvari. Online learning under delayed feedback. In Sanjoy Dasgupta and David McAllester, editors, Proceedings of the 30th International Conference on Machine Learning, volume 28 of Proceedings of Machine Learning Research, pages 1453-1461, Atlanta, Georgia, USA, 17-19 Jun 2013. PMLR.
+[23] Johannes Kirschner and Andreas Krause. Information directed sampling and bandits with heteroscedastic noise. In Sébastien Bubeck, Vianney Perchet, and Philippe Rigollet, editors, Proceedings of the 31st Conference On Learning Theory, volume 75 of Proceedings of Machine Learning Research, pages 358-384. PMLR, 06-09 Jul 2018.
+[24] Tal Lancewicki, Shahar Segal, Tomer Koren, and Y. Mansour. Stochastic multi-armed bandits with unrestricted delay distributions. In ICML, 2021.
+[25] Tor Lattimore and Csaba Szepesvari. An information-theoretic approach to minimax regret in partial monitoring. In $COLT$ , 2019.
+[26] Tor Lattimore and Csaba Szepesvári. Bandit algorithms. Cambridge University Press, 2020.
+[27] Lihong Li, Wei Chu, John Langford, and Robert E Schapire. A contextual-bandit approach to personalized news article recommendation. In Proceedings of the 19th international conference on World wide web, pages 661-670, 2010.
+[28] Lihong Li, Yu Lu, and Dengyong Zhou. Provably optimal algorithms for generalized linear contextual bandits. In International Conference on Machine Learning, pages 2071-2080. PMLR, 2017.
+[29] R.J.A. Little and D.B. Rubin. Statistical analysis with missing data. Wiley series in probability and mathematical statistics. Probability and mathematical statistics. Wiley, 2002.
+[30] Travis Mandel, Yun-En Liu, Emma Brunskill, and Zoran Popovic. The queue method: Handling delay, heuristics, prior data, and evaluation in bandits. In Proceedings of the Twenty-Ninth AAAI Conference on Artificial Intelligence, AAAI'15, page 2849-2856. AAAI Press, 2015.
+[31] P. McCullagh and J.A. Nelder. Generalized Linear Models, Second Edition. Chapman and Hall/CRC Monographs on Statistics and Applied Probability Series. Chapman & Hall, 1989.
+
+[32] Gergely Neu, Andras Antos, András György, and Csaba Szepesvári. Online markov decision processes under bandit feedback. In J. Lafferty, C. Williams, J. Shawe-Taylor, R. Zemel, and A. Culotta, editors, Advances in Neural Information Processing Systems, volume 23. Curran Associates, Inc., 2010.
+[33] Therese D. Pigott. A review of methods for missing data. Educational Research and Evaluation, 7(4):353-383, 2001.
+[34] Ciara Pike-Burke, Shipra Agrawal, Csaba Szepesvari, and Steffen Grunewalder. Bandits with delayed, aggregated anonymous feedback. In International Conference on Machine Learning, pages 4105-4113. PMLR, 2018.
+[35] Chao Qin and Daniel Russo. Adaptivity and confounding in multi-armed bandit experiments, 2022.
+[36] Daniel Russo and Benjamin Van Roy. An information-theoretic analysis of thompson sampling. Journal of Machine Learning Research, 17(68):1-30, 2016.
+[37] Daniel Russo and Benjamin Van Roy. Learning to optimize via information-directed sampling. In Z. Ghahramani, M. Welling, C. Cortes, N. Lawrence, and K.Q. Weinberger, editors, Advances in Neural Information Processing Systems, volume 27. Curran Associates, Inc., 2014.
+[38] Shubhanshu Shekhar, Tara Javidi, and Mohammad Ghavamzadeh. Adaptive sampling for estimating probability distributions. In Hal Daumé III and Aarti Singh, editors, Proceedings of the 37th International Conference on Machine Learning, volume 119 of Proceedings of Machine Learning Research, pages 8687-8696. PMLR, 13-18 Jul 2020.
+[39] Aleksandrs Slivkins. Introduction to multi-armed bandits. Foundations and Trends® in Machine Learning, 12(1-2):1-286, 2019.
+[40] Niranjan Srinivas, Andreas Krause, Sham Kakade, and Matthias Seeger. Gaussian process optimization in the bandit setting: No regret and experimental design. In Proceedings of the 27th International Conference on International Conference on Machine Learning, ICML'10, page 1015-1022, Madison, WI, USA, 2010. Omnipress.
+[41] Niranjan Srinivas, Andreas Krause, Sham M. Kakade, and Matthias W. Seeger. Information-theoretic regret bounds for gaussian process optimization in the bandit setting. IEEE Transactions on Information Theory.
+[42] Claire Vernade, Alexandra Carpentier, Tor Lattimore, Giovanni Zappella, Beyza Ermis, and Michael Brückner. Linear bandits with stochastic delayed feedback. In Hal Daumé III and Aarti Singh, editors, Proceedings of the 37th International Conference on Machine Learning, volume 119 of Proceedings of Machine Learning Research, pages 9712–9721. PMLR, 13–18 Jul 2020.
+[43] Qinshi Wang and Wei Chen. Improving regret bounds for combinatorial semi-bandits with probabilistically triggered arms and its applications. In I. Guyon, U. Von Luxburg, S. Bengio, H. Wallach, R. Fergus, S. Vishwanathan, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 30. Curran Associates, Inc., 2017.
+[44] Han Wu and Stefan Wager. Thompson sampling with unrestricted delays. arXiv preprint arXiv:2202.12431, 2022.
+[45] Fuwen Yang and Yongmin Li. Set-membership filtering for systems with sensor saturation. Automatica, 45(8):1896-1902, 2009.
+[46] Chao Yu, Jiming Liu, Shamim Nemati, and Guosheng Yin. Reinforcement learning in healthcare: A survey. ACM Computing Surveys (CSUR), 55(1):1-36, 2021.
+[47] Zhengyuan Zhou, Renyuan Xu, and Jose Blanchet. Learning in generalized linear contextual bandits with stochastic delays. In H. Wallach, H. Larochelle, A. Beygelzimer, F. d'Alché-Buc, E. Fox, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 32. Curran Associates, Inc., 2019.
\ No newline at end of file
diff --git a/effectivedimensioninbanditproblemsundercensorship/images.zip b/effectivedimensioninbanditproblemsundercensorship/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..c1e9e41e2a828114491c436bcbdffe6636513b46
--- /dev/null
+++ b/effectivedimensioninbanditproblemsundercensorship/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ff3ae792aa7269bee07f86e3b4f40da57ab3710a21ab6bab666a6af915940a90
+size 285311
diff --git a/effectivedimensioninbanditproblemsundercensorship/layout.json b/effectivedimensioninbanditproblemsundercensorship/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..07b8e7eedd038ad8acbcca985fe15e91ffb3e4e3
--- /dev/null
+++ b/effectivedimensioninbanditproblemsundercensorship/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2315909c904729bd8a25882f59f0b54e17ff1a48245d54b990972b9ccd0996d6
+size 577977
diff --git a/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/0dda3705-9530-4474-b323-6011f9bb54a4_content_list.json b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/0dda3705-9530-4474-b323-6011f9bb54a4_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..890cb26af4d5f5c72564727fbb61f6b78faebff2
--- /dev/null
+++ b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/0dda3705-9530-4474-b323-6011f9bb54a4_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:be435595d57b3c13987864c31b1cc8e5f860f2dd878c71937ee4fb855871b1b8
+size 76639
diff --git a/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/0dda3705-9530-4474-b323-6011f9bb54a4_model.json b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/0dda3705-9530-4474-b323-6011f9bb54a4_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..3181f3417d304760dea82dcc49b03d6e489e4105
--- /dev/null
+++ b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/0dda3705-9530-4474-b323-6011f9bb54a4_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:850b45d19332f3005ef7389ea1e5e599a937a39a4e91b82c75d10e31bf5a375f
+size 97690
diff --git a/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/0dda3705-9530-4474-b323-6011f9bb54a4_origin.pdf b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/0dda3705-9530-4474-b323-6011f9bb54a4_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..7ab0b1e4504f1bc3cbec8610d9c9559ebdc0a17f
--- /dev/null
+++ b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/0dda3705-9530-4474-b323-6011f9bb54a4_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2a33f83060b0ae7f6a661dd9c751feadc2bb35a28ef8c1ef16abd65229b45a1e
+size 1055825
diff --git a/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/full.md b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..f1c41940dba34167a51ea12e671b724b371b92d8
--- /dev/null
+++ b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/full.md
@@ -0,0 +1,286 @@
+# Effectiveness of Vision Transformer for Fast and Accurate Single-Stage Pedestrian Detection
+
+Jing Yuan
+
+Department of Electric and Electronic Engineering
+
+Imperial College London
+
+j.yuan20@imperial.ac.uk
+
+Panagiotis Barmpoutis
+
+Department of Computer Science
+
+University College London
+
+p.barmpoutis@ucl.ac.uk
+
+Tania Stathaki
+
+Department of Electric and Electronic Engineering
+
+Imperial College London
+
+t.stathaki@imperial.ac.uk
+
+# Abstract
+
+Vision transformers have demonstrated remarkable performance on a variety of computer vision tasks. In this paper, we illustrate the effectiveness of the deformable vision transformer for single-stage pedestrian detection and propose a spatial and multi-scale feature enhancement module, which aims to achieve the optimal balance between speed and accuracy. Performance improvement with vision transformers on various commonly used single-stage structures is demonstrated. The design of the proposed architecture is investigated in depth. Comprehensive comparisons with state-of-the-art single- and two-stage detectors on different pedestrian datasets are performed. The proposed detector achieves leading performance on Caltech and Citypersons datasets among single- and two-stage methods using fewer parameters than the baseline. The log-average miss rates for Reasonable and Heavy are decreased to $2.6\%$ and $28.0\%$ on the Caltech test set, and $10.9\%$ and $38.6\%$ on the Citypersons validation set, respectively. The proposed method outperforms SOTA two-stage detectors in the Heavy subset on the Citypersons validation set with considerably faster inference speed.
+
+# 1 Introduction
+
+Pedestrian detection is a popular task subordinate to object detection in computer vision. This task aims to locate and classify pedestrians in images or videos accurately. Pedestrian detection is very important as it serves as the prerequisite of various vision tasks [1], such as human-centric tasks (person re-identification [2, 3], person search [4], human pose estimation [5] etc.) and more generic multi-object tracking [6]. It has been applied to autonomous driving [7, 8], video surveillance [9] and action tracking. In this paper, we focus on the detection based on RGB images.
+
+Pedestrian detection suffers from significant occlusion and varying scales. Intra- and inter-class occlusion occur when a pedestrian is occluded by other pedestrians or objects like cars, bicycles etc. Both significantly reduce the discriminative features and destroy the regular shape of pedestrians. For varying scales, large pedestrians tend to have more informative features. Still, they are difficult to fully extract from a vast region, while features of small targets are compact but relatively ambiguous with less preserved details. In summary, the fluctuating amount and varying shape of effective features are the core problems. They challenge the capabilities of feature extraction modules, which act as a long-standing bottleneck in pedestrian detection.
+
+To deal with these problems, two-stage methods [10-15] based on Fast [16] and Faster R-CNN [16] have pervaded pedestrian detection tasks owing to the high detection accuracy. These methods first make coarse predictions of targets via the Region Proposal Network (RPN), then refine the bounding boxes and predict the final scores based on the features inside the proposal regions. In addition to methods for general object detection, pedestrian detectors take advantage of unique characteristics of targets, such as the mask of visible parts [17, 10] and key points of human bodies [18]. However, the inference speed of these methods is limited by the repeated predictions which makes them hard to be applied to real-world scenes.
+
+To achieve faster inference, single-stage approaches, which only make one round prediction, are developed [19] and applied to pedestrian detection [20-24]. However, they suffer from decreased detection accuracy. The miss rates of two-stage methods in the Reasonable subset on Caltech are reduced to less than $4\%$ [14, 10, 25, 18], while those for single-stage methods are larger than $4.5\%$ [22]. For the Citypersons validation set, the miss rates for the former are less than $40\%$ in the Heavy subset, which is much lower than the latter $(42\%$ [24]). In this paper, we aim to improve the detection accuracy, especially in Reasonable and Heavy subsets, and to narrow the gap between single- and two-stage methods with fast inference.
+
+Typical single-stage detectors use anchors (SSD [26]) or are anchor-free (CSP [22]). The former generates rectangular bounding boxes with different aspect ratios and scales centered at each pixel of the feature maps at certain levels. Anchor scales are designed to be smaller at lower levels to facilitate the detection of small objects. These methods predict the offsets w.r.t. the upper left position, height and width of the anchor. Taking CSP as an example, the latter method only predicts the logarithm height and offsets w.r.t. centers of each pixel. For anchor-based single-stage detectors, ALFNet [21] refines anchors progressively with stacked prediction blocks to remedy the lack of proposal regions.
+
+In the past year, most research has focused on the fusion of representative features [27-32] to improve single-stage methods. For example, [30] enhances features via increasing semantic information at a low level and enriches the localization information at a high level. Similarly, [32] fuses the feature maps with different scales in adequate proportions. [29, 31] also explore new strategies to aggregate multi-level features. These feature enhancements are mainly performed along the dimension of feature level due to the intrinsically unbalanced feature information between shallow and deep feature levels. However, this unbalance also exists in two-stage detectors. As such, this is not the particular reason for the poorer accuracy of single-stage methods.
+
+The general architecture of single- and two-stage detectors are compared in Figure 1. Assuming that the training strategies and the detection head are the same for both methods, the difference in the architecture lies in the information fed into the detection head. For two-stage methods, both positions and features of the proposal regions are fed into the detection head. These proposals contain potential pedestrians. Thereby, the detection head classifies spatially target-focused features with fewer background interruptions and refines the bounding boxes by predicting small offsets from the proposal positions. For single-stage methods, each pixel in the feature map serves as the 'proposal region' with no pre-estimated positions. The receptive fields of these pixels share the same size, which may be too small to include sufficient information for large targets or so large that the background information overwhelms the useful features. This is more challenging for the classifier compared to two-stage methods. Additionally, single-stage methods have to regress from scratch, which is more difficult than simple refinement. Thus, the lack of spatially target-focused feature representation and the prediction of bounding boxes from scratch are the two key bottlenecks hindering the improvement of single-stage detectors.
+
+To make the features fed into the detection head concentrate on the targets or other helpful information automatically without the assistance of proposal regions, we take advantage of vision transformers in this paper. Vision transformers describe the pairwise dependency of each entity in the feature map with attention weights. The output weighted averaged feature is the adaptive aggregation of important entities (with higher attention weights) while the disturbing information (with lower attention weights) is suppressed. Using such attention mechanism on top of the backbone enables the single-stage detector to supplement spatially filtered features easily for subsequent classification and regression. In this case, the modified detector makes the best use of the fast inference originating from single-stage methods and more effective features. Our main contributions are as follows:
+
+- Demonstrate the effectiveness of the deformable vision transformer in improving the accuracy of commonly used single-stage detectors on pedestrian datasets.
+
+- Extend the application of vision transformers on top of the backbone in pedestrian detection tasks.
+- Achieve the best performance among single-stage detectors on the Caltech test set and Citypersons validation set while maintaining fast inference and reducing the number of parameters.
+- Narrow the gap of detection accuracy between the single- and two-stage methods in pedestrian detection.
+
+
+Figure 1: Generic detection pipeline of the single- and two-stage detectors. The detection head consists of two parallel branches for classification and regression.
+
+# 2 Related works
+
+Currently, vision transformers are used to establish general-purpose backbones (ViT [33] and Swin Transformer [34]) or stack on top of the backbone (DETR [35]). Since we focus on pedestrian detection, this paper explores the latter case. DETR consists of the convolution backbone, six encoders and decoders and the prediction head. It is an inspiring end-to-end detector but is memory-consuming. DETR requires massive memory to store the self-attention weights within each Multi-Head Self-Attention (MHSA) layer. The memory cost is linear to the number of attention heads and is square to the number of pixels in the down-sampled feature map. Additionally, first and second-order momentum in optimization introduce further memory cost in the training procedure. In pedestrian detection, more attention heads and relatively large down-sampled feature maps are preferred to enhance detection accuracy, especially for small targets. This results in memory explosion using DETR. To this end, deformable DETR [36] is proposed. It only needs the attention weights at several sampling locations rather than each pixel in the feature map. The memory cost of the attention weights is linear to the number of pixels, which makes training with high resolutions possible. Experiments show that the deformable DETR outperforms the Faster R-CNN [37] and DETR on COCO 2017 validation set [38].
+
+So far, vision transformers show great potential, but they have rarely been applied to pedestrian detection in the form of DETR or its variants. This is because it has been observed that they perform worse than the commonly used Faster R-CNN on CrowdHuman dataset [39] and require tenfold training time [40]. Although [40] proposed using dense object queries and the rectified attention field to enhance scale-adaptive feature extraction in the decoding phase, the modified deformable DETR still shows a limited advantage over the traditional Faster R-CNN. This implies that rigidly putting the whole six encoder-decoder pairs into the pedestrian detector may not be cost-effective. As an example, BoTNet [41] only substitutes the convolution layers in residual bottleneck blocks in the last stage of ResNet [42] for MHSA layers, but it produces strong performance on ImageNet validation set [43]. Inspired by this and the limitation above, our work only utilizes a single encoder of the deformable vision transformer as an adaptive feature extractor and applies it to commonly used single-stage detectors for better detection accuracy and fast inference.
+
+# 3 Method
+
+Deformable Vision Transformer Encoder: The deformable vision transformer encoder (Figure 2) takes the $L$ feature maps $\left\{z^l\right\}_{l=1}^L$ with height $H_l$ and width $W_l$ at scale $l$ and reference points,
+
+
+Figure 2: Left: The structure of the deformable vision transformer encoder. It is the same as the encoder in DETR except that the key tensor is removed while reference points are required. Mid: The MSDA averages the features at sparse sampling locations across different scales with weights computed from the query tensor. Right: Feed-Forward Network (FFN).
+
+which are the positions of grid centers of the feature maps, as inputs. It outputs the enhanced feature maps with the same resolution as the input. The input feature maps are first added by fixed encoded positional [35] and learnable level information [36] to disambiguate spatial and scale positions, then projected to the query feature map $\mathbf{z}_q$ via a linear layer. The feature maps also generate the value feature maps $\mathbf{z}_v$ with a linear layer but without encoding. The query feature map $\mathbf{z}_q$ , value feature map $\mathbf{z}_v$ together with the pre-generated reference points are sent to the Multi-Scale Deformable Attention (MSDA) layer to enhance spatially adaptive features, followed by a Feed-Forward Network (FFN). In summary, the encoder supplements the semantic information of input feature maps via the embedded attention layer and FFN.
+
+Multi-Scale Deformable Attention: The MSDA layer sums the selected entities at sampling locations in the value feature map $z_{v}$ with predicted attention weights by each corresponding query entity. These attention weights $W$ are the linear projection of query features $z_{q}$ followed by a softmax operator along scale and sampling point dimensions. For a single query entity, it only needs $N_{h}N_{l}N_{p}$ attention weights, representing the significance of selected value features at different attention heads, scales, and points. Selections are decided by the sampling locations which are the summation of reference points $p$ and sampling offsets $\Delta p$ which is the embedding of the query features. At each float sampling location, the selected value feature is bilinear interpolated for accuracy and training offset predictor. With weight, sampling locations and selected value features prepared, the $q$ -th element of the separate output feature $z^{so,h} \in \mathbb{R}^{N_q\times c_v}$ ( $N_{q} = \sum_{l = 1}^{L}H_{l}W_{l}$ , $c_{v}$ is the number of channels) at attention head $h$ (total $N_{h}$ heads) is
+
+$$
+\boldsymbol {z} _ {q} ^ {\boldsymbol {s o}, h} = \sum_ {p = 1} ^ {N _ {p}} \sum_ {l = 1} ^ {L} W _ {p l h q} \boldsymbol {v} _ {\boldsymbol {p} _ {q l} + \Delta \boldsymbol {p} _ {p l h q}} \tag {1}
+$$
+
+where $p, q, l$ and $h$ index the sampling offsets, elements of the deformable attention feature $\mathbf{z}^o$ , the scale of value $\mathbf{v}$ and attention head. $W_{plhq}$ is a value from the weight $\mathbf{W} \in \mathbb{R}^{N_q \times N_h \times L \times N_p}$ . $\mathbf{p} \in \mathbb{R}^{N_q \times L \times 2}$ and $\Delta \mathbf{p} \in \mathbb{R}^{N_q \times N_h \times L \times N_p \times 2}$ are the reference points and sampling offsets. $\mathbf{p}_{ql}$ and $\Delta \mathbf{p}_{plhq}$ denote the position of a single reference point and one of its corresponding sampling offsets respectively. The separate output features from $N_h$ attention heads are projected to the $q$ -th element of the final output deformable attention feature $\mathbf{z}^o$ by a linear layer expressed as
+
+$$
+\boldsymbol {z} _ {q} ^ {\boldsymbol {o}} = \sum_ {h = 1} ^ {N _ {h}} \boldsymbol {W} _ {h} ^ {\prime} \boldsymbol {z} _ {q} ^ {\boldsymbol {s o}, h} \tag {2}
+$$
+
+where $\pmb{W}_{h}^{\prime}\in \mathbb{R}^{c\times c_{v}}$ denotes the learnable weight for the $h$ -th attention head.
+
+Proposed Feature Enhancement Module: The features are enhanced owing to the self-attention mechanism to supplement the spatially adaptive features across multiple scales. The proposed module
+
+
+Figure 3: The overall architecture of the proposed feature enhancement module.
+
+simply consists of convolution/deconvolution and normalization layer pairs ahead of and after the deformable encoder and a final feature fusion step as illustrated in Figure 3. In this module, input feature maps from the backbone are first upsampled with deconvolution layers or encoded with the convolution layer to generate multi-scale feature maps $\{z^l\}_{l=1}^3$ . They are followed by group normalization to prevent the Internal Covariate Shift (ICS) that might be inducted by subsequent linear operations in the deformable encoder. The encoder yields enhanced multi-scale feature maps. Enhanced features are upsampled to keep the resolution as $(H/4, W/4)$ for accurate detection. They are normalized via L2Norm [22] before concatenation along the channel dimension. This makes the features at different scales contribute equally to the final feature representation fed into the detection head. Concatenated features are compressed along the channel dimension to reduce the network parameters. The output feature maps can be fed into the detection head used in SSD, CSP etc. Except for this standard structure, the use of convolution/deconvolution layers can be adjusted according to the resolution of input, and the concatenation step can be removed if predictions are made at separate levels.
+
+Training: For anchor-free cases, namely CSP, the loss function follows [22]. The overall loss consists of three parts as Equation(3) where $L_{c}$ , $L_{h}$ and $L_{o}$ stand for the center heatmap loss, height map loss and offset loss. Weights for each loss $\lambda_{c}$ , $\lambda_{s}$ and $\lambda_{o}$ are set as 0.01, 1 and 0.1 [22]. For anchor-based cases, namely SSD or ALFNet, the multi-task loss function is formulated with two objectives as Equation(4) [21] where $\lambda_{cls}$ is experimentally set as 0.01 in the following experiments.
+
+$$
+L _ {a f} = \lambda_ {c} L _ {c} + \lambda_ {s} L _ {h} + \lambda_ {o} L _ {o} \tag {3}
+$$
+
+$$
+L _ {a b} = \lambda_ {c l s} L _ {c l s} + L _ {l o c} \tag {4}
+$$
+
+Inference: For anchor-free single-stage methods, the predicted width is the height multiplied by the uniform aspect ratio 0.41 [22]. If not specified, bounding boxes with scores above 0.01 are kept and merged by Non-Maximum Suppression (NMS) with the IoU threshold of 0.5.
+
+# 4 Experiments
+
+# 4.1 Settings
+
+Datasets: The proposed detector is evaluated on two commonly used public pedestrian datasets: Caltech [44] and Citypersons [45]. The Caltech dataset is an approximately 10 hours of $480\mathrm{x}640$ video taken in a single urban city. The standard training set contains about $250\mathrm{k}$ frames with $350\mathrm{k}$ bounding boxes. In our experiments, the training data augmented by 10 folds containing 42782 images with 13674 persons and the standard test set containing 4024 images with corresponding new annotations [46] and fixed aspect-ratio for bounding boxes [47] are used. Citypersons training set recorded across 18 different cities, 3 seasons and various weather conditions with 19654 persons in 2975 high resolution (1024x2048) images. The validation set contains 500 images across 3 cities.
+
+Training Details: If not specified, the ResNet50/VGG16 pre-trained on ImageNet, Adam with moving average weights [48] and step learning rate schedule are applied. Data augmentation techniques including random horizontal flips with a probability of 0.5 and scaling are applied. For Caltech, additional random color distortion and cropping are implemented. The input images are rescaled to 336x448 and 640x1280 for Caltech and Citypersons datasets respectively. The detectors are trained with a single NVIDIA GeForce RTX 3090 GPU for 10 and 75 epochs with batch size 16 and 4 on Caltech and Citypersons respectively using the anchor-free CSP detection head. The base learning rate is 0.5e-4 and decreased by a factor of 0.5 after 6 and 60 epochs respectively. Initialization is performed with a randomly chosen and fixed seed. Tools provided by [47] are used in the experiments.
+
+Metrics: Log-average Miss Rate (denoted as $MR^{-2}$ or miss rate in this paper) over False Positive Per Image (FPPI) in the range $[10^{-2}, 10^{0}]$ is calculated over Reasonable, Small, Heavy, and All subsets defined in Table 1. The lower the $MR^{-2}$ the better.
+
+Table 1: The experimental settings of four subsets.
+
+| Subset | Reasonable | Small | Heavy | All |
| Height | [50, inf] | [50, 75] | [50, inf] | [20, inf] |
| Visibility | [0.65, inf] | [0.65, inf] | [0.2, 0.65] | [0.2, inf] |
+
+# 4.2 Ablation Experiments
+
+Effectiveness of Enhanced Feature Maps: For generality, the proposed module is applied to three commonly used single-stage structures in pedestrian detection: anchor-based, progressive refinement, and anchor-free.
+
+For anchor-based single-stage methods, like SSD300 [26], Table 2 shows that the proposed module shows stable and significant improvement in all three subsets with an IoU threshold of 0.5 in NMS.
+
+For refined anchors, we append two Convolutional Predictor Blocks [21] after the feature maps at the last three stages of the backbone and an extra stage. The second block refines the coarse anchors predicted by the first block. Table 3 demonstrates that even though the anchors are refined progressively to remedy the lack of proposal regions, the separate enhancement at each level can bring improvement in certain subsets (level 0 improves Reasonable and All subsets, level 1, 2 improves Heavy subset). The combination of multi-level inputs brings in stable improvement in all the subsets.
+
+For anchor-free methods, We evaluated the influence of the proposed module on the baseline CSP [22] detector on Caltech (Table 4) and Citypersons (Table 5). Results from both datasets indicate that with the enhanced feature maps, the miss rates are decreased significantly in Reasonable, Heavy and All subsets, in particular, the Heavy subset witnesses a decrease of up to $7.9\%$ , and the Reasonable subset up to $3.1\%$ . The additional enhancement module increases the inference time, however, they contain fewer learnable parameters as shown in Table 6. As the combination of CSP achieves the best results, subsequent experiments follow this implementation.
+
+According to the above, the proposed module is effective for general single-stage detectors on pedestrian datasets, owing to the multi-scale deformable self-attention mechanism to enhance spatially adaptive features across levels.
+
+Table 2: Comparison of the SSD300 detector w/o the proposed feature enhancement module on Caltech test set with input size ${300} \times {300}$ .
+
+| Methods | IoU | Enhanced feature levels | Reasonable | Heavy | All |
| 1 | 2 | 3 | 4 | 5 |
| SSD300 | 0.5 | | | \ | | | 28.6 | 70.7 | 72.3 |
| 0.25 | | | | | | 27.1 | 71.3 | 71.2 |
| + Enhancement module | 0.5 | | | | | ✓ | 24.9 | 69.3 | 71.0 |
| 0.25 | | | | | | 26.2 | 70.2 | 71.3 |
| 0.5 | | | | ✓ | | 25.1 | 68.4 | 71.3 |
| 0.25 | | | | | | 26.9 | 69.1 | 71.6 |
| 0.5 | ✓ | ✓ | ✓ | | | 22.6 | 68.5 | 71.0 |
| 0.25 | ✓ | ✓ | ✓ | | | 24.9 | 67.7 | 71.2 |
| 0.5 | ✓ | ✓ | | | | 23.9 | 68.4 | 72.2 |
| 0.25 | ✓ | ✓ | | | | 25.6 | 69.1 | 72.6 |
| 0.5 | ✓ | | | | | 23.5 | 68.7 | 71.4 |
| 0.25 | ✓ | | | | | 24.4 | 71.0 | 71.8 |
+
+Feature Maps Scales: Different combinations of multi-scale feature maps $\{z^l\}_{l=1}^3$ with three downsampling ratios (1/4, 1/8 and 1/16) are compared in Table 7. In this comparison, only $z_3^o$
+
+Table 3: Comparison of the progressive refinement detector w/o the proposed feature enhancement module on Caltech test set with input size $480 \times 640$ .
+
+ | Enhanced feature levels | Reasonable | Heavy | All |
| 1 | 2 | 3 |
| Progressive refinement | | | \ | 13.4 | 61.3 | 61.9 |
| ✓ | ✓ | ✓ | 12.3 | 60.8 | 61.2 |
| + Enhancement module | | | ✓ | 13.9 | 59.2 | 61.7 |
| | ✓ | | 13.5 | 60.0 | 62.7 |
| ✓ | | | 12.4 | 61.5 | 59.8 |
+
+Table 4: Comparison of the baseline CSP detector and the proposed detectors with the enhancement module on Caltech test set. FPS stands for frames per second evaluated during test process with input size 480x640.
+
+ | Reasonable | Heavy | All | FPS |
| CSP | 6.8 | 50.7 | 62.3 | 39.2 |
| + Enhancement module | 3.7 (3.1↓) | 42.8 (7.9↓) | 56.97 (5.3↓) | 29.5 |
+
+which has the same resolution as $z^3$ is upsampled to $(H / 4, W / 4)$ , and is fed into the detection head without intermediate concatenation and L2Norm. Results show that feature maps with ratios $1 / 4$ , $1 / 8$ , and $1 / 6$ for each scale produce the best performance, which is yielded by upsampling $c_1$ and $c_2$ by two times while maintaining the scale of $c_3$ .
+
+Enhanced Feature Map Scales: Fix the downsampling ratios of $\{z^l\}_{l=1}^3$ as $1/4, 1/8,$ and $1/16,$ feed different collections of multi-scale enhanced feature maps $\{z_l^o\}_{l=1}^3$ to the detection head. Note that the deformable encoder keeps the resolutions of the input feature maps, the downsampling ratios for $\{z_l^o\}_{l=1}^3$ are $1/4, 1/8$ and $1/6$ respectively. All the enhanced feature maps are first upsampled to $(H/4, W/4)$ if needed, followed by normalization when multiple feature maps are utilized. They are then processed in three ways: 1. Cat: Concatenate them along the channel dimension followed by a compression layer to reduce the number of channels to 256. 2. Add: Implement element-wise sum of the enhanced feature maps. 3. Sep: No fusion operations across multi-scales; send them separately to the detection head which doubles the number of predictions. Table 8 compares various strategies to fuse the multi-scale enhanced feature maps. It shows that concatenation followed by L2Norm produces the overall best results in both Reasonable and Heavy subsets on the Caltech test set.
+
+Choice of the Normalization Method Applied to $\{c^l\}_{l=1}^3$ : As Table 8 shows, GN performs best in the Reasonable subset while L2N in the Heavy subset. Considering that the miss rate of GN is $11.6\%$ lower in the Reasonable subset and only $1.2\%$ higher in the Heavy subset compared to L2N, GN is utilized in our experiments before the encoder as presented in Figure 3.
+
+Number of Encoders: Based on the settings in the last part, different numbers of encoders are tested. These encoders are connected in series. Table 9 presents that although more encoders can provide higher-level semantic information, the best result is observed when only a single encoder is applied. This phenomenon supports the design of BotNet [41] to some extent, which indicates that following the whole set of six encoders and decoders in (deformable) DETR may not be suitable for specific
+
+Table 5: Comparison of the baseline CSP detector and the proposed detectors with the enhancement module on Citypersons validation set. FPS stands for frames per second. FPS stands for frames per second evaluated during test process with input size 1024x2048.
+
+ | Reasonable | Small | Heavy | All | FPS |
| CSP | 11.7 | 14.4 | 41.8 | 38.2 | 8.2 |
| + Enhancement module | 10.9 (0.8↓) | 13.7 (0.7↓) | 38.6 (3.2↓) | 37.2 (1.0↓) | 6.8 |
+
+Table 6: The number of learnable parameters in the baseline and proposed detectors.
+
+ | Backbone | Neck | Head | Total Param |
| CSP | 23.51 M | 14.68 M | 1.77 M | 39.96 M |
| + Enhancement module | 23.51 M | 8.73 M | 1.03 K | 32.24 M |
+
+Table 7: Combinations of different resolutions of input feature maps fed into the encoder.
+
+| z1 | z2 | z3 | Reasonable | Heavy |
| 1/4 | 1/8 | 1/16 | 4.1 | 44.7 |
| 1/4 | 1/16 | 1/16 | 4.2 | 45.9 |
| 1/8 | 1/8 | 1/16 | 4.6 | 48.5 |
| 1/4 | 1/8 | 1/8 | 5.9 | 47.8 |
+
+object detection tasks. A single encoder can also work effectively with the least number of learnable parameters, which prevents overfitting.
+
+# 4.3 Comparison with the state-of-the-arts
+
+Table 10 and Table 11 show that the proposed module achieves the lowest miss rates in Reasonable and Heavy subsets and leading performance in the All subset on both datasets among presented single-stage detectors.
+
+For the Caltech dataset, the lowest miss rate $(3.7\%)$ of the proposed detector in the Reasonable subset is $0.2\%$ smaller than that of the two-stage KGSNet presented in the upper part of Table 10. With pretraining on the Citypersons dataset, the miss rates on all three subsets of the Caltech dataset are reduced significantly and reach the lowest compared to other pretrained detectors as shown in the bottom part of Table 10. For the Citypersons dataset, the proposed two detectors even outperform the competitive two-stage detectors in the Reasonable and especially Heavy subset with a miss rate of $38.6\%$ which is $1.1\%$ lower than that of the best of two-stage detectors.
+
+Overall, with the enhanced spatially adaptive and multi-scale features, the gap between single- and two-stage detectors in Reasonable and Heavy subsets on different detectors has been narrowed. Surprisingly, the proposed single-stage method outperforms the accurate two-stage methods on certain pedestrian datasets, such as the Citypersons dataset. It should be noted that two-stage methods usually produce overall better accuracy than single-stage methods with the advantage of the region proposal network and refined bounding boxes and at the expense of inference time. Apart from accuracy, fast inference also matters for pedestrian detection in practical scenes. The combination of CSP and the proposed module has a simple structure, which is easy to perform and effective. On the contrary, the leading two-stage KGSNet, for example, takes advantage of the additional proposal
+
+Table 8: Combinations of enhanced feature maps with different scales in different ways followed by three Normalization Methods (NM). L2N, LN and GN stand for L2Norm, Layer Normalization and Group Normalization respectively. Train boldly without any learning rate schedules. Normalization methods applied to the enhanced feature maps after deconvolution. Normalization methods applied to the feature maps produced by the backbone before being sent to the encoder.
+
+| zo1 | ✓ | | | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
| zo2 | | ✓ | | | | | | | | | | | | | ✓ |
| zo3 | | | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
| Cat | | | | | | | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
| Add | | | | ✓ | ✓ | | | | | | | | | | |
| Sep | | | | | | ✓ | | | | | | | | | |
| NM2 | | | | | L2N | L2N | | GN1 | LN1 | L2N1 | L2N | L2N | L2N | L2N | L2N |
| NM3 | GN | GN | GN | GN | GN | GN | GN | GN | GN | GN | GN | L2N | BN | GN | GN |
| Reasonable | 4.3 | 5.7 | 4.1 | 7.0 | 3.7 | 4.2 | 5.9 | 6.4 | 4.0 | 3.9 | 3.7 | 4.3 | 4.5 | 5.3 | |
| Heavy | 44.5 | 48.8 | 44.7 | 51.3 | 45.5 | 48.1 | 50.7 | 49 | 47.4 | 44.5 | 42.8 | 42.6 | 44.6 | 44.1 | |
+
+Table 9: Using 1 to 4 encoders in the detection neck.
+
+| Number of encoders | 1 | 2 | 3 | 4 |
| Reasonable | 3.7 | 4.9 | 4.8 | 5.5 |
| Heavy | 42.8 | 46.6 | 43.1 | 45.1 |
+
+Table 10: Comparison with the state-of-the-art single- and two-stage pedestrian detectors on Caltech test set. Results reported by [22]. Bottom part: Pretrained on Citypersons and tested on Caltech. The best and second-best results are in bold and underlined with red for two-stage methods (upper part) and black for single-stage methods.
+
+| Method | Backbone | Stage | Reasonable | Heavy | All |
| Faster R-CNN† [37] | ResNet50 | 2 | 8.7 | 53.1 | 62.6 |
| ALFNet† [21] | ResNet50 | 1 | 8.1 | 51.0 | 59.1 |
| RPN+BF† [49] | VGG16 | 2 | 7.3 | 54.6 | 59.9 |
| RepLoss† [14] | ResNet50 | 2 | 5.0 | 47.9 | 59.0 |
| CSP [22] | ResNet50 | 1 | 4.5 | 45.8 | 56.9 |
| KGSNet [18] | ResNet50 | 2 | 3.9 | 34.2 | 42.2 |
| JointDet [50] | ResNet50 | 2 | 3.0 | - | - |
| PedHunter [10] | ResNet50 | 2 | 2.3 | - | - |
| CSP+Proposed module | ResNet50 | 1 | 3.7 | 42.8 | 56.97 |
| ALFNet† [21] | ResNet50 | 1 | 4.5 | 43.4 | 56.8 |
| RepLoss† [14] | ResNet50 | 2 | 4.0 | 41.8 | 58.6 |
| CSP [22] | ResNet50 | 1 | 3.8 | 36.5 | 54.4 |
| CSP+Proposed module | ResNet50 | 1 | 2.6 | 28.0 | 53.9 |
+
+generation network, the refined bounding boxes, the key-point detector and the super-resolution network. With these components, the inference speed of KGSNet is 5.9 FPS and 3.2 FPS (Titan X GPU, not including the time of using ALFNet to generate the candidate proposals) on Caltech and Citypersons datasets [18] while ours achieves 29.5 FPS and 6.8 FPS (RTX 3090 GPU) respectively. Therefore, the enhanced single-stage pedestrian detector is cost-effective with fast inference and competitive accuracy compared to complicated two-stage methods.
+
+Table 11: Comparison with the state-of-the-art pedestrian detectors on Citypersons validation set. ${}^{ \dagger }$ Results reported by [22]. ${}^{1}$ Less than ${65}\%$ visibility instead of ${20} - {65}\%$ visibility. The best and second-best results are in bold and underlined with red for two-stage methods and black for single-stage methods.
+
+| Method | Backbone | Stage | Reasonable | Heavy | All |
| FRCNN†[45] | VGG16 | 2 | 15.4 | - | - |
| FRCNN+Seg†[45] | VGG16 | 2 | 14.8 | - | - |
| TLL+MRF[23] | ResNet50 | 1 | 14.4 | 52.0 | - |
| OR-CNN[15] | VGG16 | 2 | 12.8 | 55.71 | - |
| RepLoss[14] | ResNet50 | 2 | 13.2 | 56.91 | - |
| ALFNet[21] | ResNet50 | 1 | 12.0 | 51.9 | - |
| CSP[22] | ResNet50 | 1 | 11.0 | 49.3 | - |
| PRNet[24] | ResNet50 | 1 | 10.8 | 42.0 | - |
| MGAN+[17] | VGG16 | 2 | 11.0 | 39.7 | - |
| KGSNet[18] | ResNet50 | 2 | 11.0 | 39.7 | 36.2 |
| CSP+Proposed module | ResNet50 | 1 | 10.9 | 38.6 | 37.2 |
+
+# 5 Conclusion
+
+The paper proposes a module to enhance spatial and multi-scale features based on a single encoder of the deformable vision transformer to improve the detection accuracy of single-stage pedestrian detectors with fast inference. This module is effective on commonly used single-stage structures, including (progressively refined) anchor-based and anchor-free cases. With the CSP detection head, more than $40\%$ parameters are reduced in the detection neck compared to CSP; however, this combination still achieves the best results in Reasonable and Heavy subsets among presented single-stage detectors on both Caltech and Citypersons datasets. Utilising pre-training, the miss rates for these subsets can be decreased to $2.6\%$ and $28.0\%$ , respectively, which are far better than other single-stage methods and comparable to two-stage methods. The proposed method outperforms SOTA two-stage detectors in the Heavy subset by $1.1\%$ on Citypersons with slightly decreased inference speed. This demonstrates that single-stage detectors can be improved if spatially adaptive and multi-scale features are jointly adopted, making them cost-effective and promising. It should be mentioned that false positives appear if the attention points of a negative reference point extend to the target areas. Although the performance has been improved with the current module, the generation of attention weights and sampling locations can be carefully designed to suppress the false positives for further improvements.
+
+# References
+
+[1] Jiale Cao, Yanwei Pang, Jin Xie, Fahad Shahbaz Khan, and Ling Shao. From handcrafted to deep features for pedestrian detection: a survey. IEEE transactions on pattern analysis and machine intelligence, 2021.
+[2] Wei Li, Xiatian Zhu, and Shaogang Gong. Harmonious attention network for person re-identification. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 2285–2294, 2018.
+[3] Yulin Li, Jianfeng He, Tianzhu Zhang, Xiang Liu, Yongdong Zhang, and Feng Wu. Diverse part discovery: Occluded person re-identification with part-aware transformer. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 2898–2907, 2021.
+[4] Yichao Yan, Jinpeng Li, Jie Qin, Song Bai, Shengcai Liao, Li Liu, Fan Zhu, and Ling Shao. Anchor-free person search. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 7690-7699, 2021.
+[5] Yanjie Li, Shoukui Zhang, Zhicheng Wang, Sen Yang, Wankou Yang, Shu-Tao Xia, and Erjin Zhou. Tokenpose: Learning keypoint tokens for human pose estimation. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 11313-11322, 2021.
+[6] Lianghua Huang, Xin Zhao, and Kaiqi Huang. Bridging the gap between detection and tracking: A unified approach. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 3999-4009, 2019.
+[7] Zhilu Chen and Xinming Huang. Pedestrian detection for autonomous vehicle using multispectral cameras. IEEE Transactions on Intelligent Vehicles, 4(2):211-219, 2019.
+[8] Antonin Vobecky, Michal Uricár, David Hurych, and Radoslav Skoviera. Advanced pedestrian dataset augmentation for autonomous driving. In Proceedings of the IEEE/CVF International Conference on Computer Vision Workshops, 2019.
+[9] Quanzheng Mou, Longsheng Wei, Conghao Wang, Dapeng Luo, Songze He, Jing Zhang, Huimin Xu, Chen Luo, and Changxin Gao. Unsupervised domain-adaptive scene-specific pedestrian detection for static video surveillance. Pattern Recognition, 118:108038, 2021.
+[10] Cheng Chi, Shifeng Zhang, Junliang Xing, Zhen Lei, Stan Z Li, and Xudong Zou. Pedhunter: Occlusion robust pedestrian detector in crowded scenes. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 10639-10646, 2020.
+[11] Chunze Lin, Jiwen Lu, and Jie Zhou. Multi-grained deep feature learning for robust pedestrian detection. IEEE Transactions on Circuits and Systems for Video Technology, 29(12):3608-3621, 2018.
+[12] T. Liu, W. Luo, L. Ma, J. J. Huang, T. Stathaki, and T. Dai. Coupled network for robust pedestrian detection with gated multi-layer feature extraction and deformable occlusion handling. IEEE Transactions on Image Processing, 30:754-766, 2021.
+[13] Yanwei Pang, Jin Xie, Muhammad Haris Khan, Rao Muhammad Anwer, Fahad Shahbaz Khan, and Ling Shao. Mask-guided attention network for occluded pedestrian detection. In Proceedings of the IEEE/CVF international conference on computer vision, pages 4967-4975, 2019.
+[14] Xinlong Wang, Tete Xiao, Yuning Jiang, Shuai Shao, Jian Sun, and Chunhua Shen. Repulsion loss: Detecting pedestrians in a crowd. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 7774-7783, 2018.
+[15] Shifeng Zhang, Longyin Wen, Xiao Bian, Zhen Lei, and Stan Z Li. Occlusion-aware r-cnn: detecting pedestrians in a crowd. In Proceedings of the European Conference on Computer Vision (ECCV), pages 637-653, 2018.
+[16] Ross Girshick. Fast r-cnn. In Proceedings of the IEEE international conference on computer vision, pages 1440-1448, 2015.
+
+[17] Jin Xie, Yanwei Pang, Muhammad Haris Khan, Rao Muhammad Anwer, Fahad Shahbaz Khan, and Ling Shao. Mask-guided attention network and occlusion-sensitive hard example mining for occluded pedestrian detection. IEEE Transactions on Image Processing, 30:3872-3884, 2020.
+[18] Y. Zhang, Y. Bai, M. Ding, S. Xu, and B. Ghanem. Kgsnet: Key-point-guided super-resolution network for pedestrian detection in the wild. IEEE Transactions on Neural Networks and Learning Systems, 32(5):2251-2265, 2021.
+[19] Joseph Redmon and Ali Farhadi. Yolov3: An incremental improvement. arXiv preprint arXiv:1804.02767, 2018.
+[20] Chunze Lin, Jiwen Lu, Gang Wang, and Jie Zhou. Graininess-aware deep feature learning for pedestrian detection. In Proceedings of the European conference on computer vision (ECCV), pages 732-747, 2018.
+[21] Wei Liu, Shengcai Liao, Weidong Hu, Xuezhi Liang, and Xiao Chen. Learning efficient single-stage pedestrian detectors by asymptotic localization fitting. In Proceedings of the European Conference on Computer Vision (ECCV), pages 618-634, 2018.
+[22] Wei Liu, Shengcai Liao, Weiqiang Ren, Weidong Hu, and Yinan Yu. High-level semantic feature detection: A new perspective for pedestrian detection. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 5187-5196, 2019.
+[23] Tao Song, Leiyu Sun, Di Xie, Haiming Sun, and Shiliang Pu. Small-scale pedestrian detection based on topological line localization and temporal feature aggregation. In Proceedings of the European Conference on Computer Vision (ECCV), pages 536-551, 2018.
+[24] Xiaolin Song, Kaili Zhao, Wen-Sheng Chu, Honggang Zhang, and Jun Guo. Progressive refinement network for occluded pedestrian detection. In European Conference on Computer Vision, pages 32-48. Springer, 2020.
+[25] Hong-hui Xu, Xin-qing Wang, Dong Wang, Bao-guo Duan, and Ting Rui. Object detection in crowded scenes via joint prediction. Defence Technology, 2021.
+[26] Wei Liu, Dragomir Anguelov, Dumitru Erhan, Christian Szegedy, Scott Reed, Cheng-Yang Fu, and Alexander C Berg. Ssd: Single shot multibox detector. In European conference on computer vision (ECCV), pages 21-37. Springer, 2016.
+[27] Jun Ma, Honglin Wan, Junxia Wang, Hao Xia, and Chengjie Bai. An improved one-stage pedestrian detection method based on multi-scale attention feature extraction. Journal of Real-Time Image Processing, 18(6):1965-1978, 2021.
+[28] Jun Ma, Honglin Wan, Junxia Wang, Hao Xia, and Chengjie Bai. An improved scheme of deep dilated feature extraction on pedestrian detection. Signal, Image and Video Processing, 15(2):231-239, 2021.
+[29] Binjie Ruan and Chongyang Zhang. Occluded pedestrian detection combined with semantic features. IET Image Process, 15(10):2292-2300, 2021.
+[30] Yuzhi Tan, Hongxun Yao, Haoran Li, Xiusheng Lu, and Haozhe Xie. Prf-ped: Multi-scale pedestrian detector with prior-based receptive field. In 2020 25th International Conference on Pattern Recognition (ICPR), pages 6059-6064. IEEE, 2021.
+[31] Hao Xia, Honglin Wan, Jiayu Ou, Jun Ma, Xinyao Lv, and Chengjie Bai. Mafa-net: pedestrian detection network based on multi-scale attention feature aggregation. Applied Intelligence, 52(7):7686-7699, 2022.
+[32] Yao Xu and Qin Yu. Adaptive weighted multi-level fusion of multi-scale features: A new approach to pedestrian detection. Future Internet, 13(2):38, 2021.
+[33] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, and Sylvain Gelly. An image is worth 16x16 words: Transformers for image recognition at scale. arXiv preprint arXiv:2010.11929, 2020.
+
+[34] Ze Liu, Yutong Lin, Yue Cao, Han Hu, Yixuan Wei, Zheng Zhang, Stephen Lin, and Baining Guo. Swin transformer: Hierarchical vision transformer using shifted windows. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 10012-10022, 2021.
+[35] Nicolas Carion, Francisco Massa, Gabriel Synnaeve, Nicolas Usunier, Alexander Kirillov, and Sergey Zagoruyko. End-to-end object detection with transformers. In European conference on computer vision, pages 213-229. Springer, 2020.
+[36] Xizhou Zhu, Weijie Su, Lewei Lu, Bin Li, Xiaogang Wang, and Jifeng Dai. Deformable detr: Deformable transformers for end-to-end object detection. arXiv preprint arXiv:2010.04159, 2020.
+[37] S. Ren, K. He, R. Girshick, and J. Sun. Faster r-cnn: Towards real-time object detection with region proposal networks. IEEE Transactions on Pattern Analysis and Machine Intelligence, 39(6):1137-1149, 2017.
+[38] Tsung-Yi Lin, Michael Maire, Serge Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dólár, and C Lawrence Zitnick. Microsoft coco: Common objects in context. In European conference on computer vision, pages 740-755. Springer, 2014.
+[39] Shuai Shao, Zijian Zhao, Boxun Li, Tete Xiao, Gang Yu, Xiangyu Zhang, and Jian Sun. Crowdhuman: A benchmark for detecting human in a crowd. arXiv preprint arXiv:1805.00123, 2018.
+[40] Matthieu Lin, Chuming Li, Xingyuan Bu, Ming Sun, Chen Lin, Junjie Yan, Wanli Ouyang, and Zhidong Deng. Detr for crowd pedestrian detection. arXiv preprint arXiv.:06785, 2020.
+[41] Aravind Srinivas, Tsung-Yi Lin, Niki Parmar, Jonathon Shlens, Pieter Abbeel, and Ashish Vaswani. Bottleneck transformers for visual recognition. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 16519-16529, 2021.
+[42] 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, pages 770-778, 2016.
+[43] Olga Russakovsky, Jia Deng, Hao Su, Jonathan Krause, Sanjeev Satheesh, Sean Ma, Zhiheng Huang, Andrej Karpathy, Aditya Khosla, and Michael Bernstein. Imagenet large scale visual recognition challenge. International journal of computer vision, 115(3):211-252, 2015.
+[44] Piotr Dollar, Christian Wojek, Bernt Schiele, and Pietro Perona. Pedestrian detection: An evaluation of the state of the art. IEEE transactions on pattern analysis and machine intelligence, 34(4):743-761, 2011.
+[45] Shanshan Zhang, Rodrigo Benenson, and Bernt Schiele. Citypersons: A diverse dataset for pedestrian detection. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 3213-3221, 2017.
+[46] Shanshan Zhang, Rodrigo Benenson, Mohamed Omran, Jan Hosang, and Bernt Schiele. How far are we from solving pedestrian detection? In Proceedings of the iEEE conference on computer vision and pattern recognition, pages 1259-1267, 2016.
+[47] Irtiza Hasan, Shengcai Liao, Jinpeng Li, Saad Ullah Akram, and Ling Shao. Generalizable pedestrian detection: The elephant in the room. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 11328-11337, 2021.
+[48] Antti Tarvainen and Harri Valpola. Mean teachers are better role models: Weight-averaged consistency targets improve semi-supervised deep learning results. Advances in neural information processing systems, 30, 2017.
+[49] Liliang Zhang, Liang Lin, Xiaodan Liang, and Kaiming He. Is faster r-cnn doing well for pedestrian detection? In European conference on computer vision, pages 443-457. Springer, 2016.
+[50] Cheng Chi, Shifeng Zhang, Junliang Xing, Zhen Lei, Stan Z Li, and Xudong Zou. Relational learning for joint head and human detection. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 10647-10654, 2020.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential negative societal impacts of your work? [No]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [No]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [No]
+(c) Did you include any new assets either in the supplemental material or as a URL? [No]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [Yes] The data are available online.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [No]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/images.zip b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..21455236b3eb8776c8246929cdd013979a7e5a22
--- /dev/null
+++ b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:87d5ec49ede4e4df3f01c5859bf33aed1a0bec61ac8b04fcddfbfa699aa31d5a
+size 405395
diff --git a/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/layout.json b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..dbccd786411cd0209c3eafb229997f9d645cdfa9
--- /dev/null
+++ b/effectivenessofvisiontransformerforfastandaccuratesinglestagepedestriandetection/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:389d858f19f675be09723539bd6c5869268ef7801aab0b6fe68d5cf8749cab66
+size 387168
diff --git a/effectsofdatageometryinearlydeeplearning/f0cc57a5-996b-44f9-a5fe-bb4f85094f35_content_list.json b/effectsofdatageometryinearlydeeplearning/f0cc57a5-996b-44f9-a5fe-bb4f85094f35_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..b7dcd3c4c76256a684d406818234437d8e0870fe
--- /dev/null
+++ b/effectsofdatageometryinearlydeeplearning/f0cc57a5-996b-44f9-a5fe-bb4f85094f35_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5383e2e9f89bcc630a920438f8400b8e5ee138987041362be1cb1bee8e6617fb
+size 84072
diff --git a/effectsofdatageometryinearlydeeplearning/f0cc57a5-996b-44f9-a5fe-bb4f85094f35_model.json b/effectsofdatageometryinearlydeeplearning/f0cc57a5-996b-44f9-a5fe-bb4f85094f35_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..35c095bec98758a6e9b38da956ccd63a3b0110f0
--- /dev/null
+++ b/effectsofdatageometryinearlydeeplearning/f0cc57a5-996b-44f9-a5fe-bb4f85094f35_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:582ebac32de8c7cbc09a34bd3df2bebcf641318f59515009abb2db5e4039101c
+size 112001
diff --git a/effectsofdatageometryinearlydeeplearning/f0cc57a5-996b-44f9-a5fe-bb4f85094f35_origin.pdf b/effectsofdatageometryinearlydeeplearning/f0cc57a5-996b-44f9-a5fe-bb4f85094f35_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..4e9f8cc9112f7bf753422d5298931babd7892092
--- /dev/null
+++ b/effectsofdatageometryinearlydeeplearning/f0cc57a5-996b-44f9-a5fe-bb4f85094f35_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:64f0496bbd0123848ac676dd199f48b891bdf5b9c8e114f6a748453ce8ef21c2
+size 1375011
diff --git a/effectsofdatageometryinearlydeeplearning/full.md b/effectsofdatageometryinearlydeeplearning/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..51dfbb1068f29974495779da6e0a21f614292534
--- /dev/null
+++ b/effectsofdatageometryinearlydeeplearning/full.md
@@ -0,0 +1,362 @@
+# Effects of Data Geometry in Early Deep Learning
+
+Saket Tiwari
+
+Department of Computer Science
+
+Brown University
+
+Providence, RI 02906
+
+saket_tiwari@brown.edu
+
+George Konidaris
+
+Department of Computer Science
+
+Brown University
+
+Providence, RI 02906
+
+# Abstract
+
+Deep neural networks can approximate functions on different types of data, from images to graphs, with varied underlying structure. This underlying structure can be viewed as the geometry of the data manifold. By extending recent advances in the theoretical understanding of neural networks, we study how a randomly initialized neural network with piece-wise linear activation splits the data manifold into regions where the neural network behaves as a linear function. We derive bounds on the density of boundary of linear regions and the distance to these boundaries on the data manifold. This leads to insights into the expressivity of randomly initialized deep neural networks on non-Euclidean data sets. We empirically corroborate our theoretical results using a toy supervised learning problem. Our experiments demonstrate that number of linear regions varies across manifolds and the results hold with changing neural network architectures. We further demonstrate how the complexity of linear regions is different on the low dimensional manifold of images as compared to the Euclidean space, using the MetFaces dataset.
+
+# 1 Introduction
+
+The capacity of Deep Neural Networks (DNNs) to approximate arbitrary functions given sufficient training data in the supervised learning setting is well known [Cybenko, 1989, Hornik et al., 1989, Anthony and Bartlett, 1999]. Several different theoretical approaches have emerged that study the effectiveness and pitfalls of deep learning. These studies vary in their treatment of neural networks and the aspects they study range from convergence [Allen-Zhu et al., 2019, Goodfellow and Vinyals, 2015], generalization [Kawaguchi et al., 2017, Zhang et al., 2017, Jacot et al., 2018, Sagun et al., 2018], function complexity [Montúfar et al., 2014, Mhaskar and Poggio, 2016], adversarial attacks [Szegedy et al., 2014, Goodfellow et al., 2015] to representation capacity [Arpit et al., 2017]. Some recent theories have also been shown to closely match empirical observations [Poole et al., 2016, Hanin and Rolnick, 2019b, Kunin et al., 2020].
+
+One approach to studying DNNs is to examine how the underlying structure, or geometry, of the data interacts with learning dynamics. The manifold hypothesis states that high-dimensional real world data typically lies on a low dimensional manifold [Tenenbaum, 1997, Carlsson et al., 2007, Fefferman et al., 2013]. Empirical studies have shown that DNNs are highly effective in deciphering this underlying structure by learning intermediate latent representations [Poole et al., 2016]. The ability of DNNs to "flatten" complex data manifolds, using composition of seemingly simple piece-wise linear functions, appears to be unique [Brahma et al., 2016, Hauser and Ray, 2017].
+
+DNNs with piece-wise linear activations, such as ReLU [Nair and Hinton, 2010], divide the input space into linear regions, wherein the DNN behaves as a linear function [MontuFar et al., 2014]. The density of these linear regions serves as a proxy for the DNN's ability to interpolate a complex data landscape and has been the subject of detailed studies [MontuFar et al., 2014, Telgarsky, 2015, Serra
+
+et al., 2018, Raghu et al., 2017]. The work by Hanin and Rolnick [2019a] on this topic stands out because they derive bounds on the average number of linear regions and verify the tightness of these bounds empirically for deep ReLU networks, instead of larger bounds that rarely materialize. Hanin and Rolnick [2019a] conjecture that the number of linear regions correlates to the expressive power of randomly initialized DNNs with piece-wise linear activations. However, they assume that the data is uniformly sampled from the Euclidean space $\mathbb{R}^d$ , for some $d$ . By combining the manifold hypothesis with insights from Hanin and Rolnick [2019a], we are able to go further in estimating the number of linear regions and the average distance from linear boundaries. We derive bounds on how the geometry of the data manifold affects the aforementioned quantities.
+
+To corroborate our theoretical bounds with empirical results, we design a toy problem where the input data is sampled from two distinct manifolds that can be represented in a closed form. We count the exact number of linear regions and the average distance to the boundaries of linear regions on these two manifolds that a neural network divides the two manifolds into. We demonstrate how the number of linear regions and average distance varies for these two distinct manifolds. These results show that the number of linear regions on the manifold do not grow exponentially with the dimension of input data. Our experiments do not provide estimates for theoretical constants, as in most deep learning theory, but demonstrate that the number of linear regions change as a consequence of these constants. We also study linear regions of deep ReLU networks for high dimensional data that lies on a low dimensional manifold with unknown structure and how the number of linear regions vary on and off this manifold, which is a more realistic setting. To achieve this we present experiments performed on the manifold of natural face images. We sample data from the image manifold using a generative adversarial network (GAN) [Goodfellow et al., 2014] trained on the curated images of paintings. Specifically, we generate images using the pre-trained StyleGAN [Karras et al., 2019, 2020b] trained on the curated MetFaces dataset [Karras et al., 2020a]. We generate curves on the image manifold of faces, using StyleGAN, and report how the density of linear regions varies on and off the manifold. These results shed new light on the geometry of deep learning over structured data sets by taking a data intrinsic approach to understanding the expressive power of DNNs.
+
+# 2 Preliminaries and Background
+
+Our goal is to understand how the underlying structure of real world data matters for deep learning. We first provide the mathematical background required to model this underlying structure as the geometry of data. We then provide a summary of previous work on understanding the approximation capacity of deep ReLU networks via the complexity of linear regions. For the details on how our work fits into one of the two main approaches within the theory of DNNs, from the expressive power perspective or from the learning dynamics perspective, we refer the reader to Appendix C.
+
+# 2.1 Data Manifold and Definitions
+
+
+Figure 1: A 2D surface, here represented by a 2-torus, is embedded in a larger input space, $\mathbb{R}^3$ . Suppose each point corresponds to an image of a face on this 2-torus. We can chart two curves: one straight line cutting across the 3D space and another curve that stays on the torus. Images corresponding to the points on the torus will have a smoother variation in style and shape whereas there will be images corresponding to points on the straight line that are not faces.
+
+We use the example of the MetFaces dataset [Karras et al., 2020a] to illustrate how data lies on a low dimensional manifold. The images in the dataset are $1028 \times 1028 \times 3$ dimensional. By contrast, the number of realistic dimensions along which they vary are limited, e.g. painting style, artist, size and shape of the nose, jaw and eyes, background, clothing style; in fact, very few $1028 \times 1028 \times 3$ dimensional images correspond to realistic faces. We illustrate how this affects the possible variations in the data in Figure 1. A manifold formalises the notion of limited variations in high dimensional data. One can imagine that there exists an unknown function $f: X \to Y$ from a low dimensional space of variations, to a high dimensional space of the actual data points. Such a function $f: X \to Y$ , from one open subset $X \subset \mathbb{R}^m$ , to another open subset $Y \subset R^k$ , is a diffeomorphism if $f$ is bijective, and both $f$ and $f^{-1}$ are differentiable (or smooth). Therefore, a manifold is defined as follows.
+
+Definition 2.1. Let $k, m \in \mathbb{N}_0$ . A subset $M \subset \mathbb{R}^k$ is called a smooth $m$ -dimensional submanifold of $\mathbb{R}^k$ (or $m$ -manifold in $\mathbb{R}^k$ ) iff every point $x \in M$ has an open neighborhood $U \subset \mathbb{R}^k$ such that $U \cap M$ is diffeomorphic to an open subset $\Omega \subset \mathbb{R}^m$ . A diffeomorphism (i.e. differentiable mapping),
+
+$$
+f: U \cap M \to \Omega
+$$
+
+is called a coordinate chart of $M$ and the inverse,
+
+$$
+h := f ^ {- 1}: \Omega \to U \cap M
+$$
+
+is called a smooth parametrization of $U\cap M$
+
+For the MetFaces dataset example, suppose there are 10 dimensions along which the images vary. Further assume that each variation can take a value continuously in some interval of $\mathbb{R}$ . Then the smooth parametrization would map $f:\Omega \cap \mathbb{R}^{10}\to M\cap \mathbb{R}^{1028\times 1028\times 3}$ . This parametrization and its inverse are unknown in general and computationally very difficult to estimate in practice.
+
+There are similarities in how geometric elements are defined for manifolds and Euclidean spaces. A smooth curve, on a manifold $M$ , $\gamma : I \to M$ is defined from an interval $I$ to the manifold $M$ as a function that is differentiable for all $t \in I$ , just as for Euclidean spaces. The shortest such curve between two points on a manifold is no longer a straight line, but is instead a geodesic. One recurring geometric element, which is unique to manifolds and stems from the definition of smooth curves, is that of a tangent space, defined as follows.
+
+Definition 2.2. Let $M$ be an $m$ -manifold in $\mathbb{R}^k$ and $x \in M$ be a fixed point. A vector $v \in \mathbb{R}^k$ is called a tangent vector of $M$ at $x$ if there exists a smooth curve $\gamma : I \to M$ such that $\gamma(0) = x, \dot{\gamma}(0) = v$ where $\dot{\gamma}(t)$ is the derivative of $\gamma$ at $t$ . The set
+
+$$
+T _ {x} M := \{\dot {\gamma} (0) | \gamma : \mathbb {R} \rightarrow M i s s m o o t h \gamma (0) = x \}
+$$
+
+of tangent vectors of $M$ at $x$ is called the tangent space of $M$ at $x$ .
+
+In simpler terms, the plane tangent to the manifold $M$ at point $x$ is called the tangent space and denoted by $T_{x}M$ . Consider the upper half of a 2-sphere, $S^2 \subset \mathbb{R}^3$ , which is a 2-manifold in $\mathbb{R}^3$ . The tangent space at a fixed point $x \in S^2$ is the 2D plane perpendicular to the vector $x$ and tangential to the surface of the sphere that contains the point $x$ . For additional background on manifolds we refer the reader to Appendix B.
+
+# 2.2 Linear Regions of Deep ReLU Networks
+
+The higher the density of these linear regions the more complex a function a DNN can approximate. For example, a sin curve in the range $[0, 2\pi]$ is better approximated by 4 piece-wise linear regions as opposed to 2. To clarify this further, with the 4 "optimal" linear regions $[0, \pi/2), [\pi/2, \pi), [\pi, 3\pi/2)$ , and $[3\pi/2, 2\pi]$ a function could approximate the sin curve better than any 2 linear regions. In other words, higher density of linear regions allows a DNN to approximate the variation in the curve better. We define the notion of boundary of a linear region in this section and provide an overview of previous results.
+
+We consider a neural network, $F$ , which is a composition of activation functions. Inputs at each layer are multiplied by a matrix, referred to as the weight matrix, with an additional bias vector that is added to this product. We limit our study to ReLU activation function [Nair and Hinton, 2010], which is piece-wise linear and one of the most popular activation functions being applied to various learning tasks on different types of data like text, images, signals etc. We further consider DNNs that map inputs, of dimension $n_{\mathrm{in}}$ , to scalar values. Therefore, $F: \mathbb{R}^{n_{\mathrm{in}}} \to \mathbb{R}$ is defined as,
+
+$$
+F (x) = W _ {L} \sigma \left(B _ {L - 1} + W _ {L - 1} \sigma (\dots \sigma \left(B _ {1} + W _ {1} x\right))\right), \tag {1}
+$$
+
+where $W_{l} \in \mathbb{M}^{n_{l} \times n_{l-1}}$ is the weight matrix for the $l^{\text{th}}$ hidden layer, $n_{l}$ is the number of neurons in the $l^{\text{th}}$ hidden layer, $B_{l} \in \mathbb{R}^{n_{l}}$ is the vector of biases for the $l^{\text{th}}$ hidden layer, $n_{0} = n_{\text{in}}$ and $\sigma: \mathbb{R} \to \mathbb{R}$ is the activation function. For a neuron $z$ in the $l^{\text{th}}$ layer we denote the pre-activation of this neuron, for given input $x \in \mathbb{R}^{n_{\text{in}}}$ , as $z_{l}(x)$ . For a neuron $z$ in the layer $l$ we have
+
+$$
+z (x) = W _ {l - 1, z} \sigma (\dots \sigma \left(B _ {1} + W _ {1} x\right)), \tag {2}
+$$
+
+for $l > 1$ (for the base case $l = 1$ we have $z(x) = W_{1,z}x$ ) where $W_{l-1,z}$ is the row of weights, in the weight matrix of the $l^{\text{th}}$ layer, $W_l$ , corresponding to the neuron $z$ . We use $W_z$ to denote the weight vector for brevity, omitting the layer index $l$ in the subscript. We also use $b_z$ to denote the bias term for the neuron $z$ .
+
+Neural networks with piece-wise linear activations are piece-wise linear on the input space [Montúfar et al., 2014]. Suppose for some fixed $y \in \mathbb{R}^{n_{\mathrm{in}}}$ as $x \to y$ if we have $z(x) \to -b_z$ then we observe a discontinuity in the gradient $\nabla_x \sigma(b_z + W_z z(x))$ at $y$ . Intuitively, this is because $x$ is approaching the boundary of the linear region of the function defined by the output of $z$ . Therefore, the boundary of linear regions, for a feed forward neural network $F$ , is defined as:
+
+$$
+\mathcal {B} _ {F} = \{x | \nabla F (x) \text {i s n o t c o n t i n u o u s a t} x \}.
+$$
+
+Hanin and Rolnick [2019a] argue that an important generalization for the approximation capacity of a neural network $F$ is the $(n_{\mathrm{in}} - 1)$ -dimensional volume density of linear regions defined as $\operatorname{vol}_{n_{\mathrm{in}} - 1}(\mathcal{B}_F \cap K) / \operatorname{vol}_{n_{\mathrm{in}}}(K)$ , for a bounded set $K \subset \mathbb{R}^{n_{\mathrm{in}}}$ . This quantity serves as a proxy for density of linear regions and therefore the expressive capacity of DNNs. Intuitively, higher density of linear boundaries means higher capacity of the DNN to approximate complex non-linear functions. The quantity is applied to lower bound the distance between a point $x \in K$ and the set $\mathcal{B}_F$ , which is
+
+$$
+\operatorname {d i s t a n c e} (x, \mathcal {B} _ {F}) = \min _ {\text {n e u r o n s} z} | z (x) - b _ {z} | / | | \nabla z (x) | |,
+$$
+
+which measures the sensitivity over neurons at a given input. The above quantity measures how "far" the input is from flipping any neuron from inactive to active or vice-versa.
+
+Informally, Hanin and Rolnick [2019a] provide two main results for a randomly initialized DNN $F$ , with a reasonable initialisation. Firstly, they show that
+
+$$
+\mathbb {E} \left[ \frac {\operatorname {v o l} _ {n _ {\text {i n}} - 1} \left(\mathcal {B} _ {F} \cap K\right)}{\operatorname {v o l} _ {n _ {\text {i n}}} (K)} \right] \approx \# \{\text {n e u r o n s} \},
+$$
+
+meaning the density of linear regions is bound above and below by some constant times the number of neurons. Secondly, for $x \in [0,1]^{n_{\mathrm{in}}}$ ,
+
+$$
+\mathbb {E} \left[ \operatorname {d i s t a n c e} \left(x, \mathcal {B} _ {F}\right) \right] \geq C \# \{\text {n e u r o n s} \} ^ {- 1},
+$$
+
+where $C > 0$ depends on the distribution of biases and weights, in addition to other factors. In other words, the distance to the nearest boundary is bounded above and below by a constant times the inverse of the number of neurons. These results stand in contrast to earlier worst case bounds that are exponential in the number of neurons. Hanin and Rolnick [2019a] also verify these results empirically to note that the constants lie in the vicinity of 1 throughout training.
+
+# 3 Linear Regions on the Data Manifold
+
+One important assumption in the results presented by Hanin and Rolnick [2019a] is that the input, $x$ , lies in a compact set $K \subset \mathbb{R}^{n_{\mathrm{in}}}$ and that $\mathrm{vol}_{n_{\mathrm{in}}}(K)$ is greater than 0. Also, the theorem pertaining to the lower bound on average distance of $x$ to linear boundaries the input assumes the input uniformly distributed in $[0,1]^{n_{\mathrm{in}}}$ . As noted earlier, high-dimensional real world datasets, like images, lie on low dimensional manifolds, therefore both these assumptions are false in practice. This motivates us to study the case where the data lies on some $m$ -dimensional submanifold of $\mathbb{R}^{n_{\mathrm{in}}}$ , i.e. $M \subset \mathbb{R}^{n_{\mathrm{in}}}$ where $m \ll n_{\mathrm{in}}$ . We illustrate how this constraint effects the study of linear regions in Figure 2.
+
+As introduced by Hanin and Rolnick [2019a], we denote the “ $(n_{\mathrm{in}} - k)$ -dimensional piece” of $\mathcal{B}_F$ as $\mathcal{B}_{F,k}$ . More precisely, $\mathcal{B}_{F,0} = \emptyset$ and $\mathcal{B}_{F,k}$ is recursively defined to be the set of points $x \in \mathcal{B}_F \setminus \{\mathcal{B}_{F,0} \cup \ldots \cup \mathcal{B}_{F,k-1}\}$ with the added condition that in a neighbourhood of $x$ the set $\mathcal{B}_{F,k}$
+
+
+Figure 2: A circle is an example of a 1D manifold in a 2D Euclidean space. The effective number of linear regions on the manifold, the upper half of the circle, are the number of linear regions on the arc from $-\pi$ to $\pi$ . In the diagram above, each color in the 2D space corresponds to a linear region. When the upper half of the circle is flattened into a 1D space we obtain a line. Each color on the line corresponds to a linear region of the 2D space.
+
+coincides with hyperplane of dimension $n_{\mathrm{in}} - k$ . We provide a detailed and formal definition for $\mathcal{B}_{F,k}$ with intuition in Appendix E. In our setting, where the data lies on a manifold $M$ , we define $\mathcal{B}_{F,k}'$ as $\mathcal{B}_{F,k} \cap M$ , and note that $\dim(\mathcal{B}_{F,k}') = m - k$ (Appendix E Proposition E.4). For example, the transverse intersection (see Definition E.3) of a plane in 3D with the 2D manifold $S^2$ is a 1D curve in $S^2$ and therefore has dimension 1. Therefore, $\mathcal{B}_{F,k}'$ is a submanifold of dimension $3 - 2 = 1$ . This imposes the restriction $k \leq m$ , for the intersection $\mathcal{B}_{F,k} \cap M$ to have a well defined volume.
+
+We first note that the definition of the determinant of the Jacobian, for a collection of neurons $z_{1},\ldots ,z_{k}$ , is different in the case when the data lies on a manifold $M$ as opposed to in a compact set of dimension $n_{\mathrm{in}}$ in $\mathbb{R}^{n_{\mathrm{in}}}$ . Since the determinant of the Jacobian is the quantity we utilise in our proofs and theorems repeatedly we will use the term Jacobian to refer to it for succinctness. Intuitively, this follows from the Jacobian of a function being defined differently in the ambient space $\mathbb{R}^{n_{\mathrm{in}}}$ as opposed to the manifold $M$ . In case of the former it is the volume of the parallelepiped determined by the vectors corresponding to the directions with steepest ascent along each one of the $n_{\mathrm{in}}$ axes. In case of the latter it is more complex and defined below. Let $\mathcal{H}^m$ be the $m$ -dimensional Hausdorff measure (we refer the reader to the Appendix B for background on Hausdorff measure). The Jacobian of a function on manifold $M$ , as defined by Krantz and Parks [2008] (Chapter 5), is as follows.
+
+Definition 3.1. The (determinant of) Jacobian of a function $H: M \to \mathbb{R}^k$ , where $k \leq \dim(M) = m$ , is defined as
+
+$$
+J _ {k, H} ^ {M} (x) = \sup \left\{\frac {\mathcal {H} ^ {k} \left(D _ {M} H (P)\right)}{\mathcal {H} ^ {k} (P)} \Big | P \text {i s a k - d i m e n s i o n a l p a r a l l e l e p i p e d c o n t a i n e d i n} T _ {x} M. \right\},
+$$
+
+where $D_M: T_xM \to \mathbb{R}^k$ is the differential map (see Appendix B) and we use $D_MH(P)$ to denote the mapping of the set $P$ in $T_xM$ , which is a parallelepiped, to $\mathbb{R}^k$ . The supremum is taken over all parallelepipeds $P$ .
+
+We also say that neurons $z_{1}, \ldots, z_{k}$ are good at $x$ if there exists a path of neurons from $z$ to the output in the computational graph of $F$ so that each neuron is activated along the path. Our three main results that hold under the assumptions listed in Appendix A, each of which extend and improve upon the theoretical results by Hanin and Rolnick [2019a], are:
+
+Theorem 3.2. Given $F$ a feed-forward ReLU network with input dimension $n_{in}$ , output dimension 1, and random weights and biases. Then for any bounded measurable submanifold $M \subset \mathbb{R}^{n_{in}}$ and any $k = 1,\dots,m$ the average $(m - k)$ -dimensional volume of $\mathcal{B}_{F,k}$ inside $M$ ,
+
+$$
+\mathbb {E} \left[ v o l _ {m - k} \left(\mathcal {B} _ {F, k} \cap M\right) \right] = \sum_ {\text {d i s t i n c t n e u r o n s} z _ {1}, \dots , z _ {k} \text {i n} F} \int_ {M} \mathbb {E} \left[ Y _ {z _ {1}, \dots , z _ {k}} \right] d v o l _ {m} (x), \tag {3}
+$$
+
+where $Y_{z_1,\dots,z_k}$ is $J_{m,H_k}^M(x)\rho_{b_1,\dots,b_k}(z_1(x),\dots,z_k(x))$ , times the indicator function of the event that $z_j$ is good at $x$ for each $j = 1,\dots,k$ . Here the function $\rho_{b_{z_1},\dots,b_{z_k}}$ is the density of the joint distribution of the biases $b_{z_1},\dots,b_{z_k}$ .
+
+This change in the formula, from Theorem 3.4 by Hanin and Rolnick [2019a], is a result of the fact that $z(x)$ has a different direction of steepest ascent when it is restricted to the data manifold $M$ , for any $j$ . The proof is presented in Appendix E. Formula 3 also makes explicit the fact that the data manifold has dimension $m \leq n_{\mathrm{in}}$ and therefore the $m - k$ -dimensional volume is a more representative measure of the linear boundaries. Equipped with Theorem 3.2, we provide a result for the density of boundary regions on manifold $M$ .
+
+Theorem 3.3. For data sampled uniformly from a compact and measurable $m$ dimensional manifold $M$ we have the following result for all $k \leq m$ :
+
+$$
+\frac {v o l _ {m - k} (\mathcal {B} _ {F , k} \cap M)}{v o l _ {m} (M)} \leq \binom {\# n e u r o n s} {k} \left(2 C _ {g r a d} C _ {b i a s} C _ {M}\right) ^ {k},
+$$
+
+where $C_{\mathrm{grad}}$ depends on $||\nabla z(x)||$ and the DNN's architecture, $C_M$ depends on the geometry of $M$ , and $C_{bias}$ on the distribution of biases $\rho_b$ .
+
+The constant $C_M$ is the supremum over the matrix norm of projection matrices onto the tangent space, $T_xM$ , at any point $x \in M$ . For the Euclidean space $C_M$ is always equal to 1 and therefore the term does not appear in the work by Hanin and Rolnick [2019a], but we cannot say the same for our setting. We refer the reader to Appendix F for the proof, further details, and interpretation. Finally, under the added assumptions that the diameter of the manifold $M$ is finite and $M$ has polynomial volume growth we provide a lower bound on the average distance to the linear boundary for points on the manifold and how it depends on the geometry and dimensionality of the manifold.
+
+Theorem 3.4. For any point, $x$ , chosen randomly from $M$ , we have:
+
+$$
+\mathbb {E} \left[ d i s t a n c e _ {M} \left(x, \mathcal {B} _ {F} \cap M\right) \right] \geq \frac {C _ {M , \kappa}}{C _ {\text {g r a d}} C _ {\text {b i a s}} C _ {M} \# \text {n e u r o n s}},
+$$
+
+where $C_{M,\kappa}$ depends on the scalar curvature, the input dimension and the dimensionality of the manifold $M$ . The function distance $M$ is the distance on the manifold $M$ .
+
+This result gives us intuition on how the density of linear regions around a point depends on the geometry of the manifold. The constant $C_{M,\kappa}$ captures how volumes are distorted on the manifold $M$ as compared to the Euclidean space, for the exact definition we refer the reader to the proof in Appendix G. For a manifold which has higher volume of a unit ball, on average, in comparison to the Euclidean space the constant $C_{M,\kappa}$ is higher and lower when the volume of unit ball, on average, is lower than the volume of the Euclidean space. For background on curvature of manifolds and a proof sketch we refer the reader to the Appendices B and D, respectively. Note that the constant $C_M$ is the same as in Theorem 3.3. Another difference to note is that we derive a lower bound on the geodesic distance on the manifold $M$ and not the Euclidean distance in $\mathbb{R}^k$ as done by Hanin and Rolnick [2019a]. This distance better captures the distance between data points on a manifold while incorporating the underlying structure. In other words, this distance can be understood as how much a data point should change to reach a linear boundary while ensuring that all the individual points on the curve, tracing this change, are "valid" data points.
+
+# 3.1 Intuition For Theoretical Results
+
+One of the key ingredients of the proofs by Hanin and Rolnick [2019a] is the co-area formula [Krantz and Parks, 2008]. The co-area formula is applied to get a closed form representation of the $k$ -dimensional volume of the region where any set of $k$ neurons, $z_{1}, z_{2}, \ldots, z_{k}$ is "good" in terms of the expectation over the Jacobian, in the Euclidean space. Instead of the co-area formula we use the smooth co-area formula [Krantz and Parks, 2008] to get a closed form representation of the $m - k$ -dimensional volume of the region intersected with manifold, $M$ , in terms of the Jacobian defined on a manifold (Definition 3.1). The key difference between the two formulas is that in the smooth co-area formula the Jacobian (of a function from the manifold $M$ ) is restricted to the tangent plane. While the determinant of the "vanilla" Jacobian measures the distortion of volume around a point in Euclidean space the determinant of the Jacobian defined as above (Definition 3.1) measures the distortion of volume on the manifold instead for the function with the same domain, the function that is 1 if the set of neurons are good and 0 otherwise.
+
+The value of the Jacobian as defined in Definition 3.1 has the same volume as the projection of the parallelepiped defined by the gradients $\nabla z(x)$ onto the tangent space (see Proposition F.1 in
+
+
+(a)
+
+
+(b)
+Figure 3: The tractrix (a) and circle (b) are plotted in grey and the target function is in blue. This is for illustration purposes and does not match the actual function or domains used in our experiments.
+
+Appendix). This introduces the constant $C_M$ , defined above. Essentially, the constant captures how the magnitude of the gradients, $\nabla z(x)$ , are modified upon being projected to the tangent plane. Certain manifolds "shrink" vectors upon projection to the tangent plane more than others, on an average, which is a function of their geometry. We illustrate how two distinct manifolds "shrink" the gradients differently upon projection to the tangent plane as reflected in the number of linear regions on the manifolds (see Figure 11 in the appendix) for 1D manifolds. We provide intuition for the curvature of a manifold in Appendix B, due to space constraints, which is used in the lower bound for the average distance in Theorem 3.4. The constant $C_{M,\kappa}$ depends on the curvature as the supremum of a polynomial whose coefficients depend on the curvature, with order at most $n_{\mathrm{in}}$ and at least $n_{\mathrm{in}} - m$ . Note that despite this dependence on the ambient dimension, there are other geometric constants in this polynomial (see Appendix G). Finally, we also provide a simple example as to how this constant varies with $n_{\mathrm{in}}$ and $m$ , for a simple and contrived example, in Appendix G.1.
+
+# 4 Experiments
+
+# 4.1 Linear Regions on a 1D Curve
+
+To empirically corroborate our theoretical results, we calculate the number of linear regions and average distance to the linear boundary on 1D curves for regression tasks in two settings. The first is for 1D manifolds embedded in 2D and higher dimensions and the second is for the high-dimensional data using the MetFaces dataset. We use the same algorithm, for the toy problem and the high-dimensional dataset, to find linear regions on 1D curves. We calculate the exact number of linear regions for a 1D curve in the input space, $x: I \to \mathbb{R}^{n_{\mathrm{in}}}$ where $I$ is an interval in real numbers, by finding the points where $z(x(t)) = b_z$ for every neuron $z$ . The solutions thus obtained gives us the boundaries for neurons on the curve $x$ . We obtain these solutions by using the programmatic activation of every neuron and using the sequential least squares programming (SLSQP) algorithm [Kraft, 1988] to solve for $|z(x(t)) - b_z| = 0$ for $t \in I$ . In order to obtain the programmatic activation of a neuron we construct a Deep ReLU network as defined in Equation 2. We do so for all the neurons for a given DNN with fixed weights.
+
+# 4.2 Supervised Learning on Toy Dataset
+
+We define two similar regression tasks where the data is sampled from two different manifolds with different geometries. We parameterize the first task, a unit circle without its north and south poles, by $\psi_{\mathrm{circle}}: (-\pi, \pi) \to \mathbb{R}^2$ where $\psi_{\mathrm{circle}}(\theta) = (\cos \theta, \sin \theta)$ and $\theta$ is the angle made by the vector from the origin to the point with respect to the x-axis. We set the target function for regression task to be a periodic function in $\theta$ . The target is defined as $z(\theta) = a \sin(\nu \theta)$ where $a$ is the amplitude and $\nu$ is the frequency (Figure 3). DNNs have difficulty learning periodic functions [Ziyin et al., 2020]. The motivation behind this is to present the DNN with a challenging task where it has to learn the underlying structure of the data. Moreover the DNN will have to split the circle into linear regions. For the second regression task, a tractrix is parametrized by $\psi_{\mathrm{tractrix}}: \mathbb{R}^1 \to \mathbb{R}^2$ where $\psi_{\mathrm{tractrix}}(y) = (y - \tanh y, \operatorname{sech} y)$ (see Figure 3). We assign a target function $z(t) = a \sin(\nu t)$ . For the purposes of our study we restrict the domain of $\psi_{\mathrm{tractrix}}$ to $(-3, 3)$ . We choose $\nu$ so as to ensure
+
+that the number of peaks and troughs, 6, in the periodic target function are the same for both the manifolds. This ensures that the domains of both the problems have length close to 6.28. Further experimental details are in Appendix H.
+
+The results, averaged over 20 runs, are presented in Figures 4 and 5. We note that $C_M$ is smaller for Sphere (based on Figure 4) and the curvature is positive whilst $C_M$ is larger for tractrix and the curvature is negative. Both of these constants (curvature and $C_M$ ) contribute to the lower bound in Theorem 3.4. Similarly, we show results of number of linear regions divided by the number of neurons upon changing architectures, consequently the number of neurons, for the two manifolds in Figure 8, averaged over 30 runs. Note that this experiment observes the effect of $C_M \times C_{\mathrm{grad}}$ , since changing the architecture also changes $C_{\mathrm{grad}}$ and the variation in $C_{\mathrm{grad}}$ is quite low in magnitude as observed empirically by Hanin and Rolnick [2019a]. The empirical observations are consistent with our theoretical results. We observe that the number of linear regions starts off close to #neurons and remains close throughout the training process for both the manifolds. This supports our theoretical results (Theorem 3.3) that the constant $C_M$ , which is distinct across the two manifolds, affects the number of linear regions throughout training. The tractrix has a higher value of $C_M$ and that is reflected in both Figures 4 and 5. Note that its relationship is inverse to the average distance to the boundary region, as per Theorem 3.4, and it is reflected as training progresses in Figure 5. This is due to different "shrinking" of vectors upon being projected to the tangent space (Section 3.1).
+
+# 4.3 Varying Input Dimensions
+
+To empirically corroborate the results of Theorems 2 and 3 we vary the dimension $n_{\mathrm{in}}$ while keeping $m$ constant. We achieve this by counting the number of linear regions and the average distance to boundary region on the 1D circle as we vary the input dimension in steps of 5. We draw samples of 1D circles in $\mathbb{R}^{n_{\mathrm{in}}}$ by randomly choosing two perpendicular basis vectors. We then train a network with the same architecture as the previous section on the periodic target function $(a\sin (\nu \theta))$ as defined above. The results in Figure 6 show that the quantities stay proportional to #neurons, and do not vary as $n_{\mathrm{in}}$ is increased, as predicted by our theoretical results. Our empirical study asserts how the relevant upper and lower bounds, for the setting where data lies on a low-dimensional manifold, does not grow exponentially with $n_{\mathrm{in}}$ for the density of linear regions in a compact set of $\mathbb{R}^{n_{\mathrm{in}}}$ but instead depend on the intrinsic dimension. Further details are in Appendix H.
+
+# 4.4 MetFaces: High Dimensional Dataset
+
+Our goal with this experiment is to study how the density of linear regions varies across a low dimensional manifold and the input space. To discover latent low dimensional underlying structure of data we employ a GAN. Adversarial training of GANs can be effectively applied to learn a mapping from a low dimensional latent space to high dimensional data [Goodfellow et al., 2014]. The generator is a neural network that maps $g: \mathbb{R}^k \to \mathbb{R}^{n_{\mathrm{in}}}$ . We train a deep ReLU network on the MetFaces dataset with random labels (chosen from $0, 1$ ) with cross entropy loss. As noted by Zhang et al. [2017], training with random labels can lead to the DNN memorizing the entire dataset.
+
+We compare the log density of number of linear regions on a curve on the manifold with a straight line off the manifold. We generate these curves using the data sampled by the StyleGAN by [Karras et al., 2020a]. Specifically, for each curve we sample a random pair of latent vectors: $z_{1},z_{2}\in \mathbb{R}^{k}$ , this gives us the start and end point of the curve using the generator $g(z_{1})$ and $g(z_{2})$ . We then generate 100 images to approximate a curve connecting the two images on the image manifold in a piece-wise manner. We do so by taking 100 points on the line connecting $z_{1}$ and $z_{2}$ in the latent space that are evenly spaced and generate an image from each one of them. Therefore, the $i^{\mathrm{th}}$ image is generated as: $z_{i}^{\prime} = g((100 - i)\times z_{1} + i\times z_{2}) / 100$ , using the StyleGAN generator $g$ . We qualitatively verify the images to ensure that they lie on the manifold of images of faces. The straight line, with two fixed points $g(z_{1})$ and $g(z_{2})$ , is defined as $x(t) = (1 - t)g(z_1) + tg(z_2)$ with $t\in [0,1]$ . The approximated curve on the manifold is defined as $x^{\prime}(t) = (1 - t)g(z_i^{\prime}) + tg(z_{i + 1}^{\prime})$ where $i = \text{floor}(100t)$ . We then apply the method from Section 4.1 to obtain the number of linear regions on these curves.
+
+The results are presented in Figure 9. This leads us to the key observation: the density of linear regions is significantly lower on the data manifold and devising methods to "concentrate" these linear regions on the manifold is a promising research direction. That could lead to increased expressivity for the same number of parameters. We provide further experimental details in Appendix I.
+
+
+Figure 4: Graph of number of linear regions for tractrix (blue) and sphere (orange). The shaded regions represent one standard deviation. Note that the number of neurons is 26 and the number of linear regions are comparable to 26 but different for both the manifolds throughout training.
+
+
+Figure 5: Graph of distance to linear regions for tractrix (blue) and sphere (orange). The distances are normalized by the maximum distance on the range, for both tractrix and sphere. The shaded regions represent one standard deviation.
+
+
+Figure 6: We observe that as the dimension $n_{\mathrm{in}}$ is increased, while keeping the manifold dimension constant, the number of linear regions remains proportional to number of neurons (26).
+
+
+Figure 7: We observe that as the dimension $n_{\mathrm{in}}$ is increased, while keeping the manifold dimension constant, the average distance varies very little.
+
+
+Figure 8: The effects of changing the architecture on the number of linear regions. We observe that the value of $C_M$ effects the number of linear regions proportionally. The number of hidden units for three layer networks are in the legend along with the data manifold.
+
+
+Figure 9: We observe that the log density of number of linear regions is lower on the manifold (blue) as compared to off the manifold (green). This is for the MetFaces dataset.
+
+# 5 Discussion and Conclusions
+
+There is significant work in both supervised and unsupervised learning settings for non-Euclidean data [Bronstein et al., 2017]. Despite these empirical results most theoretical analysis is agnostic to data geometry, with a few prominent exceptions [Cloninger and Klock, 2020, Shaham et al., 2015, Schmidt-Hieber, 2019]. We incorporate the idea of data geometry into measuring the effective approximation capacity of DNNs, deriving average bounds on the density of boundary regions and distance from the boundary when the data is sampled from a low dimensional manifold. Our experimental results corroborate our theoretical results. We also present insights into expressivity of DNNs on low dimensional manifolds for the case of high dimensional datasets. Estimating the geometry, dimensionality and curvature, of these image manifolds accurately is a problem that remains largely unsolved [Brehmer and Cranmer, 2020, Perraul-Joncas and Meila, 2013], which limits our inferences on high dimensional dataset to observations that guide future research. We note that proving a lower bound on the number of linear regions, as done by Hanin and Rolnick [2019a], for the manifold setting remains open. Our work opens up avenues for further research that combines model geometry and data geometry and can lead to empirical research geared towards developing DNN architectures for high dimensional datasets that lie on a low dimensional manifold.
+
+# 6 Acknowledgements
+
+This work was funded by L2M (DARPA Lifelong Learning Machines program under grant number FA8750-18-2-0117), the Penn MURI (ONR under the PERISCOPE MURI Contract N00014- 17-1-2699), and the ONR Swarm (the ONR under grant number N00014-21-1-2200). This research was conducted using computational resources and services at the Center for Computation and Visualization, Brown University.
+
+We would like to thank Sam Lobel, Rafael Rodriguez Sanchez, and Akhil Bagaria for refining our work, multiple technical discussions, and their helpful feedback on the implementation details. We also thank Tejas Kotwal for assistance on deriving the mathematical details related to the 1D Tractrix and sources for various citations. We thank Professor Pedro Lopes de Almeida, Nihal Nayak, Cameron Allen and Aarushi Kalra for their valuable comments on writing and presentation of our work. We thank all the members of the Brown robotics lab for their guidance and support at various stages of our work. Finally, we are indebted to, and graciously thank, the numerous anonymous reviewers for their time and labor as their valuable feedback and thoughtful engagement have shaped and vastly refine our work.
+
+# References
+
+Zeyuan Allen-Zhu, Y. Li, and Zhao Song. A convergence theory for deep learning via overparameterization. *ArXiv*, abs/1811.03962, 2019.
+M. Anthony and P. Bartlett. Neural network learning - theoretical foundations. In Neural Network Learning - Theoretical Foundations, 1999.
+Sanjeev Arora, Rong Ge, Behnam Neyshabur, and Yi Zhang. Stronger generalization bounds for deep nets via a compression approach. *ArXiv*, abs/1802.05296, 2018.
+Sanjeev Arora, Nadav Cohen, Noah Golowich, and Wei Hu. A convergence analysis of gradient descent for deep linear neural networks. *ArXiv*, abs/1810.02281, 2019a.
+Sanjeev Arora, Nadav Cohen, Wei Hu, and Yuping Luo. Implicit regularization in deep matrix factorization. In NeurIPS, 2019b.
+D. Arpit, Stanislaw Jastrzebski, Nicolas Ballas, David Krueger, Emmanuel Bengio, Maxinder S. Kanwal, Tegan Maharaj, Asja Fischer, Aaron C. Courville, Yoshua Bengio, and S. Lacoste-Julien. A closer look at memorization in deep networks. *ArXiv*, abs/1706.05394, 2017.
+Peter L. Bartlett, Vitaly Maiorov, and Ron Meir. Almost linear vc-dimension bounds for piecewise polynomial networks. Neural Computation, 10:2159-2173, 1998.
+
+P. P. Brahma, Dapeng Oliver Wu, and Y. She. Why deep learning works: A manifold disentanglement perspective. IEEE Transactions on Neural Networks and Learning Systems, 27:1997-2008, 2016.
+Johann Brehmer and Kyle Cranmer. Flows for simultaneous manifold learning and density estimation. ArXiv, abs/2003.13913, 2020.
+Richard P. Brent. An algorithm with guaranteed convergence for finding a zero of a function. Comput. J., 14:422-425, 1971.
+M. Bronstein, Joan Bruna, Y. LeCun, Arthur Szlam, and P. Vandergheynst. Geometric deep learning: Going beyond euclidean data. IEEE Signal Processing Magazine, 34:18-42, 2017.
+Michael M. Bronstein, Joan Bruna, Taco Cohen, and Petar Velivcković. Geometric deep learning: Grids, groups, graphs, geodesics, and gauges. ArXiv, abs/2104.13478, 2021.
+Sam Buchanan, Dar Gilboa, and John Wright. Deep networks and the multiple manifold problem. *ArXiv*, abs/2008.11245, 2021.
+G. Carlsson, T. Ishkhanov, V. D. Silva, and A. Zomorodian. On the local behavior of spaces of natural images. International Journal of Computer Vision, 76:1-12, 2007.
+Minshuo Chen, Haoming Jiang, Wenjing Liao, and Tuo Zhao. Efficient approximation of deep relu networks for functions on low dimensional manifolds. *ArXiv*, abs/1908.01842, 2019.
+Alexander Cloninger and Timo Klock. Relu nets adapt to intrinsic dimensionality beyond the target domain. ArXiv, abs/2008.02545, 2020.
+G. Cybenko. Approximation by superpositions of a sigmoidal function. Mathematics of Control, Signals and Systems, 2:303-314, 1989.
+Simon Shaolei Du, Wei Hu, and J. Lee. Algorithmic regularization in learning deep homogeneous models: Layers are automatically balanced. In NeurIPS, 2018.
+C. Fefferman, S. Mitter, and Hariharan Narayanan. Testing the manifold hypothesis. arXiv: Statistics Theory, 2013.
+Octavian-Eugen Ganea, Gary Bécigneul, and Thomas Hofmann. Hyperbolic neural networks. *ArXiv*, abs/1805.09112, 2018.
+Sebastian Goldt, Marc Mézard, Florent Krzakala, and Lenka Zdeborova. Modelling the influence of data structure on learning in neural networks. *ArXiv*, abs/1909.11500, 2020.
+I. Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, S. Ozair, Aaron C. Courville, and Yoshua Bengio. Generative adversarial nets. In NIPS, 2014.
+Ian J. Goodfellow and Oriol Vinyals. Qualitatively characterizing neural network optimization problems. CoRR, abs/1412.6544, 2015.
+Ian J. Goodfellow, Jonathon Shlens, and Christian Szegedy. Explaining and harnessing adversarial examples. CoRR, abs/1412.6572, 2015.
+Alfred Gray. The volume of a small geodesic ball of a riemannian manifold. Michigan Mathematical Journal, 20:329-344, 1974.
+Victor Guillemin and Alan Pollack. Differential Topology. Prentice-Hall, 1974.
+B. Hanin and M. Nica. Products of many large random matrices and gradients in deep neural networks. Communications in Mathematical Physics, 376:287-322, 2018.
+B. Hanin and D. Rolnick. Complexity of linear regions in deep networks. ArXiv, abs/1901.09021, 2019a.
+B. Hanin and D. Rolnick. Deep relu networks have surprisingly few activation patterns. In NeurIPS, 2019b.
+
+Boris Hanin. Universal function approximation by deep neural nets with bounded width and relu activations. ArXiv, abs/1708.02691, 2019.
+Boris Hanin and Mihai Nica. Finite depth and width corrections to the neural tangent kernel. ArXiv, abs/1909.05989, 2020.
+M. Hauser and A. Ray. Principles of riemannian geometry in neural networks. In NIPS, 2017.
+Mikael Henaff, Joan Bruna, and Yann LeCun. Deep convolutional networks on graph-structured data. ArXiv, abs/1506.05163, 2015.
+K. Hornik, M. Stinchcombe, and H. White. Multilayer feedforward networks are universal approximators. Neural Networks, 2:359-366, 1989.
+Arthur Jacot, F. Gabriel, and C. Hongler. Neural tangent kernel: Convergence and generalization in neural networks. In NeurIPS, 2018.
+Tero Karras, S. Laine, and Timo Aila. A style-based generator architecture for generative adversarial networks. 2019 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 4396-4405, 2019.
+Tero Karras, Miika Aittala, Janne Hellsten, S. Laine, J. Lehtinen, and Timo Aila. Training generative adversarial networks with limited data. ArXiv, abs/2006.06676, 2020a.
+Tero Karras, S. Laine, Miika Aittala, Janne Hellsten, J. Lehtinen, and Timo Aila. Analyzing and improving the image quality of stylegan. 2020 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 8107-8116, 2020b.
+Kenji Kawaguchi, L. Kaelbling, and Yoshua Bengio. Generalization in deep learning. *ArXiv*, abs/1710.05468, 2017.
+Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. CoRR, abs/1412.6980, 2015.
+Thomas Kipf and Max Welling. Semi-supervised classification with graph convolutional networks. ArXiv, abs/1609.02907, 2017.
+Dieter Kraft. A software package for sequential quadratic programming. Tech. Rep. DFVLR-FB 88-28, DLR German Aerospace Center - Institute for Flight Mechanics, 1988.
+S. Krantz and Harold R. Parks. Geometric integration theory. In *Geometric Integration Theory*, 2008.
+Daniel Kunin, Javier Sagastuy-Breña, S. Ganguli, Daniel L. K. Yamins, and H. Tanaka. Neural mechanics: Symmetry and broken conservation laws in deep learning dynamics. *ArXiv*, abs/2012.04728, 2020.
+Jaehoon Lee, Lechao Xiao, Samuel S. Schoenholz, Yasaman Bahri, Roman Novak, Jascha Sohl-Dickstein, and Jascha Sohl-Dickstein. Wide neural networks of any depth evolve as linear models under gradient descent. ArXiv, abs/1902.06720, 2019.
+Tengyuan Liang, Tomaso A. Poggio, Alexander Rakhlin, and James Stokes. Fisher-rao metric, geometry, and complexity of neural networks. ArXiv, abs/1711.01530, 2019.
+L. Loveridge. Physical and geometric interpretations of the riemann tensor, ricci tensor, and scalar curvature. In Physical and Geometric Interpretations of the Riemann Tensor, Ricci Tensor, and Scalar Curvature, 2004.
+H. Mhaskar and T. Poggio. Deep vs. shallow networks: An approximation theory perspective. ArXiv, abs/1608.03287, 2016.
+Federico Monti, D. Boscaini, Jonathan Masci, Emanuele Rodola, Jan Svoboda, and Michael M. Bronstein. Geometric deep learning on graphs and manifolds using mixture model cnns. 2017 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 5425-5434, 2017.
+
+Guido Montúfar, Razvan Pascanu, Kyunghyun Cho, and Yoshua Bengio. On the number of linear regions of deep neural networks. In NIPS, 2014.
+V. Nair and Geoffrey E. Hinton. Rectified linear units improve restricted boltzmann machines. In ICML, 2010.
+Behnam Neyshabur, Srinadh Bhojanapalli, David A. McAllester, and Nathan Srebro. A pac-bayesian approach to spectrally-normalized margin bounds for neural networks. *ArXiv*, abs/1707.09564, 2018.
+Roman Novak, Yasaman Bahri, Daniel A. Abolafia, Jeffrey Pennington, and Jascha Sohl-Dickstein. Sensitivity and generalization in neural networks: an empirical study. In International Conference on Learning Representations, 2018. URL https://openreview.net/forum?id=HJC2SzZCW.
+Jonas Paccolat, Leonardo Petrini, Mario Geiger, Kevin Tyloo, and Matthieu Wyart. Geometric compression of invariant manifolds in neural networks. Journal of Statistical Mechanics: Theory and Experiment, 2021, 2020.
+Dominique Perraul-Joncas and Marina Meila. Non-linear dimensionality reduction: Riemannian metric estimation and the problem of geometric discovery. arXiv: Machine Learning, 2013.
+Ben Poole, Subhaneil Lahiri, Maithra Raghu, Jascha Sohl-Dickstein, and Surya Ganguli. Exponential expressivity in deep neural networks through transient chaos. In NIPS, 2016.
+C. Qi, Hao Su, Kaichun Mo, and Leonidas J. Guibas. Pointnet: Deep learning on point sets for 3d classification and segmentation. 2017 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 77-85, 2017.
+M. Raghu, Ben Poole, J. Kleinberg, S. Ganguli, and Jascha Sohl-Dickstein. On the expressive power of deep neural networks. *ArXiv*, abs/1606.05336, 2017.
+Nasim Rahaman, Aristide Baratin, Devansh Arpit, Felix Dräxler, Min Lin, Fred A. Hamprecht, Yoshua Bengio, and Aaron C. Courville. On the spectral bias of neural networks. In ICML, 2019.
+Joel W. Robbin, Uw Madison, and Dietmar A. Salamon. INTRODUCTION TO DIFFERENTIAL GEOMETRY. Preprint, 2011.
+Levent Sagun, Utku Evci, V. U. Güney, Yann Dauphin, and L. Bottou. Empirical analysis of the hessian of over-parametrized neural networks. *ArXiv*, abs/1706.04454, 2018.
+Andrew M. Saxe, James L. McClelland, and Surya Ganguli. Exact solutions to the nonlinear dynamics of learning in deep linear neural networks. CoRR, abs/1312.6120, 2014.
+Johannes Schmidt-Hieber. Deep relu network approximation of functions on a manifold. ArXiv, abs/1908.00695, 2019.
+Thiago Serra, Christian Tjandraatmadja, and S. Ramalingam. Bounding and counting linear regions of deep neural networks. In ICML, 2018.
+Uri Shaham, Alexander Cloninger, and Ronald R. Coifman. Provable approximation properties for deep neural networks. *ArXiv*, abs/1509.07385, 2015.
+Samuel L. Smith and Quoc V. Le. A bayesian perspective on generalization and stochastic gradient descent. *ArXiv*, abs/1710.06451, 2018.
+Weijie J. Su, Stephen P. Boyd, and Emmanuel J. Candès. A differential equation for modeling nesterov's accelerated gradient method: Theory and insights. In J. Mach. Learn. Res., 2016.
+Christian Szegedy, W. Zaremba, Ilya Sutskever, Joan Bruna, D. Erhan, Ian J. Goodfellow, and R. Fergus. Intriguing properties of neural networks. CoRR, abs/1312.6199, 2014.
+Matus Telgarsky. Representation benefits of deep feedforward networks. ArXiv, abs/1509.08101, 2015.
+Joshua B. Tenenbaum. Mapping a manifold of perceptual observations. In NIPS, 1997.
+
+Pauli Virtanen, Ralf Gommers, Travis E. Oliphant, Matt Haberland, Tyler Reddy, David Cournaepau, Evgeni Burovski, PEARU Peterson, Warren Weckesser, Jonathan Bright, Stefan J. van der Walt, Matthew Brett, Joshua Wilson, K. Jarrod Millman, Nikolay Mayorov, Andrew R. J. Nelson, Eric Jones, Robert Kern, Eric Larson, C J Carey, Ilhan Polat, Yu Feng, Eric W. Moore, Jake VanderPlas, Denis Laxalde, Josef Perktold, Robert Cirmrnan, Ian Henriksen, E. A. Quintero, Charles R. Harris, Anne M. Archibald, Antonio H. Ribeiro, Fabian Pedregosa, Paul van Mulbregt, and SciPy 1.0 Contributors. SciPy 1.0: Fundamental Algorithms for Scientific Computing in Python. Nature Methods, 17:261-272, 2020. doi: 10.1038/s41592-019-0686-2.
+Z. Wan. Geometric interpretations of curvature. In GEOMETRIC INTERPRETATIONS OF CURVATURE, 2016.
+Tingran Wang, Sam Buchanan, Dar Gilboa, and John Wright. Deep networks provably classify data on curves. ArXiv, abs/2107.14324, 2021.
+Yue Wang, Yongbin Sun, Ziwei Liu, Sanjay E. Sarma, Michael M. Bronstein, and Justin M. Solomon. Dynamic graph cnn for learning on point clouds. ACM Transactions on Graphics (TOG), 38:1-12, 2019.
+Zonghan Wu, Shirui Pan, Fengwen Chen, Guodong Long, Chengqi Zhang, and Philip S. Yu. A comprehensive survey on graph neural networks. IEEE Transactions on Neural Networks and Learning Systems, 32:4-24, 2019.
+C. Zhang, S. Bengio, M. Hardt, B. Recht, and Oriol Vinyals. Understanding deep learning requires rethinking generalization. ArXiv, abs/1611.03530, 2017.
+Liu Ziyin, Tilman Hartwig, and Masahito Ueda. Neural networks fail to learn periodic functions and how to fix it. *ArXiv*, abs/2006.08195, 2020.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential negative societal impacts of your work? [N/A] Our work is primarily theoretical with few toy experiments we do not see its applicability
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes] See Appendix A for a list
+(b) Did you include complete proofs of all theoretical results? [Yes]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] See Appendix J
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See experimental sections in the Appendix and main body
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] Except for the cases where there are multiple graphs that are overlapping (Figure 6,7, 8) because it would make interpreting them difficult.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] Appendix J
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+
+(b) Did you mention the license of the assets? [Yes]
+(c) Did you include any new assets either in the supplemental material or as a URL? [No]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/effectsofdatageometryinearlydeeplearning/images.zip b/effectsofdatageometryinearlydeeplearning/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..acfe8502c54cb29ad831fe3f1b4c9c574330b5ca
--- /dev/null
+++ b/effectsofdatageometryinearlydeeplearning/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0a3d209ca402fd0c4564240e2cb241064225a3d88dc333ad11beaae0c0d43fda
+size 235436
diff --git a/effectsofdatageometryinearlydeeplearning/layout.json b/effectsofdatageometryinearlydeeplearning/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..8572d7e70c08e7f7d2db82f73f0085f4d4bbfd9b
--- /dev/null
+++ b/effectsofdatageometryinearlydeeplearning/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e7c5be5b94314aca9bc9367a19e7a08fb8f59ae937a86998570b90eb6a2346c7
+size 598316
diff --git a/efficiencyorderingofstochasticgradientdescent/d14bdeb5-142b-4606-8b0e-a6ce39916ec7_content_list.json b/efficiencyorderingofstochasticgradientdescent/d14bdeb5-142b-4606-8b0e-a6ce39916ec7_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..c0dcd90d5e8375975cc839e33ae496ebbb546832
--- /dev/null
+++ b/efficiencyorderingofstochasticgradientdescent/d14bdeb5-142b-4606-8b0e-a6ce39916ec7_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:abd67924f0a91e00ba2a4575f1985ef6d00e8ccef6a89d117c802d6a0127e6af
+size 92159
diff --git a/efficiencyorderingofstochasticgradientdescent/d14bdeb5-142b-4606-8b0e-a6ce39916ec7_model.json b/efficiencyorderingofstochasticgradientdescent/d14bdeb5-142b-4606-8b0e-a6ce39916ec7_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..7ce6139b03961bc00c8c0b6bdd00cdc3b8ddeb6d
--- /dev/null
+++ b/efficiencyorderingofstochasticgradientdescent/d14bdeb5-142b-4606-8b0e-a6ce39916ec7_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6261d2ce97ffd255983dcb1a03e5ccbe0300f460153ec26684110ea1a7978463
+size 121455
diff --git a/efficiencyorderingofstochasticgradientdescent/d14bdeb5-142b-4606-8b0e-a6ce39916ec7_origin.pdf b/efficiencyorderingofstochasticgradientdescent/d14bdeb5-142b-4606-8b0e-a6ce39916ec7_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..d5e24f3849fd28e8635f4152f5ceaa0167e85686
--- /dev/null
+++ b/efficiencyorderingofstochasticgradientdescent/d14bdeb5-142b-4606-8b0e-a6ce39916ec7_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:055e5bef6fcf1846ae068d7dc5a2f1633c67d18e9e45f8a906047e0412e3aabf
+size 748829
diff --git a/efficiencyorderingofstochasticgradientdescent/full.md b/efficiencyorderingofstochasticgradientdescent/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..2610b37e319a32a5fdbb74627364fb27becff36c
--- /dev/null
+++ b/efficiencyorderingofstochasticgradientdescent/full.md
@@ -0,0 +1,374 @@
+# Efficiency Ordering of Stochastic Gradient Descent
+
+Jie Hu $^{1*}$ Vishwaraj Doshi $^{2*}$ Do Young Eun $^{1}$
+
+1 Department of Electrical and Computer Engineering, North Carolina State University
+
+2 Data Science and Advanced Analytics, IQVIA
+
+jhu29@ncsu.edu vishwaraj.doshi@iqvia.com dyeun@ncsu.edu
+
+# Abstract
+
+We consider the stochastic gradient descent (SGD) algorithm driven by a general stochastic sequence, including i.i.d noise and random walk on an arbitrary graph, among others; and analyze it in the asymptotic sense. Specifically, we employ the notion of 'efficiency ordering', a well-analyzed tool for comparing the performance of Markov Chain Monte Carlo (MCMC) samplers, for SGD algorithms in the form of Loewner ordering of covariance matrices associated with the scaled iterate errors in the long term. Using this ordering, we show that input sequences that are more efficient for MCMC sampling also lead to smaller covariance of the errors for SGD algorithms in the limit. This also suggests that an arbitrarily weighted MSE of SGD iterates in the limit becomes smaller when driven by more efficient chains. Our finding is of particular interest in applications such as decentralized optimization and swarm learning, where SGD is implemented in a random walk fashion on the underlying communication graph for cost issues and/or data privacy. We demonstrate how certain non-Markovian processes, for which typical mixing-time based non-asymptotic bounds are intractable, can outperform their Markovian counterparts in the sense of efficiency ordering for SGD. We show the utility of our method by applying it to gradient descent with shuffling and mini-batch gradient descent, reaffirming key results from existing literature under a unified framework. Empirically, we also observe efficiency ordering for variants of SGD such as accelerated SGD and Adam, open up the possibility of extending our notion of efficiency ordering to a broader family of stochastic optimization algorithms.
+
+# 1 Introduction
+
+Stochastic gradient descent (SGD) is widely used in machine learning, signal processing and other engineering fields to solve the optimization problem
+
+$$
+\theta^ {*} = \arg \min _ {\theta \in \Theta} \left\{f (\theta) \triangleq \frac {1}{n} \sum_ {i = 1} ^ {n} F (\theta , i) \right\}, \tag {1}
+$$
+
+where $\Theta \subset \mathbb{R}^d$ is some closed and convex set, and $F(\cdot ,i):\mathbb{R}^{d}\to \mathbb{R}$ for $i\in [n]\triangleq \{1,\dots ,n\}$ are smooth functions on $\Theta$ , not necessarily convex, such that their summation $f:\mathbb{R}^d\rightarrow \mathbb{R}$ exhibits a minimizer $\theta^{*}\in \Theta$ satisfying $\nabla f(\theta^{*}) = 0$ . The update rule of the iterative SGD scheme is of the form
+
+$$
+\theta_ {t + 1} = \operatorname {P r o j} _ {\Theta} \left(\theta_ {t} - \gamma_ {t + 1} \nabla_ {\theta} F \left(\theta_ {t}, X _ {t + 1}\right)\right), \tag {2}
+$$
+
+where $\gamma_{t}$ is the step size that can be constant or diminishing as $t\to \infty$ , $\mathrm{Proj}_{\Theta}$ is a projection operator onto the constraint set $\Theta$ , and $\{X_{t}\}_{t\geq 0}$ is some sequence taking values in $[n]$ . This sequence is often generated in a stochastic manner, and samples can be drawn from temporally independent and identically distributed (i.i.d) random variables that are either uniformly distributed over $[n]$ [60, 54, 14], or leverage importance sampling techniques for variance reduction [52, 12, 27]. $\{X_{t}\}_{t\geq 0}$
+
+can also be constructed by repeatedly shuffling over all possible states without repetition, $^{2}$ leading to faster convergence than stochastic counterparts drawing i.i.d samples from $[n]$ [64, 3, 32, 72].
+
+Random Walk Stochastic Gradient Descent (RWSGD): Some applications observe restricted access to the state space, such as decentralized optimization [65, 71, 46], where communication occurs between nodes in a network to collaboratively solve the optimization problem (1). For instance, disease classification in confidential clinical swarm learning [69] considers peer-to-peer networks due to the highly private nature of medical data. In such a setting, the random sequence $\{X_{t}\}_{t\geq 0}$ is usually realized as a Markov chain on a general graph $\mathcal{G}(\mathcal{V},\mathcal{E})$ that only samples local gradients of the nodes in $\mathcal{V}\triangleq [n]$ and traverses the network via edges connecting them without divulging the update history or its own gradient. The randomness of the communication path ensures that the compromised node can not easily leak the data of its neighbors [46].
+
+Apart from the privacy concern, such dynamics are also employed in swarm learning/optimization in robotics [17] and wireless sensor networks [43] due to their low communication cost and asynchronous nature. The need for data privacy and demand for communication-efficient algorithms for decentralized optimization has spurred the study of RWSGD algorithms in recent years [57, 34, 67], with the underlying Markov chain in the form of Metropolis-Hasting random walk (MHRW) [48].
+
+Common analytical approach - Finite time bounds based on mixing time: Most of the existing works analyzing iteration (2) provide so-called finite-time upper bounds on expected error in either the objective function $\mathbb{E}[f(\tilde{\theta}_t) - f(\theta^*)]$ , where $\tilde{\theta}_t$ is some weighted average of the iterates, or its gradient $\mathbb{E}[\|\nabla f(\theta_t)\|_2^2]$ ; and are used to infer the convergence rate of the iterate sequence [57, 25, 67]. For diminishing step sizes $\gamma_t = t^{-\alpha}$ with $\alpha \in (0.5,1)$ , the upper bound on $\mathbb{E}[\|\nabla f(\theta_t)\|_2^2]$ reads as
+
+$$
+\mathbb {E} [ \| \nabla f (\theta_ {t}) \| _ {2} ^ {2} ] \leq O \left(\frac {\max \{M , 1 / \log (1 / \beta) \}}{t ^ {1 - \alpha}}\right), \tag {3}
+$$
+
+and a similar form for $\mathbb{E}[f(\tilde{\theta}_t) - f(\theta^*)]$ as well [67, 24, 7]. Here, $\beta \in (0,1)$ is the second largest eigenvalue modulus (SLEM) of the underlying Markov chain's transition matrix and is related to its mixing time property, since smaller SLEM leads to faster mixing of the Markov chain [18, 44]. On the other hand, $M > 0$ is usually a quantity proportional to the local gradients evaluated at the minimizer, or their upper bound. Both the gradient information and the mixing time play a key role in quantifying the convergence rate derived from this upper bound, and the mixing time is especially important since it hints that convergence rate of the SGD algorithm can potentially be accelerated using faster mixing Markov chains for the input driving sequence. It has also been noted that the inherent correlation of the underlying random walk has to be addressed in any analysis concerning Markov-chain-driven gradient descent [67]. The mixing time technique, by capturing the rate at which the chain converges to its stationary distribution [18, 44], is one way of doing so.
+
+Alternative approach - Asymptotic analysis and efficiency ordering: In addition to the aforementioned mixing time, another widely used metric for characterizing the second order properties of Markov chains is the asymptotic variance (AV). For any scalar valued function $g:[n]\to \mathbb{R}$ , the estimator $\hat{\mu}_t(g)\triangleq \frac{1}{t}\sum_{i = 1}^t g(X_i)$ , associated with an irreducible Markov chain $\{X_{t}\}_{t\geq 0}$ with stationary distribution $\pi$ , is the average of the samples of $g(\cdot)$ obtained along the chain's sample path up to time $t > 0$ . The AV of the Markov chain, denoted by $\sigma_X^2 (g)$ , is then defined as the the limiting variance of the estimator; that is,
+
+$$
+\sigma_ {X} ^ {2} (g) \triangleq \lim _ {t \rightarrow \infty} t \cdot \operatorname {V a r} \left(\hat {\mu} _ {t} (g)\right). \tag {4}
+$$
+
+For all functions $g(\cdot)$ satisfying $\mathbb{E}_{\pi}(g^2) < \infty$ , the AV is associated with the Central Limit Theorem (CLT) for any Markovian kernel on a finite state space, as the variance of the normally distributed estimates in the limit [61, 35, 18]. More formally, we have
+
+$$
+\sqrt {t} \cdot \left[ \hat {\mu} _ {t} (g) - \mathbb {E} _ {\boldsymbol {\pi}} (g) \right] \xrightarrow [ t \rightarrow \infty ]{d i s t} \mathcal {N} \left(0, \sigma_ {X} ^ {2} (g)\right). \tag {5}
+$$
+
+A smaller AV means that fewer samples are required post mixing of the chain $^4$ in order to obtain a desired accuracy - in some sense quantifying the chain's efficiency.
+
+Both the AV and the mixing time of a Markov chain are very strongly related concepts5. In fact, the AV has an upper bound in terms of the SLEM, which decreases as the SLEM gets smaller (chain mixes faster) [50]. However, an ordering of the SLEM between two Markov chains does not imply an ordering of their AV, as we shall demonstrate later in Section 4 for a special case. Both of these second-order properties therefore lead to different notions of optimality; and the comparison of two chains based on their AV leads to the concept of efficiency ordering [50], where we say that a chain is more efficient than the other if it has a smaller AV, uniformly over all functions $g:[n]\to \mathbb{R}$ .
+
+As mentioned earlier, the common intuition asserted by finite time bounds such as (3) is that Markov chains with smaller SLEM lead to faster convergence of the SGD iteration (2) to the minimizer [67, 7]. We put this logic to test by simulating the RWSGD algorithm with three different reversible Markov chains (w.r.t. uniform stationary distribution) as the stochastic inputs - the MHRW, a modification of MHRW, which is also shown in Appendix I [1] to be more efficient than MHRW, and the so-called 'fastest mixing Markov chain' (FMMC) as defined in [16] as the Markov chain obtained by minimizing the SLEM over the entire class of reversible chains for a given graph topology. We employ RWSGD to minimize a quadratic objective function for two underlying graphs. The exact details of the setup are deferred to Appendix I [1], and our numerical results in Figure 1 show that even though the FMMC is theoretically guaranteed to have the smallest SLEM ( $\beta_{i}$ for $i \in \{1, 2, 3\}$ ) of the three reversible chains simulated, it is the worst performing one with largest mean square error (MSE). Although MHRW and Modified-MHRW share the
+
+
+Figure 1: Comparison of MHRW (P1), Modified-MHRW (P2) and FMMC (P3) as stochastic inputs for RWSGD on two different graphs $\mathcal{G}_1$ and $\mathcal{G}_2$ .
+
+same SLEM in the lower plot of Figure 1, they still have performance differences. This is contradictory to the intuition derived from (3), and could be attributed to the finite time results providing upper bounds for all times $t > 0$ , which may therefore not necessarily be tight. On the other hand, the performance of the chains seem to be ordered according to their AV ( $\sigma_i^2$ for $i \in \{1, 2, 3\}$ ) evaluated for a test function. This lends credence to developing techniques based on AV, for judging the performance of different stochastic inputs for SGD, as possible alternatives to using SLEM as the sole performance metric.
+
+The asymptotic variance also appears in the CLT for stochastic approximation (SA) algorithms [11, 21], though this time not directly as the variance in the limit, but as a component of the limiting covariance matrix of the scaled iterate errors. Recent works [21, 51] point out that the covariance matrix itself is of special interest, and typically contains more information than the non-asymptotic MSE bounds [51]. In the sense of SGD algorithms, we will show in Section 3 that it embeds explicit information of the exact vector-valued gradient evaluated at the optimizer as well as the entire spectrum of the transition matrix; as opposed to the upper bound $M$ of the gradients and only the second largest eigenvalue modulus commonly found in mixing time based non-asymptotic bounds. It has been suggested [20, 23], and also proved for the special case of linear SA [21], that the covariance matrix emerging out of the CLT dominates as a leading term of the finite-time MSE bounds. This also holds true for finite-time bounds on weighted MSE for any preferred weight; the weighted MSE being utilized in fields such as wireless MIMO [68] and process optimization [30]. Overall, while finite-time bounds have enjoyed great success in the literature, the potential for performance gains out of the asymptotic analysis of SGD algorithms have remained largely unexplored.
+
+Contributions: We employ asymptotic analysis to propose a general framework that offers seamless connection between AV in the MCMC literature with efficiency ordering and covariance matrix in the SGD algorithms. Our framework can be used to design different random walk variants and also to systematically compare the existing sampling methods in the SGD iteration (2) with diminishing step
+
+size, not just limited to random walks. In particular, we show that any two random walks following an efficiency ordering have their covariance matrices Loewner ordered, including non-Markovian stochastic processes versus its Markovian counterpart, which defies any mixing-time (SLEM) based analysis. Such ordering can be harnessed into improving the accuracy of SGD iterates, which implies a reduction in the weighted MSE with arbitrary weights. Moreover, via a specific augmentation of the state space, we are able to analyze SGD for both single and random shuffling and show the efficiency of shuffling over i.i.d sampling for a set of objective functions that may not satisfy 'Polyak-Lojasiewicz inequality'. We further extend such comparison to mini-batch SGD algorithms. Lastly, we present numerical results where the efficiency ordering via asymptotic analysis tends to hold over all time periods and input sequences with higher efficiency have smaller errors in SGD.
+
+# 2 Modeling setup
+
+Basic notations: We use lower case, bold-faced letters to denote vectors $(\mathbf{v} \in \mathbb{R}^d)$ , and use upper case, bold-faced letters to denote matrices $(\mathbf{M} \in \mathbb{R}^{d \times d})$ . $\| \cdot \|_2$ denotes the $l^2$ norm for vectors or 2-norm for matrices. We use $\nabla \mathbf{f}(\cdot)$ as Jacobian matrix of vector-valued function $\mathbf{f}(\cdot)$ , and $\nabla^2 g(\cdot)$ as Hessian matrix of scalar-valued function $g(\cdot)$ . We let $\nabla_{\theta} g(\theta, X)$ be the gradient of the scalar-valued function $g(\theta, X)$ with respect to $\theta$ and omit the subscript $\theta$ for simplicity. Loewner ordering of matrices is denoted by $\leq_L$ such that $\mathbf{A} \leq_L \mathbf{B} \Longleftrightarrow \mathbf{x}^T (\mathbf{A} - \mathbf{B}) \mathbf{x} \leq 0$ for any $\mathbf{x} \in \mathbb{R}^d$ . The term $Tr(\mathbf{A})$ denotes the trace of matrix $\mathbf{A}$ , and let $\mathbb{1}_{\{\cdot\}}$ be the indicator function. We write $\mathcal{N}(0, \mathbf{V})$ to represent a multivariate Gaussian distribution with zero mean and covariance matrix $\mathbf{V}$ . For a connected and undirected graph $\mathcal{G}(\mathcal{V}, \mathcal{E})$ with node set $\mathcal{V}$ and edge set $\mathcal{E}$ , we use $N(i)$ for the set of neighbors of node $i \in \mathcal{V}$ and $\mathbf{d} \triangleq [d_1, d_2, \dots, d_n]^T$ for the degree vector where $d_i = |N(i)|$ .
+
+SGD algorithm with arbitrary input sequence: We consider random walks $\{X_{t}\}_{t\geq 0}$ for which the limit $\pi_i\triangleq \lim_{t\to \infty}\frac{1}{t}\sum_{k = 1}^{t}\mathbb{1}_{\{X_k = i\}}$ exists almost surely and is positive for all $i\in [n]$ , with $\pmb{\pi} = [\pi_i]_{i\in [n]}$ denoting the limiting or stationary distribution. This is trivially satisfied via strong law of large numbers [26] when $X_{t}$ for each $t > 0$ are i.i.d random variables with distribution $\pi$ over $[n]$ , and via the ergodic theorem [18] when $\{X_{t}\}_{t\geq 0}$ is an irreducible, aperiodic and positive recurrent (ergodic) Markov chain. Note however that this way of defining the stationary distribution $\pi$ allows for the input sequence $\{X_{t}\}_{t\geq 0}$ to be more general, possibly being non-Markov on $[n]$ . Then, we can use $\pi$ to rewrite the objective in (1) as
+
+$$
+f (\theta) = \frac {1}{n} \sum_ {i = 1} ^ {n} F (\theta , i) = \mathbb {E} _ {X \sim \pi} [ G (\theta , X) ], \tag {6}
+$$
+
+where function $G(\theta, i) \triangleq \frac{1}{n\pi_i} F(\theta, i)$ for any $\theta \in \Theta$ , $i \in [n]$ . The generalized update rule then becomes
+
+$$
+\theta_ {t + 1} = \operatorname {P r o j} _ {\Theta} \left(\theta_ {t} - \gamma_ {t + 1} \nabla G \left(\theta_ {t}, X _ {t + 1}\right)\right). \tag {7}
+$$
+
+This change of notation allows us to consider input sequences having possibly non-uniform stationary distributions, and is a version of importance sampling for RWSGD schemes, as in [7]. For example, the iteration (7) with the input sequence generated from a MHRW with uniform target distribution $\pi = 1 / n$ will reduce down to (2) with $G(\theta ,i) = F(\theta ,i)$ for all $\theta \in \Theta$ , $i\in [n]$ . If the input sequence is instead a simple random walk on a connected graph $\mathcal{G}(\mathcal{V},\mathcal{E})$ with $\mathcal{V} = [n]$ , we have $\pi \propto \mathbf{d}$ , and $G(\theta ,i) = \frac{\mathbf{1}^T\mathbf{d}}{nd_i} F(\theta ,i)$ for all $\theta \in \Theta$ , $i\in \mathcal{V}$ .6
+
+Asymptotic covariance matrix. We now quickly review the multivariate CLT for Markov chains, since it is a natural way to introduce the asymptotic covariance matrix, used heavily throughout the paper. For any finite, irreducible Markov chain $\{X_{t}\}_{t\geq 0}$ with stationary distribution $\pi$ , its estimator is defined as $\hat{\mu}_t(\mathbf{g})\triangleq \frac{1}{t}\sum_{k = 1}^{t}\mathbf{g}(X_k)$ for any vector-valued function $\mathbf{g}:[n]\to \mathbb{R}^d$ . Then, the ergodic theorem [18, 19] states that for any initial distribution and any $\mathbf{g}(\cdot)$ such that $\mathbb{E}_{\pi}(\mathbf{g}) = \sum_{i\in [n]}\mathbf{g}(i)\pi_i < \infty$ , we have $\hat{\mu}_t(\mathbf{g})\xrightarrow{a.s.}\mathbb{E}_{\pi}(\mathbf{g})$ . Similarly to the asymptotic variance $\sigma_X^2 (g)$ for a scalar-valued function $g(\cdot)$ , we can also define the asymptotic covariance matrix $\Sigma_X(\mathbf{g})$ for vector-valued function $\mathbf{g}(\cdot)$ ,
+
+$$
+\boldsymbol {\Sigma} _ {X} (\mathbf {g}) \triangleq \lim _ {t \rightarrow \infty} t \cdot \operatorname {V a r} \left(\hat {\mu} _ {t} (\mathbf {g})\right) = \lim _ {t \rightarrow \infty} \frac {1}{t} \cdot \mathbb {E} \left\{\Delta_ {t} \Delta_ {t} ^ {T} \right\}, \tag {8}
+$$
+
+where $\Delta_t \triangleq \sum_{s=1}^t (\mathbf{g}(X_s) - \mathbb{E}_{\pi}(\mathbf{g}))$ . The associated multivariate CLT is then given as follows.
+
+Theorem 2.1 (Chapter 1 [19]). For any function $\mathbf{g}:[n]\to \mathbb{R}^d$ that satisfies $\mathbb{E}_{\pi}(\mathbf{g}^2) < \infty$ , we have
+
+$$
+\sqrt {t} \cdot \left[ \hat {\mu} _ {t} (\mathbf {g}) - \mathbb {E} _ {\boldsymbol {\pi}} (\mathbf {g}) \right] \xrightarrow [ t \to \infty ]{d i s t} \mathcal {N} (0, \boldsymbol {\Sigma} _ {X} (\mathbf {g})).
+$$
+
+In the next section, we will show how the asymptotic covariance matrix $\Sigma_{X}(\cdot)$ also appears as part of the CLT result for SGD algorithms.
+
+# 3 Efficiency Ordering of SGD Algorithms
+
+In this section, we present our main result concerning the performance comparison of different SGD algorithms to solve (1). We first begin by stating our assumptions on the objective function and the stochastic input sequence, providing a CLT result for SGD algorithms, and analyzing the covariance matrix arising therein. We then introduce the notion of efficiency ordering of Markov chains in the context of MCMC sampling, and form the connection with covariance matrices as our main result in Theorem 3.6.
+
+For the rest of this section we assume that the functions $F(\cdot, i)$ (possibly non-convex), the summands of the objective function in (1), and the input process $\{X_t\}_{t \geq 0}$ for the SGD iteration (7) satisfy:
+
+(A1) The step size is given by $\gamma_{t} = t^{-\alpha}$ for $\alpha \in (1 / 2,1]$ ;
+(A2) There exists a unique minimizer $\theta^{*}$ in the interior of the compact set $\Theta$ with $\nabla f(\theta^{*}) = 0$ , and matrix $\nabla^2 f(\theta^*)$ (resp. $\nabla^2 f(\theta^*) - \mathbf{I} / 2$ ) is positive definite for $\alpha \in (1 / 2, 1)$ (resp. $\alpha = 1$ );
+(A3) Gradients are bounded in the compact set $\Theta$ , that is, $\sup_{\theta \in \Theta} \sup_{i \in [n]} \| \nabla F(\theta, i) \|_2 < \infty$ ;
+(A4) For every $z \in [n], \theta \in \mathbb{R}^d$ , the solution $\tilde{F}(\theta, z) \in \mathbb{R}^d$ of the Poisson equation $\tilde{F}(\theta, z) - \mathbb{E}[\tilde{F}(\theta, X_{t+1}) \mid X_t = z] = \nabla F(\theta, z) - \nabla f(\theta)$ exists, and $\sup_{\theta \in \Theta, z \in [n]} \| \tilde{F}(\theta, z) \|_2 < \infty$ ;
+(A5) The functions $F(\theta, i)$ are $L$ -smooth for all $i \in [n]$ , that is, $\forall \theta_1, \theta_2 \in \Theta, \forall i \in [n]$ , we have $\| \nabla F(\theta_1, i) - \nabla F(\theta_2, i) \|_2 \leq L \| \theta_1 - \theta_2 \|_2$ .
+
+We then have the following CLT result for SGD algorithms.
+
+Lemma 3.1. For iterates $\{\theta_t\}_{t\geq 0}$ of the SGD algorithm (7) satisfying (A1)-(A5), we have
+
+$$
+\theta_ {t} \xrightarrow [ t \rightarrow \infty ]{a . s .} \theta^ {*}, \quad a n d \quad \left(\theta_ {t} - \theta^ {*}\right) / \sqrt {\gamma_ {t}} \xrightarrow [ t \rightarrow \infty ]{D i s t} \mathcal {N} (0, \mathbf {V} _ {X}), \tag {9}
+$$
+
+where covariance matrix $\mathbf{V}_X$ is the unique solution to the Lyapunov equation $\boldsymbol{\Sigma}_X + \mathbf{K}\mathbf{V}_X + \mathbf{V}_X\mathbf{K}^T = \mathbf{0}$ when $\alpha \in (0.5,1)$ (resp. $\boldsymbol{\Sigma}_X + (\mathbf{K} + \frac{\mathbf{I}}{2})\mathbf{V}_X + \mathbf{V}_X(\mathbf{K} + \frac{\mathbf{I}}{2})^T = \mathbf{0}$ ) when $\alpha = 1$ . Here, $\boldsymbol{\Sigma}_X \triangleq \boldsymbol{\Sigma}_X(\nabla G(\theta^*,\cdot))$ is the asymptotic covariance matrix as in (8), and $\mathbf{K} \triangleq \nabla^2 f(\theta^*)$ .
+
+Additionally, for the averaged iterates $\{\bar{\theta}_t\}_{t\geq 0}$ where $\bar{\theta}_t\triangleq \frac{1}{t}\sum_{i = 0}^{t - 1}\theta_t$ , we have
+
+$$
+\bar {\theta} _ {t} \xrightarrow [ t \rightarrow \infty ]{a . s .} \theta^ {*}, \quad a n d \quad \sqrt {t} \left(\bar {\theta} _ {t} - \theta^ {*}\right) \xrightarrow [ t \rightarrow \infty ]{D i s t} \mathcal {N} \left(0, \mathbf {V} _ {X} ^ {\prime}\right), \tag {10}
+$$
+
+where $\mathbf{V}_X^{\prime} = \mathbf{K}^{-1}\pmb {\Sigma}_X(\mathbf{K}^{-1})^T$ with the same matrices $\mathbf{K}$ and $\pmb{\Sigma}_{X}$ as in the non-averaged case.
+
+Remark 3.2. Lemma 3.1 is itself a special case of the more general CLT result for SA algorithms provided in Appendix A [1], and as proved in Appendix B [1].
+
+Remark 3.3. While (A2) may appear to be too strict at first, it can be relaxed to the setting of the objective function $f(\cdot)$ having multiple minimizers, by leveraging more general CLT results from SA literature, such as Theorem 2.1 in [28]. However, this comes at a cost of cumbersome notation, requiring conditioning of iterates converging to one of the minimizers, potentially making the mathematical parts harder to follow. We also show in Appendix C [1] that (A2) is no stricter than the Polyak-Lojasiewicz inequality – a popularly adopted weak assumption in recent SGD literature studying non-convex objective functions [36, 47, 70, 72].
+
+Remark 3.4. Assumptions (A3) and (A5) are widely seen in the RWSGD literature [57, 34, 67], while (A4) is automatically satisfied for any ergodic Markov chain (see [49, 21] for details), a common assumption for the stochastic noise sequence [34, 25, 7]. The compactness in (A3) can also be relaxed, given assumptions on the objective function in [37], such that the estimator $\theta_t$ generated by Markov-driven sequences can still be 'locked in' a compact set after a sufficiently long time.
+
+Lemma 3.1 implicitly indicates that the asymptotic convergence rate (in distribution) for $\theta_t - \theta^*$ (resp. $\bar{\theta}_t - \theta^*$ ) is $O(\sqrt{\gamma_t})$ (resp. $O(1 / \sqrt{t}))$ . While this does not necessarily translate to $O(\sqrt{\gamma_t})$ convergence rate for $\mathbb{E}[\| \theta_t - \theta^*\|_2]$ ( $O(1 / \sqrt{t})$ for $\mathbb{E}[\| \bar{\theta}_t - \theta^*\|_2]$ ), it has been suggested [20, 23], and is in fact true for cases such as quadratic objective functions since they satisfy the linear stochastic approximation in [21], which is of the form
+
+$$
+\theta_ {t + 1} = \theta_ {t} - \gamma_ {t + 1} (\mathbf {A} \theta_ {t} - \mathbf {b} (X _ {t + 1})), \tag {11}
+$$
+
+for which the connection between finite-time MSE and covariance matrix $\mathbf{V}_X$ has been established [21]. This is also true for arbitrarily weighted MSE, which can be obtained as a weighted sum of diagonal entries of the covariance matrices $\mathbf{V}_X$ and $\mathbf{V}_X'$ .
+
+In addition to the apparent connection to MSE, the covariance matrix plays a wider role in SGD performance. Given any vector of weights $\mathbf{w} \in \mathbb{R}^d$ , from Lemma 3.1 we also have that the weighted sum of errors $\mathbf{w}^T (\theta_t - \theta^*)$ converges to zero almost surely, and that $\mathbf{w}^T (\theta_t - \theta^*) / \sqrt{\gamma_t} \xrightarrow[ t \to \infty ]{Dist} \mathcal{N}(0, \mathbf{w}^T \mathbf{V}_X \mathbf{w})$ . This means that, for sufficiently large $t$ , we can estimate
+
+$$
+P \left(\frac {\mathbf {w} ^ {T} (\boldsymbol {\theta} _ {t} - \boldsymbol {\theta} ^ {*})}{\sqrt {\gamma_ {t} \mathbf {w} ^ {T} \mathbf {V} _ {X} \mathbf {w}}} > \alpha\right) \approx \frac {1}{2 \pi} \int_ {\alpha} ^ {\infty} e ^ {- x ^ {2} / 2} d x,
+$$
+
+such that, for instance, the $95\%$ confidence interval for $\mathbf{w}^T\theta_t$ is approximately $\mathbf{w}^T\theta^*\pm 2\sqrt{\gamma_t\mathbf{w}^T\mathbf{V}_X\mathbf{w}}$ . In other words, smaller $\mathbf{w}^T\mathbf{V}_X\mathbf{w}$ leads to narrower confidence interval and higher accuracy. The form $\mathbf{w}^T\mathbf{V}_X\mathbf{w}$ for any vector $\mathbf{w}\in \mathbb{R}^{d}$ naturally implies that Loewner ordering should come into play when concerning the performance of SGD algorithms.
+
+To proceed, we first employ the widely used notion of efficiency ordering of Markov chains. The efficiency of different chains is compared by ordering them using their respective AV as follows.
+
+Definition 3.5 (Efficiency Ordering [50]). For two random walks $\{X_{t}\}_{t\geq 0}$ and $\{Y_{t}\}_{t\geq 0}$ with the same stationary distribution $\pi$ , we say $\{X_{t}\}_{t\geq 0}$ is more efficient than $\{Y_{t}\}_{t\geq 0}$ , which we write as $X\geq_{E}Y$ , if and only if $\sigma_X^2 (g)\leq \sigma_Y^2 (g)$ for any $g:[n]\to \mathbb{R}$ .
+
+We are now ready to state our main result. We first extend the efficiency ordering of Markov chains by proving the equivalence of comparing their scalar-valued AVs, to comparing their asymptotic covariance matrices via Loewner ordering. We then use this extension to show that more efficient inputs $\{X_{t}\}_{t\geq 0}$ (as in Definition 3.5) to the SGD algorithm lead to performance improvements in the form of smaller covariance matrices in the Loewner ordering sense.
+
+Theorem 3.6. Consider the SGD iteration (7) with two random walks $\{X_{t}\}_{t\geq 0}$ and $\{Y_{t}\}_{t\geq 0}$ as input sequences, with the same stationary distribution $\pi$ , satisfying (A1)-(A5). Then,
+
+(i) $X\geq_{E}Y$ if and only if $\pmb {\Sigma}_X(\mathbf{g})\le_L\pmb {\Sigma}_Y(\mathbf{g})$ for any vector-valued function $\mathbf{g}$
+(ii) If $\pmb{\Sigma}_{X}(\nabla G(\theta^{*},\cdot))\leq_{L}\pmb{\Sigma}_{Y}(\nabla G(\theta^{*},\cdot))$ then $\mathbf{V}_X\le_L\mathbf{V}_Y$ $(\mathbf{V}_X^{\prime}\le_L\mathbf{V}_Y^{\prime}$ for the case of averaged iterates);
+
+where function $\nabla G(\theta^{*},\cdot):[n]\to \mathbb{R}^{d}$ is defined in the SGD iteration (7), $\mathbf{V}_X$ and $\mathbf{V}_X^{\prime}$ (resp. $\mathbf{V}_Y$ and $\mathbf{V}_Y^{\prime}$ ) are the covariance matrices from Lemma 3.1, corresponding to $\{X_{t}\}_{t\geq 0}$ (resp. $\{Y_t\}_{t\geq 0}$ ) as the stochastic input sequence.
+
+Theorem 3.6 enables us to provide a sense of efficiency ordering of SGD algorithms which are driven by different stochastic inputs. Since this is achieved via Loewner ordering, it also leads to smaller confidence intervals in the long run as mentioned earlier, as well as potentially smaller $\mathrm{MSE}^8$ depending on the objective function.
+
+Remark 3.7. In addition to the CLT result for SGD algorithms with diminishing step size described in Lemma 3.1, we include in Appendix E [1] similar results for constant step sizes and quadratic objective functions, where the statement of Theorem 3.6 still holds.
+
+# 4 Applications: Towards More Efficient SGD
+
+In this section, we present some SGD variants and compare them in terms of efficiency ordering of SGD. Specifically, we first show that a certain class of non-Markov random walks can provide a better input sequence than its Markovian counterpart. We then analyze shuffling-based gradient descent and compare it to the SGD with i.i.d input in terms of efficiency ordering for SGD algorithm. We also extend our approach to a more general mini-batch version, the discussion for which is deferred to Appendix H.3 [1].
+
+High-Order Efficient Random Walk for SGD: The simple random walk (SRW) is a popular Markov chain that has been extensively studied in the literature [62, 58, 29]. Several recent works have focused on the non-backtracking random walk (NBRW) on a connected undirected graph $\mathcal{G}(\mathcal{V},\mathcal{E})$ in the MCMC literature, which is an extension of SRW with the same limiting distribution $\pi = \mathbf{d} / \mathbf{1}^T\mathbf{d}$ [53, 5, 41, 38, 10]. Intuitively speaking, NBRW is a random walk that selects one of its neighbors uniformly at random except the one it just came/transitions from. Specifically, the NBRW $\{Y_{t}\}_{t\geq 0}$ is a second-order non-reversible Markov chain (i.e., it is non-Markov on $\mathcal{V} = [n]$ ) with its transition probability given by
+
+$$
+P \left(Y _ {t + 1} = j \mid Y _ {t} = i, Y _ {t - 1} = k\right) = \left\{ \begin{array}{l l} \frac {1}{d _ {i} - 1} & \text {i f} j \neq k, j \in N (i), d _ {i} > 1, \\ 1 & \text {i f} d _ {i} = 1, j \in N (i), \\ 0 & \text {o t h e r w i s e .} \end{array} \right. \tag {12}
+$$
+
+Since the limiting distributions of NBRW and SRW are the same, NBRW can be used as the input for SGD iterations (7) with the same re-weighted local functions $G(\theta^{*},i)$ as that of SRW for all $i\in [n]$ whenever the applications call for random-walk type of inputs. Let $\Sigma_{Y}(\nabla G(\theta^{*},\cdot))$ be the asymptotic covariance matrix of this NBRW $\{Y_t\}_{t\geq 0}$ , as defined in (8). One of the main results in [41] concerns the efficiency ordering of NBRW and SRW. They show that NBRW has a smaller AV, or equivalently, from our Theorem 3.6 (i), a smaller asymptotic covariance in terms of Loewner ordering. Our next result forms the necessary connection between the asymptotic covariance matrix arising in the CLT result and $\Sigma_{Y}(\nabla G(\theta^{*},\cdot))$ .
+
+Proposition 4.1. Consider the SGD iteration (7) with two input sequences $SRW\{X_t\}_{t \geq 0}$ and NBRW $\{Y_t\}_{t \geq 0}$ respectively. Then, both the respective estimators $\theta_t^X, \theta_t^Y \xrightarrow{a.s.} \theta^*$ , and $\mathbf{V}_Y \leq_L \mathbf{V}_X$ , that is, NBRW is more efficient than SRW in the SGD algorithm.
+
+By augmenting the state space, we can represent NBRW as a Markov chain $Z_{t} = (Y_{t - 1}, Y_{t}) \in \mathcal{V} \times \mathcal{V}$ , as was done in [53, 41]. This transformation then allows us to build CLT for an SGD iteration with $\{Z_{t}\}_{t \geq 0}$ as the input. The subtlety here is to prove that the asymptotic covariance matrix arising out of the CLT with respected to the augmented process $\{Z_{t}\}_{t \geq 0}$ is indeed equal to $\Sigma_{Y}(\nabla G(\theta^{*}, \cdot))$ . This is shown by cultivating the relationship between the stationary distribution of $\{Z_{t}\}_{t \geq 0}$ on the augmented state space $\mathcal{V} \times \mathcal{V}$ and $\{Y_{t}\}_{t \geq 0}$ on the node space $\mathcal{V}$ , as provided in [53].
+
+Thus, our Theorem 3.6 together with the existing works on efficiency ordering of NBRW versus SRW in the MCMC literature [53, 41] enable us to show that NBRW is a more efficient input sequence than SRW for the SGD iteration (7). Interestingly, it has been shown that non-backtracking walks mix faster when the underlying graph is $d$ -regular [5]. In this case, a faster convergence rate is also suggested by mixing time based non-asymptotic bounds prevalent in RWSGD literature. However, no such results concerning mixing time and SLEM exist for NBRW on a general graph. Thus, in the form of Proposition 4.1, we demonstrate the utility of our approach in settings where mixing time based comparisons are unavailable.
+
+Shuffling versus i.i.d Input Sequence: Shuffling-based methods have been widely used in machine learning applications [13]. They work by repeatedly passing over the entire state space $[n]$ without repetition, each complete pass forming an epoch. Random shuffling and single shuffling are two versions therein and differ in the order in which they pass over $[n]$ . Random shuffling, as the name suggests, makes the pass in a randomly chosen order in each epoch, while single shuffling maintains the same predetermined order (often randomly chosen once at the beginning) for all
+
+epochs. Shuffling-based methods are known to show better empirical performance than i.i.d input [15], although intense theoretical analysis for shuffling-based gradient descent has only emerged in recent years [66, 33, 64, 3, 32]. In what follows, we use our results from Section 3 to compare shuffling-based gradient descent to SGD with i.i.d input. To do so, we first analyze the asymptotic covariance matrix for shuffling-based methods.
+
+Lemma 4.2. Let the input process $\{X_{t}\}_{t\geq 0}$ be single or random shuffling. Then, for any vector-valued function $\mathbf{g}:[n]\to \mathbb{R}^d$ $\Sigma_X(\mathbf{g}) = \mathbf{0}$ , where $\Sigma_X(\mathbf{g})$ is defined in (8).
+
+For i.i.d input sequence with distribution $\hat{\pi}$ , the asymptotic covariance from Lemma 3.1 reduces to
+
+$$
+\boldsymbol {\Sigma} _ {X} \left(\nabla G \left(\theta^ {*}, \cdot\right)\right) \triangleq \operatorname {V a r} _ {X _ {0} \sim \hat {\pi}} \left(\nabla G \left(\theta^ {*}, X _ {0}\right)\right) \tag {13}
+$$
+
+following its definition in (8), and thus, trivially, $\Sigma_{X}(\nabla G(\theta^{*},\cdot))\geq_{L}\mathbf{0}$ . Lemma 4.2 shows that shuffling-based methods are more efficient than i.i.d input sequence due to a smaller asymptotic covariance matrix in Loewner ordering. Next, we show that they also outperform i.i.d input when used for driving the input sequence of SGD algorithms.
+
+Proposition 4.3. Consider the SGD iteration (7) with stochastic inputs single/random shuffling $\{X_{t}\}_{t\geq 0}$ and i.i.d sampling $\{Y_{t}\}_{t\geq 0}$ , we have $\theta_t^X, \theta_t^Y \xrightarrow[ t \to \infty ]{a.s.} \theta^*$ and $\mathbf{V}_X = \mathbf{0} \leq_L \mathbf{V}_Y$ .
+
+Though it may seem so at first, Proposition 4.3 is not a simple application of Theorem 3.6, especially for random shuffling because it is hard to check if random shuffling, formulated as a time-inhomogeneous Markov chain, indeed satisfies (A4). To overcome this difficulty, in Appendix H [1] we come up with a non-trivial augmentation to a much higher dimensional state space $([n]^{n + 1})$ to make random shuffling a time-homogeneous periodic Markov chain in order to show that both single shuffling and random shuffling satisfy (A4) and thus apply Theorem 3.6.
+
+The case of shuffling versus i.i.d inputs is an example of a setting where the sequence with larger SLEM is more efficient than one with smaller $\mathrm{SLEM}^9$ as an input sequence to the SGD iteration (7). For quadratic objective functions that satisfy the linear SA iteration in [21], it also attains a faster convergence speed in terms of MSE than i.i.d inputs to SGD algorithms. Although some recent works provide more informative finite-time error bounds on the MSE of the objective function for shuffling-based methods, by studying a special case of the matrix norm AM-GM inequality and proving faster convergence rate than i.i.d inputs [56, 3, 32], our result is not a subset of theirs. To be precise, we show in Appendix C [1] that our assumption (A2) on the objective function is no less general than their most general setting based on the Polyak-Lojasiewicz inequality.
+
+Remark 4.4. Mini-batch gradient descent is another popular gradient descent variant and is widely used in the machine learning tools [22, 2, 55] to accelerate the learning process when compared to SGD. In Appendix H.3 [1] we show how our framework can be applied to study min-batch based SGD algorithms, and include the asymptotic analysis on mini-batch gradient descent with shuffling.
+
+Besides mini-batch gradient descent, there are other SGD variants, e.g., momentum SGD, Nesterov accelerated SGD and ADAM, that have been studied in the SGD literature for non-asymptotic analysis [39, 59, 6]. However, asymptotic analysis on the SGD variants is not well studied in the literature, with only very recent results on the CLT for i.i.d input sequences [42, 8, 9, 45]. Asymptotic analysis and CLT for variants more general Markovian input sequences, which would be a prerequisite for Theorem 3.6, remains an open problem. We defer the discussion on related works to Appendix I.3 [1], where we also empirically test the SGD variants and find that the efficiency ordering result still holds for these SGD variants - opening up the possibility for further theoretical analysis.
+
+# 5 Numerical Experiments
+
+In this section, we empirically validate our theoretical analysis. We select two convex objective functions as follows.
+
+$$
+\tilde {f} (\theta) = \frac {1}{n} \sum_ {i = 1} ^ {n} \log \left(1 + \exp \left(- y _ {i} \mathbf {x} _ {i} ^ {T} \theta\right)\right) + \frac {1}{2} \| \theta \| _ {2} ^ {2}, \quad \hat {f} (\theta) = \frac {1}{n} \sum_ {i = 1} ^ {n} \theta^ {T} \left(\mathbf {a} _ {i} \mathbf {a} _ {i} ^ {T} + \mathbf {D} _ {i}\right) \theta + \mathbf {b} ^ {T} \theta . \tag {14}
+$$
+
+For $l_{2}$ -regularized logistic regression $\tilde{f}(\theta)$ , we choose the dataset CIFAR-10 [40] where $n$ is the total number of data points. Here, $\mathbf{x}_i \in \mathbb{R}^{108}$ is the vector flattened from the cropped image $i$ with
+
+shape (6, 6, 3), and $y_{i} \in \mathbb{R}$ is the label. For sum-of-non-convex functions $\hat{f}(\theta)$ , which is based on the experiment setup in [31, 4], we generate random vectors $\mathbf{a}_i$ , $\mathbf{b}$ and matrices $\mathbf{D}_i$ which ensure the invertibility of matrix $\sum_{i=1}^{n} \mathbf{a}_i \mathbf{a}_i^T$ and $\sum_{i=1}^{n} \mathbf{D}_i = \mathbf{0}$ (details are deferred to Appendix I.2 [1]). For both experiments, we assign a data point to each node $i$ on the general graph 'Dolphins' (62 nodes) [63]. We set the step size in the SGD algorithm as $1/t^{0.9}$ , and use MSE $\mathbb{E}[\|\theta_t - \theta^*\|_2^2]$ to measure the relative performance of different inputs. We also employ the scaled MSE $\mathbb{E}[\|\theta_t - \theta^*\|_2^2] / \gamma_t$ to empirically show its relationship to the CLT result (9). Due to space constraints, additional simulation results which support our efficiency ordering result in the setting of large graphs, and non-convex functions are deferred to Appendix I.3 in [1]. Therein, via numerical simulations, we also observe the efficiency ordering for other SGD variants such as Nesterov accelerated SGD and ADAM when comparing their iterations under efficiency ordered noise sequences.
+
+In Figure 2 we compare NBRW and SRW as input sequences on the graph 'Dolphins' for two objective functions in (14). We also compare uniform sampling, random shuffling and single shuffling, assuming that they can access any node on the graph in each iteration. We can see in Figure 2a and 2c that NBRW always falls below SRW throughout all time periods, which indicates that NBRW tends to have smaller MSE than SRW. Single and random shuffling are both better than uniform sampling in terms of smaller MSE. The oscillation of single shuffling comes from a predetermined fixed data sampling sequence, while random shuffling changes the permutation whenever traversing all nodes. Such oscillation is not visible in Figure 2c and Figure 2d because it is small on the current y-axis scale. The curves of single and random shuffling in Figure 2b and 2d fall below that of uniform sampling and still decrease in the linear rate because eventually their covariance matrices will be zero matrix, as indicated in Proposition 4.3. Figure 2b shows that the scaled MSEs of NBRW, SRW and uniform sampling approach some constants after some time, which is consistent with the CLT result (9). The curves of NBRW are still below that of SRW, showing that the input with smaller scaled MSE tends to have higher efficiency, which supports Proposition 4.1. We can see from Figure 2d that the curves NBRW, SRW are still increasing and they have not yet entered the regime where the covariance matrix becomes the main factor. On the other hand, uniform sampling and both shuffling methods are just entering this regime.
+
+
+(a) Logistic regression; (MSE)
+
+
+
+
+(c) sum-non-convex fn.; (MSE)
+
+
+(b) Logistic regression; (scaled MSE)
+(d) sum-non-convex fn.; (scaled MSE)
+Figure 2: Performance comparison of different stochastic inputs on the graph 'Dolphins'.
+
+# 6 Conclusion
+
+We have introduced the notion of efficiency ordering of SGD algorithms, and shown that processes with smaller asymptotic covariance are always more efficient as input sequences for SGD algorithms. Furthermore, we numerically observe that this sense of efficiency ordering is also seen SGD variants such as Nesterov accelerated SGD and ADAM. Since the asymptotic analysis of such SGD variants is not well-established under general stochastic inputs, establishing theoretical results on efficiency ordering remain an open problem.
+
+# 7 Acknowledgments and Disclosure of Funding
+
+We thank the anonymous reviewers for their constructive comments. The research was conducted while Vishwaraj Doshi was with the Operations Research Graduate Program, North Carolina State University. This work was supported in part by National Science Foundation under Grant Nos. CNS-2007423, IIS-1910749, and CNS-1824518.
+
+# References
+
+[1] Efficiency ordering of stochastic gradient descent - supplementary material, 2022.
+[2] Martín Abadi, Paul Barham, Jianmin Chen, Zhifeng Chen, Andy Davis, Jeffrey Dean, Matthieu Devin, Sanjay Ghemawat, Geoffrey Irving, Michael Isard, et al. Tensorflow: A system for large-scale machine learning. In 12th USENIX symposium on operating systems design and implementation (OSDI 16), pages 265-283, 2016.
+[3] Kwangjun Ahn, Chulhee Yun, and Suvrit Sra. Sgd with shuffling: optimal rates without component convexity and large epoch requirements. In Proceedings of the 34th International Conference on Neural Information Processing Systems, volume 33, pages 17526-17535, 2020.
+[4] Zeyuan Allen-Zhu and Yang Yuan. Improved svrg for non-strongly-convex or sum-of-non-convex objectives. In International conference on machine learning, pages 1080-1089. PMLR, 2016.
+[5] Noga Alon, Itai Benjamini, Eyal Lubetzky, and Sasha Sodin. Non-backtracking random walks mix faster. Communications in Contemporary Mathematics, 9(04):585-603, 2007.
+[6] Mahmoud Assran and Michael Rabbat. On the convergence of nesterov's accelerated gradient method in stochastic settings. In Proceedings of the 37th International Conference on Machine Learning, pages 410-420, 2020.
+[7] Ghadir Ayache and Salim El Rouayheb. Private weighted random walk stochastic gradient descent. IEEE Journal on Selected Areas in Information Theory, 2(1):452-463, 2021.
+[8] Anas Barakat and Pascal Bianchi. Convergence and dynamical behavior of the adam algorithm for nonconvex stochastic optimization. SIAM Journal on Optimization, 31(1):244-274, 2021.
+[9] Anas Barakat, Pascal Bianchi, Walid Hachem, and Sholom Schechtman. Stochastic optimization with momentum: convergence, fluctuations, and traps avoidance. Electronic Journal of Statistics, 15(2):3892-3947, 2021.
+[10] Anna Ben-Hamou, Eyal Lubetzky, and Yuval Peres. Comparing mixing times on sparse random graphs. In Proceedings of the Twenty-Ninth Annual ACM-SIAM Symposium on Discrete Algorithms, pages 1734-1740. SIAM, 2018.
+[11] Albert Benveniste, Michel Métivier, and Pierre Priouret. Adaptive algorithms and stochastic approximations, volume 22. Springer Science & Business Media, 2012.
+[12] Zalán Borsos, Sebastian Curi, Kfir Yehuda Levy, and Andreas Krause. Online variance reduction with mixtures. In International Conference on Machine Learning, pages 705-714. PMLR, 2019.
+[13] Léon Bottou. Curiously fast convergence of some stochastic gradient descent algorithms. Unpublished open problem offered to the attendance of the SLDS 2009 conference, 2009.
+[14] Léon Bottou. Large-scale machine learning with stochastic gradient descent. In Proceedings of COMPSTAT'2010, pages 177-186. Springer, 2010.
+[15] Léon Bottou. Stochastic gradient descent tricks. In Neural networks: Tricks of the trade, pages 421-436. Springer, 2012.
+[16] Stephen Boyd, Persi Diaconis, and Lin Xiao. Fastest mixing markov chain on a graph. SIAM review, 46(4):667-689, 2004.
+
+[17] Manuele Brambilla, Eliseo Ferrante, Mauro Birattari, and Marco Dorigo. Swarm robotics: a review from the swarm engineering perspective. Swarm Intelligence, 7(1):1-41, 2013.
+[18] Pierre Brémaud. Markov chains: Gibbs fields, Monte Carlo simulation, and queues, volume 31. Springer Science & Business Media, 2013.
+[19] Steve Brooks, Andrew Gelman, Galin Jones, and Xiao-Li Meng, editors. Handbook of Markov Chain Monte Carlo (1st ed.). Chapman and Hall/CRC, New York, 2011.
+[20] Shuhang Chen, Adithya Devraj, Andrey Bernstein, and Sean Meyn. Accelerating optimization and reinforcement learning with quasi stochastic approximation. In 2021 American Control Conference (ACC), pages 1965-1972, 2021.
+[21] Shuhang Chen, Adithya Devraj, Ana Busic, and Sean Meyn. Explicit mean-square error bounds for monte-carlo and linear stochastic approximation. In International Conference on Artificial Intelligence and Statistics, pages 4173-4183. PMLR, 2020.
+[22] Francois Chollet et al. Keras, 2015.
+[23] Adithya M. Devraj and Sean P. Meyn. Q-learning with uniformly bounded variance. IEEE Transactions on Automatic Control, 2021.
+[24] Thinh T Doan, Lam M Nguyen, Nhan H Pham, and Justin Romberg. Finite-time analysis of stochastic gradient descent under markov randomness. arXiv preprint arXiv:2003.10973, 2020.
+[25] John C Duchi, Alekh Agarwal, Mikael Johansson, and Michael I Jordan. Ergodic mirror descent. SIAM Journal on Optimization, 22(4):1549-1578, 2012.
+[26] Rick Durrett. Probability: theory and examples, volume 49. Cambridge university press, 2019.
+[27] Ayoub El Hanchi and David Stephens. Adaptive importance sampling for finite-sum optimization and sampling with decreasing step-sizes. In Advances in Neural Information Processing Systems, volume 33, pages 15702-15713, 2020.
+[28] Gersende Fort. Central limit theorems for stochastic approximation with controlled markov chain dynamics. ESAIM: Probability and Statistics, 19:60-80, 2015.
+[29] Minas Gjoka, Maciej Kurant, Carter T Butts, and Athina Markopoulou. Practical recommendations on crawling online social networks. IEEE Journal on Selected Areas in Communications, 29(9):1872-1892, 2011.
+[30] JHF Gomes, AP Paiva, SC Costa, Pedro Paulo Balestrassi, and EJ Paiva. Weighted multivariate mean square error for processes optimization: A case study on flux-cored arc welding for stainless steel claddings. European Journal of Operational Research, 226(3):522-535, 2013.
+[31] Robert Mansel Gower, Nicolas Loizou, Xun Qian, Alibek Sailanbayev, Egor Shulgin, and Peter Richtárik. Sgd: General analysis and improved rates. In International Conference on Machine Learning, pages 5200-5209. PMLR, 2019.
+[32] Mert Gurbuzbalaban, Asu Ozdaglar, and Pablo A Parrilo. Why random reshuffling beats stochastic gradient descent. Mathematical Programming, 186(1):49-84, 2021.
+[33] Jeff Haochen and Suvrit Sra. Random shuffling beats sgd after finite epochs. In International Conference on Machine Learning, pages 2624-2633. PMLR, 2019.
+[34] Björn Johansson, Maben Rabi, and Mikael Johansson. A randomized incremental subgradient method for distributed optimization in networked systems. SIAM Journal on Optimization, 20(3):1157-1170, 2010.
+[35] Galin L Jones. On the markov chain central limit theorem. Probability surveys, 1:299-320, 2004.
+[36] Hamed Karimi, Julie Nutini, and Mark Schmidt. Linear convergence of gradient and proximal-gradient methods under the polyak-lojasiewicz condition. In Joint European Conference on Machine Learning and Knowledge Discovery in Databases, pages 795–811. Springer, 2016.
+
+[37] Prasenjit Karmakar and Shalabh Bhatnagar. Stochastic approximation with iterate-dependent markov noise under verifiable conditions in compact state space with the stability of iterates not ensured. IEEE Transactions on Automatic Control, 66(12):5941-5954, 2021.
+[38] Mark Kemple. Non-backtracking random walks and a weighted ihara's theorem. Open Journal of Discrete Mathematics, 6(4):207-226, 2016.
+[39] Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. In ICLR (Poster), 2015.
+[40] Alex Krizhevsky and Geoffrey Hinton. Learning multiple layers of features from tiny images. 2009.
+[41] Chul-Ho Lee, Xin Xu, and Do Young Eun. Beyond random walk and metropolis-hastings samplers: why you should not backtrack for unbiased graph sampling. ACM SIGMETRICS Performance evaluation review, 40(1):319-330, 2012.
+[42] Jinlong Lei and Uday V Shanbhag. Variance-reduced accelerated first-order methods: Central limit theorems and confidence statements. arXiv preprint arXiv:2006.07769, 2020.
+[43] Victor Lesser, Charles L Ortiz Jr, and Milind Tambe. Distributed sensor networks: A multiagent perspective, volume 9. Springer Science & Business Media, 2003.
+[44] David A Levin and Yuval Peres. Markov chains and mixing times, volume 107. American Mathematical Soc., 2017.
+[45] Tiejun Li, Tiannan Xiao, and Guoguo Yang. Revisiting the central limit theorems for the sgd-type methods. arXiv preprint arXiv:2207.11755, 2022.
+[46] Xianghui Mao, Kun Yuan, Yubin Hu, Yuantao Gu, Ali H Sayed, and Wotao Yin. Walkman: A communication-efficient random-walk algorithm for decentralized optimization. IEEE Transactions on Signal Processing, 68:2513-2528, 2020.
+[47] Panayotis Mertikopoulos, Nadav Hallak, Ali Kavis, and Volkan Cevher. On the almost sure convergence of stochastic gradient descent in non-convex problems. In Proceedings of the 34th International Conference on Neural Information Processing Systems, pages 1–32, 2020.
+[48] Nicholas Metropolis, Arianna W Rosenbluth, Marshall N Rosenbluth, Augusta H Teller, and Edward Teller. Equation of state calculations by fast computing machines. The journal of chemical physics, 21(6):1087-1092, 1953.
+[49] Sean P Meyn and Richard L Tweedie. Markov chains and stochastic stability. Springer Science & Business Media, 2012.
+[50] Antonietta Mira. Ordering and improving the performance of monte carlo markov chains. Statistical Science, pages 340-350, 2001.
+[51] Wenlong Mou, Chris Junchi Li, Martin J Wainwright, Peter L Bartlett, and Michael I Jordan. On linear stochastic approximation: Fine-grained polyak-ruppert and non-asymptotic concentration. In Conference on Learning Theory, pages 2947-2997. PMLR, 2020.
+[52] Hongseok Namkoong, Aman Sinha, Steve Yadlowsky, and John C Duchi. Adaptive sampling probabilities for non-smooth optimization. In International Conference on Machine Learning, pages 2574-2583. PMLR, 2017.
+[53] Radford M Neal. Improving asymptotic variance of mcmc estimators: Non-reversible chains are better. Technical report, Department of Statistics, University of Toronto, July 2004.
+[54] Arkadj Semenovič Nemirovskij and David Borisovich Yudin. Problem complexity and method efficiency in optimization. Wiley-Interscience, 1983.
+[55] Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, et al. Pytorch: An imperative style, high-performance deep learning library. Advances in neural information processing systems, 32:8026-8037, 2019.
+
+[56] Shashank Rajput, Anant Gupta, and Dimitris Papailiopoulos. Closing the convergence gap of sgd without replacement. In International Conference on Machine Learning, pages 7964-7973. PMLR, 2020.
+[57] S Sundhar Ram, A Nedic, and Venugopal V Veeravalli. Incremental stochastic subgradient algorithms for convex optimization. SIAM Journal on Optimization, 20(2):691-717, 2009.
+[58] Amir Hassan Rasti, Mojtaba Torkjazi, Reza Rejaie, Nick Duffield, Walter Willinger, and Daniel Stutzbach. Respondent-driven sampling for characterizing unstructured overlays. In IEEE INFOCOM 2009, pages 2701-2705. IEEE, 2009.
+[59] Sashank J. Reddi, Satyen Kale, and Sanjiv Kumar. On the convergence of adam and beyond. In International Conference on Learning Representations, 2018.
+[60] Herbert Robbins and Sutton Monro. A stochastic approximation method. The annals of mathematical statistics, pages 400-407, 1951.
+[61] Gareth O Roberts and Jeffrey S Rosenthal. General state space markov chains and mcmc algorithms. Probability surveys, 1:20-71, 2004.
+[62] Sheldon M Ross, John J Kelly, Roger J Sullivan, William James Perry, Donald Mercer, Ruth M Davis, Thomas Dell Washburn, Earl V Sager, Joseph B Boyce, and Vincent L Bristow. Stochastic processes, volume 2. Wiley New York, 1996.
+[63] Ryan A. Rossi and Nesreen K. Ahmed. The network data repository with interactive graph analytics and visualization. In AAAI, 2015.
+[64] Itay Safran and Ohad Shamir. How good is sgd with random shuffling? In Conference on Learning Theory, pages 3250-3284. PMLR, 2020.
+[65] Kevin Scaman, Francis Bach, Sébastien Bubeck, Yin Tat Lee, and Laurent Massoulié. Optimal algorithms for smooth and strongly convex distributed optimization in networks. In International Conference on Machine Learning, pages 3027-3036. PMLR, 2017.
+[66] Ohad Shamir. Without-replacement sampling for stochastic gradient methods. Advances in neural information processing systems, 29:46-54, 2016.
+[67] Tao Sun, Yuejiao Sun, and Wotao Yin. On markov chain gradient descent. In Proceedings of the 32nd International Conference on Neural Information Processing Systems, pages 9918-9927, 2018.
+[68] Fanggang Wang, Xiaojun Yuan, Soung Chang Liew, and Dongning Guo. Wireless mimo switching: Weighted sum mean square error and sum rate optimization. IEEE transactions on information theory, 59(9):5297-5312, 2013.
+[69] Stefanie Warnat-Herresthal, Hartmut Schultze, Krishnaprasad Lingadahalli Shastry, Sathyanarayanan Manamohan, Saikat Mukherjee, Vishesh Garg, Ravi Sarveswara, Kristian Händler, Peter Pickkers, N Ahmad Aziz, et al. Swarm learning for decentralized and confidential clinical machine learning. Nature, 594(7862):265-270, 2021.
+[70] Stephan Wojtowytsch. Stochastic gradient descent with noise of machine learning type. part i: Discrete time analysis. arXiv preprint arXiv:2105.01650, 2021.
+[71] Ran Xin, Shi Pu, Angela Nedic, and Usman A Khan. A general framework for decentralized optimization with first-order methods. Proceedings of the IEEE, 108(11):1869-1889, 2020.
+[72] Chulhee Yun, Suvrit Sra, and Ali Jabbabaie. Open problem: Can single-shuffle sgd be better than reshuffling sgd and gd? In Proceedings of Thirty Fourth Conference on Learning Theory, volume 134, pages 4653-4658. PMLR, Aug 2021.
+
+# Checklist
+
+The checklist follows the references. Please read the checklist guidelines carefully for information on how to answer these questions. For each question, change the default [TODO] to [Yes], [No], or [N/A]. You are strongly encouraged to include a justification to your answer, either by referencing the appropriate section of your paper or providing a brief inline description. For example:
+
+- Did you include the license to the code and datasets? [Yes] See Section __.
+- Did you include the license to the code and datasets? [No] The code and the data are proprietary.
+- Did you include the license to the code and datasets? [N/A]
+
+Please do not modify the questions and only use the provided macros for your answers. Note that the Checklist section does not count towards the page limit. In your paper, please delete this instructions block and only keep the Checklist section heading above along with the questions/answers below.
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [No]
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes] All the proofs are included in the supplementary material.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [No]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] The details of the simulation setup are provided in the supplementary material.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [No]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] The citations can be found in Section 5.
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficiencyorderingofstochasticgradientdescent/images.zip b/efficiencyorderingofstochasticgradientdescent/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..dc5f56abf32246c5bb52e1eb1a8ba362b9cd4a85
--- /dev/null
+++ b/efficiencyorderingofstochasticgradientdescent/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:086b9c1076cea972f100ce78508e283de89c25385e3974e67c20d8abe86950dc
+size 228338
diff --git a/efficiencyorderingofstochasticgradientdescent/layout.json b/efficiencyorderingofstochasticgradientdescent/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..2c0edf7402b6320acef808948dfbac76320349d2
--- /dev/null
+++ b/efficiencyorderingofstochasticgradientdescent/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:02c9b620bb8e0a261a75bf7b9053c1f914a2e245ff35afea480bc5deb616dbfb
+size 612194
diff --git a/efficientactivelearningwithabstention/020fba88-45d0-42df-88e5-f649d3bae703_content_list.json b/efficientactivelearningwithabstention/020fba88-45d0-42df-88e5-f649d3bae703_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..a9b1d98b13d9bfe11568dff6f59e6dbd03d20663
--- /dev/null
+++ b/efficientactivelearningwithabstention/020fba88-45d0-42df-88e5-f649d3bae703_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c2d08910e0600a2e63aaea26a113dc9d495db4e1633592577ffc7b9798970ba4
+size 89703
diff --git a/efficientactivelearningwithabstention/020fba88-45d0-42df-88e5-f649d3bae703_model.json b/efficientactivelearningwithabstention/020fba88-45d0-42df-88e5-f649d3bae703_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..012bc2e88a091019759f937d9a4e573836d6f4c2
--- /dev/null
+++ b/efficientactivelearningwithabstention/020fba88-45d0-42df-88e5-f649d3bae703_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5a09b8d77b6572347f32d8677bf1bd8b81caded4db718dd635b93734b0e73c6c
+size 114270
diff --git a/efficientactivelearningwithabstention/020fba88-45d0-42df-88e5-f649d3bae703_origin.pdf b/efficientactivelearningwithabstention/020fba88-45d0-42df-88e5-f649d3bae703_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..acf9db78dd6ad1146426852a89e3028a93fcf1f9
--- /dev/null
+++ b/efficientactivelearningwithabstention/020fba88-45d0-42df-88e5-f649d3bae703_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b6272b636c21795f8ecaec7dfc6bb23721f42ffe9186e9f33584812d21ce14fe
+size 407929
diff --git a/efficientactivelearningwithabstention/full.md b/efficientactivelearningwithabstention/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..a16a0a31b1de7d5ed48f7f92fb27667105b4fdfb
--- /dev/null
+++ b/efficientactivelearningwithabstention/full.md
@@ -0,0 +1,352 @@
+# Efficient Active Learning with Abstention
+
+Yinglun Zhu
+
+Department of Computer Sciences
+
+University of Wisconsin-Madison
+
+Madison, WI 53706
+
+yinglun@cs.wisc.edu
+
+Robert Nowak
+
+Department of Electrical and Computer Engineering
+
+University of Wisconsin-Madison
+
+Madison, WI 53706
+
+rdnowak@wisc.edu
+
+# Abstract
+
+The goal of active learning is to achieve the same accuracy achievable by passive learning, while using much fewer labels. Exponential savings in terms of label complexity have been proved in very special cases, but fundamental lower bounds show that such improvements are impossible in general. This suggests a need to explore alternative goals for active learning. Learning with abstention is one such alternative. In this setting, the active learning algorithm may abstain from prediction and incur an error that is marginally smaller than random guessing. We develop the first computationally efficient active learning algorithm with abstention. Our algorithm provably achieves polylog $\left(\frac{1}{\varepsilon}\right)$ label complexity, without any low noise conditions. Such performance guarantee reduces the label complexity by an exponential factor, relative to passive learning and active learning that is not allowed to abstain. Furthermore, our algorithm is guaranteed to only abstain on hard examples (where the true label distribution is close to a fair coin), a novel property we term proper abstention that also leads to a host of other desirable characteristics (e.g., recovering minimax guarantees in the standard setting, and avoiding the undesirable "noise-seeking" behavior often seen in active learning). We also provide novel extensions of our algorithm that achieve constant label complexity and deal with model misspecification.
+
+# 1 Introduction
+
+Active learning aims at learning an accurate classifier with a small number of labeled data points (Settles, 2009; Hanneke, 2014). Active learning has become increasingly important in modern application of machine learning, where unlabeled data points are abundant yet the labeling process requires expensive time and effort. Empirical successes of active learning have been observed in many areas (Tong and Koller, 2001; Gal et al., 2017; Sener and Savarese, 2018). In noise-free or certain low-noise cases (i.e., under Massart noise (Massart and Nédélec, 2006)), active learning algorithms with provable exponential savings over the passive counterpart have been developed (Balcan et al., 2007; Hanneke, 2007; Dasgupta et al., 2009; Hsu, 2010; Dekel et al., 2012; Hanneke, 2014; Zhang and Chaudhuri, 2014; Krishnamurthy et al., 2019; Katz-Samuels et al., 2021). On the other hand, however, not much can be said in the general case. In fact, Käärääinen (2006) provides a $\Omega\left(\frac{1}{\varepsilon^2}\right)$ lower bound by reducing active learning to a simple mean estimation problem: It takes $\Omega\left(\frac{1}{\varepsilon^2}\right)$ samples to distinguish $\eta(x) = \frac{1}{2} + \varepsilon$ and $\eta(x) = \frac{1}{2} - \varepsilon$ . Even with the relatively benign Tsybakov noise (Tsybakov, 2004), Castro and Nowak (2006, 2008) derive a $\Omega(\mathrm{poly}\left(\frac{1}{\varepsilon}\right))$ lower bound, again, indicating that exponential speedup over passive learning is not possible in general. These fundamental lower bounds lay out statistical barriers to active learning, and suggests considering a refinement of the label complexity goals in active learning (Käärääinen, 2006).
+
+Inspecting these lower bounds, one can see that active learning suffers from classifying hard examples that are close to the decision boundary. However, do we really require a trained classifier to do well
+
+on those hard examples? In high-risk domains such as medical imaging, it makes more sense for the classifier to abstain from making the decision and leave the problem to a human expert. Such idea is formalized under Chow's error (Chow, 1970): Whenever the classifier chooses to abstain, a loss that is barely smaller than random guessing, i.e., $\frac{1}{2} - \gamma$ , is incurred. The parameter $\gamma$ should be thought as a small positive quantity, e.g., $\gamma = 0.01$ . The inclusion of abstention is not only practically interesting, but also provides a statistical refinement of the label complexity goal of active learning: Achieving exponential improvement under Chow's excess error. When abstention is allowed as an action, Puchkin and Zhivotovskiy (2021) shows, for the first time, that exponential improvement in label complexity can be achieved by active learning in the general setting. However, the approach provided in Puchkin and Zhivotovskiy (2021) can not be efficiently implemented. Their algorithm follows the disagreement-based approach and requires maintaining a version space and checking whether or not an example lies in the region of disagreement. It is not clear how to generally implement these operations besides enumeration (Beygelzimer et al., 2010). Moreover, their algorithm relies on an Empirical Risk Minimization (ERM) oracle, which is known to be NP-Hard even for a simple linear hypothesis class (Guruswami and Raghavendra, 2009).
+
+In this paper, we break the computational barrier and design an efficient active learning algorithm with exponential improvement in label complexity relative to conventional passive learning. The algorithm relies on weighted square loss regression oracle, which can be efficiently implemented in many cases (Krishnamurthy et al., 2017, 2019; Foster et al., 2018, 2020). The algorithm also abstains properly, i.e., abstain only when it is the optimal choice, which allows us to easily translate the guarantees to the standard excess error. Along the way, we propose new noise-seeking noise conditions and show that: "uncertainty-based" active learners can be easily trapped, yet our algorithm provably overcome these noise-seeking conditions. As an extension, we also provide the first algorithm that enjoys constant label complexity for a general set of regression functions.
+
+# 1.1 Problem setting
+
+Let $\mathcal{X}$ denote the input space and $\mathcal{Y}$ denote the label space. We focus on the binary classification problem where $\mathcal{Y} = \{+1, -1\}$ . The joint distribution over $\mathcal{X} \times \mathcal{Y}$ is denoted as $\mathcal{D}_{\mathcal{X}\mathcal{Y}}$ . We use $\mathcal{D}_{\mathcal{X}}$ to denote the marginal distribution over the input space $\mathcal{X}$ , and use $\mathcal{D}_{\mathcal{Y}|x}$ to denote the conditional distribution of $\mathcal{Y}$ with respect to any $x \in \mathcal{X}$ . We define $\eta(x) := \mathbb{P}_{y \sim \mathcal{D}_{\mathcal{Y}|x}}(y = +1)$ as the conditional probability of taking a positive label. We consider the standard active learning setup where $(x,y) \sim \mathcal{D}_{\mathcal{X}\mathcal{Y}}$ but $y$ is observed only after a label querying. We consider hypothesis class $\mathcal{H}: \mathcal{X} \to \mathcal{Y}$ . For any classifier $h \in \mathcal{H}$ , its (standard) error is defined as $\mathrm{err}(h) := \mathbb{P}_{(x,y) \sim \mathcal{D}_{\mathcal{X}\mathcal{Y}}} (h(x) \neq y)$ .
+
+Function approximation. We focus on the case where the hypothesis class $\mathcal{H}$ is induced from a set of regression functions $\mathcal{F}:\mathcal{X}\to [0,1]$ that predicts the conditional probability $\eta (x)$ . We write $\mathcal{H} = \mathcal{H}_{\mathcal{F}}\coloneqq \{h_f:f\in \mathcal{F}\}$ where $h_f(x)\coloneqq \mathrm{sign}(2f(x) - 1)$ . The "size" of $\mathcal{F}$ is measured by the well-known complexity measure: the Pseudo dimension $\operatorname {Pdim}(\mathcal{F})$ (Pollard, 1984; Haussler, 1989, 1995). We assume $\operatorname {Pdim}(\mathcal{F}) < \infty$ throughout the paper. Following existing works in active learning (Dekel et al., 2012; Krishnamurthy et al., 2017, 2019) and contextual bandits (Agarwal et al., 2012; Foster et al., 2018; Foster and Rakhlin, 2020; Simchi-Levi and Xu, 2020), we make the following realizability assumption.
+
+Assumption 1 (Realizability). The learner is given a set of regressors $\mathcal{F}:\mathcal{X}\to [0,1]$ such that there exists a $f^{\star}\in \mathcal{F}$ characterize the true conditional probability, i.e., $f^{\star} = \eta$
+
+The realizability assumption allows rich function approximation, which strictly generalizes the setting with linear function approximation studied in active learning (e.g., in (Dekel et al., 2012)). We relax Assumption 1 in Section 4.2 to deal with model misspecification.
+
+Regression oracle. We consider a regression oracle over $\mathcal{F}$ , which is extensively studied in the literature in active learning and contextual bandits (Krishnamurthy et al., 2017, 2019; Foster et al., 2018, 2020). Given any set $\mathcal{S}$ of weighted examples $(w,x,y)\in \mathbb{R}_{+}\times \mathcal{X}\times \mathcal{Y}$ as input, the regression
+
+oracle outputs
+
+$$
+\widehat {f} = \underset {\bar {f} \in \mathcal {F}} {\arg \min } \sum_ {(w, x, y) \in \mathcal {S}} w (f (x) - y) ^ {2}. \tag {1}
+$$
+
+The regression oracle solves a convex optimization problem with respect to the regression function, and admits closed-form solutions in many cases, e.g., it is reduced to least squares when $f$ is linear. We view the implementation of the regression oracle as an efficient operation and quantify the computational complexity in terms of the number of calls to the regression oracle.
+
+Chow's excess error (Chow, 1970). Let $h^{\star} \coloneqq h_{f^{\star}} \in \mathcal{H}$ denote the Bayes classifier. The standard excess error of classifier $h \in \mathcal{H}$ is defined as $\mathrm{err}(h) - \mathrm{err}(h^{\star})$ . Since achieving exponential improvement (of active over passive learning) with respect to the standard excess error is impossible in general (Kääräinen, 2006), we introduce Chow's excess error next. We consider classifier of the form $\widehat{h}: \mathcal{X} \to \mathcal{Y} \cup \{\bot\}$ where $\bot$ denotes the action of abstention. For any fixed $0 < \gamma < \frac{1}{2}$ , the Chow's error is defined as
+
+$$
+\operatorname {e r r} _ {\gamma} (\widehat {h}) := \mathbb {P} _ {(x, y) \sim \mathcal {D} _ {\chi y}} (\widehat {h} (x) \neq y, \widehat {h} (x) \neq \bot) + (1 / 2 - \gamma) \cdot \mathbb {P} _ {(x, y) \sim \mathcal {D} _ {\chi y}} (\widehat {h} (x) = \bot). \quad (2)
+$$
+
+The parameter $\gamma$ can be chosen as a small constant, e.g., $\gamma = 0.01$ , to avoid excessive abstention: The price of abstention is only marginally smaller than random guess. The Chow's excess error is then defined as $\mathrm{err}_{\gamma}(\widehat{h}) - \mathrm{err}(h^{\star})$ (Puchkin and Zhivotovsky, 2021). For any fixed accuracy level $\varepsilon > 0$ , we aim at constructing a classifier $\widehat{h}: \mathcal{X} \to \mathcal{Y} \cup \{\bot\}$ with $\varepsilon$ Chow's excess error and $\mathrm{polylog}\left(\frac{1}{\varepsilon}\right)$ label complexity. We also relate Chow's excess error to standard excess error in Section 3.
+
+Remark 1. Competing against the optimal Chow's error, i.e., $\mathrm{err}_{\gamma}(\widehat{h}) - \inf_{h:\mathcal{X}\to \{+1, - 1,\bot \}}\mathrm{err}_{\gamma}(h)$ will eliminate active learning gains. As in Kääräinen (2006), it suffices to consider a simple problem with $\mathcal{X} = \{x\}$ . In order to achieve $\varepsilon$ excess error against the optimal Chow's classifier, we need to distinguish cases $\eta (x) = \frac{1}{2} -\gamma -2\varepsilon$ and $\eta (x) = \frac{1}{2} -\gamma +2\varepsilon$ , which inevitably requires $\Omega (\frac{1}{\varepsilon^2})$ samples. We defer a detailed discussion (with pictorial explanations) of Chow's excess error in Appendix B.
+
+# 1.2 Contributions and paper organization
+
+We provide informal statements of our main results in this section. Our results depend on complexity measures such as value function disagreement coefficient $\theta$ and eluder dimension $\mathfrak{e}$ (formally defined in Section 2 and Appendix C). These complexity measures are previously analyzed in contextual bandits (Russo and Van Roy, 2013; Foster et al., 2020) and we import them to the active learning setup. These complexity measures are well-bounded for many function classes of practical interests, e.g., we have $\theta, \mathfrak{e} = \widetilde{O}(d)$ for linear and generalized linear functions on $\mathbb{R}^d$ .
+
+Our first main contribution is that we design the first computationally efficient active learning algorithm (Algorithm 1) that achieves exponential labeling savings, without any low noise assumptions.
+
+Theorem 1 (Informal). There exists an algorithm that constructs a classifier $\widehat{h}:\mathcal{X}\to \{+1, - 1,\bot \}$ with Chow's excess error at most $\varepsilon$ and label complexity $\widetilde{O} (\frac{\theta\mathrm{Pdim}(\mathcal{F})}{\gamma^2}\cdot \mathrm{polylog}(\frac{1}{\varepsilon}))$ , without any low noise assumptions. The algorithm can be efficiently implemented via a regression oracle: It takes $\widetilde{O} (\frac{\theta\mathrm{Pdim}(\mathcal{F})}{\varepsilon\gamma^3})$ oracle calls for general $\mathcal{F}$ , and $\widetilde{O} (\frac{\theta\mathrm{Pdim}(\mathcal{F})}{\varepsilon\gamma})$ oracle calls for convex $\mathcal{F}$ .
+
+The formal statements are provided in Section 2. The statistical guarantees (i.e., label complexity) in Theorem 1 is similar to the one achieved in Puchkin and Zhivotovsky (2021), with one critical difference: The label complexity provided in Puchkin and Zhivotovsky (2021) is in terms of the classifier-based disagreement coefficient $\tilde{\theta}$ (Hanneke, 2014). Even for a set of linear classifier, $\tilde{\theta}$ is only known to be bounded in special cases, e.g., when $\mathcal{D}_{\mathcal{X}}$ is uniform over the unit sphere (Hanneke, 2007). On the other hand, we have $\theta \leq d$ for any $\mathcal{D}_{\mathcal{X}}$ (Foster et al., 2020).
+
+We say that a classifier $\widehat{h}:\mathcal{X}\to \{+1, - 1,\bot \}$ enjoys proper abstention if it abstains only if abstention is indeed the optimal choice (based on Eq. (2)). For any classifier that enjoys proper abstention, one can easily relate its standard excess error to the Chow's excess error, under commonly studied Massart/Tsybakov noises (Massart and Nédélec, 2006; Tsybakov, 2004). The classifier obtained in Theorem 1 enjoys proper abstention, and achieves the following guarantees (formally stated in Section 3.1).
+
+Theorem 2 (Informal). Under Massart/Tsybakov noise, with appropriate adjustments, the classifier learned in Theorem 1 achieves the minimax optimal label complexity under standard excess error.
+
+We also propose new noise conditions that strictly generalize the usual Massart/Tsybakov noises, which we call noise-seeking conditions. At a high-level, the noise-seeking conditions allow abundant data points with $\eta(x)$ equal/close to $\frac{1}{2}$ . These points are somewhat "harmless" since it hardly matters what label is predicted at that point (in terms of excess error). These seemingly "harmless" data points can, however, cause troubles for any active learning algorithm that requests the label for any point that is uncertain, i.e., the algorithm cannot decide if $|\eta(x) - \frac{1}{2}|$ is strictly greater than 0. We call such algorithms "uncertainty-based" active learners. These algorithms could wastefully sample in these "harmless" regions, ignoring other regions where erring could be much more harmful. We derive the following proposition (formally stated in Section 3.2) under these noise-seeking conditions.
+
+Proposition 1 (Informal). For any labeling budget $B \gtrsim \frac{1}{\gamma^2} \cdot \mathrm{polylog}\left(\frac{1}{\varepsilon}\right)$ , there exists a learning problem such that (1) any uncertainty-based active learner suffers standard excess error $\Omega(B^{-1})$ ; yet (2) the classifier $\widehat{h}$ learned in Theorem 1 achieves standard excess error at most $\varepsilon$ .
+
+The above result demonstrates the superiority of our algorithm over any "uncertainty-based" active learner. Moreover, we show that, under these strictly harder noise-seeking conditions, our algorithm still achieve guarantees similar to the ones stated in Theorem 2.
+
+Before presenting our next main result, we first consider a simple active learning problem with $\mathcal{X} = \{x\}$ . Under Massart noise, we have $|\eta(x) - \frac{1}{2}| \geq \tau_0$ for some constant $\tau_0 > 0$ . Thus, it takes no more than $O(\tau_0^{-2} \log \frac{1}{\delta})$ labels to achieve $\varepsilon$ standard excess error, no matter how small $\varepsilon$ is. This example shows that, at least in simple cases, we can expect to achieve a constant label complexity for active learning, with no dependence on $\frac{1}{\varepsilon}$ at all. To the best of our knowledge, our next result provides the first generalization of such phenomenon to a general set of (finite) regression functions, as long as its eluder dimension $\mathfrak{e}$ is bounded.
+
+Theorem 3 (Informal). Under Massart noise with parameter $\tau_0$ and a general (finite) set of regression function $\mathcal{F}$ . There exists an algorithm that returns a classifier with standard excess error at most $\varepsilon$ and label complexity $O\left(\frac{\varepsilon \cdot \log(|\mathcal{F}| / \delta)}{\tau_0^2}\right)$ , which is independent of $\frac{1}{\varepsilon}$ .
+
+A similar constant label complexity holds with Chow's excess error, without any low noise assumptions. We also provide discussion on why previous algorithms do not achieve such constant label complexity, even in the case with linear functions. We defer formal statements and discussion to Section 4.1. In Section 4.2, we relax Assumption 1 and propose an algorithm that can deal with model misspecification.
+
+Paper organization. The rest of this paper is organized as follows. We present our main algorithm and its guarantees in Section 2. We further analyze our algorithm under standard excess error in Section 3, and discuss other important properties of the algorithm. Extensions of our algorithm, e.g., achieving constant label complexity and dealing with model misspecification, are provided in Section 4. We defer the discussion of additional related work and all proofs to the Appendix due to lack of space.
+
+# 2 Efficient active learning with abstention
+
+We provide our main algorithm (Algorithm 1) in this section. Algorithm 1 is an adaptation of the algorithm developed in Krishnamurthy et al. (2017, 2019), which studies active learning under the standard excess error (and Massart/Tsybakov noises). We additionally take the abstention option into consideration, and manually construct classifiers using the active set of (uneliminated) regression functions (which do not belong to the original hypothesis class). These new elements allow us to achieve $\varepsilon$ Chow's excess error with polylog $\left(\frac{1}{\varepsilon}\right)$ label complexity, without any low noise assumptions.
+
+# Algorithm 1 Efficient Active Learning with Abstention
+
+Input: Accuracy level $\varepsilon > 0$ , abstention parameter $\gamma \in (0,1/2)$ and confidence level $\delta \in (0,1)$ .
+
+1: Define $T \coloneqq \widetilde{O}(\frac{\theta\mathrm{Pdim}(\mathcal{F})}{\varepsilon\gamma})$ , $M \coloneqq \lceil \log_2 T \rceil$ and $C_{\delta} \coloneqq O(\mathrm{Pdim}(\mathcal{F}) \cdot \log (T / \delta))$ .
+2: Define $\tau_{m} := 2^{m}$ for $m \geq 1$ , $\tau_{0} := 0$ and $\beta_{m} := (M - m + 1) \cdot C_{\delta}$ .
+3: for epoch $m = 1,2,\ldots ,M$ do
+4: Get $\widehat{f}_m\coloneqq \arg \min_{f\in \mathcal{F}}\sum_{t = 1}^{\tau_m - 1}Q_t(f(x_t) - y_t)^2$
+
+// We use $Q_{t} \in \{0,1\}$ to indicate whether the label of $x_{t}$ is queried.
+
+5: (Implicitly) Construct active set of regression functions $\mathcal{F}_m\subseteq \mathcal{F}$ as
+
+$$
+\mathcal {F} _ {m} := \left\{f \in \mathcal {F}: \sum_ {t = 1} ^ {\tau_ {m - 1}} Q _ {t} (f (x _ {t}) - y _ {t}) ^ {2} \leq \sum_ {t = 1} ^ {\tau_ {m - 1}} Q _ {t} (\widehat {f} _ {m} (x _ {t}) - y _ {t}) ^ {2} + \beta_ {m} \right\}.
+$$
+
+6: Construct classifier $\widehat{h}_m:\mathcal{X}\to \{+1, - 1,\bot \}$ as
+
+$$
+\widehat {h} _ {m} (x) := \left\{ \begin{array}{l l} \bot , & \text {i f [ l c b} (x; \mathcal {F} _ {m}), \text {u c b} (x; \mathcal {F} _ {m}) ] \subseteq \big [ \frac {1}{2} - \gamma , \frac {1}{2} + \gamma \big ]; \\ \text {s i g n} (2 \widehat {f} _ {m} (x) - 1), & \text {o . w .} \end{array} \right.
+$$
+
+and construct query function $g_{m}(x) \coloneqq \mathbb{1}\big(\frac{1}{2} \in (\mathsf{lcb}(x; \mathcal{F}_{m}), \mathsf{ucb}(x; \mathcal{F}_{m}))\big) \cdot \mathbb{1}(\widehat{h}_{m}(x) \neq \bot)$ .
+
+7: if epoch $m = M$ then
+8: Return classifier $\widehat{h}_M$ .
+9: for time $t = \tau_{m - 1} + 1,\dots ,\tau_m$ do
+0: Observe $x_{t} \sim \mathcal{D}_{\mathcal{X}}$ . Set $Q_{t} \coloneqq g_{m}(x_{t})$
+1: if $Q_{t} = 1$ then
+2: Query the label $y_{t}$ of $x_{t}$ .
+
+Algorithm 1 runs in epochs of geometrically increasing lengths. At the beginning of epoch $m \in [M]$ , Algorithm 1 first computes the empirical best regression function $\widehat{f}_m$ that achieves the smallest cumulative square loss over previously labeled data points $(\widehat{f}_1$ can be selected arbitrarily); it then (implicitly) constructs an active set of regression functions $\mathcal{F}_m$ , where the cumulative square loss of each $f \in \mathcal{F}_m$ is not too much larger than the cumulative square loss of empirical best regression function $\widehat{f}_m$ . For any $x \in \mathcal{X}$ , based on the active set of regression functions, Algorithm 1 constructs a lower bound $\operatorname{lcb}(x; \mathcal{F}_m) := \inf_{f \in \mathcal{F}_m} f(x)$ and an upper bound $\operatorname{ucb}(x; \mathcal{F}_m) := \sup_{f \in \mathcal{F}_m} f(x)$ for the true conditional probability $\eta(x)$ . An empirical classifier $\widehat{h}_m : \mathcal{X} \to \{+1, -1, \bot\}$ and a query function $g_m : \mathcal{X} \to \{0, 1\}$ are then constructed based on these confidence ranges and the abstention parameter $\gamma$ . For any time step $t$ within epoch $m$ , Algorithm 1 queries the label of the observed data point $x_t$ if and only if $Q_t := g_m(x_t) = 1$ . Algorithm 1 returns $\widehat{h}_M$ as the learned classifier.
+
+We now discuss the empirical classifier $\widehat{h}_m$ and the query function $g_m$ in more detail. Consider the event where $f^{\star} \in \mathcal{F}_m$ for all $m \in [M]$ , which can be shown to hold with high probability. The constructed confidence intervals are valid under this event, i.e., $\eta(x) \in [\mathrm{lcb}(x; \mathcal{F}_m), \mathrm{ucb}(x; \mathcal{F}_m)]$ . First, let us examine the conditions that determine a label query. The label of $x$ is not queried if
+
+- Case 1: $\widehat{h}_m(x) = \bot$ . We have $\eta(x) \in [\mathsf{cb}(x; \mathcal{F}_m), \mathsf{ucb}(x; \mathcal{F}_m)] \subseteq [\frac{1}{2} - \gamma, \frac{1}{2} + \gamma]$ . Abstention leads to the smallest error (Herbei and Wegkamp, 2006), and no query is needed.
+- Case 2: $\frac{1}{2} \notin (\operatorname{lcb}(x; \mathcal{F}_m), \operatorname{ucb}(x; \mathcal{F}_m))$ . We have $\operatorname{sign}(2\widehat{f}_m(x) - 1) = \operatorname{sign}(2f^\star(x) - 1)$ . Thus, no excess error is incurred and there is no need to query.
+
+The only case when label query is issued, and thus when the classifier $\widehat{h}_m$ may suffer from excess error, is when
+
+$$
+\frac {1}{2} \in (\operatorname {l c b} (x; \mathcal {F} _ {m}), \operatorname {u c b} (x; \mathcal {F} _ {m})) \quad \text {a n d} \quad [ \operatorname {l c b} (x; \mathcal {F} _ {m}), \operatorname {u c b} (x; \mathcal {F} _ {m}) ] \not \subseteq \left[ \frac {1}{2} - \gamma , \frac {1}{2} + \gamma \right] \tag {3}
+$$
+
+hold simultaneously. Eq. (3) necessarily leads to the condition $w(x; \mathcal{F}_m) \coloneqq \mathrm{ucb}(x; \mathcal{F}_m) - \mathrm{lcb}(x; \mathcal{F}_m) > \gamma$ . Our theoretical analysis shows that the event must $\mathbb{1}(w(x; \mathcal{F}_m) > \gamma)$ happens in-
+
+frequently, and its frequency is closely related to the so-called value function disagreement coefficient (Foster et al., 2020), which we introduce as follows.
+
+Definition 1 (Value function disagreement coefficient). For any $f^{\star} \in \mathcal{F}$ and $\gamma_0, \varepsilon_0 > 0$ , the value function disagreement coefficient $\theta_{f^{\star}}^{\mathrm{val}}(\mathcal{F}, \gamma_0, \varepsilon_0)$ is defined as
+
+$$
+\sup _ {\mathcal {D} _ {\mathcal {X}}} \sup _ {\gamma > \gamma_ {0}, \varepsilon > \varepsilon_ {0}} \left\{\frac {\gamma^ {2}}{\varepsilon^ {2}} \cdot \mathbb {P} _ {\mathcal {D} _ {\mathcal {X}}} \left(\exists f \in \mathcal {F}: | f (x) - f ^ {\star} (x) | > \gamma , \| f - f ^ {\star} \| _ {\mathcal {D} _ {\mathcal {X}}} \leq \varepsilon\right) \right\} \vee 1,
+$$
+
+where $\| f\|_{\mathcal{D}_{\mathcal{X}}}^2 \coloneqq \mathbb{E}_{x\sim \mathcal{D}_{\mathcal{X}}}[f^2 (x)]$
+
+Combining the insights discussed above, we derive the following label complexity guarantee for Algorithm 1 (we use $\theta \coloneqq \sup_{f^{\star}\in \mathcal{F},\iota >0}\theta_{f^{\star}}^{\mathrm{val}}(\mathcal{F},\gamma /2,\iota)$ and discuss its boundedness below).
+
+Theorem 4. With probability at least $1 - 2\delta$ , Algorithm 1 returns a classifier with Chow's excess error at most $\varepsilon$ and label complexity $O\left(\frac{\theta\mathrm{Pdim}(\mathcal{F})}{\gamma^2}\cdot \log^2\left(\frac{\theta\mathrm{Pdim}(\mathcal{F})}{\varepsilon\gamma}\right)\cdot \log\left(\frac{\theta\mathrm{Pdim}(\mathcal{F})}{\varepsilon\gamma\delta}\right)\right)$ .
+
+Theorem 4 shows that Algorithm 1 achieves exponential label savings (i.e., $\mathrm{polylog}(\frac{1}{\varepsilon}))$ without any low noise assumptions. We discuss the result in more detail next.
+
+- Boundedness of $\theta$ . The value function disagreement coefficient is well-bounded for many function classes of practical interests. For instance, we have $\theta \leq d$ for linear functions on $\mathbb{R}^d$ and $\theta \leq C_{\mathrm{link}} \cdot d$ for generalized linear functions (where $C_{\mathrm{link}}$ is a quantity related to the link function). Moreover, $\theta$ is always upper bounded by complexity measures such as (squared) star number and eluder dimension (Foster et al., 2020). See Appendix C for the detailed definitions/bounds.
+- Comparison to Puchkin and Zhivotovskiy (2021). The label complexity bound derived in Theorem 4 is similar to the one derived in Puchkin and Zhivotovskiy (2021), with one critical difference: The bound derived in Puchkin and Zhivotovskiy (2021) is in terms of classifier-based disagreement coefficient $\tilde{\theta}$ (Hanneke, 2014). Even in the case with linear classifiers, $\tilde{\theta}$ is only known to be bounded under additional assumptions, e.g., when $\mathcal{D}_{\mathcal{X}}$ is uniform over the unit sphere.
+
+Computational efficiency. We discuss how to efficiently implement Algorithm 1 with the regression oracle defined in Eq. (1). Our implementation relies on subroutines developed in Krishnamurthy et al. (2017); Foster et al. (2018), which allow us to approximate confidence bounds $\mathsf{ucb}(x;\mathcal{F}_m)$ and $\mathsf{lcb}(x;\mathcal{F}_m)$ up to $\alpha$ approximation error with $O\left(\frac{1}{\alpha^2}\log \frac{1}{\alpha}\right)$ (or $O(\log \frac{1}{\alpha})$ when $\mathcal{F}$ is convex and closed under pointwise convergence) calls to the regression oracle. To achieve the same theoretical guarantees shown in Theorem 4 (up to changes in constant terms), we show that it suffices to (i) control the approximation error at level $O\left(\frac{\gamma}{\log T}\right)$ , (ii) construct the approximated confidence bounds $\widehat{\mathsf{cb}}(x;\mathcal{F}_m)$ and $\widehat{\mathsf{ucb}}(x;\mathcal{F}_m)$ in a way such that the confidence region is non-increasing with respect to the epoch $m$ , i.e., $(\widehat{\mathsf{cb}}(x;\mathcal{F}_m), \widehat{\mathsf{ucb}}(x;\mathcal{F}_m)) \subseteq (\widehat{\mathsf{cb}}(x;\mathcal{F}_{m-1}), \widehat{\mathsf{ucb}}(x;\mathcal{F}_{m-1}))$ (this ensures that the sampling region is non-increasing even with approximated confidence bounds, which is important to our theoretical analysis), and (iii) use the approximated confidence bounds $\widehat{\mathsf{cb}}(x;\mathcal{F}_m)$ and $\widehat{\mathsf{ucb}}(x;\mathcal{F}_m)$ to construct the classifier $\widehat{h}_m$ and the query function $g_m$ . We provide our guarantees as follows, and leave details to Appendix E (we redefine $\theta := \sup_{f^* \in \mathcal{F}, \iota > 0} \theta_{f^*}^{\mathrm{val}}(\mathcal{F}, \gamma/4, \iota)$ in the Theorem 5 to account for approximation error).
+
+Theorem 5. Algorithm 1 can be efficiently implemented via the regression oracle and enjoys the same theoretical guarantees stated in Theorem 4. The number of oracle calls needed is $\widetilde{O} \left( \frac{\theta \operatorname{Pdim}(\mathcal{F})}{\varepsilon \gamma^3} \right)$
+
+for a general set of regression functions $\mathcal{F}$ , and $\widetilde{O} \left( \frac{\theta \operatorname{Pdim}(\mathcal{F})}{\varepsilon \gamma} \right)$ when $\mathcal{F}$ is convex and closed under pointwise convergence. The per-example inference time of the learned $\widehat{h}_M$ is $\widetilde{O} \left( \frac{1}{\gamma^2} \log^2 \left( \frac{\theta \operatorname{Pdim}(\mathcal{F})}{\varepsilon} \right) \right)$ for general $\mathcal{F}$ , and $\widetilde{O} (\log \frac{1}{\gamma})$ when $\mathcal{F}$ is convex and closed under pointwise convergence.
+
+With Theorem 5, we provide the first computationally efficient active learning algorithm that achieves exponential label savings, without any low noise assumptions.
+
+# 3 Guarantees under standard excess error
+
+We provide guarantees for Algorithm 1 under standard excess error. In Section 3.1, we show that Algorithm 1 can be used to recover the usual minimax label complexity under Massart/Tsybakov noise; we also provide a new learning paradigm based on Algorithm 1 under limited budget. In Section 3.2, we show that Algorithm 1 provably avoid the undesired noise-seeking behavior often seen in active learning.
+
+# 3.1 Recovering minimax optimal label complexity
+
+One way to convert an abstaining classifier $\widehat{h}:\mathcal{X}\to \mathcal{Y}\cup \{\bot \}$ into a standard classifier $\check{h}:\mathcal{X}\rightarrow \mathcal{Y}$ is by randomizing the prediction in its abstention region, i.e., if $\widehat{h} (x) = \bot$ , then its randomized version $\check{h} (x)$ predicts $+1 / - 1$ with equal probability (Puchkin and Zhivotovskiy, 2021). With such randomization, the standard excess error of $\check{h}$ can be characterized as
+
+$$
+\operatorname {e r r} (\check {h}) - \operatorname {e r r} (h ^ {\star}) = \operatorname {e r r} _ {\gamma} (\widehat {h}) - \operatorname {e r r} (h ^ {\star}) + \gamma \cdot \mathbb {P} _ {x \sim \mathcal {D} _ {\mathcal {X}}} (\widehat {h} (x) = \bot). \tag {4}
+$$
+
+The standard excess error depends on the (random) abstention region of $\widehat{h}$ , which is difficult to quantify in general. To give a more practical characterization of the standard excess error, we introduce the concept of proper abstention in the following.
+
+Definition 2 (Proper abstention). A classifier $\widehat{h}:\mathcal{X}\to \mathcal{Y}\cup \{\bot \}$ enjoys proper abstention if and only if it abstains in regions where abstention is indeed the optimal choice, i.e., $\{x\in \mathcal{X}:\widehat{h} (x) = \bot \} \subseteq$ $\{x\in \mathcal{X}:\eta (x)\in [\frac{1}{2} -\gamma ,\frac{1}{2} +\gamma ]\} = :X_{\gamma}.$
+
+Proposition 2. The classifier $\widehat{h}$ returned by Algorithm 1 enjoys proper abstention. With randomization over the abstention region, we have the following upper bound on its standard excess error
+
+$$
+\operatorname {e r r} (\tilde {h}) - \operatorname {e r r} (h ^ {\star}) \leq \operatorname {e r r} _ {\gamma} (\hat {h}) - \operatorname {e r r} (h ^ {\star}) + \gamma \cdot \mathbb {P} _ {x \sim \mathcal {D} _ {\mathcal {X}}} (x \in \mathcal {X} _ {\gamma}). \tag {5}
+$$
+
+The proper abstention property of $\widehat{h}$ returned by Algorithm 1 is achieved via conservation: $\widehat{h}$ will avoid abstention unless it is absolutely sure that abstention is the optimal choice. To characterize the standard excess error of classifier with proper abstention, we only need to upper bound the term $\mathbb{P}_{x\sim \mathcal{D}_X}(x\in \mathcal{X}_\gamma)$ , which does not depends on the (random) classifier $\widehat{h}$ . Instead, it only depends on the marginal distribution. We next introduce the common Massart/Tsybakov noise conditions.
+
+Definition 3 (Massart noise, Massart and Nédélec (2006)). A distribution $\mathcal{D}_{\mathcal{X}\mathcal{Y}}$ satisfies the Massart noise condition with parameter $\tau_0 > 0$ if $\mathbb{P}_{x\sim \mathcal{D}_X}(|\eta (x) - 1 / 2|\leq \tau_0) = 0$ .
+
+Definition 4 (Tsybakov noise, Tsybakov (2004)). A distribution $\mathcal{D}_{\mathcal{X}\mathcal{Y}}$ satisfies the Tsybakov noise condition with parameter $\beta \geq 0$ and a universal constant $c > 0$ if $\mathbb{P}_{x\sim \mathcal{D}_X}(|\eta (x) - 1 / 2|\leq \tau)\leq c\tau^\beta$ for any $\tau >0$
+
+As in Balcan et al. (2007); Hanneke (2014), we assume knowledge of noise parameters (e.g., $\tau_0, \beta$ ). Together with the active learning lower established in Castro and Nowak (2006, 2008), and focusing on the dependence of $\varepsilon$ , our next theorem shows that Algorithm 1 can be used to recover the minimax label complexity in active learning, under the standard excess error.
+
+Theorem 6. With an appropriate choice of the abstention parameter $\gamma$ in Algorithm 1 and randomization over the abstention region, Algorithm 1 learns a classifier $\check{h}$ at the minimax optimal rates: To achieve $\varepsilon$ standard excess error, it takes $\widetilde{\Theta} (\tau_0^{-2})$ labels under Massart noise and takes $\widetilde{\Theta} (\varepsilon^{-2 / (1 + \beta)})$ labels under Tsybakov noise.
+
+Remark 2. In addition to recovering the minimax rates, the proper abstention property is desirable in practice: It guarantees that $\widehat{h}$ will not abstain on easy examples, i.e., it will not mistakenly flag easy examples as "hard-to-classify", thus eliminating unnecessary human labeling efforts.
+
+Algorithm 1 can also be used to provide new learning paradigms in the limited budget setting, which we introduce below. No prior knowledge of noise parameters are required in this setup.
+
+New learning paradigm under limited budget. Given any labeling budget $B > 0$ , we can then choose $\gamma \approx B^{-1/2}$ in Algorithm 1 to make sure the label complexity is never greater than $B$ (with high probability). The learned classifier enjoys Chow's excess error (with parameter $\gamma$ ) at most $\varepsilon$ ; its standard excess error (with randomization over the abstention region) can be analyzed by relating the $\gamma \cdot \mathbb{P}_{x \sim \mathcal{D}_X}(x \in \mathcal{X}_\gamma)$ term in Eq. (5) to the Massart/Tsybakov noise conditions, as discussed above.
+
+# 3.2 Abstention to avoid noise-seeking
+
+Active learning algorithms sometimes exhibit noise-seeking behaviors, i.e., oversampling in regions where $\eta(x)$ is close to the $\frac{1}{2}$ level. Such noise-seeking behavior is known to be a fundamental barrier to achieve low label complexity (under standard excess error), e.g., see Käärääinen (2006). We show in this section that abstention naturally helps avoiding noise-seeking behaviors and speeding up active learning.
+
+To better illustrate how properly abstaining classifiers avoid noise-seeking behavior, we first propose new noise conditions below, which strictly generalize the usual Massart/Tsybakov noises.
+
+Definition 5 (Noise-seeking Massart noise). A distribution $\mathcal{D}_{\mathcal{X}\mathcal{Y}}$ satisfies the noise-seeking Massart noise condition with parameters $0 \leq \zeta_0 < \tau_0 \leq 1/2$ if $\mathbb{P}_{x \sim \mathcal{D}_{\mathcal{X}}}(\zeta_0 < |\eta(x) - 1/2| \leq \tau_0) = 0$ .
+
+Definition 6 (Noise-seeking Tsybakov noise). A distribution $\mathcal{D}_{\mathcal{X}\mathcal{Y}}$ satisfies the noise-seeking Tsybakov noise condition with parameters $0 \leq \zeta_0 < 1/2$ , $\beta \geq 0$ and a universal constant $c > 0$ if $\mathbb{P}_{x \sim \mathcal{D}_{\mathcal{X}}}(\zeta_0 < |\eta(x) - 1/2| \leq \tau) \leq c\tau^\beta$ for any $\tau > \zeta_0$ .
+
+Compared to the standard Massart/Tsybakov noises, these newly proposed noise-seeking conditions allow arbitrary probability mass of data points whose conditional probability $\eta(x)$ is equal/close to $1/2$ . As a result, they can trick standard active learning algorithms into exhibiting the noise-seeking behaviors (and hence their names). We also mention that the parameter $\zeta_0$ should be considered as an extremely small quantity (e.g., $\zeta_0 \ll \varepsilon$ ), with the extreme case corresponding to $\zeta_0 = 0$ (which still allow arbitrary probability for region $\{x \in \mathcal{X} : \eta(x) = 1/2\}$ ).
+
+Ideally, any active learning algorithm should not be heavily affected by these noise conditions since it hardly matters (in terms of excess error) what label is predicted over region $\{x\in \mathcal{X}:\left|\eta (x) - 1 / 2\right|\leq \zeta_0\}$ . However, these seemingly benign noise-seeking conditions can cause troubles for any "uncertainty-based" active learner, i.e., any active learning algorithm that requests the label for any point that is uncertain (see Definition 10 in Appendix F for formal definition). In particular, under limited budget, we derive the following result.
+
+Proposition 3. Fix $\varepsilon, \delta, \gamma > 0$ . For any labeling budget $B \gtrsim \frac{1}{\gamma^2} \cdot \log^2\left(\frac{1}{\varepsilon\gamma}\right) \cdot \log\left(\frac{1}{\varepsilon\gamma\delta}\right)$ , there exists a learning problem (with a set of linear regression functions) satisfying Definition 5/Definition 6 such that (1) any "uncertainty-based" active learner suffers expected standard excess error $\Omega(B^{-1})$ ; yet (2) with probability at least $1 - \delta$ , Algorithm 1 returns a classifier with standard excess error at most $\varepsilon$ .
+
+The above result demonstrates the superiority of our Algorithm 1 over any "uncertainty-based" active learner. Moreover, we show that Algorithm 1 achieves similar guarantees as in Theorem 6 under the strictly harder noise-seeking conditions. Specifically, we have the following guarantees.
+
+Theorem 7. With an appropriate choice of the abstention parameter $\gamma$ in Algorithm 1 and randomization over the abstention region, Algorithm 1 learns a classifier $\check{h}$ with $\varepsilon + \zeta_0$ standard excess error after querying $\widetilde{\Theta}(\tau_0^{-2})$ labels under Definition 5 or querying $\widetilde{\Theta}(\varepsilon^{-2/(1+\beta)})$ labels under Definition 6.
+
+The special case of the noise-seeking condition with $\zeta_0 = 0$ is recently studied in (Kpotufe et al., 2021), where the authors conclude that no active learners can outperform the passive counterparts in the nonparametric regime. Theorem 7 shows that, in the parametric setting (with function approximation), Algorithm 1 provably overcomes these noise-seeking conditions.
+
+# 4 Extensions
+
+We provide two adaptations of our main algorithm (Algorithm 1) that can (1) achieve constant label complexity for a general set of regression functions (Section 4.1); and (2) adapt to model misspecification (Section 4.2). These two adaptations can also be efficiently implemented via regression oracle and enjoy similar guarantees stated in Theorem 5. We defer computational analysis to Appendix G and Appendix H.
+
+# 4.1 Constant label complexity
+
+We start by considering a simple problem instance with $\mathcal{X} = \{x\}$ , where active learning is reduced to mean estimation of $\eta(x)$ . Consider the Massart noise case where $\eta(x) \notin [\frac{1}{2} - \tau_0, \frac{1}{2} + \tau_0]$ . No matter how small the desired accuracy level $\varepsilon > 0$ is, the learner should not spend more than $O\left(\frac{\log(1 / \delta)}{\tau_0^2}\right)$ labels to correctly classify $x$ with probability at least $1 - \delta$ , which ensures 0 excess error. In the general setting, but with Chow's excess error, a similar result follows: It takes at most $O\left(\frac{\log(1 / \delta)}{\gamma^2}\right)$ samples to verify if $\eta(x)$ is contained in $[\frac{1}{2} - \gamma, \frac{1}{2} + \gamma]$ or not. Taking the optimal action within $\{+1, -1, \bot\}$ (based on Eq. (2)) then leads to 0 Chow's excess error. This reasoning shows that, at least in simple cases, one should be able to achieve constant label complexity no matter how small $\varepsilon$ is. One natural question to ask is as follows.
+
+Is it possible to achieve constant label complexity in the general case of active learning?
+
+We provide the first affirmative answer to the above question with a general set of regression function $\mathcal{F}$ (finite), and under general action space $\mathcal{X}$ and marginal distribution $\mathcal{D}_{\mathcal{X}}$ . The positive result is achieved by Algorithm 2 (deferred to Appendix G.2), which differs from Algorithm 1 in two aspects: (1) we drop the epoch scheduling, and (2) apply a tighter elimination step derived from an optimal stopping theorem. Another change comes from the analysis of the algorithm: Instead of analyzing with respect to the disagreement coefficient, we work with the eluder dimension $\mathfrak{e} := \sup_{f^{\star} \in \mathcal{F}} \mathfrak{e}_{f^{\star}}(\mathcal{F}, \gamma/2)$ . To do that, we analyze active learning from the perspective of regret minimization with selective querying (Dekel et al., 2012), which allows us to incorporate techniques developed in the field of contextual bandits (Russo and Van Roy, 2013; Foster et al., 2020). We defer a detailed discussion to Appendix G.1 and provide the following guarantees.
+
+Theorem 8. With probability at least $1 - 2\delta$ , Algorithm 2 returns a classifier with expected Chow's excess error at most $\varepsilon$ and label complexity $O\left(\frac{\mathfrak{e}\cdot\log(|\mathcal{F}| / \delta)}{\gamma^2}\right)$ , which is independent of $\frac{1}{\varepsilon}$ .
+
+Based on discussion in Section 3, we can immediately translate the above results into standard excess error guarantees under the Massart noise (with $\gamma$ replaced by $\tau_0$ ). We next discuss why existing algorithms/analyses do not guarantee constant label complexity, even in the linear case.
+
+1. Epoch scheduling. Many algorithms proceed in epochs and aim at halving the excess error after each epoch (Balcan et al., 2007; Zhang and Chaudhuri, 2014; Puchkin and Zhivotovskiy, 2021). One inevitably needs $\log \frac{1}{\varepsilon}$ epochs to achieve $\varepsilon$ excess error.
+2. Relating to disagreement coefficient. The algorithm presented in Krishnamurthy et al. (2019) does not use epoch scheduling. However, their label complexity are analyzed with disagreement coefficient, which incurs a $\sum_{t=1}^{1/\varepsilon} \frac{1}{t} = O\left(\log \frac{1}{\varepsilon}\right)$ term in the label complexity.
+
+Remark 3. Algorithm 2 also provides guarantees when $x$ is selected by an adaptive adversary (instead of i.i.d. sampled $x \sim \mathcal{D}_{\mathcal{X}}$ ). In that case, we simultaneously upper bound the regret and the label complexity (see Theorem 10 in Appendix G.2). Our results can be viewed as a generalization of the results developed in the linear case (Dekel et al., 2012).
+
+# 4.2 Dealing with model misspecification
+
+Our main results are developed under realizability (Assumption 1), which assumes that there exists a $f^{\star} \in \mathcal{F}$ such that $f^{\star} = \eta$ . In this section, we relax that assumption and allow model misspecification. We assume the learner is given a set of regression function $\mathcal{F}: \mathcal{X} \to [0,1]$ that may only approximate the conditional probability $\eta$ . More specifically, we make the following assumption.
+
+Assumption 2 (Model misspecification). There exists a $\overline{f} \in \mathcal{F}$ such that $\overline{f}$ approximates $\eta$ up to $\kappa > 0$ accuracy, i.e., $\sup_{x \in \mathcal{X}} |f(x) - \eta(x)| \leq \kappa$ .
+
+We use a variation of Algorithm 1 to adapt to model misspecification (Algorithm 3, deferred to Appendix H.1). Compared to Algorithm 1, the main change in Algorithm 3 is to apply a more conservative step in determining the active set $\mathcal{F}_m$ at each epoch: We maintain a larger active set of regression function to ensure that $\overline{f}$ is not eliminated throughout all epochs. Our algorithm proceeds without knowing the misspecification level $\kappa$ . However, the excess error bound presented next holds under the condition that $\kappa \leq \varepsilon$ (i.e., it requires that the misspecification is no larger than the desired accuracy). Abbreviate $\bar{\theta} := \sup_{\iota > 0} \theta_{\overline{f}}^{\mathrm{val}}(\mathcal{F}, \gamma/2, \iota)$ , we achieve the following guarantees.
+
+Theorem 9. Suppose $\kappa \leq \varepsilon$ . With probability at least $1 - 2\delta$ , Algorithm 3 returns a classifier with Chow's excess error $O(\varepsilon \cdot \bar{\theta} \cdot \log \left( \frac{\operatorname{Pdim}(\mathcal{F})}{\varepsilon \gamma \delta} \right))$ and label complexity $O \left( \frac{\bar{\theta} \operatorname{Pdim}(\mathcal{F})}{\gamma^2} \cdot \log^2 \left( \frac{\operatorname{Pdim}(\mathcal{F})}{\varepsilon \gamma} \right) \cdot \log \left( \frac{\operatorname{Pdim}(\mathcal{F})}{\varepsilon \gamma \delta} \right) \right)$ .
+
+We only provide guarantee when $\kappa \leq \varepsilon$ , since the learned classifier suffers from an additive $\kappa$ term in the excess error (see Appendix H.2 for more discussion). On the other hand, the (inefficient) algorithm provided in Puchkin and Zhivotovsky (2021) works without any assumption on the approximation error. An interesting future direction is to study the relation between computational efficiency and learning with general approximation error.
+
+# Acknowledgments and Disclosure of Funding
+
+We thank the anonymous reviewers for their helpful comments. This work is partially supported by NSF grant 1934612 and AFOSR grant FA9550-18-1-0166.
+
+# References
+
+Alekh Agarwal, Miroslav Dudík, Satyen Kale, John Langford, and Robert Schapire. Contextual bandit learning with predictable rewards. In Artificial Intelligence and Statistics, pages 19-26. PMLR, 2012.
+Alekh Agarwal, Daniel Hsu, Satyen Kale, John Langford, Lihong Li, and Robert Schapire. Taming the monster: A fast and simple algorithm for contextual bandits. In International Conference on Machine Learning, pages 1638-1646. PMLR, 2014.
+Martin Anthony. Uniform glivenko-cantelli theorems and concentration of measure in the mathematical modelling of learning. Research Report LSE-CDAM-2002-07, 2002.
+Maria-Florina Balcan, Andrei Broder, and Tong Zhang. Margin based active learning. In International Conference on Computational Learning Theory, pages 35-50. Springer, 2007.
+Alina Beygelzimer, Daniel J Hsu, John Langford, and Tong Zhang. Agnostic active learning without constraints. Advances in neural information processing systems, 23, 2010.
+Olivier Bousquet and Nikita Zhivotovsky. Fast classification rates without standard margin assumptions. Information and Inference: A Journal of the IMA, 10(4):1389-1421, 2021.
+Rui M Castro and Robert D Nowak. Upper and lower error bounds for active learning. In The 44th Annual Allerton Conference on Communication, Control and Computing, volume 2, page 1, 2006.
+Rui M Castro and Robert D Nowak. Minimax bounds for active learning. IEEE Transactions on Information Theory, 54(5):2339-2353, 2008.
+CK Chow. On optimum recognition error and reject tradeoff. IEEE Transactions on information theory, 16(1):41-46, 1970.
+
+Sanjoy Dasgupta, Adam Tauman Kalai, and Adam Tauman. Analysis of perceptron-based active learning. Journal of Machine Learning Research, 10(2), 2009.
+Ofer Dekel, Claudio Gentile, and Karthik Sridharan. Selective sampling and active learning from single and multiple teachers. The Journal of Machine Learning Research, 13(1):2655-2697, 2012.
+Dylan Foster and Alexander Rakhlin. Beyond ucb: Optimal and efficient contextual bandits with regression oracles. In International Conference on Machine Learning, pages 3199-3210. PMLR, 2020.
+Dylan Foster, Alekh Agarwal, Miroslav Dudík, Haipeng Luo, and Robert Schapire. Practical contextual bandits with regression oracles. In International Conference on Machine Learning, pages 1539-1548. PMLR, 2018.
+Dylan J Foster, Alexander Rakhlin, David Simchi-Levi, and Yunzong Xu. Instance-dependent complexity of contextual bandits and reinforcement learning: A disagreement-based perspective. arXiv preprint arXiv:2010.03104, 2020.
+David A Freedman. On tail probabilities for martingales. the Annals of Probability, pages 100-118, 1975.
+Yarin Gal, Riashat Islam, and Zoubin Ghahramani. Deep bayesian active learning with image data. In International Conference on Machine Learning, pages 1183-1192. PMLR, 2017.
+Venkatesan Guruswami and Prasad Raghavendra. Hardness of learning halfspaces with noise. SIAM Journal on Computing, 39(2):742-765, 2009.
+Steve Hanneke. A bound on the label complexity of agnostic active learning. In Proceedings of the 24th international conference on Machine learning, pages 353-360, 2007.
+Steve Hanneke. Theory of active learning. Foundations and Trends in Machine Learning, 7(2-3), 2014.
+David Haussler. Decision theoretic generalizations of the pac model for neural net and other learning applications. 1989.
+David Haussler. Sphere packing numbers for subsets of the boolean n-cube with bounded vapnikchervonenkis dimension. Journal of Combinatorial Theory, Series A, 69(2):217-232, 1995.
+Radu Herbei and Marten H Wegkamp. Classification with reject option. The Canadian Journal of Statistics/La Revue Canadienne de Statistique, pages 709-721, 2006.
+Daniel Joseph Hsu. Algorithms for active learning. PhD thesis, UC San Diego, 2010.
+Tzu-Kuo Huang, Alekh Agarwal, Daniel J Hsu, John Langford, and Robert E Schapire. Efficient and parsimonious agnostic active learning. Advances in Neural Information Processing Systems, 28, 2015.
+Matti Kääräinen. Active learning in the non-realizable case. In International Conference on Algorithmic Learning Theory, pages 63-77. Springer, 2006.
+Julian Katz-Samuels, Jifan Zhang, Lalit Jain, and Kevin Jamieson. Improved algorithms for agnostic pool-based active classification. In International Conference on Machine Learning, pages 5334-5344. PMLR, 2021.
+Vladimir Koltchinskii. Rademacher complexities and bounding the excess risk in active learning. The Journal of Machine Learning Research, 11:2457-2485, 2010.
+Samory Kpotufe, Gan Yuan, and Yunfan Zhao. Nuances in margin conditions determine gains in active learning. arXiv preprint arXiv:2110.08418, 2021.
+Akshay Krishnamurthy, Alekh Agarwal, Tzu-Kuo Huang, Hal Daume III, and John Langford. Active learning for cost-sensitive classification. In International Conference on Machine Learning, pages 1915-1924. PMLR, 2017.
+Akshay Krishnamurthy, Alekh Agarwal, Tzu-Kuo Huang, Hal Daumé III, and John Langford. Active learning for cost-sensitive classification. Journal of Machine Learning Research, 20:1-50, 2019.
+Tor Lattimore, Csaba Szepesvari, and Gellert Weisz. Learning with good feature representations in bandits and in rl with a generative model. In International Conference on Machine Learning, pages 5662-5670. PMLR, 2020.
+
+Andrea Locatelli, Alexandra Carpentier, and Samory Kpotufe. Adaptivity to noise parameters in nonparametric active learning. In Proceedings of the 2017 Conference on Learning Theory, PMLR, 2017.
+Pascal Massart and Élodie Nédélec. Risk bounds for statistical learning. The Annals of Statistics, 34 (5):2326-2366, 2006.
+Stanislav Minsker. Plug-in approach to active learning. Journal of Machine Learning Research, 13 (1), 2012.
+D Pollard. Convergence of Stochastic Processes. David Pollard, 1984.
+Nikita Puchkin and Nikita Zhivotovsky. Exponential savings in agnostic active learning through abstention. arXiv preprint arXiv:2102.00451, 2021.
+Daniel Russo and Benjamin Van Roy. Eluder dimension and the sample complexity of optimistic exploration. In NIPS, pages 2256-2264. CiteSeer, 2013.
+Ozan Sener and Silvio Savarese. Active learning for convolutional neural networks: A core-set approach. In International Conference on Learning Representations, 2018.
+Burr Settles. Active learning literature survey. 2009.
+Shubhanshu Shekhar, Mohammad Ghavamzadeh, and Tara Javidi. Active learning for classification with abstention. IEEE Journal on Selected Areas in Information Theory, 2(2):705-719, 2021.
+David Simchi-Levi and Yunzong Xu. Bypassing the monster: A faster and simpler optimal algorithm for contextual bandits under realizability. Available at SSRN 3562765, 2020.
+Simon Tong and Daphne Koller. Support vector machine active learning with applications to text classification. Journal of machine learning research, 2(Nov):45-66, 2001.
+Alexander B Tsybakov. Optimal aggregation of classifiers in statistical learning. The Annals of Statistics, 32(1):135-166, 2004.
+Chicheng Zhang and Kamalika Chaudhuri. Beyond disagreement-based agnostic active learning. Advances in Neural Information Processing Systems, 27, 2014.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] Our results in the misspecification setting (i.e., in Section 4.2) are derived under an assumption. We provide discussion on such assumption in Appendix H.2, and leave a comprehensive study of the problem for future work.
+(c) Did you discuss any potential negative societal impacts of your work? [N/A] Our paper is theoretical in nature, and there is no negative societal impact of our work in the foreseeable future.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes] Assumptions are clearly stated in the statement of each theorem.
+(b) Did you include complete proofs of all theoretical results? [Yes] Complete proofs are provided in the Appendix.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [N/A]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [N/A]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [N/A]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [N/A]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [N/A]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientactivelearningwithabstention/images.zip b/efficientactivelearningwithabstention/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..857eae97c51ff6fb78f5d95fd6edf71efe3b472b
--- /dev/null
+++ b/efficientactivelearningwithabstention/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:80ce7a9ae1276aeecda57a4639ba77bc58c2e1cca039beb088edb4d02b4aeb12
+size 71840
diff --git a/efficientactivelearningwithabstention/layout.json b/efficientactivelearningwithabstention/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..3da2308005a9995f598d99f5ae86359080ab53b2
--- /dev/null
+++ b/efficientactivelearningwithabstention/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d1ef61027000c1a4b215d45bbd33b016a53db6d037cb46b6bd0839d40fe445a7
+size 626864
diff --git a/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/fd9c9cb2-661a-4d38-87d9-6a23e60c34ec_content_list.json b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/fd9c9cb2-661a-4d38-87d9-6a23e60c34ec_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..f836f0e9512d6111614a1fa419680ae6f0196b9b
--- /dev/null
+++ b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/fd9c9cb2-661a-4d38-87d9-6a23e60c34ec_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9880e95d1752615b50bd4a92edb3996871c62083bfaf3a73992e9bf98870afc6
+size 91795
diff --git a/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/fd9c9cb2-661a-4d38-87d9-6a23e60c34ec_model.json b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/fd9c9cb2-661a-4d38-87d9-6a23e60c34ec_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..4bed995151f6d44d7cbd7c0a47658a3d5e96d539
--- /dev/null
+++ b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/fd9c9cb2-661a-4d38-87d9-6a23e60c34ec_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:43ee96364d1d8d8c99289b0d584ceeb2eb2c78a5a8dc59e3928d3c7912d76d26
+size 115587
diff --git a/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/fd9c9cb2-661a-4d38-87d9-6a23e60c34ec_origin.pdf b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/fd9c9cb2-661a-4d38-87d9-6a23e60c34ec_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..f40e66d43dcd33943310d844c00f4785aee9fc16
--- /dev/null
+++ b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/fd9c9cb2-661a-4d38-87d9-6a23e60c34ec_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bd02ce878b65eb56435933393a0880dca18056484f4047705e097d1cd8814479
+size 1843605
diff --git a/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/full.md b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..47c4574b3cd4f4d7dc3e839d18af43cc2d9a4471
--- /dev/null
+++ b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/full.md
@@ -0,0 +1,338 @@
+# Efficient Adversarial Training without Attacking: Worst-Case-Aware Robust Reinforcement Learning
+
+Yongyuan Liang†* Yanchao Sun‡* Ruijie Zheng‡ Furong Huang‡
+
+† Shanghai AI Lab, ‡ University of Maryland, College Park
+
+†cherylliang@outlook.com ‡{ycs,rzheng12,furongh}@umd.edu
+
+# Abstract
+
+Recent studies reveal that a well-trained deep reinforcement learning (RL) policy can be particularly vulnerable to adversarial perturbations on input observations. Therefore, it is crucial to train RL agents that are robust against any attacks with a bounded budget. Existing robust training methods in deep RL either treat correlated steps separately, ignoring the robustness of long-term rewards, or train the agents and RL-based attacker together, doubling the computational burden and sample complexity of the training process. In this work, we propose a strong and efficient robust training framework for RL, named Worst-case-aware Robust RL (WocaR-RL), that directly estimates and optimizes the worst-case reward of a policy under bounded $\ell_p$ attacks without requiring extra samples for learning an attacker. Experiments on multiple environments show that WocaR-RL achieves state-of-the-art performance under various strong attacks, and obtains significantly higher training efficiency than prior state-of-the-art robust training methods. The code of this work is available at https://github.com/umd-huang-lab/WocaR-RL.
+
+# 1 Introduction
+
+Deep reinforcement learning (DRL) has achieved impressive results by using deep neural networks (DNN) to learn complex policies in large-scale tasks. However, well-trained DNNs may drastically fail under adversarial perturbations of the input [1, 6]. Therefore, before deploying DRL policies to real-life applications, it is crucial to improve the robustness of deep policies against adversarial attacks, especially worst-case attacks that maximally depraves the performance of trained agents [42].
+
+A line of regularization-based robust methods [54, 33, 40] focuses on improving the robustness of the DNN itself and regularizes the policy network to output similar actions under bounded state perturbations. However, different from supervised learning problems, the vulnerability of a deep policy comes not only from the DNN approximator, but also from the dynamics of the RL environment [52]. These regularization-based methods neglect the intrinsic vulnerability of policies under the environment dynamics, and thus may still fail under strong attacks [42]. For example, in the go-home task shown in Figure 1, both the green policy and the red policy arrive home without rock collision, when there is no attack. However, although regularization-based methods may ensure a minor action change under a state perturbation, the red policy may still be susceptible to a low reward under attacks, as a very small divergence can lead it to the bomb. On the more robust to adversarial attacks since it stays away from the bomb. There the robustness of DNN approximators (such as the policy network), it is a policy with stronger intrinsic robustness.
+
+
+Figure 1: Policies have different vulnerabilities.
+
+There is another line of work considering the long-term robustness of a deep policy under strong adversarial attacks. In particular, it is theoretically proved [54, 42] that the strongest (worst-case) attacker against a policy can be learned as an RL problem, and training the agent under such a learned attacker can result in a robust policy. Zhang et al. [52] propose the Alternating Training with Learned Adversaries (ATLA) framework, which alternately trains an RL agent and an RL attacker. Sun et al. [42] further propose PA-ATLA, which alternately trains an agent and the proposed more efficient PA-AD RL attacker, obtaining state-of-the-art robustness in many MuJoCo environments. However, training an RL attacker requires extra samples from the environment, and the attacker's RL problem may even be more difficult and sample expensive to solve than the agent's original RL problem [52, 42], especially in large-scale environments such as Atari games with pixel observations. Therefore, although ATLA and PA-ATLA are able to achieve high long-term reward under attacks, they double the computational burden and sample complexity to train the robust agent.
+
+The above analysis of existing literature suggests two main challenges in improving the adversarial robustness of DRL agents: (1) correctly characterizing the long-term reward vulnerability of an RL policy, and (2) efficiently training a robust agent without requiring much more effort than vanilla training. To tackle these challenges, in this paper, we propose a generic and efficient robust training framework named Worst-case-aware Robust RL (WocaR-RL) that estimates and improves the long-term robustness of an RL agent.
+
+WocaR-RL has 3 key mechanisms. First, WocaR-RL introduces a novel worst-attack Bellman operator which uses existing off-policy samples to estimate the lower bound of the policy value under the worst-case attack. Compared to prior works [52, 42] which attempt to learn the worst-case attack by RL methods, WocaR-RL does not require any extra interaction with the environment. Second, using the estimated worst-case policy value, WocaR-RL optimizes the policy to select actions that not only achieve high natural future reward, but also achieve high worst-case reward when there are adversarial attacks. Therefore, WocaR-RL learns a policy with less intrinsic vulnerability. Third, WocaR-RL regularizes the policy network with a carefully designed state importance weight. As a result, the DNN approximator tolerates state perturbations, especially for more important states where decisions are crucial for future reward. The above 3 mechanisms can also be interpreted from a geometric perspective of adversarial policy learning, as detailed in Appendix B.
+
+Our contributions can be summarized as below. (1) We provide an approach to estimate the worst-case value of any policy under any bounded $\ell_p$ adversarial attacks. This helps evaluate the robustness of a policy without learning an attacker which requires extra samples and exploration. (2) We propose a novel and principled robust training framework for RL, named Worst-case-aware Robust RL (WocaR-RL), which characterizes and improves the worst-case robustness of an agent. WocaR-RL can be used to robustify existing DRL algorithms (e.g. PPO [39], DQN [32]). (3) We show by experiments that WocaR-RL achieve improved robustness against various adversarial attacks as well as higher efficiency, compared with state-of-the-art (SOTA) robust RL methods in many MuJoCo and Atari games. For example, compared to the SOTA algorithm PA-ATLA-PPO [42] in the Walker environment, we obtain $20\%$ more worst-case reward (under the strongest attack algorithm), with only about $50\%$ training samples and $50\%$ running time. Moreover, WocaR-RL learns more interpretable "robust behaviors" than PA-ATLA-PPO in Walker as shown in Figure 2.
+
+
+Previous robust agent (PA-ATLA-PPO): jumping with one leg
+
+
+
+
+Our robust agent: lowering down its body
+
+
+Figure 2: The robust Walker agents trained with (top) the state-of-the-art method PA-ATLA-PPO [42] and (bottom) our WocaR-RL. Although PA-ATLA-PPO agent also achieves high reward under attacks, it learns to jump with one leg, which is counter-intuitive and may indicate some level of overfitting to a specific attacker. In contrast, our WocaR-RL agent learns to lower down its body, which is more intuitive and interpretable. The full agent trajectories in Walker and other environments are provided in supplementary materials as GIF figures.
+
+# 2 Related Work
+
+Defending against Adversarial Perturbations on State Observations. (1) Regularization-based methods [54, 40, 33] enforce the policy to have similar outputs under similar inputs, which achieves certifiable performance for DQN in some Atari games. But in continuous control tasks, these methods may not reliably improve the worst-case performance. A recent work by Korkmaz [21] points out that these adversarially trained models may still be sensible to new perturbations. (2) Attack-driven methods train DRL agents with adversarial examples. Some early works [22, 4, 29, 34] apply weak or strong gradient-based attacks on state observations to train RL agents against adversarial perturbations. Zhang et al. [52] propose Alternating Training with Learned Adversaries (ATLA), which alternately trains an RL agent and an RL adversary and significantly improves the policy robustness in continuous control games. Sun et al. [42] further extend this framework to PA-ATLA with their proposed more advanced RL attacker PA-AD. Although ATLA and PA-ATLA achieve strong empirical robustness, they require training an extra RL adversary that can be computationally and sample expensive. (3) There is another line of work studying certifiable robustness of RL policies. Several works [27, 33, 9] computed lower bounds of the action value network $Q^{\pi}$ to certify robustness of action selection at every step. However, these bounds do not consider the distribution shifts caused by attacks, so some actions that appear safe for now can lead to extremely vulnerable future states and low long-term reward under future attacks. Moreover, these methods cannot apply to continuous action spaces. Kumar et al. and Wu et al.[23, 49] both extend randomized smoothing [7] to derive robustness certificates for trained policies. But these works mostly focus on theoretical analysis, and effective robust training approaches rather than robust training.
+
+Adversarial Defenses against Other Adversarial Attacks. Besides observation perturbations, attacks can happen in many other scenarios. For example, the agent's executed actions can be perturbed [50, 44, 45, 24]. Moreover, in a multi-agent game, an agent's behavior can create adversarial perturbations to a victim agent [13]. Pinto et al. [35] model the competition between the agent and the attacker as a zero-sum two-player game, and train the agent under a learned attacker to tolerate both environment shifts and adversarial disturbances. We point out that although we mainly consider state adversaries, our WocaR-RL can be extended to action attacks as formulated in Appendix C.5. Note that we focus on robustness against test-time attacks, different from poisoning attacks which alter the RL training process [3, 20, 41, 56, 36].
+
+Safe RL and Risk-sensitive RL. There are several lines of work that study RL under safety/risk constraints [18, 11, 10, 2, 46] or under intrinsic uncertainty of environment dynamics [26, 30]. However, these works do not deal with adversarial attacks, which can be adaptive to the learned policy. More comparison between these methods and our proposed method is discussed in Section 4.
+
+# 3 Preliminaries and Background
+
+Reinforcement Learning (RL). An RL environment is modeled by a Markov Decision Process (MDP), denoted by a tuple $\mathcal{M} = \langle S, \mathcal{A}, P, R, \gamma \rangle$ , where $\mathcal{S}$ is a state space, $\mathcal{A}$ is an action space, $P: S \times \mathcal{A} \to \Delta(S)$ is a stochastic dynamics model $^2$ , $R: S \times \mathcal{A} \to \mathbb{R}$ is a reward function and $\gamma \in [0,1)$ is a discount factor. An agent takes actions based on a policy $\pi: S \to \Delta(\mathcal{A})$ . For any policy, its natural performance can be measured by the value function $V^{\pi}(s) := \mathbb{E}_{P,\pi}[\sum_{t=0}^{\infty} \gamma^{t} R(s_{t}, a_{t}) | s_{0} = s]$ , and the action value function $Q^{\pi}(s, a) := \mathbb{E}_{P,\pi}[\sum_{t=0}^{\infty} \gamma^{t} R(s_{t}, a_{t}) | s_{0} = s, a_{0} = a]$ . We call $V^{\pi}$ the natural value and $Q^{\pi}$ the natural action value in contrast to the values under attacks, as will be introduced in Section 4.
+
+Deep Reinforcement Learning (DRL). In large-scale problems, a policy can be parameterized by a neural network. For example, value-based RL methods (e.g. DQN [32]) usually fit a Q network and take the greedy policy $\pi(s) = \operatorname{argmax}_a Q(s, a)$ . In actor-critic methods (e.g. PPO [39]), the learner directly learns a policy network and a critic network. In practice, an agent usually follows a stochastic policy during training that enables exploration, and executes a trained policy deterministically in test-time, e.g. the greedy policy learned with DQN. Throughout this paper, we use $\pi_{\theta}$ to denote the training-time stochastic policy parameterized by $\theta$ , while $\pi$ denotes the trained deterministic policy that maps a state to an action.
+
+Test-time Adversarial Attacks. After training, the agent is deployed into the environment and executes a pre-trained fixed policy $\pi$ . An attacker/adversary, during the deployment of the agent, may
+
+perturb the state observation of the agent/victim at every time step with a certain attack budget $\epsilon$ . Note that the attacker only perturbs the inputs to the policy, and the underlying state in the environment does not change. This is a realistic setting because real-world observations can come from noisy sensors or be manipulated by malicious attacks. For example, an auto-driving car receives sensory observations; an attacker may add imperceptible noise to the camera, or perturb the GPS signal, although the underlying environment (the road) remains unchanged. In this paper, we consider the $\ell_p$ thread model which is widely used in adversarial learning literature: at step $t$ , the attacker alters the observation $s_t$ into $\tilde{s}_t \in \mathcal{B}_{\epsilon}(s_t)$ , where $\mathcal{B}_{\epsilon}(s_t)$ is a $\ell_p$ norm ball centered at $s_t$ with radius $\epsilon$ . The above setting ( $\ell_p$ constrained observation attack) is the same with many prior works [19, 34, 54, 52, 42].
+
+# 4 Worst-case-aware Robust RL
+
+In this section, we present Worst-case-aware Robust RL (WocaR-RL), a generic framework that can be fused with any DRL approach to improve the adversarial robustness of an agent. We will introduce the three key mechanisms in WocaR-RL: worst-attack value estimation, worst-case-aware policy optimization, and value-enhanced state regularization, respectively. Then, we will illustrate how to incorporate these mechanisms into existing DRL algorithms to improve their robustness.
+
+# Mechanism 1: Worst-attack Value Estimation
+
+Traditional RL aims to learn a policy with the maximal value $V^{\pi}$ . However, in a real-world problem where observations can be noisy or even adversarially perturbed, it is not enough to only consider the natural value $V^{\pi}$ and $Q^{\pi}$ . As motivated in Figure 1, two policies with similar natural rewards can get totally different rewards under attacks. To comprehensively evaluate how good a policy is in an adversarial scenario and to improve its robustness, we should be aware of the lowest possible long-term reward of the policy when its observation is adversarially perturbed with a certain attack budget $\epsilon$ at every step (with an $\ell_p$ attack model introduced in Section 3).
+
+The worst-case value of a policy is, by definition, the cumulative reward obtained under the optimal attacker. As justified by prior works [54, 42], for any given victim policy $\pi$ and attack budget $\epsilon > 0$ , there exists an optimal attacker, and finding the optimal attacker is equivalent to learning the optimal policy in another MDP. We denote the optimal (deterministic) attacker's policy as $h^*$ . However, learning such an optimal attacker by RL algorithms requires extra interaction samples from the environment, due to the unknown dynamics. Moreover, learning the attacker by RL can be hard and expensive, especially when the state observation space is high-dimensional.
+
+Instead of explicitly learning the optimal attacker with a large amount of samples, we propose to directly estimate the worst-case cumulative reward of the policy by characterizing the vulnerability of the given policy. We first define the worst-attack action value of policy $\pi$ as $Q^{\pi}(s,a) \coloneqq \mathbb{E}_P[\sum_{t=0}^{\infty} \gamma^t R(s_t, \pi(h^*(s_t))) \mid s_0 = s, a_0 = a]$ . The worst-attack value $\underline{V}^{\pi}$ can be defined using $h^*$ in the same way, as shown in Definition A.1 in Appendix A. Then, we introduce a novel operator $\overline{T}^{\pi}$ , namely the worst-attack Bellman operator, defined as below.
+
+Definition 4.1 (Worst-attack Bellman Operator). For MDP $\mathcal{M}$ , given a fixed policy $\pi$ and attack radius $\epsilon$ , define the worst-attack Bellman operator $\underline{T}^{\pi}$ as
+
+$$
+\left(\underline {{\mathcal {T}}} ^ {\pi} Q\right) (s, a) := \mathbb {E} _ {s ^ {\prime} \sim P (s, a)} \left[ R (s, a) + \gamma \min _ {a ^ {\prime} \in \mathcal {A} _ {\mathrm {a d v}} \left(s ^ {\prime}, \pi\right)} Q \left(s ^ {\prime}, a ^ {\prime}\right) \right], \tag {1}
+$$
+
+where $\forall s\in S,\mathcal{A}_{\mathrm{adv}}(s,\pi)$ is defined as
+
+$$
+\mathcal {A} _ {\mathrm {a d v}} (s, \pi) := \{a \in \mathcal {A}: \exists \tilde {s} \in \mathcal {B} _ {\epsilon} (s) \text {s . t .} \pi (\tilde {s}) = a \}. \tag {2}
+$$
+
+Here $\mathcal{A}_{\mathrm{adv}}(s', \pi)$ denotes the set of actions an adversary can mislead the victim $\pi$ into selecting by perturbing the state $s'$ into a neighboring state $\tilde{s} \in \mathcal{B}_{\epsilon}(s')$ . This hypothetical perturbation to the future state $s'$ is the key for characterizing the worst-case long-term reward under attack. The following theorem associates the worst-attack Bellman operator and the worst-attack action value.
+
+Theorem 4.2 (Worst-attack Bellman Operator and Worst-attack Action Value). For any given policy $\pi$ , $\underline{T}^{\pi}$ is a contraction whose fixed point is $\underline{Q}^{\pi}$ , the worst-attack action value of $\pi$ under any $\ell_p$ observation attacks with radius $\epsilon$ .
+
+Theorem 4.2 proved in Appendix A suggests that the lowest possible cumulative reward of a policy under bounded observation attacks can be computed by worst-attack Bellman operator. The corresponding worst-attack value $\underline{V}^{\pi}$ can be obtained by $\underline{V}^{\pi}(s) = \min_{a\in \mathcal{A}_{\mathrm{adv}}(s,\pi)}\underline{Q}^{\pi}(s,a)$ .
+
+How to Compute $\mathcal{A}_{\mathrm{adv}}$ . To obtain $\mathcal{A}_{\mathrm{adv}}(s, \pi)$ , we need to identify the actions that can be the outputs of the policy $\pi$ when the input state $s$ is perturbed within $\mathcal{B}_{\epsilon}(s)$ . This can be solved by commonly-used convex relaxation of neural networks [15, 55, 48, 53, 14], where layer-wise lower and upper bounds of the neural network are derived. That is, we calculate $\overline{\pi}$ and $\underline{\pi}$ such that $\overline{\pi}(s) \geq \pi(\hat{s}) \geq \underline{\pi}(s), \forall \hat{s} \in \mathcal{B}_{\epsilon}(s)$ . With such a relaxation, we can obtain a superset of $\mathcal{A}_{\mathrm{adv}}$ , namely $\hat{\mathcal{A}}_{\mathrm{adv}}$ . Then, the fixed point of Equation (1) with $\mathcal{A}_{\mathrm{adv}}$ being replaced by $\hat{\mathcal{A}}_{\mathrm{adv}}$ becomes a lower bound of the worst-attack action value. For a continuous action space, $\hat{\mathcal{A}}_{\mathrm{adv}}(s, \pi)$ contains actions bounded by $\overline{\pi}(s)$ and $\underline{\pi}(s)$ . For a discrete action space, we can first compute the maximal and minimal probabilities of taking each action, and derive the set of actions that are likely to be selected. The computation of $\hat{\mathcal{A}}_{\mathrm{adv}}$ is not expensive, as there are many efficient convex relaxation methods [31, 53] which compute $\overline{\pi}$ and $\underline{\pi}$ with only constant-factor more computations than directly computing $\pi(s)$ . Experiment in Section 5 verifies the efficiency of our approach, where we use a well-developed toolbox auto_LiRPA [51] to calculate the convex relaxation. More implementation details and explanations are provided in Appendix C.1.
+
+Estimating Worst-attack Value. Note that the worst-attack Bellman operator $\underline{T}^{\pi}$ is similar to the optimal Bellman operator $\mathcal{T}^*$ , although it uses $\min_{a\in \mathcal{A}_{\mathrm{adv}}}$ instead of $\max_{a\in \mathcal{A}}$ . Therefore, once we identify $\mathcal{A}_{\mathrm{adv}}$ as introduced above, it is straightforward to compute the worst-attack action value using Bellman backups. To model the worst-attack action value, we train a network named worst-attack critic, denoted by $\underline{Q}_{\phi}^{\pi}$ , where $\phi$ is the parameterization. Concretely, for any mini-batch $\{s_t,a_t,r_t,s_{t + 1}\}_{t = 1}^N$ , $\underline{Q}_{\phi}^{\pi}$ is optimized by minimizing the following estimation loss:
+
+$$
+\mathcal {L} _ {\text {e s t}} \left(\underline {{Q}} _ {\phi} ^ {\pi}\right) := \frac {1}{N} \sum_ {t = 1} ^ {N} \left(\underline {{y}} _ {t} - \underline {{Q}} _ {\phi} ^ {\pi} \left(s _ {t}, a _ {t}\right)\right) ^ {2}, \text {w h e r e} \underline {{y}} _ {t} = r _ {t} + \gamma \min _ {\hat {a} \in \mathcal {A} _ {\text {a d v}} \left(s _ {t + 1}, \pi\right)} \underline {{Q}} _ {\phi} ^ {\pi} \left(s _ {t + 1}, \hat {a}\right). \tag {3}
+$$
+
+For a discrete action space, $\mathcal{A}_{\mathrm{adv}}$ is a discrete set and solving $\underline{y}_t$ is straightforward. For a continuous action space, we use gradient descent to approximately find the minimizer $\hat{a}$ . Since $\mathcal{A}_{\mathrm{adv}}$ is in general small, this minimization is usually easy to solve. In MuJoCo, we find that 50-step gradient descent already converges to a good solution with little computational cost, as detailed in Appendix D.3.3.
+
+Differences with Worst-case Value Estimation in Related Work. Our proposed worst-attack Bellman operator is different from the worst-case Bellman operator in the literature of risk-sensitive RL [18, 11, 43, 10, 2, 46], whose goal is to avoid unsafe trajectories under the intrinsic uncertainties of the MDP. These inherent uncertainties of the environment are independent of the learned policy. In contrast, our focus is to defend against adversarial perturbations created by malicious attackers that can be adaptive to the policy. The GwC reward proposed by [33] also estimates the worst-case reward of a policy under state perturbations. But their evaluation is based on a greedy strategy and requires interactions with the environment, which is different from our estimation.
+
+# Mechanism 2: Worst-case-aware Policy Optimization
+
+So far we have introduced how to evaluate the worst-attack value of a policy by learning a worst-attack critic. Inspired by the actor-critic framework, where the actor policy network $\pi_{\theta}$ is optimized towards a direction that the critic value increases the most, we can regard worst-attack critic as a special critic that directs the actor to increase the worst-attack value. That is, we encourage the agent to select an action with a higher worst-attack action value, by minimizing the worst-attack policy loss below:
+
+$$
+\mathcal {L} _ {\mathrm {w s t}} \left(\pi_ {\theta}; \underline {{Q}} _ {\phi} ^ {\pi}\right) := - \frac {1}{N} \sum_ {t = 1} ^ {N} \sum_ {a \in \mathcal {A}} \pi_ {\theta} (a | s _ {t}) \underline {{Q}} _ {\phi} ^ {\pi} \left(s _ {t}, a\right), \tag {4}
+$$
+
+where $\underline{Q}_{\phi}^{\pi}$ is the worst-attack critic learned via $\mathcal{L}_{\mathrm{est}}$ introduced in Equation (3). Note that $\mathcal{L}_{\mathrm{wst}}$ is a general form, while the detailed implementation of the worst-attack policy optimization can vary depending on the architecture of $\pi_{\theta}$ in the base RL algorithm (e.g. PPO has a policy network, while DQN acts using the greedy policy induced by a Q network). In Appendix C.2 and Appendix C.3, we illustrate how to implement $\mathcal{L}_{\mathrm{wst}}$ for PPO and DQN as two examples.
+
+The proposed worst-case-aware policy optimization has several merits compared to prior ATLA [52] and PA-ATLA [42] methods which alternately train the agent and an RL attacker. (1) Learning the optimal attacker $h^*$ requires collecting extra samples using the current policy (on-policy estimation). In contrast, $Q_{\phi}^{\pi}$ can be learned using off-policy samples, e.g., historical samples in the replay buffer, and thus is more suitable for training where the policy changes over time. $(Q_{\phi}^{\pi})$ depends on the current
+
+policy via the computation of $\mathcal{A}_{\mathrm{adv}.}$ ) (2) We properly exploit the policy function that is being trained by computing the set of possibly selected actions $\hat{\mathcal{A}}_{\mathrm{adv}}$ for any state. In contrast, ATLA [52] learns an attacker by treating the current policy as a black box, ignoring the intrinsic properties of the policy. PA-ATLA [42], although assumes white-box access to the victim policy, also needs to explore and learn from extra on-policy interactions. (3) The attacker trained with DRL methods, namely $\hat{h}^*$ , is not guaranteed to converge to an optimal solution, such that the performance of $\pi$ estimated under $\hat{h}^*$ can be overly optimistic. Our estimation, as mentioned in Mechanism 1, computes a lower bound of $Q^{\pi}$ and thus can better indicate the robustness of a policy.
+
+# Mechanism 3: Value-enhanced State Regularization
+
+As discussed in Section 1, the vulnerability of a deep policy comes from both the policy's intrinsic vulnerability with the RL dynamics and the DNN approximator. The first two mechanisms of WocaRL mainly focus on the policy's intrinsic vulnerability, i.e., let the policy select actions that are less vulnerable to possible attacks in all future steps. However, if a bounded state perturbation can cause the network to output a very different action, then the $\mathcal{A}_{\mathrm{adv}}$ set will be large and $Q^{\pi}$ can thus be low. Therefore, it is also important to encourage the trained policy to output similar actions for the clean state $s$ and any $\tilde{s} \in \mathcal{B}_{\epsilon}(s)$ , as is done in prior work [54, 40, 9].
+
+But different from these prior methods, we note that different states should be treated differently. Some states are "critical" where selecting a bad action will result in catastrophic consequences. For example, when the agent gets close to the bomb in Figure 1, we should make the network more resistant to adversarial state perturbations. To differentiate states based on their impacts on future reward, we propose to measure the importance of states with Definition 4.3 below.
+
+Definition 4.3 (State Importance Weight). Define state importance weight of $s \in S$ for policy $\pi$ as
+
+$$
+w (s) = \max _ {a _ {1} \in \mathcal {A}} Q ^ {\pi} (s, a _ {1}) - \min _ {a _ {2} \in \mathcal {A}} Q ^ {\pi} (s, a _ {2}). \tag {5}
+$$
+
+To justify whether Definition 4.3 can characterize state importance, we train a DQN network in an Atari game Pong, and show the states with the highest weight and the lowest weight in Figure 3, among many state samples. We can see that the state with higher weight in Figure 3(left) is indeed crucial for the game, as the green agent paddle is close to the ball. Conversely, a less-important state in Figure 3(right) does not have significantly different future rewards under different actions. Computing $w(s)$ is easy in a discrete action space, while in a continuous action space, one can use gradient descent to approximately find the maximal and the minimal Q values for a state. Similar to the
+
+
+Figure 3: States in Pong with (left) high weight $w(s)$ and (right) low weight $w(s)$ .
+
+computation of Equation (3) with a continuous action space, we find that a 50-step gradient descent works well in experiments.
+
+By incorporating the state importance weight $w(s)$ , we regularize the policy network and let it pay more attention to more crucial states, by minimizing the following loss:
+
+$$
+\mathcal {L} _ {\text {r e g}} \left(\pi_ {\theta}\right) = \frac {1}{N} \sum_ {t = 1} ^ {N} w \left(s _ {t}\right) \max _ {\tilde {s} _ {t} \in \mathcal {B} _ {\epsilon} \left(s _ {t}\right)} \operatorname {D i s t} \left(\pi_ {\theta} \left(s _ {t}\right), \pi_ {\theta} \left(\tilde {s} _ {t}\right)\right), \tag {6}
+$$
+
+where $\text{Dist}$ can be any distance measure between two distributions (e.g., KL-divergence). Minimizing $\mathcal{L}_{\text{reg}}$ can result in a smaller $\mathcal{A}_{\text{adv}}$ , and thus the worst-attack value will be closer to the natural value.
+
+# WocaR-RL: A Generic Robust Training Framework
+
+So far we have introduced three key mechanisms and their loss functions, $\mathcal{L}_{\mathrm{est}}$ in Equation (3), $\mathcal{L}_{\mathrm{wst}}$ in Equation (4) and $\mathcal{L}_{\mathrm{reg}}$ in Equation (6). Then, our robust training framework WocaR-RL combines these losses with any base RL algorithm. To be more specific, as shown in Figure 4, for any base RL algorithm that trains policy $\pi_{\theta}$ using loss $\mathcal{L}_{\mathrm{RL}}$ , we learn an extra worst-attack critic network $\underline{Q}_{\phi}^{\pi}$ by minimizing
+
+
+Figure 4: Training architecture of WocaR-RL. (Components proposed in this paper are colored as red.)
+
+$$
+\mathcal {L} _ {\underline {{Q}} _ {\phi} ^ {\pi}} := \mathcal {L} _ {\text {e s t}} \left(\underline {{Q}} _ {\phi} ^ {\pi}\right), \tag {7}
+$$
+
+and combine $\mathcal{L}_{\mathrm{wst}}$ and $\mathcal{L}_{\mathrm{reg}}$ with $\mathcal{L}_{\mathrm{RL}}$ to optimize $\pi_{\theta}$ by minimizing
+
+$$
+\mathcal {L} _ {\pi_ {\theta}} := \mathcal {L} _ {\mathrm {R L}} (\pi_ {\theta}) + \kappa_ {\mathrm {w s t}} \mathcal {L} _ {\mathrm {w s t}} \left(\pi_ {\theta}; Q _ {\phi} ^ {\pi}\right) + \kappa_ {\mathrm {r e g}} \mathcal {L} _ {\mathrm {r e g}} \left(\pi_ {\theta}\right), \tag {8}
+$$
+
+where $\kappa_{\mathrm{wst}}$ and $\kappa_{\mathrm{reg}}$ are hyperparameters balancing between natural performance and robustness. Note that $Q_{\phi}^{\pi}$ is trained together but independently with $\pi_{\theta}$ using historical transition samples, so WocaR-RL does not require extra samples from the environment. WocaR-RL can also be interpreted from a geometric perspective based on prior RL polytope theory [8, 42] as detailed in Appendix B.
+
+Our WocaR-RL is a generic robust training framework that can be used to robustify existing DRL algorithms. We provide two case studies: (1) combining WocaR-RL with a policy-based algorithm PPO [39], namely WocaR-PPO, and (2) combining WocaR-RL with a value-based algorithm DQN [32], namely WocaR-DQN. The pseudocodes of WocaR-PPO and WocaR-DQN are illustrated in Appendix C.2 and Appendix C.3. The application of WocaR-RL to other DRL methods is then straightforward, since most DRL methods are either policy-based or value-based. Next, we show by experiments that WocaR-PPO and WocaR-DQN achieve state-of-the-art robustness with superior efficiency, in various continuous control tasks and video game environments. We also empirically verify the effectiveness of each of the 3 mechanisms of WocaR-RL and their weights by ablation study in Section 5.2.
+
+# 5 Experiments and Discussion
+
+In this section, our experimental evaluations on various MuJoCo and Atari environments aim to study the following questions: (1) Can WocaR-RL learn policies with better robustness under existing strong adversarial attacks? (2) Can WocaR-RL maintain natural performance when improving robustness? (3) Can WocaR-RL learn more efficiently during robust training? (4) Is each mechanism in WocaR-RL effective? Problem (1), (2) and (3) are answered in Section 5.1 with detailed empirical results, and problem (4) is studied in Section 5.2 via ablation experiments.
+
+# 5.1 Experiments and Evaluations
+
+**Environments.** Following most prior works [54, 52, 33] and the released implementation, we apply our WocaR-RL to PPO [39] on 4 MuJoCo tasks with continuous action spaces, including Hopper, Walker2d, Halfcheetah and Ant, and to DQN [32] agents on 4 Atari games including Pong, Freeway, BankHeist and RoadRunner, which have high dimensional pixel inputs and discrete action spaces.
+
+Baselines and Implementation. We compare our algorithm with several state-of-the-art robust training methods, including (1) SA-PPO/SA-DQN [54]: regularizing policy networks by convex relaxation. (2) ATLA-PPO [52]: alternately training an agent and an RL attacker. (3) PA-ATLAPPO [42]: alternately training an agent and a more advanced RL attacker PA-AD. (4) RADIALPPO/RADIAL-DQN [33]: optimizing policy network by designed adversarial loss functions based on robustness bounds. SA and RADIAL have both PPO and DQN versions, which are compared with our WocaR-PPO and WocaR-DQN. But ATLA and PA-ATLA do not provide DQN versions, since alternately training on DQN can be expensive as explained in the original papers [42]. (PA-ATLA has an A2C version, which we compare in Appendix D.2.) Therefore, we reproduce their ATLA-PPO and PA-ATLA-PPO results and compare them with our WocaR-PPO. More implementation and hyperparameter details are provided in Appendix D.1.
+
+# Case I: Robust PPO for MuJoCo Continuous Control
+
+Evaluation Metrics. To reflect both the natural performance and robustness of trained agents, we report the average episodic rewards under no attack and against various attacks. For a comprehensive robustness evaluation, we attack the trained robust models with multiple existing attack methods, including: (1) MaxDiff [54] (maximal action difference), (2) Robust Sarsa (RS) [54] (attacking with a robust action-value function), (3) SA-RL [54] (finding the optimal state adversary) and (4) PA-AD [42] (the existing strongest attack by learning the optimal policy adversary with RL). For a clear comparison, we use the same attack radius $\epsilon$ as in most baselines [54, 52, 42].
+
+Performance and Robustness of WocaR-PPO Figure 5 (left four columns) shows performance curves during training under four different adversarial attacks. Among all four attack algorithms, WocaR-PPO converges much faster than baselines, and often achieves the best asymptotic robust performance, especially under the strongest PA-AD attack. It is worth emphasizing that since we train a robust agent without explicitly learning an RL attacker, our method not only obtains
+
+
+Figure 5: Robustness, Efficiency and High Natural Performance of WocaR-PPO. (Left four columns) Learning curves of rewards under MaxDiff, Robust Sarsa, SA-RL and PA-AD (the strongest) attacks during training on four environments. (Rightmost column) Average episode natural rewards v.s. average worst rewards under attacks. Each row shows the performance of baselines and WocaR-PPO on one environment. Shaded regions are computed over 20 random seeds. Results under more attack radius $\epsilon$ 's are in Appendix D.3.1.
+
+stronger robustness and much higher efficiency, but also a more general defense: WocaR-PPO obtains comprehensively superior performance against a variety of attacks compared against existing SOTA algorithms based on learned attackers (ATLA-PPO, PA-ATLA-PPO). Additionally, in our experiments, WocaR-PPO learns relatively more universal defensive behaviors as shown in Figure 2, which can physically explain why our algorithm can defend against diverse attacks. We provide policy demonstrations in multiple tasks in our supplementary materials.
+
+The comparison of natural performance and the worst-case performance appears in Figure 5 (right). We see that WocaR-PPO maintains competitive natural rewards under no attack compared with other baselines, which demonstrates that our algorithm gains more robustness without losing too much natural performance. The full results of baselines and our algorithm under different attack evaluations are provided by Table 2 in Appendix D.2 (including performance under random attacks).
+
+Efficiency of Training WocaR-PPO. The learning curves in Figure 5 (left) directly show the sample efficiency of WocaR-PPO. Following the optimal settings provided in [54, 52, 33], our method takes $50\%$ training steps required by RADIAL-PPO and ATLA methods on Hopper, Walker2d, and Halfcheetah because RADIAL-PPO needs more steps to ensure convergence and ATLA methods require additional adversary training steps. When solving high dimensional environments like Ant, WocaR-PPO only requires $75\%$ steps compared with all other baselines to converge. We also provide additional results of baselines using the same training steps as WocaR-PPO in Appendix D.3.2. In terms of time efficiency, WocaR-PPO saves $50\%$ training time for convergence on Hopper, Walker2d, and Halfcheetah, and $32\%$ time on Ant compared with the SOTA method. Therefore, WocaR-PPO achieves both higher computational efficiency and higher sample efficiency than SOTA baselines. Detailed costs in time and sampling are in Appendix D.3.3.
+
+# Case II: Robust DQN for Atari Video Games
+
+Evaluation Metrics. Since Atari games have pixel state spaces and discrete action spaces, the applicable attacking algorithms also differ from those in MuJoCo tasks. We include the following common attacks: (1) 10-step untargeted PGD (projected gradient descent) attack, (2) MinBest [19], which minimizes the probability of choosing the "best" action, (3) PA-AD [42], as the state-of-the-art RL-based adversarial attack algorithm.
+
+| Model | Pong | BankHeist |
| Natural Reward | PGD | MinBest | PA-AD | Natural Reward | PGD | MinBest | PA-AD |
| ε=3/255 | ε=3/255 |
| DQN | 21.0 ± 0.0 | -21.0 ± 0.0 | -9.7 ± 4.0 | -19.0 ± 2.2 | 1308 ± 24 | 0 ± 0 | 119 ± 65 | 102 ± 92 |
| SA-DQN | 21.0 ± 0.0 | 21.0 ± 0.0 | 20.6 ± 3.5 | 18.7 ± 2.6 | 1245 ± 14 | 1176 ± 63 | 1024 ± 31 | 489 ± 106 |
| RADIAL-DQN | 21.0 ± 0.0 | 21.0 ± 0.0 | 19.5 ± 2.1 | 13.2 ± 1.8 | 1178 ± 4 | 1176 ± 63 | 928 ± 113 | 508 ± 85 |
| WocaR-DQN (Ours) | 21.0 ± 0.0 | 21.0 ± 0.0 | 20.8 ± 3.3 | 19.7 ± 2.4 | 1220 ± 12 | 1214 ± 7 | 1045 ± 20 | 754 ± 102 |
+
+| Model | Freeway | RoadRunner |
| Natural Reward | PGD | MinBest | PA-AD | Natural Reward | PGD | MinBest | PA-AD |
| ε=3/255 | ε=3/255 |
| DQN | 34.0 ± 0.1 | 0.0 ± 0.0 | 5.5 ± 1.8 | 4.7 ± 2.9 | 45527 ± 4894 | 0 ± 0 | 2985 ± 1440 | 203 ± 65 |
| SA-DQN | 30.0 ± 0.0 | 30.0 ± 0.0 | 18.3 ± 3.0 | 9.5 ± 3.8 | 44638 ± 2367 | 20678 ± 1563 | 4214 ± 2587 | 5516 ± 4684 |
| RADIAL-DQN | 33.1 ± 0.2 | 33.2 ± 0.2 | 16.4 ± 2.3 | 10.8 ± 3.6 | 44675 ± 5854 | 38576 ± 1960 | 8476 ± 3964 | 1290 ± 4015 |
| WocaR-DQN (Ours) | 31.2 ± 0.4 | 31.4 ± 0.3 | 19.8 ± 3.8 | 12.3 ± 3.2 | 44156 ± 2279 | 38720 ± 1765 | 10545 ± 2984 | 8239 ± 2766 |
+
+Table 1: Robustness and High Natural Performance of WocaR-DQN. Average episode rewards $\pm$ standard deviation over 50 episodes on three baselines and WocaR-DQN on four Atari environments. Best results (natural reward of under attacks for each column) on each environment boldfaced. WocaR-DQN outperforms all the baselines in most cases or gains similar performance in the other metrics. We highlight the most robust agent as gray. Each result is obtained with 10 random seeds.
+
+
+(a) Walker2d: Worst-case Values
+Figure 6: (a)&(b) Comparison between estimated worst-attack action values $\underline{Q}_{\phi}^{\pi}$ and Actual worst-case rewards under the strongest attacks during training on Walker2d; (c)&(d) The comparison between worst-case values and rewards to verify worst-attack value estimation on Ant.
+
+
+(b) Walker2d: Worst-case Rewards
+
+
+(c) Ant: Worst-case Values
+
+
+(d) Ant: Worst-case Rewards
+
+Performance and Robustness of WocaR-DQN. Table 1 presents the results on four Atari games under attack radius $\epsilon = 3/255$ , while results and analysis under smaller attack radius $1/255$ are in Appendix D.2. We can see that our WocaR-DQN consistently outperforms baselines under MinBest and PA-AD attacks in all environments, with a significant advance under the strongest (worst-case) PA-AD attacks compared with other robust agents. Under PGD attacks, WocaR-DQN performs comparably with the state-of-the-art in Freeway and Pong (which are simpler games) and gains higher rewards than other agents in BankHeist and Roadrunner. Since SA-DQN and RADIAL-DQN focus on bounding and smoothing the policy network and do not consider the policy's intrinsic vulnerability, they are robust under the PGD attack but still vulnerable against the stronger PA-AD attack.
+
+Efficiency of Training WocaR-DQN. The total training time for SA-DQN, RADIAL-DQN, and our WocaR-DQN are roughly 35, 17, and 18 hours, respectively. All baselines are trained for 6 million frames on the same hardware. Therefore, WocaR-DQN is $49\%$ faster (and is more robust) than SA-DQN. Compared to the more advanced baseline RADIAL-DQN, although WocaR-DQN is $5\%$ slower, it achieves better robustness ( $539\%$ higher reward than RADIAL-DQN in RoadRunner).
+
+# 5.2 Verifying Effectiveness of WocaR-RL
+
+Now we dive deeper into the algorithmic design and verify the effectiveness of WocaR-RL by ablation studies on WocaR-PPO.
+
+(1) Worst-attack value estimation. We show the learned worst-attack value estimation, $\underline{Q}_{\phi}^{\pi}$ , during the training process in Figure 6a and 6c, in comparison with the actual reward under the strongest attack (PA-AD [42]) in Figure 6b and 6d. The pink curves in both plots suggest that our worst-attack value estimation matches the trend of actual worst-case reward under attacks, although the network estimated value and the real reward have different scales due to the commonly-used reward normalization for learning stability. Therefore, the effectiveness of our proposed worst-attack value estimation $(\mathcal{L}_{\mathrm{est}})$ is verified.
+(2) Worst-case-aware policy optimization. Compared to vanilla PPO and SA-PPO, we can see that WocaR-PPO improves the worst-attack value and the worst-case reward during training, suggesting the effectiveness of our worst-attack value improvement $(\mathcal{L}_{\mathrm{wst}})$ . The comparison of natural rewards,
+
+
+(a) Halfcheetah: Ablation studies for $w(s)$
+
+
+(b) Hopper: Ablation studies for $\mathcal{L}_{\mathrm{reg}}$
+Figure 7: (a) Ablation evaluations for state importance weight $w(s)$ under no attack and four types of attacks on Halfcheetah; (b) Ablation studies for state regularization $\mathcal{L}_{\mathrm{reg}}$ under different evaluation metrics on Hopper. Ablated results on other environments are in Appendix D.3.6.
+
+as well as curves in other environments, are provided in Appendix D.3.4. Moreover, the adjustable weight $\kappa_{\mathrm{wst}}$ in Equation (8) controls the trade-off between natural value and worst-attack value in policy optimization. When $\kappa_{\mathrm{wst}}$ is high, the policy pays more attention to its worst-attack value. Appendix D.3.5 verifies that WocaR-RL, with different values of weight $\kappa_{\mathrm{wst}}$ , produces different robustness and natural performance while consistently dominating other robust agents.
+
+(3) Value-enhanced state regularization. We conduct ablation experiments to analyze the effect of two techniques: our proposed state importance weight $w(s)$ and the state regularization loss $\mathcal{L}_{\mathrm{reg}}$ [54]. In Figure 7a, we compare the performance of the original WocaR-PPO to a variant of WocaR-PPO without the state importance weight $w(s)$ on Halfcheetah, which visually indicates that $w(s)$ can help agents boost the robustness. Since SA-PPO [54] also uses a state regularization technique, the improvement of SA-PPO added with $w(s)$ also show the universal effectiveness of our state importance. Without $w(s)$ , our algorithm also achieves similar or better performance than baselines, but including this inexpensive technique $w(s)$ gives WocaR-RL a greater advantage, especially under learned strong attacks SA-RL and PA-AD. Figure 7b presents the performance of ATLA methods and our algorithm without $\mathcal{L}_{\mathrm{reg}}$ on Hopper, which verifies that WocaR-PPO also yields the superior performance when removing the regularization technique. And the comparison between WocaR-PPO and WocaR-PPO without $\mathcal{L}_{\mathrm{reg}}$ demonstrates that the weighted state regularization is beneficial to enhancing the robustness in our algorithm. Detailed ablation studies for $w(s)$ and $\mathcal{L}_{\mathrm{reg}}$ on four MuJoCo environments are shown in Appendix D.3.6.
+
+# 6 Conclusion and Discussion
+
+This paper proposes a robust RL training framework, WocaR-RL, that evaluates and improves the long-term robustness of a policy via worst-attack value estimation, worst-case-aware policy optimization, and value-enhanced state regularization. Different from recent state-of-the-art adversarial training methods [42, 52] which train an extra adversary to improve the robustness of an agent, we directly estimate and improve the lower bound of the agent's cumulative reward. As a result, WocaR-RL not only achieves better robustness than state-of-the-art robust RL approaches, but also halves the total sample complexity and computation complexity, in a wide range of Atari and MuJoCo tasks.
+
+There are several aspects to improve or extend the current approach. First, the proposed worst-attack Bellman operator in theory gives the exact worst-case value of a policy under $\ell_p$ bounded attacks. But in practice, it is hard to compute the set $\mathcal{A}_{\mathrm{adv}}$ directly, so we use convex relaxation to obtain a superset of it, $\hat{\mathcal{A}}_{\mathrm{adv}}$ . As a result, the fixed point of worst-attack Bellman operator with $\mathcal{A}_{\mathrm{adv}}$ being replaced by $\hat{\mathcal{A}}_{\mathrm{adv}}$ is a lower bound of the worst-case value. Then, our algorithm increases the worst-case value by improving its lower bound, as visualized and explained in Figure 8 in Appendix B. Therefore, one potential way of further improving the robustness is using a tighter relaxation. In addition, this paper only considers the $\ell_p$ threat model as is common in most related works. But in real-world applications, other attack models could exist (e.g. patch attacks [5]), and improving the robustness of RL agents in these scenarios is another important research direction.
+
+# Acknowledgments
+
+This work is supported by DOD-ONR-Office of Naval Research, DOD-DARPA-Defense Advanced Research Projects Agency Guaranteeing AI Robustness against Deception (GARD), and Adobe, Capital One and JP Morgan faculty fellowships.
+
+# References
+
+[1] Naveed Akhtar and Ajmal Mian. Threat of adversarial attacks on deep learning in computer vision: A survey. IEEE Access, 6:14410-14430, 2018.
+[2] Sarah Bechtle, Yixin Lin, Akshara Rai, Ludovic Righetti, and Franziska Meier. Curious ilqr: Resolving uncertainty in model-based rl. In Leslie Pack Kaelbling, Danica Kragic, and Komei Sugiura, editors, Proceedings of the Conference on Robot Learning, volume 100 of Proceedings of Machine Learning Research, pages 162-171. PMLR, 30 Oct-01 Nov 2020.
+[3] Vahid Behzadan and Arslan Munir. Vulnerability of deep reinforcement learning to policy induction attacks. In International Conference on Machine Learning and Data Mining in Pattern Recognition, pages 262-275. Springer, 2017.
+[4] Vahid Behzadan and Arslan Munir. Whatever does not kill deep reinforcement learning, makes it stronger. arXiv preprint arXiv:1712.09344, 2017.
+[5] Tom B Brown, Dandelion Mané, Aurko Roy, Martín Abadi, and Justin Gilmer. Adversarial patch. arXiv preprint arXiv:1712.09665, 2017.
+[6] Anirban Chakraborty, Manaar Alam, Vishal Dey, Anupam Chattopadhyay, and Debdeep Mukhopadhyay. Adversarial attacks and defences: A survey. arXiv preprint arXiv:1810.00069, 2018.
+[7] Jeremy Cohen, Elan Rosenfeld, and Zico Kolter. Certified adversarial robustness via randomized smoothing. In International Conference on Machine Learning, pages 1310-1320. PMLR, 2019.
+[8] Robert Dadashi, Adrien Ali Taiga, Nicolas Le Roux, Dale Schuurmans, and Marc G Bellemare. The value function polytope in reinforcement learning. In International Conference on Machine Learning, pages 1486-1495. PMLR, 2019.
+[9] Marc Fischer, Matthew Mirman, Steven Stalder, and Martin Vechev. Online robustness training for deep reinforcement learning. arXiv preprint arXiv:1911.00887, 2019.
+[10] Javier García and Fernando Fernández. A comprehensive survey on safe reinforcement learning. Journal of Machine Learning Research, 16(1):1437-1480, 2015.
+[11] Chris Gaskett. Reinforcement learning under circumstances beyond its control. In International Conference on Computational Intelligence for Modelling Control and Automation, 2003.
+[12] Saul B Gelfand and Sanjoy K Mitter. Recursive stochastic algorithms for global optimization in r^d. SIAM Journal on Control and Optimization, 29(5):999-1018, 1991.
+[13] Adam Gleave, Michael Dennis, Cody Wild, Neel Kant, Sergey Levine, and Stuart Russell. Adversarial policies: Attacking deep reinforcement learning. In International Conference on Learning Representations, 2020.
+[14] Sven Gowal, Krishnamurthy Dvijotham, Robert Stanforth, Rudy Bunel, Chongli Qin, Jonathan Uesato, Relja Arandjelovic, Timothy Mann, and Pushmeet Kohli. On the effectiveness of interval bound propagation for training verifiably robust models. arXiv preprint arXiv:1810.12715, 2018.
+[15] Sven Gowal, Krishnamurthy Dj Dvijotham, Robert Stanforth, Rudy Bunel, Chongli Qin, Jonathan Uesato, Relja Arandjelovic, Timothy Mann, and Pushmeet Kohli. Scalable verified training for provably robust image classification. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 4842-4851, 2019.
+[16] Arthur Guez and H Van Hasselt. Deep reinforcement learning with double q-learning. Association for the Advancement of Artificial Intelligence, 2015.
+[17] David Silver Hado Van Hasselt, Arthur Guez. Deep reinforcement learning with double q-learning. In Thirtieth AAAI Conference on Artificial Intelligence, 2016.
+[18] Matthias Heger. Consideration of risk in reinforcement learning. In International Conference on Machine Learning, 1994.
+
+[19] Sandy Huang, Nicolas Papernot, Ian Goodfellow, Yan Duan, and Pieter Abbeel. Adversarial attacks on neural network policies. arXiv preprint arXiv:1702.02284, 2017.
+[20] Yunhan Huang and Quanyan Zhu. Deceptive reinforcement learning under adversarial manipulations on cost signals. In International Conference on Decision and Game Theory for Security, pages 217-237. Springer, 2019.
+[21] Ezgi Korkmaz. Investigating vulnerabilities of deep neural policies. In Uncertainty in Artificial Intelligence, pages 1661-1670. PMLR, 2021.
+[22] Jernej Kos and Dawn Song. Delving into adversarial attacks on deep policies. arXiv preprint arXiv:1705.06452, 2017.
+[23] Aounon Kumar, Alexander Levine, and Soheil Feizi. Policy smoothing for provably robust reinforcement learning. arXiv preprint arXiv:2106.11420, 2021.
+[24] Xian Yeow Lee, Yasaman Esfandiari, Kai Liang Tan, and Soumik Sarkar. Query-based targeted action-space adversarial policies on deep reinforcement learning agents. In Proceedings of the ACM/IEEE 12th International Conference on Cyber-Physical Systems, ICCPS '21, page 87–97, New York, NY, USA, 2021. Association for Computing Machinery.
+[25] Timothy P Lillicrap, Jonathan J Hunt, Alexander Pritzel, Nicolas Heess, Tom Erez, Yuval Tassa, David Silver, and Daan Wierstra. Continuous control with deep reinforcement learning. arXiv preprint arXiv:1509.02971, 2015.
+[26] Shiau Hong Lim, Huan Xu, and Shie Mannor. Reinforcement learning in robust markov decision processes. Advances in Neural Information Processing Systems, 26:701-709, 2013.
+[27] Björn Lütjens, Michael Everett, and Jonathan P How. Certified adversarial robustness for deep reinforcement learning. In Conference on Robot Learning, pages 1328-1337. PMLR, 2020.
+[28] Aleksander Madry, Aleksandar Makelov, Ludwig Schmidt, Dimitris Tsipras, and Adrian Vladu. Towards deep learning models resistant to adversarial attacks. In International Conference on Learning Representations, 2018.
+[29] Ajay Mandlekar, Yuke Zhu, Animesh Garg, Li Fei-Fei, and Silvio Savarese. Adversarily robust policy learning: Active construction of physically-plausible perturbations. In 2017 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), pages 3932–3939. IEEE, 2017.
+[30] Daniel J. Mankowitz, Nir Levine, Rae Jeong, Abbas Abdelmaleki, Jost Tobias Springenberg, Yuanyuan Shi, Jackie Kay, Todd Hester, Timothy Mann, and Martin Riedmiller. Robust reinforcement learning for continuous control with model misspecification. In International Conference on Learning Representations, 2020.
+[31] Matthew Mirman, Timon Gehr, and Martin Vechev. Differentiable abstract interpretation for provably robust neural networks. In Jennifer Dy and Andreas Krause, editors, Proceedings of the 35th International Conference on Machine Learning, volume 80 of Proceedings of Machine Learning Research, pages 3578-3586. PMLR, 10-15 Jul 2018.
+[32] Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Alex Graves, Ioannis Antonoglou, Daan Wierstra, and Martin Riedmiller. Playing atari with deep reinforcement learning. arXiv preprint arXiv:1312.5602, 2013.
+[33] Tuomas Oikarinen, Wang Zhang, Alexandre Megretski, Luca Daniel, and Tsui-Wei Weng. Robust deep reinforcement learning through adversarial loss. In A. Beygelzimer, Y. Dauphin, P. Liang, and J. Wortman Vaughan, editors, Advances in Neural Information Processing Systems, 2021.
+[34] Anay Pattanaik, Zhenyi Tang, Shuijing Liu, Gautham Bommannan, and Girish Chowdhary. Robust deep reinforcement learning with adversarial attacks. arXiv preprint arXiv:1712.03632, 2017.
+
+[35] Lerrel Pinto, James Davidson, Rahul Sukthankar, and Abhinav Gupta. Robust adversarial reinforcement learning. In International Conference on Machine Learning, pages 2817-2826. PMLR, 2017.
+[36] Amin Rakhsha, Goran Radanovic, Rati Devidze, Xiaojin Zhu, and Adish Singla. Policy teaching via environment poisoning: Training-time adversarial attacks against reinforcement learning. In International Conference on Machine Learning, pages 7974-7984, 2020.
+[37] Tom Schaul, John Quan, Ioannis Antonoglou, and David Silver. Prioritized experience replay. arXiv preprint arXiv:1511.05952, 2015.
+[38] John Schulman, Sergey Levine, Pieter Abbeel, Michael Jordan, and Philipp Moritz. Trust region policy optimization. In International conference on machine learning, pages 1889-1897, 2015.
+[39] John Schulman, Filip Wolski, Prafulla Dhariwal, Alec Radford, and Oleg Klimov. Proximal policy optimization algorithms. arXiv preprint arXiv:1707.06347, 2017.
+[40] Qianli Shen, Yan Li, Haoming Jiang, Zhaoran Wang, and Tuo Zhao. Deep reinforcement learning with robust and smooth policy. In International Conference on Machine Learning, pages 8707-8718. PMLR, 2020.
+[41] Yanchao Sun, Da Huo, and Furong Huang. Vulnerability-aware poisoning mechanism for online with unknown dynamics. In International Conference on Learning Representations, 2021.
+[42] Yanchao Sun, Ruijie Zheng, Yongyuan Liang, and Furong Huang. Who is the strongest enemy? towards optimal and efficient evasion attacks in deep rl. arXiv preprint arXiv:2106.05087, 2021.
+[43] Aviv Tamar, Huan Xu, and Shie Mannor. Scaling up robust mdps by reinforcement learning. arXiv preprint arXiv:1306.6189, 2013.
+[44] Kai Liang Tan, Yasaman Esfandiari, Xian Yeow Lee, Soumik Sarkar, et al. Robustifying reinforcement learning agents via action space adversarial training. In 2020 American control conference (ACC), pages 3959-3964. IEEE, 2020.
+[45] Chen Tessler, Yonathan Efroni, and Shie Mannor. Action robust reinforcement learning and applications in continuous control. In International Conference on Machine Learning, pages 6215-6224. PMLR, 2019.
+[46] Garrett Thomas, Yuping Luo, and Tengyu Ma. Safe reinforcement learning by imagining the near future. In A. Beygelzimer, Y. Dauphin, P. Liang, and J. Wortman Vaughan, editors, Advances in Neural Information Processing Systems, 2021.
+[47] Ziyu Wang, Tom Schaul, Matteo Hessel, Hado Hasselt, Marc Lanctot, and Nando Freitas. *Dueling network architectures for deep reinforcement learning*. In *International conference on machine learning*, pages 1995–2003. PMLR, 2016.
+[48] Eric Wong and Zico Kolter. Provable defenses against adversarial examples via the convex outer adversarial polytope. In International Conference on Machine Learning, pages 5286-5295. PMLR, 2018.
+[49] Fan Wu, Linyi Li, Zijian Huang, Yevgeniy Vorobeychik, Ding Zhao, and Bo Li. Crop: Certifying robust policies for reinforcement learning through functional smoothing. arXiv preprint arXiv:2106.09292, 2021.
+[50] Chaowei Xiao, Xinlei Pan, Warren He, Jian Peng, Mingjie Sun, Jinfeng Yi, Mingyan Liu, Bo Li, and Dawn Song. Characterizing attacks on deep reinforcement learning. arXiv preprint arXiv:1907.09470, 2019.
+[51] Kaidi Xu, Zhouxing Shi, Huan Zhang, Yihan Wang, Kai-Wei Chang, Minlie Huang, Bhavya Kailkhura, Xue Lin, and Cho-Jui Hsieh. Automatic perturbation analysis for scalable certified robustness and beyond. In Advances in Neural Information Processing Systems, volume 33, pages 1129–1141, 2020.
+
+[52] Huan Zhang, Hongge Chen, Duane S Boning, and Cho-Jui Hsieh. Robust reinforcement learning on state observations with learned optimal adversary. In International Conference on Learning Representations, 2021.
+[53] Huan Zhang, Hongge Chen, Chaowei Xiao, Sven Gowal, Robert Stanforth, Bo Li, Duane Boning, and Cho-Jui Hsieh. Towards stable and efficient training of verifiably robust neural networks. In International Conference on Learning Representations, 2020.
+[54] Huan Zhang, Hongge Chen, Chaowei Xiao, Bo Li, Mingyan Liu, Duane Boning, and Chojui Hsieh. Robust deep reinforcement learning against adversarial perturbations on state observations. In H. Larochelle, M. Ranzato, R. Hadsell, M. F. Balcan, and H. Lin, editors, Advances in Neural Information Processing Systems, volume 33, pages 21024-21037. Curran Associates, Inc., 2020.
+[55] Huan Zhang, Tsui-Wei Weng, Pin-Yu Chen, Cho-Jui Hsieh, and Luca Daniel. Efficient neural network robustness certification with general activation functions. In Proceedings of the 32nd International Conference on Neural Information Processing Systems, NIPS'18, page 4944-4953, Red Hook, NY, USA, 2018. Curran Associates Inc.
+[56] Xuezhou Zhang, Yuzhe Ma, Adish Singla, and Xiaojin Zhu. Adaptive reward-poisoning attacks against reinforcement learning. In International Conference on Machine Learning, 2020.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes] See our abstract and Section 1.
+(b) Did you describe the limitations of your work? [Yes] We discuss the limitations in Appendix E.
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] We discuss the potential negative societal impacts in Appendix E.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] Our paper conforms to the guidelines.
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes] See Appendix A.
+(b) Did you include complete proofs of all theoretical results? [Yes] See Appendix A.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Appendix D.1
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] For each empirical result, we report error bars.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See efficiency analysis in Appendix D.3.3.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [Yes]
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [Yes]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/images.zip b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..e68f7d2a2c0d705fb0643e9af11488240df1be68
--- /dev/null
+++ b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:114f61c9effa9c65d61d209090253748671c8a60c3321aab87d44109e840281a
+size 398093
diff --git a/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/layout.json b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..b81583ba22384411769757583754f1cb1f7f2ff9
--- /dev/null
+++ b/efficientadversarialtrainingwithoutattackingworstcaseawarerobustreinforcementlearning/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:02b79f93b0173a5c71f4a872414b8348c2aaa3f9b8a23d79449b4b0f3ac71301
+size 511205
diff --git a/efficientaggregatedkerneltestsusingincompleteustatistics/d87c198c-f06a-4b00-83ad-09ba12a35c87_content_list.json b/efficientaggregatedkerneltestsusingincompleteustatistics/d87c198c-f06a-4b00-83ad-09ba12a35c87_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..c111c704c0ebc495c0af3662126878482209906e
--- /dev/null
+++ b/efficientaggregatedkerneltestsusingincompleteustatistics/d87c198c-f06a-4b00-83ad-09ba12a35c87_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:00af5c702ddda80c3ffe1b9e9e7640447026d1245533eccc0fa1b67c03e89800
+size 99745
diff --git a/efficientaggregatedkerneltestsusingincompleteustatistics/d87c198c-f06a-4b00-83ad-09ba12a35c87_model.json b/efficientaggregatedkerneltestsusingincompleteustatistics/d87c198c-f06a-4b00-83ad-09ba12a35c87_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..f2c49d2a3352454e6df64e87654332ad65d4ae64
--- /dev/null
+++ b/efficientaggregatedkerneltestsusingincompleteustatistics/d87c198c-f06a-4b00-83ad-09ba12a35c87_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3324c386cd5e67caed81817d2eef67601d87b0015ec45dddec799a26dd00bf0a
+size 125234
diff --git a/efficientaggregatedkerneltestsusingincompleteustatistics/d87c198c-f06a-4b00-83ad-09ba12a35c87_origin.pdf b/efficientaggregatedkerneltestsusingincompleteustatistics/d87c198c-f06a-4b00-83ad-09ba12a35c87_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..2b40a3abb2eb0ee35d52cf4192d7f53bd4b8a854
--- /dev/null
+++ b/efficientaggregatedkerneltestsusingincompleteustatistics/d87c198c-f06a-4b00-83ad-09ba12a35c87_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:df63b1076e5213c7b02173d5621215579eb985ac0b0aa738ea1eb534e045d09b
+size 977004
diff --git a/efficientaggregatedkerneltestsusingincompleteustatistics/full.md b/efficientaggregatedkerneltestsusingincompleteustatistics/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..49bbdd315f8c1555a69a56f4a4d15ae45af0d79a
--- /dev/null
+++ b/efficientaggregatedkerneltestsusingincompleteustatistics/full.md
@@ -0,0 +1,439 @@
+# Efficient Aggregated Kernel Tests using Incomplete $U$ -statistics
+
+# Antonin Schrab
+
+Centre for Artificial Intelligence Gatsby Computational Neuroscience Unit University College London & Inria London a.schrab@ucl.ac.uk
+
+# Benjamin Guedj
+
+Centre for Artificial Intelligence
+University College London & Inria London
+b.guedj@ucl.ac.uk
+
+# Ilmun Kim
+
+Department of Statistics & Data Science
+Department of Applied Statistics
+Yonsei University
+ilmun@yonsei.ac.kr
+
+# Arthur Gretton
+
+Gatsby Computational Neuroscience Unit
+University College London
+arthur.gretton@gmail.com
+
+# Abstract
+
+We propose a series of computationally efficient nonparametric tests for the two-sample, independence, and goodness-of-fit problems, using the Maximum Mean Discrepancy (MMD), Hilbert Schmidt Independence Criterion (HSIC), and Kernel Stein Discrepancy (KSD), respectively. Our test statistics are incomplete $U$ -statistics, with a computational cost that interpolates between linear time in the number of samples, and quadratic time, as associated with classical $U$ -statistic tests. The three proposed tests aggregate over several kernel bandwidths to detect departures from the null on various scales: we call the resulting tests MMDAggInc, HSICAggInc and KSDAggInc. This procedure provides a solution to the fundamental kernel selection problem as we can aggregate a large number of kernels with several bandwidths without incurring a significant loss of test power. For the test thresholds, we derive a quantile bound for wild bootstrapped incomplete $U$ -statistics, which is of independent interest. We derive non-asymptotic uniform separation rates for MMDAggInc and HSICAggInc, and quantify exactly the trade-off between computational efficiency and the attainable rates: this result is novel for tests based on incomplete $U$ -statistics, to our knowledge. We further show that in the quadratic-time case, the wild bootstrap incurs no penalty to test power over the more widespread permutation-based approach, since both attain the same minimax optimal rates (which in turn match the rates that use oracle quantiles). We support our claims with numerical experiments on the trade-off between computational efficiency and test power. In all three testing frameworks, the linear-time versions of our proposed tests perform at least as well as the current linear-time state-of-the-art tests.
+
+# 1 Introduction
+
+Nonparametric hypothesis testing is a fundamental field of statistics, and is widely used by the machine learning community and practitioners in numerous other fields, due to the increasing availability of huge amounts of data. When dealing with large-scale datasets, computational cost can quickly emerge as a major issue which might prevent from using expensive tests in practice; constructing efficient tests is therefore crucial for their real-world applications. In this paper, we construct kernel-based aggregated tests using incomplete $U$ -statistics (Blom, 1976) for the two-sample, independence and
+
+goodness-of-fit problems (which we detail in Section 2). The quadratic-time aggregation procedure has been shown to result in powerful tests (Fromont et al., 2012; Fromont et al., 2013; Albert et al., 2022; Schrab et al., 2021, 2022), we propose efficient variants of these well-studied tests, with computational cost interpolating from the classical quadratic-time regime to the linear-time one.
+
+Related work: aggregated tests. Kernel selection (or kernel bandwidth selection) is a fundamental problem in nonparametric hypothesis testing as this choice has a major influence on test power. Motivated by this problem, non-asymptotic aggregated tests, which combine tests with different kernel bandwidths, have been proposed for the two-sample (Fromont et al., 2012, 2013; Kim et al., 2022; Schrab et al., 2021), independence (Albert et al., 2022; Kim et al., 2022), and goodness-of-fit (Schrab et al., 2022) testing frameworks. Li and Yuan (2019) and Balasubramanian et al. (2021) construct similar aggregated tests for these three problems, with the difference that they work in the asymptotic regime. All the mentioned works study aggregated tests in terms of uniform separation rates (Baraud, 2002). Those rates depend on the sample size and satisfy the following property: if the $L^2$ -norm difference between the densities is greater than the uniform separation rate, then the test is guaranteed to have high power. All aggregated kernel-based tests in the existing literature have been studied using $U$ -statistic estimators (Hoeffding, 1992) with tests running in quadratic time.
+
+Related work: efficient kernel tests. Several linear-time kernel tests have been proposed for those three testing frameworks. Those include tests using classical linear-time estimators with median bandwidth (Gretton et al., 2012a; Liu et al., 2016) or selecting an optimal bandwidth on held-out data to maximize power (Gretton et al., 2012b), tests using eigenspectrum approximation (Gretton et al., 2009), tests using post-selection inference for adaptive kernel selection with incomplete $U$ -statistics (Yamada et al., 2018, 2019; Lim et al., 2019, 2020; Kübler et al., 2020; Freidling et al., 2021), tests which use a Nyström approximation of the asymptotic null distribution (Zhang et al., 2018; Cherfaoui et al., 2022), random Fourier features tests (Zhang et al., 2018; Zhao and Meng, 2015; Chwialkowski et al., 2015), tests based on random feature Stein discrepancies (Huggins and Mackey, 2018), the adaptive tests which use features selected on held-out data to maximize power (Jitkrittum et al., 2016, 2017a,b), as well as tests using neural networks to learn a discrepancy (Grathwohl et al., 2020). We also point out the very relevant works of Kübler et al. (2022) on a quadratic-time test, and of Ho and Shieh (2006), Zaremba et al. (2013) and Zhang et al. (2018) on the use of block $U$ -statistics with complexity $\mathcal{O}(N^{1.5})$ for block size $\sqrt{N}$ where $N$ is the sample size.
+
+Contributions and outline. In Section 2, we present the three testing problems with their associated well-known quadratic-time kernel-based estimators (MMD, HSIC, KSD) which are $U$ -statistics. We introduce three associated incomplete $U$ -statistics estimators, which can be computed efficiently, in Section 3. We then provide quantile and variance bounds for generic incomplete $U$ -statistics using a wild bootstrap, in Section 4. We study the level and power guarantees at every finite sample sizes for our efficient tests using incomplete $U$ -statistics for a fixed kernel bandwidth, in Section 5. In particular, we obtain non-asymptotic uniform separation rates for the two-sample and independence tests over a Sobolev ball, and show that these rates are minimax optimal up to the cost incurred for efficiency of the test. In Section 6, we propose our efficient aggregated tests which combine tests with multiple kernel bandwidths. We prove that the proposed tests are adaptive over Sobolev balls and achieve the same uniform separation rate (up to an iterated logarithmic term) as the tests with optimal bandwidths. As a result of our analysis, we have shown minimax optimality over Sobolev balls of the quadratic-time tests using quantiles estimated with a wild bootstrap. Whether this optimality result also holds for tests using the more general permutation-based procedure to approximate HSIC quantiles, was an open problem formulated by Kim et al. (2022), we prove that it indeed holds in Section 7. As observed in Section 8, the linear-time versions of MMDAggInc, HSICAggInc and KSDAggInc retain high power, and either outperform or match the power of other state-of-the-art linear-time kernel tests. Our implementation of the tests and code for reproducibility of the experiments are available online under the MIT license: https://github.com/antoninschrab/agginc-paper
+
+# 2 Background
+
+In this section, we briefly describe our main problems of interest, comprising the two-sample, independence and goodness-of-fit problems. We approach these problems from a nonparametric point of view using the kernel-based statistics: MMD, HSIC, and KSD. We briefly introduce original forms of these statistics, which can be computed in quadratic time, and also discuss ways of calibrating tests proposed in the literature. The three quadratic-time expressions are presented in Appendix B
+
+Two-sample testing. In this problem, we are given independent samples $\mathbb{X}_m\coloneqq (X_i)_{1\leq i\leq m}$ and $\mathbb{Y}_n = (Y_j)_{1\leq j\leq n}$ , consisting of i.i.d. random variables with respective probability density functions $p$ and $q$ on $\mathbb{R}^d$ . We assume we work with balanced sample sizes, that is $\max (m,n)\lesssim \min (m,n)$ . We are interested in testing the null hypothesis $\mathcal{H}_0:p = q$ against the alternative $\mathcal{H}_1:p\neq q$ ; that is, we want to know if the samples come from the same distribution. Gretton et al. (2012a) propose a nonparametric kernel test based on the Maximum Mean Discrepancy (MMD), a measure between probability distributions which uses a characteristic kernel $k$ (Fukumizu et al., 2008; Sriperumbudur et al., 2011). It can be estimated using a quadratic-time estimator (Gretton et al., 2012a Lemma 6) which, as noted by Kim et al. (2022), can be expressed as a two-sample $U$ -statistic (both of second order) (Hoeffding, 1992),
+
+$$
+\widehat {\mathrm {M M D}} _ {k} ^ {2} \left(\mathbb {X} _ {m}, \mathbb {Y} _ {n}\right) = \frac {1}{\left| \mathbf {i} _ {2} ^ {m} \right| \left| \mathbf {i} _ {2} ^ {n} \right|} \sum_ {(i, i ^ {\prime}) \in \mathbf {i} _ {2} ^ {m}} \sum_ {(j, j ^ {\prime}) \in \mathbf {i} _ {2} ^ {n}} h _ {k} ^ {\mathrm {M M D}} \left(X _ {i}, X _ {i ^ {\prime}}; Y _ {j}, Y _ {j ^ {\prime}}\right), \tag {1}
+$$
+
+where $\mathbf{i}_a^b$ with $a\leq b$ denotes the set of all $a$ -tuples drawn without replacement from $\{1,\ldots ,b\}$ so that $\left|\mathbf{i}_a^b\right| = b\dots (b - a + 1)$ , and where, for $x_{1},x_{2},y_{1},y_{2}\in \mathbb{R}^{d}$ , we let
+
+$$
+h _ {k} ^ {\mathrm {M M D}} \left(x _ {1}, x _ {2}; y _ {1}, y _ {2}\right) := k \left(x _ {1}, x _ {2}\right) - k \left(x _ {1}, y _ {2}\right) - k \left(x _ {2}, y _ {1}\right) + k \left(y _ {1}, y _ {2}\right). \tag {2}
+$$
+
+Independence testing. In this problem, we have access to i.i.d. pairs of samples $\mathbb{Z}_N \coloneqq (Z_i)_{1 \leq i \leq N} = ((X_i, Y_i))_{1 \leq i \leq N}$ with joint probability density $p_{xy}$ on $\mathbb{R}^{d_x} \times \mathbb{R}^{d_y}$ and marginals $p_x$ on $\mathbb{R}^{d_x}$ and $p_y$ on $\mathbb{R}^{d_y}$ . We are interested in testing $\mathcal{H}_0: p_{xy} = p_x \otimes p_y$ against $\mathcal{H}_1: p_{xy} \neq p_x \otimes p_y$ ; that is, we want to know if two components of the pairs of samples are independent or dependent. Gretton et al. (2005, 2008) propose a nonparametric kernel test based on the Hilbert Schmidt Independence Criterion (HSIC). It can be estimated using the quadratic-time estimator proposed by Song et al. (2012, Equation 5) which is a fourth-order one-sample $U$ -statistic
+
+$$
+\widehat {\mathrm {H S I C}} _ {k, \ell} (\mathbb {Z} _ {N}) = \frac {1}{| \mathbf {i} _ {4} ^ {N} |} \sum_ {(i, j, r, s) \in \mathbf {i} _ {4} ^ {N}} h _ {k, \ell} ^ {\mathrm {H S I C}} \left(Z _ {i}, Z _ {j}, Z _ {r}, Z _ {s}\right) \tag {3}
+$$
+
+for characteristic kernels $k$ on $\mathbb{R}^{d_x}$ and $\ell$ on $\mathbb{R}^{d_y}$ (Gretton, 2015), and where for $z_{a} = (x_{a},y_{a})\in$ $\mathbb{R}^{d_x}\times \mathbb{R}^{d_y}$ $a = 1,\ldots ,4$ , we let
+
+$$
+h _ {k, \ell} ^ {\mathrm {H S I C}} \left(z _ {1}, z _ {2}, z _ {3}, z _ {4}\right) := \frac {1}{4} h _ {k} ^ {\mathrm {M M D}} \left(x _ {1}, x _ {2}; x _ {3}, x _ {4}\right) h _ {\ell} ^ {\mathrm {M M D}} \left(y _ {1}, y _ {2}; y _ {3}, y _ {4}\right). \tag {4}
+$$
+
+Goodness-of-fit testing. For this problem, we are given a model density $p$ on $\mathbb{R}^d$ and i.i.d. samples $\mathbb{Z}_N \coloneqq (Z_i)_{1 \leq i \leq N}$ drawn from a density $q$ on $\mathbb{R}^d$ . The aim is again to test $\mathcal{H}_0: p = q$ against $\mathcal{H}_1: p \neq q$ ; that is, we want to know if the samples have been drawn from the model. Chwialkowski et al. (2016) and Liu et al. (2016) both construct a nonparametric goodness-of-fit test using the Kernel Stein Discrepancy (KSD). A quadratic-time KSD estimator can be computed as the second-order one-sample $U$ -statistic,
+
+$$
+\widehat {\mathrm {K S D}} _ {p, k} ^ {2} \left(\mathbb {Z} _ {N}\right) := \frac {1}{\left| \mathbf {i} _ {2} ^ {N} \right|} \sum_ {(i, j) \in \mathbf {i} _ {2} ^ {N}} h _ {k, p} ^ {\mathrm {K S D}} \left(Z _ {i}, Z _ {j}\right), \tag {5}
+$$
+
+where the Stein kernel $h_{k,p}^{\mathrm{KSD}}: \mathbb{R}^d \times \mathbb{R}^d \to \mathbb{R}$ is defined as
+
+$$
+\begin{array}{l} h _ {k, p} ^ {\mathrm {K S D}} (x, y) := \left(\nabla \log p (x) ^ {\top} \nabla \log p (y)\right) k (x, y) + \nabla \log p (y) ^ {\top} \nabla_ {x} k (x, y) \\ + \nabla \log p (x) ^ {\top} \nabla_ {y} k (x, y) + \sum_ {i = 1} ^ {d} \frac {\partial}{\partial x _ {i} \partial y _ {i}} k (x, y). \tag {6} \\ \end{array}
+$$
+
+In order to guarantee consistency of the Stein goodness-of-fit test (Chwialkowski et al., 2016, Theorem 2.2), we assume that the kernel $k$ is $C_0$ -universal (Carmeli et al., 2010, Definition 4.1) and that
+
+$$
+\mathbb {E} _ {q} \left[ h _ {k, p} ^ {\mathrm {K S D}} (z, z) \right] < \infty \quad \text {a n d} \quad \mathbb {E} _ {q} \left[ \left\| \nabla \log \left(\frac {p (z)}{q (z)}\right) \right\| _ {2} ^ {2} \right] < \infty . \tag {7}
+$$
+
+Quantile estimation. Multiple strategies have been proposed to estimate the quantiles of test statistics under the null for these three tests. We primarily focus on the wild bootstrap approach (Chwialkowski et al., 2014), though our results also hold using a parametric bootstrap for the goodness-of-fit setting (Schrab et al., 2022). In Section 7 we show that the same uniform separation rates can be derived for HSIC quadratic-time tests using permutations instead of a wild bootstrap.
+
+More details on MMD, HSIC, KSD, and on quantile estimation are provided in Appendix B.
+
+# 3 Incomplete $U$ -statistics for MMD, HSIC and KSD
+
+As presented above, the quadratic-time statistics for the two-sample (MMD), independence (HSIC) and goodness-of-fit (KSD) problems can be rewritten as $U$ -statistics with kernels $h_k^{\mathrm{MMD}}$ , $h_{k,\ell}^{\mathrm{HSIC}}$ and $h_{k,p}^{\mathrm{KSD}}$ , respectively. The computational cost of tests based on these $U$ -statistics grows quadratically with the sample size. When working with very large sample sizes, as it is often the case in real-world uses of those tests, this quadratic cost can become very problematic, and faster alternative tests are better adapted to this 'big data' setting. Multiple linear-time kernel tests have been proposed in the three testing frameworks (see Section I for details). We construct computationally efficient variants of the aggregated kernel tests proposed by Fromont et al. (2013), Albert et al. (2022), Kim et al. (2022), and Schrab et al. (2021, 2022) for the three settings, with the aim of retaining the significant power advantages of the aggregation procedure observed for quadratic-time tests. To this end, we propose to replace the quadratic-time $U$ -statistics presented in Equations (I), (3) and (5) with second-order incomplete $U$ -statistics (Blom, 1976; Janson, 1984; Lee, 1990),
+
+$$
+\overline {{\mathrm {M M D}}} _ {k} ^ {2} \left(\mathbb {X} _ {m}, \mathbb {Y} _ {n}; \mathcal {D} _ {N}\right) := \frac {1}{\left| \mathcal {D} _ {N} \right|} \sum_ {(i, j) \in \mathcal {D} _ {N}} h _ {k} ^ {\mathrm {M M D}} \left(X _ {i}, X _ {j}; Y _ {i}, Y _ {j}\right), \tag {8}
+$$
+
+$$
+\overline {{\mathrm {H S I C}}} _ {k, \ell} \left(\mathbb {Z} _ {N}; \mathcal {D} _ {\lfloor N / 2 \rfloor}\right) := \frac {1}{\left| \mathcal {D} _ {\lfloor N / 2 \rfloor} \right|} \sum_ {(i, j) \in \mathcal {D} _ {\lfloor N / 2 \rfloor}} h _ {k, \ell} ^ {\mathrm {H S I C}} \left(Z _ {i}, Z _ {j}, Z _ {i + \lfloor N / 2 \rfloor}, Z _ {j + \lfloor N / 2 \rfloor}\right), \tag {9}
+$$
+
+$$
+\overline {{\mathrm {K S D}}} _ {p, k} ^ {2} \left(\mathbb {Z} _ {N}; \mathcal {D} _ {N}\right) := \frac {1}{\left| \mathcal {D} _ {N} \right|} \sum_ {(i, j) \in \mathcal {D} _ {N}} h _ {k, p} ^ {\mathrm {K S D}} \left(Z _ {i}, Z _ {j}\right), \tag {10}
+$$
+
+where for the two-sample problem we let $N \coloneqq \min(m, n)$ , and where the design $\mathcal{D}_b$ is a subset of $\mathbf{i}_2^b$ (the set of all 2-tuples drawn without replacement from $\{1, \ldots, b\}$ ). Note that $\mathcal{D}_{[N/2]} \subseteq \mathbf{i}_2^{N/2} \subset \mathbf{i}_2^N$ . The design can be deterministic. For example, for the two-sample problem with equal even sample sizes $m = n = N$ , the deterministic design $\mathcal{D}_N = \{(2a - 1, 2a) : a = 1, \ldots, N/2\}$ corresponds to the MMD linear-time estimator proposed by Gretton et al. (2012a, Lemma 14). For fixed design size, the elements of the design can also be chosen at random without replacement, in which case the estimators in Equations (8) to (10) become random quantities given the data. For generality purposes, the results presented in this paper hold for both deterministic and random (without replacement) design choices while we focus on the deterministic design in our experiments. By fixing the design sizes in Equations (8) to (10) to be, for example,
+
+$$
+\left| \mathcal {D} _ {N} \right| = \left| \mathcal {D} _ {\lfloor N / 2 \rfloor} \right| = c N \tag {11}
+$$
+
+for some small constant $c \in \mathbb{N} \setminus \{0\}$ , we obtain incomplete $U$ -statistics which can be computed in linear time. Note that by pairing the samples $Z_{i} \coloneqq (X_{i}, Y_{i})$ , $i = 1, \dots, N$ for the MMD case and $\widetilde{Z}_{i} \coloneqq (Z_{i}, Z_{i + \lfloor N / 2 \rfloor}), i = 1, \dots, \lfloor N / 2 \rfloor$ for the HSIC case, we observe that all three incomplete $U$ -statistics of second order have the same form, with only the kernel functions and the design differing. The motivation for defining the estimators in Equations (8) and (9) as incomplete $U$ -statistics of order 2 (rather than of higher order) derives from the reasoning of Kim et al. (2022). Section 6) for permuted complete $U$ -statistics for the two-sample and independence problems (see Appendix E.1).
+
+# 4 Quantile and variance bounds for incomplete $U$ -statistics
+
+In this section, we derive upper quantile and variance bounds for a second-order incomplete degenerate $U$ -statistic with a generic degenerate kernel $h$ , for some design $\mathcal{D} \subseteq \mathbf{i}_2^N$ , defined as
+
+$$
+\overline {{U}} \left(\mathbb {Z} _ {N}; \mathcal {D}\right) := \frac {1}{| \mathcal {D} |} \sum_ {(i, j) \in \mathcal {D}} h \left(Z _ {i}, Z _ {j}\right).
+$$
+
+We will use these results to bound the quantiles and variances of our three test statistics for our hypothesis tests in Section 5. The derived bounds are of independent interest.
+
+In the following lemma, building on the results of Lee (1990), we directly derive an upper bound on the variance of the incomplete $U$ -statistic in terms of the sample size $N$ and of the design size $|\mathcal{D}|$ .
+
+Lemma 1. The variance of the incomplete $U$ -statistic can be upper bounded in terms of the quantities $\sigma_1^2 \coloneqq \operatorname{var}\big(\mathbb{E}\big[h(Z,Z')\big|Z'\big]\big)$ and $\sigma_2^2 \coloneqq \operatorname{var}(h(Z,Z'))$ with different bounds depending on the design choice. For deterministic (LHS) or random (RHS) design $\mathcal{D}$ and sample size $N$ , we have
+
+$$
+\operatorname {v a r} \left(\bar {U}\right) \lesssim \frac {N}{| \mathcal {D} |} \sigma_ {1} ^ {2} + \frac {1}{| \mathcal {D} |} \sigma_ {2} ^ {2} \quad \text {a n d} \quad \operatorname {v a r} \left(\bar {U}\right) \lesssim \frac {1}{N} \sigma_ {1} ^ {2} + \frac {1}{| \mathcal {D} |} \sigma_ {2} ^ {2}.
+$$
+
+The proof of Lemma $\square$ is deferred to Appendix F.2. We emphasize the fact that this variance bound also holds for random design with replacement, as considered by Blom (1976) and Lee (1990). For random design, we observe that if $|\mathcal{D}| \asymp N^2$ then the bound is $\sigma_1^2 / N + \sigma_2^2 / N^2$ which is the variance bound of the complete $U$ -statistic (Albert et al., 2022, Lemma 10). If $N \lesssim |\mathcal{D}| \lesssim N^2$ , the variance bound is $\sigma_1^2 / N + \sigma_2^2 / |\mathcal{D}|$ , and if $|\mathcal{D}| \lesssim N$ it is $\sigma_2^2 / |\mathcal{D}|$ since $\sigma_1^2 \leq \sigma_2^2 / 2$ (Blom, 1976, Equation 2.1).
+
+Kim et al. (2022) develop exponential concentration bounds for permuted complete $U$ -statistics, and Clémenton et al. (2013) study the uniform approximation of $U$ -statistics by incomplete $U$ -statistics. To the best of our knowledge, no quantile bounds have yet been obtained for incomplete $U$ -statistics in the literature. While permutations are well-suited for complete $U$ -statistics (Kim et al., 2022), using them with incomplete $U$ -statistics results in having to compute new kernel values, which comes at an additional computational cost we would like to avoid. Restricting the set of permutations to those for which the kernel values have already been computed for the original incomplete $U$ -statistic corresponds exactly to using a wild bootstrap (Schrab et al., 2021 Appendix B). Hence, we consider the wild bootstrapped second-order incomplete $U$ -statistic
+
+$$
+\bar {U} ^ {\epsilon} \left(\mathbb {Z} _ {N}; \mathcal {D}\right) := \frac {1}{| \mathcal {D} |} \sum_ {(i, j) \in \mathcal {D}} \epsilon_ {i} \epsilon_ {j} h \left(Z _ {i}, Z _ {j}\right) \tag {12}
+$$
+
+for i.i.d. Rademacher random variables $\epsilon_1, \ldots, \epsilon_N$ with values in $\{-1, 1\}$ , for which we derive an exponential concentration bound (quantile bound). We note the in-depth work of Chwialkowski et al. (2014) on the wild bootstrap procedure for kernel tests with applications to quadratic-time MMD and HSIC tests. We now provide exponential tail bounds for wild bootstrapped incomplete $U$ -statistics.
+
+Lemma 2. There exists some constant $C > 0$ such that, for every $t \geq 0$ , we have
+
+$$
+\mathbb {P} _ {\epsilon} \left(\left| \overline {{U}} ^ {\epsilon} \right| \geq t \mid \mathbb {Z} _ {N}, \mathcal {D}\right) \leq 2 \exp \left(- C \frac {t}{A _ {\mathrm {i n c}}}\right) \leq 2 \exp \left(- C \frac {t}{A}\right)
+$$
+
+where $A_{\mathrm{inc}}^2 \coloneqq |\mathcal{D}|^{-2}\sum_{(i,j) \in \mathcal{D}} h(Z_i, Z_j)^2$ and $A^2 \coloneqq |\mathcal{D}|^{-2}\sum_{(i,j) \in \mathbf{i}_2^N} h(Z_i, Z_j)^2$ .
+
+Lemma 2 is proved in Appendix F.3. While the second bound in Lemma 2 is less tight, it has the benefit of not depending on the choice of design $\mathcal{D}$ but only on its size $|\mathcal{D}|$ which is usually fixed.
+
+# 5 Efficient kernel tests using incomplete $U$ -statistics
+
+We now formally define the hypothesis tests obtained using the incomplete $U$ -statistics with a wild bootstrap. This is done for fixed kernel bandwidths $\lambda \in (0,\infty)^{d_x}$ , $\mu \in (0,\infty)^{d_y}$ , for the kernels
+
+$$
+k _ {\lambda} (x, y) := \prod_ {i = 1} ^ {d _ {x}} \frac {1}{\lambda_ {i}} K _ {i} \left(\frac {x _ {i} - y _ {i}}{\lambda_ {i}}\right), \quad \ell_ {\mu} (x, y) := \prod_ {i = 1} ^ {d _ {y}} \frac {1}{\mu_ {i}} L _ {i} \left(\frac {x _ {i} - y _ {i}}{\mu_ {i}}\right), \tag {13}
+$$
+
+for characteristic kernels $(x,y)\mapsto K_i(x - y),(x,y)\mapsto L_i(x - y)$ on $\mathbb{R}\times \mathbb{R}$ for functions $K_{i},L_{i}\in$ $L^1 (\mathbb{R})\cap L^2 (\mathbb{R})$ integrating to 1. We unify the notation for the three testing frameworks. For the two-sample and goodness-of-fit problems, we work only with $k_{\lambda}$ and have $d = d_{x}$ . For the independence
+
+problem, we work with the two kernels $k_{\lambda}$ and $\ell_{\mu}$ , and for ease of notation we let $d := d_x + d_y$ and $\lambda_{d_x + i} := \mu_i$ for $i = 1, \ldots, d_y$ . We also simply write $p := p_{xy}$ and $q := p_x \otimes p_y$ . We let $\overline{U}_{\lambda}$ and $h_{\lambda}$ denote either $\overline{\mathrm{MMD}}_{k_{\lambda}}^{2}$ and $h_{k_{\lambda}}^{\mathrm{MMD}}$ , or $\overline{\mathrm{HSIC}}_{k_{\lambda}, \ell_{\mu}}$ and $h_{k_{\lambda}, \ell_{\mu}}^{\mathrm{HSIC}}$ , or $\overline{\mathrm{KSD}}_{p, k_{\lambda}}^{2}$ and $h_{k_{\lambda}, p}^{\mathrm{KSD}}$ , respectively. We denote the design size of the incomplete $U$ -statistics in Equations (8) to (10) by
+
+$$
+L := \left| \mathcal {D} _ {N} \right| = \left| \mathcal {D} _ {\lfloor N / 2 \rfloor} \right|.
+$$
+
+For the three testing frameworks, we estimate the quantiles of the test statistics by simulating the null hypothesis using a wild bootstrap, as done in the case of complete $U$ -statistics by Fromont et al. (2012) and Schrab et al. (2021) for the two-sample problem, and by Schrab et al. (2022) for the goodness-of-fit problem. This is done by considering the original test statistic $U_{\lambda}^{B_1 + 1} \coloneqq \overline{U}_{\lambda}$ together with $B_1$ wild bootstrapped incomplete $U$ -statistics $U_{\lambda}^{1}, \ldots, U_{\lambda}^{B_1}$ computed as in Equation (12), and estimating the $(1 - \alpha)$ -quantile with a Monte Carlo approximation
+
+$$
+\widehat {q} _ {1 - \alpha} ^ {\lambda} := \inf \left\{t \in \mathbb {R}: 1 - \alpha \leq \frac {1}{B _ {1} + 1} \sum_ {b = 1} ^ {B _ {1} + 1} \mathbf {1} \left(U _ {\lambda} ^ {b} \leq t\right) \right\} = U _ {\lambda} ^ {\bullet^ {\lceil B _ {1} (1 - \alpha) \rceil}}, \tag {14}
+$$
+
+where $U_{\lambda}^{\bullet 1} \leq \dots \leq U_{\lambda}^{\bullet B_1 + 1}$ are the sorted elements $U_{\lambda}^{1}, \ldots, U_{\lambda}^{B_1 + 1}$ . The test $\Delta_{\alpha}^{\lambda}$ is defined as rejecting the null if the original test statistic $\overline{U}_{\lambda}$ is greater than the estimated $(1 - \alpha)$ -quantile, that is,
+
+$$
+\Delta_ {\alpha} ^ {\lambda} (\mathbb {Z} _ {N}) := \mathbf {1} \left(\bar {U} _ {\lambda} (\mathbb {Z} _ {N}) > \hat {q} _ {1 - \alpha} ^ {\lambda}\right).
+$$
+
+The resulting test has time complexity $\mathcal{O}(B_1L)$ where $L$ is the design size ( $1 \leq L \leq N(N - 1)$ ). We show in Proposition [1] that the test $\Delta_{\alpha}^{\lambda}$ has well-calibrated asymptotic level for goodness-of-fit testing, and well-calibrated non-asymptotic level for two-sample and independence testing. The proof of the latter non-asymptotic guarantee is based on the exchangeability of $U_{\lambda}^{1}, \ldots, U_{\lambda}^{B_{1} + 1}$ under the null hypothesis along with the result of Romano and Wolf (2005, Lemma 1). A similar proof strategy can be found in Fromont et al. (2012, Proposition 2), Albert et al. (2022, Proposition 1), and Schrab et al. (2021, Proposition 1). The exchangeability of wild bootstrapped incomplete $U$ -statistics for independence testing does not follow directly from the mentioned works. We show this through the interesting connection between $h_{k,\ell}^{\mathrm{HSIC}}$ and $\{h_k^{\mathrm{MMD}}, h_\ell^{\mathrm{MMD}}\}$ , the proof is deferred to Appendix F.1.
+
+Proposition 1. The test $\Delta_{\alpha}^{\lambda}$ has level $\alpha \in (0,1)$ , i.e. $\mathbb{P}_{\mathcal{H}_0}\bigl (\Delta_\alpha^\lambda (\mathbb{Z}_N) = 1\bigr)\leq \alpha$ . This holds non-asymptotically for the two-sample and independence cases, and asymptotically for goodness-of-fit.
+
+Having established the validity of the test $\Delta_{\alpha}^{\lambda}$ , we now study power guarantees for it in terms of the $L^2$ -norm of the difference in densities $\| p - q \|_2$ . In Theorem 1, we show for the three tests that, if $\| p - q \|_2$ exceeds some threshold, we can guarantee high test power. For the two-sample and independence problems, we derive uniform separation rates (Baraud, 2002) over Sobolev balls
+
+$$
+\mathcal {S} _ {d} ^ {s} (R) := \left\{f \in L ^ {1} \left(\mathbb {R} ^ {d}\right) \cap L ^ {2} \left(\mathbb {R} ^ {d}\right): \int_ {\mathbb {R} ^ {d}} \| \xi \| _ {2} ^ {2 s} | \widehat {f} (\xi) | ^ {2} \mathrm {d} \xi \leq (2 \pi) ^ {d} R ^ {2} \right\}, \tag {15}
+$$
+
+with radius $R > 0$ and smoothness parameter $s > 0$ , where $\widehat{f}$ denotes the Fourier transform of $f$ . The uniform separation rate over $\mathcal{S}_d^s (R)$ is the smallest value of $t$ such that, for any alternative with $\| p - q\| _2 > t$ and $\boxed{5}p - q\in \mathcal{S}_d^s (R)$ , the probability of type II error of $\Delta_{\alpha}^{\lambda}$ can be controlled by $\beta \in (0,1)$ . Before presenting Theorem $\boxed{1}$ we introduce further notation unified over the three testing frameworks; we define the integral transform $T_{\lambda}$ as
+
+$$
+\left(T _ {\lambda} f\right) (x) := \int_ {\mathbb {R} ^ {d}} f (x) \mathcal {K} _ {\lambda} (x, y) \mathrm {d} y \tag {16}
+$$
+
+for $f \in L^{2}(\mathbb{R}^{d})$ , $x \in \mathbb{R}^{d}$ , where $\mathcal{K}_{\lambda} \coloneqq k_{\lambda}$ for the two-sample problem, $\mathcal{K}_{\lambda} \coloneqq k_{\lambda} \otimes \ell_{\mu}$ for the independence problem, and $\mathcal{K}_{\lambda} \coloneqq h_{k_{\lambda},p}^{\mathrm{KSD}}$ for the goodness-of-fit problem. Note that, for the two-sample and independence testing frameworks, since $\mathcal{K}_{\lambda}$ is translation-invariant, the integral transform corresponds to a convolution. However, this is not true for the goodness-of-fit setting as $h_{k_{\lambda},p}^{\mathrm{KSD}}$ is not translation-invariant. We are now in a position to present our main contribution in Theorem ①: we derive power guarantee conditions for our tests using incomplete $U$ -statistics, and uniform separation rates over Sobolev balls for the two-sample and independence settings.
+
+Theorem 1. Suppose that the assumptions in Appendix [A.7] hold, and consider $\lambda \in (0,\infty)^d$ .
+
+(i) For sample size $N$ and design size $L$ , if there exists some $C > 0$ such that
+
+$$
+\| p - q \| _ {2} ^ {2} \geq \| (p - q) - T _ {\lambda} (p - q) \| _ {2} ^ {2} + C \frac {N}{L} \frac {\ln (1 / \alpha)}{\beta} \sigma_ {2, \lambda},
+$$
+
+then $\mathbb{P}_{\mathcal{H}_1}\big(\Delta_\alpha^\lambda (\mathbb{Z}_N) = 0\big)\leq \beta$ (type II error), where $\sigma_{2,\lambda}\lesssim 1 / \sqrt{\lambda_1\cdots\lambda_d}$ for MMD and HSIC.
+
+(ii) Fix $R > 0$ and $s > 0$ , and consider the bandwidths $\lambda_i^* \coloneqq (N / L)^{2/(4s + d)}$ for $i = 1, \ldots, d$ . For MMD and HSIC, the uniform separation rate of $\Delta_{\alpha}^{\lambda^*}$ over the Sobolev ball $S_d^s(R)$ is (up to a constant)
+
+$$
+\left(L / N\right) ^ {- 2 s / (4 s + d)}.
+$$
+
+The proof of Theorem I relies on the variance and quantile bounds presented in Lemmas I and 2, and also uses results of Albert et al. (2022) and Schrab et al. (2021, 2022) on complete $U$ -statistics. The details can be found in Appendix F.4. The power condition in Theorem I (i) corresponds to a variance-bias decomposition; for large bandwidths the bias term (first term) dominates, while for small bandwidths the variance term (second term which also controls the quantile) dominates. While the power guarantees of Theorem I hold for any design (either deterministic or uniformly random without replacement) of fixed size $L$ , the choice of design still influences the performance of the test in practice. The variance (but not its upper bound) depends on the choice of design; certain choices lead to minimum variance of the incomplete $U$ -statistic (Lee, 1990, Section 4.3.2).
+
+The minimax (i.e. optimal) rate over the Sobolev ball $S_{a}^{s}(R)$ is $N^{-2s/(4s+d)}$ for the two-sample (Li and Yuan, 2019; Theorem 5 (ii)) and independence (Albert et al., 2022; Theorem 4; Berrett et al., 2021; Corollary 5) problems. The rate for our incomplete $U$ -statistic test with time complexity $\mathcal{O}(B_1L)$ has the same dependence in the exponent as the minimax rate; $(L/N)^{-2s/(4s+d)} = N^{-2s/(4s+d)}(N^2/L)^{2s/(4s+d)}$ where $L \lesssim N^2$ with $L$ the design size and $N$ the sample size.
+
+- If $L \asymp N^2$ then the test runs in quadratic time and we recover exactly the minimax rate.
+- If $N \lesssim L \lesssim N^2$ then the rate still converges to 0; there is a trade-off between the cost $(N^2 / L)^{2s / (4s + d)}$ incurred in the minimax rate and the computational efficiency $\mathcal{O}(B_1L)$ .
+- If $L \lesssim N$ then there is no guarantee that the rate converges to 0.
+
+To summarize, the tests we propose have computational cost $\mathcal{O}(B_1L)$ which can be specified by the user with the choice of the number of wild bootstraps $B_{1}$ , and of the design size $L$ (as a function of the sample size $N$ ). There is a trade-off between test power and computational cost. We provide theoretical rates in terms of $L$ and $N$ , working up to a constant. The rate is minimax optimal in the case where $L$ grows quadratically with $N$ . We quantify exactly how, as the computational cost decreases from quadratic to linear in the sample size, the rate deteriorates gradually from being minimax optimal to not being guaranteed to convergence to zero. In our experiments, we use a design size which grows linearly with the sample size in order to compare our tests against other linear-time tests in the literature. The assumption guaranteeing that the rate converges to 0 is not satisfied in this setting, however, it would be satisfied for any faster growth of the design size (e.g. $L \asymp N \log \log N$ ).
+
+# 6 Efficient aggregated kernel tests using incomplete $U$ -statistics
+
+We now introduce our aggregated tests that combine single tests with different bandwidths. Our aggregation scheme is similar to those of Fromont et al. (2013), Albert et al. (2022) and Schrab et al. (2021, 2022), and can yield a test which is adaptive to the unknown smoothness parameter $s$ of the Sobolev ball $S_{d}^{s}(R)$ , with relatively low price. Let $\Lambda$ be a finite collection of bandwidths, $(w_{\lambda})_{\lambda \in \Lambda}$ be associated weights satisfying $\sum_{\lambda \in \Lambda} w_{\lambda} \leq 1$ , and $u_{\alpha}$ be some correction term defined shortly in Equation (17). Then, using the incomplete $U$ -statistic $\overline{U}_{\lambda}$ , we define our aggregated test $\Delta_{\alpha}^{\Lambda}$ as
+
+$$
+\Delta_ {\alpha} ^ {\Lambda} (\mathbb {Z} _ {N}) := \mathbf {1} \left(\overline {{U}} _ {\lambda} (\mathbb {Z} _ {N}) > \widehat {q} _ {1 - u _ {\alpha} w _ {\lambda}} ^ {\lambda} \text {f o r s o m e} \lambda \in \Lambda\right).
+$$
+
+The levels of the single tests are weighted and adjusted with a correction term
+
+$$
+u _ {\alpha} := \sup _ {B _ {3}} \left\{u \in \left(0, \min _ {\lambda \in \Lambda} w _ {\lambda} ^ {- 1}\right): \frac {1}{B _ {2}} \sum_ {b = 1} ^ {B _ {2}} \mathbf {1} \left(\max _ {\lambda \in \Lambda} \left(\widetilde {U} _ {\lambda} ^ {b} - U _ {\lambda} ^ {\bullet \lceil B _ {1} (1 - u w _ {\lambda}) \rceil}\right) > 0\right) \leq \alpha \right\}, \tag {17}
+$$
+
+where the wild bootstrapped incomplete $U$ -statistics $\widetilde{U}_{\lambda}^{1}, \ldots, \widetilde{U}_{\lambda}^{B_{2}}$ computed as in Equation (12) are used to perform a Monte Carlo approximation of the probability under the null, and where the supremum is estimated using $B_{3}$ steps of bisection method. Proposition 1, along with the reasoning of Schrab et al. (2021, Proposition 8), ensures that $\Delta_{\alpha}^{\Lambda}$ has non-asymptotic level $\alpha$ for the two-sample and independence cases, and asymptotic level $\alpha$ for the goodness-of-fit case. We refer to the three aggregated tests constructed using incomplete $U$ -statistics as MMDAggInc, HSICAggInc and KSDAggInc. The computational complexity of those tests is $\mathcal{O}(|\Lambda|(B_1 + B_2)L)$ , which means, for example, that if $L \asymp N$ as in Equation (11), the tests run efficiently in linear time in the sample size. We formally record error guarantees of $\Delta_{\alpha}^{\Lambda}$ and derive uniform separation rates over Sobolev balls.
+
+Theorem 2. Suppose that the assumptions in Appendix A.2 hold, and consider a collection $\Lambda$ .
+
+(i) For sample size $N$ and design size $L$ , if there exists some $C > 0$ such that
+
+$$
+\| p - q \| _ {2} ^ {2} \geq \min _ {\lambda \in \Lambda} \left(\| (p - q) - T _ {\lambda} (p - q) \| _ {2} ^ {2} + C \frac {N}{L} \frac {\ln \left(1 / (\alpha w _ {\lambda})\right)}{\beta} \sigma_ {2, \lambda}\right),
+$$
+
+then $\mathbb{P}_{\mathcal{H}_1}\big(\Delta_\alpha^\Lambda (\mathbb{Z}_N) = 0\big)\leq \beta$ (type II error), where $\sigma_{2,\lambda}\lesssim 1 / \sqrt{\lambda_1\cdots\lambda_d}$ for MMD and HSIC.
+
+(ii) Assume $L > N$ so that $\ln(\ln(L/N))$ is well-defined. Consider the collections of bandwidths and weights (independent of the parameters $s$ and $R$ of the Sobolev ball $S_d^s(R)$ )
+
+$$
+\Lambda := \left\{\left(2 ^ {- \ell}, \dots , 2 ^ {- \ell}\right) \in (0, \infty) ^ {d}: \ell \in \left\{1, \dots , \left\lceil \frac {2}{d} \log_ {2} \left(\frac {L / N}{\ln (\ln (L / N))}\right)\right\rceil \right\}\right\}, \quad w _ {\lambda} := \frac {6}{\pi^ {2} \ell^ {2}}.
+$$
+
+For the two-sample and independence problems, the uniform separation rate of $\Delta_{\alpha}^{\Lambda}$ over the Sobolev balls $\{S_d^s (R):R > 0,s > 0\}$ is (up to a constant)
+
+$$
+\left(\frac {L / N}{\ln (\ln (L / N))}\right) ^ {- 2 s / (4 s + d)}.
+$$
+
+The extension from Theorem 1 to Theorem 2 has been proved for complete $U$ -statistics in the two-sample (Fromont et al., 2013; Schrab et al., 2021), independence (Albert et al., 2022) and goodness-of-fit (Schrab et al., 2022) testing frameworks. The proof of Theorem 2 follows with the same reasoning by simply replacing $N$ with $L / N$ as we work with incomplete $U$ -statistics; this 'replacement' is theoretically justified by Theorem 1. Theorem 2 shows that the aggregated test $\Delta_{\alpha}^{\Lambda}$ is adaptive over Sobolev balls $\{S_d^s (R):R > 0,s > 0\}$ : the test $\Delta_{\alpha}^{\Lambda}$ does not depend on the unknown smoothness parameter $s$ (unlike $\Delta_{\alpha}^{\lambda^{*}}$ in Theorem 1) and achieves the minimax rate, up to an iterated logarithmic factor, and up to the cost incurred for efficiency of the test (i.e. $L / N$ instead of $N$ ).
+
+# 7 Minimax optimal permuted quadratic-time aggregated independence test
+
+Considering Theorem 2 with our incomplete $U$ -statistic with full design $\mathcal{D} = \mathbf{i}_2^N$ for which $L \asymp N^2$ , we have proved that the quadratic-time two-sample and independence aggregated tests using a wild bootstrap achieve the rate $(N / \ln (\ln (N)))^{-2s / (4s + d)}$ over the Sobolev balls $\{S_d^s (R): R > 0, s > 0\}$ . This is the minimax rate (Li and Yuan, 2019; Albert et al., 2022), up to some iterated logarithmic term. For the two-sample problem, Kim et al. (2022) and Schrab et al. (2021) show that this optimality result also holds when using complete $U$ -statistics with permutations. Whether the equivalent statement for the independence test with permutations holds has not yet been addressed; the rate can be proved using theoretical (unknown) quantiles with a Gaussian kernel (Albert et al., 2022), but has not yet been proved using permutations. Kim et al. (2022) Proposition 8.7) consider this problem, again using a Gaussian kernel, but they do not obtain the correct dependence on $\alpha$ (i.e. they obtain $\alpha^{-1/2}$ rather than $\ln (1/\alpha)$ ), hence they cannot recover the desired rate. As pointed out by Kim et al. (2022), Section 8): 'It remains an open question as to whether [the power guarantee] continues to hold when $\alpha^{-1/2}$ is replaced by $\ln (1/\alpha)$ . We now prove that we can improve the $\alpha$ -dependence to $\ln (1/\alpha)^{3/2}$ for any bounded kernel of the form of Equation (13), and that this allows us to obtain the desired rate over Sobolev balls $\{S_d^s (R): R > 0, s > d/4\}$ . The assumption $s > d/4$ imposes a stronger smoothness restriction on $p - q \in S_d^s (R)$ , which is similarly also considered by Li and Yuan (2019).
+
+Theorem 3. Consider the quadratic-time independence test using the complete $U$ -statistic HSIC estimator with a quantile estimated using permutations as done by [Kim et al. (2022) Proposition 8.7), with kernels as in Equation (13) for bounded functions $K_{i}$ and $L_{j}$ for $i = 1, \ldots, d_{x}$ , $j = 1, \ldots, d_{y}$ . (i) Suppose that the assumptions in Appendix A.1 hold. For fixed $R > 0$ , $s > d / 4$ , and bandwidths $\lambda_{i}^{*} \coloneqq N^{-2/(4s + d)}$ for $i = 1, \ldots, d$ , the probability of type II error of the test is controlled by $\beta$ when
+
+$$
+\| p - q \| _ {2} ^ {2} \geq \| (p - q) - T _ {\lambda^ {*}} (p - q) \| _ {2} ^ {2} + C \frac {1}{N} \frac {\ln (1 / \alpha) ^ {3 / 2}}{\beta \sqrt {\lambda_ {1} ^ {*} \cdots \lambda_ {d} ^ {*}}} \quad f o r s o m e c o n s t a n t C > 0.
+$$
+
+The uniform separation rate over the Sobolev ball $S_d^s (R)$ is, up to a constant, $N^{-2s / (4s + d)}$ .
+
+(ii) Suppose that the assumptions in Appendix A.2 hold. The uniform separation rate over the Sobolev balls $\{S_d^s (R):R > 0,s > d / 4\}$ is $(N / \ln (\ln (N)))^{-2s / (4s + d)}$ , up to a constant, with the collections
+
+$$
+\Lambda := \left\{\left(2 ^ {- \ell}, \dots , 2 ^ {- \ell}\right) \in (0, \infty) ^ {d}: \ell \in \left\{1, \dots , \left\lceil \frac {2}{d} \log_ {2} \left(\frac {N}{\ln (\ln (N))}\right)\right\rceil \right\}\right\}, \quad w _ {\lambda} := \frac {6}{\pi^ {2} \ell^ {2}}.
+$$
+
+The proof of Theorem 3 in Appendix F.5 uses the exponential concentration bound of Kim et al. (2022, Theorem 6.3) for permuted complete $U$ -statistics. Another possible approach to obtain the correct dependency on $\alpha$ is to employ the sample-splitting method proposed by Kim et al. (2022, Section 8.3) in order to transform the independence problem into a two-sample problem. While this indirect approach leads to a logarithmic factor in $\alpha$ , the practical power would be suboptimal due to an inefficient use of the data from sample splitting. Theorem 3(i) shows that a $\ln(1/\alpha)^{3/2}$ dependence is achieved by the more practical permutation-based HSIC test. Theorem 3(ii) demonstrates that this leads to a minimax optimal rate for the aggregated HSIC test, up to the $\ln(\ln(N))$ cost for adaptivity.
+
+# 8 Experiments
+
+For the two-sample problem, we consider testing samples drawn from a uniform density on $[0,1]^d$ against samples drawn from a perturbed uniform density. For the independence problem, the joint density is a perturbed uniform density on $[0,1]^{d_x + d_y}$ , the marginals are then simply uniform densities. Those perturbed uniform densities can be shown to lie in Sobolev balls (Li and Yuan, 2019; Albert et al., 2022), to which our tests are adaptive. For the goodness-of-fit problem, we use a Gaussian-Bernoulli Restricted Boltzmann Machine as first considered by Liu et al. (2016) in this testing framework. We use collections of 21 bandwidths for MMD and HSIC and of 25 bandwidth pairs for HSIC; more details on the experiments (e.g. model and test parameters) are presented in Appendix C
+
+We consider our incomplete aggregated tests MMDAggInc, HSICAggInc and KSDAggInc, with parameter $R \in \{1, \dots, N - 1\}$ which fixes the deterministic design to consist of the first $R$ subdiagonals of the $N \times N$ matrix, i.e. $\mathcal{D} \coloneqq \{(i, i + r) : i = 1, \dots, N - r \text{ for } r = 1, \dots, R\}$ with size $|\mathcal{D}| = RN - R(R - 1)/2$ . We run our incomplete tests with $R \in \{1, 100, 200\}$ and also the complete test using the full design $\mathcal{D} = \mathbf{i}_2^N$ . We compare their performances with current linear-time state-of-the-art tests: ME, SCF, FSIC and FSSD (Jitkrittum et al., 2016, 2017a,b) which evaluate the witness functions at a finite set of locations chosen to maximize the power, Cauchy RFF (random Fourier feature) and L1 IMQ (Huggins and Mackey, 2018) which are random feature Stein discrepancies, LSD (Grathwohl et al., 2020) which uses a neural network to learn the Stein discrepancy, and OST PSI (Kübler et al., 2020) which performs kernel selection using post selection inference.
+
+Similar trends are observed across all our experiments in Figure $\square$ for the three testing frameworks, when varying the sample size, the dimension, and the difficulty of the problem (scale of perturbations or noise level). The linear-time tests AggInc $R = 200$ almost match the power obtained by the quadratic-time tests AggCom in all settings (except in Figure $\square$ (i) where the difference is larger) while being computationally much more efficient as can be seen in Figure $\square$ (d, h, l). The incomplete tests with $R = 100$ have power only slightly below the ones using $R = 200$ , and run roughly twice as fast (Figure $\square$ (d, h, l)). In all experiments, those three tests (AggInc $R = 100$ , 200 and AggCom) have significantly higher power than the linear-time tests which optimize test locations (ME, SCF, FSIC and FSSD); in the two-sample case the aggregated tests run faster for small sample size but slower for large sample size, in the independence case the aggregated tests run much faster, and in the goodness-of-fit case FSSD runs faster. While both types of tests are linear, we note that the runtimes
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+Figure 1: Two-sample $(a - d)$ and independence $(e - h)$ experiments using perturbed uniform densities. Goodness-of-fit $(i - l)$ experiment using a Gaussian-Bernoulli Restricted Boltzmann Machine. The power results are averaged over 100 repetitions and the runtimes over 20 repetitions.
+
+
+
+
+
+
+
+
+
+of the tests of Jitkrittum et al. (2016, 2017a,b) increase slower with the sample size than those of our aggregated tests with $R = 100, 200$ , but a fixed computational cost is incurred for their optimization step, even for small sample sizes. In the goodness-of-fit framework, L1 IMQ performs similarly to FSSD which is in line with the results presented by Huggins and Mackey (2018, Figure 4d) who consider the same experiment. All other goodness-of-fit tests (except KSDAggInc $R = 1$ ) achieve much higher test power. Cauchy RFF and KSDAggInc $R = 200$ obtain similar power in almost all the experiments. While KSDAggInc $R = 200$ runs much faster in the experiments presented it seems that the KSDAggInc runtimes increase more steeply with the sample size than the Cauchy RFF and L1 IMQ runtimes (see Appendix D.5 for details). LSD matches the power of KSDAggInc $R = 100$ when varying the noise level in Figure I(k) (KSDAggInc $R = 200$ has higher power), and when varying the hidden dimension in Figure I(j) where $d_x = 100$ . When varying the sample size in Figure I(i), both KSDAggInc tests with $R = 100, 200$ achieve much higher power than LSD. Unsurprisingly, AggInc $R = 1$ , which runs much faster than all the aforementioned tests, has low power in every experiment. For the two-sample problem, it obtains slightly higher power than OST PSI which runs even faster. We include more experiments in Appendix D: we present experiments on the MNIST dataset (same trends are observed), we use different collection of bandwidths, we verify that all tests have well-calibrated levels, and illustrate the benefits of the aggregation procedure.
+
+# 9 Acknowledgements
+
+Antonin Schrab acknowledges support from the U.K. Research and Innovation (EP/S021566/1). Ilmun Kim acknowledges support from the Yonsei University Research Fund of 2021-22-0332, and from the Basic Science Research Program through the National Research Foundation of Korea funded by the Ministry of Education (2022R1A4A1033384). Benjamin Guedj acknowledges partial support by the U.S. Army Research Laboratory and the U.S. Army Research Office, and by the U.K. Ministry of Defence and the U.K. Engineering and Physical Sciences Research Council (EP/R013616/1), and by the French National Agency for Research (ANR-18-CE40-0016-01 & ANR-18-CE23-0015-02). Arthur Gretton acknowledges support from the Gatsby Charitable Foundation.
+
+# References
+
+Albert, M., Laurent, B., Marrel, A., and Meynaoui, A. (2022). Adaptive test of independence based on HSIC measures. The Annals of Statistics, 50(2):858-879.
+Aronszajn, N. (1950). Theory of reproducing kernels. Transactions of the American Mathematical Society, 68(3):337-404.
+Balasubramanian, K., Li, T., and Yuan, M. (2021). On the optimality of kernel-embedding based goodness-of-fit tests. Journal of Machine Learning Research, 22(1).
+Baraud, Y. (2002). Non-asymptotic minimax rates of testing in signal detection. Bernoulli, 1(8(5):577-606).
+Berrett, T. B., Kontoyiannis, I., and Samworth, R. J. (2021). Optimal rates for independence testing via u-statistic permutation tests. The Annals of Statistics, 49(5):2457-2490.
+Blom, G. (1976). Some properties of incomplete U-statistics. Biometrika, 63(3):573-580.
+Carmeli, C., De Vito, E., Toigo, A., and Umanita, V. (2010). Vector valued reproducing kernel Hilbert spaces and universality. Analysis and Applications, 8(01):19-61.
+Chebyshev, P. L. (1899). Oeuvres. Commissionaires de l'Académie Imperiale des Sciences, 1.
+Cherfaoui, F., Kadri, H., Anthoine, S., and Ralaivola, L. (2022). A discrete RKHS standpoint for Nyström MMD. HAL preprint hal-03651849.
+Chwialkowski, K., Sejdinovic, D., and Gretton, A. (2014). A wild bootstrap for degenerate kernel tests. In Advances in neural information processing systems, pages 3608-3616.
+Chwialkowski, K., Strathmann, H., and Gretton, A. (2016). A kernel test of goodness of fit. In International Conference on Machine Learning, pages 2606-2615. PMLR.
+Chwialkowski, K. P., Ramdas, A., Sejdinovic, D., and Gretton, A. (2015). Fast two-sample testing with analytic representations of probability measures. In Advances in Neural Information Processing Systems, volume 28, pages 1981-1989.
+Clémenton, S., Robbiano, S., and Tressou, J. (2013). Maximal deviations of incomplete U-statistics with applications to empirical risk sampling. In Proceedings of the 2013 SIAM International Conference on Data Mining, pages 19-27. SIAM.
+de la Peña, V. H. and Giné, E. (1999). Decoupling: From Dependence to Independence. Springer Science & Business Media.
+Dinh, L., Sohl-Dickstein, J., and Bengio, S. (2017). Density estimation using real NVP. In International Conference on Learning Representations.
+Duembgen, L. (1998). Symmetrization and decoupling of combinatorial random elements. Statistics & probability letters, 39(4):355-361.
+Dvoretzky, A., Kiefer, J., and Wolfowitz, J. (1956). Asymptotic minimax character of the sample distribution function and of the classical multinomial estimator. The Annals of Mathematical Statistics, pages 642-669.
+Fithian, W., Sun, D., and Taylor, J. (2014). Optimal inference after model selection. arXiv preprint arXiv:1410.2597.
+Freidling, T., Poinard, B., Climente-González, H., and Yamada, M. (2021). Post-selection inference with HSIC-Lasso. In International Conference on Machine Learning, pages 3439-3448. PMLR.
+Fromont, M., Laurent, B., Lerasle, M., and Reynaud-Bouret, P. (2012). Kernels based tests with non-asymptotic bootstrap approaches for two-sample problems. In Conference on Learning Theory, PMLR.
+
+Fromont, M., Laurent, B., and Reynaud-Bouret, P. (2013). The two-sample problem for Poisson processes: Adaptive tests with a nonasymptotic wild bootstrap approach. The Annals of Statistics, 41(3):1431-1461.
+Fukumizu, K., Gretton, A., Sun, X., and Scholkopf, B. (2008). Kernel measures of conditional dependence. In Advances in Neural Information Processing Systems, volume 1, pages 489-496.
+Gorham, J. and Mackey, L. (2017). Measuring sample quality with kernels. In International Conference on Machine Learning, pages 1292-1301. PMLR.
+Grathwohl, W., Wang, K.-C., Jacobsen, J.-H., Duvenaud, D., and Zemel, R. (2020). Learning the Stein discrepancy for training and evaluating energy-based models without sampling. In International Conference on Machine Learning, pages 3732-3747. PMLR.
+Gretton, A. (2015). A simpler condition for consistency of a kernel independence test. arXiv preprint arXiv:1501.06103.
+Gretton, A., Borgwardt, K. M., Rasch, M. J., Scholkopf, B., and Smola, A. (2012a). A kernel two-sample test. Journal of Machine Learning Research, 13:723-773.
+Gretton, A., Fukumizu, K., Harchaoui, Z., and Sriperumbudur, B. K. (2009). A fast, consistent kernel two-sample test. Advances in Neural Information Processing Systems, 22.
+Gretton, A., Fukumizu, K., Teo, C. H., Song, L., Schölkopf, B., and Smola, A. J. (2008). A kernel statistical test of independence. In Advances in Neural Information Processing Systems, volume 1, pages 585-592.
+Gretton, A., Herbrich, R., Smola, A., Bousquet, O., and Scholkopf, B. (2005). Kernel methods for measuring independence. Journal of Machine Learning Research, 6:2075-2129.
+Gretton, A., Sejdinovic, D., Strathmann, H., Balakrishnan, S., Pontil, M., Fukumizu, K., and Sriperumbudur, B. K. (2012b). Optimal kernel choice for large-scale two-sample tests. In Advances in Neural Information Processing Systems, volume 1, pages 1205-1213.
+Ho, H.-C. and Shieh, G. S. (2006). Two-stage U-statistics for hypothesis testing. Scandinavian journal of statistics, 33(4):861-873.
+Hoeffding, W. (1992). A class of statistics with asymptotically normal distribution. In *Breakthroughs in Statistics*, pages 308-334. Springer.
+Huggins, J. and Mackey, L. (2018). Random feature Stein discrepancies. Advances in Neural Information Processing Systems, 31.
+Janson, S. (1984). The asymptotic distributions of incomplete U-statistics. Zeitschrift für Wahrscheinlichkeitstheorie und Verwandte Gebiete, 66(4):495-505.
+Jitkrittum, W., Szabó, Z., Chwialkowski, K. P., and Gretton, A. (2016). Interpretable distribution features with maximum testing power. In Advances in Neural Information Processing Systems, volume 29, pages 181-189.
+Jitkrittum, W., Szabó, Z., and Gretton, A. (2017a). An adaptive test of independence with analytic kernel embeddings. In International Conference on Machine Learning (ICML), pages 1742-1751.
+Jitkrittum, W., Xu, W., Szabó, Z., Fukumizu, K., and Gretton, A. (2017b). A linear-time kernel goodness-of-fit test. In Advances in Neural Information Processing Systems, pages 262-271.
+Key, O., Fernandez, T., Gretton, A., and Briol, F.-X. (2021). Composite goodness-of-fit tests with kernels. arXiv preprint arXiv:2111.10275.
+Kim, I., Balakrishnan, S., and Wasserman, L. (2022). Minimax optimality of permutation tests. The Annals of Statistics, 50(1):225-251.
+Kingma, D. P. and Ba, J. (2014). Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980.
+
+Kingma, D. P. and Dhariwal, P. (2018). Glow: Generative flow with invertible 1x1 convolutions. In Advances in Neural Information Processing Systems, pages 10236-10245.
+Kübler, J. M., Jitkrittum, W., Schölkopf, B., and Muandet, K. (2020). Learning kernel tests without data splitting. In Advances in Neural Information Processing Systems 33, pages 6245-6255. Curran Associates, Inc.
+Kübler, J. M., Jitkrittum, W., Schölkopf, B., and Muandet, K. (2022). A witness two-sample test. In International Conference on Artificial Intelligence and Statistics, pages 1403-1419. PMLR.
+LeCun, Y., Cortes, C., and Burges, C. (2010). MNIST handwritten digit database. AT&T Labs.
+Lee, J. (1990). U-statistics: Theory and Practice. CiteSeer.
+Lee, J. D., Sun, D. L., Sun, Y., and Taylor, J. E. (2016). Exact post-selection inference, with application to the Lasso. The Annals of Statistics, 44(3):907-927.
+Leucht, A. and Neumann, M. H. (2013). Dependent wild bootstrap for degenerate U- and V-statistics. Journal of Multivariate Analysis, 117:257-280.
+Li, T. and Yuan, M. (2019). On the optimality of gaussian kernel based nonparametric tests against smooth alternatives. arXiv preprint arXiv:1909.03302.
+Lim, J. N., Yamada, M., Jitkrittum, W., Terada, Y., Matsui, S., and Shimodaira, H. (2020). More powerful selective kernel tests for feature selection. In International Conference on Artificial Intelligence and Statistics, pages 820-830. PMLR.
+Lim, J. N., Yamada, M., Schölkopf, B., and JITkrittum, W. (2019). Kernel Stein tests for multiple model comparison. In Advances in Neural Information Processing Systems, pages 2240-2250.
+Liu, Q., Lee, J., and Jordan, M. (2016). A kernelized Stein discrepancy for goodness-of-fit tests. In International Conference on Machine Learning, pages 276-284. PMLR.
+Massart, P. (1990). The tight constant in the Dvoretzky-Kiefer-Wolffowitz inequality. The Annals of Probability, 18(3):1269-1283.
+Müller, A. (1997). Integral probability metrics and their generating classes of functions. Advances in Applied Probability, 1:429-443.
+Rahimi, A. and Recht, B. (2007). Random features for large-scale kernel machines. In Advances in Neural Information Processing Systems (NIPS), pages 1177-1184.
+Ramachandran, P., Zoph, B., and Le, Q. V. (2017). Searching for activation functions. arXiv preprint arXiv:1710.05941.
+Romano, J. P. and Wolf, M. (2005). Exact and approximate stepdown methods for multiple hypothesis testing. Journal of the American Statistical Association, 100(469):94-108.
+Schrab, A., Guedj, B., and Gretton, A. (2022). KSD Aggregated goodness-of-fit test. In Advances in Neural Information Processing Systems 35: Annual Conference on Neural Information Processing Systems 2022, NeurIPS 2022.
+Schrab, A., Kim, I., Albert, M., Laurent, B., Guedj, B., and Gretton, A. (2021). MMD Aggregated two-sample test. arXiv preprint arXiv:2110.15073.
+Shao, X. (2010). The dependent wild bootstrap. Journal of the American Statistical Association, 105(489):218-235.
+Song, L., Smola, A. J., Gretton, A., Bedo, J., and Borgwardt, K. M. (2012). Feature selection via dependence maximization. Journal of Machine Learning Research, 13:1393-1434.
+Sriperumbudur, B. K., Fukumizu, K., and Lanckriet, G. R. (2011). Universality, characteristic kernels and RKHS embedding of measures. Journal of Machine Learning Research, 12(7).
+
+Srivastava, N., Hinton, G., Krizhevsky, A., Sutskever, I., and Salakhutdinov, R. (2014). Dropout: a simple way to prevent neural networks from overfitting. Journal of Machine Learning Research, 15(1):1929-1958.
+Sutherland, D. J., Tung, H.-Y., Strathmann, H., De, S., Ramdas, A., Smola, A., and Gretton, A. (2017). Generative models and model criticism via optimized maximum mean discrepancy. In International Conference on Learning Representations.
+Yamada, M., Umezu, Y., Fukumizu, K., and Takeuchi, I. (2018). Post selection inference with kernels. In International Conference on Artificial Intelligence and Statistics, pages 152-160. PMLR.
+Yamada, M., Wu, D., Tsai, Y. H., Ohta, H., Salakhutdinov, R., Takeuchi, I., and Fukumizu, K. (2019). Post selection inference with incomplete maximum mean discrepancy estimator. In International Conference on Learning Representations.
+Zaremba, W., Gretton, A., and Blaschko, M. (2013). B-test: A non-parametric, low variance kernel two-sample test. Advances in neural information processing systems, 26.
+Zhang, Q., Filippi, S., Gretton, A., and Sejdinovic, D. (2018). Large-scale kernel methods for independence testing. Statistics and Computing, 28(1):113-130.
+Zhao, J. and Meng, D. (2015). FastMMD: Ensemble of circular discrepancy for efficient two-sample test. Neural computation, 27(6):1345-1372.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See framed bullet points at the end of Section 5 (limitation for the case $L < N$ ).
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes] See main text for Theorem 2 and appendices for all other proofs.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] URL in Section [1]: https://github.com/antoninschrab/agginc-paper.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Appendix C
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] For the time plots in Figure I we report the error bars which represent the standard deviation (they are really small and cannot always been seen). For the power plots in Figure I since the test outputs are binary (0 or 1), there is no need to include error bars since these are deterministic given the average which is plotted.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Appendix C
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] See Appendix
+(b) Did you mention the license of the assets? [Yes] See Appendix C.
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes]
+URL in Section 1: https://github.com/antoninschrab/agginc-paper.
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientaggregatedkerneltestsusingincompleteustatistics/images.zip b/efficientaggregatedkerneltestsusingincompleteustatistics/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..83205bb9eff835a1052019d370a8909e93ee5aa6
--- /dev/null
+++ b/efficientaggregatedkerneltestsusingincompleteustatistics/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1c878a07a75531315411d545798254fe0bf81980bdcfdb567a3931cc1deda5df
+size 387061
diff --git a/efficientaggregatedkerneltestsusingincompleteustatistics/layout.json b/efficientaggregatedkerneltestsusingincompleteustatistics/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..d942c022ecceb468c91802b2b8433c1d10c72e67
--- /dev/null
+++ b/efficientaggregatedkerneltestsusingincompleteustatistics/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8db499581df253e346ad30d5f58109e894356f2442bbdf288b08e44c0a4c90c9
+size 699167
diff --git a/efficientandeffectiveaugmentationstrategyforadversarialtraining/6df68082-31ec-4798-b6a0-2c22f2a5c38d_content_list.json b/efficientandeffectiveaugmentationstrategyforadversarialtraining/6df68082-31ec-4798-b6a0-2c22f2a5c38d_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..cda2e1f8ecefa9c2aa24e473c307319bfcade416
--- /dev/null
+++ b/efficientandeffectiveaugmentationstrategyforadversarialtraining/6df68082-31ec-4798-b6a0-2c22f2a5c38d_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d1ed88fd97b03a36dd1d81acbf0939ef68b04804e0521f3a0ec1d0c0de98b7c0
+size 90287
diff --git a/efficientandeffectiveaugmentationstrategyforadversarialtraining/6df68082-31ec-4798-b6a0-2c22f2a5c38d_model.json b/efficientandeffectiveaugmentationstrategyforadversarialtraining/6df68082-31ec-4798-b6a0-2c22f2a5c38d_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..5681e05b96370c009b3a961055c337c96f579fc5
--- /dev/null
+++ b/efficientandeffectiveaugmentationstrategyforadversarialtraining/6df68082-31ec-4798-b6a0-2c22f2a5c38d_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7b6ed63a70d4de78a07e96a0447b09df8c47c9c2f2aebeecb78787a60c31309c
+size 112981
diff --git a/efficientandeffectiveaugmentationstrategyforadversarialtraining/6df68082-31ec-4798-b6a0-2c22f2a5c38d_origin.pdf b/efficientandeffectiveaugmentationstrategyforadversarialtraining/6df68082-31ec-4798-b6a0-2c22f2a5c38d_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..89bc0467e2257b19ff7ac5fffafd80032fc137e1
--- /dev/null
+++ b/efficientandeffectiveaugmentationstrategyforadversarialtraining/6df68082-31ec-4798-b6a0-2c22f2a5c38d_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7a435a10dc1bb08a9a47fd92f3b3a3e0e54036fead976fa43aeaf3e36e128eb3
+size 1317317
diff --git a/efficientandeffectiveaugmentationstrategyforadversarialtraining/full.md b/efficientandeffectiveaugmentationstrategyforadversarialtraining/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..d35a85ac23773ae31c26c7a3d67f53c40dcc477c
--- /dev/null
+++ b/efficientandeffectiveaugmentationstrategyforadversarialtraining/full.md
@@ -0,0 +1,302 @@
+# Efficient and Effective Augmentation Strategy for Adversarial Training
+
+Srivanti Addepalli† * Samyak Jain† ⋅‡ * R.Venkatesh Babu†
+
+† Video Analytics Lab, Indian Institute of Science, Bangalore
+
+$\diamond$ Indian Institute of Technology (BHU) Varanasi
+
+# Abstract
+
+Adversarial training of Deep Neural Networks is known to be significantly more data-hungry when compared to standard training. Furthermore, complex data augmentations such as AutoAugment, which have led to substantial gains in standard training of image classifiers, have not been successful with Adversarial Training. We first explain this contrasting behavior by viewing augmentation during training as a problem of domain generalization, and further propose Diverse Augmentation-based Joint Adversarial Training (DAJAT) to use data augmentations effectively in adversarial training. We aim to handle the conflicting goals of enhancing the diversity of the training dataset and training with data that is close to the test distribution by using a combination of simple and complex augmentations with separate batch normalization layers during training. We further utilize the popular Jensen-Shannon divergence loss to encourage the joint learning of the diverse augmentations, thereby allowing simple augmentations to guide the learning of complex ones. Lastly, to improve the computational efficiency of the proposed method, we propose and utilize a two-step defense, Ascending Constraint Adversarial Training (ACAT), that uses an increasing epsilon schedule and weight-space smoothing to prevent gradient masking. The proposed method DAJAT achieves substantially better robustness-accuracy trade-off when compared to existing methods on the RobustBench Leaderboard on ResNet-18 and WideResNet-34-10. The code for implementing DAJAT is available here: https://github.com/val-iisc/DAJAT.
+
+# 1 Introduction
+
+Deep Neural Network (DNN) based image classifiers are vulnerable to crafted imperceptible perturbations known as Adversarial Attacks [41] that can flip the predictions of the model to unrelated classes leading to disastrous implications. Adversarial Training [14, 27, 50] has been the most successful defense strategy, where a model is explicitly trained to be robust in the presence of such attacks. While early defenses focused on designing suitable loss functions for training, subsequent works [29, 34] showed that with careful hyperparameter tuning, even the two most popular methods PGD-AT [27] and TRADES [50] yield comparable performance, highlighting the saturation in performance with respect to changes in the training loss. Schmidt et al. [35] observed that adversarial training has a large sample complexity and further gains require the use of additional training data. Subsequent works [5, 16] indeed used additional data whose distribution is close to that of the original dataset in order to obtain performance gains. The availability of large amounts of relevant data is impractical to assume, leading to an exploration towards augmentations based on Generative Adversarial Networks [13] and Diffusion based models [19, 16]. However, the use of such generative models incurs an
+
+
+Figure 1: A Schematic representation of the proposed approach DAJAT
+
+additional training cost and suffers from limited diversity in low-data regimes and in datasets with high-resolution images.
+
+A simple and efficient solution to improve the diversity of training data in standard Empirical Risk Minimization (ERM) based training has been the use of random transformations such as rotation, color jitter, and variations in contrast, sharpness and brightness [24, 8, 9], which can change images significantly in input space while belonging to the same class as the original image. However, prior works have surprisingly found that such augmentations, that cause large changes in the input distribution, do not help adversarial training [34, 15, 40]. This limits the augmentations in adversarial training to simple ones - zero padding followed by random crop, and horizontal flip [34, 29, 15] - which may not be able to fill in the large data requirement of Adversarial Training.
+
+In this work, we firstly analyze the reasons for this contrasting trend between Standard and Adversarial Training, and further show that it is indeed possible to utilize complex augmentations effectively in Adversarial training as well, by jointly training on simple and complex data augmentations using separate batch-normalization layers for each type, as shown in Fig.1. While complex augmentations increase the data diversity resulting in better generalization, simple augmentations ensure that the model specializes on the training data distribution as well. We further minimize the Jenson-Shannon divergence between the softmax outputs of various augmentations to enable the simple augmentations to guide the learning of complex ones. In order to improve the computational efficiency of the proposed method, we use two attack steps (instead of 10) during training. By progressively increasing the magnitude of perturbations and performing smoothing in weight space, we show that it is indeed possible to improve the stability of training. Our contributions are listed below:
+
+- We analyze the reasons for the failure of strong data augmentations in adversarial training by viewing augmentation during training as a domain generalization problem, and further propose Diverse Augmentation based Joint Adversarial Training (DAJAT) to utilize data augmentations effectively in Adversarial training. The proposed approach can be integrated with many augmentations and adversarial training methods to obtain performance gains.
+- We propose and integrate DAJAT with an efficient 2-step defense strategy, Ascending Constraint Adversarial Training (ACAT) that uses linearly increasing $\varepsilon$ schedule, cosine learning rate and weight-space smoothing to prevent gradient masking and improve convergence.
+- We obtain improved robustness and large gains in standard accuracy on multiple datasets (CIFAR-10, CIFAR-100, ImageNette) and model architectures (RN-18, WRN-34-10). We obtain remarkable gains in a low data scenario (CIFAR-100, Imagenette) where data augmentations are most effective. On CIFAR-100, we outperform all existing methods on the RobustBench leaderboard [7] with the same model architecture.
+
+# 2 Related Works
+
+We discuss various existing strategies for improving the Adversarial robustness of Deep Networks.
+
+Adversarial Training (AT): Goodfellow et al. [14] proposed FGSM-AT where single-step adversarial samples were used for training. However, these models were susceptible to gradient masking [30], where the local loss landscape becomes convoluted leading to the generation of weaker single-step
+
+attacks during training. This leads to a false sense of security against single-step attacks, while the models are still susceptible to stronger multi-step attacks such as PGD [27]. PGD-AT [27, 34] used multi-step attacks in a similar adversarial training formulation to obtain robust models that stood the test of time against several attacks [2, 6, 38]. TRADES [50] explicitly optimizes the trade-off between the accuracy on natural and adversarial examples by minimizing the cross-entropy loss on natural images along with the Kullback-Leibler (KL) divergence between the predictions of adversarial and clean images. In the proposed defense, we use the base loss from TRADES-AT [50].
+
+Several works have explored the use of auxiliary techniques in AT such as weight-space smoothing [22, 44], architectural changes [15, 47] and increasing the diversity of training data by using additional natural and synthetic data [35, 5, 15, 33]. Increasing the diversity of training data achieves significant performance gains since the sample complexity of adversarial training is known to be high [35].
+
+Augmentations in Adversarial Training: While data augmentations such as contrast, sharpness and brightness adjustments are known to improve performance in the standard training regime, they have not led to substantial gains in adversarial training. AutoAugment [8] uses Proximal Policy Optimization to find the set of policies that can yield optimal performance on a given dataset. Contrary to prior works [34, 15], we show that the policies that are optimized for standard training indeed yield a boost in performance of adversarial training as well, when used in the proposed training framework.
+
+In a recent work, Rebuffi et al. [33] show that it is possible to obtain substantial gains in robust accuracy by using spatial composition based augmentations such as CutMix [48] and CutOut [11] that preserve low-level features of the image. Cutmix replaces part of an image with another and also combines the output softmax vectors in the same ratio, while CutOut blanks out a random area of an image. The authors hypothesize that the augmentations used in Adversarial training need to preserve low-level features, which severely limits the possibilities for mitigating the large sample complexity in adversarial training. We show that by using the proposed approach DAJAT, it is indeed possible to use augmentations such as color jitter, contrast, sharpness and brightness adjustments that significantly change the low level statistics of images (Ref: Table-6).
+
+# 3 Preliminaries: Notation and Threat Model
+
+We consider the Adversarial Robustness of DNN based image classifiers. An input image is denoted as $x \in \mathcal{X}$ and the corresponding ground truth label as $y \in [0,1]$ . We denote a simple transformation of $x$ obtained using Pad, Crop and Horizontal flip (Pad+Crop+HFlip, referred to as Base augmentations) by $x_{\mathrm{base}}$ and other transformations of $x$ by the respective subscript. For example, $x_{\mathrm{auto}}$ refers to the image $x$ being transformed by AutoAugment (AA) [8] followed by the base augmentations. The function mapping of the classifier $C$ from input space $\mathcal{X}$ to the softmax vectors is denoted using $f_{\theta}(.)$ , where $\theta$ denotes the network parameters. Adversarial examples corresponding to the images $x$ , $x_{\mathrm{base}}$ and $x_{\mathrm{auto}}$ are denoted using $\tilde{x}$ , $\tilde{x}_{\mathrm{base}}$ and $\tilde{x}_{\mathrm{auto}}$ respectively. We consider the $\ell_{\infty}$ norm based threat model, where $\tilde{x}$ is a valid perturbation within $\varepsilon$ if it belongs to the set $A_{\varepsilon}(x) = \{\tilde{x} : ||\tilde{x} - x||_{\infty} \leq \varepsilon\}$ .
+
+# 4 Motivation: Role of Augmentations in Neural Network Training
+
+In this section, we first explore the contrasting factors that influence the training of neural networks when data is augmented (Sec.4.1), and further delve into the specifics of adversarial training which make it challenging to obtain gains using complex data augmentations (Sec.4.2).
+
+# 4.1 Impact of Augmentations in Neural Network Training
+
+Conjecture-1: We hypothesize that the role of data augmentations in the training of Neural Networks is influenced by the following contrasting factors:
+
+(i) Reduced overfitting due to an increase in diversity of the augmented dataset, leading to better generalization of the network to the test set.
+(ii) Larger domain shift between the augmented data distribution and the test data distribution, leading to a drop in performance on the test set.
+(iii) Capacity of the Neural Network in being able to generalize well to the augmented data distribution and the unaugmented data distribution for the given task.
+
+Justification: The training of Neural Networks using augmented data can be considered as a problem of domain generalization, where the network is trained on a source domain (augmented data) and is
+
+Table 1: Impact of augmentations: Performance (%) of ACAT models on Base augmentations and AutoAugment (Auto). Clean and robust accuracy against GAMA attack [38] are reported. The use of AutoAugment results in $\sim 1.5 - 2\%$ drop in robust accuracy.
+
+| Model | Test: | No Aug | AutoAugment |
| Train ↓ | Clean | Robust | Clean | Robust |
| ResNet-18 | Base | 82.41 | 50.00 | 63.79 | 37.07 |
| Auto | 82.54 | 48.11 | 76.40 | 43.22 |
| WideResNet-34-10 | Base | 86.71 | 55.58 | 68.24 | 40.83 |
| Auto | 86.80 | 53.99 | 82.64 | 48.98 |
+
+
+Figure 2: Comparison of BN layer statistics for a WRN-34-10 model trained on CIFAR-10 using DAJAT. BN layers of the Base augmentations (Pad+Crop,H-Flip) are compared with those of AutoAugment. Initial layer (L3) parameters are diverse, while those of deeper layers (L25) are similar.
+
+expected to generalize to a target domain (test data). We use the theoretical formulation by Ben-David et al. [3] shown below to justify the respective claims in Conjecture-1:
+
+$$
+\epsilon_ {t} (f) \leq \epsilon_ {s} (f) + \frac {1}{2} d _ {\mathcal {F} \Delta \mathcal {F}} (s, t) + \lambda \tag {1}
+$$
+
+(i) The use of a more diverse or larger source dataset reduces overfitting, improving the performance of the network on the source distribution. From Eq.1, expected error on the target distribution $\epsilon_{t}$ (test set in this case) is upper bounded by the expected error on the source distribution $\epsilon_{s}$ (augmented dataset) along with other terms. Therefore, improved performance on the augmented distribution can improve the performance on the test set as well.
+(ii) The expected error on the target distribution $\epsilon_{t}$ is upper bounded by the distribution shift between the source and target distributions $\frac{1}{2} d_{\mathcal{F}\Delta \mathcal{F}}(s,t)$ along with other terms. Therefore, a larger domain shift between the augmented and test data distributions can indeed limit the performance gains on the test set.
+(iii) The constant $\lambda$ in Eq.1 measures the risk of the optimal joint classifier: $\lambda = \min_{f\in \mathcal{F}}\epsilon_s(f) + \epsilon_t(f)$ . Neural Networks with a higher capacity can minimize the expected risk on the source set $\epsilon_{s}$ and the risk of the optimal joint classifier effectively. Therefore, capacity of the Neural Network and complexity of the task influence the gains that can be obtained using augmentations.
+
+# 4.2 Analysing the role of Augmentations in Adversarial Training
+
+We analyse the trade-off between the factors described in Conjecture-1 for adversarial training when compared to standard ERM training. In addition to the goal of improving accuracy on clean samples, adversarial training aims to achieve local smoothness of the loss landscape as well. Hence, the complexity of Adversarial Training is higher than that of standard ERM training, making it important to use larger model capacities to obtain gains using data augmentations (based on Conjecture-1 (iii)). This justifies the gains obtained by Rebuffi et al. [33] on the WRN-70-16 architecture by using CutMix based augmentations (2.9% higher robust accuracy and 1.23% higher clean accuracy). The same method does not obtain significant gains on smaller architectures such as ResNet-18 where a 1.76% boost in robust accuracy is accompanied by a 2.55% drop in clean accuracy.
+
+Secondly, while the distribution shift between augmented data and test data $(\frac{1}{2} d_{\mathcal{F}\Delta \mathcal{F}}(s,t))$ may be sufficiently low for natural images leading to improved generalization to test set (Conjecture-1(i,ii)), the same may not be true for adversarial images. There is a large difference between the augmented data and test data in pixel space, although they may be similar in feature space. Since adversarial attacks perturb images in pixel space, the distribution shift between the corresponding perturbations widens further as shown in Fig.3-5 of the Appendix (Details in Appendix-B). Based on Conjecture1(ii), unless this difference is accounted for, complex augmentations cannot improve the performance of adversarial training. This trend has also been observed empirically by Rebuffi et al. [33], where they conclude that augmentations designed for robustness need to preserve low-level features.
+
+We present the performance of Adversarial Training by using either Base augmentations (Pad+Crop, Flip) or AutoAugment [8] during training and inference on the CIFAR-10 dataset using ResNet-18 and WideResNet-34-10 architectures in Table-1. Firstly, we note that by using AutoAugment during training alone, robust accuracy on the test set drops by $\sim 1.5 - 2\%$ which is as observed in prior work [15]. Secondly, the clean and robust accuracy drop by $\sim 6.5\%$ when augmented images are
+
+used for both training and testing, highlighting the complexity of the learning task. We present additional results by training without any augmentation, and by training using a combination of both augmentations in every minibatch in Table-9 of the Appendix. The use of Base Augmentations alone (Pad+Crop+HFlip) still gives the best overall performance on the unaugmented test set.
+
+# 5 Proposed Method
+
+# 5.1 Background
+
+We briefly discuss the TRADES-AWP defense [50, 44], which is the base algorithm used in DAJAT.
+
+$$
+\mathcal {L} _ {\mathrm {A W P}} = \max _ {\hat {\theta} \in \mathcal {M} (\theta)} \frac {1}{N} \sum_ {i = 1} ^ {N} \mathcal {L} _ {\mathrm {C E}} \left(f _ {\theta + \hat {\theta}} \left(x _ {i}\right), y _ {i}\right) + \beta \cdot \max _ {\tilde {x} _ {i} \in \mathcal {A} _ {\varepsilon} \left(x _ {i}\right)} \mathrm {K L} \left(f _ {\theta + \hat {\theta}} \left(x _ {i}\right) | | f _ {\theta + \hat {\theta}} \left(\tilde {x} _ {i}\right)\right) \tag {2}
+$$
+
+Firstly, an adversarial attack is generated by maximizing the KL divergence between the softmax predictions of the clean and adversarial examples iteratively for 10 attack steps. An Adversarial Weight Perturbation (AWP) step additionally perturbs the weights of the model to maximize the overall loss in weight-space. The weight perturbations are constrained in the feasible region $\mathcal{M}(\theta)$ such that for a given layer $l$ , $||\hat{\theta}_l|| \leq \gamma \cdot ||\theta_l||$ . The overall training loss is a combination of Cross-entropy loss on clean samples and the KL divergence term. The latter is weighted by a factor $\beta$ that controls the robustness-accuracy trade-off. Training the model using Adversarial Weight Perturbations leads to smoothing of loss surface in the weight space, resulting in better generalization [44, 40].
+
+# 5.2 Diverse Augmentation based Joint Adversarial Training (DAJAT)
+
+As discussed in Section-4, the use of augmentations in training can be viewed as a problem of domain generalization, where performance on the source distribution or augmented dataset is crucial towards improving the performance on the target distribution or test set. Since adversarial training is inherently challenging, for limited model capacity, it is difficult to obtain good performance on the training data that is transformed using complex augmentations. Moreover, the large distribution shift between augmented data and test data, specifically with respect to low-level statistics, results in poor generalization of robust accuracy to the test set.
+
+To mitigate these challenges, we propose the combined use of simple and complex augmentations during training, so that the model can benefit from the diversity introduced by complex augmentations, while also specializing on the original data distribution that is similar to the simple augmentations. We propose to use separate batch normalization layers for simple and complex augmentations, so as to offset the shift in distribution between the two kinds of augmentations. In our main approach, we propose to use Pad and Crop followed by Horizontal Flip (Pad+Crop+HFlip) as the Simple augmentations, and Autoaugment followed by Pad+Crop+HFlip as the complex augmentations. We justify the choice of this augmentation pipeline in Appendix-B.3.
+
+Motivated by AugMix [18], we additionally minimize the Jenson-Shannon (JS) divergence between the softmax outputs of different augmentations, so as to allow the simple augmentations to guide the learning of complex ones. We present the training loss $\mathcal{L}_{\mathrm{DAJAT}}$ of the proposed method, Diverse Augmentation based Joint Adversarial Training (DAJAT) below in Eq.5:
+
+$$
+\begin{array}{l} \mathcal {L} _ {\mathrm {T R}} (\theta , x, y) = \mathcal {L} _ {\mathrm {C E}} \left(f _ {\theta} (x), y\right) + \beta \cdot \max _ {\tilde {x} \in \mathcal {A} _ {\varepsilon} (x)} \operatorname {K L} \left(f _ {\theta} (x) \| f _ {\theta} (\tilde {x})\right) (3) \\ \tilde {\theta} = \underset {\hat {\theta} \in \mathcal {M} (\theta)} {\operatorname {a r g m a x}} \frac {1}{N} \sum_ {i = 1} ^ {N} \mathcal {L} _ {\mathrm {T R}} \left(\theta + \hat {\theta}, x _ {i, \text {b a s e}}, y _ {i}\right) (4) \\ \end{array}
+$$
+
+$$
+\begin{array}{l} \mathcal {L} _ {\mathrm {D A J A T}} = \frac {1}{T + 1} \cdot \frac {1}{N} \sum_ {i = 1} ^ {N} \left\{\mathcal {L} _ {\mathrm {T R}} \left(\theta + \tilde {\theta}, x _ {i, \text {b a s e}}, y _ {i}\right) + \sum_ {t = 1} ^ {T} \mathcal {L} _ {\mathrm {T R}} \left(\theta + \tilde {\theta}, x _ {i, \text {a u t o (t)}}, y _ {i}\right) \right\} + \\ \frac {1}{N} \sum_ {i = 1} ^ {N} \operatorname {J S D} \left(f _ {\theta + \tilde {\theta}} \left(x _ {i, \text {b a s e}}\right), f _ {\theta + \tilde {\theta}} \left(x _ {i, \text {a u t o (1)}}\right), \dots , f _ {\theta + \tilde {\theta}} \left(x _ {i, \text {a u t o (T)}}\right)\right) \tag {5} \\ \end{array}
+$$
+
+Adversarial attacks are generated individually for each augmentation by maximizing the respective KL divergence term of the TRADES loss shown in Eq.3. To improve training efficiency, we compute $\tilde{x}$ using two attack steps with a step-size of $\varepsilon$ . We use a combination of a linearly increasing schedule
+
+of $\varepsilon$ , cosine learning rate schedule and model weight-averaging [22] to improve the stability and performance of adversarial training (Details in Sec.5.4). The DAJAT loss (Eq.5) is a combination of the TRADES 2-step loss on each of the augmentations $x_{\mathrm{base}}$ and $x_{\mathrm{auto(t)}}$ , along with an adversarial weight perturbation step on the loss corresponding to the base augmentations alone to reduce compute. For every batch normalization layer, two sets of running statistics and affine parameters are maintained and used for simple and complex augmentations respectively (Ref: Algorithm-1 in the Appendix).
+
+While we use AutoAugment in our main approach, we show in Table-6 that the proposed approach works well with other augmentations as well. The role of the base (primary) augmentations is primarily to learn the batch normalization layers that would be used during inference time, and to provide better supervision for the training of complex augmentations using the JS divergence term. The role of the complex (secondary) augmentations is to enhance the diversity of the training dataset. Therefore we use a single primary augmentation and multiple instances of the secondary augmentation. We find that the gains in performance saturate with the addition of more instances of secondary augmentation, and therefore recommend the use of a single base augmentation and two instances of secondary augmentation for the best performance-accuracy trade-off. We note from Table-2 and Appendix-F.6 that in this setting, the computational efficiency of the proposed method is better than the TRADES-AWP [50, 44] defense, while achieving considerable performance gains.
+
+# 5.3 Split Batch Normalization Layers for Different Augmentations
+
+A Batch Normalization (BN) layer [21] is implemented as follows on a given feature map $g(x_{i})$ of an input image $x_{i}$ : $\hat{g}(x_{i}) = \frac{g(x_{i}) - \mu}{\sigma} \cdot \gamma + \beta$ . Here, $\mu$ and $\sigma$ denote the mean and standard deviation of the current mini-batch during training. During inference, these are set to the running mean and variance computed during training. $\gamma$ and $\beta$ constitute parameters of the network that are trained.
+
+Prior works use separate batch normalization layers to improve the performance of standard [46, 43, 28] and adversarial training [45, 42], in both supervised [46, 43, 28, 45, 42] and self-supervised settings [23, 12]. The proposed defense DAJAT uses separate batch normalization layers for simple and complex augmentations as discussed in the previous section. We do not use separate batch normalization for clean and adversarial images here.
+
+In DAJAT, we maintain two sets of BN statistics $\mu$ and $\sigma$ , and two sets of affine parameters, $\beta$ and $\gamma$ for every BN layer. We plot the cosine similarity between the BN layers corresponding to Base augmentations and AutoAugment across different layers on a WideResNet-34-10 model trained using DAJAT on CIFAR-10 in Fig.2. While the mean and variance are relatively more similar across most of the layers (0-30 in x-axis), we note significant differences in the $\gamma$ and $\beta$ values, specifically in the initial layers. We present a detailed study on the importance of having separate running statistics and affine parameters in Appendix-C, and conclude that our method works effectively by separating either the running statistics or affine parameters individually as well. However, it works best by using a combination of both (Ref: Table-5 of the Appendix). We further note that very small differences in running statistics (as seen in Fig.2 and Fig.7 of the Appendix) can also result in noteworthy performance gains. Finally, we find that the use of a single batch-norm layer for both augmentations degrades results significantly. Therefore, the use of different parameters for each augmentation type ensures that the function mapping differs for each augmentation, thereby effectively offsetting the large differences in low level statistics.
+
+# 5.4 Ascending Constraint Adversarial Training (ACAT)
+
+In this section, we discuss the methods incorporated to improve the training efficiency of DAJAT in greater detail. We apply these methods to the TRADES-AWP defense to independently analyse their impact, and term the proposed defense as Ascending Constraint Adversarial Training (ACAT). We aim to improve the training efficiency by reducing the number of attack steps of the base defense from 10 to 2. We use two attack steps for training since it is known to be more stable when compared to single-step adversarial training, while still being computationally efficient [39].
+
+As shown in Fig.3, naively reducing the number of attack steps to 2 in TRADES-AWP AT (Fixed constraint AT) causes a drop in clean and robust accuracy. While the drop is larger at higher training $\varepsilon$ , a drop in clean accuracy is seen at $\varepsilon = 8/255$ as well. Further, the large robustness gap between last and best epochs indicates that the training stability deteriorates towards the end of training. The instability of TRADES-AWP AT at $\varepsilon = 8/255$ is higher for larger model capacities (WideResNet-34-10) as discussed in Appendix-E.1.
+
+
+Figure 3: Comparison of ACAT (2-step) against TRADES-AWP 2-step baseline on CIFAR-10 with ResNet-18 architecture. (a) Clean accuracy, (b) Robust accuracy, and (c) Difference in Robust accuracy between the last and best epochs are reported. ACAT has better performance and stability even at large training $\varepsilon$ values. Robust Accuracy is reported against GAMA attack [38] on $\varepsilon = 8 / 255$ .
+
+Curriculum learning approaches [37, 4] have been used to improve robustness-accuracy trade-off in adversarial training. Prior works [36, 1] also show that training convergence at large $\varepsilon$ bounds can be improved by linearly increasing $\varepsilon$ as training progresses. Inspired by this, we propose to linearly increase $\varepsilon$ alongside a cosine learning rate schedule and weight-space smoothing for improving the stability and convergence of training (Ref: Algorithm-2 in the Appendix). The use of a lower learning rate at larger $\varepsilon$ improves training stability. As shown in Fig.3 and Table-7 of the Appendix, the performance and stability of the ACAT are significantly better when compared to the TRADES-AWP 2-step baseline, specifically at larger perturbation bounds and higher model capacities, at the same computational cost. The proposed defense maintains a good clean accuracy at all the training $\varepsilon$ values considered, and has $< 0.1\%$ robustness difference between last and best epochs.
+
+We thus show that even without modifying the training loss function it is possible to obtain significant gains in the stability and performance of 2-step adversarial training by using the proposed Ascending Constraint Adversarial Training. The proposed method can indeed improve the performance of other defenses such as GAT [38] and NuAT [39] as well, as shown in Table-8 of the Appendix.
+
+# Analysis of the proposed ACAT defense:
+
+Conjecture-2: We hypothesize that given a Neural Network $f_{\theta_{\varepsilon}}$ that minimizes the TRADES loss [50] within a maximum perturbation radius of $\varepsilon$ , and has sufficient smoothness in weight space within an $\ell_2$ radius $\psi$ around $\theta_{\varepsilon}$ , there exist $\varepsilon' > \varepsilon$ and a model $f_{\theta_{\varepsilon'}}$ where $||\theta_{\varepsilon'} - \theta_{\varepsilon}|| \leq \psi$ , such that $f_{\theta_{\varepsilon'}}$ has a lower TRADES loss within $\varepsilon'$ when compared to $f_{\theta_{\varepsilon}}$ .
+
+# Justification presented in Appendix-E.3.
+
+Based on Conjecture-2, by selecting a small enough learning rate $\eta$ and large enough $\psi$ , it is possible to move towards a better solution w.r.t. the TRADES loss at $\varepsilon'$ . The smoothness of loss surface further ensures that the gradients at $\varepsilon'$ are bounded with a low magnitude, preventing the onset of catastrophic overfitting, which is known to be associated with large magnitude gradients [26]. This motivates the proposed approach ACAT that effectively combines an increasing $\varepsilon$ schedule, cosine learning rate schedule that allows low learning rates at larger $\varepsilon$ values, and adversarial weight perturbation to ensure smoothness in the loss surface.
+
+Stability improvements obtained using ACAT: We consider an extreme case of using single-step attacks for training, to demonstrate the stability improvements obtained using ACAT. We consider a checkpoint obtained at $\varepsilon = 7.25 / 255$ while training using the proposed ACAT defense on CIFAR-10 dataset for a WideResNet-34-10 architecture. We use this model as an initialization and perform single-step adversarial training using the TRADES-AWP training objective at $\varepsilon = 7.5 / 255$ . Our goal here is to merely verify the stability of single-step training, although the use of single-step attack makes the robustness gains marginal. We present the clean accuracy and robust accuracy against PGD-20 attack using different values of Adversarial Weight Perturbation step size $\gamma$ in Fig.4(a). It is evident from the plots that for a fixed value of learning rate, increasing $\gamma$ can delay the onset of gradient masking, thereby improving the training stability. We also note marginal improvements in performance at higher $\gamma$ , due to the enhanced generalization. Therefore, weight-space smoothing indeed helps in improving the performance and stability of the proposed defense. We also note from Fig.4(b) that for a fixed value of $\gamma = 0.01$ , lower learning rate leads to better stability, therefore cosine schedule also helps in improving stability. We note that the value of gamma in relation to the learning rate is crucial. Therefore, in the proposed approach, we use a fixed value of $\gamma$ and reduce the learning rate using a cosine learning rate schedule to improve training stability as $\varepsilon$ increases.
+
+Table 2: CIFAR-10: Performance (%) of the proposed defenses ACAT and DAJAT when compared to the state-of-the-art. Robust evaluations are performed on GAMA [38] and AutoAttack [6]. Training time per epoch is reported by running each algorithm across 2 V100 GPUs.
+
+| Method | Steps | CIFAR-10, ResNet-18 | CIFAR-10, WideResNet-34 |
| Clean | GAMA | AutoAttack | Time/epoch (sec) | Clean | GAMA | AutoAttack |
| NuAT2-WA [39] | 2 | 82.21 | 50.97 | 50.75 | 109 | 86.32 | 55.08 | 54.76 |
| ACAT, Ours (Base, 2step) | 2 | 82.41 | 50.00 | 49.80 | 95 | 86.71 | 55.58 | 55.36 |
| PGD-AT [27] | 10 | 81.12 | 49.08 | 48.75 | 182 | 86.07 | 52.70 | 52.19 |
| TRADES-AWP [50, 44] | 10 | 80.47 | 50.06 | 49.87 | 228 | 85.19 | 55.87 | 55.69 |
| TRADES-AWP-WA | 10 | 80.41 | 49.89 | 49.67 | 228 | 85.10 | 56.07 | 55.87 |
| TRADES-AWP-WA (200 epochs) | 10 | 81.99 | 51.65 | 51.45 | 228 | 85.36 | 56.35 | 56.17 |
| DAJAT, Ours (Base, AA) | 2 + 2 | 85.60 | 51.27 | 51.06 | 160 | 87.87 | 56.97 | 56.68 |
| DAJAT, Ours (Base, 2*AA) | 2 + 4 | 85.99 | 51.71 | 51.48 | 219 | 88.90 | 57.22 | 56.96 |
| DAJAT, Ours (Base, 3*AA) | 2 + 6 | 86.67 | 51.81 | 51.56 | 280 | 88.64 | 57.34 | 57.05 |
+
+Table 3: CIFAR-100, ImageNette: Performance (%) of the proposed defense DAJAT when compared to the state-of-the-art. Robust evaluations are performed on GAMA [38] and AutoAttack [6].
+
+| Method | CIFAR-100, ResNet-18 | CIFAR-100, WideResNet-34 | IN-10, ResNet-18 |
| No. Steps | Clean | GAMA | AutoAttack | Clean | GAMA | AutoAttack | Clean | GAMA | AutoAttack | |
| TRADES-AWP [50, 44] | 10 | 58.81 | 25.51 | 25.30 | 62.41 | 29.70 | 29.54 | 82.73 | 57.52 | 57.40 | |
| TRADES-AWP-WA | 10 | 59.88 | 25.81 | 25.52 | 62.73 | 29.92 | 29.59 | 82.03 | 57.04 | 56.89 | |
| ACAT, Ours (Base, 2step) | 2 | 62.05 | 26.35 | 26.10 | 65.75 | 30.61 | 30.23 | 82.34 | 57.12 | 56.96 | |
| DAJAT, Ours (Base, AA) | 2 + 2 | 65.75 | 27.58 | 27.21 | 67.82 | 31.65 | 31.26 | 85.27 | 61.50 | 61.19 | |
| DAJAT, Ours (Base, 2*AA) | 2 + 4 | 66.84 | 27.61 | 27.32 | 68.74 | 31.58 | 31.30 | 86.01 | 62.52 | 62.31 | |
| DAJAT, Ours (Base, 3*AA) | 2 + 6 | 66.96 | 27.90 | 27.62 | 70.35 | 31.15 | 30.89 | 86.92 | 62.14 | 61.89 | |
+
+# 6 Experiments and Results
+
+# 6.1 State-of-the-art comparison
+
+We compare the performance of the proposed defenses ACAT and DAJAT against the 2-step and 10-step state-of-the-art defenses NuAT2-WA [38], TRADES-AWP [50, 44] and PGD-AT [27, 34] in Tables- 2, 3 and 4 on the CIFAR-10, CIFAR-100 [25] and ImageNette [20, 10]. We show in Table-16 of the Appendix that TRADES-AWP outperforms several other defenses in most settings, and the proposed defense DAJAT consistently outperforms all methods, showing substantial gains in performance. Further, since we integrate the proposed approach with TRADES-AWP, we primarily compare our approach with this across all datasets. We show in Table-17 of the Appendix that DAJAT can be integrated with other base defenses [1, 32] as well to obtain performance gains. We integrate model weight averaging with the TRADES-AWP defense (termed as TRADES-AWP-WA) as well for a fair comparison. We train all models for 110 epochs unless specified otherwise.
+
+ACAT: We compare the performance of the proposed 2-step defense ACAT with the existing state-of-the-art 2-step defense NuAT2-WA [39] in the first partition of Table-2. While we achieve similar performance on ResNet-18, we obtain improvements in both clean and robust accuracy on WideResNet-34-10. We show in Section-E.4 that our proposed defense ACAT can be integrated with the Nuclear Norm training objective as well to obtain improved results. The performance of the proposed ACAT defense is superior to PGD-AT (10-step) defense [34] as well. When compared to the TRADES-AWP (10-step) defense, ACAT achieves substantial gains in clean accuracy and improved robust accuracy on CIFAR-100 (Table-3), and improved clean accuracy at a slight drop in robust accuracy on CIFAR-10 (Table-2), at half the computational cost.
+
+DAJAT: We present three variants of the proposed defense DAJAT, by using one, two and three AutoAugment based augmentations for every image, denoted as (Base, AA), (Base, $2^{*}\mathrm{AA}$ ) and (Base, $3^{*}\mathrm{AA}$ ) respectively. From Tables-2 and 3, we note that even by using only a single augmentation (Base, AA), we obtain improved clean and robust accuracy when compared to most of the baselines considered across all datasets and models. By increasing the number of augmentations to 2 (Base, $2^{*}\mathrm{AA}$ ), we observe consistent gains in robust and clean accuracy in all cases. In this setting, the computational complexity of the proposed approach matches with that of TRADES-AWP [44] as shown in Table-2. With the setting (Base, $3^{*}\mathrm{AA}$ ), we further obtain marginal improvements in performance over (Base, $2^{*}\mathrm{AA}$ ). Overall, using the (Base, $2^{*}\mathrm{AA}$ ) approach, which has comparable time complexity as the TRADES-AWP 10-step defense, we obtain large gains ranging from $3.8\%$ to $7\%$ on clean accuracy and $\sim 1.8\%$ in robust accuracy against AutoAttack [6] across most settings. On the Imagenette dataset we obtain $4.2\%$ higher clean accuracy and $4.49\%$ higher robust accuracy, showing that augmentation strategies work best when the amount of training data is less when
+
+Table 4: Performance (%) of DAJAT using higher attack steps and 200 training epochs on CIFAR-10 and CIFAR-100. Evaluations are performed against AutoAttack [6] and Common Corruptions (CC) [17].
+
+| Dataset | Model | Method | Clean | AutoAttack | CC |
| CIFAR-10 | ResNet-18 | TRADES-AWP-WA | 81.99 | 51.45 | 72.64 |
| Ours (Base, 2*AA) | 85.71 | 52.50 | 76.13 |
| WRN-34-10 | TRADES-AWP-WA | 85.36 | 56.17 | 75.83 |
| Ours (Base, 2*AA) | 88.71 | 57.81 | 80.12 |
| CIFAR-100 | ResNet-18 | TRADES-AWP-WA | 59.11 | 25.97 | 47.95 |
| Ours (Base, 2*AA) | 65.45 | 27.69 | 54.85 |
| WRN-34-10 | TRADES-AWP-WA | 60.30 | 28.68 | 48.95 |
| Ours (Base, 2*AA) | 68.75 | 31.85 | 56.95 |
+
+
+Figure 4: Impact of (a) AWP step size $\gamma$ and (b) learning rate (LR) on stability of single-step TRADES-AWP training using $\varepsilon = 7.5 / 255$ on a model pretrained upto $\varepsilon = 7.25 / 255$ using ACAT. (a) For a fixed LR, increasing $\gamma$ improves training stability. (b) For a fixed value of $\gamma = 0.01$ , lower LR leads to better stability.
+
+
+
+compared to the complexity of the task. We observe a similar trend using smaller subsets of training data on CIFAR-10 as shown in Fig.8 of the Appendix.
+
+Scaling to higher attack steps, longer training and larger models: While the use of 2 attack steps helps in improving the training efficiency of DAJAT, we show that by using more attack steps and longer training epochs, we can indeed obtain further gains in performance. The varying $\varepsilon$ schedule in DAJAT allows the use of an increasing schedule in the number of steps as well, thereby limiting the overall cost associated with higher attack steps. We present results by increasing the number of attack steps from 2 to 5 uniformly every 50 epochs in Table-4. We obtain $\sim 3.5\%$ and $6 - 9\%$ higher clean accuracy, along with $1 - 1.6\%$ and $1.7 - 3.2\%$ gains in robust accuracy against AutoAttack on CIFAR-10 and CIFAR-100 respectively when compared to the TRADES-AWP-WA 200 epoch baseline. This achieves better robustness-accuracy trade-off when compared to all existing defenses that use the same model architecture on the RobustBench leaderboard [7]. On the CIFAR-100 RobustBench leaderboard, we outperform all existing methods using the same model architecture, w.r.t. both clean and robust accuracy, including the ones that use additional data, showing that data augmentations can be effectively used to overcome the large sample complexity of adversarial training. The use of diverse augmentations in DAJAT also improves the generalization of the model to Common Corruptions by $4\%$ and $8\%$ on CIFAR-10-C and CIFAR-100-C datasets [17] respectively as shown in Table-4. Further, we find that the performance gains obtained using DAJAT are higher on larger capacity models (Ref: Table-10 of the Appendix).
+
+Computational Efficiency: As shown in Appendix-F.6, the use of ACAT strategy in the proposed DAJAT defense enables us to achieve similar computational complexity as TRADES-AWP defense, while obtaining gains in performance. Using DAJAT, we achieve $10\%$ reduction in FLOPs (training) and training time, while obtaining $3.8 - 5.5\%$ higher clean accuracy and $1 - 1.6\%$ higher robust accuracy.
+
+# 6.2 Ablation experiments
+
+We present ablation experiments to highlight the significance of different components of the proposed approach in Table-5 on the CIFAR-10 dataset using ResNet-18 architecture. All experiments are run for 110 training epochs, except A7 which is run for 220 epochs. We show the importance of the JS divergence term in the proposed loss in the ablations A1-A6 of Table-5. Using the JS divergence term we obtain $\sim 1\%$ higher clean accuracy across (Base, AA), (Base, $2^{*}\mathrm{AA}$ ) and (Base, $3^{*}\mathrm{AA}$ ) settings of the proposed defense. For (Base, $2^{*}\mathrm{AA}$ ) and (Base, $3^{*}\mathrm{AA}$ ) we obtain marginal improvements in robust accuracy as well. From A7, A9 and A10, we find that the proposed JS divergence term helps even in the case where both augmentations of an image are generated using the same pipeline. Using two AutoAugment based transformations, we obtain $1.6\%$ higher clean accuracy when compared to the 220 epoch 2-step defense at a comparable computational cost. Comparing A9, A10 and A11, we note that the use of simple and complex augmentations indeed shows improvements over the case of using 2 complex or simple augmentations alone. The importance of split-batch norm in the proposed approach can be evidently seen by comparing A12 and A14. By using single batch norm (A12), robust accuracy drops by $8.24\%$ . Further, in this case if the JS term is also dropped, the robustness of the network is almost completely lost. This shows that using a single batch norm layer for diverse augmentations makes it harder for the network to converge. We also note that the JS divergence term indeed helps in improving the convergence of training in addition to improving performance. From Appendix-F.4, we note that the use of varying $\varepsilon$ schedule in DAJAT improves the stability of training resulting in large performance gains w.r.t. the use of fixed $\varepsilon$ , specifically at larger model capacities.
+
+Table 5: Ablation experiments performed on the CIFAR-10 dataset using ResNet-18 architecture. Robust Accuracy is reported against GAMA attack [38]
+
+| Method | # Steps | Clean | Robust | Method | # Steps | Clean | Robust |
| [A1] Ours (Base, AA), no JS div | 2 + 2 | 84.55 | 51.45 | [A8] Ours (Base, 2step) | 2 | 82.41 | 50.00 |
| [A2] Ours (Base, AA) | 2 + 2 | 85.60 | 51.27 | [A9] Ours (AA, AA) | 2 + 2 | 84.68 | 49.71 |
| [A3] Ours (Base, 2*AA), no JS div | 2 + 4 | 85.07 | 51.53 | [A10] Ours (Base, Base) | 2 + 2 | 83.93 | 49.88 |
| [A4] Ours (Base, 2*AA) | 2 + 4 | 85.99 | 51.71 | [A11] Ours (Base, AA) | 2 + 2 | 85.60 | 51.27 |
| [A5] Ours (Base, 3*AA), no JS div | 2 + 6 | 85.31 | 51.67 | [A12] Ours (Base, 3*AA) Single BN | 2 + 6 | 86.68 | 43.57 |
| [A6] Ours (Base, 3*AA) | 2 + 6 | 86.67 | 51.81 | [A13] Ours (Base, 3*AA) Single BN, no JS | 2 + 6 | 75.64 | 4.20 |
| [A7] Ours (Base, 2step), 220 epochs | 2 | 83.05 | 50.31 | [A14] Ours (Base, 3*AA) | 2 + 6 | 86.67 | 51.81 |
+
+Table 6: Impact of using other augmentations in DAJAT. Performance on CIFAR-10 dataset with ResNet-18 architecture is reported. Robust evaluations are done against GAMA attack [38]. ${}^{ \dagger }$ PreAct-ResNet18 with Swish activation is used [33, 31].
+
+| Augmentation | Augmentation | Base + Aug | Base + 2* (Aug) | Augmentation | Augmentation | Base + Aug | Base + 2* (Aug) |
| Clean | Robust | Clean | Robust | Clean | Robust | Clean | Robust | Clean | Robust | Clean | Robust |
| No Augmentation | 76.32 | 43.20 | 78.08 | 41.71 | 77.42 | 41.07 | Cutout [11] | 82.38 | 50.14 | 84.91 | 51.40 | 85.11 | 51.60 |
| Pad+Crop+H-Flip | 82.41 | 50.00 | 83.69 | 51.30 | 83.62 | 51.09 | Colour Jitter | 82.98 | 48.82 | 84.50 | 51.19 | 84.85 | 51.62 |
| AutoAugment [8] | 82.54 | 48.11 | 84.94 | 51.23 | 85.99 | 51.71 | Mixup [49] | 79.08 | 45.07 | 85.18 | 50.18 | 84.24 | 50.01 |
| Cutmix [48] | 79.03 | 41.57 | 82.33 | 50.90 | 81.64 | 49.50 | RandAugment [9] | 82.48 | 44.66 | 84.61 | 51.01 | 85.47 | 51.33 |
| \( Cutmix^† \)[33, 31] | 82.01 | 47.65 | 84.58 | 50.97 | 85.49 | 51.58 | Augmix [18] | 82.38 | 48.84 | 84.96 | 50.4 | 85.18 | 50.51 |
+
+# 6.3 Combining the proposed defense with other augmentations
+
+We explore combining the proposed defense DAJAT with other augmentations in Table-6, and present the impact of individual augmentations in AutoAugment in Table-4 of the Appendix. We do not use the JS divergence term for Cutmix and Mixup since they involve changes in the label space. Without using any augmentation in the training dataset, we obtain poor clean and robust accuracy, highlighting the importance of the simple augmentations. The proposed approach obtains good performance gains using AutoAugment [8], Color Jitter and CutOut [11] augmentations, highlighting that it can work well with pixel-level and spatial augmentations. In case of CutMix [48] and Mixup [49], since the base accuracy obtained by using the augmentation alone is itself very poor, combining them with the proposed approach does not yield competent results. However they are considerably better than naively using the augmentation. This shows that the proposed approach enables the use of a variety of augmentations without the need for careful selection. The use of Cutmix and Mixup in adversarial training are challenging since they involve changes in label space. We note that Rebuffi et al. [33] obtain considerable gains using Cutmix along with many other improvements. However, naively augmenting using CutMix leads to a considerably degraded performance. By incorporating some of the tricks reproduced by Rade et al. [31] we obtain improvements in the CutMix baseline and obtain further gains in the proposed method as well (Ref: Appendix-F.7, Table-15 of the Appendix).
+
+# 7 Conclusion
+
+Contrary to prior knowledge, we show that it is indeed possible to use common augmentation strategies that modify the low-level statistics of images to improve the performance of adversarial training. We propose a novel defense Diverse Augmentation based Joint Adversarial Training (DAJAT), that uses a combination of simple and complex augmentations with separate batch normalization layers to allow the network training to benefit from the diverse training data distribution obtained using complex augmentations, while also specializing on a distribution that is close to the test set. The use of JS divergence term between network predictions of different augmentations enables the joint learning across various augmentations. We improve the efficiency of the proposed defense by utilizing the proposed approach Ascending Constraint Adversarial Training (ACAT), that improves the stability and performance of TRADES 2-step adversarial training significantly by using a linearly increasing $\varepsilon$ schedule along with a cosine learning rate schedule and weight-space smoothing.
+
+Limitations: While we focus our work on how to use augmentations effectively in adversarial training, we do not focus on which augmentations are best suited for the same. We believe this work can open up further possibilities towards finding better data augmentations for adversarial training.
+
+# 8 Acknowledgments and Disclosure of Funding
+
+This work was supported by a research grant (CRG/2021/005925) from SERB, DST, Govt. of India. Sravanti Addepalli is supported by a Google PhD Fellowship in Machine Learning.
+
+# References
+
+[1] S. Addepalli, S. Jain, G. Sriramanan, and V. B. Radhakrishnan. Scaling adversarial training to large perturbation bounds. In The European Conference on Computer Vision (ECCV), 2022. 7, 8
+[2] A. Athalye, N. Carlini, and D. Wagner. Obfuscated gradients give a false sense of security: Circumventing defenses to adversarial examples. In International Conference on Machine Learning (ICML), 2018. 3
+[3] S. Ben-David, J. Blitzer, K. Crammer, A. Kulesza, F. Pereira, and J. W. Vaughan. A theory of learning from different domains. Machine learning, 79(1):151-175, 2010. 4
+[4] Q.-Z. Cai, C. Liu, and D. Song. Curriculum adversarial training. In Proceedings of the 27th International Joint Conference on Artificial Intelligence (IJCAI), 2018. 7
+[5] Y. Carmon, A. Raghunathan, L. Schmidt, J. C. Duchi, and P. S. Liang. Unlabeled data improves adversarial robustness. In Advances in Neural Information Processing Systems (NeurIPS), 2019. 1, 3
+[6] F. Croce and M. Hein. Reliable evaluation of adversarial robustness with an ensemble of diverse parameter-free attacks. In International Conference on Machine Learning (ICML), 2020. 3, 8, 9
+[7] F. Croce, M. Andriushchenko, V. Sehwag, E. Debenedetti, N. Flammarion, M. Chiang, P. Mittal, and M. Hein. Robustbench: a standardized adversarial robustness benchmark. In Thirty-fifth Conference on Neural Information Processing Systems Datasets and Benchmarks Track (Round 2), 2021. 2, 9
+[8] E. D. Cubuk, B. Zoph, D. Mane, V. Vasudevan, and Q. V. Le. Autoaugment: Learning augmentation strategies from data. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), June 2019. 2, 3, 4, 10
+[9] E. D. Cubuk, B. Zoph, J. Shlens, and Q. V. Le. Randaugment: Practical automated data augmentation with a reduced search space. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) Workshops, 2020. 2, 10
+[10] J. Deng, W. Dong, R. Socher, L.-J. Li, K. Li, and L. Fei-Fei. ImageNet: A Large-Scale Hierarchical Image Database. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2009. 8
+[11] T. DeVries and G. W. Taylor. Improved regularization of convolutional neural networks with cutout. arXiv preprint arXiv:1708.04552, 2017. 3, 10
+[12] L. Fan, S. Liu, P.-Y. Chen, G. Zhang, and C. Gan. When does contrastive learning preserve adversarial robustness from pretraining to finetuning? Advances in Neural Information Processing Systems (NeurIPS), 34, 2021. 6
+[13] I. Goodfellow, J. Pouget-Abadie, M. Mirza, B. Xu, D. Warde-Farley, S. Ozair, A. Courville, and Y. Bengio. Generative adversarial nets. Advances in neural information processing systems (NeurIPS), 27, 2014. 1
+[14] I. J. Goodfellow, J. Shlens, and C. Szegedy. Explaining and harnessing adversarial examples. In International Conference on Learning Representations (ICLR), 2015. 1, 2
+[15] S. Gowal, C. Qin, J. Uesato, T. Mann, and P. Kohli. Uncovering the limits of adversarial training against norm-bounded adversarial examples. arXiv preprint arXiv:2010.03593, 2020. 2, 3, 4
+[16] S. Gowal, S.-A. Rebuffi, O. Wiles, F. Stimberg, D. A. Calian, and T. A. Mann. Improving robustness using generated data. Advances in Neural Information Processing Systems (NeurIPS), 34, 2021. 1
+[17] D. Hendrycks and T. Dietterich. Benchmarking neural network robustness to common corruptions and perturbations. In International Conference on Learning Representations (ICLR), 2019. 9
+[18] D. Hendrycks*, N. Mu*, E. D. Cubuk, B. Zoph, J. Gilmer, and B. Lakshminarayanan. Augmix: A simple method to improve robustness and uncertainty under data shift. In International Conference on Learning Representations (ICLR), 2020. 5, 10
+[19] J. Ho, A. Jain, and P. Abbeel. Denoising diffusion probabilistic models. Advances in Neural Information Processing Systems (NeurIPS), 33, 2020. 1
+[20] J. Howard and S. Gugger. Fastai: a layered api for deep learning. Information, 11(2):108, 2020. 8
+[21] S. Ioffe and C. Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In Proceedings of the 32nd International Conference on Machine Learning (ICML), Proceedings of Machine Learning Research. PMLR, 2015. 6
+
+[22] P. Izmailov, D. Podoprikhin, T. Garipov, D. Vetrov, and A. G. Wilson. Averaging weights leads to wider optima and better generalization. arXiv preprint arXiv:1803.05407, 2018. 3, 6
+[23] Z. Jiang, T. Chen, T. Chen, and Z. Wang. Robust pre-training by adversarial contrastive learning. Advances in Neural Information Processing Systems (NeurIPS), 2020. 6
+[24] A. Krizhevsky, I. Sutskever, and G. E. Hinton. Imagenet classification with deep convolutional neural networks. Advances in neural information processing systems (NeurIPS), 2012. 2
+[25] A. Krizhevsky et al. Learning multiple layers of features from tiny images. 2009. 8
+[26] T. Li, Y. Wu, S. Chen, K. Fang, and X. Huang. Subspace adversarial training. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), 2022. 7
+[27] A. Madry, A. Makelov, L. Schmidt, T. Dimitris, and A. Vladu. Towards deep learning models resistant to adversarial attacks. In International Conference on Learning Representations (ICLR), 2018. 1, 3, 8
+[28] A. Merchant, B. Zoph, and E. D. Cubuk. Does data augmentation benefit from split batchnorms. ArXiv, abs/2010.07810, 2020. 6
+[29] T. Pang, X. Yang, Y. Dong, H. Su, and J. Zhu. Bag of tricks for adversarial training. International Conference on Learning Representations (ICLR), 2021. 1, 2
+[30] N. Papernot, P. McDaniel, I. Goodfellow, S. Jha, Z. B. Celik, and A. Swami. Practical black-box attacks against machine learning. In Proceedings of the ACM Asia Conference on Computer and Communications Security (ACM ASIACCS), 2017. 2
+[31] R. Rade. PyTorch implementation of uncovering the limits of adversarial training against norm-bounded adversarial examples, 2021. URL https://github.com/imrahulr/adversarial_robustness_pytorch.10
+[32] R. Rade and S.-M. Moosavi-Dezfooli. Reducing excessive margin to achieve a better accuracy vs. robustness trade-off. In International Conference on Learning Representations (ICLR), 2022. 8
+[33] S.-A. Rebuffi, S. Gowal, D. A. Calian, F. Stimberg, O. Wiles, and T. A. Mann. Data augmentation can improve robustness. Advances in Neural Information Processing Systems (NeurIPS), 34, 2021. 3, 4, 10
+[34] L. Rice, E. Wong, and J. Z. Kolter. Overfitting in adversarially robust deep learning. In International Conference on Machine Learning (ICML), 2020. 1, 2, 3, 8
+[35] L. Schmidt, S. Santurkar, D. Tsipras, K. Talwar, and A. Madry. Adversarially robust generalization requires more data. Advances in neural information processing systems (NeurIPS), 31, 2018. 1, 3
+[36] A. Shaeiri, R. Nobahari, and M. H. Rohban. Towards deep learning models resistant to large perturbations. arXiv preprint arXiv:2003.13370, 2020. 7
+[37] C. Sitawarin, S. Chakraborty, and D. A. Wagner. Improving adversarial robustness through progressive hardening. ArXiv, abs/2003.09347, 2020. 7
+[38] G. Sriramanan, S. Addepalli, A. Baburaj, and R. Venkatesh Babu. Guided Adversarial Attack for Evaluating and Enhancing Adversarial Defenses. In Advances in Neural Information Processing Systems (NeurIPS), 2020. 3, 4, 7, 8, 10
+[39] G. Sriramanan, S. Addepalli, A. Baburaj, and R. Venkatesh Babu. Towards Efficient and Effective Adversarial Training. In Advances in Neural Information Processing Systems (NeurIPS), 2021. 6, 7, 8
+[40] D. Stutz, M. Hein, and B. Schiele. Relating adversarially robust generalization to flat minima. In Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV), 2021. 2, 5
+[41] C. Szegedy, W. Zaremba, I. Sutskever, J. Bruna, D. Erhan, I. J. Goodfellow, and R. Fergus. Intriguing properties of neural networks. In International Conference on Learning Representations (ICLR), 2013. 1
+[42] H. Wang, T. Chen, S. Gui, T.-K. Hu, J. Liu, and Z. Wang. Once-for-all adversarial training: In-situ tradeoff between robustness and accuracy for free. In Advances in Neural Information Processing Systems (NeurIPS), 2020. 6
+[43] H. Wang, C. Xiao, J. Kossaifi, Z. Yu, A. Anandkumar, and Z. Wang. Augmax: Adversarial composition of random augmentations for robust training. In Advances in Neural Information Processing Systems (NeurIPS), 2021. 6
+
+[44] D. Wu, S.-T. Xia, and Y. Wang. Adversarial weight perturbation helps robust generalization. Advances in Neural Information Processing Systems (NeurIPS), 2020. 3, 5, 6, 8
+[45] C. Xie and A. Yuille. Intriguing properties of adversarial training at scale. In International Conference on Learning Representations (ICLR), 2020. 6
+[46] C. Xie, M. Tan, B. Gong, J. Wang, A. L. Yuille, and Q. V. Le. Adversarial examples improve image recognition. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), June 2020. 6
+[47] C. Xie, M. Tan, B. Gong, A. Yuille, and Q. V. Le. Smooth adversarial training. arXiv preprint arXiv:2006.14536, 2020. 3
+[48] S. Yun, D. Han, S. J. Oh, S. Chun, J. Choe, and Y. Yoo. Cutmix: Regularization strategy to train strong classifiers with localizable features. In Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV), 2019. 3, 10
+[49] H. Zhang, M. Cisse, Y. N. Dauphin, and D. Lopez-Paz. mixup: Beyond empirical risk minimization. In International Conference on Learning Representations (ICLR), 2018. 10
+[50] H. Zhang, Y. Yu, J. Jiao, E. Xing, L. El Ghaoui, and M. I. Jordan. Theoretically principled trade-off between robustness and accuracy. In International Conference on Machine Learning (ICML), 2019. 1, 3, 5, 6, 7, 8
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] Section-7
+(c) Did you discuss any potential negative societal impacts of your work? [N/A] There are no known negative societal impacts of our work.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] https://github.com/val-iisc/DAJAT.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] Appendix-F.2 and ReadMe file at https://github.com/val-iisc/DAJAT
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] Table-12 of the Appendix
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] Details on compute: Table-13 of the Appendix, Details on resources: Appendix-F.2
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] Appendix-F.1
+(b) Did you mention the license of the assets? [Yes] Appendix-F.1
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We share the code for the proposed approach at https://github.com/val-iisc/DAJAT
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A] We use only publicly released and open-sourced datasets and codes.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes] Appendix-F.1
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientandeffectiveaugmentationstrategyforadversarialtraining/images.zip b/efficientandeffectiveaugmentationstrategyforadversarialtraining/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..5563dc3020b4c7dfd41b9f19c44082f8fd3b83bd
--- /dev/null
+++ b/efficientandeffectiveaugmentationstrategyforadversarialtraining/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a28ca9d9a72a95206f499aeab3fbd99d456018e83faf5e8167f2d326e3470b2c
+size 455069
diff --git a/efficientandeffectiveaugmentationstrategyforadversarialtraining/layout.json b/efficientandeffectiveaugmentationstrategyforadversarialtraining/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..f73178031f492d8b130d5572618472bc53f46850
--- /dev/null
+++ b/efficientandeffectiveaugmentationstrategyforadversarialtraining/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:69b727b56c3a126e78b47b60a25fe0360c2e213673b8bdd3490d1ed94f405351
+size 444531
diff --git a/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/14db75ba-a677-4c75-8303-0f34c5edb247_content_list.json b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/14db75ba-a677-4c75-8303-0f34c5edb247_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..51a4f08cbb597bb8e1bcd3e15287b7e45af274fb
--- /dev/null
+++ b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/14db75ba-a677-4c75-8303-0f34c5edb247_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0ce2bc480022996732c16f6a774ef521381be102acefee5686676d9eeb90217a
+size 74379
diff --git a/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/14db75ba-a677-4c75-8303-0f34c5edb247_model.json b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/14db75ba-a677-4c75-8303-0f34c5edb247_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..7b13822ec5cd16512446928c899241aedc2cb40a
--- /dev/null
+++ b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/14db75ba-a677-4c75-8303-0f34c5edb247_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ebb5f85e26dd88054cf9f4db357cbd94eacef4873067e843b73bf6eea46081f0
+size 95154
diff --git a/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/14db75ba-a677-4c75-8303-0f34c5edb247_origin.pdf b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/14db75ba-a677-4c75-8303-0f34c5edb247_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..d40e061c64374acaa3cdb3747dd1229209f196fd
--- /dev/null
+++ b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/14db75ba-a677-4c75-8303-0f34c5edb247_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c4f5bba49750b71428dc40ae391c4ac8b08c0f6c8f4d9ea72675f82f46b60569
+size 1258895
diff --git a/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/full.md b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..f8ab3b0947499e4088da3147cf8c916fd34c0f3c
--- /dev/null
+++ b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/full.md
@@ -0,0 +1,287 @@
+# Efficient and Effective Multi-task Grouping via Meta Learning on Task Combinations
+
+Xiaozhuang Song*
+
+Southern University of Science and Technology
+
+shawnsxz97@gmail.com
+
+Shun Zheng
+
+Microsoft Research
+
+shun.zheng@microsoft.com
+
+Wei Cao
+
+Microsoft Research
+
+wei.cao@microsoft.com
+
+James J.Q. Yu
+
+Southern University of Science and Technology
+
+yujq3@sustech.edu.cn
+
+Jiang Bian
+
+Microsoft Research
+
+jiang.bian@microsoft.com
+
+# Abstract
+
+As a longstanding learning paradigm, multi-task learning has been widely applied into a variety of machine learning applications. Nonetheless, identifying which tasks should be learned together is still a challenging fundamental problem because the possible task combinations grow exponentially with the number of tasks, and existing solutions heavily relying on heuristics may probably lead to ineffective groupings with severe performance degradation. To bridge this gap, we develop a systematic multi-task grouping framework with a new meta-learning problem on task combinations, which is to predict the per-task performance gains of multi-task learning over single-task learning for any combination. Our underlying assumption is that no matter how large the space of task combinations is, the relationships between task combinations and performance gains lie in some low-dimensional manifolds and thus can be learnable. Accordingly, we develop a neural meta learner, MTG-Net, to capture these relationships, and design an active learning strategy to progressively select meta-training samples. In this way, even with limited meta samples, MTG-Net holds the potential to produce reasonable gain estimations on arbitrary task combinations. Extensive experiments on diversified multi-task scenarios demonstrate the efficiency and effectiveness of our method. Specifically, in a large-scale evaluation with 27 tasks, which produce over one hundred million task combinations, our method almost doubles the performance obtained by the existing best solution given roughly the same computational cost. Data and code are available at https://github.com/ShawnKS/MTG-Net.
+
+# 1 Introduction
+
+Multi-task learning (MTL), as a longstanding learning paradigm [37, 50], has been widely applied into a variety of machine learning applications, ranging from language understanding [11], visual recognition [33, 41], and robotic control [19] to drug discovery [36] and clinical therapeutics [17, 30]. The major motivation behind is to boost the performance of single-task learning (STL) by leveraging the additional supervision signals from other relevant tasks.
+
+Nevertheless, naively grouping multiple tasks together for MTL easily results in severe performance degradation in practice. Many recent studies acknowledged this negative-transfer phenomenon and speculated that the major reason lied in the competition and interference among incompatible tasks [39, 47, 15, 41, 14, 30, 2, 6]. To mitigate such negative-transfer effect, recent years have witnessed a few explorations on developing new optimization approaches [39, 25, 29, 48] or model architectures [27, 33, 28, 15]. But explicitly identifying a group of tasks that would benefit from training together still remains a challenging fundamental problem without adequate investigations [41, 14]. Thoroughly studying this multi-task grouping (MTG) problem not only advances core research over MTL aside from optimization or architecture developments but also facilitates various MTL scenarios that can benefit from learning auxiliary objectives [2, 6].
+
+However, identifying the best MTG solution is extremely challenging as it involves an exhaustive search over the whole space of task combinations, each of which corresponds to a whole procedure of model training and evaluation on its specific MTL objective. The cost of such an exhaustive search grows exponentially with the number of tasks and thus can be prohibitively expensive [6, 41, 14].
+
+To reduce this prohibitive computational cost, most recent efforts [41, 14] relied on the assumption of high-order approximations (HOA), meaning high-order performance gains can be estimated from corresponding pairwise gains by averaging, where the performance gain denotes the improvement of MTL over STL for a specific task. For instance, considering the group composed of tasks $\{\mathrm{A},\mathrm{B},\mathrm{C}\}$ , they assumed that when learning with the joint objective of this group, the performance gain for A can be estimated by the average of associated pairwise gains for A, which were independently obtained by learning with $\{\mathrm{A},\mathrm{B}\}$ and $\{\mathrm{A},\mathrm{C}\}$ . Under the HOA assumption, they only need to collect the transferring gains for all pairwise combinations, of which the number is only quadratically dependent on the number of tasks. While substantially reducing computational requirements, the HOA assumption also results in wildly inaccurate estimations when there exist non-linear relationships between high-order gains and corresponding pairwise gains. As a result, such untrustworthy estimations can significantly hinder the final performance of searching for the optimal grouping option.
+
+To pursue more accurate estimations of various high-order performance gains under affordable computational cost, we develop a systematic MTG framework with a new meta-learning problem on task combinations. To be specific, we divide all task combinations into two parts: one with a small number of combinations for meta training and the other with all the rest combinations for meta testing. Here the meta input is a specific task combination, and the meta objective is to predict the per-task performance gains (the meta label) for this combination. The underlying assumption of this meta-learning formulation is that although the number of task combinations grow exponentially with the number of tasks, the relationships between task combinations and performance gains lie in some low-dimensional manifolds and thus can be learnable. Following this formulation, we build a dedicated neural network, MTG-Net, as the meta learner, and further develop an active learning [35] strategy to progressively construct the meta-training set. With this strategy, we can largely improve the effectiveness of MTG-Net with only a small number of meta-training samples. After the meta-training stage, we leverage the gain predictions of MTG-Net on all task combinations to guide the final grouping selection. Extensive experiments on diversified multi-task scenarios, including vision, energy, and healthcare, demonstrate the efficiency and the effectiveness of our method. Moreover, we also visualize various latent structures discovered by MTG-Net, which empirically validate the practicability of our assumption.
+
+In summary, our contributions include:
+
+- To our best knowledge, this paper is the first effort to formulate a meta-learning problem for MTG and thus enable an efficient exploration of the exponentially growing space of task combinations, which was believed to be prohibitively challenging [41, 30, 2, 6].
+- We build a neural meta learner, MTG-Net, that can capture the relationships between task combinations and performance gains effectively.
+- We develop an active learning strategy to progressively select the most useful meta-training samples for efficient training of MTG-Net.
+- We conduct extensive experiments across diversified multi-task scenarios. Specifically, in a large-scale evaluation (27 tasks) with over one hundred million task combinations, our method almost doubles the performance obtained by the existing solution.
+
+# 2 Related Work
+
+MTG The classic assumption of MTL in statistical learning was that putting related tasks into joint learning benefited from the inductive bias encouraging cross-task information sharing [8, 9, 7, 3, 5]. However, when this assumption of relatedness did not hold, the resulting negative-transfer effects can cause significant performance degradation. Thus the further research investigated the problem of simultaneously determining with which tasks each task should share while carrying over classical cross-task sharing [20, 22]. Nevertheless, these early MTL studies can hardly be adapted to modern deep neural networks [24] due to certain prohibitive assumptions [14]. As mentioned by [41, 14], identifying proper task groupings for deep neural networks conventionally required either computationally intensive cross-validation procedures or the human knowledge that is not always applicable to machine learning. The early attempt [41] on more general and systematic MTG for deep neural networks formalized a standard workflow: 1) collecting the transferring gains (or gain predictions) for all $2^{N} - 1$ task combinations, and then 2) conducting a brute-force search for the best grouping option given a specific budget, such as the maximal number of groups. The latter step is a deterministic searching procedure, but the former step is rather challenging because the optimal solution requires $2^{N} - 1$ times MTL training and evaluation, which can be prohibitively expensive when $N$ increases. Thus [41] further proposed the HOA approximation to reduce the computational complexity from exponential into quadratic: $\binom{N}{2}$ times MTL on pairwise task combinations. Subsequently, [14] improved the efficiency of [41] by substituting $\binom{N}{2}$ times pairwise MTL procedures with a single run, in which the computation complexity is only linearly dependent on $N$ due to maintaining and updating a task affinity matrix on the fly per each gradient updating. This further approximation, named as task affinity grouping (TAG) in [14], traded the accuracy in estimating pairwise MTL gains for efficiency, which may result in more error propagation from pairwise to higher-order. Different from all these HOA-based methods, this paper formulates a systematic meta-learning problem to estimate the transferring gains and builds an effective meta model to enable more accurate and robust generalization to massive high-order combinations.
+
+Other Research on MTL & Meta Learning & Task Embedding Recent years witnessed plenty of explorations on MTL from other aspects, such as multi-objective optimization [39, 25, 29, 48], neural architecture search [28, 26, 16, 15, 42], and soft-sharing mechanisms [13, 33, 27]. While these studies have made remarkable progresses to improve MTL under a predefined task combination, the focus of this paper lies in explicitly determining with which tasks to share. Besides, as pointed by [37, 14], these two paradigms are complementary to each other and can contribute to performance improvements jointly. Moreover, our work falls into the paradigm of meta learning [43, 21, 4, 34, 40]. But different from traditional meta-learning studies, which primarily focused on the fast adaptation across tasks in few-shot scenarios, our meta objective is to estimate the performance gains for different task combinations. To fulfill this objective, we develop a meta network that treats a task combination as a set of task tokens and transforms them into task embeddings to learn their interactions. Meanwhile, we also note some existing studies leveraged a similar idea of learning task embeddings but for different purposes, such as inferring task similarities [1], estimating treatment effects [38], facilitating few-shot learning [10] or reinforcement learning [23], etc.
+
+# 3 Meta Learning for Multi-task Grouping
+
+In this section, we elaborate on how our meta learning framework works for MTG. First, in Section 3.1, we establish the basic notations and briefly introduce some crucial steps of MTG for better understanding. Then we formulate our meta learning problem on task combinations in Section 3.2. Next, we introduce the details of MTG-Net and the accompanied active learning strategy in Sections 3.3 and 3.4, respectively. Figure 1 gives an overview of our framework.
+
+# 3.1 Preliminaries
+
+Notations We adopt the following notations throughout this paper. $N$ is the number of learning tasks in total. $\mathcal{T} = \{T_1,T_2,\dots ,T_N\}$ is the universal set of all $N$ tasks, where $T_{j}$ denotes the $j$ -th task, and we have $|\mathcal{T}| = N$ . $\mathcal{C} = \{C_1,C_2,\dots ,C_{2^N -1}\}$ is the universal set of all $2^{N} - 1$ combinations, which contains $\binom{N}{1}$ combinations containing only one task, $\binom{N}{2}$ combinations containing exact two tasks, $\binom{N}{3}$ three-task combinations, etc. $C_i = [t_1^i,t_2^i,\dots ,t_{|C_i|}^i ]$ denotes the $i$ -th task combination, where
+
+
+Figure 1: An overview of our meta learning framework for multi-task grouping
+
+
+
+$t_j^i\in \mathcal{T}$ denotes the $j$ -th task in this combination. $\mathcal{Y} = \left\{Y_1,Y_2,\dots ,Y_{2^N -1}\right\}$ is the universal set of all transferring gains corresponding to $\mathcal{C}$ . $Y_{i} = \left[y_{1}^{i},y_{2}^{i},\dots ,y_{|C_{i}|}^{i}\right]$ includes all per-task transferring gains for task combination $C_i$ , where $y_j^i$ denotes the gain of conducting MTL on task combination $C_i$ over performing STL for task $t_j^i$ , and we have $|Y_{i}| = |C_{i}|$ . $\mathcal{C}^{train}$ is the set of task combinations for meta training, and $\mathcal{V}^{train}$ denotes the set of corresponding transferring gains. $\mathcal{C}^{test}$ is the set of task combinations for meta testing, and $\mathcal{V}^{test}$ also includes corresponding transferring gains. $B$ denotes the budget in grouping selection, which is the maximal number of selected task combinations.
+
+The MTL Procedure Given task combination $C_i$ , we define its MTL procedure as training with the joint objective of $C_i$ and evaluating on the validation set for each task in $C_i$ to collect per-task performance as an indication of generalization. In accordance with [41, 14], we adopt a widely used hard-sharing architecture for MTL, in which there is a single encoder to obtain shared representations followed by separate decoders for specific tasks. Moreover, we retain the same split of train, validation, and test sets for each MTL procedure and fix the optimization algorithm as well as other hyperparameters. In this way, we can attribute the variations of generalization performance for a specific task largely to the different MTL objectives of various task combinations.
+
+Transferring Gain Here we make more clarifications on collecting transferring gain $y_{j}^{i}$ for task $t_{j}^{i}$ by performing MTL on combination $C_i$ . First, we conduct the aforementioned MTL procedure to collect the generalization performance on the validation set for task $t_{j}^{i}$ in $C_i$ . Then, we define the transferring gain of conducting MTL on $C_i$ for $t_{j}^{i}$ as the improvement of the performance of MTL over the base performance of STL for $t_{j}^{i}$ . In practice, we can instantiate this improvement in different ways, such as the reduction of loss, the improvement in accuracy, etc.
+
+Grouping Selection Once obtaining all transferring gains, we can select the optimal groupings that not only possess the best overall performance but also meet some practical considerations, such as inference latency. This selection procedure is in essence a constrained searching problem, which is to select a group of task combinations covering all $N$ tasks to maximize the overall transferring gain (the average of per-task gain) while ensuring the number of groups does not exceed a given budget $(B)$ . As noted by [41, 14], this problem is NP-hard in general. A solution of recursive searching has the computational complexity of $O(2^{N \cdot B})$ . In our experiments, when $N$ is small (e.g., 5 vision tasks), we follow [41, 14] to use the branch-and-bound-like algorithm to search for the optimal groupings. While for large $N$ and $B$ (e.g., 27 medical tasks), the exact search becomes prohibitively expensive. In this case, we approximately select near-optimal groupings via a beam-search approach with polynomial complexity, which is attached in the appendix.
+
+# 3.2 Meta Learning on Task Combinations
+
+Different from all existing brute-force or heuristic approaches, we formulate a new meta-learning problem on task combinations as a more systematic framework for the estimations of transferring gains. As mentioned in preliminaries, a predefined configuration of the MTL procedure implies that the variations in transferring gains $(Y_{i})$ can be largely attributed to the MTL objectives of different task combinations $(C_i)$ . Therefore, we assume there is an underlying mapping $\mathcal{F}$ to determine the
+
+transferring gains given a specific task combination: $Y_{i} = \mathcal{F}(C_{i})$ , for $C_i\in \mathcal{C}$ . Furthermore, this view stimulates us to design a learning process to obtain a good approximation $\mathcal{F}^*$ to the oracle function $\mathcal{F}$ with limited meta samples from $\mathcal{C}$ . The underlying assumption of the learnability with limited meta samples is that the relationships between task combinations and performance gains lie in some low-dimensional manifolds no matter how large the space of task combinations is. In our experiments, we empirically validate the practicability of this assumption.
+
+To be specific, we divide the whole set $\mathcal{C}$ into two parts: one part $\mathcal{C}^{train}$ for meta training and the other $\mathcal{C}^{test}$ for meta testing. For every combination in $\mathcal{C}^{train}$ , we conduct an MTL procedure and collect corresponding transferring gains $(\hat{\mathcal{V}}^{train})$ to learn a surrogate function $\mathcal{F}^*$ . While for all combinations in $\mathcal{C}^{test}$ , we directly apply $\mathcal{F}^*$ to produce estimated transferring gains, the set of which is denoted as $\hat{\mathcal{V}}^{test}$ . Accordingly, we summarize the whole meta-learning procedure as
+
+$$
+\mathcal {F} ^ {*} = \operatorname {M e t a - T r a i n} \left(\mathcal {C} ^ {t r a i n}, \mathcal {Y} ^ {t r a i n}\right), \quad \hat {\mathcal {Y}} ^ {t e s t} = \operatorname {M e t a - T e s t} \left(\mathcal {C} ^ {t e s t}, \mathcal {F} ^ {*}\right). \tag {1}
+$$
+
+This meta-learning perspective provides an explicit trade-off between efficiency and effectiveness for MTG. On the one hand, as the size of $\mathcal{C}^{train}$ corresponds to the major computational cost, decreasing $|\mathcal{C}^{train}|$ helps improving efficiency. On the other hand, since the estimation performance on $\mathcal{C}^{test}$ largely determines the quality of the final grouping decisions, increasing $|\mathcal{C}^{train}|$ fosters effectiveness. Besides, given a fixed budget of $|\mathcal{C}^{train}|$ , namely affordable computational cost, we can devote more efforts to develop advanced meta-learning strategies to improve the gain estimation. Moreover, this new view can incorporate the well-known HOA assumption as a special case. The HOA assumption groups all pairwise task combinations into $\mathcal{C}^{train}$ and takes the average of pairwise gains as the approximation of high-order gains for all other combinations in $\mathcal{C}^{test}$ . Thus we can view it as an nonparametric method to represent the oracle mapping $\mathcal{F}$ .
+
+# 3.3 MTG-Net
+
+In the following, we elaborate on the design of our meta learner. Specifically, we call this meta learner MTG-Net, namely a meta network to facilitate multi-task grouping. First, to provide rich representations for discrete task indicators, we introduce a classic technique from natural language research [32]: transforming discrete work tokens into vector representations while preserving semantic relationships. In our case, we also construct an embedding table $\mathbf{E} \in \mathbb{R}^{N \times D}$ to transform the input $C_i$ into a vector of embeddings, denoted as $\mathbf{X}_i = \left[\pmb{x}_1^i, \pmb{x}_2^i, \dots, \pmb{x}_{|C_i|}^i\right] \in \mathbb{R}^{|C_i| \times D}$ , where $D$ denotes the embedding dimension, and $\pmb{x}_j^i \in \mathbb{R}^{1 \times D}$ corresponds to the embedding for task $t_j^i$ .
+
+Afterwards, to effectively capture the diversified interactions in different task combinations, we stack several self-attention encoding layers [45] over the dense representation $\mathbf{X}_i$ . The reason is that the self-attention mechanism not only achieves remarkable successes in a wide variety of applications [12, 18] but also perfectly matches the unordered property of task combination and holds sufficient capacities to model those diversified inter-task interactions. Here we summarize this encoding procedure as $\mathbf{H}_i = \text{Self - Att - Enc}(\mathbf{X}_i)$ , where $\mathbf{H}_i \in \mathbb{R}^{N \times D}$ is the vector of enriched representations that encode diversified interactions among tasks, and Self - Att - Enc is the self-attention-based encoder developed by [45]. Moreover, another benefit of Self - Att - Enc is that the encoded vector $\mathbf{H}_i$ shares the same length with the label vector $Y_i$ . Naturally, we stack a linear mapping over $\mathbf{H}_i$ to obtain the final output as $\hat{Y}_i = \mathbf{H}_i \cdot \mathbf{w} + b$ , where the vector $\hat{Y}_i = [\hat{y}_1^i, \hat{y}_2^i, \dots, \hat{y}_{|C_i|}^i] \in \mathbb{R}^{|C_i|}$ corresponds to our estimation of $Y_i$ , $\hat{y}_j^i$ corresponds to the estimated gain for $t_j^i$ , $\mathbf{w} \in \mathbb{R}^D$ is a weight parameter, and $b \in \mathbb{R}^1$ is a scalar parameter being broadcasted to each entry of $\mathbf{H}_i \cdot \mathbf{w}$ .
+
+In summary, MTG-Net takes in a task combination $(C_i)$ and emits a collection of gain estimations $(\hat{Y}_i)$ . Recalling Equation (1), we formulate the specific meta-learning procedure for MTG-Net as:
+
+$$
+\text {M e t a - T r a i n :} \quad \Theta^ {*} = \arg \min _ {\Theta} \sum_ {C _ {i} \in \mathcal {C} ^ {t r a i n}} \| \hat {Y _ {i}} - Y _ {i} \| _ {2} ^ {2}, \tag {2}
+$$
+
+$$
+\text {M e t a - T e s t :} \quad \hat {\mathcal {Y}} ^ {t e s t} = \left\{\operatorname {M T G - N e t} _ {\Theta^ {*}} \left(C _ {i}\right), \text {f o r} C _ {i} \in \mathcal {C} ^ {t e s t} \right\},
+$$
+
+where $\hat{Y}_i = \mathrm{MTG - Net}_{\Theta}(C_i)$ , $\Theta$ encapsulates all parameters of MTG-Net, and $\Theta^*$ denotes a well-trained $\Theta$ . By replacing the computation-intensive MTL procedure with a network inference, we can collect the estimations of all transferring gains much more efficiently. Moreover, as long as the estimation performance is reasonable, we are still able to identify near-optimal groupings.
+
+Algorithm 1: Active Learning for MTG-Net
+Input: $\mathcal{C}^{train} = \{C_{2N - 1}\}$ $\mathcal{C}^{test} = \mathcal{C} \setminus \mathcal{C}^{train}$ , K, $\alpha$ , $\eta$ , Initialize $\Theta^*$ , $\hat{\mathcal{Y}}^{test}$ via (2)
+for $k$ in $[1, \dots, K]$ do
+ for $j$ in $[1, \dots, N]$ do
+ $\mathcal{C}^{T_j} = \{C_i, \text{for } C_i \in \mathcal{C}^{test} \text{ if } T_j \in C_i\}$ $\mathcal{G}^{T_j} = \{\hat{Y}_i(T_j), \text{for } C_i \in \mathcal{C}^{T_j}\}$ $\mathcal{P}^{T_j} = \{\exp^{\alpha \cdot |G_i|}, \text{for } G_i \in \mathcal{G}^{T_j}\} // \text{Build the sampling distribution}$ $C_{next} = \text{Sample}_{\mathcal{P}^{T_i}}(\mathcal{C}^{T_i}) // \text{Select the next meta sample}$ $\mathcal{C}^{train}.\text{insert}(C_{next})$ $\mathcal{C}^{test}.remove(C_{next}) // \text{Update the meta-training set}$
+ if $(k \cdot N - N + j)\% \eta == 0$ then
+ Update $\Theta^*$ , $\hat{\mathcal{Y}}^{test}$ via (2) // Update MTG-Net and its predictions
+ end
+end
+Output: $\Theta^*$ and $\hat{\mathcal{Y}}^{test}$
+
+# 3.4 Active Learning for MTG-Net
+
+Given the meta-learning procedure (2) for MTG-Net, however, the construction of $\mathcal{C}^{train}$ is still a critical yet unsolved issue, which can have huge influences on the generalization capability of MTG-Net. To enable more efficient learning, we develop an active learning [35] strategy for MTG-Net. Here the key intuition is that paying more attention to the combinations with large gains can foster more efficient estimations of $\mathcal{Y}$ and also better facilitate the final grouping selection. Algorithm 1 includes the pseudo code of this strategy. First, we start with an MTG-Net trained on one meta sample that corresponds to the last task combination $(C_{2^{N} - 1})$ , which includes all $N$ tasks. Next, we conduct $K$ rounds of active selections. For each round, we repeat the same active learning process for all tasks. For each task $(T_{j})$ , we first filter out a candidate set $(\mathcal{C}^{T_j})$ that incorporates all combinations including this task. Then for every combination $(C_i)$ in $\mathcal{C}^{T_j}$ , we collect the estimated transferring gain $(G_{i} = \hat{Y}_{i}(T_{j}))$ for this task, and we set the (unnormized) sampling probability as $\exp^{\alpha \cdot |G_i|}$ , where $\alpha$ is the hyper-parameter that measuring our preferences for remarkable gains (no matter positive or negative). Afterwards, we select a meta sample $(C_{next})$ following the distribution defined by $\mathcal{P}^{T_j}$ , insert it into the meta-training set, and obtain updated $\Theta^{*}$ , $\hat{y}^{test}$ by re-running the meta procedure for MTG-Net if meeting a given updating interval $(\eta)$ .
+
+Discussions on Efficiency Algorithm 1 includes $O(KN)$ times MTL procedures, which take up the major computational cost because the meta training in (2) takes negligible time compared with the corresponding MTL procedures to collect $\mathcal{Y}^{train}$ . Besides, another issue that prevents from scaling to large $N$ lies in the exponential dependence of $|\mathcal{C}^{test}|$ on $N$ . In practice, we can tackle this problem by randomly sampling a group of combinations with a large yet affordable size to substitute $\mathcal{C}$ . Moreover, since the encoder part of a hard-sharing architecture usually takes up the most computation, the computational cost of $N$ -task MTL procedures does not have orders of magnitude differences for different $N$ . Thus in this work we employ the number of MTL procedures as an approximate yet intuitive measure of computational cost. While as an anonymous reviewer mentioned, if each task has its specific data, the real computational time of MTL procedures should be considered carefully.
+
+# 4 Experiments
+
+We conduct extensive experiments to validate the effectiveness and the efficiency of our method across diversified multi-task scenarios, including vision, energy, and healthcare. In this section, we only include basic setups, main experimental results, and a part of visualization analyses. Due to the space limit, we leave other details (datasets, task specifications, networks for MTL, hyper-parameters, etc.) and more results (more visualizations, case studies, etc.) to the appendix.
+
+# 4.1 Experimental Setups
+
+MTL Datasets We conduct experiments on three MTL datasets. 1) Taskonomy [49] is a computer vision dataset including massive indoor scenes. Existing HOA-based methods [41, 14] leveraged 5 vision tasks of this dataset to evaluate MTG. We also follow the setups in [41] and denote the preprocessed dataset as Taskonomy-5. 2) ETTm1 [46] is an electric load dataset with 7 time series. We follow the multi-variate time-series forecasting problem in [46] and regard the forecasting for each series as a task. Accordingly, we denote this dataset as ETTm1-7. 3) MIMIC-III [17] is a healthcare database with rich electronic health records. Previous studies [30] constructed tens of clinical prediction tasks and found that simply performing MTL on these tasks did not always bring performance gains. We select 27 crucial clinical tasks to build the MIMIC-III-27 dataset.
+
+Transferring Gains & Grouping Selection Section 3.1 introduces how to collect ground-truth transferring gains and how to perform the final grouping selection given transferring gains (or predictions). Here we make some detailed specifications for each MTL dataset. For 5 vision tasks on Taskonomy-5, we follow [41, 14] to use the loss value as the metric and thus calculate the transferring gain as the relative reduction of the loss. For 7 forecasting tasks on ETTm1-7, we instantiate the transferring gain as the relative reduction of the mean absolute error. While for 27 clinical prediction tasks on MIMIC-III-27, all of which adopt AUROC as the metric, we define the transferring gain as the relative improvement of AUROC. Note that all these transferring gains are collected on the validation set, and we conduct the MTL procedure for each case with different random seeds. Only after conducting the grouping selection based on transferring gains, we report the performance on the test set for selected groupings. Moreover, we collect all ground-truth transferring gains for 31 task combinations on Taskonomy-5 and 127 task combinations on ETTm1-7. However, 27 tasks on MIMIC-III-27 produce over one hundred million task combinations, so we randomly sample 3,000 combinations to represent the whole space. All these MTL procedures cost thousands of GPU hours in total, and we will release the collected meta datasets for future research.
+
+Hyper-parameters of MTG-Net We use the same hyper-parameters for all MTL datasets. To be specific, we set the dimension of task embeddings as $D = 64$ and stack 2 self-attention encoding layers [45]. As for Algorithm 1, we set $\alpha$ as 25 to prioritize the selection of task combinations with large gains. Besides, we leverage a dynamic strategy to schedule $\eta$ . At an early stage when $|\mathcal{C}^{train}| < N + 1$ , we set $\eta$ as 1 to frequently updating MTG-Net to pursue more effective selections. When $|\mathcal{C}^{train}| > N + 1$ , we set $\eta$ as $N$ to reduce the number of updating for MTG-Net to further improve efficiency. $K$ is the hyper-parameter deciding the total number of meta-training samples, which is specified along with each figure. Moreover, we repeat the meta training and inference of MTG-Net with five random seeds and report the average results to eliminate the effects of randomness.
+
+Baselines We compare MTG-Net with four baselines. 1) Oracle denotes the grouping solution based on all ground-truth transferring gains on the validation set, which forms an upper bound of all approximation methods. 2) Random denotes randomly selecting a group of task combinations satisfying a given budget. Since this solution has high variance, we conduct one million random trials and report the average performance, as did in [41]. 3) HOA [41] conducted $\binom{N}{2}$ MTL procedures on pairwise combinations to collect ground-truth pairwise gains and then estimated all rest high-order gains via the average of corresponding pairwise gains. 4) TAG [14] attempted to improve the efficiency of HOA by obtaining an approximation to the pairwise gains via a customized MTL procedure on all tasks, which involved $N$ times extra forward and backward processes per each gradient updating to collect pairwise affinities on the fly.
+
+# 4.2 Main Experiments
+
+We present our main evaluation results for all three datasets in Figure 2. For each dataset, we include two configurations of $K$ for MTG-Net: $K = 1$ and $K = \frac{N - 1}{2}$ . As illustrated in Section 3.4, our active learning strategy requires $O(KN)$ times MTL procedures. Therefore, these two types of $K$ roughly correspond to the computational cost required by TAG and HOA, respectively.
+
+In the left side of Figure 2, we show the final performance (on the test set) of selected groupings under different budgets. As the budget increases, meaning we have more combinations for a task to choose as the affiliated group, the final performance should also increase for a well-behaved
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+Figure 2: We show the final performance of selected groupings under different budgets (left column), the distribution of gain estimation errors (middle column), and the distribution of ground-truth gains (right column) on Taskonomy-5, ETTm1-7, and MIMIC-III-27.
+
+
+
+
+
+MTG solution. However, we observe some fluctuation and even degradation effects. There are two reasons: 1) inaccurate estimations of transferring gains can largely misguide the grouping selection, and the grouping errors become much more evident as the budget increases; 2) we use the transferring gains collected on the validation set to guide the grouping selection, but these gains are not completely consistent with the actual performance gains on the test set. The latter reason also apply to Oracle, but its performance increases with the budget at most time. Thus, we can conclude that the degradation effect influenced by the latter reason is limited, and it is reliable to attribute the final grouping performance to the quality of the estimations for transferring gains.
+
+Furthermore, we can find that HOA and TAG produce poor grouping decisions on ETTm1-7 and MIMIC-III-27, while HOA can obtain pretty well grouping performance on Taskonomy-5, and TAG can produce reasonable performance when the budget is small. The key reason is that the number of task combinations increases exponentially as the number of tasks increases, as a result, HOA and TAG fail to provide accurate estimations for massive high-order task combinations solely based on the information of pairwise combinations. As for Taskonomy-5, there are large transferring gains covered by pairwise combinations, so HOA can obtain reasonable grouping performance. However, since TAG introduces another approximation step to predict pairwise affinities, its grouping performance suffers more degradation than HOA as the budget increases. In contrast, we can see that MTG-Net behaves much better on all cases. Specifically, when we set $K = \frac{N - 1}{2}$ , which means we only have the ground-truth gains on $\frac{N(N - 1)}{2} + 1$ task combinations, MTG-Net is able to produce high-quality groupings that are very close to the ones derived by Oracle. In addition to the grouping performance, we also show the estimation errors of transferring gains (calculated on the validation set) on all task combinations in the middle column of Figure 2 and plot the distribution of ground-truth transferring gains in the right side. These auxiliary information aligns with the analyses mentioned above and further reveal the drawbacks of the HOA assumption that maps pairwise gains to high-order ones.
+
+Given the superiority of MTG-Net over existing solutions, we further conduct experiments on the much challenging MIMIC-III-27 benchmark to verify two critical factors that drive the success of MTG-Net. One is the number of meta-training samples. Figure 3a includes the performance comparisons of multiple MTG-Net counterparts with different $K$ . Here we conduct multiple runs for each counterpart and plot the average performance as well as the standard deviation (shadow
+
+
+(a) The impact of $K$
+
+
+(b) Active selection of $\mathcal{C}^{train}$ v.s. random selection
+
+
+Figure 3: Different configurations of MTG-Net on MIMIC-III-27.
+Figure 4: We select five tasks from different datasets and visualize the latent structures of transferring relationships discovered by MTG-Net. For each task, we aggregate its encoded embeddings (from $H_{i}$ ) for all relevant task combinations and project them into a two-dimensional space via t-SNE [44]. The upper two rows only include task combinations on $C^{train}$ for two $Ks$ . The bottom row includes all combinations covering this task. We color each combination by its ground-truth gain for this task (red: positive; blue: negative; the deeper the color depth, the larger the gain (absolute value)).
+
+area). We can clearly see that adding meta-training samples brings prominent improvements in the grouping performance for large budgets. While for small budgets, even $K = 1$ can produce reasonably good performance. This observation can help us to balance efficiency and effectiveness flexibly according to specific practical scenarios. Besides, the other crucial factor is the active learning strategy illustrated in Algorithm 1. Figure 3b includes the ablation study on the importance of active learning. We can observe that no matter $K$ is large (13) or small (1), the active selection of meta samples produces remarkable improvements over the random selection.
+
+# 4.3 Visualization Analyses
+
+Figure 4 visualizes some latent structures of transferring relationships discovered by MTG-Net. By inspecting the upper two rows, we can clearly see that MTG-Net discovers a more comprehensive latent structure as the active learning strategy progressively increases $|\mathcal{C}^{train}|$ from $N + 1$ to $\frac{N(N - 1)}{2} + 1$ . From the bottom two rows, we can observe that the latent structure discovered on $\mathcal{C}^{train}$ is roughly consistent with the overall structure on $\mathcal{C}$ . This observation intuitively reveals that the transferring relationships indeed lie in some low-dimensional manifolds, and our active learning strategy is effective in selecting those crucial combinations, which can function as the landmarks of the latent structure. Moreover, by comparing different latent structures across different tasks, we can observe that no matter how the MTL scenario and the number of task combinations vary, MTG-Net can still provide a reasonable approximation to the underlying latent structure.
+
+# 5 Conclusion and Future Work
+
+This paper introduces an efficient and effective approach for MTG, which is based on a new meta-learning formulation on task combinations. The key takeaway is that no matter how large the space of task combinations is, the relationships between task combinations and performance gains lie in some low-dimensional manifolds. Our experiments across diversified MTL scenarios demonstrate the practicability of this hypothesis. This is why we can make predictions for massive unseen task combinations with only ground-truth gains on a few actively selected combinations. The direct impact of this work is to benefit a wide range of real-world applications [6, 19, 36, 31], in which people have multiple learning tasks but do not know how to organize them into different groups effectively.
+
+Moreover, we note that there are some valuable future research directions given the contribution of this work, demonstrating that the transferring relationships of a predefined MTL procedure across different task combinations could be meta learned. First, when the data or the model architectures changed, the transferring effects among tasks could also distinctly change. Both HOA [41] and us have observed these phenomena, which implies that multi-task transferring relationships may be a function of the data, the model, and some other factors (such as optimization algorithms). Thus how to enable effective meta learning on task combinations across different configurations of MTL procedures is a valuable research question to be answered. Besides, this work only considers the transferring relationships among a fixed set of tasks, while in practice we would always encounter new tasks. Accordingly, how to enable incremental meta learning or endow MTG-Net with the zero-shot capability is worthy of great research attention.
+
+# References
+
+[1] Alessandro Achille, Michael Lam, Rahul Tewari, Avinash Ravichandran, Subhransu Maji, Charless C Fowlkes, Stefano Soatto, and Pietro Perona. Task2vec: Task embedding for meta-learning. In ICCV, 2019.
+[2] Armen Aghajanyan, Anchit Gupta, Akshit Shrivastava, Xilun Chen, Luke Zettlemoyer, and Sonal Gupta. Muppet: Massive multi-task representations with pre-finetuning. In EMNLP, 2021.
+[3] Rie Kubota Ando, Tong Zhang, and Peter Bartlett. A framework for learning predictive structures from multiple tasks and unlabeled data. JMLR, 2005.
+[4] Marcin Andrychowicz, Misha Denil, Sergio Gomez, Matthew W Hoffman, David Pfau, Tom Schaul, Brendan Shillingford, and Nando De Freitas. Learning to learn by gradient descent by gradient descent. In NeurIPS, 2016.
+[5] Andreas Argyriou, Theodoros Evgeniou, and Massimiliano Pontil. Convex multi-task feature learning. Machine learning, 2008.
+[6] Vamsi Aribandi, Yi Tay, Tal Schuster, Jinfeng Rao, Huaixiu Steven Zheng, Sanket Vaibhav Mehta, Honglei Zhuang, Vinh Q. Tran, Dara Bahri, Jianmo Ni, Jai Gupta, Kai Hui, Sebastian Ruder, and Donald Metzler. Ext5: Towards extreme multi-task scaling for transfer learning. In ICLR, 2022.
+[7] Jonathan Baxter. A model of inductive bias learning. JAIR, 2000.
+[8] Richard Caruana. Multitask learning: A knowledge-based source of inductive bias. In ICML, 1993.
+[9] Richard Caruana. Multitask learning. Machine learning, 1997.
+[10] Xiaohan Chen, Siyu Tang, Krikamol Muandet, et al. Mate: Plugging in model awareness to task embedding for meta learning. In NeurIPS, 2020.
+[11] Ronan Collobert and Jason Weston. A unified architecture for natural language processing: Deep neural networks with multitask learning. In ICML, 2008.
+
+[12] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, Jakob Uszkoreit, and Neil Houlsby. An image is worth 16x16 words: Transformers for image recognition at scale. In ICLR, 2021.
+[13] Long Duong, Trevor Cohn, Steven Bird, and Paul Cook. Low resource dependency parsing: Cross-lingual parameter sharing in a neural network parser. In ACL, pages 845–850, 2015.
+[14] Christopher Fifty, Ehsan Amid, Zhe Zhao, Tianhe Yu, Rohan Anil, and Chelsea Finn. Efficiently identifying task groupings for multi-task learning. In NeurIPS, 2021.
+[15] Pengsheng Guo, Chen-Yu Lee, and Daniel Ulbricht. Learning to branch for multi-task learning. In ICML, 2020.
+[16] Siyu Huang, Xi Li, Zhi-Qi Cheng, Zhongfei Zhang, and Alexander Hauptmann. GNAS: A greedy neural architecture search method for multi-attribute learning. In ACM-MM, 2018.
+[17] Alistair EW Johnson, Tom J Pollard, Lu Shen, H Lehman Li-Wei, Mengling Feng, Mohammad Ghassemi, Benjamin Moody, Peter Szolovits, Leo Anthony Celi, and Roger G Mark. Mimic-iii, a freely accessible critical care database. Scientific data, 2016.
+[18] John Jumper, Richard Evans, Alexander Pritzel, Tim Green, Michael Figurnov, Olaf Ronneberger, Kathryn Tunyasuvunakool, Russ Bates, Augustin Žídek, Anna Potapenko, et al. Highly accurate protein structure prediction with alphafold. Nature, 2021.
+[19] Dmitry Kalashnikov, Jacob Varley, Yevgen Chebotar, Benjamin Swanson, Rico Jonschkowski, Chelsea Finn, Sergey Levine, and Karol Hausman. Mt-opt: Continuous multi-task robotic reinforcement learning at scale. arXiv preprint arXiv:2104.08212, 2021.
+[20] Zhuoliang Kang, Kristen Grauman, and Fei Sha. Learning with whom to share in multi-task feature learning. In ICML, 2011.
+[21] Gregory Koch, Richard Zemel, Ruslan Salakhutdinov, et al. Siamese neural networks for one-shot image recognition. In ICML deep learning workshop, 2015.
+[22] Abhishek Kumar and Hal Daumé III. Learning task grouping and overlap in multi-task learning. In ICML, 2012.
+[23] Lin Lan, Zhenguo Li, Xiaohong Guan, and Pinghui Wang. Meta reinforcement learning with task embedding and shared policy. In *IJCAI*, 2019.
+[24] Yann LeCun, Yoshua Bengio, and Geoffrey Hinton. Deep learning. Nature, 2015.
+[25] Xi Lin, Hui-Ling Zhen, Zhenhua Li, Qing-Fu Zhang, and Sam Kwong. Pareto multi-task learning. In NeurIPS, 2019.
+[26] Chenxi Liu, Barret Zoph, Maxim Neumann, Jonathon Shlens, Wei Hua, Li-Jia Li, Li Fei-Fei, Alan Yuille, Jonathan Huang, and Kevin Murphy. Progressive neural architecture search. In ECCV, 2018.
+[27] Mingsheng Long, Zhangjie Cao, Jianmin Wang, and Philip S Yu. Learning multiple tasks with multilinear relationship networks. In NeurIPS, 2017.
+[28] Yongxi Lu, Abhishek Kumar, Shuangfei Zhai, Yu Cheng, Tara Javidi, and Rogerio Feris. Fully-adaptive feature sharing in multi-task networks with applications in person attribute classification. In CVPR, 2017.
+[29] Pingchuan Ma, Tao Du, and Wojciech Matusik. Efficient continuous pareto exploration in multi-task learning. In ICML, 2020.
+[30] Matthew McDermott, Bret Nestor, Evan Kim, Wancong Zhang, Anna Goldenberg, Peter Szolovits, and Marzyeh Ghassemi. A comprehensive evaluation of multi-task learning and multi-task pre-training on ehr time-series data. arXiv preprint arXiv:2007.10185, 2020.
+
+[31] Matthew McDermott, Bret Nestor, Evan Kim, Wancong Zhang, Anna Goldenberg, Peter Szolovits, and Marzyeh Ghassemi. A comprehensive ehr timeseries pre-training benchmark. In CHIL, 2021.
+[32] Tomas Mikolov, Ilya Sutskever, Kai Chen, Greg S Corrado, and Jeff Dean. Distributed representations of words and phrases and their compositionality. In NeurIPS, 2013.
+[33] Ishan Misra, Abhinav Shrivastava, Abhinav Gupta, and Martial Hebert. Cross-stitch networks for multi-task learning. In CVPR, 2016.
+[34] Tsendsumen Munkhdalai and Hong Yu. Meta networks. In ICML, 2017.
+[35] Michael Prince. Does active learning work? a review of the research. Journal of engineering education, 2004.
+[36] Bharath Ramsundar, Steven Kearnes, Patrick Riley, Dale Webster, David Konerding, and Vijay Pande. Massively multitask networks for drug discovery. arXiv preprint arXiv:1502.02072, 2015.
+[37] Sebastian Ruder. An overview of multi-task learning in deep neural networks. arXiv preprint arXiv:1706.05098, 2017.
+[38] Shiv Kumar Saini, Sunny Dhamnani, Akil Arif Ibrahim, and Prithviraj Chavan. Multiple treatment effect estimation using deep generative model with task embedding. In WWW, 2019.
+[39] Ozan Sener and Vladlen Koltun. Multi-task learning as multi-objective optimization. In NeurIPS, 2018.
+[40] Jake Snell, Kevin Swersky, and Richard Zemel. Prototypical networks for few-shot learning. In NeurIPS, 2017.
+[41] Trevor Standley, Amir Zamir, Dawn Chen, Leonidas Guibas, Jitendra Malik, and Silvio Savarese. Which tasks should be learned together in multi-task learning? In ICML, 2020.
+[42] Xineng Sun, Rameswar Panda, Rogerio Feris, and Kate Saenko. Adashare: Learning what to share for efficient deep multi-task learning. In NeurIPS, 2020.
+[43] Sebastian Thrun and Lorien Pratt. Learning to learn. Springer Science & Business Media, 2012.
+[44] Laurens Van der Maaten and Geoffrey Hinton. Visualizing data using t-sne. JMLR, 2008.
+[45] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. In NeurIPS, 2017.
+[46] Haixu Wu, Jiehui Xu, Jianmin Wang, and Mingsheng Long. Autoformer: Decomposition transformers with Auto-Correlation for long-term series forecasting. In NeurIPS, 2021.
+[47] Sen Wu, Hongyang R Zhang, and Christopher Ré. Understanding and improving information transfer in multi-task learning. In ICLR, 2019.
+[48] Tianhe Yu, Saurabh Kumar, Abhishek Gupta, Sergey Levine, Karol Hausman, and Chelsea Finn. Gradient surgery for multi-task learning. In NeurIPS, 2020.
+[49] Amir R Zamir, Alexander Sax, William Shen, Leonidas J Guibas, Jitendra Malik, and Silvio Savarese. Taskonomy: Disentangling task transfer learning. In CVPR, 2018.
+[50] Yu Zhang and Qiang Yang. A survey on multi-task learning. TKDE, 2021.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See Section 5
+(c) Did you discuss any potential negative societal impacts of your work? [No]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] See the extra experiments provided in the appendix.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Section 4.1.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [Yes]
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [Yes]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/images.zip b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..ac17047ce4bdccd3b6d0f1108e33c5a5a8eb0d62
--- /dev/null
+++ b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9dac40cce82c2cd03ddc3c1469eb2bad5190aaf15315c5265b16fbc50e1cded5
+size 338871
diff --git a/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/layout.json b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..a1cf8f1fbca0a68621c48c2072457afd7b451179
--- /dev/null
+++ b/efficientandeffectivemultitaskgroupingviametalearningontaskcombinations/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:da783f43a08864704cf1e3e9854bb6b4618221cf41789dcc712776438a44aa68
+size 457101
diff --git a/efficientandeffectiveoptimaltransportbasedbiclustering/3e83eeab-f761-4662-9c39-44fe6963b420_content_list.json b/efficientandeffectiveoptimaltransportbasedbiclustering/3e83eeab-f761-4662-9c39-44fe6963b420_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..dad029326ea4c203d91b408cdc00574746df3faf
--- /dev/null
+++ b/efficientandeffectiveoptimaltransportbasedbiclustering/3e83eeab-f761-4662-9c39-44fe6963b420_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ed1bffea99c523f59b7f9a135ef8bd04303c9efd5c8c7b84ce729aafa9a11516
+size 77426
diff --git a/efficientandeffectiveoptimaltransportbasedbiclustering/3e83eeab-f761-4662-9c39-44fe6963b420_model.json b/efficientandeffectiveoptimaltransportbasedbiclustering/3e83eeab-f761-4662-9c39-44fe6963b420_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..d66c12ac20992514c8c87a9b58f8b9c6f9b9deb9
--- /dev/null
+++ b/efficientandeffectiveoptimaltransportbasedbiclustering/3e83eeab-f761-4662-9c39-44fe6963b420_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c4e8623234a819bcfa013b48be5190c871f8f5c824fc90f751be6453ab38d68c
+size 93946
diff --git a/efficientandeffectiveoptimaltransportbasedbiclustering/3e83eeab-f761-4662-9c39-44fe6963b420_origin.pdf b/efficientandeffectiveoptimaltransportbasedbiclustering/3e83eeab-f761-4662-9c39-44fe6963b420_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..7eb98bea6690083dd5c41a478dfae2b082cea37e
--- /dev/null
+++ b/efficientandeffectiveoptimaltransportbasedbiclustering/3e83eeab-f761-4662-9c39-44fe6963b420_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e4b89acf92d983cb54c92ec85849331641d044df61119ff3a3d222658b35b5a6
+size 459303
diff --git a/efficientandeffectiveoptimaltransportbasedbiclustering/full.md b/efficientandeffectiveoptimaltransportbasedbiclustering/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..d25048e8c3dc501c035f17ce3736a17c4b6adbde
--- /dev/null
+++ b/efficientandeffectiveoptimaltransportbasedbiclustering/full.md
@@ -0,0 +1,382 @@
+# Efficient and Effective Optimal Transport-Based Biclustering
+
+Chakib Fettal
+
+Centre Borelli UMR 9010
+
+Université Paris Cité
+
+Informatique Caisse des Dépôts et Consignations
+
+chakib.fettal@etu.u-paris.fr
+
+Lazhar Labiod
+
+Centre Borelli UMR 9010
+
+Université Paris Cité
+
+lazhar.labiod@u-paris.fr
+
+Mohamed Nadif
+
+Centre Borelli UMR 9010
+
+Université Paris Cité
+
+mohamed.nadif@u-paris.fr
+
+# Abstract
+
+Bipartite graphs can be used to model a wide variety of dyadic information such as user-rating, document-term, and gene-disorder pairs. Biclustering is an extension of clustering to the underlying bipartite graph induced from this kind of data. In this paper, we leverage optimal transport (OT) which has gained momentum in the machine learning community to propose a novel and scalable biclustering model that generalizes several classical biclustering approaches. We perform extensive experimentation to show the validity of our approach compared to other OT biclustering algorithms along both dimensions of the dyadic datasets.
+
+# 1 Introduction
+
+Let $G = (U, V, E)$ be a bipartite graph, which is a graph whose vertices can be divided into two disjoint sets $U = \{1, 2, \dots, |U|\}$ with $|U| = n$ , $V = \{1, 2, \dots, |V|\}$ with $|V| = d$ and the set of edges $E$ where each edge connects a vertex of $U$ to a vertex of $V$ . The adjacency matrix for this type of graph has the following structure
+
+$$
+\mathbf {A} = \left( \begin{array}{c c} \mathbf {0} _ {n \times n} & \mathbf {B} \\ \mathbf {B} ^ {\top} & \mathbf {0} _ {d \times d} \end{array} \right) \tag {1}
+$$
+
+where $\mathbf{B}$ of size $n\times d$ is called the biadjacency matrix of $G$ , its rows and columns corresponding to the two sets of vertices; each entry represents an edge between a row and a column. Biclustering (or Co-clustering) is the extension of clustering to this type of graph. Following [21], several biclustering models have attempted to solve the problem by viewing $\mathbf{B}$ as a two-mode matrix and searching for a simultaneous partition of its rows and columns [9]. In this way, biclustering seeks to reveal subsets of $U$ which exhibit a similar behaviour across a subset of $V$ in matrix $\mathbf{B}$ .
+
+Biclustering has been used in a number of different contexts. [12] used microarray data to find relations between genes and conditions, finding that genes with similar functions often cluster together. [20] applied this paradigm to data from the US Food and Drug Administration reporting system in order to identify groups of drugs with adverse effects. [11] used it to find market segments among tourists so as to enable more effective targeted marketing. There have been various other applications [9, 33, 19].
+
+Several solutions to the biclustering problem have been proposed in the literature (see [17]). [10] used an information-theoretic approach to solve the problem by minimizing the difference in mutual
+
+information between $\mathbf{B}$ and a summary matrix; they implicitly assume that the data points are generated from a Poisson latent block model [18]. [3] adapted classical modularity to bipartite networks and then used it to identify modules within them. [35] proposed a biclustering paradigm based on nonnegative matrix tri-factorization of the biadjacency matrix.
+
+Recently, Optimal Transport (OT) has taken the machine learning community by storm. OT has helped to solve a variety of data mining problems, and biclustering is no exception. [25] proposed two models for biclustering: a first model, CCOT, which does co-clustering based on the scaling vectors obtained by applying the Sinkhorn-Knopp algorithm on a square subsampled version of matrix $\mathbf{B}$ , and a second model, CCOT-GW, which uses scaling vectors obtained by computing entropic Gromov-Wasserstein barycenters, and which does not require subsampling. Then came [34], where the authors did biclustering by minimizing a new metric, COOT, which generalizes the Gromov-Wasserstein distance between $\mathbf{B}$ and a summary matrix, similarly to what was done in [10]. More specifically, they proposed two new metrics: COOT, together with an entropically regularized metric $\mathrm{COOT}_{\lambda}$ . However, both [25] and [34] have certain drawbacks. First, both algorithms do not tackle the biclustering from the beginning; the co-clusters are deduced at the convergence. Thereby biclustering is a consequence and not a main goal. Secondly, they suffer from high computational complexity; CCOT and CCOT-GW also consume large amounts of memory. Finally, we will see that these algorithms are not suited to dyadic sparse data.
+
+In this paper, while integrating the biclustering objective from the beginning, we propose a generic framework for biclustering through optimal transport, which generalizes some previous biclustering approaches. We propose two efficient methods for solving this problem: one that gives an almost hard biclustering, and another that gives a fuzzy or soft biclustering through entropic regularization. These methods outperform other optimal transport biclustering models, in terms of both document and term clustering, on several regular and large scale datasets, while being more computationally and memory efficient. We emphasize once again that the approach we propose is specifically tailored to datasets consisting of dyadic data.
+
+# 2 Methodology
+
+Notations. In what follows, $\Delta^n = \{\mathbf{p} \in \mathbb{R}_+^n \mid \sum_{i=1}^n p_i = 1\}$ denotes the $n$ -dimensional standard simplex. $\Pi(\mathbf{w}, \mathbf{v}) = \{\mathbf{Z} \in \mathbb{R}_+^{n \times k} | \mathbf{Z} \mathbf{1} = \mathbf{w}, \mathbf{Z}^\top \mathbf{1} = \mathbf{v}\}$ denotes the transportation polytope, where $\mathbf{w} \in \Delta^n$ and $\mathbf{v} \in \Delta^k$ are the marginals of the joint distribution $\mathbf{Z}$ and $\mathbf{1}_n$ is a vector of ones. Matrices are denoted with uppercase boldface letters, and vectors with lowercase boldface letters. For a matrix $\mathbf{M}$ , its $i$ -th row is $\mathbf{m}_i$ and its $j$ -th column is $\mathbf{m}_j'$ . We have that $\|\cdot\|_0$ is the 0-norm which returns the number of nonzero elements of its argument.
+
+# 2.1 Preliminaries
+
+We first need to introduce exact discrete OT and its entropically regularized counterpart, and show how biclustering can be posed as an integer program.
+
+Discrete OT as a linear program. The goal of discrete optimal transport is to find a minimal cost transport plan between a source probability distribution $\mathbf{w}$ and a target distribution $\mathbf{v}$ . Here we are interested in the discrete case of the Kantorovich formulation of OT, that is
+
+$$
+\operatorname {O T} (\mathbf {M}, \mathbf {w}, \mathbf {v}) \triangleq \min _ {\mathbf {Z} \in \Pi (\mathbf {w}, \mathbf {v})} \langle \mathbf {M}, \mathbf {Z} \rangle \tag {2}
+$$
+
+where $\mathbf{M} \in \mathbb{R}^{n \times k}$ is the cost matrix, and $m_{ij}$ quantifies the effort needed to transport a probability mass from $\mathbf{w}_i$ to $\mathbf{v}_j$ .
+
+Discrete entropy regularized OT. It has been suggested in the literature [6, 5] that the use of a regularization such as entropic regularization can lead to better computational and statistical efficiency.
+
+$$
+\mathrm {O T} _ {\lambda} (\mathbf {M}, \mathbf {w}, \mathbf {v}) \triangleq \min _ {\mathbf {Z} \in \Pi (\mathbf {w}, \mathbf {v})} \left\langle \mathbf {M}, \mathbf {Z} \right\rangle - \lambda H (\mathbf {Z}) \tag {3}
+$$
+
+where $H$ is the entropy defined as $H(\mathbf{Z}) \triangleq -\sum_{i,j} z_{ij} \log z_{ij}$ and $\lambda$ controls the strength of regularization. The computational efficiency comes from the fact that the unique solution of this problem is of the structure $\mathbf{Z} := \mathrm{diag}(\mathbf{a}) \exp(-\mathbf{M} / \lambda) \mathrm{diag}(\mathbf{b})$ , a rescaled elementwise negative exponential of the cost $\mathbf{M}$ , where $\mathbf{a}$ and $\mathbf{b}$ are scaling vectors. These vectors can be found efficiently using the Sinkhorn-Knopp algorithm.
+
+Biclustering as an integer program. The Block seriation problem [27] consists in finding two permutation matrices, one for the rows and one for the columns s.t. dense blocks appear along the diagonal of the permuted matrix. A possible definition of the block seriation problem is as follows: given a matrix $\mathbf{B} \in \mathbb{R}^{n \times d}$ s.t $b_{ij}$ gives the strength of the association between row $i$ and column $j$ (such as in the case of a biadjacency matrix, for example), we have
+
+$$
+\max _ {\mathbf {C}} \sum_ {i, j} b _ {i j} c _ {i j} \tag {4}
+$$
+
+subject to $\forall i,j\quad c_{ij}\in \{0,1\}$
+
+$$
+\forall i, j, i ^ {\prime}, j ^ {\prime} \quad c _ {i j} + c _ {i j ^ {\prime}} + c _ {i ^ {\prime} j ^ {\prime}} - c _ {i ^ {\prime} j} \leq 2
+$$
+
+$$
+\forall j \quad \sum_ {i} c _ {i j} \geq 1
+$$
+
+$$
+c _ {i ^ {\prime} j ^ {\prime}} + c _ {i ^ {\prime} j} + c _ {i j} - c _ {i j ^ {\prime}} \leq 2
+$$
+
+$$
+\forall i \quad \sum_ {j} c _ {i j} \geq 1
+$$
+
+$$
+c _ {i ^ {\prime} j} + c _ {i j} + c _ {i j ^ {\prime}} - c _ {i ^ {\prime} j ^ {\prime}} \leq 2
+$$
+
+$$
+c _ {i j ^ {\prime}} + c _ {i ^ {\prime} j ^ {\prime}} + c _ {i ^ {\prime} j} - c _ {i j} \leq 2
+$$
+
+A solution $\mathbf{C}$ is a block diagonal matrix up to a permutation of its rows and columns. The block seriation problem is an integer programming problem that is NP-hard. One approach for solving this problem uses a simplified version where a rank constraint $\mathrm{rank}(\mathbf{C})\leq k$ is added for $k$ the number of desired bicusters. Integrating this constraint into (4), we can define a new problem by low-rank factorization of $\mathbf{C}$ , i.e. $\mathbf{C} = \mathbf{Z}\mathbf{W}^{\top}$ , which we formulate as
+
+$$
+\max _ {\substack {\mathbf {Z} \in \Gamma (n, k) \\ \mathbf {W} \in \Gamma (d, k)}} \sum_ {i, j, h} b _ {i j} z _ {i h} w _ {j h} \tag{5}
+$$
+
+where $\Gamma(n, k) = \{\mathbf{Z} \in \{0, 1\}^{n \times k} \mid \mathbf{Z}\mathbf{1} = \mathbf{1}\}$ is the set of hard partitions of dimension $n \times k$ . A simple heuristic for solving this problem involves alternatingly solving for $\mathbf{Z}$ given $\mathbf{W}$ , and vice-versa, using classical clustering algorithms, before identifying biclusters through the rearranged matrix $\mathbf{C}$ , which displays a block diagonal structure, as shown in figure 1a. The biclusters are identified by grouping together the rows and columns that form a block along the diagonal.
+
+# 2.2 Biclustering using Optimal Transport
+
+Here we propose a new biclustering problem based on block seriation and optimal transport. For this purpose we first define what we term an anti-adjacency matrix. Note that a similar concept has been discussed in [36].
+
+Definition 1 (Anti-adjacency matrix) Given a graph characterized by an adjacency matrix $\mathbf{A}$ , we have a corresponding anti-adjacency matrix $\overline{\mathbf{A}}$ s.t. $\overline{a}_{ij}$ quantifies the discrepancy between nodes $i$ and $j$ .
+
+We consider a bipartite graph characterized by its biadjacency matrix $\mathbf{B} = (b_{ij})\in \mathbb{R}^{n\times d}$ . The rows of $\mathbf{B}$ are endowed with weights $\mathbf{w}\in \Delta^n$ and its columns with weights $\mathbf{v}\in \Delta^d$ . We also consider a row exemplar distribution $\mathbf{r}\in \Delta^r$ and a column exemplar distribution $\mathbf{c}\in \Delta^c$ . Depending on the availability of a priori information about the data, these weight vectors can be set to uniform distributions.
+
+Now let its anti-biadjacency matrix be $\overline{\mathbf{B}} = L(\mathbf{B})$ , where $L: \mathbb{R}^{n \times d} \to \mathbb{R}^{n \times d}$ means that $b_{ij}$ , the association between node $i$ and node $j$ , is transformed into a discrepancy measure $L(\mathbf{B})_{ij}$ . Thus, we define the optimal transport block seriation problem as the following bilinear program
+
+$$
+\operatorname {BCOT} (\mathbf {w}, \mathbf {v}, \mathbf {r}, \mathbf {c}) \triangleq \min _ {\substack {\mathbf {Z} \in \Pi (\mathbf {w}, \mathbf {r}) \\ \mathbf {W} \in \Pi (\mathbf {v}, \mathbf {c})}} \sum_ {i, j, k} L (\mathbf {B}) _ {i j} z _ {i k} w _ {j k} \equiv \min _ {\substack {\mathbf {Z} \in \Pi (\mathbf {w}, \mathbf {r}) \\ \mathbf {W} \in \Pi (\mathbf {v}, \mathbf {c})}} \left\langle L (\mathbf {B}), \mathbf {Z} \mathbf {W} ^ {\top} \right\rangle \tag{6}
+$$
+
+where $\mathbf{Z}$ is a transport plan (or coupling) between between the row distribution $\mathbf{w}$ and the row exemplar distribution $\mathbf{r}$ , and similarly for $\mathbf{W}$ w.r.t. the column distribution $\mathbf{v}$ and the column exemplar distribution $\mathbf{c}$ .
+
+
+(a) Block Seriation.
+
+
+(b) BCOT.
+Figure 1: Biclusters formed using three different methods on the Pubmed dataset. Classical block seriation results in a biclustering that is hard. BCOT results in a biclustering that is almost hard with few nonzero entries outside the main block diagonal. $\mathrm{BCOT}_{\lambda}$ results in a soft biclustering with many nonzero elements outside the block diagonal.
+
+
+(c) $\mathrm{BCOT}_{\lambda}$ .
+
+Inducing a biclustering via BCOT. We will now show how to obtain a partition of the rows and the columns given a solution pair $(\mathbf{Z},\mathbf{W})$ . In what follows our aim is to identify an almost-hard clustering couple for rows and columns from the couplings $\mathbf{Z}$ and $\mathbf{W}$ .
+
+Definition 2 (h-almost hard clustering) We define an h-almost hard clustering as a clustering whose assignment matrix is $\mathbf{C} \in \mathbb{R}^{n \times k}$ s.t. $\| \mathbf{C} \|_0 = n + h$ and for each row $c$ of $\mathbf{C}$ we have that $\| c \|_0 > 0$ . When $h = 0$ , we obtain a standard hard clustering with one non-zero element per row.
+
+Proposition 1 For $\mathbf{w}$ , $\mathbf{v}$ , $\mathbf{r}$ and $\mathbf{c}$ containing no zeros, there exists an optimal pair of coupling matrices $\mathbf{Z}$ and $\mathbf{W}$ that are $h$ -almost hard clusterings with $h \in \{0, \dots, k-1\}$ . Furthermore, when $n = k$ (resp. $d = k$ ) and $\mathbf{w} = \mathbf{r}$ (resp. $\mathbf{v} = \mathbf{c}$ ), this $\mathbf{Z}$ (resp. $\mathbf{W}$ ) becomes a hard clustering, i.e., $\mathbf{Z} \in \Gamma(n, n)$ (resp. $\mathbf{W} \in \Gamma(d, d)$ ).
+
+This means that the solutions are already almost a hard partition of the data, since $k < n, d$ . To obtain a final hard clustering in the strict sense, we assign each row (resp. column) to the one corresponding to the row of $\mathbf{Z}$ (resp. $\mathbf{W}$ ) with the largest value. This should not significantly change the structure of the solution. Figure 1b provides an illustration: here we see the block diagonal structure generated by the product of the two coupling matrices $\mathbf{C} = \mathbf{Z}\mathbf{W}^{\top}$ , with its similarity in appearance to the biclustering produced by the hard block seriation 1a, apart from a few nonzero entries off the block diagonal that are hard to see immediately.
+
+Intuition for BCOT. To explain the intuition behind the proposed approach we need to look at how the problem is solved. The optimization procedure as described in algorithm 1 consists in alternating between the computation of an optimal transport plan $\mathbf{Z}$ given $\mathbf{W}$ and vice versa. As regards solving for $\mathbf{Z}$ given $\mathbf{W}$ , the problem can be rewritten as
+
+$$
+\operatorname {B C O T} (\mathbf {w}, \mathbf {v}, \mathbf {r}, \mathbf {c}) \equiv \min _ {\mathbf {Z} \in \Pi (\mathbf {w}, \mathbf {r})} \left\langle L (\mathbf {B}) \mathbf {W}, \mathbf {Z} \right\rangle . \tag {7}
+$$
+
+This is an optimal transport problem with $L(\mathbf{B})\mathbf{W}$ as the cost matrix. The resulting transport plan $\mathbf{Z}$ can be seen as a kind of row cluster assignment matrix: if $z_{ih} > 0$ , then row $i$ is assigned to cluster $h$ . The same holds for $\mathbf{W}$ , which can be seen as a column cluster assignment matrix. This also means that since $L(\mathbf{B})$ is the dissimilarity between the rows and the columns, then the cost matrix $L(\mathbf{B})\mathbf{W}$ represents the dissimilarity between rows and row exemplars (or representatives or centroids). In particular, $L(\mathbf{B})_i\mathbf{w}_h$ is the dissimilarity or cost of probability mass transportation between row $i$ and row cluster exemplar $h$ . The reasoning is the same for the columns and the optimal coupling $\mathbf{W}$ .
+
+Low-rank optimal transport. Biclustering is the main purpose of the approach we proposed, but there is another interesting use case.
+
+Proposition 2 For equal target row and column representative distributions, i.e., $\mathbf{r} = \mathbf{c}$ , and containing no zero entries, then given a solution pair $\mathbf{Z}$ and $\mathbf{W}$ to BCOT, the matrix $\mathbf{Q} = \mathbf{Z} \text{diag}(1 / \mathbf{r})\mathbf{W}^{\top}$ is an approximation of the optimal transport plan that is a solution to problem (2) and whose rank is at most $\min(\text{rank}(\mathbf{Z}), \text{rank}(\mathbf{W}))$ .
+
+Some recent works [16, 31] have suggested that this kind of low-rank regularization is preferable to entropic regularization as regards certain aspects. For example, the rank parameter is easier to select, since it has simple bounds (an integer between 1 and $n$ ). This may be contrasted with the regularization strength $\lambda$ in the Sinkhorn algorithm, which is continuous.
+
+# 2.3 Fuzzy Biclustering via Regularized Optimal Transport
+
+As previously mentioned, using entropic regularization may be interesting because of its various useful features including statistical and computational efficiency. However, another feature of entropic regularization is that the optimal couplings $\mathbf{Z}$ and $\mathbf{W}$ are dense matrices as a consequence of the structure of the optimal solution of entropically regularized OT problems. We formulate the problem as follows
+
+$$
+\operatorname {B C O T} _ {\lambda} (\mathbf {w}, \mathbf {v}, \mathbf {r}, \mathbf {c}) \triangleq \min _ {\substack {\mathbf {Z} \in \Pi (\mathbf {w}, \mathbf {r}) \\ \mathbf {W} \in \Pi (\mathbf {v}, \mathbf {c})}} \left\langle L (\mathbf {B}), \mathbf {Z} \mathbf {W} ^ {\top} \right\rangle - \lambda_ {\mathbf {Z}} H (\mathbf {Z}) - \lambda_ {\mathbf {W}} H (\mathbf {W}) \tag{8}
+$$
+
+where $\lambda_{\mathbf{Z}}$ and $\lambda_{\mathbf{W}}$ are the regularization parameters.
+
+Fuzzy block seriation. We propose a fuzzy variant of the block seriation problem that allows us by extension to define a fuzzy variant for BCOT using entropic regularization. Let the fuzzy block seriation problem be defined as
+
+$$
+\max _ {\substack {\mathbf {Z} \in \Gamma_ {s} (n, k) \\ \mathbf {W} \in \Gamma_ {s} (d, k)}} \sum_ {i, j, h} b _ {i j} z _ {i h} w _ {j h} + \Omega (\mathbf {Z}, \mathbf {W}) \tag{9}
+$$
+
+where $\Omega (\mathbf{Z},\mathbf{W})$ is some regularization term introduced to make the partition matrices $\mathbf{Z}$ and $\mathbf{W}$ dense (for example, entropic regularization or low-rank constraints), and $\Gamma_s(n,k) = \{\mathbf{Z}\in \mathbb{R}_+^{n\times k}|\mathbf{Z}\mathbf{1} = \mathbf{1}\}$ is the set of fuzzy partitions. Intuitively, for a solution pair $(\mathbf{Z},\mathbf{W})$ , up to a constant factor, each entry in the block seriation matrix $\mathbf{C} = \mathbf{Z}\mathbf{W}^{\top}$ can be seen as the probability of its corresponding row and column belonging to the same bicluster i.e. $c_{ij} = \mathbf{z}_i\mathbf{w}_j = \sum_{h = 1}^{r}z_{ih}w_{jh} = p(\mathbf{b}_i,\mathbf{b}_j') = \sum_{h = 1}^{r}p(\mathbf{b}_i,\mathbf{b}_j'\in h)$ .
+
+It is easy to see how problem (9) is related to problem (8) and that the couplings corresponding to solutions of the problem give the probability that the different rows and columns belong to the same biclusters. Figure 1c shows biclusters produced by the solutions of $\mathrm{BCOT}_{\lambda}$ . Similarly to BCOT, a block diagonal structure is formed. However, there are also several off-block diagonal nonzero entries that represent the probabilities of the row-column pairs belonging to the same biclusters.
+
+# 3 Links to Existing Work
+
+# 3.1 Modularity Maximization in Bipartite Graphs [3].
+
+This model is able to co-cluster binary and contingency matrices by directly maximizing an adapted version of the modularity measure traditionally used for networks. The criterion that it optimizes is
+
+$$
+\max _ {\substack {\mathbf {Z} \in \Gamma (n, k) \\ \mathbf {W} \in \Gamma (d, k)}} \sum_ {i, j, h} z _ {i h} w _ {j h} \left(b _ {i j} - \frac {b _ {. j} b _ {i .}}{b _ {. .}}\right). \tag{10}
+$$
+
+By setting $L(\mathbf{B}) = -\left(\mathbf{B} - \frac{1}{b}\mathbf{B}\mathbf{1}\mathbf{1}^{\top}\mathbf{B}\right)$ , this problem becomes equivalent to ours; the difference is in the constraints on $\mathbf{Z}$ and $\dot{\mathbf{W}}$ .
+
+# 3.2 Modularity-Based Sparse Soft Graph Clustering [23].
+
+Here the authors proposed a fuzzy variant of the above problem (although in the context of traditional clustering rather than biclustering). Solving the problem gives, for each element of the dataset, a probability of that element belonging to a given cluster. Our proposed entropic regularization variant represents a kind of extension of this problem to bipartite graphs.
+
+# 3.3 Directional Co-clustering with a Conscience [30, 1].
+
+This model makes use of the block von Mises-Fisher mixture model for co-clustering directional data on the unit-sphere. It optimizes the following criterion:
+
+$$
+\max _ {\substack {\mathbf {Z} \in \Gamma (n, k) \\ \mathbf {W} \in \Gamma (d, k)}} \sum_ {i, j, h} \frac {1}{\sqrt {z _ {. h} w _ {. h}}} z _ {i h} w _ {j h} b _ {i j}. \tag{11}
+$$
+
+In our formulation, if we define $L(\mathbf{B}) = -\mathbf{B}$ and apply cluster size normalization on the optimal transport plans $\tilde{\mathbf{Z}} = \mathbf{Z}\mathrm{diag}(\mathbf{Z}^{\top}\mathbf{1})^{-1 / 2}$ and $\tilde{\mathbf{W}} = \mathbf{W}\mathrm{diag}(\mathbf{W}^{\top}\mathbf{1})^{-1 / 2}$ after computing $\mathbf{Z}$ and $\mathbf{W}$ respectively in algorithm 1, we obtain a more general version of the algorithm proposed by the authors for solving problem (11).
+
+# 3.4 Bipartite Correlation Clustering [2].
+
+In the case where the cost function results in a complete bipartite graph with $+$ and $-$ edges with a function
+
+$$
+L (\mathbf {B}) _ {i j} = \left\{ \begin{array}{l l} - 1 & \text {i f} b _ {i j} > 0 \\ + 1 & \text {o t h e r w i s e} \end{array} \right. \tag {12}
+$$
+
+we get what is known as Bipartite Correlation Clustering. The solution to this problem maximizes the number of agreements, i.e. the number of all $+$ edges within clusters plus all $-$ edges distributed across clusters.
+
+# 4 Optimization and Complexity
+
+**Optimization.** Since the block seriation problem is NP-hard, computing an exact solution is prohibitive. An efficient and widely used heuristic for solving these kinds of problems involves the use of block coordinate descent, where row assignments are computed for fixed column assignments, and then vice versa, in alternation. We express the proposed algorithm in pseudo-code as algorithm 1. At each iteration we solve two intermediate optimal transport problems with cost matrices of dimensions $n \times k$ and $d \times k$ , since $\mathbf{B}$ is generally sparse, and $L$ can be defined such that $L(\mathbf{B})$ retains a similarly sparse structure. The computation of the intermediate cost matrices $L(\mathbf{B})\mathbf{W}$ and $L(\mathbf{B})^{\top}\mathbf{Z}$ is reasonably efficient. We also observed that the algorithm does not need many iterations to converge, as shown in figure 2, be it for BCOT or BCOT $_\lambda$ .
+
+
+Figure 2: Loss for BCOT and $\mathrm{BCOT}_{\lambda}$ on Pubmed.
+
+# Algorithm 1: BCOT
+
+Input :B bi-adjacency matrix, w and v row and column weights, r and c row and column exemplar distributions
+
+Output: $\pi^r$ , $\pi^c$ row and column partitions
+
+$\mathbf{W}\gets \mathbf{W}_{init}$
+
+while not converged do
+
+$\mathbf{Z}\gets \arg \mathsf{0T}(L(\mathbf{B})\mathbf{W},\mathbf{w},\mathbf{r});$ $\mathbf{W}\gets \arg \mathsf{0T}(L(\mathbf{B})^{\top}\mathbf{Z},\mathbf{v},\mathbf{c});$
+
+end
+
+Generate $\pi^r$ , $\pi^c$ from $\mathbf{Z}$ and $\mathbf{W}$ ;
+
+Proposition 3 The computational complexity of the BCOT algorithm 1 when using an exact OT solver is $\mathcal{O}(tk\|\mathbf{B}\|_0 + tnk(n + k)\log(n + k) + tdk(d + k)\log(d + k))$ , and when using entropic regularization the complexity is $\mathcal{O}(tk\|\mathbf{B}\|_0 + tkn + tkd)$ , where $t$ is the number of iterations.
+
+In table 1, we report the computational and spatial complexities of the different biclustering approaches. Our model has the same spatial complexity as the COOT variants and a better complexity
+
+Table 1: Computational and spatial complexity of the different OT biclustering approaches. For COOT variants, we report complexities for an euclidean cost matrix. For a generic cost, the time complexity is greater. For simplicity, we suppose that $d \in O(n)$ and that we want a biclustering with the same number of row and column clusters for COOT and CCOT. $t$ denotes the number of iterations and for CCOT, $s$ denotes the number of necessary samplings.
+
+| Method | Spatial complexity | Time complexity |
| CCOT | O(n2) | O(sn3) |
| CCOT-GW | O(n2) | O(n3) |
| COOT* | O(nk) | O((n+k)nk+k2n+t(n+k)nk log(n+k)) |
| COOTλ | O(nk) | O((n+k)nk+k2n+tnk) |
| BCOT | O(nk) | O(k||B||0+t(n+k)nk log(n+k)) |
| BCOTλ | O(nk) | O(k||B||0+tnk) |
+
+than CCOT variants. As regards the computational complexity, our model should in most cases be faster with sparse data, and our experiments support this conjecture. For reproducibility, we publicly release our code $^{2}$ .
+
+# 5 Experiments
+
+We ran experiments using term-document matrices. The benefit of using biclustering on this kind of data is that the resulting biclusters contain both documents and the words that characterize them, which is helpful in interpreting the clustering of the documents. Additional experiments over synthetic and gene expression data are available in the appendix.
+
+# 5.1 Datasets
+
+We evaluate BCOT in relation to six benchmark document-term datasets: ACM, DBLP, PubMed, Wiki, Ohscal, and 20 Newsgroups. Their characteristics are shown in Table 2. ACM, DBLP, Pubmed and Wiki are attributed networks from which we use only the node-level features that correspond to term-document matrices. We also selected the Ohscal collection and 20 Newsgroups as large-scale document-term matrices to serve as computational efficiency benchmarks.
+
+Table 2: Characteristics of the datasets.
+
+| Dataset | #Documents | #Terms | #Document clusters | Sparsity (%) |
| ACM [13] | 3025 | 1870 | 3 | 95.52 |
| DBLP [13] | 4057 | 334 | 4 | 96.4 |
| PubMed [32] | 19717 | 500 | 3 | 89.98 |
| Wiki [37] | 2405 | 4973 | 17 | 86.99 |
| Ohscal [22] | 11162 | 11465 | 10 | 99.47 |
| 20 Newsgroups [26] | 18846 | 14390 | 20 | 99.41 |
+
+# 5.2 Experimental Setup
+
+In our experiments we define the loss function as $L(\mathbf{B}) = -c\mathbf{B}$ , where $c$ is selected from $\{1, k, d, n\}$ . For BCOT $\lambda$ , the regularization parameter lambda is selected from $\{10^{-4}, 10^{-3}, 10^{-2}, 10^{-1}, 1, 10\}$ . The best hyper-parameters are those that minimize the number of empty clusters. In the case of ties, we select according to the value of the Davies-Bouldin index of the partition [7]. Random restarts are not used for any of the algorithms, including $k$ -means. We use the implementation provided by the authors for CCOT, CCOT $\lambda$ and CCOT-GW. The code for CCOT was not available, and so we had to implement it based on the code for CCOT-GW. All the reported figures are the averages of 10 runs.
+
+All the experiments were performed on the same machine with an Intel(R) Xeon(R) CPU and 12GB RAM. For OT solvers we made use of the POT package [15].
+
+# 5.3 Document Clustering
+
+Metrics. Here, the evaluation is straightforward, we adopt three popular clustering metrics: clustering accuracy (CA), normalized mutual information (NMI) [4], adjusted rand index (ARI) [24].
+
+Table 3: Document clustering performance on the four datasets. OOM denotes out of memory.
+
+| Method | ACM | DBLP | PubMed | Wiki |
| CA | NMI | ARI | CA | NMI | ARI | CA | NMI | ARI | CA | NMI | ARI |
| k-Means | 51.1±11.3 | 13.7±11.2 | 14.0±10.6 | 36.9±2.4 | 10.4±2.0 | 4.3±2.0 | 52.3±4.7 | 18.2±10.5 | 15.3±10.1 | 26.0±6.1 | 18.6±9.3 | 3.3±2.9 |
| CCOT | 12.4±2.0 | 1.0±0.2 | 0.4±0.2 | 28.6±0.5 | 0.6±0.0 | 0.4±0.0 | 32.7±0.2 | 3.0±0.0 | 3.1±0.1 | 10.6±0.5 | 4.9±0.1 | 0.6±0.15 |
| CCOT-GW | 8.1±0.0 | 1.5±0.0 | 0.3±0.0 | 9.4±0.0 | 1.7±0.0 | 0.3±0.0 | | OOM | | 10.9±0.0 | 4.3±0.0 | 0.48±0.0 |
| COOT* | 39.0±0.0 | 1.9±0.0 | 2.0±0.0 | 30.5±1.4 | 1.4±0.3 | 1.2±0.3 | 43.2±1.5 | 1.7±0.6 | 1.3±1.5 | 25.9±1.8 | 28.7±2.2 | 12.3±1.7 |
| COOTλ | 41.5±0.2 | 1.9±0.1 | 2.2±0.0 | 30.6±0.0 | 0.7±0.0 | 0.6±0.0 | 42.4±1.5 | 1.7±0.5 | 1.0±1.3 | 17.2±0.0 | 1.7±0.0 | 0.31±0.0 |
| BCOT | 76.6±1.5 | 38.3±2.2 | 43.3±2.6 | 61.5±6.2 | 27.4±4.3 | 28.3±5.5 | 53.6±4.5 | 15.9±1.9 | 12.9±2.4 | 49.8±1.5 | 47.9±1.0 | 30.6±1.0 |
| BCOTλ | 76.2±0.6 | 37.6±0.8 | 42.4±1.0 | 59.4±9.9 | 26.6±7.6 | 27.2±9.5 | 56.5±3.1 | 18.4±1.3 | 15.4±1.8 | 50.8±1.5 | 49.4±0.9 | 31.9±0.8 |
+
+Performance. Document clustering results on ACM, DBLP, PubMed and Wiki are given in table 3 for the three metrics. In all cases the best result is obtained either by BCOT or by $\mathrm{BCOT}_{\lambda}$ . Moreover, on Wiki, $\mathrm{BCOT}_{\lambda}$ gives competitive results when compared with state-of-the-art attributed graph clustering methods presented in [14], despite not having access to the graph structure information in the Wiki citation network.
+
+Efficiency. Figure 3 plots the document clustering performance (accuracy against training time) of the different methods on the two large-scale document-term matrices 20 Newsgroup and Ohscal. BCOT offers the best accuracy while $\mathrm{BCOT}_{\lambda}$ is fastest method on both datasets. We see that for both BCOT and COOT, the entropic-regularized versions outspeed their exact counterparts and that CCOT suffers from very high computation times, due mainly to the fact that this method requires pairwise distance matrices to be computed on the rows and columns.
+
+
+(a) 20 Newsgroups.
+
+
+(b) Ohscal.
+Figure 3: Accuracy against training time on NG20 and Ohscal. $\mathrm{BCOT}_{\lambda}$ is the fastest and has a competitive level of accuracy. BCOT gives the best accuracy while remaining relatively efficient. The multiplication factors shown for the training times take $\mathrm{BCOT}_{\lambda}$ as the reference (and so, for example, $\times 4.5$ shown for BCOT means that it is approximately 4.5 times slower than $\mathrm{BCOT}_{\lambda}$ ). We were not able to benchmark CCOT-GW since it failed to scale to these datasets.
+
+# 5.4 Term Clustering
+
+Metrics. Unlike document clustering, there is no ground truth partition for terms, so we need to find another way of evaluating term clustering results. One generally acceptable technique is to analyse the semantic coherence of the clusters obtained. To this end we introduce a metric
+
+based on point mutual information (PMI). PMI is a frequently used information-theoretic metric for quantifying the relationship between pairs of discrete random variable outcomes. The PMI measure was chosen because prior research [29] has shown that it is closely associated with human judgements in determining word relatedness. The PMI between the terms $w_{i}$ and $w_{j}$ is calculated as
+
+$$
+\operatorname {P M I} \left(w _ {i}, w _ {j}\right) = \log \frac {p \left(w _ {i} , w _ {j}\right)}{p \left(w _ {i}\right) p \left(w _ {j}\right)} \tag {13}
+$$
+
+In the context of term clustering, given the word co-occurrence matrix $\mathbf{K} = \mathbf{B}^{\top}\mathbf{B}$ , the PMI is estimated as in
+
+$$
+\operatorname {P M I} \left(w _ {i}, w _ {j}\right) = \log \frac {k _ {\cdot \cdot} k _ {i j}}{k _ {i .} k _ {. j}} \tag {14}
+$$
+
+To evaluate a partition of terms $\mathcal{P}$ , we propose a metric based on intra and inter PMI metrics as follows:
+
+$$
+\operatorname {P M I} _ {\text {i n t r a}} (P) = \sum_ {i \in P} \sum_ {j \in P} k _ {i j} \quad \tag {16}
+$$
+
+In this way, a good clustering should reveal a high intra-cluster semantic relatedness, corresponding to higher PMI values. Using the intra and inter PMIs, we propose the following coherence index
+
+$$
+\operatorname {c o h e r e n c e} (\mathcal {P}) = \frac {1}{\sum_ {P \in \mathcal {P}} | P |} \sum_ {P \in \mathcal {P}} | P | \left(\mathrm {P M I} _ {\text {i n t r a}} (P) - \mathrm {P M I} _ {\text {i n t e r}} (P)\right). \tag {17}
+$$
+
+Our reasoning is this: the greater the semantic proximity between terms in the same clusters, and the greater the semantic distance between terms in different clusters, the higher the value of coherence.
+
+Results. Since there is no ground truth number of term clusters, we use the cluster number estimations produced by CCOT-GW for all the other models so that it is easy to compare coherence values between them. Comparisons based on different numbers of clusters would favor the model using the larger number of clusters. Table 4 shows the coherences obtained across the different datasets using our approach, along with those of the baselines. It is clear that BCOT succeeds in capturing more semantics than the other approaches since, whatever the dataset, one or other of the two BCOT variants gives the highest coherence.
+
+Table 4: Term clustering performance on the four datasets. OOM denotes out of memory.
+
+| Method | ACM | DBLP | PubMed | Wiki | Ng20 | Ohscal |
| k-Means | 0.19±0.01 | 0.05±0.03 | 0.31±0.18 | 0.28±0.02 | 0.28±0.04 | 0.01±0.02 |
| CCOT | 0.03±0.00 | -0.07±0.06 | 0.02±0.01 | 0.02±0.00 | 0.05±0.00 | 0.06±0.00 |
| CCOT-GW | 0.08±0.00 | 0.03±0.00 | OOM | 0.01±0.00 | OOM | OOM |
| COOT | 0.12±0.01 | 0.07±0.00 | 0.14±0.01 | 0.40±0.00 | 0.43±0.02 | 0.23±0.01 |
| COOTλ | 0.21±0.00 | 0.04±0.00 | -0.00±0.00 | -0.08±0.00 | -0.02±0.00 | -0.13±0.00 |
| BCOT | 0.27±0.01 | 0.22±0.04 | 0.54±0.03 | 0.64±0.01 | 0.79±0.01 | 0.44±0.00 |
| BCOTλ | 0.24±0.00 | 0.16±0.02 | 0.57±0.01 | 0.62±0.01 | 0.27±0.01 | 0.35±0.00 |
+
+# 5.5 Statistical Significance
+
+We performed a Nemenyi post-hoc test [28, 8] with a confidence level of $90\%$ on the document and term clustering results that we obtained, to determine whether our model outperforms other OT biclustering approaches in a statistically significant way. To conduct this test we generated 20 performance rankings of the OT biclustering models based on their performance for each dataset and quality metric pair for both document and term clustering. Figure 4 shows the results of the test. We see that two differently performing groups were identified, one comprising BCOT and $\mathrm{BCOT}_{\lambda}$ and giving better results than the other group comprising the remaining COOT and CCOT variants. This indicates that with this specific number of datasets and metrics the test was unable to tell COOT and CCOT apart in a statistically significant way.
+
+
+Figure 4: Result of the Nemenyi post hoc test.
+
+# 6 Conclusion
+
+Clustering and biclustering through optimal transport is still at a nascent stage, with many challenges remaining unsolved. This paper introduces a novel problem for biclustering using optimal transport that takes into account the sparse nature of certain types of dyadic data such document-term matrices, to enable more computationally efficient resolution. The problem is posed as a bilinear program that we solve using an efficient block coordinate descent algorithm to find a vertex solution. Experiments on a number of document-term datasets suggest that the proposed approach does a good job in finding clusters that correspond to ground truth document classes, while generating semantically coherent partitions for the terms. In this setting, our model outperforms recent OT biclustering methods by a significant margin, while being more computationally efficient.
+
+# Acknowledgments and Disclosure of Funding
+
+This work has been funded by Informatique Caisse des Dépôts et Consignations (ICDC), Association Nationale de la Recherche et de la Technologie (ANRT), and Idex-Spectrans of Université Paris Cité.
+
+# References
+
+[1] Severine Affeldt, Lazhar Labiod, and Mohamed Nadif. Regularized bi-directional co-clustering. Statistics and Computing, 31(3):1-17, 2021.
+[2] Nir Ailon, Noa Avigdor-Elgrabli, Edo Liberty, and Anke Van Zuylen. Improved approximation algorithms for bipartite correlation clustering. SIAM Journal on Computing, 41(5):1110-1121, 2012.
+[3] Michael J Barber. Modularity and community detection in bipartite networks. Physical Review E, 76(6):066102, 2007.
+[4] Deng Cai, Xiaofei He, Xiaoyun Wu, and Jiawei Han. Non-negative matrix factorization on manifold. In 2008 eighth IEEE international conference on data mining, pages 63-72. IEEE, 2008.
+[5] Lenaic Chizat, Pierre Roussillon, Flavien Léger, François-Xavier Vialard, and Gabriel Peyré. Faster Wasserstein distance estimation with the sinkhorn divergence. Advances in Neural Information Processing Systems, 33:2257-2269, 2020.
+[6] Marco Cuturi. Sinkhorn distances: Lightspeed computation of optimal transport. Advances in neural information processing systems, 26, 2013.
+[7] David L Davies and Donald W Bouldin. A cluster separation measure. IEEE transactions on pattern analysis and machine intelligence, (2):224-227, 1979.
+[8] Janez Demšar. Statistical comparisons of classifiers over multiple data sets. The Journal of Machine Learning Research, 7:1-30, 2006.
+[9] Inderjit S Dhillon. Co-clustering documents and words using bipartite spectral graph partitioning. In Proceedings of the seventh ACM SIGKDD international conference on Knowledge discovery and data mining, pages 269-274, 2001.
+
+[10] Inderjit S Dhillon, Subramanyam Mallela, and Dharmendra S Modha. Information-theoretic co-clustering. In Proceedings of the ninth ACM SIGKDD international conference on Knowledge discovery and data mining, pages 89–98, 2003.
+[11] Sara Dolnicar, Sebastian Kaiser, Katie Lazarevski, and Friedrich Leisch. Biclustering: Overcoming data dimensionality problems in market segmentation. Journal of Travel Research, 51 (1):41-49, 2012.
+[12] Michael B Eisen, Paul T Spellman, Patrick O Brown, and David Botstein. Cluster analysis and display of genome-wide expression patterns. Proceedings of the National Academy of Sciences, 95(25):14863-14868, 1998.
+[13] Shaohua Fan, Xiao Wang, Chuan Shi, Emiao Lu, Ken Lin, and Bai Wang. One2multi graph autoencoder for multi-view graph clustering. In Proceedings of The Web Conference 2020, pages 3070-3076, 2020.
+[14] Chakib Fettal, Lazhar Labiod, and Mohamed Nadif. Efficient graph convolution for joint node representation learning and clustering. In Proceedings of the Fifteenth ACM International Conference on Web Search and Data Mining, pages 289-297, 2022.
+[15] Rémi Flamary, Nicolas Courty, Alexandre Gramfort, Mokhtar Z Alaya, Aurélie Boisbunon, Stanislas Chambon, Laetitia Chapel, Adrien Corenflos, Kilian Fatras, Nemo Fournier, et al. Pot: Python optimal transport. Journal of Machine Learning Research, 22(78):1-8, 2021.
+[16] Aden Forrow, Jan-Christian Hütter, Mor Nitzan, Philippe Rigollet, Geoffrey Schiebinger, and Jonathan Weed. Statistical optimal transport via factored couplings. In The 22nd International Conference on Artificial Intelligence and Statistics, pages 2454-2465. PMLR, 2019.
+[17] Gérard Govaert and Mohamed Nadif. Co-clustering: models, algorithms and applications. John Wiley & Sons, 2013.
+[18] Gérard Govaert and Mohamed Nadif. Mutual information, phi-squared and model-based co-clustering for contingency tables. Advances in data analysis and classification, 12(3):455-488, 2018.
+[19] Jiajun Gu and Jun S Liu. Bayesian biclustering of gene expression data. BMC genomics, 9(1): 1-10, 2008.
+[20] Rave Harpaz, Hector Perez, Herbert S Chase, Raul Rabadan, George Hripcsak, and Carol Friedman. Biclustering of adverse drug events in the fda's spontaneous reporting system. Clinical Pharmacology & Therapeutics, 89(2):243-250, 2011.
+[21] John A Hartigan. Direct clustering of a data matrix. Journal of the american statistical association, 67(337):123-129, 1972.
+[22] William Hersh, Chris Buckley, TJ Leone, and David Hickam. Ohsumed: An interactive retrieval evaluation and new large test collection for research. In SIGIR'94, pages 192-201. Springer, 1994.
+[23] Alexandre Hollocou, Thomas Bonald, and Marc Lelarge. Modularity-based sparse soft graph clustering. In The 22nd International Conference on Artificial Intelligence and Statistics, pages 323-332. PMLR, 2019.
+[24] Lawrence Hubert and Phipps Arabie. Comparing partitions. Journal of classification, 2(1): 193-218, 1985.
+[25] Charlotte Laclau, Ievgen Redko, Basarab Matei, Younes Bennani, and Vincent Brault. Co- clustering through optimal transport. In International Conference on Machine Learning, pages 1955-1964. PMLR, 2017.
+[26] Ken Lang. Newsweeder: Learning to filter netnews. In Proceedings of the Twelfth International Conference on Machine Learning, pages 331-339, 1995.
+
+[27] Jean François Marcotorchino. Block seriation problems: A unified approach. reply to the problem of h. garcia and jm proth (applied stochastic models and data analysis, 1,(1), 25-34 (1985)). Applied Stochastic Models and Data Analysis, 3(2):73-91, 1987.
+[28] Peter Bjorn Nemenyi. Distribution-free multiple comparisons. Princeton University, 1963.
+[29] David Newman, Sarvnaz Karimi, and Lawrence Cavedon. External evaluation of topic models. In in Australasian Doc. Comp. Symp., 2009. CiteSeer, 2009.
+[30] Aghiles Salah and Mohamed Nadif. Model-based von mises-fisher co-clustering with a conscience. In Proceedings of the 2017 SIAM International Conference on Data Mining, pages 246-254. SIAM, 2017.
+[31] Meyer Scetbon, Marco Cuturi, and Gabriel Peyré. Low-rank sinkhorn factorization. In International Conference on Machine Learning, pages 9344–9354. PMLR, 2021.
+[32] Prithviraj Sen, Galileo Namata, Mustafa Bilgic, Lise Getoor, Brian Galligher, and Tina Eliassi-Rad. Collective classification in network data. AI magazine, 29(3):93-93, 2008.
+[33] Jonathan Templin, Robert A Henson, et al. Diagnostic measurement: Theory, methods, and applications. Guilford Press, 2010.
+[34] Vayer Titouan, Ievgen Redko, Rémi Flamary, and Nicolas Courty. Co-optimal transport. Advances in Neural Information Processing Systems, 33:17559-17570, 2020.
+[35] Hua Wang, Feiping Nie, Heng Huang, and Fillia Makedon. Fast nonnegative matrix tri-factorization for large-scale data co-clustering. In Twenty-Second International Joint Conference on Artificial Intelligence, 2011.
+[36] Jianfeng Wang, Mei Lu, Francesco Belardo, and Milan Randić. The anti-adjacency matrix of a graph: Eccentricity matrix. Discrete Applied Mathematics, 251:299–309, 2018.
+[37] Cheng Yang, Zhiyuan Liu, Deli Zhao, Maosong Sun, and Edward Y. Chang. Network representation learning with rich text information. In *IJCAI*, 2015.
\ No newline at end of file
diff --git a/efficientandeffectiveoptimaltransportbasedbiclustering/images.zip b/efficientandeffectiveoptimaltransportbasedbiclustering/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..c3567ea3be44b70060c88281cb4dc900d3d2b8ba
--- /dev/null
+++ b/efficientandeffectiveoptimaltransportbasedbiclustering/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4656612713821d3352fc0548a3baf4ee8be0cafb726421e38eced4878bc10fc8
+size 401596
diff --git a/efficientandeffectiveoptimaltransportbasedbiclustering/layout.json b/efficientandeffectiveoptimaltransportbasedbiclustering/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..13d96fa7636d61c973e0ac57b9d9453e85aacba8
--- /dev/null
+++ b/efficientandeffectiveoptimaltransportbasedbiclustering/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5f39c497d04e8216e77af980bcbf1c7cb624a70b6afa0317cd0d48e0a49a7ca6
+size 485351
diff --git a/efficientandmodularimplicitdifferentiation/8e601e2d-7967-4325-bfc9-f13c1545a6e4_content_list.json b/efficientandmodularimplicitdifferentiation/8e601e2d-7967-4325-bfc9-f13c1545a6e4_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..7dd64ad3f13588178244ee7d565acd8c4bbf0bd5
--- /dev/null
+++ b/efficientandmodularimplicitdifferentiation/8e601e2d-7967-4325-bfc9-f13c1545a6e4_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b1188b96172e69adba4e46bea5b4189a7ad41e95b23d8a1b14d5c28341966c30
+size 88032
diff --git a/efficientandmodularimplicitdifferentiation/8e601e2d-7967-4325-bfc9-f13c1545a6e4_model.json b/efficientandmodularimplicitdifferentiation/8e601e2d-7967-4325-bfc9-f13c1545a6e4_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..7649108ae621bd8131c841591c6f3fa654199892
--- /dev/null
+++ b/efficientandmodularimplicitdifferentiation/8e601e2d-7967-4325-bfc9-f13c1545a6e4_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:61da743259a85783f1e1c68adce0fc163e4cb50cd92e0a8a638448f605d7f157
+size 113759
diff --git a/efficientandmodularimplicitdifferentiation/8e601e2d-7967-4325-bfc9-f13c1545a6e4_origin.pdf b/efficientandmodularimplicitdifferentiation/8e601e2d-7967-4325-bfc9-f13c1545a6e4_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..517ab2948c82733d38f070a3478b34ffb5418545
--- /dev/null
+++ b/efficientandmodularimplicitdifferentiation/8e601e2d-7967-4325-bfc9-f13c1545a6e4_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:af384d2c622be95acf532588caaf4022b262e1f6c810ff23ec64e4457480d556
+size 1886406
diff --git a/efficientandmodularimplicitdifferentiation/full.md b/efficientandmodularimplicitdifferentiation/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..66e69fc04888dc61c8b6fd33a3e8ec8ffc16514a
--- /dev/null
+++ b/efficientandmodularimplicitdifferentiation/full.md
@@ -0,0 +1,431 @@
+# Efficient and Modular Implicit Differentiation
+
+Mathieu Blondel, Quentin Berthet, Marco Cuturi* Roy Frostig, Stephan Hoyer, Felipe Llinares-López, Fabian Pedregosa, Jean-Philippe Vert* Google Research
+
+# Abstract
+
+Automatic differentiation (autodiff) has revolutionized machine learning. It allows to express complex computations by composing elementary ones in creative ways and removes the burden of computing their derivatives by hand. More recently, differentiation of optimization problem solutions has attracted widespread attention with applications such as optimization layers, and in bi-level problems such as hyper-parameter optimization and meta-learning. However, so far, implicit differentiation remained difficult to use for practitioners, as it often required case-by-case tedious mathematical derivations and implementations. In this paper, we propose automatic implicit differentiation, an efficient and modular approach for implicit differentiation of optimization problems. In our approach, the user defines directly in Python a function $F$ capturing the optimality conditions of the problem to be differentiated. Once this is done, we leverage autodiff of $F$ and the implicit function theorem to automatically differentiate the optimization problem. Our approach thus combines the benefits of implicit differentiation and autodiff. It is efficient as it can be added on top of any state-of-the-art solver and modular as the optimality condition specification is decoupled from the implicit differentiation mechanism. We show that seemingly simple principles allow to recover many existing implicit differentiation methods and create new ones easily. We demonstrate the ease of formulating and solving bi-level optimization problems using our framework. We also showcase an application to the sensitivity analysis of molecular dynamics.
+
+# 1 Introduction
+
+Automatic differentiation (autodiff) is now an inherent part of machine learning software. It allows to express complex computations by composing elementary ones in creative ways and removes the tedious burden of computing their derivatives by hand. In parallel, the differentiation of optimization problem solutions has found many applications. A classical example is bi-level optimization, which typically involves computing the derivatives of a nested optimization problem in order to solve an outer one. Examples of applications in machine learning include hyper-parameter optimization [23, 77, 70, 38, 12, 13], neural networks [59], and meta-learning [39, 72]. Another line of active research involving differentiation of optimization problem solutions are optimization layers [55, 6, 65, 31, 46], which can be used to encourage structured outputs, and implicit deep networks [8, 36, 43, 44, 73], which have a smaller memory footprint than backprop-trained networks.
+
+Since optimization problem solutions typically do not enjoy an explicit formula in terms of their inputs, autodiff cannot be used directly to differentiate these functions. In recent years, two main approaches have been developed to circumvent this problem. The first one consists of unrolling the iterations of an optimization algorithm and using the final iteration as a proxy for the optimization problem solution [83, 32, 29, 39, 1]. This allows to explicitly construct a computational graph relating the algorithm output to the inputs, on which autodiff can then be used transparently. However, this requires a reimplementation of the algorithm using the autodiff system, and not all algorithms
+
+are necessarily autodiff friendly. Moreover, forward-mode autodiff has time complexity that scales linearly with the number of variables and reverse-mode autodiff has memory complexity that scales linearly with the number of algorithm iterations. In contrast, a second approach consists in implicitly relating an optimization problem solution to its inputs using optimality conditions. In a machine learning context, such implicit differentiation has been used for stationarity conditions [11, 59], KKT conditions [23, 45, 6, 67, 66] and the proximal gradient fixed point [65, 12, 13]. An advantage of implicit differentiation is that a solver reimplementation is not needed, allowing to build upon decades of state-of-the-art software. Although implicit differentiation has a long history in numerical analysis [48, 10, 57, 20], so far, it remained difficult to use for practitioners, as it required a case-by-case tedious mathematical derivation and implementation. CasADI [7] allows to differentiate various optimization and root finding problem algorithms provided by the library. However, it does not allow to easily add implicit differentiation on top of existing solvers from optimality conditions expressed by the user, as we do. A recent tutorial explains how to implement implicit differentiation in JAX [34]. However, the tutorial requires the user to take care of low-level technical details and does not cover a large catalog of optimality condition mappings as we do. Other work [2] attempts to address this issue by adding implicit differentiation on top of cvxpy [30]. This works by reducing all convex optimization problems to a conic program and using conic programming's optimality conditions to derive an implicit differentiation formula. While this approach is very generic, solving a convex optimization problem using a conic programming solver—an ADMM-based splitting conic solver [68] in the case of cvxpy—is rarely state-of-the-art for every problem instance.
+
+In this work, we ambition to achieve for optimization problem solutions what autodiff did for computational graphs. We propose automatic implicit differentiation, a simple approach to add implicit differentiation on top of any existing solver. In this approach, the user defines directly in Python a mapping function $F$ capturing the optimality conditions of the problem solved by the algorithm. Once this is done, we leverage autodiff of $F$ combined with the implicit function theorem to automatically differentiate the optimization problem solution. Our approach is generic, yet it can exploit the efficiency of state-of-the-art solvers. It therefore combines the benefits of implicit differentiation and autodiff. To summarize, we make the following contributions.
+
+- We describe our framework and its JAX [21, 42] implementation (https://github.com/google/jaxopt/). Our framework significantly lowers the barrier to use implicit differentiation, thanks to the seamless integration in JAX, with low-level details all abstracted away.
+- We instantiate our framework on a large catalog of optimality conditions (Table 1), recovering existing schemes and obtaining new ones, such as the mirror descent fixed point based one.
+- On the theoretical side, we provide new bounds on the Jacobian error when the optimization problem is only solved approximately, and empirically validate them.
+- We implement four illustrative applications, demonstrating our framework's ease of use.
+
+Beyond our software implementation in JAX, we hope this paper provides a self-contained blueprint for creating an efficient and modular implementation of implicit differentiation in other frameworks.
+
+Notation. We denote the gradient and Hessian of $f\colon \mathbb{R}^d\to \mathbb{R}$ evaluated at $x\in \mathbb{R}^d$ by $\nabla f(x)\in \mathbb{R}^{d}$ and $\nabla^2 f(x)\in \mathbb{R}^{d\times d}$ . We denote the Jacobian of $F\colon \mathbb{R}^d\to \mathbb{R}^p$ evaluated at $x\in \mathbb{R}^d$ by $\partial F(x)\in \mathbb{R}^{p\times d}$ . When $f$ or $F$ have several arguments, we denote the gradient, Hessian and Jacobian in the $i^{\mathrm{th}}$ argument by $\nabla_{i}$ , $\nabla_i^2$ and $\partial_i$ , respectively. The standard probability simplex is denoted by $\triangle^d\coloneqq \{x\in \mathbb{R}^d\colon \| x\| _1 = 1,x\geq 0\}$ . For any set $\mathcal{C}\subset \mathbb{R}^d$ , we denote the indicator function $I_{\mathcal{C}}\colon \mathbb{R}^d\to \mathbb{R}\cup \{+\infty \}$ where $I_{\mathcal{C}}(x) = 0$ if $x\in \mathcal{C}$ , $I_{\mathcal{C}}(x) = +\infty$ otherwise. For a vector or matrix $A$ , we note $\| A\|$ the Frobenius (or Euclidean) norm, and $\| A\|_{\mathrm{op}}$ the operator norm.
+
+# 2 Automatic implicit differentiation
+
+# 2.1 General principles
+
+Overview. Contrary to autodiff through unrolled algorithm iterations, implicit differentiation typically involves a manual, sometimes complicated, mathematical derivation. For instance, numerous works [23, 45, 6, 67, 66] use Karush-Kuhn-Tucker (KKT) conditions in order to relate a constrained optimization problem's solution to its inputs, and to manually derive a formula for its derivatives. The derivation and implementation in these works are typically case-by-case.
+
+```python
+X_train, y_train = load_data() # Load features and labels
+def f(x, theta): # Objective function
+residual = jnp.dot(X_train, x) - y_train
+return (jnp.sum(residual ** 2) + theta * jnp.sum(x ** 2)) / 2
+# Since f is differentiable and unconstrained, the optimality # condition F is simply the gradient of f in the 1st argument F = jax.grad(f, argnums=0)
+@custom_root(F)
+def ridgeSolver(init_x, theta):
+ del init_x # Initialization not used in this solver
+XX = jnp.dot(X_train.T, X_train)
+Xy = jnp.dot(X_train.T, y_train)
+I = jnp.eye(X_train.shape[1]) # Identity matrix
+# Finds the ridge reg solution by solving a linear system
+return jnp.linalg.solve(XX + theta * I, Xy)
+init_x = None
+print(jax.jacobian(ridgeSolver, argnums=1)(init_x, 10.0))
+```
+
+Figure 1: Adding implicit differentiation on top of a ridge regression solver. The function $f(x, \theta)$ defines the objective function and the mapping $F$ , here simply equation (4), captures the optimality conditions. Our decorator @custom_root automatically adds implicit differentiation to the solver for the user, overriding JAX's default behavior. The last line evaluates the Jacobian at $\theta = 10$ .
+
+In this work, we propose a generic way to easily add implicit differentiation on top of existing solvers. In our approach, the user defines directly in Python a mapping function $F$ capturing the optimality conditions of the problem solved by the algorithm. We provide reusable building blocks to easily express such $F$ . The provided $F$ is then plugged into our Python decorator @custom_root, which we append on top of the solver declaration we wish to differentiate. Under the hood, we combine the implicit function theorem and autodiff of $F$ to automatically differentiate the optimization problem solution. A simple illustrative example is given in Figure 1.
+
+Differentiating a root. Let $F \colon \mathbb{R}^d \times \mathbb{R}^n \to \mathbb{R}^d$ be a user-provided mapping, capturing the optimality conditions of a problem. An optimal solution, denoted $x^\star(\theta)$ , should be a root of $F$ :
+
+$$
+F (x ^ {\star} (\theta), \theta) = 0. \tag {1}
+$$
+
+We can see $x^{\star}(\theta)$ as an implicitly defined function of $\theta \in \mathbb{R}^n$ , i.e., $x^{\star} \colon \mathbb{R}^{n} \to \mathbb{R}^{d}$ . More precisely, from the implicit function theorem [48, 57], we know that for $(x_0, \theta_0)$ satisfying $F(x_0, \theta_0) = 0$ with a continuously differentiable $F$ , if the Jacobian $\partial_{1}F$ evaluated at $(x_0, \theta_0)$ is a square invertible matrix, then there exists a function $x^{\star}(\cdot)$ defined on a neighborhood of $\theta_0$ such that $x^{\star}(\theta_0) = x_0$ . Furthermore, for all $\theta$ in this neighborhood, we have that $F(x^{\star}(\theta), \theta) = 0$ and $\partial x^{\star}(\theta)$ exists. Using the chain rule, the Jacobian $\partial x^{\star}(\theta)$ satisfies
+
+$$
+\partial_ {1} F (x ^ {\star} (\theta), \theta) \partial x ^ {\star} (\theta) + \partial_ {2} F (x ^ {\star} (\theta), \theta) = 0.
+$$
+
+Computing $\partial x^{\star}(\theta)$ therefore boils down to the resolution of the linear system of equations
+
+$$
+\underbrace {- \partial_ {1} F (x ^ {\star} (\theta) , \theta)} _ {A \in \mathbb {R} ^ {d \times d}} \underbrace {\partial x ^ {\star} (\theta)} _ {J \in \mathbb {R} ^ {d \times n}} = \underbrace {\partial_ {2} F (x ^ {\star} (\theta) , \theta)} _ {B \in \mathbb {R} ^ {d \times n}}. \tag {2}
+$$
+
+When (1) is a one-dimensional root finding problem ( $d = 1$ ), (2) becomes particularly simple since we then have $\nabla x^{\star}(\theta) = B^{\top} / A$ , where $A$ is a scalar value.
+
+We will show that existing and new implicit differentiation methods all reduce to this simple principle. We call our approach automatic implicit differentiation as the user can freely express the optimization solution to be differentiated through the optimality conditions $F$ . Our approach is efficient as it can be added on top of any state-of-the-art solver and modular as the optimality condition specification is decoupled from the implicit differentiation mechanism. This contrasts with existing works, where the derivation and implementation are specific to each optimality condition.
+
+Differentiating a fixed point. We will encounter numerous applications where $x^{\star}(\theta)$ is instead implicitly defined through a fixed point:
+
+$$
+x ^ {\star} (\theta) = T (x ^ {\star} (\theta), \theta),
+$$
+
+where $T\colon \mathbb{R}^d\times \mathbb{R}^n\to \mathbb{R}^d$ . This can be seen as a particular case of (1) by defining the residual
+
+$$
+F (x, \theta) = T (x, \theta) - x. \tag {3}
+$$
+
+In this case, when $T$ is continuously differentiable, using the chain rule, we have
+
+$$
+A = - \partial_ {1} F (x ^ {\star} (\theta), \theta) = I - \partial_ {1} T (x ^ {\star} (\theta), \theta) \quad \text {a n d} \quad B = \partial_ {2} F (x ^ {\star} (\theta), \theta) = \partial_ {2} T (x ^ {\star} (\theta), \theta).
+$$
+
+Computing JVPs and VJPs. In most practical scenarios, it is not necessary to explicitly form the Jacobian matrix, and instead it is sufficient to left-multiply or right-multiply by $\partial_1F$ and $\partial_2F$ . These are called vector-Jacobian product (VJP) and Jacobian-vector product (JVP), and are useful for integrating $x^{\star}(\theta)$ with reverse-mode and forward-mode autodiff, respectively. Oftentimes, $F$ will be explicitly defined. In this case, computing the VJP or JVP can be done via autodiff. In some cases, $F$ may itself be implicitly defined, for instance when $F$ involves the solution of a variational problem. In this case, computing the VJP or JVP will itself involve implicit differentiation.
+
+The right-multiplication (JVP) between $J = \partial x^{\star}(\theta)$ and a vector $v, Jv$ , can be computed efficiently by solving $A(Jv) = Bv$ . The left-multiplication (VJP) of $v^\top$ with $J, v^\top J$ , can be computed by first solving $A^\top u = v$ . Then, we can obtain $v^\top J$ by $v^\top J = u^\top AJ = u^\top B$ . Note that when $B$ changes but $A$ and $v$ remain the same, we do not need to solve $A^\top u = v$ once again. This allows to compute the VJP w.r.t. different variables while solving only one linear system.
+
+To solve these linear systems, we can use the conjugate gradient method [51] when $A$ is symmetric positive semi-definite and GMRES [75] or BiCGSTAB [81] otherwise. These algorithms are all matrix-free: they only require matrix-vector products. Thus, all we need from $F$ is its JVPs or VJPs. An alternative to GMRES/BiCGSTAB is to solve the normal equation $AA^{\top}u = Av$ using conjugate gradient. This can be implemented using JAX's transpose routine jax-linear_transpose [41]. In case of non-invertibility, a common heuristic is to solve a least squares $\min_{J}\| AJ - B\|^2$ instead.
+
+Pre-processing and post-processing mappings. Oftentimes, the goal is not to differentiate $\theta$ per se, but the parameters of a function producing $\theta$ . One example of such pre-processing is to convert the parameters to be differentiated from one form to another canonical form, such as a quadratic program [6] or a conic program [2]. Another example is when $x^{\star}(\theta)$ is used as the output of a neural network layer, in which case $\theta$ is produced by the previous layer. Likewise, $x^{\star}(\theta)$ will often not be the final output we want to differentiate. One example of such post-processing is when $x^{\star}(\theta)$ is the solution of a dual program and we apply the dual-primal mapping to recover the solution of the primal program. Another example is the application of a loss function, in order to reduce $x^{\star}(\theta)$ to a scalar value. We leave the differentiation of such pre/post-processing mappings to the autodiff system, allowing to compose functions in complex ways.
+
+Implementation details. When a solver function is decorated with @custom_root, we use jax(custom_jvp and jax(custom_vjp to automatically add custom JVP and VJP rules to the function, overriding JAX's default behavior. As mentioned above, we use linear system solvers based on matrix-vector products and therefore we only need access to $F$ through the JVP or VJP with $\partial_1F$ and $\partial_2F$ . This is done by using jax.jvp and jax.vjp, respectively. Note that, as in Figure 1, the definition of $F$ will often include a gradient mapping $\nabla_{1}f(x,\theta)$ . Thankfully, JAX supports second-order derivatives transparently. For convenience, our library also provides a @custom_fixated_point decorator, for adding implicit differentiation on top of a solver, given a fixed point iteration $T$ ; see code examples in Appendix B.
+
+# 2.2 Examples
+
+We now give various examples of mapping $F$ or fixed point iteration $T$ , recovering existing implicit differentiation methods and creating new ones. Each choice of $F$ or $T$ implies different trade-offs in terms of computational oracles; see Table 1. Source code examples are given in Appendix B.
+
+Stationary point condition. The simplest example is to differentiate through the implicit function
+
+$$
+x^{\star}(\theta) = \operatorname *{argmin}_{x\in \mathbb{R}^{d}}f(x,\theta),
+$$
+
+where $f\colon \mathbb{R}^d\times \mathbb{R}^n\to \mathbb{R}$ is twice differentiable, $\nabla_1f$ is continuously differentiable, and $\nabla_1^2 f$ is invertible at $(x^{\star}(\theta),\theta)$ . In this case, $F$ is simply the gradient mapping
+
+$$
+F (x, \theta) = \nabla_ {1} f (x, \theta). \tag {4}
+$$
+
+Table 1: Summary of optimality condition mappings. Oracles are accessed through their JVP or VJP.
+
+| Name | Equation | Solution needed | Oracle |
| Stationary | (4), (5) | Primal | ∇1f |
| KKT | (6) | Primal and dual | ∇1f, H, G, ∂1H, ∂1G |
| Proximal gradient | (7) | Primal | ∇1f, proxηg |
| Projected gradient | (9) | Primal | ∇1f, projC |
| Mirror descent | (13) | Primal | ∇1f, projC, ∇φ |
| Newton | (14) | Primal | [∇12f(x,θ)]-1, ∇1f(x,θ) |
| Block proximal gradient | (15) | Primal | [∇1f]j, [proxηg]j |
| Conic programming | (18) | Residual map root | projRP×KC*×R+ |
+
+We then have $\partial_1F(x,\theta) = \nabla_1^2 f(x,\theta)$ and $\partial_2F(x,\theta) = \partial_2\nabla_1f(x,\theta)$ , the Hessian of $f$ in its first argument and the Jacobian in the second argument of $\nabla_1f(x,\theta)$ . In practice, we use autodiff to compute Jacobian products automatically. Equivalently, we can use the gradient descent fixed point
+
+$$
+T (x, \theta) = x - \eta \nabla_ {1} f (x, \theta), \tag {5}
+$$
+
+for all $\eta > 0$ . Using (3), it is easy to check that we obtain the same linear system since $\eta$ cancels out.
+
+KKT conditions. As a more advanced example, we now show that the KKT conditions, manually differentiated in several works [23, 45, 6, 67, 66], fit our framework. As we will see, the key will be to group the optimal primal and dual variables as our $x^{\star}(\theta)$ . Let us consider the general problem
+
+$$
+\operatorname * {a r g m i n} _ {z \in \mathbb {R} ^ {p}} f (z, \theta) \quad \text {s u b j e c t t o} \quad G (z, \theta) \leq 0, H (z, \theta) = 0,
+$$
+
+where $z \in \mathbb{R}^p$ is the primal variable, $f \colon \mathbb{R}^p \times \mathbb{R}^n \to \mathbb{R}$ , $G \colon \mathbb{R}^p \times \mathbb{R}^n \to \mathbb{R}^r$ and $H \colon \mathbb{R}^p \times \mathbb{R}^n \to \mathbb{R}^q$ are twice differentiable convex functions, and $\nabla_1 f$ , $\partial_1 G$ and $\partial_1 H$ are continuously differentiable. The stationarity, primal feasibility and complementary slackness conditions give
+
+$$
+\nabla_ {1} f (z, \theta) + [ \partial_ {1} G (z, \theta) ] ^ {\top} \lambda + [ \partial_ {1} H (z, \theta) ] ^ {\top} \nu = 0
+$$
+
+$$
+H (z, \theta) = 0
+$$
+
+$$
+\lambda \circ G (z, \theta) = 0, \tag {6}
+$$
+
+where $\nu \in \mathbb{R}^q$ and $\lambda \in \mathbb{R}_+^r$ are the dual variables, also known as KKT multipliers. The primal and dual feasibility conditions can be ignored almost everywhere [34]. The system of (potentially nonlinear) equations (6) fits our framework, as we can group the primal and dual solutions as $x^{\star}(\theta) = (z^{\star}(\theta),\nu^{\star}(\theta),\lambda^{\star}(\theta))$ to form the root of a function $F(x^{\star}(\theta),\theta)$ , where $F\colon \mathbb{R}^{d}\times \mathbb{R}^{n}\to \mathbb{R}^{d}$ and $d = p + q + r$ . The primal and dual solutions can be obtained from a generic solver, such as an interior point method. In practice, the above mapping $F$ will be defined directly in Python (see Figure 7 in Appendix B) and $F$ will be differentiated automatically via autodiff.
+
+Proximal gradient fixed point. Unfortunately, not all algorithms return both primal and dual solutions. Moreover, if the objective contains non-smooth terms, proximal gradient descent may be more efficient. We now discuss its fixed point [65, 12, 13]. Let $x^{\star}(\theta)$ be implicitly defined as
+
+$$
+x^{\star}(\theta):= \operatorname *{argmin}_{x\in \mathbb{R}^{d}}f(x,\theta) + g(x,\theta),
+$$
+
+where $f\colon \mathbb{R}^d\times \mathbb{R}^n\to \mathbb{R}$ is twice-differentiable convex and $g\colon \mathbb{R}^d\times \mathbb{R}^n\to \mathbb{R}$ is convex but possibly non-smooth. Let us define the proximity operator associated with $g$ by
+
+$$
+\operatorname {p r o x} _ {g} (y, \theta) := \operatorname * {a r g m i n} _ {x \in \mathbb {R} ^ {d}} \frac {1}{2} \| x - y \| _ {2} ^ {2} + g (x, \theta).
+$$
+
+To implicitly differentiate $x^{\star}(\theta)$ , we use the fixed point mapping [69, p.150]
+
+$$
+T (x, \theta) = \operatorname {p r o x} _ {\eta g} (x - \eta \nabla_ {1} f (x, \theta), \theta), \tag {7}
+$$
+
+for any step size $\eta > 0$ . The proximity operator is 1-Lipschitz continuous [64]. By Rademacher's theorem, it is differentiable almost everywhere. If, in addition, it is continuously differentiable in a neighborhood of $(x^{\star}(\theta), \theta)$ and if $I - \partial_1 T(x^{\star}(\theta), \theta)$ is invertible, then our framework to differentiate $x^{\star}(\theta)$ applies. Similar assumptions are made in [13]. Many proximity operators enjoy a closed form and can easily be differentiated, as discussed in Appendix C. An implementation is given in Figure 2.
+
+```python
+grad = jax.grad(f) # Pre-compile the gradient.
+def T(x, theta):
+ # Unpack the parameters of f and g.
+ theta_f, theta_g = theta
+ # Return the fixed point condition evaluated at x.
+ return prox(x - grad(x, theta_f), theta_g)
+```
+
+Figure 2: Implementation of the proximal gradient fixed point (7) with step size $\eta = 1$ .
+
+Projected gradient fixed point. As a special case, when $g(x,\theta)$ is the indicator function $I_{\mathcal{C}(\theta)}(x)$ , where $\mathcal{C}(\theta)$ is a convex set depending on $\theta$ , we obtain
+
+$$
+x ^ {\star} (\theta) = \underset {x \in \mathcal {C} (\theta)} {\operatorname {a r g m i n}} f (x, \theta). \tag {8}
+$$
+
+The proximity operator $\mathrm{prox}_g$ becomes the Euclidean projection onto $\mathcal{C}(\theta)$
+
+$$
+\operatorname{prox}_{g}(y,\theta) = \operatorname{proj}_{\mathcal{C}}(y,\theta):= \operatorname *{argmin}_{x\in \mathcal{C}(\theta)}\| x - y\|_{2}^{2}
+$$
+
+and (7) becomes the projected gradient fixed point
+
+$$
+T (x, \theta) = \operatorname {p r o j} _ {\mathcal {C}} (x - \eta \nabla_ {1} f (x, \theta), \theta). \tag {9}
+$$
+
+Compared to the KKT conditions, this fixed point is particularly suitable when the projection enjoys a closed form. We discuss how to compute the JVP / VJP for a wealth of convex sets in Appendix C.
+
+Current limitations. While we have not observed issues in practice, we note that the approach developed in this section theoretically only applies to settings where the implicit function theorem is valid, namely, where optimality conditions satisfy the differentiability and invertibility conditions stated in §2.1. While this covers a wide range of situations even for non-smooth optimization problems (e.g., under mild assumptions the solution of a Lasso regression can be differentiated a.e. with respect to the regularization parameter, see Appendix E), an interesting direction for future work is to extend the framework to handle cases where the differentiability and invertibility conditions are not satisfied, using, e.g., the theory of nonsmooth implicit function theorems [25, 19].
+
+# 3 Jacobian precision guarantees
+
+In practice, either by the limitations of finite precision arithmetic or because we perform a finite number of iterations, we rarely reach the exact solution $x^{\star}(\theta)$ . Instead, we reach an approximate solution $\hat{x}$ and apply the implicit differentiation equation (2) at this approximate solution. This motivates the need for precision guarantees of this approach. We introduce the following formalism.
+
+Definition 1. Let $F: \mathbb{R}^d \times \mathbb{R}^n \to \mathbb{R}^d$ be a continuously differentiable optimality criterion mapping. Let $A := -\partial_1 F$ and $B := \partial_2 F$ . We define the Jacobian estimate at $(x, \theta)$ , when $A(x, \theta)$ is invertible, as the solution to the linear equation $A(x, \theta) J(x, \theta) = B(x, \theta)$ . It is a function $J: \mathbb{R}^d \times \mathbb{R}^n \to \mathbb{R}^{d \times n}$ .
+
+It holds by construction that $J(x^{\star}(\theta), \theta) = \partial x^{\star}(\theta)$ . Computing $J(\hat{x}, \theta)$ for an approximate solution $\hat{x}$ of $x^{\star}(\theta)$ therefore allows to approximate the true Jacobian $\partial x^{\star}(\theta)$ . In practice, an algorithm used to solve (1) depends on $\theta$ . Note however that, what we compute is not the Jacobian of $\hat{x}(\theta)$ , unlike works differentiating through unrolled algorithm iterations, but an estimate of $\partial x^{\star}(\theta)$ . We therefore use the notation $\hat{x}$ , leaving the dependence on $\theta$ implicit.
+
+We develop bounds of the form $\| J(\hat{x},\theta) - \partial x^{\star}(\theta)\| < C\| \hat{x} -x^{\star}(\theta)\|$ , hence showing that the error on the estimated Jacobian is at most of the same order as that of $\hat{x}$ as an approximation of $x^{\star}(\theta)$ . These bounds are based on the following main theorem, whose proof is included in Appendix D.
+
+Theorem 1. Let $F:\mathbb{R}^d\times \mathbb{R}^n\to \mathbb{R}^d$ be continuously differentiable. If there are $\alpha ,\beta ,\gamma ,\varepsilon ,R > 0$ s.t. $A = -\partial_{1}F$ and $B = \partial_2F$ satisfy, for all $v\in \mathbb{R}^d$ $\theta \in \mathbb{R}^n$ and $x$ s.t. $\| x - x^{\star}(\theta)\| \leq \varepsilon$
+
+A is well-conditioned, Lipschitz: $\| A(x,\theta)v\| \geq \alpha \| v\|$ , $\| A(x,\theta) - A(x^{\star}(\theta),\theta)\|_{\mathrm{op}}\leq \gamma \| x - x^{\star}(\theta)\|$
+
+$B$ is bounded and Lipschitz: $\| B(x^{\star}(\theta),\theta)\| \leq R$ , $\| B(x,\theta) - B(x^{\star}(\theta),\theta)\| \leq \beta \| x - x^{\star}(\theta)\|$
+
+Under these conditions, when $\| \hat{x} - x^{\star}(\theta) \| \leq \varepsilon$ , we have
+
+$$
+\left\| J (\hat {x}, \theta) - \partial x ^ {\star} (\theta) \right\| \leq \left(\beta \alpha^ {- 1} + \gamma R \alpha^ {- 2}\right) \| \hat {x} - x ^ {\star} (\theta) \|.
+$$
+
+This result is inspired by [52, Theorem 7.2], that is concerned with the stability of solutions to inverse problems. As a difference, we consider that $A(\cdot, \theta)$ is uniformly well-conditioned, rather than only at $x^{\star}(\theta)$ . This does not affect the first order in $\varepsilon$ of this bound, and makes it valid for all $\hat{x}$ . Our goal with Theorem 1 is to provide a result that works for general $F$ but can be tailored to specific cases.
+
+In particular, for the gradient descent fixed point (5), this yields
+
+$$
+A (x, \theta) = \eta \nabla_ {1} ^ {2} f (x, \theta) \text {a n d} B (x, \theta) = - \eta \partial_ {2} \nabla_ {1} f (x, \theta).
+$$
+
+By specializing Theorem 1 for this fixed point, we obtain Jacobian precision guarantees with conditions directly on $f$ rather than $F$ ; see Corollary 1 in Appendix D. These guarantees hold for instance for the dataset distillation experiment in Section 4. Our analysis reveals in particular that Jacobian estimation by implicit differentiation gains a factor of $t$ compared to automatic differentiation, after $t$ iterations of gradient descent in the strongly-convex setting [1, Proposition 3.2]. While our guarantees concern the Jacobian of $x^{\star}(\theta)$ , we note that other studies [47, 54, 13] give guarantees on hypergradients (i.e., the gradient of an outer objective).
+
+We illustrate these results on ridge regression, where $x^{\star}(\theta) = \operatorname{argmin}_{x} \| \Phi x - y \|_{2}^{2} + \sum_{i} \theta_{i} x_{i}^{2}$ . This problem has the merit that the solution $x^{\star}(\theta)$ and its Jacobian $\partial x^{\star}(\theta)$ are available in closed form. By running gradient descent for $t$ iterations, we obtain an estimate $\hat{x}$ of $x^{\star}(\theta)$ and an estimate $J(\hat{x}, \theta)$ of $\partial x^{\star}(\theta)$ ; cf. Definition 1. By doing so for different numbers of iterations $t$ , we can graph the relation between the error $\| x^{\star}(\theta) - \hat{x} \|_{2}$ and the error $\| \partial x^{\star}(\theta) - J(\hat{x}, \theta) \|_{2}$ , as shown in Figure 3, empirically validating Theorem 1. The results in Figure 3 were obtained using the diabetes dataset from [35], with other datasets yielding a qualitatively similar behavior. We derive similar guarantees in Corollary 2 in Appendix D for proximal gradient descent.
+
+
+Figure 3: Jacobian estimate errors. Empirical error of implicit differentiation follows closely the theoretical upper bound. Unrolling achieves a much worse error for comparable iterate error.
+
+# 4 Experiments
+
+In this section, we demonstrate the ease of solving bi-level optimization problems with our framework. We also present an application to the sensitivity analysis of molecular dynamics.
+
+# 4.1 Hyperparameter optimization of multiclass SVMs
+
+In this example, we consider the hyperparameter optimization of multiclass SVMs [27] trained in the dual. Here, $x^{\star}(\theta)$ is the optimal dual solution, a matrix of shape $m \times k$ , where $m$ is the number of training examples and $k$ is the number of classes, and $\theta \in \mathbb{R}_+$ is the regularization parameter. The challenge in differentiating $x^{\star}(\theta)$ is that each row of $x^{\star}(\theta)$ is constrained to belong to the probability simplex $\triangle^{k}$ . More formally, let $X_{\mathrm{tr}} \in \mathbb{R}^{m \times p}$ be the training feature matrix and $Y_{\mathrm{tr}} \in \{0,1\}^{m \times k}$ be the training labels (in row-wise one-hot encoding). Let $W(x,\theta) \coloneqq X_{\mathrm{tr}}^{\top}(Y_{\mathrm{tr}} - x) / \theta \in \mathbb{R}^{p \times k}$ be the dual-primal mapping. Then, we consider the following bi-level optimization problem
+
+$$
+\underbrace {\min _ {\theta = \exp (\lambda)} \frac {1}{2} \| X _ {\mathrm {v a l}} W (x ^ {\star} (\theta) , \theta) - Y _ {\mathrm {v a l}} \| _ {F} ^ {2}} _ {\text {o u t e r p r o b l e m}} \quad \text {s u b j e c t t o} \quad \underbrace {x ^ {\star} (\theta) = \underset {x \in \mathcal {C}} {\operatorname* {a r g m i n}} f (x , \theta) := \frac {\theta}{2} \| W (x , \theta) \| _ {F} ^ {2} + \langle x , Y _ {\mathrm {t r}} \rangle} _ {\text {i n n e r p r o b l e m}},
+$$
+
+where $\mathcal{C} = \triangle^k\times \dots \times \triangle^k$ is the Cartesian product of $m$ probability simplices. We apply the change of variable $\theta = \exp (\lambda)$ in order to guarantee that the hyper-parameter $\theta$ is positive. The matrix $W(x^{\star}(\theta),\theta)\in \mathbb{R}^{p\times k}$ contains the optimal primal solution, the feature weights for each class. The outer loss is computed against validation data $X_{\mathrm{val}}$ and $Y_{\mathrm{val}}$ .
+
+While KKT conditions can be used to differentiate $x^{\star}(\theta)$ , a more direct way is to use the projected gradient fixed point (9). The projection onto $\mathcal{C}$ can be easily computed by row-wise projections on the
+
+
+(a)
+
+
+(b)
+Figure 4: CPU runtime comparison of implicit differentiation and unrolling for hyperparameter optimization of multiclass SVMs for multiple problem sizes. Error bars represent $90\%$ confidence intervals. (a) Mirror descent (MD) solver, with MD fixed point for differentiation. (b) Proximal gradient (PG) solver, with PG fixed point for differentiation. (c) Block coordinate descent solver; for implicit differentiation we obtain $x^{\star}(\theta)$ by BCD but perform differentiation with the MD and PG fixed points. This shows that the solver and fixed point can be independently chosen.
+
+
+(c)
+
+simplex. The projection's Jacobian enjoys a closed form (Appendix C). Another way to differentiate $x^{\star}(\theta)$ is using the mirror descent fixed point (13). Under the KL geometry, projections correspond to a row-wise softmax. They are therefore easy to compute and differentiate. Figure 4 compares the runtime performance of implicit differentiation vs. unrolling for the latter two fixed points.
+
+# 4.2 Dataset distillation
+
+Dataset distillation [82, 59] aims to learn a small synthetic training dataset such that a model trained on this learned data set achieves a small loss on the original training set. Formally, let $X_{\mathrm{tr}} \in \mathbb{R}^{m \times p}$ and $y_{\mathrm{tr}} \in [k]^m$ denote the original training set. The distilled dataset will contain one prototype example for each class and therefore $\theta \in \mathbb{R}^{k \times p}$ . The dataset distillation problem can then naturally be cast as a bi-level problem, where in the inner problem we estimate a logistic regression model $x^{\star}(\theta) \in \mathbb{R}^{p \times k}$ trained on the distilled images $\theta \in \mathbb{R}^{k \times p}$ , while in the outer problem we want to minimize the loss achieved by $x^{\star}(\theta)$ over the training set:
+
+$$
+\underbrace {\min _ {\theta \in \mathbb {R} ^ {k \times p}} f \left(x ^ {\star} (\theta) , X _ {\mathrm {t r}} ; y _ {\mathrm {t r}}\right)} _ {\text {o u t e r p r o b l e m}} \quad \text {s u b j e c t t o} x ^ {\star} (\theta) \in \underbrace {\operatorname* {a r g m i n} _ {x \in \mathbb {R} ^ {p \times k}} f (x , \theta ; [ k ]) + \varepsilon \| x \| ^ {2}} _ {\text {i n n e r p r o b l e m}}, \tag {10}
+$$
+
+where $f(W, X; y) \coloneqq \ell(y, XW)$ , $\ell$ denotes the multiclass logistic regression loss, and $\varepsilon = 10^{-3}$ is a regularization parameter that we found had a very positive effect on convergence.
+
+In this problem, and unlike in the general hyperparameter optimization setup, both the inner and outer problems are high-dimensional, making it an ideal test-bed for gradient-based bi-level optimization methods. For this experiment, we use the MNIST dataset. The number of parameters in the inner problem is $p = 28^2 = 784$ . while the number of parameters of the outer loss is $k \times p = 7840$ . We solve this problem using gradient descent on both the inner and outer problem, with the gradient of the outer loss computed using implicit differentiation, as described in §2. This is fundamentally different from the approach used in the original paper, where they used differentiation of the unrolled iterates instead. For the same solver, we found that the implicit differentiation approach was 4 times faster than the original one. The obtained distilled images $\theta$ are visualized in Figure 5.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+Figure 5: Distilled dataset $\theta \in \mathbb{R}^{k\times p}$ obtained by solving (10).
+
+
+
+
+
+# 4.3 Task-driven dictionary learning
+
+Task-driven dictionary learning was proposed to learn sparse codes for input data in such a way that the codes solve an outer learning problem [60, 78, 85]. Formally, given a data matrix $X_{\mathrm{tr}} \in \mathbb{R}^{m \times p}$
+
+Table 2: Mean AUC (and $95\%$ confidence interval) for the cancer survival prediction problem.
+
+| Method | L1 logreg | L2 logreg | DictL + L2 logreg | Task-driven DictL |
| AUC (%) | 71.6 ± 2.0 | 72.4 ± 2.8 | 68.3 ± 2.3 | 73.2 ± 2.1 |
+
+and a dictionary of $k$ atoms $\theta \in \mathbb{R}^{k\times p}$ , a sparse code is defined as a matrix $x^{\star}(\theta) \in \mathbb{R}^{m\times k}$ that minimizes in $x$ a reconstruction loss $f(x,\theta) \coloneqq \ell(X_{\mathrm{tr}}, x\theta)$ regularized by a sparsity-inducing penalty $g(x)$ . Instead of optimizing the dictionary $\theta$ to minimize the reconstruction loss, [60] proposed to optimize an outer problem that depends on the code. Given a set of labels $Y_{\mathrm{tr}} \in \{0,1\}^m$ , we consider a logistic regression problem which results in the bilevel optimization problem:
+
+$$
+\underbrace {\min _ {\theta \in \mathbb {R} ^ {k \times p} , w \in \mathbb {R} ^ {k} , b \in \mathbb {R}} \sigma \left(x ^ {\star} (\theta) w + b ; y _ {\mathrm {t r}}\right)} _ {\text {o u t e r p r o b l e m}} \quad \text {s u b j e c t t o} x ^ {\star} (\theta) \in \underbrace {\operatorname* {a r g m i n} _ {x \in \mathbb {R} ^ {m \times k}} f (x , \theta) + g (x)} _ {\text {i n n e r p r o b l e m}}. \tag {11}
+$$
+
+When $\ell$ is the squared Frobenius distance between matrices, and $g$ the elastic net penalty, [60, Eq. 21] derive manually, using optimality conditions (notably the support of the codes selected at the optimum), an explicit re-parameterization of $x^{\star}(\theta)$ as a linear system involving $\theta$ . This closed-form allows for a direct computation of the Jacobian of $x^{\star}$ w.r.t. $\theta$ . Similarly, [78] derive first order conditions in the case where $\ell$ is a $\beta$ -divergence, while [85] propose to use unrolling of ISTA iterations. Our approach bypasses all of these manual derivations, giving the user more leisure to focus directly on modeling (loss, regularizer) aspects.
+
+We illustrate this on breast cancer survival prediction from gene expression data. We frame it as a binary classification problem to discriminate patients who survive longer than 5 years ( $m_{1} = 200$ ) vs patients who die within 5 years of diagnosis ( $m_{0} = 99$ ), from $p = 1,000$ gene expression values. As shown in Table 2, solving (11) (Task-driven DictL) reaches a classification performance competitive with state-of-the-art $L_{1}$ or $L_{2}$ regularized logistic regression with 100 times fewer variables.
+
+# 4.4 Sensitivity analysis of molecular dynamics
+
+Many physical simulations require solving optimization problems, such as energy minimization in molecular [76] and continuum [9] mechanics, structural optimization [53] and data assimilation [40]. In this experiment, we revisit an example from JAX-MD [76], the problem of finding energy minimizing configurations to a system of $k$ packed particles in a 2-dimensional box of size $\ell$
+
+$$
+x ^ {\star} (\theta) = \operatorname * {a r g m i n} _ {x \in \mathbb {R} ^ {k \times 2}} f (x, \theta) := \sum_ {i, j} U (x _ {i, j}, \theta),
+$$
+
+where $x^{\star}(\theta) \in \mathbb{R}^{k \times 2}$ are the optimal coordinates of the $k$ particles, $U(x_{i,j},\theta)$ is the pairwise potential energy function, with half the particles at diameter 1 and half at diameter $\theta = 0.6$ , which we optimize with a domain-specific optimizer [15]. Here we consider sensitivity of particle position with respect to diameter $\partial x^{\star}(\theta)$ , rather than sensitivity of the total energy from the original experiment. Figure 6 shows results calculated via forward-mode implicit
+
+differentiation (JVP). Whereas differentiating the unrolled optimizer happens to work for total energy, here it typically does not even converge, due to the discontinuous optimization method.
+
+
+Figure 6:Particle positions and position sensitivity vectors, with respect to increasing the diameter of the blue particles.
+
+# 5 Conclusion
+
+We proposed in this paper an approach for automatic implicit differentiation, allowing the user to freely express the optimality conditions of the optimization problem whose solutions are to be differentiated, directly in Python. The applicability of our approach to a large catalog of optimality conditions is shown in the non-exhaustive list of Table 1, and illustrated by the ease with which we can solve bi-level and sensitivity analysis problems.
+
+# References
+
+[1] P. Ablin, G. Peyre, and T. Moreau. Super-efficiency of automatic differentiation for functions defined as a minimum. In Proc. of ICML, pages 32-41, 2020.
+[2] A. Agrawal, B. Amos, S. Barratt, S. Boyd, S. Diamond, and Z. Kolter. Differentiable convex optimization layers. arXiv preprint arXiv:1910.12430, 2019.
+[3] A. Agrawal, S. Barratt, S. Boyd, E. Busseti, and W. M. Moursi. Differentiating through a cone program. arXiv preprint arXiv:1904.09043, 2019.
+[4] A. Ali, E. Wong, and J. Z. Kolter. A semismooth newton method for fast, generic convex programming. In International Conference on Machine Learning, pages 70-79. PMLR, 2017.
+[5] B. Amos. Differentiable optimization-based modeling for machine learning. PhD thesis, PhD thesis. Carnegie Mellon University, 2019.
+[6] B. Amos and J. Z. Kolter. Optnet: Differentiable optimization as a layer in neural networks. In Proc. of ICML, pages 136-145, 2017.
+[7] J. A. Andersson, J. Gillis, G. Horn, J. B. Rawlings, and M. Diehl. Casadi: a software framework for nonlinear optimization and optimal control. Mathematical Programming Computation, 11(1):1-36, 2019.
+[8] S. Bai, J. Z. Kolter, and V. Koltun. Deep equilibrium models. arXiv preprint arXiv:1909.01377, 2019.
+[9] A. Beatson, J. Ash, G. Roeder, T. Xue, and R. P. Adams. Learning composable energy surrogates for pde order reduction. In H. Larochelle, M. Ranzato, R. Hadsell, M. F. Balcan, and H. Lin, editors, Advances in Neural Information Processing Systems, volume 33, pages 338-348. Curran Associates, Inc., 2020.
+[10] B. M. Bell and J. V. Burke. Algorithmic differentiation of implicit functions and optimal values. In Advances in Automatic Differentiation, pages 67-77. Springer, 2008.
+[11] Y. Bengio. Gradient-based optimization of hyperparameters. Neural computation, 12(8):1889-1900, 2000.
+[12] Q. Bertrand, Q. Klopfenstein, M. Blondel, S. Vaiter, A. Gramfort, and J. Salmon. Implicit differentiation of lasso-type models for hyperparameter optimization. In Proc. of ICML, pages 810-821, 2020.
+[13] Q. Bertrand, Q. Klopfenstein, M. Massias, M. Blondel, S. Vaiter, A. Gramfort, and J. Salmon. Implicit differentiation for fast hyperparameter selection in non-smooth convex learning. arXiv preprint arXiv:2105.01637, 2021.
+[14] M. J. Best, N. Chakravarti, and V. A. Ubhaya. Minimizing separable convex functions subject to simple chain constraints. SIAM Journal on Optimization, 10(3):658-672, 2000.
+[15] E. Bitzek, P. Koskinen, F. Gähler, M. Moseler, and P. Gumbsch. Structural relaxation made simple. Phys. Rev. Lett., 97:170201, Oct 2006.
+[16] M. Blondel. Structured prediction with projection oracles. In Proc. of NeurIPS, 2019.
+[17] M. Blondel, V. Seguy, and A. Rolet. Smooth and sparse optimal transport. In Proc. of AISTATS, pages 880-889. PMLR, 2018.
+[18] M. Blondel, O. Teboul, Q. Berthet, and J. Djolonga. Fast differentiable sorting and ranking. In Proc. of ICML, pages 950-959, 2020.
+[19] J. Bolte, T. Le, E. Pauwels, and T. Silveti-Falls. Nonsmooth implicit differentiation for machine-learning and optimization. In M. Ranzato, A. Beygelzimer, Y. Dauphin, P. Liang, and J. W. Vaughan, editors, Advances in Neural Information Processing Systems, volume 34, pages 13537-13549. Curran Associates, Inc., 2021.
+[20] J. F. Bonnans and A. Shapiro. *Perturbation analysis of optimization problems*. Springer Science & Business Media, 2013.
+[21] J. Bradbury, R. Frostig, P. Hawkins, M. J. Johnson, C. Leary, D. Maclaurin, G. Necula, A. Paszke, J. VanderPlas, S. Wanderman-Milne, and Q. Zhang. JAX: composable transformations of Python+NumPy programs, 2018.
+
+[22] P. Brucker. An $O(n)$ algorithm for quadratic knapsack problems. Operations Research Letters, 3(3):163-166, 1984.
+[23] O. Chapelle, V. Vapnik, O. Bousquet, and S. Mukherjee. Choosing multiple parameters for support vector machines. Machine learning, 46(1):131-159, 2002.
+[24] H. Cherkoui, J. Sulam, and T. Moreau. Learning to solve tv regularised problems with unrolled algorithms. Advances in Neural Information Processing Systems, 33, 2020.
+[25] F. Clarke. Optimization and Nonsmooth Analysis. Wiley New York, 1983.
+[26] L. Condat. Fast projection onto the simplex and the $\ell_1$ ball. Mathematical Programming, 158(1-2):575-585, 2016.
+[27] K. Crammer and Y. Singer. On the algorithmic implementation of multiclass kernel-based vector machines. Journal of machine learning research, 2(Dec):265-292, 2001.
+[28] M. Cuturi. Sinkhorn distances: lightspeed computation of optimal transport. In Advances in Neural Information Processing Systems, volume 2, 2013.
+[29] C.-A. Deledalle, S. Vaiter, J. Fadili, and G. Peyre. Stein unbiased gradient estimator of the risk (sugar) for multiple parameter selection. SIAM Journal on Imaging Sciences, 7(4):2448-2487, 2014.
+[30] S. Diamond and S. Boyd. Cvxpy: A python-embedded modeling language for convex optimization. The Journal of Machine Learning Research, 17(1):2909–2913, 2016.
+[31] J. Djolonga and A. Krause. Differentiable learning of submodular models. Proc. of NeurIPS, 30:1013-1023, 2017.
+[32] J. Domke. Generic methods for optimization-based modeling. In Artificial Intelligence and Statistics, pages 318-326. PMLR, 2012.
+[33] J. C. Duchi, S. Shalev-Shwartz, Y. Singer, and T. Chandra. Efficient projections onto the $\ell_1$ -ball for learning in high dimensions. In Proc. of ICML, 2008.
+[34] D. Duvenaud, J. Z. Kolter, and M. Johnson. Deep implicit layers tutorial - neural ODEs, deep equilibrium models, and beyond. Neural Information Processing Systems Tutorial, 2020.
+[35] B. Efron, T. Hastie, I. Johnstone, and R. Tibshirani. Least angle regression. The Annals of statistics, 32(2):407-499, 2004.
+[36] L. El Ghaoui, F. Gu, B. Travacca, A. Askari, and A. Y. Tsai. Implicit deep learning. arXiv preprint arXiv:1908.06315, 2, 2019.
+[37] R.-E. Fan, K.-W. Chang, C.-J. Hsieh, X.-R. Wang, and C.-J. Lin. Liblinear: A library for large linear classification. JMLR, 9:1871-1874, 2008.
+[38] L. Franceschi, M. Donini, P. Frasconi, and M. Pontil. Forward and reverse gradient-based hyperparameter optimization. In International Conference on Machine Learning, pages 1165-1173. PMLR, 2017.
+[39] L. Franceschi, P. Frasconi, S. Salzo, R. Grazzi, and M. Pontil. Bilevel programming for hyperparameter optimization and meta-learning. In International Conference on Machine Learning, pages 1568-1577. PMLR, 2018.
+[40] T. Frerix, D. Kochkov, J. A. Smith, D. Cremers, M. P. Brenner, and S. Hoyer. Variational data assimilation with a learned inverse observation operator. 2021.
+[41] R. Frostig, M. Johnson, D. Maclaurin, A. Paszke, and A. Radul. Decomposing reverse-mode automatic differentiation. In LAFI 2021 workshop at POPL, 2021.
+[42] R. Frostig, M. J. Johnson, and C. Leary. Compiling machine learning programs via high-level tracing. Machine Learning and Systems (MLSys), 2018.
+[43] S. W. Fung, H. Heaton, Q. Li, D. McKenzie, S. Osher, and W. Yin. Fixed point networks: Implicit depth models with jacobian-free backprop. arXiv preprint arXiv:2103.12803, 2021.
+[44] Z. Geng, X.-Y. Zhang, S. Bai, Y. Wang, and Z. Lin. On training implicit models. Advances in Neural Information Processing Systems, 34:24247-24260, 2021.
+[45] S. Gould, B. Fernando, A. Cherian, P. Anderson, R. S. Cruz, and E. Guo. On differentiating parameterized argmin and argmax problems with application to bi-level optimization. arXiv preprint arXiv:1607.05447, 2016.
+
+[46] S. Gould, R. Hartley, and D. Campbell. Deep declarative networks: A new hope. arXiv preprint arXiv:1909.04866, 2019.
+[47] R. Grazzi, L. Franceschi, M. Pontil, and S. Salzo. On the iteration complexity of hypergradient computation. In International Conference on Machine Learning, pages 3748-3758. PMLR, 2020.
+[48] A. Griewank and A. Walther. Evaluating derivatives: principles and techniques of algorithmic differentiation. SIAM, 2008.
+[49] S. Grotzinger and C. Witzgall. Projections onto order simplexes. Applied mathematics and Optimization, 12(1):247-270, 1984.
+[50] I. Guyon. Design of experiments of the nips 2003 variable selection benchmark. In NIPS 2003 workshop on feature extraction and feature selection, volume 253, 2003.
+[51] M. R. Hestenes, E. Stiefel, et al. Methods of conjugate gradients for solving linear systems, volume 49. NBS Washington, DC, 1952.
+[52] N. J. Higham. Accuracy and Stability of Numerical Algorithms. Society for Industrial and Applied Mathematics, second edition, 2002.
+[53] S. Hoyer, J. Sohl-Dickstein, and S. Greydanus. Neural reparameterization improves structural optimization. 2019.
+[54] K. Ji, J. Yang, and Y. Liang. Bilevel optimization: Convergence analysis and enhanced design. In International Conference on Machine Learning, pages 4882-4892. PMLR, 2021.
+[55] Y. Kim, C. Denton, L. Hoang, and A. M. Rush. Structured attention networks. arXiv preprint arXiv:1702.00887, 2017.
+[56] D. P. Kingma and J. Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014.
+[57] S. G. Krantz and H. R. Parks. The implicit function theorem: history, theory, and applications. Springer Science & Business Media, 2012.
+[58] C. H. Lim and S. J. Wright. Efficient bregman projections onto the permutahedron and related polytopes. In Proc. of AISTATS, pages 1205-1213. PMLR, 2016.
+[59] J. Lorraine, P. Vicol, and D. Duvenaud. Optimizing millions of hyperparameters by implicit differentiation. In International Conference on Artificial Intelligence and Statistics, pages 1540–1552. PMLR, 2020.
+[60] J. Mairal, F. Bach, and J. Ponce. Task-driven dictionary learning. IEEE Transactions on Pattern Analysis and Machine Intelligence, 34(4):791-804, 2012.
+[61] J. Mairal and B. Yu. Complexity analysis of the lasso regularization path. In Proceedings of the 29th International Conference on Machine Learning, ICML 2012, Edinburgh, Scotland, UK, June 26 - July 1, 2012. icml.cc / Omnipress, 2012.
+[62] A. F. Martins and R. F. Astudillo. From softmax to sparsemax: A sparse model of attention and multi-label classification. In Proc. of ICML, 2016.
+[63] C. Michelot. A finite algorithm for finding the projection of a point onto the canonical simplex of $\mathbb{R}^n$ . Journal of Optimization Theory and Applications, 50(1):195-200, 1986.
+[64] J.-J. Moreau. Proximate et dualité dans un espace hilbertien. Bulletin de la S.M.F., 93:273-299, 1965.
+[65] V. Niculae and M. Blondel. A regularized framework for sparse and structured neural attention. In Proc. of NeurIPS, 2017.
+[66] V. Niculae and A. Martins. Lp-sparsemap: Differentiable relaxed optimization for sparse structured prediction. In International Conference on Machine Learning, pages 7348-7359, 2020.
+[67] V. Niculae, A. Martins, M. Blondel, and C. Cardie. Sparsemap: Differentiable sparse structured inference. In International Conference on Machine Learning, pages 3799-3808. PMLR, 2018.
+[68] B. O'Donoghue, E. Chu, N. Parikh, and S. Boyd. Conic optimization via operator splitting and homogeneous self-dual embedding. Journal of Optimization Theory and Applications, 169(3):1042-1068, 2016.
+
+[69] N. Parikh and S. Boyd. Proximal algorithms. Foundations and Trends in optimization, 1(3):127-239, 2014.
+[70] F. Pedregosa. Hyperparameter optimization with approximate gradient. In International conference on machine learning. PMLR, 2016.
+[71] F. Pedregosa, G. Varoquaux, A. Gramfort, V. Michel, B. Thirion, O. Grisel, M. Blondel, P. Prettenhofer, R. Weiss, V. Dubourg, J. Vanderplas, A. Passos, D. Cournapeau, M. Brucher, M. Perrot, and E. Duchesnay. Scikit-learn: Machine learning in Python. Journal of Machine Learning Research, 12:2825–2830, 2011.
+[72] A. Rajeswaran, C. Finn, S. Kakade, and S. Levine. Meta-learning with implicit gradients. arXiv preprint arXiv:1909.04630, 2019.
+[73] Z. Ramzi, F. Mannel, S. Bai, J.-L. Starck, P. Ciuciu, and T. Moreau. Shine: Sharing the inverse estimate from the forward pass for bi-level optimization and implicit models. arXiv preprint arXiv:2106.00553, 2021.
+[74] N. Rappoport and R. Shamir. Multi-omic and multi-view clustering algorithms: review and cancer benchmark. *Nucleic Acids Res.*, 46:10546–10562, 2018.
+[75] Y. Saad and M. H. Schultz. Gmres: A generalized minimal residual algorithm for solving nonsymmetric linear systems. SIAM Journal on scientific and statistical computing, 7(3):856-869, 1986.
+[76] S. Schoenholz and E. D. Cubuk. Jax md: A framework for differentiable physics. In H. Larochelle, M. Ranzato, R. Hadsell, M. F. Balcan, and H. Lin, editors, Advances in Neural Information Processing Systems, volume 33, pages 11428-11441. Curran Associates, Inc., 2020.
+[77] M. W. Seeger. Cross-validation optimization for large scale structured classification kernel methods. Journal of Machine Learning Research, 9(6), 2008.
+[78] P. Sprechmann, A. M. Bronstein, and G. Sapiro. Supervised non-euclidean sparse nmf via bilevel optimization with applications to speech enhancement. In 2014 4th Joint Workshop on Hands-free Speech Communication and Microphone Arrays (HSCMA), pages 11-15. IEEE, 2014.
+[79] R. J. Tibshirani. The lasso problem and uniqueness. Electronic Journal of Statistics, 7(none):1456 - 1490, 2013.
+[80] S. Vaiter, C.-A. Deledalle, G. Peyre, C. Dossal, and J. Fadili. Local behavior of sparse analysis regularization: Applications to risk estimation. Applied and Computational Harmonic Analysis, 35(3):433-451, 2013.
+[81] H. A. v. d. Vorst and H. A. van der Vorst. Bi-CGSTAB: A fast and smoothly converging variant of Bi-CG for the solution of nonsymmetric linear systems. SIAM Journal on Scientific and Statistical Computing, 13(2):631-644, 1992.
+[82] T. Wang, J.-Y. Zhu, A. Torralba, and A. A. Efros. Dataset distillation. arXiv preprint arXiv:1811.10959, 2018.
+[83] R. E. Wengert. A simple automatic derivative evaluation program. Communications of the ACM, 7(8):463-464, 1964.
+[84] Y. Wu, M. Ren, R. Liao, and R. B. Grosse. Understanding short-horizon bias in stochastic meta-optimization. In 6th International Conference on Learning Representations, ICLR 2018, Vancouver, BC, Canada, April 30 - May 3, 2018, Conference Track Proceedings. OpenReview.net, 2018.
+[85] J. Zarka, L. Thiry, T. Angles, and S. Mallat. Deep network classification by scattering and homotopy dictionary learning. arXiv preprint arXiv:1910.03561, 2019.
\ No newline at end of file
diff --git a/efficientandmodularimplicitdifferentiation/images.zip b/efficientandmodularimplicitdifferentiation/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..523deb438ea67e51c2020a6cdd9689107c28a4d7
--- /dev/null
+++ b/efficientandmodularimplicitdifferentiation/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e8908bc6c1f15698bfc45c3e3b03dfbe6cbd6d8dd7808ac174a4e6fa7c5acdb3
+size 334016
diff --git a/efficientandmodularimplicitdifferentiation/layout.json b/efficientandmodularimplicitdifferentiation/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..2e7405f4121c1eff7f074a4390847ed7973e18af
--- /dev/null
+++ b/efficientandmodularimplicitdifferentiation/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a120d26104c37a5ccbc3f20954cafabf0d7d1e794e868917b269b15bd72477cf
+size 606485
diff --git a/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/9814fc09-713f-4e39-bbbb-40a52f264ddb_content_list.json b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/9814fc09-713f-4e39-bbbb-40a52f264ddb_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..4977f0bd11fd525fff878f4d76721ea50051e394
--- /dev/null
+++ b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/9814fc09-713f-4e39-bbbb-40a52f264ddb_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4ac2c8c06f83cd3922ffba5e028788918c9fd1d54c86af725aaed1c1a5bb36b8
+size 85230
diff --git a/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/9814fc09-713f-4e39-bbbb-40a52f264ddb_model.json b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/9814fc09-713f-4e39-bbbb-40a52f264ddb_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..04b98ae836c881ae0a5c0dbd6463fc5f6d701e24
--- /dev/null
+++ b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/9814fc09-713f-4e39-bbbb-40a52f264ddb_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e9ec38d653612f83efa9fc5064d64ce40cdc766c7eab24b456f3f98042fa0855
+size 108145
diff --git a/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/9814fc09-713f-4e39-bbbb-40a52f264ddb_origin.pdf b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/9814fc09-713f-4e39-bbbb-40a52f264ddb_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..c76be6a178444013aeb6560398cd580e6f128b90
--- /dev/null
+++ b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/9814fc09-713f-4e39-bbbb-40a52f264ddb_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ac123721b4324ab714b52636eea5518bbd17a2edf8398b212a09871a0889c70d
+size 662732
diff --git a/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/full.md b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..f114a8e8a7ed634e118281216526dc3903c0fdf6
--- /dev/null
+++ b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/full.md
@@ -0,0 +1,377 @@
+# Efficient and Near-Optimal Smoothed Online Learning for Generalized Linear Functions
+
+Adam Block
+
+Department of Mathematics
+
+MIT
+
+Cambridge, MA 02139
+
+ablock@mit.edu
+
+Max Simchowitz
+
+CSAIL
+
+MIT
+
+Cambridge, MA 02139
+
+msimchow@csail.mit.edu
+
+# Abstract
+
+Due to the drastic gap in complexity between sequential and batch statistical learning, recent work has studied a smoothed sequential learning setting, where Nature is constrained to select contexts with density bounded by $1 / \sigma$ with respect to a known measure $\mu$ . Unfortunately, for some function classes, there is an exponential gap between the statistically optimal regret and that which can be achieved efficiently. In this paper, we give a computationally efficient algorithm that is the first to enjoy the statistically optimal $\log (T / \sigma)$ regret for realizable $K$ -wise linear classification. We extend our results to settings where the true classifier is linear in an over-parameterized polynomial featurization of the contexts, as well as to a realizable piecewise-regression setting assuming access to an appropriate ERM oracle. Somewhat surprisingly, standard disagreement-based analyses are insufficient to achieve regret logarithmic in $1 / \sigma$ . Instead, we develop a novel characterization of the geometry of the disagreement region induced by generalized linear classifiers. Along the way, we develop numerous technical tools of independent interest, including a general anti-concentration bound for the determinant of certain matrix averages.
+
+# 1 Introduction
+
+In batch statistical learning, a learner faces a set of independent examples drawn from a given distribution, and is tasked with generalizing to novel examples drawn from that same distribution. In sequential or online learning, however, Nature may adversarially select examples to thwart the learner's progress and success is defined only in comparison to the best a priori predictor. Due to the wide range of application and minimal set of assumptions, online learning has received considerable recent attention. For concreteness, consider binary classification, where a sequence of $T$ examples takes the form $(x_{t},y_{t})\in \mathcal{R}^{d}\times \{-1, + 1\}$ . Even in the realizable setting, where there exists a true $f^{\star}$ in a pre-specified class of functions $\mathcal{F}$ for which $f^{\star}(x_{t}) = y_{t}$ for all $t\in \{1,2,\dots ,T\}$ , the gap between batch and statistical learning and sequential learning can be drastic: when $d = 1$ , the class of linear thresholds $f_{\theta}(x) = \mathrm{sign}(x - \theta)$ has VC dimension one and is thus learnable in the PAC framework [Wainwright, 2019]. A sequential adversary, however, can select $x_{t}$ so as to force the linear to misclassify $\Omega (T)$ points [Littlestone, 1988].
+
+To circumvent the pessimism of the sequential setting, recent works [Rakhlin et al., 2011, Haghtalab et al., 2020, 2021, Block et al., 2022, Haghtalab et al., 2022] have studied the smoothed sequential learning paradigm, where the adversary is constrained to choose $x_{t}$ at random from any probability distribution $p_t$ with density at most $1 / \sigma$ with respect to a known measure $\mu$ . The most current of these results point to a striking statistical computational gap: whereas there exist algorithms which attain regret that scales with $\sqrt{T\log(\mathcal{O}\sigma)}$ , computationally efficient algorithms can only
+
+hope for $\mathrm{poly}(T / \sigma)$ regret in general, even against a realizable adversary [Haghtalab et al., 2022, Theorem 5.2]. In many $d$ -dimensional settings, natural choices of $\mu$ yield $\sigma = \exp(-\Omega(d))$ , and thus the exponential separation in $\sigma$ translates into an exponential separation in dimension. This gap motivates the following question: can the statistical-computational gap be eliminated in more structured settings? In this work, we answer the question affirmatively for a variety of natural function classes. A better understanding of what function classes allow computationally efficient, statistically optimal regret-minimizing algorithms remains a promising direction for future research.
+
+Contributions. We show that for certain classes of realizable smoothed online classification problems, there exists a computationally efficient algorithm which enjoys the statistically optimal $\log (T / \sigma)$ regret scaling, when the base measure $\mu$ is uniform on the unit-ball. Specifically, we provide computationally efficient algorithms for achieving the statistically optimal regret bound for the following function classes:
+
+- For affine thresholds,
+- For affine thresholds in nonlinear features,
+- For $K$ -class affine classification,
+- For piecewise affine regression
+
+We also provide lower bounds that demonstrate the statistical optimality of our algorithms. Furthermore, we apply our results to noiseless contextual bandits and get a fast algorithm that achieves optimal regret dependence on the horizon, up to logarithmic factors. Finally, we present a complementary approach based on the perceptron algorithm which is robust to adversarial corruptions of the labels $y_{t}$ , and enjoys a polynomial regret in a "directional smoothness" parameter which interpolates between the $\log(1/\sigma)$ -guarantees attained above in the realizable setting, and the $\mathrm{poly}(1/\sigma)$ bounds from prior work. We emphasize that, though we adopt the smoothed online learning setting of Rakhlin et al. [2011], Haghtalab et al. [2021], Block et al. [2022], we use entirely different techniques involving Ville's inequality [Ville, 1939], geometric measure theory, and convex geometry. Moreover, in none of these works was the question of adapting to realizability explored; thus, we provide the first regret bounds that are logarithmic in both the horizon and the smoothness parameter. We now discuss some related work:
+
+Online Learning. Extensions of classical learning theory to the online setting have proliferated due to the scope of application. Several works [Littlestone, 1988, Blumer et al., 1989, Ben-David et al., 2009, Rakhlin et al., 2015a] have explored the gap in statistical rates between classical and online learning settings, with Littlestone [1988], Blumer et al. [1989] showing that the class of one dimensional thresholds, which is easy to learn in the batch setting, is not learnable with adversarial data. Other works, such as Rakhlin et al. [2015a], Rakhlin and Sridharan [2013], Rakhlin et al. [2015b], Block et al. [2021], Rakhlin and Sridharan [2014] have provided sequential analogues of classical notions of complexity that characterize minimax regret, as well as providing computational separation between classical and online learning [Hazan and Koren, 2016]. Due to the statistical and computational hardness results presented in the aforementioned work, there has been great interest in finding realistic, robust assumptions, such as smoothness, that allow for efficient learning.
+
+Smoothe d Online Learning. Smo the s f th t h 192 by mth oal. Since then, smoed analysis has been applied to explain the empirical success of many algorithms [Roughgarden, 2021]. In the learning setting, Rakhlin et al. [2011] proposed smoothed adversaries and proved regret bounds for linear thresholds in $\mathbb{R}^d$ ; their proof, however, was nonconstructive and did not achieve logarithmic regret in the realizable setting. The use of smoothed adversaries was essential due to the hardness results discussed above. In a series of works Hghtalab et al. [2020, 2021] generalized Rakhlin et al. [2011] and showed the regret depending on the VC dimension was possible in the smooed online learning setting, albeit with computationally inefficient algorithms.
+
+Recently, Block et al. [2022], Haghtalab et al. [2022] generalized Haghtalab et al. [2021] to allow for continuous labels and, more importantly, provided oracle-efficient algorithms for achieving vanishing regret in the smoothed setting. These papers also showed that the dependence on $\sigma$ in the regret bounds of their oracle-efficient algorithms, which was polynomial, could not in general be
+
+reduced to the logarithmic dependence achievable by the inefficient algorithms, thereby exposing a statistical-computational gap. Unlike other recent works such as Block et al. [2022], Haghtalab et al. [2022], we do not use the coupling approach [Haghtalab et al., 2021] to prove our regret bounds.
+
+Classification with Linear Thresholds. Considering the ubiquity of linear thresholds in classification, the list of relevant references is far too long to include here; as such, we highlight only those most germane to our work. The perceptron algorithm was introduced in Rosenblatt [1958] and a margin-based mistake bound was proved in Novikoff [1963]. There have been many variations on and applications of this bound, from Ben-David et al. [2009] using it to bound the Littlestone dimension of linear thresholds with margin to dealing with non-realizable samples [Crammer et al., 2006, Freund and Schapire, 1999]. To the best of our knowledge our work constitutes the first to explore the effect that a smoothed adversary has on the perceptron algorithm.
+
+Disagreement Coefficient and Active Learning. Intuitively, our analysis is similar to works in active learning based on the disagreement coefficient [Hanneke, 2007, 2011, Hanneke et al., 2014, Wang, 2011]. Indeed, as we shall see, our regret bounds arise by bounding the probability that a point falls into the disagreement region in a similar way as, for example, Hanneke [2007] controls the label complexity of active learning. We will note in Remark 3, however, that an approach grounded purely in the disagreement coefficient cannot hope to achieve regret logarithmic in $\sigma$ in the smoothed setting. Indeed, our approach incorporates a finer understanding of the geometry, accommodated by the more limited scope of application of our techniques, which allows us to prove tight rates.
+
+In Section 2, we setup the learning problem and introduce some necessary notions from convex geometry, as well as fixing notation. In Section 3, we highlight two technical results that form the foundation of our approach, before, as a warmup, applying them to the case of classification with linear thresholds in Section 4. In Section 5, we generalize beyond linear thresholds to allow for offset and nonlinear features. Finally, in Section 6, we move beyond binary classification by extending our results to $K$ -class affine classification, piecewise affine regression, and noiseless contextual bandits.
+
+# 2 Preliminaries
+
+In this section, we provide basic definitions and setup the learning problem. We begin by defining a smooth distribution, as in Block et al. [2022], Haghtalab et al. [2021]:
+
+Definition 1. Let $\mu$ be a probability measure on a measurable space $\mathcal{X}$ . For some $0 < \sigma \leq 1$ , we say that a measure $p$ on $\mathcal{X}$ is $\sigma$ -smooth with respect to $\mu$ if the likelihood $\frac{\mathrm{d}p}{\mathrm{d}\mu} \leq \frac{1}{\sigma}$ is uniformly bounded.
+
+We consider the smoothed online learning setting. First, a horizon $T \in \mathbb{N}$ is fixed and a distribution $\mu$ on $\mathcal{X}$ is chosen. For each step $1 \leq t \leq T$ , Nature chooses a distribution $p_t$ , possibly depending on the history, such that $p_t$ is $\sigma$ -smooth with respect to $\mu$ and samples $x_t \sim p_t$ as well as choosing some $y_t \in \mathcal{Y}$ . The learner sees $x_t$ , chooses $\hat{y}_t$ and suffers loss $\ell(\hat{y}_t, y_t)$ . Given a function class $\mathcal{F}$ of functions mapping $\mathcal{X} \to \mathcal{Y}$ , the learner attempts to minimize regret, where regret is defined as:
+
+$$
+\operatorname {R e g} _ {T} = \sum_ {t = 1} ^ {T} \ell \left(\hat {y} _ {t}, y _ {t}\right) - \inf _ {f \in \mathcal {F}} \sum_ {t = 1} ^ {T} \ell \left(f \left(x _ {t}\right), y _ {t}\right). \tag {2.1}
+$$
+
+In the sequel, for the sake of simplicity, we take $\mathcal{X} = \mathcal{B}_1^d$ to be the unit ball, $\mu = \mu_d$ to be the uniform measure on $\mathcal{B}_1^d$ , and $\ell (\hat{y}_t,y_t) = \mathbb{I}(\hat{y}_t\neq y_t)$ to be the 0-1 loss.
+
+Remark 1 (Scaling of $\sigma$ ). A natural example of a smoothed adversary is one that is allowed to place $\widehat{x}_t$ in a worst-case manner, which gets perturbed by some small additive noise, chosen uniform on $\varepsilon \cdot \mathcal{B}_1^d$ , to become $x_t$ ; this adversary is $\sigma = \varepsilon^d$ smooth. For such situations, polynomial dependence on $\sigma$ in the regret translates into something exponential in dimension.
+
+Remark 2 (Other measures $\mu$ ). Assuming the dominating measure $\mu = \mu_d$ is not overly strong: if $\mu$ is another measure on $\mathcal{B}_1^d$ for which $\frac{\mathrm{d}\mu}{\mathrm{d}\mu_d} \geq c > 0$ , then, because our regret bounds are logarithmic in $\sigma$ , our results will still hold with an additive term of $\log \left(\frac{1}{c}\right)$ .
+
+For much of the paper, we assume that Nature is realizable with respect to $\mathcal{F}$ , i.e., for some $f^{\star} \in \mathcal{F}$ , $f^{\star}(x_{t}) = y_{t}$ for all $1 \leq t \leq T$ . In this case, $\operatorname{Reg}_T$ is just a mistake bound: $\operatorname{Reg}_T = \sum_{t=1}^{T} \mathbb{I}\{\hat{y}_t \neq y_t\}$ .
+
+The foundations of our analysis consider the class of linear threshold classifiers
+
+$$
+\mathcal {F} _ {\operatorname {l i n}} ^ {d} := \left\{x \mapsto \operatorname {s i g n} (\langle w, x \rangle) | w \in \mathcal {B} _ {1} ^ {d} \right\}. \tag {2.2}
+$$
+
+We identify $\mathcal{F}_{\mathrm{lin}}^d$ with the set of $w$ 's defining it, so that we may treat it as, itself, a subset of $\mathcal{B}_1^d$ ; other function classes are similarly identified with their parameters (without further comment).
+
+At the core of our base algorithm is the computation of the John ellipsoid [John, 1948, Ball et al., 1997], the maximal volume ellipsoid contained in a convex body. It is well-known that given a polytope in $\mathbb{R}^d$ , the John ellipsoid can be computed in time polynomial in $d$ and the number of faces [Boyd and Vandenberghe, 2004]. In particular, we compute the John ellipsoid of the version space, $\mathcal{F}_t$ , where for any time $t$ , we let $\mathcal{F}_t = \{f \in \mathcal{F}_{\mathrm{lin}}^d | f(x_s) = y_s \text{ for all } s < t\}$ , which is a polytope with $t \leq T$ faces. An important concept in our analysis is the notion of Hausdorff measure, which generalizes the standard notions of volume and surface area in $\mathbb{R}^d$ ; we will denote the $k$ -dimensional Hausdorff measure (see Definition 18) by $\mathrm{vol}_k(\cdot)$ . More detail on both the John ellipsoid and the Hausdorff measure can be found in Appendix B.
+
+Notation. For a set $\mathcal{U} \subset \mathbb{R}^d$ , we denote by $\partial \mathcal{U}$ its boundary. We let $\mathcal{B}_r^d$ denote the ball of radius $r$ around the origin in $\mathbb{R}^d$ and let $S^{d-1} = \partial B_1^d$ . Letting $\Gamma$ denote the $\Gamma$ -function, let $\omega_d = \frac{\pi^{d/2}}{\Gamma(d/2+1)}$ denote the volume of $\mathcal{B}_1^d$ and let $\mu_d$ denote the uniform measure on $\mathcal{B}_1^d$ normalized to be a probability measure. If $\phi: \mathbb{R}^n \to \mathbb{R}^m$ is Lipschitz, we denote the Jacobian by $D\phi$ . Lastly, we use “ $\lesssim$ ” to denote inequality up to universal, problem-independent constants.
+
+# 3 The Technical Workhorses
+
+In this section we introduce the two key workhorse results that provide the technical foundation for the rest of the paper. The first result is a purely probabilistic statement that we use as a blackbox throughout the paper to turn probabilistic and geometric theorems into regret bounds in the realizable, smoothed online learning setting. The second result is a geometric statement that allows us to apply the black box regret bound to the case of classification with affine thresholds.
+
+# 3.1 An Abstract Decay Analysis
+
+We begin with an abstract, technical result that will form the basis for all of our regret bounds. We first introduce the following definition:
+
+Definition 2. Let $\mu$ be a measure on some set $\mathcal{Z}$ and let $\ell_t: \mathcal{Z} \to \{0,1\}$ be a sequence of loss functions. For $R > 0$ and $0 < c < 1$ , we say that the sequence $(\ell_t, z_t)$ satisfies $(R, c)$ -geometric decay with respect to $\mu$ if there exists a sequence of nonnegative numbers $R_t$ with $R_1 = R$ satisfying the following two properties:
+
+1. For all $t, \mu(\{z : \ell_t(z) = 1\}) \leq R_t$ .
+2. For any $t$ such that $\ell_t(z_t) = 1$ , we have $R_{t + 1}\leq cR_{t}$ .
+
+To motivate this admittedly abstract definition, consider the case of online classification with thresholds $f_{\theta}(x) = \mathrm{sign}(x - \theta)$ from the introduction, with $\mu$ uniform on $[0,1] \times \{\pm 1\}$ (note that this does not precisely fit into the linear setting described above due to the offset); take $z_{t} = (x_{t},y_{t})$ and $\ell_t(z_t) = \mathbb{I}[\hat{y}_T \neq y_t]$ , where the learner predicts $\hat{y}_t$ at each time $t$ . By realizability, $\ell_t(z) = 1$ only when $x_{t}$ falls in the "region of disagreement," i.e. the interval the rightmost $x_{s}$ labelled $-1$ and the leftmost $x_{s}$ labelled 1. To see why this is true, note that the "version space," i.e., the set of thresholds that correctly classify all the data so far, is exactly this interval; for us to make a mistake, there must be two functions in the version space that disagree on $x_{t}$ , which can only happen if $x_{t}$ itself is in the version space. If the learner denotes by $w_{t}$ the midpoint of the region of disagreement, then any mistake forces the version space, and thus the disagreement region, to shrink by a factor of 2. We see then that $(\ell_t,z_t)$ satisfy $(1,\frac{1}{2})$ -geometric decay with respect to the uniform measure.
+
+If the adversary were constrained to choose $x_{t} \sim \mu$ at each time step, it is intuitive that we should not expect many mistakes to be made because, after any mistake, the probability that we make a mistake
+
+in some future interval decreases. In the following result, we show that this intuition holds in the more general smoothed setting:
+
+Lemma 3 (Abstract Decay Lemma). Suppose that a sequence $(\ell_t,z_t)$ satisfies $(R,c)$ -geometric decay with respect to some $\mu$ on $\mathcal{Z}$ , and that for all $t$ , there is some $p_t$ that is $\sigma$ -smooth with respect to $\mu$ and $z_{t}\sim p_{t}$ . Then for all $T\in \mathbb{N}$ , with probability at least $1 - \delta$ ,
+
+$$
+\sum_ {t = 1} ^ {T} \ell_ {t} \left(z _ {t}\right) \leq 4 \frac {\log \left(\frac {2 T R}{\sigma \delta}\right)}{\log \left(\frac {1}{c}\right)} + \frac {e - 1}{1 - \sqrt {c}}. \tag {3.1}
+$$
+
+Proof Sketch. We break our analysis into epochs whose lengths $h_m$ are tuned at the end of the proof. We then consider a sequence of stopping times $\tau_m$ that count the number of epochs of length $h_m$ we experience in between the $(m - 1)^{st}$ and $m^{th}$ time that $\ell_t = 1$ . We then show that if $h_m$ is not too large relative to the Probability that $\ell_t = 1$ , then $\tau_m - \tau_{m-1}$ is large with high probability and apply Ville's inequality [Ville, 1939] to conclude that if $m_T$ is the maximal epoch-index $m$ such that $\tau_m \leq T$ , then $m_T$ cannot be too large. We again apply Ville's inequality to show that if $h_m$ is not too large then the probability of multiple mistakes per epoch is small. Because of the geometric decay property, the probability that $\ell_t = 1$ decreases exponentially in the number of mistakes and thus we may let $h_m$ grow exponentially in $m$ and still not be too large to apply the above argument. We then conclude by noting that if $h_m$ are growing exponentially in $m$ then $m_T$ has to be logarithmic in $T$ . The details can be found in Appendix C.1.
+
+If we return to the above example of online classification with thresholds, we see that Lemma 3 immediately yields the first regret bound for realizable, smoothed online learning with thresholds that is logarithmic both in the horizon $T$ and the smoothness parameter $\sigma$ . The intuition gleaned from one-dimensional thresholds that geometric decay suffices to ensure logarithmic regret will be key to the more general regret bounds we exhibit below.
+
+# 3.2 A Volumetric Lemma
+
+In the previous section, we saw that in the setting of realizable, smoothed online classification with one-dimensional thresholds, the learner can force the indicator of a mistake at time $t$ to satisfy geometric decay; our second workhorse result will allow us to extend this fact to higher dimensions. In the case of thresholds in the unit interval, the key intuition leading to geometric decay was the fact that the disagreement region was exactly the version space and thus shrinking the version space tautologically shrank the disagreement region as well. In higher dimensions the situation is significantly more complicated. We have the following result:
+
+Lemma 4. Let $x_{1},\ldots ,x_{t}\in \mathcal{B}_{1}^{d}$ and suppose that $y_{1},\ldots ,y_{t}$ are realizable with respect to $\mathfrak{F}_{\mathrm{lin}}^d$ Define the disagreement region
+
+$$
+D _ {t} := \left\{x \in \mathcal {B} _ {1} ^ {d} \mid \text {t h e r e e x i s t f , f ^ {\prime} \in \mathcal {F} _ {t} s u c h t h a t f (x) \neq f ^ {\prime} (x)} \right\} \tag {3.2}
+$$
+
+where $\mathcal{F}_t$ is the version space, defined in Section 2. Then, recalling that $\partial \mathcal{F}_t$ is the boundary of $\mathcal{F}_t$ ,
+
+$$
+\mu_ {d} \left(D _ {t}\right) \leq 2 \cdot 4 ^ {d - 1} \mu_ {d} \left(\mathcal {F} _ {t}\right) + \frac {4 ^ {d + 1}}{\omega_ {d}} \operatorname {v o l} _ {d - 1} \left(\partial \mathcal {F} _ {t}\right). \tag {3.3}
+$$
+
+Note that by controlling the size of $D_{t}$ by that of $\mathcal{F}_t$ , Lemma 4 is a direct generalization of the one-dimensional case; however, in contradistinction to that setting, the proof is much more difficult and the bound includes an extra term corresponding to the surface area of $\mathcal{F}_t$ , which is unavoidable in general. The full proof is in Appendix C.2, but we summarize the key points here. Though the conclusion of Lemma 4 is intuitive, it requires significant technical effort to prove.
+
+Proof Sketch of Lemma 4. We first note that $D_{t}$ is contained in the set of points $x$ such that there is some $w \in \mathcal{F}_t$ with $\langle w, x \rangle = 0$ ; thus the conclusion of Lemma 4 reduces to a geometric statement about the volume of the set of points orthogonal to at least one point in a given set can be. It may seem like this should "obviously" be the volume of a $(d - 1)$ -dimensional ball multiplied by the
+
+Algorithm 1 Binary Classification with Linear Thresholds
+1: Initialize $\mathcal{W}_1 = \mathcal{B}_1^d, w_1 = \mathbf{e}_1$
+2: for $t = 1, 2, \ldots$ do
+3: Recieve $x_t$ , and predict $\hat{y}_t = \text{sign}(\langle w_t, x_t \rangle)$ , (\% self.classify(x_t))
+4: Update $\mathcal{W}_{t+1} = \mathcal{W}_t \cap \{w \in \mathcal{B}_1^d | \langle w, x_t y_t \rangle \geq 0\}$
+5: if $\hat{y}_t \neq y_t$ then (\% self.errorUpdate(x_t))
+6: $w_{t+1} \gets \text{JohnEllipsoidCenter}(\mathcal{W}_{t+1})$
+7: \% returns center of John Ellipsoid of given convex body
+
+volume of $\mathcal{F}_t$ , but this is false: if $\mathcal{F}_t$ is the equator of the sphere $S^{d-1}$ , then $\mu_d(\mathcal{F}_t) = 0$ , but the set of points orthogonal to at least one point in $\mathcal{F}_t$ is the entirety of $\mathcal{B}_1^d$ . Ruling out this pathology requires several steps, including a covering argument to reduce to the case where $\mathcal{F}_t$ is a ball, and application of (a generalized) Steiner's formula, and a deep geometric fact called Weyl's Tube Formula [Weyl, 1939, Gray, 2003] that governs how much volume we can add to $\mathcal{F}_t$ by "fattening" to include all points distance at most $\varepsilon$ from $\mathcal{F}_t$ .
+
+# 4 Warmup with Linear Classification
+
+In this section, we begin to apply our results from Section 3 to get tight regret bounds with computationally efficient algorithms for learning halfspaces in the realizable, smoothed online setting:
+
+Theorem 5. Let $\mu$ be the uniform measure on $\mathcal{B}_1$ . Suppose that we are in the smoothed, realizable online learning setting, where the adversary samples $x_{t}$ from a distribution that is $\sigma$ -smooth with respect to $\mu$ . If we predict $\hat{y}_t$ according to Algorithm 1, then for all horizons $T$ , with probability at least $1 - \delta$ ,
+
+$$
+\operatorname {R e g} _ {T} \leq 1 3 6 d \log (d) + 3 4 \log \left(\frac {T}{\sigma \delta}\right) + 5 6. \tag {4.1}
+$$
+
+Computational Efficiency. The subroutine JohnEllpsoidCenter $(\mathcal{W}_{t + 1})$ can be run in time polynomial in $T$ and $d$ by solving a Semi-definite Program (SDP) [Boyd and Vandenberghe, 2004, Primak and Kheyfets, 1995]. Note that we change our predictor $f_{t}$ only at the times $t$ that we make a mistake; thus, the number of calls to the SDP is also logarithmic in $T$ .
+
+Proof Sketch of Theorem 5. We apply Lemma 3 with $z_{t} = (x_{t},y_{t})$ and $\ell_t(z) = \mathbb{I}[\hat{y}_t\neq y_t]$ . In order to do this we need to show that $\ell_t$ satisfies $(R,c)$ geometric decay, which amounts to finding a geometrically decreasing sequence of upper bounds on $\mu (D_{t})$ . By Lemma 4, it will suffice to provide such bounds on both $\mu (\mathcal{F}_t)$ and $\mathrm{vol}_{d - 1}(\partial \mathcal{F}_t)$ , which is where the specific choice of $w_{t}$ becomes important. It is now classical [Tarasov et al., 1988, Khachiyan, 1990] that if a polytope is cut by a hyperplane through the center of its John ellipsoid then both halves have John ellipsoids whose volumes are at most $\frac{8}{9}$ times the volume of the original ellipsoid; as we know that $\mathcal{F}_t\subset d\cdot \mathcal{E}_t$ [John, 1948], where $\mathcal{E}_t$ is the John ellipsoid of $\mathcal{F}_t$ , we see that $\mu (d\cdot \mathcal{E}_t)$ is an upper bound on $\mu (\mathcal{F}_t)$ that decreases by $\frac{8}{9}$ every time we make a mistake. The true utility of the center of the John ellipsoid is that it also allows us to show that $\partial \mathcal{F}_t$ decreases by a constant factor. Indeed, we show that $\mathrm{vol}_{d - 1}(\partial \mathcal{F}_t)\leq \mathrm{vol}_{d - 1}(\partial \mathcal{E}_t)$ using a simple projection argument; we then apply a result of Rivin [2007] to bound the size of $\partial \mathcal{E}_t$ by $\mu (\mathcal{E}_t)$ . The details are in Appendix D.
+
+Importance of the John's Ellipsoid. We show in Appendix D.3 that arbitrary predictions $y_{t} = \tilde{f}_{t}(x_{t})$ for $\tilde{f}_{t} \in \mathcal{F}_{t}$ in the version space, can guarantee $1 / \sigma$ -regret at best. Hence, selecting the correct $w_{t}$ is key. One natural choice of $w_{t}$ is the Chebyshev center of $\mathcal{F}_t$ [Elzinga and Moore, 1975], equivalent to a max-margin estimator; unfortunately it need not decrease the volume sufficiently if $\mathcal{F}_t$ is too 'pointy.' Another choice, the centroid of $\mathcal{F}_t$ , ensures decrease of the polytope's volume, but is #P-hard to compute [Rademacher, 2007], and does not ensure decay of the surface area. The former problem can be accommodated with a sampling scheme [Bertsimas and Vempala, 2004], but the latter is critical. In contrast, the center of the John ellipsoid controls the decay of both $\mathcal{F}_t$ and its boundary. To gain intuition as to why the decay in surface area of $\mathcal{F}_t$ is necessary, consider the case where $\mathcal{F}_t$ is simply an arc in $S^{d - 1}$ . In this case, as $D_{t}$ is the set of points orthogonal to at least one point in in $\mathcal{F}_t$ , it follows that $D_{t}$ has positive measure even though $\mathcal{F}_t$ , being a lower dimensional set, does not; thus,
+
+it is impossible in general to get a guarantee on the size of $D_{t}$ only in terms of the volume of $\mathcal{F}_t$ , without regard to the surface area. In this way, we see that the choice of $w_{t}$ as the center of the John's Ellipsoid is critical to the success of our algorithm.
+
+Remark 3 (Disagreement Coefficient). Our analysis is similar in spirit to the disagreement-coefficient analysis of active learning [Hanneke, 2007], which also exhibits geometric decay of the disagreement region $D_{t}$ . The key difference is that the latter applies to any algorithm that selects a classifier from the version space $\mathcal{F}_t$ at each time $t$ . Again, as shown in Appendix D.3, no such analysis can recover a better than $1 / \sigma$ -regret bound. The culprit is that disagreement-coefficient arguments ensure that $D_{t}$ shrink only probabilistically under samples $x_{t}\sim \mu$ , and this probability may shrink by a factor of $\sigma$ in the smoothed-online setting. In contrast, our choice of classifier as the center of the John's ellipsoid ensures a deterministic decay of the disagreement region whenever a mistake is made.
+
+Lower Bound. Before we move on to the more complicated settings, we note that this regret bound is tight up to a logarithmic factor in $d$ . A proof of the following proposition, based on Ville's inequality, can be found in Appendix D.
+
+Proposition 6. Suppose that we are in the situation of Theorem 5. Then there is a realizable adversary such that any classifier experiences
+
+$$
+\mathbb {E} \left[ \operatorname {R e g} _ {T} \right] \geq \Omega (d + \log (T / \sigma)). \tag {4.2}
+$$
+
+# 4.1 Smoothed classification via the Perceptron algorithm
+
+Next, we present a guarantee for the classical Perceptron algorithm Rosenblatt [1958], which requires a much weaker notion of smoothness. We say that the adversary satisfies $\sigma_{\mathrm{dir}}$ directional smoothness if, for any fixed $w \in S^{d-1}$ , it holds that for all $t$ , $\langle x_t, w \rangle$ is $\sigma_{\mathrm{dir}}$ -smooth with respect to the Lebesgue measure on the real line. As we explain in Example 2 in Appendix G, the directional smoothness $\sigma_{\mathrm{dir}}$ can be nontrivial even when the smoothness parameter $\sigma = 0$ . We now show that the perceptron satisfies the following mistake bound under directional smoothness.
+
+Theorem 7. Fix any $w^{\star} \in S^{d-1}$ and $b^{\star} \in \mathbb{R}$ . And suppose that the adversary satisfies $\sigma_{\mathrm{dir}}$ -directional smoothness. Then, with probability $1 - \delta$ , the online Perceptron (Algorithm 9 in Appendix G) satisfies
+
+$$
+\operatorname {R e g} _ {T} = \sum_ {t = 1} ^ {T} \mathbb {I} \left\{\hat {y} _ {t} \neq y _ {t} \right\} \lesssim (T / \sigma_ {\mathrm {d i r}}) ^ {\frac {2}{3}} \cdot \left(N _ {\mathrm {e r r}} \left(w ^ {\star}, b ^ {\star}\right)\right) ^ {\frac {1}{3}} + \log (\lceil \log T \rceil / \delta),
+$$
+
+where $N_{\mathrm{err}}(w^{\star},b^{\star}) = 1 + \sum_{i = 1}^{T}\mathbb{I}\{y_{t}\neq \mathrm{sign}(b^{\star} + \langle w^{\star},x_{t}\rangle)\}$ controls deviation from realizability.
+
+For simplicity, Theorem 7 is stated relative to a fixed $w^{\star} \in S^{d - 1}$ and $b^{\star} \in \mathbb{R}$ ; uniform bounds can be derived via a covering argument, at the expense of an additive $d\log (T / \delta \sigma_{\mathrm{dir}})$ term in the error bound. Unlike other algorithms proposed in this paper, Theorem 7 accommodates possibly non-realizable adversaries. It is also slightly more computationally expedient, not requiring the computation of the center of a John's ellipsoid. In contrast, its bound is polynomial in $T$ and $1 / \sigma_{\mathrm{dir}}$ , rather than logarithmic in $T$ and $1 / \sigma$ . There are situations where Algorithm 1 performs exponentially better than the Perceptron approach: suppose $x_{t}$ is uniform on an $\varepsilon$ -ball whose center is chosen by the adversary. Then we have $\sigma = \varepsilon^{-d}$ and so Theorem 5 implies that the John ellipsoid approach gives regret that scales as $O(d\log (d / \varepsilon) + \log (T))$ , whereas $\sigma_{\mathrm{dir}} \approx 1 / \varepsilon$ and so Theorem 7 only ensures regret that is polynomial in $\varepsilon$ . For further comparison, consult Remark 4 in Appendix G.
+
+# 5 Beyond the Linear Case
+
+While the results of Section 4 are technically interesting and have broad applications, they are limited to the specific linear setting. In this section, we show how our results can be extended, first to the more general affine setting, where the decision boundaries do not have to go through the origin, and then to a more general regime where we do not require linear decision boundaries.
+
+# 5.1 Affine Classification
+
+Our first generalization of Theorem 5 is to the setting where we allow our decision boundaries to be offset. Thus instead of assuming realizability with respect to $\mathcal{F}_{\mathrm{lin}}^d$ , we will assume that the adversary
+
+isrealizable with respect to
+
+$$
+\mathcal {F} _ {\text {a f f}} ^ {d} = \left\{x \mapsto \operatorname {s i g n} \left(\langle w, x \rangle + b\right) \mid w \in \mathcal {B} _ {1} ^ {d} \text {a n d} b \in \mathbb {R} \right\}. \tag {5.1}
+$$
+
+We have the following result:
+
+Corollary 8. Let $\mu$ be the uniform measure on $\mathcal{B}_1^d$ and suppose that we are in the smoothed online learning setting, where the adversary samples $x_{t}$ from a distribution that is $\sigma$ -smooth with respect to $\mu$ . Suppose that the adversary is realizable with respect to the function class $\mathcal{F}_{\mathrm{aff}}^d$ defined in (5.1). Then Algorithm 3 in Appendix E.1 is a computationally efficient algorithm for choosing $f_{t} \in \mathcal{F}_{\mathrm{aff}}^{d}$ such that for all $T$ , with probability at least $1 - \delta$ , it holds that
+
+$$
+\operatorname {R e g} _ {T} \leq 2 6 8 d \log (d) + 3 4 \log (T / (\sigma \delta)) + 5 6.
+$$
+
+As $\mathcal{F}_{\mathrm{lin}}^d \subset \mathcal{F}_{\mathrm{aff}}^d$ , the lower bound of Proposition 6 holds and Corollary 8 is tight up to a factor logarithmic in dimension. The proof is given in Appendix E.1 and proceeds by reducing to the linear setting of Theorem 5 by imbedding the problem into an online learning problem with contexts $\tilde{x}_t \in \mathbb{R}^{d+1}$ , carefully randomized so as to preserve their smoothness with respect to $\mu_{d+1}$ .
+
+# 5.2 Linear Classification Under a Feature map
+
+One limitation of the above discussion has been the assumption of linearity, which can be overly strong in many cases. In this section, we weaken this assumption in two ways. First, we show that if we transform the features with a well-behaved function, then we may still apply our above machinery. Second, we will show that our approach actually generalizes to polynomial decision boundaries through an elegant reduction. In both cases, the key technical challenge is to show that our transformed features remain smooth with respect to the uniform measure on a ball. Note that it is immediate that $\phi(x_{t})$ is smooth with respect to $\phi_{\star}\mu_{d}$ ; in order to apply our results, however, we require smoothness with respect to the uniform measure. As it is not true that $\phi_{\star}\mu_{d}$ is smooth with respect to $\mu_{d}$ for general $\phi$ , we require additional assumptions. We have the following result:
+
+Theorem 9. Let $\phi : \mathcal{B}_1^d \to \mathcal{B}_1^d$ be a function such that each coordinate function, $\phi_i : \mathbb{R} \to \mathbb{R}$ satisfies $\phi_i'(u) \geq \alpha$ for some $\alpha > 0$ . If we run Algorithm 4 in Appendix E.2 then, for all $T$ , with probability at least $1 - \delta$ , it holds that
+
+$$
+\mathrm {R e g} _ {T} \leq 1 3 6 d \log (d / \alpha) + 3 4 \log (T / (\sigma \delta)) + 5 6.
+$$
+
+Algorithm 4, the algorithm that achieves the above regret bound, is actually quite simple as it just runs Algorithm 1 on the data sequence $(\phi(x_{t}), y_{t})$ . A proof of a more general result, which applies to a larger class of maps $\phi$ , is available in Appendix E.2. Even in the setting of Theorem 9, though, standard transformations like the sigmoid already apply.
+
+We now turn to the more challenging case of polynomial features. We have the following result:
+
+Theorem 10. Let $\phi : \mathcal{B}_1^d \to \mathcal{B}_1^m$ be an $L$ -Lipschitz function whose coordinates are polynomials of degree at most $\ell$ in the coordinates of $x \in \mathcal{B}_1^d$ . Suppose that we are in the smoothed online learning setting where the $x_t$ are $\sigma$ -smooth with respect to $\mu_d$ and the $y_t$ are realizable with respect to $\mathcal{F}_{\mathrm{lin}}^m \circ \phi$ . Suppose further that the Jacobian of $\phi$ satisfies for some $\alpha > 0$ ,
+
+$$
+\det \left(\mathbb {E} _ {x \sim \mu_ {d}} \left[ D \phi (x) D \phi (x) ^ {T} \right]\right) \geq \alpha^ {2}.
+$$
+
+Then Algorithm 5 in Appendix E.3 is a computationally efficient algorithm such that for all $T$ , with probability at least $1 - \delta$
+
+$$
+\operatorname {R e g} _ {T} \lesssim m \log (m) + \log \left(\frac {1}{\alpha}\right) + \ell^ {2} m ^ {2} d \log^ {2} \left(\frac {d \ell T L}{\sigma \delta}\right).
+$$
+
+Algorithm 5 is a bit more complicated than simply applying Algorithm 1 to $(\phi(x_{t}), y_{t})$ because if $d \leq m$ , then $\phi(x_{t})$ can never be smooth with respect to $\mu_{m}$ by dimension constraints. To escape this difficulty, we define a "meta-point," $\overline{x}_{\tau}$ , which is the average of $\phi(x_{t})$ for multiple different $t$ . To understand why this might fix the problem, consider the identity imbedding of $S^{d-1} \subset \mathcal{B}_1^d$ : if we sample $x$ uniformly on $S^{d-1}$ , then the law of $x$ will not even be absolutely continuous with respect to $\mu_{d}$ but if we sample two points $x, x' \sim S^{d-1}$ then their average is absolutely continuous with respect to $\mu_{d}$ . We note that the conditions on $\phi$ are fairly mild due to the logarithmic dependence on both the Lipschitz constant and the lower bound on the determinant, which is typically no less than exponentially small in $d$ and $m$ .
+
+Proof Sketch of Theorem 10. Algorithm 5 proceeds initially in a similar way to Algorithm 1: we maintain a version space $\mathcal{F}_t \subset \mathcal{F}_{\mathrm{lin}}^m$ that gets updated every round and, when we change $w_t$ , we set it to be the center of the John ellipsoid of the version space. In contradistinction to the earlier algorithm, however, we do not update $w_t$ every time we make a mistake. Instead, for some parameter $p$ , we wait until we have misclassified a label $p$ times, i.e., we guessed $-1$ but $y_t$ was $1$ p times (or the reverse) and construct $\overline{x}_{\tau}$ to be the average of the $\phi(x_t)$ for each of these $p$ mistakes. Using a novel anti-concentration bound for determinants of certain random matrices (Proposition 41) as well as some techniques from geometric measure theory (Proposition 40), we show that $\overline{x}_{\tau}$ is smooth with respect to $\mu_m$ . We then apply the abstract decay lemma (Lemma 3) in much the same way as we did in the proof of Theorem 5. The details are in Appendix E.3.
+
+# 6 Beyond Binary Classification
+
+In the previous sections, we restricted our focus to binary classification; in this section we expand our scope to a $K$ -class setting and then further extend to a regression setting. Our results for the regression setting, combined with the reduction of Foster and Rakhlin [2020], are applied to the setting of contextual bandits in Appendix A.
+
+# 6.1 Multi-Class Classification
+
+We first generalize our results to multi-class classification. The targets are $y_{t} \in [K]$ some fixed $K$ and classifications are assigned by maximum inner-product:
+
+$$
+\mathcal {F} _ {K - \operatorname {l i n}} ^ {d} = \left\{x \mapsto f _ {\mathbf {w}} (x) = \underset {1 \leq i \leq K} {\arg \max } \left\langle w ^ {i}, x \right\rangle \mid \mathbf {w} = \left(w ^ {1}, \dots , w ^ {K}\right) \in \left(\mathcal {B} _ {1} ^ {d}\right) ^ {K} \right\}. \tag {6.1}
+$$
+
+Our algorithm is a direct reduction to binary classification. For each $i < j$ , we maintain an instance $\mathcal{A}_{\mathrm{bin}}^{(i,j)}$ of Algorithm 1 which makes binary predictions $\hat{y}_t^{(i,j)}$ of $y_t^{(i,j)} = \mathrm{sign}(\langle w_\star^i - w_\star^j, x_t \rangle)$ . We then set our $K$ -class prediction $\hat{y}_t$ as the first index $i$ for which $\hat{y}_t^{(i,j)} = 1$ for all $j > i$ . The key insight is that, even though the learner does not recieve feedback on all $\hat{y}_t^{(i,j)}$ in this way, we can always assign a mistake $\hat{y}_t = y_t$ to an error $y_t^{(i,j)} \neq \hat{y}_t^{(i,j)}$ for some $i < j$ . Formal pseudocode is given Algorithm 6 and a proof of the following regret bound is given in Appendix F.1.
+
+Theorem 11. Suppose we are in the realizable, smoothed, online learning setting where the adversary is realizable with respect to the $\mathcal{F}_{K\text{-lin}}^d$ in (6.1). Then, then for all $T$ , with probability at least $1 - \delta$ , the regret of Algorithm 6 is at most
+
+$$
+\operatorname {R e g} _ {T} \leq 1 3 6 K ^ {2} d \log (d) + 9 1 K ^ {2} \log \left(T K ^ {2} / (\sigma \delta)\right). \tag {6.2}
+$$
+
+The efficiency of the above algorithm follows from the efficiency of the binary classifiers $\mathcal{A}_{\mathrm{bin}}^{(i,j)}$ . We conjecture that the dependence on $K^2$ is an artifact of our reduction to $\binom{K}{2}$ base classifiers.
+
+# 6.2 Piecewise Regression
+
+This section extends $K$ -class classification to piecewise affine regression. We now suppose that the targets $y_{t}$ are real-valued, and realizable with respect to the following class of functions:
+
+$$
+\mathcal {G} _ {\mathcal {F}} = \left\{x \mapsto g _ {f} (x) = \sum_ {i = 1} ^ {K} g _ {i} (x) \mathbb {I} [ f (x) = i ] \middle | g _ {i} (x) = \langle a _ {i}, x \rangle \text {f o r} a _ {i} \in \mathbb {R} ^ {d} \text {a n d} f \in \mathcal {F} _ {K - \ln} ^ {d} \right\}. \tag {6.3}
+$$
+
+In contradistinction to the rest of the paper, where the adversary is allowed to play the $y_{t}$ adaptively subject only to the condition of realizability, in this section we suppose that the adversary is semi-oblivious in the sense that there is a ground-truth function chosen before the start of play and after learning begins, the adversary is only allowed to choose the contexts, $x_{t}$ . This assumption is natural in the aforementioned contextual bandits application in Appendix A.
+
+Theorem 12. Adopt the semi-oblivious, smoothed online learning setting, where the adversary begins by choosing $g_{f^{\star}}^{\star} \in \mathcal{G}_{\mathcal{F}}$ from (6.3), and, at each time $t$ , draws $x_{t}$ from a distribution that is $\sigma$ -smooth
+
+with respect to $\mu$ and sets $y_{t} = g_{f^{*}}^{\star}(x_{t})$ . Then, Algorithm 7 is an algorithm that is efficient in the number of calls to an ERM oracle over $\mathcal{G}_{\mathcal{F}}$ that satisfies for all $T$ , with probability at least $1 - \delta$ ,
+
+$$
+\operatorname {R e g} _ {T} \leq 1 3 6 K ^ {2} d \log (d) + 9 1 K ^ {2} \log \left(T K ^ {2} / (\sigma \delta)\right) + K ^ {2} (\ell + 1). \tag {6.4}
+$$
+
+In Appendix F.2 we prove a more general version of the above result that allows the regression functions on each piece to be polynomial. The intuition is to reduce $K$ -piece regression to $K$ -class classification, but where each of the "classes" materialize sequentially, once there are sufficiently many points observed to "determine" one of the pieces. The algorithm and proof are considerably more subtle, and are given in Appendices F.3 and F.4, respectively. We note that Algorithm 7 only requires the ERM oracle to be called on sets of size independent of $T$ , making the total runtime of the algorithm logarithmic in the horizon.
+
+# Acknowledgements
+
+AB acknowledges support from the National Science Foundation Graduate Research Fellowship under Grant No. 1122374. We also would like to thank Sofia Dubova for her help in translating Tarasov et al. [1988] and Michel Goemans for pointing to the closely related, English-language work of Khachiyan [1990].
+
+# References
+
+Keith Ball et al. An elementary introduction to modern convex geometry. Flavors of geometry, 31 (1-58):26, 1997.
+Shai Ben-David, David Pál, and Shai Shalev-Shwartz. Agnostic online learning. In COLT, volume 3, page 1, 2009.
+Dimitris Bertsimas and Santosh Vempala. Solving convex programs by random walks. Journal of the ACM (JACM), 51(4):540-556, 2004.
+Adam Block, Yuval Dagan, and Alexander Rakhlin. Majorizing measures, sequential complexities, and online learning. In Conference on Learning Theory, pages 587-590. PMLR, 2021.
+Adam Block, Yuval Dagan, Noah Golowich, and Alexander Rakhlin. Smoothed online learning is as easy as statistical learning. arXiv preprint arXiv:2202.04690, 2022.
+Anselm Blumer, Andrzej Ehrenfeucht, David Haussler, and Manfred K Warmuth. Learnability and the vapnik-chervonenkis dimension. Journal of the ACM (JACM), 36(4):929-965, 1989.
+Stephen Boyd and Lieven Vandenberghe. Convex optimization. Cambridge university press, 2004.
+Anthony Carbery and James Wright. Distributional and $\mathcal{L}^q$ -norm inequalities for polynomials over convex bodies in $\mathbb{R}^n$ . Mathematical research letters, 8(3):233-248, 2001.
+Koby Crammer, Ofer Dekel, Joseph Keshet, Shai Shalev-Shwartz, and Yoram Singer. Online passive-aggressive algorithms. Journal of Machine Learning Research, 7:551-585, 2006.
+Jack Elzinga and Thomas G Moore. A central cutting plane algorithm for the convex programming problem. Mathematical Programming, 8(1):134-145, 1975.
+Herbert Federer. Geometric measure theory. Springer, 2014.
+Dylan Foster and Alexander Rakhlin. Beyond ucb: Optimal and efficient contextual bandits with regression oracles. In International Conference on Machine Learning, pages 3199-3210. PMLR, 2020.
+Yoav Freund and Robert E Schapire. Large margin classification using the perceptron algorithm. Machine learning, 37(3):277-296, 1999.
+Alfred Gray. Tubes, volume 221. Springer Science & Business Media, 2003.
+Nika Haghtalab, Tim Roughgarden, and Abhishek Shetty. Smoothed analysis of online and differentially private learning. arXiv preprint arXiv:2006.10129, 2020.
+Nika Haghtalab, Tim Roughgarden, and Abhishek Shetty. Smoothed analysis with adaptive adversaries. arXiv preprint arXiv:2102.08446, 2021.
+
+Nika Haghtalab, Yanjun Han, Abhishek Shetty, and Kunhe Yang. Oracle-efficient online learning for beyond worst-case adversaries. arXiv preprint arXiv:2202.08549, 2022.
+Steve Hanneke. A bound on the label complexity of agnostic active learning. In Proceedings of the 24th International Conference on Machine Learning, ICML '07, page 353-360, New York, NY, USA, 2007. Association for Computing Machinery. ISBN 9781595937933. doi: 10.1145/1273496.1273541. URL https://doi.org/10.1145/1273496.1273541.
+Steve Hanneke. Rates of convergence in active learning. The Annals of Statistics, pages 333-361, 2011.
+Steve Hanneke et al. Theory of disagreement-based active learning. Foundations and Trends® in Machine Learning, 7(2-3):131-309, 2014.
+Elad Hazan and Tomer Koren. The computational power of optimization in online learning. In Proceedings of the forty-eighth annual ACM symposium on Theory of Computing, pages 128-141, 2016.
+Fritz John. Extremum problems with inequalities as subsidiary conditions, studies and essays presented to r. courant on his 60th birthday, january 8, 1948, 1948.
+Leonid Genrikhovich Khachiyan. An inequality for the volume of inscribed ellipsoids. Discrete & Computational Geometry, 5(3):219-222, 1990.
+Victor Klee and George J Minty. How good is the simplex algorithm. Inequalities, 3(3):159-175, 1972.
+Nick Littlestone. Learning quickly when irrelevant attributes abound: A new linear-threshold algorithm. Machine learning, 2(4):285-318, 1988.
+Martin Lotz. On the volume of tubular neighborhoods of real algebraic varieties. Proceedings of the American Mathematical Society, 143(5):1875-1889, 2015.
+Albert B Novikoff. On convergence proofs for perceptrons. Technical report, STANFORD RESEARCH INST MENLO PARK CA, 1963.
+ME Primak and BL Kheyfets. A modification of the inscribed ellipsoid method. Mathematical and computer modelling, 21(11):69-76, 1995.
+Luis A Rademacher. Approximating the centroid is hard. In Proceedings of the twenty-third annual symposium on Computational geometry, pages 302-305, 2007.
+Alexander Rakhlin and Karthik Sridharan. Online learning with predictable sequences. In Conference on Learning Theory, pages 993-1019. PMLR, 2013.
+Alexander Rakhlin and Karthik Sridharan. Online non-parametric regression. In Conference on Learning Theory, pages 1232-1264. PMLR, 2014.
+Alexander Rakhlin, Karthik Sridharan, and Ambuj Tewari. Online learning: Stochastic, constrained, and smoothed adversaries. Advances in neural information processing systems, 24:1764-1772, 2011.
+Alexander Rakhlin, Karthik Sridharan, and Ambuj Tewari. Online learning via sequential complexities. J. Mach. Learn. Res., 16(1):155-186, 2015a.
+Alexander Rakhlin, Karthik Sridharan, and Ambuj Tewari. Sequential complexities and uniform martingale laws of large numbers. Probability Theory and Related Fields, 161(1):111-153, 2015b.
+Igor Rivin. Surface area and other measures of ellipsoids. Advances in Applied Mathematics, 39(4): 409-427, 2007.
+Frank Rosenblatt. The perceptron: a probabilistic model for information storage and organization in the brain. Psychological review, 65(6):386, 1958.
+Tim Roughgarden, editor. Beyond the Worst-Case Analysis of Algorithms. Cambridge University Press, 2021.
+Daniel Russo and Benjamin Van Roy. Eluder dimension and the sample complexity of optimistic exploration. Advances in Neural Information Processing Systems, 26, 2013.
+Max Simchowitz, Horia Mania, Stephen Tu, Michael I Jordan, and Benjamin Recht. Learning without mixing: Towards a sharp analysis of linear system identification. In Conference On Learning Theory, pages 439-473. PMLR, 2018.
+
+Daniel A Spielman and Shang-Hua Teng. Nearly-linear time algorithms for graph partitioning, graph sparsification, and solving linear systems. In Proceedings of the thirty-sixth annual ACM symposium on Theory of computing, pages 81-90, 2004.
+Sergei Pavlovich Tarasov, Leonid Khachiyan, and Igor Erlikh. The method of inscribed ellipsoids. In Soviet Mathematics-Doklady, volume 37, pages 226-230, 1988.
+Jean Ville. Etude critique de la notion de collectif. Bull. Amer. Math. Soc, 45(11):824, 1939.
+Martin J Wainwright. High-dimensional statistics: A non-asymptotic viewpoint, volume 48. Cambridge University Press, 2019.
+Liwei Wang. Smoothness, disagreement coefficient, and the label complexity of agnostic active learning. Journal of Machine Learning Research, 12(7), 2011.
+Hermann Weyl. On the volume of tubes. American Journal of Mathematics, 61(2):461-472, 1939.
+Y Yomdin. The set of zeroes of an "almost polynomial" function. Proceedings of the American Mathematical Society, 90(4):538-542, 1984.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes] Our claimed contributions are efficiently achievable regret bounds for certain function classes in the smoothed online learning setting. Right before the related work section, we have a paragraph describing the structure and pointing to where each of the claims is discussed.
+(b) Did you describe the limitations of your work? [Yes] Note that we are only claiming results for particular function classes in the smoothed online learning setting (see contributions).
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes] See the statements of each proposition and lemma, along with the relevant preliminaries as needed.
+(b) Did you include complete proofs of all theoretical results? [Yes] All proofs are included in the appendix.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [N/A]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [N/A]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [N/A]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [N/A]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [N/A]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/images.zip b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..0acdb03f712d255943b6c075ca52be7ea7c2372a
--- /dev/null
+++ b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5769f4ef9fa719fbc663b203c7c6f4d99e63af7bfbf9a13f9a764254798b6f4f
+size 127204
diff --git a/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/layout.json b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..0dd6755bee56fa80537b3ca30d730acb9d19a202
--- /dev/null
+++ b/efficientandnearoptimalsmoothedonlinelearningforgeneralizedlinearfunctions/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9b216a43155f52441af2ad5f0c0e2884715898261c9a2ceef4cf4ca3ad5cadce
+size 679897
diff --git a/efficientarchitecturesearchfordiversetasks/d7d4713c-a551-4c5f-9085-376cb85650cc_content_list.json b/efficientarchitecturesearchfordiversetasks/d7d4713c-a551-4c5f-9085-376cb85650cc_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..f4aaf86f1c8e2c078b81d64092ce0652cff0730a
--- /dev/null
+++ b/efficientarchitecturesearchfordiversetasks/d7d4713c-a551-4c5f-9085-376cb85650cc_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bee8b8547fdd3184808d9fd4fd41c9e3487a3184cb72fee1385e14f1fb56cedf
+size 87470
diff --git a/efficientarchitecturesearchfordiversetasks/d7d4713c-a551-4c5f-9085-376cb85650cc_model.json b/efficientarchitecturesearchfordiversetasks/d7d4713c-a551-4c5f-9085-376cb85650cc_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..92e50a6f5abf2522e53cbc44cb4c0863e6b641bc
--- /dev/null
+++ b/efficientarchitecturesearchfordiversetasks/d7d4713c-a551-4c5f-9085-376cb85650cc_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5b0c0993ca07fea7f65a103d126b340ac8332f13a28c32a70650dda0901c4ac3
+size 110523
diff --git a/efficientarchitecturesearchfordiversetasks/d7d4713c-a551-4c5f-9085-376cb85650cc_origin.pdf b/efficientarchitecturesearchfordiversetasks/d7d4713c-a551-4c5f-9085-376cb85650cc_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..83d81d645a811f9999c899a118f6e478d1628a6f
--- /dev/null
+++ b/efficientarchitecturesearchfordiversetasks/d7d4713c-a551-4c5f-9085-376cb85650cc_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5627003551efad674b5d46d4a500b9f8383bdd049d5bdfa47bee613259bb5478
+size 916282
diff --git a/efficientarchitecturesearchfordiversetasks/full.md b/efficientarchitecturesearchfordiversetasks/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..eb8fa5258a5050779c5cca5af8a7ea4420aebe58
--- /dev/null
+++ b/efficientarchitecturesearchfordiversetasks/full.md
@@ -0,0 +1,325 @@
+# Efficient Architecture Search for Diverse Tasks
+
+Junhong Shen*
+
+Carnegie Mellon University junhongs@andrew.cmu.edu
+
+Mikhail Khodak*
+
+Carnegie Mellon University khodak@cmu.edu
+
+Ameet Talwalkar
+
+Carnegie Mellon University talwalkar@cmu.edu
+
+# Abstract
+
+While neural architecture search (NAS) has enabled automated machine learning (AutoML) for well-researched areas, its application to tasks beyond computer vision is still under-explored. As less-studied domains are precisely those where we expect AutoML to have the greatest impact, in this work we study NAS for efficiently solving diverse problems. Seeking an approach that is fast, simple, and broadly applicable, we fix a standard convolutional network (CNN) topology and propose to search for the right kernel sizes and dilations its operations should take on. This dramatically expands the model's capacity to extract features at multiple resolutions for different types of data while only requiring search over the operation space. To overcome the efficiency challenges of naive weight-sharing in this search space, we introduce DASH, a differentiable NAS algorithm that computes the mixture-of-operations using the Fourier diagonalization of convolution, achieving both a better asymptotic complexity and an up-to-10x search time speedup in practice. We evaluate DASH on ten tasks spanning a variety of application domains such as PDE solving, protein folding, and heart disease detection. DASH outperforms state-of-the-art AutoML methods in aggregate, attaining the best-known automated performance on seven tasks. Meanwhile, on six of the ten tasks, the combined search and retraining time is less than 2x slower than simply training a CNN backbone that is far less accurate.
+
+# 1 Introduction
+
+The success of deep learning for computer vision and natural language processing has spurred growing interest in enabling similar breakthroughs for other domains such as biology, healthcare, and physical sciences. Consequently, there is enormous potential for neural architecture search to help automate model development in these diverse areas. However, while extensive NAS research has been devoted to improving the search speed [1,2] and automatically attaining state-of-the-art performance on vision datasets such as CIFAR and ImageNet [3], the resulting algorithms have subpar performance beyond the tasks on which they were developed. For example, in the analysis of NAS-Bench-360 [4], a recent benchmark designed for improving task diversity in NAS evaluation, the authors showed a significant gap between models found by NAS methods, such as DARTS [2] and DenseNAS [5], and hand-crafted expert architectures on a number of distinct applications.
+
+To improve the generalizability of AutoML methods, recent works such as AutoML-Zero [6] and XD-operations [7] propose to relax the inductive biases encoded in the standard search spaces. However, the former is not designed for practical deployment, and the latter is too expensive to execute even for simple problems like CIFAR-100 (Fig. 1b). Hence we ask: is there an approach that can provide sufficient expressivity to yield high accuracy across multiple domains, while still retaining the faster search and the more efficient final models of discrete architecture search?
+
+In this work, we answer in the affirmative by introducing a novel NAS method called DASH (Diverse-task Architecture SearcH). In order to attain multi-domain capability, DASH adapts standard CNN backbones to various learning problems by finding substitutes for their layer operations. Concretely, we consider a search space of cross-scale dilated convolutions which are effective for multi-scale feature extraction [8, 9] and context aggregation [10, 11]. Our key difference from past search spaces is that we explicitly consider filters with a wide range of kernel sizes and dilations—while most NAS methods only handle kernels with maximum size 5 and dilation rate 2, our proposed operator space includes not only the conventional small kernels but also significantly larger ones with size 15 or dilation 127 (Fig. 2). This design choice is motivated by the fact that large kernels can
+
+capture input relations for dense prediction problems [12], model long-range dependencies for sequence tasks [13, 14], and resemble global-attention in Transformers [15]. Thus, DASH's cross-scale search space enables adaptation to diverse downstream tasks, unlike prior NAS work which targets image classification and assumes that small kernels are sufficient.
+
+However, efficiently searching for an appropriate kernel configuration in this expansive cross-scale search space is non-trivial. Indeed, for existing NAS algorithms, the cost of exploring a combinatorially large set of operators is substantial. Even for weight-sharing methods that are known for efficiency, e.g., DARTS [16], the computational complexity scales directly with the number of kernels considered and quadratically with the largest kernel size. To overcome this obstacle, DASH explores multi-scale convolutions via three techniques—the first two exploit mathematical properties of convolutions, and the last one takes advantage of fast matrix multiplication on GPUs. Specifically:
+
+1. Using the linearity of convolutions, we mix several convolutions by computing one convolution equipped with a combined kernel rather than applying each filter separately and aggregating multiple outputs. While the number of convolution computations required by the naive aggregation of $|K|$ possible kernel sizes and $|D|$ possible dilations is $\mathcal{O}(|K||D|)$ , our approach has $\mathcal{O}(1)$ complexity, independent of the search space size.
+2. Using the diagonalization of convolutions, we relegate a major portion of the computation to element-wise multiplication in the Fourier domain, minimizing the effect of the largest kernel size on the complexity of our algorithm. For instance, a standard 1D convolution requires $\mathcal{O}(nk)$ operations to convolve a size- $k$ kernel with a length- $n$ input, but a Fourier convolution takes only $\mathcal{O}(n\log n)$ , a critical improvement that makes searching over large kernels significantly easier.
+3. Our final strategy is to use Kronecker products of undilated kernels and small sparse matrices to compute dilated kernels quickly on GPUs. This brings an additional two-fold speedup on top of the previous techniques.
+
+Aside from these innovations, DASH employs the standard weight-sharing scheme of training a supernet, discretizing to obtain a model, and retraining the model for end tasks [2]. We analyze the asymptotic complexity of the first two techniques and verify the practical utility when all three are combined together. In particular, DASH achieves a ten-fold speedup in total for differentiable NAS over the multi-scale search space. Moreover, we show that searching over large kernels is necessary to solve diverse problems and that each technique on its own cannot scale in this large-kernel setting.
+
+In terms of accuracy performance, we evaluate DASH on ten datasets spanning multiple application areas such as PDE solving, protein folding, and disease prediction from NAS-Bench-360 [4]. As shown in Fig. 1, DASH yields models with better aggregate performance than those returned by leading AutoML methods as well as hand-designed task-specific architectures. As for individual tasks, DASH beats all past automated approaches on seven of the ten problems and exceeds hand-designed models on seven, simultaneously maintaining strong efficiency relative to weight-sharing methods
+
+
+(a)
+
+
+(b)
+Figure 1: (a) Comparing the aggregate performance of the best AutoML methods (task-wise), hand-designed models, and DASH on ten diverse tasks via performance profiles (defined in Section 4.1). Larger values (larger fractions of tasks on which a method is within log $\tau$ -factor of the best) are better. (b) Runtime for Wide ResNet, DARTS, XD, and DASH on CIFAR-100. XD is too expensive to be applied to other tasks considered in this work [4,7].
+
+like DARTS. The empirical success of DASH implies that CNNs with appropriate kernels can be competitive baselines for problems where expert architectures are not available. Our code is made public at https://github.com/sjunhongshen/DASH.
+
+# 2 Related Work
+
+Neural architecture search (NAS) aims to automate the design of neural networks. Recently, there has been significant progress in both search space design [17, 27] and search strategy development [11, 18, 2, 19, 3]. However, these methods are mostly evaluated on image classification or segmentation, with a few focusing on new applications such as image restoration [20], audio classification [21], and machine translation [22]. Problems beyond the vision and language domains are less-explored.
+
+In this work, we seek to improve the generalizability of NAS by a morphism-based approach [23, 24, 7] that adapts existing CNN backbones to target tasks. We specifically focus on expanding the operation space to multiple types of convolutions, simultaneously varying the kernel size and the dilation factor. Past work in related directions has at most studied the easier problem of altering dilation alone, and only for vision tasks [25]. Therefore, although convolution has been an integral part of NAS, how to search over a large set of convolutional operators remains an open problem. In the following, we identify four types of solutions from existing work and illustrate their limitations.
+
+Differentiable Architecture Search (DARTS) We can treat convolutions as ordinary operators and apply a scalable NAS algorithm. In particular, DARTS [2] introduces continuous relaxation to the weight-sharing paradigm [1] and allows us to gain information about many networks efficiently by training a combined supernet. The algorithm relaxes the discrete set of operations at each edge in a computational graph as a softmax so the search process is end-to-end differentiable and amenable to regular optimizers. After search, it discretizes the weights to output a valid architecture. The original DARTS search space contains only four convolutions with kernel sizes no larger than 5 and dilation rates no larger than 2. While this small search space might be enough for low-resolution image input, it is insufficient for diverse tasks such as high-dimensional time series problems [4]. Although one could add more convolutions one-by-one to the operator set to augment performance, this approach scales poorly, as reflected in the limited search spaces of similar methods like AMBER [26]. In fact, AMBER has to shift the kernel size up to achieve good performance on long-sequence genomic data.
+
+MergeNAS and RepVGG An alternative way to explore the convolutional search space is to take advantage of the operator's linearity. That is, we can first mix the kernels and then apply convolution once, unlike DARTS which computes each convolution separately and outputs the aggregated result to the next layer. This kernel-mixing strategy, which we call mixed-weights and will formally define in Section 3.2, has been employed by MergeNAS [27] and RepVGG [28] to improve architecture search robustness and VGG inference speed, respectively. It works well for a few small kernels. However, we will show later that similar to DARTS, mixed-weights on its own is also insufficient for searching over a diverse set of large kernels which is crucial to solving a wide range of problems.
+
+Expressive Diagonalization (XD) Apart from linearity, XD-operations [7] propose to utilize the convolutional theorem in architecture search. In particular, XD expresses the convolution acting on input $\mathbf{x}$ with filter $\mathbf{w}$ as $\mathbf{K} \, \mathrm{diag}(\mathbf{L} \mathbf{w}) \mathbf{M} \mathbf{x}$ , where $\mathbf{K}, \mathbf{L}, \mathbf{M}$ are appropriate discrete Fourier transforms, and constructs an expansive search space by replacing these transforms with searched kaleidoscope matrices [29]. Although this new search space includes all types of convolutions, the search process is unacceptably long even for simple benchmarking tasks such as CIFAR-100 (Fig. 1b), let alone the more complex set of diverse problems that we consider in this paper. In addition, the output architectures of XD are as inefficient as the supernet due to the absence of a discretization step.
+
+Single-Path NAS Lastly, Single-Path NAS [30] defines a large filter and uses its subsets for smaller filters. This DARTS-based method compensates operator heterogeneity for efficiency during search. It does not handle search spaces with many large kernels and is not evaluated on diverse tasks.
+
+Outside the field of AutoML, there is also emerging interest in designing general-purpose models such as Perceiver IO [31] and Frozen Pretrained Transformer [32]. However, these Transformer-based models do not adapt the network to the target tasks and are generally harder to train compared with CNNs. In Table 2, we evaluate Perceiver IO and show that its performance is not ideal. Recent works also propose to learn the kernel sizes for CNNs from the data [33], but they take an entirely different approach from NAS by multiplying the response of a convolution layer with a learnable Gaussian mask.
+
+# Algorithm 1 DASH
+
+Input: training data $Z$ , loss function $l$ , the set of kernel sizes $K$ , the set of dilation rates $D$ , and subsampling ratio $p$
+
+Initialize the backbone and replace each Conv layer with the mixed operation $\mathbf{A}\mathbf{g}\mathbf{g}\mathbf{C}\mathbf{n}\mathbf{v}_{K,D}$ while not converged do
+
+Subsample $p|Z|$ training points uniformly at random
+
+Compute forward pass using Equation 4
+
+Descend the architecture parameters $\alpha$ by $\nabla_{\alpha}l(\mathbf{w},\alpha)$ and the model weights $\mathbf{w}$ by $\nabla_{\mathbf{w}}l(\mathbf{w},\alpha)$ end while
+
+Select arg $\max_{k\in K,d\in D}\alpha_{k,d}$ for each AggConv layer
+
+Tune retraining hyperparameters on a validation subset of the training data
+
+Retrain the discretized model with all training data
+
+# 3 Methods
+
+Now, we describe the details of DASH (Algorithm II). We first explain how DASH leverages existing networks to initialize the supernet and generate different models for diverse tasks. Then, we formally define the multi-scale convolution search space and propose a fast way to search this space using the three efficiency-motivated techniques mentioned earlier. Finally, we outline the procedure for discretizing the search space and retraining the searched model.
+
+# 3.1 Decoupling Topology and Operations
+
+Every architecture is a mapping from model weights to functions and can be described by a directed acyclic graph $G(V, E)$ . Each edge in $E$ is characterized by $(u, v, \mathbf{Op})$ , where $u, v \in V$ are nodes and $\mathbf{Op}$ is an operation applied to $u$ . Node $v$ aggregates the outputs of its incoming edges. NAS aims to automatically select the edge operations and the graph topology to optimize some objective. For each edge, $\mathbf{Op}$ is chosen from a search space $S = \{\mathbf{Op}_a | a \in A\}$ where $a \in A$ are architecture parameters. In past work, $A$ usually indexes a small set of operations. For instance, the DARTS search space specifies $A_{discrete} = \{1, \dots, 8\}$ with $S = \{\text{Zero}, \text{Id}, \text{MaxPool}_{3 \times 3}, \text{AvgPool}_{3 \times 3}, \text{Conv}_{3 \times 3}, \text{Conv}_{5 \times 5}, \text{DilatedConv}_{3 \times 3,2}, \text{DilatedConv}_{5 \times 5,2}\}$ . However, $A$ can also be defined systematically to identify operator properties, e.g., $\{(\text{kernel size } k, \text{ dilation } d)\}$ for convolutions.
+
+A common way to determine the network topology is to search for blocks of operations and stack several blocks together. In this work, we take a different, morphism-based approach [23, 24, 7]: we use existing networks as backbones and replace certain layers in the backbone with the searched operations. Specifically, we select a set of architectures to accommodate both 2D and 1D datasets. Convolutional layers with different kernels can then be plugged into these networks. An advantage of decoupling topology and operation search is flexibility: the searched operators can vary from the beginning to the end of a network, so features at different granularities can be processed differently.
+
+We pick Wide ResNets (WRNs) [34, 35] as the backbone networks due to their simplicity and effectiveness in image and sequence modeling. Before search, the supernet is initialized to the backbone. Then, all Conv layers are substituted with an operator $\mathbf{AggConv}_{K,D}$ (short for aggregated convolution) that represents the new search space which we now define. For simplicity, our mathematical discussion will stick to the 1D case, though our experiments are on both 1D and 2D data.
+
+# 3.2 Efficiently Searching for Multi-Scale Convolutions
+
+A convolution filter is specified by the kernel size $k$ and the dilation rate $d$ (we do not consider stride which does not change the filter shape). The effective filter size is $(k - 1)d + 1$ with nonzero entries separated by $d - 1$ zeros. Let $\mathbf{Conv}_{k,d}$ be the convolution with kernel size $k$ , dilation rate $d$ , $c_{in}$ input channels, and $c_{out}$ output channels. Given input data with shape $n$ , let $K$ be our interested set of kernel sizes, $D$ the set of dilations. We define the AggConv $_{K,D}$ search space as
+
+$$
+S _ {\mathbf {A} \mathbf {g} \mathbf {g} \mathbf {C} \mathbf {n v} _ {K, D}} = \left\{\mathbf {C} \mathbf {n v} _ {k, d} \mid k \in K, d \in D \right\}. \tag {1}
+$$
+
+Table 1: Complexity of different methods for computing AggConv. For notation, $\bar{K} \coloneqq |D| \cdot \sum_{k \in K} k$ , $\bar{D} \coloneqq \max_{k,d} (k - 1)d + 1$ . A detailed analysis is provided in Appendix A.2
+
+| Method | MULTs | ADDs |
| mixed-results (Eqn.2) | (cincoutK+coout|K||D|)n | (cincoutK+coout|K||D|)n |
| mixed-weights (Eqn.3) | cincout(K+Dn) | cincoutD(|K||D|+n) |
| DASH (Eqn.4) | cincout(K+n)+O(cincoutn log n) | cincout(|K||D|D+n)+O(cincoutn log n) |
+
+Hence, $A = K\times D$ in previous notations. $S_{\mathbf{AggConv}_{K,D}}$ contains a collection of convolutions with receptive field size ranging from $k_{min}$ to $d_{\mathrm{max}}(k_{\mathrm{max}} - 1) + 1$ , which allows us to discover models that process the input with varying resolution at each layer.
+
+To retain the efficiency of discrete NAS, we apply the continuous relaxation scheme of DARTS to $S_{\mathbf{AggConv}_{K,D}}$ , which mixes all operations in the space using architecture parameters $\{\alpha_{k,d} \in \triangle_{|K||D|} | (k,d) \in K \times D\}$ . So the output of each edge in the computational graph is
+
+$$
+\operatorname {A g g} \operatorname {C o n v} _ {K, D} (\mathbf {x}) := \sum_ {k \in K} \sum_ {d \in D} \alpha_ {k, d} \cdot \operatorname {C o n v} \left(\mathbf {w} _ {k, d}\right) (\mathbf {x}). \tag {2}
+$$
+
+Here $\{\mathbf{w}_{k,d}|(k,d)\in K\times D\}$ are the kernel weights. The resulting supernet can be trained end-to-end, and our hope is that after search, the most important operation is assigned the highest weight. However, the complexity of computing the above summation directly, a baseline algorithmic approach we call mixed-results, is $\mathcal{O}(c_{in}c_{out}(|K||D| + \bar{K})n)$ , where $\bar{K} := |D|\sum_{k\in K}k$ . Mixed-results can be expensive when we increase the maximum element in $K$ or $D$ with larger input size $n$ . To improve upon it, we propose three techniques which build up to the efficiency-oriented DASH.
+
+# 3.2.1 Technique 1: Mixed-Weights
+
+Since convolution is linear, instead of computing $|K||D|$ convolutions, we can combine the kernels and compute convolution once. We call this approach mixed-weights:
+
+$$
+\mathbf {A g g} \mathbf {C o n v} _ {K, D} (\mathbf {x}) = \mathbf {C o n v} \left(\sum_ {k \in K} \sum_ {d \in D} \alpha_ {k, d} \cdot \mathbf {w} _ {k, d} ^ {\prime}\right) (\mathbf {x}). \tag {3}
+$$
+
+Here $\mathbf{w}'$ is the properly padded version of $\mathbf{w}$ (appending 0's at the end of each dimension) so that filters of different sizes can be added. The aggregated kernel has size $\bar{D} := \max_{k,d}(k - 1)d + 1$ and the $n$ -dependent term of the complexity of mixed-weights is $c_{in}c_{out}\bar{D}n$ . Hence, it removes the direct dependence of the leading-order term on $|K||D|$ , the search space size, that mixed-results had.
+
+# 3.2.2 Technique 2: Fourier Convolution
+
+If we wish to increase the kernel size and dilation with the input size, the complexity of mixed-weights will still grow implicitly with the search space size through the dependence on $\bar{D}$ . To address this issue, we combine the kernel re-weighting idea with another technique motivated by the convolution theorem. Given a kernel $\mathbf{w}$ , recall that $\mathbf{Conv}(\mathbf{w})(\mathbf{x}) = \mathbf{F}^{-1}\mathrm{diag}(\mathbf{F}\mathbf{w}^{\prime})\mathbf{F}\mathbf{x}$ , where $\mathbf{F}$ is the discrete Fourier transform (DFT) and $\mathrm{diag}(\mathbf{z})$ is a diagonal matrix with entries $\mathbf{z}$ . In other words, convolution involves multiplying the DFT of the kernel by that of the input. Since the DFT can be applied in time $\mathcal{O}(n\log n)$ using the Fast Fourier Transform (FFT) and apart from that we only need element-wise multiplication, this yields an efficient approach to reducing dependence on the combined kernel size $\bar{D}$ . While Roberts et al. [7] replaced the DFTs with a continuous set of matrices for XD-operations, our approach can be viewed as replacing the middle DFT with a discrete set of matrices for the purpose of efficiency. Accordingly, DASH computes $\mathbf{AggConv}_{K,D}$ as follows:
+
+$$
+\mathbf {A g g} \mathbf {C o n v} _ {K, D} (\mathbf {x}) = \mathbf {F} ^ {- 1} \operatorname {d i a g} \left(\mathbf {F} \left(\sum_ {k \in K} \sum_ {d \in D} \alpha_ {k, d} \cdot \mathbf {w} _ {k, d} ^ {\prime}\right)\right) \mathbf {F} \mathbf {x}. \tag {4}
+$$
+
+Note that while the kernel changes for each $\mathbf{Conv}_{k,d}$ , the input does not. Hence, we also save time by transforming the input to the frequency domain only once.
+
+
+Figure 2: $\log_{10}$ time for one search epoch vs. number of ops in $S_{\mathbf{AggConv}_{K,D}}$ . We vary the search space by letting $K = \{2p + 1|1\leq p\leq c\}$ , $D = \{2^q -1|1\leq q\leq c\}$ and increasing $c$ from 1 to 7.
+
+
+Figure 3: $\log_{10}$ time for one search epoch vs. input length of single-channel 1D data. We fix $K = \{3,5,7,9,11\}$ , $D = \{1,3,7,15,31\}$ and test $n \in \{2^5, \ldots, 2^{12}\}$ .
+
+In Table I, we report the theoretical complexities of the baselines and DASH, the latter leveraging both Technique 1 and 2. It is easy to obtain the operation complexities of mixed-weights and mixed-results. For DASH, the number of multiplications and additions can be attributed to the inner weight sum and multi-channel product (the first term) as well as three FFTs (the second). A detailed analysis is provided in Appendix A.2 We see that mixed-weights is favorable to mixed-results when $\bar{D} < \bar{K} = \mathcal{O}(|D|k_{\max}^2)$ , which occurs with large kernels and a few dilations. On the other hand, only DASH completely separates the dominant terms containing $c_{in}c_{out}n$ from the size of the search space and its elements, replacing them by $\mathcal{O}(\log n)$ , which is small for any realistic $n$ . As we increase $k_{\max}$ and $d_{\max}$ for larger inputs, this will also lead to a slower asymptotic increase in complexity, making DASH an attractive choice for the multi-scale search space where $\bar{D}$ is large by design to extract possible long-range dependencies in the data.
+
+# 3.2.3 Technique 3: Kronecker Dilation
+
+To efficiently implement the kernel summation in mixed-weights and DASH on a GPU, we introduce our final technique: after initializing $\mathbf{w}_{k,d}$ for each $\mathbf{Conv}_{k,d}$ separately, we use a Kronecker product $\otimes$ to transform the undilated kernels into dilated forms. For example, to compute a 2D convolution with dilation $d$ , we introduce the sparse pattern matrix $\mathbf{P} \in \mathbb{R}^{d \times d}$ whose entries are all 0's except for the upper-left entry $\mathbf{P}_{1,1} = 1$ :
+
+$$
+\mathbf {P} = \left[ \begin{array}{c c c c} 1 & 0 & \dots & 0 \\ 0 & 0 & \dots & 0 \\ \vdots & \vdots & \ddots & \vdots \\ 0 & 0 & \dots & 0 \end{array} \right]. \tag {5}
+$$
+
+Then, $\mathbf{w}_{k,d} = \mathbf{w}_{k,1}\otimes \mathbf{P}$ . Beyond the theoretical gains shown in Wu et al. [36], this dilation strategy is empirically faster than the standard way of padding 0's into $\mathbf{w}_{k,1}$ (Fig.2 and 3). After dilating the kernels, we sum them together, zero-pad to match the input size, and apply the FFTs.
+
+# 3.2.4 Ablation Study for the Proposed Techniques
+
+To check that our asymptotic analysis leads to actual speedups and perform an ablation study on the proposed techniques, we evaluate the three methods on single-channel 1D input (experiment details are in Appendix A.3). Since both mixed-weights and DASH require kernel summation, which can be implemented with Kronecker dilation (Technique 3), we compare five methods in total.
+
+Fig. 2 illustrates the combined forward- and backward-pass time in log scale for one search epoch vs. the size of $S_{\mathbf{AggConv}_{K,D}}$ when $n = 1000$ . For small $\bar{D}$ , the FFT overhead makes DASH runtime slightly longer but the difference is negligible. However, as $\bar{D}$ increases, the DASH curves grow much slower whereas the runtimes for the other methods scale with the number of operations. In Fig. 3 we fix $K$ and $D$ to study how runtime is affected by input size $n$ . Both mixed-results and mixed-weights become extremely inefficient for large $n$ 's which commonly occur in time-series or signal processing. Surprisingly, DASH's runtime does not increase much with $n$ . We hypothesize that this is due to wallclock-time being dominated by data-passing at that speed.
+
+In general, Technique 1 on its own scales poorly for the considered search space. This is why methods like MergeNAS [27] cannot be used in our setting. Though XD makes use of Technique 2, it considers a parametrized space with infinitely many operations that need to be continuously evolved and is too expensive to be applied to tasks beyond CIFAR-100 (c.f. Fig. [1b]). Technique 3 contributes to $2 \times$ speedups for both mixed-weights and DASH. Overall, DASH (Kronecker) leads to about $10 \times$ search-time speedups compared to the mixed-results scheme of DARTS for both the large operation space and large input size regimes. Hence, we use this version of DASH in later experiments.
+
+# 3.3 The Full Pipeline: Architecture Search, Hyperparameter Optimization, and Retraining
+
+Having shown the main techniques for searching a large space of kernel patterns, we now detail the full search and model development pipeline. Given a dataset, we set $K = \{3 + d(p - 1) | 1 \leq p \leq p_{\max}\}$ for kernel sizes and $D = \{2^q - 1 | 1 \leq q \leq q_{\max}\}$ for dilations. For 2D input, we set $d$ to 2, $p_{\max}$ to 4, and $q_{\max}$ to 4. For longer 1D sequence data, we set $d = 4$ , $p_{\max} = 5$ , and $q_{\max} = 4$ . For instance, CIFAR has size $3 \times 32 \times 32$ where 3 is the number of channels and $n = 32$ . The corresponding $K$ is $\{3, 5, 7, 9\}$ and $D$ is $\{1, 3, 7, 15\}$ . To normalize architecture parameters into a probability distribution, we adopt the soft Gumbel Softmax activation, similar to Xie et al. [18].
+
+The backbone networks are as follows. For 2D tasks, we use WRN 16-1 as the search backbone to accelerate supernet training and WRN 16-4 for retraining. For 1D tasks, we use 1D WRN [35] in the entire pipeline. During search, we subsample the training data at each epoch. Given the loss for the target task, DASH jointly optimizes the model weights and the architecture parameters using direct gradient descent. This single-level optimization is more efficient than two-stage NAS, which finds initial assignments for architecture parameters and trains the candidates from scratch.
+
+After searching for a predefined number of epochs, we discretize the search space and pick $\mathbf{Conv}_{k,d} \in S_{\mathbf{AggConv}_{K,D}}$ with the largest weight for each layer. The final model has a similar overall structure to the backbone, but the intermediate operations are tailored to the target task. To improve training stability, we additionally add a simple hyperparameter tuning stage between search and retraining using grid search (configuration space shown in Appendix A.5.2).
+
+For each setting, we train the discretized model on a subset of the training data for fewer epochs so the tuning cost is a small fraction of the entire pipeline's cost (Table 6). Then, we evaluate the performance on a holdout validation set and select the configuration with the best validation score. As a final step, we retrain the discretized model with the optimal hyperparameters on all training data until convergence. Like other weight-sharing methods with discretization, our final model will be more efficient than the supernet.
+
+# 4 Evaluation
+
+We evaluate the performance of DASH on diverse tasks using ten datasets from NAS-Bench-360 [4], a benchmark spanning multiple application domains, input dimensions, and learning objectives. These include classical vision tasks such as CIFAR-100 where CNNs do well, scientific computing tasks such as Darcy Flow where standard CNN backbones can perform poorly [7, 37], sequence tasks such as DeepSEA where large dilations are preferred [13, 26], and many others. Thus, our evaluation will not only test whether DASH can find good architectures in the proposed new search space, but also investigate whether multi-scale convolution is a strong competitor for solving different problems. In fact, our results show that DASH is a top choice for many tasks, obtaining in-aggregate the best speed-accuracy trade-offs among the methods we evaluate (c.f. Fig. 5).
+
+# 4.1 Baselines and Experimental Setup
+
+For each NAS-Bench-360 task, we compare DASH with the following methods: DenseNAS [5] and GAEA PC-DARTS [3], which represent general NAS; Auto-DeepLab [38] and AMBER [26], which represent specialist NAS methods for dense prediction and 1D tasks, respectively; 1D temporal convolutional network (TCN) [13], regular WRN, and WRN with hyperparameter tuned ASHA [39], which represent natural NAS baselines; and Perceiver IO [31], which represents non-NAS general-purpose models. While these results are available in Tu et al. [4], we additionally add a BABY DASH
+
+Table 2: Error rates (lower is better) on NAS-Bench-360 tasks across diverse application domains and problem dimensions (the last three problems are 1D and the rest are 2D). DASH beats all the other NAS methods on 7/10 tasks and exceeds hand-designed expert models on 7/10 tasks. Scores of DASH are averaged over three trials. Scores of the baselines are from Tu et al. [4]. See Table5 in the Appendix A.6 for standard deviations.
+
+ | CIFAR-100 0-1 error (%) | Spherical 0-1 error (%) | Darcy Flow relative \( \ell_2 \) | PSICOV MAE8 | Cosmic 1-AUROC | NinaPro 0-1 error (%) | FSD50K 1-mAP | ECG 1-F1 | Satellite 0-1 error (%) | DeepSEA 1- AUROC |
| Expert | 19.39 | 67.41 | 0.008 | 3.35 | 0.13 | 8.73 | 0.62 | 0.28 | 19.8 | 0.30 |
| WRN | 23.35 | 85.77 | 0.073 | 3.84 | 0.24 | 6.78 | 0.92 | 0.43 | 15.49 | 0.40 |
| TCN | - | - | - | - | - | - | - | 0.57 | 16.21 | 0.44 |
| WRN-ASHA | 23.39 | 75.46 | 0.066 | 3.84 | 0.25 | 7.34 | 0.91 | 0.43 | 15.84 | 0.41 |
| DARTS-GAEA | 24.02 | 48.23 | 0.026 | 2.94 | 0.22 | 17.67 | 0.94 | 0.34 | 12.51 | 0.36 |
| DenseNAS | 25.98 | 72.99 | 0.10 | 3.84 | 0.38 | 10.17 | 0.64 | 0.40 | 13.81 | 0.40 |
| Auto-DL | - | - | 0.049 | 6.73 | 0.49 | - | - | - | - | - |
| AMBER | - | - | - | - | - | - | - | 0.67 | 12.97 | 0.68 |
| Perceiver IO | 70.04 | 82.57 | 0.24 | 8.06 | 0.48 | 22.22 | 0.72 | 0.66 | 15.93 | 0.38 |
| BABY DASH | 25.56 | 63.45 | 0.016 | 3.94 | 0.16 | 8.28 | 0.62 | 0.37 | 13.29 | 0.37 |
| DASH | 24.37 | 71.28 | 0.0079 | 3.30 | 0.19 | 6.60 | 0.60 | 0.32 | 12.28 | 0.28 |
+
+baseline: we run DASH in the DARTS convolution space with $K = \{3,5\}$ and $D = \{1,2\}$ to study whether large kernel sizes and dilations are necessary to strong performance across-the-board. Finally, we compare our method to the expert architectures selected by NAS-Bench-360. These models are representatives of the best that hand-crafting has to offer.
+
+Each dataset is preprocessed and split using the NAS-Bench-360 script, with the training set being used for search, hyperparameter tuning, and retraining. To construct the multi-scale search space, we set $K$ and $D$ according to the rules in Section 3.3. We use the default SGD optimizer for the WRN backbone and fix the learning rate schedule as well as the gradient clipping threshold for every task. The entire DASH pipeline can be run on a single NVIDIA V100 GPU, which is also the system that we use to report the runtime cost. Full experimental details can be found in the Appendix.
+
+We evaluate the performance of all competing methods following the NAS-Bench-360 protocol. We first report results of the target metric for each task by running the model of the last epoch on the test data. Then, we report aggregate results via performance profiles [40], a technique that considers both outliers and small performance differences to compare methods across multiple tasks robustly. In such plots, each curve represents one method. The $\tau$ on the $x$ -axis denotes the fraction of tasks on which a method is no worse than a $\tau$ -factor from the best.
+
+# 4.2 Results and Discussion
+
+We present the accuracy results for each task in Table 2 and the performance profiles in Fig. 4. Fig. 4 clearly demonstrates that DASH is superior to other competing methods in terms of aggregate performance. In particular, it ranks first among all automated models for 7/10 tasks, among all expert models for 7/10 tasks, and performs favorably when considering both accuracy and efficiency as shown in Fig. 5. In addition, Table 3 shows that DASH outperforms DARTS in speed for all 10 tasks (in several cases by an order of magnitude), and attains comparable efficiency with training vanilla WRNs for 6/10 tasks (full-pipeline time is less than or about twice as long as the WRN training time). In the following, we provide a detailed analysis of the experimental results.
+
+DASH dominates automated methods. Compared to other automated methods, DASH has a clear advantage in accuracy. Even for tasks where it does not beat the expert, e.g. ECG, DASH's performance is significantly better than other AutoML methods. It also outperforms specialist methods Auto-DL and AMBER on dense prediction and 1D tasks, respectively. Although DARTS does best on CIFAR-100 (the task for which it was designed), Spherical, and PSICOV, it is the worst on NinaPro and FSD50K. Note that the underperformance of DASH on CIFAR-100 relative to WRN (and on Spherical and Cosmic relative to BABY DASH) suggests suboptimality of the gradient descent optimization procedure but not of the operation space, since WRN and BABY DASH are contained in our search space. This indicates a future direction to improve optimization in the DASH search space.
+
+
+Figure 4: Performance profiles of general NAS methods and DASH on NAS-Bench-360. DASH being far in the top left corner indicates it is rarely suboptimal and is often the best.
+
+
+Figure 5: Comparing $-\log \tau$ -suboptimality of speed vs. accuracy on all tasks. DASH's concentration in the top right corner indicates its strong efficacy-efficiency trade-offs relative to the other methods.
+
+DASH dominates expert architectures. While the degree of sophistication of the expert networks varies task by task, the performance of DASH on tasks such as Darcy Flow suggests that it is capable of competing with highly specialized networks, e.g., Fourier Neural Operator [37] for PDE solving. These results imply that DASH, and more generally the strategy of equipping backbone networks with task-specific kernels, is a promising approach for tackling model development in new domains. Meanwhile, DASH consistently outperforms Perceiver IO which represents non-automated general-purpose models. We speculate that the poor performance of Perceiver IO is because it is developed on more sophisticated natural language and multi-modal reasoning tasks and training Transformers is generally difficult.
+
+Large kernels are needed. We also ablate the large- $k$ -large- $d$ design of the search space by comparing DASH with BABY DASH. We hypothesize that for the same task, a small performance gap between the two methods would indicate that small kernels suffice for extracting local features, whereas a major degradation in the quality of the BABY DASH model can imply that the task needs global modeling. Consequently, datasets such as Darcy Flow and ECG provide compelling evidence that kernels with large receptive fields play an important role in solving real-life problems and further back up the design of our multi-scale convolutional search space. An example of the series of WRN kernels found by DASH on Darcy Flow is: $\mathbf{Conv}_{5,3}\to \mathbf{Conv}_{3,1}\to \mathbf{Conv}_{3,1}\to$ Conv3,15 $\rightarrow$ Conv7,15 $\rightarrow$ Conv9,7 $\rightarrow$ Conv9,7 $\rightarrow$ Conv3,7 $\rightarrow$ Conv5,7 $\rightarrow$ Conv5,15 $\rightarrow$ Conv9,7 $\rightarrow$ Conv3,7 $\rightarrow$ Conv7,7. We can see that large kernels are indeed selected during search. More visualizations can be found in Appendix A.8
+
+Table 3: Full-pipeline runtime in GPU hours for NAS-Bench-360 (PSICOV results are omitted due to a discrepancy in the implementation of data loading). DASH is consistently faster than DARTS, and it is less than a factor of two slower than simply training a WRN on six of the ten tasks. DenseNAS is fast but its accuracy is far less impressive. XD is too expensive to be applied to tasks other than CIFAR-100 [7].
+
+| Task | DARTS | DenseNAS | WRN | DASH |
| CIFAR-100 | 9.5 | 2.5 | 2 | 2.5 |
| Spherical | 16.5 | 2.5 | 2 | 5 |
| Darcy Flow | 6.5 | 0.5 | 0.5 | 5.3 |
| Cosmic | 21.5 | 2.5 | 4 | 6.8 |
| NinaPro | 0.5 | 0.2 | 0.2 | 0.3 |
| FSD50K | 37 | 4.5 | 4 | 29 |
| ECG | 140 | 6.5 | 5 | 1.3 |
| Satellite | 28 | 3 | 4.5 | 6.5 |
| DeepSEA | 39.5 | 2 | 1.5 | 10 |
+
+DASH is computationally efficient. In addition to prediction quality, we also care about the efficiency of model selection. Table 3 provides the combined search and retraining time in GPU hours for DARTS, DenseNAS, and DASH, as well as the training time for vanilla WRN 16-4 without hyperparameter tuning (baseline results are taken from Tu et al. 4). We also present the breakdown of DASH's full-pipeline runtime in Appendix A.7. A key observation is that the cost of DASH is consistently below DARTS' on all tasks and is similar to training a simple CNN for more than half of them. Although DenseNAS stands out by speed, its practical performance is less impressive.
+
+In Fig. 5, we visualize the trade-off between efficiency and effectiveness for each method and task combination. Evidently, DASH takes an important step towards bridging the gap between the efficiency of DARTS and the expressivity of XD in NAS. The fact that DASH can be trained at a
+
+low cost testifies that we need not sacrifice efficiency for adding more operations. In fact, we have actually shown that DASH is both faster and more effective than DARTS in many tasks.
+
+DASH works with other backbones and is backward compatible. Lastly, in addition to the Wide ResNet backbone and NAS-Bench-360 tasks, we have also verified the efficacy of DASH on other backbones including TCN [13] and ConvNeXt [15], and on large-scale datasets including ImageNet in Appendix A.9. In particular, DASH is able to achieve a $1.4\%$ increase in top-1 accuracy for ImageNet on top of the ConvNeXt backbone. As the latter was itself developed in part via manual tuning of the kernel size, this means that DASH outperforms human hand-tuning on ImageNet. These results show that DASH is backbone-agnostic and also works well with computer vision tasks, making it backward compatible with the original use cases of CNNs.
+
+# 4.3 Limitations and Future Work
+
+There are several open problems which we leave for future work. First, it is beneficial to study why certain kernel patterns are chosen, as the selected operations can hint us at the intrinsic properties of the datasets. Second, one can improve upon DASH, e.g., by including non-square convolutions for 2D problems, using a better optimization algorithm, or developing techniques that further reduces the memory usage of performing a forward architecture search pass. One could also construct a more comprehensive search space with high-level operators such as self-attention [41].
+
+Meanwhile, although this paper focuses on NAS, which is an alternative to fine-tuning pretrained models, the aggregated convolution can be a plug-and-play module for algorithms that search for large-scale models. For instance, many Transformer models still depend on convolutions for feature extraction and transformation, and their performance relies on the quality of the embedded features. Since DASH is applicable to any architecture with a convolutional layer, it can be helpful for such models, including Vision Transformer with a convolutional patching layer [42], Deformable Transformer with a ResNet embedder [43], Swin Transformer with a convolutional decoder [44], and many others.
+
+Societal Impact This paper calls for ML community's attention to less-studied application domains and moves towards truly democratizing machine learning in real life. In terms of broader societal impact, our work can exert a positive influence as it contributes to NAS efficiency and reduces the computational burden on AutoML end-users. However, lowering the barrier for applying ML to a wide range of tasks necessarily comes with the risk of misuse. Hence, it is imperative to develop NAS methods with privacy, safety, and fairness guarantees.
+
+# 5 Conclusion
+
+In this paper, we argue that a crucial goal of NAS is to discover accessible models for diverse tasks. To this end, we propose DASH, which efficiently searches for convolution patterns and integrates them into existing backbones. DASH overcomes the computational limitations of differentiable NAS and obtains high-quality models with accuracy comparable to or better than that of the handcrafted networks on many tasks. Our experiments show that convolution can be a universal operator for many under-explored areas. DASH is also a promising step towards developing general-purpose models with more complicated structures.
+
+# Acknowledgments
+
+We thank Maria-Florina Balcan, Nicholas Roberts, and Renbo Tu for providing useful feedback. This work was supported in part by DARPA FA875017C0141, the National Science Foundation grants IIS1705121, IIS1838017, IIS2046613 and IIS-2112471, an Amazon Web Services Award, a Facebook Faculty Research Award, funding from Booz Allen Hamilton Inc., a Block Center Grant, and a Facebook Fellowship Award. Any opinions, findings and conclusions or recommendations expressed in this material are those of the author(s) and do not necessarily reflect the views of any of these funding agencies.
+
+# References
+
+[1] Hieu Pham, Melody Y. Guan, Barret Zoph, Quoc V. Le, and Jeff Dean. Efficient neural architecture search via parameter sharing. In Proceedings of the 35th International Conference on Machine Learning, 2018.
+[2] Hanxiao Liu, Karen Simonyan, and Yiming Yang. DARTS: Differentiable architecture search. In Proceedings of the 7th International Conference on Learning Representations, 2019.
+[3] Liam Li, Mikhail Khodak, Maria-Florina Balcan, and Ameet Talwalkar. Geometry-aware gradient algorithms for neural architecture search. In Proceedings of the 9th International Conference on Learning Representations, 2021.
+[4] Renbo Tu, Nicholas Roberts, Mikhail Khodak, Junhong Shen, Frederic Sala, and Ameet Talwalkar. NAS-bench-360: Benchmarking neural architecture search on diverse tasks. In Advances in Neural Information Processing Systems (NeurIPS) Datasets and Benchmarks Track, 2022.
+[5] Jiemin Fang, Yuzhu Sun, Qian Zhang, Yuan Li, Wenyu Liu, and Xinggang Wang. Densely connected search space for more flexible neural architecture search. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2020.
+[6] Esteban Real, Chen Liang, David R. So, and Quoc V. Le. AutoML-Zero: Evolving machine learning algorithms from scratch. In Proceedings of the 37th International Conference on Machine Learning, 2020.
+[7] Nicholas Roberts, Mikhail Khodak, Tri Dao, Liam Li, Chris Ré, and Ameet Talwalkar. Rethinking neural operations for diverse tasks. In Advances in Neural Information Processing Systems, 2021.
+[8] Aäron van den Oord, Sander Dieleman, Heiga Zen, Karen Simonyan, Oriol Vinyals, Alexander Graves, Nal Kalchbrenner, Andrew Senior, and Koray Kavukcuoglu. Wavenet: A generative model for raw audio. In *Arxiv*, 2016.
+[9] Zichao Yang, Zhiting Hu, Ruslan Salakhutdinov, and Taylor Berg-Kirkpatrick. Improved variational autoencoders for text modeling using dilated convolutions. In International Conference on Learning Representations, 2017.
+[10] Fisher Yu and Vladlen Koltun. Multi-scale context aggregation by dilated convolutions. CoRR, abs/1511.07122, 2016.
+[11] Liang-Chieh Chen, George Papandreou, Iasonas Kokkinos, Kevin P. Murphy, and Alan Loddon Yuille. Deeplab: Semantic image segmentation with deep convolutional nets, atrous convolution, and fully connected crfs. IEEE Transactions on Pattern Analysis and Machine Intelligence, 40: 834-848, 2018.
+[12] Chao Peng, Xiangyu Zhang, Gang Yu, Guiming Luo, and Jian Sun. Large kernel matters — improve semantic segmentation by global convolutional network. 2017 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 1743–1751, 2017.
+[13] Shaojie Bai, J. Zico Kolter, and Vladlen Koltun. An empirical evaluation of generic convolutional and recurrent networks for sequence modeling. arXiv, 2018.
+[14] Shaojie Bai, J. Zico Kolter, and Vladlen Koltun. Trellis networks for sequence modeling. In Proceedings of the 7th International Conference on Learning Representations, 2019.
+[15] Zhuang Liu, Hanzi Mao, Chaozheng Wu, Christoph Feichtenhofer, Trevor Darrell, and Saining Xie. A convnet for the 2020s. 2022 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 11966-11976, 2022.
+[16] Hanxiao Liu, Karen Simonyan, and Yiming Yang. DARTS: Differentiable architecture search. In International Conference on Learning Representations, 2019.
+[17] Barret Zoph, Vijay Vasudevan, Jonathon Shlens, and Quoc V. Le. Learning transferable architectures for scalable image recognition. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2018.
+[18] Sirui Xie, Hehui Zheng, Chunxiao Liu, and Liang Lin. SNAS: Stochastic neural architecture search. In Proceedings of the 7th International Conference on Learning Representations, 2019.
+
+[19] Yuhui Xu, Lingxi Xie, Xiaopeng Zhang, Xin Chen, Guo-Jun Qi, Qi Tian, and Hongkai Xiong. PC-DARTS: Partial channel connections for memory-efficient architecture search. In Proceedings of the 8th International Conference on Learning Representations, 2020.
+[20] M. Suganuma, M. Ozay, and T. Okatani. Exploiting the potential of standard convolutional autoencoders for image restoration by evolutionary search. In International Conference on Machine Learning, 2018.
+[21] Abhinav Mehrotra, Alberto Gil C. P. Ramos, Sourav Bhattacharya, Lukasz Dudziak, Ravichander Vipperla, Thomas C. P. Chau, Mohamed Saleh Abdelfattah, Samin S. Ishtiaq, and Nicholas D. Lane. Nas-bench-asr: Reproducible neural architecture search for speech recognition. In International Conference on Learning Representations, 2021.
+[22] David R. So, Chen Liang, and Quoc V. Le. The evolved transformer. In International Conference on Machine Learning, 2019.
+[23] Tao Wei, Changhu Wang, Yong Rui, and Chang Wen Chen. Network morphism. In International Conference on Machine Learning, 2016.
+[24] Tianqi Chen, Ian J. Goodfellow, and Jonathon Shlens. Net2net: Accelerating learning via knowledge transfer. In International Conference on Learning Representations, 2016.
+[25] Liang-Chieh Chen, Maxwell D. Collins, Yukun Zhu, George Papandreou, Barret Zoph, Florian Schroff, Hartwig Adam, and Jonathon Shlens. Searching for efficient multi-scale architectures for dense image prediction. In Advances in Neural Information Processing Systems, 2018.
+[26] Zijun Zhang, Christopher Y. Park, Chandra L. Theesfeld, and Olga G. Troyanskaya. An automated framework for efficiently designing deep convolutional neural networks in genomics. Nature Machine Intelligence, 3(5):392-400, 2021.
+[27] Xiaoxing Wang, Chao Xue, Junchi Yan, Xiaokang Yang, Yonggang Hu, and Kewei Sun. Mergenas: Merge operations into one for differentiable architecture search. In IJCAI, 2020.
+[28] Xiaohan Ding, X. Zhang, Ningning Ma, Jungong Han, Guiguang Ding, and Jian Sun. Repvgg: Making vgg-style convnets great again. 2021 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 13728-13737, 2021.
+[29] Tri Dao, Nimit Sohoni, Albert Gu, Matthew Eichhorn, Amit Blonder, Megan Leszczynski, Atri Rudra, and Christopher Ré. Kaleidoscope: An efficient, learnable representation for all structured linear maps. In Proceedings of the 8th International Conference on Learning Representations, 2020.
+[30] Dimitrios Stamoulis, Ruizhou Ding, Di Wang, Dimitrios Lymberopoulos, Bodhi Priyantha, J. Liu, and Diana Marculescu. Single-path nas: Designing hardware-efficient convnets in less than 4 hours. In ECML/PKDD, 2019.
+[31] Andrew Jaegle, Sebastian Borgeaud, Jean-Baptiste Alayrac, Carl Doersch, Catalin Ionescu, David Ding, Skanda Koppula, Andrew Brock, Evan Shelhamer, Olivier Henaff, Matthew M. Botvinick, Andrew Zisserman, Oriol Vinyals, and João Carreira. Perceiver io: A general architecture for structured inputs & outputs, 2022.
+[32] Kevin Lu, Aditya Grover, P. Abbeel, and Igor Mordatch. Pretrained transformers as universal computation engines. ArXiv, abs/2103.05247, 2021.
+[33] David W. Romero, Robert-Jan Bruintjes, Jakub M. Tomczak, Erik J. Bekkers, Mark Hoogendoorn, and Jan C. van Gemert. Flexconv: Continuous kernel convolutions with differentiable kernel sizes. International Conference on Learning Representations, 2022.
+[34] Sergey Zagoruyko and Nikos Komodakis. Wide residual networks. In Proceedings of the British Machine Vision Conference, 2016.
+[35] Hassan Ismail Fawaz, Benjamin Lucas, Germain Forestier, Charlotte Pelletier, Daniel F. Schmidt, Jonathan Weber, Geoffrey I. Webb, Lhassane Idoumghar, Pierre-Alain Muller, and Francois Petitjean. Inceptiontime: Finding alexnet for time series classification. Data Mining and Knowledge Discovery, 34:1936-1962, 2020.
+[36] Tianyi Wu, Sheng Tang, Rui Zhang, Juan Cao, and Jintao Li. Tree-structured kronecker convolutional network for semantic segmentation. 2019 IEEE International Conference on Multimedia and Expo (ICME), pages 940–945, 2019.
+
+[37] Zongyi Li, Nikola Borislavov Kovachki, Kamyar Azizzadenesheli, Burigede Liu, Kaushik Bhattacharya, Andrew Stuart, and Anima Anandkumar. Fourier neural operator for parametric partial differential equations. In Proceedings of the 9th International Conference on Learning Representations, 2021.
+[38] Chenxi Liu, Liang-Chieh Chen, Florian Schroff, Hartwig Adam, Wei Hua, Alan L Yuille, and Li Fei-Fei. Auto-DeepLab: Hierarchical neural architecture search for semantic image segmentation. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2019.
+[39] Liam Li, Kevin Jamieson, Afshin Rostamizadeh, Ekaterina Gonina, Moritz Hardt, Benjamin Recht, and Ameet Talwalkar. A system for massively parallel hyperparameter tuning. In Proceedings of the Conference on Machine Learning and Systems, 2020.
+[40] Elizabeth D. Dolan and Jorge J Moré. Benchmarking optimization software with performance profiles. Mathematical Programming, 91:201-213, 2002.
+[41] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Advances in Neural Information Processing Systems, 2017.
+[42] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, Jakob Uszkoreit, and Neil Houlsby. An image is worth 16x16 words: Transformers for image recognition at scale. In International Conference on Learning Representations, 2021.
+[43] Xizhou Zhu, Weijie Su, Lewei Lu, Bin Li, Xiaogang Wang, and Jifeng Dai. Deformable detr: Deformable transformers for end-to-end object detection. ArXiv, abs/2010.04159, 2021.
+[44] Ze Liu, Yutong Lin, Yue Cao, Han Hu, Yixuan Wei, Zheng Zhang, Stephen Lin, and Baining Guo. Swin transformer: Hierarchical vision transformer using shifted windows. 2021 IEEE/CVF International Conference on Computer Vision (ICCV), pages 9992-10002, 2021.
+[45] Gao Huang, Zhuang Liu, and Kilian Q. Weinberger. Densely connected convolutional networks. 2017 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 2261-2269, 2017.
+[46] Taco Cohen, Mario Geiger, Jonas Köhler, and Max Welling. Spherical cnns. In International Conference on Machine Learning, 2018.
+[47] David Josephs, Carson Drake, Andrew M Heroy, and John Santerre. semg gesture recognition with a simple model of attention. Machine Learning for Health, pages 126-138, 2020.
+[48] Eduardo Fonseca, Xavier Favory, Jordi Pons, Frederic Font, and Xavier Serra. Fsd50k: an open dataset of human-labeled sound events. ArXiv, abs/2010.00475, 2021.
+[49] Badri Adhikari. DEEPCON: protein contact prediction using dilated convolutional neural networks with dropout. Bioinformatics, 36(2):470-477, 07 2019.
+[50] Keming Zhang and Joshua S. Bloom. deeper: Cosmic ray rejection with deep learning. The Astrophysical Journal, 889(1):24, 2020.
+[51] Shenda Hong, Yanbo Xu, Alind Khare, Satria Priambada, Kevin O. Maher, Alaa Aljiffry, Jimeng Sun, and Alexey Tumanov. Holmes: Health online model ensemble serving for deep learning models in intensive care units. Proceedings of the 26th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining, 2020.
+[52] Angus Dempster, Francois Petitjean, and Geoffrey I. Webb. Rocket: exceptionally fast and accurate time series classification using random convolutional kernels. Data Mining and Knowledge Discovery, 34:1454-1495, 2020.
+[53] Jian Zhou and Olga G. Troyanskaya. Predicting effects of noncoding variants with deep learning-based sequence model. Nature Methods, 12:931-934, 2015.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] Our work aims to democratize machine learning in diverse real-life applications. However, reducing the barrier for deploying accurate ML models on a diverse range of tasks may introduce unintended consequences associated with safety/fairness/privacy issues. We have addressed this point in Section 4.3.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes] Complexity analysis for Table I is provided in Appendix A.2.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] Due to limited space, we present the error bars in Appendix A.6.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [Yes] See Table 4.
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A] The data we used are open-sourced and our usage comply with their terms.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A] The data we used do not include any personally identifiable information.
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientarchitecturesearchfordiversetasks/images.zip b/efficientarchitecturesearchfordiversetasks/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..7efb343914da38c4d43777363e334801f44b0af1
--- /dev/null
+++ b/efficientarchitecturesearchfordiversetasks/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bbeb6801d2a877e0315c26ae2b95123bdd8e7b265cf7c40bcfbc1a8dd8a00b2a
+size 250958
diff --git a/efficientarchitecturesearchfordiversetasks/layout.json b/efficientarchitecturesearchfordiversetasks/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..16cb8048bd106d2f7e650b7f643765b06fe069f4
--- /dev/null
+++ b/efficientarchitecturesearchfordiversetasks/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:05f46474bc32267e8404d9fdcbbcf7802fb5ad2cfceb728286db766c6c8f405e
+size 473929
diff --git a/efficientdatasetdistillationusingrandomfeatureapproximation/8d11f2ef-543a-4879-9764-350fb31ca674_content_list.json b/efficientdatasetdistillationusingrandomfeatureapproximation/8d11f2ef-543a-4879-9764-350fb31ca674_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..891cf0cf8199985062febfd84b6fa11a651fc47f
--- /dev/null
+++ b/efficientdatasetdistillationusingrandomfeatureapproximation/8d11f2ef-543a-4879-9764-350fb31ca674_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2c10f8b4c0cb9599dd1fd8f1c00db00e6a9fcf6da0358dece073b774406a4962
+size 96000
diff --git a/efficientdatasetdistillationusingrandomfeatureapproximation/8d11f2ef-543a-4879-9764-350fb31ca674_model.json b/efficientdatasetdistillationusingrandomfeatureapproximation/8d11f2ef-543a-4879-9764-350fb31ca674_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..c85dee437da0ba53648d45a782f23d4b80d40049
--- /dev/null
+++ b/efficientdatasetdistillationusingrandomfeatureapproximation/8d11f2ef-543a-4879-9764-350fb31ca674_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:be51769ac1367cee304242bbe519dfc50f55fce5446ed4b27273334f0a8e6c52
+size 122610
diff --git a/efficientdatasetdistillationusingrandomfeatureapproximation/8d11f2ef-543a-4879-9764-350fb31ca674_origin.pdf b/efficientdatasetdistillationusingrandomfeatureapproximation/8d11f2ef-543a-4879-9764-350fb31ca674_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..29de6b31c535e303c01ed839ec1acfa01a596843
--- /dev/null
+++ b/efficientdatasetdistillationusingrandomfeatureapproximation/8d11f2ef-543a-4879-9764-350fb31ca674_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7bb079b96198b2d128e5a754b901f7779a8c13499392b3a49b9c355c55b70fbf
+size 3284213
diff --git a/efficientdatasetdistillationusingrandomfeatureapproximation/full.md b/efficientdatasetdistillationusingrandomfeatureapproximation/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..12b24b218112287a67c9e6b7753060d17ad158e3
--- /dev/null
+++ b/efficientdatasetdistillationusingrandomfeatureapproximation/full.md
@@ -0,0 +1,395 @@
+# Efficient Dataset Distillation using Random Feature Approximation
+
+Noel Loo, Ramin Hasani, Alexander Amini, Daniela Rus
+Computer Science and Artificial Intelligence Lab (CSAIL)
+Massachusetts Institute of Technology (MIT)
+{loo, rhasani, amini, rus} @mit.edu
+
+# Abstract
+
+Dataset distillation compresses large datasets into smaller synthetic coresets which retain performance with the aim of reducing the storage and computational burden of processing the entire dataset. Today's best-performing algorithm, Kernel Inducing Points (KIP), which makes use of the correspondence between infinite-width neural networks and kernel-ridge regression, is prohibitively slow due to the exact computation of the neural tangent kernel matrix, scaling $O(|S|^2)$ , with $|S|$ being the coreset size. To improve this, we propose a novel algorithm that uses a random feature approximation (RFA) of the Neural Network Gaussian Process (NNGP) kernel, which reduces the kernel matrix computation to $O(|S|)$ . Our algorithm provides at least a 100-fold speedup over KIP and can run on a single GPU. Our new method, termed an RFA Distillation (RFAD), performs competitively with KIP and other dataset condensation algorithms in accuracy over a range of large-scale datasets, both in kernel regression and finite-width network training. We demonstrate the effectiveness of our approach on tasks involving model interpretability and privacy preservation.1
+
+# 1 Introduction
+
+Coreset algorithms aim to summarize large datasets into significantly smaller datasets that still accurately represent the full dataset on downstream tasks [Jubran et al., 2019]. There are myriad applications of these smaller datasets including speeding up model training [Mirza-soleiman et al., 2020], reducing catastrophic forgetting [Aljundi et al., 2019, Rebuffi et al., 2017, Borsos et al., 2020], and enhancing interpretability [Kim et al., 2016, Bien and Tibshirani, 2011]. While most coreset selection techniques aim to select representative data points from the dataset, recent work has looked at generating synthetic data points instead, a process known as dataset distillation [Wang et al., 2018, Bohdal et al.,
+
+2020, Sucholutsky and Schonlau, 2019, Zhao et al., 2021, Zhao and Bilen, 2021b, Nguyen et al., 2021b]. These synthetic datasets have the benefit of using continuous gradient-based optimization techniques rather than combinatorial methods and are not limited to the set of images and labels given by the dataset, providing added flexibility and performance.
+
+
+Figure 1: RFAD provides over 100-fold speedup over the state-of-the-art algorithm Kernel-Inducing Points (KIP) [Nguyen et al., 2021a], while exceeding its performance on CIFAR-10. (right) Example distilled synthetic sets one image per class
+
+
+
+
+
+A large variety of applications benefit from obtaining an efficient dataset distillation algorithm. For instance, Kernel methods [Vinyals et al., 2016, Kaya and Bilge, 2019, Snell et al., 2017, Ghorbani et al., 2020, Refinetti et al., 2021] usually demand a large support set in order to generate good prediction performance at inference. This can be facilitated by an efficient dataset distillation pipeline. Moreover, distilling a synthetic version of sensitive data helps preserve privacy; a support set can be provided to an end-user for the downstream applications without disclosure of data. Lastly, for resource-hungry applications such as continual learning [Borsos et al., 2020], neural architecture search [Shleifer and Prokop, 2019] and automated machine learning [Hutter et al., 2019], generation of a support-set on which we can fit models efficiently is very helpful.
+
+Recently, a dataset distillation method called Kernel-Inducing Points (KIP) [Nguyen et al., 2021a,b] showed great performance in neural network classification tasks. KIP uses Neural Tangent Kernel (NTK) ridge-regression to exactly compute the output states of an infinite-width neural network trained on the support set. Although the method established the state-of-the-art for dataset distillation in terms of accuracy, the computational complexity of KIP is very high due to the exact calculation of the NTK. The algorithm, therefore, has limited applicability.
+
+In this paper, we build on the prior work on KIP and develop a new algorithm for dataset distillation called RFAD, which has similar accuracy and significantly better performance than KIP. The key insight is to introduce a new kernel inducing point method that improves complexity from $O(|S|^2)$ (where $|S|$ is the support-set size) to $O(|S|)$ . To this end, we make three major contributions:
+
+I. We develop RFAD, a fast, accurate, and scalable algorithm for dataset distillation in neural network classification tasks.
+
+II. We improve the time performance of KIP [Nguyen et al., 2021a,b] by over two orders of magnitude while retaining or improving its accuracy. This speedup comes from leveraging a random-feature approximation of the Neural Network Gaussian Process (NNGP) kernel by instantiating random neural networks.
+
+III. We show the effectiveness of RFAD in efficient dataset distillation tasks, enhancing model interpretability and privacy preservation.
+
+# 2 Background and Related Work
+
+Coresets and Dataset Distillation. Coresets are a subset of data that ensure models trained on them show competitive performance compared to models trained directly on data. Standard coreset selection algorithms use importance sampling to find coresets [Har-Peled and Mazumdar, 2004, Lucic et al., 2017, Cohen et al., 2017]. Besides random selection methods, inspired by catastrophic forgetting [Toneva et al., 2019] and mean-matching (adding samples to the coreset to match the mean of the original dataset) [Chen et al., 2010, Rebuffi et al., 2017, Castro et al., 2018, Belouadah and Popescu, 2020, Scholkopf et al., 1999], new algorithms have been introduced. An overview of how coresets work on point approximation is provided in Phillips [2016]
+
+More recently, aligned with coreset selection methods, new algorithms have been developed to distill a synthetic dataset from a given dataset, such that fitting to this synthetic set provides performance on par with training on the original dataset [Wang et al., 2018]. To this end, these dataset condensation (or distillation) algorithms use gradient matching [Zhao et al., 2021, Maclaurin et al., 2015, Lorraine et al., 2020], utilize differentiable siamese augmentation [Zhao and Bilen, 2021b], and matching distributions [Zhao and Bilen, 2021a]. Dataset distillation has also been applied to the labels rather than images [Bohdal et al., 2020]. Recently, a novel algorithm called Kernel Inducing Points (KIP) [Nguyen et al., 2021a,b] has been introduced that performs very well on distilling synthetic sets by using neural tangent kernel ridge-regression (KRR). KIP, similar to other algorithms, is computationally expensive. Here, we propose a new method to significantly improve its complexity.
+
+Infinite Width Neural Networks. Single-layer infinite-width randomly initialized neural networks correspond to Gaussian Processes [Neal, 1996], allowing for closed-form exact training of Bayesian neural networks for regression. Recently, this has been extended to deep fully-connected networks [Lee et al., 2018, de G. Matthews et al., 2018], convolutional networks [Novak et al., 2019, Garriga-Alonso et al., 2019], attention-based networks [Hron et al., 2020], and even to arbitrary neural architectures [Yang, 2019], with the corresponding GP kernel being the NNGP Kernel. Likewise, for infinite-width neural networks trained with gradient descent, the training process simplifies dramati
+
+cally, corresponding to kernel ridge regression when trained with MSE loss with the corresponding kernel being the Neural Tangent Kernel (NTK) [Jacot et al., 2018, Arora et al., 2019, Loo et al., 2022]. These two kernels are closely related, as the NNGP kernel forms the leading term of the NTK kernel, representing the effect of the final layer weights. Calculation of kernel entries typically scales with $O(HWD)$ for conv nets, with $H, W$ being the image height and width, $D$ the network depth, and $O(H^2W^2D)$ for architectures with global average pooling [Arora et al., 2019]. This, combined with the necessity of computing and inverting the $N \times N$ kernel matrix for kernel ridge regression, typically make these methods intractable for large datasets [Snelson and Ghahramani, 2006, Titsias, 2009].
+
+Random Feature methods. Every kernel corresponds to a dot product for some feature map: $k(x, x') = \phi(x)^T \phi(x')$ . Random feature methods aim to approximate the feature vector with a finite-dimensional random feature vector, the most notable example being Random Fourier Features [Rahimi and Recht, 2007]. Typically, this limits the rank of the kernel matrix, enabling faster matrix inversion and allowing for scaling kernel methods to large datasets. Recently, these random feature methods have been used to speed up NTKs and NNGPs [Zandieh et al., 2021, Novak et al., 2022, 2019] at inference or for neural architecture search [Peng et al., 2020]. In this work, we focus on the NNGP approximation described in Novak et al. [2019], as it only requires network forward passes and is model agnostic, allowing for flexible usage across different architectures without more complex machinery needed to calculate the approximation, unlike those found in Zandieh et al. [2021], Novak et al. [2022].
+
+# 3 Algorithm Setup and Design
+
+In this section, we first provide a high-level background on the KIP algorithm. We then sequentially outline our modifications leading to the RFAD algorithm.
+
+# 3.1 KIP Revisit
+
+The Kernel-Inducing Point algorithm [Nguyen et al., 2021a,b], or KIP, is a dataset distillation technique that uses the NTK kernel ridge-regression correspondence to compute exactly the outputs of an infinite-width neural network trained on the support set, bypassing the need to ever compute gradients or back-propagate on any finite network. Let $X_{T}, y_{T}$ correspond to the images and one-hot vector labels on the training dataset and let $X_{S}, y_{S}$ be the corresponding images and labels for the support set, which we aim to optimize. We have the outputs of a trained neural network as $f(X_{T}) = K_{TS}(K_{SS} + \lambda I)^{-1}y_{S}$ , with $K$ being the kernel matrices calculated using the NTK kernel, with $T \times S$ or $S \times S$ entries, for $K_{TS}$ and $K_{SS}$ , respectively. $\lambda$ is a small regularization parameter. KIP then optimizes $L_{MSE} = ||y_{T} - f(X_{T})||_{2}^{2}$ directly. The key bottleneck is the computation of these kernel matrices, requiring $O(TS \cdot HWD)$ time and memory, necessitating the use of hundreds of GPUs working in parallel. Additionally, the use of the MSE loss is suboptimal.
+
+# 3.2 Replacing the NTK Kernel with an NNGP Kernel
+
+We first replace the NTK used in the kernel regression of KIP with an NNGP kernel. While this change alone would yield a speed up, as the NNGP kernel is less computationally intensive to compute [Novak et al., 2020], we primarily do this because the NNGP kernel admits a simple random feature approximation, with advantages described later in this section. We first justify the appropriateness of this modification.
+
+Firstly, we denote that in the computation of NTK $(\Theta)$ and NNGP $(K)$ forms the leading term, as shown in Table 1 in Appendix D of [Novak et al., 2020] which outlines the NTK and NNGP kernel computation rules for various layers of a neural network. For fully connected (FC) layers, which is the typical final layer in neural network architectures, the remaining terms are suppressed by a matrix of expected derivatives with respect to activations, $\dot{K}$ , as observed by the recursion yielded from the computation of the NTK for an FC network [Novak et al., 2020]: $\Theta^l = K^l + \dot{K}^l \odot \Theta^{l-1}$ . For ReLU activations, the entries in this derivative matrix are upper bounded by 1, so the remaining terms must have a decaying contribution. We verify that our algorithms still provide good performance under the NTK and for finite networks trained with gradient descent, justifying this approximation.
+
+Algorithm 1 Dataset distillation with NNGP random features
+Require: Training set and labels $X_{T},y_{T}$ , Randomly initialized coreset and labels $X_{S},y_{S}$ , Random network count $N$ , Random network output dimension $M$ , Batch size $|B|$ , Random network initialization distribution, $p(\theta)$ , Regularization coefficient, $\lambda$ , Learning rate $\eta$ while loss not converged do Sample batch from the training set $X_{B},y_{B}\sim p(X_{T},y_{T})$ Sample $N$ random networks each with output dimension $M$ from $p(\theta)\colon \theta_1,\dots \theta_N\sim p(\theta)$ Compute random features for batch with random nets: $\hat{\Phi} (X_B)\leftarrow \frac{1}{\sqrt{NM}} [f_{\theta_1}(X_B),\dots,f_{\theta_N}(X_B)]^T\in \mathbb{R}^{|NM|\times |B|}$ Compute random features for support set with random nets: $\hat{\Phi} (X_S)\gets \frac{1}{\sqrt{NM}} [f_{\theta_1}(X_S),\dots,f_{\theta_N}(X_S)]^T\in \mathbb{R}^{|NM|\times |S|}$ Compute kernel matrices: $\hat{K}_{BS}\gets \hat{\Phi} (X_B)^T\hat{\Phi} (X_S)$ $\hat{K}_{SS}\gets \hat{\Phi} (X_S)^T\hat{\Phi} (X_S)$ Calculate trained network output on batch: $\hat{y}_B\gets \hat{K}_{BS}(\hat{K}_{SS} + \lambda I_{|S|})^{-1}y_S$ Calculate loss: $\mathcal{L} = \mathcal{L}(y_B,\hat{y}_B)$ Update coreset: $X_{S}\gets X_{S} - \eta \frac{\partial\mathcal{L}}{\partial X_{S}},y_{S}\gets y_{S} - \eta \frac{\partial\mathcal{L}}{\partial y_{S}}$ end while
+
+# 3.3 Replacing NNGP with an Empirical NNGP
+
+When we sample from a Gaussian process $f \sim \mathcal{GP}(0, K)$ , it suggests a natural finite feature map corresponding to scaled draws from the GP: $\hat{\phi}(x) = \frac{1}{\sqrt{N}} [f_1(x), \dots, f_N(x)]^T$ . For most GPs, this insight is not relevant, as sampling from a GP typically requires a Cholesky decomposition of the kernel matrix, requiring its computation in the first place [Rasmussen and Williams, 2006]. However, for NNGP we can generate approximate samples of $f$ by instantiating random neural networks, $f_i(x) = f_{\theta_i}(x), \theta_i \sim p(\theta)$ , for some initialization distribution $p(\theta)$ . Moreover, with a given neural network, we can define $f_i$ to be a vector of dimension $M$ by having a network with multiple output heads, meaning that with $N$ networks, we have $NM$ features. For our purposes, we typically have $N = 8$ , $M = 4096$ , giving 32768 total features. For the convolutional architectures we consider, this corresponds to $C = 256$ convolutional channels per layer. Even with this relatively large number of features, we still see a significant computation speedup over exact calculation.
+
+To sample $f \sim \mathcal{GP}(0, K)$ , we would have to instantiate random infinite width neural nets, whereas, in practice, we can only sample finite ones. This discrepancy incurs an $O(1/C)$ bias to our kernel matrix entries, with $C$ being the width-relevant parameter (i.e., convolutional channels) [Yaida, 2020]. However, we have a $O(1/(NC))$ variance of the mean of the random features [Daniely et al., 2016], meaning that in practice, the variance dominates the computation over bias. This has been noted empirically in Novak et al. [2019], and we verify that the finite-width bias does not significantly affect performance in appendix I, showing that we can achieve reasonable performance with as little as one convolution channel.
+
+The time cost of computing these random features is linear in the training set and coreset size, $|T|, |S|$ . With the relatively low cost of matrix multiplication, this results in the construction of the kernel matrices $K_{TS}$ and $K_{SS}$ having $O(|T| + |S|)$ and $O(|S|)$ , time complexity, respectively, as opposed to $O(|T||S|)$ and $O(|S|^2)$ with KIP. Noting that the cost of matrix inversion is relatively small compared to random feature construction, our total runtime is reduced to linear in the coreset size. We empirically verify this linear time complexity in section 4.1 and additionally provide a more detailed discussion in appendix C.
+
+# 3.4 Loss Function in dataset distillation
+
+We denoted earlier that $L_{MSE}$ is not well suited for dataset distillation settings. In particular, there are two key problems:
+
+Over-influence of already correctly classified data points. Consider two-way classification, with the label 1 corresponding to the positive class and $-1$ corresponding to the negative class. Let $x_{1}$ and $x_{2}$ be items in the training set whose labels are both 1. Let $f_{\mathrm{KRR}}(x) = K_{x,S}(K_{SS} + \lambda I)^{-1}y_S$ be the KRR output on $x$ given our support set $X_{S}$ . If $f_{\mathrm{KRR}}(x_1) = 5$ and $f_{\mathrm{KRR}}(x_2) = -1$ , then the
+
+Table 1: Kernel distillation results on five datasets with varying support set sizes. Bolded numbers indicate the best performance with fixed labels, and underlined numbers indicate the best performance with learned labels. Note that DC and DSA use fixed labels. (n = 4)
+
+ | Fixed Labels | Learned Labels |
| Img/Cls | DC | DSA | KIP | RFAD (ours) | KIP | RFAD (ours) |
| MNIST | 1 | 91.7 ± 0.5 | 88.7 ± 0.6 | 95.2 ± 0.2 | 96.7 ± 0.2 | 97.3 ± 0.1 | 97.2 ± 0.2 |
| 10 | 97.4 ± 0.2 | 97.8 ± 0.1 | 98.4 ± 0.0 | 99.0 ± 0.1 | 99.1 ± 0.1 | 99.1 ± 0.0 |
| 50 | 98.8 ± 0.1 | 99.2 ± 0.1 | 99.1 ± 0.0 | 99.1 ± 0.0 | 99.4 ± 0.1 | 99.1 ± 0.0 |
| Fashion-MNIST | 1 | 70.5 ± 0.6 | 70.6 ± 0.6 | 78.9 ± 0.2 | 81.6 ± 0.6 | 82.9 ± 0.2 | 84.6 ± 0.2 |
| 10 | 82.3 ± 0.4 | 84.6 ± 0.3 | 87.6 ± 0.1 | 90.0 ± 0.1 | 91.0 ± 0.1 | 90.3 ± 0.2 |
| 50 | 83.6 ± 0.4 | 88.7 ± 0.2 | 90.0 ± 0.1 | 91.3 ± 0.1 | 92.4 ± 0.1 | 91.4 ± 0.1 |
| SVHN | 1 | 31.2 ± 1.4 | 27.5 ± 1.4 | 48.1 ± 0.7 | 51.4 ± 1.3 | 64.3 ± 0.4 | 57.4 ± .8 |
| 10 | 76.1 ± 0.6 | 79.2 ± 0.5 | 75.8 ± 0.1 | 77.2 ± 0.3 | 81.1 ± 0.5 | 78.2 ± 0.5 |
| 50 | 82.3 ± 0.3 | 84.4 ± 0.4 | 81.3 ± 0.2 | 81.8 ± 0.2 | 84.3 ± 0.1 | 82.4 ± 0.1 |
| CIFAR-10 | 1 | 28.3 ± 0.5 | 28.8 ± 0.7 | 59.1 ± 0.4 | 61.1 ± 0.7 | 64.7 ± 0.2 | 61.4 ± 0.8 |
| 10 | 44.9 ± 0.5 | 52.1 ± 0.5 | 67.0 ± 0.4 | 73.1 ± 0.1 | 75.6 ± 0.2 | 73.7 ± 0.2 |
| 50 | 53.9 ± 0.5 | 60.6 ± 0.5 | 71.7 ± 0.2 | 76.1 ± 0.3 | 80.6 ± 0.1 | 76.6 ± 0.3 |
| CIFAR-100 | 1 | 12.8 ± 0.3 | 13.9 ± 0.3 | 31.8 ± 0.3 | 36.0 ± 0.4 | 34.9 ± 0.1 | 44.1 ± 0.1 |
| 10 | 25.2 ± 0.3 | 32.3 ± 0.3 | 46.0 ± 0.2 | 44.9 ± 0.2 | 49.5 ± 0.3 | 46.8 ± 0.2 |
+
+resulting MSE error on $x_{1}$ and $x_{2}$ would be 16 and 4, respectively. Notably, $x_{1}$ incurs a larger loss and results in a larger gradient on $X_{S}$ than $x_{2}$ , despite being correctly classified and $x_{2}$ being incorrectly classified. In the heavily constrained dataset distillation setting, fitting both data points simultaneously is not possible, leading to underfitting of the data in terms of classification in order to better fit already-correctly labeled data points in terms of regression.
+
+Unclear probabilistic interpretation of MSE for classification. This prevents regression from being used directly in calibration-sensitive environment, necessitating the use of transformation functions in tasks such as GP classification [Williams and Barber, 1998, Milios et al., 2018].
+
+Based on these two issues, we adopt: Platt scaling [Platt, 2000], by applying a cross entropy loss to the labels instead of an MSE one: $\mathcal{L}_{\mathrm{platt}} = \mathrm{x}$ entropy $(y_{T},f(X_{T}) / \tau)$ , where $\tau$ is a positive learned temperature scaling parameter. Unlike typical Platt scaling, we learn $\tau$ jointly with our support set instead of post-hoc tuning on a separate validation set. $f(X_{T})$ is still calculated using the same KRR formula. Accordingly, this corresponds to training a network using MSE loss, but at inference, scaling the outputs by $\tau^{-1}$ and applying a softmax to get a categorical distribution. Unlike typical GP classification, we ignore the variance of our predictions, taking only the mean instead.
+
+The combination of these three changes, namely, using the NNGP kernel instead of NTK, applying a random-feature approximation of NNGP, and Platt-scaling result in our RFAD algorithm, which is given in algorithm 1.
+
+# 4 Experiments with RFAD
+
+Here, we perform experiments to evaluate the performance of RFAD in dataset distillation tasks.
+
+Benchmarks. We applied our algorithm to five datasets: MNIST, FashionMNIST, SVHN, CIFAR-10 and CIFAR-100 [LeCun et al., 2010, Xiao et al., 2017, Netzer et al., 2011, Krizhevsky et al., 2009], distilling the datasets to coresets with 1, 10 or 50 images per class.
+
+Network Structure and Training Setup. Similar to previous work on dataset distillation, we used standard ConvNet architectures with three convolutional layers with average pooling and ReLU activations [Zhao et al., 2021, 2020, Nguyen et al., 2021b]. Similar to KIP [Nguyen et al., 2021b], we do not use instancenorm layers because of the lack of an infinite-width analog. During training, we used $N = 8$ random models, each with $C = 256$ convolutional channels per layer, and during test-time, we evaluated the datasets using the exact NNGP kernel using the neural-tangents library [Novak et al., 2020]. We consider both the fixed and learned label configurations, with Platt scaling applied and no data augmentation. We used the regularized Zero Component Analysis (ZCA) preprocessing
+
+Table 2: Performance of finite networks trained with gradient descent on DC/DSA, KIP, and RFAD distilled images. * denotes the result was obtained using learned labels. (n = 12)
+
+ | Img/Cls | DC/DSA | KIP to NN | RFAD to NN |
| MNIST | 1 | 91.7 ± 0.5 | 90.1 ± 0.1 | 94.4 ± 1.5* |
| 10 | 97.8 ± 0.1 | 97.5 ± 0.0 | 98.5 ± 0.1* |
| 50 | 99.2 ± 0.1 | 98.3 ± 0.1 | 98.8 ± 0.1 |
| Fashion-MNIST | 1 | 70.6 ± 0.6 | 73.5 ± 0.5* | 78.6 ± 1.3* |
| 10 | 84.6 ± 0.3 | 86.8 ± 0.1 | 87.0 ± 0.5 |
| 50 | 88.7 ± 0.2 | 88.0 ± 0.1* | 88.8 ± 0.4 |
| SVHN | 1 | 31.2 ± 1.4 | 57.3 ± 0.1* | 52.2 ± 2.2* |
| 10 | 79.2 ± 0.5 | 75.0 ± 0.1 | 74.9 ± 0.4 |
| 50 | 84.4 ± 0.4 | 80.5 ± 0.1 | 80.9 ± 0.3* |
| CIFAR-10 | 1 | 28.8 ± 0.7 | 49.9 ± 0.2 | 53.6 ± 1.2* |
| 10 | 52.1 ± 0.5 | 62.7 ± 0.3 | 66.3 ± 0.5* |
| 50 | 60.6 ± 0.5 | 68.6 ± 0.2 | 71.1 ± 0.4 |
| CIFAR-100 | 1 | 13.9 ± 0.3 | 15.7 ± 0.2 | 26.3 ± 1.1* |
| 10 | 32.3 ± 0.3 | 28.3 ± 0.1 | 33.0 ± 0.3* |
+
+for SVHN, CIFAR-10, and CIFAR-100, to improve KRR performance for color image datasets [Shankar et al., 2020, Nguyen et al., 2021b]. More details are available in appendix D.
+
+Baselines. We compare RFAD to recently developed advanced dataset distillation algorithms such as: KIP [Nguyen et al., 2021a,b], Dataset Condensation with gradient matching (DC) [Zhao et al., 2021], and differentiable Siamese augmentation (DSA) [Zhao and Bilen, 2021b].
+
+Table 1 summarizes the results. We observe that in the fixed label configuration, our method outperforms other models in almost every dataset. In particular, it outperforms KIP by up to $6.1\%$ in the CIFAR-10 10 img/cls setting. We attribute this gain primarily to the use of Platt scaling. RFAD falls slightly behind KIP with learned labels. While this could partially be explained because we did not apply data augmentation, which marginally elevated performance for KIP on some datasets [Nguyen et al., 2021b], we hypothesize that the performance difference is caused by the increased gradient variance associated with the random feature method. Nevertheless, in all experiments, RFAD is at least two orders of magnitude faster than KIP (Figure 2).
+
+# 4.1 Time Savings during training
+
+Next, we evaluated the time efficiency of RFAD. fig. 2 shows the time taken per training iteration on CIFAR-10 over coreset sizes and the number of models, $N$ used to evaluate the empirical NNGP kernel during training. Each training iteration contains 5120 examples from the training set. fig. 2 depicts that the time taken by RFAD is linear in both the number of models used during training and in the coreset size, validating the time complexity described above. We expect that for larger coreset sizes, the matrix inversion will begin to dominate due to its cubic complexity, but for small coreset sizes, the computation of the kernel matrix dominates the computation time.
+
+In the right-hand side plot in fig. 2 we show the same plot in log-scale, compared to KIP. For KIP, we used a batch size of 5000, and rather than measuring the time taken, we use the calculation provided in appendix B of [Nguyen et al., 2021b], which describes the running time of the algorithm. We observe evidently that even for the modest coreset sizes, the quadratic time complexity of computing the exact kernel matrix in KIP results in it being multiple orders of magnitude slower than our RFAD. Both KIP and RFAD converge in between 3000-15000 training iterations, resulting in times between 1-14hrs for RFAD and several hundred GPU hours for KIP, depending on the coreset size dataset, and when the early stopping condition is triggered.
+
+
+Figure 2: Time per training iteration for RFAD and KIP with varying number of models, $N$ . Left: Linear plot of time. Right: Logarithmic time for training iteration. RFAD achieves over two-orders-of-magnitude speedup compared KIP per training iteration while converging with a similar number of iterations.
+
+
+Figure 3: NNGP to NTK transfer performance on RFAD distilled images. The blue line indicates the performance of RFAD distilled images evaluated on NNGP. The orange line shows the same images evaluated using NTK. Despite being trained using the empirical NNGP kernel, these images still perform well on the NTK kernel, losing at most a few percentage points. $(n = 4)$
+
+
+
+
+
+
+
+
+
+
+Empirical NNGP inference accuracy for CIFAR-10, 10 img/cls, fixed labels
+
+
+Figure 4: Empirical NNGP kernel performance at test-time with a varying number of models used to compute the empirical NNGP kernel and number of convolutional channels per model. $(n = 5)$
+
+
+
+# 4.2 NTK Kernel and Finite Network Transfer
+
+One of the key elements of the RFAD algorithm is the replacement of NTK with the empirical NNGP kernel. While we argued earlier that the two should exhibit a similar performance given their similar formalism, in this section, we verify this claim experimentally. We evaluated our distilled coresets obtained from our RFAD algorithm in two different transfer scenarios. In the first setting, at test time, we used an NTK kernel instead of the NNGP kernel. In the second setting, we trained a finite-width network with gradient descent on the distilled datasets obtained via RFAD. Similar to [Nguyen et al., 2021b], we used a 1024-width finite network for our finite-transfer results since it better mimics the infinite width setting that corresponds to the NTK.
+
+Remarkably, as shown in fig. 3, in most datasets, these coresets suffer little to no performance drop when evaluated using NTK compared to the exact NNGP kernel, despite being trained using the empirical NNGP kernel. The largest performance gap is $8\%$ on SVHN with 10 images per class, and in some datasets, notably CIFAR-100, 10 img/cls evaluating using the NTK kernel outperforms NNGP. This suggests that either the exact NNGP kernel or the random feature NNGP kernel could potentially be used as a cheaper approximation for the exact NTK kernel.
+
+table 2 shows the resulting finite network transfer when training with gradient descent on our coresets. Our images appear to have the best performance in finite-network transfer, outperforming KIP in almost all benchmarks and the DC/DSA algorithms in many, despite DC/DCA being designed specifically for finite-width networks. We attribute this performance gain over KIP primarily to two tricks we used during training. Firstly, we applied centering, which, rather than training a typical network $f_{\theta}(x)$ , we instead train a network with its output at initialization subtracted: $f_{\theta}(x) - f_{\theta_0}(x)$ .
+
+This has been shown empirically to speed up the convergence of finite-width networks by reducing the bias caused by the finite-width initialization while still preserving the NTK [Lee et al., 2020, Hu et al., 2020]. We find that for these small datasets, this modification significantly improves performance. The second trick is label scaling; we scale the target labels by a factor $\alpha > 1$ : $\mathcal{L}_{\alpha} = ||f_{\theta}(x) - \alpha y||_2^2 / \alpha^2$ , and at inference divide the model's outputs by $\alpha$ . Note that this does not
+
+
+Figure 5: Objective function sensitivity. $(n = 4)$ to use Platt scaling and the number of models during training (N) for Fashion-MNIST and CIFAR-10
+
+affect the infinite-width setting, as in KRR, the output is linear w.r.t. the support set labels. Ablations of these changes are in appendix F.
+
+# 4.3 Empirical NNGP Performance at Inference
+
+To validate the efficacy of our method, we evaluated our distilled coresets using features from random networks as opposed to the exact kernel. We varied the width of individual networks between 128 and 1024 channels and the number of models between 1 and 32. fig. 4 shows the resulting classification accuracy on the CIFAR-10 dataset with 10 images/class. The black dot represents the configuration we used during training: 8 models, each with width 256 (More ablations are provided in appendix I). We conclude that the random feature method, for all network widths, is able to reach close to the exact NNGP kernel performance (dotted line) if a sufficient number of models are used. Interestingly, the performance is almost entirely dependent on the total number of features (proportional to $C \times N$ , with $C$ being the number of convolutional channels) and not the width of individual networks, suggesting that the finite-width bias associated with random finite networks is minimal.
+
+In appendix I, we show that this can be taken to the extreme, with $70\%$ accuracy achieved with a network with a single convolutional channel. These results corroborate the findings of [Novak et al., 2019], which first proposed this random feature method, where they found, like us, that performance was almost entirely determined by the total feature count.
+
+Platt scaling. We performed ablations on the use of the cross-entropy loss and the number of models used during training. We reran our algorithm on CIFAR-10 and Fashion-MNIST, using either 1, 2, 4, or 8 models during training, using MSE loss or cross-entropy loss. fig. 5 shows the resulting performance of these configurations. Evidently, using a cross-entropy loss results in substantial performance gains, even as much as $8\%$ as with Fashion-MNIST with one img/cls.
+
+# 5 RFAD Application I: Interpretability
+
+Large datasets contribute to the difficulty of understanding deep learning models. In this paper, we consider interpretability in the sense of the influence of individual training examples on network predictions [Hasani et al., 2019, Lechner et al., 2020, Wang et al., 2022]. One method of understanding this effect is the use of influence functions, which seek to answer the following counterfactual question: which item in the training set, if left out, would change the model's prediction the most [Hampel, 1974, Koh and Liang, 2017, Kabra et al., 2015]? For deep networks, this can only be answered approximately. This is because retraining a network on copies of the training set with individual items left out is computationally intractable. One solution is to use kernel ridge regression on a small support set. We can recompute the KRR on the kernel matrices with the $i$ th individual coreset element removed, with $K_{x,S\backslash i}K_{S\backslash i,S\backslash i}$ being the resulting kernel matrices with the $i$ th row/column corresponding to the $i$ th coreset entry removed.
+
+In particular, let $p(y_{\mathrm{test}} = c|S)$ be the probability prediction (computed by applying Platt scaling) of an example belonging to class $c$ computed on the entire coreset, $S$ . Let $p(y_{\mathrm{test}} = c|S \setminus i)$ be the same prediction calculated with the $i$ th coreset element removed. We define the influence score, $I_i$ of coreset element $i$ on $x_{\mathrm{test}}$ as $\sum_{c \leq C} |p(y_{\mathrm{test}} = c|S) - p(y_{\mathrm{test}} = c|S \setminus i)|$ . Taking the top values of $I_i$ yields the most relevant examples.
+
+Incorrect prediction
+
+Deer
+
+
+
+Dog
+
+
+Test Image
+
+
+
+
+
+
+
+
+
+
+
+
+Figure 6: The most relevant images for an incorrect (top row) and correct (bottom row) prediction on CIFAR-10. The most relevant coreset images are picked based on the coreset influence score $I$ , and for their training set, the training influence score $J$ . These metrics are fast to compute and result in semantically meaningful explanations for these two predictions.
+
+
+Most Relevant in Coreset
+
+
+
+
+
+
+Most Relevant in Training Set
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+While this method provides a simple way of gaining insights into how a prediction depends on the coreset, it does not provide insight into how this prediction comes from the original training set which produced the coreset. The method can be extended to accommodate this. Heuristically, we conjecture that two elements are similar if their predictions depend on the same elements in the coreset. We compute $p(y_{j} = c|S)$ and $p(y_{j} = c|S \setminus i)$ for every element $j$ in the training set and $i$ in the coreset. Then, we define its influence embedding as $z_{i,c}^{j} = p(y_{j} = c|S) - p(y_{j} = c|S \setminus i), z^{j} \in R^{|S| \times |C|}$ . This way, $z^{j}$ defines the sensitivity of a training datapoint prediction on the coreset. We compute the same embedding for a test datapoint $z^{\mathrm{test}}$ , and to compare data points we use cosine similarity, $J_{\mathrm{test},j} = \cos (z^{\mathrm{test}},z^{j})$ . Values of $z^{j}$ can be precomputed for the training set, typically in a few minutes for CIFAR-10, allowing for relatively fast queries, in contrast to the more expensive Hessian-inverse vector product required in Koh and Liang [2017], which is costly to compute and difficult to store.
+
+fig. 6 shows the results of this algorithm applied to CIFAR-10 with 50 img/cls for an incorrectly and correctly predicted image. In both cases, the resulting queries are visually similar to the test data point. One could use this information to not only explain a single incorrect prediction but to understand harmful items in their test set, or where more data needs to be collected.
+
+As a second application of RFAD, we create coresets that contain no human-understandable information from the source dataset yet still retain high test performance. [Nguyen et al., 2021a] proposed the concept of a $\rho$ -corrupted coreset: A fraction $\rho$ of the coresets elements are completely independent of the source dataset. Practically, for our algorithm, this means initializing the coreset with random noise and keeping a random $\rho$ fraction of the pixels kept at their initialization. We term this algorithm $\mathrm{RFAD}_{\rho}$ .
+
+Adding noise to gradient updates of the inputs of a network can be shown to give differentially private guarantees [Abadi et al., 2016]. While our scheme does not provide the same guarantees, we note the following two privacy-preserving properties of $\mathrm{RFAD}_{\rho}$ : firstly, the distillation process is irreversible: there are many datasets for which a distilled dataset provides zero loss. Secondly, if the true data distribution assigns a low probability to images of white noise, then for high values of $\rho$ , this guarantees that the distilled dataset stays far away in $L_{2}$ norm from real data points, since $\rho$ fraction of the pixels are stuck at their initialization. This means that a distilled $\mathrm{RFAD}_{\rho}$ dataset will not recreate any real points in the training set.
+
+
+Classification Accuracy
+92.0 ± 0.2%
+
+
+91.0 ± 0.8%
+
+
+89.1 ± 0.4%
+
+
+$86.9 \pm 1.4\%$
+
+
+Female
+$\rho = 0$
+Increasing Corruption Ratio, $\rho$
+Figure 7: CelebA distilled datasets for male/female classification with 1 image per class at varying corruption ratios. At $\rho = 0$ , the distilled images are very interpretable, but at $\rho = 0.95$ , the images look like white noise, despite achieving $86.9\%$ accuracy on the classification task.
+
+
+$\rho = 0.4$
+
+
+$\rho = 0.8$
+
+
+$\rho = 0.95$
+
+of a network can be shown to give differentially. Our scheme does not provide the same guarantees, properties of $\mathrm{RFAD}_{\rho}$ : firstly, the distillation process in a distilled dataset provides zero loss. Secondly, if noisy to images of white noise, then for high values of $L_{2}$ far away in $L_{2}$ norm from real data points, since $\rho$ is non-0. This means that a distilled $\mathrm{RFAD}_{\rho}$ dataset will
+
+# 6 RFAD Application II: Privacy
+
+We applied $\mathrm{RFAD}_{\rho}$ on CIFAR-10, and CelebA faces datasets. For CIFAR-10 we distilled the standard 10-class classification task, with corruption ratios taking values of [0, 0.2, 0.4, 0.8, 0.9], with 1, 10 or 50 images per class. For CelebA, we performed male/female binary classification with corruption ratios between 0 and 0.95 with 1, 10, or 50 samples per class. fig. 8 show the resulting performance.
+
+For CIFAR-10, even at corruption ratios of 0.9, we are able to achieve $40.6\%$ accuracy with one sample per class, far above the natural baseline of $16.1\%$ ([Nguyen et al., 2021b] table A1). For CelebA, we achieve $81\%$ accuracy with only two images, one male and one female, with $95\%$ of the pixels in the image being random noise.
+
+
+Figure 8: Performance of RFAD on CIFAR-10 and CelebA classification with varying support set sizes and corruption ratios. Performance degrades very gradually as noise is increased, still achieving high performance with $90\%$ corruption. $(n = 3)$
+
+We additionally visualize the distilled images for the male and female classes in the CelebA distillation task with one image per class in fig. 7 at varying corruption ratios. While the image initially contains visually interpretable features with $\rho = 0$ , they quickly devolve into pure noise at $\rho = 0.95$ .
+
+# 7 Conclusions
+
+We proposed RFAD, a dataset distillation algorithm that provides a 100-fold speedup over the current state-of-the-art KIP while retaining accuracy. The speedup is primarily due to the use of the approximate NNGP kernel as opposed to the exact NTK one, reducing the time complexity from $O(|S|^2)$ to $O(|S|)$ . The success of the approximation here, combined with the similarity between the NTK and NNGP kernels, suggests the random network NNGP approximation as an efficient method for algorithms where the exact computation of the NNGP or NTK kernel is infeasible. We analyzed our method comprehensively and showed its effectiveness, and proposed two applications in model interpretability and privacy preservation. With this new tool, we hope that future work could begin to use Neural Tangent Kernel as an algorithmic design tool in addition to its current theoretical use for neural network analysis. Lastly, RFAD has the following limitations:
+
+Use of instancenorm. In practice, we found that our datasets distilled without instancenorm do not transfer well to finite networks with it. Conversely, if we use random networks with instancenorm in RFAD, these transfer to finite networks with instancenorm but not to ones without or the NNGP kernel. This suggests that the features used by networks with/without instancenorm differ, making it difficult to distill datasets that perform well on both. We discuss this further in appendix G.
+
+Overfitting in dataset distillation. On Platt scaling, we argued that the heavily constrained nature of dataset distillation leads to underfitting of the training set when using an MSE-style loss in KIP, and we verified the efficacy of using a Platt loss instead. However, we observed that in simple datasets, such as MNIST, or with large coresets relative to the data, such as CIFAR-100 with 10 images per class, we could overfit to the dataset. We found that these distilled datasets were able to achieve near $100\%$ classification accuracy on the training set, meaning that it was distilled perfectly in terms of the Platt-loss. This implies that adding more images would not improve performance. Thus we hypothesize that using a Platt loss would be detrimental if the compression ratio is low.
+
+# Acknowledgements
+
+This research has been funded in part by the Office of Naval Research Grant Number Grant N00014-18-1-2830, DSTA Singapore, and the J. P. Morgan AI Research program. We are very grateful.
+
+# References
+
+M. Abadi, A. Chu, I. Goodfellow, H. B. McMahan, I. Mironov, K. Talwar, and L. Zhang. Deep learning with differential privacy. In Proceedings of the 2016 ACM SIGSAC Conference on Computer and Communications Security, CCS '16, page 308-318, New York, NY, USA, 2016. Association for Computing Machinery. ISBN 9781450341394. doi: 10.1145/2976749.2978318. URL https://doi.org/10.1145/2976749.2978318.
+R. Aljundi, M. Lin, B. Goujaud, and Y. Bengio. Gradient based sample selection for online continual learning. In NeurIPS, 2019.
+S. Arora, S. S. Du, W. Hu, Z. Li, R. Salakhutdinov, and R. Wang. On exact computation with an infinitely wide neural net. In NeurIPS, 2019.
+E. Belouadah and A. Popescu. Scail: Classifier weights scaling for class incremental learning. In The IEEE Winter Conference on Applications of Computer Vision, 2020.
+J. Bien and R. Tibshirani. Prototype selection for interpretable classification. The Annals of Applied Statistics, 5(4):2403-2424, 2011.
+O. Bohdal, Y. Yang, and T. Hospedales. Flexible dataset distillation: Learn labels instead of images. Neural Information Processing Systems Workshop, 2020.
+Z. Borsos, M. Mutny, and A. Krause. Coresets via bilevel optimization for continual learning and streaming. NeurIPS, 2020.
+F. M. Castro, M. J. Marín-Jiménez, N. Guil, C. Schmid, and K. Alahari. End-to-end incremental learning. In Proceedings of the European Conference on Computer Vision (ECCV), pages 233-248, 2018.
+Y. Chen, M. Welling, and A. Smola. Super-samples from kernel herding. The Twenty-Sixth Conference Annual Conference on Uncertainty in Artificial Intelligence, 2010.
+L. Chizat, E. Oyallon, and F. R. Bach. On lazy training in differentiable programming. In NeurIPS, 2019.
+M. B. Cohen, C. Musco, and C. Musco. Input sparsity time low-rank approximation via ridge leverage score sampling. In Proceedings of the Twenty-Eighth Annual ACM-SIAM Symposium on Discrete Algorithms, pages 1758-1777. SIAM, 2017.
+A. Daniely, R. Frostig, and Y. Singer. Toward deeper understanding of neural networks: The power of initialization and a dual view on expressivity. In D. Lee, M. Sugiyama, U. Luxburg, I. Guyon, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 29. Curran Associates, Inc., 2016. URL https://proceedings.neurips.cc/paper/2016/file/abea47ba24142ed16b7d8fbf2c740e0d-Paper.pdf.
+A. G. de G. Matthews, J. Hron, M. Rowland, R. E. Turner, and Z. Ghahramani. Gaussian process behaviour in wide deep neural networks. In International Conference on Learning Representations, 2018. URL https://openreview.net/forum?id=H1-nGgWC-.
+A. Garriga-Alonso, C. E. Rasmussen, and L. Aitchison. Deep convolutional networks as shallow gaussian processes. In International Conference on Learning Representations, 2019. URL https://openreview.net/forum?id=BklfsiOcKm.
+B. Ghorbani, S. Mei, T. Misiakiewicz, and A. Montanari. When do neural networks outperform kernel methods? arXiv preprint arXiv:2006.13409, 2020.
+F. R. Hampel. The influence curve and its role in robust estimation. Journal of the American Statistical Association, 69(346):383-393, 1974. ISSN 01621459. URL http://www.jstor.org/stable/2285666.
+S. Har-Peled and S. Mazumdar. On coresets for k-means and k-median clustering. In Proceedings of the thirty-sixth annual ACM symposium on Theory of computing, pages 291-300, 2004.
+
+R. Hasani, A. Amini, M. Lechner, F. Naser, R. Grosu, and D. Rus. Response characterization for auditing cell dynamics in long short-term memory networks. In 2019 International Joint Conference on Neural Networks (IJCNN), pages 1-8. IEEE, 2019.
+J. Hron, Y. Bahri, J. Sohl-Dickstein, and R. Novak. Infinite attention: Nngp and ntk for deep attention networks. In ICML, 2020.
+W. Hu, Z. Li, and D. Yu. Simple and effective regularization methods for training on noisily labeled data with generalization guarantee. In International Conference on Learning Representations, 2020. URL https://openreview.net/forum?id=Hke3gyHYwH.
+F. Hutter, L. Kotthoff, and J. Vanschoren. Automated machine learning: methods, systems, challenges. Springer Nature, 2019.
+A. Jacot, F. Gabriel, and C. Hongler. Neural tangent kernel: Convergence and generalization in neural networks. In Advances in Neural Information Processing Systems, 2018.
+I. Jubran, A. Maalouf, and D. Feldman. Introduction to coresets: Accurate coresets. CoRR, abs/1910.08707, 2019. URL http://arxiv.org/abs/1910.08707.
+M. Kabra, A. Robie, and K. Branson. Understanding classifier errors by examining influential neighbors. 2015 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 3917-3925, 2015.
+M. Kaya and H. Bilge. Deep metric learning: A survey. Symmetry, 11:1066, 08 2019. doi: 10.3390/sym11091066.
+B. Kim, R. Khanna, and O. Koyejo. Examples are not enough, learn to criticize! criticism for interpretability. In Proceedings of the 30th International Conference on Neural Information Processing Systems, NIPS'16, page 2288-2296, Red Hook, NY, USA, 2016. Curran Associates Inc. ISBN 9781510838819.
+P. W. Koh and P. Liang. Understanding black-box predictions via influence functions. In Proceedings of the 34th International Conference on Machine Learning - Volume 70, ICML'17, page 1885-1894. JMLR.org, 2017.
+A. Krizhevsky, G. Hinton, et al. Learning multiple layers of features from tiny images. Technical report, Citeseer, 2009.
+M. Lechner, R. Hasani, A. Amini, T. A. Henzinger, D. Rus, and R. Grosu. Neural circuit policies enabling auditable autonomy. Nature Machine Intelligence, 2(10):642-652, 2020.
+Y. LeCun, C. Cortes, and C. Burges. Mnist handwritten digit database. ATT Labs [Online]. Available: http://yann.lecun.com/exdb/mnist, 2, 2010.
+J. Lee, J. Sohl-dickstein, J. Pennington, R. Novak, S. Schoenholz, and Y. Bahri. Deep neural networks as gaussian processes. In International Conference on Learning Representations, 2018. URL https://openreview.net/forum?id=B1EA-M-0Z.
+J. Lee, S. Schoenholz, J. Pennington, B. Adlam, L. Xiao, R. Novak, and J. Sohl-Dickstein. Finite versus infinite neural networks: an empirical study. In H. Larochelle, M. Ranzato, R. Hadsell, M. F. Balcan, and H. Lin, editors, Advances in Neural Information Processing Systems, volume 33, pages 15156-15172. Curran Associates, Inc., 2020. URL https://proceedings.neurips.cc/paper/2020/file/ad086f59924fffe0773f8d0ca22ea712-Paper.pdf.
+N. Loo, R. Hasani, A. Amini, and D. Rus. Evolution of neural tangent kernels under benign and adversarial training. In Advances in Neural Information Processing Systems, 2022.
+J. Lorraine, P. Vicol, and D. Duvenaud. Optimizing millions of hyperparameters by implicit differentiation. In International Conference on Artificial Intelligence and Statistics, pages 1540-1552. PMLR, 2020.
+M. Lucic, M. Faulkner, A. Krause, and D. Feldman. Training gaussian mixture models at scale via coresets. The Journal of Machine Learning Research, 18(1):5885-5909, 2017.
+
+D. Maclaurin, D. Duvenaud, and R. Adams. Gradient-based hyperparameter optimization through reversible learning. In International Conference on Machine Learning, pages 2113-2122, 2015.
+D. Milios, R. Camoriano, P. Michiardi, L. Rosasco, and M. Filippone. Dirichlet-based gaussian processes for large-scale calibrated classification. In Proceedings of the 32nd International Conference on Neural Information Processing Systems, pages 6008-6018, 2018.
+B. Mirzasoleiman, J. A. Bilmes, and J. Leskovec. Coresetts for data-efficient training of machine learning models. In Proceedings of the 37th International Conference on Machine Learning, ICML 2020, 13-18 July 2020, Virtual Event, volume 119 of Proceedings of Machine Learning Research, pages 6950-6960. PMLR, 2020.
+R. M. Neal. Bayesian Learning for Neural Networks. Springer-Verlag, Berlin, Heidelberg, 1996. ISBN 0387947248.
+Y. Netzer, T. Wang, A. Coates, A. Bissacco, B. Wu, and A. Y. Ng. Reading digits in natural images with unsupervised feature learning. Google Research, 2011.
+T. Nguyen, Z. Chen, and J. Lee. Dataset meta-learning from kernel ridge-regression. In International Conference on Learning Representations, 2021a. URL https://openreview.net/forum?id=1-PrrQrKOQR.
+T. Nguyen, R. Novak, L. Xiao, and J. Lee. Dataset distillation with infinitely wide convolutional networks. In Thirty-Fifth Conference on Neural Information Processing Systems, 2021b. URL https://openreview.net/forum?id=hXWPpJedrVP.
+R. Novak, L. Xiao, Y. Bahri, J. Lee, G. Yang, D. A. Abolafia, J. Pennington, and J. Sohl-dickstein. Bayesian deep convolutional networks with many channels are gaussian processes. In International Conference on Learning Representations, 2019. URL https://openreview.net/forum?id=B1g30j0qF7.
+R. Novak, L. Xiao, J. Hron, J. Lee, A. A. Alemi, J. Sohl-Dickstein, and S. S. Schoenholz. Neural tangents: Fast and easy infinite neural networks in python. In International Conference on Learning Representations, 2020. URL https://openreview.net/forum?id=Sk1D9yrFPS.
+R. Novak, J. Sohl-Dickstein, and S. S. Schoenholz. Fast finite width neural tangent kernel. In K. Chaudhuri, S. Jegelka, L. Song, C. Szepesváři, G. Niu, and S. Sabato, editors, International Conference on Machine Learning, ICML 2022, 17-23 July 2022, Baltimore, Maryland, USA, volume 162 of Proceedings of Machine Learning Research, pages 17018-17044. PMLR, 2022. URL https://proceedings.mlr.press/v162/novak22a.html.
+D. Peng, D. S. Park, J. Lee, J. Sohl-dickstein, and Y. Cao. Towards nngp-guided neural architecture search. In ArXiv, 2020.
+J. M. Phillips. Coresets and sketches. arXiv preprint arXiv:1601.00617, 2016.
+J. Platt. Probabilistic outputs for support vector machines and comparisons to regularized likelihood methods. Adv. Large Margin Classif., 10, 06 2000.
+A. Rahimi and B. Recht. Random features for large-scale kernel machines. In Proceedings of the 20th International Conference on Neural Information Processing Systems, pages 1177-1184, 2007.
+C. E. Rasmussen and C. K. I. Williams. Gaussian processes for machine learning. Adaptive computation and machine learning. MIT Press, 2006. ISBN 026218253X.
+S.-A. Rebuffi, A. Kolesnikov, G. Sperl, and C. H. Lampert. icarl: Incremental classifier and representation learning. 2017 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 5533-5542, 2017.
+M. Refinetti, S. Goldt, F. Krzakala, and L. Zdeborova. Classifying high-dimensional gaussian mixtures: Where kernel methods fail and neural networks succeed. arXiv preprint arXiv:2102.11742, 2021.
+
+B. Scholkopf, S. Mika, C. Burges, P. Knirsch, K.-R. Muller, G. Ratsch, and A. Smola. Input space versus feature space in kernel-based methods. IEEE Transactions on Neural Networks, 10(5): 1000-1017, 1999. doi: 10.1109/72.788641.
+V. Shankar, A. Fang, W. Guo, S. Fridovich-Keil, J. Ragan-Kelley, L. Schmidt, and B. Recht. Neural kernels without tangents. In ICML, pages 8614-8623, 2020. URL http://proceedings.mlr.press/v119/shankar20a.htm1.
+S. Shleifer and E. Prokop. Using small proxy datasets to accelerate hyperparameter search. arXiv preprint arXiv:1906.04887, 2019.
+J. Snell, K. Swersky, and R. Zemel. Prototypical networks for few-shot learning. In Advances in neural information processing systems, pages 4077-4087, 2017.
+E. Snelson and Z. Ghahramani. Sparse gaussian processes using pseudo-inputs. In Advances in neural information processing systems, pages 1257-1264, 2006.
+I. Sucholutsky and M. Schonlau. Soft-label dataset distillation and text dataset distillation. arXiv preprint arXiv:1910.02551, 2019.
+M. Titsias. Variational learning of inducing variables in sparse gaussian processes. In Artificial Intelligence and Statistics, pages 567-574, 2009.
+M. Toneva, A. Sordoni, R. T. d. Combes, A. Trischler, Y. Bengio, and G. J. Gordon. An empirical study of example forgetting during deep neural network learning. *ICLR*, 2019.
+O. Vinyals, C. Blundell, T. Lillicrap, D. Wierstra, et al. Matching networks for one shot learning. In Advances in neural information processing systems, 2016.
+T. Wang, J.-Y. Zhu, A. Torralba, and A. A. Efros. Dataset distillation. arXiv preprint arXiv:1811.10959, 2018.
+T.-H. Wang, W. Xiao, T. Seyde, R. Hasani, and D. Rus. Interpreting neural policies with disentangled tree representations. arXiv preprint arXiv:2210.06650, 2022.
+C. K. I. Williams and D. Barber. Bayesian classification with gaussian processes. IEEE Trans. Pattern Anal. Mach. Intell., 20(12):1342-1351, dec 1998. ISSN 0162-8828. doi: 10.1109/34.735807.
+H. Xiao, K. Rasul, and R. Vollgraf. Fashion-mnist: a novel image dataset for benchmarking machine learning algorithms. arXiv preprint arXiv:1708.07747, 2017.
+S. Yaida. Non-Gaussian processes and neural networks at finite widths. In J. Lu and R. Ward, editors, Proceedings of The First Mathematical and Scientific Machine Learning Conference, volume 107 of Proceedings of Machine Learning Research, pages 165-192. PMLR, 20-24 Jul 2020. URL https://proceedings.mlr.press/v107/yaida20a.htm1.
+G. Yang. Tensor programs i: Wide feedforward or recurrent neural networks of any architecture are gaussian processes. In NeurIPS 2019, December 2019.
+A. Zandieh, I. Han, H. Avron, N. Shoham, C. Kim, and J. Shin. Scaling neural tangent kernels via sketching and random features. In A. Beygelzimer, Y. Dauphin, P. Liang, and J. W. Vaughan, editors, Advances in Neural Information Processing Systems, 2021. URL https://openreview.net/forum?id=vIRFiA658rh.
+B. Zhao and H. Bilen. Dataset condensation with distribution matching. arXiv preprint arXiv:2110.04181, 2021a.
+B. Zhao and H. Bilen. Dataset condensation with differentiable siamese augmentation. arXiv preprint arXiv:2102.08259, 2021b.
+B. Zhao, K. R. Mopuri, and H. Bilen. Dataset condensation with gradient matching. In International Conference on Learning Representations, 2021. URL https://openreview.net/forum?id=mSAKhLYLSsl.
+
+S. Zhao, Z. Liu, J. Lin, J.-Y. Zhu, and S. Han. Differentiable augmentation for data-efficient gan training. Neural Information Processing Systems, 2020.
+J. Zhuang, T. Tang, Y. Ding, S. Tatikonda, N. Dvornek, X. Papademetris, and J. S. Duncan. Adelbelief optimizer: Adapting step sizes by the belief in observed gradients. arXiv preprint arXiv:2010.07468, 2020.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientdatasetdistillationusingrandomfeatureapproximation/images.zip b/efficientdatasetdistillationusingrandomfeatureapproximation/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..9dab39136416d6458f66ffcb387e6fb95f95cbf5
--- /dev/null
+++ b/efficientdatasetdistillationusingrandomfeatureapproximation/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e7d1fd3bbe3e10e8fbf68a5b0b6c4ef89ee4972cca143760e59175c90ce16c46
+size 390878
diff --git a/efficientdatasetdistillationusingrandomfeatureapproximation/layout.json b/efficientdatasetdistillationusingrandomfeatureapproximation/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..da3c1fa541ea4251d2eba06e64d96b228e9ddf22
--- /dev/null
+++ b/efficientdatasetdistillationusingrandomfeatureapproximation/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c2e1efe4e26b981c0d7941c3855c4ab4b044bd763b5f7ab1e2fddc8bbe8419a6
+size 573749
diff --git a/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/05657a70-6aba-455c-a7cb-ee892d0aaff1_content_list.json b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/05657a70-6aba-455c-a7cb-ee892d0aaff1_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..4ce5e06ffaffb99682d4c343728d45e9a6f701a8
--- /dev/null
+++ b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/05657a70-6aba-455c-a7cb-ee892d0aaff1_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:acf82b7077bc589a8ed182a92edc45a4b70cb3b0affb0411db8c7a9f74dec57c
+size 88019
diff --git a/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/05657a70-6aba-455c-a7cb-ee892d0aaff1_model.json b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/05657a70-6aba-455c-a7cb-ee892d0aaff1_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..97b626fbf5d501b0c5e49248f8787fb88b217823
--- /dev/null
+++ b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/05657a70-6aba-455c-a7cb-ee892d0aaff1_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e57834cf1e408bc093e8d5921583dfacaf27291696e08c1acf8a193f7b0e8b09
+size 110715
diff --git a/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/05657a70-6aba-455c-a7cb-ee892d0aaff1_origin.pdf b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/05657a70-6aba-455c-a7cb-ee892d0aaff1_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..7a0c43478f466e574a6bf8c46215b828ee74dc8d
--- /dev/null
+++ b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/05657a70-6aba-455c-a7cb-ee892d0aaff1_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:eed040d536902dd808aa6162f4d86831c2515e390ae9eca0631171d204639396
+size 12373469
diff --git a/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/full.md b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..7d16c4ca82c9685a0cc89b2dcff141ad143b86a5
--- /dev/null
+++ b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/full.md
@@ -0,0 +1,405 @@
+# Efficient Frameworks for Generalized Low-Rank Matrix Bandit Problems
+
+Yue Kang
+
+Department of Statistics
+University of California, Davis
+Davis, CA 95616
+yuekang@ucdavis.edu
+
+Cho-Jui Hsieh
+
+Department of Computer Science
+University of California, Los Angeles
+Los Angeles, CA 90095
+chohsieh@cs.ucla.edu
+
+Thomas C. M. Lee
+
+Department of Statistics
+University of California, Davis
+Davis, CA 95616
+tcmlee@ucdavis.edu
+
+# Abstract
+
+In the stochastic contextual low-rank matrix bandit problem, the expected reward of an action is given by the inner product between the action's feature matrix and some fixed, but initially unknown $d_{1}$ by $d_{2}$ matrix $\Theta^{*}$ with rank $r \ll \{d_1,d_2\}$ , and an agent sequentially takes actions based on past experience to maximize the cumulative reward. In this paper, we study the generalized low-rank matrix bandit problem, which has been recently proposed in [26] under the Generalized Linear Model (GLM) framework. To overcome the computational infeasibility and theoretical restraint of existing algorithms on this problem, we first propose the G-ESTT framework that modifies the idea from [17] by using Stein's method on the subspace estimation and then leverage the estimated subspaces via a regularization idea. Furthermore, we remarkably improve the efficiency of G-ESTT by using a novel exclusion idea on the estimated subspace instead, and propose the G-ESTS framework. We also show that both of our methods are the first algorithm to achieve the optimal $\tilde{O} ((d_1 + d_2)r\sqrt{T})$ bound of regret presented in [26] up to logarithm terms under some mild conditions, which improves upon the current regret of $\tilde{O} ((d_1 + d_2)^{3 / 2}\sqrt{rT})$ [26]. For completeness, we conduct experiments to illustrate that our proposed algorithms, especially G-ESTS, are also computationally tractable and consistently outperform other state-of-the-art (generalized) linear matrix bandit methods based on a suite of simulations.
+
+# 1 Introduction
+
+The contextual bandit has proven to be a powerful framework for sequential decision-making problems, with great applications to clinical trials [36], recommendation system [22], and personalized medicine [4]. This class of problems evaluates how an agent should choose an action from the potential action set at each round based on an updating policy on-the-fly so as to maximize the cumulative reward or minimize the overall regret. With high dimensional sparse data becoming ubiquitous in various fields nowadays, the most fundamental (generalized) linear bandit framework, although has been extensively studied, becomes inefficient in practice. This fact consequently leads to a line of work on stochastic high dimensional bandit problems with low dimensional structures [16, 24], such as the LASSO bandit and low-rank matrix bandit.
+
+Table 1: Comparison with other low-rank matrix bandit algorithms in rounds $T$ . ( $d = \max \{d_1, d_2\}$ , $D_{rr}$ is the $r$ -th largest singular value of $\Theta^*$ that is free of $d$ )
+
+| METHOD | REGRET BOUND; ORDER OF d | COMMENT |
| UCB-GLM (2017) | O(d1d2√T); 2 | |
| ESTR (2019) | O(√d1d2drT/Drr); 1.5 | BILINEAR |
| ε-FALB (2021) | O(√d1d2dT); 1.5 | BILINEAR |
| Low(G)LOC (2021) | O(√d1d2drT); 1.5 | |
| LOWESTR (2021) | O(√d1d2drT/Drr); 1.5 | |
| G-ESTT (OURS) | O(d√rT/Drr); 1 | |
| G-ESTS (OURS) | O(d√rT/Drr); 1 | |
+
+In this work, we investigate on the generalized low-rank matrix bandit problem firstly studied in [26]: at round $t = 1,\dots ,T$ , the algorithm selects an action represented by a $d_{1}$ by $d_{2}$ matrix $X_{t}$ from the admissible action set $\mathcal{X}_t$ ( $\mathcal{X}_t$ may be fixed), and receives its associated noisy reward $y_{t} = \mu (\langle \Theta^{*},X_{t}\rangle) + \eta_{t}$ where $\Theta^{*}\in \mathbb{R}^{d_{1}\times d_{2}}$ is some unknown low-rank matrix with rank $r\ll \{d_1,d_2\}$ and $\mu (\cdot)$ is the inverse link function. More details about this setting are deferred to Section 3. This problem has vast applicability in real world applications. On the one hand, matrix inputs are appropriate when dealing with paired contexts which are omnipresent in practice. For instance, to design a personalized movie recommendation system, we can formulate each user as $m$ $d_{1}$ -dimensional feature vectors $(x_{1},\ldots ,x_{m}\in \mathbb{R}^{d_{1}})$ and each movie as $m$ $d_{2}$ -dimensional feature vectors $(y_{1},\ldots ,y_{m}\in \mathbb{R}^{d_{2}})$ . A user-item pair can then be naturally represented by a feature matrix defined as the summation of the outer products $\sum_{k = 1}^{m}x_{k}y_{k}^{\top}\in \mathbb{R}^{d_{1}\times d_{2}}$ , which will become the contextual feature observed by the bandit algorithm. Other applications involve interaction features between two groups, such as flight-hotel bundles [26] and dating service [17] can also be similarly established. Besides, low-rank models have gained tremendous success in various areas [5]. In particular, our problem can be regarded as an extension of the inductive matrix factorization problem [14, 38], which estimates low-rank matrices with contextual information, under the online learning scenario.
+
+Our study is inspired by a line of work on stochastic contextual low-rank matrix bandit [15, 17, 26]. To design an algorithm for matrix bandit problems, a naive approach is to flatten the $d_{1}$ by $d_{2}$ feature matrices into vectors and then apply any (generalized) linear bandit algorithms, which, however, would be inefficient when $d_{1}d_{2}$ is large. To take advantage of the low-rank structure, [17] have introduced the bilinear low-rank bandit problem and proposed a two-stage algorithm named ESTR which could achieve a regret bound of $\tilde{O}((d_1 + d_2)^{3/2}\sqrt{rT} / D_{rr})^1$ . Subsequently, [15] constructed a new algorithm called $\epsilon$ -FALB for bilinear bandits and achieved a better regret of $\tilde{O}(\sqrt{d_1d_2(d_1 + d_2)T})$ . However, they only studied the linear reward framework and also restricted the feature matrix as a rank-one matrix. As a follow-up work, [26] further released the rank-one restriction on the action feature matrices, and they introduced an algorithm LowGLOC based on the online-to-confidence-set conversion [2] for generalized low-rank matrix bandits with $\tilde{O}(\sqrt{(d_1 + d_2)^3rT})$ regret bound. However, this regret bound is still loose compared with the optimal rate $\tilde{O}((d_1 + d_2)r\sqrt{T})$ deduced in [15], and the arm set is still assumed fixed at each round. This algorithm is also computationally prohibitive since it requires to calculate the weights of a self-constructed covering of the admissible parameter space at each iteration. And how to find this covering for low-rank matrices is also unclear.
+
+In this work, we propose two efficient methods called G-ESTT and G-ESTS for this problem by modifying two stages of ESTR appropriately from different perspectives. To the best of our knowledge, the proposed methods are the first two generalized (contextual) low-rank bandit algorithms that are computationally feasible, and achieve an improved regret bound of $\tilde{O}((d_1 + d_2)r\sqrt{T})$ upon all existing works on (bilinear) low-rank bandits. The main contributions of this paper can be summarized as: 1) we propose two novel two-stage frameworks G-ESTT and G-ESTS under some mild assumptions. Compared with ESTR in [17], $\epsilon$ -FALB in [15] and LowESTR in [26], our algorithms are proposed for the nonlinear reward framework with arbitrary action matrices. Compared with LowGLOC in [26], our algorithms not only achieve a better regret bound in theory, but also are computationally feasible in practice. 2) For G-ESTT, we extend the GLM-UCB algorithms [11] via a novel regularization technique. 3) Our proposed G-ESTS is simple and could be easily implemented based on any
+
+state-of-the-art generalized linear bandit algorithms. In particular, when we combine G-ESTS with some efficient algorithms (e.g. SGD-TS [9]), the total time complexity after a warm-up stage scales as $O(Tr(d_1 + d_2))$ . 4) We verify that G-ESTT and G-ESTS are the first two algorithms to attain the $\tilde{O}((d_1 + d_2)r\sqrt{T})$ optimal regret bound of low-rank matrix bandit problems up to logarithmic terms. And their practical superiority is also validated in experiments.
+
+Notations: For a vector $x \in \mathbb{R}^n$ , we use $\|x\|_p$ to denote the $l_p$ -norm of the vector $x$ and $\|x\|_H = \sqrt{x^\top Hx}$ to denote its weighted 2-norm with regard to a positive definite matrix $H \in \mathbb{R}^{n \times n}$ . For matrices $X, Y \in \mathbb{R}^{n_1 \times n_2}$ , we use $\|X\|_{\mathrm{op}}$ , $\|X\|_{\mathrm{nuc}}$ and $\|X\|_F$ to define the operator norm, nuclear norm and Frobenius norm of matrix $X$ respectively, and we denote $\langle X, Y \rangle \coloneqq \operatorname{trace}(X^\top Y)$ as the inner product between $X$ and $Y$ . We write $f(n) \asymp g(n)$ if $f(n) = O(g(n))$ and $g(n) = O(f(n))$ .
+
+# 2 Related Work
+
+In this section, we briefly discuss some previous algorithms on low-rank matrix bandit problems. Besides the works we have discussed in the former section, [18, 33] considered the rank-one bandit problems where the expected reward forms a rank-one matrix and the player selects an element from this matrix as the expected reward at each round. In addition, [19] also studied the rank-one matrix bandit via an elimination-based algorithm. Alternatively, [12, 20, 25] considered the general low-rank matrix bandit, and furthermore [13] considered a stochastic low-rank tensor bandit. However, for all these works the feature matrix of an action could be flattened into a one-hot basis vector, and our work yields a more general structure.
+
+Additionally, [24] extended some previous works [16] and presented a unified algorithm based on a greedy search for high-dimensional bandit problems. But it's nontrivial to extend the framework to the matrix bandit problem. For example, they assume that the minimum eigenvalue of the covariance matrix could be strictly lower bounded, but this lower bound would mostly depend on the size of feature matrices, and hence would affect the regret bound consequently.
+
+# 3 Preliminaries
+
+In this section we review our problem setting and introduce the assumptions for our theoretical analysis. Let $T$ be the total number of rounds and $\mathcal{X}_t$ be the action set ( $\mathcal{X}_t$ could be fixed or not). Throughout this paper, we denote the action set $\mathcal{X}_t = \mathcal{X}$ as fixed for notation simplicity, while our frameworks also work with the same regret bound when $\mathcal{X}_t$ varies over time (see Appendix H.3 for more details.) Algorithms along with theory could be identically obtained when the action set varies (Appendix H.3). At each round $t \in [T]$ , The agent selects an action $X_t \in \mathcal{X}_t$ and gets the payoff $y_t$ which is conditionally independent of the past payoffs and choices. For the generalized low-rank matrix bandits, we assume the payoff $y_t$ follows a canonical exponential family such that:
+
+$$
+\begin{array}{l} p _ {\Theta^ {*}} \left(y _ {t} \mid X _ {t}\right) = \exp \left(\frac {y _ {t} \beta - b (\beta)}{\phi} + c \left(y _ {t}, \phi\right)\right), \text {w h e r e} \beta = \operatorname {v e c} \left(X _ {t}\right) ^ {\top} \operatorname {v e c} \left(\Theta^ {*}\right) := \left\langle X _ {t}, \Theta^ {*} \right\rangle , \tag {1} \\ \mathbb {E} _ {\Theta^ {*}} \left(y _ {t} \mid X _ {t}\right) = b ^ {\prime} \left(\left\langle X _ {t}, \Theta^ {*} \right\rangle\right) := \mu \left(\left\langle X _ {t}, \Theta^ {*} \right\rangle\right), \\ \end{array}
+$$
+
+where $\Theta^{*} \subseteq \Theta$ is a fixed but unknown matrix with rank $r \ll \{d_{1}, d_{2}\}$ and $\Theta$ is some admissible compact subset of $\mathbb{R}^{d_1 \times d_2}$ (w.l.o.g. $d_{1} = \Theta(d_{2})$ ). We also call $\mu(\langle X_{t}, \Theta^{*} \rangle)$ the reward of action $X_{t}$ .
+
+In addition, one can represent model (1) in the following Eqn. (2). Note that if we relax the definition of $\mu(\cdot)$ to any real univariate function with some centered exogenous random noise $\eta_t$ , the model shown in Eqn. (2) generalizes our problem setting to a single index model (SIM) matrix bandit, and the generalized low-rank matrix bandit problem is a special case of this model.
+
+$$
+y _ {t} = \mu \left(\left\langle X _ {t}, \Theta^ {*} \right\rangle\right) + \eta_ {t}. \tag {2}
+$$
+
+Here, $\eta_t$ follows the sub-Gaussian property with some constant parameter $\sigma_0$ conditional on the filtration $\mathcal{F}_t = \{X_t, X_{t-1}, \eta_{t-1}, \ldots, X_1, \eta_1\}$ . We also denote $d = \max \{d_1, d_2\}$ . And it is natural to evaluate the agent's strategy based on the regret [3], defined as the difference between the total reward of optimal policy and the agent's total reward in practice:
+
+$$
+R e g r e t _ {t} = \sum_ {i = 1} ^ {t} \max _ {X \in \mathcal {X}} \mu (\langle X, \Theta^ {*} \rangle) - \mu (\langle X _ {i}, \Theta^ {*} \rangle).
+$$
+
+We also present the following two definitions to facilitate further analysis via Stein's method:
+
+Definition 3.1. Let $p: \mathbb{R} \to \mathbb{R}$ be a univariate probability density function defined on $\mathbb{R}$ . The score function $S^p: \mathbb{R} \to \mathbb{R}$ regarding density $p(\cdot)$ is defined as:
+
+$$
+S ^ {p} (x) = - \nabla_ {x} \log (p (x)) = - \nabla_ {x} p (x) / p (x), \quad x \in \mathbb {R}.
+$$
+
+In particular, for a random matrix with its entrywise probability density $\mathbf{p} = (p_{ij}) : \mathbb{R}^{d_1 \times d_2} \to \mathbb{R}^{d_1 \times d_2}$ , we define its score function $S^{\mathbf{p}} = (S_{ij}^{\mathbf{p}}) : \mathbb{R}^{d_1 \times d_2} \to \mathbb{R}^{d_1 \times d_2}$ as $S_{ij}^{\mathbf{p}}(x) = S^{p_{ij}}(x)$ by applying the univariate score function to each entry of $\mathbf{p}$ independently.
+
+Definition 3.2. (Fact 2.6, [27]) Given a rectangular matrix $A \in \mathbb{R}^{d_1 \times d_2}$ , the (Hermitian) dilation $\mathcal{H}: \mathbb{R}^{d_1 \times d_2} \to \mathbb{R}^{(d_1 + d_2) \times (d_1 + d_2)}$ is defined as:
+
+$$
+\mathcal {H} (A) = \left( \begin{array}{c c} 0 & A \\ A ^ {\top} & 0 \end{array} \right).
+$$
+
+We would omit the subscript $x$ of $\nabla$ and the superscript $p$ of $S$ when the underlying distribution is clear. With these definitions, we make the following mild assumptions:
+
+Assumption 3.3. (Finite second-moment score) There exists a sampling distribution $\mathcal{D}$ over $\mathcal{X}$ such that for the random matrix $X$ drawn from $\mathcal{D}$ with its associated density $\mathbf{p}:\mathbb{R}^{d_1\times d_2}\to \mathbb{R}^{d_1\times d_2}$ , we have $\mathbb{E}[(S^{\mathbf{P}}(X))_{ij}^2 ]\leq M,\forall i,j$ .
+
+Assumption 3.4. The norm of true parameter $\Theta^{*}$ and feature matrices in $\mathcal{X}$ is bounded: there exists $S\in \mathbb{R}^{+}$ such that for all arms $X\in \mathcal{X}$ , $\| X\| _F$ , $\| \Theta^{*}\|_{F}\leq S_{0}$ .
+
+Assumption 3.5. The inverse link function $\mu(\cdot)$ in GLM is continuously differentiable and there exist two constants $c_{\mu}, k_{\mu}$ such that $0 < c_{\mu} \leq \mu'(x) \leq k_{\mu}$ for all $|x| \leq S_0$ .
+
+Assumption 3.3 is commonly used in Stein's method [7], and easily satisfied by a wide range of distributions that are non-zero-mean or even non-sub-Gaussian thereby allowing us to work with cases not previously possible. For example, to find $\mathcal{D}$ we only need the convex hull of $\mathcal{X}$ contains a ball with radius $R$ , and then we can use $p_{ij}$ as centered normal p.d.f. with variance $R^2 / (d_id_j)$ . This choice works well in our experiments and please refer to Appendix I for more details. Furthermore, Assumption 3.4 and 3.5 are also standard in contextual generalized bandit literature, and they explicitly imply that we have an upper bound as $|\mu (\langle X,\Theta \rangle)|\leq |\mu (0)| + \max \{|c_\mu |,|k_\mu |\} S_0\coloneqq S_f$ .
+
+# 4 Main Results
+
+In this section, we present our novel two-stage frameworks, named Generalized Explore Subspace Then Transform (G-ESTT) and Generalized Explore Subspace Then Subtract (G-ESTS) respectively. These two algorithms are inspired by the two-stage algorithm ESTR proposed in [17]. ESTR estimates the row and column subspaces for the true parameter $\Theta^{*}$ in stage 1. In stage 2, it exploits the estimated subspaces and transforms the original matrix bandits into linear bandits with sparsity, and then invoke a penalized approach called LowOFUL.
+
+To extend their work into the nonlinear reward setting, we firstly adapt stage 1 into the GLM framework by estimating $\Theta^{*}$ via the following quadratic optimization problem in Eqn. (6) inspired by a line of work in nonlinear signal estimation [29, 37]. And then we propose two different methods based on the estimated subspaces to deal with GLM bandits for stage 2: for G-ESTT we adapt the idea of LowOFUL into the GLM framework and propose an improved algorithm with regularization. For G-ESTS we innovatively drop all negligible entries to get a low-dimensional bandit, which could efficiently be solved by any modern generalized linear bandit algorithm with much less computation.
+
+# 4.1 Stage 1: Subspace Exploration
+
+For any real-value function $f(\cdot)$ defined on $\mathbb{R}$ , and symmetric matrix $A \in \mathbb{R}^{d \times d}$ with its SVD decomposition as $A = UDU^{\top}$ , we define $f(A) \coloneqq U\mathrm{diag}(f(D_{11}), \ldots, f(D_{dd}))U^{\top}$ . To explore the valid subspace of the parameter matrix $\Theta^{*}$ , we firstly define a function $\psi : \mathbb{R} \to \mathbb{R}$ [27] in Eqn. (5) and subsequently we define $\tilde{\psi}_{\nu} : \mathbb{R}^{d_1 \times d_2} \to \mathbb{R}^{d_1 \times d_2}$ as $\tilde{\psi}_{\nu}(A) = \psi(\nu \mathcal{H}(A))_{1:d_1, (d_1 + 1): (d_1 + d_2)} / \nu$ for some parameter $\nu \in \mathbb{R}^{+}$ .
+
+$$
+\psi (x) = \left\{ \begin{array}{l l} \log (1 + x + x ^ {2} / 2), & x \geq 0; \\ - \log (1 - x + x ^ {2} / 2), & x < 0. \end{array} \right. \tag {5}
+$$
+
+# Algorithm 1 Generalized Explore Subspace Then Transform (G-ESTT)
+
+Input: $\mathcal{X}, T, T_1, \mathcal{D}$ , the probability rate $\delta$ , parameters for Stage 2: $\lambda, \lambda_{\perp}$ .
+
+# Stage 1: Subspace Estimation
+
+1: for $t = 1$ to $T_{1}$ do
+2: Pull arm $X_{t}\in \mathcal{X}$ according to $\mathcal{D}$ , observe payoff $y_{t}$ .
+3: end for
+4: Obtain $\widehat{\Theta}$ based on Eqn. (6).
+5: Obtain the full SVD of $\widehat{\Theta} = [\widehat{U},\widehat{U}_{\perp}]\widehat{D} [\widehat{V},\widehat{V}_{\perp}]^{\top}$ where $\widehat{U}\in \mathbb{R}^{d_1\times r}$ , $\widehat{V}\in \mathbb{R}^{d_2\times r}$ .
+
+# Stage 2: Sparse Generalized Linear Bandits
+
+6: Rotate the arm feature set: $\mathcal{X}' := [\widehat{U}, \widehat{U}_{\perp}]^{\top} \mathcal{X}[\widehat{V}, \widehat{V}_{\perp}]$ and the admissible parameter space: $\Theta' := [\widehat{U}, \widehat{U}_{\perp}]^{\top} \Theta[\widehat{V}, \widehat{V}_{\perp}]$ .
+7: Define the vectorized arm set so that the last $(d_1 - r)\cdot (d_2 - r)$ components are negligible:
+
+$$
+\mathcal {X} _ {0} := \left\{\operatorname {v e c} \left(\mathcal {X} _ {1: r, 1: r} ^ {\prime}\right), \operatorname {v e c} \left(\mathcal {X} _ {r + 1: d _ {1}, 1: r} ^ {\prime}\right), \operatorname {v e c} \left(\mathcal {X} _ {1: r, r + 1: d _ {2}} ^ {\prime}\right), \operatorname {v e c} \left(\mathcal {X} _ {r + 1: d _ {1}, r + 1: d _ {2}} ^ {\prime}\right) \right\}, \tag {3}
+$$
+
+and similarly define the parameter set:
+
+$$
+\theta_ {0} := \left\{\operatorname {v e c} \left(\theta_ {1: r, 1: r} ^ {\prime}\right), \operatorname {v e c} \left(\theta_ {r + 1: d _ {1}, 1: r} ^ {\prime}\right), \operatorname {v e c} \left(\theta_ {1: r, r + 1: d _ {2}} ^ {\prime}\right), \operatorname {v e c} \left(\theta_ {r + 1: d _ {1}, r + 1: d _ {2}} ^ {\prime}\right) \right\}. \tag {4}
+$$
+
+8: For $T_{2} = T - T_{1}$ rounds, invoke (P)LowGLM-UCB with $\mathcal{X}_0, \Theta_0, k = (d_1 + d_2)r - r^2, (\lambda_0, \lambda_\perp)$ .
+
+We consider the following well-defined regularized minimization problem with nuclear norm penalty:
+
+$$
+\widehat {\Theta} = \arg \min _ {\Theta \in \mathbb {R} ^ {d _ {1} \times d _ {2}}} L _ {T _ {1}} (\Theta) + \lambda_ {T _ {1}} \| \Theta \| _ {\mathrm {n u c}}, L _ {T _ {1}} (\Theta) = \langle \Theta , \Theta \rangle - \frac {2}{T _ {1}} \sum_ {i = 1} ^ {T _ {1}} \left\langle \tilde {\psi} _ {\nu} \left(y _ {i} \cdot S (X _ {i})\right), \Theta \right\rangle . \tag {6}
+$$
+
+An interesting fact is that our estimator is invariant under different choices of function $\mu (\cdot)$ , and we could present the following oracle inequality regarding the estimation error $\left\| \widehat{\Theta} -\mu^{*}\Theta^{*}\right\|_{F}$ for some nonzero constant $\mu^{*}$ by adapting generalized Stein's Method [7].
+
+Theorem 4.1. (Bounds for GLM) For any low-rank generalized linear model with samples $X_{1},\ldots ,X_{T_{1}}$ drawn from $\mathcal{X}$ according to $\mathcal{D}$ in Assumption 3.3, and assume Assumption 3.4 and 3.5 hold, then for the optimal solution to the nuclear norm regularization problem (6) with $\nu = \sqrt{2\log(2(d_1 + d_2) / \delta) / ((4\sigma_0^2 + S_f^2)MT_1d_1d_2)}$ and
+
+$$
+\lambda_ {T _ {1}} = 4 \sqrt {\frac {2 (4 \sigma_ {0} ^ {2} + S _ {f} ^ {2}) M d _ {1} d _ {2} \log (2 (d _ {1} + d _ {2}) / \delta)}{T _ {1}}},
+$$
+
+with probability at least $1 - \delta$ it holds that:
+
+$$
+\left\| \widehat {\Theta} - \mu^ {*} \Theta^ {*} \right\| _ {F} ^ {2} \leq \frac {C _ {1} d _ {1} d _ {2} r \log \left(\frac {2 \left(d _ {1} + d _ {2}\right)}{\delta}\right)}{T _ {1}}, \tag {7}
+$$
+
+for $C_1 = 36(4\sigma_0^2 + S_f^2)M$ and some nonzero constant $\mu^*$ .
+
+The proof of Theorem 4.1 is based on a novel adaptation of Stein-typed Lemmas and is deferred to Appendix B. We believe this oracle bound is non-trivial since the rate of convergence is better than that deduced from the restricted strong convexity (details in Appendix J) even without assuming the sub-Gaussian property. We also present an intuitive explanation on why our Stein-type method is better than existing matrix estimation approaches under our problem setting in Appendix J.2 Remark. In addition, this bound also holds under a more general SIM in Eqn. (2) other than just GLM. Furthermore, although there exists a non-zero constant $\mu^{*}$ in the error term, it will not affect the singular vectors and subspace estimation of $\Theta^{*}$ at all.
+
+After acquiring the estimated $\widehat{\Theta}$ in stage 1, we can obtain the corresponding SVD as $\widehat{\Theta} = [\widehat{U},\widehat{U}_{\perp}]\widehat{D} [\widehat{V},\widehat{V}_{\perp}]^{\top}$ , where $\widehat{U}\in \mathbb{R}^{d_1\times r},\widehat{U}_{\perp}\in \mathbb{R}^{d_1\times (d_1 - r)},\widehat{V}\in \mathbb{R}^{d_2\times r}$ and $\widehat{V}_{\perp}\in \mathbb{R}^{d_2\times (d_2 - r)}$ . And we assume the SVD of the matrix $\Theta^{*}$ can be represented as $\Theta^{*} = UDV^{\top}$ where $U\in \mathbb{R}^{d_1\times r}$ and $V\in \mathbb{R}^{d_2\times r}$ . To transform the original generalized matrix bandits into generalized linear bandit
+
+# Algorithm 2 LowGLM-UCB
+
+Input: $T_{2},k,\mathcal{X}_{0}$ , the probability rate $\delta$ , penalization parameters $(\lambda_0,\lambda_\perp)$
+
+Initialize $M_{1}(c_{\mu}) = \sum_{i = 1}^{T_{1}}x_{s_{1},i}x_{s_{1},i}^{\top} + \Lambda /c_{\mu}$
+
+for $t > 1$ do
+
+Estimate $\hat{\theta}_t$ according to (10).
+
+Choose the arm $x_{t} = \arg \max_{x\in \mathcal{X}_{0}}\{\mu (x^{\top}\hat{\theta}_{t}) + \rho_{t}(\delta)\| x\|_{M_{t}^{-1}(c_{\mu})}\}$ , receive $y_{t}$
+
+Update $M_{t + 1}(c_{\mu})\longleftarrow M_t(c_\mu) + x_tx_t^\top$
+
+end for
+
+problems, we follow the works in [17] and penalize those covariates that are complementary to $\widehat{U}$ and $\widehat{V}$ . Specifically, we could orthogonally rotate the parameter space $\Theta$ and the action set $\mathcal{X}$ as:
+
+$$
+\boldsymbol {\theta} ^ {\prime} = [ \widehat {U}, \widehat {U} _ {\perp} ] ^ {\top} \boldsymbol {\Theta} [ \widehat {V}, \widehat {V} _ {\perp} ], \quad \boldsymbol {\mathcal {X}} ^ {\prime} = [ \widehat {U}, \widehat {U} _ {\perp} ] ^ {\top} \boldsymbol {\mathcal {X}} [ \widehat {V}, \widehat {V} _ {\perp} ],
+$$
+
+Define the total dimension $p \coloneqq d_1d_2$ , the effective dimension $k \coloneqq d_1d_2 - (d_1 - r)(d_2 - r)$ and the $r$ -th largest singular value for $\Theta^*$ as $D_{rr}$ , and vectorize the new arm space $\mathcal{X}'$ and admissible parameter space as shown in Eqn. (3) and (4). Then for the true parameter $\theta^*$ after transformation, we know that $\theta_{k+1:p}^* = \mathrm{vec}(\Theta_{r+1:d_1,r+1:d_2}^{*,7})$ is almost null based on results in [32] and Theorem 4.1:
+
+$$
+\left\| \theta_ {k + 1: p} ^ {*} \right\| _ {2} = \left\| \widehat {U} _ {\perp} ^ {\top} U D V ^ {\top} \widehat {V} _ {\perp} \right\| _ {F} \leq \left\| \widehat {U} _ {\perp} ^ {\top} U \right\| _ {F} \left\| \widehat {V} _ {\perp} ^ {\top} V \right\| _ {F} \cdot \| D \| _ {\mathrm {o p}} \lesssim \frac {d _ {1} d _ {2} r}{T _ {1} D _ {r r} ^ {2}} \log \left(\frac {d _ {1} + d _ {2}}{\delta}\right) := S _ {\perp}. \tag {8}
+$$
+
+Therefore, this problem degenerates to an equivalent $d_{1}d_{2}$ -dimensional generalized linear bandit with a sparse structure (i.e. last $p - k$ entries of $\theta^{*}$ are almost null according to Eqn. (8)). To reload the notation we define $\mathcal{X}_0$ , $\Theta_0$ as the new feature set and parameter space as shown in Algorithm 1.
+
+Remark. Note the magnitude of $D_{rr}$ would be free of $d$ since $\Theta^*$ contains only $r$ nonzero singular values, and hence we assume that $D_{rr} = \Theta(1/\sqrt{r})$ under Assumption 3.4. This issue has been ignored in all previous analysis of explore-then-commit-type algorithms (e.g. ESTR [17], Low-ESTR [26]), where the final regret bound of them should be of order $\tilde{O}(d^{3/2}r\sqrt{T})$ instead of the originally-used $\tilde{O}(d^{3/2}\sqrt{rT})$ because of the existence of $D_{rr}$ . However, due to the fact that $r \ll d$ , it is intriguing and crucial to reduce the order of $d$ in the final regret bound, while the order of $r$ is less important. As shown in Table 1, the regret bounds of all previous low-rank matrix bandits algorithms depend on $d$ by the order $3/2$ , and we would show that both of our frameworks could improve the cumulative regret bound by a factor of $\sqrt{d}$ , which coincides with the dependence of $d$ in the minimax lower bound of the low-rank matrix bandit problem deduced in [26]. A detailed analysis is presented in the rest of our paper.
+
+# 4.2 Stage 2 of G-ESTT
+
+After reducing the original generalized matrix bandit problem into an identical $p$ -dimensional generalized linear bandit problem in stage 2, we can reformulate the problem in the following way: at each round $t$ , the agent chooses a vector $x_{t}$ of dimension $p$ from the transformed action set $\mathcal{X}_0$ , and observes a noisy reward $y_{t} = \mu (x_{t}^{\top}\theta^{*}) + \eta_{t}$ . To make use of our additional knowledge shown in Eqn. (8), we propose LowGLM-UCB as an extension of the standard generalized linear bandit algorithm GLM-UCB [11] combined with self-normalized martingale technique [1]. Specifically, we consider the following maximum quasi-likelihood estimation problem shown in Eqn. (9) for each round with a weighted regularizer, where the regularizer is $\| \theta \|_{\Lambda}^{2} / 2 = \theta^{\top}\Lambda \theta /2$ for some positive definite diagonal matrix $\Lambda = \mathrm{diag}(\lambda_0,\dots ,\lambda_0,\lambda_\perp ,\dots ,\lambda_\perp)$ with $\lambda_0$ only applied to the first $k$ diagonal entries. By enlarging $\lambda_{\perp}$ , we ensure more penalization forced on the last $p - k$ element of $\theta^{*}$ as desired.
+
+$$
+\hat {\theta} _ {t} = \arg \max _ {\theta} \widetilde {L} _ {t} ^ {\Lambda} (\theta),
+$$
+
+$$
+\widetilde {L} _ {t} ^ {\Lambda} (\theta) = \sum_ {i = 1} ^ {T _ {1}} \left[ y _ {s _ {1}, i} x _ {s _ {1}, i} ^ {\top} \theta - b \left(x _ {s _ {1}, i} ^ {\top} \theta\right) \right] + \sum_ {i = 1} ^ {t - 1} \left[ y _ {i} x _ {i} ^ {\top} \theta - b \left(x _ {i} ^ {\top} \theta\right) \right] - \frac {1}{2} \| \theta \| _ {\Lambda} ^ {2}. \tag {9}
+$$
+
+Here $x_{s_1,i}$ in Eqn. (9) is the special vectorization shown in Eqn. (3) of $[\widehat{U},\widehat{U}_{\perp}]^{\top}X_{i}[\widehat{V},\widehat{V}_{\perp}]$ where $X_{i}$ is the arm we randomly pull at $i$ -th step in stage 1, and $y_{s_1,i}$ is the corresponding payoff we observe. $x_{i}$ in the second summation of Eqn. (9) refers to the arm we pull at $i$ -th step in stage 2. Since $\widetilde{L}_t^\Lambda (\theta)$ is a strictly concave function of $\theta$ , we have its gradient equal to 0 at the maximum $\hat{\theta}_t$ i.e. $\nabla_{\theta}\widetilde{L}_{t}^{\Lambda}(\theta)|_{\hat{\theta}_{t}} = 0$ . In what follows, for $t\geq 2,\theta \in \mathbb{R}^{p}$ we define the function $g_{t}(\theta)$ and have that
+
+$$
+\begin{array}{l} \nabla_ {\theta} \widetilde {L} _ {t} ^ {\Lambda} (\theta) = \sum_ {i = 1} ^ {T _ {1}} y _ {s _ {1}, i} x _ {s _ {1}, i} + \sum_ {i = 1} ^ {t - 1} y _ {i} x _ {i} - \Big (\underbrace {\sum_ {i = 1} ^ {T _ {1}} \mu (x _ {s _ {1} , i} ^ {\top} \theta) x _ {s _ {1} , i} + \sum_ {i = 1} ^ {t - 1} \mu (x _ {i} ^ {\top} \theta) x _ {i} + \Lambda \theta} _ {:= g _ {t} (\theta)} \Big), \\ \left. \nabla_ {\theta} \widetilde {L} _ {t} ^ {\Lambda} (\theta) \right| _ {\hat {\theta} _ {t}} = 0 \quad \Longrightarrow \quad g _ {t} (\hat {\theta} _ {t}) = \sum_ {i = 1} ^ {T _ {1}} y _ {s _ {1}, i} x _ {s _ {1}, i} + \sum_ {i = 1} ^ {t - 1} y _ {i} x _ {i}. \tag {10} \\ \end{array}
+$$
+
+We also define a matrix function $M_{t}(s) = \sum_{i=1}^{T_{1}} x_{s_{1},i} x_{s_{1},i}^{\top} + \sum_{k=1}^{t-1} x_{k} x_{k}^{\top} + \Lambda / s$ for $s \in \mathbb{R}^{+}$ and denote $V_{t} := M_{t}(1)$ . Furthermore, a remarkable benefit of reusing the actions $\{X_{i}\}_{i=1}^{T_{1}}$ we randomly pull in stage 1 is that they contain more randomness and are preferable to the ones we select based on some strategy in stage 2 regarding the parameter estimation because most vector recovery theory requires sufficient randomness during sampling. More inspiring, the projection step in the tradition GLM-UCB [11], which might be nonconvex and hence hard to solve, is no longer required due the consistency of $\hat{\theta}_{t}$ after reutilizing $\{X_{i}\}_{i=1}^{T_{1}}$ . Specifically, if we assume the true parameter $\theta^{*}$ lies in the interior of $\Theta_{0}$ and the sampling distribution $\mathcal{D}$ satisfies sub-Gaussian property with parameter $\sigma$ , and Assumption 3.4, 3.5 held, then we can show that $\left\| \hat{\theta}_{t} - \theta^{*} \right\|_{2} \leq 1$ holds with probability at least $1 - \delta$ as long as $T_{1} \geq ((\hat{C}_{1}\sqrt{p} + \hat{C}_{2}\sqrt{\log(1 / \delta)}) / \sigma^{2})^{2} + 2B / \sigma^{2}$ holds for some absolute constants $\hat{C}_{1}, \hat{C}_{2}$ with the definition $B := 16\sigma_{0}^{2}(p + \log(1 / \delta)) / c_{\mu}^{2}$ . An intuitive explanation along with a rigorous proof are deferred to Appendix D due to the space limit. The proposed LowGLM-UCB is shown in Algorithm 2, and its regret analysis is presented in Theorem C.1 in Appendix.
+
+Notice that we can simply replace $M_{t}(c_{\mu})$ by $V_{t}$ in Algorithm 2, and the regret bound would increase at most up to a constant factor (Appendix G). A potential drawback of Algorithm 2 is that in each iteration we have to calculate $\hat{\theta}_{t}$ , which might be computationally expensive. We could resolve this problem by only recomputing $\hat{\theta}_{t}$ whenever $|M_{t}(c_{\mu})|$ increases significantly, i.e. by a constant factor $C > 1$ in scale. And consequently we only need to solve the Eqn. (10) for $O(\log (T_2))$ times up to the horizon $T_{2}$ , which remarkably saves the computation. Meanwhile, the bound of the regret would only increase by a constant multiplier $\sqrt{C}$ . We call this modified algorithm as PLowGLM-UCB with the initial letter "P" standing for "Parsimonious". Its pseudo-code and regret analysis are given in Appendix H.1. Equipped with LowGLM-UCB in stage 2, we deduce the overall regret of G-ESTT:
+
+# 4.2.1 Overall regret of G-ESTT
+
+To quantify the performance of our algorithm, we first define $\alpha_{t}^{x}(\cdot)$ and $\beta_t^x (\cdot)$ as
+
+$$
+\alpha_ {t} (\delta) := \frac {k _ {\mu}}{c _ {\mu}} \left(\sigma_ {0} \sqrt {k \log \left(1 + \frac {c _ {\mu} S _ {0} ^ {2} t}{k \lambda_ {0}}\right) + \frac {c _ {\mu} S _ {0} ^ {2} t}{\lambda_ {\perp}} - \log \left(\delta^ {2}\right)} + \sqrt {c _ {\mu}} \left(\sqrt {\lambda_ {0}} S _ {0} + \sqrt {\lambda_ {\perp}} S _ {\perp}\right)\right), \tag {11}
+$$
+
+$$
+\beta_ {t} ^ {x} (\delta) := \alpha_ {t} (\delta) \| x \| _ {M _ {t} ^ {- 1} \left(c _ {\mu}\right)}. \tag {12}
+$$
+
+And the following Theorem 4.2 exhibits the overall regret bound for G-ESTT.
+
+Theorem 4.2. (Regret of G-ESTT) Suppose we set $T_{1} \asymp \sqrt{d_{1}d_{2}rT\log((d_{1} + d_{2}) / \delta)} / D_{rr}$ , and we invoke LowGLM-UCB (or PLowGLM-UCB) in stage 2 with $\rho_{t}(\delta) = \alpha_{t + T_{1}}(\delta /2), p = d_{1}d_{2}, k = (d_{1} + d_{2})r - r^{2}, \lambda_{\perp} = c_{\mu}S_{0}^{2}T / (k\log (1 + c_{\mu}S_{0}^{2}T / (k\lambda_{0})))$ , and the rotated arm sets $\mathcal{X}_0$ and available parameter space $\Theta_0$ . The overall regret of G-ESTT is, with probability at least $1 - \delta$ ,
+
+$$
+R e g r e t _ {T} = \tilde {O} \left(\left(\frac {\sqrt {r d _ {1} d _ {2}}}{D _ {r r}} + k\right) \sqrt {T}\right)
+$$
+
+Note G-ESTT improves all existing regret bounds by a $\sqrt{d}$ factor based on Table 1 given that $r \ll d$ .
+
+# Algorithm 3 Generalized Explore Subspace Then Subtract (G-ESTS)
+
+Input: $\mathcal{X}, T, T_1, \mathcal{D}$ , the probability rate $\delta$ , parameters for Stage 2: $\lambda, \lambda_{\perp}$ .
+
+# Stage 1: Subspace Estimation
+
+1: Randomly choose $X_{t}\in \mathcal{X}$ according to $\mathcal{D}$ and record $X_{t},Y_{t}$ for $t = 1,\ldots T_1$
+2: Obtain $\widehat{\Theta}$ from Eqn. (6), and calculate its full SVD as $\widehat{\Theta} = [\widehat{U},\widehat{U}_{\perp}]\widehat{D} [\widehat{V},\widehat{V}_{\perp}]^{\top}$ where $\widehat{U}\in \mathbb{R}^{d_1\times r}$ , $\widehat{V}\in \mathbb{R}^{d_2\times r}$ .
+
+# Stage 2: Low Dimensional Bandits
+
+3: Rotate the arm feature set: $\mathcal{X}' := [\widehat{U},\widehat{U}_{\perp}]^{\top}\mathcal{X}[\widehat{V},\widehat{V}_{\perp}]$ and the admissible parameter space: $\Theta' := [\widehat{U},\widehat{U}_{\perp}]^{\top}\Theta[\widehat{V},\widehat{V}_{\perp}]$ .
+4: Define the vectorized arm set so that the last $(d_1 - r) \cdot (d_2 - r)$ components are negligible, and then drop them:
+
+$$
+\mathcal {X} _ {0, s u b} := \left\{\operatorname {v e c} \left(\mathcal {X} _ {1: r, 1: r} ^ {\prime}\right), \operatorname {v e c} \left(\mathcal {X} _ {r + 1: d _ {1}, 1: r} ^ {\prime}\right), \operatorname {v e c} \left(\mathcal {X} _ {1: r, r + 1: d _ {2}} ^ {\prime}\right) \right\}, \tag {13}
+$$
+
+and also refine the parameter set accordingly:
+
+$$
+\theta_ {0, s u b} := \left\{\operatorname {v e c} \left(\theta_ {1: r, 1: r} ^ {\prime}\right), \operatorname {v e c} \left(\theta_ {r + 1: d _ {1}, 1: r} ^ {\prime}\right), \operatorname {v e c} \left(\theta_ {1: r, r + 1: d _ {2}} ^ {\prime}\right) \right\}. \tag {14}
+$$
+
+5: For $T_{2} = T - T_{1}$ rounds, invoke any generalized linear bandit algorithm with $\mathcal{X}_{0,sub}$ , $\Theta_{0,sub}$ , $k = (d_{1} + d_{2})r - r^{2}$ .
+
+# 4.3 Stage 2 of G-ESTS
+
+Although G-ESTT is more efficient than all existing algorithms on our problem setting, it still needs to calculate the MLE in high dimensional space which might be increasingly formidable with large sizes of feature matrices. Note this computational issue remains ubiquitous among most bandit algorithms on high dimensional problems with sparsity, not to mention these algorithms rely on multiple unspecified hyperparameters. Therefore, to handle this practical issue, we propose another fast and efficient framework called G-ESTS in this section.
+
+Inspired by the success of dimension reduction in machine learning [34], we propose G-ESTS as shown in Algorithm 3. And we summarize the core idea of G-ESTS as: After rearranging the vectorization of the action set $\mathcal{X}'$ and the unknown $\Theta'^*$ as we have shown in Eqn. (3) and (4) for G-ESTT, we can simply exclude, rather than penalize, the subspaces that are complementary to the rows and columns of $\widehat{\Theta}$ . In other words, we could remove the last $p - k$ entries directly, i.e. Eqn. (13) and (14). Intriguingly, not only can we get a low-dimensional $(k)$ generalized linear bandit problem in stage 2, where redundant dimensions are excluded and hence any state-of-the-art algorithms could be readily invoked. But also we obtain the optimal regret bound of scale $\tilde{O}(dr\sqrt{T})$ again as shown in Table 1 with $D_r r = O(1/\sqrt{r})$ . Besides, G-ESTS requires exceedingly less computation compared with other existing algorithms since consequently we get a low-dimensional bandit problem. In summary, our G-ESTS is superior regarding both theoretical guarantee and computational efficiency.
+
+# 4.3.1 Overall regret of G-ESTS
+
+Theorem 4.3. (Regret of G-ESTS) Suppose we set $T_{1} \asymp \sqrt{d_{1}d_{2}rT\log((d_{1} + d_{2}) / \delta)} / D_{rr}$ , and we invoke any efficient generalized linear bandit algorithm with regret bound $\tilde{O}(k\sqrt{T})^{2}$ in stage 2 with $p = d_{1}d_{2}, k = (d_{1} + d_{2})r - r^{2}$ , and the reduced arm sets $\mathcal{X}_{0,sub}$ and available parameter space $\Theta_{0,sub}$ . The overall regret of G-ESTS is, with probability at least $1 - \delta$ ,
+
+$$
+R e g r e t _ {T} = \tilde {O} \left(\left(\frac {\sqrt {r d _ {1} d _ {2}}}{D _ {r r}} + k\right) \sqrt {T}\right)
+$$
+
+According to Theorem 4.2 and 4.3, both G-ESTT and G-ESTS could achieve an improved $\tilde{O}(dr\sqrt{T})$ regret bound with $D_{rr} = \Theta(1/\sqrt{r})$ . Surprisingly, this matches the lower bound of low-rank matrix bandits presented in [26] up to logarithm terms. To the best of our knowledge, our methods are the first two methods that attain this optimal rate. In addition, given the finite arm set, our G-ESTS
+
+Table 2: Time in minutes required to make decisions all over round $T$ in simulations (480 arms).
+
+| d | 10 | 12 |
| r | 1 | 2 | 1 | 2 |
| G-ESTS | 39.46 | 45.41 | 41.28 | 48.52 |
| G-ESTT | 516.14 | 531.95 | 520.25 | 539.83 |
| SGD-TS | 99.57 | 101.34 | 101.82 | 104.42 |
| LowESTR | 401.88 | 419.15 | 410.31 | 425.92 |
+
+framework can even achieve a better regret bound of order $\tilde{O} (\sqrt{d_1d_2rT} /D_{rr})$ (detailed proof in Appendix F.2), and this result is better than the lower regret bound with infinite arms by a $k\sqrt{T}$ term.
+
+In the following experiments, We will implement the SGD-TS algorithm [9] in stage 2 of G-ESTS since SGD-TS could efficiently proceed with only $O(dT)$ complexity for $d$ -dimensional features over $T$ rounds. Therefore, the total computational complexity of stage 2 is at most $O(T_{2}(d_{1} + d_{2})r)$ , which is significantly less than that of other methods for low-rank matrix bandits (e.g. LowESTR [26]). And the total time complexity of G-ESTS would only scale $O(T_{1}d_{1}d_{2} / \epsilon^{2} + T_{2}(d_{1} + d_{2})r)$ where $\epsilon$ is the accuracy for subgradient methods in stage 1. This fact also firmly validates the practical superiority of our G-ESTS approach. We naturally believe that this G-ESTS framework can be easily implemented in the linear setting as a special case of GLM, where in stage 2 one can utilize any linear bandit algorithm accordingly. In addition, we can easily modify our approaches for the contextual setting by merely transforming the action sets at each iteration with the same regret bound. More details with pseudo-codes for the contextual case are in Appendix H.3.
+
+# 5 Experiments
+
+In this section, we show by simulation experiments that our proposed G-ESTT (with LowGLM-UCB), G-ESTS (with SGD-TS) outperform existing algorithms for the generalized low-rank matrix bandit problems. Since we are the first to propose a practical algorithm for this problem, currently there is no existing literature for comparison. In order to validate the advantage of utilizing low-rank structure and generalized reward functions, we compare with the original SGD-TS after naively flattening the $d_{1}$ by $d_{2}$ matrices without using the low-rank structure, and LowESTR [26], which works well for linear low-rank matrix bandits.
+
+We simulate a dataset with $d_{1} = d_{2} = 10$ (12) and $r = 1$ (2): when $r = 1$ , we set the diagonal matrix $\Theta^{*}$ as $\mathrm{diag}(\Theta^{*}) = (0.8, 0, \dots, 0)$ . When $r = 2$ , we set $\Theta^{*} = v_{1}v_{1}^{\top} + v_{2}v_{2}^{\top}$ for two random orthogonal vectors $v_{1}, v_{2}$ with $\| v_{1}\|_{2} = \| v_{2}\|_{2} = 3$ . For arms we draw 480 (1000) random matrices from $\{X \in \mathbb{R}^{d_1\times d_2} : \| X\|_F \leq 1\}$ , and we build a logistic model where the payoff $y_{t}$ is drawn from a Bernoulli distribution with mean $\mu(X_t^\top \theta^*)$ . More details on the hyper-parameter tuning are in Appendix I. Each experiment is repeated 100 times for credibility and the average regret, along with standard deviation, is displayed in Figure 1. Note that our experiments are more comprehensive than those in [26]. And due to the expensive time complexity of UCB-based baselines (Table 2), it is formidable for us to increase $d$ here.
+
+From the plots, we observe that our algorithms G-ESTT and G-ESTS always achieve less regret compared with LowESTR and SGD-TS in all four scenarios consistently. Intriguingly, in the warm-up period SGD-TS incurs less regret compared with our methods due to the sacrifice of random sampling in stage 1, but our proposed framework quickly overtakes SGD-TS after utilizing the low-rank structure as desired. This phenomenon exactly coincides with our theory. Notice that G-ESTT is slightly better than G-ESTS in the case for $r = 2$ especially in the very beginning of stage 2, and we believe it is because that our G-ESTT could reutilize the actions in stage 1 and hence could yield more robust performance when switching to stage 2. However, G-ESTS would gradually catch up with G-ESTT in the long run as expected. Besides, it costs G-ESTS extremely less running time than other existing methods to update the decisions due to its dimensional reduction as shown in Table 2. We also observe that the cumulative regret of G-ESTS tends to become better eventually if we increase $T_{1}$ decently. (Further investigation and plots for 1000 arms are in Appendix I.) Moreover, to pre-check the efficiency of our Stein's lemma-based method for subspace estimation shown in Eqn.
+
+
+(a)
+
+
+(b)
+Figure 1: Plots of regret curves of algorithm G-ESTS, G-ESTT, SGD-TS and LowESTR under four settings (480 arms). (a): diagonal $\Theta^{*}d_{1} = d_{2} = 10, r = 1$ ; (b): diagonal $\Theta^{*}d_{1} = d_{2} = 12, r = 1$ ; (c): non-diagonal $\Theta^{*}d_{1} = d_{2} = 10, r = 2$ ; (d): non-diagonal $\Theta^{*}d_{1} = d_{2} = 12, r = 2$ .
+
+
+(c)
+
+
+(d)
+
+(6), we also tried some other low-rank subspace detection algorithms for comparison. The details are also deferred to Appendix I.4 due to the space limit.
+
+# 6 Conclusion
+
+In this paper, we discussed the generalized linear low-rank matrix bandit problem. We proposed two novel and efficient frameworks called G-ESTT and G-ESTS, and both methods could achieve an improved $\widetilde{O}(dr\sqrt{T})$ bound of regret under some mild conditions, which matches the optimal lower bound of our problem setting up to polylogarithmic terms. The practical superiority of our proposed frameworks is also validated under comprehensive experiments.
+
+There are several directions for our future work. Firstly, although the GLM has achieved tremendous success in various settings, recently some other models [39] that are proved to be powerful were proposed, so we can study these modern frameworks in the low-rank matrix case. Secondly, it seems more reasonable to continuously update the subspace estimation via online SVD over the total time horizon [17] on-the-fly with a randomized strategy. Therefore, we can consider something like arbitrarily choosing an admissible subset of the action set at each round [31] without hurting the regret too much.
+
+# Acknowledgments and Disclosure of Funding
+
+We are grateful for the constructive comments from the anonymous reviewers and area chair. This work was partially supported by the National Science Foundation under grants CCF-1934568, DMS-1811405, DMS-1811661, DMS-1916125, DMS-2113605, DMS-2210388, IIS-2008173, and IIS-2048280. CJH is also supported by Samsung, Google, Sony and the Okawa Foundation.
+
+# References
+
+[1] Yasin Abbasi-Yadkori, David Pál, and Csaba Szepesvári. Improved algorithms for linear stochastic bandits. In NIPS, volume 11, pages 2312-2320, 2011.
+[2] Yasin Abbasi-Yadkori, David Pal, and Csaba Szepesvari. Online-to-confidence-set conversions and application to sparse stochastic bandits. In Artificial Intelligence and Statistics, pages 1-9. PMLR, 2012.
+[3] Jean-Yves Audibert, Rémi Munos, and Csaba Szepesvári. Exploration-exploitation tradeoff using variance estimates in multi-armed bandits. Theoretical Computer Science, 410(19):1876-1902, 2009.
+[4] Hamsa Bastani and Mohsen Bayati. Online decision making with high-dimensional covariates. Operations Research, 68(1):276-294, 2020.
+[5] Emmanuel J Candès and Benjamin Recht. Exact matrix completion via convex optimization. Foundations of Computational mathematics, 9(6):717-772, 2009.
+[6] Kani Chen, Inchi Hu, Zhiliang Ying, et al. Strong consistency of maximum quasi-likelihood estimators in generalized linear models with fixed and adaptive designs. Annals of Statistics, 27(4):1155–1163, 1999.
+
+[7] Louis HY Chen, Larry Goldstein, and Qi-Man Shao. Normal approximation by Stein's method. Springer Science & Business Media, 2010.
+[8] Persi Diaconis, Charles Stein, Susan Holmes, and Gesine Reinert. Use of exchangeable pairs in the analysis of simulations. In Stein's Method, pages 1-25. Institute of Mathematical Statistics, 2004.
+[9] Qin Ding, Cho-Jui Hsieh, and James Sharpnack. An efficient algorithm for generalized linear bandit: Online stochastic gradient descent and thompson sampling. In International Conference on Artificial Intelligence and Statistics, pages 1585-1593. PMLR, 2021.
+[10] Jianqing Fan, Wenyan Gong, and Ziwei Zhu. Generalized high-dimensional trace regression via nuclear norm regularization. Journal of econometrics, 212(1):177-202, 2019.
+[11] Sarah Filippi, Olivier Cappe, Aurélien Garivier, and Csaba Szepesvári. Parametric bandits: The generalized linear case. In NIPS, volume 23, pages 586-594, 2010.
+[12] Aditya Gopalan, Odalric-Ambrym Maillard, and Mohammadi Zaki. Low-rank bandits with latent mixtures. arXiv preprint arXiv:1609.01508, 2016.
+[13] Botao Hao, Jie Zhou, Zheng Wen, and Will Wei Sun. Low-rank tensor bandits. arXiv preprint arXiv:2007.15788, 2020.
+[14] Prateek Jain and Inderjit S Dhillon. Provable inductive matrix completion. arXiv preprint arXiv:1306.0626, 2013.
+[15] Kyoungseok Jang, Kwang-Sung Jun, Se-Young Yun, and Wanmo Kang. Improved regret bounds of bilinear bandits using action space analysis. In International Conference on Machine Learning, pages 4744–4754. PMLR, 2021.
+[16] Nicholas Johnson, Vidyashankar Sivakumar, and Arindam Banerjee. Structured stochastic linear bandits. arXiv preprint arXiv:1606.05693, 2016.
+[17] Kwang-Sung Jun, Rebecca Willett, Stephen Wright, and Robert Nowak. Bilinear bandits with low-rank structure. In International Conference on Machine Learning, pages 3163-3172. PMLR, 2019.
+[18] Sumeet Katariya, Branislav Kveton, Csaba Szepesvári, Claire Vernade, and Zheng Wen. Bernoulli rank-1 bandits for click feedback. arXiv preprint arXiv:1703.06513, 2017.
+[19] Sumeet Katariya, Branislav Kveton, Csaba Szepesvari, Claire Vernade, and Zheng Wen. Stochastic rank-1 bandits. In Artificial Intelligence and Statistics, pages 392–401. PMLR, 2017.
+[20] Branislav Kveton, Csaba Szepesvári, Anup Rao, Zheng Wen, Yasin Abbasi-Yadkori, and S Muthukrishnan. Stochastic low-rank bandits. arXiv preprint arXiv:1712.04644, 2017.
+[21] Tor Lattimore and Csaba Szepesvári. Bandit algorithms. Cambridge University Press, 2020.
+[22] Lihong Li, Wei Chu, John Langford, and Robert E Schapire. A contextual-bandit approach to personalized news article recommendation. In Proceedings of the 19th international conference on World wide web, pages 661-670, 2010.
+[23] Lihong Li, Yu Lu, and Dengyong Zhou. Provably optimal algorithms for generalized linear contextual bandits. In International Conference on Machine Learning, pages 2071-2080. PMLR, 2017.
+[24] Wenjie Li, A darsh Barik, and Jean Honorio. A simple unified framework for high dimensional bandit problems. arXiv preprint arXiv:2102.09626, 2021.
+[25] Xiuyuan Lu, Zheng Wen, and Branislav Kveton. Efficient online recommendation via low-rank ensemble sampling. In Proceedings of the 12th ACM Conference on Recommender Systems, pages 460-464, 2018.
+
+[26] Yangyi Lu, Amirhossein Meisami, and Ambuj Tewari. Low-rank generalized linear bandit problems. In International Conference on Artificial Intelligence and Statistics, pages 460-468. PMLR, 2021.
+[27] Stanislav Minskler. Sub-gaussian estimators of the mean of a random matrix with heavy-tailed entries. The Annals of Statistics, 46(6A):2871-2903, 2018.
+[28] Sahand N Negahban, Pradeep Ravikumar, Martin J Wainwright, Bin Yu, et al. A unified framework for high-dimensional analysis of $m$ -estimators with decomposable regularizers. Statistical science, 27(4):538-557, 2012.
+[29] Yaniv Plan and Roman Vershynin. The generalized lasso with non-linear observations. IEEE Transactions on information theory, 62(3):1528-1537, 2016.
+[30] Garvesh Raskutti, Martin J Wainwright, and Bin Yu. Restricted eigenvalue properties for correlated gaussian designs. The Journal of Machine Learning Research, 11:2241-2259, 2010.
+[31] Candice Schumann, Zhi Lang, Nicholas Mattei, and John P Dickerson. Group fairness in bandit arm selection. arXiv preprint arXiv:1912.03802, 2019.
+[32] Gilbert W Stewart. Matrix perturbation theory. 1990.
+[33] Cindy Trinh, Emilie Kaufmann, Claire Vernade, and Richard Combes. Solving bernoulli rank-one bandits with unimodal thompson sampling. In Algorithmic Learning Theory, pages 862-889. PMLR, 2020.
+[34] Laurens Van Der Maaten, Eric Postma, Jaap Van den Herik, et al. Dimensionality reduction: a comparative. J Mach Learn Res, 10(66-71):13, 2009.
+[35] Martin J Wainwright. High-dimensional statistics: A non-asymptotic viewpoint, volume 48. Cambridge University Press, 2019.
+[36] Michael Woodrooe. A one-armed bandit problem with a concomitant variable. Journal of the American Statistical Association, 74(368):799–806, 1979.
+[37] Zhuoran Yang, Krishnakumar Balasubramanian, and Han Liu. High-dimensional non-gaussian single index models via thresholded score function estimation. In International Conference on Machine Learning, pages 3851-3860. PMLR, 2017.
+[38] Kai Zhong, Prateek Jain, and Inderjit S Dhillon. Efficient matrix sensing using rank-1 gaussian measurements. In International conference on algorithmic learning theory, pages 3–18. Springer, 2015.
+[39] Dongruo Zhou, Lihong Li, and Quanquan Gu. Neural contextual bandits with ucb-based exploration. In International Conference on Machine Learning, pages 11492-11502. PMLR, 2020.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] We discuss the limitation of our first algorithm G-ESTT in the beginning of Subsection 4.2.
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [N/A]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [Yes]
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/images.zip b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..22f66631460f59998fccfb40a2170a75da84bb83
--- /dev/null
+++ b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:300eba5e0d33c23f07a66cb95850cb11965aac1e730f5ec6734fa222dfa0b0cf
+size 285302
diff --git a/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/layout.json b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..3512ca2d7ce3359fff7bf6f9d3e4dd2965e131f1
--- /dev/null
+++ b/efficientframeworksforgeneralizedlowrankmatrixbanditproblems/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:19b24150e757be12418c346d83523514a334550c1b55d0f49e7988382c8fc296
+size 634896
diff --git a/efficientgraphsimilaritycomputationwithalignmentregularization/df312615-f113-4f2c-bad1-349271b1837e_content_list.json b/efficientgraphsimilaritycomputationwithalignmentregularization/df312615-f113-4f2c-bad1-349271b1837e_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..6c3743f69065d89663a74149ce70428364c91987
--- /dev/null
+++ b/efficientgraphsimilaritycomputationwithalignmentregularization/df312615-f113-4f2c-bad1-349271b1837e_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bf6c1c33da607ff35e0f01c08fbf630c43f7ea2e69ba3ff43026a5da87fb10c3
+size 82228
diff --git a/efficientgraphsimilaritycomputationwithalignmentregularization/df312615-f113-4f2c-bad1-349271b1837e_model.json b/efficientgraphsimilaritycomputationwithalignmentregularization/df312615-f113-4f2c-bad1-349271b1837e_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..96455daab6671cb8dce457f9fa588c9006069e93
--- /dev/null
+++ b/efficientgraphsimilaritycomputationwithalignmentregularization/df312615-f113-4f2c-bad1-349271b1837e_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:59d3696063661a2c6b1899d07f0b523ad137d3681936a1bbc786d161237c58d7
+size 100729
diff --git a/efficientgraphsimilaritycomputationwithalignmentregularization/df312615-f113-4f2c-bad1-349271b1837e_origin.pdf b/efficientgraphsimilaritycomputationwithalignmentregularization/df312615-f113-4f2c-bad1-349271b1837e_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..572949f75b8e3b32a9edcf95fb573ee9e0dd8777
--- /dev/null
+++ b/efficientgraphsimilaritycomputationwithalignmentregularization/df312615-f113-4f2c-bad1-349271b1837e_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:cdca0abd4459fab03e49c063a5a7eaa5263ffba73e7d4d465c2deb5c6d7bc42a
+size 3682435
diff --git a/efficientgraphsimilaritycomputationwithalignmentregularization/full.md b/efficientgraphsimilaritycomputationwithalignmentregularization/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..4b45f8b6d709a8919596af12f074e4024efa719c
--- /dev/null
+++ b/efficientgraphsimilaritycomputationwithalignmentregularization/full.md
@@ -0,0 +1,308 @@
+# Efficient Graph Similarity Computation with Alignment Regularization
+
+Wei Zhuo
+
+Shenzhen Campus of Sun Yat-sen University
+
+zhuow5@mail2.sysu.edu.cn
+
+Guang Tan
+
+Shenzhen Campus of Sun Yat-sen University
+
+tanguang@mail.sysu.edu.cn
+
+# Abstract
+
+We consider the graph similarity computation (GSC) task based on graph edit distance (GED) estimation. State-of-the-art methods treat GSC as a learning-based prediction task using Graph Neural Networks (GNNs). To capture fine-grained interactions between pair-wise graphs, these methods mostly contain a node-level matching module in the end-to-end learning pipeline, which causes high computational costs in both the training and inference stages. We show that the expensive node-to-node matching module is not necessary for GSC, and high-quality learning can be attained with a simple yet powerful regularization technique, which we call the Alignment Regularization (AReg). In the training stage, the AReg term imposes a node-graph correspondence constraint on the GNN encoder. In the inference stage, the graph-level representations learned by the GNN encoder are directly used to compute the similarity score without using AReg again to speed up inference. We further propose a multi-scale GED discriminator to enhance the expressive ability of the learned representations. Extensive experiments on real-world datasets demonstrate the effectiveness, efficiency and transferability of our approach.
+
+# 1 Introduction
+
+Graph similarity computation (GSC) is a fundamental task in graph databases and plays a critical role in many real-world applications, including drug design [14, 28], program analysis [16], and social group identification [21, 27]. For example, one can search a drug database for a query chemical compound, in order to identify drugs with high similarity in structures or attributes and thus similar curative effects as desired [23]. To measure the similarity between pair-wise graphs, Graph Edit Distance (GED) [5] has been a major metric due to its generality, and many other graph similarity measures have been proven to be its special cases [17]. Unfortunately, computing exact GED is an NP-hard problem in general [12].
+
+With the provably expressive power in distinguishing graph structures [32, 19, 7, 34], Graph Neural Networks (GNNs) have been adopted for GED approximation and shown to achieve superior performance on accuracy. Most state-of-the-art GNN-based GSC models [1, 3, 8, 18, 16] contain two sequential submodules in the end-to-end learnable pipeline (left of Fig. 1): (1) a GNN encoder, which is shared across two graphs to embed nodes into representation vectors to capture the intra-graph structure and feature information; (2) a matching model, which computes cross-graph node-level similarity, i.e., how a node in one graph relates to all the nodes in the other graph. The model outputs a summarized vector that fuses the node-level similarities between two graphs. Then, the similarity score is predicted based on the summarized vector via a regression head. The computational cost of such a sequential framework mainly comes from the matching model, which requires computational and memory cost quadratic in the number of nodes and sometimes involves additional parameters such as attention weights [18, 16], leading to heavy time consumption in both the training and inference
+
+stages. Especially in the inference stage, we need to query every testing graph from the database. The recent approach EGSC [22] speeds up the similarity learning by dropping the matching model from SimGNN [1]. However, since cross-graph node-level interactions are ignored, EGSC cannot capture finer-grained similarity information, and thus results in suboptimal prediction performance. To overcome the intrinsic tension between predictive accuracy and speed, we propose a separated neural structure (right of Fig. 1) that detaches the matching model from the sequential pipeline, where the matching model only acts as a regularization term in the training stage to help the GNN encoder capture fine-grained similarity information, while in the inference (testing) stage, since the latent cross-graph interactions have been learned by the GNN encoder, the final similarity score can be directly computed based on the output representations of the GNN encoder without invoking the matching model again.
+
+We show that explicitly learning the cross-graph node-to-node similarity is unnecessary, as the correlation information contained in the features and graph topology, when properly exploited, is sufficient to reflect such cross-graph interactions (see Section 3). Specifically, the problem of GED computation is equivalent to finding an optimal permutation such that the adjacency matrices of the two graphs can be best aligned. Hence, by analyzing the necessary conditions under the optimal permutation, we find that the best matching between two graphs can be inferred by minimizing the difference between the intra-graph node-graph similarity and cross-graph node-graph similarity. It motivates us to design a task-agnostic matching model based on the input data itself, with a novel regularization technique, called the Alignment
+
+
+Figure 1: Illustration of separating the matching model from the end-to-end GSC framework to achieve a fast model (right side). In the fast model, the dotted arrow means the matching model does not participate in the similarity computation in the inference stage.
+
+Regularization (AReg). AReg obviates the need of a matching model in the inference stage, thus making the model more efficient. AReg is also model-agnostic and can be applied to other GNN-based GSC models.
+
+On the other hand, GNN-based GSC models usually use a single GED discriminator followed by a regression head to fuse graph representations from pair-wise input graphs and output a final similarity prediction score. We show that a single GED discriminator does not fully capture the dissimilarity between two graphs, while diverse discriminators may provide complementary information to reflect GED more accurately. Thus, we propose a multi-scale GED discriminator to improve the discriminability of the learned representations. We call the overall framework ERIC: Efficient gRaph sImolarity Computation, and conduct extensive experiments to verify the efficacy of our design. Results on several real-world datasets demonstrate that ERIC achieves state-of-the-art performance by significantly outperforming the baselines.
+
+# 2 Preliminary
+
+Problem Formulation of GSC. Given a graph database $\mathcal{D}$ and a set of query graphs $\mathcal{Q}$ , the problem of graph similarity computation is to produce a similarity score $\pmb{y}$ between $\forall G_i \in \mathcal{Q}$ and $\forall G_j \in \mathcal{D}$ , i.e., $\pmb{y} = s(G_i, G_j)$ where $s: \mathcal{D} \times \mathcal{Q} \to \mathbb{R}^{(0,1]}$ is a similarity estimator. A graph $G \in \mathcal{D} \cup \mathcal{Q}$ is defined as $G = (V, E)$ , where $V = \{v_k\}_{k=1}^N$ is a node set and $E \in V \times V$ is an edge set. In our setting, all the accessible graphs are unweighted and undirected. $V$ and $E$ jointly formulate an adjacency matrix $\pmb{A} \in \mathbb{R}^{N \times N}$ . If nodes are accompanied by features (e.g., labels or attribute vectors), they are represented as $\pmb{X} \in \mathbb{R}^{N \times d}$ with dimension $d$ .
+
+Graph Edit Distance (GED). GED as a graph similarity measure has been popularly adopted on graph search queries, due to its capacity to capture the structural and feature differences between graphs. As shown in Fig. 2, GED is defined as the number of edit operations in the optimal path that transforms $G_{i}$ into $G_{j}$ , where the possible edit operations under consideration include edge
+
+deletion/insertion, node deletion $^1$ /insertion, and node relabeling. To well fit the end-to-end regression task, instead of directly estimating the GED between two graphs, we convert the GED to the ground truth similarity score that the learning model aims to approximate. Following [1], the normalized GED is defined as $\mathrm{nGED}(G_i,G_j) = \frac{\mathrm{GED}(G_i,G_j)}{(|V_i| + |V_j|) / 2}$ , and the ground truth similarity score between $G_{i}$ and $G_{j}$ is defined as the normalized exponential of GED, resulting in a value ranging (0, 1], i.e., $\mathbf{S}_{ij} = \exp (-\mathrm{nGED}(G_i,G_j))$
+
+
+Figure 2: The optimal edit path with 3 edit operations to transform $G_{i}$ to $G_{j}$ . As a result, $\mathrm{GED}(G_i, G_j) = 3$ .
+
+# 3 Motivation: Analyzing GED in Embedding Space
+
+Given two graphs $G_{i} = (A_{i},X_{i})$ and $G_{j} = (A_{j},X_{j})$ with the same number of nodes $N$ (If they have different numbers of nodes, pad the smaller $A$ and $X$ with zeros to make the two graphs equal in size), $\pi (\cdot)$ is a node index permutation that preserves the adjacency matrix. $\pi (A)$ denotes the adjacency matrix after node index permuting. We divide the computation of GED between $G_{i}$ and $G_{j}$ into two steps: (i) finding a permutation for $G_{j}$ , such that
+
+$$
+c = \min _ {\pi} \sum_ {k, l} | (\boldsymbol {A} _ {i} - \pi (\boldsymbol {A} _ {j})) [ k, l ] |, \tag {1}
+$$
+
+where $c$ is the sum of the absolute values of all elements in matrix $\mathbf{A}_i - \pi (\mathbf{A}_j)$ . We denote the optimal permutation satisfying Eq. (1) as $\pi^{\star}$ . (ii) counting the number of cross-graph node pairs with the same indices yet different features, denoted as $m$ . Then $\mathrm{GED}(G_i,G_j) = \frac{c}{2} +m$ . Obviously, if two graphs are topologically isomorphic, there exists $\pi = \pi^{\star}$ such that $\mathbf{A}_i = \pi^{\star}(\mathbf{A}_j)$ , i.e., $c = 0$ . Hence the GED is only determined by distinct features. For another example, when the node permutation $\pi$ assigns indices to $G_{j}$ as shown in Fig. 2, the structure of $G_{i}$ and $G_{j}$ can be best aligned, i.e., $c = 4$ . Then, only one pair of nodes with the same index across graphs have different features (e.g., node 4). Thus, $\mathrm{GED}(G_i,G_j) = 3$ . The core of this two-step method is finding the optimal permutation to best align two graphs, then $m$ is determined under such alignment. Traversing all possible permutations to find $\pi^{\star}$ is also NP-hard, so we make some heuristic rules from Eq. (1) to guide the model design. Under the optimal permutation $\pi^{\star}$ , the row similarity between $\mathbf{A}_i$ and $\pi^{\star}(\mathbf{A}_{j})$ is maximized, so given an injective function $f_{\theta}(\cdot):\mathbb{R}^{N}\to \mathbb{R}^{d}$ parameterized by $\theta$ to guarantee that nodes with different connectivity can be distinguished, a necessary condition is that the distance between $f_{\theta}(\mathbf{A}_i[k])$ and $f_{\theta}(\pi^{\star}(\mathbf{A}_j)[k])$ is minimized for all $k\in \{1,\dots ,N\}$ . From a global view, the matrix similarity between $\mathbf{A}_i$ and $\pi^{\star}(\mathbf{A}_{j})$ is also maximized. Given an injective function $g_{\phi}(\cdot):\mathbb{R}^{N\times N}\to \mathbb{R}^{d}$ parameterized by $\phi$ , another necessary condition under the optimal permutation is that the distance between $g_{\phi}(\mathbf{A}_i)$ and $g_{\phi}(\pi^{\star}(\mathbf{A}_{j}))$ is minimized. Thus, the optimal permutation $\pi^{\star}$ in Eq. (1) also satisfies the following function,
+
+$$
+\pi^ {\star} = \arg \min _ {\pi} \operatorname {D I S T} \left(f _ {\theta} \left(\boldsymbol {A} _ {i} [ k ]\right), f _ {\theta} \left(\pi \left(\boldsymbol {A} _ {j}\right) [ k ]\right)\right) + \operatorname {D I S T} \left(g _ {\phi} \left(\boldsymbol {A} _ {i}\right), g _ {\phi} \left(\pi \left(\boldsymbol {A} _ {j}\right)\right)\right) \quad \forall k \in \{1, \dots , N \}, \tag {2}
+$$
+
+where $\mathrm{DIST}(\cdot ,\cdot)$ is a distance metric. The two terms in Eq. (2) can reflect GED at node-level and global-level respectively. Further, we regard $\{f_{\theta}(\pmb {A}_i[k])\}_{k = 1}^N\cup \{f_{\theta}(\pi^\star (\pmb {A}_j)[k])\}_{k = 1}^N$ as $2N$ anchors and assume $N\gg d$ . When the second term of Eq. (2) reaches a minimum, it indicates that $g_{\phi}(\pmb {A}_i)$ and $g_{\phi}(\pi^{\star}(\pmb {A}_j))$ have similar distances to all anchors, i.e., the following $\gamma_{i}$ and $\gamma_{j}$ take the minimum value when $\pi = \pi^{\star}$ ,
+
+$$
+\gamma_ {i} = \sum_ {k} ^ {N} \| \operatorname {D I S T} \left(f _ {\theta} \left(\boldsymbol {A} _ {i} [ k ]\right), g _ {\phi} \left(\boldsymbol {A} _ {i}\right)\right) - \operatorname {D I S T} \left(f _ {\theta} \left(\boldsymbol {A} _ {i} [ k ]\right), g _ {\phi} \left(\pi \left(\boldsymbol {A} _ {j}\right)\right)\right) \| _ {2} \tag {3}
+$$
+
+
+Figure 3: Overview of ERIC. The GNN encoder is shared across two graphs. The green lines denote AReg. The summarized graph representations $\widehat{\pmb{Z}}_i$ and $\widehat{\pmb{Z}}_j$ are combinations of graph representations learned in each layer, which are fed into the GED discriminator followed by a regression function to obtain the prediction value. In the inference stage, the AReg submodule is removed.
+
+$$
+\gamma_ {j} = \sum_ {k} ^ {N} \| \operatorname {D I S T} \left(f _ {\theta} \left(\pi \left(\boldsymbol {A} _ {j}\right) [ k ]\right), g _ {\phi} \left(\boldsymbol {A} _ {i}\right)\right) - \operatorname {D I S T} \left(f _ {\theta} \left(\pi \left(\boldsymbol {A} _ {j}\right) [ k ]\right), g _ {\phi} \left(\pi \left(\boldsymbol {A} _ {j}\right)\right)\right) \| _ {2}. \tag {4}
+$$
+
+On the other hand, the first term of Eq. (2) is a finer-grained alignment between two graphs, and $\pi^{\star}$ causes the first term of Eq. (2) to reach a minimum. Since the only difference between $\gamma_{i}$ and $\gamma_{j}$ is that $\gamma_{j}$ replaces $f_{\theta}(\pmb{A}_i[k])$ in $\gamma_{i}$ with $f_{\theta}(\pi (\pmb{A}_j)[k])$ , the distance between $f_{\theta}(\pmb{A}_i[k])$ and $f_{\theta}(\pi (\pmb{A}_j)[k])$ can be reflected by the difference between $\gamma_{i}$ and $\gamma_{j}$ , i.e., $\| \gamma_{i} - \gamma_{j}\|_{2}$ . Hence, under the optimal permutation $\pi = \pi^{\star}$ , $G_{i}$ and $G_{j}$ are best aligned, and so Eq. (2) is established, which is equivalent to $\gamma_{i},\gamma_{j}$ , and $\| \gamma_i - \gamma_j\| _2$ all taking the minimum values. These terms reflect similarities between pair-wise graphs at both node- and graph- levels, which can be inferred from the graph structure itself without consulting the ground-truth GEDs. It motivates us to separate the matching model from the end-to-end pipeline. In other words, instead of directly searching the optimal permutation $\pi^{\star}$ , we derive the necessary conditions under $\pi^{\star}$ , which impose additional constraints on the coordinates of nodes in the embedding space. These conditions are not necessarily sufficient, nevertheless they can provide useful knowledge for the model to learn representations that are better tailored to the GSC task. In Appendix A, we further analyze the rationality of this approximation by analyzing the sufficiency of these conditions. Assuming $g_{\phi}$ is a permutation-invariant function, then all permutation operators in Eq. (3) and Eq. (4) can be removed. Moreover, instead of computing cross-graph node-to-node similarity to compute a 'soft' alignment as done in most related work, $\gamma_{i}$ and $\gamma_{j}$ only compute node-to-graph similarity, which is more efficient.
+
+# 4 Proposed Model: ERIC
+
+The proposed ERIC framework mainly consists of two submodules: the Alignment Regularization (AReg) module and the Multi-Scale GED Discriminator, as depicted in Fig. 3. AReg aims to train the shared GNN encoder to enable the GNN to capture underlying alignment information between pair-wise graphs. The multi-scale GED discriminator trains the same GNN encoder so that the learned representations of two graphs can accurately reflect the GED. Such a paradigm follows the intuition of the GED definition that when two graphs are best aligned, the difference between them is the GED.
+
+# 4.1 Alignment Regularization
+
+Learning the optimal alignment between graphs is crucial for GED estimation, however, most existing GSC models rely on intricate cross-graph node-to-node similarity computation to learn a 'soft' alignment. Furthermore, learning node-to-node similarity inevitably yields a dense similarity matrix, which could introduce more noise. To address this issue, we introduce Alignment Regularization (AReg) as a part of our framework. AReg is a model- and task-agnostic regularization term, which can easily be combined with existing embedding-based GSC models in a plug-and-play manner. The design of AReg is motivated by the analysis of GED in Section 3. Recall that GED is the difference between two graphs when they are best aligned under the optimal permutation $\pi^{\star}$ , whose necessary conditions are that $\gamma_{i},\gamma_{j}$ as well as $\| \gamma_i - \gamma_j\| _2$ take the minimum values. Thus, we expect that the learning-based model can couple with the nature of GED as much as possible, i.e., the
+
+
+(a) NTN
+
+
+(b) $\ell_2$ distance
+Figure 4: t-SNE [29] visualization of the IMDB dataset. Each point is a graph encoded by the GNN encoder of ERIC. The green cross means a randomly sampled query graph; red points mean the top $50\%$ of graph datasets that are most similar to the query graph based on ground-truth GEDs; blue points mean the remaining $50\%$ graphs in the dataset. (a): Using NTN as the discriminator, many similar graphs do not cluster together around the query graph even if each cluster is tight. (b): Using $\ell_2$ distance as the discriminator, different clusters are separated clearly but the query graph is close to the cluster boundary; in addition each cluster is dispersive. (c): By adaptively combining NTN and $\ell_2$ distance, our model makes similar graphs closely located around the query, while dissimilar graphs are far away from the query.
+
+
+(c) $\mathrm{NTN} + \ell_{2}$ distance
+
+GNN encoder can preserve the best alignment, in which case the difference between the learned graph representations can reflect the GED. To that end, we design the model based on the necessary conditions under $\pi^{\star}$ . Specifically, based on Eq. (3) and Eq. (4), we instantiate $f_{\theta}(\cdot)$ as the $L$ -layer Graph Isomorphism Network (GIN) [32], then at the $\ell$ -th layer $f_{\theta}^{(\ell)}(A_i[k])$ can be represented as:
+
+$$
+\boldsymbol {H} _ {i} ^ {(\ell)} [ k ] = f _ {\theta} ^ {(\ell)} \left(\boldsymbol {A} _ {i} [ k ]\right) = \operatorname {M L P} _ {\theta} ^ {(\ell)} \left((1 + \xi^ {(\ell)}) \boldsymbol {H} _ {i} ^ {(\ell - 1)} [ k ] + \boldsymbol {A} _ {i} [ k ] \boldsymbol {H} _ {i} ^ {(\ell - 1)}\right), \tag {5}
+$$
+
+where $\xi^{(\ell)}$ is a learnable parameter, $H_{i}^{(\ell)}\in \mathbb{R}^{N\times d^{(\ell)}}$ is the feature matrix of $G_{i}$ at the $\ell$ -th layer where $d^{(\ell)}$ denotes the feature dimension, $H_{i}^{(0)} = X_{i}$ . On the other hand, AReg implements the readout function $g_{\phi}$ with a one-layer permutation-invariant DeepSets [33] to guarantee injectiveness, taking the form:
+
+$$
+\boldsymbol {Z} _ {i} ^ {(\ell)} = g _ {\phi} ^ {(\ell)} (\boldsymbol {A} _ {i}) = \operatorname {M L P} _ {\phi} ^ {(\ell)} \left(\sum_ {k} ^ {N} f _ {\theta} ^ {(\ell)} (\boldsymbol {A} _ {i} [ k ])\right), \tag {6}
+$$
+
+where $\mathrm{MLP}_{\phi}^{(\ell)}$ and $\mathrm{MLP}_{\theta}^{(\ell)}$ have the same output dimension $d_{\mathrm{MLP}}^{(\ell)}$ . Since $g_{\phi}(\mathbf{A}_j) = g_{\phi}(\pi^{\star}(\mathbf{A}_j))$ , and $\gamma_{i}$ and $\gamma_{j}$ are sums over all $N$ nodes, hence they are permutation-invariant and we can remove all operation $\pi (\cdot)$ in Eq. (3) and Eq. (4). $\mathrm{DIST}(\cdot ,\cdot)$ can be defined as any distance metrics such as cosine similarity. Let $\gamma_i^{(\ell)}$ and $\gamma_j^{(\ell)}$ be the value of Eq. (3) and Eq. (4) at the $\ell$ -th layer, by considering multi-scale cross-graph interactions, AReg is represented as $\mathcal{L}_{\mathrm{AReg}}$ where:
+
+$$
+\mathcal {L} _ {\mathrm {A R e g}} = \frac {1}{L} \sum_ {\ell} ^ {L} \left(\gamma_ {i} ^ {(\ell)} + \gamma_ {j} ^ {(\ell)} + \left\| \gamma_ {i} ^ {(\ell)} - \gamma_ {j} ^ {(\ell)} \right\| _ {2}\right). \tag {7}
+$$
+
+Since $\gamma_{i}$ and $\gamma_{j}$ induced from Eq. (2) integrate graph-level alignment and finer-grained node-level alignment, $\mathcal{L}_{\mathrm{AReg}}$ therefore preserves underlying cross-graph interactions without computing complicated node-to-node similarity, also making the training stage more efficient.
+
+# 4.2 Multi-Scale GED Discriminator
+
+Now we have $L$ graph-level representations for $G_{i}$ and $G_{j}$ respectively, denoted as $\{\mathbf{Z}_i^{(1)},\dots ,\mathbf{Z}_i^{(L)}\}$ and $\{\mathbf{Z}_j^{(1)},\dots ,\mathbf{Z}_j^{(L)}\}$ . We concatenate the layer-wise graph representations for $G$ as: $\widehat{\pmb{Z}} = \bigoplus \left\{\pmb {Z}^{(\ell)}\right\}_{\ell = 1}^{L}$ , where $\bigoplus$ denotes the concatenation operator along the last dimension to combine the graph representation in each layer, i.e., $\widehat{\pmb{Z}}_i,\widehat{\pmb{Z}}_j\in \mathbb{R}^{d_{\mathrm{ms}}}$ , and $d_{\mathrm{ms}} = \sum_{\ell}d_{\mathrm{MLP}}^{(\ell)}$ . Then they are fed into a GED discriminator that generates score vectors as GED similarity embedding for the graph pair. Neural Tensor Network (NTN) [26] has demonstrated strong power to model the relation between the
+
+graph-level embeddings of two graphs [1, 22, 30] thanks to its capacity of exploring the element-wise dependence among the features. However, directly using NTN as the discriminator may be expensive when the dimension of $\widehat{\mathbf{Z}}_i$ and $\widehat{\mathbf{Z}}_j$ is high. Thus, we decompose the weight matrix $\mathbf{W}^t\in \mathbb{R}^{d_{\mathrm{ms}}\times d_{\mathrm{ms}}}$ into two matrices $\mathbf{W}_1^t\in \mathbb{R}^{d_{\mathrm{ms}}\times d'}$ and $\mathbf{W}_2^t\in \mathbb{R}^{d'\times d_{\mathrm{ms}}}$ where $d^{\prime}\ll d_{\mathrm{ms}}$ to reduce the number of parameters. Then NTN with decomposed weight matrices is used to measure the similarity between $\widehat{\mathbf{Z}}_i$ and $\widehat{\mathbf{Z}}_j$ :
+
+$$
+s _ {\mathrm {N T N}} \left(G _ {i}, G _ {j}\right) = \delta_ {\mathrm {N T N}} \left(\left[ \left(\widehat {\boldsymbol {Z}} _ {i} \mathbf {W} _ {1} ^ {t}\right) \left(\mathbf {W} _ {2} ^ {t} \widehat {\boldsymbol {Z}} _ {j} ^ {\top}\right): t \in \{1, \dots , T \} \right] ^ {\top} + \mathbf {W} _ {3} \bigoplus \left\{\widehat {\boldsymbol {Z}} _ {i}, \widehat {\boldsymbol {Z}} _ {j} \right\} + \mathbf {b}\right), \tag {8}
+$$
+
+where $\mathbf{W}_1\in \mathbb{R}^{d_{\mathrm{ms}}\times d'\times T}$ , $\mathbf{W}_2\in \mathbb{R}^{d'\times d_{\mathrm{ms}}\times T}$ , $\mathbf{W}_3\in \mathbb{R}^{T\times 2d_{\mathrm{ms}}}$ , and $\mathbf{b}\in \mathbb{R}^T$ are learnable; $T$ is a hyper-parameter controlling the output dimension, which is assigned as 16 for all datasets in our settings. [·] in Eq. (8) means computing $(\widehat{\pmb{Z}}_i\mathbf{W}_1^t)(\mathbf{W}_2^t\widehat{\pmb{Z}}_j^\top)$ for all $t\in \{1,\dots ,T\}$ and stacking them as a $T$ -dimensional tensor. $\delta_{\mathrm{NTN}}:\mathbb{R}^T\to \mathbb{R}^{(0,1]}$ is a fully-connected neural network with Sigmoid activation as a regression function to project the similarity score vector to the final predicted similarity value. NTN is an expressive and general similarity discriminator because it can approximate many similarity measures. The first term of Eq. (8) can be regarded as a multi-head weighted cosine similarity function. It can also approximate kernel similarity between $\widehat{\pmb{Z}}_i$ and $\widehat{\pmb{Z}}_j$ according to the universal approximation theorem [13]. The second term captures the residual knowledge. However, it is difficult for NTN to approximate high-order Minkowski distance between $\widehat{\pmb{Z}}_i$ and $\widehat{\pmb{Z}}_j$ , while diverse similarity discriminators may provide complementary information to reflect GED more accurately as shown in Fig. 4. Hence, we consider an additional similarity discriminator based on exponential $p$ -order Minkowski distance:
+
+$$
+s _ {p} \left(G _ {i}, G _ {j}\right) = \delta_ {p} \left(\exp \left(- \left\| \widehat {\boldsymbol {Z}} _ {i} - \widehat {\boldsymbol {Z}} _ {j} \right\| _ {p}\right)\right), \tag {9}
+$$
+
+where $\delta_p: \mathbb{R}^{d_{\mathrm{ms}}} \to \mathbb{R}^{(0,1]}$ is also a fully-connected neural network with Sigmoid activation. For simplicity, we uniformly set $p = 2$ (i.e., $\ell_2$ distance) for all datasets, and analyze the sensitivity of the hyper-parameter $p$ in Section 5.4. After two similarity scores $s_{\mathrm{NTN}}(G_i, G_j)$ and $s_p(G_i, G_j)$ are obtained, the final estimated similarity score is given by:
+
+$$
+s \left(G _ {i}, G _ {j}\right) = \alpha s _ {\mathrm {N T N}} \left(G _ {i}, G _ {j}\right) + \beta s _ {p} \left(G _ {i}, G _ {j}\right), \tag {10}
+$$
+
+where $\alpha$ and $\beta$ are trainable scalars denoting the weights of two similarity discriminators respectively. Given a graph database $\mathcal{D}$ , the GED discriminator is trained on a set of $n$ training pairs $(G_i, G_j) \in \mathcal{D} \times \mathcal{D}$ . The predicted similarity is compared against the ground-truth similarity $\mathbf{S}_{ij}$ based on GEDs with Mean Squared Error (MSE) loss function as:
+
+$$
+\mathcal {L} _ {\mathrm {G E D}} = \frac {1}{n} \sum_ {(G _ {i}, G _ {j}) \in \mathcal {D} \times \mathcal {D}} \operatorname {M S E} (s (G _ {i}, G _ {j}), \mathbf {S} _ {i j}). \tag {11}
+$$
+
+Model training: Combining AReg and GED discriminator, the training stage aims to minimize the following overall objective function $\mathcal{L} = \mathcal{L}_{\mathrm{GED}} + \lambda \mathcal{L}_{\mathrm{AReg}}$ , where $\lambda$ is an adjustable hyper-parameter controlling the strength of the regularization term.
+
+Model inference: Given a set of query graphs $\mathcal{Q}$ and a graph database $\mathcal{D}$ , in the testing stage, all pairs of graphs $(G_i, G_j) \in \mathcal{Q} \times \mathcal{D}$ are fed into ERIC, and directly computing a similarity score for each pair based on Eq. (10) without any node-level interactions.
+
+**Complexity:** The time complexity of GIN in AReg is $O(m)$ [31] where $m$ is the number of edges. The cross-graph node-graph interactions have complexity $O(\max(N_i, N_j))$ . The time complexity of the GED discriminator is $O(d_{\mathrm{ms}}d'T)$ . Thus the complexity of ERIC is $O(m + \max(N_i, N_j) + d_{\mathrm{ms}}d'T)$ in the training stage, while in the inference stage the complexity is $O(m + d_{\mathrm{ms}}d'T)$ .
+
+# 5 Experiments
+
+In this section, we empirically evaluate ERIC on the graph similarity computation task.
+
+Table 1: Evaluation on benchmarks. Bold : best.
+
+ | AIDS700 | LINUX | IMDB | NCI109 |
| mse\( (×10^{-3}) \)↓ | \( \rho \uparrow \) | \( \tau \uparrow \) | \( p@10 \)↑ | \( p@20 \)↑ | mse\( (×10^{-3}) \)↓ | \( \rho \uparrow \) | \( \tau \uparrow \) | \( p@10 \)↑ | \( p@20 \)↑ | mse\( (×10^{-3}) \)↓ | \( \rho \uparrow \) | \( \tau \uparrow \) | \( p@10 \)↑ | \( p@20 \)↑ | mse\( (×10^{-3}) \)↓ | \( \rho \uparrow \) | \( \tau \uparrow \) | \( p@10 \)↑ | \( p@20 \)↑ |
| Beam | 12,090 | 0.609 | 0.463 | 0.481 | 0.493 | 9.268 | 0.827 | 0.714 | 0.973 | 0.924 | - | - | - | - | - | - | - | - | - | - |
| VI | 29,157 | 0.517 | 0.383 | 0.310 | 0.345 | 63.86 | 0.581 | 0.450 | 0.287 | 0.251 | - | - | - | - | - | - | - | - | - | - |
| Hungarian | 25,296 | 0.510 | 0.378 | 0.360 | 0.392 | 29.81 | 0.638 | 0.517 | 0.913 | 0.836 | - | - | - | - | - | - | - | - | - | - |
| SimGNN | 1,573 | 0.835 | 0.678 | 0.417 | 0.489 | 2.479 | 0.912 | 0.791 | 0.635 | 0.650 | 1.437 | 0.871 | 0.752 | 0.710 | 0.769 | 7.767 | 0.576 | 0.435 | 0.023 | 0.040 |
| GraphSim | 2,014 | 0.839 | 0.662 | 0.401 | 0.499 | 0.762 | 0.953 | 0.882 | 0.956 | 0.951 | 1.924 | 0.825 | 0.821 | 0.813 | 0.825 | 8.752 | 0.557 | 0.497 | 0.086 | 0.032 |
| GMN | 4,610 | 0.672 | 0.497 | 0.200 | 0.263 | 2.571 | 0.906 | 0.763 | 0.888 | 0.856 | 4.320 | 0.665 | 0.601 | 0.588 | 0.593 | 11.710 | 0.336 | 0.358 | 0.017 | 0.019 |
| EGSC | 1,676 | 0.888 | 0.723 | 0.604 | 0.708 | 0.214 | 0.984 | 0.897 | 0.987 | 0.989 | 0.573 | 0.939 | 0.829 | 0.872 | 0.883 | 9.356 | 0.545 | 0.414 | 0.055 | 0.078 |
| MGMN | 2,297 | 0.904 | 0.736 | 0.456 | 0.534 | 2.040 | 0.965 | 0.858 | 0.956 | 0.920 | 0.496 | 0.881 | 0.803 | 0.874 | 0.861 | 9.631 | 0.492 | 0.426 | 0.015 | 0.051 |
| ERIC | 1,383 | 0.906 | 0.740 | 0.679 | 0.746 | 0.113 | 0.988 | 0.908 | 0.994 | 0.996 | 0.385 | 0.890 | 0.791 | 0.882 | 0.891 | 7.127 | 0.591 | 0.525 | 0.118 | 0.080 |
+
+# 5.1 Datasets
+
+We conduct experiments on four widely used GSC datasets including AIDS700, LINUX, IMDB [1], and NCI109 [2]. Following the same splits as [1-3], i.e., $60\%$ , $20\%$ , and $20\%$ of all graphs as training set, validation set, and query set, respectively. The training set together with the validation set are called the database. More details of the datasets are presented in Appendix B.1.
+
+# 5.2 Experimental Settings
+
+Baselines. We implement two groups of baselines for comparison: (1) Combinatorial search-based Methods: Beam [20], Hungarian [15], and VJ [9]; (2) GNN-based Methods: SimGNN [1], GMN [16], GraphSim [3], MGMN [18], and EGSC [22]. We re-implemented all baselines with the same hyperparameters as the original literature provides, or carefully tuned the parameters to get the optimal results when they are not provided. We give more implementation details of ERIC and baselines in Appendix B.2.
+
+Evaluation Metric. To comprehensively evaluate our model on the similarity computation task, following [1, 22] five metrics are adopted to evaluate results for fair comparisons: Mean Squared Error (MSE) which measures the average squared differences between the predicted and the ground-truth similarity. Spearman's Rank Correlation Coefficient $(\rho)$ and Kendall's Rank Correlation Coefficient $(\tau)$ which evaluates the ranking correlations between the predicted and the true ranking results. Precision@ $k$ where $k = 10, 20$ , which computes the interactions of the predicted and ground-truth top- $k$ results divided by $k$ . The smaller the MSE, the better performance of models; for $\rho, \tau$ , and $p@k$ , the larger the better.
+
+# 5.3 Main Results
+
+The results of ERIC and the baselines on our benchmarks are reported in Table 1. For datasets with relatively small graphs whose ground-truth GEDs are exactly computed by the $\mathbf{A}^{\star}$ algorithm, ERIC consistently achieves state-of-the-art performance across all evaluation metrics as shown in Table 1. For datasets with large graphs whose ground-truth GEDs are computed approximately, ERIC still achieves the best results on NCI109, and comparable results on IMDB. The suboptimal performance of the methods based on node-to-node similarity (SimGNN, GraphSim, GMN, and MGMN) demonstrate that overly dense and fine-grained similarity computation may not always bring a beneficial boost. EGSC also uses GIN as the backbone and totally ignores cross-graph node-level interactions, and it achieves the best results on metrics $\rho$ and $\tau$ on the IMDB dataset. The reason is that EGSC adopts intra-graph attention pooling and NTN in all layers to enhance the expression ability of representation vectors. However, the attention mechanism and full NTN need additional parameters which increase the burden of learning. Although EGSC proposed a student model based on knowledge distillation to speed up the inference process, it would sacrifice the prediction accuracy in most cases. The performance of ERIC over baselines illustrates the importance of fine-grained interactions and the proper design of such interactions.
+
+# 5.4 Ablation Study
+
+Effectiveness of AReg and Multiple GED Discriminators. ERIC contains two key components: AReg and Multi-Scale GED Discriminator. To glean a deeper insight into how different components help ERIC to achieve highly competitive results, we conduct ablation experiments by removing individual components separately. Specifically, we alter the loss by removing the AReg term to
+
+Table 2: Ablation study on the key components of ERIC on AIDS700 and LINUX.
+
+ | AIDS700 | LINUX |
| mse | ρ | p@10 | mse | ρ | p@10 |
| ERIC | 1.383 | 0.906 | 0.679 | 0.113 | 0.988 | 0.994 |
| ERIC (w/o AReg) | 1.573 | 0.886 | 0.652 | 0.363 | 0.965 | 0.979 |
| ERIC (w/o NTN) | 1.687 | 0.854 | 0.633 | 0.302 | 0.951 | 0.969 |
| ERIC (w/o ℓ2) | 1.466 | 0.881 | 0.674 | 0.253 | 0.974 | 0.980 |
+
+Table 4: Inference time (sec).
+
+| Dataset | SimGNN | GraphSim | GMN | MGMN | EGSC | ERIC |
| AIDS700 | 10.773 | 14.043 | 23.975 | 11.337 | 8.763 | 6.662 |
| LINUX | 19.347 | 31.238 | 82.489 | 22.574 | 21.573 | 18.969 |
| IMDB | 225.682 | 379.480 | 1253.551 | 357.933 | 133.437 | 48.750 |
| NCI109 | 2913.178 | 3463.620 | >10^4 | 3726.834 | 2097.405 | 1763.356 |
+
+Table 3: Transferability study of AReg on AIDS700 and LINUX.
+
+ | AIDS700 | LINUX |
| mse | ρ | p@10 | mse | ρ | p@10 |
| SimGNN | 1.573 | 0.835 | 0.417 | 2.479 | 0.912 | 0.635 |
| SimGNN+AReg | 1.439 | 0.858 | 0.506 | 1.974 | 0.945 | 0.658 |
| EGSC | 1.676 | 0.888 | 0.604 | 0.214 | 0.984 | 0.987 |
| EGSC+AReg | 1.478 | 0.904 | 0.643 | 0.142 | 0.989 | 0.992 |
+
+
+(a) AIDS700
+
+
+(b) LINUXX
+Figure 5: Impact of different order $p$ on AIDS700 and LINUX datasets.
+
+study the effect of the cross-graph node-graph interaction, with the results reported in ERIC (w/o AReg) of Table 2. We find that only using the MSE loss $\mathcal{L}_{\mathrm{GED}}$ will lead to a performance drop on the extracted three evaluation metrics, which confirms the necessity of AReg. In our design, the final similarity score is obtained by the weighted average of two similarity scores based on the NTN discriminator $s_{\mathrm{NTN}}$ and the $\ell_2$ discriminator $s_p$ respectively. To further investigate the impact of multiple GED discriminators, we remove one of $s_{\mathrm{NTN}}$ and $s_p$ to study the effect of each discriminator. As shown in Table 2, both ERIC (w/o NTN) and ERIC (w/o $\ell_2$ ) cause a decrease in effectiveness, which demonstrates both of them contribute to the final performance, while the model benefits more from NTN.
+
+Transferability of AReg Further, since AReg is a model-agnostic regularization term, we are interested in the transferability of AReg, so we evaluate the performance of applying AReg to other GSC models. We use SimGNN and EGSC as baselines. For SimGNN, we use AReg to replace the node-to-node similarity computation. For EGSC, we directly add AReg to the loss function. Table 3 shows the effect of AReg on SimGNN and EGSC. As expected, the advantage of SimGNN+AReg over SimGNN shows that integrating the dense similarity matrix into the final similarity score may bring noise which affects performance. While the performance on EGSC proves that combining fine-grained similarity in a proper way, i.e., node-graph rather than node-node, can improve the model.
+
+Sensitivity of Order $p$ in $\delta_p$ In the multi-scale GED discriminator module, we adopt the exponential $p$ -order Minkowski distance as a similarity measure to further improve the separability of clusters in the graph embedding space. For simplicity, we directly use the 2-order Minkowski distance, i.e., $\ell_2$ distance. Results in Table 2 show the effectiveness of considering the $\ell_2$ distance, and Fig. 4 demonstrates the complementarity of different similarity measures. To investigate the sensitivity of $p$ in our model, we set $p$ from [2, 4, 6, 8], and run 10 times for each value of $p$ . Then the results of mean square error with standard deviation are reported in Fig. 5. We can observe that the performance increases first and then the error becomes stable when $p \geq 2$ . It shows that using the $\ell_2$ distance as the GED discriminator is suitable for our model and higher-order Minkowski distance would not improve the performance.
+
+# 5.5 Inference Time
+
+In ERIC, the cross-graph alignment only acts as a regularization term in the training stage but is no longer used in the inference stage. To evaluate the efficiency, we compare the performance of ERIC with baselines in terms of inference time in Table 4. In Table 5 of Appendix B.1 we list the number of graph pairs in the inference stage (#Testing pairs), and all experiments are implemented with a single machine with 1 NVIDIA Quadro RTX 8000 GPU. As can be observed, node-to-node
+
+
+
+
+(a) The exact similarity ranking based on $\mathrm{A}^{\star}$
+(b) The predicted similarity ranking based on ERIC
+
+
+Figure 6: Visualization of graph search examples on the AIDS700 dataset. Nodes with different labels are assigned different colors. (a) and (b) are similarity rankings based on the normalized GEDs computed by $\mathbf{A}^{\star}$ (exact) and ERIC (estimation) respectively.
+Figure 7: Heatmaps of cross-graph node-to-node cosine similarity based on the node representations learned by the GNN encoder of ERIC. Y-axis means the node in a randomly sampled query graph. (a)~(e) are ranked by the exact normalized GEDs between the query graph and graphs of particular ranks in the database. For example, 0.571 (10th) means the nGED of the graph that ranks 10th in similarity to the query graph is 0.571. The color depth in the heatmap represents the similarity of the node pair; the deeper the color, the higher the similarity.
+
+similarity computation is more time-consuming on all datasets. Our proposed node-graph similarity computation does not incur substantial additional running time in practice. To summarize, ERIC is faster than all baseline models, while still achieving significantly higher accuracy on all datasets.
+
+# 5.6 Visualization of Graph Search
+
+The goal of the graph search task is to find $k$ graphs from the dataset that are most similar to the given query graph, which is a routine task in drug discovery [24]. In Fig. 6 we show a case based on the AIDS700 dataset, where each graph represents a functional group. Comparing the exact similarity ranking computed by $\mathrm{A}^{\star}$ and the estimated one computed by ERIC, we see that the ranking of ERIC has a high consistency with the exact ranking, which proves that ERIC is able to extract graphs that contain the similar substructure from around 700 graphs with varying size and structure and the top-ranked graph has a high degree of isomorphism with the query. It also demonstrates that ERIC can capture structural patterns shared across graphs. More results of visualization are provided in Appendix C.
+
+# 5.7 Analysis of Node-to-Node Similarity
+
+In Fig. 7, we show the node-to-node similarity between a query graph and the graphs at different ranking positions in terms of normalized GEDs. It can be found that for graph pairs with a small GED, the node representations generated by ERIC show a clear correspondence between nodes as shown in Fig. 7 (a). As the GED increases, the correspondence between nodes across the graph gradually weakens, i.e., cross-graph node-to-node similarity reduces. Thus, the similarity matrices in Fig. 7 can guide us to find a better alignment between pair-wise graphs.
+
+# 6 Related Work
+
+The goal of graph similarity computation (GSC) is to quantify the similarity between graphs under a specific similarity measure. Various similarity measures have been well studied in prior works, such as graph edit distance (GED) [5, 25, 20] and maximum common subgraph (MCS) [6, 10]. Among these, GED is the most popular one, and many other similarity measures can be proven to be its special cases [17]. However, computing the exact GED between two graphs is known to be NP-hard. In practice, the computation becomes challenging when the number of nodes is more than 16 [4] using exact GED solvers such as the $\mathbf{A}^{\star}$ algorithm [25]. Thus, approximate algorithms have been proposed for GED-based GSC. These approximate methods can be broadly divided into two classes: (1) Combinatorial search-based methods, which aim to exploit combinatorial structures or theoretical lower-bounds to approximate GED. Beam [20] is a GED estimator based on Beam Search; Hungarian [15] is proposed based on the famous Hungarian algorithm for weighted graph matching; Hausdorff approximation [11] provides a lower bound for the GED approximation; VJ [9] uses the Volgenant and Jonker algorithm for GED approximation. However, these methods are highly heuristic-driven and run with either sub-exponential time or cubic time complexity, limiting the scalability as the graphs grow in size. Also, these methods totally ignore the node feature information, so that the underlying semantic similarity can not be captured. (2) Learning-based methods, which are data-driven and aim to learn graph similarity from the data itself, hopefully with higher accuracy and far lower time costs compared with search-based methods. GMN [16] introduces a cross-graph attention layer that allows the nodes in the two graphs to interact with each other and predicts graph similarity using the representation vectors that fuse cross-graph information. SimGNN [1] relies on a shared GNN encoder, a neural tensor network, and a pairwise node comparison module to compute the similarity between two graphs. GraphSim [3] extends SimGNN by using convolutional neural networks to capture the multi-scale node-level interactions. EGSC [22] simplifies SimGNN by ignoring node-level interactions and uses knowledge distillation to accelerate the inference stage. MGMN [18] employs a node-graph matching network to capture cross-level features between nodes of a graph and the other whole graph, where the cross-graph aggregation weights are computed by node-to-node attention coefficients. Our proposed ERIC is also a learning-based method. Unlike the above approaches that either discard node-level interactions entirely, or performs interactions between all node pairs, our method proposes a novel node-graph interaction paradigm that avoids dense similarity computation while preserving fine-grained interactions.
+
+# 7 Conclusion
+
+We propose ERIC, a simple yet powerful GNN-based framework for the graph similarity computation task. Specifically, we first give a deep insight into the graph edit distance, and propose Alignment Regularization (AReg) which is a separated structure independent of the end-to-end learning pipeline. AReg frees the model from complicated node-to-node interaction for similarity computation. Further, we propose a multi-scale GED discriminator to improve the discriminative ability of the learned representations. We show the effectiveness of our model through a comprehensive set of experiments and analyses.
+
+# Acknowledgments and Disclosure of Funding
+
+This work is supported in part by Shenzhen Baisc Research Fund under grant JCYJ20200109142217397.
+
+# References
+
+[1] Bai, Y., Ding, H., Bian, S., Chen, T., Sun, Y., and Wang, W. Simgnn: A neural network approach to fast graph similarity computation. In Proceedings of the Twelfth ACM International Conference on Web Search and Data Mining, pp. 384-392, 2019.
+[2] Bai, Y., Ding, H., Qiao, Y., Marinovic, A., Gu, K., Chen, T., Sun, Y., and Wang, W. Unsupervised inductive graph-level representation learning via graph-graph proximity. arXiv preprint arXiv:1904.01098, 2019.
+
+[3] Bai, Y., Ding, H., Gu, K., Sun, Y., and Wang, W. Learning-based efficient graph similarity computation via multi-scale convolutional set matching. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pp. 3219-3226, 2020.
+[4] Blumenthal, D. B. and Gamper, J. On the exact computation of the graph edit distance. Pattern Recognition Letters, 134:46-57, 2020.
+[5] Bunke, H. On a relation between graph edit distance and maximum common subgraph. Pattern recognition letters, 18(8):689-694, 1997.
+[6] Bunke, H. and Shearer, K. A graph distance metric based on the maximal common subgraph. Pattern recognition letters, 19(3-4):255-259, 1998.
+[7] Chen, Z., Villar, S., Chen, L., and Bruna, J. On the equivalence between graph isomorphism testing and function approximation with gnns. Advances in neural information processing systems, 32, 2019.
+[8] Doan, K. D., Manchanda, S., Mahapatra, S., and Reddy, C. K. Interpretable graph similarity computation via differentiable optimal alignment of node embeddings. In Proceedings of the 44th International ACM SIGIR Conference on Research and Development in Information Retrieval, pp. 665-674, 2021.
+[9] Fankhauser, S., Riesen, K., and Bunke, H. Speeding up graph edit distance computation through fast bipartite matching. In International Workshop on Graph-Based Representations in Pattern Recognition, pp. 102-111. Springer, 2011.
+[10] Fernández, M.-L. and Valiente, G. A graph distance metric combining maximum common subgraph and minimum common supergraph. Pattern Recognition Letters, 22(6-7):753-758, 2001.
+[11] Fischer, A., Plamondon, R., Savaria, Y., Riesen, K., and Bunke, H. A Hausdorff heuristic for efficient computation of graph edit distance. In Joint IAPR International Workshops on Statistical Techniques in Pattern Recognition (SPR) and Structural and Syntactic Pattern Recognition (SSPR), pp. 83-92. Springer, 2014.
+[12] Hartmanis, J. Computers and intractability: a guide to the theory of np-completeness (michael r. garey and david s. johnson). Siam Review, 24(1):90, 1982.
+[13] Hornik, K., Stinchcombe, M., and White, H. Multilayer feedforward networks are universal approximators. Neural networks, 2(5):359-366, 1989.
+[14] Kriegel, H.-P., Pfeifle, M., and Schonauer, S. Similarity search in biological and engineering databases. IEEE Data Eng. Bull., 27(4):37-44, 2004.
+[15] Kuhn, H. W. The hungarian method for the assignment problem. Naval research logistics quarterly, 2(1-2):83-97, 1955.
+[16] Li, Y., Gu, C., Dullien, T., Vinyals, O., and Kohli, P. Graph matching networks for learning the similarity of graph structured objects. In International conference on machine learning, pp. 3835-3845. PMLR, 2019.
+[17] Liang, Y. and Zhao, P. Similarity search in graph databases: A multi-layered indexing approach. In 2017 IEEE 33rd International Conference on Data Engineering (ICDE), pp. 783-794. IEEE, 2017.
+[18] Ling, X., Wu, L., Wang, S., Ma, T., Xu, F., Liu, A. X., Wu, C., and Ji, S. Multilevel graph matching networks for deep graph similarity learning. IEEE Transactions on Neural Networks and Learning Systems, 2021.
+[19] Morris, C., Ritzert, M., Fey, M., Hamilton, W. L., Lenssen, J. E., Rattan, G., and Grohe, M. Weisfeiler and leman go neural: Higher-order graph neural networks. In Proceedings of the AAAI conference on artificial intelligence, volume 33, pp. 4602-4609, 2019.
+
+[20] Neuhaus, M., Riesen, K., and Bunke, H. Fast suboptimal algorithms for the computation of graph edit distance. In Joint IAPR International Workshops on Statistical Techniques in Pattern Recognition (SPR) and Structural and Syntactic Pattern Recognition (SSPR), pp. 163-172. Springer, 2006.
+[21] Ogaard, K., Roy, H., Kase, S., Nagi, R., Sambhoos, K., and Sudit, M. Discovering patterns in social networks with graph matching algorithms. In International Conference on Social Computing, Behavioral-Cultural Modeling, and Prediction, pp. 341-349. Springer, 2013.
+[22] Qin, C., Zhao, H., Wang, L., Wang, H., Zhang, Y., and Fu, Y. Slow learning and fast inference: Efficient graph similarity computation via knowledge distillation. Advances in Neural Information Processing Systems, 34, 2021.
+[23] Qin, Z., Bai, Y., and Sun, Y. Ghashing: semantic graph hashing for approximate similarity search in graph databases. In Proceedings of the 26th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining, pp. 2062-2072, 2020.
+[24] Ranu, S., Calhoun, B. T., Singh, A. K., and Swamidass, S. J. Probabilistic substructure mining from small-molecule screens. Molecular Informatics, 30(9):809-815, 2011.
+[25] Riesen, K., Emmenegger, S., and Bunke, H. A novel software toolkit for graph edit distance computation. In International Workshop on Graph-Based Representations in Pattern Recognition, pp. 142-151. Springer, 2013.
+[26] Socher, R., Chen, D., Manning, C. D., and Ng, A. Reasoning with neural tensor networks for knowledge base completion. Advances in neural information processing systems, 26, 2013.
+[27] Steinhaeuser, K. and Chawla, N. V. Community detection in a large real-world social network. In Social computing, behavioral modeling, and prediction, pp. 168-175. Springer, 2008.
+[28] Tian, Y., Mceachin, R. C., Santos, C., States, D. J., and Patel, J. M. Saga: a subgraph matching tool for biological graphs. Bioinformatics, 23(2):232-239, 2007.
+[29] Van der Maaten, L. and Hinton, G. Visualizing data using t-sne. Journal of machine learning research, 9(11), 2008.
+[30] Wang, R., Zhang, T., Yu, T., Yan, J., and Yang, X. Combinatorial learning of graph edit distance via dynamic embedding. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp. 5241-5250, 2021.
+[31] Wu, Z., Pan, S., Chen, F., Long, G., Zhang, C., and Philip, S. Y. A comprehensive survey on graph neural networks. IEEE transactions on neural networks and learning systems, 32(1): 4-24, 2020.
+[32] Xu, K., Hu, W., Leskovec, J., and Jegelka, S. How powerful are graph neural networks? In International Conference on Learning Representations, 2019. URL https://openreview.net/forum?id=ryGs6iA5Km.
+[33] Zaheer, M., Kottur, S., Ravanbakhsh, S., Poczos, B., Salakhutdinov, R. R., and Smola, A. J. Deep sets. Advances in neural information processing systems, 30, 2017.
+[34] Zhuo, W. and Tan, G. Proximity enhanced graph neural networks with channel contrast. In Proceedings of the Thirty-First International Joint Conference on Artificial Intelligence, IJCAI-22, pp. 2448-2455, 7 2022.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [N/A]
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes] See Section 3
+(b) Did you include complete proofs of all theoretical results? [Yes] See Section 3
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] See Supplemental Material
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Appendix B.2
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] See Section 5.4
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Section 5.5
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [No]
+(c) Did you include any new assets either in the supplemental material or as a URL? [No]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [No]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [No]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientgraphsimilaritycomputationwithalignmentregularization/images.zip b/efficientgraphsimilaritycomputationwithalignmentregularization/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..4cedd29ae4daa7ec4efd91f138f0e553c05314e7
--- /dev/null
+++ b/efficientgraphsimilaritycomputationwithalignmentregularization/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0ba5ca9f720cd1c0541e317e888c7315f729a929320471b21fd86f1a8d6e9d62
+size 390736
diff --git a/efficientgraphsimilaritycomputationwithalignmentregularization/layout.json b/efficientgraphsimilaritycomputationwithalignmentregularization/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..148c6048088daae39384369bddc532c52293b09e
--- /dev/null
+++ b/efficientgraphsimilaritycomputationwithalignmentregularization/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2f7b882fda92c259f9080c58952697e543164ce1f038b31003c54ac2f91b07a2
+size 504204
diff --git a/efficientknowledgedistillationfrommodelcheckpoints/ab32e0b9-fe0f-4ed6-bb87-c1897b0f3b76_content_list.json b/efficientknowledgedistillationfrommodelcheckpoints/ab32e0b9-fe0f-4ed6-bb87-c1897b0f3b76_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..fa0e2ccf98a0f824824256ad5d9c5aa4657d05dc
--- /dev/null
+++ b/efficientknowledgedistillationfrommodelcheckpoints/ab32e0b9-fe0f-4ed6-bb87-c1897b0f3b76_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ac83a83bc8e5ec4787dabb79dbc239b983b665e33277fe7fe26f104c7e02ac8b
+size 80670
diff --git a/efficientknowledgedistillationfrommodelcheckpoints/ab32e0b9-fe0f-4ed6-bb87-c1897b0f3b76_model.json b/efficientknowledgedistillationfrommodelcheckpoints/ab32e0b9-fe0f-4ed6-bb87-c1897b0f3b76_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..24f12c180fb34a0894c9d89e03a049ff6f88b89a
--- /dev/null
+++ b/efficientknowledgedistillationfrommodelcheckpoints/ab32e0b9-fe0f-4ed6-bb87-c1897b0f3b76_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b2c6685e2e006cd606289e79d00f30b3df9666f328cf4cf19c874a8f8f90e379
+size 104521
diff --git a/efficientknowledgedistillationfrommodelcheckpoints/ab32e0b9-fe0f-4ed6-bb87-c1897b0f3b76_origin.pdf b/efficientknowledgedistillationfrommodelcheckpoints/ab32e0b9-fe0f-4ed6-bb87-c1897b0f3b76_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..62183a679018f8194400537c7bb6b4f91cfa4e20
--- /dev/null
+++ b/efficientknowledgedistillationfrommodelcheckpoints/ab32e0b9-fe0f-4ed6-bb87-c1897b0f3b76_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:49d37898d33e25002ed98aebc0afc68a9509be4cb3e732e77d441213b1a596bb
+size 1095099
diff --git a/efficientknowledgedistillationfrommodelcheckpoints/full.md b/efficientknowledgedistillationfrommodelcheckpoints/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..ae7ce144ae94dcb9c913da0c067f5ac98eef4d10
--- /dev/null
+++ b/efficientknowledgedistillationfrommodelcheckpoints/full.md
@@ -0,0 +1,335 @@
+# Efficient Knowledge Distillation from Model Checkpoints
+
+Chaofei Wang*, Qisen Yang*, Rui Huang, Shiji Song, Gao Huang†
+Department of Automation, Tsinghua University, China
+wangcf18, yangqs19, hr20@mails.tsinghua.edu.cn
+shijis, gaohuang@tsinghua.edu.cn
+
+# Abstract
+
+Knowledge distillation is an effective approach to learn compact models (students) with the supervision of large and strong models (teachers). As empirically there exists a strong correlation between the performance of teacher and student models, it is commonly believed that a high performing teacher is preferred. Consequently, practitioners tend to use a well trained network or an ensemble of them as the teacher. In this paper, we observe that an intermediate model, i.e., a checkpoint in the middle of the training procedure, often serves as a better teacher compared to the fully converged model, although the former has much lower accuracy. More surprisingly, a weak snapshot ensemble of several intermediate models from a same training trajectory can outperform a strong ensemble of independently trained and fully converged models, when they are used as teachers. We show that this phenomenon can be partially explained by the information bottleneck principle: the feature representations of intermediate models can have higher mutual information regarding the input, and thus contain more "dark knowledge" for effective distillation. We further propose an optimal intermediate teacher selection algorithm based on maximizing the total task-related mutual information. Experiments verify its effectiveness and applicability. Our code is available at https://github.com/LeapLabTHU/CheckpointKD.
+
+# 1 Introduction
+
+Knowledge distillation (KD) [1, 2] has been proved to be an effective technique to promote the performance of a low-capacity model by transferring "dark knowledge" from a large teacher model. Empirically, there usually exists a strong correlation between the performance of the teacher model and the student model. For this reason, it is a standard practice to use a well trained network or an ensemble of multiple well trained networks as the teacher [3, 4, 5], and some researches are attempted to improve distillation performance via boosting the ensemble performance [6, 7]. The underlying assumption is that high performing teachers lead to better student models.
+
+However, this viewpoint has been challenged by some recent works [8, 9, 10, 11, 12], in which it has been observed that a large model capacity gap between the teacher and student may have a negative effect for knowledge transfer. To address this issue, researchers have proposed to employ an intermediate-size network [8] or an assistant network [9] to improve the distillation performance in such scenarios. In [10], a "tolerant" teacher model is designed by using a softened loss function. In [11], Park et al. proposed to learn student-friendly teacher by plugging in student branches during the training procedure. Nevertheless, there is no clear theoretical explanation for the gap between teacher and student, and the search for a substitute teacher is not straightforward.
+
+(a) Intermediate Teacher vs. Full Teacher
+
+Full Teacher Intermediate Teacher Distilled Student Student
+
+
+(b) Snapshot Ensemble vs. Full Ensemble
+Figure 1: A sketch map of the two counterintuitive observations. (a) A weak intermediate model can serve as a better teacher than the strong fully converged model. (b) A weak Snapshot Ensemble [13] can serve as a better teacher than the strong Full Ensemble.
+
+In this paper, we make an intriguing observation that further supports the viewpoint that high performing models may not necessarily be good teachers, but from a novel perspective. Specifically, we find that an unconverged intermediate model from the middle of the training procedure, often serves as a better teacher than the final converged model, although the former has much lower accuracy (as illustrated in Figure 1(a)). Moreover, a weak snapshot ensemble of intermediate teacher models along the same optimization path (denoted as Snapshot Ensemble, which is a variant of $[13]^3$ ) can outperform the standard ensemble of an equal number of independently trained teacher models (denoted as Full Ensemble). This surprising phenomenon is illustrated in Figure 1(b), in which a Snapshot Ensemble can have better distillation performance than a Full Ensemble, although the accuracy of the former is significantly lower.
+
+To understand the above phenomenon, we show that there is a strong connection between KD and the information bottleneck (IB) theory [14]. Therein, it has been observed that during the training procedure of deep neural networks, the mutual information between the learned features $F$ and the target $Y$ , denoted as $I(Y;F)$ , increases monotonically as a function of the training epochs; while the mutual information between $F$ and the input $X$ , denoted as $I(X;F)$ , grows in the early training stage, but then decreases gradually after a certain number of epochs. We note that maximizing the mutual information $I(Y;F)$ is helpful for improving the teacher model itself, but not always necessary for KD, because the ground truth target $Y$ is already included in the KD objective function. In contrast, the mutual information $I(X;F)$ , to some extent, can be viewed as a type of dark knowledge that is desired for effective KD. For example, considering an image with a man driving a car, although it may be uniquely labeled into the "car" category, it still contains features of the "people" category. Such weak but non-negligible features extracted from the input (measured by $I(X;F)$ ) are in fact the most valuable knowledge for distilling student models. Not surprisingly, most KD algorithms apply a high temperature to soften the network prediction in order to reveal these information from a teacher model. However, as shown by IB theory, a fully converged model tends to be overconfident and may already have collapsed representations for non-targeted classes. Therefore, simply scaling the temperature can not effectively recover the suppressed knowledge. On the contrary, an intermediate model, although does not reach its top accuracy due to non-optimal $I(Y;F)$ , may have a larger $I(X;F)$ that benefits KD. This partially explains our observation that intermediate models can be better teachers. More detailed and formal analyses are provided in the following sections.
+
+Further, we propose an optimal intermediate teacher selection algorithm based on the IB theory. From the perspective of entropy, the teacher model's representation can be decomposed as the information with respect to the input, the output and some nuisance [15]. The proposed algorithm aims to find the most informative intermediate teacher model which possesses the minimal part of nuisance on a training trajectory. Experiments verify its applicability in various distillation scenarios. Our contributions are summarized as follows:
+
+- By designing two exploratory experiments, we observe the phenomenon that intermediate models can serve as better teachers than fully converged models. This suggests that for
+
+effective KD one should not only focus on improving the teacher performance. Instead, rethinking what the "dark knowledge" is and how to enrich it is highly valuable.
+- We demonstrate the connection between our observations and the IB theory, providing a new perspective for understanding KD and explaining the "dark knowledge".
+- Based on our observations and analyses, a novel simple but effective algorithm is proposed to find the optimal intermediate teacher and achieve better distillation performance. Experiments validate its effectiveness and adaptability.
+
+# 2 Related Work
+
+Knowledge distillation. Hinton et al. [2] proposed to transfer "dark knowledge" of a strong capacity teacher model to a compact student model by minimizing the Kullback-Leibler divergence between the soft targets of the two models. Since then, many variants of KD methods were proposed to improve the distillation performance[16], such as Fitnets [17], AT[18], CCM[19], FSP[20], SP[21], CCKD[22], $\mathrm{TC^3KD}$ [23]. As a promising technique to improve model generalization, ensemble learning is often combined with knowledge distillation to improve the distillation performance[3, 11, 4]. In the online knowledge distillation framework[24], efforts were made to boost the distillation performance by increasing the diversity between multiple models to improve the ensemble performance [6, 7]. Most existing methods commonly assumed that a high performing teacher is preferred for KD. On the contrary, some researchers thought that the model capacity gap between strong teachers and small students usually degrades knowledge transfer[8, 9, 12, 25]. Some of them have experimentally verified that poor teachers can also perform KD tasks well[12, 25]. Several methods are proposed to compress this gap by introducing an assistant network [8, 9] or designing a student-friendly teacher [10, 11]. However, they did not explain theoretically why gap exists and how gap affects KD. In the self-distillation framework[26, 27], it is essentially the intermediate model that is used as the teacher, but no one has a theoretical explanation for why the intermediate model works. In this paper, we link KD and IB theory through extensive observations and experiments. From the perspective of mutual information, we explain why intermediate models serve as better teachers than full models, and how to select an suitable intermediate model to reduce the negative impact of model gap.
+
+Information bottleneck. Tishby et al. [28] firstly proposed the information bottleneck concept and provided a tabular method to numerically solve the IB Lagrangian (Eq. (3)). Later, Tishby and Zaslavsky [14] proposed to interpret deep learning with IB principle. Following this idea, Shwartz-Ziv and Tishby [29] studied the IB principle to explain the training dynamics of deep networks. It has motivated many studies to apply the IB principle to interpret and improve deep neural networks (DNNs) [30, 31, 32]. Recently, some researchers introduced IB principle to deep reinforcement learning successfully [33, 34, 35]. As far as we know, we are the first to introduce IB principle to interpret knowledge distillation.
+
+# 3 Exploratory Experiments
+
+In this section, we first formally describe the KD and ensemble KD methods used in the paper, then design two exploratory experiments to show how intermediate models are surprisingly valuable for KD, despite their lower accuracies due to incompleteness of training.
+
+# 3.1 Formulation
+
+In the classical KD setting, a fully converged teacher model (full teacher for short) $T^{\mathrm{full}}$ is used to distill a student model $S$ . Define $P_{\mathrm{T}^{\mathrm{full}}}$ as the softmax output of teacher model, $P_{\mathrm{S}}$ as the softmax output of student model and $Y_{\mathrm{true}}$ as the true labels. The student model is trained to optimize the following loss function:
+
+$$
+L _ {\mathrm {K D}} = \alpha H \left(Y _ {\text {t r u e}}, P _ {\mathrm {S}}\right) + (1 - \alpha) H \left(P _ {\mathrm {T} ^ {\text {f u l l}}} ^ {\tau}, P _ {\mathrm {S}} ^ {\tau}\right), \tag {1}
+$$
+
+where $H$ refers to the cross-entropy, $\alpha$ is the trade-off parameter, $\tau$ is the temperature. Conducting KD with an intermediate teacher model $T^{\mathrm{inter}}$ , means using $T^{\mathrm{inter}}$ instead of $T^{\mathrm{full}}$ in Eq. (1).
+
+In the standard ensemble KD setting, there are $M(M \geq 2)$ full teachers $\{T_1^{\mathrm{full}}, T_2^{\mathrm{full}}, \dots, T_M^{\mathrm{full}}\}$ , which have the same network structure and training strategy but different initial parameters. The student
+
+model needs to mimic the average softened softmax output of all teacher models. We call this method Full Ensemble KD. The loss function is as follows:
+
+$$
+L _ {\mathrm {E K D}} = \alpha H \left(Y _ {\text {t r u e}}, P _ {\mathrm {S}}\right) + (1 - \alpha) H \left(\frac {1}{M} \sum_ {i = 1} ^ {M} P _ {\mathrm {T} _ {i} ^ {\text {f u l l}}} ^ {\tau}, P _ {\mathrm {S}} ^ {\tau}\right). \tag {2}
+$$
+
+The Snapshot Ensemble aggregates $M(M \geq 2)$ intermediate teachers $\{T_1^{\mathrm{inter}}, T_2^{\mathrm{inter}}, \dots, T_M^{\mathrm{inter}}\}$ from one training trajectory. Conducting KD with a Snapshot Ensemble, means using $T_i^{\mathrm{inter}}$ instead of $T_i^{\mathrm{full}}$ in Eq. (2). We call it Snapshot Ensemble KD.
+
+# 3.2 Experimental design and setups
+
+To examine the common assumption "high performing teachers lead to better student models" and explore the value of intermediate models, we design two experiments. 1) The standard KD is to train a full teacher model to distill a student model. What if we adopt the intermediate teacher models instead? 2) The standard ensemble KD is to train multiple full teacher models independently and average their output to distill a single student model. What if we adopt the Snapshot Ensemble instead of the Full Ensemble? We name the first experiment as "Intermediate Teacher vs. Full Teacher", and the second experiment as "Snapshot Ensemble vs. Full Ensemble". For generality, we conduct experiments on the CIFAR-100 [36], Tiny-ImageNet[37] and ImageNet [38] datasets with various teacher-student pairs. The distillation loss functions follow Eqs. (1) and (2). For fair comparison, we search the optimal hyperparameters (i.e., the loss ratio $\alpha$ and the temperature $\tau$ ) for each teacher-student pair. Top 1 accuracy is averagely evaluated in five independent experiments.
+
+The "Intermediate Teacher vs. Full Teacher" experiment is conducted on the CIFAR-100 and ImageNet. On CIFAR-100, we adopt WRN-40-2[39] and ResNet-110[40] as teacher models, WRN-40-1[39], ResNet-32[40], and MobileNetV2[41] (width multiplier is 0.75) as student models. We train each teacher model for 200 epochs to ensure convergence. We save the intermediate models at the $20^{\text{th}}$ , $40^{\text{th}}$ , ..., $180^{\text{th}}$ epochs as intermediate teachers, and the models at the $200^{\text{th}}$ epoch as full teachers. On ImageNet, we adopt ResNet-50 [40], and ResNet-34 [40] as teacher models, and MobileNetV2 [41], and ResNet-18 [40] as student models. We follow the standard PyTorch practice but train teacher models for 120 epochs to guarantee convergence. We save the intermediate models at the $60^{\text{th}}$ epoch as intermediate teachers, and the models at the $120^{\text{th}}$ epoch as full teachers. The "Snapshot Ensemble vs. Full Ensemble" experiment is conducted on CIFAR-100 and Tiny-ImageNet. We train models for 150 epochs on Tiny-ImageNet to ensure convergence. We save the intermediate models at the $75^{\text{th}}$ epoch as intermediate teachers, and the models at the $150^{\text{th}}$ epoch as full teachers. We adopt WRN-40-1[39], ResNet-32[40], and MobileNetV2[41] as student models, and WRN-40-2[39], and ResNet-110[40] as teacher models. Due to the page limitation, we include the introduction of the datasets and detailed experimental settings in the Appendix A.1.
+
+# 3.3 Intermediate Teacher vs. Full Teacher
+
+Firstly, we simply compare the half-way teachers with the full teachers on CIFAR-100 and ImageNet. It means that the intermediate models at the $100^{\mathrm{th}}$ epoch are adopted as $T^{\mathrm{inter}}$ on CIFAR-100, the intermediate models at the $60^{\mathrm{th}}$ epoch are adopted as $T^{\mathrm{inter}}$ on ImageNet. The training cost of all intermediate teachers is only half that of the full teachers. Table 1 shows the comparison results. Specifically, on CIFAR-100, for WRN-40-2, the accuracy of the intermediate model is $13.54\%$ lower than that of the full model, but its distillation performance is comparable $(0.08\%)$ higher and superior $(0.96\%)$ higher). For ResNet-110, the accuracy of the intermediate model is $13.98\%$ lower than that of the full model, but its distillation performance is still comparable $(0.01\%)$ higher and $0.16\%$ higher). On ImageNet, the accuracy of the inter
+
+
+Figure 2: Ablation experiments of the training epochs of $T^{\mathrm{inter}}$ on CIFAR-100.
+
+Table 1: Comparison results of "Full Teacher vs. Intermediate Teacher". $T^{\text{full}}$ represents a full teacher. $T^{\text{inter}}$ represents a half-way intermediate teacher whose KD performance is underlined. $T_*^{\text{inter}}$ represents the best intermediate teacher whose KD performance is bold-faced. The numbers in brackets represent decreases (↓) or increases (↑) in accuracy.
+
+| Dataset | Network structure | Accuracy of reference models | Accuracy of KD |
| T | S | Tfull | Tinter | S | Tfull | Tinter | T*inter |
| CIFAR-100 | WRN-40-2 | WRN-40-1 | 76.53 | 62.99 (↓ 13.54) | 70.38 | 72.68±0.10 | 72.76±0.24 (↑ 0.08) | 73.26±0.03 (↑ 0.58) |
| MobileNetV2 | 64.49 | 68.03±0.34 | 68.99±0.12 (↑ 0.96) | 68.99±0.12 (↑ 0.96) |
| ResNet-110 | ResNet-32 | 73.41 | 59.43 (↓ 13.98) | 70.16 | 72.48±0.22 | 72.49±0.32 (↑ 0.01) | 72.63±0.13 (↑ 0.15) |
| MobileNetV2 | 64.49 | 68.63±0.35 | 68.79±0.17 (↑ 0.16) | 69.05±0.27 (↑ 0.42) |
| ImageNet | ResNet-34 | ResNet-18 | 73.86 | 66.08 (↓ 7.78) | 69.75 | 70.66 | 70.86 (↑ 0.20) | 70.98 (↑ 0.32) |
| ResNet-50 | MobileNetV2 | 76.93 | 69.14 (↓ 7.79) | 64.18 | 66.64 | 66.79 (↑ 0.15) | 66.92 (↑ 0.28) |
+
+Table 2: Comparison results of "Full Ensemble vs. Snapshot Ensemble". EN1 denotes $T_{1}^{\mathrm{full}} + T_{2}^{\mathrm{full}}$ . EN2 denotes $T_{1}^{\mathrm{inter}} + T_{2}^{\mathrm{full}}$ . EN3 denotes $T_{1}^{\mathrm{inter}} + T_{1}^{\mathrm{full}}$ . The best results of ensemble KD performance are bold-faced, while the best results of ensemble performance are underlined.
+
+| Dataset | Network structure | Accuracy of baseline | Accuracy of ensemble KD | Accuracy of ensemble |
| T | S | T | S | KD | EN1 | EN2 | EN3 | EN1 | EN2 | EN3 |
| CIFAR-100 | WRN-40-2 | WRN-40-1 | 76.53 | 70.38 | 72.68±0.10 | 73.05±0.16 | 73.80±0.31 | 73.70±0.04 | 79.44 | 76.90 | 76.29 |
| MobileNetV2 | 64.49 | 68.03±0.34 | 68.69±0.32 | 69.14±0.27 | 69.20±0.31 |
| ResNet-110 | ResNet-32 | 73.41 | 70.16 | 72.48±0.22 | 72.88±0.14 | 72.91±0.17 | 73.03±0.24 | 76.92 | 74.28 | 73.23 |
| MobileNetV2 | 64.49 | 68.63±0.35 | 69.69±0.25 | 70.46±0.34 | 70.19±0.25 |
| Tiny-ImageNet | WRN-40-2 | WRN-40-1 | 57.61 | 53.85 | 55.65 | 55.96 | 56.27 | 56.37 | 62.81 | 61.53 | 60.33 |
| MobileNetV2 | 53.75 | 56.53 | 56.67 | 57.05 | 57.28 |
| Average | | 79.32 | 74.11 | 76.04 | 66.11 | 66.61 | 66.63 | 73.06 | 70.90 | 69.95 |
+
+mediate teachers is about $7.8\%$ lower than that of the full teachers, but their distillation performance is still comparable or even better.
+
+To further explore the potential of the intermediate models, we conduct ablation experiments of the training epochs of $T^{\mathrm{inter}}$ on CIFAR-100. Figure 2 shows some valuable information. 1) Good and bad teachers both improve the baseline of student model, which is consistent with [25]. 2) The peaks of all curves are not the last points, which means that there is always an intermediate teacher that is better than the full teacher. Table 1 (the last column) shows the KD performance of the best $T^{\mathrm{inter}}$ . 3) Generally, the accuracy curve of student first rises then decreases along with the teacher's training epochs. Combing Table 1 and Figure 2, we find a counterintuitive observation:
+
+Observation 1. The distillation performance of an intermediate teacher model can be comparable with or even better than that of the fully converged teacher model, although the accuracy and training cost of the former is significantly lower.
+
+# 3.4 Snapshot Ensemble vs. Full Ensemble
+
+First, we fix the ensemble size to 2 to avoid introducing other factors. We train two full teacher models, $T_{1}^{\mathrm{full}}$ and $T_{2}^{\mathrm{full}}$ , with 200 epochs independently, and save their intermediate models, $T_{1}^{\mathrm{inter}}$ and $T_{2}^{\mathrm{inter}}$ , at the $100^{\mathrm{th}}$ epoch. For the Full Ensemble, we construct an ensemble with $T_{1}^{\mathrm{full}}$ and $T_{2}^{\mathrm{full}}$ . For the Snapshot Ensemble, we build an ensemble with one full teacher model $T_{1}^{\mathrm{full}}$ and its intermediate model $T_{1}^{\mathrm{inter}}$ . We use $T_{1}^{\mathrm{full}} + T_{2}^{\mathrm{full}}$ and $T_{1}^{\mathrm{inter}} + T_{1}^{\mathrm{full}}$ to represent the Full Ensemble and the Snapshot Ensemble, respectively. To further explore the intermediate and full models, we add an additional evaluation object, an ensemble with one intermediate model $T_{1}^{\mathrm{inter}}$ and one extra full teacher model $T_{2}^{\mathrm{full}}$ from another training trajectory. Such combination is represented as $T_{1}^{\mathrm{inter}} + T_{2}^{\mathrm{full}}$ .
+
+Table 2 shows two observations: 1) For the ensemble performance, $T_{1}^{\mathrm{full}} + T_{2}^{\mathrm{full}} > T_{1}^{\mathrm{inter}} + T_{2}^{\mathrm{full}} > T_{1}^{\mathrm{full}} + T_{1}^{\mathrm{inter}}$ is consistently true; 2) For the distillation performance, $T_{1}^{\mathrm{inter}} + T_{1}^{\mathrm{full}}$ and $T_{1}^{\mathrm{inter}} + T_{2}^{\mathrm{full}}$
+
+have similar performance, but significantly outperform $T_{1}^{\mathrm{full}} + T_{2}^{\mathrm{full}}$ . In average, the accuracy of Full Ensembles is $3.11\%$ higher than that of Snapshot Ensembles, but the distillation accuracy of the former is $0.52\%$ lower the latter. Comprehensively considering training cost and distillation performance, the Snapshot Ensemble ( $T_{1}^{\mathrm{full}} + T_{1}^{\mathrm{inter}}$ ) is the best choice.
+
+To further verify this cognition, we conduct an ablation experiment of the ensemble size $k$ on CIFAR-100. We adopt WRN-40-2/WRN-40-1 as the teacher-student pair. The Full Ensemble is composed of $k$ full teacher models, while the Snapshot Ensemble is composed of 1 full teacher model and its $k - 1$ intermediate models. For simplicity, the training process of a full teacher model is averagely divided into $k$ phases to obtain the $k - 1$ intermediate models. We evaluate the test accuracy of distilled students and the total training cost, which consists of training teachers and distilling the student. Figure 3 shows two phenomena. 1) The distillation performance of the Snapshot Ensemble is significantly better than that of the Full Ensemble, with the same ensemble size $k$ . 2) The training cost of the Snapshot Ensemble is significantly lower than that of the Full Ensemble, with the same ensemble size $k$ . Hence, Snapshot Ensemble
+
+bles can be more economical and efficient in the KD setting. Combining Table 2 and Figure 3, we obtain the second counterintuitive conclusion:
+
+
+Figure 3: An ablation experiment of ensemble size $(k = 1,2,4,7,10)$ on CIFAR-100. We estimate the training hours on TITAN Xp.
+
+Observation 2. A stronger ensemble does not always lead to a better distillation. In particular, the Snapshot Ensemble has worse ensemble performance and lower training cost but better distillation performance than the Full Ensemble.
+
+# 4 Knowledge Distillation and Information Bottleneck
+
+We have observed that the student's accuracy first increases and then decreases while the teacher's accuracy increases monotonically, as a function of the training epoch of the teacher (as shown in Figure 2). In this section, we aim to understand this phenomenon using the IB principle proposed in [14]. The effect of mutual information on distillation performance is analyzed theoretically and experimentally, and further verified with class correlation information.
+
+# 4.1 Connection knowledge distillation with information bottleneck
+
+Tishby and Zaslavsky [14] proposed that layered neural networks form a Markov chain of successive representations of the input, and explained the optimization goal of DNNs with the IB principle. They claimed that DNNs tend to obtain an efficient representation of the input, capturing the features relevant to the output and compressing those irrelevant. Formally, for a DNN, define the input variable $X$ and desired output variable $Y$ . Any representation of the input $F$ , is defined through an encoder $P(F|X)$ , and a decoder $P(Y|F)$ . The optimization goal of the network can be described as the following IB trade-off optimization problem [29]:
+
+$$
+\min _ {F} \left\{I (X; F) - \beta I (F; Y) \right\}, \tag {3}
+$$
+
+where $I(X;F)$ represents the mutual information between $X$ and $F$ , $I(F;Y)$ represents the mutual information between $F$ and $Y$ , $\beta$ is a positive trade-off parameter. From a perspective of information theory, knowledge transfer can be expressed as retaining high mutual information between the teacher and student networks (proposed in VID [42]). Following Eq. (3), we define the representation of the teacher model $F_{t}$ , the representation of the student model $F_{s}$ . The optimization goal of the student model in KD setting can be described as follows:
+
+$$
+\min _ {s} \left\{I \left(X; F _ {s}\right) - \beta I (Y; F _ {s}) - \gamma I \left(F _ {t}; F _ {s}\right) \right\}, \tag {4}
+$$
+
+
+Figure 4: The mutual information curves on the information plane. The red lines represent teacher models. The dark blue $\star$ represents $T^{\mathrm{full}}$ while the light blue $\star$ represents $T^{\mathrm{inter}}$ . The gray, dark blue and light blue lines represent students, distilled students with $T^{\mathrm{full}}$ and distilled students with $T^{\mathrm{inter}}$ . The yellow areas are the observation areas. A full teacher compresses $I(X;F)$ of student, while an intermediate teacher slows down the compression (a) or even amplifies $I(X;F)$ of student (b).
+
+
+
+where $\gamma$ is a positive trade-off parameter. $I(F_{t};F_{s})$ represents the mutual information between the teacher and the student. $F_{t}$ and $F_{s}$ can be quantified by their coordinates: $(I(X;F_t),I(Y;F_t))$ and $(I(X;F_s),I(Y;F_s))$ on the information plane. Hence, maximizing $I(F_{t};F_{s})$ can evolve into minimizing $|I(X;F_t) - I(X;F_s)| + |I(Y;F_t) - I(Y;F_s)|$ . Then, we can reformulate Eq. (4) to
+
+$$
+\begin{array}{l} \min _ {s} \left\{I (X; F _ {s}) - \beta I (Y; F _ {s}) + \gamma | I (X; F _ {t}) - I (X; F _ {s}) | \right. \\ + \gamma | I (Y; F _ {t}) - I (Y; F _ {s}) | \}, \\ \end{array}
+$$
+
+where how to remove the absolute value signs depends on the relative location of the coordinates $(I(X;F_t),I(Y;F_t))$ and $(I(X;F_s),I(Y;F_s))$ on the mutual information plane.
+
+# 4.2 Mutual Information Analysis
+
+In order to explore the role of mutual information in knowledge distillation, we quantitatively analyze the mutual information curves of different teacher-student pairs. In practice, following [43], we adopt the test accuracy to quantify $I(Y;F)$ and a reconstruction loss to quantify $I(X;F)$ . To get the reconstruction loss, we connect a decoder following the last convolution layer of the network model to reconstruct the input $X$ . We adopt WRN-40-2/WRN-40-1 and ResNet110/ResNet32 pairs on CIFAR-100. We train each teacher model for 200 epochs to get a full model $T^{\mathrm{full}}$ and save the intermediate model $T^{\mathrm{inter}}$ at the $100^{th}$ epoch. Detailed settings are given in Appendix B.1. The mutual information curves of teacher model, student model, distilled student models with $T^{\mathrm{full}}$ and $T^{\mathrm{inter}}$ are shown in Figure 4. Some important observations and inferences are summarized.
+
+1) The trend of all curves is similar to that shown in [29] and consistent with IB principle [14]. That is, $I(X;F)$ first goes up and then goes down while $I(Y;F)$ goes up monotonically. It can be interpreted as: for $I(X;F)$ , networks first absorb information of the input $X$ and later eliminate part of the information irrelevant to the target output $Y$ ; for $I(Y;F)$ , networks continuously accumulate information relevant to the target output $Y$ .
+2) The curve of a large teacher model is usually on the right of the curve of a small student model. It means a large model generally has greater ability of information representation.
+3) The full model $T^{\mathrm{full}}$ compresses more $I(X;F)$ but retains more $I(Y;F)$ than the intermediate model $T^{\mathrm{inter}}$ . That is to say, a full model may discard more information of non-target classes from $X$ .
+4) The student models distilled with $T^{\mathrm{full}}$ further compress $I(X;F)$ (the dark blue curves are on the left of the gray curves in Figure 4), while those distilled with $T^{\mathrm{inter}}$ slow down the compression of $I(X;F)$ (the light blue curve in Figure 4(a)) or even amplify $I(X;F)$ (the light blue curve in Figure 4(b)). Retaining more $I(X;F)$ seems to be a key factor to get a competitive performance from $T^{\mathrm{inter}}$ .
+
+For a full teacher with a large $I(Y;F_t)$ but a small $I(X;F_t)$ , Eq. (5) is reformulated to
+
+$$
+\min _ {s} \left\{\left(1 + \gamma\right) I \left(X; F _ {s}\right) - (\beta + \gamma) I \left(Y; F _ {s}\right) \right\}. \tag {6}
+$$
+
+
+(a) Logits; Epoch = 100
+
+
+(b) Logits; Epoch = 200
+Figure 5: The heatmaps of class correlation information on the intermediate model (at the $100^{\mathrm{th}}$ epoch) and the full model (at the $200^{\mathrm{th}}$ epoch) on the CIFAR-100 dataset. (a) and (b) are calculated with the logits output; (c) and (d) are calculated with the softened softmax output (temperature is 5). More brightly colored areas mean that the intermediate model has more diversity than the full model.
+
+
+(c) Softmax $\tau = 5$ ; Epochh = 100
+
+
+(d) Softmax $\tau = 5$ ; Epoch $\mathrm{ch} = 200$
+
+For a suitable intermediate teacher model with a large $I(Y;F_t)$ and a large $I(X;F_t)$ , Eq. (5) is reformulated to
+
+$$
+\min _ {s} \left\{\left(1 - \gamma\right) I \left(X; F _ {s}\right) - (\beta + \gamma) I \left(Y; F _ {s}\right) \right\}. \tag {7}
+$$
+
+Comparing Eq. (6) and Eq. (7), the difference is that a full teacher model accelerates the compression of $I(X;F_s)$ while the intermediate model alleviates the compression of $I(X;F_s)$ . This is consistent with our $4^{th}$ observation. Therefore, we can reasonably assume that: more mutual information with the input data can be the main reason why an intermediate teacher model achieves better distillation performance than a full teacher model.
+
+Compared with a full model, a suitable intermediate model has more $I(X;F)$ and less $I(Y;F)$ , which means that the intermediate model has more non-target classes information. To do further analysis, we use heatmaps of cosine similarity to visualize the class correlation information contained in the intermediate model and the full model. For CIFAR-100, a heatmap is a $100 \times 100$ matrix $A$ , where each element $A_{ij}$ represents the similarity between corresponding two classes. Specifically, we represent a class $c_i$ by its average logits or softmax output on the test set (a 100-dimensional vector $V_{c_i}$ ) and then calculate the cosine similarity $A_{ij}$ between $c_i$ and $c_j$ with the following equation:
+
+$$
+A _ {i j} = \frac {\left\langle V _ {c _ {i}} , V _ {c _ {j}} \right\rangle}{\left\| V _ {c _ {i}} \right\| \left\| V _ {c _ {j}} \right\|}. \tag {8}
+$$
+
+Figure 5 shows some heatmaps of cosine similarity on the intermediate model and the full model. The network structure is WRN-40-2. Comparing Figure 5(a) with (b), we can see that the logits output of the intermediate model has better diversity than that of the full model. Comparing Figure 5(c) with (d), while using a softened softmax output with a higher temperature can increase some of the diversity between classes, the intermediate model still shows a wider range of class correlation information than the full model. Results of the class correlation information further support that a suitable intermediate teacher has more non-target classes information than a full teacher, which is consistent with the mutual information analysis.
+
+# 4.3 Label smoothing regularization and knowledge distillation
+
+The previous work [25] proposed that label smoothing regularization (LSR) can be considered as an ad-hoc KD with a pre-defined uniform distribution teacher. Mathematically for LSR, a uniform distribution $u$ is used in place of $P_{\mathrm{T}^{\mathrm{full}}}^{\tau}$ in Eq. (1). We attempt to explore the connection between LSR and KD from the IB perspective. Obviously, the uniform distribution $u$ has a small $I(Y;F_t)$ and a small $I(X;F_t)$ . Eq. (5) is reformulated to
+
+$$
+\min _ {s} \left\{\left(1 + \gamma\right) I \left(X; F _ {s}\right) - (\beta - \gamma) I \left(Y; F _ {s}\right) \right\}, \tag {9}
+$$
+
+where $\beta -\gamma$ must be positive to keep the optimization direction correct. Comparing Eq. (6) and Eq. (9), if we fix the coefficient of the second term $I(Y;F_s)$ to be 1, then the coefficient of the first term is $(1 + \gamma) / (\beta +\gamma)$ in Eq. (6) and $(1 + \gamma) / (\beta -\gamma)$ in Eq. (9). It means that LSR accelerates the compression of $I(X;F_s)$ . In order to verify it visually, keeping the same setting as Figure 4, we add LSR to the student model and show its mutual information curve on the information plane. As shown in Figure 6, both the dark blue curve (the normal KD) and the yellow curve (LSR) are on the left of the gray curve (the student model). It means that both the normal KD and LSR play a similar role to
+
+
+Figure 6: The mutual information curves on the information plane. The red curves represent the teacher model. The gray, dark blue and light blue curves represent the students, distilled students with full teacher and distilled students with intermediate teacher. The yellow curves represent student training with LSR. The yellow areas are the observation areas.
+
+
+
+compress the student model's mutual information with respect to input, which supports the view in [25]. However, there is a big gap between the dark blue curve and the yellow curve, which means that the normal KD transfers more relevant information with input to the student model than the LSR does. For the distillation performance, $T^{\mathrm{inter}} > T^{\mathrm{full}} > u$ is consistent with the amount of $I(X;F_t)$ of the teacher models, which further supports our view in Sec. 4.2.
+
+# 5 Optimal Intermediate Model Selection
+
+As shown in Figure 2 and Figure 4, how to capture the optimal intermediate model is a nontrivial problem. An empirical conclusion is that a good intermediate model needs delicate tradeoff between $I(X;F)$ and $I(Y;F)$ . From the point of information entropy, the representation $F$ of model consists of information concerning the input $X$ , the output $Y$ and nuisance $Z$ which is irrelevant to the task [15]. A formal description of the entropy of $F$ is:
+
+$$
+H (F) = I (X; F) + I (Y; F) + Z. \tag {10}
+$$
+
+To reduce the nuisance $Z$ and get a more informative intermediate teacher model, we solve the following optimization problem:
+
+$$
+\max _ {F} \left\{I (X; F) + I (Y; F) \right\}, \tag {11}
+$$
+
+where $F$ belongs to the set of representations in intermediate teacher models. Figure 7 is an example of the selecting process. The optimal solution is usually located in the upper right corner of the information plane. Based on the selecting strategy, we propose an algorithm to find the optimal intermediate teacher for effec
+
+tive distillation as shown in Algorithm 1. Note that the value of mutual information $I(X;F)$ and $I(Y;F)$ is normalized to ensure the scale matching. Obtaining the optimal intermediate teacher model, standard KD or other mainstream KD methods can be conducted as usual.
+
+To verify the superiority of the optimal intermediate model selection strategy, we conduct comparison experiments on the CIFAR-100 dataset. We keep the same experimental settings as in Sec. 3.3, but save teacher's checkpoints every 10 epochs. For each checkpoint, the information theoretic quantities $I(X;F)$ and $I(Y;F)$ are estimated as in Sec. 4.2. Then, we normalize $I(X;F)$ and $I(Y;F)$ , and draw the mutual information curves. By algorithm 1, the optimal intermediate teacher models $T^{*}$ of WRN-40-2 and ResNet-110 are selected at the $160^{\mathrm{th}}$ and $120^{\mathrm{th}}$ epochs respectively. An
+
+
+Figure 7: An example of selecting the optimal intermediate teacher $T^{\mathrm{inter}}$ . The red line represents the normalized mutual information curve of the teacher model (WRN-40-2). The blue lines represent the selecting process. The star $\star$ represents the optimal intermediate teacher $T^{*}$ whose representation maximizes $\{I(X;F) + I(Y;F)\}$ .
+
+# Algorithm 1 Distillation with the optimal intermediate teacher.
+
+1: Train a teacher model $T$ from scratch and save its checkpoint $T_{i}$ every M epochs;
+2: Calculating the normalized $I(X;F)$ and $I(Y;F)$ of each $T_{i}$ ;
+3: Draw the mutual information curve of $T$ ;
+4: Find the optimal $T^{*}$ which has the representation that maximizes $\{I(X;F) + I(Y;F)\}$ ;
+5: Take $T^{*}$ as the teacher model to do distillation.
+
+Table 3: KD Results of the optimal intermediate models on CIFAR-100. The intermediate teacher models are selected at different epochs. The best results are bold-faced.
+
+| Network structure | Accuracy of T&S | KD accuracy of different intermediate teachers |
| T | S | T | S | \(T^{0.3}\) | \(T^{0.5}\) | \(T^{0.7}\) | \(T^{\text{full}}\) | \(T^{*}\) |
| WRN-40-2 | WRN-40-1 | 76.53 | 70.38 | 72.34±0.10 | 72.76±0.24 | 73.08±0.05 | 72.68±0.10 | 73.26±0.03 |
| MobileNetV2 | 64.49 | 68.21±0.33 | 68.99±0.12 | 68.54±0.07 | 68.03±0.34 | 68.58±0.34 |
| ResNet-110 | ResNet-32 | 73.41 | 70.16 | 70.74±0.18 | 72.49±0.32 | 72.46±0.30 | 72.48±0.22 | 72.63±0.13 |
| MobileNetV2 | 64.49 | 67.84±0.26 | 68.79±0.17 | 69.01±0.20 | 68.63±0.35 | 68.99±0.33 |
| Average | 74.97 | 67.38 | 69.78 | 70.76 | 70.77 | 70.46 | 70.87 |
+
+empirical conclusion is that the optimal intermediate model for each teacher model may be different. To evaluate the distillation performance of $T^{*}$ , we pick out models at the $60^{\mathrm{th}}$ , $100^{\mathrm{th}}$ , $140^{\mathrm{th}}$ , $200^{\mathrm{th}}$ epoch, which are denoted by $T^{0.3}$ , $T^{0.5}$ , $T^{0.7}$ and $T^{\mathrm{full}}$ as baselines. We adopt the same standard KD method [2] but different intermediate models as teachers. Table 3 shows that $T^{*}$ has the best average performance, which validates the effectiveness and adaptability of our selection strategy. In addition, $T^{0.7}$ and $T^{0.5}$ also have better average performance than $T^{\mathrm{full}}$ . If you think that selecting the optimal intermediate model is tedious, the half-way checkpoint may be your prefer.
+
+# 6 Conclusion and Limitations
+
+In this paper, we made an observation that an intermediate model can have richer "dark knowledge" than a fully converged model, and employed the IB principle to partially interpret this phenomenon. We argue that over-training of the teacher model results in the suppression of class correlation information, leading to degradation of the distillation performance. As a result, training a fully converged teacher may not be the optimal choice, especially under resource-limited circumstances. To save training cost, we empirically suggest that the half-way teacher model can suffice. To achieve better distillation, we further proposed an optimal intermediate model selection algorithm to find the appropriate intermediate teacher. Furthermore, this work implies a more economical and efficient way to construct a snapshot ensemble with several intermediate models from the same training trajectory instead of the standard ensemble with independently full-trained models. This technique can significantly improve the ensemble model's distillation performance and reduce the training cost.
+
+Our study also has some limitations. First, the selection of an optimal intermediate model considers the information entropy of the teacher but ignores the variation of the student structures, which can not ensure the optimal KD performance for all teacher-student pairs. Second, how to choose the best intermediate teacher model for a specific structure of student is still a challenging problem.
+
+# Acknowledgement
+
+This work is supported in part by the National Key R&D Program of China under Grant 2020AAA0105200, the National Natural Science Foundation of China under Grants 62022048, THU-Bosch JCML and Beijing Academy of Artificial Intelligence. We also appreciate the generous donation of computing resources by High-Flyer AI.
+
+# References
+
+[1] Cristian Bucila, Rich Caruana, and Alexandru Niculescu-Mizil. Model compression. In KDD '06, 2006.
+[2] Geoffrey E. Hinton, Oriol Vinyals, and Jeffrey Dean. Distilling the knowledge in a neural network. CoRR, abs/1503.02531, 2015.
+[3] Tommaso Furlanello, Zachary Chase Lipton, Michael Tschannen, Laurent Itti, and Anima Anandkumar. Born-again neural networks. In ICML, 2018.
+[4] Ying Zhang, Tao Xiang, Timothy M. Hospedales, and Huchuan Lu. Deep mutual learning. In CVPR, 2018.
+[5] Shan You, Chang Xu, Chao Xu, and Dacheng Tao. Learning from multiple teacher networks. In KDD, 2017.
+[6] Defang Chen, Jian-Ping Mei, Can Wang, Yan Feng, and Chun Chen. Online knowledge distillation with diverse peers. In AAAI, 2020.
+[7] Zheng Li, Ying Huang, Defang Chen, Tianren Luo, Ning Cai, and Zhigeng Pan. Online knowledge distillation via multi-branch diversity enhancement. In ACCV(4), 2020.
+[8] Seyed-Iman Mirzadeh, Mehrdad Farajtabar, Ang Li, Nir Levine, Akihiro Matsukawa, and Hassan Ghasemzadeh. Improved knowledge distillation via teacher assistant. In AAAI, 2020.
+[9] Mengya Gao, Yujun Shen, Quanquan Li, and Chen Change Loy. Residual knowledge distillation. CoRR, abs/2002.09168, 2020.
+[10] Chenglin Yang, Lingxi Xie, Siyuan Qiao, and Alan L Yuille. Training deep neural networks in generations: A more tolerant teacher educates better students. In AAAI, volume 33, pages 5628-5635, 2019.
+[11] Dae Young Park, Moon-Hyun Cha, Daesin Kim, Bohyung Han, et al. Learning student-friendly teacher networks for knowledge distillation. NeurIPS, 34, 2021.
+[12] Jang Hyun Cho and Bharath Hariharan. On the efficacy of knowledge distillation. In ICCV, pages 4794-4802, 2019.
+[13] Gao Huang, Yixuan Li, Geoff Pleiss, Zhuang Liu, John E. Hopcroft, and Kilian Q. Weinberger. Snapshot ensembles: Train 1, get M for free. In ICLR (Poster), 2017.
+[14] Naftali Tishby and Noga Zaslavsky. Deep learning and the information bottleneck principle. In ITW, 2015.
+[15] Alessandro Achille and Stefano Soatto. Emergence of invariance and disentanglement in deep representations. In ITA, 2018.
+[16] Jianping Gou, Baosheng Yu, Stephen J Maybank, and Dacheng Tao. Knowledge distillation: A survey. International Journal of Computer Vision, 129(6):1789-1819, 2021.
+[17] Adriana Romero, Nicolas Ballas, Samira Ebrahimi Kahou, Antoine Chassang, Carlo Gatta, and Yoshua Bengio. Fitnets: Hints for thin deep nets. In ICLR (Poster), 2015.
+[18] Sergey Zagoruyko and Nikos Komodakis. Paying more attention to attention: Improving the performance of convolutional neural networks via attention transfer. In *ICLR (Poster)*, 2017.
+[19] Chaofei Wang, Jiayu Xiao, Yizeng Han, Qisen Yang, Shiji Song, and Gao Huang. Towards learning spatially discriminative feature representations. In ICCV, pages 1326-1335, 2021.
+[20] Junho Yim, Donggyu Joo, Ji-Hoon Bae, and Junmo Kim. A gift from knowledge distillation: Fast optimization, network minimization and transfer learning. In CVPR, 2017.
+[21] Frederick Tung and Greg Mori. Similarity-preserving knowledge distillation. In ICCV, 2019.
+
+[22] Baoyun Peng, Xiao Jin, Dongsheng Li, Shunfeng Zhou, Yichao Wu, Jiaheng Liu, Zhaoning Zhang, and Yu Liu. Correlation congruence for knowledge distillation. In ICCV, 2019.
+[23] Chaofei Wang, Ke Yang, Shaowei Zhang, Gao Huang, and Shiji Song. Tc3kd: Knowledge distillation via teacher-student cooperative curriculum customization. Neurocomputing, 508:284-292, 2022.
+[24] Xu Lan, Xiatian Zhu, and Shaogang Gong. Knowledge distillation by on-the-fly native ensemble. In NeurIPS, 2018.
+[25] Li Yuan, Francis E. H. Tay, Guilin Li, Tao Wang, and Jiashi Feng. Revisit knowledge distillation: a teacher-free framework. CoRR, abs/1909.11723, 2019.
+[26] Linfeng Zhang, Jiebo Song, Anni Gao, Jingwei Chen, Chenglong Bao, and Kaisheng Ma. Be your own teacher: Improve the performance of convolutional neural networks via self distillation. In ICCV, pages 3713-3722, 2019.
+[27] Chenglin Yang, Lingxi Xie, Chi Su, and Alan L Yuille. Snapshot distillation: Teacher-student optimization in one generation. In CVPR, pages 2859-2868, 2019.
+[28] Naftali Tishby, Fernando C. N. Pereira, and William Bialek. The information bottleneck method. CoRR, physics/0004057, 2000.
+[29] Ravid Shwartz-Ziv and Naftali Tishby. Opening the black box of deep neural networks via information. CoRR, abs/1703.00810, 2017.
+[30] Ziv Goldfeld, Ewout van den Berg, Kristjan H. Greenewald, Igor Melnyk, Nam Nguyen, Brian Kingsbury, and Yury Polyanskiy. Estimating information flow in deep neural networks. In ICML, 2019.
+[31] Andrew M. Saxe, Yamini Bansal, Joel Dapello, Madhu Advani, Artemy Kolchinsky, Brendan D. Tracey, and David D. Cox. On the information bottleneck theory of deep learning. In ICLR (Poster), 2018.
+[32] Roman Pogodin and Peter E. Latham. Kernelized information bottleneck leads to biologically plausible 3-factor hebbian learning in deep networks. In NeurIPS, 2020.
+[33] Anirudh Goyal, Riashat Islam, Daniel Strouse, Zafarali Ahmed, Hugo Larochelle, Matthew Botvinick, Yoshua Bengio, and Sergey Levine. Infobot: Transfer and exploration via the information bottleneck. In ICLR (Poster), 2019.
+[34] Xingyu Lu, Kimin Lee, Pieter Abbeel, and Stas Tiomkin. Dynamics generalization via information bottleneck in deep reinforcement learning. CoRR, abs/2008.00614, 2020.
+[35] Jiameng Fan and Wenchao Li. Robust deep reinforcement learning via multi-view information bottleneck. CoRR, abs/2102.13268, 2021.
+[36] Alex Krizhevsky, Geoffrey Hinton, et al. Learning multiple layers of features from tiny images. University of Toronto, 2009.
+[37] Tiny-imagenet. https://tiny-imagenet.berokuapp.com/.
+[38] Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. Imagenet: A large-scale hierarchical image database. In CVPR, 2009.
+[39] Sergey Zagoruyko and Nikos Komodakis. Wide residual networks. In BMVC, 2016.
+[40] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In CVPR, 2016.
+[41] Andrew G. Howard, Menglong Zhu, Bo Chen, Dmitry Kalenichenko, Weijun Wang, Tobias Weyand, Marco Andreetto, and Hartwig Adam. Mobilenets: Efficient convolutional neural networks for mobile vision applications. CoRR, abs/1704.04861, 2017.
+
+[42] Sungsoo Ahn, Shell Xu Hu, Andreas Damianou, Neil D Lawrence, and Zhenwen Dai. Variational information distillation for knowledge transfer. In CVPR, pages 9163-9171, 2019.
+[43] Yulin Wang, Zanlin Ni, Shiji Song, Le Yang, and Gao Huang. Revisiting locally supervised learning: an alternative to end-to-end training. In ICLR, 2021.
+[44] Min Lin, Qiang Chen, and Shuicheng Yan. Network in network. In ICLR (Poster), 2014.
+[45] Ilya Loshchilov and Frank Hutter. SGDR: stochastic gradient descent with warm restarts. In ICLR (Poster), 2017.
+[46] Yulin Wang, Zanlin Ni, Shiji Song, Le Yang, and Gao Huang. Revisiting locally supervised learning: an alternative to end-to-end training. In ICLR (Poster), 2021.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See Section 6.
+(c) Did you discuss any potential negative societal impacts of your work? [No] We could not foresee any potential negative societal impacts of our work.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes] See Section 4.
+(b) Did you include complete proofs of all theoretical results? [Yes] See Section 4.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] We provide the URL of code for reproducing the main results.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Section 3.2, Section 4.2, Section 5 and the Appendix.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] In the paper, top 1 accuracy is averagely evaluated in five independent experiments.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Figure 3 and Figure ??
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] See Section 3.2.
+(b) Did you mention the license of the assets? [No] The models and the datasets are open source.
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We provide the URL of code for reproducing the main results.
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [No] We only use open source datasets.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [No] We only use open source datasets.
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientknowledgedistillationfrommodelcheckpoints/images.zip b/efficientknowledgedistillationfrommodelcheckpoints/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..5de852e4a80e4a7003638fc07d809a53aac718a8
--- /dev/null
+++ b/efficientknowledgedistillationfrommodelcheckpoints/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2275080c90b5f457ef632c5931c8e562b9e2ef661453ba29a117ab5cbea312c1
+size 483586
diff --git a/efficientknowledgedistillationfrommodelcheckpoints/layout.json b/efficientknowledgedistillationfrommodelcheckpoints/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..e698a3e6d5c1499c00f779f11bb25208d70fb242
--- /dev/null
+++ b/efficientknowledgedistillationfrommodelcheckpoints/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:754868cd1af8a96236dc3ab71b23824853c416e85291e76c6d524dd7aa0eea11
+size 542248
diff --git a/efficientmetareinforcementlearningforpreferencebasedfastadaptation/e919076f-f1bb-4393-bd6e-ed40660f053f_content_list.json b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/e919076f-f1bb-4393-bd6e-ed40660f053f_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..8bac094234132ce3db539eef39d698b92e0cf2ac
--- /dev/null
+++ b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/e919076f-f1bb-4393-bd6e-ed40660f053f_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:53540da7af6e6a719ad197b5960445e39ac9e1dc25d5dc7a2224fd0f10c034ec
+size 83381
diff --git a/efficientmetareinforcementlearningforpreferencebasedfastadaptation/e919076f-f1bb-4393-bd6e-ed40660f053f_model.json b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/e919076f-f1bb-4393-bd6e-ed40660f053f_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..66d7f277ccaabcc2db79ee2873ee3ec14d83d2b5
--- /dev/null
+++ b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/e919076f-f1bb-4393-bd6e-ed40660f053f_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:939ed90e080612aac4f6d881393c5399f1d97b87e28b727ba1e1cf953ab59454
+size 105597
diff --git a/efficientmetareinforcementlearningforpreferencebasedfastadaptation/e919076f-f1bb-4393-bd6e-ed40660f053f_origin.pdf b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/e919076f-f1bb-4393-bd6e-ed40660f053f_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..05239b21e8484db8ec7495d0117500b18f18fab5
--- /dev/null
+++ b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/e919076f-f1bb-4393-bd6e-ed40660f053f_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a930bdf35f54bebad2f72d9f76c5fe64ee1b4cd111ab969e53c4d45faccd9312
+size 409747
diff --git a/efficientmetareinforcementlearningforpreferencebasedfastadaptation/full.md b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..c85f1deb3f7cbc9a23763942e0aee0c89c6124b2
--- /dev/null
+++ b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/full.md
@@ -0,0 +1,310 @@
+# Efficient Meta Reinforcement Learning for Preference-based Fast Adaptation
+
+Zhizhou Ren $^{12}$ , Anji Liu $^{3}$ , Yitao Liang $^{45}$ , Jian Peng $^{126}$ , Jianzhu Ma $^{6}$
+
+$^{1}$ Helixon Ltd. $^{2}$ University of Illinois at Urbana-Champaign
+
+3University of California, Los Angeles
+
+$^{4}$ Institute for Artificial Intelligence, Peking University
+
+$^{5}$ Beijing Institute for General Artificial Intelligence
+
+$^{6}$ Institute for AI Industry Research, Tsinghua University
+
+zhizhour@helixon.com, liuanji@cs.ucla.edu
+
+yitaol@pku.edu.cn, jianpeng@illinois.edu
+
+majianzhu@tsinghua.edu.cn
+
+# Abstract
+
+Learning new task-specific skills from a few trials is a fundamental challenge for artificial intelligence. Meta reinforcement learning (meta-RL) tackles this problem by learning transferable policies that support few-shot adaptation to unseen tasks. Despite recent advances in meta-RL, most existing methods require the access to the environmental reward function of new tasks to infer the task objective, which is not realistic in many practical applications. To bridge this gap, we study the problem of few-shot adaptation in the context of human-in-the-loop reinforcement learning. We develop a meta-RL algorithm that enables fast policy adaptation with preference-based feedback. The agent can adapt to new tasks by querying human's preference between behavior trajectories instead of using per-step numeric rewards. By extending techniques from information theory, our approach can design query sequences to maximize the information gain from human interactions while tolerating the inherent error of non-expert human oracle. In experiments, we extensively evaluate our method, Adaptation with Noisy OracLE (ANOLE), on a variety of meta-RL benchmark tasks and demonstrate substantial improvement over baseline algorithms in terms of both feedback efficiency and error tolerance.
+
+# 1 Introduction
+
+Reinforcement learning (RL) has achieved great success in learning complex behaviors and strategies in a variety of sequential decision-making problems, including Atari games (Mnih et al., 2015), board game Go (Silver et al., 2016), MOBA games (Berner et al., 2019), and real-time strategy games (Vinyals et al., 2019). However, most these breakthrough accomplishments are limited in simulation environments due to the sample inefficiency of RL algorithms. Training a policy using deep reinforcement learning usually requires millions of interaction samples with the environment, which is not practicable in real-world applications. One promising methodology towards breaking this practical barrier is meta reinforcement learning (meta-RL Finn et al., 2017). The goal of meta-RL is to enable fast policy adaptation to unseen tasks with a small amount of samples. Such an ability of few-shot adaptation is supported by meta-training on a suite of tasks drawn from a prior task distribution. Meta-RL algorithms can extract transferable knowledge from the meta-training experiences by exploiting the common structures among the prior training tasks. A series of recent works have been developed to improve the efficiency of meta-RL in several aspects, e.g., using off-policy techniques to improve the sample efficiency of meta-training (Rakelly et al., 2019; Fakoor et al., 2020), and refining the exploration-exploitation trade-off during adaptation (Zintgraf et al.,
+
+2020; Liu et al., 2021). There are also theoretical works studying the notion of few-shot adaptation and knowledge reuse in RL problems (Brunskill and Li, 2014; Wang et al., 2020; Chua et al., 2021).
+
+While recent advances remarkably improve the sample efficiency of meta-RL algorithms, little work has been done regarding the type of supervision signals adopted for policy adaptation. The adaptation procedure of most meta-RL algorithms is implemented by either fine-tuning policies using new trajectories (Finn et al., 2017; Fakoor et al., 2020) or inferring task objective from new reward functions (Duan et al., 2016; Rakelly et al., 2019; Zintgraf et al., 2020), both of which require the access to the environmental reward function in new tasks to perform adaptation. Such a reward-driven adaptation protocol may become impracticable in many application scenarios. For instance, when a meta-trained robot is designed to provide customizable services for non-expert human users (Prewett et al., 2010), it is not realistic for the meta-RL algorithm to obtain per-step reward signals directly from the user interface. The design of reward function is a long-lasting challenge for reinforcement learning (Sorg et al., 2010), and there is no general solution to specify rewards for a particular goal (Amodei et al., 2016; Abel et al., 2021). Existing techniques can support reward-free meta-training by constructing a diverse policy family through unsupervised reward generation (Gupta et al., 2020), and reward-free few-shot policy adaptation remains a challenge (Liu et al., 2020).
+
+In this paper, we study the interpolation of meta-RL and human-in-the-loop RL, towards expanding the applicability of meta-RL in practical scenarios without environmental rewards. We pursue the few-shot adaptation from human preferences (Furnkranz et al., 2012), where the agent infers the objective of new tasks by querying a human oracle to compare the preference between pairs of behavior trajectories. Such a preference-based supervision is more intuitive than numeric rewards for human users to instruct the meta policy. e.g., the human user can watch the videos of two behavior trajectories and label a preference order to express the task objective (Christiano et al., 2017). The primary goal of such a preference-based adaptation setting is to suit the user's preference with only a few preference queries to the human oracle. Minimizing the burden of interactions is a central objective of human-in-the-loop learning. In addition, we require the adaptation algorithm to be robust when the oracle feedback carries some noises. The human preference is known to have some extent of inconsistency (Loewenstein and Prelec, 1992), and the human user may also make unintentional mistakes when responding to preference queries. The tolerance to feedback error is an important evaluation metric for preference-based reinforcement learning (Lee et al., 2021a).
+
+To develop an efficient and robust adaptation algorithm, we draw a connection with a classical problem called Rényi-Ulam's game (Rényi, 1961; Ulam, 1976) from information theory. We model the preference-based task inference as a noisy-channel communication problem, where the agent communicates with the human oracle and infers the task objective from the noisy binary feedback. Through this problem transformation, we extend an information quantification called Berlekamp's volume (Berlekamp, 1968) to measure the uncertainty of noisy preference feedback. This powerful toolkit enables us to design the query contents to maximize the information gain from the noisy preference oracle. We implement our few-shot adaptation algorithm, called Adaptation with Noisy Oracle (ANOLE), upon an advanced framework of probabilistic meta-RL (Rakelly et al., 2019) and conduct extensive evaluation on a suite of Meta-RL benchmark tasks. The experiment results show that our method can effectively infer the task objective from limited interactions with the preference oracle and, meanwhile, demonstrate robust error tolerance against the noisy feedback.
+
+# 2 Preliminaries
+
+# 2.1 Problem Formulation of Meta Reinforcement Learning
+
+Task Distribution. The same as previous meta-RL settings (Rakelly et al., 2019), we consider a task distribution $p(\mathcal{T})$ where each task instance $\mathcal{T}$ induces a Markov Decision Process (MDP). We use a tuple $\mathcal{M}_{\mathcal{T}} = \langle S, \mathcal{A}, T, R_{\mathcal{T}} \rangle$ to denote the MDP specified by task $\mathcal{T}$ . In this paper, we assume task $\mathcal{T}$ does not vary the environment configuration, including state space $S$ , action space $\mathcal{A}$ , and transition function $T(s' \mid s, a)$ . Only reward function $R_{\mathcal{T}}(\cdot \mid s, a)$ conditions on task $\mathcal{T}$ , which defines the agent's objectives for task-specific goals. The meta-RL algorithm is allowed to sample a suite of training tasks $\{\mathcal{T}_i\}_{i=1}^N$ from the task distribution $p(\mathcal{T})$ to support meta-training. In the meta-testing phase, a new set of tasks are drawn from $p(\mathcal{T})$ to evaluate the adaptation performance.
+
+Preference-based Adaptation. We study the few-shot adaptation with preference-based feedback, in which the agent interacts with a black-box preference oracle $\Omega_{\mathcal{T}}$ rather than directly receiving task-specific rewards from the environment $\mathcal{M}_{\mathcal{T}}$ for meta-testing adaptation. More specifically, the agent can query the preference order of a pair of trajectories $\langle \tau^{(1)},\tau^{(2)}\rangle$ through the black-box oracle $\Omega_{\mathcal{T}}$ . Each trajectory is a sequence of observed states and agent actions, denoted by $\tau = \langle s_0,a_0,s_1,a_1,\dots ,s_L\rangle$ where $L$ is the trajectory length. For each query trajectory pair $\langle \tau^{(1)},\tau^{(2)}\rangle$ , the preference oracle $\Omega_{\mathcal{T}}$ would return either $\tau^{(1)}\succ \tau^{(2)}$ or $\tau^{(1)}\prec \tau^{(2)}$ according to the task specification $\mathcal{T}$ , where $\tau^{(1)}\succ \tau^{(2)}$ means the oracle prefers trajectory $\tau^{(1)}$ to trajectory $\tau^{(2)}$ under the context of task $\mathcal{T}$ . When the preference orders of $\tau^{(1)}$ and $\tau^{(2)}$ are equal, both returns are valid. The preference-based adaptation is a weak-supervision setting in comparison with previous meta-RL works using per-step reward signals for few-shot adaptation (Finn et al., 2017; Rakelly et al., 2019). The purpose of this adaptation setting is to simulate the practical scenarios with human-in-the-loop supervision (Wirth et al., 2017; Christiano et al., 2017). We consider two aspects to evaluate the ability of an adaptation algorithm:
+
+- Feedback Efficiency. The central goal of meta-RL is conducting fast adaptation to unseen tasks with a few task-specific feedback. We consider the adaptation efficiency in terms of the number of preference queries to oracle $\Omega_{\mathcal{T}}$ . This objective expresses the practical demand that we aim to reduce the burden of preference oracle since human feedback is expensive.
+- Error Tolerance. Another performance metric is on the robustness against the noisy oracle feedback. The preference oracle $\Omega_{\mathcal{T}}$ may carry errors in practice, e.g., the human oracle may misunderstand the query message and give wrong feedback. Tolerating such oracle errors is a practical challenge for preference-based reinforcement learning.
+
+# 2.2 Meta Reinforcement Learning with Probabilistic Task Embedding
+
+Latent Task Embedding. We follow the algorithmic framework of Probabilistic Embeddings for Actor-critic RL (PEARL; Rakelly et al., 2019). The task specification $\mathcal{T}$ is modeled by a latent task variable (or latent task embedding) $z\in \mathcal{Z} = \mathbb{R}^d$ where $d$ denotes the dimension of the latent space. With this formulation, the overall paradigm of the meta-training procedure resembles a multi-task RL algorithm. Both policy $\pi (a|s;z)$ and value function $Q(s,a;z)$ condition on the latent task variable $z$ so that the representation of $z$ can be end-to-end learned with the RL objective to distinguish different task specifications. During meta-testing, the adaptation is performed in the low-dimensional task embedding space rather than the high-dimensional parameter space.
+
+Adaptation via Probabilistic Inference. To infer the task embedding $z$ from the latent task space, PEARL trains an inference network (or context encoder) $q(z|\mathbf{c})$ where $\mathbf{c}$ is the context information including agent actions, observations, and rewards. The output of $q(z|\mathbf{c})$ is probabilistic, i.e., the agent has a probabilistic belief over the latent task space $\mathcal{Z}$ based on its observations and received rewards. We use $q(z)$ to denote the prior distribution for $\mathbf{c} = \emptyset$ . The adaptation protocol of PEARL follows the framework of posterior sampling (Strens, 2000). The agent continually updates its belief by interacting with the environment and refine its policy according to the belief state. This algorithmic framework is generalized from Bayesian inference (Thompson, 1933) and has solid background in reinforcement learning theory (Agrawal and Goyal, 2012; Osband et al., 2013; Russo and Van Roy, 2014). However, some recent works show that the empirical performance of neural inference networks highly rely on the access to a dense reward function (Zhang et al., 2021; Hua et al., 2021). When the task-specific reward signals are sparsely distributed along the agent trajectory, the task inference given by context encoder $q(z|\mathbf{c})$ would suffer from low sample efficiency and cannot accurately decode task specification. This issue may worsen in our adaptation setting since only trajectory-wise preference comparisons are available to the agent. It motivates us to explore new methodology for few-shot adaptation beyond classical approaches based on posterior sampling.
+
+# 3 Preference-based Fast Adaptation with A Noisy Oracle
+
+In this section, we will introduce our method, Adaptation with Noisy OracLE (ANOLE), a novel task inference algorithm for preference-based fast adaptation. The goal of our approach is to achieve both high feedback efficiency and error tolerance.
+
+# 3.1 Connecting Preference-based Task Inference with Rényi-Ulam's Game
+
+To give an information-theoretic view on the task inference problem with preference feedback, we connect our problem setting with a classical problem called Renyi-Ulam's Game (Renyi, 1961; Ulam, 1976) from information theory to study the interactive learning procedure with a noisy oracle.
+
+Definition 1 (Rényi-Ulam's Game). There are two players, called $A$ and $B$ , participating the game. Player $A$ thinks of something in a predefined element universe, and player $B$ would like to guess it. To extract information, player $B$ can ask some questions to player $A$ , and the answers to these questions are restricted to "yes/no". A given percentage of player $A$ 's answers can be wrong, which requires player $B$ 's question strategy to be error-tolerant.
+
+In the literature of information theory, Rényi-Ulam's game specified in Definition 1 is developed to study the error-tolerant communication protocol for noisy channels (Shannon, 1956; Rényi and Makkai-Bencsath, 1984). Most previous works on Rényi-Ulam's game focus on the error tolerance of player B's question strategy, i.e., how to design the question sequence to maximize the information gain from the noisy feedback (Pelc, 2002). In this paper, we consider the online setting of Rényi-Ulam's game, where player B is allowed to continually propose queries based on previous feedback.
+
+We draw a connection between Rényi-Ulam's game and preference-based task inference. In the context of preference-based meta adaptation, the task inference algorithm corresponds to the questioner player B, and the preference oracle $\Omega$ plays the role of responder player A. The preference feedback given by oracle $\Omega$ is a binary signal regarding the comparison between two trajectories, which has the same form as the "yes/no" feedback in Rényi-Ulam's game. The goal of the task inference algorithm is to search for the true task specification in the task space using minimum number of preference queries while tolerating the errors in oracle feedback. The similarity in problem structures motivates us to extend techniques from Rényi-Ulam's game to preference-based task inference.
+
+# 3.2 An Algorithmic Framework for Preference-based Fast Adaptation
+
+In this section, we discuss how we transform the preference-based task inference problem to Rényi-Ulam's game and introduce the basic algorithmic framework of our approach to perform few-shot adaptation with a preference oracle.
+
+Transformation to Rényi-Ulam's Game. The key step of the problem transformation is establishing the correspondence between the preference query in preference-based task inference and the natural-language-based questions in Rényi-Ulam's game. In classical solutions of Rényi-Ulam's game, a general format of player B's questions is to ask whether the element in player A's mind belongs to a certain subset of the element universe (Pelc, 2002), whereas the counterpart of question format in preference-based task inference is restricted to querying whether the oracle prefers one trajectory to another. To bridge this gap, we use a model-based approach to connect the oracle preference feedback with the latent space of task embeddings. We train a preference predictor $f_{\psi}(\cdot; z)$ that predicts the oracle preference according to the task embedding $z$ . This preference predictor can transform each oracle preference feedback to a separation on the latent task space, i.e., the preference prediction $f_{\psi}(\cdot; z)$ given by task embeddings in a subspace of $z$ can match the oracle feedback, and the task embeddings in the complementary subspace lead to wrong predictions. Through this transformation, the task inference algorithm can convert the binary preference feedback to the assessment of a subspace of latent task embeddings, which works in the same mechanism as previous solutions to Rényi-Ulam's game.
+
+To realize the problem transformation, we consider a simple and direct implementation of the preference predictor. We train $f_{\psi}(\cdot ;z)$ on the meta-training tasks by optimizing the preference loss:
+
+$$
+\mathcal {L} ^ {\operatorname {P r e f}} (\psi) = \mathbb {E} \left[ D _ {\mathrm {K L}} \left(\mathbb {I} \left[ \tau^ {(1)} \succ \tau^ {(2)} \mid \mathcal {T} \right] \| f _ {\psi} \left(\tau^ {(1)} \succ \tau^ {(2)}; z\right)\right) \right], \tag {1}
+$$
+
+where $\psi$ denotes the parameters of the preference predictor, $D_{\mathrm{KL}}(\cdot \| \cdot)$ denotes the Kullback-Leibler divergence, and $\mathbb{I}[\tau^{(1)}\succ \tau^{(2)}\mid \mathcal{T}]$ is the ground-truth preference order specified by the task specification $\mathcal{T}$ (e.g., specified by the reward function on training tasks). The trajectory pair $\langle \tau^{(1)},\tau^{(2)}\rangle$ is drawn from the experience buffer, and $z$ is the task embedding vector encoding $\mathcal{T}$ . More implementation details are included in Appendix B.2.
+
+Basic Algorithmic Framework. To facilitate discussions, we introduce some notations to model the interaction with the preference oracle $\Omega_{\mathcal{T}}$ . Suppose the adaptation budget supports $K$ online preference queries to oracle $\Omega_{\mathcal{T}}$ , which divides this interactive procedure into $K$ rounds. We define the notation of query context set as Definition 2 to represent the context information extracted from the preference queries during the online oracle interaction.
+
+Definition 2 (Query Context Set). The query context set $\mathcal{Q}_k = \{\langle \tau_j^{(1)}\succ \tau_j^{(2)}\rangle \}_{j = 1}^k$ denotes the set of preference queries completed at the first $k$ rounds, in which the task inference protocol queries the preference order between the trajectory pair $\langle \tau_j^{(1)},\tau_j^{(2)}\rangle$ at the $j$ th round. To simplify the notations, the trajectory pair $\langle \tau_j^{(1)},\tau_j^{(2)}\rangle$ are relabeled according to the oracle feedback so that the preference order given by oracle $\Omega$ is $\tau_j^{(1)}\succ \tau_j^{(2)}$ for any $1\leq j\leq k$ .
+
+The query context set $\mathcal{Q}_k$ concludes the context information obtained from the oracle $\Omega$ in the first $k$ rounds. After completing the query at round $k$ , the task inference algorithm needs to decide the next-round query trajectory pair $\langle \tau_{k+1}^{(1)}, \tau_{k+1}^{(2)} \rangle$ based on the context information stored in $\mathcal{Q}_k$ . By leveraging the model-based problem transformation to Renyi-Ulam's game, we can assess the quality of a task embedding $z$ by counting the number of mismatches with respect to oracle preferences, denoted by $\mathcal{E}(z; \mathcal{Q}_k)$ :
+
+$$
+\mathcal {E} (z; \mathcal {Q} _ {k}) = \sum_ {(\tau^ {(1)} \succ \tau^ {(2)}) \in \mathcal {Q} _ {k}} \mathbb {I} \left[ f _ {\psi} \left(\tau^ {(1)} \succ \tau^ {(2)}; z\right) < f _ {\psi} \left(\tau^ {(2)} \succ \tau^ {(1)}; z\right) \right]. \tag {2}
+$$
+
+The overall algorithmic framework of our preference-based few-shot adaptation method, Adaptation with Noisy Oracle (ANOLE), is summarized in Algorithm 1.
+
+Algorithm 1 Adaptation with Noisy OracLE (ANOLE)
+1: input: a preference oracle $\Omega_{\mathcal{T}}$ , the budget of oracle queries $K$ a prior task distribution $q(z)$ , the size of candidate pool $M$ a query generation protocol GENERATEQUERY(·)
+2: $\widehat{Z}\gets \{z_j\sim q(z)\}_{j = 1}^M$ ▷ sample a candidate pool
+3: $\mathcal{Q}_0\gets \emptyset$ ▷ initialize context information
+4: for $k = 1$ to $K$ do
+5: $\langle \tau_k^{(1)},\tau_k^{(2)}\rangle \leftarrow \text{GENERATEQUERY} (\widehat{Z},\mathcal{Q}_{k - 1})$ ▷ critical step: query generation (Eq. (6))
+6: $\langle \tau_k^{(u)}\succ \tau_k^{(v)}\rangle \leftarrow \Omega_{\mathcal{T}}(\tau_j^{(1)},\tau_j^{(2)})$ where $u,v\in \{1,2\}$ ▷ request oracle feedback
+7: $\mathcal{Q}_k\gets \mathcal{Q}_{k - 1}\cup \{\langle \tau_k^{(u)}\succ \tau_k^{(v)}\rangle \}$ ▷ update context information
+8: return: arg min $z\in \widehat{Z}$ $\mathcal{E}(z;\mathcal{Q}_K)$
+
+The first step of our task inference algorithm is sampling a candidate pool $\widehat{Z}$ of latent task embeddings from the prior distribution $q(z)$ . Then we perform $K$ rounds of candidate selection by querying the preference oracle $\Omega_{\mathcal{T}}$ . The design of the query generation protocol GENERATEQUERY(\cdot) is a critical component of our task inference algorithm and will be introduced in section 3.3. The final decision would be the task embedding with minimum mismatch with the oracle preference, i.e., $\arg \min_{z\in \widehat{Z}}\mathcal{E}(z;\mathcal{Q}_K)$ .
+
+# 3.3 Error-Tolerant Task Inference for Noisy Preference Oracle
+
+The problem transformation to Renyi-Ulam's game enables us to leverage techniques from information theory to develop query strategy with both high feedback efficiency and error tolerance.
+
+Binary-Search Paradigm. The basic idea is conducting a binary-search-like protocol to leverage the binary structure of preference feedback: After each round of oracle interaction, we shrink the candidate pool $\widehat{Z}$ by removing those task embeddings leading to wrong preference predictions $f_{\psi}(\cdot ;z)$ . An ideal implementation of such a binary-search protocol with noiseless feedback is expected to roughly eliminate half of candidates using each single oracle preference feedback, which achieves the information-theoretic lower bound of interaction costs. In practice, we pursue to handle noisy
+
+feedback, since both the preference oracle $\Omega_{\mathcal{T}}$ and the preference predictor $f_{\psi}(\cdot ;z)$ may carry errors. An error-tolerant binary-search protocol requires to establish an information quantification (e.g., an uncertainty metric) to evaluate the information gain of each noisy oracle feedback. The goal of oracle interaction is to rapidly reduce the uncertainty of task inference rather than simply eliminate the erroneous candidates. In this paper, we extend an information-theoretic tool called Berlekamp's volume (Berlekamp, 1968) to develop such an uncertainty quantification.
+
+Berlekamp's Volume. One classical tool to deal with erroneous information in search problems is Berlekamp's volume, which is first proposed by Berlekamp (1968) and has been explored by subsequent works in numerous variants of Renyi-Ulam's game (Rivest et al., 1980; Pelc, 1987; Lawler and Sarkissian, 1995; Aigner, 1996; Cicalese and Deppe, 2007). The primary purpose of Berlekamp's volume is to mimic the notion of Shannon entropy from information theory (Shannon, 1948) and specialize in the applications to noisy-channel communication (Shannon, 1956) and error-tolerant search (Renyi, 1961). We refer readers to Pelc (2002) for a comprehensive literature review of the applications of Berlekamp's Volume and the solutions to Renyi-Ulam's game.
+
+In Definition 3, we rearrange the definition of Berlekamp's volume to suit the formulation of preference-based learning.
+
+Definition 3 (Berlekamp's Volume). Suppose the budget supports $K$ oracle queries in total, and the oracle may have at most $K_{E}$ incorrect feedback among these queries. Berlekamp's volume of a query context set $\mathcal{Q}_k$ is defined as follows:
+
+$$
+\mathcal {B V o l} _ {\widehat {Z}} \left(\mathcal {Q} _ {k}\right) = \sum_ {z \in \widehat {Z}} v o l _ {z} \left(\mathcal {Q} _ {k}\right), \quad v o l _ {z} \left(\mathcal {Q} _ {k}\right) = \sum_ {\ell = 0} ^ {K _ {E} - \mathcal {E} (z; \mathcal {Q} _ {k - 1})} \binom {K - k} {\ell}, \tag {3}
+$$
+
+where $\binom{K-k}{\ell}$ denotes the binomial coefficient.
+
+As stated in Definition 3, the configuration of Berlekamp's volume has two hyper-parameters: the total number of queries $K$ , and the maximum number of erroneous feedback $K_{E}$ within all queries. This error mode refers to Berlekamp (1968)'s noisy-channel model. Berlekamp's volume is a tool for designing robust query strategy to guarantee the tolerance of bounded number of feedback errors.
+
+What type of uncertainty does Berlekamp's volume characterize? Berlekamp's volume measures the uncertainty of the unknown latent task variable $z$ together with the randomness carried by the noisy oracle feedback. To give a more concrete view, we first show how the value of Berlekamp's volume $BVol_{\widehat{\mathcal{Z}}}(\mathcal{Q}_k)$ changes when receiving the feedback of a new preference query. Depending on the binary oracle feedback for the query trajectory pair $(\tau_k^{(1)},\tau_k^{(2)})$ , the query context set may be updated to two possible statuses:
+
+$$
+\mathcal {Q} _ {k} ^ {(1) \succ (2)} = \mathcal {Q} _ {k - 1} \cup \left\{\left(\tau_ {k} ^ {(1)} \succ \tau_ {k} ^ {(2)}\right) \right\} \quad \text {a n d} \quad \mathcal {Q} _ {k} ^ {(2) \succ (1)} = \mathcal {Q} _ {k - 1} \cup \left\{\left(\tau_ {k} ^ {(2)} \succ \tau_ {k} ^ {(1)}\right) \right\}, \tag {4}
+$$
+
+where $\mathcal{Q}_k^{(u) \succ (v)}$ denotes the updated status in the case of receiving oracle feedback $\tau_k^{(u)} \succ \tau_k^{(v)}$ . The relation between $\mathcal{BVol}_{\widehat{Z}}(\mathcal{Q}_{k-1})$ and $\mathcal{BVol}_{\widehat{Z}}(\mathcal{Q}_k)$ is characterized by Proposition 1, which is the foundation of Berlekamp's volume for developing error-tolerant algorithms.
+
+Proposition 1 (Volume Conservation Law). For any query context set $\mathcal{Q}_{k-1}$ and arbitrary query trajectory pair $(\tau_k^{(1)}, \tau_k^{(2)})$ , the relation between $\mathcal{BVol}_{\widehat{Z}}(\mathcal{Q}_{k-1})$ and $\mathcal{BVol}_{\widehat{Z}}(\mathcal{Q}_k)$ satisfies
+
+$$
+\mathcal {B} \mathcal {V} o l _ {\widehat {Z}} \left(\mathcal {Q} _ {k - 1}\right) = \mathcal {B} \mathcal {V} o l _ {\widehat {Z}} \left(\mathcal {Q} _ {k} ^ {(1) \succ (2)}\right) + \mathcal {B} \mathcal {V} o l _ {\widehat {Z}} \left(\mathcal {Q} _ {k} ^ {(2) \succ (1)}\right). \tag {5}
+$$
+
+The proofs of all statements presented in this section are deferred to Appendix A. As shown by Proposition 1, each preference query would partition the volume $\mathcal{B}Vol_{\widehat{Z}}(\mathcal{Q}_{k - 1})$ into two subsequent branches, $\mathcal{B}Vol_{\widehat{Z}}(\mathcal{Q}_k^{(1)\succ (2)})$ and $\mathcal{B}Vol_{\widehat{Z}}(\mathcal{Q}_k^{(2)\succ (1)})$ . The selection of preference queries does not alter the volume sum of subsequent branches. Since the values of $\mathcal{B}Vol_{\widehat{Z}}(\cdot)$ are non-negative integers, the volume is monotonically decreased with the online query procedure. When the volume is eliminated to the unit value, the selection of task embedding with minimum mismatches $\mathcal{E}(z;\mathcal{Q}_k)$ would become deterministic (see Proposition 2).
+
+Proposition 2 (Unit of Volume). Given a query context set $\mathcal{Q}_k$ with $\mathcal{BVol}_{\widehat{Z}}(\mathcal{Q}_k) = 1$ , there exists exactly one task embedding candidate $z \in \widehat{Z}$ satisfying $\mathcal{E}(z; \mathcal{Q}_k) \leq K_E$ .
+
+We can represent the preference-based task inference protocol by a decision tree, where each $\mathcal{Q}_k$ with $\mathcal{BVol}_{\widehat{Z}}(\mathcal{Q}_k) = 1$ corresponds to a leaf node and each preference query is a decision rule. The value of Berlekamp's volume $\mathcal{BVol}_{\widehat{Z}}(\mathcal{Q}_k)$ corresponds to the number of leaf nodes remaining in the subtree rooted with context set $\mathcal{Q}_k$ . The value of $z$ -conditioned volume $\text{vol}_z(\mathcal{Q}_k)$ counts the number of leaf nodes with $z$ as the final decision. Each path from an ancestor node to a leaf node can be mapped to a valid feedback sequence that does not violate $\mathcal{E}(z; \mathcal{Q}_K) \leq K_E$ . From this perspective, Berlekamp's volume quantifies the uncertainty of task inference by counting the number of valid feedback sequences for the incoming queries.
+
+Error-Tolerant Query Strategy. Given Berlekamp's volume as the uncertainty quantification, the query strategy can be constructed directly by maximizing the worst-case uncertainty reduction:
+
+$$
+\underset {\tau_ {k} ^ {(1)}, \tau_ {k} ^ {(2)}} {\text {G E N E R A T E Q U E R Y}} (\widehat {Z}, \mathcal {Q} _ {k - 1}) = \underset {\tau_ {k} ^ {(1)}, \tau_ {k} ^ {(2)}} {\arg \min } \left(\max \left\{\mathcal {B V o l} _ {\widehat {Z}} \left(\mathcal {Q} _ {k} ^ {(1) \succ (2)}\right), \mathcal {B V o l} _ {\widehat {Z}} \left(\mathcal {Q} _ {k} ^ {(2) \succ (1)}\right) \right\}\right), \tag {6}
+$$
+
+where $\text{GENERATEQUERY}(\cdot)$ refers to the query generation step at line 5 of Algorithm 1. This design follows the principle of binary search. If the Berlekamp's volumes of two subsequent branches are well balanced, the uncertainty can be exponentially reduced no matter which feedback the oracle responds. In our implementation, the arg min operator in Eq. (6) is approximated by sampling a mini-batch of trajectory pairs from the experience buffer. The query content is determined by finding the best trajectory pair within the sampled mini-batch. More implementation details are included in Appendix B.2.
+
+# 4 Experiments
+
+In this section, we investigate the empirical performance of ANOLE on a suite of Meta-RL benchmark tasks. We compare our method with simple preference-based adaptation strategies and conduct several ablation studies to demonstrate the effectiveness of our algorithmic designs.
+
+# 4.1 Experiment Setup
+
+Experiment Setting. We adopt six meta-RL benchmark tasks created by Rothfuss et al. (2019), which are widely used by meta-RL works to evaluate the performance of few-shot policy adaptation (Rakelly et al., 2019; Zintgraf et al., 2020; Fakoor et al., 2020). These environment settings consider four ways to vary the task specification $\mathcal{T}$ : forward/backward (-Fwd-Back), random target velocity (-Rand-Vel), random target direction (-Rand-Dir), and random target location (-Rand-Goal). We simulate the preference oracle $\Omega_{\mathcal{T}}$ by comparing the ground-truth trajectory return given by the MuJoCo-based environment simulator. The adaptation protocol cannot observe these environmental rewards during meta-testing and can only query the preference oracle $\Omega_{\mathcal{T}}$ to extract the task information. In addition, we impose a random noisy perturbation on the oracle feedback. Each binary feedback would be flipped with probability $\epsilon$ . We consider such independently distributed errors rather than the bounded-number error mode to evaluate the empirical performance, since it is more realistic to simulate human's unintended errors. A detailed description of the experiment setting is included in Appendix B.1.
+
+Implementation of ANOLE. Note that ANOLE is an adaptation module and can be built upon any meta-RL or multi-task RL algorithms with latent policy encoding (Hausman et al., 2018; Eysenbach et al., 2019; Pong et al., 2020; Lynch et al., 2020; Gupta et al., 2020). To align with the baseline algorithms, we implement a meta-training procedure similar to PEARL (Rakelly et al., 2019). The same as PEARL, our policy optimization module extends soft actor-critic (SAC; Haarnoja et al., 2018) with the latent task embedding $z$ , i.e., the policy and value functions are represented by $\pi_{\theta}(a \mid s;z)$ and $Q_{\phi}(s,a;z)$ where $\theta$ and $\phi$ denote the parameters. One difference from PEARL is the removal of the inference network, since it is no longer used in meta-testing. Instead, we set up a bunch of trainable latent task variables $\{z_i\}_{i=1}^N$ to learn the multi-task policy. More implementation details are included in Appendix B.2. The source code of our ANOLE implementation and experiment scripts are available at https://github.com/Stilwell-Git/Adaptation-with-Noisy-OracLE.
+
+
+
+
+
+
+
+
+Figure 1: Learning curves on a suite of MuJoCo-based meta-RL benchmark tasks with preference-based adaptation. All curves plot the average performance from eight runs with random initialization. The shaded region indicates the standard deviation. "PEARL (dense rewards)" denotes the final performance of ordinary PEARL using dense reward signals for meta-testing.
+
+
+
+
+
+Baseline Algorithms. We compare the performance with four baseline adaptation strategies. Two of these baselines are built upon the same meta-training pre-processing as ANOLE but do not use Berlekamp's volume to construct preference queries.
+
+- Greedy Binary Search. We conduct a simple and direct implementation of binary-search-like task inference. When generating preference queries, it simply ignores all candidates that have made at least one wrong preference predictions, and the query trajectory pair only aims to partition the remaining candidate pool into two balanced separations.
+- Random Query. We also include the simplest baseline that constructs the preference query by drawing a random trajectory pair from the experience buffer. This baseline serves an ablation study to investigate the benefits of removing the inference network.
+
+In addition, we implement two variants of PEARL (Rakelly et al., 2019) that use a probabilistic context encoder to infer task specification from preference-based feedback.
+
+- PEARL. We modify PEARL's context encoder to handle the preference-based feedback. More specifically, the context encoder is a LSTM-based network that takes an ordered trajectory pair as inputs to make up the task embedding $z$ , i.e., the input trajectory pair has been sorted by oracle preference. In meta-training, the preference is labeled by the ground-truth rewards from the environment simulator. During adaptation, the PEARL-based agent draws random trajectory pairs from the experience buffer to query the preference oracle, and the oracle feedback is used to update the posterior of task variable $z$ .
+- PEARL+Augmentation. We implement a data augmentation method for PEARL's metatraining to pursue the error tolerance of preference-based inference network. We impose random errors to the preference comparison when training the preference-based context encoder so that the inference network is expected to have some extent of error tolerance.
+
+We include more implementation details of these baselines in Appendix B.3.
+
+# 4.2 Performance Evaluation on MuJoCo-based Meta-RL Benchmark Tasks
+
+Figure 1 presents the performance evaluation of ANOLE and baseline algorithms on a suite of meta-RL benchmark tasks with noisy preference oracle. The adaptation algorithms are restricted to use $K = 10$ preference queries, and the noisy oracle would give wrong feedback for each query
+
+
+Figure 2: Investigating the impact of oracle noises on performance of preference-based adaptation. The dotted curves with tag "w/o noise" refer to the performance evaluation with a noiseless oracle.
+
+with probability $\epsilon = 0.2$ . We configure ANOLE with $K_{E} = 2$ to compute Berlekamp's volume. The experiment results indicate two conclusions:
+
+1. Berlekamp's volume improves the error tolerance of preference-based task inference. The only difference between ANOLE and the first two baselines, Greedy Binary Search and Random Query, is the utilization of Berlekamp's volume, which leads to a significant performance gap on benchmark tasks.
+2. The non-parametric inference framework of ANOLE improves the scalability of preference-based few-shot adaptation. Note that, using ANOLE's algorithmic framework (see Algorithm 1), a random query strategy can also outperform PEARL-based baselines. It may because the inference network used by PEARL cannot effectively translate the binary preference feedback to the task information.
+
+# 4.3 Ablation Studies on the Magnitude of Oracle Noise
+
+To demonstrate the functionality of Berlekamp's volume on improving error tolerance, we conduct an ablation study on the magnitude of oracle noise. In Figure 2, we contrast the performance of ANOLE in adaptation settings with and without oracle noises, i.e., $\epsilon = 0.2$ vs. $\epsilon = 0.0$ . When the preference oracle does not carry any error, the simple greedy baseline can achieve the same performance as ANOLE. If we impose noises to the oracle feedback, ANOLE would suffer from a performance drop, where the drop magnitude is much more moderate than that of the greedy strategy. This result indicates that Berlekamp's volume does provide remarkable benefits on improving error tolerance whereas cannot completely eliminate the negative effects of oracle noises. It opens up a problem for future work to further improve the error tolerance of preference-based few-shot adaptation. In Appendix C, we conduct more ablation studies to understand the algorithmic functionality of ANOLE.
+
+# 4.4 Experiments with Human Feedback
+
+We conduct experiments with real human feedback on MuJoCo-based meta-RL benchmark tasks. The meta-testing task specifications are generated by the same rule as the experiments in section 4.2. To facilitate human participation, we project the agent trajectory and the goal direction vector to a 2D coordinate system. The human participant watches the query trajectory pair and labels the preference according to the assigned task goal vector. The performance of
+
+Table 1: Evaluating the performance of ANOLE using human feedback.
+
+| Task | ANOLE |
| HalfCheetah-Fwd-Back | 1734.3±10.3 |
| Ant-Fwd-Back | 931.1±38.0 |
| Ant-Rand-Dir | 644.8±63.2 |
+
+ANOLE with human feedback is presented in Table 1. Each entry is evaluated by 20 runs (i.e., using $20 \times 10 = 200$ human queries). We note that, in these experiments, the feedback accuracy of the human participant is better than the uniform-noise oracle considered in section 4.2. The average error rate of human feedback is $6.2\%$ over all experiments. The evaluation results are thus better than the experiments in Figure 1. We include a visualization of the human-agent interaction interface in Appendix G.
+
+# 5 Related Work
+
+Meta-Learning and Meta-RL. Modeling task specification by a latent task embedding (or latent task variable) is a widely-applied technique in meta-learning for both supervised learning (Rusu et al., 2019; Gordon et al., 2019) and reinforcement learning (Rakelly et al., 2019). This paper studies the adaptation of latent task embedding based on preference-based supervision. One characteristic of our proposed approach is the non-parametric nature of the task inference protocol. Non-parametric adaptation has been studied in supervised meta-learning (Vinyals et al., 2016; Snell et al., 2017; Allen et al., 2019) but is rarely applied to meta-RL. From this perspective, our algorithmic framework opens up a new methodology for few-shot policy adaptation.
+
+Preference-based RL and Human-in-the-loop Learning. Learning from human's preference ranking is a classical problem formulation of human-in-the-loop RL (Akrour et al., 2011, 2012; Furnkranz et al., 2012; Wilson et al., 2012). When combining with deep RL techniques, recent advances focus on learning an auxiliary reward function that decomposes the trajectory-wise preference feedback to per-step supervision (Christiano et al., 2017; Ibarz et al., 2018). Several methods have been developed to generate informative queries (Lee et al., 2021b), improve the efficiency of data utilization (Park et al., 2022), and develop specialized exploration for preference-based RL (Liang et al., 2022). In this paper, we open up a new problem for preference-based RL, i.e., preference-based few-shot policy adaptation. The potential applications of our problem setting may be similar to that of personalized adaptation (Yu et al., 2021; Wang et al., 2021), a supervised meta-learning problem for modeling user preference. A future work is considering a wider range of human supervision, such as human attention (Zhang et al., 2020) and human annotation (Guan et al., 2021).
+
+# 6 Conclusion and Discussions
+
+In this paper, we study the problem of few-shot policy adaptation with preference-based feedback and propose a novel meta-RL algorithm, called Adaptation with Noisy OracLE (ANOLE). Our method leverages a classical problem formulation called Rényi-Ulam's game to model the task inference problem with a noisy preference oracle. This connection to information theory enables us to extend the technique of Berlekamp's volume to establish an error-tolerant approach for preference-based task inference, which is demonstrated as a promising approach on an extensive set of benchmark tasks.
+
+We conclude this paper by discussing limitations, future works, and other relevant aspects that have not been covered.
+
+Adaptation to Environment Dynamics. One limitation of ANOLE is that it does not consider the potential shift of transition dynamics from meta-training environments to meta-testing environments. Our problem formulation assumes only the reward function alters in the adaptation phase (see section 2.1). The current implementation of ANOLE cannot handle the adaptation to the changing environment dynamics. One promising way to address this issue is to integrate ANOLE with classical meta-RL modules to model the probabilistic inference regarding the transition function. In addition, it is critical to investigate the behavior of human preference when the query trajectories may contain unrealistic transitions.
+
+Expressiveness of Preference Partial Ordering. A recent theoretical work indicates that the trajectory-wise partial-order preference can define richer agent behaviors than step-wise reward functions (Abel et al., 2021). However, this superior of preference-based learning has rarely been shown in the empirical studies. e.g., in our experiments, the preference feedback is simulated by summing step-wise rewards given by the MuJoCo simulator, which is a common setting used by most preference-based RL works. In addition, most advanced preference-based RL algorithms are built on a methodology that linearly decomposes the trajectory-wise preference supervision to a step-wise auxiliary reward function, which degrades the expressiveness of the partial ordering preference system. These problems are fundamental challenges to preference-based learning.
+
+# Acknowledgments and Disclosure of Funding
+
+This work is supported by National Key R&D Program of China No. 2021YFF1201600.
+
+# References
+
+David Abel, Will Dabney, Anna Harutyunyan, Mark K Ho, Michael Littman, Doina Precup, and Satinder Singh. On the expressivity of Markov reward. In Advances in Neural Information Processing Systems, volume 34, 2021.
+Shipra Agrawal and Navin Goyal. Analysis of thompson sampling for the multi-armed bandit problem. In Conference on learning theory, pages 39-1. JMLR Workshop and Conference Proceedings, 2012.
+Martin Aigner. Searching with lies. Journal of Combinatorial Theory, Series A, 74(1):43-56, 1996.
+Riad Akfour, Marc Schoenauer, and Michele Sebag. Preference-based policy learning. In Joint European Conference on Machine Learning and Knowledge Discovery in Databases, pages 12-27. Springer, 2011.
+Riad Akfour, Marc Schoenauer, and Michèle Sebag. APRIL: Active preference learning-based reinforcement learning. In Joint European conference on machine learning and knowledge discovery in databases, pages 116-131. Springer, 2012.
+Kelsey Allen, Evan Shelhamer, Hanul Shin, and Joshua Tenenbaum. Infinite mixture prototypes for few-shot learning. In International Conference on Machine Learning, pages 232-241. PMLR, 2019.
+Dario Amodei, Chris Olah, Jacob Steinhardt, Paul Christiano, John Schulman, and Dan Mané. Concrete problems in ai safety. arXiv preprint arXiv:1606.06565, 2016.
+Elwyn R Berlekamp. Block coding for the binary symmetric channel with noiseless, delayless feedback. Error-correcting codes, pages 61-68, 1968.
+Christopher Berner, Greg Brockman, Brooke Chan, Vicki Cheung, Przemyslaw Debiak, Christy Dennison, David Farhi, Quirin Fischer, Shariq Hashme, Chris Hesse, et al. Dota 2 with large scale deep reinforcement learning. arXiv preprint arXiv:1912.06680, 2019.
+Ralph Allan Bradley and Milton E Terry. Rank analysis of incomplete block designs: I. the method of paired comparisons. Biometrika, 39(3/4):324-345, 1952.
+Emma Brunskill and Lihong Li. Pac-inspired option discovery in lifelong reinforcement learning. In International conference on machine learning, pages 316-324. PMLR, 2014.
+Paul F Christiano, Jan Leike, Tom Brown, Miljan Martic, Shane Legg, and Dario Amodei. Deep reinforcement learning from human preferences. In Advances in Neural Information Processing Systems, volume 30, 2017.
+Kurtland Chua, Qi Lei, and Jason D Lee. Provable hierarchy-based meta-reinforcement learning. arXiv preprint arXiv:2110.09507, 2021.
+Ferdinando Cicalese and Christian Deppe. Perfect minimally adaptive q-ary search with unreliable tests. Journal of statistical planning and inference, 137(1):162-175, 2007.
+Yan Duan, John Schulman, Xi Chen, Peter L Bartlett, Ilya Sutskever, and Pieter Abbeel. RL2: Fast reinforcement learning via slow reinforcement learning. arXiv preprint arXiv:1611.02779, 2016.
+Benjamin Eysenbach, Abhishek Gupta, Julian Ibarz, and Sergey Levine. Diversity is all you need: Learning skills without a reward function. In International Conference on Learning Representations, 2019.
+Rasool Fakoor, Pratik Chaudhari, Stefano Soatto, and Alexander J Smola. Meta-q-learning. In International Conference on Learning Representations, 2020.
+Chelsea Finn, Pieter Abbeel, and Sergey Levine. Model-agnostic meta-learning for fast adaptation of deep networks. In International conference on machine learning, pages 1126-1135. PMLR, 2017.
+Scott Fujimoto, David Meger, and Doina Precup. Off-policy deep reinforcement learning without exploration. In International Conference on Machine Learning, pages 2052-2062. PMLR, 2019.
+
+Johannes Furnkranz, Eyke Hüllermeier, Weiwei Cheng, and Sang-Hyeun Park. Preference-based reinforcement learning: a formal framework and a policy iteration algorithm. Machine learning, 89(1):123-156, 2012.
+Jonathan Gordon, John Bronskill, Matthias Bauer, Sebastian Nowozin, and Richard Turner. Meta-learning probabilistic inference for prediction. In International Conference on Learning Representations, 2019.
+Lin Guan, Mudit Verma, Suna Sihang Guo, Ruohan Zhang, and Subbarao Kambhampati. Widening the pipeline in human-guided reinforcement learning with explanation and context-aware data augmentation. In Advances in Neural Information Processing Systems, volume 34, pages 21885-21897, 2021.
+Abhishek Gupta, Benjamin Eysenbach, Chelsea Finn, and Sergey Levine. Unsupervised meta-learning for reinforcement learning. In International Conference on Learning Representations, 2020.
+Tuomas Haarnoja, Aurick Zhou, Pieter Abbeel, and Sergey Levine. Soft actor-critic: Off-policy maximum entropy deep reinforcement learning with a stochastic actor. In International conference on machine learning, pages 1861-1870. PMLR, 2018.
+Karol Hausman, Jost Tobias Springenberg, Ziyu Wang, Nicolas Heess, and Martin Riedmiller. Learning an embedding space for transferable robot skills. In International Conference on Learning Representations, 2018.
+Yun Hua, Xiangfeng Wang, Bo Jin, Wenhao Li, Junchi Yan, Xiaofeng He, and Hongyuan Zha. Hmrl: Hyper-meta learning for sparse reward reinforcement learning problem. In Proceedings of the 27th ACM SIGKDD Conference on Knowledge Discovery & Data Mining, pages 637-645, 2021.
+Borja Ibarz, Jan Leike, Tobias Pohlen, Geoffrey Irving, Shane Legg, and Dario Amodei. Reward learning from human preferences and demonstrations in atari. In Advances in neural information processing systems, volume 31, 2018.
+Diederik P Kingma and Jimmy Ba. Adam: A method for stochastic optimization. In International Conference on Learning Representations, 2015.
+Eugene L Lawler and Sergei Sarkissian. An algorithm for "Ulam's game" and its application to error correcting codes. Information processing letters, 56(2):89-93, 1995.
+Kimin Lee, Laura Smith, Anca Dragan, and Pieter Abbeel. B-pref: Benchmarking preference-based reinforcement learning. In Advances in Neural Information Processing Systems Datasets and Benchmarks Track, 2021a.
+Kimin Lee, Laura M Smith, and Pieter Abbeel. PEBBLE: Feedback-efficient interactive reinforcement learning via relabeling experience and unsupervised pre-training. In International Conference on Machine Learning, pages 6152-6163. PMLR, 2021b.
+Xinran Liang, Katherine Shu, Kimin Lee, and Pieter Abbeel. Reward uncertainty for exploration in preference-based reinforcement learning. In International Conference on Learning Representations, 2022.
+Evan Z Liu, Aditi Raghunathan, Percy Liang, and Chelsea Finn. Decoupling exploration and exploitation for meta-reinforcement learning without sacrifices. In International Conference on Machine Learning, pages 6925-6935. PMLR, 2021.
+Evan Zheran Liu, Aditi Raghunathan, Percy Liang, and Chelsea Finn. Explore then execute: Adapting without rewards via factorized meta-reinforcement learning. 2020.
+George Loewenstein and Drazen Prelec. Anomalies in intertemporal choice: Evidence and an interpretation. The Quarterly Journal of Economics, 107(2):573-597, 1992.
+Corey Lynch, Mohi Khansari, Ted Xiao, Vikash Kumar, Jonathan Tompson, Sergey Levine, and Pierre Sermanet. Learning latent plans from play. In Conference on robot learning, pages 1113-1132. PMLR, 2020.
+
+Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Andrei A Rusu, Joel Veness, Marc G Bellemare, Alex Graves, Martin Riedmiller, Andreas K Fidjeland, Georg Ostrovski, et al. Human-level control through deep reinforcement learning. nature, 518(7540):529-533, 2015.
+Ian Osband, Daniel Russo, and Benjamin Van Roy. (more) efficient reinforcement learning via posterior sampling. Advances in Neural Information Processing Systems, 26, 2013.
+Jongjin Park, Younggyo Seo, Jinwoo Shin, Honglak Lee, Pieter Abbeel, and Kimin Lee. SURF: Semi-supervised reward learning with data augmentation for feedback-efficient preference-based reinforcement learning. In International Conference on Learning Representations, 2022.
+Andrzej Pelc. Solution of Ulam's problem on searching with a lie. Journal of Combinatorial Theory, Series A, 44(1):129-140, 1987.
+Andrzej Pelc. Searching games with errors—fifty years of coping with liars. Theoretical Computer Science, 270(1-2):71-109, 2002.
+Vitchyr Pong, Murtaza Dalal, Steven Lin, Ashvin Nair, Shikhar Bahl, and Sergey Levine. Skew-fit: State-covering self-supervised reinforcement learning. In International Conference on Machine Learning, pages 7783-7792. PMLR, 2020.
+Matthew S Prewett, Ryan C Johnson, Kristin N Saboe, Linda R Elliott, and Michael D Coovert. Managing workload in human-robot interaction: A review of empirical studies. Computers in Human Behavior, 26(5):840-856, 2010.
+Kate Rakelly, Aurick Zhou, Deirdre Quillen, Chelsea Finn, and Sergey Levine. Efficient off-policy meta-reinforcement learning via probabilistic context variables. In International conference on machine learning, pages 5331-5340. PMLR, 2019.
+Zhizhou Ren, Ruihan Guo, Yuan Zhou, and Jian Peng. Learning long-term reward redistribution via randomized return decomposition. In International Conference on Learning Representations, 2022.
+Alfréd Rényi. On a problem of information theory. MTA Mat. Kut. Int. Kozl. B, 6(MR143666): 505-516, 1961.
+Alfréd Rényi and Zsuzsanna Makkai-Bencsáth. A diary on information theory. Akadémiai Kiadó Budapest, 1984.
+Ronald L. Rivest, Albert R. Meyer, Daniel J. Kleitman, Karl Winklmann, and Joel Spencer. Coping with errors in binary search procedures. Journal of Computer and System Sciences, 20(3):396-404, 1980.
+Jonas Rothfuss, Dennis Lee, Ignasi Clavera, Tamim Asfour, and Pieter Abbeel. ProMP: Proximal meta-policy search. In International Conference on Learning Representations, 2019.
+Daniel Russo and Benjamin Van Roy. Learning to optimize via posterior sampling. Mathematics of Operations Research, 39(4):1221-1243, 2014.
+Andrei A Rusu, Dushyant Rao, Jakub Sygnowski, Oriol Vinyals, Razvan Pascanu, Simon Osindero, and Raia Hadsell. Meta-learning with latent embedding optimization. In International Conference on Learning Representations, 2019.
+Claude Shannon. A mathematical theory of communication. The Bell system technical journal, 27 (3):379-423, 1948.
+Claude Shannon. The zero error capacity of a noisy channel. IRE Transactions on Information Theory, 2(3):8-19, 1956.
+David Silver, Aja Huang, Chris J Maddison, Arthur Guez, Laurent Sifre, George Van Den Driessche, Julian Schrittwieser, Ioannis Antonoglou, Veda Panneershelvam, Marc Lanctot, et al. Mastering the game of go with deep neural networks and tree search. nature, 529(7587):484-489, 2016.
+Jake Snell, Kevin Swersky, and Richard Zemel. Prototypical networks for few-shot learning. In Advances in neural information processing systems, volume 30, 2017.
+
+Jonathan Sorg, Richard L Lewis, and Satinder Singh. Reward design via online gradient ascent. Advances in Neural Information Processing Systems, 23, 2010.
+Malcolm JA Strens. A bayesian framework for reinforcement learning. In Proceedings of the Seventeenth International Conference on Machine Learning, pages 943-950, 2000.
+William R Thompson. On the likelihood that one unknown probability exceeds another in view of the evidence of two samples. Biometrika, 25(3-4):285-294, 1933.
+Stanislaw M Ulam. Adventures of a mathematician. New York: Scribner, 1976.
+Oriol Vinyals, Charles Blundell, Timothy Lillicrap, Daan Wierstra, et al. Matching networks for one shot learning. In Advances in neural information processing systems, volume 29, 2016.
+Oriol Vinyals, Igor Babuschkin, Wojciech M Czarnecki, Michael Mathieu, Andrew Dudzik, Junyoung Chung, David H Choi, Richard Powell, Timo Ewalds, Petko Georgiev, et al. Grandmaster level in starcraft ii using multi-agent reinforcement learning. Nature, 575(7782):350-354, 2019.
+Li Wang, Binbin Jin, Zhenya Huang, Hongke Zhao, Defu Lian, Qi Liu, and Enhong Chen. Preference-adaptive meta-learning for cold-start recommendation. In Proceedings of the International Joint Conference on Artificial Intelligence (IJCAI), pages 1607-1614, 2021.
+Lingxiao Wang, Qi Cai, Zhuoran Yang, and Zhaoran Wang. On the global optimality of model-agnostic meta-learning. In International conference on machine learning, pages 9837-9846. PMLR, 2020.
+Aaron Wilson, Alan Fern, and Prasad Tadepalli. A bayesian approach for policy learning from trajectory preference queries. Advances in neural information processing systems, 25, 2012.
+Christian Wirth, Riad Akrour, Gerhard Neumann, and Johannes Furnkranz. A survey of preference-based reinforcement learning methods. Journal of Machine Learning Research, 18:1-46, 2017.
+Runsheng Yu, Yu Gong, Xu He, Yu Zhu, Qingwen Liu, Wenwu Ou, and Bo An. Personalized adaptive meta learning for cold-start user preference prediction. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pages 10772-10780, 2021.
+Jin Zhang, Jianhao Wang, Hao Hu, Tong Chen, Yingfeng Chen, Changjie Fan, and Chongjie Zhang. Metacure: Meta reinforcement learning with empowerment-driven exploration. In International Conference on Machine Learning, pages 12600-12610. PMLR, 2021.
+Ruohan Zhang, Calen Walshe, Zhuode Liu, Lin Guan, Karl Muller, Jake Whitner, Luxin Zhang, Mary Hayhoe, and Dana Ballard. Atari-head: Atari human eye-tracking and demonstration dataset. In Proceedings of the AAAI conference on artificial intelligence, volume 34, pages 6811-6820, 2020.
+Luisa Zintgraf, Kyriacos Shiarlis, Maximilian Igl, Sebastian Schulze, Yarin Gal, Katja Hofmann, and Shimon Whiteson. VariBAD: A very good method for bayes-adaptive deep rl via meta-learning. In International Conference on Learning Representations, 2020.
\ No newline at end of file
diff --git a/efficientmetareinforcementlearningforpreferencebasedfastadaptation/images.zip b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..4d0ba1c618deb621c50fdbda4a1a7a6af4b8e9bf
--- /dev/null
+++ b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d704f63b221318015621e8a63cd578eb9a4903bfbde63bb06d9565847d333fcb
+size 214550
diff --git a/efficientmetareinforcementlearningforpreferencebasedfastadaptation/layout.json b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..f15e84f4671ea705cad4fcea2c9a56497611d89d
--- /dev/null
+++ b/efficientmetareinforcementlearningforpreferencebasedfastadaptation/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:670afd7f89eb11b0d7d96632e0105f46bc1dff2ba8b53fb67d3f13bb8883972d
+size 469442
diff --git a/efficientmethodsfornonstationaryonlinelearning/6be53e57-7417-47a7-b680-7cf9befbb2f4_content_list.json b/efficientmethodsfornonstationaryonlinelearning/6be53e57-7417-47a7-b680-7cf9befbb2f4_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..c6f5e300065379bd58f13d8b27831b0343be3174
--- /dev/null
+++ b/efficientmethodsfornonstationaryonlinelearning/6be53e57-7417-47a7-b680-7cf9befbb2f4_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6ac0eba21c530f3e09cea803ae8091513a92a868cd00639e17f0a962353b9c6b
+size 91596
diff --git a/efficientmethodsfornonstationaryonlinelearning/6be53e57-7417-47a7-b680-7cf9befbb2f4_model.json b/efficientmethodsfornonstationaryonlinelearning/6be53e57-7417-47a7-b680-7cf9befbb2f4_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..bd9a4eeb1220fa96f22957962bfa2f57b9f113b2
--- /dev/null
+++ b/efficientmethodsfornonstationaryonlinelearning/6be53e57-7417-47a7-b680-7cf9befbb2f4_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c90558638c9965bcd279d51718c974177a928abf45a5509bf03d02e6877b67ef
+size 114856
diff --git a/efficientmethodsfornonstationaryonlinelearning/6be53e57-7417-47a7-b680-7cf9befbb2f4_origin.pdf b/efficientmethodsfornonstationaryonlinelearning/6be53e57-7417-47a7-b680-7cf9befbb2f4_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..a0473bdba0f152cb67b6a62f38c4cf9cd703d6f2
--- /dev/null
+++ b/efficientmethodsfornonstationaryonlinelearning/6be53e57-7417-47a7-b680-7cf9befbb2f4_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0abb85fea09bf33201195df2c1e20b96d624cc1d0b25d2e7ad5688bffb333be4
+size 3247938
diff --git a/efficientmethodsfornonstationaryonlinelearning/full.md b/efficientmethodsfornonstationaryonlinelearning/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..b3ccf40bedf2a8b68cdba2c3b179c06138c3bd48
--- /dev/null
+++ b/efficientmethodsfornonstationaryonlinelearning/full.md
@@ -0,0 +1,378 @@
+# Efficient Methods for Non-stationary Online Learning
+
+Peng Zhao, Yan-Feng Xie, Lijun Zhang, Zhi-Hua Zhou
+
+National Key Laboratory for Novel Software Technology,
+
+Nanjing University, Nanjing, China
+
+{zhaop, xieyf, zhanglj, zhouzh}@lamda.nju.edu.cn
+
+# Abstract
+
+Non-stationary online learning has drawn much attention in recent years. In particular, dynamic regret and adaptive regret are proposed as two principled performance measures for online convex optimization in non-stationary environments. To optimize them, a two-layer online ensemble is usually deployed due to the inherent uncertainty of the non-stationarity, in which a group of base-learners are maintained and a meta-algorithm is employed to track the best one on the fly. However, the two-layer structure raises the concern about the computational complexity — those methods typically maintain $\mathcal{O}(\log T)$ base-learners simultaneously for a $T$ -round online game and thus perform multiple projections onto the feasible domain per round, which becomes the computational bottleneck when the domain is complicated. In this paper, we present efficient methods for optimizing dynamic regret and adaptive regret, which reduce the number of projections per round from $\mathcal{O}(\log T)$ to 1. Moreover, our obtained algorithms require only one gradient query and one function evaluation at each round. Our technique hinges on the reduction mechanism developed in parameter-free online learning and requires non-trivial twists on non-stationary online methods. Empirical studies verify our theoretical findings.
+
+# 1 Introduction
+
+Classic online learning minimizes the static regret, which benchmarks the online learner's performance against the best fixed decision in hindsight. In many real-world online applications, however, the environments are non-stationary [Zhou, 2022] and static regret becomes less attractive since it would be unrealistic to assume the existence of a single decision behaved satisfactorily over time.
+
+To address the limitation, in recent years, researchers have studied more strengthened performance measures to facilitate online algorithms with the capability of handling non-stationarity. In particular, dynamic regret [Zinkevich, 2003; Zhang et al., 2018a] and adaptive regret [Hazan and Seshadhri, 2009; Daniely et al., 2015] are proposed as two principled metrics to guide the algorithm design. We focus on the online convex optimization (OCO) setting [Hazan, 2016]. OCO can be deemed as a game between the learner and the environments. At each round $t \in [T]$ , the learner submits her decision $\mathbf{x}_t \in \mathcal{X}$ from a convex feasible domain $\mathcal{X} \subseteq \mathbb{R}^d$ and simultaneously environments choose a convex function $f_t: \mathcal{X} \mapsto \mathbb{R}$ , and subsequently the learner suffers an instantaneous loss $f_t(\mathbf{x}_t)$ .
+
+# 1.1 Dynamic Regret and Adaptive Regret
+
+Dynamic regret is proposed by Zinkevich [2003] to compare the online learner's performance against a sequence of any feasible comparators $\mathbf{u}_1, \ldots, \mathbf{u}_T \in \mathcal{X}$ . Formally, it is defined as
+
+$$
+\mathrm {D} - \operatorname {R E G} _ {T} \left(\mathbf {u} _ {1}, \dots , \mathbf {u} _ {T}\right) = \sum_ {t = 1} ^ {T} f _ {t} \left(\mathbf {x} _ {t}\right) - \sum_ {t = 1} ^ {T} f _ {t} \left(\mathbf {u} _ {t}\right). \tag {1}
+$$
+
+Dynamic regret minimization enables the learner to track changing comparators. A favorable dynamic regret bound should scale with a certain non-stationarity measure dependent on the comparators such as the path length $P_{T} = \sum_{t=2} \| \mathbf{u}_{t} - \mathbf{u}_{t-1} \|_{2}$ . Notably, the classic static regret can be treated as a special case of dynamic regret by specifying the comparators as the best fixed decision in hindsight.
+
+Adaptive regret is proposed by Hazan and Seshadhri [2009] and further strengthened by Daniely et al. [2015], which measures the regret over any interval $I = [r, s] \subseteq [T]$ with a length of $\tau = |I|$ , i.e.,
+
+$$
+\mathrm {A} - \operatorname {R E G} _ {T} (| I |) = \max _ {[ r, r + \tau - 1 ] \subseteq [ T ]} \left\{\sum_ {t = r} ^ {r + \tau - 1} f _ {t} (\mathbf {x} _ {t}) - \min _ {\mathbf {u} \in \mathcal {X}} \sum_ {t = r} ^ {r + \tau - 1} f _ {t} (\mathbf {u}) \right\}. \tag {2}
+$$
+
+Since the minimizers of different intervals can be different, adaptive regret minimization also ensures the capability of competing with changing comparators. A desired adaptive regret bound should be as close as the minimax static regret of this interval. Algorithms with adaptive regret matching static regret of this interval up to logarithmic terms in $T$ are referred to strongly adaptive [Daniely et al., 2015]. Moreover, adaptive regret includes static regret when choosing $I = [T]$ .
+
+It is worth noting that the relationship between dynamic regret and adaptive regret for OCO is generally unclear [Zhang, 2020, Section 5], even though a black-box reduction from dynamic regret to adaptive regret has been proven for the simpler expert setting (i.e., online linear optimization over simplex) [Luo and Schapire, 2015, Theorem 4]. Hence, the two measures are separately developed and many algorithms have been proposed, including algorithms for dynamic regret [Zinkevich, 2003; Hall and Willett, 2013; Zhang et al., 2018a; Zhao et al., 2020, 2021b,a; Baby and Wang, 2021; Zhao et al., 2022a] and the ones for adaptive regret [Hazan and Seshadhri, 2009; Daniely et al., 2015; Jun et al., 2017; Zhang et al., 2018b, 2019]. Note that there are also studies [Zhang et al., 2020; Cutkosky, 2020] optimizing both measures simultaneously by an even strengthened metric $\sum_{t=r}^{s} f_t(\mathbf{x}_t) - \sum_{t=r}^{s} f_t(\mathbf{u}_t)$ over any interval $[r,s] \subseteq [T]$ , hence called "interval dynamic regret".
+
+# 1.2 Two-layer Structure and Projection Complexity Issue
+
+The fundamental challenge of optimizing these two non-stationary regret measures is the uncertainty of the environmental non-stationarity. Concretely, to ensure the robustness to the unknown environments, dynamic regret aims to compete with any feasible comparator sequence, while adaptive regret examines the local performance over any intervals. The unknown comparators or unknown intervals bring considerable uncertainty to online optimization. To address the issue, a two-layer structure is usually deployed to optimize the measures, where a set of base-learners are maintained to handle the different possibilities of online environments and a meta-algorithm is employed to combine them all and track the unknown best one. Such a framework successfully achieves many state-of-the-art results, including the $\mathcal{O}(\sqrt{T(1 + P_T)})$ dynamic regret [Zhang et al., 2018a] and the $\mathcal{O}(\sqrt{(F_T + P_T)(1 + P_T)})$ small-loss dynamic regret for smooth functions [Zhao et al., 2020], where $P_{T} = \sum_{t = 2}^{T}\| \mathbf{u}_{t} - \mathbf{u}_{t - 1}\|_{2}$ is the path length and $F_{T} = \sum_{t = 1}^{T}f_{t}(\mathbf{u}_{t})$ is the cumulative loss of comparators; as well as the $\mathcal{O}(\sqrt{|I|\log T})$ adaptive regret [Jun et al., 2017] and the $\mathcal{O}(\sqrt{F_I\log F_I\log F_T})$ small-loss adaptive regret for smooth functions [Zhang et al., 2019] for any interval $I = [r,s]\subseteq [T]$ , where $F_{I} = \min_{\mathbf{x}\in \mathcal{X}}\sum_{t = r}^{s}f_{t}(\mathbf{x})$ and $F_{T} = \min_{\mathbf{x}\in \mathcal{X}}\sum_{t = 1}^{T}f_{t}(\mathbf{x})$ . Besides, an $\mathcal{O}(\sqrt{|I|(\log T + P_I)})$ interval dynamic regret is also achieved by a two-layer (or even three-layer) structure [Zhang et al., 2020], where $P_{I} = \sum_{t = r}^{s}\| \mathbf{u}_{t} - \mathbf{u}_{t - 1}\|_{2}$ is the path length over the interval.
+
+The two-layer methods have demonstrated great effectiveness in tackling non-stationary online environments, whereas the gain is at the price of heavier computations than the methods for minimizing static regret. While it is believed that additional computations are necessary for more robustness, we are wondering whether it is possible to pay for a "minimal" computation overhead for adapting to the non-stationarity. To this end, we focus on the popular first-order online methods and aim to streamline unnecessary computations while retaining the same regret guarantees. Arguably, the most computationally expensive step of each round is the projection onto the convex feasible domain, namely, the projection operation $\Pi_{\mathcal{X}}[\mathbf{y}] = \arg \min_{\mathbf{x}\in \mathcal{X}}\| \mathbf{x} - \mathbf{y}\| _2$ for a convex set $\mathcal{X}\subseteq \mathbb{R}^d$ . Typical two-layer non-stationary online algorithms require maintaining $N = \mathcal{O}(\log T)$ base-learners simultaneously to cover the possibility of unknown environments. Define the projection complexity of online methods as the number of projections onto the feasible domain per round. Then, those non-stationary methods suffer an $\mathcal{O}(\log T)$ projection complexity, whereas standard online methods for static regret minimization require only one projection per round such as online gradient descent [Zinkevich, 2003].
+
+# 1.3 Our Contributions and Techniques
+
+In this paper, we design a generic mechanism to reduce the projection complexity of many existing non-stationary methods from $\mathcal{O}(\log T)$ to 1 without sacrificing the regret optimality, hence matching the projection complexity of stationary methods. Our reduction is inspired by the recent advance in parameter-free online learning [Cutkosky and Orabona, 2018; Mhammedi et al., 2019]. The idea is simple: we reduce the original problem learned in the feasible domain $\mathcal{X}$ to an alternative one learned in a surrogate domain $\mathcal{Y} \supseteq \mathcal{X}$ such that the projection onto it is much cheaper, e.g., simply choosing $\mathcal{Y}$ as a properly scaled Euclidean ball; and moreover, a carefully designed surrogate loss is necessary for the alternative problem to retain the regret optimality. We reveal that a necessary condition for our reduction mechanism to deploy and reduce the projection complexity is that the non-stationary online algorithm shall query the function gradient once and evaluate the function value once per round. Several algorithms for the worst-case dynamic regret or adaptive regret already satisfy the requirements, so we can immediately deploy the reduction and obtain their efficient counterparts with the same regret guarantees and 1 projection complexity. However, many non-stationary algorithms, particularly those designed for small-loss bounds, do not satisfy the requirement. Hence, we require non-trivial efforts to make them compatible. Due to this, we have developed a series of algorithms that achieve worst-case/small-loss dynamic regret and adaptive regret with one projection per round (actually, with one gradient query and one function evaluation per round as well).
+
+Despite that the reduction mechanism of this paper has been studied in parameter-free online learning, applying it to non-stationary online learning requires new ideas and non-trivial modifications. Here we highlight the technical innovation. The main challenge comes from the reduction condition mentioned earlier — as the surrogate loss involves the projection operation, our reduction requires the algorithm query one gradient and evaluate one function value at each round. However, many nonstationary algorithms do not satisfy the requirement, which is to be contrasted to the parameter-free algorithms such as MetaGrad [van Erven and Koolen, 2016; Mhammedi et al., 2019] that naturally satisfy the condition. For example, the SACS algorithm [Zhang et al., 2019] enjoys the best known small-loss adaptive regret, yet the method requires $N$ gradient queries and $N + 1$ function evaluations at each round, where $N = \mathcal{O}(\log T)$ is the number of base-learners. Thus, we have to dig into the algorithm and modify it to fit our reduction. First, we replace their meta-algorithm with Adapt-ML-Prod [Gaillard et al., 2014], an expert-tracking algorithm with a second-order regret with excess losses to accommodate the linearized loss that is used to ensure one gradient query per round. Second, we introduce a sequence of time-varying thresholds to adaptively determine the problem-dependent geometric covers in contrast to a fixed threshold used in their method. In particular, we register the cumulative loss of the final decisions rather than the base-learner's one to compare it with the changing thresholds, which renders the design of one function value evaluation per round and also turns out to be crucial for achieving an improved small-loss bound that can recover the best known worst-case adaptive regret (by contrast, SACS cannot obtain optimal worst-case adaptive regret). To summarize, our final algorithm only requires one projection/gradient query/function evaluation at each round, substantially improving the efficiency of SACS algorithm that requires $N$ projections/gradient queries/function evaluations per round.
+
+# 1.4 Assumptions
+
+We list several standard assumptions used in OCO [Shalev-Shwartz, 2012; Hazan, 2016]. Notably, not all assumptions are always required. We will explicitly state the requirements in the theorem.
+
+Assumption 1 (bounded gradient). The norm of the gradients of online functions over the domain $\mathcal{X}$ is bounded by $G$ , i.e., $\| \nabla f_t(\mathbf{x}) \|_2 \leq G$ , for all $\mathbf{x} \in \mathcal{X}$ and $t \in [T]$ .
+
+Assumption 2 (bounded domain). The domain $\mathcal{X} \subseteq \mathbb{R}^d$ contains the origin $\mathbf{0}$ , and the diameter of the domain $\mathcal{X}$ is at most $D$ , i.e., $\| \mathbf{x} - \mathbf{x}'\|_2 \leq D$ for any $\mathbf{x}, \mathbf{x}' \in \mathcal{X}$ .
+
+Assumption 3 (non-negativity and smoothness). All the online functions are non-negative and $L$ -smooth, i.e., for any $\mathbf{x}, \mathbf{x}' \in \mathcal{X}$ and $t \in [T]$ , $\| \nabla f_t(\mathbf{x}) - \nabla f_t(\mathbf{x}') \|_2 \leq L \| \mathbf{x} - \mathbf{x}' \|_2$ .
+
+Organization. The rest is structured as follows. Section 2 presents the reduction mechanism and illustrates its application to dynamic regret minimization. Section 3 provides efficient methods for optimizing adaptive regret. Section 4 reports the experiments. Section 5 concludes the paper and makes discussions. All the proofs and omitted details for algorithms are deferred to the appendices.
+
+# 2 The Reduction Mechanism and Dynamic Regret Minimization
+
+We start from the dynamic regret minimization. First, we briefly review existing methods in Section 2.1, and then present our reduction mechanism and illustrate how to apply it to reducing the projection complexity of dynamic regret methods in Section 2.2.
+
+# 2.1 A Brief Review of Dynamic Regret Minimization
+
+Zhang et al. [2018a] propose a two-layer online algorithm called Ader with an $\mathcal{O}(\sqrt{T(1 + P_T)})$ dynamic regret, which is proven to be minimax optimal for convex functions. Ader maintains a group of base-learners, each performing online gradient descent (OGD) [Zinkevich, 2003] with a customized step size specified by the pool $\mathcal{H} = \{\eta_1,\dots ,\eta_N\}$ , and then uses a meta-algorithm to combine them all. Denoted by $\mathcal{B}_1,\ldots ,\mathcal{B}_N$ the $N$ base-learners. For each $i\in [N]$ , $\mathcal{B}_i$ updates by
+
+$$
+\mathbf {x} _ {t + 1, i} = \Pi_ {\mathcal {X}} \left[ \mathbf {x} _ {t, i} - \eta_ {i} \nabla f _ {t} \left(\mathbf {x} _ {t}\right) \right], \tag {3}
+$$
+
+where $\eta_i\in \mathcal{H}$ is the associated step size and $\Pi_{\mathcal{X}}[\cdot ]$ denotes the projection onto the feasible domain $\mathcal{X}$ with $\Pi_{\mathcal{X}}[\mathbf{y}] = \arg \min_{\mathbf{x}\in \mathcal{X}}\| \mathbf{y} - \mathbf{x}\| _2$ . Notably, all the base-learners share the same gradient $\nabla f_t(\mathbf{x}_t)$ rather than using their individual one $\nabla f_{t}(\mathbf{x}_{t,i})$ . This is because Ader optimizes the linearized loss $\ell_t(\mathbf{x}) = \langle \nabla f_t(\mathbf{x}_t),\mathbf{x}\rangle$ , which enjoys the benign property of $\nabla \ell_t(\mathbf{x}_{t,i}) = \nabla f_t(\mathbf{x}_t)$ for all $i\in [N]$ .
+
+Furthermore, the meta-algorithm evaluates each base-learner by $\ell_t(\mathbf{x}_{t,i}) = \langle \nabla f_t(\mathbf{x}_t),\mathbf{x}_{t,i}\rangle$ and updates the weight vector $\pmb{p}_{t + 1}\in \Delta_N$ by the Hedge algorithm [Freund and Schapire, 1997], namely,
+
+$$
+p _ {t + 1, i} = \frac {p _ {t , i} \exp \left(- \varepsilon \langle \nabla f _ {t} (\mathbf {x} _ {t}) , \mathbf {x} _ {t , i} \rangle\right)}{\sum_ {j = 1} ^ {N} p _ {t , j} \exp \left(- \varepsilon \langle \nabla f _ {t} (\mathbf {x} _ {t}) , \mathbf {x} _ {t , j} \rangle\right)}, \forall i \in [ N ], \tag {4}
+$$
+
+where $\varepsilon > 0$ is the learning rate of the meta-algorithm. The final prediction is obtained by $\mathbf{x}_{t+1} = \sum_{i=1}^{N} p_{t+1,i} \mathbf{x}_{t+1,i}$ . The learner submits the prediction $\mathbf{x}_{t+1}$ and then receives the loss $f_{t+1}(\mathbf{x}_{t+1})$ and the gradient $\nabla f_{t+1}(\mathbf{x}_{t+1})$ as the feedback of this round. Under a suitable configuration of the step size pool $\mathcal{H}$ with $N = \mathcal{O}(\log T)$ and learning rate $\varepsilon = \Theta(\sqrt{(\ln N)/T})$ , Ader enjoys an $\mathcal{O}(\sqrt{T(1 + P_T)})$ dynamic regret [Zhang et al., 2018a, Theorem 4].
+
+For convex and smooth functions, Zhao et al. [2021b] demonstrate that a similar two-layer structure can attain an $\mathcal{O}(\sqrt{(F_T + P_T)(1 + P_T)})$ small-loss dynamic regret under a suitable setting of the step size pool $\mathcal{H}$ and time-varying learning rates of meta-algorithm $\{\varepsilon_t\}_{t=1}^T$ , where $F_T = \sum_{t=1}^T f_t(\mathbf{u}_t)$ is the cumulative loss of the comparators. This bound safeguards the minimax rate in the worst case, while can be much smaller than $\mathcal{O}(\sqrt{T(1 + P_T)})$ bound in benign environments.
+
+# 2.2 The Reduction Mechanism for Reducing Projection Complexity
+
+As demonstrated in the update (3), all the base-learners require projecting the intermediate solution onto the domain $\mathcal{X}$ to ensure the feasibility. As a result, $\mathcal{O}(\log T)$ projections are required at each round, which is generally time-consuming particularly when the domain $\mathcal{X}$ is complicated.
+
+We present a generic reduction mechanism for reducing the projection complexity and apply it to dynamic regret methods. Our reduction builds upon the seminal work [Cutkosky and Orabona, 2018] and a further refined result [Cutkosky, 2020], who propose a black-box reduction from constrained online learning to the unconstrained setting (or another constrained problem with a larger domain).
+
+Reduction mechanism. Given an algorithm for non-stationary online learning Algo whose projection complexity is $\mathcal{O}(\log T)$ , our reduction mechanism builds on it to yield an algorithm Efficient-Algo with 1 projection onto $\mathcal{X}$ per round and retaining the same order of regret. The central idea is to replace expensive projections onto the original domain $\mathcal{X}$ with other much cheaper projections. To this end, we introduce a surrogate domain $\mathcal{Y}$ defined as the minimum Euclidean ball containing the feasible domain $\mathcal{X}$ , i.e., $\mathcal{Y} = \{\mathbf{x} \mid \| \mathbf{x} \|_2 \leq D\} \supseteq \mathcal{X}$ . Then, the reduced algorithm Algo works on $\mathcal{Y}$ whose projection can be realized by a simple rescaling. More importantly, to avoid regret degeneration, it is necessary to carefully construct the surrogate loss $g_t: \mathcal{Y} \mapsto \mathbb{R}$ as
+
+$$
+g _ {t} (\mathbf {y}) = \left\langle \nabla f _ {t} \left(\mathbf {x} _ {t}\right), \mathbf {y} \right\rangle - \mathbb {1} _ {\{\left\langle \nabla f _ {t} \left(\mathbf {x} _ {t}\right), \mathbf {v} _ {t} \right\rangle < 0 \}} \cdot \left\langle \nabla f _ {t} \left(\mathbf {x} _ {t}\right), \mathbf {v} _ {t} \right\rangle \cdot S _ {\mathcal {X}} (\mathbf {y}), \tag {5}
+$$
+
+# Algorithm 1 Efficient Algorithm for Minimizing Dynamic Regret
+
+Input: step size pool $\mathcal{H} = \{\eta_1,\dots ,\eta_N\}$ , learning rate of meta-algorithm $\varepsilon_{t}$ (or simply a fixed $\varepsilon$ ).
+
+1: Initialization: let $\mathbf{x}_1$ and $\{\mathbf{y}_{1,i}\}_{i = 1}^{N}$ be any point in $\mathcal{X}$ ; $\forall i\in [N],p_{1,i} = 1 / N$ .
+2: for $t = 1$ to $T$ do
+3: Receive the gradient information $\nabla f_{t}(\mathbf{x}_{t})$
+4: Construct the surrogate loss $g_{t}:\mathcal{V}\mapsto \mathbb{R}$ according to Eq. (5).
+5: Compute the gradient $\nabla g_t(\mathbf{y}_t)$ according to Lemma 1.
+6: For each $i \in [N]$ , the base-learner $\mathcal{B}_i$ produces the local decision by
+
+$$
+\widehat {\mathbf {y}} _ {t + 1, i} = \mathbf {y} _ {t, i} - \eta_ {i} \nabla g _ {t} (\mathbf {y} _ {t}), \mathbf {y} _ {t + 1, i} = \widehat {\mathbf {y}} _ {t + 1, i} \Big (\mathbb {1} _ {\{\| \widehat {\mathbf {y}} _ {t + 1, i} \| _ {2} \leq D \}} + \frac {D}{\| \widehat {\mathbf {y}} _ {t + 1 , i} \| _ {2}} \cdot \mathbb {1} _ {\{\| \widehat {\mathbf {y}} _ {t + 1, i} \| _ {2} \geq D \}} \Big).
+$$
+
+7: Meta-algorithm updates weight by $p_{t + 1,i} \propto \exp (-\varepsilon_{t + 1}\sum_{s = 1}^{t}\langle \nabla g_s(\mathbf{y}_s),\mathbf{y}_{s,i}\rangle)$ , $i \in [N]$ .
+8: Compute $\mathbf{y}_{t + 1} = \sum_{i = 1}^{N}p_{t + 1,i}\mathbf{y}_{t + 1,i}$
+9: Submit $\mathbf{x}_{t + 1} = \Pi_{\mathcal{X}}[\mathbf{y}_{t + 1}]$ . $\triangleright$ The only step projects onto feasible domain $\mathcal{X}$ per round.
+
+# 10: end for
+
+where $S_{\mathcal{X}}(\mathbf{y}) = \inf_{\mathbf{x} \in \mathcal{X}} \| \mathbf{y} - \mathbf{x} \|_2$ is the distance function to $\mathcal{X}$ and $\mathbf{v}_t = (\mathbf{y}_t - \mathbf{x}_t) / \| \mathbf{y}_t - \mathbf{x}_t \|_2$ is the vector indicating the projection direction.
+
+The main protocol of our reduction is presented as follows. The input includes original functions $\{f_t\}_{t=1}^T$ , the feasible domain $\mathcal{X}$ , and the reduced algorithm Algo.
+
+1: for $t = 1, \dots, T$ do
+2: receive the gradient information $\nabla f_{t}(\mathbf{x}_{t})$
+3: construct the surrogate loss $g_{t}:\mathcal{V}\mapsto \mathbb{R}$ according to Eq. (5);
+4: obtain the intermediate prediction $\mathbf{y}_{t + 1}\gets \mathsf{Algo}(g_t(\cdot),\mathbf{y}_t,\mathcal{Y})$
+5: submit the final prediction $\mathbf{x}_{t + 1} = \Pi_{\mathcal{X}}[\mathbf{y}_{t + 1}]$
+6: end for
+
+Our reduction enjoys the regret safeness due to the following benign properties of surrogate loss.
+
+Theorem 1 (Theorem 2 of Cutkosky [2020]). The surrogate loss $g_t: \mathcal{Y} \mapsto \mathbb{R}$ defined in (5) is convex. Moreover, we have $\| \nabla g_t(\mathbf{y}_t) \|_2 \leq \| \nabla f_t(\mathbf{x}_t) \|_2$ and for any $\mathbf{u}_t \in \mathcal{X}$
+
+$$
+\langle \nabla f _ {t} (\mathbf {x} _ {t}), \mathbf {x} _ {t} - \mathbf {u} _ {t} \rangle \leq g _ {t} (\mathbf {y} _ {t}) - g _ {t} (\mathbf {u} _ {t}) \leq \langle \nabla g _ {t} (\mathbf {y} _ {t}), \mathbf {y} _ {t} - \mathbf {u} _ {t} \rangle . \tag {6}
+$$
+
+The theorem shows the convexity of the surrogate loss $g_{t}(\mathbf{y})$ and we thus have $f_{t}(\mathbf{x}_{t}) - f_{t}(\mathbf{u}_{t}) \leq \langle \nabla g_{t}(\mathbf{y}_{t}), \mathbf{y}_{t} - \mathbf{u}_{t} \rangle$ , which implies that it suffices to optimize the linearized upper bound, i.e., to optimize function $\ell_{t}(\mathbf{y}) = \langle \nabla g_{t}(\mathbf{y}_{t}), \mathbf{y} \rangle$ . The following lemma specifies the gradient calculation.
+
+Lemma 1. For any $\mathbf{y} \in \mathcal{V}$ , $\nabla g_t(\mathbf{y}) = \nabla f_t(\mathbf{x}_t)$ when $\langle \nabla f_t(\mathbf{x}_t), \mathbf{v}_t \rangle \geq 0$ ; and $\nabla g_t(\mathbf{y}) = \nabla f_t(\mathbf{x}_t) - \langle \nabla f_t(\mathbf{x}_t), \mathbf{v}_t \rangle \cdot (\mathbf{y} - \Pi_{\mathcal{X}}[\mathbf{y}]) / \| \mathbf{y} - \Pi_{\mathcal{X}}[\mathbf{y}] \|_2$ when $\langle \nabla f_t(\mathbf{x}_t), \mathbf{v}_t \rangle < 0$ . Here $\mathbf{v}_t = (\mathbf{y}_t - \mathbf{x}_t) / \| \mathbf{y}_t - \mathbf{x}_t \|_2$ . In particular, $\nabla g_t(\mathbf{y}_t) = \nabla f_t(\mathbf{x}_t) - \langle \nabla f_t(\mathbf{x}_t), \mathbf{v}_t \rangle \cdot \mathbf{v}_t$ when $\langle \nabla f_t(\mathbf{x}_t), \mathbf{v}_t \rangle < 0$ .
+
+Reduction requirements. An important necessary condition for the reduction is to require the reduced algorithm satisfying one gradient query and one function evaluation at each round. Indeed, the reduction essentially updates according to the surrogate loss $\{g_t\}_{t=1}^T$ . Note that the definition of surrogate loss involves the distance function $S_{\mathcal{X}}(\mathbf{y})$ , see Eq. (5). Thus, each evaluation of $g_t(\mathbf{y})$ leads to one projection onto $\mathcal{X}$ due to the calculation of $S_{\mathcal{X}}(\mathbf{y})$ . Similarly, each gradient query of $\nabla g_t(\mathbf{y})$ also contributes to one projection, see Lemma 1 for details. To summarize, we can use the reduction to ensure a 1 projection complexity, only when the reduced algorithm satisfies the requirements of one gradient query and one function evaluation per round. Below, we demonstrate the usage of our reduction mechanism for two methods of dynamic regret minimization that satisfy the conditions, including the worst-case method [Zhang et al., 2018a] and the small-loss method [Zhao et al., 2021b].
+
+Application to dynamic regret minimization. Algorithm 1 summarizes the main procedures of our efficient methods for optimizing dynamic regret, which is an instance of the reduction mechanism by picking Algo as Ader [Zhang et al., 2018a]. More specifically, Lines 6 - 8 are essentially performing Ader algorithm using the surrogate loss $\{g_t\}_{t=1}^T$ over the surrogate domain $\mathcal{V}$ . Note that the base update in Line 6 is essentially performing OGD with projection onto $\mathcal{V}$ , a scaled Euclidean ball, and
+
+thus the projection admits a simple closed form. The overall algorithm requires projecting onto $\mathcal{X}$ only once per round, see Line 9. Our method provably retains the same dynamic regret.
+
+Theorem 2. Set the step size pool as $\mathcal{H} = \left\{\eta_i = 2^{i - 1}(D / G)\sqrt{5 / (2T)} \mid i \in [N]\right\}$ with $N = \lceil 2^{-1}\log_2(1 + 2T / 5)\rceil + 1$ and the learning rate as $\varepsilon = \sqrt{(\ln N) / (1 + G^2D^2T)}$ . Under Assumptions 1 and 2, our algorithm requires one projection onto $\mathcal{X}$ per round and enjoys
+
+$$
+\sum_ {t = 1} ^ {T} f _ {t} \left(\mathbf {x} _ {t}\right) - \sum_ {t = 1} ^ {T} f _ {t} \left(\mathbf {u} _ {t}\right) \leq \mathcal {O} \left(\sqrt {T \left(1 + P _ {T}\right)}\right). \tag {7}
+$$
+
+For smooth and non-negative functions, the Sword++ algorithm [Zhao et al., 2021b] achieves an $\mathcal{O}(\sqrt{(F_T + P_T)(1 + P_T)})$ small-loss dynamic regret, which requires one gradient and one function value per iteration. However, notice that the surrogate loss $g_{t}(\cdot)$ in Eq. (5) is neither smooth nor non-negative, which hinders the application of our reduction to their method. Fortunately, owing to the benign property of $\| \nabla g_t(\mathbf{y}_t)\| _2\leq \| \nabla f_t(\mathbf{x}_t)\| _2$ (see Theorem 1), we can still deploy the reduction via an improved analysis and obtain a projection-efficient algorithm with the same small-loss bound.
+
+Theorem 3. Set the step size pool as $\mathcal{H} = \left\{\eta_i = 2^{i - 1}\sqrt{5D^2 / (1 + 8LGDT)} \mid i \in [N]\right\}$ with $N = \lceil 2^{-1}\log_2((5D^2 + 2D^2 T)(1 + 8LGDT) / (5D^2))\rceil + 1$ and the learning rate of the meta-algorithm as $\varepsilon_t = \sqrt{(\ln N) / (1 + D^2\sum_{s = 1}^{t - 1}\|\nabla g_s(\mathbf{y}_s)\|_2^2)}$ . Under Assumptions 1, 2, and 3, our algorithm requires one projection onto $\mathcal{X}$ per round and enjoys the following dynamic regret:
+
+$$
+\sum_ {t = 1} ^ {T} f _ {t} \left(\mathbf {x} _ {t}\right) - \sum_ {t = 1} ^ {T} f _ {t} \left(\mathbf {u} _ {t}\right) \leq \mathcal {O} \left(\sqrt {\left(F _ {T} + P _ {T}\right) \left(1 + P _ {T}\right)}\right), \tag {8}
+$$
+
+where $F_{T} = \sum_{t=1}^{T} f_{t}(\mathbf{u}_{t})$ is the cumulative loss of the comparators.
+
+# 3 Adaptive Regret Minimization
+
+In this section, we present our efficient methods to minimize adaptive regret. First, we briefly review existing methods in Section 3.1, and then present our efficient methods to reducing the projection complexity of adaptive regret methods in Section 3.2.
+
+# 3.1 A Brief Review of Adaptive Regret Minimization
+
+Adaptive regret minimization ensures the online learner to be competitive with a fixed decision over every contiguous interval. For the worst-case bound, the best known result is the $\mathcal{O}(\sqrt{|I| \log T})$ adaptive regret bound achieved by the CBCE algorithm [Jun et al., 2017]. CBCE algorithm requires multiple gradients at each round. Wang et al. [2018] improve CBCE by using the linearized loss to make it requiring one gradient per iteration and retaining the same adaptive regret. Moreover, the improved CBCE algorithm only evaluates the function value once per iteration. Therefore, we can directly apply our reduction and obtain a projection-efficient variation with the same adaptive regret. More detailed elaborations can be found in Appendix C.1.
+
+Now, we focus on the more challenging case of small-loss adaptive regret. The best known result is the $\mathcal{O}(\sqrt{F_I\log F_I\log F_T})$ bound for any interval $I = [r,s]\subseteq [T]$ obtained by the SACS algorithm [Zhang et al., 2019], where $F_{I} = \min_{\mathbf{x}\in \mathcal{X}}\sum_{t = r}^{s}f_{t}(\mathbf{x})$ and $F_{T} = \min_{\mathbf{x}\in \mathcal{X}}\sum_{t = 1}^{T}f_{t}(\mathbf{x})$ . However, SACS does not satisfy our reduction requirements, because it requires $N$ gradient queries (i.e., $\nabla f_t(\mathbf{x}_{t,i})$ for $i\in [N]$ ) and $N + 1$ function evaluations (i.e., $f_{t}(\mathbf{x}_{t,i})$ for $i\in [N]$ , and $f_{t}(\mathbf{x}_{t,i})$ ) at round $t\in [T]$ , where $N$ denotes the number of active base-learners and $\mathbf{x}_{t,i}$ denotes local decision returned by the $i$ -th base-learner. To address so, we have to modify the algorithm to fit our purpose.
+
+In the following, we first sketch the SACS algorithm and then present our modifications. In fact, to optimize the adaptive regret, an online algorithm usually consists of the three components:
+
+(i) base-algorithm: an online algorithm that can attain low (static) regret in a given interval;
+(ii) scheduling: a set of intervals and each one is associated with a base-learner who aims to minimize the static regret over the interval (from starting time to ending time);
+(iii) meta-algorithm: a combining algorithm that can track the best base-learner on the fly.
+
+The specific configurations of the SACS algorithm is as follows. First, SACs use scale-free online gradient descent (SOGD) [Orabona and Pál, 2018] as the base-algorithm, which ensures a small-loss regret in a given interval. Second, SACs employs AdaNormalHedge [Luo and Schapire, 2015] as the meta-algorithm, which supports the sleeping expert setup and also enjoys a small-loss regret. Finally, SACs designs a clever strategy of problem-dependent geometric covers to determine the set of intervals such that the number of active base-learners also depends on the small-loss quantity. As a result, SACs can achieve a fully problem-dependent adaptive regret of order $\mathcal{O}(\sqrt{F_I\log F_I\log F_T})$ scaling with the cumulative loss of comparators. However, SACs also suffers from an $\mathcal{O}(\log T)$ projection complexity in the worst case due to a two-layer structure; and moreover, it can be observed that SACs only attains an $\mathcal{O}(\sqrt{|I|\log|I|\log T})$ bound in the worst case, which exhibits an $\sqrt{\log|I|$ gap compared with the best known result of $\mathcal{O}(\sqrt{|I|\log T})$ [Jun et al., 2017]. Below, we present an efficient algorithm for small-loss adaptive regret, which resolves the above two issues simultaneously.
+
+# 3.2 Efficient Algorithms for Adaptive Regret
+
+As multiple gradient queries and function evaluations are involved in all the three components of SACS, we have to make plenty of modifications to achieve an algorithm with small-loss adaptive regret yet requiring only one gradient query and function evaluation per round. With such an algorithm on hand, we can then deploy our reduction to achieve an efficient method with 1 projection complexity. Below we present the details. By the reduction mechanism, it is noticeable that we only need to consider the input online functions as surrogate loss $\{g_t\}_{t=1}^T$ , where $g_t$ is defined in Eq. (5).
+
+Base-algorithm. We use SOGD with a linearized surrogate loss $\langle \nabla g_t(\mathbf{y}_t),\mathbf{y}\rangle$ over the surrogate domain $\mathcal{V}$ . Denote by $A_{t}$ the set of active base-learners' indices, then the base-learner $\mathcal{B}_i$ updates by
+
+$$
+\mathbf {y} _ {t + 1, i} = \Pi_ {\mathcal {Y}} \left[ \mathbf {y} _ {t, i} - \eta_ {t, i} \nabla g _ {t} \left(\mathbf {y} _ {t}\right) \right], \tag {9}
+$$
+
+with $\eta_{t,i} = D / \sqrt{(\delta + \sum_{s = \tau_i}^t\| \nabla g_s(\mathbf{y}_s)\|_2^2)}$ , where $\tau_{i}$ denotes the starting time of the base-learner $i\in A_t$ . The projection onto $\mathcal{V}$ can be easily calculated by a simple rescaling if needed. Notably, owing to the convexity of the surrogate loss $g_{t}$ , we can use the same gradient $\nabla g_{t}(\mathbf{y}_{t})$ for all the base-learners at each round, ensuring one gradient query of $\nabla f_{t}(\mathbf{x}_{t})$ at each round.
+
+Geometric Covers. The covers consist of a set of intervals that specify the alive time of base-learners. To achieve a small-loss adaptive regret, SACS [Zhang et al., 2019] employs a clever covering construction called problem-dependent geometric covers (PGC) — instead of initiating a base-learner at each round $t$ like earlier algorithms [Daniely et al., 2015; Jun et al., 2017], SACS adds a new base-learner only when the cumulative loss exceeds a pre-defined threshold. As a result, the number of active base-learners relates to the small-loss quantity such that the overall algorithm achieves a fully problem-dependent adaptive regret. Notably, to determine the threshold, SACS monitors the cumulative loss of the latest base-learner $f_{t}(\mathbf{x}_{t,i^{\dagger}})$ with $i^{\dagger}$ being the latest base-learner's index, but clearly this will introduce an additional function evaluation beyond $f_{t}(\mathbf{x}_{t})$ at each round.
+
+To avoid the limitation, instead of using a fixed threshold to decide the initiations of base-learners, we design a sequence of time-varying thresholds to adaptively start a new base-learner according to amount of cumulative loss of final decisions (e.g., $f_{t}(\mathbf{x}_{t})$ ), bypassing the requirement of additional function evaluation. This realizes the condition of one function evaluation per round. Also, the new design of thresholds mechanism is important to ensure that the overall small-loss bound can simultaneously recover the best known worst-case guarantee, which SACS fails to achieve [Zhang et al., 2019]. Let $C_1, C_2, C_3, \ldots$ denote the sequence of thresholds, and they will be determined by a threshold generating function $\mathcal{G}(\cdot): \mathbb{N} \mapsto \mathbb{R}_+$ that will be specified later. Our problem-dependent geometric covers are set as follows. We initialize the setting by $s_1 = 1$ . We set $s_2$ as the round when the cumulative loss of the overall algorithm (namely, $\sum_{s=1}^{t} f_s(\mathbf{x}_s)$ ) exceeds the threshold $C_1$ and then initialize a new instance of SOGD starting at this round. The process is repeated until the end of online game. We thus generate a sequence of points $s_1, s_2, \ldots$ , referred to as the markers. See
+
+Algorithm 2 Efficient Algorithm for Problem-dependent Adaptive Regret
+Input: threshold generating function $\mathcal{G}(\cdot):\mathbb{N}\mapsto \mathbb{R}_{+}$
+1: Initialize total intervals $m = 1$ , marker $s_1 = 1$ , threshold $C_1 = \mathcal{G}(1)$ ; let $\mathbf{x}_1$ be any point in $\mathcal{X}$
+2: for $t = 1$ to $T$ do
+3:Receive the gradient information $\nabla f_t(\mathbf{x}_t)$
+4: Construct the surrogate loss $g_{t}:\mathcal{V}\mapsto \mathbb{R}$ according to Eq. (5).
+5: Compute the (sub-)gradient $\nabla g_{t}(\mathbf{y}_{t})$ according to Lemma 1.
+6: Compute $L_{t} = L_{t - 1} + f_{t}(\mathbf{x}_{t})$ $\%$ constructing Problem-dependent Geometric Covers(PGC)
+7: if $L_{t} > C_{m}$ then
+8: Set $L_{t} = 0$ , remove base-learners $\mathcal{B}_k$ whose ending point $e_k = m + 1$
+9: Set $m\gets m + 1$ $s_m\gets t$ $C_m = \mathcal{G}(m)$
+10: Initialize a new base-learner with ending point $e_m = j$ satisfying $[m,j - 1]\in \mathcal{C}$ , where $\mathcal{C} = \bigcup_{k\in \mathbb{N}\cup \{0\}}\mathcal{C}_k$ and $\mathcal{C}_k = \left\{\left[i\cdot 2^k,(i + 1)\cdot 2^k -1\right]\mid i\text{is odd}\right\}$ for all $k\in \mathbb{N}\cup \{0\}$
+11: Set $\gamma_{m} = \ln (1 + 2m)$ $w_{t,m} = 1$ $\eta_{t,m} = \min \{1 / 2,\sqrt{\gamma_m}\}$ for the meta-algorithm.
+12: end if
+13: Send $\nabla g_t(\mathbf{y}_t)$ to all base-learners and obtain local predictions $\mathbf{y}_{t + 1,i}$ for $i\in A_t$
+14: Meta-algorithm updates weight $p_{t + 1}\in \Delta_{|A_{t + 1}|}$ according to Eq. (11), Eq. (12), and Eq. (13)
+15: Compute $\mathbf{y}_{t + 1} = \sum_{i\in A_{t + 1}}p_{t + 1,i}\mathbf{y}_{t + 1,i}$
+16: Submit $\mathbf{x}_{t + 1} = \Pi_{\mathcal{X}}[\mathbf{y}_{t + 1}]$ . ▷ The only projection onto feasible domain $\mathcal{X}$ per round.
+17: end for
+
+the condition in Line 7, registration of markers in Line 9, and the overall updates in Lines 7 - 11 of Algorithm 2. Those markers specify the starting time (and the ending time) of base-learners and thus construct the PGC as
+
+$$
+\widetilde {\mathcal {C}} = \bigcup_ {k \in \mathbb {N} \cup \{0 \}} \widetilde {\mathcal {C}} _ {k}, \text {w h e r e} \widetilde {\mathcal {C}} _ {k} = \left\{\left[ s _ {i \cdot 2 ^ {k}}, s _ {(i + 1) \cdot 2 ^ {k}} - 1 \right] \mid i \text {i s o d d} \right\} \text {f o r a l l} k \in \mathbb {N} \cup \{0 \}. \tag {10}
+$$
+
+It is noteworthy to emphasize that PGC is constructed by the language of "marker", whose exact time stamp is unknown ahead of time but is only determined according to the learner's performance on the fly. Moreover, the notation $\mathcal{C}$ in Lines 10 of Algorithm 2 is defined based on the registered indexes of markers, and there is a one-one correspondence from the interval in $\mathcal{C}$ to that in PGC $\widetilde{\mathcal{C}}$ . More concretely, an interval $[i \cdot 2^k, (i + 1) \cdot 2^k - 1] \in \mathcal{C}$ will be mapped into the interval $[s_{i \cdot 2^k}, s_{(i + 1) \cdot 2^k} - 1]$ in PGC, managing the alive time of base-learners in a geometric manner with respect to the subscripts.
+
+Meta-algorithm. SACS uses the AdaNormalHedge [Luo and Schapire, 2015] as the meta-algorithm, however, this is not suitable for our propose. To ensure one projection per iteration, we cannot use multiple function values, i.e., $\{g_t(\mathbf{y}_{t,i})\}_{i=1}^N$ , for meta-algorithm to evaluate the loss. Instead, we can only use the linearized loss value, namely, $\{\langle \nabla g_t(\mathbf{y}_t), \mathbf{y}_{t,i} \rangle\}_{i=1}^N$ in the weight update of meta-algorithm. The small-loss regret bound in the meta-algorithm of SACS crucially relies on the original function values, which is unfortunately inaccessible in our case. Technically, when fed with linearized loss, it is hard to establish a squared gradient-norm bound and then convert it to the small loss due to the first-order regret bound of AdaNormalHedge. Based on this crucial technical observation, we propose to use the Adapt-ML-Prod algorithm [Gaillard et al., 2014] as the meta-algorithm in our method. The key advantage is that it enjoys a second-order regret and also supports the sleeping expert setup. Adapt-ML-Prod maintains multiple learning rates $\eta_{t+1}$ and an intermediate weight vector $\mathbf{w}_{t+1}$ , which are updated by the following rule. For any active base-learner $i \in A_{t+1}$ ,
+
+$$
+\eta_ {t + 1, i} = \min \left\{\frac {1}{2}, \sqrt {\frac {\gamma_ {i}}{1 + \sum_ {k = s _ {i}} ^ {t} (\widehat {\ell} _ {k} - \ell_ {k , i}) ^ {2}}} \right\}, w _ {t + 1, i} = \left(w _ {t, i} \left(1 + \eta_ {t, i} \left(\widehat {\ell} _ {t} - \ell_ {t, i}\right)\right)\right) ^ {\frac {\eta_ {t + 1 , i}}{\eta_ {t , i}}}, \tag {11}
+$$
+
+where $\gamma_{i} = \ln (1 + 2i)$ is a certain scaling factor and the feedback loss is constructed as for $i\in A_t$
+
+$$
+\widehat {\ell} _ {t} = \left\langle \nabla g _ {t} (\mathbf {y} _ {t}), \mathbf {y} _ {t} \right\rangle / (2 G D), \text {a n d} \ell_ {t, i} = \left\langle \nabla g _ {t} (\mathbf {y} _ {t}), \mathbf {y} _ {t, i} \right\rangle / (2 G D). \tag {12}
+$$
+
+The final weight vector $\pmb{p}_{t + 1}\in \Delta_{|A_{t + 1}|}$ is obtained by
+
+$$
+p _ {t + 1, i} = \frac {w _ {t + 1 , i} \cdot \eta_ {t + 1 , i}}{\sum_ {j \in A _ {t + 1}} w _ {t + 1 , j} \cdot \eta_ {t + 1 , j}}. \tag {13}
+$$
+
+Notably, the meta update only uses one gradient at round $t$ , namely, $\nabla g_t(\mathbf{y}_t)$ .
+
+Finally, we compute $\mathbf{y}_{t + 1} = \sum_{i\in A_{t + 1}}p_{t + 1,i}\mathbf{y}_{t + 1,i}$ as the overall prediction in the surrogate domain $\mathcal{V}$ and calculate $\mathbf{x}_{t + 1} = \Pi_{\mathcal{X}}[\mathbf{y}_{t + 1}]$ to ensure the feasibility. This is the only projection onto $\mathcal{X}$ at each round. Algorithm 2 summarizes the main procedures of our efficient methods for small-loss adaptive regret. Albeit with a similar two-layer structure as SACS, our algorithm exhibits salient differences in base-algorithm, meta-algorithm, and geometric covers. As a benefit, we can successfully deploy our reduction mechanism and make the overall algorithm project onto the feasible domain $\mathcal{X}$ once per round, see Line 16. Our method retains the same small-loss adaptive regret as [Zhang et al., 2019].
+
+Theorem 4. Under Assumptions 1-3, setting the threshold generating function $\mathcal{G}(m) = \Theta (\log m)$ whose explicit form is in Eq. (46) of Appendix C, Algorithm 2 requires only one projection onto $\mathcal{X}$ per round and enjoys the small-loss adaptive regret:
+
+$$
+\sum_ {t = r} ^ {s} f _ {t} \left(\mathbf {x} _ {t}\right) - \sum_ {t = r} ^ {s} f _ {t} (\mathbf {u}) \leq \mathcal {O} \left(\min \left\{\sqrt {F _ {I} \log F _ {I} \log F _ {T}}, \sqrt {| I | \log T} \right\}\right) \tag {14}
+$$
+
+for any interval $I = [r,s] \subseteq [T]$ , where $F_{I} = \min_{\mathbf{x} \in \mathcal{X}} \sum_{t=r}^{s} f_{t}(\mathbf{x})$ and $F_{T} = \min_{\mathbf{x} \in \mathcal{X}} \sum_{t=1}^{T} f_{t}(\mathbf{x})$ .
+
+Remark 1. Note that the $\mathcal{O}(\sqrt{F_I\log F_I\log F_T})$ small-loss bound of Zhang et al. [2019] becomes $\mathcal{O}(\sqrt{|I|\log|I|\log T})$ in the worst case, looser than the $\mathcal{O}(\sqrt{|I|\log T})$ bound [Jun et al., 2017] by a factor of $\log |I|$ . We show that this limitation can be actually avoided by the new design of thresholds mechanism and a refined analysis. More discussions can be found in Appendix C.3. Indeed, our result in (14) can strictly match the best known problem-independent result in the worst case.
+
+# 4 Experiment
+
+In this section, we provide empirical studies to evaluate our proposed methods.
+
+General Setup. We conduct experiments on the synthetic data. We consider the following online regression problem. Let $T$ denote the number of total rounds. At each round $t \in [T]$ the learner outputs the model parameter $\mathbf{w}_t \in \mathcal{W} \subseteq \mathbb{R}^d$ and simultaneously receives a data sample $(x_t, y_t)$ with $x_t \in \mathcal{X} \subseteq \mathbb{R}^d$ being the feature and $y_t \in \mathbb{R}$ being the corresponding label. The learner can then evaluate her model by the online loss $f_t(\mathbf{w}_t) = \frac{1}{2}(x_t^\top \mathbf{w}_t - y_t)^2$ which uses a square loss to evaluate the difference between the predictive value $x_t^\top \mathbf{w}_t$ and the ground-truth label $y_t$ , and then use the feedback information to update the model. In the simulations, we set $T = 20000$ , the domain diameter as $D = 6$ , and the dimension of the domain as $d = 8$ . The feasible domain $\mathcal{W}$ is set as an ellipsoid $\mathcal{W} = \{\mathbf{w} \in \mathbb{R}^d | \mathbf{w}^\top \mathbf{E} \mathbf{w} \leq \lambda_{\min}(\mathbf{E}) \cdot (D/2)^2\}$ , where $\mathbf{E}$ is a certain diagonal matrix and $\lambda_{\min}(\mathbf{E})$ denotes its minimum eigenvalue. Then, a projection onto $\mathcal{W}$ requires solving a convex programming that is generally expensive. In the experiment, we use scipy.optimize.NonlinearConstraint to solve it to perform the projection onto the feasible domain.
+
+To simulate the non-stationary online environments, we control the way to generate the date samples $\{(x_{t},y_{t})\}_{t = 1}^{T}$ . Specifically, for $t\in [T]$ , the feature $x_{t}$ is randomly sampled in an Euclidean ball with a diameter $D$ same as the feasible domain of model parameters; and the corresponding label is set as $y_{t} = x_{t}^{\top}\mathbf{w}_{t}^{*} + \varepsilon_{t}$ , where $\varepsilon_{t}$ is the random noise drawn from $[0,0.1]$ and $\mathbf{w}_t^*$ is the underlying ground-truth model from the feasible domain $\mathcal{W}$ generated according to a certain strategy specified below. For dynamic regret minimization, we simulate piecewise-stationary model drifts, as dynamic regret will be linear in $T$ and thus vacuous when the model drift happens every round due to a linear path length measure. Concretely, we split the time horizon evenly into 25 stages and restrict the underlying model parameter $\mathbf{w}_t^*$ to be stationary within a stage. For adaptive regret minimization, we simulate gradually evolving model drifts, where the underlying model parameter $\mathbf{w}_{t + 1}^{*}$ is generated based on the last-round model parameter $\mathbf{w}_t^*$ with an additional random walk in the feasible domain $\mathcal{W}$ . The step size of random walk is set to be proportional to $D / T$ to ensure a smooth model change.
+
+Contenders. For both dynamic regret and adaptive regret minimization, we directly work on the small-loss online methods. We choose the Sword algorithm [Zhao et al., 2021b] as the contender of
+
+
+(a) dynamic regret (loss)
+
+
+Figure 1: Performance comparisons of existing methods and our methods (indicated by "efficient" prefix) in terms of cumulative loss and running time (in seconds). The first two figures plot the results of methods for dynamic regret minimization, while the latter ones are for adaptive regret.
+
+
+(b) dynamic regret (time)
+
+
+(c) adaptive regret (loss)
+(d) adaptive regret (time)
+
+our efficient method for dynamic regret (Algorithm 1) and choose the SACS algorithm [Zhang et al., 2019] as the contender of our efficient method for adaptive regret (Algorithm 2).
+
+Results. We repeat the experiments for five times with different random seeds and report the results (mean and standard deviation) in Figure 1. We use a machine with a single CPU (Intel(R) Core(TM) i9-10900K CPU @ 3.70GHz) and 32GB main memory to conduct the experiments. We plot both cumulative loss and running time (in seconds) for all the methods. We first examine the performance of dynamic regret minimization, see Figure 1(a) for cumulative loss and see Figure 1(b) for running time. The empirical results show that our method has a comparable performance to Sword without much sacrifice of cumulative loss, while our method can achieve about 10 times speedup due to the improved projection complexity. Second, as shown in Figure 1(c) and Figure 1(d), a similar performance enhancement also appears in adaptive regret minimization, though the speedup is slightly smaller due to the fact that fewer learners are required to maintain for adaptive regret. To summarize, the empirical results show the effectiveness of our methods in retaining the regret performance and also the efficiency in terms of the running time due to the reduced projection complexity.
+
+# 5 Conclusion
+
+In this paper, we design a generic reduction mechanism that can reduce the projection complexity of two-layer methods for non-stationary online learning, hence approaching a clearer resolution of necessary computational overhead for robustness to non-stationarity. Building on the reduction mechanism, we develop a series of online algorithms for optimizing dynamic regret and adaptive regret. All the algorithms retain the best known regret guarantees, and more importantly, require one projection onto the feasible domain per iteration. It is further worth mentioning that, due to the requirement of our reduction, all our algorithms only need one gradient query and one function evaluation at each round as well, which can be appealing in situations with limited feedback.
+
+Our reduction can also be applied to other settings to achieve light project complexity, for example, dynamic regret of OCO with memory [Zhao et al., 2022b], OCO with switching cost [Zhang et al., 2021], and related applications such as online non-stochastic control [Hazan et al., 2020]. Moreover, it is possible to derive similar efficient algorithms for minimizing the interval dynamic regret, an even stringent measure for non-stationary online convex optimization. There is one important open question left on another type of problem-dependent bound that scales with gradient variation [Chiang et al., 2012], which plays an important role in establishing fast convergence in zero-sum games [Syrgkanis et al., 2015; Zhang et al., 2022]. Although Zhao et al. [2021b] have devised a two-layer method that enjoys a gradient-variation dynamic regret and requires one gradient per iteration, it is quite challenging to incorporate the optimistic online learning into our reduction mechanism due to the constrained feasible domain and the complicated two-layer structure. Finally, it would be greatly important to further understand the minimal computational overhead in response to the robustness to non-stationarity, in particular, some information-theoretic arguments would be highly interesting.
+
+# Acknowledgements
+
+This research was supported by NSFC (61921006, 62206125), JiangsuSF (BK20220776), National Postdoctoral Program for Innovative Talent, and Collaborative Innovation Center of Novel Software Technology and Industrialization.
+
+# References
+
+P. Auer, N. Cesa-Bianchi, and C. Gentile. Adaptive and self-confident on-line learning algorithms. Journal of Computer and System Sciences, 64(1):48-75, 2002.
+D. Baby and Y.-X. Wang. Optimal dynamic regret in exp-concave online learning. In Proceedings of the 34th Conference on Learning Theory (COLT), pages 359-409, 2021.
+C.-K. Chiang, T. Yang, C.-J. Lee, M. Mahdavi, C.-J. Lu, R. Jin, and S. Zhu. Online optimization with gradual variations. In Proceedings of the 25th Conference On Learning Theory (COLT), pages 6.1-6.20, 2012.
+A. Cutkosky. Parameter-free, dynamic, and strongly-adaptive online learning. In Proceedings of the 37th International Conference on Machine Learning (ICML), pages 2250-2259, 2020.
+A. Cutkosky and F. Orabona. Black-box reductions for parameter-free online learning in banach spaces. In Proceedings of the 31st Conference on Learning Theory (COLT), pages 1493-1529, 2018.
+A. Daniely, A. Gonen, and S. Shalev-Shwartz. Strongly adaptive online learning. In Proceedings of the 32nd International Conference on Machine Learning (ICML), pages 1405-1411, 2015.
+Y. Freund and R. E. Schapire. A decision-theoretic generalization of on-line learning and an application to boosting. Journal of Computer and System Sciences, 55(1):119-139, 1997.
+P. Gaillard, G. Stoltz, and T. van Erven. A second-order bound with excess losses. In Proceedings of the 27th Conference on Learning Theory (COLT), pages 176-196, 2014.
+E. C. Hall and R. Willett. Dynamical models and tracking regret in online convex programming. In Proceedings of the 30th International Conference on Machine Learning (ICML), pages 579-587, 2013.
+E. Hazan. Introduction to Online Convex Optimization. Foundations and Trends in Optimization, 2 (3-4):157-325, 2016.
+E. Hazan and C. Seshadhri. Efficient learning algorithms for changing environments. In Proceedings of the 26th International Conference on Machine Learning (ICML), pages 393-400, 2009.
+E. Hazan, S. M. Kakade, and K. Singh. The nonstochastic control problem. In Proceedings of the 31st International Conference on Algorithmic Learning Theory (ALT), pages 408-421, 2020.
+K.-S. Jun, F. Orabona, S. Wright, and R. Willett. Improved strongly adaptive online learning using coin betting. In Proceedings of the 20th International Conference on Artificial Intelligence and Statistics (AISTATS), pages 943-951, 2017.
+H. Luo and R. E. Schapire. Achieving all with no parameters: AdaNormalHedge. In Proceedings of the 28th Annual Conference Computational Learning Theory (COLT), pages 1286-1304, 2015.
+Z. Mhammedi, W. M. Koolen, and T. van Erven. Lipschitz adaptivity with multiple learning rates in online learning. In Proceedings of the 32nd Annual Conference Computational Learning Theory (COLT), pages 2490-2511, 2019.
+F. Orabona. A Modern Introduction to Online Learning. ArXiv preprint, 1912.13213, 2019.
+F. Orabona and D. Pál. Scale-free online learning. Theoretical Computer Science, 716:50-69, 2018.
+R. Pogodin and T. Lattimore. On first-order bounds, variance and gap-dependent bounds for adversarial bandits. In Proceedings of the 35th Conference on Uncertainty in Artificial Intelligence (UAI), pages 894-904, 2019.
+S. Shalev-Shwartz. Online Learning: Theory, Algorithms and Applications. PhD Thesis, 2007.
+S. Shalev-Shwartz. Online Learning and Online Convex Optimization. Foundations and Trends in Machine Learning, 4(2):107-194, 2012.
+N. Srebro, K. Sridharan, and A. Tewari. Smoothness, low noise and fast rates. In Advances in Neural Information Processing Systems 23 (NIPS), pages 2199-2207, 2010.
+V. Syrgkanis, A. Agarwal, H. Luo, and R. E. Schapire. Fast convergence of regularized learning in games. In Advances in Neural Information Processing Systems 28 (NIPS), pages 2989-2997, 2015.
+T. van Erven and W. M. Koolen. Metagraph: Multiple learning rates in online learning. In Advances in Neural Information Processing Systems 29 (NIPS), pages 3666-3674, 2016.
+
+G. Wang, D. Zhao, and L. Zhang. Minimizing adaptive regret with one gradient per iteration. In Proceedings of the 27th International Joint Conference on Artificial Intelligence (IJCAI), pages 2762-2768, 2018.
+L. Zhang. Online learning in changing environments. In Proceedings of the 29th International Joint Conference on Artificial Intelligence (IJCAI), pages 5178-5182, 2020. Early Career.
+L. Zhang, S. Lu, and Z.-H. Zhou. Adaptive online learning in dynamic environments. In Advances in Neural Information Processing Systems 31 (NeurIPS), pages 1330-1340, 2018a.
+L. Zhang, T. Yang, R. Jin, and Z.-H. Zhou. Dynamic regret of strongly adaptive methods. In Proceedings of the 35th International Conference on Machine Learning (ICML), pages 5877-5886, 2018b.
+L. Zhang, T.-Y. Liu, and Z.-H. Zhou. Adaptive regret of convex and smooth functions. In Proceedings of the 36th International Conference on Machine Learning (ICML), pages 7414-7423, 2019.
+L. Zhang, S. Lu, and T. Yang. Minimizing dynamic regret and adaptive regret simultaneously. In Proceedings of the 23rd International Conference on Artificial Intelligence and Statistics (AISTATS), pages 309-319, 2020.
+L. Zhang, W. Jiang, S. Lu, and T. Yang. Revisiting smoothed online learning. In Advances in Neural Information Processing Systems 34 (NeurIPS), pages 13599-13612, 2021.
+M. Zhang, P. Zhao, H. Luo, and Z.-H. Zhou. No-regret learning in time-varying zero-sum games. In Proceedings of the 39th International Conference on Machine Learning (ICML), pages 26772-26808, 2022.
+P. Zhao, Y.-J. Zhang, L. Zhang, and Z.-H. Zhou. Dynamic regret of convex and smooth functions. In Advances in Neural Information Processing Systems 33 (NeurIPS), pages 12510-12520, 2020.
+P. Zhao, G. Wang, L. Zhang, and Z.-H. Zhou. Bandit convex optimization in non-stationary environments. Journal of Machine Learning Research, 22(125):1-45, 2021a.
+P. Zhao, Y.-J. Zhang, L. Zhang, and Z.-H. Zhou. Adaptivity and non-stationarity: Problem-dependent dynamic regret for online convex optimization. ArXiv preprint, arXiv:2112.14368, 2021b.
+P. Zhao, L.-F. Li, and Z.-H. Zhou. Dynamic regret of online markov decision processes. In Proceedings of the 39th International Conference on Machine Learning (ICML), pages 26865-26894, 2022a.
+P. Zhao, Y.-X. Wang, and Z.-H. Zhou. Non-stationary online learning with memory and non-stochastic control. In Proceedings of the 25th International Conference on Artificial Intelligence and Statistics (AISTATS), pages 2101-2133, 2022b.
+Z.-H. Zhou. Open-environment machine learning. National Science Review, 9(8):nwac123, 2022.
+M. Zinkevich. Online convex programming and generalized infinitesimal gradient ascent. In Proceedings of the 20th International Conference on Machine Learning (ICML), pages 928-936, 2003.
+
+# Checklist
+
+The checklist follows the references. Please read the checklist guidelines carefully for information on how to answer these questions. For each question, change the default [TODO] to [Yes], [No], or [N/A]. You are strongly encouraged to include a justification to your answer, either by referencing the appropriate section of your paper or providing a brief inline description.
+
+Please do not modify the questions and only use the provided macros for your answers. Note that the Checklist section does not count towards the page limit. In your paper, please delete this instructions block and only keep the Checklist section heading above along with the questions/answers below.
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See discussions in Section 5
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [N/A]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientmethodsfornonstationaryonlinelearning/images.zip b/efficientmethodsfornonstationaryonlinelearning/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..574db5dba2327d1935957c3fb28937c26cb6a836
--- /dev/null
+++ b/efficientmethodsfornonstationaryonlinelearning/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a1db02c66f4f4f01133a1a854bd47768a27ae6b39c793920e8115437e78160f0
+size 156996
diff --git a/efficientmethodsfornonstationaryonlinelearning/layout.json b/efficientmethodsfornonstationaryonlinelearning/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..d409fb4c58c1936b3a073e8bad07abb74c145837
--- /dev/null
+++ b/efficientmethodsfornonstationaryonlinelearning/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2a5b8744b703ef5a3110a2d9ad52523a5c4a4532ca0977a3217eed0a577f0648
+size 612496
diff --git a/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/dcee8e29-b4cc-4897-a155-993052ea2fd8_content_list.json b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/dcee8e29-b4cc-4897-a155-993052ea2fd8_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..8d470ec84480c158615a591618fa30c43564d051
--- /dev/null
+++ b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/dcee8e29-b4cc-4897-a155-993052ea2fd8_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ec2e4fbc589aba5727e74a4161a294a46d4e80118dd514e3bad5e1ba0673bc3e
+size 78097
diff --git a/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/dcee8e29-b4cc-4897-a155-993052ea2fd8_model.json b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/dcee8e29-b4cc-4897-a155-993052ea2fd8_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..2c71a4315c221b52317df551eeb69c513fd5b61d
--- /dev/null
+++ b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/dcee8e29-b4cc-4897-a155-993052ea2fd8_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c4fd637d3483540a63b8f6166c6db4c606ad846983092425085b8090a0dcfab9
+size 103721
diff --git a/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/dcee8e29-b4cc-4897-a155-993052ea2fd8_origin.pdf b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/dcee8e29-b4cc-4897-a155-993052ea2fd8_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..4b5d3c5acbd82a252eed7eb024cbaf04c3cf312f
--- /dev/null
+++ b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/dcee8e29-b4cc-4897-a155-993052ea2fd8_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3deb24220aa88566849849422ef95f2bd24a00b6c9c5295c667c19fef2c3d3a2
+size 5710391
diff --git a/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/full.md b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..c4d8af2e688f15faca10a146e8b99379f3a14839
--- /dev/null
+++ b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/full.md
@@ -0,0 +1,316 @@
+# Efficient Multi-agent Communication via Self-supervised Information Aggregation
+
+Cong Guan $^{1*}$ , Feng Chen $^{1*}$ , Lei Yuan $^{1,2}$ , Chenghe Wang $^{1}$ , Hao Yin $^{1}$ , Zongzhang Zhang $^{1}$ , Yang Yu $^{1,2\dagger}$
+
+$^{1}$ National Key Laboratory for Novel Software Technology, Nanjing University $^{2}$ Polixir Technologies
+
+{guanc, chenf, yuanl, wangch, yinh}@lamda.nju.edu.cn {zzzhang, yuy}@nju.edu.cn
+
+# Abstract
+
+Utilizing messages from teammates can improve coordination in cooperative Multi-agent Reinforcement Learning (MARL). To obtain meaningful information for decision-making, previous works typically combine raw messages generated by teammates with local information as inputs for policy. However, neglecting the aggregation of multiple messages poses great inefficiency for policy learning. Motivated by recent advances in representation learning, we argue that efficient message aggregation is essential for good coordination in MARL. In this paper, we propose Multi-Agent communication via Self-supervised Information Aggregation (MASIA), with which agents can aggregate the received messages into compact representations with high relevance to augment the local policy. Specifically, we design a permutation invariant message encoder to generate common information aggregated representation from raw messages and optimize it via reconstructing and shooting future information in a self-supervised manner. Each agent would utilize the most relevant parts of the aggregated representation for decision-making by a novel message extraction mechanism. Empirical results demonstrate that our method significantly outperforms strong baselines on multiple cooperative MARL tasks for various task settings.
+
+# 1 Introduction
+
+Multi-Agent Reinforcement Learning (MARL) [17] has attracted widespread attention [17, 8] recently, achieving remarkable success in many complex domains [1], such as traffic signal control [9], autonomous driving [59], and droplet control [24]. For better coordination on further applications, some issues like non-stationarity [33], scalability [3] remain to be solved. To solve the non-stationarity caused by the concurrent learning of multiple policies and scalability as the agent number increases, most recent works on MARL adopt the Centralized Training and Decentralized Execution (CTDE) [20, 27] paradigm, which includes both value-based methods [42, 36, 46, 53] and policy gradient methods [14, 26, 49, 52]. Under the CTDE paradigm, however, the coordination ability of the learned policies can be fragile due to the partial observability in the multi-agent environment, which is a common challenge in many multi-agent tasks [29]. While recurrent neural networks could in principle relieve this issue by conditioning the policy on action-observation history [16], the uncertainty of other agents (e.g., states and actions) at execution time can result in catastrophic miscoordination and even sub-optimality [48, 6].
+
+Communication shows great potential in solving these problems [55, 60], with which agents can share information such as observations, intentions, or experiences to stabilize the learning process, leading to a better understanding of the environment (or the other agents) and better coordination as a result. Previous communication methods either focus on generating meaningful information [48, 19, 57] for the message senders, or design techniques such as attention mechanism [4, 31], message gate [28, 6] to filter the most relevant information on raw received messages. These approaches treat the received information as a black box and tacitly assume that policy networks can automatically extract the most critical information from multiple raw messages during policy learning. On this occasion, with the only signal given by reinforcement learning, the extraction process may be reasonably inefficient, especially in complex scenarios.
+
+Motivated by recent advances in state representation learning [38, 22], which reveals that auxiliary representation objectives could facilitate policy learning [12], we aim at efficiently aggregating information as compact representations for policy by designing a novel communication framework Multi-Agent communication via Self-supervised Information Aggregation (MASIA). Specifically, representations are optimized through self-supervised objectives, which encourages the representations to be both abstract of the true states and predictive of the future information. Since agents are guided towards higher cumulative rewards during policy learning, correlating representations with true states and future information could intensify the learning signals in policy learning. In this way, the efficiency of policy learning could be encouraged. Also, considering that permutation invariance of representations can also promote efficiency, we design a self-attention mechanism to maintain the invariance of obtained representations. We also design a network that weighs the aggregated representation for individual agents to derive unique and highly relevant representation to augment local policies. To evaluate our method, we conduct extensive experiments on various cooperative multi-agent benchmarks, including Hallway [48], Level-Based Foraging [34], Traffic Junction [4], and two maps from StarCraft Multi-Agent Challenge (SMAC) [48]. The experimental results show that MASIA outperforms previous approaches, strong baselines, and ablations of our method.
+
+# Our main contributions are:
+
+- We propose a novel framework that uses a message aggregation network to extract from multiple messages generated by various teammates, with which we acquire a permutation invariant information aggregation representation. Agents can then use a novel focusing network to extract the most relevant information for decision-making.
+- Two representation objectives are introduced to make the information representation compact and sufficient, including the state reconstruction and multi-step future states prediction.
+- Sufficient experimental results on various benchmarks and communication conditions demonstrate that our proposed approach significantly improves the communication performance, and visualization results further reveal why it works.
+
+# 2 Problem Formulation
+
+This paper considers a fully cooperative MARL communication problem, which can be modeled as Decentralised Partially Observable Markov Decision Process under Communication (Dec-POMDPCom) [32] and formulated as a tuple $\langle \mathcal{N},\mathcal{S},\mathcal{A},P,\Omega ,O,R,\gamma ,\mathcal{M}\rangle$ , where $\mathcal{N} = \{1,\dots ,n\}$ is the set of agents, $S$ is the set of global states, $\mathcal{A}$ is the set of actions, $\Omega$ is the set of observations, $O$ is the observation function, $R$ represents the reward function, $\gamma \in [0,1)$ stands for the discounted factor, and $\mathcal{M}$ indicates the set of message. At each time step, due to partial observability, each agent $i\in \mathcal{N}$ can only acquire the observation $o_i\in \Omega$ drawn from the observation function $O(s,i)$ with $s\in S$ , each agent holds an individual policy $\pi (a_{i}\mid \tau_{i},m_{i})$ , where $\tau_{i}$ represents the history $(o_i^1,a_i^1,\ldots,o_i^{t - 1},o_i^{t - 1},o_i^t)$ of agent $i$ at current timestep $t$ , and $m_{i}\in \mathcal{M}$ is the message received by the agent $i$ . The joint action $\pmb {a} = \langle a_1,\dots ,a_n\rangle$ leads to next state $s^\prime \sim P(s^\prime \mid s,\pmb {a})$ and the global reward $R(s,a)$ . The formal objective is to find a joint policy $\pi (\tau ,\pmb {a})$ to maximize the global value function $Q_{\mathrm{tot}}^{\pi}(\tau ,\pmb {a}) = \mathbb{E}_{s,\pmb{a}}[\sum_{t = 0}^{\infty}\gamma^{t}R(s,\pmb {a})|s_{0} = s,\pmb{a}_{0} = \pmb {a},\pmb {\pi}]$ , with $\tau = \langle \tau_1,\dots ,\tau_n\rangle$ As each agent can behave as a message sender as well as a message receiver, this paper considers learning useful message representation in the received end, and agents only use local information $o_i$ as message to share within the team.
+
+We optimize the policy by value-based MARL, where deep Q-learning [30] implements the action-value function $Q(s, \pmb{a})$ with a deep neural network $Q(\pmb{\tau}, \pmb{a}; \pmb{\theta})$ parameterized by $\pmb{\theta}$ . This paper follows
+
+
+Figure 1: Structure of MASIA. (a) The overall architecture. (b) Information aggregation and extraction. (c) Information aggregation optimization. (d) Transition model learning.
+
+
+(b)
+
+
+(c)
+(d)
+
+the CTDE paradigm. In the centralized training phase, deep Q-learning uses a replay memory $\mathcal{D}$ to store the transition tuple $\langle \tau, \boldsymbol{a}, r, \tau' \rangle$ . We use $Q(\tau, \boldsymbol{a}; \boldsymbol{\theta})$ to approximate $Q(s, \boldsymbol{a}; \boldsymbol{\theta})$ to relieve the partial observability. Thus, the parameters $\boldsymbol{\theta}$ are learnt by minimizing the expected Temporal Difference (TD) error:
+
+$$
+\mathcal {L} (\boldsymbol {\theta}) = \mathbb {E} _ {(\boldsymbol {\tau}, \boldsymbol {a}, r, \boldsymbol {\tau} ^ {\prime}) \in \mathcal {D}} \left[ \left(r + \gamma V \left(\boldsymbol {\tau} ^ {\prime}; \boldsymbol {\theta} ^ {-}\right) - Q (\boldsymbol {\tau}, \boldsymbol {a}; \boldsymbol {\theta})\right) ^ {2} \right],
+$$
+
+where $V(\tau'; \theta^-) = \max_{\pmb{a}'} Q(\tau', \pmb{a}'; \theta^-)$ is the expected future return of the TD target and $\theta^-$ are parameters of the target network, which will be periodically updated with $\theta$ .
+
+# 3 Method
+
+In this paper, we propose efficient Multi-Agent communication via Self-supervised Information Aggregation (MASIA), a novel multi-agent communication mechanism for promoting cooperation performance. Redundant communications could increase the burden of information processing for each agent to make decisions and pose new challenges for information extraction since plenty of irrelevant information is contained in raw messages. To design an efficient communication mechanism, we believe two properties are of vital importance - sufficiency and compactness, where sufficiency means a rich amount of information, and compactness calls for higher information density.
+
+To meet the standard of sufficiency, a global encoder, which we call Information Aggregation Encoder (IAE), is shared among agents to aggregate the information broadcasted by agents into a common representation. With proper training, this representation could reflect the global observation so that each agent could obtain sufficient information from it to make decisions. As for compactness, we first design an auxiliary loss on the global representation to correlate it with the policy learning process, and make each agent only focus on the part of the representation related to its performance and coordination by the designed focusing network through excluding the unrelated parts. The entire framework of our method is shown in Fig. 1. We introduce the aggregation and extraction process in Sec. 3.1, and the objectives for compactness and sufficiency in Sec. 3.2. Also, a description of the training and execution process flow can be found in Appendix A.6.
+
+# 3.1 Information Aggregation and Extraction
+
+Information Aggregation. Believing that the true state should be reflected from combined messages, we design the aggregation encoder to be capable of subsuming all the messages sent from agents. Also, the communication system in multi-agent systems is flexible and permutation invariant in nature,
+
+which calls for a permutation invariant structure for the aggregation encoder. Based on these beliefs, we apply a self-attention mechanism to aggregate multiple messages from different teammates:
+
+$$
+\boldsymbol {Q}, \boldsymbol {K}, \boldsymbol {V} = \operatorname {M L P} _ {Q, K, V} ([ o _ {1} ^ {t}, \dots , o _ {i} ^ {t}, \dots , o _ {n} ^ {t} ]), \tag {1}
+$$
+
+$$
+\boldsymbol {H} = \operatorname {s o f t m a x} \left(\frac {\boldsymbol {Q} \boldsymbol {K} ^ {T}}{\sqrt {d _ {k}}}\right) \boldsymbol {V}, \tag {2}
+$$
+
+where the learnable matrices $Q$ , $K$ , and $V$ transform the perception from all agents into the corresponding query $Q$ , key $K$ , and value $V$ , which are the concepts defined in the attention mechanism [44]. Specifically, each row vector of $H$ can be seen as a querying result of one agent for all available information, and the hidden state $H$ will be fed into the subsequent integration network to finally obtain the output aggregated representation $z^t$ . A detailed discussion about the design of the integration network can be found in Appendix A.3.
+
+In the centralized training phase, we use the aggregated representation $z^t$ as extra inputs in addition to the individual observation to feed the value function. Since $z^t$ contains the information required to determine the true state, taking $z^t$ as extra inputs could reduce the uncertainty about the environment states and produce better estimations on the Q-value for value functions under any value-based policy learning algorithm.
+
+Information Extraction. Similar to the decision process of human beings, global messages are usually redundant for an individual agent to make good coordination in communication systems. For example, on the task of Traffic Junction [4], one natural idea is that the information of neighboring cars are more important for agents to perceive than those distant ones, and the unrelated information in global message may sometimes even confuse the agents and impede the learning when the map is large. A toy experiment shown in Fig. 2 supports this idea. We apply the QMIX algorithm in Traffic Junction tasks with different
+
+
+Figure 2: A toy experiment for information redundancy on the task of Traffic Junction.
+
+sight settings. The results show that the agents learn better policies when in a small-sight setting (sight-1) than both in a super-limited-sight setting (sight-0) and full-sight setting (sight-full).
+
+To make each agent capable of deciding its own perceptive area, we employ the focusing network to weigh the aggregated representations for each agent. The focusing network is designed as a Multi-Layer Perception (MLP) with the Sigmoid output activation function to ensure that each dimension of $w_{i}^{t}$ is bounded between 0 and 1. By taking element-wise multiplication with $z^{t}$ , a unique representation could be distilled for individual agents. In this way, if the focusing network produces higher weights on specific dimensions, changes in aggregated representations on these dimensions would be more significant and thus, the agent would be more sensitive to aggregated representation on these parts. On the contrary, if some near-zero weights are outputted on some dimensions, information on those dimensions would be filtered out. In particular, although the information extraction process can, to some extent, reflect the specificity of each agent, we stress the local information by feeding it into the subsequent network together with the extracted representation.
+
+# 3.2 Information Aggregation Representation Optimization
+
+As for the learning process of aggregated representation, we consider two typical objectives in global encoder training: reconstruction and multi-step prediction, which constrain the representations produced by the global encoder to be sufficient and compact, respectively. For the reconstruction objective, we employ an additional decoder, which aims to reconstruct the global state by the aggregated representation to allow self-supervision on the global encoder. Specifically, the decoder is optimized together with the aggregation encoder by reconstructing global states $s^t$ from messages $o^t$ :
+
+$$
+\mathcal {L} _ {a e} (\theta , \eta) = \mathbb {E} _ {\boldsymbol {o} ^ {t}, s ^ {t}} \| g _ {\eta} (z ^ {t}) - s ^ {t} \| _ {2} ^ {2}, \quad z ^ {t} = f _ {\theta} (\boldsymbol {o} ^ {t}), \tag {3}
+$$
+
+where $f_{\theta}, g_{\eta}$ denote the encoder network parameterized by $\theta$ and the decoder network parameterized by $\eta$ , respectively. This loss term resembles a classical auto-encoder loss, while the decoder here is
+
+not to reconstruct the input, but to recover the global state from representations instead. By utilizing this loss, we guide the encoder to extract observational features that can help infer the global state and let $z^{t} = f_{\theta}(\pmb{o}^{t})$ be a sufficient representation.
+
+As for the multi-step prediction objective, we constrain the produced representation to be predictive of future information. Specifically, we design a transition model $h_{\psi}:\mathcal{Z}\times \mathcal{A}^n\to \mathcal{Z}$ parameterized by $\psi$ as auxiliary model, which predicts the aggregated representation $z^{t + 1}$ on next step $t + 1$ through the aggregated representation $z^t$ and joint action $\pmb{a}^{t}$ on current step $t$ . We regress the predicted aggregated representation after $k$ -step rollout on the actual aggregated representation of future messages $o^{t + k}$ , updating both the aggregation encoder and the auxiliary model via the multi-step prediction loss:
+
+$$
+\mathcal {L} _ {m} (\theta , \psi) = \mathbb {E} _ {\boldsymbol {o} ^ {t}, s ^ {t}, \boldsymbol {a} ^ {t}, \dots , \boldsymbol {a} ^ {t + K - 1}, \boldsymbol {o} ^ {t + K}, s ^ {t + K}} \left[ \sum_ {k = 1} ^ {K} \| \hat {z} ^ {t + k} - \tilde {z} ^ {t + k} \| _ {2} ^ {2} \right], \tag {4}
+$$
+
+$$
+\hat {z} ^ {t + 1} = h _ {\psi} \left(\tilde {z} ^ {t}, \boldsymbol {a} ^ {t}\right), \tag {5}
+$$
+
+$$
+\hat {z} ^ {t + k} = h _ {\psi} \left(\hat {z} ^ {t + k - 1}, \boldsymbol {a} ^ {t + k - 1}\right), \quad k = 2, \dots , K, \tag {6}
+$$
+
+$$
+\tilde {z} ^ {t + k} = f _ {\theta} \left(\boldsymbol {o} ^ {t + k}\right), \quad k = 0, \dots , K. \tag {7}
+$$
+
+To further stabilize the learning process, we apply the double network technique, which employs two networks with the same architecture but different update frequencies, for the aggregation encoder. The target network is updated via Exponential Moving Average (EMA) like in SPR [38]. By forcing the aggregated representation to be predictive of its future states, the aggregated representation could be more correlated with the information required for its decision-making, which meets the compactness standard. Combining these two objectives allows the aggregation encoder to extract more helpful information for agents to coordinate better. To improve the capability of information extraction on individual agents, we also enhance the learning process of these components with an RL objective. Specifically, we consider minimizing the TD loss:
+
+$$
+\mathcal {L} _ {r l} (\theta , \phi) = \mathbb {E} _ {(\boldsymbol {\tau}, \boldsymbol {a}, r, \boldsymbol {\tau} ^ {\prime}) \in \mathcal {D}} \left[ \left(r + \gamma \max _ {\boldsymbol {a} ^ {\prime}} Q _ {\mathrm {t o t}} \left(\boldsymbol {\tau} ^ {\prime}, \boldsymbol {a} ^ {\prime}; \theta^ {-}, \phi^ {-}\right) - Q _ {\mathrm {t o t}} (\boldsymbol {\tau}, \boldsymbol {a}; \theta , \phi)\right) ^ {2} \right], \tag {8}
+$$
+
+where $Q_{\mathrm{tot}}$ is computed with individual $Q$ -values. The computation of Q-values is actually dependent on the specific value-based learning algorithm. We apply it to prevalent methods, including VDN [42], QMIX [36], and QPLEX [46]. Moreover, the updating of the focusing network is coupled to the RL objective, making the weights produced by the focusing network could be task-sensitive, which could also facilitate policy learning.
+
+# 4 Experiment
+
+We conduct experiments on various benchmarks with different communication request levels3. Specifically, we aim to answer the following questions in this section: 1) How does our method perform when compared with multiple baselines in various scenarios (Sec. 4.1)? 2) What kind of knowledge has been learned by the information aggregation encoder (Sec. 4.2)? 3) How can the information extraction module extract the most relevant information for the individual from the learned embedding space (Sec. 4.3)? 4) Can MASIA be applied to different value decomposition baselines to improve their coordination ability and robustness in various communication conditions (Sec. 4.4)? We compare MASIA against a variety of baselines, including communication-free methods and some state-of-the-art communication approaches. QMIX [36] is a strong communication-free baseline, and we use the implementation by PyMARL4 for comparison, which has shown excellent performance on diverse multi-agent benchmarks [37]. TarMAC utilizes an attention mechanism to select messages according to their relative importance. The implementation we used is provided by [48], denoted as TarMAC + QMIX. NDQ [48] aims at learning nearly decomposable Q functions via generating meaningful messages and communication minimization. TMC [57] applies a temporal smoothing technique at the message sender end to drastically reduce the amount of information exchanged between agents. For the ablation study, we design a baseline only different in the communication protocol, which adopts a full communication paradigm, where each agent gets message from all other teammates at each timestep, denoted as FullComm.
+
+
+(a) Hallway
+
+
+(b) LBF
+
+
+(c) Traffic Junction (TJ)
+
+
+(d) SMAC
+
+
+Figure 3: Multiple benchmarks used in our experiments.
+
+
+(a) Hallway: $4 \times 6 \times 10$
+(e) Hallway: $3 \times 5 - 4 \times 6 \times 10$
+Figure 4: Performance comparison with baselines on multiple benchmarks.
+
+
+(f) LBF: 20x20-10p-6f-s1
+
+
+(c) TJ: medium
+(g) TJ: hard
+
+
+(d) SMAC: 1o10b_vs_1r
+(h) SMAC: 1o2r_vs_4r
+
+We evaluate our proposed method on multiple benchmarks shown in Fig. 3. Hallway [48] is a cooperative environment under partial observability, where $m$ agents are randomly initialized at different positions and required to arrive at the goal $g$ simultaneously. We consider two scenarios with various agents and different groups, and different groups have to arrive at different times. Level Based Foraging (LBF) [34] is another cooperative partially observable grid world game, where agents coordinate to collect food concurrently. Traffic Junction (TJ) [4] is a popular benchmark used to test communication ability, where many cars move along two-way roads with one or more road junctions following the predefined routes, and we test on the medium and hard maps. Two maps named 1o2r_vs_4r and 1o10b_vs_1r from SMAC [48] require the agents to cooperate and communicate to get the position of the enemies. For evaluation, all results are reported with median performance with $95\%$ confidence interval on 5 random seeds. Details about benchmarks, network architecture and hyper-parameter choices of our method are all presented in Appendices A.1, and A.3, respectively.
+
+# 4.1 Communication Performance
+
+We first compare MASIA against multiple baselines to investigate the communication efficiency on various benchmarks. As illustrated in Fig. 4, MASIA achieves the best performance with low variance on all benchmarks, indicating MASIA's strong applicability in scenarios with various difficulties. In Hallway (Fig. 4a & Fig. 4e), where frequent communications are required for good performance (method without communication such as QMIX fails), other communication methods such as TarMAC, NDQ, and TMC achieve low performance or even fail in this environment. This indicates that inappropriate message generation or message selection would injure the learning process. We believe the reason why FullComm succeeds is that there is hardly any redundancy in agents' observations in Hallway. Our MASIA also succeeds in this environment, showing superiority over others. The dominating performance of MASIA is even more significant in extended Hallway
+
+
+(a)
+
+
+(b)
+Figure 5: (a) Information aggregation visualization. Each plotted dot represents an aggregated representation. The three different colors respectively represent three different initialization situations for the enemy entities. For example, type 0 shows the case when the enemies initialize at the lower right corner. To distinguish aggregated representations on different timesteps, we mark larger timesteps by darker shades of the dots. (b) Visualization of variations of selected agents' focus weight $w_{i}^{t}$ in a single episode. We use the horizontal axes for timesteps in one single episode and vertical axes for dimensions of the aggregated representation. The weight is reflected through luminance, and the darker the cell, the larger the weight.
+
+(Fig. 4e), where agents are separated into different groups. In this environment, MASIA can help agents extract information about their teammates and learn a coordination pattern more efficiently. In LBF (Fig. 4b & Fig. 4f), existing communication-based MARL methods like NDQ, Fullcomm, and TarMAC struggle due to the sparsity of rewards, especially when the foods are more sparsely distributed (Fig. 4f). In contrast to the performance of QMIX in Hallway, QMIX performs well in LBF, which is attributed to the fact that agents can observe the grids near them, and the mixing network of QMIX can help improve the coordination ability of the fixed group of agents in the training phase. Our method achieves comparable performance with QMIX and TarMAC, showing its strong coordination ability even in sparse reward scenarios. In Traffic Junction (Fig. 4c & Fig. 4g), TarMAC and NDQ have high variance due to the instability of their messages, while MASIA gains high sample efficiency and can generate steady messages since it aims to reconstruct the state. On the SMAC benchmarks (Fig. 4d & Fig. 4h), we test on two complex scenarios requiring communication to succeed, where one overseer is in active service to get the information of the enemies. Messages are demanded since the agents have limited sight, so other teammates need the overseer's messages to identify the enemies' positions. Our method MASIA can maintain the high efficiency of learning and always have competitive performance when converged, which is superior to other baselines.
+
+# 4.2 Insights into Information Aggregation Encoder
+
+To determine what kind of knowledge the encoder has learned through training, we conduct a visualization analysis on the map 1o2r_vs_4r from SMAC to demonstrate the information contained in the aggregation representation $z^t$ . We project the aggregation representation vectors into two-dimensional plane by t-SNE [43] in Fig 5a. We take trajectories from 3 scenarios of different types of initialization under a task where agents have to seek the enemy at the start, discover the enemy, and finally battle with it for better performance. It can be observed that (1) the aggregated representations could be well distinguished by phases. Projected representations in the seeking phase are far from those in the battle phase and closing phase. This implies that our learned representations could well reflect the true states. (2) the aggregated representations are first divergent in the seeking phase
+
+when enemies have been initialized, but become increasingly interlaced later until the closing phase, when enemies have been wiped out after a fierce battle. Since enemies are highly related to decision making, such a result verifies that the aggregated representations exploit also reward information. To sum up, the visualization results show that MASIA can extract valuable global information with these representations.
+
+# 4.3 Study about Individual Information Extraction
+
+To demonstrate the effectiveness of our information extraction module, we analyze the weights computed by the focusing network. Specifically, we select the TJ (medium) task for evaluation and compare the weights produced by two different agents. In this environment, agents could dynamically enter or leave the plane, making the agents staying in the environment flexible through time. It can be observed that agent 3 and agent 6 put focus on similar areas of the aggregated representation. Especially after timestep 15, when agents 3 and 6 are in similar situations and distant from the intersection, their focuses are nearly the same. This verifies that the global state information has been successfully extracted to individual agents. Also, on the top of the figure, we draw a figure to measure the relationship between the cosine similarity of weight vectors of different agents against timesteps. It reveals that the similarity of their focus rises after these two agents begin to proceed
+
+in the same line (indicated by the render images posted on the lower parts of Fig. 5 (b)). This also conforms to the intuition that similar messages should be extracted for similar observations.
+
+
+Figure 6: Performance comparison with varying sights, where $sn$ means the sight range is $n$ .
+
+# 4.4 Generality of Our Method
+
+We aim to verify that the proposed approach is agnostic to various sight ranges and applied value-based MARL methods. We first conduct experiments on the map 1o10b_vs_1r to show that MASIA could also generalize well on agents with limited observations. The results in Sec. 4.1 show the performance of MASIA when the agents have a sight range of 9. When we narrow the agents' sight ranges, as shown in Fig. 6, by receiving and aggregating messages from teammates, the performance of MASIA does not suffer from a significant drop. Our information aggregation and extraction modules prevent the agent from forfeiting knowledge about the state when the sight range is further limited.
+
+To show the generality of the MASIA framework, we also carry out experiments to integrate MASIA with current baselines, including VDN, QMIX, and QPLEX. As illustrated in Fig. 7, when integrated with MASIA, the performance of these baselines can be vastly im
+
+proved on the map 1o10b_vs_1r from SMAC. In this scenario, one overseer is in service to monitor the enemies. Without communication, the other agents have to search the map for the enemies exhaustively. While with reliable communication, they could communicate with each other and the overseer for better coordination. The results demonstrate that MASIA can efficiently aggregate the messages and improve the agents' coordination ability for these value-based MARL methods.
+
+
+Figure 7: The increase of winning rates brought about by MASIA on map 1o10b_vs_1r.
+
+# 5 Related Work
+
+Multi-agent reinforcement learning (MARL) has made prominent progress these years. Having emerged under the CTDE paradigm, many methods are designed to relieve the non-stationarity issue, and have made noticeable progress these years. Most of them can be roughly divided into policy-based and value-based methods. Typical policy gradient-methods involves MADDPG [26], COMA [14], MAAC [18], SQDDPG [47], FOP [58], and HAPPO [21] which explore the optimization of multi-agent policy gradient methods, while value-based methods mainly focus on the factorization of the global value function [45, 7]. VDN [42] applies a simple additive factorization to decompose the
+
+joint value function into agent-wise value functions. QMIX [36] structurally enforces the learned joint value function to be monotonic to the agent's utilities, which can represent a more affluent class of value functions. QPLEX [46] further takes a duplex dueling network architecture to factorize the joint value function, achieving a full expressiveness power of IGM [39].
+
+Multi-agent Communication Communication plays a promising role in multi-agent coordination under partial observability [11, 60]. Extensive researches have been made on learning communication protocols to improve performance on cooperative tasks [15, 13, 23, 51, 10, 25, 54, 50]. Previous works can be divided into two categories. One focuses on generating a meaningful message for the message senders. The simplest way is to treat the raw local observation, or the local information history as message [13, 40]. VBC [56] and TMC [57] apply techniques, such as variance-based control and temporal smoothing, in the sender end to make the generated messages meaningful and valuable for policy learning. NDQ [48] generates minimized messages for different teammates to learn nearly decomposable value functions, and optimize the message generator based on two different information-theory-based regularizers to achieve expressive communication. On the contrary, other works try to learn efficiently to extract the most useful message on the receiver end, and they design mechanisms to differentiate the importance of messages. I2C [6] and ACML [28] employ gate mechanism to be selective on received messages. There are also works inspired by the broad application of the attention mechanism [2, 5]. TarMAC [4] achieves targeted communication via a simple signature-based soft-attention mechanism, where the sender broadcasts a key encoding the properties of the agents, then the receiver attends to all received messages for a weighted sum of messages for decision marking. SARNet [35] and MAGIC [31] further remove the signature in TarMAC and leverage attention-based networks to learn efficient and interpretable relations between entities, decide when and with whom to communicate.
+
+To the best of our knowledge, none of the existing MARL communication methods explicitly consider how the multiple received messages can be optimized for efficient policy learning. Agents may be confused by redundant information from teammates, and simply augmenting the local policy with the raw message may burden the learning. Our proposed method applies a message aggregation module to learn a compact information representation and extracts the most relevant part for decision-making.
+
+# 6 Conclusion and Future Work
+
+In this paper, we investigate the information representation for multi-agent communication. Previous works either focus on generating meaningful message or designing a mechanism to select the most relevant message in a raw way, ignoring the aggregation of the message, resulting in low sample efficiency in complex scenarios. Our approach improves communication efficiency by learning a compact information representation to ground the true state and optimizing it in a self-supervised way. Also, we apply a focusing network to extract the most relevant part for decision-making. We conduct sufficient experiments in various benchmarks to verify the efficiency of the proposed methods, and more visualization results further reveal why our approach works. For future work, more results on image input and solving the scalability issue when facing environments with hundreds or thousands of agents by techniques like agent grouping would be of great interest.
+
+# Acknowledgements
+
+This work is supported by the National Key Research and Development Program of China (2020AAA0107200), the National Science Foundation of China (61921006, 61876119, 62276126), the Natural Science Foundation of Jiangsu (BK20221442), and the program B for Outstanding PhD candidate of Nanjing University. We thank the anonymous reviewers for their useful suggestions.
+
+# References
+
+[1] Lorenzo Canese, Gian Carlo Cardarilli, Luca Di Nunzio, Rocco Fazzolari, Daniele Giardino, Marco Re, and Sergio Spanò. Multi-agent reinforcement learning: A review of challenges and applications. Applied Sciences, 11(11):4948, 2021.
+[2] Sneha Chaudhari, Varun Mithal, Gungor Polatkan, and Rohan Ramanath. An attentive survey of attention models. arXiv preprint arXiv:1904.02874, 2019.
+
+[3] Filippos Christianos, Georgios Papoudakis, Muhammad A Rahman, and Stefano V Albrecht. Scaling multi-agent reinforcement learning with selective parameter sharing. In International Conference on Machine Learning, pages 1989-1998, 2021.
+[4] Abhishek Das, Théophile Gervet, Joshua Romoff, Dhruv Batra, Devi Parikh, Mike Rabbat, and Joelle Pineau. TarMAC: Targeted multi-agent communication. In International Conference on Machine Learning, pages 1538-1546, 2019.
+[5] Alana de Santana Correia and Esther Luna Colombini. Attention, please! a survey of neural attention models in deep learning. arXiv preprint arXiv:2103.16775, 2021.
+[6] Ziluo Ding, Tiejun Huang, and Zongqing Lu. Learning individually inferred communication for multi-agent cooperation. In Advances in Neural Information Processing Systems, pages 22069-22079, 2020.
+[7] Zehao Dou, Jakub Grudzien Kuba, and Yaodong Yang. Understanding value decomposition algorithms in deep cooperative multi-agent reinforcement learning. arXiv preprint arXiv:2202.04868, 2022.
+[8] Wei Du and Shifei Ding. A survey on multi-agent deep reinforcement learning: from the perspective of challenges and applications. Artificial Intelligence Review, 54(5):3215-3238, 2021.
+[9] Xin Du, Jiahai Wang, Siyuan Chen, and Zhiyue Liu. Multi-agent deep reinforcement learning with spatio-temporal feature fusion for traffic signal control. In Joint European Conference on Machine Learning and Knowledge Discovery in Databases, pages 470-485, 2021.
+[10] Yali Du, Bo Liu, Vincent Moens, Ziqi Liu, Zhicheng Ren, Jun Wang, Xu Chen, and Haifeng Zhang. Learning correlated communication topology in multi-agent reinforcement learning. In International Conference on Autonomous Agents and MultiAgent Systems, pages 456-464, 2021.
+[11] Tom Eccles, Yoram Bachrach, Guy Lever, Angeliki Lazaridou, and Thore Graepel. Biases for emergent communication in multi-agent reinforcement learning. In Advances In Neural Information Processing Systems, pages 13111-13121, 2019.
+[12] Linus Ericsson, Henry Gouk, Chen Change Loy, and Timothy M Hospedales. Self-supervised representation learning: Introduction, advances and challenges. arXiv preprint arXiv:2110.09327, 2021.
+[13] Jakob Foerster, Ioannis Alexandros Assael, Nando De Freitas, and Shimon Whiteson. Learning to communicate with deep multi-agent reinforcement learning. In Advances in Neural Information Processing Systems, pages 2137-2145, 2016.
+[14] Jakob N. Foerster, Gregory Farquhar, Triantafyllos Afouras, Nantas Nardelli, and Shimon Whiteson. Counterfactual multi-agent policy gradients. In AAAI Conference on Artificial Intelligence, pages 2974-2982, 2018.
+[15] C Lee Giles and Kam-Chuen Jim. Learning communication for multi-agent systems. In Workshop on Radical Agent Concepts, pages 377-390. Springer, 2002.
+[16] Matthew J. Hausknecht and Peter Stone. Deep recurrent q-learning for partially observable mdps. In AAAI Conference on Artificial Intelligence, pages 29-37, 2015.
+[17] Pablo Hernandez-Leal, Bilal Kartal, and Matthew E Taylor. A survey and critique of multiagent deep reinforcement learning. Autonomous Agents and Multi-Agent Systems, 33(6):750-797, 2019.
+[18] Shariq Iqbal and Fei Sha. Actor-attention-critic for multi-agent reinforcement learning. In International Conference on Machine Learning, pages 2961–2970, 2019.
+[19] Woojun Kim, Jongeui Park, and Youngchul Sung. Communication in multi-agent reinforcement learning: Intention sharing. In International Conference on Learning Representations, 2020.
+
+[20] Landon Kraemer and Bikramjit Banerjee. Multi-agent reinforcement learning as a rehearsal for decentralized planning. Neurocomputing, 190:82-94, 2016.
+[21] Jakub Grudzien Kuba, Ruiqing Chen, Munning Wen, Ying Wen, Fanglei Sun, Jun Wang, and Yaodong Yang. Trust region policy optimisation in multi-agent reinforcement learning. arXiv preprint arXiv:2109.11251, 2021.
+[22] Michael Laskin, Aravind Srinivas, and Pieter Abbeel. CURL: Contrastive unsupervised representations for reinforcement learning. In International Conference on Machine Learning, pages 5639-5650, 2020.
+[23] Angeliki Lazaridou and Marco Baroni. Emergent multi-agent communication in the deep learning era. arXiv preprint arXiv:2006.02419, 2020.
+[24] Tung-Che Liang, Jin Zhou, Yun-Sheng Chan, Tsung-Yi Ho, Krishnendu Chakrabarty, and Cy Lee. Parallel droplet control in media biochips using multi-agent reinforcement learning. In International Conference on Machine Learning, pages 6588-6599, 2021.
+[25] Toru Lin, Jacob Huh, Christopher Stauffer, Ser Nam Lim, and Phillip Isola. Learning to ground multi-agent communication with autoencoders. In Advances in Neural Information Processing Systems, pages 15230-15242, 2021.
+[26] Ryan Lowe, Yi Wu, Aviv Tamar, Jean Harb, Pieter Abbeel, and Igor Mordatch. Multi-agent actor-critic for mixed cooperative-competitive environments. In Advances in Neural Information Processing Systems, pages 6379–6390, 2017.
+[27] Xueguang Lyu, Yuchen Xiao, Brett Daley, and Christopher Amato. Contrasting centralized and decentralized critics in multi-agent reinforcement learning. arXiv preprint arXiv:2102.04402, 2021.
+[28] Hangyu Mao, Zhengchao Zhang, Zhen Xiao, Zhibo Gong, and Yan Ni. Learning agent communication under limited bandwidth by message pruning. In AAAI Conference on Artificial Intelligence, pages 5142-5149, 2020.
+[29] Weichao Mao, Kaiqing Zhang, Erik Miehling, and Tamer Başar. Information state embedding in partially observable cooperative multi-agent reinforcement learning. In IEEE Conference on Decision and Control, pages 6124-6131, 2020.
+[30] Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Andrei A. Rusu, Joel Veness, Marc G. Bellemare, Alex Graves, Martin A. Riedmiller, Andreas Fidjeland, Georg Ostrovski, Stig Petersen, Charles Beattie, Amir Sadik, Ioannis Antonoglou, Helen King, Dharshan Kumaran, Daan Wierstra, Shane Legg, and Demis Hassabis. Human-level control through deep reinforcement learning. Nature, 518(7540):529-533, 2015.
+[31] Yaru Niu, Rohan Paleja, and Matthew Gombolay. Multi-agent graph-attention communication and teaming. In International Conference on Autonomous Agents and MultiAgent Systems, pages 964–973, 2021.
+[32] Frans A Oliehoek and Christopher Amato. A Concise Introduction to Decentralized POMDPs. Springer, 2016.
+[33] Georgios Papoudakis, Filippos Christianos, Arrayah Rahman, and Stefano V Albrecht. Dealing with non-stationarity in multi-agent deep reinforcement learning. arXiv preprint arXiv:1906.04737, 2019.
+[34] Georgios Papoudakis, Filippos Christianos, Lukas Schäfer, and Stefano V Albrecht. Benchmarking multi-agent deep reinforcement learning algorithms in cooperative tasks. In Proceedings of the Neural Information Processing Systems Track on Datasets and Benchmarks, 2021.
+[35] Murtaza Rangwala and Ryan Williams. Learning multi-agent communication through structured attentive reasoning. In Advances in Neural Information Processing Systems, pages 10088-10098, 2020.
+
+[36] Tabish Rashid, Mikayel Samvelyan, Christian Schroeder, Gregory Farquhar, Jakob Foerster, and Shimon Whiteson. QMIX: Monotonic value function factorisation for deep multi-agent reinforcement learning. In International Conference on Machine Learning, pages 4295-4304, 2018.
+[37] Mikayel Samvelyan, Tabish Rashid, Christian Schröder de Witt, Gregory Farquhar, Nantas Nardelli, Tim GJ Rudner, Chia-Man Hung, Philip HS Torr, Jakob N Foerster, and Shimon Whiteson. The starcraft multi-agent challenge. In International Conference on Autonomous Agents and MultiAgent Systems, pages 2186-2188, 2019.
+[38] Max Schwarzer, Ankesh Anand, Rishab Goel, R Devon Hjelm, Aaron Courville, and Philip Bachman. Data-efficient reinforcement learning with self-predictive representations. In International Conference on Learning Representations, 2020.
+[39] Kyunghwan Son, Daewoo Kim, Wan Ju Kang, David Earl Hostallero, and Yung Yi. QTRAN: Learning to factorize with transformation for cooperative multi-agent reinforcement learning. In International Conference on Machine Learning, pages 5887-5896, 2019.
+[40] Sainbayar Sukhbaatar, Arthur Szlam, and Rob Fergus. Learning multiagent communication with backpropagation. In Advances in Neural Information Processing Systems, pages 2244-2252, 2016.
+[41] Yanchao Sun, Ruijie Zheng, Parisa Hassanzadeh, Yongyuan Liang, Soheil Feizi, Sumitra Ganesh, and Furong Huang. Certifiably robust policy learning against adversarial communication in multi-agent systems. arXiv preprint arXiv:2206.10158, 2022.
+[42] Peter Sunehag, Guy Lever, Audrunas Gruslys, Wojciech Marian Czarnecki, Vinicius Flores Zambaldi, Max Jaderberg, Marc Lanctot, Nicolas Sonnerat, Joel Z Leibo, Karl Tuyls, and Thore Graepel. Value-decomposition networks for cooperative multi-agent learning based on team reward. In International Conference on Autonomous Agents and MultiAgent Systems, pages 2085-2087, 2018.
+[43] Laurens Van der Maaten and Geoffrey Hinton. Visualizing data using t-SNE. Journal of Machine Learning Research, 9(11):2579-2605, 2008.
+[44] Ashish Vavwani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Advances in neural information processing systems, pages 5998-6008, 2017.
+[45] Jianhao Wang, Zhizhou Ren, Beining Han, Jianing Ye, and Chongjie Zhang. Towards understanding cooperative multi-agent q-learning with value factorization. In Advances in Neural Information Processing Systems, pages 29142-29155, 2021.
+[46] Jianhao Wang, Zhizhou Ren, Terry Liu, Yang Yu, and Chongjie Zhang. QPLEX: Duplex dueling multi-agent q-learning. In International Conference on Learning Representations, 2021.
+[47] Jianhong Wang, Yuan Zhang, Tae-Kyun Kim, and Yunjie Gu. Shapley Q-value: A local reward approach to solve global reward games. In AAAI Conference on Artificial Intelligence, pages 7285-7292, 2020.
+[48] Tonghan Wang, Jianhao Wang, Chongyi Zheng, and Chongjie Zhang. Learning nearly decomposable value functions via communication minimization. In International Conference on Learning Representations, 2020.
+[49] Yihan Wang, Beining Han, Tonghan Wang, Heng Dong, and Chongjie Zhang. DOP: Off-policy multi-agent decomposed policy gradients. In International Conference on Learning Representations, 2021.
+[50] Di Xue, Lei Yuan, Zongzhang Zhang, and Yang Yu. Efficient multi-agent communication via shapley message value. In International Joint Conference on Artificial Intelligence, pages 578-584, 2022.
+
+[51] Wanqi Xue, Wei Qiu, Bo An, Zinovi Rabinovich, Svetlana Obratztova, and Chai Kiat Yeo. Mis-spoke or mis-lead: Achieving robustness in multi-agent communicative reinforcement learning. In International Conference on Autonomous Agents and MultiAgent Systems, pages 1418–1426, 2022.
+[52] Jianing Ye, Chenghao Li, Jianhao Wang, and Chongjie Zhang. Towards global optimality in cooperative marl with sequential transformation. arXiv preprint arXiv:2207.11143, 2022.
+[53] Lei Yuan, Chenghe Wang, Jianhao Wang, Fuxiang Zhang, Feng Chen, Cong Guan, Zongzhang Zhang, Chongjie Zhang, and Yang Yu. Multi-agent concentrale coordination with decentralized task representation. In International Joint Conference on Artificial Intelligence, pages 599-605, 2022.
+[54] Lei Yuan, Jianhao Wang, Fuxiang Zhang, Chenghe Wang, Zongzhang Zhang, Yang Yu, and Chongjie Zhang. Multi-agent incentive communication via decentralized teammate modeling. In AAAI Conference on Artificial Intelligence, pages 9466-9474, 2022.
+[55] Mohamed Salah Zaiem and Etienne Bennequin. Learning to communicate in multi-agent reinforcement learning: A review. arXiv preprint arXiv:1911.05438, 2019.
+[56] Sai Qian Zhang, Qi Zhang, and Jieyu Lin. Efficient communication in multi-agent reinforcement learning via variance based control. In Advances in Neural Information Processing Systems, pages 3230-3239, 2019.
+[57] Sai Qian Zhang, Qi Zhang, and Jieyu Lin. Succinct and robust multi-agent communication with temporal message control. In Advances in Neural Information Processing Systems, pages 17271-17282, 2020.
+[58] Tianhao Zhang, Yueheng Li, Chen Wang, Guangming Xie, and Zongqing Lu. FOP: Factorizing optimal joint policy of maximum-entropy multi-agent reinforcement learning. In International Conference on Machine Learning, pages 12491–12500, 2021.
+[59] Ming Zhou, Jun Luo, Julian Villela, Yaodong Yang, David Rusu, Jiayu Miao, Weinan Zhang, Montgomery Alban, Iman Fadakar, Zheng Chen, Aurora Chongxi Huang, Ying Wen, Kimia Hassanzadeh, Daniel Graves, Dong Chen, Zhengbang Zhu, Nhat M. Nguyen, Mohamed Elsayed, Kun Shao, Sanjeevan Ahilan, Baokuan Zhang, Jiannan Wu, Zhengang Fu, Kasra Rezaee, Peyman Yadmellat, Mohsen Rohani, Nicolas Perez Nieves, Yihan Ni, Seyedershad Banijamali, Alexander Imani Cowen-Rivers, Zheng Tian, Daniel Palenicek, Haitham Bou-Ammar, Hongbo Zhang, Wulong Liu, Jianye Hao, and Jun Wang. Smarts: Scalable multi-agent reinforcement learning training school for autonomous driving. arXiv preprint arXiv:2010.09776, 2020.
+[60] Changxi Zhu, Mehdi Dastani, and Shihan Wang. A survey of multi-agent reinforcement learning with communication. arXiv preprint arXiv:2203.08975, 2022.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See Section 6.
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] See Section 6.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] Our paper conforms to them.
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] See our supplemental material.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Appendix A.3.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] See the results in Section 4.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Appendix A.3.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] See Section 4.
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] Our new assets are included in the supplemental material.
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/images.zip b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..e4982aba9ea8c138bd70a833dc6edb752ab40ac4
--- /dev/null
+++ b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:354d3638c383cf07962a5be6da4e10f779babc4594810b2d02240805cfc1ce3d
+size 382698
diff --git a/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/layout.json b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..9c393441ec91f0e86f24fbad59aa06e1d161c064
--- /dev/null
+++ b/efficientmultiagentcommunicationviaselfsupervisedinformationaggregation/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:22d831a3cedf4a2b4a5bc5b49ee4c3484fc1395414029039dc327bf16e717dde
+size 416421
diff --git a/efficientnonparametricoptimizersearchfordiversetasks/6f7cdbb8-3767-48e3-aa2a-2e4c81e3c1fe_content_list.json b/efficientnonparametricoptimizersearchfordiversetasks/6f7cdbb8-3767-48e3-aa2a-2e4c81e3c1fe_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..6ec1037f0948de14a1119c299f3903bf70f31dfe
--- /dev/null
+++ b/efficientnonparametricoptimizersearchfordiversetasks/6f7cdbb8-3767-48e3-aa2a-2e4c81e3c1fe_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:aa62cac77c94f5f10c35ea0349121e18de996c56be8bf62f98530071e0d2a7b5
+size 85588
diff --git a/efficientnonparametricoptimizersearchfordiversetasks/6f7cdbb8-3767-48e3-aa2a-2e4c81e3c1fe_model.json b/efficientnonparametricoptimizersearchfordiversetasks/6f7cdbb8-3767-48e3-aa2a-2e4c81e3c1fe_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..6c4a93c8770f5b892e74c27b42ed971b9a6b2ebf
--- /dev/null
+++ b/efficientnonparametricoptimizersearchfordiversetasks/6f7cdbb8-3767-48e3-aa2a-2e4c81e3c1fe_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:497133af10debe6aa63bfe24137399367c336ae9b4e97d7b5dac20ed3cd56798
+size 114171
diff --git a/efficientnonparametricoptimizersearchfordiversetasks/6f7cdbb8-3767-48e3-aa2a-2e4c81e3c1fe_origin.pdf b/efficientnonparametricoptimizersearchfordiversetasks/6f7cdbb8-3767-48e3-aa2a-2e4c81e3c1fe_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..29ed3e1aaf953575637c0204093fa5dd2907630a
--- /dev/null
+++ b/efficientnonparametricoptimizersearchfordiversetasks/6f7cdbb8-3767-48e3-aa2a-2e4c81e3c1fe_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5c7f937d91ebbab7a51fa11a2398b21212577860c75d2a9ff69066320436f741
+size 913734
diff --git a/efficientnonparametricoptimizersearchfordiversetasks/full.md b/efficientnonparametricoptimizersearchfordiversetasks/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..0c1563a68f542a5363e072cbf68bd56b572f15e9
--- /dev/null
+++ b/efficientnonparametricoptimizersearchfordiversetasks/full.md
@@ -0,0 +1,338 @@
+# Efficient Non-Parametric Optimizer Search for Diverse Tasks
+
+Ruochen Wang $^{1}$ , Yuanhao Xiong $^{1}$ , Minhao Cheng $^{2}$ , Cho-Jui Hsieh $^{1}$
+
+$^{1}$ Department of Computer Science, UCLA, $^{2}$ HKUST
+
+ruocwang@ucla.edu minhaocheng@ust.hk {chohsieh, yhxiong}@cs.ucla.edu
+
+# Abstract
+
+Efficient and automated design of optimizers plays a crucial role in full-stack AutoML systems. However, prior methods in optimizer search are often limited by their scalability, generalization, or sample efficiency. With the goal of democratizing research and application of optimizer search, we present the first efficient, scalable and generalizable framework that can directly search on the tasks of interest. We first observe that optimizer updates are fundamentally mathematical expressions applied to the gradient. Inspired by the innate tree structure of the underlying math expressions, we re-arrange the space of optimizers into a super-tree, where each path encodes an optimizer. This way, optimizer search can be naturally formulated as a path-finding problem, allowing a variety of well-established tree traversal methods to be used as the search algorithm. We adopt an adaptation of the Monte Carlo method to tree search, equipped with rejection sampling and equivalent-form detection that leverage the characteristics of optimizer update rules to further boost the sample efficiency. We provide a diverse set of tasks to benchmark our algorithm and demonstrate that, with only 128 evaluations, the proposed framework can discover optimizers that surpass both human-designed counterparts and prior optimizer search methods. Our code is publicly available at https://github.com/ruocwang/enos.
+
+# 1 Introductions
+
+Motivated by a vision of democratizing machine learning, the central objective for automated machine learning (AutoML), such as automated architecture [22, 26, 29, 40, 55, 60, 62, 65] / optimizer [10, 12, 15, 17, 59, 68] / loss [36] / augmentation search [37, 39], lies in reducing the need for expert design on a diverse set of tasks. To achieve this goal, it is critical for AutoML systems to exhibit a high level of efficiency, so that they can be directly applied to a variety of tasks without consuming a humongous amount of computing resources. A widely successful example of such an effort is DARTS [40] in Neural Architecture Search (NAS), which reduces the search cost from thousands of GPU days of early RL-based algorithms to a single digit, enabling direct application of NAS systems to a wide range of tasks [32, 33, 38, 44, 50].
+
+Inspired by the success of efficient NAS methods, we turn our attention to another important but much less studied area of AutoML - Automated optimizer search, where an efficient, scalable and generalizable framework is still absent. Optimizer search aims to automatically design a suitable update function that takes gradients as inputs and produces update directions for the optimizer's parameters. Pioneering work in this area, coined Learning to Optimize (L2O), adopts a data-driven approach by replacing human-designed update rules with a learnable parametric function [10, 12, 17, 59]. However, parametric optimizers are fundamentally not scalable to large models or datasets, as inferring its parameters typically requires expensive meta-learning steps such as backpropagating through gradient descent [10, 15, 68]. Moreover, the learned optimizer often generalizes poorly to even minor variants of its training task (Figure 3) [10, 68]. Poor scalability and
+
+generalization prevents L2O from being served as a general-purpose optimizer search framework that can be directly applied to tasks of interest.
+
+The aforementioned limitations of parametric optimizers bring our attention to another line of method that searches over the discrete space of non-parametric update functions [1] which generally exhibit the same level of scalability and generality as human-designed optimizers [15, 51]. NOS-RL [15] extends early RL-based NAS framework [22] to optimizer search, proposing to learn a sequential controller to produce optimizer update rules according to a predefined pattern. However, NOS-RL is sample inefficient, requiring over 10k evaluations to find good candidates. More recently, AutoML-Zero [51, 69] proposes to search over the vast space of computer codes for the entire ML pipeline (including the optimizer). The excessive generality of its search space makes it even more costly to run than RL-based method. The search cost of existing non-parametric optimizer search frameworks makes them computationally prohibitive not only for practitioners to apply but also for researchers to analyze.
+
+With the goal of democratizing research and practical applications of automated optimizer design, we introduce the first efficient, scalable, and generalizable optimizer search framework that can be directly applied to a wide range of tasks. We observe that non-parametric update rules are essentially mathematical expressions, with an innate tree structure where nodes are elementary math operators and edges represent their I/Os. Consequently, generating an update rule can be viewed as progressively appending nodes to the expression tree until it is complete. Inspired by this observation, we re-imagine the optimizer search space as a super-tree of mathematical expressions. Each leaf node on the super-tree contains an optimizer, and the path towards it represents the generation process of that optimizer's underlying expression. With the tree-structured search space, optimizer search can be naturally formulated as a path-finding problem, allowing a wide range of well-established tree-traversal methods to be used as the search algorithm. We show that a simple adaptation of Monte Carlo Sampling [30, 53], equipped with our proposed rejection sampling and equivalent-form detection, can already produce remarkable results on our search space within a fraction of budgets compared with NOS-RL ( $\sim 1\%$ ).
+
+We extensively evaluate the proposed framework on a diverse set of learning tasks: digit classification with MNISTNET [10], image classification with ConvNet [15], graph learning with (Cluster-)GAT [21, 28], norm-bounded adversarial attack on robustly trained models [20, 45, 46], and BERT fine-tuning on NLP datasets [34, 56]. These tasks cover both constraint and unconstrained optimizations and span over a large variety of models and datasets. Despite the simplicity, the proposed framework is able to discover update rules that surpass human-designed optimizers and prior optimizer search methods, with a budget of only 128 evaluations. We hope the proposed framework could lower the barrier of entry to practical non-parametric optimizer search, thereby providing an entry point for researchers and practitioners from ML community and beyond to study and utilize automated optimizer search systems.
+
+# 2 Efficient, scalable and generalizable framework for optimizer search
+
+# 2.1 Optimizer design space
+
+Notations and problem formulation Deep learning tasks are frequently expressed as optimizing a loss function $L(\cdot)$ defined over parameter domain $\theta \in \Theta$ . The minimizer of $L$ can thus be obtained by $\theta^{*} = \arg \min_{\theta \in \Theta} L(\theta)$ . For differentiable functions, a standard optimizer typically takes the form of iterative gradient descent: $\theta_{t+1} = \theta_t - \gamma * \phi(\nabla_\theta L(\theta_t))$ , where $t$ is the current iteration, $\gamma$ is the learning rate and $\phi$ denote the update function. Existing optimizers primarily differ in their design of update function $\phi$ ; For example, vanilla gradient descent uses identity mapping $\phi(x) = x$ as the update function, whereas Adam adopts a momentum-based dynamic learning rate schema: $\phi(\nabla_\theta L(\theta_t)) = m(\nabla_\theta L(\theta_t)) / \sqrt{m((\nabla_\theta L(\theta_t))^2)}$ , where $m(\cdot)$ denotes the momentum function with an internal state.
+
+The goal of optimizer search is to automatically find a suitable update function $\phi$ over some hypothesis space $\Phi$ . The hypothesis spaces used in prior work can be divided into two categories: non-parametric and parametric spaces. Most human-designed optimizers belong to the first category, where the update
+
+function $\phi$ is not trainable. Learnable optimizers, such as L2LGD2 [10] and SymbolicL2O [68], fall into the second category. Our work mainly focuses on non-parametric optimizer search, with the goal of providing an efficient, scalable and generalizable optimizer search framework that can be directly apply to various tasks.
+
+Optimizer update rules as expression trees The first step toward such a framework is to understand the structure of non-parametric optimizers. We realize that, fundamentally, optimizers are mathematical expressions consisting of elementary operators $(+, -, sign(), inputs, e.t.c.)$ . Math expressions have an inherent tree structure that preserves its order of execution, where nodes are operators and edges represent their I/Os. For instance, Diagram [1] shows the expression tree of Adam [9]:
+
+
+Diagram 1: Adam optimizer
+
+
+Diagram 2: Our discovered Optimizer for adversarial attack
+
+where $m_{1}$ and $m_{2}$ denote the first and second order momentum (which can also be broken down into their own expression trees).
+
+Therefore, the generation of an update rule, as a mathematical expression, can also be conducted via top-down node selection: Take Adam as an example, we first select division (/) as the root node. For its left child, we pick $m_1$ , which is a leaf node and thus ends the branch. For the right child, we select $\sqrt{}$ , and subsequently pick $m_2$ to follow it. At this point, there is no empty branches left, and we obtain the complete update rule for Adam.
+
+A tree-structured search space Inspired by the completion process of update rules, we rearrange all expressions into a super-tree, where each leaf node contains an update rule and each path represents its completion process. The super-tree can be generated in a top-down manner: Starting from the root node with an empty update rule, we generate each of its child nodes by inserting a different operator into the update rule, and repeat this process for the generated nodes. Consequently, an optimizer can be sampled by traversing the super-tree until a leaf node is reached. Since the super-tree can grow in
+
+finitely deep, it is often desirable to restrict the tree to a predefined depth $N$ , where only the paths that can be completed within depth $N$ are included. Figure [1] provides an instantiation of our super-tree, where the paths leading to Adam and SGD optimizers are displayed as an example.
+
+The benefit of arranging the optimizer space into a tree is two folds. Firstly, the tree-based search space is tight:
+
+Proposition 1 Define the length of an update rule as the number of operators it includes, then the above tree-based search space is tight: a super-tree with a maximum depth of $N$ covers all update rules of length no greater than $N$ .
+
+In a tight search space, all optimizers can be represented at the right level of complexity, allowing them to be visited by the search algorithm without exploring unnecessarily deep into the super-tree. Although tightness is a fairly obvious result for our space, it is not the case for the previous search space defined in NOS-RL, as we will explain later. Secondly, with our super-tree, optimizer search can be naturally formulated as a path-finding problem, allowing a variety of well-established tree traversal methods to be deployed as search algorithms.
+
+
+Figure 1: An illustration of traversing the supertree to discover Adam and SGD.
+
+Contents To concretize the content of the search space, we allow three types of operators in the optimizer update rule:
+
+- a set of $p_1$ unary operators (e.g. $\log(|\cdot|)$ , $\exp(\cdot)$ , $\sqrt{|\cdot|}$ , $\text{sign}(\cdot)$ , $\text{drop}(\cdot)$ )
+- a set of $p_2$ binary operators (e.g. $+, -, \times, /, \text{pow}(\cdot, \cdot)$ )
+- a set of $L$ leaf values (input operators) containing gradient-based terms (e.g. $g, m_1$ ), decays (e.g. cosine Decay), and constants (e.g. 1, 2)
+
+This categorization of mathematical operators is not new, as it is also adopted in symbolic math solver [35] and NOS-RL [15].
+
+Comparison with NOS-RL's search space Although both NOS-RL [15] and our framework use elementary math operators as building blocks for optimizers, they have little in common in terms of the arrangement of the search spaces. Optimizers in NOS-RL's search space are formed by a chain of predefined motifs: $b(u(I), u(I))$ , where $b, u, I$ denote binary, unary and input operators. Due to the fixed structure of such motifs, NOS-RL's search space is not tight: there exist many optimizers that take extra longer sequences to express, potentially lowering their chance of being discovered by the search algorithm. For instance, Diagram 2 shows an optimizer of length 5, but it takes (10 - 1) nodes (two chained motifs) to represent it under NOS-RL's arrangement; Moreover, NOS-RL's search space also requires extra bypass operators (e.g. $u(x) = x$ and $b(x, y) = x$ ) to cover even human-design optimizers such as Adam and PGD, further increasing the complexity. In contrast, our representation of optimizers is directly inspired by the innate structure of its underlying mathematical expressions, resulting in a tight tree-based search space. In our search space, optimizer search can be naturally formulated as a form of top-down path-finding problem. In the next sections, we will detail our choice of algorithms for traversing the super-tree, as well as several techniques that leverage the characteristics of optimizer update rules to boost the sample efficiency.
+
+# 2.2 Monte Carlo Sampling for tree traversal
+
+We adopt a simple adaptation of Monte Carlo Sampling to tree traversal [30, 53, 70] (MCT) as the search algorithm. The idea is to assign scores to the nodes in the super-tree (Figure II), and use these scores to guide the tree traversal. We define the score of a node $v$ as a Monte Carlo estimation over unrolling steps from $v$ : If $v$ is an internal node, we randomly generate a set of unrolled paths from $v$ to the corresponding leaf nodes, and take the average score of the resulting optimizers as the score for $v$ ; If $v$ is a leaf node, we set its score to 0 as it cannot be expanded. The search can thus be conducted as follows: 1). Starting from the root node $v^{(0)}$ at level 0, we generate all child nodes $\{v^{(1)}\}$ of $v^{(0)}$ by inserting each operator from the candidate pool to the update rule in $v^{(0)}$ ; 2). From there, we select the child node $v^{*(1)}$ with the highest MC score to expand, and move on to the next level; 3). The process is repeated until a predefined maximum search level is reached. Algorithm II in the Appendix provides a detailed summary of the complete search process.
+
+Directly applying the MCT algorithm to optimizer search would not perform well under limited search budgets, due to two unique characteristics of optimizer update rules that challenge the sample efficiency of the Monte Carlo estimates. Firstly, the majority of mathematical expressions, when deployed as optimizer update rules, perform poorly or even would not converge. This is usually not the case for other AutoML tasks such as neural architecture search, as most networks in the search space perform reasonably well. The large body of poor-performing optimizers not only consumes precious search budget, but also causes the MC estimation to be unstable. Secondly, there exists many mathematical redundancies in the expression space, for example: $\text{sign}(\text{sign}(\text{sign}(x)))$ can be reduced to $\text{sign}(x)$ , and $\frac{m_1 + \sqrt{m_2}}{\sqrt{m_2}}$ is equivalent to $\frac{m_1}{\sqrt{m_2}} + 1$ . Identifying and eliminating these redundancies would not only save budget, but also prevent the sampling distribution from biasing toward mathematically simple and shallow update rules. To address these issues and further boost the sample efficiency, we propose two sets of techniques - rejection sampling and equivalent-form detection. When combined with these techniques, the simple MCT algorithm becomes particularly effective for the optimizer search task. We will discuss them in detail in the following sections.
+
+# 2.3 Rejection sampling
+
+Eliminating poor optimizers with a train-free task-agnostic test Inspired by the characteristics of optimizer update rules, we develop a train-free task-agnostic test to eliminate poor optimizers without evaluating them. We propose a necessary condition for a valid optimizer: it must produce an acute angle with steepest descent direction (i.e. gradients). We check the validity of optimizers against this condition and only evaluate those that pass the test. For the test to be task-agnostic, we feed the optimizer with a batch of random Gaussian vectors in place of actual gradients. Formally, the descent test can be written as:
+
+$$
+E _ {u \sim \mathcal {N} (0, 1)} \left[ \cos \left(\phi \left(\nabla_ {\theta} \mathcal {L}\right), \nabla_ {\theta} \mathcal {L}\right) \right] > \lambda_ {d}
+$$
+
+
+Figure 2: Performance distribution of optimizers after applying descent test, under $\lambda_{d} = 0.15$ and a batch size of 25.
+
+where $\lambda_{d}$ is a predefined threshold. Although our descent test is by-no-mean comprehensive, it can effectively rule out a large chunk of poor optimizers with negligible false-negative rates, as demonstrated in Figure 2
+
+Reducing the variance of MC estimates via score thresholding After applying the descent test, there still remains a non-negligible portion of poor optimizers. When sampled during the unrolling step, these optimizers would drastically lower the Monte Carlo score of the stem node, causing the MC estimation to exhibit high variance and thus become unreliable. This adverse effect is especially severe under the efficient setting when the sample size is small. Therefore, we propose to simply reject candidates with scores lower than a predefined threshold, thereby removing them from the MC scores of the corresponding stem nodes.
+
+# 2.4 Detecting and handling redundancies in mathematically equivalent forms
+
+On-the-fly constraint tree-traversal for redundant path pruning One benefit of formulating the search problem as top-down path-finding is that we can easily apply constraints on-the-fly to eliminate undesirable branches - those that lead to mathematically redundant expressions in our case. We identify three main categories of such constraints:
+
+- child operator that nullifies its parent's operator. e.g. $-(-x) = x$ , $ln(e^{x}) = x$
+- child operator that is redundant under its parent. e.g. $\text{clip}(\text{clip}(x)) = \text{clip}(x)$
+- sequence of operators that reduces to a constant in the search space. e.g. $\sqrt{|sign(x)|} = 1$
+
+The complete sets of constraints we used can be found in the Appendix. Enforcing these constraints during the traversal can effectively trim down the search tree, allowing the algorithm to explore branches that lead to more diverse and complex expressions.
+
+Hashing mathematically equivalent expressions Besides enforcing constraints during the traversal, it is also important to detect mathematically equivalent optimizers to avoid duplicated evaluations. One can always apply off-the-shelf symbolic solvers to identify the equivalence of two expressions, $\phi$ and $\phi^{\prime}$ , by checking if $(\phi -\phi^{\prime})$ can be reduced to 0. However, it could become extremely slow as the pool of evaluated optimizers $\{\phi_i\}_{1}^{N}$ gets larger and larger, since we need to solve $N$ pair of equations every time a new update rule is sampled. Instead, we apply hashing to efficiently query the evaluated candidate pool for mathematically equivalent optimizers. Concretely, we assign each optimizer a hash code, obtained by feeding a fixed probing vector as input to the optimizer and recording its output. The probing vector is pre-sampled from Gaussian distribution. When a newly sampled optimizer arrives, we only need to compare its code with the hash table to check the existence of its equivalent form. Empirically, it is much faster to run the proposed hashing-based checker than symbolic solvers.
+
+# 3 Discussions and relationship to prior work
+
+Automated optimizer design Optimization plays a crucial role in training deep learning models. Generally, there does not exist one optimizer that acces all scenarios, as different tasks (dataset,
+
+architecture, loss, parameterization, e.t.c.) might favor different optimization methods [2, 10]. The demand for task-specific optimizers stimulates research interest in developing automated systems for optimizer design [10, 12, 15, 17, 41, 51, 59, 66, 68]. Early work adopts a data-driven method by modeling the optimizer update with a parametric function [10, 12, 59]. L2LGD2 [10] deploys an LSTM model as the update function that takes historical gradients as input and produces the update direction. However, parametric optimizer search methods are fundamentally limited by its scalability, as inferring its parameters requires expensive meta-learning steps such as back-propagation through optimization [10, 59, 68]. Although SymbolicL2O [68] improves the scalability of the learned LSTM optimizer by distilling it into a lightly-parameterized symbolic optimizer, it still requires a pretrained LSTM model to begin with. Instead of learning a parametric optimizer, NOS-RL [15] directly searches over a discrete space of non-parametric update functions comprised of mathematical operators. It extends early RL-based NAS method [22] to optimizer search, by training a sequential controller to produce the optimizer update rule according to a predefined pattern. However, similar to its NAS counterpart, NOS-RL is also computationally expensive, requiring over $10\mathrm{k}$ evaluations to find good candidates.
+
+Symbolic optimization and differential program synthesis Symbolic optimization (SO) [1, 13, 53, 61, 63, 64] aims at optimizing an objective over a symbolic hypothesis space of functions (or more broadly, programs). One line of work attempts to recover the unknown equation from its generated data, with great potential in automating scientific discoveries [54, 64]. Another line of methods aims at finding a more interpretable and generalizable symbolic model to replace the black-box neural networks [53, 61, 63]; Applications that witnessed some success include learning symbolic policy networks for RL [63] and sequential classification models [53, 61]. The latter is often studied under the concept of Program Synthesis [24], where a model is extended to include programmatic rules such as if-else clause, indexing, e.t.c. SO is closely connected to AutoML at a high level, as both fields frame their problems as discrete optimization. Indeed, many existing optimizer search methods can find their counterparts in symbolic optimization. Our method is also inspired by the rich body of literature in deep symbolic mathematics and program synthesis, which also explores tree-based expression spaces for differential equations and programs [30, 35, 53, 61, 64]. However, due to significant differences in taskonomy, SO and AutoML methods are often developed separately, converging into different branches of techniques. Symbolic optimization often studies tasks where candidates are cheap to evaluate but finding the global optimal is desired [1, 54, 64]; As a result, sample efficiency is often not the primary concern. Much to the opposite, in AutoML tasks, candidate evaluations are extremely expensive; Therefore, it is more beneficial to identify a good-enough candidate within a limited amount of budget.
+
+# 4 Empirical evaluations on a diverse set of tasks
+
+We extensively evaluate the proposed framework on a suite of tasks, covering a variety of models and datasets. On standard benchmark tasks for optimizer search, our method is able to discover optimizers that outperform its human-designed and automatically searched counterparts. In addition, we also show that the proposed framework enables automated optimizer design for many other popular learning tasks, such as adversarial attack, GNN training, and BERT finetuning. Due to the space limits, we will include detailed descriptions, search settings, and discovered optimizers for each task in the Appendix.
+
+# 4.1 General setting
+
+MCT algorithm Across all experiments, we limit the maximum level of MCT traversal to 4, and set the number of Monte Carlo samples to 32 (a multiple of 8 for parallelism on 8-GPU servers) for each level. This amounts to a fixed total budget of 128 evaluations. The maximum depth for the super-tree is set to 10, which already covers many top-performing optimizers for various tasks. We use a similar set of elementary operations as NOS-RL to build the optimizers, with only minor adjustments for some tasks (see Appendix for more details).
+
+Optimizer evaluation We follow the default settings and hyperparameters for each task, and only swap out the optimizer; This potentially puts our algorithm at a disadvantage, as the hyperparameters are usually tuned around the default optimizers. Before optimizer evaluation, we perform grid search
+
+on a small proxy task (fewer steps) to find a proper learning rate. During the grid search, we also aggressively terminate optimizers if their performance falls under a certain threshold. Since early stopped optimizers consume fewer resources than a full evaluation, we do not count them into the budget (number of evaluations).
+
+# 4.2 Hand-written digit classification
+
+
+Figure 3: Training loss trajectory on hand-written digit classification task (log scaled). Each optimizer is evaluated for 4 random seeds. Our method is marked in red.
+
+
+
+
+
+
+
+We first compare our method with the LSTM-based optimizer (L2LGD2) on hand-written digit classification. Following L2LGD2 [10], the goal is to minimize the cumulative training loss of a single-hidden-layer MLP with Sigmoid activation (MNISTNET) on the MNIST dataset; The search is conducted on MNISTNET for 100 steps with a batch size of 128, and the discovered optimizers are subsequently transferred to three variants of MNISTNET with different activations (MNISTNET-ReLU), number of hidden layers (MNISTNET-2Layer), and dimensions (MNISTNET-Big). Under this setting, our method finishes in 0.92h on RTX 2080ti, much faster than L2LGD2 (2.62h).
+
+As shown in Figure 3, our discovered optimizer achieves the lowest training loss under both direct search and transfer settings. Notable, the LSTM-based parametric update function indeed converges faster when the number of steps is close to the search phase (black-dotted vertical line on Figure 3). However, it extrapolates poorly to longer trajectories. As the training proceeds, all other non-parametric optimizers eventually catch-up, achieving much lower training loss. Moreover, LSTM-based optimizer also generalizes poorly to other model variants (most noticeably MNISTNET-ReLU), revealing its tendency to overfit the search task.
+
+# 4.3 Image classification with ConvNet
+
+We proceed to evaluate our method on the CIFAR-10 [8] classification task proposed in NOS-RL [15]. The model of choice is a 2-layer ConvNet. Each layer of this network contains a 32-filter 3x3 convolution with ReLU activation and batch normalization. Following NOS-RL's setting, for every optimizer, the best learning rate is searched over a grid of $\{1e^{-5}, 1e^{-4}, 1e^{-3}, 1e^{-2}, 1e^{-1}, 1\}$ with 1 epoch of training, and the discovered learning rate is subsequently used to train the model for a longer period of time (5 epochs). Since NOS-RL's implementation is not open-sourced, we reproduce and compare with the two families of discovered optimizers described in NOS-RL paper: AddSign and PowSign.
+
+The results are summarized in Table [1]. For NOS-RL, we display the performance of the top 4 variants of PowSign and AddSign, which are obtained after training the controller for over 10k evaluations (Figure 4 in the NOS-RL paper [15]). With only a fraction ( $\sim 1\%$ ) of the search budget, our framework is able to discover optimizers that reach a test accuracy of $77.02\%$ , topping both PowSign and AddSign optimizers and also human-designed ones by a sizable margin. The sheer reduction in search cost and the improvement in search performance evince the efficiency and effectiveness of the proposed framework for discovering better optimizers.
+
+# 4.4 Adversarial attack
+
+Next, we apply our framework to discover optimizers for constraint optimization. We select adversarial attack, which aims at finding norm-bounded perturbations in the input space that alter the model's predictions. The de facto optimizer used in adversarial attack is Projected Gradient Descent
+
+Table 1: Performance of automated search algorithms on CIFAR-10.
+
+| Optimizer | Test Accuracy (%) | Search Method | Search Budget (#evaluations) |
| SGD | 70.99% ± 2.12 | manual | - |
| SGD + Momentum | 74.12% ± 0.44 | manual | - |
| Nesterov | 74.15% ± 0.52 | manual | - |
| Adam | 73.42% ± 0.56 | manual | - |
| RMSprop | 71.42% ± 1.42 | manual | - |
| PowSign-ld | 75.48% ± 0.45 | RL on hand-crafted patterns | >10,000 |
| PowSign-cd | 76.21% ± 0.16 | RL on hand-crafted patterns | >10,000 |
| AddSign-ld | 75.54% ± 0.39 | RL on hand-crafted pattern space | >10,000 |
| AddSign-cd | 76.07% ± 0.59 | RL on hand-crafted pattern space | >10,000 |
| Ours | 77.02% ± 0.19 | MCT on super-tree space | 128 |
+
+(PGD) [20]. We consider the most popular $l_{\infty}$ -norm setting. For $l_{\infty}$ -norm bounded attack, PGD takes the form of: $x = \text{Proj}_{B_{\epsilon}^{\infty}(x_o)}(x + \gamma \text{sign}(\nabla_x L(x)))$ , where $B_{\epsilon}^{\infty}(x_o)$ represents a $\epsilon$ ball around the original image $x_o$ w.r.t. $l_{\infty}$ -norm. The models of choice come from the AutoAttack library [46], which holds a leaderboard of top defense methods. Following their settings, we set $\epsilon = 8/255$ , and run each optimizer once for 100 steps on every image from the test split [46].
+
+On this task, we mainly search for the update rule inside the projection operator (e.g. sign() for PGD). The search is conducted on the pretrained Carmon2019 model [27], and the proposed optimizer is subsequently evaluated on other top defense methods for WideResNet [14] (WRN---) and ResNet [11] (RN). As shown in Table 2, our discovered optimizer consistently outperforms PGD by a sizable margin. Surprisingly, we found that the algorithm tends to pick log(|·|) rather than sign(·) as the first operator, resulting in many log-based optimizers that surpass sign-based PC
+
+Table 2: Attack success rate of different optimizers on top defense methods on CIFAR-10.
+
+| Defense Models | PGD | APGD | Ours |
| Carmon2019 (WRN-28-10) 27 | 37.83% | 38.22% | 38.35% |
| Gowal2020‡ (WRN-70-16) 48 | 31.10% | 32.00% | 32.00% |
| Gowal2020‡ (WRN-34-20) 48 | 40.05% | 40.46% | 40.50% |
| Gowal2020‡ (WRN-28-10) 48 | 33.65% | 34.33% | 34.34% |
| Sehwag2020‡ (WRN-28-10) 52 | 40.00% | 40.43% | 40.46% |
| Wu2020‡ (WRN-28-10) 58 | 36.41% | 36.70% | 36.78% |
| Wang2020‡ (WRN-28-10) 42 | 37.78% | 38.16% | 38.27% |
| Engstrom2019 (RN-50) 31 | 47.76% | 48.25% | 48.32% |
| Wong2020Fast (RN-18) 57 | 53.69% | 54.11% | 54.19% |
+
+$\ddagger$ Methods that explore extra data during robust training.
+
+In addition to PGD, we also compare our log-based optimizer with the best handcrafted and tuned optimizer for adversarial attack: Adaptive PGD (APGD) [46]; The design of APGD is packed with domain expertise: it combines a well-tuned momentum update rule with a conditional learning rate decay based on a handcrafted schedule and sophisticated decay conditions (see Appendix for details). However, the performance of our automatically discovered optimizer rivals APGD across various defense methods, despite of having a much simpler form (see Appendix for details). This result demonstrates the potential of applying our framework to reduce the need of human expertise in designing optimizers for diverse tasks.
+
+# 4.5 Node classification on graphs
+
+We next test our framework for optimizing graph neural networks to classify nodes on graphs. The model of interest is Graph Attention Network (GAT) [21], one of the most widely used architectures in graph learning tasks. We compare our method against Adam [9] - the standard optimizer for optimizing GATs - on five commonly used graph datasets: OGBN-Product [49], Cora [4], CiteSeer [3], PubMed [6], and PPI [18]. Among them, OGBN-Product is the largest in scale, consisting of 2,449,029 nodes. Since standard GATs cannot scale to this dataset, we instead adopt an adaptation of cluster-GCN [28] to GAT as the testbed, termed Cluster-GAT. Cluster-GAT trains standard GAT on smaller partitions of the original graph, thereby allow
+
+Table 3: Performance of our discovered optimizers against Adam on GATs on five commonly used Graph datasets of diverse size. Results that use the same GAT implementations are grouped together.
+
+| Dataset | Adam | Ours |
| Products | 77.49% ± 0.56† | 80.15% ± 0.16 |
| Cora | 84.72% ± 0.32 | 85.20% ± 0.19 |
| Citeseer | 71.70% ± 1.03 | 73.10% ± 0.43 |
| PubMed | 78.20% ± 0.22 | 79.25% ± 0.70 |
| PPI | 97.53% ± 0.45‡ | 98.13% ± 0.10‡ |
+
+† Our reproduced accuracy using ognb-leaderboard's implementation is lower than the displayed number (79.23% ± 0.78).
+F1 Score
+
+ing the model to be applied to large-scale graphs. We refer the reader to the Appendix for detailed descriptions of all GAT implementations and experimental setups.
+
+The results are summarized in Table 3. On all datasets, our search algorithm is able to discover optimizers that outperform Adam. An interesting observation is that the top-performing optimizers discovered for this task almost always contain $\text{sign}(\cdot)$ operators, revealing the potential of adopting sign-based optimizers to improve the training of graph neural networks.
+
+# 4.6 BERT fine-tuning on NLP datasets
+
+We also evaluate the proposed framework on BERT finetuning task on GLUE benchmark [25]. For this task, we follow all configurations of the Hugging-Face [56] implementations: we finetune a pretrained BERT (base based) model for 3 epochs on Cola [43], STS-B [16] and RTE [7] dataset, and 5 epochs on MRPC [5] and WNLI [25] dataset. The batch size is set to 32. We compare our discovered optimizers with the default AdamW [19]. As shown in Table 4, our automatically discovered optimizers outperform AdamW on all datasets.
+
+Table 4: Performance of our discovered optimizers for BERT finetuning on GLUE tasks.
+
+| Dataset | AdamW | Ours |
| Cola | 59.56 ± 2.04* | 60.89 ± 1.33* |
| MRPC | 82.84 ± 0.57‡ | 86.64 ± 0.94‡ |
| STS-B | 87.80 ± 1.14† | 88.91 ± 0.30† |
| RTE | 65.97 ± 1.56‡ | 68.50 ± 1.93‡ |
| WNLI | 53.17 ± 5.49‡ | 56.34 ± 0.00‡ |
+
+\* Mathews Correlation.
+† Spearman Correlation.
+Accuracy $(\%)$
+
+# 5 Ablation study
+
+In this section, we ablate the proposed framework using the MNISTNET task. All experiments are repeated over 4 random seeds to account for randomness in the search phase.
+
+Random search baseline We study the effectiveness of our MCT algorithm alone by comparing it with random sampling. Concretely, instead of traversing the tree based on MC scores, we randomly generate all optimizers from the root. Everything else in our framework remains unchanged, including our rejection sampling and equivalent
+
+form detection techniques. This is equivalent to Random Search on our search space. As shown in Table 5, MCT algorithm outperforms Random Search baseline by a sizable margin, showing that the Monte Carlo node scoring schema can indeed guide the traversal towards promising branches of the tree.
+
+Table 5: Performance comparison of Random Search and MCT.
+
+| Method | Training Loss (sum) | Test Accuracy |
| Random | 60.25 ± 2.99 | 88.02% ± 1.53 |
| MCT | 59.25 ± 2.50 | 89.43% ± 0.85 |
+
+Score thresholding As discussed in prior sections, score thresholding is important to the performance of the MCT algorithm. To verify this, we ablate this technique by disabling it in our framework while keeping everything else the same. Without score thresholding, the cumulative training loss of the proposed optimizers raises from $59.25 \pm 2.50$ to $60.25 \pm 2.87$ , similar to that of random search.
+
+# 6 Conclusion
+
+Despite the recent advancement of practical AutoML systems in automatizing the design of architectures, data augmentation policies, and hyperparameters, progress in automated discovery of optimizers is still inadequate due to the limitations of prior methods in terms of 1). efficiency, 2). generalization, and 3). scalability. In this paper, we introduce the first optimizer search framework that meets all these criteria, allowing it to be directly applied to the tasks of interest. The proposed framework demonstrates promising results across a variety of tasks, from image classification, adversarial attack, to graph learning and BERT finetuning. Our method by-no-mean solves the optimizer search problem, as there is plenty of room for improvement on the algorithm and search space; Rather, our goal is to open up a new possibility for future development in non-parametric optimizer search methods. We hope the proposed framework could democratize research and applications of automated optimizer search, and stimulate interest among researchers and practitioners.
+
+# 7 Limitations
+
+Our view of this work is as a starting point of an efficient, scalable, and generalizable framework for optimizer search. And we expect plenty of room for improvement for future works. For instance, we identify the following concrete limitations of the method:
+
+1. We use pre-computed momentum terms as input to our search space. This is a practice borrowed from NOS-RL. Adding commonly used terms ease the job of the search algorithm because it does not have to rediscover them from scratch every time. However, searching for novel momentum update rules could potentially help to find even stronger optimizers. In principle, our framework allows it: one can do this by inserting an operator with its own internal state. This would serve as a direction for future explorations.
+2. Identifying proper hyperparameters for an optimizer is essentially for evaluation. In the current work, we use a simple grid search to discover the best learning rate for an optimizer. While it works fine for our tasks, this could potentially be suboptimal as it might underestimate some optimizers. Leveraging advanced fast HPO during the search phase could be another direction to explore.
+3. Although our framework is $100\mathrm{x}$ faster than the comparable method (NOS-RL), it still requires 128 evaluations in the search phase. These evaluations can be largely parallelized. But potentially, the efficiency can be improved further with better search algorithms, more train-free tests, knowledge transfer, e.t.c.
+
+# Reproducibility & ethics statements
+
+Reproducibility We have specified the setup for ours experiments in the main paper and Appendix, including settings for each task and hyperparameters for our method. The code and the optimizers found by our methods will also be published on Github upon acceptance to encourage future development. Before then, a copy of our code is included in the supplementary material for reference.
+
+Ethics We are not aware of any potential ethical concerns regarding our work.
+
+# Acknowledgments and Disclosure of Funding
+
+This work is supported in part by NSF under IIS-2008173, IIS-2048280, an Okawa research grant and a Google research scholar award.
+
+# References
+
+[1] Miles Cranmer. Pysr: Fast & parallelized symbolic regression in python/julia, september 2020. URL https://doi.org/10.5281/zenodo, 4052869.
+[2] David H Wolpert and William G Macready. No free lunch theorems for optimization. IEEE transactions on evolutionary computation, 1(1):67-82, 1997.
+[3] C Lee Giles, Kurt D Bollacker, and Steve Lawrence. Citeseer: An automatic citation indexing system. In Proceedings of the third ACM conference on Digital libraries, pages 89-98, 1998.
+[4] Andrew Kachites McCallum, Kamal Nigam, Jason Rennie, and Kristie Seymore. Automating the construction of internet portals with machine learning. Information Retrieval, 3(2):127-163, 2000.
+[5] Bill Dolan and Chris Brockett. Automatically constructing a corpus of sentential paraphrases. In Third International Workshop on Paraphrasing (IWP2005), 2005.
+[6] Prithviraj Sen, Galileo Namata, Mustafa Bilgic, Lise Getoor, Brian Galligher, and Tina Eliassi-Rad. Collective classification in network data. AI magazine, 29(3):93-93, 2008.
+[7] Luisa Bentivogli, Peter Clark, Ido Dagan, and Danilo Giampiccolo. The fifth pascal recognizing textual entailment challenge. In TAC, 2009.
+[8] Alex Krizhevsky, Geoffrey Hinton, et al. Learning multiple layers of features from tiny images. 2009.
+[9] Diederik P Kingma and Jimmy Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014.
+[10] Marcin Andrychowicz, Misha Denil, Sergio Gomez, Matthew W Hoffman, David Pfau, Tom Schaul, Brendan Shillingford, and Nando De Freitas. Learning to learn by gradient descent by gradient descent. Advances in neural information processing systems, 29, 2016.
+[11] 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, pages 770-778, 2016.
+[12] Ke Li and Jitendra Malik. Learning to optimize. arXiv preprint arXiv:1606.01885, 2016.
+[13] Emilio Parisotto, Abdel-rahman Mohamed, Rishabh Singh, Lihong Li, Dengyong Zhou, and Pushmeet Kohli. Neuro-symbolic program synthesis. arXiv preprint arXiv:1611.01855, 2016.
+[14] Sergey Zagoruyko and Nikos Komodakis. Wide residual networks. arXiv preprint arXiv:1605.07146, 2016.
+[15] Irwan Bello, Barret Zoph, Vijay Vasudevan, and Quoc V Le. Neural optimizer search with reinforcement learning. In International Conference on Machine Learning, pages 459-468. PMLR, 2017.
+[16] Daniel Cer, Mona Diab, Eneko Agirre, Inigo Lopez-Gazpio, and Lucia Specia. Semeval-2017 task 1: Semantic textual similarity-multilingual and cross-lingual focused evaluation. arXiv preprint arXiv:1708.00055, 2017.
+[17] Yutian Chen, Matthew W Hoffman, Sergio Gómez Colmenarejo, Misha Denil, Timothy P Lillicrap, Matt Botvinick, and Nando Freitas. Learning to learn without gradient descent by gradient descent. In International Conference on Machine Learning, pages 748-756. PMLR, 2017.
+[18] Will Hamilton, Zhitao Ying, and Jure Leskovec. Inductive representation learning on large graphs. Advances in neural information processing systems, 30, 2017.
+[19] Ilya Loshchilov and Frank Hutter. Decoupled weight decay regularization. arXiv preprint arXiv:1711.05101, 2017.
+
+[20] Aleksander Madry, Aleksandar Makelov, Ludwig Schmidt, Dimitris Tsipras, and Adrian Vladu. Towards deep learning models resistant to adversarial attacks. arXiv preprint arXiv:1706.06083, 2017.
+[21] Petar Velicković, Guillem Cucurull, Arantxa Casanova, Adriana Romero, Pietro Lio, and Yoshua Bengio. Graph attention networks. arXiv preprint arXiv:1710.10903, 2017.
+[22] Barret Zoph and Quoc V. Le. Neural architecture search with reinforcement learning. In ICLR, 2017.
+[23] Stefan Falkner, Aaron Klein, and Frank Hutter. Bohb: Robust and efficient hyperparameter optimization at scale. In International Conference on Machine Learning, pages 1437-1446. PMLR, 2018.
+[24] Lazar Valkov, Dipak Chaudhari, Akash Srivastava, Charles Sutton, and Swarat Chaudhuri. Houdini: Lifelong learning as program synthesis. Advances in Neural Information Processing Systems, 31, 2018.
+[25] Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel R Bowman. Glue: A multi-task benchmark and analysis platform for natural language understanding. In International Conference on Learning Representations, 2018.
+[26] Sirui Xie, Hehui Zheng, Chunxiao Liu, and Liang Lin. Snas: stochastic neural architecture search. arXiv preprint arXiv:1812.09926, 2018.
+[27] Yair Carmon, Aditi Raghunathan, Ludwig Schmidt, John C Duchi, and Percy S Liang. Unlabeled data improves adversarial robustness. Advances in Neural Information Processing Systems, 32, 2019.
+[28] Wei-Lin Chiang, Xuanqing Liu, Si Si, Yang Li, Samy Bengio, and Cho-Jui Hsieh. Cluster-gcn: An efficient algorithm for training deep and large graph convolutional networks. In Proceedings of the 25th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining, pages 257-266, 2019.
+[29] Xuanyi Dong and Yi Yang. Searching for a robust neural architecture in fourgpu hours. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 1761-1770, 2019.
+[30] Kevin Ellis, Maxwell Nye, Yewen Pu, Felix Sosa, Josh Tenenbaum, and Armando Solar-Lezama. Write, execute, assess: Program synthesis with a repl. Advances in Neural Information Processing Systems, 32, 2019.
+[31] Logan Engstrom, Andrew Ilyas, Hadi Salman, Shibani Santurkar, and Dimitris Tsipras. Robustness (python library), 2019.
+[32] Golnaz Ghiasi, Tsung-Yi Lin, and Quoc V Le. Nas-fpn: Learning scalable feature pyramid architecture for object detection. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 7036-7045, 2019.
+[33] Yufan Jiang, Chi Hu, Tong Xiao, Chunliang Zhang, and Jingbo Zhu. Improved differentiable architecture search for language modeling and named entity recognition. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3585-3590, 2019.
+[34] Jacob Devlin Ming-Wei Chang Kenton and Lee Kristina Toutanova. Bert: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of NAACL-HLT, pages 4171–4186, 2019.
+[35] Guillaume Lample and François Charton. Deep learning for symbolic mathematics. In International Conference on Learning Representations, 2019.
+[36] Chuming Li, Xin Yuan, Chen Lin, Minghao Guo, Wei Wu, Junjie Yan, and Wanli Ouyang. Ampls: Automl for loss function search. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 8410-8419, 2019.
+
+[37] Sungbin Lim, Ildoo Kim, Taesup Kim, Chiheon Kim, and Sungwoong Kim. Fast autoaugment. Advances in Neural Information Processing Systems, 32, 2019.
+[38] Chenxi Liu, Liang-Chieh Chen, Florian Schroff, Hartwig Adam, Wei Hua, Alan L Yuille, and Li Fei-Fei. Auto-deeplab: Hierarchical neural architecture search for semantic image segmentation. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 82–92, 2019.
+[39] Hanxiao Liu, Karen Simonyan, and Yiming Yang. Autoaugment: Learning augmentation policies from data. In Proceedings of the IEEE/CVF International Conference on Computer Vision, 2019.
+[40] Hanxiao Liu, Karen Simonyan, and Yiming Yang. DARTS: Differentiable architecture search. In International Conference on Learning Representations, 2019.
+[41] Luke Metz, Niru Maheswaranathan, Jeremy Nixon, Daniel Freeman, and Jascha Sohl-Dickstein. Understanding and correcting pathologies in the training of learned optimizers. In International Conference on Machine Learning, pages 4556-4565. PMLR, 2019.
+[42] Yisen Wang, Difan Zou, Jinfeng Yi, James Bailey, Xingjun Ma, and Quanquan Gu. Improving adversarial robustness requires revisiting misclassified examples. In International Conference on Learning Representations, 2019.
+[43] Alex Warstadt, Amanpreet Singh, and Samuel R Bowman. Neural network acceptability judgments. Transactions of the Association for Computational Linguistics, 7:625-641, 2019.
+[44] Daoyuan Chen, Yaliang Li, Minghui Qiu, Zhen Wang, Bofang Li, Bolin Ding, Hongbo Deng, Jun Huang, Wei Lin, and Jingren Zhou. Adabert: Task-adaptive bert compression with differentiable neural architecture search. arXiv preprint arXiv:2001.04246, 2020.
+[45] Francesco Croce, Maksym Andriushchenko, Vikash Sehwag, Edoardo Debenedetti, Nicolas Flammarion, Mung Chiang, Prateek Mittal, and Matthias Hein. Robustbench: a standardized adversarial robustness benchmark. arXiv preprint arXiv:2010.09670, 2020.
+[46] Francesco Croce and Matthias Hein. Reliable evaluation of adversarial robustness with an ensemble of diverse parameter-free attacks. In ICML, 2020.
+[47] Lukasz Dudziak, Thomas Chau, Mohamed S. Abdelfattah, Royson Lee, Hyeji Kim, and Nicholas D. Lane. Brp-nas: Prediction-based nas using gcns. In NeurIPS, 2020.
+[48] Sven Gowal, Chongli Qin, Jonathan Uesato, Timothy Mann, and Pushmeet Kohli. Uncovering the limits of adversarial training against norm-bounded adversarial examples. arXiv preprint arXiv:2010.03593, 2020.
+[49] Weihua Hu, Matthias Fey, Marinka Zitnik, Yuxiao Dong, Hongyu Ren, Bowen Liu, Michele Catasta, and Jure Leskovec. Open graph benchmark: Datasets for machine learning on graphs. Advances in neural information processing systems, 33:22118-22133, 2020.
+[50] Abhinav Mehrotra, Alberto Gil CP Ramos, Sourav Bhattacharya, Lukasz Dudziak, Ravichander Vipperla, Thomas Chau, Mohamed S Abdelfattah, Samin Ishtiaq, and Nicholas Donald Lane. Nas-bench-asr: Reproducible neural architecture search for speech recognition. In International Conference on Learning Representations, 2020.
+[51] Esteban Real, Chen Liang, David So, and Quoc Le. Automl-zero: Evolving machine learning algorithms from scratch. In International Conference on Machine Learning, pages 8007-8019. PMLR, 2020.
+[52] Vikash Sehwag, Shiqi Wang, Prateek Mittal, and Suman Jana. Hydra: Pruning adversarily robust neural networks. Advances in Neural Information Processing Systems, 33:19655-19666, 2020.
+[53] Ameesh Shah, Eric Zhan, Jennifer Sun, Abhinav Verma, Yisong Yue, and Swarat Chaudhuri. Learning differentiable programs with admissible neural heuristics. Advances in neural information processing systems, 33:4940-4952, 2020.
+
+[54] Silviu-Marian Udrescu and Max Tegmark. Ai feynman: A physics-inspired method for symbolic regression. Science Advances, 6(16):eay2631, 2020.
+[55] Ruochen Wang, Minhao Cheng, Xiangning Chen, Xiaocheng Tang, and Cho-Jui Hsieh. Rethinking architecture selection in differentiable nas. In International Conference on Learning Representations, 2020.
+[56] Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierrick Cistac, Tim Rault, Rémi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander M. Rush. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45, Online, October 2020. Association for Computational Linguistics.
+[57] Eric Wong, Leslie Rice, and J Zico Kolter. Fast is better than free: Revisiting adversarial training. arXiv preprint arXiv:2001.03994, 2020.
+[58] Dongxian Wu, Shu-Tao Xia, and Yisen Wang. Adversarial weight perturbation helps robust generalization. In NeurIPS, 2020.
+[59] Tianlong Chen, Xiaohan Chen, Wuyang Chen, Howard Heaton, Jialin Liu, Zhangyang Wang, and Wotao Yin. Learning to optimize: A primer and a benchmark. arXiv preprint arXiv:2103.12828, 2021.
+[60] Xiangning Chen, Ruochen Wang, Minhao Cheng, Xiaocheng Tang, and Cho-Jui Hsieh. DrNAS: Dirichlet neural architecture search. In ICLR, 2021.
+[61] Guofeng Cui and He Zhu. Differentiable synthesis of program architectures. Advances in Neural Information Processing Systems, 34, 2021.
+[62] Shoukang Hu, Ruochen Wang, HONG Lanqing, Zhenguo Li, Cho-Jui Hsieh, and Jiashi Feng. Generalizing few-shot nas with gradient matching. In International Conference on Learning Representations, 2021.
+[63] Mikel Landajuela, Brenden K Petersen, Sookyung Kim, Claudio P Santiago, Ruben Glatt, Nathan Mundhenk, Jacob F Pettit, and Daniel Faissol. Discovering symbolic policies with deep reinforcement learning. In International Conference on Machine Learning, pages 5979-5989. PMLR, 2021.
+[64] Brenden K Petersen, Mikel Landajuela, T Nathan Mundhenk, Claudio P Santiago, Soo K Kim, and Joanne T Kim. Deep symbolic regression: Recovering mathematical expressions from data via risk-seeking policy gradients. In Proc. of the International Conference on Learning Representations, 2021.
+[65] Nicholas Roberts, Mikhail Khodak, Tri Dao, Liam Li, Christopher Ré, and Ameet Talwalkar. Rethinking neural operations for diverse tasks. Advances in Neural Information Processing Systems, 34, 2021.
+[66] Paul Vicol, Luke Metz, and Jascha Sohl-Dickstein. Unbiased gradient estimation in unrolled computation graphs with persistent evolution strategies. In International Conference on Machine Learning, pages 10553-10563. PMLR, 2021.
+[67] Ruochen Wang, Xiangning Chen, Minhao Cheng, Xiaocheng Tang, and Cho-Jui Hsieh. RANK-NOSH: Efficient predictor-based architecture search via non-uniform successive halving. In ICCV, 2021.
+[68] Wenqing Zheng, Tianlong Chen, Ting-Kuei Hu, and Zhangyang Wang. Symbolic learning to optimize: Towards interpretability and scalability. In International Conference on Learning Representations, 2021.
+[69] Xiangning Chen, Chen Liang, Da Huang, Esteban Real, Yao Liu, Kaiyuan Wang, Cho-Jui Hsieh, Yifeng Lu, and Quoc V Le. Evolved optimizer for visio. In AutoML 2022 Workshop, 2022.
+[70] Yu A Shreider. The Monte Carlo method: the method of statistical trials, volume 87. Elsevier, 2014.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See Section 6
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] We are not aware of any negative societal impacts of this work.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] Due to space limits, some of these training details are included in the Appendix
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] The error bars for all optimizers are shown in the main text. The only exception is MNISTNET task, where we removed error bar for a cleaner plot. We will display the error bar for this task in the Appendix.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [Yes]
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientnonparametricoptimizersearchfordiversetasks/images.zip b/efficientnonparametricoptimizersearchfordiversetasks/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..30366a939f3896024a3e89065d7fbf99bd7deaea
--- /dev/null
+++ b/efficientnonparametricoptimizersearchfordiversetasks/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:33010b3cafef82b0445e5550a0a483ac77e58df87ce47fe3aa47a0aa93b7b3a7
+size 238758
diff --git a/efficientnonparametricoptimizersearchfordiversetasks/layout.json b/efficientnonparametricoptimizersearchfordiversetasks/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..3b0d9ea61ad8b7b707c88a8f675287d654e4bbbd
--- /dev/null
+++ b/efficientnonparametricoptimizersearchfordiversetasks/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:61315260125f91b902cbe7b12c4e920987dbda537875bc4cf8027458696a032c
+size 444181
diff --git a/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/81276465-7cad-490d-9a4f-b456a21810a8_content_list.json b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/81276465-7cad-490d-9a4f-b456a21810a8_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..407cf43665679e5136b58cb433e799dbd3365a1d
--- /dev/null
+++ b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/81276465-7cad-490d-9a4f-b456a21810a8_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1b8939248b6634704c91f4ff5cf1259166d111554c7f2e431a46ed846611e0be
+size 93235
diff --git a/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/81276465-7cad-490d-9a4f-b456a21810a8_model.json b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/81276465-7cad-490d-9a4f-b456a21810a8_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..17543d0007ee1d99e825da748367fe4e4ff33093
--- /dev/null
+++ b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/81276465-7cad-490d-9a4f-b456a21810a8_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4b488c88b0fc3723f06f0c8c581b144096284a05117989ae1b8114f269a7d9f0
+size 117554
diff --git a/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/81276465-7cad-490d-9a4f-b456a21810a8_origin.pdf b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/81276465-7cad-490d-9a4f-b456a21810a8_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..3538aa4322c8df789c90a01cceb0c51fb385e9e7
--- /dev/null
+++ b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/81276465-7cad-490d-9a4f-b456a21810a8_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ceee7b70ce1e19c0c9832320baadf3f0ded6bf3d1687f37ab688b17144c681aa
+size 447287
diff --git a/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/full.md b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..724e0036f6f7321d7996cedaa7c6021f907a8d7f
--- /dev/null
+++ b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/full.md
@@ -0,0 +1,471 @@
+# Efficient Phi-Regret Minimization in Extensive-Form Games via Online Mirror Descent
+
+Yu Bai
+
+Salesforce Research
+
+yu.bai@salesforce.com
+
+Chi Jin
+
+Princeton University
+
+chij@princeton.edu
+
+Song Mei
+
+UC Berkeley
+
+songmei@berkeley.edu
+
+Ziang Song
+
+Stanford University
+
+ziangs@stanford.edu
+
+Tiancheng Yu
+
+MIT
+
+yutc@mit.edu
+
+# Abstract
+
+A conceptually appealing approach for learning Extensive-Form Games (EFGs) is to convert them to Normal-Form Games (NFGs). This approach enables us to directly translate state-of-the-art techniques and analyses in NFGs to learning EFGs, but typically suffers from computational intractability due to the exponential blow-up of the game size introduced by the conversion. In this paper, we address this problem in natural and important setups for the $\Phi$ -Hedge algorithm—A generic algorithm capable of learning a large class of equilibria for NFGs. We show that $\Phi$ -Hedge can be directly used to learn Nash Equilibria (zero-sum settings), Normal-Form Coarse Correlated Equilibria (NFCCE), and Extensive-Form Correlated Equilibria (EFCE) in EFGs. We prove that, in those settings, the $\Phi$ -Hedge algorithms are equivalent to standard Online Mirror Descent (OMD) algorithms for EFGs with suitable dilated regularizers, and run in polynomial time. This new connection further allows us to design and analyze a new class of OMD algorithms based on modifying its log-partition function. In particular, we design an improved algorithm with balancing techniques that achieves a sharp $\tilde{\mathcal{O}}(\sqrt{XAT})$ EFCE-regret under bandit-feedback in an EFG with $X$ information sets, $A$ actions, and $T$ episodes. To our best knowledge, this is the first such rate and matches the information-theoretic lower bound.
+
+# 1 Introduction
+
+Extensive form games (EFGs) is a natural formulation for multi-player games with imperfect information and sequential play, which models real-world games such as Poker [9, 10], Bridge [45], Scotland Yard [41], Diplomacy [7] and has many other important applications such as cybersecurity [32], auction [39], marketing [29]. In multi-player general-sum EFGs, computing an approximate Nash equilibrium (NE) [40] is PPAD-hard [15] and thus likely intractable. A reasonable and computationally tractable solution concept in general-sum EFGs is the extensive-form correlated equilibria (EFCE) [46, 27, 13, 23]. It is known that, as long as each player runs an uncoupled dynamics minimizing a suitable EFCE-regret, their average joint policy will converge to an EFCE [28].
+
+Existing algorithms of minimizing the EFCE-regret are mostly built upon the regret decomposition techniques [51], which utilize the structure of the game and the set of policy modifications [13, 38, 23, 42]. For example, Morrill et al. [38] decomposes the EFCE-regret to local regrets at each information set (infoset) with each of them handled by a local regret minimizer; Farina et al. [23] utilizes the trigger structure of the policy modification set to decompose the regret to external-like regrets.
+
+There are at least two alternative approaches to designing regret minimization algorithms for EFGs. The first is to convert a EFG to a normal-form game (NFG) and use NFG-based algorithms such as $\Phi$ -Hedge [28]. This approach typically admits simple algorithm designs and sharp regret bounds by directly translating existing results in NFGs [44]. However, the conversion introduces an exponential blow-up in the game size, and makes such algorithms computationally intractable in general. The computational efficiency of these NFG-based algorithms is recently investigated by Farina et al. [25] in the external regret minimization problem, who provided an efficient implementation of an NFG-based algorithm using "kernel tricks". The second is to use Online Mirror Descent (OMD) algorithms via suitably designed regularizers over the parameter space. This approach has been successfully implemented in minimizing the external regret [35] but not yet generalized to the EFCE-regret, as it remains unclear how to design suitable regularizers for the policy modification space.
+
+In this paper, we develop the first line of EFCE-regret minimization algorithms along both lines of approaches above, and identify an equivalence between them. We consider EFCE-regret minimization in EFGs with $X$ infosets, $A$ actions, and maximum $L_{1}$ -norm of sequence-form policies bounded by $\| \Pi \| _1$ (cf. Section 2.2 for the formal definition). Our contributions can be summarized as follows:
+
+- We present an efficient implementation of the $\Phi$ -Hedge algorithm for minimizing the extensive-form trigger regret, by recursively evaluating the gradient of a log-partition function (Section 3.1). The implementation further reveals that this algorithm (via reparametrization) is equivalent to an OMD algorithm with dilated regularizers, which we term as EFCE-OMD (Section C.1).
+- We show that EFCE-OMD achieves trigger regret bound $\widetilde{\mathcal{O}} (\sqrt{\|\Pi\|_1T})$ under full feedback and $\widetilde{\mathcal{O}} (\sqrt{X\|\Pi\|_1AT})$ under bandit feedback (Section 3.3). Notably, the proofs are done using the corresponding NFG analysis straightforwardly, and is independent of the actual implementation.
+- We design an improved algorithm Balanced EFCE-OMD, and show that it achieves a sharp $\widetilde{\mathcal{O}} (\sqrt{XAT})$ trigger regret under bandit feedback (Section 4). This improves over EFCE-OMD by a factor of $\| \Pi \| _1$ and is the first to match the information-theoretic lower bound. The algorithm works by modifying the above log-partition function using a variety of balancing techniques, and is equivalent to another OMD algorithm (but no longer an NFG algorithm).
+- As another example of our framework, we show that the $\Phi$ -Hedge algorithm for vanilla (external) regret minimization in EFGs, along with its efficient implementation via "kernelization" developed recently in [25], is actually equivalent to standard OMD with dilated entropy (Section 5).
+
+# 1.1 Related work
+
+$\Phi$ -regret minimization and correlated equilibrium The $\Phi$ -regret minimization framework was introduced in Greenwald and Jafari [28] and Stoltz and Lugosi [44]. In particular, Greenwald and Jafari [28] showed that uncoupled no $\Phi$ -regret dynamics leads to $\Phi$ -correlated equilibria, a generalized notion of correlated equilibria introduced by Aumann [5]. Stoltz and Lugosi [44] then developed a family of $\Phi$ -regret minimization algorithms using the fixed-point method (including the $\Phi$ -Hedge algorithm considered in this paper), and derived explicit regret bounds. Two important special cases of $\Phi$ -regret are the internal regret and swap regret in normal-form games [43, 8]. A recent line of work developed algorithms with $\mathcal{O}(\mathrm{polylog}T)$ swap regret bound in normal-form games [2, 3].
+
+Regret minimization in EFG from full feedback A line of work considers external regret minimization in EFGs from full feedback [51, 12, 11, 21, 50]. In particular, Zhou et al. [50] achieves $\widetilde{\mathcal{O}} (\sqrt{XT})$ external regret. The recent work of Farina et al. [25] develops the first algorithm to achieve $\widetilde{\mathcal{O}} (\| \Pi \| _1\mathrm{polylog}T)$ external regret in EFGs by converting it to an NFG and invoking the fast rate of Optimistic Hedge [16], along with an efficient implementation via the "kernel trick". Our $\Phi$ -regret framework covers their algorithm as a special case, and we further show that their algorithm (along with its efficient implementation) is equivalent to the standard OMD with dilated entropy.
+
+The notion of Extensive-Form Correlated Equilibria (EFCE) in EFGs was introduced in Von Stengel and Forges [46]. Optimization-based algorithms for computing computing EFCEs in multi-player EFGs from full feedback have been proposed in Huang and von Stengel [31], Farina et al. [20].
+
+Gordon et al. [27] first proposed to use uncoupled EFCE-regret minimization dynamics to compute EFCE; however, they do not explain how to efficiently implement each iteration of the dynamics. Recent works [13, 23, 38, 42] developed uncoupled EFCE regret minimization learning dynamics
+
+with efficient implementation; All of these algorithms are based on counterfactual regret decomposition [51] and minimizing each trigger regret (first considered by Dudik and Gordon [17], Gordon et al. [27]) using a different regret minimizer. Celli et al. [13] decomposed the regret to each laminar subtree, but they did not give an explicit regret bound. Farina et al. [23] decomposed the regret to each trigger sequence and used CFR type algorithm to minimize the regret on each trigger sequence and achieved an $\tilde{O} (\sqrt{X^2T})$ EFCE-regret bound. Morrill et al. [38], Song et al. [42] decomposed the regret to each information set and use regret minimization algorithms with time-selection functions [8, 33] to minimize the regret on each information set, giving $\tilde{\mathcal{O}} (\sqrt{X^2T})$ and $\tilde{\mathcal{O}} (\sqrt{XT})$ regret bounds respectively. In this paper, we show that the simple $\Phi$ -Hedge algorithm, which has an efficient implementation and an intuitive interpretation, can also achieve the state-of-art $\tilde{\mathcal{O}} (\sqrt{XT})$ regret bound in the full feedback setting.
+
+Regret minimization in EFG from bandit feedback Minimizing the external regret in EFGs from bandit feedback is considered in a more recent line of work [36, 22, 19, 24, 49, 47, 34, 6]. Dudík and Gordon [18] consider sample-based learning of EFCE in succinct extensive-form games; however, their algorithm relies on an approximate Markov-Chain Monte-Carlo sampling subroutine that does not lead to a sample complexity guarantee.
+
+A concurrent work by Song et al. [42] also achieves $\widetilde{\mathcal{O}}(X/\varepsilon^2)$ sample complexity for learning EFCE under bandit feedback (when only highlighting $X$ ) using the Balanced $K$ -EFR algorithm. Our work achieves the same linear in $X$ sample complexity, but using a very different algorithm (Balanced EFCE-OMD). We also remark that the algorithm of [42] cannot minimize the EFCE-regret against adversarial opponents from bandit feedback like our algorithm, as their algorithm requires playing multiple episodes against a fixed opponent, which is infeasible when the opponent is adversarial.
+
+# 2 Preliminaries
+
+# 2.1 $\Phi$ -regret minimization and $\Phi$ -Hedge algorithm
+
+Consider a generic linear regret minimization problem on a policy set $\Pi \subset \mathbb{R}_{\geq 0}^{d}$ with respect to a policy modification set $\Phi \subset \mathbb{R}^{d\times d}$ . Here $\Pi$ is a convex compact subset of $\mathbb{R}^d$ , and $\Phi$ is a convex compact subset of $\mathbb{R}^{d\times d}$ , where each $\phi \in \Phi$ is a policy modification function which is a linear transformation from $\mathbb{R}^d$ to $\mathbb{R}^d$ that maps $\Pi$ to itself ( $\phi(\Pi) \subseteq \Pi$ ). For any algorithm that plays policies $\{\mu^t\}_{t=1}^T$ within $T$ rounds and receives loss functions $\{\ell^t\}_{t=1}^T \subset \mathbb{R}_{\geq 0}^d$ , the $\Phi$ -regret is defined as
+
+$$
+\operatorname {R e g} ^ {\Phi} (T) := \sup _ {\phi \in \Phi} \sum_ {t = 1} ^ {T} \left\langle \mu^ {t} - \phi \mu^ {t}, \ell^ {t} \right\rangle . \tag {1}
+$$
+
+The $\Phi$ -regret subsumes the vanilla regret (i.e. external regret) as a special case by taking $\Phi$ to be the set of all constant modifications $\Phi^{\mathrm{ext}} \coloneqq \{\phi_{\mu_\star} : \mu_\star \in \Pi\}$ where $\phi_{\mu^\star} \mu = \mu^\star$ for all $\mu \in \Pi$ . Another widely studied example is the swap regret [8] (and the closely related internal regret [26]) for normal-form games, where $\Pi = \Delta_d$ is the probability simplex over $d$ actions, and $\Phi$ is the set of all stochastic matrices (i.e. those mapping $\Delta_d$ to itself). A primary motivation for minimizing the $\Phi$ -regret is for computing various types of Correlated Equilibria (CEs) in multi-player games using the online-to-batch conversion (see e.g. [14]), which has been established in many games and has been a cornerstone in the online learning and games literature.
+
+$\Phi$ -Hedge algorithm A widely used strategy for minimizing the $\Phi$ -regret is to use any (black-box) linear regret minimization algorithm on the $\Phi$ set to produce a sequence of $\{\phi^t\}_{t=1}^T \subset \Phi$ , combined with the fixed point technique (e.g. [43])—Output policy $\mu^t$ that satisfies the fixed-point equation $\phi^t\mu^t = \mu^t$ in each round $t$ . In the common scenario where $\Phi$ is the convex hull of a finite number of vertices, i.e. $\Phi = \mathrm{conv}(\Phi_0)$ where $\Phi_0$ is a finite subset of $\Phi$ , a standard regret minimization algorithm over $\Phi$ is Hedge (a.k.a. Exponential Weights) [4], leading to the $\Phi$ -Hedge algorithm (Algorithm 1).
+
+It is a standard result ([44], see also Lemma A.1) that Algorithm 1 achieves $\Phi$ -regret bound
+
+$$
+\operatorname {R e g} ^ {\Phi} (T) \leq \frac {\log | \Phi_ {0} |}{\eta} + \frac {\eta}{2} \sum_ {t = 1} ^ {T} \sum_ {\phi \in \Phi_ {0}} p _ {\phi} ^ {t} \left(\left\langle \phi \mu^ {t}, \ell^ {t} \right\rangle\right) ^ {2}. \tag {2}
+$$
+
+By choosing $\eta > 0$ , this result implies a quite desirable bound $\mathrm{Reg}^{\Phi}(T) \leq L \sqrt{2 \log |\Phi_0| \cdot T}$ in the full-feedback setting (assuming bounded loss $\langle \phi \mu^t, \ell^t \rangle \leq L$ ), and can also be used to prove regret bounds in the bandit-feedback setting.
+
+# Algorithm 1 $\Phi$ -Hedge
+
+Require: Finite vertex set $\Phi_0\subset \mathbb{R}^{d\times d}$ such that $\mathrm{conv}(\Phi_0) = \Phi$ ; Learning rate $\eta$
+
+1: Initialize $p^1 \in \Delta_{\Phi_0}$ with $p_\phi^1 = 1 / |\Phi_0|$ for $\phi \in \Phi_0$ .
+2: for iteration $t = 1,\dots ,T$ do
+3: Compute $\phi^t = \sum_{\phi \in \Phi_0}p_\phi^t\phi$
+4: Set policy $\mu^t$ to be the fixed point of equation $\mu^t = \phi^t\mu^t$
+5: Receive loss function $\ell^t\in \mathbb{R}_{\geq 0}^d$ , suffer loss $\langle \mu^t,\ell^t\rangle$
+6: Update $p_{\phi}^{t + 1} \propto_{\phi} p_{\phi}^{t} \cdot \exp \{-\eta \langle \phi \mu^{t}, \ell^{t} \rangle \}$ .
+
+# 2.2 Extensive-form games (EFGs) and extensive-form trigger regret
+
+In this paper, we consider $m$ -player imperfect-information extensive-form games (EFGs) with perfectrecall (see Appendix B.1 for detailed definitions). For the purpose of this work, we consider an alternative formulation of EFGs—Tree-Form Adversarial Markov Decision Processes (TFAMDP). This model is equivalent to studying EFGs from the perspective of a single player, while treating all other players as adversaries who can change both transitions and rewards in each round.
+
+Tree-form adversarial MDP We consider an episodic, tabular TFAMDP which consists of the followings $(H,\{\mathcal{X}_h\}_{h\in [H]},\mathcal{A},\mathcal{T},\{p_h^t\}_{h\in \{0\} \cup [H],t\geq 1},\{R_h^t\}_{h\in [H],t\geq 1})$ . Here $H\in \mathbb{N}_{+}$ is the horizon length; $\mathcal{X}_h$ is the space of information sets (henceforth infosets) at step $h$ with size $|\mathcal{X}_h| = X_h$ and $\sum_{h = 1}^{H}X_{h} = X$ ; $\mathcal{A}$ is the action space with size $|\mathcal{A}| = A$ . Next, $\mathcal{T} = \{\mathcal{C}(x,a)\}_{(x,a)\in \mathcal{X}\times \mathcal{A}}$ defines the tree structure over the infosets and actions, where $\mathcal{C}(x_h,a_h)\subset \mathcal{X}_{h + 1}$ denotes the set of immediate children of $(x_{h},a_{h})$ . Furthermore, $\{\mathcal{C}(x_h,a_h)\}_{(x_h,a_h)\in \mathcal{X}_h\times \mathcal{A}}$ forms a partition of $\mathcal{X}_{h + 1}$ . It directly follows from the tree structure of TFAMDP that the player has perfect recall, i.e., for any infoset $x_{h}\in \mathcal{X}_{h}$ , there is a unique history $(x_{1},a_{1},\ldots ,x_{h - 1},a_{h - 1})$ that leads to $x_{h}$ . Furthermore, $p_0^t (\cdot)\in \Delta_{\mathcal{X}_1}$ is the initial distribution over $\mathcal{X}_1$ at episode $t$ ; $p_h^t (\cdot |x_h,a_h)$ is the transition probability from $(x_{h},a_{h})$ to its immediate children $\mathcal{C}(x_h,a_h)$ at episode $t$ ; $R_h^t (\cdot |x_h,a_h)$ is the distribution of the stochastic reward $r\in [0,1]$ received at $(x_{h},a_{h})$ at episode $t$ , with expectation $\overline{R}_h^t (x_h,a_h)$ .
+
+At the beginning of episode $t$ , an adversary will first choose the initial distribution $p_0^t$ , transition $\{p_h^t\}_{h \in [H]}$ , and reward distribution $\{R_h^t\}_{h \in [H]}$ . Then in the bandit feedback setting, at each step $h$ , the player observes the current info set $x_h$ , takes an action $a_h$ , receives a bandit feedback of the reward $r_h^t \sim R_h^t(\cdot | x_h, a_h)$ , and the environment transitions to the next state $x_{h+1} \sim p_h^t(\cdot | x_h, a_h)$ .
+
+Policies We use $\mu = \{\mu_h(\cdot |x_h)\}_{h\in [H],x_h\in \mathcal{X}_h}$ to denote a policy, where each $\mu_h(\cdot |x_h)\in \Delta_{\mathcal{A}}$ is the action distribution at info set $x_{h}$ . We say $\mu$ is a deterministic policy if $\mu_h(\cdot |x_h)$ takes some single action with probability 1 for any $(h,x_h)$ . Let $\Pi$ denote the set of all possible policies. We denote the sequence form representation of policy $\mu \in \Pi$ by
+
+$$
+\mu_ {1: h} \left(x _ {h}, a _ {h}\right) := \prod_ {h ^ {\prime} = 1} ^ {h} \mu_ {h ^ {\prime}} \left(a _ {h ^ {\prime}} \mid x _ {h ^ {\prime}}\right), \tag {3}
+$$
+
+where $(x_{1},a_{1},\ldots ,x_{h - 1},a_{h - 1})$ is the unique history of $x_{h}$ . We also identify $\mu$ as a vector in $\mathbb{R}_{\geq 0}^{XA}$ , whose $(x_{h},a_{h})$ -th entry is equal to its sequence form $\mu_{1:h}(x_h,a_h)$ . Let $\| \Pi \| _1\coloneqq \max_{\mu \in \Pi}\| \mu \| _1$ , which admits bound $\| \Pi \| _1\leq X$ but can in addition be smaller (cf. Appendix B.3).
+
+Expected loss function Given any policy $\mu^t$ at round $t$ , the total expected loss received at round $t$ (which equals to $H$ minus the total rewards within round $t$ ) is given by
+
+$$
+\langle \mu^ {t}, \ell^ {t} \rangle := \sum_ {h, x _ {h}, a _ {h}} \mu_ {1: h} ^ {t} (x _ {h}, a _ {h}) \ell_ {h} ^ {t} (x _ {h}, a _ {h}),
+$$
+
+where the loss function for the $t$ -th round is given by $\ell^t = \{\ell_h^t (x_h,a_h)\}_{h,x_h,a_h}\in \mathbb{R}_{\geq 0}^{XA}$ :
+
+$$
+\ell_ {h} ^ {t} \left(x _ {h}, a _ {h}\right) := p _ {0} ^ {t} \left(x _ {1}\right) \prod_ {h ^ {\prime} = 1} ^ {h - 1} p _ {h ^ {\prime}} ^ {t} \left(x _ {h ^ {\prime} + 1} \mid x _ {h ^ {\prime}}, a _ {h ^ {\prime}}\right) \left[ 1 - \bar {R} _ {h} ^ {t} \left(x _ {h}, a _ {h}\right) \right], \tag {4}
+$$
+
+where $(x_{1},a_{1},\ldots ,x_{h - 1},a_{h - 1})$ is the unique history that leads to $x_{h}$ . In the full feedback setting, the learner is further capable of observing the full loss vector $\ell^t\in \mathbb{R}_{\geq 0}^{XA}$ at the end of each round $t$ .
+
+Subtree and subtree policies For any $g \leq h$ , $x_{g} \in \mathcal{X}_{g}, x_{h} \in \mathcal{X}_{h}$ , and any action $a_{g}, a_{h} \in \mathcal{A}$ , we say $x_{h}$ or $(x_{h}, a_{h})$ is in the subtree rooted at $x_{g}$ , written as $x_{h} \succeq x_{g}$ or $(x_{h}, a_{h}) \succeq x_{g}$ , if $x_{g}$ is either equal to $x_{h}$ or is a part of the unique preceding history $(x_{1}, a_{1}, \ldots, x_{h-1}, a_{h-1})$ which leads to $x_{h}$ . Similarly, we say $x_{h}$ or $(x_{h}, a_{h})$ is in the subtree of $(x_{g}, a_{g})$ , written as $x_{h} \succ (x_{g}, a_{g})$ or $(x_{h}, a_{h}) \succ (x_{g}, a_{g})$ , if $(x_{g}, a_{g})$ is either equal to $(x_{h}, a_{h})$ (only in the latter case), or is a part of the unique preceding history $(x_{1}, a_{1}, \ldots, x_{h-1}, a_{h-1})$ which leads to $x_{h}$ .
+
+For any $g \in [H]$ , and any assoc $\mathcal{X}_g \in \mathcal{X}_g$ , we use $\mu^{x_g} = \{\mu_h^{x_g}(\cdot | x_h) \in \Delta_{\mathcal{A}} : x_h \succeq x_g\}$ to denote a subtree policy rooted at $x_g$ . We use $\Pi^{x_g}$ and $\mathcal{V}^{x_g}$ to denote the set of all subtree policies and the set of all deterministic subtree policies rooted at $x_g$ . We denote the sequence form representation of $\mu^{x_g} \in \Pi^{x_g}$ by:
+
+$$
+\mu_ {g: h} ^ {x _ {g}} (x _ {h}, a _ {h}) = \left\{ \begin{array}{l l} \prod_ {h ^ {\prime} = g} ^ {h} \mu_ {h ^ {\prime}} ^ {x _ {g}} (a _ {h ^ {\prime}} | x _ {h ^ {\prime}}) & \text {i f} (x _ {h}, a _ {h}) \succeq x _ {g}, \\ 0 & \text {o t h e r w i s e}. \end{array} \right.
+$$
+
+Similarly, we can also identify any subtree policy $\mu^{x_g} \in \Pi^{x_g}$ as a vector in $\mathbb{R}_{\geq 0}^{XA}$ , whose $(x_h, a_h)$ -th entry is equal to its sequence form $\mu_{g:h}^{x_g}(x_h, a_h)$ (which is non-zero only on the subtree rooted at $x_g$ ).
+
+Extensive-form trigger regret The notion of trigger regret is introduced in [27, 13, 23]. An (extensive-form) trigger modification $\phi_{x_g a_g \to m^{x_g}}$ is a policy modification that modifies any policy $\mu \in \Pi$ as follows: When $x_g$ is visited and $a_g$ is about to be taken (by $\mu$ ), we say $x_g a_g$ is triggered, in which case the subtree policy rooted at $x_g$ is then replaced by $m^{x_g} \in \Pi^{x_g}$ . One can verify that the trigger modification $\phi_{x_g a_g \to m^{x_g}}$ can be written as a linear transformation that maps from $\Pi$ to $\Pi$ :
+
+$$
+\phi_ {x _ {g} a _ {g} \rightarrow m ^ {x _ {g}}} := \left(I - E _ {\succeq x _ {g} a _ {g}}\right) + m ^ {x _ {g}} e _ {x _ {g} a _ {g}} ^ {\top} \in \mathbb {R} ^ {X A \times X A}.
+$$
+
+Here, $E_{\succeq x_{g}a_{g}}$ is a diagonal matrix with diagonal entry 1 at all $(x_{h},a_{h})$ satisfying $(x_{h},a_{h})\succeq (x_{g},a_{g})$ and zero otherwise, and $e_{x_ga_g}\in \mathbb{R}^{XA}$ is an indicator vector whose only non-zero entry is 1 at $(x_{g},a_{g})$ . We say $\phi_{x_ga_g\to v^{x_g}}$ is a deterministic trigger modification if $v^{x_g}\in \mathcal{V}^{x_g}$ is a deterministic subtree policy. We denote the set of all deterministic trigger modifications and its convex hull as $\Phi_0^{\mathrm{Tr}}$ and $\Phi^{\mathrm{Tr}}$ respectively, where
+
+$$
+\Phi_ {0} ^ {\mathrm {T r}} := \bigcup_ {g, x _ {g}, a _ {g}} \bigcup_ {v ^ {x _ {g}} \in \mathcal {V} ^ {x _ {g}}} \left\{\phi_ {x _ {g} a _ {g} \rightarrow v ^ {x _ {g}}} \right\}, \quad \Phi^ {\mathrm {T r}} = \operatorname {c o n v} \left\{\Phi_ {0} ^ {\mathrm {T r}} \right\}. \tag {5}
+$$
+
+The (extensive-form) trigger regret is then defined as the difference in the total loss when comparing against the best extensive-form trigger modification in hindsight. We note that the trigger regret is a special case of $\Phi$ -regret (1) with $\Phi = \Phi^{\mathrm{Tr}}$ .
+
+Definition 1 (Extensive-Form Trigger Regret). For any algorithm that plays policies $\mu^t \in \Pi$ at round $t \in [T]$ , the extensive-form trigger regret (also the EFCE-regret) is defined as
+
+$$
+\operatorname {R e g} ^ {\mathsf {T r}} (T) := \max _ {\phi \in \Phi^ {\mathsf {T r}}} \sum_ {t = 1} ^ {T} \left\langle \mu^ {t} - \phi \mu^ {t}, \ell^ {t} \right\rangle . \tag {6}
+$$
+
+From trigger regret to Extensive-Form Correlated Equilibrium (EFCE) The importance of extensive-form trigger regret is in its connection to computing EFCE: By standard online-to-batch conversion [13, 23], if all players have low trigger regret (with $\mathrm{Reg}_i^{\mathrm{Tr}}(T)$ for the $i^{\mathrm{th}}$ player), then the average joint policy $\overline{\pi}$ is an $\varepsilon$ -EFCE, where $\varepsilon = \max_{i\in [m]}\mathrm{Reg}_i^{\mathrm{Tr}}(T) / T$ (cf. Appendix B.2). We remark in passing by taking $\Phi = \Phi^{\mathrm{ext}}$ , low $\Phi$ -regret implies learning (Normal-Form) Coarse Correlated Equilibria in EFGs, as well as Nash Equilibria in the two-player zero-sum setting [6].
+
+# 3 Efficient $\Phi$ -Hedge for Extensive-Form Trigger Regret Minimization
+
+In this section, we study the $\Phi$ -Hedge algorithm (Algorithm 1) for minimizing the trigger regret. Naively, Algorithm 1 requires maintaining and updating $p^t \in \Delta_{\Phi_0}$ (cf. Line 6), whose computational cost is linear in $|\Phi_0^{\mathrm{Tr}}|$ which can be exponential in $X$ in the worst case1. We begin by deriving an efficient implementation of the iterate $\phi^t \in \Phi$ (of Line 3) directly by exploiting the structure of $\Phi_0^{\mathrm{Tr}}$ .
+
+# 3.1 Efficient implementation of $\Phi^{\mathrm{Tr}}$ -Hedge algorithm
+
+We first use a standard trick to convert the computation of $\phi^t$ (Line 3 & 6, Algorithm 1) in $\Phi$ -Hedge to evaluating the gradient of a suitable log-partition function. This is stated in the lemma below (for any generic $\Phi_0$ ), whose proof can be found in Appendix C.2.
+
+Lemma 2 (Conversion to log-partition function). Define the log-partition function $F^{\Phi_0} : \mathbb{R}^{d \times d} \to \mathbb{R}$
+
+$$
+F ^ {\Phi_ {0}} (M) := \log \sum_ {\phi \in \Phi_ {0}} \exp \{- \langle \phi , M \rangle \}. \tag {7}
+$$
+
+Then Line 3 of $\Phi$ -Hedge (Algorithm 1) has a closed-form update for all $t \geq 1$ :
+
+$$
+\phi^ {t} = - \nabla F ^ {\Phi_ {0}} \left(\eta \sum_ {s = 1} ^ {t - 1} M ^ {s}\right) = - \frac {\sum_ {\phi \in \Phi_ {0}} \exp \left\{- \eta \left\langle \phi , \sum_ {s = 1} ^ {t - 1} M ^ {s} \right\rangle \right\} \phi}{\sum_ {\phi \in \Phi_ {0}} \exp \left\{- \eta \left\langle \phi , \sum_ {s = 1} ^ {t - 1} M ^ {s} \right\rangle \right\}}, \quad M ^ {t} := \ell^ {t} (\mu^ {t}) ^ {\top}. \tag {8}
+$$
+
+Eq. (8) suggests a strategy for evaluating $\phi^t = -\nabla F^{\Phi_0}(\eta \sum_{s=1}^{t-1} M^s)$ —So long as the vertex set $\Phi_0$ has some structure that allows efficient evaluation of the sum of exponentials on the numerators and denominators (i.e. faster than naive sum), $\phi^t$ may be computed directly in sublinear in $|\Phi_0|$ time, and there is no need to maintain the underlying distribution $p^t \in \Delta_{\Phi_0}$ .
+
+The following lemma enables such an efficient computation for the log-partition function $F^{\mathrm{Tr}} \coloneqq F^{\Phi^{\mathrm{Tr}}}$ (and its gradient) associated with the trigger modification set $\Phi = \Phi^{\mathrm{Tr}}$ . This lemma (proof deferred to Appendix C.3) is a consequence of the specific structure of $\Phi_0$ (cf. (5)), whose elements are indexed by a sequence $x_{g}a_{g}$ and a deterministic subtree policy $v^{x_g} \in \mathcal{V}^{x_g}$ .
+
+Lemma 3 (Recursive expression of $F^{\mathrm{Tr}}$ and $\nabla F^{\mathrm{Tr}}$ ). For any loss matrix $M \in \mathbb{R}^{XA \times XA}$ , the EFCE log-partition function can be written as
+
+$$
+F ^ {\mathbf {T r}} (M) = \log \sum_ {g, x _ {g}, a _ {g}} \exp \left\{- \left\langle I - E _ {\succeq x _ {g} a _ {g}}, M \right\rangle + F _ {x _ {g} a _ {g}, x _ {g}} (M) \right\}, \tag {9}
+$$
+
+where for any $x_{h}\succeq x_{g}$
+
+$$
+F _ {x _ {g} a _ {g}, x _ {h}} (M) := \log \sum_ {a _ {h}} \exp \left\{- M _ {x _ {h} a _ {h}, x _ {g} a _ {g}} + \sum_ {x _ {h + 1} \in \mathcal {C} \left(x _ {h}, a _ {h}\right)} F _ {x _ {g} a _ {g}, x _ {h + 1}} (M) \right\}. \tag {10}
+$$
+
+Furthermore, define $\lambda = (\lambda_{x_g a_g})_{x_g a_g \in \mathcal{X} \times \mathcal{A}} \in \Delta_{XA}$ and $m = (m_{x_g a_g})_{x_g a_g \in \mathcal{X} \times \mathcal{A}}$ with $m_{x_g a_g} \in \Pi^{x_g}$ (and also identified as a vector in $\mathbb{R}^{XA}$ ) as
+
+$$
+\lambda_ {x _ {g} a _ {g}} \propto_ {x _ {g} a _ {g}} \exp \left\{- \left\langle I - E _ {\succeq x _ {g} a _ {g}}, M \right\rangle + F _ {x _ {g} a _ {g}, x _ {g}} (M) \right\}, \tag {11}
+$$
+
+$$
+m _ {x _ {g} a _ {g}, h} \left(a _ {h} \mid x _ {h}\right) \propto_ {a _ {h}} \exp \left\{- M _ {x _ {h} a _ {h}, x _ {g} a _ {g}} + \sum_ {x _ {h + 1} \in \mathcal {C} \left(x _ {h}, a _ {h}\right)} F _ {x _ {g} a _ {g}, x _ {h + 1}} (M) \right\}, \tag {12}
+$$
+
+then we have
+
+$$
+- \nabla F ^ {\mathbf {T r}} (M) = \phi (\lambda , m) := \sum_ {g, x _ {g}, a _ {g}} \lambda_ {x _ {g} a _ {g}} \left(I - E _ {\succeq x _ {g} a _ {g}} + m _ {x _ {g} a _ {g}} e _ {x _ {g} a _ {g}} ^ {\top}\right). \tag {13}
+$$
+
+Above, $\lambda = (\lambda_{x_g a_g})_{x_g a_g \in \mathcal{X} \times \mathcal{A}} \in \Delta_{XA}$ is a probability distribution over $\mathcal{X} \times \mathcal{A}$ , and $m = (m_{x_g a_g})_{x_g a_g \in \mathcal{X} \times \mathcal{A}} \in \mathcal{M} \equiv \prod_{g, x_g a_g} \Pi^{x_g a_g}$ is a collection of subtree policies $m_{x_g a_g}$ , where each $m_{x_g a_g} \in \Pi^{x_g}$ is a subtree policy that specifies an action distribution $m_{x_g a_g, h}(a_h | x_h)$ for every $x_h \succeq x_g$ , and can be identified with a vector in $\mathbb{R}^{XA}$ (c.f. Section 2.2).
+
+The recursive structure in Lemma 3 offers a roadmap for evaluating $(\lambda, m)$ and thus $\nabla F^{\mathrm{Tr}}(M)$ in $O(X^{2}A^{2})$ time (formal statement in Appendix C.4). Applying Lemma 3 with $M = \eta \sum_{s=1}^{t-1} M^{s}$ gives an efficient implementation of (8), i.e. the $\Phi$ -Hedge algorithm with $\Phi = \Phi^{\mathrm{Tr}}$ . For clarity, we summarize this in Algorithm 2. We remark that the parameters $(\lambda^{t}, m^{t})$ therein can also be expressed in terms of $(\lambda^{t-1}, m^{t-1})$ and $M^{t-1}$ , which we present in Algorithm 4 (the equivalent "OMD" form) in Appendix C.1. We also note that the fixed point equation $\phi^{t}\mu = \mu$ in Line 5 can be solved in $O(X^{2}A^{2})$ time [23, Corollary 4.15].
+
+# 3.2 Equivalence to FTRL and OMD
+
+We now show that Algorithm 2 is equivalent to FTRL and OMD with suitable dilated entropies and divergences (hence the name EFCE-OMD). We define the trigger dilated entropy function and trigger
+
+# Algorithm 2 EFCE-OMD (FTRL form; equivalent OMD form in Algorithm 4)
+
+Require: Learning rate $\eta > 0$ .
+
+1: for $t = 1,2,\ldots ,T$ do
+2: For each $x_{g}a_{g}\in \mathcal{X}\times \mathcal{A}$ , from the reverse order of $x_{h}$ , compute $m_{x_g a_g,h}^t (a_h|x_h)$ and $F_{x_g a_g,x_h}^t$
+
+$$
+\left. m _ {x _ {g} a _ {g}, h} ^ {t} \left(a _ {h} \mid x _ {h}\right) \propto_ {a _ {h}} \exp \left\{- \eta \sum_ {s = 1} ^ {t - 1} M _ {x _ {h} a _ {h}, x _ {g} a _ {g}} ^ {s} + \sum_ {x _ {h + 1} \in \mathcal {C} \left(x _ {h}, a _ {h}\right)} F _ {x _ {g} a _ {g}, x _ {h + 1}} ^ {t} \right\}, \right. \tag {14}
+$$
+
+$$
+F _ {x _ {g} a _ {g}, x _ {h}} ^ {t} = \log \sum_ {a _ {h}} \exp \left\{- \eta \sum_ {s = 1} ^ {t - 1} M _ {x _ {h} a _ {h}, x _ {g} a _ {g}} ^ {s} + \sum_ {x _ {h + 1} \in \mathcal {C} \left(x _ {h}, a _ {h}\right)} F _ {x _ {g} a _ {g}, x _ {h + 1}} ^ {t} \right\}, \tag {15}
+$$
+
+3: Compute $\lambda_{xgag}^t$ as
+
+$$
+\lambda_ {x _ {g} a _ {g}} ^ {t} \propto_ {x _ {g} a _ {g}} \exp \left\{- \eta \left\langle I - E _ {\succeq x _ {g} a _ {g}}, \sum_ {s = 1} ^ {t - 1} M ^ {s} \right\rangle + F _ {x _ {g} a _ {g}, x _ {g}} ^ {t} \right\}. \tag {16}
+$$
+
+4: Compute $\phi^t = \phi (\lambda^t,m^t)$ where $\phi$ is in Eq. (13).
+5: Compute the policy $\mu^t$ , which is a solution of the fixed point equation $\phi^t\mu^t = \mu^t$
+6: Receive loss $\ell^t = \{\ell_h^t (x_h,a_h)\}_{(x_h,a_h)\in \mathcal{X}\times \mathcal{A}}\in \mathbb{R}_{\geq 0}^{XA}$
+7: Compute matrix loss $M^t = \ell^t (\mu^t)^\top \in \mathbb{R}_{\geq 0}^{XA\times XA}$
+
+dilated KL divergence function over $(\lambda ,m)\in \Delta_{XA}\times \mathcal{M}$ as
+
+$$
+H ^ {\mathsf {T r}} (\lambda , m) := H (\lambda) + \sum_ {g, x _ {g}, a _ {g}} \lambda_ {x _ {g} a _ {g}} H _ {x _ {g}} (m _ {x _ {g} a _ {g}}),
+$$
+
+$$
+D ^ {\operatorname {T r}} (\lambda , m \| \lambda^ {\prime}, m ^ {\prime}) := D _ {\mathrm {K L}} (\lambda \| \lambda^ {\prime}) + \sum_ {g, x _ {g}, a _ {g}} \lambda_ {x _ {g} a _ {g}} D _ {x _ {g}} (m _ {x _ {g} a _ {g}} \| m _ {x _ {g} a _ {g}} ^ {\prime}),
+$$
+
+where $H(\cdot)$ and $D_{\mathrm{KL}}(\cdot \|\cdot)$ are the (negative) Shannon entropy and KL divergence; and for any $x_g$ , $H_{x_g}(\cdot)$ is the dilated entropy, and $D_{x_g}(\cdot \|\cdot)$ is the dilated KL divergence [30], both for the subtree rooted at $x_g$ (detailed definitions in Appendix C.5).
+
+Lemma 4 (Equivalent formulations of $\Phi^{\mathrm{Tr}}$ -hedge). For any sequence of loss functions $\{M^t\}_{t\geq 1}$ , the iterates $(\lambda^t,m^t)$ in Algorithm 2 (i.e. (14)-(16)) are equivalent to (i.e. satisfy) the following FTRL update on $H^{\mathrm{Tr}}$ and OMD update on $D^{\mathrm{Tr}}$ :
+
+$$
+\left(\lambda^ {t}, m ^ {t}\right) = \arg \min _ {\lambda , m} \left[ \eta \left\langle \phi (\lambda , m), \sum_ {s = 1} ^ {t - 1} M ^ {s} \right\rangle + H ^ {\mathrm {T r}} (\lambda , m) \right], \tag {17}
+$$
+
+$$
+\left(\lambda^ {t}, m ^ {t}\right) = \arg \min _ {\lambda , m} \left[ \eta \left\langle \phi (\lambda , m), M ^ {t - 1} \right\rangle + D ^ {\operatorname {T r}} \left(\lambda , m \| \lambda^ {t - 1}, m ^ {t - 1}\right) \right]. \tag {18}
+$$
+
+The proof of Lemma 4 follows directly by the concrete forms of $(\lambda^t, m^t)$ in (14)-(16), and can be found in Appendix C.6.
+
+# 3.3 Regret bound under full feedback and bandit feedback
+
+We now present the regret bounds of Algorithm 2. We emphasize that these regret bounds are simple consequence of the generic bound for $\Phi$ -Hedge in (2), and their proofs do not depend on the actual implementation of Algorithm 2 developed in the preceding two subsections. We first consider the full feedback setting, where the full expected loss vector $\ell^t \in \mathbb{R}_{>0}^{XA}$ is received after each episode.
+
+Theorem 5 (Regret bound of EFCE-OMD under full feedback). Running Algorithm 2 with $\eta = \mathcal{O}(\sqrt{\|\Pi\|_1\iota / (H^2T)})$ achieves the following trigger regret bound
+
+$$
+\operatorname {R e g} ^ {\mathsf {T r}} (T) \leq \mathcal {O} \big (\sqrt {H ^ {2} \| \Pi \| _ {1} \iota T} \big),
+$$
+
+where $\iota \coloneqq \log (XA)$ is a log factor.
+
+The proof of Theorem 5 is simply by applying (2) and observing that $\log (\Phi_0^{\mathrm{Tr}})\leq \| \Pi \| _1\log A+$ $\log (XA)$ (see Appendix D.1). This theorem shows that the $\Phi^{\mathrm{Tr}}$ -Hedge algorithm gives $\widetilde{\mathcal{O}} (\sqrt{XT})$ trigger regret bound, which matches the information-theoretic lower bound $\Omega (\sqrt{XT})$ [48, Theorem 2] up to a $\widetilde{\mathcal{O}} (\mathrm{poly}(H))$ factor, and is slightly better than the $\widetilde{\mathcal{O}} (\sqrt{XAT})$ upper bound of [42, Corollary F.3] though their definition of EFCE-regret is slightly stricter (thus higher) than ours.
+
+# Algorithm 3 Balanced EFCE-OMD (FTRL form; equivalent OMD form in Algorithm 5)
+
+Require: Learning rate $\eta$ , balanced exploration policy $\{\mu^{\star,h}\}_{h\in [H]}$ .
+
+1: for $t = 1,2,\ldots ,T$ do
+2: For each $x_{g}a_{g}\in \mathcal{X}\times \mathcal{A}$ , from the reverse order of $x_{h}$ , compute $m_{x_g a_g,h}^t (a_h|x_h)$ and $F_{x_g a_g,x_h}^{\star ,t}$
+
+$$
+m _ {x _ {g} a _ {g}, h} ^ {t} \left(a _ {h} \mid x _ {h}\right) \propto_ {a _ {h}} \exp \left\{\mu_ {g: h} ^ {\star , h} \left(x _ {h}, a _ {h}\right) \Big (- \eta \sum_ {s = 1} ^ {t - 1} \widetilde {M} _ {x _ {h} a _ {h}, x _ {g} a _ {g}} ^ {s} + \sum_ {x _ {h + 1} \in \mathcal {C} \left(x _ {h}, a _ {h}\right)} F _ {x _ {g} a _ {g}, x _ {h + 1}} ^ {\star , t} \Big) \right\},
+$$
+
+$$
+\begin{array}{l} F _ {x _ {g} a _ {g}, x _ {h}} ^ {\star , t} := \frac {1}{\mu_ {g : h} ^ {\star , h} (x _ {h} , a _ {h})} \log \sum_ {a _ {h} \in \mathcal {A}} \exp \left\{\mu_ {g: h} ^ {\star , h} (x _ {h}, a _ {h}) \right. \\ \times \left[ - \eta \sum_ {s = 1} ^ {t} \widetilde {M} _ {x _ {h} a _ {h}, x _ {g} a _ {g}} ^ {s} + \sum_ {x _ {h + 1} \in \mathcal {C} (x _ {h} a _ {h})} F _ {x _ {g} a _ {g}, x _ {h + 1}} ^ {\star , t} \right] \Big \}. \\ \end{array}
+$$
+
+3: Compute $\lambda_{x_g a_g}^{t + 1}$ as
+
+$$
+\lambda_ {x _ {g} a _ {g}} ^ {t} \propto_ {x _ {g} a _ {g}} \exp \left\{\frac {1}{X A} \left(- \eta \langle I - E _ {\succeq x _ {g} a _ {g}}, \sum_ {s = 1} ^ {t - 1} \widetilde {M} ^ {s} \rangle + F _ {x _ {g} a _ {g}, x _ {g}} ^ {\star , t}\right) \right\}. \tag {20}
+$$
+
+4: Compute $\phi^t = \phi (\lambda^t,m^t)$ , where $\phi$ is as defined in Eq. (13).
+5: Find a $\mu^t$ to be a solution of the fixed point equation $\mu^t = \phi^t\mu^t$
+6: Play policy $\mu^t$ , observe trajectory $(x_h^t, a_h^t, r_h^t)_{h \in [H]}$ .
+7: Form vector loss estimator $\widetilde{\ell}^{t,x_{g}a_{g}} = \{\widetilde{\ell}_{h}^{t,x_{g}a_{g}}(x_{h},a_{h})\}_{x_{h}a_{h}}$ for each $(g,x_{g}a_{g})$ as in Eq. (23).
+8: Compute matrix loss estimator $\widetilde{M}^t = \sum_{g,x_g,a_g}\mu_{x_ga_g}^t\widetilde{\ell}^{t,x_ga_g}e_{x_ga_g}^\top$
+
+In the bandit feedback setting, the learner only observes her own rewards and infosets. In this case we replace $\ell^t$ in Algorithm 2 with the following loss estimator (with IX bonus $\gamma$ ) proposed in [34]:
+
+$$
+\widetilde {\ell} _ {h} ^ {t} \left(x _ {h}, a _ {h}\right) := 1 \left\{\left(x _ {h} ^ {t}, a _ {h} ^ {t}\right) = \left(x _ {h}, a _ {h}\right) \right\} \left(1 - r _ {h} ^ {t}\right) / \left(\mu_ {1: h} ^ {t} \left(x _ {h}, a _ {h}\right) + \gamma\right). \tag {19}
+$$
+
+We show that EFCE-OMD achieves the following guarantee in the bandit feedback setting (proof in Appendix D.2). The proof follows by plugging the loss estimator $\widetilde{\ell}^t$ into (2) and additionally bounding concentrations (which we remark is a better strategy than using a naive bandit-based loss estimator in the corresponding NFG space).
+
+Theorem 6 (Regret bound of EFCE-OMD under bandit feedback). Run Algorithm 2 with loss estimator $\{\widetilde{\ell}^t\}_{t=1}^T$ (19), $\eta = \sqrt{\|\Pi\|_1 \log A / (HXAT)}$ , and $\gamma = \sqrt{\|\Pi\|_1 \iota / (XAT)}$ . Then we have the following trigger regret bound with probability at least $1 - \delta$ :
+
+$$
+\operatorname {R e g} ^ {\mathsf {T r}} (T) \leq \mathcal {O} \big (\sqrt {H X A \| \Pi \| _ {1} \iota \cdot T} \big),
+$$
+
+where $\iota = \log (3XA / \delta)$ is a log term.
+
+To our best knowledge, Theorem 6 gives the first trigger regret bound against adversarial opponents and bandit feedback. This $\widetilde{\mathcal{O}} (\sqrt{XA\|\Pi\|_1T})$ rate is $\sqrt{XA}$ worse than Theorem 5 (ignoring $H$ and log factors), and is at most $\widetilde{\mathcal{O}} (\sqrt{X^2AT})$ using $\| \Pi \| _1\leq X$ .
+
+# 4 Balanced EFCE-OMD for bandit feedback
+
+We now build upon the EFCE-OMD algorithm (Algorithm 2) to develop a new algorithm, Balanced EFCE-OMD (Algorithm 3), and show that it achieves near-optimal extensive-form trigger regret guarantee under bandit feedback. Here we discuss the two key modifications in the algorithm design.
+
+Key modification I: "Rebalancing" the log-partition function Building on the balancing technique of [6], we start from Eq. (9) and (10) of the log partition function, and rescale the inner functions $F_{x_g a_g, x_h}$ using balanced exploration policies $\{\mu_{g:h}^{\star, h}(x_h, a_h)\}_{g, x_h, a_h}$ (see Definition E.1
+
+for the formal definition), and rescale the outer function $F^{\mathrm{Tr}}$ by $X A$ . Concretely, for any matrix $M \in \mathbb{R}^{XA \times XA}$ , we define the balanced EFCE log-partition function as
+
+$$
+F _ {\mathrm {b a l}} ^ {\mathrm {T r}} (M) := X A \log \sum_ {g, x _ {g}, a _ {g}} \exp \left\{\frac {1}{X A} \left[ - \left\langle I - E _ {\succeq x _ {g} a _ {g}}, M \right\rangle + F _ {x _ {g} a _ {g}, x _ {g}} ^ {\star} (M) \right] \right\}, \tag {21}
+$$
+
+where for any $x_{h} \succeq x_{g}$ (using $\mu_{g:h}^{\star,h} \coloneqq \mu_{g:h}^{\star,h}(x_{h}, a_{h})$ as shorthand, which depends on $x_{h}$ but not $a_{h}$ ),
+
+$$
+F _ {x _ {g} a _ {g}, x _ {h}} ^ {\star} (M) := \frac {1}{\mu_ {g : h} ^ {\star , h}} \log \sum_ {a _ {h}} \exp \left\{\mu_ {g: h} ^ {\star , h} \left[ - M _ {x _ {h} a _ {h}, x _ {g} a _ {g}} + \sum_ {x _ {h + 1} \in \mathcal {C} \left(x _ {h} a _ {h}\right)} F _ {x _ {g} a _ {g}, x _ {h + 1}} ^ {\star} (M) \right] \right\}. \tag {22}
+$$
+
+Key modification II: New loss estimator under bandit feedback We use an adaptive family of bandit-based loss estimators $\{\widetilde{\ell}^{t,x_ga_g}\}_{x_ga_g} \subset \mathbb{R}_{\geq 0}^{XA}$ , one for each $(x_{g},a_{g}) \in \mathcal{X} \times \mathcal{A}$ , defined as
+
+$$
+\widetilde {\ell} _ {h} ^ {t, x _ {g} a _ {g}} \left(x _ {h}, a _ {h}\right) := \frac {\mathbf {1} \left\{\left(x _ {h} ^ {t} , a _ {h} ^ {t}\right) = \left(x _ {h} , a _ {h}\right) \right\} \left(1 - r _ {h} ^ {t}\right)}{\mu_ {1 : h} ^ {t} \left(x _ {h} , a _ {h}\right) + \gamma \left(\mu_ {1 : h} ^ {\star , h} \left(x _ {h} , a _ {h}\right) + \mu_ {x _ {g} a _ {g}} ^ {t} m _ {x _ {g} a _ {g} , g : h} ^ {t} \left(x _ {h} , a _ {h}\right) \mathbf {1} \left\{x _ {h} \succeq x _ {g} \right\}\right)}, \tag {23}
+$$
+
+where $\mu_{x_ga_g}^t \coloneqq \mu_{1:g}^t(x_g, a_g)$ for shorthand. The main difference of (23) over (19) is in the adaptive IX bonus term on the denominator that scales with $\gamma$ but is different for each $x_ga_g$ . We then place each $\mu_{x_ga_g}^t \widetilde{\ell}^{t,x_ga_g}$ into the $x_ga_g$ -th column of a matrix loss estimator $\widetilde{M}^t$ , or in matrix form,
+
+$$
+\widetilde {M} ^ {t} := \sum_ {g, x _ {g}, a _ {g}} \mu_ {x _ {g} a _ {g}} ^ {t} \widetilde {\ell} ^ {t, x _ {g} a _ {g}} e _ {x _ {g} a _ {g}} ^ {\top}.
+$$
+
+With (21)-(23) at hand, our algorithm Balanced EFCE-OMD is defined as the negative gradient of $F_{\mathrm{bal}}^{\mathrm{Tr}}$ evaluated at the cumulative loss estimators:
+
+$$
+\phi^ {t} = - \nabla F _ {\mathsf {b a l}} ^ {\mathsf {T r}} \left(\eta \sum_ {s = 1} ^ {t - 1} \widetilde {M} ^ {s}\right), \quad \forall t \geq 1, \tag {24}
+$$
+
+and $\mu^t\in \Pi$ solves the fixed point equation $\phi^t\mu^t = \mu^t$ . Similar as EFCE-OMD, (24) also admits efficient implementations in both FTRL and OMD form (cf. Algorithm 3 & 5). The corresponding $(\lambda^t,m^t)$ is also equivalent to running a FTRL/OMD algorithm with respect to a balanced dilated entropy/KL-divergence over $\phi \in \Phi^{\mathrm{Tr}}$ (cf. Lemma E.4 and Appendix E.3 for details).
+
+Main result We now present the theoretical guarantee of Algorithm 3 (proof in Appendix F).
+
+Theorem 7. Balanced EFCE-OMD (Algorithm 3) with $\eta = \sqrt{XA\iota / H^4T}$ and $\gamma = 2\sqrt{XA\iota / H^2T}$ achieves the following extensive-form trigger regret bound with probability at least $1 - \delta$ :
+
+$$
+\operatorname {R e g} ^ {\operatorname {T r}} (T) \leq \mathcal {O} \left(\sqrt {H ^ {4} X A T \iota}\right),
+$$
+
+where $\iota = \log (10XA / \delta)$ is a log term.
+
+The $\widetilde{\mathcal{O}} (\sqrt{XAT})$ trigger regret asserted in Theorem 7 improves over Theorem 6 by a factor of $\sqrt{\|\Pi\|_1}$ and matches the information-theoretic lower bound up to $\mathrm{poly}(H)$ and log factors. By the online-to-batch conversion (Appendix B.2), Theorem 7 also implies an $\widetilde{\mathcal{O}} (H^4 X A / \varepsilon^2)$ sample complexity for learning EFCE under bandit feedback (assuming same game sizes for all $m$ players). This improves over the best known $\widetilde{\mathcal{O}} (mH^{6}XA^{2} / \varepsilon^{2})$ sample complexity in the recent work of Song et al. [42]3.
+
+Overview of techniques The proof of Theorem 7 is significantly more challenging than that of Theorem 6, even though the algorithm itself is designed by appearingly simple modifications. This happens since Algorithm 3, unlike Algorithm 2, no longer necessarily corresponds to any normal-form algorithm. The technical crux of the proof is to bound the nonlinear part of $F_{\mathrm{bal}}^{\mathrm{Tr}}$ (with respect to the losses), which we do by carefully controlling a series of second-order terms utilizing the balanced policies within $F_{\mathrm{bal}}^{\mathrm{Tr}}$ and the new adaptive IX bonus within $\{\widetilde{\ell}^{t,x_{g}a_{g}}\}_{x_{g}a_{g}}$ (Lemma F.5-F.8).
+
+# 5 Equivalence of OMD and Vertex MWU for external regret minimization
+
+As another illustration of our framework, we now choose $\Phi = \Phi^{\mathrm{ext}} = \mathrm{conv}\{\Phi_0^{\mathrm{ext}}\}$ to be the set of external policy modifications, which modify any policy to some deterministic policy. In this case, the $\Phi^{\mathrm{ext}}$ -Hedge algorithm minimizes the external regret in EFGs. In this section, we show that $\Phi^{\mathrm{ext}}$ -Hedge, same as the vertex MWU algorithm considered in Farina et al. [25], is actually equivalent to the OMD with dilated entropy [30]. Let $\{\ell^t\}_{t\geq 1} \subset \mathbb{R}_{\geq 0}^{XA}$ be an arbitrary sequence of loss vectors.
+
+Vertex MWU We use $\mathcal{V}$ to denote all the deterministic sequence-form policies, which can also be viewed as the vertex set of the policy set $\Pi$ . A simple reformulation (cf. Appendix G) shows that $\Phi^{\mathrm{ext}}$ -Hedge (Algorithm 1) gives the vertex MWU algorithm considered by Farina et al. [25]
+
+$$
+\mu^ {t} = \sum_ {v \in \mathcal {V}} p _ {v} ^ {t} \cdot v \quad \text {a n d} \quad p _ {v} ^ {t} \propto_ {v} \exp \left\{- \eta \left\langle v, \sum_ {s = 1} ^ {t - 1} \ell^ {s} \right\rangle \right\}. \tag {25}
+$$
+
+OMD with dilated entropy Another popular algorithm for external regret minimization is the OMD algorithm on the sequence-form policy space with the dilated entropy [30, 35]:
+
+$$
+\mu^ {t} = \underset {\mu \in \Pi} {\arg \min } \left[ \eta \left\langle \mu , \ell^ {t - 1} \right\rangle + D _ {\emptyset} (\mu \| \mu^ {t - 1}) \right], \tag {26}
+$$
+
+$$
+D _ {\emptyset} (\mu \| \nu) := \sum_ {h = 1} ^ {H} \sum_ {x _ {h}, a _ {h}} \mu_ {1: h} \left(x _ {h}, a _ {h}\right) \log \frac {\mu_ {h} \left(a _ {h} \mid x _ {h}\right)}{\nu_ {h} \left(a _ {h} \mid x _ {h}\right)}. \tag {27}
+$$
+
+Theorem 8 (Equivalence of OMD and Vertex MWU). For any sequence of loss vectors $\{\ell^t\}_{t\geq 1}$ , OMD with dilated entropy is equivalent to Vertex MWU, that is, (26) and (25) give the same $\{\mu^t\}_{t\geq 1}$ .
+
+The proof of Theorem 8 can be found in Appendix G.1. Our proof also reveals that the efficient implementation of Vertex MWU developed by Farina et al. [25] using the "kernel trick" is actually equivalent to the standard linear-time efficient implementation of OMD with dilated entropy.
+
+# 6 Conclusion
+
+In this paper, we present an efficient implementation of the $\Phi$ -Hedge algorithm for minimizing the extensive form trigger regret. The algorithm is equivalent to OMD with dilated regularizers, and achieves efficient regret bounds under both full feedback and bandit feedback. We also design an improved algorithm Balanced EFCE-OMD, which achieves a sharp trigger regret bound under bandit feedback. We believe our work leads to many open questions, such as efficient implementations of $\Phi$ -Hedge with more general $\Phi$ sets (e.g. the behavioral modifications considered in [38, 42]), or accelerated polylog(T) $\Phi$ -regret bounds under full feedback by optimistic algorithms.
+
+# Acknowledgment
+
+S.M. is supported by NSF grant DMS-2210827. C.J. is supported by Office of Naval Research N00014-22-1-2253. T.Y. is supported by NSF CCF-2112665 (TILOS AI Research Institute).
+
+# References
+
+[1] A. Agarwal, D. Hsu, S. Kale, J. Langford, L. Li, and R. Schapire. Taming the monster: A fast and simple algorithm for contextual bandits. In International Conference on Machine Learning, pages 1638-1646. PMLR, 2014.
+[2] I. Anagnostides, C. Daskalakis, G. Farina, M. Fishelson, N. Golowich, and T. Sandholm. Near-optimal no-regret learning for correlated equilibria in multi-player general-sum games. arXiv preprint arXiv:2111.06008, 2021.
+[3] I. Anagnostides, G. Farina, C. Kroer, C.-W. Lee, H. Luo, and T. Sandholm. Uncoupled learning dynamics with $o(logt)$ swap regret in multiplayer games. arXiv preprint arXiv:2204.11417, 2022.
+
+[4] S. Arora, E. Hazan, and S. Kale. The multiplicative weights update method: a meta-algorithm and applications. Theory of computing, 8(1):121-164, 2012.
+[5] R. J. Aumann. Subjectivity and correlation in randomized strategies. Journal of mathematical Economics, 1(1):67-96, 1974.
+[6] Y. Bai, C. Jin, S. Mei, and T. Yu. Near-optimal learning of extensive-form games with imperfect information. arXiv preprint arXiv:2202.01752, 2022.
+[7] A. Bakhtin, D. Wu, A. Lerer, and N. Brown. No-press diplomacy from scratch. Advances in Neural Information Processing Systems, 34, 2021.
+[8] A. Blum and Y. Mansour. From external to internal regret. Journal of Machine Learning Research, 8(6), 2007.
+[9] N. Brown and T. Sandholm. Superhuman ai for heads-up no-limit poker: Libratus beats top professionals. Science, 359(6374):418-424, 2018.
+[10] N. Brown and T. Sandholm. Superhuman ai for multiplayer poker. Science, 365(6456):885-890, 2019.
+[11] N. Burch, M. Moravcik, and M. Schmid. Revisiting cfr+ and alternating updates. Journal of Artificial Intelligence Research, 64:429-443, 2019.
+[12] A. Celli, A. Marchesi, T. Bianchi, and N. Gatti. Learning to correlate in multi-player general-sum sequential games. Advances in Neural Information Processing Systems, 32, 2019.
+[13] A. Celli, A. Marchesi, G. Farina, and N. Gatti. No-regret learning dynamics for extensive-form correlated equilibrium. Advances in Neural Information Processing Systems, 33:7722-7732, 2020.
+[14] N. Cesa-Bianchi and G. Lugosi. Prediction, learning, and games. Cambridge university press, 2006.
+[15] C. Daskalakis, P. W. Goldberg, and C. H. Papadimitriou. The complexity of computing a nash equilibrium. SIAM Journal on Computing, 39(1):195-259, 2009.
+[16] C. Daskalakis, M. Fishelson, and N. Golowich. Near-optimal no-regret learning in general games. Advances in Neural Information Processing Systems, 34, 2021.
+[17] M. Dudik and G. Gordon. A sampling-based approach to computing equilibria in succinct extensive-form games. arXiv preprint arXiv:1205.2649, 2012.
+[18] M. Dudík and G. J. Gordon. A sampling-based approach to computing equilibria in succinct extensive-form games. In Proceedings of the Twenty-Fifth Conference on Uncertainty in Artificial Intelligence, pages 151-160, 2009.
+[19] G. Farina and T. Sandholm. Model-free online learning in unknown sequential decision making problems and games. arXiv preprint arXiv:2103.04539, 2021.
+[20] G. Farina, C. K. Ling, F. Fang, and T. Sandholm. Correlation in extensive-form games: Saddle-point formulation and benchmarks. Advances in Neural Information Processing Systems, 32, 2019.
+[21] G. Farina, C. Kroer, and T. Sandholm. Faster game solving via predictive blackwell approachability: Connecting regret matching and mirror descent. arXiv preprint arXiv:2007.14358, 2020.
+[22] G. Farina, C. Kroer, and T. Sandholm. Stochastic regret minimization in extensive-form games. In International Conference on Machine Learning, pages 3018-3028. PMLR, 2020.
+[23] G. Farina, A. Celli, A. Marchesi, and N. Gatti. Simple uncoupled no-regret learning dynamics for extensive-form correlated equilibrium. arXiv preprint arXiv:2104.01520, 2021.
+
+[24] G. Farina, R. Schmucker, and T. Sandholm. Bandit linear optimization for sequential decision making and extensive-form games. arXiv preprint arXiv:2103.04546, 2021.
+[25] G. Farina, C.-W. Lee, H. Luo, and C. Kroer. Kernelized multiplicative weights for 0/1-polyhedral games: Bridging the gap between learning in extensive-form and normal-form games. arXiv preprint arXiv:2202.00237, 2022.
+[26] D. P. Foster and R. V. Vohra. Asymptotic calibration. Biometrika, 85(2):379-390, 1998.
+[27] G. J. Gordon, A. Greenwald, and C. Marks. No-regret learning in convex games. In Proceedings of the 25th international conference on Machine learning, pages 360-367, 2008.
+[28] A. Greenwald and A. Jafari. A general class of no-regret learning algorithms and game-theoretic equilibria. In Learning theory and kernel machines, pages 2-12. Springer, 2003.
+[29] P. A. Herbig. Game theory in marketing: Applications, uses and limits. Journal of Marketing Management, 7(3):285-298, 1991.
+[30] S. Hoda, A. Gilpin, J. Pena, and T. Sandholm. Smoothing techniques for computing nash equilibria of sequential games. Mathematics of Operations Research, 35(2):494-512, 2010.
+[31] W. Huang and B. von Stengel. Computing an extensive-form correlated equilibrium in polynomial time. In International Workshop on Internet and Network Economics, pages 506-513. Springer, 2008.
+[32] V. Kakkad, H. Shah, R. Patel, and N. Doshi. A comparative study of applications of game theory in cyber security and cloud computing. Procedia Computer Science, 155:680-685, 2019.
+[33] S. Khot and A. K. Ponnuswami. Minimizing wide range regret with time selection functions. In $COLT$ , pages 81-86, 2008.
+[34] T. Kozuno, P. Ménard, R. Munos, and M. Valko. Model-free learning for two-player zero-sum partially observable markov games with perfect recall. arXiv preprint arXiv:2106.06279, 2021.
+[35] C. Kroer, K. Waugh, F. Kilinç-Karzan, and T. Sandholm. Faster first-order methods for extensive-form game solving. In Proceedings of the Sixteenth ACM Conference on Economics and Computation, pages 817-834, 2015.
+[36] M. Lanctot, K. Waugh, M. Zinkevich, and M. H. Bowling. Monte carlo sampling for regret minimization in extensive games. In NIPS, pages 1078-1086, 2009.
+[37] T. Lattimore and C. Szepesvári. Bandit algorithms. Cambridge University Press, 2020.
+[38] D. Morrill, R. D'Orazio, M. Lanctot, J. R. Wright, M. Bowling, and A. R. Greenwald. Efficient deviation types and learning for hindsight rationality in extensive-form games. In International Conference on Machine Learning, pages 7818-7828. PMLR, 2021.
+[39] R. B. Myerson. Optimal auction design. Mathematics of operations research, 6(1):58-73, 1981.
+[40] J. F. Nash. Equilibrium points in n-person games. Proceedings of the National Academy of Sciences of the United States of America, 36(1):48-49, 1950.
+[41] M. Schmid, M. Moravecik, N. Burch, R. Kadlec, J. Davidson, K. Waugh, N. Bard, F. Timbers, M. Lanctot, Z. Holland, et al. Player of games. arXiv preprint arXiv:2112.03178, 2021.
+[42] Z. Song, S. Mei, and Y. Bai. Sample-efficient learning of correlated equilibria in extensive-form games. arXiv preprint arXiv:2205.07223, 2022.
+[43] G. Stoltz and G. Lugosi. Internal regret in on-line portfolio selection. Machine Learning, 59(1): 125-159, 2005.
+[44] G. Stoltz and G. Lugosi. Learning correlated equilibria in games with compact sets of strategies. Games and Economic Behavior, 59(1):187-208, 2007.
+[45] Y. Tian, Q. Gong, and T. Jiang. Joint policy search for multi-agent collaboration with imperfect information. arXiv preprint arXiv:2008.06495, 2020.
+
+[46] B. Von Stengel and F. Forges. Extensive-form correlated equilibrium: Definition and computational complexity. Mathematics of Operations Research, 33(4):1002-1022, 2008.
+[47] B. H. Zhang and T. Sandholm. Finding and certifying (near-) optimal strategies in black-box extensive-form games. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pages 5779-5788, 2021.
+[48] Y. Zhou, T. Ren, J. Li, D. Yan, and J. Zhu. Lazy-cfr: fast and near optimal regret minimization for extensive games with imperfect information. arXiv preprint arXiv:1810.04433, 2018.
+[49] Y. Zhou, J. Li, and J. Zhu. Posterior sampling for multi-agent reinforcement learning: solving extensive games with imperfect information. In International Conference on Learning Representations, 2019.
+[50] Y. Zhou, T. Ren, J. Li, D. Yan, and J. Zhu. Lazy-cfr: fast and near-optimal regret minimization for extensive games with imperfect information. In International Conference on Learning Representations, 2020. URL https://openreview.net/forum?id=rJx4p3NYDB.
+[51] M. Zinkevich, M. Johanson, M. Bowling, and C. Piccione. Regret minimization in games with incomplete information. Advances in neural information processing systems, 20:1729-1736, 2007.
\ No newline at end of file
diff --git a/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/images.zip b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..dde65be7a9306065942fef4f8de82ca1d10de10c
--- /dev/null
+++ b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:42d390c7555f6bb93b3a074164fbd05bfbd310e8937ff51c2383637961bf9509
+size 303957
diff --git a/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/layout.json b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..07808bc80af9ef7729266e1e6e47d3a82af35c9c
--- /dev/null
+++ b/efficientphiregretminimizationinextensiveformgamesviaonlinemirrordescent/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e23d65ba5c0f0f0e308a2910a1751a81c0d4dad5e33f5339d298a809a2e7b22b
+size 714388
diff --git a/efficientriskaversereinforcementlearning/e7ac50ce-2e35-44a4-b25e-8ccc5e05ff4d_content_list.json b/efficientriskaversereinforcementlearning/e7ac50ce-2e35-44a4-b25e-8ccc5e05ff4d_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..d460b43d68cda7b92e8f408c429b2d67ff41af25
--- /dev/null
+++ b/efficientriskaversereinforcementlearning/e7ac50ce-2e35-44a4-b25e-8ccc5e05ff4d_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:364193626dcda66beed190e374a7b54e28998a20f66a29b15525f0b80bc61b73
+size 93823
diff --git a/efficientriskaversereinforcementlearning/e7ac50ce-2e35-44a4-b25e-8ccc5e05ff4d_model.json b/efficientriskaversereinforcementlearning/e7ac50ce-2e35-44a4-b25e-8ccc5e05ff4d_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..5079dd512565013b5bd56b357216ce7b94b19a55
--- /dev/null
+++ b/efficientriskaversereinforcementlearning/e7ac50ce-2e35-44a4-b25e-8ccc5e05ff4d_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:87e4a0cc253aa90c95e63b7865e43cc53b6a2f1b74dcb3a8a0ac2108d72b2587
+size 121209
diff --git a/efficientriskaversereinforcementlearning/e7ac50ce-2e35-44a4-b25e-8ccc5e05ff4d_origin.pdf b/efficientriskaversereinforcementlearning/e7ac50ce-2e35-44a4-b25e-8ccc5e05ff4d_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..37d3fa3624b20e912a047b5ed110f70563564fef
--- /dev/null
+++ b/efficientriskaversereinforcementlearning/e7ac50ce-2e35-44a4-b25e-8ccc5e05ff4d_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b0a1dfd14b95f511dfcf8942a8c51074905305cce2cdde82d1f9cd38ea015ed5
+size 610425
diff --git a/efficientriskaversereinforcementlearning/full.md b/efficientriskaversereinforcementlearning/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..b40e36c69b9f7bd0685b28bbb7345234c7bf54f8
--- /dev/null
+++ b/efficientriskaversereinforcementlearning/full.md
@@ -0,0 +1,387 @@
+# Efficient Risk-Averse Reinforcement Learning
+
+Ido Greenberg
+
+Technion
+
+gido@campus.technion.ac.il
+
+Yinlam Chow
+
+Google Research
+
+yinlamchow@google.com
+
+Mohammad Ghavamzadeh
+
+Google Research
+
+ghavamza@google.com
+
+Shie Mannor
+
+Technion, Nvidia Research
+
+shie@ee.technion.ac.il
+
+# Abstract
+
+In risk-averse reinforcement learning (RL), the goal is to optimize some risk measure of the returns. A risk measure often focuses on the worst returns out of the agent's experience. As a result, standard methods for risk-averse RL often ignore high-return strategies. We prove that under certain conditions this inevitably leads to a local-optimum barrier, and propose a mechanism we call soft risk to bypass it. We also devise a novel cross entropy module for sampling, which (1) preserves risk aversion despite the soft risk; (2) independently improves sample efficiency. By separating the risk aversion of the sampler and the optimizer, we can sample episodes with poor conditions, yet optimize with respect to successful strategies. We combine these two concepts in CeSoR - Cross-entropy Soft-Risk optimization algorithm - which can be applied on top of any risk-averse policy gradient (PG) method. We demonstrate improved risk aversion in maze navigation, autonomous driving, and resource allocation benchmarks, including in scenarios where standard risk-averse PG completely fails. Our results and CeSoR implementation are available on Github. The stand-alone cross entropy module is available on PyPI.
+
+# 1 Introduction
+
+Risk-averse reinforcement learning (RL) is important for high-stake applications, such as driving, robotic surgery, and finance [Vittori et al., 2020]. In contrast to risk-neutral RL, it optimizes a risk measure of the return random variable, rather than its expectation. A popular risk measure is the Conditional Value at Risk (CVaR), defined as $\mathrm{CVaR}_{\alpha}(R) = \mathbb{E}[R|R \leq q_{\alpha}(R)]$ , where $q_{\alpha}(R) = \inf \{x \mid F_R(x) \geq \alpha\}$ is the $\alpha$ -quantile of the random variable $R$ and $F_R$ is its CDF. Intuitively, CVaR measures the expected return below a specific quantile $\alpha$ , also termed the risk level. CVaR optimization is widely researched in the RL community, e.g., using adjusted policy gradient approaches (CVaR-PG) [Tamar et al., 2015b, Hiraoka et al., 2019]. In addition, CVaR is a coherent risk measure, and its optimization is equivalent to a robust optimization problem [Chow et al., 2015].
+
+Since risk-averse RL aims to avoid the hazardous parts of the environment (e.g., dangerous areas in navigation), CVaR-PG algorithms typically sample a batch of $N$ trajectories (episodes), and then optimize w.r.t. the mean of the $\alpha N$ trajectories with worst returns [Tamar et al., 2015b, Rajeswaran et al., 2017]. This approach suffers from two major drawbacks: (i) $1 - \alpha$ of the batch is wasted and excluded from the optimization (where often $0.01 \leq \alpha \leq 0.05$ ), leading to sample inefficiency; (ii) focusing on the worst episodes inherently overlooks good agent strategies corresponding to high returns – a phenomenon we refer to as the blindness to success.
+
+An illustrative example – the Guarded Maze: Consider the Guarded Maze benchmark (visualized in Figure 1d). The goal is to reach the target zone (a constant location marked in green), resulting in
+
+
+(a) Guarded Maze
+
+
+(b) Driving Game
+
+
+(c) Servers Allocation
+
+
+(d) CeSoR learns to avoid the risk (red) and take the long path to the target (green), whereas GCVaR fails due to blindness to success.
+
+
+(e) CeSoR maintains a safe margin from the leader, while PG has an accident and GCVaR maintains a too conservative distance.
+
+
+(f) CeSoR handles the exceptional peak in user-requests without paying for as many servers as GCVaR, while PG fails to handle the peak.
+Figure 1: Over 3 benchmarks, test results of 3 agents: risk-neutral PG, standard CVaR-PG (GCVaR, Tamar et al. [2015b]), and our CeSoR. Top: the lower quantiles of the returns distributions. Bottom: sample episodes.
+
+a reward of 16 points. However, the guarded zone (in red) may be watched by a guard who demands a payment from any agent that passes by. Every episode, the probability that a guard is present is $\phi_1 = 20\%$ , and the payment is exponentially-distributed with average $\phi_2 = 32$ . That is, the cost of crossing the guarded zone in a certain episode is $C = C_1 \cdot C_2$ , where $C_1 \sim \text{Ber}(\phi_1)$ , $C_2 \sim \text{Exp}(\phi_2)$ are independent and unknown to the agent. The agent starts at a random point at the lower half, and every time-step, observing its location, it selects an action: left, right, up or down, with an additive control noise. One point is deducted per step, up to 32 deductions.
+
+In this maze, the shortest path maximizes the average return; yet, the longer path is CVaR-optimal, since sometimes short cuts make long delays [Tolkien, 1954]. However, the standard CVaR-PG optimizer (GCVaR in Figure 1) suffers from blindness to success: in a batch of $N$ random episodes, the worst $\alpha N$ returns (e.g., for $\alpha = 5\%$ ) usually correspond to either encountering a guard in the short path, or not reaching the goal at all. Hence, the desired long path is never even observed by the CVaR-PG optimizer, and cannot be learned.
+
+Our key insight is that the variation in returns comes from both environment conditions (epistemic uncertainty) and agent actions (aleatoric uncertainty). We wish to focus on the low quantiles w.r.t. the conditions (e.g., a costly guard in the short path of the maze), yet to be exposed to the high quantiles w.r.t. the strategies (e.g., taking the long path in the maze). To that end, we devise two mechanisms: first, we use a soft risk-level scheduling method, which begins the training with risk neutrality $\alpha' = 1$ , and gradually shifts the risk aversion to $\alpha' = \alpha$ . Second, we present a novel dynamic-target version of the Cross Entropy method (CE or CEM) [de Boer et al., 2005], aiming to sample the worst parts of the environment. That is, the CEM samples trajectories with more challenging or riskier conditions, and the soft risk feeds a larger part of them ( $\alpha' \geq \alpha$ ) to the CVaR-PG optimizer. Together, these constitute the Cross-entropy method for Soft-Risk optimization ( $CeSoR$ ). CeSoR can be applied on top of any CVaR-PG method to learn any differentiable model (e.g., a neural network).
+
+To apply the CEM, we assume to have certain control over the environment conditions. For example, in driving we may choose the roads for collecting training data, or in any simulation we may control the environment parameters (e.g., $\phi_1, \phi_2$ in the Guarded Maze). Note that (i) only the CE sampler (not the agent) is aware of the conditions; (ii) their underlying effect is unknown to the sampler and may vary with the agent throughout the training, hence the CEM needs to learn it adaptively.
+
+Contribution: We present the following contribution for PG algorithms under risk-sensitive MDP problems (as defined in Section 2):
+
+1. We analyze the phenomenon of blindness to success in the standard CVaR-PG, and show that it leads to a local-optimum barrier in certain environments (Section 3.1).
+2. We analyze the potential increase in sample efficiency – if we could sample directly from the tail of the returns distribution (Section 3.2).
+3. We introduce the CeSoR algorithm (Section 4), which modifies any CVaR-PG method with: (i) a soft risk mechanism preventing blindness to success; (ii) a novel dynamic-CE method that over-samples the riskier realizations of the environment, increasing sample efficiency.
+4. We demonstrate the effectiveness of CeSoR in 3 risk-sensitive domains (Section 5), where it learns faster and achieves higher returns (both CVaR and mean) than the baseline CVaR-PG.
+
+# 1.1 Related Work
+
+Optimizing risk in RL is crucial to enforce safety in decision-making [García and Fernández, 2015, Paduraru et al., 2021]. It has been long studied through various risk criteria, e.g., mean-variance [Sato et al., 2001, Prashanth and Ghavamzadeh, 2013, 2016, Xie et al., 2018], entropic risk measure [Borkar and Meyn, 2002, Borkar and Jain, 2014, Fei et al., 2021] and distortion risk measures [Vijayan and Prashanth, 2021]. Tamar et al. [2015a] derived a PG method for general coherent risk measures, given their risk-envelope representation.
+
+The CVaR risk measure specifically was studied using value iteration [Chow et al., 2015] and distributional RL [Dabney et al., 2018a, Tang et al., 2019, Bodnar et al., 2020] (also discussed in Appendix H). CVaR optimization was also shown equivalent to mean optimization under robustness [Chow et al., 2015], motivating robust-RL methods [Pinto et al., 2017, Godbout et al., 2021]. Yet, PG remains the most popular approach for CVaR optimization in RL [Tamar et al., 2015b, Rajeswaran et al., 2017, Hiraoka et al., 2019, Huang et al., 2021b], and can be flexibly applied to a variety of use-cases, e.g., mixed mean-CVaR criteria [Chow and Ghavamzadeh, 2014] and multi-agent problems [Qiu et al., 2021].
+
+Optimizing the CVaR for risk levels $\alpha \ll 1$ poses a significant sample efficiency challenge, as only a small portion of the agent's experience is used to optimize its policy [Curi et al., 2020]. Keramati et al. [2020] used an exploration-based approach to address the sample efficiency. Pessimistic sampling for improved sample efficiency was suggested heuristically by Tamar et al. [2015b] using a dedicated value function, but no systematic method was suggested to direct the pessimism level. In this work, we use the CEM to control the sampled episodes around the desired risk level $\alpha$ , and demonstrate CVaR optimization for as extreme levels as $\alpha = 1\%$ . Note that unlike other CE-optimizers in RL [Mannor et al., 2003, Huang et al., 2021c], we use the CEM for sampling, to support a gradient-based optimizer.
+
+# 2 Problem Formulation
+
+Consider a Markov Decision Process (MDP) $(S, A, P, \gamma, P_0)$ , corresponding to states, actions, state-transition and reward distribution, discount factor, and initial state distribution, respectively. For any policy parameter $\theta \in \mathbb{R}^n$ , we denote by $\pi_{\theta}$ the parameterized policy that maps a state to a probability distribution over actions. Given a state-action-reward trajectory $\tau = \{(s_t, a_t, r_t)\}_{t=0}^T$ , the trajectory total return is denoted by $R(\tau) = \sum_{t=0}^{T} \gamma^t r_t$ . The expected return of a policy $\pi_{\theta}$ is defined as
+
+$$
+J (\pi_ {\theta}) = \mathbb {E} _ {\tau \sim P ^ {\pi_ {\theta}}} [ R (\tau) ], \tag {1}
+$$
+
+where $P^{\pi_{\theta}}(\tau) = P_0(s_0)\prod_{t = 0}^{T - 1}P(s_{t + 1},r_t|s_t,a_t)\pi_{\theta}(a_t|s_t)$ is the probability distribution of $\tau$ induced by $\pi_{\theta}$ . Under the risk-neutral objective, the PG method uses the gradient $\nabla_{\theta}J(\pi_{\theta})$ to learn $\theta$ , aiming to increase the probability of actions that lead to higher returns. In contrast, CVaR-PG methods aim to optimize the risk-averse $\mathrm{CVaR}_{\alpha}$ objective (w.r.t. a given risk level $\alpha$ ):
+
+$$
+J _ {\alpha} \left(\pi_ {\theta}\right) = \mathbb {E} _ {\tau \sim P ^ {\pi_ {\theta}}} [ R (\tau) \mid R (\tau) \leq q _ {\alpha} (R | \pi_ {\theta}) ], \tag {2}
+$$
+
+where $q_{\alpha}(R|\pi_{\theta})$ is the $\alpha$ -quantile of the return random variable of policy $\pi_{\theta}$ . Thus, CVaR-PG algorithms aim to improve the actions specifically for episodes whose returns are lower than $q_{\alpha}(R|\pi_{\theta})$ . Specifically, given a batch of $N$ trajectories $\{\tau_i\}_{i=1}^N$ whose empirical return quantile is $\hat{q}_{\alpha} = \hat{q}_{\alpha}(\{R(\tau_i)\}_{i=1}^N)$ , the CVaR gradient estimation is given by [Tamar et al., 2015b]:
+
+$$
+\nabla_ {\theta} \hat {J} _ {\alpha} \left(\left\{\tau_ {i} \right\} _ {i = 1} ^ {N}; \pi_ {\theta}\right) = \frac {1}{\alpha N} \sum_ {i = 1} ^ {N} w _ {i} \cdot \mathbf {1} _ {R \left(\tau_ {i}\right) \leq \hat {q} _ {\alpha}} \left(R \left(\tau_ {i}\right) - \hat {q} _ {\alpha}\right) \sum_ {t = 0} ^ {T} \nabla_ {\theta} \log \pi_ {\theta} \left(a _ {i, t}; s _ {i, t}\right), \tag {3}
+$$
+
+where $w_{i} = P^{\pi_{\theta}}(\tau_{i}) / f(\tau_{i}|\pi_{\theta})$ is the importance sampling (IS) correction factor for $\tau_{i}$ , if $\tau_{i}$ is sampled from a distribution $f \neq P^{\pi_{\theta}}$ . Specifically, as discussed below, we modify the sample distribution using the cross entropy method over a context-MDP formulation of the environment.
+
+Context-MDP: As mentioned above, we aim to focus on high-risk environment conditions. To discuss the notion of conditions, given a standard MDP, we extend its formulation to a Context-MDP (C-MDP) [Hallak et al., 2015], where the context is a set of variables that capture (part or all of) the randomness of the original MDP. We define the extension as $(S,A,\mathcal{C},P_{\mathcal{C}},\gamma ,P_0,D_{\phi_0})$ , where $C\in \mathcal{C}$ is sampled from the context space $\mathcal{C}$ according to the distribution $D_{\phi_0}$ parameterized by $\phi_0$ , and $P_C(\cdot) = P(\cdot |C)$ is the transition and reward distribution conditioned on $C$ . In a C-MDP, a context-trajectory pair is sampled from the distribution $P_{\phi_0}^{\pi_\theta}(C,\tau) = D_{\phi_0}(C)P_C^{\pi_\theta}(\tau)$ , where $P_{C}^{\pi_{\theta}}(\tau) = P_{0}(s_{0})\prod_{t = 0}^{T - 1}P_{C}(s_{t + 1},r_{t}|s_{t},a_{t})\pi_{\theta}(a_{t}|s_{t})$ . The mean and CVaR $\alpha$ objectives $J(\pi_{\theta})$ $J_{\alpha}(\pi_{\theta})$ in Equations (1) and (2) are naturally generalized to C-MDP using the distribution $P_{\phi_0}^{\pi_\theta}(C,\tau)$
+
+Once we extend an MDP into a C-MDP, we can learn how to modify the context-distribution parameter $\phi$ to sample high-risk contexts and trajectories, focusing the training on high-risk parts of the environment and thus improving sample efficiency. For this, we assume that certain aspects of the training environment (represented by $C$ ) can be controlled. This assumption indeed holds in many practical applications – in both simulated and physical environments. For example, consider a data collection procedure for a self-driving agent training, which by default samples all driving hours uniformly: $C \sim U([0,24))$ . As the hour may affect traffic and driving patterns, a risk-averse driver would prefer to sample more experience in high-risk hours. To that end, we could re-parameterize the uniform distribution as, say, $\text{Beta}(\phi)$ with $\phi_0 = (1,1)$ (note that $\text{Beta}(1,1)$ is the uniform distribution), learn the high-risk hours, and modify $\phi$ to over-sample them. As another example, in the Guarded Maze described above, we can control the parameters $\phi_1, \phi_2$ of the simulation.
+
+# 3 Limitations of CVaR-PG
+
+Consider the standard CVaR-PG algorithm, which relies on Equation (3) to apply PG for maximization of $J_{\alpha}(\pi_{\theta})$ of (2). In this section, we analyze two major limitations of this algorithm. Section 3.1 analyzes the blindness to success phenomenon, which may bring CVaR-PG learning to a local-optimum deadlock. This will motivate the soft-risk scheduling in Section 4. Section 3.2 analyzes the potential increase in sample efficiency when the environmental context is sampled in correspondence to the tail of the returns distribution. This will motivate the cross-entropy sampler in Section 4.
+
+While the analysis focuses on CVaR-PG methods, Appendix H discusses Distributional RL algorithms for CVaR optimization, and demonstrates that similar limitations apply to these methods as well.
+
+# 3.1 Blindness to Success
+
+We formally analyze how the blindness to success phenomenon can bring the policy learning to a local-optimum deadlock by ignoring successful agent strategies.
+
+Recall the $\alpha$ -quantile of a return distribution $q_{\alpha}^{\pi} = \min \{r|F_{R(a)|\pi}(r)\geq \alpha \}$ . We first introduce the notion of a tail barrier, corresponding to a returns-distribution tail with a constant value.
+
+Definition 1 (Tail barrier). Let $\alpha \in (0,1]$ . A policy $\pi$ has an $\alpha$ -tail barrier if $\forall \alpha' \in [0,\alpha]: q_{\alpha'}^{\pi} = q_{\alpha}^{\pi}$ .
+
+Note that in any environment with a discrete rewards distribution, a policy is prone to having a tail barrier for some $\alpha > 0$ . In existing CVaR-PG analysis [Tamar et al., 2015b], such barriers are often overlooked by assuming continuous rewards. For the Guarded Maze, Figure 13c in the appendix demonstrates how a standard CVaR-PG exhibits a 0.9-tail barrier, since as many as $90\%$ of the trajectories reach neither the target nor the guard, and thus have identical low returns.
+
+A tail barrier has a destructive effect on CVaR-PG. Consider a $\mathrm{CVaR}_{\alpha}$ objective, and a policy $\pi$ with a $\beta$ -tail barrier where $\beta > \alpha$ . Intuitively, any infinitesimal change of $\pi$ cannot affect the CVaR return, since the returns infinitesimally above $q_{\alpha}^{\pi}$ are identical to those below $q_{\alpha}^{\pi}$ . That is, any tail barrier wider than $\alpha$ brings the CVaR-PG to a stationary point of type plateau. More formally, consider $\nabla_{\theta} \hat{J}_{\alpha}$ of Equation (3) with a $\beta$ -tail barrier $\beta > \alpha$ : any trajectory has either $\mathbf{1}_{R(\tau_i) \leq q_{\alpha}^{\pi}} = 0$ (if its return is above $q_{\alpha}^{\pi}$ ) or $R(\tau_i) - q_{\alpha}^{\pi} = 0$ (otherwise), hence the whole gradient vanishes. Such a loss plateau was also observed in a specific MDP in Section 5.1 of Huang et al. [2021a].
+
+In practice, a discrepancy between $q_{\alpha}^{\pi}$ and its estimate $\hat{q}_{\alpha}(\{R(\tau_i)\})$ (used in Equation 3) may prevent the gradient from completely vanishing, if $q_{\alpha}^{\pi} = q_{\beta}^{\pi} < \hat{q}_{\alpha}(\{R(\tau_i)\})$ . Otherwise, if $\hat{q}_{\alpha}(\{R(\tau_i)\}) \leq q_{\beta}^{\pi}$ in every subsequent iteration, the gradient remains zero, the policy cannot learn any further, and any trajectory returns beyond $q_{\alpha}^{\pi}$ will never be even propagated to the optimizer. We refer to this phenomenon as blindness to success.
+
+Definition 2 (Blindness to success). Let a risk level $\alpha \in (0,1)$ and a CVaR-PG training step $m_0 \geq 1$ , and let $\beta \in (\alpha,1)$ . Denote by $\mathcal{T}, \Pi$ the spaces of trajectories and policies, respectively, and by $\{\tau_{m,i}\}_{i=1}^{N} \sim P^{\pi_m}$ the random trajectories in step $m \geq m_0$ . We denote by $\mathcal{B}_{\alpha,\beta}^{m_0,n}$ the event of blindness to success in the subsequent $n$ steps (and the complementary event by $\neg \mathcal{B}_{\alpha,\beta}^{m_0,n}$ ):
+
+$$
+\mathcal {B} _ {\alpha , \beta} ^ {m _ {0}, n} = \left\{\left\{\left(\{\tau_ {m, i} \} _ {i = 1} ^ {N}, \pi_ {m}\right) \right\} _ {m _ {0} \leq m < m _ {0} + n} \in (\mathcal {T} ^ {N} \times \Pi) ^ {n} \Big | \forall m: \hat {q} _ {\alpha} (\{R (\tau_ {m, i}) \}) \leq q _ {\beta} ^ {\pi_ {m _ {0}}} \right\}.
+$$
+
+Note that Definition 2 uses $q_{\beta}^{\pi_{m_0}}$ (corresponding to step $m_0$ ) to bound the returns in training steps $m > m_0$ , thus indeed represents training stagnation. Theorem 1 shows that given a $\beta$ -tail barrier with $\beta > \alpha$ , the probability that CVaR-PG avoids the blindness to success decreases exponentially with $\beta - \alpha$ . For example, for $n = 10^6$ , $\alpha = 0.05$ , $\beta = 0.25$ , and $N = 400$ , we have $\mathbb{P}(\neg \mathcal{B}_{\alpha, \beta}^{m_0, n}) < 10^{-7}$ .
+
+Theorem 1. Under Definition 2's conditions, $\mathbb{P}\left(\neg \mathcal{B}_{\alpha ,\beta}^{m_0,n}\mid \pi_{m_0}\text{has}\beta$ -tail barrier) $\leq ne^{-2N(\beta -\alpha)^2}$
+
+Proof sketch (see the full proof in Appendix A). In every step $m$ , we have $q_{\beta}^{\pi_{m_0}} < \hat{q}_{\alpha}(\{R(\tau_{m,i})\})$ only if at least $1 - \alpha$ of the returns are higher than $q_{\beta}^{\pi_{m_0}}$ . We bound the probability of this event using the Hoeffding inequality (Lemma 1). In the complementary event the gradient is 0 (due to the barrier), thus the policy does not change, and the argument can be applied inductively to the next step.
+
+# 3.2 Variance Reduction and Sample Efficiency
+
+As discussed in Section 2, an MDP can be often re-parameterized as a C-MDP. In terms of the C-MDP, CVaR-PG samples $N$ context-trajectory pairs from the distribution $P_{\phi_0}^{\pi_\theta}(C,\tau)$ , and calculates the policy gradients with respect to the $\alpha N$ trajectories with the lowest returns. That is, CVaR-PG aims to follow the policy gradients corresponding to the tail distribution defined by
+
+$$
+P _ {\phi_ {0}, \alpha} ^ {\pi_ {\theta}} (C, \tau) = \alpha^ {- 1} \mathbf {1} _ {R (\tau) \leq q _ {\alpha} (R | \pi_ {\theta})} P _ {\phi_ {0}} ^ {\pi_ {\theta}} (C, \tau) \tag {4}
+$$
+
+Notice that by considering only $\alpha$ of the trajectories, CVaR-PG essentially suffers from $\alpha^{-1}$ -reduction in sample efficiency in comparison to risk-neutral PG.
+
+Proposition 1 shows that if we could sample trajectories directly from $P_{\phi_0,\alpha}^{\pi_\theta}$ , we would reduce the variance of the policy gradient estimate (and thus increase the sample efficiency) back by a factor of $\alpha^{-1}$ . This will motivate the CEM in Section 4, which will aim to modify $\phi$ such that $P_{\phi}^{\pi_\theta} \approx P_{\phi_0,\alpha}^{\pi_\theta}$ .
+
+Proposition 1 (Variance reduction). If the quantile estimation error is negligible ( $\hat{q}_{\alpha} = q_{\alpha}(R|\pi_{\theta})$ in Equation (3)), then
+
+$$
+\operatorname {V a r} _ {\tau_ {i} \sim P _ {\phi_ {0}, \alpha} ^ {\pi_ {\theta}}} (\nabla_ {\theta} \hat {J} _ {\alpha} (\{\tau_ {i} \} _ {i = 1} ^ {N}; \pi_ {\theta})) \leq \alpha \cdot \operatorname {V a r} _ {\tau_ {i} \sim P _ {\phi_ {0}} ^ {\pi_ {\theta}}} (\nabla_ {\theta} \hat {J} _ {\alpha} (\{\tau_ {i} \} _ {i = 1} ^ {N}; \pi_ {\theta})).
+$$
+
+Proof sketch (see the full proof in Appendix B). Since the left term corresponds to the sample distribution $P_{\phi_0,\alpha}^{\pi_\theta}$ , the corresponding IS weights are $w \equiv \alpha$ w.p. 1. When applying IS analysis to the expected value, $w$ cancels out the distributional shift (as in Equation 5), resulting in the same expected gradient estimate. When applying the same analysis to the variance, we begin with the square weight $w^2$ , thus a $w = \alpha$ factor still remains after the distributional shift compensation.
+
+The variance reduction can be connected to sample efficiency through the convergence rate as follows. According to Theorem 5.5 in Xu et al. [2020], denoting the initial parameters by $\theta_0$ , the convergence of any CVaR-PG algorithm can be written as $\mathbb{E}[\| \nabla_{\theta}J_{\alpha}(\pi_{\theta})\|^{2}] \leq \mathcal{O}\left(\frac{J_{\alpha}(\theta) - J_{\alpha}(\theta_{0})}{M}\right) + \mathcal{O}\left(\frac{\mathrm{Var}(\nabla_{\theta}\hat{J}_{\alpha}(\{\tau_{i}\}_{i = 1}^{N};\pi_{\theta}))}{\alpha N}\right)$ . Clearly, variance reduction of $\alpha$ -factor linearly improves the second term. In particular, it cancels out the denominator's $\alpha$ -factor attributed to tail sub-sampling, and brings the sample efficiency back to the level of the risk-neutral PG.
+
+# 4 The Cross-entropy Soft-Risk Algorithm
+
+Algorithm 1 presents our Cross-entropy Soft-Risk algorithm (CeSoR), which uses a PG approach to maximize $J_{\alpha}(\pi_{\theta})$ in (2). CeSoR adds two components on top of CVaR-PG: soft-risk scheduling to address the blindness to success analyzed in Section 3.1, and CE sampling to address the sample efficiency analyzed in Section 3.2.
+
+# Algorithm 1: CeSoR
+
+1 Input: risk level $\alpha$ ; context distribution $D_{\phi}$ ; original context parameter $\phi_0$ ; training steps $M$ ; trajectories sampled per batch $N$ , where $\nu$ fraction of them is from the original $D_{\phi_0}$ ; smoothed CE quantile $\beta$ ; risk-level scheduling factor $\rho$
+
+2 Initialize: policy $\pi_{\theta}$ , $\phi \gets \phi_0$
+3 $N_{o}\gets \lfloor \nu N\rfloor$ , $N_{s}\leftarrow \lceil (1 - \nu)N\right\rceil$
+4 for $m$ in $1:M$ do
+
+// Sample contexts
+
+5 Sample $\{C_{o,i}\}_{i = 1}^{N_o}\sim D_{\phi_0},\quad \{C_{\phi ,i}\}_{i = 1}^{N_s}\sim D_\phi$
+6 $C\gets (C_{o,1},\ldots ,C_{o,N_o},C_{\phi ,1},\ldots ,C_{\phi ,N_s})$
+$w_{o,i}\gets 1,\forall i\in \{1,\ldots ,N_o\}$
+8 $w_{\phi ,i}\gets \frac{D_{\phi_0}(C_{\phi,i})}{D_{\phi}(C_{\phi,i})},\forall i\in \{1,\ldots ,N_s\}$
+9 $w\gets (w_{o,1},\dots ,w_{o,N_o},w_{\phi ,1},\dots ,w_{\phi ,N_s})$ // Sample trajectories
+10 $\{\tau_{C_{o,i}}\} ,\{\tau_{C_{\phi ,i}}\} \gets$ run_episodes $(\pi_{\theta},C)$ // Update CE sampler
+11 $q\gets \max (\hat{q}_{\alpha}(\{R(\tau_{C_{o,i}})\}),\hat{q}_{\beta}(\{R(\tau_{C_{.i}})\}))$
+12 $\phi \gets \operatorname{argmax}_{\phi'} \sum_{i \leq N} w_i \mathbf{1}_{R(\tau C_i) \leq q} \log D_{\phi'}(C_i)$ // PG step (e.g., Eq. 6)
+13 $\alpha^{\prime}\gets \max (\alpha ,1 - (1 - \alpha)\cdot m / (\rho \cdot M))$
+14 $q^{\prime}\gets \hat{q}_{\alpha^{\prime}}(\{R(\tau_{C_{o,i}})\})$
+15 $\theta \gets \mathrm{CVaR\_PG}(\pi_{\theta},(\{\tau_{C_{o,i}}\} ,\{\tau_{C_{\phi ,i}}\}),w,q^{\prime})$
+
+Soft-risk scheduler: We set the policy optimizer (Line 15 in Algorithm 1) to use a soft risk level $\alpha^{\prime}$ that gradually decreases from 1 to $\alpha$ (Line 13 and Figure 2). This is motivated by the blindness to success analyzed in Section 3.1: by modifying the risk level to $\alpha^{\prime} > \alpha$ , and specifically $\alpha^{\prime} \approx 1$ at the beginning of training, we guarantee that there cannot be a wider tail barrier $\beta > \alpha^{\prime}$ . Thus, CeSoR can feed the optimizer with trajectories whose returns $q_{\beta}^{\pi} < R \leq q_{\alpha^{\prime}}^{\pi}$ are higher than any constant tail; and since the fed returns are not constant, they do not eliminate the gradient. In this sense, CeSoR looks beyond local optimization-plateaus to prevent the blindness to success.
+
+The scheduling defined in Line 13 and Figure 2 is heuristic. As demonstrated in Section 5, once we understand the limitation of blindness to success, this simple heuristic is sufficient to bypass the blindness. An adaptive $\alpha^{\prime}$ scheduling that maximizes blindness prevention probability would require tighter concentration inequalities [Boucheron et al., 2013], and is left for future work.
+
+Cross Entropy Method (CEM): The CEM [de Boer et al., 2005] is a general approach to rare-event sampling and optimization, which we use to sample high-risk contexts and trajectories. First, we review the standard CEM in terms adjusted to our setting and notations (for a more general presentation, see Algorithm 2 in the appendix). Then, we discuss the limitations of the standard CEM in the RL settings, and present our dynamic, regularized version of the CEM.
+
+Motivated by the sample efficiency analysis of Section 3.2, we wish to align the agent's experience with the $\alpha$ worst-case returns - by sampling contexts whose corresponding trajectory-returns are likely to be below $q_{\alpha}(R|\pi_{\theta})$ . That is, we wish to sample context-trajectory pairs from $P_{\phi_0,\alpha}^{\pi_\theta}$ of (4). To that end, the CEM searches for a value of $\phi$ for which $P_{\phi}^{\pi_{\theta}}$ is similar to $P_{\phi_0,\alpha}^{\pi_\theta}$ . More precisely, it looks for $\phi^{*}$ that minimizes the KL-divergence (i.e., cross-entropy) between the two:
+
+$$
+\begin{array}{l} \phi^ {*} \in \operatorname {a r g m i n} _ {\phi^ {\prime}} D _ {K L} \left(P _ {\phi_ {0}, \alpha} ^ {\pi_ {\theta}} (C, \tau) | | P _ {\phi^ {\prime}} ^ {\pi_ {\theta}} (C, \tau)\right) \\ = \operatorname {a r g m a x} _ {\phi^ {\prime}} \mathbb {E} _ {(C, \tau) \sim P _ {\phi_ {0}} ^ {\pi_ {\theta}}} \left[ \alpha^ {- 1} \mathbf {1} _ {R (\tau) \leq q _ {\alpha} (R | \pi_ {\theta})} \log D _ {\phi^ {\prime}} (C) \right] \tag {5} \\ = \operatorname {a r g m a x} _ {\phi^ {\prime}} \mathbb {E} _ {(C, \tau) \sim P _ {\phi} ^ {\pi_ {\theta}}} \left[ \alpha^ {- 1} w (C, \tau) \mathbf {1} _ {R (\tau) \leq q _ {\alpha} (R | \pi_ {\theta})} \log D _ {\phi^ {\prime}} (C) \right], \\ \end{array}
+$$
+
+where $P_{\phi'}^{\pi_\theta}(C, \tau) = D_{\phi'}(C)P_C^{\pi_\theta}(\tau)$ (Section 2), and $w(C, \tau) = \frac{P_{\phi_0}^{\pi_\theta}(C, \tau)}{P_\phi^{\pi_\theta}(C, \tau)} = \frac{D_{\phi_0}(C)}{D_\phi(C)}$ is the IS weight corresponding to the sample distribution $(C, \tau) \sim P_\phi^{\pi_\theta}$ . The optimization problem in Equation (5) often reduces to a simple closed-form calculation: if $D_\phi$ is a Gaussian, for example, $\phi^*$ reduces to the weighted expectation and variance of $\{C | R(\tau) \leq q_\alpha\}_{C, \tau \sim P_\phi^{\pi_\theta}}$ with the IS weights $w(C, \tau)$ .
+
+Equation (5) may produce noisy results when estimated from data $\{(C_i,\tau_i)\}_{i = 1}^N$ , unless $N\gg \alpha^{-1}$ since only $\alpha N$ trajectory-samples satisfy $R(\tau)\leq q_{\alpha}$ and are used in the estimation. To address this,
+
+
+Figure 2: The soft-risk scheduling (Algorithm 1, Line 13). The linear phase $\alpha' > \alpha$ prevents the blindness to success (Section 3.1), while the CEM still preserves risk aversion. The final constant phase $\alpha' = \alpha$ provides a stationary objective and allows CeSoR to converge (Appendix C).
+
+
+Figure 3: An illustration of training batches. Each point represents an episode with return $R$ and context $C$ . Points of the same color correspond to "similar" agent actions that induce similar policy gradients. Mean-PG averages over the whole batch and learns the blue strategy. CVaR-PG considers the left part (low returns) and learns the orange strategy. CeSoR over-samples the upper part (high-risk contexts), and only later decreases $\alpha'$ to explicitly focus on low returns, thus learning the purple strategy. The illustrated episodes are analogous to the strategies in Figures 1d,4.
+
+
+
+
+
+the CEM reaches the $\alpha$ -tail gradually over iterations. Every iteration, it samples a batch of contexts $\{C_i\}_{i=1}^N$ from the current distribution $D_{\phi}$ , and then solves Equation (5) with respect to a higher quantile $q \geq q_{\alpha}$ . More specifically, denote by $\hat{q}_{\alpha}^{\phi}$ the estimated $\alpha$ -quantile of $\{R(\tau)\}_{C,\tau \sim P_{\phi}^{\pi \theta}}$ ; then, we set $q = \max(\hat{q}_{\alpha}^{\phi_0}, \hat{q}_{\beta}^{\phi})$ with a hyperparameter $\beta > \alpha$ (often $\beta = 0.2$ ). Since the data is drawn from $P_{\phi}^{\pi \theta}$ , this guarantees at least $\beta N$ samples per update step. The quantile $\hat{q}_{\alpha}^{\phi_0}$ corresponds to the $\alpha$ -tail of the original context-distribution, and can be viewed as a stopping condition: once $\hat{q}_{\alpha}^{\phi_0} > \hat{q}_{\beta}^{\phi}$ , many of our samples are already in the tail, and $\beta$ is no longer needed to smooth the update of $\phi$ .
+
+Dynamic-target CEM: The standard CEM assumes to search for the tail of a constant distribution. In our setting, however, we look for the tail of the distribution of the returns $R(\tau)$ , where $C, \tau \sim P_{\phi_0}^{\pi_\theta}$ depend on $\pi_\theta$ and thus are non-stationary throughout the training. The non-stationarity poses several challenges for the CEM. First, the stopping condition $\hat{q}_{\alpha}^{\phi_0}$ varies with $\pi_\theta$ and has to be re-estimated every iteration1. Second, the high-risk contexts $C$ (which correspond to the lowest returns) may vary as the agent evolves; and if the CEM learns to only sample a strict subset of the context space, then it may miss such changes in the high-risk contexts.
+
+We address both issues using reference samples: every iteration, we sample two batches of contexts - $\{C_{\phi ,i}\}_{i = 1}^{N_s}$ from the current context distribution $D_{\phi}$ and $\{C_{o,i}\}_{i = 1}^{N_o}$ from the original distribution $D_{\phi_0}$ . The reference contexts provide an important regularization: they guarantee continual exposure to the whole context space, in case that the high-risk contexts vary. In addition, the reference samples were empirically found to stabilize the estimation of $\hat{q}_{\alpha}^{\phi_0}$ (Line 11 in Algorithm 1).
+
+Consider the two batches of context-trajectory pairs, and denote the estimated return quantile $\hat{q}_{\alpha} = \hat{q}_{\alpha}(\{R(\tau_i)\}_{i=1}^{N_o})$ . We can estimate the CVaR policy gradient, using the notation $\forall 1 \leq i \leq N_o + N_s$ :
+
+$$
+\begin{array}{l} C _ {i} = \left\{ \begin{array}{l l} C _ {o, i} & \text {i f} 1 \leq i \leq N _ {o} \\ C _ {\phi , i - N _ {o}} & \text {i f} N _ {o} + 1 \leq i \leq N _ {o} + N _ {s}, \end{array} \right., \text {b y} \\ \nabla_ {\theta} \hat {J} _ {\alpha} \left(\pi_ {\theta}\right) = \frac {1}{\alpha \left(N _ {o} + N _ {s}\right)} \sum_ {i = 1} ^ {N _ {o} + N _ {s}} w _ {i} \cdot \mathbf {1} _ {R \left(\tau_ {i}\right) \leq \hat {q} _ {\alpha}} \left(R \left(\tau_ {i}\right) - \hat {q} _ {\alpha}\right) \sum_ {t = 0} ^ {T} \nabla_ {\theta} \log \pi_ {\theta} \left(a _ {i, t}; s _ {i, t}\right), \tag {6} \\ \end{array}
+$$
+
+where $w_{i} = 1$ for $1\leq i\leq N_o$ and $w_{i} = D_{\phi_{0}}(C_{i}) / D_{\phi^{*}}(C_{i})$ for $N_{o} + 1\leq i\leq N_{o} + N_{s}$
+
+Note that if the policy learning scale is slower than that of $\phi$ , the target context distribution $P_{\phi_0,\alpha}^{\pi_\theta}$ is effectively stationary in the $\phi$ -optimization problem. In that case, according to de Mello and Rubinstein [2003], the CEM will converge to the KL-divergence minimizer $\phi^*$ of (5).
+
+Sample efficiency in practice: Proposition 1 guarantees an $\alpha^{-1}$ -increase in sample efficiency when using an accurate quantile estimate $\hat{q}_{\alpha} = q_{\alpha}(R|\pi_{\theta})$ and sampling exactly from $P_{\phi, \alpha}^{\pi_{\theta}}$ . The latter condition is equivalent to the CE-sampler reaching its objective $D_{KL}(P_{\phi, \alpha}^{\pi_{\theta}} \mid P_{\phi}^{\pi_{\theta}}) = 0$ . In practice, $P_{\phi, \alpha}^{\pi_{\theta}}$ can only be approximated, and the sample efficiency is increased - but by a smaller factor than $\alpha^{-1}$ . Appendix D.3 demonstrates the increased sample size exploited by CeSoR in our experiments.
+
+If $\hat{q}_{\alpha} \neq q_{\alpha}(R|\pi_{\theta})$ , the quantile estimation error may theoretically lead to unbounded IS weights (see Appendix B). Practically, we address this by clipping the weights (as mentioned in Section 5), and by constraining the family of permitted distributions $\{D_{\phi}\}_{\phi}$ to have a constant support independently of $\phi$ . A side-effect is a function approximation error of the family $\{D_{\phi}\}_{\phi}$ , as $D_{\phi^{*}}(C)P_{C}^{\pi_{\theta}}(\tau)$ cannot replicate the tail distribution $P_{\phi_0,\alpha}^{\pi_\theta}(C,\tau)$ to achieve the full $\alpha^{-1}$ -increase in sample efficiency.
+
+Another limitation in the expressiveness of $P_{\phi}^{\pi_{\theta}}(C,\tau) = D_{\phi}(C)P_{C}^{\pi_{\theta}}(\tau)$ occurs when the context $C$ only controls part of the environment randomness in $P_{C}^{\pi_{\theta}}(\tau)$ . As an extreme example in the Guarded Maze, after $\pi_{\theta}$ already learns to avoid the short path, the context (guard cost) does not affect the outcome at all anymore. Indeed, Figure 10a in the appendix shows that high guard costs are sampled in the beginning; then, once the short path is avoided, the sampler gradually falls back to the original context distribution. Note that in this example, the invariance to $C$ began after the learning was essentially done, hence the CEM did play its part effectively.
+
+Finally, note that the soft risk creates an intentional bias in the gradient estimate (to overcome the blindness to success). As a result, in the first phase of training $(\alpha' \gg \alpha)$ , only a few trajectories are overlooked every iteration. As $\alpha'$ approaches $\alpha$ , the number of overlooked trajectories increases, and so is the importance of over-sampling the tail. In the final steady-state phase $(\alpha' = \alpha)$ , the sample inefficiency is most severe, the soft risk produces no further biases, and the CEM helps CeSoR to reduce the high variance in the policy gradient estimation.
+
+The harmony between the soft risk and the CEM: Soft risk has the inherent side effect of reducing the risk aversion. In the Guarded Maze, for example, as demonstrated in Section 5.1, soft risk alone leads to learning the short path (instead of the risk-averse long path). Fortunately, the CEM reduces this side effect. In that sense, the two mechanisms complement each other: $\alpha' > \alpha$ allows the optimizer to learn policies with high returns, while the CE sampler still preserves the risk aversion – as illustrated in Figure 3. This connection stands in addition to the independent motivations of the two mechanisms, as discussed above.
+
+Baseline optimizer: CeSoR can be implemented on top of any CVaR-PG method as a baseline (Line 15). We use the standard GCVaR [Tamar et al., 2015b], which guarantees asymptotic convergence under certain regularity conditions. Appendix C shows that these guarantees hold for CeSoR as well, when implemented on top of GCVaR. Other CVaR-PG baselines can also be used, such as the TRPO-based algorithm of Rajeswaran et al. [2017]. However, such methods often include heuristics that introduce additional gradient estimation bias (to reduce variance), and thus do not necessarily guarantee the same theoretical convergence.
+
+# 5 Experiments
+
+We conduct experiments in 3 different domains. We implement CeSoR on top of a standard CVaR-PG method, which is also used as a risk-averse baseline for comparison. Specifically, we use the standard GCVaR baseline [Tamar et al., 2015b], which guarantees convenient convergence properties (see Appendix C) and is simple to implement and analyze. We also use the standard policy gradient (PG) as a risk-neutral baseline. We stress that the comparison to PG is only intended to present the mean-CVaR tradeoff, while each method legitimately optimizes its own objective. Appendix H also compares CeSoR to risk-neutral and risk-averse Distributional RL algorithms.
+
+In all the experiments, all agents are trained using Adam [Diederik P. Kingma, 2014], with a learning rate selected manually per benchmark and $N = 400$ episodes per training step. Every 10 steps we run validation episodes, and we choose the final policy according to the best validation score (best mean for PG, best CVaR for GCVaR and CeSoR). For CeSoR, unless specified otherwise, $\nu = 20\%$ of the trajectories per batch are drawn from the original distribution $D_{\phi_0}$ ; $\beta = 20\%$ are used for the CE update; and the soft risk level reaches $\alpha$ after $\rho = 80\%$ of the training. As mentioned in Section 4, for numerical stability, we also clip the IS weights (Algorithm 1, Line 9) to the range $[1/5, 5]$ .
+
+Every policy is modeled as a neural network with tanh activation on its middle layers and softmax operator on its output, with temperature 1 in training (i.e., network outputs are actions probabilities), and 0 in validation and test (i.e., the max output is the selected action). We use a middle layer with 32 neurons in Section 5.2, 16 neurons in Section 5.3, and no middle layer (linear model) in Section 5.1.
+
+In each of the 3 domains, the experiments required a running time of a few hours on an Ubuntu machine with eight i9-10900X CPU cores. In addition to these RL-related experiments, Appendix D presents dedicated experiments for the independent CE module.
+
+# 5.1 The Guarded Maze
+
+Benchmark: The Guarded Maze benchmark is defined in Section 1. For the experiments, we set a target risk level of $\alpha = 0.05$ , and train each agent for $n = 250$ steps with the parameters described above. The CEM controls $C$ through $\phi = (\phi_1,\phi_2)$ where $\phi_0 = (0.2,32)$ as mentioned above, and updates $\phi_1,\phi_2$ using the weighted means of $C_1$ and $C_2$ , respectively. As an ablation test, we add two partial variants of our CeSoR: CeR (with CE, without $\alpha$ -scheduling) and SoR (with scheduling, without CE). See more details in Appendix E.1.
+
+Results: Figure 1a summarizes the test scores, and Figure 1d illustrates a sample episode. PG learned the short path, maximizing the average but at the cost of poor returns whenever charged by the guard. CeSoR, on the other hand, successfully learned to follow the CVaR-optimal long path. GCVaR, which also aimed to maximize the CVaR, failed to do so.
+
+As analyzed in Figure 4, throughout GCVaR training, the agent takes the long path in up to $50\%$ of the episodes per batch, but none of these episodes is ever included in the bottom $\alpha = 5\%$ that are fed to the optimizer. Thus, GCVaR is entirely blind to the successful episodes and fails to learn the corresponding strategy. In fact, in most training steps, all the worst episodes of GCVaR reach neither the guard nor the target, leading to a constant return of $-32$ , a tail barrier, and a zero loss-gradient.
+
+CeR suffers from blindness to success just as GCVaR. SoR is exposed to the successful long-path episodes thanks to soft risk scheduling; however, due to the reduced risk-aversion, it fails to prefer the long path over the short one. Only CeSoR both observes the "good" strategy (thanks to soft risk scheduling) and judges it under "bad" environment variations (thanks to the CEM). Appendix E.2 presents a detailed analysis of the learning dynamics, the blindness to success and the learned policies. It is important to notice that standard optimization tweaks cannot bring GCVaR to learn the long path: a "warm-start" from a standard PG only encourages the short-path policy (as in SoR); and increased batch size $N$ does not expose the optimizer to the long path (see Theorem 1).
+
+
+
+
+Figure 4: GCVaR, SoR, CeSoR: $\%$ -episodes that did not reach the target ("stay"), or reached it through the short or the long path in the Guarded Maze. Bottom Right: $\%$ -long-paths among the trajectories fed to the optimizer. See more details in Figure 13.
+
+# 5.2 The Driving Game
+
+Benchmark: The Driving Game is based on an inverse-RL benchmark used by Majumdar et al. [2017] and Singh et al. [2018]. The agent's car has to follow the leader (an "erratic driver") for 30 seconds as closely as possible without colliding. Every 1.5 seconds (i.e., 20 times per episode), the leader chooses a random action (independently of the agent): drive straight, accelerate, decelerate, change lane, or brake hard ("emergency brake"), with respective probabilities $\phi_0 = (0.35, 0.3, 0.248, 0.1, 0.002)$ . We denote the sequence of leader actions by $C \in \{1, \dots, 5\}^{20}$ .
+
+Every 0.5 seconds (60 times per episode), the agent observes its relative position and velocity to the leader, with a delay of 0.7 seconds (representing reaction time), as well as its own acceleration and steering direction. The agent chooses one of the five actions: drive in the same steering direction, accelerate, decelerate, turn left, or turn right. Changing lane is not an atomic action and has to be learned using turns. The rewards express the requirements to stay behind the leader, on the road, on the same lane, not too far behind and without colliding. See the complete details in Appendix F.1.
+
+We set $\alpha = 0.01$ , and train each agent for $n = 500$ steps. To initiate learning, for each agent we begin with shorter training episodes of 6 seconds and gradually increase their length. The CEM controls the leader's behavior through the probabilities $\phi = \{\phi_i\}_{i=1}^5$ described above.
+
+Results: Figure 1b summarizes the test scores of the agents, where CeSoR presents a reduction of $28\%$ in the CVaR cost in comparison to the baselines. GCVaR completely fails to learn a reasonable policy - losing in terms of CVaR even to the risk-neutral PG. Figure 5 shows that CeSoR learned an arguably-intuitive policy for risk averse driving: it keeps a safer distance from the leader, and uses the gas and the brake less frequently. This results in complete avoidance of the rare accidents occurring to PG, as demonstrated in Figure 1e. In Appendix D, we also see that by over-sampling turns and emergency brakes of the leader, the CEM manages to align the mean return of the training samples with the $1\%$ -CVaR of the environment, and significantly increases the data efficiency.
+
+# 5.3 The Computational Resource Allocation Problem
+
+Benchmark: Computational resource allocation in serving systems, and in particular the tradeoff between resource cost and serving latency, is an important challenge to both academia [Jiang et al., 2013, Tessler et al., 2022] and industry [Barr, 2018, Lunden, 2022]. In popular applications such as E-commerce and news, latency is most critical at times of peak loads [Garces, 2019], making CVaR a natural metric for risk-averse optimization. In our benchmark, the agent allocates servers to handle user requests, managing the tradeoff between servers cost and time-to-service (TTS). Requests arrive randomly with a constant rate, up to rare events that cause sudden peak loads, whose frequency is controlled by the CE sampler. S
+
+
+(a)
+
+
+(b)
+Figure 5: Over all the time-steps in all the test episodes in the Driving Game, the distribution of (a) the distance between the agent and the leader, (b) the agent actions. Evidently, CeSoR learns to keep more distance than the risk-neutral PG, and has a slightly less frequent use of the gas and the brake.
+
+Results: As shown in Figure 1c, CeSoR significantly improves the CVaR return, and does not compromise the mean as much as GCVaR. As demonstrated in Figure 1f, CeSoR learned to allocate a default of 5 servers and react to peak loads as needed, whereas GCVaR simply allocates 8 servers at all times. PG only allocates 4 servers by default, and thus its TTS is more sensitive to peak loads. Appendix G describes the complete implementation and detailed results, discusses the poor parameterization of $D_{\phi}$ in this problem and shows the robustness of CeSoR to that parameterization.
+
+# 6 Summary and Future Work
+
+We introduced CeSoR, a novel method for risk-averse RL, focused on efficient sampling and soft risk. In a variety of experimental domains, in comparison to a risk-averse baseline, CeSoR demonstrated higher CVaR metric, better sample-efficiency, and elimination of blindness to success – where the latter two were also analyzed theoretically.
+
+There are certain limitations to CeSoR. First, we assume to have at least partial control over the training conditions, through a parametric family of distributions that needs to be selected. Second, CeSoR can be applied robustly on top of any CVaR-PG method, but is currently not applicable to non-PG methods. Since the limitations of CVaR-PG apply in other risk-averse methods as well (as we demonstrated for Distributional RL), future work may adjust CeSoR to such methods, as well as to other risk measures. Third, in terms of blindness to success and estimation variance, CeSoR shows both theoretical and empirical improvement – but is not proven optimal. Future work may look for optimal design of CEM or risk scheduling. Considering the current results and the potential extensions, we believe CeSoR may open the door for more practical applications of risk-averse RL.
+
+Acknowledgements: This research was supported by the Israel Science Foundation (grant 2199/20).
+
+# References
+
+Jeff Barr. Predictive scaling for EC2, powered by machine learning, 2018. URL https://aws.amazon.com/blogs/aws/new-predictive-scaling-for-ec2-powered-by-machine-learning/.
+Marc G Bellemare, Will Dabney, and Rémi Munos. A distributional perspective on reinforcement learning. In International Conference on Machine Learning, pages 449-458. PMLR, 2017.
+Cristian Bodnar, Adrian Li, Karol Hausman, Peter Pastor, and Mrinal Kalakrishnan. Quantile QT-Opt for risk-aware vision-based robotic grasping. In Proceedings of Robotics: Science and Systems, Corvalis, Oregon, USA, July 2020. doi: 10.15607/RSS.2020.XVI.075.
+V. S. Borkar and S. P. Meyn. Risk-sensitive optimal control for Markov decision processes with monotone cost. Mathematics of Operations Research, 27(1):192-209, 2002.
+Vivek Borkar and Rahul Jain. Risk-constrained Markov decision processes. IEEE Transactions on Automatic Control, 2014.
+Stéphane Boucheron, Gábor Lugosi, and Pascal Massart. Concentration inequalities: A nonasymptotic theory of independence. Oxford university press, 2013.
+Y. Chow and M. Ghavamzadeh. Algorithms for CVaR optimization in MDPs. In Proceedings of Advances in Neural Information Processing Systems 27, pages 3509-3517, 2014.
+Y. Chow, A. Tamar, S. Mannor, and M. Pavone. Risk-sensitive and robust decision-making: a CVaR optimization approach. In Advances in Neural Information Processing Systems, 2015.
+Sebastian Curi, Kfir Y. Levy, Stefanie Jegelka, and Andreas Krause. Adaptive sampling for stochastic risk-averse learning. In H. Larochelle, M. Ranzato, R. Hadsell, M.F. Balcan, and H. Lin, editors, Advances in Neural Information Processing Systems, volume 33, pages 1036-1047. Curran Associates, Inc., 2020. URL https://proceedings.neurips.cc/paper/2020/file/0b6ace9e8971cf36f1782aa982a708db-Paper.pdf.
+Will Dabney, Georg Ostrovski, David Silver, and Remi Munos. Implicit quantile networks for distributional reinforcement learning. In Proceedings of the 35th International Conference on Machine Learning, pages 1096-1105, 2018a.
+Will Dabney, Mark Rowland, Marc Bellemare, and Rémi Munos. Distributional reinforcement learning with quantile regression. Proceedings of the AAAI Conference on Artificial Intelligence, 32(1), Apr. 2018b. doi: 10.1609/aaai.v32i1.11791. URL https://ojs(aaai.org/index.php/AAAI/article/view/11791.
+Frederic Dambreville. Cross-entropy method: convergence issues for extended implementation, 2006.
+P. T. de Boer, Dirk P. Kroese, Shie Mannor, and Reuven Y. Rubinstein. A tutorial on the cross-entropy method. Annals of Operations Research, 134:19-67, 2005.
+Tito Homem de Mello and Reuven Y. Rubinstein. Rare event estimation for static models via cross-entropy and importance sampling, 2003.
+Jimmy Ba Diederik P. Kingma. Adam: A method for stochastic optimization, 2014. URL https://arxiv.org/abs/1412.6980.
+Yingjie Fei, Zhuoran Yang, Yudong Chen, and Zhaoran Wang. Exponential bellman equation and improved regret bounds for risk-sensitive reinforcement learning. Advances in Neural Information Processing Systems, 34, 2021.
+Carla Prat Garces. The problem of peak loads in web applications and its solutions, 2019.
+Javier García and Fernando Fernández. A comprehensive survey on safe reinforcement learning. J. Mach. Learn. Res., 16:1437-1480, 2015.
+
+Mathieu Godbout, Maxime Heuillet, Sharath Chandra, Rupali Bhati, and Audrey Durand. CARL: Conditional-value-at-risk adversarial reinforcement learning. arXiv preprint arXiv:2109.09470, 2021.
+Ido Greenberg. Cross entropy method with non-stationary score function. https://pypi.org/project/cross-entropy-method/, 2022.
+Assaf Hallak, Dotan Di Castro, and Shie Mannor. Contextual markov decision processes. arXiv preprint arXiv:1502.02259, 2015.
+Takuya Hiraoka, Takahisa Imagawa, Tatsuya Mori, Takashi Onishi, and Yoshimasa Tsuruoka. Learning robust options by conditional value at risk optimization. NeurIPS, 05 2019.
+Wassily Hoeffding. Probability inequalities for sums of bounded random variables. In The collected works of Wassily Hoeffding, pages 409-426. Springer, 1994.
+L. Jeff Hong and Guangwu Liu. Simulating sensitivities of conditional value at risk. Management Science, 55(2):281-293, 2009. ISSN 00251909, 15265501. URL http://www.jstor.org/stable/40539145.
+Audrey Huang, Liu Leqi, Zachary C. Lipton, and Kamyar Azizzadenesheli. On the convergence and optimality of policy gradient for markov coherent risk, 2021a. URL https://arxiv.org/abs/2103.02827.
+Audrey Huang, Liu Leqi, Zachary C. Lipton, and Kamyar Azizzadenesheli. On the convergence and optimality of policy gradient for markov coherent risk, 2021b. URL https://arxiv.org/abs/2103.02827.
+Kevin Huang, Sahin Lale, Ugo Rosolia, Yuanyuan Shi, and Anima Anandkumar. CEM-GD: Cross-entropy method with gradient descent planner for model-based reinforcement learning, 2021c.
+Jing Jiang, Jie Lu, Guangquan Zhang, and Guodong Long. Optimal cloud resource auto-scaling for web applications. In 2013 13th IEEE/ACM International Symposium on Cluster, Cloud, and Grid Computing, pages 58-65. IEEE, 2013.
+Ramtin Keramati, Christoph Dann, Alex Tamkin, and Emma Brunskill. Being optimistic to be conservative: Quickly learning a CVaR policy. Proceedings of the AAAI Conference on Artificial Intelligence, 34:4436-4443, 04 2020.
+Leslie Kish. Survey Sampling. New York: John Wiley and Sons, Inc., 1965.
+Tom Leinster. Effective sample size, 2014.
+Ingrid Lunden. Intel confirms acquisition of AI-based workload optimization startup granulate, reportedly for up to $650M, 2022.
+Anirudha Majumdar, Sumeet Singh, Ajay Mandlekar, and Marco Pavone. Risk-sensitive inverse reinforcement learning via coherent risk models. Robotics: Science and Systems, 07 2017. doi: 10.15607/RSS.2017.XIII.069.
+Shie Mannor, Reuven Rubinstein, and Yohai Gat. The cross entropy method for fast policy search. Proceedings, Twentieth International Conference on Machine Learning, 2, 07 2003.
+Cosmin Paduraru, Daniel J. Mankowitz, Gabriel Dulac-Arnold, Jerry Li, Nir Levine, Sven Gowal, and Todd Hester. Challenges of real-world reinforcement learning: Definitions, benchmarks and analysis. Machine Learning Journal, 2021.
+Lerrel Pinto, James Davidson, Rahul Sukthankar, and Abhinav Gupta. Robust adversarial reinforcement learning. In Proceedings of the 34th International Conference on Machine Learning - Volume 70, ICML'17, page 2817-2826. JMLR.org, 2017.
+L.A. Prashanth and M. Ghavamzadeh. Actor-critic algorithms for risk-sensitive MDPs. In Proceedings of Advances in Neural Information Processing Systems 26, pages 252-260, 2013.
+
+L.A. Prashanth and M. Ghavamzadeh. Variance-constrained actor-critic algorithms for discounted and average reward MDPs. Machine Learning Journal, 105(3):367-417, 2016.
+Wei Qiu, Xinrun Wang, Runsheng Yu, Xu He, R. Wang, Bo An, Svetlana Obraztsova, and Zinovi Rabinovich. RMIX: Learning risk-sensitive policies for cooperative reinforcement learning agents. ArXiv, abs/2102.08159, 2021.
+Antonin Raffin, Ashley Hill, Adam Gleave, Anssi Kanervisto, Maximilian Ernestus, and Noah Dormann. Stable-baselines3: Reliable reinforcement learning implementations. Journal of Machine Learning Research, 22(268):1-8, 2021. URL http://jmlr.org/papers/v22/20-1364.html.
+Aravind Rajeswaran, Sarvjeet Ghotra, Balaraman Ravindran, and Sergey Levine. Epopt: Learning robust neural network policies using model ensembles. ICLR, 2017.
+Makoto Sato, Hajime Kimura, and Syumpei Kobayashi. TD algorithm for the variance of return and mean-variance reinforcement learning. Transactions of The Japanese Society for Artificial Intelligence, 16:353-362, 2001.
+Sumeet Singh, Jonathan Lacotte, Anirudha Majumdar, and Marco Pavone. Risk-sensitive inverse reinforcement learning via semi- and non-parametric methods. The International Journal of Robotics Research, 37, 04 2018. doi: 10.1177/0278364918772017.
+Aviv Tamar, Yinlam Chow, Mohammad Ghavamzadeh, and Shie Mannor. Policy gradient for coherent risk measures. NIPS, 2015a.
+Aviv Tamar, Yonatan Glassner, and Shie Mannor. Optimizing the CVaR via sampling. AAAI'15, page 2993-2999, 2015b.
+Yichuan Tang, Jian Zhang, and Ruslan Salakhutdinov. Worst cases policy gradients. In CoRL, 2019.
+Chen Tessler, Yuval Shpigelman, Gal Dalal, Amit Mandelbaum, Doron Haritan Kazakov, Benjamin Fuhrer, Gal Chechik, and Shie Mannor. Reinforcement learning for datacenter congestion control. SIGMETRICS Perform. Eval. Rev., 49(2):43-46, jan 2022. ISSN 0163-5999. doi: 10.1145/3512798.3512815. URL https://doi.org/10.1145/3512798.3512815.
+J. R. R. Tolkien. The Lord of the Rings: The Fellowship of the Ring. George Allen and Unwin, 1954.
+Nithia Vijayan and L. A. Prashanth. Likelihood ratio-based policy gradient methods for distorted risk measures: A non-asymptotic analysis. ArXiv, abs/2107.04422, 2021.
+Edoardo Vittori, Michele Trapletti, and Marcello Restelli. Option hedging with risk averse reinforcement learning. In Proceedings of the First ACM International Conference on AI in Finance, ICAIF '20, New York, NY, USA, 2020. Association for Computing Machinery. ISBN 9781450375849. doi: 10.1145/3383455.3422532. URL https://doi.org/10.1145/3383455.3422532.
+T. Xie, B. Liu, Y. Xu, M. Ghavamzadeh, Y. Chow, D. Lyu, and D. Yoon. A block coordinate ascent algorithm for mean-variance optimization. In Proceedings of Advances in Neural Information Processing Systems 232, pages 1073-1083, 2018.
+Pan Xu, Felicia Gao, and Quanquan Gu. An improved convergence analysis of stochastic variance-reduced policy gradient. In Uncertainty in Artificial Intelligence, pages 541-551. PMLR, 2020.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See the summary (Section 6).
+(c) Did you discuss any potential negative societal impacts of your work? [N/A] Risk sensitive RL is an abstract task and is not specifically associated with any negative-impact applications.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes] For each result, Section 3 either states the assumptions directly or refers to Appendices A-C.
+(b) Did you include complete proofs of all theoretical results? [Yes] See Section 3 with references to Appendices A-C.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] A repository of our code presents Jupyter notebooks that reproduce the experimental results.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] General details in the beginning of Section 5, and specific details per experiment in Sections 5.1-5.3.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] In Figures 1,11,16,20a, we provide not only the average return but the full distribution, which implicitly includes the information of error bars.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] In the beginning of Section 5.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [N/A]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] An anonymized repository of our code is linked from the abstract.
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientriskaversereinforcementlearning/images.zip b/efficientriskaversereinforcementlearning/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..7ad7e6393b2ae90093c2399d1406ca33e5d164a3
--- /dev/null
+++ b/efficientriskaversereinforcementlearning/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:da26edf4e1ec317930df6eef38b51e23b76b366eeb7aa4a4480a0b9aba3c321e
+size 270489
diff --git a/efficientriskaversereinforcementlearning/layout.json b/efficientriskaversereinforcementlearning/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..a328e4c58eed3dd7d75a3efbd8e3590b0d8b0a6b
--- /dev/null
+++ b/efficientriskaversereinforcementlearning/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:554f20f5a24b5a2c7677b6c12c73d3b29012feb186d0be162c3ec406947de421
+size 639336
diff --git a/efficientsamplingonriemannianmanifoldsvialangevinmcmc/2bb0c25a-d92e-467b-a74d-2c146d045123_content_list.json b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/2bb0c25a-d92e-467b-a74d-2c146d045123_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..0ca626d207949bf837d88efe1fb7f9b1b2b92b36
--- /dev/null
+++ b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/2bb0c25a-d92e-467b-a74d-2c146d045123_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:60712d5db174630543b6190fbf1cedc5b7ad4dd562ec6415469aadeef9ec0a29
+size 86927
diff --git a/efficientsamplingonriemannianmanifoldsvialangevinmcmc/2bb0c25a-d92e-467b-a74d-2c146d045123_model.json b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/2bb0c25a-d92e-467b-a74d-2c146d045123_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..6b6c8d943bb187c8d797fcf2cab0e194d79e905f
--- /dev/null
+++ b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/2bb0c25a-d92e-467b-a74d-2c146d045123_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8d052739d3301b882165fea3f183d626c03353ee85d203de626021abbd106657
+size 103805
diff --git a/efficientsamplingonriemannianmanifoldsvialangevinmcmc/2bb0c25a-d92e-467b-a74d-2c146d045123_origin.pdf b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/2bb0c25a-d92e-467b-a74d-2c146d045123_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..911a98040b035bde0ec02f7e9e23e74b9ff87017
--- /dev/null
+++ b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/2bb0c25a-d92e-467b-a74d-2c146d045123_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5d667d204336cbc8c111374094f1e9d738343da640dd40671849c5d2ae2112cc
+size 492557
diff --git a/efficientsamplingonriemannianmanifoldsvialangevinmcmc/full.md b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..36a3d9c885219b97145d2775f07520767982a4c7
--- /dev/null
+++ b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/full.md
@@ -0,0 +1,395 @@
+# Efficient Sampling on Riemannian Manifolds via Langevin MCMC
+
+Xiang Cheng
+
+Massachusetts Institute of Technology
+
+x.cheng@berkeley.edu
+
+Jingzhao Zhang
+
+Tsinghua University jzhzhang@mit.edu
+
+Suvrit Sra
+
+Massachusetts Institute of Technology
+
+suvrit@mit.edu
+
+# Abstract
+
+We study the task of efficiently sampling from a Gibbs distribution $d\pi^{*} = e^{-h}d\mathrm{vol}_{g}$ over a Riemannian manifold $M$ via (geometric) Langevin MCMC; this algorithm involves computing exponential maps in random Gaussian directions and is efficiently implementable in practice. The key to our analysis of Langevin MCMC is a bound on the discretization error of the geometric Euler-Murayama scheme, assuming $\nabla h$ is Lipschitz and $M$ has bounded sectional curvature. Our error bound matches the error of Euclidean Euler-Murayama in terms of its stepsize dependence. Combined with a contraction guarantee for the geometric Langevin Diffusion under Kendall-Cranston coupling, we prove that the Langevin MCMC iterates lie within $\varepsilon$ -Wasserstein distance of $\pi^{*}$ after $\tilde{O} (\varepsilon^{-2})$ steps, which matches the iteration complexity for Euclidean Langevin MCMC. Our results apply in general settings where $h$ can be nonconvex and $M$ can have negative Ricci curvature. Under additional assumptions that the Riemannian curvature tensor has bounded derivatives, and that $\pi^{*}$ satisfies a $CD(\cdot ,\infty)$ condition, we analyze the stochastic gradient version of Langevin MCMC, and bound its iteration complexity by $\tilde{O} (\varepsilon^{-2})$ as well.
+
+# 1 Introduction
+
+Stochastic differential equations (SDEs) offer a powerful formalism for studying diffusion processes, Brownian motion, and algorithms for sampling and optimization. We study in particular the following geometric stochastic differential equation:
+
+$$
+d x (t) = \beta (x (t)) d t + d B _ {t} ^ {g}, \tag {1.1}
+$$
+
+that evolves on a $d$ -dimensional Riemannian manifold $(M,g)$ . Analogous to the Euclidean setting, the map $\beta :x\to T_xM$ denotes a drift $(T_{x}M$ is the tangent space at $x\in M)$ , and $dB_{t}^{g}$ denotes the standard Brownian motion on $M$ [Hsu, 2002, Ch. 3]. The notation in (1.1) is a shorthand; we can define (1.1) more precisely as the unique diffusion process whose generator is the operator $Lf = \langle \nabla f,\beta \rangle +\frac{1}{2}\Delta f$ , where $\Delta$ is the Laplace-Beltrami operator (see [Hsu, 2002, Proposition 3.2.1]).
+
+When the drift $\beta (x) = -\frac{1}{2}\nabla h(x)$ (the gradient is taken w.r.t. the manifold metric), the SDE (1.1) has an invariant distribution $\pi^{*}$ with density $e^{-h(x)}$ , with respect to the Riemannian volume measure $\mathrm{vol}_g(x)$ ; for $M = \mathbb{R}^d$ with metric $g(x) = I$ , this reduces to the familiar result for Euclidean Langevin diffusion. Using the Kendall-Cranston Coupling technique (Chapter 6.5, Hsu [2002]) together with a carefully constructed Lyapunov function by Eberle [2016], we can quantify the mixing rate for (1.1) in the 1-Wasserstein distance (w.r.t. the manifold distance) under suitable regularity conditions.
+
+However, the exact SDE is not implementable in practice, so we consider an MCMC algorithm using the Geometric Euler-Murayama [Piggott and Solo, 2016, Muniz et al., 2021] discretization of (1.1):
+
+$$
+x _ {k + 1} = \operatorname {E x p} _ {x _ {k}} (\delta \beta (x _ {k}) + \sqrt {\delta} \zeta_ {k}), \tag {1.2}
+$$
+
+where $\mathrm{Exp}_x$ denotes the exponential map for $M$ , and $\zeta_k$ is a standard Gaussian with respect to any orthonormal basis of $T_{x_k}M$ . It has long been known that the discrete-time process (1.2) converges to the SDE (1.1) in the limit as $\delta \to 0$ [Gangolli, 1964, Jorgensen, 1975, Hsu, 2002].
+
+# Motivation for studying the SDE (1.1)
+
+Geometric SDEs such as (1.1) play a crucial role in the design and analysis of MCMC algorithms [Girolami and Calderhead, 2011, Patterson and Teh, 2013] that have had much success in solving Bayesian problems on statistical manifolds. Recently, it has been shown that the mirror Langevin Algorithm on the Hessian manifold of a function can be significantly faster than its Euclidean counterpart [Zhang et al., 2020, Chewi et al., 2020, Li et al., 2022, Gatmiry and Vempala, 2022].
+
+These SDEs also directly relate to the tasks of sampling and optimization on manifolds, where often a Lie group structure helps capture symmetries (e.g., the Grassmann manifold, $\mathrm{SO}(n)$ , $O(n)$ , etc.) [Moitra and Risteski, 2020, Piggott and Solo, 2016, Muniz et al., 2021]. Furthermore, in Lee and Vempala [2017, 2018], the authors propose fast algorithms for constrained sampling and volume estimation on polytopes by sampling from the Hessian manifold of a barrier function.
+
+# 2 Overview of Main Contributions
+
+Our first contribution in this paper is to provide a quantitative, non-asymptotic bound on the discretization error between (1.1) and (1.2). We present this bound in Lemma 1 in Section 4. In our bound, the expected-squared-distance between a single step of (1.2) and (1.1) over $\delta$ time is bounded by $O(\delta^3)$ . This $\delta^3$ error scaling matches that of Euler Murayama in Euclidean space [Durmus and Moulines, 2017]. We highlight that our bound is entirely explicit, and depends polynomially on dimension, sectional curvature of $M$ , and the Lipschitz parameter for $\beta -$ quantities which are intrinsic to the manifold, and invariant to the choice of coordinate system.
+
+Two recent papers, [Wang et al., 2020, Li et al., 2022] also look into a similar problem of bounding the discretization error of (1.2). Wang et al. [2020] analyze the error of (1.2), but rely on uniformly bounding certain derivatives of the densities along the sample path (see Assumption 3 [Wang et al., 2020]); even in Euclidean space, it is not clear whether such a bound exists, and whether it depends only polynomially on parameters such as dimension. Li et al. [2022] provide a quantitative bound on the bias of (1.2) on Hessian manifolds; they assume a bound on a "modified self-concordance" parameter that is not affine invariant and can be made arbitrarily large.
+
+We discuss Lemma 1 in more detail, and sketch its proof in Section 4. The proof relies on a careful construction of geometric Langevin Diffusion as the limit of (1.2), and may be of independent interest.
+
+Our second contribution is to show that after $\tilde{O} (\varepsilon^{-2})$ steps, the distribution of (1.2) is within $\varepsilon$ 1-Wasserstein distance from the stationary distribution of (1.1). We present this result in Theorem 1. This $\varepsilon$ dependence matches that of Euclidean Langevin MCMC [Durmus and Moulines, 2017].
+
+The $\tilde{O}$ in our iteration complexity hides polynomial dependency on dimension, sectional curvature, Lipschitz-parameter of $\beta$ , and $1 / \alpha$ , where $\alpha$ can be viewed as "mixing rate of the exact SDE." Theorem 1 requires that $\beta$ satisfy a manifold analog of the distant-dissipativity assumption (Assumption 2 with $m > L_{Ric} / 2$ , where $-L_{Ric}$ is a lower bound on the Ricci curvature of $M$ ). Assumption 2 is general enough to include cases when $\beta = -\nabla h$ for some nonconvex $h$ or when $M$ has negative Ricci curvature. The catch is that in such cases, $1 / \alpha$ can become very large; this is generally unavoidable, even on Euclidean space. Distant-dissipativity assumption has often been used in the analysis of Euclidean Langevin diffusion for non-log-concave distributions [Eberle, 2016, Bou-Rabee et al., 2020, Gorham et al., 2019, Cheng et al., 2020].
+
+We highlight a computational sub-contribution that (1.2) only requires computing exponential maps in the direction of $\beta$ plus a uniform Gaussian direction. In many cases, exponential maps are efficiently computable, and this Theorem 1 leads to a computationally efficient sampling algorithm. Our analysis extends naturally if one replaces (1.2) by a retraction step; if the retraction is of order $3/2$
+
+or higher, the one-step error still scales as $O(\delta^3)$ . The question of how to construct good retraction maps is well studied in literature, and is somewhat orthogonal to our main objective, so we do not provide details here, and instead refer readers to [Absil and Malick, 2012, Absil et al., 2009].
+
+Recently, Ahn and Chewi [2021], Gatmiry and Vempala [2022], Li and Erdogdu [2020] have considered a different discretization of (1.1), where one assumes that the endpoint of the geometric Brownian motion $dB_{t}^{g}$ can be sampled exactly (so that only the drift $\beta$ is discretized). Sampling the exact geometric Brownian motion can be done efficiently in special settings such as the sphere [Li and Erdogdu, 2020], but on a general manifold, this can be much more expensive than computing an exponential map; in such settings the Langevin MCMC algorithm based on (1.2) may be preferable. We do highlight, however, that a number of the above results provide error bounds in KL-divergence, which is tighter than the Wasserstein bound in Theorem 1.
+
+We discuss assumptions and consequences of Theorem 1 in more detail and sketch its proof in Section 5. The proof essentially combines our discretization analysis with a mixing result for (1.1) based on the Kendall-Cranston coupling and a Lyapunov function from [Eberle, 2016].
+
+For our third contribution, we analyze the manifold analog of SGLD [Welling and Teh, 2011]:
+
+$$
+x _ {k + 1} = \operatorname {E x p} _ {x _ {k}} \left(\delta \tilde {\beta} _ {k} \left(x _ {k}\right) + \sqrt {\delta} \zeta_ {k}\right), \tag {2.1}
+$$
+
+The difference between (2.1) and (1.2), is that at each step, $\beta$ is replaced by a random vector field $\tilde{\beta}_k$ which satisfies: (i) $\mathbb{E}[\tilde{\beta}_k] = \beta$ ; and (ii) $\| \tilde{\beta}_k(x) - \beta (x)\| \leq \sigma$ almost surely. We show that after $\tilde{O} (\varepsilon^{-2})$ steps, (2.1) is within $\varepsilon$ -2-Wasserstein distance from the stationary distribution of (1.1); thus the $\varepsilon$ dependency does not degrade when replacing $\beta$ by its stochastic estimate. We present this result in Theorem 2. For this analysis, we require Assumption 2, with $m > L_{\mathrm{Ric}} / 2$ and $\mathcal{R} = 0$ ; this is a more restrictive condition than Theorem 1; when $\beta = -\frac{1}{2}\nabla h$ , this restriction is equivalent to the $CD(\cdot ,\infty)$ condition [Bakry et al., 2014]: $\nabla^2 h + \mathrm{Ric}\succ 0$ , where $\mathrm{Ric}$ is the Ricci curvature tensor1.
+
+Though restrictive, the $CD(\cdot ,\infty)$ class of distributions is nonetheless interesting; it is the manifold analog of the class of log-concave densities on Euclidean space, and sampling from this class has been a topic of much recent interest. In machine learning, the stochastic estimate of $\beta$ can often be computed much more quickly than the exact $\beta$ , e.g., when $\beta = -2\nabla f$ , where $f$ is the empirical average of some loss over a large number of observations. In such cases, (2.1) can be much faster than (1.2). In Section 6 we discuss the assumptions and consequences of Theorem 2 in greater detail.
+
+Though Theorem 2 requires more restrictive assumptions than Theorem 1, its proof differs from the proof of Theorem 1 in a significant way: we show mixing of the discrete-time process directly (instead of relying on mixing of the exact SDE). This approach is necessary in order to take advantage of the fact that $\tilde{\beta}_k$ is an unbiased estimate $\beta$ . The key intermediate result for showing mixing under (2.1) is Lemma 29. We believe this lemma to be of independent interest as it quantifies the distance evolution between two arbitrary discrete-time stochastic processes (that may be unrelated to Gaussian noise and Brownian motion). As an example, Mangoubi and Smith [2018] showed that ball walk mixes quickly on manifolds with positive sectional curvature. Using Lemma 29, one can show the more general statement "ball walk mixes quickly on compact manifolds with positive Ricci curvature."
+
+# 3 Preliminaries: Key Assumptions and Notation
+
+We state in this section the four key assumptions of this paper. Our first assumption involves lower bounding Ricci curvature of the manifold $M$ . Let $\mathrm{Ric}$ denote the Ricci curvature tensor:
+
+Assumption 1. We assume that for all $x \in M$ , $u, u \in T_xM$ , $\operatorname{Ric}(u, u) \geq -L_{\operatorname{Ric}}$ , for some $L_{\operatorname{Ric}} \in \mathbb{R}$ .
+
+Intuitively, the more positive the Ricci curvature (i.e. the smaller the value of $L_{\mathrm{Ric}}$ ), the faster geometric Brownian motion mixes.
+
+Our second assumption is a natural generalization of the distant-dissipativity condition in the Euclidean setting. It helps ensure that the drift traps the variable within a bounded region. For any $x, y \in M$ , let $\mathrm{d}(x, y)$ denote their Riemannian distance.
+
+Assumption 2. We call a vector field $\beta$ ( $m, q, \mathcal{R}$ )-distant-dissipative if there exist constants $m > 0$ , $\mathcal{R} \geq 0$ , and $q \in \mathbb{R}$ such that, for all $x, y$ satisfying $\mathrm{d}(x, y) \geq \mathcal{R}$ , there exists a minimizing geodesic
+
+$\gamma :[0,1]\to M$ with $\gamma (0) = x$ and $\gamma (1) = y$ , such that the inequality
+
+$$
+\left\langle \Gamma (\beta (y); y \rightarrow x) - \beta (x), \gamma^ {\prime} (0) \right\rangle \leq - m d (x, y) ^ {2},
+$$
+
+holds, where $\Gamma (\cdot ;y\to x)$ denotes parallel transport from $T_{y}M$ to $T_{x}M$ along $\gamma$ . In addition, for all $x,y$ satisfying $\mathrm{d}(x,y)\leq \mathcal{R}$ , there exists a minimizing geodesic $\gamma :[0,1]\to M$ with $\gamma (0) = x$ and $\gamma (1) = y$ , such that we have instead the inequality
+
+$$
+\left\langle \Gamma (\beta (y); y \rightarrow x) - \beta (x), \gamma^ {\prime} (0) \right\rangle \leq q \mathrm {d} (x, y) ^ {2}.
+$$
+
+For some intuition: a strictly convex function will have $m > 0$ , $\mathcal{R} = 0$ , and $q$ arbitrary. Note that we do not require a unique geodesic between $x, y$ .
+
+For some intuition about Assumption 2: in the Euclidean setting, the first condition simplifies to $\langle \beta(y) - \beta(x), y - x \rangle \leq -m \|y - x\|_2^2$ , and the second condition simplifies to $\langle \beta(y) - \beta(x), y - x \rangle \leq q \|y - x\|_2^2$ .
+
+We need our third and fourth assumptions for bounding the discretization error of (1.2). Assumption 3 upper bounds the Lipschitz constant of $\beta$ ; Assumption 4 lower bounds sectional curvature of $M$ .
+
+Assumption 3. A vector field $\beta$ is $L_{\beta}^{\prime}$ -Lipschitz if, for all $x \in M$ and all $v \in T_xM$ , $\| \nabla_v\beta (x)\| \leq L_{\beta}^{\prime}\| v\|$ .
+
+In the (flat) Euclidean setting, Assumption 3 is equivalent to saying that $\beta(x)$ being a $L_{\beta}^{\prime}$ Lipschitz vector field.
+
+Assumption 4. Let $R$ be the Riemannian curvature tensor of the manifold $M$ . We assume that there exists $L_{R} \in \mathbb{R}^{+}$ such that for all $x \in M$ , and for all $u, v, w, z \in T_{x}M$ , $\langle R(u,v)v,u\rangle \leq L_{R}\|u\|^{2}\|v\|^{2}$ .
+
+We now introduce additional notation that will be used throughout this paper. We assume some background in Riemannian geometry, and freely use standard notation; we refer the reader to [Jost, 2008, Lee, 2006, Petersen, 2006] for an in depth treatment. Readers may also find some works on Riemannian optimization useful as additional context: [Bacák, 2014, Udriste, 2013, Absil et al., 2009, Zhang and Sra, 2016, Boumal, 2022].
+
+We use $\nabla$ to denote the Levi Civita connection. Given $x, y \in M$ and $v \in T_xM$ , we use $\Gamma(v; x \to y)$ to denote parallel transport of $v$ from $x$ to $y$ along their minimizing geodesic (if such a choice is not unique we will specify); we sometimes also use the more concise alternative notation $\Gamma_x^y v \coloneqq \Gamma(v; x \to y)$ . Given a general curve (possibly non-geodesic) $\gamma : [0,1] \to M$ , we will also use $\Gamma_{\gamma(t)}v$ to denote the parallel transport of $v$ from $\gamma(0)$ to $\gamma(1)$ , along $\gamma$ .
+
+A basis $F$ of the tangent space $T_{x}M$ at some point $x \in M$ is an ordered tuple $(F^{1},\ldots,F^{d})$ of vectors that span $T_{x}M$ . We use $\Gamma(F;x \to y) \coloneqq (\Gamma(F^{1};x \to y)\dots \Gamma(F^{d};x \to y))$ to denote the ordered tuple of parallel transport of the each of the basis vectors in $F$ . Given $v \in \mathbb{R}^{d}$ and basis $F$ of some $T_{x}M$ , we use $v \circ F$ as shorthand for $\sum_{i=1}^{d} v_{i}F^{i}$ . A distribution that we will see frequently in this paper is the one given by $\xi \circ E^{x}$ , where $\xi \sim \mathcal{N}(0,I)$ is a random vector in $\mathbb{R}^{d}$ , and $x \in M$ and $E^{x}$ is an orthonormal basis of $T_{x}M$ . We use $\mathcal{N}_{x}(0,I)$ to denote the distribution of $\xi \circ E^{x}$ . One can verify that $\mathcal{N}_{x}(0,I)$ does not depend on the choice of basis $E^{x}$ .
+
+# 3.1 An illustrative example: sampling from a sphere
+
+To give some intuition about Assumptions 1 - 4, we present a simple example for sampling from $S^{d-1}$ , the unit d-sphere in $\mathbb{R}^d$ , which is a positively curved Riemannian manifold. The subsequent bounds for the $S^d$ case also generalize with minor modifications to other closely-related manifolds such as $\mathrm{SO}(d)$ .
+
+Let $U(x): \mathbb{R}^d \to Re$ be a potential function, and suppose that we wish to sample from $dp(x) \propto e^{-U(x)} dvol_g(x)$ defined over $S^{d-1}$ . It is known that for any $x \in S^{d-1}$ , $v \in T_xM$ , $\operatorname{Ric}(v, v) > 0$ ,
+
+so that Assumption 1 is satisfied with $L_{Ric} = 0$ . The sectional curvature is bounded by 1, so that Assumption 4 holds with $L_{R} = 1$ . For the remainder of this example, for $x \in S^{d-1}$ we will identify $T_{x}M$ with $\{v \in \mathbb{R}^d : v^T x = 0\}$ . Since the sphere is a submanifold of $\mathbb{R}^d$ , the metric is simply given by the Euclidean dot product, i.e. $g(u,v) = u^T v$ .
+
+Next, we will verify Assumption 3. Let us assume that for all $x$ on the sphere, $U(x)$ satisfies $\| \nabla U(x) \| \leq L_1$ and $\left\| \nabla^2 U(x) \right\|_2 \leq L_2$ , where $\nabla$ and $\nabla^2$ are the usual Euclidean gradient and Hessian respectively (bolded to distinguish from $\nabla$ , the covariant derivative). In order to sample from $dp(x)$ , $\beta(x) = (I - xx^T) \nabla U(x)$ . It is known that a geodesic $\gamma(t)$ corresponds to a great arc on the sphere, and that parallel transport of a vector $v$ involves a rotation of the tangential component of $v$ . To be precise, for any $x \in S^d$ and $u, v \in T_x M$ such that $\| u \| = 1$ , we verify that, in Cartesian coordinates, $\nabla_u v = (uu^T)v$ . Thus $\nabla \beta(x) = (uu^T)(I - xx^T) \nabla U(x) + \nabla^2 U(x)u \leq L_1 + L_2$ . Thus Assumption 3 holds with $L_\beta' = L_1 + L_2$ .
+
+Finally, we will verify Assumption 2. Since $S^{d-1}$ has diameter $\pi$ , the first part of Assumption 2 is satisfied with arbitrary $m$ and $R = \pi$ . The second part of Assumption 2 is satisfied with $q = L_{\beta}'$ . This is because $\frac{d}{dt} \langle \Gamma(\beta(\gamma(t)); \gamma(t) \to \gamma(0)) - \beta(\gamma(0)), \gamma'(0) \rangle = \frac{d}{dt} \langle \beta(\gamma(t)), \gamma'(t) \rangle = \langle \nabla_{\gamma'(t)} \beta(\gamma(t)), \gamma'(t) \rangle \leq L_{\beta}' \| \gamma'(t) \|^2$ .
+
+# 4 Bounding the Discretization Error in Geometric Euler-Murayama
+
+One of our main technical contributions is an error bound for the Euler-Murayama discretization. We provide an informal statement of this error bound as Lemma 1 below, and provide the formal statement as Lemma 7 in Appendix A.3.
+
+Lemma 1 (Informal version of Lemma 7). Let $x(t)$ denote the solution to (1.1) initialized at some $x(0)$ . Let $x^0(t)$ denote one step geometric Euler Murayama discretization: $x^0(t) \coloneqq \mathrm{Exp}_{x(0)}(t\beta(x(0)) + \sqrt{t}\zeta)$ , where $\zeta \sim \mathcal{N}_{x(0)}(0, I)$ . Under Assumptions 3 and 4, for sufficiently small $t$ , there exists a coupling between $x(t)$ and $x^0(t)$ such that
+
+$$
+\mathbb {E} [ \mathrm {d} (x (t), x ^ {0} (t)) ^ {2} ] \leq O (t ^ {3}),
+$$
+
+where $O(\cdot)$ hides polynomial dependence on the Lipschitz constant $L_{\beta}^{\prime}$ , the sectional curvature of $M$ , and dimension $d$ .
+
+# Proof Sketch for Lemma 1
+
+Given a time interval $T$ , we construct a sequence of processes $\{x^i(t)\}_{i \geq 0}$ indexed by $i$ (exact definition given in (4.2) below). Marginally, each $x^i(t)$ corresponds to the linear interpolation of a sequence of Euler-Murayama steps with stepsize $\delta^i = 2^{-i}T$ . More specifically, for $k \in \mathbb{Z}^+$ ,
+
+$$
+x _ {k + 1} ^ {i} = \operatorname {E x p} _ {x _ {k} ^ {i}} \left(\delta^ {i} \beta \left(x _ {k} ^ {i}\right) + \sqrt {\delta^ {i}} \zeta_ {k} ^ {i}\right) \quad \zeta_ {k} ^ {i} \sim \mathcal {N} _ {x _ {k} ^ {i}} (0, I)
+$$
+
+$$
+x ^ {i} (t) = \operatorname {E x p} _ {x _ {k} ^ {i}} \left(\frac {t - k \delta^ {i}}{\delta^ {i}} \left(\delta^ {i} \beta \left(x _ {k} ^ {i}\right) + \sqrt {\delta^ {i}} \zeta_ {k} ^ {i}\right)\right) \quad \text {f o r} t \in [ k \delta^ {i}, (k + 1) \delta^ {i} ]
+$$
+
+Notice that for $i = 0$ , $x^0(T)$ is a single step of (1.2) with stepsize $T$ . On the other hand, $x(t) \coloneqq \lim_{i \to \infty} x^i(t)$ is exactly the SDE in (1.1) (see Lemma 2 at the end of this section). We will soon see that $\mathbb{E}[\mathrm{d}(x^i(T), x^{i+1}(T))^2] = O(T^2 \delta^i)$ . We can then bound $\mathbb{E}[\mathrm{d}(x^0(T), x(T))^2] = O(T^3)$ by summing over the pairwise distance between adjacent $x^i$ and $x^{i+1}$ for $i \in \mathbb{Z}^+$ (this diminishes geometrically). This proves Lemma 1.
+
+To bound the distance between $x^i$ and $x^{i+1}$ , we introduce a crucial additional structure: adjacent pairs of processes $(x_k^i, x_k^{i+1})$ are coupled using the manifold analog of synchronous coupling, together with the discrete-time analog of "rolling without slipping". (see Remark 1),
+
+The exact formula for how $x_{k}^{i + 1}$ is to be constructed from $x_{k}^{i}$ is given in (4.1) below; it is a little dense, so we provide a pictorial illustration in Figure 1. For simplicity, we assume that $\beta = 0$ (the dominating error in Lemma 1 is due to Brownian motion). Figure 1 takes place over a period of time from $k\delta^i$ to $(k + 1)\delta^i$ (equivalently, $2k\delta^{i + 1}$ to $(2k + 2)\delta^{i + 1}$ ). The black squiggle denotes $(\mathbf{B}(t) - \mathbf{B}(k\delta^i)) \circ E_k^i$ for $t \in [k\delta^i, (k + 1)\delta^i]$ , where $\mathbf{B}(t)$ is a standard $d$ -dimensional Brownian
+
+motion, and $E_{k}^{i}$ is some basis at $x_{k}^{i}$ . Let $b_{k}^{i} := (\mathbf{B}((k + 1)\delta^{i}) - \mathbf{B}(k\delta^{i})) \circ E_{k}^{i}$ (black solid arrow). Bounding the distance between $x^{i}$ and $x^{i + 1}$ consists of two steps:
+
+
+Figure 1: An illustration of the coupling between paths for $x^i$ and $x^{i+1}$ when $\beta = 0$ over the time interval $[k\delta^i, (k + 1)\delta^i]$ .
+
+Step 1: Bounding $\mathrm{d}(x_{k + 1}^i, \mathrm{Exp}_{x_{2k}^{i + 1}}(\Gamma(b_k^i; x_k^i \to x_{2k}^{i + 1})))$ [Solid black arrow vs dotted black arrow] The purple line represents the geodesic from $x_k^i$ to $x_{2k}^{i + 1}$ ; by construction, the basis $E_{2k}^{i + 1}$ is the parallel transport of $E_k^i$ along the purple geodesic. The dotted black arrow denotes the $(\mathbf{B}((k + 1)\delta^i) - \mathbf{B}(k\delta^i)) \circ E_{2k}^{i + 1}$ ; we verify that it is the parallel transport of $b_k^i$ (black arrow) along the purple geodesic. Using Lemma 28, we can bound the distance between $x_{k + 1}^i = \mathrm{Exp}_{x_k^i}(b_k^i)$ (gray point) and $\mathrm{Exp}_{x_{2k}^{i + 1}}(\Gamma(b_k^i; x_k^i \to x_{2k}^{i + 1}))$ (green point) as
+
+$$
+\mathbb {E} [ \mathrm {d} (\mathrm {E x p} _ {x _ {k} ^ {i}} (b _ {k} ^ {i}), \mathrm {E x p} _ {x _ {2 k} ^ {i + 1}} (\Gamma (b _ {k} ^ {i}; x _ {k} ^ {i} \to x _ {2 k} ^ {i + 1}))) ^ {2} ] \leq (1 + O (L _ {R} d \delta^ {i})) \mathbb {E} [ \mathrm {d} (x _ {k} ^ {i}, x _ {2 k} ^ {i + 1}) ^ {2} ]
+$$
+
+Step 2: Bounding $\mathrm{d}(\mathrm{Exp}_{x_{2k}^{i + 1}}(\Gamma (b_k^i;x_k^i\to x_{2k}^{i + 1})),x_{2k + 2}^{i + 1})$ [Dotted black arrow vs blue + red arrow] Let
+
+$$
+b _ {2 k} ^ {i + 1} := \left(\mathbf {B} \left((2 k + 1) \delta^ {i + 1}\right) - \mathbf {B} \left(2 k \delta^ {i + 1}\right)\right) \circ E _ {2 k} ^ {i + 1}
+$$
+
+$$
+b _ {2 k + 1} ^ {i + 1} := \left(\mathbf {B} ((2 k + 2) \delta^ {i + 1}) - \mathbf {B} ((2 k + 1) \delta^ {i + 1})\right) \circ E _ {2 k} ^ {i + 1}
+$$
+
+We verify that $\Gamma(b_k^i; x_k^i \to x_{2k}^{i+1})$ (black dotted arrow) is equal to $b_{2k}^{i+1} + b_{2k+1}^{i+1}$ (note that $\delta^{i+1} = 1/2\delta^i$ ). On the other hand, $x_{2k+2}^{i+1}$ (orange point) is obtained from taking a step in $b_{2k}^{i+1}$ direction (blue arrow) followed by a step in the $\Gamma(b_{2k+1}^{i+1}; x_{2k}^{i+1} \to x_{2k+1}^{i+1})$ direction (red arrow). Due to curvature, this is not the same as taking a single step in the $b_k^i = b_{2k}^{i+1} + b_{2k+1}^{i+1}$ direction (green point). However, we can bound the distance between the orange point and the green point using Lemma 3 of Sun et al. [2019] (restated as Lemma 38 for ease of reference):
+
+$$
+\mathbb {E} [ \mathrm {d} (\mathrm {E x p} _ {x _ {2 k} ^ {i + 1}} (\Gamma (b _ {k} ^ {i}; x _ {k} ^ {i} \to x _ {2 k} ^ {i + 1})), x _ {2 k + 2} ^ {i + 1}) ^ {2} ] \leq O (\| b _ {2 k} ^ {i + 1} \| ^ {2} \| b _ {2 k + 1} ^ {i + 1} \| ^ {2} (\| b _ {2 k} ^ {i + 1} \| + \| b _ {2 k + 1} ^ {i + 1} \|) ^ {2}) = O ((\delta^ {i}) ^ {3})
+$$
+
+Summing the bounds of Step 1 and Step 2 gives $\mathbb{E}[\mathrm{d}(x_{k + 1}^i,x_{2k + 2}^{i + 1})^2 ]\leq e^{O(L_Rd\delta^i)}\mathbb{E}[\mathrm{d}(x_k^i,x_{2k}^{i + 1})^2 ] + O((\delta^i)^3)$ . Recursing over $k = 0\dots 2^i$ , and assuming that $T\leq \frac{1}{L_Rd}$ , we get $\mathbb{E}[\mathrm{d}(x_{2^i}^i,x_{2^{i + 1}}^{i + 1})^2 ] = \mathbb{E}[\mathrm{d}(x^i (T),x^{i + 1}(T))^2 ]\leq O(T^2\delta^i)$ . Summing over $i = 0\dots \infty$ gives $\mathbb{E}[\mathrm{d}(x^i (T),x(T))^2 ] = O(T^3)$ .
+
+# Details for Construction of Brownian Motion
+
+To bound the discretization error, we first characterize the manifold SDE (1.1) as the limit of a family of random processes. Let $x_0 \in M$ be an initial point and $E = \{E^1, \ldots, E^d\}$ be an orthonormal basis of $T_{x^0}$ . Let $\mathbf{B}(t)$ denote a standard Brownian Motion in $\mathbb{R}^d$ . Let $T \in \mathbb{R}^+$ . Define
+
+$$
+x _ {0} ^ {0} = x _ {0}, \qquad E _ {0} ^ {0} = E,
+$$
+
+$$
+x _ {1} ^ {0} = \operatorname {E x p} _ {x _ {0} ^ {0}} (T \beta (x _ {0} ^ {0}) + (\mathbf {B} (T) - \mathbf {B} (0)) \circ E _ {0} ^ {0}).
+$$
+
+For any $i \in \mathbb{Z}^+$ , let $\delta^i \coloneqq 2^{-i}T$ . We will now define points $x_k^i \in M$ and orthonormal basis $E_k^i$ of $T_{x_k^i}$ for all $i$ and all $k \in \{0, \dots, T / \delta^i\}$ . Our construction is inductive: Suppose we have already defined $x_k^i$ and $E_k^i$ for some $i$ and for all $k \in \{0, \dots, T / \delta^i\}$ . Then, we construct $x_k^{i+1}$ , for all $k = \{0, \dots, T / \delta^{i+1}\}$ , as follows:
+
+$$
+x _ {0} ^ {i + 1} := x _ {0}, \qquad E _ {0} ^ {i + 1} := E,
+$$
+
+$$
+x _ {2 k + 1} ^ {i + 1} := \operatorname {E x p} _ {x _ {2 k} ^ {i + 1}} \left(\delta^ {i + 1} \beta (x _ {2 k} ^ {i + 1}) + (\mathbf {B} ((2 k + 1) \delta^ {i + 1}) - \mathbf {B} (2 k \delta^ {i + 1})) \circ E _ {2 k} ^ {i + 1}\right),
+$$
+
+$$
+E _ {2 k + 1} ^ {i + 1} := \Gamma \left(E _ {2 k} ^ {i + 1}; x _ {2 k} ^ {i + 1} \rightarrow x _ {2 k + 1} ^ {i + 1}\right),
+$$
+
+$$
+x _ {2 k + 2} ^ {i + 1} := \operatorname {E x p} _ {x _ {2 k + 1} ^ {i + 1}} (\delta^ {i + 1} \beta (x _ {2 k + 1} ^ {i + 1}) + (\mathbf {B} ((2 k + 2) \delta^ {i + 1}) - \mathbf {B} ((2 k + 1) \delta^ {i + 1})) \circ E _ {2 k + 1} ^ {i + 1}),
+$$
+
+$$
+E _ {2 k + 2} ^ {i + 1} := \Gamma \left(E _ {k + 1} ^ {i}; x _ {k + 1} ^ {i} \rightarrow x _ {2 k + 2} ^ {i + 1}\right). \tag {4.1}
+$$
+
+The above display defines points $x_{k}^{i + 1}$ for all $k = \{0,\dots ,T / \delta^{i + 1}\}$ . For parallel transport, if the minimizing geodesic is not unique, any arbitrary choice will do. We verify that for any $i$ , for all $k$ , $x_{k}^{i}$ is indeed of the form (1.2), i.e. $x_{k + 1}^{i} = \mathrm{Exp}_{x_{k}^{i}}(\delta^{i}\beta (x_{k}^{i}) + \sqrt{\delta^{i}}\zeta_{k}^{i})$ , where $\zeta_k^i \coloneqq \frac{1}{\sqrt{\delta^i}} (\mathbf{B}((k + 1)\delta^i) - \mathbf{B}(k\delta^i)\circ E_k^i)\sim \mathcal{N}_{x_k^i}(0,I)$ . Finally, for any $i$ , any $k$ , and any $t\in [k\delta^i,(k + 1)\delta^i)$ , we define $x^{i}(t)$ to be the "linear interpolation" of $x_{k}^{i}$ and $x_{k + 1}^{i}$ , i.e.,
+
+$$
+x ^ {i} (t) := \operatorname {E x p} _ {x _ {k} ^ {i}} \left(\frac {t - k \delta^ {i}}{\delta^ {i}} \left(\delta^ {i} \beta \left(x _ {k} ^ {i}\right) + \left(\mathbf {B} \left((k + 1) \delta^ {i}\right) - \mathbf {B} \left(k \delta^ {i}\right)\right)\right) \circ E _ {k} ^ {i}\right). \tag {4.2}
+$$
+
+Remark 1. The choice of basis $E_{k}^{i}$ in (4.1) can be seen as a combination of "synchronous coupling" and "rolling without slipping" (see Chapter 2 of [Hsu, 2002]). In particular, $E_{2k}^{i+1} \coloneqq \Gamma(E_{k}^{i}; x_{k}^{i} \to x_{2k}^{i+1})$ corresponds to "synchronous coupling"—the step from $x_{2k}^{i+1}$ to $x_{2k+1}^{i+1}$ is (roughly) parallel to the step from $x_{k}^{i}$ to $x_{k+1}^{i}$ . On the other hand, $E_{2k+1}^{i+1} \coloneqq \Gamma(E_{2k}^{i+1}; x_{2k}^{i+1} \to x_{2k+1}^{i+1})$ corresponds to "rolling without slipping"—the step from $x_{2k+1}^{i+1}$ to $x_{2k+2}^{i+1}$ is with respect to an orthonormal basis that is parallel-transported from $x_{2k}^{i+1}$ to $x_{2k+1}^{i+1}$ .
+
+We verify in the following Lemma that the limit, $i\to \infty$ , of $x^{i}(t)$ is the SDE (1.1):
+
+Lemma 2. For any $T$ , for $t \in [0, T]$ , let $x(t) \coloneqq \lim_{i \to \infty} x^i(t)$ . This limit exists uniformly almost surely, and $x(t)$ is a diffusion process generated by the operator $L$ whose action on any smooth function $f$ is given by $Lf = \langle \nabla f, \beta \rangle + \frac{1}{2} \Delta(f)$ , where $\Delta$ denotes the Laplace Beltrami operator. Thus $x(t)$ is equal to (1.1) in distribution.
+
+Lemma 2 follows immediately from [Gangolli, 1964, Jorgensen, 1975], but we provide a proof in Appendix A.1 for completeness.
+
+# 5 Langevin MCMC on Riemannian Manifolds
+
+With the one-step discretization error in Lemma 1, we can bound the iteration complexity of Langevin MCMC (1.2):
+
+Theorem 1 (Convergence of Langevin MCMC on Riemannian Manifold). Assume the manifold $M$ satisfies Assumptions 1 and 4. Assume in addition that there exists a constant $L_R'$ such that for all $x \in M$ , $u, v, w, z, a \in T_xM$ , $\langle (\nabla_aR)(u, v)w, z \rangle \leq L_R' \|u\| \|v\| \|w\| \|z\| \|a\|$ (this last assumption is for analytical convenience; $L_R'$ does not show up in the quantitative bounds). Let $\beta$ be a vector field satisfying Assumptions 2 and 3; assume in addition that $m > L_{\mathrm{Ric}} / 2$ and that $q + L_{\mathrm{Ric}} / 2 \geq 0$ . Let $x^*$ be some point with $\beta(x^*) = 0$ .
+
+Let $y(t)$ denote the exact geometric SDE given in (1.1) initialized at some $y(0)$ . Let $K \in \mathbb{Z}^+$ be some iteration number and $\delta$ be some stepsize. Let $x_k$ denote the Euler Murayama discretization of (1.1), defined by $x_{k+1} = \mathrm{Exp}_{x_k}(\delta \beta(x_k) + \sqrt{\delta} \zeta_k)$ , where $\zeta_k \sim \mathcal{N}_{x_k}(0, I)$ , initialized at some $x_0$ satisfying $\mathrm{d}(x_0, x^*) \leq 2\mathcal{R}$ .
+
+Then, there exists a constant $\mathcal{C}_0 = \text{poly}(L_\beta', d, L_R, \mathcal{R}, \frac{1}{m - L_{\mathrm{Ric}} / 2}, \log K)$ , such that if $\delta \leq \frac{1}{\mathcal{C}_0}$ , then there is a coupling between $x_K$ and $y(K\delta)$ satisfying the distance bound
+
+$$
+\mathbb {E} [ \mathrm {d} (y (K \delta), x _ {K}) ] \leq e ^ {- \alpha K \delta + (q + L _ {\mathrm {R i c}} / 2) \mathcal {R} ^ {2} / 2} \mathbb {E} [ \mathrm {d} (y (0), x _ {0}) ] + \exp \left((q + L _ {\mathrm {R i c}} / 2) \mathcal {R} ^ {2}\right) \cdot \tilde {O} (\delta^ {1 / 2}).
+$$
+
+$\tilde{O}$ hides polynomial dependence on $L_{\beta}^{\prime},d,L_{R},\mathcal{R},\frac{1}{m - L_{\mathrm{Ric}} / 2},\log K,\log \frac{1}{\delta},$ and $\alpha \coloneqq \min \left\{\frac{m - L_{\mathrm{Ric}} / 2}{16},\frac{1}{2\mathcal{R}^2}\right\} \cdot e^{-\frac{1}{2} (q + L_{\mathrm{Ric}} / 2)\mathcal{R}^2}.$
+
+We defer the proof of Theorem 1 to Appendix A.4, where we state the explicit expressions for $\mathcal{C}_0$ .
+
+# Discussion of Theorem 1
+
+To sample from $d\pi^{*}(x) = e^{-h(x)}d\mathrm{vol}_{g}(x)$ , we let $\beta (x)\coloneqq -\frac{1}{2}\nabla h(x)$ ; under this choice of $\beta$ , $\pi^{*}(x)$ is invariant under the SDE for $y(t)$ . Picking $y(0)\sim \pi^{*}(x)$ , we thus ensure that $\operatorname {Law}(y(t)) = \pi^*$ for all $t$ . Therefore, the $W_{1}$ distance between $\operatorname {Law}(x_K)$ and $\pi^{*}$ is upper bounded by $\mathbb{E}[\mathrm{d}(y(K\delta),x_K)]$ , which is in turn upper bounded in Theorem 1.
+
+The distance bound consists of two terms: the first term is exponentially small in $K\delta$ , so it goes to 0 as the number of steps tends to infinity; the second term is proportional to $\delta^{1/2}$ . We first pick $\delta = \tilde{O}(\varepsilon^2)$ so that the second term is bounded by $\varepsilon$ . It then suffices to let $K = \frac{1}{\alpha\delta}\log\left(\frac{\mathbb{E}[\mathrm{d}(y(0),x_0)]}{\varepsilon}\right) + (q + L_{\mathrm{Ric}} / 2)\mathcal{R}^2 = \tilde{O}(\varepsilon^{-2})$ in order for the first term to be bounded by $\varepsilon$ . Note that by our assumptions and by Lemma 18 $\mathbb{E}[\mathrm{d}(y(0),x_0)] \leq poly(L_R,L_\beta',d,\mathcal{R},\frac{1}{m})$ .
+
+We now discuss a few specific cases for Assumption 2. The easiest setting is when $m > L_{\mathrm{Ric}} / 2$ and $\mathcal{R} = 0$ (in this case the value of $q$ does not matter); this occurs, for example, if $\beta = -\frac{1}{2}\nabla h$ for some $c$ -strongly-convex $h$ , and $M$ has positive Ricci curvature. The mixing rate is $\alpha = \frac{c - L_{\mathrm{Ric}}}{32}$ , and this closely relates to a well-known result by Bakry and Emery on the Log-Sobolev Inequality of $CD(\cdot, \infty)$ distributions:
+
+Theorem ([Bakry et al., 2014]) Let $\operatorname{Ric}$ denote the Ricci curvature tensor. If $d\pi^{*}(x) = e^{-h(x)}d\mathrm{vol}_{g}(x)$ , and $\nabla^2 h + \operatorname{Ric} \succ \rho I$ , then $\pi^{*}$ satisfies the Log-Sobolev Inequality (LSI) with parameter $\rho$ .
+
+When $\pi^{*}$ satisfies the $LSI(\rho)$ , it has been shown in [Bakry et al., 2014] that for any initialization, the KL divergence of $\mathrm{Law}(x(t))$ of (1.1) with respect to its stationary distribution converges to 0 with rate $\rho$ . In our example in the preceding paragraph, $d\pi^{*} = e^{-h}d\mathrm{vol}_{g}$ satisfies LSI with $\rho = c - L_{\mathrm{Ric}}$ , which is, up to a constant factor, equal to our mixing rate.
+
+The requirement $q + L_{\mathrm{Ric}} / 2 \geq 0$ is without loss of generality. If $q + L_{\mathrm{Ric}} / 2 < 0$ , we can take $q' = -L_{\mathrm{Ric}} / 2$ and verify that $\beta$ satisfies Assumption 2 with $(m, q', \mathcal{R})$ . Since $q' + L_{\mathrm{Ric}} / 2 = 0$ , the mixing rate is then $\alpha = \min \left\{\frac{m - L_{\mathrm{Ric}} / 2}{16}, \frac{1}{2\mathcal{R}^2}\right\}$ , which corresponds to the easy "CD(0,∞)" setting.
+
+A harder, but more general setting is when $\beta = \frac{1}{2}\nabla h$ for some non-convex $h$ , and $L_{\mathrm{Ric}} > 0$ , i.e. the manifold can have negative Ricci curvature. We will still need to assume that $\nabla h(x)$ is contractive for points which are further away than some radius $\mathcal{R}$ ; otherwise, the SDE (1.1) may drift off to infinity and $e^{-h}$ may not be integrable. Under Assumption 3, $\beta$ satisfies Assumption 2 with $m, L_{\beta}^{\prime}, \mathcal{R}$ . The mixing rate $\alpha$ is then proportional to $e^{-(L_{\beta}^{\prime} + L_{\mathrm{Ric}} / 2)\mathcal{R}^2}$ ; this can be very small if $h$ is nonconvex and highly nonsmooth, and the manifold $M$ has large negative Ricci curvature, leading to very slow mixing. This is generally unavoidable, even when $M$ is the flat Euclidean space.
+
+Readers familiar with the Holly-Stroock perturbation may find the exp $(q + L_{\text{Ric}} / 2) \mathcal{R}^2)$ term familiar: Let $M$ have diameter $\mathcal{R}$ and let $U$ have $2q$ -Lipschitz gradient, so that $\beta = \frac{1}{2} \nabla U$ satisfies Assumption 2 with $q$ . Then we can decompose $U = U_1 + U_2$ , where $U_1$ is $-L_{\text{Ric}}$ -strongly-convex and $U_2$ is a "perturbation" with magnitude $(2q + L_{\text{Ric}}) \mathcal{R}^2$ . $e^{2U_1} dvol_g$ satisfies $CD(0, \infty)$ and thus $e^{2U} dvol_g$ has Log-Sobolev constant scaling with $\exp((2q + L_{\text{Ric}}) \mathcal{R}^2)$ .
+
+Finally, on compact manifolds without boundary, one may take $\mathcal{R}$ to be the diameter of the manifold and upper bound the mixing rate $\alpha$ by $\alpha = \frac{1}{2\mathcal{R}^2} e^{-\frac{1}{2}(q + L_{\mathrm{Ric}} / 2)\mathcal{R}^2}$ .
+
+# 5.1 Proof Sketch of Theorem 1
+
+The proof of Theorem 1 consists of two steps. The first step is bounding the discretization error of (1.2); we have already done this in Lemma 1 in the previous section.
+
+The second step is showing that two paths of (1.1) converge. To do so, we consider $f(\mathrm{d}(x(t),y(t)))$ where $f$ is a Lyapunov function taken from [Eberle, 2016] (its exact form is given in Definition 2 in
+
+the Appendix). Two key property of $f$ are that (i) $\frac{1}{2} \exp \left( -(q + L_{\mathrm{Ric}} / 2)\mathcal{R}^2 / 2)r \leq f(r) \leq r \right.$ ; and (ii) $f'(r) \leq 1$ , so that convergence in $f(\mathrm{d}(x(t), y(t)))$ implies convergence in $\mathrm{d}(x(t), y(t))$ .
+
+Under the Kendall-Cranston Coupling $^3$ of $x(t)$ and $y(t)$ , one can show that $f(\mathrm{d}(x(t),y(t)))$ contracts with rate $\alpha$ . We quantify the contraction rate in Lemma 3 below. We stress that Lemma 3 is not new; it was first presented by Eberle [2016] (with minor variation), and its proof combines Theorem 6.6.2 of [Hsu, 2002] with the Lyapunov function analysis of [Eberle, 2016]. For completeness, we provide a proof of Lemma 3 in Appendix B.3.
+
+Lemma 3. Assume $\beta$ is $(m,q,\mathcal{R})$ -distant dissipative as per Assumption 2, and that is also satisfies Assumption 3. Further assume that $m > L_{\mathrm{Ric}} / 2$ and $q + L_{\mathrm{Ric}} / 2 \geq 0$ . Let $x(t)$ and $y(t)$ denote solutions to (1.1). Then there exists a Lyapunov function $f$ satisfying 1. $f(r) \geq \frac{1}{2} \exp \left(-\left(q + L_{\mathrm{Ric}} / 2\right) \mathcal{R}^2 / 2\right)r$ and 2. $|f'(r)| \leq 1$ , and a coupling between $x(t)$ and $y(t)$ , such that for all time $T$ ,
+
+$$
+\mathbb {E} [ f (\mathrm {d} (x (T), y (T))) ] \leq \exp (- \alpha T) f (\mathrm {d} (x _ {0}, y _ {0})),
+$$
+
+where $\alpha := \min \left\{\frac{m - L_{\mathrm{Ric}} / 2}{16}, \frac{1}{2\mathcal{R}^2}\right\} \cdot \exp \left(-\frac{1}{2}(q + L_{\mathrm{Ric}} / 2)\mathcal{R}^2\right)$ .
+
+Given these two steps, we can now sketch the proof of Theorem 1. Consider an arbitrary step $k$ of (1.2). For $t \in [k\delta, (k + 1)\delta)$ , let $\bar{x}(t)$ denote the solution to (1.1), initialized at $\bar{x}(k\delta)$ . Then by Lemma 3, $\mathbb{E}[f(\mathrm{d}(y((k + 1)\delta), \bar{x}((k + 1)\delta)))] \leq e^{-\alpha \delta} \mathbb{E}[f(\mathrm{d}(y(k\delta), x_k))]$ . On the other hand, by Lemma 1 $\mathbb{E}[\mathrm{d}(\bar{x}((k + 1)\delta), x_{k + 1})] \leq O(\delta^{3/2})$ . Summing these two bounds, applying triangle inequality, and using the fact that $f'(r) \leq 1$ , we get
+
+$$
+\mathbb {E} [ f (\mathrm {d} (y ((k + 1) \delta), x _ {k + 1})) ] \leq e ^ {- \alpha \delta} \mathbb {E} [ f (\mathrm {d} (y (k \delta), x _ {k})) ] + O \left(\delta^ {3 / 2}\right) \tag {5.1}
+$$
+
+Applying the above recursively for $k = 0 \dots K$ , we get
+
+$$
+\mathbb {E} [ f (\mathrm {d} (x _ {K}, y (K \delta))) ] \leq e ^ {- \alpha K \delta} \mathbb {E} [ f (\mathrm {d} (x _ {0}, y (0))) ] + \frac {1}{\alpha} O (\delta^ {1 / 2})
+$$
+
+Theorem 1 thus follows from the bounds $\frac{1}{2}\exp \left(-\left(q + L_{\mathrm{Ric}} / 2\right)\mathcal{R}^2 /2\right)r\leq f(r)\leq r$
+
+Lastly, we briefly mention a complication in the full proof that we omitted from the above sketch: the discretization error between $\bar{x}((k + 1)\delta)$ and $x_{k + 1}$ grows with $\|\beta(x_k)\|$ , which does not have a global upper bound. In practice, we can verify that $\mathrm{d}(x_k, x^*)$ is sub-Gaussian, so that with high probability $\mathrm{d}(x_k, x^*) \leq O(\log(k\delta))$ ; this in turn allows us to bound $\|\beta(x_k)\|$ via Assumption 3. This is the reason for the dependency on $\log K$ and $\log(1/\delta)$ in the iteration complexity of Theorem 1.
+
+# 6 Stochastic Gradient Langevin MCMC
+
+Finally, we bound the iteration complexity of process (2.1), which takes the Euler-Murayama scheme (1.2), and replaces $\beta(x_k)$ at step $k$ by a stochastic estimate $\tilde{\beta}_k(x_k)$ .
+
+Theorem 2 (Convergence of SGLD on Riemannian Manifold). Assume the manifold $M$ satisfies Assumptions 1 and 4. Assume in addition that there exists a constant $L_{R}^{\prime}$ such that for all $x \in M$ , $u, v, w, z, a \in T_xM$ , $\langle (\nabla_aR)(u,v)w,z\rangle \leq L_R^\prime \| u\| \| v\| \| w\| \| z\| \| a\|$ . Let $\beta$ be a vector field satisfying Assumptions 2 and 3; assume in addition that $m > L_{\mathrm{Ric}} / 2$ and that $\mathcal{R} = 0$ .
+
+Let $y(t)$ denote the exact geometric SDE given in (1.1). Let $x_{k}$ denote the stochastic Euler Murayama discretization (2.1), where $\tilde{\beta}_{k}$ denote independent random vector fields, with $\mathbb{E}[\tilde{\beta}(x)] = \beta(x)$ for all $x$ and $\| \beta(x) - \tilde{\beta}_{k}(x) \| \leq \sigma$ with probability 1.
+
+Let $K \in \mathbb{Z}^{+}$ be some iteration number and $\delta$ be some stepsize. There exists a constant $C_1 = \text{poly}(L_{\beta}', d, L_R, L'_R, \frac{1}{m}, \log K)$ , such that if $\delta \leq \frac{1}{C_1}$ , then there is a coupling between $x_K$ and $y(K\delta)$ satisfying the distance bound
+
+$$
+\mathbb {E} \left[ \mathrm {d} \left(y (K \delta), x _ {K}\right) ^ {2} \right] \leq e ^ {- \frac {1}{8} (m - L _ {\operatorname {R i c}} / 2) K \delta} \mathbb {E} \left[ \mathrm {d} \left(y (0), x _ {0}\right) ^ {2} \right] + \tilde {O} (\delta).
+$$
+
+$\tilde{O}$ hides polynomial dependence on $L_{\beta}^{\prime},d,L_{R},L_{R}^{\prime},\sigma ,\frac{1}{m - L_{\mathrm{Ric}} / 2},\log K,\log \frac{1}{\delta}.$
+
+We defer the proof of Theorem 2 to Appendix A.5, where we state the explicit expressions for $\mathcal{C}_1$ .
+
+# Discussion of Theorem 2
+
+To sample from $d\pi^{*}(x) = e^{-h(x)}d\mathrm{vol}_{g}(x)$ , we let $\beta (x)\coloneqq -\frac{1}{2}\nabla h(x)$ and let $y(0)\sim \pi^{*}(x)$ . The $W_{2}$ distance between $\operatorname {Law}(x_K)$ and $\pi^*$ is upper bounded by $\sqrt{\mathbb{E}[\mathrm{d}(y(K\delta),x_K)^2]}$ . To achieve $\varepsilon$ error in $W_{2}$ , Theorem 2 requires $\tilde{O} (\varepsilon^{-2})$ steps. The reasoning is very similar to Theorem 1.
+
+As already discussed in Section 2, the Assumption on Theorem 2 is considerably more restrictive than Theorem 1. We also highlight that the error bound in Theorem 2 does depend on $L_{R}^{\prime}$ , the derivative of the Riemannain curvature tensor. This is in contrast to Theorem 1, where $L_{R}^{\prime}$ does not appear in any of the bounds.
+
+Though the iteration complexity for Theorem 2 can be larger than Theorem 1 as it depends on additional parameters $\sigma$ and $L_R'$ , (2.1) may nonetheless be faster than (1.2). For example, let $h(x) = \frac{1}{N}\sum_{i=1}^{N}h_i(x)$ and assume $\|\nabla h_i - \nabla h_j\| \leq \sigma$ for all $i,j$ , one step of (2.1) can be performed with a single gradient computation for a single uniformly sampled $h_i$ , whereas (1.2) would require $N$ gradient computations.
+
+# Proof Sketch of Theorem 2 and Theoretical Highlights
+
+For any step $k$ , let us define $\bar{y}_{k+1} \coloneqq \mathrm{Exp}_{y(k\delta)}(\delta \beta(y(k\delta)) + \sqrt{\delta}\bar{\zeta}_k)$ , where $\bar{\zeta}_k \sim \mathcal{N}_{y_k}(0, I)$ . We show, in Lemma 8, that $\mathbb{E}[\mathrm{d}(x_{k+1}, \bar{y}_{k+1})^2] \leq (1 - \frac{\delta}{4}(m - L_{\mathrm{Ric}}/2))\mathbb{E}[\mathrm{d}(x_k, y(k\delta))^2] + 16\delta^2\sigma^2$ . On the other hand, once again applying Lemma 1, we can verify that $\mathbb{E}[\mathrm{d}(y((k+1)\delta), \bar{y}_{k+1})^2] \leq O(\delta^3)$ . By Young's inequality and triangle Inequality,
+
+$$
+\mathbb {E} [ \mathrm {d} (x _ {k + 1}, y ((k + 1) \delta)) ^ {2} ] \leq (1 - \frac {\delta}{8} (m - L _ {\mathrm {R i c}} / 2)) \mathbb {E} [ \mathrm {d} (x _ {k}, y (k \delta)) ^ {2} ] + O (\delta^ {2})
+$$
+
+The bound in Theorem 2 follows immediately from applying the above recursively for $k = 1 \dots K$ . We note that The contraction in Lemma 8 is in turn derived from Lemma 29, which may be of independent interest as it quantifies the distance evolution between two general discrete-time stochastic processes (which do not have to be diffusions or related to the Gaussian noise).
+
+It is elucidative to compare the proof structure of Theorem 2 with that of Theorem 1 above. On a high level, at step $k$ , Theorem 1 first approximates the discrete MCMC step $(x_{k + 1})$ by an exact SDE initialized at $x_{k}$ $(\bar{x} ((k + 1)\delta))$ . It then uses two facts: 1. $f(\mathrm{d}(\bar{x} (t),y(t)))$ contracts under the exact SDE, and 2. the approximation error between $x_{k + 1}$ and $\tilde{x} ((k + 1)\delta)$ is small. In contrast, at step $k$ , Theorem 2 first approximates the exact SDE $(y((k + 1)\delta))$ by a Euler-Murayama step $(\bar{y}_{k + 1})$ . It then uses two facts: 1. $\mathrm{d}(x_{k + 1},\bar{y} ((k + 1)\delta))$ contracts under the stochastic Euler-Murayama step, and 2. the approximation error between $\bar{y}_{k + 1}$ and $y((k + 1)\delta)$ is small. The reason for this change is to make use of the fact that $\mathbb{E}[\tilde{\beta}_k] = \beta$ , conditioned on the randomness up to time $k\delta$ . Suppose we had followed the proof of Theorem 1 and defined $\bar{x} (t)$ to be the solution to the exact SDE, with drift $\tilde{\beta}_k$ , then showing contraction of the exact SDE becomes very tricky as $\mathbb{E}[\tilde{\beta}_k]$ is not equal to $\beta$ when conditioned on $\bar{x} (t)$ for any $t > k\delta$ .
+
+# 7 Acknowledgements
+
+Xiang Cheng acknowledge support from NSF BIGDATA grant (1741341) and NSF CCF-2112665 (TILOS AI Research Institute). Jingzhao Zhang acknowledges support by Tsinghua University Initiative Scientific Research Program.
+
+# References
+
+P-A Absil and Jérôme Malick. Projection-like retractions on matrix manifolds. SIAM Journal on Optimization, 22(1):135-158, 2012.
+P-A Absil, Robert Mahony, and Rodolphe Sepulchre. Optimization algorithms on matrix manifolds. Princeton University Press, 2009.
+Kwangjun Ahn and Sinho Chewi. Efficient constrained sampling via the mirror-langevin algorithm. Advances in Neural Information Processing Systems, 34, 2021.
+
+Miroslav Bacák. Convex analysis and optimization in Hadamard spaces. de Gruyter, 2014.
+Dominique Bakry, Ivan Gentil, Michel Ledoux, et al. Analysis and geometry of Markov diffusion operators, volume 103. Springer, 2014.
+Nawaf Bou-Rabee, Andreas Eberle, and Raphael Zimmer. Coupling and convergence for hamiltonian monte carlo. The Annals of applied probability, 30(3):1209-1250, 2020.
+Nicolas Boumal. An introduction to optimization on smooth manifolds. To appear with Cambridge University Press, Jan 2022. URL http://www.nicolasboumal.net/book.
+Xiang Cheng, Dong Yin, Peter Bartlett, and Michael Jordan. Stochastic gradient and Langevin processes. In International Conference on Machine Learning, pages 1810-1819. PMLR, 2020.
+Sinho Chewi, Thibaut Le Gouic, Chen Lu, Tyler Maunu, Philippe Rigollet, and Austin Stromme. Exponential ergodicity of mirror-langevin diffusions. Advances in Neural Information Processing Systems, 33:19573-19585, 2020.
+Alain Durmus and Eric Moulines. Nonasymptotic convergence analysis for the unadjusted Langevin algorithm. The Annals of Applied Probability, 27(3):1551-1587, 2017.
+Andreas Eberle. Reflection couplings and contraction rates for diffusions. *Probability theory and related fields*, 166(3):851-886, 2016.
+Ramesh Gangolli. On the construction of certain diffusions on a differentiable manifold. Zeitschrift für Wahrscheinlichkeitstheorie und Verwandte Gebiete, 2(5):406-419, 1964.
+Khashayar Gatmiry and Santosh S Vempala. Convergence of the riemannian langevin algorithm. arXiv preprint arXiv:2204.10818, 2022.
+Mark Girolami and Ben Calderhead. Riemann manifold Langevin and Hamiltonian Monte Carlo methods. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 73(2): 123-214, 2011.
+Jackson Gorham, Andrew B Duncan, Sebastian J Vollmer, Lester Mackey, et al. Measuring sample quality with diffusions. Annals of Applied Probability, 29(5):2884-2928, 2019.
+Elton P Hsu. Stochastic analysis on manifolds. Number 38. American Mathematical Soc., 2002.
+Erik Jørgensen. The central limit problem for geodesic random walks. Zeitschrift für Wahrscheinlichkeitstheorie und verwandte Gebiete, 32(1):1-64, 1975.
+Jürgen Jost. Riemannian geometry and geometric analysis. Springer, seventh edition, 2008.
+Hermann Karcher. Riemannian center of mass and mollifier smoothing. Communications on pure and applied mathematics, 30(5):509-541, 1977.
+John M Lee. Riemannian manifolds: an introduction to curvature, volume 176. Springer Science & Business Media, 2006.
+Yin Tat Lee and Santosh S Vempala. Geodesic walks in polytopes. In Proceedings of the 49th Annual ACM SIGACT Symposium on theory of Computing, pages 927-940, 2017.
+Yin Tat Lee and Santosh S Vempala. Convergence rate of Riemannian Hamiltonian Monte Carlo and faster polytope volume computation. In Proceedings of the 50th Annual ACM SIGACT Symposium on Theory of Computing, pages 1115-1121, 2018.
+Mufan Bill Li and Murat A Erdogdu. Riemannian Langevin algorithm for solving semidefinite programs. arXiv preprint arXiv:2010.11176, 2020.
+Ruilin Li, Molei Tao, Santosh S Vempala, and Andre Wibisono. The mirror langevin algorithm converges with vanishing bias. In International Conference on Algorithmic Learning Theory, pages 718-742. PMLR, 2022.
+Oren Mangoubi and Aaron Smith. Rapid mixing of geodesic walks on manifolds with positive curvature. The Annals of Applied Probability, 28(4):2501-2543, 2018.
+Ankur Moitra and Andrej Risteski. Fast convergence for Langevin diffusion with manifold structure. arXiv preprint arXiv:2002.05576, 2020.
+Michelle Muniz, Matthias Ehrhardt, Michael Gunther, and Renate Winkler. Higher strong order methods for Itô SDEs on matrix Lie groups. arXiv preprint arXiv:2102.04131, 2021.
+Sam Patterson and Yee Whye Teh. Stochastic gradient Riemannian Langevin dynamics on the probability simplex. In NIPS, pages 3102-3110, 2013.
+Peter Petersen. Riemannian geometry, volume 171. Springer Science & Business Media, 2006.
+
+Marc J Piggott and Victor Solo. Geometric Euler-Maruyama schemes for stochastic differential equations in $\mathrm{SO}(n)$ and $\mathrm{SE}(n)$ . SIAM Journal on Numerical Analysis, 54(4):2490-2516, 2016.
+Yue Sun, Nicolas Flammarion, and Maryam Fazel. Escaping from saddle points on Riemannian manifolds. arXiv preprint arXiv:1906.07355, 2019.
+Constantin Udriste. Convex functions and optimization methods on Riemannian manifolds, volume 297. Springer Science & Business Media, 2013.
+Xiao Wang, Qi Lei, and Ioannis Panageas. Fast convergence of Langevin dynamics on manifold: Geodesics meet log-sobolev. Advances in Neural Information Processing Systems, 33:18894-18904, 2020.
+Max Welling and Yee W Teh. Bayesian learning via stochastic gradient Langevin dynamics. In Proceedings of the 28th international conference on machine learning (ICML-11), pages 681-688. CiteSeer, 2011.
+Hongyi Zhang and Suvrit Sra. First-order methods for geodesically convex optimization. In Conference on Learning Theory, pages 1617-1638. PMLR, 2016.
+Kelvin Shuangjian Zhang, Gabriel Peyré, Jalal Fadili, and Marcelo Pereyra. Wasserstein control of mirror langevin monte carlo. In Conference on Learning Theory, pages 3814-3841. PMLR, 2020.
\ No newline at end of file
diff --git a/efficientsamplingonriemannianmanifoldsvialangevinmcmc/images.zip b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..6dffb628711d3ab2e6b50c704f84209ad6561e1d
--- /dev/null
+++ b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e6c56dab39b4a9dfd3ae02803e6b72785a3f6f0d34c59bcc29ccb565f2b022a9
+size 203221
diff --git a/efficientsamplingonriemannianmanifoldsvialangevinmcmc/layout.json b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..5059a9d2501552ed81d91f088efb8c5a72c2ba98
--- /dev/null
+++ b/efficientsamplingonriemannianmanifoldsvialangevinmcmc/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5ee36e6c55ba685d88173d5e23ad2bffbe771b1d082b4a9e145f8b5e37597dd4
+size 791437
diff --git a/efficientschedulingofdataaugmentationfordeepreinforcementlearning/9f2b3377-2669-451e-a671-a4bd9afd6eee_content_list.json b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/9f2b3377-2669-451e-a671-a4bd9afd6eee_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..0a1463e9e0dc04e14286b46fc7d49d45b56adb42
--- /dev/null
+++ b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/9f2b3377-2669-451e-a671-a4bd9afd6eee_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3edb8f4a593aef6e02ddf6e1b26856c4be739aecaf282ee45e695f871a21a477
+size 80166
diff --git a/efficientschedulingofdataaugmentationfordeepreinforcementlearning/9f2b3377-2669-451e-a671-a4bd9afd6eee_model.json b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/9f2b3377-2669-451e-a671-a4bd9afd6eee_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..0befcd3a565dba89ec585ec9a7a5f50b4125d286
--- /dev/null
+++ b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/9f2b3377-2669-451e-a671-a4bd9afd6eee_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0f8d768be728af8c96505da7160704f4150ad9eda778ae47dc4246d43cb3ab6b
+size 106102
diff --git a/efficientschedulingofdataaugmentationfordeepreinforcementlearning/9f2b3377-2669-451e-a671-a4bd9afd6eee_origin.pdf b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/9f2b3377-2669-451e-a671-a4bd9afd6eee_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..f51d207644d919de61f4a82bcb3f4a3186199d31
--- /dev/null
+++ b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/9f2b3377-2669-451e-a671-a4bd9afd6eee_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:df3e13c4f1c5d98c4733a8da99a63a46d5ef3264e4da49cc4784ba23704e0860
+size 634633
diff --git a/efficientschedulingofdataaugmentationfordeepreinforcementlearning/full.md b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..3cb034fca603d7fc74fca92f942a1fba838af492
--- /dev/null
+++ b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/full.md
@@ -0,0 +1,345 @@
+# Efficient Scheduling of Data Augmentation for Deep Reinforcement Learning
+
+Byungchan Ko*
+
+NALBI
+
+kbc@nalbi.ai
+
+Jungseul Ok
+
+GSAI, POSTECH
+
+jungseul@postech.ac.kr
+
+# Abstract
+
+In deep reinforcement learning (RL), data augmentation is widely considered as a tool to induce a set of useful priors about semantic consistency and to improve sample efficiency and generalization performance. However, even when the prior is useful for generalization, distilling it to RL agent often interferes with RL training and degenerates sample efficiency. Meanwhile, the agent is forgetful of the prior due to the non-stationary nature of RL. These observations suggest two extreme schedules of distillation: (i) over the entire training; or (ii) only at the end. Hence, we devise a stand-alone network distillation method to inject the consistency prior at any time (even after RL), and a simple yet efficient framework to automatically schedule the distillation. Specifically, the proposed framework first focuses on mastering train environments regardless of generalization by adaptively deciding which or no augmentation to be used for the training. After this, we add the distillation to extract the remaining benefits for generalization from all the augmentations, which requires no additional new samples. In our experiments, we demonstrate the utility of the proposed framework, in particular, that considers postponing the augmentation to the end of RL training. https://github.com/kbc-6723/es-da
+
+# 1 Introduction
+
+Deep reinforcement learning (RL) aims at finding a neural network to represent policy or value functions taking raw observation as input, of which the most common form in practice is visual data or images of high-dimensionality, e.g., video games [23], board games [29, 28], and robot controls [32, 18]. RL handling high-dimensional input often suffers from poor sample efficiency and generalization capability, mainly due to the curse of dimensionality [4, 15]. To overcome these issues, it has been widely considered to augment data based on prior knowledge that a set of transformations preserve the meaning or context of input observations, e.g., cropping out unimportant parts of images, and changing colors [20, 19, 21, 14]. On one hand, RL agent can be directly fed with the original and augmented data so that it implicitly learns a representation with the prior and improves the sample efficiency and generalization [20]. On the other hand, the prior knowledge in data augmentation can be explicitly distilled via a self-supervised learning, which introduces additional regularization to ensure consistency between responses to original and augmented inputs [25, 14].
+
+However, data augmentation shows highly task-dependent effect in RL, and it is prone to generate severe interference with the training even when it truly conveys a useful prior to train and test environments [20, 25, 14]. We address the problem of alleviating the interference between data augmentation and RL training to improve sample efficiency for acquainting train tasks, and generalization capability for unseen test environments. This problem in (online) RL is more critical and challenging than that in supervised learning (SL) since the objective function and data distribution are time-varying in RL,
+
+while they are not in SL. Indeed, according to [1, 10], it is sufficient to partly apply data augmentation just for a short period of SL at any time. Meanwhile, we empirically observe that the prior from data augmentation can be easily forgotten in RL of the non-stationary nature (see Section 5.3), i.e., the effect of augmentation is time-sensitive.
+
+Based on our observation about the interference and the time-sensitivity, we propose two simple yet effective methods according to timings of data augmentation: Intra Distillation with Augmented observations (InDA) and Extra Distillation with Augmented observations (ExDA). Data augmentation beneficial for the sample efficiency needs to be applied over the entire RL training, i.e., InDA. Conversely, data augmentation useful only for the generalization should be postponed to the end of RL training, i.e., ExDA, so that we can minimize the interference in the training, while enjoying the benefit in the testing. InDA and ExDA are equipped with Distillation with Augmented observation (DA). DA is a stand-alone self-supervised learning which enables us to induce the prior after RL training, and shows a relatively small interference with RL training by explicitly preserving the response of RL agent to the original input.
+
+The best timing (InDA or ExDA) depends on traits of train task and augmentation. We hence suggest a framework of adaptive scheduling, named UCB-ExDA, that (i) first aims at maximizing the sample efficiency by adaptively selecting which or no augmentation to be used during RL training; and then, (ii) distill the priors from all the augmentations after RL training. Specifically, inspired by [25], we devise UCB-InDA for the adaptive selection in the first part by modifying the upper confidence bound (UCB) algorithm [3] for multi-armed bandit, where differently from [25], the set of arms includes all the augmentations and the option to not augment. In summary, UCB-ExDA is nothing but executing UCB-InDA followed by ExDA. Our experiment demonstrates the utility of the proposed framework.
+
+Our contributions are summarized as follows:
+
+(i) We devise DA (Section 4.1) which explicitly preserves the knowledge of RL agent so that enables distilling the consistency prior of augmentation into RL agent not only during but also after RL training, while other methods [20, 25, 14] need to be applied concurrently with RL training and thus show relatively strong interference in our experiments (Section 5.2).
+(ii) We identify the simple yet effective timings of data augmentation: either InDA or ExDA (Section 4.2, Section 4.3), based upon the discovery of the time-sensitivity (Section 5.3) that has not been observed in SL [10], i.e., the proposed timings are effective particularly for RL.
+(iii) We finally establish UCB-ExDA which automatically decides the best timing of augmentation, and demonstrate its superiority compared to others (Section 5.4). The advantage of UCB-ExDA is particularly substantial when the best strategy is ExDA postponing augmentation to the end of RL training.
+
+# 2 Related Works
+
+Augmented experience in RL. To solve the problem of poor generalization and sparse data, a popular approach is to fabricate virtual experiences and train the RL agent to learn with them. Domain randomization is a technique to produce such experiences from a simulator of a targeted system, [32, 24, 26]. Accurate simulators of practical systems are difficult to obtain, and it has limited applicability. However, visual augmentation has no such limit because the method uses simple image transformations such as cropping, tilting, and color jitter, although applications require a careful understanding of the targeted system to guide the design of an appropriate image transformer. A method of curriculum learning for domain randomization, in which the difficulty is gradually increasing [26] provided insights that coincide with some of our findings. However, we provide a further understanding of the types of visual augmentation that should be early or late during training.
+
+Regularization from augmented data in vision-based RL has been implemented in various learning frameworks, including but not limited to representation [14, 31], self-supervised [25], and contrast [30]. One proposed algorithm [25] applies the UCB algorithm [3] to automatically select the most effective augmentations over RL training, where each augmentation is considered as an arm and then evaluate the effectiveness of augmentation by using a sliding window average. The idea of adapting augmentation concurs with our main message regarding the timing of augmentation. In [25], 'not augmenting' is not an option, whereas our findings indicate that it should be. In addition, [25] does not consider post augmentation followed by RL training, as in ExDA.
+
+Other time-sensitivity in deep learning. During deep learning, the early stage of training often has a significant effect [7, 1]. Therefore, we devised time-sensitive methods that adapt to the progress of training, such as learning rate decay [35] and curriculum learning [33]. Golatkar et al. [10] studied such a time-sensitivity of regularization techniques for SL, where the effect of data augmentation in different time does not change much. We find that the time-sensitivity of augmentation can be significant in RL. This contrast may occur because of the non-stationary nature of RL, which SL does not have. Although a set of techniques originally developed for SL such as convolutional neural network, weight decay, batch normalization, dropout and self-supervised learning improve deep RL [16, 6, 22, 8, 30, 34, 13], a thorough study should be conducted before introducing a method from different learning frameworks, because we find the contrasting time-sensitivities of data augmentation. This spirit is also shared with an application [17] of implicit bias in SL [12, 2, 9] to RL.
+
+# 3 Background
+
+Notation. We consider a standard agent-environment interface of vision-based reinforcement learning in a discrete Markov decision process of state space $S$ , action space $\mathcal{A}$ , and kernel $P = P(s_{t+1}, r_t | s_t, a_t)$ which determines the state transition and reward distribution. The goal of the RL agent is to find a policy that maximizes the expectation of cumulative reward $\sum_{t=0}^{t' - 1} \gamma^t r_t$ , where $t'$ is terminating time and $\gamma \in [0,1]$ is discount factor. At each timestep $t$ , the agent selects an action $a_t \in \mathcal{A}$ and receives a reward $r_t$ and an image $o_{t+1} = O(s_{t+1}) \in \mathbb{R}^{k \times k'}$ as an observation of the next state $s_{t+1}$ . Data augmentation can be described by an image transformation function $\phi: \mathbb{R}^{k \times k'} \mapsto \mathbb{R}^{k \times k'}$ of which output is presumed to have the same or similar semantics of the input.
+
+Baseline RL algorithm. Throughout this paper, we use Proximal Policy Optimization (PPO) [27] as a baseline, although we believe our findings and methods can be easily adjusted to others. PPO is a representative on-policy RL algorithm to learn policy $\pi_{\theta}(a \mid o)$ and value function $V_{\theta}$ of neural agent parameterized by $\theta$ . Storing a set of recent transitions $\tau_t \coloneqq (o_t, a_t, r_t, o_{t+1})$ in experience buffer $\mathcal{D}$ , the agent is updated to minimize the following loss function:
+
+$$
+L _ {\mathrm {P P O}} (\theta) = - L _ {\pi} (\theta) + \alpha L _ {V} (\theta), \tag {1}
+$$
+
+where $\alpha$ is a hyperparameter and canonical regularization terms are omitted. The clipped policy objective function $L_{\pi}$ and value loss function $L_{V}$ are defined as:
+
+$$
+L _ {\pi} (\theta) = \hat {\mathbb {E}} \left[ \min \left(\rho_ {t} (\theta) \hat {A} _ {t}, \operatorname {c l i p} \left(\rho_ {t} (\theta), 1 - \epsilon , 1 + \epsilon\right) \hat {A} _ {t}\right) \right] \tag {2}
+$$
+
+$$
+L _ {V} (\theta) = \hat {\mathbb {E}} \left[ \left(V _ {\theta} \left(o _ {t}\right) - V _ {t} ^ {\operatorname {t a r g}}\right) ^ {2} \right], \tag {3}
+$$
+
+where the expectation $\hat{\mathbb{E}}$ is taken with respect to $\tau_t \sim \mathcal{D}$ , we denote by $\theta_{\mathrm{old}}$ the parameter before the update, $\rho_t(\theta)$ is the importance ratio $\frac{\pi_\theta(a_t|o_t)}{\pi\vartheta_{\mathrm{old}}(a_t|o_t)}$ , and $\hat{A}_t$ is the generalized advantage estimation [27].
+
+# 4 Method
+
+In what follows, we present our methods: Distillation with Augmented observations (DA; Section 4.1), Intra DA (InDA; Section 4.2), Extra DA (ExDA; Section 4.3), and then the adaptive scheduling frameworks based on UCB (UCB-InDA and UCB-ExDA; Section 4.4). DA is a stand-alone knowledge distillation method, which can be used at any time to instill the underlying prior of augmentation into a given RL agent. InDA and ExDA conduct either DA or PPO in each epoch but have different schedules (Figure 1), where InDA interleaves PPO and DA, whereas ExDA performs PPO first then DA. UCB-InDA adaptively decides which or no augmentation to be used in each DA epoch of InDA based on the UCB of estimated gain from each option. UCB-ExDA performs ExDA preceded by UCB-InDA.
+
+# 4.1 Distillation with augmented observations (DA)
+
+The underlying prior of augmentation can be infused by minimizing a measure of inconsistency between the agent's responses to original and augmented inputs (resp. $o_t$ and $\phi(o_t)$ ). For instance,
+
+
+Figure 1: An illustration of InDA and ExDA
+
+
+Figure 2: An illustration of distillation losses.
+
+with PPO agent learning policy $\pi_{\theta}$ and value $V_{\theta}$ , Raileanu et al. [25] proposes the following measure:
+
+$$
+L _ {\mathrm {d i s}} (\theta , \phi) := \hat {\mathbb {E}} _ {o _ {t} \sim \mathcal {D}} \left[ \mathrm {K L} \left[ \pi_ {\theta} \left(\cdot | o _ {t}\right), \pi_ {\theta} \left(\cdot | \phi (o _ {t})\right) \right] \right] + \hat {\mathbb {E}} _ {o _ {t} \sim \mathcal {D}} \left[ \left(V _ {\theta} (o _ {t}) - V _ {\theta} \left(\phi (o _ {t})\right)\right) ^ {2} \right], \tag {4}
+$$
+
+which uses Kullback-Leibler divergence (first term) and mean squared deviation (second term) for policy and value inconsistencies, respectively. Noting that $L_{\mathrm{dis}}(\theta; \phi)$ can be minimized to be zero by a constant response to all inputs, the distillation with Eq (4) can distort the RL agent, in particular, when applying it outside of RL training.
+
+We hence devise a network distillation technique (DA) which explicitly preserves the RL agent's response to original input and thus is applicable even after RL training. DA distills the knowledge of RL agent $\theta_{\mathrm{old}}$ into $\theta$ using not only original but also augmented observations. More formally, the loss of DA is written as:
+
+$$
+L _ {\mathrm {D A}} (\theta , \phi ; \theta_ {\text {o l d}}) := L _ {\text {d i s}} (\theta , \mathbb {I}; \theta_ {\text {o l d}}) + L _ {\text {d i s}} (\theta , \phi ; \theta_ {\text {o l d}}). \tag {5}
+$$
+
+We here denote the identity transformation by $\mathbb{I}$ such that $\mathbb{I}(o) = o$ for all $o$ , and extend the definition of $L_{\mathrm{dis}}$ in Eq (4) as follows:
+
+$$
+L _ {\mathrm {d i s}} (\theta , \phi ; \theta_ {\mathrm {o l d}}) = \hat {\mathbb {E}} _ {o _ {t} \sim \mathcal {D}} \left[ \right. \mathrm {K L} \left[ \pi_ {\theta_ {\mathrm {o l d}}} (\cdot | o _ {t}), \pi_ {\theta} (\cdot | \phi (o _ {t})) ] \right] + \hat {\mathbb {E}} _ {o _ {t} \sim \mathcal {D}} \left[\left(V _ {\theta_ {\mathrm {o l d}}} (o _ {t}) - V _ {\theta} (\phi (o _ {t}))\right) ^ {2} \right]. \tag {6}
+$$
+
+In Eq (5), the first term ensures that $\theta$ and $\theta_{\mathrm{old}}$ behave identically for the original inputs, and the second one infuses the consistency prior. In Figure 2, $L_{\mathrm{dis}}(\theta, \mathbb{I}; \theta_{\mathrm{old}})$ , $L_{\mathrm{dis}}(\theta, \phi; \theta_{\mathrm{old}})$ , and $L_{\mathrm{dis}}(\theta, \phi; \theta)$ graphically correspond to (A), (B), and (C), respectively. From this, it follows that minimizing $L_{\mathrm{DA}}$ in Eq (5) eventually reduces $L_{\mathrm{dis}}(\theta, \phi; \theta)$ in Eq (4). In addition, the minimization of $L_{\mathrm{DA}}$ secures the responses of $\theta$ to the original inputs (which can be pre-computed to reduce computation cost) to the those of $\theta_{\mathrm{old}}$ , while the alternatives (e.g., (A)+(C): $L_{\mathrm{dis}}(\theta, \mathbb{I}; \theta_{\mathrm{old}}) + L_{\mathrm{dis}}(\theta, \phi; \theta)$ ) does not and thus may generate interference with RL training. Our experiments (Section 5.2; Figure 4) justifies the design of DA by showing substantial advantage compared to the other alternatives such as DrAC [25] using $L_{\mathrm{dis}}(\theta, \phi; \theta)$ in Eq (4). We note that this advantage becomes much clearer when a wrong augmentation is given, c.f., the supplementary material.
+
+# 4.2 Intra distillation with augmented observations
+
+InDA (Algorithm 1) alternates between minimizing $L_{\mathrm{PPO}}$ and $L_{\mathrm{DA}}$ , i.e., PPO and DA are explicitly separated, whereas they are often executed simultaneously in other methods [25]. Such a clear separation reduces the interference [14]. We can control the frequency and timing of applying distillation with hyperparameters $I$ , $S$ and $T$ , where we perform DA after each $I$ rounds of RL training only if the current epoch $n$ is in the interval of $[S,T]$ , i.e., $S$ and $T$ are the epochs to begin and terminate DA, respectively. We vary $S$ and $T$ to study the time-dependency of data augmentation. We denote InDA[ $S,T$ ] to indicate the period to apply DA, while we omit the indication when DA is applied over the entire period. We provide further details on InDA in the supplementary material.
+
+# Algorithm 1 InDA
+
+Require: $N,I,\phi ,S,T$
+
+1: Initialize $\theta$ close to origin.
+2: for $n = 1,2,\ldots ,N$ do
+3: // RL training
+4: Store sampled transitions to $\mathcal{D}$
+5: Optimize RL objective $L_{\mathrm{PPO}}(\theta)$ with $\mathcal{D}$
+6: // Distillation
+7: if $n \in [S, T]$ and $\mathrm{mod}(n - 1, I) = 0$ then
+8: Store $\theta_{\mathrm{old}}\gets \theta$
+9: Minimize $L_{\mathrm{DA}}(\theta)$ for $\mathcal{D}$ , $\theta_{\mathrm{old}}$ and $\phi$ ;
+0: end if
+11: end for
+
+# Algorithm 2 ExDA
+
+Require: $N,M,\phi$
+
+1: Initialize $\theta$ close to origin.
+2: //Pre-training phase with RL algorithm
+3: for $n = 1,2,\ldots ,N$ do
+4: Store sampled transitions to $\mathcal{D}$
+5: Optimize RL objective $L_{\mathrm{PPO}}(\theta)$ with $\mathcal{D}$
+6: end for
+7:
+8: Store $\theta_{\mathrm{old}} \gets \theta$
+9: // Distillation at the end of RL training
+0: for $m = 1,2,\ldots ,M$ do
+11: Minimize $L_{\mathrm{DA}}(\theta)$ for $\mathcal{D}$ , $\theta_{\mathrm{old}}$ and $\phi$ ;
+12: end for
+
+# 4.3 Extra distillation with augmented observations
+
+ExDA (Algorithm 2) performs the distillation after the end of RL training, where the lengths of DA and RL training are parameterized by $M$ and $N$ , respectively. We note that computational cost can be reduced by removing the value inconsistency measure $\tilde{\mathbb{E}}_{o_t\sim \mathcal{D}}\left[(V_{\theta_{old}}(o_t) - V_\theta (\phi (o_t)))^2\right]$ from $L_{\mathrm{dis}}$ in Eq (6) because the value consistency is not necessary for RL training nor distillation in the actor-critic framework and including it has a potential risk of generating additional interference. In the supplementary material, it is empirically verified that this reduction does not degrade RL performance. We leave more interesting details in the supplementary. For instance, one can consider re-initializing $\theta$ before starting DA as a part of exploiting the implicit bias [12, 17] to improve generalization. However, test performance is often dropped. This is mainly because the dataset to distill $\pi_{\theta_{old}}$ has much less diversity than that observed along the trajectory. Thus, we use no re-initialization for the experiments in the main paper.
+
+# 4.4 UCB-based adaptive scheduling frameworks
+
+The training benefit by augmentation differs depending on the task. This dependency complicates the choice of whether to use InDA or ExDA for augmentation. Hence, we devise an auto-augmentation method, called UCB-InDA, inspired by UCB-DrAC [25], where each augmentation is corresponded to an arm in multi-armed bandit (MAB) problem and assessed its potential gain in training with upper confidence bound (UCB) [3]. More formally, in UCB-InDA, the set of arms is the set of augmentations, $\Phi = \{\phi_1,\dots ,\phi_K\}$ , which must include the identity function $\mathbb{I}$ , i.e., the option not to augment. The inclusion of identity function is small but makes crucial difference than UCB-DrAC [25] since we observe that using augmentation sometimes needs to be postponed after RL training for the sake of better sampling complexity and test performance.
+
+A round of MAB corresponds to every $I$ epoch of InDA, where we let $\phi_{k(s)}\in \Phi$ be the augmentation selected at the $s$ -th round of DA. Let $G(s)$ be the average return, the sum of estimated advantage $\hat{A}$ and predicted value $V_{\theta}$ , over $(I - 1)$ epochs of PPO followed by the $s$ -th DA. UCB algorithm assumes that each arm generates reward independently drawn from a fixed distribution, and estimates the empirical mean over the entire sampling process. However, in RL, the return $G(s)$ is non-stationary, so UCB-InDA computes moving average gain $\bar{G}_k(s)$ , instead, taken over a certain number (chosen to be 3 in our experiment) of most recent rounds selecting $\phi_k$ as Raileanu et al. [25] proposed. Then, inspired by UCB1 algorithm [3], UCB-InDA selects action $k(s)$ at round $s$ as follows:
+
+$$
+k (s) = \underset {k \in \{1, \dots , K \}} {\arg \max } \bar {G} _ {k} (s) + c \sqrt {\frac {\log (s)}{N _ {k} (s)}} \tag {7}
+$$
+
+where $c$ is the UCB exploration coefficient, and $N_{k}(s)$ is the number of times selecting $\phi_{k}$ up to round $s$ . We refer to the supplementary material for the hyperparameter choice. We remark that compared to UCB-DrAC [25], the proposed UCB-InDA has subtle but important differences, summarized in two folds: (i) the inclusion of identity transformation (i.e., no augmentation) and (ii) the distillation with
+
+
+(a) non-conflicting: $\langle g_{\mathrm{aux}},g_{\mathrm{main}}\rangle \geq 0$
+
+
+(b) conflicting: $\langle g_{\mathrm{aux}},g_{\mathrm{main}}\rangle < 0$
+Figure 3: An illustration of gradient conflicting and PAGrad. We here let $g_{\mathrm{main}}$ and $g_{\mathrm{aux}}$ denote the gradients of main (shown in red; e.g., $\nabla L_{\mathrm{PPO}}$ ) and auxiliary (shown in blue; e.g., $\nabla L_{\mathrm{dis}}$ ) losses, respectively. In the computation of PAGrad (shown in black), the component of $g_{\mathrm{aux}}$ conflicting to $g_{\mathrm{main}}$ only when it exists (i.e., $\langle g_{\mathrm{aux}}, g_{\mathrm{main}} \rangle < 0$ ).
+
+augmentation via InDA. The gain of each component is numerically studied in Section 5. Finally, we note that UCB-ExDA is nothing but UCB-InDA followed by ExDA.
+
+# 4.5 PAGrad
+
+Inspired by [36], we devise an alternative approach to reduce the interference by interpreting RL training with data augmentation as a multi-task learning, where $L_{\mathrm{PPO}}$ and $L_{\mathrm{dis}}$ correspond to the main and auxiliary task losses, respectively. In [36], the degree of conflict from task A to task B is estimated by the inner product of the gradient of task A and the negative gradient of task B, c.f., Figure 3. From this, we propose PAGrad (Projecting Auxiliary Gradient) to compute a modified gradient of $L_{\mathrm{PPO}}$ excluding the conflict from the auxiliary gradient $\nabla L_{\mathrm{dis}}$ to the main one $\nabla L_{\mathrm{PPO}}$ . Formally, PAGrad computes the gradient given as follows:
+
+$$
+\nabla L _ {\mathrm {P P O}} + \left(\nabla L _ {\mathrm {d i s}} - \frac {\min \{0 , \langle \nabla L _ {\mathrm {d i s}} , \nabla L _ {\mathrm {P P O}} \rangle \}}{\| \nabla L _ {\mathrm {P P O}} \| ^ {2}} \nabla L _ {\mathrm {P P O}}\right), \tag {8}
+$$
+
+where $\frac{\min\{0, \langle\nabla L_{\mathrm{dis}}, \nabla L_{\mathrm{PPO}}\rangle\}}{\|\nabla L_{\mathrm{PPO}}\|^2} \nabla L_{\mathrm{PPO}}$ is the components of $\nabla L_{\mathrm{dis}}$ opposite to $\nabla L_{\mathrm{PPO}}$ which may disturb optimizing the main objective $L_{\mathrm{PPO}}$ . Based on this, we devise $\mathrm{DrAC + PAGrad}$ that updates the model parameter toward the negative direction of (8). This is an alternative of InDA, while it concurrently optimizes $L_{\mathrm{PPO}}$ and $L_{\mathrm{dis}}$ differently from InDA adopting the time-separation of optimizing $L_{\mathrm{PPO}}$ and $L_{\mathrm{dis}}$ . We also note that it differs from the original method proposed in [36] alternating the main and auxiliary tasks to accomplish every task at equal priority, while we have a clear priority on RL task.
+
+# 5 Experiment
+
+# 5.1 Setups
+
+Train and test tasks. We use the OpenAI Progen benchmark of 16 video games [5], where a main character tries to achieve a specific goal, e.g., finding exit (Maze) or collecting coins (Coinrun), while avoiding enemies given a 2D map. At each time $t$ , visual observation $o_t$ is given as an image of size $64 \times 64$ . A train or test task is to achieve a high score on a set of environments configured by game and mode, where a mode describes predefined sets of levels (e.g., complexity of map) and backgrounds. Cobbe et al. [5] provide easy mode for each game, consisting of 200 levels and a certain set of backgrounds.
+
+We simplify easy mode and train agents in easybg mode, of which the only difference from easy mode [5] is showing only a single background. This is useful to investigate the case that using visual augmentation is helpful for testing but not for training. We denote the task configuration by game_name(mode), e.g., Coinrun(easybg). Then, we evaluate generalization capabilities using two modes: test-bg and test-lv, which contain unseen backgrounds and levels, respectively, in addition to easybg mode that we use for training.
+
+Types of augmentation. For clarity, we mainly focus on two types of visual augmentation, each of which conveys distinguishing inductive bias:
+
+(a) Random color transforms an image by passing through either color jitter layer or random convolutional layer proposed in [21]. From this, we can impose the consistency to color changes, which may provide a strong generalization to diverse backgrounds of test-bg mode.
+(b) Random crop leaves a randomly-selected rectangle and pads zeros to the rest of the image [25]. This augmentation is particularly useful in fully-observable games (e.g., Chaser and Heist), because it imposes an efficient attention mechanism.
+
+We also report the result with other augmentations including color jitter, random convolution, gray, and cutout color in the supplementary material, from which the same messages can be interpreted.
+
+Baseline methods for RL with data augmentation. We mainly compare the proposed methods (InDA and ExDA) to the following baselines:
+
+(a) RAD [20] simply feeds PPO with experiences of original and augmented observations.
+(b) $DrAC$ [25] is a method to simultaneously minimizing $L_{\mathrm{PPO}}$ in Eq (1) and $L_{\mathrm{dis}}$ in Eq (4).
+(c) $D r A C + P A G r a d$ is a variant of DrAC, which we devise to investigate another mechanism to relieve the interference between RL training and augmentation in Section 4.5.
+
+The supplementary material presents further details and experiments, which we omitted for simplicity. All results in the main paper are averaged over five runs.
+
+
+Figure 4: Benefit of separating distillation from RL training. We compare InDA, ExDA, DrAC, DrAC+PAGrad and ExDrAC when we start to apply each of them to distill the prior of random crop after 20M timesteps of PPO. ExDrAC is a variant of DrAC without RL training, i.e., minimizing only $L_{\mathrm{dis}}$ in Eq (4).
+
+# 5.2 Benefit of separating distillation from RL training.
+
+In Figure 4, after training PPO agent up to 20M timesteps, we start to suddenly apply one of the different distillation methods with random crop. We report averaged scores over 6 environments (Bigfish, Dodgeball, Plunder, Chaser, Heist, Maze) after normalized by the highest train score of PPO on each environment. After 20M timesteps, ExDA and ExDrAC have no RL training but minimize $L_{\mathrm{DA}}$ in Eq (5) and $L_{\mathrm{dis}}$ in Eq (4), respectively. The substantial gap between ExDA and ExDrAC justifies the design of DA explicitly preserving the knowledge from RL when distilling the prior. More importantly, it is remarkable that ExDA promptly learns the generalization ability once it starts to distill the prior. This validates the idea of postponing the distillation after RL training.
+
+We now compare the distillation methods (InDA, DrAC, and $\mathrm{DrAC + PAGrad}$ ) concurrently optimizing the RL objective and distilling the prior in Figure 4. Each method has performance degeneration due to the interference generated by distillation. However, InDA and $\mathrm{DrAC + PAGrad}$ have clearly smaller degeneration than DrAC which is the only one without any separation of optimizing the RL objective and distillation loss. We note that $\mathrm{DrAC + PAGrad}$ has more interference than InDA, and it seems to fail to impose the prior since there is not much difference to PPO in testing. Hence, this verifies the superiority of InDA which enables distilling the prior while alleviating the interference.
+
+
+(a) train (easybg)
+
+
+(b) test-lv
+
+
+(c) Policy Distance
+
+
+(d) train (easybg)
+
+
+(e) test-lv
+
+
+(f) Policy Distance
+Figure 5: Time-sensitivity of applying augmentation. We compare train and test performance of InDA[S,T] with random crop, where the timing of applying DA is governed by starting time $S$ and terminating time $T$ , and we evaluate four different pairs of $[S,T] = [0,0],[0,5],[20,25],[0,25]$ up to 25M timesteps. Furthermore, we show the change of distance between two policies on an original observation and an augmented observation. Note that InDA with $[S,T] = [0,0]$ means RL training with no augmentation, i.e., vanilla PPO. We focus on Chaser and Heist since they exemplify two representative time-dependencies. Each train task uses easybg mode. We present further details and results with other games in the supplementary material.
+
+# 5.3 Effective timings of distillation
+
+In what follows, we aim to identifying effective timings of distillation. To this end, in Figure 5, we test several schedules of applying DA on two representative environments of distinguishing traits. The supplementary material presents the result on more environments, which is similar one of the representatives.
+
+An effective timing: InDA. Chaser with random crop (Figure 5(a) and 5(b)) represents the case when augmentation improves the sample efficiency of training and thus the generalization ability in training. To compare the generalization ability, we measure policy distance between original and augmented observations using Jenson-Shannon divergence (Figure 5(c)). InDA[0, 5]'s policy distance is increased after it stops using DA. Thus, the generalization ability is degraded, if we do not continue to use DA. In this case, it is clear that InDA should be applied during the entire RL training, as InDA[0, 25] shows the best performance in both training and testing. In addition, it is also important to apply DA as soon as possible since the effect of InDA[0,5] applying DA in the beginning is relatively prompt and significant comparing to that of InDA[20,25]. This suggests that the automatic framework needs to explore more in the early stage.
+
+An effective timing: ExDA. Heist with random crop (Figure 5(d) and 5(e)) shows the opposite use of data augmentation to what Chaser case suggests, i.e., postponing data augmentation as much as possible. Random crop generates a slight interference, although it immediately improves the generalization ability. We remark that the inductive bias from the random crop is easily forgotten, as the test performance of InDA[0, 5] is saturated right after stopping the distillation. This can be explained by the time-varying nature of sample distribution and objective in RL. Interestingly, it is in contrast to the data augmentation in SL, where an early distillation is sufficient to impose the prior [10]. On the other hand, the test performance curve of InDA[20, 25] soars right after DA. Furthermore, Figure 5(f) shows that InDA[20, 25] narrows the gap between two policies on the
+
+original and augmented observation. Recalling the interference between RL training and distillation, this suggests postponing the distillation at the end of RL training, and motivates our ExDA.
+
+Performance benchmark on InDA and ExDA. In Table 1, we summarize the train and test performances of InDA and ExDA on a set of games with different augmentations and modes. ExDA outperforms other baselines with random color on test-bg. Moreover, we note that ExDA consumes only 0.5M timesteps to inject the prior at the end of RL training, whereas the others use all the training data. ExDA in both sample efficiency and generalization ability with random crop on test-lv. It is worth noting that DrAC+PAGrad is slightly better than DrAC, while there is a substantial gap between InDA and each DrAC-based algorithm. This again confirms the benefit from the separated distillation of InDA observed in Figure 4. These results demonstrate that each combination of environment and augmentation has a suitable time at which to apply augmentation, and the gain from using the right distillation timing, i.e., online (InDA, DrAC, or DrAC+PAGrad) or offline (ExDA), is rigid regardless of the choice of algorithms.
+
+| Augmentation | Task | PPO | RAD | DrAC | DrAC+PAGrad | InDA | ExDA |
| Rand color | Rand conv | Train | 1.00 | 0.98 | 0.88 | 0.89 | 0.88 | 0.98 |
| Test-bg | 1.00 | 1.08 | 1.86 | 1.88 | 1.92 | 2.11 |
| Test-lv | 1.00 | 0.81 | 0.84 | 0.84 | 0.7 | 0.87 |
| Color jitter | Train | 1.00 | 0.94 | 0.95 | 0.95 | 0.96 | 0.98 |
| Test-bg | 1.00 | 1.37 | 1.44 | 1.44 | 1.43 | 1.48 |
| Test-lv | 1.00 | 0.83 | 0.86 | 0.86 | 0.84 | 0.88 |
| Rand crop | Train | 1.00 | 0.28 | 1.08 | 1.09 | 1.25 | 0.91 |
| Test-bg | 1.00 | 0.64 | 0.87 | 0.94 | 0.94 | 0.95 |
| Test-lv | 1.00 | 0.46 | 1.52 | 1.53 | 1.80 | 1.09 |
+
+Table 1: Benchmark of InDA and ExDA. We report normalized train and test scores of InDA, ExDA and DrAC with PAGrad on Open AI Progen, compared to baselines PPO, DrAC [25], RAD [20]. Boldface indicates the best performance. We average the score among several environments [(Rand color: coinrun, ninja, climber, fruitbot, jumper, heist, maze), (Rand crop: Bigfish, Dodgeball, Plunder, Heist, Chaser, Maze)] after normalization considering PPO score to be 1. Every method is trained on 200 levels, using easybg mode. We evaluate test performance on both test-bg and test-lv. The results can be interpreted as an upper bound of potential gain from using data augmentation at perfect timing.
+
+# 5.4 Adaptive scheduling methods
+
+Adaptive selecting of timings: UCB-InDA and UCB-ExDA. It is hard to know in advance whether a certain augmentation helps the training or not [25]. We hence employ UCB-InDA which estimates the gain or damage from each augmentation from trial and error and identifies the one
+
+
+(a) Chaser
+
+
+(b) Heist
+Figure 6: Exploration & exploitation to find the most beneficial augmentation. We show that selected augmentation during training with UCB-InDA for each Chaser and Heist. UCB-InDA automatically selects the augmentation among three options, random color, identity and random crop.
+
+| Env | Method | PPO | DrAC | UCB-DrAC | InDA | ExDA | UCB-InDA | UCB-ExDA |
| Heist | Train | 9.2 ± 0.46 | 3.53 ± 0.3 | 7.41± 2.09 | 4.9 ± 0.79 | 9.14 ± 0.56 | 9.67± 0.23 | 9.45 ± 0.29 |
| Test-bg | 5.18 ± 1.53 | 3.58 ± 0.31 | 3.76± 0.54 | 4.9 ± 0.87 | 7.05 ± 1.29 | 6.23± 1.29 | 7.86± 0.83 |
| Test-lv | 4.13 ± 1.39 | 3.07 ± 0.33 | 3.49± 0.48 | 1.47± 0.77 | 5.05 ± 0.98 | 4.8± 1.24 | 5.74± 0.67 |
| Chaser | Train | 5.63± 1.12 | 0.16± 0.02 | 4.6± 1.22 | 5.69± 1.42 | 5.58± 1.33 | 7.49± 1.27 | 7.23± 1.15 |
| Test-bg | 0.87± 0.06 | 0.1± 0.02 | 0.57± 0.12 | 3.51± 1.33 | 1.02± 0.04 | 1.08± 0.08 | 3. 18± 0.79 |
| Test-lv | 4.83± 0.88 | 0.14± 0.01 | 4.14± 1.01 | 4.96± 1.21 | 5.11± 1.05 | 6.45± 0.8 | 6.43± 1.28 |
+
+Table 2: Full exploitation of augmentation to improve generalization on both test-bg and test-lv. We compare InDA, ExDA, DrAC, UCB-DrAC, UCB-InDA, UCB-ExDA and PPO about train, test-bg and test-lv. Boldface indicates the best method. InDA and DrAC use both random color and random crop during RL training. ExDA use both augmentation after RL training. UCB-InDA and UCB-DrAC are trained as automatically selecting the augmentation during training. UCB-ExDA trains ExDA after UCB-InDA with both augmentation.
+
+with most help. Recall Table 2 where PPO (without augmentation) shows much better training performance than InDA in Heist. As shown in Figure 6(b), UCB-InDA is able to identify that no augmentation is best for training in Heist. This implies that ExDA is more appropriate than InDA. Conversely, random crop is selected on Chaser (Figure 6(a)). As the result, we can automatically select InDA or ExDA appropriately for each task.
+
+Fully exploitation of augmentation In Table 2, when both random color and random crop are used to improve generalization on both test-bg and test-lv, we report numerical evaluation of UCB-InDA and UCB-ExDA with other baselines on train and test tasks. Decreased train performance of DrAC and InDA compare to PPO show the difficulty of simultaneous training with several augmentations. Train performance of UCB-InDA and UCB-DrAC are improved by adaptive selecting, especially, UCB-InDA is better than UCB-DrAC. The gap is made due to the robustness about the change of augmentation during training. In terms of generalization, UCB-ExDA clearly surpasses UCB-InDA thanks to ExDA to extract all the priors from the complete set of data augmentations at the end of RL training.
+
+# 6 Discussion
+
+We have identified two most effective yet simple timings (InDA and ExDA) of data augmentation for RL, and proposed UCB-ExDA framework to adaptively select the best scheduling augmentations. We note that the effectiveness of this framework is restricted but specialized for RL with the unique nonstationary nature. Indeed, in SL without shift of data distribution and objective, it is sufficient to apply data augmentation at the beginning [10]. Our framework employs the most basic multi-armed bandit algorithm with a finite set of data augmentation. It is interesting to investigate a room to improve by further optimizing continuous parameters of data augmentation for RL, c.f., an auto-augmentation technique to optimize continuous augmentation parameter per sample for SL [11]. Another promising direction is to accelerate the distillation process of DA by data condensation with augmentation [37]. This is possible with our framework clearly separating between RL training and distillation, and may be particularly useful to train distributed RL agents since a condensed data for an agent's distillation is usable for the other.
+
+# Acknowledgments and Disclosure of Funding
+
+We thank Kimin Lee for helpful discussions. This work was supported by Institute of Information & communications Technology Planning & Evaluation (IITP) grant funded by the Korea government (MSIT) (No.2019-0-01906, Artificial Intelligence Graduate School Program (POSTECH)) and Institute of Information & communications Technology Planning & Evaluation (IITP) grant funded by the Korea government (MSIT) (No.2021-0-02068, Artificial Intelligence Innovation Hub) and the National Research Foundation of Korea (NRF) grant funded by the Korea government (MSIT) (No. 2021M3E5D2A01023887). Byungchan Ko was supported by the Institute of Information & Communications Technology Planning & Evaluation (IITP) grant funded by Korea (MSIT) (2020-0-01594, PSAI industry-academic joint research and education program).
+
+# References
+
+[1] Alessandro Achille, Matteo Rovere, and Stefano Soatto. Critical learning periods in deep networks. In International Conference on Learning Representations, 2018.
+[2] Sanjeev Arora, Nadav Cohen, Wei Hu, and Yuping Luo. Implicit regularization in deep matrix factorization. In Advances in Neural Information Processing Systems, pages 7411-7422, 2019.
+[3] Peter Auer. Using confidence bounds for exploitation-exploration trade-offs. Journal of Machine Learning Research, 3(Nov):397-422, 2002.
+[4] Richard E Bellman. Adaptive control processes. Princeton university press, 2015.
+[5] Karl Cobbe, Chris Hesse, Jacob Hilton, and John Schulman. Leveraging procedural generation to benchmark reinforcement learning. In International conference on machine learning, pages 2048-2056. PMLR, 2020.
+[6] Karl Cobbe, Oleg Klimov, Chris Hesse, Taehoon Kim, and John Schulman. Quantifying generalization in reinforcement learning, 2019.
+[7] Dumitru Erhan, Aaron Courville, Yoshua Bengio, and Pascal Vincent. Why does unsupervised pre-training help deep learning? In Proceedings of the thirteenth international conference on artificial intelligence and statistics, pages 201-208. JMLR Workshop and Conference Proceedings, 2010.
+[8] Jesse Farebrother, Marlos C. Machado, and Michael Bowling. Generalization and regularization in dqn, 2020.
+[9] Gauthier Gidel, Francis Bach, and Simon Lacoste-Julien. Implicit regularization of discrete gradient dynamics in linear neural networks. In Advances in Neural Information Processing Systems, pages 3196-3206, 2019.
+[10] Aditya Sharad Golatkar, Alessandro Achille, and Stefano Soatto. Time matters in regularizing deep networks: Weight decay and data augmentation affect early learning dynamics, matter little near convergence. In Advances in Neural Information Processing Systems, pages 10678-10688, 2019.
+[11] Denis Gudovskiy, Luca Rigazio, Shun Ishizaka, Kazuki Kozuka, and Sotaro Tsukizawa. Autodo: Robust autoaugment for biased data with label noise via scalable probabilistic implicit differentiation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 16601-16610, 2021.
+[12] Suriya Gunasekar, Blake E Woodworth, Srinadh Bhojanapalli, Behnam Neyshabur, and Nati Srebro. Implicit regularization in matrix factorization. In Advances in Neural Information Processing Systems, pages 6151-6159, 2017.
+[13] Nicklas Hansen, Yu Sun, Pieter Abbeel, Alexei A Efros, Lerrel Pinto, and Xiaolong Wang. Self-supervised policy adaptation during deployment. arXiv preprint arXiv:2007.04309, 2020.
+[14] Nicklas Hansen and Xiaolong Wang. Generalization in reinforcement learning by soft data augmentation. In 2021 IEEE International Conference on Robotics and Automation (ICRA), pages 13611-13617. IEEE, 2021.
+[15] Peter Henderson, Riashat Islam, Philip Bachman, Joelle Pineau, Doina Precup, and David Meger. Deep reinforcement learning that matters, 2019.
+[16] Irina Higgins, Arka Pal, Andrei A. Rusu, Loic Matthew, Christopher P Burgess, Alexander Pritzel, Matthew Botvinick, Charles Blundell, and Alexander Lerchner. Darla: Improving zero-shot transfer in reinforcement learning, 2018.
+[17] Maximilian Igl, Gregory Farquhar, Jelena Luketina, Wendelin Boehmer, and Shimon Whiteson. The impact of non-stationarity on generalisation in deep reinforcement learning. arXiv preprint arXiv:2006.05826, 2020.
+
+[18] Dmitry Kalashnikov, Alex Irpan, Peter Pastor, Julian Ibarz, Alexander Herzog, Eric Jang, Deirdre Quillen, Ethan Holly, Mrinal Kalakrishnan, Vincent Vanhoucke, et al. Qt-opt: Scalable deep reinforcement learning for vision-based robotic manipulation. arXiv preprint arXiv:1806.10293, 2018.
+[19] Ilya Kostrikov, Denis Yarats, and Rob Fergus. Image augmentation is all you need: Regularizing deep reinforcement learning from pixels. arXiv preprint arXiv:2004.13649, 2020.
+[20] Michael Laskin, Kimin Lee, Adam Stooke, Lerrel Pinto, Pieter Abbeel, and Aravind Srinivas. Reinforcement learning with augmented data. arXiv preprint arXiv:2004.14990, 2020.
+[21] Kimin Lee, Kibok Lee, Jinwoo Shin, and Honglak Lee. Network randomization: A simple technique for generalization in deep reinforcement learning. arXiv, pages arXiv-1910, 2019.
+[22] Zhuang Liu, Xuanlin Li, Bingyi Kang, and Trevor Darrell. Regularization matters in policy optimization - an empirical study on continuous control, 2020.
+[23] Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Andrei A Rusu, Joel Veness, Marc G Bellemare, Alex Graves, Martin Riedmiller, Andreas K Fidjeland, Georg Ostrovski, et al. Human-level control through deep reinforcement learning. nature, 518(7540):529-533, 2015.
+[24] Lerrel Pinto, Marcin Andrychowicz, Peter Welinder, Wojciech Zaremba, and Pieter Abbeel. Asymmetric actor critic for image-based robot learning. arXiv preprint arXiv:1710.06542, 2017.
+[25] Roberta Raileanu, Max Goldstein, Denis Yarats, Ilya Kostrikov, and Rob Fergus. Automatic data augmentation for generalization in deep reinforcement learning. arXiv preprint arXiv:2006.12862, 2020.
+[26] Sharath Chandra Raparthy, Bhairav Mehta, Florian Golemo, and Liam Paull. Generating automatic curricula via self-supervised active domain randomization, 2020.
+[27] John Schulman, Philipp Moritz, Sergey Levine, Michael Jordan, and Pieter Abbeel. High-dimensional continuous control using generalized advantage estimation. arXiv preprint arXiv:1506.02438, 2015.
+[28] David Silver, Thomas Hubert, Julian Schrittwieser, Ioannis Antonoglou, Matthew Lai, Arthur Guez, Marc Lanctot, Laurent Sifre, Dharshan Kumaran, Thore Graepel, et al. A general reinforcement learning algorithm that masters chess, shogi, and go through self-play. Science, 362(6419):1140-1144, 2018.
+[29] David Silver, Julian Schrittwieser, Karen Simonyan, Ioannis Antonoglou, Aja Huang, Arthur Guez, Thomas Hubert, Lucas Baker, Matthew Lai, Adrian Bolton, et al. Mastering the game of go without human knowledge. nature, 550(7676):354-359, 2017.
+[30] Aravind Srinivas, Michael Laskin, and Pieter Abbeel. Curl: Contrastive unsupervised representations for reinforcement learning, 2020.
+[31] Adam Stooke, Kimin Lee, Pieter Abbeel, and Michael Laskin. Decoupling representation learning from reinforcement learning. arXiv preprint arXiv:2009.08319, 2020.
+[32] Josh Tobin, Rachel Fong, Alex Ray, Jonas Schneider, Wojciech Zaremba, and Pieter Abbeel. Domain randomization for transferring deep neural networks from simulation to the real world. In 2017 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), pages 23-30. IEEE, 2017.
+[33] Xiaoxia Wu, Ethan Dyer, and Behnam Neyshabur. When do curricula work?, 2021.
+[34] Denis Yarats, Amy Zhang, Ilya Kostrikov, Brandon Amos, Joelle Pineau, and Rob Fergus. Improving sample efficiency in model-free reinforcement learning from images, 2020.
+[35] Kaichao You, Mingsheng Long, Jianmin Wang, and Michael I. Jordan. How does learning rate decay help modern neural networks?, 2019.
+
+[36] Tianhe Yu, Saurabh Kumar, Abhishek Gupta, Sergey Levine, Karol Hausman, and Chelsea Finn. Gradient surgery for multi-task learning. arXiv preprint arXiv:2001.06782, 2020.
+[37] Bo Zhao and Hakan Bilen. Dataset condensation with differentiable siamese augmentation. In International Conference on Machine Learning, pages 12674-12685. PMLR, 2021.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes] We claim our three main contributions in 1 and target on DeepRL.
+(b) Did you describe the limitations of your work? [Yes] We describe the limitations of our work about a limited set of data augmentation for UCB methods in Section 6.
+(c) Did you discuss any potential negative societal impacts of your work? [N/A] We believe that our research will not have a negative impact on society.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] We read the ethics review guidelines.
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A] Our works are based on experimental results.
+(b) Did you include complete proofs of all theoretical results? [N/A] Our works are based on experimental results.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] We describe our training environments and include code in the supplemental material.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] We describe training details in the supplementary material.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] We indicate standard deviation with score in Figure 5 and Table 2 except normalized score with several environments such as Figure 4 and Table 1.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] We explain about training time in the supplementary material.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] Our experiment environments are based on OpenAI Progen [5].
+(b) Did you mention the license of the assets? [Yes] We include the license of the assets in the code.
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientschedulingofdataaugmentationfordeepreinforcementlearning/images.zip b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..3525ea8d453d13cf1beedfeb6cc3c4266eff2d81
--- /dev/null
+++ b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6bfd7f02731299e670dba9d16334ef9fa3f7ab2e1f21db8f95a03cd4b7997400
+size 312334
diff --git a/efficientschedulingofdataaugmentationfordeepreinforcementlearning/layout.json b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..e4ae965fb160f06a7a16b306b752e8d9b6b5e486
--- /dev/null
+++ b/efficientschedulingofdataaugmentationfordeepreinforcementlearning/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2720b161d8a43562baa5c66c311e84e7ea916e6b262edb41a4c60515e4cff59e
+size 485342
diff --git a/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/f6877ec2-68d0-4811-afb1-51090b19e4d2_content_list.json b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/f6877ec2-68d0-4811-afb1-51090b19e4d2_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..9149d56aadc1214f60990ee9ba68e85ca065d5e8
--- /dev/null
+++ b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/f6877ec2-68d0-4811-afb1-51090b19e4d2_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ff1a753d8895b6298246014d3c03f6406dcae719b5750f2df2c60956b60136fd
+size 104898
diff --git a/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/f6877ec2-68d0-4811-afb1-51090b19e4d2_model.json b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/f6877ec2-68d0-4811-afb1-51090b19e4d2_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..4b02478b88f8031fb081f8b91ca8c16df04b9d5e
--- /dev/null
+++ b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/f6877ec2-68d0-4811-afb1-51090b19e4d2_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d66927316bd7fcf8366a941225e03cbefd45ce32a79c86e5588b7a2a23b3ee38
+size 144308
diff --git a/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/f6877ec2-68d0-4811-afb1-51090b19e4d2_origin.pdf b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/f6877ec2-68d0-4811-afb1-51090b19e4d2_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..45fbab971d4b27c39a9b4146f4fa9c6a1b078047
--- /dev/null
+++ b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/f6877ec2-68d0-4811-afb1-51090b19e4d2_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c2d756f3080571a436a7bbda12242f7beb0b569724188edc216e112d2130cbc9
+size 14650988
diff --git a/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/full.md b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..3af3521ee483c82af690aff54618f338e264d176
--- /dev/null
+++ b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/full.md
@@ -0,0 +1,465 @@
+# Efficient Spatially Sparse Inference for Conditional GANs and Diffusion Models
+
+Muyang Li $^{1}$ Ji Lin $^{2}$ Chenlin Meng $^{3}$ Stefano Ermon $^{3}$ Song Han $^{2}$ Jun-Yan Zhu $^{1}$ $^{1}$ Carnegie Mellon University $^{2}$ Massachusetts Institute of Technology $^{3}$ Stanford University
+
+# Abstract
+
+During image editing, existing deep generative models tend to re-synthesize the entire output from scratch, including the unedited regions. This leads to a significant waste of computation, especially for minor editing operations. In this work, we present Spatially Sparse Inference (SSI), a general-purpose technique that selectively performs computation for edited regions and accelerates various generative models, including both conditional GANs and diffusion models. Our key observation is that users tend to make gradual changes to the input image. This motivates us to cache and reuse the feature maps of the original image. Given an edited image, we sparsely apply the convolutional filters to the edited regions while reusing the cached features for the unedited regions. Based on our algorithm, we further propose Sparse Incremental Generative Engine (SIGE) to convert the computation reduction to latency reduction on off-the-shelf hardware. With $1.2\%$ area edited regions, our method reduces the computation of DDIM by $7.5\times$ and GauGAN by $18\times$ while preserving the visual fidelity. With SIGE, we accelerate the inference time of DDIM by $3.0\times$ on RTX 3090 and $6.6\times$ on Apple M1 Pro CPU, and GauGAN by $4.2\times$ on RTX 3090 and $14\times$ on Apple M1 Pro CPU.
+
+# 1 Introduction
+
+Deep generative models, such as GANs [1, 2] and diffusion models [3, 4, 5], excel at synthesizing photo-realistic images, enabling many image synthesis and editing applications. For example, users can edit an image by drawing sketches [6, 7], semantic maps [6, 8], or strokes [9]. All of these applications require users to interact with generative models frequently and therefore demand fast inference time.
+
+In practice, content creators often edit images gradually and only update a small image region each time. However, even for a minor edit, recent generative models often synthesize the entire image, including the unchanged regions, which leads to a significant waste of computation. As a concrete example shown in Figure 2(a), the result of the previous editing has already been computed, and the user further edits $9.4\%$ area. However, the vanilla DDIM [5] needs to generate the entire image to obtain the newly edited regions, wasting $80\%$ computation on the unchanged regions. A naive approach to address this issue would be to first segment the newly edited regions, synthesize the corresponding output regions, and blend the outputs back into the previous output. Unfortunately, this method often creates visible seams between the newly edited and unedited regions. How could we save the computation by only updating the edited regions without losing global coherence?
+
+In this work, we propose Spatially Sparse Inference (SSI), a general method to accelerate deep generative models, including conditional GANs and diffusion models, by utilizing the spatial sparsity of edited regions. Our method is motivated by the observation that feature maps at the unedited regions remain mostly the same during user editing. As shown in Figure 2(b), our key idea is to reuse the cached feature maps of the previous editing and sparsely update the newly edited regions. Specifically, given user input, we first compute the difference mask to locate the newly edited regions. For each
+
+
+Original
+
+
+11.5% Editing
+
+
+DDIM: 249G MACs
+
+
+Ours: 61.3G $(4.1\times)$
+
+
+Original
+
+
+2.02% Editing
+
+
+Original
+
+
+3.78% Editing
+
+
+DDIM: 249G MACs
+
+
+Ours: 40.6G (6.1×)
+Figure 1: We introduce Spatially Sparse Inference, a general-purpose method to selectively perform computations at the edited regions for image editing applications. Our method reduces the computation of DDIM [5] by $4 \sim 6 \times$ and GauGAN [8] by $15 \times$ for the examples shown in the figures while preserving the image quality. When combined with existing model compression methods such as GAN Compression [10], our method further reduces the computation of GauGAN by $47 \times$ .
+
+
+1GAN Compression: 31.2G (9.0×
+
+
+GAN Comp.+Ours: 6.02G $(47\times)$
+
+convolution layer in the model, we only apply the filters to the masked regions sparsely while reusing the previous activations for the unchanged regions. The sparse update can significantly reduce the computation without hurting the image quality. However, the sparse update involves a gather-scatter process, which often incurs significant latency overheads for existing deep learning frameworks. To address the issue, we propose Sparse Incremental Generative Engine (SIGE) to translate the theoretical computation reduction of our algorithm to measured latency reduction on various hardware.
+
+To evaluate our method, we automatically create new image editing benchmark datasets on LSUN Church [11] and Cityscapes [12]. Without loss of visual fidelity, we reduce the computation of DDIM [5] by $7.5 \times$ , Progressive Distillation [13] by $2.7 \times$ , and GauGAN by $18 \times$ measured by MACs*. Compared to existing generative model acceleration methods [10, 14, 15, 16, 17, 18, 19], our method directly uses the off-the-shelf pre-trained weights and could be applied to these methods as a plugin. When applied to GAN Compression [10], our method reduces the computation of GauGAN by $\sim 50 \times$ . See Figure 1 for some examples of our method. With SIGE, we accelerate DDIM $3.0 \times$ on RTX 3090 GPU and $6.6 \times$ on Apple M1 Pro CPU, and GauGAN $4.2 \times$ on RTX 3090 GPU and $38 \times$ on Apple M1 Pro CPU. Our code and benchmarks are available at https://github.com/lmxyy/sige.
+
+# 2 Related Work
+
+Generative models. Generative models such as GANs [1, 2, 20, 21], diffusion models [4, 3, 22], and auto-regressive models [23, 24] have demonstrated impressive photorealistic synthesis capability. They have also been extended to conditional image synthesis tasks such as image-to-image translation [25, 6, 26, 27], controllable image generation [9, 28, 8], and real image editing [29, 28, 30, 31, 32, 33, 34, 27]. Unfortunately, recent generative models have become increasingly computationally intensive, compared to their recognition counterparts. For example, GauGAN [8] consumes 281G MACs, $500 \times$ more than MobileNet [35, 36, 37]. Similarly, one key limitation of diffusion models [4] is their long inference time and substantial computation cost. To generate one image, DDPM requires hundreds or thousands of forwarding steps [4, 22], which is often infeasible in real-world interactive settings. To improve the sampling efficiency of DDPMs, recent works [5, 38, 39] propose to interpret the sampling process of DDPMs from the perspective of ordinary differential equations. However, these approaches still require hundreds of steps to generate high-quality samples. To further reduce the sampling cost, DDGAN [40] uses a multimodal conditional GAN to model each denoising step. Salimans et al. [13] propose to progressively distill a pre-trained DDPM model into a new model that requires fewer steps. Although this approach drastically reduces the sampling steps, the distilled model itself remains computationally prohibitive. Unlike prior work, our work focuses on reducing the computation cost of a pre-trained model. Our work is complementary to recent efforts on model compression, distillation, and the sampling step reduction of the diffusion models.
+
+Model acceleration. People apply model compression techniques, including pruning [41, 42, 43, 44, 45, 46] and quantization [41, 47, 48, 49, 50, 51], to reduce the computation and model size of off-the-shelf deep learning models. Recent works apply Neural Architecture Search (NAS) [52, 53, 54, 55,
+
+
+Figure 2: In the interactive editing scenario, a user edits $9.4\%$ area. (a) Vanilla DDIM has to regenerate the entire image for every single editing, even though only $9.4\%$ editing is made. (b) Our method instead reuses the feature maps of the previous editing and only applies convolutions to the newly edited regions sparsely, which has a $5.0 \times$ MACs reduction in this case.
+
+56, 57, 58] to automatically design efficient neural architectures. The above ideas can be successfully applied to accelerate the inference of GANs [10, 59, 60, 61, 14, 62, 15, 16, 17, 18, 19, 63]. Although these methods have achieved prominent compression and speedup ratios, they all reduce the computation from the model dimension but fail to exploit the redundancy in the spatial dimension during image editing. Besides, these methods require re-training the compressed model to maintain performance, while our method can be directly applied to existing pre-trained models. We show that our method can be combined with model compression [10] to achieve a $\sim 50\times$ MACs reduction in Section 4.1.
+
+Sparse computation. Sparse computation has been widely explored in the weight domain [64, 65, 66, 67], input domain [68, 69], and activation domain [70, 71, 72, 73]. For activation sparsity, RRN [74] utilizes the sparsity in the consecutive video frame difference to accelerate video models. However, their sparsity is unstructured, which requires special hardware to reach its full speedup potential. Several works instead use structured sparsity. Li et al. [75] use a deep layer cascade to apply more convolutions on the hard regions than the easy regions to improve the accuracy and speed of semantic segmentation. To accelerate 3D object detection, SBNet [70] uses a spatial mask, either from a priori problem knowledge or an auxiliary network, to sparsify the activations. It adopts a tiling-based sparse convolution algorithm to handle spatial sparsity. Recent works further integrate the spatial mask generation network into the sparse inference network in an end-to-end manner [76] and extend the idea to different tasks [77, 78, 79, 80]. Compared to SBNet [70], our mask is directly derived from the difference between the original image and the edited image. Additionally, our method does not require any auxiliary network or extra model training. We also introduce other optimizations, such as normalization removal and kernel fusions, to better adapt our engine for image editing.
+
+# 3 Method
+
+We build our method based on the following observation: during interactive image editing, a user often only changes the image content gradually. As a result, only a small subset of pixels in a local region is being updated at any moment. Therefore, we can reuse the activations of the original image for the unedited regions. As shown in Figure 3, we first pre-compute all activations of the original input image. During the editing process, we locate the editing regions by computing a difference mask between the original and edited image. We then reuse the pre-computed activations for the unedited regions and only update the edited regions by applying convolutional filters to them. In Section 3.1, we show the sparsity in the intermediate activations and present our main algorithm. In Section 3.2, we discuss the technical details of how our Sparse Incremental Generative Engine (SIGE) supports the sparse inference and converts the theoretical computation reduction to measured speedup on hardware.
+
+# 3.1 Activation Sparsity
+
+Preliminary. First, we closely study the computation within a single layer. We denote $A_{l}^{\mathrm{original}}$ and $A_{l}^{\mathrm{edited}}$ as the input tensor of the original image and edited image to the $l$ -th convolution layer $F_{l}$ , respectively. $W_{l}$ and $b_{l}$ are the weight and bias of $F_{l}$ . The output of $F_{l}$ with input $A_{l}^{\mathrm{edited}}$ could be
+
+
+Difference Mask Reduced Indices
+
+
+Figure 3: Tiling-based sparse convolution overview. For each convolution $F_{l}$ in the network, we wrap it into SIGE Conv $_{l}$ . The activations of the original image are already pre-computed. When getting the edited image, we first compute a difference mask between the original and edited image and reduce the mask to the active block indices to locate the edited regions. In each SIGE Conv $_{l}$ , we directly gather the active blocks from the edited activation $A_{l}^{\mathrm{edited}}$ according to the reduced indices, stack the blocks along the batch dimension, and feed them into $F_{l}$ . The gathered blocks have an overlap of width 2 if $F_{l}$ is $3 \times 3$ convolution [70]. After getting the output blocks from $F_{l}$ , we scatter them back into $F_{l}(A_{l}^{\mathrm{original}})$ to get the edited output, which approximates $F_{l}(A_{l}^{\mathrm{edited}})$ .
+Figure 4: Left: Detailed editing example. Right: Channel-wise average of $|\Delta A_l|$ at the $l$ -th layer of DDIM with different feature map resolutions. $|\Delta A_l|$ is sparse and non-zero values are aggregated at the edited regions.
+
+computed in the following way due to the linearity of convolution:
+
+$$
+\begin{array}{l} F _ {l} \left(A _ {l} ^ {\text {e d i t e d}}\right) = W _ {l} * A _ {l} ^ {\text {e d i t e d}} + b _ {l} \\ = W _ {l} * \left(A _ {l} ^ {\text {e d i t e d}} - A _ {l} ^ {\text {o r i g i n a l}}\right) + \left(W _ {l} * A _ {l} ^ {\text {o r i g i n a l}} + b _ {l}\right) \\ = W _ {l} * \underbrace {\Delta A _ {l}} _ {\text {s p a r s e}} + \underbrace {F _ {l} \left(A _ {l} ^ {\text {o r i g i n a l}}\right)} _ {\text {p r e - c o m p u t e d}}, \\ \end{array}
+$$
+
+where $*$ is the convolution operator and $\Delta A_{l} = A_{l}^{\mathrm{edited}} - A_{l}^{\mathrm{original}}$ . If we already pre-computed all the $F_{l}(A_{l}^{\mathrm{original}})$ , we only need to compute $W_{l}*\Delta A_{l}$ . Naively, computing $W_{l}*\Delta A_{l}$ has the same complexity as $W_{l}*A_{l}^{\mathrm{edited}}$ . However, since the edited image shares similar features with the original image given a small edit, $\Delta A_{l}$ should be sparse. Below, we discuss different strategies to leverage the activation sparsity to accelerate model inference.
+
+Our first attempt was to prune $\Delta A_{l}$ by zeroing out elements smaller than a certain threshold to achieve the target sparsity. Unfortunately, this pruning method fails to achieve measured speedup due to the overheads of the on-the-fly pruning and irregular sparsity pattern.
+
+Structured sparsity. Fortunately, user edits are often highly structured and localized. As a result, $\Delta A_{l}$ should also share the structured spatial sparsity, where non-zero values are mostly aggregated within the edited regions, as shown in Figure 4. We then directly use the original image and edited image to compute a difference mask and sparsify $\Delta A_{l}$ with this mask.
+
+# 3.2 Sparse Engine SIGE
+
+But how could we leverage the structured sparsity to accelerate $W_{l} * \Delta A_{l}$ ? A naive approach is to crop a rectangular edited region out of $\Delta A_{l}$ for each convolution and only compute features for the cropped regions. Unfortunately, this naive cropping method works poorly for the irregular edited regions (e.g., the example shown in Figure 4).
+
+Tiling-based sparse convolution. Instead, as shown in Figure 5(a), we use a tiling-based sparse convolution algorithm. We first downsample the difference mask to different scales and dilate the downsampled masks with extra pixels (1 for diffusion models and 2 for GauGAN). Then we divide $\Delta A_{l}$ into multiple small blocks of the same size spatially and index the difference mask
+
+
+Figure 5: The tilting-based sparse convolution pipelines. (a) We first compute the activation difference $\Delta A_{l}$ and gather the active blocks along the batch dimension from it according to the indices reduced from the difference mask. We then feed the blocks into the convolution $F_{l}$ without bias, scatter the output into a zero tensor, and add the residual $F_{l}(A_{l}^{\mathrm{original}})$ back. (b) We directly gather the blocks from $A_{l}^{\mathrm{edited}}$ without computing $\Delta A_{l}$ . $F_{l}$ is computed with bias. We scatter the output into $F_{l}(A_{l}^{\mathrm{original}})$ instead of a zero tensor.
+
+at the corresponding resolution. Each block index refers to a single block with non-zero elements. We then gather the non-zero blocks (we also call them active blocks) accordingly along the batch dimension and feed them into the convolution $F_{l}$ . Finally, we scatter the output blocks into a zero tensor according to the indices to recover the original spatial size and add the pre-computed residual $F_{l}(A^{\mathrm{original}})$ back. The gathered active blocks have an overlap with width 2 for $3 \times 3$ convolution to ensure the output blocks of the adjacent input blocks are seamlessly stitched together [70].
+
+This pipeline in Figure 5(a) is equivalent to a simpler pipeline in Figure 5(b). Instead of gathering $\Delta A_{l}$ , we could directly gather $A_{l}^{\mathrm{edited}}$ . The convolution needs to be computed with bias $b_{l}$ . Besides, we need to scatter the output blocks into $F_{l}(A_{l}^{\mathrm{original}})$ instead of a zero tensor. Thus, we do not need to store $A_{l}^{\mathrm{original}}$ anymore, which further saves memory and removes the overheads of addition and subtraction. Figure 3 visualizes the pipeline.
+
+However, the aforementioned pipeline still fails to produce a noticeable speedup due to extra kernel calls and memory movement overheads in Gather and Scatter. For example, the original dense $3 \times 3$ convolution with 128 channels and input resolution $256 \times 256$ would take 0.78ms on RTX 3090. The sparse convolution using pipeline Figure 5(b) on the example shown in Figure 4 (15.5% edited regions) needs 0.42ms in total, while Gather and Scatter cost a significant overhead (0.17ms, about $41\%$ ). To reduce it, we further optimize SIGE by pre-computing normalization parameters and applying kernel fusion.
+
+Pre-computing normalization parameters. For batch normalization [81], it is easy to remove the normalization layer during inference time since we can use pre-computed mean and variance statistics from model training. However, recent deep generative models often use instance normalization [82, 83] or group normalization [84, 85], which compute the statistics on the fly during inference. These normalization layers create overheads as we need to estimate the statistics from the full-size tensors. However, as the original and edited images are quite similar given a small user edit, we assume $A_{l}^{\mathrm{original}} \approx A_{l}^{\mathrm{edited}}$ . This allows us to reuse the statistics of $A_{l}^{\mathrm{original}}$ for the normalization instead of recomputing them for $A_{l}^{\mathrm{edited}}$ . Thus, normalization layers could be replaced by simple Scale+Shift operations with pre-computed $A_{l}^{\mathrm{original}}$ statistics.
+
+Kernel fusion. As mentioned before, both the Gather and Scatter operations introduce significant data movement overheads. To reduce it, we fuse several element-wise operations (Scale+Shift and Nonlinearity) into Gather and Scatter [70, 86, 87] and only apply these element-wise operations to the active blocks (i.e., edited regions). Furthermore, we perform in-place computation to reduce the number of kernel calls and memory allocation overheads.
+
+In Scatter, we need to copy the pre-computed activation $F_{l}(A_{l}^{\mathrm{original}})$ . This copying operation is highly redundant, as most elements from $F_{l}(A_{l}^{\mathrm{original}})$ do not involve any computation given a small edit and will be discarded in the next Gather. To reduce the tensor copying overheads, we fuse the Scatter and the following Gather by directly gathering the active blocks from $F_{l}(A_{l}^{\mathrm{original}})$ and the input blocks to be scattered. Sometimes, the residual connection in the ResBlock [88] contains shortcut $1 \times 1$ convolution to match the channel number of the residual and the ResBlock output. We also fuse the Scatter in the shortcut branch, main branch, and the residual addition together to avoid the tensor copying overheads in the shortcut Scatter. Please refer to Appendix A for more details.
+
+# 4 Experiments
+
+Below we first describe our models, baselines, datasets, and evaluation protocols. We then discuss our main qualitative and quantitative results. Finally, we include a detailed ablation study regarding the importance of each algorithmic design.
+
+Models. We conduct experiments on three models, including diffusion models and GAN-based models, to explore the generality of our method.
+
+- DDIM [5] is a fast sampling approach for diffusion models. It proposes to interpret the sampling process of diffusion models through the lens of ordinary differential equations.
+- Progressive Distillation (PD) [13] adopts network distillation [89] to progressively reduce the number of steps for diffusion models.
+- GauGAN [8] is a paired image-to-image translation model which learns to generate a high-fidelity image given a semantic label map.
+
+Baselines. We compare our methods against the following baselines:
+
+- Patch. We crop the smallest patch covering all the edited regions, feed it into the model, and blend the output patch into the original image.
+- $Crop$ . For each convolution $F_{l}$ , we crop the smallest rectangular region that covers all masked elements of the activation $A_{l}^{\mathrm{edited}}$ , feed it into $F_{l}$ , and scatter the output patch into $F_{l}(A_{l}^{\mathrm{original}})$ .
+- $40\%$ Pruning. We uniformly prune $40\%$ weights of the models without further fine-tuning, as our method directly uses the pre-trained weights. Since the fine-grained pruning is unstructured, it requires special hardware to achieve measured speedup, so we do not report MACs for this baseline.
+- 0.19 GauGAN. We reduce each convolution layer of GauGAN to $19\%$ channels ( $21 \times$ MACs reduction) and train it from scratch.
+- GAN Compression [10]. A general-purpose compression method for conditional GANs. GAN Comp. (S) means GAN Compression with a larger compression ratio.
+- 0.5 Original means linearly scaling each layer of the original model to $50\%$ channels, and we only use this to benchmark our efficiency results.
+
+Datasets. We use the following two datasets in our experiments:
+
+- LSUN Church. We use the LSUN Church Outdoor dataset [11] and follow the same preprocessing steps as prior works [4, 38]. To automatically generate a stroke editing benchmark, we first use Detic [90] to segment the images in the validation set. For each segmented object, we use its segmentation mask to inpaint the image by CoModGAN [91] and treat the inpainted image as the original image. We generate the corresponding user strokes by first blurring the masked regions with the median filter and quantizing it into 6 colors following SDEdit [9]. We collect 454 editing pairs in total (431 synthetic + 23 manual). We evaluate DDIM [5] and PD [13] on this dataset.
+- Cityscapes. The dataset [12] contains images of German street scenes. The training and validation sets consist of 2975 and 500 images, respectively. Our editing dataset has 1505 editing pairs in total. We evaluate GauGAN [8] on this dataset.
+
+Please refer to Appendix B for more details about the benchmark datasets.
+
+Metrics. Following previous works [9, 10, 8], we use the standard metrics Peak Signal Noise Ratio (PSNR, higher is better), LPIPS (lower is better) [92], and Fréchet Inception Distance (FID, lower is better) $[93, 94]^{\dagger}$ to evaluate the image quality on both LSUN Church [11] and Cityscapes [12]. For Cityscapes, we adopt a semantic segmentation metric to evaluate the generated images. Specifically, we run DRN-D-105 [95] on the generated images and compute the mean Intersection over Union (mIoU) of the segmentation results. Generally, a higher mIoU indicates that the generated images look more realistic and better align to the input.
+
+| Model | Method | MACs | PSNR (↑) | LPIPS (↓) | FID (↓) | mIoU (↑) |
| Value | Ratio | with G.T. | with Orig. | with G.T. | with Orig. |
| DDIM | Original | 249G | - | 26.8 | - | 0.069 | - | 65.4 | - |
| 40% Pruning | - | - | 24.9 | 31.0 | 0.991 | 0.101 | 72.2 | - |
| Patch | 72.0G | 3.5× | 26.8 | 40.6 | 0.076 | 0.022 | 66.4 | - |
| Ours | 65.3G | 3.8× | 26.8 | 53.4 | 0.070 | 0.009 | 65.8 | - |
| PD | Original | 66.9G | - | 21.9 | - | 0.182 | - | 90.0 | - |
| 40% Pruning | - | - | 21.6 | 37.6 | 0.189 | 0.051 | 101 | - |
| Ours | 32.5G | 2.1× | 21.9 | 60.7 | 0.183 | 0.003 | 90.1 | - |
| GauGAN | Original | 281G | - | 15.8 | - | 0.451 | - | 55.2 | 62.4 |
| GAN Comp. [10] | 31.2G | 9.0× | 15.7 | 19.5 | 0.453 | 0.282 | 55.3 | 61.5 |
| Ours | 30.7G | 9.2× | 15.8 | 26.5 | 0.454 | 0.113 | 54.2 | 62.1 |
| 0.19 GauGAN | 13.3G | 21× | 15.5 | 18.6 | 0.462 | 0.319 | 57.8 | 53.5 |
| GAN Comp. (S) | 9.64G | 29× | 15.7 | 19.1 | 0.461 | 0.306 | 50.3 | 57.4 |
| GAN Comp.+Ours | 7.06G | 40× | 15.7 | 19.1 | 0.457 | 0.294 | 54.4 | 60.1 |
+
+Table 1: Quantitative quality evaluation. PSNR/LPIPS with G.T. means computing the metrics with the groundtruth images, and with Orig. means computing with the generated samples from the original model. $40\%$ Pruning: Uniformly pruning $40\%$ weights of the model without fine-tuning. Patch: Cropping the smallest image patch that covers all the edited region and blending the output patch into the original image. 0.19 GauGAN: Uniformly reducing each layer of GauGAN to $19\%$ channels and training from scratch. GAN Comp. (S): GAN Compression with a larger compression ratio. For all models, our method outperforms other baselines with less computation. When applying our method to GAN Compression, we reduce the MACs of GauGAN by $40\times$ with minor performance degradation.
+
+Implementation details. The number of denoising steps for DDIM and PD are 100 and 8, respectively, and we use 50 and 5 steps for SDEdit. We dilate the difference mask by 5, 2, 5, and 1 pixels for DDIM, PD with resolution 128, PD with resolution 256 and GauGAN, respectively. Besides, we apply our sparse kernel to all convolution layers whose input feature map resolutions are larger than $32 \times 32$ , $16 \times 16$ , $8 \times 16$ and $16 \times 32$ for DDIM, PD, original GauGAN and GAN Compression, respectively. For DDIM [5] and PD [13], we pre-compute and reuse the statistics of the original image for all group normalization layers [84]. For GAN Compression [10], we pre-compute and reuse the statistics of the original image for all instance normalization layers [82] whose resolution is higher than $16 \times 32$ . For all models, the sparse block size for $3 \times 3$ convolution is 6 and $1 \times 1$ convolution is 4.
+
+# 4.1 Main Results
+
+Image quality. We report the quantitative results of applying our method on DDIM [5], Progressive Distillation (PD) [13], and GauGAN [8] in Table 1 and show the qualitative results in Figure 6. For PSNR and LPIPS, with $G.T.$ means computing the metric with the ground-truth images. With Orig. means computing the metric with the samples generated by the original model. On LSUN Church, we only use 431 synthetic images for the PSNR/LPIPS with $G.T.$ metrics, as manual editing does not have ground truths. For the other metrics, we use the entire LSUN Church dataset (431 synthetic + 23 manual). On Cityscapes, we view the synthetic semantic maps as the original input and the ground-truth semantic maps as the edited input for the PSNR/LPIPS with $G.T.$ metrics, which has 1505 samples. For the other metrics, we include symmetric editing (view the ground-truth semantic maps as the original inputs and synthetic semantic maps as the edited inputs), which has 3010 samples in total. For the models with method Patch and Ours, whose computation is editing dependent, we measure the average MACs over the whole dataset.
+
+For DDIM and Progressive Distillation, our method outperforms all baselines consistently and achieves results on par with the original model. The Patch inference fails when the edited region is small as the global context is insufficient. Although our method only applies convolutional filters to the local edited regions, we could reuse the global context stored in the original activations. Therefore, our method could perform the same as the original model. For GauGAN, our method also performs better than GAN Compression [10] with an even larger MACs reduction. When applying our method to GAN Compression, we further achieve a $\sim 40\times$ MACs reduction with minor performance degradation, beating both 0.19 GauGAN and GAN Comp. (S).
+
+
+Original
+
+
+1.20% Editing
+
+
+
+
+
+
+
+
+
+
+
+
+Original
+
+
+7.19% Editing
+
+
+DDIM:249G MACs
+FID:65.4
+
+
+Patch: 31.1G (8.0×)
+FID: 66.4
+
+
+Ours: 33.4G $(7.5\times)$ FID:65.8
+
+
+PD: 66.9G MACs
+FID: 90.0
+
+
+Ours: 24.5G (2.7×) FID: 90.1
+Ours: 29.4G $(2.3\times)$ FID: 90.1
+
+
+Original
+
+
+15.5% Editing
+
+
+DDIM:249G MACs FID:65.4.2
+DDIM:249G MACs FID:65.4.2
+
+
+Patch: 62.2G (4.0×)
+FID: 66.4
+Patch: 187G $(1.3\times)$ FID:66.4
+
+
+Ours:51.8G $(4.8\times)$ FID:65.8
+Ours: 78.9G (3.2×) FID:65.8
+
+
+PD: 66.9G MACs
+FID: 90.0
+PD: 66.9G MACs
+FID: 90.0
+
+
+Ours:37.6G $(1.8\times)$ FID:90.1
+
+
+Original
+
+
+1.18% Editing
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+GauGAN:281GMACs mIoU:62.4
+
+
+Ours:15.3G $(18\times)$ mIoU:62.1
+
+
+GAN Comp.: 31.2G (9.0× mIoU: 61.5
+GAN Comp.+Ours:5.59G $(50\times$ mIoU:60.1
+GAN Comp: 31.2G (9.0×)
+mIoU: 61.5
+
+
+
+
+Original
+Figure 6: Qualitative results of our method under different editing sizes. Our method well preserves the visual fidelity of the original model without losing global context. On the contrast, Patch (cropping the smallest image patch that covers all the edited regions and scatter the output patch back into the original image) performs poorly because of the lack of global context when the editing is small.
+
+
+13.5% Editing
+
+
+GauGAN:281GMACs mIoU:62.4
+
+
+Ours: 69.8G (4.0×)
+mIoL: 62.1
+GAN Comp.: 31.2G (9.0×) mIoU:61.5
+
+
+GAN Comp.+Ours: 8.54G (33×) mIoU: 60.1
+GAN Comp+Ours: 10.8G (26×) mIoU: 60.1
+
+Model efficiency. For real-world interactive image editing applications, inference acceleration on hardware is more critical than the computation reduction. To verify the effectiveness of our proposed engine, we measure the speedup of the editing examples shown in Figure 6 on four devices, including NVIDIA RTX 3090, NVIDIA RTX 2080Ti, Intel Core i9-10920X CPU, and Apple M1 Pro CPU, with different computational powers. We use batch size 1 to simulate real-world use. For GPU devices, we first perform 200 warm-up runs and measure the average latency of the next 200 runs. For CPU devices, we perform 10 warm-up runs and 10 test runs, repeat this process 5 times and report the average latency. The latency is measured in PyTorch $1.7^{\ddagger}$ . The results are shown in Table 2.
+
+The original Progressive Distillation [13] can only generate $128 \times 128$ images, which is too small for real use. We add some extra layers to adapt the model to resolution $256 \times 256$ . For fair comparisons, we also pre-compute the normalization parameters for the Crop baseline. When the editing pattern is like a rectangle, this baseline reduces similar computation with ours (e.g., the first example of DDIM in Figure 6). However, the speedup is still worse than ours on RTX 3090, 2080Ti and Intel Core i9-10920X due to the large memory index overheads in native PyTorch. When the edited region is far from a rectangle (e.g., the third example of DDIM), the cropped patches have much redundancy. Therefore, even though only $15.5\%$ region is edited, the MACs reduction is only $1.6 \times$ . With $1.2\%$ editing size, our method achieves a $7.5 \times$ , $4.6 \times$ , and $18 \times$ MACs reduction for DDIM, Progressive Distillation, and GauGAN, respectively. With SIGE, we achieve at most $4.1 \times$ , $2.9 \times$ , $6.0 \times$ and $14 \times$ speedup on RTX 3090, 2080Ti, Intel Core i9-10920X and Apple M1 Pro CPU, respectively. When applied to GAN Compression, SIGE achieves a $9.5 \times$ and $38 \times$ latency reduction on Intel Core i9-10920X and Apple M1 Pro CPU, respectively.
+
+| Model | Editing Size | Method | MACs | 3090 | 2080Ti | Intel Core i9-10920X | Apple M1 Pro |
| Value | Ratio | Value | Ratio | Value | Ratio | Value | Ratio | Value | Ratio |
| DDIM | - | Original | 248G | - | 37.5ms | - | 54.6ms | - | 609ms | - | 12.9s | - |
| 0.5 Original | 62.5G | 4.0× | 20.0ms | 1.9× | 31.2ms | 1.8× | 215ms | 2.8× | 3.22s | 4.0× |
| 1.20% | Crop | 32.6G | 7.6× | 15.5ms | 2.4× | 29.3ms | 1.9× | 185ms | 3.3× | 1.85s | 6.9× |
| Ours | 33.4G | 7.5× | 12.6ms | 3.0× | 19.1ms | 2.9× | 147ms | 4.1× | 1.96s | 6.6× |
| 15.5% | Crop | 155G | 1.6× | 30.5ms | 1.2× | 44.5ms | 1.2× | 441ms | 1.4× | 8.09s | 1.6× |
| Ours | 78.9G | 3.2× | 19.4ms | 1.9× | 29.8ms | 1.8× | 304ms | 2.0× | 5.04s | 2.6× |
| PD256 | - | Original | 119G | - | 35.1ms | - | 51.2ms | - | 388ms | - | 6.18s | - |
| 0.5 Original | 31.0G | 3.8× | 29.4ms | 1.2× | 43.2ms | 1.2× | 186ms | 2.1× | 1.72s | 3.6× |
| 1.20% | Ours | 25.9G | 4.6× | 18.6ms | 1.9× | 26.4ms | 1.9× | 152ms | 2.5× | 1.55s | 4.0× |
| 15.5% | Ours | 48.5G | 2.5× | 21.4ms | 1.6× | 30.7ms | 1.7× | 250ms | 1.6× | 3.22s | 1.9× |
| GauGAN | - | Original | 281G | - | 45.4ms | - | 49.5ms | - | 682ms | - | 14.1s | - |
| GAN Compression | 31.2G | 9.0× | 17.0ms | 2.7× | 25.0ms | 2.0× | 333ms | 2.1× | 2.11s | 6.7× |
| 1.18% | Ours | 15.3G | 18× | 11.1ms | 4.1× | 19.3ms | 2.6× | 114ms | 6.0× | 0.990s | 14× |
| GAN Comp.+Ours | 5.59G | 50× | 10.8ms | 4.2× | 16.2ms | 3.1× | 53.1ms | 13× | 0.370s | 38× |
| 13.5% | Ours | 69.8G | 4.0× | 17.8ms | 2.5× | 27.1ms | 1.8× | 238ms | 2.9× | 4.06s | 3.5× |
| GAN Comp.+Ours | 10.8G | 26× | 11.8ms | 3.8× | 17.4ms | 2.8× | 94.4ms | 7.2× | 0.741s | 19× |
+
+Table 2: Measured latency speedup on different devices. The detailed editing examples are shown in Figure 6. 0.5 Original: Linearly scaling each layer of the model to $50\%$ channels. Crop: For each convolution, we find a smallest patch covering the masked elements, crop it out, feed it into the convolution and scatter the output patch into the original image activation. Our method could reduce up to $18\times$ MACs, and achieve up to $4.1\times$ , $2.9\times$ , $6.0\times$ and $14\times$ latency reduction on NVIDIA RTX 3090, 2080Ti, Intel Core i9-10920X and M1 Pro CPU. With GAN Compression, we could further speed up GauGAN by $9.5\times$ on Intel Core-i9 and $38\times$ on Apple M1 Pro CPU.
+
+| MACs | Optimizations | Latency |
| Sparse | Norm. | Elem. | Sct. | Value | Ratio |
| 249G | | | | | 54.6ms | - |
| 32.6G (7.6×) | ✓ | | | | 34.0ms | 1.6× |
| ✓ | ✓ | | | 29.6ms | 1.8× |
| ✓ | ✓ | ✓ | | 20.7ms | 2.6× |
| ✓ | ✓ | ✓ | ✓ | 19.1ms | 2.9× |
+
+(a)
+
+| Method | Editing Size | MACs | PyTorch | TensorRT |
| Value Ratio | Value Ratio | Value Ratio |
| Original | - | 249G | - | 54.6ms | - | 47.7ms | - |
| Ours | 1.20% | 33.4G | 7.5× | 19.1ms | 2.9× | 14.4ms | 3.3× |
| 7.19% | 51.8G | 4.8× | 22.1ms | 2.5× | 18.6ms | 2.6× |
| 15.5% | 78.9G | 3.2× | 29.8ms | 1.8× | 26.9ms | 1.8× |
+
+(b)
+
+Table 3: (a) Ablation study of each kernel optimization. Sparse: Using tiling-based sparse convolution. Norm.: Pre-computing normalization parameters. Elem.: Fusing element-wise operations. Scct.: Fusing Scatter to reduce the tensor copying overheads. With all optimizations, we could reduce the latency of DDIM by $2.9 \times$ on NVIDIA RTX 2080Ti. (b) Latency comparisons of DDIM on RTX 2080Ti between PyTorch and TensorRT. The speedup ratio is larger in TensorRT than PyTorch, especially when the editing size is small.
+
+# 4.2 Ablation Study
+
+Below we perform several ablation studies to show the effectiveness of each design choice.
+
+Memory usage. The pre-computed activations of the original image require additional memory storage. We profile the peak memory usage of the original model and our method in PyTorch. Our method only increases the peak memory usage of a single forward for DDIM, PD, GauGAN, and GAN Compression by 0.1G, 0.1G, 0.8G, and 0.3G, respectively. Specifically, our method needs to store additional 169M, 56M, 275M, and 120M parameters for DDIM [5], PD [13], original GauGAN [8] and GAN Compression [10], respectively, for a single forward. For the diffusion models, we need to store activations for all iteration steps (e.g., 50 for DDIM and 5 for PD). However, data movement and kernel computation are asynchronized on GPU, so we could store the activations in CPU memory and load the on-demand ones on GPU to reduce peak memory usage.
+
+Speedup of each design. Table 3a shows the effectiveness of each kernel optimization we add to SIGE for DDIM [5] on RTX 2080Ti. Naively applying the tiling-based sparse convolution could reduce the computation by $7.6 \times$ . Still, the latency reduction is only $1.6 \times$ due to the large memory overheads in Gather and Scatter. Pre-computing the normalization parameters could remove the latency of normalization statistics calculation and reduce the overall latency to $29.6 \mathrm{~ms}$ . Fusing
+
+element-wise operations into the Gather and Scatter could remove some redundant operations that are applied to the unedited regions and also reduce the memory allocation overheads (about 9ms). Finally, fusing the Scatter and Gather to Scatter-Gather and Scatter in the shortcut branch and main branch could further reduce about 1.6ms tensor copying overheads, achieving $2.9 \times$ speedup.
+
+Experiments with TensorRT. Real-world model deployment also depends on deep learning backends with optimized libraries and runtimes. To demonstrate the effectiveness and extensibility of SIGE, we also implement our kernels in a widely-used backend TensorRT $^{\S}$ and benchmark the DDIM latency results on RTX 2080Ti in Table 3b. Specifically, our speedup ratio becomes more prominent with TensorRT compared to PyTorch, especially for small edits, as TensorRT better supports small convolutional kernels with higher GPU utilization than PyTorch.
+
+# 5 Conclusion & Discussion
+
+For image editing, existing deep generative models often waste computation by re-synthesizing the image regions that do not require modifications. To solve this issue, we have presented a general-purpose method, Spatially Sparse Inference (SSI), to selectively perform computation on edited regions, and Sparse Incremental Generative Engine (SIGE) to convert the computation reduction to latency reduction on commonly-used hardware. We have demonstrated the effectiveness of our approach in various hardware settings.
+
+Limitations. As discussed in Section 4.2, our method requires extra memory to store the original activations, which slightly increases the peak GPU memory usage. It may not work on certain memory-constrained devices, especially for the diffusion models (e.g., DDIM [5]), since our method requires storing activations of all denoising steps.
+
+Our engine has limited speedup on convolution with low resolution. When the input resolution is low, the active block size needs to be even smaller to get a decent sparsity, such as 1 or 2. However, such extremely small block sizes have bad memory locality and will result in low hardware efficiency.
+
+Besides, we sometimes observe noticeable boundary between the edited regions and unedited regions in our generated samples of GauGAN [8]. This is because, for GauGAN model, the unedited region will also change slightly when we perform normal inference. However, since our method does not update the unedited region, there may be some visible seams between the edited and unedited regions, even though the semantic is coherent. Dilating the difference mask would help reduce the gap.
+
+In most cases, the edit will only update the edited regions. However, sometimes the edit will also introduce global illumination changes such as shadow and reflection. For this case, as we only update the edited regions, we cannot update the global changes outside the edited regions accordingly.
+
+Societal impact. In this paper, we investigate how to update user editing locally without losing global coherence to enable smoother interaction with the generative models. In real-world scenarios, people could use an interactive interface to edit an image, and our method could provide a quick and high-quality preview for their editing, which eases the process of visual content creation and reduces energy consumption, leading to a greener AI application. The reduced cost also provides a good user experience for lower-end devices, which further democratize the applications of generative models.
+
+However, our method can be utilized by malicious users to generate fake contents, deceive people, and spread misinformation, which may lead to potential negative social impacts. Following previous works [9], we explicitly specify the usage permission of our engine with proper licenses. Additionally, we run a forensics detector [96] to detect the generated results of our method. On GauGAN, our generated images can be detected with $97.2\%$ average precision (AP). However, on DDIM [5] and Progressive Distillation [13], the APs are only $56.6\%$ and $52.4\%$ . Such low APs are caused by the model differences between GANs and diffusion models, as observed in SDEdit [9]. We believe developing forensic methods for diffusion models is a critical future research direction.
+
+Acknowledgment. We thank Yaoyao Ding, Zihao Ye, Lianmin Zheng, Haotian Tang, and Ligeng Zhu for the helpful comments on the engine design. We also thank George Cazenavette, Kangle Deng, Ruihan Gao, Daohan Lu, Sheng-Yu Wang and Bingliang Zhang for their valuable feedback. The project is partly supported by NSF, MIT-IBM Watson AI Lab, Kwai Inc, and Sony Corporation.
+
+# References
+
+[1] Ian Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron Courville, and Yoshua Bengio. Generative adversarial nets. NeurIPS, 2014. 1, 2
+[2] Tero Karras, Samuli Laine, and Timo Aila. A style-based generator architecture for generative adversarial networks. In CVPR, 2019. 1, 2
+[3] Jascha Sohl-Dickstein, Eric Weiss, Niru Maheswaranathan, and Surya Ganguli. Deep unsupervised learning using nonequilibrium thermodynamics. In ICML, 2015. 1, 2
+[4] Jonathan Ho, Ajay Jain, and Pieter Abbeel. Denoising diffusion probabilistic models. NeurIPS, 2020. 1, 2, 6
+[5] Jiaming Song, Chenlin Meng, and Stefano Ermon. Denoising diffusion implicit models. In ICLR, 2020. 1, 2, 6, 7, 9, 10, 17, 19, 20, 23
+[6] Phillip Isola, Jun-Yan Zhu, Tinghui Zhou, and Alexei A Efros. Image-to-image translation with conditional adversarial networks. In CVPR, 2017. 1, 2
+[7] Patsorn Sangkloy, Jingwan Lu, Chen Fang, Fisher Yu, and James Hays. Scribbler: Controlling deep image synthesis with sketch and color. In CVPR, 2017. 1
+[8] Taesung Park, Ming-Yu Liu, Ting-Chun Wang, and Jun-Yan Zhu. Semantic image synthesis with spatially-adaptive normalization. In CVPR, 2019. 1, 2, 6, 7, 9, 10, 19, 20, 24
+[9] Chenlin Meng, Yutong He, Yang Song, Jiaming Song, Jiajun Wu, Jun-Yan Zhu, and Stefano Ermon. SDEdit: Guided image synthesis and editing with stochastic differential equations. In ICLR, 2022. 1, 2, 6, 10, 19
+[10] Muyang Li, Ji Lin, Yaoyao Ding, Zhijian Liu, Jun-Yan Zhu, and Song Han. Gan compression: Efficient architectures for interactive conditional gans. In CVPR, 2020. 2, 3, 6, 7, 9, 19, 20
+[11] Fisher Yu, Yinda Zhang, Shuran Song, Ari Seff, and Jianxiong Xiao. Lsun: Construction of a large-scale image dataset using deep learning with humans in the loop. arXiv preprint arXiv:1506.03365, 2015. 2, 6, 20, 21
+[12] Marius Cordts, Mohamed Omran, Sebastian Ramos, Timo Rehfeld, Markus Enzweiler, Rodrigo Benenson, Uwe Franke, Stefan Roth, and Bernt Schiele. The cityscapes dataset for semantic urban scene understanding. In CVPR, 2016. 2, 6, 20, 21
+[13] Tim Salimans and Jonathan Ho. Progressive distillation for fast sampling of diffusion models. In ICLR, 2021. 2, 6, 7, 8, 9, 10, 19, 20
+[14] Liang Hou, Zehuan Yuan, Lei Huang, Huawei Shen, Xueqi Cheng, and Changhu Wang. Slimmable generative adversarial networks. In AAAI, 2021. 2, 3
+[15] Yonggan Fu, Wuyang Chen, Haotao Wang, Haoran Li, Yingyan Lin, and Zhangyang Wang. Autogandistiller: Searching to compress generative adversarial networks. In ICML, 2020. 2, 3
+[16] Shaojie Li, Mingbao Lin, Yan Wang, Chao Fei, Ling Shao, and Rongrong Ji. Learning efficient gans for image translation via differentiable masks and co-attention distillation. IEEE Transactions on Multimedia, 2022. 2, 3
+[17] Qing Jin, Jian Ren, Oliver J Woodford, Jiazhuo Wang, Geng Yuan, Yanzhi Wang, and Sergey Tulyakov. Teachers do more than teach: Compressing image-to-image models. In CVPR, 2021. 2, 3
+[18] Tamar Rott Shaham, Michael Gharbi, Richard Zhang, Eli Shechtman, and Tomer Michaeli. Spatially-adaptive pixelwise networks for fast image translation. In CVPR, 2021. 2, 3
+[19] Haotao Wang, Shupeng Gui, Haichuan Yang, Ji Liu, and Zhangyang Wang. Gan slimming: All-in-one gan compression by a unified optimization framework. In ECCV, 2020. 2, 3
+[20] Tero Karras, Samuli Laine, Miika Aittala, Janne Hellsten, Jaakko Lehtinen, and Timo Aila. Analyzing and improving the image quality of stylegan. In CVPR, 2020. 2
+[21] Andrew Brock, Jeff Donahue, and Karen Simonyan. Large scale gan training for high fidelity natural image synthesis. In ICLR, 2019. 2
+
+[22] Prafulla Dhariwal and Alexander Nichol. Diffusion models beat gans on image synthesis. NeurIPS, 2021. 2
+[23] Patrick Esser, Robin Rombach, and Bjorn Ommer. Taming transformers for high-resolution image synthesis. In CVPR, 2021. 2
+[24] Ali Razavi, Aaron Van den Oord, and Oriol Vinyals. Generating diverse high-fidelity images with vq-vae-2. In NeurIPS, volume 32, 2019. 2
+[25] Chitwan Sahara, William Chan, Huiwen Chang, Chris Lee, Jonathan Ho, Tim Salimans, David Fleet, and Mohammad Norouzi. Palette: Image-to-image diffusion models. In SIGGRAPH, 2022. 2
+[26] Jun-Yan Zhu, Taesung Park, Phillip Isola, and Alexei A Efros. Unpaired image-to-image translation using cycle-consistent adversarial networks. In ICCV, 2017. 2
+[27] Peihao Zhu, Rameen Abdal, Yipeng Qin, and Peter Wonka. Sean: Image synthesis with semantic region-adaptive normalization. In CVPR, 2020. 2
+[28] Alex Nichol, Prafulla Dhariwal, Aditya Ramesh, Pranav Shyam, Pamela Mishkin, Bob McGrew, Ilya Sutskever, and Mark Chen. Glide: Towards photorealistic image generation and editing with text-guided diffusion models. arXiv preprint arXiv:2112.10741, 2021. 2
+[29] Jooyoung Choi, Sungwon Kim, Yonghyun Jeong, Youngjune Gwon, and Sungroh Yoon. Ilvr: Conditioning method for denoising diffusion probabilistic models. In ICCV, 2021. 2
+[30] Gwanghyun Kim and Jong Chul Ye. Diffusionclip: Text-guided image manipulation using diffusion models. arXiv preprint arXiv:2110.02711, 2021. 2
+[31] Jun-Yan Zhu, Philipp Krahenbuhl, Eli Shechtman, and Alexei A Efros. Generative visual manipulation on the natural image manifold. In ECCV, 2016. 2
+[32] Or Patashnik, Zongze Wu, Eli Shechtman, Daniel Cohen-Or, and Dani Lischinski. Styleclip: Text-driven manipulation of stylegan imagery. In ICCV, 2021. 2
+[33] Rameen Abdal, Yipeng Qin, and Peter Wonka. Image2stylegan: How to embed images into the stylegan latent space? In ICCV, 2019. 2
+[34] Rameen Abdul, Yipeng Qin, and Peter Wonka. Image2stylegan++: How to edit the embedded images? In CVPR, 2020. 2
+[35] Andrew Howard, Mark Sandler, Grace Chu, Liang-Chieh Chen, Bo Chen, Mingxing Tan, Weijun Wang, Yukun Zhu, Ruoming Pang, Vijay Vasudevan, et al. Searching for mobilenetv3. In ICCV, 2019. 2
+[36] Andrew G Howard, Menglong Zhu, Bo Chen, Dmitry Kalenichenko, Weijun Wang, Tobias Weyand, Marco Andretto, and Hartwig Adam. Mobilenets: Efficient convolutional neural networks for mobile vision applications. arXiv preprint arXiv:1704.04861, 2017. 2
+[37] Mark Sandler, Andrew Howard, Menglong Zhu, Andrey Zhmoginov, and Liang-Chieh Chen. *Mobilenetv2: Inverted residuals and linear bottlenecks*. In *CVPR*, 2018. 2
+[38] Yang Song, Jascha Sohl-Dickstein, Diederik P Kingma, Abhishek Kumar, Stefano Ermon, and Ben Poole. Score-based generative modeling through stochastic differential equations. In ICLR, 2020. 2, 6
+[39] Zhifeng Kong and Wei Ping. On fast sampling of diffusion probabilistic models. In ICML Workshop on Invertible Neural Networks, Normalizing Flows, and Explicit Likelihood Models, 2021. 2
+[40] Zhisheng Xiao, Karsten Kreis, and Arash Vahdat. Tackling the generative learning trilemma with denoising diffusion GANs. In ICLR, 2022. 2
+[41] Song Han, Huizi Mao, and William J Dally. Deep Compression: Compressing Deep Neural Networks with Pruning, Trained Quantization and Huffman Coding. In ICLR, 2016. 2
+[42] Yihui He, Ji Lin, Zhijian Liu, Hanrui Wang, Li-Jia Li, and Song Han. AMC: AutoML for Model Compression and Acceleration on Mobile Devices. In ECCV, 2018. 2
+[43] Ji Lin, Yongming Rao, Jiwen Lu, and Jie Zhou. Runtime neural pruning. In NeurIPS, 2017. 2
+[44] Yihui He, Xiangyu Zhang, and Jian Sun. Channel pruning for accelerating very deep neural networks. In ICCV, 2017. 2
+
+[45] Zhuang Liu, Jianguo Li, Zhiqiang Shen, Gao Huang, Shoumeng Yan, and Changshui Zhang. Learning efficient convolutional networks through network slimming. In ICCV, 2017. 2
+[46] Zechun Liu, Haoyuan Mu, Xiangyu Zhang, Zichao Guo, Xin Yang, Kwang-Ting Cheng, and Jian Sun. MetaPruning: Meta Learning for Automatic Neural Network Channel Pruning. In ICCV, 2019. 2
+[47] Shuchang Zhou, Yuxin Wu, Zekun Ni, Xinyu Zhou, He Wen, and Yuheng Zou. Dorefa-net: Training low bitwidth convolutional neural networks with low bitwidth gradients. arXiv preprint arXiv:1606.06160, 2016.2
+[48] Mohammad Rastegari, Vicente Ordonez, Joseph Redmon, and Ali Farhadi. Xnor-net: Imagenet classification using binary convolutional neural networks. In ECCV, 2016. 2
+[49] Kuan Wang, Zhijian Liu, Yujun Lin, Ji Lin, and Song Han. HAQ: Hardware-Aware Automated Quantization with Mixed Precision. In CVPR. 2
+[50] Jungwook Choi, Zhuo Wang, Swagath Venkataramani, Pierce I-Jen Chuang, Vijayalakshmi Srinivasan, and Kailash Gopalakrishnan. Pact: Parameterized clipping activation for quantized neural networks. arXiv preprint arXiv:1805.06085, 2018. 2
+[51] Benoit Jacob, Skirmantas Kligys, Bo Chen, Menglong Zhu, Matthew Tang, Andrew Howard, Hartwig Adam, and Dmitry Kalenichenko. Quantization and training of neural networks for efficient integer-arithmetic-only inference. In CVPR, 2018. 2
+[52] Barret Zoph and Quoc V Le. Neural Architecture Search with Reinforcement Learning. In ICLR, 2017. 2
+[53] Barret Zoph, Vijay Vasudevan, Jonathon Shlens, and Quoc V. Le. Learning Transferable Architectures for Scalable Image Recognition. In CVPR, 2018. 2
+[54] Haoxiao Liu, Karen Simonyan, and Yiming Yang. DARTS: Differentiable Architecture Search. In ICLR, 2019. 2
+[55] Han Cai, Ligeng Zhu, and Song Han. ProxylessNAS: Direct Neural Architecture Search on Target Task and Hardware. In ICLR, 2019. 2
+[56] Mingxing Tan, Bo Chen, Ruoming Pang, Vijay Vasudevan, Mark Sandler, Andrew Howard, and Quoc V Le. MnasNet: Platform-Aware Neural Architecture Search for Mobile. In CVPR, 2019. 3
+[57] Bichen Wu, Xiaoliang Dai, Peizhao Zhang, Yanghan Wang, Fei Sun, Yiming Wu, Yuandong Tian, Peter Vajda, Yangqing Jia, and Kurt Keutzer. FBNet: Hardware-Aware Efficient ConvNet Design via Differentiable Neural Architecture Search. In CVPR, 2019. 3
+[58] Ji Lin, Wei-Ming Chen, Yujun Lin, John Cohn, Chuang Gan, and Song Han. Mcunet: Tiny deep learning on IoT devices. In NeurIPS, 2020. 3
+[59] Ji Lin, Richard Zhang, Frieder Ganz, Song Han, and Jun-Yan Zhu. Anycost gans for interactive image synthesis and editing. In CVPR, 2021. 3
+[60] Han Shu, Yunhe Wang, Xu Jia, Kai Han, Hanting Chen, Chunjing Xu, Qi Tian, and Chang Xu. Coevolutionary compression for unpaired image translation. In ICCV, 2019. 3
+[61] Yuchen Liu, Zhixin Shu, Yijun Li, Zhe Lin, Federico Perazzi, and Sun-Yuan Kung. Content-aware gan compression. In CVPR, 2021. 3
+[62] Ruixin Ma and Junying Lou. Cpgan: An efficient architecture designing for text-to-image generative adversarial networks based on canonical polyadic decomposition. Scientific Programming, 2021. 3
+[63] Angeline Aguinaldo, Ping-Yeh Chiang, Alex Gain, Ameya Patil, Kolten Pearson, and Soheil Feizi. Compressing gans using knowledge distillation. arXiv preprint arXiv:1902.00159, 2019. 3
+[64] Song Han, Jeff Pool, John Tran, and William Dally. Learning both weights and connections for efficient neural network. NeurIPS, 2015. 3
+[65] Hao Li, Asim Kadav, Igor Durdanovic, Hanan Samet, and Hans Peter Graf. Pruning filters for efficient convnets. *ICLR*, 2016. 3
+[66] Baoyuan Liu, Min Wang, Hassan Foroosh, Marshall Tappen, and Marianna Pensky. Sparse convolutional neural networks. In CVPR, 2015. 3
+
+[67] Max Jaderberg, Andrea Vedaldi, and Andrew Zisserman. Speeding up convolutional neural networks with low rank expansions. In BMVC, 2014. 3
+[68] Haotian Tang, Zhijian Liu, Xiuyu Li, Yujun Lin, and Song Han. Torchsparse: Efficient point cloud inference engine. In MLSys, 2022. 3
+[69] Gernot Riegler, Ali Osman Ulusoy, and Andreas Geiger. Octnet: Learning deep 3d representations at high resolutions. In CVPR, 2017. 3
+[70] Mengye Ren, Andrei Pokrovsky, Bin Yang, and Raquel Urtasun. Sbnet: Sparse blocks network for fast inference. In CVPR, 2018. 3, 4, 5
+[71] Patrick Judd, Alberto Delmas, Sayeh Sharify, and Andreas Moshovos. Cnvlutin2: Ineffectual-activation-and-weight-free deep neural network computing. arXiv preprint arXiv:1705.00125, 2017. 3
+[72] Shaohuai Shi and Xiaowen Chu. Speeding up convolutional neural networks by exploiting the sparsity of rectifier units. arXiv preprint arXiv:1704.07724, 2017. 3
+[73] Xuanyi Dong, Junshi Huang, Yi Yang, and Shuicheng Yan. More is less: A more complicated network with less inference complexity. In CVPR, 2017. 3
+[74] Bowen Pan, Wuwei Lin, Xiaolin Fang, Chaoqin Huang, Bolei Zhou, and Cewu Lu. Recurrent residual module for fast inference in videos. In CVPR, 2018. 3
+[75] Xiaoxiao Li, Ziwei Liu, Ping Luo, Chen Change Loy, and Xiaou Tang. Not all pixels are equal: Difficulty-aware semantic segmentation via deep layer cascade. In CVPR, 2017. 3
+[76] Thomas Verelst and Tinne Tuytelaars. Dynamic convolutions: Exploiting spatial sparsity for faster inference. In CVPR, 2020. 3
+[77] Longguang Wang, Xiaoyu Dong, Yingqian Wang, Xinyi Ying, Zaiping Lin, Wei An, and Yulan Guo. Exploring sparsity in image super-resolution for efficient inference. In CVPR, 2021. 3
+[78] Yizeng Han, Gao Huang, Shiji Song, Le Yang, Yitian Zhang, and Haojun Jiang. Spatially adaptive feature refinement for efficient inference. TIP, 2021. 3
+[79] Yulin Wang, Yang Yue, Yuanze Lin, Haojun Jiang, Zihang Lai, Victor Kulikov, Nikita Orlov, Humphrey Shi, and Gao Huang. Adafocus v2: End-to-end training of spatial dynamic networks for video recognition. In CVPR, 2022. 3
+[80] Mathias Parger, Chengcheng Tang, Christopher D Twigg, Cem Keskin, Robert Wang, and Markus Steinberger. Deltacnn: End-to-end cnn inference of sparse frame differences in videos. In CVPR, 2022. 3
+[81] Sergey Ioffe and Christian Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In ICML, 2015. 5
+[82] Dmitry Ulyanov, Andrea Vedaldi, and Victor Lempitsky. Instance normalization: The missing ingredient for fast stylization. arXiv preprint arXiv:1607.08022, 2016. 5, 7
+[83] Xun Huang and Serge Belongie. Arbitrary style transfer in real-time with adaptive instance normalization. In ICCV, 2017. 5
+[84] Yuxin Wu and Kaiming He. Group normalization. In ECCV, 2018. 5, 7
+[85] Alexander Quinn Nichol and Prafulla Dhariwal. Improved denoising diffusion probabilistic models. In ICML, 2021. 5
+[86] Yaoyao Ding, Ligeng Zhu, Zhihao Jia, Gennady Pekhimenko, and Song Han. Ios: Inter-operator scheduler for cnn acceleration. MLSys, 2021. 5
+[87] Zhihao Jia, Oded Padon, James Thomas, Todd Warszawski, Matei Zaharia, and Alex Aiken. Taso: optimizing deep learning computation with automatic generation of graph substitutions. In SOSP, 2019. 5
+[88] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In CVPR, 2016. 5, 17
+[89] Geoffrey Hinton, Oriol Vinyls, Jeff Dean, et al. Distilling the knowledge in a neural network. arXiv preprint arXiv:1503.02531, 2(7), 2015. 6
+
+[90] Xingyi Zhou, Rohit Girdhar, Armand Joulin, Philipp Krahenbuhl, and Ishan Misra. Detecting twenty-thousand classes using image-level supervision. In arXiv preprint arXiv:2201.02605, 2021. 6
+[91] Shengyu Zhao, Jonathan Cui, Yilun Sheng, Yue Dong, Xiao Liang, Eric I Chang, and Yan Xu. Large scale image completion via co-modulated generative adversarial networks. In ICLR, 2021. 6
+[92] Richard Zhang, Phillip Isola, Alexei A Efros, Eli Shechtman, and Oliver Wang. The unreasonable effectiveness of deep features as a perceptual metric. In CVPR, 2018. 6
+[93] Martin Heusel, Hubert Ramsauer, Thomas Unterthiner, Bernhard Nessler, and Sepp Hochreiter. Gans trained by a two time-scale update rule converge to a local nash equilibrium. NeurIPS, 2017. 6
+[94] Gaurav Parmar, Richard Zhang, and Jun-Yan Zhu. On aliased resizing and surprising subtleties in gan evaluation. In CVPR, 2022. 6
+[95] Fisher Yu, Vladlen Koltun, and Thomas Funkhouser. Dilated residual networks. In CVPR, 2017. 6
+[96] Sheng-Yu Wang, Oliver Wang, Richard Zhang, Andrew Owens, and Alexei A Efros. Cnn-generated images are surprisingly easy to spot... for now. In CVPR, 2020. 10
+[97] Han Zhang, Ian Goodfellow, Dimitris Metaxas, and Augustus Odena. Self-attention generative adversarial networks. In ICML, 2019. 19
+[98] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. NeurIPS, 2017. 19
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See Section 5.
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] See Section 5.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] See Section 4.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Section 4.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Appendix D.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [Yes] See Appendix D.
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] Our code and benchmark datasets are available at https://github.com/lmxyy/sige.
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [Yes] See Appendix D.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes] See Section 5.
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/images.zip b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..23d426a6879665d7d3b984a2dd77c244e8b17c33
--- /dev/null
+++ b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:353844042284ae35b4777ed0efa726a2414ce83a80f5915cb01d2b942ecae72f
+size 659108
diff --git a/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/layout.json b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..288dcb4eef84437b35a61ec8868736574c254795
--- /dev/null
+++ b/efficientspatiallysparseinferenceforconditionalgansanddiffusionmodels/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c4bd426d6796b049bd47b712acc47e3ae9c27791d95793ccf882f5ee9401406a
+size 688352
diff --git a/efficientsubmodularoptimizationundernoiselocalsearchisrobust/1aaa8cab-844a-4d86-985f-a358ab2610fd_content_list.json b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/1aaa8cab-844a-4d86-985f-a358ab2610fd_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..6ac538349e00e847cc729d82a123fe8324e59a4d
--- /dev/null
+++ b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/1aaa8cab-844a-4d86-985f-a358ab2610fd_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a948f3192ace8b693263a6a01ba5605daf9745014682c212d68a54f74797aa42
+size 83982
diff --git a/efficientsubmodularoptimizationundernoiselocalsearchisrobust/1aaa8cab-844a-4d86-985f-a358ab2610fd_model.json b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/1aaa8cab-844a-4d86-985f-a358ab2610fd_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..3f99df13901bf29580faa481243d1cbd82baa07c
--- /dev/null
+++ b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/1aaa8cab-844a-4d86-985f-a358ab2610fd_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0a41d152e5d94cd165fd64989c8941a4805e0a0eb1e61a489687b0cf6ab09754
+size 103112
diff --git a/efficientsubmodularoptimizationundernoiselocalsearchisrobust/1aaa8cab-844a-4d86-985f-a358ab2610fd_origin.pdf b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/1aaa8cab-844a-4d86-985f-a358ab2610fd_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..6abfd03b116b00d05a596dae0e1d6738f716a360
--- /dev/null
+++ b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/1aaa8cab-844a-4d86-985f-a358ab2610fd_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8aa0e08f36145ebee0d5b12f27c33c5ed8f991799f4db8c66b44357b05174d61
+size 390478
diff --git a/efficientsubmodularoptimizationundernoiselocalsearchisrobust/full.md b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..411ec39072c59d6ddf64a58b5e6fadda41ae9545
--- /dev/null
+++ b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/full.md
@@ -0,0 +1,337 @@
+# Efficient Submodular Optimization under Noise: Local Search is Robust
+
+Lingxiao Huang
+Huawei TCS Lab -> Nanjing University
+huanglingxiao1990@126.com
+
+Chunxue Yang
+Nanyang Technological University
+chunxue001@e.ntu.edu.sg
+
+Yuyi Wang
+Swiss Federal Institute of Technology
+yuyiwang920@gmail.com
+
+Huanjian Zhou
+The University of Tokyo
+zhou@ms.k.u-tokyo.ac.jp
+
+# Abstract
+
+The problem of monotone submodular maximization has been studied extensively due to its wide range of applications. However, there are cases where one can only access the objective function in a distorted or noisy form because of the uncertain nature or the errors involved in the evaluation. This paper considers the problem of constrained monotone submodular maximization with noisy oracles introduced by [11]. For a cardinality constraint, we propose an algorithm achieving a near-optimal $\left(1 - \frac{1}{e} - O(\varepsilon)\right)$ -approximation guarantee (for arbitrary $\varepsilon > 0$ ) with only a polynomial number of queries to the noisy value oracle, which improves the exponential query complexity of [20]. For general matroid constraints, we show the first constant approximation algorithm in the presence of noise. Our main approaches are to design a novel local search framework that can handle the effect of noise and to construct certain smoothing surrogate functions for noise reduction.
+
+# 1 Introduction
+
+Consider the following problems in machine learning and operations research: (1) selecting a set of locations to open up facilities with the goal of maximizing their overall user coverage [15]; (2) reducing the number of features in a machine learning model while retaining as much information as possible [23]; and (3) identifying a small set of seed nodes that can achieve the largest overall influence in a social network [14]. Solving these problems all involves maximizing a monotone submodular set function $f: 2^{N} \mapsto \mathbb{R}$ subject to certain constraints. Intuitively, submodularity captures the property of diminishing returns. For example, a newly opened facility will contribute less to the overall user coverage if we have already opened many facilities and more if we have only opened a few. Although the general problem of monotone submodular maximization subject to a cardinality or general matroid constraint is NP-hard [5], the greedy algorithm, which selects an element with the largest margin at each step, can approximately solve this problem under a cardinality constraint by a factor of $1 - 1/e$ , and this approximation ratio is tight [18]. Moreover, a non-oblivious local search algorithm, which iteratively alters one element to improve an auxiliary objective function, is guaranteed to achieve an approximation ratio of $1 - 1/e$ for general matroid constraints [7].
+
+In the literature, the submodular optimization problem usually assumes a value oracle to the objective function $f$ , which means one is allowed to query the exact value of $f(S)$ for any $S \subseteq N$ . However, in many applications, due to the uncertain nature of the objective or the errors involved in the evaluation, one can only access the function value in a distorted or noisy form. For example, Globerson and Roweis [9] pointed out that selecting features to construct a robust learning model is particularly
+
+important in domains with non-stationary feature distributions or input sensor failures. It is known that without any assumption on the noise, direct adoptions of the greedy and local search methods mentioned above may yield arbitrarily poor performance [12]. To address this issue, Hassidim and Singer [11] introduced and studied the following problem of monotone submodular maximization under noise: For a monotone submodular function $f$ , given a noisy value oracle $\tilde{f}$ satisfying $\tilde{f}(S) = \xi_S f(S)$ for each set $S \subseteq N$ , where the noise multiplier $\xi_S$ is independently drawn from a certain distribution, the goal is to find a set $S$ maximizing $f(S)$ under certain constraints. Some applications of this problem are provided in [20] such as revealed preference theory [3] and active learning [6]. Hassidim and Singer [11] showed that under a sufficiently large cardinality constraint, a variant of the greedy algorithm achieves a near-optimal approximation ratio of $1 - \frac{1}{e} - O(\varepsilon)$ for arbitrary $\varepsilon > 0$ . The problem becomes more challenging when the cardinality constraint is relatively small since there is less room for mistakes. In a subsequent work, Singer and Hassidim [20] developed another greedy-based algorithm for small cardinality constraints and showed a near-tight approximation guarantee.
+
+Despite these encouraging results, we want to point out two directions along this line of monotone submodular maximization under noise that still have room for improvements:
+
+- In the algorithm from [20], the query complexity to the noisy value oracle is exponential in $\varepsilon^{-1}$ , which is costly when a near-optimal solution is needed, i.e., when the parameter $\varepsilon$ is close to 0. Is it possible to obtain near-optimal approximations for monotone submodular maximization under cardinality constraints with the number of queries polynomial in $\varepsilon^{-1}$ ?
+- All previous works in submodular maximization under noise consider only the cardinality constraint, and no approximation guarantee is known under other constraints. Is there any algorithm that can achieve a constant approximation for submodular maximization under noise for more general constraints, such as commonly studied matroid constraints [16, 26]?
+
+In this paper, we provide answers to both questions above.
+
+# 1.1 Our contributions
+
+We study the problem of constrained monotone submodular maximization under noise (Problem 2.6). Following prior works [11, 20], we assume generalized exponential tail noises (Definition 2.5) and consider the solutions subject to cardinality constraints (Definition 2.2) and matroid constraints (Definition 2.3). The main contribution of this work is to show that for optimizing a monotone submodular function under a cardinality constraint, $\left(1 - \frac{1}{\varepsilon} - O(\varepsilon)\right)$ -approximations can be obtained with high probability by querying the noisy oracle only Poly $(n, \frac{1}{\varepsilon})$ times.
+
+Theorem 1.1 (Informal, see Theorems 4.1 and 4.6). Let $\varepsilon > 0$ and assume $n$ is sufficiently large. For any $r \in \Omega\left(\frac{1}{\varepsilon}\right)$ , there exists an algorithm that returns a $\left(1 - \frac{1}{e} - O(\varepsilon)\right)$ -approximation for the monotone submodular maximization problem under a $r$ -cardinality constraint, with probability $1 - o(1)$ and query complexity Poly $(n, \frac{1}{\varepsilon})$ to $\tilde{f}$ .
+
+For a cardinality constraint, this paper and prior works [11, 20] all achieve near-optimal approximations. However, our result is applicable for a larger range $\Omega\left(\frac{1}{\varepsilon}\right)$ of cardinalities than $\Omega\left(\log \log n \cdot \varepsilon^{-2}\right)$ in [11]. Moreover, we only require Poly $(n, \frac{1}{\varepsilon})$ queries to the noisy value oracle, which improves the query complexity $\Omega(n^{\frac{1}{\varepsilon}})$ of [20].
+
+Our main idea to address this problem is to employ a local search procedure, whereas prior methods are all variants of the greedy algorithm. Intuitively, local search is more robust than the greedy since the marginal functions are more sensitive to noise than the value functions. To achieve a sufficient gain in each iteration, the greedy algorithm must identify the element with maximum margin. In contrast, local search only needs to estimate the sets' values. This is why we can improve the query complexity to Poly $(n,\frac{1}{\varepsilon})$ for small cardinality constraints.
+
+We present a unified framework (Algorithm 1) for enhancing the local search to cope with noise. One of the main differences between our framework and the non-oblivious local search proposed by [7] is that we use an approximation of the auxiliary function (Definition 3.2) rather than the exact
+
+one due to the presence of noise. We analyze the impact of the inaccuracies on the approximation performance and query complexity of the local search (Theorem 3.3).
+
+Another difference is the construction of the auxiliary functions used to guide the local search. We construct the auxiliary function not based on the objective function but on smoothing surrogate functions.
+
+A surrogate function $h$ needs to meet two properties: (i) $h$ should depend on an averaging set of size $\mathrm{poly}(n)$ , such that $h(S)$ and its noisy analogue $\tilde{h}(S)$ are close for all sets $S$ considered by local search; (ii) $h$ needs to be close to the original function $f$ , such that optimizing $h$ can yield a near-optimal solution to optimizing $f$ . However, a large averaging set is more likely to induce a large gap between the surrogate and original function, making simultaneous fulfillment of both properties non-trivial.
+
+In this paper we carefully design the smoothing surrogate functions as follows. For a set with size $r \in \Omega\left(\frac{1}{\varepsilon}\right) \cap O\left(n^{1/3}\right)$ , we define the smoothing surrogate function $h$ as the expectation of $f$ 's value when a random element in $N$ is added to the set (Definition 4.2). This surrogate function is robust for a relatively small cardinality as it is based on a rather large averaging set with size nearly $n$ , but too concentrated for a large cardinality close to $n$ . Thus, we consider another smoothing surrogate function $h_H$ for size $r \in \Omega\left(n^{1/3}\right)$ , defined as the average value combined with all subsets of a certain small-size set $H$ (Definition 4.7). The auxiliary functions constructed on both smoothing surrogates are shown to have almost accurate approximations (Lemma 4.4 and 4.9). Consequently, we can apply our unified local search framework (Algorithm 1) in both cases (Algorithm 2 and 3), and guarantee to achieve nearly tight approximate solutions (Theorem 4.1 and 4.6).
+
+The other contribution of this paper is a constant approximation result for maximizing monotone submodular functions with noisy oracles under general matroid constraints.
+
+Theorem 1.2 (Informal, see Theorems 5.1 and 5.2). Let $\varepsilon > 0$ and assume $n$ is sufficiently large. For any $r \in \Omega$ ( $\varepsilon^{-1} \log(\varepsilon^{-1})$ ), there exists an algorithm that returns a $\left(\frac{1}{2}\left(1 - \frac{1}{e}\right) - O(\varepsilon)\right)$ -approximation for the monotone submodular maximization problem under a matroid constraint with rank $r$ , with probability $1 - o(1)$ and query complexity at most Poly $(n, \frac{1}{\varepsilon})$ to $\tilde{f}$ .
+
+To the best of our knowledge, this is the first result showing that constant approximation guarantees are obtainable under general matroid constraints in the presence of noise. To cope with noise, one common approach for cardinality constraints is to incorporate some extra elements to gain robustness and include these elements in the final solutions. However, for a matroid, additional elements may undermine the independence of a set. To address this difficulty, we develop a technique for comparing the values of independent sets in the presence of noise, which allows us to select either the local search solutions or the additional elements for robustness and leads to an approximation ratio of $\frac{1}{2}\left(1 - \frac{1}{e}\right)$ .
+
+# 1.2 Related work
+
+Research has been conducted on monotone submodular maximization in the presence of noise. We say a noisy oracle is inconsistent if it returns different answers when repeatedly queried. For inconsistent oracles, noise often does not present a barrier to optimization, since concentration assumptions can eliminate the noise after a sufficient number of queries [21, 13]. When identical queries always obtain the same answer, the problem becomes more challenging. Aside from the i.i.d noise adopted in [11, 20] and this paper, Horel and Singer [12] study submodular optimization under noise adversarially generated from $[1 - \varepsilon /r,1 + \varepsilon /r]$ , where the greedy algorithm achieves a ratio of $1 - 1 / e - O(\varepsilon)$ . No algorithm can obtain a constant approximation if noise is not bounded in this range.
+
+# 2 The model
+
+This section formally defines our model (Problem 2.6) of maximizing a monotone submodular function (Definition 2.1) under a cardinality constraint (Definition 2.2) or a matroid constraint (Definition 2.3), given access to a noisy value oracle (Definition 2.4). Let $N$ be the ground set with size $|N| = n$ , and we use the shorthands $S + x = S \cup \{x\}$ and $S - x = S \setminus \{x\}$ throughout this paper. We first review the definition of monotone submodular functions.
+
+Definition 2.1 (Monotone submodular functions). A function $f: 2^N \to \mathbb{R}_{\geq 0}$ is monotone submodular if 1) (monotonicity) $f(A) \leq f(B)$ for any $A \subseteq B \subseteq N$ ; 2) (submodularity) for any subset $A, B \subseteq N$ and $x \in N$ : $f(A + x) - f(A) \geq f(B + x) - f(B)$ .
+
+There are various examples of monotone submodular functions in optimization, such as budget additive functions, coverage functions, cut functions and rank functions [1]. Since the description of a submodular function may be exponential in the size $N$ , we usually assume access of a value oracle that answers $f(S)$ for each $S \subseteq N$ . Let $\mathcal{I}$ denote a collection of feasible subsets $S \subseteq N$ . The goal of a constrained monotone submodular maximization is to find a subset $S \subseteq \mathcal{I}$ to maximize $f(S)$ . The objective $f$ is further assumed to be normalized, i.e., $f(\emptyset) = 0$ . We consider two types of constraints in our models: cardinality constraints and matroid constraints.
+
+Definition 2.2 (Cardinality constraints). Given a ground set $N$ and an integer $r \geq 1$ , a cardinality constraint is of the form $\mathcal{I}(r) = \{S \subseteq N : |S| \leq r\}$ .
+
+Definition 2.3 (Matroids and Matroid constraints). Given a ground set $N$ , a matroid $\mathcal{M}$ is represented by an ordered pair $(N, \mathcal{I}(\mathcal{M}))$ satisfying that 1) $\varnothing \in \mathcal{I}(\mathcal{M})$ ; 2) If $I \in \mathcal{I}(\mathcal{M})$ and $I' \subseteq I$ , then $I' \in \mathcal{I}(\mathcal{M})$ ; 3) If $I_1, I_2 \subseteq \mathcal{I}(\mathcal{M})$ and $|I_1| < |I_2|$ , then there must exist an element $e \in I_2 \setminus I_1$ such that $I_1 \cup \{e\} \in \mathcal{I}(\mathcal{M})$ . Each $I \in \mathcal{I}(\mathcal{M})$ is called an independent set. The maximum size of an independent set is called the rank of $\mathcal{M}$ . We call the collection $\mathcal{I}(\mathcal{M})$ a matroid constraint.
+
+Assume we are given a membership oracle of $\mathcal{I}(\mathcal{M})$ that for any set $S\subseteq N$ answers whether $S\in \mathcal{I}(\mathcal{M})$ . As a widely used combinatorial structure, there is an extensive study on matroids [28, 19, 27]. Common matroids include uniform matroids, partition matroids, regular matroids, etc. See [19] for more discussions. Specifically, a uniform matroid constraint is equivalent to a cardinality constraint, implying that cardinality constraints are a special case of matroid constraints.
+
+Noisy value oracle. It is well known that given an exact value oracle to $f$ , for any $\varepsilon > 0$ , there exists a randomized $(1 - 1 / e - \varepsilon)$ -approximate algorithm for the submodular optimization problem under a matroid constraint, i.e., $\max_{S \subseteq \mathcal{I}} f(S)$ [2, 7]. However, as discussed earlier, the value oracle of $f$ may be imperfect, and we may only have a noisy value oracle $\tilde{f}$ instead of $f$ . We consider the following noisy value oracle that has also been investigated in [12, 11].
+
+Definition 2.4 ((Multiplicative) noisy value oracle [11]). We call $\tilde{f}: 2^N \to \mathbb{R}_{\geq 0}$ a (multiplicative) noisy value oracle of $f$ , if there exists some distribution $\mathcal{D}$ s.t. for any $S \subseteq N$ , $\tilde{f}(S) = \xi_S f(S)$ where $\xi_S$ is i.i.d. drawn from $\mathcal{D}$ .
+
+Throughout this paper, we consider a general class of noise distributions, called generalized exponential tail distributions, defined in [20].
+
+Definition 2.5 (Generalized exponential tail distributions [20]). A noise distribution $\mathcal{D}$ has a generalized exponential tail if there exists some $x_0$ such that for every $x > x_0$ the probability density function $\rho(x) = e^{-g(x)}$ , where $g(x) = \sum_{i} c_i x^{\gamma_i}$ for some (not necessarily integers) $\gamma_0 \geq \gamma_1 \geq \ldots$ , s.t. $\gamma_0 \geq 1$ and $c_0 > 0$ . If $\mathcal{D}$ has bounded support we only require that either it has an atom at its supremum or that $\rho$ is continuous and non-zero at the supremum.
+
+W.l.o.g., we assume $\mathbb{E}[\mathcal{D}] = 1$ . As mentioned in [20], the class of generalized exponential tail distributions contains Gaussian distributions, exponential distributions, and all distributions with bounded support that is independent of $n$ .
+
+The model. We are ready to propose the main problem, which has already been considered in [11, 20].
+
+Problem 2.6 (Constrained submodular optimization under noise). Given a noisy value oracle $\tilde{f}: 2^N \to \mathbb{R}_{\geq 0}$ (with a certain generalized exponential tail distribution $\mathcal{D}$ ) to an underlying monotone submodular function $f$ , and a cardinality constraint $\mathcal{I} = \mathcal{I}(r)$ or a matroid constraint $\mathcal{I} = \mathcal{I}(\mathcal{M})$ , the goal is to find $S \subseteq \mathcal{I}$ to maximize $f(S)$ .
+
+# 3 Local search with approximate evaluation oracles to auxiliary functions
+
+This section proposes a non-oblivious local search framework with a noisy value oracle (Algorithm 1), and gives an analysis (Theorem 3.3) of its performance. This algorithm is a generalization of that
+
+in [7] and will be used as a meta-algorithm for solving Problem 2.6 in Sections 4 and 5. Roughly speaking, a local search framework first constructs a "good" initial solution via a standard greedy algorithm and then iteratively improves the solution w.r.t. to an auxiliary function (Definition 3.1) by swapping an element at each step. The following auxiliary function proposed by [7] is a linear combination of the original function over all subsets.
+
+Definition 3.1 (Auxiliary function [7]). Given a monotone submodular function $h:2^{N}\to \mathbb{R}_{\geq 0}$ , its auxiliary function $\varphi_h:2^N\to \mathbb{R}_{\geq 0}$ is defined as $\varphi_h(S) = \sum_{T\subseteq S}m_{|S| - 1,|T| - 1}\cdot h(T)$ , where $m_{s,t} = \int_0^1 e^p (e - 1)^{-1}p^t (1 - p)^{s - t}dp$ for all $s\geq t\geq 0$ .
+
+We use $h$ instead of $f$ because we may do local search on certain smoothing surrogate function $h$ of $f$ (see examples in Definitions 4.2 and 4.7). Note that $\varphi_h$ is also a monotone submodular function. Given an exact value oracle of $\varphi_h$ and a matroid constraint $\mathcal{I}(\mathcal{M})$ , Filmus and Ward [7] show that there exists a local search algorithm that outputs a $(1 - 1/e)$ -approximate solution for the optimization problem $\max_{S \subseteq \mathcal{I}(\mathcal{M})} h(S)$ . However, as mentioned before, we do not have an exact value oracle of $h$ . Thus, it may not be possible to construct an exact value oracle of $\varphi_h$ . To understand how these inaccuracies can affect the performance of the local search algorithm, we introduce the following approximation for the auxiliary function $\varphi_h$ .
+
+Definition 3.2 $((\alpha, \delta, \mathcal{I}(\mathcal{M}))$ -approximation of $\varphi_h$ ). Given an auxiliary function $\varphi_h$ , a matroid constraint $\mathcal{I}(\mathcal{M})$ and constants $\alpha, \delta > 0$ , we say a randomized function $\widehat{\varphi_h}$ is an $(\alpha, \delta, \mathcal{I}(\mathcal{M}))$ -approximation of $\varphi_h$ if for any independent set $A \in \mathcal{I}(\mathcal{M})$ ,
+
+$$
+\mathbb {P} \left[ | \widehat {\varphi_ {h}} (A) - \varphi_ {h} (A) | > \alpha \cdot \max _ {S \in \mathcal {I} (\mathcal {M})} \varphi_ {h} (S) \right] \leq \delta .
+$$
+
+Intuitively, $\widehat{\varphi_h}$ is a randomized version of $\varphi_h$ with an additive concentration guarantee, where the randomness may come from noise of $h$ or sampling error for estimating $\varphi_h$ . As $\alpha, \delta$ tend to 0, $\widehat{\varphi_h}$ is a better approximation of $\varphi_h$ . Specifically, when $\alpha = \delta = 0$ and $\mathcal{I} = 2^N$ , $\widehat{\varphi_h}$ is exactly equivalent to $\varphi_h$ . Now we are ready to provide our local search framework (Algorithm 1), which is a generalization of [7, Algorithm 2]. The main difference is that we use an approximation $\widehat{\varphi_h}$ instead of $\varphi_h$ for evaluation at each greedy step (Line 4) and local search step (Line 12). The performance of Algorithm 1 is summarized in Theorem 3.3.
+
+Algorithm 1: Noisy local search (NLS( $\widehat{\varphi_h},\mathcal{I}(\mathcal{M}),\Delta)$
+Input: A matroid constraint $\mathcal{I}(\mathcal{M})$ of rank $r\geq 1$ , a value oracle to an $(\alpha ,\delta ,\mathcal{I}(\mathcal{M}))$ -approximation $\widehat{\varphi_h}$ of $\varphi_{h}$ , a stepsize $\Delta \in (0,1 / 2)$
+1 Set $I\gets \left[\log_{1 + \Delta}\left(\frac{2(1 + \alpha)}{1 - 2(r + 1)\alpha}\right)\right]$
+2 Initialize: $U_{0}\gets \emptyset$ $i = 1$
+3 while $i\leq r$ do
+4 $\begin{array}{rl} & u_i\gets \arg \max_{e:U_{i - 1} + e\in \mathcal{I}(\mathcal{M})}\widehat{\varphi_h} (U_{i - 1} + e)\\ & U_i\gets U_{i - 1} + u_i\\ & i\gets i + 1 \end{array}$
+5
+6
+7 $S_0\gets U_r$ ▷ Initial solution by greedy
+8 for $i = 0$ to $I - 1$ do ▷ Local search for $I$ iterations
+9 for each element $x\in S_i$ and $y\in N\setminus S_i$ do
+10 $\begin{array}{l}S_i'\gets S_i - x + y\\ \text{if} S_i'\in \mathcal{I}(\mathcal{M})\text{then}\\ \text{if}\widehat{\varphi_h} (S_i')\geq (1 + \Delta)\cdot \widehat{\varphi_h} (S_i)\text{then}\quad \triangleright \text{An improved solution} S_i'\text{was found}\\ S_{i + 1}\gets S_i'\text{break and continue to the next iteration of} i \end{array}$
+11
+
+Theorem 3.3 (Performance of noisy local search). Let $I = \log_{1 + \Delta}\left(\frac{2(1 + \alpha)}{1 - 2(r + 1)\alpha}\right)$ . With probability at least $1 - (I + 1)rn\delta$ , the output $S_I$ of Algorithm 1 is a $\left(1 - \frac{1}{e}\right)(1 - r\ln (er)((2 + \Delta)\alpha +\Delta))$ -approximate solution for problem $\max_{S\subseteq \mathcal{I}(\mathcal{M})}h(S)$ , with at most $(I + 1)rn$ calls to $\widehat{\varphi_h}$ .
+
+We defer the proof to Section C. Roughly, given a nearly accurate approximation $\widehat{\varphi_h}$ , we can show that the initial solution $S_0$ is likely to be a constant approximation for $\max_{S\in \mathcal{I}(\mathcal{M})}\varphi_h(S)$ (Lemma C.1). This guarantees that we will reach a local optimal solution w.r.t. $\varphi_h$ in $I$ iterations with high probability (Claim C.3). Then combining with basic properties of $\varphi_h$ shown in [7] and the fact that $\widehat{\varphi_h}$ is "close" to $\varphi_h$ , we obtain Theorem 3.3.
+
+Corollary 3.4. Assume $n \in \Omega \left( \exp \left( \left( \frac{1}{\varepsilon} \right)^{O(1)} \right) \right)$ , if $\alpha, \Delta = \frac{\varepsilon}{4r\log r}$ , we have $I \leq \frac{5r\ln r}{\varepsilon}$ , and with probability at least $1 - (I + 1)rn\delta$ , the output $S_I$ of Algorithm 1 is a $\left( 1 - \frac{1}{e} - \varepsilon \right)$ -approximate solution for problem $\max_{S \subseteq \mathcal{I}(\mathcal{M})} h(S)$ , with at most $(I + 1)rn$ calls to $\widehat{\varphi_h}$ .
+
+# 4 Our algorithms and main theorems for cardinality constraints
+
+For different ranges of cardinalities, this section presents algorithms (Algorithm 2 and 3) that return a $\left(1 - \frac{1}{e} - O(\varepsilon)\right)$ -approximation for Problem 2.6 with only Poly $\left(n, \frac{1}{\varepsilon}\right)$ queries to the noisy oracle $\tilde{f}$ . The analyses (Theorem 4.1 and 4.6) of the algorithms constitute a proof of Theorem 1.1.
+
+# 4.1 Algorithmic results for cardinality constraints when $r \in \Omega\left(\frac{1}{\varepsilon}\right) \cap O\left(n^{\frac{1}{3}}\right)$
+
+We first present an algorithm (Algorithm 2) and its analysis (Theorem 4.1) that are applicable for all $r \in \Omega\left(\frac{1}{\varepsilon}\right) \cap O\left(n^{\frac{1}{3}}\right)$ when $n$ is sufficiently large. All missing proofs can be found in Section D.
+
+Theorem 4.1 (Algorithmic results for cardinality constraints when $r \in \Omega\left(\frac{1}{\varepsilon}\right) \cap O\left(n^{\frac{1}{3}}\right)$ . Let $\varepsilon > 0$ and assume $n \in \Omega\left(\exp\left(\left(\frac{1}{\varepsilon}\right)^{O(1)}\right)\right)$ is sufficiently large. For any $r \in \Omega\left(\frac{1}{\varepsilon}\right) \cap O\left(n^{\frac{1}{3}}\right)$ , there exists an algorithm that returns a $(1 - \frac{1}{e} - O(\varepsilon))$ -approximation for Problem 2.6 under a $r$ -cardinality constraint, with probability at least $1 - O\left(\frac{1}{\log n}\right)$ and query complexity at most $O\left(r^{2} \log^{2} r \cdot n^{\frac{3}{2}} \varepsilon^{-1} \max\{r, \log n\}\right)$ to $\tilde{f}$ .
+
+The assumption that $n$ is sufficiently large is necessary and has also been adopted in prior works on noisy submodular optimization [11, 20]. We achieve a tight approximation ratio of $1 - 1 / e - O(\varepsilon)$ . Furthermore, we only require Poly $(n, 1 / \varepsilon)$ queries to $\tilde{f}$ , in contrast to $\Omega \left(n^{1 / \varepsilon}\right)$ for the prior greedy algorithm [20].
+
+# 4.1.1 Useful notations and useful facts for Theorem 4.1
+
+Our algorithm and analysis are based on the following smoothing surrogate function $h$ .
+
+Definition 4.2 (Smoothing surrogate function I). For any set $S \subseteq N$ , we define the smoothing surrogate function $h(S)$ as the expectation of $f(S + e)$ over a random element $e \in N$ , i.e., $h(S) = \frac{1}{n} \sum_{e \in N} f(S + e)$ .
+
+The surrogate function $h(S)$ is robust to noise when $|S|$ is relatively small since at this time $h(S)$ is based on a rather large averaging set with size nearly $n$ . Note that $h(S)$ becomes too concentrated on $f(S)$ as $|S| \approx n$ , and hence, we consider this surrogate $h$ for the range $r \in O\left(n^{\frac{1}{3}}\right)$ . We now show that $h$ shares some basic properties with $f$ .
+
+Lemma 4.3 (Properties of $h$ ). The smoothing surrogate function $h$ is monotone and submodular.
+
+Note that $h$ is implicitly constructed since we only have a value oracle to $\tilde{f}$ instead of $f$ . Hence, we construct an approximation of its auxiliary function $\varphi_h$ ; summarized by the following lemma.
+
+Lemma 4.4 (Approximation of $\varphi_h$ ). Let $\alpha, \delta \in (0,1/2)$ and assume $n \in \Omega(\alpha^{-2}\log(\delta^{-1}))$ . There exists a value oracle $\mathcal{O}$ to an $(\alpha, \delta, \mathcal{I}(r-1))$ -approximation $\widehat{\varphi_h}$ of $\varphi_h$ , which answering $\mathcal{O}(A)$ queries at most $M = \Theta\left(\log r \cdot n^{\frac{1}{2}}\max\{r,\log n\}\right)$ times to $\tilde{f}$ for each set $A \in \mathcal{I}(r-1)$ .
+
+The above lemma indicates that for a sufficiently large $n$ , we can achieve an arbitrary accurate approximation $\widehat{\varphi_h}$ of $\varphi_h$ , which queries $\tilde{f}$ only $\tilde{O}(rn^{\frac{1}{2}})$ times for each $\widehat{\varphi_h}(A)$ .
+
+More precisely, the relationship among $\alpha$ , $\delta$ and $n$ can be expressed as $\alpha^{-2}\ln (4\delta^{-1})\leq c\cdot n\kappa^{-2}$ (See Lemma D.5), where $\kappa$ is the sub-exponential norm (Definition D.2) of the noise distribution $\mathcal{D}$ depending on the parameters $c_{i},\gamma_{i}$ of density function, and $c$ is an absolute constant. A small $\kappa$ indicates a concentrated noise distribution. Generally speaking, the more concentrated the noise is $(\kappa \rightarrow 0)$ , the more accurate approximation we are able to obtain $(\alpha ,\delta \rightarrow 0)$ .
+
+# 4.1.2 Algorithm for Theorem 4.1
+
+Algorithm 2: Noisy local search under a small cardinality constraint
+Input: a value oracle to $\tilde{f}$ , budget $r \in \Omega\left(\frac{1}{\varepsilon}\right) \cap O\left(n^{\frac{1}{3}}\right)$ and $\varepsilon \in (0, 1/2)$
+1 Let $\widehat{\varphi_h}$ be a $\left(\alpha = \frac{\varepsilon}{4r \ln r}, \delta = \frac{1}{(I + 1)(r - 1)n^2}, \mathcal{I}(r - 1)\right)$ -approximation of $\varphi_h$ as in Lemma 4.4
+2 $S_L \gets \text{NLS}(\widehat{\varphi_h}, \mathcal{I}(r - 1), \Delta = \frac{\varepsilon}{4r \ln r})$ ▷ Local search phase
+3 $S_M \gets S_L + \arg \max_{e \in N \setminus S_L} \tilde{f}(S_L + e)$ ▷ $\tilde{f}$ -maximization phase
+4 return $S_M$
+
+We present Algorithm 2 that contains two phases: a local search phase (Line 2) and a $\tilde{f}$ -maximization phase (Line 3). We first run a non-oblivious local search procedure (Algorithm 1) under the $(r - 1)$ -cardinality constraint (Line 2). We set $\delta = \frac{1}{(I + 1)(r - 1)n^2}$ by Corollary 3.4 when applying Algorithm 1 to obtain a $(1 - \frac{1}{e} - \varepsilon)$ -approximation solution $S_L$ for $h$ -maximization. At the $\tilde{f}$ -maximization phase (Line 3), we obtain $S_M$ by selecting an additional element $e \in N \setminus S_L$ that maximizes $\tilde{f}(S_L + e)$ . This guarantees that $f(S_M) \geq (1 - \varepsilon)h(S_L)$ with high probability (Lemma 4.5), which results in the approximation ratio $1 - \frac{1}{e} - O(\varepsilon)$ in Theorem 4.1.
+
+Given the smoothing surrogate function $h(S)$ (Definition 4.2), a natural idea is to simply apply local search (Algorithm 1) to optimize it under the $r$ -cardinality constraint. However, this idea does not yield a provable approximation of $\max_{S:|S|\leq r}f(S)$ , since it is not easy to control the contribution of the additional element $e\in N$ to $h(S)$ and it is possible that $h(S)\gg f(S)$ . To handle this difficulty, Algorithm 2 first runs a local search procedure under the $(r - 1)$ -cardinality constraint, and then selects an additional element with a "large enough" margin at the $\tilde{f}$ -maximization phase. This idea enables us to control the loss induced by the surrogate $h$ within $\frac{1}{r}\cdot \max_{S:|S|\leq r}f(S)$ .
+
+# 4.1.3 Proof sketch of Theorem 4.1
+
+We first analyze the query complexity and then prove the approximation performance.
+
+Query complexity of Algorithm 2. In Line 3, we make $(n - r + 1)$ calls to the noisy oracle $\tilde{f}$ in total. By Corollary 3.4, the total number of queries to $\widehat{\varphi_h}$ in Line 2 is at most $(I + 1)(r - 1)n$ and $I \leq \frac{5r\ln r}{\varepsilon}$ . Combining with Lemma 4.4, the query complexity to $\tilde{f}$ is upper bounded by $(n - r + 1) + M(I + 1)(r - 1)n = O\left(r^2\log^2 r \cdot n^{\frac{3}{2}}\varepsilon^{-1}\max \{r,\log n\}\right)$ . This matches Theorem 4.1.
+
+Approximation ratio and success probability of Algorithm 2. Let $O_h \in \arg \max_{S \in \mathcal{I}(r-1)} h(S)$ represent the $(r-1)$ -set whose value of $h$ is the largest. Following from Theorem 3.3, we have $h(S_L) \geq \left(1 - \frac{1}{e} - \varepsilon\right) h(O_h)$ with probability at least $1 - \frac{1}{n}$ . We denote by $O_f \in \arg \max_{S \in \mathcal{I}(r)} f(S)$ the optimal solution to $f$ . By the submodularity of $f$ , $O_f$ has a subset $\tilde{O}_f$ with $r-1$ elements such that $f(\tilde{O}_f) \geq \left(1 - \frac{1}{r}\right) f(O_f)$ . Then we have
+
+$$
+h \left(S _ {L}\right) \geq \left(1 - \frac {1}{e} - \varepsilon\right) h \left(\tilde {O} _ {f}\right) \geq \left(1 - \frac {1}{e} - \varepsilon\right) f \left(\tilde {O} _ {f}\right) \geq \left(1 - \frac {1}{r}\right) \left(1 - \frac {1}{e} - \varepsilon\right) f \left(O _ {f}\right), \tag {1}
+$$
+
+where the first inequality follows from $h(S_L) \geq \left(1 - \frac{1}{e} - \varepsilon\right) h(O_h)$ and the second from monotonicity of $f$ . Since $r$ is assumed to be $\Omega\left(\frac{1}{\varepsilon}\right)$ , $h(S_L)$ is a $\left(1 - \frac{1}{e} - O(\varepsilon)\right)$ -approximation of $f(O_f)$ .
+
+Recall that $h(S_L)$ is the expectation of $f(S_L + e)$ over a random element $e \in N$ . Ineq. (1) already proves a claim that uniformly randomly adding an element $e \in N$ to $S_L$ achieves an approximation ratio of $1 - \frac{1}{e} - O(\varepsilon)$ in expectation for maximizing $f$ , i.e., $\mathbb{E}[f(S_L + e)] \geq \left(1 - \frac{1}{e} - O(\varepsilon)\right)f(O_f)$ . Moreover, we can convert this claim to a with-high-probability claim by the following lemma.
+
+Lemma 4.5 (Approximation at the $\tilde{f}$ -maximization phase). With probability $1 - O\left(\frac{1}{\log n}\right)$ , we have $f(S_M) \geq (1 - \varepsilon)h(S_L)$ .
+
+This lemma indicates that a bad element $e \in N \setminus S_L$ with $f(S_L + e) < (1 - \varepsilon)h(S_L)$ is unlikely to be chosen at the $\tilde{f}$ -maximization phase. This is because the local search procedure guarantees that the number of good elements with $f(S_L + e) \geq (1 - \varepsilon)h(S_L)$ is almost of the same order as the bad ones. Consequently, we can show that the selected element is likely to be good due to the generalized exponential tail noise, using similar proof idea as that of [20, Lemma 3.4]. By Ineq. (1) and Lemma 4.5, we complete the proof.
+
+# 4.2 Algorithmic results for cardinality constraints when $r \in \Omega \left( n^{\frac{1}{3}} \right)$
+
+We present in this subsection an algorithm (Algorithm 3) and its analysis (Theorem 4.6) that can be applied to $r \in \Omega \left(n^{\frac{1}{3}}\right)$ when $n$ is sufficiently large. All missing proofs can be found in Section E.
+
+Theorem 4.6 (Algorithmic results for cardinality constraints when $r \in \Omega \left(n^{\frac{1}{3}}\right)$ . Let $\varepsilon > 0$ and assume $n \in \Omega \left(\frac{1}{\varepsilon^4}\right)$ is sufficiently large. For any $r \in \Omega \left(n^{\frac{1}{3}}\right)$ , there exists an algorithm that returns a $\left(1 - \frac{1}{e} - O(\varepsilon)\right)$ -approximation for Problem 2.6 under a $r$ -cardinality constraint, with probability $1 - O\left(\frac{1}{n^2}\right)$ and query complexity at most $O(n^{6}\varepsilon^{-1})$ to $\tilde{f}$ .
+
+The above theorem addresses the remaining range of $r$ in Theorem 4.1, and also achieves a tight approximation ratio of $1 - \frac{1}{e} - O(\varepsilon)$ with $\mathrm{Poly}(n, 1 / \varepsilon)$ queries to $\tilde{f}$ .
+
+# 4.2.1 Useful notations and useful facts for Theorem 4.6
+
+Our algorithm and analysis in this subsection are based on another smoothing surrogate function $h$ .
+
+Definition 4.7 (Smoothing surrogate function II). Given a subset $H \subseteq N$ , for any set $S \subseteq N \setminus H$ we define the smoothing surrogate function $h_{H}(S)$ as $h_{H}(S) = \sum_{H_{j} \subseteq H} f(S \cup H_{j}) / 2^{|H|}$ .
+
+Intuitively, if $|H|$ is sufficiently large, the surrogate function $h$ is robust to noise as it is based on a large averaging set with size $2^{|H|}$ . Throughout the rest of this subsection, we consider the case that $|H| \in \Omega (\log n)$ . Similar to Section 4.1.1, we give some basic properties of $h_{H}$ .
+
+Lemma 4.8 (Properties of $h_H$ ). For any $H \subseteq N$ , the smoothing surrogate function $h_H$ is monotone and submodular, and for all $S \subseteq N \setminus H$ , $h_H(S) \geq \frac{1}{2} f(S \cup H) + \frac{1}{2} f(S)$ .
+
+Given a cardinality $r$ and a set $H \subseteq N$ , we define a $(r - |H|)$ -cardinality constraint confined on $N \setminus H$ as $\mathcal{I}_H(r) = \{S \subseteq N \setminus H : |S| = r - |H|\}$ . Similar to Section 4.1.1, we provide the following lemma indicating that the auxiliary function $\varphi_{h_H}$ can be well approximated.
+
+Lemma 4.9 (Approximation of $\varphi_{h_H}$ ). Let $\varepsilon > 0$ and assume $n \in \Omega$ ( $\varepsilon^{-4}$ ). For a set $H$ with $|H| \geq 3\ln n$ , there exists a value oracle $\mathcal{O}$ to $a$ ( $\alpha = \frac{\varepsilon}{4r\ln r}$ , $\delta = \frac{3}{n^6}, \mathcal{I}_H(r)$ )-approximation $\widehat{\varphi_{h_H}}$ of $\varphi_{h_H}$ which answering $\mathcal{O}(A)$ queries $\tilde{f}$ 's oracle $O\left(r\varepsilon^{-1}\log^{\frac{5}{2}}n\log^2 r\right)$ times for each set $A \in \mathcal{I}_H(r)$ .
+
+The above lemma indicates that for sufficiently large $n$ and $|H|$ , we can achieve an almost accurate approximation $\widehat{\varphi_{h_H}}$ of $\varphi_{h_H}$ , which queries $\tilde{f}$ only $\tilde{O}(n\varepsilon^{-1})$ times for each $\widehat{\varphi_{h_H}}(A)$ . By Corollay 3.4, we set $\delta = \frac{3}{n^6}$ when applying Algorithm 1.
+
+# 4.2.2 Algorithm for Theorem 4.6
+
+We present Algorithm 3 that mainly contains a local search phase (Line 3). The main difference from Algorithm 2 is that Algorithm 3 arbitrarily selects a redundant set $H$ (Line 1), and use this set to construct a smoothing surrogate function $h_{H}$ for local search (Line 3). Then Algorithm 3 returns $S_{L} \cup H$ directly (Line 4) without a $\tilde{f}$ -maximization phase.
+
+Algorithm 3: Noisy local search under large cardinality constraint
+Input: a value oracle to $\tilde{f}$ , budget $r \in \Omega\left(n^{\frac{1}{3}}\right)$ , and $\varepsilon \in (0, 1/2)$
+1 Arbitrarily select a subset $H \subseteq N$ with $|H| = \lceil 3\ln n \rceil$
+2 Let $\widehat{\varphi_{h_H}}$ be a $(\alpha = \frac{\varepsilon}{4r\ln r}, \delta = \frac{3}{n^6}, \mathcal{I}_H(r))$ -approximation of $\varphi_{h_H}$ as in Lemma 4.9
+3 $S_L \gets \mathrm{NLS}(\widehat{\varphi_{h_H}}, \mathcal{I}_H(r), \Delta = \frac{\varepsilon}{4r\ln r})$ ▷ Local search phase
+4 return $S_L \cup H$
+
+# 4.2.3 Proof sketch of Theorem 4.6
+
+Again, we first analyze the query complexity and then prove the approximation performance.
+
+Query complexity of Algorithm 3. Since $n \in \Omega\left(\frac{1}{\varepsilon^4}\right)$ , we have $I \in O(n^{2})$ in Corollary 3.4. Hence Line 4 calls the oracle of $\widehat{\varphi_{h_H}}$ at most $O(rn^3)$ times by Corollary 3.4, and each call to $\widehat{\varphi_{h_H}}$ queries $\tilde{f}$ at most $O\left(r\varepsilon^{-1}\log^{\frac{5}{2}}n\log^{2}r\right)$ times by Lemma 4.9. Thus we query $\tilde{f}$ at most $O(n^{6}\varepsilon^{-1})$ times.
+
+Approximation ratio and success probability of Algorithm 3. Corollary 3.4, we have $h_H(S_L) \geq \left(1 - \frac{1}{e} - \varepsilon\right) \cdot \max_{S \subseteq \mathcal{I}_H(r)} h_H(S)$ with probability $1 - O\left(\frac{1}{n^2}\right)$ . Furthermore, $f(S_L \cup H) \geq h_H(S_L)$ follows from the monotonicity of $f$ . Then we can demonstrate the approximation performance of Algorithm 3 by the following lemma.
+
+Lemma 4.10. Let $O^{\star} = \arg \max_{S \in \mathcal{I}(r)} f(S)$ . We have $\max_{S \in \mathcal{I}_H(r)} h_H(S) \geq \left(1 - \frac{|H|}{r}\right)f(O^{\star})$ .
+
+Roughly speaking, there exists a subset $A \subseteq O^{\star}$ of size $|H|$ such that $f(O^{\star} \backslash A) \geq \left(1 - \frac{|H|}{r}\right)f(O^{\star})$ by submodularity of $f$ . The claim follows from $\max_{S_L \in \mathcal{I}_H(r)} h_H(S) \geq h(O^{\star} \backslash A) \geq f(O^{\star} \backslash A)$ . Combining the fact that $f(S_L \cup H) \geq \left(1 - \frac{1}{e} - \varepsilon\right) \max_{S \subseteq \mathcal{I}_H(r)} h_H(S)$ with Lemma 4.10, we complete the proof of Theorem 4.6.
+
+# 5 Our algorithms and main theorems for general matroid constraints
+
+In this section, we consider Problem 2.6 under matroid constraints. Similarly, for different ranges of matroid ranks, we prove there are $(1 - \frac{1}{e} - O(\varepsilon)) / 2$ -approximate algorithms (Theorems 5.1 and 5.2). W.l.o.g., we assume that all single elements are feasible for the given matroid constraints.
+
+Theorem 5.1 (Algorithmic results for matroid constraints with rank $r \in \Omega \left( \frac{1}{\varepsilon} \log \left( \frac{1}{\varepsilon} \right) \right) \cap O \left( n^{\frac{1}{3}} \right)$ ). Let $\varepsilon > 0$ is sufficiently small and assume $n \in \Omega \left( \exp \left( \left( \frac{1}{\varepsilon} \right)^{O(1)} \right) \right)$ is sufficiently large. For any $r \in \Omega (\varepsilon^{-1} \log (\varepsilon^{-1})) \cap O\left(n^{\frac{1}{3}}\right)$ , there exists an algorithm that returns a $\left( \left( 1 - \frac{1}{e} \right) / 2 - O(\varepsilon) \right)$ -approximation for Problem 2.6 under a matroid constraint $\mathcal{I}(\mathcal{M})$ with rank $r$ , with probability at least $1 - O(\varepsilon^4)$ and query complexity at most $O\left(r^{2} \log^{2} r \cdot n^{\frac{3}{2}} \varepsilon^{-1} \max \{r, \log n\}\right)$ to $\tilde{f}$ .
+
+The proof can be found in Section F. The main difference from Theorem 4.1 is that the approximation ratio is $\left(1 - \frac{1}{e}\right) / 2 - O(\varepsilon)$ instead of $1 - \frac{1}{e} - O(\varepsilon)$ . The reason is that to maintain the feasibility of the output, we may not be able to add an element to $S_{L}$ as in Line 3 of Algorithm 2. To address this issue, we design a comparison procedure (Lines 4-8 of Algorithm 7) to evaluate the value of $f(S_{L})$ and $f(S_{M} \setminus S_{L})$ and output the larger one, which results in a loss on the approximation ratio. Moreover, the failure probability of the comparison procedure is upper bounded by $O(\varepsilon^{4})$ .
+
+Theorem 5.2 (Algorithmic results for matroid constraints with rank $r \in \Omega \left(n^{\frac{1}{3}}\right)$ . Let $\varepsilon > 0$ and assume $n \in \Omega \left(\frac{1}{\varepsilon^4}\right)$ is sufficiently large. For $r \in \Omega \left(n^{\frac{1}{3}}\right)$ , there exists an algorithm returning a $\left(\left(1 - \frac{1}{e}\right) / 2 - O(\varepsilon)\right)$ -approximation for Problem 2.6 under a matroid constraint $\mathcal{I}(\mathcal{M})$ with rank $r$ , with probability $1 - O\left(\frac{1}{n^2}\right)$ and query complexity $O(n^{6}\varepsilon^{-1})$ to $\tilde{f}$ . Specifically, for a strongly base-orderable matroid (Definition H.1), the approximation ratio can be improved to $1 - \frac{1}{e} - O(\varepsilon)$ .
+
+The proof for general matroid constraints can be found in Section G. The main difference from Theorem 4.6 is again the approximation ratio. For maintaining the feasibility, we divide an arbitrary base into two equal-size subsets, apply Algorithm 3 to both subsets, and output the larger one. Consequently, we achieve a $\left(\left(1 - \frac{1}{\varepsilon}\right) / 2 - O(\varepsilon)\right)$ -approximation ratio. Specifically, for a strongly base-orderable matroid, we can use its good exchangeable property to maintain the feasibility without sacrificing the approximation ratio; see Section H for a complete proof.
+
+# 6 Discussions
+
+For any cardinality $r \geq 2$ , Algorithms 2 and 3 return a $\left(\left(1 - \frac{1}{r}\right)\left(1 - \frac{1}{e}\right) - O(\varepsilon)\right)$ -approximation for monotone submodular maximization problem under noise with query complexity Poly $\left(n, \frac{1}{\varepsilon}\right)$ . When $r \in \Omega\left(\frac{1}{\varepsilon}\right)$ , the approximation ratio can be written as $\left(1 - \frac{1}{e}\right) - O(\varepsilon)$ (Theorem 1.1). However, if $r \in O\left(\frac{1}{\varepsilon}\right)$ , then this ratio is not close to the optimal one. In this case, Singer and Hassidim [20] provide an algorithm that achieves $\left(1 - \frac{1}{r}\right)$ -approximation with query complexity $\Omega(n^r)$ . It remains open whether there is an algorithm that returns $\left(1 - \frac{1}{e} - O(\varepsilon)\right)$ -approximation with query complexity Poly $\left(n, \frac{1}{\varepsilon}\right)$ for $r \in O\left(\frac{1}{\varepsilon}\right)$ . The main challenges of our approach to handle this range of $r$ is that the introduction of surrogates (Definition 4.2) inevitably results in a loss of $\frac{1}{r}$ in approximation ratio. For the special case of $r = 1$ , one of the few known results is an algorithm by [20] achieving a $\frac{1}{2}$ -approximation guarantee in expectation, which is information theoretically tight. To the best of our knowledge, there is no with-high-probability result for this case.
+
+Another limitation of this work is that we only consider independent noise. For non-i.i.d. noise, Hassidim and Singer [11] indicate that no algorithm can achieve a constant approximation when the noise multipliers are arbitrarily correlated across sets. Considering this, it may be worthwhile to consider special cases of correlated distributions for which optimal guarantees can be obtained. One of them is a model called $d$ -correlated noise [11]: a noise distribution is $d$ -correlated if for any two sets $S$ and $T$ such that $|S \setminus T| + |T \setminus S| > d$ , the noise is applied independently to $S$ and to $T$ . The noise multipliers can be arbitrarily correlated when $S$ and $T$ are similar in the sense that $|S \setminus T| + |T \setminus S| \leq d$ . We notice that our algorithms can be naturally extended to $d$ -correlated noise for $d \in O(1)$ . In particular, to adapt Algorithm 2 to deal with $d$ -correlated noise, we need to arbitrarily split $N$ into sets $T_1, \ldots, T_{\lfloor \frac{N}{d+1} \rfloor}$ and define the smoothing surrogate function as $h(S) = \frac{1}{L} \sum_{l=1}^{L} f(S \cup T_l)$ to replace the original surrogate.
+
+# 7 Conclusions
+
+In this work, we study the problem of constrained monotone submodular maximization with noisy oracles. We design a unified local search framework that allows for inaccuracy in the objective function. Under this framework, we construct several smoothing surrogate functions to average the noise out. For cardinality constraints, the local search framework results in algorithms that achieve a $\left(1 - \frac{1}{e} - O(\varepsilon)\right)$ -approximation with Poly $(n, \frac{1}{\varepsilon})$ query complexity. Moreover, for general matroid constraints, the framework obtains an approximation ratio arbitrarily close to $\left(1 - \frac{1}{e}\right) / 2$ , which is the first constant approximation result to our knowledge.
+
+There are many directions in which this work could be extended. For submodular maximization with noisy oracles under general matroid constraints, there is a gap between the approximation ratio of $(1 - 1 / e) / 2 - O(\varepsilon)$ provided in this paper and impossibility results [5, 20]. The first open question is to close this gap. In addition, it would be interesting to consider more complex constraints under noise including knapsack constraints [4]. It is meaningful to investigate submodular maximization with correlated noise. Moreover, it is also worthwhile to investigate the robustness of other submodular optimization approaches, e.g., multi-linear extension [25].
+
+# Acknowledgements
+
+We are grateful to Dr. Bei Xiaohui for his good counsel and valuable comments on the manuscript.
+
+# References
+
+[1] Niv Buchbinder and Moran Feldman. Submodular functions maximization problems. In Handbook of Approximation Algorithms and Metaheuristics, page 771-806. Chapman and Hall/CRC, 2018.
+[2] Gruia Calinescu, Chandra Chekuri, Martin Pal, and Jan Vondrak. Maximizing a monotone submodular function subject to a matroid constraint. SIAM Journal on Computing, 40(6): 1740-1766, 2011.
+[3] Christopher P Chambers and Federico Echenique. Revealed Preference Theory. Cambridge University Press, 2016.
+[4] Chandra Chekuri, Jan Vondrák, and Rico Zenklusen. Submodular function maximization via the multilinear relaxation and contention resolution schemes. SIAM Journal on Computing, 43 (6):1831-1879, 2014.
+[5] Uriel Feige. A threshold of $\ln n$ for approximating set cover. Journal of the ACM (JACM), 45 (4):634-652, 1998.
+[6] Vitaly Feldman. On the power of membership queries in agnostic learning. The Journal of Machine Learning Research, 10:163-182, 2009.
+[7] Yuval Filmus and Justin Ward. Monotone submodular maximization over a matroid via non-oblivious local search. SIAM Journal on Computing, 43(2):514-542, 2014.
+[8] Marshall L Fisher, George L Nemhauser, and Laurence A Wolsey. An analysis of approximations for maximizing submodular set functions—II. In *Polyhedral combinatorics*, pages 73–87. Springer, 1978.
+[9] Amir Globerson and Sam Roweis. Nightmare at test time: robust learning by feature deletion. In Proceedings of the 23rd international conference on Machine learning, pages 353-360, 2006.
+[10] Curtis Greene. A multiple exchange property for bases. Proceedings of the American Mathematical Society, 39(1):45-50, 1973.
+[11] Avinatan Hassidim and Yaron Singer. Submodular optimization under noise. In Conference on Learning Theory, pages 1069-1122. PMLR, 2017.
+[12] Thibaut Horel and Yaron Singer. Maximization of approximately submodular functions. Advances in neural information processing systems, 29, 2016.
+[13] Shinji Ito. Submodular function minimization with noisy evaluation oracle. Advances in Neural Information Processing Systems, 32, 2019.
+[14] David Kempe, Jon Kleinberg, and Éva Tardos. Maximizing the spread of influence through a social network. In Proceedings of the ninth ACM SIGKDD international conference on Knowledge discovery and data mining, pages 137-146, 2003.
+[15] Andreas Krause, Jure Leskovec, Carlos Guestrin, Jeanne VanBriesen, and Christos Faloutsos. Efficient sensor placement optimization for securing large water distribution networks. Journal of Water Resources Planning and Management, 134(6):516-526, 2008.
+[16] Andreas Krause, Ram Rajagopal, Anupam Gupta, and Carlos Guestrin. Simultaneous placement and scheduling of sensors. In 2009 International Conference on Information Processing in Sensor Networks, pages 181-192. IEEE, 2009.
+[17] Jon Lee, Maxim Sviridenko, and Jan Vondrak. Submodular maximization over multiple matroids via generalized exchange properties. Mathematics of Operations Research, 35(4):795-806, 2010.
+[18] George L Nemhauser, Laurence A Wolsey, and Marshall L Fisher. An analysis of approximations for maximizing submodular set functions—I. Mathematical programming, 14(1):265-294, 1978.
+
+[19] James G Oxley. Matroid theory, volume 3. Oxford University Press, USA, 2006.
+[20] Yaron Singer and Avinatan Hassidim. Optimization for approximate submodularity. Advances in Neural Information Processing Systems, 31, 2018.
+[21] Adish Singla, Sebastian Tschiatschek, and Andreas Krause. Noisy submodular maximization via adaptive sampling with applications to crowdsourced image collection summarization. In Thirtieth AAAI Conference on Artificial Intelligence, 2016.
+[22] Maxim Sviridenko. A note on maximizing a submodular set function subject to a knapsack constraint. Operations Research Letters, 32(1):41-43, 2004.
+[23] Marisa Thoma, Hong Cheng, Arthur Gretton, Jiawei Han, Hans-Peter Kriegel, Alex Smola, Le Song, Philip S Yu, Xifeng Yan, and Karsten Borgwardt. Near-optimal supervised feature selection among frequent subgraphs. In Proceedings of the 2009 SIAM International Conference on Data Mining, pages 1076-1087. SIAM, 2009.
+[24] Roman Vershynin. High-dimensional probability: An introduction with applications in data science. Cambridge University Press, 2018.
+[25] Jan Vondrák. Optimal approximation for the submodular welfare problem in the value oracle model. In Proceedings of the fortieth annual ACM symposium on Theory of computing, pages 67-74, 2008.
+[26] Jan Vondrák, Chandra Chekuri, and Rico Zenklusen. Submodular function maximization via the multilinear relaxation and contention resolution schemes. In Proceedings of the forty-third annual ACM symposium on Theory of computing, pages 783-792, 2011.
+[27] Dominic JA Welsh. Matroid theory. Courier Corporation, 2010.
+[28] Robin J Wilson. An introduction to matroid theory. The American Mathematical Monthly, 80 (5):500-525, 1973.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See Section 7.
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes] All missing proofs can be found in the appendix.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [N/A]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [N/A]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [N/A]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [N/A]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [N/A]
+(c) Did you include any new assets either in the supplemental material or as a URL? [No]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficientsubmodularoptimizationundernoiselocalsearchisrobust/images.zip b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..463a50676d16c1ec3a856f3602e82461a8ea6fb4
--- /dev/null
+++ b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7c1d843ad6ba1e890d3932efb09e7c7ad4f4086bc932253a991ee9ae50b68e66
+size 17628
diff --git a/efficientsubmodularoptimizationundernoiselocalsearchisrobust/layout.json b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..5fcc0e1070db44faa7c9a6fedf2623e89e7b1078
--- /dev/null
+++ b/efficientsubmodularoptimizationundernoiselocalsearchisrobust/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:80a2d202884e7dcec41c4c6fa578b06dc00db8ef5d6bbad52505d59d66e53cdc
+size 758674
diff --git a/efficienttrainingoflowcurvatureneuralnetworks/6dd5df7d-438a-46e5-874e-1d2916acd592_content_list.json b/efficienttrainingoflowcurvatureneuralnetworks/6dd5df7d-438a-46e5-874e-1d2916acd592_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..d0ea12315fb25f7302419702145e77ecb85ef7b8
--- /dev/null
+++ b/efficienttrainingoflowcurvatureneuralnetworks/6dd5df7d-438a-46e5-874e-1d2916acd592_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8d3b999447c14c9c2d53494c95a17821da3341036dc58a0f62b0c7be3fc14cf1
+size 82037
diff --git a/efficienttrainingoflowcurvatureneuralnetworks/6dd5df7d-438a-46e5-874e-1d2916acd592_model.json b/efficienttrainingoflowcurvatureneuralnetworks/6dd5df7d-438a-46e5-874e-1d2916acd592_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..90733eafe91fa2dbbe10a9279a34b4011f475ca7
--- /dev/null
+++ b/efficienttrainingoflowcurvatureneuralnetworks/6dd5df7d-438a-46e5-874e-1d2916acd592_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:70ab1e8863608590f898809f2704a0281036c07221c91413227d19a5b13ffd59
+size 102269
diff --git a/efficienttrainingoflowcurvatureneuralnetworks/6dd5df7d-438a-46e5-874e-1d2916acd592_origin.pdf b/efficienttrainingoflowcurvatureneuralnetworks/6dd5df7d-438a-46e5-874e-1d2916acd592_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..91bf0bc3e41d1d14279e8d47185f2a5bbab29989
--- /dev/null
+++ b/efficienttrainingoflowcurvatureneuralnetworks/6dd5df7d-438a-46e5-874e-1d2916acd592_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2aad3b68c8640f22bc1b477d08fab1ce90712c1ecce02bccc7c95f4f57a39da1
+size 417950
diff --git a/efficienttrainingoflowcurvatureneuralnetworks/full.md b/efficienttrainingoflowcurvatureneuralnetworks/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..bbe5a94cf98df44ee335d8105a24f51b1dd19ca2
--- /dev/null
+++ b/efficienttrainingoflowcurvatureneuralnetworks/full.md
@@ -0,0 +1,333 @@
+# Efficient Training of Low-Curvature Neural Networks
+
+Suraj Srinivas\*1
+Harvard University
+ssrinivas@seas.harvard.edu
+
+Himabindu Lakkaraju
+Harvard University
+hlakkaraju@hbs.edu
+
+Kyle Matoba*
+Idiap Research Institute & EPFL
+kyle.matoba@epfl.ch
+
+François Fleuret
+University of Geneva
+francois.fleuret@unige.ch
+
+# Abstract
+
+Standard deep neural networks often have excess non-linearity, making them susceptible to issues such as low adversarial robustness and gradient instability. Common methods to address these downstream issues, such as adversarial training, are expensive and often sacrifice predictive accuracy.
+
+In this work, we address the core issue of excess non-linearity via curvature, and demonstrate low-curvature neural networks (LCNNs) that obtain drastically lower curvature than standard models while exhibiting similar predictive performance. This leads to improved robustness and stable gradients, at a fraction of the cost of standard adversarial training. To achieve this, we decompose overall model curvature in terms of curvatures and slopes of its constituent layers. To enable efficient curvature minimization of constituent layers, we introduce two novel architectural components: first, a non-linearity called centered-softplus that is a stable variant of the softplus non-linearity, and second, a Lipschitz-constrained batch normalization layer.
+
+Our experiments show that LCNNs have lower curvature, more stable gradients and increased off-the-shelf adversarial robustness when compared to standard neural networks, all without affecting predictive performance. Our approach is easy to use and can be readily incorporated into existing neural network architectures.
+
+Code to implement our method and replicate our experiments is available at https://github.com/kylematoba/lconn.
+
+# 1 Introduction
+
+The high degree of flexibility present in deep neural networks is critical to achieving good performance in complex tasks such as image classification, language modelling and generative modelling of images [1-3]. However, excessive flexibility is undesirable as this can lead to model underspecification [4] which results in unpredictable behaviour on out-of-domain inputs, such as vulnerability to adversarial examples. Such under-specification can be avoided in principle via Occam's razor, which requires training models that are as simple as possible for the task at hand, and not any more. Motivated by this principle, in this work we focus on training neural network models without excess non-linearity in their input-output map (e.g.: see Fig 1b), such that predictive performance remains unaffected.
+
+
+(a) Decision boundary with standard NN $(\beta = 1000)$
+
+
+(b) Decision boundary with LCNN $(\beta = 1)$
+
+
+(c) Softplus vs Centered-Softplus
+Figure 1: Decision boundaries of (a) standard NN and (b) LCNN trained on the two moons dataset. LCNN recovers highly regular decision boundaries in contrast to the standard NN. (c) Comparison of softplus and centered-softplus non-linearities (defined in §3.3). These behave similarly for large $\beta$ values, and converge to linear maps for low $\beta$ values. However, softplus diverges while centered-softplus stays close to the origin.
+
+Central to this work is a precise notion of curvature, which is a mathematical quantity that encodes the flexibility or the degree of non-linearity of a function at a point. In deep learning, the curvature of a function at a point is often quantified as the norm of the Hessian at that point [5-7]. Hessian norms are zero everywhere if and only if the function is linear, making them suitable to measure the degree of non-linearity. However, they suffer from a dependence on the scaling of model gradients, which makes them unsuitable to study its interplay with model robustness. In particular, robust models have small gradient norms [8], which naturally imply smaller Hessian norms. But are they truly more linear as a result? To be able to study robustness independent of non-linearity, we propose normalized curvature, which normalizes the Hessian norm by its corresponding gradient norm, thus disentangling the two measures. Surprisingly, we find that normalized curvature is a stable measure across train and test samples (see Table 3), whereas the usual curvature is not.
+
+A conceptually straightforward approach to train models with low-curvature input-output maps [6, 9] involves directly penalizing curvature locally at training samples. However, these methods involve expensive Hessian computations, and only minimize local point-wise curvature and not curvature everywhere. A complementary approach is that of Dombrowski et al. [10], who propose architectures that have small global curvature, but do not explicitly penalize this curvature during training. In contrast, we propose efficient mechanisms to explicitly penalize the normalized curvature globally. In addition, while previous methods [6, 7] penalize the Frobenius norm of the Hessian, we penalize its spectral norm, thus providing tighter and more interpretable robustness bounds. $^{1}$
+
+Our overall contributions in this paper are:
+
+1. In §3.1 we propose to measure curvature of deep models via normalized curvature, which is invariant to scaling of the model gradients.
+2. In §3.2 we show that normalized curvature of neural networks can be upper bounded in terms of normalized curvatures and slopes of individual layers.
+3. We introduce an architecture for training LCNNs combining a novel activation function called the centered-softplus (§3.3), and recent innovations to constrain the Lipschitz constant of convolutional (§3.4.1) and batch normalization (§3.4.2) layers.
+4. In §4 we prove bounds on the relative gradient robustness and adversarial robustness of models in terms of normalized curvature, showing that controlling normalized curvature directly controls these properties.
+5. In §5, we show experiments demonstrating that our proposed innovations are successful in training low-curvature models without sacrificing training accuracy, and that such models have robust gradients, and are more robust to adversarial examples out-of-the-box.
+
+# 2 Related Work
+
+Adversarial Robustness of Neural Networks: The well-known phenomenon of adversarial vulnerabilities of neural networks [11, 12] shows that adding small amounts of imperceptible noise can cause deep neural networks to misclassify points with high confidence. The canonical method to defend against this vulnerability is adversarial training [13] which trains models to accurately classify adversarial examples generated via an attack such as projected gradient descent (PGD). However, this approach is computationally expensive and provides no formal guarantees on robustness. Cohen et al. [14] proposed randomized smoothing, which provides a formal guarantee on robustness by generating a smooth classifier from any black-box classifier. Hein and Andriushchenko [8] identified the local Lipschitz constant as critical quantity to prove formal robustness guarantees. Moosavi Dezfooli et al. [6] penalize the Frobenius norm of the Hessian, and show that they perform similarly to models trained via adversarial training. Qin et al. [9] introduce a local linearity regularizer, which also implicitly penalizes the Hessian. Similar to these works, we enforce low curvature to induce robustness, but we focus on out of the box robustness of LCNNs.
+
+Unreliable Gradient Interpretations in Neural Networks: Gradient explanations in neural networks can be unreliable. Ghorbani et al. [15], Zhang et al. [16] showed that for any input, it is possible to find adversarial inputs such that the gradient explanations for these points that are highly dissimilar to each other. Srinivas and Fleuret [17] showed that pre-softmax logit gradients however are independent of model behaviour, and as a result we focus on post-softmax loss gradients in this work. Ros and Doshi-Velez [18] showed empirically that robustness can be improved by gradient regularization, however Dombrowski et al. [10] showed that gradient instability is primarily due to large Hessian norms. This suggests that the gradient penalization in Ros and Doshi-Velez [18] performed unintentional Hessian regularization, which is consistent with our experimental results. To alleviate this, Dombrowski et al. [7] proposed to train low curvature models via softplus activations and weight decay, broadly similar to our strategy. However, while Dombrowski et al. [7] focused on the Frobenius norm of the Hessian, we penalize the normalized curvature - a scaled version of the Hessian spectral norm - which is strictly smaller than the Frobenius norm, and this results in a more sophisticated penalization strategy.
+
+Lipschitz Layers in Neural Networks There has been extensive work on methods to bound the Lipschitz constant of neural networks. Cisse et al. [19] introduced Parseval networks, which penalizes the deviation of linear layers from orthonormality - since an orthonormal linear operator evidently has a Lipschitz constant of one, this shrinks the Lipschitz constant of a layer towards one. Trockman and Kolter [20] use a reparameterization of the weight matrix, called the Cayley Transform, that is orthogonal by construction. Miyato et al. [21], Ryu et al. [22] proposed spectral normalization, where linear layers are re-parameterized by dividing by their spectral norm, ensuring that the overall spectral norm of the parameterized layer is one.
+
+# 3 Training Low-Curvature Neural Networks
+
+In this section, we introduce our approach for training low-curvature neural nets (LCNNs). Unless otherwise specified, we shall consider a neural network classifier $f$ that maps inputs $\mathbf{x} \in \mathbb{R}^d$ to logits which characterize the prediction, and can be further combined with the true label distribution and a loss function to give a scalar loss value $f(\mathbf{x}) \in \mathbb{R}^{+}$ .
+
+# 3.1 Measuring Relative Model Non-Linearity via Normalized Curvature
+
+We begin our analysis by discussing a desirable definition of curvature $\mathcal{C}_f(\mathbf{x})\in \mathbb{R}^+$ . While curvature is well-studied topic in differential geometry [23] where Hessian normalization is a common theme, our discussion will be largely independent of this literature, in a manner more suited to requirements in deep learning. Regardless of the definition, a typical property of a curvature measure is that $\mathcal{C}_f(\mathbf{x}) = 0\forall \mathbf{x}\in \mathbb{R}^d\iff f$ is linear, and the higher the curvature, the further from linear the function is. Hence $\max_{\mathbf{x}\in \mathbb{R}^d}\mathcal{C}_f(\mathbf{x})$ can be thought of as a measure of a model's non-linearity. A common way to define curvature in machine learning [5-7] has been via Hessian norms. However, these measures are sensitive to gradient scaling, which is undesirable. After all, the degree of model non-linearity must intuitively be independent of how large its gradients are.
+
+For example, if two functions $f, g$ are scaled ( $f = k \times g$ ), or rotated versions of each other ( $\nabla f = k \times \nabla g$ ), then we would like them to have similar curvatures in the interest of disentangling curvature (i.e., degree of non-linearity) from scaling. It is easy to see that Hessian norms $\| \nabla_{\mathbf{x}}^2 f(\mathbf{x}) \|_2$ do not have this property, as scaling the function also scales the corresponding Hessian. We would like to be able to recover low-curvature models with steep gradients (that are non-robust), precisely to be able to disentangle their properties from low-curvature models with small gradients (that are robust), which Hessian norms do not allow us to do.
+
+To avoid this problem, we propose a definition of curvature that is approximately normalized: $\mathcal{C}_f(\mathbf{x}) = \| \nabla^2 f(\mathbf{x})\| _2 / (\| \nabla f(\mathbf{x})\| _2 + \varepsilon)$ . Here $\| \nabla f(\mathbf{x})\| _2$ and $\| \nabla^2 f(\mathbf{x})\| _2$ are the $\ell_2$ norm of the gradient and the spectral norm of the Hessian, respectively, where $\nabla f(\mathbf{x})\in \mathbb{R}^d$ , $\nabla^2 f(\mathbf{x})\in \mathbb{R}^{d\times d}$ and $\varepsilon >0$ is a small constant to ensure well-behavedness of the measure. This definition measures Hessian norm relative to the gradient norm, and captures a notion of relative local linearity, which can be seen via an application of Taylor's theorem:
+
+$$
+\underbrace {\left\| f (\mathbf {x} + \epsilon) - f (\mathbf {x}) - \nabla f (\mathbf {x}) ^ {\top} \epsilon \right\| _ {2}} _ {\text {r e l a t i v e l o c a l l i n e a r i t y}} \leq \frac {1}{2} \underbrace {\max _ {\mathbf {x} \in \mathbb {R} ^ {d}} \mathcal {C} _ {f} (\mathbf {x})} _ {\text {n o r m a l i z e d c u r v a t u r e}} \| \epsilon \| _ {2}. \tag {1}
+$$
+
+Here the numerator on the left captures the local linearity error, scaled by the gradient norm in the denominator, which can be shown using Taylor's theorem to be upper bounded by the normalized curvature. We shall consider penalizing this notion of normalized curvature, and we shall simply refer to this quantity as curvature in the rest of the paper.
+
+# 3.2 A Data-Free Upper Bound on Curvature
+
+Directly penalizing the curvature is computationally expensive as it requires backpropagating an estimate of the Hessian norm, which itself requires backpropagating gradient-vector products. This requires chaining the entire computational graph of the model at least three times. Moosavi Dezfooli et al. [6] reduce the complexity of this operation by computing a finite-difference approximation to the Hessian from gradients, but even this double-backpropagation is expensive. We require an efficient penalization procedure takes a single backpropagation step.
+
+To this end, we propose to minimize a data-free upper bound on the curvature. To illustrate the idea, we first show this upper bound for the simplified case of the composition of one-dimensional functions $(f:\mathbb{R}\to \mathbb{R})$ .
+
+Lemma 1. Given a 1-dimensional compositional function $f = f_{L} \circ f_{L-1} \circ \ldots \circ f_{1}$ with $f_{i} : \mathbb{R} \to \mathbb{R}$ for $i = 1,2,\ldots,L$ , the normalized curvature $\mathcal{C}_f := |f''/f'|$ , is bounded by $\left| \frac{f''}{f'} \right| \leq \sum_{i=1}^{L} \left| \frac{f_i''}{f_i'} \right| \prod_{j=1}^{i} |f_j'|$ .
+
+Proof. We first have $f' = \prod_{i=1}^{L} f_i'$ . Differentiating this expression we have $f'' = \sum_{i=1}^{L} f_i'' \prod_{j=1}^{i} f_j' \prod_{k=1,k \neq i}^{L} f_k'$ . Dividing by $f'$ , taking absolute value of both sides, and using the triangle inequality, we have the intended result.
+
+Extending the above expression to functions $\mathbb{R}^n\to \mathbb{R}$ is not straightforward, as the intermediate layer Hessians are order three tensors. We derive this using a result from Wang et al. [24] that connects the spectral norms of order- $n$ tensors to the spectral norm of their matrix "unfoldings". The full derivation is presented in the appendix, and the (simplified) result is stated below.
+
+Theorem 1. Given a function $f = f_{L} \circ f_{L-1} \circ \ldots \circ f_{1}$ with $f_{i}: \mathbb{R}^{n_{i-1}} \to \mathbb{R}^{n_{i}}$ , the curvature $\mathcal{C}_{f}$ can be bounded by the sum of curvatures of individual layers $\mathcal{C}_{f_{i}}(\mathbf{x})$ , i.e.,
+
+$$
+\mathcal {C} _ {f} (\mathbf {x}) \leq \sum_ {i = 1} ^ {L} n _ {i} \times \mathcal {C} _ {f _ {i}} (\mathbf {x}) \prod_ {j = 1} ^ {i} \| \nabla_ {f _ {j - 1}} f _ {j} (\mathbf {x}) \| _ {2} \leq \sum_ {i = 1} ^ {L} n _ {i} \times \max _ {\mathbf {x} ^ {\prime}} \mathcal {C} _ {f _ {i}} \left(\mathbf {x} ^ {\prime}\right) \prod_ {j = 1} ^ {i} \max _ {\mathbf {x} ^ {\prime}} \| \nabla_ {f _ {j - 1}} f _ {j} \left(\mathbf {x} ^ {\prime}\right) \| _ {2}. \tag {2}
+$$
+
+The rightmost term is independent of $\mathbf{x}$ and thus holds uniformly across all data points. This bound shows that controlling the curvature and Lipschitz constant of each layer of a neural network enables us to control the overall curvature of the model.
+
+Practical neural networks typically consist of linear maps such as convolutions, fully connected layers, and batch normalization layers, and non-linear activation functions. Linear maps have zero curvature by definition, and non-linear layers often have bounded gradients $(= 1)$ , which simplifies computations. In the sections that follow, we shall see how to penalize the remaining terms, i.e., the curvature of the non-linear activations, and the Lipschitz constant of the linear layers.
+
+# 3.3 Centered-Softplus: Activation Function with Trainable Curvature
+
+Theorem 1 shows that the curvature of a neural network depends on the curvature of its constituent activation functions. We thus propose to use activation functions with minimal curvature.
+
+The kink at the origin of the ReLU function implies an undefined second derivative. On the other hand, a smooth activation such as the softplus function, $s(x;\beta) = \log (1 + \exp (\beta x)) / \beta$ is better suited to analyzing questions of curvature. Despite not being a common baseline choice, softplus does see regular use, especially where its smoothness facilitates analysis [25]. The curvature of the softplus function is
+
+$$
+\mathcal {C} _ {s (\cdot ; \beta)} (x) = \beta \times \left(1 - \frac {\mathrm {d} s (x ; \beta)}{\mathrm {d} x}\right) \leq \beta \tag {3}
+$$
+
+Thus using softplus with small $\beta$ values ensures low curvature. However, we observe two critical drawbacks of softplus preventing its usage with small $\beta$ : (1) divergence for small $\beta$ , where $s(x; \beta \to 0) = \infty$ which ensures that well-behaved low curvature maps cannot be recovered and, (2) instability upon composition i.e., $s^n (x = 0; \beta) = \underbrace{s \circ s \circ \ldots \circ s}_{n \text{ times}} (x = 0; \beta) = \frac{\log(n + 1)}{\beta}$ . Thus
+
+we have that $s^n (x = 0;\beta)\to \infty$ as $n\to \infty$ , which shows that composing softplus functions exacerbates instability around the origin. This is critical for deep models with large number of layers $n$ , which is precisely the scenario of interest to us. To remedy this problem, we propose centered-softplus $s_0(x;\beta)$ , a simple modification to softplus by introducing a normalizing term as follows.
+
+$$
+s _ {0} (x; \beta) = s (x; \beta) - \frac {\log 2}{\beta} = \frac {1}{\beta} \log \left(\frac {1 + \exp (\beta x)}{2}\right). \tag {4}
+$$
+
+This ensures that $s(x = 0; \beta) = s^n (x = 0; \beta) = 0$ for any positive integer $n$ , and hence also ensures stability upon composition. More importantly, we have $s_0(x; \beta \to 0) = x / 2$ which is a scaled linear map, while still retaining $s_0(x; \beta \to \infty) = \operatorname{ReLU}(x)$ . This ensures that we are able to learn both well-behaved linear maps, as well as highly non-linear ReLU-like maps if required.
+
+We further propose to cast $\beta$ is a learnable parameter and penalize its value, hence directly penalizing the curvature of that layer. Having accounted for the curvature of the non-linearities, the next section discusses controlling the gradients of the linear layers.
+
+# 3.4 Lipschitz Linear Layers
+
+Theorem 1 shows that penalizing the Lipschitz constants of the constituent linear layers in a model is necessary to penalize overall model curvature. There are broadly three classes of linear layers we consider: convolutions, fully connected layers, and batch normalization.
+
+# 3.4.1 Spectrally Normalized Convolutions and Fully Connected Layers
+
+We propose to penalize the Lipschitz constant of convolutions and fully connected layer via existing spectral normalization-like techniques. For fully connected layers, we use vanilla spectral normalization (Miyato et al. [21]) which controls the spectral norm of a fully connected layer by reparameterization - replacing a weight matrix $W$ , by $W / ||W||_2$ which has a unit spectral norm. Ryu et al. [22] generalize this to convolutions by presenting a power iteration method that works directly on the linear mapping implicit in a convolution: maintaining 3D left and right singular "vectors" of the 4D tensor of convolutional filters and developing the corresponding update rules.
+
+They call this "real" spectral normalization to distinguish it from the approximation that [21] proposed for convolutions. Using spectral normalization on fully connected layers and "real" spectral normalization on convolutional layers ensures that the spectral norm of these layers is exactly equal to one, further simplifying the bound in Theorem 1.
+
+# 3.4.2 $\gamma$ -Lipschitz Batch Normalization
+
+In principle, at inference time batch normalization (BN) is multiplication by the diagonal matrix of inverse running standard deviation estimates. Thus we can spectrally normalize the BN layer by computing the reciprocal of the smallest running standard deviation value across dimensions $i$ , i.e., $||\mathrm{BN}||_2 = \max_x||\mathrm{BN}(x)||_2 = 1 / \min_i$ running-standard(i). In practice, we found that models with such spectrally normalized BN layers tended to either diverge or fail to train in the first place, indicating that the scale introduced by BN is necessary for training. To remedy this, we introduce the $\gamma$ -Lipschitz batch normalization, defined by
+
+$$
+\begin{array}{l} 1 \text {- L i p s c h i t z - B N} (\mathbf {x}) \leftarrow \mathrm {B N} (\mathbf {x}) / | | \mathrm {B N} | | _ {2} \\ \gamma \text {- L i p s c h i t z - B N} (\mathbf {x}) \leftarrow \underbrace {\min (\gamma , | | \mathrm {B N} | | _ {2})} _ {\text {s c a l i n g f a c t o r} \leq \gamma} \times 1 \text {- L i p s c h i t z - B N} (\mathbf {x}). \\ \end{array}
+$$
+
+By clipping the scaling above at $\gamma$ (equivalently, the running standard deviation below, at $1 / \gamma$ ), we can ensure that the Lipschitz constant of a batch normalization layer is at most equal to $\gamma \in \mathbb{R}^{+}$ . We provide a PyTorch-style code snippet in the appendix. As with $\beta$ , described in §3.3, we cast $\gamma$ as a learnable parameter in order to penalize it during training. Gouk et al. [26] proposed a similar (simpler) solution, whereas they fit a common $\gamma$ to all BN layers, we let $\gamma$ vary freely by layer.
+
+# 3.5 Penalizing Curvature
+
+We have discussed three architectural innovations - centered-softplus activations with a trainable $\beta$ , spectrally normalized linear and convolution layers and a $\gamma$ -Lipschitz batch normalization layer. We now discuss methods to penalize the overall curvature of a model built with these layers.
+
+Since convolutional and fully connected layers have spectral norms equal to one by construction, they contribute nothing to curvature. Thus, we restrict attention to batch normalization and activation layers. The set of which will be subsequently referred to respectively $\beta \mathrm{SP}$ and $\gamma \mathrm{BN}$ . For models with batch normalization, naively using the upper bound in Theorem 1 is problematic due to the exponential growth in the product of Lipschitz constants of batch normalization layers. To alleviate this, we propose to use a penalization $\mathcal{R}_f$ where $\gamma_{i}$ terms are aggregated additively across batch normalization layers, and independent of the $\beta_{i}$ terms in the following manner:
+
+$$
+\mathcal {R} _ {f} = \lambda_ {\beta} \times \sum_ {i \in \beta \mathrm {S P}} \beta_ {i} + \lambda_ {\gamma} \times \sum_ {j \in \gamma \mathrm {B N}} \log \gamma_ {j} \tag {5}
+$$
+
+An additive aggregation ensures that the penalization is well-behaved during training and does not grow exponentially. Note that the underlying model is necessarily linear if the penalization term is zero, thus making it an appropriate measure of model non-linearity. Also note that $\beta_{i} \geq 0, \gamma_{i} \geq 1$ by construction. We shall henceforth use the term "LCNN" to refer to a model trained with the proposed architectural components (centered-softplus, spectral normalization, and $\gamma$ -Lipschitz batch normalization) and associated regularization terms on $\beta, \gamma$ . We next discuss the robustness and interpretability benefits that we obtain with LCNNs.
+
+# 4 Why Train Low-Curvature Models?
+
+In this section we discuss the advantages that low-curvature models offer, particularly as it pertains to robustness and gradient stability. These statements apply not just to LCNNs, but low-curvature models in general obtained via any other mechanism.
+
+# 4.1 Low Curvature Models have Stable Gradients
+
+Recent work [15, 16] has shown that gradient explanations are manipulable, and that we can easily find inputs whose explanations differ maximally from those at the original inputs, making them unreliable in practice for identifying important features. As we shall show, this amounts to models having a large curvature. In particular, we show that the relative gradient difference across points $\| \epsilon \| _2$ away in the $\ell_2$ sense is upper bounded by the normalized curvature $C_f$ , as given below.
+
+Proposition 1. Consider a model $f$ with $\max_{\mathbf{x}}\mathcal{C}_f(\mathbf{x})\leq \delta_{\mathcal{C}}$ , and two inputs $\mathbf{x}$ and $\mathbf{x} + \epsilon$ ( $\in \mathbb{R}^d$ ). The relative distance between gradients at these points is bounded by
+
+$$
+\frac {\| \nabla f (\mathbf {x} + \epsilon) - \nabla f (\mathbf {x}) \| _ {2}}{\| \nabla f (\mathbf {x}) \| _ {2}} \leq \| \epsilon \| _ {2} \delta_ {\mathcal {C}} \exp (\| \epsilon \| _ {2} \delta_ {\mathcal {C}}) \sim \| \epsilon \| _ {2} \mathcal {C} _ {f} (\mathbf {x}) \quad (Q u a d r a t i c A p p r o x i m a t i o n)
+$$
+
+The proof expands $f(\mathbf{x})$ in a Taylor expansion around $\mathbf{x} + \epsilon$ and bounds the magnitude of the second and higher order terms over the neighborhood of $\mathbf{x}$ , and the full argument is given in the appendix. The upper bound is considerably simpler when we assume that the function locally quadratic, which corresponds to the rightmost term $\| \epsilon \|_2 \mathcal{C}_f(\mathbf{x})$ . Thus the smaller the model curvature, the more locally stable are the gradients.
+
+# 4.2 Low Curvature is Necessary for $\ell_2$ Robustness
+
+Having a small gradient norm is known to be an important aspect of adversarial robustness [8]. However, small gradients alone are not sufficient, and low curvature is necessary, to achieve robustness. This is easy to see intuitively - a model may have low gradients at a point leading to robustness for small noise values, but if the curvature is large, then gradient norms at neighboring points can quickly increase, leading to misclassification for even slightly larger noise levels. This effect is an instance of gradient-masking [27], which provides an illusion of robustness by making models only locally robust.
+
+In the result below, we formalize this intuition and establish an upper bound on the distance between two nearby points, which we show depends on both the gradient norm (as was known previously) and well as the max curvature of the underlying model.
+
+Proposition 2. Consider a model $f$ with $\max_{\mathbf{x}}\mathcal{C}_f(\mathbf{x})\leq \delta_{\mathcal{C}}$ , then for two inputs $\mathbf{x}$ and $\mathbf{x} + \epsilon (\in \mathbb{R}^d)$ , we have the following expression for robustness
+
+$$
+\begin{array}{l} \| f (\mathbf {x} + \epsilon) - f (\mathbf {x}) \| _ {2} \leq \| \epsilon \| _ {2} \| \nabla f (\mathbf {x}) \| _ {2} \left(1 + \| \epsilon \| _ {2} \delta_ {\mathcal {C}} \exp \left(\| \epsilon \| _ {2} \delta_ {\mathcal {C}}\right)\right) \\ \sim \| \epsilon \| _ {2} \| \nabla f (\mathbf {x}) \| _ {2} (1 + \| \epsilon \| _ {2} \mathcal {C} _ {f} (\mathbf {x})) \quad (Q u a d r a t i c A p p r o x i m a t i o n) \\ \end{array}
+$$
+
+The proof uses similar techniques to those of proposition 1, and is also given in the appendix. This result shows that given two models with equally small gradients at data points, the greater robustness will be achieved by the model with the smaller curvature.
+
+# 5 Experiments
+
+In this section we perform experiments to (1) evaluate the effectiveness of our proposed method in training models with low curvature as originally intended, (2) evaluate whether low curvature models have robust gradients in practice, and (3) evaluate the effectiveness of low-curvature models for adversarial robustness. Our experiments are primarily conducted on a base ResNet-18 architecture ([28]) using the CIFAR10 and CIFAR100 datasets ([29]), and using the Pytorch [30] framework. Our methods entailed fairly modest computation – our most involved computations can be completed in under three GPU days, and all experimental results could be computed in less than 60 GPU-days. We used a mixture of GPUs – primarily NVIDIA GeForce GTX 1080 Tis – on an internal compute cluster.
+
+Baselines and Our Methods Our baseline model for comparison involves using a ResNet-18 model with softplus activation with a high $\beta = 10^{3}$ to mimic ReLU, and yet have well-defined curvatures.
+
+Another baseline is gradient norm regularization (which we henceforth call 'GradReg') [31], where the same baseline model is trained with an additional penalty on the gradient norm. We train two variants of our approach - a base LCNN, which involves penalizing the curvature, and another variant combining LCNN penalty and gradient norm regularization (LCNN + GradReg), which controls both the curvature and gradient norm. Our theory indicates that the LCNN + GradReg variant is likely to produce more robust models, which we verify experimentally. We also compare with CURE [6], softplus with weight decay [7] and adversarial training with $\ell_2$ PGD [13] with noise magnitude of 0.1 and 3 iterations of PGD. We provide experimental details in the appendix.
+
+Parameter Settings All our models are trained for 200 epochs with an SGD + momentum optimizer, with a momentum of 0.9 and an initial learning rate of 0.1 which decays by a factor of 10 at 150 and 175 epochs, and a weight decay of $5 \times 10^{-4}$ .
+
+# 5.1 Evaluating the Efficacy of Curvature Penalization
+
+In this section, we evaluate whether LCNNs indeed reduce model curvature in practice. Table 1 contains our results, from which we make the following observations: (1) most of our baselines except CURE and adversarial training do not meaningfully lose predictive performance (2) GradReg and adversarially trained models are best at reducing gradient norm while LCNN-based models are best at penalizing curvature. Overall, these experimental results show that LCNN-based models indeed minimize curvature as intended.
+
+We also observe in Table 1 that GradReg [31] has an unexpected regularizing effect on the Hessian and curvature. We conjecture that this is partly due to the following decomposition of the loss Hessian, which can be written as $\nabla^2 f(\mathbf{x})\sim \nabla f_l(\mathbf{x})\nabla_{f_l}^2\mathrm{LSE}(\mathbf{x})\nabla f_l(\mathbf{x})^\top +\nabla_{f_l}\mathrm{LSE}(\mathbf{x})\nabla^2 f_l(\mathbf{x})$ where $\mathrm{LSE}(\mathbf{x})$ is the LogSumExp function, and $f_{l}(\mathbf{x})$ is the pre-softmax logit output. We observe that the first term strongly depends on the gradients, which may explain the Hessian regularization effects of GradReg, while the second term depends on the Hessian of the bulk of the neural network, which is penalized by the LCNN penalties. This also explains why combining both penalizations (LCNN + GradReg) further reduces curvature.
+
+We also measure the average per-epoch training times on a GTX 1080Ti, which are: standard models / softplus + weight decay ( $\sim$ 100 sec), LCNN ( $\sim$ 160 sec), GradReg ( $\sim$ 270 sec), LCNN+GradReg ( $\sim$ 350 sec), CURE / Adversarial Training ( $\sim$ 500 sec). Note that the increase in computation for LCNN is primarily due to the use of spectral normalization layers. The results show that LCNNs are indeed able to penalize curvature by only marginally ( $1.6\times$ ) increasing training time, and using LCNN+GradReg only increases time $1.3\times$ over GradReg while providing curvature benefits.
+
+Table 1: Model geometry of various ResNet-18 models trained with various regularizers on the CIFAR100 test dataset. Gradient norm regularized models [31] ('GradReg') are best at reducing gradient norms, while LCNN-based models are best at reducing curvature, leaving gradients unpenalized. We obtain the benefits of both by combining these penalties. Results are averaged across two runs.
+
+| Model | Ex||∇f(x)||2 | Ex||∇2f(x)||2 | ExCf(x) | Accuracy (%) |
| Standard | 19.66 ± 0.33 | 6061.96 ± 968.05 | 270.89 ± 75.04 | 77.42 ± 0.11 |
| LCNNs | 22.04 ± 1.41 | 1143.62 ± 99.38 | 69.50 ± 2.41 | 77.30 ± 0.11 |
| GradReg [31] | 8.86 ± 0.12 | 776.56 ± 63.62 | 89.47 ± 5.86 | 77.20 ± 0.26 |
| LCNNs + GradReg | 9.87 ± 0.27 | 154.36 ± 0.22 | 25.30 ± 0.09 | 77.29 ± 0.07 |
| CURE [6] | 8.86 ± 0.01 | 979.45 ± 14.05 | 116.31 ± 4.58 | 76.48 ± 0.07 |
| Softplus + Wt. Decay [7] | 18.08 ± 0.05 | 1052.84 ± 7.27 | 70.39 ± 0.88 | 77.44 ± 0.28 |
| Adversarial Training [32] | 7.99 ± 0.03 | 501.43 ± 18.64 | 63.79 ± 1.65 | 76.96 ± 0.26 |
+
+# 5.2 Impact of Curvature on Gradient Robustness
+
+In §4.1, we showed that low-curvature models tend to have more robust gradients. Here we evaluate whether this prediction empirically by measuring the relative gradient robustness for the models with various ranges of curvature values and noise levels. In particular, we measure robustness to random noise at fixed magnitudes ranging logarithmically from $1 \times 10^{-3}$ to $1 \times 10^{-1}$ . We plot our results
+
+
+(a) Gradient Robustness on CIFAR10
+
+
+(b) Gradient Robustness on CIFAR100
+Figure 2: Plot showing relative gradient robustness $\frac{\|\nabla f(\mathbf{x} + \epsilon) - \nabla f(\mathbf{x})\|_2}{\|\nabla f(\mathbf{x})\|_2}$ as a function of added noise $\|\epsilon\|_2$ on (a) CIFAR10 and (b) CIFAR100 with a ResNet-18 model. We observe that low-curvature models lead to an order of magnitude improvement in gradient robustness, and this improvement closely follows the trend predicted by the theoretical upper bound in §4.
+
+in Figure 2 where we find that our results match theory (i.e, the simplified quadratic approximation in §4.1) quite closely in terms of the overall trends, and that low curvature models have an order of magnitude improvement in robustness over standard models.
+
+# 5.3 Impact of Curvature on Adversarial Robustness
+
+Our theory in §4.2 shows that having low curvature is necessary for robustness, along with having small gradient norms. In this section we evaluate this claim empirically, by evaluating adversarial examples via $\ell_2$ PGD [13] adversaries with various noise magnitudes. We use the Cleverhans library [33] to implement PGD. Our results are present in Table 2 where we find that $\mathrm{LCNN} + \mathrm{GradReg}$ models perform on par with adversarial training, without a resulting accuracy loss.
+
+Table 2: Results indicating off-the-shelf model accuracies (\%) upon using $\ell_2$ PGD adversarial examples across various noise magnitudes. Adversarial training performs the best overall, however sacrifices clean accuracy. LCNN+GradReg models perform similarly but without significant loss of clean accuracy. Results are averaged across two runs.
+
+| Model | Acc. (%) | ||ε||2=0.05 | ||ε||2=0.1 | ||ε||2=0.15 | ||ε||2=0.2 |
| Standard | 77.42 ± .10 | 59.97 ± .11 | 37.55 ± .13 | 23.41 ± .08 | 16.11 ± .21 |
| LCNN | 77.16 ± .07 | 61.17 ± .53 | 39.72 ± .17 | 25.60 ± .32 | 17.66 ± .18 |
| GradReg | 77.20 ± .26 | 71.90 ± .11 | 61.06 ± .03 | 49.19 ± .12 | 38.09 ± .47 |
| LCNNs + GradReg | 77.29 ± .26 | 72.68 ± .52 | 63.36 ± .39 | 52.96 ± .76 | 42.70 ± .77 |
| CURE [6] | 76.48 ± .07 | 71.39 ± .12 | 61.28 ± .32 | 49.60 ± .09 | 39.04 ± .16 |
| Softplus + Wt. Decay [7] | 77.44 ± .28 | 60.86 ± .36 | 38.04 ± .43 | 23.85 ± .33 | 16.20 ± .01 |
| Adversarial Training [32] | 76.96 ± .26 | 72.76 ± .15 | 64.70 ± .20 | 54.80 ± .25 | 44.98 ± .57 |
+
+# 5.4 Train-Test Discrepancy in Model Geometry
+
+During our experiments, we observed a consistent phenomenon where the gradient norms and Hessian norms for test data points were much larger than those for the train data points, which hints at a form of overfitting with regards to these quantities. We term this phenomenon as the train-test discrepancy in model geometry. Interestingly, we did not observe any such discrepancy using our proposed curvature measure, indicating that our proposed measure may be a more reliable measure of model geometry. We report our results in Table 3, where we measure the relative discrepancy, finding that the discrepancy for our proposed measure of curvature is multiple orders of magnitude smaller than the corresponding quantity for gradient and Hessian norms. We leave further investi
+
+gation of this phenomenon – regarding why curvature is stable across train and test – as a topic for future work.
+
+Table 3: Train-test descrepancy in model geometry, where the relative descrepancy $\Delta_{tt}g(\mathcal{X}) = \left|\frac{g(\mathcal{X}_{\mathrm{test}}) - g(\mathcal{X}_{\mathrm{train}})}{g(\mathcal{X}_{\mathrm{test}})}\right|$ is shown for three different geometric measures. We observe that (1) there exists a large train-test descrepancy, with the test gradient / hessian norms being $>10\times$ the corresponding values for the train set. (2) the descrepancy is 2-3 orders of magnitude smaller for our proposed curvature measure, indicating that it may be a stable model property.
+
+| Model | ΔttEx∈X||∇f(x)||2 | ΔttEx∈X||∇2f(x)||2 | ΔttEx∈XCf(x) |
| Standard | 11.75 | 12.28 | 0.025 |
| GradReg | 11.33 | 11.22 | 0.017 |
| LCNN | 19.99 | 11.33 | 0.129 |
| LCNNs + GradReg | 21.82 | 10.43 | 0.146 |
+
+# Summary of Experimental Results Overall, our experiments show that:
+
+(1) LCNNs have lower curvature than standard models as advertised, and combining them with gradient norm regularization further decreases curvature (see Table 1). The latter phenomenon is unexpected, as our curvature measure ignores gradient scaling.
+(2) LCNNs combined with gradient norm regularization achieve an order of magnitude improved gradient robustness over standard models (see Figure 2).
+(3) LCNNs combined with gradient norm regularization outperform adversarial training in terms of achieving a better predictive accuracy at a lower curvature (see Table 1), and are competitive in terms of adversarial robustness (see Table 2), while being $\sim 1.4\times$ faster.
+(4) We observe that there exists a train-test discrepancy for standard geometric quantities like the gradient and Hessian norm, and this discrepancy disappears for our proposed curvature measure (see Table 3).
+
+We also present ablation experiments, additional adversarial attacks, and evaluations on more datasets and architectures in the Appendix.
+
+# 6 Discussion
+
+In this paper, we presented a modular approach to remove excess curvature in neural network models. Importantly, we found that combining vanilla LCNNs with gradient norm regularization resulted in models with the smallest curvature, the most stable gradients as well as those that are the most adversarially robust. Notably, this procedure achieves adversarial robustness without explicitly generating adversarial examples during training.
+
+The current limitations of our approach are that we only consider convolutional and fully connected layers, and not self-attention or recurrent layers. We also do not investigate the learning-theoretic benefits (or harms) of low-curvature models, or study their generalization for small number of training samples, or their robustness to label noise (which we already observe in Fig. 1b). Investigating these are important topics for future work.
+
+# Acknowledgments and Disclosure of Funding
+
+The authors would like to thank the anonymous reviewers for their helpful feedback and all the funding agencies listed below for supporting this work. SS and HL are supported in part by the NSF awards #IIS-2008461 and #IIS-2040989, and research awards from Google, JP Morgan, Amazon, Harvard Data Science Initiative, and $\mathrm{D}^3$ Institute at Harvard. KM and SS (partly) are supported by the Swiss National Science Foundation under grant number FNS-188758 "CORTTI". HL would like to thank Sujatha and Mohan Lakkaraju for their continued support and encouragement.
+
+# References
+
+[1] 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, pages 770-778, 2016.
+[2] Aakanksha Chowdhery, Sharan Narang, Jacob Devlin, Maarten Bosma, Gaurav Mishra, Adam Roberts, Paul Barham, Hyung Won Chung, Charles Sutton, Sebastian Gehrmann, et al. Palm: Scaling language modeling with pathways. arXiv preprint arXiv:2204.02311, 2022.
+[3] Aditya Ramesh, Prafulla Dhariwal, Alex Nichol, Casey Chu, and Mark Chen. Hierarchical text-conditional image generation with clip latents. arXiv preprint arXiv:2204.06125, 2022.
+[4] Alexander D'Amour, Katherine Heller, Dan Moldovan, Ben Adlam, Babak Alipanahi, Alex Beutel, Christina Chen, Jonathan Deaton, Jacob Eisenstein, Matthew D Hoffman, et al. Underspecification presents challenges for credibility in modern machine learning. arXiv preprint arXiv:2011.03395, 1(3), 2020.
+[5] Laurent Dinh, Razvan Pascanu, Samy Bengio, and Yoshua Bengio. Sharp minima can generalize for deep nets. In Doina Precup and Yee Whye Teh, editors, Proceedings of the 34th International Conference on Machine Learning, volume 70 of Proceedings of Machine Learning Research, pages 1019-1028. PMLR, 06-11 Aug 2017. URL https://proceedings.mlr.press/v70/dinh17b.html.
+[6] Seyed Mohsen Moosavi Dezfooli, Alhussein Fawzi, Jonathan Uesato, and Pascal Frossard. Robustness via curvature regularization, and vice versa. In 2019 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 9070-9078, Los Alamitos, CA, USA, jun 2019. IEEE Computer Society. URL https://doi.ieeecomputersociety.org/10.1109/CVPR.2019.00929.
+[7] Ann-Kathrin Dombrowski, Christopher J. Anders, Klaus-Robert Müller, and Pan Kessel. Towards robust explanations for deep neural networks. Pattern Recognition, 121:108194, 2022. ISSN 0031-3203. URL https://doi.org/10.1016/j.patcog.2021.108194.
+[8] Matthias Hein and Maksym Andriushchenko. Formal guarantees on the robustness of a classifier against adversarial manipulation. Advances in neural information processing systems, 30, 2017.
+[9] Chongli Qin, James Martens, Sven Gowal, Dilip Krishnan, Krishnamurthy Dvijotham, Alhussein Fawzi, Soham De, Robert Stanforth, and Pushmeet Kohli. Adversarial robustness through local linearization. Advances in Neural Information Processing Systems, 32, 2019.
+[10] Ann-Kathrin Dombrowski, Maximillian Alber, Christopher Anders, Marcel Ackermann, Klaus-Robert Müller, and Pan Kessel. Explanations can be manipulated and geometry is to blame. In H. Wallach, H. Larochelle, A. Beygelzimer, F. d'Alché-Buc, E. Fox, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 32. Curran Associates, Inc., 2019. URL https://proceedings.neurips.cc/paper/2019/file/bb836c01cdc9120a9c984c525e4b1a4a-Paper.pdf.
+[11] Christian Szegedy, Wojciech Zaremba, Ilya Sutskever, Joan Bruna, Dumitru Erhan, Ian Goodfellow, and Rob Fergus. Intriguing properties of neural networks. In International Conference on Learning Representations, 2014. URL http://arxiv.org/abs/1312.6199.
+[12] Ian J. Goodfellow, Jonathon Shlens, and Christian Szegedy. Explaining and Harnessing Adversarial Examples. arXiv e-prints, Dec 2014. URL http://arxiv.org/abs/1412.6572.
+[13] Aleksander Madry, Aleksandar Makelov, Ludwig Schmidt, Dimitris Tsipras, and Adrian Vladu. Towards deep learning models resistant to adversarial attacks. In International Conference on Learning Representations, 2018. URL https://openreview.net/forum?id=rJzIBfZAb.
+[14] Jeremy Cohen, Elan Rosenfeld, and Zico Kolter. Certified adversarial robustness via randomized smoothing. In International Conference on Machine Learning, pages 1310-1320. PMLR, 2019.
+
+[15] Amirata Ghorbani, Abubakar Abid, and James Zou. Interpretation of neural networks is fragile. Proceedings of the AAAI conference on artificial intelligence, 33(01):3681-3688, 2019. URL https://doi.org/10.1609/aaai.v33i01.33013681.
+[16] Xinyang Zhang, Ningfei Wang, Hua Shen, Shouling Ji, Xiapu Luo, and Ting Wang. Interpretable deep learning under fire. In 29th {USENIX} Security Symposium ( {USENIX} Security 20), 2020.
+[17] Suraj Srinivas and Francois Fleuret. Rethinking the role of gradient-based attribution methods for model interpretability. In International Conference on Learning Representations, 2020.
+[18] Andrew Slavin Ros and Finale Doshi-Velez. Improving the adversarial robustness and interpretability of deep neural networks by regularizing their input gradients. In Proceedings of the Thirty-Second AAAI Conference on Artificial Intelligence and Thirtieth Innovative Applications of Artificial Intelligence Conference and Eighth AAAI Symposium on Educational Advances in Artificial Intelligence, AAAI'18/IAAI'18/EAAI'18. AAAI Press, 2018. ISBN 978-1-57735-800-8.
+[19] Moustapha Cisse, Piotr Bojanowski, Edouard Grave, Yann Dauphin, and Nicolas Usunier. Parseval Networks: Improving Robustness to Adversarial Examples. arXiv e-prints, art. arXiv:1704.08847, April 2017.
+[20] Asher Trockman and J. Zico Kolter. Orthogonalizing convolutional layers with the Cayley transform. In International Conference on Learning Representations, 2021. URL https://openreview.net/forum?id=Pbj8H_jEHYv.
+[21] Takeru Miyato, Toshiki Kataoka, Masanori Koyama, and Yuichi Yoshida. Spectral Normalization for Generative Adversarial Networks. arXiv e-prints, Feb 2018. URL http://arxiv.org/abs/1802.05957.
+[22] Ernest Ryu, Jialin Liu, Sicheng Wang, Xiaohan Chen, Zhangyang Wang, and Wotao Yin. Plug-and-play methods provably converge with properly trained denoisers. In Kamalika Chaudhuri and Ruslan Salakhutdinov, editors, Proceedings of the 36th International Conference on Machine Learning, volume 97 of Proceedings of Machine Learning Research, pages 5546-5557. PMLR, 09-15 Jun 2019. URL https://proceedings.mlr.press/v97/ryu19a.html.
+[23] John M Lee. Riemannian Manifolds: An Introduction to Curvature, volume 176. Springer Science & Business Media, 2006.
+[24] Miaoyan Wang, Khanh Dao Duc, Jonathan Fischer, and Yun S. Song. Operator norm inequalities between tensor unfoldings on the partition lattice. Linear Algebra and its Applications, 520:44-66, 2017. ISSN 0024-3795. URL https://doi.org/10.1016/j.laa.2017.01.017.
+[25] Will Grathwohl, Ricky T. Q. Chen, Jesse Bettencourt, and David Duvenaud. Scalable reversible generative models with free-form continuous dynamics. In International Conference on Learning Representations, 2019. URL https://openreview.net/forum?id=rJxgknCcK7.
+[26] Henry Gouk, Eibe Frank, Bernhard Pfahringer, and Michael J Cree. Regularisation of neural networks by enforcing lipschitz continuity. Machine Learning, 110(2):393-416, 2021.
+[27] Anish Athalye, Nicholas Carlini, and David Wagner. Obfuscated gradients give a false sense of security: Circumventing defenses to adversarial examples. In International conference on machine learning, pages 274-283. PMLR, 2018.
+[28] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In 2016 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 770-778, 2016. URL https://doi.org/10.1109/CVPR.2016.90.
+[29] Alex Krizhevsky. Learning multiple layers of features from tiny images. Technical report, University of Toronto, 2009. URL https://www.cs.toronto.edu/~kriz/ learning-features-2009-TR.pdf.
+
+[30] Adam Paszke, Sam Gross, Soumith Chintala, Gregory Chanan, Edward Yang, Zachary DeVito, Zeming Lin, Alban Desmaison, Luca Antiga, and Adam Lerer. Automatic differentiation in pytorch. In NIPS 2017 Workshop Autodiff Program, 2017.
+[31] H. Drucker and Y. Le Cun. Improving generalization performance using double backpropagation. IEEE Transactions on Neural Networks, 3(6):991-997, 1992. doi: 10.1109/72.165600.
+[32] Aleksander Madry, Aleksandar Makelov, Ludwig Schmidt, Dimitris Tsipras, and Adrian Vladu. Towards Deep Learning Models Resistant to Adversarial Attacks. arXiv e-prints, June 2017. URL http://arxiv.org/abs/1706.06083.
+[33] Nicolas Papernot, Fartash Faghri, Nicholas Carlini, Ian Goodfellow, Reuben Feinman, Alexey Kurakin, Cihang Xie, Yash Sharma, Tom Brown, Aurko Roy, Alexander Matyasko, Vahid Behzadan, Karen Hambardzumyan, Zhishuai Zhang, Yi-Lin Juang, Zhi Li, Ryan Sheatsley, Abhibhav Garg, Jonathan Uesato, Willi Gierke, Yinpeng Dong, David Berthelot, Paul Hendricks, Jonas Rauber, and Rujun Long. Technical report on the CleverHans v2.1.0 adversarial examples library. arXiv preprint arXiv:1610.00768, 2018. URL https://arxiv.org/abs/1610.00768.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential negative societal impacts of your work? [N/A] We present foundational work on the geometry of neural network models and as such we do not foresee any negative societal impacts beyond those that already exist with the usage of neural network models.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes]
+(b) Did you include complete proofs of all theoretical results? [Yes] proofs are provided in the appendix
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes]
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] some training details are mentioned in the appendix
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [Yes]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+We did not use crowdsourcing or conducted research with human subjects.
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/efficienttrainingoflowcurvatureneuralnetworks/images.zip b/efficienttrainingoflowcurvatureneuralnetworks/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..681febaaa10cf6bb1de50300e0cb108d7287ed1b
--- /dev/null
+++ b/efficienttrainingoflowcurvatureneuralnetworks/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5e6ed22565ed54155cb54f82403155a56aed9eb18b8ea9201742c39e7fa81265
+size 352416
diff --git a/efficienttrainingoflowcurvatureneuralnetworks/layout.json b/efficienttrainingoflowcurvatureneuralnetworks/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..5edab7bb4362c1bf44e436447580fe6b8d9b2a9b
--- /dev/null
+++ b/efficienttrainingoflowcurvatureneuralnetworks/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:cfd0bec77013b996685f8d00bf2a06902ee3ae9d766a5c0d0252beba7743b3b8
+size 416863
diff --git a/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/e2d83d00-fdb2-40bd-ba34-1e69a4cf8ff0_content_list.json b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/e2d83d00-fdb2-40bd-ba34-1e69a4cf8ff0_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..ec84c52c58d5dba6635c24c8d9cc31cf5abdbe02
--- /dev/null
+++ b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/e2d83d00-fdb2-40bd-ba34-1e69a4cf8ff0_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:acae436766c00dae36055d82b5efd72e89626c7fc4f294bca911711235352301
+size 88975
diff --git a/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/e2d83d00-fdb2-40bd-ba34-1e69a4cf8ff0_model.json b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/e2d83d00-fdb2-40bd-ba34-1e69a4cf8ff0_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..f11fff2052bca40eedbd88d284cec9ac89dc6c3c
--- /dev/null
+++ b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/e2d83d00-fdb2-40bd-ba34-1e69a4cf8ff0_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:410526e1f521e19715b8c1c4e75cacb506cdafdb9003d673f1088dad958b5eef
+size 113426
diff --git a/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/e2d83d00-fdb2-40bd-ba34-1e69a4cf8ff0_origin.pdf b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/e2d83d00-fdb2-40bd-ba34-1e69a4cf8ff0_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..a0a3a0f52095944db04c1b652d9a8aa7c020661d
--- /dev/null
+++ b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/e2d83d00-fdb2-40bd-ba34-1e69a4cf8ff0_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e81117e0da008dd3bc041330f47a5280c19c1b2c1767ba94fcceb97424a3fe0c
+size 3877218
diff --git a/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/full.md b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..a5de546e4bcf505f86f3d3c1e017b1ed90d06e52
--- /dev/null
+++ b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/full.md
@@ -0,0 +1,385 @@
+# EGSDE: Unpaired Image-to-Image Translation via Energy-Guided Stochastic Differential Equations
+
+Min Zhao $^{1}$ , Fan Bao $^{1}$ , Chongxuan Li $^{2,3*}$ , Jun Zhu $^{1*}$
+
+$^{1}$ Dept. of Comp. Sci. & Tech., BNRist Center, THU-Bosch ML Center, Tsinghua University, China
+
+$^{2}$ Gaoling School of Artificial Intelligence, Renmin University of China, Beijing, China
+
+3 Beijing Key Laboratory of Big Data Management and Analysis Methods, Beijing, China
+
+$^{4}$ Pazhou Laboratory (Huangpu), Guangzhou, China
+
+gracezhao1997@gmail.com; bf19@mails.tsinghua.edu.cn;
+
+chongxuanli@ruc.edu.cn; dcszj@tsinghua.edu.cn
+
+# Abstract
+
+Score-based diffusion models (SBDMs) have achieved the SOTA FID results in unpaired image-to-image translation (I2I). However, we notice that existing methods totally ignore the training data in the source domain, leading to sub-optimal solutions for unpaired I2I. To this end, we propose energy-guided stochastic differential equations (EGSDE) that employs an energy function pretrained on both the source and target domains to guide the inference process of a pretrained SDE for realistic and faithful unpaired I2I. Building upon two feature extractors, we carefully design the energy function such that it encourages the transferred image to preserve the domain-independent features and discard domain-specific ones. Further, we provide an alternative explanation of the EGSDE as a product of experts, where each of the three experts (corresponding to the SDE and two feature extractors) solely contributes to faithfulness or realism. Empirically, we compare EGSDE to a large family of baselines on three widely-adopted unpaired I2I tasks under four metrics. EGSDE not only consistently outperforms existing SBDMs-based methods in almost all settings but also achieves the SOTA realism results without harming the faithful performance. Furthermore, EGSDE allows for flexible trade-offs between realism and faithfulness and we improve the realism results further (e.g., FID of 51.04 in Cat $\rightarrow$ Dog and FID of 50.43 in Wild $\rightarrow$ Dog on AFHQ) by tuning hyper-parameters. The code is available at https://github.com/ML-GSAI/EGSDE.
+
+# 1 Introduction
+
+Unpaired image-to-image translation (I2I) aims to transfer an image from a source domain to a related target domain, which involves a wide range of computer vision tasks such as style transfer, super-resolution and pose estimation [35]. In I2I, the translated image should be realistic to fit the style of the target domain by changing the domain-specific features accordingly, and faithful to preserve the domain-independent features of the source image. Over the past few years, generative adversarial networks [12] (GANs)-based methods [10, 60, 54, 36, 3, 57, 44, 19, 17, 26, 10] dominated this field due to their ability to generate high-quality samples.
+
+In contrast to GANs, score-based diffusion models (SBDMs) [48, 16, 34, 49, 2, 31] perturb data to a Gaussian noise by a diffusion process and learn the reverse process to transform the noise back to the data distribution. Recently, SBDMs achieved competitive or even superior image generation performance to GANs [9] and thus were naturally applied to unpaired I2I [7, 32], which have achieved
+
+
+Figure 1: (a) Apart from the SDE, the EGSDE incorporates a realism expert and a faithful expert to preserve the domain-independent features and discard domain-specific ones. (b) Representative translation results on three unpaired I2I tasks.
+
+the state-of-the-art FID [13] and KID [4] results empirically. However, we notice that these methods did not leverage the training data in the source domain at all. Indeed, they trained a diffusion model solely on the target domain and exploited the test source image during inference (see details in Sec. 2.2). Therefore, we argue that if the training data in the source domain can be exploited together with those in the target domain, one can learn domain-specific and domain-independent features to improve both the realism and faithfulness of the SBDMs in unpaired I2I.
+
+To this end, we propose energy-guided stochastic differential equations (EGSDE) that employs an energy function pretrained across the two domains to guide the inference process of a pretrained SDE for realistic and faithful unpaired I2I. Formally, EGSDE defines a valid conditional distribution via a reverse time SDE that composes the energy function and the pretrained SDE. Ideally, the energy function should encourage the transferred image to preserve the domain-independent features and discard domain-specific ones. To achieve this, we introduce two feature extractors that learn domain-independent features and domain-specific ones respectively, and define the energy function upon the similarities between the features extracted from the transferred image and the test source image. Further, we provide an alternative explanation of the discretization of EGSDE in the formulation of product of experts [15]. In particular, the pretrained SDE and the two feature extractors in the energy function correspond to three experts and each solely contributes to faithfulness or realism.
+
+Empirically, we validate our method on the widely-adopted AFHQ [8] and CelebA-HQ [20] datasets including Cat $\rightarrow$ Dog, Wild $\rightarrow$ Dog and Male $\rightarrow$ Female tasks. We compare to a large family of baselines, including the GANs-based ones [36, 60, 17, 26, 3, 10, 57, 58] and SBDMs-based ones [7, 32] under four metrics (e.g., FID). EGSDE not only consistently outperforms SBDMs-based methods in almost all settings but also achieves the SOTA realism results without harming the faithful performance. Furthermore, EGSDE allows for flexible trade-offs between realism and faithfulness and we improve the FID further (e.g., 51.04 in Cat $\rightarrow$ Dog and 50.43 in Wild $\rightarrow$ Dog) by tuning hyper-parameters. EGSDE can also be extended to multi-domain translation easily.
+
+# 2 Background
+
+# 2.1 Score-based Diffusion Models
+
+Score-based diffusion models (SBDMs) gradually perturb data by a forward diffusion process, and then reverse it to recover the data [49, 2, 47, 16, 9]. Let $q(\pmb{y}_0)$ be the unknown data distribution
+
+on $\mathbb{R}^D$ . The forward diffusion process $\{\pmb{y}_t\}_{t\in [0,T]}$ , indexed by time $t$ , can be represented by the following forward SDE:
+
+$$
+d \boldsymbol {y} = \boldsymbol {f} (\boldsymbol {y}, t) d t + g (t) d \boldsymbol {w}, \tag {1}
+$$
+
+where $\pmb{w} \in \mathbb{R}^{D}$ is a standard Wiener process, $\pmb{f}(\cdot, t): \mathbb{R}^{D} \to \mathbb{R}^{D}$ is the drift coefficient and $g(t) \in \mathbb{R}$ is the diffusion coefficient. The $f(\pmb{y}, t)$ and $g(t)$ is related into the noise size and determines the perturbation kernel $q_{t|0}(\pmb{y}_t | \pmb{y}_0)$ from time 0 to $t$ . In practice, the $f(\pmb{y}, t)$ is usually affine so that the perturbation kernel is a linear Gaussian distribution and can be sampled in one step.
+
+Let $q_{t}(\pmb{y})$ be the marginal distribution of the SDE at time $t$ in Eq. (1). Its time reversal can be described by another SDE [49]:
+
+$$
+\mathrm {d} \boldsymbol {y} = [ \boldsymbol {f} (\boldsymbol {y}, t) - g (t) ^ {2} \nabla_ {\boldsymbol {y}} \log q _ {t} (\boldsymbol {y}) ] \mathrm {d} t + g (t) \mathrm {d} \bar {\boldsymbol {w}}, \tag {2}
+$$
+
+where $\overline{\boldsymbol{w}}$ is a reverse-time standard Wiener process, and $\mathrm{dt}$ is an infinitesimal negative timestep. [49] adopts a score-based model $s(\pmb {y},t)$ to approximate the unknown $\nabla_{\pmb{y}}\log q_t(\pmb {y})$ by score matching, thus inducing a score-based diffusion model (SBDM), which is defined by a SDE:
+
+$$
+\mathrm {d} \boldsymbol {y} = [ \boldsymbol {f} (\boldsymbol {y}, t) - g (t) ^ {2} \boldsymbol {s} (\boldsymbol {y}, t) ] \mathrm {d} t + g (t) \mathrm {d} \bar {\boldsymbol {w}}. \tag {3}
+$$
+
+There are numerous SDE solver to solve the Eq. (3) to generate images. [49] discretizes it using the Euler-Maruyama solver. Formally, adopting a step size of $h$ , the iteration rule from $s$ to $t = s - h$ is:
+
+$$
+\boldsymbol {y} _ {t} = \boldsymbol {y} _ {s} - \left[ \boldsymbol {f} \left(\boldsymbol {y} _ {s}, s\right) - g (s) ^ {2} \boldsymbol {s} \left(\boldsymbol {y} _ {s}, s\right) \right] h + g (s) \sqrt {h} z, \quad z \sim \mathcal {N} (\boldsymbol {0}, \boldsymbol {I}). \tag {4}
+$$
+
+# 2.2 SBDMs in Unpaired Image to Image Translation
+
+Given unpaired images from the source domain $\mathcal{X} \subset \mathbb{R}^D$ and the target domain $\mathcal{Y} \subset \mathbb{R}^D$ as the training data, the goal of unpaired I2I is to transfer an image from the source domain to the target domain. Such a process can be formulated as designing a distribution $p(\boldsymbol{y}_0 | \boldsymbol{x}_0)$ on the target domain $\mathcal{Y}$ conditioned on an image $\boldsymbol{x}_0 \in \mathcal{X}$ to transfer. The translated image should be realistic for the target domain by changing the domain-specific features and faithful for the source image by preserving the domain-independent features.
+
+ILVR [7] uses a diffusion model on the target domain for realism. Formally, ILVR starts from $\pmb{y}_T\sim \mathcal{N}(\pmb {0},\pmb {I})$ and samples from the diffusion model according to Eq. (4) to obtain $\pmb{y}_t$ . For faithfulness, it further refines $\pmb{y}_t$ by adding the residual between the sample $\pmb{y}_t$ and the perturbed source image $\pmb{x}_t$ through a non-trainable low-pass filter
+
+$$
+\boldsymbol {y} _ {t} \leftarrow \boldsymbol {y} _ {t} + \Phi (\boldsymbol {x} _ {t}) - \Phi (\boldsymbol {y} _ {t}), \quad \boldsymbol {x} _ {t} \sim q _ {t | 0} (\boldsymbol {x} _ {t} | \boldsymbol {x} _ {0}), \tag {5}
+$$
+
+where $\Phi (\cdot)$ is a low-pass filter and $q_{t|0}(\cdot |\cdot)$ is the perturbation kernel determined by the forward SDE in Eq. (1).
+
+Similarly, SDEdit [32] also adopts a SBDM on the target domain for realism, i.e., sampling from the SBDM according to Eq. (4). For faithfulness, SDEdit starts the generation process from the noisy source image $\pmb{y}_M \sim q_{M|0}(\pmb{y}_M | \pmb{x}_0)$ , where $M$ is a middle time between 0 and $T$ , and is chosen to preserve the original overall structure and discard local details. We use $p_{r1}(\pmb{y}_0 | \pmb{x}_0)$ to denote the marginal distribution defined by such SDE conditioned on $\pmb{x}_0$ .
+
+Notably, these methods did not leverage the training data in the source domain at all and thus can be sub-optimal in terms of both the realism and faithfulness in unpaired I2I.
+
+# 3 Method
+
+To overcome the limitations of existing methods [7, 32] as highlighted in Sec. 2.2, we propose energy-guided stochastic differential equations (EGSDE) that employs an energy function pre-trained across the two domains to guide the inference process of a pretrained SDE for realistic and faithful unpaired I2I (see Fig. 2). EGSDE defines a valid conditional distribution $p(\pmb{y}_0|\pmb{x}_0)$ by compositing a pretrained SDE and a pretrained energy function under mild regularity conditions² as follows:
+
+$$
+\mathrm {d} \boldsymbol {y} = [ \boldsymbol {f} (\boldsymbol {y}, t) - g (t) ^ {2} (\boldsymbol {s} (\boldsymbol {y}, t) - \nabla_ {\boldsymbol {y}} \mathcal {E} (\boldsymbol {y}, \boldsymbol {x} _ {0}, t)) ] \mathrm {d} t + g (t) \mathrm {d} \bar {\boldsymbol {w}}, \tag {6}
+$$
+
+
+Figure 2: The overview of our EGSDE. Starting from the noisy source image, we can run the EGSDE for unpaired I2I, which employs an energy function $\mathcal{E}(\pmb{y},\pmb{x},t)$ pretrained on both the source and target domains to guide the inference process of a pretrained SDE ( $s(\pmb{y},t)$ , realism expert 1). The energy function is decomposed into two terms further, where the realistic expert $2\mathcal{E}_s(\pmb{y},\pmb{x},t)$ encourages the transferred image to discard domain-specific features and the faithful expert $\mathcal{E}_i(\pmb{y},\pmb{x},t)$ aims to preserve the domain-independent ones.
+
+where $\overline{\boldsymbol{w}}$ is a reverse-time standard Wiener process, $\mathrm{d}t$ is an infinitesimal negative timestep, $\boldsymbol{s}(\cdot ,\cdot):$ $\mathbb{R}^D\times \mathbb{R}\to \mathbb{R}^D$ is the score-based model in the pretrained SDE and $\mathcal{E}(\cdot ,\cdot ,\cdot):\mathbb{R}^{D}\times \mathbb{R}^{D}\times \mathbb{R}\rightarrow \mathbb{R}$ is the energy function. The start point $\pmb {y}_M$ is sampled from the perturbation distribution $q_{M|0}(\pmb {y}_M|\pmb {x}_0)$ [32], where $M = 0.5T$ typically. We obtain the transferred images by taking the samples at endpoint $t = 0$ following the SDE in Eq. (6).
+
+Similar to the prior work [7, 32], EGSDE employs an SDE trained solely in the target domain as in Eq. (2), which defines a marginal distribution of the target images and mainly contributes to the realism of the transferred samples. In contrast, the energy function involves the training data across both the source and target domain, making EGSDE distinct from the prior work [7, 32]. Notably, although many other possibilities exist, we carefully design the energy function such that it (approximately) encourages the sample to retain the domain-independent features and discard the domain-specific ones to improve both the faithfulness and realism of the transferred sample. Below, we formally formulate the energy function.
+
+# 3.1 Choice of Energy
+
+In this section, we show how to design the energy function. Intuitively, during the translation, the domain-independent features (pose, color, etc. on $\mathrm{Cat} \to \mathrm{Dog}$ ) should be preserved while the domain-specific features (beard, nose, etc. on $\mathrm{Cat} \to \mathrm{Dog}$ ) should be changed accordingly. Motivated by this, we decompose the energy function $\mathcal{E}(\boldsymbol{y}, \boldsymbol{x}, t)$ as the sum of two log potential functions [5]:
+
+$$
+\begin{array}{l} \mathcal {E} (\boldsymbol {y}, \boldsymbol {x}, t) = \lambda_ {s} \mathcal {E} _ {s} (\boldsymbol {y}, \boldsymbol {x}, t) + \lambda_ {i} \mathcal {E} _ {i} (\boldsymbol {y}, \boldsymbol {x}, t) (7) \\ = \lambda_ {s} \mathbb {E} _ {q _ {t | 0} (\boldsymbol {x} _ {t} | \boldsymbol {x})} \mathcal {S} _ {s} (\boldsymbol {y}, \boldsymbol {x} _ {t}, t) - \lambda_ {i} \mathbb {E} _ {q _ {t | 0} (\boldsymbol {x} _ {t} | \boldsymbol {x})} \mathcal {S} _ {i} (\boldsymbol {y}, \boldsymbol {x} _ {t}, t), (8) \\ \end{array}
+$$
+
+where $\mathcal{E}_i(\cdot, \cdot, \cdot): \mathbb{R}^D \times \mathbb{R}^D \times \mathbb{R} \to \mathbb{R}$ and $\mathcal{E}_s(\cdot, \cdot, \cdot): \mathbb{R}^D \times \mathbb{R}^D \times \mathbb{R} \to \mathbb{R}$ are the log potential functions, $x_t$ is the perturbed source image in the forward SDE, $q_{t|0}(\cdot|\cdot)$ is the perturbation kernel from time 0 to time $t$ in the forward SDE, $\mathcal{S}_s(\cdot, \cdot, \cdot): \mathbb{R}^D \times \mathbb{R}^D \times \mathbb{R} \to \mathbb{R}$ and $\mathcal{S}_i(\cdot, \cdot, \cdot): \mathbb{R}^D \times \mathbb{R}^D \times \mathbb{R} \to \mathbb{R}$ are two functions measuring the similarity between the sample and perturbed source image, and $\lambda_s \in \mathbb{R}_{>0}, \lambda_i \in \mathbb{R}_{>0}$ are two weighting hyper-parameters. Note that the expectation w.r.t. $q_{t|0}(\boldsymbol{x}_t|\boldsymbol{x})$ in Eq. (7) guarantees that the energy function changes slowly over the trajectory to satisfy the regularity conditions in Appendix A.1.
+
+To specify $S_{s}(\cdot ,\cdot ,\cdot)$ , we introduce a time-dependent domain-specific feature extractor $E_{s}(\cdot ,\cdot):\mathbb{R}^{D}\times \mathbb{R}\to \mathbb{R}^{C\times H\times W}$ , where $C$ is the channel-wise dimension, $H$ and $W$ are the dimension of height and width. In particular, $E_{s}(\cdot ,\cdot)$ is the all but the last layer of a classifier that is trained on both domains to predict whether an image is from the source domain or the target domain. Intuitively, $E_{s}(\cdot ,\cdot)$ will preserve the domain-specific features and discard the domain-independent features for accurate predictions. Building upon it, $S_{s}(\cdot ,\cdot ,\cdot)$ is defined as the cosine similarity between the
+
+features extracted from the generated sample and the source image as follows:
+
+$$
+\mathcal {S} _ {s} (\boldsymbol {y}, \boldsymbol {x} _ {t}, t) = \frac {1}{H W} \sum_ {h, w} \frac {E _ {s} ^ {h w} (\boldsymbol {x} _ {t} , t) ^ {\top} E _ {s} ^ {h w} (\boldsymbol {y} , t)}{| | E _ {s} ^ {h w} (\boldsymbol {x} _ {t} , t) | | _ {2} | | E _ {s} ^ {h w} (\boldsymbol {y} , t) | | _ {2}}, \tag {9}
+$$
+
+where $E_s^{hw}(\cdot, \cdot) \in \mathbb{R}^C$ denote the channel-wise feature at spatial position $(h, w)$ . Here we employ the cosine similarity since it preserves the spatial information and helps to improve the FID score empirically (see Appendix C.1 for the ablation study). Intuitively, reducing the energy value in Eq. (7) encourages the transferred sample to discard the domain-specific features to improve realism.
+
+To specify $S_{i}(\cdot, \cdot, \cdot)$ , we introduce a domain-independent feature extractor $E_{i}(\cdot, \cdot): \mathbb{R}^{D} \times \mathbb{R} \rightarrow \mathbb{R}^{D}$ , which is a low-pass filter. Intuitively, $E_{i}(\cdot, \cdot)$ will preserve the overall structures (i.e., domain-independent features) and discard local information like textures (i.e., domain-specific features). Building upon it, $S_{i}(\cdot, \cdot, \cdot)$ is defined as the negative squared $L_{2}$ distance between the features extracted from the generated sample and source image as follows:
+
+$$
+\mathcal {S} _ {i} (\boldsymbol {y}, \boldsymbol {x} _ {t}, t) = - | | E _ {i} (\boldsymbol {y}, t) - E _ {i} (\boldsymbol {x} _ {t}, t) | | _ {2} ^ {2}. \tag {10}
+$$
+
+Here, we choose negative squared $L_{2}$ distance as the similarity metric because it helps to preserve more domain-independent features empirically (see Appendix C.1 for the ablation study). Intuitively, reducing the energy value in Eq. (7) encourages the transferred sample to preserve the domain-independent features to improve faithfulness. In this paper we employ a low-pass filter for its simplicity and effectiveness while we can train more sophisticated $E_{i}$ , e.g., based on disentangled representation learning methods [42, 6, 14, 23, 28], on the data in the two domains.
+
+In our preliminary experiment, alternative to Eq. (7), we consider a simpler energy function that only involves the original source image $\pmb{x}$ as follows:
+
+$$
+\mathcal {E} (\boldsymbol {y}, \boldsymbol {x}, t) = \lambda_ {s} \mathcal {S} _ {s} (\boldsymbol {y}, \boldsymbol {x}, t) - \lambda_ {i} \mathcal {S} _ {i} (\boldsymbol {y}, \boldsymbol {x}, t), \tag {11}
+$$
+
+which does not require to take the expectation w.r.t. $\boldsymbol{x}_t$ . We found that it did not perform well because it is not reasonable to measure the similarity between the noise-free source image and the transferred sample in a gradual denoising process. See Appendix C.2 for empirical results.
+
+# 3.2 Solving the Energy-guided Reverse-time SDE
+
+Based on the pretrained score-based model $s(\pmb{y}, t)$ and energy function $\mathcal{E}(\pmb{y}, \pmb{x}, t)$ , we can solve the proposed energy-guided SDE to generate samples from conditional distribution $p(\pmb{y}_0 | \pmb{x}_0)$ . There are numerical solvers to approximate trajectories from SDEs. In this paper, we take the Euler-Maruyama solver following [32] for a fair comparison. Given the EGSDE as in Eq. (6) and adopting a step size $h$ , the iteration rule from $s$ to $t = s - h$ is:
+
+$$
+\boldsymbol {y} _ {t} = \boldsymbol {y} _ {s} - \left[ \boldsymbol {f} (\boldsymbol {y}, s) - g (s) ^ {2} \left(\boldsymbol {s} \left(\boldsymbol {y} _ {s}, s\right) - \nabla_ {\boldsymbol {y}} \mathcal {E} \left(\boldsymbol {y} _ {s}, \boldsymbol {x} _ {0}, s\right)\right) \right] h + g (s) \sqrt {h} \boldsymbol {z}, \quad \boldsymbol {z} \sim \mathcal {N} (\boldsymbol {0}, \boldsymbol {I}). \tag {12}
+$$
+
+The expectation in $\mathcal{E}(\pmb{y}_s, \pmb{x}_0, s)$ is estimated by the Monte Carlo method of a single sample for efficiency. For brevity, we present the general sampling procedure of our method in Algorithm 1. In experiments, we use the variance preserve energy-guided SDE (VP-EGSDE) [49, 16] and the details are explained in Appendix A.3, where we can modify the noise prediction network to $\tilde{\epsilon}(\pmb{y}, \pmb{x}_0, t) = \epsilon(\pmb{y}, t) + \sqrt{\bar{\beta}_t} \nabla_{\pmb{y}} \mathcal{E}(\pmb{y}, \pmb{x}_0, t)$ and take it into the sampling procedure in DDPM [16]. Following SDEdit [32], we further extend this by repeating the Algorithm $1$ $K$ times (see details in Appendix A.2). Further, we explain the connection with classifier guidance[9] in Appendix A.5.
+
+# 3.3 EGSDE as Product of Experts
+
+Inspired by the posterior inference process in diffusion models [46], we present a product of experts [15] explanation for the discretized sampling process of EGSDE, which formalizes our motivation in an alternative perspective and provides insights on the role of each component in EGSDE.
+
+We first define a conditional distribution $\tilde{p} (\pmb {y}_t|\pmb {x}_0)$ at time $t$ as a product of experts:
+
+$$
+\tilde {p} \left(\boldsymbol {y} _ {t} \mid \boldsymbol {x} _ {0}\right) = \frac {p _ {r 1} \left(\boldsymbol {y} _ {t} \mid \boldsymbol {x} _ {0}\right) p _ {e} \left(\boldsymbol {y} _ {t} \mid \boldsymbol {x} _ {0}\right)}{Z _ {t}}, \tag {13}
+$$
+
+# Algorithm 1 EGSDE for unpaired image-to-image translation
+
+Require: the source image $x_0$ , the initial time $M$ , denoising steps $N$ , weighting hyper-parameters
+
+$\lambda_{s}, \lambda_{i}$ , the similarity function $\mathcal{S}_s(\cdot, \cdot, \cdot)$ , $\mathcal{S}_i(\cdot, \cdot, \cdot)$ , the score function $s(\cdot, \cdot)$
+
+$\pmb{y} \sim q_{M|0}(\pmb{y}|\pmb{x}_0)$ # the start point
+
+$$
+h = \frac {M}{N}
+$$
+
+for $i = N$ to 1 do
+
+$$
+s \leftarrow i h
+$$
+
+$\pmb{x} \sim q_{s|0}(\pmb{x}|\pmb{x}_0)$ # sample perturbed source image from the perturbation kernel
+
+$\mathcal{E}(\pmb {y},\pmb {x},s)\gets \lambda_s\mathcal{S}_s(\pmb {y},\pmb {x},s) - \lambda_i\mathcal{S}_i(\pmb {y},\pmb {x},s)\#$ compute energy with one Monte Carlo
+
+$\pmb{y} \gets \pmb{y} - [\pmb{f}(\pmb{y}, s) - g(s)^2 (\pmb{s}(\pmb{y}, s) - \nabla_{\pmb{y}}\mathcal{E}(\pmb{y}, \pmb{x}, s))]h$ # the update rule in Eq. (12)
+
+$$
+z \sim \mathcal {N} (\mathbf {0}, I) \text {i f} i > 1, \text {e l s e} z = \mathbf {0}
+$$
+
+$$
+\boldsymbol {y} \leftarrow \boldsymbol {y} + g (s) \sqrt {h} z
+$$
+
+end for
+
+$$
+\mathbf {y} _ {0} \leftarrow \mathbf {y}
+$$
+
+return $y_0$
+
+where $Z_{t}$ is the partition function, $p_{e}(\pmb{y}_{t}|\pmb{x}_{0})\propto \exp (-\mathcal{E}(\pmb{y}_{t},\pmb{x}_{0},t))$ and $p_{r1}(\pmb{y}_t|\pmb{x}_0)$ is the marginal distribution at time $t$ defined by SDEdit based on a pretrained SDE on the target domain.
+
+To sample from $\tilde{p} (\pmb {y}_t|\pmb {x}_0)$ , we need to construct a transition kernel $\tilde{p} (\pmb {y}_t|\pmb {y}_s)$ , where $t = s - h$ and $h$ is small. Following [46], using the desirable equilibrium $\tilde{p} (\pmb {y}_t|\pmb {x}_0) = \int \tilde{p} (\pmb {y}_t|\pmb {y}_s)\tilde{p} (\pmb {y}_s|\pmb {x}_0)d\pmb {y}_s$ , we construct the $\tilde{p} (\pmb {y}_t|\pmb {y}_s)$ as follows:
+
+$$
+\tilde {p} \left(\boldsymbol {y} _ {t} \mid \boldsymbol {y} _ {s}\right) = \frac {p \left(\boldsymbol {y} _ {t} \mid \boldsymbol {y} _ {s}\right) p _ {e} \left(\boldsymbol {y} _ {t} \mid \boldsymbol {x} _ {0}\right)}{\tilde {Z} _ {t} \left(\boldsymbol {y} _ {s}\right)}, \tag {14}
+$$
+
+where $\tilde{Z}_t(\pmb{y}_s)$ is the partition function and $p(\pmb{y}_t|\pmb{y}_s) = \mathcal{N}(\pmb{\mu}(\pmb{y}_s,h),\Sigma (s,h)\pmb {I})$ is the transition kernel of the pretrained SDE in Eq. (4), i.e., $\pmb {\mu}(\pmb {y}_s,h) = \pmb {y}_s - [\pmb {f}(\pmb {y}_s,s) - g(s)^2\pmb {s}(\pmb {y}_s,s)]h$ and $\Sigma (s,h) = g(s)^2 h$ . Assuming that $\mathcal{E}(\pmb{y}_t,\pmb{x}_0,t)$ has low curvature relative to $\Sigma (s,h)^{-1}$ , it can be approximated using Taylor expansion around $\pmb{\mu}(\pmb{y}_s,h)$ and further we can obtain
+
+$$
+\tilde {p} \left(\boldsymbol {y} _ {t} \mid \boldsymbol {y} _ {s}\right) \approx \mathcal {N} \left(\boldsymbol {\mu} \left(\boldsymbol {y} _ {s}, h\right) - \Sigma (s, h) \nabla_ {\boldsymbol {y} ^ {\prime}} \mathcal {E} \left(\boldsymbol {y} ^ {\prime}, \boldsymbol {x} _ {0}, t\right) \mid_ {\boldsymbol {y} ^ {\prime} = \boldsymbol {\mu} \left(\boldsymbol {y} _ {s}, h\right)}, \Sigma (s, h) \boldsymbol {I}\right). \tag {15}
+$$
+
+More details about derivation are available in Appendix A.4. We can observe the transition kernel $\tilde{p}(\boldsymbol{y}_t|\boldsymbol{y}_s)$ in (15) is equal to the discretization of our EGSDE in Eq. (12). Therefore, solving the energy-guided SDE in a discretization manner is approximately equivalent to drawing samples from a product of experts in Eq. (13). Note that $\mathcal{E}(\boldsymbol{y}_t,\boldsymbol{x}_0,t) = \lambda_s\mathcal{E}_s(\boldsymbol{y}_t,\boldsymbol{x}_0,t) + \lambda_i\mathcal{E}_i(\boldsymbol{y}_t,\boldsymbol{x}_0,t)$ , the $\tilde{p}(\boldsymbol{y}_t|\boldsymbol{x}_0)$ can be rewritten as:
+
+$$
+\tilde {p} \left(\boldsymbol {y} _ {t} \mid \boldsymbol {x} _ {0}\right) = \frac {p _ {r 1} \left(\boldsymbol {y} _ {t} \mid \boldsymbol {x} _ {0}\right) p _ {r 2} \left(\boldsymbol {y} _ {t} \mid \boldsymbol {x} _ {0}\right) p _ {f} \left(\boldsymbol {y} _ {t} \mid \boldsymbol {x} _ {0}\right)}{Z _ {t}}, \tag {16}
+$$
+
+where $p_{r2}(\boldsymbol{y}_t|\boldsymbol{x}_0)\propto \exp (-\lambda_s\mathcal{E}_s(\boldsymbol{y}_t,\boldsymbol{x}_0,t)),p_f(\boldsymbol{y}_t|\boldsymbol{x}_0)\propto \exp (-\lambda_i\mathcal{E}_i(\boldsymbol{y}_t,\boldsymbol{x}_0,t))$
+
+In Eq. (16), by setting $t = 0$ , we can explain that the transferred samples approximately follow the distribution defined by the product of three experts, where $p_{r1}(\boldsymbol{y}_t|\boldsymbol{x}_0)$ and $p_{r2}(\boldsymbol{y}_t|\boldsymbol{x}_0)$ are the realism experts and $p_f(\boldsymbol{y}_t|\boldsymbol{x}_0)$ is the faithful expert, corresponding to the score function $s(\boldsymbol{y},t)$ and the log potential functions $\mathcal{E}_s(\boldsymbol{y},\boldsymbol{x},t)$ and $\mathcal{E}_i(\boldsymbol{y},\boldsymbol{x},t)$ respectively. Such a formulation clearly explains the role of each expert in EGSDE and supports our empirical results.
+
+# 4 Related work
+
+Apart from the prior work mentioned before, we discuss other related work including GANs-based methods for unpaired I2I and SBDMs-based methods for image translation.
+
+GANs-based methods for Unpaired I2I. Although previous paired image translation methods have also achieved remarkable performances [18, 51, 50, 37, 55, 59], we mainly focus on unpaired image translation in this work. The methods for two-domain unpaired I2I are mainly divided into two classes: two-side and one-side mapping [35, 57]. In the two-side framework [60, 54, 25, 29, 27, 24, 11, 1, 53, 56, 21], the cycle-consistency constraint is the most widely-used strategy such as in
+
+
+CUT ILVR SDEdit Ours Source
+Figure 3: The qualitative comparison on Cat $\rightarrow$ Dog, Wild $\rightarrow$ Dog and Male $\rightarrow$ Female. Our method achieved better visual quality for both realism and faithfulness. For example, in the forth column, we successfully preserve the domain-independent features (i.e. green ground, pose and yellow color of body) and discard the domain-specific ones (i.e. leopard print).
+
+CycleGAN [60], DualGAN [54] and DiscoGAN [25]. The key idea is that the translated image should be able to be reconstructed by an inverse mapping. More recently, there are numerical studies to improve this such as SCAN [27] and U-GAT-IT [24]. Specifically, U-GAT-IT [24] applies an attention module to let the generator and discriminator focus on more important regions instead of the whole regions through the auxiliary classifier. Since such bijective projection is too restrictive, several studies are devoted to one-side mapping [36, 3, 10, 60, 57, 38, 19]. One representative approach is to design some kind of geometry distance to preserve content [35]. For example, DistanceGAN [3] keeps the distances between images within domains. GCGAN [10] maintains geometry-consistency between input and output. CUT [36] maximizes the mutual information between the input and output using contrastive learning. LSeSim [57] learns spatially-correlative representation to preserve scene structure consistency via self-similarities.
+
+SBDMs-based methods for Image Translation. Several studies leveraged SBDMs for image translation due to their powerful generative ability and achieved good results. For example, Diffusion-CLIP [22] fine-tune the score network with CLIP [39] loss, which is applied on text-driven image manipulation, zero-shot image manipulation and multi-attribute transfer successfully. GLIDE [33] and SDG [30] has achieved great performance on text-to-image translation. As for I2I, SR3 [41] and Palette [40] learn a conditional SBDM and outperform state-of-art GANs-based methods on super-resolution, colorization and so on, which needs paired data. For unpaired I2I, UNIT-DDPM [43] learns two SBDMs and two domain translation models using cycle-consistency loss. Compared with it, our method only needs one SBDM on the target domain, which is a kind of one-side mapping. ILVR [7] and SDEdit [32] utilize a SBDM on the target domain and exploited the test source image to refine inference, which ignored the training data in the source domain. Compared with these methods, our method employs an energy function pretrained across both the source and target domains to improve the realism and faithfulness of translated images.
+
+# 5 Experiment
+
+Datasets. We validated the EGSDE on following datasets, where all images are resized to $256 \times 256$ : (1) CelebA-HQ [20] contains high quality face images and is separated into two domains: male and female. Each category has 1000 testing images. We perform Male $\rightarrow$ Female on this dataset.
+(2) AFHQ [8] consists of high-resolution animal face images including three domains: cat, dog and wild, which has relatively large variations. Each domain has 500 testing images. We perform Cat $\rightarrow$ Dog and Wild $\rightarrow$ Dog on this dataset. We also perform multi-domain translation on AFHQ dataset and the experimental results are reported in Appendix D.
+
+Implementation. The time-dependent domain-specific extractor $E_{s}(\boldsymbol{x},t)$ is trained based on the backbone in [9]. The resize function including downsampling and upsampling operation is used as low-pass filter and is implemented by [45]. For generation process, by default, the weight parameter $\lambda_{s}$ , $\lambda_{i}$ is set 500 and 2 respectively. The initial time $M$ and denoising steps $N$ is set $0.5T$ and 500 by default. More details about implementation are available in Appendix B.
+
+Evaluation Metrics. We evaluate translated images from two aspects: realism and faithfulness. For realism, we report the widely-used Frechet Inception Score (FID) [13] between translated images and the target dataset. To quantify faithfulness, we report the $L_{2}$ distance, PSNR and SSIM [52] between each input-output pair. To quantify both faithfulness and realism, we leverage Amazon Mechanical Turk(AMT) human evaluation to perform pairwise comparisons between the baselines and EGSDE. More details is available in Appendix B.6.
+
+# 5.1 Two-Domain Unpaired Image Translation
+
+In this section, we compare EGSDE with the following state-of-the-art I2I methods in three tasks: SBDMs-based methods including ILVR [7] and SDEdit [32], and GANs-based methods including CUT [36], which are reproduced using public code. On the most popular benchmark Cat $\rightarrow$ Dog, we also report the performance of other state-of-the-art GANs-methods, where StarGAN v2 [8] is evaluated by the provided public checkpoint and the others are public results from CUT[36] and ITTR [58]. We provide more details about reproductions in Appendix B.7.
+
+The quantitative comparisons and qualitative results are shown in Table 1 and Figure 3. We can derive several observations. First, our method outperforms the SBDMs-based methods significantly in almost all realism and faithfulness metrics, suggesting the effectiveness of employing energy function pretrained on both domains to guide the generation process. Especially, compared with the most direct competitor, i.e., SDEdit, with a lower $L_{2}$ distance at the same time, EGSDE improves the FID score by 8.35, 8.76 and 7.5 on Cat → Dog, Wild → Dog and Male → Female respectively. Second, EGSDE† outperforms the current state-of-art GANs-based methods by a large margin on the challenging AFHQ dataset. For example, compared with CUT [36], we achieve an improvement of FID score with 25.17 and 42.51 on the Cat → Dog and Wild → Dog tasks respectively. In addition, the human evaluation shows that EGSDE are preferred compared to all baselines (> 50%). The qualitative results in Figure 3 agree with quantitative comparisons in Table 1, where our method achieved the results with the best visual quality for both realism and faithfulness. We show more qualitative results and select some failure cases in Appendix C.6.
+
+# 5.2 Ablation Studies
+
+The function of each expert. We validate the function of realistic expert $\mathcal{E}_s(\pmb {y},\pmb {x},t)$ and faithful expert $\mathcal{E}_i(\pmb {y},\pmb {x},t)$ by changing the weighting hyper-parameter $\lambda_{s}$ and $\lambda_{i}$ . As shown in Table 3 and Figure 1, larger $\lambda_{s}$ results in more realistic images and larger $\lambda_{i}$ results in more faithful images. More results is available in Appendix C.5.
+
+The choice of initial time $M$ . We explore the effect of the initial time $M$ of EGSDE. As shown in Figure 4, the larger $M$ results in more realistic and less faithful image. More results is available in Appendix C.3.
+
+Repeating $K$ Times. Following SDEdit [32], we show the results of repeating the Algorithm 1 $K$ times. The quantitative and qualitative results are depicted in Table 2 and Figure 4. The experimental results show the EGSDE outperforms SDEdit in each $K$ step in all metrics. With the increase of $K$ , the SDEdit generates more realism images but the faithful metrics decrease sharply, because it only
+
+Table 1: Quantitative comparison. ILVR [7], SDEdit [32] and CUT [36] are reproduced using public code. StarGAN v2 [8] is evaluated by the provided public checkpoint and the other methods marked by * are public results from CUT[36] and ITTR [58]. All SBDMs-based methods and StarGAN v2 are repeated 5 times to eliminate randomness. CUT is conducted once since it learns a deterministic mapping. AMT show the preference rate of EGSDE against baselines via human evaluation. The EGSDE use the default-parameters ( $\lambda_s = 500$ , $\lambda_i = 2$ , $M = 0.5T$ ) and $\mathrm{EGSDE}^\dagger$ use the parameters with $\lambda_s = 700$ , $\lambda_i = 0.5$ , $M = 0.6T$ .
+
+| Model | FID ↓ | L2 ↓ | PSNR ↑ | SSIM ↑ | AMT ↑ |
| Cat → Dog |
| CycleGAN* [60] | 85.9 | - | - | - | - |
| MUNIT* [17] | 104.4 | - | - | - | - |
| DRIT* [26] | 123.4 | - | - | - | - |
| Distance* [3] | 155.3 | - | - | - | - |
| SelfDistance* [3] | 144.4 | - | - | - | - |
| GCGAN* [10] | 96.6 | - | - | - | - |
| LSeSim* [57] | 72.8 | - | - | - | - |
| ITTR (CUT)* [58] | 68.6 | - | - | - | - |
| StarGAN v2 [8] | 54.88 ± 1.01 | 133.65 ± 1.54 | 10.63 ± 0.10 | 0.27 ± 0.003 | - |
| CUT* [36] | 76.21 | 59.78 | 17.48 | 0.601 | 79.6% |
| ILVR [7] | 74.37 ± 1.55 | 56.95 ± 0.14 | 17.77 ± 0.02 | 0.363 ± 0.001 | 75.4% |
| SDEdit [32] | 74.17 ± 1.01 | 47.88 ± 0.06 | 19.19 ± 0.01 | 0.423 ± 0.001 | 65.2% |
| EGSDE | 65.82 ± 0.77 | 47.22 ± 0.08 | 19.31 ± 0.02 | 0.415 ± 0.001 | - |
| EGSDET | 51.04 ± 0.37 | 62.06 ± 0.10 | 17.17 ± 0.02 | 0.361 ± 0.001 | - |
| Wild → Dog |
| CUT [36] | 92.94 | 62.21 | 17.2 | 0.592 | 82.4% |
| ILVR [7] | 75.33 ± 1.22 | 63.40 ± 0.15 | 16.85 ± 0.02 | 0.287 ± 0.001 | 73.4% |
| SDEdit [32] | 68.51 ± 0.65 | 55.36 ± 0.05 | 17.98 ± 0.01 | 0.343 ± 0.001 | 57.2% |
| EGSDE | 59.75 ± 0.62 | 54.34 ± 0.08 | 18.14 ± 0.01 | 0.343 ± 0.001 | - |
| EGSDET | 50.43± 0.52 | 66.52± 0.09 | 16.40± 0.01 | 0.300± 0.001 | - |
| Male → Female |
| CUT [36] | 31.94 | 46.61 | 19.87 | 0.74 | 58.6% |
| ILVR [7] | 46.12 ± 0.33 | 52.17 ± 0.10 | 18.59 ± 0.02 | 0.510 ± 0.001 | 88.2% |
| SDEdit [32] | 49.43 ± 0.47 | 43.70 ± 0.03 | 20.03 ± 0.01 | 0.572 ± 0.000 | 74.4% |
| EGSDE | 41.93 ± 0.11 | 42.04 ± 0.03 | 20.35 ± 0.01 | 0.574 ± 0.000 | - |
| EGSDET | 30.61 ± 0.19 | 53.44 ± 0.09 | 18.32 ± 0.02 | 0.510 ± 0.001 | - |
+
+utilizes the source image at the initial time $M$ . As shown in Figure 4, when $K = 3$ , SDEdit discard the domain-independent information of the source image (i.e., color and background) while our method still preserves them without harming realism.
+
+# 6 Conclusions and Discussions
+
+In this paper, we propose energy-guided stochastic differential equations (EGSDE) for realistic and faithful unpaired I2I, which employs an energy function pretrained on both domains to guide the generation process of a pretrained SDE. Building upon two feature extractors, we carefully design the energy function to preserve the domain-independent features and discard domain-specific ones of the source image. We demonstrate the EGSDE by outperforming state-of-art I2I methods on three widely-adopted unpaired I2I tasks.
+
+One limitation of this paper is we employ a low-pass filter as the domain-independent feature extractor for its simplicity and effectiveness while we can train more sophisticated extractor, e.g. based on disentangled representation learning methods [42, 6, 14, 23, 28], on the data in the two domains. We
+
+
+Figure 4: (a) The results of different initial time $M$ . The larger $M$ results in more realistic and less faithful images. (b) The results of repeating the Algorithm 1 $K$ times. With the increase of $\mathbf{K}$ , SDEdit [32] tend to discard the domain-independent information of the source image (e.g., color and background) while our method still preserve them without harming realism.
+
+Table 2: Comparison with SDEdit [32] under different $K$ times on Male $\rightarrow$ Female. The results on other tasks are reported in Appendix C.4.
+
+| Methods | K | FID↓ | L2↓ | PSNR↑ | SSIM↑ |
| SDEdit [32] | 1 | 49.95 | 43.71 | 20.03 | 0.572 |
| EGSDE | 42.17 | 42.07 | 20.35 | 0.573 |
| SDEdit [32] | 2 | 46.26 | 50.70 | 18.77 | 0.542 |
| EGSDE | 38.68 | 47.10 | 19.40 | 0.548 |
| SDEdit [32] | 3 | 45.19 | 55.03 | 18.08 | 0.527 |
| EGSDE | 37.55 | 49.63 | 18.96 | 0.536 |
+
+Table 3: The results of different ${\lambda }_{s}$ and ${\lambda }_{i}$ on Wild $\rightarrow$ Dog. ${\lambda }_{s} = {\lambda }_{i} = 0$ corresponds to SDEdit [32].
+
+| λs,λi | FID↓ | L2↓ | PSNR ↑ | SSIM↑ |
| λs=0,λi=0 | 67.87 | 55.39 | 17.97 | 0.344 |
| λs=100,λi=0 | 60.80 | 56.19 | 17.85 | 0.341 |
| λs=500,λi=0 | 53.72 | 58.65 | 17.47 | 0.335 |
| λs=800,λi=0 | 53.01 | 60.02 | 17.27 | 0.331 |
| λs=0,λi=0.5 | 68.31 | 53.23 | 18.32 | 0.347 |
| λs=0,λi=2 | 71.10 | 51.99 | 18.52 | 0.349 |
| λs=0,λi=5 | 72.70 | 51.44 | 18.61 | 0.351 |
+
+leave this issue in future work. In addition, we must take care to exploit the method to avoid the potential negative social impact (i.e., generating fake images to mislead people).
+
+# Acknowledgement
+
+We thank Cheng Lu, Yuhao Zhou, Haoyu Liang and Shuyu Cheng for helpful discussions about the method and its limitations. This work was supported by the National Key Research and Development Program of China (2020AAA0106302); NSF of China Projects (Nos. 62061136001, 61620106010, 62076145, U19B2034, U1811461, U19A2081, 6197222); Beijing NSF Project (No. JQ19016); Beijing Outstanding Young Scientist Program NO. BJWZYJH012019100020098; a grant from Tsinghua Institute for Guo Qiang; the High Performance Computing Center, Tsinghua University; the Fundamental Research Funds for the Central Universities, and the Research Funds of Renmin University of China (22XNKJ13). Part of the computing resources supporting this work, totaled 500 A100 GPU hours, were provided by High-Flyer AI. (Hangzhou High-Flyer AI Fundamental Research Co., Ltd.). J.Z was also supported by the XPlorer Prize.
+
+# References
+
+[1] Matthew Amodio and Smita Krishnaswamy. Travelgan: Image-to-image translation by transformation vector learning. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 8975-8984, 2019.
+[2] Fan Bao, Chongxuan Li, Jun Zhu, and Bo Zhang. Analytic-dpm: an analytic estimate of the optimal reverse variance in diffusion probabilistic models. In International Conference on Learning Representations, 2021.
+[3] Sagie Benaim and Lior Wolf. One-sided unsupervised domain mapping. Advances in Neural Information Processing Systems, 30, 2017.
+[4] Mikołaj Binkowski, Danica J Sutherland, Michael Arbel, and Arthur Gretton. Demystifying mmd gans. In International Conference on Learning Representations, 2018.
+[5] Christopher M. Bishop. Pattern Recognition and Machine Learning. 2006.
+[6] Xi Chen, Yan Duan, Rein Houthooft, John Schulman, Ilya Sutskever, and Pieter Abbeel. Infogan: Interpretable representation learning by information maximizing generative adversarial nets. Advances in Neural Information Processing Systems, 29, 2016.
+[7] Jooyoung Choi, Sungwon Kim, Yonghyun Jeong, Youngjune Gwon, and Sungroh Yoon. Ilvr: Conditioning method for denoising diffusion probabilistic models. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 14367-14376, 2021.
+[8] Yunjey Choi, Youngjung Uh, Jaejun Yoo, and Jung-Woo Ha. Stargan v2: Diverse image synthesis for multiple domains. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 8188-8197, 2020.
+[9] Prafulla Dhariwal and Alexander Nichol. Diffusion models beat gans on image synthesis. Advances in Neural Information Processing Systems, 34, 2021.
+[10] Huan Fu, Mingming Gong, Chaohui Wang, Kayhan Batmanghelich, Kun Zhang, and Dacheng Tao. Geometry-consistent generative adversarial networks for one-sided unsupervised domain mapping. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 2427-2436, 2019.
+[11] Aaron Gokaslan, Vivek Ramanujan, Daniel Ritchie, Kwang In Kim, and James Tompkin. Improving shape deformation in unsupervised image-to-image translation. In Proceedings of the European Conference on Computer Vision, pages 649-665, 2018.
+[12] Ian Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron Courville, and Yoshua Bengio. Generative adversarial nets. Advances in Neural Information Processing Systems, 27, 2014.
+[13] Martin Heusel, Hubert Ramsauer, Thomas Unterthiner, Bernhard Nessler, and Sepp Hochreiter. Gans trained by a two time-scale update rule converge to a local nash equilibrium. Advances in Neural Information Processing Systems, 30, 2017.
+[14] Irina Higgins, Loic Matthew, Arka Pal, Christopher Burgess, Xavier Glorot, Matthew Botvinick, Shakir Mohamed, and Alexander Lerchner. beta-vae: Learning basic visual concepts with a constrained variational framework. 2016.
+[15] Geoffrey E Hinton. Training products of experts by minimizing contrastive divergence. Neural computation, 14(8):1771-1800, 2002.
+[16] Jonathan Ho, Ajay Jain, and Pieter Abbeel. Denoising diffusion probabilistic models. Advances in Neural Information Processing Systems, 33:6840-6851, 2020.
+[17] Xun Huang, Ming-Yu Liu, Serge Belongie, and Jan Kautz. Multimodal unsupervised image-to-image translation. In Proceedings of the European Conference on Computer Vision, pages 172-189, 2018.
+
+[18] Phillip Isola, Jun-Yan Zhu, Tinghui Zhou, and Alexei A Efros. Image-to-image translation with conditional adversarial networks. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 1125-1134, 2017.
+[19] Liming Jiang, Changxu Zhang, Mingyang Huang, Chunxiao Liu, Jianping Shi, and Chen Change Loy. Tsit: A simple and versatile framework for image-to-image translation. In Proceedings of the European Conference on Computer Vision, pages 206–222, 2020.
+[20] Tero Karras, Timo Aila, Samuli Laine, and Jaakko Lehtinen. Progressive growing of gans for improved quality, stability, and variation. In International Conference on Learning Representations, 2018.
+[21] Oren Katzir, Dani Lischinski, and Daniel Cohen-Or. Cross-domain cascaded deep translation. In Proceedings of the European Conference on Computer Vision, pages 673–689, 2020.
+[22] Gwanghyun Kim, Taesung Kwon, and Jong Chul Ye. Diffusionclip: Text-guided diffusion models for robust image manipulation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 2426-2435, 2022.
+[23] Hyunjik Kim and Andriy Mnih. Disentangling by factorising. In International Conference on Machine Learning, pages 2649-2658, 2018.
+[24] Junho Kim, Minjae Kim, Hyeonwoo Kang, and Kwang Hee Lee. U-gat-it: Unsupervised generative attentional networks with adaptive layer-instance normalization for image-to-image translation. In International Conference on Learning Representations, 2019.
+[25] Taeksoo Kim, Moonsu Cha, Hyunsoo Kim, Jung Kwon Lee, and Jiwon Kim. Learning to discover cross-domain relations with generative adversarial networks. In International Conference on Machine Learning, pages 1857-1865, 2017.
+[26] Hsin-Ying Lee, Hung-Yu Tseng, Jia-Bin Huang, Maneesh Singh, and Ming-Hsuan Yang. Diverse image-to-image translation via disentangled representations. In Proceedings of the European Conference on Computer Vision, pages 35-51, 2018.
+[27] Minjun Li, Haozhi Huang, Lin Ma, Wei Liu, Tong Zhang, and Yugang Jiang. Unsupervised image-to-image translation with stacked cycle-consistent adversarial networks. In Proceedings of the European Conference on Computer Vision, pages 184-199, 2018.
+[28] Alexander H Liu, Yen-Cheng Liu, Yu-Ying Yeh, and Yu-Chiang Frank Wang. A unified feature disentangler for multi-domain image translation and manipulation. Advances in Neural Information Processing Systems, 31, 2018.
+[29] Ming-Yu Liu, Thomas Breuel, and Jan Kautz. Unsupervised image-to-image translation networks. Advances in Neural Information Processing Systems, 30, 2017.
+[30] Xihui Liu, Dong Huk Park, Samaneh Azadi, Gong Zhang, Arman Chopikyan, Yuxiao Hu, Humphrey Shi, Anna Rohrbach, and Trevor Darrell. More control for free! image synthesis with semantic diffusion guidance. arXiv preprint arXiv:2112.05744, 2021.
+[31] Cheng Lu, Yuhao Zhou, Fan Bao, Jianfei Chen, Chongxuan Li, and Jun Zhu. Dpm-solver: A fast ode solver for diffusion probabilistic model sampling in around 10 steps. arXiv preprint arXiv:2206.00927, 2022.
+[32] Chenlin Meng, Yutong He, Yang Song, Jiaming Song, Jiajun Wu, Jun-Yan Zhu, and Stefano Ermon. Sdedit: Guided image synthesis and editing with stochastic differential equations. In International Conference on Learning Representations, 2021.
+[33] Alex Nichol, Prafulla Dhariwal, Aditya Ramesh, Pranav Shyam, Pamela Mishkin, Bob McGrew, Ilya Sutskever, and Mark Chen. Glide: Towards photorealistic image generation and editing with text-guided diffusion models. arXiv preprint arXiv:2112.10741, 2021.
+[34] Alexander Quinn Nichol and Prafulla Dhariwal. Improved denoising diffusion probabilistic models. In International Conference on Machine Learning, pages 8162-8171, 2021.
+
+[35] Yingxue Pang, Jianxin Lin, Tao Qin, and Zhibo Chen. Image-to-image translation: Methods and applications. IEEE Transactions on Multimedia, 2021.
+[36] Taesung Park, Alexei A Efros, Richard Zhang, and Jun-Yan Zhu. Contrastive learning for unpaired image-to-image translation. In Proceedings of the European Conference on Computer Vision, pages 319-345, 2020.
+[37] Taesung Park, Ming-Yu Liu, Ting-Chun Wang, and Jun-Yan Zhu. Semantic image synthesis with spatially-adaptive normalization. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 2337-2346, 2019.
+[38] Taesung Park, Jun-Yan Zhu, Oliver Wang, Jingwan Lu, Eli Shechtman, Alexei Efros, and Richard Zhang. Swapping autoencoder for deep image manipulation. Advances in Neural Information Processing Systems, 33:7198-7211, 2020.
+[39] Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, et al. Learning transferable visual models from natural language supervision. In International Conference on Machine Learning, pages 8748-8763, 2021.
+[40] Chitwan Sahara, William Chan, Huiwen Chang, Chris Lee, Jonathan Ho, Tim Salimans, David Fleet, and Mohammad Norouzi. Palette: Image-to-image diffusion models. In ACM SIGGRAPH, pages 1-10, 2022.
+[41] Chitwan Sahara, Jonathan Ho, William Chan, Tim Salimans, David J Fleet, and Mohammad Norouzi. Image super-resolution via iterative refinement. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2022.
+[42] Eduardo Hugo Sanchez, Mathieu Serrurier, and Mathias Ortner. Learning disentangled representations via mutual information estimation. In Proceedings of the European Conference on Computer Vision, pages 205-221, 2020.
+[43] Hiroshi Sasaki, Chris G Willcocks, and Toby P Breckon. Unit-ddpm: Unpaired image translation with denoising diffusion probabilistic models. arXiv preprint arXiv:2104.05358, 2021.
+[44] Zhiqiang Shen, Mingyang Huang, Jianping Shi, Xiangyang Xue, and Thomas S Huang. Towards instance-level image-to-image translation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 3683-3692, 2019.
+[45] Assaf Shocher. Resizeright. https://github.com/assafshocher/ResizeRight, 2018.
+[46] Jascha Sohl-Dickstein, Eric Weiss, Niru Maheswaranathan, and Surya Ganguli. Deep unsupervised learning using nonequilibrium thermodynamics. In International Conference on Machine Learning, pages 2256-2265, 2015.
+[47] Yang Song, Conor Durkan, Iain Murray, and Stefano Ermon. Maximum likelihood training of score-based diffusion models. Advances in Neural Information Processing Systems, 34, 2021.
+[48] Yang Song and Stefano Ermon. Generative modeling by estimating gradients of the data distribution. Advances in Neural Information Processing Systems, 32, 2019.
+[49] Yang Song, Jascha Sohl-Dickstein, Diederik P Kingma, Abhishek Kumar, Stefano Ermon, and Ben Poole. Score-based generative modeling through stochastic differential equations. In International Conference on Learning Representations, 2020.
+[50] Hao Tang, Dan Xu, Nicu Sebe, Yanzhi Wang, Jason J Corso, and Yan Yan. Multi-channel attention selection gan with cascaded semantic guidance for cross-view image translation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 2417-2426, 2019.
+[51] Ting-Chun Wang, Ming-Yu Liu, Jun-Yan Zhu, Andrew Tao, Jan Kautz, and Bryan Catanzaro. High-resolution image synthesis and semantic manipulation with conditional gans. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 8798-8807, 2018.
+
+[52] Zhou Wang, Alan C Bovik, Hamid R Sheikh, and Eero P Simoncelli. Image quality assessment: from error visibility to structural similarity. IEEE Transactions on Image Processing, 13(4):600-612, 2004.
+[53] Wayne Wu, Kaidi Cao, Cheng Li, Chen Qian, and Chen Change Loy. Transgaga: Geometry-aware unsupervised image-to-image translation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 8012-8021, 2019.
+[54] Zili Yi, Hao Zhang, Ping Tan, and Minglun Gong. Dualgan: Unsupervised dual learning for image-to-image translation. In Proceedings of the IEEE International Conference on Computer Vision, pages 2849-2857, 2017.
+[55] Pan Zhang, Bo Zhang, Dong Chen, Lu Yuan, and Fang Wen. Cross-domain correspondence learning for exemplar-based image translation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 5143-5153, 2020.
+[56] Yihao Zhao, Ruihai Wu, and Hao Dong. Unpaired image-to-image translation using adversarial consistency loss. In Proceedings of the European Conference on Computer Vision, pages 800-815, 2020.
+[57] Chuanxia Zheng, Tat-Jen Cham, and Jianfei Cai. The spatially-correlative loss for various image translation tasks. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 16407-16417, 2021.
+[58] Wanfeng Zheng, Qiang Li, Guoxin Zhang, Pengfei Wan, and Zhongyuan Wang. Ittr: Unpaired image-to-image translation with transformers. arXiv preprint arXiv:2203.16015, 2022.
+[59] Xingran Zhou, Bo Zhang, Ting Zhang, Pan Zhang, Jianmin Bao, Dong Chen, Zhongfei Zhang, and Fang Wen. Cocosnet v2: Full-resolution correspondence learning for image translation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 11465-11475, 2021.
+[60] Jun-Yan Zhu, Taesung Park, Phillip Isola, and Alexei A Efros. Unpaired image-to-image translation using cycle-consistent adversarial networks. In Proceedings of the IEEE International Conference on Computer Vision, pages 2223-2232, 2017.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See Section 6.
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] See Section 6.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes] See Appendix A.1
+(b) Did you include complete proofs of all theoretical results? [Yes] See Appendix A.4
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] See Section 5 and Appendix B
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Appendix B and Appendix C
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] See Table 1
+
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Appendix B
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] See Section 5 and Appendix B
+(b) Did you mention the license of the assets? [Yes] See Appendix B
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] See Appendix B
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A] We use the public datasets.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A] We use the public datasets.
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/images.zip b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..4c1dd6d3d7675450efede32cbad13992816f31dc
--- /dev/null
+++ b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5dc150759deadf1faa955313e018dc86d9fcae8355169f64295a6df06793a183
+size 769612
diff --git a/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/layout.json b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..e4766548cb421dd09cee394d4f41e7e4376e1003
--- /dev/null
+++ b/egsdeunpairedimagetoimagetranslationviaenergyguidedstochasticdifferentialequations/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8b545f7f96a8ff2b79e3eb51c400f6e05c310fa53a2789db58af65b0e6046fde
+size 525172
diff --git a/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/9e135c98-6f63-4a52-be7d-0e7c9d523d41_content_list.json b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/9e135c98-6f63-4a52-be7d-0e7c9d523d41_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..4c83426b6fdf607b7a644b9b76bfef5c6be9e0fe
--- /dev/null
+++ b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/9e135c98-6f63-4a52-be7d-0e7c9d523d41_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6e91ce43c0444811c725a3b9dcf688184bf2e3c7f9316301cb3dcb77e1778d04
+size 73907
diff --git a/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/9e135c98-6f63-4a52-be7d-0e7c9d523d41_model.json b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/9e135c98-6f63-4a52-be7d-0e7c9d523d41_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..0279d7367c634f79e8c96a79b117d8f91b9f3272
--- /dev/null
+++ b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/9e135c98-6f63-4a52-be7d-0e7c9d523d41_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a570f0e7bb12f29dfa0dabc1cc5b50704da20684a10336191c9f89b17481f729
+size 90379
diff --git a/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/9e135c98-6f63-4a52-be7d-0e7c9d523d41_origin.pdf b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/9e135c98-6f63-4a52-be7d-0e7c9d523d41_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..1c8432365d85ad1ef938283950514172cb802422
--- /dev/null
+++ b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/9e135c98-6f63-4a52-be7d-0e7c9d523d41_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d8b52190201d587208015b58890a4e14e58f6c7932121bc25c449629d82febab
+size 607802
diff --git a/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/full.md b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..bd8b7d29451158b653b3c57624f758ebf9f6d96b
--- /dev/null
+++ b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/full.md
@@ -0,0 +1,223 @@
+# EHRSQL: A Practical Text-to-SQL Benchmark for Electronic Health Records
+
+Gyubok Lee $^{1}$ , Hyeonji Hwang $^{1}$ , Seongsu Bae $^{1}$ , Yeonsu Kwon $^{2}$ , Woncheol Shin $^{1}$ , Seongjun Yang $^{1}$ , Minjoon Seo $^{1}$ , Jongyeup Kim†, Edward Choi $^{1}$
+KAIST, Daejeon $^{1}$ Seoul Women's University, Seoul $^{2}$
+College of Medicine, Konyang University, Daejeon†
+{gyubok.lee, localh, seongsu, swc1905, seong junyang, minjoon, edwardchoi}@kaist.ac.kr $^{1}$
+dustn1259@swu.ac.kr $^{2}$ , jykim@kyuh.ac.kr†
+
+# Abstract
+
+We present a new text-to-SQL dataset for electronic health records (EHRs). The utterances were collected from 222 hospital staff, including physicians, nurses, insurance review and health records teams, and more. To construct the QA dataset on structured EHR data, we conducted a poll at a university hospital and templatized the responses to create seed questions. Then, we manually linked them to two open-source EHR databases—MIMIC-III and eICU—and included them with various time expressions and held-out unanswerable questions in the dataset, which were all collected from the poll. Our dataset poses a unique set of challenges: the model needs to 1) generate SQL queries that reflect a wide range of needs in the hospital, including simple retrieval and complex operations such as calculating survival rate, 2) understand various time expressions to answer time-sensitive questions in healthcare, and 3) distinguish whether a given question is answerable or unanswerable based on the prediction confidence. We believe our dataset, EHRSQL, could serve as a practical benchmark to develop and assess QA models on structured EHR data and take one step further towards bridging the gap between text-to-SQL research and its real-life deployment in healthcare. EHRSQL is available at https://github.com/glee4810/EHRSQL.
+
+# 1 Introduction
+
+Electronic health records (EHRs) are relational databases that store a patient's entire medical history in the hospital. From hospital admission to patient treatment and discharge, all medical events that happened in the hospital are recorded and stored in the EHR. The records cover a wide range of clinical knowledge, from individual-level information to group-level insight, in various forms, including tables, text, and images [16, 17, 11, 15]. As a vast and comprehensive knowledge base, hospital staff, including physicians, nurses, and administrators, constantly interact with EHRs to store and retrieve patient information to make better clinical decisions [32, 3].
+
+Meanwhile, most hospital staff interact with the EHR database using pre-defined rule conversion systems. To look for information beyond the rules, one needs to undergo special training to modify and extend the system [32]. As a result, it is a massive bottleneck for the users to fully utilize the information stored in the EHR. An alternative way to tackle this problem is to build a system that can automatically translate questions directly into the corresponding SQL queries. Then, the users can simply type or verbally ask their questions to the system, and it will return the answers without going through any complicated process. Such systems will unleash the potential of EHR data and tremendously speed up any task involving data retrieval from the database.
+
+Existing datasets that tackle question answering (QA) over structured EHR data are MIMICSQL [32] and emrKBQA [27]. MIMICSQL is the first dataset for healthcare QA on MIMIC-III [16], where the questions are automatically generated with pre-defined templates. emrKBQA is another dataset on MIMIC-III derived from emrQA [23], a clinical reading comprehension dataset. However, through a poll at a university hospital, we discover that the existing datasets are far from fulfilling the actual needs in the hospital workplace in several aspects.
+
+We present EHRSQL1, a new large-scale text-to-SQL dataset linked to two open-source EHR databases—MIMIC-III [16] and eICU [25]. To the best of our knowledge, our work is the first EHR QA dataset that reflects the diverse needs of hospital staff while introducing practical issues in deploying healthcare QA systems. The unique challenges posed by our dataset are threefold:
+
+- Wide range of questions: We conducted a poll at a university hospital to collect questions frequently asked on structured EHR data. The total number of respondents was 222 people with varying years of experience in their professions (see Figure 1). After filtering and templating the responses, the resulting templates cover a wide range of questions, including retrieving patient records (e.g., vital signs measured and hospital cost) and conducting complex group-level operations (e.g., retrieving the top N medications prescribed after being diagnosed with a disease and calculating the N-year survival rate). See Table 1 for more examples.
+- Time-sensitive questions: Based on the poll, we learned that real-world questions in the hospital workplace are rich in time expressions, as time is one of the most crucial aspects of healthcare. To reflect this in the dataset, we systematically categorized time into multiple expression types (e.g., absolute, relative, and mixed), units (e.g., hospital visit, month, and day), and interval types (e.g., since, until, and in). Then, we combined the categorized time with the question templates to simulate time-sensitive questions asked in the hospital. More details are discussed in Section 3.1.2.
+- Trustworthy QA systems: Developing trustworthy systems is crucial for the adoption of AI in healthcare. Likewise, QA systems need to return only accurate answers and refuse to answer questions beyond their capabilities. To test this, we include unanswerable questions in the dataset, utilizing the remaining utterances from the poll result. These utterances are unanswerable due to incompatibility with the database schema or requiring external domain knowledge.
+
+# 2 Related Works
+
+EHR QA Pampari et al. [23] proposed emrQA for question answering on clinical notes based on physicians' frequently asked questions. Later, Raghavan et al. [27] proposed emrKBQA², which adapted emrQA to structured patient records in MIMIC-III. Due to the nature of the original dataset targeting outpatients, the scope of the questions in emrKBQA is limited to mostly asking about patients' test results [27]. Recently, Wang et al. [32] proposed MIMICSQL, which first tackles EHR QA with the text-to-SQL generation task. To construct the dataset, they automatically generated questions based on pre-defined rules and filtered them through crowd-sourcing. However, MIMICSQL contains a limited scope of questions and simple SQL queries restricted to five tables, which are far from the actual use case in the hospital [24]. EHRSQL, on the other hand, originates from the actual poll result and covers a variety of real-world questions (spanning 13.5 tables on average) frequently asked on structured EHR data (see Table 1).
+
+Semantic parsing datasets Semantic parsing has been one of the most active areas of research in natural language processing over the past few decades [13, 37, 34, 9]. It involves converting natural language utterances to logical form representations, which are often executable programs such as Python scripts and SQL queries. WikiSQL [40] and Spider [35] are leading datasets that assess semantic parsing models on unseen databases. WikiSQL provides a wide range of database domains extracted from HTML tables in Wikipedia, but it only contains simple SQL queries and single tables. Spider aims to tackle complex queries, including joining and set operations, on multiple tables in multiple database domains. Recently, more realistic datasets have been proposed to bridge the gap between academic and practical settings in semantic parsing. KaggleDBQA [19] utilizes real-world databases from Kaggle and constructs domain-specific questions without relying on the database
+
+Table 1: Sample utterances in EHRSQL (SQL queries are labeled differently according to the MIMIC-III and eICU schemas).
+
+ | Type | Sample question | Department |
| Question diversity | Demographics | Tell me the birthdate of patient 92721? | Nursing |
| Prescription | When was the first prescription time of patient 20000? | Nursing |
| Vital sign | What was the last arterial bp [systolic] for patient 23042? | Physician, Nursing, Health records, Other |
| Cost | What is the average total hospital cost that involves non-invasive mech vent? | Insurance review |
| Survival rate | What is the five diagnoses which have the lowest four year survival rate? | Nursing |
| Longitudinal statistics | What are the five most commonly prescribed drugs for patients who have been diagnosed with hypotension nos earlier since 2104 within 2 months? | Physician, Nursing |
| Time-sensitive question | Absolute | Is the heart rate of patient 2518 measured at 2105-12-31 12:00:00 less than the value measured at 2105-12-31 09:00:00? | Physician |
| Tell me the last specimen test given to patient 51177 in 10/2105? | Nursing |
| Relative | Tell me patient 6990's daily average gastric meds intake on the last ICU visit. | - |
| Mixed | Tell me the medication that patient 3929 has been prescribed for the first time in 05 this year. | Nursing |
| Unanswerable question | Requiring external knowledge | What is the name of the medication which should not be administered during the contrast arteriogram-leg treatment? | Nursing |
| Beyond DB schema | When is the next earliest hospital visit of patient 73652? | Nursing |
+
+schema. SEDE [12] deals with complex SQL queries that Stack Exchange users ask in real life. Our motivation aligns with theirs in that additional challenges arise in real-world healthcare QA systems.
+
+Unanswerable questions in QA In the early days of question answering, unanswerable questions were generated via distant supervision [18, 4], rule-based editing [14], or adversarial creation by crowd workers [28]. Yet, in semantic parsing, most works assume that all input questions are valid and can be answered; however, this is not true in practice [38]. Retrieving answers to all the input questions is not always desirable for the model to ensure system reliability. To address this, Zhang et al. [38] utilized other text-to-SQL and chit-chat datasets to construct unanswerable questions and posed the problem as a classification task to detect unanswerable questions. Our work, on the other hand, addresses both system reliability and semantic parsing simultaneously and the unanswerable questions are naturally collected through the poll. In task-oriented dialog systems, the same task has been tackled in the name of Out-of-Domain (OOD) detection, and several recent works approach this problem without explicitly showing OOD samples to the model during training for practical reasons. Following their setup, our unanswerable questions are only included in the validation and test sets.
+
+# 3 Dataset Construction
+
+Data collection The motivation behind our work is to construct a dataset that reflects the actual needs of hospital staff and tackles several practical issues that can arise in real-world healthcare QA systems (see Table 1). To this end, we collaborated with the Konyang University Hospital3 and conducted a poll to collect real-world questions as if one is asking an AI speaker what they frequently look for in structured information in the EHR. In addition, to clarify what machines can and cannot answer, we provided typical negative examples of what should not be asked, such as requiring external knowledge, ambiguous or qualitative statements, or asking for reasons behind clinical decisions. As a result, we gathered a total of 1,742 utterances, and the number of valid respondents was 222 (see Figure 1 for respondent demographics).
+
+# 3.1 Question and SQL Generation
+
+# 3.1.1 Question template
+
+After the poll, we filtered out the utterances that did not meet the criteria, including ambiguous statements, those that require external knowledge, or those that go beyond the database schema. We
+
+
+Figure 1: Demographics of the 222 respondents by hospital departments and the years of experience.
+
+
+Figure 2: EHR schema is structured in a hierarchy, and real-world questions often require multi-step reasoning over tables.
+
+then categorized the utterances into three patient-based scopes: a single patient, a group of patients, and no patient. For each scope, duplicate utterances, but differently phrased, were merged into a single question template. We also manually added question templates that were simple variants of existing templates. For example, we modified the type of medical events (e.g., lab test, prescription, etc.) in question templates, such as from "Count the number of times that a patient had a lab test" to "Count the number of times that a patient received a prescription." To cover more questions on longitudinal statistics, we linked two different medical events together whenever possible. For example, the question "What are the top N prescriptions after a diagnosis," which was originally collected, is extended to "What are the top N lab tests after a diagnosis." Finally, the filtered-out utterances were also automatized and considered unanswerable. The unanswerable questions included side effects, next check-up schedules, primary care doctor, patient's personal information, whether a patient has signed a consent form, diagnosis received in other departments, and more.
+
+Table 2: Sample question templates. The full list is reported in Supplementary B.1.
+
+| Patient scope | Question template |
| None | What is the intake method of {drug_name}? |
| Individual | Has patient {patient_id} received any procedure [time_filter_global]? |
| Group | Count the number of hospital visits of patient {patient_id} [time_filter_global]. |
| What are the top [n_rank] frequent procedures that patients received [time_filter_within] after having been diagnosed with {diagnosis_name} [time_filter_global]? |
| Unanswerable | What is the effect of {drug_name}? |
+
+The resulting question templates are natural utterances with slots that are later filled with pre-defined values or database records (see Table 2). Slots containing "time_filter" are processed in the time template sampling stage, described in Section 3.1.2. We eliminate any ambiguity in the question templates that could cause the model to infer table or column names incorrectly. For example, "When did this patient get [slot] today?" is removed because it does not tell us whether we are interested in drugs, lab tests, or something else unless the slot is filled. Such linguistic ambiguity is later introduced in the paraphrase generation stage described in Section 3.3. As a result, we curated 230 question templates (174 for answerable and 56 for unanswerable) based on the MIMIC-III and eICU schemas. For answerable questions, their corresponding SQL queries were labeled for each database, which is further discussed in Section 3.1.3.
+
+# 3.1.2 Time template
+
+Since the healthcare domain is inextricably linked to time, many utterances we collected were rich in time expressions. To reflect this in the dataset, we developed three time filter types and assigned different time factors (expression types, units, and interval types) to each filter type to compose a single time template. First, we define a "global" time filter ([time_filter_global]) that
+
+constrains the full range of time we are interested in. Second, within the global time filter, we can also use a "within" time filter ([time_filter_within]) to indicate the time range between two or more medical events. Third, we can point to an exact time ([time_filter_exact]), such as "last" measurement or "at 2105-12-31 09:00:00" if we know the exact time or the order of an event.
+
+Each time filter type has three factors and an extra option: 1) Expression type is whether the filter is phrased in an absolute, relative, or mixed time expression (e.g., last year, in 2022, etc.); 2) Unit is the granularity of time, such as a standardized unit (e.g., year, month, day, etc.) or an arbitrary unit of events (e.g., hospital visit, ICU visit); 3) Interval type specifies the type of time interval (e.g., since, until, in, etc.). Depending on the use case, Option allows to choose one exact event (e.g., first, last) among the filtered events. Table 3 shows sample time templates and their natural language (NL) time expressions. It is important to note that each time template has its corresponding NL time expression (e.g., since {month}/{day}/{year}) and SQL time pattern (e.g., WHERE北京时间('%Y-%m-%d', [time_column]) >= {'year}-{month}-{day}'), while the question templates are originally created in natural language. The NL time expressions are combined with the question templates to form complete questions. The SQL time patterns are combined with the labeled SQL queries to form complete SQL queries (see Section 3.1.4 for details). The full list of time templates (NL and SQL pairs) is reported in Supplementary B.2.
+
+Table 3: Sample time templates and their NL time expressions.
+
+| Time filter type | Expression type | Unit | Interval type | Option | Time template | NL time expression |
| [time_filter_global] | absolute | day | since | - | abs-day-since | since {month}/{day}/{year} |
| relative | year | in | last | rel-year-last | last year |
| this | rel-year-this | this year |
| [time_filter_within] | - | hospital | in | - | within-hosp | within the same hospital visit |
| - | day | in | - | within-day | within the same day |
| [time_filter_exact] | relative | exact | at | - | exact-first | first |
+
+# 3.1.3 SQL annotation
+
+The SQL annotation process was conducted manually by four graduate students over the course of five months, with repeated revisions. Since the questions were collected independently of the database schema, SQL labeling required numerous assumptions (e.g., which medical event is mapped to which column in the database, the choice of rank functions in SQL, the occasion of using DISTINCT, etc.). To sync template and value sampling, the same slots introduced in Section 3.1.1 and 3.1.2 (e.g., {drug_name}, [n_rank], [time_filter_global]) were also used in SQL labeling as placeholders. The SQL queries for question and time templates were labeled by one person, followed by a reviewer for each database. Unlike most SQL datasets, the students were asked to avoid using JOIN, which is a go-to operation when retrieving information across multiple tables. In MIMIC-III and eICU, several tables contain more than 100 million rows (e.g., 330 million rows in MIMIC-III chartevents) as the records are stored in a "log" based manner. In fact, it is extremely inefficient to merge all the tables in such large databases without understanding what specific columns are needed to answer a question. As a result, the students were asked to utilize the hierarchical structure of the EHR schema, as illustrated in Figure 2, and labeled each query in a nested manner whenever possible. SQL annotation details and the comparison between JOIN and nesting-based queries are discussed in Supplementary C.
+
+# 3.1.4 Template combination and data generation
+
+Data generation starts by selecting a question template, followed by three sampling stages that add semantic variety: operation value sampling, time template sampling, and condition value sampling (See Figure 3). Stage 1 involves sampling operation values from pre-defined values that are independent of the database schema or records (e.g., maximum, five-year, two or more times, etc.). Then, time templates are sampled in Stage 2 based on the time filter types that each question template can have. Stage 2 in Figure 3 illustrates that the time templates ([time_filter_global] and [time_filter_within]) have already been sampled and converted into NL time expressions. More details are discussed in Supplementary B.3. Finally, condition value sampling (e.g., {diagnosis_name}, {year}) occurs in Stage 3, and the slot filling process is complete. This
+
+
+Figure 3: Question generation process. The shaded region refers to the expansion of semantic diversity in the template pool.
+
+final stage is where the actual database records are sampled, and all generated SQL queries are checked to have at least one valid answer. Once the query is successfully executed, the pair of SQL and the corresponding question is added to the data pool, which is later used for data splitting.
+
+# 3.2 Database Pre-processing
+
+Cost table We modified the original MIMIC-III and eICU databases to include a cost table in order to reflect hospital administration and insurance-related questions. When constructing the table, we referred to the OMOP Common Data Model4 to create new column names, which include: patient_id, hospital_admission_id, event_type (cost_domain_id), event_id (cost_event_id), chargetime, and cost. For cost sampling, we take a two-step sampling procedure to simulate cost values. First, we sampled discrete-valued mean costs for four different medical event types (diagnosis, procedure, prescription, and lab events) from a Poisson distribution with a mean of 10. Then, we sampled continuous-valued costs from Gaussian distributions with their corresponding means.
+
+Time shifting The time span of MIMIC-III is over a hundred years due to the de-identification process (originally seven years), while eICU's time span remains intact (two years). To simulate a more realistic time span asked in the hospital and match the time across the databases, we shifted the admission time of every patient's records ranging from 2100 to 2105. In addition, to incorporate the concept of current and the use of relative time expressions, we set the current time to be "2105-12-31 23:59:00" and removed any record past the current time. In this way, patients with missing hospital discharge time are considered current patients. The poll result revealed that many time expressions used in the hospital are relative time expressions (e.g., today, yesterday, last month, etc.), and therefore this process was necessary to reflect time-sensitive questions. More details are reported in Supplementary D.2.
+
+De-identification MIMIC-III and eICU databases are de-identified datasets, and a user needs to request credentialed access to PhysioNet5 to obtain them. Both datasets, however, do contain real patient records, and the questions derived from them could potentially reveal patient-specific information. For example, the question "What medication was given to patient ID 1234 after being diagnosed with diabetes?" implies that this patient was diagnosed with diabetes. Combined with some unforeseen external knowledge, this might lead to recovering the patient's identity. To add another layer of de-identification, we randomly shuffled values across all patients in the database before sampling condition values. In this way, the semantic structure of the question remains the same, but sampled condition values are untraceable. More details of the de-identification process are reported in Supplementary D.3.
+
+Table 4: The comparison between EHRSQL and other text-to-SQL datasets. # Nesting/Q is the average number of nesting levels per query. % Time Used/Q is the percentage of at least one time column used in queries. ?Schema is whether the question authors are unaware of the database schema when they first come up with their question. UnANS indicates whether the dataset contains unanswerable questions.
+
+| Dataset | # Example | # DB | # Table/DB | # Row/Table | # Table/Q | # Nesting/Q | % Time Used/Q | ?Schema | UnANS |
| Spider† | 8K | 160 | 5.1 | 2K | 1.6 | 1.2 | 12.7% | X | X |
| KaggleDBQA | 0.3K | 8 | 2.3 | 280K | 1.2 | 1.0 | 17.3% | X | X |
| SEDE | 12K | 1 | 29 | - | 1.8 | 1.3 | 20.2% | X | X |
| MIMICSQL | 10K | 1 | 5 | 7K | 1.8 | 1.0 | 26.6% | X | X |
| emrKBQA‡ | 940K | 1 | 9 | - | - | - | - | ✓ | X |
| EHRSQL | 24K | 2 | 13.5 | 108K | 2.4 | 2.7 | 93.2% | ✓ | ✓ |
+
+†Train and validation sets are counted. ‡The dataset is yet to be publicly released.
+
+# 3.3 Paraphrase Generation
+
+To add linguistic variety to the questions, we generated template paraphrases from the question templates with manual paraphrasing and the help of machine learning models. Before paraphrasing, we ensure that the templates do not contain any domain-specific expressions, creating the paraphrasing process departing from the healthcare domain to leverage general-domain tools. The overall procedure is as follows:
+
+1. Human paraphrasing is first conducted to add more high-quality templates, averaging 21 paraphrases per question template.
+2. Based on the human paraphrases, more paraphrases are generated using machine learning models, such as T5 paraphraseers [6, 5, 1] and multilingual translation models for back-translation [8, 31].
+3. The paraphrases that are too different from the original meaning are filtered using a duplicate question detection model, specifically RoBERTa-large [20] trained on the Quora duplicate question detection dataset.
+4. The paraphrases are ranked by the perplexity score from GPT-Neo 1.3B [10] per question template and disregarded if they are too similar to the other paraphrases with lower perplexity. The Levenshtein distance is used to detect lexical similarity.
+5. The final paraphrases are reviewed by crowd workers to rate the quality of the paraphrases. In our case, we collaborated with a crowd-sourcing company named Selectstar6. Three groups of annotators were assigned to this task and marked a pass or fail for each paraphrase sample. The samples with unanimous pass marks were considered the final machine-paraphrased templates, leaving 47 paraphrases per template on average.
+
+During the paraphrasing process, slots are replaced with generic values (e.g., {patient_id} → the patient) and returned to the original slots after the process is complete. Later, those slots are filled with the actual condition values in the value sampling process to construct the final question-to-SQL pairs. The overview of the paraphrase pipeline is illustrated in Supplementary E.
+
+# 3.4 EHRSQL and Other Datasets
+
+Table 4 summarizes the statistics of EHRSQL and other text-to-SQL datasets in the literature. Compared to general domain datasets (first three rows), EHRSQL has a large number of text-to-SQL pairs (# Example), tables per database (# Table/DB), and rows per table (# Row/Table). KaggleDBQA [19] and SEDE [12] are designed to bridge the gap between academic datasets and practical usability by using real databases and naturally-occurring utterances. However, we have gone one step further where the question authors (the poll respondents) were not presented with the database schema (?Schema), which adds more reality to the dataset [12]. Finally, EHRSQL contains unanswerable questions (UnANS) that were collected together from the poll, which may play a critical role in assessing the reliability of the QA model. To the best of our knowledge, EHRSQL is the first attempt to combine answerable and unanswerable questions in the context of text-to-SQL.
+
+From a healthcare perspective, EHRSQL covers a variety of questions frequently asked in the hospital. The scope of these questions ranges from non-patient information (e.g., the cost of a procedure) to
+
+
+Figure 4: Overview of trustworthy semantic parsing.
+
+individual-level information (e.g., retrieving patient demographics and the lab values) and group-level information (e.g., counting the number of patients in the hospital and the top N frequently prescribed drugs of patients over 60s), further combined with various time expressions (% Time Used/Q). The SQL queries are linked to two EHR databases: MIMIC-III and eICU, and this is the first attempt to label SQL queries on eICU, allowing questions about multi-center critical care to be answered.
+
+# 4 Benchmarks
+
+# 4.1 Task
+
+In this section, we define a new text-to-SQL task that assesses models under more realistic healthcare QA settings than prior works—namely, trustworthy semantic parsing. As illustrated in Figure 4, the trustworthy model needs to 1) generate SQL queries that reflect a wide range of needs in the hospital workplace, 2) understand various time expressions to answer time-sensitive questions in healthcare, and 3) have the capacity to distinguish whether a given question is answerable or unanswerable based on the prediction confidence. Among various ways to calculate the confidence score, we argue that a desirable way to calculate it is not based on the data the model is trained on, but on the model prediction itself. As illustrated in Figure 4, once a confidence score exceeds some threshold of choice (assuming that a greater score means less confidence), the generated SQL should not be sent to the database.
+
+To make the task feasible, we keep the condition values (e.g., prescription name) the same in this work, except for genders and vital signs, as this is another major challenge in semantic parsing [30, 29]. When splitting the dataset into train, validation, and test sets, we ensure that all the question templates are present in each split. To create a more realistic QA setting, we include unanswerable questions only in the validation and test sets (consisting of $33\%$ of each split), following the OOD detection setting [22, 39]. Among 24,411 question pairs in the dataset, the train, valid, and test splits contain 9.3K, 1.1K, and 1.8K pairs, respectively, for each database. We release the train and valid splits, totaling 21K samples, and the other 3K samples are saved for a hidden test set. Details of data splitting are reported in Supplementary F.
+
+# 4.2 Evaluation
+
+The goal of the trustworthy semantic parsing task is to correctly return the answers to answerable questions while disregarding unanswerable questions. This process can be evaluated in two aspects. The model first needs to have a strategy that distinguishes whether a given question is answerable or unanswerable. Given that the goal is to correctly recognize as many answerable questions as possible, the model's performance can be measured in precision and recall. In this case, the precision $(\mathrm{P}_{ans})$ calculates the number of correctly recognized answerable questions among all questions predicted to be answerable, while recall $(\mathrm{R}_{ans})$ calculates the number of correctly recognized answerable questions among all answerable questions. We use $\mathrm{F1}_{ans}$ to combine these two scores.
+
+Table 5: Performance on MIMIC-III (Left) and eICU (Right).
+
+| Model | Valid | Test | Model | Valid | Test |
| F1ans | Pexe | Rexe | F1exe | F1ans | Pexe | Rexe | F1exe | F1ans | Pexe | Rexe | F1exe | F1ans | Pexe | Rexe | F1exe |
| Threshold: None | Threshold: None |
| T5 | 80.8 | 65.2 | 96.2 | 77.7 | 80.3 | 64.0 | 95.4 | 76.6 | T5 | 80.7 | 65.2 | 96.4 | 77.8 | 80.4 | 64.0 | 95.2 | 76.5 |
| T5 + Schema | 80.8 | 65.3 | 96.4 | 77.9 | 80.3 | 64.0 | 95.3 | 76.6 | T5 + Schema | 80.7 | 64.4 | 95.2 | 76.8 | 80.4 | 64.1 | 95.4 | 76.7 |
| Threshold: Clustering-based | Threshold: Clustering-based |
| T5 | 93.1 | 89.3 | 94.5 | 91.8 | 90.1 | 83.6 | 93.1 | 88.1 | T5 | 92.4 | 89.4 | 92.8 | 91.1 | 89.5 | 82.1 | 93.2 | 87.3 |
| T5 + Schema | 92.2 | 86.7 | 95.0 | 90.6 | 89.8 | 82.5 | 93.8 | 87.8 | T5 + Schema | 92.7 | 86.8 | 94.0 | 90.3 | 89.5 | 79.9 | 95.0 | 86.8 |
| Threshold: Percentile-based | Threshold: Percentile-based |
| T5 | 94.8 | 94.1 | 93.2 | 93.7 | 91.4 | 88.8 | 91.1 | 89.9 | T5 | 93.0 | 92.5 | 91.7 | 92.1 | 90.8 | 87.5 | 91.6 | 89.5 |
| T5 + Schema | 93.5 | 93.0 | 92.0 | 92.5 | 90.6 | 88.4 | 89.7 | 89.1 | T5 + Schema | 94.2 | 92.5 | 91.7 | 92.1 | 90.9 | 84.8 | 93.5 | 88.9 |
+
+Next, we must evaluate how well the model generates correct SQL queries, given that some questions are considered answerable and ready to predict. The word predict here means the actions of generating a query and sending it to the database, where extra care is needed because the answer from the database may be directly used for clinical decision-making. Combining the concept of $\mathrm{F1}_{\text {ans }}$ and execution accuracy in semantic parsing, $\mathrm{F1}_{\text {exe }}$ counts only when the returned answer is correct. In other words, $\mathrm{F1}_{\text {exe }}$ is a combined score of $\mathrm{P}_{\text {exe }}$ and $\mathrm{R}_{\text {exe }}$ , where $\mathrm{P}_{\text {exe }}$ is the ratio of the number of correctly answered questions to all questions predicted to be answerable and $\mathrm{R}_{\text {exe }}$ is the ratio of the number of correctly answered questions to all answerable questions. As a result, the denominators of the precisions and recalls are the same, but the numerators are more strictly counted in metrics with $exe$ . This gap between $ans$ and $exe$ reveals the model's inability to generate correct SQL queries, given that the questions are both recognized as answerable and indeed answerable.
+
+# 4.3 Model Development
+
+Most state-of-the-art (SOTA) semantic parsing models utilize grammar-based decoders and are only compatible with the grammars (or their subsets) defined in the Spider dataset. As the queries in EHRSQL are created in response to actual needs, most of them are incompatible with the Spider parser mainly due to time-related operators like `strstr`, `datetime`, `NULL`. Therefore, we chose general-purpose sequence-to-sequence models, T5-base [26] and T5-base with schema serialization [30, 12], as baseline models for our task. This choice aligns with a recent finding that transfer learning from pre-trained language models surpasses healthcare-specific text-to-SQL models [2]. Training details are reported in Supplementary G.
+
+To give a model the ability to refuse to answer questions, we adopt a simple uncertainty estimation method inspired by [21, 33]. If the maximum entropy during the decoding process exceeds a predefined threshold, we consider this a refusal. The threshold values are determined by two heuristic approaches, and they are compared with the result obtained without refusal.
+
+1. Clustering-based: Run K-means clustering with $k = 2$ on all maximum entropy values of validation samples, assuming that high-entropy samples are from unanswerable questions. The decision boundary between the two clusters is then used as the threshold.
+2. Percentile-based: Set the threshold to the 67th percentile of the maximum entropy values of the validation samples, based on the fact that $33\%$ of the questions in the validation set are unanswerable.
+
+To illustrate the domain gap between general-domain and healthcare datasets, we create a subset of EHRSQL that could be parsed with the Spider parser. Then, we compare how well the SOTA cross-domain semantic parsing models generalize to healthcare text-to-SQL datasets. We choose MIMICSQL, which contains simple SQL queries that can all be parsed with the Spider grammar, and EHRSQL for the healthcare datasets. Among many SOTA models in the Spider leaderboard, we use Generation-Augmented Pre-training (GAP) [29] to test its zero-shot domain transfer performance.
+
+# 4.4 Results and Findings
+
+The baseline results are reported in Table 5. Among the three different threshold approaches, the percentile-based threshold performs best on both the validation and test sets. This result is an expected outcome because the ratios of the answerable and unanswerable questions in the validation and test sets are kept the same in our setting. As for the clustering-based method, an additional training or
+
+Table 6: Performance of zero-shot cross-domain transfer with GAP in execution accuracy. Easy, medium, hard, and extra refer to Spider's SQL hardness criteria. The numbers in parenthesis indicate the number of correct cases divided by the number of answerable queries. All experiments are done on answerable questions in the validation set.
+
+| Dataset | Easy | Medium | Hard | Extra | Skipped | All \ Skipped |
| MIMICSQL[32] | 46.7 (79/169) | 10.5 (85/809) | 0.0 (0/22) | - | - | 16.4 (164/1000) |
| EHRSQL | 23.8 (5/21) | - | 0.0 (0/23) | 0.0 (0/63) | (0/1408) | 4.7 (5/107) |
| MIMIC-III only | 16.7 (2/12) | - | 0.0 (0/15) | 0.0 (0/30) | (0/703) | 3.5 (2/57) |
| eICU only | 3.3 (3/9) | - | 0.0 (0/8) | 0.0 (0/33) | (0/705) | 6.0 (3/50) |
+
+clustering technique is needed for the models to better discriminate the entropy values. The naive entropy values from the current models are not linearly separable across predictions (see Figure 7 in Supplementary H.4 for maximum entropy distributions). T5+Schema shows comparable performance to T5 in both databases. This result agrees with the recent finding in [12] that models trained in a single database setting do not effectively leverage schema information. Additional qualitative results are provided in Supplementary H, including SQL generation results by question complexity, time expressions, falsely executed results, and refused results.
+
+Table 6 shows the performance of zero-shot cross-domain transfer with the GAP model. Unlike the queries in MIMICSQL, which are all parsable with the Spider grammar, EHRSQL has much more complex SQL operators and structures, with only about $7\%$ (107/1,515) of the answerable questions in the validation set being parsable. As for model performance, GAP achieves $16.4\%$ in the full MIMICSQL validation set and $5.8\%$ in the subset of the validation set in EHRSQL. This result motivates again the need for a new practical text-to-SQL dataset in healthcare and QA models that can handle multiple real-world challenges in the hospital.
+
+# 5 Conclusion and Future Direction
+
+In this paper, we present EHRSQL, a new practical text-to-SQL dataset for question answering over structured information in EHRs. Through a poll conducted at a university hospital, we collected questions that are frequently asked on structured EHR data across various professions in the hospital. The questions reflect the actual needs in the hospital and different time expressions used in daily work, which are particularly crucial in healthcare. Additionally, we also collected unanswerable questions, which were the questions submitted by the respondents but turned out to be beyond the EHR schema or ambiguous. Finally, we manually labeled SQL queries for two open-source EHR databases—MIMIC-III and eICU—and cast these challenges as one task—trustworthy semantic parsing—where QA models should only answer the question when their predictions are confident but not otherwise.
+
+Though we have carefully designed the dataset, there are several limitations. First, despite more than two hundred people participating in the poll, the source of the questions is from one Korean university hospital, which may not reflect every unique situation in different hospitals worldwide. Secondly, the question templates are paraphrased using general-domain paraphrasers; therefore, paraphrases with the heavy use of medical jargon could make them more realistic. Finally, SQL labels for two EHR databases might not be a sufficient number of databases to train and test a model for unseen EHR databases.
+
+We expect numerous research directions with our dataset. The seed questions can be a valuable resource for expanding the scope of table-based healthcare QA tasks, such as creating interactive QA [36, 7] or developing it into multimodal QA datasets on EHRs. With the idea of trustworthy semantic parsing, a new class of end-to-end uncertainty-aware semantic parsing models can be proposed. As existing text-to-SQL models assume all inputs are answerable, this can be a unique venue for semantic parsing to bridge the gap between research and industrial needs.
+
+# Acknowledgments and Disclosure of Funding
+
+We would like to thank five anonymous reviewers for their time and insightful comments. We also thank Woochan Hwang for assisting us in clarifying our questions during the data labeling process. This work was supported by Institute of Information & communications Technology Planning & Evaluation (IITP) grant funded by the Korea government(MSIT) (No.2019-0-00075, Artificial Intelligence Graduate School Program(KAIST)), National Research Foundation of Korea (NRF) grant (NRF-2020H1D3A2A03100945) and Data Voucher grant (2021-DV-I-P-00114), funded by the Korea government (MSIT).
+
+# References
+
+[1] Sai Vamsi Alisetti. Paraphrase generator with t5, 2020. URL https://github.com/Vamsi995/Paraphrase-Generator.
+[2] Seongsu Bae, Daeyoung Kim, Jiho Kim, and Edward Choi. Question answering for complex electronic health records database using unified encoder-decoder architecture. In Proceedings of Machine Learning for Health, volume 158 of Proceedings of Machine Learning Research, pages 13-25. PMLR, 04 Dec 2021. URL https://proceedings.mlr.press/v158/bae21a.html.
+[3] Jayetri Bardhan, Anthony Colas, Kirk Roberts, and Daisy Zhe Wang. Drugehrqa: A question answering dataset on structured and unstructured electronic health records for medicine related queries. arXiv preprint arXiv:2205.01290, 2022.
+[4] Christopher Clark and Matt Gardner. Simple and effective multi-paragraph reading comprehension. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 845–855, Melbourne, Australia, July 2018. Association for Computational Linguistics. doi: 10.18653/v1/P18-1078. URL https://aclanthology.org/P18-1078.
+[5] Prithiviraj Damodaran. Parrot: Paraphrase generation for nlu, 2021. URL https://github.com/PrithivirajDamodaran/Parrot_PARphraser.
+[6] Prithiviraj Damodaran. Styleformer, 2021. URL https://github.com/PrithivirajDamodaran/Styleformer.
+[7] Ahmed Elghohary, Saghar Hosseini, and Ahmed Hassan Awadallah. Speak to your parser: Interactive text-to-SQL with natural language feedback. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 2065-2077, Online, July 2020. Association for Computational Linguistics. doi: 10.18653/v1/2020.acl-main.187. URL https://aclanthology.org/2020.acl-main.187.
+[8] Angela Fan, Shruti Bhosale, Holger Schwenk, Zhiyi Ma, Ahmed El-Kishky, Siddharth Goyal, Mandeep Baines, Onur Celebi, Guillaume Wenzek, Vishrav Chaudhary, et al. Beyond english-centric multilingual machine translation. Journal of Machine Learning Research, 22(107):1-48, 2021.
+[9] Catherine Finegan-Dollak, Jonathan K Kummerfeld, Li Zhang, Karthik Ramanathan, Sesh Sadasivam, Rui Zhang, and Dragomir Radev. Improving text-to-sql evaluation methodology. arXiv preprint arXiv:1806.09029, 2018.
+[10] Leo Gao, Stella Biderman, Sid Black, Laurence Golding, Travis Hoppe, Charles Foster, Jason Phang, Horace He, Anish Thite, Noa Nabeshima, et al. The pile: An 800gb dataset of diverse text for language modeling. arXiv preprint arXiv:2101.00027, 2020.
+[11] Ary L Goldberger, Luis AN Amaral, Leon Glass, Jeffrey M Hausdorff, Plamen Ch Ivanov, Roger G Mark, Joseph E Mietus, George B Moody, Chung-Kang Peng, and H Eugene Stanley. Physiobank, physiotoolkit, and physionet: components of a new research resource for complex physiologic signals. circulation, 101 (23):e215–e220, 2000.
+[12] Moshe Hazoom, Vibhor Malik, and Ben Bogin. Text-to-sql in the wild: A naturally-occurring dataset based on stack exchange data. arXiv preprint arXiv:2106.05006, 2021.
+[13] Charles T. Hemphill, John J. Godfrey, and George R. Doddington. The ATIS spoken language systems pilot corpus. In Speech and Natural Language: Proceedings of a Workshop Held at Hidden Valley, Pennsylvania, June 24-27, 1990, 1990. URL https://aclanthology.org/H90-1021.
+
+[14] Robin Jia and Percy Liang. Adversarial examples for evaluating reading comprehension systems. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 2021-2031, Copenhagen, Denmark, September 2017. Association for Computational Linguistics. doi: 10.18653/v1/D17-1215. URL https://aclanthology.org/D17-1215.
+[15] Alistair Johnson, Lucas Bulgarelli, Tom Pollard, Steven Horng, Leo Anthony Celi, and Roger Mark. Mimic-iv (version 1.0). PhysioNet, 2021. doi: https://doi.org/10.13026/s6n6-xd98.
+[16] Alistair EW Johnson, Tom J Pollard, Lu Shen, H Lehman Li-Wei, Mengling Feng, Mohammad Ghassemi, Benjamin Moody, Peter Szolovits, Leo Anthony Celi, and Roger G Mark. Mimic-iii, a freely accessible critical care database. Scientific data, 3(1):1-9, 2016.
+[17] Alistair EW Johnson, Tom J Pollard, Seth J Berkowitz, Nathaniel R Greenbaum, Matthew P Lungren, Chih-ying Deng, Roger G Mark, and Steven Horng. Mimic-cxr, a de-identified publicly available database of chest radiographs with free-text reports. Scientific data, 6(1):1–8, 2019.
+[18] Mandar Joshi, Eunsol Choi, Daniel Weld, and Luke Zettlemoyer. TriviaQA: A large scale distantly supervised challenge dataset for reading comprehension. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1601-1611, Vancouver, Canada, July 2017. Association for Computational Linguistics. doi: 10.18653/v1/P17-1147. URL https://aclanthology.org/P17-1147.
+[19] Chia-Hsuan Lee, Oleksandr Polozov, and Matthew Richardson. Kaggledbqa: Realistic evaluation of text-to-sql parsers. arXiv preprint arXiv:2106.11455, 2021.
+[20] Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692, 2019.
+[21] Andrey Malinin and Mark Gales. Uncertainty estimation in autoregressive structured prediction. arXiv preprint arXiv:2002.07650, 2020.
+[22] Petr Marek, Vishal Ishwar Naik, Vincent Auvray, and Anuj Goyal. Oodgan: Generative adversarial network for out-of-domain data generation. arXiv preprint arXiv:2104.02484, 2021.
+[23] Anusri Pampari, Preethi Raghavan, Jennifer Liang, and Jian Peng. emrqa: A large corpus for question answering on electronic medical records. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 2357-2368, 2018.
+[24] Junwoo Park, Youngwoo Cho, Haneol Lee, Jaegul Choo, and Edward Choi. Knowledge graph-based question answering with electronic health records. In Machine Learning for Healthcare Conference, pages 36-53. PMLR, 2021.
+[25] Tom J Pollard, Alistair EW Johnson, Jesse D Raffa, Leo A Celi, Roger G Mark, and Omar Badawi. The eicu collaborative research database, a freely available multi-center database for critical care research. Scientific data, 5(1):1-13, 2018.
+[26] Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J Liu. Exploring the limits of transfer learning with a unified text-to-text transformer. arXiv preprint arXiv:1910.10683, 2019.
+[27] Preethi Raghavan, Jennifer J Liang, Diwakar Mahajan, Rachita Chandra, and Peter Szolovits. emrkbq: A clinical knowledge-base question answering dataset. In Proceedings of the 20th Workshop on Biomedical Language Processing, pages 64-73, 2021.
+[28] Pranav Rajpurkar, Robin Jia, and Percy Liang. Know what you don't know: Unanswerable questions for squad. arXiv preprint arXiv:1806.03822, 2018.
+[29] Peng Shi, Patrick Ng, Zhiguo Wang, Henghui Zhu, Alexander Hanbo Li, Jun Wang, Cicero Nogueira dos Santos, and Bing Xiang. Learning contextual representations for semantic parsing with generation-augmented pre-training. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pages 13806-13814, 2021.
+[30] Alane Suhr, Ming-Wei Chang, Peter Shaw, and Kenton Lee. Exploring unexplored generalization challenges for cross-database semantic parsing. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8372–8388, 2020.
+
+[31] Yuqing Tang, Chau Tran, Xian Li, Peng-Jen Chen, Naman Goyal, Vishrav Chaudhary, Jiatao Gu, and Angela Fan. Multilingual translation with extensible multilingual pretraining and finetuning. arXiv preprint arXiv:2008.00401, 2020.
+[32] Ping Wang, Tian Shi, and Chandan K Reddy. Text-to-sql generation for question answering on electronic medical records. In Proceedings of The Web Conference 2020, pages 350-361, 2020.
+[33] Yijun Xiao and William Yang Wang. On hallucination and predictive uncertainty in conditional language generation. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 2734-2744, 2021.
+[34] Navid Yaghmazadeh, Yuepeng Wang, Isil Dillig, and Thomas Dillig. SQLizer: query synthesis from natural language. Proceedings of the ACM on Programming Languages, 1(OOPSLA):1-26, 2017.
+[35] Tao Yu, Rui Zhang, Kai Yang, Michihiro Yasunaga, Dongxu Wang, Zifan Li, James Ma, Irene Li, Qingning Yao, Shanelle Roman, et al. Spider: A large-scale human-labeled dataset for complex and cross-domain semantic parsing and text-to-sql task. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 3911-3921, 2018.
+[36] Tao Yu, Rui Zhang, Michihiro Yasunaga, Yi Chern Tan, Xi Victoria Lin, Suyi Li, Heyang Er, Irene Li, Bo Pang, Tao Chen, et al. Sparc: Cross-domain semantic parsing in context. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4511-4523, 2019.
+[37] John M Zelle and Raymond J Mooney. Learning to parse database queries using inductive logic programming. In Proceedings of the national conference on artificial intelligence, pages 1050-1055, 1996.
+[38] Yusen Zhang, Xiangyu Dong, Shuaichen Chang, Tao Yu, Peng Shi, and Rui Zhang. Did you ask a good question? a cross-domain question intention classification benchmark for text-to-sql. arXiv preprint arXiv:2010.12634, 2020.
+[39] Yinhe Zheng, Guanyi Chen, and Minlie Huang. Out-of-domain detection for natural language understanding in dialog systems. IEEE/ACM Transactions on Audio, Speech, and Language Processing, 28:1198-1209, 2020.
+[40] Victor Zhong, Caiming Xiong, and Richard Socher. Seq2sql: Generating structured queries from natural language using reinforcement learning. arXiv preprint arXiv:1709.00103, 2017.
\ No newline at end of file
diff --git a/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/images.zip b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..138b01173fdc562ecc9ba96177144102a575b395
--- /dev/null
+++ b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7409185cf4466c399783c8d4953215f43ed4dc9b2dc3c50c09ece8408f7f8fc8
+size 450893
diff --git a/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/layout.json b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..9236b509666cc7e102a8cc1eb7722972bb3aba8c
--- /dev/null
+++ b/ehrsqlapracticaltexttosqlbenchmarkforelectronichealthrecords/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d557ebaa1addc5a0982b09ba1c995c1f7da6818a48c8249f74b3cb92312fe874
+size 282779
diff --git a/elasticnumericalreasoningwithadaptivesymboliccompiler/806407ac-dcaa-4ed6-9af3-25ab5a56b5d3_content_list.json b/elasticnumericalreasoningwithadaptivesymboliccompiler/806407ac-dcaa-4ed6-9af3-25ab5a56b5d3_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..a7fe2b2b604f3c767b733ec81c8364c45e590696
--- /dev/null
+++ b/elasticnumericalreasoningwithadaptivesymboliccompiler/806407ac-dcaa-4ed6-9af3-25ab5a56b5d3_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ab9f0a0647544205185abafb135046aa5ecd360c446c823fedce279be9247702
+size 82346
diff --git a/elasticnumericalreasoningwithadaptivesymboliccompiler/806407ac-dcaa-4ed6-9af3-25ab5a56b5d3_model.json b/elasticnumericalreasoningwithadaptivesymboliccompiler/806407ac-dcaa-4ed6-9af3-25ab5a56b5d3_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..0f9af77c547ad4337938e96858b81cb099946855
--- /dev/null
+++ b/elasticnumericalreasoningwithadaptivesymboliccompiler/806407ac-dcaa-4ed6-9af3-25ab5a56b5d3_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ba4d33f6a331ce01a60645fd85667526ef100351bb35bb4f609e43f1bc58684d
+size 103791
diff --git a/elasticnumericalreasoningwithadaptivesymboliccompiler/806407ac-dcaa-4ed6-9af3-25ab5a56b5d3_origin.pdf b/elasticnumericalreasoningwithadaptivesymboliccompiler/806407ac-dcaa-4ed6-9af3-25ab5a56b5d3_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..544ae44cf1fcfa94d03d35f1cc3f5f4180a457a0
--- /dev/null
+++ b/elasticnumericalreasoningwithadaptivesymboliccompiler/806407ac-dcaa-4ed6-9af3-25ab5a56b5d3_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8fae72f18fd2805b3809808ba4bdbc17df9dd75a35f1ead583b09edffa4cd67e
+size 626052
diff --git a/elasticnumericalreasoningwithadaptivesymboliccompiler/full.md b/elasticnumericalreasoningwithadaptivesymboliccompiler/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..c922e40a9b1c8d8dc69aeffe041cbdfa3947b186
--- /dev/null
+++ b/elasticnumericalreasoningwithadaptivesymboliccompiler/full.md
@@ -0,0 +1,281 @@
+# ELASTIC: Numerical Reasoning with Adaptive Symbolic Compiler
+
+Jiaxin Zhang
+
+University of Strathclyde 16 Richmond Street, Glasgow, G1 1XQ jiaxin.zhang@strath.ac.uk
+
+Yashar Moshfeghi
+
+University of Strathclyde 16 Richmond Street, Glasgow, G1 1XQ yashar.moshfeghi@strath.ac.uk
+
+# Abstract
+
+Numerical reasoning over text is a challenging task of Artificial Intelligence (AI), requiring reading comprehension and numerical reasoning abilities. Previous approaches use numerical reasoning programs to represent the reasoning process. However, most works do not separate the generation of operators and operands, which are key components of a numerical reasoning program, thus limiting their ability to generate such programs for complicated tasks. In this paper, we introduce the numErlaL reAsoning with adapTive symbolIc Compiler (ELASTIC) model, which is constituted of the RoBERTa as the Encoder and a Compiler with four modules: Reasoning Manager, Operator Generator, Operands Generator, and Memory Register. ELASTIC is robust when conducting complicated reasoning. Also, it is domain agnostic by supporting the expansion of diverse operators without caring about the number of operands it contains. Experiments show that ELASTIC achieves 68.96 and 65.21 of execution accuracy and program accuracy on the FinQA dataset and 83.00 program accuracy on the MathQA dataset, outperforming previous state-of-the-art models significantly. $^{1}$
+
+# 1 Introduction
+
+Recently, Pre-trained Language Models (PLMs) [1, 2, 3, 4, 5] show astonishing performance over reading comprehension tasks like SQuAD [6]. However, PLMs fall short of numerical reasoning over text [7], which requires conducting numerical reasoning based on understanding the text. Hence, numerical reasoning over text is more challenging than reading comprehension [8] and attracts the interest of the AI community. Previous approaches adopt the sequence-to-sequence architecture to generate the sequential format of numerical reasoning programs (see (b) in Table 1) [9, 10]. However, the sequential format could produce invalid expressions such as "3 - ((2)" because of the wrong position of parentheses [11]. To avoid this, some methods convert the reasoning program to the binary tree, then use the tree-decoder to generate the pre/post-order traversal sequence (see (c) in Table 1) [12, 13, 14]. Alternatively, FinQANet [15] represents the reasoning program in a flattened format and generates the right parentheses forcibly after generating two consecutive operands. To increase the scalability, NeRd [7] introduces the symbolic operations and generates the reasoning program as the nested compositional format (see (e) in Table 1). Researchers also investigate to capture valuable information between entities and numbers to improve numerical reasoning ability. Some works use PLMs [8, 7, 16], while others, like Li et al. [17] and Ran et al. [18], adopt graph neural network to encode the text.
+
+Currently, proposed approaches struggle with two significant problems. Firstly, they are vulnerable to complicated numerical reasoning problems. The complicated numerical reasoning problems usually
+
+contain a long reasoning program, in which the types of operators are diverse, and the number of operands is dynamic. Since most works do not separate the generation of operators and operands, their performance is hindered by cascading errors when encountering complicated tasks. Secondly, previous works lack extensibility for the operators, which arises from either the flaw of the model architecture or the representation format of the program, making them hard to apply to different data domains.
+
+Table 1: An Example (from MathQA [19] dataset) requires solving the problem by conducting numerical reasoning. The numerical reasoning program could be represented by four different formats: sequential format, tree-traverse format, flatten format [15], or nested format. $\# n$ refers to the executable result from the $n$ th sub-program, and const_2 refers to the constant number 2.
+
+Problem: A small table has a length of 12 inches and a breadth of b inches. Cubes are placed on the surface of the table so as to cover the entire surface. The maximum side of such cubes is found to be 4 inches. Also, a few such tables are arranged to form a square. The minimum length of side possible for such a square is 80 inches. What is the number for b?
+
+(a) Numerical Reasoning Program: $b = \sqrt{\left(\frac{80}{4}\right)^2 - 12^2}$
+(b) Sequential Format: $\sqrt{((80 \div 4) \times (80 \div 4) - (12 \times 12))}$
+(c) Pre-order Traverse Format: $\sqrt{, - , \times , \div , 80, 4, \div , 80, 4, \times , 12, 12, \text{none}}$
+(d) Flattened Format:
+divide(80,4)|power(12,const_2)|power(#0,const_2)|subtract(#2,#1)|sqrt(#3)
+(e) Nested Format: sqrt(subtract(power(divide(80, 4), const_2), power(12, const_2)))
+
+Hence, we present the numErlaL reASoning with adapTive symbolc Compiler (ELASTIC) model. ELASTIC separates the generation of operators and operands, allowing it to be less influenced by the cascading error from the complicated reasoning. Moreover, ELASTIC is adaptable to the number of operands following an operator, making it domain-agnostic to support diverse operators. Specifically, ELASTIC contains an Encoder part extracting the contextual representations of the passage and question and a Compiler part generating the numerical reasoning program. The Compiler consists of four modules: Reasoning Manager, Operator Generator, Operands Generator, and Memory Register. We conduct experiments on two challenging datasets: FinQA [15], and MathQA [19]. Since FinQA and MathQA are collected from different domains: annual financial reports and GRE/GMAT, ELASTIC demonstrates its adaptability by achieving state-of-the-art results on both datasets. Furthermore, our ablation studies investigate how the length of the numerical reasoning program influences the model's numerical reasoning ability, which shows that ELASTIC is less liable to being influenced by the cascading error. In addition, we introduce the maximum Memory Departing Distance (M-MDD), which measures how difficult for the mode to use the executable results from the previous sub-program. We use M-MDD to demonstrate the necessity of the Memory Register in ELASTIC. The contributions of our work are: (1) we present a numerical reasoning model ELASTIC with good adaptability and elasticity, which separates the generation of operators and operands. ELASTIC achieves state-of-the-art results on two challenging datasets: FinQA and MathQA; (2) we introduce the design of separate modules and Memory Register, making ELASTIC perform stably on complicated numerical reasoning problems; (3) the proposed ELASTIC is domain agnostic because it supports diverse operators.
+
+# 2 Related Work
+
+Making models to conduct numerical reasoning has attracted the AI community since the last century [20]. Previous research has investigated making the model do numerical reasoning over text by using statistical learning methods to find a similar equation pattern [21, 22, 23, 24]. Since deep learning has recently achieved great success in many tasks, Wang et al. [25] propose DNS, which is the first deep learning model for solving math word problems as far as we know. After their work, researchers
+
+try to find a better way to represent the numerical reasoning program. For example, Wang et al. [26], and Wang et al. [27] use the expression tree to represent the reasoning program. Sun et al. [11] create tree-decoder GTS, which generates prefix traverse sequence of the tree. Chiang et al. [28], and Qin et al. [13] extract the semantic information from the question and passage texts and want to connect them with the reasoning steps. In addition, Li et al. [29], and Zhang et al. [30] introduce the graph encoder to capture the structural information or syntactic information to capture the relation between numbers and entities. Shen et al. [31] propose a unified model, which uses both sequential and graph as the encoder, then uses seq2seq and tree decoder to generate the reasoning program.
+
+Furthermore, several datasets are proposed to evaluate the model's numerical reasoning ability, such as Math23K [32] and HWMP [13]. There are also more challenging datasets, like ASdiv [33], and MathQA [19]. At the same time, Dua et al. propose DROP [34], which requires more than arithmetic operations to conduct numerical reasoning. State-of-the-art models like NeRd [7] and NumNet [18] are introduced to solve the DROP dataset. More recently, a dataset called FinQA [15] has been proposed, which is constructed from the annual financial report.
+
+Despite the considerable success achieved by these approaches, Patel et al. [35] argues that some state-of-the-art models, like GTS [11] and Graph2Tree [30], only learn the statistical relation instead of numerical reasoning ability. Unlike previous works, our model ELASTIC separates the generation of operators and operands, allowing it to conduct complicated numerical reasoning. Moreover, ELASTIC is adaptable to the number of operands following an operator, making it domain agnostic.
+
+# 3 Approach
+
+Figure 1 shows the architecture of our ELASTIC model. ELASTIC consists of an Encoder part encoding the question text and problem text into contextual vectors and a Compiler part producing the numerical reasoning programs. The Compiler part consists of four modules: Reasoning Manager, Operator Generator, Operands Generator, and Memory Register. The Reasoning Manager leverages other modules to produce the numerical reasoning program. Since a complete numerical reasoning program usually contains several sub-programs, the generation steps between operators and operands are interchangeable. To help the following sub-programs use executable results from the previous sub-programs, Memory Register stores the sub-programs executable results into corresponding pre-defined cache tokens embeddings. $^2$
+
+Table 2: Task Definition Notation
+
+| Notation | Description |
| P, Q, R | Problem Text, Question Text, Numerical Reasoning Program |
| NUM | The numbers in P and Q |
| CONS | Constants defined in DSL |
| OP | All mathematical operators |
| op i | Theith operator in R |
| OE | All operands |
| oe i | All operands belonging to op i |
| oej i | The jth operands of op i |
| s | From either OP or OE, s constitute R |
| ri | The i-th sub-program of R
+ri = op i [oe i] |
+
+Task Definition Given the problem text $P$ and question text $Q$ , the task is to generate a numerical reasoning program $R$ . Both problem text $P$ and question text $Q$ consist of words and numbers (denoted by $NUM$ ). The Numerical reasoning program $R$ represents the numerical reasoning process,
+
+which is a sequence of symbols (denoted by $s$ ) from mathematical operators (denoted by $OP$ ) and operands (denoted by $OE$ ). Operands $OE$ are from either constant numbers (denoted by $CONS$ ) defined in Domain Specific Language (DSL) or NUM. $CONS$ are the special numbers that do not exist in either the problem text $P$ and question text $Q$ , such as $\mathrm{const\_pi}(\pi)$ . Finally, the pattern of the numerical reasoning program $R$ is defined as $R = \left\{op_{i}\left[oe_{j}^{i}\right]_{j=0}^{m-1}\right\}_{i=0}^{n-1}$ , where $op_{i} \in OP$ , it is the $i_{th}$ operator in $R$ , and $op_{i}$ contains several operands $oe_{j}^{i}$ . In addition, we regard a group of one operator and its operands as the sub-program $r$ . For example, $op_{i}\left[oe_{j}^{i}\right]$ is the $i_{th}$ sub-program $r_{i}$ , which can be executed since it is a complete arithmetic program. $^3$
+
+# 3.1 Encoder Part
+
+As shown in Figure 1 (Encoder), the Encoder takes the concatenated sequence of $Q$ and $P$ as input. The Encoder encodes the input sequence and outputs the contextual vectors $\mathbf{h}^{enc}$ . Next, $\mathbf{h}^{enc}$ is used for the Compiler to produce the numerical reasoning program $R$ . In this work, we use RoBERTa as the Encoder. The outputs from the final layer of RoBERTa are used as $\mathbf{h}^{enc} \in \mathbb{R}^{h*s}$ , where $s$ is the maximum input length of the RoBERTa, and $h$ is the hidden size of RoBERTa. Note that ELASTIC is not dependent on the specific type of encoder. Any model providing contextual vectors of the sequence can be used.
+
+
+Figure 1: The overall architecture of the ELASTIC model. The Encoder part takes the sequence of question text $Q$ and passage text $P$ as input, then generates the contextual vectors $\mathbf{h}^{enc}$ . The Compiler part consists of four modules: Reasoning Manager, Operator Generator, Operands Generator, and Memory Register. The right part of the figure shows a complete process of the generation of sub-program $r_t$ . Firstly, Reasoning Manager sends the guidance vectors $g^{op}$ to the Operator Generator, which guides the generation of operator $op_t$ . Secondly, Reasoning Manager suspends the Operator Generator, then the Operands Generator takes $g^{op}$ and $op_t$ from the Operator Generator to produce the first operand $oe_1^t$ . When finish the generation of the sub-program $r_t$ , the Memory Register stores the results and updates the embedding vectors of cache token $\# t$ by $g_t^{oe}$ . Again, the Compiler repeats to generate next sub-program $r_{t+1}$ .
+
+# 3.2 Compiler Part
+
+Decoding Vocabulary and Token Embedding We first describe the decoding vocabulary. The decoding vocabulary consists of $OP$ and $OE$ , where $OE$ can be further categorized into $NUM$ and $CONS$ . The embedding $\mathbf{e}_s$ of symbol $s$ of the decoding vocabulary is represented by the embedding $\mathbf{E}_{op,cons,num}(s)$ , which is the embedding look-up function. Hence, the embedding for symbol $s$ is defined as:
+
+$$
+\mathbf {e} _ {s} = \left\{ \begin{array}{l l} \mathbf {E} _ {o p} (s) & \text {i f s \in O P} \\ \mathbf {E} _ {c o n s} (s) & \text {i f s \in C O N S} \\ \mathbf {E} _ {n u m} (s) = \mathbf {h} _ {i} ^ {e n c} & \text {i f s \in N U M} \end{array} \right. \tag {1}
+$$
+
+The symbols embeddings of $OP$ and $CONS$ are two trainable embedding matrices $\mathbf{E}_{op} \in \mathbb{R}^{h*n_{op}}$ and $\mathbf{E}_{cons} \in \mathbb{R}^{h*n_{cons}}$ ( $n_{op}$ and $n_{cons}$ refers to the sizes of $OP$ and $CONS$ respectively). The embedding for the symbol of $NUM$ is $\mathbf{h}_i^{enc} \in \mathbb{R}^h$ , where $i$ denotes the index position in the sequence of $\mathbf{Q}$ and $\mathbf{P}$ .
+
+Reasoning Manager As shown in Figure 1 (Reasoning Manager), the Reasoning Manager outputs the vector $\mathbf{g}$ , which guides the Operator Generator and the Operands Generator to produce $op$ and $oe$ . The inputs for the Reasoning Manager are contextual vectors $\mathbf{h}_q^{enc}$ ( $\mathbf{h}_q^{enc}$ for generating operators) from the Encoder and embedding of the previously generated symbol $s_{t-1}$ . The Reasoning Manager first calculates the context vector $\mathbf{c}$ by the normalized vectors of $\mathbf{h}_i^{enc}$ and the attention weights $a_i$ :
+
+$$
+\mathbf {c} = \sum_ {i} a _ {i} \mathbf {h} _ {i} ^ {\text {e n c}} \tag {2}
+$$
+
+$$
+a _ {i} = \frac {\exp \left(\operatorname {s c o r e} \left(\mathbf {e} _ {s _ {t - 1}} , \mathbf {h} _ {i} ^ {e n c}\right)\right)}{\sum_ {j} \exp \left(\operatorname {s c o r e} \left(\mathbf {e} _ {s _ {t - 1}} , \mathbf {h} _ {j} ^ {e n c}\right)\right)} \tag {3}
+$$
+
+$$
+\operatorname {s c o r e} \left(\mathbf {e} _ {s _ {t - 1}}, \mathbf {h} _ {i} ^ {\text {e n c}}\right) = \mathbf {e} _ {s _ {t - 1}} ^ {\mathrm {T}} \mathbf {W} _ {1} \cdot \mathbf {W} _ {2} \mathbf {h} _ {i} ^ {\text {e n c}} \tag {4}
+$$
+
+where $\mathbf{W}_1\in \mathbb{R}^{h*h}$ and $\mathbf{W}_2\in \mathbb{R}^{h*h}$ , and both are trainable parameters. The c summarizes the encoded information from the Encoder according to the previous generated symbol $s$ . Next, the Reasoning Manager adopts the GRU [36] network to generate the guidance output $\mathbf{g}$ :
+
+$$
+\mathbf {g}, \mathbf {h} _ {t} = \operatorname {G R U} \left(\operatorname {R e l u} \left(\mathbf {W} _ {3} [ \mathbf {c}: \mathbf {E} _ {\text {o p , c o n s , n u m}} (s _ {t - 1}) ]\right), \mathbf {h} _ {t - 1}\right) \tag {5}
+$$
+
+where $":"$ represents concatenation. $\mathbf{W}_3\in \mathbb{R}^{h*2h}$ is trainable parameter, and Relu is the activation function. $\mathbf{h}_{\mathbf{t - 1}}\in \mathbb{R}^h$ is the hidden state of GRU from the previous step, and $\mathbf{h}_0$ is $\mathbf{0}$ .
+
+Operator Generator As shown in Figure 1 (Operator Generator). Firstly, the Operator Generator receives the guidance vector $\mathbf{g}_t^{op}$ from the Reasoning Manager by inputting: contextual vectors $\mathbf{h}_q^{enc}$ of tokens from the question $Q$ , and embedding $\mathbf{E}_{op}(opt_{t-1})$ of the previously generated operator. Next, the Operator Generator calculates the probabilities of $i$ -th operator (denoted as $i-op$ ) of the OP:
+
+$$
+\mathbb {P} (i - o p | \mathbf {E} _ {o p} (o p _ {t - 1}), \mathbf {g} _ {t} ^ {o p}) = \frac {\exp \left(\mathbf {E} _ {o p} ^ {\mathrm {T}} (i - o p) \operatorname {R e l u} \left(\mathbf {W} _ {o p} \mathbf {g} _ {t} ^ {o p}\right)\right)}{\sum_ {j - o p \in O P} \exp \left(\mathbf {E} _ {o p} ^ {\mathrm {T}} (j - o p) \operatorname {R e l u} \left(\mathbf {W} _ {o p} \mathbf {g} _ {t} ^ {o p}\right) \right.} \tag {6}
+$$
+
+where $W_{op} \in \mathbb{R}^{h*h}$ is trainable parameter. The Operator Generator selects the operator with the highest probability as the predicted op. Next, unlike other models, the Reasoning Manager suspends the generation of operators and starts to generate operands $\{o e^t\}$ through the Operands Generator.
+
+Operands Generator As shown in Figure 1 (Operands Generator). The inputs from Operands Generator to the Reasoning Manager are different from Operator Generator's. Because $oe$ could be a number in $Q$ or $P$ , the contextual vectors $\mathbf{h}^{enc}$ of all tokens are used. Furthermore, the Operands Generator initializes the embedding of the initial operand $\mathbf{e}_{(oe_0^t)}$ as $\text{Relu}(\mathbf{W}_4[\mathbf{E}_{op}(op_t):\mathbf{g}_t])$ ( $\mathbf{W}_4 \in \mathbb{R}^{h*2h}$ ), leveraging information of $op_t$ to produce $oe^t$ . Next, the Reasoning Manager outputs $g_n^{oe}$ for $n$ -th step generation of operand $oe_n^t$ . Finally, the probability of $i$ -th operand (denoted as $i - oe$ ) of the OE:
+
+$$
+\mathbb {P} (i - o e | \mathbf {E} _ {\text {c o n s , n u m}} (o e _ {n - 1} ^ {t}), \mathbf {g} _ {t} ^ {o e}) = \frac {\exp \left(\mathbf {E} _ {\text {c o n s , n u m}} ^ {\mathrm {T}} (i - o e) \operatorname {R e l u} \left(\mathbf {W} _ {o e} \mathbf {g} _ {t} ^ {o e}\right)\right)}{\sum_ {j - o e \in O E} \exp \left(\mathbf {E} _ {\text {c o n s , n u m}} ^ {\mathrm {T}} (j - o e) \operatorname {R e l u} \left(\mathbf {W} _ {o e} \mathbf {g} _ {t} ^ {o e}\right)\right)} \tag {7}
+$$
+
+where $W_{oe} \in \mathbb{R}^{h*h}$ is trainable parameter. The Operands Generator selects the operand with the highest probability as the predicted oe. After one operand has been generated, the Operands Generator continues producing operands for the sub-program $r_t$ . The decoding process for the operands terminates when the token none is produced.
+
+Memory Register When generating sub-program $r_i$ , its operands could be the executable results from the previous sub-program $r_p(p < i)$ . To make the Operands Generator be able to use the results from previous sub-programs. Inspired by Chen et al. [15], we introduce a cache token $\# n$ to the CONS of DSL, which is used for storing the information of executable results. Unlike other constants, $\# n$ does not point to a static value. It is different according to the different sub-program $r_n$ . As the results, ELASTIC needs to update the representation of $\# n$ after the sub-program $r_n$ is generated. Specifically, the Memory and Register module update the cache $\# n$ by replacing its embedding with output $\mathbf{g}_n^{oe}$ , which is the guidance vector from Reasoning Manager to guide the generation of the last operands belonging to the sub-program $r_n$ .
+
+Training Objective Given the data $\mathbb{D}$ with size of $N$ containing $P_{i}, Q_{i}, \hat{o}p^{i}, \hat{o}e^{i}$ , where $P_{i}$ and $Q_{i}$ refer to the passage and question in the $i^{th}$ training data, likewise, $\hat{o}p^{i}$ and $\hat{o}e^{i}$ are the golden operators and operands. Our training goal is to minimize the sum of the negative log-likelihood over the entire data, so the training loss is $\sum_{i=1}^{N} -\left\{\log \mathbb{P}(\mathrm{OP}^{i}|\mathrm{P}^{i}, \mathrm{Q}^{i}) + \log \mathbb{P}(\mathrm{OE}^{i}|\mathrm{P}^{i}, \mathrm{Q}^{i})\right\}$ .
+
+# 4 Experimental Set-up
+
+Datasets We conduct evaluation experiments on two datasets: FinQA [15] and MathQA [19].4
+
+FinQA: FinQA is a dataset created from the annual financial reports. It contains 8,281 data, split into train, eval, and test parts with 6,251, 883, and 1,147 examples. We adopt the evaluation metrics from the original FinQA paper: execution accuracy (Exe Acc) and program accuracy (Prog Acc). The program accuracy calculates the accuracy of the operators and operands between the predicted program and the golden program. The execution accuracy calculates the accuracy between the golden executable result and the result from the predicted program. Since the FinQA dataset only contains operators with two operands, we extend it by creating questions required to be solved by the operators with more than two operands. We use the extended FinQA dataset to evaluate our models' adaptability to the number of operands (See Appendix A).
+
+MathQA: MathQA is created from GRE/GMAT examinations, containing 37,200 math word problems. The dataset is split into $80\%$ , $12\%$ , and $8\%$ of train, dev, and test data. Compared with the FinQA dataset, the examples of MathQA require more advanced reasoning ability, which challenges the model to conduct advanced numerical reasoning (see Appendix B). A significant difference with FinQA is that the number of operands following an operator is not explicit in the MathQA dataset. Each MathQA question contains one correct of several answer options, calculated by the reasoning program with the knowledge of the operation semantics. Since we do not have this kind of knowledge, we adopted the same way as NeRd [7], by only using program accuracy to evaluate models' performances. Note that program accuracy is stricter than execution accuracy because the model could find the correct answer by spurious reasoning programs.
+
+Baselines We compare our ELASTIC model with several state-of-the-art models. (1) FinQANet [15]: It adopts the Encoder-Decoder architecture with a cache updating mechanism to generate the program. Since FinQANet only supports generating operators with exact two operands, we manage to train and evaluate FinQANet on the MathQA dataset by discarding the operators containing more than two operands. (2) NeRd [7]: it uses the BERT and a pointer-generator-based model to generate the symbolic nested program. (3) Graph2Tree [17]: It models the dependency information of the text sequence by the GraphSAGE [38] like model, and generates the program in a tree-structured way. (4) NumNet [18]: NumNet models the numeracy information by a GNN network. We also train the NumNet+, which replaces the Encoder of the NumNet by RoBERTa-large. Note that program
+
+accuracy does not apply to NumNet, since NumNet does not generate compositional reasoning programs. (5) Human Performance: We also report the human performance of both experts and non-experts in the FinQA dataset. The results are taken from the original FinQA paper [15].
+
+Implementation Details The model is implemented by Pytorch [39] and Transformer [40], then trained on a server with an NVIDIA Tesla A100 GPU of 40G memory. Training epochs are set to 50 and 100 for FinQA and MathQA, respectively. The batch size for all datasets is set to 10. We use Adam as optimizer [41] to update the parameters of the models. The initial learning rate is set to 1e-5 equally, and it would be halved in every 25 epochs and 50 epochs for FinQA and MathQA. During training, the dropout rate and the weight decay are set to 0.1 and 1e-5 to prevent over-fitting. The parameters of the RoBERTa are fine-tuned during training. For the GRU cell in the decoder, the hidden size is the same as the RoBERTa, and the GRU layers number is 4. During inference, we use greedy decoding to generate the reasoning program.
+
+# 5 Results
+
+Overall Results Table 3 shows the performances of our ELASTIC model and baselines on FinQA and MathQA. Overall, ELASTIC (RoBERTa-large) achieves the highest scores on both datasets. In the FinQA dataset, we see a significant lead in our ELASTIC (RoBERTa-large) model compared to the best baseline FinQANet (RoBERTa-large), with 3.91 points higher execution accuracy and 1.69 points higher program accuracy. When we change the Encoder part of ELASTIC from RoBERTa-large to RoBERTa-base, it still achieves better results than FinQANet using the same size of RoBERTa. Since both ELASTIC and FinQANet use the RoBERTa as the encoder, the results demonstrate the improvements brought by separating the generation procedures for operators and operands. Both ELASTIC models outperform the NeRd with a large margin. It is worth mentioning that NeRd defines external rules for different operators in their model [7], which is not the case with the ELASTIC. ELASTIC also outperforms the NumNet and NumNet+ by a considerable margin. This could be due to the internal structure of these models limiting their scalability in generating reasoning programs, thus struggling to produce reasoning steps in a systematic manner [42]. Finally, Graph2Tree achieves only 0.37 accuracy on the FinQA test dataset, which is much lower compared to its 69.96 program accuracy on the MathQA dataset. We suspect that this is because of the data leak problem existing in FinQA train and eval data (see detailed explanation in Appendix D). Although ELASTIC surpasses the non-expert performance, we can still find a large gap between our ELASTIC model and Human Expert.
+
+For the MathQA dataset, ELASTIC (RoBERTa-large) is the best performing model, with 3.3 higher program accuracy than NeRd and 13.04 points higher than Graph2Tree. We further investigate the performance of ELASTIC using RoBERTa-base, which still achieves higher accuracy of 82.27 than 79.7 of NeRd. The slight performance difference between ELASTIC (RoBERTa-large) and ELASTIC (RoBERTa-base) suggests that the extracted contextual semantic information of passage and question is sufficient. Finally, FinQANet achieves promising results on MathQA, $79.20\%$ program accuracy by FinQANet (RoBERTa-large) and $74.12\%$ program accuracy by FinQANet (RoBERTa-base). Note that we discarded the data of MathQA containing more than two operands for the FinQANet, so that performance of FinQANet on MathQA is the overestimation of its numerical reasoning ability. Even with such consideration, ELASTIC outperforms FinQANet significantly, demonstrating that ELASTIC is more adaptable by supporting diverse operators than FinQANet.
+
+Performance Breakdown To demonstrate the strength of ELASTIC, we investigate the importance of the Memory Register. Also, we show ELASTIC performance when generating different lengths of program steps.
+
+Necessity of Memory Register As discussed in the Section Memory Register, ELASTIC stores the executable results of each sub-program into a special cache token \#n, and updates its embedding after $n$ -th sub-program is generated. The longer the reasoning program is, the higher the probability of the generating process using the previous sub-program result. This section investigates the effect of the Memory Register on improving numerical reasoning performance.
+
+First, we present an ablation study of using and not using the Memory Register for ELASTIC. From Table 4, we find that ELASTIC with Memory Register performs slightly better than it without. Similar
+
+Table 3: Overall Results for the baselines and ELASTIC on the testing data from three datasets. $\dagger$ means that the scores are taken from the original papers. $\ddagger$ means that the scores are taken from the FinQA paper [15]. $\star$ The program accuracy does not apply to the NumNet on FinQA and MathQA datasets because NumNet does not generate the intermediate reasoning program. In addition, NumNet could only solve reasoning program involving add and subtract operations. However, the proportions of examples only use add and subtract as operations in MahtQA are $0.055\%$ and $0.056\%$ , respectively. As a result, we choose not to train NumNet on MathQA.
+
+| Datasets & Metrics | FinQA (test) | MathQA (test) |
| Exe Acc | Prog Acc | Prog Acc |
| Graph2Tree | 0.37 | 0.0 | 69.96† |
| NumNet | 2.32 | n/a* | n/a* |
| NumNet+ | 10.29 | n/a* | n/a* |
| NeRd | 52.48‡ | 49.90‡ | 79.70† |
| FinQANet (RoBERTa-base) | 60.10† | 58.38† | 74.12 |
| FinQANet (RoBERTa-large) | 65.05† | 63.52† | 79.20 |
| ELASTIC (RoBERTa-base) | 62.66 | 59.28 | 82.27 |
| ELASTIC (RoBERTa-large) | 68.96 | 65.21 | 83.00 |
| Human Expert | 91.16† | 87.49† | n/a |
| Human Non-Expert | 50.68† | 48.17† | n/a |
+
+Table 4: The performances of ELASTIC with or without memory register (MR). ELASTIC with MR performs better than without MR on FinQA and MathQA datasets. Both ELASTIC with or without MR performs better than FinQANet. All models use the RoBERTa-large as the encoder.
+
+| Datasets & Metrics | FinQA (test) | MathQA (test) |
| Exe Acc | Prog Acc | Prog Acc |
| ELASTIC w MR | 68.96 | 65.21 | 83.00 |
| ELASTIC w/o MR | 68.79 | 64.78 | 82.68 |
| FinQANet | 65.06 | 63.52 | 79.20 |
+
+observations can be found for the MathQA dataset. This observation demonstrates the value of the Memory Register. Next, since ELASTIC and FinQANet store the executable results from the previous sub-program in a different way, we conduct a comparison between the two models. The results from Table 4 show that the ELASTIC with Memory Register achieves significantly higher scores than FinQANet on both datasets.
+
+Next, given two sub-program belonging to the same $R$ : $r_i, r_j (i < j)$ , where the executable result of $r_i$ is used as the operand for $r_j$ . Then, we introduce the Memory Departing Distance (MDD) for $r_i$ and $r_j$ as $j - i$ , and the maximum Memory Departing Distance (M-MDD) as the longest MDD between all $\{r\}$ of $R$ . The bigger M-MDD is, the more challenging to select the correct previous sub-program result, since the model tends to forget the information passing from long steps before. As the result, we investigate how models perform when dealing with different M-MDD.
+
+From Figure 2a and Figure 2b, the ELASTIC with Memory Register performs better than ELASTIC without it at each M-MDD on FinQA and MathQA datasets. Particularly in the MathQA dataset, when M-MDD is larger than 5, ELASTIC with Memory Register can achieve better results than the ELASTIC without it. This demonstrates the importance of the Memory Register when using
+
+
+(a)
+
+
+(b)
+
+
+(c)
+Figure 2: (a) Program Accuracy on FinQA according to the M-MDD. (b) Program Accuracy on MathQA according to the M-MDD. (c) Program Accuracy and Operator Accuracy of ELASTIC (RoBERTa-large) on different program steps in MathQA dataset, compared with Program Accuracy of FinQANet (RoBERTa-large).
+
+executable results from long steps before. Worth mentioning that ELASTIC performs better than FinQANet on both datasets, even without the Memory Register.
+
+Performance on Different Program Steps When producing the long numerical reasoning program, ELASTIC is less influenced by the cascading error. To demonstrate this superiority of ELASTIC, we investigate how different lengths of programs influence models' performances.
+
+Table 5: ELASTIC and FinQANet performances on FinQA dataset in terms of different program steps. The "# Train & Dev" is the number of training and development data. All models use the RoBERTa-large as the encoder. $\dagger$ means the results of that model are taken from the original FinQA [15] paper. $\ddagger$ means that the FinQANet (RoBERTa-large) is re-trained by ourselves.
+
+| Program Steps | ELASTIC | FinQANet† | FinQANet‡ | # Train & Dev |
| Exe Acc | Prog Acc | Exe Acc | Prog Acc | Exe Acc | Prog Acc |
| =1 | 76.30 | 75.66 | 70.27 | 68.77 | 73.70 | 71.25 | 4240 |
| =2 | 66.01 | 66.01 | 63.69 | 61.79 | 62.34 | 59.65 | 2300 |
| ≥3 | 31.78 | 31.10 | 31.65 | 31.65 | 28.57 | 23.80 | 594 |
+
+Table 5 displays the models' performances when generating programs with different steps. ELASTIC (RoBERTa-large) performs better than FinQANet (RoBERTa-large)† when the program step is either 1 or 2, indicating ELASTIC also performs well on the shorter program steps. Surprisingly, with the program step increasing from 3, the accuracy for both ELASTIC and FinQANet tumbles by half compared with the performances on program steps equal 2. We suspect that the FinQA dataset lacks sufficient training examples for the data with more than 3 program steps. Table 5 shows that the number of training data with more than 2 program steps is 594 compared to the numbers of data available for program steps equal to 1 (4240) or 2 (2300). For a fair comparison, we retrained the FinQANet (RoBERTa-large) on the FinQA dataset, but ELASTIC still outperforms it in execution accuracy and program accuracy.
+
+From Figure 2c, ELASTIC (RoBERTa-large) surpasses the FinQANet (RoBERTa-large) on MathQA dataset almost on every program step. Meanwhile, although MathQA is challenging, ELASTIC (RoBERTa-large) still achieves program accuracy over 80.0 when program steps are less than or equal to 8. The model's performance drops when the program steps are equal to 9 and 10, but starts to soar when the program steps are bigger than 10. This demonstrates that ELASTIC performs well when generating longer program steps. As shown in Figure 2c, we plot the accuracy for the operator generation, which ignores the correctness of operands generation. We could find that the operation accuracy is always higher than the program accuracy regarding different program steps (except for program steps equal to 12). This finding demonstrates the advantage of separating the generation
+
+procedure for operators and operands. This finding also reveals that the wrong predictions are because ELASTIC selects the wrong operands. We suspect this is due to too much noise from the context.
+
+Finally, our ELASTIC (RoBERTa-large) model (with approximately 500 million trainable parameters) outperforms Austin et al.'s smallest model [43] (with 8 billion trainable parameters) but only marginally underperforms their largest model (with 137 billion trainable parameters). The parameter size of these models are 1600 and 274000 times bigger than our model respectively, resulting the training resources required significantly considerable.
+
+# 6 Conclusion and Future Work
+
+This paper presents the numErlaL reAsoning with adapTive symbolIc Compiler (ELASTIC) model aiming to solve the numerical reasoning over text problem. ELASTIC separates the generation of operators and operands, allowing the model to generate the long and complicated reasoning program. Also, ELASTIC is domain agnostic and supports diverse operators, increasing adaptability. In addition, we introduce the Memory Register and improve the performance of the model by using executable results from the preceding sub-programs. We evaluated the performance of the ELASTIC model on FinQA and MathQA datasets and conducted an extensive comparison with state-of-the-art models. The results show ELASTIC gained significant improvement over the state-of-the-art baselines. Furthermore, We investigated the model's performance in terms of different M-MDD, demonstrating the necessity of the Memory Register. Finally, we compared models' performances regarding different lengths of numerical reasoning programs, showing ELASTIC is adept at producing long numerical reasoning programs. In the future, we plan to improve the accuracy of matching numbers and entities of the text. In addition, ELASTIC requires annotated reasoning programs, which is labor intensive. It is worth investigating how to generate reasoning programs from the trained model.
+
+# References
+
+[1] Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. BERT: pre-training of deep bidirectional transformers for language understanding. In Jill Burstein, Christy Doran, and Thamar Solorio, editors, Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2019, Minneapolis, MN, USA, June 2-7, 2019, Volume 1 (Long and Short Papers), pages 4171-4186. Association for Computational Linguistics, 2019.
+[2] Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. Roberta: A robustly optimized BERT pretraining approach. CoRR, abs/1907.11692, 2019.
+[3] Zhilin Yang, Zihang Dai, Yiming Yang, Jaime G. Carbonell, Ruslan Salakhutdinov, and Quoc V. Le. Xlnet: Generalized autoregressive pretraining for language understanding. In Hanna M. Wallach, Hugo Larochelle, Alina Beygelzimer, Florence d'Alché-Buc, Emily B. Fox, and Roman Garnett, editors, Advances in Neural Information Processing Systems 32: Annual Conference on Neural Information Processing Systems 2019, NeurIPS 2019, December 8-14, 2019, Vancouver, BC, Canada, pages 5754-5764, 2019.
+[4] Tom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel M. Ziegler, Jeffrey Wu, Clemens Winter, Christopher Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. Language models are few-shot learners. In Hugo Larochelle, Marc'Aurelio Ranzato, Raia Hadsell, Maria-Florina Balcan, and Hsuan-Tien Lin, editors, Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual, 2020.
+[5] Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. Exploring the limits of transfer learning with a unified text-to-text transformer. J. Mach. Learn. Res., 21:140:1-140:67, 2020.
+
+[6] Pranav Rajpurkar, Jian Zhang, Konstantin Lopyrev, and Percy Liang. Squad: 100, 000+ questions for machine comprehension of text. In Jian Su, Xavier Carreras, and Kevin Duh, editors, Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, EMNLP 2016, Austin, Texas, USA, November 1-4, 2016, pages 2383-2392. The Association for Computational Linguistics, 2016.
+[7] Xinyun Chen, Chen Liang, Adams Wei Yu, Denny Zhou, Dawn Song, and Quoc V. Le. Neural symbolic reader: Scalable integration of distributed and symbolic representations for reading comprehension. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net, 2020.
+[8] Mor Geva, Ankit Gupta, and Jonathan Berant. Injecting numerical reasoning skills into language models. In Dan Jurafsky, Joyce Chai, Natalie Schluter, and Joel R. Tetreault, editors, Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, ACL 2020, Online, July 5-10, 2020, pages 946-958. Association for Computational Linguistics, 2020.
+[9] Yan Wang, Xiaojiang Liu, and Shuming Shi. Deep neural solver for math word problems. In Martha Palmer, Rebecca Hwa, and Sebastian Riedel, editors, Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, EMNLP 2017, Copenhagen, Denmark, September 9-11, 2017, pages 845-854. Association for Computational Linguistics, 2017.
+[10] Yan Wang, Xiaojiang Liu, and Shuming Shi. Deep neural solver for math word problems. In Martha Palmer, Rebecca Hwa, and Sebastian Riedel, editors, Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, EMNLP 2017, Copenhagen, Denmark, September 9-11, 2017, pages 845-854. Association for Computational Linguistics, 2017.
+[11] Zhipeng Xie and Shichao Sun. A goal-driven tree-structured neural model for math word problems. In Sarit Kraus, editor, Proceedings of the Twenty-Eighth International Joint Conference on Artificial Intelligence, IJCAI 2019, Macao, China, August 10-16, 2019, pages 5299-5305. ijcai.org, 2019.
+[12] Qianying Liu, Wenyv Guan, Sujian Li, and Daisuke Kawahara. Tree-structured decoding for solving math word problems. In Kentaro Inui, Jing Jiang, Vincent Ng, and Xiaojun Wan, editors, Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing, EMNLP-IJCNLP 2019, Hong Kong, China, November 3-7, 2019, pages 2370-2379. Association for Computational Linguistics, 2019.
+[13] Jinghui Qin, Lihui Lin, Xiaodan Liang, Rumin Zhang, and Liang Lin. Semantically-aligned universal tree-structured solver for math word problems. In Bonnie Webber, Trevor Cohn, Yulan He, and Yang Liu, editors, Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing, EMNLP 2020, Online, November 16-20, 2020, pages 3780-3789. Association for Computational Linguistics, 2020.
+[14] Jipeng Zhang, Roy Ka-Wei Lee, Ee-Peng Lim, Wei Qin, Lei Wang, Jie Shao, and Qianru Sun. Teacher-student networks with multiple decoders for solving math word problem. In Christian Bessiere, editor, Proceedings of the Twenty-Ninth International Joint Conference on Artificial Intelligence, IJCAI 2020, pages 4011–4017. ijcai.org, 2020.
+[15] Zhiyu Chen, Wenhu Chen, Charese Smiley, Sameena Shah, Iana Borova, Dylan Langdon, Reema Moussa, Matt Beane, Ting-Hao Huang, Bryan R. Routledge, and William Yang Wang. Finqa: A dataset of numerical reasoning over financial data. In Marie-Francine Moens, Xuanjing Huang, Lucia Specia, and Scott Wen-tau Yih, editors, Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, EMNLP 2021, Virtual Event / Punta Cana, Dominican Republic, 7-11 November, 2021, pages 3697-3711. Association for Computational Linguistics, 2021.
+[16] Zhenwen Liang, Jipeng Zhang, Jie Shao, and Xiangliang Zhang. MWP-BERT: A strong baseline for math word problems. CoRR, abs/2107.13435, 2021.
+
+[17] Shucheng Li, Lingfei Wu, Shiwei Feng, Fangli Xu, Fengyuan Xu, and Sheng Zhong. Graph-to-tree neural networks for learning structured input-output translation with applications to semantic parsing and math word problem. In Trevor Cohn, Yulan He, and Yang Liu, editors, Findings of the Association for Computational Linguistics: EMNLP 2020, Online Event, 16-20 November 2020, volume EMNLP 2020 of Findings of ACL, pages 2841-2852. Association for Computational Linguistics, 2020.
+[18] Qiu Ran, Yankai Lin, Peng Li, Jie Zhou, and Zhiyuan Liu. Numnet: Machine reading comprehension with numerical reasoning. In Kentaro Inui, Jing Jiang, Vincent Ng, and Xiaojun Wan, editors, Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing, EMNLP-IJCNLP 2019, Hong Kong, China, November 3-7, 2019, pages 2474-2484. Association for Computational Linguistics, 2019.
+[19] Aida Amini, Saadia Gabriel, Shanchuan Lin, Rik Koncel-Kedziorski, Yejin Choi, and Hannaneh Hajishirzi. Mathqa: Towards interpretable math word problem solving with operation-based formalisms. In Jill Burstein, Christy Doran, and Thamar Solorio, editors, Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2019, Minneapolis, MN, USA, June 2-7, 2019, Volume 1 (Long and Short Papers), pages 2357-2367. Association for Computational Linguistics, 2019.
+[20] Edward A Feigenbaum, Julian Feldman, et al. Computers and thought. New York McGraw-Hill, 1963.
+[21] Subhro Roy, Tim Vieira, and Dan Roth. Reasoning about quantities in natural language. Transactions of the Association for Computational Linguistics, 3:1-13, 2015.
+[22] Mohammad Javad Hosseini, Hannaneh Hajishirzi, Oren Etzioni, and Nate Kushman. Learning to solve arithmetic word problems with verb categorization. In Proceedings of the 2014 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 523-533, 2014.
+[23] Sowmya S Sundaram and Deepak Khemani. Natural language processing for solving simple word problems. In Proceedings of the 12th International Conference on Natural Language Processing, pages 394-402, 2015.
+[24] Chao-Chun Liang, Kuang-Yi Hsu, Chien-Tsung Huang, Chung-Min Li, Shen-Yu Miao, and Keh-Yih Su. A tag-based statistical english math word problem solver with understanding, reasoning and explanation. In IJCAI, pages 4254-4255, 2016.
+[25] Yan Wang, Xiaojiang Liu, and Shuming Shi. Deep neural solver for math word problems. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 845-854, 2017.
+[26] Lei Wang, Yan Wang, Deng Cai, Dongxiang Zhang, and Xiaojiang Liu. Translating a math word problem to an expression tree. CoRR, abs/1811.05632, 2018.
+[27] Lei Wang, Dongxiang Zhang, Jipeng Zhang, Xing Xu, Lianli Gao, Bing Tian Dai, and Heng Tao Shen. Template-based math word problem solvers with recursive neural networks. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 33, pages 7144-7151, 2019.
+[28] Ting-Rui Chiang and Yun-Nung Chen. Semantically-aligned equation generation for solving and reasoning math word problems. In Jill Burstein, Christy Doran, and Thamar Solorio, editors, Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2019, Minneapolis, MN, USA, June 2-7, 2019, Volume 1 (Long and Short Papers), pages 2656-2668. Association for Computational Linguistics, 2019.
+[29] Shucheng Li, Lingfei Wu, Shiwei Feng, Fangli Xu, Fengyuan Xu, and Sheng Zhong. Graph-to-tree neural networks for learning structured input-output translation with applications to semantic parsing and math word problem. In Trevor Cohn, Yulan He, and Yang Liu, editors, Findings of the Association for Computational Linguistics: EMNLP 2020, Online Event, 16-20
+
+November 2020, volume EMNLP 2020 of Findings of ACL, pages 2841-2852. Association for Computational Linguistics, 2020.
+[30] Jipeng Zhang, Lei Wang, Roy Ka-Wei Lee, Yi Bin, Yan Wang, Jie Shao, and Ee-Peng Lim. Graph-to-tree learning for solving math word problems. In Dan Jurafsky, Joyce Chai, Natalie Schluter, and Joel R. Tetreault, editors, Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, ACL 2020, Online, July 5-10, 2020, pages 3928-3937. Association for Computational Linguistics, 2020.
+[31] Yibin Shen and Cheqing Jin. Solving math word problems with multi-encoders and multi-decoders. In Donia Scott, Núria Bel, and Chengqing Zong, editors, Proceedings of the 28th International Conference on Computational Linguistics, COLING 2020, Barcelona, Spain (Online), December 8-13, 2020, pages 2924-2934. International Committee on Computational Linguistics, 2020.
+[32] Yan Wang, Xiaojiang Liu, and Shuming Shi. Deep neural solver for math word problems. In Martha Palmer, Rebecca Hwa, and Sebastian Riedel, editors, Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, EMNLP 2017, Copenhagen, Denmark, September 9-11, 2017, pages 845-854. Association for Computational Linguistics, 2017.
+[33] Shen-Yun Miao, Chao-Chun Liang, and Keh-Yih Su. A diverse corpus for evaluating and developing english math word problem solvers. In Dan Jurafsky, Joyce Chai, Natalie Schluter, and Joel R. Tetreault, editors, Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, ACL 2020, Online, July 5-10, 2020, pages 975-984. Association for Computational Linguistics, 2020.
+[34] Dheeru Dua, Yizhong Wang, Pradeep Dasigi, Gabriel Stanovsky, Sameer Singh, and Matt Gardner. DROP: A reading comprehension benchmark requiring discrete reasoning over paragraphs. pages 2368-2378, 2019.
+[35] Arkil Patel, Satwik Bhattachamishra, and Navin Goyal. Are NLP models really able to solve simple math word problems? In Kristina Toutanova, Anna Rumshisky, Luke Zettlemoyer, Dilek Hakkani-Tür, Iz Beltagy, Steven Bethard, Ryan Cotterell, Tanmoy Chakraborty, and Yichao Zhou, editors, Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2021, Online, June 6-11, 2021, pages 2080-2094. Association for Computational Linguistics, 2021.
+[36] Junyoung Chung, Caglar Güçehre, KyungHyun Cho, and Yoshua Bengio. Empirical evaluation of gated recurrent neural networks on sequence modeling. CoRR, abs/1412.3555, 2014.
+[37] Rik Koncel-Kedziorski, Subhro Roy, Aida Amini, Nate Kushman, and Hannaneh Hajishirzi. MAWPS: A math word problem repository. In Kevin Knight, Ani Nenkova, and Owen Rambow, editors, NAACL HLT 2016, The 2016 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, San Diego California, USA, June 12-17, 2016, pages 1152-1157. The Association for Computational Linguistics, 2016.
+[38] William L. Hamilton, Zhitao Ying, and Jure Leskovec. Inductive representation learning on large graphs. In Isabelle Guyon, Ulrike von Luxburg, Samy Bengio, Hanna M. Wallach, Rob Fergus, S. V. N. Vishwanathan, and Roman Garnett, editors, Advances in Neural Information Processing Systems 30: Annual Conference on Neural Information Processing Systems 2017, December 4-9, 2017, Long Beach, CA, USA, pages 1024-1034, 2017.
+[39] Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, Alban Desmaison, Andreas Kopf, Edward Yang, Zachary DeVito, Martin Raison, Alykhan Tejani, Sasank Chilamkurthy, Benoit Steiner, Lu Fang, Junjie Bai, and Soumith Chintala. Pytorch: An imperative style, high-performance deep learning library. In Advances in Neural Information Processing Systems 32, pages 8024-8035. Curran Associates, Inc., 2019.
+
+[40] Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierrick Cistac, Tim Rault, Rémi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander M. Rush. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45, Online, October 2020. Association for Computational Linguistics.
+[41] Diederik P. Kingma and Jimmy Ba. Adam: A method for stochastic optimization. In Yoshua Bengio and Yann LeCun, editors, 3rd International Conference on Learning Representations, ICLR 2015, San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings, 2015.
+[42] Brenden M. Lake and Marco Baroni. Generalization without systematicity: On the compositional skills of sequence-to-sequence recurrent networks. In Jennifer G. Dy and Andreas Krause, editors, Proceedings of the 35th International Conference on Machine Learning, ICML 2018, Stockholm, Sweden, July 10-15, 2018, volume 80 of Proceedings of Machine Learning Research, pages 2879-2888. PMLR, 2018.
+[43] Jacob Austin, Augustus Odena, Maxwell I. Nye, Maarten Bosma, Henryk Michalewski, David Dohan, Ellen Jiang, Carrie J. Cai, Michael Terry, Quoc V. Le, and Charles Sutton. Program synthesis with large language models. CoRR, abs/2108.07732, 2021.
+
+# Checklist
+
+The checklist follows the references. Please read the checklist guidelines carefully for information on how to answer these questions. For each question, change the default [TODO] to [Yes], [No], or [N/A]. You are strongly encouraged to include a justification to your answer, either by referencing the appropriate section of your paper or providing a brief inline description. For example:
+
+- Did you include the license to the code and datasets? [Yes] See Section ??
+- Did you include the license to the code and datasets? [No] The code and the data are proprietary.
+- Did you include the license to the code and datasets? [N/A]
+
+Please do not modify the questions and only use the provided macros for your answers. Note that the Checklist section does not count towards the page limit. In your paper, please delete this instructions block and only keep the Checklist section heading above along with the questions/answers below.
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] We provide the URL of our code in 1 of the paper.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See Section Implementation Details.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] We think the error bars are not related to the core result of our experiments.
+
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Section Implementation Details.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] See Section Datasets and Section Baselines.
+(b) Did you mention the license of the assets? [Yes]
+(c) Did you include any new assets either in the supplemental material or as a URL? [N/A]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/elasticnumericalreasoningwithadaptivesymboliccompiler/images.zip b/elasticnumericalreasoningwithadaptivesymboliccompiler/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..06e91adc10e5cea77d5f43afe0d651e6221bdabb
--- /dev/null
+++ b/elasticnumericalreasoningwithadaptivesymboliccompiler/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:83e31a132bc6e70436fe748c05d54fba7c08a3a60d8b6927cee65ca870293358
+size 300547
diff --git a/elasticnumericalreasoningwithadaptivesymboliccompiler/layout.json b/elasticnumericalreasoningwithadaptivesymboliccompiler/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..b3ce1fb4a23f46e049804b13306b67c3c70ff1bb
--- /dev/null
+++ b/elasticnumericalreasoningwithadaptivesymboliccompiler/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:78f180a83ed325da6c1469b97335b5c79a4cb69b163122adcf9baa01616bc79c
+size 446964
diff --git a/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/8644fa7e-3853-445f-a474-fdcb30359216_content_list.json b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/8644fa7e-3853-445f-a474-fdcb30359216_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..d86dc94554631b3ba095ad056ef8237c8fd023b0
--- /dev/null
+++ b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/8644fa7e-3853-445f-a474-fdcb30359216_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:13b5d4999cc810a48aa896533aeabab5bd0a51f0b1371342c44d43c95fa4903d
+size 86481
diff --git a/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/8644fa7e-3853-445f-a474-fdcb30359216_model.json b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/8644fa7e-3853-445f-a474-fdcb30359216_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..cf3544897c1d06eeb2bf0269f5319274417b6958
--- /dev/null
+++ b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/8644fa7e-3853-445f-a474-fdcb30359216_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c015436409489db3dd210e2d1b90e0b2c715bbb27223de4d275861b245fba813
+size 115574
diff --git a/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/8644fa7e-3853-445f-a474-fdcb30359216_origin.pdf b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/8644fa7e-3853-445f-a474-fdcb30359216_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..bbb16217119afd3ed9b480b7e3ac5ab825e121e0
--- /dev/null
+++ b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/8644fa7e-3853-445f-a474-fdcb30359216_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2464f1d209ac6346303b4328ec4e3c656bff9fb04b582e332c93bbd62330ba21
+size 3969546
diff --git a/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/full.md b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..ca19ee50deef938ab4cda6ba673e2a09b3fc38ff
--- /dev/null
+++ b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/full.md
@@ -0,0 +1,301 @@
+# ELEVATER: A Benchmark and Toolkit for Evaluating Language-Augmented Visual Models
+
+Chunyuan Li\*1, Haotian Liu\*2, Liunian Harold Li3, Pengchuan Zhang1, Jyoti Aneja1
+Jianwei Yang1, Ping Jin1, Houdong Hu1, Zicheng Liu1, Yong Jae Lee2, Jianfeng Gao1
+1Microsoft University of Wisconsin-Madison 3UCLA
+
+# Abstract
+
+Learning visual representations from natural language supervision has recently shown great promise in a number of pioneering works. In general, these language-augmented visual models demonstrate strong transferability to a variety of datasets and tasks. However, it remains challenging to evaluate the transferability of these models due to the lack of easy-to-use evaluation toolkits and public benchmarks. To tackle this, we build ELEVATER1, the first benchmark and toolkit for evaluating (pre-trained) language-augmented visual models. ELEVATER is composed of three components. $(i)$ Datasets. As downstream evaluation suites, it consists of 20 image classification datasets and 35 object detection datasets, each of which is augmented with external knowledge. $(ii)$ Toolkit. An automatic hyper-parameter tuning toolkit is developed to facilitate model evaluation on downstream tasks. $(iii)$ Metrics. A variety of evaluation metrics are used to measure sample-efficiency (zero-shot and few-shot) and parameter-efficiency (linear probing and full model fine-tuning). ELEVATER is platform for Computer Vision in the Wild (CVinW), and is publicly released at https://computer-vision-in-the-wild.github.io/ELEVATER/.
+
+# 1 Introduction
+
+Visual recognition has become ubiquitous in our society [76], with applications in geolocation [66], action recognition [73], street number transcription [58], satellite remote sensing [31], medical imaging [80], self-driving cars [26], etc. Core to these applications are visual recognition tasks such as image classification (IC) and object detection (OD). It is of high value to develop transferable visual models that perform well on a wide range of downstream applications. By leveraging large web crawled image-text corpora, recent advances in language-augmented visual models such as CLIP [66] and ALIGNN [35] have demonstrated strong transfer performance, making this direction one of the most practical visual learning approaches. The reason is twofold: $(i)$ open-set recognition is made possible by reformulating classification tasks as retrieval; $(ii)$ model generalization is improved as language supervision significantly increases the coverage of visual concepts for model training.
+
+The success has immediately inspired many studies of large-scale model pre-training [88, 92, 89, 49, 57, 27, 47, 95]. However, these studies use their own evaluation settings based on customized sets of downstream tasks where the detailed process of adapting the models to these tasks is typically not accessible to the public. Thus, it is extremely difficult for researchers to fairly compare models and develop new models based on other people's works. To fill this gap, we develop an open-source benchmark and toolkit, ELEVATER, to make the research results (e.g., model's task-level transferability) more rigorous, and reproducible. ELEVATER is composed of three components.
+
+- Benchmark (Datasets and Knowledge). We build the first publicly available benchmark to evaluate the large-scale task-level transferability of language-augmented visual models. The benchmark consists of two challenges: Image Classification in the Wild (ICinW) with 20 IC datasets and Object Detection in the Wild (ODinW) with 35 OD datasets. A collected external knowledge base for each dataset which could be used for language data augmentation.
+- Comprehensive Metrics. To measure the cost of deploying models for real-world applications, we measure a model's sample-efficiency in the zero-shot, few-shot and full-shot settings and parameter-efficiency in the linear probing and full model fine-tuning settings.
+- Reproducible Toolkit & Language-augmented Adaptation Methods. We develop an open-source software toolkit to support model adaptation and evaluation. Automatic hyper-parameter tuning is employed to avoid human-in-the-loop tuning, thus reducing human labor and ensuring a fair comparison among different model checkpoints. We also present a set of new model adaptation methods for pre-trained language-augmented visual models. Our methods significantly outperform the traditional vision-only adaptation methods. These methods serve as baselines for the development of more advanced adaptation methods.
+
+In addition, our empirical study leads to interesting findings. (i) Leveraging both text and vision in these models consistently yields better performance than vision-only in few-shot settings; In contrast, random initialization of the linear head in language-augmented visual models is sub-optimal. We also find that few-shot results are always better than zero-shot results, which is different from the results reported in [66]. (ii) For language-augmented visual models, linear probing performs better than full model fine-tuning in the few-shot settings. As the task-specific training data increases, fine-tuning outperforms linear probing. (iii) Our study shows that the use of external knowledge, including explicit knowledge of human-compiled thesaurus/dictionaries/documents and implicit knowledge stored in GPT3 [6], can improve zero-shot and few-shot learning performance. We summarize the pipeline to use ELEVATER in Figure 1, and organize the paper to focus on the benchmark and toolkit.
+
+
+Figure 1: The illustrative pipeline to use ELEVATER to evaluate a model checkpoint.
+
+# 2 Related Work: From Class-level to Task-level Transfer
+
+Zero-shot learning in computer vision has been studied for decades. The research topic has witnessed two distinctive notions of zero-shot: the traditional class-level zero-shot that usually refers to the study of generalizing to unseen object categories [42], and the recently popular task-level zero-shot that refers to the study of generalizing to unseen datasets/tasks [44, 66]. In Table 1, we compare our benchmark against existing benchmarks. Existing zero-shot learning benchmarks are developed for the class-level zero-shot setting. They are usually in a single domain, with a manual split of categories to produce disjoint training and test categories, e.g., Animal with Attributes (AwA) [43], Caltech-UCSD Birds-200 (CUB) [82], SUN [61], aPY [21], and ZS-ImageNet [67, 24]. For the OD problem, COCO [50] and LVIS [29] represent two well established datasets to compare various OD methods in a single domain, while UODB [86] is a multi-domain OD benchmark.
+
+In contrast, our benchmark focuses on task-level transfer across domains, i.e., it aims to evaluate the transferability of models, by pre-training from their own large corpus, then evaluating zero-shot performance on a diverse set of downstream datasets. This setting has been recently studied [44, 66, 45, 92], and is arguably more practical for real-world applications, as it brings the convenience towards the spirit of one-model-for-all. The well-known ImageNet-1K dataset [14] was originally proposed as a large dataset for model training and testing. It has also recently been considered as one downstream task to study zero-shot transfer [66, 45, 92]. Our work presents the first public benchmark to standardize the zero-shot task-level transfer setting. Note that visual task transfer has been previously explored in VTAB [94], which measures good visual representations as those that adapt to diverse, unseen tasks with an emphasis on few training examples. The pre-trained models and task adaptation in VTAB are considered for vision backbones only, and no language model/modality is involved. Our benchmark shares a similar spirit of task-level transfer to VTAB, but
+
+| Problem | Benchmark Statistics | Evaluation |
| #Datasets | #Image | #Concepts | Knowledge Source | Zero | Few | Full | |
| Image Classification (IC) | AwA [43] | 1 | 30337 / 6985 | 40 / 10 | Attributes | ✓ | | |
| CUB [82] | 1 | 8855 / 2933 | 150 / 50 | Attributes | ✓ | | |
| SUN [61] | 1 | 12900 / 1440 | 645 / 72 | Attributes | ✓ | | |
| aPY [21] | 1 | 12695 / 2644 | 20 / 12 | Attributes | ✓ | | |
| ZS-ImageNet [67] | 1 | 1.2M / 54K | 1K / 360 | WordNet | ✓ | | |
| ImageNet-1K [14] | 1 | 1.2M / 50K | 1K | WordNet | ✓ | | ✓ |
| VTAB [94] | 19 | 2.2M / - | 940 | - | | ✓ | ✓ |
| ELEVATER (ICinW) | 20 | 638K / 193K | 1151◇ | WordNet, Wiki, GPT-3 | ✓ | ✓ | ✓ |
| Object Detection (OD) | COCO [50] | 1 | 83K / 41K | 80 | - | | | ✓ |
| LVIS [29] | 1 | 120K / 40K | 1723 | WordNet | | | ✓ |
| UODB [86] | 11 | 113K / 40K | 109 | - | | | ✓ |
| ELEVATER (ODinW) | 35 | 132K / 20K | 314◇ | WordNet, Wiki, GPT-3 | ✓ | ✓ | ✓ |
+
+Table 1: Comparison of dataset statistics and evaluation settings. For existing zero-shot datasets in IC, the number of images and concepts are reported for development / evaluation stages separately. $\diamond$ represents the total number of concepts in the benchmark to evaluate task-level transfer, and there is no train-evaluation category split as in class-level transfer.
+
+strives to analyze the vital role of language and knowledge in visual transfer. All of them are usually evaluated in full-shot settings, without considering task-level transfer. We have further made several novel contributions to consolidate the benchmark: (i) We add external knowledge for each dataset to cultivate new research directions in knowledge-augmented visual models, inspired by the success of knowledge in traditional class-level transfer. (ii) We consider the full spectrum in measuring the sample-efficiency of task adaptation, including zero-shot, few-shot, and full-shot.
+
+In this paper, we develop ELEVATER as a platform for "computer vision in the wild", whose ultimate goal is to develop a transferable foundation model/system that can effortlessly adapt to a large range of visual tasks in the wild. It consists of two key factors: (i) The task transfer cost is low., which is formally defined in Section 3.3, where our evaluation metrics is designed with efficiency considerations. (ii) The task transfer scenarios are broad. We illustrate and compare CVinW with other settings using a 2D chart in Figure 2, where the space is constructed with two orthogonal dimensions: input image and output concept. The 2D chart is divided into four quadrants, based on how the model evaluation stage is different from model development stage. Both training and evaluation distributions are consistent in both dimensions for the traditional close-set recognition. Open-set recognition allows new concepts in evalua
+
+tion, while typically remains the same visual domain [87, 93]; Domain shift allows new visual domain in evaluation, while typically remains the same concept pool [63, 28]. CVinW allows the flexibility in both dimensions, where any new tasks/datasets in the wild essentially fall into.
+
+
+Figure 2: Illustration of CVinW in comparison with close-set, open-set and domain shift.
+
+# 3 Benchmarks
+
+# 3.1 A Suite of Datasets with Language/Knowledge Augmentations
+
+As a proxy for performing unseen tasks in the wild, we collect a diverse set of public datasets from various domains in computer vision, as the basis of our benchmark. Specifically, we consider 20 datasets for IC and 35 datasets for OD. We exhibit the dataset names in Figure 3 (a), and the detailed statistics of each dataset in Table 5 and Table 6 in Appendix. It is recommended in [66] that studying task-level zero-shot transfer is a way of measuring the task learning capabilities of machine learning systems. The task definition of each downstream recognition dataset is typically specified using category names. Adding user specification/note is a natural way to clarify the task definition e.g., the attribute or explanation of a visual concept. Importantly, a similar spirit has been implemented
+
+
+(a) Dataset names. The font size is proportional to the number of concepts in each dataset.
+
+
+
+
+
+
+Concept name: risotto
+
+
+(b) Examples of collected external knowledge.
+
+
+Concept name: starfish
+Figure 3: Illustration of our benchmark. Left: Image classification, Right: Object detection.
+
+in traditional class-level zero-shot by adding individual domain-specific knowledge (see Table 1), and demonstrated promising zero-shot performance gains. In this paper, we generalize the notion of "zero-shot" to task-level, collecting external knowledge from general sources for our benchmark.
+
+- WordNet Hierarchy (def_path). The words along the traversal path from the query node in WordNet [56] to the highest parent node is recorded as the hierarchy knowledge.
+- WordNet Definition (def wn). The definition in WordNet synsets [56] is used to explain the query.
+- Wiktionary Definition (def_wik). The definition of a query in Wiktionary [55] is used.
+- GPT3 Knowledge (gpt3). For the above three knowledge sources, it is not always feasible to retrieve valid knowledge for any query. To enable full knowledge coverage, we propose to use GPT3 [6] to generate "pseudo" knowledge using in-context-learning, where prompts are constructed with multiple pairs of class names and their Wiktionary definitions. We generate five GPT3 knowledge sequences for each class name, by constructing different context prompts with randomly sampled pairs. See details in Section C.4.
+
+In Fig. 3 (b), we show examples to illustrate the knowledge sources. In practice, there is a trade-off between the knowledge quality and its coverage. For example, WordNet has relatively rich and precise knowledge, but the coverage is low; GPT3 knowledge has the full coverage (as it is generated via prompting a pre-trained neural language model), but it is hard to assess its quality. In the experiment section, we provide baseline results to demonstrate the benefits of external knowledge, and encourage the community to design advanced prompting techniques to leverage these knowledge sources.
+
+# 3.2 Pre-trained Models for Transfer Learning
+
+Industry Track and Academic Track. Our benchmark is an evaluation platform for pre-trained models, whose performance largely depends on the scale of the pre-training corpus. Larger corpus typically yields higher performance, but unfortunately results in a barrier to many participants, especially a majority of researchers from university labs. To increase inclusivity, we create two tracks with restrictions on the pre-training data scale: (i) Academic track is a setting that limits the data in established public large datasets (i.e., ImageNet-21K [14], GCC3M [70] & 12M [8], YFCC15M [78]). This track is more academic-friendly, aiming to encourage the exploration in data-efficient pre-training methodologies. (ii) Industry track has no limit on pre-training data scale, except that images in our benchmark are not allowed in pre-training when reporting zero-/few-shot performance. This track aims to explore the scaling limit. We encourage participants to report the pre-training datasets to enable reproducible research.
+
+Pre-trained Models. To establish baseline results on ELEVATER, we evaluate the pre-trained model checkpoints in Table 2. More details of the checkpoints are described in Appendix. Most existing visual models are language-free, where no text is used in model training. Till recently, visual
+
+| Checkpoints | Taxonomy | Pre-training Settings | Network Architecture |
| Language | Knowledge | Training Objective | Dataset | Vision | Language | Others |
| Image Classification |
| MoCo-v3 [10] | X | X | Self-Supervised | ImageNet-1K (1.2M) | ViT-B | - | - |
| MAE [30] | X | X | Self-Supervised | ImageNet-1K (1.2M) | ViT-B | - | - |
| DeiT [79] | X | X | Supervised | ImageNet-1K (1.2M) | ViT-B | - | - |
| ViT [18] | X | X | Supervised | ImageNet-22K (14M) | ViT-B | - | - |
| CLIP [66] | ✓ | X | Image-Text Contrast | WebImageText (400M) | ViT-B | T-B | - |
| UniCL [88] | ✓ | X | Image-Text Contrast | ImageNet-21K (13M) | Swin-T | T-B | - |
| K-LITE [71] | ✓ | ✓ | Image-Text Contrast | ImageNet-21K (13M) | Swin-T | T-B | - |
| Object Detection |
| DyHead [13] | X | X | Supervised | Object365 | Swin-T | - | - |
| GLIP [47] | ✓ | X | Supervised | Object365 & Grounding | Swin-T | Bert-B | Fusion |
| GLIP-A [47] | ✓ | X | Supervised | Object365 | Swin-T | Bert-B | - |
| K-LITE [71] | ✓ | ✓ | Supervised | Object365 | Swin-T | Bert-B | - |
+
+Table 2: The pre-trained models evaluated in ELEVATER as baselines. In terms of taxonomy, $\checkmark$ indicates the model checkpoint is pre-trained with the use of language / knowledge, while $\times$ indicates language- / knowledge-free. For image classification, the number of images in pre-training is reported. T-B indicate a Base-size Transformer architecture, using a 63M-parameter 12-layer 512-wide model with 8 attention heads. Swin-T is a Tiny-size Swin Transformer [52], Bert-B is a Base-size Bert [16], and Fusion indicates a cross-attention module to fuse the image-text features [47].
+
+models are trained in a language-augmented and/or knowledge-augmented manner using a language model [66, 88, 71, 47], among which CLIP [66] represents a strong baseline in the industry track. Please see the detailed taxonomy in Appendix Section G.1.
+
+# 3.3 Evaluation Settings: Efficiency Considerations
+
+One major advantage of pre-trained models is the promise that they can transfer to downstream tasks effortlessly. The cost is considered in two orthogonal dimensions: sample-efficiency and parameter-efficiency, as illustrated in Figure 4. The bottom-left corner and top-right corner is the most inexpensive and expensive adaptation strategy, respectively. One may interpolate and make combinations in the 2D space, to get different model adaptation methods with different cost.
+
+
+Figure 4: The model adaptation cost chart.
+
+Sample-efficiency: Zero-, Few-, and Full-shot. Due to the high cost of annotating data, it is often desired to provide a small number of labeled image-label pairs in downstream datasets. Transferable models should be able to reach high performance in this data-limited scenario. To assess this ability, we vary the number of training set size $N$ per category in the downstream dataset. For IC, $N = 0,5,20,50$ . For $\mathrm{OD}^2$ , $N = 0,1,3,5,10$ . Three random seeds are chosen, each of which identifies a subset of samples from the full dataset in a deterministic manner. Once the random seed is given, the indices of training samples in few-shot settings are fixed to encourage reproducible research. We also consider the full-shot setting, where all samples of a given dataset are used.
+
+Parameter-efficiency: Linear Probing vs Full Model Fine-tuning. Maintaining a small number of dataset-specific model parameters is often favored for model maintenance, as it can be expensive to maintain a unique copy of large model checkpoints for each of the thousands of downstream applications. In IC, linear probing provides a simple strategy for training a dataset-specific linear embedding matrix, while keeping the pre-trained visual backbone frozen. It arguably represents the minimum cost solution for parameter-efficiency. In contrast, fine-tuning often updates the entire weights in backbone and linear head, representing the most expensive solution to model adaptation.
+
+
+Figure 5: Illustrative comparison of different model evaluation and adaption methods.
+
+In OD [85], linear probing means updating the linear heads for classification and localization tasks only, while fine-tuning means updating all model weights including the backbone and the detectors.
+
+# 4 Toolkits
+
+To ease the process to onboard new checkpoints for evaluation, we provide a software toolkit, including $(i)$ automatic hyper-parameter tuning and $(ii)$ various strategies for model adaptation to downstream tasks. First, automatic hyper-parameter tuning pipeline is developed to avoid human-in-the-loop tuning, thus reducing human labor and ensuring fair comparisons of different model checkpoints. We follow CLIP [66] to implement a simple grid-search style tuning pipeline, and leave more sophisticated methods like BOHB [20] and DEHB [3] as future work. Details are provided in Appendix. Second, we provide several model adaptation methods as strong baselines, which allow effective transfer learning of pre-trained visual models. The ideas are illustrated in Figure 5. For a downstream dataset, we first represent it in a triplet-wise data format $\mathcal{D} = \{(x_{n},t_{n},y_{n})\}_{n = 1}^{N}$ , where $x\in \mathcal{X}$ is the image, $t\in \mathcal{T}$ is its corresponding language description, and $y\in \mathcal{Y}$ is a label indicating the index of the unique language description in the dataset. $|\mathcal{B}|$ is batch size. In IC, the number of labels $|\mathcal{V}| = K$ , i.e., the number of category names.
+
+Language-free Visual Models. Most existing visual models are language-free, as language is often not considered in training, e.g., supervised and self-supervised methods. Such models can not be directly used for zero-shot transfer, and model adaptation is often enabled by adding additional weights. For each image $\pmb{x}$ , an image encoder $f_{\theta}$ parameterized by $\pmb{\theta}$ first represents $\pmb{x}$ as a visual feature vector $\pmb{h} \in \mathbb{R}^{D \times 1}$ : $\pmb{h} = f_{\theta}(\pmb{x})$ . One randomly initialized linear projection layer with $\mathbf{W}_m \in \mathbb{R}^{D \times K}$ (we absorb the bias $\pmb{b}$ in $\mathbf{W}_m$ for simplicity) is used as the classifier; see Figure 5 (a).
+
+Language-augmented Visual Models. Recent works [66, 35] that learn visual models with language supervision often employ a two-encoder architecture. Besides the image encoder model $f_{\theta}$ , a text encoder $f_{\phi}(t)$ parameterized by $\phi$ is also used to encode text $t$ . Additional projection layers $\mathbf{W}_v$ and $\mathbf{W}_t$ are introduced for image and language features, embedding them into a joint space with dimension $P$ , with projected features as $\mathbf{u}$ and $\mathbf{v}$ respectively. Note that lowercase $\mathbf{u}$ and $\mathbf{v}$ are single feature vectors while $\mathbf{U}$ and $\mathbf{V}$ are a batch with multiple feature vectors. As in Figure 5 (b), zero-shot learning can be directly performed in this space: the mean text feature $\mathbf{v}$ is first obtained for each category, by averaging text features of the category name in different language prompts. The image is predicted as the category yielding the highest similarity $\mathbf{u}^{\top}\mathbf{v}$ .
+
+- Random initialized Adaptation. In the original CLIP paper [66], one randomly initialized linear projection layer $\mathbf{W} \in \mathbb{R}^{P \times K}$ (similarly, we absorb the bias $b$ in $\mathbf{W}$ for simplicity) is added on the pre-retained visual projection, which is shown as the two-projection method in Figure 5 (c).
+- Language-initialized Adaptation. We argue that the full capacity of language-augmented visual models is not leveraged in [66]. The power of pre-trained language encoder and text inputs must play a vital role in model adaptation. Hence, we propose two language-initialized adaption methods, each of which is ensured as a fair comparison variant for language-augmented and language-free models, respectively. (i) Two-Projection. For the linear head $\mathbf{W} \in \mathbb{R}^{P \times K}$ added on the projection space, we initialize $\mathbf{W}$ with $\mathbf{V}$ (bias terms are initialized as zeros), as shown in Figure 5 (d). In this way, the visual and text heads are separated. Note that the language-initialized Two-Projection
+
+scheme is also basically equivalent to Figure 5 (b) in zero-shot settings. Please see Appendix Section F for discussions. (ii) One-Projection. To fairly compare with language-free model adaptation in Figure 5 (a), one linear projection head should directly be added on the backbone (before the visual projection) to ensure that the same number of trainable parameters are updated. Therefore, we propose to initialize $\mathbf{W}_m\in \mathbb{R}^{D\times K}$ in this case with the multiplication result of two linear matrices $\mathbf{W}_v\mathbf{V}$ , as shown in Figure 5 (e).
+
+Discussion. We highly recommend the proposed language-initialized methods as the standard to adapt language-augmented visual models for two reasons: (i) This simple method yields surprisingly superior empirical performance, as demonstrated in our experiments. (ii) It provides an effective mechanism to leverage the external knowledge that is collected for a downstream task in our benchmark. Specifically, the knowledge can be concatenated with the original language prompt (with a simple “;” in our experiments), then encoded into contextualized text features. When multiple knowledge items exist (e.g., the case of GPT-3) for each concept, we concatenate one of its prompts and one of its knowledge items, and get the encoded text embedding of the concatenated sequence via the language encoder. This is performed for all the combinations between all prompts and knowledge items for this concept, then the averaged embedding is computed to represent the concept. In contrast, random initialization would ignore this knowledge source. The language-initialized method can serve as a strong baseline to encourage more effective knowledge-augmented adaptation methods.
+
+In OD, GLIP is a language-augmented detector, whose overall architecture can be simply considered as adding a cross-modal module over the CLIP-like dual-encoder. In GLIP [47], its linear probing has been implemented via updating $\mathbf{W}_v$ and $\mathbf{W}_t$ . A prompt-tuning strategy was proposed, by initializing the language input of the cross-modal module as $\mathbf{V}$ , and only updating $\mathbf{V}$ during adaptation. This is similar to our language-initialized strategy.
+
+# 5 Empirical Results and Findings
+
+We present the experimental results with our benchmark to illustrate two points. Q1: The importance of language in visual model transfer in the adaptation stage. Q2: We present three playgrounds that our benchmark can help to cultivate research in, including sample-efficiency, parameter-efficiency and external knowledge for visual transfer. We also present novel empirical findings.
+
+# 5.1 The Role of Language for Vision
+
+Effectiveness of Language-initialized Adaptation Methods. In Table 3, we compare the effectiveness of the proposed language-initialization methods with the checkpoint CLIP ViT-B32. The one-projection scheme is consistently better than two-projection scheme in all settings (though the gain is minor). This is because the former often has less parameters than the latter, as $\bar{D} = 768 > P = 512$ . To ensure fair comparisons with the random initialization of linear head in CLIP [66] (i.e., # trainable parameters is the same), in the ensuing experiments, we consider the two-projection language-initialization scheme as the default, unless the one-projection scheme is specified.
+
+As shown in Fig. 6, under both linear probe (LP) and fine-tuning (FT) settings, language-based initialization significantly outperforms random initialization. Notably, we show that even with very few shots (e.g., 2-shots), both our LP and FT is able to outperform the zero-shot CLIP. This is contradictory to the finding in the original CLIP paper [66], where zero-shot outperforms linear probing in the fewer shot (less than 4) settings. With the proposed language-init method, one can ensure that few-shot performance is always better than zero-shot, as we essentially reduce to zero-shot when zero iteration is updated in our language-init method. Moreover, we also find that with random initialization, FT performs significantly worse than LP under few-shot settings. However,
+
+
+Figure 6: Comparison of random- and language- initialized adaptation.
+
+with language-init, FT starts to outperform LP with more than 20 shots. Both findings demonstrate the proposed language-based initialization is consistently effective, suggesting that it is an important
+
+| Checkpoint | Settings | 20 IC datasets |
| Adaptation | Initialization | Zero-shot† | Few-shot (5, 20, 50) | Full |
| Industry Track (No pre-train data scale limit) |
| CLIP(ViT-B32) | LP | Random-2P | 56.64 | 58.09 ± 2.80, 69.97 ± 1.30, 74.09 ± 0.69 | 78.38 |
| LP | Language-2P | 65.35 ± 1.24, 71.69 ± 0.93, 74.89 ± 0.79 | 78.40 |
| LP | Language-1P | 65.88 ± 0.79, 72.05 ± 0.85, 75.08 ± 0.73 | 78.96 |
| FT | Random-2P | 29.75 ± 6.64, 46.76 ± 11.9, 61.70 ± 9.97 | 77.77 |
| FT | Language-2P | 63.29 ± 3.18, 72.19 ± 1.31, 75.70 ± 1.14 | 80.35 |
| Supervised(ViT-B32) | LP | Random-1P | - | 56.00 ± 2.67, 67.23 ± 1.66, 71.35 ± 1.17 | 75.29 |
| FT | Random-1P | 58.55 ± 2.58, 71.27 ± 1.25, 75.36 ± 1.42 | 80.39 |
| Academic Track (Pre-trained on large established public datasets) |
| UniCL(Swin-Tiny) | LP | Language-2P | 27.15 | 54.31 ± 4.15, 66.42 ± 2.08, 70.49 ± 1.01 | 74.75 |
| FT | Language-2P | 44.75 ± 5.42, 56.53 ± 5.37, 67.90 ± 5.31 | 78.48 |
| K-LITE(Swin-Tiny) | LP | Language-2P | 33.44 | 55.06 ± 2.36, 66.26 ± 1.56, 70.16 ± 1.09 | 74.47 |
| FT | Language-2P | 48.41 ± 2.84, 58.06 ± 4.30, 71.66 ± 2.02 | 78.05 |
+
+Table 3: Averaged results on 20 IC datasets using linear probing (LP) and fine-tuning (FT). Random-1P, Random-2P, Language-1P and Language-2P indicates the initialization method in Figure 5 (a), (c), (e) and (d), respectively. $\dagger$ Note that one zero-shot result is reported for each model checkpoint using the method in Figure 5 (b), which is independent from adaptation/initialization methods.
+
+| Checkpoint | Adaptation | 35 OD datasets |
| Zero-shot | Few-shot (1, 3, 5, 10) | Full |
| GLIP(Swin-Tiny) | Prompt | 19.7 | 29.7±0.4, 36.5±0.6, 39.0±1.1, 41.8±1.2 | 54.4 |
| LP | 22.2±0.1, 24.4±0.2, 25.1±0.2, 25.6±0.6 | 35.2 |
| FT | 32.2±0.7, 39.2±0.3, 42.5±0.9, 49.1±0.6 | 63.2 |
| DyHead(Swin-Tiny) | LP | - | 15.2±0.6, 19.2±0.9, 19.8±1.0, 20.6±1.1 | 31.4 |
| FT | 25.6±0.4, 37.1±0.5, 40.1±1.5, 44.6±0.7 | 63.9 |
+
+Table 4: Averaged results on 35 OD datasets.
+
+technique, and should be the standard adaptation method for language-augmented visual models like CLIP. Further, the correct adaptation methods for language-augmented visual models should leverage both the pre-trained visual and text encoder. It is not sufficient to solely transfer from the visual encoder, pre-trained language encoder plays an important role in task transfer.
+
+The Competition of Pre-trained Models: Language-free vs Language-augmented. We summarize the transfer performance of pre-trained models for IC in Table 3 and OD in Table 4. For IC, we also compare CLIP against other language-free visual models including MoCov3, MAE, ViT, DeiT in Appendix. We see that the language-augmented model (CLIP) outperforms language-free model (Supervised ViT) in the limited data settings. The gap is closed when more training examples are observed (e.g., 50-shot and full-shot). This is probably because the pre-training power is gradually dominated by larger-scale downstream training. Further, language-augmented models are able to perform zero-shot task transfer, while traditional language-free models cannot. Similar conclusions can be drawn for OD in Table 4. Hence, we recommend the use of language-augmented visual models for task-level transfer.
+
+# 5.2 Playground I: Sample Efficiency
+
+We explore sample efficiency in Fig. 7 (a) for IC. First, we find that CLIP consistently outperforms supervised ViT (Sup-ViT), yielding a significant $5\sim 10\%$ gain in the 5-shot settings. This suggests that CLIP is more sample-efficient than supervised ViT. Furthermore, we find that fine-tuning CLIP yields better performance than linear probing in $>20$ -shot settings, while being worse in the 5-shot setting. This is a bit surprising, as it is contradictory to the common convention that fine-tuning is always better than linear probing. We hypothesize this is because fine-tuning tends to over-fit in the scenarios with a large number of trainable parameters and a small number of training samples. Overall, it suggests that fine-tuning CLIP potentially has a better sample efficiency than linear probing, and a better adaptation strategy on fewer-shot settings can be explored in the future. For supervised ViT, FT is always better than LP, the performance gap becomes larger when more samples are used. In 5-shot settings, the gap is minor, which is similar to observations made for supervised CNNs [91, 37, 38]. To compare pre-trained models, we suggest to report the evaluation results on the entire spectrum of sample-efficiency to fully study the behaviors of a pre-trained model. If compute resource is limited, zero-shot or few-shot evaluation can be used as a quick assessment.
+
+
+(a) IC: Sample Efficiency
+
+
+(b) OD: Sample Efficiency
+
+
+(c) IC: Parameter Efficiency
+
+
+(d) OD: Parameter Efficiency
+Figure 7: Adaptation efficiency considerations. For IC, comparison of adaptation efficiency between CLIP and supervised ViT (Sup-ViT). For OD, comparison of adaptation efficiency between GLIP and DyHead.
+
+We explore sample efficiency for OD in Fig. 7 (b). The conclusion is similar to IC in that the language-augmented visual model (GLIP) is more sample-efficient than the language-free visual model (DyHead), when the models are adapted using either LP or FT settings. The performance gap is large in the fewer-shot settings and is small in the full-shot settings. The difference is that FT consistently outperforms LP in all settings for OD. This is probably because there are a lot of boxes (training instances) per image in OD, which makes OD less likely to over-fit compared to IC.
+
+# 5.3 Playground II: Parameter Efficiency
+
+We study the parameter efficiency in Fig. 7 (c) for IC. For CLIP, we experiment with two different settings of linear probing on whether to merge the last two linear projection layers $(\mathbf{W}_v$ and $\mathbf{V}$ in Fig. 5). Merging these two layers in CLIP allows $1.5\times$ trainable parameters in the linear probe classifier as keeping them separated. First, it shows a trend that a larger number of trainable parameters leads to better performance, as demonstrated by three curves/scenarios: full-shot CLIP, full-shot Sup-ViT and 5-shot Sup-ViT. This also verifies that LP and FT provide the lower bound and upper bound, respectively, in terms of both #parameter and performance. Most existing parameter-efficient adaptation methods play a trade-off game. However, in the scenario of 5-shot CLIP, we do notice a slight drop in performance when we further increase the number of trainable parameters to full-model fine-tuning. It suggests that the scenario of adapting language-augmented visual models for data-limited settings is a more meaningful playground to explore the line of research in parameter-efficient adaptation methods, as the best performance may require an optimal number of trainable parameters, which has been less explored.
+
+We study the parameter efficiency in Fig. 7 (d) for OD. The overall trend is similar in that better performance comes with more parameters. It turns out that prompt tuning an language-augmented OD model is an effective parameter-efficient approach. For example, prompting is better than linear
+
+
+(a) Image classification
+
+
+(b) Object detection
+Figure 8: Zero-shot task transfer with various external knowledge sources in the evaluation stage. In (a) and (b), a varying number of generated GPT-3 knowledge sequences is utilized for inference, and "Wiki-and-GPT3" indicates both Wiktionary and GPT3 knowledge are used simultaneously. The bottom table summarizes the prediction result for each knowledge source.
+
+| Problem | Model | Baseline | External Knowledge Sources in Evaluation |
| wn_path | wn_def | wiki_def | gpt3 | wiki_def & gpt3 |
| IC | UniCL | 27.15 | 30.68 | 29.92 | 33.44 | 33.73 | 33.95 |
| OD | GLIP-A | 11.53 | 12.43 | 11.70 | 13.14 | 11.98 | 13.30 |
+
+probing in GLIP. Further, prompt tuning GLIP outperforms fine-tuning DyHead in the 1-shot setting, where the former has less than $0.1\%$ parameters of the latter.
+
+# 5.4 Playground III: The Benefit of External Knowledge for Vision
+
+We investigate the effectiveness of external knowledge in Fig. 8, measured by zero-shot task transfer performance. The model K-LITE is evaluated, as its pre-training is knowledge-augmented. We find that leveraging external knowledge improves upon the knowledge-free pre-training counterparts (UniCL and GLIP). For example, UniCL is improved from 27.15 to $29.92\sim 33.93$ and GLIP-A is improved from 11.53 to $11.70\sim 13.30$ . Further, for GPT3 knowledge, a larger number of generated knowledge items often leads to higher performance. When combining GPT3 knowledge with Wiktionary knowledge, we see a further performance boost. With an increasing number of GPT3 knowledge items, the gain is consistently improved for IC, but not for OD. In Table 3, we study the role of knowledge for task transfer in model adaptation. Initializing the linear head using features encoded with knowledge is an effective way to leverage the collected knowledge sources, especially for the fewer-shot settings.
+
+One may wonder if the collected knowledge in ELEVATER benchmark can also benefit knowledge-free pre-trained models such as CLIP during model adaptation? We confirm its effectiveness in Appendix. In zero-shot transfer, external knowledge improves the baseline on four datasets. In few- and full-shot transfer, one may selectively choose whether to update the model using external knowledge, by observing the best performance in the auto-tuning stage. This selective strategy with the availability of external knowledge demonstrates a consistent improvement (or tie) on $15+$ out of 20 datasets.
+
+# 6 Conclusions
+
+We have presented ELEVATER, a platform to evaluate the recently emerging language-augmented visual models for task-level transfer. It consists of 20 image classification datasets and 35 object detection datasets. All of them are collected from public domains, and are enriched with various external knowledge sources to enhance the language modality. We have developed open-source toolkits with an auto hyper-parameter pipeline and novel language-initialized adaptation methods to ensure easy utilization and fair comparisons. Strong baseline results are produced from the toolkit to cultivate research in a variety of topics, e.g., more transferable language-augmented visual models, advanced model adaption methods (sample-efficiency and parameter-efficiency), and external knowledge for task-level transfer. The question of how to design general-purpose task-level transferable visual models remains largely unanswered. Given benchmarks and toolkits we have developed from the perspective of language-augmented visual models, we believe that ELEVATER can provide fertile soil for addressing this challenge.
+
+# Acknowledgments
+
+The authors gratefully acknowledge Haotian Zhang for building the ODinW leaderboard on Eval AI, Pengcheng He for helpful discussions to have a separate track dedicated for users from academia, Baolin Peng and and Zhengyuan Yang for the inspirations of GPT3 to generate knowledge for dialogue and OK-VQA tasks, Bo Li for insights on the topic of domain generalization, Zhuowen Tu for the inspirations to make benchmark scope wider to measure all pre-trained vision models, Ce Liu for suggestions to compare the benchmark with well-established vision datasets such as ImageNet and COCO. The benchmark depends on publicly available datasets; we acknowledge all the original authors who made their datasets public. Please follow the original license of each dataset and keep this benchmark for academic purposes. This work was supported in part by NSF CAREER IIS-2150012, the Wisconsin Alumni Research Foundation, and Institute of Information & communications Technology Planning & Evaluation(IITP) grants funded by the Korea government(MSIT) (No. 2022-0-00871, Development of AI Autonomy and Knowledge Enhancement for AI Agent Collaboration) and (No. RS-2022-00187238, Development of Large Korean Language Model Technology for Efficient Pre-training).
+
+# References
+
+[1] FER 2013: Kaggle challenges in representation learning facial expression recognition. https://www.kaggle.com/.
+[2] Stanislaw Antol, Aishwarya Agrawal, Jiasen Lu, Margaret Mitchell, Dhruv Batra, C Lawrence Zitnick, and Devi Parikh. VQA: Visual question answering. In ICCV, 2015.
+[3] Noor Awad, Neeratyoy Mallik, and Frank Hutter. Dehb: Evolutionary hyperband for scalable, robust and efficient hyperparameter optimization. arXiv preprint arXiv:2105.09821, 2021.
+[4] Sven Bambach, Stefan Lee, David Crandall, and Chen Yu. Lending a hand: Detecting hands and recognizing activities in complex egocentric interactions. In ICCV, 2015.
+[5] Lukas Bossard, Matthieu Guillaumin, and Luc Van Gool. Food-101-mining discriminative components with random forests. In ECCV, 2014.
+[6] Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. NeurIPS, 2020.
+[7] Emanuele Bugliarello, Fangyu Liu, Jonas Pfeiffer, Siva Reddy, Desmond Elliott, Edoardo Maria Ponti, and Ivan Vulic. Iglue: A benchmark for transfer learning across modalities, tasks, and languages. arXiv preprint arXiv:2201.11732, 2022.
+[8] Soravit Changpinyo, Piyush Sharma, Nan Ding, and Radu Soricut. Conceptual 12m: Pushing web-scale image-text pre-training to recognize long-tail visual concepts. In CVPR, 2021.
+[9] Xiaokang Chen, Mingyu Ding, Xiaodi Wang, Ying Xin, Shentong Mo, Yunhao Wang, Shumin Han, Ping Luo, Gang Zeng, and Jingdong Wang. Context autoencoder for self-supervised representation learning. arXiv preprint arXiv:2202.03026, 2022.
+[10] Xinlei Chen, Saining Xie, and Kaiming He. An empirical study of training self-supervised visual transformers. ICCV, 2021.
+[11] Gong Cheng, Junwei Han, and Xiaoqiang Lu. Remote sensing image scene classification: Benchmark and state of the art. Proceedings of the IEEE, 2017.
+[12] Mircea Cimpoi, Subhransu Maji, Iasonas Kokkinos, Sammy Mohamed, and Andrea Vedaldi. Describing textures in the wild. In CVPR, 2014.
+[13] Xiyang Dai, Yinpeng Chen, Bin Xiao, Dongdong Chen, Mengchen Liu, Lu Yuan, and Lei Zhang. Dynamic head: Unifying object detection heads with attentions. In CVPR, 2021.
+[14] Jia Deng, Wei Dong, Richard Socher, Li-Jia Li, Kai Li, and Li Fei-Fei. ImageNet: A large-scale hierarchical image database. In CVPR, 2009.
+[15] Li Deng. The MNIST database of handwritten digit images for machine learning research. IEEE signal processing magazine, 2012.
+
+[16] Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805, 2018.
+[17] Carl Doersch, Abhinav Gupta, and Alexei A Efros. Unsupervised visual representation learning by context prediction. In Proceedings of the IEEE international conference on computer vision, pages 1422-1430, 2015.
+[18] Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, et al. An image is worth 16x16 words: Transformers for image recognition at scale. arXiv preprint arXiv:2010.11929, 2020.
+[19] Mark Everingham, Luc Van Gool, Christopher KI Williams, John Winn, and Andrew Zisserman. The pascal visual object classes (VOC) challenge. IJCV, 2010.
+[20] Stefan Falkner, Aaron Klein, and Frank Hutter. Bohb: Robust and efficient hyperparameter optimization at scale. In International Conference on Machine Learning, pages 1437-1446. PMLR, 2018.
+[21] Ali Farhadi, Ian Endres, Derek Hoiem, and David Forsyth. Describing objects by their attributes. In CVPR, 2009.
+[22] Li Fei-Fei, Rob Fergus, and Pietro Perona. Learning generative visual models from few training examples: An incremental Bayesian approach tested on 101 object categories. In CVPR workshop, 2004.
+[23] Jannik Fritsch, Tobias Kuehl, and Andreas Geiger. A new performance measure and evaluation benchmark for road detection algorithms. In ITSC. IEEE, 2013.
+[24] Yanwei Fu and Leonid Sigal. Semi-supervised vocabulary-informed learning. In CVPR, 2016.
+[25] Peng Gao, Shijie Geng, Renrui Zhang, Teli Ma, Rongyao Fang, Yongfeng Zhang, Hongsheng Li, and Yu Qiao. CLIP-adapter: Better vision-language models with feature adapters. arXiv preprint arXiv:2110.04544, 2021.
+[26] Andreas Geiger, Philip Lenz, Christoph Stiller, and Raquel Urtasun. Vision meets robotics: The kitti dataset. *IJRR*, 2013.
+[27] Xiuye Gu, Tsung-Yi Lin, Weicheng Kuo, and Yin Cui. Zero-shot detection via vision and language knowledge distillation. arXiv preprint arXiv:2104.13921, 2021.
+[28] Ishaan Gulrajani and David Lopez-Paz. In search of lost domain generalization. arXiv preprint arXiv:2007.01434, 2020.
+[29] Agrim Gupta, Piotr Dollar, and Ross Girshick. LVIS: A dataset for large vocabulary instance segmentation. In CVPR, 2019.
+[30] Kaiming He, Xinlei Chen, Saining Xie, Yanghao Li, Piotr Dollár, and Ross Girshick. Masked autoencoders are scalable vision learners. arXiv preprint arXiv:2111.06377, 2021.
+[31] Patrick Helber, Benjamin Bischke, Andreas Dengel, and Damian Borth. EuroSat: A novel dataset and deep learning benchmark for land use and land cover classification. IEEE Journal of Selected Topics in Applied Earth Observations and Remote Sensing, 2019.
+[32] Neil Houlsby, Andrei Giurgiu, Stanislaw Jastrzebski, Bruna Morrone, Quentin De Laroussilhe, Andrea Gesmundo, Mona Attariyan, and Sylvain Gelly. Parameter-efficient transfer learning for nlp. In ICML, 2019.
+[33] Gabriel Ilharco, Mitchell Wortsman, Ross Wightman, Cade Gordon, Nicholas Carlini, Rohan Taori, Achal Dave, Vaishaal Shankar, Hongseok Namkoong, John Miller, Hannaneh Hajishirzi, Ali Farhadi, and Ludwig Schmidt. OpenCLIP, July 2021.
+[34] Sergey Ioffe and Christian Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In International conference on machine learning, pages 448-456. PMLR, 2015.
+[35] Chao Jia, Yinfei Yang, Ye Xia, Yi-Ting Chen, Zarana Parekh, Hieu Pham, Quoc V Le, Yunhsuan Sung, Zhen Li, and Tom Duerig. Scaling up visual and vision-language representation learning with noisy text supervision. arXiv preprint arXiv:2102.05918, 2021.
+[36] Menglin Jia, Luming Tang, Bor-Chun Chen, Claire Cardie, Serge Belongie, Bharath Hariharan, and Ser-Nam Lim. Visual prompt tuning. arXiv preprint arXiv:2203.12119, 2022.
+
+[37] Sergey Karayev, Matthew Trentacoste, Helen Han, Aseem Agarwala, Trevor Darrell, Aaron Hertzmann, and Holger Winnemoeller. Recognizing image style. arXiv preprint arXiv:1311.3715, 2013.
+[38] Nikolaos Karianakis, Zicheng Liu, Yinpeng Chen, and Stefano Soatto. Reinforced temporal attention and split-rate transfer for depth-based person re-identification. In ECCV, 2018.
+[39] Douwe Kiela, Hamed Firooz, Aravind Mohan, Vedanuj Goswami, Amanpreet Singh, Pratik Ringshia, and Davide Testuggine. The hateful memes challenge: Detecting hate speech in multimodal memes. NeurIPS, 2020.
+[40] Jonathan Krause, Michael Stark, Jia Deng, and Li Fei-Fei. 3d object representations for fine-grained categorization. In ICCV workshops, 2013.
+[41] Alex Krizhevsky, Geoffrey Hinton, et al. Learning multiple layers of features from tiny images. 2009.
+[42] Christoph H Lampert, Hannes Nickisch, and Stefan Harmeling. Learning to detect unseen object classes by between-class attribute transfer. In CVPR, 2009.
+[43] Christoph H Lampert, Hannes Nickisch, and Stefan Harmeling. Attribute-based classification for zero-shot visual object categorization. PAMI, 2013.
+[44] Ang Li, Allan Jabri, Armand Joulin, and Laurens Van Der Maaten. Learning visual N-grams from web data. In ICCV, 2017.
+[45] Junnan Li, Ramprasaath R Selvaraju, Akhilesh Deepak Gotmare, Shafiq Joty, Caiming Xiong, and Steven Hoi. Align before fuse: Vision and language representation learning with momentum distillation. arXiv preprint arXiv:2107.07651, 2021.
+[46] Linjie Li, Jie Lei, Zhe Gan, Licheng Yu, Yen-Chun Chen, Rohit Pillai, Yu Cheng, Luowei Zhou, Xin Eric Wang, William Yang Wang, et al. Value: A multi-task benchmark for video-and-language understanding evaluation. arXiv preprint arXiv:2106.04632, 2021.
+[47] Liunian Harold Li, Pengchuan Zhang, Haotian Zhang, Jianwei Yang, Chunyuan Li, Yiwu Zhong, Lijuan Wang, Lu Yuan, Lei Zhang, Jenq-Neng Hwang, et al. Grounded language-image pre-training. CVPR, 2022.
+[48] Xiang Lisa Li and Percy Liang. Prefix-tuning: Optimizing continuous prompts for generation. arXiv preprint arXiv:2101.00190, 2021.
+[49] Yangguang Li, Feng Liang, Lichen Zhao, Yufeng Cui, Wanli Ouyang, Jing Shao, Fengwei Yu, and Junjie Yan. Supervision exists everywhere: A data efficient contrastive language-image pre-training paradigm. arXiv preprint arXiv:2110.05208, 2021.
+[50] Tsung-Yi Lin, Michael Maire, Serge Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dólar, and C Lawrence Zitnick. Microsoft COCO: Common objects in context. In ECCV, 2014.
+[51] Pengfei Liu, Weizhe Yuan, Jinlan Fu, Zhengbao Jiang, Hiroaki Hayashi, and Graham Neubig. Pre-train, prompt, and predict: A systematic survey of prompting methods in natural language processing. arXiv preprint arXiv:2107.13586, 2021.
+[52] Ze Liu, Yutong Lin, Yue Cao, Han Hu, Yixuan Wei, Zheng Zhang, Stephen Lin, and Baining Guo. Swin transformer: Hierarchical vision transformer using shifted windows. ICCV, 2021.
+[53] Subhransu Maji, Esa Rahtu, Juho Kannala, Matthew Blaschko, and Andrea Vedaldi. Fine-grained visual classification of aircraft. arXiv preprint arXiv:1306.5151, 2013.
+[54] Kenneth Marino, Mohammad Rastegari, Ali Farhadi, and Roozbeh Mottaghi. OK-VQA: A visual question answering benchmark requiring external knowledge. In CVPR, 2019.
+[55] Christian M Meyer and Iryna Gurevych. Wiktionary: A new rival for expert-built lexicons? Exploring the possibilities of collaborative lexicography. 2012.
+[56] George A Miller. WordNet: An electronic lexical database. MIT press, 1998.
+[57] Norman Mu, Alexander Kirillov, David Wagner, and Saining Xie. SLIP: Self-supervision meets language-image pre-training. arXiv preprint arXiv:2112.12750, 2021.
+[58] Yuval Netzer, Tao Wang, Adam Coates, Alessandro Bissacco, Bo Wu, and Andrew Y Ng. Reading digits in natural images with unsupervised feature learning. 2011.
+
+[59] Maria-Elena Nilsback and Andrew Zisserman. Automated flower classification over a large number of classes. In Indian Conference on Computer Vision, Graphics & Image Processing. IEEE, 2008.
+[60] Omkar M Parkhi, Andrea Vedaldi, Andrew Zisserman, and CV Jawahar. Cats and dogs. In CVPR, 2012.
+[61] Genevieve Patterson and James Hays. SUN attribute database: Discovering, annotating, and recognizing scene attributes. In CVPR, 2012.
+[62] Malte Pedersen, Joakim Bruslund Haurum, Rikke Gade, Thomas B. Moeslund, and Niels Madsen. Detection of marine animals in a new underwater dataset with varying visibility. In CVPR Workshops, 2019.
+[63] Xingchao Peng, Qinxun Bai, Xide Xia, Zijun Huang, Kate Saenko, and Bo Wang. Moment matching for multi-source domain adaptation. In Proceedings of the IEEE/CVF international conference on computer vision, pages 1406-1415, 2019.
+[64] Fabio Petroni, Aleksandra Piktus, Angela Fan, Patrick Lewis, Majid Yazdani, Nicola De Cao, James Thorne, Yacine Jernite, Vladimir Karpukhin, Jean Maillard, et al. KILT: a benchmark for knowledge intensive language tasks. arXiv preprint arXiv:2009.02252, 2020.
+[65] Bryan A Plummer, Liwei Wang, Chris M Cervantes, Juan C Caicedo, Julia Hockenmaier, and Svetlana Lazebnik. Flickr30k entities: Collecting region-to-phrase correspondences for richer image-to-sentence models. In ICCV, 2015.
+[66] Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, et al. Learning transferable visual models from natural language supervision. In ICML, 2021.
+[67] Marcus Rohrbach, Michael Stark, and Bernt Schiele. Evaluating knowledge transfer and zero-shot learning in a large-scale setting. In CVPR, 2011.
+[68] Victor Sanh, Albert Webson, Colin Raffel, Stephen H Bach, Lintang Sutawika, Zaid Alyafeai, Antoine Chaffin, Arnaud Stiegler, Teven Le Scao, Arun Raja, et al. Multitask prompted training enables zero-shot task generalization. arXiv preprint arXiv:2110.08207, 2021.
+[69] Shuai Shao, Zeming Li, Tianyuan Zhang, Chao Peng, Gang Yu, Xiangyu Zhang, Jing Li, and Jian Sun. Objects365: A large-scale, high-quality dataset for object detection. In ICCV, 2019.
+[70] Piyush Sharma, Nan Ding, Sebastian Goodman, and Radu Soricut. Conceptual captions: A cleaned, hypernymed, image alt-text dataset for automatic image captioning. In ACL, 2018.
+[71] Sheng Shen, Chunyuan Li, Xiaowei Hu, Yujia Xie, Jianwei Yang, Pengchuan Zhang, Anna Rohrbach, Zhe Gan, Lijuan Wang, Lu Yuan, Ce Liu, Kurt Keutzer, Trevor Darrell, and Jianfeng Gao. K-LITE: Learning transferable visual models with external knowledge. In NeurIPS, 2022.
+[72] Davinder Singh, Naman Jain, Pranjali Jain, Pratik Kayal, Sudhakar Kumawat, and Nipun Batra. PlantDoc: A dataset for visual plant disease detection, 2019.
+[73] Khurram Soomro, Amir Roshan Zamir, and Mubarak Shah. Ucf101: A dataset of 101 human actions classes from videos in the wild. arXiv preprint arXiv:1212.0402, 2012.
+[74] Johannes Stallkamp, Marc Schlipsing, Jan Salmen, and Christian Igel. The german traffic sign recognition benchmark: a multi-class classification competition. In IJCNN, 2011.
+[75] Yi-Lin Sung, Jaemin Cho, and Mohit Bansal. VL-adapter: Parameter-efficient transfer learning for vision-and-language tasks. CVPR, 2022.
+[76] Richard Szeliski. Computer vision: algorithms and applications. Springer Science & Business Media, 2010.
+[77] Hao Tan and Mohit Bansal. Vokenization: Improving language understanding with contextualized, visual-grounded supervision. arXiv preprint arXiv:2010.06775, 2020.
+[78] Bart Thomee, David A Shamma, Gerald Friedland, Benjamin Elizalde, Karl Ni, Douglas Poland, Damian Borth, and Li-Jia Li. YFCC100M: The new data in multimedia research. Communications of the ACM, 2016.
+[79] Hugo Touvron, Matthieu Cord, Matthijs Douze, Francisco Massa, Alexandre Sablayrolles, and Hervé Jégou. Training data-efficient image transformers & distillation through attention. In International Conference on Machine Learning, pages 10347-10357. PMLR, 2021.
+
+[80] Bastiaan S Veeling, Jasper Linmans, Jim Winkens, Taco Cohen, and Max Welling. Rotation equivariant CNNs for digital pathology. June 2018.
+[81] Bastiaan S Veeling, Jasper Linmans, Jim Winkens, Taco Cohen, and Max Welling. Rotation equivariant cnns for digital pathology. In MICCAI, 2018.
+[82] Catherine Wah, Steve Branson, Peter Welinder, Pietro Perona, and Serge Belongie. The Caltech-UCSD birds-200-2011 dataset. 2011.
+[83] Alex Wang, Yada Pruksachatkun, Nikita Nangia, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel Bowman. SuperGLUE: A stickier benchmark for general-purpose language understanding systems. NeurIPS, 2019.
+[84] Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel R Bowman. GLUE: A multi-task benchmark and analysis platform for natural language understanding. arXiv preprint arXiv:1804.07461, 2018.
+[85] Xin Wang, Thomas E Huang, Trevor Darrell, Joseph E Gonzalez, and Fisher Yu. Frustratingly simple few-shot object detection. arXiv preprint arXiv:2003.06957, 2020.
+[86] Xudong Wang, Zhaowei Cai, Dashan Gao, and Nuno Vasconcelos. Towards universal object detection by domain attention. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 7289-7298, 2019.
+[87] Yongqin Xian, Christoph H Lampert, Bernt Schiele, and Zeynep Akata. Zero-shot learning—a comprehensive evaluation of the good, the bad and the ugly. PAMI, 2018.
+[88] Jianwei Yang, Chunyuan Li, Pengchuan Zhang, Bin Xiao, Lu Yuan, Ce Liu, and Jianfeng Gao. UniCL: unified contrastive learning in image-text-label space. CVPR, 2022.
+[89] Lewei Yao, Runhui Huang, Lu Hou, Guansong Lu, Minzhe Niu, Hang Xu, Xiaodan Liang, Zhenguo Li, Xin Jiang, and Chunjing Xu. FILIP: Fine-grained interactive language-image pre-training. arXiv preprint arXiv:2111.07783, 2021.
+[90] Yuan Yao, Ao Zhang, Zhengyan Zhang, Zhiyuan Liu, Tat-Seng Chua, and Maosong Sun. CPT: Colorful prompt tuning for pre-trained vision-language models. arXiv preprint arXiv:2109.11797, 2021.
+[91] Jason Yosinski, Jeff Clune, Yoshua Bengio, and Hod Lipson. How transferable are features in deep neural networks? NIPS, 2014.
+[92] Lu Yuan, Dongdong Chen, Yi-Ling Chen, Noel Codella, Xiyang Dai, Jianfeng Gao, Houdong Hu, Xuedong Huang, Boxin Li, Chunyuan Li, et al. Florence: A new foundation model for computer vision. arXiv preprint arXiv:2111.11432, 2021.
+[93] Alireza Zareian, Kevin Dela Rosa, Derek Hao Hu, and Shih-Fu Chang. Open-vocabulary object detection using captions. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 14393-14402, 2021.
+[94] Xiaohua Zhai, Joan Puigcerver, Alexander Kolesnikov, Pierre Ruyssen, Carlos Riquelme, Mario Lucic, Josip Djolonga, Andre Susano Pinto, Maxim Neumann, Alexey Dosovitskiy, et al. A large-scale study of representation learning with the visual task adaptation benchmark. arXiv preprint arXiv:1910.04867, 2019.
+[95] Yiwu Zhong, Jianwei Yang, Pengchuan Zhang, Chunyuan Li, Noel Codella, Lianian Harold Li, Luowei Zhou, Xiyang Dai, Lu Yuan, Yin Li, et al. RegionCLIP: Region-based language-image pretraining. CVPR, 2022.
+[96] Kaiyang Zhou, Jingkang Yang, Chen Change Loy, and Ziwei Liu. Conditional prompt learning for vision-language models. arXiv preprint arXiv:2203.05557, 2022.
+[97] Wangchunshu Zhou, Yan Zeng, Shizhe Diao, and Xinsong Zhang. Vlue: A multi-task multi-dimension benchmark for evaluating vision-language pre-training. In International Conference on Machine Learning, pages 27395-27411. PMLR, 2022.
\ No newline at end of file
diff --git a/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/images.zip b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..41662ccf6d280791532c3642f7cb55dadf77291e
--- /dev/null
+++ b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0e92bfccdbd2850edb4d0a53e19d9e577b3b91dab2b856a353f39f2ada4e30b9
+size 710797
diff --git a/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/layout.json b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..20d6ff6fb402406dee70b33c1e3cc58b6d5be3cb
--- /dev/null
+++ b/elevaterabenchmarkandtoolkitforevaluatinglanguageaugmentedvisualmodels/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:447c26526c9fd2de59a09a4ed1c080ebba3b1500c3da657901f1fbd09831c0b6
+size 435171
diff --git a/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/6d649c51-eafe-4414-8e5d-73bbd59324a2_content_list.json b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/6d649c51-eafe-4414-8e5d-73bbd59324a2_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..a49f0e55f6269342223d089225613ab680936cee
--- /dev/null
+++ b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/6d649c51-eafe-4414-8e5d-73bbd59324a2_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3743202e044c7227fdd75c448a11eb7ad58a18efcd6b74be205e03a3e5e420da
+size 80616
diff --git a/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/6d649c51-eafe-4414-8e5d-73bbd59324a2_model.json b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/6d649c51-eafe-4414-8e5d-73bbd59324a2_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..dda62cceff2ef4984335269637854537d30c3188
--- /dev/null
+++ b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/6d649c51-eafe-4414-8e5d-73bbd59324a2_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:10124ae1f6d28a5c4d2e1793ffcb18542bf78bf5d6e7fd539260e55ee9779b1f
+size 94344
diff --git a/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/6d649c51-eafe-4414-8e5d-73bbd59324a2_origin.pdf b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/6d649c51-eafe-4414-8e5d-73bbd59324a2_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..16615dddae206609f9e49c4ac88002fbb425fa7b
--- /dev/null
+++ b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/6d649c51-eafe-4414-8e5d-73bbd59324a2_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:57ac11ca9350ba20716d0d35433d7e2dfce95354edc640d36c3013b45cdcb9b9
+size 3087462
diff --git a/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/full.md b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..1efecad62a08c3a710e6781df7934d7ea24dd806
--- /dev/null
+++ b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/full.md
@@ -0,0 +1,269 @@
+# ELIAS: End-to-End Learning to Index and Search in Large Output Spaces
+
+Nilesh Gupta
+
+UT Austin
+
+nilesh@cs.utexas.edu
+
+Patrick H. Chen
+
+UCLA
+
+patrickchen@g.ucla.edu
+
+Hsiang-Fu, Yu *
+
+Amazon
+
+rofu.yu@gmail.com
+
+Cho-Jui, Hsieh
+
+UCLA
+
+chohsieh@cs.ucla.edu
+
+Inderjit S. Dhillon
+
+UT Austin & Google
+
+inderjit@cs.utexas.edu
+
+# Abstract
+
+Extreme multi-label classification (XMC) is a popular framework for solving many real-world problems that require accurate prediction from a very large number of potential output choices. A popular approach for dealing with the large label space is to arrange the labels into a shallow tree-based index and then learn an ML model to efficiently search this index via beam search. Existing methods initialize the tree index by clustering the label space into a few mutually exclusive clusters based on pre-defined features and keep it fixed throughout the training procedure. This approach results in a sub-optimal indexing structure over the label space and limits the search performance to the quality of choices made during the initialization of the index. In this paper, we propose a novel method ELIAS which relaxes the tree-based index to a specialized weighted graph-based index which is learned end-to-end with the final task objective. More specifically, ELIAS models the discrete cluster-to-label assignments in the existing tree-based index as soft learnable parameters that are learned jointly with the rest of the ML model. ELIAS achieves state-of-the-art performance on several large-scale extreme classification benchmarks with millions of labels. In particular, ELIAS can be up to $2.5\%$ better at precision@1 and up to $4\%$ better at recall@100 than existing XMC methods. A PyTorch implementation of ELIAS along with other resources is available at https://github.com/nilesh2797/ELIAS.
+
+# 1 Introduction
+
+Many real-world problems require making accurate predictions from a large number of potential output choices. For example, search advertising aims to find the most relevant ads to a given search query from a large corpus of ads [26, 14], open-domain question answering requires finding the right answers to a given question from a large collection of text documents [8, 29], and product recommendation requires recommending similar or related products from a large product catalog, based on past searches and interactions by users. eXtreme Multi-label Classification (XMC) is a popular framework for solving such problems [4], which formulates these problems as a multi-label classification task with very large number of labels; here each output choice is treated as a separate label. A label $\ell$ is often parameterized by its one-versus-all classifier vector $\mathbf{w}_{\ell}$ and the relevance between label $\ell$ and input $\mathbf{x}$ is formulated as $\mathbf{w}_{\ell}^{T}\boldsymbol{\phi}(\mathbf{x})$ , where $\boldsymbol{\phi}$ is an encoding function which maps an input $\mathbf{x}$ to its vector representation.
+
+
+Figure 1: Traditional partition-based index vs ELIAS index; here an arrow from a cluster to a label denotes the assignment of the label to the cluster, arrow width indicates the weight of the assignment. (left) Existing partition based XMC methods use a shallow balanced tree as the index structure with a label uniquely assigned to exactly one cluster; moreover, they initialize the clusters over pre-defined features and keep them fixed throughout the training procedure. (right) ELIAS generalizes the tree based index to a sparsely connected graph-based index and learns the cluster-to-label assignments end-to-end with the task objective during training.
+
+
+
+Evaluating $\mathbf{w}_{\ell}^{T}\phi (\mathbf{x})$ for every label $\ell$ in an XMC task can get computationally expensive since the number of labels could easily be upwards of millions. To reduce the complexity, most existing methods employ a search index that efficiently shortlists a small number of labels for an input query and the relevance scores are only evaluated on these shortlisted labels. The quality of the search index plays a pivotal role in the accuracy of these methods since a label $\ell$ outside the shortlist will be directly discarded, even if it can be correctly captured by its classifier vector $\mathbf{w}_{\ell}$ . Moreover, the label classifier $\mathbf{w}_{\ell}$ is a function of the quality of the index as during training, the label classifiers are learned with negative sampling based on the search index. Therefore, how to improve the quality of the search index becomes a key challenge in the XMC problem.
+
+There are two main formulations of the search index: 1) partition-based approach [25, 31, 7, 18, 32] and 2) approximate nearest neighbor search (ANNS) based approach [16, 9, 13, 10]. In partition-based approach, labels are first arranged into a tree-based index by partitioning the label space into mutually exclusive clusters and then a ML model is learned to route a given instance to a few relevant clusters. In an ANNS-based approach, a fixed, black-box ANNS index is learned on pre-defined label embeddings. Given an input embedding, this index is then used to efficiently query a small set of nearest labels based on some distance/similarity between the input and label embeddings. Both of these approaches suffer from a critical limitation that the index structure is fixed after it's initialized.
+
+This decoupling of the search index from the rest of the ML model training prevents the search index from adapting with the rest of the model during training, which leads to sub-optimal performance.
+
+To overcome this challenge, we propose a novel method called ELIAS: End-to-end Learning to Index and Search, which jointly learns the search index along with the rest of the ML model for multi-label classification in large output spaces. In particular, as illustrated in Fig. 1, ELIAS generalizes the widely used partition tree-based index to a sparsely connected weighted graph-based index. ELIAS models the discrete cluster-to-label assignments in the existing partition based approaches as soft learnable parameters that are learned end-to-end with the encoder and classification module to optimize the final task objective. Moreover, because ELIAS uses a graph-based arrangement of labels instead of a tree-based arrangement, a label can potentially be assigned to multiple relevant clusters. This helps to better serve labels with a multi-modal input distribution [22].
+
+Through extensive experiments we demonstrate that ELIAS achieves state-of-the-art results on multiple large-scale XMC benchmarks. Notably, ELIAS can be up to $2.5\%$ better at precision@1 and up to $4\%$ better at recall@100 than existing XMC methods. ELIAS's search index can be efficiently implemented on modern GPUs to offer fast inference times on million scale datasets. In particular, ELIAS offers sub-milliseconds prediction latency on a dataset with 3 million labels on a single GPU.
+
+# 2 Related Work
+
+One-vs-all (OVA) methods: OVA methods consider classification for each label as an independent binary classification problem. In particular, an OVA method learns $L$ (number of classes) independent label classifiers $[\mathbf{w}_{\ell}]_{\ell=1}^{L}$ , where the job of each classifier $\mathbf{w}_{\ell}$ is to distinguish training points of label $\ell$ from the rest of the training points. At prediction time, each label classifier is evaluated and the labels are ranked according to classifier scores. Traditional OVA methods like DiSMEC [2], ProXML [3], and PPDSparse [30] represent each input instance by their sparse bag-of-word features and learn
+
+sparse linear classifiers by massively parallelizing over multiple machines. OVA methods achieve promising results on XMC benchmarks but suffer from huge computational complexity because of their linear scaling with number of labels. Subsequent XMC methods borrow the same building blocks of an OVA approach but overcome the computational overhead by employing some form of search index to efficiently shortlist only a few labels during training and prediction.
+
+Partition based methods: Many XMC methods such as Parabel [25], Bonsai [19], XR-Linear [32], AttentionXML [31], X-Transformer [28], XR-Transformer [33], LightXML [18] follow this approach where the label space is partitioned into a small number of mutually exclusive clusters, and then an ML model is learned to route a given instance to a few relevant clusters. A popular way to construct clusters is to perform balanced $k$ -means clustering recursively using some pre-defined input features. Traditional methods like Parabel, Bonsai, and XR-Linear represent their input by sparse bag-of-word features and learn sparse linear classifiers with negative sampling performed based on the search index. With the advancement of deep learning in NLP, recent deep learning based XMC methods replace sparse bag-of-word input features with dense embeddings obtained from a deep encoder. In particular, AttentionXML uses a BiLSTM encoder while X-Transformer, XR-Transformer, and LightXML use deep transformer models such as BERT [11] to encode the raw input text. In addition to dense embeddings, the state-of-the-art XR-Transformer method uses a concatenation of dense embedding and sparse bag-of-word features to get a more elaborate representation of the input, thus mitigating the information loss in text truncation in transformers.
+
+ANNS based methods: Methods like SLICE [16], DeepXML [9], and GLaS [13] utilize approximate nearest neighbor search (ANNS) structure over pre-defined label representations to efficiently shortlist labels. In particular, SLICE represents each input instance by its FastText [24] embedding and uses the mean of a label's training points as a surrogate embedding for that label. It further constructs an HNSW [23] graph (a popular ANNS method) over these surrogate label embeddings. For a given input, the HNSW graph is queried to efficiently retrieve nearest indexed labels based on the cosine similarity between the input and label embedding. DeepXML extends SLICE by learning an MLP text encoder on a surrogate classification task instead of using a fixed FastText model to obtain input embeddings. GLaS takes a different approach and learns label classifiers with random negative sampling. After the model is trained, it constructs an ANNS index to perform fast maximum inner product search (MIPS) directly on the learned label classifiers.
+
+Learning search index: There has been prior works [21, 1] that model different types of standard data structures with neural networks. A recent paper [27] models the search index in information retrieval systems as a sequence to sequence model where all the parameters of the search index is encoded in the parameters of a big transformer model. In a more similar spirit to our work, another recent paper [22] attempts to learn overlapping cluster partitions for XMC tasks by assigning each label to multiple clusters. Even though it serves as a generic plug-in method to improve over any existing partition based XMC method, it still suffers from the following shortcomings: 1) label assignments are not learned end-to-end with the task objective; instead, it alternates between finding the right model given the fixed label assignments and then finding the right label assignments given the fixed model, 2) all labels are assigned to a pre-defined number of clusters with equal probability and get duplicated in each assigned cluster, which results in increased computational complexity of the method.
+
+# 3 ELIAS: End-to-end Learning to Index and Search
+
+The multi-label classification problem can be formulated as following: given an input $\mathbf{x} \in \mathcal{X}$ , predict $\mathbf{y} \in \{0,1\}^L$ where $\mathbf{y}$ is a sparse $L$ dimensional vector with $y_{\ell} = 1$ if and only if label $\ell$ is relevant to input $\mathbf{x}$ . Here, $L$ denotes the number of distinct labels - note that $\mathbf{y}$ can have multiple non-zero entries resulting in multiple label assignments to input $\mathbf{x}$ . The training dataset is given in the form of $\{(\mathbf{x}^i,\mathbf{y}^i):i = 1,\dots,N\}$ . XMC methods address the case where the label space $(L)$ is extremely large (in the order of few hundred thousands to millions). All deep learning based XMC methods have the following three key components:
+
+Deep encoder $\phi : \mathcal{X} \to \mathbb{R}^D$ which maps the input $\mathbf{x}$ to a $D$ -dimensional dense embedding through a differentiable function. For text input, a popular choice of $\phi$ is the BERT [11] encoder where each input $\mathbf{x}$ is represented as a sequence of tokens.
+
+
+Figure 2: Illustration of ELIAS's search procedure: an input $\mathbf{x}$ is first embedded by the text encoder $\phi$ to get its embedding $\phi (\mathbf{x})$ . Only a few (beam-size) clusters are shortlisted based on cluster relevance scores $\hat{s}_c\sim \hat{\mathbf{w}}_c^T\phi (\mathbf{x})$ . All potential edges of shortlisted clusters are explored and assigned a score based on the product $\hat{s}_c*\hat{s}_{c,\ell}$ ( $\hat{s}_{c,\ell}$ is normalized form of learnable edge weight parameter $a_{c,\ell}$ between cluster $c$ and label $l$ ). Top- $K$ paths are shortlisted based on their assigned scores and the final label relevance is computed as $\sigma (\mathbf{w}_\ell^T\boldsymbol {\phi}(\boldsymbol {x}))*\hat{s}_{c,\ell}*\hat{s}_c$ , here $\sigma$ is the sigmoid function. If a label $\ell$ can be reached from multiple paths then the path with maximal score is kept and rest are discarded.
+
+Search Index $\mathcal{I}:\mathcal{X}\to \mathbb{R}^L$ shortlists $K$ labels along with a score assigned to each shortlisted label for a given input $\mathbf{x}$ . More specifically, $\hat{\mathbf{y}} = \mathcal{I}(\mathbf{x})$ is a sparse real valued vector with only $K\left(\ll L\right)$ non-zero entries and $\hat{y}_{\ell}\neq 0$ implies that label $\ell$ is shortlisted for input $\mathbf{x}$ with shortlist relevance score $\hat{y}_{\ell}$ . As illustrated in Figure 1, many partition based methods [18, 33] formulate their index as a label tree derived by hierarchically partitioning the label space into $C$ clusters and then learn classifier vectors $\hat{\mathbf{W}}_C = [\hat{\mathbf{w}}_c]_{c = 1}^C (\hat{\mathbf{w}}_c\in \mathbb{R}^D)$ for each cluster which is used to select only a few clusters for a given input. More specifically, given the input $\mathbf{x}$ , the relevance of cluster $c$ to input $\mathbf{x}$ is quantified by cluster relevance scores $\hat{s}_c = \hat{\mathbf{w}}_c^T\phi (\mathbf{x})$ . The top- $b$ clusters based on these scores are selected and all labels inside the shortlisted clusters are returned as the shortlisted labels, where $b(\ll C)$ is a hyperparameter denoting the beam-size.
+
+Label classifiers $\mathbf{W}_L = [\mathbf{w}_{\ell}]_{\ell=1}^L$ where $\mathbf{w}_{\ell} \in \mathbb{R}^{D}$ represents the classifier vector for label $\ell$ and $\mathbf{w}_{\ell}^{T}\phi(\mathbf{x})$ represents the label relevance score of label $\ell$ for input $\mathbf{x}$ . As explained above, $\mathbf{w}_{\ell}^{T}\phi(\mathbf{x})$ is only computed for a few shortlisted labels obtained from the search index $\mathcal{I}$ .
+
+# 3.1 ELIAS Index
+
+ELIAS formulates its label index as a specialized weighted graph between a root node $\emptyset$ , $C$ cluster nodes $\mathcal{C} = \{c\}_{c=1}^{C}$ and $L$ label nodes $\mathcal{V} = \{\ell\}_{\ell=1}^{L}$ . As illustrated in Figure 2, all cluster nodes are connected to the root node and all label nodes are sparsely connected to few cluster nodes. ELIAS parameterizes the cluster-to-label edge assignments by a learnable adjacency matrix $\mathbf{A} = [a_{c,\ell}]_{C \times L}$ , where the scalar parameter $a_{c,\ell}$ denotes the edge importance between cluster $c$ and label $\ell$ .
+
+Note that $\mathbf{A}$ can be very large for XMC datasets and using a dense $\mathbf{A}$ will incur $\mathcal{O}(CL)$ cost in each forward pass which can be computationally prohibitive for large-scale datasets. To mitigate this we restrict $\mathbf{A}$ to be a row-wise sparse matrix i.e. $\| \mathbf{a}_i\| _0\leq \kappa$ where $\| .\| _0$ represents the $\ell_0$ norm, $\mathbf{a}_i$ represents the $i^{th}$ row of $\mathbf{A}$ and $\kappa$ is a hyper-parameter which controls the sparsity of $\mathbf{A}$ . During training, only the non-zero entries of $\mathbf{A}$ is learned and the zero entries do not participate in any calculation. We defer the details of how we initialize the sparsity structure of $\mathbf{A}$ to Section 3.4.
+
+Existing partition based XMC methods can be thought of as a special case of this formulation by adding additional restrictions that 1) each label is connected to exactly one cluster node, and 2) all cluster-to-label connections have equal importance. Moreover, existing methods initialize the cluster-to-label adjacency matrix $\mathbf{A}$ beforehand based on clustering over pre-defined features and keep it fixed throughout the training procedure. ELIAS overcomes these shortcomings by enabling the model to learn the cluster-to-label edge importance.
+
+# 3.2 Forward Pass
+
+ELIAS trains the entire model, including the deep encoder $\phi$ , the search index parameters $\hat{\mathbf{W}}_C$ , $\mathbf{A}$ and the label classifiers $\mathbf{W}_L$ in an end-to-end manner. We now describe the details of the forward pass of ELIAS.
+
+Text representation: An input $\mathbf{x}$ is embedded by the encoder $\phi$ into a dense vector representation $\phi (\mathbf{x})$ . In particular, we use BERT-base [11] as the encoder and represent $\phi (\mathbf{x})$ by the final layer's CLS token vector.
+
+Query search index: Recall that the goal of the search index $\mathcal{I}$ is to efficiently compute a shortlist of labels $\hat{\mathbf{y}}\in \mathbb{R}^L$ , where $\hat{\mathbf{y}}$ is a sparse real valued vector with $K\left(\ll L\right)$ non-zero entries and $\hat{y}_{\ell}\neq 0$ implies that label $\ell$ is shortlisted for input $\mathbf{x}$ with shortlist score $\hat{y}_{\ell}$ . Similar to existing methods, ELIAS achieves this by first shortlisting a small subset of clusters $\hat{\mathcal{C}}\subset \mathcal{C}$ based on cluster relevance scores defined by $\hat{\mathbf{w}}_c^T\phi (\mathbf{x})$ . But unlike existing methods which simply return the union of the fixed label set assigned to each shortlisted cluster, ELIAS shortlists the top- $K$ labels based on the soft cluster-to-label assignments and backpropagates the loss feedback to each of the shortlisted paths. More specifically, ELIAS defines the cluster relevance scores $\hat{\mathrm{s}}_{\mathcal{C}}\in \mathbb{R}^{C}$ as:
+
+$$
+\hat {\mathbf {s}} _ {\mathcal {C}} = [ \hat {s} _ {c} ] _ {c = 1} ^ {C} = \min (1, \alpha * \operatorname {s o f t m a x} (\hat {\mathbf {W}} _ {C} ^ {T} \phi (\mathbf {x}))). \qquad (1)
+$$
+
+Here hyperparameter $\alpha$ is multiplied by the softmax scores to allow multiple clusters to get high relevance scores. Intuitively, $\alpha$ controls how many effective clusters can simultaneously activate for a given input (in practice, we keep $\alpha \approx 10$ ).
+
+Given cluster relevance scores $\hat{\mathbf{s}}_{\mathcal{C}}$ , we define set $\mathcal{C}_{topb}$ as the top $b$ clusters with the highest cluster relevance scores, where $b \ll C$ is the beam size hyperparameter. In the training phase, we further define a parent set $\mathcal{C}_{parent}$ to guarantee that the correct labels of $\mathbf{x}$ are present in the shortlist. More specifically, for each positive label of $\mathbf{x}$ , we include the cluster with the strongest edge connection to $l$ in $\mathcal{C}_{parent}$ . The shortlisted set $\hat{\mathcal{C}}$ is defined as the union of these two sets and the selection process can be summarized as follows:
+
+$$
+\mathcal {C} _ {\text {t o p b}} = \arg \operatorname {t o p} - b (\hat {\mathbf {s}} _ {\mathcal {C}}), \text {w h e r e} b (\ll C) \text {i s} \tag {2}
+$$
+
+$$
+\mathcal {C} _ {\text {p a r e n t}} = \left\{ \begin{array}{l l} \{\} & \text {d u r i n g p r e d i c t i o n ,} \\ \bigcup_ {\ell : y _ {\ell} = 1} \left\{\arg \max _ {c} \left(a _ {c, \ell}\right) \right\} & \text {d u r i n g t r a i n i n g} \end{array} \right. \tag {3}
+$$
+
+$$
+\hat {\mathcal {C}} = \mathcal {C} _ {t o p b} \cup \mathcal {C} _ {p a r e n t}. \tag {4}
+$$
+
+After shortlisting a small subset of clusters $\hat{\mathcal{C}}$ , all potential edges of shortlisted clusters are explored and a set $\hat{\mathcal{P}}$ of explored paths is constructed, where $\hat{\mathcal{P}} = \{\emptyset \to c \to \ell : c \in \hat{\mathcal{C}}$ and $a_{c,\ell} > 0\}$ . Furthermore, each path $\emptyset \to c \to \ell \in \hat{\mathcal{P}}$ is assigned a path score $\hat{s}_{\emptyset,c,\ell}$ , where the path score $\hat{s}_{\emptyset,c,\ell}$ is expressed as the product of cluster relevance score $\hat{s}_c$ (defined by Eqn. 1) and edge score $\hat{s}_{c,\ell}$ which quantifies the probability of label $\ell$ getting assigned to cluster $c$ and is defined in terms of the learnable edge weight parameter $a_{c,\ell}$ as follows:
+
+$$
+\hat {s} _ {c, \ell} = \min \left(1, \beta * a _ {c, \ell} ^ {\text {n o r m}}\right), \text {w h e r e} a _ {c, \ell} ^ {\text {n o r m}} = \frac {\exp \left(a _ {c , \ell}\right)}{\sum_ {\ell^ {\prime} = 1} ^ {L} \exp \left(a _ {c , \ell^ {\prime}}\right)}, \text {a n d} \hat {s} _ {\emptyset , c, \ell} = \hat {s} _ {c} * \hat {s} _ {c, \ell}. \tag {5}
+$$
+
+Defining edge scores $\hat{s}_{c,\ell}$ in such a manner allows modelling the desired probability distribution of label assignment to a cluster, where a few relevant labels are assigned to a particular cluster with probability 1, and all other labels have probability 0. Hyperparameter $\beta$ controls how many effective labels can get assigned to a cluster, we choose $\beta \approx L / C$ . Figure 3 empirically confirms that the trained model indeed learns the desired edge score distribution with most of the probability concentrated on a few labels and the rest of the labels getting assigned low probability. Moreover, this formulation also prevents labels with high softmax scores from overpowering edge assignments because as per 5, a relevant label $\ell$ for cluster $c$ gets positive feedback for $a_{c,\ell}$ only if $a_{c,\ell}^{norm} < 1 / \beta$ , otherwise $a_{c,\ell}$ does not participate in the calculation of $\hat{s}_{\ell}$ label assignments. Note that, because of the assumption that can be computed efficiently in $\mathcal{O}(\kappa)$ instead of $\mathcal{O}(L)$ time
+
+
+Figure 3: $a_{c,\ell}^{\text{norm}}$ (edge weight) distribution averaged over all clusters of trained ELIAS model on Amazon-670K dataset
+
+Since there can be multiple paths in $\hat{\mathcal{P}}$ which reach a particular label $\ell$ , ELIAS defines shortlist score $\hat{y}_{\ell}$ for label $\ell$ by the maximum scoring path in $\hat{\mathcal{P}}$ that reaches $\ell$ , i.e.
+
+$$
+\hat {y} _ {\ell} = \max _ {c ^ {\prime}} \left\{\hat {s} _ {\emptyset , c ^ {\prime}, \ell}: \emptyset \rightarrow c ^ {\prime} \rightarrow \ell \in \hat {\mathcal {P}} \right\}. \tag {6}
+$$
+
+Finally, only the top- $K$ entries in $\hat{\mathbf{y}}$ are retained and the resulting vector is returned as the shortlist for input $\mathbf{x}$ .
+
+Evaluating label classifiers: label classifiers $[\mathbf{w}_{\ell}]_{\ell=1}^{L}$ are evaluated for the $K$ non-zero labels in $\hat{\mathbf{y}}$ and the final relevance score between label $\ell$ and input $\mathbf{x}$ is returned as $p_{\ell} = \sigma(\mathbf{w}_{\ell}^{T}\phi(\mathbf{x})) * \hat{y}_{\ell}$ , here $\sigma$ is the sigmoid function.
+
+# 3.3 Loss
+
+ELIAS is trained on a combination of classification and shortlist loss where the shortlist loss encourages correct labels to have high shortlist scores $(\hat{y}_{\ell})$ and classification loss encourages positive labels in the shortlist to have high final score $(p_{\ell})$ and negative labels in the shortlist to have low final score. More specifically, the final loss $\mathcal{L}$ is defined as $\mathcal{L} = \mathcal{L}_c + \lambda \mathcal{L}_s$ , where $\lambda$ is a hyperparameter and classification loss $\mathcal{L}_c$ is defined as binary cross entropy loss over shortlisted labels
+
+$$
+\mathcal {L} _ {c} = - \sum_ {\ell : \hat {y} _ {\ell} \neq 0} \left(y _ {\ell} \log \left(p _ {\ell}\right) + \left(1 - y _ {\ell}\right) \left(1 - \log \left(p _ {\ell}\right)\right)\right), \tag {7}
+$$
+
+shortlist loss $\mathcal{L}_s$ is defined as negative log likelihood loss over the positive labels
+
+$$
+\mathcal {L} _ {s} = - \sum_ {\ell : y _ {\ell} = 1} \log \left(\hat {y} _ {\ell}\right). \tag {8}
+$$
+
+# 3.4 Staged Training
+
+Previous sub-sections described the ELIAS framework for learning the index graph along with the ML model in an end-to-end manner. Although, in principle one can optimize the network with the given loss function from a random initialization but we highlight a few key challenges in doing so: 1) Optimization challenge: because of the flexibility in the network to assign a label node to various clusters, it becomes hard for a label to get confidently assigned to only a few relevant clusters. As a result, the model is always chasing a moving target and for a given input it is not able to be sure about any single path; 2) Computational challenge: the full cluster-label adjacency matrix $\mathbf{A}$ can be very large for large datasets and will incur $\mathcal{O}(CL)$ cost in each forward pass if implemented in dense form. To address these challenges we train the ELIAS model in two stages. In the first stage, we only train the encoder $\phi$ , cluster classifiers $\hat{\mathbf{W}}_C$ , and label classifiers $\mathbf{W}_L$ keeping $A$ fixed and assigned based on traditional balanced partitions. We then utilize the stage-1 trained model to initialize the sparse adjacency matrix $\mathbf{A}$ . In the second stage, we take the initialized $\mathbf{A}$ and rest of the stage 1 model, and jointly train the full model $\phi$ , $\hat{\mathbf{W}}_C$ , $\mathbf{W}_L$ , $\mathbf{A}$ .
+
+Stage 1: In stage 1 training, similar to existing partition-based XMC methods, we partition the label space into $C$ mutually exclusive clusters by performing balanced $k$ -means clustering over pre-defined label features. The adjacency matrix induced by these clusters is then used as fixed assignment for $\mathbf{A}$ . Keeping $\mathbf{A}$ fixed, we train the rest of the model (i.e. $\phi, \hat{\mathbf{W}}_C, \mathbf{W}_L$ ) on the loss described in Section 3.3. More details on clustering are provided in Section C.1 in the Appendix.
+
+Initializing A: As highlighted before, to overcome the $\mathcal{O}(CL)$ cost associated with a full adjacency matrix $\mathbf{A}$ , we want to restrict $\mathbf{A}$ to be a row-wise sparse matrix. In other words, we want to restrict each cluster to choose from a candidate subset of $\kappa$ labels instead of the whole label set. Intuitively, in order for the model to learn anything meaningful, the candidate subset for each cluster should contain approximately similar labels. To achieve this, we utilize the stage 1 model to first generate an approximate adjacency matrix $\mathbf{A}'$ and then select the top- $\kappa$ entries in each row of $\mathbf{A}'$ as non-zero entries for $\mathbf{A}$ . More specifically, we first identify top- $b$ matched clusters for each training point $\mathbf{x}^i$ by computing the cluster matching matrix $\mathbf{M} = [m_{i,c}]_{N\times C}$ as:
+
+$$
+m _ {i, c} = \left\{ \begin{array}{l l} \hat {\mathbf {s}} _ {c} ^ {i} & \text {i f} c \in \mathcal {C} _ {t o p b} ^ {i}, \\ 0 & \text {o t h e r w i s e} \end{array} \right. \tag {9}
+$$
+
+where $\hat{\mathbf{s}}_c^i$ represents the cluster relevance score and $\mathcal{C}_{topb}^i$ represents the set of top- $b$ clusters for $i^{th}$ training point $\mathbf{x}^i$ . After computing $\mathbf{M}$ , we define the approximate adjacency matrix $\mathbf{A}' = [a_{c,\ell}']_{C\times L} = \mathbf{M}^T\mathbf{Y}$ , where $\mathbf{Y} = [\mathbf{y}^1, \dots, \mathbf{y}^i, \dots, \mathbf{y}^N]^T$ . The element $a_{c,\ell}'$ essentially denotes the weighted count of how many times the cluster $c$ got placed in top- $b$ positions for positive training points of label $\ell$ . Finally, the top $\kappa$ elements in each row of $\mathbf{A}'$ are selected as the non-zero parameters of $\mathbf{A}$ , i.e.
+
+$$
+a _ {c, \ell} = \left\{ \begin{array}{l l} \operatorname {r a n d o m} (0, 1) & \text {i f} \ell \in \arg \operatorname {t o p} - \kappa \left(\mathbf {a} _ {c} ^ {\prime}\right) \\ 0 & \text {o t h e r w i s e} \end{array} \right. \tag {10}
+$$
+
+We choose a large enough $\kappa$ to provide the model enough degree of freedom to learn cluster-to-label assignments. In particular, $\kappa \sim 10 \times L / C$ works well across datasets without adding any computational burden. For efficient implementation on GPUs, we store matrix $\mathbf{A}$ in the form of two tensors, one storing the non-zero indices and the other storing the values corresponding to those non-zero indices.
+
+Stage 2: In stage 2 training, we initialize $\mathbf{A}$ as described above, and $\phi$ , $\hat{\mathbf{W}}_C$ from stage 1 model. We then train the full ELIAS model (i.e., $\hat{\mathbf{W}}_C$ , $\mathbf{W}_L$ , $\mathbf{A}$ ) end-to-end to optimize the loss defined in Section 3.3.
+
+# 3.5 Sparse Ranker
+
+State-of-the-art XMC methods like XR-Transformer [33] and X-Transformer [7] utilize high capacity sparse classifiers learned on the concatenated sparse bag-of-word features and dense embedding obtained from the deep encoder for ranking their top predictions. Because of the high capacity, sparse classifiers are able to represent head labels more elaborately than dense classifiers. Moreover, bag-of-words representation is able to capture the full input document instead of the truncated document that the deep encoder receives.
+
+To compare fairly with such methods, we explore an enhanced variant of ELIAS represented by ELIAS ++, which additionally learns a sparse ranker that re-ranks the top 100 predictions of ELIAS. In particular, the sparse ranker takes the concatenated sparse bag-of-word and dense embedding input features and learns sparse linear classifiers on the top 100 label predictions made from the trained ELIAS model for each training point. Because these sparse classifiers are only trained on 100 labels per training point, they can be quickly trained by parallel linear solvers like LIBLINEAR [12]. We use the open-source PECOS $^2$ [32] library to train and make predictions with the sparse ranker.
+
+During prediction, the top 100 predictions are first made by ELIAS and then the learned sparse ranker is evaluated on these top 100 predictions. We empirically observe that the scores returned by ELIAS and sparse ranker are not well calibrated across different label regimes. As shown in Figure 4, the sparse
+
+
+Figure 4: True label's score distribution of sparse ranker and ELIAS (d) over different label deciles on Amazon-670K dataset. $1^{st}$ decile represents labels with most training points while $10^{th}$ decile represents labels with least training points
+
+ranker underestimates scores on tail labels while ELIAS scores are more balanced across all label regimes. To correct this score mis-calibration, we learn a simple score calibration module which consists of a standard decision tree classifier3 that takes both of these scores and the training frequency of the label as input and predicts a single score denoting the label relevance. The score calibration module is learned on a small validation set of 5,000 points. More details on the sparse ranker are in Appendix Section C.2.
+
+# 3.6 Time Complexity Analysis
+
+The time complexity for processing a batch of $n$ data-points is $\mathcal{O}(n(T_{\mathrm{bert}} + Cd + b\kappa + Kd))$ where $T_{\mathrm{bert}}$ represents the time complexity of the bert encoder, $C$ represents the number of clusters in index,
+
+Table 1: Performance comparison on extreme classification benchmark datasets. Bold numbers represent overall best numbers for that dataset while underlined numbers represent best numbers for dense embedding based methods. Methods which only use sparse bag-of-word features are distinguished by $(s)$ superscript, dense embedding based methods are distinguished by $(d)$ superscript and methods that use both sparse + dense features are distinguished by $(s+d)$ superscript
+
+| Method | P@1 | P@3 | P@5 | PSP@1 | PSP@3 | PSP@5 | P@1 | P@3 | P@5 | PSP@1 | PSP@3 | PSP@5 |
| Amazon-670K | LF-AmazonTitles-131K |
| DiSMEC(s) | 44.70 | 39.70 | 36.10 | 27.80 | 30.60 | 34.20 | 35.14 | 23.88 | 17.24 | 25.86 | 32.11 | 36.97 |
| Parabel(s) | 44.89 | 39.80 | 36.00 | 25.43 | 29.43 | 32.85 | 32.60 | 21.80 | 15.61 | 23.27 | 28.21 | 32.14 |
| XR-Linear(s) | 45.36 | 40.35 | 36.71 | - | - | - | - | - | - | - | - | - |
| Bonsai(s) | 45.58 | 40.39 | 36.60 | 27.08 | 30.79 | 34.11 | 34.11 | 23.06 | 16.63 | 24.75 | 30.35 | 34.86 |
| Slice(d) | 33.15 | 29.76 | 26.93 | 20.20 | 22.69 | 24.70 | 30.43 | 20.50 | 14.84 | 23.08 | 27.74 | 31.89 |
| Astec(d) | 47.77 | 42.79 | 39.10 | 32.13 | 35.14 | 37.82 | 37.12 | 25.20 | 18.24 | 29.22 | 34.64 | 39.49 |
| GLaS(d) | 46.38 | 42.09 | 38.56 | 38.94 | 39.72 | 41.24 | - | - | - | - | - | - |
| AttentionXML(d) | 47.58 | 42.61 | 38.92 | 30.29 | 33.85 | 37.13 | 32.55 | 21.70 | 15.64 | 23.97 | 28.60 | 32.57 |
| LightXML(d) | 49.10 | 43.83 | 39.85 | - | - | - | 38.49 | 26.02 | 18.77 | 28.09 | 34.65 | 39.82 |
| XR-Transformer(s+d) | 50.11 | 44.56 | 40.64 | 36.16 | 38.39 | 40.99 | 38.42 | 25.66 | 18.34 | 29.14 | 34.98 | 39.66 |
| Overlap-XMC(s+d) | 50.70 | 45.40 | 41.55 | 36.39 | 39.15 | 41.96 | - | - | - | - | - | - |
| ELIAS(d) | 50.63 | 45.49 | 41.60 | 32.59 | 36.44 | 39.97 | 39.14 | 26.40 | 19.08 | 30.01 | 36.09 | 41.07 |
| ELIAS++(s+d) | 53.02 | 47.18 | 42.97 | 34.32 | 38.12 | 41.93 | 40.13 | 27.11 | 19.54 | 31.05 | 37.57 | 42.88 |
| Wikipedia-500K | Amazon-3M |
| DiSMEC(s) | 70.21 | 50.57 | 39.68 | 31.20 | 33.40 | 37.00 | 47.34 | 44.96 | 42.80 | - | - | - |
| Parabel(s) | 68.70 | 49.57 | 38.64 | 26.88 | 31.96 | 35.26 | 47.48 | 44.65 | 42.53 | 12.82 | 15.61 | 17.73 |
| XR-Linear(s) | 68.12 | 49.07 | 38.39 | - | - | - | 47.96 | 45.09 | 42.96 | - | - | - |
| Bonsai(s) | 69.20 | 49.80 | 38.80 | - | - | - | 48.45 | 45.65 | 43.49 | 13.79 | 16.71 | 18.87 |
| Slice(d) | 62.62 | 41.79 | 31.57 | 24.48 | 27.01 | 29.07 | - | - | - | - | - | - |
| Astec(d) | 73.02 | 52.02 | 40.53 | 30.69 | 36.48 | 40.38 | - | - | - | - | - | - |
| GLaS(d) | 69.91 | 49.08 | 38.35 | - | - | - | - | - | - | - | - | - |
| AttentionXML(d) | 76.95 | 58.42 | 46.14 | 30.85 | 39.23 | 44.34 | 50.86 | 48.04 | 45.83 | 15.52 | 18.45 | 20.60 |
| LightXML(d) | 77.78 | 58.85 | 45.57 | - | - | - | - | - | - | - | - | - |
| XR-Transformer(s+d) | 79.40 | 59.02 | 46.25 | 35.76 | 42.22 | 46.36 | 54.20 | 50.81 | 48.26 | 20.52 | 23.64 | 25.79 |
| Overlap-XMC(s+d) | - | - | - | - | - | - | 52.70 | 49.92 | 47.71 | 18.79 | 21.90 | 24.10 |
| ELIAS(d) | 79.00 | 60.37 | 46.87 | 33.86 | 42.99 | 47.29 | 51.72 | 48.99 | 46.89 | 16.05 | 19.39 | 21.81 |
| ELIAS++(s+d) | 81.26 | 62.51 | 48.82 | 35.02 | 45.94 | 51.13 | 54.28 | 51.40 | 49.09 | 15.85 | 19.07 | 21.52 |
+
+$d$ is the embedding dimension, $b$ is the beam size, $\kappa$ is the row-wise sparsity of cluster-to-label adjacency matrix $A$ , and $K$ is the number of labels shortlisted for classifier evaluation. Assuming $C = \mathcal{O}(\sqrt{L})$ , $\kappa = \mathcal{O}(L / C) = \mathcal{O}(\sqrt{L})$ and $K = \mathcal{O}(\sqrt{L})$ , the final time complexity comes out to be $\mathcal{O}(n(T_{\mathrm{bert}} + \sqrt{L}(2d + b)))$ . Empirical prediction and training times on benchmark datasets are reported in Table 6 of the Appendix.
+
+# 4 Experimental Results
+
+Experimental Setup We conduct experiments on three standard full-text extreme classification datasets: Wikipedia-500K, Amazon-670K, Amazon-3M and one short-text dataset: LF-AmazonTitles-131K which only contains titles of Amazon products as input text. For Wikipedia-500K, Amazon-670K, and Amazon-3M, we use the same experimental setup (i.e. raw input text, sparse features and train-test split) as existing deep XMC methods [31, 33, 18, 7]. For LF-AmazonTitles-131K, we use the experimental setup provided in the extreme classification repository [5]. Comparison to existing XMC methods is done by standard evaluation metrics of precision@ $K$ ( $\mathrm{P}@\mathcal{K} = 1,3,5$ ) and its propensity weighted variant ( $\mathrm{PSP}@\mathcal{K} = 1,3,5$ ) [15]. We also compare competing methods and baselines with ELIAS at recall@ $K$ ( $\mathrm{R}@\mathcal{K} = 10,20,100$ ) evaluation to illustrate the superior shortlisting performance of ELIAS's search index. More details on the experimental setup and dataset statistics are presented in Appendix Section B.
+
+Implementation details Similar to existing XMC methods, we take an ensemble of 3 models with different initial clustering of label space to report final numbers. For efficient implementation on GPU, the raw input sequence is concatenated to 128 tokens for full-text datasets and 32 tokens for short-text dataset. Number of clusters $C$ for each dataset is chosen to be the same as LightXML which selects $C \sim L / 100$ . We keep the shortlist size hyperparameter $K$ fixed to 2000 which is approximately same as the number of labels existing partition based methods shortlist assuming beam-size $b = 20$
+
+Table 2: Precision and recall comparison of single model dense embedding-based methods. ELIAS matches or even outperforms the brute-force Bert-OvA baseline while existing partition based methods fail to compare well, especially at recall values.
+
+| Method | P@1 | P@3 | P@5 | R@10 | R@20 | R@100 | P@1 | P@3 | P@5 | R@10 | R@20 | R@100 |
| Amazon-670K | LF-AmazonTitles-131K |
| BERT-OvA-1(d) | 48.50 | 43.41 | 39.67 | 49.53 | 56.60 | 67.90 | 38.17 | 25.66 | 18.44 | 50.29 | 54.71 | 62.80 |
| AttentionXML-1(d) | 45.84 | 40.92 | 37.24 | 45.59 | 51.25 | 60.77 | 30.26 | 20.03 | 14.31 | 38.16 | 41.47 | 47.73 |
| LightXML-1(d) | 47.29 | 42.24 | 38.48 | 47.34 | 53.26 | 62.03 | 37.01 | 24.88 | 17.90 | 48.07 | 52.10 | 59.42 |
| XR-Transformer-1(d) | 45.25 | 40.3 | 36.45 | 45.19 | 51.61 | 61.11 | 34.58 | 23.31 | 16.79 | 45.72 | 49.65 | 56.00 |
| ELIAS-1(d) | 48.68 | 43.78 | 40.04 | 50.33 | 57.67 | 68.95 | 37.90 | 25.61 | 18.45 | 50.12 | 54.62 | 62.88 |
+
+Table 3: Performance analysis of different components of ELIAS. Allowing the model to learn cluster-to-label assignments significantly improves both precision and recall performance (see row 2 vs row 1). Sparse ranker further improves performance on top predictions (see row 4 vs row 2).
+
+| Method | P@1 | P@3 | P@5 | R@10 | R@20 | R@100 | P@1 | P@3 | P@5 | R@10 | R@20 | R@100 |
| Amazon-670K | LF-AmazonTitles-131K |
| Stage 1 | 46.63 | 41.65 | 37.58 | 46.08 | 52.29 | 61.72 | 36.96 | 24.67 | 17.69 | 47.69 | 51.74 | 58.81 |
| + Stage 2 | 48.68 | 43.78 | 40.04 | 50.33 | 57.67 | 68.95 | 37.90 | 25.61 | 18.45 | 50.12 | 54.62 | 62.88 |
| + Sparse ranker w/o calibration | 50.72 | 45.25 | 41.27 | 51.51 | 58.43 | 68.95 | 39.25 | 26.47 | 19.02 | 51.4 | 55.39 | 62.88 |
| + Score calibration | 51.41 | 45.69 | 41.62 | 51.97 | 58.81 | 68.95 | 39.26 | 26.47 | 19.02 | 51.4 | 55.35 | 62.88 |
| + 3× ensemble | 53.02 | 47.18 | 42.97 | 53.99 | 61.33 | 72.07 | 40.13 | 27.11 | 19.54 | 53.31 | 57.78 | 65.15 |
+
+and the number of labels per cluster $= 100$ . AdamW [20] optimizer is used to train the whole model with weight decay applied only to non-gain and non-bias parameters. Optimization update for label classifiers $\mathbf{W}_L$ is performed with high accumulation steps (i.e. optimization update is performed at every $k$ training steps, where $k = 10$ ) since updating $\mathbf{W}_L$ every step is a computational bottleneck and only few parameters inside $\mathbf{W}_L$ gets updated in each optimization step anyway. More details and hyperparameters for each dataset are presented in Appendix Section B.
+
+Comparison on XMC benchmarks Table 1 compares our method with leading XMC methods such as DiSMEC [2], Parabel [25], XR-Linear [32], Bonsai [19], Slice [16], Astec [9], GlaS [13], AttentionXML [31], LightXML [18], XR-Transformer [33], and Overlap-XMC [22]. Most baseline results are obtained from their respective papers when available and otherwise taken from results reported in [31, 33] and extreme classification repository [5]. To allow fair comparison among methods that use the same form of input representation, we distinguish methods that use only sparse bag-of-word input features by $(s)$ superscript, methods that use only dense embedding based input features by $(d)$ superscript, and methods that use both sparse + dense features by $(s+d)$ superscript. ELIAS ++ which uses sparse + dense features achieves state-of-the-art performance on all datasets at precision values while being either the best or second best method at propensity scored precision on most datasets. The dense embedding based ELIAS $(d)$ consistently outperforms existing dense embedding based XMC methods by significant margin and on many occasions achieves gains over previous state-of-the-art methods which use both sparse + dense features.
+
+Comparison with brute-force OvA baseline To establish the classification performance that could have been achieved if there was no sampling performed by the shortlisting procedure, we implement the brute-force one-versus-all baseline BERT-OvA which consists of BERT encoder followed by a fully connected linear classification layer and is trained and inferred in one-versus-all fashion without any sampling. We follow the same training procedures as ELIAS for this baseline. Table 2 compares the OvA baseline with ELIAS and leading deep XMC methods such as AttentionXML, LightXML and a dense version of XR-Transformer which uses only dense embeddings, under single model (i.e. no ensemble) setup for direct comparison. Existing deep XMC methods do not compare well against the OvA model especially at recall@100 but ELIAS matches and sometimes even marginally outperforms, the brute-force OvA baseline while enjoying faster training and inference speed due to the search index.
+
+Component wise ablation of ELIAS Table 3 presents a build-up ablation of performance gains made by different components of ELIAS. The stage 1 model which fixes its adjacency matrix by clustering labels into mutually exclusive clusters performs similarly to existing single model XMC methods. Allowing the model to learn the adjacency matrix $\mathbf{A}$ in stage 2 improves recall by up to $7\%$ and precision by up to $2.5\%$ over the stage 1 model. Adding the sparse ranker and score-calibration
+
+module further improves model performance on top predictions but the gains diminish as we increase prediction set size. Finally, the ensemble of 3 models improves performance at all evaluation metrics which is a well observed behaviour with all XMC methods.
+
+
+Figure 5: (left) Comparison of recall at different prediction set size on Amazon-670K (right) Decile-wise analysis of recall@100 on Amazon-670K, $1^{st}$ decile represents labels with most training points i.e. head labels while $10^{th}$ decile represents labels with least training points i.e. tail labels
+
+
+
+Recall comparison Next, we compare the recall capabilities of existing methods with ELIAS. The left plot in Figure 5 plots the recall at different prediction set size for all competing methods and ELIAS. ELIAS strictly outperforms existing methods at all prediction set sizes and in particular, can be up to $4\%$ better at recall@100 than the next best method. To further investigate which label regimes benefit most from ELIAS's search index we plot the decile wise contribution to recall@100 for each method. As we can see, ELIAS improves recall performance over existing methods in each label decile but the most improvement come from the top 2 deciles representing the most popular labels. We hypothesize that because the popular labels are likely to have multi-modal input distribution, existing partition based methods which assign a label to only one cluster fail to perform well on these multi-modal labels. Section C.4 contains additional discussion and results to support this claim.
+
+# 5 Conclusion and Discussions
+
+In this paper, we propose ELIAS, which extends the widely used partition tree based search index to a learnable graph based search index for extreme multi-label classification task. Instead of using a fixed search index, ELIAS relaxes the discrete cluster-to-label assignments in the existing partition based approaches as soft learnable parameters. This enables the model to learn a flexible index structure, and it allows the search index to be learned end-to-end with the encoder and classification module to optimize the final task objective. Empirically, ELIAS achieves state-of-the-art performance on several large-scale extreme classification benchmarks with millions of labels. ELIAS can be up to $2.5\%$ better at precision@1 and up to $4\%$ better at recall@100 than existing XMC methods.
+
+This work primarily explores many-shot and few-shot scenarios where some training supervision is available for each label (output). It would be interesting to see how we can adapt the proposed solution to zero-shot scenarios where there is no training supervision available for the labels. One potential approach could be to parameterize the cluster-to-label adjacency matrix as a function of cluster and label features instead of free learnable scalars. Furthermore, one limitation of the proposed solution is that it learns a shallow graph structure over label space; this may not be ideal for scaling the method to billion-scale datasets. It would be exciting to explore how one can extend ELIAS to learn deep graph structures.
+
+# References
+
+[1] H. Abu-Libdeh, D. Altinbüken, A. Beutel, E. Chi, L. Doshi, T. Kraska, X. Li, A. Ly, and C. Olston. Learned indexes for a google-scale disk-based database. CoRR, abs/2012.12501, 2020. URL https://arxiv.org/abs/2012.12501.
+[2] R. Babbar and B. Schölkopf. DiSMEC: Distributed Sparse Machines for Extreme Multi-label Classification. In WSDM, 2017.
+[3] R. Babbar and B. Schölkopf. Data scarcity, robustness and extreme multi-label classification. ML, 2019.
+[4] S. Bengio, K. Dembczynski, T. Joachims, M. Kloft, and M. Varma. Extreme Classification (Dagstuhl Seminar 18291). Dagstuhl Reports, 8(7):62-80, 2019. ISSN 2192-5283. doi: 10. 4230/DagRep.8.7.62. URL http://drops.dagstuhl.de/opus/volltexte/2019/10173.
+[5] K. Bhatia, K. Dahiya, H. Jain, P. Kar, A. Mittal, Y. Prabhu, and M. Varma. The extreme classification repository: Multi-label datasets and code, 2016. URL http://manikvarma.org/downloads/XC/XMLRepository.html.
+[6] C. W. Chang, H. F. Yu, K. Zhong, Y. Yang, and I. S. Dhillon. A Modular Deep Learning Approach for Extreme Multi-label Text Classification. CoRR, 2019.
+[7] W.-C. Chang, Y. H.-F., K. Zhong, Y. Yang, and I.-S. Dhillon. Taming Pretrained Transformers for Extreme Multi-label Text Classification. In KDD, 2020.
+[8] W.-C. Chang, F.-X. Yu, Y.-W. Chang, Y. Yang, and S. Kumar. Pre-training Tasks for Embedding-based Large-scale Retrieval. In ICLR, 2020.
+[9] K. Dahiya, D. Saini, A. Mittal, A. Shaw, K. Dave, A. Soni, H. Jain, S. Agarwal, and M. Varma. DeepXML: A Deep Extreme Multi-Label Learning Framework Applied to Short Text Documents. In WSDM, 2021.
+[10] K. Dahiya, N. Gupta, D. Saini, A. Soni, Y. Wang, K. Dave, J. Jiao, G. K, P. Dey, A. Singh, D. Hada, V. Jain, B. Paliwal, A. Mittal, S. Mehta, R. Ramjee, S. Agarwal, P. Kar, and M. Varma. Ngame: Negative mining-aware mini-batching for extreme classification. arXiv, 2022. doi: 10.48550/ARXIV.2207.04452. URL https://arxiv.org/abs/2207.04452.
+[11] J. Devlin, M. W. Chang, K. Lee, and K. Toutanova. BERT: Pre-training of deep bidirectional transformers for language understanding. *NAACL*, 2019.
+[12] R.-E. Fan, K.-W. Chang, C.-J. Hsieh, X.-R. Wang, and C.-J. Lin. Lib- linear: a library for large linear classification. In Journal of machine learning research, 2008.
+[13] C. Guo, A. Mousavi, X. Wu, D.-N. Holtmann-Rice, S. Kale, S. Reddi, and S. Kumar. Breaking the Glass Ceiling for Embedding-Based Classifiers for Large Output Spaces. In NeurIPS, 2019.
+[14] N. Gupta, S. Bohra, Y. Prabhu, S. Purohit, and M. Varma. Generalized zero-shot extreme multi-label learning. In Proceedings of the ACM SIGKDD Conference on Knowledge Discovery and Data Mining, August 2021.
+[15] H. Jain, Y. Prabhu, and M. Varma. Extreme Multi-label Loss Functions for Recommendation, Tagging, Ranking and Other Missing Label Applications. In KDD, August 2016.
+[16] H. Jain, V. Balasubramanian, B. Chanduri, and M. Varma. Slice: Scalable Linear Extreme Classifiers trained on 100 Million Labels for Related Searches. In WSDM, 2019.
+[17] V. Jain, N. Modhe, and P. Rai. Scalable Generative Models for Multi-label Learning with Missing Labels. In ICML, 2017.
+[18] T. Jiang, D. Wang, L. Sun, H. Yang, Z. Zhao, and F. Zhuang. LightXML: Transformer with Dynamic Negative Sampling for High-Performance Extreme Multi-label Text Classification. In AAAI, 2021.
+
+[19] S. Khandagale, H. Xiao, and R. Babbar. Bonsai: Diverse and shallow trees for extreme multi-label classification. Mach. Learn., 109(11):2099-2119, nov 2020. ISSN 0885-6125. doi: 10.1007/s10994-020-05888-2. URL https://doi.org/10.1007/s10994-020-05888-2.
+[20] P. D. Kingma and J. Ba. Adam: A Method for Stochastic Optimization. 2014.
+[21] T. Kraska, A. Beutel, E. Chi, J. Dean, and N. Polyzotis. The case for learned index structures. SIGMOD, 2018.
+[22] X. Liu, W.-C. Chang, H.-F. Yu, C.-J. Hsieh, and I. S. Dhillon. Label Disentanglement in Partition-based Extreme Multilabel Classification. In NeurIPS, 2021.
+[23] A. Y. Malkov and D. A. Yashunin. Efficient and robust approximate nearest neighbor search using Hierarchical Navigable Small World graphs. TPAMI, 2016.
+[24] T. Mikolov, I. Sutskever, K. Chen, G. Corrado, and J. Dean. Distributed Representations of Words and Phrases and Their Compositionality. In NIPS, 2013.
+[25] Y. Prabhu, A. Kag, S. Harsola, R. Agrawal, and M. Varma. Parabel: Partitioned label trees for extreme classification with application to dynamic search advertising. In WWW, 2018.
+[26] Y. Prabhu, A. Kusupati, N. Gupta, and M. Varma. Extreme Regression for Dynamic Search Advertising. In WSDM, 2020.
+[27] Y. Tay, V. Q. Tran, M. Dehghani, J. Ni, D. Bahri, H. Mehta, Z. Qin, K. Hui, Z. Zhao, J. Gupta, T. Schuster, W. W. Cohen, and D. Metzler. Transformer memory as a differentiable search index. arXiv, 2022. URL https://arxiv.org/abs/2202.06991.
+[28] T. Wei, W. W. Tu, and Y. F. Li. Learning for Tail Label Data: A Label-Specific Feature Approach. In IJCAI, 2019.
+[29] L. Xiong, C. Xiong, Y. Li, K.-F. Tang, J. Liu, P. Bennett, J. Ahmed, and A. Overwijk. Approximate nearest neighbor negative contrastive learning for dense text retrieval. arXiv preprint arXiv:2007.00808, 2020.
+[30] E. I. Yen, X. Huang, W. Dai, P. Ravikumar, I. Dhillon, and E. Xing. PPDSparse: A Parallel Primal-Dual Sparse Method for Extreme Classification. In KDD, 2017.
+[31] R. You, S. Dai, Z. Zhang, H. Mamitsuka, and S. Zhu. AttentionXML: Extreme Multi-Label Text Classification with Multi-Label Attention Based Recurrent Neural Networks. In NeurIPS, 2019.
+[32] H.-F. Yu, K. Zhong, J. Zhang, W.-C. Chang, and I. S. Dhillon. Pecos: Prediction for enormous and correlated output spaces. Journal of Machine Learning Research, 2022.
+[33] J. Zhang, W.-C. Chang, H.-F. Yu, and I. S. Dhillon. Fast multi-resolution transformer fine-tuning for extreme multi-label text classification. In NeurIPS, 2021.
\ No newline at end of file
diff --git a/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/images.zip b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..e80719ed222d1ecd57a8124160d149e228dc7351
--- /dev/null
+++ b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e6ef1a8c8ad97d6df86bf218a2fee711b78d9be30977ee7c8fa1f88eb2b93256
+size 453769
diff --git a/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/layout.json b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..1052ae2b103ac2c3ac528a9cc32a18f6c31e2d24
--- /dev/null
+++ b/eliasendtoendlearningtoindexandsearchinlargeoutputspaces/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6ea1261285e94bab370ed100da85785a3d4b09607fac5aed473658a6d065b8c0
+size 505626
diff --git a/elignexpectationalignmentasamultiagentintrinsicreward/d2241b05-7299-4094-8262-bb7c3a5373b5_content_list.json b/elignexpectationalignmentasamultiagentintrinsicreward/d2241b05-7299-4094-8262-bb7c3a5373b5_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..237821683cd820bae26ba8005b4bfba8bfc6c552
--- /dev/null
+++ b/elignexpectationalignmentasamultiagentintrinsicreward/d2241b05-7299-4094-8262-bb7c3a5373b5_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7da6eca4d026c2af7f94633d17392870ac022c0a949a1ee902aff74f6a9f2cde
+size 86953
diff --git a/elignexpectationalignmentasamultiagentintrinsicreward/d2241b05-7299-4094-8262-bb7c3a5373b5_model.json b/elignexpectationalignmentasamultiagentintrinsicreward/d2241b05-7299-4094-8262-bb7c3a5373b5_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..2856dec49b3ab21ad476503414c947c916dc3a25
--- /dev/null
+++ b/elignexpectationalignmentasamultiagentintrinsicreward/d2241b05-7299-4094-8262-bb7c3a5373b5_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:40d1c329642f3ced21bef889c281df20b01115397ed32ab1570daa4b70bc1a74
+size 109981
diff --git a/elignexpectationalignmentasamultiagentintrinsicreward/d2241b05-7299-4094-8262-bb7c3a5373b5_origin.pdf b/elignexpectationalignmentasamultiagentintrinsicreward/d2241b05-7299-4094-8262-bb7c3a5373b5_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..5420d26c23715a1f2facfe871e64f0f048f9f95c
--- /dev/null
+++ b/elignexpectationalignmentasamultiagentintrinsicreward/d2241b05-7299-4094-8262-bb7c3a5373b5_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4bff71bb0b158a6bc18f6854b1f0b35289c7063851a67cdd7b8a9f45da877cae
+size 1053523
diff --git a/elignexpectationalignmentasamultiagentintrinsicreward/full.md b/elignexpectationalignmentasamultiagentintrinsicreward/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..ef9743125a5d60a3cfb47ff4c5d742bbea70f4d6
--- /dev/null
+++ b/elignexpectationalignmentasamultiagentintrinsicreward/full.md
@@ -0,0 +1,353 @@
+# ELIGN: Expectation Alignment as a Multi-Agent Intrinsic Reward
+
+Zixian Ma $^{1}$ , Rose E. Wang $^{1}$ , Li Fei-Fei $^{1}$ , Michael Bernstein $^{1}$ , Ranjay Krishna $^{1,2}$
+
+Stanford University1, University of Washington2
+
+{zixianma,rewang,feifeili,msb,ranjaykrishna}@cs.stanford.edu
+
+# Abstract
+
+Modern multi-agent reinforcement learning frameworks rely on centralized training and reward shaping to perform well. However, centralized training and dense rewards are not readily available in the real world. Current multi-agent algorithms struggle to learn in the alternative setup of decentralized training or sparse rewards. To address these issues, we propose a self-supervised intrinsic reward ELIGN - expectation alignment - inspired by the self-organization principle in Zoology. Similar to how animals collaborate in a decentralized manner with those in their vicinity, agents trained with expectation alignment learn behaviors that match their neighbors' expectations. This allows the agents to learn collaborative behaviors without any external reward or centralized training. We demonstrate the efficacy of our approach across 6 tasks in the multi-agent particle and the complex Google Research football environments, comparing ELIGN to sparse and curiosity-based intrinsic rewards. When the number of agents increases, ELIGN scales well in all multi-agent tasks except for one where agents have different capabilities. We show that agent coordination improves through expectation alignment because agents learn to divide tasks amongst themselves, break coordination symmetries, and confuse adversaries. These results identify tasks where expectation alignment is a more useful strategy than curiosity-driven exploration for multi-agent coordination, enabling agents to do zero-shot coordination.
+
+# 1 Introduction
+
+Many real world AI applications can be formulated as multi-agent systems, including autonomous vehicles (Cao et al., 2012), resource management (Ying & Dayong, 2005), traffic control (Sunehag et al., 2017), robot swarms (Swamy et al., 2020), and multi-player video games (Berner et al., 2019). Agents must adapt their behaviors to each other in order to coordinate successfully in these systems. However, adaptive coordination algorithms are challenging to develop because each agent is not privy to other agents' intentions and their future behaviors (Foerster et al., 2017).
+
+These challenges are more acute in decentralized training under partial observability than centralized training or full observability. In the real world, agents act under partial observability and learn in a decentralized manner: they do not learn collaborative behaviors with a single centralized algorithm with a complete knowledge of the environment (Iqbal & Sha, 2019; Liu et al., 2020). Unfortunately, the most successful multi-agent algorithms train agents with a centralized critic, assuming access to all agents' observations and actions (Foerster et al., 2018; Rashid et al., 2018; Sunehag et al., 2017; Lowe et al., 2017). The most successful multi-agent algorithms for decentralized training and partial observability assume task-specific reward shaping (Jain et al., 2020; Iqbal & Sha, 2019), which is expensive to generate. These algorithms struggle to learn with sparse reward structure.
+
+Consider a cooperative navigation task, where $N$ agents aim to simultaneously occupy $N$ goal locations. A centralized algorithm with full observability is capable of optimally assigning the nearest
+
+
+Agent j's dynamics prediction of i
+
+$$
+\overline {{r _ {\mathrm {i n}} \left(o _ {i} , a _ {i}\right) = - \frac {1}{\left| \mathcal {N} (i) \right|} \sum_ {j \in \mathcal {N} (i)} \left\| o _ {i} ^ {\prime} - f _ {\theta_ {j}} \left(o _ {i} , a _ {i}\right) \right\|}}
+$$
+
+
+Figure 1: We introduce ELIGN, i.e., expectation alignment, a task-agnostic intrinsic reward to improve multi-agent systems. Intuitively, ELIGN encourages agents to become more predictable to their neighbors. An agent (e.g., agent $i$ here) learns to behave in ways that match its neighbors' (e.g., agent $j$ 's) predictions of its next observation. Here, agent $j$ expects agent $i$ to move up instead of down, moving closer to a point of interest above it. Agent $i$ attains (a) a higher reward when its action (e.g., upward) aligns with this expectation or (b) a lower reward when its action (e.g., downward) is misaligned.
+
+
+(a) Aligned $\rightarrow$ high $r_{\mathrm{in}}$
+(b) Misaligned $\rightarrow$ low $r_{\mathrm{in}}$
+
+
+Agent i
+
+
+Agent j
+
+
+Goal
+
+
+Receptive field
+
+goal location to each respective agent. However, with partial observability, agents can see only a handful of goal locations and other agents. They are unaware of others' observations, actions, and intentions with decentralized training. We observe that agents simultaneously occupy the same goal; they fail to collaborate because they do not predict which goal each agent is expected to occupy. To overcome instances of miscoordination, decentralized algorithms have adapted single-agent curiosity-based intrinsic rewards (Pathak et al., 2017; Stadie et al., 2015). Multi-agent curiosity-based rewards incentivize agents to explore novel states (Iqbal & Sha, 2020). Although curiosity helps agents discover new goal locations, it doesn't solve the challenge of coordination, such as assigning goals to each agent. Only a few attempts explore other forms of multi-agent intrinsic rewards (Iqbal & Sha, 2020; Bohmer et al., 2019; Schafer, 2019).
+
+In this work, we propose ELIGN as a novel multi-agent self-supervised intrinsic reward, enabling decentralized training under partial observability. Intuitively, expectation alignment encourages agents to elicit behaviors that decrease future uncertainty for their team: it encourages each agent to choose actions that match their teammates' expectations. Going back to the cooperative navigation task, expectation alignment encourages each agent to move to goals others expect it to occupy, like goals that are either closest to the agent or goals that other agents aren't moving towards (Figure 1). We take inspiration from the self-organization principle in Zoology (Couzin, 2007). This principle hypothesizes that collective animal intelligence emerges because groups synchronize their behaviors using only their local environment; they do not rely on complete information about other agents and can coordinate successfully by predicting the dynamics of agents within their field-of-view (Collett et al., 1998; Theraulaz & Bonabeau, 1995; Ben-Jacob et al., 1994; Buhl et al., 2006). Similarly, expectation alignment as an intrinsic reward is calculated based on the agent's local observations and its approximation of neighboring agents' expectations. It does not require a centralized controller nor full observability. ELIGN is task-agnostic and we apply it to both collaborative and competitive multi-agent tasks.
+
+We demonstrate the efficacy of our approach in the multi-agent particle and Google Research football environments, two popular benchmarks for multi-agent reinforcement learning (Lowe et al., 2017; Kurach et al., 2019). We evaluate ELIGN under partial and full observability, with decentralized and centralized training, and in terms of scalability. We observe that expectation alignment outperforms sparse and curiosity-based intrinsic rewards (Ndousse et al., 2021; Stadie et al., 2015; Iqbal & Sha, 2020), especially under partial observability with decentralized training. We additionally test expectation alignment as a way to perform zero-shot coordination with new agent partners, and investigate why ELIGN improves coordination. We show that agent coordination improves through expectation alignment because agents learn to divide tasks amongst themselves and break coordination symmetries (Hu et al., 2020).
+
+# 2 Related Work
+
+Our formulation of expectation alignment, a task-agnostic intrinsic reward for multi-agent training, draws inspiration from the self-organization principle in Zoology, which posits that synchronized group behavior is mediated by local behavioral rules (Couzin, 2007) and not by a centralized controller (Camazine et al., 2020). Group cohesion emerges by predicting and adjusting one's behavior to that of near neighbors (Buhl et al., 2006). This principle underlies the coordination found in multi-cellular organisms (Camazine et al., 2020), the migration of wingless locusts (Collett et al., 1998), the collective swarms of bacteria (Ben-Jacob et al., 1994), the construction of bridge structures by ants (Theraulaz & Bonabeau, 1995), and some human navigation behaviors (Couzin, 2007).
+
+Intrinsic motivation for single agents. Although we draw inspiration from Zoology for formalizing expectation alignment as an intrinsic reward, there is a rich body of work on intrinsic rewards within the single-agent reinforcement learning community. To incentivize exploration, even when non-optimal successful trajectories are uncovered first, scholars have argued for the use of intrinsic motivation (Schmidhuber, 1991). Single-agent intrinsic motivation has focused on exploring previously unencountered states (Pathak et al., 2017; Burda et al., 2018a), which works particularly well in discrete domains. In continuous domains, identifying unseen states requires keeping track of an intractable number of visited states; instead, literature has recommended learning a forward dynamics model to predict future states and identify novel states using the uncertainty of this model (Achiam & Sastry, 2017). Other formulations encourage re-visiting states where the dynamics model's prediction of future states errs (Stadie et al., 2015; Pathak et al., 2017). Follow up papers have improved how uncertainty (Kim et al., 2020) and model errors (Burda et al., 2018b; Sekar et al., 2020) are calculated.
+
+Intrinsic motivation for multiple agents. Most multi-agent intrinsic rewards have been adapted from single-agent curiosity-based incentives (?Bohmer et al., 2019; Schafer, 2019) and have primarily focused on cooperative tasks. They propose intrinsic rewards to improve either coordination, collaboration, or deception: These rewards either maximize information conveyed by an agent's actions (?Chitnis et al., 2020; Wang et al., 2019), shape the influence of an agent (Jaques et al., 2019; Foerster et al., 2017), incentivize agents to hide intentions (Strouse et al., 2018), build accurate models of other agents' policies (Hernandez-Leal et al., 2019; Jaques et al., 2019), or break extrinsic rewards for better credit assignment (Du et al., 2019).
+
+Several multi-agent intrinsic rewards (Hernandez-Leal et al., 2019; Jaques et al., 2019), including ours, rely on the ability to model others' dynamics in a shared environment. This ability is a key component to coordination, closely related to Theory of Mind (Tomasello et al., 2005). Our work can be interpreted as using a Theory of Mind model of others' behaviors to calculate an intrinsic motivation loss. Unlike existing Theory of Mind methods that learn a model per collaborator (Roy et al., 2020), we learn a single dynamics model, allowing our method to scale as the number of agents increase. Our proposal is related to model-based reinforcement learning (Jaderberg et al., 2016; Wang et al., 2020a); however, instead of learning a dynamics model for control, we learn a dynamics model as a source of reward. Our work is closely related to a recently proposed auxiliary loss on predicting an agent's own future states (Ndousse et al., 2021). However, there are three key differences. First, their work predicts ego-agent observations, whereas our work additionally predicts future observations from the other agents' point of view. Second, their loss optimizes state embeddings while ours optimizes agents' policies. Third, their work focuses on cooperative tasks whereas ours applies to both cooperative and competitive domains.
+
+Multi-agent reinforcement learning algorithms. Today, the predominant deep multi-agent framework uses actor-critic methods with a centralized critic and decentralized execution (Lowe et al., 2017; Foerster et al., 2018; Iqbal & Sha, 2019; Liu et al., 2020; Rashid et al., 2018). This framework allows a critic to access the observations and actions of all agents to ease training. However, there are several situations where centralized training may not be desirable or possible. Examples include low bandwidth communication restrictions or human-robot tasks where observations cannot be easily shared between agents (Ying & Dayong, 2005; Cao et al., 2012; Huang et al., 2015). Decentralized training is therefore the most practical training paradigm but it suffers from unstable training: the environment is nonstationary from a single-agent's perspective (Lowe et al., 2017). Our work uses a decentralized training framework and tackles the nonstationarity challenge with an intrinsic reward designed to improve an agent's ability to model others. We also apply expectation alignment to centralized training and observe that it still aids cooperative and some competitive tasks.
+
+# 3 Background
+
+We formulate our setting as a partially observable Markov game $(S, \mathcal{O}, \mathcal{A}, \mathcal{T}, r_{\mathrm{ex}}, N)$ (Littman, 1994). A Markov game for $N$ agents is defined by a state space $\mathcal{S}$ describing the possible configurations of the environment. The observation space for agents is $\mathcal{O} = (\mathcal{O}_1, \dots, \mathcal{O}_N)$ and the action space is $\mathcal{A} = (\mathcal{A}_1, \dots, \mathcal{A}_N)$ . Each agent $i$ observes $\mathbf{o}_i \in \mathcal{O}_i$ , a private partial view of the state, and performs actions $a_i \in \mathcal{A}_i$ . Using the observation, each agent uses a stochastic policy $\pi_{\theta_i}: \mathcal{O}_i \times \mathcal{A}_i \to [0,1]$ , where $\theta_i$ parameterizes the policy. The environment changes according to the state transition function which transitions to the next state using the current state and each agent's actions, $\mathcal{T}: S \times \mathcal{A} \to S$ . The team of agents obtains a shared extrinsic reward as a function of the environment state, $r_{\mathrm{ex}}: S \times \mathcal{A} \to \mathbb{R}$ . The team's goal is to maximize the total expected return: $R = \sum_{t=0}^{T} \gamma^t r_{\mathrm{ex}}^t$ where $0 \leq \gamma \leq 1$ is the discount factor, $t$ is the time step, and $T$ is the time horizon. The environment may also contain adversarial agents who have their own reward structure.
+
+# 4 Expectation Alignment
+
+To understand expectation alignment intuitively, let's revisit the cooperative navigation task, where $N$ agents are rewarded for simultaneously occupying as many goal locations as possible. In Figure 1, agent $i$ has a dynamics model trained on its past experiences. It predicts how future states will evolve from the point of view of agent $j$ , who is within $i$ 's view. In this example, $j$ will expect $i$ to move towards the goal since $i$ is closer to it. ELIGN encourages $i$ to pursue the action that $j$ expects (Figure 1(a)). In turn, $j$ can now assume that the observed goal location will eventually be occupied by $i$ and should therefore explore to find another goal. By aligning shared expectations, agent behaviors become more predictable. Conversely, when neighbors behave opposite to an agent's predictions, the agent can infer about the environment outside of its own receptive field (Krause et al., 2002). For example, in Figure 1 (b), if agent $j$ observes $i$ running away from a goal, this surprising behavior might indicate the existence of an adversary outside $j$ 's receptive field.
+
+Our training algorithm consists of three interwoven phases of learning a dynamics model, calculating the ELIGN reward, and optimizing the agent's policy (Algorithm 1).
+
+# 4.1 Training the dynamics model
+
+Similar to prior work (Wang et al., 2018; Kidambi et al., 2020), each agent $i$ learns a dynamics model $f_{\theta_i}$ to predict the next observation $\hat{o}_i^\prime$ given its current observation and action $o_i, a_i$ , i.e,
+
+$$
+\hat {o} _ {i} ^ {\prime} = f _ {\theta_ {i}} \left(o _ {i}, a _ {i}\right).
+$$
+
+We use a three-layer Multi-Layer Perceptron with ReLU non-linearities as the dynamics model. We minimize the mean squared error between its prediction and ground truth next observation $o_{i}^{\prime}$ .
+
+# 4.2 Calculating intrinsic reward
+
+The intrinsic reward captures how well agent $i$ aligns to its neighbors' (e.g., agent $j$ 's) expectations on its next state. Calculating this reward requires $j$ to accurately predict $i$ 's behavior, simulating a Theory of Mind (Tomasello et al., 2005). As suggested by the self-organization principle, $i$ must learn to align to $j$ 's predictions. Ideally, the ELIGN intrinsic reward is calculated as:
+
+$$
+r _ {\mathrm {i n}} \left(o _ {i}, a _ {i}\right) = - \frac {1}{\left| \mathcal {N} (i) \right|} \sum_ {j \in \mathcal {N} (i)} \left\| o _ {i} ^ {\prime} - f _ {\theta_ {j}} \left(o _ {i}, a _ {i}\right) \right\|
+$$
+
+where $\mathcal{N}(i)$ is the set of neighbors within $i$ 's receptive field, including $i$ itself. The ELIGN reward is high when the average $L_{2}$ loss is small, i.e., when $i$ 's actual next observation is close to agent $j$ 's predicted observation of $i$ for all $j$ in its neighbors. In that case, $i$ has chosen an action that aligns with $j$ 's expectations of how $i$ should act.
+
+In a decentralized training setup, however, $i$ doesn't have access to $j$ 's dynamics model $f_{\theta_j}$ , so $i$ approximates $j$ 's dynamic model with a proxy: its own dynamics model $f_{\theta_i}$ and the knowledge of agent $j$ 's observation radius. Such an approximation is ecologically valid since we often approximate others' behaviors using a second-order cognitive Theory of Mind (Morin, 2006). Additionally, $i$
+
+doesn't have access to $j$ 's entire observation; so, we restrict the future prediction from $j$ 's point of view by using the portion of $j$ 's observation $i$ can see: $o_{i \cap j} = o_i \odot o_j$ . Agent $i$ 's decentralized intrinsic reward then becomes:
+
+$$
+r _ {\mathrm {i n}} \left(o _ {i}, a _ {i}\right) = - \frac {1}{\left| \mathcal {N} (i) \right|} \sum_ {j \in \mathcal {N} (i)} \left\| o _ {i \cap j} ^ {\prime} - f _ {\theta_ {i}} \left(o _ {i \cap j}, a _ {i}\right) \right\|
+$$
+
+We found that the approximation of $f_{\theta_j}$ using $f_{\theta_i}$ works well empirically. Dynamics model losses for all agents quickly decrease within 5-10 training epochs. we validate its applicability in small-scale heterogeneous multi-agent tasks where agents have variable capabilities, although we find the methods perform similarly when more heterogeneous agents are added.
+
+# 4.3 Policy learning
+
+Once the ELIGN rewards are calculated, the total rewards at each step for each agent $i$ is: $r_i = r_{\mathrm{ex}} + \beta r_{\mathrm{in}}(o_i,a_i)$ where $r_{\mathrm{ex}}$ is the extrinsic reward provided by the environment and $\beta$ is a hyperparameter for weighing the intrinsic reward in the agent's overall reward calculation. In practice, we set $\beta$ to be $\frac{1}{|\mathcal{O}_i|}$ where $|\mathcal{O}_i|$ is the observation dimension; we find this scale generalizes well across tasks. Since our contribution is ag- nostic to any particular multi-agent training algo- rithm, the team of agents can now be trained using any multi-agent training algorithm to maximize returns $R = \sum_{t = 0}^{T}\gamma^{t}r.$
+
+Both centralized and decentralized training algorithms can make use of these rewards. We primarily use the multi-agent decentralized variant of the soft-actor critic algorithm in our experiments (Haarnoja et al., 2018; Iqbal & Sha, 2019). Compared to centralized joint-action training, whose action space grows exponentially in $N$ agents, our decentralized method has linear space complexity. Further, decentralized training can parallelize training time to be less than linear with respect to $N$ . Although we present results
+
+with one centralized training framework, studying the impact of expectation alignment with all the centralized critic frameworks is out of scope for this paper.
+
+Algorithm 1 ELIGN: Expectation Alignment
+1: Initialize replay buffer $D$ and $D'$
+2: Initialize $N$ agents with random $\theta_{i}$ : $i\in [1,N]$
+3: while not converged do
+4: for $b = 1\dots B$ do
+5: Populate buffer $D$ with episode using policies $(\pi_{\theta_1},\dots,\pi_{\theta_N})$
+6: end for
+7: // TRAIN DYNAMICS MODEL
+8: for agent $i = 1\dots N$ do
+9: Sample transitions: $\{(o_i,a_i,r_{\mathrm{ex}},o_i^{\prime})\} \sim D_i$
+10: Predict $\hat{o}_i^{\prime} = f_{\theta_i}(o_i,a_i)$
+11: Update dynamics $\theta_{i}$ using $o_i^\prime$
+12: end for
+13: // CALCULATE ELIGN REWARD
+14: for agent $i = 1\dots N$ do
+15: Sample $B$ transitions: $\{(o_i,a_i,r_{\mathrm{ex}},o_i^{\prime})\} \sim D_i$
+16: Compute intrinsic rewards $r_{\mathrm{in}}(o_i,a_i)$
+17: Add $\{(o_i,a_i,r_{\mathrm{ex}} + \beta r_{\mathrm{in}},o_i^{\prime})\}$ to $D_i^\prime$
+18: end for
+19: // POLICY LEARNING
+20: Update all $\theta_{i}$ s using transitions from $D^{\prime}$
+21: end while
+
+# 4.4 Extending expectation alignment to competitive tasks
+
+We extend the ELIGN formulation to competitive tasks where a team of agents compete against adversaries. In this case, agents are encouraged to misalign with their adversaries' expectations, i.e., agents are incentivized to be unpredictable to their adversaries within its receptive field $(\mathcal{N}_{\mathrm{adv}}(i))$ :
+
+$$
+r _ {\mathrm {i n}} = \frac {1}{\left| \mathcal {N} _ {\mathrm {a d v}} (i) \right|} \sum_ {k \in \mathcal {N} _ {\mathrm {a d v}} (i)} \left\| o _ {i \cap k} ^ {\prime} - f _ {\theta_ {i}} \left(o _ {i \cap k}, a _ {i}\right) \right\|
+$$
+
+# 5 Experiments
+
+Our experiments explore the utility of using expectation alignment as an intrinsic reward compared to sparse and curiosity-based intrinsic rewards. We primarily focus on decentralized training under partial observability. However, we also demonstrate that ELIGN can easily augment centralized methods and assist in fully observable tasks. We vary the number of agents in the multi-agent particle tasks to test scalability. We end by investigating how and why ELIGN improves coordination by designing three evaluation conditions. First, does expectation alignment improve coordination by
+
+Table 1: We report the mean test episode extrinsic rewards and standard errors of decentralized training under partial observability in multi-agent particle and Google Research football environments. $\mathrm{ELIGN}_{\mathrm{self / team}}$ outperform SPARSE and both curiosity-based intrinsic rewards. $\mathrm{ELIGN}_{\mathrm{adv}}$ achieves the best performance among all competitive tasks except for Physical deception, where $\mathrm{ELIGN}_{\mathrm{team}}$ is the best. These results demonstrate the benefit of using alignment as intrinsic reward to train better decentralized policies under partial observability.
+
+| Task (Agt# v Adv#) | Cooperative | Competitive |
| Coop nav. (3v0) | Hetero nav. (4v0) | Phy decep. (2v1) | Pred-prey (2v2) | Keep-away (2v2) | 3v1 w/ keeper (3v2) |
| SPARSE1 | 139.07 ± 13.63 | 284.42 ± 12.83 | 93.60 ± 8.61 | -4.72 ± 2.4 | 4.58 ± 3.27 | 0.020 ± 0.001 |
| CURIO2self | 133.93 ± 7.66 | 286.22 ± 9.97 | 68.80 ± 7.93 | -6.50 ± 2.18 | 11.88 ± 2.88 | 0.024 ± 0.004 |
| CURIO3team | 125.42 ± 11.95 | 262.28 ± 22.59 | 85.31 ± 11.93 | -3.57 ± 1.75 | 9.54 ± 5.04 | 0.021 ± 0.002 |
| ELIGNSelf | 155.88 ± 5.11 | 292.34 ± 9.24 | 69.91 ± 4.51 | -7.58 ± 2.55 | 12.84 ± 4.29 | 0.003 ± 0.018 |
| ELIGNteam | 141.04 ± 8.04 | 311.67 ± 10.88 | 101.72 ± 6.31 | -7.69 ± 2.69 | 2.96 ± 4.03 | 0.022 ± 0.001 |
| ELIGNadv | — | — | 92.20 ± 4.23 | -2.51 ± 1.70 | 19.46 ± 5.05 | 0.025 ± 0.001 |
| HAND-CRAFTED1 | 75.56 ± 18.90 | 228.48 ± 18.88 | 94.25 ± 14.75 | -0.77 ± 0.17 | 52.14 ± 3.11 | — |
| 1 Lowe et al. (2017); Kurach et al. (2019),2 Stadie et al. (2015),3 Iqbal & Sha (2020) |
+
+
+Figure 2: We plot the average test occupancy/collision count per step of decentralized algorithms under partially observable multi-agent particle tasks. On these metrics, $\mathrm{ELIGN}_{\mathrm{self}}$ and $\mathrm{ELIGN}_{\mathrm{adv}}$ perform the best on cooperative and competitive tasks respectively.
+
+
+Test Occupancy $(\uparrow)$ /Collision $(\downarrow)$ Count Per Step
+
+
+
+
+
+
+
+breaking symmetries (Hu et al., 2020; Wang et al., 2020b)? Second, does ELIGN enable zero-shot generalization to new partners? Lastly, is the dynamics model critical in aligning agent behaviors?
+
+# 5.1 Environments
+
+We evaluate ELIGN across both cooperative and competitive tasks in the multi-agent particle environment (Mordatch & Abbeel, 2017; Lowe et al., 2017) and the Google Research football environment (Kurach et al., 2019).
+
+State and action space The multi-agent particle environment is a two-dimensional world. The Google Research football environment is a three-dimensional world. Both environments have continuous state spaces and discrete action spaces. Particle agents observe all agents' positions and velocities. They can "stay" or change their velocity in one of the four cardinal directions. Each football agent controls one player. Players observe the ball, other players' positions and directions. They can apply one of ten actions from "top_left", "top", "top_right", "right", "bottom_right", "bottom", "bottom_left", "sprint", and "dribble".
+
+Observability The original environments assume full observability, where each agent can observe the position $p = (x,y)$ and velocity $v = (\Delta x, \Delta y)$ of all agents; each agent's observation vector is thus $\mathbf{o}_{i,\mathrm{full}} = [p_1, \ldots, p_N, v_1, \ldots, v_N]$ . We extend these environments to be partially observable, where agent $i$ observes only the portion within its receptive field; like prior work with partial observability (Corder et al., 2019), we hide the position and velocity information of any agent $j$ outside of agent $i$ 's receptive field; i.e., if the Euclidean distance between agent $i$ and $j$ surpasses a vicinity threshold $\tau$ , then $p_j$ and $v_j$ are 0 in $\mathbf{o}_{i,\mathrm{partial}}$ . We set $\tau = 0.5$ for partially observable and $\infty$ in the original fully observable case, where the world's width and height are 2.0 in the multi-agent particle environment and 0.84:2.00 in the Google Research football environment. Both environments also contain objects such as obstacles, goals and a ball; they are similarly hidden if out of sight. Partial observability is a more ecologically valid training condition since most agents in real-world tasks can only observe a small portion of their environment at a given time.
+
+# 5.2 Tasks
+
+Multi-agent particle environment We use the following tasks from the multi-agent particle environment (Lowe et al., 2017; Liu et al., 2020). We choose $N$ based on prior work.
+
+Table 2: We report the mean test episode extrinsic rewards and standard errors as the number of agents is increased and trained using of decentralized algorithms. When the number of agents increases, one of ELIGN still performs the best in all tasks except for Heterogenous navigation.
+
+| Task (Agt # vs. Adv #) | Cooperative | Competitive |
| Coop nav. (5v0) | Hetero nav. (6v0) | Phy decep. (4v2) | Pred-prey (4v4) | Keep-away (4v4) |
| SPARSE1 | 459.92 ± 22.44 | 616.62 ± 25.30 | 166.89 ± 27.72 | -28.75 ± 7.3 | 0.75 ± 1.82 |
| CURIO2self | 458.45 ± 19.79 | 702.73 ± 18.57 | 146.55 ± 29.05 | -25.35 ± 6.16 | 10.52 ± 5.48 |
| CURIO3team | 497.15 ± 11.47 | 695.38 ± 12.22 | 84.66 ± 16.94 | -17.21 ± 8.23 | 1.40 ± 2.06 |
| ELIGNself | 498.24 ± 9.77 | 646.70 ± 23.25 | 137.38 ± 30.00 | -9.14 ± 5.57 | 9.83 ± 11.22 |
| ELIGNteam | 488.83 ± 20.82 | 638.74 ± 28.93 | 186.83 ± 21.92 | -20.4 ± 5.93 | 2.07 ± 4.55 |
| ELIGNadv | — | — | 182.61 ± 17.63 | -21.37 ± 7.02 | 11.29 ± 9.02 |
| 1 Lowe et al. (2017),2Stadie et al. (2015),3Iqbal & Sha (2020) |
+
+Cooperative navigation: $N$ agents must cooperate to reach a set of $N$ goal locations. Agents are collectively rewarded based on the occupancy of any agent on any goal location.
+
+Heterogeneous navigation: $N$ agents must reach $N$ goals but they differ in speeds and sizes. $\frac{N}{2}$ agents are slow and big, and the other $\frac{N}{2}$ agents are fast and small.
+
+Physical deception: $N$ agents cooperate to reach a single goal location and are rewarded if any one occupies the goal. However, they are penalized when any of $\frac{N}{2}$ adversaries occupies the goal and gets rewarded. The adversaries do not know which landmark is the goal and must infer it from the agents' behavior. The agents should learn to deceive the adversaries by covering all the landmarks.
+
+Keep-away: There are $N$ landmarks, one of which is the goal and known to $N$ agents. Agents are rewarded for occupying it and preventing $M$ adversaries from reaching it. Adversaries are rewarded for pushing the agents away from the goal, but they can only infer which landmark is the goal.
+
+Predator-prey: $N$ slow adversaries chase and capture $N$ fast cooperating agents around a randomly generated obstacle-filled environment. Each time an adversary catches an agent, the agent is penalized and the adversary is rewarded.
+
+Google Research football We use the Academy 3vs1 with Keeper competitive task from the Google Research football environment (Kurach et al., 2019). In this task, three agents try to score from the edge of the penalty box, one on each side, and the other at the center. This task is initialized with the centered agent having the ball and facing the defender. There is an adversary who plays the keeper.
+
+# 5.3 Training and evaluation
+
+We train all algorithms with 5 random seeds. All the hyperparameters used in the training can be found in the Appendix. For the Multi-agent particle environment, each experiment uses one Tesla K40 GPU to train until convergence, i.e. the best evaluation episode reward hasn't changed for 100 epochs. Each epoch equates to $4K$ episodes of 25 timesteps. We evaluate the algorithms by running $1K$ test episodes of 25 timesteps and mainly report the mean average test episode reward and standard error across the random seeds. We also evaluate on task-specific metrics, including agent-goal occupancy/agent-adversary collision count, and agent-goal/agent-adversary distance. For Google Research football, each experiment trains for $5M$ timesteps. We evaluate on and report the mean average episode rewards and the standard errors across the seeds.
+
+# 5.4Baselines
+
+All algorithms are trained using the same agent architecture and optimization algorithm. They vary in task-specific extrinsic rewards and intrinsic rewards. We use two versions of the soft actor-critic algorithm Haarnoja et al. (2018): a decentralized one that trains each agent individually without access to other agents' observations and actions (ie. the original soft-actor critic algorithm) and a centralized one with a critic that has access to other agents' observations and actions (Iqbal & Sha, 2019). Note, our intrinsic reward can also be added to non-actor-critic methods, such as COMA (Foerster et al., 2018) and VDN (Sunehag et al., 2017). We leave this to future work to avoid conflating the effects of expectation alignment with COMA's counterfactual reasoning and VDN's value decomposition.
+
+We use SPARSE (Lowe et al., 2017; Kurach et al., 2019), $\mathrm{CURIO}_{\mathrm{self}}$ (Stadie et al., 2015), $\mathrm{CURIO}_{\mathrm{team}}$ (Iqbal & Sha, 2020), and variations of our ELIGN rewards. SPARSE rewards agents
+
+only when they reach a goal state. $\mathrm{CURIO}_{\mathrm{team}}$ is a curiosity-based multi-agent intrinsic reward which maximizes the average $L_{2}$ loss (instead of minimizing it in ELIGN). It rewards agents for exploring novel states (Iqbal & Sha, 2020). $\mathrm{CURIO}_{\mathrm{self}}$ also maximizes the $L_{2}$ loss but only using agent $i$ 's own observation (Stadie et al., 2015). We experiment with three variants of ELIGN: $\mathrm{ELIGN}_{\mathrm{self}}$ , incentivizing alignment to one's own expectation $\mathrm{ELIGN}_{\mathrm{team}}$ incentivizing agents to align to their team, and $\mathrm{ELIGN}_{\mathrm{adv}}$ incentivizing misalignment to adversaries' expectations. Note that $\mathrm{ELIGN}_{\mathrm{self}}$ is similar to the auxiliary loss in Ndousse et al. (2021) but we use it for policy optimization, rather than for training a state encoder. We also add hand-crafted dense rewards to provide oracle performance for all tasks.
+
+# 5.5 Results in partially observable environments with decentralized training
+
+ELIGN outperforms baselines across cooperative and competitive tasks in the multi-agent particle environment. Table 1 demonstrates that both $\mathrm{ELIGN}_{\mathrm{self}}$ and $\mathrm{ELIGN}_{\mathrm{team}}$ outperform all SPARSE and $\mathrm{CURIO}_{\mathrm{self}/\mathrm{team}}$ baseline rewards in cooperative tasks. While not all ELIGN variants surpass the baselines in competitive tasks, we find that $\mathrm{ELIGN}_{\mathrm{team}}$ achieves the highest reward in Physical deception, and $\mathrm{ELIGN}_{\mathrm{adv}}$ performs the best in Predator-prey and Keep-away. Similarly, Figure 2 shows that $\mathrm{ELIGN}_{\mathrm{self}}$ achieves the highest per-step occupancy count in both cooperative tasks, and $\mathrm{ELIGN}_{\mathrm{adv}}$ does the best in all competitive tasks.
+
+ELIGN outperforms baselines in the complex Google Research football environment. As shown in Table 1, $\mathrm{ELIGN}_{\mathrm{adv}}$ achieves the best mean average episode reward in the competitive Academy 3vs1 with keeper task. Collectively, these results provide empirical evidence that the self-organizing principle improves coordination under partial information, a setting that is most realistic to real world multi-agent systems.
+
+In competitive tasks, agents benefit more from being misaligned to adversaries than being aligned to their team members. Among the four competitive tasks in the multi-agent particle and football environments, we find that $\mathrm{ELIGN}_{\mathrm{adv}}$ outperforms all SPARSE and $\mathrm{CURIO}_{\mathrm{self/team}}$ baselines and other variants of ELIGN in Predator-prey, Keep-away and Academy 3vs1 with keeper. This suggests that being misaligned to adversaries, ie taking surprising actions that conflict with the adversary's expectations, might be a more useful strategy in multi-agent competitive tasks.
+
+When the number of agents increases, ELIGN scales well in all multi-agent particle tasks except for Heterogenous navigation. Table 2 shows that our ELIGN intrinsic reward still largely achieves the best performance when more agents are added to cooperative and competitive tasks. The only exception is the Heterogenous navigation task, where both $\mathrm{ELIGN}_{\mathrm{self}}$ and $\mathrm{ELIGN}_{\mathrm{team}}$ outperform SPARSE but not $\mathrm{CURIO}_{\mathrm{self/team}}$ . We hypothesize that it is more difficult for agents to predict their neighbors' future states accurately when there are more agents with different sizes and speeds, and errors in dynamics prediction could lead to misleading alignment signals. Further, we see a consistent increase in $\mathrm{ELIGN}_{\mathrm{team}}$ 's performance compared against SPARSE even when the number of agents scales to ten in Cooperative navigation (Figure 3).
+
+# 5.6 Results with full observability and centralized ELIGN
+
+
+Figure 3: $\mathrm{ELIGN}_{\mathrm{team}}$ achieves consistent gains compared against SPARSE when the number of agents increases in the Cooperative navigation task.
+
+We further test the utility of decentralized ELIGN in fully observable environments and centralized ELIGN under partial observability. We find that decentralized expectation alignment helps in fully observable Cooperative navigation, Heterogenous navigation, and Predator-prey, tasks where expectation alignment has been observed in nature. Similarly, centralized ELIGN also improves agents' performance compared against SPARSE and $\mathrm{CURIO}_{\mathrm{self / team}}$ rewards in the same tasks with partial observability. These results can be found in Tables 3 and 4 in the Appendix. As full observability and centralized training are our main focus, we leave it to future work to investigate why expectation alignment benefits these tasks but not others.
+
+# 5.7 Investigating how the ELIGN reward helps
+
+
+Figure 5: We plot the test occupancy/collision count per step of decentralized algorithms in symmetry-breaking settings under partial observability. $\mathrm{ELIGN}_{\mathrm{self}}$ performs the best in both cooperative tasks. $\mathrm{ELIGN}_{\mathrm{team}}$ and $\mathrm{ELIGN}_{\mathrm{adv}}$ are the best strategies in Physical deception and Predator-prey.
+
+
+Figure 6: Test performance decreases with dynamics model loss ( $R^2 = 0.242$ ), implying that ALIGN requires an accurate dynamics model.
+
+We further investigate how expectation alignment improves coordination through three evaluation setups.
+
+ELIGN helps agents divide subtasks. A core challenge in multiagent collaboration is efficient task division (Wang et al., 2020b). Here, we test whether expectation alignment improves sub-task allocation. We initialize agents in states without an optimal
+
+
+Figure 4: We visualize the symmetry-breaking setups in three example tasks. More details can be found in the Appendix.
+
+sub-task allocation, necessitating symmetry-breaking (Hu et al., 2020). Figure 4 illustrates the symmetry-breaking setups: in cooperative navigation, when agents are initialized equidistant to all the goal locations, there isn't an optimal allocation of agents to goals. We find that $\mathrm{ELIGN}_{\mathrm{self}}$ achieves the best performance in both cooperative tasks, while $\mathrm{ELIGN}_{\mathrm{team}}$ and $\mathrm{ELIGN}_{\mathrm{adv}}$ are the best strategies in Physical deception and Predator-prey respectively (Figure 5). Upon a qualitative evaluation of Cooperative navigation, we observe that agents with expectation alignment are able to predict which goals will be covered by their collaborators and move towards their allocated one. Without expectation alignment, agents move towards the same goal.
+
+ELIGN helps agents generalize to new partners. Another core challenge in multi-agent collaboration is zero-shot coordination, where agents are tested to collaborate with new partners they haven't been trained with. We study whether expectation alignment enables better zero-shot coordination. New partners are sampled from other training runs with different seeds and the team is evaluated using the same metrics as before. We observe that ELIGN strategies enable better performance than SPARSE on average, and one of $\mathrm{ELIGN}_{\mathrm{self,team,adv}}$ performs the best in Heterogenous navigation, Physical deception and Keep away. (Figure 7). These results suggest that ELIGN results in better zero-shot coordination with new partners sampled from separate training runs.
+
+Accuracy of the dynamics model affects ELIGN. We investigate the accuracy of the dynamics model in calculating useful intrinsic rewards. Since ELIGN uses a dynamics model to calculate
+
+
+Figure 7: We plot the test occupancy/collision count per step of decentralized algorithms in zero-shot evaluation with new partners. We find that one of $\mathrm{ELIGN}_{\mathrm{self,team,adv}}$ achieves the best performance in Heterogenous navigation, Physical deception and Keep away.
+
+rewards, we test whether an inaccurate model misleads agents towards unaligned behaviors. We train agents on noisy dynamics models by adding Gaussian noise $\epsilon \sim \mathcal{N}(0,\sigma)$ to the predictions made by the dynamics model. We run experiments with multiple $\sigma$ values to study how performance changes as the dynamics model becomes more noisy: $\sigma \in [0.5,1.0,2.0]$ . Our experiments cover one cooperative and one competitive task. Figure 6 plots the final dynamics loss against the reward change from the noiseless run. As the dynamics model degrades, we observe that the task performance also drops. This study identifies the importance of an accurate dynamics model, suggesting that expectation alignment should be used in environments where an accurate dynamics model can be learned.
+
+# 6 Discussion
+
+Limitations and future work. While curiosity has proven useful for exploration in single-agent tasks, we find that expectation alignment—which mathematically encourages agents to be more predictable instead of finding novelty—outperforms curiosity in numerous multi-agent tasks. We hypothesize that our results arise because today's multi-agent task state space requires significantly less exploration than those used for single-agent (e.g. Atari games). Our findings are limited to the multi-agent particle and Google Research football environments, which have a smaller action space than most ecologically valid scenarios.
+
+Language, motion, and human gesture are all combinatorially vast; in such action spaces, expectation alignment might develop social dynamics that hinder non-optimal multi-agent behaviors. Similarly, photorealistic environments have a larger state space, where teams perform common household activities (e.g., cooking, cleaning, etc.) or drive together in crowded cities (Srivastava et al., 2021). Future work should develop new multi-agent environments that demand exploration complexity and where both curiosity and expectation alignment would be necessary for collaboration. For example, in a search and rescue task where a single agent is unable to carry the injured, curiosity would encourage "search" while ELIGN would speed up "rescue". In the end, we envision that both these forms of rewards would be necessary for successful collaboration. However, choosing when to encourage curiosity versus expectation alignment is an open research problem.
+
+Additionally, enabling stable multi-agent training without centralized training could open up future opportunities for legible (Dragan et al., 2013) agents in human environments. Agents with interpretable actions can induce more faithful human mental models, improving human-AI interaction; however, predictability does not imply legibility. Future work could explore the role of legibility in designing intrinsic rewards.
+
+Future work should also explore the use of expectation alignment in massive collaboration settings with hundreds of agents. Drawing on Zoology research Couzin (2007) expectation alignment should scale in such settings if agents align their behaviors only to their nearest neighbors and not to the entire cohort.
+
+Conclusion. Inspired by the self-organizing principle in Zoology, we introduce ELIGN, i.e., expectation alignment, a simple, task-agnostic, and self-supervised intrinsic reward for multi-agent systems. ELIGN rewards agents when they act predictably to their teammates and unpredictably to their adversaries. ELIGN improves multi-agent performance across six cooperative and competitive tasks in the multi-agent particle and Google Research football environments, especially for decentralized training under partial observability. It also scales well, helps agents break symmetries, and generalize to new partners.
+
+# References
+
+Achiam, J. and Sastry, S. Surprise-based intrinsic motivation for deep reinforcement learning. arXiv preprint arXiv:1703.01732, 2017.
+Ben-Jacob, E., Schochet, O., Tenenbaum, A., Cohen, I., Czirok, A., and Vicsek, T. Generic modelling of cooperative growth patterns in bacterial colonies. Nature, 368(6466):46-49, 1994.
+Berner, C., Brockman, G., Chan, B., Cheung, V., Debiak, P., Dennison, C., Farhi, D., Fischer, Q., Hashme, S., Hesse, C., et al. Dota 2 with large scale deep reinforcement learning. arXiv preprint arXiv:1912.06680, 2019.
+Bohmer, W., Rashid, T., and Whiteson, S. Exploration with unreliable intrinsic reward in multi-agent reinforcement learning. arXiv preprint arXiv:1906.02138, 2019.
+Buhl, J., Sumpter, D. J., Couzin, I. D., Hale, J. J., Despland, E., Miller, E. R., and Simpson, S. J. From disorder to order in marching locusts. Science, 312(5778):1402-1406, 2006.
+Burda, Y., Edwards, H., Pathak, D., Storkey, A., Darrell, T., and Efros, A. A. Large-scale study of curiosity-driven learning. arXiv preprint arXiv:1808.04355, 2018a.
+Burda, Y., Edwards, H., Storkey, A., and Klimov, O. Exploration by random network distillation. arXiv preprint arXiv:1810.12894, 2018b.
+Camazine, S., Deneubourg, J.-L., Franks, N. R., Sneyd, J., Theraula, G., and Bonabeau, E. Self-organization in biological systems. Princeton university press, 2020.
+Cao, Y., Yu, W., Ren, W., and Chen, G. An overview of recent progress in the study of distributed multi-agent coordination. IEEE Transactions on Industrial informatics, 9(1):427-438, 2012.
+Chitnis, R., Tulsiani, S., Gupta, S., and Gupta, A. Intrinsic motivation for encouraging synergistic behavior. arXiv preprint arXiv:2002.05189, 2020.
+Collett, M., Despland, E., Simpson, S. J., and Krakauer, D. C. Spatial scales of desert locust gregarization. Proceedings of the National Academy of Sciences, 95(22):13052-13055, 1998.
+Corder, K., Vindiola, M. M., and Decker, K. Decentralized multi-agent actor-critic with generative inference. arXiv preprint arXiv:1910.03058, 2019.
+Couzin, I. Collective minds. Nature, 445(7129):715-715, 2007.
+Dragan, A. D., Lee, K. C., and Srinivasa, S. S. Legibility and predictability of robot motion. In 2013 8th ACM/IEEE International Conference on Human-Robot Interaction (HRI), pp. 301-308. IEEE, 2013.
+Du, Y., Han, L., Fang, M., Dai, T., Liu, J., and Tao, D. Liir: learning individual intrinsic reward in multi-agent reinforcement learning. In Proceedings of the 33rd International Conference on Neural Information Processing Systems, pp. 4403-4414, 2019.
+Foerster, J., Farquhar, G., Afouras, T., Nardelli, N., and Whiteson, S. Counterfactual multi-agent policy gradients. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 32, 2018.
+Foerster, J. N., Chen, R. Y., Al-Shedivat, M., Whiteson, S., Abbeel, P., and Mordatch, I. Learning with opponent-learning awareness. arXiv preprint arXiv:1709.04326, 2017.
+Haarnoja, T., Zhou, A., Abbeel, P., and Levine, S. Soft actor-critic: Off-policy maximum entropy deep reinforcement learning with a stochastic actor. In ICML, 2018.
+Hernandez-Leal, P., Kartal, B., and Taylor, M. E. Agent modeling as auxiliary task for deep reinforcement learning. In Proceedings of the AAAI Conference on Artificial Intelligence and Interactive Digital Entertainment, volume 15, pp. 31-37, 2019.
+Hu, H., Lerer, A., Peysakhovich, A., and Foerster, J. "other-play" for zero-shot coordination. In International Conference on Machine Learning, pp. 4399-4410. PMLR, 2020.
+
+Huang, C.-M., Cakmak, M., and Mutlu, B. Adaptive coordination strategies for human-robot handovers. In Robotics: science and systems, volume 11. Rome, Italy, 2015.
+Iqbal, S. and Sha, F. Actor-attention-critic for multi-agent reinforcement learning. In International Conference on Machine Learning, pp. 2961–2970. PMLR, 2019.
+Iqbal, S. and Sha, F. Coordinated exploration via intrinsic rewards for multi-agent reinforcement learning, 2020. URL https://openreview.net/forum?id=rklteOVKwH.
+Jaderberg, M., Mnih, V., Czarnecki, W. M., Schaul, T., Leibo, J. Z., Silver, D., and Kavukcuoglu, K. Reinforcement learning with unsupervised auxiliary tasks. arXiv preprint arXiv:1611.05397, 2016.
+Jain, U., Weihs, L., Kolve, E., Farhadi, A., Lazebnik, S., Kembhavi, A., and Schwing, A. A cordial sync: Going beyond marginal policies for multi-agent embodied tasks. In European Conference on Computer Vision, pp. 471-490. Springer, 2020.
+Jaques, N., Lazaridou, A., Hughes, E., Gulcehre, C., Ortega, P., Strouse, D., Leibo, J. Z., and De Freitas, N. Social influence as intrinsic motivation for multi-agent deep reinforcement learning. In International Conference on Machine Learning, pp. 3040-3049. PMLR, 2019.
+Kidambi, R., Rajeswaran, A., Netrapalli, P., and Joachims, T. Morel: Model-based offline reinforcement learning. arXiv preprint arXiv:2005.05951, 2020.
+Kim, K., Sano, M., De Freitas, J., Haber, N., and Yamins, D. Active world model learning with progress curiosity. In International conference on machine learning, pp. 5306-5315. PMLR, 2020.
+Krause, J., Ruxton, G. D., Ruxton, G., Ruxton, I. G., et al. Living in groups. Oxford University Press, 2002.
+Kurach, K., Raichuk, A., Stanczyk, P., Zajac, M., Bachem, O., Espeholt, L., Riquelme, C., Vincent, D., Michalski, M., Bousquet, O., and Gelly, S. Google research football: A novel reinforcement learning environment. CoRR, abs/1907.11180, 2019. URL http://arxiv.org/abs/1907.11180.
+Littman, M. L. Markov games as a framework for multi-agent reinforcement learning. In Machine learning proceedings 1994, pp. 157-163. Elsevier, 1994.
+Liu, I.-J., Yeh, R. A., and Schwing, A. G. Pic: permutation invariant critic for multi-agent deep reinforcement learning. In Conference on Robot Learning, pp. 590-602. PMLR, 2020.
+Lowe, R., Wu, Y., Tamar, A., Harb, J., Abbeel, P., and Mordatch, I. Multi-agent actor-critic for mixed cooperative-competitive environments. Advances in Neural Information Processing Systems, 2017.
+Mordatch, I. and Abbeel, P. Emergence of grounded compositional language in multi-agent populations. arXiv preprint arXiv:1703.04908, 2017.
+Morin, A. Levels of consciousness and self-awareness: A comparison and integration of various neurocognitive views. Consciousness and cognition, 15(2):358-371, 2006.
+Ndousse, K., Eck, D., Levine, S., and Jaques, N. Emergent social learning via multi-agent reinforcement learning, 2021.
+Pathak, D., Agrawal, P., Efros, A. A., and Darrell, T. Curiosity-driven exploration by self-supervised prediction. In International conference on machine learning, pp. 2778-2787. PMLR, 2017.
+Rashid, T., Samvelyan, M., de Witt, C. S., Farquhar, G., Foerster, J., and Whiteson, S. Qmix: Monotonic value function factorisation for deep multi-agent reinforcement learning, 2018.
+Roy, J., Barde, P., Harvey, F., Nowrouzezahrai, D., and Pal, C. Promoting coordination through policy regularization in multi-agent deep reinforcement learning. Advances in Neural Information Processing Systems, 33:15774-15785, 2020.
+Schafer, L. Curiosity in multi-agent reinforcement learning. PhD thesis, Master's thesis, The University of Edinburgh, 2019.
+
+Schmidhuber, J. A possibility for implementing curiosity and boredom in model-building neural controllers. In Proc. of the international conference on simulation of adaptive behavior: From animals to animals, pp. 222-227, 1991.
+Sekar, R., Rybkin, O., Daniilidis, K., Abbeel, P., Hafner, D., and Pathak, D. Planning to explore via self-supervised world models. In International Conference on Machine Learning, pp. 8583-8592. PMLR, 2020.
+Srivastava, S., Li, C., Lingelbach, M., Martin-Martin, R., Xia, F., Vainio, K., Lian, Z., Gokmen, C., Buch, S., Liu, C. K., et al. Behavior: Benchmark for everyday household activities in virtual, interactive, and ecological environments. arXiv preprint arXiv:2108.03332, 2021.
+Stadie, B. C., Levine, S., and Abbeel, P. Incentivizing exploration in reinforcement learning with deep predictive models. arXiv preprint arXiv:1507.00814, 2015.
+Strouse, D., Kleiman-Weiner, M., Tenenbaum, J., Botvinick, M., and Schwab, D. J. Learning to share and hide intentions using information regularization. Advances in Neural Information Processing Systems, 31:10249-10259, 2018.
+Sunehag, P., Lever, G., Gruslys, A., Czarnecki, W. M., Zambaldi, V., Jaderberg, M., Lanctot, M., Sonnerat, N., Leibo, J. Z., Tuyls, K., et al. Value-decomposition networks for cooperative multi-agent learning. arXiv preprint arXiv:1706.05296, 2017.
+Swamy, G., Reddy, S., Levine, S., and Dragan, A. D. Scaled autonomy: Enabling human operators to control robot fleets. In 2020 IEEE International Conference on Robotics and Automation (ICRA), pp. 5942-5948. IEEE, 2020.
+Theraulaz, G. and Bonabeau, E. Coordination in distributed building. Science, 269(5224):686-688, 1995.
+Tomasello, M., Carpenter, M., Call, J., Behne, T., and Moll, H. Understanding and sharing intentions: The origins of cultural cognition. Behavioral and brain sciences, 28(5):675-691, 2005.
+Wang, R. E., Kew, J. C., Lee, D., Lee, T.-W. E., Zhang, T., Ichter, B., Tan, J., and Faust, A. Model-based reinforcement learning for decentralized multiagent rendezvous, 2020a.
+Wang, R. E., Wu, S. A., Evans, J. A., Tenenbaum, J. B., Parkes, D. C., and Kleiman-Weiner, M. Too many cooks: Bayesian inference for coordinating multi-agent collaboration, 2020b.
+Wang, T., Wang, J., Wu, Y., and Zhang, C. Influence-based multi-agent exploration. arXiv preprint arXiv:1910.05512, 2019.
+Wang, X., Xiong, W., Wang, H., and Wang, W. Y. Look before you leap: Bridging model-free and model-based reinforcement learning for planned-ahead vision-and-language navigation. In Proceedings of the European Conference on Computer Vision (ECCV), pp. 37-53, 2018.
+Ying, W. and Dayong, S. Multi-agent framework for third party logistics in e-commerce. Expert Systems with Applications, 29(2):431-436, 2005.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes] See Section 5 for the results mentioned in the abstract.
+(b) Did you describe the limitations of your work? [Yes] See Section 6 for a discussion on the limitations.
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] See the Appendix
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes] We have read the ethics review guidelines.
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] See the Appendix
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See the Experiments 5 and Appendix sections.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] See the Experiments 5 section.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See the Experiments 5 and Appendix sections.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] See the Alignment 4 and Experiments 5 sections.
+(b) Did you mention the license of the assets? [Yes] See the Appendix
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] See the Appendix
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A] We did not collect any data.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A] We did not collect any data.
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A] We did not crowdsourced any data.
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A] There were no human subjects experiments in our work.
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A] No human subjects were hired.
\ No newline at end of file
diff --git a/elignexpectationalignmentasamultiagentintrinsicreward/images.zip b/elignexpectationalignmentasamultiagentintrinsicreward/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..bdc94e3b489f5e80788bca7c272cdaa9fbaf02ba
--- /dev/null
+++ b/elignexpectationalignmentasamultiagentintrinsicreward/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:cfceed71c7c24bd8ae8807deceb2794e6f36d7f7daca81fdbdfaa969642b3e05
+size 295682
diff --git a/elignexpectationalignmentasamultiagentintrinsicreward/layout.json b/elignexpectationalignmentasamultiagentintrinsicreward/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..9964d3d49013050d3db446ec25af3da7610e0cd9
--- /dev/null
+++ b/elignexpectationalignmentasamultiagentintrinsicreward/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d9e575ec657394e48e98747e5e6108f96177213b828c43eda758b0679ff5817c
+size 524070
diff --git a/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/49651e5b-5f76-4cd5-8023-e40a23f0c67d_content_list.json b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/49651e5b-5f76-4cd5-8023-e40a23f0c67d_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..5a3b0670ac651f70461d5c6a9ea68c18a80d91c7
--- /dev/null
+++ b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/49651e5b-5f76-4cd5-8023-e40a23f0c67d_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3418723e9ff56591c30b3e508da5e74099bd7c8775e831765048d80420d4ad69
+size 80820
diff --git a/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/49651e5b-5f76-4cd5-8023-e40a23f0c67d_model.json b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/49651e5b-5f76-4cd5-8023-e40a23f0c67d_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..853891f4e462230f7d6235297191cb9b395f0b31
--- /dev/null
+++ b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/49651e5b-5f76-4cd5-8023-e40a23f0c67d_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ed087b7559c46874d882880efaad0be080e44899e6332a42d689eb388d36e36e
+size 105438
diff --git a/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/49651e5b-5f76-4cd5-8023-e40a23f0c67d_origin.pdf b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/49651e5b-5f76-4cd5-8023-e40a23f0c67d_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..60e518317a1215534aec26a9d924e3db8c049aeb
--- /dev/null
+++ b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/49651e5b-5f76-4cd5-8023-e40a23f0c67d_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7237589c7a20bc7823c51a732466c5c08136ed47f94d53b4c629dbac46a64224
+size 2442201
diff --git a/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/full.md b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..c6e73dc4f294112eeff19a1785e12d7708e12480
--- /dev/null
+++ b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/full.md
@@ -0,0 +1,325 @@
+# E-MAPP: Efficient Multi-Agent Reinforcement Learning with Parallel Program Guidance
+
+Can Chang $^{1,2*}$ , Ni Mu $^{3}$ , Jiajun Wu $^{4}$ , Ling Pan $^{5}$ , Huazhe Xu $^{1,2}$ $^{1}$ IIIS, Tsinghua University $^{2}$ Shanghai Qi Zhi Institute $^{3}$ Southeast University $^{4}$ Stanford University $^{5}$ Mila, Université de Montréal cc22@mails.tsinghua.edu.cn, xuhuazhe12@gmail.com
+
+# Abstract
+
+A critical challenge in multi-agent reinforcement learning (MARL) is for multiple agents to efficiently accomplish complex, long-horizon tasks. The agents often have difficulties in cooperating on common goals, dividing complex tasks, and planning through several stages to make progress. We propose to address these challenges by guiding agents with programs designed for parallelization, since programs as a representation contain rich structural and semantic information, and are widely used as abstractions for long-horizon tasks. Specifically, we introduce Efficient Multi-Agent Reinforcement Learning with Parallel Program Guidance (E-MAPP), a novel framework that leverages parallel programs to guide multiple agents to efficiently accomplish goals that require planning over $10+$ stages. E-MAPP integrates the structural information from a parallel program, promotes the cooperative behaviors grounded in program semantics, and improves the time efficiency via a task accelerator. We conduct extensive experiments on a series of challenging, long-horizon cooperative tasks in the Overcooked environment. Results show that E-MAPP outperforms strong baselines in terms of the completion rate, time efficiency, and zero-shot generalization ability by a large margin.
+
+# 1 Introduction
+
+Multi-agent reinforcement learning (MARL) has achieved significant progress by advancing the cooperation of multiple agents to accomplish complex tasks, e.g., multi-robot control [20], autonomous driving [48, 54], and video games [50, 4]. Most recent advances in MARL focus on tasks that feature behavior coordination [39] or joint motion planning [41]. However, for long-horizon tasks such as preparing a dish, existing methods often suffer from the inability to understand the task compositionality and subtasks' dependencies, resulting in inefficient cooperation and frequent conflicts. Therefore, a natural question to ask here is how we can solve long-horizon tasks in MARL, in the face of large state/action spaces and sparse feedback.
+
+Long-horizon tasks are usually blessed with rich structure, and thus can be divided into a sequence of subtasks that can be resolved separately. Previous work [45, 52] has introduced programs as instructions to help a single agent understand the task hierarchy and accomplish the task. Inspired by them, we develop a general multi-agent framework, where agents can leverage programs for accomplishing long-horizon tasks together. This is a challenging problem, and three substantial issues will emerge if multiple agents are naively enforced to follow sequential programs: first, sequential programs do not explicitly express the dependencies among subtasks, thus hindering the division
+
+of jobs among agents; second, different agents might have different abilities to accomplish certain subtasks or lines of programs; third, when assigned to a subtask together, multiple agents might need to collaborate without blocking resources with each other.
+
+As modern CPUs dispatch instructions to parallel processors, we propose a new multi-agent framework, Efficient Multi-Agent Reinforcement Learning with Parallel Program Guidance (E-MAPP), guiding cooperation and execution by automatically inferring the structure of parallelism from programs. Specifically, we first design a domain-specific language (DSL) for multi-agent cooperation, and use multi-stage learning to ground subroutines of a given program into the agents' policy. Then, we learn feasibility functions, which entail the ability of agents to complete specific subroutines in the program in the status quo. Finally, we leverage the learned task structure to automatically enforce cooperation and division of labor among agents.
+
+We conduct experiments on gradually more difficult challenges in the Overcooked [50] environment. The Overcooked environment requires the agents to cooperate on very long-horizon tasks, such as preparing dishes, while avoiding conflicting behaviors. Our method significantly outperforms other strong baselines in completion rates and efficiency. The program structure also enables E-MAPP to deliver superior compositional generalization to novel scenes.
+
+Our main contributions can be summarized as follows:
+
+- We formulate a novel task of learning multi-agent cooperation via the guidance of parallel programs.
+- We present a novel framework for program grounding and long-horizon planning and instantiate the framework into practical multi-agent reinforcement learning algorithms.
+- We demonstrate the effectiveness of E-MAPP in completion rates and generalization ability over existing strong baselines and provide empirical analysis in long-horizon tasks.
+
+# 2 Related Work
+
+Cooperative Multi-Agent Reinforcement Learning. In a multi-agent cooperative game, agents collaborate with each other on a common goal [33]. Researchers have investigated many ways to facilitate agent coordination [21, 12, 53, 34, 19]. Value-based MARL algorithms engage in discovering the relationship between global value function and local value functions [46, 38], while policy-based MARL algorithms use a centralized critic [51, 26] to coordinate agent behaviors. More specifically, MAPPO [51] and MADDPG [26] leverage a fully-observable central critic to solve the issue of non-stationarity [33]. Value factorization approaches [38, 46, 37] decompose the global value function into a combination of local agent-wise utilities to cope with scalability, while policy factorization approaches [18] factorize the joint action space to coordinate marginal policies.
+
+Reinforcement Learning for Long-horizon Tasks. Reinforcement learning agents usually lack the ability to plan and reason over a long time horizon due to sparse rewards [49, 14, 40, 15, 16, 30]. Goal-conditioned reinforcement learning [36] is one of the popular paradigms to address the sparse supervision problem. Imitation learning [17, 16] is another approach to solving the sparse reward problem. Another line of work has presented automatic goal generation and selection algorithms [3, 35, 24, 9]; however, this introduces new challenges to design a suitable goal space that enjoys rich semantic meanings [13]. By contrast, our work uses the subtasks corresponding to possible subroutines in a program as goals, which are associated with domain knowledge. Hierarchical reinforcement learning [HRL; 47, 42, 28, 43, 29] is another path to solve long-horizon tasks, using a high-level policy for long-term planning and low-level policies for motion planning or specific behaviors. While our work is related to multi-agent hierarchical reinforcement learning [27], which explicitly provides the directed acyclic task graph and the necessity of cooperation of each subtask, we focus on learning task structure such as subtask dependencies, loops, and branchings from the program and judging the necessity of cooperation without additional information.
+
+Instruction-Guided Agents. Many recent advances have testified the advantages of leveraging structured prior knowledge such as task graphs [1, 22], natural languages [2, 6, 23] and programs [45, 52] to promote efficient policy learning. In contrast to other structured priors, programs stand out because of their strictly formatted and composable subroutines [5, 7]. Previous works leverage programs to enable a single agent to learn complex tasks by following programs [45, 52]. However, a plethora of new challenges have been introduced, including task dependencies, collaboration schemes,
+
+
+Figure 1: The overall framework of E-MAPP. E-MAPP includes four components: 1) A perception module that maps a query $q$ and the current state $s$ to boolean responses. 2) A program executor that maintains a pool of possible subtasks and updates them according to the perceptive results. 3) A task allocator that chooses proper subtasks from the subtask pool and assigns those to agents. 4) A policy module that instructs agents in taking actions to accomplish specific subtasks.
+
+and others; hence, it is difficult to trivially extend the existing works in the MARL settings. To enable multi-thread orderless policy execution, we leverage "plug-and-play" auxiliary functions to infer the relationships among subtasks.
+
+# 3 Problem Statement
+
+# 3.1 Program Guided Cooperative Markov Game
+
+An infinite-horizon Markov Game is defined by a tuple $(\mathcal{N},\mathcal{S},\mathcal{A},\mathcal{T},\mathcal{R},\gamma)$ , where $\mathcal{N} = \{1,\dots ,N\}$ denotes the set of $N$ engaging agents, $\mathcal{S}$ denotes the state space, $\mathcal{A} = \mathcal{A}^1\times \dots \times \mathcal{A}^N$ denotes the Cartesian product of all the $N$ agents' action space, $\mathcal{T}\colon S\times \mathcal{A}\to \mathcal{S}$ denotes the state transition function from current state $s$ to the next state $s^\prime$ for the joint action $a = (a^{1},\ldots ,a^{N})$ , $\mathcal{R} = \mathcal{R}^1\times \dots \times \mathcal{R}^N$ denotes the Cartesian product of all the $N$ agents' reward functions, where each $\mathcal{R}^i$ determines the immediate reward for the $i$ -th agent from the current state $s$ and joint action $a$ , and $\gamma$ is the discount factor.
+
+At each time $t$ , each agent $i$ observes the current state $s_t$ , makes the decision $a_t^i$ , and receives the reward $r_t^i$ . In a cooperative game, the collective goal is to optimize the joint policy $\pi : S \to A$ to maximize the sum of each agent's expected cumulative discounted rewards $\mathbb{E}_{\mathbf{a}_t^i} \sim \pi^i(\cdot|\mathbf{s}_t), \mathbf{s}_t \sim \mathcal{P}\left[\sum_{t=1}^{\infty} \sum_{i=1}^{N} \gamma^t r_t^i(\mathbf{s}_t, \mathbf{a}_t^i)\right]$ .
+
+A program-guided Markov game is a Markov game with a factorized state space. Specifically, state $S = S_{e} \times S_{p}$ , where $S_{e}$ is the common state space of the environment and $S_{p}$ is the multi-pointer program space (see Section 3.2). Accordingly, the state transition function takes as input the current compounded states $(s_{e}, s_{p})$ and joint actions $a$ and then returns the next joint state $(s_{e}', s_{p}')$ . In this study, the transition function of the program space is based on predefined rules.
+
+# 3.2 Parallel Programs
+
+The program space consists of three components: a domain-specific language (DSL) that contains all the possible subroutines, a set of pointers that point to relevant subroutines, and a control flow that manages the pointers. A complete specification of the DSL used by our framework is in the Appendix A.1. Inside this DSL, a subroutine is a minimal executable unit in the program that corresponds to a subtask in the domain (e.g., Chop(Tomato)). As in previous works [45, 52], we consider two types of subroutines: perception primitives (e.g., IsOnFire)), which query about the status of the environment; and behavior primitives (e.g., Chop(Tomato), which issue an instruction. Control flow involves branching statements (if/else), loops (for/while), and parallelism indicators (repeat/parallel). The parallelism indicators are designed for multi-thread execution. The subroutines in a parallel block are possible but not guaranteed to run concurrently, i.e., the agents should reason about what subroutines in a parallel block can be executed concurrently. The
+
+
+Figure 2: The perception module. The perception module encodes the perception primitive into modulation parameters, which operate on the state embeddings to get the goal-conditioned embeddings. These embeddings are then fed into another encoder, followed by a sigmoid function. The output is a real number in $[0,1]$ , and will be binarized for branching selection by the program executor.
+
+subroutine in a repeat block can be executed many times simultaneously. We summarize all the current subroutines that are possible and executable as the Possible Subroutine Set. The set of pointers points to all the subroutines in this set.
+
+# 3.3 Multi-Agent RL with Parallel Programs
+
+In our study, we aim to develop a framework for optimizing the joint policy in a parallel program-guided cooperative Markov game. To this end, the agents must keep track of the pointers in the program, learn to reason the primitives to choose the right branches, and perform the action either collaboratively or individually to pursue high efficiency.
+
+# 4 Method
+
+Our goal is to enable multiple agents to cooperate to solve long-horizon tasks guided by parallel programs. There are three important factors we should consider: first, the agents should learn subtask-conditioned policies that can be composed together to accomplish long-horizon tasks and further generalize compositionally to unseen tasks; second, the agents should reason about task dependencies so that they can automatically parallelize tasks among them; and third, the agents should distinguish between cooperative tasks and non-cooperative tasks that can be achieved by a single agent to avoid competition for common resources.
+
+We propose Efficient Multi-Agent Reinforcement Learning with Parallel Programs (E-MAPP), a multi-agent reinforcement learning framework where agents can cooperate to solve long-horizon tasks by following program guidance. As shown in Figure 1, E-MAPP includes four components: a perception module that is able to judge whether the queried status exists in the state; a parallel program executor that keeps track of subroutines and updates them based on the perception module output; a task allocator, which extracts queries of interest and obtains the corresponding set of possible subtasks from the program executor, and assigns tasks to agents; and a multi-agent policy module, which agents use to make their decisions based on the input subtask. The following of this section will introduce these four key components of E-MAPP. The complete algorithm is shown in Appendix A.3.
+
+# 4.1 Parallel Program Executor
+
+The program executor keeps a set of pointers pointing to possible subroutines in a domain-specific Possible Subroutine Set. There are four types of control flows: if-routine, while-routine, parallel-routine, and repeat-routine. Meanwhile, there are two types of subroutines in our program: behavior primitives and perception primitives.
+
+Control flows. An if-routine contains a condition statement (usually a perception primitive) and subroutines in the corresponding blocks. A while-routine contains a condition statement and a looping
+
+
+Figure 3: The policy module. We adopt a goal-conditioned reinforcement learning framework to determine the policy. We encode goals with a goal encoder and fuse them into the state features. If an agent is assistive, the goal is encoded with an altruistic goal encoder instead. The network has three outputs, including the value function, the action distribution, and the auxiliary functions.
+
+block of subroutines. A parallel-routine contains parallel blocks of subroutines that are possible to be executed simultaneously. A repeat-routine contains an unconditioned block of subroutines that can be executed multiple times by different agents.
+
+Subroutines. A behavior primitive (e.g., Chop(Tomato)) corresponds to a subtask that must be completed by the agents. As for a perception primitive (e.g., IsOnFire(), it is a query that requires a boolean response.
+
+After an action is performed or a response to a perceptive query is received, the program executor updates its pointers and the Possible Subroutine Set. Detailed updating rules are shown in Appendix A.2. We note that if an achieved subtask does not correspond to any subroutine in the Possible Subroutine Set, the program executor will terminate the program immediately. This guarantees that no exceptions will occur due to violating the instructed order of subtasks.
+
+# 4.2 Perception Module
+
+The perception module learns to map a query $q$ and the current state $s_t$ to a boolean answer $h = \phi(q, s_t)$ . For example, when a perception primitive IsOnFire() is passed to the perception module, it learns to check the existence of fire in the environment and returns true/false. The architecture is shown in Figure 2. Specifically, we randomly sample states, queries, and the ground-truth perception $h_{gt}$ as the training dataset and train the network $\phi$ in a supervised manner. We use binary cross entropy (BCE) loss $\mathcal{L}_{\text{perception}} = BCELoss(h_{\text{pred}}, h_{\text{gt}})$ as the objective, where $h_{\text{pred}}$ denotes the perception output. In terms of architecture, we encode the perception primitive $s_p$ and the common state $s_e$ with a neural encoder. The encoded primitives are represented as $\gamma$ and $\beta$ to modulate the encoded common state. At the last layer, we use a sigmoid function to obtain the binary output. Training details and detailed architecture descriptions can be found in Appendix A.5. In this way, this module can determine whether the queried primitive exists in the state to aid the agents' decision-making.
+
+# 4.3 Policy Module
+
+The policy module grounds agents' actions with the programs and encourages cooperation in completing the tasks. The overall policy learning procedure advocates a subtask-conditioned reinforcement learning framework as shown in Figure 3. Our algorithm backbone is MAPPO [51] and consists of two stages. More concretely, we first learn a policy for each agent where other agents' policies are fixed. The input is the state and the encoded subtask. The reward signal is based on whether a subroutine is executed correctly. Then we enable multiple agents to coordinate by learning a joint policy for accomplishing collective goals cooperatively and efficiently, with the help of auxiliary functions and a task allocator. We use the same architecture to fuse state and goal features as that in the perception module in Figure 2. We also leverage self-imitation learning to tackle the challenge of sparse rewards, which is shown in Appendix A.4
+
+
+(a) reachability
+
+
+(b) feasibility
+
+
+(c) cost-to-go
+Figure 4: The auxiliary functions. Figure 4a shows the reachability that indicates if an agent can reach an object. Figure 4b shows the feasibility that indicates whether a subtask can be achieved by the agents collectively. Figure 4c shows the cost-to-go function that indicates time consumption.
+
+Learning to cooperate on a subtask. After obtaining single-agent policies, we then encourage agents to accomplish harder tasks that require cooperation. When assigned a cooperative subtask, one of the agents is in charge of finalizing the task. The rest of the agents are assistive. For example, the assistive agents might pass an onion to the leading agents to chop. In practice, we randomly appoint one agent as the leading agent and the others as the assistive agents. The leading agent is rewarded if this subtask is completed. The reward function for the assistive agents is calculated based on the reachability improvement of the leading agent. We defer the formal definition of this reward function to Section 4.4. Such reward function encourages the assistive agents to help the leading agents to obtain rewards. Then, we use a MAPPO-style algorithm to obtain a cooperation policy. We also encode the leading agent's goal into the observation space of the assistive agents to enhance information sharing.
+
+# 4.4 Task Allocator
+
+The task allocator assigns subtasks to each agent to accomplish a long-horizon task together. Specifically, we design the task allocator for efficient coordination based on the following principles: 1) It only assigns subtasks that are feasible for the agent(s) without additional prerequisite subtasks. 2) If a subtask is cooperative, the task allocator would assign the subtask to a number of agents. 3) It assigns a subtask to the agent that has the lowest cost in terms of execution time.
+
+To facilitate the task allocation, we propose to learn three auxiliary functions: a reachability function, a feasibility function, and a cost-to-go function as illustrated in Figure 4. Training details of the auxiliary functions are in Appendix A.6
+
+Reachability. The reachability function $f_{reach} = f_{reach}(s_t, i, \tau)$ is defined as a boolean value to indicate if agent $i$ can complete task $\tau$ alone at the state $s_t$ . For a cooperative subtask $\tau$ and a selected leading agent $i$ , an extrinsic reward $f_{reach}(s_t', i, \tau) - f_{reach}(s_t, i, \tau)$ is provided to the assistive agents for learning altruistic behaviors. To train this reachability function, we randomly sample triplets $(s_t, i, \tau)$ and obtain the ground-truth value $f_{reach}^{gt}$ through running the pre-trained non-cooperative policy. Then we optimize the network by minimizing the binary cross entropy $BCE(f_{reach}^{pred}, f_{reach}^{gt})$ .
+
+Feasibility. The feasibility function $f_{feas} = f_{feas}(s_t, i, \tau)$ is defined as a boolean variable indicating if an agent $i$ can complete a subtask $\tau$ with others' assistance at the state $s_t$ . The training procedure of the feasibility function is similar to that of the reachability function, except that we leverage the cooperative policy instead of the single agent policy to collect training data.
+
+Cost-to-go. The cost-to-go function $f_{cost} = f_{cost-to-go}(s_t, i, \tau)$ denotes the remaining timesteps for agent $i$ to accomplish the subtask from the state $s_t$ . We leverage trajectories generated by a pre-trained intermediate cooperative policy from E-MAPP to train this cost function. Specifically, we randomly sample triplets $(s_t, i, \tau)$ and execute the pre-trained cooperative policy in Section 4.3.
+
+to obtain the ground-truth timesteps $f_{cost-to-go}^{gt}$ to complete the subtask $\tau$ . Then we optimize the network by reducing the Mean Squared Error (MSE) $\mathcal{L}_{cost-to-go} = \mathrm{MSE}(f_{cost-to-go}^{pred}, f_{cost-to-go}^{gt})$ .
+
+Criteria for subtask allocation. For a specific Possible Subroutine Set $\{\tau_1,\dots ,\tau_m\}$ , we denote a legal subtask allocation as $\{T_{1},T_{2},\ldots ,T_{m}\}$ such that
+
+- $T_{i}$ is a list of $n_i$ agents where $n_i = |T_i|$ . The agents are those in the agent set $\{1, \dots, N\}$ who aim at completing the subtask $\tau_i$ .
+- For all $i \in \{1, \dots, m\}$ , if $n_i$ is larger than one, then the agent $T_i^1$ is selected as the leading agent and the agent(s) $T_i^2, \dots, T_i^{n_i}$ are selected as the assistive agent(s).
+- For $1 \leq i < j \leq m$ , we have that $T_{i} \cap T_{j} = \emptyset$ , which means no agent is assigned two subtasks simultaneously.
+
+We compute the cost of each possible subtask allocation $\{T_1, T_2, \ldots, T_m\}$ as the sum of three terms
+
+$$
+c _ {\text {t o t a l}} = c _ {\text {f e a s}} + c _ {\text {c o s t - t o - g o}} + c _ {\text {r e a c h}} \tag {1}
+$$
+
+,where
+
+$$
+c _ {\text {f e a s}} = \sum_ {i = 1} ^ {m} - n _ {i} w _ {\text {f e a s}} \log f _ {\text {f e a s}} \left(s, T _ {i} [ 1 ], \tau_ {i}\right) \tag {2}
+$$
+
+$$
+c _ {\text {c o s t - t o - g o}} ^ {i = 1} = \sum_ {i = 1} - n _ {i} w _ {\text {c o s t}} f _ {\text {c o s t}} (s, T _ {i} [ 1 ], \tau_ {i}) \tag {3}
+$$
+
+$$
+c _ {\text {r e a c h}} = \sum_ {i = 1} ^ {m} \mathbb {I} [ n _ {i} = 1 ] w _ {\text {r e a c h}} \log f _ {\text {r e a c h}} (s, T _ {i} [ 1 ], \tau_ {i}) \tag {4}
+$$
+
+$w_{\text{feas}}, w_{\text{reach}}$ , and $w_{\text{cost}}$ are tunable hyperparameters and $\mathbb{I}[\cdot]$ is the indicator function. The feasibility term encourages the agents to choose the feasible subtasks, the cost-to-go term encourages the agents to choose the less costly subtasks, and the reachability term guarantees that the subtask assigned to only one agent is non-cooperative. The log operator operating on a value approximating 1 will induce a huge cost, thus preventing the allocation of an infeasible or unreachable subtask to an agent. We search from the possible allocations $\{T_1, T_2, \ldots, T_m\}$ and apply the one with minimal cost as the final allocation.
+
+In practice, we also use two hyperparameters: $c_{r}$ to be subtracted from the cost-to-go function to encourage the agents to finish their ongoing subtasks, and $c_{i}$ to be added to the cost-to-go function to avoid allocating subtasks to an agent who can never accomplish a task within a timeout threshold $t_{o}$ .
+
+# 4.5 Complexity Analysis
+
+In an environment with $M$ subtasks and $N$ agents, the brute force search for an optimal allocation indeed has a complexity of $O(M^{N})$ . However, the practical complexity is much smaller than it. The reasons are as follows:
+
+1. In a certain stage of a long-horizon task, only a small amount of subtasks are feasible. Thus, the subtask amount $M$ can be pruned into a smaller number $L$ by checking the feasibility function $O(M \times N)$ times and ignoring the subtasks whose feasibility functions are less than a given threshold.
+2. The engaging $N$ agents can be classified into $C$ roles. The agents sharing the same role have the same reachability functions. $C$ is often a property of the task that does not scale with $N$ . For example, in the overcooked environment, $C$ can be the number of connected components of the map. Note that, in E-MAPP, the assistive agents aim to increase the reachability of the leading agents. We define $C \times L$ new subtasks $(\tau, c)$ , where $\tau$ comes from the $L$ feasible subtasks and $c$ comes from the $C$ roles. The goal of each new subtask $(\tau, c)$ is to help agents with role $c$ to gain reachability on subtask $\tau$ . We can obtain a new subtask set of size $O(C \times L)$ by extending the original subtask set with these newly defined subtasks. Assume that the number of agents is smaller than the number of feasible subtasks (otherwise, idle agents will inevitably emerge). Under this assumption, each agent will choose to either complete a subtask alone or assist a certain group of agents with the same role, and each subtask in the new subtask set is allocated to at most one agent to avoid
+
+conflict. Then the task allocation problem turns into finding the best matching of $N$ agents and $O(C \times L)$ subtasks with the smallest total cost, which can be solved by the Hungarian algorithm. The computational complexity is $O((N + CL)^3) \leq O((N + CM)^3)$ that scales well.
+
+# 5 Experiments
+
+In this section, we aim to investigate the following key questions. First, is the program guidance helpful for agents to understand long-horizon tasks in comparison with other structured information guidance? Second, are the parallel structures in the programs bring forth cooperative behaviors among the agents? Third, does the task allocator improve the completion rates and the time efficiency of the long-horizon tasks by virtue of the auxiliary functions?
+
+# 5.1 Environment Description
+
+To evaluate the proposed framework, we adapted the previous environment [50] mimicking the video game to a more challenging one "Overcooked v2". Concretely, we extend temporally for the horizon length of a task by adding additional behaviors such as "wash dishes" and "put out fire". As shown in Figure 5, agents can navigate through the grid world, interact with objects (e.g., tomatoes, knives), and deliver the dishes to the customers (the yellow star). The goal of the agents is to serve dishes according to the given recipes that can be divided into subtasks. More details about the environment can be found in Appendix A.7.
+
+
+Figure 5: A sample from the Overcooked environment.
+
+# 5.2 Setup
+
+Tasks. We test the agents on a variety of tasks with different difficulty levels. The easy tasks contain only one subroutine for verification. The medium tasks contain two or three subroutines. The hard task
+
+requires the agents to complete multiple dishes that require at least two subroutines each while putting out the randomly appearing fire. We conduct evaluation in two different patterns, based on seen or unseen tasks. Note that both evaluation scheme are conducted on novel maps, which makes the task more challenging. The unseen tasks share the subroutines with the seen tasks but is never used as a goal during training. The unseen tasks are used to test whether the methods can generalize compositionally. We also note that for the tasks with a repeat command (e.g., repeatedly pick an onion from the supply), a targeted repeat number is preset.
+
+Metrics. We use the completion rates and the average scores as the metrics. The completion rate is defined as the percentage of tasks that can be completed in an episode. The average score is the discounted cumulative rewards in an episode across all testing tasks. Agents will receive a reward of 1 when the final goal is achieved and receive a reward of 0.2 when a correct subtask is completed. Each algorithm is tested in 1000 environments and we report their average in the tables.
+
+Baselines. We compare our model with two baselines: MAPPO [51] and a natural language-guided agent. Detailed descriptions are in Appendix A.9.
+
+# 5.3 Results
+
+Results with seen tasks in novel maps. Table 1 shows the completion rate and average scores on seen tasks in novel maps, demonstrating that E-MAPP excels at understanding the structure of complex tasks. As expected, the end-to-end MAPPO model performs well on short-horizon tasks, but suffers from a significant performance drop when the task becomes complex. The natural language-guided model also has a large performance drop when the horizon of the tasks becomes longer. We attribute this to the agents' failure to understand the complex task structure described in natural language without explicit structure. By contrast, E-MAPP performs well even when the tasks have a long horizon with various accidental events happening.
+
+Table 1: Results on the seen tasks in novel maps. Completion rates and average scores of seen tasks in the Overcooked environment with three difficulty levels.
+
+| Methods | Completion Rates | Average Scores |
| Easy | Medium | Hard | Easy | Medium | Hard |
| E-MAPP (ours) | 98.0% | 97.5% | 56.3% | 1.06±0.17 | 1.12±0.22 | 1.58±0.60 |
| Natural language guidance | 81.9% | 48.1% | 1.01% | 0.87±0.43 | 0.63±0.51 | 0.82 ± 0.31 |
| MAPPO [51] | 100.0% | 65.7% | 0.00% | 1.11±0.04 | 0.79±0.31 | 0.59± 0.27 |
+
+Generalization with unseen tasks in novel maps. Table 2 shows the results on the zero-shot generalization scheme. The scenarios and tasks are very different from the training domain, posing an extra challenge to all the algorithms, including the auxiliary functions of E-MAPP. We find that E-MAPP is significantly better than both the previous multi-agent RL algorithms and a language-guided agent. We attribute the success of E-MAPP to the fact that programs have better compositionality and less ambiguity. In the training time, E-MAPP learns certain subroutines from other tasks; it applies the behavior compositionally to achieve goals never seen during training. More visualized results are in Appendix A.8.
+
+Table 2: Results on the unseen tasks in novel maps. Completion rates and average scores of unseen tasks with two difficulty levels.
+
+| Methods | Completion Rates | Average Scores |
| Medium | Hard | Medium | Hard |
| E-MAPP (ours) | 100.0% | 43.7% | 1.13 ± 0.10 | 0.99 ± 0.22 |
| Natural language-guided model | 58.4% | 0.0% | 0.58 ± 0.50 | 0.48 ± 0.21 |
+
+Ablation of auxiliary functions. We analyze the significance of the proposed key components in our model by comparing our model with the variants that removes 1) the feasibility predictor 2) the reachability predictor 3) the cost-to-go predictor. The completion rates and the average scores are shown in Table 3. We find that all the components are important to E-MAPP. Specifically, we find that removing the reachability predictor from E-MAPP leads to a significantly increased average timestep, and this is the component that provides the largest performance gain. We attribute this to the reachability function that pointed out the subtasks that can be completed individually, providing an impetus for agents to parallelize.
+
+Ablation of parallelism in the programs. We compare the proposed parallel programs with sequential programs in the same environments. In Table 3, we find that the agents with parallel programs use $15\%$ fewer time steps to accomplish the same goal as those with sequential programs. These results show that the parallel programs are central to E-MAPP in terms of time efficiency.
+
+Table 3: Ablation study. Completion rates, average scores, and timesteps when one of the key components of E-MAPP is removed.
+
+ | Completion Rates ↑ | Average Scores ↑ | Average Timesteps ↓ |
| E-MAPP | 56.3% | 1.58 ± 0.60 | 17.6 |
| w/o feasibility predictor | 38.5% | 1.42 ± 0.56 | 21.24 |
| w/o reachability predictor | 43.8% | 1.45 ± 0.50 | 23.37 |
| w/o cost-to-go predictor | 52.0% | 1.46 ± 0.45 | 20.42 |
| sequential program | 48.8% | 1.51 ± 0.47 | 20.33 |
+
+Partially observable environments. We conduct an experiment to show that E-MAPP can still outperform other methods in a partially observable environment. In the new setting, the observation of each agent is only part of the map within reach. Table 4 shows the results. Under the new setting, E-MAPP can still learn to allocate sub-tasks to agents and accomplish tasks efficiently.
+
+Table 4: Additional experiment in partially observable environments we conduct an experiment to show that E-MAPP can still outperform other methods in a partially observable environment.
+
+| model | score | completion rate |
| E-Mapp(partial obs) | 1.01±0.38 | 27.1% |
| E-MAPP(original) | 1.58±0.60 | 56.3% |
| MAPPO | 0.59±0.27 | 0.0% |
+
+# 5.4 Visualization of Learned Behaviors
+
+
+(a) parallel
+
+
+(b) repeat
+Figure 6: Learned behaviors of E-MAPP. Figure 6a shows that two agents are assigned two subtasks concurrently. Figure 6b shows that both agents are trying to repeatedly perform the same task. Figure 6c shows that one agent is passing an onion to the agent who can chop it.
+
+
+(c) assist
+
+In Figure 6, we show the representative learned behaviors of E-MAPP. In Figure 6(a), the two subroutines are allocated to two agents separately. This demonstrates the effectiveness of the feasibility function, with which the task allocator successfully identified the parallelizable subtasks that can be executed concurrently. We note that the parallel indicator in the program only suggests the agent trying to identify what subtasks are parallelizable rather than providing a ground-truth task structure. In Figure 6(b), we find that the two agents are performing the same task in a repeat subroutine independently. We show the allocator can assign tasks to multiple agents that are reachable to the goal. In Figure 6(c), we show that an assistive agent is passing an onion to the leading agent to chop. This shows how the agents learn to cooperate with each other. More visualizations can be found in Appendix A.8.
+
+# 5.5 Scalability to New Domains
+
+We also investigate whether E-MAPP can be effective on tasks with continuous action space based on the Stacking environment. More details and demos in Stacking can be found in Appendix A.10. We discuss some potential parallel-program synthesis approaches when applying E-MAPP to a new domain in Appendix A.14
+
+# 6 Conclusion
+
+In this paper, we first formulate the problem of program-guided multi-agent tasks. We propose Efficient Multi-Agent Reinforcement Learning with Parallel Programs (E-MAPP), an effective framework that uses a type of parallelism-aware program for multi-agent collaboration and a task allocation strategy via a set of learnable auxiliary functions. The results show that our algorithm can infer the task structure and significantly boost completion rates, efficiency, and generalization ability on long-horizon tasks.
+
+Limitations. Our current framework does not consider more challenging scenarios such as dynamic scenes or generalization to novel objects. We believe that this work opens a welcoming avenue to this research direction, and more future works will address additional challenges.
+
+Acknowledgements. We thank Yuping Luo and Zhecheng Yuan for their careful proofreading and writing suggestions.
+
+# References
+
+[1] Christopher Agia, Krishna Murthy Jatavallabhula, Mohamed Khodeir, Ondrej Miksik, Vibhav Vineet, Mustafa Mukadam, Liam Paull, and Florian Shkurti. Taskography: Evaluating robot task planning over large 3d scene graphs. In Aleksandra Faust, David Hsu, and Gerhard Neumann, editors, Proceedings of the 5th Conference on Robot Learning, volume 164 of Proceedings of Machine Learning Research, pages 46-58. PMLR, 08-11 Nov 2022.
+[2] Michael Ahn, Anthony Brohan, Noah Brown, Yevgen Chebotar, Omar Cortes, Byron David, Chelsea Finn, Keerthana Gopalakrishnan, Karol Hausman, Alex Herzog, Daniel Ho, Jasmine Hsu, Julian Ibarz, Brian Ichter, Alex Irpan, Eric Jang, Rosario Jauregui Ruano, Kyle Jeffrey, Sally Jesmonth, Nikhil Joshi, Ryan Julian, Dmitry Kalashnikov, Yuheng Kuang, Kuang-Huei Lee, Sergey Levine, Yao Lu, Linda Luu, Carolina Parada, Peter Pastor, Jornell Quiambao, Kanishka Rao, Jarek Rettinghouse, Diego Reyes, Pierre Sermanet, Nicolas Sievers, Clayton Tan, Alexander Toshev, Vincent Vanhoucke, Fei Xia, Ted Xiao, Peng Xu, Sichun Xu, and Mengyuan Yan. Do as i can and not as i say: Grounding language in robotic affordances. In arXiv preprint arXiv:2204.01691, 2022.
+[3] Marcin Andrychowicz, Filip Wolski, Alex Ray, Jonas Schneider, Rachel Fong, Peter Welinder, Bob McGrew, Josh Tobin, OpenAI Pieter Abbeel, and Wojciech Zaremba. Hindsight experience replay. Advances in neural information processing systems, 30, 2017.
+[4] Kai Arulkumaran, Antoine Cully, and Julian Togelius. Alphastar: An evolutionary computation perspective. In Proceedings of the genetic and evolutionary computation conference companion, pages 314-315, 2019.
+[5] Rudy Bunel, Matthew Hausknecht, Jacob Devlin, Rishabh Singh, and Pushmeet Kohli. Leveraging grammar and reinforcement learning for neural program synthesis. arXiv preprint arXiv:1805.04276, 2018.
+[6] David Chen and Raymond Mooney. Learning to interpret natural language navigation instructions from observations. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 25, pages 859-865, 2011.
+[7] Xinyun Chen, Chang Liu, and Dawn Song. Execution-guided neural program synthesis. In International Conference on Learning Representations, 2018.
+[8] Xinyun Chen, Dawn Song, and Yuandong Tian. Latent execution for neural program synthesis, 2021.
+[9] Todor Davchev, Oleg Sushkov, Jean-Baptiste Regli, Stefan Schaal, Yusuf Aytar, Markus Wulfmeier, and Jon Scholz. Wish you were here: Hindsight goal selection for long-horizon dexterous manipulation. In Deep RL Workshop NeurIPS 2021, 2021.
+[10] Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805, 2018.
+[11] Jacob Devlin, Jonathan Uesato, Surya Bhupatiraju, Rishabh Singh, Abdel-rahman Mohamed, and Pushmeet Kohli. Robustfill: Neural program learning under noisy i/o. In International conference on machine learning, pages 990–998. PMLR, 2017.
+[12] Ziluo Ding, Tiejun Huang, and Zongqing Lu. Learning individually inferred communication for multi-agent cooperation. Advances in Neural Information Processing Systems, 33:22069-22079, 2020.
+[13] Zach Dwiel, Madhavun Candadai, Mariano Phielipp, and Arjun K Bansal. Hierarchical policy learning is sensitive to goal space design. arXiv preprint arXiv:1905.01537, 2019.
+[14] Scott Emmons, Ajay Jain, Misha Laskin, Thanard Kurutach, Pieter Abbeel, and Deepak Pathak. Sparse graphical memory for robust planning. Advances in Neural Information Processing Systems, 33:5251-5262, 2020.
+
+[15] Ben Eysenbach, Russ R Salakhutdinov, and Sergey Levine. Search on the replay buffer: Bridging planning and reinforcement learning. Advances in Neural Information Processing Systems, 32, 2019.
+[16] Abhishek Gupta, Vikash Kumar, Corey Lynch, Sergey Levine, and Karol Hausman. Relay policy learning: Solving long-horizon tasks via imitation and reinforcement learning. In Conference on Robot Learning, pages 1025-1037. PMLR, 2020.
+[17] Jonathan Ho and Stefano Ermon. Generative adversarial imitation learning. Advances in neural information processing systems, 29, 2016.
+[18] Unnat Jain, Luca Weihs, Eric Kolve, Ali Farhadi, Svetlana Lazebnik, Aniruddha Kembhavi, and Alexander Schwing. A cordial sync: Going beyond marginal policies for multi-agent embodied tasks. In European Conference on Computer Vision, pages 471-490. Springer, 2020.
+[19] Natasha Jaques, Angeliki Lazaridou, Edward Hughes, Caglar Gulcehre, Pedro Ortega, DJ Strouse, Joel Z Leibo, and Nando De Freitas. Social influence as intrinsic motivation for multi-agent deep reinforcement learning. In International Conference on Machine Learning, pages 3040-3049. PMLR, 2019.
+[20] Christian Jestel, Harmtmut Surmann, Jonas Stenzel, Oliver Urbann, and Marius Brehler. Obtaining robust control and navigation policies for multi-robot navigation via deep reinforcement learning. In 2021 7th International Conference on Automation, Robotics and Applications (ICARA), pages 48–54. IEEE, 2021.
+[21] Jiechuan Jiang and Zongqing Lu. Learning attentional communication for multi-agent cooperation. Advances in neural information processing systems, 31, 2018.
+[22] Kishor Jothimurugan, Suguman Bansal, Osbert Bastani, and Rajeev Alur. Compositional reinforcement learning from logical specifications. Advances in Neural Information Processing Systems, 34, 2021.
+[23] Russell Kaplan, Christopher Sauer, and Alexander Sosa. Beating atari with natural language guided reinforcement learning. arXiv preprint arXiv:1704.05539, 2017.
+[24] Yunfei Li, Yilin Wu, Huazhe Xu, Xiaolong Wang, and Yi Wu. Solving compositional reinforcement learning problems via task reduction. In International Conference on Learning Representations, 2020.
+[25] Yunchao Liu and Zheng Wu. Learning to describe scenes with programs. In International conference on learning representations, 2019.
+[26] Ryan Lowe, Yi I Wu, Aviv Tamar, Jean Harb, OpenAI Pieter Abbeel, and Igor Mordatch. Multi-agent actor-critic for mixed cooperative-competitive environments. Advances in neural information processing systems, 30, 2017.
+[27] Rajbala Makar, Sridhar Mahadevan, and Mohammad Ghavamzadeh. Hierarchical multi-agent reinforcement learning. In Proceedings of the fifth international conference on Autonomous agents, pages 246-253, 2001.
+[28] Shie Mannor, Ishai Menache, Amit Hoze, and Uri Klein. Dynamic abstraction in reinforcement learning via clustering. In Proceedings of the twenty-first international conference on Machine learning, page 71, 2004.
+[29] Ofir Nachum, Shixiang (Shane) Gu, Honglak Lee, and Sergey Levine. Data-efficient hierarchical reinforcement learning. In S. Bengio, H. Wallach, H. Larochelle, K. Grauman, N. Cesa-Bianchi, and R. Garnett, editors, Advances in Neural Information Processing Systems, volume 31. Curran Associates, Inc., 2018.
+[30] Soroush Nasiriany, Huihan Liu, and Yuke Zhu. Augmenting reinforcement learning with behavior primitives for diverse manipulation tasks. In IEEE International Conference on Robotics and Automation (ICRA), 2022.
+
+[31] Junhyuk Oh, Yijie Guo, Satinder Singh, and Honglak Lee. Self-imitation learning. In Jennifer Dy and Andreas Krause, editors, Proceedings of the 35th International Conference on Machine Learning, volume 80 of Proceedings of Machine Learning Research, pages 3878–3887. PMLR, 10–15 Jul 2018.
+[32] Junhyuk Oh, Yijie Guo, Satinder Singh, and Honglak Lee. Self-imitation learning. In International Conference on Machine Learning, pages 3878–3887. PMLR, 2018.
+[33] Afshin Oroojlooyjadid and Davood Hajinezhad. A review of cooperative multi-agent deep reinforcement learning. CoRR, abs/1908.03963, 2019.
+[34] Peng Peng, Ying Wen, Yaodong Yang, Quan Yuan, Zhenkun Tang, Haitao Long, and Jun Wang. Multiagent bidirectionally-coordinated nets: Emergence of human-level coordination in learning to play starcraft combat games. arXiv preprint arXiv:1703.10069, 2017.
+[35] Silviu Pitis, Harris Chan, Stephen Zhao, Bradly Stadie, and Jimmy Ba. Maximum entropy gain exploration for long horizon multi-goal reinforcement learning. In International Conference on Machine Learning, pages 7750-7761. PMLR, 2020.
+[36] Matthias Plappert, Marcin Andrychowicz, Alex Ray, Bob Mcgrew, Bowen Baker, Glenn Powell, Jonas Schneider, Josh Tobin, Maciek Chogiej, Peter Welinder, et al. Multi-goal reinforcement learning: Challenging robotics environments and request for research. 2018. URL https://arxiv.org/pdf/1802.09464.pdf, 2018.
+[37] Tabish Rashid, Gregory Farquhar, Bei Peng, and Shimon Whiteson. Weighted qmix: Expanding monotonic value function factorisation for deep multi-agent reinforcement learning. Advances in neural information processing systems, 33:10199-10210, 2020.
+[38] Tabish Rashid, Mikayel Samvelyan, Christian Schroeder, Gregory Farquhar, Jakob Foerster, and Shimon Whiteson. Qmix: Monotonic value function factorisation for deep multi-agent reinforcement learning. In International Conference on Machine Learning, pages 4295-4304. PMLR, 2018.
+[39] Mikayel Samvelyan, Tabish Rashid, Christian Schroeder De Witt, Gregory Farquhar, Nantas Nardelli, Tim GJ Rudner, Chia-Man Hung, Philip HS Torr, Jakob Foerster, and Shimon Whiteson. The starcraft multi-agent challenge. arXiv preprint arXiv:1902.04043, 2019.
+[40] Nikolay Savinov, Alexey Dosovitskiy, and Vladlen Koltun. Semi-parametric topological memory for navigation. In International Conference on Learning Representations, 2018.
+[41] Samaneh Hosseini Semnani, Hugh Liu, Michael Everett, Anton De Ruiter, and Jonathan P How. Multi-agent motion planning for dense and dynamic environments via deep reinforcement learning. IEEE Robotics and Automation Letters, 5(2):3221-3226, 2020.
+[42] Satinder Singh, Richard L Lewis, Andrew G Barto, and Jonathan Sorg. Intrinsically motivated reinforcement learning: An evolutionary perspective. IEEE Transactions on Autonomous Mental Development, 2(2):70-82, 2010.
+[43] Martin Stolle and Doina Precup. Learning options in reinforcement learning. In International Symposium on abstraction, reformulation, and approximation, pages 212-223. Springer, 2002.
+[44] Shao-Hua Sun, Hyeonwoo Noh, Sriram Somasundaram, and Joseph Lim. Neural program synthesis from diverse demonstration videos. In International Conference on Machine Learning, pages 4790-4799. PMLR, 2018.
+[45] Shao-Hua Sun, Te-Lin Wu, and Joseph J Lim. Program guided agent. In International Conference on Learning Representations, 2019.
+[46] Peter Sunehag, Guy Lever, Audrunas Gruslys, Wojciech Marian Czarnecki, Vinicius Flores Zambaldi, Max Jaderberg, Marc Lanctot, Nicolas Sonnerat, Joel Z Leibo, Karl Tuyls, et al. Value-decomposition networks for cooperative multi-agent learning based on team reward. In AAMAS, 2018.
+
+[47] Richard S. Sutton and Andrew G. Barto. Reinforcement Learning: An Introduction. The MIT Press, second edition, 2018.
+[48] Eugene Vinitsky, Aboudy Kreidieh, Luc Le Flem, Nishant Kheterpal, Kathy Jang, Cathy Wu, Fangyu Wu, Richard Liaw, Eric Liang, and Alexandre M Bayen. Benchmarks for reinforcement learning in mixed-autonomy traffic. In Conference on robot learning, pages 399-409. PMLR, 2018.
+[49] Ruosong Wang, Simon S Du, Lin F Yang, and Sham M Kakade. Is long horizon reinforcement learning more difficult than short horizon reinforcement learning? arXiv preprint arXiv:2005.00527, 2020.
+[50] Sarah A Wu, Rose E Wang, James A Evans, Joshua B Tenenbaum, David C Parkes, and Max Kleiman-Weiner. Too many cooks: Bayesian inference for coordinating multi-agent collaboration. Topics in Cognitive Science, 13(2):414–432, 2021.
+[51] Chao Yu, Akash Velu, Eugene Vinitsky, Yu Wang, Alexandre Bayen, and Yi Wu. The surprising effectiveness of ppo in cooperative, multi-agent games. arXiv preprint arXiv:2103.01955, 2021.
+[52] Zelin Zhao, Karan Samel, Binghong Chen, et al. Proto: Program-guided transformer for program-guided tasks. Advances in Neural Information Processing Systems, 34, 2021.
+[53] Ming Zhou, Jun Luo, Julian Villella, Yaodong Yang, David Rusu, Jiayu Miao, Weinan Zhang, Montgomery Alban, Iman Fadakar, Zheng Chen, et al. Smarts: Scalable multi-agent reinforcement learning training school for autonomous driving. arXiv preprint arXiv:2010.09776, 2020.
+[54] Ming Zhou, Jun Luo, Julian Villella, Yaodong Yang, David Rusu, Jiayu Miao, Weinan Zhang, Montgomery Alban, IMAN FADAKAR, Zheng Chen, Chongxi Huang, Ying Wen, Kimia Hassanzadeh, Daniel Graves, Zhengbang Zhu, Yihan Ni, Nhat Nguyen, Mohamed Elsayed, Haitham Ammar, Alexander Cowen-Rivers, Sanjeevan Ahilan, Zheng Tian, Daniel Palenicek, Kasra Rezaee, Peyman Yadmellat, Kun Shao, dong chen, Baokuan Zhang, Hongbo Zhang, Jianye Hao, Wulong Liu, and Jun Wang. Smarts: An open-source scalable multi-agent rl training school for autonomous driving. In Jens Kober, Fabio Ramos, and Claire Tomlin, editors, Proceedings of the 2020 Conference on Robot Learning, volume 155 of Proceedings of Machine Learning Research, pages 264-285. PMLR, 16-18 Nov 2021.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential negative societal impacts of your work? [N/A] Our work focus on designing an algorithm for boosting the performance and generalization ability, rather than a specific real-world application.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] In the supplementary material
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] In the supplementary material
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes]
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] In the supplementary material
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [Yes]
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/images.zip b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..1e604992f5b53584eb98ca5932d032325489fdc2
--- /dev/null
+++ b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:97f9aee0a5047e56b776d0619ffc93317b9c4720dfe2388089d3fbde70f67e84
+size 336713
diff --git a/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/layout.json b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..fe6092bd2d22c4a51cd2071ee7bdcd26a52db447
--- /dev/null
+++ b/emappefficientmultiagentreinforcementlearningwithparallelprogramguidance/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c948b3f216e64223c9bdf614189826048fa47af5d6d3c41c092a642a97a70527
+size 450970
diff --git a/ens10adatasetforpostprocessingensembleweatherforecasts/e8838874-b2d0-411a-ac8a-b59947063ded_content_list.json b/ens10adatasetforpostprocessingensembleweatherforecasts/e8838874-b2d0-411a-ac8a-b59947063ded_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..cbb00360f12ed0e954905e4d979dfa086398af7e
--- /dev/null
+++ b/ens10adatasetforpostprocessingensembleweatherforecasts/e8838874-b2d0-411a-ac8a-b59947063ded_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ce26fe1412ddb5c92aa0ec7c53144289d1b2e168b0caba325d4432afa731cb67
+size 83915
diff --git a/ens10adatasetforpostprocessingensembleweatherforecasts/e8838874-b2d0-411a-ac8a-b59947063ded_model.json b/ens10adatasetforpostprocessingensembleweatherforecasts/e8838874-b2d0-411a-ac8a-b59947063ded_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..760671ddf356cf17a4653e96d8f878dd5ef1e342
--- /dev/null
+++ b/ens10adatasetforpostprocessingensembleweatherforecasts/e8838874-b2d0-411a-ac8a-b59947063ded_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:203fe161b3aa14a827cdf06412b158662821e3b28634b778631a317e81b7c4e4
+size 104946
diff --git a/ens10adatasetforpostprocessingensembleweatherforecasts/e8838874-b2d0-411a-ac8a-b59947063ded_origin.pdf b/ens10adatasetforpostprocessingensembleweatherforecasts/e8838874-b2d0-411a-ac8a-b59947063ded_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..00510c485c4ca50582a963c2fb962dada12c003f
--- /dev/null
+++ b/ens10adatasetforpostprocessingensembleweatherforecasts/e8838874-b2d0-411a-ac8a-b59947063ded_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4c8ee17ba262ee19bd9b524dc097e137a53f6fa09f6b908b00baa0e4e916fe82
+size 3606332
diff --git a/ens10adatasetforpostprocessingensembleweatherforecasts/full.md b/ens10adatasetforpostprocessingensembleweatherforecasts/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..f406067ffc8b772f86fc88dd2b2d5ce35bf3ca5b
--- /dev/null
+++ b/ens10adatasetforpostprocessingensembleweatherforecasts/full.md
@@ -0,0 +1,340 @@
+# ENS-10: A Dataset For Post-Processing Ensemble Weather Forecasts
+
+Saleh Ashkboos
+
+ETH Zürich
+
+saleh.ashkboos@inf.ethz.ch
+
+Langwen Huang
+
+ETH Zürich
+
+langwen.huang@inf.ethz.ch
+
+Nikoli Dryden
+
+ETH Zürich
+
+ndryden@ethz.ch
+
+Tal Ben-Nun
+
+ETH Zürich
+
+talbn@inf.ethz.ch
+
+Peter Dueben
+
+ECMWF
+
+peter.dueben@ecmwf.int
+
+Lukas Gianinazzi
+
+ETH Zürich
+
+glukas@ethz.ch
+
+Luca Kummer
+
+ETH Zürich
+
+lkummer@student.ethz.ch
+
+Torsten Hoefler
+
+ETH Zürich
+
+htor@inf.ethz.ch
+
+# Abstract
+
+Post-processing ensemble prediction systems can improve the reliability of weather forecasting, especially for extreme event prediction. In recent years, different machine learning models have been developed to improve the quality of weather post-processing. However, these models require a comprehensive dataset of weather simulations to produce high-accuracy results, which comes at a high computational cost to generate. This paper introduces the ENS-10 dataset, consisting of ten ensemble members spanning 20 years (1998-2017). The ensemble members are generated by perturbing numerical weather simulations to capture the chaotic behavior of the Earth. To represent the three-dimensional state of the atmosphere, ENS-10 provides the most relevant atmospheric variables at 11 distinct pressure levels and the surface at $0.5^{\circ}$ resolution for forecast lead times $T = 0$ , 24, and 48 hours (two data points per week). We propose the ENS-10 prediction correction task for improving the forecast quality at a 48-hour lead time through ensemble post-processing. We provide a set of baselines and compare their skill at correcting the predictions of three important atmospheric variables. Moreover, we measure the baselines' skill at improving predictions of extreme weather events using our dataset. The ENS-10 dataset is available under the Creative Commons Attribution 4.0 International (CC BY 4.0) license.
+
+# 1 Introduction
+
+Weather forecasting is among the most critical scientific applications, and has a significant influence on society and the economy [25]. Predicting the trajectory of a hurricane or tropical cyclone can save lives and billions of dollars in damages by allowing adequate mitigation efforts [29]. Moreover, weather forecasts can improve agricultural yield [53, 54] and guide decisions in aviation [16] and maritime ship transport [32]. However, predicting the weather, and extreme events in particular, are among the most complex tasks due to their chaotic behavior [35], and there has been an enormous amount of effort to tackle this problem in recent years [1, 4, 27, 48].
+
+In the last decades, forecasting weather variables (like temperature or precipitation) has been done by solving complex partial differential equations (PDEs) [28, 30]. To this end, Numerical Weather
+
+
+Figure 1: The post-processing pipeline feeds the ENS-10 ensemble, representing a biased distribution, to the deep learning model, which predicts a corrected distribution. This corrected distribution is scored against ERA5 ground truth data with the Continuous Ranked Probability Score (CRPS).
+
+Prediction (NWP) models start from an initial weather condition and output the new conditions by numerically approximating a set of PDEs. As a single simulation cannot represent the chaotic behavior of the environment [35], ensembles of simulations have been introduced to quantify such uncertainty and improve forecast quality [6]. In such methods, the initial conditions of the environment are perturbed multiple times, and an NWP model is run on each condition to generate an ensemble of forecasts. However, running NWP models incurs high computational costs. In addition, ensemble weather prediction suffers from systematic errors, known as biases, which are introduced during either the generation of initial conditions or the simulation itself [47].
+
+Ensemble post-processing approaches have been proposed to improve forecast skill by correcting the output distribution of the ensemble weather prediction models to remove biases, known as prediction correction, and are critical to improving the quality of ensemble forecasts [6, 45, 55]. In recent years, deep learning models [2, 12, 15, 26, 36, 39] have shown promising results on prediction correction over the well-known statistical methods [48] (e.g., EMOS [14], Bayesian Model Averaging [37]), which are representative of current approaches in production forecasting systems. Figure 1 summarizes the key steps of a deep learning-based post-processing pipeline. However, the performance of these models heavily depends on the available training data and the community lacks a unified and standard ensemble dataset, with different works using different forecast models, regions of the Earth, and so on [12, 26, 39]. Further, constructing an ensemble requires running multiple numerical models at a high computational cost. This makes training and comparing the quality of machine learning models for prediction correction challenging.
+
+To address this challenge, we introduce the ENS-10 dataset, a collection of 10 perturbed ensemble members over 20 years (1998–2017) for medium-range ensemble forecasts (48 hour lead time). To represent the state of the atmosphere, we provide the most relevant atmospheric fields at 11 different pressure levels as well as on the surface on a structured longitude/latitude grid with $0.5^{\circ}$ resolution. We then define the prediction correction task and propose two metrics of skill: Continuous Ranked Probability Score (CRPS), and the novel Extreme Event Weighted Continuous Ranked Probability Score (EECRPS). The weighted score gives importance to points where the ensemble members deviate from the climatology, rewarding skill on challenging, potentially unusual weather phenomena. We provide a set of baselines to apply unsupervised, statistical, and DNN-based supervised learning solutions (with different architectures) to the prediction correction task to serve as an initial benchmark. Finally, we provide a set of Python interfaces to download, train, and compare different models.
+
+# 1.1 Related Work
+
+Current weather forecasting is based on purely physical models, which numerically solve underlying equations to simulate weather [4]. In contrast, data-driven forecasting uses a learned model to directly predict weather variables. Such methods start from a deterministic atmospheric condition and generate the next state using a neural network or other model. In recent years, different architectures like fully connected networks [8], convolutional networks [8, 40, 43, 44], LSTMs [51], and transformers [34] have been applied to tackle this problem. While such models are becoming competitive for short-term nowcasting [10, 46], they currently are not competitive with NWP for medium-range forecasting [38].
+
+As data-driven forecasting approaches heavily depend on the data, they usually use reanalysis data, namely reproducing historical weather data consistently with an existing NWP model, as ground truth. To this end, different datasets such as ERA5 [20] and CFSR [42] have been developed and
+
+used as the input of the neural networks. Recently, WeatherBench [38] provided a set of benchmarks and metrics on a subset of the ERA5 dataset to accelerate data-driven weather forecasting research.
+
+In contrast to deterministic data-driven forecasting, we focus on ensemble processing methods [48], which can easily slot into production forecast workflows [45]. These methods operate on a set of ensemble members, each generated by running a NWP simulation on perturbed initial atmospheric conditions. The goal is to correct the prediction by mitigating the biases of the ensemble outputs, known as ensemble post-processing. Statistical methods such as ensemble model output statistics (EMOS) [14] and Bayesian moving averages (BMA) [37] are widely used for correcting such biases.
+
+Recent work has developed deep learning models for ensemble post-processing. To this end, different architectures, e.g., shallow fully connected networks [12, 39], LeNet-style convolutional networks [26], and U-Net-style networks [15] have been proposed. However, each work utilizes its own dataset and loss metrics (e.g., different regions of the Earth, different spatial or temporal resolutions, different forecast models, etc.), which makes comparisons challenging. ENS-10 fills this gap by providing a standard dataset and easy-to-use benchmarking infrastructure for post-processing.
+
+Other weather datasets contain ensembles, but most are not suitable for our prediction correction task. For example, the ERA5 dataset [20] contains ensembles, but is not suitable for post-processing because it is a reanalysis, not a forecast; and the Large Ensemble Community Project [22] focuses on longer-term climate predictions. Most closely related to ENS-10 are the Global Ensemble Forecast System (GEFS) reforecast datasets [18, 31] and the THORPEX Interactive Grand Global Ensemble (TIGGE) [5]. However, new GEFS reforecasts use only five ensemble members, compared to ten in ENS-10. TIGGE consists of operational forecasts, as opposed to forecasts, and therefore the forecast model, quality, and other parameters are inconsistent over time.
+
+# 2 ENS-10 Dataset
+
+# 2.1 Data Collection
+
+Global weather predictions are performed operationally in certain time intervals and often use ensembles of simulations for uncertainty quantification — for example, a 50-member ensemble twice a day at the European Centre for Medium-range Weather Forecasts (ECMWF).
+
+To derive a long-term training dataset that provides consistent quality for ensemble simulations, we use reforecasts [19], which are ensemble weather predictions that run routinely at ECMWF to simulate the weather over the past 20 years to the present. The resulting dataset is used to provide an estimate of the climate for each date to measure the skill of the forecast system [49, 50]. (Note the model used to generate reforecast datasets typically changes frequently as it is improved, so different reforecast datasets cannot typically be combined.) The reforecasts that were used for this dataset were generated by a model with 91 vertical levels using the Integrated Forecast System (IFS) of ECMWF [9], widely considered to be the most accurate global forecast model [17]. Reforecasts are generated for the time period from January 1998 to December 2017 and two simulations are started per week. The model uses a spectral representation of the model fields and a cubic octahedral reduced Gaussian grid is used to represent fields in grid-point space with a grid-spacing of approximately $36\mathrm{km}$ . For all years, IFS model cycle Cy43r1 was used to generate the data for all dates before 5th June and model cycle Cy45r1 were used for later dates of each year. This configuration matches what is used for production forecasts at ECMWF. As machine learning solutions often make use of convolutions in horizontal directions, we map the model fields and the ERA5 dataset onto a structured longitude/latitude grid with a $0.5^{\circ}$ resolution. The dataset is approximately 3 TB in size.
+
+# 2.2 Dataset Features
+
+The IFS weather model uses ten prognostic variables per grid point and 91 vertical levels per column, plus additional prognostic variables at the surface, yielding about one thousand prognostic variables per grid column. The vertical levels are processed into pressure levels, which are more representative for post-processing tasks. To keep data volume reasonable (the raw data would be hundreds of terabytes), we select a majority of the variables on each of a subset of the pressure levels, and additional surface variables. In doing so, we aim to select the input fields that hold the most significant amount of information about the three-dimensional state of the atmosphere.
+
+Table 1: Parameters of ENS-10. The dataset contains each parameter for 10 different ensemble members on resolution $0.5^{\circ}$ latitude/longitude grids at 0, 24, and 48 hour forecast lead times.
+
+| Name | Abbr | Unit | 48 h forecast min, mean, max (1998-2015) |
| Surface: |
| Sea surface temperature | SST | K | 306 |
| Total column water | TCW | kg/m2 | 261 |
| Total column water vapor | TCWV | kg/m2 | 137 |
| Convective precipitation | CP | m | 26 |
| Mean sea level pressure | MSL | Pa | 24.3 |
| Total cloud cover | TCC | (0-1) | 0.0002 |
| 10 m U wind component | U10m | m/s | 107480 |
| 10 m V wind component | V10m | m/s | 10138 |
| 2 m temperature | T2m | K | 0.62 |
| Total precipitation | TP | m | 41.3 |
| Skin temperature at surface | SKT | K | 42.2 |
| Pressure levels (10, 50, 100, 200, 300, 400, 500, 700, 850, 925 and 1000 hPa): |
| U wind component | U | m/s | 160 |
| V wind component | V | m/s | -115 |
| Geopotential | Z | m2/s2 | 117 |
| Temperature | T | K | 210 |
| Specific humidity | Q | kg kg-1 | 0.0001 |
| Vertical velocity | W | Pa/s | 0.0002 |
| Divergence | D | 1/s | 0.0014 |
+
+ENS-10 consists of the atmospheric fields that appear most relevant in this context (see Table 1), selected using a combination of community consensus (e.g., [15, 34, 38, 39]) and expert meteorological advice from ECMWF. Some of the fields are available at the surface (e.g., the wind at 10 meter height in the zonal and meridional directions, U10m and V10m; or temperature at 2 meters above ground, T2m). Other fields are integrated quantities over the vertical column of the atmospheric model resulting in two-dimensional horizontal fields that are classified as surface fields (e.g., total column water, TCW). Finally, some of the fields are diagnosed at pressure levels along the vertical direction of the atmosphere. These are geopotential, which provides information about the larger synoptic situation; temperature and the U and V wind components, which are highly relevant for forecast users; and specific humidity, vertical velocity, and divergence, which provide information about the cloud fields and convective state of the grid column. ENS-10 provides these fields at 11 distinct pressure levels between 10 and $1000\mathrm{hPa}$ , to describe the state of the atmosphere from the surface to the stratosphere. The fields are at lead times of 0, 24, and 48 hours starting from two dates per week over a span of 20 years (1998–2017).
+
+# 2.2.1 Surface Level Features
+
+The following variables are provided at surface level2.
+
+Sea Surface Temperature (SST) is the temperature of the sea in units of kelvin.
+
+Total Column Water (TCW) is the sum of water vapor, liquid water, cloud ice, rain, and snow in a column extending from the surface of the Earth to the top of the atmosphere. It is saved in units of kilogram per square meter.
+
+Total Column Water Vapor (TCWV) is the amount of water vapor in a column extending from the surface of the Earth to the top of the atmosphere. Like TCW, it is saved in units of kilogram per square meter.
+
+Convective Precipitation (CP) is the accumulated liquid and frozen water, comprising rain and snow, that falls to the Earth's surface, which is generated by the convection scheme in units of meters.
+
+Mean Sea Level pressure (MSL) is the pressure (force per unit area) of the atmosphere adjusted to the height of mean sea level in units of pascals.
+
+Total Cloud Cover (TCC) is the proportion of a grid column covered by cloud calculated as a single level field from the clouds occurring at different model levels through the atmosphere.
+
+10m U wind component (U10m) is the eastward component of the wind 10 meters above the ground in units of meters per second.
+
+10m V wind component (V10m) is the northward component of the wind 10 meters above the ground in units of meters per second.
+
+2m Temperature (T2m) is the temperature of air at $2\mathrm{m}$ above the surface of land, sea or in-land waters calculated by interpolating between the lowest model level and the Earth's surface, taking account of the atmospheric conditions. The field is saved in units of kelvin.
+
+Total Precipitation (TP) is the accumulated liquid and frozen water, comprising rain and snow, that falls to the Earth's surface. It is the sum of large-scale precipitation and convective precipitation and saved in units of meters.
+
+Skin temperature at the surface (SKT) indicates the temperature of the uppermost surface layer, which has no heat capacity and so can respond instantaneously to changes in surface fluxes, in kelvin.
+
+# 2.2.2 Volumetric Features
+
+The dataset provides the following seven fields at 11 distinct pressure levels between 10 and 1000 hPa, to describe the state of the atmosphere from the surface to the stratosphere.
+
+U wind component (U) is the eastward component of the wind at each pressure level. It is the horizontal speed of air moving towards the east, in units of meters per second. A negative sign thus indicates air movement towards the west.
+
+V wind component (V) is the northward component of the wind at each pressure level. It is the horizontal speed of air moving towards the north, in units of meters per second. A negative sign thus indicates air movement towards the south.
+
+Geopotential $(\mathbf{Z})$ is the gravitational potential energy of a unit mass, at a particular location, relative to mean sea level at each pressure level. It is also the amount of work that would have to be done, against the force of gravity, to lift a unit mass to that location from mean sea level. The variable is saved in units of $\mathrm{m}^2/\mathrm{s}^2$ .
+
+Temperature (T) shows the temperature at each pressure level. The field is saved in units of kelvin.
+
+Specific humidity (Q) is the mass of water vapor per kilogram of moist air at each pressure level. The total mass of moist air is the sum of the dry air, water vapor, cloud liquid, cloud ice, rain and falling snow. The field is saved in units of kilograms per kilogram.
+
+Vertical Velocity (W) is the air speed in the upward or downward direction at each pressure level in units of pascals per second.
+
+Divergence (D) is the rate of spreading the air from a point per square meter at each pressure level in the inverse second. The negative values show that the air is concentrating.
+
+# 3 Task
+
+The ultimate goal of ensemble post-processing is to correct the forecast of an ensemble by adjusting for any biases present (see Figure 2). In this section, we define the prediction correction task for different variables using the ENS-10 dataset. We provide different evaluation metrics to assess the quality of a given solution for this task on weather and extreme event forecasting. We also study the role of varying the number of ensemble members on the quality of a solution in our task.
+
+# 3.1 Prediction Correction
+
+For a given time $T$ , the input is a set of ensemble members $E = \{E_{k,T}\}_{k\in [1,10]}$ . Each ensemble member $E_{k,T}$ contains all surface and volumetric features at time steps $T, T + 24\mathrm{h}$ , and $T + 48\mathrm{h}$ .
+
+
+(a) Z500
+
+
+(b) T850
+Figure 2: A scatterplot of the raw ENS-10 ensemble forecast against the ERA5 reanalysis reveals varying levels of uncertainty for different target variables. Moreover, certain ranges of values are better characterized by the raw forecast than others. Post-processing corrects the raw ensemble distribution to remove biases and improve the forecast skill.
+
+
+(c) T2m
+
+For a given target variable at a specific pressure level (or at the surface), the task is to predict a corrected cumulative distribution function (CDF) $F^{i,j}$ for that variable at time $T + 48\mathrm{h}$ at each grid point $(i,j)$ (at the specified pressure level). Usually, this is achieved by estimating the parameters of the output probability distribution. Many previous works [15, 36, 39] assume a Gaussian distribution at each grid point and estimate the means and standard deviations. We follow this approach for our baselines. However, in general, any distribution or distribution representation may be assumed.
+
+In particular, we consider three target variables: $2\mathrm{m}$ temperature (T2m), temperature at 850 hPa (T850), and geopotential at 500 hPa (Z500). The years 1998-2015 are used as the training set and 2016-2017 as the test set. We use ERA5 as ground truth data for the exact weather at prediction time.
+
+# 3.2 Evaluation Metrics
+
+To evaluate a potential solution for our task, we use two different metrics as scores for prediction skill. CRPS is used for scoring predictions in general, and is widely used for evaluating forecast skill (e.g., in [15, 17, 39]). We also define a novel metric, called EECRPS, which assesses the correction's improvement in skill for extreme event prediction.
+
+Continuous Ranked Probability Score (CRPS). The corrected CDF $F$ is evaluated against the ERA5 ground-truth with CRPS [57]. CRPS generalizes the mean absolute error for the case where forecasts are probabilistic. Let $\mathbb{1}_{x \leq y}$ be an indicator function (1 if $x \leq y$ and 0 otherwise). Given the ground truth observation $x$ at grid-point $(i, j)$ , the CRPS for the corrected CDF $F$ at point $(i, j)$ is
+
+$$
+\operatorname {C R P S} \left(F ^ {i, j}, x\right) = \int_ {- \infty} ^ {\infty} \left(F ^ {i, j} (y) - \mathbb {1} _ {x \leq y}\right) ^ {2} d y, \tag {1}
+$$
+
+where the integration is over the range of possible outcomes for the target variable (see Figure 3(a)). The CRPS assumes $F$ has finite expectation. We report the mean CRPS over all grid points over the two test years, and for each day, we consider the variable at 00:00 UTC. The CRPS integral can often be solved in closed form using an identity by Baringhaus and Franz [3, 13].
+
+Extreme Event Weighted Continuous Ranked Probability Score (EECRPS). A crucial goal in correcting prediction biases is mitigating uncertainty during extreme weather events. In order to avoid muddling such events with forecast skill in the average case, we define a weighted version of CRPS that emphasizes such events.
+
+A widely used metric that defines the irregularity of forecast field values is the extreme forecast index (EFI) [24, 58]. The EFI measures the deviation of the ensemble forecast relative to a probabilistic climate model (see Figure 3(b)). The EFI ranges between $-1$ and $1$ , where large absolute values indicate a larger deviation from the meteorological record. Generally, values of magnitude between $0.5 - 0.8$ are considered unusual and values above $0.8$ are considered very unusual and indicate that extreme weather is likely. Therefore, given the ground-truth observation $y$ at grid-point $(i,j)$ , we use the absolute value of EFI at that point to weight the CRPS as a secondary score:
+
+$$
+\operatorname {E E C R P S} \left(F ^ {i, j}, y\right) := \left| \operatorname {E F I} _ {(i, j)} \right| \times \operatorname {C R P S} \left(F ^ {i, j}, y\right). \tag {2}
+$$
+
+We report the mean EECRPS over all grid points of the test years.
+
+Figure 3: Visualization of CRPS and EFI for predicting the temperature at $850\mathrm{hPa}$
+
+(a) CRPS is the calculated by integrating the square of the difference between the ensemble CDF and the reanalysis CDF (green area).
+
+
+(b) Left: $f(q)$ is the cumulative probability of the ensemble values that is smaller than the $q$ -quantile of the climate model. Right: EFI integrates the difference between the model climate and the ensemble forecast, but gives more weight to the extreme values.
+
+
+
+Given a grid-point $(i,j)$ , for each date, the climate model is an empirical distribution function of all ensemble predictions in a window around that date over many years at $(i,j)$ . That is, a sliding window is used to select the ensembles for each date.
+
+We calculate the $\mathrm{EFI}_{(i,j)}$ for all grid-points $(i,j)$ over the ENS-10 test set with 0.05-quantiles. To this end, at a specific date, we first calculate the cumulative histogram of the 10 ensemble members of our dataset at that date. Note that we use the same lead time of $48\mathrm{h}$ for all ensemble forecasts. Then, we aggregate ensemble predictions in a window of 9 dates centered around the selected date over the past 18 years. Hence, a total of $18\times 9\times 10$ ensemble members represent the climate model for each date. We calculate their quantiles from probability 0 to 1 at an interval of 0.05 as a discrete representation of the inverse of the cumulative distribution function. In the end, the $\mathrm{EFI}_{(i,j)}$ is calculated as
+
+$$
+\operatorname {E F I} _ {(i, j)} = \frac {2}{\pi} \sum_ {q \in \mathcal {Q}} \frac {q - f _ {(i , j)} (q)}{\sqrt {q (1 - q)}} \Delta q, \tag {3}
+$$
+
+where $\Delta q = 0.05$ , $\mathcal{Q} = \{0,0.05,0.1,\dots,0.95,1\}$ , $f_{(i,j)}(q)$ is calculated from the $q$ -quantile value of our climate model subtracted from the cumulative histogram at the position of the $q$ -quantile value.
+
+# 4 Benchmarks and Results
+
+We now define several representative baselines for the prediction correction task on ENS-10, and evaluate them all with both CRPS and EECRPS using five and ten ensemble members as input. All baselines are implemented in PyTorch [33] and included in the ENS-10 repository.
+
+# 4.1 Baseline Models
+
+A handful of models have been developed to tackle the ensemble post-processing task during the past decades [12, 14, 15, 37, 39]. However, they fall into five broad categories from which we select exemplars: "Simple" learned statistical methods, such as EMOS [14, 15, 39], which are also broadly representative of what is presently used by production forecast systems for post-processing; MLPs [12, 39]; simple convolutional neural networks [26] (also widely used for weather prediction [38, 40, 52]); U-Nets [15]; and transformers, which have recently been applied to ensembles [11] (and also to weather prediction [34]). Our goal is to train these models to minimize CRPS. However, in general, CRPS is not a differentiable metric. To overcome this issue, following previous work [15, 36, 39], we assume a Gaussian distribution on the target variable and learn the mean and standard deviation of this distribution. In this case, the CRPS from Eqn. (1) can be rewritten as
+
+$$
+\operatorname {C R P S} \left(F ^ {i, j}, x\right) = \sigma \left[ 2 \psi \left(\frac {x - \mu}{\sigma}\right) + \frac {x - \mu}{\sigma} \left(2 \phi \left(\frac {x - \mu}{\sigma}\right) - 1\right) - \frac {1}{\sqrt {\pi}} \right], \tag {4}
+$$
+
+where $\mu$ and $\sigma$ are the mean and standard deviation of the distribution, and $\psi$ and $\phi$ are the probability density and cumulative density function of a standard Gaussian random variable, respectively [13].
+
+In the simplest case, one can use the mean and standard deviation of the raw ensemble members as a predictor without any correction. However, to improve forecasting quality, the mean and standard deviation can be estimated using simple statistical approaches [14, 37] or deep learning models [12, 15, 39]. We define our baselines next.
+
+The raw baseline refers to using the raw ensemble mean and standard deviation for prediction. We apply this baseline for predicting all three variables in the prediction correction task. To this end, we calculate the CRPS using the mean and standard deviation of the ensembles on each grid point at $T = 48\mathrm{h}$ on our test set. We also calculate the EECRPS for $\mathrm{T2m}$ at $T + 48\mathrm{h}$ on the test set.
+
+Ensemble Model Output Statistics (EMOS) [14] is a statistical method based on a linear relation between the ensemble values and the corrected mean and variance.
+
+For a given set of ensemble members $E = \{E_{i,T}\}_{i\in [1,m]}$ , EMOS assumes a Gaussian distribution over the variable of interest $Y\sim \mathcal{N}(\mu ,\sigma^2)$ on each point and computes the mean $\mu$ and standard deviation $\sigma$ using $\mu = a + \sum_{i = 1}^{m}b_{i}E_{i,T}$ and $\sigma = c + d\sigma_{E}$ , where $\sigma_{E}$ is the standard deviation of the ensemble variables in $E$ . However, for predicting a target variable (such as Z500), EMOS uses only the input features for Z500 and does not exploit the inter-variable relations.
+
+A multi-layer perceptron (MLP) is a series of fully-connected layers followed by a non-linear function. For our baseline, we use an MLP with one hidden layer, following Rasp and Lerch [39]. The network corrects the prediction point-wise by estimating the corrected mean and standard deviation of a corrected Gaussian random variable. For each point, we provide the mean and standard deviation of all variables in ENS-10 at lead time $T = 48\mathrm{h}$ in the same pressure level as the variable of interest. In addition, we provide the spatial information of that point (latitude and longitude) in our baselines using a three-dimensional xyz coordinate on a unit sphere where $x = \cos(\psi)\sin(\phi), y = \cos(\psi)\cos(\phi), z = \sin(\psi)$ and $\psi, \phi$ are latitude and longitude.
+
+The MLP outputs two values associated with the mean and the standard deviation of the variable of interest. As we normalize the input to the network, to get the correct mean and standard deviation of a given input, we multiply the first output value with the standard deviation of the ensemble member and add the ensemble mean at that point. Similarly, we get the corrected standard deviation by taking the exponential of the second output value and multiplying it with the ensemble standard deviation. The baseline network has 25 and 17 input dimensions (two inputs for each variable in the ENS-10 dataset and three for XYZ coordinates) for the surface and volumetric features, respectively. We use a hidden layer with dimension 128 and ReLU as the activation function.
+
+Convolutional neural networks have demonstrated promise for both ensemble post-processing [26] and weather prediction [38, 40, 52]. We therefore follow Li et al. [26] and use a LeNet-style network as a baseline. Our network consists of three convolutional layers, each with an ELU [7] activation and batch normalization [21], kernel size $3 \times 3$ , no padding, and 64, 32, and 16 channels, respectively. When post-processing a grid point, we input a $7 \times 7$ patch centered on that grid point. The output (of shape $16 \times 1 \times 1$ ) is then used as input to an MLP constructed as above, with the same three-dimensional location embedding concatenated. The output features of the network then encode the mean and standard deviation of the corrected grid point and are also handled as above.
+
+The U-Net architecture is widely used in image segmentation tasks [41] and other tasks such as pixel-wise regression [56]. Recently, a U-Net style network has been applied to correcting the biases of ensembles [15]. We use a U-Net network as our baseline to predict the corrected mean and standard deviation of the Gaussian target variables.
+
+Following Gronquist et al. [15], we create a U-Net baseline with three levels, each containing a set of [convolution, batch normalization, ReLU] modules. The network operates on the whole grid with 22 and 14 input dimensions (two inputs for each variable in the ENS-10 dataset) for the surface and volumetric features, respectively. We use convolutions with 32, 64, and 128 output channels in our network's first, second, and third levels, respectively.
+
+Input data to the U-Net are normalized. The network outputs two grids for the mean and standard deviation of the variable of interest. Similar to the MLP, we scale and add the value of the first output channel with the standard deviation and mean of the ensemble members in each grid point. Also, we take the exponential of the second output channel of the network and multiply it with the ensemble standard deviation to get the corrected standard deviation.
+
+Finally, following Finn [11], we apply a self-attentive ensemble transformer as a baseline. Our model consists of three main components: the embedding layer, the self-attentive transformer module, and the output layer. The embedding consists of three $5 \times 5$ convolutional layers with ReLU activations and eight filters. Data are circularly padded longitudinally and zero padded latitudinally. Then, for the $i$ -th ensemble member, the self-attentive transformer module uses the weights estimated
+
+Table 2: Global mean CRPS and EECRPS on the ENS-10 test set (2016–2017) for baseline models with five (5-ENS) or ten (10-ENS) ensemble members.
+
+| Metric | Model | Z500 [m2s-2] | T850 [K] | T2m [K] |
| 5-ENS | 10-ENS | 5-ENS | 10-ENS | 5-ENS | 10-ENS |
| CRPS | Raw | 81.03 | 78.24 | 0.748 | 0.719 | 0.758 | 0.733 |
| EMOS | 79.08±0.739 | 81.74±6.131 | 0.725±0.002 | 0.756±0.052 | 0.718±0.003 | 0.749±0.054 |
| MLP | 75.84±0.016 | 74.63±0.029 | 0.701±2e-4 | 0.684±4e-4 | 0.684±6e-4 | 0.672±5e-4 |
| LeNet | 75.56±0.101 | 74.41±0.109 | 0.689±2e-4 | 0.674±2e-4 | 0.669±7e-4 | 0.659±4e-4 |
| U-Net | 76.66±0.470 | 76.25±0.106 | 0.687±0.003 | 0.669±0.009 | 0.659±0.005 | 0.644±0.006 |
| Transformer | 77.30±0.061 | 74.79±0.118 | 0.686±0.002 | 0.665±0.002 | 0.649±0.004 | 0.626±0.004 |
| EECRPS | Raw | 29.8 | 28.78 | 0.256 | 0.246 | 0.258 | 0.25 |
| EMOS | 29.10±0.187 | 30.13±2.166 | 0.248±3e-4 | 0.259±0.018 | 0.245±0.001 | 0.255±0.018 |
| MLP | 27.86±0.006 | 27.41±0.010 | 0.240±1e-4 | 0.234±2e-4 | 0.233±2e-4 | 0.229±2e-4 |
| LeNet | 27.72±0.039 | 27.30±0.037 | 0.235±5e-5 | 0.230±8e-5 | 0.228±2e-4 | 0.224±1e-4 |
| U-Net | 27.98±0.240 | 27.61±0.490 | 0.235±0.003 | 0.230±0.002 | 0.223±5e-4 | 0.219±0.001 |
| Transformer | 28.35±0.026 | 27.42±0.047 | 0.235±0.001 | 0.227±0.001 | 0.222±0.001 | 0.214±0.001 |
+
+based on the query-key similarity, where the query represents the $i$ -th ensemble member and the key the perturbations of the ensemble members. Finally, the output layer will map the transformed ensemble member with a $1 \times 1$ convolutional layer to the corrected ensemble member. We use one self-attentive transformer module with 16 heads. As the model outputs the corrected ensemble member, we calculate the mean and standard deviations offline to compute the CRPS and EECRPS.
+
+# 4.2 Baseline Scores
+
+We train all models using the Adam optimizer [23] with learning rate $10^{-5}$ , except the transformer, which uses 0.001. We do not use any learning rate scheduler during training. Input data is split into mini-batches according to the time index: each sample inside a mini-batch contains a "slice" of data with the same time index but different latitude/longitude indices. We use a batch size of 8 for the U-Net model, and 1 for the EMOS, MLP, and transformer models, as larger batch sizes yielded degraded performance. For the LeNet model, we use batch size 1 but feed the entire grid into the network at once. We train all models for 10 epochs on a single A100 GPU. Training the models took 0.75 (EMOS), 0.25 (MLP), 1.25 (LeNet), 1 (U-Net), and 1 (transformer) hours, respectively.
+
+The input data normalization for the MLP and U-Net models is performed according to the mean and standard deviation over all the time steps and ensemble members. Specifically, for each input variable at each latitude/longitude, the value is subtracted by the time-ensemble mean and divided by the standard deviation. In this way, any Gaussian distributed value over time and ensembles can be scaled to the Gaussian distribution with mean 0 and standard deviation 1. The normalization process is performed independently for different latitudes or longitudes to flatten the variance over different locations, following Gronquist et al. [15].
+
+Following the original implementation of EMOS [14], the normalization of input data for the EMOS model linearly scales each variable to the range between 0 and 1 using minimum and maximum values over all the time steps, ensemble members, and grid points.
+
+In addition to using the whole dataset (ten ensemble members), to show the importance of the number of ensemble members on the prediction correction task, we repeat all our experiments with the first five ensemble members (half of the dataset) from ENS-10. To evaluate the ability of our baselines on extreme event forecasting, we calculate the EECRPS of the T2m variable using the extracted EFI from our dataset (see Section 3.2 for more details). We use the absolute value of EFI to weight the CRPS metric before averaging over the global data points in our test set. We train each model using three different random seeds and report the mean and standard deviation.
+
+We show the results of our baselines in Table 2. Performance trends are similar between both CRPS and EECRPS: the LeNet-style model is best on Z500, whereas the transformer is best on T850 and T2m. The U-Net model also performs consistently well across all metrics. EMOS exhibited degradation in performance relative to the raw ensemble when using ten ensemble members in some runs and consequently has a large spread in performance; we suspect this could be avoided with
+
+additional optimizer tuning. Overall, no one model is consistently best, indicating the need to study a broad range of architectures and to refine their performance for future post-processing applications.
+
+# 5 Conclusion
+
+We present a dataset, ENS-10, and metrics for learning to correct biases in ensemble weather prediction systems. In particular, ten high-resolution ensemble members were generated for 20 years of weather forecasts. To represent the atmospheric environment of the earth, the dataset consists of the 11 most relevant surface variables as well as 7 variables at 11 distinct pressure levels in $0.5^{\circ}$ resolution. To measure prediction correction quality, we benchmark learned models using a widely-used score (CRPS) and a novel scoring function that prioritizes extreme weather events (EECRPS). As a baseline, we evaluate a set of statistical and machine learning models that are used by the weather and climate community on the dataset. By generating a high-resolution dataset of perturbed ensemble member simulations, ENS-10 enables data-driven global scale uncertainty quantification and bias correction, aiding in accurate pinpointing of extreme weather events. However, we caution that ENS-10 is not suitable on its own for tasks such as weather prediction; and further that its performance evaluation is necessarily predicated on the quality of the ERA5 reanalysis dataset we use as ground truth.
+
+Beyond ensemble post-processing, ENS-10 could be used for additional tasks, such as uncertainty quantification for weather prediction, developing probabilistic forecasts from deterministic trajectories, learning diagnostic fields from the prognostic fields of a forecast, or learning to fill gaps in weather time-series data to reduce the size of NWP model outputs.
+
+The ENS-10 dataset can be downloaded directly or through a downloader Python script. Examining the raw data, preprocessing, normalization, and training are all provided through a set of Python APIs, examples written in PyTorch, and Jupyter notebooks.
+
+# Acknowledgements
+
+This project received EuroHPC-JU funding under grant MAELSTROM, No. 955513. N.D. is supported by the ETH Postdoctoral Fellowship. T.B.N. is supported by the Swiss National Science Foundation (Ambizione Project #185778). We thank the Swiss National Supercomputing Center (CSCS) for providing computing resources.
+
+# References
+
+[1] Richard B Alley, Kerry A Emanuel, and Fuqing Zhang. Advances in weather prediction. Science, 363(6425):342-344, 2019.
+[2] Sándor Baran and Ágnes Baran. Calibration of wind speed ensemble forecasts for power generation. Quarterly Journal of the Hungarian Meteorological Service, 125(4):521-692, 2021.
+[3] L. Baringhaus and C. Franz. On a new multivariate two-sample test. Journal of Multivariate Analysis, 88(1):190-206, 2004.
+[4] Peter Bauer, Alan Thorpe, and Gilbert Brunet. The quiet revolution of numerical weather prediction. Nature, 525(7567):47-55, 2015.
+[5] Philippe Bougeault, Zoltan Toth, Craig Bishop, Barbara Brown, David Burridge, De Hui Chen, Beth Ebert, Manuel Fuentes, Thomas M Hamill, Ken Mylne, et al. The THORPEX interactive grand global ensemble. Bulletin of the American Meteorological Society, 91(8), 2010.
+[6] Roberto Buizza and David Richardson. 25 years of ensemble forecasting at ECMWF. ECMWF Newsletter, 2017.
+
+[7] Djork-Arné Clevert, Thomas Unterthiner, and Sepp Hochreiter. Fast and accurate deep network learning by exponential linear units (ELUs). In International Conference on Learning Representations (ICLR), 2016.
+[8] Peter D Dueben and Peter Bauer. Challenges and design choices for global weather and climate models based on machine learning. Geoscientific Model Development, 11(10):3999-4009, 2018.
+[9] ECMWF. Modeling and prediction. https://www.ecmwf.int/en/research/modelling-and-prediction, 2022.
+[10] Lasse Espeholt, Shreya Agrawal, Casper Sønderby, Manoj Kumar, Jonathan Heek, Carla Bromberg, Cenk Gazen, Jason Hickey, Aaron Bell, and Nal Kalchbrenner. Skillful twelve hour precipitation forecasts using large context neural networks. arXiv preprint arXiv:2111.07470, 2021.
+[11] Tobias Sebastian Finn. Self-attentive ensemble transformer: Representing ensemble interactions in neural networks for earth system models. In Tackling Climate Change with Machine Learning workshop at ICML, 2021.
+[12] Mohammadvaghef Ghazvinian, Yu Zhang, Dong-Jun Seo, Minxue He, and Nelun Fernando. A novel hybrid artificial neural network-parametric scheme for postprocessing medium-range precipitation forecasts. Advances in Water Resources, 151:103907, 2021.
+[13] Tilmann Gneiting and Adrian E Raftery. Strictly proper scoring rules, prediction, and estimation. Journal of the American Statistical Association, 102(477):359-378, 2007.
+[14] Tilmann Gneiting, Adrian E Raftery, Anton H Westveld III, and Tom Goldman. Calibrated probabilistic forecasting using ensemble model output statistics and minimum CRPS estimation. Monthly Weather Review, 133(5):1098-1118, 2005.
+[15] Peter Gronquist, Chengyuan Yao, Tal Ben-Nun, Nikoli Dryden, Peter Dueben, Shigang Li, and Torsten Hoefler. Deep learning for post-processing ensemble weather forecasts. Philosophical Transactions of the Royal Society A, 379(2194):20200092, 2021.
+[16] Ismail Gultepe, R Sharman, Paul D Williams, Binbin Zhou, G Ellrod, P Minnis, S Trier, S Griffin, Seong Yum, B Gharabaghi, et al. A review of high impact weather for aviation meteorology. Pure and applied geophysics, 176(5):1869-1921, 2019.
+[17] T Haiden, M Janousek, F Vitart, Z Ben-Bouallegue, L Ferranti, and F Prates. Evaluation of ECMWF Forecasts, including the 2021 Upgrade. European Centre for Medium Range Weather Forecasts, 2021.
+[18] Thomas M Hamill, Gary T Bates, Jeffrey S Whitaker, Donald R Murray, Michael Fiorino, Thomas J Galarneau, Yuejian Zhu, and William Lapenta. NOAA's second-generation global medium-range ensemble reforecast dataset. Bulletin of the American Meteorological Society, 94(10), 2013.
+[19] Thomas M. Hamill, Jeffrey S. Whitaker, and Steven L. Mullen. Reforecasts: An important dataset for improving weather predictions. Bulletin of the American Meteorological Society, 87(1), 2006.
+[20] Hans Hersbach, Bill Bell, Paul Berrisford, Shoji Hirahara, András Horányi, Joaquin Muñoz-Sabater, Julien Nicolas, Carole Peubey, Raluca Radu, Dinand Schepers, et al. The ERA5 global reanalysis. Quarterly Journal of the Royal Meteorological Society, 146(730):1999-2049, 2020.
+[21] Sergey Ioffe and Christian Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In International conference on machine learning (ICML), 2015.
+[22] Jennifer E Kay, Clara Deser, A Phillips, A Mai, Cecile Hannay, Gary Strand, Julie Michelle Arblaster, SC Bates, Gokhan Danabasoglu, James Edwards, et al. The community earth system model (CESM) large ensemble project: A community resource for studying climate change in the presence of internal climate variability. Bulletin of the American Meteorological Society, 96(8), 2015.
+
+[23] Diederik P Kingma and Jimmy Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014.
+[24] Francois Lalaurette. Early detection of abnormal weather conditions using a probabilistic extreme forecast index. Quarterly Journal of the Royal Meteorological Society: A journal of the atmospheric sciences, applied meteorology and physical oceanography, 129(594):3037-3057, 2003.
+[25] Jeffrey K Lazo, Rebecca E Morss, and Julie L Demuth. 300 billion served: Sources, perceptions, uses, and values of weather forecasts. Bulletin of the American Meteorological Society, 90(6), 2009.
+[26] Wentao Li, Baoxiang Pan, Jiangjiang Xia, and Qingyun Duan. Convolutional neural network-based statistical post-processing of ensemble precipitation forecasts. Journal of Hydrology, 605:127301, 2022.
+[27] Andrew C Lorenc. Analysis methods for numerical weather prediction. Quarterly Journal of the Royal Meteorological Society, 112(474):1177-1194, 1986.
+[28] Peter Lynch. Weather prediction by numerical process. The Emergence of Numerical Weather Prediction, 11:1-27, 2006.
+[29] UC Mohanty, Krishna K Osuri, Vijay Tallapragada, Frank D Marks, Sujata Pattanayak, M Mohapatra, LS Rathore, SG Gopalakrishnan, and Dev Niyogi. A great escape from the bay of bengal "super sapphire-phailin" tropical cyclone: a case of improved weather forecast and societal response for disaster mitigation. Earth Interactions, 19(17):1-11, 2015.
+[30] Eike H Müller and Robert Scheicl. Massively parallel solvers for elliptic partial differential equations in numerical weather and climate prediction. Quarterly Journal of the Royal Meteorological Society, 140(685):2608-2624, 2014.
+[31] NOAA. NOAA global ensemble forecast system (GEFS) re-forecast. https://registry.opendataaws/noaa-gefs-reforecast/, 2022.
+[32] Vaino Nurmi, Adriaan Perrels, Pertti Nurmi, Silas Michaelides, Spyros Athanasatos, and Matheos Papadakis. Economic value of weather forecasts on transportation-impacts of weather forecast quality developments to the economic effects of severe weather. EWENT FP7 project, 490, 2012.
+[33] Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, Alban Desmaison, Andreas Kopf, Edward Yang, Zachary DeVito, Martin Raison, Alykhan Tejani, Sasank Chilamkurthy, Benoit Steiner, Lu Fang, Junjie Bai, and Soumith Chintala. PyTorch: An imperative style, high-performance deep learning library. In Advances in neural information processing systems (NeurIPS), 2019.
+[34] Jaideep Pathak, Shashank Subramanian, Peter Harrington, Sanjeev Raja, Ashesh Chattopadhyay, Morteza Mardani, Thorsten Kurth, David Hall, Zongyi Li, Kamyar Azizzadeneshli, et al. FourCastNet: A global data-driven high-resolution weather model using adaptive fourier neural operators. arXiv preprint arXiv:2202.11214, 2022.
+[35] D Patil, I Szunyogh, B Hunt, J Yorke, E Ott, and E Kalnay. Applications of chaotic dynamics to weather forecasting. In AGU Fall Meeting Abstracts, volume 2001, pages NG42A-0412, 2001.
+[36] Ting Peng, Xiefei Zhi, Yan Ji, Luying Ji, and Ye Tian. Prediction skill of extended range 2-m maximum air temperature probabilistic forecasts using machine learning post-processing methods. Atmosphere, 11(8):823, 2020.
+[37] Adrian E Raftery, Tilmann Gneiting, Fadoua Balabdaoui, and Michael Polakowski. Using bayesian model averaging to calibrate forecast ensembles. Monthly weather review, 133(5):1155-1174, 2005.
+
+[38] Stephan Rasp, Peter D Dueben, Sebastian Scher, Jonathan A Weyn, Soukayna Mouatadid, and Nils Thuerey. WeatherBench: a benchmark data set for data-driven weather forecasting. Journal of Advances in Modeling Earth Systems, 12(11):e2020MS002203, 2020.
+[39] Stephan Rasp and Sebastian Lerch. Neural networks for postprocessing ensemble weather forecasts. Monthly Weather Review, 146(11):3885-3900, 2018.
+[40] Stephan Rasp and Nils Thuerey. Data-driven medium-range weather prediction with a ResNet pretrained on climate simulations: A new model for WeatherBench. Journal of Advances in Modeling Earth Systems, 13(2), 2021.
+[41] Olaf Ronneberger, Philipp Fischer, and Thomas Brox. U-net: Convolutional networks for biomedical image segmentation. In International Conference on Medical image computing and computer-assisted intervention, 2015.
+[42] Suranjana Saha, Shrinivas Moorthi, Hua-Lu Pan, Xingren Wu, Jande Wang, Sudhir Nadiga, Patrick Tripp, Robert Kistler, John Woollen, David Behringer, et al. The NCEP climate forecast system reanalysis. Bulletin of the American Meteorological Society, 91(8):1015-1058, 2010.
+[43] Sebastian Scher. Toward data-driven weather and climate forecasting: Approximating a simple general circulation model with deep learning. Geophysical Research Letters, 45(22):12-616, 2018.
+[44] Sebastian Scher and Gabriele Messori. Weather and climate forecasting with neural networks: using general circulation models (GCMs) with different complexity as a study ground. Geoscientific Model Development, 12(7):2797-2809, 2019.
+[45] Martin G Schultz, Clara Betancourt, Bing Gong, Felix Kleinert, Michael Langguth, Lukas Hubert Leufen, Amirpasha Mozaffari, and Scarlet Stadtler. Can deep learning beat numerical weather prediction? Philosophical Transactions of the Royal Society A, 379(2194), 2021.
+[46] Casper Kaae Sønderby, Lasse Espeholt, Jonathan Heek, Mostafa Dehghani, Avital Oliver, Tim Salimans, Shreya Agrawal, Jason Hickey, and Nal Kalchbrenner. MetNet: A neural weather model for precipitation forecasting. arXiv preprint arXiv:2003.12140, 2020.
+[47] Zoltan Toth and Eugenia Kalnay. Ensemble forecasting at NMC: The generation of perturbations. Bulletin of the american meteorological society, 74(12):2317-2330, 1993.
+[48] Stephane Vannitsem, John Bjørnar Bremnes, Jonathan Demaeyer, Gavin R Evans, Jonathan Flowerdew, Stephan Hemri, Sebastian Lerch, Nigel Roberts, Susanne Theis, Aitor Atencia, et al. Statistical postprocessing for weather forecasts: Review, challenges, and avenues in a big data world. Bulletin of the American Meteorological Society, 102(3):E681-E699, 2021.
+[49] F Vitart. Evolution of ECMWF sub-seasonal forecast skill scores. Quarterly Journal of the Royal Meteorological Society, 140(683):1889-1899, 2014.
+[50] F. Vitart, M. Alonso-Balmaseda, A. Benedetti, B. Balan-Sarojini, S. Tietsche, J. Yao, M. Janousek, G. Balsamo, M. Leutbecher, P. Bechtold, I. Polichthouk, D. Richardson, T. Stockdale, and C. Roberts. Extended-range prediction. ECMWF Technical Memorandum 854, 2019.
+[51] Jonathan A Weyn, Dale R Durran, and Rich Caruana. Can machines learn to predict weather? using deep learning to predict gridded 500-hPa geopotential height from historical weather data. Journal of Advances in Modeling Earth Systems, 11(8):2680-2693, 2019.
+[52] Jonathan A Weyn, Dale R Durran, and Rich Caruana. Improving data-driven global weather prediction using deep convolutional neural networks on a cubed sphere. Journal of Advances in Modeling Earth Systems, 12(9), 2020.
+[53] D.S. Wilks, R.E. Pitt, and G.W. Fick. Modeling optimal alfalfa harvest scheduling using short-range weather forecasts. Agricultural Systems, 42(3):277-305, 1993.
+[54] D.S. Wilks and D.W. Wolfe. Optimal use and economic value of weather forecasts for lettuce irrigation in a humid climate. Agricultural and Forest Meteorology, 89(2):115-129, 1998.
+
+[55] World Meteorological Organization. Guidelines on ensemble prediction system postprocessing, 2021 edition. Technical report, World Meteorological Organization, 2021.
+[56] Wei Yao, Zhigang Zeng, Cheng Lian, and Huiming Tang. Pixel-wise regression using U-net and its application on pansharpening. Neurocomputing, 312:364-371, 2018.
+[57] Michael Zamo and Philippe Naveau. Estimation of the continuous ranked probability score with limited information and applications to ensemble weather forecasts. Mathematical Geosciences, 50(2):209-234, 2018.
+[58] Ervin Zsóter. Recent developments in extreme weather forecasting. ECMWF newsletter, 107(107):8-17, 2006.
\ No newline at end of file
diff --git a/ens10adatasetforpostprocessingensembleweatherforecasts/images.zip b/ens10adatasetforpostprocessingensembleweatherforecasts/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..535e66aa1da146cc4c05e7d0bdc675aa1c682033
--- /dev/null
+++ b/ens10adatasetforpostprocessingensembleweatherforecasts/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d9591521126a4d99da924f5b3c3b25eb8044d920beb0ebec8f3e505931ff153c
+size 388008
diff --git a/ens10adatasetforpostprocessingensembleweatherforecasts/layout.json b/ens10adatasetforpostprocessingensembleweatherforecasts/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..d60a6a86d7d865805da5182f2ab4b76a19a30d2b
--- /dev/null
+++ b/ens10adatasetforpostprocessingensembleweatherforecasts/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:30b363aacfa87929abb0c457d279b6ae7aa5188a8ca0b1e5d0c315eb66780979
+size 394233
diff --git a/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/8b1a6a81-04bb-42cc-b96f-9666534e51f0_content_list.json b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/8b1a6a81-04bb-42cc-b96f-9666534e51f0_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..e6e7057f4479897a458a1af833ffc56971dad2c1
--- /dev/null
+++ b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/8b1a6a81-04bb-42cc-b96f-9666534e51f0_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:67c9f9980a053b1cfaa866790e57b19181f2026f1a1f7152e7bd4661d0618dac
+size 80227
diff --git a/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/8b1a6a81-04bb-42cc-b96f-9666534e51f0_model.json b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/8b1a6a81-04bb-42cc-b96f-9666534e51f0_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..94ed635039f7afe27ebea49f726194c92a6590ec
--- /dev/null
+++ b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/8b1a6a81-04bb-42cc-b96f-9666534e51f0_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:aaa9f7ddc7bc477332a7814e664c0c06f3ae0fe3f1d33785b34f22ffdced50bc
+size 99500
diff --git a/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/8b1a6a81-04bb-42cc-b96f-9666534e51f0_origin.pdf b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/8b1a6a81-04bb-42cc-b96f-9666534e51f0_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..d1bd0526806e63667793ef437fc89f9142610ad3
--- /dev/null
+++ b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/8b1a6a81-04bb-42cc-b96f-9666534e51f0_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f310a99ce060d482922ca91acdfe0543e405e9fa3abef6bc085d26b87eb5655b
+size 31126031
diff --git a/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/full.md b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..d9176d1659799c4335d1e4a14b3461468ab8cef4
--- /dev/null
+++ b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/full.md
@@ -0,0 +1,303 @@
+# EPIC-KITCHENS VISOR Benchmark Video Segmentations and Object Relations
+
+
+
+# Abstract
+
+We introduce VISOR, a new dataset of pixel annotations and a benchmark suite for segmenting hands and active objects in egocentric video. VISOR annotates videos from EPIC-KITCHENS, which comes with a new set of challenges not encountered in current video segmentation datasets. Specifically, we need to ensure both short- and long-term consistency of pixel-level annotations as objects undergo transformative interactions, e.g. an onion is peeled, diced and cooked - where we aim to obtain accurate pixel-level annotations of the peel, onion pieces, chopping board, knife, pan, as well as the acting hands. VISOR introduces an annotation pipeline, AI-powered in parts, for scalability and quality. In total, we publicly release 272K manual semantic masks of 257 object classes, 9.9M interpolated dense masks, 67K hand-object relations, covering 36 hours of 179 untrimmed videos. Along with the annotations, we introduce three challenges in video object segmentation, interaction understanding and long-term reasoning.
+
+For data, code and leaderboards: http://epic-kitchens.github.io/VISOR
+
+# 1 Introduction
+
+Consider a video capturing the tedious process of preparing bread, from obtaining, measuring and mixing ingredients to kneading and shaping dough. Despite being a routine task, the discrete nature of computer vision models, trained mostly from images, expects to recognise objects as either flour or dough. Capturing the transformation through pixel-level annotations has not been attempted to date. Building on top of EPIC-KITCHENS egocentric videos [12], VISOR utilises action labels and provides sparse segmentations, of hands and active objects, with a rate of annotations so as to represent both short (e.g. 'add salt') and long ('knead dough') temporal actions. In Fig. 1, we introduce sample annotations from one video of VISOR.
+
+Rich pixel-level annotations have transformed image understanding [17, 23] and autonomous driving [10, 13], amongst other tasks. By augmenting action labels with semantic segmentations, we hope to enable complex video understanding capabilities. Previous efforts to incorporate spatio-temporal annotations and object relations [15, 16, 19, 22] have only featured bounding boxes. A few seminal video datasets [31, 41, 43] provide pixel labels over time, but are often short-term, and are not associated with fine-grained action labels. We compare VISOR to other datasets in §2.
+
+We obtain VISOR annotations via a new pipeline consisting of three stages that we describe in §3: (i) identifying active objects that are of relevance to the current action, as well as their semantic label; (ii) annotating pixel-level segments with an AI-powered interactive interface iterated with manual quality-control checks; and (iii) relating objects spatially and temporally for short-term consistency and hand-object relations.
+
+
+Figure 1: VISOR Annotations and Benchmarks. Sparse segmentations from one video (P06_03), where flour turns into dough over the course of over 11 minutes. The colours of the timeline represent the stages: flour $\rightarrow$ mixture $\rightarrow$ dough. By building off of the EPIC-KITCHENS dataset, our segments join a rich set of action labels. We use the annotations to define three challenges at different timescales: (i) Semi-Supervised VOS over several actions; (ii) Hand $\leftrightarrow$ Object Segmentation and contact relations in the moment; and (iii) where did this come from? for long-term reasoning.
+
+In total, we obtain annotations of 271.6K masks across 50.7K images of 36 hours, interpolated to 9.9M dense masks, which we analyse in §4. Moreover, these new annotations directly plug in with a strong existing ecosystem of annotations, from action labels to closed-vocabulary of objects.
+
+In §5, we use these new annotations to define three benchmarks, depicted in Fig. 1 (bottom). Our first task, Semi-Supervised Video Object Segmentation (VOS), requires tracking object segments across consecutive actions. We extend previous VOS efforts [31, 41, 43] by tackling 2.5-4x longer sequences. Our second task, Hand Object Segmentation (HOS), involves predicting the contact between hands and the active objects, and extends past efforts by predict both the relation and accurate segmentations of hands and objects. Our final task, Where Did This Come From (WDTCF)?, is a taster benchmark for long-term perception with scene segmentation, where one traces back a given segment to the container it came from (e.g., milk from the fridge, and a plate from a particular cupboard) and identifies the frame(s) containing evidence of the query object emerging from the container.
+
+# 2 Related Efforts
+
+We compare VISOR with previous efforts that have both pixel-level and action annotations in Table 1. We divide our comparison into three sections: basic statistics on the videos themselves, pixel-level annotation statistics on images annotated, masks and average masks per image and action annotations where entities or action classes have been labelled. Our videos are significantly longer. On average, VISOR videos are 12 minutes long. To make the challenge feasible to current state-of-the-art models, we divide our videos into shorter sequences that are 12 seconds long on average. VISOR is also the only dataset that combines pixel-level segmentations with both action and entity class labels.
+
+The closest effort to VISOR is that of the seminal UVO work [41] that annotates videos from the Kinetics dataset [7]. As every video in Kinetics captures a single action, UVO only offers short-term object segmentations, focusing on translated objects and occlusions. In contrast, VISOR annotates videos from EPIC-KITCHENS [11] that capture sequences of 100s of fine-grained actions. VISOR segmentations thus capture long-term object segmentations of the same instance undergoing a series of transformations – the same potato is seen being picked from the fridge, washed, peeled, cut,
+
+Table 1: Comparison with Current Data. Compared to past efforts featuring both pixel- and action-level annotations, VISOR features longer sequences and provides the largest number of manually annotated masks on diverse actions and objects. *:Stats from train/val public annotations. † Avg VISOR video is 12 minutes long. We divide these into sub-sequences w/ consistent entities (See §3). Masks are semantically consistent, through class knowledge, across all videos.
+
+| Dataset | Basic Statistics | Pixel-Level Annotations | Action Annotations |
| Year | Total Mins | Avg Seq Ln | Total Masks | Total Images | Avg Masks per Image | Actions | #Action Classes | #Entity Classes |
| EgoHand [3] | 2015 | 72 | - | 15.1K | 4.8K | 3.2 | - | - | 2 |
| DAVIS [6] | 2019 | 8 | 3s | 32.0K | 10.7K | 3.0 | - | - | - |
| YTVOS [43] | 2018 | 335 | 5s | 197.2K | 120.4K | 1.6 | - | - | 94 |
| UVOv0.5 (Sparse) [41] | 2021 | 511 | 3s | *200.6K | 30.5K | *8.8 | 10,213 | 300 | - |
| VISOR (Ours) | 2022 | 2,180 | \( 12s^† \) | 271.6K | 50.7K | 5.3 | 27,961 | 2,594 | 257 |
+
+and cooked. Object transformations are also significantly more varied, beyond translation and deformation, offering a challenge previously unexplored. Ensuring long-term temporal consistency in VISOR requires a more complex framework for relating objects over sequences and through semantic classes. In doing so, we take inspiration from UVO [41] in how sparse segmentations were used with bi-directional interpolations to obtain dense annotations (See appendix 3.4).
+
+VISOR is also related to efforts that capture hand-object relations, including for identifying active objects [35, 4], next active objects [33, 25], object articulation [44] and grasping [18, 39, 38, 40]. Distinct from these works, we provide the first pipeline, annotations and benchmark suite for pixel-level segmentations.
+
+# 3 VISOR annotation pipeline
+
+Our annotation pipeline consists of multiple stages. In the first stage, we identify the frames and active entities to be annotated (§3.1). Having identified what should be segmented, we obtain pixel-level annotations, substantially accelerated by an AI-powered tool. To achieve consistency, we subject annotators to extensive training, and employ manual verification (§3.2). Finally, we collect additional annotations that are needed for our challenges (§3.3). We next describe our pipeline in detail.
+
+Background: EPIC-KITCHENS Dataset and Annotations. We build on the large-scale egocentric EPIC-KITCHENS-100 dataset [11], collected with University of Bristol faculty ethics approval and signed consent forms of participants (anonymous). Participants wear a head-mounted camera, start recording before they enter the kitchen and only stop recording when they leave the room. These videos have fine-grained action labels comprising: (i) video file (e.g., P06_108); (ii) start and end times of an action (e.g., from 03:52.6 to 03:58.4); (iii) short open-vocabulary narration describing the action (e.g., 'take mozzarella out of packet'); (iv) closed-vocabulary of verb and noun classes (e.g. mapping 'mozzarella' to the class 'cheese'). Table 2 of [11] compares EPIC-KITCHENS to publicly available action recognition datasets in size, annotations and classes (e.g., [7, 16, 37]).
+
+# 3.1 Entities, frames and sub-sequences
+
+Our first stage aims to identify what data and entities ought to be annotated. Our data selection aims to find clear frames to annotate and distribute annotation uniformly across actions rather than time, to cover actions of varying length. Entity selection aims to find all active objects, relevant to the action, including tools, crockery and appliances. This step is needed since the narrations do not include objects that are implied by common-sense, and are different per sample: e.g., one example of the action 'peel carrot' might involve a peeler and a bowl while another might use a knife and chopping board. Note that as videos are captured in people's homes, frames can be highly cluttered with background/irrelevant objects we do not wish to segment.
+
+We show the pipeline for the selection of frames and entities in Fig. 2. We divide the untrimmed videos into sequences comprising 3 non-overlapping actions. This achieves a mean of 12 seconds of temporally consistent annotations. We chose 3 actions so as to introduce slight but reasonable challenge to previous video segmentation datasets, increasing sequence lengths from 3-5s to 12s (see Table 1). We annotate 6 frames per sequence, avoiding blurred frames when possible for better object boundaries. We candidate active entities to annotate from parsing nouns in narrations, correlations with actions from parsed verbs (e.g., 'cut' and 'knife') and manual annotations. Annotators select the
+
+
+Figure 2: Part of the VISOR Annotation Pipeline. We divide untrimmed videos to subsequences of 3 consecutive actions, sampling 6 frames/seq. We find entities to annotate via the union of automatic parsing of narrations, manual rules, and human annotations. These are then manually segmented.
+
+Table 2: VISOR splits statistics. Details of VISOR splits.
+
+| VISOR splits | Train | Val | Train+Val | Test | Total |
| # Kitchens | 33 | 24 (5 unseen) | 38 | 13 (4 unseen) | 42 |
| # Untrimmed Videos | 115 | 43 | 158 | 21 | 179 |
| # Images (and %) | 32,857 (64.8%) | 7,747 (15.3%) | 40,604 (80.0%) | 10,125 (20.0%) | 50,729 |
| # Masks (and %) | 174,426 (64.2%) | 41,559 (15.3%) | 215,985 (79.5%) | 55,599 (20.5%) | 271,584 |
| # Entity Classes | 242 | 182 (9 zero-shot) | 251 | 160 (6 zero-shot) | 257 |
+
+entities that are present per frame from this over-complete list. A showcase of the dataset's diversity in actions and entities is visualised in Fig. 3 and more details are in the appendix.
+
+# 3.2 Tooling, annotation rules and annotator training
+
+During the project's 22 months, we worked closely with 13 annotators: training, answering questions, and revising their annotations. A more complete description of the annotation pipeline and interface, including cross-annotator agreement, is included in the appendix.
+
+AI-Powered Segmentation Tooling. To reduce the cost of pixel-level annotation, we use TORonto Annotation Suite (TORAS) [20], which uses interactive tools built from variants of [24, 42]. The interface combines a mix of manual and AI-enhanced tools that we found to dramatically improve the speed of obtaining accurate annotations. The AI models were trained on generic segmentation datasets like ADE-20K [45]. We found they generalised well to our domain as shown in [2, 8, 24].
+
+Annotator Recruiting, Onboarding, and Rules. We hired freelance annotators via Upwork. They received an overview of the project, training sessions with the tool, and a glossary of objects. We devised rules to facilitate consistent segmentations across frames for containers, packaging, transparency and occlusion, detailed in Appendix. To give an example, first image in Fig 3 shows our 'container' rule where other inactive objects in the cupboard are not segmented out, to show the full extent of the cupboard. Each video was annotated by one annotator to maximise temporal consistency. In addition to actively resolving annotator confusions, each video was manually verified. We created an interface for fast correction of annotations, focusing on temporal consistency.
+
+Splits. In Table 2 we showcase the Train/Val/Test splits. We provide a train/val publicly-accessible split along with a held-out test set of 21 videos ( $\approx$ $20\%$ of the frames and the masks). Note that the Test split aligns with the EPIC-KITCHENS test split, which is used for the action recognition challenge. For both Val and Test, we keep some kitchens unseen to test generality to new environments. The Train/Test annotations are available here. Evaluating on the test set is through the challenge leaderboards - see the EPIC-KITCHENS challenges for details.
+
+
+Figure 3: Segmentations from VISOR with entity names (legend) and ongoing action (above).
+
+# 3.3 VISOR Object Relations and Entities
+
+We now describe additional meta-data we collected to utilise spatial relations between the segmentations, using crowdsourcing with gold-standard checks (details in appendix).
+
+Entities. EPIC-KITCHENS-100 contains 300 noun classes, grouping open-vocabulary entity names. Of these, VISOR segmentations cover 252 classes from the annotated 36 hours. VISOR introduces 263 new entities spanning 83 noun classes. We manually re-cluster these into the 300 EPIC-KITCHENS classes. These entities are mainly objects that are handled in everyday actions but not mentioned in narrations, such as 'coffee package', which is grouped into the 'package' class. We also introduce five new classes: 'left hand', 'right hand' (previously only 'hand'), 'left glove', 'right glove' (previously only 'glove') and 'foot'. As a result, VISOR contain 257 entity classes.
+
+Hand-Object Relations. The activities depicted in VISOR are driven by hands interacting with the scene. We augment each hand segmentation in the dataset with contact information indicating whether it is in contact and, if so, which segment the hand is best described as contacting. We identify candidate segments as those sharing a border with the hand. Human annotators select from these segments, or alternatively identify the hand as "not in physical contact" with any object or select "none of the above" for occluded hands. Where Annotators cannot come to a consensus, we mark these as inconclusive. We ignore hands annotated with "none of the above" or inconclusive decisions during training and evaluation. Occasionally, in the kitchen, the hand is concealed by a glove, in cases of washing, cleaning or oven mats for hot surfaces. We thus also annotate all gloves to find cases where the glove is on the hand. We further annotate these on-hand gloves and their relations to active objects, in the same manner as visible hands. We consider both hands and on-hand gloves as acting hands for all relevant benchmarks.
+
+Exhaustive Annotations. Recall that we annotate active objects rather than all objects. Thus, one cupboard in use can be segmented while another cupboard would not be segmented. To facilitate use of our annotations in other tasks, we flag each segment indicating whether it has been exhaustively annotated [17], i.e., there are no more instances of the entity in the image. Similarly, lack of consensus is marked as inconclusive. Since the task is imbalanced towards exhaustive, we add one decoy task, that is artificially made non-exhaustive, for every four real tasks to prevent annotation fatigue.
+
+# 3.4 Dense annotations
+
+We interpolate manual sparse annotations to produce dense interpolations where feasible. Inspired by [41], we perform forward and backward multi-mask propagation between every two manually
+
+
+
+
+Figure 4: Frequency of Segmented Entity Classes. (Log y-axis) Some classes are far more frequent. Histogram is long tailed with many rare objects (e.g., 'hoover', 'cork'). Best viewed with zoom.
+
+
+Figure 5: Frame-level co-occurrences of verbs-entities (Left) and intra-entities (Middle). Percentage of annotated pixels per macro-class (Right) - large objects (e.g. furniture, storage) are visible.
+Figure 6: Hand Object Relation Statistics. (Left) Samples from 6 kinds of hand-object contacts with 1 or 2 hands. (Middle) Statistics about the fraction of entities making up the contacted objects, showing there is a long tail. (Right) Top-10 most common objects in contact with hands.
+
+annotated sparse frames. The two directions' logits are averaged with a weight on each based on the distance from the manual frame. We exclude objects that appear in only one of the two frames, except for hands which are always interpolated. Additionally, we exclude interpolations longer than 5s.
+
+This process yields 14.5M generated masks in 3.2M train/val images (compared to 5.6M masks in 683K images in [41]). We filter interpolations by starting from the middle frame, in each interpolation, and track these automatic segmentations back to the first manually-annotated frame and forward to the last frame. We compute the average $\mathcal{I}\& \mathcal{F}$ [31] VOS metric to score each reconstructed mask. We reject all interpolated masks with $\mathcal{I}\& \mathcal{F} \leq 85$ . As a result of filtering, we keep $69.4\%$ of automatic interpolations with a total of 9.9M masks, which we release as dense annotations (sample in video).
+
+# 4 Dataset Statistics and Analysis
+
+Having introduced our dataset and pipeline, we present analysis by answering four questions.
+
+What objects are segmented? Fig. 4 shows the segmented entity classes, clustered into 22 macro-classes, ordered by the macro-class frequency. Hands are common due to the egocentric perspective, and right hands are slightly more frequent than left ones. The next most frequent categories tend to be appliances, cutlery, and cookware like 'hob', 'knife', and 'pan'. However, the data has a long tail with segments for many rare objects such as 'watch' (5) and 'candle' (4).
+
+What Objects Co-Occur? Correlations in Fig. 5 show frequent co-occurrences between actions and objects (e.g., 'measure'/'spoon') and amongst objects (e.g., 'hob'/'pan'). Although our data shows many co-occurrences, there is substantial entropy too, demonstrating the dataset's diversity.
+
+Table 3: VOS Performance. We use STM [30] as a baseline and report varying training schemes. We include the scores for unseen kitchens in both Val and Test. These are considerably lower.
+
+| Pre-train COCO [23] | Fine-Tune Davis[32]+YT[43] | Fine-Tune VISOR | Val Set Performance | Test Set Performance |
| J&F | J | F | J&Funseen | J&F | J | F | J&Funseen |
| ✓ | | | 56.9 | 55.5 | 58.2 | 48.1 | 58.7 | 57.2 | 60.3 | 57.7 |
| | ✓ | 62.8 | 60.6 | 64.9 | 53.9 | 63.7 | 61.9 | 65.5 | 62.2 |
| ✓ | ✓ | | 60.9 | 59.4 | 62.4 | 55.8 | 64.5 | 62.2 | 66.7 | 63.7 |
| ✓ | | ✓ | 75.8 | 73.6 | 78.0 | 71.2 | 78.0 | 75.8 | 81.0 | 76.6 |
+
+What are hands doing? The data shows diverse hand interactions. Hands are marked as visible in $94.8\%$ of annotated images. We annotated 72.7K hand states, of which 67.2K are in contact. Of these in-contact relations, 0.9K are contacts with on-hand gloves (76% of all gloves are marked as on-hand). Fig. 6 presents hand-object relation statistics on $77\%$ of all images, for which conclusive annotations are present for both hands. The figure shows that $54\%$ of these images include both hands in some contact with the world. Some objects like knives are over-represented in hand-object relations, but because the data is unscripted, there is a heavy tail: the least-contacted $90\%$ of entities make up $24\%$ of hand-object relations.
+
+How prevalent are active objects? Although we annotate active objects, $91.1\%$ of the objects are exhaustively annotated. $4.1\%$ of the objects are inexhaustive, and $4.8\%$ had inconclusive annotations. Consistently, exhaustively annotated objects include 'chopping board' and 'spatula'. In contrast, 'sponge' and 'plate' are likely to have more inactive instances in view. Inconclusive samples occur with motion blur or objects with semantic ambiguity (e.g., 'sauce', 'pan'/'pot').
+
+# 5 Challenges and Baselines
+
+We now define three challenges that showcase our annotations and comprise the new VISOR benchmark suite. We select the three challenges so as to demonstrate the various aspects of VISOR: short-term understanding of object transformations, in-frame hand-object relations and ultra-long video understanding respectively. Our first task (§5.1) is Semi-Supervised Video Object Segmentation, or tracking multiple segments from the first frame over time through a short subsequence. Our second task, detecting Hand-Object Segmentation Relations (§5.2), segments in-contact objects or active objects along with the manipulating hand. Our final task, titled Where Did This Come From (§5.3) tracks highlighted segmentations back in time to find where they were acquired from. We report all baseline implementation details in the appendix.
+
+# 5.1 Semi-Supervised Video Object Segmentation (VOS)
+
+Definition. We follow the definition of this task from DAVIS [32]. As explained in §3.1, we divide our videos into shorter sub-sequences. Given a sub-sequence of frames with M object masks in the first frame, the goal is to segment these through the remaining frames. Other objects not present in the first frame of the sub-sequence are excluded from this benchmark. Note that any of the $M$ objects can be occluded or out of view, and can reappear during the subsequence. We include statistics of train/val/test split for this benchmark in Appendix H.1.
+
+Evaluation Metrics. Following the standard protocol used by [32, 43], we use the Jaccard Index/Intersection over Union $(\mathcal{J})$ and Boundary F-Measure $(\mathcal{F})$ metrics. Unlike other datasets, such as DAVIS [32], we use all annotated frames, including the last frame, in our evaluation. Moreover, we report the scores for unseen kitchens to assess generalisation.
+
+Baselines and Results. We use Space-Time Memory Networks (STM) [30] as a baseline on this task and follow their 2-stage training strategy. First, we train using COCO [23] images by synthesising a video of 3 images from random affine transforms. We fine-tune this model using VISOR training data, again sampling 3 images from a sub-sequence. To learn long-term appearance change, we increase the gap between sampled frames during training in a curriculum learning fashion.
+
+We report the results in Table 3. Pre-training on COCO suffers as many categories are specific to VISOR (e.g. left/right hands) or not present in COCO (e.g. potato), and due to the limitations of synthetic sequences. Training on VISOR only without pre-training gives slightly better results, but fine-tuning increases the overall score by $13\%$ on Val. We show the gap between VISOR and [32, 43] by reporting the performance of a model trained on these benchmarks. Fig. 7 shows 5 qualitative examples.
+
+Code and Models. Available from https://github.com/epic-kitchens/VISOR-VOS
+
+
+Figure 7: Qualitative Results of STM for VOS on Validation Set. 4 successes and 2 failures. Frames are ordered chronologically left-to-right with the first being the reference frame.
+
+Limitations and Challenges. Segmenting objects through transformations offers opportunities for new research. Common failures arise from: occlusions, particularly in the reference frame (Fig. 7 row 4 where the knife is initially occluded by the drying rack), tiny objects, motion blur (Fig. 7 row 5), and drastic transformations, e.g. objects being cut, broken or mixed into ingredients.
+
+# 5.2 Hand-Object Segmentation (HOS) Relations
+
+Definition. The goal of this benchmark is to estimate the relation between the hands and the objects given a single frame as input. Our first task is Hand-Contact-Relation as in [35]. We characterize each hand in terms of side (left vs right), contact (contact vs no-contact), and segment each hand and contacted object. Each contacted segment must be associated with a hand, and in the case of segments with multiple connected components (e.g., multiple onions), we only use the component in contact with the hand. Our second task is Hand-And-Active-Object, or segmenting hands and all active objects (in-contact or otherwise). In both tasks, we also consider on-hand gloves as hands.
+
+Related Datasets. Multiple past datasets have provided similar data for hands [1, 3, 27, 29] as well as hands in contact with objects [28, 34, 35]. Our work is unique in having large numbers of detailed segments for both hands and objects, distinguishing it from work that has boxes [35]. Most work with segments has focused only on hands [3] or has been gathered at the few thousand scale [14, 36].
+
+Evaluation Metrics. We evaluate via instance segmentation tasks using the COCO Mask AP [23]. Due to large differences in AP for hands and objects, we evaluate per-category. We evaluate Hand-Contact by instance segmentation with in-contact objects as a class and three schemes for hand classes: all hands as one class; hands split by side; and hands split by contact state. Hand-object association is evaluated implicitly by requiring each in-contact object to associate with a hand.
+
+Baselines and Results. For our baseline, we build on PointRend [21] instance segmentation. We add three auxiliary detection heads to detect hand side (left/right), contact state (contact/no-contact), and an offset to the contacted object (using the scheme and parameterisation from [35]). We select the in-contact object as the closest centre to the hand plus offset.
+
+We use the Training set to evaluate on Val, then use both Train and Val to report results on the Test set. Table 4 shows quantitative results, and Fig. 8 shows sample qualitative examples on Val. Hands are segmented accurately, with side easier to predict than contact state. Objects are harder,
+
+Table 4: HOS Performance. Hands are segmented accurately, but identifying contact is challenging.
+
+ | Hand | Hand-Contact | Hand-Active Object |
| Hand, Side | Hand, Contact | Object | Hand | Active Object |
| Val Mask AP | 90.9 | 87.1 | 73.5 | 30.5 | 91.1 | 24.1 |
| Test Mask AP | 95.4 | 92.4 | 78.7 | 33.7 | 95.6 | 25.7 |
+
+
+Figure 8: HOS Relations Validation Results. Contact (Top): Left Hands, Right Hands, Objects; Active Object (Bottom): Hands, Objects. Hands are well-segmented, as are many of the in-contact objects. In 'Active', the method finds all active objects regardless of whether they are in contact. The rightmost shows a failure when the object is not detected leading to wrong hand-object relation.
+
+
+
+
+
+
+
+
+
+
+
+which we attribute to the long tail of objects and occlusion. Recognising active objects is harder still, particularly from single images.
+
+Code and Models. Available from https://github.com/epic-kitchens/VISOR-HOS
+
+Limitations and Challenges. Predicting hand contact state and segmenting contacted objects is hard due to the difficulty of distinguishing hand overlap and contact, the diversity of held objects, and hand-object and hand-hand occlusion. Using multiple frames can improve performance.
+
+# 5.3 Where Did This Come From (WDTCF)? A Taster Challenge
+
+Definition. Given a frame from an untrimmed video with a mask indicating a query object, we aim to trace the mask back through time to identify 'where did this come from?', where the pronoun this refers to the indicated mask. For tractability, we use 15 sources from which objects emerge in the dataset: {fridge, freezer, cupboard, drawer, oven, dishwasher, bag, bottle, box, package, jar, can, pan, tub, cup}. To avoid trivial solutions, the answer must be spatiotemporally grounded in an evidence frame(s) when the query object emerges from the source.
+
+Annotation Statistics. Annotating long-term relations in videos is challenging. We obtain 222 WDTCF examples from 92 untrimmed videos. These form this challenge's test set. We encourage self-supervised learning for tackling this challenge. The distribution of the sources is long-tailed, where 'fridge' and 'cupboard' occupy the largest portions (37% and 31% respectively). Fig. 9 shows the 78 query objects and four samples with timestamp differences between the query and evidence frames. The gap between the query and evidence frames adds challenge. The gap is 5.4 mins (19K frames) on average, but it varies widely with a standard deviation of 8 mins (min=1s, max=52 mins).
+
+When annotating, we aim to find the furthest container as a source. For example, if 'jam' emerges from a 'jar', which is a potential source container, but the 'jar' itself is seen retrieved from a 'cupboard', the correct answer to the WDTCF question is the 'cupboard'. In another case, where the 'jar' is only seen on the counter throughout the video, then the 'jar' would be considered as the correct source.
+
+Related Datasets. This challenge is related to VQA tasks in previous datasets [9, 15, 26]. In [15], the aim is to find the previous encounter of the object itself and [9] aims to ground the object in a single image. In both, the query object is visible in the evidence image, unlike in our challenge where the query object is occluded and being manipulated. We are also looking for its source, where it was before it is first encountered, rather than when/where it was spotted last.
+
+Evaluation Metrics. We evaluate by classifying the correct source (accuracy), locating the evidence frame and segmenting the source and query objects in the evidence frame (IoU). If the evidence frame is incorrect, the IoU is 0.
+
+Annotations and code. Available from https://github.com/epic-kitchens/VISOR-WDTCF
+
+Baselines and Results. No prior method has tackled this challenge, so we test baselines using different levels of oracle knowledge. As shown in Table 5, guessing from the source distribution
+
+
+Figure 9: WDTCF Annotations. Distributions and examples of query entities and 4 samples.
+
+
+
+
+
+
+
+Table 5: WDTCF Performance. Performance using oracle knowledge of distribution of source classes (prior), location of (evidence) frame, (query class) and a model trained with (GT Masks).
+
+| Method | Prior | Evidence | Query CIs | GT Masks | Source | Query IoU | Source IoU |
| Random | ✓ | | | | 24.8 | - | - |
| PointRend [21] | ✓ | | ✓ | ✓ | 28.8 | 30.3 | 25.4 |
| ✓ | | ✓ | 33.8 | 31.6 | 29.7 |
| ✓ | | ✓ | 88.3 | 79.4 | 78.8 |
| ✓ | ✓ | | ✓ | 94.1 | 79.4 | 84.1 |
+
+gets $24.8\%$ accuracy; while guessing the most frequent source ('fridge') achieves $37\%$ accuracy but cannot localise the evidence frame and segment. We thus trained a PointRend instance segmentation model on the all VISOR classes using our Train and Val data to detect objects. Given the query mask, we predict its class using the mask with the highest IoU, then propose the first three frames containing both the object and a source as candidates. The relative performance suggests that the hardest task is temporally localising the evidence frame; when this is given, performance is significantly boosted.
+
+Limitations and Challenges. Since objects often originate from the same source container, e.g., milk comes from the fridge, bias is expected. While we have introduced the evidence frame grounding task, shortcuts via the presence of source classes can still be used. As noted above, the baselines use oracle knowledge; an AI system to answer WDTCF is left for future work.
+
+# 6 Conclusion and Next Steps
+
+We introduced VISOR, a new dataset built on EPIC-KITCHENS-100 videos, with rich pixel-level annotations across space and time. Through the release of these annotations and the proposed benchmarks, we hope VISOR enables the community to investigate new problems in long-term understanding of the interplay between actions and object transformations.
+
+# Acknowledgments and Disclosure of Funding
+
+We gratefully acknowledge valuable support from: Michael Wray for revising the EPIC-KITCHENS-100 classes; Seung Wook Kim and Marko Boben for technical support to TORAS; Srdjan Delic for quality checks particularly on the Test set; several members of the MaVi group at Bristol for quality checking: Toby Perrett, Michael Wray, Dena Bazazian, Adriano Fragomeni, Kevin Flanagan, Daniel Whettam, Alexandros Stergiou, Jacob Chalk, Chiara Plizzari and Zhifan Zhu.
+
+Annotations were funded by a charitable unrestricted donations to the University of Bristol from Procter and Gamble and DeepMind.
+
+Research at the University of Bristol is supported by UKRI Engineering and Physical Sciences Research Council (EPSRC) Doctoral Training Program (DTP), EPSRC Fellowship UMPIRE (EP/T004991/1) and EPSRC Program Grant Visual AI (EP/T028572/1). We acknowledge the use of the ESPRC funded Tier 2 facility, JADE, and the University of Bristol's Blue Crystal 4 facility. Research at the University of Michigan is based upon work supported by the National Science Foundation under Grant No. 2006619.
+
+Research at the University of Toronto is in part sponsored by NSERC. S.F. also acknowledges support through the Canada CIFAR AI Chair program.
+
+# References
+
+[1] The vision for intelligent vehicles and applications (VIVA) challenge, laboratory for intelligent and safe automobiles, UCSD. http://cvrr.ucsd.edu/vivachallenge/. 8
+[2] David Acuna, Huan Ling, Amlan Kar, and Sanja Fidler. Efficient interactive annotation of segmentation datasets with polygon-RNN++. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2018. 4
+[3] Sven Bambach, Stefan Lee, David Crandall, and Chen Yu. Lending a hand: Detecting hands and recognizing activities in complex egocentric interactions. In Proceedings of the IEEE International Conference on Computer Vision, 2015. 3, 8
+[4] Fabien Baradel, Natalia Neverova, Christian Wolf, Julien Mille, and Greg Mori. Object level visual reasoning in videos. In European Conference on Computer Vision (ECCV), 2018. 3
+[5] Rodrigo Benenson, Stefan Popov, and Vittorio Ferrari. Large-scale interactive object segmentation with human annotators. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2019. 24
+[6] Sergi Caelles, Jordi Pont-Tuset, Federico Perazzi, Alberto Montes, Kevis-Kokitsi Maninis, and Luc Van Gool. The 2019 DAVIS challenge on VOS: Unsupervised multi-object segmentation. arXiv:1905.00737, 2019. 3
+[7] Joao Carreira and Andrew Zisserman. Quo vadis, action recognition? a new model and the kinetics dataset. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2017. 2, 3
+[8] Lluis Castrejon, Kaustav Kundu, Raquel Urtasun, and Sanja Fidler. Annotating object instances with a polygon-RNN. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2017. 4
+[9] Chongyan Chen, Samreen Anjum, and Danna Gurari. Grounding answers for visual questions asked by visually impaired people. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2022. 9
+[10] Marius Cordts, Mohamed Omran, Sebastian Ramos, Timo Rehfeld, Markus Enzweiler, Rodrigo Benenson, Uwe Franke, Stefan Roth, and Bernt Schiele. The Cityscapes Dataset for Semantic Urban Scene Understanding. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2016. 1
+[11] Dima Damen, Hazel Doughty, Giovanni Maria Farinella, , Antonino Furnari, Jian Ma, Evangelos Kazakos, Davide Moltisanti, Jonathan Munro, Toby Perrett, Will Price, and Michael Wray. Rescaling egocentric vision. International Journal of Computer Vision (IJCV), 2022. 2, 3, 17
+[12] Dima Damen, Hazel Doughty, Giovanni Maria Farinella, Sanja Fidler, Antonino Furnari, Evangelos Kazakos, Davide Moltisanti, Jonathan Munro, Toby Perrett, Will Price, and Michael Wray. Scaling egocentric vision: The EPIC-KITCHENS Dataset. In Proceedings of the European Conference on Computer Vision, 2018. 1
+[13] Andreas Geiger, Philip Lenz, and Raquel Urtasun. Are we ready for autonomous driving? the Kitti vision benchmark suite. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition. IEEE, 2012. 1
+[14] Mohit Goyal, Sahil Modi, Rishabh Goyal, and Saurabh Gupta. Human hands as probes for interactive object understanding. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 3293-3303, 2022. 8
+[15] Kristen Grauman, Andrew Westbury, Eugene Byrne, Zachary Chavis, Antonio Furnari, Rohit Girdhar, Jackson Hamburger, Hao Jiang, Miao Liu, Xingyu Liu, Miguel Martin, Tushar Nagarajan, Ilija Radosavovic, Santhosh Kumar Ramakrishnan, Fiona Ryan, Jayant Sharma, Michael Wray, Mengmeng Xu, Eric Zhong-cong Xu, Chen Zhao, Siddhant Bansal, Dhruv Batra, Vincent Cartillier, Sean Crane, Tien Do, Morrie Doulaty, Akshay Erapalli, Christoph Feichtenhofer, Adriano Fragomeni, Qichen Fu, Christian Fuegen, Abraham Gebreselasie, Cristina Gonzalez, James Hillis, Xuhua Huang, Yifei Huang, Wenqi Jia, Weslie Khoo, Jachym Kolar, Satwik Kottur, Anurag Kumar, Federico Landini, Chao Li, Yanghao Li, Zhenqiang Li, Karttikeya Mangalam, Raghava Modhugu, Jonathan Munro, Tullie Murrell, Takumi Nishiyasu, Will Price, Paola Ruiz Puentes, Merey Ramazanova, Leda Sari, Kiran Somasundaram, Audrey Southerland, Yusuke Sugano, Ruijie Tao, Minh Vo, Yuchen Wang, Xindi Wu, Takuma Yagi, Yunyi Zhu, Pablo Arbelaez, David Crandall, Dima Damen, Giovanni Maria Farinella, Bernard Ghanem, Vamsi Krishna Ithapu, C. V. Jawahar, Hanbyul Joo, Kris Kitani, Haizhou Li, Richard Newcombe, Aude Oliva, Hyun Soo Park, James M. Rehg, Yoichi Sato, Jianbo Shi, Mike Zheng Shou, Antonio Torralba, Lorenzo Torresani, Mingfei Yan, and Jitendra Malik. Ego4D: Around the World in 3,000 Hours of Egocentric Video. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2022. 1, 9
+[16] Chunhui Gu, Chen Sun, David A Ross, Carl Vondrick, Caroline Pantofaru, Yeqing Li, Sudheendra Vijayanarasimhan, George Toderici, Susanna Ricco, Rahul Sukthankar, et al. AVA: A video dataset of spatio-temporally localized atomic visual actions. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2018. 1, 3
+[17] Agrim Gupta, Piotr Dollar, and Ross Girshick. LVIS: A dataset for large vocabulary instance segmentation. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2019. 1, 5
+
+[18] Yana Hasson, Gül Varol, Dimitrios Tzionas, Igor Kalevatykh, Michael J. Black, Ivan Laptev, and Cordelia Schmid. Learning joint reconstruction of hands and manipulated objects. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2019. 3
+[19] Jingwei Ji, Ranjay Krishna, Li Fei-Fei, and Juan Carlos Niebles. Action Genome: Actions as compositions of spatio-temporal scene graphs. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2020. 1
+[20] Amlan Kar, Seung Wook Kim, Marko Boben, Jun Gao, Tianxing Li, Huan Ling, Zian Wang, and Sanja Fidler. Toronto annotation suite. https://aidemos.cs.toronto.edu/toras, 2021. 4, 23
+[21] Alexander Kirillov, Yuxin Wu, Kaiming He, and Ross Girshick. Pointrend: Image segmentation as rendering. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2020. 8, 10, 38
+[22] Ang Li, Meghana Thotakuri, David A Ross, Joao Carreira, Alexander Vostrikov, and Andrew Zisserman. The AVA-Kinetics localized human actions video dataset. arXiv preprint arXiv:2005.00214, 2020. 1
+[23] Tsung-Yi Lin, Michael Maire, Serge Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dólar, and C Lawrence Zitnick. Microsoft COCO: Common objects in context. In Proceedings of the European Conference on Computer Vision. Springer, 2014. 1, 7, 8, 38
+[24] Huan Ling, Jun Gao, Amlan Kar, Wenzheng Chen, and Sanja Fidler. Fast interactive object annotation with curve-gcn. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2019. 4, 23
+[25] Shaowei Liu, Subarna Tripathi, Somdeb Majumdar, and Xiaolong Wang. Joint hand motion and interaction hotspots prediction from egocentric videos. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), 2022. 3
+[26] Jean-Philippe Mercier, Mathieu Garon, Philippe Giguere, and Jean-Francois Lalonge. Deep template-based object instance detection. In Proceedings of the IEEE Winter Conference on Applications of Computer Vision, January 2021. 9
+[27] A. Mittal, A. Zisserman, and P. H. S. Torr. Hand detection using multiple proposals. In British Machine Vision Conference, 2011. 8
+[28] Supreeth Narasimhaswamy, Trung Nguyen, and Minh Hoai. Detecting hands and recognizing physical contact in the wild. In Neural Information Processing Systems, 2020. 8
+[29] Supreeth Narasimhaswamy, Zhengwei Wei, Yang Wang, Justin Zhang, and Minh Hoai. Contextual attention for hand detection in the wild. In Proceedings of the IEEE International Conference on Computer Vision, 2019. 8
+[30] Seoung Wug Oh, Joon-Young Lee, Ning Xu, and Seon Joo Kim. Video object segmentation using spacetime memory networks. In Proceedings of the IEEE International Conference on Computer Vision, October 2019. 7
+[31] F. Peruzzi, J. Pont-Tuset, B. McWilliams, L. Van Gool, M. Gross, and A. Sorkine-Hornung. A benchmark dataset and evaluation methodology for video object segmentation. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2016. 1, 2, 6
+[32] Jordi Pont-Tuset, Federico Perazzi, Sergi Caelles, Pablo Arbeláez, Alex Sorkine-Hornung, and Luc Van Gool. The 2017 DAVIS challenge on video object segmentation. arXiv preprint arXiv:1704.00675, 2017. 7, 35
+[33] Francesco Ragusa, Antonino Furnari, and Giovanni Maria Farinella. Meccano: A multimodal egocentric dataset for humans behavior understanding in the industrial-like domain. arXiv preprint arXiv:2209.08691, 2022. 3
+[34] Francesco Ragusa, Antonino Furnari, Salvatore Livatino, and Giovanni Maria Farinella. The Meccano dataset: Understanding human-object interactions from egocentric videos in an industrial-like domain. In Proceedings of the IEEE Winter Conference on Applications of Computer Vision, 2021. 8
+[35] Dandan Shan, Jiaqi Geng, Michelle Shu, and David F Fouhey. Understanding human hands in contact at internet scale. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2020. 3, 8
+[36] Dandan Shan, Richard E.L. Higgins, and David F. Fouhey. COHESIV: Contrastive object and hand embedding segmentation in video. In Neural Information Processing Systems, 2021. 8
+[37] Gunnar A Sigurdsson, Gúl Varol, Xiaolong Wang, Ali Farhadi, Ivan Laptev, and Abhinav Gupta. Hollywood in homes: Crowdsourcing data collection for activity understanding. In Proceedings of the European Conference on Computer Vision. Springer, 2016. 3
+[38] Omid Taheri, Vasileios Choutas, Michael J. Black, and Dimitrios Tzionas. Goal: Generating 4d whole-body motion for hand-object grasping. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), 2022. 3
+[39] Omid Taheri, Nima Ghorbani, Michael J. Black, and Dimitrios Tzionas. Grab: A dataset of whole-body human grasping of objects. In Andrea Vedaldi, Horst Bischof, Thomas Brox, and Jan-Michael Frahm, editors, European Conference on Computer Vision (ECCV), 2020. 3
+
+[40] Dylan Turpin, Liquan Wang, Eric Heiden, Yun-Chun Chen, Miles Macklin, Stavros Tsogkas, Sven Dickinson, and Animesh Garg. Grasp'd: Differentiable contact-rich grasp synthesis for multi-fingered hands. In European Conference on Computer Vision (ECCV), 2022. 3
+[41] Weiyao Wang, Matt Feiszli, Heng Wang, and Du Tran. Unidentified video objects: A benchmark for dense, open-world segmentation. In Proceedings of the IEEE International Conference on Computer Vision, 2021. 1, 2, 3, 5, 6
+[42] Zian Wang, David Acuna, Huan Ling, Amlan Kar, and Sanja Fidler. Object instance annotation with deep extreme level set evolution. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2019. 4, 23
+[43] Ning Xu, Linjie Yang, Yuchen Fan, Dingcheng Yue, Yuchen Liang, Jianchao Yang, and Thomas Huang. Youtube-VOS: A large-scale video object segmentation benchmark. arXiv preprint arXiv:1809.03327, 2018. 1, 2, 3, 7
+[44] Xiang Xu, Hanbyul Joo, Greg Mori, and Manolis Savva. D3d-hoi: Dynamic 3d human-object interactions from videos. arXiv preprint arXiv:2108.08420, 2021. 3
+[45] Bolei Zhou, Hang Zhao, Xavier Puig, Sanja Fidler, Adela Barriuso, and Antonio Torralba. Scene parsing through ADE20k dataset. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2017. 4
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes] This paper introduces a dataset, with annotation pipeline and challenges. Throughout the paper and appendix, we thoroughly describe our annotation pipeline, summarise the statistics, compare to other datasets. For each benchmark, we clearly define the benchmark, metrics and report baseline and qualitative results.
+(b) Did you describe the limitations of your work? [Yes] We discuss limitations of our challenges in §5.1, §5.2, §5.3
+(c) Did you discuss any potential negative societal impacts of your work? [Yes] We mention this in §3. We also devote a section in appendix to potential bias in the data and resulting models
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A] There are no theoretical results.
+(b) Did you include complete proofs of all theoretical results? [N/A] There are no theoretical results.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the appendix material or as a URL)? [Yes] Train/Val annotations are publicly available from: https://epic-kitchens.github.io/VISOR. Code for reproducing the first two challenges is published on GitHub. Test set annotations, including those for the third challenge will remain hidden. A leaderboard available from: https://epic-kitchens.github.io.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] Dataset split (Train/Val/Test) is summarised in Sec 2.2, and specifically for semi-supervised VOS in Appendix. Training details per challenge are detailed in the appendix.
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [No] The experiments run are too computationally costly to do multiple runs of the experiments. Our results form baselines that we expect more intelligent methods to beat. Code allows replication of baselines where needed.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] We include an analysis of resources used in the appendix.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] We build on the EPIC-KITCHENS-100 dataset, which we extensively cite throughout the paper. We also cite models we use to bulid baselines.
+(b) Did you mention the license of the assets? [Yes] VISOR dataset is available under the same licenses as EPIC-KITCHENS
+(c) Did you include any new assets either in the appendix material or as a URL? [Yes] We introduce new assets in the form of annotations. We share these privately with reviewers and will share publicly in August.
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [Yes] We mention the dataset, EPIC-KITCHENS-100, that was used. This dataset was collected with ethics approval and with consent from the people who are in the data.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [Yes] The EPIC-KITCHENS videos do not contain any personally identifiable information. It was collected from participants who reviewed the footage prior to publication.
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [Yes] Please see the appendix material for detailed descriptions of all instructions for annotators.
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A] There are no human studies done in this paper. However, the dataset that we build upon, EPIC-KITCHENS-100 was collected with IRB approval, as described in §3.
+ (c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [Yes] Freelance annotators were paid hourly, and self-reported their hours via the Upwork platform. Hourly rate varied by experience and submitted proposal from $6-$9/hour, with the higher rate reserved for most experienced annotators who were also in charge of QA checks. We report compensation in the appendix.
\ No newline at end of file
diff --git a/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/images.zip b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..46c826fd254d3494b3c803cd671ec68e250b1862
--- /dev/null
+++ b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:be70087b6c0ea933829be484f3252e75248f0d733369caa163fe9e29aff3be0f
+size 1061374
diff --git a/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/layout.json b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..2d16ae8fe4d4e54f17976ba675172642ad6d3073
--- /dev/null
+++ b/epickitchensvisorbenchmarkvideosegmentationsandobjectrelations/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b7d9b6c49f88aef89809d3b1f0a35e82ccd29a85c3f8a5a2f49fd03f519da047
+size 337734
diff --git a/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/f77868cc-436f-4fc2-a9f5-5a6048fd5c14_content_list.json b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/f77868cc-436f-4fc2-a9f5-5a6048fd5c14_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..74729e28d19c1d58dd3a83ae95729218d0b0669a
--- /dev/null
+++ b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/f77868cc-436f-4fc2-a9f5-5a6048fd5c14_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:756164c9d5402a4b40d3b2b2ce11f4ec4f22a307963f86680730f08c76bd60aa
+size 91855
diff --git a/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/f77868cc-436f-4fc2-a9f5-5a6048fd5c14_model.json b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/f77868cc-436f-4fc2-a9f5-5a6048fd5c14_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..ba3ec2261fea066518982b6c0f35a0dde27da5b2
--- /dev/null
+++ b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/f77868cc-436f-4fc2-a9f5-5a6048fd5c14_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:df6ab444897435ae8fdbd92fe3c85f1703bea3798dac486b12fc7b8bdbac3c29
+size 117065
diff --git a/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/f77868cc-436f-4fc2-a9f5-5a6048fd5c14_origin.pdf b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/f77868cc-436f-4fc2-a9f5-5a6048fd5c14_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..b9945e5efe876e59c73cc10a2407064ec8792446
--- /dev/null
+++ b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/f77868cc-436f-4fc2-a9f5-5a6048fd5c14_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:372cbf27367050248202f9d8accfcd4f2b0ec12b5ab605e139fc95ea245ee4c8
+size 4125212
diff --git a/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/full.md b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..cbda946acca4e58e93125f5db71e7e5a87c3c46e
--- /dev/null
+++ b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/full.md
@@ -0,0 +1,386 @@
+# ESCADA: Efficient Safety and Context Aware Dose Allocation for Precision Medicine
+
+Ilker Demirel*
+
+Bilkent University
+
+ilkerd@ee.bilkent.edu.tr
+
+A. Alparslan Celik
+
+Bilkent University
+
+acelik@ee.bilkent.edu.tr
+
+Cem Tekin
+
+Bilkent University
+
+cemtekin@ee.bilkent.edu.tr
+
+# Abstract
+
+Finding an optimal individualized treatment regimen is considered one of the most challenging precision medicine problems. Various patient characteristics influence the response to the treatment, and hence, there is no one-size-fits-all regimen. Moreover, the administration of an unsafe dose during the treatment can have adverse effects on health. Therefore, a treatment model must ensure patient safety while efficiently optimizing the course of therapy. We study a prevalent medical problem where the treatment aims to keep a physiological variable in a safe range and preferably close to a target level, which we refer to as leveling. Such a task may be relevant in numerous other domains as well. We propose ESCADA, a novel and generic multi-armed bandit (MAB) algorithm tailored for the leveling task, to make safe, personalized, and context-aware dose recommendations. We derive high probability upper bounds on its cumulative regret and safety guarantees. Following ESCADA's design, we also describe its Thompson sampling-based counterpart. We discuss why the straightforward adaptations of the classical MAB algorithms such as GP-UCB may not be a good fit for the leveling task. Finally, we make in silico experiments on the bolus-insulin dose allocation problem in type-1 diabetes mellitus disease and compare our algorithms against the famous GP-UCB algorithm, the rule-based dose calculators, and a clinician.
+
+# 1 Introduction
+
+Precision medicine aims to provide the best possible treatment on an individual level by considering patient characteristics' variability [3, 30]. Many healthcare problems require keeping a physiological variable (e.g., blood glucose level) in a safe range and preferably close to a target level. One such example is electrolyte disorders, common among intensive care unit patients. When the blood sodium level falls below 135 milliequivalents per liter $(\mathrm{mEq} / \mathrm{L})$ or goes beyond $145~\mathrm{mEq / L}$ , the patient experiences hypo-/hyper-natremia with adverse effects on health [24]. Therefore, correct dosing of electrolytes is crucial to ensure patient safety, and there is no consensus on how to assess the correct dosage for different patient characteristics. Another critical problem is blood pressure disorder. These are hypo-/hyper-tension events where the blood pressure deviates from its standard value and needs to be corrected. Patient characteristics play an essential role in determining the blood pressure response to the therapeutic agent, and they should be taken into account in the dosing process [33].
+
+Related work and background A fair amount of research is dedicated to adaptive clinical trials which aim to identify a drug's effectiveness within a group, including a tradeoff between efficacy and
+
+toxicity [26, 27, 40, 53]. The algorithms proposed in these works are not applicable to the problem structure considered here for two main reasons. First, the therapeutic agent is not necessarily toxic, and our aim is not to maximize the response to the agent but to keep it close to a target level. Therefore, classical upper confidence bound (UCB) based algorithms such as UCB1 [4] or GP-UCB [41] are not applicable for our objective. That is simply because the UCB-based algorithms leverage the optimism in the face of uncertainty (OFU) principle to form optimistic estimates of arm outcomes and pick the arm with the highest estimated outcome. However, in our case, optimism refers to the proximity of an arm's outcome to the target. This fundamental difference in our task necessitates a novel acquisition strategy. One could simply form pseudo-rewards to maximize, such as $r(n) = -|o(n) - K|$ , where $o(n)$ is the outcome at the end of round $n$ and $K$ is the target level. We particularly refrain from doing so as different reasonable choices for the pseudo-reward will lead the algorithm to operate differently in practice. Therefore, we keep the objective (i.e., minimize $|o(n) - K|$ ) in the most generic form and propose a suitable acquisition strategy instead. We provide more details on our objective and motivation behind designing a new acquisition strategy in §2. Secondly, our goal is to provide personalized recommendations rather than for a group of patients. We approach the safe dose allocation problem from a contextual multi-armed bandit (MAB) [29] perspective with additional safety constraints and propose a novel acquisition function tailored for this problem structure in §3.
+
+To render our acquisition method safe, we propose a safe exploration strategy. There is a surge of interest in safe exploration for Bayesian optimization (BO), Markov decision processes, MABs, and reinforcement learning in general. [15, 17, 31, 54]. [1] propose the linear Thompson sampling (LTS) algorithm for the linear stochastic bandit (LSB) setting by adding a random perturbation to the regularized least-squares estimates of the parameters in a way that the OFU principle can be used. [32] modifies the LTS' randomization procedure to continue leveraging the OFU principle in the face of additional safety constraints and matches LTS' order of regret. [21] proposes a safe algorithm incurring a near-optimal expected regret for the LSB problem as well, which uses the arm outcomes' lower confidence bounds to guarantee the safety of exploration and greedily exploit when it is safe.
+
+There is a strand of literature on "risk-averse" MABs, where the learner is concerned not only with maximizing long-term earnings but also with reducing a certain measure of risk [9, 37]. [37, 49, 50] investigate the MAB problem using two risk measures, Mean-Variance and Value-at-Risk, which are widely adopted in financial portfolio management [42]. [8, 14, 20] study the Conditional-Value-at-Risk measure, which captures the tail-risk better compared to the Value-at-Risk measure. Another related area is the "conservative" bandits, where the learner's cumulative reward must always exceed a predetermined fraction of a baseline's [19, 56]. These works, however, do not address stagewise safety constraints on instantaneous arm outcomes, which must be explicitly satisfied at any given time.
+
+We operate in a BO framework where we model the objective function as a sample from a Gaussian process (GP). [15, 17] consider BO with stagewise safety constraints. However, they aim to find optimal safe solutions and allow unsafe evaluations during exploration. [2] propose a safe variant of GP-UCB, which employs a pure exploration phase at the beginning and provides upper bounds on its cumulative regret. SafeOPT and StageOPT algorithms provide guarantees on the safety of the exploration process [44, 45]. However, they model the exploration of the safe set as a proxy objective which leads to unnecessary suboptimal evaluations at the boundaries of the safe set [48]. Moreover, they do not provide formal regret bounds. Goal-oriented Safe Expansion (GoOSE) algorithm works with any acquisition function as a plug-in safety mechanism and encourages the expansion of the safe set only when necessary [48]. When the query is not guaranteed to be safe, only then GoOSE expands the safe set by evaluating the function at safe points to learn more about the initial query's safety. However, such re-evaluations are not possible within the framework of dynamic treatment regimes since this setup does not allow the administration of multiple doses. Moreover, all the works above consider a one-sided safety constraint $(f(x)\geq c)$ , whereas we consider a two-sided one as the aim is to keep $f(x)$ in a range $(c_{1}\leq f(x)\leq c_{2})$ . We provide a table comparing our work to some existing literature on safe exploration with GPs in Appendix A. Our key contributions are as follows.
+
+We study an important and overlooked problem in medicine that which is relevant in other domains as well, such as demand-side management [7]. We formalize the problem from a contextual MAB perspective via a suitable definition of regret as the proxy performance metric in §2. Since our objective is to keep the outcomes close to a target rather than maximize them as in the usual MAB setting, we propose a novel acquisition method in §3. We design a safe exploration scheme for our acquisition function in §3 and derive high probability upper bounds on its regret with safety guarantees in §4. We make in silico experiments on type-1 diabetes mellitus (T1DM) disease in
+
+§5. T1DM is characterized by insulin deficiency due to pancreatic $\beta$ -cell loss, and it can have adverse effects which might result in hospitalization and death [6]. Therefore, T1DM patients must regulate their blood glucose by administering bolus insulin doses before meals. We optimize the dose recommendation process via safely and efficiently learning to recommend better doses.
+
+# 2 Problem statement
+
+We denote by $[N]$ the set $\{1, \ldots, N\}$ , $z \in \mathcal{Z}$ a context, and $d \in \mathcal{D}$ a dose, where both $\mathcal{Z}$ and $\mathcal{D}$ are compact and convex, and $\mathcal{D} = [0, \overline{D}]$ . Let $f: \mathcal{Z} \times \mathcal{D} \to \Omega$ be the unknown function that maps $(z, d)$ pairs to the physiological variable of interest, where $\Omega = [0, \overline{T}]$ . At round $n \in [N]$ , the learner observes a context, $z_{n}$ , and recommends a dose, $d_{n}$ , to obtain a noisy evaluation of $f$ at $(z_{n}, d_{n})$ , given as $y_{n} = f(z_{n}, d_{n}) + \nu_{n}$ , where $\nu_{n}$ are zero-mean i.i.d. Gaussian with known variance $\sigma^2$ . The learner's objective is to keep the physiological variable, $f(z_{n}, d_{n})$ , within a safe range and close to the target level. We formalize this objective as a contextual MAB problem with safety constraints as,
+
+$$
+\text {m i n i m i z e} R _ {N} = \sum_ {n = 1} ^ {N} | f \left(\boldsymbol {z} _ {n}, d _ {n}\right) - T | \tag {1}
+$$
+
+$$
+\text {s u b j e c t} T _ {\min } \leq f \left(\boldsymbol {z} _ {n}, d _ {n}\right) \leq T _ {\max }, \quad \forall n \in [ N ], \tag {2}
+$$
+
+where $T_{\min}$ and $T_{\max}$ denote the lower and upper safety thresholds for $f$ , respectively, and $T \in (T_{\min} + \alpha, T_{\max} - \alpha)$ is the target value, where $\alpha > 0$ . We introduce the non-zero $\alpha$ term to ensure that the target level is not exactly equal to the safety thresholds, which is required later in the analyses. We assume $\forall z \in \mathcal{Z}$ , there exists $d_z^* \in \mathcal{D}$ such that $f(z, d_z^*) = T$ .
+
+
+Figure 1: A hypothetical objective function $f(x)$ , and three candidate reward functions.
+
+Regularity assumptions Our safe exploration strategy relies on expanding around an initial safe set by exploiting the smoothness properties of the objective function $f(x)$ . Without an initial safe set, and some regularity assumptions on $f(x)$ , it is not possible to make inferences on the safety of the prospective recommendations [44]. Let $\mathcal{X} = \mathcal{Z} \times \mathcal{D}$ denote the space of all context-dose pairs. Let $k(\cdot, \cdot)$ be a positive definite kernel function on $\mathcal{X}$ . We assume that $f(x)$ is a function from the Reproducing Kernel Hilbert Space (RKHS) corresponding to $k(\cdot, \cdot)$ . In addition, we assume that $f(x)$ has bounded norm in this particular RKHS, i.e., $\| f \|_k < B_f$ [39]. This mild assumption makes $f(x)$ smooth enough to be efficiently learnable by a GP. More precisely, $f(x)$ is $L$ -Lipschitz continuous w.r.t. kernel
+
+metric $q(\pmb{x}, \pmb{x}^{\prime}) = \sqrt{k(\pmb{x}, \pmb{x}) - 2k(\pmb{x}, \pmb{x}^{\prime}) + k(\pmb{x}^{\prime}, \pmb{x}^{\prime})}$ , where $L = B_{f}$ [43]. Also, we denote by $q_{\pmb{z}}(d,d') := q((\pmb{z}, d), (\pmb{z}, d'))$ . At this point, we define a discretization of $\mathcal{D}$ for every $\pmb{z} \in \mathcal{Z}$ as,
+
+$$
+\overline {{\mathcal {D}}} _ {z} := \left\{d _ {i} (z) \in \mathcal {D} \mid i \in \{1, \dots , k \} \right\},
+$$
+
+where $d_{1}(z) = 0$ , $d_{i}(z) > d_{j}(z)$ for $i > j$ , $q_{z}(d_{i},d_{i + 1}) = \lambda /2L$ , $q_{z}(d_{k},\overline{D}) < \lambda /2L$ , and $\lambda >0$ is the discretization parameter. We assume that an initial safe set of discretized doses $S_0(z)$ is available for each $z\in \mathcal{Z}$ . These assumptions allow us to use Gaussian processes (GP) to design our algorithm, and analyze its regret and safety guarantees [36]. A GP is a distribution over functions which is characterized by its mean, $\mu (\cdot)$ , and covariance, $k(\cdot ,\cdot)$ , functions. Once we assume a GP prior over $f(x)$ , after observing a set of noisy evaluations $\pmb {y}_N = [y_1\dots y_N]^T$ at $A_{N} = \{\pmb{x}_{1},\dots,\pmb{x}_{N}\}$ , the posterior over $f(x)$ is a GP again with the following mean and covariance functions,
+
+$$
+k _ {N} (\boldsymbol {x}, \boldsymbol {x} ^ {\prime}) = k (\boldsymbol {x}, \boldsymbol {x} ^ {\prime}) - \boldsymbol {k} _ {N} (\boldsymbol {x}) ^ {T} \left(\boldsymbol {K} _ {N} + \sigma^ {2} \boldsymbol {I}\right) ^ {- 1} \boldsymbol {k} _ {N} (\boldsymbol {x} ^ {\prime})
+$$
+
+$$
+\sigma_ {N} ^ {2} (\boldsymbol {x}) = k _ {N} (\boldsymbol {x}, \boldsymbol {x})
+$$
+
+$$
+\mu_ {N} (\boldsymbol {x}) = \boldsymbol {k} _ {N} (\boldsymbol {x}) ^ {T} \left(\boldsymbol {K} _ {N} + \sigma^ {2} \boldsymbol {I}\right) ^ {- 1} \boldsymbol {y} _ {N},
+$$
+
+where $\pmb{k}_N(\pmb{x}) = [k(\pmb{x}_1,\pmb{x}),\dots,k(\pmb{x}_N,\pmb{x})]^T$ and $\pmb{K}_{N}$ is the positive definite kernel matrix $[k(\pmb{x},\pmb{x}^{\prime})]_{\pmb{x},\pmb{x}^{\prime}\in A_{N}}$ .
+
+Comparison with GP-UCB Our objective is to keep $f(x)$ close to a target level $T$ . As we discussed in §1, one could use the GP-UCB algorithm in [41] if the objective was to maximize $f(x)$ . In our case, however, we have to define pseudo-rewards to maximize such as $-|f(z_n, d_n) - T|$ that are decreasing
+
+
+Figure 2: ESCADA Algorithm Description (left). Upon observing a context $\mathbf{z}_n$ in round $n$ , TACO forms the set $\mathcal{C}_n(\mathbf{z}_n) \subseteq S_n(\mathbf{z}_n)$ after eliminating the doses that are suboptimal with high probability (TACO uses $\mathcal{D}_n = S_n(\mathbf{z}_n)$ in Algorithm 1 to ensure safety with high probability). If $\mathcal{C}_n(\mathbf{z}_n) \neq \emptyset$ , it recommends the dose whose mean response is closest to the target $T$ . If $\mathcal{C}_n(\mathbf{z}_n) = \emptyset$ , it recommends the dose with the widest confidence interval in $S_n(\mathbf{z}_n) \cap \overline{\mathcal{D}}_{\mathbf{z}_n}$ . Flowchart (right). A simple interpretation of the dose allocation process intended for domain experts.
+
+with $|f(z_{n},d_{n}) - T|$ to capture the "leveling" task in (1). We present three such reward functions in Figure 1. However, $f(x)$ being smooth and efficiently learnable by a GP does not imply that a reward functional defined on $f(x)$ will be as well. Figure 1 shows that different reward functions can have significantly different landscapes. For instance, it is almost impossible to achieve our task efficiently by using the so-called "plausible" Reward 1. In §5, we compare our algorithms' performances against the GP-UCB's for three reward functions in Figure 1. Also, when $T \neq (T_{\min} + T_{\max}) / 2$ (which may well be the case, see §5), the reward-based GP-UCB method needs another GP to directly learn $f(x)$ to efficiently satisfy the safety requirements, doubling the computational complexity compared to our algorithms which use a single GP for everything. Finally, by learning $f(x)$ with a GP, we can provide interpretations for our model's recommendations (see Figure 2).
+
+# 3 ESCADA algorithm
+
+We propose ESCADA: Efficient Safety and Context Aware Dose Allocation algorithm. It consists of two blocks: (i) an acquisition function, which we call TACO: TTarget-based COnfident-acquisition, (ii) a safety mechanism to render TACO safe. Algorithm 1 and Figure 2 summarize ESCADA's design. ESCADA's recommendation procedure can be interpreted to domain experts via the flowchart in Figure 2 as opposed to black-box models [58].2
+
+Acquisition strategy We propose TACO, a novel acquisition method specifically tailored for the "leveling" task described in §2. At each round $n$ , TACO uses the confidence bounds of doses $d \in \mathcal{D}$ for $z_{n}$ derived from the GP prior as $l_{n}(z_{n},d) = \mu_{n - 1}(z_{n},d) - \beta_{n}^{1 / 2}\sigma_{n - 1}(z_{n},d)$ , and $u_{n}(z_{n},d) = \mu_{n - 1}(z_{n},d) + \beta_{n}^{1 / 2}\sigma_{n - 1}(z_{n},d)$ . We define $\beta_{n}$ later in a way that the confidence intervals contain the true value of $f$ with high probability (see Lemma 1). Then, using Lipschitz continuity of $f$ , we form the final lower and upper confidence bounds for every $d \in \mathcal{D}$ as,
+
+# Algorithm 1 ESCADA algorithm
+
+for $n = 1,2,\ldots$ do
+
+Observe $z_{n}$ and form $C_n(z_n)$
+
+Update $S_{n}(\mathbf{z}_{n})$ via (3)
+
+$$
+d _ {n} \leftarrow \operatorname {T A C O} \left(C _ {n} \left(\boldsymbol {z} _ {n}\right), S _ {n} \left(\boldsymbol {z} _ {n}\right)\right)
+$$
+
+Observe $y_{n} = f(\pmb{z}_{n},d_{n}) + \nu_{n}$
+
+Update GP posterior
+
+Subroutine: TACO
+
+Inputs: $C_n(\pmb{z}_n); \mathcal{D}_n$
+
+$\mathcal{C}_n = \{d\in \mathcal{D}_n\mid T\in C_n(\pmb {z}_n,d)\}$
+
+if $\mathcal{C}_n\neq \emptyset$ then
+
+$$
+d\gets \operatorname *{arg min}_{d^{\prime}\in \mathcal{C}_{n}}|\mu_{n - 1}(\boldsymbol{z}_{n},d^{\prime}) - T|
+$$
+
+else
+
+$$
+l\leftarrow \operatorname *{arg max}_{d^{\prime}\in \mathcal{D}_{n}\cap \overline{\mathcal{D}}_{z_{n}}}w_{n}(z_{n},d^{\prime})
+$$
+
+return $d$
+
+$$
+\bar {l} _ {n} \left(\boldsymbol {z} _ {n}, d\right) = \max \left\{l _ {n} \left(\boldsymbol {z} _ {n}, d\right), l _ {n} \left(\boldsymbol {z} _ {n}, d ^ {\prime}\right) - L q _ {\boldsymbol {z} _ {n}} \left(d, d ^ {\prime}\right) \right\}
+$$
+
+$$
+\bar {u} _ {n} \left(\boldsymbol {z} _ {n}, d\right) = \min \left\{u _ {n} \left(\boldsymbol {z} _ {n}, d\right), u _ {n} \left(\boldsymbol {z} _ {n}, d ^ {\prime}\right) + L q _ {\boldsymbol {z} _ {n}} \left(d, d ^ {\prime}\right) \right\},
+$$
+
+where $d' = \operatorname{argmin}_{\hat{d} \in \overline{\mathcal{D}}_{\boldsymbol{z}_n}} q_{\boldsymbol{z}_n}(d, \hat{d})$ . We denote by $C_n(\boldsymbol{z}_n, d) = [\bar{l}_n(\boldsymbol{z}_n, d), \bar{u}_n(\boldsymbol{z}_n, d)]$ the confidence interval of a dose $d \in \mathcal{D}$ in round $n$ , and by $C_n(\boldsymbol{z}_n) = \{C_n(\boldsymbol{z}_n, d)\}_{d \in \mathcal{D}}$ . Finally, we form the confidence widths for each dose $d \in \mathcal{D}$ as $w_n(\boldsymbol{z}_n, d) = \bar{u}_n(\boldsymbol{z}_n, d) - \bar{l}_n(\boldsymbol{z}_n, d)$ .
+
+TACO queries a recommendation from a dose set $\mathcal{D}_n$ at each round $n$ upon observing the context $z_{n}$ in three steps: (i): Identify the dose set $\mathcal{C}_n\subseteq \mathcal{D}_n$ whose elements' confidence intervals contain
+
+the target value, $T$ . (ii) If $\mathcal{C}_n \neq \emptyset$ , recommend the dose in $\mathcal{C}_n$ with the closest mean response to the target value $T$ . (iii) If $\mathcal{C}_n = \emptyset$ , recommend the dose in $\mathcal{D}_n \cap \overline{\mathcal{D}}_{z_n}$ with the widest confidence interval. In the first step, TACO eliminates the doses which are suboptimal with high probability. This step includes elements of both exploration and exploitation. A dose whose mean response is close to the target value can be selected (exploitation). On the other hand, if a dose is under-explored, it will have a wider confidence interval which may contain the target, and it stands a chance to be selected (exploration). In the third step, TACO focuses on pure exploration to identify the doses that may be optimal. TACO is efficient in the sense that it treats exploration as a proxy objective –in the third step–only when all the feasible doses (i.e., safe) are suboptimal with high probability.
+
+Safety awareness We design a safe exploration scheme inspired from the previous works on safe GP optimization [44, 45]. We denote the safe set at round $n$ for the context $\mathbf{z}_n$ by $S_{n}(\mathbf{z}_{n})$ . Let us denote by $\hat{l}_n(\mathbf{z}_n,d,d')\coloneqq \bar{l}_n(\mathbf{z}_n,d) - Lq_{\mathbf{z}_n}(d,d')$ , and $\hat{u}_n(\mathbf{z}_n,d,d')\coloneqq \bar{u}_n(\mathbf{z}_n,d) + Lq_{\mathbf{z}_n}(d,d')$ . We implement the following expansion rule to derive $S_{n}(\mathbf{z}_{n})$ each round,
+
+$$
+S _ {n} \left(\boldsymbol {z} _ {n}\right) = S _ {n - 1} \left(\boldsymbol {z} _ {n}\right) \cup \left(\bigcup_ {d \in S _ {n - 1} \left(\boldsymbol {z} _ {n}\right)} \left\{d ^ {\prime} \in \mathcal {D} \mid \hat {l} _ {n} \left(\boldsymbol {z} _ {n}, d, d ^ {\prime}\right) \geq T _ {\min } \wedge \hat {u} _ {n} \left(\boldsymbol {z} _ {n}, d, d ^ {\prime}\right) \leq T _ {\max } \right\}\right), \tag {3}
+$$
+
+To satisfy the safety requirements, TACO recommends a dose from $\mathcal{D}_n = S_n(z_n)$ at each round $n$ . $S_{n}(z_{n})$ only contains the doses for which $f$ resides in the target interval almost certainly (see Theorem 1). We also define the $\epsilon$ -reachability operator $\mathcal{R}_{\epsilon}$ , where $\epsilon >0$ accounts for the uncertainty in measurements as in [44],
+
+$$
+\begin{array}{l} \mathcal {R} _ {\epsilon} \left(S _ {0} (z)\right) := S _ {0} (z) \cup \left\{d \in \mathcal {D} \mid \exists d ^ {\prime} \in S _ {0} (z), f (z, d ^ {\prime}) - L q _ {z} (d, d ^ {\prime}) - \epsilon \geq T _ {\min } \right. \\ \left. \wedge f (z, d ^ {\prime}) + L q _ {z} (d, d ^ {\prime}) + \epsilon \leq T _ {\max } \right\}. \tag {4} \\ \end{array}
+$$
+
+We denote by $\mathcal{R}_{\epsilon}^{n}$ the $n$ -time reachability operator, which calls $\mathcal{R}_{\epsilon} n$ times using the previous step's output. Then, $\lim_{n \to +\infty} \mathcal{R}_{\epsilon}^{n}(S_{0}(\pmb{z}))$ represents the subset of $\mathcal{D}$ that can be identified as safe for the context $\pmb{z}$ using the initial safe set $S_{0}(\pmb{z})$ , by observing $f$ up to a statistical certainty restricted by $\epsilon$ .
+
+# 4 Theoretical analyses
+
+Consider a sequence of patient contexts $\bar{z} = [z_1\ldots z_N]$ . Let $\mathbb{X}_N = X_1\times \ldots X_N$ denote the space of all context-admissible recommendation pairs, where $X_{n} = z_{n}\times \mathbb{D}_{n}$ , and $\mathbb{D}_n\subseteq \mathcal{D}$ is the admissible dose space for $z_{n}$ . For a given sequence of context-recommendation set $A$ , let $\pmb{y}_A$ denote the $|A|$ -dimensional vector containing corresponding noisy evaluations of $f$ . The quantity governing our regret bounds after $N$ rounds in this scenario is a volatility-adapted maximum information gain term, $\gamma_N^{vol} = \max_{A\subset \mathbb{X}_N}I(\pmb {y}_A;\pmb {f}_A)$ , where $\pmb {f}_A = [f(\pmb {x})]_{\pmb {x}\in A}$ and $I(\pmb {y}_A;\pmb {f}_A)$ is the mutual information between $f$ and observations at points in $A$ . In the general setting where there is not a fixed context sequence, we have $\gamma_{N} = \max_{A\subset \mathcal{X}^{N}}I(\pmb {y}_A;\pmb {f}_A)$ . Note that since $\mathbb{X}_N\subseteq \mathcal{X}^N$ , we have $\gamma_N^{vol}\leq \gamma_N$ . Explicit bounds on $\gamma_{N}$ depending on $N$ are studied in the literature [41, 51]. In this section, we first derive a high probability upper bound on the cumulative regret of TACO for a fixed context sequence without safety constraints. Then, we bound the regret of ESCADA in a single context scenario with safety constraints. For the former, we have $\bar{z}_1 = [z_1\dots z_N]$ , and $\mathbb{D}_n = \mathcal{D}$ , and we denote the upper bound on the information gain term (see Lemma 2) by $\gamma_N^{vol1}$ . For the latter, we have $\bar{z}_2 = [z\dots z]$ , $\mathbb{D}_n = S_n(z)$ , and we denote the upper bound on the information gain term by $\gamma_N^{vol2}$ . We also prove that every dose recommended by ESCADA is safe with high probability (w.h.p.). Detailed proofs for each result can be found in Appendix D.
+
+First, we mention two standard results. Lemma 1 shows that $f(x)$ is contained in the GP-induced confidence intervals w.h.p. and Lemma 2 expresses the information gain in terms of predictive variances.
+
+Lemma 1. (Theorem 1 in [25]) Pick $\delta \in (0,1)$ , and define $\beta_{n} = 2L^{2} + 300\gamma_{n}\log^{3}(n / \delta)$ , where $L$ is the Lipschitz constant. Let $\mathcal{E} = \{|\mu_{n - 1}(\pmb {x}) - f(\pmb {x})|\leq \beta_n^{1 / 2}\sigma_{n - 1}(\pmb {x}),\forall n\in \mathbb{N},\forall \pmb {x}\in \mathcal{X}\}$ . We have $\mathbb{P}\{\mathcal{E}\} \geq 1 - \delta$ .
+Lemma 2. (Lemma 5.3 in [41]) The information gain for the points selected can be expressed in terms of the predictive variances. If $\pmb{f}_N = (f(\pmb{x}_n))$ , $I(\pmb{y}_N; \pmb{f}_N) = \frac{1}{2} \sum_{n=1}^{N} \log(1 + \sigma^{-2} \sigma_{n-1}^2(\pmb{x}_n))$ .
+
+The following theorem provides a safety guarantee for ESCADA under the event $\mathcal{E}$ in Lemma 1. The proof depends on an inductive argument on the safe sets constructed by ESCADA.
+
+Theorem 1. Given that an initial safe dose set $S_0(z)$ is available $\forall z \in \mathcal{Z}$ , all doses recommended by ESCADA are safe, that is, $T_{\mathrm{min}} \leq f(\pmb {z}_n,d_n) \leq T_{\mathrm{max}} \forall n \in [N]$ , with at least $1 - \delta$ probability.
+
+We proposed a novel acquisition function, TACO, for the leveling problem described in §2. Theorem 2 provides an upper bound on the regret of TACO without any safety constraints in place.
+
+Theorem 2. Define $\beta_{n}$ as in Lemma 1 and let $C\coloneqq 8 / \log (1 + \sigma^{-2})$ . Cumulative regret of TACO for a fixed context sequence is upper-bounded as follows,
+
+$$
+\mathbb {P} \left\{R _ {N} \leq \sqrt {C N \beta_ {N} \gamma_ {N} ^ {v o l 1}} \right\} \geq 1 - \delta .
+$$
+
+Next, we introduce a new concept, safe path.
+
+Definition 1. (Safe Path) For a fixed context $z \in \mathcal{Z}$ , we say that there exists a safe path between two doses $d_1, d_2 \in \mathcal{D}$ if the following is satisfied,
+
+$$
+\eta \left(d _ {1}, d _ {2}\right) = \min \left(\min _ {d \in \left[ d _ {1}, d _ {2} \right]} \left(T _ {\max } - \epsilon - f (\boldsymbol {z}, d)\right), \min _ {d \in \left[ d _ {1}, d _ {2} \right]} \left(f (\boldsymbol {z}, d) - T _ {\min } - \epsilon\right)\right) > 0, \tag {5}
+$$
+
+where $\epsilon > 0$ is same as in (4). Definition 1 states that if there exists a safe path between two doses $d_{1}$ and $d_{2}$ , then there is no dose violating or exactly at the safety constraints between them. That is, $f(d) \in (T_{\min} + \epsilon + \eta(d_{1}, d_{2}), T_{\max} - \epsilon - \eta(d_{1}, d_{2}))$ for all $d \in [d_{1}, d_{2}]$ . Next, we give the regret bound for ESCADA, which uses TACO with the safe sets $S_{n}(z_{n})$ in (3). We assume a fixed context scenario and show that the safety constraints result in at most a constant addition to the regret.
+
+Theorem 3. If there exists a safe path between at least one dose $d \in S_0(z)$ and $d_{\mathbf{z}}^*$ , and we have $q_{\mathbf{z}}(d_1, d_2) = K(|d_1 - d_2|)$ for some monotonically increasing mapping $K: \mathbb{R}^{+} \to \mathbb{R}^{+}$ and for all $d_1, d_2 \in \mathcal{D}$ , then the cumulative regret of ESCADA in a safety constrained single context $(\mathbf{z})$ scenario can be upper-bounded by setting the discretization parameter $\lambda < \epsilon$ as follows,
+
+$$
+\mathbb {P} \big \{R _ {N} \leq \sqrt {C N \beta_ {N} \gamma_ {N} ^ {v o l 2}} + \overline {{T}} N _ {z} \big \} \geq 1 - \delta ,
+$$
+
+where $N_z \in \mathbb{N}$ is a constant independent of $N$ .
+
+Note that since $f(\boldsymbol{z}, d_{\boldsymbol{z}}^{*}) = T$ and $T \in (T_{\min} + \alpha, T_{\max} - \alpha)$ , one must ensure that $\alpha > \epsilon$ for the possibility of a safe path between some $d \in S_0(\boldsymbol{z})$ and $d_{\boldsymbol{z}}^{*}$ at the first place.
+
+The assumption that $q_{\mathbf{z}}(d_1,d_2) = K(|d_1 - d_2|)$ for a monotonically increasing mapping $K$ holds in our working example where the blood glucose response to insulin dose can be characterized by the carbohydrate factor (CF) [38, 55]. That is, if we let $L \gg \mathrm{CF}$ , then we have $f(\mathbf{z},d_1) - f(\mathbf{z},d_2) \leq L|d_1 - d_2|$ for $d_1,d_2 \in \mathcal{D}$ , and $q_{\mathbf{z}}(d_1,d_2) = |d_1 - d_2|$ . Moreover, this is the case for a variety of widely used kernel induced distance metrics. For the squared exponential kernel $k(\alpha ,\beta) = \exp \left(-\| \alpha -\beta \| ^2 /2\sigma^2\right)$ , we have (see §2),
+
+$$
+q _ {\boldsymbol {z}} \left(d _ {1}, d _ {2}\right) = \sqrt {2 - 2 \exp \left(- \left| d _ {1} - d _ {2} \right| ^ {2} / \sigma^ {2}\right)} \tag {6}
+$$
+
+Similar observations follow for other radial-basis function kernels (e.g., Laplacian kernel). Theorems 2 and 3 constitute the non-incremental parts in our analysis as they provide explicit regret guarantees for a novel problem structure and acquisition strategy, both with and without safety constraints for a compact and convex action set. To generalize the bound in Theorem 3 to mixed context scenarios, one needs to impose further assumptions on the regularity of context arrivals over time. We provide experimental results on mixed context scenarios in §5 and show that the inter-contextual information transfer actually improves the performance as expected.
+
+# 5 Experiments
+
+# 5.1 Experimental setup
+
+Online experimentation in the clinical setting is hazardous and it faces ethical challenges [12, 34, 35, 52]. Previous works on dose-finding clinical trials validate their methods either through synthetic experiments or by using external algorithms to fit a dose-response model to real-world data when
+
+the patient group is homogeneous [5, 26, 40]. Such algorithms are not applicable in our case as they assume a shared dose-response model among patients, whereas we aim to learn personalized models. We make in silico experiments using the open-source implementation [57] of the U.S. FDA approved University of Virginia (UVA)/PADOVA T1DM simulator [23], which is the most frequently used framework in blood glucose control studies [10, 11, 13, 18, 28, 46, 59, 60]. It comes with 30 virtual patients with different individual characteristics: 10 adults, 10 adolescents, and 10 children. The simulator calculates the postprandial blood glucose (PPBG) response of a patient for (meal event, bolus insulin dose) pairs using differential equations and patient characteristics [23]. In our best effort to evaluate the success and potential of ESCADA as a supplementary tool in the clinical setting and to provide external validation, we also compare its performance against a clinician for five virtual adult patients. Our code is available at https://github.com/Bilkent-CYBORG/ESCADA.
+
+Performance metrics When the PPBG level drops below $70\mathrm{mg / dl}$ (or exceeds $180\mathrm{mg / dl}$ ), hypoglycemia (hyperglycemia) events occur. Both events may lead to life-threatening conditions [6]. Our primary objective is to recommend insulin doses that keep the patients' PPBG level close to the target BG level (see (1)) while not recommending any insulin dose that triggers hypoglycemia or hyperglycemia events (see (2)). We set the target blood glucose (BG) level to $112.5\mathrm{mg / dl}$ [22]. We gauge an algorithm's performance by combining its regret, hypoglycemia/hyperglycemia frequencies (error frequencies), and glycemic risk indices. Glycemic risk indices are low blood glycemic index (LBGI) and high blood glycemic index (HBGI), and they characterize the risk of hypoglycemia and hyperglycemia events in the long term, respectively [22]. A well-rounded algorithm should have a low cumulative regret together with small risk index values by safely and efficiently learning to recommend better insulin doses. Besides, we discuss the competing algorithms' consistency since inexplicable variations in medical therapy are undesirable [47]. Precisely speaking, for a fixed history, when we query a recommendation from a consistent algorithm multiple times for the same meal event, it should not change. A meal event is a two-element tuple: (carbohydrate intake, fasting blood glucose). We create different meal events via uniform sampling to create an ensemble of different scenarios. We sample carbohydrate intake for each meal event from $[20, 80]$ g, and fasting blood glucose from $[100, 150]$ mg/dl.
+
+Single meal event (SME) scenario In this part, we recommend insulin doses to a patient for the same meal event, assuming that the patient takes the insulin dose directly before the meal. Simulating this setup is helpful for two reasons: (i) it tests the performance of the algorithms in the classical non-contextual MAB setting, (ii) it provides a simple benchmark to understand the performance metrics and to compare them with the contextual setup later. Our objective is to optimize the PPBG 150 minutes after the meal. We make 15 consecutive dose recommendations for a meal event in a single run. We repeat this experiment with 30 different meal events for all 30 patients.
+
+Multiple meal events (MME) scenario In this part, we recommend insulin doses to a single patient for a sequence of different meal events and use the same 30 meal events created in the SME scenario. We make consecutive recommendations for different meal events in a round-robin fashion and recommend a total of 15 doses for each meal event. Precisely speaking, after making a dose recommendation for a meal event, we make recommendations for the other 29 meal events and observe the PPBGs before making the next recommendation for the same meal event. This setup illustrates that the information gained from a context can assist in making decisions for different contexts. Contextual knowledge transfer enables our algorithm to adapt to intra- and inter-daily variability in meal events.
+
+Algorithms We simulate ESCADA and TACO (i.e., without the safety mechanism). Besides, we propose a Thompson sampling (TS)-based algorithm and its safe version (STS), which operates as follows: TS samples a PPBG function from the posterior GP in each round and recommends the dose that achieves the PPBG closest to the target BG. STS implements the safe exploration strategy in §3 and uses TS as the acquisition function. In the final part, we implement the GP-UCB algorithm in [41] using three different "reward" functions in Figure 1 and compare it to our acquisition functions TACO and TS. We use two versions of dose calculators as baselines, whose details are given below.
+
+Dose calculators Dose calculators are commonly used in diabetes care, as they are transparent and interpretable [55]. We use them to initialize the safe dose set for patient and meal event pairs. A calculator recommends an insulin dose via a simple equation, including carbohydrate intake, fasting blood glucose, and patient-specific parameters. They must be fine-tuned to ensure safety which may be challenging. Even when fine-tuned, they may not include some patient characteristics which can affect PBBG in the calculation rule. Correction doses constitute $9\%$ of the patients' daily insulin dose intake due to the calculator's failure [55]. More details about bolus calculators are available in Appendix C.
+
+Table 1: “-TC” indicates that tuned calculator was used. Target PPBG level is $T = 112.5 \, \mathrm{mg/dl}$ . "PPBG" column is averaged over observations for all 30 patients, 30 meal events per patient, and 15 recommendations per meal event. "Hyper" and "Hypo" columns denote the hyperglycemia and hypoglycemia event frequencies, respectively, averaged over all 30 patients. Similarly, HBGI and LBGI risk indices are averaged over all 30 patients. We report (mean ± standard deviation).
+
+ | Algorithm | PPBG | Hyper | Hypo | HBGI | LBGI |
| SME | Calc. | 144.0 ± 39.5 | .143 ± .217 | .0614 ± .189 | 3.84 ± 3.41 | 1.37 ± 3.95 |
| Tuned Calc. | 123.7 ± 18.1 | 0 | .0021 ± .010 | 0.83 ± 0.66 | 0.24 ± 0.47 |
| TS | 119.8 ± 42.2 | .046 ± .029 | .0216 ± .028 | 1.52 ± 1.25 | 1.01 ± 2.31 |
| TACO | 121.7 ± 50.4 | .049 ± .032 | .0175 ± .019 | 1.89 ± 1.63 | 0.52 ± 0.46 |
| STS | 121.6 ± 24.8 | .031 ± .063 | .0029 ± .010 | 1.07 ± 1.33 | 0.15 ± 0.23 |
| ESCADA | 122.2 ± 20.0 | .015 ± .030 | .0031 ± .008 | 0.77 ± 0.82 | 0.11 ± 0.24 |
| STS-TC | 117.1 ± 11.9 | .002 ± .004 | .0004 ± .001 | 0.28 ± 0.24 | 0.05 ± 0.05 |
| ESCADA-TC | 116.1 ± 12.5 | .002 ± .004 | .0007 ± .003 | 0.26 ± 0.21 | 0.07 ± 0.09 |
| MME | GP-UCB-1 | 124.1 ± 87.0 | .179 ± .050 | .2618 ± .202 | 5.43 ± 2.26 | 15.4 ± 22.5 |
| GP-UCB-2 | 103.7 ± 59.4 | .080 ± .060 | .2873 ± .254 | 2.21 ± 1.58 | 16.0 ± 27.0 |
| GP-UCB-3 | 111.0 ± 32.6 | .022 ± .010 | .0648 ± .076 | 0.73 ± 0.33 | 3.45 ± 5.17 |
| TS | 112.4 ± 14.4 | .003 ± .003 | .0107 ± .011 | 0.16 ± 0.18 | 0.53 ± 0.95 |
| TACO | 113.7 ± 19.2 | .006 ± .031 | .0010 ± .002 | 0.29 ± 1.18 | 0.07 ± 0.04 |
| STS | 116.5 ± 12.5 | .004 ± .015 | .0007 ± .002 | 0.32 ± 0.49 | 0.05 ± 0.05 |
| ESCADA | 116.9 ± 13.1 | .006 ± .017 | .0005 ± .002 | 0.34 ± 0.55 | 0.04 ± 0.04 |
+
+We consider two setups. First, we use a calculator setting that occasionally fails to provide safe dose recommendations and sacrifice the assumption that an initial safe set, $S_0(z)$ , is always available. Then, we use tuned calculators for each patient and ensure that $S_0(z)$ is almost always available.
+
+# 5.2 Discussion of results
+
+Safety Ensuring patient safety is pivotal. Theorem 1 shows that ESCADA recommends safe doses with high probability when an initial safe dose set is available. However, the initially provided set may not always be safe in reality due to calculator or clinician mistakes. We simulate two scenarios when an initial safe set is almost always available and not. For the latter, Table 1 shows that the error frequencies of ESCADA are not zero. We expect that error since the calculator fails to consistently provide safe doses in the beginning. However, ESCADA yields significantly lower error frequencies and risk index values than the calculator. That improvement stems from ESCADA's ability to gradually identify and recommend safe doses, even when initially misdirected. We plot consecutive dose recommendations by ESCADA in SME scenario for three different meal events in Figure 4. For each of these meal events, rule-based calculator fails to provide safe doses in the beginning. Notwithstanding, ESCADA expands its safe set in the right direction and eventually recommends safe doses. Figure 3 and Table 1 confirm the safety mechanism's effectiveness as ESCADA and STS yield significantly better safety metrics than the unsafe algorithms, TACO and TS, especially for hypoglycemia. Next, we manually tune the calculator parameters for each patient separately so that it successfully provides an initial safe set almost always (Tuned Calc., Table 1). Table 1 shows that ESCADA-TC and STS-TC yield remarkably lower error frequencies and risk indices, along with better PBBG distributions.
+
+Regret Minimizing the regret is equivalent to recommending doses that lead to PBBG values close to the target BG by (1). We observe from Figures 3 and 5, and Table 1 that ESCADA(-TC) and STS(-TC) significantly outperforms the (tuned) calculator. Figure 5 shows that TACO and TS incur lower cumulative regrets than ESCADA and STS in the MME scenario. That is a natural trade-off between safety and regret since the safety mechanism restricts the allocation of a dose before it is identified as safe. Therefore, a safe algorithm yields higher regret when the initial safe set is far from the optimal dose.
+
+Inter-contextual information transfer We investigate the efficiency of GP-induced smoothness in transferring information between different contexts. We mark an evident advancement in PBBG distributions and safety metrics in the MME scenario compared to the SME scenario in Table 1. Examining Figure 6, we observe that ESCADA expands the safe dose set and identifies the optimal dose faster in the MME scenario. Remember that ESCADA recommends doses for different meal
+
+
+Figure 3: PPBG distribution boxplots in SME scenario. "TC" suffix indicates that the tuned calculator is used.
+
+
+Figure 5: The cumulative regrets averaged over all 30 patients in MME scenario (± 0.25 standard deviation).
+
+
+Figure 4: Consecutive dose recommendations to three different meal events with unsafe $S_{0}(z)$ in SME scenario.
+
+
+Figure 6: Consecutive dose recommendations for three different meal events (ME) in SME and MME scenarios.
+
+events between two consecutive recommendations for the same meal event in the MME scenario. That is, the information gained from a context improves the performance for other contexts. Besides, we observe significant advances in the safety metrics of TACO and TS in the MME scenario as well.
+
+Comparison with GP-UCB We compare our acquisition functions, TACO and TS, against the adaptations of the GP-UCB algorithm as described in §2 for three different reward functions in Figure 1. "GP-UCB-X" uses "Reward X" in Figure 1, which are defined as follows at each round $n$ ,
+
+$$
+r _ {1} (n) = - \log (| y _ {n} - T | + 1) \qquad r _ {2} (n) = 1 - \exp (| y _ {n} - T | / 2 0) \qquad r _ {3} (n) = - | y _ {n} - T |
+$$
+
+We have $y_{n}$ instead of $f(z_{n},d_{n})$ as the observations are noisy. Figures 7, 8, and 9 show that GP-UCB's performance varies wildly for different rewards, and it is outperformed by TACO and TS. The practitioner needs to choose a "good" reward function for each problem. Our algorithms do not require that.
+
+Consistency Figures 3 and 5, and Table 1 reveal that ESCADA and STS yield similar results. Both algorithms use GPs and have $\mathcal{O}(n^3)$ time and $\mathcal{O}(n^2)$ memory complexities where $n$ is the number of observations. The key difference between them is that STS strikes the balance between exploration and exploitation through intrinsic randomization. That is, for a fixed patient history, STS can make different recommendations for the same meal event in test time, damaging its interpretability and leading to undesired inexplicable variations in the treatment [47]. On the other hand, ESCADA trades off the exploration and exploitation through the explicit and deterministic machinery described in §3 which makes it a fairly interpretable model. Moreover, even though we design and test STS, we do not provide an upper bound on its regret as opposed to ESCADA, which is an interesting future work.
+
+Clinician comparison We compare ESCADA's performance against a clinician's for five virtual patients. For each patient, we provided the clinician with 20 samples in the form of (meal event, insulin dose, PBBG) and asked her to make recommendations for 20 unseen meal events. We provided ESCADA with the same 20 samples for each patient and queried recommendations for the same 20 test meal events. Figure 10 shows that the clinician performs slightly worse than the calculator,
+
+and ESCADA outperforms both significantly. These results suggest that making inferences about a patient's dose response is not trivial, and ESCADA is promising supplementary tool in clinical setting. Moreover, ESCADA can provide the clinicians with various useful statistics regarding dose responses, such as the confidence region of the response, hypo-/hyper-glycemia probabilities, or probability of response residing in a specific interval for a given patient, meal event, and insulin dose.
+
+
+Figure 7: PBBG distribution boxplots for TACO, TS, GP-UCB, and the calculator in MME scenario.
+
+
+Figure 8: Cumulative regrets for TACO, TS, GP-UCB, and calculator in MME scenario (±0.25 standard deviation)
+
+
+Figure 9: Cumulative regrets for TACO and the best GP-UCB in MME scenario (± 0.25 standard deviation).
+
+
+Figure 10: PPBG distribution boxplots for five virtual patients in the clinician comparison experiment.
+
+# 6 Concluding remarks
+
+We formalized and studied a prevalent problem in medicine, safe leveling, and proposed TACO, a novel acquisition function tailored for this problem structure. As safety is crucial in healthcare, we proposed a safe exploration strategy to render TACO safe. Combining these two blocks, we proposed ESCADA, a safe and efficient learning algorithm, and provided safety guarantees and upper bounds on its cumulative regret. Through extensive in silico experiments on the bolus-insulin dose allocation problem for type-1 diabetes disease, we showed our algorithms' effectiveness over the rule-based dose calculators and straightforward adaptations of the GP-UCB algorithm for the safe leveling task. We also compared ESCADA's performance against a clinician's to provide external validation and discussed its potential as a complementary instrument in clinical settings. ESCADA can also be used in other safety-critical decision-making problems where the goal is to safely control a target variable.
+
+Acknowledgments: This work was supported by the Scientific and Technological Research Council of Turkey (TUBITAK) under Grant 215E342. Ilker Demirel was also supported by Vodafone as part of 5G and Beyond Joint Graduate Support Programme coordinated by Information and Communication Technologies Authority. The clinician experiment was done as part of the TUBITAK Project 215E342 under the supervision of a Professor in the Dept. of Internal Diseases in Umraniye Training and Research Hospital, Istanbul, Turkey. Dose recommendations for the virtual patients are provided by a clinical dietician working in the same hospital. Research conducted within the scope of the TUBITAK Project 215E342 has been approved by the ethics committee of the hospital.
+
+# References
+
+[1] M. Abeille and A. Lazaric. Linear Thompson Sampling Revisited. In International Conference on Artificial Intelligence and Statistics (AISTATS), pages 176-184, 2017.
+[2] S. Amani, M. Alizadeh, and C. Thrampoulidis. Regret bound for safe Gaussian process bandit optimization. In Conference on Learning for Dynamics and Control, pages 158-159, 2020.
+[3] E. A. Ashley. Towards precision medicine. Nature Reviews Genetics, 17(9):507, 2016.
+[4] P. Auer, N. Cesa-Bianchi, and P. Fischer. Finite-time analysis of the multiarmed bandit problem. Machine Learning, 47(2):235-256, 2002.
+[5] M. Aziz, E. Kaufmann, and M.-K. Riviere. On multi-armed bandit designs for dose-finding clinical trials. Journal of Machine Learning Research, 22:1-38, 2021.
+[6] A. Bastaki et al. Diabetes mellitus and its treatment. International Journal of Diabetes and Metabolism, 13(3):111, 2005.
+[7] M. Brégère, P. Gaillard, Y. Goude, and G. Stoltz. Target tracking for contextual bandits: Application to demand side management. In International Conference on Machine Learning (ICML), pages 754-763, 2019.
+[8] A. R. Cardoso and H. Xu. Risk-averse stochastic convex bandit. In International Conference on Artificial Intelligence and Statistics (AISTATS), pages 39–47, 2019.
+[9] A. Cassel, S. Mannor, and A. Zeevi. A general approach to multi-armed bandits under risk criteria. In Conference On Learning Theory (COLT), pages 1295–1306, 2018.
+[10] Y. Chandak, G. Theocharous, S. Shankar, M. White, S. Mahadevan, and P. Thomas. Optimizing for the future in non-stationary mdps. In International Conference on Machine Learning (ICML), pages 1414-1425, 2020.
+[11] Y. Chandak, S. Niekum, B. da Silva, E. Learned-Miller, E. Brunskill, and P. S. Thomas. Universal off-policy evaluation. Advances in Neural Information Processing Systems (NeurIPS), 34, 2021.
+[12] I. Y. Chen, E. Pierson, S. Rose, S. Joshi, K. Ferryman, and M. Ghassemi. Ethical machine learning in healthcare. Annual Review of Biomedical Data Science, 4, 2020.
+[13] I. Fox, J. Lee, R. Pop-Busui, and J. Wiens. Deep reinforcement learning for closed-loop blood glucose control. In Machine Learning for Healthcare Conference (ML4HC), pages 508-536, 2020.
+[14] N. Galichet, M. Sebag, and O. Teytaud. Exploration vs exploitation vs safety: Risk-aware multi-armed bandits. In Asian Conference on Machine Learning, pages 245–260, 2013.
+[15] M. A. Gelbart, J. Snoek, and R. P. Adams. Bayesian optimization with unknown constraints. In Uncertainty in Artificial Intelligence (UAI), pages 250–259, 2014.
+[16] GPy. GPy: A Gaussian process framework in Python. url = http://github.com/SheffieldML/GPy, 2012.
+[17] J. M. Hernandez-Lobato, M. A. Gelbart, R. P. Adams, M. W. Hoffman, Z. Ghahramani, et al. A general framework for constrained Bayesian optimization using information-based search. Journal of Machine Learning Research, 17(160):1-53, 2016.
+[18] A. Huang, L. Leqi, Z. Lipton, and K. Azizzadenesheli. Off-policy risk assessment in contextual bandits. Advances in Neural Information Processing Systems (NeurIPS), 34, 2021.
+[19] A. Kazerouni, M. Ghavamzadeh, Y. Abbasi Yadkori, and B. Van Roy. Conservative contextual linear bandits. Advances in Neural Information Processing Systems (NeurIPS), 30, 2017.
+[20] N. Khajonchotpanya, Y. Xue, and N. Rugeerapaiboon. A revised approach for risk-averse multi-armed bandits under CVaR criterion. Operations Research Letters, 49(4):465–472, 2021.
+[21] K. Khezeli and E. Bitar. Safe linear stochastic bandits. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 10202-10209, 2020.
+[22] B. P. Kovatchev, D. J. Cox, A. Kumar, L. Gonder-Frederick, and W. L. Clarke. Algorithmic evaluation of metabolic control and risk of severe hypoglycemia in type 1 and type 2 diabetes using self-monitoring blood glucose data. Diabetes Technology & Therapeutics, 5(5):817-828, 2003.
+
+[23] B. P. Kovatchev, M. Breton, C. Dalla Man, and C. Cobelli. In silico preclinical trials: a proof of concept in closed-loop control of type 1 diabetes, 2009.
+[24] M. D. Kraft, I. F. Btaiche, G. S. Sacks, and K. A. Kudsk. Treatment of electrolyte disorders in adult patients in the intensive care unit. American Journal of Health-System Pharmacy, 62(16):1663-1682, 2005.
+[25] A. Krause and C. S. Ong. Contextual Gaussian process bandit optimization. In Advances in Neural Information Processing Systems (NeurIPS), pages 2447-2455, 2011.
+[26] H.-S. Lee, C. Shen, J. Jordan, and M. Schaar. Contextual constrained learning for dose-finding clinical trials. In International Conference on Artificial Intelligence and Statistics (AISTATS), pages 2645-2654, 2020.
+[27] H.-S. Lee, C. Shen, W. Zame, J.-W. Lee, and M. van der Schaar. Sdf-bayes: Cautious optimism in safe dose-finding clinical trials with drug combinations and heterogeneous patient groups. In International Conference on Artificial Intelligence and Statistics AISTATS, pages 2980-2988, 2021.
+[28] S. Lee, J. Kim, S. W. Park, S.-M. Jin, and S.-M. Park. Toward a fully automated artificial pancreas system using a bioinspired reinforcement learning design: In silico validation. IEEE Journal of Biomedical and Health Informatics, 25(2):536-546, 2020.
+[29] T. Lu, D. Pál, and M. Pál. Contextual multi-armed bandits. In International Conference on Artificial Intelligence and Statistics (AISTATS), pages 485–492, 2010.
+[30] R. Mirnezami, J. Nicholson, and A. Darzi. Preparing for precision medicine. New England Journal of Medicine, 366(6):489-491, 2012.
+[31] T. M. Moldovan and P. Abbeel. Safe exploration in Markov decision processes. In International Conference on Machine Learning (ICML), 2012.
+[32] A. Moradipari, S. Amani, M. Alizadeh, and C. Thrampoulidis. Safe linear thompson sampling with side information. IEEE Transactions on Signal Processing, 2021.
+[33] K. A. Nerenberg, K. B. Zarnke, A. A. Leung, K. Dasgupta, S. Butalia, K. McBrien, K. C. Harris, M. Nakhla, L. Cloutier, M. Gelfer, et al. Hypertension Canada's 2018 guidelines for diagnosis, risk assessment, prevention, and treatment of hypertension in adults and children. Canadian Journal of Cardiology, 34(5): 506-525, 2018.
+[34] W. Price and I. Nicholson. Regulating black-box medicine. Mich. L. Rev., 116:421, 2017.
+[35] W. N. Price. Big data and black-box medical algorithms. Science Translational Medicine, 10(471), 2018.
+[36] C. E. Rasmussen. Gaussian processes in machine learning. Advanced Lectures on Machine Learning, 2004.
+[37] A. Sani, A. Lazaric, and R. Munos. Risk-aversion in multi-armed bandits. Advances in Neural Information Processing Systems (NeurIPS), 25, 2012.
+[38] S. Schmidt and K. Nørgaard. Bolus calculators. Journal of Diabetes Science and Technology, 8(5): 1035-1041, 2014.
+[39] B. Schölkopf, A. J. Smola, F. Bach, et al. Learning with kernels: support vector machines, regularization, optimization, and beyond. MIT Press, 2002.
+[40] C. Shen, Z. Wang, S. Villar, and M. Van Der Schaar. Learning for dose allocation in adaptive clinical trials with safety constraints. In International Conference on Machine Learning (ICML), pages 8730-8740, 2020.
+[41] N. Srinivas, A. Krause, S. Kakade, and M. Seeger. Gaussian process optimization in the bandit setting: no regret and experimental design. In International Conference on Machine Learning (ICML), pages 1015-1022, 2010.
+[42] M. C. Steinbach. Markowitz revisited: Mean-variance models in financial portfolio analysis. SIAM Review, 43(1):31-85, 2001.
+[43] I. Steinwart and A. Christmann. Support vector machines. Springer Science & Business Media, 2008.
+[44] Y. Sui, A. Gotovos, J. Burdick, and A. Krause. Safe exploration for optimization with Gaussian processes. In International Conference on Machine Learning (ICML), pages 997-1005, 2015.
+
+[45] Y. Sui, vincent Zhuang, J. Burdick, and Y. Yue. Stagewise safe Bayesian optimization with Gaussian processes. In International Conference on Machine Learning (ICML), pages 4781-4789, 2018.
+[46] M. Tejedor, A. Z. Woldaregay, and F. Godtliebsen. Reinforcement learning application in diabetes blood glucose control: A systematic review. Artificial Intelligence in Medicine, 104:101836, 2020.
+[47] C. R. Tomson and S. N. Van Der Veer. Learning from practice variation to improve the quality of care. Clinical Medicine, 13(1):19, 2013.
+[48] M. Turchetta, F. Berkenkamp, and A. Krause. Safe exploration for interactive machine learning. In Advances in Neural Information Processing Systems (NeurIPS), 2019.
+[49] S. Vakili and Q. Zhao. Mean-variance and value at risk in multi-armed bandit problems. In Annual Allerton Conference on Communication, Control, and Computing, pages 1330–1335. IEEE, 2015.
+[50] S. Vakili and Q. Zhao. Risk-averse multi-armed bandit problems under mean-variance measure. IEEE Journal of Selected Topics in Signal Processing, 10(6):1093–1111, 2016.
+[51] S. Vakili, K. Khezeli, and V. Picheny. On information gain and regret bounds in gaussian process bandits. In International Conference on Artificial Intelligence and Statistics (AISTATS), pages 82–90, 2021.
+[52] E. Vayena, A. Blasimme, and I. G. Cohen. Machine learning in medicine: addressing ethical challenges. PLoS Medicine, 15(11):e1002689, 2018.
+[53] S. S. Villar and W. F. Rosenberger. Covariate-adjusted response-adaptive randomization for multi-arm clinical trials using a modified forward looking Gittins index rule. Biometrics, 74(1):49-57, 2018.
+[54] A. Wachi, Y. Sui, Y. Yue, and M. Ono. Safe exploration and optimization of constrained MDPs using Gaussian processes. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 32, 2018.
+[55] J. Walsh, R. Roberts, and T. Bailey. Guidelines for optimal bolus calculator settings in adults. Journal of Diabetes Science and Technology, 5(1):129-135, 2011.
+[56] Y. Wu, R. Shariff, T. Lattimore, and C. Szepesvári. Conservative bandits. In International Conference on Machine Learning (ICML), pages 1254–1262, 2016.
+[57] J. Xie. Simglucose v0.2.1. url=https://github.com/jxx123/simglucose, 2018.
+[58] Y. Zhang, E. B. Laber, M. Davidian, and A. A. Tsiatis. Interpretable dynamic treatment regimes. Journal of the American Statistical Association, 113(524):1541-1549, 2018.
+[59] T. Zhu, K. Li, P. Herrero, and P. Georgiou. Basal glucose control in type 1 diabetes using deep reinforcement learning: An in silico validation. IEEE Journal of Biomedical and Health Informatics, 2020.
+[60] T. Zhu, K. Li, L. Kuang, P. Herrero, and P. Georgiou. An insulin bolus advisor for type 1 diabetes using deep reinforcement learning. Sensors, 20(18):5058, 2020.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes] See the discussions after (6), and the comments on Safe Thompson Sampling (STS) in Consistency part in §5.
+(c) Did you discuss any potential negative societal impacts of your work? [N/A]
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [Yes] See §2.
+(b) Did you include complete proofs of all theoretical results? [Yes] See Appendix D.
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [Yes] Complete code repository is included in the supplementary material with a README file containing the instructions on reproduction.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes] See §5 and the code repository (includes comments).
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] See Table 1 and Figures 3, 5, 7, 8, and 9.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes] See Appendix E.
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes] See §5 and Appendix E. We cite [16] and [57].
+(b) Did you mention the license of the assets? [Yes] See Appendix E for the licences of the used assets.
+(c) Did you include any new assets either in the supplemental material or as a URL? [Yes] We share our complete code repository for the experiments in the supplementary material, which will be made publicly available after publishing the manuscript.
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [N/A]
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/images.zip b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..f813de5b8f916403996d315883886caf893eecf5
--- /dev/null
+++ b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0d0175a77d0107e9eb454e70dd2785bb72e67e3f6d2573e97d81153765f5fbc9
+size 479331
diff --git a/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/layout.json b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..7d814ad9d4afd058c63bad535985c5e69af3b8b2
--- /dev/null
+++ b/escadaefficientsafetyandcontextawaredoseallocationforprecisionmedicine/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9ad798630b07e34787e8ca0a46a1010cf4ee9bdbcd8f526757813834385322dc
+size 571358
diff --git a/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/e529c03d-9410-422e-b354-8f98e987dbe5_content_list.json b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/e529c03d-9410-422e-b354-8f98e987dbe5_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..66e17afcb8c6192f947b20ab93a96bdea8b28f19
--- /dev/null
+++ b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/e529c03d-9410-422e-b354-8f98e987dbe5_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:02ef60213d4ba60adf59f5976221514a2452eae3cedb0452a1f40079c12d0fa8
+size 71923
diff --git a/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/e529c03d-9410-422e-b354-8f98e987dbe5_model.json b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/e529c03d-9410-422e-b354-8f98e987dbe5_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..d282431a8b3e17bd1d743445103bc84b7ed4ecfe
--- /dev/null
+++ b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/e529c03d-9410-422e-b354-8f98e987dbe5_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a462ecdde6517aae6aef4efe51b0b0e5ac86df9f8702adb27143b209cafd99b8
+size 86693
diff --git a/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/e529c03d-9410-422e-b354-8f98e987dbe5_origin.pdf b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/e529c03d-9410-422e-b354-8f98e987dbe5_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..1a79c59c3182acac9ed1db446e680b634715bcba
--- /dev/null
+++ b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/e529c03d-9410-422e-b354-8f98e987dbe5_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:81b076d2efaea6a025a3b1ad565fadf7b174bd3f4931dca1a3b0a53a07b52ecc
+size 3170823
diff --git a/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/full.md b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..822069c2a7be5771b135e9f31b4abc10df0bd777
--- /dev/null
+++ b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/full.md
@@ -0,0 +1,261 @@
+# ETAB: A Benchmark Suite for Visual Representation Learning in Echocardiography
+
+Ahmed M. Alaa
+
+UC Berkeley and UCSF
+
+Berkeley, CA
+
+amalaa@berkeley.edu
+
+Anthony Philippakis
+
+Broad Institute of MIT and Harvard
+
+Cambridge, MA
+
+David Sontag
+
+MIT CSAIL and IMES
+
+Cambridge, MA
+
+dsontag@csail.mit.edu
+
+# Abstract
+
+Echocardiography is one of the most commonly used diagnostic imaging modalities in cardiology. Application of deep learning models to echocardiograms can enable automated identification of cardiac structures, estimation of cardiac function, and prediction of clinical outcomes. However, a major hindrance to realizing the full potential of deep learning is the lack of large-scale, fully curated and annotated data sets required for supervised training. High-quality pre-trained representations that can transfer useful visual features of echocardiograms to downstream tasks can help adapt deep learning models to new setups using fewer examples. In this paper, we design a suite of benchmarks that can be used to pre-train and evaluate echocardiographic representations with respect to various clinically-relevant tasks using publicly accessible data sets. In addition, we develop a unified evaluation protocol—which we call the echocardiographic task adaptation benchmark (ETAB)—that measures how well a visual representation of echocardiograms generalizes to common downstream tasks of interest. We use our benchmarking framework to evaluate state-of-the-art vision modeling pipelines. We envision that our standardized, publicly accessible benchmarks would encourage future research and expedite progress in applying deep learning to high-impact problems in cardiovascular medicine.
+
+
+Figure 1: Visual task adaptation for echocardiography. Using multiple open- and public-access echocardiogram data sets, we develop a suite of benchmarks for representation and transfer learning in echocardiography.
+
+# 1 Introduction and Motivation
+
+Echocardiography is one of the most commonly used non-invasive imaging techniques for assessing cardiac function, examining heart anatomy and diagnosing cardiovascular diseases. An "echo" study is an ultrasound of the heart acquired by a cardiac sonographer through a transducer device—different acquisition angles by which the device is placed relative to the patient's heart provide different "views" of the heart anatomy. Echocardiograms inform cardiologists, surgeons, oncologists and emergency physicians on clinical decisions pertaining to treatment management and surgical planning [1-6]. Because of the central role it plays in cardiovascular medicine, there has been a significant interest in applying deep learning-based computer vision models to echocardiograms, with the ultimate goal of automating cardiac evaluation, reducing variance and improving reproducibility in interpreting echocardiograms, and predicting patient-specific clinical outcomes [7-14].
+
+A key hindrance to wider engagement in research focusing on applying deep learning to echocardiography is the lack of large, standardized, publicly-accessible data sets with the annotations required for all downstream tasks of interest. This is because, in addition to the regulatory hurdles associated with publicly sharing clinical data, building such data sets is already a difficult task in itself—i.e., collecting all labels of interest would require examination of clinical reports, pre-selection of relevant echo views, and retrospective manual annotation by experts. Consequently, existing public data sets for echocardiography (e.g., [15-17]) tend to contain a modest number of samples, with only subsets of the annotations and views required for all possible downstream analyses.
+
+Because many downstream tasks would share the same relevant echocardiographic features, access to high-quality representations of echocardiograms—i.e., representations that retain these features—could enable reusing the same pre-trained representations across many tasks rather than training a new model from scratch for each task [18-20], hence enabling adaptation of pre-trained models in setups where fewer annotated data might be available. We shall call such a procedure visual task adaptation—see Figure 1 for a pictorial illustration. Motivated by such thinking, this paper develops a standardized set of benchmark tasks for pre-training and/or evaluating visual models of echocardiography. Our goal is to increase engagement of researchers in a high-impact application domain by providing a systematic domain-specific benchmark through which researchers can focus their effort on tackling challenging problems peculiar to echocardiography, and translate methodological advances in representation learning to practical problems in cardiovascular medicine.
+
+The contribution of this paper is two-fold. First, we develop a comprehensive suite of benchmark tasks tailored to echocardiography using a meta-dataset of public-access sources of echocardiographic data. These benchmark tasks can be used to test vision modeling pipelines, pre-train visual representations of echoes, and evaluate the transferability of representations across pairs of source-target tasks which might differ in the data source, echo views and annotations. Second, using our suite of benchmark tasks we specify a unified evaluation protocol for readily available pre-trained representations—the echocardiographic task adaptation benchmark (ETAB)—which is meant to evaluate the extent by which a given representation generalizes to different tasks, views and patient cohorts. The ETAB benchmark enables researchers to share a unified and publicly-accessible evaluation protocol, even when the representations themselves are pre-trained on private hospital data. ETAB is implemented as a full-fledged software package with a user-friendly API for researchers to design and evaluate visual representations for echocardiograms (Code available at: https://github.com/ahmedmalaa/ETAB).
+
+# 2 Echocardiogram Datasets
+
+The ETAB benchmark suite is based on 5 publicly accessible echocardiogram data sets that span different cohorts and involve different echocardiographic views and annotations (Table 1). In what follows, we provide a brief overview of all data sets currently supported in ETAB.
+
+EchoNet. This data set has two variants: EchoNet-Dynamic and EchoNet-LVH. In the EchoNet-Dynamic data set, introduced in [15], one apical-4 chamber (AP4CH) 2D gray-scale video is extracted from each echo study. A total of 10,036 videos are collected from 10,036 distinct individuals who underwent echocardiography between 2006 and 2018 as part of routine care at a University Hospital. Individuals in the data set were selected at random from hospital records. Along with each video, cardiac function assessments and calculations obtained by a registered sonographer and verified by a level-3 echocardiographer are provided. The second data set, EchoNet-LVH, was collected for a
+
+| Data set | Sample size | Echo views | Annotations |
| EchoNet-Dynamic | 10,036 | AP4CH | LV traces and LV ejection fraction (EF) |
| EchoNet-LVH | 12,000 | PLAX | LV internal dimension, LV posterior wall, In-traventricular septum |
| Unity | 1,224 | AP4CH, PLAX | LV measurements and longitudinal strain |
| CAMUS | 500 | AP4CH, AP2CH | LV EF, ES/ED frames, LV epicardium, endocardium and left atrium segments |
| TMED | 2,341 | PLAX, PSAX, Other | Aortic Stenosis diagnoses, view annotations |
+
+Table 1: Publicly accessible data sets involved in our ETAB framework.
+
+similar cohort and comprises detailed measurements of the LV dimensions based on parasternal long axis (PLAX) views. Both data sets were released by Stanford AIMI Center and are accessible via: https://echonet.github.io/echoNet/ and https://echonet.github.io/lvh/.
+
+Unity Imaging Collaborative. These echocardiograms were obtained from the British echocardiography laboratories and were retrospectively annotated by echocardiography-certified cardiologists through a UK-wide initiative that involved 17 hospitals [21]. The data set comprises a mixture of apical and parasternal views; the former is accompanied with measures of longitudinal strain, and the latter involves measures of LV dimensions. The data is accessible via: https://dataunityimaging.net/.
+
+CAMUS. The Cardiac Acquisitions for Multi-structure Ultrasound Segmentation (CAMUS) is an open-access data set from 500 patients, acquired at the University Hospital of St. Etienne (France) [16]. Compared to EchoNet, this data set has a smaller sample size but is more elaborately annotated, hence it serves as an appropriate target data set for a variety of downstream tasks. The data set contains apical two- and four-chamber acquisitions (AP2CH and AP4CH). Half of the population has a left ventricle (LV) ejection fraction lower than $45\%$ , thus being considered at pathological risk. The data set contains full annotation of the left atrium, the endocardium and epicardium borders of the LV, performed by a cardiologist. To identify the beginning and end of each cardiac cycle, ED and ES frames within each echo clip are labeled. Data is accessible via: https://www.creatis.insa-lyon.fr/Challenge/camus/.
+
+TMED. The Tufts Medical Echocardiogram Dataset (TMED) contains still echocardiogram imagery acquired in the course of routine care from 2015 to 2020 [17]. This data set contains both labeled and unlabeled images—labels include a categorization of views into parasternal long and short axis views (PLAX and PSAX), and diagnostic severity ratings for aortic stenosis (AS). Unlike EchoNet, Unity and CAMUS, this data set contains only still images rather than sequences of frames. The data set is publicly available and can be accessed through: https://tmed.cs.tufts.edu/.
+
+# 3 A Benchmark Suite for Echocardiographic Representation Learning
+
+Our benchmark suite encapsulates a set of standardized tasks that cover a wide variety of echocardiographic modeling problems of interest. Each task comprises a selection of a data set, a view and an annotation from the options listed in Table 1. These standardized tasks can be used to benchmark the performance of vision models, pre-train visual representations, or evaluate the quality of externally pre-trained representations of echocardiograms. In Section 3.1, we present the ETAB benchmark tasks, and in Section 3.2 we describe our proposed ETAB evaluation protocol.
+
+# 3.1 The ETAB benchmark tasks
+
+Based on the data sets listed in Section 2, we design 31 benchmark tasks that cover various echocardiographic tasks of interest. Each benchmark task comprises a specification of the data set, echo view and annotations. The benchmarks are divided into four categories: $(\bullet)$ cardiac structure identification (e.g., detecting the borders of the LV), $(\bullet)$ cardiac function estimation (e.g., estimating the LV ejection fraction), $(\bullet)$ view classification, and $(\bullet)$ clinical prediction. Benchmarks within the same category share a color code that will be later used in visualizations of experimental results. These benchmark tasks constitute the core of the ETAB evaluation protocol presented later in Section 3.2.
+
+ | Benchmark description |
| Benchmark code | Data set | View | Task |
| Cardiac structure identification | a0-A4-E | EchoNet-Dynamic | AP4CH | Left ventricle segmentation |
| a0-A4-C | CAMUS | AP4CH | Left ventricle segmentation |
| a1-A4-C | CAMUS | AP4CH | Left atrium segmentation |
| a2-A4-C | CAMUS | AP4CH | Myocardial wall segmentation |
| a0-A2-C | CAMUS | AP2CH | Left ventricle segmentation |
| a1-A2-C | CAMUS | AP2CH | Left atrium segmentation |
| a2-A2-C | CAMUS | AP2CH | Myocardial wall segmentation |
| Cardiac function estimation | b0-A4-E | EchoNet-Dynamic | AP4CH | LV ejection fraction estimation |
| b1-A4-E | EchoNet-Dynamic | AP4CH | Cardiac cycle phase estimation |
| b2-PL-E | EchoNet-LVH | PLAX | Intraventricular septum estimation |
| b3-PL-E | EchoNet-LVH | PLAX | LV internal dimension estimation |
| b4-PL-E | EchoNet-LVH | PLAX | LV posterior wall identification |
| b0-A4-C | CAMUS | AP4CH | LV ejection fraction estimation |
| b0-A2-C | CAMUS | AP2CH | LV ejection fraction estimation |
| b1-A4-C | CAMUS | AP4CH | Cardiac cycle phase estimation |
| b1-A2-C | CAMUS | AP2CH | Cardiac cycle phase estimation |
| b5-A4-U | Unity | AP4CH | Identifying mitral hinge point on septum |
| b6-A4-U | Unity | AP4CH | Identifying mitral hinge point on lateral wall |
| b7-A4-U | Unity | AP4CH | Identifying LV endocardial apex |
| b8-A4-U | Unity | AP4CH | Identifying LV endocardial contour |
| b2-PL-U | Unity | PLAX | Intraventricular septum estimation |
| b3-PL-U | Unity | PLAX | LV internal dimension estimation |
| b4-PL-U | Unity | PLAX | LV posterior wall identification |
| View recognition | c1-XX-E | EchoNet | — | Classify AP4CH and PLAX views |
| c0-XX-C | CAMUS | — | Classify AP4CH and AP2CH views |
| c1-XX-U | Unity | — | Classify AP4CH and PLAX views |
| c2-XX-T | TMED | — | Classify PLAX and PSAX views |
| Clinical prediction | d0-A4-E | EchoNet-Dynamic | AP4CH | Diagnose cardiomyopathy |
| d1-PL-T | TMED | PLAX | Diagnose Aortic Stenosis |
| d0-A4-C | CAMUS | AP4CH | Diagnose cardiomyopathy |
| d0-A2-C | CAMUS | AP2CH | Diagnose cardiomyopathy |
+
+Table 2: List of all ETAB benchmark tasks. The tasks cover four categories: (●) cardiac structure identification, (●) cardiac function estimation, (●) view classification, and (●) clinical prediction. Each benchmark task is assigned a code that encodes a specification of the source data set, echocardiographic view and annotations.
+
+Each benchmark is encoded through an 5-character code of the form XX-XX-X. The encoding scheme describes each benchmark in terms of the data source, echo view and modeling task follows:
+
+- Characters 0-1: Task identifier
+- Characters 2-3: View identifier
+- Characters 4-5: Dataset identifier
+
+The data sets are encoded as follows E: EchoNet, C: CAMUS, U: Unity, and T: TMED. The views are encoded as follows: A2: Apical 2-chamber, A4: Apical 4-chamber, PL: parasternal long axis, and PS: parasternal short axis. The 4 task categories are encoded as a, b, c and d, and the detailed list of codes for all tasks is provided in the Appendix. The task encoding provides a systematic way for running benchmark experiments and reporting results through the ETAB software library.
+
+Transfer learning benchmarks. In addition to the core benchmark tasks listed in Table 2, benchmark setups for transfer learning can be constructed by picking pairs of source and target tasks from the ETAB task suite. The pairs of benchmark tasks would be typically selected so that at least one of the three elements of a task specification (i.e., data set, view or annotation) differs between the source and the target. These "adaptation" setups can be used to test the ability of a transfer learning algorithm
+
+to repurpose pre-trained representations for new downstream tasks, and provide insights into which tasks and model architectures lead to the most generalizable representations of echocardiograms. A transfer learning benchmark is encoded as: Source-task-code/Target-task-code. For example, benchmark a0-A4-E/b3-PL-U involves pre-training a representation to segment the left ventricle using apical 4-chamber studies from EchoNet-Dynamic, and then using the resulting representation to estimate the LV internal dimension using PLAX studies from the unity data set.
+
+Vision modeling pipelines. Each of the core benchmark tasks in Table 2 can be conducted using a vision modeling pipeline $\mathcal{M}$ that comprises (1) a choice of a backbone architecture for the visual representation and a (2) task-specific model head as depicted in Figure 2. The backbone representation can either be pretrained using external data sources or trained from scratch on the benchmark task.
+
+When applied to a transfer learning setup (i.e., a pair of source and target benchmark tasks from Table 2), the modeling pipeline retains the backbone representation trained on the source task and finetunes a task-specific head using data from the target task. This could help us answer questions such as: is LV segmentation a good pretext task for learning useful representations in patients with aortic stenosis? which architectures result in representations that generalize well across patient cohorts? How many echo studies do we need to annotate in order to finetune a pretrained model for a given downstream task? Answers to these questions can inform practical modeling choices and data collection requirements.
+
+
+Figure 2: Depiction of a vision modeling pipeline $\mathcal{M}$ .
+
+# 3.2 The ETAB evaluation protocol
+
+In many practical scenarios, we might be interested in evaluating how well a visual representation pretrained on an external data set captures echocardiographic features, e.g., private echocardiogram data, data for other cardiac imaging modalities, or even non-medical data sets (such as ImageNet). The echocardiographic task adaptation benchmark (ETAB) is a unified evaluation protocol that uses the core benchmark tasks in Table 2 to evaluate the usefulness of a given (pre-trained) visual representation for a wide variety of common downstream tasks in echocardiography.
+
+Let $\mathcal{K} = \{1,\dots ,K\}$ be the benchmark categories, and let $\mathcal{T}_k = \{t_{1,k},\ldots ,t_{T_k,k}\}$ be the tasks within category $k\in \mathcal{K}$ . (In Table 2, we have $K = 4$ task categories.) Let $\mathcal{D}_{t,k}$ be the data set associated with the $t$ -th task within the $k$ -th category. Let $\mathcal{R}_{\theta}$ be a pre-trained representation with an architectural specification $\mathcal{R}$ and parameters $\theta$ . For each task $t_k$ , we construct a model $\mathcal{M}_{\theta ,\phi (t_k)} = \mathcal{R}_{\theta}\circ h_{\phi (t_k)}$ where $h_{\phi (t_k)}$ is a model head (e.g., a linear layer) that is specific to task $t_k$ with parameters $\phi (t_k)$ . For each task $t_k$ , the corresponding data set $\mathcal{D}_{t,k}^n = \{(X_{t,k}^i,Y_{t,k}^i)\}_{i = 1}^n$ is used to optimize the parameters of the task-specific head $\phi^{*}$ , with the representation parameters $\theta$ fixed. Let $\mathcal{E}_{t,k}$ be the evaluation metric used to assess performance on task $t_k$ , which we assume takes on values in [0, 1]. The ETAB score of a pre-trained representation $\mathcal{R}_{\theta}$ is thus defined as:
+
+$$
+\operatorname {E T A B} _ {k} ^ {n} \left(\mathcal {R} _ {\theta}\right) \triangleq \mathbb {E} _ {t \sim P _ {\tau_ {k}}} \mathcal {E} _ {t, k} \left[ \mathcal {M} _ {\theta , \phi^ {*} \left(t _ {k}\right)} \left(\mathcal {D} _ {t, k} ^ {n}\right) \right], \operatorname {E T A B} ^ {n} \left(\mathcal {R} _ {\theta}\right) \triangleq \mathbb {E} _ {k \sim P _ {\kappa}} \operatorname {E T A B} _ {k} ^ {n} \left(\mathcal {R} _ {\theta}\right). \tag {1}
+$$
+
+The ETAB score can be evaluated for different values of $n$ to assess the sample efficiency, i.e., transferability, of a pre-trained representation. We implement the metric in (1) by assigning equal weights to all benchmark tasks across all task categories, i.e., $P_{\mathcal{T}_k}$ and $P_{\mathcal{K}}$ are uniform distributions. A weighted ETAB score (with non-uniform choice of $P_{\mathcal{T}_k}$ and $P_{\mathcal{K}}$ ) can be defined to reflect the relative importance or frequency of the different echocardiographic tasks in Table 2 in real-world settings.
+
+The ETAB protocol is model-agnostic, hence it can serve as a benchmark against which all existing and future architectural choices $\mathcal{R}$ and pre-training algorithms can be evaluated. This includes representations pre-trained using supervised, semi-supervised, self-supervised, and generative approaches. Unlike the individual benchmark tasks in Section 3.1—which assess specific downstream or transfer learning scenarios—the ETAB protocol assesses the general usefulness of a visual representation to
+
+echocardiographic tasks through a single procedure and metric. Currently, the total number of benchmark tasks involved in ETAB is 31. We envision that the number of ETAB tasks will grow as more data sets and annotations for echocardiograms are released for public access over time.
+
+To the best of our knowledge, ETAB is the first systematic benchmarking setup dedicated to evaluating echocardiographic representations. Our benchmarking setup can be considered as the domain-specific analogue of the general benchmark for vision tasks developed in [19, 20]. (Further discussion on related work is provided in the supplement.) Models that perform well on general benchmarks may not necessarily be as competitive on downstream tasks specific to echo data, which creates the need for benchmarks that are tailored to the tasks most relevant to cardiovascular problems. A schematic depiction of the protocol is provided in Figure 3.
+
+
+Figure 3: Schematic depiction of the ETAB protocol.
+
+# 4 The ETAB Software Library
+
+The ETAB library is a PyTorch-based implementation of our benchmarking framework that provides a unified and easy-to-use API for running benchmark experiments out-of-the-box, developing new vision modeling pipelines for echocardiography and evaluating pre-trained representations using the ETAB score. The ETAB library offers two key features:
+
+- A unified API for loading and processing publicly-accessible echocardiography datasets.
+- An easy-to-use API for creating modeling pipelines that supports a wide variety of backbone architectures and covers the benchmark tasks in Table 2.
+
+The ETAB package can be installed via https://github.com/ahmedmalaa/ETAB. In this Section, we describe the key features of the package along with representative results for benchmark experiments.
+
+# 4.1 Key features and examples of usage
+
+ETAB data sets. The ETAB library supports a unified API for all public-access data sets listed in Table 1. The ETAB_dataset class is a container for echocardiography data with a multitude of options that specify the data source, echo view, annotations and parameters of the echo study clip (e.g., resolution and frame size, clip length, frame sampling rates). An example for instantiating a data set of apical 4-chamber echo studies with LV EF measurements is provided below:
+
+import etab
+
+```python
+echonet = ETAB_dataset(name="echonet", target="EF", view="A4CH", video=False, normalize=True, frame_l=224, frame_w=224, clip_l=16, fps=50, padding=None)
+```
+
+The ETAB_dataset comes with built-in functionalities for loading and processing the data. A detailed description of these functionalities can be found in the ETAB package documentation.
+
+ETAB model zoo. The ETAB package supports a variety of built-in vision modeling pipelines. Currently, the package supports 12 backbone representations that belong to the convolutional neural network (CNN) and vision transformer (ViT) families. Note that some benchmark tasks (e.g., estimation of LV ejection fraction) are defined with respect to video clips rather than still images, whereas other tasks and datasets are limited to 2D images. In the current release of ETAB, we restrict the backbone representations to frame embeddings and use these representations repeatedly over sequences of images. By restricting the backbone representations to frame embeddings, we ensure that the backbone architecture can be used systematically across all benchmark tasks. In Section 4.3,
+
+we describe the task-specific heads for all benchmark categories in Table 2. The ETAB model zoo (all of the supported backbone and model heads) is available in the Supplementary material.
+
+ETAB score computation. To compute the ETAB score for a given pre-trained representation, the user can load the pre-trained weights for a PyTorch implementation of any of the supported backbones, and then invoke the ETABscore function to evaluate the quality of the representation as follows:
+
+```python
+from etab.scores import ETABscore
+from torchvision.models import resnet50
+backbone $=$ resnet50(weights $\coloneqq$ "IMAGENET1K_V1")
+etab_score $=$ ETABscore(backbone_architecture $\equiv$ "ResNet-50", backbone_model $\equiv$ backbone)
+```
+
+In the example above, we load a ResNet-50 model pre-trained on the ImageNet-1K data set and then evaluate its ETAB score, i.e., measure how well a ResNet-50 trained on non-medical imaging data captures echocardiographic features. By default, the ETAB score is evaluated assuming a uniform weight for all benchmark tasks and with the pre-trained weights being frozen across all tasks. The ETABscore function also supports full finetuning and weighted sampling of benchmark tasks.
+
+Evaluation metrics. We use the following evaluation metrics within the ETAB evaluation protocol in Equation (1). For all segmentation tasks, the metric $\mathcal{E}_{t,k}$ corresponds to the DICE score. For classification tasks, $\mathcal{E}_{t,k}$ is defined as the area under the ROC curve (AUC-ROC). For regression tasks (i.e., predicting LV EF), we use $R^2$ as the metric $\mathcal{E}_{t,k}$ . All metrics are computed on held-out samples. Note that, while we use different metrics for the different tasks, all metrics are defined in the normalized range [0, 1] (higher is better). To compute the ETAB score for a given baseline, we run all benchmark tasks in Table 2 and average the resulting evaluation metrics.
+
+# 4.2 ETAB modeling pipelines
+
+As discussed in the previous Section, ETAB supports backbone representations $\mathcal{R}_{\theta}$ that belong to the CNN and ViT architectural families. The CNN backbones include: ResNet [22], ResNeXt [23], DenseNet [24], Inception [25], MobileNet [26] and ConvNext [27]. The ViT backbones include: Mix Transformer encoders (MiT) [28], Pyramid Vision Transformer (PVT) [29], Multi-scale vision Transformer (ResT) [30], PoolFormer [31], and UniFormer [32]. In what follows, we describe the task-specific heads $h_{\phi}$ for the four benchmark categories in Table 2.
+
+$(\bullet)$ Task-specific heads for cardiac structure identification benchmarks.
+
+The "cardiac structure identification" tasks $(\bullet)$ involve semantic segmentation of ventricular and other anatomic structures. We consider the following segmentation heads: U-Net [33], U-Net++ [34], MAnet [35], Linknet [36], PSPNet [37], DeepLabV3 [38], TopFormer and SegFormer [28]. Depending on the architecture of the selected backbone representation, the default segmentation head used in the ETABscore function is either a U-Net or a SegFormer.
+
+$(\bullet)$ Task-specific heads for cardiac function estimation benchmarks.
+
+This category of tasks involve estimating a patient's cardiac output from an echocardiography video. For all tasks in this category, we apply the backbone representations to obtain frame-level embeddings for the sequence of frames in each echo study. The task-specific heads are variants of recurrent neural networks (RNN) applied to these frame embeddings to obtain a representation for the sequence.
+
+$(\bullet, \bullet)$ Task-specific heads for view classification and clinical predictions.
+
+For all benchmark tasks in this category, we considered baseline models that train attach a simple linear layer on top of the backbone representation to evaluate the output prediction.
+
+The ETABmodel class in ETAB provides a unified sklearn-like API for all vision modeling pipelines. Examples of usage of the ETAB modeling pipelines are provided in the demo notebooks within the ETAB package documentation. Evaluations of the ETAB scores for state-of-the-art backbone models are maintained and regularly updated on the online ETAB leaderboard. In the rest of this Section, we provide sample results for applying the vision modeling pipelines to the benchmark tasks in Table 2.
+
+
+
+
+
+
+
+
+
+
+Figure 4: Results for the cardiac structure identification benchmarks $(\bullet)$ . (a) Performance of the SegFormer model head with a ResNet-50 backbone with and without pre-training on the source data in each transfer learning benchmark. (b) Ground-truth traces (top) and samples of the recovered segmentation by the model (bottom).
+
+# 4.3 Transfer learning benchmarks
+
+In this Section, we consider the cardiac structure identification benchmarks $(\bullet)$ in Table 2. Here, the goal is to segment various anatomic structures of relevance to cardiac diagnostics. In particular, the tasks cover segmentation of the left ventricle (LV), the left atrium (LA), and myocardial wall (MY). LV segmentation is used to compute cardiac contractile function parameters (e.g., systolic/diastolic volumes, ejection fraction, and myocardium mass), which are key indicators of cardiac health [39]. Similarly, segmental evaluation of the MY and LA confer diagnostic value since MY wall thickness and LA enlargement are associated with pathological conditions such as hypertrophy [40].
+
+Based on these benchmarks, we consider 3 experimental setups designed to test the transferability of features across data sets, echo views and tasks. Setup a0-A4-C/a0-A2-C can be used to assess the transferability of ML models across 4- and 2-chamber views, setups a0-A4-C/a1-A4-C and a0-A4-C/a2-A4-C assesses transferability across targets, whereas a0-A4-E/a0-A4-C tests transferability across data sets. Setups a0-A4-E/a0-A2-C and a0-A4-E/a2-A2-C are more challenging as they involve changing data sets, views and labels between the source and target tasks.
+
+In Figure 4 (a), we show the performance of the SegFormer head with a ResNet-50 backbone for setups a0-A4-E/a0-A4-C, a0-A4-C/a0-A2-C and a0-A4-C/a2-A4-C. We evaluate the sample efficiency of the baseline model by fixing the number of training examples in the source task, and varying the number of training examples within the target task. This setup emulates the real-world scenario where we would have few echocardiographic studies extracted from hospital records for a cohort of interest that are manually annotated by a cardiologist, and we would like to adapt a model pre-trained on data from a different hospital to the cohort under study. Stronger baselines would enable us to collect and manually annotate less data points.
+
+The results in Figure 4 (a) demonstrate the relative difficulty of the different transfer learning tasks in terms of the number of (target) examples required for competitive performance. For each of the benchmark tasks, we compare an adaptation pipeline that pre-trains the model on the source task with training from scratch on the target task. For the a0-A4-E/a0-A4-C and a0-A4-C/a0-A2-C setups, we observe that pre-training on source task significantly outperforms supervised learning from scratch when the number of target samples is as few as 16 target examples. From a practical perspective, this means that we can use these benchmarks to select adaptation pipelines for small-scale studies involving echocardiography data (e.g., clinical trial data), and expect the selected model to per
+
+ | Benchmark | U-Net | U-Net++ | MAnet | Linknet | PSPNet | DeepLabV3 |
| Cardiac struct. | a0-A4-C/a0-A2-C | 0.885 | 0.893 | 0.752 | 0.892 | 0.847 | 0.840 |
| a0-A4-C/a1-A4-C | 0.729 | 0.705 | 0.739 | 0.481 | 0.684 | 0.659 |
| a0-A4-C/a2-A4-C | 0.540 | 0.494 | 0.539 | 0.709 | 0.532 | 0.666 |
| a0-A4-E/a0-A4-C | 0.909 | 0.804 | 0.898 | 0.896 | 0.900 | 0.909 |
| a0-A4-E/a0-A2-C | 0.891 | 0.774 | 0.882 | 0.894 | 0.883 | 0.879 |
| a0-A4-E/a2-A4-C | 0.634 | 0.603 | 0.691 | 0.580 | 0.707 | 0.671 |
+
+form competitively on the data set at hand even if the number of samples is small. Samples of the boundaries of LV and MY detected by the adapted models are illustrated in Figure 4 (b).
+
+Figure 4 (a) shows that, while transferring learned features across data sets and across echo views is feasible, transferring representations across different labels (i.e., LV and MY) is a difficult task. We observe that for setup a0-A4-C/a2-A4-C, pre-training on the source task was no better than training from scratch on target data. The difficulty of this benchmark task inspires future research that focuses on developing adaptation pipelines that use other approaches, such as self-supervised or multi-task learning, to improve the transferability of features across the LV and MY labels.
+
+Table 3 demonstrates the performance of all segmentation heads with the ResNet-50 backbone on 6 transfer learning benchmarks. We observe that no modeling pipeline uniformly outperforms others on all benchmarks, which suggests that our benchmark suite can be used for model selection in new downstream tasks. Overall, we found that transfer learning benchmarks involving label shift (e.g., a0-A4-C/a1-A4-C and a0-A4-C/a2-A4-C) are more difficult than benchmarks involving shift in data sets or views. Benchmarks that involved label shifts also exhibited larger variance in the observed performance of the different modeling baselines.
+
+Table 3: Performance of different segmentation heads on cardiac structure identification benchmarks. In all experiments, we use 32 training examples in the target task. All baselines use ResNet-50 backbone as the encoder architecture. Reported numbers are DICE scores on a test set; bold values correspond to best performing baseline.
+
+| Representation | Weights | ETAB score | Representation | Weights | ETAB score |
| MobileNet-V2 | ImageNet-1K | 0.783 | PoolFormer-S24 | ImageNet-1K | 0.692 |
| ResNet-50 | Fully finetuned | 0.769 | MiT-B2 | Fully finetuned | 0.691 |
| MobileNet-V3-Large | Fully finetuned | 0.749 | ResNet-50 | ImageNet-1K | 0.689 |
| ResNet-18 | ImageNet-1K | 0.702 | MiT-B2 | ImageNet-1K | 0.653 |
| ResNet-34 | ImageNet-1K | 0.699 | ConvNext-Base | Fully finetuned | 0.647 |
+
+Table 4: ETAB scores for various backbone representations.
+
+# 4.4 Evaluating pre-trained representations using the ETAB protocol
+
+Finally, we compare various pre-trained backbone representations with respect to their ETAB scores and report the results in Table 4. Here, we evaluate the ETAB scores by tuning the different backbone models to tasks a0-A4-E, a0-A4-C, a0-A2-C, a1-A4-C, and a1-A2-C, with equal weights for all tasks. We explore two variants of each backbone model: freezing the pre-trained ImageNet-1K weights and tuning the head, and fully finetuning the entire model for each benchmark task. The backbone models included CNN architectures (ResNet, MobileNet, ConvNext), as well ViT models (MiT and PoolFormer). Table 4 lists the ETAB scores for all backbone models. A visualization for the break down of the task-specific ETAB scores is available in the online leaderboard.
+
+Overall, we found that the CNN-variants outperformed their ViT counterparts. Moreover, full fine-tuning on the ETAB data sets did not significantly improve the ETAB scores for most backbone models. An interesting use case for our the ETAB framework is to explore whether pre-training backbone representations on large-scale medical imaging data sets, such as RadImageNet [41], could outperform the ImageNet-pretrained backbone with respect to the ETAB score.
+
+# 5 Conclusion
+
+Deep learning can help automate the echocardiography workflow and refine our understanding of heart disease subtypes using cardiac ultrasound data. The scarcity and sporadicity of publicly accessible echocardiogram data sets create a need for standardized benchmarks in order to encourage engagement in research applying state-of-the-art representation learning methods to echocardiographic data. This paper takes a first step towards building a standardized framework for benchmarking the quality of representations for echocardiograms. We hope that the benchmark tasks and evaluation methods presented in this paper will lower the barrier to translating advances in visual representation learning into impactful applications in the medical domain.
+
+# Acknowledgments and Disclosure of Funding
+
+Funding to support this research was provided for by the Eric and Wendy Schmidt Center at the Broad Institute of MIT and Harvard (https://www.broadinstitute.org/ewsc.).
+
+# References
+
+[1] Robert R Moss, Emma Ivens, Sanjeevan Pasupati, Karin Humphries, Christopher R Thompson, Brad Munt, Ajay Sinhal, and John G Webb. Role of echocardiography in percutaneous aortic valve implantation. JACC: Cardiovascular Imaging, 1(1):15-24, 2008.
+[2] G Habib and A Torbicki. The role of echocardiography in the diagnosis and management of patients with pulmonary hypertension. European Respiratory Review, 19(118):288-299, 2010.
+[3] Jennifer Liu, Jose Banchs, Negareh Mousavi, Juan Carlos Plana, Marielle Scherrer-Crosbie, Paaladinesh Thavendiranathan, and Ana Barac. Contemporary role of echocardiography for clinical decision making in patients during and after cancer therapy. JACC: Cardiovascular Imaging, 11(8):1122-1131, 2018.
+[4] Guy R Randolph, Donald J Hagler, Heidi M Connolly, Joseph A Dearani, Francisco J Puga, Gordon K Danielson, Martin D Abel, V Shane Pankratz, and Patrick W O'Leary. Intraoperative transesophageal echocardiography during surgery for congenital heart defects. The Journal of Thoracic and Cardiovascular Surgery, 124(6):1176-1182, 2002.
+[5] Meredith K Ford, W Scott Beattie, and Duminda N Wijeysundera. Systematic review: prediction of perioperative cardiac complications and mortality by the revised cardiac risk index. Annals of internal medicine, 152(1):26-35, 2010.
+[6] Raphael Rosenhek, Ursula Klaar, Michael Schemper, Christine Scholten, Maria Heger, Harald Gabriel, Thomas Binder, Gerald Maurer, and Helmut Baumgartner. Mild and moderate aortic stenosis: natural history and risk stratification by echocardiography. European Heart Journal, 25(3):199-205, 2004.
+[7] David Ouyang, Bryan He, Amirata Ghorbani, Neal Yuan, Joseph Ebinger, Curtis P Langlotz, Paul A Heidenreich, Robert A Harrington, David H Liang, Euan A Ashley, et al. Video-based ai for beat-to-beat assessment of cardiac function. Nature, 580(7802):252-256, 2020.
+[8] Grant Duffy, Paul P Cheng, Neal Yuan, Bryan He, Alan C Kwan, Matthew J Shun-Shin, Kevin M Alexander, Joseph Ebinger, Matthew P Lungren, Florian Rader, et al. High-throughput precision phenotyping of left ventricular hypertrophy with cardiovascular deep learning. *JAMA* cardiology, 7(4):386-395, 2022.
+[9] KY Esther Leung and Johan G Bosch. Automated border detection in three-dimensional echocardiography: principles and promises. European journal of echocardiography, 11(2):97-108, 2010.
+[10] Sumeet Gandhi, Wassim Mosleh, Joshua Shen, and Chi-Ming Chow. Automation, machine learning, and artificial intelligence in echocardiography: a brave new world. *Echocardiography*, 35(9):1402-1418, 2018.
+[11] Sukrit Narula, Khader Shameer, Alaa Mabrouk Salem Omar, Joel T Dudley, and Partho P Sengupta. Machine-learning algorithms to automate morphological and functional assessments in 2d echocardiography. Journal of the American College of Cardiology, 68(21):2287-2295, 2016.
+
+[12] Manar D Samad, Alvaro Ulloa, Gregory J Wehner, Linyuan Jing, Dustin Hartzel, Christopher W Good, Brent A Williams, Christopher M Haggerty, and Brandon K Fornwalt. Predicting survival from large echocardiography and electronic health record datasets: optimization with machine learning. JACC: Cardiovascular Imaging, 12(4):681-689, 2019.
+[13] Kenya Kusunose, Akihiro Haga, Takashi Abe, and Masataka Sata. Utilization of artificial intelligence in echocardiography. Circulation Journal, pages CJ-19, 2019.
+[14] Federico M Asch, Theodore Abraham, Madeline Jankowski, Jayne Cleve, Mike Adams, Nathanael Romano, Nicolas Polivert, Ha Hong, and Roberto Lang. Accuracy and reproducibility of a novel artificial intelligence deep learning-based algorithm for automated calculation of ejection fraction in echocardiography. Journal of the American College of Cardiology, 73(9S1):1447-1447, 2019.
+[15] David Ouyang, Bryan He, Amirata Ghorbani, Matt P Lungren, Euan A Ashley, David H Liang, and James Y Zou. Echonet-dynamic: a large new cardiac motion video data resource for medical machine learning. In NeurIPS ML4H Workshop: Vancouver, BC, Canada, 2019.
+[16] Sarah Leclerc, Erik Smistad, Joao Pedrosa, Andreas Østvik, Frederic Cervenansky, Florian Espinosa, Torvald Espeland, Erik Andreas Rye Berg, Pierre-Marc Jodoin, Thomas Grenier, et al. Deep learning for segmentation using an open large-scale dataset in 2d echocardiography. IEEE transactions on medical imaging, 38(9):2198-2210, 2019.
+[17] Zhe Huang, Gary Long, Benjamin Wessler, and Michael C Hughes. A new semi-supervised learning benchmark for classifying view and diagnosing aortic stenosis from echocardiograms. In Machine Learning for Healthcare Conference, pages 614-647. PMLR, 2021.
+[18] Fuzhen Zhuang, Zhiyuan Qi, Keyu Duan, Dongbo Xi, Yongchun Zhu, Hengshu Zhu, Hui Xiong, and Qing He. A comprehensive survey on transfer learning. Proceedings of the IEEE, 109(1):43-76, 2020.
+[19] Xiaohua Zhai, Joan Puigcerver, Alexander Kolesnikov, Pierre Ruyssen, Carlos Riquelme, Mario Lucic, Josip Djolonga, Andre Susano Pinto, Maxim Neumann, Alexey Dosovitskiy, et al. The visual task adaptation benchmark. 2019.
+[20] Xiaohua Zhai, Joan Puigcerver, Alexander Kolesnikov, Pierre Ruyssen, Carlos Riquelme, Mario Lucic, Josip Djolonga, Andre Susano Pinto, Maxim Neumann, Alexey Dosovitskiy, et al. A large-scale study of representation learning with the visual task adaptation benchmark. arXiv preprint arXiv:1910.04867, 2019.
+[21] James P Howard, Catherine C Stowell, Graham D Cole, Kajaluxy Ananthan, Camelia D Demetrescu, Keith Pearce, Ronak Rajani, Jobanpreet Sehmi, Kavitha Vimalesvaran, G Sunthar Kanaganayagam, et al. Automated left ventricular dimension assessment using artificial intelligence developed and validated by a uk-wide collaborative. Circulation: Cardiovascular Imaging, 14(5):e011951, 2021.
+[22] 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, pages 770-778, 2016.
+[23] Saining Xie, Ross Girshick, Piotr Dólar, Zhuowen Tu, and Kaiming He. Aggregated residual transformations for deep neural networks. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 1492-1500, 2017.
+[24] Forrest Iandola, Matt Moskewicz, Sergey Karayev, Ross Girshick, Trevor Darrell, and Kurt Keutzer. Densenet: Implementing efficient convnet descriptor pyramids. arXiv preprint arXiv:1404.1869, 2014.
+[25] Christian Szegedy, Vincent Vanhoucke, Sergey Ioffe, Jon Shlens, and Zbigniew Wojna. Rethinking the inception architecture for computer vision. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 2818-2826, 2016.
+[26] Andrew Howard, Mark Sandler, Grace Chu, Liang-Chieh Chen, Bo Chen, Mingxing Tan, Weijun Wang, Yukun Zhu, Ruoming Pang, Vijay Vasudevan, et al. Searching for mobilenetv3. In Proceedings of the IEEE/CVF international conference on computer vision, pages 1314-1324, 2019.
+[27] Zhuang Liu, Hanzi Mao, Chao-Yuan Wu, Christoph Feichtenhofer, Trevor Darrell, and Saining Xie. A convnet for the 2020s. arXiv preprint arXiv:2201.03545, 2022.
+
+[28] Enze Xie, Wenhai Wang, Zhiding Yu, Anima Anandkumar, Jose M Alvarez, and Ping Luo. Segformer: Simple and efficient design for semantic segmentation with transformers. Advances in Neural Information Processing Systems, 34, 2021.
+[29] Wenhai Wang, Enze Xie, Xiang Li, Deng-Ping Fan, Kaitao Song, Ding Liang, Tong Lu, Ping Luo, and Ling Shao. Pvt v2: Improved baselines with pyramid vision transformer. Computational Visual Media, 8(3):415-424, 2022.
+[30] Qinglong Zhang and Yu-Bin Yang. Rest: An efficient transformer for visual recognition. Advances in Neural Information Processing Systems, 34:15475-15485, 2021.
+[31] Weihao Yu, Mi Luo, Pan Zhou, Chenyang Si, Yichen Zhou, Xinchao Wang, Jiashi Feng, and Shuicheng Yan. Metaformer is actually what you need for vision. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 10819-10829, 2022.
+[32] Kunchang Li, Yali Wang, Junhao Zhang, Peng Gao, Guanglu Song, Yu Liu, Hongsheng Li, and Yu Qiao. Uniformer: Unifying convolution and self-attention for visual recognition. arXiv preprint arXiv:2201.09450, 2022.
+[33] Olaf Ronneberger, Philipp Fischer, and Thomas Brox. U-net: Convolutional networks for biomedical image segmentation. In International Conference on Medical image computing and computer-assisted intervention, pages 234-241. Springer, 2015.
+[34] Zongwei Zhou, Md Mahfuzur Rahman Siddiquee, Nima Tajbakhsh, and Jianming Liang. Unet++: A nested u-net architecture for medical image segmentation. In Deep learning in medical image analysis and multimodal learning for clinical decision support, pages 3-11. Springer, 2018.
+[35] Tongle Fan, Guanglei Wang, Yan Li, and Hongrui Wang. Ma-net: A multi-scale attention network for liver and tumor segmentation. IEEE Access, 8:179656-179665, 2020.
+[36] Abhishek Chaurasia and Eugenio Culurciello. Linknet: Exploiting encoder representations for efficient semantic segmentation. In 2017 IEEE Visual Communications and Image Processing (VCIP), pages 1-4. IEEE, 2017.
+[37] Hengshuang Zhao, Jianping Shi, Xiaojuan Qi, Xiaogang Wang, and Jiaya Jia. Pyramid scene parsing network. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 2881-2890, 2017.
+[38] Liang-Chieh Chen, George Papandreou, Florian Schroff, and Hartwig Adam. Rethinking atrous convolution for semantic image segmentation. arXiv preprint arXiv:1706.05587, 2017.
+[39] Shusil Dangi, Ziv Yaniv, and Cristian A Linte. Left ventricle segmentation and quantification from cardiac cine mr images via multi-task learning. In International Workshop on Statistical Atlases and Computational Models of the Heart, pages 21-31. Springer, 2018.
+[40] Phong T Lee, Marc R Dweck, Sparsh Prasher, Anoop Shah, Steve E Humphries, Dudley J Pennell, Hugh E Montgomery, and John R Payne. Left ventricular wall thickness and the presence of asymmetric hypertrophy in healthy young army recruits: data from the large heart study. Circulation: Cardiovascular Imaging, 6(2):262-267, 2013.
+[41] Xueyan Mei, Zelong Liu, Philip M Robson, Brett Marinelli, Mingqian Huang, Amish Doshi, Adam Jacobi, Chendi Cao, Katherine E Link, Thomas Yang, et al. Radimagenet: An open radiologic deep learning research dataset for effective transfer learning. Radiology: Artificial Intelligence, 4(5):e210315, 2022.
\ No newline at end of file
diff --git a/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/images.zip b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..1f9e494cfa12e5b25417da06544d0c1a3c897982
--- /dev/null
+++ b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:173839ad6f35e72c6c0abc62f3005cc84dccd0b15f609d49700472c9857005de
+size 516583
diff --git a/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/layout.json b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..547b52200d3190850eff44311071197765ceed80
--- /dev/null
+++ b/etababenchmarksuiteforvisualrepresentationlearninginechocardiography/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:08f0b2fc14d911dfc3b3a33db968bfc0857481c3e60fa346c3b6cc4600d4af2d
+size 304132
diff --git a/eznasevolvingzerocostproxiesforneuralarchitecturescoring/6e09771b-cf01-4d07-9e47-2fdd9014dca5_content_list.json b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/6e09771b-cf01-4d07-9e47-2fdd9014dca5_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..62595274dab1a27a04fb7fbd9b86f5b5d807350f
--- /dev/null
+++ b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/6e09771b-cf01-4d07-9e47-2fdd9014dca5_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:861f4fc17262238be6be1ffb85d46b1f04aceac29c3c49ca57976d34bc6d1b62
+size 66632
diff --git a/eznasevolvingzerocostproxiesforneuralarchitecturescoring/6e09771b-cf01-4d07-9e47-2fdd9014dca5_model.json b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/6e09771b-cf01-4d07-9e47-2fdd9014dca5_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..75ef0e69b344c0d34b67fe601046d58bbbe3f179
--- /dev/null
+++ b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/6e09771b-cf01-4d07-9e47-2fdd9014dca5_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9d8ce26e85ab739ac844e399215f7e873879fa59008837e223a306c644f0edcc
+size 82491
diff --git a/eznasevolvingzerocostproxiesforneuralarchitecturescoring/6e09771b-cf01-4d07-9e47-2fdd9014dca5_origin.pdf b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/6e09771b-cf01-4d07-9e47-2fdd9014dca5_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..36767bb3a340d1162ce023032be76f417a3146a9
--- /dev/null
+++ b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/6e09771b-cf01-4d07-9e47-2fdd9014dca5_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e02b867fd8280e6a2a8a475399d06feaad2c5fe33386b022b9cf61804c962f55
+size 1904051
diff --git a/eznasevolvingzerocostproxiesforneuralarchitecturescoring/full.md b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..54a9d22e350fa4234ec413353ae7f037ce9e5036
--- /dev/null
+++ b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/full.md
@@ -0,0 +1,272 @@
+# EZNAS: Evolving Zero-Cost Proxies For Neural Architecture Scoring
+
+Yash Akhauri1 J. Pablo Muñoz2 Nilesh Jain2 Ravi Iyer2
+
+$^{1}$ Cornell University $^{2}$ Intel Labs
+
+ya255@cornell.edu
+
+{pablo.munoz,nilesh.jain,ravishanker.iyer}@intel.com
+
+# Abstract
+
+Neural Architecture Search (NAS) has significantly improved productivity in the design and deployment of neural networks (NN). As NAS typically evaluates multiple models by training them partially or completely, the improved productivity comes at the cost of significant carbon footprint. To alleviate this expensive training routine, zero-shot/cost proxies analyze an NN at initialization to generate a score, which correlates highly with its true accuracy. Zero-cost proxies are currently designed by experts conducting multiple cycles of empirical testing on possible algorithms, datasets, and neural architecture design spaces. This experimentation lowers productivity and is an unsustainable approach towards zero-cost proxy design as deep learning use-cases diversify in nature. Additionally, existing zero-cost proxies fail to generalize across neural architecture design spaces. In this paper, we propose a genetic programming framework to automate the discovery of zero-cost proxies for neural architecture scoring. Our methodology efficiently discovers an interpretable and generalizable zero-cost proxy that gives state of the art score-accuracy correlation on all datasets and search spaces of NASBench201 and Network Design Spaces (NDS). We believe that this research indicates a promising direction towards automatically discovering zero-cost proxies that can work across network architecture design spaces, datasets, and tasks.
+
+# 1 Introduction
+
+The manual trial-and-error method of designing neural network architectures and assessing whether it meets performance and accuracy requirements is not scalable to complex neural architecture design spaces and hardware deployment scenarios. Neural Architecture Search is intended to address this problem of iterative and expensive design by automating the search of neural network architectures. Enabling such automation requires accurate and efficient prediction of the accuracy of candidate neural network architectures. The process of predicting the accuracy often involves partial or complete training of many neural network architectures in the search space. Such methods are infeasible for very large architecture design spaces, as considerable sampling and training of neural networks would be required to sufficiently describe the entire design space. Popular NAS techniques often involve generating and training neural network architectures and using this accuracy to train accuracy predictors to serve as feedback in the search algorithm. This architecture generation and feedback methodology can be leveraged by algorithms such as reinforcement learning (Luo et al. [2019]) and evolutionary algorithms (Real et al. [2019]). One-shot methods (Cai et al. [2019, 2020], Xie et al. [2020], Yang et al. [2020], Liu et al. [2019]) maintain a super-network, from which sub-networks are sampled. The weights are shared between the sub-networks which reduces NAS cost as there are lesser parameters to train.
+
+The primary challenge of Neural Architecture Search is the evaluation of candidate architectures, which can take hours to days to estimate (Abdelfattah et al. [2021]). Further, practical deployment of neural networks is no longer limited to accuracy-oriented neural architecture design. The need for efficient deployment has given rise to significant literature in co-design of hardware and neural network architectures (Choi et al. [2021], Akhauri et al. [2021], Zhang et al. [2020]). However, hardware performance metrics in such co-design tasks are often non-differentiable in nature due to factors such as memory access patterns and cache hierarchy. The interaction between the workload and the hardware makes this optimization problem significantly more complex, and being able to score neural network architectures without the expensive training step would allow for the development of more efficient co-design algorithms.
+
+Most zero-cost proxies utilize a single minibatch of data and a single forward/backward propagation pass to score a neural network (Abdelfattah et al. [2021]). We refer to algorithms that score neural network architectures without training as Zero-Cost Neural Architecture Scoring Metrics (ZC-NASM). Design of existing ZC-NASMs are driven by human intuition or are theoretically inspired. These algorithms attempt to quantify the trainability and expressivity of neural networks. The primary hurdle with existing ZC-NASM design is that they are not generalizable to different neural architecture design spaces.
+
+In this paper, we introduce a genetic programming driven methodology to automatically discover ZC-NASMs that are interpretable, generalizable and deliver state of the art score-accuracy correlation. We refer to our method as EZNAS (Evolutionarily Generated Zero-Cost Neural Architecture Scoring Metric). Our approach is:
+
+- Interpretable: We discover ZC-NASMs as expression trees that explicitly indicate which NN features and mathematical operations are being utilized.
+- Generalizable: The ZC-NASM discovered by EZNAS delivers SoTA score-accuracy correlation on unseen neural architecture design spaces and datasets (NASBench-201, NDS & NATS-Bench). Our framework utilizes simple mathematical operations and an expression tree structure that can be trivially extended to implement arbitrarily complex ZC-NASMs
+- Efficient: We are able to discover our SoTA ZC-NASM on an Intel(R) Xeon(R) Gold 6242 CPU in under 24 hours. This requires $12.5 \times$ lesser CO2e than a NAS search. Our ZC-NASM is generalizable to multiple design spaces, increasing the end-to-end efficiency of NN architecture search by over two orders of magnitude.
+
+# 2 Related Work
+
+Neural Architecture Search (NAS) was proposed to reduce the human effort that goes into manually designing complex neural network architectures. Early efforts in the field of NAS adopted brute force methods by training candidate architectures and using the obtained accuracy as a proxy to discover better architectures. AmoebaNet (Real et al. [2019]) utilized evolutionary algorithms (EA) and 3150 GPU days of compute to achieve $74.5\%$ top-1 accuracy on the ImageNet dataset. Many EA and Reinforcement Learning (RL) driven methods have since significantly improved the efficiency of the search process (Yang et al. [2020], Liu et al. [2018], Tan et al. [2019], Zoph et al. [2018]). These methods often require sampling and training of several candidate architectures. One-shot (Hu et al. [2020], Xie et al. [2020], Cai et al. [2019]) methods of NAS do not require training of candidate architectures to completion, but train large super-networks and identify sub-networks that can give high accuracy. Such super-networks can be generated automatically from pre-trained models (Muñoz et al. [2021]). These improvements have significantly reduced the cost of NAS. However, as the search space continues to get larger with new architectural innovations, we need more efficient methods to predict the accuracy of neural networks in intractably large design spaces.
+
+Zero-Cost Neural Architecture Scoring is a promising paradigm which explores zero-cost proxies for estimating the true accuracy of neural networks. The majority of research in this field introduces novel methods of scoring neural networks at initialization along with a theoretical or intuitive explanation of their scoring strategy. For instance, (Abdelfattah et al. [2021]) empirically studies metrics such as synflow, SNIP and FISHER. Figure 2 depicts the expression tree representations of these metrics. NASWOT (Mellor et al. [2021]) works by treating the output of each layer as a binary
+
+
+Figure 1: (A): Collecting neural network statistics for the ZC-NASM. The $\mathcal{D}$ input tensor represents a single mini-batch from the dataset serving as input to the neural network. $\mathcal{N}$ represents a randomly initialized noise tensor. $\mathcal{P}$ represents an input to the neural network which is a data-sample perturbed by noise. NN statistics are collected for each of the $\mathcal{D}$ , $\mathcal{N}$ and $\mathcal{P}$ inputs. (B): The ZC-NASM is applied to each ReLU-Conv2D-BatchNorm2D (RCB) instance of the neural network. The ZC-NASM has 22 tensors available to it as arguments in each RGB instance, generated by collecting intermediate tensors of the neural network for the three types of input $(\mathcal{D},\mathcal{N},\mathcal{P})$ . The ZC-NASM depicted above only utilizes 2 intermediate tensors $(T3$ and $T4G_{P})$ in each layer to generate a score.
+
+indicator (zero if value is negative, one if value is positive) and using the hamming distance between two binary codes induced by an untrained network from two inputs as a measure of dissimilarity. The intuition here is that the more similar two inputs are, the more challenging it is for the network to learn how to separate them. Works like TENAS (Chen et al. [2021]), GradSign (Zhang and Jia [2021]) create proxies for trainability & expressivity of neural networks to rank them.
+
+Program Synthesis: Program synthesis is the task of automatically discovering programs that satisfy user constraints. AutoML-Zero (Real et al. [2020]) evolves entire machine learning algorithms from scratch with little restrictions on form and using only simple mathematical operations. The algorithms are learnt symbolically, representing programs as a sequence of instructions. We posit that the current endeavor of identifying fundamental architectural properties that correlate strongly with testing accuracy can benefit from a methodology that minimizes human bias and intervention in a similar fashion. This stems from the observation that majority of the existing ZC-NASMs can be represented as simple programs that utilize the neural network statistics as inputs which can be discovered with genetic programming
+
+
+Figure 2: Expression tree representation of existing ZC-NASMs. $T3G_{D}$ represents the Conv2D weight gradient for a mini-batch of data, $T3_{D}$ represents the weights of Conv2D. $T4G_{D}$ represents the activation gradient and $T4_{D}$ represents the corresponding activation. $T3G_{N}$ represents the Conv2D weight gradient for a mini-batch of random noisy tensor, $T3_{N}$ represents the weights of Conv2D. Each program is applied to all layers of the neural network, and the output is aggregated to generate the final score. Further details of this program representation is explained later.
+
+
+
+
+
+# 3 Evolutionary Framework
+
+EZNAS uses evolutionary search to discover programs that can score neural network architectures such that it correlates highly with accuracy. In this section, we detail the specifics of how ZC-NASM programs are constructed, evaluated and evolved with EZNAS.
+
+# 3.1 Program Representation
+
+Each individual ZC-NASM has to be evaluated on tens of gigabytes of tensors of NN architectures with no approximations to generate precise ZC-NASM score-accuracy correlation to serve as the measure of fitness. To make such search computationally tractable, it is crucial to not introduce redundant operations in the program. Our initial attempt described in the appendix resembled that of AutoML-Zero (Real et al. [2020]) where ZC-NASMs were represented as a sequence of instructions and a memory space to store intermediate tensors. This led to discovery of ZC-NASMs with many redundant computations due to program length bloating and an intractably large run
+
+Algorithm 1 EZNAS Search Algorithm
+1: evol_space = [NN1,enas, NN2,enas,... NNN,enas]
+2: population = gen_random_valid_population(n)
+3: # Evaluate and assign fitness over evol_space.
+4: population = evaluate(population)
+5: for gen=1:T do
+6: offspring = []
+7: while len(offspring) < \lfloor n/2 \rfloor do
+8: # Variation Function
+9: children = VarOr(population)
+10: offspring.append(selectValid(children))
+11: new_c = gen_random_valid_population(\lfloor n/2 \rfloor)
+12: offspring.append(new_c)
+13: population = evaluate(offspring)
+
+time. To reduce the complexity of search, we necessitate a expression tree structure on the ZC-NASM program to capture the executional ordering of the program. The program output appears at a root node, and the child (terminal) nodes are the arguments of the expression tree. These arguments are the network statistics. The advantage of this program representation is that there is only a single root node with dense connectivity from the root to the terminal nodes, leading to fewer redundancies.
+
+# 3.2 Neural Network Statistics Generation
+
+Each ZC-NASM requires a set of arguments as inputs. These arguments are the intermediate tensors of the neural network. As depicted in Figure 1, for any sampled neural network from the NDS or NASBench-201 spaces, we identify every ReLU-Conv2D-BatchNorm2D (RCB) instance at initialization, and register the activations, weights and the corresponding gradients for three types of network inputs (a mini-batch of data $(\mathcal{D})$ , a random noisy tensor $(\mathcal{N})$ , and a mini-batch of data perturbed by random noise $(\mathcal{P}))$ .
+
+We collect $T1_{\{D,N,P\}}$ , $T2_{\{D,N,P\}}$ , $T3$ , $T4_{\{D,N,P\}}$ (10 tensors) and $T1G_{\{D,N,P\}}$ , $T2G_{\{D,N,P\}}$ , $T3G_{\{D,N,P\}}$ , $T4G_{\{D,N,P\}}$ (12 tensors) from each RCB instance. T3 represents the Conv2D weights and does not change for the network input type, thus giving us 22 tensors for each RCB instance. We present an alternate formulation by identifying Conv2D-BatchNorm2D-ReLU (CBR) instance for network statistics generation to demonstrate that the evolutionary framework is not restricted to a RCB structure in the appendix.
+
+# 3.3 Mathematical Operations
+
+The expression tree describes the execution order of the mathematical operations available to us. It is crucial to provide a varied set of operations to process the neural network statistics effectively. We provide 34 unique operations in our program search space. We include basic mathematical operations (Addition, Product) as well as some advanced operations such as Cosine Similarity and Hamming Distance. We provide the full list of mathematical operations in the supplementary material.
+
+# 3.4 Program Application
+
+Majority of the neural network architectures available in NASBench-201 and NDS have over 100 instances of ReLU-Conv2D-BatchNorm2D. This may mean that an expression tree would have as many as $2200(22\times 100)$ possible arguments (terminal nodes), each of which can be used multiple times. This would result in a computationally intractable expression tree. To simplify the search problem, we generate a single expression tree with 22 possible inputs. It is not necessary that the root node of an expression tree would give a scalar value, so we add a to Scalar operation above the root node of the expression tree. As seen in Figure 1 the expression tree is then applied on every ReLU-Conv2D-BatchNorm2D instance and the output is aggregated across all instances using an aggregation_function. This serves as the 'score' of the sampled neural network architecture. In EZNAS-A, the aggregation_function and toScalar are both mean. In the appendix, we explore L2-Norm as a toScalar function as well and find that we are able to discover effective ZC-NASMs.
+
+# 3.5 Evolutionary Algorithm
+
+Our search algorithm discovers programs by modifying the expression tree representation of the population by variation-functions. A fitness score is generated for every expression tree in the population at each generation. The variation_function (VarOr) is then used to generate new offspring. We describe our search algorithm in Algorithm 1
+
+# 3.5.1 Population Initialization
+
+We initialize a population of n programs. We do not impose any restrictions on the operations the nodes can use in the expression tree. Due to this, the number of valid expression trees is several orders of magnitude lesser than the total number of expression trees that can be generated with our
+
+
+Figure 3: Variation of expression trees every generation. The x signs denote point of cross-over or mutation.
+
+mathematical operators and network statistics. To increase search efficiency, we would like to ensure that we sample and evolve only valid expression trees. To enable this, we ensure that all individuals in the population are valid programs by testing program execution on a small sub-set of network statistics data. All programs that produce outputs with inf, nan or fail to execute are replaced by new randomly initialized valid programs.
+
+# 3.5.2 Fitness Objective
+
+As the goal of zero-cost NAS is to be able to rank neural network architectures well, we utilize the Kendall Tau rank correlation coefficient as the fitness objective. The search objective is to maximize the Kendall Tau rank correlation coefficient between the scores generated by a program and the test accuracy of the neural networks in the evol_space.
+
+# 3.5.3 Variation Algorithms
+
+In our tests, we utilize the VarOr implementation from Distributed Evolutionary Algorithms in Python (DEAP) (Fortin et al. [2012]) framework for the variation of individual programs. We generate $n$ (hyper-parameter) offspring programs at each generation. $\lfloor n / 2 \rfloor$ offspring are generated as a result of three operations; crossover, mutation or reproduction. These variations are depicted in Figure 3. For crossover, two individual programs are randomly selected from the population and mated. Our mating function randomly selects a crossover point from each individual and exchanges the sub-trees with the selected point as root between each individual. The first child is appended to the offspring population. For mutation, we randomly select a point in the individual program, and replace the sub-tree at that point by a randomly generated expression tree. We repeat the variation algorithm on the population till $\lfloor n / 2 \rfloor$ valid individuals are generated. To encourage diversity, we also randomly generate $\lfloor n / 2 \rfloor$ valid individuals. We have placed static limits on the depth of all expression trees at 10.
+
+# 3.6 Program Evaluation Methodology
+
+At each generation, the fitness of the entire population is invalidated and recalculated. Calculating the fitness of each program on the entire dataset (which can be approximately 1 TB) is computationally infeasible. Further, we may want to find generalized programs that give high fitness on many different architecture design spaces and datasets. This would translate to evaluating each individual on over 7 TB of data on the NDS and NASBench-201 search spaces.
+
+Reducing the computation by evaluating the fitness of the population on a single small fixed sub-set of neural networks from the search space causes discovered programs to trivially over-fit to the sub-set statistics in our tests. To address over-fitting of programs to small datasets of network statistics while minimizing compute resources required for evaluating on the entire dataset of network statistics, we generate an evolution task dataset. This is generated by randomly sampling 80 neural networks
+
+SPEARMAN $\rho$ CF10 CF100 IN16-120
+
+| EZNAS-A | 0.83 | 0.82 | 0.78 |
| synflow | 0.74 | 0.76 | 0.75 |
| jacob_cov | 0.73 | 0.71 | 0.71 |
| FLOPs | 0.75 | 0.72 | 0.69 |
| Params | 0.75 | 0.72 | 0.69 |
| grad_norm | 0.58 | 0.64 | 0.58 |
| snip | 0.58 | 0.63 | 0.58 |
| grasp | 0.48 | 0.54 | 0.56 |
| fisher | 0.36 | 0.39 | 0.33 |
+
+Table 1: Spearman $\rho$ for NASBench-201.
+
+| SPEARMAN ρ | CF10 | CF100 | IN16-120 |
| EZNAS-A | 0.89 | 0.74 | 0.81 |
| NASWOT | 0.45 | 0.18 | 0.41 |
+
+Table 2: Spearman $\rho$ for NATS-BenchSSS.
+
+| KENDALL τ | CF10 | CF100 | IN16-120 |
| EZNAS-A | 0.65 | 0.65 | 0.61 |
| NASWOT | 0.57 | 0.61 | 0.55 |
| AngleNAS | 0.57 | 0.60 | 0.54 |
| FLOPs | 0.56 | 0.54 | 0.50 |
| Params | 0.56 | 0.54 | 0.50 |
+
+Table 3: Kendall $\tau$ for NASBench-201.
+
+| KENDALL τ | DARTS | Amoeba | ENAS | PNAS | NASNet |
| EZNAS-A | 0.56 | 0.45 | 0.52 | 0.51 | 0.44 |
| NASWOT | 0.47 | 0.22 | 0.37 | 0.38 | 0.30 |
| grad_norm | 0.28 | -0.1 | -0.02 | -0.01 | -0.08 |
| synflow | 0.37 | -0.06 | 0.02 | 0.03 | -0.03 |
| FLOPs | 0.51 | 0.26 | 0.47 | 0.34 | 0.20 |
| Params | 0.50 | 0.26 | 0.47 | 0.32 | 0.21 |
+
+Table 4: Kendall $\tau$ for NDS CIFAR-10.
+
+from each available search space (NASBench-201 and NDS) and dataset (CIFAR-10, CIFAR-100, ImageNet-16-120). We evaluate individuals by randomly choosing s search spaces, and sampling 20 neural networks from each of the chosen search spaces. We take the minimum fitness achieved by the individual program on the s spaces. We consider s as a hyper-parameter. In our tests, this is consistently kept at 4.
+
+# 3.7 Program Testing Methodology
+
+At the end of the evolutionary search, our primary goal is to test whether the programs discovered are able to provide high fitness on previously unseen neural network architectures. We test the fittest program from our final population as well as the two fittest programs encountered through-out the evolutionary search. At test time, we take the program and find the score-accuracy correlation over 4000 neural network architectures sampled from the NASBench-201 and NDS design spaces.
+
+# 4 Results
+
+As described in Algorithm 1, we search for effective ZC-NASMs on every design space from NDS CIFAR-10 and the NASBench-201 datasets. Each search takes approximately 24 hours on a Intel(R) Xeon(R) Gold 6242 CPU with 1 terabyte of RAM.
+
+We choose the most consistent ZC-NASM (EZNAS-A, discovered by evolving programs on the NDS-DARTS CIFAR-10 search space) from our evolutionary search and compare it with existing ZC-NASMs from recent works. We report both the Kendall $\tau$ rank correlation coefficient and the Spearman $\rho$ rank-order correlation coefficient to fairly compare EZNAS-A with a broad set of ZC-NASMs from recent literature. We provide our Spearman $\rho$ correlation on the NATS-Bench SSS search space and NDS ImageNet design spaces as well.
+
+NASBench-201: We report our scoreaccuracy correlation by scoring all neural
+
+
+Figure 4: Search speedup with EZNAS-A on CIFAR-10 NAS-Bench-201. The average best test accuracy is taken over 10 repeated experiments.
+
+networks in the NASBench-201 design space. As seen in Table 3, we obtain the highest score-accuracy Kendall Tau Ranking Correlation on all datasets. We also benchmark our work against the pruning based saliency metrics formalized in (Abdelfattah et al. [2021]) and find that our program EZNAS-A has the highest Spearman $\rho$ among the ZC-NASMs in Table 1.
+
+NDS: We report our score-accuracy correlation by scoring all neural networks in the NDS design space for the CIFAR-10 dataset and scoring 40 random neural networks over 5 seeds for the ImageNet dataset (Table 5). We find that EZNAS-A has the highest score accuracy Kendall Tau Ranking Correlation on each of the design spaces of NDS CIFAR-10 in Table 4.
+
+NATS-Bench: We report our score-accuracy correlation by scoring 200 randomly sampled neural networks in the NATS-Bench TSS (same as NB-201) and SSS (Dong et al. [2021]) design space averaged over 5 seeds for the CIFAR-10, CIFAR-100 and ImageNet16-120 dataset in Table 2.
+
+Neural Architecture Search Integration: We integrate our ZC-NASMs EZNAS-A with the Aging Evolution (AE) Search algorithm from (Real et al. [2019]). Our evolutionary search discovers a ZC-NASM that is competitive in search efficiency with existing ZC-NASMs in Figure 4.
+
+# 5 Examination Of Best Programs
+
+EZNAS discovers a set of ZC-NASMs at the end of the evolutionary search. In this section, we analyze two of the best ZC-NASMs discovered by our method to give a deeper understanding of the nature of programs. We
+
+| SPEARMAN ρ | DARTS | Amoeba | PNAS | ENAS | NASNet |
| EZNAS-A | 0.70 | 0.58 | 0.43 | 0.43 | 0.31 |
+
+Figure 5: Spearman $\rho$ for NDS ImageNet.
+
+refer to these programs as EZNAS-A and EZNAS-B. For each program, we generate random input tensors of varying sizes and average the ZC-NASM score 5000 times. This is an approximate method to understand how the ZC-NASM responds to change in architectural parameters (kernel size, number of channels, activation size).
+
+EZNAS-A: The evolution task dataset for discovering this program was NDS-DARTS. The input to the ZC-NASM in Figure 6 is the $T3G_N$ (Weight Gradient with Random Noise Input) tensor. We find that the score increases as the number of channels or depth increases, we also observe that kernel sizes of 1 and 7 give higher scores than 3 and 5 with the lowest score being assigned to kernel of size 3. It is interesting to see that the expectation value of EZNAS-A in Figure 6 translates to a weighted form of parameter counting, with a non-linear monotonically increasing scaling of score with the number of input/output channels and a locally parabolic relationship between the score and the kernel size with the minimum score at kernel size of 3.
+
+EZNAS-B: The evolution task dataset for discovering this program was NDS-ENAS. The input to the ZC-NASM in Figure 6 is $T1G_{P}$ (Difference in pre-activation gradients for a noise perturbed data mini-batch). We find that the activation map size is exponentially more influential to the score when compared to the number of channels.
+
+Through this analysis, we see that EZNAS-A & EZNAS-B generate a score which is correlated with the activation or weight sizes. It is interesting to note that when compared to ZC-NASMs from recent literature, this form of weighted parameter counting works more consistently. This is supported by our finding that FLOPs and Params are more generalizable than ZC-NASMs which work on the NASBench-201 space but fail on the NDS space.
+
+# 6 Discussion and Future Work
+
+With the EZNAS formulation, we discover effective ZC-NASMs which generalize across design spaces and datasets, as well as give SoTA score-accuracy correlation. This is a promising new direction, but there is much work to be done. In this section, we discuss the current limitations of EZNAS with scope for future work.
+
+Program Design: To simplify the search problem, we take a mean (aggregation_function) of the scores generated across all ReLU-Conv2D-BatchNorm2D instances. This formulation does not take layer connectivity patterns into account explicitly. Extending our evolutionary
+
+
+Figure 6: (Left) Analysis of our best program (EZNAS-A) on the Image Classification task. toscalar is not required as the output is already a scalar. (Right) Analysis of our second best program (EZNAS-B) on the Image Classification task.
+
+search to take into account the global connectivity pattern of the neural networks or learning weighted averaging techniques for the individual layer (RCB instance) scores could help us discover better ZC-NASMs. Further, we impose structural restrictions on our program by necessitating a fixed structure (ReLU-Conv2D-BatchNorm2D). We have to truncate instances of ReLU-Conv2D-Conv2D-BatchNorm2D from the NDS space by ignoring the second convolution. As more diverse architectures are introduced in the field, we must re-formulate collection of network statistics in a more robust manner. Note that NASWOT measures the similarity in the binary codes generated from the ReLU units for two different inputs. Our program design limits us to only using a single mini-batch of inputs and does not compare inputs directly. Thus, we would not be able to discover the NASWOT ZC-NASM metric with our approach. Fortunately, integrating such functionality into the program design space is feasible and is an interesting line of future work to generate more complex metrics.
+
+It is also important to have a robust and diverse set of mathematical operations to discover effective ZC-NASMs. We utilize 34 mathematical operations inspired by AutoML-Zero (Real et al. [2020]) and operations found in existing ZC-NASMs. None of our operations or network statistics generation have any scalar hyper parameters. For example, the Power operation is fixed to do an element-wise square, and the noise generation for input tensor is fixed to $\mathcal{N}(0,1)$ . Optimizing these values dynamically and ensuring a sufficiently diverse set of operations may enable discovery of better ZC-NASMs.
+
+Network Statistics: Due to the computational resources required to generate network statistics, we have to pre-compute them and use the generated data as an evolutionary task dataset. We only use network statistics with input batch-size of 1 for evolution. A single sample statistic of a neural network is insufficient to describe the architecture, as evidenced by our increase in score-accuracy correlation with the batch size in Figure 7. Further, from Figure 7 we observe high variance in the fitness of a ZC-NASM when evaluated for multiple seeds with a batch size of 1. Testing over a large number of seeds or increasing the batch-size would cause a linear increase in memory requirement as well as increase in run-time of the evolutionary search.
+
+Ranking Architectures: It is interesting to observe that in the entire neural architecture design space, FLOPs and Params are competitive proxies and sometimes better than many existing ZC-NASMs. A deeper investigation reveals that ranking the top $10\%$ of the neural networks in the design space is a significantly more difficult task. In the top $10\%$ of neural networks, FLOPs and Params are extremely weak proxies. Further, (Abdelfattah et al. [2021]) finds that among their ZC-NASMs, synflow is the only one which is able to serve as a weak correlator for performance in top $10\%$ of the neural networks on the NASBench-201 CIFAR-100 and ImageNet16-120 design spaces. However, synflow is not able to rank networks effective in the top $10\%$ of CIFAR-10 NASBench-201 and the entire NDS design space.
+
+
+Figure 7: (Left) Effect on score-accuracy correlation of EZNAS-A with respect to batch size. This test was done on the NDS PNAS design space over 7 seeds for 400 Neural Networks.(Right) Effect of seed on our score-accuracy correlation of EZNAS-A with a batch size of 1. CIFAR and ImageNet abbreviated as CF and IN respectively. This test was done on each design space over 7 seeds for 400 Neural Networks.
+
+
+
+EZNAS-A is able to rank neural networks robustly across both the NASBench-201 and NDS design spaces, but does not rank the top $10\%$ of neural networks effectively. We discover alternative ZC-NASMs that can weakly rank the top $10\%$ of neural networks, but such ZC-NASMs fail to generalize across neural architecture design search spaces. This ability to identify good architectures but inability to distinguish between the best architectures may be an inherent limitation of ZC-NASMs. Alternatively, improvements to our evolutionary framework may result in robust ZC-NASMs that can rank the top $10\%$ neural networks effectively. This is an interesting research direction and may require creation of more neural architecture design spaces like NASBench-201/NDS which exhibit lower correlation with FLOPs/Params.
+
+Evolutionary Search: In this paper, we introduce an intuitive program representation and appropriate variation methodologies to enable discovery of ZC-NASMs with minimal human intervention. However, recent advances in the field of Neuro-Symbolic Program Synthesis (Parisotto et al. [2017]) to learn mappings from input-output examples (neural network statistics to neural architecture scores) can motivate improvements in our evolutionary search. Further, exploring architecture connectivity encodings (White et al. [2021]) for neural architecture search and discovering programs to rank neural architecture encodings may enable discovery of effective connectivity patterns to enable a deeper understanding of important features in neural architecture design beyond those contained in activations maps and weights.
+
+Efficiency: EZNAS is able to discover a set of ZC-NASMs on a single CPU in under 24 hours, which translates to $358.6\mathrm{g}$ of CO2e (Lannelongue et al. [2020]). In comparison, a single NAS search (assuming 8 GPU days (Zhou et al. [2020])) can take over $4.49\mathrm{kg}$ of CO2e. Recent works integrate their zero-cost proxies with differentiable architecture search (Xiang et al. [2021]) to deliver $40\times$ NAS speed-up. As the architecture design spaces that ZC-NASMs need to be discovered on diversify, the efficiency of our methodology must be improved to scale to larger problems. Seeding the initial population with viable candidates can enable faster discovery of robust ZC-NASMs. The search process can be made more efficient by using lower precision numerical formats, or exploring proxy tasks on smaller datasets (down-sampled image datasets, smaller neural network design architecture etc.).
+
+# 7 Conclusion
+
+In this paper, we present EZNAS, a novel genetic programming driven approach to discover Zero-Cost Neural Architecture Scoring Metrics (ZC-NASMs). The key advantage of EZNAS is that it is an interpretable approach to discover generalizable methods to rank neural networks. Generalizability of a ZC-NASM is crucial for its practical utility, as a robust ZC-NASM should be able to rank NNs in previously unseen neural architecture search spaces.
+
+With our approach, we are able to discover a ZC-NASM (EZNAS-A) which evolved only on the NDS DARTS space, but delivers state of the art score-accuracy correlation across both the NASBench201 and NDS design space. We also demonstrate the generalizability of EZNAS-A by providing extremely strong correlation results on NATS-Bench as well as NDS ImageNet. We demonstrate competitive search efficiency of EZNAS-A by integrating our metric with the Aging Evolution (AE) search algorithm from (Abdelfattah et al. [2021]). Further, we provide an in-depth analysis of the nature of programs we have discovered, along with a detailed account of existing limitations of our methodology to motivate future work in this direction. EZNAS has the potential to reduce human bias in design of ZC-NASMs, and aid in discovery of programs that provide deeper insights into properties that make a neural network perform well.
+
+# References
+
+[1] Mohamed S. Abdelfattah, Abhinav Mehrotra, Lukasz Dudziak, and Nicholas D. Lane. Zero-cost proxies for lightweight nas, 2021.
+[2] Yash Akhauri, Adithya Niranjan, J. Pablo Munoz, Suvadeep Banerjee, Abhijit Davare, Pasquale Cocchini, Anton A. Sorokin, Ravi Iyer, and Nilesh Jain. Rhnas: Realizable hardware and neural architecture search, 2021.
+[3] Han Cai, Ligeng Zhu, and Song Han. Proxylessnas: Direct neural architecture search on target task and hardware, 2019.
+[4] Han Cai, Chuang Gan, Tianzhe Wang, Zhekai Zhang, and Song Han. Once-for-all: Train one network and specialize it for efficient deployment, 2020.
+[5] Wuyang Chen, Xinyu Gong, and Zhangyang Wang. Neural architecture search on imagenet in fourgpu hours: A theoretically inspired perspective, 2021.
+[6] Kanghyun Choi, Deokki Hong, Hojae Yoon, Joonsang Yu, Youngsok Kim, and Jinho Lee. Dance: Differentiable accelerator/network co-exploration, 2021.
+[7] Xuanyi Dong, Lu Liu, Katarzyna Musial, and Bogdan Gabrys. NATS-bench: Benchmarking NAS algorithms for architecture topology and size. IEEE Transactions on Pattern Analysis and Machine Intelligence, pages 1-1, 2021. doi: 10.1109/tpami.2021.3054824. URL https://doi.org/10.1109/ftpami.2021.3054824.
+[8] Félix-Antoine Fortin, François-Michel De Rainville, Marc-André Gardner, Marc Parizeau, and Christian Gagné. DEAP: Evolutionary algorithms made easy. Journal of Machine Learning Research, 13:2171-2175, jul 2012.
+[9] Shoukang Hu, Sirui Xie, Hehui Zheng, Chunxiao Liu, Jianping Shi, Xunying Liu, and Dahua Lin. Dsnas: Direct neural architecture search without parameter retraining, 2020.
+[10] Loic Lannelongue, Jason Grealey, and Michael Inouye. Green algorithms: Quantifying the carbon footprint of computation, 2020.
+[11] Chenxi Liu, Barret Zoph, Maxim Neumann, Jonathon Shlens, Wei Hua, Li-Jia Li, Li Fei-Fei, Alan Yuille, Jonathan Huang, and Kevin Murphy. Progressive neural architecture search, 2018.
+[12] Hanxiao Liu, Karen Simonyan, and Yiming Yang. Darts: Differentiable architecture search, 2019.
+[13] Renqian Luo, Fei Tian, Tao Qin, Enhong Chen, and Tie-Yan Liu. Neural architecture optimization, 2019.
+[14] Joseph Mellor, Jack Turner, Amos Storkey, and Elliot J. Crowley. Neural architecture search without training, 2021.
+[15] J. Pablo Muñoz, Nikolay Lyalyushkin, Yash Akhauri, Anastasia Senina, Alexander Kozlov, and Nilesh Jain. Enabling NAS with automated super-network generation. CoRR, abs/2112.10878, 2021. URL https://arxiv.org/abs/2112.10878.
+[16] Emilio Parisotto, Abdelrahman Mohamed, Rishabh Singh, Lihong Li, Denny Zhou, and Pushmeet Kohli. Neuro-symbolic program synthesis. In 5th International Conference on Learning Representations (ICLR 2017), February 2017. URL https://www.microsoft.com/en-us/research/publication/neuro-symbolic-program-synthesis-2/.
+[17] Esteban Real, Alok Aggarwal, Yanping Huang, and Quoc V Le. Regularized evolution for image classifier architecture search, 2019.
+[18] Esteban Real, Chen Liang, David R. So, and Quoc V. Le. Automl-zero: Evolving machine learning algorithms from scratch, 2020.
+[19] Mingxing Tan, Bo Chen, Ruoming Pang, Vijay Vasudevan, Mark Sandler, Andrew Howard, and Quoc V. Le. Mnasnet: Platform-aware neural architecture search for mobile, 2019.
+
+[20] Colin White, Willie Neiswanger, Sam Nolen, and Yash Savani. A study on encodings for neural architecture search, 2021.
+[21] Lichuan Xiang, Lukasz Dudziak, Mohamed S. Abdelfattah, Thomas Chau, Nicholas D. Lane, and Hongkai Wen. Zero-cost proxies meet differentiable architecture search, 2021.
+[22] Sirui Xie, Hehui Zheng, Chunxiao Liu, and Liang Lin. Snas: Stochastic neural architecture search, 2020.
+[23] Zhaohui Yang, Yunhe Wang, Xinghao Chen, Boxin Shi, Chao Xu, Chunjing Xu, Qi Tian, and Chang Xu. Cars: Continuous evolution for efficient neural architecture search, 2020.
+[24] Yongan Zhang, Yonggan Fu, Weiwen Jiang, Chaojian Li, Haoran You, Meng Li, Vikas Chandra, and Yingyan Lin. Dna: Differentiable network-accelerator co-search, 2020.
+[25] Zhihao Zhang and Zhihao Jia. Gradsign: Model performance inference with theoretical insights. 2021. doi: 10.48550/ARXIV.2110.08616. URL https://arxiv.org/abs/2110.08616.
+[26] Dongzhan Zhou, Xinchi Zhou, Wenwei Zhang, Chen Change Loy, Shuai Yi, Xuesen Zhang, and Wanli Ouyang. Econas: Finding proxies for economical neural architecture search, 2020.
+[27] Barret Zoph, Vijay Vasudevan, Jonathon Shlens, and Quoc V. Le. Learning transferable architectures for scalable image recognition, 2018.
+
+# Checklist
+
+1. For all authors...
+
+(a) Do the main claims made in the abstract and introduction accurately reflect the paper's contributions and scope? [Yes]
+(b) Did you describe the limitations of your work? [Yes]
+(c) Did you discuss any potential negative societal impacts of your work? [No] Our method increases the efficiency of NAS significantly, and is aimed at reducing the negative societal impact of AI.
+(d) Have you read the ethics review guidelines and ensured that your paper conforms to them? [Yes]
+
+2. If you are including theoretical results...
+
+(a) Did you state the full set of assumptions of all theoretical results? [N/A]
+(b) Did you include complete proofs of all theoretical results? [N/A]
+
+3. If you ran experiments...
+
+(a) Did you include the code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL)? [No] We plan to open-source our work as part of a larger framework in the future.
+(b) Did you specify all the training details (e.g., data splits, hyperparameters, how they were chosen)? [Yes]
+(c) Did you report error bars (e.g., with respect to the random seed after running experiments multiple times)? [Yes] We report error bars for the score-accuracy correlation of our discovered metric against variation of batc hsize as well as seed.
+(d) Did you include the total amount of compute and the type of resources used (e.g., type of GPUs, internal cluster, or cloud provider)? [Yes]
+
+4. If you are using existing assets (e.g., code, data, models) or curating/releasing new assets...
+
+(a) If your work uses existing assets, did you cite the creators? [Yes]
+(b) Did you mention the license of the assets? [No]
+(c) Did you include any new assets either in the supplemental material or as a URL? [No]
+(d) Did you discuss whether and how consent was obtained from people whose data you're using/curating? [No] Crediting the curators was sufficient as specified in their open-source license.
+(e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content? [N/A]
+
+5. If you used crowdsourcing or conducted research with human subjects...
+
+(a) Did you include the full text of instructions given to participants and screenshots, if applicable? [N/A]
+(b) Did you describe any potential participant risks, with links to Institutional Review Board (IRB) approvals, if applicable? [N/A]
+(c) Did you include the estimated hourly wage paid to participants and the total amount spent on participant compensation? [N/A]
\ No newline at end of file
diff --git a/eznasevolvingzerocostproxiesforneuralarchitecturescoring/images.zip b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..5277a3e4705fda761c9095745312f5302f40b5cf
--- /dev/null
+++ b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a93052104f66a1ce1a144e165ac3615ec6db468136dbf8d00484976b17a3653a
+size 260555
diff --git a/eznasevolvingzerocostproxiesforneuralarchitecturescoring/layout.json b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..7bdc42db0aca62848cbc4c06bf42341cc35361cc
--- /dev/null
+++ b/eznasevolvingzerocostproxiesforneuralarchitecturescoring/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9d513bbf071e2be7b796cd7f8a1de07a9e75f9b2cbd33acb0de1af55fba89918
+size 315481