Skip to content

Instantly share code, notes, and snippets.

View Shmuma's full-sized avatar

Max Lapan Shmuma

View GitHub Profile

Keybase proof

I hereby claim:

  • I am shmuma on github.
  • I am shmuma (https://keybase.io/shmuma) on keybase.
  • I have a public key ASB-Udjo8uXeywt8Q8Ur3dPLK5cKWdwA8-Nog8tOPGNp8go

To claim this, I am signing this object:

@Shmuma
Shmuma / gist:97c7482cab4b0105c96de3ccd383c87f
Created October 2, 2017 08:40
PyTorch byte Variable overflow
>>> import torch
>>> from torch.autograd import Variable
>>> t = torch.ByteTensor([240, 240])
>>> t.sum()
480
>>> v = Variable(t)
>>> v
Variable containing:
240
240
#!/usr/bin/env python3
# test memory leak on long RNN sequences
from tqdm import tqdm
import random
import numpy as np
import itertools
import torch
import torch.optim as optim
import torch.nn as nn
https://github.com/Shmuma/rl/blob/ptan/ptan/samples/reinforce.py
DQN with experience replay
Code: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/dqn_expreplay_doom.py
Config: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/runs/dqn_exp_doom_predict.ini
DQN with experience replay
Code: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/dqn_expreplay_doom.py
Config: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/runs/dqn_exp_doom_defend_line.ini
DQN with experience replay
Code: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/dqn_expreplay_doom.py
Config: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/runs/dqn_exp_doom_defend_center.ini
DQN with experience replay
Code: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/dqn_expreplay_doom.py
Config: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/runs/dqn_exp_doom_health.ini
DQN with experience replay
Code: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/dqn_expreplay_doom.py
Config: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/runs/dqn_exp_doom_basic.ini
DQN with experience replay.
Code: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/dqn_expreplay_doom.py
Config: https://github.com/Shmuma/rl/blob/ptan/ptan/samples/runs/dqn_exp_doom_corridor.ini