def get_shards(self, num, num_shards):
        """Shard number into evenly sized parts. `Remaining` values are put into the last shard.

        Parameters
        ----------
        num: int
            Number to shard

        num_shards: int
            Number of shards

        Returns
        -------
        List of length (num_shards or num_shards +1), depending on whether num is perfectly divisible by num_shards
        """
        assert num_shards > 0, "Invalid number of shards"
        num_per_shard = num // num_shards
        remaining_num = num % num_shards
        full_shards = num_shards * (num_per_shard > 0)
        if remaining_num == 0:
            return [num_per_shard] * full_shards
        else:
            return [num_per_shard] * full_shards + [remaining_num]
Shard number into evenly sized parts. `Remaining` values are put into the last shard.

        Parameters
        ----------
        num: int
            Number to shard

        num_shards: int
            Number of shards

        Returns
        -------
        List of length (num_shards or num_shards +1), depending on whether num is perfectly divisible by num_shards
        
tridet/evaluators/kitti_3d_evaluator.py