-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Improve documentation #6307
Improve documentation #6307
Conversation
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
@@ -144,9 +144,7 @@ demonstrate the usage of Open3D Python interface. See ``examples/python`` for | |||
all Python examples. | |||
|
|||
.. note:: Open3D's Python tutorial utilizes some external packages: ``numpy``, | |||
``matplotlib``, ``opencv-python``. OpenCV is only used for reconstruction |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed missing shell script, as well as why Opencv is used (most users dont care about that) and also its easy to make this doc redundant when adding a new example where opencv is used (which might have already happened, I do need to check if numpy
, matplotlib
, opencv-python
are the only needed libs. Maybe adding etc. and some requirements_example.txt file would be better.
docker | ||
arm | ||
open3d_ml |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I moved open3d_ml to the bottom and arm above, with docker option closer to right after compilation, since new user would want to see how to get started with open3d faster. Let me know if this is alright or not.
@@ -88,3 +71,20 @@ Open3D: A Modern Library for 3D Data Processing | |||
python_example/pipelines/index | |||
python_example/utility/index | |||
python_example/visualization/index | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -405,7 +405,7 @@ | |||
"cell_type": "markdown", | |||
"metadata": {}, | |||
"source": [ | |||
"#### 1. Set Inputs and Parameters" | |||
"### 1. Set Inputs and Parameters" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
More info on why here - spatialaudio/nbsphinx#373 (comment)
P.S. Just noticed that the changes here are getting over written somehow when building docs. Will check and fix this commit.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Found my oversight. So, changes here are getting ignored because a pre-built t_icp_registration
notebook file is getting downloaded in make_docs.py
due to #4321.
Is the documentation still built without cuda on CI/CD?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think so. It is safe to keep the changes here now, we can study the best option regarding large notebook files in another PR.
…d-string.` This escapes vertical bars in bash tree output in pydocs but doesnt fix rendering in html.
544ee3e
to
fb7c71c
Compare
docs/conf.in.py
Outdated
def setup(app): | ||
app.connect("autodoc-skip-member", skip) | ||
app.connect("autodoc-process-docstring", escape_vertical_bars) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The issue comes from vertical bars in python docs which are from tree command - http://open3d.org/docs/release/python_api/open3d.data.RedwoodIndoorLivingRoom1.html. This change fixes the warning but the output is in html paragraph tag and new lines get ignored.
There was an alternate option to also remove output of tree command from docs, but I thought better keep tree output. Python docs are nicer, even if sphinx is not yet. Any ideas on how to fix for sphinx as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @saurabheights this issue actually originates from C++ code where the doc string is written, so the best way to fix this is there. We should not need a python postprocessing script here. The doscstring is rst and the rst syntax for literal text is:
https://www.sphinx-doc.org/en/master/usage/restructuredtext/basics.html#literal-blocks
(double colon and indented block)
Can you switch the pybind docstring to this syntax and see if that fixes this issue?
The pybind docstring is here:
https://github.com/isl-org/Open3D/blob/master/cpp/pybind/data/dataset.cpp#L979
Similarly, the C++ doxygen documentation is also mis-formatted:
Doxygen uses markdown syntax for code blocks:
https://www.doxygen.nl/manual/markdown.html#mddox_code_blocks
Here is the C++ documentation:
https://github.com/isl-org/Open3D/blob/master/cpp/open3d/data/Dataset.h#L726
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ssheorey Thanks for catching this. Learnt something new. Reverted my earlier postprocessing script and added suggested solution. Worked nicely for both sphinx and doxygen.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the kind contribution!
LGTM with minor change requests. I will also have to study how to render the tree structure correctly and will post my feedback later.
@@ -405,7 +405,7 @@ | |||
"cell_type": "markdown", | |||
"metadata": {}, | |||
"source": [ | |||
"#### 1. Set Inputs and Parameters" | |||
"### 1. Set Inputs and Parameters" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think so. It is safe to keep the changes here now, we can study the best option regarding large notebook files in another PR.
docs/conf.in.py
Outdated
def setup(app): | ||
app.connect("autodoc-skip-member", skip) | ||
app.connect("autodoc-process-docstring", escape_vertical_bars) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @saurabheights this issue actually originates from C++ code where the doc string is written, so the best way to fix this is there. We should not need a python postprocessing script here. The doscstring is rst and the rst syntax for literal text is:
https://www.sphinx-doc.org/en/master/usage/restructuredtext/basics.html#literal-blocks
(double colon and indented block)
Can you switch the pybind docstring to this syntax and see if that fixes this issue?
The pybind docstring is here:
https://github.com/isl-org/Open3D/blob/master/cpp/pybind/data/dataset.cpp#L979
Similarly, the C++ doxygen documentation is also mis-formatted:
Doxygen uses markdown syntax for code blocks:
https://www.doxygen.nl/manual/markdown.html#mddox_code_blocks
Here is the C++ documentation:
https://github.com/isl-org/Open3D/blob/master/cpp/open3d/data/Dataset.h#L726
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @saurabheights ! This looks good!
Type
Motivation and Context
Reviewing documentation and required cleanup. This PR only address some of the issues. Each issue is fixed in single commit, so should be easier to review commit-wise. More changes will follow along in a separate PR.
P.S. My end goal is to later on address issues like architecture documentation request, fix existing documentation issues as one fixed earlier here, etc.
Checklist:
python util/check_style.py --apply
to apply Open3D code styleto my code.
updated accordingly.
results (e.g. screenshots or numbers) here.
Description
I will add screenshot commit wise wherever necessary.
This change is