Commandline Image Uploader for KartaView
Project description
Commandline tools to upload discrete images to KartaView.
Also supports Vantrue OnDash X4S videos.
Usage
Install:
pip3 install kartaview-tools
Authorize: This step is needed only once. You need an OSM account.
kv_auth
Your KartaView credentials are now stored in the file
~/.config/kartaview/credentials.json
. Keep this file secret. The KartaView credentials do not expire, but you can delete the credentials file, in which case you must authorize again.Sequence the images:
kv_sequence ~/Pictures/kartaview/*.jpg
This step sorts your images into sequences. It extracts the GPS data from your images and stores it in sidecar files, where you can easily review it.
Upload the images:
kv_upload ~/Pictures/kartaview/*.jpg
The script remembers which images were successfully uploaded. In case of errors, if you run the upload script on the same images again, the ones already uploaded will not be uploaded again.
Run the scripts with ‘-h’ to see more options.
Videos
This software only supports videos produced by the Vantrue OnDas X4S dashcam.
To split a video file into discrete images use ffmpeg.
Proposed workflow:
mkdir -p /tmp/frames
# extract I-frames for better clarity
ffmpeg -skip_frame nointra -i ~/Videos/dash.mp4 -vsync 0 -frame_pts 1 /tmp/frames/%08d.jpg
# patch GPS data into image files
kv_vantrue_x4s -i ~/Videos/dash.mp4 /tmp/frames/%08d.jpg
# sequence image files
kv_sequence /tmp/frames/%08d.jpg
# upload files
kv_upload /tmp/frames/%08d.jpg
See:
https://trac.ffmpeg.org/wiki/Create%20a%20thumbnail%20image%20every%20X%20seconds%20of%20the%20video
GPX Files
You can extract the GPS data in your video into a GPX file and then use third-party tools (eg. exiftool) to further process it.
Proposed workflow:
kv_vantrue_x4s -i ~/Videos/dash.mp4 --gpx=track.gpx
exiftool -geotag=track.gpx /tmp/frames
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
Built Distribution
File details
Details for the file kartaview-tools-0.0.2.tar.gz
.
File metadata
- Download URL: kartaview-tools-0.0.2.tar.gz
- Upload date:
- Size: 36.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0ca02aace1759ab3f1ce9a1694f8b07ea92bfe82e6c49b4f0adc1a180ca97ee4 |
|
MD5 | 5641f916db0e5cab2a7232def39ca819 |
|
BLAKE2b-256 | 4a0bc6bdccb11fa1d8b5756ce38c218d3a6716517f3bf1f9634a0d9cbdb6bcfb |
File details
Details for the file kartaview_tools-0.0.2-py3-none-any.whl
.
File metadata
- Download URL: kartaview_tools-0.0.2-py3-none-any.whl
- Upload date:
- Size: 40.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 29e99ce6ac9bd1ed5ef6c160a47a294a694f0e85a631f3c8101bd57cb0d091e0 |
|
MD5 | 74c475e6852b1fd1d84622b81f9a9d42 |
|
BLAKE2b-256 | d356944a71ed31d7c50bf76107dacfa274e919c7f812c2dc5b5ffec94d4fe552 |