Skip to content

Conversation

sciunto
Copy link
Contributor

@sciunto sciunto commented Sep 18, 2012

Hi,

As far I understand, the docstrings at the top of files are not included in the documentation.
For instance, the netcdf.py (in scipy.io) contains Notes and examples which are not in the doc
(I checked there: http://docs.scipy.org/doc/scipy/reference/tutorial/io.html?highlight=netcdf#module-scipy.io.netcdf and http://docs.scipy.org/doc/scipy/reference/generated/scipy.io.netcdf.netcdf_file.html#scipy.io.netcdf.netcdf_file)

Since notes and examples document the usage of netcdf_file, I moved these sections in the docstring of this class.

Please, correct me if I'm wrong.

@rgommers
Copy link
Member

Good idea to move this, it indeed otherwise doesn't show up in the built docs.

The part in Notes on "There are three main sections" seems to contradict to some extent the first paragraph of the class docstring.

The paragraph on PyNIO and pynetcdf can remain in the module docstringI think, with a single sentence in the class docstring on this topic being enough. An addition to that part is that this module is derived from and almost equal to the standalone package pupynere. The part on Scientific is not relevant anymore probably.

@sciunto
Copy link
Contributor Author

sciunto commented Sep 20, 2012

I added some corrections from your remarks.

About the part in Notes on "There are three main sections" , I see the point. The original author uses the same word (attributes) to designate two differents things. At the top of the docstring, attribute means attribute of an (python) object while attribute in the notes refers to the sementic used in netcdf specifications (see http://www.unidata.ucar.edu/software/netcdf/docs/netcdf.html#Dataset-Components).
Both sentences are right IMHO. The module implements the netcdf attributes as illustrated in examples (units is an attribute).
To be accurate, netcdf attribute handling is implemented in netcdf_variable(). This is suggested by the following the NetCDF data structure list. Split the notes into two just for that would be less efficient I think.
Nevertheless, if you have a better idea to clarify that, i'm all ears. :)

I agree with your second point. I left the sentence on scientific.io api in the module docstring.

Thanks for the careful review.

@rgommers
Copy link
Member

You're right, the attributes usage is slightly confusing but correct. Not sure it's easy to change, so I'll merge this now.

rgommers pushed a commit that referenced this pull request Sep 21, 2012
DOC: reorganized netcdf docstring.
@rgommers rgommers merged commit 01d3251 into scipy:master Sep 21, 2012
@rgommers
Copy link
Member

Merged, thanks!

mckib2 added a commit to mckib2/scipy that referenced this pull request Apr 16, 2020
73c0126cf Merge pull request #23 from ERGO-Code/master
097b4ca2d Return slack and lagrange multipliers.
2aa374196 Merge pull request scipy#319 from ERGO-Code/BoxedColumnLp
c39fdf9b6 Correct objective and clearer identifier names
80166edf1 Fixed bug for BoxedColumnMaxLp
3dd1bf266 Remove hardcoded c++11 compiler flags
58cf13eea Remove hard coded compiler optimization flags

git-subtree-dir: scipy/optimize/_highs
git-subtree-split: 73c0126cfee6db7330b812603acc024f26ef77b8
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