59

The Python help of the module imp is talking about a frozen module. What is it?

http://docs.python.org/library/imp.html#imp.PY_FROZEN

6
  • You realize that it points to an explanation right there in that doc? Were you looking for a detailed answer about what the Freeze process is? Commented Mar 28, 2012 at 22:21
  • Yeah, you're right I was looking for the freeze process. I read the part. I will reformat it or create a new question. Commented Mar 28, 2012 at 22:26
  • No problem. I just posted an answer to that then. Commented Mar 28, 2012 at 22:32
  • write it here: stackoverflow.com/questions/9916647/… I will close this question. Commented Mar 28, 2012 at 22:35
  • import __hello__ Commented Dec 14, 2016 at 18:13

3 Answers 3

49

This link explains what the Python Freeze utility is in detail: http://wiki.python.org/moin/Freeze

In a nutshell, it creates a portable version of a python script that carries its own built in interpreter (basically like a binary executable), so that you can run it on machines without python.

Sign up to request clarification or add additional context in comments.

Comments

11

http://docs.python.org/library/imp.html#imp.PY_FROZEN links to http://docs.python.org/library/imp.html#imp.init_frozen which explains it:

Frozen modules are modules written in Python whose compiled byte-code object is incorporated into a custom-built Python interpreter by Python’s freeze utility. See Tools/freeze/ for now.

2 Comments

Also by utility py2exe
The above quoted text is now at docs.python.org/2/library/imp.html#imp.init_frozen - but I can't find that description, or anything similar, in the Python 3.x documentation. It may be there, I just haven't been able to find it.
5

The answer is in the same place:

(Frozen modules are modules written in Python whose compiled byte-code object is incorporated into a custom-built Python interpreter by Python’s freeze utility. See Tools/freeze/ for now.)

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.