@@ -611,10 +611,10 @@ struct NDArrayWrapper
611611 array:: AbstractArray
612612 compression:: Compression
613613 inline:: Bool
614- layout :: Symbol
614+ lz4_layout :: Symbol
615615end
616- function NDArrayWrapper (array:: AbstractArray ; compression:: Compression = C_Bzip2, inline:: Bool = false , layout :: Symbol = :default )
617- return NDArrayWrapper (array, compression, inline, layout )
616+ function NDArrayWrapper (array:: AbstractArray ; compression:: Compression = C_Bzip2, inline:: Bool = false , lz4_layout :: Symbol = :block )
617+ return NDArrayWrapper (array, compression, inline, lz4_layout )
618618end
619619Base. getindex (val:: NDArrayWrapper ) = val. array
620620
@@ -765,15 +765,15 @@ function write_file(filename::AbstractString, document::Dict{Any,Any})
765765 # TODO : Don't copy input
766766 input = input isa Vector ? input : Vector (input)
767767 data = transcode (XzCompressor, input)
768- elseif array. compression == C_Lz4 && ( array. layout == :default || array . layout == : block)
768+ elseif array. compression == C_Lz4 && array. lz4_layout == :block
769769 data = encode_Lz4_block (input)
770770 # data = encode(LZ4BlockEncodeOptions(), input) # Not compatible with Python asdf
771771 else
772772 if array. compression == C_Blosc
773773 encode_options = BloscEncodeOptions (; clevel= 9 , doshuffle= 2 , typesize= sizeof (eltype (array. array)), compressor= " zstd" )
774774 elseif array. compression == C_Bzip2
775775 encode_options = BZ2EncodeOptions (; blockSize100k= 9 )
776- elseif array. compression == C_Lz4 && array. layout == :frame
776+ elseif array. compression == C_Lz4 && array. lz4_layout == :frame
777777 encode_options = LZ4FrameEncodeOptions (; compressionLevel= 12 , blockSizeID= 7 )
778778 elseif array. compression == C_Zlib
779779 encode_options = ZlibEncodeOptions (; level= 9 )
0 commit comments