Skip to main content

Analyze a golf swing looking at critical points.

Project description

Introdction

This package provides a utility for analyzing a golf swing. The input data is represented as a json file generated by GolfTracker.

The scripts in this package simply analze the data and meausre the various metrics associated with the swing.

Json File Format

An example json file is present in the data folder. It has the following entries. | Class | Attribute | Type | Description | |------------------|----------------|----------------------|------------------------------------| | | GolfData | video_spec | VideoSpec | The video specifications. | | | video_input | VideoInput | Information about the video input. | | | num_frames | int | The number of frames in the video analysis. | | | pose_result | PoseResult | The result of the pose analysis. | | | club_head_result | ClubHeadResult | Results of the club head analysis. | | | mp_result | List[List[float]] | Multi-dimensional list representing additional analysis results. |

Each of the child dict definitons are below.

Class Attribute Type Description
VideoSpec height int The height of the video in pixels.
width int The width of the video in pixels.
num_frames int The number of frames in the video.
fps int The frames per second rate of the video.
scale int The scale factor used for the video.
rotate str The rotation setting for the video, if any.
VideoInput fname str The file name of the video.
size int The size of the video file in bytes.
PoseResult poses List[str] A list of identified poses.
handed str Information on whether the subject is left or right-handed, or 'Unknown'.
ClubHeadResult norm_points List[List[float]] Normalized points representing the position of the club head.
algos List[str] List of algorithms used for analyzing the club

Installation

Installs as a standard python package using PIP.

pip install golftrainer

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

golftrainer-0.0.2-py3-none-any.whl (4.4 kB view hashes)

Uploaded Python 3

Supported by

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