Skip to content

Commit 8d8ffaf

Browse files
authored
Links update (#251)
* Updated desc for odd size in readme * fixed language * Added odd size issue to issues description in tutorial: * Removed unnecessary line causing a warning message * Updated instructions for skipping notebook execution * Updated absolute links to relative links in documentation * added hidden tags to dataset download cells * Updated link checker' * Updated link checker' * Updated link checker' * Updated link checker' * Updated link checker' * Updated tutorial * Revert accidentally hidden cells * Updated tqdm to tqdm.auto * Updated docs requirements * Updated tutorial notebooks * Updated tags
1 parent 972f060 commit 8d8ffaf

File tree

11 files changed

+72
-46
lines changed

11 files changed

+72
-46
lines changed

.github/workflows/links.yml

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,15 @@ jobs:
1717
find . -name '*.html' -delete
1818
- run: |
1919
find . -name '*.md' -exec pandoc -i {} -o {}.html \;
20-
- uses: anishathalye/proof-html@v1
20+
- uses: anishathalye/proof-html@v2
2121
with:
2222
directory: .
23+
check_html: false
2324
check_favicon: false
24-
empty_alt_ignore: true
25-
url_ignore_re: |
26-
^https:\/\/twitter.com\/CleanlabAI
25+
ignore_missing_alt: true
26+
ignore_empty_alt: true
27+
tokens: |
28+
{"https://github.com": "${{ secrets.GITHUB_TOKEN }}"}
29+
swap_urls: |
30+
{"^(\\..*)\\.md(#?.*)$": "\\1.md.html\\2",
31+
"^(https://github\\.com/.*)#.*$": "\\1"}

DEVELOPMENT.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ pip install -r docs/requirements.txt
123123
sphinx-build docs/source cleanvision-docs
124124
```
125125

126-
**Note for faster build**: Executing the Jupyter Notebooks (i.e., the .ipynb files) that make up some portion of the docs, such as the tutorials, takes a long time. If you want to skip rendering these, set the environment variable `SKIP_NOTEBOOKS=1`. You can either set this using `export SKIP_NOTEBOOKS=1`
126+
**Note for faster build**: Executing the Jupyter Notebooks (i.e., the .ipynb files) that make up some portion of the docs, such as the tutorials, takes a long time. If you want to skip rendering these, add `nbsphinx_execute = 'never' to [sphinx configuration](docs/source/conf.py)
127127

128128
4. To view the docs open the file `cleanvision-docs/index.html` file in a browser.
129129

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ In any collection of image files (most [formats](https://pillow.readthedocs.io/e
8989
| 6 | Light | Irregularly bright images (*over*exposed) | light | ![](https://raw.githubusercontent.com/cleanlab/assets/master/cleanvision/example_issue_images/light.jpg) |
9090
| 7 | Grayscale | Images lacking color | grayscale | ![](https://raw.githubusercontent.com/cleanlab/assets/master/cleanvision/example_issue_images/grayscale.jpg) |
9191
| 8 | Odd Aspect Ratio | Images with an unusual aspect ratio (overly skinny/wide) | odd_aspect_ratio | ![](https://raw.githubusercontent.com/cleanlab/assets/master/cleanvision/example_issue_images/odd_aspect_ratio.jpg) |
92-
| 9 | Odd Size | Images that are abnormally large or small | odd_size | <img src="https://raw.githubusercontent.com/cleanlab/assets/master/cleanvision/example_issue_images/odd_size.png" width=20% height=20%> |
92+
| 9 | Odd Size | Images that are abnormally large or small compared to the rest of the dataset | odd_size | <img src="https://raw.githubusercontent.com/cleanlab/assets/master/cleanvision/example_issue_images/odd_size.png" width=20% height=20%> |
9393

9494
CleanVision supports Linux, macOS, and Windows and runs on Python 3.7+.
9595

docs/requirements.txt

Lines changed: 11 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,12 @@
1-
sphinx==5.1.1
2-
sphinx-tabs==3.4.1
3-
nbsphinx==0.8.8
4-
autodocsumm==0.2.9
1+
sphinx==7.1.2
2+
sphinx-tabs==3.4.5
3+
nbsphinx==0.9.3
4+
autodocsumm==0.2.12
55
sphinx-multiversion==0.2.4
6-
sphinx-copybutton==0.5.0
7-
sphinxcontrib-katex==0.8.6
8-
sphinx-autodoc-typehints==1.19.2
9-
furo==2022.06.21
10-
numpy>=1.20.0
11-
pandas>=1.1.5
12-
Pillow>=9.3
13-
matplotlib>=3.4
14-
tqdm>=4.53.0
15-
imagehash>=4.2.0
16-
datasets>=2.7.0
17-
torchvision>=0.12.0
18-
ipykernel==6.8.0
19-
ipywidgets==7.6.5
6+
sphinx-copybutton==0.5.2
7+
sphinxcontrib-katex==0.9.9
8+
sphinx-autodoc-typehints==1.25.2
9+
furo==2023.09.10
10+
ipykernel==6.29.0
11+
ipywidgets==8.1.1
12+
ipython==8.0.1

docs/source/conf.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,6 @@
7777

7878
html_title = ""
7979
html_theme = "furo"
80-
html_static_path = ["_static"]
8180
html_logo = "https://raw.githubusercontent.com/cleanlab/assets/master/cleanlab/cleanlab_logo_only.png"
8281

8382
html_theme_options = {

docs/source/faq.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ CleanVision is independent of any machine learning tasks as it directly works on
1010
2. **Can I check for specific issues in my dataset?**
1111

1212

13-
Yes, you can specify issues like ``light`` or ``blurry`` in the issue_types argument when calling ``Imagelab.find_issues``
13+
Yes, you can specify issues like ``light`` or ``blurry`` in the issue_types argument when calling :py:meth:`~cleanvision.imagelab.Imagelab.find_issues`
1414

1515
.. code-block:: python3
1616

docs/source/index.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
Documentation
66
=======================================
77

8-
CleanVision automatically detects various issues in image datasets, such as images that are: (near) duplicates, blurry,
8+
CleanVision automatically detects various issues in your image data, such as images that are: (near) duplicates, blurry,
99
over/under-exposed, etc. This data-centric AI package is designed as a quick first step for any computer vision project
1010
to find problems in your dataset, which you may want to address before applying machine learning.
1111

@@ -120,9 +120,9 @@ CleanVision works smoothly with Torchvision datasets too:
120120
121121
Additional Resources
122122
--------------------
123-
- Get started with our `Example Notebook <https://cleanvision.readthedocs.io/en/latest/tutorials/tutorial.html>`_
124-
- Explore more `Example Notebooks <https://github.com/cleanlab/cleanvision-examples>`_
125-
- Learn how to contribute in the `Contribution Guide <https://github.com/cleanlab/cleanvision/blob/main/CONTRIBUTING.md>`_
123+
- Get started with `Starter Tutorial <tutorials/tutorial.ipynb>`_.
124+
- View more `code examples <https://github.com/cleanlab/cleanvision-examples>`_ that demonstrate how to use CleanVision on various datasets.
125+
- Interested in contributing to CleanVision? Check out our `Contribution Guide <https://github.com/cleanlab/cleanvision/blob/main/CONTRIBUTING.md>`_ to get started.
126126

127127

128128
.. toctree::

docs/source/tutorials/custom_issue_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import numpy as np
44
import pandas as pd
55
from PIL import Image
6-
from tqdm import tqdm
6+
from tqdm.auto import tqdm
77

88
from cleanvision.dataset.base_dataset import Dataset
99
from cleanvision.issue_managers import register_issue_manager

docs/source/tutorials/huggingface_dataset.ipynb

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,19 @@
4444
"from cleanvision import Imagelab"
4545
]
4646
},
47+
{
48+
"cell_type": "code",
49+
"execution_count": null,
50+
"metadata": {
51+
"nbsphinx": "hidden"
52+
},
53+
"outputs": [],
54+
"source": [
55+
"import warnings\n",
56+
"\n",
57+
"warnings.filterwarnings(\"ignore\")"
58+
]
59+
},
4760
{
4861
"cell_type": "markdown",
4962
"metadata": {},
@@ -60,7 +73,9 @@
6073
{
6174
"cell_type": "code",
6275
"execution_count": null,
63-
"metadata": {},
76+
"metadata": {
77+
"tags": []
78+
},
6479
"outputs": [],
6580
"source": [
6681
"dataset = load_dataset(\"cats_vs_dogs\", split=\"train\")"
@@ -184,7 +199,7 @@
184199
"metadata": {},
185200
"outputs": [],
186201
"source": [
187-
"imagelab.issues"
202+
"imagelab.issues.head()"
188203
]
189204
},
190205
{
@@ -243,7 +258,7 @@
243258
"cell_type": "markdown",
244259
"metadata": {},
245260
"source": [
246-
"**For more detailed guide on how to use CleanVision, check the [tutorial notebook](https://github.com/cleanlab/cleanvision/blob/main/docs/source/tutorials/tutorial.ipynb).**"
261+
"**For more detailed guide on how to use CleanVision, check the** [tutorial notebook](tutorial.ipynb)."
247262
]
248263
}
249264
],
@@ -263,7 +278,7 @@
263278
"name": "python",
264279
"nbconvert_exporter": "python",
265280
"pygments_lexer": "ipython3",
266-
"version": "3.8.5"
281+
"version": "3.11.7"
267282
}
268283
},
269284
"nbformat": 4,

docs/source/tutorials/torchvision_dataset.ipynb

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,9 +70,12 @@
7070
"cell_type": "code",
7171
"execution_count": null,
7272
"id": "3d207006",
73-
"metadata": {},
73+
"metadata": {
74+
"tags": []
75+
},
7476
"outputs": [],
7577
"source": [
78+
"%%capture\n",
7679
"train_set = CIFAR10(root=\"./\", download=True)\n",
7780
"test_set = CIFAR10(root=\"./\", train=False, download=True)"
7881
]
@@ -200,7 +203,7 @@
200203
"metadata": {},
201204
"outputs": [],
202205
"source": [
203-
"imagelab.issues"
206+
"imagelab.issues.head()"
204207
]
205208
},
206209
{
@@ -264,7 +267,7 @@
264267
"id": "75912aea",
265268
"metadata": {},
266269
"source": [
267-
"**For more detailed guide on how to use CleanVision, check the [tutorial notebook](https://github.com/cleanlab/cleanvision/blob/main/docs/source/tutorials/tutorial.ipynb).**"
270+
"**For more detailed guide on how to use CleanVision, check the** [tutorial notebook](tutorial.ipynb)."
268271
]
269272
}
270273
],
@@ -284,7 +287,7 @@
284287
"name": "python",
285288
"nbconvert_exporter": "python",
286289
"pygments_lexer": "ipython3",
287-
"version": "3.11.0"
290+
"version": "3.10.0"
288291
}
289292
},
290293
"nbformat": 4,

0 commit comments

Comments
 (0)