Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(blur) replace BodyPix with TFLite
Use the Google Meet model and SIMD optimized WASM.
- Loading branch information
Showing
14 changed files
with
218 additions
and
69 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Virtual Background on stream effects | ||
|
||
> Inspired from https://ai.googleblog.com/2020/10/background-features-in-google-meet.html and https://github.com/Volcomix/virtual-background.git | ||
#### Canvas 2D + CPU | ||
|
||
This rendering pipeline is pretty much the same as for BodyPix. It relies on Canvas compositing properties to blend rendering layers according to the segmentation mask. | ||
|
||
Interactions with TFLite inference tool are executed on CPU to convert from UInt8 to Float32 for the model input and to apply softmax on the model output. | ||
|
||
The framerate is higher and the quality looks better than BodyPix | ||
|
||
#### SIMD and non-SIMD | ||
|
||
How to test on SIMD: | ||
1. Go to chrome://flags/ | ||
2. Search for SIMD flag | ||
3. Enable WebAssembly SIMD support(Enables support for the WebAssembly SIMD proposal). | ||
4. Reopen Google Chrome | ||
|
||
More details: | ||
- [WebAssembly](https://webassembly.org/) | ||
- [WebAssembly SIMD](https://github.com/WebAssembly/simd) | ||
- [TFLite](https://blog.tensorflow.org/2020/07/accelerating-tensorflow-lite-xnnpack-integration.html) |
Binary file added
BIN
+398 KB
react/features/stream-effects/blur/vendor/models/segm_full_v679.tflite
Binary file not shown.
Binary file added
BIN
+398 KB
react/features/stream-effects/blur/vendor/models/segm_lite_v681.tflite
Binary file not shown.
Oops, something went wrong.