86b670cf47e4442af93bfe1621ca4a9ef1220757,arviz/utils/xarray_utils.py,PyStanToXarray,to_xarray,#PyStanToXarray#,393
Before Change
for key in self.varnames:
var_dtype = {key : "int"} if key in dtypes else {}
vals = fit.extract(key, dtypes=var_dtype, permuted=False)[key]
if len(vals.shape) == 1:
vals = np.expand_dims(vals, axis=1)
vals = np.swapaxes(vals, 0, 1)
dims_str = base_dims + self.dims[key]
After Change
data = xr.Dataset(coords=self.coords)
base_dims = ["chain", "draw"]
extract = fit.extract(pars=self.varnames,
dtypes=dtypes,
permuted=False)
for key, vals in extract.items():
if len(vals.shape) == 1:
vals = np.expand_dims(vals, axis=1)
vals = np.swapaxes(vals, 0, 1)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances
Project Name: arviz-devs/arviz
Commit Name: 86b670cf47e4442af93bfe1621ca4a9ef1220757
Time: 2018-07-31
Author: ari.hartikainen@aalto.fi
File Name: arviz/utils/xarray_utils.py
Class Name: PyStanToXarray
Method Name: to_xarray
Project Name: J535D165/recordlinkage
Commit Name: 4a24e4e36ee175aef54b92eb03e08a2be7811a96
Time: 2018-03-10
Author: jonathandebruinhome@gmail.com
File Name: recordlinkage/datasets/febrl.py
Class Name:
Method Name: _febrl_links
Project Name: arviz-devs/arviz
Commit Name: 86b670cf47e4442af93bfe1621ca4a9ef1220757
Time: 2018-07-31
Author: ari.hartikainen@aalto.fi
File Name: arviz/utils/xarray_utils.py
Class Name: PyStanToXarray
Method Name: default_varnames_coords_dims