Reputation: 365
I'm using Debian 10.2 (buster) and followed the procedure on https://www.tensorflow.org/install/pip?lang=python3 , using the virtual environment procedure as recommended. Everything works, down to and including:
pip install --upgrade tensorflow
This generates a bunch of progress messages, all of which look OK. The very last step is "Verify the install:"
python -c "import tensorflow as tf;print(tf.reduce_sum(tf.random.normal([1000, 1000])))"
I type that (still in the venv environment) and it generates the message:
Illegal instruction (core dumped)
Nothing else. No hint as to what went wrong.
I used gdb to look at the core dump and found:
Program terminated with signal SIGILL, Illegal instruction.
#0 0x00007fafbfd99820 in nsync::nsync_mu_init(nsync::nsync_mu_s_*) () from
/home/me/venv/lib/python3.7/site-packages/tensorflow_core/python/_pywrap_tensorflow_internal.so
Upvotes: 0
Views: 222
Reputation: 365
https://www.tensorflow.org/install/pip says:
Starting with TensorFlow 1.6, binaries use AVX instructions
My box says "Core i7" on the outside, but my /proc/cpuinfo gives the following flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf pni dtes64 monitor ds_cpl vmx smx est tm2 ssse3 cx16 xtpr pdcm sse4_1 sse4_2 popcnt lahf_lm pti ssbd ibrs ibpb stibp tpr_shadow vnmi flexpriority ept vpid dtherm ida flush_l1d
So I conclude it doesn't have avx and the pre-built binaries require it. The pre-built binaries are therefore useless except for newer computers.
Upvotes: 1