npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

datasetviewer

v0.1.6

Published

组件提供画线条、多边形、像素混合功能和例子。 基本涵盖常见算法输出的数据。

Downloads

4

Readme

dataset-viewer

组件提供画线条、多边形、像素混合功能和例子。 基本涵盖常见算法输出的数据。

在线demo

Installation

yarn add datasetviewer

Documentation

Usage

  import DatasetViewer from 'datasetviewer'

  const config:DatasetViewerConfig = {...}

  const viewer = new DatasetViewer(config)

  viewer.init()

调用例子代码调用例子代码调用例子代码调用例子代码调用例子代码调用例子代码

DatasetViewerConfig

| name | type | descriptions | | --- | --- | --- | | canvasInstance | HTMLCanvasElement | canvas标签,ref | | url | string | 展示图片地址 | | data | Array | canvas绘画的每一项数据 | | opreationsConfig | OpreationsConfig | 能否缩放拖动的控制 | | isDraw | boolean | 控制是否绘画数据 |

DataItem

| name | type | descriptions | | --- | --- | --- | | type | CustomRect | polyline | CustomPolygon | 更多请查看fabric | 必填项,这是画布应该用什么工具处理数据的前提 | | label | string | 标签名 | | points | Array<{x:number, y:number}> | 多边形或者折线的坐标点 | | stroke | string | 颜色 | | fill | string | 颜色 | | rectData | [x,y,w,h] | 起点坐标,宽高 | | drawPoint | boolean | 是否需要画点 |

OpreationsConfig

| name | type | descriptions | | --- | --- | --- | | zoom | boolean | 是否缩放 |


数据转换例子

注意:如果项目比较注重性能,请注意源数据的精度,最好把浮点数去掉

简单来说,检测就是画框。单目3D也是画框,不过是多个不规则多边形的组合。 姿态检测类型的就是线段、或者折线的绘画。

分割比较特殊,需要看算法怎么输出mask数据类型。一般是用像素存储数据,看你们怎么规定约束条件。用canvas像素diff数据,混合就行。(最简单的混合就是srgb+颜色/2完事)。这一块和这个绘图组件无关,更多的是canvas操作数据问题

分类可以忽略,直接绝对定位一个标签就行。

car_pose_detection (单目3d同理)

detection (简单的画框)

pose_detection

通用分割