https://flyte.org logo
#ask-the-community
Title
# ask-the-community
p

Petko Georgiev

11/22/2023, 10:35 AM
Hi folks. I have the following problem. I am getting this error while I run it with pyflyte run --remote train.py training_workflow command. When I run the script locally (on my machine without pyflyte) everything works perfectly. I'd appreciate any help. Cheers. Traceback (most recent call last): File "/usr/local/lib/python3.10/site-packages/flytekit/exceptions/scopes.py", line 206, in user_entry_point return wrapped(*args, **kwargs) File "/root/flyteWorkFlow/train.py", line 69, in get_data all_docs['class_int'] = pd.Categorical(all_docs['class']).codes File "/usr/local/lib/python3.10/site-packages/pandas/core/frame.py", line 3807, in getitem indexer = self.columns.get_loc(key) File "/usr/local/lib/python3.10/site-packages/pandas/core/indexes/base.py", line 3804, in get_loc raise KeyError(key) from err Message: 'class' User error.
k

Ketan (kumare3)

11/22/2023, 3:17 PM
This seems like a user code error
p

Petko Georgiev

11/23/2023, 7:51 AM
No idea what caused that. It runs on my machine. It fails on Flyte. Any ideas how to solve it?
k

Ketan (kumare3)

11/23/2023, 7:41 PM
Is the data the same
p

Petko Georgiev

11/29/2023, 6:35 AM
What you mean the data is the same? I did not get you. The data consist of: first row - text, second row - class name and third one - class number. Total ~ 5k records.
Any feedback on that?
k

Ketan (kumare3)

12/06/2023, 3:09 PM
I don’t know how to help with this, the failure is when you try to index into the dataframe
3 Views