From 865e69dcbadb03646c74c7b2172f93d148f60139 Mon Sep 17 00:00:00 2001 From: hcji Date: Mon, 20 May 2019 10:52:19 +0800 Subject: [PATCH] check openbabel --- PyFingerprint/All_Fingerprint.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/PyFingerprint/All_Fingerprint.py b/PyFingerprint/All_Fingerprint.py index add8020..b9e1220 100644 --- a/PyFingerprint/All_Fingerprint.py +++ b/PyFingerprint/All_Fingerprint.py @@ -8,7 +8,10 @@ import numpy as np from PyFingerprint.CDK_Fingerprint import cdk_fingerprint from PyFingerprint.RDK_Fingerprint import rdk_fingerprint -from PyFingerprint.Babel_Fingerprint import ob_fingerprint +try: + from PyFingerprint.Babel_Fingerprint import ob_fingerprint +except: + print('Cannot import pybal, openbabel fingerprint cannot be used') def get_fingerprint(smi, fp_type, nbit=None, depth=None, output='bit'):