-
Notifications
You must be signed in to change notification settings - Fork 21
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
Tables.jl and DataAPI.jl interoperation #67
Comments
Also cc @manikyabard |
I think the only methods we need in Tables.jl are
Now, since there is no function numobs(data)
if istable(data)
return numrows(data)
else
return length(data)
end
end
function getobs(data, i)
if istable(data)
return getrow(data, i)
else
return data[i]
end
end Having those branches in such low-level functions is not great but I don't know how else we can support generic Tables.jl's tables here. |
x-ref to discussion in Tables.jl JuliaData/Tables.jl#278 |
Closing this and leaving only #61 open |
@ablaom I am not sure if this is the best place to start this discussion, but it is a follow up to https://discourse.julialang.org/t/random-access-to-rows-of-a-table/77386 and JuliaData/Tables.jl#278.
The key point is to avoid creating functions having essentially the same functionalities across DataAPI.jl, Tables.jl, and MLUtils.jl (possibly other ML packages I am not aware of).
Assume for a moment that Tables.jl table is a source of data for some ML model and you want operations to be efficient.
My understanding that your high-level workflow is the following:
The question is:
What functionalities you need to have in DataAPI.jl and Tables.jl so that it is efficient and you do not need to provide duplicate definitions of concepts in MLUtils.jl (or some other packages)?
Another consideration (raised in the linked discussions) is that I would expect that what we develop is consistent with the interfaces that Base Julia already defines (e.g. iterator interface, abstract vector interface, indexing interface, view interface)
The text was updated successfully, but these errors were encountered: