Return a dict of limits for EC2 instances only.
        This method should only be used internally by
        :py:meth:~.get_limits`.

        :rtype: dict

def _get_limits_instances(self):
        """
        Return a dict of limits for EC2 instances only.
        This method should only be used internally by
        :py:meth:~.get_limits`.

        :rtype: dict
        """
        # from: http://aws.amazon.com/ec2/faqs/
        # (On-Demand, Reserved, Spot)
        default_limits = (20, 20, 5)
        special_limits = {
            'c4.4xlarge': (10, 20, 5),
            'c4.8xlarge': (5, 20, 5),
            'c5.4xlarge': (10, 20, 5),
            'c5.9xlarge': (5, 20, 5),
            'c5.18xlarge': (5, 20, 5),
            'cg1.4xlarge': (2, 20, 5),
            'cr1.8xlarge': (2, 20, 5),
            'd2.4xlarge': (10, 20, 5),
            'd2.8xlarge': (5, 20, 5),
            'g2.2xlarge': (5, 20, 5),
            'g2.8xlarge': (2, 20, 5),
            'g3.4xlarge': (1, 20, 5),
            'g3.8xlarge': (1, 20, 5),
            'g3.16xlarge': (1, 20, 5),
            'h1.8xlarge': (10, 20, 5),
            'h1.16xlarge': (5, 20, 5),
            'hi1.4xlarge': (2, 20, 5),
            'hs1.8xlarge': (2, 20, 0),
            'i2.2xlarge': (8, 20, 0),
            'i2.4xlarge': (4, 20, 0),
            'i2.8xlarge': (2, 20, 0),
            'i2.xlarge': (8, 20, 0),
            'i3.2xlarge': (2, 20, 0),
            'i3.4xlarge': (2, 20, 0),
            'i3.8xlarge': (2, 20, 0),
            'i3.16xlarge': (2, 20, 0),
            'i3.large': (2, 20, 0),
            'i3.xlarge': (2, 20, 0),
            'm4.4xlarge': (10, 20, 5),
            'm4.10xlarge': (5, 20, 5),
            'm4.16xlarge': (5, 20, 5),
            'm5.4xlarge': (10, 20, 5),
            'm5.12xlarge': (5, 20, 5),
            'm5.24xlarge': (5, 20, 5),
            'p2.8xlarge': (1, 20, 5),
            'p2.16xlarge': (1, 20, 5),
            'p2.xlarge': (1, 20, 5),
            'p3.2xlarge': (1, 20, 5),
            'p3.8xlarge': (1, 20, 5),
            'p3.16xlarge': (1, 20, 5),
            'p3dn.24xlarge': (1, 20, 5),
            'r3.4xlarge': (10, 20, 5),
            'r3.8xlarge': (5, 20, 5),
            'r4.4xlarge': (10, 20, 5),
            'r4.8xlarge': (5, 20, 5),
            'r4.16xlarge': (1, 20, 5),
        }
        limits = {}
        for i_type in self._instance_types():
            key = 'Running On-Demand {t} instances'.format(
                t=i_type)
            lim = default_limits[0]
            if i_type in special_limits:
                lim = special_limits[i_type][0]
            limits[key] = AwsLimit(
                key,
                self,
                lim,
                self.warning_threshold,
                self.critical_threshold,
                limit_type='On-Demand instances',
                limit_subtype=i_type,
                ta_limit_name='On-Demand instances - %s' % i_type
            )
        # limit for ALL running On-Demand instances
        key = 'Running On-Demand EC2 instances'
        limits[key] = AwsLimit(
            key,
            self,
            default_limits[0],
            self.warning_threshold,
            self.critical_threshold,
            limit_type='On-Demand instances',
        )
        return limits