Skip to content

Commit 6cfb5ee

Browse files
Irina NicolaeIrina Nicolae
authored andcommitted
Remove circular import
1 parent d83814d commit 6cfb5ee

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/classifiers/utils.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,6 @@
77
from keras.models import model_from_json
88
from keras.optimizers import SGD
99

10-
from src.classifiers.bnn import BNN
11-
from src.classifiers.cnn import CNN
12-
from src.classifiers.mlp import MLP
13-
from src.classifiers.resnet import ResNet
1410
from src.layers.activations import BoundedReLU
1511
from src.utils import make_directory
1612

@@ -56,6 +52,11 @@ def load_classifier(file_path, weights_name="weights.h5"):
5652
:param weights_name: name of the file containing the weights
5753
:return: Classifier
5854
"""
55+
from src.classifiers.bnn import BNN
56+
from src.classifiers.cnn import CNN
57+
from src.classifiers.mlp import MLP
58+
from src.classifiers.resnet import ResNet
59+
5960
# Load json and create model
6061
with open(os.path.join(file_path, "model.json"), "r") as json_file:
6162
model_json = json_file.read()

0 commit comments

Comments
 (0)