Giter Site home page Giter Site logo

Stylegan2-ada and GANSpace about ganspace HOT 5 OPEN

harskish avatar harskish commented on May 22, 2024
Stylegan2-ada and GANSpace

from ganspace.

Comments (5)

100330706 avatar 100330706 commented on May 22, 2024 4

Hello! At the end I managed the code to work just by changing the repo path when converting the weights to pytorch weights:

python /content/ganspace/models/stylegan2/stylegan2-pytorch/convert_weight.py --repo="path/to/the/stylegan2-ada/repo" "tensorflow_pkl"

Once weights are converted GANSpace works fine. I just had to change a couple of paths to make it work within Colab.

from ganspace.

harskish avatar harskish commented on May 22, 2024 2

Getting stylegan2-ada checkpoints to load probably requires some extra work.
First of all, if the checkpoints are from TensorFlow, then they need to be converted to PyTorch. The conversion needs to be done with https://github.com/rosinality/stylegan2-pytorch, and if that repo doesn't support converting sg2-ada checkpoints, then that functionality needs to be added.
Further, GANSpace uses a fork of the aforementioned repo, so any relevant changes need to be added to the fork (https://github.com/harskish/stylegan2-pytorch).

I'd be happy to accept a pull request if anyone gets this working!

from ganspace.

Mohamed209 avatar Mohamed209 commented on May 22, 2024 1

I solved the issue by converting with the original torch2stylegan repo not the fork included in your repo
Thanks

from ganspace.

Mohamed209 avatar Mohamed209 commented on May 22, 2024

got this issue while converting stylegan2ada model trained with continue training from ffhq256 on custom dataset
KeyError: 'G_mapping/Dense2/weight'
this is true as weights dict has no such layer

from ganspace.

Brainerd95 avatar Brainerd95 commented on May 22, 2024

got this issue while converting stylegan2ada model trained with continue training from ffhq256 on custom dataset KeyError: 'G_mapping/Dense2/weight' this is true as weights dict has no such layer

I get the exact same error (using the official stylegan2-ada repo as suggested above)

I solved the issue by converting with the original torch2stylegan repo not the fork included in your repo Thanks

Can you specify which exact repo you used for that?

from ganspace.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.