Program uses twice as much memory in Python 3.6 than in Python 3.5

Peter Otten __peter__ at web.de
Tue Mar 28 03:08:37 EDT 2017


Jan Gosmann wrote:

> On 27 Mar 2017, at 18:30, Peter Otten wrote:
> 
>> Are you perchance comparing 32-bit Python 3.5 with 64-bit Python 3.6?
> 
> I don't think so.
> [sys.maxsize](https://docs.python.org/3/library/platform.html#cross-platform)
> indicates both to be 64-bit.

While my original idea was obviously nonsense given the amount of memory you 
deal with I still cling to the underlying idea.

Perhaps numpy's default integer type has changed (assuming you are using 
integer arrays, I did look at, but not into your code)?

You could compare

>>> numpy.array([42]).itemsize
8

for the two interpreters.



More information about the Python-list mailing list