Question

I wrote a genetic algorithm program using the inspyred library with a 32bit Python2.7 version on a 64bit Win7 machine. While generating the population the program stops running when it uses memory up to 1959044K.

I have read a number of questions on this site, and I understand that it is due to a 2GB cap on 32bit programs by the OS. So I have tried to switch to a 64bit Python and install the 64bit versions of the modules I was working with, unfortunately all but one module cannot run on the 64bit platform.

I also installed pywin32 as advised in another question but that has failed to help too. This module is not a standard Python library and I have pasted it below. The error message I get is:

import AoN
ImportError: DLL load failed: %1 is not a valid Win32 application.

My understanding is that the 64bit Python does not recognize the 32bit module. I also read here: http://effbot.org/zone/python-compile.htm about compiling the source code, but I have compiled the source code in 64bit but that does not help either as it continues to give that error.

Lastly I pasted the directory path of the module in the interpreter path but that does not help too.

Is there a way to have this module run on the 64bit Python? And please can anyone explain the process of compiling source codes and if that can help me out?

Was it helpful?

Solution

The answer is simple - it can't work. A process is either 32 or 64 bit, it's as simple as that. So if there is one module that can't run in 64 bit, one option besides re-compiling the module for 64 bit is to delegate whatever purpose it has to a second process running in 32 bit, just doing that. This might or might not be practical, depending on the actual task of the module.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top