Skip to content

Commit

Permalink
add NoLearningRule
Browse files Browse the repository at this point in the history
  • Loading branch information
harisorgn committed Dec 16, 2024
1 parent 64e03c3 commit 37bc2ea
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/blox/reinforcement_learning.jl
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
abstract type AbstractEnvironment end
abstract type AbstractLearningRule end

struct NoLearningRule <: AbstractLearningRule end

mutable struct HebbianPlasticity <:AbstractLearningRule
const K::Float64
const W_lim::Float64
Expand Down Expand Up @@ -94,6 +96,9 @@ function maybe_set_state_post!(lr::AbstractLearningRule, state)
end
end

maybe_set_state_pre!(lr::NoLearningRule, state) = lr
maybe_set_state_post!(lr::NoLearningRule, state) = lr

mutable struct ClassificationEnvironment{S} <: AbstractEnvironment
const name::Symbol
const namespace::Symbol
Expand Down

0 comments on commit 37bc2ea

Please sign in to comment.