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

Create doc files for h5pyd #248

Open
wants to merge 36 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
b15cc0a
doc updates
jreadey Dec 27, 2024
961d874
fix file cloning
jreadey Dec 31, 2024
3913b73
fix flake8 errors
jreadey Dec 31, 2024
daa41b4
updated index
jreadey Dec 31, 2024
f4da456
support file attributes when cloning
jreadey Dec 31, 2024
ff57151
added docs for File
jreadey Jan 2, 2025
fb70d1e
Merge branch 'master' into rtd
jreadey Jan 3, 2025
9ae650e
update to File docs
jreadey Jan 6, 2025
272ab38
update for group docs
jreadey Jan 6, 2025
f7b0f8a
speed up test_file test
jreadey Jan 7, 2025
d70f634
fix flake8 error
jreadey Jan 7, 2025
b06a242
fix flake8 error
jreadey Jan 7, 2025
fda4def
updated group doc
jreadey Jan 7, 2025
64d5a4d
sort links client side
jreadey Jan 9, 2025
c1bc51b
fix test for h5py compat
jreadey Jan 9, 2025
4bb9f4c
first pass at objdb class
jreadey Jan 20, 2025
bd2a54b
added closed_group test
jreadey Jan 21, 2025
dd3fe0a
cleaned up debug print statements
jreadey Jan 21, 2025
62ecf1d
more cleanup
jreadey Jan 21, 2025
6f45089
add weakref for closed objs
jreadey Jan 21, 2025
712bcdb
updates for folders and dimscales
jreadey Jan 22, 2025
1763015
reorganize lowlevel and highlevel files
jreadey Jan 23, 2025
1c48eaf
update for dimsacale support
jreadey Jan 24, 2025
ea5a3cb
fix for objectid import
jreadey Jan 24, 2025
2a06a0d
added config get method
jreadey Jan 24, 2025
0e0a7b6
Merge branch 'master' into rtd
jreadey Jan 25, 2025
6c9fe24
no PUT on close by default
jreadey Jan 25, 2025
1981d94
added ACLs class
jreadey Jan 26, 2025
4549ab1
update comments for ACL class
jreadey Jan 26, 2025
b42b559
added limits to objdb
jreadey Jan 27, 2025
2cb2e30
fist pass at delayed updates
jreadey Jan 28, 2025
7b5c2c4
fix h5py compat errors
jreadey Jan 28, 2025
a9ca5f6
flush pending when max items exceeded
jreadey Jan 28, 2025
a42ee3b
fix flake8 error
jreadey Jan 28, 2025
cc56569
doc updates
jreadey Feb 3, 2025
987be23
doc updates
jreadey Feb 7, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion COPYING
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ h5serv Software Service, Libraries and Utilities
-----------------------------------------------------------------------------

HDF5 REST Server, Libraries and Utilities
Copyright 2014-2019 by The HDF Group.
Copyright by The HDF Group.

All rights reserved.

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ variables are needed to be defined:
To use "local" mode with S3, define these variables:

* ``AWS_S3_GATEWAY`` - AWS S3 endpoint, e.g.: ``https://s3.us-west-2.amazonaws.com``
* ``AWS_REGION`` - Region where the Lambda function is installed, e.g.: ``us-west-2``
* ``AWS_REGION`` - Region where the S3 bucket is located, e.g.: ``us-west-2``
* ``AWS_SECRET_ACCESS_KEY`` - Your AWS secret access AWS_SECRET_ACCESS_KEY
* ``AWS_ACCESS_KEY_ID`` - Your AWS access key ID

Expand Down
12 changes: 8 additions & 4 deletions docs/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Makefile for Sphinx documentation
#

# You can set these variables from the command line.
SPHINXOPTS = -W
Expand Down Expand Up @@ -84,17 +85,17 @@ qthelp:
@echo
@echo "Build finished; now you can run "qcollectiongenerator" with the" \
".qhcp project file in $(BUILDDIR)/qthelp, like this:"
@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/h5py.qhcp"
@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/h5pyd.qhcp"
@echo "To view the help file:"
@echo "# assistant -collectionFile $(BUILDDIR)/qthelp/h5py.qhc"
@echo "# assistant -collectionFile $(BUILDDIR)/qthelp/h5pyd.qhc"

devhelp:
$(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp
@echo
@echo "Build finished."
@echo "To view the help file:"
@echo "# mkdir -p $$HOME/.local/share/devhelp/h5py"
@echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/h5py"
@echo "# mkdir -p $$HOME/.local/share/devhelp/h5pyd"
@echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/h5pyd"
@echo "# devhelp"

epub:
Expand Down Expand Up @@ -174,3 +175,6 @@ pseudoxml:
$(SPHINXBUILD) -b pseudoxml $(ALLSPHINXOPTS) $(BUILDDIR)/pseudoxml
@echo
@echo "Build finished. The pseudo-XML files are in $(BUILDDIR)/pseudoxml."

show:
@python -m webbrowser -t "file://$(shell pwd)/_build/html/index.html"
106 changes: 99 additions & 7 deletions docs/conf.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,18 @@
# -*- coding: utf-8 -*-
#
# h5pyd documentation build configuration file,
#
# This file is execfile()d with the current directory set to its
# containing dir.
#
# Note that not all possible configuration values are present in this
# autogenerated file.
#
# All configuration values have a default; values that are commented out
# serve to show the default.

import sys
import os
from importlib import metadata

# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
Expand All @@ -21,12 +33,13 @@
'sphinx.ext.mathjax',
]

# intersphinx_mapping = {'low': ('https://api.h5py.org', None)}
intersphinx_mapping = {'low': ('https://api.h5py.org', None)}

extlinks = {
'issue': ('https://github.com/HDFGroup/h5pyd/issues/%s', 'GH'),
'pr': ('https://github.com/HDFGroup/h5pyd/pulls/%s', 'PR '),
'issue': ('https://github.com/h5py/h5pyd/issues/%s', 'GH%s'),
'pr': ('https://github.com/h5py/h5pyd/pull/%s', 'PR %s'),
}

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']

Expand All @@ -41,14 +54,14 @@

# General information about the project.
project = 'h5pyd'
copyright = '2014 The HDF Group'
copyright = '2017, The HDF Group'

# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
# built documents.
#
# The full version, including alpha/beta/rc tags.
release = metadata.version('h5pyd')
release = '0.20.0'
# The short X.Y version.
version = '.'.join(release.split('.')[:2])

Expand Down Expand Up @@ -95,7 +108,7 @@

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
html_theme = 'furo'
html_theme = 'sphinx_rtd_theme'

# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
Expand Down Expand Up @@ -174,3 +187,82 @@

# Output file base name for HTML help builder.
htmlhelp_basename = 'h5pyddoc'


# -- Options for LaTeX output ---------------------------------------------

latex_elements = {
# The paper size ('letterpaper' or 'a4paper').
# 'papersize': 'letterpaper',

# The font size ('10pt', '11pt' or '12pt').
# 'pointsize': '10pt',

# Additional stuff for the LaTeX preamble.
# 'preamble': '',
}

# Grouping the document tree into LaTeX files. List of tuples
# (source start file, target name, title,
# author, documentclass [howto, manual, or own class]).
latex_documents = [
('index', 'h5pyd.tex', 'h5pyd Documentation',
'The HDF Group', 'manual'),
]

# The name of an image file (relative to this directory) to place at the top of
# the title page.
# latex_logo = None

# For "manual" documents, if this is true, then toplevel headings are parts,
# not chapters.
# latex_use_parts = False

# If true, show page references after internal links.
# latex_show_pagerefs = False

# If true, show URL addresses after external links.
# latex_show_urls = False

# Documents to append as an appendix to all manuals.
# latex_appendices = []

# If false, no module index is generated.
# latex_domain_indices = True


# -- Options for manual page output ---------------------------------------

# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [
('index', 'h5pyd', 'h5pyd Documentation',
['The HDF Group'], 1)
]

# If true, show URL addresses after external links.
# man_show_urls = False


# -- Options for Texinfo output -------------------------------------------

# Grouping the document tree into Texinfo files. List of tuples
# (source start file, target name, title, author,
# dir menu entry, description, category)
texinfo_documents = [
('index', 'h5pyd', 'h5pyd Documentation',
'The HDF Group', 'h5pyd', 'One line description of project.',
'Miscellaneous'),
]

# Documents to append as an appendix to all manuals.
# texinfo_appendices = []

# If false, no module index is generated.
# texinfo_domain_indices = True

# How to display URL addresses: 'footnote', 'no', or 'inline'.
# texinfo_show_urls = 'footnote'

# If true, do not generate a @detailmenu in the "Top" node's menu.
# texinfo_no_detailmenu = False
56 changes: 5 additions & 51 deletions docs/config.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Configuring h5py
================
Configuring h5pyd
=================

Library configuration
---------------------
Expand All @@ -19,58 +19,12 @@ attributes:
is ("FALSE", "TRUE").

**track_order**
Whether to track dataset/group/attribute creation order. If
container creation order is tracked, its links and attributes
Controls whether links and attributes should be listed by
creation order (rather than alphanumerically). If
track_order is True when an object is created, its links and attributes
are iterated in ascending creation order (consistent with
``dict`` in Python 3.7+); otherwise in ascending alphanumeric
order. Global configuration value can be overridden for
particular container by specifying ``track_order`` argument to
:class:`h5py.File`, :meth:`h5py.Group.create_group`,
:meth:`h5py.Group.create_dataset`. The default is ``False``.


IPython
-------

H5py ships with a custom ipython completer, which provides object introspection
and tab completion for h5py objects in an ipython session. For example, if a
file contains 3 groups, "foo", "bar", and "baz"::

In [4]: f['b<TAB>
bar baz

In [4]: f['f<TAB>
# Completes to:
In [4]: f['foo'

In [4]: f['foo'].<TAB>
f['foo'].attrs f['foo'].items f['foo'].ref
f['foo'].copy f['foo'].iteritems f['foo'].require_dataset
f['foo'].create_dataset f['foo'].iterkeys f['foo'].require_group
f['foo'].create_group f['foo'].itervalues f['foo'].values
f['foo'].file f['foo'].keys f['foo'].visit
f['foo'].get f['foo'].name f['foo'].visititems
f['foo'].id f['foo'].parent

The easiest way to enable the custom completer is to do the following in an
IPython session::

In [1]: import h5py

In [2]: h5py.enable_ipython_completer()

It is also possible to configure IPython to enable the completer every time you
start a new session. For >=ipython-0.11, "h5py.ipy_completer" just needs to be
added to the list of extensions in your ipython config file, for example
:file:`~/.config/ipython/profile_default/ipython_config.py` (if this file does
not exist, you can create it by invoking `ipython profile create`)::

c = get_config()
c.InteractiveShellApp.extensions = ['h5py.ipy_completer']

For <ipython-0.11, the completer can be enabled by adding the following lines
to the :func:`main` in :file:`.ipython/ipy_user_conf.py`::

def main():
ip.ex('from h5py import ipy_completer')
ip.ex('ipy_completer.load_ipython_extension()')
Loading