import tensorflow as tf

            dynamic_boffset=tf.constant([0, 0], dtype=tf.int32),
            add=True,
            transpose=transpose)
    else:
        y = sbnet_module.sparse_scatter(
            q,
            indices.bin_counts,
            indices.active_block_indices,
            x,
            dynamic_bsize=tf.constant(block_params.bsize_out, dtype=tf.int32),
            dynamic_bstride=tf.constant(block_params.bsize_out, dtype=tf.int32),
            dynamic_boffset=tf.constant([0, 0], dtype=tf.int32),
            add=True,
            transpose=transpose)
    return y


def sparse_conv2d_matmul(x, w, blk_indices, strides, padding):
    """
    Performs 2D convolution using matrix multiplication on a sparse feature map.
