Rewrite the script in C or C++
Good day
There is a script written in Python and it is very slow, processing 1 MB of data takes more than 25 seconds
1. The problem in the code (technical):
Specifically — in generate_auto_seed() and rank_two_symbols_optimized()
They take ~90% of the total execution time of the script
This is related to:
iterating over each bit in a long array (0 and 1)
calculating a large rank of permutations (a mathematically intensive operation)
using large numbers (often with binomial coefficients)
We need a specialist who:
Understands the algorithmic essence of ranking permutations,
Is skilled in memory optimization, threading, and large numbers,
Can implement low-level block processing of the 0/1 array.
The main essence is speed - the desired speed is 1-3 seconds
In parallel - work on the seed
Send your application if you can implement this.
Thank you
Client's review of cooperation with Roman Smolyakov
Rewrite the script in C or C++Roman left me with a very pleasant impression - he did everything quickly and efficiently. There was simply no chance for problems 🙂
Freelancer's review of cooperation with Roman Freelancer
Rewrite the script in C or C++Everything is fine with the client! We will continue to work! Feel free to reach out!
-
1 day100 USD
235 1 day100 USDHello!
Your script is slow because of two functions:
generate_auto_seed() — bit enumeration, working with large numbers.
rank_two_symbols_optimized() — permutation rank calculation (heavy combinatorial operations).
What I will do:
…
1. Algorithmic optimization
I will replace the enumeration with an O(n) algorithm for ranking binary sequences (analogous to the Combinatorial Number System).
I will pre-calculate binomial coefficients in O(n²) once, not in a loop.
2. Speedup by 10-100 times
I will rewrite critical parts in Cython (remove Python overhead).
I will add Numba JIT compilation for math.
If needed — SIMD instructions (AVX2) via C extensions.
3. Parallelism and memory
I will split the data into blocks, process in 4-8 threads (multiprocessing).
I will replace lists with numpy.ndarray (dtype=uint8) to save memory.
4. Guarantees
The first 500 KB will be processed in ≤3 sec in 2 days.
The final result is 1-3 sec/MB (or I will refund the money for the improvements).
Why me?
I recently accelerated similar code for seed generation in cryptography (from 30 sec to 0.8 sec).
I am ready to show a prototype on the first 100 lines of your data for free.
What should I send:
Sources of generate_auto_seed() and rank_two_symbols_optimized().
An example of input data (bit array 0/1).
Precise requirements for the environment (Python 3.10? Linux/Windows?).
Starting today. Waiting for your data!
Respectfully,
Ziqo,
P.S. If you have any doubts, I can do a free analysis of 10-20 lines of code and show how to speed them up
-
Winning proposal1 day95 USD
1928 29 1 1 Winning proposal1 day95 USDGood day! I am always available to help. Write to me, we will discuss! And don't forget to check out the portfolio — there is a lot of interesting stuff there!
-
2 days100 USD
626 6 0 2 days100 USDHello, I am interested in your offer, can I learn more about it in private messages.
-
Доброго дня. Будь ласка, надайте зразу посилання на ваш код, git ... дякую.
-
зроблю швидко пишіть
-
Доброго дня! надайте код проекту
-
Доброго дня, можна якось ознайомитись із проектом?
-
Current freelance projects in the category C & C++
Consultation and audit of the current project on Odoo 19 Community EditionWe are looking for an Odoo Developer — a solo developer with experience in Odoo 19 Community Edition, including using Claude Code. We need a specialist who has successfully implemented projects in Odoo and practical experience in development using Claude Code. Important: we only… C & C++, Javascript and Typescript ∙ 1 day back ∙ 5 proposals |
Creation or refinement of firmware and logic for three autonomous LoRa stations based on ESP32.
113 USD
Creation or refinement of firmware and logic for three autonomous LoRa stations based on ESP32. The devices must set up a Wi-Fi access point, serve a local site via a browser (HTTP), receive text and images within a radius of 5-10 km (plus or minus), store data (preferably on… C & C++, C# ∙ 1 day 2 hours back ∙ 3 proposals |
Software development for Arduino (RF modules 3–7.5 GHz, automatic frequency scanning)It is necessary to develop a system on Arduino for the automatic search of active analog video signals and the automatic tuning of the transmitter to the detected frequency.It is planned to use three separate transceiver modules: 3000–4200 MHz; 4900–6000 MHz; 6100–7500… C & C++, Embedded Systems & Microcontrollers ∙ 2 days back ∙ 4 proposals |
Black Ukraine (RP-project on base MTA)
1164 USD
|
Residential Proxy Infrastructure EngineerWe're building a residential proxy network from scratch — fully owned, no third-party suppliers. We need one exceptional network engineer to build the entire technical foundation. What you'll build: - Android background SDK that routes proxy traffic through user devices… C & C++, DevOps ∙ 7 days 20 hours back ∙ 13 proposals |