2

I'm trying to investigate high RAM use during the use of my Python application. The image below shows the high memory usage. Is there an option when using PyCharm to view memory usage? I have 16GB of system memory.

High Memory Image

Makoto
  • 104,088
  • 27
  • 192
  • 230
James Gray
  • 97
  • 2
  • 13
  • Twitter dashboard? Are you constantly storing tweets into a list? – OneCricketeer Mar 12 '16 at 22:52
  • I think that this is more a duplicate simply because to my mind PyCharm doesn't come with these tools, but cProfile and Profile have existed for aeons and are generally simple to work with. – Makoto Mar 12 '16 at 22:53
  • Yes - I am storing Twitter Posts into a list. PyCharm doesn't come with memory monitoring tools like Netbeans? – James Gray Mar 12 '16 at 22:56
  • It *might*, but in all actuality it'd be exposing cProfile or Profile *anyway*... – Makoto Mar 12 '16 at 22:57
  • You should dump the list of tweets occasionally (either empty the list, keep a max, or write to disk) to prevent a out of memory error. – OneCricketeer Mar 12 '16 at 23:00
  • cricket_007 this is the problem that I'm trying to solve by monitoring the memory usage. I get a 'Memory Error' after running the application for about an hour. Are you able to explain in a bit more detail how I can prevent this? – James Gray Mar 12 '16 at 23:03
  • Thanks Makoto for pointing me to cProfile. This is not a tool that I've seen before and it will be useful. – James Gray Mar 12 '16 at 23:04
  • I am not sure about your goal, but I think in general loading all tweets into RAM is not a good idea. Batching may be useful if applicable. – Patrick the Cat Mar 12 '16 at 23:41

0 Answers0