You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
By save("xxx.gif", bitmat), one should get a white picture, however, the output is black.
using FileIO
save("one.gif", ones(Bool, 200, 200)) # get a black imageload("one.gif") |> iszero # true
More generally, when the rate of zeros is small enough, the ones-matrix is treated as a zeros-matrix.
a =ones(Bool, 200, 200)
# set zero on a small range
ind =rand(1:40000, 300)
a[ind] .=falsesave("small.gif", a)
load("small.gif") |> iszero # true again# set zero on more place
ind =rand(1:40000, 3000)
a[ind] .=falsesave("normal.gif", a) # now we get the right image
This issue occurs only in the case of gif, might have to do with the wrapper of ImageMagick.jl?
The text was updated successfully, but these errors were encountered:
By
save("xxx.gif", bitmat)
, one should get a white picture, however, the output is black.More generally, when the rate of zeros is small enough, the ones-matrix is treated as a zeros-matrix.
This issue occurs only in the case of
gif
, might have to do with the wrapper of ImageMagick.jl?The text was updated successfully, but these errors were encountered: