Skip to content

Instantly share code, notes, and snippets.

View ThyrixYang's full-sized avatar
🐟

Thyrix ThyrixYang

🐟
View GitHub Profile
@ThyrixYang
ThyrixYang / cloudSettings
Last active July 1, 2020 16:36
vscode_setting.json
{"lastUpload":"2020-07-01T16:36:25.427Z","extensionVersion":"v3.4.3"}
import getpass
import io
import os
import requests
import retro.data
import subprocess
import sys
import tarfile
import tempfile
import zipfile
@ThyrixYang
ThyrixYang / ddpg_Pendulum.py
Created August 31, 2017 17:45
ddpg_Pendulum
'''
author: Thyrix Yang
github: https://github.com/ThyrixYang
'''
# Deep DPG (DDPG)
# I didn't do much experiment on the model and hyper-parameters,
# and this is a implementation without some tricks mentioned in the paper.
# The result on this env is well, but worse than my CEM implementation...
import numpy as np
import gym
from gym import wrappers
import tensorflow as tf
import json, sys, os
from os import path
import random
from collections import deque
#####################################################################################################
@ThyrixYang
ThyrixYang / CEM_Pendulum.py
Last active October 31, 2019 23:20
CEM-Pendulum-v0
'''
author: Thyrix Yang
github: https://github.com/ThyrixYang
'''
import numpy as np
import gym
# Cross Entropy Method
@ThyrixYang
ThyrixYang / CEM_CartPole.py
Created August 27, 2017 13:27
CartPole-v1 with CEM
'''
author: Thyrix Yang
github: https://github.com/ThyrixYang
'''
import numpy as np
import gym
# Cross Entropy Method
@ThyrixYang
ThyrixYang / CEM_CartPole.py
Last active August 26, 2017 18:56
CEM algorithm on CartPole-v0
'''
author: Thyrix Yang
github: https://github.com/ThyrixYang
'''
import numpy as np
import gym
-- The C compiler identification is GNU 5.4.0
-- The CXX compiler identification is GNU 5.4.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
@ThyrixYang
ThyrixYang / test result
Created March 17, 2017 11:41
test result on random sampling
original test
average fail count on each model
at round 200
------------------------
0 0 0.0000000000
0 1 0.0000000000
0 2 0.0000000000
1 0 1.8900000000
1 1 0.0000000000
1 2 0.0000000000
The test result on mlpack_krann
I have tried four different threshold(5, 12, 20, 28), with the RAModelTest
Each test is run 200 times,
round 200 fail 200 (run 200 times, the test failed 200 times)
------------------------
model id, j, failure count
0 0 0
0 1 0