Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Julia 0.7 using JLD Error #223

Closed
programistawpf opened this issue Aug 17, 2018 · 8 comments
Closed

Julia 0.7 using JLD Error #223

programistawpf opened this issue Aug 17, 2018 · 8 comments

Comments

@programistawpf
Copy link

  | | | | | | |/ _` |  |
  | | |_| | | | (_| |  |  Version 0.7.0 (2018-08-08 06:46 UTC)
 _/ |\__'_|_|_|\__'_|  |  Official http://julialang.org/ release
|__/                   |  x86_64-w64-mingw32

(v0.7) pkg> add JLD
  Updating registry at `C:\Users\PC\.julia\registries\General`
  Updating git-repo `https://github.com/JuliaRegistries/General.git`
 Resolving package versions...
  Updating `C:\Users\PC\.julia\environments\v0.7\Project.toml`
  [4138dd39] + JLD v0.8.3
  Updating `C:\Users\PC\.julia\environments\v0.7\Manifest.toml`
  [a74b3585] + Blosc v0.5.1
  [e1450e63] + BufferedStreams v1.0.0
  [631607c0] + CMake v1.0.1
  [d5fb7624] + CMakeWrapper v0.2.2
  [5789e2e9] + FileIO v1.0.1
  [f67ccb44] + HDF5 v0.9.4
  [0862f596] + HTTPClient v0.2.1
  [d9be37ee] + Homebrew v0.7.0
  [4138dd39] + JLD v0.8.3
  [1b4a561d] + LegacyStrings v0.3.0
  [b27032c2] + LibCURL v0.3.1
  [522f3ed2] + LibExpat v0.4.2
  [2ec943e9] + Libz v1.0.0
  [c17dfb99] + WinRPM v0.4.0


julia> using JLD
[ Info: Precompiling JLD [4138dd39-2aa7-5051-a626-17a0bb65d9c8]
┌ Warning: Deprecated syntax `try without catch or finally` at C:\Users\PC\.julia\packages\JLD\D7dpY\src\JLD.jl:
999.
└ @ C:\Users\PC\.julia\packages\JLD\D7dpY\src\JLD.jl:999
┌ Warning: Deprecated syntax `immutable` at C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\LegacyStrings.jl
:59.
│ Use `struct` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\LegacyStrings.jl:59
┌ Warning: Deprecated syntax `immutable` at C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\LegacyStrings.jl
:65.
│ Use `struct` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\LegacyStrings.jl:65
┌ Warning: Deprecated syntax `immutable` at C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\LegacyStrings.jl
:71.
│ Use `struct` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\LegacyStrings.jl:71
┌ Warning: Deprecated syntax `immutable` at C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\LegacyStrings.jl
:81.
│ Use `struct` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\LegacyStrings.jl:81
┌ Warning: Deprecated syntax `parametric method syntax isvalid{T <: Union{ASCIIString, UTF8String, UTF16String,
UTF32String}}(str::T)` around C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\support.jl:278.
│ Use `isvalid(str::T) where T <: Union{ASCIIString, UTF8String, UTF16String, UTF32String}` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\support.jl:278
┌ Warning: Deprecated syntax `parametric method syntax isvalid{T <: Union{ASCIIString, UTF8String, UTF16String,
UTF32String}}(::Type{T}, str::T)` around C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\support.jl:279.
│ Use `isvalid(#unused#::Type{T}, str::T) where T <: Union{ASCIIString, UTF8String, UTF16String, UTF32String}` i
nstead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\support.jl:279
┌ Warning: Deprecated syntax `call to `%` inside call to bitshift operator` at C:\Users\PC\.julia\packages\Legac
yStrings\fNnOL\src\utf8.jl:246.
│ Use `parenthesized call to `%`` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf8.jl:246
┌ Warning: Deprecated syntax `parametric method syntax encode_to_utf8{T <: Union{UInt16, UInt32}}(::Type{T}, dat
, len)` around C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf8.jl:293.
│ Use `encode_to_utf8(#unused#::Type{T}, dat, len) where T <: Union{UInt16, UInt32}` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf8.jl:293
┌ Warning: Deprecated syntax `parametric method syntax fast_utf_copy{S <: Union{UTF16String, UTF32String}, T <:
Union{UInt16, UInt32}}(::Type{S}, ::Type{T}, len, dat, flag::Bool = false)` around C:\Users\PC\.julia\packages\L
egacyStrings\fNnOL\src\utf16.jl:6.
│ Use `fast_utf_copy(#s20::Type{S}, #s19::Type{T}, len, dat, flag::Bool = false) where {S <: Union{UTF16String,
UTF32String}, T <: Union{UInt16, UInt32}}` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf16.jl:6
┌ Warning: Deprecated syntax `parametric method syntax unsafe_convert{T <: Union{Int16, UInt16}}(::Type{Ptr{T}},
 s::UTF16String)` around C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf16.jl:209.
│ Use `unsafe_convert(#unused#::Type{Ptr{T}}, s::UTF16String) where T <: Union{Int16, UInt16}` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf16.jl:209
┌ Warning: Deprecated syntax `parametric method syntax convert{T <: AbstractString, S <: Union{UInt32, Char, Int
32}}(::Type{T}, v::AbstractVector{S})` around C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:133.
│ Use `convert(#unused#::Type{T}, v::AbstractVector{S}) where {T <: AbstractString, S <: Union{UInt32, Char, Int
32}}` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:133
┌ Warning: Deprecated syntax `parametric method syntax convert{T <: ByteString, S <: Union{UInt32, Char, Int32}}
(::Type{T}, data::AbstractVector{S})` around C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:138.
│ Use `convert(#unused#::Type{T}, data::AbstractVector{S}) where {T <: ByteString, S <: Union{UInt32, Char, Int3
2}}` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:138
┌ Warning: Deprecated syntax `parametric method syntax unsafe_convert{T <: Union{UInt32, Int32, Char}}(::Type{Pt
r{T}}, s::UTF32String)` around C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:149.
│ Use `unsafe_convert(#unused#::Type{Ptr{T}}, s::UTF32String) where T <: Union{UInt32, Int32, Char}` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:149
┌ Warning: Deprecated syntax `parametric method syntax pointer{T <: ByteString}(x::SubString{T})` around C:\User
s\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:250.
│ Use `pointer(x::SubString{T}) where T <: ByteString` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:250
┌ Warning: Deprecated syntax `parametric method syntax pointer{T <: ByteString}(x::SubString{T}, i::Integer)` ar
ound C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:251.
│ Use `pointer(x::SubString{T}, i::Integer) where T <: ByteString` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:251
┌ Warning: Deprecated syntax `parametric method syntax pointer{T <: Union{UTF16String, UTF32String}}(x::SubStrin
g{T})` around C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:252.
│ Use `pointer(x::SubString{T}) where T <: Union{UTF16String, UTF32String}` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:252
┌ Warning: Deprecated syntax `parametric method syntax pointer{T <: Union{UTF16String, UTF32String}}(x::SubStrin
g{T}, i::Integer)` around C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:253.
│ Use `pointer(x::SubString{T}, i::Integer) where T <: Union{UTF16String, UTF32String}` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\utf32.jl:253
┌ Warning: Deprecated syntax `immutable` at C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\rep.jl:3.
│ Use `struct` instead.
└ @ C:\Users\PC\.julia\packages\LegacyStrings\fNnOL\src\rep.jl:3
WARNING: importing deprecated binding Base.ObjectIdDict into JLD.
WARNING: Base.ObjectIdDict is deprecated, use IdDict{Any, Any} instead.
  likely near C:\Users\PC\.julia\packages\JLD\D7dpY\src\JLD.jl:41
ERROR: LoadError: LoadError: UndefVarError: SimpleVector not defined
Stacktrace:
 [1] top-level scope at none:0
 [2] include at .\boot.jl:317 [inlined]
 [3] include_relative(::Module, ::String) at .\loading.jl:1038
 [4] include at .\sysimg.jl:29 [inlined]
 [5] include(::String) at C:\Users\PC\.julia\packages\JLD\D7dpY\src\JLD.jl:3
 [6] top-level scope at none:0
 [7] include at .\boot.jl:317 [inlined]
 [8] include_relative(::Module, ::String) at .\loading.jl:1038
 [9] include(::Module, ::String) at .\sysimg.jl:29
 [10] top-level scope at none:2
 [11] eval at .\boot.jl:319 [inlined]
 [12] eval(::Expr) at .\client.jl:399
 [13] top-level scope at .\none:3
in expression starting at C:\Users\PC\.julia\packages\JLD\D7dpY\src\jld_types.jl:15
in expression starting at C:\Users\PC\.julia\packages\JLD\D7dpY\src\JLD.jl:110
ERROR: Failed to precompile JLD [4138dd39-2aa7-5051-a626-17a0bb65d9c8] to C:\Users\PC\.julia\compiled\v0.7\JLD\l
8ijy.ji.
Stacktrace:
 [1] error(::String) at .\error.jl:33
 [2] macro expansion at .\logging.jl:313 [inlined]
 [3] compilecache(::Base.PkgId, ::String) at .\loading.jl:1185
 [4] _require(::Base.PkgId) at .\logging.jl:311
 [5] require(::Base.PkgId) at .\loading.jl:852
 [6] macro expansion at .\logging.jl:311 [inlined]
 [7] require(::Module, ::Symbol) at .\loading.jl:834


@egoecho
Copy link

egoecho commented Sep 11, 2018

I'm also waiting for the update of this package, but it seems untouched for a long while. JLD2 is supposed to be a better replacement, however, JLD2 "has extensive unit tests, but it has received little testing in the wild. Please use caution. If your tolerance for data loss is low, JLD may be a better choice at this time." Plus that JLD2 is not compatible with old JLD file, I think JLD has a good reason to be maintained at least for a while in the Julia 1.0 period. Any idea about the future plan of this package?

@carstenbauer
Copy link

carstenbauer commented Sep 14, 2018

I think this package must be ported to 1.0. JLD has been "sold" to people as the way to store data in Julia on discourse a lot. So people did and now the package is getting no support in the 1.0 transition.

Also, from a users point of view I don't quite understand where JLD2 is going. On the one hand it says it's HDF5-compatible, on the other hand it can't open the simplest hdf5 files (JLD gives a warning but does it anyway). It seems that it sort of defines a new data format whereas JLD was more like a Julia convenience feature on top of HDF5. I would love to get some clarification if I'm mistaken with this view.

PS: There is hope: #227

@egoecho
Copy link

egoecho commented Sep 27, 2018

I quite support @crstnbr that it is very worth to maintain and develop JLD continually in the future. JLD can stick at "standard" HDF5 format, so that .jld file can be accessed by other languages easily, and data saved in the HDF5 format outside Julia can also be assessed by Julia in a more convenient way than directly using HDF5 package. Meanwhile, JLD2 can develop to be more fancy and multifunctional, compatible with more Julia data types.

For my personal experience (I'm a computational biologist), now I cannot move my project to Julia 0.7 because all the data are saved in JLD format, and there is no way to access them in Julia 0.7 at this moment. Since the data security is the priority for me, I'll stick JLD for quite a while anyhow until the JLD2 has been tested for enough time, or I am willing to always stay in JLD if this package is keeping maintained. I think many other JLD users are facing the same dilemma as me especially under the current pressure of moving to Julia 1.0.

@kzapfe
Copy link

kzapfe commented Oct 9, 2018

I am also a victim of this mess. I have worth two years of experimental data in JLD format and I cannot seem to be able to move them out of them. For one part, I have a Julia 0.6.3 installation where I upgraded HDF5 and JLD and they broke, so I cannot use them anymore. For the other part, using plain HDF5 in Julia 1.0.0 seems to have errors: some of the data are variables of type Set, and they get absolutely messed up when trying to use HDF5 utilities to read them.
So, we absolutetly need JLD on Julia 1.0 and HDF5 to compile in Julia 0.6.x so that we can use it to transition from one version to another.

@JeffBezanson
Copy link
Contributor

There is now a 1.0-compatible release of JLD. Please check and see if it works. If you have files that fail to read, please post an issue with a detailed description of the problem. If you don't want to publish the files you can send them to me privately for debugging if that turns out to be necessary.

@programistawpf
Copy link
Author

programistawpf commented Oct 20, 2018

Hi, What about reading jld files from older version ?
i have many SparseArrays from ver 0.6

Version 0.6.2 (2017-12-13 18:08 UTC)

x86_64-w64-mingw32

julia> Pkg.status("JLD")
 - JLD                           0.8.3
julia> save("S.jld","S",sprand(10,10,.5))

Version 1.0.1 (2018-09-29)
[4138dd39] JLD v0.9.0
this file:

julia> load("S.jld","S")
┌ Warning: type Base.SparseArrays.SparseMatrixCSC{Core.Float64,Core.Int64} not present in workspace; reconstruct
ing
└ @ JLD C:\Users\PC\.julia\packages\JLD\5N2lz\src\jld_types.jl:707
getfield(JLD, Symbol("##Base.SparseArrays.SparseMatrixCSC{Core.Float64,Core.Int64}#366"))(10, 10, [1, 6, 9, 11,
16, 19, 24, 32, 39, 46, 52], [2, 4, 5, 6, 10, 2, 4, 5, 4, 8    5, 6, 7, 9, 2, 3, 4, 5, 6, 9], [0.687667, 0.59327
3, 0.630624, 0.503641, 0.0381188, 0.605063, 0.528025, 0.999082, 0.237263, 0.334366    0.246024, 0.741386, 0.1728
, 0.994913, 0.754341, 0.365975, 0.612956, 0.282227, 0.535251, 0.190595])

Paul

@carstenbauer
Copy link

Did you using SparseArrays?

@programistawpf
Copy link
Author

 Version 1.0.1 (2018-09-29)
julia> using JLD
julia> using SparseArrays
julia> load("S.jld","S")
┌ Warning: type Base.SparseArrays.SparseMatrixCSC{Core.Float64,Core.Int64} not present in workspace;
ing
└ @ JLD C:\Users\PC\.julia\packages\JLD\5N2lz\src\jld_types.jl:707
getfield(JLD, Symbol("##Base.SparseArrays.SparseMatrixCSC{Core.Float64,Core.Int64}#360"))(10, 10, [1
 24, 31, 35, 41, 44, 49, 55], [1, 3, 4, 5, 6, 8, 1, 2, 3, 4    6, 7, 9, 10, 1, 2, 4, 7, 8, 10], [0.8
117, 0.905441, 0.801815, 0.342129, 0.901027, 0.796286, 0.775726, 0.659807, 0.367295    0.978056, 0.5
866, 0.642235, 0.243074, 0.799531, 0.038362, 0.919542, 0.557772, 0.773157])

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants