Orange Forum • View topic - python crashes when running the sample_adult.py

python crashes when running the sample_adult.py

A place to ask questions about methods in Orange and how they are used and other general support.

python crashes when running the sample_adult.py

Postby irfanm6d » Tue Aug 11, 2009 4:12

Hi,
I am getting a python crash when using the orange.MakeRandomIndices2(data, 0.03) method in the sample_adult.py.

Any clues??

Thanks,
Irfan

Environment:
python - 2.6
os - ubuntu 9.04
orange - compiled from trunk

irfan@damascus:~/qw/sandbox_6/data/orange/samples$ python sample_adult.py
*** buffer overflow detected ***: python terminated
======= Backtrace: =========
/lib/tls/i686/cmov/libc.so.6(__fortify_fail+0x48)[0xb7fa0da8]
/lib/tls/i686/cmov/libc.so.6[0xb7f9eeb0]
/lib/tls/i686/cmov/libc.so.6[0xb7f9e7b7]
/lib/tls/i686/cmov/libc.so.6(__snprintf_chk+0x34)[0xb7f9e6a4]
/usr/lib/python2.6/dist-packages/orange/orange.so(_ZNK7TOrange25raiseCompatibilityWarningEPKcz+0x7e)[0xb7baea4e]
/usr/lib/python2.6/dist-packages/orange/orange.so(_ZN19TMakeRandomIndices2clE5GCPtrI17TExampleGeneratorERKf+0x625)[0xb7c2c9e5]
/usr/lib/python2.6/dist-packages/orange/orange.so(_Z23MakeRandomIndices2_callP7_objectS0_S0_+0x460)[0xb79d27f0]
/usr/lib/python2.6/dist-packages/orange/orange.so(_Z27PyOrType_GenericCallableNewP11_typeobjectP7_objectS2_+0xb8)[0xb78f7158]
python[0x80ab5ad]
python(PyObject_Call+0x4a)[0x806111a]
python(PyEval_EvalFrameEx+0x380a)[0x80dcfea]
python(PyEval_EvalCodeEx+0x7a8)[0x80e00b8]
python(PyEval_EvalCode+0x57)[0x80e0217]
python(PyRun_FileExFlags+0x121)[0x80fe0e1]
python(PyRun_SimpleFileExFlags+0x1da)[0x80fe43a]
python(Py_Main+0xcb2)[0x805c882]
python(main+0x22)[0x805b972]
/lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe5)[0xb7eb9775]
python[0x805b8b1]
======= Memory map: ========
08048000-08225000 r-xp 00000000 08:05 3063847 /usr/bin/python2.6
08225000-08226000 r--p 001dc000 08:05 3063847 /usr/bin/python2.6
08226000-08273000 rw-p 001dd000 08:05 3063847 /usr/bin/python2.6
08273000-0827c000 rw-p 08273000 00:00 0
090f4000-09a99000 rw-p 090f4000 00:00 0 [heap]
b7468000-b7599000 rw-p b758f000 00:00 0
b75df000-b7620000 rw-p b75df000 00:00 0
b7620000-b762d000 r-xp 00000000 08:05 950830 /lib/libgcc_s.so.1
b762d000-b762e000 r--p 0000c000 08:05 950830 /lib/libgcc_s.so.1
b762e000-b762f000 rw-p 0000d000 08:05 950830 /lib/libgcc_s.so.1
b762f000-b7713000 r-xp 00000000 08:05 8060960 /usr/lib/libstdc++.so.6.0.10
b7713000-b7717000 r--p 000e3000 08:05 8060960 /usr/lib/libstdc++.so.6.0.10
b7717000-b7718000 rw-p 000e7000 08:05 8060960 /usr/lib/libstdc++.so.6.0.10
b7718000-b771e000 rw-p b7718000 00:00 0
b771e000-b7d8c000 r-xp 00000000 08:05 8508993 /usr/lib/python2.6/dist-packages/orange/orange.so
b7d8c000-b7d8d000 ---p 0066e000 08:05 8508993 /usr/lib/python2.6/dist-packages/orange/orange.so
b7d8d000-b7d9a000 r--p 0066e000 08:05 8508993 /usr/lib/python2.6/dist-packages/orange/orange.so
b7d9a000-b7dc3000 rw-p 0067b000 08:05 8508993 /usr/lib/python2.6/dist-packages/orange/orange.so
b7dc3000-b7dd9000 rw-p b7dc3000 00:00 0
b7dd9000-b7de0000 r--s 00000000 08:05 8062810 /usr/lib/gconv/gconv-modules.cache
b7de0000-b7e1f000 r--p 00000000 08:05 8080396 /usr/lib/locale/en_US.utf8/LC_CTYPE
b7e1f000-b7ea3000 rw-p b7e1f000 00:00 0
b7ea3000-b7fff000 r-xp 00000000 08:05 950793 /lib/tls/i686/cmov/libc-2.9.so
b7fff000-b8000000 ---p 0015c000 08:05 950793 /lib/tls/i686/cmov/libc-2.9.so
b8000000-b8002000 r--p 0015c000 08:05 950793 /lib/tls/i686/cmov/libc-2.9.so
b8002000-b8003000 rw-p 0015e000 08:05 950793 /lib/tls/i686/cmov/libc-2.9.so
b8003000-b8006000 rw-p b8003000 00:00 0
b8006000-b802a000 r-xp 00000000 08:05 950801 /lib/tls/i686/cmov/libm-2.9.so
b802a000-b802b000 r--p 00023000 08:05 950801 /lib/tls/i686/cmov/libm-2.9.so
b802b000-b802c000 rw-p 00024000 08:05 950801 /lib/tls/i686/cmov/libm-2.9.so
b802c000-b8040000 r-xp 00000000 08:05 950832 /lib/libz.so.1.2.3.3
b8040000-b8041000 r--p 00013000 08:05 950832 /lib/libz.so.1.2.3.3
b8041000-b8042000 rw-p 00014000 08:05 950832 /lib/libz.so.1.2.3.3
b8042000-b8044000 r-xp 00000000 08:05 950828 /lib/tls/i686/cmov/libutil-2.9.so
b8044000-b8045000 r--p 00001000 08:05 950828 /lib/tls/i686/cmov/libutil-2.9.so
b8045000-b8046000 rw-p 00002000 08:05 950828 /lib/tls/i686/cmov/libutil-2.9.so
b8046000-b8047000 rw-p b8046000 00:00 0
b8047000-b8049000 r-xp 00000000 08:05 950799 /lib/tls/i686/cmov/libdl-2.9.so
b8049000-b804a000 r--p 00001000 08:05 950799 /lib/tls/i686/cmov/libdl-2.9.so
b804a000-b804b000 rw-p 00002000 08:05 950799 /lib/tls/i686/cmov/libdl-2.9.so
b804b000-b8060000 r-xp 00000000 08:05 950821 /lib/tls/i686/cmov/libpthread-2.9.so
b8060000-b8061000 r--p 00014000 08:05 950821 /lib/tls/i686/cmov/libpthread-2.9.so
b8061000-b8062000 rw-p 00015000 08:05 950821 /lib/tls/i686/cmov/libpthread-2.9.so
b8062000-b8064000 rw-p b8062000 00:00 0
b8077000-b8079000 rw-p b8077000 00:00 0
b8079000-b807a000 r-xp b8079000 00:00 0 [vdso]
b807a000-b8096000 r-xp 00000000 08:05 950277 /lib/ld-2.9.so
b8096000-b8097000 r--p 0001b000 08:05 950277 /lib/ld-2.9.so
b8097000-b8098000 rw-p 0001c000 08:05 950277 /lib/ld-2.9.so
bf97e000-bf997000 rw-p bffe7000 00:00 0 [stack]
Aborted
irfan@damascus:~/qw/sandbox_6/data/orange/samples$

Postby marko » Tue Aug 11, 2009 7:01

Both the newest and a week old version worked for me on 32-bit Ubuntu 9.04 and 8.04. Do you use the 64-bit Ubuntu?

Do the other scripts work correctly?

Regards,
Marko

Postby Guest » Tue Aug 11, 2009 12:33

Thanks for the quick reply.

I am using 32 bit ubuntu.

irfan@damascus:~/thirdparty/src/orangesvn$ uname -a
Linux damascus 2.6.28-14-server #47-Ubuntu SMP Sat Jul 25 01:18:34 UTC 2009 i686 GNU/Linux

Any help is appreciated.

Postby Guest » Tue Aug 11, 2009 12:51

To your earlier question, about other scripts. I am able to run the other scripts like data_characteristics.py etc., after making a full copy of adult.tab to adult_sample.tab.

I think the problem is with the method orange.MakeRandomIndices2().

Thanks.

irfan@damascus:~/qw/sandbox_6/data/orange/samples$ python data_characteristics.py
Classes: 2
Attributes: 14 , 6 continuous, 8 discrete
Instances: 32561 total , 7841 with class >50K , 24720 with class <=50K
irfan@damascus:~/qw/sandbox_6/data/orange/samples$

Postby marko » Wed Aug 12, 2009 10:12

I am sorry, but I can not reproduce your error. Could you try installing the beta version of Orange again? Maybe there were some bugs in the repository when you checked out Orange.

Before installation, delete the old source folder and download orange again, either from packed sources (http://www.ailab.si/orange/nightly_builds.html) or SVN (use the trunk). Please follow instructions in INSTALL.linux.txt file.

Postby irfanm6d » Wed Aug 12, 2009 15:44

I rebuilt the orange modules by doing it a complete "make clean" and "make".

The problem is fixed after a full re-install.

Thanks.


Return to Questions & Support



cron