bnelearn.mechanism.auctions_combinatorial module¶
Auction mechanism for combinatorial auctions (where bidders are interested in bundles of items).
- class bnelearn.mechanism.auctions_combinatorial.CombinatorialAuction(rule='first_price', cuda: bool = True, bundles=None, parallel: int = 1)[source]¶
Bases:
Mechanism
A combinatorial auction, implemented via (possibly parallel) calls to the gurobi solver.
- Args:
rule: pricing rule
- run(bids: Tensor) Tuple[Tensor, Tensor] [source]¶
Performs a general Combinatorial auction
- Args:
- bids: torch.Tensor
of bids with dimensions (batch_size, n_players, 2) [0,Inf]
- bundles: torch.Tensor
of bundles with dimensions (batch_size, 2, n_items), {0,1}
- Returns:
allocation: torch.Tensor, dim (batch_size, n_bidders, 2) payments: torch.Tensor, dim (batch_size, n_bidders)
- class bnelearn.mechanism.auctions_combinatorial.LLGAuction(rule='first_price', cuda: bool = True)[source]¶
Bases:
Mechanism
Implements simple auctions in the LLG setting with 3 bidders and 2 goods. Notably, this is not an implementation of a general Combinatorial auction and bidders do not submit full bundle (XOR) bids: Rather, it’s assumed a priori that each bidder bids on a specific bundle: The first bidder will only bid on the bundle {1}, the second on {2}, the third on {1,2}, thus actions are scalar for each bidder.
For the LLG Domain see e.g. Ausubel & Milgrom 2006 or Bosshard et al 2017
- run(bids: Tensor) Tuple[Tensor, Tensor] [source]¶
Runs a (batch of) LLG Combinatorial auction(s).
We assume n_players == 3 with 0,1 being local bidders and 3 being the global bidder.
Parameters¶
- bids: torch.Tensor
of bids with dimensions (batch_size, n_players, 1)
Returns¶
- (allocation, payments): Tuple[torch.Tensor, torch.Tensor]
- allocation: tensor of dimension (n_batches x n_players x 1),
1 indicating the desired bundle is allocated to corresponding player in that batch, 0 otherwise. (i.e. 1 for player0 means {1} allocated, for player2 means {2} allocated, for player3 means {1,2} allocated.)
- payments: tensor of dimension (n_batches x n_players)
Total payment from player to auctioneer for her allocation in that batch.
- class bnelearn.mechanism.auctions_combinatorial.LLGFullAuction(rule='first_price', cuda: bool = True)[source]¶
Bases:
Mechanism
Implements auctions in the LLG setting with 3 bidders and 2 goods.
Here, bidders do submit full bundle (XOR) bids. For this specific LLG domain see (Beck and Ott 2013).
Item dim 0 corresponds to item A, dim 1 to item B and dim 2 to the bundle of both.
- class bnelearn.mechanism.auctions_combinatorial.LLLLGGAuction(rule='first_price', core_solver='NoCore', parallel: int = 1, cuda: bool = True)[source]¶
Bases:
Mechanism
Inspired by implementation of Seuken Paper (Bosshard et al. (2019), https://arxiv.org/abs/1812.01955). Hard coded possible solutions for faster batch computations.
- Args:
rule: pricing rule core_solver: which solver to use, only relevant if pricing rule is a core rule parallel: number of processors for parallelization in gurobi (only)
- class bnelearn.mechanism.auctions_combinatorial.LLLLRRGAuction(rule='first_price', core_solver='NoCore', parallel: int = 1, cuda: bool = True)[source]¶
Bases:
LLLLGGAuction
Extended LLLLGG Auction with an additional ‘superglobal’ bider. Implementation is identical to LLLLGG except we overwrite some settings in the constructor.