oidn-web 0.2.2 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -3
- package/dist/oidn.js +3520 -3407
- package/dist/oidn.umd.cjs +474 -464
- package/lib/UNet.d.ts +22 -5
- package/lib/UNet.js +101 -74
- package/lib/UNet.js.map +1 -1
- package/lib/WGPUComputePass.d.ts +13 -3
- package/lib/WGPUComputePass.js +85 -29
- package/lib/WGPUComputePass.js.map +1 -1
- package/lib/backend.js +6 -1
- package/lib/backend.js.map +1 -1
- package/lib/helper.d.ts +3 -0
- package/lib/helper.js +6 -0
- package/lib/helper.js.map +1 -1
- package/lib/process.d.ts +14 -5
- package/lib/process.js +207 -86
- package/lib/process.js.map +1 -1
- package/package.json +1 -1
- package/src/UNet.ts +154 -100
- package/src/WGPUComputePass.ts +100 -38
- package/src/backend.ts +8 -2
- package/src/helper.ts +8 -0
- package/src/process.ts +227 -98
package/README.md
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
# Open Image Denoise on the Web
|
|
2
2
|
|
|
3
3
|
This library brings the state-of-the-art AI-based denoising library [Open Image Denoise](https://github.com/RenderKit/oidn) to the web.
|
|
4
|
+
Currently it's only available on the browsers support WebGPU.
|
|
4
5
|
|
|
5
6
|
It's used in the [Vector to 3D](https://www.figma.com/community/plugin/1264600219316901594/) Figma plugin for high quality rendering and denoising.
|
|
6
7
|
|
|
@@ -12,10 +13,12 @@ It's used in the [Vector to 3D](https://www.figma.com/community/plugin/126460021
|
|
|
12
13
|
|
|
13
14
|
It uses [tfjs](https://github.com/tensorflow/tfjs) to build the UNet model used by the OIDN. Then use the model to do prediction with a WebGPU backend from the image data.
|
|
14
15
|
|
|
15
|
-
Currently it's only available on the browser with WebGPU enabled.
|
|
16
|
-
|
|
17
16
|
## How to Use
|
|
18
17
|
|
|
18
|
+
[Basic Example](https://oidn-web-example.vercel.app/) ([Code](https://github.com/pissang/oidn-web-example/blob/main/src/main.js))
|
|
19
|
+
|
|
20
|
+
[Use with three-gpu-pathtracer](https://oidn-web-example.vercel.app/three-gpu-pathtracer.html) ([Code](https://github.com/pissang/oidn-web-example/blob/main/src/three-gpu-pathtracer.js))
|
|
21
|
+
|
|
19
22
|
### Install
|
|
20
23
|
|
|
21
24
|
```shell
|
|
@@ -73,7 +76,7 @@ initUNetFromURL('./weights/rt_hdr.tza', undefined, {
|
|
|
73
76
|
});
|
|
74
77
|
```
|
|
75
78
|
|
|
76
|
-
###
|
|
79
|
+
### Use auxiliary images
|
|
77
80
|
|
|
78
81
|
```ts
|
|
79
82
|
import { UNet, initUNetFromURL } from 'oidn-web';
|