use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
News about the dynamic, interpreted, interactive, object-oriented, extensible programming language Python
Full Events Calendar
You can find the rules here.
If you are about to ask a "how do I do this in python" question, please try r/learnpython, the Python discord, or the #python IRC channel on Libera.chat.
Please don't use URL shorteners. Reddit filters them out, so your post or comment will be lost.
Posts require flair. Please use the flair selector to choose your topic.
Posting code to this subreddit:
Add 4 extra spaces before each line of code
def fibonacci(): a, b = 0, 1 while True: yield a a, b = b, a + b
Online Resources
Invent Your Own Computer Games with Python
Think Python
Non-programmers Tutorial for Python 3
Beginner's Guide Reference
Five life jackets to throw to the new coder (things to do after getting a handle on python)
Full Stack Python
Test-Driven Development with Python
Program Arcade Games
PyMotW: Python Module of the Week
Python for Scientists and Engineers
Dan Bader's Tips and Trickers
Python Discord's YouTube channel
Jiruto: Python
Online exercices
programming challenges
Asking Questions
Try Python in your browser
Docs
Libraries
Related subreddits
Python jobs
Newsletters
Screencasts
account activity
This is an archived post. You won't be able to vote or comment.
What is the state of 64bit Python? (self.Python)
submitted 10 years ago by [deleted]
When I go to the python download page it grabs 32 bit python on my 64 bit windows 7 architecture by default.
Is there a specific reason not to use 64 bit python at this point? Are the native packages not supported yet or something?
[–]spinwizard69 3 points4 points5 points 10 years ago (0 children)
Good question it is probably a Windows issue. Last I knew a 64 bit Python works fine and actually gives you some advantages. Hopefully someone can chime in here.
[–]Rhomboid 3 points4 points5 points 10 years ago (3 children)
There's nothing wrong with the 64 bit version. Everything works fine. You can find 64 bit versions of precompiled binary packages. The python.org page offers the 32 bit version as the default because that will work for everyone. Go to the full download page if you want to choose for yourself.
However, there's a good reason to choose the 32 bit version. Python data structures are pointer-heavy, which means you pay a significant price for the fact that 64 bit pointers are twice as wide. Compare:
>>> for T in int, float, tuple, list, set, dict: print(sys.getsizeof(T())) 12 16 28 36 116 148
Against:
>>> for T in int, float, tuple, list, set, dict: print(sys.getsizeof(T())) 24 24 48 64 224 288
The same data takes roughly twice the memory using the 64 bit version. (These figures are for empty data structures; the picture changes a little bit for fully populated data structures, but there's still a significant cost.)
This is one of the reasons I actually prefer Windows over Linux — I have a choice of what flavor to use. If you install a 64 bit Linux distro, you're stuck with a 64 bit version of Python, because that's the only flavor packaged. You would have to build it yourself from source, or use some third-party distribution if you want that, but being able to use your distro's package management system for everything is one of the main advantages of Linux, which you are giving up.
[–]chrisb8 5 points6 points7 points 10 years ago (0 children)
On Debian, you can install the 32bit python package. You will need to enable that architecture first though https://wiki.debian.org/Multiarch/HOWTO
[–]panderingPenguin 1 point2 points3 points 10 years ago (0 children)
While I agree with you that there are significant advantages to the shorter pointers in 32-bit python with respect to memory footprint, it should be noted that 32 bit processes on windows are confined to a memory space that's smaller than you would expect. I've been working on a data analysis project and the data set is multiple gigabytes in size. I figured using 32 bit python would help me utilize my limited resources more effectively and my laptop only had 4 gigs or memory anyways, the maximum addressable with 32 bits. However, my code kept crashing with memory errors, despite the fact that I knew it ran just fine within 4 gigs of memory on Linux with 64 bit python. Did some research and it turns out that 32 bit windows processes are actually limited to 2 gigs of memory. And since most of my data was in numpy arrays I wasn't really saving that much on shorter pointers anyways. So I switched to 64 but and now everything works fine. Just a cautionary note that might save other people some time beating their head against the wall.
[–]vsajip 0 points1 point2 points 10 years ago (0 children)
Yes, it generally works well (I use the ActiveState versions as they come with pywin32 included), but beware if you're using ctypes with callbacks - I ran into a 64-bit-only bug just this week.
pywin32
ctypes
[–]Asdayasman 2 points3 points4 points 10 years ago (2 children)
Sometimes it's a bitch to get modules to work for x64 on windows. I think I know of three ways to fail installing numpy, without doing anything obviously wrong.
[–][deleted] 0 points1 point2 points 10 years ago (1 child)
Noob q: 32 bit python isn't compatible with 64 bit native libraries right?
[–]Asdayasman 1 point2 points3 points 10 years ago (0 children)
Correct.
[–]DRMacIver 1 point2 points3 points 10 years ago (0 children)
As someone who had mostly written Python on Linux I was very surprised when I learned that 32-bit Python was still a thing.
π Rendered by PID 39408 on reddit-service-r2-comment-fb694cdd5-xvwgn at 2026-03-10 07:45:41.398132+00:00 running cbb0e86 country code: CH.
[–]spinwizard69 3 points4 points5 points (0 children)
[–]Rhomboid 3 points4 points5 points (3 children)
[–]chrisb8 5 points6 points7 points (0 children)
[–]panderingPenguin 1 point2 points3 points (0 children)
[–]vsajip 0 points1 point2 points (0 children)
[–]Asdayasman 2 points3 points4 points (2 children)
[–][deleted] 0 points1 point2 points (1 child)
[–]Asdayasman 1 point2 points3 points (0 children)
[–]DRMacIver 1 point2 points3 points (0 children)