Coder Social home page Coder Social logo

Comments (4)

cvramanan avatar cvramanan commented on August 11, 2024

If i try to run draw_trajectory function the error below pops up
`/kaggle/usr/lib/lyft_l5kit_unofficial_fix/l5kit/visualization/utils.py in draw_trajectory(on_image, positions, rgb_color, radius, yaws)
70 for pos in positions:
71 pred_waypoint = pos[:2]
---> 72 cv2.circle(on_image, tuple(pred_waypoint.astype(np.int)), radius, rgb_color, -1)
73
74

TypeError: Argument 'radius' is required to be an integer`

I'm running the code in kaggle notebook.

from l5kit.

cvramanan avatar cvramanan commented on August 11, 2024

The order of parameters has been changed in the draw_trajectory method.

Updated prams order :

def draw_trajectory(
on_image: np.ndarray,
positions: np.ndarray,
rgb_color: Tuple[int, int, int],
radius: int = 1,
yaws: Optional[np.ndarray] = None,
)

This worked for me
draw_trajectory(image, positions_pixels, (255, 0, 255),1,data["target_yaws"])

from l5kit.

lucabergamini avatar lucabergamini commented on August 11, 2024

I don't know why but since few days/weeks function draw_trajectory does not correctly visualise vehicle targets.

I think this is an issue with coordinates frames, which version of l5kit are you using? Can you post here your trajectory visualisation code?

from l5kit.

lucabergamini avatar lucabergamini commented on August 11, 2024

I'll close this for now, let me know if you're still experiencing the issue though.

from l5kit.

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.