Skip to content

Commit 257ccc0

Browse files
committed
Merge branch '0.4.3.1'
2 parents 0910004 + 7eda143 commit 257ccc0

File tree

1 file changed

+37
-18
lines changed

1 file changed

+37
-18
lines changed

src/test_combo.jl

Lines changed: 37 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ function test_combo(test_mode;kwargs...)
318318
n_features_base, n_features_inflections,
319319
n_features, sd_base_mean, sd_inflection_mean, sd_base,
320320
sd_inflection, isdeep, add_noise, sd_noise,
321-
normalized, verbose)
321+
normalized, if_combined, verbose)
322322

323323
# temporary fix, S_val is not valid using :train_only
324324
# add noise don't apply to both S
@@ -403,7 +403,8 @@ function test_combo(test_mode;kwargs...)
403403

404404
if max_t == 0
405405
max_t = cal_max_timestep(data_train, data_val,
406-
n_grams_target_col)
406+
n_grams_target_col, tokenized = n_grams_tokenized,
407+
sep_token = n_grams_sep_token)
407408
end
408409

409410
# choose A
@@ -851,23 +852,41 @@ end
851852
function make_S_train_val(data_train, data_val,
852853
n_features_base, n_features_inflections,
853854
ncol, sd_base_mean, sd_inflection_mean, sd_base, sd_inflection,
854-
isdeep, add_noise, sd_noise, normalized, verbose)
855+
isdeep, add_noise, sd_noise, normalized, if_combined, verbose)
855856
verbose && println("Making S matrix...")
856-
make_S_matrix(
857-
data_train,
858-
data_val,
859-
n_features_base,
860-
n_features_inflections,
861-
ncol = ncol,
862-
sd_base_mean = sd_base_mean,
863-
sd_inflection_mean = sd_inflection_mean,
864-
sd_base = sd_base,
865-
sd_inflection = sd_inflection,
866-
isdeep = isdeep,
867-
add_noise = add_noise,
868-
sd_noise = sd_noise,
869-
normalized = normalized
870-
)
857+
if if_combined
858+
make_combined_S_matrix(
859+
data_train,
860+
data_val,
861+
n_features_base,
862+
n_features_inflections,
863+
ncol = ncol,
864+
sd_base_mean = sd_base_mean,
865+
sd_inflection_mean = sd_inflection_mean,
866+
sd_base = sd_base,
867+
sd_inflection = sd_inflection,
868+
isdeep = isdeep,
869+
add_noise = add_noise,
870+
sd_noise = sd_noise,
871+
normalized = normalized
872+
)
873+
else
874+
make_S_matrix(
875+
data_train,
876+
data_val,
877+
n_features_base,
878+
n_features_inflections,
879+
ncol = ncol,
880+
sd_base_mean = sd_base_mean,
881+
sd_inflection_mean = sd_inflection_mean,
882+
sd_base = sd_base,
883+
sd_inflection = sd_inflection,
884+
isdeep = isdeep,
885+
add_noise = add_noise,
886+
sd_noise = sd_noise,
887+
normalized = normalized
888+
)
889+
end
871890
end
872891

873892
function get_kwarg(kwargs, kw; required=false)

0 commit comments

Comments
 (0)