image-gpt icon indicating copy to clipboard operation
image-gpt copied to clipboard

Oh c’mon you guys...

Open kcrosley-leisurelabs opened this issue 5 years ago • 15 comments

Colab notebook?

(OpenAI’s dedication to crap documentation never ceases to amaze, amirite?)

kcrosley-leisurelabs avatar Jun 18 '20 02:06 kcrosley-leisurelabs

I'd like a colab notebook too but it's probably too much to ask.

Kreijstal avatar Jun 18 '20 09:06 Kreijstal

Here you go. Just does sampling, I didn't implement image completion.

https://gist.github.com/JonathanFly/eb61f0d31680e1b890f3a53fbaf31384

JonathanFly avatar Jun 18 '20 11:06 JonathanFly

@JonathanFly on the codelab How can I pass images as input? thanks

methescripter avatar Jun 18 '20 16:06 methescripter

@JonathanFly on the codelab How can I pass images as input? thanks

That wasn't built in to the code released. It shouldn't be too hard to add but someone will have to do it. They do provide an encoding function for their cluster palette. I'll probably add it if I play more with this in the future.

JonathanFly avatar Jun 19 '20 09:06 JonathanFly

backlink https://github.com/huggingface/transformers/issues/5088

Kreijstal avatar Jun 19 '20 10:06 Kreijstal

Hey guys, I modified @JonathanFly 's notebook to support conditional input such as cropped images.

colab

apeguero1 avatar Jun 19 '20 21:06 apeguero1

Thanks @apeguero1 you improved it a lot.

JonathanFly avatar Jun 20 '20 00:06 JonathanFly

No problem @JonathanFly glad to help (:

apeguero1 avatar Jun 20 '20 00:06 apeguero1

@apeguero1 I tried Runtime>Run All, but it doesn't work. GPU is not the problem, and I cannot understand what the problem is. On "Functions from run.py", on "import tensorflow as tf", it shows an error and it says:


NOTE: If your import is failing due to a missing package, you can manually install dependencies using either !pip or !apt.

To view examples of installing some common dependencies, click the "Open Examples" button below.

dryn27 avatar Sep 02 '20 11:09 dryn27

Thanks for pointing this out @dryn27. Somehow bumping up to tensorflow version 1.15.0 fixes the import error. Just updated the colab.

apeguero1 avatar Sep 07 '20 17:09 apeguero1

Hey guys, I modified @JonathanFly 's notebook to support conditional input such as cropped images.

colab

Hi, Is there any way to sample with a higher resolution?

Randy-H0 avatar Sep 28 '20 22:09 Randy-H0

@apeguero1

Hi! thanks for the colab with the conditional sampling.

is it possible to generate samples from a specific class from ImageNet?

Generating photos of cars for example.

eyalbetzalel avatar Oct 07 '20 20:10 eyalbetzalel

@eyalbetzalel hmm... in theory you could just finetune the whole model on a subset of the images with a particular label. Haven't tried this yet though.

Alternatively, Maybe you could make an adapter per class starting with the HF model made here which would seem to be more efficient.

Ideally, there would be a way to train a single slightly modified architecture of the model that just adds a learned class conditional embedding to the token and positional embeddings. That would be pretty cool.

apeguero1 avatar Oct 12 '20 10:10 apeguero1

Why’d you email me idk who you are Sent from ProtonMail Mobile

On Mon, Oct 12, 2020 at 3:49 AM, DJ AI [email protected] wrote:

@eyalbetzalel hmm... in theory you could just finetune the whole model on a subset of the images with a particular label. Haven't tried this yet though.

Alternatively, Maybe you could make an adapter per class starting with the HF model made here which would seem to be more efficient.

Ideally, there would be a way to train a single slightly modified architecture of the model that just adds a learned class conditional embedding to the token and positional embeddings. That would be pretty cool.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.

proudbatdan avatar Oct 12 '20 15:10 proudbatdan

@proudbatdan you might be signed up to watch this repo for any activity. You can always disable this.

apeguero1 avatar Oct 12 '20 19:10 apeguero1