Skip to content

kaiopen/tab_kit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

The TAB Toolkit

中文版

A toolkit for reading, visualizing the TAB, a travelable area boundary dataset, and evaluating the detectors.

Python Environment

Installation

Run the following command in the tab_kit/:

pip install .

Usage

  1. Read the TAB.
from kaitorch.pcd import PointCloudXYZIR
from tab import TAB


tab = TAB('path/to/TAB', 'train')

# Iterate the TAB frame by frame.
for f in tab:
    # Read the point cloud.
    pcd: PointCloudXYZIR = tab.get_pcd(f)

    # Clip the point cloud.
    # It is not needed to do so because the point cloud has already been clipped before.
    pcd = TAB.filter_pcd_(pcd)

    print(pcd.xyz)
    print(pcd.i)
    print(pcd.r)

    # Read labels.
    bounds = tab.get_bound(f)
    for bound in bounds:
        print(bound.keys())

More examples are available.

  1. Do visualization.
from tab import BEV, TAB, Visualizer


vis = Visualizer(
    BEV(mode=BEV.Mode.CONSTANT),
    width=2,
    save=True,
    dst='results'
)

tab = TAB('path/to/TAB', 'train')

for f in tqdm(tab):
    vis(f.seq, f.id, tab.get_pcd(f), tab.get_bound(f))

More examples are available.

  1. Do evaluation.
from tab import Evaluator


evaluator = Evaluator('path/to/TAB', 'test')

# Get prediction results.
# preds = ...

print(Evaluator.tabulate(*evaluator(preds)))

The example in detail is ./test/eval.py. More examples are available.

About

A toolkit for the TAB.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages