question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ValueError: invalid literal for int() with base 10: '0.69327074'

See original GitHub issue

When the input has floating values i.e the bounding boxes I am getting the following error ValueError: invalid literal for int() with base 10: '0.69327074'

I changed the line 263 of the ssd_batch_generator.py file to obj.append(float(i[self.input_format.index(item)].strip())) but in vain

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
pierluigiferraricommented, Feb 13, 2018

As I said above, you should just change your coordinate values from relative to absolute. Doing that is way easier than changing the batch generator.

If you want to change the code to work with relative coordinates, that’s your own adventure. I don’t know of the top of my head all places in the code you’d have to change and I don’t intend to invest time in it. If I were you I would just write a simple preprocessing function that takes your CSV with relative coordinates and outputs either another CSV with absolute coordinates or a Python list with the labels in the format as the batch generator constructor needs them.

0reactions
heavenaocommented, Jan 14, 2019

I have changed the absolute coordinates of the picture. But still report an error,invalid literal for int() with base 10: ‘628.0’。

Read more comments on GitHub >

github_iconTop Results From Across the Web

ValueError: invalid literal for int() with base 10: '' - Stack Overflow
ValueError : invalid literal for int() with base 10: '' · 2. For anyone currently looking here. The error may be that one...
Read more >
Python ValueError: invalid literal for int() with base 10
This error can frequently occur when converting user-input to an integer-type using the int() function. This problem happens because Python stores the input...
Read more >
Python ValueError: invalid literal for int() with base 10 Solution
Our error message tells us there is an invalid literal for an integer in base 10. This means the value we have passed...
Read more >
ValueError: invalid literal for int() with base 10
The error message invalid literal for int() with base 10 would seem to indicate that you are passing a string that's not an...
Read more >
How to fix this ValueError invalid literal for int with base 10 ...
The error message invalid literal for int() with base 10 would seem to indicate that you are passing a string that's not an...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found