I have a function that accepts a void* as a parameter
Im trying to convert this to use as the void*
float trainingData[4][2] = { {501, 10}, {255, 10}, {501, 255}, {10, 501} };
this is how i do a void* 1d array
float labels[4] = {1.0, -1.0, -1.0, -1.0};
(labels (foreign-alloc :float :initial-contents '(1.0 -1.0 -1.0 -1.0)))
so how do i do the 2d array
On Sat, Nov 23, 2013 at 1:09 AM, Joeish W joeish80829@yahoo.com wrote:
(labels (foreign-alloc :float :initial-contents '(1.0 -1.0 -1.0 -1.0)))
so how do i do the 2d array
Have a look at the undocumented foreign-array-alloc function.
HTH,
since it is undocumented can you show me how to use it in this context...plus i notice in src/types.lisp where foreign-array-alloc is located there are a few undocumented functions how would I learn to use them.
On Saturday, November 23, 2013 4:49 PM, Luís Oliveira loliveira@common-lisp.net wrote:
On Sat, Nov 23, 2013 at 1:09 AM, Joeish W joeish80829@yahoo.com wrote:
(labels (foreign-alloc :float :initial-contents '(1.0 -1.0 -1.0 -1.0)))
so how do i do the 2d array
Have a look at the undocumented foreign-array-alloc function.
HTH,
-- Luís Oliveira http://kerno.org/~luis/
since it is undocumented can you show me how to use it in this context...plus i notice in src/types.lisp where foreign-array-alloc is located there are a few undocumented functions how would I learn to use them.
On Saturday, November 23, 2013 4:49 PM, Luís Oliveira loliveira@common-lisp.net wrote:
On Sat, Nov 23, 2013 at 1:09 AM, Joeish W joeish80829@yahoo.com wrote:
(labels (foreign-alloc :float :initial-contents '(1.0 -1.0 -1.0 -1.0)))
so how do i do the 2d array
Have a look at the undocumented foreign-array-alloc function.
HTH,
-- Luís Oliveira http://kerno.org/~luis/