Title: Improve handling of spcforc output · Issue #84 · open-lasso-python/lasso-python · GitHub
Open Graph Title: Improve handling of spcforc output · Issue #84 · open-lasso-python/lasso-python
X Title: Improve handling of spcforc output · Issue #84 · open-lasso-python/lasso-python
Description: 🐛 Describe the bug spcforce output columns in pandas dataframe are not loaded when using as_df method. 🔢 To Reproduce binout = Binout(file_path) binout.read('spcforc') ['time', 'x_resultant', 'y_resultant', 'z_resultant', 'spc_mids', 'da...
Open Graph Description: 🐛 Describe the bug spcforce output columns in pandas dataframe are not loaded when using as_df method. 🔢 To Reproduce binout = Binout(file_path) binout.read('spcforc') ['time', 'x_resultant', 'y_re...
X Description: 🐛 Describe the bug spcforce output columns in pandas dataframe are not loaded when using as_df method. 🔢 To Reproduce binout = Binout(file_path) binout.read('spcforc') ['time', '...
Opengraph URL: https://github.com/open-lasso-python/lasso-python/issues/84
X: @github
Domain: patch-diff.githubusercontent.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Improve handling of spcforc output","articleBody":"**🐛 Describe the bug**\nspcforce output columns in pandas dataframe are not loaded when using as_df method.\n\n**🔢 To Reproduce**\nbinout = Binout(file_path)\nbinout.read('spcforc') \n\u003e\u003e\u003e ['time', 'x_resultant', 'y_resultant', 'z_resultant', 'spc_mids', 'date', 'x_force', 'build_id', 'moment_ids', 'x_moment', 'spc_ids', 'revision', 'y_force', 'y_moment', 'force_ids', 'z_force', 'misc', 'z_moment', 'title', 'version']\n\nin binout.py, as_df method:\n\n if data.ndim \u003e 1:\n df = pd.DataFrame(index=time_pdi)\n\n if args[0] == \"rcforc\":\n ids = [\n (str(i) + \"m\") if j else (str(i) + \"s\")\n for i, j in zip(self.read(\"rcforc\", \"ids\"), self.read(\"rcforc\", \"side\"))\n ]\n else:\n ids = self.read(*args[:-1], \"ids\")\n\nspcforc does not have 'ids' output (rather, force_ids and moment_ids; or - might not always have, not sure about it)\n\nSuggested solution is to add the following condition (similar to as already present for rcforc)\n elif args[0] == \"spcforc\":\n if args[-1].endswith(\"force\"):\n ids = self.read(*args[:-1], \"force_ids\")\n elif args[-1].endswith(\"moment\"):\n ids = self.read(*args[:-1], \"moment_ids\")\n else:\n ids = self.read(*args[:-1], \"ids\")\n\nTo have the following snippet:\n\n # create dataframe\n if data.ndim \u003e 1:\n df = pd.DataFrame(index=time_pdi)\n\n if args[0] == \"rcforc\":\n ids = [\n (str(i) + \"m\") if j else (str(i) + \"s\")\n for i, j in zip(self.read(\"rcforc\", \"ids\"), self.read(\"rcforc\", \"side\"))\n ]\n elif args[0] == \"spcforc\":\n if args[-1].endswith(\"force\"):\n ids = self.read(*args[:-1], \"force_ids\")\n elif args[-1].endswith(\"moment\"):\n ids = self.read(*args[:-1], \"moment_ids\")\n else:\n ids = self.read(*args[:-1], \"ids\")\n \n else:\n ids = self.read(*args[:-1], \"ids\")\n\n**🖥️ Setup**\n - OS: Windows 11\n - LS-Dyna R14.0\n\n\n","author":{"url":"https://github.com/marcodesiderio","@type":"Person","name":"marcodesiderio"},"datePublished":"2025-07-29T18:02:04.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/84/lasso-python/issues/84"}
| 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:845557de-b386-f14f-ba97-b9197d1209dd |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | EC02:103635:12E30E:191448:698DAE21 |
| html-safe-nonce | 5aabbe96e26b06bcd30eeae7fea87defe866ca4497499e3ba3a6df4b1a34f449 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFQzAyOjEwMzYzNToxMkUzMEU6MTkxNDQ4OjY5OERBRTIxIiwidmlzaXRvcl9pZCI6IjU0NzM5ODA0MTA4NzMzNTk5MDUiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 9901f53aa8b9dc20a113823fbeb7a6f434b93b4d33337d5d66eb2f1d5eb309e2 |
| hovercard-subject-tag | issue:3274506615 |
| 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/open-lasso-python/lasso-python/84/issue_layout |
| twitter:image | https://opengraph.githubassets.com/c76657c96de562e4eb7a179e21be04cbe86138a060fb24fa65c5c5dcadc8f0f2/open-lasso-python/lasso-python/issues/84 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/c76657c96de562e4eb7a179e21be04cbe86138a060fb24fa65c5c5dcadc8f0f2/open-lasso-python/lasso-python/issues/84 |
| og:image:alt | 🐛 Describe the bug spcforce output columns in pandas dataframe are not loaded when using as_df method. 🔢 To Reproduce binout = Binout(file_path) binout.read('spcforc') ['time', 'x_resultant', 'y_re... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | marcodesiderio |
| hostname | github.com |
| expected-hostname | github.com |
| None | 8c7947c0c592efeab6162b9909ad11fa43bff8b0cb5ff43273dc25e41979d43e |
| turbo-cache-control | no-preview |
| go-import | github.com/open-lasso-python/lasso-python git https://github.com/open-lasso-python/lasso-python.git |
| octolytics-dimension-user_id | 114169132 |
| octolytics-dimension-user_login | open-lasso-python |
| octolytics-dimension-repository_id | 540129748 |
| octolytics-dimension-repository_nwo | open-lasso-python/lasso-python |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 540129748 |
| octolytics-dimension-repository_network_root_nwo | open-lasso-python/lasso-python |
| 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 | b22a9fbf4dea601ec149a9e5362e0558df79b505 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width