{ "info": { "author": "Michael de Gans", "author_email": "", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Intended Audience :: Developers", "Intended Audience :: End Users/Desktop", "License :: OSI Approved :: MIT License", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.8", "Topic :: Scientific/Engineering :: Artificial Intelligence", "Topic :: Scientific/Engineering :: Image Recognition" ], "description": "# JetStreamer\nJetStreamer is a command line utility* to record frames and perform inferences \nfrom a camera on NVIDIA Tegra. It uses the Jetson Inference library which is\ncomprised of utilities and wrappers around lower level NVIDIA inference \nlibraries.\n\n*display support is planned\n\n## Requirements\nThe only requirement for installation is the\n[Jetson Inference repository](https://github.com/dusty-nv/jetson-inference.git).\n\nTo build and install Jetson Inference on your Tegra device, run these commands\non the device itself or via ssh:\n\n```shell\nsudo apt install git cmake python3-dev\ncd ~\ngit clone https://github.com/dusty-nv/jetson-inference.git\ncd jetson-inference\ngit submodule update --init\nmkdir build\ncd build\ncmake -DCMAKE_INSTALL_PREFIX=~/.local ..\nmake -j4 && sudo make install\n```\n\n**warning: do not delete the jetson-inference folder** since there is a \nsymlink from /usr/local/bin/networks to jetson-inference/data/networks\n \n**Optional fix for above warning if you're the paranoid/perfectionist type**:\n\nInstead it's recommended to run the app with the networks you want *first* to \ngenerate the optimized networks, *then* copy them over, and *then* delete the \nbuild folder. After you've the run the app as your build user and see something\nlike this for **each of the networks you need**...\n```\n[TRT] device GPU, completed writing engine cache to /usr/local/bin/networks/ped-100/snapshot_iter_70800.caffemodel.1.1.GPU.FP16.engine\n```\n...perform the following steps to copy the files over as root so that they're\nboth immutable to and accessable to all users (eg, a system user running \njetstreamer as a daemon)\n```\nsudo rm /usr/local/bin/networks\nsudo cp -r ~/jetson-inference/data/networks /usr/local/bin\nrm -rf ~/jetson-inference\n```\n\n## installation\n(on your tegra device)\n```shell\npip3 install jetstreamer\n```\n\n**Warning**: don't **ever** run pip with sudo. If an app requests you do this,\nuninstall it **immediately**, even if you're not the paranoid type.\n\nPypi if **full** of malware (docker hub and npm are worse) and even a well \nintentioned author might include a malicious package. Installing it or running \nit as your root user could compromise your Tegra device, potentially leading to \na compromise of your entire network.\n\n## Usage\nSimply run `jetstreamer` after installation.\n\n```\nusage: __main__.py [-h] [--camera CAMERA] [--width WIDTH] [--height HEIGHT]\n [--interval INTERVAL] [--classify CLASSIFY]\n [--detect DETECT] [--detect-threshold DETECT_THRESHOLD]\n [--format {jpg,png}]\n base_filename\n\nClassify, Detect, or simply save frames from camera using Jetson Inference and Jetson Utils. \n\nPress Ctrl+C or send SIGINT to stop.\n\nexamples: \n jetstreamer --classify googlenet outfilename\n jetstreamer --detect pednet outfilename\n jetstreamer --detect pednet --classify googlenet outfilename\n\npositional arguments:\n base_filename base filename for images and sidecar files\n\noptional arguments:\n -h, --help show this help message and exit\n --camera CAMERA v4l2 device (eg. /dev/video0) or '0' for CSI camera (default: 0)\n --width WIDTH camera capture width (default: 720)\n --height HEIGHT camera capture height (default: 480)\n --interval INTERVAL interval between captures in seconds as float, fraction, or integer. Default is to capture as fast as the gstCamera will allow (currently 30fps) and thepipeline can process. (default: None)\n --classify CLASSIFY classification network to use (default: None)\n --detect DETECT detection network to use (default: None)\n --detect-threshold DETECT_THRESHOLD\n detectNet threshold (default: 0.5)\n --format {jpg,png} format to save image sequence in (jpg is probably fastest) (default: jpg)\n```\n\n## Uninstallation\n```shell\npip3 uninstall jetstreamer\n```\n\n## FAQ\n- **What is the .nfo file for**? The nfo file stores the parameters used to \nlaunch main() so you know what network, for example, is associated with a given\ncapture sequence. This lets you look up the description for class ids without\nhaving to store long string and in future versions will allow loading from it\nso cid -> class description associations can be made automatically.\n\n- **what is the .jsonl file for** The .jsonl file is a \n[json lines file format](http://jsonlines.org/).\nEach line is json containing the frame number and any assocaited metadata.\n\n## Use as a library:\nThis is not recommended as the API will likely change, but docstrings are\nincluded for every function and pipeline element with the exception of main()\nfor which one may refer to the above usage.\n\n- **How do I split the pipeline?**\n[itertools.tee](https://docs.python.org/3/library/itertools.html#itertools.tee)\nwill likely do the job. Display sink support is planned using this. Really, \nitertools is the python module you want when dealing with iterators/generators.\n\n- **How do I write my own sink**\nYou need something that consumes from a generator/iterator. Looping over it or\ncalling next(source), where source is your generator, will pull frames through\nthe pipeline.\n\n- **Is a file source planned**\nYes. You will be able to feed it an Iterable of filenames. Also planned is a\nsource generator with a send method so you push filenames into the source on\ndemand.\n\n- **Are copies of the data being made as it's passed down the pipeline and into\nC functions?**\nNo. The image is passed back and forth through C in a PyCapsule container which\nactually contains a pointer to the image in shared CPU/GPU memory and not the \nimage itself. No copies are made.\n\n- **Will you add support for network streaming**? Possibly, if there is enough \ninterest.", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "jetstreamer", "package_url": "https://pypi.org/project/jetstreamer/", "platform": "", "project_url": "https://pypi.org/project/jetstreamer/", "project_urls": { "Bug Reports": "https://github.com/mdegans/jetstreamer/issues", "Source": "https://github.com/mdegans/jetstreamer/" }, "release_url": "https://pypi.org/project/jetstreamer/0.0.3/", "requires_dist": null, "requires_python": ">=3.6", "summary": "Image and inference metadata recording utility for NVIDIA Tegra", "version": "0.0.3" }, "last_serial": 5745943, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "9e8390bbfeec0e5a940598068cd685d6", "sha256": "3b6c2b38fe6fe82257200335f3741da02972c2865fca1c9b21288634e3fc1c4a" }, "downloads": -1, "filename": "jetstreamer-0.0.1.tar.gz", "has_sig": false, "md5_digest": "9e8390bbfeec0e5a940598068cd685d6", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 7184, "upload_time": "2019-08-28T04:13:39", "url": "https://files.pythonhosted.org/packages/10/8c/61387da47523f53ddaf9819977eba1644b65d0382c741943639a8180d62c/jetstreamer-0.0.1.tar.gz" } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "f0b9afc18e879b71f60b8d26ff5d5266", "sha256": "045263cbc539644bd724e88e63863d8d24475f23c93ddea7be32aa9dee19c0da" }, "downloads": -1, "filename": "jetstreamer-0.0.3.tar.gz", "has_sig": false, "md5_digest": "f0b9afc18e879b71f60b8d26ff5d5266", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 7788, "upload_time": "2019-08-28T21:25:59", "url": "https://files.pythonhosted.org/packages/2b/b8/86c9dfbbe7646f313e4cfdafa0e9de34c9cf5490d487dc0e7ee88e2f22c8/jetstreamer-0.0.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "f0b9afc18e879b71f60b8d26ff5d5266", "sha256": "045263cbc539644bd724e88e63863d8d24475f23c93ddea7be32aa9dee19c0da" }, "downloads": -1, "filename": "jetstreamer-0.0.3.tar.gz", "has_sig": false, "md5_digest": "f0b9afc18e879b71f60b8d26ff5d5266", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 7788, "upload_time": "2019-08-28T21:25:59", "url": "https://files.pythonhosted.org/packages/2b/b8/86c9dfbbe7646f313e4cfdafa0e9de34c9cf5490d487dc0e7ee88e2f22c8/jetstreamer-0.0.3.tar.gz" } ] }