Skip to content

Instantly share code, notes, and snippets.

View ischlag's full-sized avatar

Imanol Schlag ischlag

View GitHub Profile
import tensorflow as tf
import numpy as np
import random
import time
from tensorflow.python.framework import ops
from tensorflow.python.framework import dtypes
dataset_path = "/cs/home/is59/database/"
train_labels_file = "labels.csv"
import tensorflow as tf
import numpy as np
import random
import time
from tensorflow.python.framework import ops
from tensorflow.python.framework import dtypes
dataset_path = "/cs/home/is59/database/"
train_labels_file = "labels.csv"
@ischlag
ischlag / mnist-to-jpg.py
Last active January 23, 2024 06:45
Simple python script which takes the mnist data from tensorflow and builds a data set based on jpg files and text files containing the image paths and labels. Parts of it are from the mnist tensorflow example.
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import gzip
import os
import sys
import time
from six.moves import urllib