Skip to content

Commit

Permalink
Changes
Browse files Browse the repository at this point in the history
  • Loading branch information
Bharath Ramsundar authored and Bharath Ramsundar committed Jul 9, 2020
1 parent b10fd07 commit c4d396a
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 15 deletions.
3 changes: 1 addition & 2 deletions deepchem/feat/base_classes.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,7 @@ def featurize(self, datapoints, log_every_n=1000):
Returns
-------
A numpy array containing a featurized representation of
`datapoints`.
A numpy array containing a featurized representation of `datapoints`.
"""
datapoints = list(datapoints)
features = []
Expand Down
5 changes: 3 additions & 2 deletions deepchem/feat/graph_features.py
Original file line number Diff line number Diff line change
Expand Up @@ -352,9 +352,10 @@ class ConvMolFeaturizer(MolecularFeaturizer):
References
---------
.. [1] Duvenaud, David K., et al. "Convolutional networks on graphs for
learning molecular fingerprints." Advances in neural information processing
systems. 2015.
learning molecular fingerprints." Advances in neural information
processing systems. 2015.
Note
----
Expand Down
23 changes: 12 additions & 11 deletions deepchem/feat/smiles_featurizers.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,17 @@ def create_char_to_idx(filename,
verbose=False):
"""Creates a dictionary with character to index mapping.
Parameters
----------
filename: str,
Name of the file containing the SMILES strings
max_len: int, default 250
Maximum allowed length of the SMILES string
smiles_field: str, default smiles
Field indicating the SMILES strings int the file.
verbose: bool, default True
Whether to print the progress
"""
Parameters
----------
filename: str,
Name of the file containing the SMILES strings
max_len: int, default 250
Maximum allowed length of the SMILES string
smiles_field: str, default smiles
Field indicating the SMILES strings int the file.
verbose: bool, default True
Whether to print the progress
"""
smiles_df = pd.read_csv(filename)
char_set = set()
for smile in smiles_df[smiles_field]:
Expand Down Expand Up @@ -76,6 +76,7 @@ class SmilesToSeq(MolecularFeaturizer):

def __init__(self, char_to_idx, max_len=250, pad_len=10, **kwargs):
"""Initialize this class.
Parameters
----------
char_to_idx: dict
Expand Down

0 comments on commit c4d396a

Please sign in to comment.