I am rolling up a distribution of a program I wrote. It uses matplotlib
with tkagg so the bundle is HUGE (47 MB, 14 MB after bz compression). Is
there any way to run the program, put it through all of its paces, and
then inspect which modules were loaded. I would like to gather these in
a list and delete any others that py2app and py2exe attempt to include.
Currently, these (or py2app, at least) use dependency graphing and
icnlude everything belonging to pylab, matplotlib, and numpy by default.
I don't want everything, I only want what my program needs to run. For
example, some modules are imported by functions (in Pmw, for example)
that never get called. I don't want to include these.
Thanks in advance for any help.
James 1 1129
James Stroud wrote:
I am rolling up a distribution of a program I wrote. It uses
matplotlib with tkagg so the bundle is HUGE (47 MB, 14 MB after bz
compression). Is there any way to run the program, put it through all
of its paces, and then inspect which modules were loaded. I would like
to gather these in a list and delete any others that py2app and py2exe
attempt to include. Currently, these (or py2app, at least) use
dependency graphing and icnlude everything belonging to pylab,
matplotlib, and numpy by default. I don't want everything, I only want
what my program needs to run. For example, some modules are imported
by functions (in Pmw, for example) that never get called. I don't want
to include these.
Thanks in advance for any help.
James
-- http://mail.python.org/mailman/listinfo/python-list
Import sys, then look at sys.modules. It's a dictionary that contains
all the imported modules, but I suspect you'll find that it's much
easier to let py2app and py2exe determine what's imported than it is to
go through sys.modules yourself.
Gary Herron This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: saidev |
last post by:
A quick question, I'm about to recompile PHP, last time I compiled it
with alot of modules, thinking that this time I should not need that
many. Is there any tool(s) that could run under the...
|
by: Remy Cool |
last post by:
Hello,
I've created an archive import class (with the help of importers.py from the
python /demo/imputil dir) which imports packages and modules from a
dictionary. So far so good.
The problem...
|
by: Jelmer |
last post by:
Hi I've been trying to create an addin similar to Find & Replace from Rick
Fisher that looks thru your tables / queries / forms / modules etc.. for a
reference to a string and optionally let's you...
|
by: Lauren Quantrell |
last post by:
At running the risk of asking how big is too big...
Is there a rule of thumb or a best practice that says I may have too
many modules? I currently have a Access2K app with about 30 code
modules,...
|
by: David Van D |
last post by:
Hi there,
A few weeks until I begin my journey towards a degree in Computer
Science at Canterbury University in New Zealand,
Anyway the course tutors are going to be teaching us JAVA wth bluej...
|
by: mfasoccer |
last post by:
I am sorry if this is an inappropriate place to put this post, if so
please delete it.
I am wondering about a few things. Do you guys recommend learning C as
a second language, as someone who...
|
by: Frank |
last post by:
Hi,
I have the following weird behavior when I load modules:
8
Everything is fine.
Traceback (most recent call last):
|
by: Marco |
last post by:
Hi
Is there a way to find out if a thread holds a handle to a loaded module?
In detail:
I have all IDs and handles of all running threads and loaded modules(dlls)
of a process.
No i want to...
|
by: bernhard.voigt |
last post by:
Hey!
I'm using ipython as my python shell and often run scripts with the
magic command %run:
In : %run script.py
If modules are loaded within the script these are not reloaded when I
rerun...
|
by: MeoLessi9 |
last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
|
by: DolphinDB |
last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation.
Take...
|
by: DolphinDB |
last post by:
Tired of spending countless mintues downsampling your data? Look no further!
In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
|
by: Aftab Ahmad |
last post by:
Hello Experts!
I have written a code in MS Access for a cmd called "WhatsApp Message" to open WhatsApp using that very code but the problem is that it gives a popup message everytime I clicked on...
|
by: Aftab Ahmad |
last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below.
Dim IE As Object
Set IE =...
|
by: ryjfgjl |
last post by:
ExcelToDatabase: batch import excel into database automatically...
|
by: marcoviolo |
last post by:
Dear all,
I would like to implement on my worksheet an vlookup dynamic , that consider a change of pivot excel via win32com, from an external excel (without open it) and save the new file into a...
|
by: Vimpel783 |
last post by:
Hello!
Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
|
by: ArrayDB |
last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
| |