- Go to https://toolchains.bootlin.com
- Select arch: armv6-eabihf
- Select libc: glibc
- Download bleeding-edge
- Uncompress it (for example to
/opt) - Add the
bin/directory of the toolchain to$PATH - In my case:
export PATH=$PATH:/opt/armv6-eabihf--glibc--bleeding-edge-2020.08-1
The official instructions on installing TensorFlow are here: https://www.tensorflow.org/install. If you want to install TensorFlow just using pip, you are running a supported Ubuntu LTS distribution, and you're happy to install the respective tested CUDA versions (which often are outdated), by all means go ahead. A good alternative may be to run a Docker image.
I am usually unhappy with installing what in effect are pre-built binaries. These binaries are often not compatible with the Ubuntu version I am running, the CUDA version that I have installed, and so on. Furthermore, they may be slower than binaries optimized for the target architecture, since certain instructions are not being used (e.g. AVX2, FMA).
So installing TensorFlow from source becomes a necessity. The official instructions on building TensorFlow from source are here: ht
| REGIONS = { | |
| 'Auvergne-Rhône-Alpes': ['01', '03', '07', '15', '26', '38', '42', '43', '63', '69', '73', '74'], | |
| 'Bourgogne-Franche-Comté': ['21', '25', '39', '58', '70', '71', '89', '90'], | |
| 'Bretagne': ['35', '22', '56', '29'], | |
| 'Centre-Val de Loire': ['18', '28', '36', '37', '41', '45'], | |
| 'Corse': ['2A', '2B'], | |
| 'Grand Est': ['08', '10', '51', '52', '54', '55', '57', '67', '68', '88'], | |
| 'Guadeloupe': ['971'], | |
| 'Guyane': ['973'], | |
| 'Hauts-de-France': ['02', '59', '60', '62', '80'], |
| #!/bin/sh | |
| TOOLCHAIN=/opt/armv6-eabihf--glibc--bleeding-edge-2020.02-2/bin/arm-buildroot-linux-gnueabihf- | |
| cp arch/arm/configs/nintendo3ds_defconfig .config | |
| make ARCH=arm CROSS_COMPILE=$TOOLCHAIN -j8 | |
| make ARCH=arm CROSS_COMPILE=$TOOLCHAIN nintendo3ds_ctr.dtb | |
| echo "Output file: ./arch/arm/boot/zImage" |
| # | |
| # Automatically generated file; DO NOT EDIT. | |
| # Buildroot 2020.11-312-gfd5eeabac0 Configuration | |
| # | |
| BR2_HAVE_DOT_CONFIG=y | |
| BR2_HOST_GCC_AT_LEAST_4_9=y | |
| BR2_HOST_GCC_AT_LEAST_5=y | |
| BR2_HOST_GCC_AT_LEAST_6=y | |
| BR2_HOST_GCC_AT_LEAST_7=y | |
| BR2_HOST_GCC_AT_LEAST_8=y |
| void poller(int socketIn, std::string srcIP, int port){ | |
| struct pollfd fds[2]; | |
| // Initialize the fds to 0 | |
| memset(fds, 0, sizeof(fds)); | |
| // Wait in ms before poll times out. -1 for infinite | |
| int timeout = 15000; | |
| fds[0].fd = socketIn; |