-
Notifications
You must be signed in to change notification settings - Fork 106
Create model execute command #680
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Conversation
…hich is deprecated for enterprise cluster)
Codecov Report
@@ Coverage Diff @@
## master #680 +/- ##
==========================================
+ Coverage 78.37% 78.90% +0.52%
==========================================
Files 41 43 +2
Lines 6535 6850 +315
==========================================
+ Hits 5122 5405 +283
- Misses 1413 1445 +32
Continue to review full report at Codecov.
|
extern int rlecMajorVersion; | ||
extern int rlecMinorVersion; | ||
extern int rlecPatchVersion; | ||
extern int rlecBuild; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do you need those here after they moved to utils?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because we use them in the onLoad function also...
return false; | ||
} | ||
} | ||
RedisModule_Log(ctx, "warning", "could not load %s from keyspace, key doesn't exist", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
notice that you log this message in RAI_GetModelFromKeyspace
please consolidate the error messages
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You right, the logging in RAI_GetModelFromKeyspace
should occur only in LITE version where we don't call VerifyKeyInThisShard
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so why we have it two places?
if (!VerifyKeyInThisShard(ctx, outkeys[i])) { // Relevant for enterprise cluster. | ||
RAI_SetError(err, RAI_EMODELRUN, | ||
"ERR CROSSSLOT Keys in request don't hash to the same slot"); | ||
return REDISMODULE_ERR; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
move this to the actual parsing phase. fail as soon as possible when you can
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can't because the parsing function is used from dag command as well (and in DAG we do not take the keys from key space...)
But ModelRunCtx_SetParams
is called only from "pure" AI.MODELEXECUTE.
… to depracted.c - Replace modelrun and modelset with modelexecute and modelstroe in onnx and pytorch tests. - Create a new test file (currently still empty) for testing deprcated APIs.
…Use "tests_commands" to test the new commands syntax (not for a specific backend), and test the deprecated commands only in "test_deprecated". Update AI.MODELSTORE documentation.
tests/flow/tests_onnx.py
Outdated
@@ -150,42 +74,30 @@ def test_onnx_modelrun_batchdim_mismatch(env): | |||
return | |||
|
|||
con = env.getConnection() | |||
model_pb = load_from_file('batchdim_mismatch.onnx') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove enitre test
src/backends/onnxruntime.c
Outdated
array_new_on_stack(const char *, 5, input_names) | ||
array_new_on_stack(const char *, 5, output_names) array_new_on_stack(OrtValue *, 5, inputs) | ||
array_new_on_stack(OrtValue *, 5, outputs) OrtTensorTypeAndShapeInfo *info = NULL; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
array_new_on_stack(const char *, 5, input_names) | |
array_new_on_stack(const char *, 5, output_names) array_new_on_stack(OrtValue *, 5, inputs) | |
array_new_on_stack(OrtValue *, 5, outputs) OrtTensorTypeAndShapeInfo *info = NULL; | |
int stack_arr_size = 5; | |
array_new_on_stack(const char *, stack_arr_size , input_names); | |
array_new_on_stack(const char *, stack_arr_size , output_names); | |
array_new_on_stack(OrtValue *, stack_arr_size , inputs); | |
array_new_on_stack(OrtValue *, stack_arr_size , outputs); | |
OrtTensorTypeAndShapeInfo *info = NULL; |
you also need to free inputs
and outputs
in the end
AI.MODELRUN command is now deprecated by AI.MODELEXECUTE.
In enterprise cluster, only AI.MODELEXECUTE will be available.