Skip to content

Set dtype=object when creating Ragged array#12092

Merged
d61h6k4 merged 13 commits intomainfrom
ENG-45-numpy-deprecation-issue
Mar 6, 2023
Merged

Set dtype=object when creating Ragged array#12092
d61h6k4 merged 13 commits intomainfrom
ENG-45-numpy-deprecation-issue

Conversation

@d61h6k4
Copy link
Copy Markdown
Contributor

@d61h6k4 d61h6k4 commented Feb 28, 2023

To create an array from a list of inhomogeneous objects, explicitly set the type to object

Since NumPy 1.24 numpy raises ValueError when creating a Ragged array numpy/numpy#22004

Proposed changes:

  • ...

Status (please check what you already did):

  • added some tests for the functionality
  • updated the documentation
  • updated the changelog (please check changelog for instructions)
  • reformat files using black (please check Readme for instructions)

In order to create an array from list of inhomogeneus objects explicitly
dtype to object

Since numpy 1.24 numpy raises ValueError when creating Ragged array
numpy/numpy#22004
@d61h6k4 d61h6k4 requested a review from a team February 28, 2023 10:25
Comment thread rasa/utils/tensorflow/model_data.py Outdated
@d61h6k4 d61h6k4 requested review from Shmuma and ancalita March 3, 2023 13:22
Comment thread poetry.lock Outdated
Comment thread pyproject.toml
Comment thread rasa/utils/tensorflow/model_data.py Outdated
Comment thread rasa/utils/tensorflow/model_data.py Outdated
@d61h6k4 d61h6k4 requested a review from ancalita March 6, 2023 11:17
Copy link
Copy Markdown
Member

@ancalita ancalita left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

Comment thread rasa/utils/tensorflow/model_data.py Outdated
Co-authored-by: Anca Lita <[email protected]>
@varunshankar varunshankar self-requested a review March 6, 2023 11:31
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 6, 2023

🚀 A preview of the docs have been deployed at the following URL: https://12092--rasahq-docs-rasa-v2.netlify.app/docs/rasa

@d61h6k4 d61h6k4 enabled auto-merge (squash) March 6, 2023 13:24
@d61h6k4 d61h6k4 merged commit 0dddbdb into main Mar 6, 2023
@d61h6k4 d61h6k4 deleted the ENG-45-numpy-deprecation-issue branch March 6, 2023 18:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants