Skip to content

ReflectionPadding2D gives error at save #59

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 9 commits into
base: tensorflow_2
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion 07_01_notation_compose.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"outputs": [],
"source": [
"\n",
"from music21 import converter\n"
"from music21 import converter, chord, note\n"
]
},
{
Expand Down
4 changes: 4 additions & 0 deletions Dockerfile.cpu
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ ARG groupid=1000
ARG userid=1000
## end modify

RUN apt-get update && apt-get install -y \
graphviz \
libgraphviz-dev

COPY ./requirements.txt /
RUN python3 -m pip install --upgrade pip
RUN pip install -r /requirements.txt
Expand Down
4 changes: 4 additions & 0 deletions Dockerfile.gpu
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ ARG groupid=1000
ARG userid=1000
## end modify

RUN apt-get update && apt-get install -y \
graphviz \
libgraphviz-dev

COPY ./requirements.txt /
RUN python3 -m pip install --upgrade pip
RUN pip install -r /requirements.txt
Expand Down
45 changes: 8 additions & 37 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,44 +1,15 @@
# Generative Deep Learning
### Teaching Machines to paint, write, compose and play
# 🦜 Generative Deep Learning

The official code repository for examples in the O'Reilly book 'Generative Deep Learning'
## [NEW] 🚀 2nd edition codebase now live!

https://learning.oreilly.com/library/view/generative-deep-learning/9781492041931/
⚠️ This repository is no longer maintained as the codebase for the 2nd edition of Generative Deep Learning is now live!

https://www.amazon.com/Generative-Deep-Learning-Teaching-Machines/dp/1492041947/ref=sr_1_1
Please head over to https://github.com/davidADSP/Generative_Deep_Learning_2nd_Edition to check it out.

## Structure

This repository is structured as follows:

The notebooks for each chapter are in the root of the repository, prefixed with the chapter number.

The `data` folder is where to download relevant data sources (chapter 3 onwards)
The `run` folder stores output from the generative models (chapter 3 onwards)
The `utils` folder stores useful functions that are sourced by the main notebooks

## Book Contents
Part 1: Introduction to Generative Deep Learning
* Chapter 1: Generative Modeling
* Chapter 2: Deep Learning
* Chapter 3: Variational Autoencoders
* Chapter 4: Generative Adversarial Networks

Part 2: Teaching Machines to Paint, Write, Compose and Play
* Chapter 5: Paint
* Chapter 6: Write
* Chapter 7: Compose
* Chapter 8: Play
* Chapter 9: The Future of Generative Modeling
* Chapter 10: Conclusion


## Getting started

To get started, first install the required libraries inside a virtual environment:

`pip install -r requirements.txt`

## Branches

The `master` branch of this repo contains the Tensorflow 1.14 code that is present in the original book (first edition)

The `tensorflow_2` branch contains updated code that runs using Tensorflow 2.

However, I recommend swiching over to the repository for the 2nd edition (see above), as it contains many new examples and improvements to the overall structure.
2 changes: 1 addition & 1 deletion models/cycleGAN.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from __future__ import print_function, division
import scipy

from keras_contrib.layers.normalization import InstanceNormalization
from keras_contrib.layers.normalization.instancenormalization import InstanceNormalization
from keras.layers import Input, Dense, Reshape, Flatten, Dropout, Concatenate
from keras.layers import BatchNormalization, Activation, ZeroPadding2D, Add
from keras.layers.advanced_activations import LeakyReLU, ELU
Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ jupyter-core==4.4.0
Keras==2.2.4
Keras-Applications==1.0.7
Keras-Preprocessing==1.0.9
git+https://www.github.com/keras-team/keras-contrib.git
kiwisolver==1.0.1
Markdown==3.0.1
MarkupSafe==1.1.0
Expand Down