An OpenAI Gym for Shopping Cart Reinforcement Learning
Project description
gym-display-advertising
An OpenAI Gym for Shopping Cart Reinforcement Learning.
This is a project by Winder Research, a Cloud-Native Data Science consultancy.
Installation
pip install gym-shopping-cart
Usage
This example will use the small example data included in the repo.
import gym
import gym_shopping_cart
env = gym.make("ShoppingCart-v0")
episode_over = False
rewards = 0
while not episode_over:
state, reward, episode_over, _ = env.step(env.action_space.sample())
print(state, reward)
rewards += reward
print("Total reward: {}".format(rewards))
Real Shopping Cart Data
This environment uses real shopping cart information from the Instacart dataset.
To help read this data the library also comes with a data parser. This loads the raw data and cleans the data to be in a format expected by the environment.
Credits
Gitlab icon made by Freepik from www.flaticon.com.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file gym_shopping_cart-0.2.0.tar.gz
.
File metadata
- Download URL: gym_shopping_cart-0.2.0.tar.gz
- Upload date:
- Size: 24.1 kB
- Tags: Source
- Uploaded using 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.41.0 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6fbdc151d74534d32264595419c597da0b0564e63795f4e6a79f1c03b1f9380f |
|
MD5 | f89ac64905029dfe09c2b5b48373db42 |
|
BLAKE2b-256 | 1115a6c09d670f622804bc91ac39c663db4f08a8ba4030446048249a1b8b331f |
File details
Details for the file gym_shopping_cart-0.2.0-py3-none-any.whl
.
File metadata
- Download URL: gym_shopping_cart-0.2.0-py3-none-any.whl
- Upload date:
- Size: 25.9 kB
- Tags: Python 3
- Uploaded using 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.41.0 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | aaeb07eeb96802211baf25dbdacd5613776311cfbe92ecd031033d2146fae8bd |
|
MD5 | 670f0cb5a0bd56e05a2aa3ff3048c97f |
|
BLAKE2b-256 | 5aa667b4a815a07a0e9cabf7bfd2ddc9f8dcc23f1e48f24f1c2e11eda8225bec |