Skip to content

data_overide_3d #19

Merged
fmalatino merged 10 commits intofmalatino:mainfrom
mlee03:data_override_3d
Mar 28, 2025
Merged

data_overide_3d #19
fmalatino merged 10 commits intofmalatino:mainfrom
mlee03:data_override_3d

Conversation

@mlee03
Copy link
Copy Markdown
Collaborator

@mlee03 mlee03 commented Mar 27, 2025

This PR adds in data_override_3d

@mlee03 mlee03 requested review from bensonr and fmalatino March 27, 2025 20:03
fieldname: str,
data_shape: list[int],
data_type: Any,
is_in: int | None = None,
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Maybe use Optional[int] = None instead

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I will change the "optional" arguments to be is_in : int = None.

raise RuntimeError("Data_override, datatype not supported")

ndata = np.prod(data_shape)

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Why not use the data_handling module?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

The data_handling module is outdated and could be more pythonic such as,
data_c, data_t = convert(types.c_int, data)

They will be upgraded and used throughout.

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Can you add that as an issue so we can track and assign it?

@mlee03
Copy link
Copy Markdown
Collaborator Author

mlee03 commented Mar 28, 2025

ready for review again. I made some additional changes such as removing from pyfms import ... and just import pyfms for code clarity

@fmalatino fmalatino merged commit 6a28647 into fmalatino:main Mar 28, 2025
1 check passed
mlee03 pushed a commit to mlee03/pyFMS_old that referenced this pull request Apr 21, 2025
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.

2 participants