fix(cluster-gan): valid shape error
#26
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
reproduct
error
Traceback (most recent call last): File "./cluster_gan.py", line 396, in <module> real_loss = bce_loss(D_real, valid) File "/usr/local/lib/python3.8/dist-packages/jittor/__init__.py", line 1172, in __call__ return self.execute(*args, **kw) File "/usr/local/lib/python3.8/dist-packages/jittor/nn.py", line 487, in execute return bce_loss(output, target, self.weight, self.size_average) File "/usr/local/lib/python3.8/dist-packages/jittor/nn.py", line 409, in bce_loss loss = - (target * jt.log(jt.maximum(output, 1e-20)) + (1 - target) * jt.log(jt.maximum(1 - output, 1e-20))) RuntimeError: Wrong inputs arguments, Please refer to examples(help(jt.__mul__)). Types of your inputs are: self = Var, b = Var, The function declarations are: VarHolder* multiply(VarHolder* x, VarHolder* y) Failed reason:[f 0422 19:43:25.634921 80 binary_op.cc:432] Check failed xshape(64) == yshape(32) Shape not match, x:float32[64,1,] y:float32[32,1,]