Skip to content

Instantly share code, notes, and snippets.

@timehaven
Created July 19, 2017 15:47
Show Gist options
  • Save timehaven/c1d0838884464669758d5e12a32ea5b5 to your computer and use it in GitHub Desktop.
Save timehaven/c1d0838884464669758d5e12a32ea5b5 to your computer and use it in GitHub Desktop.
# 'features' is file path to bcolz array on disk
bc = bcolz.open(features)[:]
# begin epoch loop
while 1:
...
df = df.sample(frac=1) # shuffle all rows
bc = bc[df.index.values]
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment