-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: only have the callback_with_info api
- Loading branch information
1 parent
51d4f70
commit 347b1d4
Showing
8 changed files
with
306 additions
and
73 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,19 @@ | ||
#include "session_c.h" | ||
#include <MNN/Interpreter.hpp> | ||
|
||
namespace MNN { | ||
class Session { | ||
public: | ||
bool hasAsyncWork(); | ||
}; | ||
} // namespace MNN | ||
void Session_destroy(Session *session) { | ||
auto mnn_session = reinterpret_cast<MNN::Session *>(session); | ||
// delete mnn_session; | ||
} | ||
|
||
int Session_hasAsyncWork(Session *session) { | ||
auto mnn_session = reinterpret_cast<MNN::Session *>(session); | ||
return mnn_session->hasAsyncWork(); | ||
// return true; | ||
} |
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 |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#ifndef SESSION_C_H | ||
#define SESSION_C_H | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
typedef struct Session Session; | ||
void Session_destroy(Session *session); | ||
int Session_hasAsyncWork(Session *session); | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif // SESSION_C_H |
Oops, something went wrong.