-
Notifications
You must be signed in to change notification settings - Fork 188
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
Friendly "getting started" section that encompasses installation + running examples for new users? #1149
Comments
Maybe we can rename the section to "Getting started..." |
“Installation and Getting started” |
I don't know if I would advocate for telling users to
What if we suggested they add/install the Plots.jl package (since it's used by all examples) and asked users to follow along with the examples, either by copy pasting into the REPL or by copy pasting into a script in a text editor that they then We should also point users to https://www.julia-vscode.org/ in case an IDE is more comfortable for them. |
How do you recommend running the examples without |
Is there anything useful in the approach here https://youtu.be/GCj4xHUGZ0g?t=2555 their message was sort of that everything was really easy. |
I guess As for downloading the source or not, we currently put Should we move examples into a separate repo instead? |
Where should users go to find examples? If we think the examples are... bad examples... I think we should write new, better examples that we are proud to recommend to users. |
@ali-ramadhan does makes a fair point. But there will be some learning curve either way... The user should either know some git, or they should be familiar with Julia's syntax, or Julia's project management ( By the way Literate.jl provides ways to output the examples in different forms other than markdown for the docs. |
Docker should be also mentioned as another avenue for users to be able to get examples running... |
Yep. Somewhere in the top of the example in the documentation there should be these links... This is a primitive form of what I was thinking: https://fourierflows.github.io/GeophysicalFlowsDocumentation/dev/generated/twodnavierstokes_decaying/ But, after this discussion I realised that we should be post-processing to strip the notebooks from |
I personally think that the most effective and productive way to use Oceananigans (eg, play around, experiment, run new simulations, plot new things) is to copy / paste an existing script that does something similar to what you would like to do and modify it. So I think we need a solution that helps get users to this point as quickly and effortlessly as possible. Julia environments and the ambiguity between the Oceananigans installed as a package in a specific environment, and the source code, is certainly a major source of confusion. How about a link that downloads the examples and an environment (including Oceananigans, Plots and any other package needed to run the examples) in scripting-friendly format into a folder on the user's computer? |
We could possibly go the way of ClimateMachine and create a new folder called "tutorials" (code with extensive literate markup) and distinguish between these and "examples" (code that looks a lot more like a script we might write ourselves). |
I've seen that some other packages start their examples with something like
Could we add these to the top of our examples? This should work no matter what the user is doing (minimizing user pain). Most of the examples only need Oceananigans.jl, Plots.jl, and JLD2.jl/NCDatasets.jl. |
Not bad idea... |
I think it may not after the first call... (@v1.5) pkg> st
Status `~/.julia/environments/v1.5/Project.toml`
[777c4786] ClimateMachine v0.3.0-DEV `https://github.com/CliMA/ClimateMachine.jl.git#master`
[c27321d9] Glob v1.3.0
[033835bb] JLD2 v0.2.4
[ee78f7c6] Makie v0.11.1
[9e8cae18] Oceananigans v0.44.0
[91a5bcdd] Plots v1.6.12
[438e738f] PyCall v1.92.1
[d330b81b] PyPlot v2.9.0
[295af30f] Revise v3.1.3
julia> using Pkg
julia> @time Pkg.add("JLD2")
Resolving package versions...
No Changes to `~/.julia/environments/v1.5/Project.toml`
No Changes to `~/.julia/environments/v1.5/Manifest.toml`
0.545965 seconds (2.62 M allocations: 218.625 MiB, 14.30% gc time) |
I think that's a good idea. It fails after breaking API changes, but these typically don't persist long without a tag. |
OK, I'll do that on a separate PR for all examples. |
How about this proposal: we create two new directories called In the new What do you think @ali-ramadhan @navidcy ? |
I think having three directories in the repo (tutorials, examples, notebooks) feels somewhat cumbersome. Pretty sure we can get the same functionality you're proposing by generating the notebook and the stripped down example (both Literate.jl output) as part of the doc build (they would live the I guess this would be similar to what you guys do for FourierFlows.jl, e.g. https://fourierflows.github.io/GeophysicalFlowsDocumentation/dev/generated/twodnavierstokes_decaying/ (but we could just link to script + notebook instead of binder + nbviewer). |
I think that some people do clone the repo or click through github to look at files. This is the fastest way to see code. Our documentation may be amazing, but github is github and familiar to so many. It was observed earlier in this issue that the scripts in I think, if we don't want to put too many files in the source code, we should move tutorials somewhere else and keep the examples. The reason is that it means someone who only gets the source (doesn't look at online documentation) can get up and running quickly without having to go elsewhere. |
I guess to achieve what I'm suggesting, we'd move the current "examples" (which are tutorials) to We can also provide a separate list of |
The wiki is a step towards this: https://github.com/CliMA/Oceananigans.jl/wiki |
Actually, I think we can close this because we decided that the wiki is the right place for stuff like this, while the docs should focus on documenting the source code. |
The installation instructions are helpful for users who have downloaded julia. However, to run examples one needs to know how to use git, and also to have a text editor. Neither of these is necessarily trivial so it might be nice both to provide some simple explanations about how to get started with running the examples, and also to link to info about text editing, IDEs, and using github.
The text was updated successfully, but these errors were encountered: