Try to initialize this Semaphore instance with the given permit count.

        :param permits: (int), the given permit count.
        :return: (bool), ``true`` if initialization success.

def init(self, permits):
        """
        Try to initialize this Semaphore instance with the given permit count.

        :param permits: (int), the given permit count.
        :return: (bool), ``true`` if initialization success.
        """
        check_not_negative(permits, "Permits cannot be negative!")
        return self._encode_invoke(semaphore_init_codec, permits=permits)