Try `reinterpret(UInt8, x.chunks)`
On Monday, September 28, 2015 at 1:01:47 AM UTC-4, Sweta Yamini wrote: > > > > Hi, > > I am new to Julia. I have an N X N BitArray that I want to pack to Uint8 > of size N X ceil(N/8) > > I tried to reinterpret the array as > > packed = reinterpret(Uint8, mybitarray) > > but it gives me an error "auto_unbox: unable to determine argument type" > > I tried > > packed = convert(Array{Uint8}, bitpack(mybitarray)) > > but it just gives me an N X N Uint8 array with 0 and 1. > > Could you help me with this? > > Sweta >