leon0399 / benchmarks

World's complete programming language benchmark
https://leon0399.ru/experiments/benchmarks/
MIT License
4 stars 1 forks source link

Sweep: implement primes/Simple in Python #12

Closed leon0399 closed 6 months ago

leon0399 commented 6 months ago

Details

Implement primes/Simple benchmark in Python, and put it into python/primes/Simple.py.

You MUST implement it exactly in the same way as in other languages examples: php/primes/Simple.php, javascript/primes/Simple.js, ruby/primes/Simple.rb. Add script to python/benchmark.yaml

Here are other examples of out Python code: python/primes/Atkin.py. Use it to se how collect and report execution time.

Checklist - [X] Create `python/primes/Simple.py` ✓ https://github.com/leon0399/benchmarks/commit/eb5f257b148b32431d2e6863508e4f2928e7fcb6 [Edit](https://github.com/leon0399/benchmarks/edit/sweep/implement_primessimple_in_python/python/primes/Simple.py) - [X] Running GitHub Actions for `python/primes/Simple.py` ✓ [Edit](https://github.com/leon0399/benchmarks/edit/sweep/implement_primessimple_in_python/python/primes/Simple.py) - [X] Modify `python/benchmark.yml` ✓ https://github.com/leon0399/benchmarks/commit/b3eed5f951e563bfc067c947837fede6a952205c [Edit](https://github.com/leon0399/benchmarks/edit/sweep/implement_primessimple_in_python/python/benchmark.yml#L12-L18) - [X] Running GitHub Actions for `python/benchmark.yml` ✓ [Edit](https://github.com/leon0399/benchmarks/edit/sweep/implement_primessimple_in_python/python/benchmark.yml#L12-L18)
sweep-ai[bot] commented 6 months ago

🚀 Here's the PR! #17

See Sweep's progress at the progress dashboard!
Sweep Basic Tier: I'm using GPT-4. You have 2 GPT-4 tickets left for the month and 1 for the day. (tracking ID: 660d0316a3)

For more GPT-4 tickets, visit our payment portal. For a one week free trial, try Sweep Pro (unlimited GPT-4 tickets).

[!TIP] I'll email you at hello@leon0399.ru when I complete this pull request!


Actions (click)

GitHub Actions✓

Here are the GitHub Actions logs prior to making any changes:

Sandbox logs for 37fe75b
Checking python/benchmark.yml for syntax errors... ✅ python/benchmark.yml has no syntax errors! 1/1 ✓
Checking python/benchmark.yml for syntax errors...
✅ python/benchmark.yml has no syntax errors!

Sandbox passed on the latest master, so sandbox checks will be enabled for this issue.


Step 1: 🔎 Searching

I found the following snippets in your repository. I will now analyze these snippets and come up with a plan.

Some code snippets I think are relevant in decreasing order of relevance (click to expand). If some file is missing from here, you can mention the path in the ticket description. https://github.com/leon0399/benchmarks/blob/37fe75ba12a1620a4951a35d05e846ae55170caf/php/benchmark.yml#L15-L26 https://github.com/leon0399/benchmarks/blob/37fe75ba12a1620a4951a35d05e846ae55170caf/ruby/benchmark.yml#L16-L26 https://github.com/leon0399/benchmarks/blob/37fe75ba12a1620a4951a35d05e846ae55170caf/javascript/benchmark.yml#L15-L22 https://github.com/leon0399/benchmarks/blob/37fe75ba12a1620a4951a35d05e846ae55170caf/run_on_changes.py#L1-L21 https://github.com/leon0399/benchmarks/blob/37fe75ba12a1620a4951a35d05e846ae55170caf/python/primes/Atkin.py#L1-L107 https://github.com/leon0399/benchmarks/blob/37fe75ba12a1620a4951a35d05e846ae55170caf/python/benchmark.yml#L1-L19

Step 2: ⌨️ Coding

Ran GitHub Actions for eb5f257b148b32431d2e6863508e4f2928e7fcb6:

--- 
+++ 
@@ -18,3 +18,4 @@
       - treap/Naive.py

       - recursion/Tak.py
+      - primes/Simple.py

Ran GitHub Actions for b3eed5f951e563bfc067c947837fede6a952205c:


Step 3: 🔁 Code Review

I have finished reviewing the code for completeness. I did not find errors for sweep/implement_primessimple_in_python.


🎉 Latest improvements to Sweep:
  • New dashboard launched for real-time tracking of Sweep issues, covering all stages from search to coding.
  • Integration of OpenAI's latest Assistant API for more efficient and reliable code planning and editing, improving speed by 3x.
  • Use the GitHub issues extension for creating Sweep issues directly from your editor.

💡 To recreate the pull request edit the issue title or description. To tweak the pull request, leave a comment on the pull request.Something wrong? Let us know.

This is an automated message generated by Sweep AI.