         // dynamic allocator, in c++ (inference engine) we need to use
         // fixed-size workspace and create a static allocator.
         auto ws_tensors = SpconvOps::get_indice_gen_tensors_from_workspace(
-            workspace.raw_data(), KV, real_num_act_in,
-            is_subm ? real_num_act_in : out_inds_num_limit, max_act_out_theory,
-            is_subm, use_int64_hash_k, use_direct_table);
+            workspace.raw_data(), KV, static_num_act_in,
+            is_subm ? static_num_act_in : out_inds_num_limit,
+            max_act_out_theory, is_subm, use_int64_hash_k, use_direct_table);
         // pair can also have a upper bound.
         // !!!!!IMPORTANT!!!!!!! if you provide a static (padded) pair_fwd and
         // other indice data, the output layout is tight pair_fwd_correct =

        int num_act_out_real = std::get<1>(pair_res);

        tv::Tensor out_features =
            tv::empty({is_subm ? real_num_act_in : out_inds_num_limit, 64},
                      tv::float16, 0);
        auto out_features_real =
            out_features.slice_first_axis(0, num_act_out_real);

              weights, pair, indices_kernel_num, arch, out_features_real.dim(0),
              inverse, is_subm,
              static_cast<int>(tv::gemm::SparseConvAlgo::kNative),
              reinterpret_cast<std::uintptr_t>(stream), bias,
              1.0
              /*bias alpha, only used for leaky relu*/,
              0.0, tv::gemm::Activation::kReLU);
        } else {
          // regular conv use numbers in indices_kernel_num to perform gemm
          // so we don't need to slice.
