Skip to content

Commit

Permalink
fix: flake8 issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Kohulan committed Mar 13, 2023
1 parent 096dc67 commit fd596da
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions app/modules/decimermodules.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,14 @@
from decimer_segmentation import segment_chemical_structures_from_file
from DECIMER import predict_SMILES

def getPredictedSegments(path:str):

def getPredictedSegments(path: str):
"""Takes an image filepath and returns a set of paths of segmented images
Args:
input_path (str): path of an image
Returns:
segment_paths (list): a list of paths of segmented images.
segment_paths (list): a list of paths of segmented images.
"""
smiles_predicted = []
image_name = os.path.split(path)[1]
Expand All @@ -25,4 +26,4 @@ def getPredictedSegments(path:str):
smiles = predict_SMILES(segment_path)
smiles_predicted.append(smiles)
os.remove(segment_path)
return '.'.join(smiles_predicted)
return ".".join(smiles_predicted)

0 comments on commit fd596da

Please sign in to comment.