Skip to content

Instantly share code, notes, and snippets.

View ThoenigAdrian's full-sized avatar
🎯
Focusing

ThoenigAdrian

🎯
Focusing
View GitHub Profile
[jane@nixos:~/graphviz]$ cat default.nix
let
pkgs = import <nixpkgs> {};
mkDerivation = import ./autotools.nix pkgs;
patchedPkgs = import /home/jane/nixpkgs {} // {binutils-unwrapped="";};
mkDerivation2 = import ./autotools.nix patchedPkgs;
libs = with patchedPkgs; { inherit gd fontconfig bzip2 libjpeg;};
in
cat /usr/include/cudnn.h | grep CUDNN_MAJOR -A 2
import socket
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.connect(("127.0.0.1", 80))
#s.send()
#print(s.recv(1024))
@ThoenigAdrian
ThoenigAdrian / tensorflow_gpu_support_test.py
Created December 9, 2019 16:15
Checks if gpu is supported after pip install tensorflow-gpu
import tensorflow
tensorflow.Session(config=tensorflow.ConfigProto(log_device_placement=True))