@@ -193,7 +193,7 @@ function load(::Type{DMatrix}, fname::AbstractString;
193193 # docs are inconsistent and don't explain this, so it's disabled
194194 # "data_split_mode"=>string(data_split_mode),
195195 )
196- xgbcall (XGDMatrixCreateFromURI, JSON3 . write (cfg), o)
196+ xgbcall (XGDMatrixCreateFromURI, JSON . json (cfg), o)
197197 DMatrix (o[], kw... )
198198end
199199
@@ -361,7 +361,7 @@ function getdata(dm::DMatrix)
361361 rowptr = Vector {UInt64} (undef, m+ 1 )
362362 colval = Vector {UInt32} (undef, nnonmissing (dm))
363363 data = Vector {Float32} (undef, nnonmissing (dm))
364- cfg = JSON3 . write (Dict ())
364+ cfg = JSON . json (Dict ())
365365 xgbcall (XGDMatrixGetDataAsCSR, dm. handle, cfg, rowptr, colval, data)
366366 SparseMatrixCSR {0} (m, n, rowptr, UInt64 .(colval), data)
367367end
@@ -496,9 +496,9 @@ function numpy_json_dict(x::AbstractArray; read_only::Bool=false)
496496 )
497497end
498498
499- numpy_json_info (x:: AbstractArray ; kw... ) = JSON3 . write (numpy_json_dict (x; kw... ))
499+ numpy_json_info (x:: AbstractArray ; kw... ) = JSON . json (numpy_json_dict (x; kw... ))
500500
501- numpy_json_infos (cols:: Tables.Columns ; kw... ) = JSON3 . write (map (x -> numpy_json_dict (x; kw... ), cols))
501+ numpy_json_infos (cols:: Tables.Columns ; kw... ) = JSON . json (map (x -> numpy_json_dict (x; kw... ), cols))
502502
503503# TODO : still a little worried about ownership here
504504# TODO : sparse data for iterator and proper missings handling
@@ -597,7 +597,7 @@ function _dmatrix_caching_config_json(;cache_prefix::AbstractString,
597597 repr (missing_value)
598598 end
599599 # xgboost allows nan and inf which JSON3 thinks is invalid
600- replace (JSON3 . write (d), " \" __NAN_STR__\" " => nanstr)
600+ replace (JSON . json (d), " \" __NAN_STR__\" " => nanstr)
601601end
602602
603603function DMatrix (itr:: DataIterator ;
0 commit comments