Original: Meta-Learning Dynamics Forecasting Using Task Inference
Revised: Meta-Learning Dynamics Forecasting Using Task Inference

Original: Abstract
Revised: Abstract

Original: Current deep learning models for dynamics forecasting struggle with generalization.
Revised: Current deep learning models for dynamics forecasting struggle with generalization.

Original: They can only forecast in a specific domain and fail when applied to systems with different parameters, external forces, or boundary conditions.
Revised: They can only forecast in a specific domain and fail when applied to systems with different parameters, external forces, or boundary conditions.

Original: We propose a model-based meta-learning method called DyAd which can generalize across heterogeneous domains by partitioning them into different tasks.
Revised: We propose a model-based meta-learning method called DyAd which can generalize across heterogeneous domains by partitioning them into different tasks.

Original: DyAd has two parts: an encoder which infers the time-invariant hidden features of the task with weak supervision, and a forecaster which learns the shared dynamics of the entire domain.
Revised: DyAd has two parts: an encoder which infers the time-invariant hidden features of the task with weak supervision, and a forecaster which learns the shared dynamics of the entire domain.

Original: The encoder adapts and controls the forecaster during inference using adaptive instance normalization and adaptive padding.
Revised: The encoder adapts and controls the forecaster during inference using adaptive instance normalization and adaptive padding.

Original: Theoretically, we prove that the generalization error of such  procedure is related to the task relatedness in the source domain, as well as the domain differences between source and target.
Revised: We prove that the generalization error of such a procedure is governed by task relatedness in the source domain and domain differences between source and target.

Original: Experimentally, we demonstrate that our model outperforms state-of-the-art approaches on forecasting complex physical dynamics including turbulent flow, real-world sea surface temperature and ocean currents.
Revised: Experimentally, we demonstrate that our model outperforms state-of-the-art approaches to forecasting complex physical dynamics including turbulent flow, real-world sea surface temperature and ocean currents.

Original: We open-source our code  at https://github.com/Rose-STL-Lab/Dynamic-Adaptation-Network .
Revised: Our code is available open sourced at https://github.com/Rose-STL-Lab/Dynamic-Adaptation-Network .

Original:  Introduction
Revised:  Introduction

Original: Modeling dynamical systems with deep learning has shown great success in a wide range of systems from climate science, Internet of Things (IoT) to infectious diseases [23, 64, 8, 33, 42, 22].
Revised: Modeling dynamical systems with deep learning has shown great success in a wide range of systems from climate science, Internet of Things (IoT) to infectious diseases [23, 64, 8, 33, 42, 22].

Original: However, the main limitation of previous works is limited generalizability.
Revised: However, the main limitation of previous works is limited generalizability.

Original: Most approaches only focus on a specific system and train on past data in order to predict the future.
Revised: Most approaches only focus on a specific system and train on past data in order to predict the future.

Original: Thus, a new model must be trained to predict a system with different dynamics.
Revised: Thus, a new model must be trained to predict a system with different dynamics.

Original: Consider, for example, learning fluid dynamics; shown in Fig.
Revised: Consider, for example, learning fluid dynamics; shown in Fig.

Original: 1 are two fluid flows with different degrees of turbulence.
Revised: 1 are two fluid flows with different degrees of turbulence.

Original: Although the flows are governed by the same equations, the difference in buoyant forces would require two separate deep learning models to forecast.
Revised: Although the flows are governed by the same equations, the difference in buoyant forces would require two separate deep learning models to forecast.

Original: Therefore, it is imperative to develop generalizable deep learning models for dynamical systems that can learn and predict well over a large heterogeneous domain.
Revised: Therefore, it is imperative to develop generalizable deep learning models for dynamical systems that can learn and predict well over a large heterogeneous domain.

Original: time ?
Revised: time ?

Original:  needs to generalize to a flow with a very different buoyant force.
Revised: flow. The model needs to generalize to a flow with a very different buoyant force.

Original: Meta-learning [63, 7, 13], or learning to learn, improves generalization by learning multiple tasks from the environment.
Revised: Meta-learning [63, 7, 13], or learning to learn, improves generalization by learning multiple tasks from the environment.

Original: Recent developments in meta-learning have been successfully applied to few-shot classification [46, 62], active learning [77], and reinforcement learning [18, 20].
Revised: Recent developments in meta-learning have been successfully applied to few-shot classification [46, 62], active learning [77], and reinforcement learning [18, 20].

Original: However, meta-learning in the context of forecasting high-dimensional physical dynamics has not been studied before.
Revised: However, meta-learning in the context of forecasting high-dimensional physical dynamics has not been studied before.

Original: The challenges with meta-learning dynamical systems are unique in that (1) we need to efficiently infer the latent representation of the dynamical system given observed time series data, (2) we need to account for changes in unknown initial and boundary conditions, and (3) we need to model the temporal dynamics across heterogeneous domains.
Revised: The challenges with meta-learning dynamical systems are unique in that (1) we need to efficiently infer the latent representation of the dynamical system given observed time series data, (2) we need to account for changes in unknown initial and boundary conditions, and (3) we need to model the temporal dynamics across heterogeneous domains.

Original: Our approach is inspired by the fact that similar dynamical systems may share time-invariant hidden features.
Revised: Our approach is inspired by the fact that similar dynamical systems may share time-invariant hidden features.

Original: Even the slightest change in these features may lead to vastly different phenomena.
Revised: Even the slightest change in these features may lead to vastly different phenomena.

Original: For example, in climate science, fluids are governed by a set of differential equations called NavierStokes equations.
Revised: For example, in climate science, fluids are governed by a set of differential equations called NavierStokes equations.

Original: Some features such as kinematic viscosity and external forces (e.g. gravity), are time-invariant and determine the flow characteristics.
Revised: Some features such as kinematic viscosity and external forces (e.g. gravity), are time-invariant and determine the flow characteristics.

Original: By inferring this latent representation, we can model diverse system behaviors from smoothly flowing water to atmospheric turbulence.
Revised: By inferring this latent representation, we can model diverse system behaviors from smoothly flowing water to atmospheric turbulence.

Original: Inspired by neural style transfer [26], we propose a model-based meta-learning method, called DyAd , which can rapidly adapt to systems with varying dynamics.
Revised: Inspired by neural style transfer [26], we propose a model-based meta-learning method, called DyAd , which can rapidly adapt to systems with varying dynamics.

Original: DyAd has two parts, an encoder g and a forecaster f .
Revised: DyAd has two parts, an encoder g and a forecaster f .

Original: The encoder maps different dynamical systems to time-invariant hidden features representing constants of motion, boundary conditions, and external forces which characterize the system.
Revised: The encoder maps different dynamical systems to time-invariant hidden features representing constants of motion, boundary conditions, and external forces which characterize the system.

Original: The forecaster f then takes the learnt hidden features from the encoder and the past system states to forecast the future system state.
Revised: The forecaster f then takes the learnt hidden features from the encoder and the past system states to forecast the future system state.

Original: Controlled by the time-invariant hidden features, the forecaster has the flexibility to adapt to a wide range of systems with heterogeneous dynamics.
Revised: Controlled by the time-invariant hidden features, the forecaster has the flexibility to adapt to a wide range of systems with heterogeneous dynamics.

Original: Unlike gradient-based meta-learning techniques such as MAML [13], DyAd automatically adapts during inference using an encoder and does not require retraining.
Revised: Unlike gradient-based meta-learning techniques such as MAML [13], DyAd automatically adapts during inference using an encoder and does not require retraining.

Original: Similar to model-based metalearning methods such as MetaNets [46], we employ a two-part design with an adaptable learner which receives task-specific weights.
Revised: Similar to model-based metalearning methods such as MetaNets [46], we employ a two-part design with an adaptable learner which receives task-specific weights.

Original: However, for time-series forecasting, since input and output come from the same domain, a support set of labeled data is unnecessary to define the task.
Revised: However, for time-series forecasting, since input and output come from the same domain, a support set of labeled data is unnecessary to define the task.

Original: The encoder can infer the task directly from the query input.
Revised: The encoder can infer the task directly from the query input.

Original: Our contributions include:
Revised: Our contributions include:

Original: • A novel model-based meta-learning method ( DyAd ) for dynamic forecasting in a large heterogeneous domain.
Revised: • A novel model-based meta-learning method ( DyAd ) for dynamic forecasting in a large heterogeneous domain.

Original: • An encoder capable of extracting the time-invariant hidden features of a dynamical system using time-shift invariant model structure and weak supervision.
Revised: • An encoder capable of extracting the time-invariant hidden features of a dynamical system using time-shift invariant model structure and weak supervision.

Original: • A new adaptive padding layer (AdaPad), designed for adapting to boundary conditions.
Revised: • A new adaptive padding layer (AdaPad), designed for adapting to boundary conditions.

Original: • Theoretical guarantees for DyAd on the generalization error of task inference in the source domain as well as domain adaptation to the target domain.
Revised: • Theoretical guarantees for DyAd on the generalization error of task inference in the source domain as well as domain adaptation to the target domain.

Original: • Improved
Revised: • Improved

Original: generalization performance on heterogeneous domains such as fluid flow and sea temperature forecasting, even to new tasks outside the training distribution.
Revised: generalization performance on heterogeneous domains such as fluid flow and sea temperature forecasting, even to new tasks outside the training distribution.

Original:  Methods 2.1 Meta-learning in dynamics forecasting
Revised:  Methods 2.1 Meta-learning in dynamics forecasting

Original: Let x ∈ R
Revised: Let x ∈ R

Original: d be a d -dimensional state of a dynamical system governed by parameters ψ .
Revised: d be a d -dimensional state of a dynamical system governed by parameters ψ .

Original: The problem of dynamics forecasting is that given a sequence of past states ( x 1 , . . .
Revised: The problem of dynamics forecasting is that given a sequence of past states ( x 1 , . . .

Original: , x t ) , we want to learn a map f such that: f : ( x 1 , . . .
Revised: , x t ) , we want to learn a map f such that: f : ( x 1 , . . .

Original: , x t ) (cid:55)−→ ( x t +1 , . . .
Revised: , x t ) (cid:55)−→ ( x t +1 , . . .

Original: x t + k ) .
Revised: x t + k ) .

Original: Here l is the length of the input series, and h is the forecasting horizon in the output.
Revised: Here l is the length of the input series, and h is the forecasting horizon in the output.

Original: Existing approaches for dynamics forecasting only predict future data for a specific system as a single task.
Revised: Existing approaches for dynamics forecasting only predict future data for a specific system as a single task.

Original: Here a task refers to forecasting for a specific system with a given set of parameters.
Revised: Here a task refers to forecasting for a specific system with a given set of parameters.

Original: The resulting models often generalize poorly to different system dynamics.
Revised: The resulting models often generalize poorly to different system dynamics.

Original: Thus a new model must be trained to predict for each specific system.
Revised: Thus a new model must be trained to predict for each specific system.

Original: To perform meta-learning, we identify each forecasting task by some parameters c ⊂ ψ , such as constants of motion, external forces, and boundary conditions.
Revised: To perform meta-learning, we identify each forecasting task by some parameters c ⊂ ψ , such as constants of motion, external forces, and boundary conditions.

Original: We learn multiple tasks simultaneously and infer the task from data.
Revised: We learn multiple tasks simultaneously and infer the task from data.

Original: Here we use c for a subset of system parameters ψ , because we usually do not have the full knowledge of the system dynamics.
Revised: Here we use c for a subset of system parameters ψ , because we usually do not have the full knowledge of the system dynamics.

Original: In the turbulent flow example, the state x t is the velocity field at time t .
Revised: In the turbulent flow example, the state x t is the velocity field at time t .

Original: Parameters c can represent Reynolds number, mean vorticity, mean magnitude, or a vector of all three.
Revised: Parameters c can represent Reynolds number, mean vorticity, mean magnitude, or a vector of all three.

Original: Let µ be the data distribution over X × Y representing the function f : X → Y where X = R d × t and Y =
Revised: Let µ be the data distribution over X × Y representing the function f : X → Y where X = R d × t and Y =

Original: R d × k .
Revised: R d × k .

Original: Our main assumption is that the domain X can be partitioned into separate tasks
Revised: Our main assumption is that the domain X can be partitioned into separate tasks

Original: X = ∪ c ∈C X c , where X c is the domain for task c and C is the set of all tasks.
Revised: X = ∪ c ∈C X c , where X c is the domain for task c and C is the set of all tasks.

Original: The data in the same task share the same set of parameters.
Revised: The data in the same task share the same set of parameters.

Original: Let µ c be the conditional distribution over X c × Y for task c .
Revised: Let µ c be the conditional distribution over X c × Y for task c .

Original: During training, the model is presented with data drawn from a subset of tasks { ( x, y ) : ( x, y ) ∼ µ c , c ∼ C } .
Revised: During training, the model is presented with data drawn from a subset of tasks { ( x, y ) : ( x, y ) ∼ µ c , c ∼ C } .

Original: Our goal is to learn the function f : X → Y over the whole domain X which can thus generalize across all tasks c ∈ C .
Revised: Our goal is to learn the function f : X → Y over the whole domain X which can thus generalize across all tasks c ∈ C .

Original: To do so, we need to learn the map g : X → C taking x ∈ X c to c in order to infer the task with minimal supervision.
Revised: To do so, we need to learn the map g : X → C taking x ∈ X c to c in order to infer the task with minimal supervision.

Original: 2.2 DyAd : Dynamic Adaptation Network
Revised: 2.2 DyAd : Dynamic Adaptation Network

Original: We propose a model-based meta-learning approach for dynamics forecasting.
Revised: We propose a model-based meta-learning approach for dynamics forecasting.

Original: Given multiple forecasting tasks, we propose to learn the function f in two stages.
Revised: Given multiple forecasting tasks, we propose to learn the function f in two stages.

Original: That is, by first inferring the task c from the input x , and then adapting to a specialized forecaster f c : X c → Y for each task.
Revised: That is, by first inferring the task c from the input x , and then adapting to a specialized forecaster f c : X c → Y for each task.

Original: An alternative is to use a single deep neural network to directly model f in one step over the whole domain.
Revised: An alternative is to use a single deep neural network to directly model f in one step over the whole domain.

Original: But this requires the training set to have good and uniform coverage of the different tasks.
Revised: But this requires the training set to have good and uniform coverage of the different tasks.

Original: If the data distribution µ is highly heterogeneous or the training set is not sampled i.i.d.
Revised: If the data distribution µ is highly heterogeneous or the training set is not sampled i.i.d.

Original: from the whole domain, then a single model may struggle with generalization.
Revised: from the whole domain, then a single model may struggle with generalization.

Original: We hypothesize that by partitioning the domain into different tasks, the model would learn to pick up task-specific features without requiring uniform coverage of the training data.
Revised: We hypothesize that by partitioning the domain into different tasks, the model would learn to pick up task-specific features without requiring uniform coverage of the training data.

Original: Furthermore, by separating task inference and forecasting into two stages, we allow the forecaster to rapidly adapt to new tasks that never appeared in the training set.
Revised: Furthermore, by separating task inference and forecasting into two stages, we allow the forecaster to rapidly adapt to new tasks that never appeared in the training set.

Original: As shown in Fig.
Revised: As shown in Fig.

Original: 2, our model consists of two parts: an encoder g and a forecaster f .
Revised: 2, our model consists of two parts: an encoder g and a forecaster f .

Original: We introduce z c as a time-invariant hidden feature for task c .
Revised: We introduce z c as a time-invariant hidden feature for task c .

Original: We assume that c depends linearly on the hidden feature for simplicity and easy interpretation.
Revised: We assume that c depends linearly on the hidden feature for simplicity and easy interpretation.

Original: We design the encoder to infer the hidden feature z c given the input x .
Revised: We design the encoder to infer the hidden feature z c given the input x .

Original: We then use z c to adapt the forecaster f to the specific task, i.e., model y =
Revised: We then use z c to adapt the forecaster f to the specific task, i.e., model y =

Original: f c ( x ) as y = f
Revised: f c ( x ) as y = f

Original: ( x, z c ) .
Revised: ( x, z c ) .

Original: As the system dynamics are encoded in the input sequence x , we can feed the same input sequence x to a forecaster and generate predictions ˆ y =
Revised: As the system dynamics are encoded in the input sequence x , we can feed the same input sequence x to a forecaster and generate predictions ˆ y =

Original: f c ( x ) .
Revised: f c ( x ) .

Original: 2.3 Encoder Network
Revised: 2.3 Encoder Network

Original: The encoder maps the input x to the hidden features z c that are time-invariant.
Revised: The encoder maps the input x to the hidden features z c that are time-invariant.

Original: To enforce this inductive bias, we encode time-invariance both in the architecture and in the training objective.
Revised: To enforce this inductive bias, we encode time-invariance both in the architecture and in the training objective.

Original: Time-Invariant Encoder.
Revised: Time-Invariant Encoder.

Original: The encoder is implemented using 4 Conv 3D layers, each followed by
Revised: The encoder is implemented using 4 Conv 3D layers, each followed by

Original: BatchNorm , LeakyReLU , and max-pooling.
Revised: BatchNorm , LeakyReLU , and max-pooling.

Original: Note that theoretically, max-pooling is not perfectly shift invariant since 2x2x2 max-pooling is equivariant to shifts of size 2 and only approximately invariant to shifts of size 1.
Revised: Note that theoretically, max-pooling is not perfectly shift invariant since 2x2x2 max-pooling is equivariant to shifts of size 2 and only approximately invariant to shifts of size 1.

Original: But standard convolutional architectures often include max-pooling layers to boost performance.
Revised: But standard convolutional architectures often include max-pooling layers to boost performance.

Original: We convolve both across spatial and temporal dimensions.
Revised: We convolve both across spatial and temporal dimensions.

Original: After that, we use a global mean-pooling layer and a fully connected layer to estimate the hidden feature ˆ z c .
Revised: After that, we use a global mean-pooling layer and a fully connected layer to estimate the hidden feature ˆ z c .

Original: The task parameter depends linearly on the hidden feature.
Revised: The task parameter depends linearly on the hidden feature.

Original: We use a fully connected layer to compute the parameter estimate ˆ c .
Revised: We use a fully connected layer to compute the parameter estimate ˆ c .

Original: Since convolutions are equivariant to shift (up to boundary frames) and mean pooling is invariant to shift, the encoder is shift-invariant.
Revised: Since convolutions are equivariant to shift (up to boundary frames) and mean pooling is invariant to shift, the encoder is shift-invariant.

Original: In practice, shifting the time sequence one frame forward will add one new frame at the beginning and drop one frame at the end.
Revised: In practice, shifting the time sequence one frame forward will add one new frame at the beginning and drop one frame at the end.

Original: This creates some change in output value of the encoder.
Revised: This creates some change in output value of the encoder.

Original: Thus, practically, the encoder is only approximately shift-invariant.
Revised: Thus, practically, the encoder is only approximately shift-invariant.

Original: Encoder Training.
Revised: Encoder Training.

Original: The encoder network g is trained first.
Revised: The encoder network g is trained first.

Original: To combat the loss of shift invariance from the change from the boundary frames, we train the encoder using a time-invariant loss.
Revised: To combat the loss of shift invariance from the change from the boundary frames, we train the encoder using a time-invariant loss.

Original: Given two training samples ( x ( i ) , y ( i ) ) and ( x ( j ) , y ( j ) ) and their task parameters c , we have loss
Revised: Given two training samples ( x ( i ) , y ( i ) ) and ( x ( j ) , y ( j ) ) and their task parameters c , we have loss

Original: [Equation]
Revised: [Equation]

Original: where ˆ z ( i ) =
Revised: where ˆ z ( i ) =

Original: g ( x ( i ) ) and ˆ z ( j ) = g ( x ( j ) ) and ˆ c ( i ) =
Revised: g ( x ( i ) ) and ˆ z ( j ) = g ( x ( j ) ) and ˆ c ( i ) =

Original: W ˆ
Revised: W ˆ

Original: z
Revised: z

Original: ( i ) c
Revised: ( i ) c

Original: + b is an affine transformation of z c .
Revised: + b is an affine transformation of z c .

Original: The first term ∥ ˆ c − c ∥ 2 uses weak supervision of the task parameters whenever they are available.
Revised: The first term ∥ ˆ c − c ∥ 2 uses weak supervision of the task parameters whenever they are available.

Original: Such weak supervision helps guide the learning of hidden feature z c for each task.
Revised: Such weak supervision helps guide the learning of hidden feature z c for each task.

Original: While not all parameters of the dynamical system are known, we can compute approximate values in the datum c ( i ) based on our domain knowledge.
Revised: While not all parameters of the dynamical system are known, we can compute approximate values in the datum c ( i ) based on our domain knowledge.

Original: For example, instead of the Reynolds number of the fluid flow, we can use the average vorticity as a surrogate for task parameters.
Revised: For example, instead of the Reynolds number of the fluid flow, we can use the average vorticity as a surrogate for task parameters.

Original: The second term ∥ ˆ z ( i ) c − ˆ z ( j ) c ∥ 2 is the time-shift invariance loss, which penalizes the changes in latent variables between samples from different time steps.
Revised: The second term ∥ ˆ z ( i ) c − ˆ z ( j ) c ∥ 2 is the time-shift invariance loss, which penalizes the changes in latent variables between samples from different time steps.

Original: Since the time-shift invariance of convolution is only approximate, this loss term drives the time-shift error even lower.
Revised: Since the time-shift invariance of convolution is only approximate, this loss term drives the time-shift error even lower.

Original: The third term |∥ ˆ z ( i ) c
Revised: The third term |∥ ˆ z ( i ) c

Original: ∥ − m |( m is a positive value) prevents the encoder from generating small ˆ z ( i ) c
Revised: ∥ − m |( m is a positive value) prevents the encoder from generating small ˆ z ( i ) c

Original: due to time-shift invariance loss.
Revised: due to time-shift invariance loss.

Original: It also helps the encoder to learn more interesting z , even in the absence of weak supervision.
Revised: It also helps the encoder to learn more interesting z , even in the absence of weak supervision.

Original: Hidden Features.
Revised: Hidden Features.

Original: The encoder learns time-invariant hidden features.
Revised: The encoder learns time-invariant hidden features.

Original: These hidden features resemble the time-invariant dimensionless parameters [30] in physical modeling, such as Reynolds number in fluid mechanics.
Revised: These hidden features resemble the time-invariant dimensionless parameters [30] in physical modeling, such as Reynolds number in fluid mechanics.

Original: The hidden features may also be viewed as partial disentanglement of the system state.
Revised: The hidden features may also be viewed as partial disentanglement of the system state.

Original: As suggested by [37, 47], our disentanglement method is guided by inductive bias and training objectives.
Revised: As suggested by [37, 47], our disentanglement method is guided by inductive bias and training objectives.

Original: Unlike complete disentanglement, as in e.g. [39], in which the latent representation is factored into timeinvariant and time-varying components, we focus only on time-shift-invariance.
Revised: Unlike complete disentanglement, as in e.g. [39], in which the latent representation is factored into timeinvariant and time-varying components, we focus only on time-shift-invariance.

Original: Nonetheless, the hidden features can control the forecaster which is useful for generalization.
Revised: Nonetheless, the hidden features can control the forecaster which is useful for generalization.

Original: 2.4 Forecaster Network.
Revised: 2.4 Forecaster Network.

Original: The forecaster incorporates the hidden feature z c from the encoder and adapts to the specific forecasting task f c = f ( · , z c ) .
Revised: The forecaster incorporates the hidden feature z c from the encoder and adapts to the specific forecasting task f c = f ( · , z c ) .

Original: In what follows, we use z for z c .
Revised: In what follows, we use z for z c .

Original: We use two specialized layers, adaptive instance normalization ( AdaIN ) and adaptive padding ( AdaPad ).
Revised: We use two specialized layers, adaptive instance normalization ( AdaIN ) and adaptive padding ( AdaPad ).

Original: AdaIN has been used in neural style transfer [26, 21] to control generative networks.
Revised: AdaIN has been used in neural style transfer [26, 21] to control generative networks.

Original: Here, AdaIN may adapt for specific coefficients and external forces.
Revised: Here, AdaIN may adapt for specific coefficients and external forces.

Original: We also introduce a new layer, AdaPad( x, z ) , which is designed for encoding the boundary conditions of dynamical systems.
Revised: We also introduce a new layer, AdaPad( x, z ) , which is designed for encoding the boundary conditions of dynamical systems.

Original: The backbone of the forecaster network can be any sequence prediction model.
Revised: The backbone of the forecaster network can be any sequence prediction model.

Original: We use a design that is similar to ResNet for spatiotemporal sequences.
Revised: We use a design that is similar to ResNet for spatiotemporal sequences.

Original: 𝒙
Revised: 𝒙

Original: FC z
Revised: FC z

Original: AdaPad 𝒚
Revised: AdaPad 𝒚

Original: AdaIN.
Revised: AdaIN.

Original: We employ AdaIN to adapt the forecaster network.
Revised: We employ AdaIN to adapt the forecaster network.

Original: Denote the channels of input x by x i and let µ ( x i ) and σ ( x i ) be the mean and standard deviation of channel i .
Revised: Denote the channels of input x by x i and let µ ( x i ) and σ ( x i ) be the mean and standard deviation of channel i .

Original: For each AdaIN layer, a particular style is computed s =
Revised: For each AdaIN layer, a particular style is computed s =

Original: ( µ i , σ i ) i =
Revised: ( µ i , σ i ) i =

Original: Az + b , where the linear map A and bias b are learned weights.
Revised: Az + b , where the linear map A and bias b are learned weights.

Original: Adaptive instance normalization is then defined as y i =
Revised: Adaptive instance normalization is then defined as y i =

Original: σ i x i − µ ( x i ) σ ( x i ) + µ i .
Revised: σ i x i − µ ( x i ) σ ( x i ) + µ i .

Original: In essence, the channels are renormalized to the style s .
Revised: In essence, the channels are renormalized to the style s .

Original: For dynamics forecasting, the hidden feature z encodes data analogous to the coefficients of a differential equation and external forces on the system.
Revised: For dynamics forecasting, the hidden feature z encodes data analogous to the coefficients of a differential equation and external forces on the system.

Original: In numerical simulation of a differential equation these coefficients enter as scalings of different terms in the equation and the external forces are added to the combined force equation [24].
Revised: In numerical simulation of a differential equation these coefficients enter as scalings of different terms in the equation and the external forces are added to the combined force equation [24].

Original: Thus in our context AdaIN , which scales channels and adds a global vector, is well-suited to injecting this information.
Revised: Thus in our context AdaIN , which scales channels and adds a global vector, is well-suited to injecting this information.

Original: AdaPad.
Revised: AdaPad.

Original: To complement AdaIN , we introduce AdaPad , which encodes the boundary conditions of each specific dynamical system.
Revised: To complement AdaIN , we introduce AdaPad , which encodes the boundary conditions of each specific dynamical system.

Original: Generally when predicting dynamical systems, error is introduced along the boundaries since it is unknown how the dynamics interact with the boundary of the domain, and there may be unknown inflows or outflows.
Revised: Generally when predicting dynamical systems, error is introduced along the boundaries since it is unknown how the dynamics interact with the boundary of the domain, and there may be unknown inflows or outflows.

Original: In our method, the inferred hidden feature z may contain the boundary information.
Revised: In our method, the inferred hidden feature z may contain the boundary information.

Original: AdaPad uses the hidden features to compute the boundary conditions via a linear layer.
Revised: AdaPad uses the hidden features to compute the boundary conditions via a linear layer.

Original: Then it applies the boundary conditions as padding immediately outside the spatial domain in each layer, as shown in Fig.
Revised: Then it applies the boundary conditions as padding immediately outside the spatial domain in each layer, as shown in Fig.

Original: Forecaster Training The forecaster is trained separately after the encoder.
Revised: Forecaster Training The forecaster is trained separately after the encoder.

Original: The kernels of the convolutions and the mappings of the AdaIN and AdaPad layers are all trained simultaneously as the forecaster network is trained.
Revised: The kernels of the convolutions and the mappings of the AdaIN and AdaPad layers are all trained simultaneously as the forecaster network is trained.

Original: Denote the true state as y and the predicted state as ˆ y , we compute the loss per time step ∥ ˆ y − y ∥ 2 for each example.
Revised: Denote the true state as y and the predicted state as ˆ y , we compute the loss per time step ∥ ˆ y − y ∥ 2 for each example.

Original: We accumulate the loss over different time steps and generate multi-step forecasts in an autoregressive fashion.
Revised: We accumulate the loss over different time steps and generate multi-step forecasts in an autoregressive fashion.

Original: In practice, we observe separate training achieves better performances than training end-to-end, see experiments for details.
Revised: In practice, we observe separate training achieves better performances than training end-to-end, see experiments for details.

Original: 2.5 Theoretical Analysis
Revised: 2.5 Theoretical Analysis

Original: The high-level idea of our method is to learn a good representation of the dynamics that generalizes well across a heterogeneous domain, and then adapt this representation to make predictions on new tasks.
Revised: The high-level idea of our method is to learn a good representation of the dynamics that generalizes well across a heterogeneous domain, and then adapt this representation to make predictions on new tasks.

Original: Our model achieves this by learning on multiple tasks simultaneously and then adapting to new tasks with domain transfer.
Revised: Our model achieves this by learning on multiple tasks simultaneously and then adapting to new tasks with domain transfer.

Original: We prove that learning the tasks simultaneously as opposed to independently results in better generalization (Proposition B.3 in Appendix).
Revised: We prove that learning the tasks simultaneously as opposed to independently results in better generalization (Proposition B.3 in Appendix).

Original: We also provide a theoretical decomposition for the generalization error.
Revised: We also provide a theoretical decomposition for the generalization error.

Original: Specifically, our hypothesis space has the form { x (cid:55)→ f θ ( x, g ϕ ( x )) } where ϕ and θ are the weights of the encoder and forecaster respectively.
Revised: Specifically, our hypothesis space has the form { x (cid:55)→ f θ ( x, g ϕ ( x )) } where ϕ and θ are the weights of the encoder and forecaster respectively.

Original: Let ϵ X be the error over the entire domain X , that is, for all c .
Revised: Let ϵ X be the error over the entire domain X , that is, for all c .

Original: Let ϵ enc ( g ϕ ) =
Revised: Let ϵ enc ( g ϕ ) =

Original: E x ∼X
Revised: E x ∼X

Original: ( L 1 ( g ( x ) , g ϕ ( x )) be the encoder error where g : X → C is the ground truth.
Revised: ( L 1 ( g ( x ) , g ϕ ( x )) be the encoder error where g : X → C is the ground truth.

Original: Let G =
Revised: Let G =

Original: { g ϕ : X → C} be the encoder hypothesis space.
Revised: { g ϕ : X → C} be the encoder hypothesis space.

Original: Denote the empirical risk of g ϕ by ˆ ϵ enc ( g ϕ ) .
Revised: Denote the empirical risk of g ϕ by ˆ ϵ enc ( g ϕ ) .

Original: W 1 denotes the Wasserstein distance between tasks.
Revised: W 1 denotes the Wasserstein distance between tasks.

Original: R ( G ) and R ( F ) represent the Rademacher complexities of encoder and forecaster.
Revised: R ( G ) and R ( F ) represent the Rademacher complexities of encoder and forecaster.

Original: The following Proposition decomposes the generalization error in terms of forecaster error, encoder error, and distance between tasks.
Revised: The following Proposition decomposes the generalization error in terms of forecaster error, encoder error, and distance between tasks.

Original: Proposition 2.1.
Revised: Proposition 2.1.

Original: Assume the forecaster c (cid:55)→ f θ ( · , c ) is Lipschitz continuous with Lipschitz constant γ uniformly in θ and l ≤ 1 / 2 .
Revised: Assume the forecaster c (cid:55)→ f θ ( · , c ) is Lipschitz continuous with Lipschitz constant γ uniformly in θ and l ≤ 1 / 2 .

Original: Let λ c = min f ∈F
Revised: Let λ c = min f ∈F

Original: ( ϵ c ( f ) + 1 /K (cid:80)
Revised: ( ϵ c ( f ) + 1 /K (cid:80)

Original: Kk
Revised: Kk

Original: =1 ϵ c k ( f )) .
Revised: =1 ϵ c k ( f )) .

Original: For large n and probability ≥ 1 − δ ,
Revised: For large n and probability ≥ 1 − δ ,

Original: [Equation]
Revised: [Equation]

Original: This result helps to quantify the trade-offs with respect to different terms in the error bound in our two-part architecture and the error of the model can be controlled by minimizing the empirical errors of the encoder and forecaster.
Revised: This result helps to quantify the trade-offs with respect to different terms in the error bound in our two-part architecture and the error of the model can be controlled by minimizing the empirical errors of the encoder and forecaster.

Original: See the Appendix Proposition B.6 for full proofs.
Revised: See the Appendix Proposition B.6 for full proofs.

Original:  Related Work
Revised:  Related Work

Original: Learning Dynamical Systems.
Revised: Learning Dynamical Systems.

Original: Deep learning models are gaining popularity for learning dynamical systems [60, 8, 29, 5, 73, 64, 51].
Revised: Deep learning models are gaining popularity for learning dynamical systems [60, 8, 29, 5, 73, 64, 51].

Original: An emerging topic is physics-informed deep learning [53, 6, 11, 69, 4, 3, 68, 12, 10] which integrates inductive biases from physical systems to improve learning.
Revised: An emerging topic is physics-informed deep learning [53, 6, 11, 69, 4, 3, 68, 12, 10] which integrates inductive biases from physical systems to improve learning.

Original: For example, [45, 6] incorporated Koopman theory into the architecture.
Revised: For example, [45, 6] incorporated Koopman theory into the architecture.

Original: [43] used deep neural networks to solve PDEs with physical laws enforced in the loss functions.
Revised: [43] used deep neural networks to solve PDEs with physical laws enforced in the loss functions.

Original: [17] and [9] build models upon Hamiltonian and Lagrangian mechanics that respect conservation laws.
Revised: [17] and [9] build models upon Hamiltonian and Lagrangian mechanics that respect conservation laws.

Original: [68] proposed a hybrid approach by marrying two well-established turbulent flow simulation techniques with deep learning to produce a better prediction of turbulence.
Revised: [68] proposed a hybrid approach by marrying two well-established turbulent flow simulation techniques with deep learning to produce a better prediction of turbulence.

Original: [10] propose a physics-informed GAN architecture that uses physics knowledge to inform the learning of both the generator and discriminator models.
Revised: [10] propose a physics-informed GAN architecture that uses physics knowledge to inform the learning of both the generator and discriminator models.

Original: However, these approaches deal with a specific system dynamics instead of a large heterogeneous domain.
Revised: However, these approaches deal with a specific system dynamics instead of a large heterogeneous domain.

Original: Multi-task learning and Meta-learning.
Revised: Multi-task learning and Meta-learning.

Original: Multi-task learning [65] focuses on learning shared representations from multiple related tasks.
Revised: Multi-task learning [65] focuses on learning shared representations from multiple related tasks.

Original: Architecture-based MTL methods can be categorized into encoder-focused [35] and decoder-focused [74].
Revised: Architecture-based MTL methods can be categorized into encoder-focused [35] and decoder-focused [74].

Original: There are also optimization-based MTL methods, such as task balancing methods [27].
Revised: There are also optimization-based MTL methods, such as task balancing methods [27].

Original: But MTL assumes tasks are known a priori instead of inferring the task from data.
Revised: But MTL assumes tasks are known a priori instead of inferring the task from data.

Original: On the other hand, the aim of meta-learning [63] is to leverage the shared representation to fast adapt to unseen tasks.
Revised: On the other hand, the aim of meta-learning [63] is to leverage the shared representation to fast adapt to unseen tasks.

Original: Based on how the meta-level knowledge is extracted and used, meta-learning methods are classified into model-based [46, 1, 50, 59, 78], metric-based [67, 61] and gradient-based [13, 57, 16, 76].
Revised: Based on how the meta-level knowledge is extracted and used, meta-learning methods are classified into model-based [46, 1, 50, 59, 78], metric-based [67, 61] and gradient-based [13, 57, 16, 76].

Original: Most meta-learning approaches are not designed for forecasting with a few exceptions.
Revised: Most meta-learning approaches are not designed for forecasting with a few exceptions.

Original: [72] proposed to train a domain classifier with weak supervision to help domain adaptation but focused on low-dimensioal time series classification problems.
Revised: [72] proposed to train a domain classifier with weak supervision to help domain adaptation but focused on low-dimensioal time series classification problems.

Original: [50] designed a residual architecture for time series forecasting with a meta-learning parallel.
Revised: [50] designed a residual architecture for time series forecasting with a meta-learning parallel.

Original: [1] proposed a modular meta-learning approach for continuous control.
Revised: [1] proposed a modular meta-learning approach for continuous control.

Original: But forecasting physical dynamics poses unique challenges to meta-learning as it requires encoding physical knowledge into our model.
Revised: But forecasting physical dynamics poses unique challenges to meta-learning as it requires encoding physical knowledge into our model.

Original: Style Transfer.
Revised: Style Transfer.

Original: Our approach is inspired by neural style transfer techniques.
Revised: Our approach is inspired by neural style transfer techniques.

Original: In style transfer, a generative network is controlled by an external style vector through adaptive instance normalization between convolutional layers.
Revised: In style transfer, a generative network is controlled by an external style vector through adaptive instance normalization between convolutional layers.

Original: Our hidden representation bears affinity with the “style” vector in style transfer techniques.
Revised: Our hidden representation bears affinity with the “style” vector in style transfer techniques.

Original: Rather than aesthetic style in images, our hidden representation encodes time-invariant features.
Revised: Rather than aesthetic style in images, our hidden representation encodes time-invariant features.

Original: Style transfer initially appear in non-photorealistic rendering [31].
Revised: Style transfer initially appear in non-photorealistic rendering [31].

Original: Recently, neural style transfer [25] has been applied to image synthesis [15, 36], videos generation [56], and language translation [52].
Revised: Recently, neural style transfer [25] has been applied to image synthesis [15, 36], videos generation [56], and language translation [52].

Original: For dynamical systems, [58] adapts texture synthesis to transfer the style of turbulence for animation.
Revised: For dynamical systems, [58] adapts texture synthesis to transfer the style of turbulence for animation.

Original: [28] studies unsupervised generative modeling of turbulent flows but for super-resolution reconstruction rather than forecasting.
Revised: [28] studies unsupervised generative modeling of turbulent flows but for super-resolution reconstruction rather than forecasting.

Original: Video Prediction.
Revised: Video Prediction.

Original: Our work is also related to video prediction.
Revised: Our work is also related to video prediction.

Original: Conditioning on the historic observed frames, video prediction models are trained to predict future frames, e.g., [41, 14, 75, 66, 49, 14, 70, 71, 32, 40, 34].
Revised: Conditioning on the historic observed frames, video prediction models are trained to predict future frames, e.g., [41, 14, 75, 66, 49, 14, 70, 71, 32, 40, 34].

Original: There is also conditional video prediction [48] which achieves controlled synthesis.
Revised: There is also conditional video prediction [48] which achieves controlled synthesis.

Original: Many of these models are trained on natural videos from unknown physical processes.
Revised: Many of these models are trained on natural videos from unknown physical processes.

Original: Our work is substantially different because we do not attempt to predict object or camera motions.
Revised: Our work is substantially different because we do not attempt to predict object or camera motions.

Original: However, our method can be potentially combined with video prediction models to improve generalization.
Revised: However, our method can be potentially combined with video prediction models to improve generalization.

Original:  Experiments
Revised:  Experiments

Original: 4.1 Datasets
Revised: 4.1 Datasets

Original: We experiment on three datasets: synthetic turbulent flows, real-world sea surface temperature and ocean currents data.
Revised: We experiment on three datasets: synthetic turbulent flows, real-world sea surface temperature and ocean currents data.

Original: These are difficult to forecast using numerical methods due to unknown external forces and complex dynamics not fully captured by simplified mathematical models.
Revised: These are difficult to forecast using numerical methods due to unknown external forces and complex dynamics not fully captured by simplified mathematical models.

Original: Turbulent Flow with Varying Buoyancy.
Revised: Turbulent Flow with Varying Buoyancy.

Original: We generate a synthetic dataset of turbulent flows with a numerical simulator, PhiFlow 1 .
Revised: We generate a synthetic dataset of turbulent flows with a numerical simulator, PhiFlow 1 .

Original: It contains 64 × 64 velocity fields of turbulent flows in which we vary
Revised: It contains 64 × 64 velocity fields of turbulent flows in which we vary

Original: [Table]
Revised: [Table]

Original: the buoyant force acting on the fluid from 1 to 25.
Revised: the buoyant force acting on the fluid from 1 to 25.

Original: Each buoyant force corresponds to a forecasting task and there are 25 tasks in total.
Revised: Each buoyant force corresponds to a forecasting task and there are 25 tasks in total.

Original: We use the mean vorticity of each task as partial supervision c as we can directly calculate it from the data.
Revised: We use the mean vorticity of each task as partial supervision c as we can directly calculate it from the data.

Original: Vorticity can characterize formation and circular motion of turbulent flows.
Revised: Vorticity can characterize formation and circular motion of turbulent flows.

Original: Sea Surface Temperature.
Revised: Sea Surface Temperature.

Original: We evaluate on a real-world sea surface temperature data generated by the NEMO ocean engine [38] 2 .
Revised: We evaluate on a real-world sea surface temperature data generated by the NEMO ocean engine [38] 2 .

Original: We select an area from Pacific ocean range from 01/01/ to 12/31/2020.
Revised: We select an area from Pacific ocean range from 01/01/ to 12/31/2020.

Original: The corresponding latitude and longitude are (-150 ∼ -120, -20 ∼ -50).
Revised: The corresponding latitude and longitude are (-150 ∼ -120, -20 ∼ -50).

Original: This area is then divided into 25 64 × 64 subregions, each is a task since the mean temperature varies a lot along longitude and latitude.
Revised: This area is then divided into 25 64 × 64 subregions, each is a task since the mean temperature varies a lot along longitude and latitude.

Original: For the encoder training, we use season as an additional supervision signal besides the mean temperature of each subregion.
Revised: For the encoder training, we use season as an additional supervision signal besides the mean temperature of each subregion.

Original: In other words, the encoder should be able to infer the mean temperature of the subregion as well as to classify four seasons given the temperature series.
Revised: In other words, the encoder should be able to infer the mean temperature of the subregion as well as to classify four seasons given the temperature series.

Original: Ocean Currents.
Revised: Ocean Currents.

Original: We also experiment with the velocity fields of ocean currents from the same region and use the same task division as the sea surface temperature data set.
Revised: We also experiment with the velocity fields of ocean currents from the same region and use the same task division as the sea surface temperature data set.

Original: Similar to the turbulent flow data set, we use the mean vorticity of each subregion as the weak-supervision signal.
Revised: Similar to the turbulent flow data set, we use the mean vorticity of each subregion as the weak-supervision signal.

Original: 4.2 Baselines
Revised: 4.2 Baselines

Original: We include several SoTA baselines from meta-learning and dynamics forecasting.
Revised: We include several SoTA baselines from meta-learning and dynamics forecasting.

Original: • ResNet [19]: A widely adopted video prediction model [69].
Revised: • ResNet [19]: A widely adopted video prediction model [69].

Original: • U-net
Revised: • U-net

Original: 55]: Originally developed for biomedical image segmentation, adapted for dynamics forecasting [11].
Revised: 55]: Originally developed for biomedical image segmentation, adapted for dynamics forecasting [11].

Original: • ResNet/Unet-c
Revised: • ResNet/Unet-c

Original: Above ResNet and Unet with an additional final layer that generates task parameter c and trained with weak-supervision and forecasting loss altogether.
Revised: Above ResNet and Unet with an additional final layer that generates task parameter c and trained with weak-supervision and forecasting loss altogether.

Original: • PredRNN [70]: A state-of-art RNNs-based spatiotemporal forecasting model.
Revised: • PredRNN [70]: A state-of-art RNNs-based spatiotemporal forecasting model.

Original: • VarSepNet [12]: A convolutional dynamics forecasting model based on spatiotemporal disentanglement.
Revised: • VarSepNet [12]: A convolutional dynamics forecasting model based on spatiotemporal disentanglement.

Original: • Mod-attn
Revised: • Mod-attn

Original: [1]: A modular meta-learning method which combines the outputs of modules to generalize to new tasks using attention.
Revised: [1]: A modular meta-learning method which combines the outputs of modules to generalize to new tasks using attention.

Original: • Mod-wt : A modular meta-learning variant which uses attention weights to combine the parameters of the convolutional kernels in different modules for new tasks.
Revised: • Mod-wt : A modular meta-learning variant which uses attention weights to combine the parameters of the convolutional kernels in different modules for new tasks.

Original: • MetaNet [46]: A model-based meta-learning method which requires a few samples from test tasks as a support set to adapt.
Revised: • MetaNet [46]: A model-based meta-learning method which requires a few samples from test tasks as a support set to adapt.

Original: • MAML [13]: A optimization-based meta-learning approach.
Revised: • MAML [13]: A optimization-based meta-learning approach.

Original: We replaced the original classifier with a ResNet for regression.
Revised: We replaced the original classifier with a ResNet for regression.

Original: [Table] [Table]
Revised: [Table] [Table]

Original: [Table] [Table]
Revised: [Table] [Table]

Original: Note that both ResNet-c and Unet-c have access to task parameters c .
Revised: Note that both ResNet-c and Unet-c have access to task parameters c .

Original: Modular-attn has a convolutional encoder f
Revised: Modular-attn has a convolutional encoder f

Original: that takes the same input x as each module M to generate attention weights,
Revised: that takes the same input x as each module M to generate attention weights,

Original: [Equation] [Equation]
Revised: [Equation] [Equation]

Original: x )
Revised: x )

Original: [Equation]
Revised: [Equation]

Original: )] M l ( x ) .
Revised: )] M l ( x ) .

Original: Modular-wt also has the same encoder but to generate weights for combining the convolution parameters of all modules.
Revised: Modular-wt also has the same encoder but to generate weights for combining the convolution parameters of all modules.

Original: MetaNet requires samples from test tasks as a support set and MAML needs adaptation retraining on test tasks, while other models do not need any information from the test domains.
Revised: MetaNet requires samples from test tasks as a support set and MAML needs adaptation retraining on test tasks, while other models do not need any information from the test domains.

Original: Thus, we use additional samples of up to 20% of the test set from test tasks.
Revised: Thus, we use additional samples of up to 20% of the test set from test tasks.

Original: MetaNet uses these as a support set.
Revised: MetaNet uses these as a support set.

Original: MAML is retrained on these samples for 10 epoch for adaptation.
Revised: MAML is retrained on these samples for 10 epoch for adaptation.

Original: To demonstrate the generalizability of DyAd , we experimented with ResNet and U-net as our forecaster.
Revised: To demonstrate the generalizability of DyAd , we experimented with ResNet and U-net as our forecaster.

Original: 4.3 Experiments Setup
Revised: 4.3 Experiments Setup

Original: For all datasets, we use a sliding-window approach to generate samples of sequences.
Revised: For all datasets, we use a sliding-window approach to generate samples of sequences.

Original: We evaluate on two scenarios of generalization.
Revised: We evaluate on two scenarios of generalization.

Original: For test-future, we train and test on the same task but different time steps.
Revised: For test-future, we train and test on the same task but different time steps.

Original: For test-domain, we train and test on different tasks with an 80-20 split.
Revised: For test-domain, we train and test on different tasks with an 80-20 split.

Original: All models are trained to make next step prediction given the history.
Revised: All models are trained to make next step prediction given the history.

Original: We forecast in an autoregressive manner to generate multi-step ahead predictions.
Revised: We forecast in an autoregressive manner to generate multi-step ahead predictions.

Original: All results are averaged over 3 runs with random initialization.
Revised: All results are averaged over 3 runs with random initialization.

Original: Apart from the root mean square error (RMSE), we also report the energy spectrum error (ESE) for ocean current prediction, which quantifies the physical consistency.
Revised: Apart from the root mean square error (RMSE), we also report the energy spectrum error (ESE) for ocean current prediction, which quantifies the physical consistency.

Original: ESE indicates whether the predictions preserve the correct statistical distribution and obey the energy conservation law, which is a critical metric for physical consistency.
Revised: ESE indicates whether the predictions preserve the correct statistical distribution and obey the energy conservation law, which is a critical metric for physical consistency.

Original: See details about energy spectrum and complete experiments details in Appendix A.1.
Revised: See details about energy spectrum and complete experiments details in Appendix A.1.

Original:  Results 5.1 Prediction Performance.
Revised:  Results 5.1 Prediction Performance.

Original: Table 1 shows the RMSE of multi-step predictions on
Revised: Table 1 shows the RMSE of multi-step predictions on

Original: Turbulent Flows (20 steps), Sea Surface Temperature ( steps), and Ocean Currents (10 step) in two testing scenarios.
Revised: Turbulent Flows (20 steps), Sea Surface Temperature ( steps), and Ocean Currents (10 step) in two testing scenarios.

Original: We observe that DyAd makes the most accurate predictions in both scenarios across all datasets.
Revised: We observe that DyAd makes the most accurate predictions in both scenarios across all datasets.

Original: Comparing
Revised: Comparing

Original: ResNet/Unet-c with DyAd , we observe the clear advantage of task inference with separate training.
Revised: ResNet/Unet-c with DyAd , we observe the clear advantage of task inference with separate training.

Original: VarSepNet achieves competitive performances on Ocean Currents (second best) through spatiotemporal disentanglement but cannot adapt to future data.
Revised: VarSepNet achieves competitive performances on Ocean Currents (second best) through spatiotemporal disentanglement but cannot adapt to future data.

Original: Table 1 also reports ESEs on real-world Ocean Currents.
Revised: Table 1 also reports ESEs on real-world Ocean Currents.

Original: DyAd not only has small
Revised: DyAd not only has small

Original: RMSE but also obtains the smallest ESE, suggesting it captures the statistical distribution of ocean currents well.
Revised: RMSE but also obtains the smallest ESE, suggesting it captures the statistical distribution of ocean currents well.

Original: Figure 4 shows the target and the predicted velocity norm fields ( √ u 2 + v 2 ) by Unet-c , Modular-wt and DyAd at time step 1, 5, 10 for Turbulent Flows with buoyancy factors 9 and 21 respectively.
Revised: Figure 4 shows the target and the predicted velocity norm fields ( √ u 2 + v 2 ) by Unet-c , Modular-wt and DyAd at time step 1, 5, 10 for Turbulent Flows with buoyancy factors 9 and 21 respectively.

Original: We can see that DyAd can generate realistic flows with the corresponding characteristics while the baselines have trouble understanding and disentangling the buoyancy factor.
Revised: We can see that DyAd can generate realistic flows with the corresponding characteristics while the baselines have trouble understanding and disentangling the buoyancy factor.

Original: Figure 5 shows DyAd ,
Revised: Figure 5 shows DyAd ,

Original: ResNet , U-net , PredRNN predictions on an ocean current sample in the future test set, and we see the shape of predictions by DyAd is closest to the target.
Revised: ResNet , U-net , PredRNN predictions on an ocean current sample in the future test set, and we see the shape of predictions by DyAd is closest to the target.

Original: These results demonstrate that DyAd not only forecasts well but also accurately captures the physical characteristics of the system.
Revised: These results demonstrate that DyAd not only forecasts well but also accurately captures the physical characteristics of the system.

Original: 5.2 Controllable Forecast.
Revised: 5.2 Controllable Forecast.

Original: DyAd infers the hidden features from data, which allows direct control of the latent space in the forecaster.
Revised: DyAd infers the hidden features from data, which allows direct control of the latent space in the forecaster.

Original: We vary the encoder input while keeping the forecaster input fixed.
Revised: We vary the encoder input while keeping the forecaster input fixed.

Original: Figure 6 right shows the forecasts from DyAd when the encoder is fed with flows having different buoyancy factors c = 5 , 15 , 25 .
Revised: Figure 6 right shows the forecasts from DyAd when the encoder is fed with flows having different buoyancy factors c = 5 , 15 , 25 .

Original: As expected, with higher buoyancy factors, the predictions from the forecaster become more turbulent.
Revised: As expected, with higher buoyancy factors, the predictions from the forecaster become more turbulent.

Original: This demonstrates that the encoder can successfully disentangle the latent representation of difference tasks, and control the predictions of the forecaster.
Revised: This demonstrates that the encoder can successfully disentangle the latent representation of difference tasks, and control the predictions of the forecaster.

Original: 5.3 Ablation Study.
Revised: 5.3 Ablation Study.

Original: We performed several ablation studies of DyAd on the turbulence dataset to understand the contribution of each model component.
Revised: We performed several ablation studies of DyAd on the turbulence dataset to understand the contribution of each model component.

Original: Ablation of the Model and Training Strategy.
Revised: Ablation of the Model and Training Strategy.

Original: We first performed ablation study of the model architecture, shown in Table 2.
Revised: We first performed ablation study of the model architecture, shown in Table 2.

Original: We first remove the encoder from DyAd while keeping the same forecaster network ( No_enc ).
Revised: We first remove the encoder from DyAd while keeping the same forecaster network ( No_enc ).

Original: The resulting model degrades but still outperforms ResNet .
Revised: The resulting model degrades but still outperforms ResNet .

Original: This demonstrates the effectiveness of AdaIN and AdaPad for forecasting.
Revised: This demonstrates the effectiveness of AdaIN and AdaPad for forecasting.

Original: We also tested DyAd with
Revised: We also tested DyAd with

Original: AdaIN only ( No_AdaPad ), and the performance without AdaPad was slightly worse.
Revised: AdaIN only ( No_AdaPad ), and the performance without AdaPad was slightly worse.

Original: Another notable feature of our model is the ability to infer tasks with weakly supervised signals c .
Revised: Another notable feature of our model is the ability to infer tasks with weakly supervised signals c .

Original: It is important to have a c that is related to the task domain.
Revised: It is important to have a c that is related to the task domain.

Original: As an ablative study, we fed the encoder in
Revised: As an ablative study, we fed the encoder in

Original: DyAd with a random c , leading to Wrong_enc .
Revised: DyAd with a random c , leading to Wrong_enc .

Original: We can see that having the totally wrong supervision may slightly hurt the forecasting performance.
Revised: We can see that having the totally wrong supervision may slightly hurt the forecasting performance.

Original: We also trained the encoder and the forecaster in
Revised: We also trained the encoder and the forecaster in

Original: DyAd altogether ( End2End ) but observed worse performance.
Revised: DyAd altogether ( End2End ) but observed worse performance.

Original: This validates our hypothesis about the significance of domain partitioning and separate training strategy.
Revised: This validates our hypothesis about the significance of domain partitioning and separate training strategy.

Original: Ablation of Encoder Training Losses.
Revised: Ablation of Encoder Training Losses.

Original: We performed an ablation study of three training loss terms for the encoder to show the necessity of each loss term, shown in Table 

Revised: We performed an ablation study of three training loss terms for the encoder to show the necessity of each loss term, shown in Table

Original: We tried training the encoder only with the supervision of task parameters ( Sup_c ).
Revised: We tried training the encoder only with the supervision of task parameters ( Sup_c ).

Original: We also tested training with the first two terms but without the magnitude loss ( Sup_c+time_inv ).
Revised: We also tested training with the first two terms but without the magnitude loss ( Sup_c+time_inv ).

Original: We can see that missing any of three loss terms would make the encoder fail to learn the correct task-specific and time-invariant features.
Revised: We can see that missing any of three loss terms would make the encoder fail to learn the correct task-specific and time-invariant features.

Original: Alternatives to AdaIN.
Revised: Alternatives to AdaIN.

Original: We also tested 5 different alternatives to AdaIN for injecting the hidden feature z c into the forecaster, and reported the results in Table 4.
Revised: We also tested 5 different alternatives to AdaIN for injecting the hidden feature z c into the forecaster, and reported the results in Table 4.

Original: We tested concatenating z c to the input of the forecaster, using z c as the kernels of the forecaster, concatenating z c to the hidden states, adding z c to the hidden states, using z c as the biases in the convolutional layers in the forecaster.
Revised: We tested concatenating z c to the input of the forecaster, using z c as the kernels of the forecaster, concatenating z c to the hidden states, adding z c to the hidden states, using z c as the biases in the convolutional layers in the forecaster.

Original: AdaIN worked better than any alternative we tested.
Revised: AdaIN worked better than any alternative we tested.

Original: [Table] [Table]
Revised: [Table] [Table]

Original:  Conclusion
Revised:  Conclusion

Original: We propose a model-based meta-learning method, DyAd to forecast physical dynamics.
Revised: We propose a model-based meta-learning method, DyAd to forecast physical dynamics.

Original: DyAd uses an encoder to infer the parameters of the task and a prediction network to adapt and forecast giving the inferred task.
Revised: DyAd uses an encoder to infer the parameters of the task and a prediction network to adapt and forecast giving the inferred task.

Original: Our model can also leverage any weak supervision signals that can help distinguish different tasks, allowing the incorporation of additional domain knowledge.
Revised: Our model can also leverage any weak supervision signals that can help distinguish different tasks, allowing the incorporation of additional domain knowledge.

Original: On challenging turbulent flow prediction and real-world ocean temperature and currents forecasting tasks, we observe superior performance of our model across heterogeneous dynamics.
Revised: On challenging turbulent flow prediction and real-world ocean temperature and currents forecasting tasks, we observe superior performance of our model across heterogeneous dynamics.

Original: Future work would consider non-grid data such as flows on a graph or a sphere.
Revised: Future work would consider non-grid data such as flows on a graph or a sphere.

Original: Acknowledgments and Disclosure of Funding
Revised: Acknowledgments and Disclosure of Funding

Original: We are grateful to several anonymous reviewers for their comments which have helped us to improve this work.
Revised: We are grateful to several anonymous reviewers for their comments which have helped us to improve this work.

Original: This work was supported in part by U
Revised: This work was supported in part by U

Original: S. Department Of Energy, Office of Science grant
Revised: S. Department Of Energy, Office of Science grant

Original: DE-SC0022255, U. S. Army Research Office grant W911NF-20-1-0334, and NSF grants # and #2146343.
Revised: DE-SC0022255, U. S. Army Research Office grant W911NF-20-1-0334, and NSF grants # and #2146343.

Original: R. Walters was supported by the Roux Institute and the Harold Alfond Foundation and
Revised: R. Walters was supported by the Roux Institute and the Harold Alfond Foundation and

Original: NSF grants #2107256 and #2134178.
Revised: NSF grants #2107256 and #2134178.

Original: This research used resources of the National Energy Research
Revised: This research used resources of the National Energy Research

Original: Scientific Computing Center, a DOE Office of Science User Facility supported by the Office of
Revised: Scientific Computing Center, a DOE Office of Science User Facility supported by the Office of

Original: Science of the U.S. Department of Energy under Contract No. DE-AC02-05CH11231 using NERSC award ßASCR-ERCAP0022715.
Revised: Science of the U.S. Department of Energy under Contract No. DE-AC02-05CH11231 using NERSC award ßASCR-ERCAP0022715.

Original: A Additional Results A.1 Experiments Details
Revised: A Additional Results A.1 Experiments Details

Original: We use a sliding window approach to generate samples of sequences.
Revised: We use a sliding window approach to generate samples of sequences.

Original: For test-future, we train and test on the same tasks but different time steps.
Revised: For test-future, we train and test on the same tasks but different time steps.

Original: For test-domain, we train and test on different tasks with an 80%-20% split.
Revised: For test-domain, we train and test on different tasks with an 80%-20% split.

Original: All models are trained to make next step prediction given the previous steps as input.
Revised: All models are trained to make next step prediction given the previous steps as input.

Original: We forecast in an autoregressive manner to generate multi-step ahead predictions.
Revised: We forecast in an autoregressive manner to generate multi-step ahead predictions.

Original: All results are averaged over 3 runs with random initialization.
Revised: All results are averaged over 3 runs with random initialization.

Original: We tuned learning rate (1e-2 ∼ 1e-5), batch size (16 ∼ 64), the number of unrolled prediction steps for backpropogation (2 ∼ 6), and hidden size (64 ∼ 512).
Revised: We tuned learning rate (1e-2 ∼ 1e-5), batch size (16 ∼ 64), the number of unrolled prediction steps for backpropogation (2 ∼ 6), and hidden size (64 ∼ 512).

Original: We fixed the number of historic input frames as 20.
Revised: We fixed the number of historic input frames as 20.

Original: The models that use ResNet, including MAML , MetaNets and DyAd+ResNet , have same number of residual blocks for fair comparison.
Revised: The models that use ResNet, including MAML , MetaNets and DyAd+ResNet , have same number of residual blocks for fair comparison.

Original: When we trained the encoder on turbulence and sea surface temperature, we used α = 1 and β = 1 in the Equ. 1.
Revised: When we trained the encoder on turbulence and sea surface temperature, we used α = 1 and β = 1 in the Equ. 1.

Original: For ocean currents, we used α = 0 .
Revised: For ocean currents, we used α = 0 .

Original: 2 and β = 0 .
Revised: 2 and β = 0 .

Original: We performed all experiments on 4 V100 GPUs.
Revised: We performed all experiments on 4 V100 GPUs.

Original: Table 5 in Appendix A displays the number of parameters of each fine-tuned model on the turbulence dataset.
Revised: Table 5 in Appendix A displays the number of parameters of each fine-tuned model on the turbulence dataset.

Original: We compare our model with a series of baselines on the multi-step forecasting with different dynamics.
Revised: We compare our model with a series of baselines on the multi-step forecasting with different dynamics.

Original: We consider two testing scenarios: (1) dynamics with different initial conditions (test-future) and (2) dynamics with different parameters such as external force (test-domain).
Revised: We consider two testing scenarios: (1) dynamics with different initial conditions (test-future) and (2) dynamics with different parameters such as external force (test-domain).

Original: The first scenario evaluates the models’ ability to extrapolate into the future for the same task.
Revised: The first scenario evaluates the models’ ability to extrapolate into the future for the same task.

Original: The second scenario is to estimate the capability of the models to generalize across different tasks.
Revised: The second scenario is to estimate the capability of the models to generalize across different tasks.

Original: Apart from the root mean square error (RMSE), we also report the energy spectrum error (ESE) for ocean current prediction which quantifies the physical consistency.
Revised: Apart from the root mean square error (RMSE), we also report the energy spectrum error (ESE) for ocean current prediction which quantifies the physical consistency.

Original: ESE indicates whether the predictions preserve the correct statistical distribution and obey the energy conservation law, which is a critical metric for physical consistency.
Revised: ESE indicates whether the predictions preserve the correct statistical distribution and obey the energy conservation law, which is a critical metric for physical consistency.

Original: The turbulence kinetic energy spectrum E ( k ) is related to the mean turbulence kinetic energy as
Revised: The turbulence kinetic energy spectrum E ( k ) is related to the mean turbulence kinetic energy as

Original: [Equation]
Revised: [Equation]

Original: / 2 , ( u ′ ) 2 = 1 T
Revised: / 2 , ( u ′ ) 2 = 1 T

Original: T (cid:88) t
Revised: T (cid:88) t

Original: = ( u ( t ) − ¯ u ) 2 .
Revised: = ( u ( t ) − ¯ u ) 2 .

Original: where the k is the wavenumber and t is the time step.
Revised: where the k is the wavenumber and t is the time step.

Original: The spectrum can describe the transfer of energy from large scales of motion to the small scales and provides a representation of the dependence of energy on frequency.
Revised: The spectrum can describe the transfer of energy from large scales of motion to the small scales and provides a representation of the dependence of energy on frequency.

Original: Thus, the ESE can indicate whether the predictions preserve the correct statistical distribution and obey the energy conservation law.
Revised: Thus, the ESE can indicate whether the predictions preserve the correct statistical distribution and obey the energy conservation law.

Original: A trivial example that can illustrate why we need ESE is that if a model simply outputs moving averages of input frames, the accumulated
Revised: A trivial example that can illustrate why we need ESE is that if a model simply outputs moving averages of input frames, the accumulated

Original: RMSE of predictions might not be high but the ESE would be really big because all the small or even medium eddies are smoothed out.
Revised: RMSE of predictions might not be high but the ESE would be really big because all the small or even medium eddies are smoothed out.

Original: A.2 Addtional Experiments Results
Revised: A.2 Addtional Experiments Results

Original: [Table]
Revised: [Table]

Original: B Theoretical Analysis
Revised: B Theoretical Analysis

Original: The high-level idea of our method is to learn a good representation of the dynamics that generalizes well across a heterogeneous domain, and then adapt this representation to make predictions on new tasks.
Revised: The high-level idea of our method is to learn a good representation of the dynamics that generalizes well across a heterogeneous domain, and then adapt this representation to make predictions on new tasks.

Original: Our model achieves this by learning on multiple tasks simultaneously and then adapting to new tasks with domain transfer.
Revised: Our model achieves this by learning on multiple tasks simultaneously and then adapting to new tasks with domain transfer.

Original: We prove that learning the tasks simultaneously as opposed to independently results in tighter generalization bounds.
Revised: We prove that learning the tasks simultaneously as opposed to independently results in tighter generalization bounds.

Original: As these are upper bounds, they do not necessarily imply better generalization, although empirically, this is what we observe.
Revised: As these are upper bounds, they do not necessarily imply better generalization, although empirically, this is what we observe.

Original: Although we are not able to provide a proof of our empirical finding that an encoder-forecaster architecture outperforms a monolithic architecture, we do provide an analysis of the error, decomposing it into error due to the forecaster, encoder, and domain adaptation.
Revised: Although we are not able to provide a proof of our empirical finding that an encoder-forecaster architecture outperforms a monolithic architecture, we do provide an analysis of the error, decomposing it into error due to the forecaster, encoder, and domain adaptation.

Original: This decomposition helps to quantify the trade-offs involved in our two-part architecture.
Revised: This decomposition helps to quantify the trade-offs involved in our two-part architecture.

Original: Suppose we have K tasks { c k } Kk =1 ∼ C , each of which is sampled from a continuous parameter space C .
Revised: Suppose we have K tasks { c k } Kk =1 ∼ C , each of which is sampled from a continuous parameter space C .

Original: Here c k are the parameters of the task, which can be inferred by the encoder.
Revised: Here c k are the parameters of the task, which can be inferred by the encoder.

Original: For each task c k , we have a collection of data ˆ µ c k of size n , sampled from µ k , a shorthand for µ c k .
Revised: For each task c k , we have a collection of data ˆ µ c k of size n , sampled from µ k , a shorthand for µ c k .

Original: B.1 Multi-Task Learning Error
Revised: B.1 Multi-Task Learning Error

Original: We want to bound the true loss ϵ using the empirical loss ˆ ϵ and Rademacher complexity of the hypothesis class F .
Revised: We want to bound the true loss ϵ using the empirical loss ˆ ϵ and Rademacher complexity of the hypothesis class F .

Original: We can use the classic results from [2].
Revised: We can use the classic results from [2].

Original: Define empirical Rademacher complexity for all tasks as
Revised: Define empirical Rademacher complexity for all tasks as

Original: [Equation]
Revised: [Equation]

Original: where { σ ( i ) k } are independent binary variables σ ( i ) k ∈ {− 1 , 1 } .
Revised: where { σ ( i ) k } are independent binary variables σ ( i ) k ∈ {− 1 , 1 } .

Original: The true Rademacher complexity is then defined R ( F ) =
Revised: The true Rademacher complexity is then defined R ( F ) =

Original: E X
Revised: E X

Original: ( ˆ R X ( F )) .
Revised: ( ˆ R X ( F )) .

Original: The following theorem restates the main result from [2].
Revised: The following theorem restates the main result from [2].

Original: We simplify the statement by using
Revised: We simplify the statement by using

Original: Rademacher complexity rather than the set cover number argument used in the original proof.
Revised: Rademacher complexity rather than the set cover number argument used in the original proof.

Original: The assumption of bounded loss is reasonable given a prescribed data domain and data preprocessing.
Revised: The assumption of bounded loss is reasonable given a prescribed data domain and data preprocessing.

Original: Theorem B.1.
Revised: Theorem B.1.

Original: ([2]) Assume the loss is bounded l ≤ 1 / 2 .
Revised: ([2]) Assume the loss is bounded l ≤ 1 / 2 .

Original: Given n samples each from K different forecasting tasks µ 1 , · · · , µ k , then with probability at least 1 − δ , the following inequality holds for each f ∈ F in the hypothesis class:
Revised: Given n samples each from K different forecasting tasks µ 1 , · · · , µ k , then with probability at least 1 − δ , the following inequality holds for each f ∈ F in the hypothesis class:

Original: [Equation]
Revised: [Equation]

Original: Proof.
Revised: Proof.

Original: Consider { x ( i ) k } as independent random variables.
Revised: Consider { x ( i ) k } as independent random variables.

Original: For a function ϕ that satisfies | ϕ ( x (1) , · · · , x
Revised: For a function ϕ that satisfies | ϕ ( x (1) , · · · , x

Original: [Equation]
Revised: [Equation]

Original: i ) ,
Revised: i ) ,

Original: [Equation]
Revised: [Equation]

Original: · x
Revised: · x

Original: [Equation]
Revised: [Equation]

Original: −
Revised: −

Original: [Equation]
Revised: [Equation]

Original: i by McDiarmid’s inequality, we have
Revised: i by McDiarmid’s inequality, we have

Original: [Equation]
Revised: [Equation]

Original: Applying this inequality to the max difference Q ( X ) =
Revised: Applying this inequality to the max difference Q ( X ) =

Original: sup f ∈F [ ϵ ( f ) − ˆ ϵ ( f, X )] , then with probability at least 1 − δ , we have
Revised: sup f ∈F [ ϵ ( f ) − ˆ ϵ ( f, X )] , then with probability at least 1 − δ , we have

Original: [Equation]
Revised: [Equation]

Original: where C is a constant depending on the bounds
Revised: where C is a constant depending on the bounds

Original: c i .
Revised: c i .

Original: If the loss l ≤ 1 / 2 , then | Q | ≤ 1 / 2 and so we can take c i = 1 leading to C = 1 / √ 2 .
Revised: If the loss l ≤ 1 / 2 , then | Q | ≤ 1 / 2 and so we can take c i = 1 leading to C = 1 / √ 2 .

Original: A standard computation (see [44] Theorem 3.3) using the law of total expectation shows E X [ Q ( X )] ≤ 2 R ( F ) , which finishes the proof.
Revised: A standard computation (see [44] Theorem 3.3) using the law of total expectation shows E X [ Q ( X )] ≤ 2 R ( F ) , which finishes the proof.

Original: The following inequality compares the performance for multi-task learning to learning individual tasks.
Revised: The following inequality compares the performance for multi-task learning to learning individual tasks.

Original: Let R k ( F ) be the Rademacher complexity for F over µ k .
Revised: Let R k ( F ) be the Rademacher complexity for F over µ k .

Original: Lemma B.2.
Revised: Lemma B.2.

Original: The Rademacher complexity for multi-task learning is bounded R ( F ) ≤ (1 /K )
Revised: The Rademacher complexity for multi-task learning is bounded R ( F ) ≤ (1 /K )

Original: (cid:80) Kk =1 R k ( F ) .
Revised: (cid:80) Kk =1 R k ( F ) .

Original: Proof.
Revised: Proof.

Original: We compute the empirical Rademacher complexity,
Revised: We compute the empirical Rademacher complexity,

Original: [Equation]
Revised: [Equation]

Original: (cid:17)(cid:17)(cid:33)(cid:35)
Revised: (cid:17)(cid:17)(cid:33)(cid:35)

Original: [Equation]
Revised: [Equation]

Original: Proposition B.3.
Revised: Proposition B.3.

Original: Assume n = n k for all tasks k
Revised: Assume n = n k for all tasks k

Original: and the loss l is bounded l ≤ 1 / 2 , then the generalization bound given by considering each task individually is
Revised: and the loss l is bounded l ≤ 1 / 2 , then the generalization bound given by considering each task individually is

Original: [Equation]
Revised: [Equation]

Original: which is weaker than the bound of Theorem B.1.
Revised: which is weaker than the bound of Theorem B.1.

Original: Proof.
Revised: Proof.

Original: Applying the classical analog of Theorem B.1 to a single task, we find with probability greater than 1 − δ ,
Revised: Applying the classical analog of Theorem B.1 to a single task, we find with probability greater than 1 − δ ,

Original: [Equation]
Revised: [Equation]

Original: Averaging over all tasks yields
Revised: Averaging over all tasks yields

Original: [Equation]
Revised: [Equation]

Original: Since the loss l is bounded l ≤ 1 / 2 , we can take C =
Revised: Since the loss l is bounded l ≤ 1 / 2 , we can take C =

Original: C k = 1 / √ 2 , giving the generalization upper bound for the joint error of Equation 3.
Revised: C k = 1 / √ 2 , giving the generalization upper bound for the joint error of Equation 3.

Original: By Lemma B.2 and the fact 1 / √ 2 nK ≤ 1 / √ 2 n , the bound in Theorem B.1 is strictly tighter.
Revised: By Lemma B.2 and the fact 1 / √ 2 nK ≤ 1 / √ 2 n , the bound in Theorem B.1 is strictly tighter.

Original: The upper bound in Theorem B.1 is strictly tighter than that of Proposition B.3 as the first terms ˆ ϵ ( f ) are equal, the second term is smaller by Lemma B.2 and the third is smaller since 1 / √ 2 nK ≤ 1 / √ 2 n .
Revised: The upper bound in Theorem B.1 is strictly tighter than that of Proposition B.3 as the first terms ˆ ϵ ( f ) are equal, the second term is smaller by Lemma B.2 and the third is smaller since 1 / √ 2 nK ≤ 1 / √ 2 n .

Original: This helps explain why our multitask learning forecaster has better generalization than learning each task independently.
Revised: This helps explain why our multitask learning forecaster has better generalization than learning each task independently.

Original: The shared data tightens the generalization bound.
Revised: The shared data tightens the generalization bound.

Original: Ultimately, though a tighter upper bound suggests lower error, it does not strictly imply it.
Revised: Ultimately, though a tighter upper bound suggests lower error, it does not strictly imply it.

Original: We further verify this theory in our experiments by comparison to baselines which learn each task independently.
Revised: We further verify this theory in our experiments by comparison to baselines which learn each task independently.

Original: B.2 Domain Adaptation Error
Revised: B.2 Domain Adaptation Error

Original: Since we test on c ∼ C outside the training set { c k } , we incur error due to domain adaptation from the source domains µ c 1 , . .
Revised: Since we test on c ∼ C outside the training set { c k } , we incur error due to domain adaptation from the source domains µ c 1 , . .

Original: . , µ c K to target domain µ c with µ being the true distribution.
Revised: . , µ c K to target domain µ c with µ being the true distribution.

Original: Denote the corresponding empirical distributions of n samples per task by ˆ µ c = 1 n c (cid:80) n c i =1 δ x ( i ) c .
Revised: Denote the corresponding empirical distributions of n samples per task by ˆ µ c = 1 n c (cid:80) n c i =1 δ x ( i ) c .

Original: For different c and c ′ , the domains µ c and µ c ′ may have largely disjoint support, leading to very high KL divergence.
Revised: For different c and c ′ , the domains µ c and µ c ′ may have largely disjoint support, leading to very high KL divergence.

Original: However, if c and c ′ are close, samples x c ∼ µ c and x c ′ ∼ µ c ′ may be close in the domain X with respect to the metric ∥ · ∥ X .
Revised: However, if c and c ′ are close, samples x c ∼ µ c and x c ′ ∼ µ c ′ may be close in the domain X with respect to the metric ∥ · ∥ X .

Original: For example, if the external forces c and c ′ are close, given x c ∼ µ c there is likely x c ′ ∼ µ c ′
Revised: For example, if the external forces c and c ′ are close, given x c ∼ µ c there is likely x c ′ ∼ µ c ′

Original: such that the distance between the velocity fields ∥ x c − x c ′ ∥ is small.
Revised: such that the distance between the velocity fields ∥ x c − x c ′ ∥ is small.

Original: This implies the distributions µ c and µ c ′ may be be close in Wasserstein distance
Revised: This implies the distributions µ c and µ c ′ may be be close in Wasserstein distance

Original: W 1 ( µ c , µ c ′ ) .
Revised: W 1 ( µ c , µ c ′ ) .

Original: The bound from [54] applies well to our setting as such:
Revised: The bound from [54] applies well to our setting as such:

Original: Theorem B.4.
Revised: Theorem B.4.

Original: Let λ c = min f ∈F (cid:16) ϵ c ( f ) + 1 /K (cid:80)
Revised: Let λ c = min f ∈F (cid:16) ϵ c ( f ) + 1 /K (cid:80)

Original: Kk
Revised: Kk

Original: =1 ϵ c k
Revised: =1 ϵ c k

Original: ( f ) (cid:17) .
Revised: ( f ) (cid:17) .

Original: There is N = N (dim( X )) such that for n > N , for any hypothesis f , with probability at least 1 − δ ,
Revised: There is N = N (dim( X )) such that for n > N , for any hypothesis f , with probability at least 1 − δ ,

Original: [Equation]
Revised: [Equation]

Original: Proof.
Revised: Proof.

Original: We apply [54] Theorem 2 to target domain µ T = µ c and joint source domain µ S = 1 /K
Revised: We apply [54] Theorem 2 to target domain µ T = µ c and joint source domain µ S = 1 /K

Original: (cid:80)
Revised: (cid:80)

Original: Kk
Revised: Kk

Original: =1 µ c k with empirical samples ˆ µ T =
Revised: =1 µ c k with empirical samples ˆ µ T =

Original: ˆ µ c and ˆ µ S = 1 /K (cid:80)
Revised: ˆ µ c and ˆ µ S = 1 /K (cid:80)

Original: Kk
Revised: Kk

Original: =

Revised: =

Original: ˆ µ c k .
Revised: ˆ µ c k .

Original: B.3 Encoder versus Prediction Network Error
Revised: B.3 Encoder versus Prediction Network Error

Original: Our goal is to learn a joint hypothesis h over the entire domain X in two steps, first inferring the task c and then inferring x t +1 conditioned on c .
Revised: Our goal is to learn a joint hypothesis h over the entire domain X in two steps, first inferring the task c and then inferring x t +1 conditioned on c .

Original: Error from DyAd may result from either the encoder g ϕ or the prediction network f θ .
Revised: Error from DyAd may result from either the encoder g ϕ or the prediction network f θ .

Original: Our hypothesis space has the form { x
Revised: Our hypothesis space has the form { x

Original: (cid:55)→ f θ ( x, g ϕ ( x )) } where ϕ and θ are the weights of the encoder and prediction network respectively.
Revised: (cid:55)→ f θ ( x, g ϕ ( x )) } where ϕ and θ are the weights of the encoder and prediction network respectively.

Original: Let ϵ X be the error over the entire domain X , that is, for all c .
Revised: Let ϵ X be the error over the entire domain X , that is, for all c .

Original: Let ϵ enc ( g ϕ ) =
Revised: Let ϵ enc ( g ϕ ) =

Original: E x ∼X
Revised: E x ∼X

Original: ( L 1 ( g ( x ) , g ϕ ( x )) be the encoder error where g : X → C is the ground truth.
Revised: ( L 1 ( g ( x ) , g ϕ ( x )) be the encoder error where g : X → C is the ground truth.

Original: We state a result that decomposes the final error into that attributable to the encoder and that to the forecaster.
Revised: We state a result that decomposes the final error into that attributable to the encoder and that to the forecaster.

Original: Proposition B.5.
Revised: Proposition B.5.

Original: Assume c
Revised: Assume c

Original: (cid:55)→ f θ ( · , c ) is Lipschitz continuous with Lipschitz constant γ uniformly in θ .
Revised: (cid:55)→ f θ ( · , c ) is Lipschitz continuous with Lipschitz constant γ uniformly in θ .

Original: Then we bound
Revised: Then we bound

Original: [Equation] [Equation]
Revised: [Equation] [Equation]

Original: where the first term is the error due to the encoder incorrectly identifying the task and the second term is the error due the prediction network alone.
Revised: where the first term is the error due to the encoder incorrectly identifying the task and the second term is the error due the prediction network alone.

Original: The hypothesis in the second term consists of the prediction network combined with the ground truth task label x
Revised: The hypothesis in the second term consists of the prediction network combined with the ground truth task label x

Original: (cid:55)→ f θ ( x, g ( x )) .
Revised: (cid:55)→ f θ ( x, g ( x )) .

Original: In practice, the Lipschitz constant γ of the encoder may be indirectly minimized through weight decay.
Revised: In practice, the Lipschitz constant γ of the encoder may be indirectly minimized through weight decay.

Original: Proof.
Revised: Proof.

Original: By the triangle inequality and linearity of expectation,
Revised: By the triangle inequality and linearity of expectation,

Original: [Equation]
Revised: [Equation]

Original: By Lipschitz continuity,
Revised: By Lipschitz continuity,

Original: [Equation]
Revised: [Equation]

Original: which, since g ( x ) = c and by linearity of expectation,
Revised: which, since g ( x ) = c and by linearity of expectation,

Original: [Equation]
Revised: [Equation]

Original: by definition of ϵ enc and ϵ c ,
Revised: by definition of ϵ enc and ϵ c ,

Original: [Equation]
Revised: [Equation]

Original: γϵ enc
Revised: γϵ enc

Original: [Equation]
Revised: [Equation]

Original: [Equation]
Revised: [Equation]

Original: By combining Theorem B.1, Proposition B.5, and Theorem B.4, we can bound the generalization error in terms of the empirical error of the prediction network on the source domains, the Wasserstein distance between the source and target domains, and the empirical error of the encoder.
Revised: By combining Theorem B.1, Proposition B.5, and Theorem B.4, we can bound the generalization error in terms of the empirical error of the prediction network on the source domains, the Wasserstein distance between the source and target domains, and the empirical error of the encoder.

Original: Let G =
Revised: Let G =

Original: { g ϕ : X → C} be the task encoder hypothesis space.
Revised: { g ϕ : X → C} be the task encoder hypothesis space.

Original: Denote the empirical risk of the encoder g ϕ with respect to X by ˆ ϵ enc ( g ϕ ) .
Revised: Denote the empirical risk of the encoder g ϕ with respect to X by ˆ ϵ enc ( g ϕ ) .

Original: Proposition B.6.
Revised: Proposition B.6.

Original: Assuming the hypotheses of Theorem B.1, Proposition B.5, and Theorem B.4,
Revised: Assuming the hypotheses of Theorem B.1, Proposition B.5, and Theorem B.4,

Original: [Equation]
Revised: [Equation]

Original: Proof.
Revised: Proof.

Original: We provide an upper bound for the right-hand side of (4).
Revised: We provide an upper bound for the right-hand side of (4).

Original: By Theorem B
Revised: By Theorem B

Original: [Equation]
Revised: [Equation]

Original: 1 or [44], Theorem 3.3, we can bound
Revised: 1 or [44], Theorem 3.3, we can bound

Original: [Equation]
Revised: [Equation]

Original: In order to apply Theorem B
Revised: In order to apply Theorem B

Original: [Equation]
Revised: [Equation]

Original: 1 to the risk ϵ c and relate it to the empirical risk
Revised: 1 to the risk ϵ c and relate it to the empirical risk

Original: [Equation]
Revised: [Equation]

Original: we first relate the error on the target domain back to the source domain of our empirical samples.
Revised: we first relate the error on the target domain back to the source domain of our empirical samples.

Original: By Theorem B.4,
Revised: By Theorem B.4,

Original: [Equation]
Revised: [Equation]

Original: Applying Theorem B
Revised: Applying Theorem B

Original: [Equation] [Equation]
Revised: [Equation] [Equation]

Original: this is
Revised: this is

Original: [Equation]
Revised: [Equation]

Original: + (cid:112)
Revised: + (cid:112)

Original: [Equation]
Revised: [Equation]

Original: log(1 /δ )
Revised: log(1 /δ )

Original: (cid:16)(cid:112) 1 /n + (cid:112)
Revised: (cid:16)(cid:112) 1 /n + (cid:112)

Original: [Equation]
Revised: [Equation]

Original: ( nK ) (cid:17)
Revised: ( nK ) (cid:17)

Original: [Equation]
Revised: [Equation]

Original: λ
Revised: λ

Original: [Equation]
Revised: [Equation]

Original: Substituting (5) and (7) into (4) gives
Revised: Substituting (5) and (7) into (4) gives

Original: [Equation]
Revised: [Equation]

Original: [Equation]
Revised: [Equation]

Original: Using linearity of the expectation over c , removing it where there is no dependence on c , and rearranging terms.
Revised: Using linearity of the expectation over c , removing it where there is no dependence on c , and rearranging terms.

Original: Although this result does not settle either the question of end-to-end versus pre-training or encoderforecaster versus monolithic model, it quantifies the trade-offs these choices depend on.
Revised: Although this result does not settle either the question of end-to-end versus pre-training or encoderforecaster versus monolithic model, it quantifies the trade-offs these choices depend on.

Original: We empirically consider both questions in the experiments section.
Revised: We empirically consider both questions in the experiments section.