bucket: NotImplementedError: Could not find signature for execute_node: <Bucket, Series, tuple, bool, bool, bool>
See original GitHub issueWhat happened?
I’m trying to see if I can get the support for Ibis working in hvPlot and HoloViews. Right now for histograms.
Running some code I see NotImplementedError: Could not find signature for execute_node: <Bucket, Series, tuple, bool, bool, bool>
.
I’ve reduced it to this small example
import ibis
import pandas as pd
df = pd.DataFrame({
"y": [1,2,3,4,5]
})
con = ibis.pandas.connect({"df": df})
table = con.table("df")
bins=[1.0,3.0,5.0]
expr=table
expr=expr.y
expr.bucket(bins).execute()
What version of ibis are you using?
3.2.0
What backend(s) are you using, if any?
Pandas.
My problem started with duckDB though. But the example above was just simpler to provide.
Relevant log output
$ python script3.py
Traceback (most recent call last):
File "C:\repos\private\hvplot\.venv\lib\site-packages\multipledispatch\dispatcher.py", line 269, in __call__
func = self._cache[types]
KeyError: (<class 'ibis.expr.operations.histograms.Bucket'>, <class 'pandas.core.series.Series'>, <class 'tuple'>, <class 'bool'>, <class 'bool'>, <class 'bool'>)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\repos\private\hvplot\script3.py", line 12, in <module>
expr.bucket(bins).execute()
File "C:\repos\private\hvplot\.venv\lib\site-packages\ibis\expr\types\core.py", line 291, in execute
return self._find_backend(use_default=True).execute(
File "C:\repos\private\hvplot\.venv\lib\site-packages\ibis\backends\pandas\__init__.py", line 216, in execute
return execute_and_reset(query, params=params, **kwargs)
File "C:\repos\private\hvplot\.venv\lib\site-packages\ibis\backends\pandas\core.py", line 491, in execute_and_reset
result = execute(
File "C:\repos\private\hvplot\.venv\lib\site-packages\multipledispatch\dispatcher.py", line 278, in __call__
return func(*args, **kwargs)
File "C:\repos\private\hvplot\.venv\lib\site-packages\ibis\backends\pandas\trace.py", line 137, in traced_func
return func(*args, **kwargs)
File "C:\repos\private\hvplot\.venv\lib\site-packages\ibis\backends\pandas\core.py", line 436, in main_execute
return execute_with_scope(
File "C:\repos\private\hvplot\.venv\lib\site-packages\ibis\backends\pandas\core.py", line 222, in execute_with_scope
result = execute_until_in_scope(
File "C:\repos\private\hvplot\.venv\lib\site-packages\ibis\backends\pandas\trace.py", line 137, in traced_func
return func(*args, **kwargs)
File "C:\repos\private\hvplot\.venv\lib\site-packages\ibis\backends\pandas\core.py", line 363, in execute_until_in_scope
result = execute_node(
File "C:\repos\private\hvplot\.venv\lib\site-packages\multipledispatch\dispatcher.py", line 273, in __call__
raise NotImplementedError(
NotImplementedError: Could not find signature for execute_node: <Bucket, Series, tuple, bool, bool, bool>
Code of Conduct
- I agree to follow this project’s Code of Conduct
Issue Analytics
- State:
- Created 10 months ago
- Comments:6 (1 by maintainers)
Top Results From Across the Web
Tuple<ThisThing, bool> parameter for OnNavigatedToAsync ...
The issue here is that C# 7.0 tuples are not System.Tuple , they're System.ValueTuple . So the correct cast is:
Read more >tensorflow.csv - Github-Gist
We can't make this file beautiful and searchable because it's too large. commit,author_name,time_sec,subject,files_changed,lines_inserted,lines_deleted.
Read more >All Problems Tagged With Whatever - Code Grepper
Get code examples instantly right from your google search results with the ... bucket is inplace or not · @Override public boolean on...
Read more >Python all() Function - Initial Commit
Let's use Python's bool() built-in function to determine which boolean value is given to certain common objects. >>> bool(True) True >>> ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ok, so given that, I think that you can probably “just” offer
duckdb
andsqlite
to start. A user might have data in an existing sqlite db, or an existing duckdb file, but there isn’t a pandas representation on disk, and any stored data they might want to load (like a csv or a parquet dataset) can be loaded induckdb
instead.Short of the situation where you have existing data in a specific on-disk format, I don’t think there’s any benefit to using a local backend that isn’t
duckdb
– it’s far and away the most performant (of the three above) and there are fast paths from DuckDB to arrow.Hey @MarcSkovMadsen – the workaround in #4940 is specific to the (probable) bug in DuckDB – it won’t help with the lack of implementation in the pandas backend.
I understand wanting to offer users the ability to choose any backend so that whatever data the user brings, they can make use of holoviews.
In the case of pandas dataframes, you aren’t limited to the pandas backend because there is an option to create a
memtable
, which loads an in-memory dataframe into duckdb.