Skip to content
This repository was archived by the owner on Aug 28, 2024. It is now read-only.

Commit 887a576

Browse files
authored
Merge pull request #70 from khiemauto/master
correct order of input tensor channels
2 parents c6af5ca + 4f7b24a commit 887a576

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ObjectDetection/ObjectDetection/Inference/InferenceModule.mm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ - (nullable instancetype)initWithFileAtPath:(NSString*)filePath {
3232

3333
- (NSArray<NSNumber*>*)detectImage:(void*)imageBuffer {
3434
try {
35-
at::Tensor tensor = torch::from_blob(imageBuffer, { 1, 3, input_width, input_height }, at::kFloat);
35+
at::Tensor tensor = torch::from_blob(imageBuffer, { 1, 3, input_height, input_width }, at::kFloat);
3636

3737
c10::InferenceMode guard;
3838
CFTimeInterval startTime = CACurrentMediaTime();

0 commit comments

Comments
 (0)