👾 Jupyter Notebook + Space Invaders!?

Overview


TrainInvaders
Train Invaders

Jupyter Notebook + Space Invaders!?

Python version Python version License

Why?Getting startedHow it worksFAQDrawbacksContributeThanks toYou may also like...

Demo

Why

Training a model can be a long long process!

In the meantime, have a bit of fun with a competitive space invaders game.

See if you can get your name to the top of the leaderboard.

Getting started 🏁

  1. Install the game: !pip3 install train_invaders --upgrade
  2. Import the game in your notebook: import train_invaders.start
  3. Start training your model. The game will automatically pop up when the process begins.
  4. Play the game! You'll get notified when your training is finished.
  5. Want to stop the game from popping up when the model is being trained? import train_invaders.stop will do the work.

How it works ⚙️

Tons of magic... Just kidding :)

When importing the start module, its code will be executed.

The code utilizes python's settrace function which follows the functions' call stack.

When a function named fit train or train_on_batch is called - using Jupyter notebook's kernel, aka, IPython, a javascript view code will be injected inside the output block as an iframe to keep it completely isolated from your code.

When importing the stop module, the settrace function will be canceled and the function hooks will be removed.

FAQ 🙋

Will it interfere with the training process somehow?

NO. The game will start and be played in parallel to the training and will even let you know when the training is finished.

Drawbacks 🥺

  • Training stop indication is only in Jupyter Notebook. Want to get notified by email or text? Try MLNotify
  • Authentication, and therefore, saving your score can only be done from localhost and port 8888 - 8891 / 8080 / 8081

Contribute 🤝

Have an awesome idea for a new feature? PRs are more than welcome!

  1. Clone the project
  2. Run make build-game to get a local and compiled copy of the game (if not exists)
  3. Enter src/view directory and run npm run serve to run the local environment
  4. Implement your ideas
  5. Made changes in the game (C files)? Re-run make build-game from root dir and check them out
  6. Enter root directory, run make build, pip install . --upgrade and test the changes in your notebook
  7. PR us!

Thanks to 🙏

JanSiebert for the WebAssembly game.

Cody Boisclair for the PressStart2P font.

Vue for the awesome FE framework.

You may also ❤️

Aporia - Customized monitoring for your ML models.

MLNotify - Get notified when training is complete.

MLOps Toys - A curated list of useful MLOps tools.

You might also like...
Exploring the Design Space of Page Management for Multi-Tiered Memory Systems (USENIX ATC'21)

AutoTiering This repo contains the kernel code in the following paper: Exploring the Design Space of Page Management for Multi-Tiered Memory Systems (

Lib 2d - A c++ library for paths defined by points within the 2d space

#lib_2d A c++ library for anything related to points within the 2d space (using floating point data types) using Catch as testing framework https://gi

A collection of user-space Linux kernel specific guided fuzzers based on LKL

kBdysch kBdysch is a collection of fast Linux kernel specific fuzzing harnesses supposed to be run in userspace in a guided fuzzing manner. It was des

Project Etnaviv is an open source user-space driver for the Vivante GCxxx series of embedded GPUs.

Introduction Project Etnaviv is an open source user-space driver for the Vivante GCxxx series of embedded GPUs. This repository contains reverse-engin

HESS (Hyper Exponential Space Sorting) is a polynomial black-box optimization algorithm, that work very well with any NP-Complete, or NP-Hard problem

The original HESS (Hyper Exponential Space Sorting) is a polynomial black-box optimization algorithm, that work very well with any NP-Complete, or NP-Hard problem, at 2021 thanks to suggestions of Daniel Mattes, work like a complete algorithm.

A Navigator 2.0 based Flutter widget that automatically splits the screen into two views based on available space
A Navigator 2.0 based Flutter widget that automatically splits the screen into two views based on available space

A Navigator 2.0 based Flutter widget that automatically splits the screen into two views based on available space

imGuIZMO.quat is a ImGui widget: like a trackball it provides a way to rotate models, lights, or objects with mouse, and graphically visualize their position in space, also around any single axis (Shift/Ctrl/Alt/Super)
imGuIZMO.quat is a ImGui widget: like a trackball it provides a way to rotate models, lights, or objects with mouse, and graphically visualize their position in space, also around any single axis (Shift/Ctrl/Alt/Super)

imGuIZMO.quat v3.0 imGuIZMO.quat is a ImGui widget: like a trackball it provides a way to rotate models, lights, or objects with mouse, and graphicall

Separable Subsurface Scattering is a technique that allows to efficiently perform subsurface scattering calculations in screen space in just two passes.

Separable Subsurface Scattering Separable Subsurface Scattering is a technique that allows to efficiently perform subsurface scattering calculations i

Cloud Native Data Plane (CNDP) is a collection of user space libraries to accelerate packet processing for cloud applications.

CNDP - Cloud Native Data Plane Overview Cloud Native Data Plane (CNDP) is a collection of userspace libraries for accelerating packet processing for c

Releases(v1.0.4)
Owner
Aporia
The Monitoring Platform for Machine Learning
Aporia
xeus-wren is a Jupyter kernel for wren based on the native implementation of the Jupyter protocol xeus.

xeus-wren is a Jupyter kernel for wren based on the native implementation of the Jupyter protocol xeus. Installation xeus-wren has not been packaged f

Thorsten Beier 4 Mar 9, 2022
Space invaders clone in C++

memeinvaders Space invaders clone in C++ To build: Install SDL2 (and possibly OpenGL): https://wiki.libsdl.org/Installation Install CMake: https://cma

null 2 Jan 8, 2022
This is a C port of Stefan Hirschmann's NoteBook FanControl.

It provides the same utilities with the same interfaces as the original NBFC, although the implementation differs.

null 161 Jan 2, 2023
A framework for implementing block device drivers in user space

BDUS is a Linux 4.0+ framework for developing block devices in user space. More specifically, it enables you to implement block device drivers as regu

Alberto Faria 26 Dec 13, 2022
our supper awesome kernel and user space system

osakauss our super awesome kernel and user space system memory layout The kernel is loaded at 0x00100000. kmalloc initially uses 'placement' allocatio

Eduard 8 Aug 26, 2021
ORBION the OpenSource Space Mouse 3D

Orbion The OpenSource Space Mouse To ensure greater precision and fluidity it is recommended to put a foam ring under the knob (see photo above) and d

FaqTotum 314 Jan 7, 2023
OSA a is minisatellite/ space probe the size of a can designed to participate in the ESA CanSat 2021 competition 🛰️ 📡 .

Project OSA OSA a is minisatellite/ space probe the size of a can designed to participate in the ESA CanSat 2021 competition ??️ ?? . Our project is c

OSATeam 11 Sep 30, 2022
User space configuration tool for RME HDSPe MADI / AES / RayDAT / AIO and AIO Pro cards driven by the snd-hdspe driver.

hdspeconf User space configuration tool for RME HDSPe MADI / AES / RayDAT / AIO and AIO Pro cards, driven by the snd-hdspe driver. Building hdspeconf

Philippe Bekaert 10 Nov 29, 2022
CPU implementation of Seidel aberrations for screen-space DOF by Niels Asberg.

PrimeFocusCPU CPU implementation of Seidel aberrations for screen-space DOF by Niels Asberg. MIT License Copyright (c) 2021 Niels Asberg Permission is

Zeno Pelgrims 3 Nov 24, 2021