Open liliquan0118 opened 1 month ago
Hi @liliquan0118 ,
I've executed the code snippet you provided, and I'm receiving the expected same output across all backends (CPU, WASM, WebGL). I'm running the snippet on macOS 14.7 and my chrome version is 129.0.66
Ouptput:
Thank You!!
@shmishra99 I get inconsistent results on macOS 13.3 (22E252) and my chrome version is Version 128.0.6613.86 (Official Build) (arm64). I also reproduced this inconsistency in Firefox and safari.
Output:
Please make sure that this is a bug. As per our GitHub Policy, we only address code/doc bugs, performance issues, feature requests and build/installation issues on GitHub. tag:bug_template
System information
Describe the current behavior Given the specific input, the output of the operator
tf.cos
is inconsistent between the backend WebGL and CPU、Wasm. The input is:[[222031363.04483604,-644006247.6421678,-605587169.2042153],[1454271400.9804254,62586397.87448788,-68460449.96912003],[947971713.1915293,-1557450302.7682097,-177600034.40499234],[580296681.4137621,-1029945044.7648776,1242489427.454761],[765821514.0764089,-1050250673.9083493,-807593657.384702],[-899719029.7993956,1994507237.8503175,643740213.4526525],[1739034989.3838263,854594021.672925,2080780625.6686144],[-1487391531.946444,-649097467.5578747,915379088.7619557],[-699072652.5136976,580871812.2644863,-2054123548.3292303],[-1695726211.436941,-1668680183.31515,-1232482205.5715837],[-271449972.2313881,-1794459494.529479,485735372.1116624],[-1498322592.7383604,81534077.20091677,-171731024.55517578],[-1734544940.168774,-1537308013.2696624,-813783320.1463277],[1877502216.6916676,738706968.7915564,-151212949.78009176],[-497439374.4975374,-1492868504.0418532,-1147644161.922762],[-381496084.0865674,-1273512753.80469,-1342920474.1095667],[1305493931.7932196,1111735360.2880988,-758057797.123117],[-1530258070.5911965,-460829762.73904085,925297487.5536752],[1011907807.5187173,-947508069.6779656,1415089246.4553628]]
The output on the WebGL backend is:
The output on the CPU backend is:
The output on the WASM backend is:
Describe the expected behavior The consistent behavior in all backends.
Standalone code to reproduce the issue Provide a reproducible test case that is the bare minimum necessary to generate the problem. If possible, please share a link to Colab/CodePen/any notebook.
Other info / logs Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached.