Commit Graph

159 Commits

Author SHA1 Message Date
Matt
4068025572 Check all new prop names not just exposure time (#1080)
Fixes v4l renaming prop names and OV9281 exposure min/max being wrong by introducing new UI control
2024-01-05 23:40:06 -05:00
Matt
0af5a62d5e Use mrcal for camera-calibration (#1036)
Uses jars built from https://github.com/photonvision/mrcal-java/
See: https://mrcal.secretsauce.net/ and https://docs.photonvision.org/en/latest/docs/calibration/calibration.html#investigating-calibration-data-with-mrcal

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2024-01-05 14:26:17 -05:00
Matt
b033f7e585 Publish API docs (#1094)
Redirects I want eventually ( @Bankst )

demo.photonvision.org redirected to https://photonvision.github.io/photonvision/built-client/
javadocs.photonvision.org redirected to https://photonvision.github.io/photonvision/built-docs/javadoc/
cppdocs.photonvision.org redirected to https://photonvision.github.io/photonvision/built-docs/doxygen/html/

For now this runs on all commits to master. Once we confirm it works, let's pull back to only tagged releases


---------

Co-authored-by: Mohammad Durrani <46766905+mdurrani808@users.noreply.github.com>
Co-authored-by: Chris <chrisgerth010592@gmail.com>
2024-01-05 14:14:22 -05:00
Matt
4f84f6e4f5 Fix getCalibrationCoeffs args in calibration info card 2024-01-03 15:23:39 -07:00
Matt
7f09f9e4f5 Save calibration data and show preliminary GUI (#1078)
* Serialize all calibration data

* Run lint

* typing nit

* fix code

* move these tables around some

* Add cool formatting

* add request to get snapshots by resolution and camera

* re-enable all resolutions

* add wip so i can change computers (SQUASH ME AND KILL ME AHHHH)

* Get everything working but viewing snapshots

* Update RequestHandler.java

* Update CameraCalibrationInfoCard.vue

* Update CameraCalibrationInfoCard.vue

* add observation viewer

* round

* fix illiegal import

* Swap to PNG and serialize insolution

* move import/export buttons TO THE TOP

* Update WebsocketDataTypes.ts

* Add snapshotname to observation

* Refactor to serialize snapshot image itself

* Run lint

* Use new base64 image data in info card

* Update SettingTypes.ts

* Create calibration json -> mrcal converter script

* Update calibrationUtils.py

* Fix calibrate NPEs in teest

* Run lint

* Always run cornersubpix

* Update CameraCalibrationInfoCard.vue

Update CameraCalibrationInfoCard.vue

* Update OpenCVHelp.java

* Update OpenCVHelp.java

* Replace test mode camera JSONs

* Run wpiformat

* Revert intrinsics but keep other data

* Remove misc comments

* Rename JsonMat->JsonImageMat and add calobject_warp

* Update Server.java

* Rename cameraExtrinsics to distCoeffs

* fix typing issues

* use util methods

* Formatting fixes

* fix styling

* move to devTools

* remove unneeded or unused imports

* Remove fixed-right css

If its really that big of a deal, we can add it back later, kind of a drag to fix rn.

* Create util method

* Remove extra legacy calibration things

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2024-01-03 16:32:04 -05:00
Sriman Achanta
e4f475a253 Improve UI stability, reliability, and readability (#1104)
closes #1090
closes #1030

Also fixes various styling issues and overflow issues for mobile support
2024-01-02 09:03:16 -07:00
Programmers3539
2a1792e71a Allow 90-deg rotation of USB cameras on Pi (#1103)
UI would say that every camera on a Pi device was a CSI camera basically. It would not let you rotate usb cameras 90 degrees or 270 degrees because it thought that they were CSI cameras. Fixes: #1098
2024-01-02 10:27:09 -05:00
Sriman Achanta
2ecd988628 Add protobuf publish setting slider (#1075)
Allows logging software and live data view to see results. Also removes the requirement for AScope to keep up with the packet serde schema and instead just use the Protobuf descriptor.
2023-12-31 00:14:21 -05:00
Matt
282e1bb47d Handle angle wrapping (#1061) 2023-12-28 12:40:50 -05:00
Matt
954ca9a577 Record standard deviations for multi-tag pose (#1019)
* Record standard deviations for multi-tag pose

* Add XYZ translation and angle to stdev uI

* create multitag result buffer in store

allows results to be stored in the background

* simplify logic in targeting tab

also adds a reset button

* Formatting fixes

* convert rad angles to deg

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2023-12-19 15:47:53 -05:00
Joseph Farkas
7b49570e9d Radians to Degrees for multi-tag pose (#1027)
* Radians to Degrees for multi-tag pose

* fix optional check

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2023-11-27 23:43:57 -05:00
Matt
16f63e4d90 Remove % from ambiguity (#1017)
* Remove % from ambiguity

* Update javadocs

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2023-11-25 14:06:22 -05:00
Sriman Achanta
5a9cf418d4 Fix bug with always opening stream fullscreen onclick (#1018)
* Update photon-camera-stream.vue

* formatting fixes
2023-11-21 22:15:08 -05:00
Sriman Achanta
9b183ebb85 Add option to view streams fullscreen (#1006)
closes #1005
2023-11-20 21:24:49 -05:00
Sriman Achanta
623b4e5b84 Show Saved Snapshots in UI (#995)
Add Camera Control tab to Cameras for the button to live in
2023-11-05 11:33:45 -05:00
Sriman Achanta
0898dfe2f7 Aruco/Multitag 36h11 support (#981)
- Aruco pipeline now infers tag width from tag family like the AprilTag pipeline
- Removes unused Aruco and 200mm AprilTag models
- `VisionEstimation.estimateCamPosePNP()` now requires a target model instead of assuming 16h5
  - Multitarget pipeline similarly infers target model of tag family now
  - `PhotonPoseEstimator` can have target model set for on-rio multitarget

---------

Co-authored-by: amquake <noleetarrr@gmail.com>
2023-10-29 23:02:16 -04:00
Matt
cb401e1c7a Add 36h11 tag model for 2024 (#951)
* Add 36h11 model

* Formatting fixes

* Match frontend TargetModel enum with backend

* fix target model merge

* Update TargetModel.java

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2023-10-24 23:04:52 -04:00
amquake
df45bc2d73 Re-enable OpenCV ArUco detector for AprilTags (#916)
- Fixes ArUco on picam
- Adds `ArucoPoseEstimatorPipe` for single-tag pose estimation
  - Previously, `Aruco.estimatePoseSingleMarkers()` was used for tag pose estimation. This uses the default `SOLVEPNP_ITERATIVE` solver and I believe the method is removed in opencv 4.8. The `SOLVEPNP_IPPE_SQUARE` solver implemented is more appropriate for markers.
- Pipeline architecture cleanup
- Re-enables ArUco pipeline in UI
- Multi-tag support

ArUco detector support is still considered experimental at this time. This should enable a baseline of support for initial testing, but expect some quirks to remain across platforms.
2023-10-24 22:39:38 -04:00
Sriman Achanta
959c162fc2 [photon-client] Styling fixes (#968) 2023-10-21 11:09:55 -04:00
Sriman Achanta
8446c94508 [photon-client] Fix camera and pipeline name editing (#969)
closes #965

    Had to disable the eslint rule that was causing the bug.
    Disallows disabling driver mode when there are no other pipelines to swap to
    Also adds icons for saving and canceling name edits
    Adds the option to create a new pipeline in driver mode if there are no other pipelines
    Adds disable prop to the driver mode switch on the camera settings page
2023-10-21 10:46:53 -04:00
Sriman Achanta
89908fc181 [photon-server] Fix journal-ctl export bug (#970)
* Update Server.java

* And this
2023-10-20 07:04:19 -05:00
Sriman Achanta
25a4f24b06 [photon-client] ATFL Settings card unit and styling fixes (#967)
* Fix ATFL settings card

* Update ApriltagControlCard.vue
2023-10-19 00:30:04 -04:00
Sriman Achanta
7f98941b23 [photon-client] Change UI naming schema from CV to PV (#955) 2023-10-17 16:32:59 -04:00
Matt
47bd077bbb Run multitag on coprocessor (#816) 2023-10-17 10:20:00 -04:00
Sriman Achanta
ededc4f130 Take Snapshots from PhotonClient (#940) 2023-10-17 09:08:25 -04:00
Sriman Achanta
1aa6bc80c9 File upload robustness (#956)
Fixes issues uploading multiple files manually
2023-10-17 09:02:13 -04:00
Matt
67d8680a32 Remove empty tab groups in UI (#948)
* Remove empty tab  groups

* Chain list comprehension

* Further condense

* add comment

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2023-10-15 15:11:23 -04:00
Sriman Achanta
8b9a198d0b [photon-client] Fix imports and simplify process of updated pipeline settings in store (#946)
* Update CameraSettingsStore.ts

* Fix imports
2023-10-11 15:31:50 -07:00
Matt
b37948cf5e Fix function argument types for file upload (#939) 2023-10-10 23:55:48 -04:00
Sriman Achanta
65d5494ab3 update ui ci names and levels (#929) 2023-10-01 21:28:07 -04:00
Sriman Achanta
5267b2c70d Temp fix to revert to hash URLs (#927) 2023-09-27 22:52:19 -04:00
Sriman Achanta
43eefcf1c5 Correctly stringify numbers in textboxes (#921)
* fix an issue where the fov isnt reset on error

* Fix issue with incorrectly reading fov on update

* Properly handle NPE in case of error

* Fix issue with vuetify comps not converting strings to numbers

* Formatting fixes
2023-09-26 08:02:18 -04:00
Matt
306677e56f Advanced networking settings (#899)
Exposes NetworkManager interface name and more robustly handles device/interface names internally.

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2023-09-01 15:58:35 -04:00
Sriman Achanta
08892b9e68 UI patches (#905)
- Show 0 clients when NT server props are undefined
- Add Prettier 

---------

Co-authored-by: Matthew Morley <matthew.morley.ca@gmail.com>
2023-08-31 16:56:58 -04:00
Sriman Achanta
8751764721 Update GeneralSettingsStore.ts (#900) 2023-08-22 15:34:45 -07:00
Matt
2f2396fe57 Fix frontend spelling of shouldManage (#898) 2023-08-21 16:47:28 -04:00
Sriman Achanta
f623e4a1cc [PhotonClient] Vite and Typescript complete refactor (#884) 2023-08-20 22:51:35 -07:00
Sriman Achanta
715ef62c85 Update backend to provide more useful info to frontend (#866) 2023-06-25 18:07:27 -07:00
Sriman Achanta
f813048462 [PhotonClient] Fix misc bugs and dataflow errors (#861)
Fixes leftover bugs from #767 and #856

- Because new URLs aren't based on hash URL schemas, all the routes need to be updated to final paths instead of relative ones that were previously caught by the hash URL
- Fixed misc Vue warnings pointed out by @mcm001
2023-06-18 00:05:46 -04:00
Sriman Achanta
58419cfe38 Update vue-router to use HTML5 history (#856)
closes #855

Only issues I see is that only HTML5 History API supported browsers support this which is fine given that the only thing that doesn't is probably the laptop they use to flash routers at competitions.

The 404 page can be up for debate lol.
2023-06-10 17:15:28 -04:00
Sriman Achanta
7b8fb3385b [PhotonClient] Update dependencies to latest, update assets, and styling fixes (#767)
Currently, there is a difficult-to-reproduce bug where the backend reports that camera calibration was successful in logs via the logger but then throws an exception causing the backend to return a 500 error code with no request body which causes the frontend to interpret this as a failed calibration attempt. This ultimately leads to the entire instance of photonvision crashing and requiring the entire pi to be restarted. It is believed this issue resides inside the ConfigManager's saving action following the calibration update but is not confirmed.
2023-06-09 10:09:41 -07:00
Doug Wegscheid
80f479344d Allow arbitrary networktables address (#764)
* Allow specifying NT server address by ip.
2023-05-12 18:01:09 -04:00
Stephen Day
6bdb158b33 Remove ErodeDilate from UI and ColoredShapePipeline (#829) 2023-04-18 18:50:01 -04:00
person4268
78ffa415fc Vendor fonts for offline usage (#839)
This should reduce loading time as browsers show a blank screen while they try and load the inaccessible Google Fonts. Fontsource simply provides an easy way to integrate the font without much work on our end.
2023-04-17 11:32:33 -04:00
Mason Vogt
767c0471d9 Fix typo in calibration message (#814) 2023-02-26 22:39:46 -05:00
Matt
3c53dcbb7b Call correct addCalibration in VisionModule (#793) 2023-02-08 21:06:53 -05:00
Matt
d0162b0ed0 Switch network management to networkmanager on Linux (#738)
* Switch network management to networkmanager

* Run style

* Fix command formatting

* Add curst Pi 5 second sleep

* Run formatter

* Also bring up/down on other linux

* Switch to nmcli down/up

* Remove sleep in nmcli down/up

* Address review
2023-01-18 16:31:14 -05:00
Matt
9d6997180d Add calibdb upload button (#735)
* Add calibdb upload

* Fix distortion coefficients size
2023-01-18 16:29:58 -05:00
Matt
d9f99f9c9b Add calibration decimate dropdown (#739)
* Increase resized size to 640

* Add calibration decimation dropdown

* Update Calibrate3dPipeTest.java

* Only allow decimation down to >=320x240

* Update CamerasView.vue
2023-01-14 19:23:14 -06:00
Chris Gerth
e12f360a29 Update cv-select.vue (#719) 2023-01-07 10:54:54 -05:00