Skip to content

Instantly share code, notes, and snippets.

@jakublipinski
jakublipinski / install_tensorflow_custom_gcc.md
Last active February 8, 2024 02:54
How to install Tensorflow with custom GCC

How to install the latest version of Tensorflow (2.3.0) on a machine where the default gcc is too old or too new and you don't have root access

This solves the following issue when compiling Tensorflow:

ERROR: /home/users/*/tensorflow/tensorflow/core/framework/BUILD:1324:1: ProtoCompile tensorflow/core/framework/op_def.pb.h failed (Exit 1)
bazel-out/host/bin/external/com_google_protobuf/protoc: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by bazel-out/host/bin/external/com_google_protobuf/protoc)
bazel-out/host/bin/external/com_google_protobuf/protoc: /lib64/libstdc++.so.6: version `CXXABI_1.3.8' not found (required by bazel-out/host/bin/external/com_google_protobuf/protoc)
bazel-out/host/bin/external/com_google_protobuf/protoc: /lib64/libstdc++.so.6: version `CXXABI_1.3.9' not found (required by bazel-out/host/bin/external/com_google_protobuf/protoc)
bazel-out/host/bin/external/com_google_protobuf/protoc: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by b
===== BEGIN SOLIDSTAMP VERIFICATION =====
srxc5pxncsh3duyhdrqaeyeav7ajfivk
===== END SOLIDSTAMP VERIFICATION =====
@jakublipinski
jakublipinski / sync vs async vs batch
Last active February 7, 2023 07:40
Web3 JSON RPC
import timeit
import asyncio
import contextlib
import requests
from aiohttp import ClientSession
from web3.providers.base import JSONBaseProvider
from web3.providers import HTTPProvider
from web3 import Web3
===== BEGIN SOLIDSTAMP VERIFICATION =====
vf37fgxuyywwlikqyf3rdvbuyndvfrz1
===== END SOLIDSTAMP VERIFICATION =====
===== BEGIN SOLIDSTAMP VERIFICATION =====
o4wspkyrbbdbdmo69t3vrirvnf1ydujp
===== END SOLIDSTAMP VERIFICATION =====
===== BEGIN SOLIDSTAMP VERIFICATION =====
oxaa4cybetu1edbtgns5wlw63k8zwbvz
===== END SOLIDSTAMP VERIFICATION =====
===== BEGIN SOLIDSTAMP VERIFICATION =====
r062yws7csamldzatfue72y4ugglp7uk
===== END SOLIDSTAMP VERIFICATION =====
===== BEGIN SOLIDSTAMP VERIFICATION =====
4yr4v5fkrd3t0tvesttle1gkpc4qncie
===== END SOLIDSTAMP VERIFICATION =====
===== BEGIN SOLIDSTAMP VERIFICATION =====
k8umdg6dsrfcayj1bikfmw3mbyncwhf1
===== END SOLIDSTAMP VERIFICATION =====
===== BEGIN SOLIDSTAMP VERIFICATION =====
xodud3wy8byy6yleyaf2idubbky1jyjn
===== END SOLIDSTAMP VERIFICATION =====