Skip to content

Commit

Permalink
Fix input setting and invocation. (#5888)
Browse files Browse the repository at this point in the history
Fix input setting and invocation. (#5752)

Summary:
Pull Request resolved: #5752

.

Reviewed By: kirklandsign

Differential Revision: D63640035

fbshipit-source-id: 47b5952d3e77cbe65751c81af55960001a9552fd
(cherry picked from commit 68548e5)

Co-authored-by: Anthony Shoumikhin <shoumikhin@meta.com>
  • Loading branch information
pytorchbot and shoumikhin authored Oct 4, 2024
1 parent 4adf496 commit f8d6689
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions extension/apple/Benchmark/Tests/Tests.mm
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,8 @@ + (void)initialize {
const auto sizes = tensor_meta->sizes();
tensors.emplace_back(ones({sizes.begin(), sizes.end()},
tensor_meta->scalar_type()));
inputs.emplace_back(tensors.back());
XCTAssertEqual(module->set_input(tensors.back(), index),
Error::Ok);
} break;
default:
XCTFail("Unsupported tag %i at input %d", *input_tag, index);
Expand All @@ -110,7 +111,7 @@ + (void)initialize {
]
options:XCTMeasureOptions.defaultOptions
block:^{
XCTAssertEqual(module->forward(inputs).error(),
XCTAssertEqual(module->forward().error(),
Error::Ok);
}];
});
Expand Down

0 comments on commit f8d6689

Please sign in to comment.