kentsommer / pytorch-value-iteration-networks

Pytorch implementation of Value Iteration Networks (NIPS 2016 best paper)
BSD 3-Clause "New" or "Revised" License
318 stars 62 forks source link

testing accuracy fairly low #3

Closed xinleipan closed 6 years ago

xinleipan commented 6 years ago

I just tried to follow the instructions in the repo, and tested models trained but got a fairly low accuracy. I'm using pyTorch 0.1.12_1. Is there anything I should pay attention to?

xinleipan commented 6 years ago

I found the downloaded model does not work but my trained model works right now

kentsommer commented 6 years ago

@xinleipan

I'm glad to hear you got it working. This week is busy for me but I'll take a look next week and see if there is an issue with the pretrained models. Perhaps there has been a change in PyTorch that is causing performance issues but not errors.

Thank you for bringing this to my attention! :+1:

xinleipan commented 6 years ago

Thanks. Do you have a plan to implement DQN or A3C with VIN?

kentsommer commented 6 years ago

@xinleipan

Do you mean using VIN as a global planner and training some agent (DL / RL policy) using DQN/A3C/ACKTR to be the local planner?

I guess I'm not sure I understand your question?

xinleipan commented 6 years ago

Yes, so VIN can be considered as a value function which takes in the state and outputs values for each action. So it can be used in DQN to train a policy that can generalize to different maps in grid world environment?

kentsommer commented 6 years ago

That is actually the direction of my current research! However, that probably won't ever be merged into this repository.

I just noticed you authored the "Virtual to Real Reinforcement Learning for Autonomous Driving" paper, you presented some really great ideas! Happy to "meet" you :+1:

xinleipan commented 6 years ago

Nice to meet you too! Hope you will soon figure out how RL works with VIN

kentsommer commented 6 years ago

Check out this paper for integrating VIN as a global planner: https://arxiv.org/abs/1702.03920, I think you might find that interesting (if you haven't already seen it).

aseembits93 commented 6 years ago

I found an error in how the error is calculated while testing in Line no 80 (train.py) correct += (predicted == labels).sum() should instead be correct += (torch.eq(torch.squeeze(predicted), labels)).sum()

kentsommer commented 6 years ago

@aseembits93

Thanks for this report, with the changes in the latest version of PyTorch this indeed introduced a bug. I'll be fixing this along with the bug reported in #4 this weekend.