MolScribe
MolScribe copied to clipboard
Running in a Jupyter notebook works nicely. Running as a .py causes my computer to freeze due to insane cpu usage.
Running MolScribe in a Jupyter notebook works nicely for me. Running the same code as a .py causes my computer to freeze due to insane cpu usage.
Running this piece of code on M1 Mac
model = MolScribe(f'{folder}/data/swin_base_char_aux_1m.pth', device=torch.device('cpu'))
def mol_scribe_osr(filepath):
output = model.predict_image_file(filepath, return_atoms_bonds=True, return_confidence=True)
return output['smiles']