NNPDF / pineappl

PineAPPL is not an extension of APPLgrid
https://nnpdf.github.io/pineappl/
GNU General Public License v3.0
12 stars 3 forks source link

Write Monte Carlo interface documentation #141

Open cschwan opened 2 years ago

cschwan commented 2 years ago

After talking to @scarlehoff I get the feeling that our documentation can be improved in quite a few places. Specifically, we should at least

alecandido commented 2 years ago
  • in Grid::fill and also in other functions/methods we should make clear that whenever we have to give indices for order, bin and lumi that are given in exactly this order, to resemble the obl subcommand of pineappl;

Just as a feedback, and with no further purpose: I actually find this order a bit unnatural, since for me bin is the most external object, the one surviving all the convolutions. I would have found more natural bol sorting, but at this point that's it, and it's not worth to switch.

felixhekhorn commented 2 years ago

I can try to help with this, but let me repeat what I said in https://github.com/N3PDF/pineappl/issues/130#issuecomment-1077661355

  • it remains unclear to me what is your maintained source of documentation: repo (meaning this file), inline (meaning pineappl tutorial), docs (on docs.rs), website

@AleCandido can you please remind me of the Rust project you showed to me where the documentation was as source code and hence on docs.rs?

alecandido commented 2 years ago

It is simple, it's just ndarray. You can find examples here:

https://github.com/rust-ndarray/ndarray/tree/master/src/doc

But I'd actually improve over this: instead of docs.rs containing markdown, I'd make docs.md, and docs.rs embed the content of docs.md through a macro.

alecandido commented 2 years ago

Something like this:

https://doc.rust-lang.org/std/macro.include_str.html

cschwan commented 2 years ago

Something that I now feel quite comfortable with is to host common mark documents in the repository and point to it (on github) in the --help documentation of pineappl. For instance, for pineappl remap --help I removed the text that explained REMAPPING, which now points to https://github.com/N3PDF/pineappl/blob/master/docs/cli-reference.md, which has the same text. There I also explain a few other things that are quite handy.

felixhekhorn commented 2 years ago

Maybe you want a README in https://github.com/N3PDF/pineappl/tree/master/docs ?

alecandido commented 2 years ago

A README.md (but even README, README.txt, and README.rst) would be rendered by GitHub in the folder view, like for the top-level one. So, I agree with @felixhekhorn

cschwan commented 2 years ago

That's probably a good idea. Right now there's the top-level README which points to the various documents, but it might better to have it close to the other documents.

cschwan commented 1 year ago

@aykhuss you might be interested in some of the items in https://github.com/NNPDF/pineappl/issues/141#issue-1224111192.