Skip to main content

LASA Handwriting dataset for Python3

Project description

pyLASAHandwritingDataset

Ruff

LASA Handwriting dataset for Python3

This package provides a typed, lightweight Python interface for loading and accessing the dataset.

Installation

Install the package from PyPI:

# Using uv
uv add pylasahandwritingdataset

# Or with pip
pip3 install pylasahandwritingdataset

To install from the latest commit:

uv add git+https://github.com/AshrithSagar/pyLASAHandwritingDataset.git@main

Usage

import pyLASAHandwritingDataset as lasa

# List available motions
motions = lasa.DataSet.handwriting_motions()
print(motions)  # ('Angle', 'BendedLine', 'CShape', 'DoubleBendedLine', 'GShape', 'JShape', 'JShape_2', 'Khamesh', 'LShape', 'Leaf_1', 'Leaf_2', 'Line', 'Multi_Models_1', 'Multi_Models_2', 'Multi_Models_3', 'Multi_Models_4', 'NShape', 'PShape', 'RShape', 'Saeghe', 'Sharpc', 'Sine', 'Snake', 'Spoon', 'Sshape', 'Trapezoid', 'WShape', 'Worm', 'Zshape', 'heee')

# Load a motion pattern
pattern = lasa.DataSet["GShape"]
print(pattern.name)  # "GShape"
print(pattern.dt)
print(len(pattern.demos))  # 7

# Access demonstrations
demo = pattern.demos[0]
t   = demo.t    # shape (1, 1000)
pos = demo.pos  # shape (2, 1000)
vel = demo.vel  # shape (2, 1000)
acc = demo.acc  # shape (2, 1000)

# For typing specification, the motion names are also available in
from pyLASAHandwritingDataset import (
    HandwritingMotion,  # Any handwriting motion: single pattern or multi-model
    SinglePatternMotion,  # Any single pattern handwriting motion
    MultiModelMotion,  # Any multi-model handwriting motion
    #
    ALL_HANDWRITING_MOTIONS,  # A tuple of all handwriting motions
    ALL_SINGLE_PATTERN_MOTIONS,  # A tuple of all single pattern handwriting motions
    ALL_MULTI_MODEL_MOTIONS,  # A tuple of all multi-model handwriting motions
    #
    is_handwriting_motion,  # A TypeGuard to check whether a `str` is a handwriting motion
)

For documentation, refer to the original dataset repo's README.

References

Acknowledgement

If you use this dataset in research, please cite the original author:

S. M. Khansari-Zadeh and A. Billard, "Learning Stable Non-Linear Dynamical
Systems with Gaussian Mixture Models", IEEE Transaction on Robotics, 2011.

License

The LASA Handwriting Dataset is free for non-commercial academic use.

Please refer to the original dataset repository for licensing details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pylasahandwritingdataset-0.1.3.tar.gz (81.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pylasahandwritingdataset-0.1.3-py3-none-any.whl (7.4 kB view details)

Uploaded Python 3

File details

Details for the file pylasahandwritingdataset-0.1.3.tar.gz.

File metadata

  • Download URL: pylasahandwritingdataset-0.1.3.tar.gz
  • Upload date:
  • Size: 81.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.4 {"installer":{"name":"uv","version":"0.10.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for pylasahandwritingdataset-0.1.3.tar.gz
Algorithm Hash digest
SHA256 f7f1dc60f7a9d623deef9c06dc7fec08c5897a93fb6918aaa19b46ba7ed5ffc4
MD5 9d0c84f12bfd0a5d10de13536ef80e44
BLAKE2b-256 1f389878d23cccc70bcda8ebfc1b06e427b9234f984022e51540567dd83dffcb

See more details on using hashes here.

File details

Details for the file pylasahandwritingdataset-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: pylasahandwritingdataset-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 7.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.4 {"installer":{"name":"uv","version":"0.10.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for pylasahandwritingdataset-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 e157b1b6e031afa9cff98ef205953dfe28a46434a3f5c9697112ae7dcc4f3d30
MD5 473baacd78ea4bb882a3b02ba8676ca6
BLAKE2b-256 2abcc99b557a2e7c67962fcae550cfdb3103100b09d5a289e2dc369c1d64b383

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page