Open complyue opened 2 years ago
A lucky guess took me a step forward w.r.t.
indicator_demo.ipynb
, if I change:task_load_csv_data = { TaskSpecSchema.task_id: "load_csv_data", TaskSpecSchema.node_type: "CsvStockLoader", TaskSpecSchema.conf: {"file": "../data/stock_price_hist.csv.gz"}, TaskSpecSchema.inputs: {} }
To:
task_load_csv_data = { TaskSpecSchema.task_id: "load_csv_data", TaskSpecSchema.node_type: "CsvStockLoader", TaskSpecSchema.conf: {"file": "../data/stock_price_hist.csv.gz"}, TaskSpecSchema.inputs: {}, TaskSpecSchema.module: 'greenflow_gquant_plugin.dataloader', }
Then it'll fail with
Exception: Cannot find the Node Class:SortNode
instead ofException: Cannot find the Node Class:CsvStockLoader
.So is this the way codeful graph nodes are supposed to be written? Should I report a bug against
indicator_demo.ipynb
and fix it somehow?
So in general, one should set the module. So it should be like this:
task_load_csv_data = {
TaskSpecSchema.task_id: "load_csv_data",
TaskSpecSchema.node_type: "CsvStockLoader",
TaskSpecSchema.conf: {"file": "../data/stock_price_hist.csv.gz"},
TaskSpecSchema.inputs: {},
TaskSpecSchema.module: 'greenflow_gquant_plugin.dataloader'
}
task_sort = {
TaskSpecSchema.task_id: "sort",
TaskSpecSchema.node_type: "SortNode",
TaskSpecSchema.conf: {"keys": ['asset', 'datetime']},
TaskSpecSchema.inputs: {"in": "load_csv_data.cudf_out"},
TaskSpecSchema.module: 'greenflow_gquant_plugin.transform'
}
task_stock_symbol = {
TaskSpecSchema.task_id: "stock_symbol",
TaskSpecSchema.node_type: "StockNameLoader",
TaskSpecSchema.conf: {"file": "../data/security_master.csv.gz"},
TaskSpecSchema.inputs: {},
TaskSpecSchema.module: 'greenflow_gquant_plugin.dataloader'
}
But greenflow is supposed to be smart enough to find the node automatically without specifying the module explicitly as long as some plugin provides this node. Looks like this automatic search functionality is broken right now. I would have to debug and fix greenflow.
I had trouble running this indicator demo notebook regardless. The "bqplot" was giving me trouble plotting, and there's a path lookup in the "cuInidicator/viz" package.
load_modules(os.getenv('MODULEPATH')+'/rapids_modules/')
from rapids_modules.cuindicator import . . .
Replace all "rapids_modules" with "greenflow_gquant_plugin" which I think should be the correct way to do it. And remove load_modules(os.getenv('MODULEPATH')+'/rapids_modules/')
.
Alternatively, to get it working without modifying any code I made a symbolic link in "gQuant/plugins/gquant_plugin/modules"
rapids_modules -> <absolute_path_to>/gQuant/plugins/gquant_plugin/greenflow_gquant_plugin/
Then started jupyter lab from directory: "gQuant/plugins/gquant_plugin"
# MODUELPATH corresponds to: "gQuant/plugins/gquant_plugin/modules"
export MODULEPATH=${PWD}/modules
jupyter lab --ip=0.0.0.0 # etc...
Even with all the fixes, I couldn't get bqplot to work. It's not plotting correctly in that notebook.
Describe the bug
The cuIndicator demo notebook has various issues to reproduce its result.
Steps/Code to reproduce bug
First, an identified issue and possible fix:
https://github.com/NVIDIA/fsi-samples/issues/154#issuecomment-1016278338
Then
(I tried to give some value to that variable but further strange errors occurred, so maybe someone familiar with it should better have a look)
Expected behavior
The notebook should be reproducible.
Environment overview (please complete the following information)
Environment details
N/A
Additional context
154