This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import argparse | |
import json | |
from datetime import datetime | |
from typing import List, Tuple | |
from listenbrainz import ListenBrainzClient, Track | |
def chunks(lst, n): | |
"""Yield successive n-sized chunks from lst.""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import argparse | |
import csv | |
from datetime import datetime, timezone | |
from typing import List, Tuple | |
from listenbrainz import ListenBrainzClient, Track | |
def process_scrobble_log(file) -> List[Tuple[int, Track]]: | |
local_tz = datetime.now(timezone.utc).astimezone().tzinfo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Java 17+35-2724 | |
Benchmark Mode Cnt Score Error Units | |
FibonacciBenchmark.testFibonacciForkJoin avgt 9 1.160 ± 0.040 s/op | |
FibonacciBenchmark.testFibonacciSingle avgt 9 4.462 ± 0.031 s/op | |
Java 8.0.302 | |
Benchmark Mode Cnt Score Error Units | |
FibonacciBenchmark.testFibonacciForkJoin avgt 9 1.040 ± 0.014 s/op | |
FibonacciBenchmark.testFibonacciSingle avgt 9 4.091 ± 0.043 s/op |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
EXPLAIN ANALYZE | |
WITH exclude_tracks AS ( | |
SELECT recording_mbid | |
FROM mapping.tracks_of_the_year t | |
WHERE user_name = 'ribombee' | |
), tracks AS ( | |
SELECT recording_mbid, listen_count | |
FROM mapping.tracks_of_the_year t | |
WHERE user_name IN ('kazatchok', 'tn5421', 'Shwedish') | |
AND recording_mbid NOT IN (SELECT * FROM exclude_tracks) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sort (cost=45223.48..45223.91 rows=174 width=70) | |
Sort Key: (sum(t.listen_count)) DESC | |
-> GroupAggregate (cost=45213.09..45217.00 rows=174 width=70) | |
Group Key: q.recording_mbid, r.name, ac.name | |
-> Sort (cost=45213.09..45213.52 rows=174 width=66) | |
Sort Key: q.recording_mbid, r.name, ac.name | |
-> Nested Loop (cost=26654.58..45206.61 rows=174 width=66) | |
-> Nested Loop (cost=26654.15..45127.91 rows=174 width=44) | |
-> Hash Join (cost=26653.59..43660.13 rows=174 width=36) | |
Hash Cond: (t.recording_mbid = q.recording_mbid) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Benchmark (arrayLength) Mode Cnt Score Error Units | |
FizzBuzzBenchmark.scalarFizzBuzz 256 thrpt 25 2090520.408 ± 24101.832 ops/s | |
FizzBuzzBenchmark.scalarFizzBuzzMasked 256 thrpt 25 4236376.841 ± 44501.955 ops/s | |
FizzBuzzBenchmark.simdFizzBuzz 256 thrpt 25 6732049.853 ± 77958.142 ops/s | |
FizzBuzzBenchmark.simdFizzBuzzMasked 256 thrpt 25 6305409.813 ± 37281.736 ops/s | |
FizzBuzzBenchmark.simdFizzBuzzMasked128 256 thrpt 25 9893416.108 ± 563120.103 ops/s | |
FizzBuzzBenchmark.simdFizzBuzzMasked256 256 thrpt 25 28848586.063 ± 203890.020 ops/s | |
FizzBuzzBenchmark.simdFizzBuzzMaskedPreferred 256 thrpt 25 28836915.191 ± 206452.056 ops/s | |
FizzBuzzBenchmark.simdFizzBuzzMasksInArray 256 thrpt 25 7298538.643 ± 127103.017 ops/s | |
FizzBuzzBenchmark.simdFizzBuzzSeparateMaskI |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Benchmark | Mode | Threads | Samples | Score | Score Error (99.9%) | Unit | Param: testFile | |
---|---|---|---|---|---|---|---|---|
com.augustnagro.utf8.Bench.jdk | thrpt | 1 | 5 | 1047.367078 | 64.065492 | ops/s | /twitter.json | |
com.augustnagro.utf8.Bench.jdk | thrpt | 1 | 5 | 41833.951718 | 1574.539777 | ops/s | /utf8-demo.txt | |
com.augustnagro.utf8.Bench.jdk | thrpt | 1 | 5 | 40178.133554 | 1555.286114 | ops/s | /utf8-demo-invalid.txt | |
com.augustnagro.utf8.Bench.jdk | thrpt | 1 | 5 | 64160.619182 | 1694.943367 | ops/s | /20k.txt | |
com.augustnagro.utf8.Bench.vector_preferred | thrpt | 1 | 5 | 4823.627789 | 97.421841 | ops/s | /twitter.json | |
com.augustnagro.utf8.Bench.vector_preferred | thrpt | 1 | 5 | 99850.175988 | 1951.260050 | ops/s | /utf8-demo.txt | |
com.augustnagro.utf8.Bench.vector_preferred | thrpt | 1 | 5 | 98252.526543 | 1803.710937 | ops/s | /utf8-demo-invalid.txt | |
com.augustnagro.utf8.Bench.vector_preferred | thrpt | 1 | 5 | 251105.034639 | 24333.272169 | ops/s | /20k.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Benchmark | Mode | Threads | Samples | Score | Score Error (99.9%) | Unit | Param: testFile | |
---|---|---|---|---|---|---|---|---|
com.augustnagro.utf8.Bench.jdk | thrpt | 1 | 5 | 1071.651259 | 69.378064 | ops/s | /twitter.json | |
com.augustnagro.utf8.Bench.jdk | thrpt | 1 | 5 | 41291.171245 | 987.979351 | ops/s | /utf8-demo.txt | |
com.augustnagro.utf8.Bench.jdk | thrpt | 1 | 5 | 39261.365705 | 1525.907095 | ops/s | /utf8-demo-invalid.txt | |
com.augustnagro.utf8.Bench.jdk | thrpt | 1 | 5 | 64591.879593 | 1028.072935 | ops/s | /20k.txt | |
com.augustnagro.utf8.Bench.vector_128 | thrpt | 1 | 5 | 1702.455763 | 26.254190 | ops/s | /twitter.json | |
com.augustnagro.utf8.Bench.vector_128 | thrpt | 1 | 5 | 49127.803531 | 335.445137 | ops/s | /utf8-demo.txt | |
com.augustnagro.utf8.Bench.vector_128 | thrpt | 1 | 5 | 48945.018702 | 1425.528574 | ops/s | /utf8-demo-invalid.txt | |
com.augustnagro.utf8.Bench.vector_128 | thrpt | 1 | 5 | 13743.690834 | 257.241637 | ops/s | /20k.txt | |
com.augustnagro.utf8.Bench.vector_preferred | thrpt | 1 | 5 | 2796.828402 | 34.079979 | ops/s | /twitter.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Benchmark | Mode | Cnt | Score | Error | Units | ||
---|---|---|---|---|---|---|---|
FastMethodPerfTest.method_direct_StringStartsWith | avgt | 25 | 0.756 | ± | 0.010 | ns/op | |
FastMethodPerfTest.method_direct_StringStartsWith_Return | avgt | 25 | 4.580 | ± | 0.073 | ns/op | |
FastMethodPerfTest.method_fastreflect_StringStartsWith | avgt | 25 | 0.765 | ± | 0.010 | ns/op | |
FastMethodPerfTest.method_fastreflect_StringStartsWith_Return | avgt | 25 | 4.557 | ± | 0.055 | ns/op | |
FastMethodPerfTest.method_reflect_StringStartsWith | avgt | 25 | 14.457 | ± | 0.209 | ns/op | |
FastMethodPerfTest.method_reflect_StringStartsWith_Return | avgt | 25 | 17.191 | ± | 0.190 | ns/op |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.fasterxml.jackson.annotation.JsonCreator; | |
import com.fasterxml.jackson.annotation.JsonProperty; | |
import java.time.OffsetDateTime; | |
public class Container { | |
private final OffsetDateTime offsetDateTime; | |
@JsonCreator | |
public Container(@JsonProperty("value") OffsetDateTime offsetDateTime) { |
NewerOlder