Skip to content

Commit

Permalink
Bddap/getnumatoms (#7)
Browse files Browse the repository at this point in the history
* Mol.GetNumAtoms, Mol.GetConformers, Conformer.GetNumAtoms

* version bump

* BuildFeatureFactoryFromString

* add RemoveHs
  • Loading branch information
bddap authored Aug 8, 2023
1 parent 1d6ea6b commit 33b4e56
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 14 deletions.
6 changes: 2 additions & 4 deletions rdkit-stubs/Chem/rdMolChemicalFeatures.pyi
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
from typing import Any, ClassVar

from typing import overload
from typing import Any, ClassVar, overload

class MolChemicalFeature:
@classmethod
Expand Down Expand Up @@ -50,5 +48,5 @@ class MolChemicalFeatureFactory:
def __reduce__(cls) -> Any: ...

def BuildFeatureFactory(*args, **kwargs) -> Any: ...
def BuildFeatureFactoryFromString(*args, **kwargs) -> Any: ...
def BuildFeatureFactoryFromString(arg1: str) -> MolChemicalFeatureFactory: ...
def GetAtomMatch(boost) -> Any: ...
11 changes: 4 additions & 7 deletions rdkit-stubs/Chem/rdchem.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -421,8 +421,7 @@ class Conformer:
def GetId(cls, RDKit) -> Any: ...
@classmethod
def GetIntProp(cls, *args, **kwargs) -> Any: ...
@classmethod
def GetNumAtoms(cls, RDKit) -> Any: ...
def GetNumAtoms(self) -> int: ...
@classmethod
def GetOwningMol(cls, RDKit) -> Any: ...
def GetPositions(
Expand Down Expand Up @@ -534,7 +533,7 @@ class Mol:
@classmethod
def GetAromaticAtoms(cls, boost) -> Any: ...
def GetAtomWithIdx(self, idx: int) -> Atom: ...
def GetAtoms(self) -> Iterable[Atom]: ...
def GetAtoms(self) -> Sequence[Atom]: ...
def GetAtomsMatchingQuery(self, arg2: QueryAtom) -> Sequence[Atom]: ...
@classmethod
def GetBondBetweenAtoms(cls, *args, **kwargs) -> Any: ...
Expand All @@ -545,14 +544,12 @@ class Mol:
@classmethod
def GetBoolProp(cls, *args, **kwargs) -> Any: ...
def GetConformer(self, id: int = -1) -> Conformer: ...
@classmethod
def GetConformers(cls, boost) -> Any: ...
def GetConformers(self) -> Sequence[Conformer]: ...
@classmethod
def GetDoubleProp(cls, *args, **kwargs) -> Any: ...
@classmethod
def GetIntProp(cls, *args, **kwargs) -> Any: ...
@classmethod
def GetNumAtoms(cls, RDKit) -> Any: ...
def GetNumAtoms(self, onlyHeavy: int = -1, onlyExplicit: bool = True) -> int: ...
@classmethod
def GetNumBonds(cls, RDKit) -> Any: ...
@classmethod
Expand Down
16 changes: 14 additions & 2 deletions rdkit-stubs/Chem/rdmolops.pyi
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from typing import Any, ClassVar, Sequence
from typing import Any, ClassVar, Sequence, overload

from rdkit.Chem.rdchem import Mol
from rdkit.Chem.rdMolDescriptors import AtomPairsParameters
Expand Down Expand Up @@ -247,7 +247,19 @@ def PathToSubmol(RDKit, boost) -> Any: ...
def PatternFingerprint(RDKit) -> Any: ...
def RDKFingerprint(*args, **kwargs) -> Any: ...
def RemoveAllHs(RDKit) -> Any: ...
def RemoveHs(RDKit) -> Any: ...
@overload
def RemoveHs(
mol: Mol,
implicitOnly: bool = False,
updateExplicitCount: bool = False,
sanitize: bool = True,
) -> Mol: ...
@overload
def RemoveHs(
mol: Mol,
params: RemoveHsParameters,
sanitize: bool = True,
) -> Mol: ...
def RemoveStereochemistry(RDKit) -> Any: ...
def RenumberAtoms(RDKit, boost) -> Any: ...
def ReplaceCore(mol, core, match) -> Any: ...
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def list_package_files() -> List[str]:

setup(
name="rdkit-stubs",
version="0.6",
version="0.7",
description="type stubs for rdkit",
author="Andrew Dirksen, Ryan Rightmer",
author_email="[email protected], [email protected]",
Expand Down

0 comments on commit 33b4e56

Please sign in to comment.