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

Add demo SVM #98

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

geoffroyleconte
Copy link
Member

No description provided.

@codecov
Copy link

codecov bot commented Mar 31, 2023

Codecov Report

All modified lines are covered by tests ✅

see 3 files with indirect coverage changes

📢 Thoughts on this report? Let us know!.

examples/demo-svm.jl Outdated Show resolved Hide resolved
examples/demo-svm.jl Outdated Show resolved Hide resolved
examples/demo-svm.jl Outdated Show resolved Hide resolved
examples/demo-svm.jl Show resolved Hide resolved
examples/demo-svm.jl Outdated Show resolved Hide resolved
examples/demo-svm.jl Outdated Show resolved Hide resolved
examples/plot-utils-svm.jl Outdated Show resolved Hide resolved
@dpo
Copy link
Member

dpo commented Apr 4, 2023

there's still more

a = PGFPlots.Axis(
[
PGFPlots.Plots.MatrixPlot(reshape(x, 28, 28);
colormap = PGFPlots.ColorMaps.GrayMap())#, zmin = -700, zmax = 700)#, legendentry="computed"),
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it ok if I leave this one? In case we want to set the axis manually?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

uncomment what you use. add arguments to the function if you want to be able to change the functionality

@geoffroyleconte
Copy link
Member Author

geoffroyleconte commented Apr 4, 2023

For some reason, there seem to be a compat issue with DataFrames but it is not even in the deps of examples/project.toml.
When I check status I have something weird:

(examples) pkg> status --outdated
Status `C:\Users\Geoffroy Leconte\.julia\dev\RegularizedOptimization\examples\Project.toml`
⌅ [54578032] ADNLPModels v0.4.0 (<v0.6.0) [compat]
⌅ [a4795742] NLPModels v0.19.2 (<v0.20.0) [compat]
  [196f2941] RegularizedOptimization v0.1.0 `https://github.com/JuliaSmoothOptimizers/RegularizedOptimization.jl.git#master` [<v0.1.7], (<v0.2.2)

But RegularizedOptimization does not even have a version 0.2.2. @dpo do you know where this could come from?

@geoffroyleconte
Copy link
Member Author

@dpo
Copy link
Member

dpo commented Apr 4, 2023

can PGFPlots be upgraded?

@geoffroyleconte
Copy link
Member Author

I just tried but actually it should work because 1.0 is in the deps so 1.3 should be able to be installed. So I still don't understand where this error might come from. The error message with RegularizedOptimization is really weird.

@geoffroyleconte
Copy link
Member Author

I still don't understand the error. It works for me locally, even without dev PGFPlots and updating the compat entry for DataFrames.
@dpo could you test this on your computer to see if you get the error?

Status `C:\Users\Geoffroy Leconte\.julia\dev\RegularizedOptimization\examples\Project.toml`
⌅ [54578032] ADNLPModels v0.4.0
  [0c46a032] DifferentialEquations v7.7.0
  [eb30cadb] MLDatasets v0.7.9
⌅ [a4795742] NLPModels v0.19.2
  [e01155f1] NLPModelsModifiers v0.6.5
  [3b7a836e] PGFPlots v3.4.2
  [a725b495] ProximalOperators v0.15.3
  [196f2941] RegularizedOptimization v0.1.0 `C:\Users\Geoffroy Leconte\.julia\dev\RegularizedOptimization`
  [ea076b23] RegularizedProblems v0.1.0 `C:\Users\Geoffroy Leconte\.julia\dev\RegularizedProblems`
  [d4fd37fa] ShiftedProximalOperators v0.1.0 `C:\Users\Geoffroy Leconte\.julia\dev\ShiftedProximalOperators`
Info Packages marked with ⌅ have new versions available but compatibility constraints restrict them from upgrading. To see why use `status --outdated`

run: |
pkg_path = dirname(Base.find_package("RegularizedOptimization"))
include(joinpath(pkg_path, "..", "examples", "demo-svm.jl"))
shell: julia --project="examples" --color=yes {0}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the step "Installing non registered dependencies" still necessary here? Could it be the source of the problem?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes I think RegularizedOptimization and ShiftedProximalOperators are still not registered.

@dpo
Copy link
Member

dpo commented Apr 18, 2023

I did

pkg> activate examples
pkg> add ../RegularizedProblems.jl
pkg> add ../ShiftedProximalOperators.jl
pkg> dev .
pkg> instantiate

and it seems ok. In the end, I get DataFrames 1.5.

@dpo
Copy link
Member

dpo commented Apr 18, 2023

To debug, uncomment the "tmate" lines in the workflow file and ssh into the virtual machine to look around.

@dpo
Copy link
Member

dpo commented Jul 6, 2023

Any news here?

@geoffroyleconte
Copy link
Member Author

I could not make this work here, even though it works for me locally, I'm not sure what I should do.

@dpo dpo closed this Jul 17, 2023
@dpo dpo reopened this Jul 17, 2023
@dpo
Copy link
Member

dpo commented Oct 3, 2023

@geoffroyleconte Would you mind rebasing this and seeing if the problem went away?

@dpo
Copy link
Member

dpo commented Oct 4, 2023

@geoffroyleconte Could you please try to undo the changes in the Project.toml files and play with them to see if you can make the error go away and determine what causes it?

@geoffroyleconte
Copy link
Member Author

I can't find the issue for now, but I had this message when typing dev RegularizedOptimization in the example env:

(examples) pkg> dev RegularizedOptimization
[ Info: Use `./RegularizedOptimization` to add or develop the local directory at `C:\Users\Geoffroy Leconte\.julia\dev\RegularizedOptimization`.
   Resolving package versions...
    Updating `C:\Users\Geoffroy Leconte\.julia\dev\RegularizedOptimization\examples\Project.toml`
  [196f2941] ~ RegularizedOptimization v0.1.7  v0.1.0 `C:\Users\Geoffroy Leconte\.julia\dev\RegularizedOptimization`
...
...
...

I am not aware that the 0.1.7 version exists??

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 this pull request may close these issues.

2 participants