Skip to content

Instantly share code, notes, and snippets.

View zeyademam's full-sized avatar

Zeyad Emam zeyademam

View GitHub Profile
@shonkaga
shonkaga / docker.md
Last active February 24, 2022 15:54
Introduction to Docker

An Introduction To Docker

Written by Shon Kaganovich shon.kaganovich@gmail.com

What Is Docker?

A docker is a tool that allows developers to easily deploy apps without having to custom download all their dependencies for said project. It uses a sandbox (also called a container) that contains all the dependencies and compilers needed, but unlike virtual machines contains do not have high overhead and thus are efficient.

# Inspired by https://medium.com/@tuzzer/cart-pole-balancing-with-q-learning-b54c6068d947
import gym
import numpy as np
import math
from collections import deque
class QCartPoleSolver():
def __init__(self, buckets=(1, 1, 6, 12,), n_episodes=1000, n_win_ticks=195, min_alpha=0.1, min_epsilon=0.1, gamma=1.0, ada_divisor=25, max_env_steps=None, quiet=False, monitor=False):
self.buckets = buckets # down-scaling feature space to discrete range