Lines Matching refs:c_stat
268 __constant__ BGPixelStat c_stat; variable
272 cudaSafeCall( cudaMemcpyToSymbol(c_stat, &stat, sizeof(BGPixelStat)) ); in setBGPixelStat()
313 if (!c_stat.is_trained_dyn_model(i, j)) in bgfgClassification()
321 for (int k = 0; k < N1cc && c_stat.PV_CC(i, j, k) > alpha2; ++k) in bgfgClassification()
323 OT v1 = c_stat.V1_CC<OT>(i, j, k); in bgfgClassification()
324 OT v2 = c_stat.V2_CC<OT>(i, j, k); in bgfgClassification()
333 Pv += c_stat.PV_CC(i, j, k); in bgfgClassification()
334 Pvb += c_stat.PVB_CC(i, j, k); in bgfgClassification()
338 Pb = c_stat.Pbcc(i, j); in bgfgClassification()
343 else if(c_stat.is_trained_st_model(i, j)) in bgfgClassification()
348 for (int k = 0; k < N1c && c_stat.PV_C(i, j, k) > alpha2; ++k) in bgfgClassification()
350 OT v = c_stat.V_C<OT>(i, j, k); in bgfgClassification()
356 Pv += c_stat.PV_C(i, j, k); in bgfgClassification()
357 Pvb += c_stat.PVB_C(i, j, k); in bgfgClassification()
360 Pb = c_stat.Pbc(i, j); in bgfgClassification()
413 const uchar is_trained_dyn_model = c_stat.is_trained_dyn_model(i, j); in updateBackgroundModel()
418 float Pbcc = c_stat.Pbcc(i, j); in updateBackgroundModel()
436 float PV_CC = c_stat.PV_CC(i, j, k); in updateBackgroundModel()
442 c_stat.PV_CC(i, j, k) = 0; in updateBackgroundModel()
443 c_stat.PVB_CC(i, j, k) = 0; in updateBackgroundModel()
447 c_stat.PV_CC(i, j, k) = PV_CC * (1.0f - alpha); in updateBackgroundModel()
448 c_stat.PVB_CC(i, j, k) = c_stat.PVB_CC(i, j, k) * (1.0f - alpha); in updateBackgroundModel()
450 OT v1 = c_stat.V1_CC<OT>(i, j, k); in updateBackgroundModel()
458 OT v2 = c_stat.V2_CC<OT>(i, j, k); in updateBackgroundModel()
481 c_stat.PV_CC(i, j, indx) = alpha; in updateBackgroundModel()
482 c_stat.PVB_CC(i, j, indx) = alpha; in updateBackgroundModel()
485 c_stat.V1_CC<OT>(i, j, indx) = Output<OT>::make(prevVal.x, prevVal.y, prevVal.z); in updateBackgroundModel()
486 c_stat.V2_CC<OT>(i, j, indx) = Output<OT>::make(curVal.x, curVal.y, curVal.z); in updateBackgroundModel()
491 c_stat.PV_CC(i, j, indx) += alpha; in updateBackgroundModel()
495 c_stat.PVB_CC(i, j, indx) += alpha; in updateBackgroundModel()
500 const float PV_CC_indx = c_stat.PV_CC(i, j, indx); in updateBackgroundModel()
501 const float PVB_CC_indx = c_stat.PVB_CC(i, j, indx); in updateBackgroundModel()
502 const OT V1_CC_indx = c_stat.V1_CC<OT>(i, j, indx); in updateBackgroundModel()
503 const OT V2_CC_indx = c_stat.V2_CC<OT>(i, j, indx); in updateBackgroundModel()
506 if (c_stat.PV_CC(i, j, k) <= PV_CC_indx) in updateBackgroundModel()
523 Pv_tmp1 = c_stat.PV_CC(i, j, l); in updateBackgroundModel()
524 c_stat.PV_CC(i, j, l) = Pv_tmp2; in updateBackgroundModel()
527 Pvb_tmp1 = c_stat.PVB_CC(i, j, l); in updateBackgroundModel()
528 c_stat.PVB_CC(i, j, l) = Pvb_tmp2; in updateBackgroundModel()
531 v1_tmp1 = c_stat.V1_CC<OT>(i, j, l); in updateBackgroundModel()
532 c_stat.V1_CC<OT>(i, j, l) = v1_tmp2; in updateBackgroundModel()
535 v2_tmp1 = c_stat.V2_CC<OT>(i, j, l); in updateBackgroundModel()
536 c_stat.V2_CC<OT>(i, j, l) = v2_tmp2; in updateBackgroundModel()
550 const float PV_CC = c_stat.PV_CC(i, j, k); in updateBackgroundModel()
555 sum2 += c_stat.PVB_CC(i, j, k); in updateBackgroundModel()
559 c_stat.is_trained_dyn_model(i, j) = 1; in updateBackgroundModel()
569 const float PV_CC = c_stat.PV_CC(i, j, k); in updateBackgroundModel()
573 … c_stat.PVB_CC(i, j, k) = (PV_CC - Pbcc * c_stat.PVB_CC(i, j, k)) / (1.0f - Pbcc); in updateBackgroundModel()
577 c_stat.Pbcc(i, j) = Pbcc; in updateBackgroundModel()
583 const float alpha = c_stat.is_trained_st_model(i, j) ? alpha2 : alpha3; in updateBackgroundModel()
585 float Pbc = c_stat.Pbc(i, j); in updateBackgroundModel()
602 float PV_C = c_stat.PV_C(i, j, k); in updateBackgroundModel()
606 c_stat.PV_C(i, j, k) = 0; in updateBackgroundModel()
607 c_stat.PVB_C(i, j, k) = 0; in updateBackgroundModel()
612 c_stat.PV_C(i, j, k) = PV_C * (1.0f - alpha); in updateBackgroundModel()
613 c_stat.PVB_C(i, j, k) = c_stat.PVB_C(i, j, k) * (1.0f - alpha); in updateBackgroundModel()
615 OT v = c_stat.V_C<OT>(i, j, k); in updateBackgroundModel()
636 c_stat.PV_C(i, j, indx) = alpha; in updateBackgroundModel()
637 c_stat.PVB_C(i, j, indx) = alpha; in updateBackgroundModel()
640 c_stat.V_C<OT>(i, j, indx) = Output<OT>::make(curVal.x, curVal.y, curVal.z); in updateBackgroundModel()
645 c_stat.PV_C(i, j, indx) += alpha; in updateBackgroundModel()
649 c_stat.PVB_C(i, j, indx) += alpha; in updateBackgroundModel()
654 const float PV_C_indx = c_stat.PV_C(i, j, indx); in updateBackgroundModel()
655 const float PVB_C_indx = c_stat.PVB_C(i, j, indx); in updateBackgroundModel()
656 OT V_C_indx = c_stat.V_C<OT>(i, j, indx); in updateBackgroundModel()
659 if (c_stat.PV_C(i, j, k) <= PV_C_indx) in updateBackgroundModel()
673 Pv_tmp1 = c_stat.PV_C(i, j, l); in updateBackgroundModel()
674 c_stat.PV_C(i, j, l) = Pv_tmp2; in updateBackgroundModel()
677 Pvb_tmp1 = c_stat.PVB_C(i, j, l); in updateBackgroundModel()
678 c_stat.PVB_C(i, j, l) = Pvb_tmp2; in updateBackgroundModel()
681 v_tmp1 = c_stat.V_C<OT>(i, j, l); in updateBackgroundModel()
682 c_stat.V_C<OT>(i, j, l) = v_tmp2; in updateBackgroundModel()
695 const float PV_C = c_stat.PV_C(i, j, k); in updateBackgroundModel()
700 sum2 += c_stat.PVB_C(i, j, k); in updateBackgroundModel()
704 c_stat.is_trained_st_model(i, j) = 1; in updateBackgroundModel()
714 const float PV_C = c_stat.PV_C(i, j, k); in updateBackgroundModel()
718 c_stat.PVB_C(i, j, k) = (PV_C - Pbc * c_stat.PVB_C(i, j, k)) / (1.0f - Pbc); in updateBackgroundModel()
721 c_stat.Pbc(i, j) = 1.0f - Pbc; in updateBackgroundModel()
725 c_stat.Pbc(i, j) = Pbc; in updateBackgroundModel()