An OpenAI Gym for Shopping Cart Reinforcement Learning
pip install gym-shopping-cart==0.0.0
An OpenAI Gym for Shopping Cart Reinforcement Learning.
This is a project by Winder Research, a Cloud-Native Data Science consultancy.
pip install gym-shopping-cart
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))
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.
Gitlab icon made by Freepik from www.flaticon.com.