Git Product home page Git Product logo

bird_processing's Introduction

bird processing

This repo has code for processing the bird data, in particular handling the compressed HEVC/mp4 files.

pytorch video loader

The SynchronizedVideoLoader class lets you recover synchronized data from an unsynchronized video stream. But first you need to get the video into shape:

bag_file=full_path_to_my_bag_file.bag
video_dir=full_path_to_my_target_video_directory
roslaunch ffmpeg_image_transport_tools split_bag.launch	bag:=$bag_file out_file_base:=$video_dir/video_ write_time_stamps:=true convert_to_mp4:=true

Running this should produce 8 videos in the video output directory, along with time stamp files that map frame numbers to ROS time stamps.

Once you have the files in place, you can use a SynchronizedVideoLoader to access it in pytorch format:

loader = SynchronizedVideoLoader(file_root_dir, crop_size)

for i, inputs in enumerate(loader):
    frame_0 = inputs[0]
    print(i, 'size: ', frame_0['data'].shape, frame_0['time'])

There is a little demo program you can check out:

./src/test_bird_video_loading.py -r $video_dir

projecting points

In the src directory there is the demo code projector.py that projects 3d points into cameras. It needs the calibration.yaml file that is produced during extrinsic calibration

bird_processing's People

Contributors

berndpfrommer avatar

Watchers

James Cloos avatar Kenneth Chaney avatar Alex Zhu avatar  avatar  avatar

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.