Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conflict with DataFrames.jl #16

Closed
datafig opened this issue Jan 7, 2016 · 8 comments
Closed

Conflict with DataFrames.jl #16

datafig opened this issue Jan 7, 2016 · 8 comments

Comments

@datafig
Copy link

datafig commented Jan 7, 2016

Another issue that I am noticing is with interoperability with DataFrames. When I just execute using PlotlyJS everything's fine.

But if execute it after importing DataFrames or vice-versa. The screen get's filled with the following Warning messages.

               _
   _       _ _(_)_     |  A fresh approach to technical computing
  (_)     | (_) (_)    |  Documentation: http://docs.julialang.org
   _ _   _| |_  __ _   |  Type "?help" for help.
  | | | | | | |/ _` |  |
  | | |_| | | | (_| |  |  Version 0.4.2 (2015-12-06 21:47 UTC)
 _/ |\__'_|_|_|\__'_|  |  Official http://julialang.org/ release
|__/                   |  x86_64-apple-darwin13.4.0

julia> using DataFrames

julia> using PlotlyJS
WARNING: New definition 
    ./(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:55
is ambiguous with: 
    ./(AbstractArray, Union{DataArrays.PooledDataArray, DataArrays.DataArray}) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:285.
To fix, define 
    ./(Images.AbstractImageDirect, Union{DataArrays.PooledDataArray, DataArrays.DataArray})
before the new definition.
WARNING: New definition 
    +(AbstractArray, Images.AbstractImageDirect) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:20
is ambiguous with: 
    +(DataArrays.DataArray, AbstractArray) at /Users/datafig/.julia/v0.4/DataArrays/src/operators.jl:326.
To fix, define 
    +(DataArrays.DataArray, Images.AbstractImageDirect)
before the new definition.
WARNING: New definition 
    +(AbstractArray, Images.AbstractImageDirect) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:20
is ambiguous with: 
    +(DataArrays.AbstractDataArray, AbstractArray) at /Users/datafig/.julia/v0.4/DataArrays/src/operators.jl:349.
To fix, define 
    +(DataArrays.AbstractDataArray, Images.AbstractImageDirect)
before the new definition.
WARNING: New definition 
    .==(Images.AbstractImageDirect{Bool, N<:Any}, AbstractArray{Bool, N<:Any}) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:181
is ambiguous with: 
    .==(AbstractArray{Bool, N<:Any}, Union{DataArrays.DataArray{Bool, N<:Any}, DataArrays.PooledDataArray{Bool, R<:Integer, N<:Any}}) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:330.
To fix, define 
    .==(Images.AbstractImageDirect{Bool, N<:Any}, Union{DataArrays.DataArray{Bool, N<:Any}, DataArrays.PooledDataArray{Bool, R<:Integer, N<:Any}})
before the new definition.
WARNING: New definition 
    .==(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:182
is ambiguous with: 
    .==(AbstractArray{Bool, N<:Any}, Union{DataArrays.DataArray{Bool, N<:Any}, DataArrays.PooledDataArray{Bool, R<:Integer, N<:Any}}) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:330.
To fix, define 
    .==(Images.AbstractImageDirect{Bool, N<:Any}, Union{DataArrays.DataArray{Bool, N<:Any}, DataArrays.PooledDataArray{Bool, R<:Integer, N<:Any}})
before the new definition.
WARNING: New definition 
    .==(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:182
is ambiguous with: 
    .==(AbstractArray, Union{DataArrays.PooledDataArray, DataArrays.DataArray}) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:285.
To fix, define 
    .==(Images.AbstractImageDirect, Union{DataArrays.PooledDataArray, DataArrays.DataArray})
before the new definition.
WARNING: New definition 
    .<(Images.AbstractImageDirect{Bool, N<:Any}, AbstractArray{Bool, N<:Any}) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:177
is ambiguous with: 
    .<(AbstractArray{Bool, N<:Any}, Union{DataArrays.DataArray{Bool, N<:Any}, DataArrays.PooledDataArray{Bool, R<:Integer, N<:Any}}) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:330.
To fix, define 
    .<(Images.AbstractImageDirect{Bool, N<:Any}, Union{DataArrays.DataArray{Bool, N<:Any}, DataArrays.PooledDataArray{Bool, R<:Integer, N<:Any}})
before the new definition.
WARNING: New definition 
    .<(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:178
is ambiguous with: 
    .<(AbstractArray{Bool, N<:Any}, Union{DataArrays.DataArray{Bool, N<:Any}, DataArrays.PooledDataArray{Bool, R<:Integer, N<:Any}}) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:330.
To fix, define 
    .<(Images.AbstractImageDirect{Bool, N<:Any}, Union{DataArrays.DataArray{Bool, N<:Any}, DataArrays.PooledDataArray{Bool, R<:Integer, N<:Any}})
before the new definition.
WARNING: New definition 
    .<(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:178
is ambiguous with: 
    .<(AbstractArray, Union{DataArrays.PooledDataArray, DataArrays.DataArray}) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:285.
To fix, define 
    .<(Images.AbstractImageDirect, Union{DataArrays.PooledDataArray, DataArrays.DataArray})
before the new definition.
WARNING: New definition 
    -(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:35
is ambiguous with: 
    -(AbstractArray, DataArrays.DataArray) at /Users/datafig/.julia/v0.4/DataArrays/src/operators.jl:326.
To fix, define 
    -(Images.AbstractImageDirect, DataArrays.DataArray)
before the new definition.
WARNING: New definition 
    -(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:35
is ambiguous with: 
    -(AbstractArray, DataArrays.AbstractDataArray) at /Users/datafig/.julia/v0.4/DataArrays/src/operators.jl:349.
To fix, define 
    -(Images.AbstractImageDirect, DataArrays.AbstractDataArray)
before the new definition.
WARNING: New definition 
    -(AbstractArray, Images.AbstractImageDirect) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:37
is ambiguous with: 
    -(DataArrays.DataArray, AbstractArray) at /Users/datafig/.julia/v0.4/DataArrays/src/operators.jl:326.
To fix, define 
    -(DataArrays.DataArray, Images.AbstractImageDirect)
before the new definition.
WARNING: New definition 
    -(AbstractArray, Images.AbstractImageDirect) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:37
is ambiguous with: 
    -(DataArrays.AbstractDataArray, AbstractArray) at /Users/datafig/.julia/v0.4/DataArrays/src/operators.jl:349.
To fix, define 
    -(DataArrays.AbstractDataArray, Images.AbstractImageDirect)
before the new definition.
WARNING: New definition 
    .>(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:179
is ambiguous with: 
    .>(AbstractArray{Bool, N<:Any}, Union{DataArrays.DataArray{Bool, N<:Any}, DataArrays.PooledDataArray{Bool, R<:Integer, N<:Any}}) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:330.
To fix, define 
    .>(Images.AbstractImageDirect{Bool, N<:Any}, Union{DataArrays.DataArray{Bool, N<:Any}, DataArrays.PooledDataArray{Bool, R<:Integer, N<:Any}})
before the new definition.
WARNING: New definition 
    .>(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:179
is ambiguous with: 
    .>(AbstractArray, Union{DataArrays.PooledDataArray, DataArrays.DataArray}) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:285.
To fix, define 
    .>(Images.AbstractImageDirect, Union{DataArrays.PooledDataArray, DataArrays.DataArray})
before the new definition.
WARNING: New definition 
    .*(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:51
is ambiguous with: 
    .*(AbstractArray, Union{DataArrays.PooledDataArray, DataArrays.DataArray}, AbstractArray...) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:295.
To fix, define 
    .*(Images.AbstractImageDirect, Union{DataArrays.PooledDataArray, DataArrays.DataArray})
before the new definition.
WARNING: New definition 
    .*(AbstractArray, Images.AbstractImageDirect) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:52
is ambiguous with: 
    .*(Union{DataArrays.PooledDataArray, DataArrays.DataArray}, AbstractArray...) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:295.
To fix, define 
    .*(Union{DataArrays.PooledDataArray, DataArrays.DataArray}, Images.AbstractImageDirect)
before the new definition.
WARNING: New definition 
    .-(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:40
is ambiguous with: 
    .-(AbstractArray, Union{DataArrays.PooledDataArray, DataArrays.DataArray}) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:285.
To fix, define 
    .-(Images.AbstractImageDirect, Union{DataArrays.PooledDataArray, DataArrays.DataArray})
before the new definition.
WARNING: New definition 
    .+(Images.AbstractImageDirect, AbstractArray) at /Users/datafig/.julia/v0.4/Images/src/algorithms.jl:22
is ambiguous with: 
    .+(AbstractArray, Union{DataArrays.PooledDataArray, DataArrays.DataArray}, AbstractArray...) at /Users/datafig/.julia/v0.4/DataArrays/src/broadcast.jl:297.
To fix, define 
    .+(Images.AbstractImageDirect, Union{DataArrays.PooledDataArray, DataArrays.DataArray})
before the new definition.
@sglyon
Copy link
Member

sglyon commented Jan 7, 2016

So this looks like a problem between DataArrays and Images. I'm going to close here because there isn't much I can do about it, but we should probably open issues at one or both of those pacakges

@sglyon sglyon closed this as completed Jan 7, 2016
@datafig
Copy link
Author

datafig commented Jan 7, 2016

Thanks, that makes sense.

@tbreloff
Copy link
Member

tbreloff commented Jan 7, 2016

FYI... I'm pretty sure there are already issues open in both packages for
this. (and I don't see a solution coming anytime soon)

On Thu, Jan 7, 2016 at 3:05 PM, datafig [email protected] wrote:

Thanks, that makes sense.


Reply to this email directly or view it on GitHub
#16 (comment)
.

@asbisen
Copy link

asbisen commented Jan 9, 2016

Given the scope of this module, I suspect a large number of users would be using DataFrame for visualization. If I am not mistaken Images is used by ImageMagick in this module, which in turn is used for saving the plots in raster formats.

I suggest for the time being we resort to saving HTML of the plots, which will retain the interactivity of the plots and eliminate the dependency with Images.

@sglyon
Copy link
Member

sglyon commented Jan 9, 2016

I would be OK with hot loading ImageMagick within the savefig function when users ask for something besides svg or html.

That would prevent this happening when you load the package and only cause the printouts when saving in a different format.

@asbisen
Copy link

asbisen commented Jan 9, 2016

That sounds even better. And frankly the outputs in html and svg are much prettier anyways :)

@sglyon
Copy link
Member

sglyon commented Jan 9, 2016

Very true. That's an issue with how plotly exports png data. They use html canvas to convert the svg to base64 encoded png. The problem is that the data is fixed at either 72 or 96 dpi (I think 96, but I can't remember which)

As png is lossless I should be able to use the imagemagic c api to convert to a higher quality image, but I haven't figured out the right functions to call yet.

@sglyon
Copy link
Member

sglyon commented Jan 10, 2016

Implemented on master

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants