ERROR: MethodError: Cannot convert
an object of type Array{Float64,1} to an object of type Int64
#344
-
Hi all! I was wondering if I could get some help with a generative POMDP I'm creating. I believe my issue is defining the state space whichcan't be explicity defined because I am repetitively adding to it in the transition function. Here is a link to the code: https://github.com/danortega2014/v3-/blob/main/README.md I get the error "ERROR: MethodError: Cannot convert an object of type Array{Float64,1} to an object of type Int64" It also might be worth mentioning that the structure of the POMDP is a Tuple{Int64, Symbol, Tuple{Int64,Int64, Int64}} . Thanks again for the help! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 9 replies
-
This error results because your |
Beta Was this translation helpful? Give feedback.
Hi @danortega2014
This error results because your
initialstate
function returns an actual state. It should return a distribution of states. To see why it outputs this particular error, runrand(initialstate(m))
. It is having trouble converting that to a state, which it thinks should be anInt