Giter Club home page Giter Club logo

Comments (5)

bhavikapanara avatar bhavikapanara commented on August 23, 2024

@ivelin

Can you please provide me with a sample test fall image so I can reproduce the error and fix it?

from fall-detection.

ivelin avatar ivelin commented on August 23, 2024

No, because the error is intermittent and since it is not handled in a way that provides much context, I cannot correlate the message to an image. Please think how we can better encapsulate this error with a contextual information in the log that allows us to track it down.

from fall-detection.

bhavikapanara avatar bhavikapanara commented on August 23, 2024

ok...will check it.

from fall-detection.

bhavikapanara avatar bhavikapanara commented on August 23, 2024

@ivelin

I have tried to trace this issue but unable to locate the bug.
This function use output data(heatmap_data, offset_data) that are generated from TFLite posenet model.

pose_kps[i, 0] = int(remap_pos[0] + offset_data[max_val_pos[0], max_val_pos[1], i])

pose_kps[i, 0] = int(remap_pos[0] + offset_data[max_val_pos[0], max_val_pos[1], i])
TypeError: only size-1 arrays can be converted to Python scalars

And this error is raised when the function expects a single value but you pass an array instead.

I am trying to check at what circumstance model output is different. But not able to find it.
Can you please help me with your thoughts to deal with this bug?

thanks

from fall-detection.

ivelin avatar ivelin commented on August 23, 2024

It's not obvious to me what the issue is. Is it possible that
remap_pos[0] returns anything but a scalar?
Same question for offset_data[max_val_pos[0], max_val_pos[1], i].

One of these two returns a list or array, which confuses int().

I suggest surrounding these lines with an exception handling block that provides as much context as needed. That way the next time this happens, we would know exactly what caused it.

from fall-detection.

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.