# RNN support + RAM usage for RL algorithms

**URL:** <https://discuss.ray.io/t/rnn-support-ram-usage-for-rl-algorithms/8983>\
**Category:** RLlib\
**Created:** [January 16, 2023, 3:52pm UTC](https://discuss.ray.io/t/rnn-support-ram-usage-for-rl-algorithms/8983 "2023-01-16T15:52:47Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![qtomcat](https://avatars.discourse-cdn.com/v4/letter/q/7ba0ec/32.png) [@qtomcat](https://discuss.ray.io/u/qtomcat)\
**Post date:** [January 16, 2023, 3:52pm UTC](https://discuss.ray.io/t/rnn-support-ram-usage-for-rl-algorithms/8983/1 "2023-01-16T15:52:48Z")

</div>

Dear developers,

I am AI researcher and very new to Ray, and it looks to me as a very diverse and powerful ML package. I’m looking for a working example of RL algorithm with support of RNN. Let’s say PPO+LSTM that solves Cart Pole, or anything like that. Will appreciate your help a lot.

And also, please, explain why Ray instances take so much RAM on my PC (Windows 11, Anaconda, no CUDA). Is it possible to reduce the memory usage in Ray instances?

---

<div class="post-metadata">

**Author:** ![mannyv](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ray.io/mannyv/32/606_2.png) [@mannyv](https://discuss.ray.io/u/mannyv)\
**Post date:** [January 17, 2023, 1:32am UTC](https://discuss.ray.io/t/rnn-support-ram-usage-for-rl-algorithms/8983/2 "2023-01-17T01:32:25Z")

</div>

Hi @qtomcat,

Here is an example with PPO / IMPALA in a stateless version of the cartpole environment using an LSTM.

> <https://github.com/ray-project/ray/blob/master/rllib/examples/cartpole_lstm.py>

---

<div class="post-metadata">

**Author:** ![qtomcat](https://avatars.discourse-cdn.com/v4/letter/q/7ba0ec/32.png) [@qtomcat](https://discuss.ray.io/u/qtomcat)\
**Post date:** [January 17, 2023, 2:20pm UTC](https://discuss.ray.io/t/rnn-support-ram-usage-for-rl-algorithms/8983/3 "2023-01-17T14:20:50Z")

</div>

many thanks, I will try it
