Package rdkit :: Package DataStructs :: Module cDataStructs :: Class IntSparseIntVect
[hide private]
[frames] | no frames]

Class IntSparseIntVect

 object --+    
          |    
??.instance --+
              |
             IntSparseIntVect

A container class for storing integer
values within a particular range.

The length of the vector is set at construction time.

As you would expect, _SparseIntVects_ support a set of binary operations
so you can do things like:
  Arithmetic:
  siv1 += siv2
  siv3 = siv1 + siv2
  siv1 -= siv3
  siv3 = siv1 - siv2
  "Fuzzy" binary operations:
  siv3 = siv1 & siv2  the result contains the smallest value in each entry
  siv3 = siv1 | siv2  the result contains the largest value in each entry

Elements can be set and read using indexing (i.e. siv[i] = 4 or val=siv[i])

Instance Methods [hide private]
 
GetLength(...)
GetLength( (IntSparseIntVect)arg1) -> int : Returns the length of the vector
 
GetNonzeroElements(...)
GetNonzeroElements( (IntSparseIntVect)arg1) -> dict : returns a dictionary of the nonzero elements
 
GetTotalVal(...)
GetTotalVal( (IntSparseIntVect)arg1 [, (bool)useAbs=False]) -> int : Get the sum of the values in the vector, basically L1 norm
 
ToBinary(...)
ToBinary( (IntSparseIntVect)arg1) -> object : returns a binary (pickle) representation of the vector
 
UpdateFromSequence(...)
UpdateFromSequence( (IntSparseIntVect)arg1, (AtomPairsParameters)arg2) -> None : update the vector based on the values in the list or tuple
 
__add__(...)
__add__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :
 
__and__(...)
__and__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :
 
__eq__(...)
__eq__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :
 
__getinitargs__(...)
__getinitargs__( (IntSparseIntVect)arg1) -> tuple :
 
__getitem__(...)
__getitem__( (IntSparseIntVect)arg1, (int)arg2) -> int : Get the value at a specified location
 
__iadd__(...)
__iadd__( (object)arg1, (IntSparseIntVect)arg2) -> object :
 
__idiv__(...)
__idiv__( (object)arg1, (int)arg2) -> object :
 
__imul__(...)
__imul__( (object)arg1, (int)arg2) -> object :
 
__init__(...)
__init__( (object)arg1, (int)arg2) -> None : Constructor
 
__isub__(...)
__isub__( (object)arg1, (IntSparseIntVect)arg2) -> object :
 
__ne__(...)
__ne__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :
 
__or__(...)
__or__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :
 
__reduce__(...)
helper for pickle
 
__setitem__(...)
__setitem__( (IntSparseIntVect)arg1, (int)arg2, (int)arg3) -> None : Set the value at a specified location
 
__sub__(...)
__sub__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :

Inherited from unreachable.instance: __new__

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  __instance_size__ = 32
  __safe_for_unpickling__ = True
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

GetLength(...)

 

GetLength( (IntSparseIntVect)arg1) -> int :
    Returns the length of the vector

    C++ signature :
        int GetLength(RDKit::SparseIntVect<int> {lvalue})

GetNonzeroElements(...)

 

GetNonzeroElements( (IntSparseIntVect)arg1) -> dict :
    returns a dictionary of the nonzero elements

    C++ signature :
        boost::python::dict GetNonzeroElements(RDKit::SparseIntVect<int> {lvalue})

GetTotalVal(...)

 

GetTotalVal( (IntSparseIntVect)arg1 [, (bool)useAbs=False]) -> int :
    Get the sum of the values in the vector, basically L1 norm

    C++ signature :
        int GetTotalVal(RDKit::SparseIntVect<int> {lvalue} [,bool=False])

ToBinary(...)

 

ToBinary( (IntSparseIntVect)arg1) -> object :
    returns a binary (pickle) representation of the vector

    C++ signature :
        boost::python::api::object ToBinary(RDKit::SparseIntVect<int>)

UpdateFromSequence(...)

 

UpdateFromSequence( (IntSparseIntVect)arg1, (AtomPairsParameters)arg2) -> None :
    update the vector based on the values in the list or tuple

    C++ signature :
        void UpdateFromSequence(RDKit::SparseIntVect<int> {lvalue},boost::python::api::object {lvalue})

__add__(...)
(Addition operator)

 

__add__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :

    C++ signature :
        _object* __add__(RDKit::SparseIntVect<int> {lvalue},RDKit::SparseIntVect<int>)

__and__(...)
(And operator)

 

__and__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :

    C++ signature :
        _object* __and__(RDKit::SparseIntVect<int> {lvalue},RDKit::SparseIntVect<int>)

__eq__(...)
(Equality operator)

 

__eq__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :

    C++ signature :
        _object* __eq__(RDKit::SparseIntVect<int> {lvalue},RDKit::SparseIntVect<int>)

__getinitargs__(...)

 

__getinitargs__( (IntSparseIntVect)arg1) -> tuple :

    C++ signature :
        boost::python::tuple __getinitargs__(RDKit::SparseIntVect<int>)

__getitem__(...)
(Indexing operator)

 

__getitem__( (IntSparseIntVect)arg1, (int)arg2) -> int :
    Get the value at a specified location

    C++ signature :
        int __getitem__(RDKit::SparseIntVect<int> {lvalue},int)

__iadd__(...)

 

__iadd__( (object)arg1, (IntSparseIntVect)arg2) -> object :

    C++ signature :
        _object* __iadd__(boost::python::back_reference<RDKit::SparseIntVect<int>&>,RDKit::SparseIntVect<int>)

__iadd__( (object)arg1, (int)arg2) -> object :

    C++ signature :
        _object* __iadd__(boost::python::back_reference<RDKit::SparseIntVect<int>&>,int)

__idiv__(...)

 

__idiv__( (object)arg1, (int)arg2) -> object :

    C++ signature :
        _object* __idiv__(boost::python::back_reference<RDKit::SparseIntVect<int>&>,int)

__imul__(...)

 

__imul__( (object)arg1, (int)arg2) -> object :

    C++ signature :
        _object* __imul__(boost::python::back_reference<RDKit::SparseIntVect<int>&>,int)

__init__(...)
(Constructor)

 

__init__( (object)arg1, (int)arg2) -> None :
    Constructor

    C++ signature :
        void __init__(_object*,int)

__init__( (object)arg1, (str)arg2) -> None :

    C++ signature :
        void __init__(_object*,std::string)

Overrides: object.__init__

__isub__(...)

 

__isub__( (object)arg1, (IntSparseIntVect)arg2) -> object :

    C++ signature :
        _object* __isub__(boost::python::back_reference<RDKit::SparseIntVect<int>&>,RDKit::SparseIntVect<int>)

__isub__( (object)arg1, (int)arg2) -> object :

    C++ signature :
        _object* __isub__(boost::python::back_reference<RDKit::SparseIntVect<int>&>,int)

__ne__(...)

 

__ne__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :

    C++ signature :
        _object* __ne__(RDKit::SparseIntVect<int> {lvalue},RDKit::SparseIntVect<int>)

__or__(...)
(Or operator)

 

__or__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :

    C++ signature :
        _object* __or__(RDKit::SparseIntVect<int> {lvalue},RDKit::SparseIntVect<int>)

__reduce__(...)

 
helper for pickle

Overrides: object.__reduce__
(inherited documentation)

__setitem__(...)
(Index assignment operator)

 

__setitem__( (IntSparseIntVect)arg1, (int)arg2, (int)arg3) -> None :
    Set the value at a specified location

    C++ signature :
        void __setitem__(RDKit::SparseIntVect<int> {lvalue},int,int)

__sub__(...)
(Subtraction operator)

 

__sub__( (IntSparseIntVect)arg1, (IntSparseIntVect)arg2) -> object :

    C++ signature :
        _object* __sub__(RDKit::SparseIntVect<int> {lvalue},RDKit::SparseIntVect<int>)