Grant Tang <[EMAIL PROTECTED]> added the comment:
Facundo:
I understand now. You mean every unique float number used will be an object
in memory. And never been released until Python quit. Is there any way to
reclaim these memory? We need 3G memory to create a list of 100million
randum numbers.
Thank you very much,
Grant
On Sun, Jun 8, 2008 at 11:59 AM, Facundo Batista <[EMAIL PROTECTED]>
wrote:
>
> Facundo Batista <[EMAIL PROTECTED]> added the comment:
>
> So, 0.0 would be cached, and the 414m+384m would be from the list
> itself, right? I tried,
>
> >>> data = [(1.0/i) for i in xrange(1,100000000)]
>
> And the memory consumption was the big one.
>
> Grant, the 800 MB is taken by ONE 0.0, and a list of zillion positions.
>
> Furthermore, I did:
>
> >>> for x in xrange(100000000):
> ... i = random()
>
> And the memory didn't increase.
>
> Grant, take note that there's no gc issue, the numbers stay alive
> because the list itself is pointing to them.
>
> Closing this as invalid.
>
> ----------
> resolution: -> invalid
> status: open -> closed
>
> _______________________________________
> Python tracker <[EMAIL PROTECTED]>
> <http://bugs.python.org/issue3063>
> _______________________________________
>
Added file: http://bugs.python.org/file10552/unnamed
_______________________________________
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue3063>
_______________________________________
<div>Facundo:</div>
<div> </div>
<div>I understand now. You mean every unique float number used will be an
object in memory. And never been released until Python quit. Is there any way
to reclaim these memory? We need 3G memory to create a list of 100million
randum numbers.</div>
<div> </div>
<div>Thank you very much,</div>
<div>Grant<br><br></div>
<div class="gmail_quote">On Sun, Jun 8, 2008 at 11:59 AM, Facundo Batista
<<a href="mailto:[EMAIL PROTECTED]">[EMAIL PROTECTED]</a>> wrote:<br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px
0.8ex; BORDER-LEFT: #ccc 1px solid">
<div class="Ih2E3d"><br>Facundo Batista <<a href="mailto:[EMAIL
PROTECTED]">[EMAIL PROTECTED]</a>> added the comment:<br><br></div>So, 0.0
would be cached, and the 414m+384m would be from the list<br>
itself, right? I tried,<br><br>>>> data = [(1.0/i) for i in
xrange(1,100000000)]<br><br>And the memory consumption was the big
one.<br><br>Grant, the 800 MB is taken by ONE 0.0, and a list of zillion
positions.<br>
<br>Furthermore, I did:<br><br>>>> for x in xrange(100000000):<br>...
i = random()<br><br>And the memory didn't
increase.<br><br>Grant, take note that there's no gc issue, the numbers
stay alive<br>because the list itself is pointing to them.<br>
<br>Closing this as invalid.<br><br>----------<br>resolution: ->
invalid<br>status: open -> closed<br>
<div>
<div></div>
<div class="Wj3C7c"><br>_______________________________________<br>Python
tracker <<a href="mailto:[EMAIL PROTECTED]">[EMAIL
PROTECTED]</a>><br><<a href="http://bugs.python.org/issue3063"
target="_blank">http://bugs.python.org/issue3063</a>><br>
_______________________________________<br></div></div></blockquote></div><br><br
clear="all"><br>-- <br>Grant Tang
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com