• Stars
    star
    118
  • Rank 290,532 (Top 6 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created about 5 years ago
  • Updated over 4 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Can a neural network predict your next move on a game of rock, paper and scissor?

JoKenPo

Can a Neural Network predict your next move on a game of rock, paper, scissors?

Me playing it with the same pattern

Play it here

Alternative link here

About

An experiment involving a game of rock, paper and scissor, also known as Jo Ken Po. During the first 3 rounds the computer chooses a move (rock, paper or scissor) at random. After that, it assumes it has enough data about the player to predict it's pattern. The data set consists of the player last two moves, being the last one, the one they'll do after the first one. Kind of confusing, right?! Simple put, the computer stores the first move as a input x and the move after that as a label or target y, meaning that after the player choosing rock, for instance, there's a possibility they'll choose paper as the next move. If the computer predicts the player will play rock, it plays paper, so on and so forth. Every time the computer loses, it trains the neural network again.

Know problems

This is just an experiment, don't be upset if the computer (my neural network) won't do a good job of playing against you. Also, I'm never deleting from the data set, meaning that eventually the time to train the neural network will be larger and larger.

More Repositories

1

isocity

A isometric city builder in JavaScript
JavaScript
2,812
star
2

invaderz

Space invaders, but the invaders evolve with genetic algorithm
JavaScript
705
star
3

radialMenu

A highly customizable radial menu that's very easy to setup.
JavaScript
382
star
4

imgToAscii

A JavaScript implementation of a image to Ascii code
JavaScript
376
star
5

aimAndShoot

A neuroevolution game experiment.
JavaScript
220
star
6

groupImg

A script in python to organize your images by similarity.
Python
211
star
7

hntitlenator

Test your HN title against a neural network
JavaScript
183
star
8

fos

Web Components to turn your web app into a fake operating system
JavaScript
175
star
9

dial

A Rotary Dial menu for input numbers
JavaScript
161
star
10

oldTerminal

an old terminal template for html pages
CSS
156
star
11

retroSynthwave

A retro synthwave "demo scene"
JavaScript
134
star
12

fingerPool

A pool game in JavaScript using my sphereCollision project
JavaScript
106
star
13

tileEditor

A 2D Tile Editor that runs on the browser.
JavaScript
103
star
14

budget

A simply budget app that predicts where the expenses are being made
JavaScript
103
star
15

ocr

Simple app to extract text from pictures using Tesseract
HTML
103
star
16

bangBang

Play BangBang against a Neural Network
JavaScript
99
star
17

photoEditor

A image editor in browser using JavaScript canvas
JavaScript
94
star
18

radio

A simple javascript web radio visualizer
JavaScript
92
star
19

randomFractal

Random fractal or the secret behind my tree
JavaScript
91
star
20

rpiapi

An API for your Raspberry Pi
Python
85
star
21

bruteforcetv

Let's brute force this hotel's tv.
73
star
22

perceptronCobol

A perceptron written in COBOL
COBOL
69
star
23

simpleWFC

A simplified version of the Wave Function Collapse algorithm
JavaScript
56
star
24

bangBangML

Watch a Neural Network learns to shoot a target
JavaScript
56
star
25

googol

Googol Game or "You should learn when to quit". A JavaScript game.
JavaScript
47
star
26

perceptron

The simplest Perceptron you'll ever see
JavaScript
45
star
27

myConsole

A JavaScript editor for your phone, in JavaScript
JavaScript
41
star
28

carGamePerceptron

A Neural Network experiment involving a JavaScript game.
JavaScript
31
star
29

3Dengine

A JavaScript WebGL 3D engine. From scratch.
JavaScript
28
star
30

deforestation

A machine learning exercise, using KNN to classify deforested areas
Python
27
star
31

scrap

Scrapping Facebook with JavaScript.
JavaScript
27
star
32

pixelRestorer

Using statistics to restore pixel art images.
HTML
26
star
33

paintDraw

A JavaScript paint and draw app.
JavaScript
24
star
34

digitRecognition

Implementation of a digit recognition using my Neural Network with the MNIST data set.
JavaScript
21
star
35

terrainGenerator

A 3D terrain generator from a height maps using Three.js
JavaScript
18
star
36

MLP

A multilayer perceptron in JavaScript
JavaScript
17
star
37

raspberryCar

A flask server to control a raspberry pi over the internet.
Python
15
star
38

genius

Genius game implemented using JavaScript and RadialMenu
JavaScript
14
star
39

rippleEffect

A JavaScript ripple effect implemented using canvas
JavaScript
14
star
40

faceRecognition

A face recognition in JavaScript using my neural network
JavaScript
13
star
41

towerDefense

A tower defense game written in vanilla JavaScript
JavaScript
13
star
42

gaia

An AI concept that can help the game designer create procedural quests.
JavaScript
11
star
43

create

A simple bash script to create progressive web apps (pwa).
Shell
11
star
44

imageCounter

A simple page view counter that store data as text and shows data as a PNG image
PHP
10
star
45

memes

A progressive web app with memes, videos and gifs, from reddit.
JavaScript
10
star
46

FOStutorial

A git repository to go along with a tutorial for using FOS to build a web app
HTML
9
star
47

pathfind

Using Breadth-First Search as a pathfinder algorithm, visualizing the final path.
JavaScript
9
star
48

audio2text

Converting audio files to text using Google Chrome's speech API.
JavaScript
9
star
49

monteCarlo

Finding Areas Using the Monte Carlo Method
JavaScript
8
star
50

plot

Plot equations using JavaScript canvas
HTML
8
star
51

splitDjangoModels

Split Django generated models into separated files, with proper names, classes and imports
Python
8
star
52

remember

Remember is a simple bash script that allow you to write "to do" lists and things you want to remember.
Shell
7
star
53

myRaycast

A JavaScript Ray Casting engine I'm working on
JavaScript
7
star
54

bridge

A JavaScript implementation of the bridge game.
JavaScript
7
star
55

sphereCollision

Javascript experiment with 2D physics
JavaScript
7
star
56

terms

Get related terms to a word.
JavaScript
6
star
57

syntax

A very simple JavaScript syntax highlighter
HTML
6
star
58

naiveCorners

A naive algorithm to identify corners on a image
Python
6
star
59

customFilter

A image editor that runs in the browser
JavaScript
4
star
60

keypad2text

Convert text to keypad code and vice versa.
JavaScript
4
star
61

fireEffect

A fire effect algorithm implemented using JavaScript canvas
JavaScript
4
star
62

rpg2djavascriptgame

"Engine" for a 2D JavaScript rpg game
JavaScript
3
star
63

mycanvas

A JavaScript Canvas application
HTML
3
star
64

scramble

A puzzle game in JavaScript
JavaScript
3
star
65

dtf

DTF - Duplicate Thumbnail Files - A method to identify duplicate files.
Python
3
star
66

goSpellcheck

A terrible spell checker in Go.
Go
2
star
67

montyhall

Monty Hall problem. An old code I wrote a long time ago.
HTML
2
star
68

AOSE

A simulation involving a criminal, a civilian, a police officer and a firefighter. My final project for the AOSE class.
JavaScript
2
star
69

BatalhaNaval

Jogo Java Batalha Naval
Java
2
star
70

BeautyHair

BeautyHair is a multiplatform CLI software written in Java to manage beauty saloons.
Java
1
star
71

compactImage

Trying to beat the PNG file format (Just for fun)
JavaScript
1
star
72

carGame

A simple JavaScript game
JavaScript
1
star
73

simpleCounter

A simple counter in vanilla JavaScript
JavaScript
1
star
74

victorqribeiro

1
star