Skip to content

Instantly share code, notes, and snippets.

View lucasrdrgs's full-sized avatar

Lucas Rodrigues lucasrdrgs

  • Hubla
  • Campinas - São Paulo
  • 18:58 (UTC -03:00)
View GitHub Profile
@lucasrdrgs
lucasrdrgs / shuffle_weights.py
Created October 31, 2019 23:31 — forked from jkleint/shuffle_weights.py
Quickly re-initialize weights of a Keras model
#!/usr/bin/env python
"""Demonstrate Keras model weight shuffling as fast alternative to re-creating a model."""
from __future__ import print_function
import numpy as np
from keras.layers import Dense
from keras.models import Sequential