Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
D
dlib
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
钟尚武
dlib
Commits
eb08cfc6
Commit
eb08cfc6
authored
Feb 16, 2017
by
Davis King
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added some comments about vector calculus.
parent
51476c4c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
0 deletions
+5
-0
loss.h
dlib/dnn/loss.h
+5
-0
No files found.
dlib/dnn/loss.h
View file @
eb08cfc6
...
@@ -1012,6 +1012,11 @@ namespace dlib
...
@@ -1012,6 +1012,11 @@ namespace dlib
else
else
d2
=
std
::
sqrt
(
d2
);
d2
=
std
::
sqrt
(
d2
);
// It should be noted that the derivative of length(x-y) with respect
// to the x vector is the unit vector (x-y)/length(x-y). If you stare
// at the code below long enough you will see that it's just an
// application of this formula.
if
(
x_label
==
y_label
)
if
(
x_label
==
y_label
)
{
{
// Things with the same label should have distances < dist_thresh between
// Things with the same label should have distances < dist_thresh between
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment