Pyrovision
Computer vision library for wildfire detection.
https://github.com/pyronear/pyro-vision
Category: Biosphere
Sub Category: Wildfire
Keywords
computer-vision deep-learning image-classification keypoint-detection object-detection onnx python pytorch wildfire
Keywords from Contributors
measur transforms archiving projection animals compose observation conversion optimize generic
Last synced: about 1 hour ago
JSON representation
Repository metadata
Computer vision library for wildfire detection 🌲 Deep learning models in PyTorch & ONNX for inference on edge devices (e.g. Raspberry Pi)
- Host: GitHub
- URL: https://github.com/pyronear/pyro-vision
- Owner: pyronear
- License: apache-2.0
- Created: 2019-09-08T13:15:41.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2024-04-12T00:53:18.000Z (about 1 year ago)
- Last Synced: 2025-04-17T06:49:48.732Z (10 days ago)
- Topics: computer-vision, deep-learning, image-classification, keypoint-detection, object-detection, onnx, python, pytorch, wildfire
- Language: Python
- Homepage: https://pyronear.org/pyro-vision/
- Size: 7.66 MB
- Stars: 58
- Watchers: 9
- Forks: 24
- Open Issues: 10
- Releases: 4
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
README.md
Pyrovision: wildfire early detection
The increasing adoption of mobile phones have significantly shortened the time required for firefighting agents to be alerted of a starting wildfire. In less dense areas, limiting and minimizing this duration remains critical to preserve forest areas.
Pyrovision aims at providing the means to create a wildfire early detection system with state-of-the-art performances at minimal deployment costs.
Quick Tour
Automatic wildfire detection in PyTorch
You can use the library like any other python package to detect wildfires as follows:
from pyrovision.models import rexnet1_0x
from torchvision import transforms
import torch
from PIL import Image
# Init
normalize = transforms.Normalize(mean=[0.485, 0.456, 0.406], std=[0.229, 0.224, 0.225])
tf = transforms.Compose([transforms.Resize(size=(448)), transforms.CenterCrop(size=448),
transforms.ToTensor(), normalize])
model = rexnet1_0x(pretrained=True).eval()
# Predict
im = tf(Image.open("path/to/your/image.jpg").convert('RGB'))
with torch.no_grad():
pred = model(im.unsqueeze(0))
is_wildfire = torch.sigmoid(pred).item() >= 0.5
Setup
Python 3.6 (or higher) and pip/conda are required to install PyroVision.
Stable release
You can install the last stable release of the package using pypi as follows:
pip install pyrovision
or using conda:
conda install -c pyronear pyrovision
Developer installation
Alternatively, if you wish to use the latest features of the project that haven't made their way to a release yet, you can install the package from source:
git clone https://github.com/pyronear/pyro-vision.git
pip install -e pyro-vision/.
What else
Documentation
The full package documentation is available here for detailed specifications.
Demo app
The project includes a minimal demo app using Gradio
You can check the live demo, hosted on 🤗 HuggingFace Spaces 🤗 over here 👇
Docker container
If you wish to deploy containerized environments, a Dockerfile is provided for you build a docker image:
docker build . -t <YOUR_IMAGE_TAG>
Minimal API template
Looking for a boilerplate to deploy a model from PyroVision with a REST API? Thanks to the wonderful FastAPI framework, you can do this easily. Follow the instructions in ./api
to get your own API running!
Reference scripts
If you wish to train models on your own, we provide training scripts for multiple tasks!
Please refer to the ./references
folder if that's the case.
Citation
If you wish to cite this project, feel free to use this BibTeX reference:
@misc{pyrovision2019,
title={Pyrovision: wildfire early detection},
author={Pyronear contributors},
year={2019},
month={October},
publisher = {GitHub},
howpublished = {\url{https://github.com/pyronear/pyro-vision}}
}
Contributing
Please refer to CONTRIBUTING
to help grow this project!
License
Distributed under the Apache 2 License. See LICENSE
for more information.
Owner metadata
- Name: PyroNear
- Login: pyronear
- Email:
- Kind: organization
- Description: Preserving forests from wildfires one commit at a time
- Website: https://pyronear.org/
- Location: Paris
- Twitter: pyro_near
- Company:
- Icon url: https://avatars.githubusercontent.com/u/61667887?v=4
- Repositories: 23
- Last ynced at: 2024-10-30T02:43:17.535Z
- Profile URL: https://github.com/pyronear
GitHub Events
Total
- Watch event: 8
Last Year
- Watch event: 8
Committers metadata
Last synced: 6 days ago
Total Commits: 140
Total Committers: 10
Avg Commits per committer: 14.0
Development Distribution Score (DDS): 0.457
Commits in past year: 6
Committers in past year: 2
Avg Commits per committer in past year: 3.0
Development Distribution Score (DDS) in past year: 0.5
Name | Commits | |
---|---|---|
F-G Fernandez | f****3@h****r | 76 |
x0s | g****a@g****m | 29 |
lostanlen | m****n@g****m | 20 |
dependabot[bot] | 4****] | 6 |
blenzi | B****i@c****h | 4 |
Akidlitu | 5****u | 1 |
Ankit Dobhal | d****t@p****m | 1 |
Nidham Tekaya | 6****m | 1 |
Serhii Kupriienko | 7****a | 1 |
fe51 | 5****1 | 1 |
Committer domains:
- cern.ch: 1
Issue and Pull Request metadata
Last synced: 1 day ago
Total issues: 46
Total pull requests: 140
Average time to close issues: 5 months
Average time to close pull requests: 26 days
Total issue authors: 9
Total pull request authors: 10
Average comments per issue: 1.63
Average comments per pull request: 1.85
Merged pull request: 116
Bot issues: 0
Bot pull requests: 14
Past year issues: 0
Past year pull requests: 0
Past year average time to close issues: N/A
Past year average time to close pull requests: N/A
Past year issue authors: 0
Past year pull request authors: 0
Past year average comments per issue: 0
Past year average comments per pull request: 0
Past year merged pull request: 0
Past year bot issues: 0
Past year bot pull requests: 0
Top Issue Authors
- frgfm (27)
- MateoLostanlen (9)
- blenzi (3)
- Akilditu (2)
- x0s (1)
- TekayaNidham (1)
- alizeeeeeee (1)
- KevinJMcEntee (1)
- fe51 (1)
Top Pull Request Authors
- frgfm (74)
- MateoLostanlen (31)
- dependabot[bot] (14)
- x0s (8)
- blenzi (5)
- Akilditu (2)
- powerexploit (2)
- fe51 (2)
- TekayaNidham (1)
- skupr-anaconda (1)
Top Issue Labels
- help wanted (17)
- type: enhancement (13)
- module: datasets (12)
- module: models (11)
- type: bug (10)
- ext: references (6)
- ext: tests (5)
- wontfix (4)
- topic: build (3)
- topic: documentation (3)
- invalid (2)
- question (2)
- module: utils (1)
- ext: demo (1)
Top Pull Request Labels
- type: enhancement (48)
- topic: documentation (37)
- topic: build (37)
- module: datasets (31)
- type: bug (22)
- ext: api (17)
- ext: tests (16)
- ext: references (15)
- dependencies (14)
- module: models (13)
- topic: ci (13)
- type: new feature (10)
- ext: docs (6)
- type: code quality (5)
- module: utils (5)
- module: nn (3)
- ext: scripts (3)
- topic: docker (2)
- type: breaking change (2)
- ext: demo (2)
- invalid (1)
- question (1)
- type: misc (1)
Package metadata
- Total packages: 1
-
Total downloads:
- pypi: 142 last-month
- Total dependent packages: 0
- Total dependent repositories: 1
- Total versions: 3
- Total maintainers: 1
pypi.org: pyrovision
Datasets and models for wildfire detection in PyTorch
- Homepage:
- Documentation: https://pyrovision.readthedocs.io/
- Licenses: Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
- Latest release: 0.2.0 (published almost 3 years ago)
- Last Synced: 2025-04-26T14:01:54.235Z (1 day ago)
- Versions: 3
- Dependent Packages: 0
- Dependent Repositories: 1
- Downloads: 142 Last month
-
Rankings:
- Dependent packages count: 10.095%
- Dependent repos count: 21.615%
- Average: 23.637%
- Downloads: 39.2%
- Maintainers (1)
Dependencies
- actions/cache v2 composite
- actions/checkout v2 composite
- actions/setup-python v2 composite
- actions/setup-python v1 composite
- abatilo/actions-poetry v2.0.0 composite
- actions/checkout v2 composite
- actions/setup-python v2 composite
- JamesIves/github-pages-deploy-action 3.7.1 composite
- actions/cache v2 composite
- actions/checkout v2 composite
- actions/setup-python v2 composite
- webfactory/ssh-agent v0.4.1 composite
- actions/checkout master composite
- gaurav-nelson/github-action-markdown-link-check master composite
- actions/cache v2 composite
- actions/checkout v2 composite
- actions/labeler v4 composite
- actions/setup-python v2 composite
- actions/cache v2 composite
- actions/checkout v2 composite
- actions/setup-python v2 composite
- conda-incubator/setup-miniconda v2 composite
- docker/build-push-action v1 composite
- actions/checkout v2 composite
- actions/setup-python v1 composite
- actions/cache v2 composite
- actions/checkout v2 composite
- actions/setup-python v2 composite
- actions/cache v2 composite
- actions/checkout v2 composite
- actions/download-artifact v2 composite
- actions/setup-python v1 composite
- actions/upload-artifact v2 composite
- codecov/codecov-action v1 composite
- frgfm/validate-python-headers main composite
- python 3.8.1-slim build
- tiangolo/uvicorn-gunicorn-fastapi python3.8-slim build
- anyio 3.6.1
- atomicwrites 1.4.1
- attrs 21.4.0
- certifi 2023.7.22
- charset-normalizer 2.1.0
- click 8.1.3
- colorama 0.4.5
- fastapi 0.78.0
- filelock 3.7.1
- flatbuffers 2.0
- h11 0.12.0
- httpcore 0.15.0
- httpx 0.23.0
- huggingface-hub 0.8.1
- idna 3.3
- iniconfig 1.1.1
- numpy 1.23.1
- onnxruntime 1.11.1
- packaging 21.3
- pillow 9.3.0
- pluggy 1.0.0
- protobuf 4.21.6
- py 1.11.0
- pydantic 1.9.1
- pyparsing 3.0.9
- pytest 7.1.2
- pytest-asyncio 0.18.3
- python-multipart 0.0.5
- pyyaml 6.0
- requests 2.31.0
- rfc3986 1.5.0
- six 1.16.0
- sniffio 1.2.0
- starlette 0.19.1
- tomli 2.0.1
- tqdm 4.64.0
- typing-extensions 4.3.0
- urllib3 1.26.10
- uvicorn 0.18.2
- httpx >=0.23.0 develop
- pytest >=5.3.2,<8.0.0 develop
- pytest-asyncio >=0.14.0,<1.0.0 develop
- requests ^2.31.0 develop
- Pillow >=8.4.0
- fastapi >=0.65.2,<1.0.0
- huggingface-hub >=0.4.0,<1.0.0
- numpy ^1.19.5
- onnxruntime ^1.10.0
- python ^3.8
- python-multipart ==0.0.5
- uvicorn >=0.11.1
- Pillow >=8.4.0
- gradio >=3.0.2,<4.0.0
- huggingface-hub >=0.4.0,<1.0.0
- numpy >=1.19.5,<2.0.0
- onnxruntime >=1.10.0,<2.0.0
- huggingface-hub >=0.4.0
- pylocron >=0.2.1,<1.0.0
- requests >=2.20.0,<3.0.0
- torch >=1.11.0,<2.0.0
- torchvision >=0.12.0,<1.0.0
- tqdm >=4.1.0
Score: 11.491906097746153