Title: Scalar / Array mismatches in iosys not compatible with NumPy 1.24 · Issue #853 · python-control/python-control · GitHub
Open Graph Title: Scalar / Array mismatches in iosys not compatible with NumPy 1.24 · Issue #853 · python-control/python-control
X Title: Scalar / Array mismatches in iosys not compatible with NumPy 1.24 · Issue #853 · python-control/python-control
Description: Discussed in #852 Originally posted by codeFighter2022 January 26, 2023 Hi, First of all, thanks a lot for this amazing toolbox! I think, I found a bug, or a suggestion for improvement, when running the prey example: https://python-contr...
Open Graph Description: Discussed in #852 Originally posted by codeFighter2022 January 26, 2023 Hi, First of all, thanks a lot for this amazing toolbox! I think, I found a bug, or a suggestion for improvement, when runnin...
X Description: Discussed in #852 Originally posted by codeFighter2022 January 26, 2023 Hi, First of all, thanks a lot for this amazing toolbox! I think, I found a bug, or a suggestion for improvement, when runnin...
Opengraph URL: https://github.com/python-control/python-control/issues/853
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Scalar / Array mismatches in iosys not compatible with NumPy 1.24","articleBody":"### Discussed in https://github.com/python-control/python-control/discussions/852\r\n\r\n\u003cdiv type='discussions-op-text'\u003e\r\n\r\n\u003csup\u003eOriginally posted by **codeFighter2022** January 26, 2023\u003c/sup\u003e\r\nHi,\r\nFirst of all, thanks a lot for this amazing toolbox!\r\n\r\nI think, I found a bug, or a suggestion for improvement, when running the prey example:\r\nhttps://python-control.readthedocs.io/en/0.9.3.post2/iosys.html#example\r\n\r\nWhen I run the code of the prey example, in particular the linearization, \r\n`lin_predprey = ct.linearize(io_predprey, xeq, 0)`\r\nI get the following error\r\n`ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (2,) + inhomogeneous part.`\r\n\r\nAfter analyzing the code, I think the origin of the error is that in predprey_rhs() dH is of type numpy arrary, while dL is not. \r\n\r\nI think others ones are much deeper in the code than me. That is why I post this topic instead of a pull request. \r\n\r\nMaybe a type check with dummy input/output data already solves these kind of issues when initializing the constructor. I think such a feature could save people some time.\r\n\r\nBest,\r\ncodeFighter2022\r\n\r\nPython: 3.810\r\nControl: 0.9.3.post2\r\nI installed the toolbox via pip\r\n\u003c/div\u003e","author":{"url":"https://github.com/bnavigator","@type":"Person","name":"bnavigator"},"datePublished":"2023-01-26T20:50:32.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":3},"url":"https://github.com/853/python-control/issues/853"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:e596ce6d-e06d-03c9-6479-e9e9d5487f68 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | DA4E:243963:62A160:8CC59A:697A1D1C |
| html-safe-nonce | 6e6bce7c14dec926c133e78f9ebb816b3a633ec9a2fdbf900e5a37722e4ac5f6 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEQTRFOjI0Mzk2Mzo2MkExNjA6OENDNTlBOjY5N0ExRDFDIiwidmlzaXRvcl9pZCI6IjY4NjAwODI5OTE0MjMxNjc3NzIiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 1c078424d994588958871e4c5838aaa2af2939603c118e13553c0153f7d76cd7 |
| hovercard-subject-tag | issue:1558760456 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python-control/python-control/853/issue_layout |
| twitter:image | https://opengraph.githubassets.com/1a63d698fed6c5be4938e113139103f258bc0066bdcb399f2e0d6ae03e74678b/python-control/python-control/issues/853 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/1a63d698fed6c5be4938e113139103f258bc0066bdcb399f2e0d6ae03e74678b/python-control/python-control/issues/853 |
| og:image:alt | Discussed in #852 Originally posted by codeFighter2022 January 26, 2023 Hi, First of all, thanks a lot for this amazing toolbox! I think, I found a bug, or a suggestion for improvement, when runnin... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | bnavigator |
| hostname | github.com |
| expected-hostname | github.com |
| None | 24021c77440f544078f9cbe80d78a2fb16ccff65fca92deda9da3c51d1cdc5fc |
| turbo-cache-control | no-preview |
| go-import | github.com/python-control/python-control git https://github.com/python-control/python-control.git |
| octolytics-dimension-user_id | 2285872 |
| octolytics-dimension-user_login | python-control |
| octolytics-dimension-repository_id | 22791752 |
| octolytics-dimension-repository_nwo | python-control/python-control |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 22791752 |
| octolytics-dimension-repository_network_root_nwo | python-control/python-control |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 2841ead760bbcdca99003cf970f91348178160c3 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width