Comments (4)
Thank you @robmoss! I have included the tutorials in the documentation and updated it on readthedocs.
from linfa.
Thank you for these comments.
- I have included the code in the examples using the literalinclude directive as suggested.
- That RCR example uses annealing, so it is normal for the loss to increase going from t=0 to t=1, instead of being reduced monotonically like for the other examples. I have added a comment so this is more clear.
- I tried the nbsphinx extension to render notebooks, but I get a large number of errors and warning, like these below:
WARNING: Block quote ends without a blank line; unexpected unindent.
ERROR: Unexpected indentation.
I'm trying to fix these problem. Have you seen them before?
from linfa.
Hi @daneschi
That RCR example uses annealing, so it is normal for the loss to increase going from t=0 to t=1, instead of being reduced monotonically like for the other examples. I have added a comment so this is more clear.
Thanks very much for the clarification, I was thoroughly confused!
I tried the nbsphinx extension to render notebooks, but I get a large number of errors and warning [...] Have you seen them before?
I haven't used the nbsphinx
extension myself, but I've just given it a try and found a few things:
- I needed to install
nbsphinx
(it's not listed indocs/requirements.txt
).- I also installed
ipython
(also not listed) to avoid some warnings about syntax highlighting. - I also removed the numpy version in
docs/requirements.txt
so that it could install a newer version — otherwise it would try to build numpy from source when using Python 3.10.
- I also installed
- The nbsphinx docs say to add the file names of your notebooks (without the .ipynb extension) to the
toctree
directive, rather than creating a .rst file and using theinclude
directive.- I suspect this was the cause of the "unexpected indentation" error message.
- When I added the notebook files to the
toctree
indocs/content/num_examples.rst
, sphinx complained that it couldn't find the referenced images (which are in./tutorial
).- I resolved this by moving the tutorial directory to
docs/content/tutorial
. - The notebook links in
README.md
would need to be updated.
- I resolved this by moving the tutorial directory to
The toctree
in docs/contents/num_examples.rst
now looks like this:
.. toctree::
:maxdepth: 2
tutorial/tutorial_linfa_2d
tutorial/tutorial_linfa_3d
trivial
...
After these steps, I was able to build the documentation and view the notebooks!
There is still one warning:
MissingIDFieldWarning: Cell is missing an id field, this will become a hard error in future nbformat versions. You may want to use `normalize()` on your notebooks before validations (available since nbformat 5.1.4). Previous versions of nbformat are fixing this issue transparently, and will stop doing so in the future.
validate(nb)
The good news is that this can be resolved relatively easily.
from linfa.
The tutorials look great!
from linfa.
Related Issues (15)
- update call to torch.meshgrid HOT 1
- create easy calls for scripts to run test cases and post-process results HOT 1
- finalize tutorial
- table and figure links in sphinx documentation HOT 1
- run test cases from command line HOT 1
- linfa.models is not included in built packages HOT 2
- Missing DOI in the paper HOT 6
- .idea folder HOT 1
- Contributing guide HOT 1
- comparison with other software packages HOT 4
- reproducibility HOT 1
- Running examples from the test suite HOT 2
- Plotting outputs with linfa.plot_res HOT 1
- CI test coverage ? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from linfa.