Another case of: "Can't locate object method "code" via package "-1"
Opened this issue · 2 comments
IvanSpirandelli commented
For the following code I get a similar error message as in issue #246 but the fix suggested there does not work.
points = rand(Float64, (10,2))
vd = polytope.VoronoiPolyhedron(SITES=points)
Polymake.call_method(vd, :VISUAL_NN_CRUST)
Produces a warning:
polymake: WARNING: rule VORONOI_GRAPH.BOUNDING_BOX : SITES, VERTICES, FAR_FACE, N_VERTICES failed: block matrix - col dimension mismatch at /home/ivan/.julia/packages/Polymake/qn5DS/deps/usr/share/polymake/apps/polytope/rules/voronoi.rules line 110.
And an error:
Stacktrace:
[1] internal_call_method(::String, ::Polymake.BigObjectAllocated, ::Array{Any,1}) at /home/ivan/.julia/packages/CxxWrap/hEmjg/src/CxxWrap.jl:558
[2] #22 at /home/ivan/.julia/packages/Polymake/qn5DS/src/call_function.jl:46 [inlined]
[3] disable_sigint at ./c.jl:446 [inlined]
[4] call_method(::Type{Polymake.PropertyValue}, ::Polymake.BigObjectAllocated, ::Symbol; kwargs::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}) at /home/ivan/.julia/packages/Polymake/qn5DS/src/call_function.jl:45
[5] call_method at /home/ivan/.julia/packages/Polymake/qn5DS/src/call_function.jl:43 [inlined]
[6] #call_method#24 at /home/ivan/.julia/packages/Polymake/qn5DS/src/call_function.jl:51 [inlined]
[7] call_method(::Polymake.BigObjectAllocated, ::Symbol) at /home/ivan/.julia/packages/Polymake/qn5DS/src/call_function.jl:51
[8] top-level scope at In[7]:3
benlorenz commented
This is more similiar to #163, i.e. please homogenize your input.
julia> points = hcat(ones(10),rand(Float64, (10,2)))
10×3 Array{Float64,2}:
1.0 0.896657 0.606154
1.0 0.711502 0.144289
1.0 0.0103487 0.500112
1.0 0.490934 0.502527
1.0 0.276318 0.0812545
1.0 0.0628814 0.650391
1.0 0.227065 0.275643
1.0 0.319228 0.31516
1.0 0.50661 0.790712
1.0 0.641218 0.882224
julia> vd = polytope.VoronoiPolyhedron(SITES=points);
julia> Polymake.call_method(vd, :VISUAL_NN_CRUST);
polymake: used package ppl
The Parma Polyhedra Library ([[wiki:external_software#PPL]]): A C++ library for convex polyhedra
and other numerical abstractions.
http://www.cs.unipr.it/ppl/
polymake: used package threejs
Three.js is a lightweight cross-browser JavaScript library/API used to create and display animated 3D computer graphics on a Web browser.
See http://github.com/mrdoob for the source code.
kalmarek commented
that's a nice picture;) I guess this could be closed?