Skip to content

Commit 6d8015e

Browse files
committed
add supports_training_losses
1 parent 3fedc33 commit 6d8015e

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/StatisticalTraits.jl

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ const TRAITS = [
3232
:aggregation,
3333
:is_feature_dependent,
3434
:distribution_type,
35-
:iteration_parameter
35+
:iteration_parameter,
36+
:supports_training_losses
3637
]
3738

3839

@@ -166,6 +167,7 @@ is_feature_dependent(::Type) = false
166167
reports_each_observation(::Type) = false
167168
distribution_type(::Type) = missing
168169
iteration_parameter(::Type) = nothing
170+
supports_training_losses(::Type) = false
169171

170172
# Returns a tuple, with one entry per field of `T` (the type of some
171173
# statistical model, for example). Each entry is `nothing` or defines

test/runtests.jl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,7 @@ const NONCONSTANT = [:docstring,
8383
:name,
8484
:human_name,
8585
:hyperparameters,
86-
:hyperparameter_types,
87-
:iteration_parameter]
86+
:hyperparameter_types]
8887

8988
@testset "traits with constant fall-back" begin
9089
for trait in setdiff(StatisticalTraits.TRAITS, NONCONSTANT)

0 commit comments

Comments
 (0)