Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/yjg30737/high-performance-lang-comparison

Compare performance between Python, R, Go, Rust, Julia
https://github.com/yjg30737/high-performance-lang-comparison

batch cargo go golang julia performance performance-analysis performance-compare performance-comparison python r rust

Last synced: 1 day ago
JSON representation

Compare performance between Python, R, Go, Rust, Julia

Awesome Lists containing this project

README

        

# high-performance-lang-comparison
Compare performance between Python(numpy), R, Go, Rust, Julia

This checks the performance of each language by multiplying two randomized float values between 0 and 1 10,000,000 times by default.

You can change the number of times of calculation.

Maximum number is 2147483647(Limits on Integer Constants). It shall be like it since working with large arrays can be very memory-intensive and may require a lot of processing power, so the calculation may take a long time to complete.

## How to test
```powershell
python compare.py
```
## Performance comparison
In my case
```batch
Input number(10,000,000 by default):
R: 0.928009 seconds
Go: 0.2529853 seconds
Python: 0.14574241638183594 seconds
REM updating/compiling/finished/running output for Rust
Rust: 0.0926837 seconds
Julia: 0.064706 seconds
Press Any Key...
```

How about you?

## Note

### For Rust

Rust will make a bunch of files while running the test. Feel free to remove it after you've done the test.

You can remove
```
target
Cargo.lock
```

Cargo.toml is Rust version of package.json. If you want to run Rust script, you should not delete it.

This is working for only Windows currently, because commands are running through Windows batch file.

## See Also
* pyside-lang-comparison-graph - GUI version