pyronear / pyronear/pyro-envdev
[Python script] Create fake alerts thourgh the API
Nobody has claimed this yet.
- Dominant language
- Jupyter Notebook
- Stars
- 1
- Forks
- 3
- PR merge metrics
- No merged PRs in 30d
Description
Current Behavior
The only alerts created for development purpose are created by the false cameras (you can check cameras' behavior here : https://github.com/pyronear/pyro-envdev/issues/10).
But the the timestamp of the alerts are set by the engine which means :
- we cannot create alerts in the past
- all the alerts will be attached to the same Sequence object in the API database (which means a Wildfire) because we need to have a pause of 30min between two alerts in order to create a new Sequence.
Wanted Behavior
We would like to be able to create Detections with a python script, using the /detections/ POST endpoint of the dev env API (documentation here)
In order to link the detections to an existing cameras you will have to generate a token thankts to the endpoint /cameras/{camera_id}/token. For that you can hardcode camera_id=1 for the static camera and camera_id=2 for the ptz camera.
- No need to containerized the script, you can use the localhost:5050 url.
- You can use these images saved in a new directory
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No repository file or test is named. Start with the linked /detections/ POST documentation and the /cameras/{camera_id}/token endpoint, using localhost:5050 and camera IDs 1 and 2. Done means a Python script uses the release images to create detections with controllable past timestamps and associates them with the existing cameras.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100