-
Notifications
You must be signed in to change notification settings - Fork 25
Small cleanups in meshmode.mesh #486
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
meshmode/mesh/__init__.py
Outdated
| IndexArray: TypeAlias = np.ndarray[tuple[int], np.dtype[np.integer[Any]]] | ||
|
|
||
| VertexIndices: TypeAlias = np.ndarray[tuple[int, int], np.dtype[np.integer[Any]]] | ||
| VertexArray: TypeAlias = np.ndarray[tuple[int, int], np.dtype[np.floating[Any]]] | ||
|
|
||
| NodesArray: TypeAlias = np.ndarray[tuple[int, int, int], np.dtype[np.floating[Any]]] | ||
| RefNodesArray: TypeAlias = np.ndarray[tuple[int, int], np.dtype[np.floating[Any]]] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've been pretty liberal with adding these local type aliases, mostly because Sphinx expands them, so they don't really show up anywhere. Is it worth starting a meshmode.typing for something like this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wouldn't mind that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tried that, but between Sphinx not being very helpful and a bunch of extra imports in places.. I went with using optype instead. What do you think?
Updated all the uses in meshmode.mesh and meshmode.mesh.processing to use optype instead and it looks pretty good.
f7df0dd to
102887b
Compare
|
Thanks! |
102887b to
9bf3f14
Compare
Started removing
RUF067yesterday and ended up doing some more random cleanup inmeshmode.mesh. The commits should be self-explanatory.