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

Add Prize Money to Challenges #3893

Open
gchhablani opened this issue Mar 21, 2023 · 10 comments · May be fixed by #3906
Open

Add Prize Money to Challenges #3893

gchhablani opened this issue Mar 21, 2023 · 10 comments · May be fixed by #3906
Assignees
Labels

Comments

@gchhablani
Copy link
Collaborator

gchhablani commented Mar 21, 2023

Description

Currently it is difficult to find know which challenges have prizes, and if yes, what are the first/second/thrid prizes, etc. This feature will help us understand which challenges on EvalAI have prizes. The idea is to add a new prize money section here:

Screenshot 2023-03-21 at 2 09 51 AM

There are several components to be designed here:

  1. The idea is to create a new model ChallengePrizes with the following details:
- challenge_pk
- amount
- rank
  1. The challenge prizes will be a new section in the challenge configuration. Example:
prizes:
- rank: 1
   amount: "1000USD"
- rank: 2
   amount: "500USD"
  1. This will also require you to add changes to the challenge validation script to ensure people put appropriate values for prizes.
  2. Add a new attribute has_prizes in the Challenge model.
  3. You will also need to modify the create_or_update_github_challenge function to update the challenge and the entries.
  4. Display the prizes for the challenge if the challenge has prizes. This will require you to modify the frontend.

Pre-requisites/Learnings

This issue essentially requires background on a few things:

How to Approach

  • You can start by setting up EvalAI locally. Set up the dev version locally (preferred) using the steps here.
  • Add the new models, the new attribute to the backend.
  • Update the challenge configuration, the validation and the create/update method to handle this.
  • Play around with the the frontend, and create a PR. Please add screenshots of the changes.
  • Reach out to us regarding any issues that you face or if you need any help with understanding any of the above.
@b9aurav
Copy link

b9aurav commented Mar 21, 2023

Hi @gchhablani
Please assign me this issue.

@b9aurav
Copy link

b9aurav commented Mar 21, 2023

@gchhablani What's difference between 'prize_amount' and 'amount' in model?

@gchhablani
Copy link
Collaborator Author

@b9aurav My bad, they are the same thing.

@ADITYA97-CODER
Copy link

@gchhablani hey i would also like to work on this issue? can i start working on this as you have assigned this one already ?

@gchhablani
Copy link
Collaborator Author

@ADITYA97-CODER Can you please take up one of the other issues?

@ADITYA97-CODER
Copy link

@gchhablani sure . Can you assign me "contacting host using a form issue"
Also i am getting an error while setting up locally
"failed to solve: rpc error: code = Unknown desc = failed to solve with frontend dockerfile.v0: failed to create LLB definition: pull access denied, repository does not exist or may require authorization: server message: insufficient_scope: authorization failed"
Can you help?

@b9aurav
Copy link

b9aurav commented Mar 23, 2023

@gchhablani I've done my coding part, Now I am struggling in hosting a challenge locally to test it.
According to docs, I tried "evalai_host_url": "https://staging.eval.ai" and "evalai_host_url": "127.0.0.1:8888". But failed.

Workflow error log for https://staging.eval.ai
File "github/challenge_processing_script.py", line 74, in <module> response.raise_for_status() File "/opt/hostedtoolcache/Python/3.7.5/x64/lib/python3.7/site-packages/requests/models.py", line 941, in raise_for_status raise HTTPError(http_error_msg, response=self) requests.exceptions.HTTPError: 401 Client Error: Unauthorized for url: https://staging.eval.ai/api/challenges/challenge/challenge_host_team/1/validate_challenge_config/

Workflow error log for '127.0.0.1:8888'
Following errors occurred while validating the challenge config: HTTPConnectionPool(host='127.0.0.1', port=8888): Max retries exceeded with url: /api/challenges/challenge/challenge_host_team/1/validate_challenge_config/ (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f9e197adb50>: Failed to establish a new connection: [Errno 111] Connection refused'))

I am guessing, there's another way to host challenge locally (For testing purpose).

@AyushR1
Copy link
Contributor

AyushR1 commented Mar 24, 2023

@gchhablani I've done my coding part, Now I am struggling in hosting a challenge locally to test it. According to docs, I tried "evalai_host_url": "https://staging.eval.ai" and "evalai_host_url": "127.0.0.1:8888". But failed.

Workflow error log for https://staging.eval.ai File "github/challenge_processing_script.py", line 74, in <module> response.raise_for_status() File "/opt/hostedtoolcache/Python/3.7.5/x64/lib/python3.7/site-packages/requests/models.py", line 941, in raise_for_status raise HTTPError(http_error_msg, response=self) requests.exceptions.HTTPError: 401 Client Error: Unauthorized for url: https://staging.eval.ai/api/challenges/challenge/challenge_host_team/1/validate_challenge_config/

Workflow error log for '127.0.0.1:8888' Following errors occurred while validating the challenge config: HTTPConnectionPool(host='127.0.0.1', port=8888): Max retries exceeded with url: /api/challenges/challenge/challenge_host_team/1/validate_challenge_config/ (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f9e197adb50>: Failed to establish a new connection: [Errno 111] Connection refused'))

I am guessing, there's another way to host challenge locally (For testing purpose).

@b9aurav I had the same problem and I fixed by creating a script to test the challenges locally you can refer to my pull request here It include script along with the documentation. It will solve your issue

@b9aurav
Copy link

b9aurav commented Mar 24, 2023

@gchhablani I've done my coding part, Now I am struggling in hosting a challenge locally to test it. According to docs, I tried "evalai_host_url": "https://staging.eval.ai" and "evalai_host_url": "127.0.0.1:8888". But failed.
Workflow error log for https://staging.eval.ai File "github/challenge_processing_script.py", line 74, in <module> response.raise_for_status() File "/opt/hostedtoolcache/Python/3.7.5/x64/lib/python3.7/site-packages/requests/models.py", line 941, in raise_for_status raise HTTPError(http_error_msg, response=self) requests.exceptions.HTTPError: 401 Client Error: Unauthorized for url: https://staging.eval.ai/api/challenges/challenge/challenge_host_team/1/validate_challenge_config/
Workflow error log for '127.0.0.1:8888' Following errors occurred while validating the challenge config: HTTPConnectionPool(host='127.0.0.1', port=8888): Max retries exceeded with url: /api/challenges/challenge/challenge_host_team/1/validate_challenge_config/ (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f9e197adb50>: Failed to establish a new connection: [Errno 111] Connection refused'))
I am guessing, there's another way to host challenge locally (For testing purpose).

@b9aurav I had the same problem and I fixed by creating a script to test the challenges locally you can refer to my pull request here It include script along with the documentation. It will solve your issue

@AyushR1 Thanks, I'll definitely give it try

@b9aurav b9aurav linked a pull request Mar 25, 2023 that will close this issue
@b9aurav
Copy link

b9aurav commented Mar 25, 2023

@gchhablani It seems like my pull request #3906 build failed due to test case failure, Do I need to add test cases along with my other commits?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants