Anurag1734/cuda-error-resolution-analysis
07
1[2 {3 "post_stream": {4 "posts": [5 {6 "id": 411350,7 "name": "Javier Alonso",8 "username": "Javier_Alonso",9 "avatar_template": "/user_avatar/discuss.pytorch.org/javier_alonso/{size}/62606_2.png",10 "created_at": "2023-07-25T14:52:54.686Z",11 "cooked": "<p>Hi everyone, I’m new in this community and relative new in IA.</p>\n<p>I downloaded the llama-2-7b-chat from meta and I want to run this in Java.</p>\n<p>First I tried to load the module with:</p>\n<pre><code class=\"lang-auto\">Module mod = Module.load(\"llama-2-7b-chat/consolidated.00.pth\", extraFiles, Device.CPU);\n</code></pre>\n<p>but I have theese errors:</p>\n<pre><code class=\"lang-auto\">Exception in thread \"main\" com.facebook.jni.CppException: PytorchStreamReader failed locating file constants.pkl: file not found\nException raised from valid at C:\\actions-runner\\_work\\pytorch\\pytorch\\builder\\windows\\pytorch\\caffe2\\serialize\\inline_container.cc:184 (most recent call first):\n</code></pre>\n<p>I read that is a problem with the model’s format and I should convert it into a pt (TorchScript model).</p>\n<p>I’ve tried with a lot of code, and in my last attemp I wrote this:</p>\n<pre><code class=\"lang-auto\">import torch\nfrom transformers import LlamaPreTrainedModel\n\n#print(torch.__version__)\n\n# Carga tu modelo entrenado en PyTorch\n#model = torch.jit.load('consolidated.00.pth', map_location=torch.device('cpu'))\nmodel = LlamaPreTrainedModel.from_pretrained(pretrained_model_name_or_path='consolidated.00.pth',\n config='params.json',)\n\nprint(type(model))\n\n# Convierte el modcelo a TorchScript\nscripted_model = torch.jit.script(model)\n\nprint(type(scripted_model))\n\n# Guarda el modelo en formato TorchScript\n#torch.save(scripted_model, 'llama_chat.pt')\n</code></pre>\n<p>I can see only the lines of the error but not the exception, my terminal only displays:<br>\nStopIteration</p>\n<p>Somebody managed to convert this model to torchscript?</p>\n<p>Thanks for read!</p>",12 "post_number": 1,13 "post_type": 1,14 "posts_count": 3,15 "updated_at": "2023-07-25T15:24:10.121Z",16 "reply_count": 0,17 "reply_to_post_number": null,18 "quote_count": 0,19 "incoming_link_count": 4042,20 "reads": 21,21 "readers_count": 20,22 "score": 20114.2,23 "yours": false,24 "topic_id": 185015,25 "topic_slug": "convert-pth-to-pt",26 "display_username": "Javier Alonso",27 "primary_group_name": null,28 "flair_name": null,29 "flair_url": null,30 "flair_bg_color": null,31 "flair_color": null,32 "flair_group_id": null,33 "badges_granted": [],34 "version": 3,35 "can_edit": false,36 "can_delete": false,37 "can_recover": false,38 "can_see_hidden_post": false,39 "can_wiki": false,40 "read": true,41 "user_title": null,42 "bookmarked": false,43 "actions_summary": [],44 "moderator": false,45 "admin": false,46 "staff": false,47 "user_id": 68150,48 "hidden": false,49 "trust_level": 0,50 "deleted_at": null,51 "user_deleted": false,52 "edit_reason": null,53 "can_view_edit_history": true,54 "wiki": false,55 "post_url": "/t/convert-pth-to-pt/185015/1",56 "can_accept_answer": false,57 "can_unaccept_answer": false,58 "accepted_answer": false,59 "topic_accepted_answer": null,60 "can_vote": false61 },62 {63 "id": 424326,64 "name": "Hanson Mwangi",65 "username": "GithinjiHans",66 "avatar_template": "/user_avatar/discuss.pytorch.org/githinjihans/{size}/65538_2.png",67 "created_at": "2023-11-17T22:29:12.852Z",68 "cooked": "<p>did you find a solution for this?</p>",69 "post_number": 2,70 "post_type": 1,71 "posts_count": 3,72 "updated_at": "2023-11-17T22:29:12.852Z",73 "reply_count": 1,74 "reply_to_post_number": null,75 "quote_count": 0,76 "incoming_link_count": 3,77 "reads": 9,78 "readers_count": 8,79 "score": 21.8,80 "yours": false,81 "topic_id": 185015,82 "topic_slug": "convert-pth-to-pt",83 "display_username": "Hanson Mwangi",84 "primary_group_name": null,85 "flair_name": null,86 "flair_url": null,87 "flair_bg_color": null,88 "flair_color": null,89 "flair_group_id": null,90 "badges_granted": [],91 "version": 1,92 "can_edit": false,93 "can_delete": false,94 "can_recover": false,95 "can_see_hidden_post": false,96 "can_wiki": false,97 "read": true,98 "user_title": null,99 "bookmarked": false,100 "actions_summary": [],101 "moderator": false,102 "admin": false,103 "staff": false,104 "user_id": 71002,105 "hidden": false,106 "trust_level": 1,107 "deleted_at": null,108 "user_deleted": false,109 "edit_reason": null,110 "can_view_edit_history": true,111 "wiki": false,112 "post_url": "/t/convert-pth-to-pt/185015/2",113 "can_accept_answer": false,114 "can_unaccept_answer": false,115 "accepted_answer": false,116 "topic_accepted_answer": null117 },118 {119 "id": 424366,120 "name": "Javier Alonso",121 "username": "Javier_Alonso",122 "avatar_template": "/user_avatar/discuss.pytorch.org/javier_alonso/{size}/62606_2.png",123 "created_at": "2023-11-18T16:22:38.404Z",124 "cooked": "<p>No. Sorry <img src=\"https://discuss.pytorch.org/images/emoji/apple/frowning.png?v=12\" title=\":frowning:\" class=\"emoji\" alt=\":frowning:\" loading=\"lazy\" width=\"20\" height=\"20\"></p>\n<p>I’ve been very busy.</p>",125 "post_number": 3,126 "post_type": 1,127 "posts_count": 3,128 "updated_at": "2023-11-18T16:22:38.404Z",129 "reply_count": 0,130 "reply_to_post_number": 2,131 "quote_count": 0,132 "incoming_link_count": 15,133 "reads": 6,134 "readers_count": 5,135 "score": 71.2,136 "yours": false,137 "topic_id": 185015,138 "topic_slug": "convert-pth-to-pt",139 "display_username": "Javier Alonso",140 "primary_group_name": null,141 "flair_name": null,142 "flair_url": null,143 "flair_bg_color": null,144 "flair_color": null,145 "flair_group_id": null,146 "badges_granted": [],147 "version": 1,148 "can_edit": false,149 "can_delete": false,150 "can_recover": false,151 "can_see_hidden_post": false,152 "can_wiki": false,153 "read": true,154 "user_title": null,155 "reply_to_user": {156 "id": 71002,157 "username": "GithinjiHans",158 "name": "Hanson Mwangi",159 "avatar_template": "/user_avatar/discuss.pytorch.org/githinjihans/{size}/65538_2.png"160 },161 "bookmarked": false,162 "actions_summary": [],163 "moderator": false,164 "admin": false,165 "staff": false,166 "user_id": 68150,167 "hidden": false,168 "trust_level": 0,169 "deleted_at": null,170 "user_deleted": false,171 "edit_reason": null,172 "can_view_edit_history": true,173 "wiki": false,174 "post_url": "/t/convert-pth-to-pt/185015/3",175 "can_accept_answer": false,176 "can_unaccept_answer": false,177 "accepted_answer": false,178 "topic_accepted_answer": null179 }180 ],181 "stream": [182 411350,183 424326,184 424366185 ]186 },187 "timeline_lookup": [188 [189 1,190 823191 ],192 [193 2,194 708195 ],196 [197 3,198 707199 ]200 ],201 "suggested_topics": [202 {203 "fancy_title": "torch.OutOfMemoryError: CUDA out of memory",204 "id": 217669,205 "title": "torch.OutOfMemoryError: CUDA out of memory",206 "slug": "torch-outofmemoryerror-cuda-out-of-memory",207 "posts_count": 4,208 "reply_count": 2,209 "highest_post_number": 4,210 "image_url": null,211 "created_at": "2025-03-10T14:46:11.148Z",212 "last_posted_at": "2025-03-12T12:34:35.945Z",213 "bumped": true,214 "bumped_at": "2025-03-12T12:34:35.945Z",215 "archetype": "regular",216 "unseen": false,217 "pinned": false,218 "unpinned": null,219 "visible": true,220 "closed": false,221 "archived": false,222 "bookmarked": null,223 "liked": null,224 "tags_descriptions": {},225 "like_count": 0,226 "views": 580,227 "category_id": 1,228 "featured_link": null,229 "has_accepted_answer": false,230 "posters": [231 {232 "extras": "latest",233 "description": "Original Poster, Most Recent Poster",234 "user": {235 "id": 82794,236 "username": "Mohan_Krishna",237 "name": "Mohan Krishna",238 "avatar_template": "/user_avatar/discuss.pytorch.org/mohan_krishna/{size}/75758_2.png",239 "trust_level": 1240 }241 },242 {243 "extras": null,244 "description": "Frequent Poster",245 "user": {246 "id": 3534,247 "username": "ptrblck",248 "name": "",249 "avatar_template": "/user_avatar/discuss.pytorch.org/ptrblck/{size}/1823_2.png",250 "admin": true,251 "moderator": true,252 "trust_level": 2253 }254 }255 ]256 },257 {258 "fancy_title": "Not able to access GPT-Fast blogpost anymore",259 "id": 217765,260 "title": "Not able to access GPT-Fast blogpost anymore",261 "slug": "not-able-to-access-gpt-fast-blogpost-anymore",262 "posts_count": 1,263 "reply_count": 0,264 "highest_post_number": 1,265 "image_url": null,266 "created_at": "2025-03-12T22:41:03.576Z",267 "last_posted_at": "2025-03-12T22:41:03.615Z",268 "bumped": true,269 "bumped_at": "2025-03-12T22:41:03.615Z",270 "archetype": "regular",271 "unseen": false,272 "pinned": false,273 "unpinned": null,274 "visible": true,275 "closed": false,276 "archived": false,277 "bookmarked": null,278 "liked": null,279 "tags_descriptions": {},280 "like_count": 0,281 "views": 51,282 "category_id": 1,283 "featured_link": null,284 "has_accepted_answer": false,285 "posters": [286 {287 "extras": "latest single",288 "description": "Original Poster, Most Recent Poster",289 "user": {290 "id": 83227,291 "username": "njkumarr",292 "name": "",293 "avatar_template": "/letter_avatar_proxy/v4/letter/n/d9b06d/{size}.png",294 "trust_level": 0295 }296 }297 ]298 },299 {300 "fancy_title": "Recommended way to modify the Adam optimizer?",301 "id": 214161,302 "title": "Recommended way to modify the Adam optimizer?",303 "slug": "recommended-way-to-modify-the-adam-optimizer",304 "posts_count": 4,305 "reply_count": 2,306 "highest_post_number": 4,307 "image_url": null,308 "created_at": "2024-12-12T17:34:14.096Z",309 "last_posted_at": "2024-12-17T16:41:15.255Z",310 "bumped": true,311 "bumped_at": "2024-12-17T16:41:15.255Z",312 "archetype": "regular",313 "unseen": false,314 "pinned": false,315 "unpinned": null,316 "visible": true,317 "closed": false,318 "archived": false,319 "bookmarked": null,320 "liked": null,321 "tags_descriptions": {},322 "like_count": 0,323 "views": 452,324 "category_id": 1,325 "featured_link": null,326 "has_accepted_answer": false,327 "posters": [328 {329 "extras": null,330 "description": "Original Poster",331 "user": {332 "id": 57979,333 "username": "TriKri",334 "name": "",335 "avatar_template": "/letter_avatar_proxy/v4/letter/t/9de0a6/{size}.png",336 "trust_level": 2337 }338 },339 {340 "extras": "latest",341 "description": "Most Recent Poster",342 "user": {343 "id": 3534,344 "username": "ptrblck",345 "name": "",346 "avatar_template": "/user_avatar/discuss.pytorch.org/ptrblck/{size}/1823_2.png",347 "admin": true,348 "moderator": true,349 "trust_level": 2350 }351 }352 ]353 },354 {355 "fancy_title": "Should I start learning to use Pytorch?",356 "id": 217375,357 "title": "Should I start learning to use Pytorch?",358 "slug": "should-i-start-learning-to-use-pytorch",359 "posts_count": 2,360 "reply_count": 0,361 "highest_post_number": 2,362 "image_url": null,363 "created_at": "2025-03-03T10:03:58.772Z",364 "last_posted_at": "2025-03-03T11:45:52.247Z",365 "bumped": true,366 "bumped_at": "2025-03-03T11:45:52.247Z",367 "archetype": "regular",368 "unseen": false,369 "pinned": false,370 "unpinned": null,371 "visible": true,372 "closed": false,373 "archived": false,374 "bookmarked": null,375 "liked": null,376 "tags_descriptions": {},377 "like_count": 0,378 "views": 88,379 "category_id": 1,380 "featured_link": null,381 "has_accepted_answer": false,382 "posters": [383 {384 "extras": null,385 "description": "Original Poster",386 "user": {387 "id": 83036,388 "username": "fjesuslsanchez",389 "name": "",390 "avatar_template": "/letter_avatar_proxy/v4/letter/f/e480ec/{size}.png",391 "trust_level": 0392 }393 },394 {395 "extras": "latest",396 "description": "Most Recent Poster",397 "user": {398 "id": 64488,399 "username": "Naming-isDifficult",400 "name": "",401 "avatar_template": "/user_avatar/discuss.pytorch.org/naming-isdifficult/{size}/58644_2.png",402 "trust_level": 2403 }404 }405 ]406 },407 {408 "fancy_title": "Segmentation fault in 50K x 50K torch.matmul (fixed)",409 "id": 218513,410 "title": "Segmentation fault in 50K x 50K torch.matmul (fixed)",411 "slug": "segmentation-fault-in-50k-x-50k-torch-matmul-fixed",412 "posts_count": 2,413 "reply_count": 0,414 "highest_post_number": 2,415 "image_url": null,416 "created_at": "2025-04-02T05:10:32.606Z",417 "last_posted_at": "2025-04-02T14:44:43.440Z",418 "bumped": true,419 "bumped_at": "2025-04-02T14:44:43.440Z",420 "archetype": "regular",421 "unseen": false,422 "pinned": false,423 "unpinned": null,424 "visible": true,425 "closed": false,426 "archived": false,427 "bookmarked": null,428 "liked": null,429 "tags_descriptions": {},430 "like_count": 0,431 "views": 40,432 "category_id": 1,433 "featured_link": null,434 "has_accepted_answer": false,435 "posters": [436 {437 "extras": "latest single",438 "description": "Original Poster, Most Recent Poster",439 "user": {440 "id": 77475,441 "username": "Sanjeev_Rampal",442 "name": "Sanjeev Rampal",443 "avatar_template": "/user_avatar/discuss.pytorch.org/sanjeev_rampal/{size}/62377_2.png",444 "trust_level": 1445 }446 }447 ]448 }449 ],450 "tags_descriptions": {},451 "fancy_title": "Convert .pth to .pt",452 "id": 185015,453 "title": "Convert .pth to .pt",454 "posts_count": 3,455 "created_at": "2023-07-25T14:52:54.595Z",456 "views": 3881,457 "reply_count": 1,458 "like_count": 0,459 "last_posted_at": "2023-11-18T16:22:38.404Z",460 "visible": true,461 "closed": false,462 "archived": false,463 "has_summary": false,464 "archetype": "regular",465 "slug": "convert-pth-to-pt",466 "category_id": 1,467 "word_count": 241,468 "deleted_at": null,469 "user_id": 68150,470 "featured_link": null,471 "pinned_globally": false,472 "pinned_at": null,473 "pinned_until": null,474 "image_url": null,475 "slow_mode_seconds": 0,476 "draft": null,477 "draft_key": "topic_185015",478 "draft_sequence": null,479 "unpinned": null,480 "pinned": false,481 "current_post_number": 1,482 "highest_post_number": 3,483 "deleted_by": null,484 "actions_summary": [485 {486 "id": 4,487 "count": 0,488 "hidden": false,489 "can_act": false490 },491 {492 "id": 8,493 "count": 0,494 "hidden": false,495 "can_act": false496 },497 {498 "id": 10,499 "count": 0,500 "hidden": false,501 "can_act": false502 },503 {504 "id": 7,505 "count": 0,506 "hidden": false,507 "can_act": false508 }509 ],510 "chunk_size": 20,511 "bookmarked": false,512 "topic_timer": null,513 "message_bus_last_id": 0,514 "participant_count": 2,515 "show_read_indicator": false,516 "thumbnails": null,517 "slow_mode_enabled_until": null,518 "can_vote": false,519 "vote_count": 0,520 "user_voted": false,521 "discourse_zendesk_plugin_zendesk_id": null,522 "discourse_zendesk_plugin_zendesk_url": "https://your-url.zendesk.com/agent/tickets/",523 "details": {524 "can_edit": false,525 "notification_level": 1,526 "participants": [527 {528 "id": 68150,529 "username": "Javier_Alonso",530 "name": "Javier Alonso",531 "avatar_template": "/user_avatar/discuss.pytorch.org/javier_alonso/{size}/62606_2.png",532 "post_count": 2,533 "primary_group_name": null,534 "flair_name": null,535 "flair_url": null,536 "flair_color": null,537 "flair_bg_color": null,538 "flair_group_id": null,539 "trust_level": 0540 },541 {542 "id": 71002,543 "username": "GithinjiHans",544 "name": "Hanson Mwangi",545 "avatar_template": "/user_avatar/discuss.pytorch.org/githinjihans/{size}/65538_2.png",546 "post_count": 1,547 "primary_group_name": null,548 "flair_name": null,549 "flair_url": null,550 "flair_color": null,551 "flair_bg_color": null,552 "flair_group_id": null,553 "trust_level": 1554 }555 ],556 "created_by": {557 "id": 68150,558 "username": "Javier_Alonso",559 "name": "Javier Alonso",560 "avatar_template": "/user_avatar/discuss.pytorch.org/javier_alonso/{size}/62606_2.png"561 },562 "last_poster": {563 "id": 68150,564 "username": "Javier_Alonso",565 "name": "Javier Alonso",566 "avatar_template": "/user_avatar/discuss.pytorch.org/javier_alonso/{size}/62606_2.png"567 }568 },569 "bookmarks": []570 },571 {572 "post_stream": {573 "posts": [574 {575 "id": 424363,576 "name": "Aisha Mohamed2022",577 "username": "AishaMohamed2022",578 "avatar_template": "/user_avatar/discuss.pytorch.org/aishamohamed2022/{size}/65556_2.png",579 "created_at": "2023-11-18T15:03:17.770Z",580 "cooked": "<p>i implement Algorithm merge sort by c++<br>\nbut it not sorted Array input</p>\n<p><span class=\"hashtag-raw\">#include</span><br>\nusing namespace std;<br>\nvoid MERGE(int* A, int p, int q, int r) {<br>\nint n1 = q - p + 1;<br>\nint n2 = r - q;<br>\nint* L = new int[n1];<br>\nint * R=new int[n2];<br>\nfor (int i = 0; i < n1 + 1; i++) {<br>\nL[i] = A[p + i - 1];<br>\n}<br>\nfor (int j = 0; j < n2 + 1; j++) {<br>\nR[j] = A[p + j];<br>\n}<br>\nint l = 0, t = 0;<br>\nfor (int k = p; k < r + 1; k++) {<br>\nif (L[l] <= R[t]) {<br>\nA[k] = L[l];<br>\nl++;<br>\n}<br>\nelse if (A[k] == R[t])<br>\nt++;<br>\n}<br>\n}<br>\nvoid Merge_sort(int* A, int start, int end) {<br>\nif (start < end) {<br>\nint q = (start + end) / 2;<br>\nMerge_sort(A, start, q);<br>\nMerge_sort(A, q + 1, end);<br>\nMERGE(A, start, q, end);<br>\n}<br>\n}</p>\n<p>int main() {<br>\nint A<span class=\"chcklst-box fa fa-square-o fa-fw\"></span> = { 9,6,3,7,8,1,4,2,8,7 };<br>\nint a = 0, o = 5, e = 10;<br>\ncout << “Array sort” << endl;</p>\n<pre><code>Merge_sort(A,0,10);\n</code></pre>\n<p>for (int s = 0; s < e; s++) {<br>\ncout << A[s] << \" \";<br>\n}<br>\n}</p>\n<p>that is out put of code<br>\n-858993460 -858993460 -858993460 -858993460 3 1 1 1 1 7</p>",581 "post_number": 1,582 "post_type": 1,583 "posts_count": 2,584 "updated_at": "2023-11-18T15:05:51.491Z",585 "reply_count": 0,586 "reply_to_post_number": null,587 "quote_count": 0,588 "incoming_link_count": 8,589 "reads": 13,590 "readers_count": 12,591 "score": 42.6,592 "yours": false,593 "topic_id": 192115,594 "topic_slug": "can-anyone-correct-this-code-c",595 "display_username": "Aisha Mohamed2022",596 "primary_group_name": null,597 "flair_name": null,598 "flair_url": null,599 "flair_bg_color": null,600 "flair_color": null,601 "flair_group_id": null,602 "badges_granted": [],603 "version": 1,604 "can_edit": false,605 "can_delete": false,606 "can_recover": false,607 "can_see_hidden_post": false,608 "can_wiki": false,609 "read": true,610 "user_title": null,611 "bookmarked": false,612 "actions_summary": [],613 "moderator": false,614 "admin": false,615 "staff": false,616 "user_id": 71021,617 "hidden": false,618 "trust_level": 1,619 "deleted_at": null,620 "user_deleted": false,621 "edit_reason": null,622 "can_view_edit_history": true,623 "wiki": false,624 "post_url": "/t/can-anyone-correct-this-code-c/192115/1",625 "can_accept_answer": false,626 "can_unaccept_answer": false,627 "accepted_answer": false,628 "topic_accepted_answer": null,629 "can_vote": false630 },631 {632 "id": 424365,633 "name": "",634 "username": "ptrblck",635 "avatar_template": "/user_avatar/discuss.pytorch.org/ptrblck/{size}/1823_2.png",636 "created_at": "2023-11-18T15:06:31.776Z",637 "cooked": "<p>General C++ questions are better asked on StackOverflow. Use <code>torch.sort</code> to sort PyTorch tensors.</p>",638 "post_number": 2,639 "post_type": 1,640 "posts_count": 2,641 "updated_at": "2023-11-18T15:06:31.776Z",642 "reply_count": 0,643 "reply_to_post_number": null,644 "quote_count": 0,645 "incoming_link_count": 3,646 "reads": 13,647 "readers_count": 12,648 "score": 17.6,649 "yours": false,650 "topic_id": 192115,651 "topic_slug": "can-anyone-correct-this-code-c",652 "display_username": "",653 "primary_group_name": null,654 "flair_name": null,655 "flair_url": null,656 "flair_bg_color": null,657 "flair_color": null,658 "flair_group_id": null,659 "badges_granted": [],660 "version": 1,661 "can_edit": false,662 "can_delete": false,663 "can_recover": false,664 "can_see_hidden_post": false,665 "can_wiki": false,666 "read": true,667 "user_title": "",668 "bookmarked": false,669 "actions_summary": [],670 "moderator": true,671 "admin": true,672 "staff": true,673 "user_id": 3534,674 "hidden": false,675 "trust_level": 2,676 "deleted_at": null,677 "user_deleted": false,678 "edit_reason": null,679 "can_view_edit_history": true,680 "wiki": false,681 "post_url": "/t/can-anyone-correct-this-code-c/192115/2",682 "can_accept_answer": false,683 "can_unaccept_answer": false,684 "accepted_answer": false,685 "topic_accepted_answer": null686 }687 ],688 "stream": [689 424363,690 424365691 ]692 },693 "timeline_lookup": [694 [695 1,696 707697 ]698 ],699 "suggested_topics": [700 {701 "fancy_title": "Trace/Retrieve C++ implementations from a single python operation",702 "id": 220520,703 "title": "Trace/Retrieve C++ implementations from a single python operation",704 "slug": "trace-retrieve-c-implementations-from-a-single-python-operation",705 "posts_count": 1,706 "reply_count": 0,707 "highest_post_number": 1,708 "image_url": null,709 "created_at": "2025-06-02T15:52:29.111Z",710 "last_posted_at": "2025-06-02T15:52:29.150Z",711 "bumped": true,712 "bumped_at": "2025-06-02T15:52:29.150Z",713 "archetype": "regular",714 "unseen": false,715 "pinned": false,716 "unpinned": null,717 "visible": true,718 "closed": false,719 "archived": false,720 "bookmarked": null,721 "liked": null,722 "tags_descriptions": {},723 "like_count": 0,724 "views": 47,725 "category_id": 11,726 "featured_link": null,727 "has_accepted_answer": false,728 "posters": [729 {730 "extras": "latest single",731 "description": "Original Poster, Most Recent Poster",732 "user": {733 "id": 84550,734 "username": "nautsimon",735 "name": "Simon",736 "avatar_template": "/user_avatar/discuss.pytorch.org/nautsimon/{size}/77242_2.png",737 "trust_level": 0738 }739 }740 ]741 },742 {743 "fancy_title": "[BUG] why does the C++ Libtorch performance slower than pytorch? (show the full code)",744 "id": 222333,745 "title": "[BUG] why does the C++ Libtorch performance slower than pytorch? (show the full code)",746 "slug": "bug-why-does-the-c-libtorch-performance-slower-than-pytorch-show-the-full-code",747 "posts_count": 1,748 "reply_count": 0,749 "highest_post_number": 1,750 "image_url": null,751 "created_at": "2025-08-13T14:58:27.870Z",752 "last_posted_at": "2025-08-13T14:58:27.951Z",753 "bumped": true,754 "bumped_at": "2025-08-13T14:58:27.951Z",755 "archetype": "regular",756 "unseen": false,757 "pinned": false,758 "unpinned": null,759 "visible": true,760 "closed": false,761 "archived": false,762 "bookmarked": null,763 "liked": null,764 "tags_descriptions": {},765 "like_count": 0,766 "views": 68,767 "category_id": 11,768 "featured_link": null,769 "has_accepted_answer": false,770 "posters": [771 {772 "extras": "latest single",773 "description": "Original Poster, Most Recent Poster",774 "user": {775 "id": 85492,776 "username": "Sukidesyo",777 "name": "Sukidesyo",778 "avatar_template": "/user_avatar/discuss.pytorch.org/sukidesyo/{size}/77955_2.png",779 "trust_level": 1780 }781 }782 ]783 },784 {785 "fancy_title": "Libtorch batch jacobians and hessians",786 "id": 212426,787 "title": "Libtorch batch jacobians and hessians",788 "slug": "libtorch-batch-jacobians-and-hessians",789 "posts_count": 1,790 "reply_count": 0,791 "highest_post_number": 1,792 "image_url": null,793 "created_at": "2024-11-01T19:33:33.035Z",794 "last_posted_at": "2024-11-01T19:33:33.079Z",795 "bumped": true,796 "bumped_at": "2024-11-01T19:33:33.079Z",797 "archetype": "regular",798 "unseen": false,799 "pinned": false,800 "unpinned": null,801 "visible": true,802 "closed": false,803 "archived": false,804 "bookmarked": null,805 "liked": null,806 "tags_descriptions": {},807 "like_count": 0,808 "views": 122,809 "category_id": 11,810 "featured_link": null,811 "has_accepted_answer": false,812 "posters": [813 {814 "extras": "latest single",815 "description": "Original Poster, Most Recent Poster",816 "user": {817 "id": 80640,818 "username": "dlittlewood",819 "name": "",820 "avatar_template": "/letter_avatar_proxy/v4/letter/d/f4b2a3/{size}.png",821 "trust_level": 1822 }823 }824 ]825 },826 {827 "fancy_title": "`.to(torch::kUInt8)` position caused weird issues",828 "id": 218310,829 "title": "`.to(torch::kUInt8)` position caused weird issues",830 "slug": "to-torch-kuint8-position-caused-weird-issues",831 "posts_count": 1,832 "reply_count": 0,833 "highest_post_number": 1,834 "image_url": null,835 "created_at": "2025-03-27T04:38:53.960Z",836 "last_posted_at": "2025-03-27T04:38:54.059Z",837 "bumped": true,838 "bumped_at": "2025-03-27T04:43:20.073Z",839 "archetype": "regular",840 "unseen": false,841 "pinned": false,842 "unpinned": null,843 "visible": true,844 "closed": false,845 "archived": false,846 "bookmarked": null,847 "liked": null,848 "tags_descriptions": {},849 "like_count": 0,850 "views": 57,851 "category_id": 11,852 "featured_link": null,853 "has_accepted_answer": false,854 "posters": [855 {856 "extras": "latest single",857 "description": "Original Poster, Most Recent Poster",858 "user": {859 "id": 56882,860 "username": "L_R",861 "name": "L R",862 "avatar_template": "/user_avatar/discuss.pytorch.org/l_r/{size}/30837_2.png",863 "trust_level": 1864 }865 }866 ]867 },868 {869 "fancy_title": "Custom_class nn::module issue",870 "id": 222423,871 "title": "Custom_class nn::module issue",872 "slug": "custom-class-nn-module-issue",873 "posts_count": 1,874 "reply_count": 0,875 "highest_post_number": 1,876 "image_url": null,877 "created_at": "2025-08-17T15:42:41.847Z",878 "last_posted_at": "2025-08-17T15:42:41.903Z",879 "bumped": true,880 "bumped_at": "2025-08-17T15:42:41.903Z",881 "archetype": "regular",882 "unseen": false,883 "pinned": false,884 "unpinned": null,885 "visible": true,886 "closed": false,887 "archived": false,888 "bookmarked": null,889 "liked": null,890 "tags_descriptions": {},891 "like_count": 0,892 "views": 22,893 "category_id": 11,894 "featured_link": null,895 "has_accepted_answer": false,896 "posters": [897 {898 "extras": "latest single",899 "description": "Original Poster, Most Recent Poster",900 "user": {901 "id": 85405,902 "username": "pya",903 "name": null,904 "avatar_template": "/letter_avatar_proxy/v4/letter/p/919ad9/{size}.png",905 "trust_level": 1906 }907 }908 ]909 }910 ],911 "tags_descriptions": {},912 "fancy_title": "Can anyone correct this code c++",913 "id": 192115,914 "title": "Can anyone correct this code c++",915 "posts_count": 2,916 "created_at": "2023-11-18T15:03:17.678Z",917 "views": 319,918 "reply_count": 0,919 "like_count": 0,920 "last_posted_at": "2023-11-18T15:06:31.776Z",921 "visible": true,922 "closed": false,923 "archived": false,924 "has_summary": false,925 "archetype": "regular",926 "slug": "can-anyone-correct-this-code-c",927 "category_id": 11,928 "word_count": 204,929 "deleted_at": null,930 "user_id": 71021,931 "featured_link": null,932 "pinned_globally": false,933 "pinned_at": null,934 "pinned_until": null,935 "image_url": null,936 "slow_mode_seconds": 0,937 "draft": null,938 "draft_key": "topic_192115",939 "draft_sequence": null,940 "unpinned": null,941 "pinned": false,942 "current_post_number": 1,943 "highest_post_number": 2,944 "deleted_by": null,945 "actions_summary": [946 {947 "id": 4,948 "count": 0,949 "hidden": false,950 "can_act": false951 },952 {953 "id": 8,954 "count": 0,955 "hidden": false,956 "can_act": false957 },958 {959 "id": 10,960 "count": 0,961 "hidden": false,962 "can_act": false963 },964 {965 "id": 7,966 "count": 0,967 "hidden": false,968 "can_act": false969 }970 ],971 "chunk_size": 20,972 "bookmarked": false,973 "topic_timer": null,974 "message_bus_last_id": 0,975 "participant_count": 2,976 "show_read_indicator": false,977 "thumbnails": null,978 "slow_mode_enabled_until": null,979 "can_vote": false,980 "vote_count": 0,981 "user_voted": false,982 "discourse_zendesk_plugin_zendesk_id": null,983 "discourse_zendesk_plugin_zendesk_url": "https://your-url.zendesk.com/agent/tickets/",984 "details": {985 "can_edit": false,986 "notification_level": 1,987 "participants": [988 {989 "id": 3534,990 "username": "ptrblck",991 "name": "",992 "avatar_template": "/user_avatar/discuss.pytorch.org/ptrblck/{size}/1823_2.png",993 "post_count": 1,994 "primary_group_name": null,995 "flair_name": null,996 "flair_url": null,997 "flair_color": null,998 "flair_bg_color": null,999 "flair_group_id": null,1000 "admin": true,1001 "moderator": true,1002 "trust_level": 21003 },1004 {1005 "id": 71021,1006 "username": "AishaMohamed2022",1007 "name": "Aisha Mohamed2022",1008 "avatar_template": "/user_avatar/discuss.pytorch.org/aishamohamed2022/{size}/65556_2.png",1009 "post_count": 1,1010 "primary_group_name": null,1011 "flair_name": null,1012 "flair_url": null,1013 "flair_color": null,1014 "flair_bg_color": null,1015 "flair_group_id": null,1016 "trust_level": 11017 }1018 ],1019 "created_by": {1020 "id": 71021,1021 "username": "AishaMohamed2022",1022 "name": "Aisha Mohamed2022",1023 "avatar_template": "/user_avatar/discuss.pytorch.org/aishamohamed2022/{size}/65556_2.png"1024 },1025 "last_poster": {1026 "id": 3534,1027 "username": "ptrblck",1028 "name": "",1029 "avatar_template": "/user_avatar/discuss.pytorch.org/ptrblck/{size}/1823_2.png"1030 }1031 },1032 "bookmarks": []1033 },1034 {1035 "post_stream": {1036 "posts": [1037 {1038 "id": 424023,1039 "name": "Teddy Salas",1040 "username": "Teddy_Salas",1041 "avatar_template": "/user_avatar/discuss.pytorch.org/teddy_salas/{size}/64758_2.png",1042 "created_at": "2023-11-15T07:21:48.567Z",1043 "cooked": "<p>Hello everyone can anyone please tell me how to build a How to build a multi modal models in PyTorch from scratch?</p>",1044 "post_number": 1,1045 "post_type": 1,1046 "posts_count": 3,1047 "updated_at": "2023-11-15T07:21:48.567Z",1048 "reply_count": 0,1049 "reply_to_post_number": null,1050 "quote_count": 0,1051 "incoming_link_count": 59,1052 "reads": 7,1053 "readers_count": 6,1054 "score": 296.4,1055 "yours": false,1056 "topic_id": 191917,1057 "topic_slug": "how-to-build-a-multi-modals-models-in-pytorch",1058 "display_username": "Teddy Salas",1059 "primary_group_name": null,1060 "flair_name": null,1061 "flair_url": null,1062 "flair_bg_color": null,1063 "flair_color": null,1064 "flair_group_id": null,1065 "badges_granted": [],1066 "version": 1,1067 "can_edit": false,1068 "can_delete": false,1069 "can_recover": false,1070 "can_see_hidden_post": false,1071 "can_wiki": false,1072 "read": true,1073 "user_title": null,1074 "bookmarked": false,1075 "actions_summary": [],1076 "moderator": false,1077 "admin": false,1078 "staff": false,1079 "user_id": 63964,1080 "hidden": false,1081 "trust_level": 1,1082 "deleted_at": null,1083 "user_deleted": false,1084 "edit_reason": null,1085 "can_view_edit_history": true,1086 "wiki": false,1087 "post_url": "/t/how-to-build-a-multi-modals-models-in-pytorch/191917/1",1088 "can_accept_answer": false,1089 "can_unaccept_answer": false,1090 "accepted_answer": false,1091 "topic_accepted_answer": true,1092 "can_vote": false1093 },1094 {1095 "id": 424312,1096 "name": "James Callinicos",1097 "username": "JamesTrick",1098 "avatar_template": "/user_avatar/discuss.pytorch.org/jamestrick/{size}/10956_2.png",1099 "created_at": "2023-11-17T19:10:20.034Z",1100 "cooked": "<p>Hi Teddy</p>\n<p>You may want to checkout <a href=\"https://pytorch.org/blog/introducing-torchmultimodal/\" rel=\"noopener nofollow ugc\">TorchMultiModal</a>.</p>\n<p>If you’re wanting to combine an image and text for example, you can process these separately, and eventually join the two tensors (image and text) together using something like <code>torch.cat()</code>. We can’t help you too much further without more information.</p>",1101 "post_number": 2,1102 "post_type": 1,1103 "posts_count": 3,1104 "updated_at": "2023-11-17T19:10:20.034Z",1105 "reply_count": 1,1106 "reply_to_post_number": null,1107 "quote_count": 0,1108 "incoming_link_count": 2,1109 "reads": 7,1110 "readers_count": 6,1111 "score": 31.4,1112 "yours": false,1113 "topic_id": 191917,1114 "topic_slug": "how-to-build-a-multi-modals-models-in-pytorch",1115 "display_username": "James Callinicos",1116 "primary_group_name": null,1117 "flair_name": null,1118 "flair_url": null,1119 "flair_bg_color": null,1120 "flair_color": null,1121 "flair_group_id": null,1122 "badges_granted": [],1123 "version": 1,1124 "can_edit": false,1125 "can_delete": false,1126 "can_recover": false,1127 "can_see_hidden_post": false,1128 "can_wiki": false,1129 "link_counts": [1130 {1131 "url": "https://pytorch.org/blog/introducing-torchmultimodal/",1132 "internal": false,1133 "reflection": false,1134 "title": "Introducing TorchMultimodal - a library for accelerating exploration in Multimodal AI | PyTorch",1135 "clicks": 171136 }1137 ],1138 "read": true,1139 "user_title": null,1140 "bookmarked": false,1141 "actions_summary": [1142 {1143 "id": 2,1144 "count": 11145 }1146 ],1147 "moderator": false,1148 "admin": false,1149 "staff": false,1150 "user_id": 17564,1151 "hidden": false,1152 "trust_level": 2,1153 "deleted_at": null,1154 "user_deleted": false,1155 "edit_reason": null,1156 "can_view_edit_history": true,1157 "wiki": false,1158 "post_url": "/t/how-to-build-a-multi-modals-models-in-pytorch/191917/2",1159 "can_accept_answer": false,1160 "can_unaccept_answer": false,1161 "accepted_answer": true,1162 "topic_accepted_answer": true1163 },1164 {1165 "id": 424356,1166 "name": "Teddy Salas",1167 "username": "Teddy_Salas",1168 "avatar_template": "/user_avatar/discuss.pytorch.org/teddy_salas/{size}/64758_2.png",1169 "created_at": "2023-11-18T13:38:19.491Z",1170 "cooked": "<p>okay, thank you i will inform you later.</p>",1171 "post_number": 3,1172 "post_type": 1,1173 "posts_count": 3,1174 "updated_at": "2023-11-18T13:38:19.491Z",1175 "reply_count": 0,1176 "reply_to_post_number": 2,1177 "quote_count": 0,1178 "incoming_link_count": 0,1179 "reads": 6,1180 "readers_count": 5,1181 "score": 1.2,1182 "yours": false,1183 "topic_id": 191917,1184 "topic_slug": "how-to-build-a-multi-modals-models-in-pytorch",1185 "display_username": "Teddy Salas",1186 "primary_group_name": null,1187 "flair_name": null,1188 "flair_url": null,1189 "flair_bg_color": null,1190 "flair_color": null,1191 "flair_group_id": null,1192 "badges_granted": [],1193 "version": 1,1194 "can_edit": false,1195 "can_delete": false,1196 "can_recover": false,1197 "can_see_hidden_post": false,1198 "can_wiki": false,1199 "read": true,1200 "user_title": null,