473,395 Members | 1,689 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

scipy and py2exe

I am trying to package my application with py2exe. Unfortunately it
uses both scipy/numpy and numarray so I'm having to jump through a lot
of hoops to get it going. I'm getting problems packaging an app that
uses only scipy. See below.

Thanks!
Janto

===setup.py===
from distutils.core import setup
import py2exe

import sys
sys.argv.append('py2exe')

setup(
windows = [{
"script": "test.py",
}],

options = dict(
py2exe = dict(
ascii=1,
skip_archive = 1,
packages = ["scipy"],
excludes = [
'_gtkagg',
'_tkagg',
'tcl',
'Tkconstants',
'Tkinter',
'tcl',
],
)
),
)

===test.py===
import time
import scipy
print scipy.array([1,2,3])
time.sleep(1)

===error file===
import core -> failed: No module named _internal
import lib -> failed: 'module' object has no attribute '_ARRAY_API'
import linalg -> failed: 'module' object has no attribute '_ARRAY_API'
import dft -> failed: 'module' object has no attribute '_ARRAY_API'
import random -> failed: 'module' object has no attribute 'dtype'
Traceback (most recent call last):
File "test.py", line 2, in ?
File "scipy\__init__.pyc", line 25, in ?
numpy name space
File "numpy\__init__.pyc", line 49, in ?

File "numpy\add_newdocs.pyc", line 2, in ?
`ï¾Cc
File "numpy\lib\__init__.pyc", line 5, in ?

File "numpy\lib\type_check.pyc", line 8, in ?

File "numpy\core\__init__.pyc", line 6, in ?

File "numpy\core\umath.pyc", line 12, in ?

File "numpy\core\umath.pyc", line 10, in __load

AttributeError: 'module' object has no attribute '_ARRAY_API'

Apr 26 '06 #1
0 1609

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: RJS | last post by:
Hi all, I can't get a py2exe compiled app to run with numarray (numarray-0.5.win32- py2.2). Also wxPythonWIN32-2.3.3.1-Py22 and ActivePython-2.2.1-222. In the sample below, commenting out...
2
by: Stefan Behrens | last post by:
Hi, does anybody know how I can get py2exe to work with wxPython's wxCalendarCtrl? Currently, I have just a "standard" setup.py, and py2exe gives me a syntax error. Do I need to include any...
0
by: Kathleen Kudzma | last post by:
I'm having a problem with py2exe for Python 2.3. I got fixed the Lookuperror no codec search functions registered: can't find encoding by following the instructions on the py2exe page (added...
8
by: Kathleen Kudzma | last post by:
Does anyone know how to resolve the following problem that I'm getting in Python 2.2 and 2.3? PROBLEM: When I try to create a classReader object I get an exception: "SAXReaderNotAvailable: No...
6
by: Luc Saffre | last post by:
Hello, I had a strange problem when freezing (using either py2exe or McMillan installer) a script that imports reportlab (which imports PIL (which imports FixTk))). - Python 2.3.3c (also with...
1
by: tkpmep | last post by:
I installed SciPy and NumPy (0.9.5, because 0.9.6 does not work with the current version of SciPy), and had some teething troubles. I looked around for help and observed that the tutorial is dated...
0
by: Julien Fiore | last post by:
Hi, I have problems trying to install the scipy.weave package. I run Python 2.4 on windows XP and my C compiler is MinGW. Below is the output of scipy.weave.test(). I read that the tests should...
2
by: robert | last post by:
I'm using latest numpy & scipy. What is this problem ? : RuntimeError: module compiled against version 1000002 of C-API but this version of numpy is 1000009 Traceback (most recent call last):...
2
by: Frank Moyles | last post by:
Hi, I want to use SciPy library. I am using W2k, and ActiveState Python 2.5. I have succesfully numpy, but when I run the scipy-0.6.0.win32-py2.5.exe (from the downloads section on the SciPy...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.