Skip to content
This repository has been archived by the owner on Sep 18, 2024. It is now read-only.

Docs refactoring dev ex 103 #743

Draft
wants to merge 34 commits into
base: docs-refactoring
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
99394d7
First commit - starting in on README
May 2, 2023
bacad3a
docs: Second commit to force build
May 2, 2023
2fd94c4
docs: what-is-finetuner
May 2, 2023
bf21230
docs: fix table
May 2, 2023
3dd3f89
docs: tables, again
May 2, 2023
4954516
docs: tables
May 2, 2023
2e9aa60
docs: attempted fix
May 2, 2023
b00a53d
docs: one more time with dummy images page
May 2, 2023
f0782f6
docs: minor
May 10, 2023
e03e4cf
docs: part 1 how NNs work
May 10, 2023
b0100ff
docs: Rest of draft
May 10, 2023
acd9528
docs: fix headers
May 10, 2023
1c88cf2
docs: brief referesher page
May 10, 2023
03d92a0
docs: bump to force build
May 11, 2023
95e2347
docs: trying to fix link
May 11, 2023
f1c38de
docs: fix link again
May 11, 2023
e8f6634
docs: finally got the link right
May 11, 2023
b40ea30
docs: Fix Cosing Distance title depth, experiment with width
May 11, 2023
60225eb
dcos: trying to fix sizes
May 11, 2023
0f0f2a2
docs: img resize test
May 11, 2023
e60800a
docs: img resize
May 11, 2023
e370950
docs: Making all images HTML ready via dummy page
May 11, 2023
c0581b7
docs: bump to force recompile
May 11, 2023
827b636
docs: 150px hard coded left margin
May 11, 2023
c2d05bc
docs: Restore orig sizes
May 11, 2023
8cb4157
docs: attempted image fix
May 11, 2023
caf7ef9
docs: resize again
May 11, 2023
47a1c53
docs: algebra imgs
May 11, 2023
e438306
docs: htmlify
May 11, 2023
701c8df
docs: notation
May 11, 2023
2fe681c
docs: try again
May 11, 2023
b09b8dd
Major revisions and broke NN to new page
May 16, 2023
f9a5de3
docs: fix lnks
May 16, 2023
209bb72
docs: Don't Panic
May 16, 2023
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
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@

<!-- start elevator-pitch -->

Fine-tuning is an effective way to improve performance on [neural search](https://jina.ai/news/what-is-neural-search-and-learn-to-build-a-neural-search-engine/) tasks.
Fine-tuning is an effective way to improve AI model performance on specific tasks and use cases tasks.
However, setting up and performing fine-tuning can be very time-consuming and resource-intensive.

Jina AI's Finetuner makes fine-tuning easier and faster by streamlining the workflow and handling all the complexity and infrastructure in the cloud.
With Finetuner, you can easily enhance the performance of pre-trained models,
making them production-ready [without extensive labeling](https://jina.ai/news/fine-tuning-with-low-budget-and-high-expectations/) or expensive hardware.
making them production-ready [with less data](https://jina.ai/news/fine-tuning-with-low-budget-and-high-expectations/) and without investing in expensive hardware.

🎏 **Better embeddings**: Create high-quality embeddings for semantic search, visual similarity search, cross-modal text<->image search, recommendation systems,
clustering, duplication detection, anomaly detection, or other uses.
Expand All @@ -39,6 +39,7 @@ freezing, dimensionality reduction, hard-negative mining, cross-modal models, an
☁ **All-in-cloud**: Train using our GPU infrastructure, manage runs, experiments, and artifacts on Jina AI Cloud
without worrying about resource availability, complex integration, or infrastructure costs.


<!-- end elevator-pitch -->

## [Documentation](https://finetuner.jina.ai/)
Expand Down
16 changes: 16 additions & 0 deletions docs/dummy/dummy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
![The Mona Lisa with a section cut out.](../imgs/MonaLisa1.png)
![The Mona Lisa with added blurring.](../imgs/MonaLisa2.png)
![2D space](../imgs/xy-axes.png)
![3D space](../imgs/xyz-axes.png)
![Vector notation](../imgs/notation1.png)
![Vector notation](../imgs/notation2.png)
![Vector notation](../imgs/notation3.png)
![Vector notation](../imgs/notation4.png)
![Pythagoras Theorem](../imgs/PythagorasTheorem.png)
![Algebra](../imgs/algebra1.png)
![Algebra](../imgs/algebra2.png)
![Algebra](../imgs/algebra3.png)
![Algebra](../imgs/algebra4.png)
![Cosine](../imgs/Cosine.png)
![Cosine Formula](../imgs/Cosine1.png)
![Cosine Formula](../imgs/Cosine2.png)
Binary file added docs/imgs/Cosine.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/Cosine1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/Cosine2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/Dont_Panic.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/Faces.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/HairType.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/MenWomen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/MonaLisa1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/MonaLisa2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/PythagorasTheorem.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/Wynona.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/algebra1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/algebra2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/algebra3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/algebra4.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/dog_w_text.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/finetuning-adjusting-dials.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/fruit_NN2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/fruit_and_dots.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/matrix1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/matrix2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/matrix3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/matrix_eq1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/nn_first_layer.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/nn_small.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/imgs/notation1.png
Binary file added docs/imgs/notation2.png
Binary file added docs/imgs/notation3.png
Binary file added docs/imgs/notation4.png
Binary file added docs/imgs/ordered_veg.png
Binary file added docs/imgs/plain_fruit_NN.png
Binary file added docs/imgs/relu.png
Binary file added docs/imgs/relu1.png
Binary file added docs/imgs/scatterplot_fruit.png
Binary file added docs/imgs/scatterplot_fruit_ordered.png
Binary file added docs/imgs/scatterplot_fruit_partitioned.png
Binary file added docs/imgs/scatterplot_veg.png
Binary file added docs/imgs/sigmoid.png
Binary file added docs/imgs/thresholds.png
Binary file added docs/imgs/thresholds1.png
Binary file added docs/imgs/tomato_centroid.png
Binary file added docs/imgs/tomato_centroid_arrow.png
Binary file added docs/imgs/unordered_veg_partition.png
Binary file added docs/imgs/unordered_veg_partition_softmax.png
Binary file added docs/imgs/vector.png
Binary file added docs/imgs/veg_NN.jpg
Binary file added docs/imgs/veg_apart.png
Binary file added docs/imgs/veg_together.png
Binary file added docs/imgs/veg_triplet.png
Binary file added docs/imgs/xy-axes.png
Binary file added docs/imgs/xyz-axes.png
3 changes: 3 additions & 0 deletions docs/intro/AI-pipeline.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
In practice, we typically do transform the input data in some way before inputting
it into a neural network (we call this *preprocessing*) and have to perform some
transformation on the output. Nonetheless,
115 changes: 115 additions & 0 deletions docs/intro/brief-refresher-on-vectors.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
# {octicon}`light-bulb` Brief Refresher on Vectors

Vectors are ordered lists of numbers that correspond to points in a high-dimensional
metric space. For example, a point on a graph is defined by a vector. In the
image below, you can see three points on a graph, each defined by a vector:
`[-3,1]`, `[4,2]`, `[2.5,-3]`

![Untitled](../imgs/xy-axes.png)

Points in a two-dimensional space are defined by vectors of two numbers. In a
three-dimensional space, you need vectors with three numbers. In the image below,
point *Q* is defined by the vector `[-5, -5, 7]` and point *P* by `[3,0,5]`:

![Untitled](../imgs/xyz-axes.png)

A vector isn’t limited to three numbers. It can have any amount — hundreds,
thousands, even millions or billions — defining a point in what’s called a
*vector space*.

These vector spaces are just extensions of the three-dimensional space we are
all used to. It can be hard to imagine a space with millions of dimensions, and
even harder to draw a picture of it, but they still have the same properties
two- and three-dimensional spaces have: Every point is uniquely defined by a
vector and each vector defines a unique point. If two vectors are the same,
they correspond to the same point in space, and the distance between them is
therefore zero. Any two points that correspond to different vectors are different
points, and we can calculate the distance between them from their vectors.

## Vector Notation

Traditionally, we write vectors with a little arrow above them, like this
five-dimensional vector:

![Untitled](../imgs/notation1.png)

Or this one:

![Untitled](../imgs/notation2.png)

And we designate the individual numbers in a vector with a subscript:

![Untitled](../imgs/notation3.png)

![Untitled](../imgs/notation4.png)

## Distance

There are a number of different kinds of distances that we can calculate
between vectors. The two most commonly used in neural networks are
*Euclidean distance*, which closely corresponds to our common-sense ideas
about distance, and *cosine distance*, which measures the angle between
vectors as if they were lines from the origin, instead of points.

### Euclidean distance

Euclidean distance corresponds closely with our everyday sense of distance.
If a town is two kilometers to the north and four kilometers to the east,
then the straight-line distance to that town is five kilometers, because of
the Pythagorean theorem:

![Pythagoras2.png](../imgs/PythagorasTheorem.png)

If sides *a* and *b* form a right angle (= 90 degrees), then the length of
side *c* must fit the equation:

[//]: # (![Untitled]&#40;../imgs/algebra1.png&#41;)
<p align="left"><img src="../../_images/algebra1.png"/></p>

This means:

[//]: # (![Untitled]&#40;../imgs/algebra2.png&#41;)
<p align="left"><img src="../../_images/algebra2.png"/></p>

We can generalize this to get the Euclidean distance between any two
*n*-dimensional vectors with the formula:

[//]: # (![Untitled]&#40;../imgs/algebra3.png&#41;)
<p align="left"><img src="../../_images/algebra3.png"/></p>

For two five-dimensional vectors, `[2 -3 7 4 1]` and `[-7 0 -2 5 4]`,
it looks like this:

[//]: # (![Untitled]&#40;../imgs/algebra4.png&#41;)
<p align="left"><img src="../../_images/algebra4.png"/></p>

Even if two vectors have thousands or millions of dimensions, it’s
pretty trivial for a computer to calculate the Euclidean distance
between them.

### Cosine distance

Vectors can also be seen as lines in a high-dimensional space from the
origin (the point where all the numbers in the vector are zero) to the
point designated by the coordinates in the vector.

![Cosine.png](../imgs/Cosine.png)

Seen in this way, we can calculate the *angle* between the two vectors.
For two vectors of dimension *n*:

[//]: # (![Untitled]&#40;../imgs/Cosine1.png&#41;)
<p align="left"><img src="../../_images/Cosine1.png"/></p>

For the two-dimensional vectors `[2,3]` and `[5,1]`:

[//]: # (![Untitled]&#40;../imgs/Cosine2.png&#41;)
<p align="left"><img src="../../_images/Cosine2.png"/></p>

Usually, we just stick to the cosine, without calculating the radians or
degrees of the angle. If *cos(θ) = 1*, then the angle *θ* is zero degrees,
if *cos(θ) = 0* then the angle *θ* is 90 degrees.

We sometimes use other measures than Euclidean distance and cosine, but
these are the two most important ones, and you can see how both are quickly
calculated from vectors.
Loading