kailaix / ADCME.jl

Automatic Differentiation Library for Computational and Mathematical Engineering
https://kailaix.github.io/ADCME.jl/latest/
MIT License
286 stars 57 forks source link

error about using ADCME with julia 1.6 #73

Closed guoketing closed 2 years ago

guoketing commented 2 years ago

许博士您好:

很抱歉打扰您,我是中国石油大学(华东)的一名研究生,我叫郭柯廷, 我对您的ADCME库非常感兴趣,但是,当我使用这个库的时候,出现了一些问题,错误提示如下所示: julia> using ADCME [ Info: Precompiling ADCME [07b341a0-ce75-57c6-b2de-414ffdc00be5] ERROR: LoadError: ADCME is not properly built; run Pkg.build("ADCME") to fix the problem. Stacktrace: [1] error(s::String) @ Base .\error.jl:33 [2] top-level scope @ C:\Users\Keting.julia\packages\ADCME\94vEM\src\ADCME.jl:46 [3] include @ .\Base.jl:386 [inlined] [4] include_package_for_output(pkg::Base.PkgId, input::String, depot_path::Vector{String}, dl_load_path::Vector{String}, load_path::Vector{String}, concrete_deps::Vector{Pair{Base.PkgId, UInt64}}, source::Nothing) @ Base .\loading.jl:1235 [5] top-level scope @ none:1 [6] eval @ .\boot.jl:360 [inlined] [7] eval(x::Expr) @ Base.MainInclude .\client.jl:446 [8] top-level scope @ none:1 in expression starting at C:\Users\Keting.julia\packages\ADCME\94vEM\src\ADCME.jl:3 ERROR: Failed to precompile ADCME [07b341a0-ce75-57c6-b2de-414ffdc00be5] to C:\Users\Keting.julia\compiled\v1.6\ADCME\jl_1362.tmp. Stacktrace: [1] error(s::String) @ Base .\error.jl:33 [2] compilecache(pkg::Base.PkgId, path::String, internal_stderr::Base.TTY, internal_stdout::Base.TTY, ignore_loaded_modules::Bool) @ Base .\loading.jl:1385 [3] compilecache(pkg::Base.PkgId, path::String) @ Base .\loading.jl:1329 [4] _require(pkg::Base.PkgId) @ Base .\loading.jl:1043 [5] require(uuidkey::Base.PkgId) @ Base .\loading.jl:936 [6] require(into::Module, mod::Symbol) @ Base .\loading.jl:923

当我键入 Pkg.build("ADCME")时,出现了如下错误:

julia> Pkg.build("ADCME") Building Conda ─→ C:\Users\Keting\.julia\scratchspaces\44cfe95a-1eb2-52ea-b672-e2afdf69b78f\299304989a5e6473d985212c28928899c74e9421\build.log Building PyCall → C:\Users\Keting\.julia\scratchspaces\44cfe95a-1eb2-52ea-b672-e2afdf69b78f\4ba3651d33ef76e24fef6a598b63ffd1c5e1cd17\build.log Building CMake ─→ C:\Users\Keting\.julia\scratchspaces\44cfe95a-1eb2-52ea-b672-e2afdf69b78f\50a8b41d2c562fccd9ab841085fc7d1e2706da82\build.log Building HDF5 ──→ C:\Users\Keting\.julia\scratchspaces\44cfe95a-1eb2-52ea-b672-e2afdf69b78f\698c099c6613d7b7f151832868728f426abe698b\build.log Building ADCME ─→ C:\Users\Keting\.julia\scratchspaces\44cfe95a-1eb2-52ea-b672-e2afdf69b78f\4ecfc24dbdf551f92b5de7ea2d99da3f7fde73c9\build.log ERROR: Error building ADCME: ϵͳ�Ҳ���ָ�����ļ� ┌ Warning: Pkg.installed() is deprecated └ @ Pkg C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Pkg.jl:570 ┌ Warning: Pkg.installed() is deprecated └ @ Pkg C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Pkg.jl:570 [ Info: Your Julia version is 1.6.3, current ADCME version is 0.7.3, ADCME dependencies installation path: C:\Users\Keting.julia\adcme [ Info: --------------- (1/7) Install Tensorflow Dependencies --------------- [ Info: ADCME dependencies have already been installed. [ Info: --------------- (2/7) Check Python Version --------------- ┌ Warning: Pkg.installed() is deprecated └ @ Pkg C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Pkg.jl:570 Building Conda ─→ C:\Users\Keting\.julia\scratchspaces\44cfe95a-1eb2-52ea-b672-e2afdf69b78f\299304989a5e6473d985212c28928899c74e9421\build.log Building PyCall → C:\Users\Keting\.julia\scratchspaces\44cfe95a-1eb2-52ea-b672-e2afdf69b78f\4ba3651d33ef76e24fef6a598b63ffd1c5e1cd17\build.log Precompiling project... ✗ ADCME 0 dependencies successfully precompiled in 2 seconds (42 already precompiled) 1 dependency errored. To see a full report either run import Pkg; Pkg.precompile() or load the package ┌ Info: PyCall Python version: C:\Users\Keting.julia\adcme\python.exe └ Conda Python version: C:\Users\Keting.julia\adcme\python.exe [ Info: --------------- (3/7) Looking for TensorFlow Dynamic Libraries --------------- [ Info: --------------- (Windows) Downloading Include Files for Custom Operators --------------- ERROR: LoadError: failed process: Process(cmd /c rmdir /s /q 'C:\Users\Keting\.julia\adcme\lib\site-packages\tensorflow_core\include', ProcessExited(2)) [2]

Stacktrace: [1] pipeline_error @ .\process.jl:525 [inlined] [2] run(::Cmd; wait::Bool) @ Base .\process.jl:440 [3] run(::Cmd) @ Base .\process.jl:438 [4] top-level scope @ C:\Users\Keting.julia\packages\ADCME\94vEM\deps\build.jl:91 [5] include(fname::String) @ Base.MainInclude .\client.jl:444 [6] top-level scope @ none:5 in expression starting at C:\Users\Keting.julia\packages\ADCME\94vEM\deps\build.jl:88 Stacktrace: [1] pkgerror(msg::String) @ Pkg.Types C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Types.jl:55 [2] (::Pkg.Operations.var"#82#87"{Bool, Pkg.Types.Context, String, Pkg.Types.PackageSpec})() @ Pkg.Operations C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Operations.jl:1048 [3] withenv(::Pkg.Operations.var"#82#87"{Bool, Pkg.Types.Context, String, Pkg.Types.PackageSpec}, ::Pair{String, String}, ::Vararg{Pair{String, B} where B, N} where N) @ Base .\env.jl:161 [4] (::Pkg.Operations.var"#109#113"{String, Pkg.Operations.var"#82#87"{Bool, Pkg.Types.Context, String, Pkg.Types.PackageSpec}, Pkg.Types.PackageSpec})() @ Pkg.Operations C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Operations.jl:1546 [5] with_temp_env(fn::Pkg.Operations.var"#109#113"{String, Pkg.Operations.var"#82#87"{Bool, Pkg.Types.Context, String, Pkg.Types.PackageSpec}, Pkg.Types.PackageSpec}, temp_env::String) @ Pkg.Operations C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Operations.jl:1448 [6] (::Pkg.Operations.var"#108#112"{Pkg.Operations.var"#82#87"{Bool, Pkg.Types.Context, String, Pkg.Types.PackageSpec}, Pkg.Types.Context, Pkg.Types.PackageSpec, String, Pkg.Types.Project, String})(tmp::String) @ Pkg.Operations C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Operations.jl:1521 [7] mktempdir(fn::Pkg.Operations.var"#108#112"{Pkg.Operations.var"#82#87"{Bool, Pkg.Types.Context, String, Pkg.Types.PackageSpec}, Pkg.Types.Context, Pkg.Types.PackageSpec, String, Pkg.Types.Project, String}, parent::String; prefix::String) @ Base.Filesystem .\file.jl:729 [8] mktempdir(fn::Function, parent::String) (repeats 2 times) @ Base.Filesystem .\file.jl:727 [9] sandbox(fn::Function, ctx::Pkg.Types.Context, target::Pkg.Types.PackageSpec, target_path::String, sandbox_path::String, sandbox_project_override::Pkg.Types.Project) @ Pkg.Operations C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Operations.jl:1487 [10] build_versions(ctx::Pkg.Types.Context, uuids::Vector{Base.UUID}; verbose::Bool) @ Pkg.Operations C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Operations.jl:1029 [11] build(ctx::Pkg.Types.Context, pkgs::Vector{Pkg.Types.PackageSpec}, verbose::Bool) @ Pkg.Operations C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Operations.jl:910 [12] build(ctx::Pkg.Types.Context, pkgs::Vector{Pkg.Types.PackageSpec}; verbose::Bool, kwargs::Base.Iterators.Pairs{Symbol, Base.TTY, Tuple{Symbol}, NamedTuple{(:io,), Tuple{Base.TTY}}}) @ Pkg.API C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:900 [13] build(pkgs::Vector{Pkg.Types.PackageSpec}; io::Base.TTY, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}) @ Pkg.API C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:80 [14] build(pkgs::Vector{Pkg.Types.PackageSpec}) @ Pkg.API C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:78 [15] #build#71 @ C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:76 [inlined] [16] build @ C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:76 [inlined] [17] #build#70 @ C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:75 [inlined] [18] build(pkg::String) @ Pkg.API C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:75 [19] top-level scope @ REPL[23]:1

我是在win10系统上运行的,系统环境变量也添加好了,您知道怎么解决这个问题吗?

期待您的回复, 祝好, 郭柯廷