Skip to content

Commit

Permalink
Add comments in traits.jl
Browse files Browse the repository at this point in the history
  • Loading branch information
juliohm committed Jul 29, 2023
1 parent 53a6394 commit 38cc432
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/traits.jl
Original file line number Diff line number Diff line change
Expand Up @@ -248,6 +248,8 @@ Return `true` if the given `loss` is a minimizable loss.
isminimizable(loss::SupervisedLoss) = isconvex(loss)

export
# export traits whenever users type:
# using LossFunctions.Traits
Loss,
SupervisedLoss,
MarginLoss,
Expand All @@ -274,6 +276,8 @@ export
end

import .Traits:
# import traits into current module
# to add method definitions
Loss,
SupervisedLoss,
MarginLoss,
Expand Down

0 comments on commit 38cc432

Please sign in to comment.