コード例 #1
0
ファイル: _base.py プロジェクト: jlabroquere/pagmo
    def __init__(self, *args):
        """
		Base problem constructor. It must be called from within the derived class constructor __init__()
		
		USAGE: super(derived_class_name,self).__init__(dim, i_dim, n_obj, c_dim, c_ineq_dim, c_tol)
		
		* dim: Total dimension of the decision vector
		* i_dim: dimension of the integer part of decision vector (the integer part is placed at the end of the decision vector). Defaults to 0
		* n_obj: number of objectives. Defaults to 1
		* c_dim: total dimension of the constraint vector. dDefaults to 0
		* c_ineq_dim: dimension of the inequality part of the constraint vector (inequality const. are placed at the end of the decision vector). Defaults to 0
		* c_tol: constraint tolerance. When comparing individuals, this tolerance is used to decide whether a constraint is considered satisfied.
		"""
        if len(args) == 0:
            raise ValueError("Cannot initialise base problem without parameters for the constructor.")
        _base.__init__(self, *args)
コード例 #2
0
ファイル: _base.py プロジェクト: YS-L/pagmo
    def __init__(self, *args):
        """
		Base problem constructor. It must be called from within the derived class constructor __init__()
		
		USAGE: super(derived_class_name,self).__init__(dim, i_dim, n_obj, c_dim, c_ineq_dim, c_tol)
		
		* dim: Total dimension of the decision vector
		* i_dim: dimension of the integer part of decision vector (the integer part is placed at the end of the decision vector). Defaults to 0
		* n_obj: number of objectives. Defaults to 1
		* c_dim: total dimension of the constraint vector. dDefaults to 0
		* c_ineq_dim: dimension of the inequality part of the constraint vector (inequality const. are placed at the end of the decision vector). Defaults to 0
		* c_tol: constraint tolerance. When comparing individuals, this tolerance is used to decide whether a constraint is considered satisfied.
		"""
        if len(args) == 0:
            raise ValueError(
                "Cannot initialise base problem without parameters for the constructor."
            )
        _base.__init__(self, *args)
コード例 #3
0
ファイル: _base_class.py プロジェクト: irwenqiang/pagmo
	def __init__(self,*args):
		if len(args) == 0:
			raise ValueError("Cannot initialise base problem without parameters for the constructor.")
		_base.__init__(self,*args)