Git Product home page Git Product logo

Comments (7)

pavitrakumar78 avatar pavitrakumar78 commented on September 28, 2024

Are you sure the image you open at line 57 is of shape (3232,208,3)? Try opening an image separately and check the dimensions. The error has nothing to do with any code that you have attached above. image_shape which is a parameter to sample_from_dataset() function should match the dimensions of whatever image you are loading.

from anime-face-gan-keras.

vinaysp avatar vinaysp commented on September 28, 2024

@pavitrakumar78 I have previously checked the size of the images and am certain the dimensions I have provided above are correct, these images are images of actual 2d platformer game levels.

You mention that the error is not to do with the code? what does the error in screenshot refer to?Apologies but I am still pretty new to GAN models

from anime-face-gan-keras.

pavitrakumar78 avatar pavitrakumar78 commented on September 28, 2024

It does where the images are from and the error has nothing to do with GAN logic. It's just that the image you inputted is of shape (208,3232,3) and when you try to save it into an array of objects of shape (3232,208,3) it gives you the error you see above.
Try changing line 66 to:
sample[index,...] = image.T

from anime-face-gan-keras.

vinaysp avatar vinaysp commented on September 28, 2024

screen shot 2018-06-27 at 15 21 36

@pavitrakumar78 When I changed the line to sample[index,...] = image.T the above error occurred

I then tried the following sample[index,...] = image.T[2,1,0] I got the following error
screen shot 2018-06-27 at 15 29 29

from anime-face-gan-keras.

pavitrakumar78 avatar pavitrakumar78 commented on September 28, 2024

Sorry. My bad, use np.rot90(image) instead of image.T because it's a 3D array.

from anime-face-gan-keras.

vinaysp avatar vinaysp commented on September 28, 2024

still producing index out of range error
screen shot 2018-06-27 at 15 54 54

from anime-face-gan-keras.

pavitrakumar78 avatar pavitrakumar78 commented on September 28, 2024

Please check where the error is coming from and work from there. The original error you had has been solved.

If you need help with matplotlib, check their documentation.

Since this is not an issue anymore with the actual code in the repository, I will close this issue. If you think there is still an issue related to the code (like GAN logic), feel free to re-open this issue.

from anime-face-gan-keras.

Related Issues (3)

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.