Comments (3)
@vanbasten23 can you take a look since you are offcall this week?
from xla.
I think there might be something wrong with
xla/torch_xla/core/xla_model.py
Lines 496 to 498 in 18b4dfa
If you set pin_layout = True
, I can see the correct result. To unblock you, can you try to replace new_t = xm.all_reduce('sum', new_t, pin_layout=False)
with xm.all_reduce('sum', [new_t], pin_layout=False)
?
from xla.
Sorry for the late reply. This issue isn't just with the all reduce API. If I switch to xm.collective_permute(new_t, [[0, 1], [1, 0]])
, the result is also incorrect. However, the result of xm.collective_permute(new_t.clone(), [[0, 1], [1, 0]])
is correct. It seems that this issue is related to XLAβs own implementation of custom ops, and there are some incompatibilities with PyTorch's inplace operators. Moreover, this issue can easily cause pitfalls for users.
from xla.
Related Issues (20)
- Op info test for `nn.functional.celu .. nn.functional.glu`
- Op info test for `nn.functional.hardshrink .. nn.functional.huber_loss`
- Op info test for `nn.functional.kl_div .. nn.functional.mse_loss`
- Op info test for `nn.functional.prelu .. nn.functional.silu`
- Op info test for `nn.functional.smooth_l1_loss .. nn.functional.softsign`
- Op info test for `nn.functional.tanhshrink .. nn.functional.upsample_bilinear`
- Op info test for `ones .. rad2deg`
- Op info test for `reshape_as .. roll`
- Op info test for `rsqrt .. signal.windows.cosine`
- Op info test for `signal.windows.exponential .. signal.windows.hamming`
- Op info test for `signal.windows.hann .. slice_scatter`
- Op info test for `sparse.mm .. special.xlog1py`
- Op info test for `split .. stack`
- Op info test for `sum_to_size .. tril_indices`
- Op info test for `triu_indices .. unsafe_chunk`
- Op info test for `unsafe_split .. view_as`
- Op info test for `view_copy .. zeros`
- Op info test for `view_copy .. zeros`
- `F.embedding_bag(..., mode='max')` yields different results than PyTorch eager. HOT 2
- Print(tensor) takes a very long time! HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xla.