A function that cannot be inverted

Lets say I have a function f(x)=x.
Then PyTorch can find this relation.
Lets say I have a function f(x,y)=x
Then Pytorch cannot find the relation between f and y, because there is no relation.
But will the Pytorch still succeed at finding the relation between f and x?
Or will the performance at finding x be degraded because of the presence of y?

In my experiment, it seems like the performance of the network is degraded, at finding x.