This works:
img_float[:,:,1] + (img_float[:,:,1] * 0.5)

but this gives that error:
img_float[:,:,1] * (img_float[:,:,1] * 0.5)



On Tuesday, July 1, 2014 7:34:04 PM UTC-3, David A. wrote:
>
> I'm trying to operate on just one dimension of an Array of 3 dimensions, 
> but getting this: ERROR: DimensionMismatch("*")
>
> The steps I'm doing are:
>
> img = imread("path-to-image")
> img_float = convert(Array, img) / 255
>
> img_float becomes of type Array{Float64,3}
> And trying to modify the first dimension like this:
>
> img_float[:,:,1] = img_float[:,:,1] + (img_float[:,:,1] * 0.5)
>
> This line gives the error: ERROR: DimensionMismatch("*")
>
> What's the appropriate way?
>
>

Reply via email to