Hi Julia Community,
i’m facing some problems with a code so i decided to run it part by part, and i have a problem with this code:
function prob(q, na, mask)
q0 = round(Int, q.>0)
m0 = round(Int, mask)
return prod((q0 + (1-2q0).*pdet0(na)).^m0)
end
psetproposal(x::Vector) = QuantumRelay.OrthoNNDist(x, ui2oc)
new(prob, psetproposal)
end
end
end
It would help if you described the problem you encountered, any error or other diagnostic messages you saw, and what you expected.
2 Likes
Here’s a link with some suggestions for how you can formulate your question in a way that helps us to help you get to a solution.
2 Likes
well the problem that i am facing is a code divided on 4 packages and one main code where i am calling those packages. The packages are working but the main code is not i have posted the code here but this the Github link of the entire Code, the main code called “relais quantique”. i don’t see any possible way to simplify it because it’s a physical problem and i’m still new on Julia.
https://github.com/marouanehanhasse/info
Can you say what the error message (or unexpected behavior) is? If the packages are working, your minimal example can include using Package1, Package2
etc as part of it. It sounds like you were able to narrow it down to a particular part of the code that’s causing the problem - can you tell us how you did that?
It’s very difficult to help when one says “my code isn’t working” when there’s not a discrete chunk of code that I can run to reproduce the problem. It is certainly a challenge to reduce your problem this way to something others can understand, but it’s a very useful exercise because it helps you understand your code (and hopefully the solution, once we find it) better.
1 Like
for now this is what the main code shows me:
ArgumentError: Package PolyLib not found in current path:
- Run
Pkg.add("PolyLib")
to install the PolyLib package.
Stacktrace:
[1] require(::Module, ::Symbol) at ./loading.jl:817
well i have been trying to run the PolyLib package in my machine as well but it doesn’t want too and everytime i try to run it it shows me this error:
WARNING: Base.Pkg is deprecated, run using Pkg
instead
in module Main
ERROR: The following package names could not be resolved:
- PolyLib (not found in project, manifest or registry)
Please specify by known name=uuid
.
I could only find
under that name, and it appears to be unregistered and quite outdated.
It may be a medium scale undertaking to bring this code and all dependencies up to date. I would advise that you put it on the back burner for now and learn Julia first, eg by working through the manual.
1 Like
that’s what i found as well when i was coding because what i wanted to do what we call in linear algebra the smith decomposition Un,n Pn,m Vm,m = Sn,m(U and P and V and S are matrices) and calculate the inverse of two matrices(U and V), the funny thing is i used this PolyLib without runing it on my machine in one package called Utility you can find it in the code if you want and it worked, i don’t know other choices how to do that altough the fact i’m stuck with this problem it doesn’t mean i stopped learning Julia, it’s just running this code it’s important for me.
Do you have any suggetions how to do that instead??