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

MethodError for connected_components #25

Closed
yha opened this issue Nov 4, 2021 · 2 comments
Closed

MethodError for connected_components #25

yha opened this issue Nov 4, 2021 · 2 comments

Comments

@yha
Copy link

yha commented Nov 4, 2021

Trying the "Getting started" example from the docs:

julia> using ManifoldLearning

julia> X, _ = ManifoldLearning.swiss_roll();

julia> M = fit(Isomap, X)
ERROR: MethodError: no method matching connected_components(::SimpleWeightedGraphs.SimpleWeightedGraph{Int64, Float64})
Closest candidates are:
  connected_components(::LightGraphs.AbstractGraph{T}) where T at C:\Users\sternlab\.julia\packages\LightGraphs\IgJif\src\connectivity.jl:100
Stacktrace:
 [1] largest_component(G::SimpleWeightedGraphs.SimpleWeightedGraph{Int64, Float64})
   @ ManifoldLearning C:\Users\sternlab\.julia\packages\ManifoldLearning\ocJhX\src\utils.jl:52
 [2] fit(::Type{Isomap}, X::Matrix{Float64}; k::Int64, maxoutdim::Int64, nntype::Type)
   @ ManifoldLearning C:\Users\sternlab\.julia\packages\ManifoldLearning\ocJhX\src\isomap.jl:54
 [3] fit(::Type{Isomap}, X::Matrix{Float64})
   @ ManifoldLearning C:\Users\sternlab\.julia\packages\ManifoldLearning\ocJhX\src\isomap.jl:52
 [4] top-level scope
   @ REPL[43]:1

This happens for all methods except DiffMap. Tested in julia 1.6.2 in a new temp environment.

(jl_wfx66s) pkg> status
      Status `C:\Users\sternlab\AppData\Local\Temp\jl_wfx66s\Project.toml`
  [06eb3307] ManifoldLearning v0.6.2

(jl_wfx66s) pkg> status -m
      Status `C:\Users\sternlab\AppData\Local\Temp\jl_wfx66s\Manifest.toml`
  [ec485272] ArnoldiMethod v0.1.0
  [7d9fca2a] Arpack v0.4.0
  [d360d2e6] ChainRulesCore v1.11.1
  [861a8166] Combinatorics v1.0.2
  [34da2185] Compat v3.40.0
  [9a962f9c] DataAPI v1.9.0
  [864edb3b] DataStructures v0.18.10
  [ffbed154] DocStringExtensions v0.8.6
  [86223c79] Graphs v1.4.1
  [d25df0c9] Inflate v0.1.2
  [3587e190] InverseFunctions v0.1.1
  [92d709cd] IrrationalConstants v0.1.1
  [093fc24a] LightGraphs v1.3.5
  [2ab3a3ac] LogExpFunctions v0.3.4
  [1914dd2f] MacroTools v0.5.9
  [06eb3307] ManifoldLearning v0.6.2
  [e1d29d7a] Missings v1.0.2
  [6f286f6a] MultivariateStats v0.8.0
  [bac558e1] OrderedCollections v1.4.1
  [699a6c99] SimpleTraits v0.9.4
  [47aef6b3] SimpleWeightedGraphs v1.2.0
  [a2af1166] SortingAlgorithms v1.0.1
  [90137ffa] StaticArrays v1.2.13
  [82ae8749] StatsAPI v1.0.0
  [2913bbd2] StatsBase v0.33.12
  [68821587] Arpack_jll v3.5.0+3
  [0dad84c5] ArgTools
  [56f22d72] Artifacts
  [2a0f44e3] Base64
  [ade2ca70] Dates
  [8bb1440f] DelimitedFiles
  [8ba89e20] Distributed
  [f43a241f] Downloads
  [b77e0a4c] InteractiveUtils
  [b27032c2] LibCURL
  [76f85450] LibGit2
  [8f399da3] Libdl
  [37e2e46d] LinearAlgebra
  [56ddb016] Logging
  [d6f4376e] Markdown
  [a63ad114] Mmap
  [ca575930] NetworkOptions
  [44cfe95a] Pkg
  [de0858da] Printf
  [3fa0cd96] REPL
  [9a3f8284] Random
  [ea8e919c] SHA
  [9e88b42a] Serialization
  [1a1011a3] SharedArrays
  [6462fe0b] Sockets
  [2f01184e] SparseArrays
  [10745b16] Statistics
  [fa267f1f] TOML
  [a4e569a6] Tar
  [8dfed614] Test
  [cf7118a7] UUIDs
  [4ec0a83e] Unicode
  [e66e0078] CompilerSupportLibraries_jll
  [deac9b47] LibCURL_jll
  [29816b5a] LibSSH2_jll
  [c8ffd9c3] MbedTLS_jll
  [14a3606d] MozillaCACerts_jll
  [4536629a] OpenBLAS_jll
  [83775a58] Zlib_jll
  [8e850ede] nghttp2_jll
  [3f19e933] p7zip_jll
@yha
Copy link
Author

yha commented Nov 7, 2021

Workaround: ]add SimpleWeightedGraphs@1.1, which removes the Graphs.jl dependency.
I suppose SimpleWeightedGraphs should be capped at 1.1, or this package should transition from LightGraphs to Graphs.

@wildart
Copy link
Owner

wildart commented Feb 16, 2022

Fixed in the new release.

@wildart wildart closed this as completed Feb 16, 2022
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

Successfully merging a pull request may close this issue.

2 participants