File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed
Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -92,7 +92,7 @@ function encoder_kwargs_from(os::OS) where {OS <: ObservationSeries}
9292 observations = get_observations(os)
9393 obs_vec = [get_obs(obs) for obs in observations]
9494 obs_noise_cov = get_obs_noise_cov(observations[1 ], build = false )
95- if ! all([get_obs_noise_cov(observations[i], build = false ) == obs_noise_vec for i in length(observations)])
95+ if ! all([get_obs_noise_cov(observations[i], build = false ) == obs_noise_cov for i in length(observations)])
9696 @warn("""
9797 Detected that observation covariances vary for different observations.
9898 Encoder kwarg `:obs_noise_cov` will be set to the FIRST of these covariances for the purpose of data processing.
Original file line number Diff line number Diff line change @@ -208,6 +208,7 @@ $(TYPEDSIGNATURES)
208208Apply the `ElementwiseScaler` encoder, on a columns-are-data matrix
209209"""
210210function encode_data(es:: ElementwiseScaler , data:: MM ) where {MM <: AbstractMatrix }
211+ out = zeros(size(data))
211212 enc = get_data_encoder_mat(es)[1 ]
212213 mul!(out, enc, data) # must use this form to get matrix output of enc*out
213214 return out
@@ -219,6 +220,7 @@ $(TYPEDSIGNATURES)
219220Apply the `ElementwiseScaler` decoder, on a columns-are-data matrix
220221"""
221222function decode_data(es:: ElementwiseScaler , data:: MM ) where {MM <: AbstractMatrix }
223+ out = zeros(size(data))
222224 dec = get_data_decoder_mat(es)[1 ]
223225 mul!(out, dec, data) # must use this form to get matrix output of dec*out
224226 return out
You can’t perform that action at this time.
0 commit comments