Cleaned RNN code and added testing code