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

BUG: unsupported operand type(s) for -: 'TransformWorkflow' and 'list' #293

Open
rnyak opened this issue Apr 24, 2023 · 0 comments
Open
Labels
bug Something isn't working P0
Milestone

Comments

@rnyak
Copy link
Contributor

rnyak commented Apr 24, 2023

Currently this notebook is giving error when we pull the latest branches from the dev branch. Although we dont know the main reason, this might be due to extra columns that are in the NVT workflow output_schema but TF4Rec model does not use them as inputs. One way to remove these extra columns from NVT workflow could be doing it in the way the graph is constructed by using - operator to adjust the selector. However, I am getting an error when I do the following:

torch_op = workflow.input_schema.column_names >> (TransformWorkflow(workflow) - ["session_id", "day_first"])>> PredictPyTorch(
    traced_model, input_schema, output_schema
)

TypeError Traceback (most recent call last)
Cell In[19], line 1
----> 1 torch_op = workflow.input_schema.column_names >> (TransformWorkflow(workflow) - ["session_id"])>> PredictPyTorch(
2 traced_model, input_schema, output_schema
3 )
5 ensemble = Ensemble(torch_op, workflow.input_schema)

TypeError: unsupported operand type(s) for -: 'TransformWorkflow' and 'list'

To repro the issue, you can run these notebooks in order:

torch_op = workflow.input_schema.column_names >> (TransformWorkflow(workflow) - ["session_id", "day_first"])>> PredictPyTorch(
    traced_model, input_schema, output_schema
)
ensemble = Ensemble(torch_op, workflow.input_schema)
@rnyak rnyak added the bug Something isn't working label Apr 24, 2023
@rnyak rnyak added this to the Merlin 23.04 milestone Apr 24, 2023
@rnyak rnyak added the P0 label Apr 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working P0
Projects
None yet
Development

No branches or pull requests

1 participant