Skip to main content

gym-display-advertising

An OpenAI Gym for Display Advertisment Reinforcement Learning

Installation

pip install gym-display-advertising

Usage

import gym_display_advertising

env = gym.make("StaticDisplayAdvertising-v0")
episode_over = False
while not episode_over:
    state, reward, episode_over, _ = env.step(env.action_space.sample())
    print(state, reward)
import gym_display_advertising

env = gym.make("DisplayAdvertising-v0")
episode_over = False
while not episode_over:
    state, reward, episode_over, _ = env.step(env.action_space.sample())
    print(state, reward)

Real Ad Bidding Data

The repository contains real-life bidding data from a single merchant and loads this by default. If you want to load more data follow the instructions in the make-ipinyou-data repository to create the data.

Then use the helper class ProcessedIPinYouData to load the data and pass the dataframe into the gym.make command.

import pathlib
import gym
import gym_display_advertising

ipinyou = gym_display_advertising.data.ProcessedIPinYouData(directory=pathlib.Path("path/to/file"))
training_data, _ = ipinyou.get_merchant_data(2997)
env = gym.make("DisplayAdvertising-v0", data=training_data)
state, reward, _, _ = env.step(env.action_space.sample())
print(state, reward)

Acknowledgements

This is a project by Winder Research, a Cloud-Native Data Science consultancy.

Metadata

Release files for gym-display-advertising 0.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for gym-display-advertising 0.0.1
File Size Uploaded Provenance Actions
gym_display_advertising-0.0.1.tar.gz 78.7 kB Without provenance Details for gym_display_advertising-0.0.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for gym-display-advertising 0.0.1
File Interpreter ABI Platform Actions
gym_display_advertising-0.0.1-py3-none-any.whl Python 3 none any Details for gym_display_advertising-0.0.1-py3-none-any.whl

Total release size: 87.0 kB

Release files / gym_display_advertising-0.0.1.tar.gz

Download URL gym_display_advertising-0.0.1.tar.gz
Size 78.7 kB
Tags Source
SHA-256 checksum
How to use checksums
2210d234c80ae914442a14d092cb2b4fdc7009b9236be68a5929781747460fcc
BLAKE2b-256 checksum
How to use checksums
42c3bf5f31aae4eea0e38b8ae2c6b0128c3f00306f88145f7e4c8c20d7e33fd2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.4

Release files / gym_display_advertising-0.0.1-py3-none-any.whl

Download URL gym_display_advertising-0.0.1-py3-none-any.whl
Size 8.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
dd703412daf918d5f7d2f637b9a5f666f96fdbb2e9a346f086eff2d55139682d
BLAKE2b-256 checksum
How to use checksums
039b921afb089808b6486686c922a9d578980dd2b691cd010cca89791560b080
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.4

Security for gym-display-advertising 0.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.0.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page