Skip to content

Commit c2615a3

Browse files
removed logging during fitting
1 parent 02218ca commit c2615a3

File tree

1 file changed

+2
-9
lines changed

1 file changed

+2
-9
lines changed

diffxpy/testing/tests.py

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,7 @@ def _fit(
127127
}
128128

129129
if isinstance(training_strategy, str) and training_strategy.lower() == 'bfgs':
130+
assert False, "depreceated"
130131
lib_size = np.zeros(data.shape[0])
131132
if noise_model == "nb" or noise_model == "negative_binomial":
132133
estim = Estim_BFGS(X=data, design_loc=design_loc, design_scale=design_scale,
@@ -143,8 +144,6 @@ def _fit(
143144
else:
144145
raise ValueError('base.test(): `noise_model="%s"` not recognized.' % noise_model)
145146

146-
logging.getLogger("diffxpy").info("Fitting model...")
147-
logging.getLogger("diffxpy").debug(" * Assembling input data...")
148147
input_data = InputDataGLM(
149148
data=data,
150149
design_loc=design_loc,
@@ -155,7 +154,6 @@ def _fit(
155154
feature_names=gene_names,
156155
)
157156

158-
logging.getLogger("diffxpy").debug(" * Set up Estimator...")
159157
constructor_args = {}
160158
if batch_size is not None:
161159
constructor_args["batch_size"] = batch_size
@@ -173,22 +171,17 @@ def _fit(
173171
dtype=dtype,
174172
**constructor_args
175173
)
176-
177-
logging.getLogger("diffxpy").debug(" * Initializing Estimator...")
178174
estim.initialize()
179175

180-
logging.getLogger("diffxpy").debug(" * Run estimation...")
181-
# training:
176+
# Training:
182177
if callable(training_strategy):
183178
# call training_strategy if it is a function
184179
training_strategy(estim)
185180
else:
186181
estim.train_sequence(training_strategy=training_strategy)
187182

188183
if close_session:
189-
logging.getLogger("diffxpy").debug(" * Finalize estimation...")
190184
estim.finalize()
191-
logging.getLogger("diffxpy").debug(" * Model fitting done.")
192185

193186
return estim
194187

0 commit comments

Comments
 (0)