@@ -72,7 +72,7 @@ static void Dag_LoadInputsToCurrentOp(RedisAI_RunInfo *rinfo, RAI_DagOp *current
72
72
}
73
73
74
74
for (uint i = 0 ; i < n_outkeys ; i ++ ) {
75
- RAI_ExecutionCtx_AddOuputPlaceholder (currentOp -> ectx );
75
+ RAI_ExecutionCtx_AddOutputPlaceholder (currentOp -> ectx );
76
76
}
77
77
}
78
78
@@ -260,7 +260,7 @@ void RedisAI_DagRunSession_ScriptRun_Step(RedisAI_RunInfo *rinfo, RAI_DagOp *cur
260
260
RAI_ExecutionCtx_AddInput (currentOp -> ectx , inputTensors [i ]);
261
261
}
262
262
for (uint i = 0 ; i < n_outkeys ; i ++ ) {
263
- RAI_ExecutionCtx_AddOuputPlaceholder (currentOp -> ectx );
263
+ RAI_ExecutionCtx_AddOutputPlaceholder (currentOp -> ectx );
264
264
}
265
265
}
266
266
@@ -574,44 +574,15 @@ int RedisAI_DagRun_Reply(RedisModuleCtx *ctx, RedisModuleString **argv, int argc
574
574
break ;
575
575
}
576
576
577
- case REDISAI_DAG_CMD_MODELRUN : {
578
- rinfo -> dagReplyLength ++ ;
579
- struct RedisAI_RunStats * rstats = NULL ;
580
- RAI_GetRunStats (currentOp -> runkey , & rstats );
581
- if (currentOp -> result == REDISMODULE_ERR ) {
582
- RAI_SafeAddDataPoint (rstats , 0 , 1 , 1 , 0 );
583
- RedisModule_ReplyWithError (ctx , currentOp -> err -> detail_oneline );
584
- dag_error = 1 ;
585
- } else if (currentOp -> result == -1 ) {
586
- RedisModule_ReplyWithSimpleString (ctx , "NA" );
587
- } else {
588
- RAI_Tensor * t = NULL ;
589
- if (RAI_ExecutionCtx_NumOutputs (currentOp -> ectx ) > 0 ) {
590
- t = RAI_ExecutionCtx_GetOutput (currentOp -> ectx , 0 );
591
- }
592
- int batch_size = 0 ;
593
- if (t ) {
594
- batch_size = RAI_TensorDim (t , 0 );
595
- }
596
- RAI_SafeAddDataPoint (rstats , currentOp -> duration_us , 1 , 0 , batch_size );
597
- RedisModule_ReplyWithSimpleString (ctx , "OK" );
598
- }
599
- break ;
600
- }
601
-
577
+ case REDISAI_DAG_CMD_MODELRUN :
602
578
case REDISAI_DAG_CMD_SCRIPTRUN : {
603
579
rinfo -> dagReplyLength ++ ;
604
- struct RedisAI_RunStats * rstats = NULL ;
605
- RAI_GetRunStats (currentOp -> runkey , & rstats );
606
580
if (currentOp -> result == REDISMODULE_ERR ) {
607
- RAI_SafeAddDataPoint (rstats , 0 , 1 , 1 , 0 );
608
581
RedisModule_ReplyWithError (ctx , currentOp -> err -> detail_oneline );
609
582
dag_error = 1 ;
610
583
} else if (currentOp -> result == -1 ) {
611
584
RedisModule_ReplyWithSimpleString (ctx , "NA" );
612
585
} else {
613
- int batch_size = 1 ;
614
- RAI_SafeAddDataPoint (rstats , currentOp -> duration_us , 1 , 0 , batch_size );
615
586
RedisModule_ReplyWithSimpleString (ctx , "OK" );
616
587
}
617
588
break ;
0 commit comments