-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
52 additions
and
47 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,12 @@ | ||
import { BaseModule } from './BaseModule'; | ||
import { _ClassificationModule } from '../../native/RnExecutorchModules'; | ||
|
||
export class ClassificationModule extends BaseModule { | ||
constructor() { | ||
super(new _ClassificationModule()); | ||
export class ClassificationModule { | ||
static async load(modelSource: string | number) { | ||
await BaseModule.load(_ClassificationModule, modelSource); | ||
} | ||
|
||
static async forward(input: string): Promise<{ [category: string]: number }> { | ||
return await BaseModule.forward(_ClassificationModule, input); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,13 @@ | ||
import { BaseModule } from './BaseModule'; | ||
import { _ObjectDetectionModule } from '../../native/RnExecutorchModules'; | ||
import { Detection } from '../../types/object_detection'; | ||
|
||
export class ObjectDetectionModule extends BaseModule { | ||
constructor() { | ||
super(new _ObjectDetectionModule()); | ||
export class ObjectDetectionModule { | ||
static async load(modelSource: string | number) { | ||
await BaseModule.load(_ObjectDetectionModule, modelSource); | ||
} | ||
|
||
static async forward(input: string): Promise<Detection[]> { | ||
return await BaseModule.forward(_ObjectDetectionModule, input); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,12 @@ | ||
import { BaseModule } from './BaseModule'; | ||
import { _StyleTransferModule } from '../../native/RnExecutorchModules'; | ||
|
||
export class StyleTransfer extends BaseModule { | ||
constructor() { | ||
super(new _StyleTransferModule()); | ||
export class StyleTransferModule { | ||
static async load(modelSource: string | number) { | ||
await BaseModule.load(_StyleTransferModule, modelSource); | ||
} | ||
|
||
static async forward(input: string): Promise<string> { | ||
return await BaseModule.forward(_StyleTransferModule, input); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters