Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Checking 3.8.0 (defaults bad, good with flag) #131

Closed
wants to merge 3 commits into from

Conversation

wingman-jr-addon
Copy link
Owner

I gave this a shot but unfortunately the loading + first inference performance degrades heavily on my machine from 2.7.0 to 3.8.0.

Here are some numbers:
3.8.0

LIFECYCLE: TIMING LOADING: {"uploadWaitMs":3241,"downloadWaitMs":0,"kernelMs":{"error":"WebGL query timers are not supported in this environment."},"wallMs":13325}
LIFECYCLE: TIMING LOADING: {"uploadWaitMs":3262,"downloadWaitMs":0,"kernelMs":{"error":"WebGL query timers are not supported in this environment."},"wallMs":13569}
LIFECYCLE: TIMING LOADING: {"uploadWaitMs":3179,"downloadWaitMs":0,"kernelMs":{"error":"WebGL query timers are not supported in this environment."},"wallMs":13623}

2.7.0

LIFECYCLE: TIMING LOADING: {"uploadWaitMs":3349,"downloadWaitMs":0,"kernelMs":{"error":"WebGL query timers are not supported in this environment."},"wallMs":8992}
LIFECYCLE: TIMING LOADING: {"uploadWaitMs":3639,"downloadWaitMs":0,"kernelMs":{"error":"WebGL query timers are not supported in this environment."},"wallMs":9447}
LIFECYCLE: TIMING LOADING: {"uploadWaitMs":3085,"downloadWaitMs":0,"kernelMs":{"error":"WebGL query timers are not supported in this environment."},"wallMs":8448}

@wingman-jr-addon wingman-jr-addon changed the title Trying TF.js 3.8.0 Checking 3.8.0 (bad) Jul 19, 2021
@wingman-jr-addon wingman-jr-addon changed the title Checking 3.8.0 (bad) Checking 3.8.0 (defaults bad, good with flag) Jul 26, 2021
@wingman-jr-addon wingman-jr-addon marked this pull request as ready for review July 26, 2021 03:04
@wingman-jr-addon
Copy link
Owner Author

Update: I did some work in figuring out the core of the regression and ended up making three changes:

  1. tf.env().set('WEBGL_PACK_DEPTHWISECONV', false) fixes a regression caused by a flag default changing in 3.3 -> 3.4.
  2. The order of the outputs changed somehow in the TF.js upgrade, so it broke and I needed to switch the ordering on sqrxrScore.
  3. TF.js team was kind and pointed out I might get a load-time performance boost from the new tf.env().set('WEBGL_USE_SHAPES_UNIFORMS', true)

So the net result is that load times are something like 500+ ms faster on my box.

@wingman-jr-addon wingman-jr-addon deleted the fast-shader-compilation branch December 19, 2021 22:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant