Skip to content

Commit

Permalink
Zero-out all data
Browse files Browse the repository at this point in the history
  • Loading branch information
Stijn de Boer committed Aug 16, 2023
1 parent 4fe979e commit a13f907
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions pcntoolkit/model/hbr.py
Original file line number Diff line number Diff line change
Expand Up @@ -392,8 +392,13 @@ def estimate(self, X, y, batch_effects, **kwargs):
dummy_array = xarray.DataArray(data = np.zeros((len(chain), len(draw), 1)), coords = {'chain':chain, 'draw':draw,'empty':np.array([0])}, name=j)
self.idata.posterior[j] = dummy_array
self.vars_to_sample.append(j)
self.idata.observed_data = None
self.idata.constant_data = None

# zero-out all data
for i in self.idata.constant_data.data_vars:
self.idata.constant_data[i] *= 0
for i in self.idata.observed_data.data_vars:
self.idata.observed_data[i] *= 0

return self.idata

def predict(
Expand Down

0 comments on commit a13f907

Please sign in to comment.