what is a .pyo file?

Kalle Svensson karl-sve at dsv.su.se
Fri Jun 23 07:34:38 EDT 2000


On 23 Jun 2000, Venkatesh Prasad Ranganath wrote:

> what are the contents of .pyo file?  When is it generated?  What is it used for?

It's optimized byte code, generated by importing a module or using
py_compile.compile() in a python process run with the -O command line
option. The advantages of the .pyo over the .pyc file is just that it's
optimized and thus runs faster. I guess... :)

HTH,
  Kalle Svensson




More information about the Python-list mailing list