Skip to content

Commit

Permalink
fix object array in emcee code (#2239)
Browse files Browse the repository at this point in the history
* fix object array

* Update CHANGELOG.md

* Update CHANGELOG.md
  • Loading branch information
ahartikainen authored May 7, 2023
1 parent d8a0ef2 commit 5cdcc6a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@

### Maintenance and fixes

- Fixes for creating numpy object array ([2233](https://github.com/arviz-devs/arviz/pull/2233) and [2239](https://github.com/arviz-devs/arviz/pull/2239))

### Deprecation

### Documentation
Expand Down
2 changes: 1 addition & 1 deletion arviz/data/io_emcee.py
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ def blobs_to_dict(self):
if int(self.emcee.__version__[0]) >= 3:
blobs = self.sampler.get_blobs()
else:
blobs = np.array(self.sampler.blobs)
blobs = np.array(self.sampler.blobs, dtype=object)
if (blobs is None or blobs.size == 0) and self.blob_names:
raise ValueError("No blobs in sampler, blob_names must be None")
if len(blobs.shape) == 2:
Expand Down

0 comments on commit 5cdcc6a

Please sign in to comment.