Giter Site home page Giter Site logo

varunagrawal / bbox Goto Github PK

View Code? Open in Web Editor NEW
97.0 97.0 12.0 5.98 MB

Python library for 2D/3D bounding boxes

Home Page: https://varunagrawal.github.io/bbox/

License: MIT License

Python 98.53% Makefile 0.63% Batchfile 0.85%
3d-bounding-boxes bounding-boxes computer-vision computer-vision-tools

bbox's Introduction

Varun Agrawal

PhD student at Georgia Tech's School of Interactive Computing.

I like robots, food, and music.

Buy Me A Coffee

Varun Agrawal's Stats

bbox's People

Contributors

dependabot[bot] avatar fabaff avatar varunagrawal avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

bbox's Issues

BBox2DList accepted types

Hi,
BBox2D can accept a tuple, but BBox2DList can't accept a list of tuples.
Is it possible to make BBox2DList accept a list of tuples?
Maybe even let BBox2D accept and typing.Sequence, and BBox2DList any Sequence of Sequences.

Thanks

GTSAM中 IMUKittiExampleGPS.m

Hello, nice to meet you, and thank you very much for providing such a useful example for new users of gtsam. About the program (imukittiexamplegps. M), I have successfully run it. Now I want to test it with different data. As a first step, I try to generate data in the same format from Kitti raw data. I want to know   Kittiequivbiasedimu.txt and attached   Kittigps_converted.txt what do these two data components represent respectively, such as attached   What are the meanings of X, y and Z in kittigps_converted.txt? What are the meanings of X, y and Z in kittiequivbiasedimu.txt. Looking forward to your reply!!!
您好,很高兴见到您,非常感谢您为 gts am 的新用户提供了这样一个有用的示例。关于程序( imu kitti example gps 。米),我已经成功运行了。现在我想用不同的数据来检验。作为第一步,我尝试从 Kitti 原始数据生成相同格式的数据。我想知道 Kitti equiv bia sedimum . txt 和附件中的 Kitt i gps _ convorted . txt 这两个数据分量分别代表什么,如附件中 kitt iq ps _ Convented . txt 中的 X , y , Z 是什么意思?kitti equiv biased imu . txt 中的 X 、 y 、 Z 是什么意思?期待您的回复!!!

Why are negative coordinates disallowed in BBox2D setters?

Thanks for putting this library together -- we are finding it very useful.

One limitation we have encountered is that the various setters for the x/y coordinates in BBox2D raise an exception when faced with negative values. It is not clear why this limitation is in place, and it also seems a little inconsistent since the constructor does allow for instantiating a bbox with negative coordinates.

Additionally, the width and height setters prohibit negative values which seems sensible, but there is not similar checking in the constructor and thus you can instantiate a bbox with negative width/height.

Use __array__() method interface instead of numpy() method

Bounding boxes can be cast to a numpy array by exposing the __array__ dunder method, so that you can call np.array() on it and get the result that you want instead of (or in addition to, so that you can still have the flag) the numpy() method.

https://docs.scipy.org/doc/numpy-1.15.0/reference/generated/numpy.array.html

object : array_like

An array, any object exposing the array interface, an object whose __array__ method returns an array, or any (nested) sequence.

Publish package to PyPI

The original bbox package name was reserved by Dustin Tran (the Edward guy) who has responded to me and relinquished control of the name.

Currently, there is no formal process to takeover the package name and publish my code to it, though it is being worked upon by PyPA.

Once the process has been finalized, and I have permission from the legal teams, I should go ahead and publish this library.

Error in jaccard_index_3d when using quaternions

The following code:

from bbox import BBox3D
import pyquaternion
a = BBox3D(x=0, y=0, z=0, q=pyquaternion.Quaternion(axis=[1, 0, 0], angle=3.14159265))  
 b = BBox3D(x=1, y=0, z=0, q=pyquaternion.Quaternion(axis=[1, 0, 0], angle=3.14159265))  
bbox.metrics.iou_3d(a,b)

produces the error

---------------------------------------------------------------------------
IndexError                                Traceback (most recent call last)
<ipython-input-7-e3b42501e331> in <module>
----> 1 bbox.metrics.iou_3d(a,b)

~/PycharmProjects/thea_context/.venv/lib/python3.6/site-packages/bbox/metrics.py in iou_3d(a, b)
    131     Alias for `jaccard_index_3d`.
    132     """
--> 133     return jaccard_index_3d(a, b)
    134 
    135 

~/PycharmProjects/thea_context/.venv/lib/python3.6/site-packages/bbox/metrics.py in jaccard_index_3d(a, b)
    152         return np.round_(0, decimals=5)
    153 
--> 154     intersection_points = polygon_intersection(a.p[0:4, 0:2], b.p[0:4, 0:2])
    155     inter_area = polygon_area(intersection_points)
    156 

~/PycharmProjects/thea_context/.venv/lib/python3.6/site-packages/bbox/geometry.py in polygon_intersection(poly1, poly2)
    171         input_list = output_list
    172         output_list = []
--> 173         s = input_list[-1]
    174 
    175         for e in input_list:

IndexError: list index out of range

Publish new release to PyPi

About a year ago, a fix was committed for a NumPy deprecation.

15cb8fb

Can we publish a release including this fix to PyPi? There hasn't been a new PyPi version since 2020.

Contains point

NIce library. It'd be convenient if it contained a point-inclusion test.

error in jaccard_index_3d?

Is it wrong in this code for jaccard_index_3d?
inter_area = polygon_area(intersection_points)
zmax = np.minimum(a.cz, b.cz) //this is center
zmin = np.maximum(a.cz - a.h, b.cz - b.h) //what is the point?

I think it should be
zmax = np.minimum(a.cz + 0.5 * a.h, b.cz + 0.5 * a.h) //upper bound
zmin = np.maximum(a.cz - 0.5 * a.h, b.cz - 0.5 * b.h) //lower bound
For example,

a = bbox.BBox3D(0,0,0,1,1,2)
b = bbox.BBox3D(0,0,-2.0,1,1,2.4)
jaccard_index_3d(a,b)
0.0

How ever, z range for a is [-1,1]
z range for b is [-3.2,-0.8]
There must be a intersection, which means iou should not be 0.
Is my calculation wrong?

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.