I want to run a Julia file inside a Python Script. The Julia file is
func1.jl
using LowRankApprox
using LinearAlgebra
function f(A)
F = pqrfact(A)
M = A * F[:P]
return M
end
function k(A)
F = pqrfact(A)
k = F[:k]
return k
end
This code is working perfectly in Atom. But I need it to work inside a Python Script. My Python Script is:
import numpy as np
import julia
j = julia.Julia()
j.include("func1.jl")
A = np.array([[1, 3, 1], [1, 1, 1], [2, 1, 1]])
print(j.k(A))
Gives the following error:
FileNotFoundError
I've tried to put the Julia file in several folders but it always gives the same message. If anyone can help me I will be very grateful.