Giter VIP home page Giter VIP logo

Comments (5)

drasmuss avatar drasmuss commented on July 20, 2024 1

Rank refers to the number of dimensions in the array. So, e.g., an array with shape (5,) is rank 1, (5, 3) would be rank 2, etc. So that error is telling you that you have an extra dimension in your input data. In that line print(x_train.shape..., I'd guess that that is printing out a shape with 4 elements (likely because the two-dimensional images have not been flattened).

from nengo-dl.

joh10891 avatar joh10891 commented on July 20, 2024 1

Ah, yes. Attached are some tests I ran after loading both datasets (prior to adding the time dimension). They seem so similar (screenshot), so was not sure why the mnist fashion would throw an extra dimension error when running sim. After poring through data very thoroughly, was able to sort it out- issue was with each row in mnist fashion image being stored as an array, rather than one large array.

After restructuring data, got spiking working with fashion-mnist! I appreciate the help!
screen shot 2018-11-18 at 10 58 50 pm

from nengo-dl.

joh10891 avatar joh10891 commented on July 20, 2024

That is what I had assumed, but when I print("x_train shape:", x_train.shape, "y_train shape:", y_train.shape) , it returns x_train shape: (60000, 28, 28) y_train shape: (60000,) So it appears that the x_train is 3 dim. I appreciate your help, excited to start working with nengo-dl more.

from nengo-dl.

drasmuss avatar drasmuss commented on July 20, 2024

Oh also keep in mind that if you're following the spiking-mnist example then later on you're adding an extra dimension (for time), so your shape would become (60000, 1, 28, 28).

from nengo-dl.

sauravtii avatar sauravtii commented on July 20, 2024

Hi @joh10891!

I am also facing the same issue, so can you please share the code of how you restructured the data that helped you resolving the issue ?

from nengo-dl.

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.