Skip to content

Experiments - Add two of notebooks/experiments/*.ipynb files to project documentation#119

Merged
jnareb merged 6 commits into
mainfrom
experiments
Apr 4, 2025
Merged

Experiments - Add two of notebooks/experiments/*.ipynb files to project documentation#119
jnareb merged 6 commits into
mainfrom
experiments

Conversation

@jnareb
Copy link
Copy Markdown
Member

@jnareb jnareb commented Apr 4, 2025

Add two notebooks comparing annotations generated with the PatchScope project with manual annotations in two publications: HaPy-Bug and Herbold et. al to the project documentation available at https://ncusi.github.io/PatchScope/, cleaning first of those beforehand.

Jupyter Notebooks are added to the MkDocs-generated documentation with the help of the mkdocs-jupyter plugin.

jnareb added 6 commits April 3, 2025 12:07
… et al.

Remove the whole "Comparison with line annotations in the Herbold et al.
dataset (hunk_labels.json only)" section, as the comparison there was
based on a faoulty assumption on how changes are represented in the
hunk_labels.json data file, and how that representation corresponds
to the diff of changes.

The correct comparison is present in a separate notebook, namely
experiments/02-compare_annotations_Herbold.ipynb

The state before the change was tagged with 'notebooks-before_experiments_cleanup'.
…g.ipynb

Adjust name of the notebook, now that it consists only of the "Comparison with
line annotations in the HaPy-Bug dataset" section.
This new dependency is intended to make it possible to add Jupyter Notebooks
directly to the MkDocs navigation.

Of the two MkDocs plugins created for this purpose, namely
mkdocs-jupyter and mknotebooks, the first (and the one selected)
seems to be actively maintained.
Copy those Jupyter Notebooks that would be used in project documentation
to newly created docs/notebooks/ directory.

The copy might be replaced later with symlinks.
One think that I have noticed that is missing is support for LaTeX-based
math equations, like $D_{BIP}$.

There is https://github.com/mitya57/python-markdown-math extension for
Python-Markdown, but is there some plugin or extension like that for
MkDocs?
In commit 11c6d01 (docs: Copy relevant Jupyter Notebooks to docs/notebooks/,
2025-04-03) two *.ipynb files were copied to docs/notebooks.  Instead of
taking space by duplicated files, use symbolic links.
@jnareb jnareb added the documentation Improvements or additions to documentation label Apr 4, 2025
@jnareb jnareb self-assigned this Apr 4, 2025
@dagshub
Copy link
Copy Markdown

dagshub Bot commented Apr 4, 2025

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 4, 2025

Coverage

Coverage Report
FileStmtsMissCoverMissing
src/diffannotator
   __init__.py00100% 
   annotate.py82313683%52, 75–76, 85, 92, 101–104, 106–108, 110, 368–369, 373–374, 376, 413, 415–417, 419, 421–423, 425–426, 428–430, 528, 531, 534–535, 577, 727, 756, 799–801, 805, 836, 914, 1149, 1163–1166, 1168, 1172–1175, 1177, 1354, 1357, 1526, 1528, 1565, 1582–1583, 1669, 1672, 1784–1785, 1787, 1804, 1846–1847, 1859–1860, 1863, 1878, 1893–1894, 1925, 1988, 1999, 2025, 2035, 2037, 2046–2050, 2054–2058, 2060, 2086, 2173, 2187, 2189–2190, 2192–2194, 2196, 2198–2200, 2202–2203, 2205, 2207, 2221, 2224, 2239–2241, 2247, 2260, 2269, 2277, 2280, 2350, 2356, 2358–2359, 2372, 2381–2386, 2500–2501, 2504–2505, 2509, 2554
   config.py50786%52–56, 58, 93
   gather_data.py3445384%61, 87, 91, 93, 101, 106, 108, 121, 129, 161, 228–229, 232–233, 236, 239, 248, 259–265, 288–289, 309–310, 325, 343, 365–366, 531, 535, 568, 696, 709, 711, 714, 718, 720, 758, 784–785, 838, 890, 1076, 1108–1112, 1116
   generate_patches.py38392%102, 104, 126
   languages.py1011684%170, 173, 176, 179, 182, 186, 217–218, 230, 249, 261, 263–264, 267, 273, 311
   lexer.py29293%87–88
src/diffannotator/utils
   __init__.py00100% 
   git.py4878582%107, 233, 316, 318, 321–322, 324, 326–329, 331–333, 335–337, 342–343, 347, 349–350, 354–356, 358–359, 361–362, 364–365, 367, 475–476, 479, 516, 526, 529–531, 537, 568, 572, 579, 603, 616, 671, 753, 800, 807, 837, 841, 845, 885, 887, 898, 903, 908, 999–1000, 1047–1049, 1052–1053, 1087, 1091, 1157, 1162, 1164, 1167–1168, 1170, 1229–1230, 1344, 1346, 1369–1370, 1382, 1384, 1396–1397, 1431, 1445
TOTAL187230283% 

Tests Skipped Failures Errors Time
81 8 💤 0 ❌ 0 🔥 8.524s ⏱️

@jnareb jnareb merged commit 55c3bb9 into main Apr 4, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant