Skip to content
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

Docstrings #362

Merged
merged 12 commits into from
Jun 10, 2024
Merged

Docstrings #362

merged 12 commits into from
Jun 10, 2024

Conversation

christiangnrd
Copy link
Contributor

Add docstrings for all missing docstrings from the Metal module except for MtlDeviceVector and MtlDeviceMatrix as I am unfamiliar with them. Also adds docstrings for the storage mode structs from MTL as those will potentially be used.

I added very basic docstrings for the MTL and MPS modules, but I feel like not having them gives a more useful output (exported names and such).

See #358

Copy link
Member

@maleadt maleadt left a comment

Choose a reason for hiding this comment

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

This is great, thanks!

Some bike shedding below:

lib/mtl/storage_type.jl Outdated Show resolved Hide resolved
src/array.jl Outdated Show resolved Hide resolved
lib/mtl/storage_type.jl Outdated Show resolved Hide resolved
@christiangnrd
Copy link
Contributor Author

@maleadt I've addressed the comments.

Also, do you have any thoughts on whether the MTL and MPS docstrings should stay?

@maleadt
Copy link
Member

maleadt commented Jun 10, 2024

Also, do you have any thoughts on whether the MTL and MPS docstrings should stay?

Maybe a link to the Apple documentation, e.g., https://developer.apple.com/documentation/metalperformanceshaders? I considered suggesting an explanation on the different levels of wrappers (integrations, high-level wrappers, low-level wrappers), but that distinction isn't as clear in Metal.jl as it is in CUDA.jl where the low-level wrappers are auto-generated. Also, MTL doesn't really integrate with many interfaces. So it's probably not that valuable.

@christiangnrd
Copy link
Contributor Author

I pushed some improvements based on your suggestions to the MTL and MPS docstrings. This PR is ready for final review.

Copy link
Member

@maleadt maleadt left a comment

Choose a reason for hiding this comment

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

LGTM; couple of minor nits, let's merge this after.

docs/src/api/array.md Outdated Show resolved Hide resolved
lib/mps/MPS.jl Outdated Show resolved Hide resolved
lib/mtl/MTL.jl Outdated Show resolved Hide resolved
christiangnrd and others added 3 commits June 10, 2024 12:44
Co-authored-by: Tim Besard <[email protected]>
Co-authored-by: Tim Besard <[email protected]>
Co-authored-by: Tim Besard <[email protected]>
@christiangnrd
Copy link
Contributor Author

Done! I'll merge once tests pass or failures unrelated.

@maleadt maleadt merged commit 920ca04 into JuliaGPU:main Jun 10, 2024
1 check was pending
@maleadt
Copy link
Member

maleadt commented Jun 10, 2024

Done! I'll merge once tests pass or failures unrelated.

Oh sorry, didn't see your message. Well, we don't have doctests anyway, so this shouldn't matter hopefully 😅

@christiangnrd christiangnrd deleted the docstrings branch June 18, 2024 13:18
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