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

Toponym Resolution API error on 'NIL' prediction #174

Open
lukehare opened this issue Dec 15, 2022 · 0 comments
Open

Toponym Resolution API error on 'NIL' prediction #174

lukehare opened this issue Dec 15, 2022 · 0 comments

Comments

@lukehare
Copy link
Collaborator

lukehare commented Dec 15, 2022

Querying the deezy_relwithoutpubl API configuration with the following sentence results in an error:

API_EXAMPLE = "Chrixtchurch, June 10 Yesterday being the day appointed for the election of taro gentlemen to tepcoeot this borough in the new Parliament."

>>>
...
deezy_rel_without_publ_1  |   File "/usr/local/lib/python3.9/site-packages/fastapi/routing.py", line 161, in run_endpoint_function
deezy_rel_without_publ_1  |     return await dependant.call(**values)
deezy_rel_without_publ_1  |   File "/app/./app.py", line 58, in run_pipeline
deezy_rel_without_publ_1  |     resolved = geoparser.run_sentence(api_query.sentence,
deezy_rel_without_publ_1  |   File "/app/geoparser/pipeline.py", line 183, in run_sentence
deezy_rel_without_publ_1  |     mentions_dataset = self.mylinker.perform_linking_rel(
deezy_rel_without_publ_1  |   File "/app/geoparser/linking.py", line 294, in perform_linking_rel
deezy_rel_without_publ_1  |     idx_pred = prediction["candidates"].index(prediction["prediction"])
deezy_rel_without_publ_1  | ValueError: 'NIL' is not in list
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant