LASA Handwriting dataset loader and other tools for Python.
Project description
PyLasaDataset
LASA Handwriting dataset loader and other tools for Python 2 and Python 3.
Installation
Via pip
python3 -m pip install pylasadataset
Or
python3 -m pip install git+https://github.com/justagist/pylasadataset
Manual Install
- Dependencies:
apt install python-tk
;pip install numpy scipy matplotlib
. - Run
python setup.py install
.
Usage
import pyLasaDataset as lasa
# DataSet object has all the LASA handwriting data files
# as attributes, eg:
angle_data = lasa.DataSet.Angle
sine_data = lasa.DataSet.Sine
# Each Data object has attributes dt and demos (For documentation,
# refer original dataset repo:
# https://bitbucket.org/khansari/lasahandwritingdataset/src/master/Readme.txt)
dt = angle_data.dt
demos = angle_data.demos # list of 7 Demo objects, each corresponding to a
# repetition of the pattern
# Each Demo object in demos list will have attributes pos, t, vel, acc
# corresponding to the original .mat format described in
# https://bitbucket.org/khansari/lasahandwritingdataset/src/master/Readme.txt
demo_0 = demos[0]
pos = demo_0.pos # np.ndarray, shape: (2,2000)
vel = demo_0.vel # np.ndarray, shape: (2,2000)
acc = demo_0.acc # np.ndarray, shape: (2,2000)
t = demo_0.t # np.ndarray, shape: (1,2000)
# To visualise the data (2D position and velocity) use the plot_model utility
lasa.utilities.plot_model(lasa.DataSet.BendedLine) # give any of the available
# pattern data as argument
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pyLasaDataset-0.1.1.tar.gz
(10.7 MB
view hashes)
Built Distribution
Close
Hashes for pyLasaDataset-0.1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2d47245bb788c7a31bbf307830893451271b6c1f2dbe92ff800214dc0865db25 |
|
MD5 | fe548aa6a32a67b32817e5d2fedf69c8 |
|
BLAKE2b-256 | 6dca66fa27a360b04e42836781dd20cadb612e1e4b81a417e3b7a3ebdb390373 |