From b2bafd27e4ea6bc4f79faa00a1fa975db68b3103 Mon Sep 17 00:00:00 2001 From: Essam Date: Sat, 28 Sep 2024 16:10:10 -0500 Subject: [PATCH] =?UTF-8?q?=E2=9C=85=20Fix=20float=20type?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/encoders.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/encoders.jl b/src/encoders.jl index 31818ab..5085ce0 100644 --- a/src/encoders.jl +++ b/src/encoders.jl @@ -22,7 +22,7 @@ function ordinal_encoder_fit(X; featinds) (Set([Float32(i) for i in 1:length(feat_levels)]) == Set(feat_levels)) && continue # Compute the dict using the given feature_mapper function mapping_matrix[i] = - Dict{Any, AbstractFloat}( + Dict{eltype(feat_levels), Float32}( value => Float32(index) for (index, value) in enumerate(feat_levels) ) end