allenai / S2AFF

link raw affiliation to ROR ids
Apache License 2.0
24 stars 4 forks source link

can't import s2aff #23

Open alberto-martin opened 7 months ago

alberto-martin commented 7 months ago

Hello,

I've used previous versions of this model, but today I built the environment and installed as per the instructions in a new machine, and found an issue.

I was able to download the model, download the latest version of ROR (v1.42-2024-02-21) and update consts.py, but in step 4 (Run python scripts/update_openalex_works_counts.py) I get the following error:

Traceback (most recent call last): File "C:\Users\Alberto\Documents\s2aff\S2AFF\scripts\update_openalex_works_counts.py", line 7, in from s2aff.consts import PATHS File "c:\users\alberto\documents\s2aff\s2aff\s2aff__init__.py", line 2, in from s2aff.model import parse_ner_prediction File "c:\users\alberto\documents\s2aff\s2aff\s2aff\model.py", line 16, in from s2aff.consts import PATHS File "c:\users\alberto\documents\s2aff\s2aff\s2aff\consts.py", line 21, in ROR_VERSION = get_ror_version() File "c:\users\alberto\documents\s2aff\s2aff\util\s3.py", line 6, in get_ror_version response = s3.list_objects_v2( File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\client.py", line 553, in _api_call return self._make_api_call(operation_name, kwargs) File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\client.py", line 989, in _make_api_call http, parsed_response = self._make_request( File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\client.py", line 1015, in _make_request return self._endpoint.make_request(operation_model, request_dict) File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\endpoint.py", line 119, in make_request return self._send_request(request_dict, operation_model) File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\endpoint.py", line 198, in _send_request request = self.create_request(request_dict, operation_model) File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\endpoint.py", line 134, in create_request self._event_emitter.emit( File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\hooks.py", line 412, in emit return self._emitter.emit(aliased_event_name, kwargs) File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\hooks.py", line 256, in emit return self._emit(event_name, kwargs) File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\hooks.py", line 239, in _emit response = handler(kwargs) File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\signers.py", line 105, in handler return self.sign(operation_name, request) File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\signers.py", line 195, in sign auth.add_auth(request) File "C:\Users\Alberto\anaconda3\envs\s2aff\lib\site-packages\botocore\auth.py", line 418, in add_auth raise NoCredentialsError() botocore.exceptions.NoCredentialsError: Unable to locate credentials

I get a similar error when I try to run the example code in the Getting Started section.

Any suggestions would be appreciated. Thank you in advance.