Giter Club home page Giter Club logo

Comments (4)

alfredomaussa avatar alfredomaussa commented on May 22, 2024 2

i changed this line of code and worked:

prediction = model.predict([np.einsum('ij->ji', source).reshape((1,30,37)), s0[:1], c0[:1]])

from deep-learning-specialization-coursera.

piyushsoni27 avatar piyushsoni27 commented on May 22, 2024

Is there any resolution for this error yet? I am facing similar error. I am using Keras- "2.2.4"

from deep-learning-specialization-coursera.

esraahisham753 avatar esraahisham753 commented on May 22, 2024

I have the same error also

from deep-learning-specialization-coursera.

shanghaiJ avatar shanghaiJ commented on May 22, 2024

I edited code with this:

source = string_to_int(example, Tx, human_vocab)
source = np.array(list(map(lambda x: to_categorical(x, num_classes=len(human_vocab)), source)))
ttt=np.expand_dims(source,axis=0)
print(ttt.shape)
prediction = model.predict([ttt, s0, c0])

Then, I got another error:
ValueError: Data cardinality is ambiguous:
x sizes: 1, 10000, 10000
Please provide data which shares the same first dimension.

I downgraded TF version to 2.0.0 instead of 2.3.0.

Anybody able to solve the issue? I am stuck on this.

from deep-learning-specialization-coursera.

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.