Update the README
This commit is contained in:
parent
3e5a9f32a0
commit
b66d32c84e
21
README.md
21
README.md
|
@ -2,7 +2,26 @@
|
|||
[![build](https://github.com/Polochon-street/bliss-rs/workflows/Rust/badge.svg)](https://github.com/Polochon-street/bliss-rs/actions)
|
||||
[![doc](https://docs.rs/bliss-audio/badge.svg)](https://docs.rs/bliss-audio/)
|
||||
|
||||
# bliss music analyzer - Rust version
|
||||
# Fork notice
|
||||
This repo is a fork of [bliss-rs](https://github.com/Polochon-street/bliss-rs) with bindings for Node.js (using N-API and Neon).
|
||||
|
||||
## Example usage:
|
||||
The package will be published to the Gitea registry and available for installation later.
|
||||
```ts
|
||||
import { analyze, analyzeSync } from 'bliss';
|
||||
|
||||
await analyze("/path/to/track.mp3") // returns Uint8Array
|
||||
```
|
||||
|
||||
## Return value
|
||||
The output of `bliss-rs` consists of single-precision floats, currently 20 of them. This fork contains code to convert it into an array of 80 bytes in little endian order. An additional version (also comes from `bliss-rs`, currently equal to `1`) is prepended at the start as 16 bits in platform endianness. Therefore, the total output size is 82 bytes.
|
||||
|
||||
### Usage
|
||||
The output (without the version) is meant to be converted back into floats and used to calculate the [Euclidean distance](https://en.wikipedia.org/wiki/Euclidean_distance#Higher_dimensions) between two songs. Other distance algorithms are being worked on by the Bliss team.
|
||||
|
||||
---
|
||||
|
||||
# (Original README) bliss music analyzer - Rust version
|
||||
bliss-rs is the Rust improvement of [bliss](https://github.com/Polochon-street/bliss), a
|
||||
library used to make playlists by analyzing songs, and computing distance between them.
|
||||
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
{
|
||||
"name": "bliss-rs",
|
||||
"version": "1.0.0",
|
||||
"description": "[![crate](https://img.shields.io/crates/v/bliss-audio.svg)](https://crates.io/crates/bliss-audio) [![build](https://github.com/Polochon-street/bliss-rs/workflows/Rust/badge.svg)](https://github.com/Polochon-street/bliss-rs/actions) [![doc](https://docs.rs/bliss-audio/badge.svg)](https://docs.rs/bliss-audio/)",
|
||||
"main": "index.js",
|
||||
"description": "A fork of the bliss-rs library with Node.js bindings",
|
||||
"main": "index.node",
|
||||
"types": "index.d.ts",
|
||||
"directories": {
|
||||
"example": "examples"
|
||||
},
|
||||
|
@ -10,7 +11,7 @@
|
|||
"test": "echo \"Error: no test specified\" && exit 1",
|
||||
"build": "cargo-cp-artifact -nc index.node -- cargo build --message-format=json-render-diagnostics"
|
||||
},
|
||||
"author": "",
|
||||
"author": "antonlyap",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"cargo-cp-artifact": "^0.1.8"
|
||||
|
|
Loading…
Reference in New Issue
Block a user