Skip to content

Instantly share code, notes, and snippets.

💭
waiting for the end of the deep learning hype

Patrick Wieschollek PatWie

💭
waiting for the end of the deep learning hype
Block or report user

Report or block PatWie

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@PatWie
PatWie / tf_info.sh
Created Jan 11, 2019
Trouble-Shooting TensorFlow
View tf_info.sh
# get os info
uname -as
# get compiler info
g++ --version
# check python library versions
pip list 2>&1 | grep "proto\|numpy\|tensorflow"
# get TensorFlow information
cat <<EOF > /tmp/check_tf.py
import tensorflow as tf;
print("path = %s" % tf.__file__)
@PatWie
PatWie / glfw_ship.cpp
Created Dec 5, 2018 — forked from ad8e/glfw_ship.cpp
instructions to use skia and glfw together. (download, installation, first program). works on Linux and Windows.
View glfw_ship.cpp
/* Note: this Google copyright notice only applies to the original file, which has large sections copy-pasted here. my changes are under CC0 (public domain).
* Copyright 2015 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
/*
this is intended as a second-resort, after trying to build using the official instructions inevitably fails because of poor documentation and strange build systems.
View cuda_index.h
// Patrick Wieschollek <mail@patwie.com>, 2018
#ifndef LIB_CUDA_INDEX_H_
#define LIB_CUDA_INDEX_H_
#include <array>
namespace cuda_index {
namespace impl {
@PatWie
PatWie / benchmark.py
Created Jun 19, 2018
database benchmark tensorpack
View benchmark.py
#! /usr/bin/env python
# -*- coding: utf-8 -*-
# Author: Patrick Wieschollek <mail@patwie.com>
from tensorpack import *
from tensorpack.dataflow.base import DataFlow
from tensorpack.dataflow.dftools import LMDBDataWriter, TFRecordDataWriter, NumpyDataWriter, HDF5DataWriter
from tensorpack.dataflow.format import LMDBDataReader, TFRecordDataReader, NumpyDataReader, HDF5DataReader
import os
@PatWie
PatWie / nvml.py
Created Feb 8, 2018
NVML for Python
View nvml.py
#! /usr/bin/env python
# -*- coding: utf-8 -*-
# Author: Patrick Wieschollek <mail@patwie.com>
"""
A Python2 + Python3 wrapper for NVML
"""
from ctypes import *
import threading
View c.txt
A B C D E F
A B C D E H
A B C D E I
A B C D E K
A B C D E L
A B C D E M
A B C D E O
A B C D F H
A B C D F I
A B C D F K
@PatWie
PatWie / foot.txt
Last active Jan 6, 2018
shhot foot
View foot.txt
TASK: To shoot yourself in the foot...
C
You shoot yourself in the foot.
C++
You accidentally create a dozen instances of yourself and shoot them all in the foot.
Providing emergency medical care is impossible since you can't tell which are bitwise
copies and which are just pointing at others and saying, "That's me over there."
@PatWie
PatWie / test.cu
Created Dec 1, 2017
test nvidia-smi
View test.cu
// compile me by nvcc copy.cu -o test
#include <iostream>
int main(int argc, char const *argv[])
{
const size_t MB = 10;
const size_t len = MB*256;
float *d_ptr, *h_ptr;
View wide_face.py
# Patrick Wieschollek <mail@patwie.com>
from zipfile import ZipFile
import cv2
import numpy as np
import scipy.io as sio
from tensorpack import *
import argparse
"""
@PatWie
PatWie / TheNumericsOfGANs.ipynb
Created Sep 16, 2017 — forked from LMescheder/TheNumericsOfGANs.ipynb
This notebook contains the code for the toy experiment in the paper The Numerics of GANs.
View TheNumericsOfGANs.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
You can’t perform that action at this time.