npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

maia-hash

v0.0.30

Published

Hashing and fingerprinting functions supporting various applications by Music Artificial Intelligence Algorithms, Inc.

Downloads

39

Readme

==============

Hashing and fingerprinting functions supporting various applications by Music Artificial Intelligence Algorithms, Inc.

Local Installation

Set yourself up with an installation of Node.js. Then open up a terminal window and navigate to a directory where you want to experiment with MAIA Hash.

User

Server-side use/command-line use. See here for example usage. Apologies you have to scroll past the big Composition object to get to the interesting stuff at lines 462-476.

At the moment this package is not published on npm. If the package is published on npm, a user would add it to the package.json file of their own repo, under dependencies, something like this

"dependencies": {
  ...
  "maia-hash": "^a.b.c",
  ...
}

where "a.b.c" is the semantic version, and run

npm install

from command line to obtain it. Then they would be able to write

const mh = require("maia-hash")
let h = new mh.OntimePitchHasher()

where...

console.log("sthg")

Client-side use. Copy the file maia-hash.js to some directory where you need it, and add something like

<script src="./maia-hash.js"></script>

Developer

With Node.js set up, clone the MAIA Hash repository from here and run npm install to acquire the dependencies. Some packages, such as Rollup, might need a general install.

Please follow these steps when making additions or changes:

  1. Additions or changes to the code should be made in the es6 folder;
  2. When documenting, follow the JSDoc format used therein;
  3. Write unit tests below each method/function;
  4. Edit es6 -> index.js so that any new classes are included in the compile;
  5. Update package.json -> version field;
  6. Execute npm run compile to convert the various components in the es6 into the corresponding components in the dist folder, and to combine them into an IIFE (called maia-hash.js, in the root of the repository);
  7. Do the usual git add ., git commit -m "Short meaningful message", git tag v0.0.??, git push origin v0.0.9, and git push, and we'll see it on the other side as a pull request;
  8. npm publish
  9. There should not be any need for you to edit the version in package.json;
  10. Please keep any data files out of the repository by editing the .gitignore file.

Hello-world examples

TBD

Tests

TBD

Contributing

TBD

Release History

  • 0.0.25-? Calculating similarity with pre-computed hashes.
  • 0.0.24 Fix rounding errors.
  • 0.0.22-0.0.23 Add a new function match_query_lookup_piece() to build hashes for the input lookup piece and store the hashes in memory. Then, counting how many unique hashes in the query match that in the lookup table.
  • 0.0.21 Split match_hash_entries() into three cases: "duples", "triples", and "tripleIdx".
  • 0.0.19-0.0.20 Modifications for visualising triples of points that give rise to matching hashes.
  • 0.0.8-18 Implemented a version without concatenation.
  • 0.0.4-7 Renamed an outdated histogram operation to get_piece_names().
  • 0.0.0-3 Initial release and bug fixes