Title: On Imitation in Mean-field Games
Venue: NeurIPS 2023
Accepted: yes
Keywords: Mean-field games

Imitation Learning
Abstract: We explore the problem of imitation learning (IL) in the context of mean-field games (MFGs), where the goal is to imitate the behavior of a population of agents following a Nash equilibrium policy according to some unknown payoff function. IL in MFGs presents new challenges compared to single-agent IL, particularly when both the reward function and the transition kernel depend on the population distribution. In this paper, departing from the existing literature on IL for MFGs, we introduce a new solution concept called the Nash imitation gap. Then we show that when only the reward depends on the population distribution, IL in MFGs can be reduced to single-agent IL with similar guarantees. However, when the dynamics is population-dependent, we provide a novel upper-bound that suggests IL is harder in this setting. To address this issue, we propose a new adversarial formulation where the reinforcement learning problem is replaced by a mean-field control (MFC) problem, suggesting progress in IL within MFGs may have to build upon MFC.

On Imitation in Mean-field Games

Abstract

We explore the problem of imitation learning (IL) in the context of mean-field games (MFGs), where the goal is to imitate the behavior of a population of agents following a Nash equilibrium policy according to some unknown payoff function. IL in MFGs presents new challenges compared to single-agent IL, particularly when both the reward function and the transition kernel depend on the population distribution. In this paper, departing from the existing literature on IL for MFGs, we introduce a new solution concept called the Nash imitation gap. Then we show that when only the reward depends on the population distribution, IL in MFGs can be reduced to single-agent IL with similar guarantees. However, when the dynamics is population-dependent, we provide a novel upper-bound that suggests IL is harder in this setting. To address this issue, we propose a new adversarial formulation where the reinforcement learning problem is replaced by a mean-field control (MFC) problem, suggesting progress in IL within MFGs may have to build upon MFC.

1 Introduction

Imitation learning (IL) is a popular framework involving an apprentice agent who learns to imitate the behavior of an expert agent by observing its actions and transitions. In the context of mean-field games (MFGs), IL is used to learn a policy that imitates the behavior of a population of infinitely-many expert agents that are following a Nash equilibrium policy, according to some unknown payoff function. Mean-field games are an approximation introduced to simplify the analysis of games with a large (but finite) number of identical players, where we can look at the interaction between a representative infinitesimal player and a term capturing the population's behavior. The MFG framework enables to scale to an infinite number of agents, where both the reward and the transition are populationdependent. The aim is to learn effective policies that can effectively learn and imitate the behavior of a large population of agents, which is a crucial problem in many real-world applications, such as traffic management [12, 30, 31], crowd control [11, 1], and financial markets [6, 5].

IL in MFGs presents new challenges compared to single-agent IL, as both the (unknown) reward function and the transition kernel can depend on the population distribution. Furthermore, algorithms will depend on whether we can only observe the trajectories drawn from the Nash Equilibrium (NE) or if we can access the MFG itself, either driven by the expert population or the imitating one.

The main question we address is whether IL in MFGs is actually harder than IL in single-agent settings and if we can use single-agent techniques to solve IL in the MFGs framework.

Although there exist IL algorithms for MFGs in the literature, none comes with a characterization of the quality of the learnt imitation policy. We will also explain that they essentially amount to a reduction to classic IL, and explain the underlying possible issues. So as to compare algorithms on a

rational basis, we provide an extension of the concept of imitation gap to this setting and study it. Our contributions are:

We introduce a new solution concept for IL in MFGs called Nash imitation gap , which is a strict generalization of the classic imitation gap and that we think may be more widely applicable to Multi-agent Reinforcement Learning.

In light of this new criterion, we first study the setting where only the reward depends on the population's distribution, while the dynamics does not. This setting was largely studied in the past few years [16, 4, 1, 14, 22], and we show that in this case IL in MFGs reduces to single-agent IL with similar guarantees for Behavioral Cloning (BC) and Adversarial Imitation (ADV) type of algorithms.

Then, we provide a similar analysis in the more general setting where the dynamics depends on the population's distribution. In this case, we provide for BC and ADV approaches upper-bounds that are exponential in the horizon, suggesting that IL is harder in this setting. On an abstract way, all previous works of the existing literature correspond to this setting.

Due to these negative results, we introduce a new proxy to the Nash imitation gap, for which we can derive a quadratic upper bound on the horizon. Then, we discuss how a practical algorithm could be designed with an adversarial learning viewpoint. The idea behind it is to use an approach similar to adversarial IL, where the underlying RL problem is replaced by a Mean-Field Control (MFC) problem. We leave the design and experimentation of practical algorithms for future works, but this suggests that making progress on IL in MFGs may have to build upon MFC. We also provide a numerical illustration empirically supporting our claims in the appendix.

2 Background

2.1 Mean-field Games

Intuitively, an MFG corresponds to the limit of an N -player game when N tends towards infinity. We focus on the finite-horizon setting, in discrete time, and with finite state and action spaces. Mathematically, the MFG is defined by a tuple M = ( S , A , P, r, H, ρ 0 ) where S is a finite state space, A is a finite action space, P : S × A × ∆ S → ∆ S is a transition kernel, r : S × A × ∆ S → R is a reward function, H is a finite horizon and ρ 0 ∈ ∆ S is a distribution over initial states. The first and second inputs of P and r represent respectively the individual player's state and action, while the third input represents the distribution of the population. This allows the model to capture interactions or mean field type. We denote [ H -1] = { 0 , . . . , H -1 } . Since the problem is set in finite time horizon, we consider non-stationary stochastic policies of the form π = ( π 0 , . . . , π H -1 ) where for each n ∈ [ H -1] , π n : S → ∆ A . This means that, at time n , a representative player whose state is s n ∈ S picks an action according to π n ( s n ) . We will also view π n as a function from S × A to [0 , 1] and use the notation π n ( a | s n ) to denote the probability to pick action a according to π n ( s n ) . We also introduce the set of population-independent non-stationary rewards uniformly bound by 1, that will be useful later, R = { r : S × A × [ H -1] → [ -1 , 1] } .

When a player is at state s and uses action a while the population distribution is ρ , it gets the reward r ( s, a, ρ ) . In a finite-player game, ρ would be replaced by the empirical distribution of the other players' states. These players would be influenced by the player under consideration, leading to complex interactions. However, the influence of a single player on the population distribution becomes smaller as the number of players increases. In the limit, we can expect that each player has no influence on the distribution. We will use interchangeably the terms 'agent' and 'player'.

The MFG framework allows us to formalize this idea. So the problem faced by a single representative player is a Markov Decision Process (MDP), in which the distribution is fixed: Given a mean field sequence ρ = ( ρ n ) n ∈ [ H -1] , the player wants to find a policy π maximizing the value function V defined by:

where S 0 is distributed according to the initial state distribution ρ 0 , A n ∼ π n ( S n ) , and S n +1 ∼ P ( S n , A n , ρ n ) . The resulting policy is called a best response to the mean field ρ . We will sometime write V r ( π , ρ ) to make explicit to reward of the value function.

Definition 1 (Best response) . A policy π is a best response to ρ if: V ( π , ρ ) = max π ′ V ( π ′ , ρ ) .

Intuitively, ρ is a Nash equilibrium if it is the distribution sequence obtained when all the players use a best response policy against ρ . To formalize this idea, we introduce the notion of population distribution sequence induced by a policy that does influence the transition kernel.

Definition 2 (Population distribution sequence) . We denote by ρ ( π ) the state-distribution sequence induced by the population following policy π , which is defined as:

The state-action distribution sequence, denoted by µ ( π ) , is defined as:

We can now give a formal definition of Nash equilibrium. 1

Definition 3 (Nash equilibrium) . A policy π is called a Nash equilibrium policy if it is a best response against ρ π , i.e., π is a maximizer of π ′ ↦→ V ( π ′ , ρ π ) . The distribution sequence ρ π induced by a Nash equilibrium policy π is called a Nash equilibrium mean field sequence.

The value function can be written without expectation by introducing the state and state-action distributions for a single agent, which does not influence the transition kernel (only the population does, it is a core reason for considering the mean-field limit).

Definition 4 (Single-agent distribution sequence) . Consider an agent using policy π ′ who evolves among a population using policy π . We denote by ρ ( π ) π ′ the state-distribution sequence of this single agent, which is defined by:

From these definitions we directly have that ρ ( π ) π = ρ ( π ) and µ ( π ) π = µ ( π ) . Furthermore, for any policies π and π ′ , we define a generalized value function

Definition 5 (Exploitability) . The exploitability of a policy π quantifies the gain for a representative player to replace its policy by a best response:

A Nash equilibrium policy can be defined equivalently as a policy such that its exploitability is 0 .

Finding a Nash Equilibrium policy is different from trying to maximize the value function, which can be interpreted as a social optimum. This problem is sometimes referred to as mean field control problem (MFC) because it can be interpreted as an optimal control for an MDP where the state is augmented with the distribution.

Definition 6 (Social optimum) . A policy π is socially optimal if V ( π , ρ π ) = max π ′ V ( π ′ , ρ π ′ ) .

In general the Nash equilibrium and the social optimum do not coincide, i.e., the MFG policy and the MFC solution can be different. In other words, if π is an MFG solution, then we might have V ( π , ρ π ) < max π ′ V ( π ′ , ρ π ′ ) , and if π is an MFC policy, then we might have E ( π ) = 0 .

/negationslash

In this work, we will frequently make two common assumptions (e.g., [2, Asm. 1], or [34, Asm. 1]).

Assumption 1. The reward function r and the transition kernel P are Lipschitz continuous w.r.t. the population distribution and have corresponding Lipschitz constants L r and L P . In particular, for any state-action pair ( s, a ) it holds for any state distributions ρ , ρ ′ ∈ ∆ S that

These assumptions mean that the reward and the transitions depend on the mean field in a smooth way. For example, r ( s, a, ρ ) = -c r ρ ( s ) + ˜ r ( s, a ) satisfies the assumption with L r = c r . A reward of this form penalizes the agent for being in a crowded state. In particular, these assumptions imply that r and P are continuous with respect to the distribution and since S and A are finite sets and we consider a discrete-time, finite horizon MFG, these assumptions are sufficient to ensure existence of a Nash equilibrium, see e.g. [10, Proposition 1].

Note that these assumptions do not assume that L r or L P need to be small. However, we will consider separately the case L P = 0 , which has received attention in the MFG literature and which corresponds to situations where the mean-field interactions occur through the reward only. Note that when L P = L r = 0 , then there are no interactions so the Nash equilibrium condition becomes trivial and the problem reduces to a single agent MDP. We will write the value function as V ( π ) .

2.2 Classic imitation learning

The single-agent setting is a special case of the above, with L P = L r = 0 . In this case, the Imitation Learning (IL) problem has been extensively studied [20]. In IL we assume that we observe state-action trajectories generated by an expert who is using an optimal policy π E , i.e., π E ∈ argmax V ( π ) . We do not know π E , V , r nor P . The goal is to learn a policy, denoted by π A , which performs as well as the expert policy π E according to the unknown reward: V ( π A ) = V ( π E ) = max π ′ V ( π ′ ) .

Given the imitation policy π A , the imitation gap is a non-negative quantity defined by V ( π E ) -V ( π A ) [29]. The goal is to learn a policy π A whose imitation gap is as close to 0 as possible. However, when we do not know the model, this quantity cannot be minimized directly. For this reason, different methods were introduced in literature. Here we focus on the following two prominent methods: Behavioral Cloning (BC) [24] and adversarial IL such as Generative Adversarial IL (GAIL) [18].

For simplicity, we will denote ρ E = ρ ( π E ) π E , µ E = µ ( π E ) π E , ρ A = ρ ( π A ) π A , and µ A = µ ( π A ) π A . When the dynamics does not depend on the population ( L P = 0 ), we will write ρ π = ρ ( π any ) π , µ π = µ ( π any ) π , as the population driven by π any has no effect on the transition kernel.

Behavioral Cloning. In this work, we frame BC as minimizing the expected /lscript 1 -distance between the action probability distributions of the expert and the imitation policy, where the expectation is over the expert state occupancy. Although in practice it consists in a reverse KL-divergence, or equivalently as the maximum likelihood estimation in supervised learning, here we consider the /lscript 1 -norm distance (or scaled total variation), which is more convenient for the analysis. However, the analysis could be adapted to this maximum likelihood estimation with minor changes thanks to Pinsker's inequality (see App. A). In the finite-horizon case, one obtains a bound on quantities of the form:

That is, we solve one BC problem per time-step, from data generated by an expert. The single-agent imitation-learning gap is bounded by O ( /epsilon1 BC H 2 ) , where /epsilon1 BC = max n ∈ { 0 ,...,H -1 } /epsilon1 BC n [26]. We will retrieve this result as a special case of our analysis.

Adversarial Imitation Learning. Using adversarial-like approaches [18, 13] we control a distance or divergence between the state-action occupancy measures of the expert and the imitation policy. In the single-agent IL setting this divergence can be expressed as:

Similar IL quantities are extensively studied in the single-agent case, leading to algorithms minimizing a divergence or distance such as Generative Adversarial Imitation Learning [18] or IQ-learn [13]. If we control the state-action occupancy measure errors, then we get a single-agent imitation-learning gap of order O ( /epsilon1 ADV H ) , where /epsilon1 ADV = max n ∈ [0 ,...,H -1] /epsilon1 ADV n , gaining an H factor compared to the BC bound [32].

To make the link to adversarial approaches, controlling the terms of Eq. (2) can be achieved through the following equivalent formulation, based on the Integral Probability Metric (IPM) formulation of the total variation (see Appx. B for a detailed derivation and additional discussions):

with R defined in Sec. 2.1 (non-stationary population-independent rewards functions uniformly bounded by 1). This form is similar to classic adversarial imitation approach, learning both a reward function and a policy, the inner problem being a reinforcement learning (RL) problem. Previous work usually consider an f -divergence [15, 19] between state-action occupation measures, which leads to different min-max problems. However, in this paper, we will focus on the /lscript 1 -distance, that we think is a meaningful and practical abstraction of adversarial approaches. Our results could be extended to other settings by using tools like the Pinsker inequality.

Remark 1. Remember that in the single-agent case (same as when we have L P = L r = 0 ) the transition dynamics and the reward function do not depend on the population distribution. In the mean-field game, on the other hand, the transition dynamics and the reward function can depend on the population distribution. For this reason, we need to consider different quantities to be controlled. We will see more about it in the next section.

3 Related works

We provide a commented review of the literature focusing on the fundamentals of the different approaches, their pros and their cons.

To the best of our knowledge, the first work addressing the IL problem in MFGs is [33]. The authors consider a discrete-time MFG over a complete graph, and they propose a reduction from MFGs to finite-horizon MDP (with a population-augmented state) and then use single-agent IL algorithms on the new MDP. In the reduction, the new reward function is computed in the following way: r ( ρ , π ) = ∑ s ρ ( s ) ∑ a π ( a | s ) r ( s, a, ρ ) , considering that the state is the population distribution ρ and the actions are the possible policies π . Using this reduction, the authors implicitly assume that the observed expert is solving an MFC problem, i.e. she is looking for a socially optimal policy (see Def. 6). However, in general, this does not actually coincide with a Nash Equilibrium policy (see Def. 3). Then, the reduction works only for cooperative MFGs, but it is prone to biased reward inference in non-cooperative environments.

The first work enlightening this issue is [8]. The authors consider a discounted finite-horizon MFG and propose a novel method called Mean Field IRL. They reframe the problem as finding a reward function that makes the expert policy π E the best response with respect to the expert population distribution ρ E , i.e., find a population-dependent r such that V ( π E , ρ E ) ∈ argmax π V ( π , ρ E ) . To solve this problem they use a max-margin approach similar to [25] in the single-agent case. In fact, fixing the population distribution ρ E , the MFG is reduced to an MDP, and the imitation problem is reduced to single-agent IL. However, since they do not have access to the actual population distribution ρ E , they need to estimate it from samples. In this way, the authors do not have any actual theoretical guarantee on the performances of the recovered policy, since it depends on the estimation of ρ E .

Recently, [9] proposed a novel approach reusing ideas from adversarial learning [18] and maximum entropy [36]. The authors assume they have access to an expert optimizing a meanfield-regularized Nash-equilibrium, i.e., the value-function has an additional regularization term: V ( π ′ , ρ π ) = ∑ H -1 n =0 ∑ s { H ( π ′ ( ·| s )) + ∑ a µ ( π ) π ′ n ( s, a ) r ( s, a, ρ ( π ) n ) } , with H the Shannon entropy. This term guarantees that the MFG has a unique equilibrium solution, and only one best response policy. Then, they assume to have access to the population distribution ρ E , or to be able to estimate this population distribution from samples. Fixing the population distribution, the MFG problem reduces to the single-agent setting, which allows applying GAIL [18] or maximum entropy IRL to learn an approximate policy π A . This leads to two main problems. (i) We are actually estimating ρ E from samples, trying to find a policy which gives us the true ρ E ; this circulating reasoning leads to many estimation errors. (ii) From an abstract viewpoint, the final theoretical guarantee we can hope to have for the recovered policy π A would approximately be ‖ µ ( π E ) π A -µ ( π E ) π E ‖ 1 (in practice for a different distance or divergence, but involving the same occupancy measures), which may not

be sufficient as we will show in Sec. 4.2. We will see that the upper-bound for this case has an exponential dependency on the horizon.

In [35], the authors assume observing an MFG where the agents are acting according to a correlated equilibrium. The authors justify the study of a correlated equilibrium by some applications where we can have access to some correlation device (e.g., traffic network equilibrium induced from the public routing recommendations). Similar to [9], the authors of this work reuse ideas from adversarial learning [18] to recover a policy observing a correlated equilibrium policy. As in [9] they fix the population distribution to be the expert one and then apply single-agent GAIL to the problem. Then, although the solution concept is different, this approach faces similar problems as in [9], where instead the authors considered to observe an expert following a Nash Equilibrium policy. We will focus on experts achieving a Nash equilibrium. Extending our results (see Sec. 4) to more general equilibria such as coarse correlated ones is an interesting future research direction.

Notice also that all GAIL-like approaches discussed above learn an intermediate population-dependent reward function. This is complicated (as the population is a distribution over the state space, generally difficult to represent compactly), and in fact superfluous in their setting. Indeed, as all these approaches assume that the interaction is done with the MFG driven by the expert population (or a given approximation of it), it is sufficient to consider an intermediate population-independent but non-stationary reward. This will appears clearly in the IPM formulations we propose in Sec. 4.

4 Nash imitation gap and imitation in MFGs

We consider the imitation learning problem in MFGs. Similar to single-agent IL, we observe the interactions between an expert and a fixed MFG environment, for which we do not know the reward function r nor the transition kernel P . We only observe samples coming from an expert policy denoted by π E , which we assume to be a Nash equilibrium policy, i.e., E ( π E ) = 0 . In single-agent IL the goal is clear: Find a policy π A to minimize the imitation gap max π V ( π ) -V ( π A ) . However, in MFG, the goal is less clear. Previous works focused on solving IL for a single agent in a population that stays at equilibrium, but this is not relevant for many applications, in which the population might use the learnt policy. The learnt policy should thus not only be good at the individual level, but it should also be an equilibrium policy. As a first contribution, we propose a natural formulation for studying the performance of imitation learning in MFG, called Nash imitation gap:

Definition 7. The Nash imitation gap (NIG) of a policy π A is defined as:

Therefore, the NIG is simply defined as being the exploitability of the considered policy. The NIG has many interesting and useful properties. (i) If it is zero, the recovered policy π A is a Nash equilibrium policy. (ii) It is a generalization of the single-agent imitation gap (see above and Sec. 2.2), which is recovered as a special case when L P = L r = 0 .

As for the single-agent imitation gap, we cannot optimize it directly, since we do not know the reward function, but instead we can envision proxys, such as reducing the distance between the recovered policy π A and the expert policy π E (BC-like) or their occupancy measures (GAIL-like) as in the classic IL setting (see Sec. 2.2). In this section, we first discuss the imitation learning problem when the dynamics does not depend on the population, i.e. L P = 0 , a common setting largely explored in the last years [22, 23]. Then, we present our results for the general setting when the dynamics depends on the population, i.e. when L P > 0 .

For what follows, in addition to the Lipschitz assumption (Asm. 1), we will also assume that the unknown reward function r for which the expert π E is a Nash equilibrium is uniformly bounded when the population is the expert one.

Assumption 2. The unknown reward r satisfies

4.1 Population-independent dynamics: a reduction to classic imitation

We start by analyzing a simpler but commonly used setting (e.g., see [23] in the context of reinforcement learning methods, or [16, 4, 1] in the context of the analysis of discrete or continuous space

MFGs), where the dynamics does not depend on the population. Here the MFG interaction is without reward and it is only the (unknown) reward function that depends on the population. This setting is equivalent to observing an interaction between an expert and an MDP, since the state-distribution does not depend on the population, i.e., ρ ( π ) π ′ = ρ π ′ .

Behavioral Cloning. The behavioral cloning setting is the same as the single agent setting (see Sec. 2.2), i.e, we control:

where π E is the expert policy and π A the imitation policy. Under the assumption of the BC-type error, we give the following bound on the Nash imitation gap (proof in Appx. C).

Theorem 1. Let /epsilon1 BC = max n 0 ,...,H 1 /epsilon1 BC n . If L P = 0 , the Nash imitation gap satisfies

Theorem 1 shows that when L P = 0 we recover the single-agent imitation learning bound. Perhaps surprisingly, the simple BC approach was not previously considered for MFG, to the best of our knowledge.

Adversarial learning. In the adversarial setting, similar to the single-agent case (see Sec. 2.2) we control a distance or divergence between occupancy measures. More precisely, we consider the following distance between occupancy measures:

It is important to recall that in this setting, the dynamics do not depend on the population, thus µ ( π ) π ′′ = µ ( π ′ ) π ′′ for every triplet of policies ( π , π ′ , π ′′ ) .

Since in this case the dynamics do not depend on the population distribution, the same IPM approach (see Eq. (3)) of single-agent imitation-learning also works in this context. Then we can practically solve the MFG IL problem using GAIL-like approaches [18, 15, 19, 13].

We now provide a novel bound on the Nash imitation gap (proof in Appx. C).

Theorem 2. Let /epsilon1 ADV = max n ∈ { 0 ,...,H -1 } /epsilon1 ADV n . If L P = 0 , the Nash imitation gap satisfies

In contrast to the quadratic horizon dependence in Theorem 1, we derive here a linear horizon dependence. Furthermore, the bound in Theorem 2 is almost the same (similarly to the BC case) as in the single-agent IL problem. In fact, it recovers the bound of [32] by setting L r = 0 .

Discussion. When L P = 0 interacting with the MFG without reward amounts to interact with and MDP without reward, so from a practical aspect any classic IL approach could be used, including Dagger-like approaches [27] that we do not analyse here. Our upper bounds show that when the dynamics is independent of the population, IL for MFG has similar guarantees as in singleagent imitation learning. In fact, our results suggest that a population-dependent unkown reward function affects the IL policy performance very moderately (through the L r constant). However, new challenges may arise if we also want to recover the reward function, as in the case of Inverse Reinforcement Learning. We leave this interesting research direction for future work.

4.2 Population-dependent dynamics

When the dynamics of the MFG depend on the population, i.e., L P > 0 , then the previous results do not apply anymore. In this section, we present results on MFGs with population-dependent dynamics, for the same proxys introduced above (BC and adversarial).

Behavioral Cloning. The BC proxy to the NIG is the same as in Equation (4). In this case, however, the bound we get is no longer comparable to the classic IL setting (proof in Appx. C).

Theorem 3. Let /epsilon1 BC = max n ∈ { 0 ,...,H -1 } /epsilon1 BC n . If L P > 0 , the Nash imitation gap satisfies:

We observe that when the dynamics depend on the population, the dependence on the horizon is no longer quadratic but exponential. From a technical viewpoint, this comes from the dependency of the transition kernel to the population. A worse dependency makes sense intuitively. In the classic IL setting, an error on policies will amplify at the occupancy measure level (drift phenomenon in imitation learning). Here, this problem is even more amplified by the fact that the transition kernel that defines the occupancy measure itself depends on the related population, amplifying even more the imitation error. Sec. 5 provides some empirical evidence that IL in MFGs has an exponential dependence on the horizon for BC as L P increases.

Although we cannot claim our result is tight, this suggests that in MFGs we cannot hope to use BC to obtain a good imitation policy π A , but we need to control the divergence between the state-action occupancy induced by π A and the one induced by π E .

Adversarial learning. In contrast to the population-independent case, the quantity to control in this setting is not trivial. In fact, it depends on the MFG interaction assumption. We can assume to have the possibility to interact with only the MFG or with the MFG driven by ρ E . These two types of interactions lead us to consider two different errors. We start by considering the error we would like to minimize if we can interact with the MFG driven by the expert population ρ E . Assuming access to this MFG, the IL problem reduces to doing classic IL in an MDP without reward and with transition distribution P ( ·| s, a, ρ π E ) . The error is defined as follows:

This assumption was implicitly made in all previous works (see Sec. 3), where the authors assume to fix the expert distribution ρ E and then solve the IL problem. However, assuming to have access to the expert distribution may not be reasonable in practice, and due to this in [9, 8] the authors replace the expert population distribution ρ E with its approximation from sampling ˆ ρ E , in order to learn µ ( π E ) π A . In reality, however, we seek to learn µ ( π E ) π A and then ρ E , which is the ultimate goal of the problem. This circular reasoning leads to not easily having theoretical guarantees for this setting.

In this case, for obtaining an adversarial formulation, we can use a similar approach as the one for the non-population dependent dynamics, Eq. (3), providing (details in Appx. B):

We can observe that the inner problem is again an RL problem (for the MDP induced by ρ ( π E ) ), and in practice any single-agent adversarial approach could be applied to solve for a similar proxy (related to a different min-max problem).

We provide a bound for this approach (proof in Appx. C).

Theorem 4. Let /epsilon1 vanilla -ADV = max n ∈ { 0 ,...,H -1 } /epsilon1 vanilla -ADV n . If L P > 0 the NE imitation gap satisfies:

Therefore, in this case, if in practice we can apply GAIL-like approaches to the MDP with transition distribution P ( ·| s, a, ρ E ) , we have an exponential dependency in the horizon. Interestingly this is close to the quantity that previous works [9, 8] tried to control. Although we do not know if this bound is tight, reasonably controlling this quantity can lead to weak theoretical guarantees. Sec. 5 provides empirical evidences that, when H and L P are large enough, vanilla-ADV exponential depends on the horizon like BC.

4.3 Population-dependent dynamics: a new efficient proxy

Although the vanilla-ADV error is a reasonable quantity to control, another interesting proxy is to consider state-action occupancy measures with population induced by the associated policy, namely

To control this quantity, we do not need to have access to the expert population (except through data), we can directly interact with the MFG, driven by what we are learning. As we explained in Sec. 4.1,

if L P = 0 then this quantity is the same as the vanilla-ADV error. Before presenting and discussing an adversarial formulation (that will explain the naming choice for the error), we provide a novel bound for this quantity (proof in Appx. C):

This gives us a significant improvement compared to the BC case and the vanilla-ADV error. Indeed, the dependency to the horizon is now quadratic and not anymore exponential. Comparing this result with classic imitation learning we have worse dependency on H , since in the classic setting is only linear (we can recover this dependency when L P = 0 ). However, as explained before, the fact that the transition kernel does depend on the population indeed intuitively implies a larger amplification of errors. Sec. 5 provides empirical evidence that this approach is better than the previous two, with much less influence from H and L P .

Now, we provide an adversarial formulation, to get a sense of what a practical algorithm could look like. Using again an IPM argument, we have that (details in Appx. B)

Notice that it is not obvious if we can switch the min and the max here, due to the underlying set of policy-induced occupancy measures being not necessarily convex (due to the dependency of the dynamics on the population). Assuming we can, we still learn an intermediate population-independent non-stationary reward, but now the underlying control problem is no longer RL, it is an MFC problem, as it implies studying max π V f ( π , ρ ( π ) ) , where the population does depend on the optimized policy. This suggests that in practice one could start from a classic adversarial IL approach, and replace the underlying RL algorithm by an inner MFC algorithm (e.g. [28, 7, 21, 17, 3]). We leave the design and implementation of such a practical algorithm for future work, which may be more complex than a straight replacement of the control part (notably, many MFC approaches learn a population-dependent policy). However, this overall suggests that making progress on IL for MFGs may have to build upon MFC.

5 Simulation

In order to provide some empirical evidences of the insights given by our analysis (influence of the horizon and the dependency of the dynamics to the population on the various considered proxys to the Nash imitation gap), we introduce the 'Attractor MFG' (see more details about it in App. D). This is a 2-state and 2-action MFG with initial distribution satisfying ρ 0 ( s 0 ) = 1 , with horizon H and with Lipschitz parameter L . The reward only depends on the state (not on the distribution nor the

action) and satisfies for all a ∈ A , ρ ∈ ∆ S ,

In the state s 1 , any choice of actions leads deterministically to s 1 , the transition kernel satisfies P ( s 1 | s 1 , a, ρ ) = 1 for all a ∈ A , ρ ∈ ∆ S . In the state s 0 , the action a 0 leads deterministically to s 1 , while action a 0 leads stochastically to one of the two states: the higher the fraction of the population in s 1 , the higher the chance to transit to s 1 after choosing a 0 :

Therefore, the state s 1 is an attractor, hence the chosen name for the MFG.

The experiment consists in computing the errors /epsilon1 BC n , /epsilon1 vanilla -ADV n , and /epsilon1 MFC -ADV n for various values of L = { 0 . 01 , 0 . 05 , 0 . 1 , 0 . 5 } and H = { 3 , 25 , 50 , 75 , 100 } and we show the NIG as a function of the mentioned errors. From Fig. 1, we can observe an exponential dependency of the horizon for both BC and vanilla-ADV when L increases, while this does not happen for MFC-ADV. This experiment demonstrates empirically what our theoretical upper bound shows, supporting the insights of our analysis. This suggests that a practical algorithm for IL in MFGs needs to minimize the MFC-ADV error (see Section 4.2). In Appx. D we provide more experimental results.

6 Conclusion

In this paper, we have studied the recent question of imitation learning in mean-field games. We have reviewed the few previous works tackling this problem and provided a critical discussion on the proposed approach. We then have introduced the new solution concept of Nash imitation gap to quantify the quality of imitation. In the simpler case of a population-independent dynamics, we have shown that the problem basically reduces to single-agent imitation learning, and that abstractions of the canonical BC and adversarial approaches come with a similar performance guarantee. In the harder population-dependent case, we have provided upper-bounds that are exponential in the horizon, for both BC and adversarial IL, the latter being the approach adopted in previous work. We also introduce a new proxy that amounts to control different occupancy measures, not solely driven by the expert population but by the policy-induced population. From a practical viewpoint, it only implies interacting with the MFG (without access to the expert population for driving the dynamics), and from a theoretical viewpoint it enjoys a much better quadratic dependency to the horizon. The associated adversarial formulation suggests that classic adversarial IL approaches could be adapted by replacing the inner RL loop by an MFC one.

This work opens a number of interesting research questions. Our last result suggests a simple modification of existing adversarial approaches, but in practice it may be more difficult than just replacing the control part, and could call for additional research in MFC and MFGs. Maybe also that controlling other kinds of occupancy measures, or even different quantities related to the policy and dynamics, may lead to even better guarantees, ideally recovering the linear dependency to the horizon of the single-agent case. We provided upper-bounds, but there is no known associated lower-bound in this setting, which is another interesting research direction. We focused on experts achieving a Nash equilibrium, and extending our work to different kind of equilibria is another possible direction. We focused on imitating the expert, not on recovering the underlying optimized reward (inverse RL). Doing so may require a different approach, as our adversarial formulations all rely on population-independent rewards (which is convenient from a practical viewpoint, whenever one just wants to recover the policy). We also plan to work on the extension of Nash imitation gap to other kinds of games.

References

Yves Achdou and Jean-Michel Lasry. Mean field games for modeling crowd motion. Contributions to partial differential equations and applications , pages 17-42, 2019.

Berkay Anahtarci, Can Deha Kariksiz, and Naci Saldi. Q-learning in regularized mean-field games. Dynamic Games and Applications , 13(1):89-117, 2023.

Andrea Angiuli, Jean-Pierre Fouque, and Mathieu Laurière. Unified reinforcement Q-learning for mean field game and control problems. Mathematics of Control, Signals, and Systems , 34(2):217-271, 2022.

Pierre Cardaliaguet and P Jameson Graber. Mean field games systems of first order. ESAIM: Control, Optimisation and Calculus of Variations , 21(3):690-722, 2015.

Rene Carmona. Applications of mean field games in financial engineering and economic theory. arXiv preprint arXiv:2012.05237 , 2020.

René Carmona and Mathieu Laurière. Deep learning for mean field games and mean field control with applications to finance. arXiv preprint arXiv:2107.04568 , 2021.

René Carmona, Mathieu Laurière, and Zongjun Tan. Model-free mean-field reinforcement learning: mean-field MDP and mean-field Q-learning. arXiv preprint arXiv:1910.12802 , 2019.

Yang Chen, Libo Zhang, Jiamou Liu, and Shuyue Hu. Individual-level inverse reinforcement learning for mean field games. In Proceedings of the 21st International Conference on Autonomous Agents and Multiagent Systems , pages 253-262, 2022.

Yang Chen, Libo Zhang, Jiamou Liu, and Michael Witbrock. Adversarial inverse reinforcement learning for mean field games. arXiv preprint arXiv:2104.14654 , 2021.

Kai Cui and Heinz Koeppl. Approximately solving mean field games via entropy-regularized deep reinforcement learning. In International Conference on Artificial Intelligence and Statistics , pages 1909-1917. PMLR, 2021.

Christian Dogbé. Modeling crowd dynamics by the mean-field limit approach. Mathematical and Computer Modelling , 52(9-10):1506-1520, 2010.

Mohammed Elhenawy, Ahmed A Elbery, Abdallah A Hassan, and Hesham A Rakha. An intersection game-theory-based traffic control algorithm in a connected vehicle environment. In 2015 IEEE 18th international conference on intelligent transportation systems , pages 343-347. IEEE, 2015.

Divyansh Garg, Shuvam Chakraborty, Chris Cundy, Jiaming Song, and Stefano Ermon. Iq-learn: Inverse soft-q learning for imitation. Advances in Neural Information Processing Systems , 34:4028-4039, 2021.

Matthieu Geist, Julien Pérolat, Mathieu Laurière, Romuald Elie, Sarah Perrin, Oliver Bachem, Rémi Munos, and Olivier Pietquin. Concave utility reinforcement learning: The mean-field game viewpoint. In Proceedings of the 21st International Conference on Autonomous Agents and Multiagent Systems , pages 489-497, 2022.

Seyed Kamyar Seyed Ghasemipour, Richard Zemel, and Shixiang Gu. A divergence minimization perspective on imitation learning methods. In Conference on Robot Learning , pages 1259-1277. PMLR, 2020.

Diogo A Gomes, Joana Mohr, and Rafael Rigao Souza. Discrete time, finite state space mean field games. Journal de mathématiques pures et appliquées , 93(3):308-328, 2010.

Haotian Gu, Xin Guo, Xiaoli Wei, and Renyuan Xu. Mean-field controls with Q-learning for cooperative MARL: convergence and complexity analysis. SIAM Journal on Mathematics of Data Science , 3(4):1168-1196, 2021.

Jonathan Ho and Stefano Ermon. Generative adversarial imitation learning. In Advances in neural information processing systems (NeurIPS) , 2016.

Liyiming Ke, Sanjiban Choudhury, Matt Barnes, Wen Sun, Gilwoo Lee, and Siddhartha Srinivasa. Imitation learning as f-divergence minimization. In Algorithmic Foundations of Robotics XIV: Proceedings of the Fourteenth Workshop on the Algorithmic Foundations of Robotics 14 , pages 313-329. Springer, 2021.

Takayuki Osa, Joni Pajarinen, Gerhard Neumann, J Andrew Bagnell, Pieter Abbeel, Jan Peters, et al. An algorithmic perspective on imitation learning. Foundations and Trends R © in Robotics , 7(1-2):1-179, 2018.

Barna Pasztor, Ilija Bogunovic, and Andreas Krause. Efficient model-based multi-agent meanfield reinforcement learning. arXiv preprint arXiv:2107.04050 , 2021.

Julien Pérolat, Sarah Perrin, Romuald Elie, Mathieu Laurière, Georgios Piliouras, Matthieu Geist, Karl Tuyls, and Olivier Pietquin. Scaling mean field games by online mirror descent. In Proceedings of the 21st International Conference on Autonomous Agents and Multiagent Systems , pages 1028-1037, 2022.

Sarah Perrin, Julien Pérolat, Mathieu Laurière, Matthieu Geist, Romuald Elie, and Olivier Pietquin. Fictitious play for mean field games: Continuous time analysis and applications. Advances in Neural Information Processing Systems , 33:13199-13213, 2020.

Dean A Pomerleau. Efficient training of artificial neural networks for autonomous navigation. Neural computation , 3(1):88-97, 1991.

Nathan D Ratliff, J Andrew Bagnell, and Martin A Zinkevich. Maximum margin planning. In Proceedings of the 23rd international conference on Machine learning , pages 729-736, 2006.

Stéphane Ross and Drew Bagnell. Efficient reductions for imitation learning. In Proceedings of the thirteenth international conference on artificial intelligence and statistics , pages 661-668. JMLR Workshop and Conference Proceedings, 2010.

Stéphane Ross, Geoffrey Gordon, and Drew Bagnell. A reduction of imitation learning and structured prediction to no-regret online learning. In Proceedings of the fourteenth international conference on artificial intelligence and statistics , pages 627-635. JMLR Workshop and Conference Proceedings, 2011.

Jayakumar Subramanian and Aditya Mahajan. Reinforcement learning in stationary meanfield games. In Proceedings of the 18th International Conference on Autonomous Agents and MultiAgent Systems , pages 251-259, 2019.

Gokul Swamy, Sanjiban Choudhury, J Andrew Bagnell, and Steven Wu. Of moments and matching: A game-theoretic framework for closing the imitation gap. In International Conference on Machine Learning , pages 10022-10032. PMLR, 2021.

Takashi Tanaka, Ehsan Nekouei, and Karl Henrik Johansson. Linearly solvable mean-field road traffic games. In 2018 56th Annual Allerton Conference on Communication, Control, and Computing (Allerton) , pages 283-289. IEEE, 2018.

Huisheng Wang, Yuejiang Li, and H Vicky Zhao. Research on intelligent traffic control methods at intersections based on game theory. arXiv preprint arXiv:2009.05216 , 2020.

Tian Xu, Ziniu Li, and Yang Yu. Error bounds of imitating policies and environments. Advances in Neural Information Processing Systems , 33:15737-15749, 2020.

Jiachen Yang, Xiaojing Ye, Rakshit Trivedi, Huan Xu, and Hongyuan Zha. Learning deep mean field games for modeling large population behavior. arXiv preprint arXiv:1711.03156 , 2017.

Batuhan Yardim, Semih Cayci, Matthieu Geist, and Niao He. Policy mirror ascent for efficient and independent learning in mean field games. arXiv preprint arXiv:2212.14449 , 2022.

Zhiyu Zhao, Renyuan Xu, Haifeng Zhang, Jun Wang, Mingyuan Zhang, and Yaodong Yang. Imitation learning for mean field games with correlated equilibria. openreview preprint: id=VUdMeSbExWg , 2023.

Brian D Ziebart, Andrew Maas, J Andrew Bagnell, and Anind K Dey. Maximum entropy inverse reinforcement learning. In Proceedings of the 23rd national conference on Artificial intelligence-Volume 3 , pages 1433-1438, 2008.

Peer reviews:
comments: SUMMARY:
The paper presents a novel solution concept Nash imitation gap (NIG) for imitation learning problems in Mean-field games. For both population-independent and population-dependent dynamics, the author provides the upper-bounds of NIG for behavioral cloning (BC), vanilla adversarial imitation learning (vanilla-ADV), and mean-field controlling adversarial imitation learning (MFC-ADV). The empirical results show that MFC-ADV is better than vanilla-ADV which is better than BC.

STRENGTHS:
Originality: The paper proposes a novel solution concept, NIG, which generalized the classic imitation gap, and shows the upper-bounds of NIG for several different settings.
Quality: The theoretical analyze is solid and supports the upper bounds well.
Clarity: The paper is clearly written and well organized.
Significance: Both the theoretical upper bounds and the empirical results suggest that the adversarial imitation learning could replace the inner RL by an MFC.

WEAKNESSES:
No lower bound of NIG is provided so that the theoretical results cannot directly indicate which methods (BC, vanilla-ADV, MFC-ADV) is the best one.

QUESTIONS:
1. Could the upper-bounds for BC and vanilla-ADV be improved to polynomial in the horizon? Are there any evidence showing that their NIGs should be exponential in horizon?
2. Is MFC-ADV still the best one if $s_1$ is no longer a sink in the experiment? For example, $P(s_0 \vert s_1,a_0,\rho)>0$.

LIMITATIONS:
N/A
TITLE: Official Review
SOUNDNESS_CORRECTNESS: 3
DATE: 2023-07-05

{"IS_META_REVIEW": false, "comments": "SUMMARY:\nThis paper focuses on the imitation learning problem in mean-field games. The authors propose a new performance metric Nash imitation gap. They show that when the transition kernels of MDP are independent of the mean fields, the imitation learning problem reduces to that in the single-agent MDP. When the transition kernels of MDP depend on the mean fields, the upper bound of the suboptimality grows exponentially in horizon H. A new adversarial algorithm is proposed to mitigate such exponential dependency.\n\nSTRENGTHS:\nThis paper focuses on provably efficient imitation learning algorithms. The previous works do not provide any performance guarantee for imitation learning algorithms in MFG. In contrast, the authors derive the suboptimality bounds for BC and adversarial imitation learning algorithms. Particularly, when the transition kernels depend on the mean field, the authors propose a new adversarial algorithm to mitigate the exponential dependency on the horizon.\n\nWEAKNESSES:\n1. More justifications should be provided for the l_1 norm-based algorithm. The previous works for BC all focus on the log-likelihood type algorithms, and algorithms for GAIL focus on the Jensen-Shannon divergence-based algorithm. However, this paper adopts the l_1 error optimization framework, which is quite different from the empirical implementation. More discussions should be provided to justify this new framework. In addition, how to transfer the results in this paper to the analysis of the original algorithms should be discussed.\n\n2. As stated in the paper, when the transition kernels depend on the mean field, the exponential dependence on the horizon may not be tight. The empirical verification will be very helpful to demonstrate the true dependency on the horizon.\n\n3. For the proposed algorithm in Section 4.3, the reformulation of the algorithm below line 353 requires the value of $\\rho^{(\\pi)}$. However, it is not clear how to calculate this quantity from the paper. More clarification is required here.\n\n4. For the algorithm in Section 4.3, it is not clear why we can assume that min and max are exchangeable in the reformulation. What kind of condition is required should be explained.\n\nQUESTIONS:\nThe questions are provided in the previous section.\n\nLIMITATIONS:\nLimitation part is missing in the paper.", "TITLE": "Official Review", "RECOMMENDATION": 4, "REVIEWER_CONFIDENCE": 3, "SOUNDNESS_CORRECTNESS": 3, "DATE": "2023-07-06"}

{"IS_META_REVIEW": false, "comments": "SUMMARY:\nThe authors prove new upper bounds on the error in imitation learning for mean-field games. They then propose a new approach based on using mean-field control, which might provide a more reasonable imitation goal for imitation learning.\n\nSTRENGTHS:\nThe paper is clear in its description of connections and provides extensive mathematical arguments. The authors clearly show a gap in current literature and proceed with an ample analysis of how to fill it, which -- albeit very preliminary -- may lay substantial ground work for future research, as described in the paper's very own conclusion.\n\nWEAKNESSES:\nIn my opinion, the paper's biggest weakness is that it talks about practical applications only in the introduction and then never again. The whole paper would benefit from presenting concrete examples for the various settings that are discussed and including references, where these settings might occur \"in the wild\". Most notably the link to practice is lacking in l.s 235-239 and 321-324. Numerical analysis was suggested in the paper and is, in fact, presented in the appendix to some extent, but might have also deserved a little bit of space in the main paper. As it is, it is hard to see the practical applications of the proposed techniques.\n\nWhile related work is discussed very well, I do not see why it is pointed out as a separate contribution. Overall, the list of contributions could be stream-lined when strengthening the overall story (by referring to the beginning in the conclusion, e.g.).\n\nThe writing style is very good. Minor mistakes persist:\n- l. 87 \"policy, that\" --> \"policy that\"\n- l. 135: \\pi_E ---> \\pi^E\n- l. 319: \"kind\" ---> \"kinds\"\n- l. 379: \"works open\" --> \"work opens\"\n- throughout: comma after \"i.e.\" is set inconsistently.\n\nQUESTIONS:\nWhich further studies should be executed to solidify empirical evidence and why did you choose the setting you did in the appendix? Can a  small explanation be fit into the main text?\n\nLIMITATIONS:\nThe authors discuss the limitations of their work generally very well.", "TITLE": "Official Review", "RECOMMENDATION": 6, "REVIEWER_CONFIDENCE": 3, "SOUNDNESS_CORRECTNESS": 3, "DATE": "2023-07-06"}

{"IS_META_REVIEW": false, "comments": "SUMMARY:\nIn this work, the authors propose a newly defined measure called the Nash imitation gap for imitation learning in mean-field games (MFG). They establish upper bounds for the Nash imitation gap of behavioral cloning and adversarial imitation learning in both population independent and dependent dynamics in MFG. Additionally, they introduce the formulation of mean-field control (MFC) problem as a proxy to address population-dependent dynamics in imitation learning scenarios.\n\nSTRENGTHS:\n1.The authors of this paper demonstrate a high level of clarity in their definitions and statements, making the paper easily readable and accessible to the readers. This clarity enhances the understanding and comprehension of the presented concepts and results.\n\n2.One notable contribution of this paper is the introduction of an alternative optimization goal for imitation learning in mean-field games (MFG). By adopting this alternative goal, the paper avoids the need for approximating the MFG dynamics driven by the expert population. This alternative approach provides a novel perspective and potential solution for tackling the challenges associated with MFG-driven imitation learning.\n\nWEAKNESSES:\n1.While the authors provide a numerical illustration in the appendx, the lack of comprehensive experiments weakens the justification for using the Nash imitation gap as a measure for quantifying the quality of imitation. The absence of quantitative evaluations and comparisons with other approaches limits the ability to fully assess the effectiveness and practical significance of the proposed measure.\n\n2.Despite introducing a new perspective through the Nash imitation gap, this paper does not present any new algorithms or methods specifically designed for addressing this measure. This limitation reduces the overall significance and contribution of the work, as it does not offer novel practical solutions or techniques that directly leverage the Nash imitation gap.\n\n3.The lack of clear motivation for the use of the newly proposed performance measure undermines the justification and relevance of its inclusion. Providing a comprehensive rationale would strengthen the understanding and significance of the contributions.\n\nQUESTIONS:\nQuestions:\n\n1.In line 169, could you provide a more concrete justification for the use of the L1 distance as a measure?\n\n2.Line 238 mentions the need for the learned policy to be an equilibrium policy, but it's not clear why this is necessary. Could you elaborate on the significance and potential applications of requiring an equilibrium policy?\n\n3.Could you justify the need for defining the Nash imitation gap when exploitability is already defined? Are these measures equivalent, and is it possible to simplify by using just one of them?\n\n4.The distinction between the learner's population and expert's population in the paper reminds me of the difference between online imitation learning (e.g., DAgger) and offline imitation learning (e.g., behavior cloning). Are these pairs of concepts related, and if so, how do they connect to the ideas presented in the paper?\n\nLIMITATIONS:\n1.The lack of a clear motivation for the inclusion of the newly proposed performance measure undermines its justification and relevance. \n\n2.The limited scope of experiments and the absence of quantitative evaluations and comparisons with other approaches weaken the justification for using the Nash imitation gap as a measure for quantifying the quality of imitation. \n\n3.The ambiguous goal of mean-field games (MFG) and the using the Nash imitation gap as a performance measure may limit its applicability in real-world applications.", "TITLE": "Official Review", "RECOMMENDATION": 5, "REVIEWER_CONFIDENCE": 3, "SOUNDNESS_CORRECTNESS": 2, "DATE": "2023-07-07"}