# Can't compile the student's code. RuntimeError

**URL:** <https://community.deeplearning.ai/t/cant-compile-the-students-code-runtimeerror/289318>\
**Category:** Build Basic Generative Adversarial Networks\
**Tags:** week-module-4\
**Created:** [March 12, 2023, 7:51pm UTC](https://community.deeplearning.ai/t/cant-compile-the-students-code-runtimeerror/289318 "2023-03-12T19:51:37Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![paulinpaloalto](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/paulinpaloalto/32/187_2.png) [@paulinpaloalto](https://community.deeplearning.ai/u/paulinpaloalto)\
**Post date:** [March 16, 2023, 7:42pm UTC](https://community.deeplearning.ai/t/cant-compile-the-students-code-runtimeerror/289318/7 "2023-03-16T19:42:01Z")

</div>

I think this is [another case](https://community.deeplearning.ai/t/all-cells-passed-the-unit-test-but-got-error-after-submitting/291125/7) in which the torch version that the grader is using is less permissive than the one in the notebook. It looks like the grader’s version of `torch.cat` can’t handle different types. I wrote that code like this and it passes the grader:

`combined = torch.cat((x.float(), y.float()), dim = 1)`

The point is that I do the conversion to `float` _before_ the cat, of course.

---

_[View the full topic](https://community.deeplearning.ai/t/cant-compile-the-students-code-runtimeerror/289318)._
