Repository: hughrawlinson/meyda Branch: main Commit: ecf256616d43 Files: 135 Total size: 1.3 MB Directory structure: gitextract_v075f53j/ ├── .github/ │ ├── ISSUE_TEMPLATE/ │ │ ├── bug_report.md │ │ ├── feature_request.md │ │ ├── question-other.md │ │ └── showcase-application.md │ ├── ISSUE_TEMPLATES/ │ │ └── config.yml │ ├── dependabot.yml │ └── workflows/ │ ├── build.yml │ ├── commitlint.yml │ ├── lint.yml │ └── merge-build.yml ├── .husky/ │ ├── commit-msg │ └── pre-commit ├── .npmignore ├── .npmrc ├── .prettierignore ├── CODE_OF_CONDUCT.md ├── LICENSE.md ├── README.md ├── __tests__/ │ ├── TestData.ts │ ├── data/ │ │ ├── blackman1024.json │ │ ├── blackman128.json │ │ ├── blackman2048.json │ │ ├── blackman256.json │ │ ├── blackman512.json │ │ ├── hamming1024.json │ │ ├── hamming128.json │ │ ├── hamming2048.json │ │ ├── hamming256.json │ │ ├── hamming512.json │ │ ├── hanning1024.json │ │ ├── hanning128.json │ │ ├── hanning2048.json │ │ ├── hanning256.json │ │ ├── hanning512.json │ │ ├── sine1024.json │ │ ├── sine128.json │ │ ├── sine2048.json │ │ ├── sine256.json │ │ └── sine512.json │ ├── exports-node.ts │ ├── exports-web.ts │ ├── extractors/ │ │ ├── chroma.ts │ │ ├── energy.ts │ │ ├── loudness.ts │ │ ├── melBands.ts │ │ ├── mfcc.ts │ │ ├── perceptualSharpness.ts │ │ ├── perceptualSpread.ts │ │ ├── powerSpectrum.ts │ │ ├── rms.ts │ │ ├── spectralCentroid.ts │ │ ├── spectralCrest.ts │ │ ├── spectralFlatness.ts │ │ ├── spectralKurtosis.ts │ │ ├── spectralRolloff.ts │ │ ├── spectralSkewness.ts │ │ ├── spectralSlope.ts │ │ ├── spectralSpread.ts │ │ └── zcr.ts │ ├── featureExtractors.ts │ ├── main.ts │ ├── utilities.ts │ └── windowing.ts ├── bin/ │ ├── cli.js │ └── wav-loader.js ├── docs/ │ ├── 404.html │ ├── CNAME │ ├── Gemfile │ ├── README.md │ ├── _config.yml │ ├── _includes/ │ │ ├── contributors.html │ │ ├── footer.html │ │ ├── head.html │ │ ├── header.html │ │ ├── nav.html │ │ └── showcase.html │ ├── _layouts/ │ │ ├── default.html │ │ └── homepage.html │ ├── assets/ │ │ ├── main.css │ │ └── main.js │ ├── audio-features.md │ ├── getting-started.md │ ├── guides/ │ │ ├── contributing.md │ │ ├── offline-cli.md │ │ ├── offline-node.md │ │ └── online-web-audio.md │ ├── index.md │ ├── major-changes-policy.md │ ├── package.json │ ├── reference/ │ │ ├── .nojekyll │ │ ├── assets/ │ │ │ ├── highlight.css │ │ │ ├── icons.css │ │ │ ├── main.js │ │ │ ├── search.js │ │ │ └── style.css │ │ ├── classes/ │ │ │ └── meyda_wa.MeydaAnalyzer.html │ │ ├── index.html │ │ ├── interfaces/ │ │ │ ├── Meyda.MeydaFeaturesObject.html │ │ │ ├── Meyda.SliceableArrayLike.html │ │ │ ├── Meyda.default.html │ │ │ └── meyda_wa.MeydaAnalyzerOptions.html │ │ └── modules/ │ │ ├── Meyda.html │ │ └── meyda_wa.html │ ├── rollup.config.js │ ├── showcase.md │ └── src/ │ ├── audio.ts │ └── main.ts ├── package.json ├── rollup.config.mjs ├── src/ │ ├── extractors/ │ │ ├── chroma.ts │ │ ├── energy.ts │ │ ├── extractorUtilities.ts │ │ ├── loudness.ts │ │ ├── melBands.ts │ │ ├── mfcc.ts │ │ ├── perceptualSharpness.ts │ │ ├── perceptualSpread.ts │ │ ├── powerSpectrum.ts │ │ ├── rms.ts │ │ ├── spectralCentroid.ts │ │ ├── spectralCrest.ts │ │ ├── spectralFlatness.ts │ │ ├── spectralFlux.ts │ │ ├── spectralKurtosis.ts │ │ ├── spectralRolloff.ts │ │ ├── spectralSkewness.ts │ │ ├── spectralSlope.ts │ │ ├── spectralSpread.ts │ │ └── zcr.ts │ ├── featureExtractors.ts │ ├── main.ts │ ├── meyda-wa.ts │ ├── utilities.ts │ └── windowing.ts └── tsconfig.json ================================================ FILE CONTENTS ================================================ ================================================ FILE: .github/ISSUE_TEMPLATE/bug_report.md ================================================ --- name: Bug report about: Create a report to help us improve title: '' labels: bug assignees: '' --- **Describe the bug** A clear and concise description of what the bug is. **To Reproduce** Code that exhibits the behaviour you're reporting. If possible, provide us with a RunKit example. RunKit is a service that allows you to import npm packages, edit code in a notebook format, publish it, and have it be executable from your browser. **Expected behavior** A clear and concise description of what you expected to happen. **Environment configuration** Whether you're using Meyda in the browser or in Node (or another JS environment), version numbers for node/browser, Meyda version, any other relevant info about your environment. **Additional context** Add any other context about the problem here. ================================================ FILE: .github/ISSUE_TEMPLATE/feature_request.md ================================================ --- name: Feature request about: Suggest an idea for this project title: '' labels: '' assignees: '' --- **Is your feature request related to a problem? Please describe.** A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] **Is your feature request for a new Audio Feature Extractor? Please link to relevant articles, formulae, information about usage, and implementations - as much information as possible** A list of sources for background reading on your requested Audio Feature Extractor **Describe the solution you'd like** A clear and concise description of what you want to happen. **Describe alternatives you've considered** A clear and concise description of any alternative solutions or features you've considered. **Additional context** Add any other context or screenshots about the feature request here. ================================================ FILE: .github/ISSUE_TEMPLATE/question-other.md ================================================ --- name: Question/Other about: Got a question? Does your issue not fit into the above categories? This template is for you title: '' labels: question assignees: '' --- __Write your question or issue with as much detail as possible__ ================================================ FILE: .github/ISSUE_TEMPLATE/showcase-application.md ================================================ --- name: Showcase Application about: Apply to have your project featured in Meyda's Showcase title: '' labels: Showcase Request assignees: '' --- Hi! I'd like to be featured in Meyda's User Showcase. Here's a few sentences explaining why: ... Project Name: Project Link: Author(s) Names (or preferred way to be referred to. Usernames/Handles/Anonymity are all fine): Author(s) Links: Project Description: Project Screenshots: ================================================ FILE: .github/ISSUE_TEMPLATES/config.yml ================================================ ================================================ FILE: .github/dependabot.yml ================================================ version: 2 updates: - package-ecosystem: npm directory: "/" schedule: interval: daily open-pull-requests-limit: 10 commit-message: prefix: fix prefix-development: chore include: scope - package-ecosystem: bundler directory: "/docs" schedule: interval: daily open-pull-requests-limit: 10 commit-message: prefix: docs prefix-development: docs include: scope ================================================ FILE: .github/workflows/build.yml ================================================ name: build on: [pull_request] jobs: build: runs-on: ubuntu-latest strategy: matrix: node-version: [ # Disabled because with typescript, the 10.x build fails by running out # of heap space. I can't figure out how to increase heap size on the build # but since we're dropping support for 10.x soon, I think this is fine. # Tests still run on all the other versions, and we publish from 16.x now, # so we I think we're fine to disable it for the next few releases. # See you in 2035. # # https://github.com/meyda/meyda/pull/908/checks?check_run_id=3090204396 # 10.x, 18.x, 20.x, 21.x ] steps: - uses: actions/checkout@v4 with: fetch-depth: 1 - name: Use Node.js ${{ matrix.node-version }} uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} - name: Run install run: npm install --ci - name: Run build run: npm run build - name: Run test run: npm run test ================================================ FILE: .github/workflows/commitlint.yml ================================================ name: Lint Commit Messages on: [pull_request] jobs: commitlint: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: fetch-depth: 0 - uses: wagoid/commitlint-github-action@v6 ================================================ FILE: .github/workflows/lint.yml ================================================ name: lint on: [pull_request] jobs: build: runs-on: ubuntu-latest strategy: matrix: node-version: [21.x] steps: - uses: actions/checkout@v4 with: fetch-depth: 1 - name: Use Node.js ${{ matrix.node-version }} uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} - name: Run install run: npm install --ci - name: Run lint run: npm run lint ================================================ FILE: .github/workflows/merge-build.yml ================================================ name: merge-build on: push: branches: - main jobs: build: runs-on: ubuntu-latest strategy: matrix: node-version: [21.x] steps: - uses: actions/checkout@v4 with: fetch-depth: 1 - name: Use Node.js ${{ matrix.node-version }} uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} - name: Run install run: npm install --ci - name: Run build run: npm run build - name: Run test run: npm run test - name: Semantic Release env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} NPM_TOKEN: ${{ secrets.NPM_TOKEN }} run: ./node_modules/.bin/semantic-release ================================================ FILE: .husky/commit-msg ================================================ #!/bin/sh . "$(dirname "$0")/_/husky.sh" ./node_modules/.bin/commitlint --edit "$1" ================================================ FILE: .husky/pre-commit ================================================ #!/bin/sh . "$(dirname "$0")/_/husky.sh" npm run lint npx lint-staged ================================================ FILE: .npmignore ================================================ !dist docs __tests__ .travis.yml .github CODE_OF_CONDUCT.md rollup.config.js coverage .husky .prettierignore .tsconfig.json ================================================ FILE: .npmrc ================================================ registry=https://registry.npmjs.org/ ================================================ FILE: .prettierignore ================================================ node_modules .github .husky dist __tests__/data __tests__/TestData.ts docs/node_modules docs/assets docs/_site docs/.jekyll-cache docs/_includes docs/_layouts docs/reference ================================================ FILE: CODE_OF_CONDUCT.md ================================================ # Contributor Code of Conduct As contributors and maintainers of this project, and in the interest of fostering an open and welcoming community, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities. We are committed to making participation in this project a harassment-free experience for everyone, regardless of level of experience, gender, gender identity and expression, sexual orientation, disability, personal appearance, body size, race, ethnicity, age, religion, or nationality. Examples of unacceptable behavior by participants include: - The use of sexualized language or imagery - Personal attacks - Trolling or insulting/derogatory comments - Public or private harassment - Publishing other's private information, such as physical or electronic addresses, without explicit permission - Other unethical or unprofessional conduct Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful. By adopting this Code of Conduct, project maintainers commit themselves to fairly and consistently applying these principles to every aspect of managing this project. Project maintainers who do not follow or enforce the Code of Conduct may be permanently removed from the project team. This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting a project maintainer at hugh [at] codeoclock [dot] net. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. Maintainers are obligated to maintain confidentiality with regard to the reporter of an incident. This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.3.0, available at [http://contributor-covenant.org/version/1/3/0/][version] [homepage]: http://contributor-covenant.org [version]: http://contributor-covenant.org/version/1/3/0/ ================================================ FILE: LICENSE.md ================================================ # The MIT License (MIT) Copyright (c) 2014 Hugh A. Rawlinson, Nevo Segal, Jakub Fiala Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ================================================ FILE: README.md ================================================ # meyda ![Build Status][build-status-image] Meyda is a Javascript audio feature extraction library. Meyda supports both offline feature extraction as well as real-time feature extraction using the [Web Audio API][web-audio-api]. We wrote a paper about it, which is available [here][meyda-paper]. Would you like your Meyda project to be featured in our [user showcase]? [Please let us know!](https://github.com/meyda/meyda/issues/new?assignees=&labels=Showcase+Request&template=showcase-application.md&title=) Want to ask questions, or chat about Meyda? Check out our [slack channel] on the Web Audio Slack Team. You'll need to [sign up here][web-audio-slack-team-signup] before you can join. [hughrawlinson][hugh-github] | [nevosegal][nevo-github] | [jakubfiala][jakub-github] | [2xAA][2xaa-github] ### Usage Please see [the documentation][docs] for setup and usage instructions. ### Contributing Please see [our contributor guidelines][contributing] for guidelines about contributing, and bear in mind that we adhere to the [Contributor Covenant][contributor-covenant] [build-status-image]: https://img.shields.io/github/checks-status/meyda/meyda/main [web-audio-api]: https://github.com/WebAudio/web-audio-api [meyda-paper]: https://wac.ircam.fr/pdf/wac15_submission_17.pdf [hugh-github]: https://github.com/hughrawlinson [nevo-github]: https://github.com/nevosegal [jakub-github]: https://github.com/jakubfiala [2xaa-github]: https://github.com/2xaa [contributing]: https://meyda.js.org/guides/contributing [contributor-covenant]: https://github.com/meyda/meyda/wiki/Contributor-Covenant [docs]: https://meyda.js.org/ [slack channel]: https://web-audio.slack.com/messages/C51A03LBS/ [web-audio-slack-team-signup]: https://web-audio-slackin.herokuapp.com/ [user showcase]: https://meyda.js.org/showcase ================================================ FILE: __tests__/TestData.ts ================================================ /* eslint @typescript-eslint/no-loss-of-precision: 0 */ // I want to reformat these arrays as tables but I have no idea how // to do it automatically, and I'm sure not doing it manually. var validSignal = new Float32Array([ 0.210053, 0.177877, 0.164105, 0.174483, 0.198507, 0.20863, 0.185864, 0.149152, 0.134373, 0.150244, 0.175646, 0.185254, 0.167029, 0.134828, 0.120649, 0.135059, 0.152342, 0.146518, 0.117914, 0.0850726, 0.0711188, 0.0831116, 0.0956098, 0.0790327, 0.0386703, 0.00368093, -0.00425037, 0.01758, 0.0456599, 0.0422213, 0.0018336, -0.0355098, -0.0354277, -0.00522628, 0.0238358, 0.0238101, -0.00896865, -0.0435429, -0.0451826, -0.0192383, -0.000213783, -0.0072255, -0.0326651, -0.0559957, -0.0555821, -0.0307709, -0.0120282, -0.0235698, -0.0497144, -0.0602726, -0.0456664, -0.0148111, 0.0133652, 0.0170683, -0.00243172, -0.0136483, 0.00683369, 0.0461872, 0.0739733, 0.0715558, 0.0445791, 0.0201561, 0.0230904, 0.0475926, 0.0640758, 0.0537718, 0.0257536, 0.00576359, 0.0137561, 0.042704, 0.0628399, 0.0573935, 0.0416932, 0.0383675, 0.0519358, 0.0709064, 0.0770058, 0.0582382, 0.0266868, 0.00986234, 0.0160813, 0.0258315, 0.019729, -0.00208688, -0.0258508, -0.0354935, -0.0237033, -0.00151217, 0.0104479, 0.00505008, -0.00615324, -0.0103148, -0.00378875, 0.0100817, 0.0210761, 0.0179143, 0.00375283, -0.00439698, 0.00246343, 0.0155962, 0.0232143, 0.0230499, 0.0195738, 0.0194644, 0.0281883, 0.0424282, 0.0505708, 0.0459622, 0.0333743, 0.0229521, 0.0232969, 0.0337038, 0.0411679, 0.034791, 0.0200176, 0.0104787, 0.0125863, 0.0219084, 0.0288187, 0.0271796, 0.0185851, 0.00814602, 0.00010769, -0.00410729, -0.00845905, -0.0181532, -0.0315387, -0.0425157, -0.0485562, -0.0509943, -0.0525175, -0.0569078, -0.0648728, -0.0707186, -0.0692475, -0.0636362, -0.061308, -0.0663872, -0.0786958, -0.0932887, -0.101306, -0.099305, -0.0946008, -0.0954661, -0.102402, -0.110466, -0.112303, -0.102428, -0.0862367, -0.0770018, -0.0791694, -0.0844438, -0.0842266, -0.0770584, -0.0681956, -0.0662046, -0.0726287, -0.0776818, -0.0738193, -0.0649626, -0.0572661, -0.0527713, -0.0523181, -0.0530069, -0.0482611, -0.0390906, -0.0356254, -0.043084, -0.0567773, -0.0695831, -0.0758914, -0.0746767, -0.0730654, -0.0784022, -0.0882514, -0.0957163, -0.0974575, -0.0924076, -0.0829959, -0.0774842, -0.0811269, -0.0894263, -0.0964565, -0.101951, -0.10749, -0.113172, -0.11888, -0.12452, -0.128645, -0.128639, -0.124067, -0.118649, -0.115934, -0.114884, -0.112186, -0.106954, -0.10164, -0.0997993, -0.10383, -0.113101, -0.121923, -0.123055, -0.117317, -0.113413, -0.114568, -0.115077, -0.111366, -0.104934, -0.0965366, -0.0884383, -0.0869267, -0.0935031, -0.100325, -0.1003, -0.0952662, -0.0916667, -0.0937288, -0.100514, -0.105195, -0.0995115, -0.0825775, -0.0635737, -0.0538227, -0.0558786, -0.0608032, -0.0585483, -0.0496366, -0.0427656, -0.0445796, -0.055052, -0.0673823, -0.0719562, -0.0654653, -0.0541091, -0.0467475, -0.0468283, -0.0487808, -0.0425466, -0.0265339, -0.0126342, -0.0123718, -0.022114, -0.0286979, -0.0256131, -0.0160068, -0.00526088, 0.00134264, 0.00154443, 0.00483469, 0.0256667, 0.0613991, 0.092394, 0.107694, 0.11447, 0.122727, 0.136071, 0.153204, 0.166608, 0.165065, 0.148037, 0.132945, 0.137259, 0.155005, 0.165077, 0.161352, 0.156986, 0.163093, 0.180532, 0.204865, 0.225191, 0.22949, 0.219644, 0.211666, 0.218466, 0.236073, 0.24553, 0.232326, 0.204887, 0.184331, 0.18092, 0.190672, 0.202115, 0.198955, 0.174898, 0.148543, 0.144139, 0.160337, 0.174553, 0.171143, 0.152899, 0.13376, 0.128038, 0.136623, 0.14159, 0.126432, 0.0983383, 0.0779321, 0.0740726, 0.0785174, 0.0754532, 0.0533432, 0.0185456, -0.0056379, -0.00360204, 0.0148392, 0.0257646, 0.0124646, -0.0202455, -0.045171, -0.0377004, -0.00770286, 0.0103068, -0.000772779, -0.0270371, -0.0454872, -0.0421428, -0.0207754, -0.00473425, -0.0142364, -0.0405185, -0.05827, -0.0555856, -0.0394355, -0.0266644, -0.0340385, -0.0585364, -0.0723941, -0.0558309, -0.0223699, 0.000482343, -0.000267456, -0.0157868, -0.0208784, 0.00474627, 0.0481501, 0.0719419, 0.0588237, 0.0288848, 0.0127234, 0.0246608, 0.0537408, 0.068271, 0.0467811, 0.00954849, -0.00377789, 0.0171299, 0.0491611, 0.0652267, 0.0543435, 0.0320568, 0.029578, 0.055131, 0.0812543, 0.0806456, 0.053999, 0.02228, 0.00938343, 0.0222486, 0.0382825, 0.029001, -0.00349459, -0.0316094, -0.0354257, -0.0158886, 0.0105391, 0.0209381, 0.00657669, -0.0131035, -0.0128786, 0.00808002, 0.0303607, 0.0363252, 0.0222121, 0.001955, -0.00275888, 0.0130369, 0.030836, 0.0319413, 0.0178758, 0.00550592, 0.00869962, 0.0255403, 0.0408193, 0.0401646, 0.0234699, 0.00582221, 0.00269674, 0.0140874, 0.0254329, 0.0224041, 0.00511699, -0.0106915, -0.0105429, 0.00252097, 0.0139908, 0.0140592, 0.00385489, -0.00722043, -0.0103427, -0.00763009, -0.00922786, -0.0203442, -0.0365691, -0.0497839, -0.0555759, -0.0560929, -0.0562996, -0.0596174, -0.0667598, -0.073583, -0.0731928, -0.0655504, -0.0591449, -0.0604797, -0.0693413, -0.0823657, -0.0935218, -0.0965494, -0.0934511, -0.0935731, -0.100812, -0.109499, -0.112634, -0.106653, -0.0922115, -0.077002, -0.0707268, -0.0726923, -0.0726287, -0.0650586, -0.0546635, -0.0487427, -0.0508422, -0.0580151, -0.06137, -0.0552217, -0.0449878, -0.0395081, -0.0399968, -0.0416351, -0.0398412, -0.0330693, -0.0251293, -0.0237558, -0.0330045, -0.0491153, -0.0640765, -0.0713467, -0.0711243, -0.0715761, -0.0805191, -0.0952137, -0.104761, -0.102692, -0.0936894, -0.0871804, -0.0876623, -0.0931927, -0.0993491, -0.102432, -0.103029, -0.106451, -0.115241, -0.124862, -0.129781, -0.128199, -0.121359, -0.11399, -0.11134, -0.111923, -0.10881, -0.0990765, -0.0871665, -0.0797417, -0.0802897, -0.0872773, -0.0951172, -0.0974329, -0.0925392, -0.0862979, -0.0854679, -0.0884219, -0.0882209, -0.0827227, -0.0746967, -0.066372, -0.0607307, -0.0619048, -0.0687389, -0.0749493, -0.0774976, -0.0776059, -0.0767834, -0.0784744, -0.0856714, -0.0927187, -0.0899654, -0.0773404, -0.0639323, -0.0570897, -0.0585352, -0.0654574, -0.0704296, -0.0670013, -0.0595495, -0.0602296, -0.0729674, -0.0877086, -0.0920242, -0.0831493, -0.0688663, -0.0591427, ]); var validAmpSpec = new Float32Array([ 0.19665084779262543, 0.2347041368484497, 0.8820229172706604, 0.24657772481441498, 0.5405293107032776, 0.1720474362373352, 0.4865507185459137, 0.10723359882831573, 0.21100476384162903, 0.2224891483783722, 0.2123824954032898, 0.2276570349931717, 0.12126567959785461, 0.066037617623806, 0.0979113057255745, 0.05718739330768585, 0.06418971717357635, 0.07439148426055908, 0.059811681509017944, 0.05451417341828346, 0.04494194686412811, 0.053511425852775574, 0.028220178559422493, 0.0508715994656086, 0.027684783563017845, 0.055125508457422256, 0.07665202021598816, 0.024500979110598564, 0.07082470506429672, 0.04819667339324951, 0.033702537417411804, 0.04822755232453346, 0.029374826699495316, 0.04507448524236679, 0.060386642813682556, 0.10165651887655258, 0.03139510378241539, 0.047015901654958725, 0.025697000324726105, 0.028244679793715477, 0.02587614394724369, 0.025666840374469757, 0.024105869233608246, 0.023856936022639275, 0.02298814244568348, 0.022686418145895004, 0.022146806120872498, 0.021367959678173065, 0.021091477945446968, 0.02044217474758625, 0.019870873540639877, 0.01956181973218918, 0.019178330898284912, 0.01895197108387947, 0.018175866454839706, 0.018201783299446106, 0.017440032213926315, 0.019627967849373817, 0.016084877774119377, 0.015716033056378365, 0.01793968863785267, 0.018144676461815834, 0.015560757368803024, 0.015966320410370827, 0.015865841880440712, 0.01724650338292122, 0.02212366834282875, 0.01283203810453415, 0.002370527945458889, 0.020350787788629532, 0.004152496345341206, 0.01835423894226551, 0.017795231193304062, 0.015214941464364529, 0.01477932371199131, 0.012785752303898335, 0.01735319010913372, 0.014473535120487213, 0.01173403486609459, 0.012687225826084614, 0.010277103632688522, 0.008647308684885502, 0.004186284728348255, 0.013694271445274353, 0.021512459963560104, 0.13956978917121887, 0.03825224190950394, 0.10673661530017853, 0.017183126881718636, 0.05120223015546799, 0.04658796265721321, 0.01062155794352293, 0.015622202306985855, 0.017075074836611748, 0.01364621426910162, 0.015216752886772156, 0.019511371850967407, 0.011106664314866066, 0.014739356935024261, 0.010785780847072601, 0.009001226164400578, 0.010783134028315544, 0.012424162589013577, 0.01052388921380043, 0.015232899226248264, 0.012698809616267681, 0.01273293700069189, 0.013579973950982094, 0.010236277244985104, 0.012397444806993008, 0.009453014470636845, 0.010430392809212208, 0.011005212552845478, 0.009151102975010872, 0.012203438207507133, 0.009068693034350872, 0.009711087681353092, 0.008781732991337776, 0.008229474537074566, 0.010262145660817623, 0.010236688889563084, 0.010204239748418331, 0.008296496234834194, 0.010923029854893684, 0.00945588294416666, 0.011303017847239971, 0.00820787250995636, 0.012193659320473671, 0.006696794647723436, 0.012072503566741943, 0.006136278621852398, 0.009859058074653149, 0.008026177063584328, 0.009486223571002483, 0.008378936909139156, 0.010838311165571213, 0.009234151802957058, 0.010003417730331421, 0.0069491127505898476, 0.0085842190310359, 0.008667370304465294, 0.009399629198014736, 0.00894227996468544, 0.007868955843150616, 0.00740796560421586, 0.008399457670748234, 0.009870490059256554, 0.01123284175992012, 0.005783144850283861, 0.00897462759166956, 0.0062180436216294765, 0.0034215368796139956, 0.0074971625581383705, 0.006735298316925764, 0.006660213693976402, 0.007263282313942909, 0.008068612776696682, 0.007176463026553392, 0.007691658101975918, 0.00771364476531744, 0.007871231064200401, 0.007622267585247755, 0.00793878547847271, 0.007455659564584494, 0.00759520661085844, 0.00735881645232439, 0.007547167595475912, 0.007401882670819759, 0.007520320825278759, 0.007383257150650024, 0.0073102377355098724, 0.007291282992810011, 0.007268768269568682, 0.0071226442232728004, 0.007194608449935913, 0.0072617256082594395, 0.007123888004571199, 0.007138390094041824, 0.007114463020116091, 0.0071001239120960236, 0.007095871493220329, 0.007049843668937683, 0.007028147112578154, 0.007019645534455776, 0.006987142376601696, 0.006965840235352516, 0.006965469568967819, 0.006934246979653835, 0.006920137442648411, 0.006895418278872967, 0.006881091743707657, 0.006860425230115652, 0.006845660042017698, 0.006826385855674744, 0.006810335908085108, 0.006792010739445686, 0.006778267677873373, 0.0067602782510221004, 0.006741780322045088, 0.006730182096362114, 0.006709547247737646, 0.006696504540741444, 0.0066810110583901405, 0.0066679697483778, 0.0066535272635519505, 0.006640746723860502, 0.006627073045819998, 0.006614472717046738, 0.006601832341402769, 0.006589086726307869, 0.006576948799192905, 0.0065663158893585205, 0.006554600782692432, 0.006542955990880728, 0.006531682796776295, 0.006521271541714668, 0.006511314772069454, 0.006501263007521629, 0.006491524633020163, 0.0064818719401955605, 0.006473584100604057, 0.006464917212724686, 0.006453651934862137, 0.006447129882872105, 0.006438340060412884, 0.006433091592043638, 0.006421483587473631, 0.006416960619390011, 0.006405588239431381, 0.0064027863554656506, 0.006392698269337416, 0.00638605048879981, 0.006379866506904364, 0.006380920764058828, 0.006368506699800491, 0.006370063871145248, 0.006358082871884108, 0.006360414903610945, 0.006350744981318712, 0.006349365226924419, 0.006344451103359461, 0.006340163294225931, 0.006336219608783722, 0.006333556957542896, 0.0063298651948571205, 0.006326799280941486, 0.0063240863382816315, 0.006322585511952639, 0.006320611108094454, 0.006318414118140936, 0.006317055318504572, 0.006315510254353285, 0.006314756814390421, 0.0063149346970021725, 0.006312258541584015, 0.00631281454116106, ]); var validFFT = { real: new Float32Array([ -0.19665084779262543, -0.19752468168735504, 0.36683952808380127, -0.2433284968137741, 0.48324400186538696, -0.05727904662489891, 0.2585470974445343, 0.10665424913167953, 0.07199767976999283, 0.22096122801303864, -0.07637365162372589, -0.15345974266529083, 0.0073951175436377525, 0.018520567566156387, 0.02713807113468647, 0.029163897037506104, 0.03566587343811989, -0.044555239379405975, 0.011641419492661953, -0.006447592284530401, 0.011403278447687626, -0.009334547445178032, -0.0047442726790905, -0.008093228563666344, -0.019951220601797104, -0.018373994156718254, 0.07639355957508087, -0.011358998715877533, 0.03888266533613205, 0.0034968173131346703, 0.0070980144664645195, -0.02688266895711422, 0.025376001372933388, -0.043581705540418625, 0.03376776725053787, -0.003065094817429781, 0.020791348069906235, 0.016667073592543602, 0.013580083847045898, 0.010121488012373447, 0.011874902062118053, 0.009539823047816753, 0.00959095824509859, 0.009431146085262299, 0.009135594591498375, 0.009086290374398232, 0.008232609368860722, 0.007974330335855484, 0.007991848513484001, 0.007485880516469479, 0.00723373144865036, 0.007032811176031828, 0.006953357253223658, 0.006927272770553827, 0.006759696640074253, 0.0064453016966581345, 0.006554528139531612, 0.008652739226818085, 0.004625708796083927, 0.005859009455889463, 0.006949464790523052, -0.003223725827410817, 0.0045992592349648476, 0.002923077903687954, 0.002486512530595064, 0.0005761167849414051, -0.0026042622048407793, 0.006519898306578398, -0.0022269380278885365, 0.016397951170802116, 0.0001522246457170695, 0.011844188906252384, 0.012074699625372887, 0.003284972859546542, 0.011473655700683594, 0.0020412669982761145, 0.014012168161571026, 0.007358142640441656, 0.007261600811034441, 0.0038233932573348284, 0.007721417583525181, 0.004036695696413517, 0.0006298600928857923, -0.010049507953226566, 0.0010332296369597316, -0.07787133753299713, 0.02331184409558773, 0.08912429958581924, 0.01535407267510891, 0.041799306869506836, 0.04321489855647087, 0.007313059642910957, 0.010057803243398666, 0.01242067851126194, 0.009817083366215229, 0.010617588646709919, 0.01676148921251297, 0.002485822420567274, 0.0026900183875113726, 0.008226996287703514, 0.007060603704303503, 0.0077970316633582115, 0.009426608681678772, 0.007362358272075653, 0.0091349883005023, 0.00871466938406229, 0.0077154794707894325, 0.009411475621163845, 0.00595090864226222, 0.009597858414053917, 0.005629582796245813, 0.004851765930652618, 0.006783735007047653, 0.006945793516933918, 0.008454684168100357, 0.005890170112252235, 0.0053056590259075165, 0.006906349211931229, 0.005137230269610882, 0.007416581269353628, 0.006845252122730017, 0.006610281765460968, 0.0056885299272835255, 0.008585539646446705, 0.006960442289710045, 0.008162051439285278, 0.005645608529448509, 0.00855440367013216, 0.0040309131145477295, 0.008840540423989296, 0.003720984561368823, 0.006988272536545992, 0.006515841465443373, 0.007293523754924536, 0.006819248199462891, 0.006574138533324003, 0.006817225366830826, 0.007057804148644209, 0.004834975115954876, 0.007327443920075893, 0.007043471559882164, 0.008074653334915638, 0.0069845858961343765, 0.006871236953884363, 0.006475189700722694, 0.007664144970476627, 0.006187759805470705, 0.00864401925355196, 0.004271855112165213, 0.004158757161349058, 0.005097470711916685, 0.003043494187295437, 0.005848107393831015, 0.005845715757459402, 0.006285677198320627, 0.0064400541596114635, 0.007056203670799732, 0.006167156621813774, 0.00666792131960392, 0.006738143041729927, 0.007025711704045534, 0.006782619282603264, 0.006766937207430601, 0.006693252827972174, 0.006672648712992668, 0.006510886363685131, 0.006521802861243486, 0.00646448228508234, 0.006618787534534931, 0.006626246031373739, 0.006372587755322456, 0.006422026548534632, 0.006534790154546499, 0.00639765989035368, 0.006459202151745558, 0.006494620349258184, 0.006421111524105072, 0.006446992978453636, 0.006438942160457373, 0.006432001944631338, 0.006441065110266209, 0.006432574242353439, 0.00641908822581172, 0.006432970520108938, 0.0064155892468988895, 0.0064157661981880665, 0.006421670317649841, 0.006413833238184452, 0.006415552459657192, 0.006406727246940136, 0.006407492328435183, 0.006402577273547649, 0.006401305086910725, 0.006397162098437548, 0.006395534612238407, 0.006390783935785294, 0.006391157396137714, 0.0063867466524243355, 0.006378623656928539, 0.006381320301443338, 0.006373580079525709, 0.006372799631208181, 0.006369728595018387, 0.006369008217006922, 0.006365716923028231, 0.006364297121763229, 0.006361851468682289, 0.006360107567161322, 0.006357864011079073, 0.006355467718094587, 0.006353544071316719, 0.006352653261274099, 0.006350608076900244, 0.0063482532277703285, 0.006346206180751324, 0.006344705354422331, 0.006343318149447441, 0.006341894157230854, 0.006340099964290857, 0.006338686216622591, 0.006337993778288364, 0.006337002385407686, 0.006332934368401766, 0.006333628669381142, 0.006331718526780605, 0.006332730874419212, 0.006327662616968155, 0.0063288332894444466, 0.00632462790235877, 0.006326642353087664, 0.006322877481579781, 0.006321584805846214, 0.006320431362837553, 0.006325934082269669, 0.00631851376965642, 0.006324665620923042, 0.006316954270005226, 0.0063230418600142, 0.006317440420389175, 0.006319508887827396, 0.006318141706287861, 0.006316909100860357, 0.00631600059568882, 0.0063161407597362995, 0.006314966361969709, 0.006314364727586508, 0.006313743535429239, 0.006314222235232592, 0.00631408067420125, 0.006313348188996315, 0.006313388701528311, 0.0063129388727247715, 0.006313106510788202, 0.006314004771411419, 0.006311849225312471, 0.006312710233032703, 0.00631279731169343, 0.006312710233032703, 0.006311849225312471, 0.006314004771411419, 0.006313106510788202, 0.0063129388727247715, 0.006313388701528311, 0.006313348188996315, 0.00631408067420125, 0.006314222235232592, 0.006313743535429239, 0.006314364727586508, 0.006314966361969709, 0.0063161407597362995, 0.00631600059568882, 0.006316909100860357, 0.006318141706287861, 0.006319508887827396, 0.006317440420389175, 0.0063230418600142, 0.006316954270005226, 0.006324665620923042, 0.00631851376965642, 0.006325934082269669, 0.006320431362837553, 0.006321584805846214, 0.006322877481579781, 0.006326642353087664, 0.00632462790235877, 0.0063288332894444466, 0.006327662616968155, 0.006332730874419212, 0.006331718526780605, 0.006333628669381142, 0.006332934368401766, 0.006337002385407686, 0.006337993778288364, 0.006338686216622591, 0.006340099964290857, 0.006341894157230854, 0.006343318149447441, 0.006344705354422331, 0.006346206180751324, 0.0063482532277703285, 0.006350608076900244, 0.006352653261274099, 0.006353544071316719, 0.006355467718094587, 0.006357864011079073, 0.006360107567161322, 0.006361851468682289, 0.006364297121763229, 0.006365716923028231, 0.006369008217006922, 0.006369728595018387, 0.006372799631208181, 0.006373580079525709, 0.006381320301443338, 0.006378623656928539, 0.0063867466524243355, 0.006391157396137714, 0.006390783935785294, 0.006395534612238407, 0.006397162098437548, 0.006401305086910725, 0.006402577273547649, 0.006407492328435183, 0.006406727246940136, 0.006415552459657192, 0.006413833238184452, 0.006421670317649841, 0.0064157661981880665, 0.0064155892468988895, 0.006432970520108938, 0.00641908822581172, 0.006432574242353439, 0.006441065110266209, 0.006432001944631338, 0.006438942160457373, 0.006446992978453636, 0.006421111524105072, 0.006494620349258184, 0.006459202151745558, 0.00639765989035368, 0.006534790154546499, 0.006422026548534632, 0.006372587755322456, 0.006626246031373739, 0.006618787534534931, 0.00646448228508234, 0.006521802861243486, 0.006510886363685131, 0.006672648712992668, 0.006693252827972174, 0.006766937207430601, 0.006782619282603264, 0.007025711704045534, 0.006738143041729927, 0.00666792131960392, 0.006167156621813774, 0.007056203670799732, 0.0064400541596114635, 0.006285677198320627, 0.005845715757459402, 0.005848107393831015, 0.003043494187295437, 0.005097470711916685, 0.004158757161349058, 0.004271855112165213, 0.00864401925355196, 0.006187759805470705, 0.007664144970476627, 0.006475189700722694, 0.006871236953884363, 0.0069845858961343765, 0.008074653334915638, 0.007043471559882164, 0.007327443920075893, 0.004834975115954876, 0.007057804148644209, 0.006817225366830826, 0.006574138533324003, 0.006819248199462891, 0.007293523754924536, 0.006515841465443373, 0.006988272536545992, 0.003720984561368823, 0.008840540423989296, 0.0040309131145477295, 0.00855440367013216, 0.005645608529448509, 0.008162051439285278, 0.006960442289710045, 0.008585539646446705, 0.0056885299272835255, 0.006610281765460968, 0.006845252122730017, 0.007416581269353628, 0.005137230269610882, 0.006906349211931229, 0.0053056590259075165, 0.005890170112252235, 0.008454684168100357, 0.006945793516933918, 0.006783735007047653, 0.004851765930652618, 0.005629582796245813, 0.009597858414053917, 0.00595090864226222, 0.009411475621163845, 0.0077154794707894325, 0.00871466938406229, 0.0091349883005023, 0.007362358272075653, 0.009426608681678772, 0.0077970316633582115, 0.007060603704303503, 0.008226996287703514, 0.0026900183875113726, 0.002485822420567274, 0.01676148921251297, 0.010617588646709919, 0.009817083366215229, 0.01242067851126194, 0.010057803243398666, 0.007313059642910957, 0.04321489855647087, 0.041799306869506836, 0.01535407267510891, 0.08912429958581924, 0.02331184409558773, -0.07787133753299713, 0.0010332296369597316, -0.010049507953226566, 0.0006298600928857923, 0.004036695696413517, 0.007721417583525181, 0.0038233932573348284, 0.007261600811034441, 0.007358142640441656, 0.014012168161571026, 0.0020412669982761145, 0.011473655700683594, 0.003284972859546542, 0.012074699625372887, 0.011844188906252384, 0.0001522246457170695, 0.016397951170802116, -0.0022269380278885365, 0.006519898306578398, -0.0026042622048407793, 0.0005761167849414051, 0.002486512530595064, 0.002923077903687954, 0.0045992592349648476, -0.003223725827410817, 0.006949464790523052, 0.005859009455889463, 0.004625708796083927, 0.008652739226818085, 0.006554528139531612, 0.0064453016966581345, 0.006759696640074253, 0.006927272770553827, 0.006953357253223658, 0.007032811176031828, 0.00723373144865036, 0.007485880516469479, 0.007991848513484001, 0.007974330335855484, 0.008232609368860722, 0.009086290374398232, 0.009135594591498375, 0.009431146085262299, 0.00959095824509859, 0.009539823047816753, 0.011874902062118053, 0.010121488012373447, 0.013580083847045898, 0.016667073592543602, 0.020791348069906235, -0.003065094817429781, 0.03376776725053787, -0.043581705540418625, 0.025376001372933388, -0.02688266895711422, 0.0070980144664645195, 0.0034968173131346703, 0.03888266533613205, -0.011358998715877533, 0.07639355957508087, -0.018373994156718254, -0.019951220601797104, -0.008093228563666344, -0.0047442726790905, -0.009334547445178032, 0.011403278447687626, -0.006447592284530401, 0.011641419492661953, -0.044555239379405975, 0.03566587343811989, 0.029163897037506104, 0.02713807113468647, 0.018520567566156387, 0.0073951175436377525, -0.15345974266529083, -0.07637365162372589, 0.22096122801303864, 0.07199767976999283, 0.10665424913167953, 0.2585470974445343, -0.05727904662489891, 0.48324400186538696, -0.2433284968137741, 0.36683952808380127, -0.19752468168735504, ]), imag: new Float32Array([ 0, -0.12676763534545898, 0.8021179437637329, -0.039897620677948, 0.2421717494726181, -0.1622326523065567, 0.41217106580734253, -0.01113172434270382, 0.1983414888381958, 0.02602989412844181, 0.19817514717578888, 0.16816014051437378, 0.121039979159832, 0.06338734179735184, 0.09407523274421692, 0.049192123115062714, 0.05336914211511612, 0.059572841972112656, 0.058667831122875214, 0.05413154140114784, 0.04347118362784386, 0.05269097536802292, 0.027818525210022926, 0.0502236932516098, -0.01919364556670189, 0.051973242312669754, 0.006289381068199873, 0.02170877903699875, 0.05919693410396576, 0.048069652169942856, 0.03294661268591881, 0.04004021733999252, 0.014796585775911808, -0.0115040959790349, 0.05006280541419983, 0.10161030292510986, 0.02352386899292469, 0.04396252706646919, 0.021815525367856026, 0.026368871331214905, 0.02299046702682972, 0.02382810227572918, 0.02211575023829937, 0.021913623437285423, 0.021094918251037598, 0.020787324756383896, 0.020559795200824738, 0.01982422173023224, 0.01951872929930687, 0.019022200256586075, 0.018507424741983414, 0.018253885209560394, 0.01787342131137848, 0.017640581354498863, 0.01687212474644184, 0.017022427171468735, 0.016161462292075157, 0.017617810517549515, 0.015405392274260521, 0.014583062380552292, 0.016538964584469795, 0.01785600371658802, 0.014865529723465443, 0.015696464106440544, 0.01566978543996811, 0.017236877232789993, 0.021969854831695557, -0.011052245274186134, -0.000812496233265847, 0.012052458710968494, 0.004149705171585083, 0.014021171256899834, 0.013071797788143158, 0.01485608983784914, 0.009315772913396358, 0.01262175478041172, 0.010236813686788082, 0.01246358547359705, 0.009217197075486183, 0.012097411789000034, 0.006782224867492914, 0.007647289894521236, 0.004138629883527756, 0.009302712976932526, -0.021487632766366005, -0.11582650989294052, 0.030328072607517242, -0.05873299390077591, -0.007714421022683382, 0.029571712017059326, 0.017404330894351006, 0.007703028153628111, 0.011953819543123245, 0.011716864071786404, 0.009478610008955002, 0.010900292545557022, 0.009987298399209976, 0.01082491036504507, 0.01449180580675602, 0.006974926218390465, 0.0055830045603215694, 0.007448642048984766, 0.008093137294054031, 0.007519835140556097, 0.012189880944788456, 0.009236574172973633, 0.010129119269549847, 0.009789781644940376, 0.008328748866915703, 0.007847148925065994, 0.007593897171318531, 0.009233280085027218, 0.008665774017572403, 0.005958073772490025, 0.008800125680863857, 0.00689544016495347, 0.008133584633469582, 0.00542412931099534, 0.0064290836453437805, 0.007092669606208801, 0.007611329201608896, 0.007773717865347862, 0.006039245054125786, 0.006752858404070139, 0.006400465499609709, 0.007819151505827904, 0.005957874469459057, 0.008689505979418755, 0.005347784608602524, 0.008221324533224106, 0.004879363812506199, 0.006954500451683998, 0.004686504602432251, 0.00606571976095438, 0.004868720658123493, 0.008616825565695763, 0.006228562910109758, 0.007089129649102688, 0.004991310648620129, 0.004471842665225267, 0.005051021464169025, 0.004811757244169712, 0.005583899561315775, 0.003834914183244109, 0.003598593408241868, 0.003436826402321458, 0.007690136320888996, 0.007173399440944195, 0.003898206865414977, 0.00795290432870388, 0.003560879034921527, 0.0015633482253178954, 0.004691171459853649, 0.0033454219810664654, 0.002201977651566267, 0.003358715446665883, 0.003913119900971651, 0.00366985029540956, 0.0038341134786605835, 0.003754695877432823, 0.003549035172909498, 0.0034777927212417126, 0.004151250701397657, 0.0032843907829374075, 0.0036280741915106773, 0.0034293641801923513, 0.0037981343921273947, 0.003605320118367672, 0.0035702765453606844, 0.0032565852161496878, 0.003581857308745384, 0.003452590899541974, 0.0031830030493438244, 0.0031308161560446024, 0.003168769646435976, 0.003248471301048994, 0.0030853047501295805, 0.003064783290028572, 0.0030258235055953264, 0.003006843850016594, 0.0029772589914500713, 0.0028848371002823114, 0.002861845539882779, 0.002809325698763132, 0.002767738187685609, 0.0027130928356200457, 0.0026981316041201353, 0.0026356265880167484, 0.002594029763713479, 0.0025496354792267084, 0.0025086775422096252, 0.0024642320349812508, 0.002426180988550186, 0.0023824062664061785, 0.0023404727689921856, 0.002299846149981022, 0.002257879124954343, 0.002216038526967168, 0.002182832919061184, 0.002138714771717787, 0.0020965454168617725, 0.0020568417385220528, 0.002015555975958705, 0.0019742229487746954, 0.0019357356941327453, 0.001896112342365086, 0.0018560552271082997, 0.0018166668014600873, 0.001778132515028119, 0.0017389915883541107, 0.0016996278427541256, 0.001661416026763618, 0.0016225191066041589, 0.0015842837747186422, 0.001545493258163333, 0.0015072152018547058, 0.001469536335207522, 0.0014306644443422556, 0.001393923768773675, 0.0013548876158893108, 0.0013180007226765156, 0.0012796694645658135, 0.0012424042215570807, 0.0012044224422425032, 0.0011668613879010081, 0.0011318946490064263, 0.0010936807375401258, 0.001059835427440703, 0.00101520586758852, 0.000984514714218676, 0.0009422375005669892, 0.0009051006054505706, 0.0008688165689818561, 0.000835888902656734, 0.0007964043179526925, 0.0007591552566736937, 0.0007220158004201949, 0.0006884903414174914, 0.000649545225314796, 0.000615015160292387, 0.0005771868163719773, 0.0005425234558060765, 0.0005057844682596624, 0.00046936928993090987, 0.00043404396274127066, 0.0003964655043091625, 0.00036154271219857037, 0.00032509685843251646, 0.0002872466866392642, 0.0002529642661102116, 0.0002152013621525839, 0.00018019504204858094, 0.00014435929188039154, 0.00010835941066034138, 0.00007186409493442625, 0.00003627773548942059, 0, -0.00003627773548942059, -0.00007186409493442625, -0.00010835941066034138, -0.00014435929188039154, -0.00018019504204858094, -0.0002152013621525839, -0.0002529642661102116, -0.0002872466866392642, -0.00032509685843251646, -0.00036154271219857037, -0.0003964655043091625, -0.00043404396274127066, -0.00046936928993090987, -0.0005057844682596624, -0.0005425234558060765, -0.0005771868163719773, -0.000615015160292387, -0.000649545225314796, -0.0006884903414174914, -0.0007220158004201949, -0.0007591552566736937, -0.0007964043179526925, -0.000835888902656734, -0.0008688165689818561, -0.0009051006054505706, -0.0009422375005669892, -0.000984514714218676, -0.00101520586758852, -0.001059835427440703, -0.0010936807375401258, -0.0011318946490064263, -0.0011668613879010081, -0.0012044224422425032, -0.0012424042215570807, -0.0012796694645658135, -0.0013180007226765156, -0.0013548876158893108, -0.001393923768773675, -0.0014306644443422556, -0.001469536335207522, -0.0015072152018547058, -0.001545493258163333, -0.0015842837747186422, -0.0016225191066041589, -0.001661416026763618, -0.0016996278427541256, -0.0017389915883541107, -0.001778132515028119, -0.0018166668014600873, -0.0018560552271082997, -0.001896112342365086, -0.0019357356941327453, -0.0019742229487746954, -0.002015555975958705, -0.0020568417385220528, -0.0020965454168617725, -0.002138714771717787, -0.002182832919061184, -0.002216038526967168, -0.002257879124954343, -0.002299846149981022, -0.0023404727689921856, -0.0023824062664061785, -0.002426180988550186, -0.0024642320349812508, -0.0025086775422096252, -0.0025496354792267084, -0.002594029763713479, -0.0026356265880167484, -0.0026981316041201353, -0.0027130928356200457, -0.002767738187685609, -0.002809325698763132, -0.002861845539882779, -0.0028848371002823114, -0.0029772589914500713, -0.003006843850016594, -0.0030258235055953264, -0.003064783290028572, -0.0030853047501295805, -0.003248471301048994, -0.003168769646435976, -0.0031308161560446024, -0.0031830030493438244, -0.003452590899541974, -0.003581857308745384, -0.0032565852161496878, -0.0035702765453606844, -0.003605320118367672, -0.0037981343921273947, -0.0034293641801923513, -0.0036280741915106773, -0.0032843907829374075, -0.004151250701397657, -0.0034777927212417126, -0.003549035172909498, -0.003754695877432823, -0.0038341134786605835, -0.00366985029540956, -0.003913119900971651, -0.003358715446665883, -0.002201977651566267, -0.0033454219810664654, -0.004691171459853649, -0.0015633482253178954, -0.003560879034921527, -0.00795290432870388, -0.003898206865414977, -0.007173399440944195, -0.007690136320888996, -0.003436826402321458, -0.003598593408241868, -0.003834914183244109, -0.005583899561315775, -0.004811757244169712, -0.005051021464169025, -0.004471842665225267, -0.004991310648620129, -0.007089129649102688, -0.006228562910109758, -0.008616825565695763, -0.004868720658123493, -0.00606571976095438, -0.004686504602432251, -0.006954500451683998, -0.004879363812506199, -0.008221324533224106, -0.005347784608602524, -0.008689505979418755, -0.005957874469459057, -0.007819151505827904, -0.006400465499609709, -0.006752858404070139, -0.006039245054125786, -0.007773717865347862, -0.007611329201608896, -0.007092669606208801, -0.0064290836453437805, -0.00542412931099534, -0.008133584633469582, -0.00689544016495347, -0.008800125680863857, -0.005958073772490025, -0.008665774017572403, -0.009233280085027218, -0.007593897171318531, -0.007847148925065994, -0.008328748866915703, -0.009789781644940376, -0.010129119269549847, -0.009236574172973633, -0.012189880944788456, -0.007519835140556097, -0.008093137294054031, -0.007448642048984766, -0.0055830045603215694, -0.006974926218390465, -0.01449180580675602, -0.01082491036504507, -0.009987298399209976, -0.010900292545557022, -0.009478610008955002, -0.011716864071786404, -0.011953819543123245, -0.007703028153628111, -0.017404330894351006, -0.029571712017059326, 0.007714421022683382, 0.05873299390077591, -0.030328072607517242, 0.11582650989294052, 0.021487632766366005, -0.009302712976932526, -0.004138629883527756, -0.007647289894521236, -0.006782224867492914, -0.012097411789000034, -0.009217197075486183, -0.01246358547359705, -0.010236813686788082, -0.01262175478041172, -0.009315772913396358, -0.01485608983784914, -0.013071797788143158, -0.014021171256899834, -0.004149705171585083, -0.012052458710968494, 0.000812496233265847, 0.011052245274186134, -0.021969854831695557, -0.017236877232789993, -0.01566978543996811, -0.015696464106440544, -0.014865529723465443, -0.01785600371658802, -0.016538964584469795, -0.014583062380552292, -0.015405392274260521, -0.017617810517549515, -0.016161462292075157, -0.017022427171468735, -0.01687212474644184, -0.017640581354498863, -0.01787342131137848, -0.018253885209560394, -0.018507424741983414, -0.019022200256586075, -0.01951872929930687, -0.01982422173023224, -0.020559795200824738, -0.020787324756383896, -0.021094918251037598, -0.021913623437285423, -0.02211575023829937, -0.02382810227572918, -0.02299046702682972, -0.026368871331214905, -0.021815525367856026, -0.04396252706646919, -0.02352386899292469, -0.10161030292510986, -0.05006280541419983, 0.0115040959790349, -0.014796585775911808, -0.04004021733999252, -0.03294661268591881, -0.048069652169942856, -0.05919693410396576, -0.02170877903699875, -0.006289381068199873, -0.051973242312669754, 0.01919364556670189, -0.0502236932516098, -0.027818525210022926, -0.05269097536802292, -0.04347118362784386, -0.05413154140114784, -0.058667831122875214, -0.059572841972112656, -0.05336914211511612, -0.049192123115062714, -0.09407523274421692, -0.06338734179735184, -0.121039979159832, -0.16816014051437378, -0.19817514717578888, -0.02602989412844181, -0.1983414888381958, 0.01113172434270382, -0.41217106580734253, 0.1622326523065567, -0.2421717494726181, 0.039897620677948, -0.8021179437637329, 0.12676763534545898, ]), length: 512, }; var expectedPowerSpectrumOutput = new Float32Array([ 0.03867155686020851, 0.055086031556129456, 0.7779644131660461, 0.06080057471990585, 0.2921719253063202, 0.029600320383906364, 0.2367316037416458, 0.011499044485390186, 0.04452301189303398, 0.04950142279267311, 0.045106325298547745, 0.051827725023031235, 0.014705364592373371, 0.0043609668500721455, 0.00958662386983633, 0.0032703978940844536, 0.004120319616049528, 0.0055340928956866264, 0.003577437251806259, 0.002971795154735446, 0.0020197785925120115, 0.002863472793251276, 0.0007963784737512469, 0.0025879195891320705, 0.0007664472213946283, 0.003038821741938591, 0.005875532049685717, 0.0006002979935146868, 0.005016138777136803, 0.0023229194339364767, 0.0011358610354363918, 0.0023258968722075224, 0.0008628804353065789, 0.002031709300354123, 0.0036465467419475317, 0.010334047488868237, 0.0009856525575742126, 0.002210495062172413, 0.0006603358197025955, 0.0007977619534358382, 0.0006695748306810856, 0.0006587866810150445, 0.0005810929578728974, 0.000569153402466327, 0.0005284546641632915, 0.0005146735929884017, 0.0004904810339212418, 0.00045658971066586673, 0.00044485044782049954, 0.00041788251837715507, 0.00039485160959884524, 0.0003826647880487144, 0.0003678083885461092, 0.00035917721106670797, 0.0003303621197119355, 0.00033130490919575095, 0.0003041547315660864, 0.0003852571244351566, 0.0002587233029771596, 0.00024699370260350406, 0.0003218324272893369, 0.0003292292822152376, 0.00024213717551901937, 0.00025492339045740664, 0.0002517249376978725, 0.00029744187486357987, 0.0004894566955044866, 0.00016466120723634958, 0.000005619402600132162, 0.00041415455052629113, 0.000017243226466234773, 0.00033687808900140226, 0.0003166702517773956, 0.0002314944431418553, 0.00021842840942554176, 0.00016347545897588134, 0.0003011332009918988, 0.0002094832161674276, 0.0001376875734422356, 0.00016096570470836014, 0.00010561885574134067, 0.00007477594772353768, 0.000017524980648886412, 0.00018753306358121336, 0.0004627859452739358, 0.019479725509881973, 0.0014632339589297771, 0.011392705142498016, 0.0002952598442789167, 0.002621668390929699, 0.00217043817974627, 0.00011281749175395817, 0.0002440532116452232, 0.00029155818629078567, 0.00018621915660332888, 0.00023154956579674035, 0.00038069364381954074, 0.00012335799692664295, 0.00021724864200223237, 0.00011633306712610647, 0.0000810220735729672, 0.00011627597996266559, 0.00015435981913469732, 0.00011075224756496027, 0.00023204121680464596, 0.00016125976981129497, 0.00016212768969126046, 0.0001844156940933317, 0.00010478137119207531, 0.00015369664470199496, 0.00008935948426369578, 0.00010879309411393479, 0.00012111470277886838, 0.00008374268509214744, 0.0001489239075453952, 0.0000822411966510117, 0.00009430522186448798, 0.0000771188351791352, 0.00006772424967493862, 0.00010531163570703939, 0.00010478979675099254, 0.00010412650590296835, 0.00006883184687467292, 0.0001193125790450722, 0.0000894137192517519, 0.00012775821960531175, 0.00006736916839145124, 0.00014868532889522612, 0.00004484706005314365, 0.00014574534725397825, 0.00003765391375054605, 0.00009720102389110252, 0.00006441951700253412, 0.00008998843986773863, 0.00007020658085821196, 0.00011746898962883279, 0.00008526955934939906, 0.000100068369647488, 0.00004829016688745469, 0.00007368881779257208, 0.00007512330921599641, 0.00008835303015075624, 0.00007996436761459336, 0.00006192046566866338, 0.000054877953516552225, 0.00007055088644847274, 0.0000974265713011846, 0.00012617673201020807, 0.00003344476499478333, 0.00008054394129430875, 0.0000386640676879324, 0.000011706914847309235, 0.00005620744559564628, 0.00004536424239631742, 0.00004435844675754197, 0.00005275526928016916, 0.00006510251114377752, 0.000051501621783245355, 0.00005916160444030538, 0.00005950031481916085, 0.0000619562779320404, 0.000058098961744690314, 0.00006302431575022638, 0.00005558686098083854, 0.000057687164371600375, 0.000054152180382516235, 0.000056959739595185965, 0.00005478786624735221, 0.000056555225455667824, 0.0000545124858035706, 0.00005343957673176192, 0.000053162806580075994, 0.00005283499194774777, 0.00005073206193628721, 0.00005176239210413769, 0.000052732659241883084, 0.000050749778893077746, 0.00005095661254017614, 0.000050615584768820554, 0.00005041175973019563, 0.00005035139110987075, 0.00004970029476680793, 0.00004939485006616451, 0.0000492754224978853, 0.00004882015855400823, 0.000048522928409511223, 0.00004851776611758396, 0.00004808378071174957, 0.00004788830119650811, 0.00004754679321194999, 0.00004734942194772884, 0.00004706543404608965, 0.00004686306056100875, 0.00004659954356611706, 0.00004638067548512481, 0.0000461314084532205, 0.00004594491110765375, 0.00004570136297843419, 0.000045451601181412116, 0.00004529534999164753, 0.00004501802322920412, 0.000044843174691777676, 0.00004463590812520124, 0.00004446181992534548, 0.000044269425416132435, 0.000044099517253926024, 0.000043918098526773974, 0.00004375124990474433, 0.00004358419027994387, 0.00004341606472735293, 0.00004325625559431501, 0.00004311650263844058, 0.00004296279075788334, 0.00004281027213437483, 0.000042662879423005506, 0.000042526982724666595, 0.00004239721965859644, 0.000042266419768566266, 0.000042139890865655616, 0.000042014664359157905, 0.00004190728941466659, 0.000041795155993895605, 0.00004164962228969671, 0.00004156548311584629, 0.000041452221921645105, 0.00004138466829317622, 0.000041235452954424545, 0.00004117738353670575, 0.00004103156243218109, 0.00004099567377124913, 0.0000408665910072159, 0.000040781640564091504, 0.000040702696423977613, 0.00004071614966960624, 0.000040557879401603714, 0.00004057771366205998, 0.00004042521686642431, 0.000040454877307638526, 0.00004033196091768332, 0.000040314440411748365, 0.00004025205998914316, 0.00004019767220597714, 0.00004014767910121009, 0.000040113944123731926, 0.00004006719245808199, 0.00004002838977612555, 0.00003999406908405945, 0.00003997508611064404, 0.000039950125938048586, 0.000039922357245814055, 0.00003990518962382339, 0.000039885668229544535, 0.00003987615491496399, 0.000039878399547887966, 0.00003984460636274889, 0.00003985162766184658, ]); var barkScale = new Float32Array([ 0, 0.8502324223518372, 1.694183111190796, 2.5250110626220703, 3.336550712585449, 4.123549461364746, 4.881809711456299, 5.60823392868042, 6.300786972045898, 6.9583940505981445, 7.580804347991943, 8.168436050415039, 8.722225189208984, 9.243483543395996, 9.733778953552246, 10.194833755493164, 10.628447532653809, 11.036436080932617, 11.420586585998535, 11.782628059387207, 12.124208450317383, 12.446884155273438, 12.752114295959473, 13.041257858276367, 13.315570831298828, 13.576218605041504, 13.824270248413086, 14.060709953308105, 14.286441802978516, 14.502294540405273, 14.709027290344238, 14.907334327697754, 15.097854614257812, 15.281168937683105, 15.457812309265137, 15.628273963928223, 15.793001174926758, 15.95240592956543, 16.106861114501953, 16.256715774536133, 16.40228271484375, 16.543851852416992, 16.68168830871582, 16.816038131713867, 16.947120666503906, 17.075143814086914, 17.20029067993164, 17.322736740112305, 17.44263458251953, 17.560131072998047, 17.675357818603516, 17.788429260253906, 17.899459838867188, 18.008546829223633, 18.115779876708984, 18.221240997314453, 18.32500648498535, 18.427141189575195, 18.5277099609375, 18.62676239013672, 18.72435188293457, 18.82052230834961, 18.915313720703125, 19.008760452270508, 19.100894927978516, 19.191747665405273, 19.281343460083008, 19.36970329284668, 19.45684814453125, 19.542797088623047, 19.627565383911133, 19.71116828918457, 19.79361915588379, 19.87492561340332, 19.955102920532227, 20.03415870666504, 20.112102508544922, 20.188940048217773, 20.26468276977539, 20.339336395263672, 20.412906646728516, 20.485403060913086, 20.55683135986328, 20.627199172973633, 20.69651222229004, 20.76477813720703, 20.83200454711914, 20.89820098876953, 20.96337127685547, 21.02752685546875, 21.090675354003906, 21.15282440185547, 21.2139835357666, 21.27416229248047, 21.333370208740234, 21.391616821289062, 21.44891357421875, 21.505268096923828, 21.56069564819336, 21.615201950073242, 21.66880226135254, 21.721508026123047, 21.773326873779297, 21.824275970458984, 21.87436294555664, 21.923601150512695, 21.972003936767578, 22.01958465576172, 22.06635284423828, 22.112321853637695, 22.15750503540039, 22.201915740966797, 22.24556541442871, 22.28846549987793, 22.330629348754883, 22.372072219848633, 22.41280174255371, 22.452835083007812, 22.4921817779541, 22.530853271484375, 22.568864822387695, 22.606224060058594, 22.642948150634766, 22.679046630859375, 22.714529037475586, 22.749408721923828, 22.78369903564453, 22.817407608032227, 22.850547790527344, 22.88313102722168, 22.915164947509766, 22.946664810180664, 22.977636337280273, 23.008092880249023, 23.038043975830078, 23.06749725341797, 23.096466064453125, 23.124958038330078, 23.152984619140625, 23.180551528930664, 23.207670211791992, 23.23434829711914, 23.260595321655273, 23.286420822143555, 23.311830520629883, 23.336835861206055, 23.36144256591797, 23.38566017150879, 23.409494400024414, 23.432954788208008, 23.45604705810547, 23.47878074645996, 23.501161575317383, 23.523195266723633, 23.544889450073242, 23.566253662109375, 23.587289810180664, 23.608007431030273, 23.6284122467041, 23.648509979248047, 23.668306350708008, 23.687808990478516, 23.707019805908203, 23.725948333740234, 23.744598388671875, 23.762975692749023, 23.781084060668945, 23.798931121826172, 23.81652069091797, 23.8338565826416, 23.85094451904297, 23.86779022216797, 23.884397506713867, 23.90077018737793, 23.916912078857422, 23.932830810546875, 23.94852638244629, 23.964006423950195, 23.979272842407227, 23.99432945251465, 24.00918197631836, 24.023832321166992, 24.038286209106445, 24.05254364013672, 24.066612243652344, 24.08049201965332, 24.09419059753418, 24.10770606994629, 24.12104606628418, 24.13421058654785, 24.14720344543457, 24.160030364990234, 24.172691345214844, 24.185190200805664, 24.197528839111328, 24.209712982177734, 24.22174072265625, 24.233619689941406, 24.24534797668457, 24.25693130493164, 24.26837158203125, 24.27967071533203, 24.290830612182617, 24.30185317993164, 24.312744140625, 24.323501586914062, 24.334129333496094, 24.34463119506836, 24.355005264282227, 24.365259170532227, 24.375389099121094, 24.385400772094727, 24.395296096801758, 24.405075073242188, 24.41474151611328, 24.42429542541504, 24.433738708496094, 24.44307518005371, 24.45230484008789, 24.461429595947266, 24.47045135498047, 24.479372024536133, 24.488191604614258, 24.49691390991211, 24.505538940429688, 24.514068603515625, 24.522504806518555, 24.53084945678711, 24.53910255432129, 24.547266006469727, 24.555341720581055, 24.563329696655273, 24.57123374938965, 24.579051971435547, 24.586788177490234, 24.594440460205078, 24.602014541625977, 24.609508514404297, 24.616924285888672, 24.624263763427734, 24.631526947021484, 24.638713836669922, 24.645828247070312, 24.652870178222656, 24.659839630126953, 24.66674041748047, 24.67357063293457, 24.680330276489258, 24.68702507019043, 24.69365119934082, 24.700212478637695, 24.706708908081055, 24.71314239501953, 24.719511032104492, 24.725818634033203, 24.732065200805664, 24.738250732421875, 24.74437713623047, 24.750444412231445, 24.756454467773438, 24.762407302856445, 24.76830291748047, 24.774141311645508, 24.77992820739746, 24.78565788269043, 24.791336059570312, 24.796960830688477, 24.802532196044922, 24.808053970336914, 24.81352424621582, 24.818944931030273, 24.824316024780273, 24.82963752746582, 24.83491325378418, 24.840139389038086, 24.845319747924805, 24.850452423095703, 24.855539321899414, 24.86058235168457, 24.865581512451172, 24.870534896850586, 24.875444412231445, 24.880311965942383, 24.8851375579834, 24.889921188354492, 24.894662857055664, 24.899364471435547, 24.90402603149414, 24.908647537231445, 24.91322898864746, 24.91777229309082, 24.92227554321289, 24.926742553710938, 24.931171417236328, 24.935564041137695, 24.93992042541504, 24.944238662719727, 24.948522567749023, 24.95277214050293, 24.956985473632812, 24.961164474487305, 24.965309143066406, 24.969419479370117, 24.973499298095703, 24.977542877197266, 24.981555938720703, 24.985536575317383, 24.989486694335938, 24.9934024810791, 24.997289657592773, 25.001144409179688, 25.00497055053711, 25.008766174316406, 25.012531280517578, 25.016267776489258, 25.019975662231445, 25.02365493774414, 25.02730369567871, 25.030925750732422, 25.034521102905273, 25.038087844848633, 25.041627883911133, 25.045141220092773, 25.048627853393555, 25.052087783813477, 25.055522918701172, 25.058931350708008, 25.062314987182617, 25.065673828125, 25.069005966186523, 25.072315216064453, 25.075599670410156, 25.078859329223633, 25.082096099853516, 25.085308074951172, 25.088499069213867, 25.091665267944336, 25.09480857849121, 25.097929000854492, 25.101028442382812, 25.10410499572754, 25.107158660888672, 25.110191345214844, 25.113203048706055, 25.116193771362305, 25.11916160583496, 25.12211036682129, 25.125038146972656, 25.127944946289062, 25.13083267211914, 25.133699417114258, 25.136547088623047, 25.139373779296875, 25.142183303833008, 25.14497184753418, 25.147741317749023, 25.150493621826172, 25.15322494506836, 25.15593910217285, 25.15863609313965, 25.161312103271484, 25.163972854614258, 25.166614532470703, 25.169239044189453, 25.171846389770508, 25.174436569213867, 25.1770076751709, 25.179563522338867, 25.182104110717773, 25.18462562561035, 25.187131881713867, 25.189620971679688, 25.192094802856445, 25.194551467895508, 25.19699478149414, 25.199420928955078, 25.20182991027832, 25.204225540161133, 25.206605911254883, 25.208969116210938, 25.211318969726562, 25.213655471801758, 25.215974807739258, 25.218280792236328, 25.220571517944336, 25.222848892211914, 25.22511100769043, 25.227359771728516, 25.229595184326172, 25.231815338134766, 25.23402214050293, 25.236215591430664, 25.23839569091797, 25.240564346313477, 25.242717742919922, 25.244857788085938, 25.246986389160156, 25.249099731445312, 25.251203536987305, 25.253292083740234, 25.255369186401367, 25.25743293762207, 25.259485244750977, 25.261526107788086, 25.263553619384766, 25.26556968688965, 25.267574310302734, 25.269567489624023, 25.271547317504883, 25.273517608642578, 25.275474548339844, 25.277420043945312, 25.279356002807617, 25.281278610229492, 25.283191680908203, 25.285093307495117, 25.286985397338867, 25.288864135742188, 25.290733337402344, 25.292593002319336, 25.29444122314453, 25.29627799987793, 25.298105239868164, 25.299922943115234, 25.301729202270508, 25.303525924682617, 25.30531120300293, 25.30708885192871, 25.308855056762695, 25.310611724853516, 25.312358856201172, 25.314096450805664, 25.315824508666992, 25.317543029785156, 25.319252014160156, 25.320951461791992, 25.322641372680664, 25.324323654174805, 25.32599639892578, 25.32765769958496, 25.329313278198242, 25.330957412719727, 25.33259391784668, 25.3342227935791, 25.335840225219727, 25.337451934814453, 25.339052200317383, 25.340646743774414, 25.34222984313965, 25.343807220458984, 25.345375061035156, 25.346935272216797, 25.348485946655273, 25.35003089904785, 25.351566314697266, 25.35309410095215, 25.354612350463867, 25.356124877929688, 25.357629776000977, 25.3591251373291, 25.360612869262695, 25.36209487915039, 25.363567352294922, 25.365034103393555, 25.366491317749023, 25.367942810058594, 25.369386672973633, 25.37082290649414, 25.372251510620117, 25.373672485351562, 25.37508773803711, 25.376495361328125, 25.37789535522461, 25.379289627075195, 25.38067626953125, 25.382055282592773, 25.3834285736084, 25.384794235229492, 25.386154174804688, 25.38750648498535, 25.388853073120117, 25.39019203186035, 25.391525268554688, 25.392852783203125, 25.39417266845703, 25.395484924316406, 25.396793365478516, 25.398094177246094, 25.399389266967773, 25.400676727294922, 25.401958465576172, 25.403234481811523, 25.404504776000977, 25.40576934814453, 25.407026290893555, 25.408279418945312, 25.40952491760254, 25.410764694213867, 25.411998748779297, 25.41322898864746, 25.414451599121094, 25.415668487548828, 25.416879653930664, 25.4180850982666, 25.41928482055664, 25.42047882080078, 25.421669006347656, 25.4228515625, 25.424030303955078, 25.425203323364258, 25.426368713378906, 25.427532196044922, ]); const expectedChromagramOutput = new Float32Array([ 0.889173501932042, 0.8377149437424725, 0.7983608438722133, 0.8340835109903056, 0.9257658376982487, 0.9697310997078421, 1, 0.8781674865696717, 0.7889747445705728, 0.7880426774703064, 0.9250473589362254, 0.8824577772499042, ]); export default { VALID_SIGNAL: validSignal, VALID_AMPLITUDE_SPECTRUM: validAmpSpec, VALID_FFT: validFFT, VALID_BARK_SCALE: barkScale, EXPECTED_POWER_SPECTRUM_OUTPUT: expectedPowerSpectrumOutput, EXPECTED_CHROMAGRAM_OUTPUT: expectedChromagramOutput, }; ================================================ FILE: __tests__/data/blackman1024.json ================================================ [ -1.3877787807814457e-17, 3.3951337172766216e-06, 1.358109057036927e-05, 3.055953493458219e-05, 5.433323894976638e-05, 8.490608888678253e-05, 0.00012228307605255395, 0.00016647028678562492, 0.00021747495338786393, 0.00027530535589903593, 0.00033997089485637844, 0.000411482120398432, 0.000489850586745888, 0.0005750890704803169, 0.0006672112504020333, 0.000766232144087553, 0.0008721675840206444, 0.000985034741461277, 0.0011048517189919949, 0.0012316375505179167, 0.0013654128415510058, 0.001506198663264513, 0.0016540174838155508, 0.0018088927026838064, 0.001970848999917507, 0.0021399117540568113, 0.0023161075077950954, 0.002499464200809598, 0.0026900102384388447, 0.0028877751901745796, 0.003092789789661765, 0.0033050859346985817, 0.003524696221575141, 0.0037516544107347727, 0.003985994961112738, 0.004227753262966871, 0.004476966802030802, 0.0047336723655462265, 0.004997908603399992, 0.005269715096801519, 0.005549132823944092, 0.005836201831698418, 0.006130965426564217, 0.006433466449379921, 0.006743749137967825, 0.007061857730150223, 0.007387838792055845, 0.007721738424152136, 0.008063605055212975, 0.008413486182689667, 0.00877143070101738, 0.009137489832937717, 0.009511712938547134, 0.009894154034554958, 0.010284862481057644, 0.010683894157409668, 0.011091301217675209, 0.011507139541208744, 0.0119314631447196, 0.012364329770207405, 0.012805796228349209, 0.013255918398499489, 0.013714756816625595, 0.01418236829340458, 0.014658814296126366, 0.015144153498113155, 0.015638448297977448, 0.016141757369041443, 0.01665414683520794, 0.01717567630112171, 0.017706410959362984, 0.01824641227722168, 0.018795747309923172, 0.019354479387402534, 0.01992267370223999, 0.02050039730966091, 0.02108771540224552, 0.021684695035219193, 0.022291403263807297, 0.022907909005880356, 0.023534279316663742, 0.024170581251382828, 0.024816887453198433, 0.02547326497733593, 0.02613978274166584, 0.026816511526703835, 0.027503522112965584, 0.02820088528096676, 0.02890866994857788, 0.02962694875895977, 0.030355794355273247, 0.031095275655388832, 0.031845465302467346, 0.03260643407702446, 0.03337825834751129, 0.034161005169153214, 0.034954752773046494, 0.035759568214416504, 0.036575525999069214, 0.03740270063281059, 0.03824116289615631, 0.03909098729491234, 0.039952244609594345, 0.0408250093460083, 0.041709356009960175, 0.04260535538196564, 0.04351307824254036, 0.04443260282278061, 0.04536399617791176, 0.04630733281373978, 0.04726269096136093, 0.0482301339507103, 0.04920973628759384, 0.050201576203107834, 0.05120571702718735, 0.05222223699092865, 0.053251203149557114, 0.05429269000887871, 0.0553467683494091, 0.056413501501083374, 0.05749296769499779, 0.058585237711668015, 0.05969037488102913, 0.0608084499835968, 0.061939533799886703, 0.0630836933851242, 0.06424099951982498, 0.0654115155339241, 0.06659531593322754, 0.06779245287179947, 0.06900300830602646, 0.07022703438997269, 0.07146460562944412, 0.07271578162908554, 0.07398062944412231, 0.07525921612977982, 0.07655159384012222, 0.07785782963037491, 0.07917798310518265, 0.08051211386919022, 0.08186028897762299, 0.08322256803512573, 0.08459899574518204, 0.08598964661359787, 0.08739456534385681, 0.08881381154060364, 0.09024744480848312, 0.09169550985097885, 0.09315807372331619, 0.09463518112897873, 0.09612688422203064, 0.0976332351565361, 0.0991542860865593, 0.1006900817155838, 0.1022406741976738, 0.10380610823631287, 0.10538642853498459, 0.10698168724775314, 0.10859192162752151, 0.11021718382835388, 0.11185750365257263, 0.11351293325424194, 0.1151835024356842, 0.116869255900383, 0.1185702309012413, 0.12028646469116211, 0.1220179870724678, 0.12376484274864197, 0.1255270540714264, 0.12730465829372406, 0.12909768521785736, 0.13090617954730988, 0.1327301412820816, 0.13456960022449493, 0.13642460107803345, 0.13829515874385834, 0.140181303024292, 0.1420830488204956, 0.14400039613246918, 0.14593340456485748, 0.14788205921649933, 0.1498463898897171, 0.151826411485672, 0.1538221389055252, 0.15583357214927673, 0.15786074101924896, 0.1599036306142807, 0.16196227073669434, 0.16403664648532867, 0.1661267876625061, 0.16823266446590424, 0.17035430669784546, 0.17249169945716858, 0.1746448576450348, 0.1768137514591217, 0.17899839580059052, 0.18119877576828003, 0.18341489136219025, 0.18564672768115997, 0.18789426982402802, 0.19015750288963318, 0.19243642687797546, 0.19473102688789368, 0.19704125821590424, 0.19936713576316833, 0.2017085999250412, 0.20406566560268402, 0.20643828809261322, 0.2088264375925064, 0.2112300992012024, 0.21364924311637878, 0.216083824634552, 0.21853382885456085, 0.22099919617176056, 0.22347991168498993, 0.2259759157896042, 0.22848719358444214, 0.2310137003660202, 0.2335553765296936, 0.23611217737197876, 0.2386840581893921, 0.24127097427845, 0.24387288093566895, 0.2464897185564041, 0.24912142753601074, 0.25176796317100525, 0.25442925095558167, 0.2571052610874176, 0.2597958743572235, 0.2625010907649994, 0.2652208209037781, 0.2679549753665924, 0.2707034945487976, 0.2734663486480713, 0.2762434184551239, 0.27903464436531067, 0.28183993697166443, 0.2846592366695404, 0.28749245405197144, 0.29033952951431274, 0.2932003438472748, 0.2960748076438904, 0.29896289110183716, 0.3018644452095032, 0.30477938055992126, 0.30770763754844666, 0.3106490969657898, 0.3136036992073059, 0.31657129526138306, 0.3195517957210541, 0.3225451111793518, 0.3255511522293091, 0.32856976985931396, 0.3316009044647217, 0.3346444070339203, 0.3377001881599426, 0.34076812863349915, 0.3438480794429779, 0.34693998098373413, 0.35004371404647827, 0.353159099817276, 0.35628604888916016, 0.3594244420528412, 0.36257416009902954, 0.3657350242137909, 0.36890697479248047, 0.37208983302116394, 0.37528350949287415, 0.37848779559135437, 0.38170263171195984, 0.3849278390407562, 0.3881632685661316, 0.3914088308811188, 0.39466431736946106, 0.3979296088218689, 0.40120455622673035, 0.40448904037475586, 0.4077828526496887, 0.41108590364456177, 0.4143979847431183, 0.4177189767360687, 0.42104870080947876, 0.42438700795173645, 0.42773371934890747, 0.43108871579170227, 0.4344518184661865, 0.4378228187561035, 0.4412015974521637, 0.44458797574043274, 0.4479817748069763, 0.4513828158378601, 0.45479094982147217, 0.4582059979438782, 0.4616277515888214, 0.46505606174468994, 0.46849074959754944, 0.4719316363334656, 0.47537854313850403, 0.4788312613964081, 0.4822896122932434, 0.48575344681739807, 0.48922252655029297, 0.4926966726779938, 0.49617573618888855, 0.4996594786643982, 0.5031477212905884, 0.5066403150558472, 0.5101369619369507, 0.5136376023292542, 0.5171418786048889, 0.5206497311592102, 0.5241608619689941, 0.5276751518249512, 0.5311923623085022, 0.5347122550010681, 0.5382346510887146, 0.5417593717575073, 0.5452861785888672, 0.5488148331642151, 0.5523452162742615, 0.5558770298957825, 0.5594100952148438, 0.5629441738128662, 0.5664791464805603, 0.5700146555900574, 0.5735505819320679, 0.5770866870880127, 0.5806227922439575, 0.5841585993766785, 0.5876939296722412, 0.5912286043167114, 0.5947623252868652, 0.5982949137687683, 0.6018261313438416, 0.6053557991981506, 0.6088836193084717, 0.6124094128608704, 0.6159329414367676, 0.619454026222229, 0.6229723691940308, 0.6264877319335938, 0.6299999952316284, 0.6335088610649109, 0.6370140910148621, 0.6405154466629028, 0.6440126895904541, 0.6475057005882263, 0.6509941220283508, 0.6544777750968933, 0.6579563617706299, 0.661429762840271, 0.6648976802825928, 0.6683599352836609, 0.6718161702156067, 0.6752663254737854, 0.6787099838256836, 0.6821470260620117, 0.6855772137641907, 0.6890003085136414, 0.6924160122871399, 0.695824146270752, 0.6992245316505432, 0.702616810798645, 0.706000804901123, 0.7093762755393982, 0.7127429842948914, 0.7161007523536682, 0.7194492220878601, 0.7227882742881775, 0.7261176109313965, 0.7294370532035828, 0.7327463030815125, 0.7360451817512512, 0.7393333911895752, 0.74261075258255, 0.7458770275115967, 0.7491319179534912, 0.7523753046989441, 0.7556068301200867, 0.7588263750076294, 0.7620335817337036, 0.7652283310890198, 0.7684103846549988, 0.7715794444084167, 0.7747352719306946, 0.777877688407898, 0.7810065150260925, 0.7841213941574097, 0.7872222065925598, 0.7903086543083191, 0.7933804988861084, 0.7964376211166382, 0.7994796633720398, 0.8025065064430237, 0.805517852306366, 0.8085135221481323, 0.8114932775497437, 0.8144568800926208, 0.8174041509628296, 0.820334792137146, 0.8232486844062805, 0.8261455297470093, 0.8290250897407532, 0.8318872451782227, 0.8347317576408386, 0.8375583291053772, 0.8403668403625488, 0.8431569933891296, 0.8459286093711853, 0.8486815690994263, 0.8514155149459839, 0.8541303277015686, 0.8568257689476013, 0.8595016002655029, 0.8621577024459839, 0.8647938370704651, 0.8674097657203674, 0.8700053095817566, 0.8725802898406982, 0.8751344680786133, 0.8776676654815674, 0.8801796436309814, 0.8826703429222107, 0.8851394057273865, 0.8875867128372192, 0.8900121450424194, 0.8924153447151184, 0.8947963118553162, 0.897154688835144, 0.8994904160499573, 0.9018032550811768, 0.9040930867195129, 0.9063596129417419, 0.9086027145385742, 0.9108222723007202, 0.9130180478096008, 0.9151898622512817, 0.9173375964164734, 0.9194610714912415, 0.9215600490570068, 0.92363440990448, 0.9256840348243713, 0.9277086853981018, 0.9297082424163818, 0.9316825270652771, 0.933631420135498, 0.9355546832084656, 0.9374522566795349, 0.9393239617347717, 0.9411696791648865, 0.9429891705513, 0.9447823166847229, 0.9465490579605103, 0.948289155960083, 0.9500025510787964, 0.9516890048980713, 0.9533485174179077, 0.9549808502197266, 0.9565858840942383, 0.9581634998321533, 0.9597136378288269, 0.9612360596656799, 0.9627307057380676, 0.9641974568367004, 0.9656361937522888, 0.9670467972755432, 0.9684290885925293, 0.9697830677032471, 0.9711085557937622, 0.9724054932594299, 0.9736737012863159, 0.9749131798744202, 0.9761237502098083, 0.9773052930831909, 0.9784577488899231, 0.9795810580253601, 0.9806751012802124, 0.9817398190498352, 0.9827750325202942, 0.9837807416915894, 0.9847568869590759, 0.9857032895088196, 0.9866199493408203, 0.9875067472457886, 0.9883636236190796, 0.9891905188560486, 0.9899874329566956, 0.9907541871070862, 0.9914907217025757, 0.9921970963478088, 0.9928731322288513, 0.9935188293457031, 0.9941340684890747, 0.9947189092636108, 0.9952732920646667, 0.9957970380783081, 0.9962902665138245, 0.9967527985572815, 0.9971847534179688, 0.9975859522819519, 0.997956395149231, 0.9982960820198059, 0.9986050128936768, 0.998883068561554, 0.999130368232727, 0.9993467330932617, 0.9995322227478027, 0.9996868371963501, 0.9998105764389038, 0.9999033212661743, 0.9999651908874512, 0.9999961256980896, 0.9999961256980896, 0.9999651908874512, 0.9999033212661743, 0.9998105764389038, 0.9996868371963501, 0.9995322227478027, 0.9993467330932617, 0.999130368232727, 0.998883068561554, 0.9986050128936768, 0.9982960820198059, 0.997956395149231, 0.9975859522819519, 0.9971847534179688, 0.9967527985572815, 0.9962902665138245, 0.9957970380783081, 0.9952732920646667, 0.9947189092636108, 0.9941340684890747, 0.9935188293457031, 0.9928731322288513, 0.9921970963478088, 0.9914907217025757, 0.9907541871070862, 0.9899874329566956, 0.9891905188560486, 0.9883636236190796, 0.9875067472457886, 0.9866199493408203, 0.9857032895088196, 0.9847568869590759, 0.9837807416915894, 0.9827750325202942, 0.9817398190498352, 0.9806751012802124, 0.9795810580253601, 0.9784577488899231, 0.9773052930831909, 0.9761237502098083, 0.9749131798744202, 0.9736737012863159, 0.9724054932594299, 0.9711085557937622, 0.9697830677032471, 0.9684290885925293, 0.9670467972755432, 0.9656361937522888, 0.9641974568367004, 0.9627307057380676, 0.9612360596656799, 0.9597136378288269, 0.9581634998321533, 0.9565858840942383, 0.9549808502197266, 0.9533485174179077, 0.9516890048980713, 0.9500025510787964, 0.948289155960083, 0.9465490579605103, 0.9447823166847229, 0.9429891705513, 0.9411696791648865, 0.9393239617347717, 0.9374522566795349, 0.9355546832084656, 0.933631420135498, 0.9316825270652771, 0.9297082424163818, 0.9277086853981018, 0.9256840348243713, 0.92363440990448, 0.9215600490570068, 0.9194610714912415, 0.9173375964164734, 0.9151898622512817, 0.9130180478096008, 0.9108222723007202, 0.9086027145385742, 0.9063596129417419, 0.9040930867195129, 0.9018032550811768, 0.8994904160499573, 0.897154688835144, 0.8947963118553162, 0.8924153447151184, 0.8900121450424194, 0.8875867128372192, 0.8851394057273865, 0.8826703429222107, 0.8801796436309814, 0.8776676654815674, 0.8751344680786133, 0.8725802898406982, 0.8700053095817566, 0.8674097657203674, 0.8647938370704651, 0.8621577024459839, 0.8595016002655029, 0.8568257689476013, 0.8541303277015686, 0.8514155149459839, 0.8486815690994263, 0.8459286093711853, 0.8431569933891296, 0.8403668403625488, 0.8375583291053772, 0.8347317576408386, 0.8318872451782227, 0.8290250897407532, 0.8261455297470093, 0.8232486844062805, 0.820334792137146, 0.8174041509628296, 0.8144568800926208, 0.8114932775497437, 0.8085135221481323, 0.805517852306366, 0.8025065064430237, 0.7994796633720398, 0.7964376211166382, 0.7933804988861084, 0.7903086543083191, 0.7872222065925598, 0.7841213941574097, 0.7810065150260925, 0.777877688407898, 0.7747352719306946, 0.7715794444084167, 0.7684103846549988, 0.7652283310890198, 0.7620335817337036, 0.7588263750076294, 0.7556068301200867, 0.7523753046989441, 0.7491319179534912, 0.7458770275115967, 0.74261075258255, 0.7393333911895752, 0.7360451817512512, 0.7327463030815125, 0.7294370532035828, 0.7261176109313965, 0.7227882742881775, 0.7194492220878601, 0.7161007523536682, 0.7127429842948914, 0.7093762755393982, 0.706000804901123, 0.702616810798645, 0.6992245316505432, 0.695824146270752, 0.6924160122871399, 0.6890003085136414, 0.6855772137641907, 0.6821470260620117, 0.6787099838256836, 0.6752663254737854, 0.6718161702156067, 0.6683599352836609, 0.6648976802825928, 0.661429762840271, 0.6579563617706299, 0.6544777750968933, 0.6509941220283508, 0.6475057005882263, 0.6440126895904541, 0.6405154466629028, 0.6370140910148621, 0.6335088610649109, 0.6299999952316284, 0.6264877319335938, 0.6229723691940308, 0.619454026222229, 0.6159329414367676, 0.6124094128608704, 0.6088836193084717, 0.6053557991981506, 0.6018261313438416, 0.5982949137687683, 0.5947623252868652, 0.5912286043167114, 0.5876939296722412, 0.5841585993766785, 0.5806227922439575, 0.5770866870880127, 0.5735505819320679, 0.5700146555900574, 0.5664791464805603, 0.5629441738128662, 0.5594100952148438, 0.5558770298957825, 0.5523452162742615, 0.5488148331642151, 0.5452861785888672, 0.5417593717575073, 0.5382346510887146, 0.5347122550010681, 0.5311923623085022, 0.5276751518249512, 0.5241608619689941, 0.5206497311592102, 0.5171418786048889, 0.5136376023292542, 0.5101369619369507, 0.5066403150558472, 0.5031477212905884, 0.4996594786643982, 0.49617573618888855, 0.4926966726779938, 0.48922252655029297, 0.48575344681739807, 0.4822896122932434, 0.4788312613964081, 0.47537854313850403, 0.4719316363334656, 0.46849074959754944, 0.46505606174468994, 0.4616277515888214, 0.4582059979438782, 0.45479094982147217, 0.4513828158378601, 0.4479817748069763, 0.44458797574043274, 0.4412015974521637, 0.4378228187561035, 0.4344518184661865, 0.43108871579170227, 0.42773371934890747, 0.42438700795173645, 0.42104870080947876, 0.4177189767360687, 0.4143979847431183, 0.41108590364456177, 0.4077828526496887, 0.40448904037475586, 0.40120455622673035, 0.3979296088218689, 0.39466431736946106, 0.3914088308811188, 0.3881632685661316, 0.3849278390407562, 0.38170263171195984, 0.37848779559135437, 0.37528350949287415, 0.37208983302116394, 0.36890697479248047, 0.3657350242137909, 0.36257416009902954, 0.3594244420528412, 0.35628604888916016, 0.353159099817276, 0.35004371404647827, 0.34693998098373413, 0.3438480794429779, 0.34076812863349915, 0.3377001881599426, 0.3346444070339203, 0.3316009044647217, 0.32856976985931396, 0.3255511522293091, 0.3225451111793518, 0.3195517957210541, 0.31657129526138306, 0.3136036992073059, 0.3106490969657898, 0.30770763754844666, 0.30477938055992126, 0.3018644452095032, 0.29896289110183716, 0.2960748076438904, 0.2932003438472748, 0.29033952951431274, 0.28749245405197144, 0.2846592366695404, 0.28183993697166443, 0.27903464436531067, 0.2762434184551239, 0.2734663486480713, 0.2707034945487976, 0.2679549753665924, 0.2652208209037781, 0.2625010907649994, 0.2597958743572235, 0.2571052610874176, 0.25442925095558167, 0.25176796317100525, 0.24912142753601074, 0.2464897185564041, 0.24387288093566895, 0.24127097427845, 0.2386840581893921, 0.23611217737197876, 0.2335553765296936, 0.2310137003660202, 0.22848719358444214, 0.2259759157896042, 0.22347991168498993, 0.22099919617176056, 0.21853382885456085, 0.216083824634552, 0.21364924311637878, 0.2112300992012024, 0.2088264375925064, 0.20643828809261322, 0.20406566560268402, 0.2017085999250412, 0.19936713576316833, 0.19704125821590424, 0.19473102688789368, 0.19243642687797546, 0.19015750288963318, 0.18789426982402802, 0.18564672768115997, 0.18341489136219025, 0.18119877576828003, 0.17899839580059052, 0.1768137514591217, 0.1746448576450348, 0.17249169945716858, 0.17035430669784546, 0.16823266446590424, 0.1661267876625061, 0.16403664648532867, 0.16196227073669434, 0.1599036306142807, 0.15786074101924896, 0.15583357214927673, 0.1538221389055252, 0.151826411485672, 0.1498463898897171, 0.14788205921649933, 0.14593340456485748, 0.14400039613246918, 0.1420830488204956, 0.140181303024292, 0.13829515874385834, 0.13642460107803345, 0.13456960022449493, 0.1327301412820816, 0.13090617954730988, 0.12909768521785736, 0.12730465829372406, 0.1255270540714264, 0.12376484274864197, 0.1220179870724678, 0.12028646469116211, 0.1185702309012413, 0.116869255900383, 0.1151835024356842, 0.11351293325424194, 0.11185750365257263, 0.11021718382835388, 0.10859192162752151, 0.10698168724775314, 0.10538642853498459, 0.10380610823631287, 0.1022406741976738, 0.1006900817155838, 0.0991542860865593, 0.0976332351565361, 0.09612688422203064, 0.09463518112897873, 0.09315807372331619, 0.09169550985097885, 0.09024744480848312, 0.08881381154060364, 0.08739456534385681, 0.08598964661359787, 0.08459899574518204, 0.08322256803512573, 0.08186028897762299, 0.08051211386919022, 0.07917798310518265, 0.07785782963037491, 0.07655159384012222, 0.07525921612977982, 0.07398062944412231, 0.07271578162908554, 0.07146460562944412, 0.07022703438997269, 0.06900300830602646, 0.06779245287179947, 0.06659531593322754, 0.0654115155339241, 0.06424099951982498, 0.0630836933851242, 0.061939533799886703, 0.0608084499835968, 0.05969037488102913, 0.058585237711668015, 0.05749296769499779, 0.056413501501083374, 0.0553467683494091, 0.05429269000887871, 0.053251203149557114, 0.05222223699092865, 0.05120571702718735, 0.050201576203107834, 0.04920973628759384, 0.0482301339507103, 0.04726269096136093, 0.04630733281373978, 0.04536399617791176, 0.04443260282278061, 0.04351307824254036, 0.04260535538196564, 0.041709356009960175, 0.0408250093460083, 0.039952244609594345, 0.03909098729491234, 0.03824116289615631, 0.03740270063281059, 0.036575525999069214, 0.035759568214416504, 0.034954752773046494, 0.034161005169153214, 0.03337825834751129, 0.03260643407702446, 0.031845465302467346, 0.031095275655388832, 0.030355794355273247, 0.02962694875895977, 0.02890866994857788, 0.02820088528096676, 0.027503522112965584, 0.026816511526703835, 0.02613978274166584, 0.02547326497733593, 0.024816887453198433, 0.024170581251382828, 0.023534279316663742, 0.022907909005880356, 0.022291403263807297, 0.021684695035219193, 0.02108771540224552, 0.02050039730966091, 0.01992267370223999, 0.019354479387402534, 0.018795747309923172, 0.01824641227722168, 0.017706410959362984, 0.01717567630112171, 0.01665414683520794, 0.016141757369041443, 0.015638448297977448, 0.015144153498113155, 0.014658814296126366, 0.01418236829340458, 0.013714756816625595, 0.013255918398499489, 0.012805796228349209, 0.012364329770207405, 0.0119314631447196, 0.011507139541208744, 0.011091301217675209, 0.010683894157409668, 0.010284862481057644, 0.009894154034554958, 0.009511712938547134, 0.009137489832937717, 0.00877143070101738, 0.008413486182689667, 0.008063605055212975, 0.007721738424152136, 0.007387838792055845, 0.007061857730150223, 0.006743749137967825, 0.006433466449379921, 0.006130965426564217, 0.005836201831698418, 0.005549132823944092, 0.005269715096801519, 0.004997908603399992, 0.0047336723655462265, 0.004476966802030802, 0.004227753262966871, 0.003985994961112738, 0.0037516544107347727, 0.003524696221575141, 0.0033050859346985817, 0.003092789789661765, 0.0028877751901745796, 0.0026900102384388447, 0.002499464200809598, 0.0023161075077950954, 0.0021399117540568113, 0.001970848999917507, 0.0018088927026838064, 0.0016540174838155508, 0.001506198663264513, 0.0013654128415510058, 0.0012316375505179167, 0.0011048517189919949, 0.000985034741461277, 0.0008721675840206444, 0.000766232144087553, 0.0006672112504020333, 0.0005750890704803169, 0.000489850586745888, 0.000411482120398432, 0.00033997089485637844, 0.00027530535589903593, 0.00021747495338786393, 0.00016647028678562492, 0.00012228307605255395, 8.490608888678253e-05, 5.433323894976638e-05, 3.055953493458219e-05, 1.358109057036927e-05, 3.3951337172766216e-06, -1.3877787807814457e-17 ] ================================================ FILE: __tests__/data/blackman128.json ================================================ [ -1.3877787807814457e-17, 0.00022048462415114045, 0.0008842693641781807, 0.0019983130041509867, 0.003574101720005274, 0.005627480801194906, 0.008178424090147018, 0.011250740848481655, 0.014871722087264061, 0.019071735441684723, 0.023883763700723648, 0.029342904686927795, 0.035485826432704926, 0.04235018044710159, 0.04997401311993599, 0.058395106345415115, 0.06765036284923553, 0.07777513563632965, 0.08880257606506348, 0.10076300799846649, 0.11368323862552643, 0.1275860071182251, 0.14248935878276825, 0.1584061086177826, 0.175343319773674, 0.19330184161663055, 0.21227586269378662, 0.23225261270999908, 0.253212034702301, 0.27512651681900024, 0.2979607582092285, 0.321671724319458, 0.3462085425853729, 0.37151262164115906, 0.39751771092414856, 0.42415013909339905, 0.45132920145988464, 0.4789673089981079, 0.5069705247879028, 0.5352391004562378, 0.5636678338050842, 0.5921469330787659, 0.6205624341964722, 0.6487972140312195, 0.6767313480377197, 0.7042432427406311, 0.7312102317810059, 0.7575095891952515, 0.7830193042755127, 0.8076188564300537, 0.8311902284622192, 0.8536187410354614, 0.8747937679290771, 0.8946096301078796, 0.9129664301872253, 0.929770827293396, 0.9449363946914673, 0.9583848714828491, 0.9700462818145752, 0.9798595309257507, 0.987773060798645, 0.9937452077865601, 0.9977442622184753, 0.9997491240501404, 0.9997491240501404, 0.9977442622184753, 0.9937452077865601, 0.987773060798645, 0.9798595309257507, 0.9700462818145752, 0.9583848714828491, 0.9449363946914673, 0.929770827293396, 0.9129664301872253, 0.8946096301078796, 0.8747937679290771, 0.8536187410354614, 0.8311902284622192, 0.8076188564300537, 0.7830193042755127, 0.7575095891952515, 0.7312102317810059, 0.7042432427406311, 0.6767313480377197, 0.6487972140312195, 0.6205624341964722, 0.5921469330787659, 0.5636678338050842, 0.5352391004562378, 0.5069705247879028, 0.4789673089981079, 0.45132920145988464, 0.42415013909339905, 0.39751771092414856, 0.37151262164115906, 0.3462085425853729, 0.321671724319458, 0.2979607582092285, 0.27512651681900024, 0.253212034702301, 0.23225261270999908, 0.21227586269378662, 0.19330184161663055, 0.175343319773674, 0.1584061086177826, 0.14248935878276825, 0.1275860071182251, 0.11368323862552643, 0.10076300799846649, 0.08880257606506348, 0.07777513563632965, 0.06765036284923553, 0.058395106345415115, 0.04997401311993599, 0.04235018044710159, 0.035485826432704926, 0.029342904686927795, 0.023883763700723648, 0.019071735441684723, 0.014871722087264061, 0.011250740848481655, 0.008178424090147018, 0.005627480801194906, 0.003574101720005274, 0.0019983130041509867, 0.0008842693641781807, 0.00022048462415114045, -1.3877787807814457e-17 ] ================================================ FILE: __tests__/data/blackman2048.json ================================================ [ -1.3877787807814457e-17, 8.479456710119848e-07, 3.391817472220282e-06, 7.631719199707732e-06, 1.3567823771154508e-05, 2.1200372430030257e-05, 3.052967804251239e-05, 4.1556122596375644e-05, 5.42801535630133e-05, 6.870229117339477e-05, 8.4823121142108e-05, 0.00010264330921927467, 0.0001221635757246986, 0.00014338470646180212, 0.00016630758182145655, 0.00019093311857432127, 0.00021726233535446227, 0.000245296279899776, 0.00027503614546731114, 0.00030648306710645556, 0.0003396383544895798, 0.0003745033754967153, 0.000411079527111724, 0.00044936826452612877, 0.0004893711884506047, 0.000531089841388166, 0.0005745260277763009, 0.0006196813774295151, 0.0006665578112006187, 0.0007151571335271001, 0.0007654813816770911, 0.0008175325347110629, 0.0008713127463124692, 0.0009268240537494421, 0.000984068843536079, 0.0010430492693558335, 0.0011037677759304643, 0.0011662266915664077, 0.0012304286938160658, 0.001296376227401197, 0.0013640718534588814, 0.0014335184823721647, 0.0015047186752781272, 0.0015776753425598145, 0.0016523912781849504, 0.0017288696253672242, 0.0018071132944896817, 0.0018871253123506904, 0.001968909054994583, 0.0020524675492197275, 0.002137803938239813, 0.0022249219473451376, 0.002313824836164713, 0.00240451586432755, 0.002496998989954591, 0.0025912774726748466, 0.002687355037778616, 0.002785235643386841, 0.002884922781959176, 0.0029864206444472075, 0.00308973272331059, 0.0031948634423315525, 0.003301816526800394, 0.0034105961676687002, 0.0035212067887187004, 0.003633652115240693, 0.003747937036678195, 0.0038640655111521482, 0.003982041962444782, 0.00410187104716897, 0.004223557189106941, 0.004347105044871569, 0.0044725192710757256, 0.004599804524332285, 0.00472896546125412, 0.004860007204115391, 0.004992934409528971, 0.00512775219976902, 0.005264465697109699, 0.005403079558163881, 0.005543599370867014, 0.0056860302574932575, 0.005830376874655485, 0.0059766448102891445, 0.006124840117990971, 0.0062749674543738365, 0.00642703240737319, 0.0065810405649244785, 0.00673699751496315, 0.006894908845424652, 0.0070547801442444324, 0.007216617465019226, 0.007380426395684481, 0.007546212989836931, 0.0077139828354120255, 0.007883742451667786, 0.008055496960878372, 0.008229252882301807, 0.008405016735196114, 0.008582794107496738, 0.00876259058713913, 0.008944414556026459, 0.009128270670771599, 0.009314165450632572, 0.009502105414867401, 0.009692097082734108, 0.00988414790481329, 0.01007826253771782, 0.010274449363350868, 0.010472713969647884, 0.01067306287586689, 0.010875504463911057, 0.011080043390393257, 0.011286688037216663, 0.011495444923639297, 0.011706321500241756, 0.011919323354959488, 0.012134457938373089, 0.01235173363238573, 0.012571156024932861, 0.012792733497917652, 0.01301647163927555, 0.013242379762232304, 0.013470463454723358, 0.013700730167329311, 0.01393318921327591, 0.014167845249176025, 0.014404707588255405, 0.014643783681094646, 0.01488508004695177, 0.01512860506772995, 0.015374365262687206, 0.015622369945049286, 0.01587262563407421, 0.016125140711665154, 0.01637992262840271, 0.016636978834867477, 0.016896318644285202, 0.01715794764459133, 0.017421875149011612, 0.01768810860812664, 0.017956657335162163, 0.018227526918053627, 0.01850072853267193, 0.018776265904307365, 0.019054152071475983, 0.01933439075946808, 0.019616995006799698, 0.01990196853876114, 0.020189320668578148, 0.02047906070947647, 0.020771196112036705, 0.021065736189484596, 0.02136269025504589, 0.021662062034010887, 0.02196386456489563, 0.022268105298280716, 0.022574791684746742, 0.022883933037519455, 0.02319553680717945, 0.023509612306952477, 0.023826168850064278, 0.02414521388709545, 0.024466756731271744, 0.024790804833173752, 0.02511736750602722, 0.0254464540630579, 0.025778071954846382, 0.026112230494618416, 0.026448940858244896, 0.02678820677101612, 0.027130041271448135, 0.027474451810121536, 0.02782144583761692, 0.028171034529805183, 0.028523225337266922, 0.028878027573227882, 0.02923545055091381, 0.029595499858260155, 0.029958190396428108, 0.03032352589070797, 0.030691517516970634, 0.03106217458844185, 0.03143550455570221, 0.03181151673197746, 0.032190222293138504, 0.03257162868976593, 0.03295574337244034, 0.03334257751703262, 0.03373213857412338, 0.03412443771958351, 0.03451947867870331, 0.034917280077934265, 0.03531784191727638, 0.035721179097890854, 0.03612729534506798, 0.03653620555996895, 0.03694791719317436, 0.03736243396997452, 0.03777977451682091, 0.03819993883371353, 0.03862294182181358, 0.03904878720641136, 0.03947748988866806, 0.039909057319164276, 0.040343496948480606, 0.040780819952487946, 0.04122103005647659, 0.04166414588689804, 0.04211016744375229, 0.04255910962820053, 0.043010979890823364, 0.043465785682201385, 0.04392353445291519, 0.04438424110412598, 0.04484791308641434, 0.04531455785036087, 0.04578418284654617, 0.04625679925084114, 0.04673241823911667, 0.047211043536663055, 0.047692690044641495, 0.048177361488342285, 0.04866506904363632, 0.0491558238863945, 0.04964963346719742, 0.05014650523662567, 0.05064644664525986, 0.05114947259426117, 0.05165558680891991, 0.052164800465106964, 0.05267712101340294, 0.053192559629678726, 0.05371112376451492, 0.054232824593782425, 0.05475766584277153, 0.05528566241264343, 0.05581681802868843, 0.05635114014148712, 0.0568886436522007, 0.05742933601140976, 0.0579732209444046, 0.05852031335234642, 0.05907062068581581, 0.05962414667010307, 0.0601809024810791, 0.06074089929461479, 0.06130414456129074, 0.061870645731687546, 0.0624404102563858, 0.06301344931125641, 0.06358977407217026, 0.06416938453912735, 0.06475229561328888, 0.06533850729465485, 0.06592804193496704, 0.06652089953422546, 0.06711708754301071, 0.06771661341190338, 0.06831949204206467, 0.06892572343349457, 0.06953532248735428, 0.0701482966542244, 0.07076465338468552, 0.07138439267873764, 0.07200752943754196, 0.07263407856225967, 0.07326403260231018, 0.07389741390943527, 0.07453422248363495, 0.07517446577548981, 0.07581815868616104, 0.07646530121564865, 0.07711590081453323, 0.07776997238397598, 0.0784275159239769, 0.07908854633569717, 0.07975306361913681, 0.080421082675457, 0.08109260350465775, 0.08176764100790024, 0.08244619518518448, 0.08312828093767166, 0.08381389826536179, 0.08450305461883545, 0.08519576489925385, 0.08589203655719757, 0.08659186214208603, 0.08729526400566101, 0.08800224214792252, 0.08871280401945114, 0.08942695707082748, 0.09014471620321274, 0.0908660739660263, 0.09159103780984879, 0.09231963008642197, 0.09305184334516525, 0.09378768503665924, 0.09452717006206512, 0.0952702984213829, 0.09601707756519318, 0.09676751494407654, 0.09752161800861359, 0.09827938675880432, 0.09904083609580994, 0.09980596601963043, 0.10057477653026581, 0.10134728997945786, 0.10212350636720657, 0.10290341824293137, 0.10368705540895462, 0.10447440296411514, 0.10526546835899353, 0.10606027394533157, 0.10685880482196808, 0.10766108334064484, 0.10846710205078125, 0.10927687585353851, 0.11009040474891663, 0.11090768873691559, 0.11172875016927719, 0.11255357414484024, 0.11338218301534653, 0.11421456187963486, 0.11505074054002762, 0.11589070409536362, 0.11673445999622345, 0.11758202314376831, 0.1184333935379982, 0.11928856372833252, 0.12014755606651306, 0.12101037055253983, 0.12187699973583221, 0.12274745851755142, 0.12362175434827805, 0.12449987977743149, 0.12538185715675354, 0.12626765668392181, 0.1271573156118393, 0.12805083394050598, 0.12894819676876068, 0.1298494189977646, 0.1307545006275177, 0.1316634565591812, 0.13257628679275513, 0.13349297642707825, 0.13441354036331177, 0.13533799350261688, 0.1362663209438324, 0.1371985375881195, 0.1381346434354782, 0.1390746384859085, 0.1400185227394104, 0.14096631109714508, 0.14191798865795135, 0.14287357032299042, 0.14383305609226227, 0.1447964459657669, 0.14576375484466553, 0.14673495292663574, 0.14771008491516113, 0.1486891210079193, 0.14967207610607147, 0.15065895020961761, 0.15164974331855774, 0.15264445543289185, 0.15364308655261993, 0.1546456515789032, 0.15565213561058044, 0.15666253864765167, 0.15767689049243927, 0.15869516134262085, 0.1597173511981964, 0.16074348986148834, 0.16177354753017426, 0.16280755400657654, 0.1638454794883728, 0.16488733887672424, 0.16593313217163086, 0.16698287427425385, 0.1680365353822708, 0.16909414529800415, 0.17015567421913147, 0.17122115194797516, 0.17229054868221283, 0.17336389422416687, 0.1744411736726761, 0.17552238702774048, 0.17660751938819885, 0.1776966005563736, 0.17878960072994232, 0.17988653481006622, 0.1809874027967453, 0.18209220468997955, 0.1832009255886078, 0.1843135803937912, 0.1854301542043686, 0.18655066192150116, 0.1876750886440277, 0.18880343437194824, 0.18993568420410156, 0.19107186794281006, 0.19221197068691254, 0.1933559775352478, 0.19450388848781586, 0.1956557184457779, 0.19681145250797272, 0.19797109067440033, 0.19913463294506073, 0.20030207931995392, 0.2014734148979187, 0.20264863967895508, 0.20382775366306305, 0.20501075685024261, 0.20619764924049377, 0.20738841593265533, 0.2085830718278885, 0.20978158712387085, 0.2109839767217636, 0.21219024062156677, 0.21340034902095795, 0.21461433172225952, 0.2158321589231491, 0.2170538455247879, 0.2182793766260147, 0.21950873732566833, 0.22074194252490997, 0.22197897732257843, 0.2232198417186737, 0.2244645357131958, 0.22571304440498352, 0.22696536779403687, 0.22822149097919464, 0.22948141396045685, 0.23074515163898468, 0.23201265931129456, 0.23328396677970886, 0.2345590442419052, 0.2358379065990448, 0.23712053894996643, 0.2384069263935089, 0.23969706892967224, 0.24099096655845642, 0.24228860437870026, 0.24358998239040375, 0.2448950856924057, 0.24620391428470612, 0.247516468167305, 0.24883271753787994, 0.25015267729759216, 0.25147634744644165, 0.2528036832809448, 0.2541347146034241, 0.255469411611557, 0.25680777430534363, 0.25814980268478394, 0.25949546694755554, 0.26084479689598083, 0.26219773292541504, 0.26355430483818054, 0.26491451263427734, 0.26627829670906067, 0.2676457166671753, 0.26901671290397644, 0.2703912854194641, 0.2717694342136383, 0.273151159286499, 0.2745364308357239, 0.27592524886131287, 0.2773175835609436, 0.27871349453926086, 0.2801128923892975, 0.28151580691337585, 0.2829222083091736, 0.28433212637901306, 0.2857455015182495, 0.28716233372688293, 0.2885826528072357, 0.2900063991546631, 0.2914336025714874, 0.29286420345306396, 0.2942982614040375, 0.2957356870174408, 0.2971765398979187, 0.2986207604408264, 0.30006834864616394, 0.3015192747116089, 0.30297359824180603, 0.3044312298297882, 0.3058921992778778, 0.30735647678375244, 0.3088240623474121, 0.3102949261665344, 0.3117690682411194, 0.313246488571167, 0.31472715735435486, 0.316211074590683, 0.317698210477829, 0.31918856501579285, 0.3206821084022522, 0.3221788704395294, 0.32367879152297974, 0.32518187165260315, 0.32668811082839966, 0.3281974792480469, 0.3297099769115448, 0.33122560381889343, 0.332744300365448, 0.3342660963535309, 0.3357909321784973, 0.3373188376426697, 0.338849812746048, 0.34038376808166504, 0.34192076325416565, 0.34346073865890503, 0.34500372409820557, 0.3465496301651001, 0.3480985164642334, 0.3496503531932831, 0.35120511054992676, 0.35276275873184204, 0.35432329773902893, 0.3558867275714874, 0.35745298862457275, 0.3590221107006073, 0.3605940639972687, 0.3621688485145569, 0.36374640464782715, 0.36532676219940186, 0.36690986156463623, 0.36849573254585266, 0.37008431553840637, 0.37167564034461975, 0.373269647359848, 0.3748663365840912, 0.37646567821502686, 0.3780677020549774, 0.3796723186969757, 0.3812795877456665, 0.38288941979408264, 0.3845018446445465, 0.3861168324947357, 0.3877343535423279, 0.389354407787323, 0.39097699522972107, 0.39260202646255493, 0.39422956109046936, 0.3958595395088196, 0.3974919617176056, 0.399126797914505, 0.4007640480995178, 0.40240365266799927, 0.40404564142227173, 0.40568995475769043, 0.40733659267425537, 0.40898555517196655, 0.4106367826461792, 0.4122902750968933, 0.4139460325241089, 0.41560399532318115, 0.4172641932964325, 0.41892656683921814, 0.4205910861492157, 0.42225778102874756, 0.42392659187316895, 0.42559751868247986, 0.4272705614566803, 0.4289456307888031, 0.43062275648117065, 0.43230193853378296, 0.43398308753967285, 0.4356662333011627, 0.43735137581825256, 0.4390384256839752, 0.4407274127006531, 0.44241830706596375, 0.44411107897758484, 0.44580569863319397, 0.4475021958351135, 0.44920048117637634, 0.4509005546569824, 0.45260241627693176, 0.454306036233902, 0.4560113847255707, 0.4577184319496155, 0.4594271779060364, 0.4611375629901886, 0.46284961700439453, 0.4645632803440094, 0.4662785530090332, 0.46799540519714355, 0.4697137773036957, 0.47143369913101196, 0.47315514087677, 0.47487807273864746, 0.4766024351119995, 0.47832825779914856, 0.48005548119544983, 0.4817841053009033, 0.48351410031318665, 0.4852454662322998, 0.48697811365127563, 0.4887120723724365, 0.4904473125934601, 0.4921838045120239, 0.49392154812812805, 0.4956604540348053, 0.49740055203437805, 0.4991418123245239, 0.5008842349052429, 0.5026277303695679, 0.5043722987174988, 0.5061179399490356, 0.5078646540641785, 0.5096123218536377, 0.5113610029220581, 0.5131106376647949, 0.5148612260818481, 0.516612708568573, 0.5183650255203247, 0.5201182961463928, 0.521872341632843, 0.5236272215843201, 0.5253828763961792, 0.5271393060684204, 0.5288965106010437, 0.5306543707847595, 0.5324129462242126, 0.5341721773147583, 0.5359320044517517, 0.5376924872398376, 0.5394535064697266, 0.5412151217460632, 0.5429772138595581, 0.544739842414856, 0.5465030074119568, 0.5482665300369263, 0.550030529499054, 0.5517949461936951, 0.5535597205162048, 0.5553247928619385, 0.5570902228355408, 0.5588559508323669, 0.560621976852417, 0.5623881816864014, 0.5641546249389648, 0.5659213066101074, 0.5676881074905396, 0.5694550275802612, 0.5712220668792725, 0.5729891657829285, 0.574756383895874, 0.5765235424041748, 0.5782907605171204, 0.5800579190254211, 0.5818250179290771, 0.5835920572280884, 0.5853589773178101, 0.5871257781982422, 0.58889240026474, 0.5906588435173035, 0.5924250483512878, 0.5941910147666931, 0.5959566831588745, 0.597722053527832, 0.5994871258735657, 0.6012517809867859, 0.6030160784721375, 0.6047799587249756, 0.6065434217453003, 0.6083064079284668, 0.6100688576698303, 0.6118308305740356, 0.6135922074317932, 0.6153530478477478, 0.6171132326126099, 0.6188728213310242, 0.6206316947937012, 0.6223899126052856, 0.624147355556488, 0.6259040832519531, 0.6276600360870361, 0.6294151544570923, 0.6311694383621216, 0.6329228281974792, 0.6346753835678101, 0.6364269852638245, 0.6381776332855225, 0.639927327632904, 0.6416759490966797, 0.6434235572814941, 0.6451701521873474, 0.6469155550003052, 0.648659884929657, 0.6504030823707581, 0.6521450877189636, 0.6538858413696289, 0.6556254029273987, 0.6573636531829834, 0.6591006517410278, 0.6608362793922424, 0.6625705361366272, 0.6643034815788269, 0.6660349369049072, 0.6677649617195129, 0.669493556022644, 0.671220600605011, 0.6729461550712585, 0.6746701002120972, 0.6763924956321716, 0.6781132221221924, 0.6798323392868042, 0.6815497875213623, 0.6832655072212219, 0.6849794983863831, 0.6866917610168457, 0.6884021759033203, 0.6901107430458069, 0.6918175220489502, 0.6935223937034607, 0.6952253580093384, 0.6969263553619385, 0.6986254453659058, 0.7003224492073059, 0.7020174860954285, 0.7037104368209839, 0.7054013013839722, 0.7070900797843933, 0.7087766528129578, 0.7104610800743103, 0.7121433019638062, 0.7138233184814453, 0.7155010104179382, 0.7171764969825745, 0.7188495993614197, 0.7205203175544739, 0.7221887111663818, 0.723854660987854, 0.7255182266235352, 0.727179229259491, 0.728837788105011, 0.7304938435554504, 0.7321473360061646, 0.7337982058525085, 0.7354464530944824, 0.7370920777320862, 0.738735020160675, 0.740375280380249, 0.7420127987861633, 0.7436475157737732, 0.7452794909477234, 0.7469086647033691, 0.7485349178314209, 0.7501583099365234, 0.7517788410186768, 0.7533963918685913, 0.7550110220909119, 0.7566226124763489, 0.7582311630249023, 0.759836733341217, 0.7614391446113586, 0.7630385160446167, 0.7646346688270569, 0.7662277221679688, 0.7678175568580627, 0.7694041132926941, 0.7709874510765076, 0.7725675106048584, 0.7741442918777466, 0.7757176756858826, 0.7772877216339111, 0.7788543701171875, 0.7804175615310669, 0.7819772958755493, 0.7835335731506348, 0.7850863337516785, 0.7866355180740356, 0.7881811857223511, 0.7897232174873352, 0.791261613368988, 0.7927963733673096, 0.7943274974822998, 0.7958548069000244, 0.7973784804344177, 0.7988982796669006, 0.8004143834114075, 0.8019266128540039, 0.8034349679946899, 0.8049394488334656, 0.8064400553703308, 0.8079367280006409, 0.809429407119751, 0.8109180927276611, 0.8124027848243713, 0.8138834238052368, 0.8153599500656128, 0.816832423210144, 0.818300724029541, 0.8197648525238037, 0.8212248682975769, 0.8226805925369263, 0.8241321444511414, 0.8255794048309326, 0.8270223140716553, 0.8284609913825989, 0.8298952579498291, 0.8313251733779907, 0.832750678062439, 0.8341717720031738, 0.8355883955955505, 0.8370004892349243, 0.8384081125259399, 0.8398112058639526, 0.8412097692489624, 0.8426036834716797, 0.8439930081367493, 0.8453776836395264, 0.846757709980011, 0.8481330275535583, 0.8495035767555237, 0.8508694171905518, 0.8522304892539978, 0.8535867929458618, 0.8549382090568542, 0.8562847971916199, 0.8576264977455139, 0.8589633107185364, 0.8602951765060425, 0.861622154712677, 0.8629440665245056, 0.8642610311508179, 0.8655729293823242, 0.8668797612190247, 0.8681815266609192, 0.8694782257080078, 0.870769739151001, 0.8720561265945435, 0.8733373284339905, 0.874613344669342, 0.8758841156959534, 0.8771495819091797, 0.8784098625183105, 0.8796647787094116, 0.8809143900871277, 0.882158637046814, 0.8833975195884705, 0.8846309781074524, 0.8858590126037598, 0.8870816230773926, 0.888298749923706, 0.8895103931427002, 0.8907164931297302, 0.8919170498847961, 0.893112063407898, 0.8943014740943909, 0.8954852819442749, 0.89666348695755, 0.8978359699249268, 0.8990027904510498, 0.9001639485359192, 0.9013193249702454, 0.9024689793586731, 0.9036128520965576, 0.9047509431838989, 0.9058831930160522, 0.9070096611976624, 0.9081302285194397, 0.9092448949813843, 0.9103536605834961, 0.9114565253257751, 0.9125534296035767, 0.9136443734169006, 0.9147292971611023, 0.9158082604408264, 0.9168811440467834, 0.9179479479789734, 0.919008731842041, 0.9200634360313416, 0.9211119413375854, 0.9221543669700623, 0.9231905937194824, 0.9242206811904907, 0.9252445697784424, 0.9262621998786926, 0.9272736310958862, 0.9282787442207336, 0.9292776584625244, 0.9302701950073242, 0.9312564730644226, 0.93223637342453, 0.9332098960876465, 0.9341771006584167, 0.9351378679275513, 0.93609219789505, 0.9370400905609131, 0.9379816055297852, 0.9389165639877319, 0.939845085144043, 0.9407670497894287, 0.9416825175285339, 0.9425914287567139, 0.9434937834739685, 0.9443895220756531, 0.9452787041664124, 0.9461612105369568, 0.9470371603965759, 0.9479063749313354, 0.9487689733505249, 0.9496248364448547, 0.9504740238189697, 0.9513164758682251, 0.9521521925926208, 0.952981173992157, 0.9538033604621887, 0.9546187520027161, 0.955427348613739, 0.9562291502952576, 0.957024097442627, 0.9578121304512024, 0.9585933685302734, 0.9593676924705505, 0.9601351022720337, 0.9608955979347229, 0.9616491794586182, 0.9623957872390747, 0.9631354808807373, 0.9638681411743164, 0.9645938277244568, 0.9653125405311584, 0.9660241603851318, 0.9667288064956665, 0.9674264192581177, 0.9681168794631958, 0.9688003659248352, 0.9694766998291016, 0.9701459407806396, 0.9708080291748047, 0.9714630246162415, 0.9721108675003052, 0.9727515578269958, 0.9733850955963135, 0.9740114212036133, 0.9746305346488953, 0.9752424359321594, 0.9758471846580505, 0.9764446020126343, 0.977034866809845, 0.9776178002357483, 0.9781935214996338, 0.9787619113922119, 0.9793230295181274, 0.9798768162727356, 0.9804233312606812, 0.9809625148773193, 0.9814943075180054, 0.9820188283920288, 0.9825359582901001, 0.9830456972122192, 0.9835480451583862, 0.9840430617332458, 0.9845306277275085, 0.9850108027458191, 0.9854835867881775, 0.9859488606452942, 0.9864067435264587, 0.9868571758270264, 0.9873001575469971, 0.9877356886863708, 0.9881637096405029, 0.9885842800140381, 0.9889973402023315, 0.9894028902053833, 0.9898009300231934, 0.9901914596557617, 0.9905744791030884, 0.9909499287605286, 0.991317868232727, 0.9916782379150391, 0.9920310974121094, 0.9923763275146484, 0.9927140474319458, 0.9930441379547119, 0.9933667182922363, 0.9936816692352295, 0.9939889907836914, 0.9942887425422668, 0.994580864906311, 0.994865357875824, 0.9951422810554504, 0.9954115748405457, 0.9956731796264648, 0.9959272146224976, 0.9961735606193542, 0.9964122772216797, 0.9966433644294739, 0.996866762638092, 0.9970824718475342, 0.9972905516624451, 0.9974909424781799, 0.9976837038993835, 0.9978687763214111, 0.9980461001396179, 0.9982157945632935, 0.998377799987793, 0.9985321164131165, 0.9986786842346191, 0.9988176226615906, 0.9989488124847412, 0.9990723133087158, 0.9991881251335144, 0.9992961883544922, 0.999396562576294, 0.9994892477989197, 0.9995741844177246, 0.9996514320373535, 0.9997209310531616, 0.9997827410697937, 0.999836802482605, 0.9998831748962402, 0.9999217987060547, 0.9999526739120483, 0.999975860118866, 0.9999912977218628, 0.9999990463256836, 0.9999990463256836, 0.9999912977218628, 0.999975860118866, 0.9999526739120483, 0.9999217987060547, 0.9998831748962402, 0.999836802482605, 0.9997827410697937, 0.9997209310531616, 0.9996514320373535, 0.9995741844177246, 0.9994892477989197, 0.999396562576294, 0.9992961883544922, 0.9991881251335144, 0.9990723133087158, 0.9989488124847412, 0.9988176226615906, 0.9986786842346191, 0.9985321164131165, 0.998377799987793, 0.9982157945632935, 0.9980461001396179, 0.9978687763214111, 0.9976837038993835, 0.9974909424781799, 0.9972905516624451, 0.9970824718475342, 0.996866762638092, 0.9966433644294739, 0.9964122772216797, 0.9961735606193542, 0.9959272146224976, 0.9956731796264648, 0.9954115748405457, 0.9951422810554504, 0.994865357875824, 0.994580864906311, 0.9942887425422668, 0.9939889907836914, 0.9936816692352295, 0.9933667182922363, 0.9930441379547119, 0.9927140474319458, 0.9923763275146484, 0.9920310974121094, 0.9916782379150391, 0.991317868232727, 0.9909499287605286, 0.9905744791030884, 0.9901914596557617, 0.9898009300231934, 0.9894028902053833, 0.9889973402023315, 0.9885842800140381, 0.9881637096405029, 0.9877356886863708, 0.9873001575469971, 0.9868571758270264, 0.9864067435264587, 0.9859488606452942, 0.9854835867881775, 0.9850108027458191, 0.9845306277275085, 0.9840430617332458, 0.9835480451583862, 0.9830456972122192, 0.9825359582901001, 0.9820188283920288, 0.9814943075180054, 0.9809625148773193, 0.9804233312606812, 0.9798768162727356, 0.9793230295181274, 0.9787619113922119, 0.9781935214996338, 0.9776178002357483, 0.977034866809845, 0.9764446020126343, 0.9758471846580505, 0.9752424359321594, 0.9746305346488953, 0.9740114212036133, 0.9733850955963135, 0.9727515578269958, 0.9721108675003052, 0.9714630246162415, 0.9708080291748047, 0.9701459407806396, 0.9694766998291016, 0.9688003659248352, 0.9681168794631958, 0.9674264192581177, 0.9667288064956665, 0.9660241603851318, 0.9653125405311584, 0.9645938277244568, 0.9638681411743164, 0.9631354808807373, 0.9623957872390747, 0.9616491794586182, 0.9608955979347229, 0.9601351022720337, 0.9593676924705505, 0.9585933685302734, 0.9578121304512024, 0.957024097442627, 0.9562291502952576, 0.955427348613739, 0.9546187520027161, 0.9538033604621887, 0.952981173992157, 0.9521521925926208, 0.9513164758682251, 0.9504740238189697, 0.9496248364448547, 0.9487689733505249, 0.9479063749313354, 0.9470371603965759, 0.9461612105369568, 0.9452787041664124, 0.9443895220756531, 0.9434937834739685, 0.9425914287567139, 0.9416825175285339, 0.9407670497894287, 0.939845085144043, 0.9389165639877319, 0.9379816055297852, 0.9370400905609131, 0.93609219789505, 0.9351378679275513, 0.9341771006584167, 0.9332098960876465, 0.93223637342453, 0.9312564730644226, 0.9302701950073242, 0.9292776584625244, 0.9282787442207336, 0.9272736310958862, 0.9262621998786926, 0.9252445697784424, 0.9242206811904907, 0.9231905937194824, 0.9221543669700623, 0.9211119413375854, 0.9200634360313416, 0.919008731842041, 0.9179479479789734, 0.9168811440467834, 0.9158082604408264, 0.9147292971611023, 0.9136443734169006, 0.9125534296035767, 0.9114565253257751, 0.9103536605834961, 0.9092448949813843, 0.9081302285194397, 0.9070096611976624, 0.9058831930160522, 0.9047509431838989, 0.9036128520965576, 0.9024689793586731, 0.9013193249702454, 0.9001639485359192, 0.8990027904510498, 0.8978359699249268, 0.89666348695755, 0.8954852819442749, 0.8943014740943909, 0.893112063407898, 0.8919170498847961, 0.8907164931297302, 0.8895103931427002, 0.888298749923706, 0.8870816230773926, 0.8858590126037598, 0.8846309781074524, 0.8833975195884705, 0.882158637046814, 0.8809143900871277, 0.8796647787094116, 0.8784098625183105, 0.8771495819091797, 0.8758841156959534, 0.874613344669342, 0.8733373284339905, 0.8720561265945435, 0.870769739151001, 0.8694782257080078, 0.8681815266609192, 0.8668797612190247, 0.8655729293823242, 0.8642610311508179, 0.8629440665245056, 0.861622154712677, 0.8602951765060425, 0.8589633107185364, 0.8576264977455139, 0.8562847971916199, 0.8549382090568542, 0.8535867929458618, 0.8522304892539978, 0.8508694171905518, 0.8495035767555237, 0.8481330275535583, 0.846757709980011, 0.8453776836395264, 0.8439930081367493, 0.8426036834716797, 0.8412097692489624, 0.8398112058639526, 0.8384081125259399, 0.8370004892349243, 0.8355883955955505, 0.8341717720031738, 0.832750678062439, 0.8313251733779907, 0.8298952579498291, 0.8284609913825989, 0.8270223140716553, 0.8255794048309326, 0.8241321444511414, 0.8226805925369263, 0.8212248682975769, 0.8197648525238037, 0.818300724029541, 0.816832423210144, 0.8153599500656128, 0.8138834238052368, 0.8124027848243713, 0.8109180927276611, 0.809429407119751, 0.8079367280006409, 0.8064400553703308, 0.8049394488334656, 0.8034349679946899, 0.8019266128540039, 0.8004143834114075, 0.7988982796669006, 0.7973784804344177, 0.7958548069000244, 0.7943274974822998, 0.7927963733673096, 0.791261613368988, 0.7897232174873352, 0.7881811857223511, 0.7866355180740356, 0.7850863337516785, 0.7835335731506348, 0.7819772958755493, 0.7804175615310669, 0.7788543701171875, 0.7772877216339111, 0.7757176756858826, 0.7741442918777466, 0.7725675106048584, 0.7709874510765076, 0.7694041132926941, 0.7678175568580627, 0.7662277221679688, 0.7646346688270569, 0.7630385160446167, 0.7614391446113586, 0.759836733341217, 0.7582311630249023, 0.7566226124763489, 0.7550110220909119, 0.7533963918685913, 0.7517788410186768, 0.7501583099365234, 0.7485349178314209, 0.7469086647033691, 0.7452794909477234, 0.7436475157737732, 0.7420127987861633, 0.740375280380249, 0.738735020160675, 0.7370920777320862, 0.7354464530944824, 0.7337982058525085, 0.7321473360061646, 0.7304938435554504, 0.728837788105011, 0.727179229259491, 0.7255182266235352, 0.723854660987854, 0.7221887111663818, 0.7205203175544739, 0.7188495993614197, 0.7171764969825745, 0.7155010104179382, 0.7138233184814453, 0.7121433019638062, 0.7104610800743103, 0.7087766528129578, 0.7070900797843933, 0.7054013013839722, 0.7037104368209839, 0.7020174860954285, 0.7003224492073059, 0.6986254453659058, 0.6969263553619385, 0.6952253580093384, 0.6935223937034607, 0.6918175220489502, 0.6901107430458069, 0.6884021759033203, 0.6866917610168457, 0.6849794983863831, 0.6832655072212219, 0.6815497875213623, 0.6798323392868042, 0.6781132221221924, 0.6763924956321716, 0.6746701002120972, 0.6729461550712585, 0.671220600605011, 0.669493556022644, 0.6677649617195129, 0.6660349369049072, 0.6643034815788269, 0.6625705361366272, 0.6608362793922424, 0.6591006517410278, 0.6573636531829834, 0.6556254029273987, 0.6538858413696289, 0.6521450877189636, 0.6504030823707581, 0.648659884929657, 0.6469155550003052, 0.6451701521873474, 0.6434235572814941, 0.6416759490966797, 0.639927327632904, 0.6381776332855225, 0.6364269852638245, 0.6346753835678101, 0.6329228281974792, 0.6311694383621216, 0.6294151544570923, 0.6276600360870361, 0.6259040832519531, 0.624147355556488, 0.6223899126052856, 0.6206316947937012, 0.6188728213310242, 0.6171132326126099, 0.6153530478477478, 0.6135922074317932, 0.6118308305740356, 0.6100688576698303, 0.6083064079284668, 0.6065434217453003, 0.6047799587249756, 0.6030160784721375, 0.6012517809867859, 0.5994871258735657, 0.597722053527832, 0.5959566831588745, 0.5941910147666931, 0.5924250483512878, 0.5906588435173035, 0.58889240026474, 0.5871257781982422, 0.5853589773178101, 0.5835920572280884, 0.5818250179290771, 0.5800579190254211, 0.5782907605171204, 0.5765235424041748, 0.574756383895874, 0.5729891657829285, 0.5712220668792725, 0.5694550275802612, 0.5676881074905396, 0.5659213066101074, 0.5641546249389648, 0.5623881816864014, 0.560621976852417, 0.5588559508323669, 0.5570902228355408, 0.5553247928619385, 0.5535597205162048, 0.5517949461936951, 0.550030529499054, 0.5482665300369263, 0.5465030074119568, 0.544739842414856, 0.5429772138595581, 0.5412151217460632, 0.5394535064697266, 0.5376924872398376, 0.5359320044517517, 0.5341721773147583, 0.5324129462242126, 0.5306543707847595, 0.5288965106010437, 0.5271393060684204, 0.5253828763961792, 0.5236272215843201, 0.521872341632843, 0.5201182961463928, 0.5183650255203247, 0.516612708568573, 0.5148612260818481, 0.5131106376647949, 0.5113610029220581, 0.5096123218536377, 0.5078646540641785, 0.5061179399490356, 0.5043722987174988, 0.5026277303695679, 0.5008842349052429, 0.4991418123245239, 0.49740055203437805, 0.4956604540348053, 0.49392154812812805, 0.4921838045120239, 0.4904473125934601, 0.4887120723724365, 0.48697811365127563, 0.4852454662322998, 0.48351410031318665, 0.4817841053009033, 0.48005548119544983, 0.47832825779914856, 0.4766024351119995, 0.47487807273864746, 0.47315514087677, 0.47143369913101196, 0.4697137773036957, 0.46799540519714355, 0.4662785530090332, 0.4645632803440094, 0.46284961700439453, 0.4611375629901886, 0.4594271779060364, 0.4577184319496155, 0.4560113847255707, 0.454306036233902, 0.45260241627693176, 0.4509005546569824, 0.44920048117637634, 0.4475021958351135, 0.44580569863319397, 0.44411107897758484, 0.44241830706596375, 0.4407274127006531, 0.4390384256839752, 0.43735137581825256, 0.4356662333011627, 0.43398308753967285, 0.43230193853378296, 0.43062275648117065, 0.4289456307888031, 0.4272705614566803, 0.42559751868247986, 0.42392659187316895, 0.42225778102874756, 0.4205910861492157, 0.41892656683921814, 0.4172641932964325, 0.41560399532318115, 0.4139460325241089, 0.4122902750968933, 0.4106367826461792, 0.40898555517196655, 0.40733659267425537, 0.40568995475769043, 0.40404564142227173, 0.40240365266799927, 0.4007640480995178, 0.399126797914505, 0.3974919617176056, 0.3958595395088196, 0.39422956109046936, 0.39260202646255493, 0.39097699522972107, 0.389354407787323, 0.3877343535423279, 0.3861168324947357, 0.3845018446445465, 0.38288941979408264, 0.3812795877456665, 0.3796723186969757, 0.3780677020549774, 0.37646567821502686, 0.3748663365840912, 0.373269647359848, 0.37167564034461975, 0.37008431553840637, 0.36849573254585266, 0.36690986156463623, 0.36532676219940186, 0.36374640464782715, 0.3621688485145569, 0.3605940639972687, 0.3590221107006073, 0.35745298862457275, 0.3558867275714874, 0.35432329773902893, 0.35276275873184204, 0.35120511054992676, 0.3496503531932831, 0.3480985164642334, 0.3465496301651001, 0.34500372409820557, 0.34346073865890503, 0.34192076325416565, 0.34038376808166504, 0.338849812746048, 0.3373188376426697, 0.3357909321784973, 0.3342660963535309, 0.332744300365448, 0.33122560381889343, 0.3297099769115448, 0.3281974792480469, 0.32668811082839966, 0.32518187165260315, 0.32367879152297974, 0.3221788704395294, 0.3206821084022522, 0.31918856501579285, 0.317698210477829, 0.316211074590683, 0.31472715735435486, 0.313246488571167, 0.3117690682411194, 0.3102949261665344, 0.3088240623474121, 0.30735647678375244, 0.3058921992778778, 0.3044312298297882, 0.30297359824180603, 0.3015192747116089, 0.30006834864616394, 0.2986207604408264, 0.2971765398979187, 0.2957356870174408, 0.2942982614040375, 0.29286420345306396, 0.2914336025714874, 0.2900063991546631, 0.2885826528072357, 0.28716233372688293, 0.2857455015182495, 0.28433212637901306, 0.2829222083091736, 0.28151580691337585, 0.2801128923892975, 0.27871349453926086, 0.2773175835609436, 0.27592524886131287, 0.2745364308357239, 0.273151159286499, 0.2717694342136383, 0.2703912854194641, 0.26901671290397644, 0.2676457166671753, 0.26627829670906067, 0.26491451263427734, 0.26355430483818054, 0.26219773292541504, 0.26084479689598083, 0.25949546694755554, 0.25814980268478394, 0.25680777430534363, 0.255469411611557, 0.2541347146034241, 0.2528036832809448, 0.25147634744644165, 0.25015267729759216, 0.24883271753787994, 0.247516468167305, 0.24620391428470612, 0.2448950856924057, 0.24358998239040375, 0.24228860437870026, 0.24099096655845642, 0.23969706892967224, 0.2384069263935089, 0.23712053894996643, 0.2358379065990448, 0.2345590442419052, 0.23328396677970886, 0.23201265931129456, 0.23074515163898468, 0.22948141396045685, 0.22822149097919464, 0.22696536779403687, 0.22571304440498352, 0.2244645357131958, 0.2232198417186737, 0.22197897732257843, 0.22074194252490997, 0.21950873732566833, 0.2182793766260147, 0.2170538455247879, 0.2158321589231491, 0.21461433172225952, 0.21340034902095795, 0.21219024062156677, 0.2109839767217636, 0.20978158712387085, 0.2085830718278885, 0.20738841593265533, 0.20619764924049377, 0.20501075685024261, 0.20382775366306305, 0.20264863967895508, 0.2014734148979187, 0.20030207931995392, 0.19913463294506073, 0.19797109067440033, 0.19681145250797272, 0.1956557184457779, 0.19450388848781586, 0.1933559775352478, 0.19221197068691254, 0.19107186794281006, 0.18993568420410156, 0.18880343437194824, 0.1876750886440277, 0.18655066192150116, 0.1854301542043686, 0.1843135803937912, 0.1832009255886078, 0.18209220468997955, 0.1809874027967453, 0.17988653481006622, 0.17878960072994232, 0.1776966005563736, 0.17660751938819885, 0.17552238702774048, 0.1744411736726761, 0.17336389422416687, 0.17229054868221283, 0.17122115194797516, 0.17015567421913147, 0.16909414529800415, 0.1680365353822708, 0.16698287427425385, 0.16593313217163086, 0.16488733887672424, 0.1638454794883728, 0.16280755400657654, 0.16177354753017426, 0.16074348986148834, 0.1597173511981964, 0.15869516134262085, 0.15767689049243927, 0.15666253864765167, 0.15565213561058044, 0.1546456515789032, 0.15364308655261993, 0.15264445543289185, 0.15164974331855774, 0.15065895020961761, 0.14967207610607147, 0.1486891210079193, 0.14771008491516113, 0.14673495292663574, 0.14576375484466553, 0.1447964459657669, 0.14383305609226227, 0.14287357032299042, 0.14191798865795135, 0.14096631109714508, 0.1400185227394104, 0.1390746384859085, 0.1381346434354782, 0.1371985375881195, 0.1362663209438324, 0.13533799350261688, 0.13441354036331177, 0.13349297642707825, 0.13257628679275513, 0.1316634565591812, 0.1307545006275177, 0.1298494189977646, 0.12894819676876068, 0.12805083394050598, 0.1271573156118393, 0.12626765668392181, 0.12538185715675354, 0.12449987977743149, 0.12362175434827805, 0.12274745851755142, 0.12187699973583221, 0.12101037055253983, 0.12014755606651306, 0.11928856372833252, 0.1184333935379982, 0.11758202314376831, 0.11673445999622345, 0.11589070409536362, 0.11505074054002762, 0.11421456187963486, 0.11338218301534653, 0.11255357414484024, 0.11172875016927719, 0.11090768873691559, 0.11009040474891663, 0.10927687585353851, 0.10846710205078125, 0.10766108334064484, 0.10685880482196808, 0.10606027394533157, 0.10526546835899353, 0.10447440296411514, 0.10368705540895462, 0.10290341824293137, 0.10212350636720657, 0.10134728997945786, 0.10057477653026581, 0.09980596601963043, 0.09904083609580994, 0.09827938675880432, 0.09752161800861359, 0.09676751494407654, 0.09601707756519318, 0.0952702984213829, 0.09452717006206512, 0.09378768503665924, 0.09305184334516525, 0.09231963008642197, 0.09159103780984879, 0.0908660739660263, 0.09014471620321274, 0.08942695707082748, 0.08871280401945114, 0.08800224214792252, 0.08729526400566101, 0.08659186214208603, 0.08589203655719757, 0.08519576489925385, 0.08450305461883545, 0.08381389826536179, 0.08312828093767166, 0.08244619518518448, 0.08176764100790024, 0.08109260350465775, 0.080421082675457, 0.07975306361913681, 0.07908854633569717, 0.0784275159239769, 0.07776997238397598, 0.07711590081453323, 0.07646530121564865, 0.07581815868616104, 0.07517446577548981, 0.07453422248363495, 0.07389741390943527, 0.07326403260231018, 0.07263407856225967, 0.07200752943754196, 0.07138439267873764, 0.07076465338468552, 0.0701482966542244, 0.06953532248735428, 0.06892572343349457, 0.06831949204206467, 0.06771661341190338, 0.06711708754301071, 0.06652089953422546, 0.06592804193496704, 0.06533850729465485, 0.06475229561328888, 0.06416938453912735, 0.06358977407217026, 0.06301344931125641, 0.0624404102563858, 0.061870645731687546, 0.06130414456129074, 0.06074089929461479, 0.0601809024810791, 0.05962414667010307, 0.05907062068581581, 0.05852031335234642, 0.0579732209444046, 0.05742933601140976, 0.0568886436522007, 0.05635114014148712, 0.05581681802868843, 0.05528566241264343, 0.05475766584277153, 0.054232824593782425, 0.05371112376451492, 0.053192559629678726, 0.05267712101340294, 0.052164800465106964, 0.05165558680891991, 0.05114947259426117, 0.05064644664525986, 0.05014650523662567, 0.04964963346719742, 0.0491558238863945, 0.04866506904363632, 0.048177361488342285, 0.047692690044641495, 0.047211043536663055, 0.04673241823911667, 0.04625679925084114, 0.04578418284654617, 0.04531455785036087, 0.04484791308641434, 0.04438424110412598, 0.04392353445291519, 0.043465785682201385, 0.043010979890823364, 0.04255910962820053, 0.04211016744375229, 0.04166414588689804, 0.04122103005647659, 0.040780819952487946, 0.040343496948480606, 0.039909057319164276, 0.03947748988866806, 0.03904878720641136, 0.03862294182181358, 0.03819993883371353, 0.03777977451682091, 0.03736243396997452, 0.03694791719317436, 0.03653620555996895, 0.03612729534506798, 0.035721179097890854, 0.03531784191727638, 0.034917280077934265, 0.03451947867870331, 0.03412443771958351, 0.03373213857412338, 0.03334257751703262, 0.03295574337244034, 0.03257162868976593, 0.032190222293138504, 0.03181151673197746, 0.03143550455570221, 0.03106217458844185, 0.030691517516970634, 0.03032352589070797, 0.029958190396428108, 0.029595499858260155, 0.02923545055091381, 0.028878027573227882, 0.028523225337266922, 0.028171034529805183, 0.02782144583761692, 0.027474451810121536, 0.027130041271448135, 0.02678820677101612, 0.026448940858244896, 0.026112230494618416, 0.025778071954846382, 0.0254464540630579, 0.02511736750602722, 0.024790804833173752, 0.024466756731271744, 0.02414521388709545, 0.023826168850064278, 0.023509612306952477, 0.02319553680717945, 0.022883933037519455, 0.022574791684746742, 0.022268105298280716, 0.02196386456489563, 0.021662062034010887, 0.02136269025504589, 0.021065736189484596, 0.020771196112036705, 0.02047906070947647, 0.020189320668578148, 0.01990196853876114, 0.019616995006799698, 0.01933439075946808, 0.019054152071475983, 0.018776265904307365, 0.01850072853267193, 0.018227526918053627, 0.017956657335162163, 0.01768810860812664, 0.017421875149011612, 0.01715794764459133, 0.016896318644285202, 0.016636978834867477, 0.01637992262840271, 0.016125140711665154, 0.01587262563407421, 0.015622369945049286, 0.015374365262687206, 0.01512860506772995, 0.01488508004695177, 0.014643783681094646, 0.014404707588255405, 0.014167845249176025, 0.01393318921327591, 0.013700730167329311, 0.013470463454723358, 0.013242379762232304, 0.01301647163927555, 0.012792733497917652, 0.012571156024932861, 0.01235173363238573, 0.012134457938373089, 0.011919323354959488, 0.011706321500241756, 0.011495444923639297, 0.011286688037216663, 0.011080043390393257, 0.010875504463911057, 0.01067306287586689, 0.010472713969647884, 0.010274449363350868, 0.01007826253771782, 0.00988414790481329, 0.009692097082734108, 0.009502105414867401, 0.009314165450632572, 0.009128270670771599, 0.008944414556026459, 0.00876259058713913, 0.008582794107496738, 0.008405016735196114, 0.008229252882301807, 0.008055496960878372, 0.007883742451667786, 0.0077139828354120255, 0.007546212989836931, 0.007380426395684481, 0.007216617465019226, 0.0070547801442444324, 0.006894908845424652, 0.00673699751496315, 0.0065810405649244785, 0.00642703240737319, 0.0062749674543738365, 0.006124840117990971, 0.0059766448102891445, 0.005830376874655485, 0.0056860302574932575, 0.005543599370867014, 0.005403079558163881, 0.005264465697109699, 0.00512775219976902, 0.004992934409528971, 0.004860007204115391, 0.00472896546125412, 0.004599804524332285, 0.0044725192710757256, 0.004347105044871569, 0.004223557189106941, 0.00410187104716897, 0.003982041962444782, 0.0038640655111521482, 0.003747937036678195, 0.003633652115240693, 0.0035212067887187004, 0.0034105961676687002, 0.003301816526800394, 0.0031948634423315525, 0.00308973272331059, 0.0029864206444472075, 0.002884922781959176, 0.002785235643386841, 0.002687355037778616, 0.0025912774726748466, 0.002496998989954591, 0.00240451586432755, 0.002313824836164713, 0.0022249219473451376, 0.002137803938239813, 0.0020524675492197275, 0.001968909054994583, 0.0018871253123506904, 0.0018071132944896817, 0.0017288696253672242, 0.0016523912781849504, 0.0015776753425598145, 0.0015047186752781272, 0.0014335184823721647, 0.0013640718534588814, 0.001296376227401197, 0.0012304286938160658, 0.0011662266915664077, 0.0011037677759304643, 0.0010430492693558335, 0.000984068843536079, 0.0009268240537494421, 0.0008713127463124692, 0.0008175325347110629, 0.0007654813816770911, 0.0007151571335271001, 0.0006665578112006187, 0.0006196813774295151, 0.0005745260277763009, 0.000531089841388166, 0.0004893711884506047, 0.00044936826452612877, 0.000411079527111724, 0.0003745033754967153, 0.0003396383544895798, 0.00030648306710645556, 0.00027503614546731114, 0.000245296279899776, 0.00021726233535446227, 0.00019093311857432127, 0.00016630758182145655, 0.00014338470646180212, 0.0001221635757246986, 0.00010264330921927467, 8.4823121142108e-05, 6.870229117339477e-05, 5.42801535630133e-05, 4.1556122596375644e-05, 3.052967804251239e-05, 2.1200372430030257e-05, 1.3567823771154508e-05, 7.631719199707732e-06, 3.391817472220282e-06, 8.479456710119848e-07, -1.3877787807814457e-17 ] ================================================ FILE: __tests__/data/blackman256.json ================================================ [ -1.3877787807814457e-17, 5.465338836074807e-05, 0.0002187572099501267, 0.0004927419940941036, 0.0008773234440013766, 0.0013735000975430012, 0.001982549438253045, 0.0027060233987867832, 0.003545743180438876, 0.004503792151808739, 0.005582507699728012, 0.006784474011510611, 0.008112512528896332, 0.009569671005010605, 0.011159210465848446, 0.012884598225355148, 0.014749490655958652, 0.016757719218730927, 0.018913280218839645, 0.021220317110419273, 0.023683100938796997, 0.026306021958589554, 0.02909356914460659, 0.03205030784010887, 0.035180870443582535, 0.0384899266064167, 0.04198218509554863, 0.045662347227334976, 0.049535106867551804, 0.05360512435436249, 0.057877011597156525, 0.062355298548936844, 0.06704442948102951, 0.07194873690605164, 0.07707241922616959, 0.0824195146560669, 0.08799390494823456, 0.09379925578832626, 0.09983905404806137, 0.10611651837825775, 0.11263464391231537, 0.1193961501121521, 0.12640348076820374, 0.1336587518453598, 0.14116378128528595, 0.14892004430294037, 0.1569286733865738, 0.1651904284954071, 0.17370566725730896, 0.18247437477111816, 0.19149614870548248, 0.20077013969421387, 0.21029508113861084, 0.22006924450397491, 0.23009051382541656, 0.2403562366962433, 0.25086337327957153, 0.261608362197876, 0.2725871801376343, 0.28379538655281067, 0.295227974653244, 0.3068794906139374, 0.318744033575058, 0.3308151960372925, 0.34308603405952454, 0.35554927587509155, 0.3681969940662384, 0.38102099299430847, 0.3940124213695526, 0.4071621298789978, 0.42046046257019043, 0.43389734625816345, 0.4474622309207916, 0.46114426851272583, 0.47493213415145874, 0.488814115524292, 0.502778172492981, 0.5168119072914124, 0.530902624130249, 0.5450371503829956, 0.5592021942138672, 0.5733842253684998, 0.5875691771507263, 0.6017430424690247, 0.6158915162086487, 0.6299999952316284, 0.6440538167953491, 0.6580381989479065, 0.6719380617141724, 0.6857385039329529, 0.6994242668151855, 0.712980329990387, 0.7263913750648499, 0.739642322063446, 0.7527180314064026, 0.7656033635139465, 0.778283417224884, 0.7907432317733765, 0.8029680848121643, 0.8149434328079224, 0.8266549110412598, 0.8380883932113647, 0.8492298722267151, 0.860065758228302, 0.8705826997756958, 0.8807676434516907, 0.8906079530715942, 0.9000912308692932, 0.9092056751251221, 0.9179396033287048, 0.9262821078300476, 0.934222400188446, 0.9417504668235779, 0.9488565325737, 0.9555315375328064, 0.96176677942276, 0.9675542116165161, 0.972886323928833, 0.9777562022209167, 0.9821574091911316, 0.9860843420028687, 0.9895316958427429, 0.992495059967041, 0.9949705004692078, 0.9969547986984253, 0.9984453320503235, 0.99944007396698, 0.9999377727508545, 0.9999377727508545, 0.99944007396698, 0.9984453320503235, 0.9969547986984253, 0.9949705004692078, 0.992495059967041, 0.9895316958427429, 0.9860843420028687, 0.9821574091911316, 0.9777562022209167, 0.972886323928833, 0.9675542116165161, 0.96176677942276, 0.9555315375328064, 0.9488565325737, 0.9417504668235779, 0.934222400188446, 0.9262821078300476, 0.9179396033287048, 0.9092056751251221, 0.9000912308692932, 0.8906079530715942, 0.8807676434516907, 0.8705826997756958, 0.860065758228302, 0.8492298722267151, 0.8380883932113647, 0.8266549110412598, 0.8149434328079224, 0.8029680848121643, 0.7907432317733765, 0.778283417224884, 0.7656033635139465, 0.7527180314064026, 0.739642322063446, 0.7263913750648499, 0.712980329990387, 0.6994242668151855, 0.6857385039329529, 0.6719380617141724, 0.6580381989479065, 0.6440538167953491, 0.6299999952316284, 0.6158915162086487, 0.6017430424690247, 0.5875691771507263, 0.5733842253684998, 0.5592021942138672, 0.5450371503829956, 0.530902624130249, 0.5168119072914124, 0.502778172492981, 0.488814115524292, 0.47493213415145874, 0.46114426851272583, 0.4474622309207916, 0.43389734625816345, 0.42046046257019043, 0.4071621298789978, 0.3940124213695526, 0.38102099299430847, 0.3681969940662384, 0.35554927587509155, 0.34308603405952454, 0.3308151960372925, 0.318744033575058, 0.3068794906139374, 0.295227974653244, 0.28379538655281067, 0.2725871801376343, 0.261608362197876, 0.25086337327957153, 0.2403562366962433, 0.23009051382541656, 0.22006924450397491, 0.21029508113861084, 0.20077013969421387, 0.19149614870548248, 0.18247437477111816, 0.17370566725730896, 0.1651904284954071, 0.1569286733865738, 0.14892004430294037, 0.14116378128528595, 0.1336587518453598, 0.12640348076820374, 0.1193961501121521, 0.11263464391231537, 0.10611651837825775, 0.09983905404806137, 0.09379925578832626, 0.08799390494823456, 0.0824195146560669, 0.07707241922616959, 0.07194873690605164, 0.06704442948102951, 0.062355298548936844, 0.057877011597156525, 0.05360512435436249, 0.049535106867551804, 0.045662347227334976, 0.04198218509554863, 0.0384899266064167, 0.035180870443582535, 0.03205030784010887, 0.02909356914460659, 0.026306021958589554, 0.023683100938796997, 0.021220317110419273, 0.018913280218839645, 0.016757719218730927, 0.014749490655958652, 0.012884598225355148, 0.011159210465848446, 0.009569671005010605, 0.008112512528896332, 0.006784474011510611, 0.005582507699728012, 0.004503792151808739, 0.003545743180438876, 0.0027060233987867832, 0.001982549438253045, 0.0013735000975430012, 0.0008773234440013766, 0.0004927419940941036, 0.0002187572099501267, 5.465338836074807e-05, -1.3877787807814457e-17 ] ================================================ FILE: __tests__/data/blackman512.json ================================================ [ -1.3877787807814457e-17, 1.3607682376459707e-05, 5.44396425539162e-05, 0.0001225226151291281, 0.00021790112077724189, 0.00034063743078149855, 0.0004908115370199084, 0.0006685210973955691, 0.000873881159350276, 0.001107024378143251, 0.0013681006385013461, 0.0016572769964113832, 0.0019747375044971704, 0.002320683328434825, 0.002695332048460841, 0.0030989176593720913, 0.0035316909197717905, 0.003993918187916279, 0.004485881421715021, 0.005007879342883825, 0.0055602239444851875, 0.006143244449049234, 0.006757283117622137, 0.007402697112411261, 0.00807985756546259, 0.008789150044322014, 0.009530973620712757, 0.01030573807656765, 0.011113868094980717, 0.011955800466239452, 0.012831982225179672, 0.013742873445153236, 0.0146889453753829, 0.01567067764699459, 0.01668856292963028, 0.017743101343512535, 0.018834801390767097, 0.01996418461203575, 0.02113177441060543, 0.022338109090924263, 0.023583726957440376, 0.024869179353117943, 0.026195017620921135, 0.02756180427968502, 0.028970103710889816, 0.030420485883951187, 0.03191352263092995, 0.033449795097112656, 0.035029876977205276, 0.036654356867074966, 0.03832381218671799, 0.040038831532001495, 0.04179999977350235, 0.04360789805650711, 0.04546311870217323, 0.04736623540520668, 0.04931783303618431, 0.051318492740392685, 0.05336878448724747, 0.05546928569674492, 0.05762055516242981, 0.059823162853717804, 0.062077656388282776, 0.0643845945596695, 0.06674451380968094, 0.06915795803070068, 0.07162544131278992, 0.07414749264717102, 0.07672461867332458, 0.07935731112957001, 0.08204606920480728, 0.08479136973619461, 0.08759366720914841, 0.09045342355966568, 0.09337107837200165, 0.09634705632925034, 0.09938176721334457, 0.1024756133556366, 0.10562896728515625, 0.10884220153093338, 0.11211567372083664, 0.1154496967792511, 0.11884460598230362, 0.12230068445205688, 0.12581820785999298, 0.1293974369764328, 0.13303862512111664, 0.1367419809103012, 0.14050769805908203, 0.14433594048023224, 0.14822690188884735, 0.15218067169189453, 0.15619738399982452, 0.1602771282196045, 0.16441994905471802, 0.16862590610980988, 0.17289499938488007, 0.17722724378108978, 0.18162256479263306, 0.1860809326171875, 0.19060224294662476, 0.19518640637397766, 0.19983325898647308, 0.20454265177249908, 0.20931439101696014, 0.21414823830127716, 0.21904397010803223, 0.22400128841400146, 0.2290199100971222, 0.23409949243068695, 0.2392396628856659, 0.24444004893302917, 0.24970023334026337, 0.25501975417137146, 0.26039811968803406, 0.26583486795425415, 0.27132943272590637, 0.27688124775886536, 0.28248974680900574, 0.2881542444229126, 0.2938741445541382, 0.2996487319469452, 0.3054772913455963, 0.31135910749435425, 0.31729334592819214, 0.3232792913913727, 0.32931602001190186, 0.3354027271270752, 0.3415384888648987, 0.3477224111557007, 0.3539535105228424, 0.36023083329200745, 0.3665533661842346, 0.37292003631591797, 0.3793298304080963, 0.3857816159725189, 0.39227429032325745, 0.39880669116973877, 0.40537765622138977, 0.41198593378067017, 0.41863036155700684, 0.4253096282482147, 0.43202248215675354, 0.43876758217811584, 0.4455436170101166, 0.4523491859436035, 0.4591829478740692, 0.46604350209236145, 0.47292935848236084, 0.4798390865325928, 0.48677122592926025, 0.4937242269515991, 0.50069659948349, 0.5076868534088135, 0.5146933197975159, 0.521714448928833, 0.528748631477356, 0.535794198513031, 0.542849600315094, 0.5499131679534912, 0.5569831132888794, 0.5640578269958496, 0.5711356401443481, 0.5782146453857422, 0.5852932929992676, 0.5923697352409363, 0.599442183971405, 0.6065089106559753, 0.613568127155304, 0.6206179261207581, 0.6276565790176392, 0.6346822381019592, 0.6416930556297302, 0.6486871838569641, 0.6556628346443176, 0.6626180410385132, 0.6695510149002075, 0.6764598488807678, 0.683342695236206, 0.6901976466178894, 0.6970228552818298, 0.7038164138793945, 0.7105764150619507, 0.7173009514808655, 0.7239882349967957, 0.7306362986564636, 0.7372432947158813, 0.7438073754310608, 0.7503265738487244, 0.756799042224884, 0.7632229328155518, 0.7695963978767395, 0.7759175896644592, 0.7821846008300781, 0.7883956432342529, 0.7945488691329956, 0.8006424903869629, 0.806674599647522, 0.8126435279846191, 0.8185474276542664, 0.8243845105171204, 0.8301530480384827, 0.83585125207901, 0.8414774537086487, 0.8470299243927002, 0.8525069355964661, 0.8579068183898926, 0.8632279634475708, 0.8684687614440918, 0.8736274838447571, 0.8787025809288025, 0.8836924433708191, 0.8885956406593323, 0.8934105634689331, 0.8981356620788574, 0.9027695059776306, 0.9073106646537781, 0.9117576479911804, 0.9161090850830078, 0.9203636050224304, 0.9245198965072632, 0.9285765290260315, 0.9325323104858398, 0.936385989189148, 0.9401362538337708, 0.9437819719314575, 0.9473219513893127, 0.9507550597190857, 0.9540801644325256, 0.9572962522506714, 0.9604023098945618, 0.963397204875946, 0.9662801027297974, 0.9690499901771545, 0.9717060327529907, 0.9742472767829895, 0.9766730070114136, 0.9789823889732361, 0.981174647808075, 0.9832491278648376, 0.9852050542831421, 0.9870418906211853, 0.9887589812278748, 0.9903557896614075, 0.9918317794799805, 0.9931864738464355, 0.9944194555282593, 0.9955302476882935, 0.9965185523033142, 0.9973840713500977, 0.9981264472007751, 0.9987454414367676, 0.9992409348487854, 0.9996126294136047, 0.9998605251312256, 0.9999845027923584, 0.9999845027923584, 0.9998605251312256, 0.9996126294136047, 0.9992409348487854, 0.9987454414367676, 0.9981264472007751, 0.9973840713500977, 0.9965185523033142, 0.9955302476882935, 0.9944194555282593, 0.9931864738464355, 0.9918317794799805, 0.9903557896614075, 0.9887589812278748, 0.9870418906211853, 0.9852050542831421, 0.9832491278648376, 0.981174647808075, 0.9789823889732361, 0.9766730070114136, 0.9742472767829895, 0.9717060327529907, 0.9690499901771545, 0.9662801027297974, 0.963397204875946, 0.9604023098945618, 0.9572962522506714, 0.9540801644325256, 0.9507550597190857, 0.9473219513893127, 0.9437819719314575, 0.9401362538337708, 0.936385989189148, 0.9325323104858398, 0.9285765290260315, 0.9245198965072632, 0.9203636050224304, 0.9161090850830078, 0.9117576479911804, 0.9073106646537781, 0.9027695059776306, 0.8981356620788574, 0.8934105634689331, 0.8885956406593323, 0.8836924433708191, 0.8787025809288025, 0.8736274838447571, 0.8684687614440918, 0.8632279634475708, 0.8579068183898926, 0.8525069355964661, 0.8470299243927002, 0.8414774537086487, 0.83585125207901, 0.8301530480384827, 0.8243845105171204, 0.8185474276542664, 0.8126435279846191, 0.806674599647522, 0.8006424903869629, 0.7945488691329956, 0.7883956432342529, 0.7821846008300781, 0.7759175896644592, 0.7695963978767395, 0.7632229328155518, 0.756799042224884, 0.7503265738487244, 0.7438073754310608, 0.7372432947158813, 0.7306362986564636, 0.7239882349967957, 0.7173009514808655, 0.7105764150619507, 0.7038164138793945, 0.6970228552818298, 0.6901976466178894, 0.683342695236206, 0.6764598488807678, 0.6695510149002075, 0.6626180410385132, 0.6556628346443176, 0.6486871838569641, 0.6416930556297302, 0.6346822381019592, 0.6276565790176392, 0.6206179261207581, 0.613568127155304, 0.6065089106559753, 0.599442183971405, 0.5923697352409363, 0.5852932929992676, 0.5782146453857422, 0.5711356401443481, 0.5640578269958496, 0.5569831132888794, 0.5499131679534912, 0.542849600315094, 0.535794198513031, 0.528748631477356, 0.521714448928833, 0.5146933197975159, 0.5076868534088135, 0.50069659948349, 0.4937242269515991, 0.48677122592926025, 0.4798390865325928, 0.47292935848236084, 0.46604350209236145, 0.4591829478740692, 0.4523491859436035, 0.4455436170101166, 0.43876758217811584, 0.43202248215675354, 0.4253096282482147, 0.41863036155700684, 0.41198593378067017, 0.40537765622138977, 0.39880669116973877, 0.39227429032325745, 0.3857816159725189, 0.3793298304080963, 0.37292003631591797, 0.3665533661842346, 0.36023083329200745, 0.3539535105228424, 0.3477224111557007, 0.3415384888648987, 0.3354027271270752, 0.32931602001190186, 0.3232792913913727, 0.31729334592819214, 0.31135910749435425, 0.3054772913455963, 0.2996487319469452, 0.2938741445541382, 0.2881542444229126, 0.28248974680900574, 0.27688124775886536, 0.27132943272590637, 0.26583486795425415, 0.26039811968803406, 0.25501975417137146, 0.24970023334026337, 0.24444004893302917, 0.2392396628856659, 0.23409949243068695, 0.2290199100971222, 0.22400128841400146, 0.21904397010803223, 0.21414823830127716, 0.20931439101696014, 0.20454265177249908, 0.19983325898647308, 0.19518640637397766, 0.19060224294662476, 0.1860809326171875, 0.18162256479263306, 0.17722724378108978, 0.17289499938488007, 0.16862590610980988, 0.16441994905471802, 0.1602771282196045, 0.15619738399982452, 0.15218067169189453, 0.14822690188884735, 0.14433594048023224, 0.14050769805908203, 0.1367419809103012, 0.13303862512111664, 0.1293974369764328, 0.12581820785999298, 0.12230068445205688, 0.11884460598230362, 0.1154496967792511, 0.11211567372083664, 0.10884220153093338, 0.10562896728515625, 0.1024756133556366, 0.09938176721334457, 0.09634705632925034, 0.09337107837200165, 0.09045342355966568, 0.08759366720914841, 0.08479136973619461, 0.08204606920480728, 0.07935731112957001, 0.07672461867332458, 0.07414749264717102, 0.07162544131278992, 0.06915795803070068, 0.06674451380968094, 0.0643845945596695, 0.062077656388282776, 0.059823162853717804, 0.05762055516242981, 0.05546928569674492, 0.05336878448724747, 0.051318492740392685, 0.04931783303618431, 0.04736623540520668, 0.04546311870217323, 0.04360789805650711, 0.04179999977350235, 0.040038831532001495, 0.03832381218671799, 0.036654356867074966, 0.035029876977205276, 0.033449795097112656, 0.03191352263092995, 0.030420485883951187, 0.028970103710889816, 0.02756180427968502, 0.026195017620921135, 0.024869179353117943, 0.023583726957440376, 0.022338109090924263, 0.02113177441060543, 0.01996418461203575, 0.018834801390767097, 0.017743101343512535, 0.01668856292963028, 0.01567067764699459, 0.0146889453753829, 0.013742873445153236, 0.012831982225179672, 0.011955800466239452, 0.011113868094980717, 0.01030573807656765, 0.009530973620712757, 0.008789150044322014, 0.00807985756546259, 0.007402697112411261, 0.006757283117622137, 0.006143244449049234, 0.0055602239444851875, 0.005007879342883825, 0.004485881421715021, 0.003993918187916279, 0.0035316909197717905, 0.0030989176593720913, 0.002695332048460841, 0.002320683328434825, 0.0019747375044971704, 0.0016572769964113832, 0.0013681006385013461, 0.001107024378143251, 0.000873881159350276, 0.0006685210973955691, 0.0004908115370199084, 0.00034063743078149855, 0.00021790112077724189, 0.0001225226151291281, 5.44396425539162e-05, 1.3607682376459707e-05, -1.3877787807814457e-17 ] ================================================ FILE: __tests__/data/hamming1024.json ================================================ [ 0.07999999821186066, 0.08000865578651428, 0.08003463596105576, 0.08007793128490448, 0.08013854175806046, 0.08021646738052368, 0.08031170070171356, 0.0804242417216301, 0.08055409044027328, 0.08070123195648193, 0.08086566627025604, 0.08104738593101501, 0.08124639093875885, 0.08146265894174576, 0.08169619739055634, 0.08194699138402939, 0.08221502602100372, 0.08250029385089874, 0.08280279487371445, 0.08312250673770905, 0.08345941454172134, 0.08381351083517075, 0.08418478816747665, 0.08457322418689728, 0.08497880399227142, 0.0854015201330185, 0.0858413502573967, 0.08629827201366425, 0.08677228540182114, 0.08726336061954498, 0.087771475315094, 0.08829662203788757, 0.08883877098560333, 0.08939790725708008, 0.08997400850057602, 0.09056705236434937, 0.09117701649665833, 0.0918038859963417, 0.09244762361049652, 0.09310820698738098, 0.09378562122583389, 0.09447983652353287, 0.09519082307815552, 0.09591855853796005, 0.09666301310062408, 0.09742415696382523, 0.09820196032524109, 0.09899640083312988, 0.09980744868516922, 0.10063505917787552, 0.10147922486066818, 0.10233989357948303, 0.10321703553199768, 0.10411062836647034, 0.10502062737941742, 0.10594701021909714, 0.10688973218202591, 0.10784875601530075, 0.10882405191659927, 0.1098155826330185, 0.11082331091165543, 0.11184719949960709, 0.11288720369338989, 0.11394328624010086, 0.1150154173374176, 0.11610354483127594, 0.11720763146877289, 0.11832763254642487, 0.11946351081132889, 0.12061522156000137, 0.12178272753953934, 0.1229659765958786, 0.12416492402553558, 0.1253795325756073, 0.12660974264144897, 0.12785552442073822, 0.12911681830883026, 0.1303935945034027, 0.1316857784986496, 0.13299334049224854, 0.13431622087955475, 0.13565437495708466, 0.13700775802135468, 0.13837631046772003, 0.13975998759269714, 0.14115872979164124, 0.14257249236106873, 0.14400120079517365, 0.1454448401927948, 0.14690332114696503, 0.14837661385536194, 0.14986464381217957, 0.15136736631393433, 0.15288470685482025, 0.15441663563251495, 0.15596307814121246, 0.157523974776268, 0.159099280834198, 0.16068892180919647, 0.16229283809661865, 0.16391098499298096, 0.16554328799247742, 0.16718968749046326, 0.1688501238822937, 0.17052453756332397, 0.1722128540277481, 0.17391502857208252, 0.17563097178936005, 0.1773606389760971, 0.17910397052764893, 0.18086087703704834, 0.18263129889965057, 0.18441519141197205, 0.1862124651670456, 0.18802306056022644, 0.18984690308570862, 0.19168393313884735, 0.19353407621383667, 0.1953972578048706, 0.19727341830730438, 0.19916248321533203, 0.20106437802314758, 0.20297902822494507, 0.2049063742160797, 0.20684634149074554, 0.2087988406419754, 0.2107638269662857, 0.2127411961555481, 0.2147308737039566, 0.21673281490802765, 0.21874693036079407, 0.2207731306552887, 0.22281135618686676, 0.2248615175485611, 0.22692354023456573, 0.2289973497390747, 0.23108288645744324, 0.23318003118038177, 0.23528873920440674, 0.23740892112255096, 0.2395404875278473, 0.24168337881565094, 0.24383749067783356, 0.24600274860858917, 0.248179093003273, 0.2503664195537567, 0.2525646388530731, 0.25477367639541626, 0.25699347257614136, 0.25922390818595886, 0.261464923620224, 0.2637164294719696, 0.26597830653190613, 0.2682505249977112, 0.2705329954624176, 0.27282556891441345, 0.27512824535369873, 0.2774408459663391, 0.2797633707523346, 0.28209567070007324, 0.2844376862049103, 0.28678932785987854, 0.28915050625801086, 0.2915211319923401, 0.29390108585357666, 0.2962903380393982, 0.29868873953819275, 0.30109623074531555, 0.3035127520561218, 0.30593812465667725, 0.3083723485469818, 0.3108152747154236, 0.3132668435573578, 0.3157269358634949, 0.3181954622268677, 0.3206723630428314, 0.32315748929977417, 0.32565081119537354, 0.3281521797180176, 0.3306615352630615, 0.3331787884235382, 0.3357038199901581, 0.338236540555954, 0.34077683091163635, 0.3433246612548828, 0.3458798825740814, 0.348442405462265, 0.35101214051246643, 0.3535889983177185, 0.3561728596687317, 0.3587636649608612, 0.3613612651824951, 0.36396563053131104, 0.36657658219337463, 0.3691940903663635, 0.37181803584098816, 0.3744482696056366, 0.37708479166030884, 0.37972739338874817, 0.3823760747909546, 0.3850306570529938, 0.38769111037254333, 0.39035725593566895, 0.3930290639400482, 0.3957063853740692, 0.39838916063308716, 0.4010772705078125, 0.4037705957889557, 0.40646904706954956, 0.40917253494262695, 0.4118809401988983, 0.4145941734313965, 0.4173121452331543, 0.4200347065925598, 0.42276179790496826, 0.4254932999610901, 0.42822912335395813, 0.43096914887428284, 0.43371325731277466, 0.4364613890647888, 0.43921342492103577, 0.44196924567222595, 0.4447287619113922, 0.447491854429245, 0.4502584636211395, 0.4530284106731415, 0.45580166578292847, 0.45857805013656616, 0.4613575339317322, 0.4641399681568146, 0.4669252634048462, 0.4697133004665375, 0.47250398993492126, 0.475297212600708, 0.47809287905693054, 0.4808908700942993, 0.48369109630584717, 0.48649343848228455, 0.4892977774143219, 0.49210405349731445, 0.49491211771965027, 0.4977218806743622, 0.5005332231521606, 0.5033460855484009, 0.506160318851471, 0.5089758038520813, 0.5117924809455872, 0.5146101713180542, 0.5174288749694824, 0.5202484130859375, 0.5230686664581299, 0.5258895754814148, 0.5287110209465027, 0.531532883644104, 0.534355103969574, 0.5371775031089783, 0.5400000214576721, 0.5428224802017212, 0.5456448793411255, 0.5484670996665955, 0.5512889623641968, 0.5541104078292847, 0.5569313168525696, 0.559751570224762, 0.562571108341217, 0.5653898119926453, 0.5682075619697571, 0.5710241794586182, 0.5738397240638733, 0.5766538977622986, 0.5794667601585388, 0.5822781324386597, 0.5850878953933716, 0.587895929813385, 0.5907022356987, 0.5935065746307373, 0.5963088870048523, 0.5991091132164001, 0.6019071340560913, 0.6047027707099915, 0.6074960231781006, 0.6102867126464844, 0.6130747199058533, 0.6158600449562073, 0.6186424493789673, 0.6214219331741333, 0.6241983771324158, 0.6269716024398804, 0.6297415494918823, 0.6325081586837769, 0.6352712512016296, 0.6380307674407959, 0.6407865881919861, 0.6435385942459106, 0.6462867259979248, 0.649030864238739, 0.6517708897590637, 0.6545066833496094, 0.6572381854057312, 0.6599652767181396, 0.6626878976821899, 0.665405809879303, 0.6681190729141235, 0.6708274483680725, 0.6735309362411499, 0.6762294173240662, 0.678922712802887, 0.6816108226776123, 0.6842936277389526, 0.6869709491729736, 0.6896427273750305, 0.6923089027404785, 0.6949693560600281, 0.6976239085197449, 0.7002726197242737, 0.7029152512550354, 0.7055517435073853, 0.7081819772720337, 0.7108058929443359, 0.7134234309196472, 0.7160343527793884, 0.7186387181282043, 0.7212363481521606, 0.7238271236419678, 0.726410984992981, 0.7289878726005554, 0.7315576076507568, 0.7341201305389404, 0.7366753220558167, 0.7392231822013855, 0.7417634725570679, 0.7442961931228638, 0.7468212246894836, 0.7493384480476379, 0.7518478035926819, 0.7543491721153259, 0.7568424940109253, 0.7593276500701904, 0.7618045210838318, 0.7642730474472046, 0.7667331695556641, 0.7691847085952759, 0.77162766456604, 0.7740618586540222, 0.7764872908592224, 0.7789037823677063, 0.7813112735748291, 0.7837096452713013, 0.7860988974571228, 0.7884788513183594, 0.790849506855011, 0.7932106852531433, 0.7955623269081116, 0.7979043126106262, 0.8002366423606873, 0.8025591373443604, 0.8048717975616455, 0.8071744441986084, 0.8094670176506042, 0.8117494583129883, 0.8140217065811157, 0.8162835836410522, 0.8185350894927979, 0.820776104927063, 0.8230065107345581, 0.8252263069152832, 0.8274353742599487, 0.8296335935592651, 0.8318209052085876, 0.8339972496032715, 0.8361625075340271, 0.8383166193962097, 0.8404595255851746, 0.8425911068916321, 0.8447112441062927, 0.8468199372291565, 0.8489171266555786, 0.8510026335716248, 0.8530764579772949, 0.8551384806632996, 0.8571886420249939, 0.8592268824577332, 0.8612530827522278, 0.863267183303833, 0.865269124507904, 0.8672587871551514, 0.869236171245575, 0.8712011575698853, 0.8731536865234375, 0.8750936388969421, 0.8770209550857544, 0.8789356350898743, 0.8808375000953674, 0.8827266097068787, 0.8846027255058289, 0.8864659070968628, 0.8883160948753357, 0.8901531100273132, 0.8919769525527954, 0.8937875628471375, 0.8955848217010498, 0.8973686695098877, 0.8991391062736511, 0.9008960127830505, 0.9026393294334412, 0.9043689966201782, 0.9060849547386169, 0.9077871441841125, 0.9094754457473755, 0.9111498594284058, 0.9128103256225586, 0.9144567251205444, 0.9160889983177185, 0.9177071452140808, 0.9193111062049866, 0.9209007024765015, 0.9224759936332703, 0.9240369200706482, 0.9255833625793457, 0.927115261554718, 0.9286326169967651, 0.9301353693008423, 0.9316233992576599, 0.9330966472625732, 0.934555172920227, 0.935998797416687, 0.9374275207519531, 0.9388412833213806, 0.9402400255203247, 0.9416236877441406, 0.9429922699928284, 0.9443456530570984, 0.9456837773323059, 0.9470066428184509, 0.9483142495155334, 0.9496064186096191, 0.950883150100708, 0.9521445035934448, 0.9533902406692505, 0.9546204805374146, 0.9558351039886475, 0.9570340514183044, 0.9582172632217407, 0.9593847990036011, 0.9605364799499512, 0.9616723656654358, 0.9627923965454102, 0.9638964533805847, 0.9649845957756042, 0.9660567045211792, 0.9671127796173096, 0.9681528210639954, 0.969176709651947, 0.9701843857765198, 0.9711759686470032, 0.9721512198448181, 0.9731102585792542, 0.9740529656410217, 0.9749793410301208, 0.9758893847465515, 0.9767829775810242, 0.9776601195335388, 0.9785207509994507, 0.9793649315834045, 0.9801925420761108, 0.9810035824775696, 0.9817980527877808, 0.9825758337974548, 0.9833369851112366, 0.9840814471244812, 0.984809160232544, 0.9855201840400696, 0.9862143993377686, 0.9868918061256409, 0.9875524044036865, 0.9881961345672607, 0.9888229966163635, 0.9894329309463501, 0.9900259971618652, 0.9906020760536194, 0.9911612272262573, 0.9917033910751343, 0.9922285079956055, 0.9927366375923157, 0.9932277202606201, 0.993701696395874, 0.9941586256027222, 0.9945985078811646, 0.9950212240219116, 0.9954267740249634, 0.9958152174949646, 0.9961864948272705, 0.9965406060218811, 0.9968774914741516, 0.9971972107887268, 0.9974997043609619, 0.9977849721908569, 0.9980530142784119, 0.9983038306236267, 0.9985373616218567, 0.9987536072731018, 0.9989526271820068, 0.9991343021392822, 0.9992987513542175, 0.999445915222168, 0.9995757341384888, 0.9996882677078247, 0.9997835159301758, 0.999861478805542, 0.9999220967292786, 0.9999653697013855, 0.9999913573265076, 1, 0.9999913573265076, 0.9999653697013855, 0.9999220967292786, 0.999861478805542, 0.9997835159301758, 0.9996882677078247, 0.9995757341384888, 0.999445915222168, 0.9992987513542175, 0.9991343021392822, 0.9989526271820068, 0.9987536072731018, 0.9985373616218567, 0.9983038306236267, 0.9980530142784119, 0.9977849721908569, 0.9974997043609619, 0.9971972107887268, 0.9968774914741516, 0.9965406060218811, 0.9961864948272705, 0.9958152174949646, 0.9954267740249634, 0.9950212240219116, 0.9945985078811646, 0.9941586256027222, 0.993701696395874, 0.9932277202606201, 0.9927366375923157, 0.9922285079956055, 0.9917033910751343, 0.9911612272262573, 0.9906020760536194, 0.9900259971618652, 0.9894329309463501, 0.9888229966163635, 0.9881961345672607, 0.9875524044036865, 0.9868918061256409, 0.9862143993377686, 0.9855201840400696, 0.984809160232544, 0.9840814471244812, 0.9833369851112366, 0.9825758337974548, 0.9817980527877808, 0.9810035824775696, 0.9801925420761108, 0.9793649315834045, 0.9785207509994507, 0.9776601195335388, 0.9767829775810242, 0.9758893847465515, 0.9749793410301208, 0.9740529656410217, 0.9731102585792542, 0.9721512198448181, 0.9711759686470032, 0.9701843857765198, 0.969176709651947, 0.9681528210639954, 0.9671127796173096, 0.9660567045211792, 0.9649845957756042, 0.9638964533805847, 0.9627923965454102, 0.9616723656654358, 0.9605364799499512, 0.9593847990036011, 0.9582172632217407, 0.9570340514183044, 0.9558351039886475, 0.9546204805374146, 0.9533902406692505, 0.9521445035934448, 0.950883150100708, 0.9496064186096191, 0.9483142495155334, 0.9470066428184509, 0.9456837773323059, 0.9443456530570984, 0.9429922699928284, 0.9416236877441406, 0.9402400255203247, 0.9388412833213806, 0.9374275207519531, 0.935998797416687, 0.934555172920227, 0.9330966472625732, 0.9316233992576599, 0.9301353693008423, 0.9286326169967651, 0.927115261554718, 0.9255833625793457, 0.9240369200706482, 0.9224759936332703, 0.9209007024765015, 0.9193111062049866, 0.9177071452140808, 0.9160889983177185, 0.9144567251205444, 0.9128103256225586, 0.9111498594284058, 0.9094754457473755, 0.9077871441841125, 0.9060849547386169, 0.9043689966201782, 0.9026393294334412, 0.9008960127830505, 0.8991391062736511, 0.8973686695098877, 0.8955848217010498, 0.8937875628471375, 0.8919769525527954, 0.8901531100273132, 0.8883160948753357, 0.8864659070968628, 0.8846027255058289, 0.8827266097068787, 0.8808375000953674, 0.8789356350898743, 0.8770209550857544, 0.8750936388969421, 0.8731536865234375, 0.8712011575698853, 0.869236171245575, 0.8672587871551514, 0.865269124507904, 0.863267183303833, 0.8612530827522278, 0.8592268824577332, 0.8571886420249939, 0.8551384806632996, 0.8530764579772949, 0.8510026335716248, 0.8489171266555786, 0.8468199372291565, 0.8447112441062927, 0.8425911068916321, 0.8404595255851746, 0.8383166193962097, 0.8361625075340271, 0.8339972496032715, 0.8318209052085876, 0.8296335935592651, 0.8274353742599487, 0.8252263069152832, 0.8230065107345581, 0.820776104927063, 0.8185350894927979, 0.8162835836410522, 0.8140217065811157, 0.8117494583129883, 0.8094670176506042, 0.8071744441986084, 0.8048717975616455, 0.8025591373443604, 0.8002366423606873, 0.7979043126106262, 0.7955623269081116, 0.7932106852531433, 0.790849506855011, 0.7884788513183594, 0.7860988974571228, 0.7837096452713013, 0.7813112735748291, 0.7789037823677063, 0.7764872908592224, 0.7740618586540222, 0.77162766456604, 0.7691847085952759, 0.7667331695556641, 0.7642730474472046, 0.7618045210838318, 0.7593276500701904, 0.7568424940109253, 0.7543491721153259, 0.7518478035926819, 0.7493384480476379, 0.7468212246894836, 0.7442961931228638, 0.7417634725570679, 0.7392231822013855, 0.7366753220558167, 0.7341201305389404, 0.7315576076507568, 0.7289878726005554, 0.726410984992981, 0.7238271236419678, 0.7212363481521606, 0.7186387181282043, 0.7160343527793884, 0.7134234309196472, 0.7108058929443359, 0.7081819772720337, 0.7055517435073853, 0.7029152512550354, 0.7002726197242737, 0.6976239085197449, 0.6949693560600281, 0.6923089027404785, 0.6896427273750305, 0.6869709491729736, 0.6842936277389526, 0.6816108226776123, 0.678922712802887, 0.6762294173240662, 0.6735309362411499, 0.6708274483680725, 0.6681190729141235, 0.665405809879303, 0.6626878976821899, 0.6599652767181396, 0.6572381854057312, 0.6545066833496094, 0.6517708897590637, 0.649030864238739, 0.6462867259979248, 0.6435385942459106, 0.6407865881919861, 0.6380307674407959, 0.6352712512016296, 0.6325081586837769, 0.6297415494918823, 0.6269716024398804, 0.6241983771324158, 0.6214219331741333, 0.6186424493789673, 0.6158600449562073, 0.6130747199058533, 0.6102867126464844, 0.6074960231781006, 0.6047027707099915, 0.6019071340560913, 0.5991091132164001, 0.5963088870048523, 0.5935065746307373, 0.5907022356987, 0.587895929813385, 0.5850878953933716, 0.5822781324386597, 0.5794667601585388, 0.5766538977622986, 0.5738397240638733, 0.5710241794586182, 0.5682075619697571, 0.5653898119926453, 0.562571108341217, 0.559751570224762, 0.5569313168525696, 0.5541104078292847, 0.5512889623641968, 0.5484670996665955, 0.5456448793411255, 0.5428224802017212, 0.5400000214576721, 0.5371775031089783, 0.534355103969574, 0.531532883644104, 0.5287110209465027, 0.5258895754814148, 0.5230686664581299, 0.5202484130859375, 0.5174288749694824, 0.5146101713180542, 0.5117924809455872, 0.5089758038520813, 0.506160318851471, 0.5033460855484009, 0.5005332231521606, 0.4977218806743622, 0.49491211771965027, 0.49210405349731445, 0.4892977774143219, 0.48649343848228455, 0.48369109630584717, 0.4808908700942993, 0.47809287905693054, 0.475297212600708, 0.47250398993492126, 0.4697133004665375, 0.4669252634048462, 0.4641399681568146, 0.4613575339317322, 0.45857805013656616, 0.45580166578292847, 0.4530284106731415, 0.4502584636211395, 0.447491854429245, 0.4447287619113922, 0.44196924567222595, 0.43921342492103577, 0.4364613890647888, 0.43371325731277466, 0.43096914887428284, 0.42822912335395813, 0.4254932999610901, 0.42276179790496826, 0.4200347065925598, 0.4173121452331543, 0.4145941734313965, 0.4118809401988983, 0.40917253494262695, 0.40646904706954956, 0.4037705957889557, 0.4010772705078125, 0.39838916063308716, 0.3957063853740692, 0.3930290639400482, 0.39035725593566895, 0.38769111037254333, 0.3850306570529938, 0.3823760747909546, 0.37972739338874817, 0.37708479166030884, 0.3744482696056366, 0.37181803584098816, 0.3691940903663635, 0.36657658219337463, 0.36396563053131104, 0.3613612651824951, 0.3587636649608612, 0.3561728596687317, 0.3535889983177185, 0.35101214051246643, 0.348442405462265, 0.3458798825740814, 0.3433246612548828, 0.34077683091163635, 0.338236540555954, 0.3357038199901581, 0.3331787884235382, 0.3306615352630615, 0.3281521797180176, 0.32565081119537354, 0.32315748929977417, 0.3206723630428314, 0.3181954622268677, 0.3157269358634949, 0.3132668435573578, 0.3108152747154236, 0.3083723485469818, 0.30593812465667725, 0.3035127520561218, 0.30109623074531555, 0.29868873953819275, 0.2962903380393982, 0.29390108585357666, 0.2915211319923401, 0.28915050625801086, 0.28678932785987854, 0.2844376862049103, 0.28209567070007324, 0.2797633707523346, 0.2774408459663391, 0.27512824535369873, 0.27282556891441345, 0.2705329954624176, 0.2682505249977112, 0.26597830653190613, 0.2637164294719696, 0.261464923620224, 0.25922390818595886, 0.25699347257614136, 0.25477367639541626, 0.2525646388530731, 0.2503664195537567, 0.248179093003273, 0.24600274860858917, 0.24383749067783356, 0.24168337881565094, 0.2395404875278473, 0.23740892112255096, 0.23528873920440674, 0.23318003118038177, 0.23108288645744324, 0.2289973497390747, 0.22692354023456573, 0.2248615175485611, 0.22281135618686676, 0.2207731306552887, 0.21874693036079407, 0.21673281490802765, 0.2147308737039566, 0.2127411961555481, 0.2107638269662857, 0.2087988406419754, 0.20684634149074554, 0.2049063742160797, 0.20297902822494507, 0.20106437802314758, 0.19916248321533203, 0.19727341830730438, 0.1953972578048706, 0.19353407621383667, 0.19168393313884735, 0.18984690308570862, 0.18802306056022644, 0.1862124651670456, 0.18441519141197205, 0.18263129889965057, 0.18086087703704834, 0.17910397052764893, 0.1773606389760971, 0.17563097178936005, 0.17391502857208252, 0.1722128540277481, 0.17052453756332397, 0.1688501238822937, 0.16718968749046326, 0.16554328799247742, 0.16391098499298096, 0.16229283809661865, 0.16068892180919647, 0.159099280834198, 0.157523974776268, 0.15596307814121246, 0.15441663563251495, 0.15288470685482025, 0.15136736631393433, 0.14986464381217957, 0.14837661385536194, 0.14690332114696503, 0.1454448401927948, 0.14400120079517365, 0.14257249236106873, 0.14115872979164124, 0.13975998759269714, 0.13837631046772003, 0.13700775802135468, 0.13565437495708466, 0.13431622087955475, 0.13299334049224854, 0.1316857784986496, 0.1303935945034027, 0.12911681830883026, 0.12785552442073822, 0.12660974264144897, 0.1253795325756073, 0.12416492402553558, 0.1229659765958786, 0.12178272753953934, 0.12061522156000137, 0.11946351081132889, 0.11832763254642487, 0.11720763146877289, 0.11610354483127594, 0.1150154173374176, 0.11394328624010086, 0.11288720369338989, 0.11184719949960709, 0.11082331091165543, 0.1098155826330185, 0.10882405191659927, 0.10784875601530075, 0.10688973218202591, 0.10594701021909714, 0.10502062737941742, 0.10411062836647034, 0.10321703553199768, 0.10233989357948303, 0.10147922486066818, 0.10063505917787552, 0.09980744868516922, 0.09899640083312988, 0.09820196032524109, 0.09742415696382523, 0.09666301310062408, 0.09591855853796005, 0.09519082307815552, 0.09447983652353287, 0.09378562122583389, 0.09310820698738098, 0.09244762361049652, 0.0918038859963417, 0.09117701649665833, 0.09056705236434937, 0.08997400850057602, 0.08939790725708008, 0.08883877098560333, 0.08829662203788757, 0.087771475315094, 0.08726336061954498, 0.08677228540182114, 0.08629827201366425, 0.0858413502573967, 0.0854015201330185, 0.08497880399227142, 0.08457322418689728, 0.08418478816747665, 0.08381351083517075, 0.08345941454172134, 0.08312250673770905, 0.08280279487371445, 0.08250029385089874, 0.08221502602100372, 0.08194699138402939, 0.08169619739055634, 0.08146265894174576, 0.08124639093875885, 0.08104738593101501, 0.08086566627025604, 0.08070123195648193, 0.08055409044027328, 0.0804242417216301, 0.08031170070171356, 0.08021646738052368, 0.08013854175806046, 0.08007793128490448, 0.08003463596105576, 0.08000865578651428 ] ================================================ FILE: __tests__/data/hamming128.json ================================================ [ 0.07999999821186066, 0.08055409044027328, 0.08221502602100372, 0.08497880399227142, 0.08883877098560333, 0.09378562122583389, 0.09980744868516922, 0.10688973218202591, 0.1150154173374176, 0.12416492402553558, 0.13431622087955475, 0.1454448401927948, 0.157523974776268, 0.17052453756332397, 0.18441519141197205, 0.19916248321533203, 0.2147308737039566, 0.23108288645744324, 0.248179093003273, 0.26597830653190613, 0.2844376862049103, 0.3035127520561218, 0.32315748929977417, 0.3433246612548828, 0.36396563053131104, 0.3850306570529938, 0.40646904706954956, 0.42822912335395813, 0.4502584636211395, 0.47250398993492126, 0.49491211771965027, 0.5174288749694824, 0.5400000214576721, 0.562571108341217, 0.5850878953933716, 0.6074960231781006, 0.6297415494918823, 0.6517708897590637, 0.6735309362411499, 0.6949693560600281, 0.7160343527793884, 0.7366753220558167, 0.7568424940109253, 0.7764872908592224, 0.7955623269081116, 0.8140217065811157, 0.8318209052085876, 0.8489171266555786, 0.865269124507904, 0.8808375000953674, 0.8955848217010498, 0.9094754457473755, 0.9224759936332703, 0.934555172920227, 0.9456837773323059, 0.9558351039886475, 0.9649845957756042, 0.9731102585792542, 0.9801925420761108, 0.9862143993377686, 0.9911612272262573, 0.9950212240219116, 0.9977849721908569, 0.999445915222168, 1, 0.999445915222168, 0.9977849721908569, 0.9950212240219116, 0.9911612272262573, 0.9862143993377686, 0.9801925420761108, 0.9731102585792542, 0.9649845957756042, 0.9558351039886475, 0.9456837773323059, 0.934555172920227, 0.9224759936332703, 0.9094754457473755, 0.8955848217010498, 0.8808375000953674, 0.865269124507904, 0.8489171266555786, 0.8318209052085876, 0.8140217065811157, 0.7955623269081116, 0.7764872908592224, 0.7568424940109253, 0.7366753220558167, 0.7160343527793884, 0.6949693560600281, 0.6735309362411499, 0.6517708897590637, 0.6297415494918823, 0.6074960231781006, 0.5850878953933716, 0.562571108341217, 0.5400000214576721, 0.5174288749694824, 0.49491211771965027, 0.47250398993492126, 0.4502584636211395, 0.42822912335395813, 0.40646904706954956, 0.3850306570529938, 0.36396563053131104, 0.3433246612548828, 0.32315748929977417, 0.3035127520561218, 0.2844376862049103, 0.26597830653190613, 0.248179093003273, 0.23108288645744324, 0.2147308737039566, 0.19916248321533203, 0.18441519141197205, 0.17052453756332397, 0.157523974776268, 0.1454448401927948, 0.13431622087955475, 0.12416492402553558, 0.1150154173374176, 0.10688973218202591, 0.09980744868516922, 0.09378562122583389, 0.08883877098560333, 0.08497880399227142, 0.08221502602100372, 0.08055409044027328 ] ================================================ FILE: __tests__/data/hamming2048.json ================================================ [ 0.07999999821186066, 0.08000216633081436, 0.08000865578651428, 0.08001948148012161, 0.08003463596105576, 0.08005411922931671, 0.08007793128490448, 0.08010607212781906, 0.08013854175806046, 0.08017534017562866, 0.08021646738052368, 0.08026192337274551, 0.08031170070171356, 0.08036581426858902, 0.0804242417216301, 0.08048700541257858, 0.08055409044027328, 0.0806254968047142, 0.08070123195648193, 0.08078128844499588, 0.08086566627025604, 0.08095436543226242, 0.08104738593101501, 0.08114472776651382, 0.08124639093875885, 0.0813523679971695, 0.08146265894174576, 0.08157727122306824, 0.08169619739055634, 0.08181943744421005, 0.08194699138402939, 0.08207885175943375, 0.08221502602100372, 0.08235550671815872, 0.08250029385089874, 0.08264939486980438, 0.08280279487371445, 0.08296050131320953, 0.08312250673770905, 0.08328881114721298, 0.08345941454172134, 0.08363431692123413, 0.08381351083517075, 0.08399700373411179, 0.08418478816747665, 0.08437686413526535, 0.08457322418689728, 0.08477386832237244, 0.08497880399227142, 0.08518802374601364, 0.0854015201330185, 0.08561929315328598, 0.0858413502573967, 0.08606767654418945, 0.08629827201366425, 0.08653314411640167, 0.08677228540182114, 0.08701568841934204, 0.08726336061954498, 0.08751528710126877, 0.087771475315094, 0.08803191781044006, 0.08829662203788757, 0.08856557309627533, 0.08883877098560333, 0.08911621570587158, 0.08939790725708008, 0.08968383818864822, 0.08997400850057602, 0.09026841819286346, 0.09056705236434937, 0.09086992591619492, 0.09117701649665833, 0.09148833900690079, 0.0918038859963417, 0.09212364256381989, 0.09244762361049652, 0.09277581423521042, 0.09310820698738098, 0.0934448167681694, 0.09378562122583389, 0.09413063526153564, 0.09447983652353287, 0.09483323246240616, 0.09519082307815552, 0.09555260092020035, 0.09591855853796005, 0.09628869593143463, 0.09666301310062408, 0.09704149514436722, 0.09742415696382523, 0.09781097620725632, 0.09820196032524109, 0.09859710186719894, 0.09899640083312988, 0.09939984977245331, 0.09980744868516922, 0.10021918267011642, 0.10063505917787552, 0.1010550782084465, 0.10147922486066818, 0.10190749168395996, 0.10233989357948303, 0.1027764081954956, 0.10321703553199768, 0.10366177558898926, 0.10411062836647034, 0.10456357896327972, 0.10502062737941742, 0.10548177361488342, 0.10594701021909714, 0.10641632974147797, 0.10688973218202591, 0.10736721009016037, 0.10784875601530075, 0.10833437740802765, 0.10882405191659927, 0.10931779444217682, 0.1098155826330185, 0.1103174239397049, 0.11082331091165543, 0.11133323609828949, 0.11184719949960709, 0.11236518621444702, 0.11288720369338989, 0.1134132370352745, 0.11394328624010086, 0.11447735130786896, 0.1150154173374176, 0.1155574843287468, 0.11610354483127594, 0.11665359139442444, 0.11720763146877289, 0.1177656427025795, 0.11832763254642487, 0.1188935935497284, 0.11946351081132889, 0.12003739178180695, 0.12061522156000137, 0.12119700759649277, 0.12178272753953934, 0.12237238883972168, 0.1229659765958786, 0.1235634908080101, 0.12416492402553558, 0.12477027624845505, 0.1253795325756073, 0.12599268555641174, 0.12660974264144897, 0.1272306889295578, 0.12785552442073822, 0.12848423421382904, 0.12911681830883026, 0.12975327670574188, 0.1303935945034027, 0.13103775680065155, 0.1316857784986496, 0.13233762979507446, 0.13299334049224854, 0.13365286588668823, 0.13431622087955475, 0.1349833905696869, 0.13565437495708466, 0.13632915914058685, 0.13700775802135468, 0.13769014179706573, 0.13837631046772003, 0.13906626403331757, 0.13975998759269714, 0.14045748114585876, 0.14115872979164124, 0.14186373353004456, 0.14257249236106873, 0.14328497648239136, 0.14400120079517365, 0.1447211652994156, 0.1454448401927948, 0.14617222547531128, 0.14690332114696503, 0.14763812720775604, 0.14837661385536194, 0.14911878108978271, 0.14986464381217957, 0.1506141722202301, 0.15136736631393433, 0.15212421119213104, 0.15288470685482025, 0.15364885330200195, 0.15441663563251495, 0.15518803894519806, 0.15596307814121246, 0.15674172341823578, 0.157523974776268, 0.15830983221530914, 0.159099280834198, 0.15989230573177338, 0.16068892180919647, 0.1614890992641449, 0.16229283809661865, 0.16310013830661774, 0.16391098499298096, 0.1647253781557083, 0.16554328799247742, 0.16636472940444946, 0.16718968749046326, 0.1680181622505188, 0.1688501238822937, 0.16968558728694916, 0.17052453756332397, 0.17136695981025696, 0.1722128540277481, 0.17306222021579742, 0.17391502857208252, 0.1747712790966034, 0.17563097178936005, 0.17649409174919128, 0.1773606389760971, 0.17823059856891632, 0.17910397052764893, 0.17998072504997253, 0.18086087703704834, 0.18174441158771515, 0.18263129889965057, 0.183521568775177, 0.18441519141197205, 0.1853121519088745, 0.1862124651670456, 0.1871161013841629, 0.18802306056022644, 0.188933327794075, 0.18984690308570862, 0.19076377153396606, 0.19168393313884735, 0.19260737299919128, 0.19353407621383667, 0.1944640427827835, 0.1953972578048706, 0.19633372128009796, 0.19727341830730438, 0.19821634888648987, 0.19916248321533203, 0.20011183619499207, 0.20106437802314758, 0.20202010869979858, 0.20297902822494507, 0.20394112169742584, 0.2049063742160797, 0.20587478578090668, 0.20684634149074554, 0.20782102644443512, 0.2087988406419754, 0.2097797840833664, 0.2107638269662857, 0.21175095438957214, 0.2127411961555481, 0.2137344926595688, 0.2147308737039566, 0.21573032438755035, 0.21673281490802765, 0.21773836016654968, 0.21874693036079407, 0.2197585254907608, 0.2207731306552887, 0.22179074585437775, 0.22281135618686676, 0.22383494675159454, 0.2248615175485611, 0.22589105367660522, 0.22692354023456573, 0.22795897722244263, 0.2289973497390747, 0.23003865778446198, 0.23108288645744324, 0.2321300059556961, 0.23318003118038177, 0.23423294723033905, 0.23528873920440674, 0.23634740710258484, 0.23740892112255096, 0.23847328126430511, 0.2395404875278473, 0.2406105250120163, 0.24168337881565094, 0.24275903403759003, 0.24383749067783356, 0.24491873383522034, 0.24600274860858917, 0.24708954989910126, 0.248179093003273, 0.24927137792110443, 0.2503664195537567, 0.2514641582965851, 0.2525646388530731, 0.25366780161857605, 0.25477367639541626, 0.25588223338127136, 0.25699347257614136, 0.25810736417770386, 0.25922390818595886, 0.26034310460090637, 0.261464923620224, 0.26258936524391174, 0.2637164294719696, 0.2648460865020752, 0.26597830653190613, 0.2671131491661072, 0.2682505249977112, 0.2693904936313629, 0.2705329954624176, 0.27167803049087524, 0.27282556891441345, 0.2739756405353546, 0.27512824535369873, 0.27628329396247864, 0.2774408459663391, 0.27860087156295776, 0.2797633707523346, 0.2809283137321472, 0.28209567070007324, 0.28326547145843506, 0.2844376862049103, 0.2856123149394989, 0.28678932785987854, 0.2879687249660492, 0.28915050625801086, 0.29033464193344116, 0.2915211319923401, 0.29270994663238525, 0.29390108585357666, 0.2950945496559143, 0.2962903380393982, 0.29748839139938354, 0.29868873953819275, 0.2998913526535034, 0.30109623074531555, 0.30230337381362915, 0.3035127520561218, 0.3047243356704712, 0.30593812465667725, 0.3071541488170624, 0.3083723485469818, 0.30959272384643555, 0.3108152747154236, 0.31203997135162354, 0.3132668435573578, 0.31449583172798157, 0.3157269358634949, 0.3169601559638977, 0.3181954622268677, 0.3194328844547272, 0.3206723630428314, 0.3219138979911804, 0.32315748929977417, 0.32440313696861267, 0.32565081119537354, 0.32690051198005676, 0.3281521797180176, 0.32940587401390076, 0.3306615352630615, 0.33191919326782227, 0.3331787884235382, 0.33444032073020935, 0.3357038199901581, 0.3369692265987396, 0.338236540555954, 0.33950573205947876, 0.34077683091163635, 0.34204980731010437, 0.3433246612548828, 0.3446013331413269, 0.3458798825740814, 0.3471602201461792, 0.348442405462265, 0.3497263789176941, 0.35101214051246643, 0.35229969024658203, 0.3535889983177185, 0.35488006472587585, 0.3561728596687317, 0.3574674129486084, 0.3587636649608612, 0.3600616157054901, 0.3613612651824951, 0.3626626133918762, 0.36396563053131104, 0.3652702867984772, 0.36657658219337463, 0.3678845167160034, 0.3691940903663635, 0.3705052435398102, 0.37181803584098816, 0.3731323778629303, 0.3744482696056366, 0.37576577067375183, 0.37708479166030884, 0.3784053325653076, 0.37972739338874817, 0.3810510039329529, 0.3823760747909546, 0.3837026357650757, 0.3850306570529938, 0.38636016845703125, 0.38769111037254333, 0.38902348279953003, 0.39035725593566895, 0.39169245958328247, 0.3930290639400482, 0.3943670392036438, 0.3957063853740692, 0.39704710245132446, 0.39838916063308716, 0.3997325599193573, 0.4010772705078125, 0.40242329239845276, 0.4037705957889557, 0.4051191806793213, 0.40646904706954956, 0.4078201651573181, 0.40917253494262695, 0.4105261266231537, 0.4118809401988983, 0.41323697566986084, 0.4145941734313965, 0.41595256328582764, 0.4173121452331543, 0.4186728596687317, 0.4200347065925598, 0.42139768600463867, 0.42276179790496826, 0.4241270124912262, 0.4254932999610901, 0.4268606901168823, 0.42822912335395813, 0.4295985996723175, 0.43096914887428284, 0.43234071135520935, 0.43371325731277466, 0.43508684635162354, 0.4364613890647888, 0.4378369450569153, 0.43921342492103577, 0.44059085845947266, 0.44196924567222595, 0.44334855675697327, 0.4447287619113922, 0.4461098611354828, 0.447491854429245, 0.44887474179267883, 0.4502584636211395, 0.4516430199146271, 0.4530284106731415, 0.45441463589668274, 0.45580166578292847, 0.4571894705295563, 0.45857805013656616, 0.45996740460395813, 0.4613575339317322, 0.46274837851524353, 0.4641399681568146, 0.4655322730541229, 0.4669252634048462, 0.4683189392089844, 0.4697133004665375, 0.4711083173751831, 0.47250398993492126, 0.47390028834342957, 0.475297212600708, 0.4766947329044342, 0.47809287905693054, 0.47949159145355225, 0.4808908700942993, 0.48229071497917175, 0.48369109630584717, 0.48509201407432556, 0.48649343848228455, 0.4878953695297241, 0.4892977774143219, 0.49070069193840027, 0.49210405349731445, 0.49350786209106445, 0.49491211771965027, 0.4963167905807495, 0.4977218806743622, 0.4991273581981659, 0.5005332231521606, 0.5019394755363464, 0.5033460855484009, 0.504753053188324, 0.506160318851471, 0.5075678825378418, 0.5089758038520813, 0.5103839635848999, 0.5117924809455872, 0.5132011771202087, 0.5146101713180542, 0.5160194039344788, 0.5174288749694824, 0.5188385248184204, 0.5202484130859375, 0.5216584801673889, 0.5230686664581299, 0.5244790315628052, 0.5258895754814148, 0.527300238609314, 0.5287110209465027, 0.530121922492981, 0.531532883644104, 0.5329439640045166, 0.534355103969574, 0.5357662439346313, 0.5371775031089783, 0.5385887622833252, 0.5400000214576721, 0.541411280632019, 0.5428224802017212, 0.5442337393760681, 0.5456448793411255, 0.5470560193061829, 0.5484670996665955, 0.5498780608177185, 0.5512889623641968, 0.5526997447013855, 0.5541104078292847, 0.5555209517478943, 0.5569313168525696, 0.5583415627479553, 0.559751570224762, 0.561161458492279, 0.562571108341217, 0.5639805793762207, 0.5653898119926453, 0.5667988061904907, 0.5682075619697571, 0.5696160197257996, 0.5710241794586182, 0.5724321007728577, 0.5738397240638733, 0.5752469897270203, 0.5766538977622986, 0.578060507774353, 0.5794667601585388, 0.580872654914856, 0.5822781324386597, 0.58368319272995, 0.5850878953933716, 0.586492121219635, 0.587895929813385, 0.5892993211746216, 0.5907022356987, 0.5921046137809753, 0.5935065746307373, 0.5949079990386963, 0.5963088870048523, 0.5977092981338501, 0.5991091132164001, 0.6005083918571472, 0.6019071340560913, 0.6033052802085876, 0.6047027707099915, 0.6060997247695923, 0.6074960231781006, 0.6088916659355164, 0.6102867126464844, 0.6116810441017151, 0.6130747199058533, 0.6144677400588989, 0.6158600449562073, 0.6172516345977783, 0.6186424493789673, 0.6200326085090637, 0.6214219331741333, 0.6228105425834656, 0.6241983771324158, 0.6255853772163391, 0.6269716024398804, 0.6283569931983948, 0.6297415494918823, 0.631125271320343, 0.6325081586837769, 0.6338901519775391, 0.6352712512016296, 0.6366514563560486, 0.6380307674407959, 0.6394091248512268, 0.6407865881919861, 0.6421630382537842, 0.6435385942459106, 0.6449131369590759, 0.6462867259979248, 0.6476593017578125, 0.649030864238739, 0.6504014134407043, 0.6517708897590637, 0.6531393527984619, 0.6545066833496094, 0.6558730006217957, 0.6572381854057312, 0.6586022973060608, 0.6599652767181396, 0.6613271236419678, 0.6626878976821899, 0.6640474200248718, 0.665405809879303, 0.6667630076408386, 0.6681190729141235, 0.6694738864898682, 0.6708274483680725, 0.6721798181533813, 0.6735309362411499, 0.6748808026313782, 0.6762294173240662, 0.6775767207145691, 0.678922712802887, 0.6802674531936646, 0.6816108226776123, 0.682952880859375, 0.6842936277389526, 0.6856329441070557, 0.6869709491729736, 0.688307523727417, 0.6896427273750305, 0.6909765005111694, 0.6923089027404785, 0.6936398148536682, 0.6949693560600281, 0.6962973475456238, 0.6976239085197449, 0.6989490389823914, 0.7002726197242737, 0.7015946507453918, 0.7029152512550354, 0.70423424243927, 0.7055517435073853, 0.7068676352500916, 0.7081819772720337, 0.7094947695732117, 0.7108058929443359, 0.712115466594696, 0.7134234309196472, 0.7147297263145447, 0.7160343527793884, 0.7173373699188232, 0.7186387181282043, 0.7199383974075317, 0.7212363481521606, 0.7225325703620911, 0.7238271236419678, 0.725119948387146, 0.726410984992981, 0.7277002930641174, 0.7289878726005554, 0.7302736043930054, 0.7315576076507568, 0.7328397631645203, 0.7341201305389404, 0.7353986501693726, 0.7366753220558167, 0.7379502058029175, 0.7392231822013855, 0.7404942512512207, 0.7417634725570679, 0.7430307865142822, 0.7442961931228638, 0.7455596923828125, 0.7468212246894836, 0.7480807900428772, 0.7493384480476379, 0.7505941390991211, 0.7518478035926819, 0.7530995011329651, 0.7543491721153259, 0.7555968761444092, 0.7568424940109253, 0.758086085319519, 0.7593276500701904, 0.7605671286582947, 0.7618045210838318, 0.7630398273468018, 0.7642730474472046, 0.7655041813850403, 0.7667331695556641, 0.7679600119590759, 0.7691847085952759, 0.7704072594642639, 0.77162766456604, 0.7728458642959595, 0.7740618586540222, 0.7752756476402283, 0.7764872908592224, 0.7776966094970703, 0.7789037823677063, 0.780108630657196, 0.7813112735748291, 0.7825115919113159, 0.7837096452713013, 0.7849054336547852, 0.7860988974571228, 0.7872900366783142, 0.7884788513183594, 0.7896653413772583, 0.790849506855011, 0.7920312881469727, 0.7932106852531433, 0.794387698173523, 0.7955623269081116, 0.7967345118522644, 0.7979043126106262, 0.7990716695785522, 0.8002366423606873, 0.8013991117477417, 0.8025591373443604, 0.8037167191505432, 0.8048717975616455, 0.8060243725776672, 0.8071744441986084, 0.8083219528198242, 0.8094670176506042, 0.8106095194816589, 0.8117494583129883, 0.8128868341445923, 0.8140217065811157, 0.8151538968086243, 0.8162835836410522, 0.8174106478691101, 0.8185350894927979, 0.8196569085121155, 0.820776104927063, 0.8218926191329956, 0.8230065107345581, 0.8241177797317505, 0.8252263069152832, 0.8263322114944458, 0.8274353742599487, 0.8285358548164368, 0.8296335935592651, 0.8307285904884338, 0.8318209052085876, 0.8329104781150818, 0.8339972496032715, 0.8350812792778015, 0.8361625075340271, 0.837240993976593, 0.8383166193962097, 0.8393895030021667, 0.8404595255851746, 0.8415266871452332, 0.8425911068916321, 0.843652606010437, 0.8447112441062927, 0.8457670211791992, 0.8468199372291565, 0.8478699922561646, 0.8489171266555786, 0.8499613404273987, 0.8510026335716248, 0.8520410060882568, 0.8530764579772949, 0.8541089296340942, 0.8551384806632996, 0.8561650514602661, 0.8571886420249939, 0.8582092523574829, 0.8592268824577332, 0.8602414727210999, 0.8612530827522278, 0.8622616529464722, 0.863267183303833, 0.8642696738243103, 0.865269124507904, 0.8662654757499695, 0.8672587871551514, 0.8682490587234497, 0.869236171245575, 0.8702202439308167, 0.8712011575698853, 0.8721789717674255, 0.8731536865234375, 0.8741251826286316, 0.8750936388969421, 0.8760588765144348, 0.8770209550857544, 0.8779798746109009, 0.8789356350898743, 0.8798881769180298, 0.8808375000953674, 0.881783664226532, 0.8827266097068787, 0.8836662769317627, 0.8846027255058289, 0.8855359554290771, 0.8864659070968628, 0.8873926401138306, 0.8883160948753357, 0.8892362117767334, 0.8901531100273132, 0.8910666704177856, 0.8919769525527954, 0.8928838968276978, 0.8937875628471375, 0.894687831401825, 0.8955848217010498, 0.8964784145355225, 0.8973686695098877, 0.8982555866241455, 0.8991391062736511, 0.9000192880630493, 0.9008960127830505, 0.9017693996429443, 0.9026393294334412, 0.9035059213638306, 0.9043689966201782, 0.9052287340164185, 0.9060849547386169, 0.9069377779960632, 0.9077871441841125, 0.9086330533027649, 0.9094754457473755, 0.9103144407272339, 0.9111498594284058, 0.9119818210601807, 0.9128103256225586, 0.91363525390625, 0.9144567251205444, 0.9152746200561523, 0.9160889983177185, 0.9168998599052429, 0.9177071452140808, 0.918510913848877, 0.9193111062049866, 0.9201076626777649, 0.9209007024765015, 0.9216901659965515, 0.9224759936332703, 0.9232583045959473, 0.9240369200706482, 0.9248119592666626, 0.9255833625793457, 0.9263511300086975, 0.927115261554718, 0.927875816822052, 0.9286326169967651, 0.9293858408927917, 0.9301353693008423, 0.9308812022209167, 0.9316233992576599, 0.932361900806427, 0.9330966472625732, 0.9338277578353882, 0.934555172920227, 0.9352788329124451, 0.935998797416687, 0.9367150068283081, 0.9374275207519531, 0.9381362795829773, 0.9388412833213806, 0.9395425319671631, 0.9402400255203247, 0.9409337639808655, 0.9416236877441406, 0.9423098564147949, 0.9429922699928284, 0.9436708092689514, 0.9443456530570984, 0.945016622543335, 0.9456837773323059, 0.9463471174240112, 0.9470066428184509, 0.947662353515625, 0.9483142495155334, 0.9489622712135315, 0.9496064186096191, 0.9502467513084412, 0.950883150100708, 0.9515157341957092, 0.9521445035934448, 0.9527692794799805, 0.9533902406692505, 0.9540073275566101, 0.9546204805374146, 0.9552296996116638, 0.9558351039886475, 0.9564365148544312, 0.9570340514183044, 0.9576275944709778, 0.9582172632217407, 0.9588029980659485, 0.9593847990036011, 0.9599626064300537, 0.9605364799499512, 0.9611064195632935, 0.9616723656654358, 0.962234377861023, 0.9627923965454102, 0.9633464217185974, 0.9638964533805847, 0.9644424915313721, 0.9649845957756042, 0.9655226469039917, 0.9660567045211792, 0.9665867686271667, 0.9671127796173096, 0.9676347970962524, 0.9681528210639954, 0.9686667919158936, 0.969176709651947, 0.9696825742721558, 0.9701843857765198, 0.9706822037696838, 0.9711759686470032, 0.971665620803833, 0.9721512198448181, 0.9726327657699585, 0.9731102585792542, 0.9735836982727051, 0.9740529656410217, 0.9745182394981384, 0.9749793410301208, 0.9754364490509033, 0.9758893847465515, 0.9763382077217102, 0.9767829775810242, 0.9772235751152039, 0.9776601195335388, 0.9780924916267395, 0.9785207509994507, 0.9789448976516724, 0.9793649315834045, 0.9797807931900024, 0.9801925420761108, 0.9806001782417297, 0.9810035824775696, 0.9814028739929199, 0.9817980527877808, 0.9821889996528625, 0.9825758337974548, 0.9829584956169128, 0.9833369851112366, 0.983711302280426, 0.9840814471244812, 0.9844474196434021, 0.984809160232544, 0.9851667881011963, 0.9855201840400696, 0.9858693480491638, 0.9862143993377686, 0.9865551590919495, 0.9868918061256409, 0.9872241616249084, 0.9875524044036865, 0.9878763556480408, 0.9881961345672607, 0.9885116815567017, 0.9888229966163635, 0.9891300797462463, 0.9894329309463501, 0.9897316098213196, 0.9900259971618652, 0.9903161525726318, 0.9906020760536194, 0.9908837676048279, 0.9911612272262573, 0.9914344549179077, 0.9917033910751343, 0.9919680953025818, 0.9922285079956055, 0.9924846887588501, 0.9927366375923157, 0.9929842948913574, 0.9932277202606201, 0.993466854095459, 0.993701696395874, 0.99393230676651, 0.9941586256027222, 0.9943807125091553, 0.9945985078811646, 0.9948119521141052, 0.9950212240219116, 0.9952261447906494, 0.9954267740249634, 0.9956231117248535, 0.9958152174949646, 0.9960029721260071, 0.9961864948272705, 0.9963656663894653, 0.9965406060218811, 0.9967111945152283, 0.9968774914741516, 0.9970394968986511, 0.9971972107887268, 0.9973506331443787, 0.9974997043609619, 0.9976444840431213, 0.9977849721908569, 0.9979211688041687, 0.9980530142784119, 0.9981805682182312, 0.9983038306236267, 0.9984227418899536, 0.9985373616218567, 0.9986476302146912, 0.9987536072731018, 0.9988552927970886, 0.9989526271820068, 0.9990456104278564, 0.9991343021392822, 0.9992187023162842, 0.9992987513542175, 0.999374508857727, 0.999445915222168, 0.9995129704475403, 0.9995757341384888, 0.9996342062950134, 0.9996882677078247, 0.9997380971908569, 0.9997835159301758, 0.9998246431350708, 0.999861478805542, 0.9998939037322998, 0.9999220967292786, 0.999945878982544, 0.9999653697013855, 0.9999805092811584, 0.9999913573265076, 0.9999978542327881, 1, 0.9999978542327881, 0.9999913573265076, 0.9999805092811584, 0.9999653697013855, 0.999945878982544, 0.9999220967292786, 0.9998939037322998, 0.999861478805542, 0.9998246431350708, 0.9997835159301758, 0.9997380971908569, 0.9996882677078247, 0.9996342062950134, 0.9995757341384888, 0.9995129704475403, 0.999445915222168, 0.999374508857727, 0.9992987513542175, 0.9992187023162842, 0.9991343021392822, 0.9990456104278564, 0.9989526271820068, 0.9988552927970886, 0.9987536072731018, 0.9986476302146912, 0.9985373616218567, 0.9984227418899536, 0.9983038306236267, 0.9981805682182312, 0.9980530142784119, 0.9979211688041687, 0.9977849721908569, 0.9976444840431213, 0.9974997043609619, 0.9973506331443787, 0.9971972107887268, 0.9970394968986511, 0.9968774914741516, 0.9967111945152283, 0.9965406060218811, 0.9963656663894653, 0.9961864948272705, 0.9960029721260071, 0.9958152174949646, 0.9956231117248535, 0.9954267740249634, 0.9952261447906494, 0.9950212240219116, 0.9948119521141052, 0.9945985078811646, 0.9943807125091553, 0.9941586256027222, 0.99393230676651, 0.993701696395874, 0.993466854095459, 0.9932277202606201, 0.9929842948913574, 0.9927366375923157, 0.9924846887588501, 0.9922285079956055, 0.9919680953025818, 0.9917033910751343, 0.9914344549179077, 0.9911612272262573, 0.9908837676048279, 0.9906020760536194, 0.9903161525726318, 0.9900259971618652, 0.9897316098213196, 0.9894329309463501, 0.9891300797462463, 0.9888229966163635, 0.9885116815567017, 0.9881961345672607, 0.9878763556480408, 0.9875524044036865, 0.9872241616249084, 0.9868918061256409, 0.9865551590919495, 0.9862143993377686, 0.9858693480491638, 0.9855201840400696, 0.9851667881011963, 0.984809160232544, 0.9844474196434021, 0.9840814471244812, 0.983711302280426, 0.9833369851112366, 0.9829584956169128, 0.9825758337974548, 0.9821889996528625, 0.9817980527877808, 0.9814028739929199, 0.9810035824775696, 0.9806001782417297, 0.9801925420761108, 0.9797807931900024, 0.9793649315834045, 0.9789448976516724, 0.9785207509994507, 0.9780924916267395, 0.9776601195335388, 0.9772235751152039, 0.9767829775810242, 0.9763382077217102, 0.9758893847465515, 0.9754364490509033, 0.9749793410301208, 0.9745182394981384, 0.9740529656410217, 0.9735836982727051, 0.9731102585792542, 0.9726327657699585, 0.9721512198448181, 0.971665620803833, 0.9711759686470032, 0.9706822037696838, 0.9701843857765198, 0.9696825742721558, 0.969176709651947, 0.9686667919158936, 0.9681528210639954, 0.9676347970962524, 0.9671127796173096, 0.9665867686271667, 0.9660567045211792, 0.9655226469039917, 0.9649845957756042, 0.9644424915313721, 0.9638964533805847, 0.9633464217185974, 0.9627923965454102, 0.962234377861023, 0.9616723656654358, 0.9611064195632935, 0.9605364799499512, 0.9599626064300537, 0.9593847990036011, 0.9588029980659485, 0.9582172632217407, 0.9576275944709778, 0.9570340514183044, 0.9564365148544312, 0.9558351039886475, 0.9552296996116638, 0.9546204805374146, 0.9540073275566101, 0.9533902406692505, 0.9527692794799805, 0.9521445035934448, 0.9515157341957092, 0.950883150100708, 0.9502467513084412, 0.9496064186096191, 0.9489622712135315, 0.9483142495155334, 0.947662353515625, 0.9470066428184509, 0.9463471174240112, 0.9456837773323059, 0.945016622543335, 0.9443456530570984, 0.9436708092689514, 0.9429922699928284, 0.9423098564147949, 0.9416236877441406, 0.9409337639808655, 0.9402400255203247, 0.9395425319671631, 0.9388412833213806, 0.9381362795829773, 0.9374275207519531, 0.9367150068283081, 0.935998797416687, 0.9352788329124451, 0.934555172920227, 0.9338277578353882, 0.9330966472625732, 0.932361900806427, 0.9316233992576599, 0.9308812022209167, 0.9301353693008423, 0.9293858408927917, 0.9286326169967651, 0.927875816822052, 0.927115261554718, 0.9263511300086975, 0.9255833625793457, 0.9248119592666626, 0.9240369200706482, 0.9232583045959473, 0.9224759936332703, 0.9216901659965515, 0.9209007024765015, 0.9201076626777649, 0.9193111062049866, 0.918510913848877, 0.9177071452140808, 0.9168998599052429, 0.9160889983177185, 0.9152746200561523, 0.9144567251205444, 0.91363525390625, 0.9128103256225586, 0.9119818210601807, 0.9111498594284058, 0.9103144407272339, 0.9094754457473755, 0.9086330533027649, 0.9077871441841125, 0.9069377779960632, 0.9060849547386169, 0.9052287340164185, 0.9043689966201782, 0.9035059213638306, 0.9026393294334412, 0.9017693996429443, 0.9008960127830505, 0.9000192880630493, 0.8991391062736511, 0.8982555866241455, 0.8973686695098877, 0.8964784145355225, 0.8955848217010498, 0.894687831401825, 0.8937875628471375, 0.8928838968276978, 0.8919769525527954, 0.8910666704177856, 0.8901531100273132, 0.8892362117767334, 0.8883160948753357, 0.8873926401138306, 0.8864659070968628, 0.8855359554290771, 0.8846027255058289, 0.8836662769317627, 0.8827266097068787, 0.881783664226532, 0.8808375000953674, 0.8798881769180298, 0.8789356350898743, 0.8779798746109009, 0.8770209550857544, 0.8760588765144348, 0.8750936388969421, 0.8741251826286316, 0.8731536865234375, 0.8721789717674255, 0.8712011575698853, 0.8702202439308167, 0.869236171245575, 0.8682490587234497, 0.8672587871551514, 0.8662654757499695, 0.865269124507904, 0.8642696738243103, 0.863267183303833, 0.8622616529464722, 0.8612530827522278, 0.8602414727210999, 0.8592268824577332, 0.8582092523574829, 0.8571886420249939, 0.8561650514602661, 0.8551384806632996, 0.8541089296340942, 0.8530764579772949, 0.8520410060882568, 0.8510026335716248, 0.8499613404273987, 0.8489171266555786, 0.8478699922561646, 0.8468199372291565, 0.8457670211791992, 0.8447112441062927, 0.843652606010437, 0.8425911068916321, 0.8415266871452332, 0.8404595255851746, 0.8393895030021667, 0.8383166193962097, 0.837240993976593, 0.8361625075340271, 0.8350812792778015, 0.8339972496032715, 0.8329104781150818, 0.8318209052085876, 0.8307285904884338, 0.8296335935592651, 0.8285358548164368, 0.8274353742599487, 0.8263322114944458, 0.8252263069152832, 0.8241177797317505, 0.8230065107345581, 0.8218926191329956, 0.820776104927063, 0.8196569085121155, 0.8185350894927979, 0.8174106478691101, 0.8162835836410522, 0.8151538968086243, 0.8140217065811157, 0.8128868341445923, 0.8117494583129883, 0.8106095194816589, 0.8094670176506042, 0.8083219528198242, 0.8071744441986084, 0.8060243725776672, 0.8048717975616455, 0.8037167191505432, 0.8025591373443604, 0.8013991117477417, 0.8002366423606873, 0.7990716695785522, 0.7979043126106262, 0.7967345118522644, 0.7955623269081116, 0.794387698173523, 0.7932106852531433, 0.7920312881469727, 0.790849506855011, 0.7896653413772583, 0.7884788513183594, 0.7872900366783142, 0.7860988974571228, 0.7849054336547852, 0.7837096452713013, 0.7825115919113159, 0.7813112735748291, 0.780108630657196, 0.7789037823677063, 0.7776966094970703, 0.7764872908592224, 0.7752756476402283, 0.7740618586540222, 0.7728458642959595, 0.77162766456604, 0.7704072594642639, 0.7691847085952759, 0.7679600119590759, 0.7667331695556641, 0.7655041813850403, 0.7642730474472046, 0.7630398273468018, 0.7618045210838318, 0.7605671286582947, 0.7593276500701904, 0.758086085319519, 0.7568424940109253, 0.7555968761444092, 0.7543491721153259, 0.7530995011329651, 0.7518478035926819, 0.7505941390991211, 0.7493384480476379, 0.7480807900428772, 0.7468212246894836, 0.7455596923828125, 0.7442961931228638, 0.7430307865142822, 0.7417634725570679, 0.7404942512512207, 0.7392231822013855, 0.7379502058029175, 0.7366753220558167, 0.7353986501693726, 0.7341201305389404, 0.7328397631645203, 0.7315576076507568, 0.7302736043930054, 0.7289878726005554, 0.7277002930641174, 0.726410984992981, 0.725119948387146, 0.7238271236419678, 0.7225325703620911, 0.7212363481521606, 0.7199383974075317, 0.7186387181282043, 0.7173373699188232, 0.7160343527793884, 0.7147297263145447, 0.7134234309196472, 0.712115466594696, 0.7108058929443359, 0.7094947695732117, 0.7081819772720337, 0.7068676352500916, 0.7055517435073853, 0.70423424243927, 0.7029152512550354, 0.7015946507453918, 0.7002726197242737, 0.6989490389823914, 0.6976239085197449, 0.6962973475456238, 0.6949693560600281, 0.6936398148536682, 0.6923089027404785, 0.6909765005111694, 0.6896427273750305, 0.688307523727417, 0.6869709491729736, 0.6856329441070557, 0.6842936277389526, 0.682952880859375, 0.6816108226776123, 0.6802674531936646, 0.678922712802887, 0.6775767207145691, 0.6762294173240662, 0.6748808026313782, 0.6735309362411499, 0.6721798181533813, 0.6708274483680725, 0.6694738864898682, 0.6681190729141235, 0.6667630076408386, 0.665405809879303, 0.6640474200248718, 0.6626878976821899, 0.6613271236419678, 0.6599652767181396, 0.6586022973060608, 0.6572381854057312, 0.6558730006217957, 0.6545066833496094, 0.6531393527984619, 0.6517708897590637, 0.6504014134407043, 0.649030864238739, 0.6476593017578125, 0.6462867259979248, 0.6449131369590759, 0.6435385942459106, 0.6421630382537842, 0.6407865881919861, 0.6394091248512268, 0.6380307674407959, 0.6366514563560486, 0.6352712512016296, 0.6338901519775391, 0.6325081586837769, 0.631125271320343, 0.6297415494918823, 0.6283569931983948, 0.6269716024398804, 0.6255853772163391, 0.6241983771324158, 0.6228105425834656, 0.6214219331741333, 0.6200326085090637, 0.6186424493789673, 0.6172516345977783, 0.6158600449562073, 0.6144677400588989, 0.6130747199058533, 0.6116810441017151, 0.6102867126464844, 0.6088916659355164, 0.6074960231781006, 0.6060997247695923, 0.6047027707099915, 0.6033052802085876, 0.6019071340560913, 0.6005083918571472, 0.5991091132164001, 0.5977092981338501, 0.5963088870048523, 0.5949079990386963, 0.5935065746307373, 0.5921046137809753, 0.5907022356987, 0.5892993211746216, 0.587895929813385, 0.586492121219635, 0.5850878953933716, 0.58368319272995, 0.5822781324386597, 0.580872654914856, 0.5794667601585388, 0.578060507774353, 0.5766538977622986, 0.5752469897270203, 0.5738397240638733, 0.5724321007728577, 0.5710241794586182, 0.5696160197257996, 0.5682075619697571, 0.5667988061904907, 0.5653898119926453, 0.5639805793762207, 0.562571108341217, 0.561161458492279, 0.559751570224762, 0.5583415627479553, 0.5569313168525696, 0.5555209517478943, 0.5541104078292847, 0.5526997447013855, 0.5512889623641968, 0.5498780608177185, 0.5484670996665955, 0.5470560193061829, 0.5456448793411255, 0.5442337393760681, 0.5428224802017212, 0.541411280632019, 0.5400000214576721, 0.5385887622833252, 0.5371775031089783, 0.5357662439346313, 0.534355103969574, 0.5329439640045166, 0.531532883644104, 0.530121922492981, 0.5287110209465027, 0.527300238609314, 0.5258895754814148, 0.5244790315628052, 0.5230686664581299, 0.5216584801673889, 0.5202484130859375, 0.5188385248184204, 0.5174288749694824, 0.5160194039344788, 0.5146101713180542, 0.5132011771202087, 0.5117924809455872, 0.5103839635848999, 0.5089758038520813, 0.5075678825378418, 0.506160318851471, 0.504753053188324, 0.5033460855484009, 0.5019394755363464, 0.5005332231521606, 0.4991273581981659, 0.4977218806743622, 0.4963167905807495, 0.49491211771965027, 0.49350786209106445, 0.49210405349731445, 0.49070069193840027, 0.4892977774143219, 0.4878953695297241, 0.48649343848228455, 0.48509201407432556, 0.48369109630584717, 0.48229071497917175, 0.4808908700942993, 0.47949159145355225, 0.47809287905693054, 0.4766947329044342, 0.475297212600708, 0.47390028834342957, 0.47250398993492126, 0.4711083173751831, 0.4697133004665375, 0.4683189392089844, 0.4669252634048462, 0.4655322730541229, 0.4641399681568146, 0.46274837851524353, 0.4613575339317322, 0.45996740460395813, 0.45857805013656616, 0.4571894705295563, 0.45580166578292847, 0.45441463589668274, 0.4530284106731415, 0.4516430199146271, 0.4502584636211395, 0.44887474179267883, 0.447491854429245, 0.4461098611354828, 0.4447287619113922, 0.44334855675697327, 0.44196924567222595, 0.44059085845947266, 0.43921342492103577, 0.4378369450569153, 0.4364613890647888, 0.43508684635162354, 0.43371325731277466, 0.43234071135520935, 0.43096914887428284, 0.4295985996723175, 0.42822912335395813, 0.4268606901168823, 0.4254932999610901, 0.4241270124912262, 0.42276179790496826, 0.42139768600463867, 0.4200347065925598, 0.4186728596687317, 0.4173121452331543, 0.41595256328582764, 0.4145941734313965, 0.41323697566986084, 0.4118809401988983, 0.4105261266231537, 0.40917253494262695, 0.4078201651573181, 0.40646904706954956, 0.4051191806793213, 0.4037705957889557, 0.40242329239845276, 0.4010772705078125, 0.3997325599193573, 0.39838916063308716, 0.39704710245132446, 0.3957063853740692, 0.3943670392036438, 0.3930290639400482, 0.39169245958328247, 0.39035725593566895, 0.38902348279953003, 0.38769111037254333, 0.38636016845703125, 0.3850306570529938, 0.3837026357650757, 0.3823760747909546, 0.3810510039329529, 0.37972739338874817, 0.3784053325653076, 0.37708479166030884, 0.37576577067375183, 0.3744482696056366, 0.3731323778629303, 0.37181803584098816, 0.3705052435398102, 0.3691940903663635, 0.3678845167160034, 0.36657658219337463, 0.3652702867984772, 0.36396563053131104, 0.3626626133918762, 0.3613612651824951, 0.3600616157054901, 0.3587636649608612, 0.3574674129486084, 0.3561728596687317, 0.35488006472587585, 0.3535889983177185, 0.35229969024658203, 0.35101214051246643, 0.3497263789176941, 0.348442405462265, 0.3471602201461792, 0.3458798825740814, 0.3446013331413269, 0.3433246612548828, 0.34204980731010437, 0.34077683091163635, 0.33950573205947876, 0.338236540555954, 0.3369692265987396, 0.3357038199901581, 0.33444032073020935, 0.3331787884235382, 0.33191919326782227, 0.3306615352630615, 0.32940587401390076, 0.3281521797180176, 0.32690051198005676, 0.32565081119537354, 0.32440313696861267, 0.32315748929977417, 0.3219138979911804, 0.3206723630428314, 0.3194328844547272, 0.3181954622268677, 0.3169601559638977, 0.3157269358634949, 0.31449583172798157, 0.3132668435573578, 0.31203997135162354, 0.3108152747154236, 0.30959272384643555, 0.3083723485469818, 0.3071541488170624, 0.30593812465667725, 0.3047243356704712, 0.3035127520561218, 0.30230337381362915, 0.30109623074531555, 0.2998913526535034, 0.29868873953819275, 0.29748839139938354, 0.2962903380393982, 0.2950945496559143, 0.29390108585357666, 0.29270994663238525, 0.2915211319923401, 0.29033464193344116, 0.28915050625801086, 0.2879687249660492, 0.28678932785987854, 0.2856123149394989, 0.2844376862049103, 0.28326547145843506, 0.28209567070007324, 0.2809283137321472, 0.2797633707523346, 0.27860087156295776, 0.2774408459663391, 0.27628329396247864, 0.27512824535369873, 0.2739756405353546, 0.27282556891441345, 0.27167803049087524, 0.2705329954624176, 0.2693904936313629, 0.2682505249977112, 0.2671131491661072, 0.26597830653190613, 0.2648460865020752, 0.2637164294719696, 0.26258936524391174, 0.261464923620224, 0.26034310460090637, 0.25922390818595886, 0.25810736417770386, 0.25699347257614136, 0.25588223338127136, 0.25477367639541626, 0.25366780161857605, 0.2525646388530731, 0.2514641582965851, 0.2503664195537567, 0.24927137792110443, 0.248179093003273, 0.24708954989910126, 0.24600274860858917, 0.24491873383522034, 0.24383749067783356, 0.24275903403759003, 0.24168337881565094, 0.2406105250120163, 0.2395404875278473, 0.23847328126430511, 0.23740892112255096, 0.23634740710258484, 0.23528873920440674, 0.23423294723033905, 0.23318003118038177, 0.2321300059556961, 0.23108288645744324, 0.23003865778446198, 0.2289973497390747, 0.22795897722244263, 0.22692354023456573, 0.22589105367660522, 0.2248615175485611, 0.22383494675159454, 0.22281135618686676, 0.22179074585437775, 0.2207731306552887, 0.2197585254907608, 0.21874693036079407, 0.21773836016654968, 0.21673281490802765, 0.21573032438755035, 0.2147308737039566, 0.2137344926595688, 0.2127411961555481, 0.21175095438957214, 0.2107638269662857, 0.2097797840833664, 0.2087988406419754, 0.20782102644443512, 0.20684634149074554, 0.20587478578090668, 0.2049063742160797, 0.20394112169742584, 0.20297902822494507, 0.20202010869979858, 0.20106437802314758, 0.20011183619499207, 0.19916248321533203, 0.19821634888648987, 0.19727341830730438, 0.19633372128009796, 0.1953972578048706, 0.1944640427827835, 0.19353407621383667, 0.19260737299919128, 0.19168393313884735, 0.19076377153396606, 0.18984690308570862, 0.188933327794075, 0.18802306056022644, 0.1871161013841629, 0.1862124651670456, 0.1853121519088745, 0.18441519141197205, 0.183521568775177, 0.18263129889965057, 0.18174441158771515, 0.18086087703704834, 0.17998072504997253, 0.17910397052764893, 0.17823059856891632, 0.1773606389760971, 0.17649409174919128, 0.17563097178936005, 0.1747712790966034, 0.17391502857208252, 0.17306222021579742, 0.1722128540277481, 0.17136695981025696, 0.17052453756332397, 0.16968558728694916, 0.1688501238822937, 0.1680181622505188, 0.16718968749046326, 0.16636472940444946, 0.16554328799247742, 0.1647253781557083, 0.16391098499298096, 0.16310013830661774, 0.16229283809661865, 0.1614890992641449, 0.16068892180919647, 0.15989230573177338, 0.159099280834198, 0.15830983221530914, 0.157523974776268, 0.15674172341823578, 0.15596307814121246, 0.15518803894519806, 0.15441663563251495, 0.15364885330200195, 0.15288470685482025, 0.15212421119213104, 0.15136736631393433, 0.1506141722202301, 0.14986464381217957, 0.14911878108978271, 0.14837661385536194, 0.14763812720775604, 0.14690332114696503, 0.14617222547531128, 0.1454448401927948, 0.1447211652994156, 0.14400120079517365, 0.14328497648239136, 0.14257249236106873, 0.14186373353004456, 0.14115872979164124, 0.14045748114585876, 0.13975998759269714, 0.13906626403331757, 0.13837631046772003, 0.13769014179706573, 0.13700775802135468, 0.13632915914058685, 0.13565437495708466, 0.1349833905696869, 0.13431622087955475, 0.13365286588668823, 0.13299334049224854, 0.13233762979507446, 0.1316857784986496, 0.13103775680065155, 0.1303935945034027, 0.12975327670574188, 0.12911681830883026, 0.12848423421382904, 0.12785552442073822, 0.1272306889295578, 0.12660974264144897, 0.12599268555641174, 0.1253795325756073, 0.12477027624845505, 0.12416492402553558, 0.1235634908080101, 0.1229659765958786, 0.12237238883972168, 0.12178272753953934, 0.12119700759649277, 0.12061522156000137, 0.12003739178180695, 0.11946351081132889, 0.1188935935497284, 0.11832763254642487, 0.1177656427025795, 0.11720763146877289, 0.11665359139442444, 0.11610354483127594, 0.1155574843287468, 0.1150154173374176, 0.11447735130786896, 0.11394328624010086, 0.1134132370352745, 0.11288720369338989, 0.11236518621444702, 0.11184719949960709, 0.11133323609828949, 0.11082331091165543, 0.1103174239397049, 0.1098155826330185, 0.10931779444217682, 0.10882405191659927, 0.10833437740802765, 0.10784875601530075, 0.10736721009016037, 0.10688973218202591, 0.10641632974147797, 0.10594701021909714, 0.10548177361488342, 0.10502062737941742, 0.10456357896327972, 0.10411062836647034, 0.10366177558898926, 0.10321703553199768, 0.1027764081954956, 0.10233989357948303, 0.10190749168395996, 0.10147922486066818, 0.1010550782084465, 0.10063505917787552, 0.10021918267011642, 0.09980744868516922, 0.09939984977245331, 0.09899640083312988, 0.09859710186719894, 0.09820196032524109, 0.09781097620725632, 0.09742415696382523, 0.09704149514436722, 0.09666301310062408, 0.09628869593143463, 0.09591855853796005, 0.09555260092020035, 0.09519082307815552, 0.09483323246240616, 0.09447983652353287, 0.09413063526153564, 0.09378562122583389, 0.0934448167681694, 0.09310820698738098, 0.09277581423521042, 0.09244762361049652, 0.09212364256381989, 0.0918038859963417, 0.09148833900690079, 0.09117701649665833, 0.09086992591619492, 0.09056705236434937, 0.09026841819286346, 0.08997400850057602, 0.08968383818864822, 0.08939790725708008, 0.08911621570587158, 0.08883877098560333, 0.08856557309627533, 0.08829662203788757, 0.08803191781044006, 0.087771475315094, 0.08751528710126877, 0.08726336061954498, 0.08701568841934204, 0.08677228540182114, 0.08653314411640167, 0.08629827201366425, 0.08606767654418945, 0.0858413502573967, 0.08561929315328598, 0.0854015201330185, 0.08518802374601364, 0.08497880399227142, 0.08477386832237244, 0.08457322418689728, 0.08437686413526535, 0.08418478816747665, 0.08399700373411179, 0.08381351083517075, 0.08363431692123413, 0.08345941454172134, 0.08328881114721298, 0.08312250673770905, 0.08296050131320953, 0.08280279487371445, 0.08264939486980438, 0.08250029385089874, 0.08235550671815872, 0.08221502602100372, 0.08207885175943375, 0.08194699138402939, 0.08181943744421005, 0.08169619739055634, 0.08157727122306824, 0.08146265894174576, 0.0813523679971695, 0.08124639093875885, 0.08114472776651382, 0.08104738593101501, 0.08095436543226242, 0.08086566627025604, 0.08078128844499588, 0.08070123195648193, 0.0806254968047142, 0.08055409044027328, 0.08048700541257858, 0.0804242417216301, 0.08036581426858902, 0.08031170070171356, 0.08026192337274551, 0.08021646738052368, 0.08017534017562866, 0.08013854175806046, 0.08010607212781906, 0.08007793128490448, 0.08005411922931671, 0.08003463596105576, 0.08001948148012161, 0.08000865578651428, 0.08000216633081436 ] ================================================ FILE: __tests__/data/hamming256.json ================================================ [ 0.07999999821186066, 0.08013854175806046, 0.08055409044027328, 0.08124639093875885, 0.08221502602100372, 0.08345941454172134, 0.08497880399227142, 0.08677228540182114, 0.08883877098560333, 0.09117701649665833, 0.09378562122583389, 0.09666301310062408, 0.09980744868516922, 0.10321703553199768, 0.10688973218202591, 0.11082331091165543, 0.1150154173374176, 0.11946351081132889, 0.12416492402553558, 0.12911681830883026, 0.13431622087955475, 0.13975998759269714, 0.1454448401927948, 0.15136736631393433, 0.157523974776268, 0.16391098499298096, 0.17052453756332397, 0.1773606389760971, 0.18441519141197205, 0.19168393313884735, 0.19916248321533203, 0.20684634149074554, 0.2147308737039566, 0.22281135618686676, 0.23108288645744324, 0.2395404875278473, 0.248179093003273, 0.25699347257614136, 0.26597830653190613, 0.27512824535369873, 0.2844376862049103, 0.29390108585357666, 0.3035127520561218, 0.3132668435573578, 0.32315748929977417, 0.3331787884235382, 0.3433246612548828, 0.3535889983177185, 0.36396563053131104, 0.3744482696056366, 0.3850306570529938, 0.3957063853740692, 0.40646904706954956, 0.4173121452331543, 0.42822912335395813, 0.43921342492103577, 0.4502584636211395, 0.4613575339317322, 0.47250398993492126, 0.48369109630584717, 0.49491211771965027, 0.506160318851471, 0.5174288749694824, 0.5287110209465027, 0.5400000214576721, 0.5512889623641968, 0.562571108341217, 0.5738397240638733, 0.5850878953933716, 0.5963088870048523, 0.6074960231781006, 0.6186424493789673, 0.6297415494918823, 0.6407865881919861, 0.6517708897590637, 0.6626878976821899, 0.6735309362411499, 0.6842936277389526, 0.6949693560600281, 0.7055517435073853, 0.7160343527793884, 0.726410984992981, 0.7366753220558167, 0.7468212246894836, 0.7568424940109253, 0.7667331695556641, 0.7764872908592224, 0.7860988974571228, 0.7955623269081116, 0.8048717975616455, 0.8140217065811157, 0.8230065107345581, 0.8318209052085876, 0.8404595255851746, 0.8489171266555786, 0.8571886420249939, 0.865269124507904, 0.8731536865234375, 0.8808375000953674, 0.8883160948753357, 0.8955848217010498, 0.9026393294334412, 0.9094754457473755, 0.9160889983177185, 0.9224759936332703, 0.9286326169967651, 0.934555172920227, 0.9402400255203247, 0.9456837773323059, 0.950883150100708, 0.9558351039886475, 0.9605364799499512, 0.9649845957756042, 0.969176709651947, 0.9731102585792542, 0.9767829775810242, 0.9801925420761108, 0.9833369851112366, 0.9862143993377686, 0.9888229966163635, 0.9911612272262573, 0.9932277202606201, 0.9950212240219116, 0.9965406060218811, 0.9977849721908569, 0.9987536072731018, 0.999445915222168, 0.999861478805542, 1, 0.999861478805542, 0.999445915222168, 0.9987536072731018, 0.9977849721908569, 0.9965406060218811, 0.9950212240219116, 0.9932277202606201, 0.9911612272262573, 0.9888229966163635, 0.9862143993377686, 0.9833369851112366, 0.9801925420761108, 0.9767829775810242, 0.9731102585792542, 0.969176709651947, 0.9649845957756042, 0.9605364799499512, 0.9558351039886475, 0.950883150100708, 0.9456837773323059, 0.9402400255203247, 0.934555172920227, 0.9286326169967651, 0.9224759936332703, 0.9160889983177185, 0.9094754457473755, 0.9026393294334412, 0.8955848217010498, 0.8883160948753357, 0.8808375000953674, 0.8731536865234375, 0.865269124507904, 0.8571886420249939, 0.8489171266555786, 0.8404595255851746, 0.8318209052085876, 0.8230065107345581, 0.8140217065811157, 0.8048717975616455, 0.7955623269081116, 0.7860988974571228, 0.7764872908592224, 0.7667331695556641, 0.7568424940109253, 0.7468212246894836, 0.7366753220558167, 0.726410984992981, 0.7160343527793884, 0.7055517435073853, 0.6949693560600281, 0.6842936277389526, 0.6735309362411499, 0.6626878976821899, 0.6517708897590637, 0.6407865881919861, 0.6297415494918823, 0.6186424493789673, 0.6074960231781006, 0.5963088870048523, 0.5850878953933716, 0.5738397240638733, 0.562571108341217, 0.5512889623641968, 0.5400000214576721, 0.5287110209465027, 0.5174288749694824, 0.506160318851471, 0.49491211771965027, 0.48369109630584717, 0.47250398993492126, 0.4613575339317322, 0.4502584636211395, 0.43921342492103577, 0.42822912335395813, 0.4173121452331543, 0.40646904706954956, 0.3957063853740692, 0.3850306570529938, 0.3744482696056366, 0.36396563053131104, 0.3535889983177185, 0.3433246612548828, 0.3331787884235382, 0.32315748929977417, 0.3132668435573578, 0.3035127520561218, 0.29390108585357666, 0.2844376862049103, 0.27512824535369873, 0.26597830653190613, 0.25699347257614136, 0.248179093003273, 0.2395404875278473, 0.23108288645744324, 0.22281135618686676, 0.2147308737039566, 0.20684634149074554, 0.19916248321533203, 0.19168393313884735, 0.18441519141197205, 0.1773606389760971, 0.17052453756332397, 0.16391098499298096, 0.157523974776268, 0.15136736631393433, 0.1454448401927948, 0.13975998759269714, 0.13431622087955475, 0.12911681830883026, 0.12416492402553558, 0.11946351081132889, 0.1150154173374176, 0.11082331091165543, 0.10688973218202591, 0.10321703553199768, 0.09980744868516922, 0.09666301310062408, 0.09378562122583389, 0.09117701649665833, 0.08883877098560333, 0.08677228540182114, 0.08497880399227142, 0.08345941454172134, 0.08221502602100372, 0.08124639093875885, 0.08055409044027328, 0.08013854175806046 ] ================================================ FILE: __tests__/data/hamming512.json ================================================ [ 0.07999999821186066, 0.08003463596105576, 0.08013854175806046, 0.08031170070171356, 0.08055409044027328, 0.08086566627025604, 0.08124639093875885, 0.08169619739055634, 0.08221502602100372, 0.08280279487371445, 0.08345941454172134, 0.08418478816747665, 0.08497880399227142, 0.0858413502573967, 0.08677228540182114, 0.087771475315094, 0.08883877098560333, 0.08997400850057602, 0.09117701649665833, 0.09244762361049652, 0.09378562122583389, 0.09519082307815552, 0.09666301310062408, 0.09820196032524109, 0.09980744868516922, 0.10147922486066818, 0.10321703553199768, 0.10502062737941742, 0.10688973218202591, 0.10882405191659927, 0.11082331091165543, 0.11288720369338989, 0.1150154173374176, 0.11720763146877289, 0.11946351081132889, 0.12178272753953934, 0.12416492402553558, 0.12660974264144897, 0.12911681830883026, 0.1316857784986496, 0.13431622087955475, 0.13700775802135468, 0.13975998759269714, 0.14257249236106873, 0.1454448401927948, 0.14837661385536194, 0.15136736631393433, 0.15441663563251495, 0.157523974776268, 0.16068892180919647, 0.16391098499298096, 0.16718968749046326, 0.17052453756332397, 0.17391502857208252, 0.1773606389760971, 0.18086087703704834, 0.18441519141197205, 0.18802306056022644, 0.19168393313884735, 0.1953972578048706, 0.19916248321533203, 0.20297902822494507, 0.20684634149074554, 0.2107638269662857, 0.2147308737039566, 0.21874693036079407, 0.22281135618686676, 0.22692354023456573, 0.23108288645744324, 0.23528873920440674, 0.2395404875278473, 0.24383749067783356, 0.248179093003273, 0.2525646388530731, 0.25699347257614136, 0.261464923620224, 0.26597830653190613, 0.2705329954624176, 0.27512824535369873, 0.2797633707523346, 0.2844376862049103, 0.28915050625801086, 0.29390108585357666, 0.29868873953819275, 0.3035127520561218, 0.3083723485469818, 0.3132668435573578, 0.3181954622268677, 0.32315748929977417, 0.3281521797180176, 0.3331787884235382, 0.338236540555954, 0.3433246612548828, 0.348442405462265, 0.3535889983177185, 0.3587636649608612, 0.36396563053131104, 0.3691940903663635, 0.3744482696056366, 0.37972739338874817, 0.3850306570529938, 0.39035725593566895, 0.3957063853740692, 0.4010772705078125, 0.40646904706954956, 0.4118809401988983, 0.4173121452331543, 0.42276179790496826, 0.42822912335395813, 0.43371325731277466, 0.43921342492103577, 0.4447287619113922, 0.4502584636211395, 0.45580166578292847, 0.4613575339317322, 0.4669252634048462, 0.47250398993492126, 0.47809287905693054, 0.48369109630584717, 0.4892977774143219, 0.49491211771965027, 0.5005332231521606, 0.506160318851471, 0.5117924809455872, 0.5174288749694824, 0.5230686664581299, 0.5287110209465027, 0.534355103969574, 0.5400000214576721, 0.5456448793411255, 0.5512889623641968, 0.5569313168525696, 0.562571108341217, 0.5682075619697571, 0.5738397240638733, 0.5794667601585388, 0.5850878953933716, 0.5907022356987, 0.5963088870048523, 0.6019071340560913, 0.6074960231781006, 0.6130747199058533, 0.6186424493789673, 0.6241983771324158, 0.6297415494918823, 0.6352712512016296, 0.6407865881919861, 0.6462867259979248, 0.6517708897590637, 0.6572381854057312, 0.6626878976821899, 0.6681190729141235, 0.6735309362411499, 0.678922712802887, 0.6842936277389526, 0.6896427273750305, 0.6949693560600281, 0.7002726197242737, 0.7055517435073853, 0.7108058929443359, 0.7160343527793884, 0.7212363481521606, 0.726410984992981, 0.7315576076507568, 0.7366753220558167, 0.7417634725570679, 0.7468212246894836, 0.7518478035926819, 0.7568424940109253, 0.7618045210838318, 0.7667331695556641, 0.77162766456604, 0.7764872908592224, 0.7813112735748291, 0.7860988974571228, 0.790849506855011, 0.7955623269081116, 0.8002366423606873, 0.8048717975616455, 0.8094670176506042, 0.8140217065811157, 0.8185350894927979, 0.8230065107345581, 0.8274353742599487, 0.8318209052085876, 0.8361625075340271, 0.8404595255851746, 0.8447112441062927, 0.8489171266555786, 0.8530764579772949, 0.8571886420249939, 0.8612530827522278, 0.865269124507904, 0.869236171245575, 0.8731536865234375, 0.8770209550857544, 0.8808375000953674, 0.8846027255058289, 0.8883160948753357, 0.8919769525527954, 0.8955848217010498, 0.8991391062736511, 0.9026393294334412, 0.9060849547386169, 0.9094754457473755, 0.9128103256225586, 0.9160889983177185, 0.9193111062049866, 0.9224759936332703, 0.9255833625793457, 0.9286326169967651, 0.9316233992576599, 0.934555172920227, 0.9374275207519531, 0.9402400255203247, 0.9429922699928284, 0.9456837773323059, 0.9483142495155334, 0.950883150100708, 0.9533902406692505, 0.9558351039886475, 0.9582172632217407, 0.9605364799499512, 0.9627923965454102, 0.9649845957756042, 0.9671127796173096, 0.969176709651947, 0.9711759686470032, 0.9731102585792542, 0.9749793410301208, 0.9767829775810242, 0.9785207509994507, 0.9801925420761108, 0.9817980527877808, 0.9833369851112366, 0.984809160232544, 0.9862143993377686, 0.9875524044036865, 0.9888229966163635, 0.9900259971618652, 0.9911612272262573, 0.9922285079956055, 0.9932277202606201, 0.9941586256027222, 0.9950212240219116, 0.9958152174949646, 0.9965406060218811, 0.9971972107887268, 0.9977849721908569, 0.9983038306236267, 0.9987536072731018, 0.9991343021392822, 0.999445915222168, 0.9996882677078247, 0.999861478805542, 0.9999653697013855, 1, 0.9999653697013855, 0.999861478805542, 0.9996882677078247, 0.999445915222168, 0.9991343021392822, 0.9987536072731018, 0.9983038306236267, 0.9977849721908569, 0.9971972107887268, 0.9965406060218811, 0.9958152174949646, 0.9950212240219116, 0.9941586256027222, 0.9932277202606201, 0.9922285079956055, 0.9911612272262573, 0.9900259971618652, 0.9888229966163635, 0.9875524044036865, 0.9862143993377686, 0.984809160232544, 0.9833369851112366, 0.9817980527877808, 0.9801925420761108, 0.9785207509994507, 0.9767829775810242, 0.9749793410301208, 0.9731102585792542, 0.9711759686470032, 0.969176709651947, 0.9671127796173096, 0.9649845957756042, 0.9627923965454102, 0.9605364799499512, 0.9582172632217407, 0.9558351039886475, 0.9533902406692505, 0.950883150100708, 0.9483142495155334, 0.9456837773323059, 0.9429922699928284, 0.9402400255203247, 0.9374275207519531, 0.934555172920227, 0.9316233992576599, 0.9286326169967651, 0.9255833625793457, 0.9224759936332703, 0.9193111062049866, 0.9160889983177185, 0.9128103256225586, 0.9094754457473755, 0.9060849547386169, 0.9026393294334412, 0.8991391062736511, 0.8955848217010498, 0.8919769525527954, 0.8883160948753357, 0.8846027255058289, 0.8808375000953674, 0.8770209550857544, 0.8731536865234375, 0.869236171245575, 0.865269124507904, 0.8612530827522278, 0.8571886420249939, 0.8530764579772949, 0.8489171266555786, 0.8447112441062927, 0.8404595255851746, 0.8361625075340271, 0.8318209052085876, 0.8274353742599487, 0.8230065107345581, 0.8185350894927979, 0.8140217065811157, 0.8094670176506042, 0.8048717975616455, 0.8002366423606873, 0.7955623269081116, 0.790849506855011, 0.7860988974571228, 0.7813112735748291, 0.7764872908592224, 0.77162766456604, 0.7667331695556641, 0.7618045210838318, 0.7568424940109253, 0.7518478035926819, 0.7468212246894836, 0.7417634725570679, 0.7366753220558167, 0.7315576076507568, 0.726410984992981, 0.7212363481521606, 0.7160343527793884, 0.7108058929443359, 0.7055517435073853, 0.7002726197242737, 0.6949693560600281, 0.6896427273750305, 0.6842936277389526, 0.678922712802887, 0.6735309362411499, 0.6681190729141235, 0.6626878976821899, 0.6572381854057312, 0.6517708897590637, 0.6462867259979248, 0.6407865881919861, 0.6352712512016296, 0.6297415494918823, 0.6241983771324158, 0.6186424493789673, 0.6130747199058533, 0.6074960231781006, 0.6019071340560913, 0.5963088870048523, 0.5907022356987, 0.5850878953933716, 0.5794667601585388, 0.5738397240638733, 0.5682075619697571, 0.562571108341217, 0.5569313168525696, 0.5512889623641968, 0.5456448793411255, 0.5400000214576721, 0.534355103969574, 0.5287110209465027, 0.5230686664581299, 0.5174288749694824, 0.5117924809455872, 0.506160318851471, 0.5005332231521606, 0.49491211771965027, 0.4892977774143219, 0.48369109630584717, 0.47809287905693054, 0.47250398993492126, 0.4669252634048462, 0.4613575339317322, 0.45580166578292847, 0.4502584636211395, 0.4447287619113922, 0.43921342492103577, 0.43371325731277466, 0.42822912335395813, 0.42276179790496826, 0.4173121452331543, 0.4118809401988983, 0.40646904706954956, 0.4010772705078125, 0.3957063853740692, 0.39035725593566895, 0.3850306570529938, 0.37972739338874817, 0.3744482696056366, 0.3691940903663635, 0.36396563053131104, 0.3587636649608612, 0.3535889983177185, 0.348442405462265, 0.3433246612548828, 0.338236540555954, 0.3331787884235382, 0.3281521797180176, 0.32315748929977417, 0.3181954622268677, 0.3132668435573578, 0.3083723485469818, 0.3035127520561218, 0.29868873953819275, 0.29390108585357666, 0.28915050625801086, 0.2844376862049103, 0.2797633707523346, 0.27512824535369873, 0.2705329954624176, 0.26597830653190613, 0.261464923620224, 0.25699347257614136, 0.2525646388530731, 0.248179093003273, 0.24383749067783356, 0.2395404875278473, 0.23528873920440674, 0.23108288645744324, 0.22692354023456573, 0.22281135618686676, 0.21874693036079407, 0.2147308737039566, 0.2107638269662857, 0.20684634149074554, 0.20297902822494507, 0.19916248321533203, 0.1953972578048706, 0.19168393313884735, 0.18802306056022644, 0.18441519141197205, 0.18086087703704834, 0.1773606389760971, 0.17391502857208252, 0.17052453756332397, 0.16718968749046326, 0.16391098499298096, 0.16068892180919647, 0.157523974776268, 0.15441663563251495, 0.15136736631393433, 0.14837661385536194, 0.1454448401927948, 0.14257249236106873, 0.13975998759269714, 0.13700775802135468, 0.13431622087955475, 0.1316857784986496, 0.12911681830883026, 0.12660974264144897, 0.12416492402553558, 0.12178272753953934, 0.11946351081132889, 0.11720763146877289, 0.1150154173374176, 0.11288720369338989, 0.11082331091165543, 0.10882405191659927, 0.10688973218202591, 0.10502062737941742, 0.10321703553199768, 0.10147922486066818, 0.09980744868516922, 0.09820196032524109, 0.09666301310062408, 0.09519082307815552, 0.09378562122583389, 0.09244762361049652, 0.09117701649665833, 0.08997400850057602, 0.08883877098560333, 0.087771475315094, 0.08677228540182114, 0.0858413502573967, 0.08497880399227142, 0.08418478816747665, 0.08345941454172134, 0.08280279487371445, 0.08221502602100372, 0.08169619739055634, 0.08124639093875885, 0.08086566627025604, 0.08055409044027328, 0.08031170070171356, 0.08013854175806046, 0.08003463596105576 ] ================================================ FILE: __tests__/data/hanning1024.json ================================================ [ 0, 9.430768841411918e-06, 3.7722722481703386e-05, 8.487478771712631e-05, 0.00015088518557604402, 0.0002357514458708465, 0.0003394703380763531, 0.0004620379477273673, 0.0006034497055225074, 0.000763700227253139, 0.0009427834302186966, 0.001140692620538175, 0.0013574203476309776, 0.0015929584624245763, 0.0018472978845238686, 0.0021204291842877865, 0.002412342233583331, 0.0027230256237089634, 0.0030524679459631443, 0.0034006566274911165, 0.003767578396946192, 0.0041532195173203945, 0.004557565785944462, 0.0049806018359959126, 0.005422311369329691, 0.005882677622139454, 0.006361683830618858, 0.006859311368316412, 0.0073755416087806225, 0.007910354994237423, 0.008463731966912746, 0.009035651572048664, 0.009626091457903385, 0.010235029272735119, 0.010862442664802074, 0.011508308351039886, 0.01217260118573904, 0.012855296023190022, 0.01355636864900589, 0.014275790192186832, 0.015013535507023335, 0.01576957479119301, 0.016543881967663765, 0.017336426302790642, 0.01814717799425125, 0.018976107239723206, 0.01982318051159382, 0.020688369870185852, 0.02157163806259632, 0.022472955286502838, 0.023392286151647568, 0.024329597130417824, 0.02528485096991062, 0.026258012279868126, 0.027249043807387352, 0.028257910162210464, 0.02928457222878933, 0.030328990891575813, 0.03139112517237663, 0.0324709415435791, 0.03356838971376419, 0.034683436155319214, 0.03581603243947029, 0.03696614131331444, 0.03813371807336807, 0.039318718016147614, 0.04052109271287918, 0.04174080491065979, 0.04297780245542526, 0.04423204064369202, 0.045503467321395874, 0.04679204523563385, 0.04809771478176117, 0.04942043498158455, 0.05076014995574951, 0.052116815000772476, 0.053490374237298965, 0.0548807755112648, 0.056287966668605804, 0.057711899280548096, 0.0591525137424469, 0.060609761625528336, 0.06208358332514763, 0.0635739266872406, 0.06508072465658188, 0.06660393625497818, 0.06814350187778473, 0.06969934701919556, 0.07127143442630768, 0.07285968959331512, 0.07446406036615372, 0.07608447968959808, 0.07772088795900345, 0.07937323302030563, 0.08104144036769867, 0.08272545784711838, 0.08442521095275879, 0.08614064753055573, 0.08787168562412262, 0.08961828052997589, 0.09138035029172897, 0.09315783530473709, 0.09495066851377487, 0.09675878286361694, 0.09858211129903793, 0.10042057186365128, 0.10227411240339279, 0.10414265841245651, 0.10602613538503647, 0.10792447626590729, 0.109837606549263, 0.11176545172929764, 0.11370794475078583, 0.1156650111079216, 0.11763656884431839, 0.11962255835533142, 0.12162289768457413, 0.12363750487565994, 0.1256663054227829, 0.12770923972129822, 0.12976621091365814, 0.1318371444940567, 0.13392198085784912, 0.13602061569690704, 0.1381329745054245, 0.1402589976787567, 0.14239858090877533, 0.14455166459083557, 0.14671814441680908, 0.1488979607820511, 0.15109102427959442, 0.15329724550247192, 0.15551653504371643, 0.15774883329868317, 0.15999403595924377, 0.16225206851959229, 0.16452284157276154, 0.16680626571178436, 0.1691022664308548, 0.17141073942184448, 0.17373161017894745, 0.17606478929519653, 0.17841020226478577, 0.1807677298784256, 0.18313729763031006, 0.18551883101463318, 0.1879122257232666, 0.19031739234924316, 0.1927342265844345, 0.19516266882419586, 0.19760259985923767, 0.20005394518375397, 0.2025166153907776, 0.20499049127101898, 0.20747549831867218, 0.20997154712677002, 0.21247853338718414, 0.2149963676929474, 0.2175249457359314, 0.220064178109169, 0.22261397540569305, 0.22517424821853638, 0.22774487733840942, 0.23032577335834503, 0.23291684687137604, 0.23551799356937408, 0.238129124045372, 0.24075011909008026, 0.24338090419769287, 0.24602137506008148, 0.24867141246795654, 0.2513309419155121, 0.25399985909461975, 0.25667804479599, 0.25936540961265564, 0.26206183433532715, 0.26476725935935974, 0.26748156547546387, 0.2702046036720276, 0.2729363441467285, 0.2756766378879547, 0.278425395488739, 0.28118252754211426, 0.2839478850364685, 0.286721408367157, 0.28950297832489014, 0.2922925055027008, 0.29508984088897705, 0.2978949248790741, 0.30070760846138, 0.30352783203125, 0.30635544657707214, 0.30919039249420166, 0.3120325207710266, 0.31488174200057983, 0.3177379369735718, 0.3206010162830353, 0.3234708607196808, 0.32634738087654114, 0.3292304277420044, 0.3321199417114258, 0.33501577377319336, 0.3379178047180176, 0.34082597494125366, 0.34374016523361206, 0.34666022658348083, 0.3495860695838928, 0.35251760482788086, 0.3554547131061554, 0.3583972454071045, 0.3613451421260834, 0.3642982542514801, 0.3672564923763275, 0.37021973729133606, 0.3731878697872162, 0.37616080045700073, 0.37913838028907776, 0.3821205198764801, 0.3851071298122406, 0.3880980610847473, 0.3910932242870331, 0.39409247040748596, 0.3970957398414612, 0.4001028835773468, 0.40311378240585327, 0.4061283469200134, 0.4091464579105377, 0.4121679961681366, 0.4151928424835205, 0.4182208776473999, 0.4212520122528076, 0.4242860972881317, 0.4273230731487274, 0.4303627610206604, 0.4334051012992859, 0.43644991517066956, 0.439497172832489, 0.44254666566848755, 0.4455983638763428, 0.44865208864212036, 0.45170778036117554, 0.454765260219574, 0.4578244686126709, 0.46088525652885437, 0.4639475345611572, 0.46701115369796753, 0.4700760245323181, 0.47314202785491943, 0.47620904445648193, 0.47927695512771606, 0.4823456406593323, 0.4854150116443634, 0.4884849190711975, 0.49155527353286743, 0.49462592601776123, 0.49769678711891174, 0.5007677674293518, 0.5038386583328247, 0.5069094300270081, 0.5099799633026123, 0.5130500793457031, 0.5161197781562805, 0.5191887617111206, 0.5222570896148682, 0.5253245830535889, 0.5283911228179932, 0.5314565300941467, 0.5345208048820496, 0.5375837683677673, 0.5406453013420105, 0.5437053442001343, 0.5467637181282043, 0.5498203039169312, 0.5528750419616699, 0.5559277534484863, 0.5589783787727356, 0.5620267391204834, 0.565072774887085, 0.5681163668632507, 0.5711573958396912, 0.5741957426071167, 0.5772312879562378, 0.5802639126777649, 0.5832935571670532, 0.5863199830055237, 0.5893431901931763, 0.5923629999160767, 0.5953793525695801, 0.598392128944397, 0.601401150226593, 0.6044063568115234, 0.6074076294898987, 0.6104048490524292, 0.6133979558944702, 0.6163867115974426, 0.6193711161613464, 0.6223509907722473, 0.6253262758255005, 0.6282967925071716, 0.6312625408172607, 0.6342232823371887, 0.6371789574623108, 0.6401294469833374, 0.6430746912956238, 0.6460145115852356, 0.6489488482475281, 0.6518775820732117, 0.654800534248352, 0.6577176451683044, 0.6606288552284241, 0.6635339856147766, 0.6664329171180725, 0.669325590133667, 0.6722118854522705, 0.6750916838645935, 0.6779648661613464, 0.6808313727378845, 0.6836910247802734, 0.6865437626838684, 0.6893894672393799, 0.6922279596328735, 0.6950592994689941, 0.6978831887245178, 0.7006996870040894, 0.7035085558891296, 0.7063097953796387, 0.7091032266616821, 0.7118887901306152, 0.7146663665771484, 0.7174358367919922, 0.7201970815658569, 0.7229500412940979, 0.7256945967674255, 0.7284305691719055, 0.7311580181121826, 0.7338767051696777, 0.7365865707397461, 0.7392874956130981, 0.7419794201850891, 0.7446622252464294, 0.7473357915878296, 0.75, 0.7526547908782959, 0.7553000450134277, 0.7579357028007507, 0.7605615854263306, 0.7631776928901672, 0.7657838463783264, 0.7683799266815186, 0.7709659337997437, 0.7735417485237122, 0.7761071920394897, 0.7786622047424316, 0.7812067866325378, 0.7837406992912292, 0.7862638831138611, 0.7887763381004333, 0.7912778258323669, 0.7937684059143066, 0.7962478399276733, 0.798716127872467, 0.8011731505393982, 0.8036187887191772, 0.8060529828071594, 0.8084756731987, 0.8108866810798645, 0.8132859468460083, 0.8156734108924866, 0.8180489540100098, 0.8204125761985779, 0.8227640390396118, 0.8251033425331116, 0.8274303674697876, 0.8297450542449951, 0.8320472836494446, 0.8343369960784912, 0.8366141319274902, 0.8388785719871521, 0.8411301970481873, 0.8433689475059509, 0.8455947637557983, 0.8478075265884399, 0.850007176399231, 0.8521935939788818, 0.8543667793273926, 0.8565265536308289, 0.8586729168891907, 0.8608056902885437, 0.8629249334335327, 0.8650304079055786, 0.8671221733093262, 0.8692000508308411, 0.8712640404701233, 0.8733139634132385, 0.8753498792648315, 0.8773715496063232, 0.8793790340423584, 0.8813722133636475, 0.8833510279655457, 0.8853153586387634, 0.887265145778656, 0.8892003297805786, 0.8911207914352417, 0.8930265307426453, 0.8949174880981445, 0.8967934846878052, 0.8986545205116272, 0.9005005359649658, 0.9023314714431763, 0.904147207736969, 0.9059476852416992, 0.9077328443527222, 0.9095026254653931, 0.9112569689750671, 0.9129957556724548, 0.9147190451622009, 0.9164265990257263, 0.9181185364723206, 0.9197946190834045, 0.921454906463623, 0.9230993390083313, 0.924727737903595, 0.9263401627540588, 0.9279364347457886, 0.929516613483429, 0.9310805797576904, 0.932628333568573, 0.9341596961021423, 0.9356747269630432, 0.9371733069419861, 0.9386553764343262, 0.9401209354400635, 0.9415698647499084, 0.9430021643638611, 0.9444177150726318, 0.9458165168762207, 0.9471985101699829, 0.9485636353492737, 0.9499118328094482, 0.9512430429458618, 0.9525572657585144, 0.9538543820381165, 0.955134391784668, 0.9563972353935242, 0.9576428532600403, 0.9588711857795715, 0.9600822925567627, 0.9612759351730347, 0.962452232837677, 0.9636111259460449, 0.9647524356842041, 0.9658762812614441, 0.9669825434684753, 0.9680711627006531, 0.9691421389579773, 0.9701954126358032, 0.9712309837341309, 0.9722487330436707, 0.9732487201690674, 0.9742308259010315, 0.9751949906349182, 0.9761412739753723, 0.977069616317749, 0.9779799580574036, 0.9788722395896912, 0.9797464609146118, 0.9806026220321655, 0.9814406037330627, 0.9822604656219482, 0.9830621480941772, 0.9838455319404602, 0.9846107363700867, 0.9853576421737671, 0.9860861897468567, 0.9867964386940002, 0.987488329410553, 0.9881618618965149, 0.9888169169425964, 0.9894535541534424, 0.9900717735290527, 0.9906714558601379, 0.991252601146698, 0.9918152689933777, 0.9923593997955322, 0.9928848743438721, 0.9933918118476868, 0.9938801527023315, 0.9943498373031616, 0.994800865650177, 0.9952332377433777, 0.9956469535827637, 0.9960419535636902, 0.9964182376861572, 0.9967758059501648, 0.9971145987510681, 0.997434675693512, 0.9977359771728516, 0.9980185031890869, 0.9982821941375732, 0.9985271692276001, 0.9987533092498779, 0.9989606142044067, 0.9991490840911865, 0.9993187785148621, 0.9994696378707886, 0.9996016025543213, 0.999714732170105, 0.9998090267181396, 0.9998844861984253, 0.9999410510063171, 0.99997878074646, 0.999997615814209, 0.999997615814209, 0.99997878074646, 0.9999410510063171, 0.9998844861984253, 0.9998090267181396, 0.999714732170105, 0.9996016025543213, 0.9994696378707886, 0.9993187785148621, 0.9991490840911865, 0.9989606142044067, 0.9987533092498779, 0.9985271692276001, 0.9982821941375732, 0.9980185031890869, 0.9977359771728516, 0.997434675693512, 0.9971145987510681, 0.9967758059501648, 0.9964182376861572, 0.9960419535636902, 0.9956469535827637, 0.9952332377433777, 0.994800865650177, 0.9943498373031616, 0.9938801527023315, 0.9933918118476868, 0.9928848743438721, 0.9923593997955322, 0.9918152689933777, 0.991252601146698, 0.9906714558601379, 0.9900717735290527, 0.9894535541534424, 0.9888169169425964, 0.9881618618965149, 0.987488329410553, 0.9867964386940002, 0.9860861897468567, 0.9853576421737671, 0.9846107363700867, 0.9838455319404602, 0.9830621480941772, 0.9822604656219482, 0.9814406037330627, 0.9806026220321655, 0.9797464609146118, 0.9788722395896912, 0.9779799580574036, 0.977069616317749, 0.9761412739753723, 0.9751949906349182, 0.9742308259010315, 0.9732487201690674, 0.9722487330436707, 0.9712309837341309, 0.9701954126358032, 0.9691421389579773, 0.9680711627006531, 0.9669825434684753, 0.9658762812614441, 0.9647524356842041, 0.9636111259460449, 0.962452232837677, 0.9612759351730347, 0.9600822925567627, 0.9588711857795715, 0.9576428532600403, 0.9563972353935242, 0.955134391784668, 0.9538543820381165, 0.9525572657585144, 0.9512430429458618, 0.9499118328094482, 0.9485636353492737, 0.9471985101699829, 0.9458165168762207, 0.9444177150726318, 0.9430021643638611, 0.9415698647499084, 0.9401209354400635, 0.9386553764343262, 0.9371733069419861, 0.9356747269630432, 0.9341596961021423, 0.932628333568573, 0.9310805797576904, 0.929516613483429, 0.9279364347457886, 0.9263401627540588, 0.924727737903595, 0.9230993390083313, 0.921454906463623, 0.9197946190834045, 0.9181185364723206, 0.9164265990257263, 0.9147190451622009, 0.9129957556724548, 0.9112569689750671, 0.9095026254653931, 0.9077328443527222, 0.9059476852416992, 0.904147207736969, 0.9023314714431763, 0.9005005359649658, 0.8986545205116272, 0.8967934846878052, 0.8949174880981445, 0.8930265307426453, 0.8911207914352417, 0.8892003297805786, 0.887265145778656, 0.8853153586387634, 0.8833510279655457, 0.8813722133636475, 0.8793790340423584, 0.8773715496063232, 0.8753498792648315, 0.8733139634132385, 0.8712640404701233, 0.8692000508308411, 0.8671221733093262, 0.8650304079055786, 0.8629249334335327, 0.8608056902885437, 0.8586729168891907, 0.8565265536308289, 0.8543667793273926, 0.8521935939788818, 0.850007176399231, 0.8478075265884399, 0.8455947637557983, 0.8433689475059509, 0.8411301970481873, 0.8388785719871521, 0.8366141319274902, 0.8343369960784912, 0.8320472836494446, 0.8297450542449951, 0.8274303674697876, 0.8251033425331116, 0.8227640390396118, 0.8204125761985779, 0.8180489540100098, 0.8156734108924866, 0.8132859468460083, 0.8108866810798645, 0.8084756731987, 0.8060529828071594, 0.8036187887191772, 0.8011731505393982, 0.798716127872467, 0.7962478399276733, 0.7937684059143066, 0.7912778258323669, 0.7887763381004333, 0.7862638831138611, 0.7837406992912292, 0.7812067866325378, 0.7786622047424316, 0.7761071920394897, 0.7735417485237122, 0.7709659337997437, 0.7683799266815186, 0.7657838463783264, 0.7631776928901672, 0.7605615854263306, 0.7579357028007507, 0.7553000450134277, 0.7526547908782959, 0.75, 0.7473357915878296, 0.7446622252464294, 0.7419794201850891, 0.7392874956130981, 0.7365865707397461, 0.7338767051696777, 0.7311580181121826, 0.7284305691719055, 0.7256945967674255, 0.7229500412940979, 0.7201970815658569, 0.7174358367919922, 0.7146663665771484, 0.7118887901306152, 0.7091032266616821, 0.7063097953796387, 0.7035085558891296, 0.7006996870040894, 0.6978831887245178, 0.6950592994689941, 0.6922279596328735, 0.6893894672393799, 0.6865437626838684, 0.6836910247802734, 0.6808313727378845, 0.6779648661613464, 0.6750916838645935, 0.6722118854522705, 0.669325590133667, 0.6664329171180725, 0.6635339856147766, 0.6606288552284241, 0.6577176451683044, 0.654800534248352, 0.6518775820732117, 0.6489488482475281, 0.6460145115852356, 0.6430746912956238, 0.6401294469833374, 0.6371789574623108, 0.6342232823371887, 0.6312625408172607, 0.6282967925071716, 0.6253262758255005, 0.6223509907722473, 0.6193711161613464, 0.6163867115974426, 0.6133979558944702, 0.6104048490524292, 0.6074076294898987, 0.6044063568115234, 0.601401150226593, 0.598392128944397, 0.5953793525695801, 0.5923629999160767, 0.5893431901931763, 0.5863199830055237, 0.5832935571670532, 0.5802639126777649, 0.5772312879562378, 0.5741957426071167, 0.5711573958396912, 0.5681163668632507, 0.565072774887085, 0.5620267391204834, 0.5589783787727356, 0.5559277534484863, 0.5528750419616699, 0.5498203039169312, 0.5467637181282043, 0.5437053442001343, 0.5406453013420105, 0.5375837683677673, 0.5345208048820496, 0.5314565300941467, 0.5283911228179932, 0.5253245830535889, 0.5222570896148682, 0.5191887617111206, 0.5161197781562805, 0.5130500793457031, 0.5099799633026123, 0.5069094300270081, 0.5038386583328247, 0.5007677674293518, 0.49769678711891174, 0.49462592601776123, 0.49155527353286743, 0.4884849190711975, 0.4854150116443634, 0.4823456406593323, 0.47927695512771606, 0.47620904445648193, 0.47314202785491943, 0.4700760245323181, 0.46701115369796753, 0.4639475345611572, 0.46088525652885437, 0.4578244686126709, 0.454765260219574, 0.45170778036117554, 0.44865208864212036, 0.4455983638763428, 0.44254666566848755, 0.439497172832489, 0.43644991517066956, 0.4334051012992859, 0.4303627610206604, 0.4273230731487274, 0.4242860972881317, 0.4212520122528076, 0.4182208776473999, 0.4151928424835205, 0.4121679961681366, 0.4091464579105377, 0.4061283469200134, 0.40311378240585327, 0.4001028835773468, 0.3970957398414612, 0.39409247040748596, 0.3910932242870331, 0.3880980610847473, 0.3851071298122406, 0.3821205198764801, 0.37913838028907776, 0.37616080045700073, 0.3731878697872162, 0.37021973729133606, 0.3672564923763275, 0.3642982542514801, 0.3613451421260834, 0.3583972454071045, 0.3554547131061554, 0.35251760482788086, 0.3495860695838928, 0.34666022658348083, 0.34374016523361206, 0.34082597494125366, 0.3379178047180176, 0.33501577377319336, 0.3321199417114258, 0.3292304277420044, 0.32634738087654114, 0.3234708607196808, 0.3206010162830353, 0.3177379369735718, 0.31488174200057983, 0.3120325207710266, 0.30919039249420166, 0.30635544657707214, 0.30352783203125, 0.30070760846138, 0.2978949248790741, 0.29508984088897705, 0.2922925055027008, 0.28950297832489014, 0.286721408367157, 0.2839478850364685, 0.28118252754211426, 0.278425395488739, 0.2756766378879547, 0.2729363441467285, 0.2702046036720276, 0.26748156547546387, 0.26476725935935974, 0.26206183433532715, 0.25936540961265564, 0.25667804479599, 0.25399985909461975, 0.2513309419155121, 0.24867141246795654, 0.24602137506008148, 0.24338090419769287, 0.24075011909008026, 0.238129124045372, 0.23551799356937408, 0.23291684687137604, 0.23032577335834503, 0.22774487733840942, 0.22517424821853638, 0.22261397540569305, 0.220064178109169, 0.2175249457359314, 0.2149963676929474, 0.21247853338718414, 0.20997154712677002, 0.20747549831867218, 0.20499049127101898, 0.2025166153907776, 0.20005394518375397, 0.19760259985923767, 0.19516266882419586, 0.1927342265844345, 0.19031739234924316, 0.1879122257232666, 0.18551883101463318, 0.18313729763031006, 0.1807677298784256, 0.17841020226478577, 0.17606478929519653, 0.17373161017894745, 0.17141073942184448, 0.1691022664308548, 0.16680626571178436, 0.16452284157276154, 0.16225206851959229, 0.15999403595924377, 0.15774883329868317, 0.15551653504371643, 0.15329724550247192, 0.15109102427959442, 0.1488979607820511, 0.14671814441680908, 0.14455166459083557, 0.14239858090877533, 0.1402589976787567, 0.1381329745054245, 0.13602061569690704, 0.13392198085784912, 0.1318371444940567, 0.12976621091365814, 0.12770923972129822, 0.1256663054227829, 0.12363750487565994, 0.12162289768457413, 0.11962255835533142, 0.11763656884431839, 0.1156650111079216, 0.11370794475078583, 0.11176545172929764, 0.109837606549263, 0.10792447626590729, 0.10602613538503647, 0.10414265841245651, 0.10227411240339279, 0.10042057186365128, 0.09858211129903793, 0.09675878286361694, 0.09495066851377487, 0.09315783530473709, 0.09138035029172897, 0.08961828052997589, 0.08787168562412262, 0.08614064753055573, 0.08442521095275879, 0.08272545784711838, 0.08104144036769867, 0.07937323302030563, 0.07772088795900345, 0.07608447968959808, 0.07446406036615372, 0.07285968959331512, 0.07127143442630768, 0.06969934701919556, 0.06814350187778473, 0.06660393625497818, 0.06508072465658188, 0.0635739266872406, 0.06208358332514763, 0.060609761625528336, 0.0591525137424469, 0.057711899280548096, 0.056287966668605804, 0.0548807755112648, 0.053490374237298965, 0.052116815000772476, 0.05076014995574951, 0.04942043498158455, 0.04809771478176117, 0.04679204523563385, 0.045503467321395874, 0.04423204064369202, 0.04297780245542526, 0.04174080491065979, 0.04052109271287918, 0.039318718016147614, 0.03813371807336807, 0.03696614131331444, 0.03581603243947029, 0.034683436155319214, 0.03356838971376419, 0.0324709415435791, 0.03139112517237663, 0.030328990891575813, 0.02928457222878933, 0.028257910162210464, 0.027249043807387352, 0.026258012279868126, 0.02528485096991062, 0.024329597130417824, 0.023392286151647568, 0.022472955286502838, 0.02157163806259632, 0.020688369870185852, 0.01982318051159382, 0.018976107239723206, 0.01814717799425125, 0.017336426302790642, 0.016543881967663765, 0.01576957479119301, 0.015013535507023335, 0.014275790192186832, 0.01355636864900589, 0.012855296023190022, 0.01217260118573904, 0.011508308351039886, 0.010862442664802074, 0.010235029272735119, 0.009626091457903385, 0.009035651572048664, 0.008463731966912746, 0.007910354994237423, 0.0073755416087806225, 0.006859311368316412, 0.006361683830618858, 0.005882677622139454, 0.005422311369329691, 0.0049806018359959126, 0.004557565785944462, 0.0041532195173203945, 0.003767578396946192, 0.0034006566274911165, 0.0030524679459631443, 0.0027230256237089634, 0.002412342233583331, 0.0021204291842877865, 0.0018472978845238686, 0.0015929584624245763, 0.0013574203476309776, 0.001140692620538175, 0.0009427834302186966, 0.000763700227253139, 0.0006034497055225074, 0.0004620379477273673, 0.0003394703380763531, 0.0002357514458708465, 0.00015088518557604402, 8.487478771712631e-05, 3.7722722481703386e-05, 9.430768841411918e-06, 0 ] ================================================ FILE: __tests__/data/hanning128.json ================================================ [ 0, 0.0006117919110693038, 0.002445670310407877, 0.005497147794812918, 0.00975875649601221, 0.015220067463815212, 0.021867716684937477, 0.029685435816645622, 0.03865409269928932, 0.04875174164772034, 0.05995366722345352, 0.07223246246576309, 0.08555807918310165, 0.09989789873361588, 0.11521684378385544, 0.13147741556167603, 0.14863981306552887, 0.1666620522737503, 0.18550002574920654, 0.205107644200325, 0.22543691098690033, 0.24643807113170624, 0.26805973052978516, 0.2902490198612213, 0.31295156478881836, 0.3361118733882904, 0.35967323184013367, 0.38357800245285034, 0.4077676832675934, 0.43218305706977844, 0.4567644000053406, 0.48145154118537903, 0.5061841011047363, 0.5309014916419983, 0.5555432438850403, 0.5800490975379944, 0.6043590903282166, 0.6284136772155762, 0.6521539688110352, 0.675521969795227, 0.6984604001045227, 0.7209132313728333, 0.7428253889083862, 0.7641433477401733, 0.7848148345947266, 0.8047894239425659, 0.8240180611610413, 0.8424538373947144, 0.8600515723228455, 0.876768171787262, 0.892562747001648, 0.907396674156189, 0.921233594417572, 0.9340397119522095, 0.9457836747169495, 0.9564367532730103, 0.9659727811813354, 0.9743685722351074, 0.9816034436225891, 0.9876598119735718, 0.9925227165222168, 0.9961804151535034, 0.9986238479614258, 0.9998470544815063, 0.9998470544815063, 0.9986238479614258, 0.9961804151535034, 0.9925227165222168, 0.9876598119735718, 0.9816034436225891, 0.9743685722351074, 0.9659727811813354, 0.9564367532730103, 0.9457836747169495, 0.9340397119522095, 0.921233594417572, 0.907396674156189, 0.892562747001648, 0.876768171787262, 0.8600515723228455, 0.8424538373947144, 0.8240180611610413, 0.8047894239425659, 0.7848148345947266, 0.7641433477401733, 0.7428253889083862, 0.7209132313728333, 0.6984604001045227, 0.675521969795227, 0.6521539688110352, 0.6284136772155762, 0.6043590903282166, 0.5800490975379944, 0.5555432438850403, 0.5309014916419983, 0.5061841011047363, 0.48145154118537903, 0.4567644000053406, 0.43218305706977844, 0.4077676832675934, 0.38357800245285034, 0.35967323184013367, 0.3361118733882904, 0.31295156478881836, 0.2902490198612213, 0.26805973052978516, 0.24643807113170624, 0.22543691098690033, 0.205107644200325, 0.18550002574920654, 0.1666620522737503, 0.14863981306552887, 0.13147741556167603, 0.11521684378385544, 0.09989789873361588, 0.08555807918310165, 0.07223246246576309, 0.05995366722345352, 0.04875174164772034, 0.03865409269928932, 0.029685435816645622, 0.021867716684937477, 0.015220067463815212, 0.00975875649601221, 0.005497147794812918, 0.002445670310407877, 0.0006117919110693038, 0 ] ================================================ FILE: __tests__/data/hanning2048.json ================================================ [ 0, 2.355394826736301e-06, 9.421557479072362e-06, 2.1198420654400252e-05, 3.7685873394366354e-05, 5.888376108487137e-05, 8.47918854560703e-05, 0.00011540999548742548, 0.00015073781833052635, 0.00019077499746344984, 0.00023552117636427283, 0.0002849759184755385, 0.00033913878723978996, 0.00039800922968424857, 0.0004615867219399661, 0.0005298706237226725, 0.0006028603529557586, 0.000680555182043463, 0.0007629544124938548, 0.0008500572293996811, 0.0009418628178536892, 0.0010383703047409654, 0.0011395788751542568, 0.0012454874813556671, 0.0013560950756072998, 0.0014714007265865803, 0.0015914032701402903, 0.0017161016585305333, 0.0018454946111887693, 0.001979581080377102, 0.0021183595526963472, 0.002261828863993287, 0.0024099876172840595, 0.0025628346484154463, 0.002720368094742298, 0.002882586792111397, 0.0030494893435388803, 0.003221073653548956, 0.0033973385579884052, 0.003578282194212079, 0.003763902932405472, 0.003954199142754078, 0.004149168264120817, 0.004348809830844402, 0.0045531210489571095, 0.004762100055813789, 0.0049757445231080055, 0.005194053519517183, 0.005417024251073599, 0.005644654855132103, 0.005876942537724972, 0.006113885901868343, 0.006355482619255781, 0.006601730361580849, 0.006852626334875822, 0.007108168676495552, 0.007368355058133602, 0.0076331826858222485, 0.007902649231255054, 0.008176751434803009, 0.00845548789948225, 0.008738855831325054, 0.009026852436363697, 0.00931947398930788, 0.009616718627512455, 0.009918583557009697, 0.010225065983831882, 0.010536163114011288, 0.010851871222257614, 0.011172188445925713, 0.01149711012840271, 0.011826635338366032, 0.012160759419202805, 0.012499479576945305, 0.012842793017625809, 0.013190696947276592, 0.013543186709284782, 0.013900259509682655, 0.014261912554502487, 0.014628141187131405, 0.01499894354492426, 0.015374314971268177, 0.015754252672195435, 0.016138752922415733, 0.0165278110653162, 0.016921425238251686, 0.017319589853286743, 0.017722303047776222, 0.018129559233784676, 0.018541356548666954, 0.01895768940448761, 0.019378554075956345, 0.01980394683778286, 0.020233863964676857, 0.020668301731348038, 0.021107254549860954, 0.021550720557570457, 0.0219986941665411, 0.022451169788837433, 0.022908145561814308, 0.023369617760181427, 0.023835578933358192, 0.024306025356054306, 0.02478095516562462, 0.025260362774133682, 0.02574424259364605, 0.026232589036226273, 0.02672540210187435, 0.02722267247736454, 0.02772439643740654, 0.028230570256710052, 0.02874119020998478, 0.029256248846650124, 0.029775744304060936, 0.03029966913163662, 0.030828017741441727, 0.03136079013347626, 0.03189797326922417, 0.032439570873975754, 0.03298557177186012, 0.033535972237586975, 0.03409076854586601, 0.03464995324611664, 0.03521352261304855, 0.03578147292137146, 0.03635379299521446, 0.03693048655986786, 0.037511538714170456, 0.03809694945812225, 0.038686711341142654, 0.03928082063794136, 0.039879269897937775, 0.0404820553958416, 0.041089169681072235, 0.041700609028339386, 0.042316365987062454, 0.04293643310666084, 0.043560806661844254, 0.04418947920203209, 0.04482245072722435, 0.04545970633625984, 0.046101246029138565, 0.04674706235527992, 0.047397151589393616, 0.04805150255560875, 0.048710111528635025, 0.049372971057891846, 0.05004007741808891, 0.05071142315864563, 0.0513870045542717, 0.05206681042909622, 0.052750833332538605, 0.053439073264598846, 0.05413152277469635, 0.05482817068696022, 0.05552900955080986, 0.05623403936624527, 0.05694325268268585, 0.05765663459897041, 0.05837418884038925, 0.059095900505781174, 0.05982176959514618, 0.060551781207323074, 0.06128593906760216, 0.06202422454953194, 0.06276664137840271, 0.06351317465305328, 0.06426382064819336, 0.06501857191324234, 0.06577742099761963, 0.06654036045074463, 0.06730739027261734, 0.06807848811149597, 0.06885366141796112, 0.06963289529085159, 0.07041618227958679, 0.07120351493358612, 0.07199489325284958, 0.07279029488563538, 0.07358972728252411, 0.07439318299293518, 0.0752006396651268, 0.07601210474967957, 0.07682755589485168, 0.07764700055122375, 0.07847042381763458, 0.07929781824350357, 0.08012917637825012, 0.08096449077129364, 0.08180375397205353, 0.08264695852994919, 0.08349408954381943, 0.08434514701366425, 0.08520012348890305, 0.08605900406837463, 0.08692178875207901, 0.08778846263885498, 0.08865901827812195, 0.08953344821929932, 0.09041175246238708, 0.09129390865564346, 0.09217992424964905, 0.09306977689266205, 0.09396345913410187, 0.0948609709739685, 0.09576230496168137, 0.09666743874549866, 0.09757637977600098, 0.09848910570144653, 0.09940561652183533, 0.10032590478658676, 0.10124995559453964, 0.10217776149511337, 0.10310932248830795, 0.10404461622238159, 0.10498364269733429, 0.10592639446258545, 0.10687285661697388, 0.10782301425933838, 0.10877687484025955, 0.1097344234585762, 0.11069564521312714, 0.11166054010391235, 0.11262908577919006, 0.11360128223896027, 0.11457712203264236, 0.11555659770965576, 0.11653968691825867, 0.11752639710903168, 0.118516705930233, 0.11951060593128204, 0.1205080971121788, 0.12150915712118149, 0.1225137859582901, 0.12352197617292404, 0.12453370541334152, 0.12554897367954254, 0.1265677809715271, 0.1275900900363922, 0.12861591577529907, 0.1296452432870865, 0.13067805767059326, 0.1317143440246582, 0.1327541172504425, 0.13379733264446259, 0.13484400510787964, 0.13589411973953247, 0.1369476616382599, 0.1380046308040619, 0.13906501233577728, 0.14012877643108368, 0.14119595289230347, 0.14226649701595306, 0.14334040880203247, 0.1444176882505417, 0.14549832046031952, 0.14658229053020477, 0.14766958355903625, 0.14876019954681396, 0.1498541235923767, 0.1509513556957245, 0.1520518660545349, 0.15315565466880798, 0.1542627215385437, 0.15537303686141968, 0.1564866006374359, 0.1576033979654312, 0.15872342884540558, 0.15984666347503662, 0.16097311675548553, 0.16210275888442993, 0.16323557496070862, 0.1643715798854828, 0.16551074385643005, 0.16665305197238922, 0.1677985042333603, 0.16894708573818207, 0.17009878158569336, 0.17125359177589417, 0.1724115014076233, 0.17357249557971954, 0.17473655939102173, 0.17590369284152985, 0.1770738810300827, 0.1782471090555191, 0.17942336201667786, 0.18060263991355896, 0.18178492784500122, 0.18297022581100464, 0.18415848910808563, 0.1853497475385666, 0.18654395639896393, 0.18774113059043884, 0.18894124031066895, 0.19014427065849304, 0.19135023653507233, 0.1925591081380844, 0.1937708705663681, 0.1949855238199234, 0.19620303809642792, 0.19742342829704285, 0.1986466646194458, 0.19987273216247559, 0.2011016458272934, 0.20233336091041565, 0.20356787741184235, 0.2048051953315735, 0.20604529976844788, 0.20728816092014313, 0.20853379368782043, 0.20978215336799622, 0.21103326976299286, 0.21228709816932678, 0.2135436236858368, 0.21480286121368408, 0.21606479585170746, 0.21732939779758453, 0.2185966521501541, 0.2198665738105774, 0.2211391180753708, 0.2224142998456955, 0.22369210422039032, 0.22497250139713287, 0.22625549137592316, 0.22754105925559998, 0.22882919013500214, 0.23011988401412964, 0.2314131259918213, 0.2327088862657547, 0.23400716483592987, 0.2353079617023468, 0.2366112321615219, 0.2379170060157776, 0.23922523856163025, 0.2405359297990799, 0.24184906482696533, 0.24316462874412537, 0.24448262155056, 0.24580301344394684, 0.2471258044242859, 0.24845096468925476, 0.24977850914001465, 0.25110840797424316, 0.2524406611919403, 0.2537752389907837, 0.2551121413707733, 0.2564513385295868, 0.2577928304672241, 0.2591366171836853, 0.26048266887664795, 0.2618309557437897, 0.26318150758743286, 0.2645342946052551, 0.2658892869949341, 0.2672465145587921, 0.26860588788986206, 0.2699674665927887, 0.27133122086524963, 0.2726971209049225, 0.27406516671180725, 0.27543532848358154, 0.27680763602256775, 0.2781819999217987, 0.2795584797859192, 0.2809370458126068, 0.2823176681995392, 0.2837003469467163, 0.2850850522518158, 0.28647178411483765, 0.2878605127334595, 0.28925126791000366, 0.29064399003982544, 0.2920387089252472, 0.29343536496162415, 0.2948339581489563, 0.29623451828956604, 0.2976369559764862, 0.2990413308143616, 0.30044758319854736, 0.30185574293136597, 0.3032657504081726, 0.3046776056289673, 0.30609130859375, 0.30750682950019836, 0.3089241683483124, 0.31034332513809204, 0.3117642402648926, 0.3131869435310364, 0.31461140513420105, 0.3160376250743866, 0.31746554374694824, 0.31889522075653076, 0.3203265964984894, 0.3217596411705017, 0.32319438457489014, 0.3246307969093323, 0.32606884837150574, 0.3275085389614105, 0.32894986867904663, 0.3303928077220917, 0.33183732628822327, 0.3332834541797638, 0.3347311317920685, 0.3361803889274597, 0.3376311659812927, 0.3390834927558899, 0.34053730964660645, 0.34199264645576477, 0.3434494733810425, 0.3449077606201172, 0.3463675379753113, 0.34782874584198, 0.3492913842201233, 0.3507554531097412, 0.35222092270851135, 0.35368776321411133, 0.3551560044288635, 0.35662561655044556, 0.35809656977653503, 0.35956886410713196, 0.36104246973991394, 0.362517386674881, 0.3639936149120331, 0.36547109484672546, 0.3669498860836029, 0.36842989921569824, 0.36991116404533386, 0.3713936507701874, 0.3728773295879364, 0.3743622303009033, 0.37584832310676575, 0.3773355484008789, 0.3788239657878876, 0.380313515663147, 0.3818041980266571, 0.3832959830760956, 0.3847888708114624, 0.3862828314304352, 0.3877778649330139, 0.3892739713191986, 0.39077112078666687, 0.3922692835330963, 0.3937684893608093, 0.39526867866516113, 0.39676985144615173, 0.39827200770378113, 0.39977508783340454, 0.40127915143966675, 0.402784138917923, 0.40429002046585083, 0.4057968258857727, 0.4073045253753662, 0.40881308913230896, 0.41032248735427856, 0.4118327498435974, 0.4133438467979431, 0.4148557484149933, 0.4163684844970703, 0.41788196563720703, 0.4193962514400482, 0.4209112823009491, 0.42242705821990967, 0.42394357919692993, 0.4254607856273651, 0.42697873711586, 0.4284973442554474, 0.4300166368484497, 0.43153658509254456, 0.43305718898773193, 0.43457841873168945, 0.4361002445220947, 0.43762269616127014, 0.4391457140445709, 0.44066932797431946, 0.44219350814819336, 0.44371819496154785, 0.4452434480190277, 0.44676920771598816, 0.4482954442501068, 0.44982218742370605, 0.4513494074344635, 0.45287707448005676, 0.4544052183628082, 0.45593374967575073, 0.45746272802352905, 0.4589920938014984, 0.4605218470096588, 0.46205195784568787, 0.46358242630958557, 0.46511325240135193, 0.46664440631866455, 0.46817588806152344, 0.4697076380252838, 0.47123968601226807, 0.4727720022201538, 0.47430458664894104, 0.4758374094963074, 0.4773704707622528, 0.47890371084213257, 0.48043718934059143, 0.48197081685066223, 0.48350465297698975, 0.4850386083126068, 0.4865727126598358, 0.48810696601867676, 0.48964130878448486, 0.4911757707595825, 0.49271029233932495, 0.49424490332603455, 0.49577954411506653, 0.4973142445087433, 0.49884894490242004, 0.5003836750984192, 0.5019184350967407, 0.5034531354904175, 0.5049877762794495, 0.5065224170684814, 0.5080569982528687, 0.5095914602279663, 0.5111258625984192, 0.5126601457595825, 0.5141943693161011, 0.5157284140586853, 0.5172622799873352, 0.5187960267066956, 0.5203295946121216, 0.5218629240989685, 0.5233960747718811, 0.5249290466308594, 0.5264617204666138, 0.5279941558837891, 0.5295263528823853, 0.5310582518577576, 0.5325899124145508, 0.5341212153434753, 0.535652220249176, 0.5371828675270081, 0.5387131571769714, 0.5402430891990662, 0.5417726635932922, 0.5433018207550049, 0.5448305606842041, 0.5463588833808899, 0.5478867888450623, 0.5494142770767212, 0.5509412288665771, 0.5524677634239197, 0.5539937615394592, 0.5555192232131958, 0.5570442080497742, 0.5585686564445496, 0.560092568397522, 0.5616158843040466, 0.5631386041641235, 0.5646607279777527, 0.5661822557449341, 0.5677031874656677, 0.5692234635353088, 0.5707430839538574, 0.5722620487213135, 0.5737802982330322, 0.5752978920936584, 0.5768147706985474, 0.578330934047699, 0.5798463225364685, 0.5813609957695007, 0.5828748941421509, 0.5843879580497742, 0.5859003067016602, 0.5874118208885193, 0.5889225006103516, 0.590432345867157, 0.5919412970542908, 0.5934494137763977, 0.5949566960334778, 0.5964630246162415, 0.5979684591293335, 0.5994729995727539, 0.6009765863418579, 0.6024792194366455, 0.6039808392524719, 0.6054815649986267, 0.6069812178611755, 0.608479917049408, 0.6099776029586792, 0.6114742159843445, 0.6129697561264038, 0.614464282989502, 0.6159577369689941, 0.6174500584602356, 0.6189413070678711, 0.6204314231872559, 0.6219204068183899, 0.6234081983566284, 0.6248948574066162, 0.6263803839683533, 0.62786465883255, 0.6293477416038513, 0.6308296322822571, 0.6323102712631226, 0.6337896585464478, 0.6352677941322327, 0.6367446780204773, 0.6382202506065369, 0.6396945118904114, 0.6411674618721008, 0.6426391005516052, 0.6441093683242798, 0.6455782651901245, 0.6470458507537842, 0.6485120058059692, 0.6499767899513245, 0.6514401435852051, 0.6529020667076111, 0.6543624997138977, 0.6558215618133545, 0.6572791337966919, 0.6587352156639099, 0.6601898074150085, 0.661642849445343, 0.6630944013595581, 0.6645444631576538, 0.6659929156303406, 0.6674398183822632, 0.6688851118087769, 0.6703288555145264, 0.6717709898948669, 0.6732115149497986, 0.6746503710746765, 0.6760876178741455, 0.6775231957435608, 0.6789571046829224, 0.6803892850875854, 0.6818198561668396, 0.6832486391067505, 0.6846756935119629, 0.6861010193824768, 0.6875246167182922, 0.6889464259147644, 0.6903665065765381, 0.6917847394943237, 0.6932011842727661, 0.6946157813072205, 0.6960285305976868, 0.6974394917488098, 0.6988485455513, 0.7002557516098022, 0.7016611099243164, 0.703064501285553, 0.7044659852981567, 0.7058655619621277, 0.7072632312774658, 0.7086588740348816, 0.7100526094436646, 0.7114443778991699, 0.7128341197967529, 0.7142218351364136, 0.7156075835227966, 0.7169912457466125, 0.7183728814125061, 0.7197524905204773, 0.7211300134658813, 0.7225054502487183, 0.723878800868988, 0.7252500057220459, 0.7266191244125366, 0.7279860973358154, 0.7293509244918823, 0.7307136058807373, 0.7320740818977356, 0.7334323525428772, 0.7347884774208069, 0.7361423969268799, 0.7374940514564514, 0.7388434410095215, 0.7401906251907349, 0.7415355443954468, 0.7428781986236572, 0.7442185282707214, 0.7455565929412842, 0.7468923330307007, 0.748225748538971, 0.749556839466095, 0.750885546207428, 0.7522119283676147, 0.7535358667373657, 0.7548574805259705, 0.7561766505241394, 0.7574934363365173, 0.7588078379631042, 0.7601197361946106, 0.7614291906356812, 0.7627362012863159, 0.7640407085418701, 0.7653427720069885, 0.7666422724723816, 0.7679393291473389, 0.7692338228225708, 0.7705257534980774, 0.7718151807785034, 0.7731020450592041, 0.7743863463401794, 0.7756680250167847, 0.7769471406936646, 0.7782236337661743, 0.779497504234314, 0.7807686924934387, 0.7820373177528381, 0.7833032608032227, 0.7845665216445923, 0.785827100276947, 0.7870849967002869, 0.788340151309967, 0.7895926237106323, 0.7908423542976379, 0.7920893430709839, 0.7933335900306702, 0.7945750951766968, 0.795813798904419, 0.7970497012138367, 0.7982828617095947, 0.7995131611824036, 0.800740659236908, 0.8019652962684631, 0.8031871318817139, 0.8044061064720154, 0.8056221604347229, 0.8068353533744812, 0.8080456852912903, 0.8092530965805054, 0.8104575872421265, 0.8116591572761536, 0.8128578066825867, 0.8140535354614258, 0.8152462244033813, 0.8164359927177429, 0.8176227807998657, 0.8188065886497498, 0.8199873566627502, 0.821165144443512, 0.8223398923873901, 0.8235116004943848, 0.8246802687644958, 0.8258458375930786, 0.8270083665847778, 0.8281678557395935, 0.8293241858482361, 0.8304774761199951, 0.831627607345581, 0.8327746391296387, 0.8339185118675232, 0.8350592255592346, 0.8361968398094177, 0.837331235408783, 0.8384624719619751, 0.8395904898643494, 0.8407153487205505, 0.8418369889259338, 0.8429554104804993, 0.8440706133842468, 0.8451825380325317, 0.8462912440299988, 0.8473966717720032, 0.8484988212585449, 0.849597692489624, 0.8506932258605957, 0.8517855405807495, 0.8528744578361511, 0.8539600968360901, 0.8550423979759216, 0.8561213612556458, 0.8571969866752625, 0.858269214630127, 0.8593380451202393, 0.8604035377502441, 0.8614656329154968, 0.8625242710113525, 0.863579511642456, 0.8646313548088074, 0.8656797409057617, 0.8667247295379639, 0.8677662014961243, 0.8688042163848877, 0.8698387742042542, 0.8708698749542236, 0.8718974590301514, 0.8729215264320374, 0.8739420771598816, 0.8749591112136841, 0.8759726285934448, 0.876982569694519, 0.8779889941215515, 0.8789918422698975, 0.8799911141395569, 0.8809868097305298, 0.8819789290428162, 0.8829674124717712, 0.8839523196220398, 0.884933590888977, 0.885911226272583, 0.8868852853775024, 0.8878556489944458, 0.8888223767280579, 0.8897854089736938, 0.8907448053359985, 0.8917005062103271, 0.8926525115966797, 0.8936008214950562, 0.8945454359054565, 0.8954863548278809, 0.8964235186576843, 0.8973569273948669, 0.8982865810394287, 0.8992125391960144, 0.9001346826553345, 0.9010531306266785, 0.9019677042961121, 0.9028785824775696, 0.9037855863571167, 0.904688835144043, 0.9055882692337036, 0.9064838886260986, 0.9073756337165833, 0.9082635641098022, 0.9091476798057556, 0.9100278615951538, 0.9109042286872864, 0.9117767214775085, 0.9126453399658203, 0.9135100841522217, 0.9143709540367126, 0.9152278304100037, 0.916080892086029, 0.9169299602508545, 0.9177751541137695, 0.9186163544654846, 0.9194536805152893, 0.920287013053894, 0.9211163520812988, 0.9219417572021484, 0.9227632284164429, 0.9235806465148926, 0.9243941307067871, 0.9252035617828369, 0.9260090589523315, 0.9268105030059814, 0.9276078939437866, 0.9284012913703918, 0.9291906356811523, 0.9299759864807129, 0.9307572245597839, 0.9315344095230103, 0.9323075413703918, 0.9330766201019287, 0.9338416457176208, 0.9346024990081787, 0.9353592991828918, 0.9361119866371155, 0.9368606209754944, 0.937605082988739, 0.9383454322814941, 0.9390816688537598, 0.9398137331008911, 0.940541684627533, 0.9412654638290405, 0.9419851303100586, 0.9427005648612976, 0.9434118866920471, 0.9441189765930176, 0.9448219537734985, 0.9455206990242004, 0.9462152123451233, 0.9469055533409119, 0.9475917220115662, 0.9482735991477966, 0.9489513039588928, 0.94962477684021, 0.950294017791748, 0.9509589672088623, 0.9516197443008423, 0.9522762298583984, 0.9529284238815308, 0.953576385974884, 0.9542200565338135, 0.9548594355583191, 0.9554945826530457, 0.9561253786087036, 0.9567519426345825, 0.9573741555213928, 0.9579920768737793, 0.9586056470870972, 0.9592149257659912, 0.9598198533058167, 0.9604204893112183, 0.9610167741775513, 0.9616087079048157, 0.9621962904930115, 0.9627795219421387, 0.9633584022521973, 0.9639329314231873, 0.9645030498504639, 0.9650688171386719, 0.9656301736831665, 0.9661871790885925, 0.9667397737503052, 0.9672879576683044, 0.9678317904472351, 0.9683711528778076, 0.9689061641693115, 0.9694367051124573, 0.9699628353118896, 0.9704845547676086, 0.9710018634796143, 0.9715147018432617, 0.972023069858551, 0.972527027130127, 0.9730265140533447, 0.9735215902328491, 0.9740121364593506, 0.9744982719421387, 0.9749798774719238, 0.9754570722579956, 0.9759297370910645, 0.9763979911804199, 0.9768616557121277, 0.9773209095001221, 0.9777756333351135, 0.978225827217102, 0.9786715507507324, 0.9791128039360046, 0.9795494675636292, 0.9799816608428955, 0.9804093241691589, 0.9808324575424194, 0.981251060962677, 0.9816651344299316, 0.9820746183395386, 0.9824796319007874, 0.9828800559043884, 0.9832759499549866, 0.9836673140525818, 0.9840540885925293, 0.9844362735748291, 0.984813928604126, 0.9851870536804199, 0.9855555295944214, 0.9859194755554199, 0.9862788319587708, 0.9866336584091187, 0.9869838356971741, 0.9873294234275818, 0.9876704812049866, 0.9880068898200989, 0.9883387088775635, 0.9886659383773804, 0.9889885187149048, 0.9893065690994263, 0.9896199703216553, 0.9899287223815918, 0.9902329444885254, 0.9905324578285217, 0.9908274412155151, 0.9911177158355713, 0.9914034008979797, 0.9916844367980957, 0.991960883140564, 0.9922326803207397, 0.992499828338623, 0.9927623271942139, 0.9930201768875122, 0.9932733774185181, 0.9935219883918762, 0.9937658905982971, 0.9940051436424255, 0.9942398071289062, 0.9944697618484497, 0.9946950674057007, 0.9949156641960144, 0.9951316714286804, 0.9953429698944092, 0.9955496191978455, 0.9957516193389893, 0.9959489107131958, 0.9961415529251099, 0.9963294863700867, 0.996512770652771, 0.9966914057731628, 0.9968653321266174, 0.9970345497131348, 0.9971991181373596, 0.9973589777946472, 0.9975141882896423, 0.9976646900177002, 0.9978104829788208, 0.9979516267776489, 0.9980880618095398, 0.9982197880744934, 0.9983468055725098, 0.9984691739082336, 0.9985868334770203, 0.9986997842788696, 0.9988080263137817, 0.9989116191864014, 0.999010443687439, 0.9991046190261841, 0.9991940855979919, 0.9992788434028625, 0.9993588924407959, 0.999434232711792, 0.9995048642158508, 0.9995707869529724, 0.9996320009231567, 0.9996885061264038, 0.9997403621673584, 0.999787449836731, 0.9998298287391663, 0.9998674988746643, 0.9999004602432251, 0.9999287724494934, 0.9999523162841797, 0.9999711513519287, 0.9999852776527405, 0.999994695186615, 0.9999994039535522, 0.9999994039535522, 0.999994695186615, 0.9999852776527405, 0.9999711513519287, 0.9999523162841797, 0.9999287724494934, 0.9999004602432251, 0.9998674988746643, 0.9998298287391663, 0.999787449836731, 0.9997403621673584, 0.9996885061264038, 0.9996320009231567, 0.9995707869529724, 0.9995048642158508, 0.999434232711792, 0.9993588924407959, 0.9992788434028625, 0.9991940855979919, 0.9991046190261841, 0.999010443687439, 0.9989116191864014, 0.9988080263137817, 0.9986997842788696, 0.9985868334770203, 0.9984691739082336, 0.9983468055725098, 0.9982197880744934, 0.9980880618095398, 0.9979516267776489, 0.9978104829788208, 0.9976646900177002, 0.9975141882896423, 0.9973589777946472, 0.9971991181373596, 0.9970345497131348, 0.9968653321266174, 0.9966914057731628, 0.996512770652771, 0.9963294863700867, 0.9961415529251099, 0.9959489107131958, 0.9957516193389893, 0.9955496191978455, 0.9953429698944092, 0.9951316714286804, 0.9949156641960144, 0.9946950674057007, 0.9944697618484497, 0.9942398071289062, 0.9940051436424255, 0.9937658905982971, 0.9935219883918762, 0.9932733774185181, 0.9930201768875122, 0.9927623271942139, 0.992499828338623, 0.9922326803207397, 0.991960883140564, 0.9916844367980957, 0.9914034008979797, 0.9911177158355713, 0.9908274412155151, 0.9905324578285217, 0.9902329444885254, 0.9899287223815918, 0.9896199703216553, 0.9893065690994263, 0.9889885187149048, 0.9886659383773804, 0.9883387088775635, 0.9880068898200989, 0.9876704812049866, 0.9873294234275818, 0.9869838356971741, 0.9866336584091187, 0.9862788319587708, 0.9859194755554199, 0.9855555295944214, 0.9851870536804199, 0.984813928604126, 0.9844362735748291, 0.9840540885925293, 0.9836673140525818, 0.9832759499549866, 0.9828800559043884, 0.9824796319007874, 0.9820746183395386, 0.9816651344299316, 0.981251060962677, 0.9808324575424194, 0.9804093241691589, 0.9799816608428955, 0.9795494675636292, 0.9791128039360046, 0.9786715507507324, 0.978225827217102, 0.9777756333351135, 0.9773209095001221, 0.9768616557121277, 0.9763979911804199, 0.9759297370910645, 0.9754570722579956, 0.9749798774719238, 0.9744982719421387, 0.9740121364593506, 0.9735215902328491, 0.9730265140533447, 0.972527027130127, 0.972023069858551, 0.9715147018432617, 0.9710018634796143, 0.9704845547676086, 0.9699628353118896, 0.9694367051124573, 0.9689061641693115, 0.9683711528778076, 0.9678317904472351, 0.9672879576683044, 0.9667397737503052, 0.9661871790885925, 0.9656301736831665, 0.9650688171386719, 0.9645030498504639, 0.9639329314231873, 0.9633584022521973, 0.9627795219421387, 0.9621962904930115, 0.9616087079048157, 0.9610167741775513, 0.9604204893112183, 0.9598198533058167, 0.9592149257659912, 0.9586056470870972, 0.9579920768737793, 0.9573741555213928, 0.9567519426345825, 0.9561253786087036, 0.9554945826530457, 0.9548594355583191, 0.9542200565338135, 0.953576385974884, 0.9529284238815308, 0.9522762298583984, 0.9516197443008423, 0.9509589672088623, 0.950294017791748, 0.94962477684021, 0.9489513039588928, 0.9482735991477966, 0.9475917220115662, 0.9469055533409119, 0.9462152123451233, 0.9455206990242004, 0.9448219537734985, 0.9441189765930176, 0.9434118866920471, 0.9427005648612976, 0.9419851303100586, 0.9412654638290405, 0.940541684627533, 0.9398137331008911, 0.9390816688537598, 0.9383454322814941, 0.937605082988739, 0.9368606209754944, 0.9361119866371155, 0.9353592991828918, 0.9346024990081787, 0.9338416457176208, 0.9330766201019287, 0.9323075413703918, 0.9315344095230103, 0.9307572245597839, 0.9299759864807129, 0.9291906356811523, 0.9284012913703918, 0.9276078939437866, 0.9268105030059814, 0.9260090589523315, 0.9252035617828369, 0.9243941307067871, 0.9235806465148926, 0.9227632284164429, 0.9219417572021484, 0.9211163520812988, 0.920287013053894, 0.9194536805152893, 0.9186163544654846, 0.9177751541137695, 0.9169299602508545, 0.916080892086029, 0.9152278304100037, 0.9143709540367126, 0.9135100841522217, 0.9126453399658203, 0.9117767214775085, 0.9109042286872864, 0.9100278615951538, 0.9091476798057556, 0.9082635641098022, 0.9073756337165833, 0.9064838886260986, 0.9055882692337036, 0.904688835144043, 0.9037855863571167, 0.9028785824775696, 0.9019677042961121, 0.9010531306266785, 0.9001346826553345, 0.8992125391960144, 0.8982865810394287, 0.8973569273948669, 0.8964235186576843, 0.8954863548278809, 0.8945454359054565, 0.8936008214950562, 0.8926525115966797, 0.8917005062103271, 0.8907448053359985, 0.8897854089736938, 0.8888223767280579, 0.8878556489944458, 0.8868852853775024, 0.885911226272583, 0.884933590888977, 0.8839523196220398, 0.8829674124717712, 0.8819789290428162, 0.8809868097305298, 0.8799911141395569, 0.8789918422698975, 0.8779889941215515, 0.876982569694519, 0.8759726285934448, 0.8749591112136841, 0.8739420771598816, 0.8729215264320374, 0.8718974590301514, 0.8708698749542236, 0.8698387742042542, 0.8688042163848877, 0.8677662014961243, 0.8667247295379639, 0.8656797409057617, 0.8646313548088074, 0.863579511642456, 0.8625242710113525, 0.8614656329154968, 0.8604035377502441, 0.8593380451202393, 0.858269214630127, 0.8571969866752625, 0.8561213612556458, 0.8550423979759216, 0.8539600968360901, 0.8528744578361511, 0.8517855405807495, 0.8506932258605957, 0.849597692489624, 0.8484988212585449, 0.8473966717720032, 0.8462912440299988, 0.8451825380325317, 0.8440706133842468, 0.8429554104804993, 0.8418369889259338, 0.8407153487205505, 0.8395904898643494, 0.8384624719619751, 0.837331235408783, 0.8361968398094177, 0.8350592255592346, 0.8339185118675232, 0.8327746391296387, 0.831627607345581, 0.8304774761199951, 0.8293241858482361, 0.8281678557395935, 0.8270083665847778, 0.8258458375930786, 0.8246802687644958, 0.8235116004943848, 0.8223398923873901, 0.821165144443512, 0.8199873566627502, 0.8188065886497498, 0.8176227807998657, 0.8164359927177429, 0.8152462244033813, 0.8140535354614258, 0.8128578066825867, 0.8116591572761536, 0.8104575872421265, 0.8092530965805054, 0.8080456852912903, 0.8068353533744812, 0.8056221604347229, 0.8044061064720154, 0.8031871318817139, 0.8019652962684631, 0.800740659236908, 0.7995131611824036, 0.7982828617095947, 0.7970497012138367, 0.795813798904419, 0.7945750951766968, 0.7933335900306702, 0.7920893430709839, 0.7908423542976379, 0.7895926237106323, 0.788340151309967, 0.7870849967002869, 0.785827100276947, 0.7845665216445923, 0.7833032608032227, 0.7820373177528381, 0.7807686924934387, 0.779497504234314, 0.7782236337661743, 0.7769471406936646, 0.7756680250167847, 0.7743863463401794, 0.7731020450592041, 0.7718151807785034, 0.7705257534980774, 0.7692338228225708, 0.7679393291473389, 0.7666422724723816, 0.7653427720069885, 0.7640407085418701, 0.7627362012863159, 0.7614291906356812, 0.7601197361946106, 0.7588078379631042, 0.7574934363365173, 0.7561766505241394, 0.7548574805259705, 0.7535358667373657, 0.7522119283676147, 0.750885546207428, 0.749556839466095, 0.748225748538971, 0.7468923330307007, 0.7455565929412842, 0.7442185282707214, 0.7428781986236572, 0.7415355443954468, 0.7401906251907349, 0.7388434410095215, 0.7374940514564514, 0.7361423969268799, 0.7347884774208069, 0.7334323525428772, 0.7320740818977356, 0.7307136058807373, 0.7293509244918823, 0.7279860973358154, 0.7266191244125366, 0.7252500057220459, 0.723878800868988, 0.7225054502487183, 0.7211300134658813, 0.7197524905204773, 0.7183728814125061, 0.7169912457466125, 0.7156075835227966, 0.7142218351364136, 0.7128341197967529, 0.7114443778991699, 0.7100526094436646, 0.7086588740348816, 0.7072632312774658, 0.7058655619621277, 0.7044659852981567, 0.703064501285553, 0.7016611099243164, 0.7002557516098022, 0.6988485455513, 0.6974394917488098, 0.6960285305976868, 0.6946157813072205, 0.6932011842727661, 0.6917847394943237, 0.6903665065765381, 0.6889464259147644, 0.6875246167182922, 0.6861010193824768, 0.6846756935119629, 0.6832486391067505, 0.6818198561668396, 0.6803892850875854, 0.6789571046829224, 0.6775231957435608, 0.6760876178741455, 0.6746503710746765, 0.6732115149497986, 0.6717709898948669, 0.6703288555145264, 0.6688851118087769, 0.6674398183822632, 0.6659929156303406, 0.6645444631576538, 0.6630944013595581, 0.661642849445343, 0.6601898074150085, 0.6587352156639099, 0.6572791337966919, 0.6558215618133545, 0.6543624997138977, 0.6529020667076111, 0.6514401435852051, 0.6499767899513245, 0.6485120058059692, 0.6470458507537842, 0.6455782651901245, 0.6441093683242798, 0.6426391005516052, 0.6411674618721008, 0.6396945118904114, 0.6382202506065369, 0.6367446780204773, 0.6352677941322327, 0.6337896585464478, 0.6323102712631226, 0.6308296322822571, 0.6293477416038513, 0.62786465883255, 0.6263803839683533, 0.6248948574066162, 0.6234081983566284, 0.6219204068183899, 0.6204314231872559, 0.6189413070678711, 0.6174500584602356, 0.6159577369689941, 0.614464282989502, 0.6129697561264038, 0.6114742159843445, 0.6099776029586792, 0.608479917049408, 0.6069812178611755, 0.6054815649986267, 0.6039808392524719, 0.6024792194366455, 0.6009765863418579, 0.5994729995727539, 0.5979684591293335, 0.5964630246162415, 0.5949566960334778, 0.5934494137763977, 0.5919412970542908, 0.590432345867157, 0.5889225006103516, 0.5874118208885193, 0.5859003067016602, 0.5843879580497742, 0.5828748941421509, 0.5813609957695007, 0.5798463225364685, 0.578330934047699, 0.5768147706985474, 0.5752978920936584, 0.5737802982330322, 0.5722620487213135, 0.5707430839538574, 0.5692234635353088, 0.5677031874656677, 0.5661822557449341, 0.5646607279777527, 0.5631386041641235, 0.5616158843040466, 0.560092568397522, 0.5585686564445496, 0.5570442080497742, 0.5555192232131958, 0.5539937615394592, 0.5524677634239197, 0.5509412288665771, 0.5494142770767212, 0.5478867888450623, 0.5463588833808899, 0.5448305606842041, 0.5433018207550049, 0.5417726635932922, 0.5402430891990662, 0.5387131571769714, 0.5371828675270081, 0.535652220249176, 0.5341212153434753, 0.5325899124145508, 0.5310582518577576, 0.5295263528823853, 0.5279941558837891, 0.5264617204666138, 0.5249290466308594, 0.5233960747718811, 0.5218629240989685, 0.5203295946121216, 0.5187960267066956, 0.5172622799873352, 0.5157284140586853, 0.5141943693161011, 0.5126601457595825, 0.5111258625984192, 0.5095914602279663, 0.5080569982528687, 0.5065224170684814, 0.5049877762794495, 0.5034531354904175, 0.5019184350967407, 0.5003836750984192, 0.49884894490242004, 0.4973142445087433, 0.49577954411506653, 0.49424490332603455, 0.49271029233932495, 0.4911757707595825, 0.48964130878448486, 0.48810696601867676, 0.4865727126598358, 0.4850386083126068, 0.48350465297698975, 0.48197081685066223, 0.48043718934059143, 0.47890371084213257, 0.4773704707622528, 0.4758374094963074, 0.47430458664894104, 0.4727720022201538, 0.47123968601226807, 0.4697076380252838, 0.46817588806152344, 0.46664440631866455, 0.46511325240135193, 0.46358242630958557, 0.46205195784568787, 0.4605218470096588, 0.4589920938014984, 0.45746272802352905, 0.45593374967575073, 0.4544052183628082, 0.45287707448005676, 0.4513494074344635, 0.44982218742370605, 0.4482954442501068, 0.44676920771598816, 0.4452434480190277, 0.44371819496154785, 0.44219350814819336, 0.44066932797431946, 0.4391457140445709, 0.43762269616127014, 0.4361002445220947, 0.43457841873168945, 0.43305718898773193, 0.43153658509254456, 0.4300166368484497, 0.4284973442554474, 0.42697873711586, 0.4254607856273651, 0.42394357919692993, 0.42242705821990967, 0.4209112823009491, 0.4193962514400482, 0.41788196563720703, 0.4163684844970703, 0.4148557484149933, 0.4133438467979431, 0.4118327498435974, 0.41032248735427856, 0.40881308913230896, 0.4073045253753662, 0.4057968258857727, 0.40429002046585083, 0.402784138917923, 0.40127915143966675, 0.39977508783340454, 0.39827200770378113, 0.39676985144615173, 0.39526867866516113, 0.3937684893608093, 0.3922692835330963, 0.39077112078666687, 0.3892739713191986, 0.3877778649330139, 0.3862828314304352, 0.3847888708114624, 0.3832959830760956, 0.3818041980266571, 0.380313515663147, 0.3788239657878876, 0.3773355484008789, 0.37584832310676575, 0.3743622303009033, 0.3728773295879364, 0.3713936507701874, 0.36991116404533386, 0.36842989921569824, 0.3669498860836029, 0.36547109484672546, 0.3639936149120331, 0.362517386674881, 0.36104246973991394, 0.35956886410713196, 0.35809656977653503, 0.35662561655044556, 0.3551560044288635, 0.35368776321411133, 0.35222092270851135, 0.3507554531097412, 0.3492913842201233, 0.34782874584198, 0.3463675379753113, 0.3449077606201172, 0.3434494733810425, 0.34199264645576477, 0.34053730964660645, 0.3390834927558899, 0.3376311659812927, 0.3361803889274597, 0.3347311317920685, 0.3332834541797638, 0.33183732628822327, 0.3303928077220917, 0.32894986867904663, 0.3275085389614105, 0.32606884837150574, 0.3246307969093323, 0.32319438457489014, 0.3217596411705017, 0.3203265964984894, 0.31889522075653076, 0.31746554374694824, 0.3160376250743866, 0.31461140513420105, 0.3131869435310364, 0.3117642402648926, 0.31034332513809204, 0.3089241683483124, 0.30750682950019836, 0.30609130859375, 0.3046776056289673, 0.3032657504081726, 0.30185574293136597, 0.30044758319854736, 0.2990413308143616, 0.2976369559764862, 0.29623451828956604, 0.2948339581489563, 0.29343536496162415, 0.2920387089252472, 0.29064399003982544, 0.28925126791000366, 0.2878605127334595, 0.28647178411483765, 0.2850850522518158, 0.2837003469467163, 0.2823176681995392, 0.2809370458126068, 0.2795584797859192, 0.2781819999217987, 0.27680763602256775, 0.27543532848358154, 0.27406516671180725, 0.2726971209049225, 0.27133122086524963, 0.2699674665927887, 0.26860588788986206, 0.2672465145587921, 0.2658892869949341, 0.2645342946052551, 0.26318150758743286, 0.2618309557437897, 0.26048266887664795, 0.2591366171836853, 0.2577928304672241, 0.2564513385295868, 0.2551121413707733, 0.2537752389907837, 0.2524406611919403, 0.25110840797424316, 0.24977850914001465, 0.24845096468925476, 0.2471258044242859, 0.24580301344394684, 0.24448262155056, 0.24316462874412537, 0.24184906482696533, 0.2405359297990799, 0.23922523856163025, 0.2379170060157776, 0.2366112321615219, 0.2353079617023468, 0.23400716483592987, 0.2327088862657547, 0.2314131259918213, 0.23011988401412964, 0.22882919013500214, 0.22754105925559998, 0.22625549137592316, 0.22497250139713287, 0.22369210422039032, 0.2224142998456955, 0.2211391180753708, 0.2198665738105774, 0.2185966521501541, 0.21732939779758453, 0.21606479585170746, 0.21480286121368408, 0.2135436236858368, 0.21228709816932678, 0.21103326976299286, 0.20978215336799622, 0.20853379368782043, 0.20728816092014313, 0.20604529976844788, 0.2048051953315735, 0.20356787741184235, 0.20233336091041565, 0.2011016458272934, 0.19987273216247559, 0.1986466646194458, 0.19742342829704285, 0.19620303809642792, 0.1949855238199234, 0.1937708705663681, 0.1925591081380844, 0.19135023653507233, 0.19014427065849304, 0.18894124031066895, 0.18774113059043884, 0.18654395639896393, 0.1853497475385666, 0.18415848910808563, 0.18297022581100464, 0.18178492784500122, 0.18060263991355896, 0.17942336201667786, 0.1782471090555191, 0.1770738810300827, 0.17590369284152985, 0.17473655939102173, 0.17357249557971954, 0.1724115014076233, 0.17125359177589417, 0.17009878158569336, 0.16894708573818207, 0.1677985042333603, 0.16665305197238922, 0.16551074385643005, 0.1643715798854828, 0.16323557496070862, 0.16210275888442993, 0.16097311675548553, 0.15984666347503662, 0.15872342884540558, 0.1576033979654312, 0.1564866006374359, 0.15537303686141968, 0.1542627215385437, 0.15315565466880798, 0.1520518660545349, 0.1509513556957245, 0.1498541235923767, 0.14876019954681396, 0.14766958355903625, 0.14658229053020477, 0.14549832046031952, 0.1444176882505417, 0.14334040880203247, 0.14226649701595306, 0.14119595289230347, 0.14012877643108368, 0.13906501233577728, 0.1380046308040619, 0.1369476616382599, 0.13589411973953247, 0.13484400510787964, 0.13379733264446259, 0.1327541172504425, 0.1317143440246582, 0.13067805767059326, 0.1296452432870865, 0.12861591577529907, 0.1275900900363922, 0.1265677809715271, 0.12554897367954254, 0.12453370541334152, 0.12352197617292404, 0.1225137859582901, 0.12150915712118149, 0.1205080971121788, 0.11951060593128204, 0.118516705930233, 0.11752639710903168, 0.11653968691825867, 0.11555659770965576, 0.11457712203264236, 0.11360128223896027, 0.11262908577919006, 0.11166054010391235, 0.11069564521312714, 0.1097344234585762, 0.10877687484025955, 0.10782301425933838, 0.10687285661697388, 0.10592639446258545, 0.10498364269733429, 0.10404461622238159, 0.10310932248830795, 0.10217776149511337, 0.10124995559453964, 0.10032590478658676, 0.09940561652183533, 0.09848910570144653, 0.09757637977600098, 0.09666743874549866, 0.09576230496168137, 0.0948609709739685, 0.09396345913410187, 0.09306977689266205, 0.09217992424964905, 0.09129390865564346, 0.09041175246238708, 0.08953344821929932, 0.08865901827812195, 0.08778846263885498, 0.08692178875207901, 0.08605900406837463, 0.08520012348890305, 0.08434514701366425, 0.08349408954381943, 0.08264695852994919, 0.08180375397205353, 0.08096449077129364, 0.08012917637825012, 0.07929781824350357, 0.07847042381763458, 0.07764700055122375, 0.07682755589485168, 0.07601210474967957, 0.0752006396651268, 0.07439318299293518, 0.07358972728252411, 0.07279029488563538, 0.07199489325284958, 0.07120351493358612, 0.07041618227958679, 0.06963289529085159, 0.06885366141796112, 0.06807848811149597, 0.06730739027261734, 0.06654036045074463, 0.06577742099761963, 0.06501857191324234, 0.06426382064819336, 0.06351317465305328, 0.06276664137840271, 0.06202422454953194, 0.06128593906760216, 0.060551781207323074, 0.05982176959514618, 0.059095900505781174, 0.05837418884038925, 0.05765663459897041, 0.05694325268268585, 0.05623403936624527, 0.05552900955080986, 0.05482817068696022, 0.05413152277469635, 0.053439073264598846, 0.052750833332538605, 0.05206681042909622, 0.0513870045542717, 0.05071142315864563, 0.05004007741808891, 0.049372971057891846, 0.048710111528635025, 0.04805150255560875, 0.047397151589393616, 0.04674706235527992, 0.046101246029138565, 0.04545970633625984, 0.04482245072722435, 0.04418947920203209, 0.043560806661844254, 0.04293643310666084, 0.042316365987062454, 0.041700609028339386, 0.041089169681072235, 0.0404820553958416, 0.039879269897937775, 0.03928082063794136, 0.038686711341142654, 0.03809694945812225, 0.037511538714170456, 0.03693048655986786, 0.03635379299521446, 0.03578147292137146, 0.03521352261304855, 0.03464995324611664, 0.03409076854586601, 0.033535972237586975, 0.03298557177186012, 0.032439570873975754, 0.03189797326922417, 0.03136079013347626, 0.030828017741441727, 0.03029966913163662, 0.029775744304060936, 0.029256248846650124, 0.02874119020998478, 0.028230570256710052, 0.02772439643740654, 0.02722267247736454, 0.02672540210187435, 0.026232589036226273, 0.02574424259364605, 0.025260362774133682, 0.02478095516562462, 0.024306025356054306, 0.023835578933358192, 0.023369617760181427, 0.022908145561814308, 0.022451169788837433, 0.0219986941665411, 0.021550720557570457, 0.021107254549860954, 0.020668301731348038, 0.020233863964676857, 0.01980394683778286, 0.019378554075956345, 0.01895768940448761, 0.018541356548666954, 0.018129559233784676, 0.017722303047776222, 0.017319589853286743, 0.016921425238251686, 0.0165278110653162, 0.016138752922415733, 0.015754252672195435, 0.015374314971268177, 0.01499894354492426, 0.014628141187131405, 0.014261912554502487, 0.013900259509682655, 0.013543186709284782, 0.013190696947276592, 0.012842793017625809, 0.012499479576945305, 0.012160759419202805, 0.011826635338366032, 0.01149711012840271, 0.011172188445925713, 0.010851871222257614, 0.010536163114011288, 0.010225065983831882, 0.009918583557009697, 0.009616718627512455, 0.00931947398930788, 0.009026852436363697, 0.008738855831325054, 0.00845548789948225, 0.008176751434803009, 0.007902649231255054, 0.0076331826858222485, 0.007368355058133602, 0.007108168676495552, 0.006852626334875822, 0.006601730361580849, 0.006355482619255781, 0.006113885901868343, 0.005876942537724972, 0.005644654855132103, 0.005417024251073599, 0.005194053519517183, 0.0049757445231080055, 0.004762100055813789, 0.0045531210489571095, 0.004348809830844402, 0.004149168264120817, 0.003954199142754078, 0.003763902932405472, 0.003578282194212079, 0.0033973385579884052, 0.003221073653548956, 0.0030494893435388803, 0.002882586792111397, 0.002720368094742298, 0.0025628346484154463, 0.0024099876172840595, 0.002261828863993287, 0.0021183595526963472, 0.001979581080377102, 0.0018454946111887693, 0.0017161016585305333, 0.0015914032701402903, 0.0014714007265865803, 0.0013560950756072998, 0.0012454874813556671, 0.0011395788751542568, 0.0010383703047409654, 0.0009418628178536892, 0.0008500572293996811, 0.0007629544124938548, 0.000680555182043463, 0.0006028603529557586, 0.0005298706237226725, 0.0004615867219399661, 0.00039800922968424857, 0.00033913878723978996, 0.0002849759184755385, 0.00023552117636427283, 0.00019077499746344984, 0.00015073781833052635, 0.00011540999548742548, 8.47918854560703e-05, 5.888376108487137e-05, 3.7685873394366354e-05, 2.1198420654400252e-05, 9.421557479072362e-06, 2.355394826736301e-06, 0 ] ================================================ FILE: __tests__/data/hanning256.json ================================================ [ 0, 0.00015177401655819267, 0.0006070039235055447, 0.0013654133072122931, 0.0024265418760478497, 0.003789745271205902, 0.005454195663332939, 0.007418883498758078, 0.009682614356279373, 0.01224401593208313, 0.015101531520485878, 0.018253426998853683, 0.021697789430618286, 0.0254325270652771, 0.02945537306368351, 0.033763885498046875, 0.038355447351932526, 0.04322727024555206, 0.04837640002369881, 0.05379970744252205, 0.05949390307068825, 0.06545552611351013, 0.0716809630393982, 0.0781664252281189, 0.08490798622369766, 0.09190154075622559, 0.09914285689592361, 0.10662753134965897, 0.11435101926326752, 0.1223086342215538, 0.13049554824829102, 0.13890677690505981, 0.1475372314453125, 0.15638165175914764, 0.16543470323085785, 0.174690842628479, 0.1841444969177246, 0.19378989934921265, 0.20362119376659393, 0.21363243460655212, 0.22381751239299774, 0.23417027294635773, 0.2446843981742859, 0.25535354018211365, 0.2661712169647217, 0.2771308124065399, 0.2882257401943207, 0.29944923520088196, 0.310794472694397, 0.32225459814071655, 0.3338226079940796, 0.345491498708725, 0.3572542071342468, 0.3691035807132721, 0.38103240728378296, 0.3930334448814392, 0.40509945154190063, 0.4172230660915375, 0.42939692735671997, 0.44161364436149597, 0.45386582612991333, 0.46614599227905273, 0.47844672203063965, 0.49076053500175476, 0.5030799508094788, 0.5153975486755371, 0.527705729007721, 0.5399971008300781, 0.5522642135620117, 0.5644996166229248, 0.5766957998275757, 0.5888454914093018, 0.6009411811828613, 0.6129756569862366, 0.6249414682388306, 0.636831521987915, 0.6486384272575378, 0.6603550910949707, 0.6719744801521301, 0.6834893822669983, 0.694892942905426, 0.7061781883239746, 0.7173382043838501, 0.7283663153648376, 0.7392557859420776, 0.75, 0.7605924606323242, 0.7710266709327698, 0.7812963724136353, 0.7913953065872192, 0.8013173341751099, 0.8110564351081848, 0.8206066489219666, 0.8299622535705566, 0.8391175866127014, 0.8480669856071472, 0.8568050861358643, 0.8653265833854675, 0.8736262917518616, 0.8816991448402405, 0.8895403146743774, 0.8971449732780457, 0.9045084714889526, 0.9116264581680298, 0.9184945821762085, 0.9251085519790649, 0.9314644932746887, 0.9375584721565247, 0.9433868527412415, 0.9489459991455078, 0.9542326331138611, 0.9592434763908386, 0.9639755487442017, 0.9684259295463562, 0.9725919365882874, 0.9764710068702698, 0.9800608158111572, 0.9833592176437378, 0.9863641262054443, 0.9890738129615784, 0.9914865493774414, 0.9936009049415588, 0.9954156279563904, 0.9969295859336853, 0.9981418251991272, 0.9990516901016235, 0.9996585249900818, 0.9999620318412781, 0.9999620318412781, 0.9996585249900818, 0.9990516901016235, 0.9981418251991272, 0.9969295859336853, 0.9954156279563904, 0.9936009049415588, 0.9914865493774414, 0.9890738129615784, 0.9863641262054443, 0.9833592176437378, 0.9800608158111572, 0.9764710068702698, 0.9725919365882874, 0.9684259295463562, 0.9639755487442017, 0.9592434763908386, 0.9542326331138611, 0.9489459991455078, 0.9433868527412415, 0.9375584721565247, 0.9314644932746887, 0.9251085519790649, 0.9184945821762085, 0.9116264581680298, 0.9045084714889526, 0.8971449732780457, 0.8895403146743774, 0.8816991448402405, 0.8736262917518616, 0.8653265833854675, 0.8568050861358643, 0.8480669856071472, 0.8391175866127014, 0.8299622535705566, 0.8206066489219666, 0.8110564351081848, 0.8013173341751099, 0.7913953065872192, 0.7812963724136353, 0.7710266709327698, 0.7605924606323242, 0.75, 0.7392557859420776, 0.7283663153648376, 0.7173382043838501, 0.7061781883239746, 0.694892942905426, 0.6834893822669983, 0.6719744801521301, 0.6603550910949707, 0.6486384272575378, 0.636831521987915, 0.6249414682388306, 0.6129756569862366, 0.6009411811828613, 0.5888454914093018, 0.5766957998275757, 0.5644996166229248, 0.5522642135620117, 0.5399971008300781, 0.527705729007721, 0.5153975486755371, 0.5030799508094788, 0.49076053500175476, 0.47844672203063965, 0.46614599227905273, 0.45386582612991333, 0.44161364436149597, 0.42939692735671997, 0.4172230660915375, 0.40509945154190063, 0.3930334448814392, 0.38103240728378296, 0.3691035807132721, 0.3572542071342468, 0.345491498708725, 0.3338226079940796, 0.32225459814071655, 0.310794472694397, 0.29944923520088196, 0.2882257401943207, 0.2771308124065399, 0.2661712169647217, 0.25535354018211365, 0.2446843981742859, 0.23417027294635773, 0.22381751239299774, 0.21363243460655212, 0.20362119376659393, 0.19378989934921265, 0.1841444969177246, 0.174690842628479, 0.16543470323085785, 0.15638165175914764, 0.1475372314453125, 0.13890677690505981, 0.13049554824829102, 0.1223086342215538, 0.11435101926326752, 0.10662753134965897, 0.09914285689592361, 0.09190154075622559, 0.08490798622369766, 0.0781664252281189, 0.0716809630393982, 0.06545552611351013, 0.05949390307068825, 0.05379970744252205, 0.04837640002369881, 0.04322727024555206, 0.038355447351932526, 0.033763885498046875, 0.02945537306368351, 0.0254325270652771, 0.021697789430618286, 0.018253426998853683, 0.015101531520485878, 0.01224401593208313, 0.009682614356279373, 0.007418883498758078, 0.005454195663332939, 0.003789745271205902, 0.0024265418760478497, 0.0013654133072122931, 0.0006070039235055447, 0.00015177401655819267, 0 ] ================================================ FILE: __tests__/data/hanning512.json ================================================ [ 0, 3.7796577089466155e-05, 0.00015118058945517987, 0.0003401349240448326, 0.0006046309717930853, 0.0009446287294849753, 0.0013600768288597465, 0.0018509125802665949, 0.0024170614778995514, 0.003058438189327717, 0.0037749456241726875, 0.004566475749015808, 0.005432908423244953, 0.006374112796038389, 0.007389946840703487, 0.008480256423354149, 0.009644877165555954, 0.0108836330473423, 0.01219633687287569, 0.013582789339125156, 0.015042781829833984, 0.016576092690229416, 0.01818249188363552, 0.0198617335408926, 0.02161356620490551, 0.023437725380063057, 0.025333933532238007, 0.027301903814077377, 0.02934134192764759, 0.031451936811208725, 0.03363336622714996, 0.03588530793786049, 0.038207415491342545, 0.040599338710308075, 0.04306071996688843, 0.04559118300676346, 0.048190344125032425, 0.05085781589150429, 0.053593188524246216, 0.05639605596661568, 0.05926598608493805, 0.06220255047082901, 0.06520530581474304, 0.06827379763126373, 0.07140755653381348, 0.07460611313581467, 0.0778689831495285, 0.08119567483663559, 0.08458568155765533, 0.08803849667310715, 0.09155359119176865, 0.09513044357299805, 0.09876850247383118, 0.10246722400188446, 0.10622604191303253, 0.11004439741373062, 0.11392170935869217, 0.11785738915205002, 0.12185084074735641, 0.1259014755487442, 0.13000865280628204, 0.1341717690229416, 0.1383902132511139, 0.14266330003738403, 0.14699043333530426, 0.15137092769145966, 0.1558041274547577, 0.16028937697410583, 0.16482597589492798, 0.1694132536649704, 0.1740504950284958, 0.17873702943325043, 0.183472141623497, 0.18825510144233704, 0.1930851936340332, 0.197961688041687, 0.20288383960723877, 0.20785091817378998, 0.21286216378211975, 0.2179168164730072, 0.22301411628723145, 0.2281533032655716, 0.23333357274532318, 0.23855416476726532, 0.24381428956985474, 0.24911314249038696, 0.2544499337673187, 0.25982382893562317, 0.2652340531349182, 0.270679771900177, 0.2761601507663727, 0.2816743850708008, 0.28722161054611206, 0.29280102252960205, 0.2984117567539215, 0.3040529489517212, 0.30972379446029663, 0.3154233694076538, 0.32115086913108826, 0.32690542936325073, 0.3326861262321472, 0.33849215507507324, 0.3443225622177124, 0.35017651319503784, 0.3560531437397003, 0.3619515001773834, 0.3678707480430603, 0.3738099932670593, 0.3797682821750641, 0.38574475049972534, 0.39173850417137146, 0.3977486193180084, 0.4037742018699646, 0.40981432795524597, 0.4158681035041809, 0.421934574842453, 0.4280128479003906, 0.43410202860832214, 0.44020116329193115, 0.44630932807922363, 0.45242562890052795, 0.4585490822792053, 0.4646788537502289, 0.47081393003463745, 0.4769534170627594, 0.4830964207649231, 0.48924195766448975, 0.49538910388946533, 0.5015369653701782, 0.507684588432312, 0.5138310790061951, 0.519975483417511, 0.5261167883872986, 0.5322542190551758, 0.5383867621421814, 0.544513463973999, 0.5506334900856018, 0.5567458271980286, 0.5628495812416077, 0.5689438581466675, 0.5750277042388916, 0.5811002254486084, 0.5871604084968567, 0.5932074785232544, 0.5992404818534851, 0.6052584052085876, 0.6112604737281799, 0.6172456741333008, 0.6232131719589233, 0.629162073135376, 0.6350914239883423, 0.6410003304481506, 0.6468879580497742, 0.6527533531188965, 0.658595621585846, 0.6644139885902405, 0.6702074408531189, 0.6759752035140991, 0.6817163228988647, 0.6874299645423889, 0.6931152939796448, 0.6987714171409607, 0.7043974995613098, 0.7099926471710205, 0.7155560851097107, 0.7210869193077087, 0.7265843152999878, 0.732047438621521, 0.7374755144119263, 0.7428677082061768, 0.7482231259346008, 0.7535410523414612, 0.758820652961731, 0.7640610933303833, 0.7692616581916809, 0.7744214534759521, 0.7795398235321045, 0.7846158742904663, 0.7896489500999451, 0.7946382164955139, 0.7995828986167908, 0.8044823408126831, 0.8093357086181641, 0.8141423463821411, 0.8189014196395874, 0.8236123323440552, 0.8282743096351624, 0.8328866958618164, 0.8374487161636353, 0.8419597148895264, 0.8464190363883972, 0.8508259654045105, 0.8551798462867737, 0.8594800233840942, 0.8637259006500244, 0.8679167628288269, 0.8720519542694092, 0.8761309385299683, 0.8801530599594116, 0.8841177225112915, 0.8880242705345154, 0.8918721675872803, 0.8956608176231384, 0.8993896842002869, 0.9030581712722778, 0.9066656827926636, 0.9102116823196411, 0.913695752620697, 0.917117178440094, 0.9204756021499634, 0.9237704873085022, 0.9270012378692627, 0.9301674365997314, 0.933268666267395, 0.9363043308258057, 0.93927401304245, 0.9421773552894592, 0.9450137615203857, 0.9477829337120056, 0.9504844546318054, 0.9531177878379822, 0.955682635307312, 0.9581786394119263, 0.9606053233146667, 0.9629623889923096, 0.9652494788169861, 0.9674661755561829, 0.9696122407913208, 0.9716873168945312, 0.9736910462379456, 0.9756231307983398, 0.9774833917617798, 0.979271411895752, 0.9809869527816772, 0.9826298356056213, 0.9841997027397156, 0.9856963753700256, 0.9871196150779724, 0.9884692430496216, 0.989745020866394, 0.9909467101097107, 0.992074191570282, 0.9931272864341736, 0.9941058158874512, 0.9950096607208252, 0.9958386421203613, 0.9965927004814148, 0.9972716569900513, 0.9978753924369812, 0.9984039068222046, 0.9988570809364319, 0.9992347955703735, 0.9995370507240295, 0.9997637867927551, 0.9999149441719055, 0.9999905228614807, 0.9999905228614807, 0.9999149441719055, 0.9997637867927551, 0.9995370507240295, 0.9992347955703735, 0.9988570809364319, 0.9984039068222046, 0.9978753924369812, 0.9972716569900513, 0.9965927004814148, 0.9958386421203613, 0.9950096607208252, 0.9941058158874512, 0.9931272864341736, 0.992074191570282, 0.9909467101097107, 0.989745020866394, 0.9884692430496216, 0.9871196150779724, 0.9856963753700256, 0.9841997027397156, 0.9826298356056213, 0.9809869527816772, 0.979271411895752, 0.9774833917617798, 0.9756231307983398, 0.9736910462379456, 0.9716873168945312, 0.9696122407913208, 0.9674661755561829, 0.9652494788169861, 0.9629623889923096, 0.9606053233146667, 0.9581786394119263, 0.955682635307312, 0.9531177878379822, 0.9504844546318054, 0.9477829337120056, 0.9450137615203857, 0.9421773552894592, 0.93927401304245, 0.9363043308258057, 0.933268666267395, 0.9301674365997314, 0.9270012378692627, 0.9237704873085022, 0.9204756021499634, 0.917117178440094, 0.913695752620697, 0.9102116823196411, 0.9066656827926636, 0.9030581712722778, 0.8993896842002869, 0.8956608176231384, 0.8918721675872803, 0.8880242705345154, 0.8841177225112915, 0.8801530599594116, 0.8761309385299683, 0.8720519542694092, 0.8679167628288269, 0.8637259006500244, 0.8594800233840942, 0.8551798462867737, 0.8508259654045105, 0.8464190363883972, 0.8419597148895264, 0.8374487161636353, 0.8328866958618164, 0.8282743096351624, 0.8236123323440552, 0.8189014196395874, 0.8141423463821411, 0.8093357086181641, 0.8044823408126831, 0.7995828986167908, 0.7946382164955139, 0.7896489500999451, 0.7846158742904663, 0.7795398235321045, 0.7744214534759521, 0.7692616581916809, 0.7640610933303833, 0.758820652961731, 0.7535410523414612, 0.7482231259346008, 0.7428677082061768, 0.7374755144119263, 0.732047438621521, 0.7265843152999878, 0.7210869193077087, 0.7155560851097107, 0.7099926471710205, 0.7043974995613098, 0.6987714171409607, 0.6931152939796448, 0.6874299645423889, 0.6817163228988647, 0.6759752035140991, 0.6702074408531189, 0.6644139885902405, 0.658595621585846, 0.6527533531188965, 0.6468879580497742, 0.6410003304481506, 0.6350914239883423, 0.629162073135376, 0.6232131719589233, 0.6172456741333008, 0.6112604737281799, 0.6052584052085876, 0.5992404818534851, 0.5932074785232544, 0.5871604084968567, 0.5811002254486084, 0.5750277042388916, 0.5689438581466675, 0.5628495812416077, 0.5567458271980286, 0.5506334900856018, 0.544513463973999, 0.5383867621421814, 0.5322542190551758, 0.5261167883872986, 0.519975483417511, 0.5138310790061951, 0.507684588432312, 0.5015369653701782, 0.49538910388946533, 0.48924195766448975, 0.4830964207649231, 0.4769534170627594, 0.47081393003463745, 0.4646788537502289, 0.4585490822792053, 0.45242562890052795, 0.44630932807922363, 0.44020116329193115, 0.43410202860832214, 0.4280128479003906, 0.421934574842453, 0.4158681035041809, 0.40981432795524597, 0.4037742018699646, 0.3977486193180084, 0.39173850417137146, 0.38574475049972534, 0.3797682821750641, 0.3738099932670593, 0.3678707480430603, 0.3619515001773834, 0.3560531437397003, 0.35017651319503784, 0.3443225622177124, 0.33849215507507324, 0.3326861262321472, 0.32690542936325073, 0.32115086913108826, 0.3154233694076538, 0.30972379446029663, 0.3040529489517212, 0.2984117567539215, 0.29280102252960205, 0.28722161054611206, 0.2816743850708008, 0.2761601507663727, 0.270679771900177, 0.2652340531349182, 0.25982382893562317, 0.2544499337673187, 0.24911314249038696, 0.24381428956985474, 0.23855416476726532, 0.23333357274532318, 0.2281533032655716, 0.22301411628723145, 0.2179168164730072, 0.21286216378211975, 0.20785091817378998, 0.20288383960723877, 0.197961688041687, 0.1930851936340332, 0.18825510144233704, 0.183472141623497, 0.17873702943325043, 0.1740504950284958, 0.1694132536649704, 0.16482597589492798, 0.16028937697410583, 0.1558041274547577, 0.15137092769145966, 0.14699043333530426, 0.14266330003738403, 0.1383902132511139, 0.1341717690229416, 0.13000865280628204, 0.1259014755487442, 0.12185084074735641, 0.11785738915205002, 0.11392170935869217, 0.11004439741373062, 0.10622604191303253, 0.10246722400188446, 0.09876850247383118, 0.09513044357299805, 0.09155359119176865, 0.08803849667310715, 0.08458568155765533, 0.08119567483663559, 0.0778689831495285, 0.07460611313581467, 0.07140755653381348, 0.06827379763126373, 0.06520530581474304, 0.06220255047082901, 0.05926598608493805, 0.05639605596661568, 0.053593188524246216, 0.05085781589150429, 0.048190344125032425, 0.04559118300676346, 0.04306071996688843, 0.040599338710308075, 0.038207415491342545, 0.03588530793786049, 0.03363336622714996, 0.031451936811208725, 0.02934134192764759, 0.027301903814077377, 0.025333933532238007, 0.023437725380063057, 0.02161356620490551, 0.0198617335408926, 0.01818249188363552, 0.016576092690229416, 0.015042781829833984, 0.013582789339125156, 0.01219633687287569, 0.0108836330473423, 0.009644877165555954, 0.008480256423354149, 0.007389946840703487, 0.006374112796038389, 0.005432908423244953, 0.004566475749015808, 0.0037749456241726875, 0.003058438189327717, 0.0024170614778995514, 0.0018509125802665949, 0.0013600768288597465, 0.0009446287294849753, 0.0006046309717930853, 0.0003401349240448326, 0.00015118058945517987, 3.7796577089466155e-05, 0 ] ================================================ FILE: __tests__/data/sine1024.json ================================================ [ 0, 0.003070955630391836, 0.006141882389783859, 0.009212750941514969, 0.01228353288024664, 0.015354199334979057, 0.01842472143471241, 0.021495068445801735, 0.024565212428569794, 0.027635125443339348, 0.03070477955043316, 0.03377414122223854, 0.0368431881070137, 0.03991188481450081, 0.04298020526766777, 0.0460481196641922, 0.04911560192704201, 0.05218261852860451, 0.05524914339184761, 0.05831514671444893, 0.06138060241937637, 0.06444548070430756, 0.06750974804162979, 0.07057337462902069, 0.07363634556531906, 0.07669861614704132, 0.07976016402244568, 0.08282095938920975, 0.08588097244501114, 0.08894018083810806, 0.09199854731559753, 0.09505604207515717, 0.09811264276504517, 0.10116831958293915, 0.10422304272651672, 0.1072767823934555, 0.1103295087814331, 0.11338119953870773, 0.1164318174123764, 0.11948134005069733, 0.12252973020076752, 0.12557697296142578, 0.12862302362918854, 0.1316678673028946, 0.13471145927906036, 0.13775378465652466, 0.1407948136329651, 0.14383451640605927, 0.1468728631734848, 0.1499098241329193, 0.1529453694820404, 0.1559794694185257, 0.159012109041214, 0.1620432436466217, 0.16507284343242645, 0.16810089349746704, 0.17112736403942108, 0.174152210354805, 0.17717541754245758, 0.18019694089889526, 0.18321678042411804, 0.18623489141464233, 0.18925124406814575, 0.1922658085823059, 0.1952785700559616, 0.19828948378562927, 0.2012985199689865, 0.20430566370487213, 0.20731088519096375, 0.21031413972377777, 0.2133154273033142, 0.21631468832492828, 0.21931192278862, 0.22230707108974457, 0.225300133228302, 0.2282910794019699, 0.2312798649072647, 0.234266459941864, 0.23725084960460663, 0.24023300409317017, 0.24321290850639343, 0.24619050323963165, 0.24916577339172363, 0.2521387040615082, 0.2551092505455017, 0.25807738304138184, 0.26104310154914856, 0.2640063464641571, 0.2669670879840851, 0.2699253261089325, 0.27288103103637695, 0.2758341431617737, 0.2787846624851227, 0.28173255920410156, 0.28467780351638794, 0.28762033581733704, 0.29056015610694885, 0.2934972643852234, 0.29643160104751587, 0.2993631362915039, 0.3022918403148651, 0.3052176833152771, 0.30814066529273987, 0.31106072664260864, 0.3139778673648834, 0.3168920576572418, 0.31980323791503906, 0.32271140813827515, 0.3256165385246277, 0.3285185992717743, 0.3314175605773926, 0.33431339263916016, 0.337206095457077, 0.340095579624176, 0.34298187494277954, 0.3458649516105652, 0.3487447500228882, 0.35162124037742615, 0.35449445247650146, 0.357364296913147, 0.36023077368736267, 0.36309385299682617, 0.3659535050392151, 0.3688097298145294, 0.3716624677181244, 0.3745116889476776, 0.3773573637008667, 0.38019949197769165, 0.3830380439758301, 0.3858729898929596, 0.3887042999267578, 0.39153191447257996, 0.3943558633327484, 0.3971760869026184, 0.39999255537986755, 0.40280523896217346, 0.40561413764953613, 0.4084192216396332, 0.4112204611301422, 0.41401779651641846, 0.4168112576007843, 0.4196007549762726, 0.4223863184452057, 0.42516788840293884, 0.42794543504714966, 0.43071895837783813, 0.4334884285926819, 0.4362538158893585, 0.43901506066322327, 0.4417721927165985, 0.4445251524448395, 0.4472739100456238, 0.4500184655189514, 0.4527587592601776, 0.45549479126930237, 0.4582265317440033, 0.4609539210796356, 0.46367698907852173, 0.46639570593833923, 0.46910998225212097, 0.47181984782218933, 0.4745252728462219, 0.47722622752189636, 0.47992268204689026, 0.4826146066188812, 0.4853019714355469, 0.4879847466945648, 0.49066293239593506, 0.4933364987373352, 0.49600541591644287, 0.49866965413093567, 0.5013291835784912, 0.5039839744567871, 0.506633996963501, 0.5092793107032776, 0.5119197368621826, 0.5145553946495056, 0.517186164855957, 0.5198121070861816, 0.5224331021308899, 0.5250492095947266, 0.5276603102684021, 0.5302664637565613, 0.5328676104545593, 0.5354637503623962, 0.5380548238754272, 0.5406408309936523, 0.5432217121124268, 0.5457975268363953, 0.5483681559562683, 0.5509335994720459, 0.553493857383728, 0.5560489296913147, 0.5585986971855164, 0.5611432194709778, 0.563682496547699, 0.5662164092063904, 0.5687450170516968, 0.5712682008743286, 0.5737860202789307, 0.5762984752655029, 0.5788054466247559, 0.5813069939613342, 0.5838030576705933, 0.5862935781478882, 0.5887786149978638, 0.5912580490112305, 0.5937319397926331, 0.5962002277374268, 0.5986628532409668, 0.601119875907898, 0.6035712361335754, 0.6060168743133545, 0.6084568500518799, 0.6108910441398621, 0.613319456577301, 0.6157421469688416, 0.6181589961051941, 0.6205700039863586, 0.6229751706123352, 0.625374436378479, 0.6277678608894348, 0.6301553249359131, 0.6325368881225586, 0.6349124312400818, 0.6372820138931274, 0.6396455764770508, 0.6420031189918518, 0.6443545818328857, 0.6466999650001526, 0.6490393280982971, 0.651372492313385, 0.653699517250061, 0.6560204029083252, 0.6583350896835327, 0.6606435775756836, 0.6629458069801331, 0.6652418375015259, 0.6675315499305725, 0.669814944267273, 0.672092080116272, 0.67436283826828, 0.6766272783279419, 0.678885281085968, 0.681136965751648, 0.6833821535110474, 0.685620903968811, 0.687853217124939, 0.6900790333747864, 0.6922982931137085, 0.6945110559463501, 0.6967173218727112, 0.6989169716835022, 0.7011100053787231, 0.7032964825630188, 0.7054762840270996, 0.7076494693756104, 0.7098159193992615, 0.7119757533073425, 0.7141287922859192, 0.716275155544281, 0.7184147238731384, 0.7205475568771362, 0.7226735949516296, 0.7247927784919739, 0.7269051671028137, 0.7290106415748596, 0.7311093211174011, 0.7332010269165039, 0.7352858781814575, 0.7373637557029724, 0.7394347190856934, 0.7414987087249756, 0.7435556650161743, 0.7456056475639343, 0.7476485371589661, 0.7496844530105591, 0.751713216304779, 0.7537349462509155, 0.7557495832443237, 0.7577570676803589, 0.759757399559021, 0.7617505788803101, 0.7637365460395813, 0.7657153606414795, 0.7676869034767151, 0.7696512341499329, 0.771608293056488, 0.7735580801963806, 0.7755005955696106, 0.7774357795715332, 0.7793636322021484, 0.7812840938568115, 0.7831972241401672, 0.7851030230522156, 0.7870013117790222, 0.7888922691345215, 0.790775716304779, 0.7926517724990845, 0.7945203185081482, 0.7963813543319702, 0.7982348799705505, 0.8000808954238892, 0.8019194006919861, 0.8037502765655518, 0.8055736422538757, 0.8073893189430237, 0.8091974854469299, 0.8109979629516602, 0.8127908110618591, 0.8145759701728821, 0.816353440284729, 0.8181232213973999, 0.8198853135108948, 0.8216396570205688, 0.8233862519264221, 0.8251250386238098, 0.8268561363220215, 0.8285793662071228, 0.8302947878837585, 0.8320024013519287, 0.8337021470069885, 0.835394024848938, 0.8370780348777771, 0.8387541770935059, 0.8404223918914795, 0.842082679271698, 0.8437350392341614, 0.8453794121742249, 0.8470158576965332, 0.8486442565917969, 0.8502646684646606, 0.8518770933151245, 0.8534814715385437, 0.8550778031349182, 0.8566660284996033, 0.8582462072372437, 0.8598182797431946, 0.861382246017456, 0.8629381060600281, 0.8644858598709106, 0.8660253882408142, 0.8675568103790283, 0.8690800070762634, 0.8705950379371643, 0.8721018433570862, 0.873600423336029, 0.8750907778739929, 0.876572847366333, 0.8780466914176941, 0.8795121908187866, 0.8809694647789001, 0.8824183940887451, 0.8838590383529663, 0.8852912783622742, 0.8867152333259583, 0.888130784034729, 0.8895379900932312, 0.8909367918968201, 0.8923271894454956, 0.8937091827392578, 0.8950827717781067, 0.8964478969573975, 0.8978045582771301, 0.8991527557373047, 0.9004924297332764, 0.9018236994743347, 0.9031463861465454, 0.904460608959198, 0.9057662487030029, 0.9070634245872498, 0.9083519577980042, 0.9096319675445557, 0.9109034538269043, 0.9121662974357605, 0.9134204983711243, 0.9146661162376404, 0.9159031510353088, 0.9171314835548401, 0.9183511734008789, 0.9195622801780701, 0.9207646250724792, 0.921958327293396, 0.9231433272361755, 0.9243196249008179, 0.925487220287323, 0.9266460537910461, 0.9277961850166321, 0.9289374947547913, 0.9300701022148132, 0.9311939477920532, 0.9323089718818665, 0.9334152340888977, 0.9345126748085022, 0.9356013536453247, 0.9366811513900757, 0.9377521276473999, 0.9388142824172974, 0.9398675560951233, 0.9409119486808777, 0.9419475197792053, 0.9429742097854614, 0.9439919590950012, 0.9450008273124695, 0.9460007548332214, 0.9469918012619019, 0.947973906993866, 0.9489470720291138, 0.9499112963676453, 0.9508665204048157, 0.9518128037452698, 0.9527501463890076, 0.9536784887313843, 0.9545977711677551, 0.9555081129074097, 0.9564094543457031, 0.9573017358779907, 0.9581850171089172, 0.9590592384338379, 0.9599244594573975, 0.9607805609703064, 0.9616276621818542, 0.9624656438827515, 0.9632945656776428, 0.9641144275665283, 0.9649251699447632, 0.9657268524169922, 0.9665193557739258, 0.9673027992248535, 0.9680771231651306, 0.9688422679901123, 0.9695983529090881, 0.9703452587127686, 0.9710829854011536, 0.9718115925788879, 0.9725310206413269, 0.9732412695884705, 0.9739423394203186, 0.9746342301368713, 0.9753168821334839, 0.9759904146194458, 0.9766547083854675, 0.9773097634315491, 0.9779556393623352, 0.9785922765731812, 0.9792196750640869, 0.9798378944396973, 0.9804468154907227, 0.9810464978218079, 0.9816369414329529, 0.9822181463241577, 0.9827900528907776, 0.9833527207374573, 0.983906090259552, 0.9844501614570618, 0.9849849939346313, 0.985510528087616, 0.9860267639160156, 0.9865337014198303, 0.9870312809944153, 0.9875196218490601, 0.9879986643791199, 0.98846834897995, 0.9889286756515503, 0.9893797039985657, 0.9898214340209961, 0.9902538061141968, 0.9906768798828125, 0.9910905361175537, 0.99149489402771, 0.9918898940086365, 0.9922755360603333, 0.9926518201828003, 0.9930187463760376, 0.9933763146400452, 0.9937244653701782, 0.9940633177757263, 0.9943927526473999, 0.9947128295898438, 0.9950234889984131, 0.9953247904777527, 0.9956167340278625, 0.9958992004394531, 0.9961723685264587, 0.9964361190795898, 0.9966904520988464, 0.9969353675842285, 0.9971709251403809, 0.9973970651626587, 0.997613787651062, 0.9978210926055908, 0.9980189800262451, 0.9982075095176697, 0.998386561870575, 0.9985562562942505, 0.9987165331840515, 0.9988673329353333, 0.9990087747573853, 0.999140739440918, 0.9992632865905762, 0.9993764758110046, 0.9994801878929138, 0.9995744824409485, 0.9996593594551086, 0.9997347593307495, 0.9998008012771606, 0.9998573660850525, 0.9999045133590698, 0.9999422430992126, 0.999970555305481, 0.99998939037323, 0.9999988079071045, 0.9999988079071045, 0.99998939037323, 0.999970555305481, 0.9999422430992126, 0.9999045133590698, 0.9998573660850525, 0.9998008012771606, 0.9997347593307495, 0.9996593594551086, 0.9995744824409485, 0.9994801878929138, 0.9993764758110046, 0.9992632865905762, 0.999140739440918, 0.9990087747573853, 0.9988673329353333, 0.9987165331840515, 0.9985562562942505, 0.998386561870575, 0.9982075095176697, 0.9980189800262451, 0.9978210926055908, 0.997613787651062, 0.9973970651626587, 0.9971709251403809, 0.9969353675842285, 0.9966904520988464, 0.9964361190795898, 0.9961723685264587, 0.9958992004394531, 0.9956167340278625, 0.9953247904777527, 0.9950234889984131, 0.9947128295898438, 0.9943927526473999, 0.9940633177757263, 0.9937244653701782, 0.9933763146400452, 0.9930187463760376, 0.9926518201828003, 0.9922755360603333, 0.9918898940086365, 0.99149489402771, 0.9910905361175537, 0.9906768798828125, 0.9902538061141968, 0.9898214340209961, 0.9893797039985657, 0.9889286756515503, 0.98846834897995, 0.9879986643791199, 0.9875196218490601, 0.9870312809944153, 0.9865337014198303, 0.9860267639160156, 0.985510528087616, 0.9849849939346313, 0.9844501614570618, 0.983906090259552, 0.9833527207374573, 0.9827900528907776, 0.9822181463241577, 0.9816369414329529, 0.9810464978218079, 0.9804468154907227, 0.9798378944396973, 0.9792196750640869, 0.9785922765731812, 0.9779556393623352, 0.9773097634315491, 0.9766547083854675, 0.9759904146194458, 0.9753168821334839, 0.9746342301368713, 0.9739423394203186, 0.9732412695884705, 0.9725310206413269, 0.9718115925788879, 0.9710829854011536, 0.9703452587127686, 0.9695983529090881, 0.9688422679901123, 0.9680771231651306, 0.9673027992248535, 0.9665193557739258, 0.9657268524169922, 0.9649251699447632, 0.9641144275665283, 0.9632945656776428, 0.9624656438827515, 0.9616276621818542, 0.9607805609703064, 0.9599244594573975, 0.9590592384338379, 0.9581850171089172, 0.9573017358779907, 0.9564094543457031, 0.9555081129074097, 0.9545977711677551, 0.9536784887313843, 0.9527501463890076, 0.9518128037452698, 0.9508665204048157, 0.9499112963676453, 0.9489470720291138, 0.947973906993866, 0.9469918012619019, 0.9460007548332214, 0.9450008273124695, 0.9439919590950012, 0.9429742097854614, 0.9419475197792053, 0.9409119486808777, 0.9398675560951233, 0.9388142824172974, 0.9377521276473999, 0.9366811513900757, 0.9356013536453247, 0.9345126748085022, 0.9334152340888977, 0.9323089718818665, 0.9311939477920532, 0.9300701022148132, 0.9289374947547913, 0.9277961850166321, 0.9266460537910461, 0.925487220287323, 0.9243196249008179, 0.9231433272361755, 0.921958327293396, 0.9207646250724792, 0.9195622801780701, 0.9183511734008789, 0.9171314835548401, 0.9159031510353088, 0.9146661162376404, 0.9134204983711243, 0.9121662974357605, 0.9109034538269043, 0.9096319675445557, 0.9083519577980042, 0.9070634245872498, 0.9057662487030029, 0.904460608959198, 0.9031463861465454, 0.9018236994743347, 0.9004924297332764, 0.8991527557373047, 0.8978045582771301, 0.8964478969573975, 0.8950827717781067, 0.8937091827392578, 0.8923271894454956, 0.8909367918968201, 0.8895379900932312, 0.888130784034729, 0.8867152333259583, 0.8852912783622742, 0.8838590383529663, 0.8824183940887451, 0.8809694647789001, 0.8795121908187866, 0.8780466914176941, 0.876572847366333, 0.8750907778739929, 0.873600423336029, 0.8721018433570862, 0.8705950379371643, 0.8690800070762634, 0.8675568103790283, 0.8660253882408142, 0.8644858598709106, 0.8629381060600281, 0.861382246017456, 0.8598182797431946, 0.8582462072372437, 0.8566660284996033, 0.8550778031349182, 0.8534814715385437, 0.8518770933151245, 0.8502646684646606, 0.8486442565917969, 0.8470158576965332, 0.8453794121742249, 0.8437350392341614, 0.842082679271698, 0.8404223918914795, 0.8387541770935059, 0.8370780348777771, 0.835394024848938, 0.8337021470069885, 0.8320024013519287, 0.8302947878837585, 0.8285793662071228, 0.8268561363220215, 0.8251250386238098, 0.8233862519264221, 0.8216396570205688, 0.8198853135108948, 0.8181232213973999, 0.816353440284729, 0.8145759701728821, 0.8127908110618591, 0.8109979629516602, 0.8091974854469299, 0.8073893189430237, 0.8055736422538757, 0.8037502765655518, 0.8019194006919861, 0.8000808954238892, 0.7982348799705505, 0.7963813543319702, 0.7945203185081482, 0.7926517724990845, 0.790775716304779, 0.7888922691345215, 0.7870013117790222, 0.7851030230522156, 0.7831972241401672, 0.7812840938568115, 0.7793636322021484, 0.7774357795715332, 0.7755005955696106, 0.7735580801963806, 0.771608293056488, 0.7696512341499329, 0.7676869034767151, 0.7657153606414795, 0.7637365460395813, 0.7617505788803101, 0.759757399559021, 0.7577570676803589, 0.7557495832443237, 0.7537349462509155, 0.751713216304779, 0.7496844530105591, 0.7476485371589661, 0.7456056475639343, 0.7435556650161743, 0.7414987087249756, 0.7394347190856934, 0.7373637557029724, 0.7352858781814575, 0.7332010269165039, 0.7311093211174011, 0.7290106415748596, 0.7269051671028137, 0.7247927784919739, 0.7226735949516296, 0.7205475568771362, 0.7184147238731384, 0.716275155544281, 0.7141287922859192, 0.7119757533073425, 0.7098159193992615, 0.7076494693756104, 0.7054762840270996, 0.7032964825630188, 0.7011100053787231, 0.6989169716835022, 0.6967173218727112, 0.6945110559463501, 0.6922982931137085, 0.6900790333747864, 0.687853217124939, 0.685620903968811, 0.6833821535110474, 0.681136965751648, 0.678885281085968, 0.6766272783279419, 0.67436283826828, 0.672092080116272, 0.669814944267273, 0.6675315499305725, 0.6652418375015259, 0.6629458069801331, 0.6606435775756836, 0.6583350896835327, 0.6560204029083252, 0.653699517250061, 0.651372492313385, 0.6490393280982971, 0.6466999650001526, 0.6443545818328857, 0.6420031189918518, 0.6396455764770508, 0.6372820138931274, 0.6349124312400818, 0.6325368881225586, 0.6301553249359131, 0.6277678608894348, 0.625374436378479, 0.6229751706123352, 0.6205700039863586, 0.6181589961051941, 0.6157421469688416, 0.613319456577301, 0.6108910441398621, 0.6084568500518799, 0.6060168743133545, 0.6035712361335754, 0.601119875907898, 0.5986628532409668, 0.5962002277374268, 0.5937319397926331, 0.5912580490112305, 0.5887786149978638, 0.5862935781478882, 0.5838030576705933, 0.5813069939613342, 0.5788054466247559, 0.5762984752655029, 0.5737860202789307, 0.5712682008743286, 0.5687450170516968, 0.5662164092063904, 0.563682496547699, 0.5611432194709778, 0.5585986971855164, 0.5560489296913147, 0.553493857383728, 0.5509335994720459, 0.5483681559562683, 0.5457975268363953, 0.5432217121124268, 0.5406408309936523, 0.5380548238754272, 0.5354637503623962, 0.5328676104545593, 0.5302664637565613, 0.5276603102684021, 0.5250492095947266, 0.5224331021308899, 0.5198121070861816, 0.517186164855957, 0.5145553946495056, 0.5119197368621826, 0.5092793107032776, 0.506633996963501, 0.5039839744567871, 0.5013291835784912, 0.49866965413093567, 0.49600541591644287, 0.4933364987373352, 0.49066293239593506, 0.4879847466945648, 0.4853019714355469, 0.4826146066188812, 0.47992268204689026, 0.47722622752189636, 0.4745252728462219, 0.47181984782218933, 0.46910998225212097, 0.46639570593833923, 0.46367698907852173, 0.4609539210796356, 0.4582265317440033, 0.45549479126930237, 0.4527587592601776, 0.4500184655189514, 0.4472739100456238, 0.4445251524448395, 0.4417721927165985, 0.43901506066322327, 0.4362538158893585, 0.4334884285926819, 0.43071895837783813, 0.42794543504714966, 0.42516788840293884, 0.4223863184452057, 0.4196007549762726, 0.4168112576007843, 0.41401779651641846, 0.4112204611301422, 0.4084192216396332, 0.40561413764953613, 0.40280523896217346, 0.39999255537986755, 0.3971760869026184, 0.3943558633327484, 0.39153191447257996, 0.3887042999267578, 0.3858729898929596, 0.3830380439758301, 0.38019949197769165, 0.3773573637008667, 0.3745116889476776, 0.3716624677181244, 0.3688097298145294, 0.3659535050392151, 0.36309385299682617, 0.36023077368736267, 0.357364296913147, 0.35449445247650146, 0.35162124037742615, 0.3487447500228882, 0.3458649516105652, 0.34298187494277954, 0.340095579624176, 0.337206095457077, 0.33431339263916016, 0.3314175605773926, 0.3285185992717743, 0.3256165385246277, 0.32271140813827515, 0.31980323791503906, 0.3168920576572418, 0.3139778673648834, 0.31106072664260864, 0.30814066529273987, 0.3052176833152771, 0.3022918403148651, 0.2993631362915039, 0.29643160104751587, 0.2934972643852234, 0.29056015610694885, 0.28762033581733704, 0.28467780351638794, 0.28173255920410156, 0.2787846624851227, 0.2758341431617737, 0.27288103103637695, 0.2699253261089325, 0.2669670879840851, 0.2640063464641571, 0.26104310154914856, 0.25807738304138184, 0.2551092505455017, 0.2521387040615082, 0.24916577339172363, 0.24619050323963165, 0.24321290850639343, 0.24023300409317017, 0.23725084960460663, 0.234266459941864, 0.2312798649072647, 0.2282910794019699, 0.225300133228302, 0.22230707108974457, 0.21931192278862, 0.21631468832492828, 0.2133154273033142, 0.21031413972377777, 0.20731088519096375, 0.20430566370487213, 0.2012985199689865, 0.19828948378562927, 0.1952785700559616, 0.1922658085823059, 0.18925124406814575, 0.18623489141464233, 0.18321678042411804, 0.18019694089889526, 0.17717541754245758, 0.174152210354805, 0.17112736403942108, 0.16810089349746704, 0.16507284343242645, 0.1620432436466217, 0.159012109041214, 0.1559794694185257, 0.1529453694820404, 0.1499098241329193, 0.1468728631734848, 0.14383451640605927, 0.1407948136329651, 0.13775378465652466, 0.13471145927906036, 0.1316678673028946, 0.12862302362918854, 0.12557697296142578, 0.12252973020076752, 0.11948134005069733, 0.1164318174123764, 0.11338119953870773, 0.1103295087814331, 0.1072767823934555, 0.10422304272651672, 0.10116831958293915, 0.09811264276504517, 0.09505604207515717, 0.09199854731559753, 0.08894018083810806, 0.08588097244501114, 0.08282095938920975, 0.07976016402244568, 0.07669861614704132, 0.07363634556531906, 0.07057337462902069, 0.06750974804162979, 0.06444548070430756, 0.06138060241937637, 0.05831514671444893, 0.05524914339184761, 0.05218261852860451, 0.04911560192704201, 0.0460481196641922, 0.04298020526766777, 0.03991188481450081, 0.0368431881070137, 0.03377414122223854, 0.03070477955043316, 0.027635125443339348, 0.024565212428569794, 0.021495068445801735, 0.01842472143471241, 0.015354199334979057, 0.01228353288024664, 0.009212750941514969, 0.006141882389783859, 0.003070955630391836, 1.2246468525851679e-16 ] ================================================ FILE: __tests__/data/sine128.json ================================================ [ 0, 0.02473442815244198, 0.049453720450401306, 0.07414275407791138, 0.09878642112016678, 0.12336964160203934, 0.14787736535072327, 0.17229461669921875, 0.19660644233226776, 0.22079795598983765, 0.2448543757200241, 0.2687609791755676, 0.29250311851501465, 0.31606629490852356, 0.33943605422973633, 0.36259815096855164, 0.38553833961486816, 0.4082426428794861, 0.43069714307785034, 0.4528881013393402, 0.4748019576072693, 0.4964253008365631, 0.5177448391914368, 0.5387476086616516, 0.5594207644462585, 0.5797515511512756, 0.5997276306152344, 0.619336724281311, 0.6385669112205505, 0.6574063301086426, 0.6758434772491455, 0.6938670873641968, 0.7114661335945129, 0.7286298871040344, 0.7453477382659912, 0.7616095542907715, 0.7774053812026978, 0.7927254438400269, 0.8075605034828186, 0.8219014406204224, 0.8357394337654114, 0.8490660786628723, 0.861873209476471, 0.8741528987884521, 0.8858977556228638, 0.897100567817688, 0.9077544212341309, 0.9178528189659119, 0.9273896217346191, 0.9363589882850647, 0.9447553753852844, 0.9525737166404724, 0.9598091244697571, 0.9664573073387146, 0.9725140929222107, 0.9779758453369141, 0.9828391671180725, 0.9871010780334473, 0.990759015083313, 0.9938107132911682, 0.9962543249130249, 0.9980883598327637, 0.9993116855621338, 0.9999235272407532, 0.9999235272407532, 0.9993116855621338, 0.9980883598327637, 0.9962543249130249, 0.9938107132911682, 0.990759015083313, 0.9871010780334473, 0.9828391671180725, 0.9779758453369141, 0.9725140929222107, 0.9664573073387146, 0.9598091244697571, 0.9525737166404724, 0.9447553753852844, 0.9363589882850647, 0.9273896217346191, 0.9178528189659119, 0.9077544212341309, 0.897100567817688, 0.8858977556228638, 0.8741528987884521, 0.861873209476471, 0.8490660786628723, 0.8357394337654114, 0.8219014406204224, 0.8075605034828186, 0.7927254438400269, 0.7774053812026978, 0.7616095542907715, 0.7453477382659912, 0.7286298871040344, 0.7114661335945129, 0.6938670873641968, 0.6758434772491455, 0.6574063301086426, 0.6385669112205505, 0.619336724281311, 0.5997276306152344, 0.5797515511512756, 0.5594207644462585, 0.5387476086616516, 0.5177448391914368, 0.4964253008365631, 0.4748019576072693, 0.4528881013393402, 0.43069714307785034, 0.4082426428794861, 0.38553833961486816, 0.36259815096855164, 0.33943605422973633, 0.31606629490852356, 0.29250311851501465, 0.2687609791755676, 0.2448543757200241, 0.22079795598983765, 0.19660644233226776, 0.17229461669921875, 0.14787736535072327, 0.12336964160203934, 0.09878642112016678, 0.07414275407791138, 0.049453720450401306, 0.02473442815244198, 1.2246468525851679e-16 ] ================================================ FILE: __tests__/data/sine2048.json ================================================ [ 0, 0.0015347296139225364, 0.0030694555025547743, 0.004604174289852381, 0.0061388821341097355, 0.007673575542867184, 0.009208250790834427, 0.010742904618382454, 0.012277533300220966, 0.013812132179737091, 0.015346699394285679, 0.016881229355931282, 0.018415721133351326, 0.01995016820728779, 0.02148456871509552, 0.023018918931484222, 0.024553215131163597, 0.026087453588843346, 0.02762162871658802, 0.02915574051439762, 0.0306897833943367, 0.03222375363111496, 0.03375764936208725, 0.035291463136672974, 0.03682519495487213, 0.038358841091394424, 0.039892397820949554, 0.041425857692956924, 0.042959220707416534, 0.044492483139038086, 0.04602564126253128, 0.04755868762731552, 0.04909162595868111, 0.05062444508075714, 0.05215714871883392, 0.053689729422330856, 0.05522217974066734, 0.05675450339913368, 0.05828669294714928, 0.05981874465942383, 0.06135065481066704, 0.0628824234008789, 0.06441403925418854, 0.06594550609588623, 0.06747681647539139, 0.06900797039270401, 0.0705389603972435, 0.07206977903842926, 0.07360043376684189, 0.07513091713190079, 0.07666122168302536, 0.07819133996963501, 0.07972127944231033, 0.08125103265047073, 0.08278059214353561, 0.08430995792150497, 0.08583912253379822, 0.08736808598041534, 0.08889684826135635, 0.09042539447546005, 0.09195373207330704, 0.09348184615373611, 0.09500974416732788, 0.09653741866350174, 0.09806486964225769, 0.09959208965301514, 0.10111907124519348, 0.10264581441879272, 0.10417231172323227, 0.10569857060909271, 0.10722457617521286, 0.10875033587217331, 0.11027583479881287, 0.11180107295513153, 0.1133260503411293, 0.11485075950622559, 0.11637520045042038, 0.11789935827255249, 0.11942324787378311, 0.12094685435295105, 0.1224701777100563, 0.12399320304393768, 0.12551595270633698, 0.1270383894443512, 0.12856054306030273, 0.1300823837518692, 0.1316039115190506, 0.13312514126300812, 0.13464605808258057, 0.13616664707660675, 0.13768692314624786, 0.1392068713903427, 0.1407264918088913, 0.14224578440189362, 0.14376474916934967, 0.14528335630893707, 0.1468016356229782, 0.1483195722103119, 0.14983715116977692, 0.1513543725013733, 0.152871236205101, 0.15438775718212128, 0.1559039056301117, 0.15741968154907227, 0.158935084939003, 0.16045011579990387, 0.1619647741317749, 0.1634790599346161, 0.16499294340610504, 0.16650643944740295, 0.16801954805850983, 0.16953226923942566, 0.17104458808898926, 0.17255648970603943, 0.17406800389289856, 0.17557910084724426, 0.17708978056907654, 0.17860004305839539, 0.1801098883152008, 0.1816193014383316, 0.18312829732894897, 0.18463686108589172, 0.18614497780799866, 0.18765266239643097, 0.18915991485118866, 0.19066670536994934, 0.1921730637550354, 0.19367896020412445, 0.1951843947172165, 0.19668938219547272, 0.19819389283657074, 0.19969795644283295, 0.20120152831077576, 0.20270463824272156, 0.20420727133750916, 0.20570941269397736, 0.20721107721328735, 0.20871224999427795, 0.21021294593811035, 0.21171313524246216, 0.21321281790733337, 0.2147120088338852, 0.21621069312095642, 0.21770887076854706, 0.2192065268754959, 0.22070367634296417, 0.22220028936862946, 0.22369639575481415, 0.22519196569919586, 0.2266870141029358, 0.22818152606487274, 0.2296755015850067, 0.2311689257621765, 0.23266181349754333, 0.23415414988994598, 0.23564594984054565, 0.23713718354701996, 0.2386278510093689, 0.24011796712875366, 0.24160750210285187, 0.2430964857339859, 0.24458488821983337, 0.24607272446155548, 0.24755996465682983, 0.24904663860797882, 0.25053271651268005, 0.2520182132720947, 0.25350308418273926, 0.2549873888492584, 0.25647109746932983, 0.2579541802406311, 0.2594366669654846, 0.2609185576438904, 0.262399822473526, 0.2638804614543915, 0.2653604745864868, 0.266839861869812, 0.26831862330436707, 0.269796758890152, 0.27127426862716675, 0.272751122713089, 0.2742273509502411, 0.27570292353630066, 0.2771778404712677, 0.2786521017551422, 0.2801257371902466, 0.28159868717193604, 0.28307098150253296, 0.28454259037971497, 0.28601354360580444, 0.2874838411808014, 0.28895342350006104, 0.29042235016822815, 0.29189059138298035, 0.2933581471443176, 0.29482501745224, 0.29629117250442505, 0.2977566421031952, 0.299221396446228, 0.30068546533584595, 0.30214881896972656, 0.3036114573478699, 0.3050733804702759, 0.3065345883369446, 0.307995080947876, 0.30945485830307007, 0.31091389060020447, 0.3123721778392792, 0.3138297498226166, 0.3152865767478943, 0.3167426586151123, 0.31819799542427063, 0.3196525573730469, 0.3211064040660858, 0.3225594758987427, 0.32401180267333984, 0.32546335458755493, 0.32691413164138794, 0.32836416363716125, 0.3298133909702301, 0.33126187324523926, 0.33270955085754395, 0.33415645360946655, 0.3356025815010071, 0.33704790472984314, 0.33849242329597473, 0.33993616700172424, 0.3413791060447693, 0.34282124042510986, 0.3442625403404236, 0.3457030653953552, 0.34714275598526, 0.3485816419124603, 0.3500196933746338, 0.3514569401741028, 0.35289332270622253, 0.3543289005756378, 0.35576364398002625, 0.3571975529193878, 0.35863062739372253, 0.360062837600708, 0.3614942133426666, 0.362924724817276, 0.36435437202453613, 0.3657831847667694, 0.36721113324165344, 0.36863818764686584, 0.3700644075870514, 0.3714897334575653, 0.37291419506073, 0.3743377923965454, 0.3757604956626892, 0.3771823048591614, 0.3786032497882843, 0.3800232708454132, 0.38144242763519287, 0.3828606605529785, 0.38427799940109253, 0.3856944441795349, 0.3871099650859833, 0.38852459192276, 0.3899382948875427, 0.3913510739803314, 0.3927629292011261, 0.39417386054992676, 0.3955838680267334, 0.396992951631546, 0.39840108156204224, 0.39980828762054443, 0.4012145400047302, 0.402619868516922, 0.40402424335479736, 0.4054276645183563, 0.4068301022052765, 0.40823161602020264, 0.40963214635849, 0.41103172302246094, 0.4124303460121155, 0.4138279855251312, 0.4152246415615082, 0.41662031412124634, 0.4180150330066681, 0.41940873861312866, 0.42080146074295044, 0.4221931993961334, 0.4235839545726776, 0.4249736964702606, 0.42636245489120483, 0.4277501702308655, 0.4291369318962097, 0.4305226504802704, 0.4319073557853699, 0.4332910478115082, 0.4346736967563629, 0.43605536222457886, 0.43743598461151123, 0.43881556391716003, 0.44019412994384766, 0.4415716528892517, 0.4429481327533722, 0.4443235695362091, 0.44569796323776245, 0.44707128405570984, 0.44844356179237366, 0.4498147964477539, 0.4511849880218506, 0.4525540769100189, 0.4539221227169037, 0.4552890956401825, 0.45665499567985535, 0.45801982283592224, 0.4593835771083832, 0.46074622869491577, 0.4621078073978424, 0.4634683132171631, 0.4648277163505554, 0.4661860167980194, 0.46754321455955505, 0.46889930963516235, 0.4702543020248413, 0.4716082215309143, 0.4729609787464142, 0.4743126630783081, 0.4756632149219513, 0.47701263427734375, 0.47836095094680786, 0.47970813512802124, 0.4810541868209839, 0.4823991060256958, 0.4837428629398346, 0.48508551716804504, 0.4864270091056824, 0.48776736855506897, 0.48910656571388245, 0.4904446303844452, 0.4917815327644348, 0.49311724305152893, 0.4944518208503723, 0.4957852363586426, 0.4971174895763397, 0.49844855070114136, 0.4997784495353699, 0.5011072158813477, 0.5024347305297852, 0.5037611126899719, 0.5050862431526184, 0.5064102411270142, 0.5077330470085144, 0.5090546011924744, 0.5103750228881836, 0.5116941928863525, 0.513012170791626, 0.5143289566040039, 0.5156445503234863, 0.5169588923454285, 0.5182720422744751, 0.5195839405059814, 0.5208946466445923, 0.5222041010856628, 0.5235123634338379, 0.5248193144798279, 0.5261251330375671, 0.5274296402931213, 0.5287328958511353, 0.5300349593162537, 0.531335711479187, 0.5326352715492249, 0.5339335799217224, 0.5352305769920349, 0.5365263223648071, 0.5378208756446838, 0.5391140580177307, 0.5404060482978821, 0.5416967272758484, 0.5429861545562744, 0.5442742705345154, 0.5455611348152161, 0.5468467473983765, 0.548130989074707, 0.5494139790534973, 0.5506957173347473, 0.5519760847091675, 0.5532552003860474, 0.5545330047607422, 0.555809497833252, 0.5570846796035767, 0.5583585500717163, 0.5596310496330261, 0.5609022974967957, 0.5621722340583801, 0.5634407997131348, 0.5647080540657043, 0.5659739971160889, 0.5672386288642883, 0.568501889705658, 0.5697637796401978, 0.5710243582725525, 0.5722836256027222, 0.573541522026062, 0.574798047542572, 0.576053261756897, 0.5773070454597473, 0.5785595178604126, 0.579810619354248, 0.5810604095458984, 0.5823087692260742, 0.5835557579994202, 0.5848013758659363, 0.5860456228256226, 0.587288498878479, 0.5885300040245056, 0.5897700786590576, 0.5910087823867798, 0.5922461152076721, 0.5934820175170898, 0.5947165489196777, 0.595949649810791, 0.5971813797950745, 0.5984116792678833, 0.5996406078338623, 0.6008681058883667, 0.6020941734313965, 0.6033188104629517, 0.604542076587677, 0.605763852596283, 0.6069842576980591, 0.6082032322883606, 0.6094207167625427, 0.610636830329895, 0.6118514537811279, 0.613064706325531, 0.6142764687538147, 0.6154868006706238, 0.6166956424713135, 0.6179030537605286, 0.619109034538269, 0.6203135251998901, 0.6215165853500366, 0.6227181553840637, 0.6239182353019714, 0.6251168847084045, 0.6263140439987183, 0.6275097727775574, 0.6287039518356323, 0.6298967003822327, 0.6310879588127136, 0.6322777271270752, 0.6334660053253174, 0.6346527934074402, 0.6358380317687988, 0.6370218396186829, 0.6382041573524475, 0.639384925365448, 0.6405642032623291, 0.6417419910430908, 0.6429182291030884, 0.6440929770469666, 0.6452661752700806, 0.64643794298172, 0.6476081013679504, 0.6487767696380615, 0.6499438881874084, 0.651109516620636, 0.6522735357284546, 0.6534360647201538, 0.6545971035957336, 0.6557565331459045, 0.656914472579956, 0.6580708026885986, 0.659225583076477, 0.6603788733482361, 0.6615305542945862, 0.6626806855201721, 0.6638292670249939, 0.6649762988090515, 0.666121780872345, 0.6672656536102295, 0.6684079766273499, 0.6695486903190613, 0.6706878542900085, 0.6718254089355469, 0.672961413860321, 0.674095869064331, 0.6752286553382874, 0.6763598918914795, 0.6774895191192627, 0.6786175966262817, 0.6797440648078918, 0.6808688640594482, 0.6819921135902405, 0.6831137537956238, 0.6842337846755981, 0.6853522062301636, 0.6864690184593201, 0.6875841617584229, 0.6886977553367615, 0.6898096799850464, 0.6909199953079224, 0.6920287013053894, 0.6931357383728027, 0.6942411661148071, 0.6953449845314026, 0.6964471340179443, 0.6975476741790771, 0.6986465454101562, 0.6997437477111816, 0.7008393406867981, 0.7019332647323608, 0.7030255198478699, 0.70411616563797, 0.7052050828933716, 0.7062923908233643, 0.7073780298233032, 0.7084619998931885, 0.70954430103302, 0.7106249332427979, 0.711703896522522, 0.7127811908721924, 0.7138567566871643, 0.7149306535720825, 0.7160029411315918, 0.7170734405517578, 0.7181423306465149, 0.7192094922065735, 0.7202749848365784, 0.7213387489318848, 0.7224007844924927, 0.7234612107276917, 0.7245198488235474, 0.7255768179893494, 0.7266320586204529, 0.7276856303215027, 0.728737473487854, 0.7297875881195068, 0.7308359742164612, 0.731882631778717, 0.7329275608062744, 0.7339708209037781, 0.7350122928619385, 0.7360520958900452, 0.7370901107788086, 0.7381263971328735, 0.73916095495224, 0.740193784236908, 0.7412248253822327, 0.7422541379928589, 0.7432817220687866, 0.7443075776100159, 0.7453316450119019, 0.7463539242744446, 0.7473745346069336, 0.7483932971954346, 0.7494103312492371, 0.7504256367683411, 0.751439094543457, 0.7524508237838745, 0.7534608244895935, 0.7544689774513245, 0.7554754018783569, 0.7564800381660461, 0.7574828863143921, 0.7584839463233948, 0.7594832181930542, 0.7604807019233704, 0.7614763975143433, 0.7624703049659729, 0.7634624242782593, 0.7644527554512024, 0.7654412388801575, 0.7664279341697693, 0.7674128413200378, 0.7683959603309631, 0.7693772315979004, 0.7703567147254944, 0.7713343501091003, 0.772310197353363, 0.7732841968536377, 0.7742564082145691, 0.7752267718315125, 0.7761953473091125, 0.7771620750427246, 0.7781269550323486, 0.7790899872779846, 0.7800512313842773, 0.781010627746582, 0.7819681763648987, 0.7829238772392273, 0.7838777303695679, 0.7848297357559204, 0.7857798933982849, 0.7867282032966614, 0.7876746654510498, 0.7886192798614502, 0.7895620465278625, 0.7905029058456421, 0.7914419770240784, 0.7923791408538818, 0.7933143973350525, 0.7942478656768799, 0.7951793670654297, 0.7961090803146362, 0.79703688621521, 0.7979628443717957, 0.7988868951797485, 0.7998090386390686, 0.8007293343544006, 0.8016477227210999, 0.802564263343811, 0.8034788370132446, 0.8043915629386902, 0.8053024411201477, 0.8062113523483276, 0.8071184158325195, 0.8080235123634338, 0.8089267611503601, 0.8098281025886536, 0.8107275366783142, 0.811625063419342, 0.8125206232070923, 0.8134143352508545, 0.8143060803413391, 0.8151959776878357, 0.8160839080810547, 0.8169698715209961, 0.8178539872169495, 0.8187361359596252, 0.8196163773536682, 0.8204946517944336, 0.8213710188865662, 0.8222454786300659, 0.8231179714202881, 0.8239885568618774, 0.8248571157455444, 0.8257238268852234, 0.8265885710716248, 0.8274513483047485, 0.8283121585845947, 0.8291710615158081, 0.8300279974937439, 0.8308829665184021, 0.8317359685897827, 0.8325870037078857, 0.833436131477356, 0.8342832326889038, 0.8351284265518188, 0.8359716534614563, 0.8368128538131714, 0.8376521468162537, 0.8384894132614136, 0.8393247127532959, 0.8401580452919006, 0.8409894108772278, 0.8418188095092773, 0.8426461815834045, 0.8434715867042542, 0.8442950248718262, 0.8451164364814758, 0.8459358811378479, 0.8467533588409424, 0.8475688099861145, 0.848382294178009, 0.8491937518119812, 0.850003182888031, 0.8508106470108032, 0.8516161441802979, 0.8524195551872253, 0.8532209992408752, 0.8540204167366028, 0.8548178672790527, 0.8556132912635803, 0.8564066886901855, 0.8571980595588684, 0.8579874038696289, 0.858774721622467, 0.8595600128173828, 0.860343337059021, 0.861124575138092, 0.8619038462638855, 0.8626810312271118, 0.8634561896324158, 0.8642293214797974, 0.8650004267692566, 0.8657695055007935, 0.8665364980697632, 0.8673015236854553, 0.8680644631385803, 0.868825376033783, 0.8695842027664185, 0.8703410029411316, 0.8710957765579224, 0.871848464012146, 0.8725991249084473, 0.8733476996421814, 0.8740942478179932, 0.8748387098312378, 0.8755810856819153, 0.8763214945793152, 0.8770597577095032, 0.8777959942817688, 0.8785301446914673, 0.8792622089385986, 0.8799922466278076, 0.8807201981544495, 0.8814460635185242, 0.8821698427200317, 0.8828915357589722, 0.8836112022399902, 0.8843287229537964, 0.8850442171096802, 0.885757565498352, 0.8864688873291016, 0.8871781229972839, 0.8878852128982544, 0.8885902762413025, 0.8892931938171387, 0.8899940252304077, 0.8906927704811096, 0.8913894295692444, 0.8920839428901672, 0.8927764296531677, 0.8934667706489563, 0.8941550254821777, 0.8948411345481873, 0.8955251574516296, 0.8962070941925049, 0.8968868851661682, 0.8975645899772644, 0.8982401490211487, 0.8989136219024658, 0.899584949016571, 0.9002541899681091, 0.9009212851524353, 0.9015862941741943, 0.9022491574287415, 0.9029098749160767, 0.9035685062408447, 0.9042249917984009, 0.9048793315887451, 0.9055315256118774, 0.9061816334724426, 0.9068295955657959, 0.9074754118919373, 0.9081190824508667, 0.9087606072425842, 0.9094000458717346, 0.9100372791290283, 0.9106723666191101, 0.9113053679466248, 0.9119361639022827, 0.9125648736953735, 0.9131913781166077, 0.9138157367706299, 0.9144379496574402, 0.9150580167770386, 0.915675938129425, 0.9162917137145996, 0.9169052839279175, 0.9175167679786682, 0.9181260466575623, 0.9187331199645996, 0.9193381071090698, 0.9199408888816833, 0.920541524887085, 0.9211399555206299, 0.9217362403869629, 0.9223303198814392, 0.9229222536087036, 0.9235120415687561, 0.9240996241569519, 0.9246850609779358, 0.925268292427063, 0.9258493185043335, 0.9264281988143921, 0.927004873752594, 0.927579402923584, 0.9281517267227173, 0.9287218451499939, 0.9292898178100586, 0.9298555850982666, 0.9304191470146179, 0.9309805035591125, 0.9315397143363953, 0.9320966601371765, 0.9326514601707458, 0.9332040548324585, 0.9337545037269592, 0.9343026876449585, 0.9348486661911011, 0.9353924989700317, 0.9359340667724609, 0.9364734888076782, 0.937010645866394, 0.937545657157898, 0.9380784034729004, 0.9386089444160461, 0.93913733959198, 0.9396634697914124, 0.940187394618988, 0.940709114074707, 0.9412285685539246, 0.9417458772659302, 0.9422609210014343, 0.9427737593650818, 0.9432843923568726, 0.9437927603721619, 0.9442989826202393, 0.9448028802871704, 0.9453046321868896, 0.9458041191101074, 0.9463014006614685, 0.9467964172363281, 0.947289228439331, 0.9477798342704773, 0.9482681751251221, 0.9487543106079102, 0.9492381811141968, 0.9497198462486267, 0.9501992464065552, 0.9506763815879822, 0.9511513113975525, 0.9516240358352661, 0.9520944356918335, 0.952562689781189, 0.9530286192893982, 0.9534923434257507, 0.9539538025856018, 0.9544130563735962, 0.9548699855804443, 0.9553247690200806, 0.9557772278785706, 0.9562274217605591, 0.9566754102706909, 0.9571211338043213, 0.9575645923614502, 0.9580057859420776, 0.9584447741508484, 0.9588814377784729, 0.9593158960342407, 0.9597480893135071, 0.960178017616272, 0.9606056809425354, 0.9610310196876526, 0.9614541530609131, 0.9618750214576721, 0.9622936248779297, 0.9627099633216858, 0.9631240367889404, 0.9635358452796936, 0.9639453887939453, 0.9643526077270508, 0.9647576212882996, 0.9651603102684021, 0.9655607342720032, 0.9659588932991028, 0.9663547873497009, 0.9667484164237976, 0.9671397805213928, 0.9675288200378418, 0.9679155945777893, 0.9683001041412354, 0.9686822891235352, 0.9690622687339783, 0.9694399237632751, 0.9698152542114258, 0.9701883792877197, 0.9705591797828674, 0.9709277153015137, 0.9712939262390137, 0.9716578722000122, 0.9720194935798645, 0.9723788499832153, 0.9727359414100647, 0.9730907082557678, 0.9734432101249695, 0.9737934470176697, 0.9741412997245789, 0.9744869470596313, 0.9748302698135376, 0.9751712679862976, 0.9755100011825562, 0.9758464097976685, 0.9761805534362793, 0.9765123724937439, 0.9768418669700623, 0.9771690964698792, 0.9774940013885498, 0.977816641330719, 0.9781369566917419, 0.9784549474716187, 0.9787706732749939, 0.9790840744972229, 0.9793952107429504, 0.979703962802887, 0.980010449886322, 0.9803146123886108, 0.9806165099143982, 0.9809160232543945, 0.9812132716178894, 0.9815082550048828, 0.9818008542060852, 0.9820911884307861, 0.982379138469696, 0.9826648235321045, 0.9829481840133667, 0.9832292795181274, 0.9835079908370972, 0.9837844371795654, 0.9840584993362427, 0.9843302965164185, 0.984599769115448, 0.9848669171333313, 0.9851317405700684, 0.9853942394256592, 0.9856544137001038, 0.9859123229980469, 0.986167848110199, 0.9864210486412048, 0.9866719841957092, 0.9869205355644226, 0.9871667623519897, 0.9874107241630554, 0.9876523017883301, 0.9878915548324585, 0.9881285429000854, 0.9883631467819214, 0.9885954260826111, 0.9888253808021545, 0.9890530109405518, 0.9892783164978027, 0.9895012974739075, 0.9897218942642212, 0.9899402260780334, 0.9901562333106995, 0.9903698563575745, 0.9905811548233032, 0.9907901287078857, 0.990996778011322, 0.9912011027336121, 0.9914031028747559, 0.9916027188301086, 0.9918000102043152, 0.9919949769973755, 0.9921876192092896, 0.9923779368400574, 0.9925658702850342, 0.9927514791488647, 0.9929347634315491, 0.9931157231330872, 0.993294358253479, 0.9934706091880798, 0.9936445355415344, 0.993816077709198, 0.9939853549003601, 0.9941522479057312, 0.994316816329956, 0.9944790601730347, 0.9946389198303223, 0.9947964549064636, 0.994951605796814, 0.9951044917106628, 0.9952549934387207, 0.9954031705856323, 0.9955489635467529, 0.9956924319267273, 0.9958335757255554, 0.9959723353385925, 0.9961087703704834, 0.9962428212165833, 0.9963746070861816, 0.996504008769989, 0.9966310262680054, 0.9967557191848755, 0.9968780875205994, 0.9969980716705322, 0.9971157312393188, 0.9972310662269592, 0.9973440170288086, 0.9974545836448669, 0.9975628852844238, 0.9976687431335449, 0.9977723360061646, 0.9978735446929932, 0.9979723691940308, 0.9980689287185669, 0.9981630444526672, 0.9982548356056213, 0.9983443021774292, 0.9984314441680908, 0.9985162019729614, 0.998598575592041, 0.9986786246299744, 0.9987562894821167, 0.9988316297531128, 0.9989046454429626, 0.9989752769470215, 0.9990435838699341, 0.9991095066070557, 0.999173104763031, 0.9992343187332153, 0.9992931485176086, 0.9993497133255005, 0.9994038343429565, 0.9994556307792664, 0.9995051026344299, 0.9995521903038025, 0.9995969533920288, 0.9996393322944641, 0.9996793866157532, 0.9997170567512512, 0.999752402305603, 0.9997853636741638, 0.9998160004615784, 0.9998442530632019, 0.9998701810836792, 0.9998937249183655, 0.9999148845672607, 0.9999337792396545, 0.9999502301216125, 0.9999643564224243, 0.9999761581420898, 0.9999855756759644, 0.9999926686286926, 0.9999973773956299, 0.9999997019767761, 0.9999997019767761, 0.9999973773956299, 0.9999926686286926, 0.9999855756759644, 0.9999761581420898, 0.9999643564224243, 0.9999502301216125, 0.9999337792396545, 0.9999148845672607, 0.9998937249183655, 0.9998701810836792, 0.9998442530632019, 0.9998160004615784, 0.9997853636741638, 0.999752402305603, 0.9997170567512512, 0.9996793866157532, 0.9996393322944641, 0.9995969533920288, 0.9995521903038025, 0.9995051026344299, 0.9994556307792664, 0.9994038343429565, 0.9993497133255005, 0.9992931485176086, 0.9992343187332153, 0.999173104763031, 0.9991095066070557, 0.9990435838699341, 0.9989752769470215, 0.9989046454429626, 0.9988316297531128, 0.9987562894821167, 0.9986786246299744, 0.998598575592041, 0.9985162019729614, 0.9984314441680908, 0.9983443021774292, 0.9982548356056213, 0.9981630444526672, 0.9980689287185669, 0.9979723691940308, 0.9978735446929932, 0.9977723360061646, 0.9976687431335449, 0.9975628852844238, 0.9974545836448669, 0.9973440170288086, 0.9972310662269592, 0.9971157312393188, 0.9969980716705322, 0.9968780875205994, 0.9967557191848755, 0.9966310262680054, 0.996504008769989, 0.9963746070861816, 0.9962428212165833, 0.9961087703704834, 0.9959723353385925, 0.9958335757255554, 0.9956924319267273, 0.9955489635467529, 0.9954031705856323, 0.9952549934387207, 0.9951044917106628, 0.994951605796814, 0.9947964549064636, 0.9946389198303223, 0.9944790601730347, 0.994316816329956, 0.9941522479057312, 0.9939853549003601, 0.993816077709198, 0.9936445355415344, 0.9934706091880798, 0.993294358253479, 0.9931157231330872, 0.9929347634315491, 0.9927514791488647, 0.9925658702850342, 0.9923779368400574, 0.9921876192092896, 0.9919949769973755, 0.9918000102043152, 0.9916027188301086, 0.9914031028747559, 0.9912011027336121, 0.990996778011322, 0.9907901287078857, 0.9905811548233032, 0.9903698563575745, 0.9901562333106995, 0.9899402260780334, 0.9897218942642212, 0.9895012974739075, 0.9892783164978027, 0.9890530109405518, 0.9888253808021545, 0.9885954260826111, 0.9883631467819214, 0.9881285429000854, 0.9878915548324585, 0.9876523017883301, 0.9874107241630554, 0.9871667623519897, 0.9869205355644226, 0.9866719841957092, 0.9864210486412048, 0.986167848110199, 0.9859123229980469, 0.9856544137001038, 0.9853942394256592, 0.9851317405700684, 0.9848669171333313, 0.984599769115448, 0.9843302965164185, 0.9840584993362427, 0.9837844371795654, 0.9835079908370972, 0.9832292795181274, 0.9829481840133667, 0.9826648235321045, 0.982379138469696, 0.9820911884307861, 0.9818008542060852, 0.9815082550048828, 0.9812132716178894, 0.9809160232543945, 0.9806165099143982, 0.9803146123886108, 0.980010449886322, 0.979703962802887, 0.9793952107429504, 0.9790840744972229, 0.9787706732749939, 0.9784549474716187, 0.9781369566917419, 0.977816641330719, 0.9774940013885498, 0.9771690964698792, 0.9768418669700623, 0.9765123724937439, 0.9761805534362793, 0.9758464097976685, 0.9755100011825562, 0.9751712679862976, 0.9748302698135376, 0.9744869470596313, 0.9741412997245789, 0.9737934470176697, 0.9734432101249695, 0.9730907082557678, 0.9727359414100647, 0.9723788499832153, 0.9720194935798645, 0.9716578722000122, 0.9712939262390137, 0.9709277153015137, 0.9705591797828674, 0.9701883792877197, 0.9698152542114258, 0.9694399237632751, 0.9690622687339783, 0.9686822891235352, 0.9683001041412354, 0.9679155945777893, 0.9675288200378418, 0.9671397805213928, 0.9667484164237976, 0.9663547873497009, 0.9659588932991028, 0.9655607342720032, 0.9651603102684021, 0.9647576212882996, 0.9643526077270508, 0.9639453887939453, 0.9635358452796936, 0.9631240367889404, 0.9627099633216858, 0.9622936248779297, 0.9618750214576721, 0.9614541530609131, 0.9610310196876526, 0.9606056809425354, 0.960178017616272, 0.9597480893135071, 0.9593158960342407, 0.9588814377784729, 0.9584447741508484, 0.9580057859420776, 0.9575645923614502, 0.9571211338043213, 0.9566754102706909, 0.9562274217605591, 0.9557772278785706, 0.9553247690200806, 0.9548699855804443, 0.9544130563735962, 0.9539538025856018, 0.9534923434257507, 0.9530286192893982, 0.952562689781189, 0.9520944356918335, 0.9516240358352661, 0.9511513113975525, 0.9506763815879822, 0.9501992464065552, 0.9497198462486267, 0.9492381811141968, 0.9487543106079102, 0.9482681751251221, 0.9477798342704773, 0.947289228439331, 0.9467964172363281, 0.9463014006614685, 0.9458041191101074, 0.9453046321868896, 0.9448028802871704, 0.9442989826202393, 0.9437927603721619, 0.9432843923568726, 0.9427737593650818, 0.9422609210014343, 0.9417458772659302, 0.9412285685539246, 0.940709114074707, 0.940187394618988, 0.9396634697914124, 0.93913733959198, 0.9386089444160461, 0.9380784034729004, 0.937545657157898, 0.937010645866394, 0.9364734888076782, 0.9359340667724609, 0.9353924989700317, 0.9348486661911011, 0.9343026876449585, 0.9337545037269592, 0.9332040548324585, 0.9326514601707458, 0.9320966601371765, 0.9315397143363953, 0.9309805035591125, 0.9304191470146179, 0.9298555850982666, 0.9292898178100586, 0.9287218451499939, 0.9281517267227173, 0.927579402923584, 0.927004873752594, 0.9264281988143921, 0.9258493185043335, 0.925268292427063, 0.9246850609779358, 0.9240996241569519, 0.9235120415687561, 0.9229222536087036, 0.9223303198814392, 0.9217362403869629, 0.9211399555206299, 0.920541524887085, 0.9199408888816833, 0.9193381071090698, 0.9187331199645996, 0.9181260466575623, 0.9175167679786682, 0.9169052839279175, 0.9162917137145996, 0.915675938129425, 0.9150580167770386, 0.9144379496574402, 0.9138157367706299, 0.9131913781166077, 0.9125648736953735, 0.9119361639022827, 0.9113053679466248, 0.9106723666191101, 0.9100372791290283, 0.9094000458717346, 0.9087606072425842, 0.9081190824508667, 0.9074754118919373, 0.9068295955657959, 0.9061816334724426, 0.9055315256118774, 0.9048793315887451, 0.9042249917984009, 0.9035685062408447, 0.9029098749160767, 0.9022491574287415, 0.9015862941741943, 0.9009212851524353, 0.9002541899681091, 0.899584949016571, 0.8989136219024658, 0.8982401490211487, 0.8975645899772644, 0.8968868851661682, 0.8962070941925049, 0.8955251574516296, 0.8948411345481873, 0.8941550254821777, 0.8934667706489563, 0.8927764296531677, 0.8920839428901672, 0.8913894295692444, 0.8906927704811096, 0.8899940252304077, 0.8892931938171387, 0.8885902762413025, 0.8878852128982544, 0.8871781229972839, 0.8864688873291016, 0.885757565498352, 0.8850442171096802, 0.8843287229537964, 0.8836112022399902, 0.8828915357589722, 0.8821698427200317, 0.8814460635185242, 0.8807201981544495, 0.8799922466278076, 0.8792622089385986, 0.8785301446914673, 0.8777959942817688, 0.8770597577095032, 0.8763214945793152, 0.8755810856819153, 0.8748387098312378, 0.8740942478179932, 0.8733476996421814, 0.8725991249084473, 0.871848464012146, 0.8710957765579224, 0.8703410029411316, 0.8695842027664185, 0.868825376033783, 0.8680644631385803, 0.8673015236854553, 0.8665364980697632, 0.8657695055007935, 0.8650004267692566, 0.8642293214797974, 0.8634561896324158, 0.8626810312271118, 0.8619038462638855, 0.861124575138092, 0.860343337059021, 0.8595600128173828, 0.858774721622467, 0.8579874038696289, 0.8571980595588684, 0.8564066886901855, 0.8556132912635803, 0.8548178672790527, 0.8540204167366028, 0.8532209992408752, 0.8524195551872253, 0.8516161441802979, 0.8508106470108032, 0.850003182888031, 0.8491937518119812, 0.848382294178009, 0.8475688099861145, 0.8467533588409424, 0.8459358811378479, 0.8451164364814758, 0.8442950248718262, 0.8434715867042542, 0.8426461815834045, 0.8418188095092773, 0.8409894108772278, 0.8401580452919006, 0.8393247127532959, 0.8384894132614136, 0.8376521468162537, 0.8368128538131714, 0.8359716534614563, 0.8351284265518188, 0.8342832326889038, 0.833436131477356, 0.8325870037078857, 0.8317359685897827, 0.8308829665184021, 0.8300279974937439, 0.8291710615158081, 0.8283121585845947, 0.8274513483047485, 0.8265885710716248, 0.8257238268852234, 0.8248571157455444, 0.8239885568618774, 0.8231179714202881, 0.8222454786300659, 0.8213710188865662, 0.8204946517944336, 0.8196163773536682, 0.8187361359596252, 0.8178539872169495, 0.8169698715209961, 0.8160839080810547, 0.8151959776878357, 0.8143060803413391, 0.8134143352508545, 0.8125206232070923, 0.811625063419342, 0.8107275366783142, 0.8098281025886536, 0.8089267611503601, 0.8080235123634338, 0.8071184158325195, 0.8062113523483276, 0.8053024411201477, 0.8043915629386902, 0.8034788370132446, 0.802564263343811, 0.8016477227210999, 0.8007293343544006, 0.7998090386390686, 0.7988868951797485, 0.7979628443717957, 0.79703688621521, 0.7961090803146362, 0.7951793670654297, 0.7942478656768799, 0.7933143973350525, 0.7923791408538818, 0.7914419770240784, 0.7905029058456421, 0.7895620465278625, 0.7886192798614502, 0.7876746654510498, 0.7867282032966614, 0.7857798933982849, 0.7848297357559204, 0.7838777303695679, 0.7829238772392273, 0.7819681763648987, 0.781010627746582, 0.7800512313842773, 0.7790899872779846, 0.7781269550323486, 0.7771620750427246, 0.7761953473091125, 0.7752267718315125, 0.7742564082145691, 0.7732841968536377, 0.772310197353363, 0.7713343501091003, 0.7703567147254944, 0.7693772315979004, 0.7683959603309631, 0.7674128413200378, 0.7664279341697693, 0.7654412388801575, 0.7644527554512024, 0.7634624242782593, 0.7624703049659729, 0.7614763975143433, 0.7604807019233704, 0.7594832181930542, 0.7584839463233948, 0.7574828863143921, 0.7564800381660461, 0.7554754018783569, 0.7544689774513245, 0.7534608244895935, 0.7524508237838745, 0.751439094543457, 0.7504256367683411, 0.7494103312492371, 0.7483932971954346, 0.7473745346069336, 0.7463539242744446, 0.7453316450119019, 0.7443075776100159, 0.7432817220687866, 0.7422541379928589, 0.7412248253822327, 0.740193784236908, 0.73916095495224, 0.7381263971328735, 0.7370901107788086, 0.7360520958900452, 0.7350122928619385, 0.7339708209037781, 0.7329275608062744, 0.731882631778717, 0.7308359742164612, 0.7297875881195068, 0.728737473487854, 0.7276856303215027, 0.7266320586204529, 0.7255768179893494, 0.7245198488235474, 0.7234612107276917, 0.7224007844924927, 0.7213387489318848, 0.7202749848365784, 0.7192094922065735, 0.7181423306465149, 0.7170734405517578, 0.7160029411315918, 0.7149306535720825, 0.7138567566871643, 0.7127811908721924, 0.711703896522522, 0.7106249332427979, 0.70954430103302, 0.7084619998931885, 0.7073780298233032, 0.7062923908233643, 0.7052050828933716, 0.70411616563797, 0.7030255198478699, 0.7019332647323608, 0.7008393406867981, 0.6997437477111816, 0.6986465454101562, 0.6975476741790771, 0.6964471340179443, 0.6953449845314026, 0.6942411661148071, 0.6931357383728027, 0.6920287013053894, 0.6909199953079224, 0.6898096799850464, 0.6886977553367615, 0.6875841617584229, 0.6864690184593201, 0.6853522062301636, 0.6842337846755981, 0.6831137537956238, 0.6819921135902405, 0.6808688640594482, 0.6797440648078918, 0.6786175966262817, 0.6774895191192627, 0.6763598918914795, 0.6752286553382874, 0.674095869064331, 0.672961413860321, 0.6718254089355469, 0.6706878542900085, 0.6695486903190613, 0.6684079766273499, 0.6672656536102295, 0.666121780872345, 0.6649762988090515, 0.6638292670249939, 0.6626806855201721, 0.6615305542945862, 0.6603788733482361, 0.659225583076477, 0.6580708026885986, 0.656914472579956, 0.6557565331459045, 0.6545971035957336, 0.6534360647201538, 0.6522735357284546, 0.651109516620636, 0.6499438881874084, 0.6487767696380615, 0.6476081013679504, 0.64643794298172, 0.6452661752700806, 0.6440929770469666, 0.6429182291030884, 0.6417419910430908, 0.6405642032623291, 0.639384925365448, 0.6382041573524475, 0.6370218396186829, 0.6358380317687988, 0.6346527934074402, 0.6334660053253174, 0.6322777271270752, 0.6310879588127136, 0.6298967003822327, 0.6287039518356323, 0.6275097727775574, 0.6263140439987183, 0.6251168847084045, 0.6239182353019714, 0.6227181553840637, 0.6215165853500366, 0.6203135251998901, 0.619109034538269, 0.6179030537605286, 0.6166956424713135, 0.6154868006706238, 0.6142764687538147, 0.613064706325531, 0.6118514537811279, 0.610636830329895, 0.6094207167625427, 0.6082032322883606, 0.6069842576980591, 0.605763852596283, 0.604542076587677, 0.6033188104629517, 0.6020941734313965, 0.6008681058883667, 0.5996406078338623, 0.5984116792678833, 0.5971813797950745, 0.595949649810791, 0.5947165489196777, 0.5934820175170898, 0.5922461152076721, 0.5910087823867798, 0.5897700786590576, 0.5885300040245056, 0.587288498878479, 0.5860456228256226, 0.5848013758659363, 0.5835557579994202, 0.5823087692260742, 0.5810604095458984, 0.579810619354248, 0.5785595178604126, 0.5773070454597473, 0.576053261756897, 0.574798047542572, 0.573541522026062, 0.5722836256027222, 0.5710243582725525, 0.5697637796401978, 0.568501889705658, 0.5672386288642883, 0.5659739971160889, 0.5647080540657043, 0.5634407997131348, 0.5621722340583801, 0.5609022974967957, 0.5596310496330261, 0.5583585500717163, 0.5570846796035767, 0.555809497833252, 0.5545330047607422, 0.5532552003860474, 0.5519760847091675, 0.5506957173347473, 0.5494139790534973, 0.548130989074707, 0.5468467473983765, 0.5455611348152161, 0.5442742705345154, 0.5429861545562744, 0.5416967272758484, 0.5404060482978821, 0.5391140580177307, 0.5378208756446838, 0.5365263223648071, 0.5352305769920349, 0.5339335799217224, 0.5326352715492249, 0.531335711479187, 0.5300349593162537, 0.5287328958511353, 0.5274296402931213, 0.5261251330375671, 0.5248193144798279, 0.5235123634338379, 0.5222041010856628, 0.5208946466445923, 0.5195839405059814, 0.5182720422744751, 0.5169588923454285, 0.5156445503234863, 0.5143289566040039, 0.513012170791626, 0.5116941928863525, 0.5103750228881836, 0.5090546011924744, 0.5077330470085144, 0.5064102411270142, 0.5050862431526184, 0.5037611126899719, 0.5024347305297852, 0.5011072158813477, 0.4997784495353699, 0.49844855070114136, 0.4971174895763397, 0.4957852363586426, 0.4944518208503723, 0.49311724305152893, 0.4917815327644348, 0.4904446303844452, 0.48910656571388245, 0.48776736855506897, 0.4864270091056824, 0.48508551716804504, 0.4837428629398346, 0.4823991060256958, 0.4810541868209839, 0.47970813512802124, 0.47836095094680786, 0.47701263427734375, 0.4756632149219513, 0.4743126630783081, 0.4729609787464142, 0.4716082215309143, 0.4702543020248413, 0.46889930963516235, 0.46754321455955505, 0.4661860167980194, 0.4648277163505554, 0.4634683132171631, 0.4621078073978424, 0.46074622869491577, 0.4593835771083832, 0.45801982283592224, 0.45665499567985535, 0.4552890956401825, 0.4539221227169037, 0.4525540769100189, 0.4511849880218506, 0.4498147964477539, 0.44844356179237366, 0.44707128405570984, 0.44569796323776245, 0.4443235695362091, 0.4429481327533722, 0.4415716528892517, 0.44019412994384766, 0.43881556391716003, 0.43743598461151123, 0.43605536222457886, 0.4346736967563629, 0.4332910478115082, 0.4319073557853699, 0.4305226504802704, 0.4291369318962097, 0.4277501702308655, 0.42636245489120483, 0.4249736964702606, 0.4235839545726776, 0.4221931993961334, 0.42080146074295044, 0.41940873861312866, 0.4180150330066681, 0.41662031412124634, 0.4152246415615082, 0.4138279855251312, 0.4124303460121155, 0.41103172302246094, 0.40963214635849, 0.40823161602020264, 0.4068301022052765, 0.4054276645183563, 0.40402424335479736, 0.402619868516922, 0.4012145400047302, 0.39980828762054443, 0.39840108156204224, 0.396992951631546, 0.3955838680267334, 0.39417386054992676, 0.3927629292011261, 0.3913510739803314, 0.3899382948875427, 0.38852459192276, 0.3871099650859833, 0.3856944441795349, 0.38427799940109253, 0.3828606605529785, 0.38144242763519287, 0.3800232708454132, 0.3786032497882843, 0.3771823048591614, 0.3757604956626892, 0.3743377923965454, 0.37291419506073, 0.3714897334575653, 0.3700644075870514, 0.36863818764686584, 0.36721113324165344, 0.3657831847667694, 0.36435437202453613, 0.362924724817276, 0.3614942133426666, 0.360062837600708, 0.35863062739372253, 0.3571975529193878, 0.35576364398002625, 0.3543289005756378, 0.35289332270622253, 0.3514569401741028, 0.3500196933746338, 0.3485816419124603, 0.34714275598526, 0.3457030653953552, 0.3442625403404236, 0.34282124042510986, 0.3413791060447693, 0.33993616700172424, 0.33849242329597473, 0.33704790472984314, 0.3356025815010071, 0.33415645360946655, 0.33270955085754395, 0.33126187324523926, 0.3298133909702301, 0.32836416363716125, 0.32691413164138794, 0.32546335458755493, 0.32401180267333984, 0.3225594758987427, 0.3211064040660858, 0.3196525573730469, 0.31819799542427063, 0.3167426586151123, 0.3152865767478943, 0.3138297498226166, 0.3123721778392792, 0.31091389060020447, 0.30945485830307007, 0.307995080947876, 0.3065345883369446, 0.3050733804702759, 0.3036114573478699, 0.30214881896972656, 0.30068546533584595, 0.299221396446228, 0.2977566421031952, 0.29629117250442505, 0.29482501745224, 0.2933581471443176, 0.29189059138298035, 0.29042235016822815, 0.28895342350006104, 0.2874838411808014, 0.28601354360580444, 0.28454259037971497, 0.28307098150253296, 0.28159868717193604, 0.2801257371902466, 0.2786521017551422, 0.2771778404712677, 0.27570292353630066, 0.2742273509502411, 0.272751122713089, 0.27127426862716675, 0.269796758890152, 0.26831862330436707, 0.266839861869812, 0.2653604745864868, 0.2638804614543915, 0.262399822473526, 0.2609185576438904, 0.2594366669654846, 0.2579541802406311, 0.25647109746932983, 0.2549873888492584, 0.25350308418273926, 0.2520182132720947, 0.25053271651268005, 0.24904663860797882, 0.24755996465682983, 0.24607272446155548, 0.24458488821983337, 0.2430964857339859, 0.24160750210285187, 0.24011796712875366, 0.2386278510093689, 0.23713718354701996, 0.23564594984054565, 0.23415414988994598, 0.23266181349754333, 0.2311689257621765, 0.2296755015850067, 0.22818152606487274, 0.2266870141029358, 0.22519196569919586, 0.22369639575481415, 0.22220028936862946, 0.22070367634296417, 0.2192065268754959, 0.21770887076854706, 0.21621069312095642, 0.2147120088338852, 0.21321281790733337, 0.21171313524246216, 0.21021294593811035, 0.20871224999427795, 0.20721107721328735, 0.20570941269397736, 0.20420727133750916, 0.20270463824272156, 0.20120152831077576, 0.19969795644283295, 0.19819389283657074, 0.19668938219547272, 0.1951843947172165, 0.19367896020412445, 0.1921730637550354, 0.19066670536994934, 0.18915991485118866, 0.18765266239643097, 0.18614497780799866, 0.18463686108589172, 0.18312829732894897, 0.1816193014383316, 0.1801098883152008, 0.17860004305839539, 0.17708978056907654, 0.17557910084724426, 0.17406800389289856, 0.17255648970603943, 0.17104458808898926, 0.16953226923942566, 0.16801954805850983, 0.16650643944740295, 0.16499294340610504, 0.1634790599346161, 0.1619647741317749, 0.16045011579990387, 0.158935084939003, 0.15741968154907227, 0.1559039056301117, 0.15438775718212128, 0.152871236205101, 0.1513543725013733, 0.14983715116977692, 0.1483195722103119, 0.1468016356229782, 0.14528335630893707, 0.14376474916934967, 0.14224578440189362, 0.1407264918088913, 0.1392068713903427, 0.13768692314624786, 0.13616664707660675, 0.13464605808258057, 0.13312514126300812, 0.1316039115190506, 0.1300823837518692, 0.12856054306030273, 0.1270383894443512, 0.12551595270633698, 0.12399320304393768, 0.1224701777100563, 0.12094685435295105, 0.11942324787378311, 0.11789935827255249, 0.11637520045042038, 0.11485075950622559, 0.1133260503411293, 0.11180107295513153, 0.11027583479881287, 0.10875033587217331, 0.10722457617521286, 0.10569857060909271, 0.10417231172323227, 0.10264581441879272, 0.10111907124519348, 0.09959208965301514, 0.09806486964225769, 0.09653741866350174, 0.09500974416732788, 0.09348184615373611, 0.09195373207330704, 0.09042539447546005, 0.08889684826135635, 0.08736808598041534, 0.08583912253379822, 0.08430995792150497, 0.08278059214353561, 0.08125103265047073, 0.07972127944231033, 0.07819133996963501, 0.07666122168302536, 0.07513091713190079, 0.07360043376684189, 0.07206977903842926, 0.0705389603972435, 0.06900797039270401, 0.06747681647539139, 0.06594550609588623, 0.06441403925418854, 0.0628824234008789, 0.06135065481066704, 0.05981874465942383, 0.05828669294714928, 0.05675450339913368, 0.05522217974066734, 0.053689729422330856, 0.05215714871883392, 0.05062444508075714, 0.04909162595868111, 0.04755868762731552, 0.04602564126253128, 0.044492483139038086, 0.042959220707416534, 0.041425857692956924, 0.039892397820949554, 0.038358841091394424, 0.03682519495487213, 0.035291463136672974, 0.03375764936208725, 0.03222375363111496, 0.0306897833943367, 0.02915574051439762, 0.02762162871658802, 0.026087453588843346, 0.024553215131163597, 0.023018918931484222, 0.02148456871509552, 0.01995016820728779, 0.018415721133351326, 0.016881229355931282, 0.015346699394285679, 0.013812132179737091, 0.012277533300220966, 0.010742904618382454, 0.009208250790834427, 0.007673575542867184, 0.0061388821341097355, 0.004604174289852381, 0.0030694555025547743, 0.0015347296139225364, 1.2246468525851679e-16 ] ================================================ FILE: __tests__/data/sine256.json ================================================ [ 0, 0.012319659814238548, 0.02463744953274727, 0.03695150092244148, 0.04925994202494621, 0.06156090646982193, 0.0738525241613388, 0.08613293617963791, 0.09840027987957001, 0.11065268516540527, 0.12288828939199448, 0.13510525226593018, 0.14730170369148254, 0.15947578847408295, 0.17162567377090454, 0.1837495118379593, 0.19584546983242035, 0.2079116851091385, 0.21994635462760925, 0.2319476455450058, 0.24391372501850128, 0.25584277510643005, 0.26773300766944885, 0.27958258986473083, 0.29138973355293274, 0.3031526803970337, 0.31486958265304565, 0.32653871178627014, 0.3381582796573639, 0.34972649812698364, 0.3612416684627533, 0.3727020025253296, 0.38410574197769165, 0.39545121788978577, 0.4067366421222687, 0.41796034574508667, 0.42912060022354126, 0.44021573662757874, 0.451244056224823, 0.46220389008522034, 0.47309356927871704, 0.4839114248752594, 0.4946558475494385, 0.505325198173523, 0.5159178376197815, 0.5264321565628052, 0.5368666052818298, 0.5472195744514465, 0.5574894547462463, 0.5676746964454651, 0.5777738094329834, 0.5877852439880371, 0.5977074503898621, 0.6075389385223389, 0.6172782182693481, 0.6269237995147705, 0.6364742517471313, 0.6459280848503113, 0.6552838683128357, 0.66454017162323, 0.6736956238746643, 0.6827488541603088, 0.691698431968689, 0.7005430459976196, 0.709281325340271, 0.7179118990898132, 0.7264335751533508, 0.734844982624054, 0.7431448101997375, 0.7513318657875061, 0.7594048976898193, 0.767362654209137, 0.7752040028572083, 0.7829276323318481, 0.7905324101448059, 0.7980172038078308, 0.8053809404373169, 0.8126223683357239, 0.8197404742240906, 0.826734185218811, 0.8336023688316345, 0.8403440713882446, 0.8469582200050354, 0.8534438014030457, 0.859799861907959, 0.8660253882408142, 0.8721194863319397, 0.8780812621116638, 0.8839097023010254, 0.8896040320396423, 0.8951632976531982, 0.900586724281311, 0.9058734178543091, 0.9110226631164551, 0.9160336256027222, 0.9209055304527283, 0.9256376624107361, 0.9302293062210083, 0.9346797466278076, 0.9389883875846863, 0.9431544542312622, 0.9471773505210876, 0.9510565400123596, 0.9547913074493408, 0.9583812355995178, 0.9618256688117981, 0.9651240706443787, 0.9682760238647461, 0.9712810516357422, 0.974138617515564, 0.976848304271698, 0.9794097542762756, 0.9818225502967834, 0.9840863347053528, 0.986200749874115, 0.9881654977798462, 0.9899802207946777, 0.9916446805000305, 0.9931586384773254, 0.9945219159126282, 0.9957341551780701, 0.9967952966690063, 0.9977051615715027, 0.9984636306762695, 0.9990704655647278, 0.9995257258415222, 0.9998292326927185, 0.9999810457229614, 0.9999810457229614, 0.9998292326927185, 0.9995257258415222, 0.9990704655647278, 0.9984636306762695, 0.9977051615715027, 0.9967952966690063, 0.9957341551780701, 0.9945219159126282, 0.9931586384773254, 0.9916446805000305, 0.9899802207946777, 0.9881654977798462, 0.986200749874115, 0.9840863347053528, 0.9818225502967834, 0.9794097542762756, 0.976848304271698, 0.974138617515564, 0.9712810516357422, 0.9682760238647461, 0.9651240706443787, 0.9618256688117981, 0.9583812355995178, 0.9547913074493408, 0.9510565400123596, 0.9471773505210876, 0.9431544542312622, 0.9389883875846863, 0.9346797466278076, 0.9302293062210083, 0.9256376624107361, 0.9209055304527283, 0.9160336256027222, 0.9110226631164551, 0.9058734178543091, 0.900586724281311, 0.8951632976531982, 0.8896040320396423, 0.8839097023010254, 0.8780812621116638, 0.8721194863319397, 0.8660253882408142, 0.859799861907959, 0.8534438014030457, 0.8469582200050354, 0.8403440713882446, 0.8336023688316345, 0.826734185218811, 0.8197404742240906, 0.8126223683357239, 0.8053809404373169, 0.7980172038078308, 0.7905324101448059, 0.7829276323318481, 0.7752040028572083, 0.767362654209137, 0.7594048976898193, 0.7513318657875061, 0.7431448101997375, 0.734844982624054, 0.7264335751533508, 0.7179118990898132, 0.709281325340271, 0.7005430459976196, 0.691698431968689, 0.6827488541603088, 0.6736956238746643, 0.66454017162323, 0.6552838683128357, 0.6459280848503113, 0.6364742517471313, 0.6269237995147705, 0.6172782182693481, 0.6075389385223389, 0.5977074503898621, 0.5877852439880371, 0.5777738094329834, 0.5676746964454651, 0.5574894547462463, 0.5472195744514465, 0.5368666052818298, 0.5264321565628052, 0.5159178376197815, 0.505325198173523, 0.4946558475494385, 0.4839114248752594, 0.47309356927871704, 0.46220389008522034, 0.451244056224823, 0.44021573662757874, 0.42912060022354126, 0.41796034574508667, 0.4067366421222687, 0.39545121788978577, 0.38410574197769165, 0.3727020025253296, 0.3612416684627533, 0.34972649812698364, 0.3381582796573639, 0.32653871178627014, 0.31486958265304565, 0.3031526803970337, 0.29138973355293274, 0.27958258986473083, 0.26773300766944885, 0.25584277510643005, 0.24391372501850128, 0.2319476455450058, 0.21994635462760925, 0.2079116851091385, 0.19584546983242035, 0.1837495118379593, 0.17162567377090454, 0.15947578847408295, 0.14730170369148254, 0.13510525226593018, 0.12288828939199448, 0.11065268516540527, 0.09840027987957001, 0.08613293617963791, 0.0738525241613388, 0.06156090646982193, 0.04925994202494621, 0.03695150092244148, 0.02463744953274727, 0.012319659814238548, 1.2246468525851679e-16 ] ================================================ FILE: __tests__/data/sine512.json ================================================ [ 0, 0.006147892214357853, 0.012295551598072052, 0.018442746251821518, 0.02458924427628517, 0.03073481284081936, 0.036879219114780426, 0.04302223399281502, 0.04916362091898918, 0.05530314892530441, 0.06144058704376221, 0.06757570058107376, 0.07370826601982117, 0.07983803749084473, 0.08596479892730713, 0.09208830446004868, 0.09820833802223206, 0.10432465374469757, 0.11043702811002731, 0.11654522269964218, 0.12264902144670486, 0.12874817848205566, 0.13484247028827667, 0.14093166589736938, 0.1470155268907547, 0.1530938446521759, 0.1591663658618927, 0.16523288190364838, 0.17129313945770264, 0.17734692990779877, 0.18339401483535767, 0.18943417072296143, 0.19546717405319214, 0.2014927715063095, 0.20751076936721802, 0.21352091431617737, 0.21952299773693085, 0.22551676630973816, 0.23150202631950378, 0.23747853934764862, 0.24344606697559357, 0.2494044005870819, 0.25535330176353455, 0.26129254698753357, 0.26722192764282227, 0.27314120531082153, 0.27905014157295227, 0.28494855761528015, 0.2908361852169037, 0.29671281576156616, 0.30257824063301086, 0.3084322214126587, 0.31427454948425293, 0.32010501623153687, 0.3259233832359314, 0.3317294120788574, 0.3375228941440582, 0.3433036506175995, 0.3490714132785797, 0.3548259735107422, 0.3605671226978302, 0.36629465222358704, 0.372008353471756, 0.37770795822143555, 0.3833933174610138, 0.38906416296958923, 0.39472031593322754, 0.4003615379333496, 0.4059876501560211, 0.41159841418266296, 0.41719359159469604, 0.4227730333805084, 0.4283364713191986, 0.4338837265968323, 0.4394145905971527, 0.4449288547039032, 0.45042628049850464, 0.4559066891670227, 0.4613698720932007, 0.46681562066078186, 0.47224369645118713, 0.47765395045280457, 0.48304614424705505, 0.4884200692176819, 0.49377554655075073, 0.4991123676300049, 0.5044302940368652, 0.5097292065620422, 0.515008807182312, 0.5202689170837402, 0.5255094170570374, 0.5307300686836243, 0.5359306335449219, 0.5411109328269958, 0.5462707877159119, 0.5514099597930908, 0.5565283298492432, 0.5616256594657898, 0.5667017698287964, 0.5717564225196838, 0.5767894983291626, 0.5818007588386536, 0.5867900252342224, 0.5917571783065796, 0.5967018604278564, 0.601624071598053, 0.6065235137939453, 0.6114000082015991, 0.6162534356117249, 0.6210835576057434, 0.6258901953697205, 0.6306731700897217, 0.6354323029518127, 0.6401674151420593, 0.6448783874511719, 0.6495649218559265, 0.6542268991470337, 0.6588642001152039, 0.6634765863418579, 0.6680638790130615, 0.6726258993148804, 0.6771625280380249, 0.6816735863685608, 0.6861588358879089, 0.6906181573867798, 0.695051372051239, 0.6994583010673523, 0.7038388252258301, 0.708192765712738, 0.7125198841094971, 0.7168201208114624, 0.7210932374000549, 0.7253391146659851, 0.7295575737953186, 0.7337484359741211, 0.737911581993103, 0.7420468330383301, 0.7461540102958679, 0.7502330541610718, 0.7542836666107178, 0.7583057880401611, 0.7622992992401123, 0.7662639617919922, 0.7701996564865112, 0.7741062045097351, 0.777983546257019, 0.7818315029144287, 0.785649836063385, 0.7894385457038879, 0.7931973934173584, 0.7969262599945068, 0.8006249666213989, 0.8042934536933899, 0.8079315423965454, 0.8115390539169312, 0.8151159286499023, 0.8186619877815247, 0.8221771121025085, 0.8256611227989197, 0.8291139602661133, 0.832535445690155, 0.8359254598617554, 0.8392838835716248, 0.8426105976104736, 0.8459054827690125, 0.8491683602333069, 0.8523991703987122, 0.855597734451294, 0.8587639331817627, 0.8618977069854736, 0.8649989366531372, 0.8680674433708191, 0.8711031079292297, 0.8741058707237244, 0.8770756125450134, 0.8800122141838074, 0.8829154968261719, 0.8857854604721069, 0.8886219263076782, 0.891424834728241, 0.8941940069198608, 0.8969293832778931, 0.8996308445930481, 0.9022983312606812, 0.9049317240715027, 0.9075309038162231, 0.910095751285553, 0.9126262664794922, 0.9151222109794617, 0.9175836443901062, 0.9200103282928467, 0.9224022626876831, 0.9247593283653259, 0.9270814657211304, 0.9293685555458069, 0.9316204786300659, 0.9338372349739075, 0.9360186457633972, 0.9381647109985352, 0.9402753114700317, 0.9423503875732422, 0.944389820098877, 0.946393609046936, 0.9483615756034851, 0.9502937197685242, 0.9521899223327637, 0.9540501832962036, 0.9558743238449097, 0.9576623439788818, 0.9594141840934753, 0.9611297845840454, 0.9628090262413025, 0.9644519090652466, 0.9660583138465881, 0.9676281809806824, 0.9691615104675293, 0.9706581830978394, 0.9721181988716125, 0.9735414385795593, 0.9749279022216797, 0.9762775301933289, 0.9775902032852173, 0.9788659811019897, 0.9801047444343567, 0.9813064932823181, 0.9824711084365845, 0.9835985898971558, 0.9846888780593872, 0.9857419729232788, 0.9867578148841858, 0.9877364039421082, 0.9886775612831116, 0.9895814061164856, 0.9904478788375854, 0.9912768602371216, 0.9920684099197388, 0.9928224086761475, 0.9935389757156372, 0.9942179322242737, 0.9948592782020569, 0.9954630732536316, 0.9960291981697083, 0.9965577125549316, 0.997048556804657, 0.9975017309188843, 0.9979171752929688, 0.9982948899269104, 0.9986348748207092, 0.9989371299743652, 0.9992016553878784, 0.999428391456604, 0.999617338180542, 0.9997684955596924, 0.9998818635940552, 0.9999575018882751, 0.9999952912330627, 0.9999952912330627, 0.9999575018882751, 0.9998818635940552, 0.9997684955596924, 0.999617338180542, 0.999428391456604, 0.9992016553878784, 0.9989371299743652, 0.9986348748207092, 0.9982948899269104, 0.9979171752929688, 0.9975017309188843, 0.997048556804657, 0.9965577125549316, 0.9960291981697083, 0.9954630732536316, 0.9948592782020569, 0.9942179322242737, 0.9935389757156372, 0.9928224086761475, 0.9920684099197388, 0.9912768602371216, 0.9904478788375854, 0.9895814061164856, 0.9886775612831116, 0.9877364039421082, 0.9867578148841858, 0.9857419729232788, 0.9846888780593872, 0.9835985898971558, 0.9824711084365845, 0.9813064932823181, 0.9801047444343567, 0.9788659811019897, 0.9775902032852173, 0.9762775301933289, 0.9749279022216797, 0.9735414385795593, 0.9721181988716125, 0.9706581830978394, 0.9691615104675293, 0.9676281809806824, 0.9660583138465881, 0.9644519090652466, 0.9628090262413025, 0.9611297845840454, 0.9594141840934753, 0.9576623439788818, 0.9558743238449097, 0.9540501832962036, 0.9521899223327637, 0.9502937197685242, 0.9483615756034851, 0.946393609046936, 0.944389820098877, 0.9423503875732422, 0.9402753114700317, 0.9381647109985352, 0.9360186457633972, 0.9338372349739075, 0.9316204786300659, 0.9293685555458069, 0.9270814657211304, 0.9247593283653259, 0.9224022626876831, 0.9200103282928467, 0.9175836443901062, 0.9151222109794617, 0.9126262664794922, 0.910095751285553, 0.9075309038162231, 0.9049317240715027, 0.9022983312606812, 0.8996308445930481, 0.8969293832778931, 0.8941940069198608, 0.891424834728241, 0.8886219263076782, 0.8857854604721069, 0.8829154968261719, 0.8800122141838074, 0.8770756125450134, 0.8741058707237244, 0.8711031079292297, 0.8680674433708191, 0.8649989366531372, 0.8618977069854736, 0.8587639331817627, 0.855597734451294, 0.8523991703987122, 0.8491683602333069, 0.8459054827690125, 0.8426105976104736, 0.8392838835716248, 0.8359254598617554, 0.832535445690155, 0.8291139602661133, 0.8256611227989197, 0.8221771121025085, 0.8186619877815247, 0.8151159286499023, 0.8115390539169312, 0.8079315423965454, 0.8042934536933899, 0.8006249666213989, 0.7969262599945068, 0.7931973934173584, 0.7894385457038879, 0.785649836063385, 0.7818315029144287, 0.777983546257019, 0.7741062045097351, 0.7701996564865112, 0.7662639617919922, 0.7622992992401123, 0.7583057880401611, 0.7542836666107178, 0.7502330541610718, 0.7461540102958679, 0.7420468330383301, 0.737911581993103, 0.7337484359741211, 0.7295575737953186, 0.7253391146659851, 0.7210932374000549, 0.7168201208114624, 0.7125198841094971, 0.708192765712738, 0.7038388252258301, 0.6994583010673523, 0.695051372051239, 0.6906181573867798, 0.6861588358879089, 0.6816735863685608, 0.6771625280380249, 0.6726258993148804, 0.6680638790130615, 0.6634765863418579, 0.6588642001152039, 0.6542268991470337, 0.6495649218559265, 0.6448783874511719, 0.6401674151420593, 0.6354323029518127, 0.6306731700897217, 0.6258901953697205, 0.6210835576057434, 0.6162534356117249, 0.6114000082015991, 0.6065235137939453, 0.601624071598053, 0.5967018604278564, 0.5917571783065796, 0.5867900252342224, 0.5818007588386536, 0.5767894983291626, 0.5717564225196838, 0.5667017698287964, 0.5616256594657898, 0.5565283298492432, 0.5514099597930908, 0.5462707877159119, 0.5411109328269958, 0.5359306335449219, 0.5307300686836243, 0.5255094170570374, 0.5202689170837402, 0.515008807182312, 0.5097292065620422, 0.5044302940368652, 0.4991123676300049, 0.49377554655075073, 0.4884200692176819, 0.48304614424705505, 0.47765395045280457, 0.47224369645118713, 0.46681562066078186, 0.4613698720932007, 0.4559066891670227, 0.45042628049850464, 0.4449288547039032, 0.4394145905971527, 0.4338837265968323, 0.4283364713191986, 0.4227730333805084, 0.41719359159469604, 0.41159841418266296, 0.4059876501560211, 0.4003615379333496, 0.39472031593322754, 0.38906416296958923, 0.3833933174610138, 0.37770795822143555, 0.372008353471756, 0.36629465222358704, 0.3605671226978302, 0.3548259735107422, 0.3490714132785797, 0.3433036506175995, 0.3375228941440582, 0.3317294120788574, 0.3259233832359314, 0.32010501623153687, 0.31427454948425293, 0.3084322214126587, 0.30257824063301086, 0.29671281576156616, 0.2908361852169037, 0.28494855761528015, 0.27905014157295227, 0.27314120531082153, 0.26722192764282227, 0.26129254698753357, 0.25535330176353455, 0.2494044005870819, 0.24344606697559357, 0.23747853934764862, 0.23150202631950378, 0.22551676630973816, 0.21952299773693085, 0.21352091431617737, 0.20751076936721802, 0.2014927715063095, 0.19546717405319214, 0.18943417072296143, 0.18339401483535767, 0.17734692990779877, 0.17129313945770264, 0.16523288190364838, 0.1591663658618927, 0.1530938446521759, 0.1470155268907547, 0.14093166589736938, 0.13484247028827667, 0.12874817848205566, 0.12264902144670486, 0.11654522269964218, 0.11043702811002731, 0.10432465374469757, 0.09820833802223206, 0.09208830446004868, 0.08596479892730713, 0.07983803749084473, 0.07370826601982117, 0.06757570058107376, 0.06144058704376221, 0.05530314892530441, 0.04916362091898918, 0.04302223399281502, 0.036879219114780426, 0.03073481284081936, 0.02458924427628517, 0.018442746251821518, 0.012295551598072052, 0.006147892214357853, 1.2246468525851679e-16 ] ================================================ FILE: __tests__/exports-node.ts ================================================ /** * This is required to trick typescript into thinking this file is a module * rather than a script. If this file is a script, it won't get its own scope * and EXPECTED_EXPORTS will be in the global scope, where it conflicts with * a variable of the same name in `exports-node.ts`. */ export {}; const EXPECTED_EXPORTS = [ "audioContext", "spn", "bufferSize", "sampleRate", "melBands", "chromaBands", "callback", "windowingFunction", "featureExtractors", "EXTRACTION_STARTED", "numberOfMFCCCoefficients", "numberOfBarkBands", "_featuresToExtract", "windowing", "_errors", "createMeydaAnalyzer", "listAvailableFeatureExtractors", "extract", ]; describe("package exports", () => { test("meyda node exports at least currently expected fields", () => { var meyda = require("../dist/node/main"); expect(Object.keys(meyda)).toEqual(EXPECTED_EXPORTS); }); }); ================================================ FILE: __tests__/exports-web.ts ================================================ /** * @jest-environment jsdom */ /** * This is required to trick typescript into thinking this file is a module * rather than a script. If this file is a script, it won't get its own scope * and EXPECTED_EXPORTS will be in the global scope, where it conflicts with * a variable of the same name in `exports-node.ts`. */ export {}; const EXPECTED_EXPORTS = [ "audioContext", "spn", "bufferSize", "sampleRate", "melBands", "chromaBands", "callback", "windowingFunction", "featureExtractors", "EXTRACTION_STARTED", "numberOfMFCCCoefficients", "numberOfBarkBands", "_featuresToExtract", "windowing", "_errors", "createMeydaAnalyzer", "listAvailableFeatureExtractors", "extract", ]; describe("package exports", () => { test("meyda web exports at least currently expected fields", () => { expect(window["Meyda"]).not.toBeDefined(); var meyda = require("../dist/web/meyda"); expect(Object.keys(meyda)).toEqual(EXPECTED_EXPORTS); expect(Object.keys(window["Meyda"])).toEqual(EXPECTED_EXPORTS); // @ts-ignore delete window["Meyda"]; }); test("meyda web min exports at least currently expected fields", () => { expect(global["Meyda"]).not.toBeDefined(); var meyda = require("../dist/web/meyda.min"); expect(Object.keys(meyda)).toEqual(EXPECTED_EXPORTS); expect(Object.keys(global["Meyda"])).toEqual(EXPECTED_EXPORTS); // @ts-ignore delete global["Meyda"]; }); }); describe("package exports", () => { test("meyda node exports at least currently expected fields", () => { var meyda = require("../dist/node/main"); expect(Object.keys(meyda)).toEqual(EXPECTED_EXPORTS); expect(Object.keys(global["Meyda"])).toEqual(EXPECTED_EXPORTS); }); }); ================================================ FILE: __tests__/extractors/chroma.ts ================================================ import TestData from "../TestData"; var utilities = require("../../dist/node/utilities"); // Setup var chroma = require("../../dist/node/extractors/chroma"); describe("chroma", () => { test("should return correct chroma value given a valid signal", (done) => { var chromagram = chroma({ sampleRate: 44100, bufferSize: 512, ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, chromaFilterBank: utilities.createChromaFilterBank(12, 44100, 512), }); for (var i in TestData.EXPECTED_CHROMAGRAM_OUTPUT) { expect( Math.abs(chromagram[i] - TestData.EXPECTED_CHROMAGRAM_OUTPUT[i]) ).toBeLessThanOrEqual(1e-5); } done(); }); test("should throw an error when passed an empty object", (done) => { try { var chromagram = chroma({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var chromagram = chroma(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var chromagram = chroma({ ampSpectrum: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/energy.ts ================================================ import TestData from "../TestData"; // Setup var energy = require("../../dist/node/extractors/energy"); describe("energy", () => { test("should return the correct value given a valid signal", (done) => { var en = energy({ signal: TestData.VALID_SIGNAL, }); expect(en).toEqual(3.6735467237693653); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = energy({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = energy(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = energy({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/loudness.ts ================================================ import TestData from "../TestData"; // Setup var loudness = require("../../dist/node/extractors/loudness"); describe("loudness", () => { test("should return correct value given a valid signal", (done) => { var en = loudness({ ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, barkScale: TestData.VALID_BARK_SCALE, }); expect(en).toEqual({ specific: new Float32Array([ 0.8241609334945679, 0.971539318561554, 0.7246851921081543, 0.868057370185852, 0.9084116816520691, 0.5983786582946777, 0.8250990509986877, 0.8279480338096619, 0.6802764534950256, 0.6513881683349609, 0.6347343325614929, 0.6553743481636047, 0.6563374996185303, 0.7111011147499084, 0.694219172000885, 0.7696076035499573, 0.677422285079956, 0.6804705262184143, 0.668949544429779, 0.6583544611930847, 0.8762503862380981, 0.7247303128242493, 0.7742922306060791, 0.8974387645721436, ]), total: 17.959227442741394, }); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = loudness({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = loudness(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = loudness({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/melBands.ts ================================================ import TestData from "../TestData"; var utilities = require("../../dist/node/utilities"); // Setup var melBands = require("../../dist/node/extractors/melBands"); describe("melBands", () => { test("should return correct melBands value given a valid signal", (done) => { var en = melBands({ sampleRate: 44100, bufferSize: 512, ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, melFilterBank: utilities.createMelFilterBank(26, 44100, 512), }); const expectedValues = [ 0.05362230911850929, 0.5754691362380981, 0.18804392218589783, 0.25777846574783325, 0.14160922169685364, 0.09012959152460098, 0.08216794580221176, 0.020733006298542023, 0.01394730806350708, 0.008802562952041626, 0.01255915779620409, 0.011275732889771461, 0.01811823807656765, 0.00460180826485157, 0.0031142467632889748, 0.00262887473218143, 0.0025565065443515778, 0.0038858000189065933, 0.03446952626109123, 0.004388371482491493, 0.00174950051587075, 0.0015815229853615165, 0.0013017841847613454, 0.0012407194590196013, 0.0012172914575785398, 0.001246776431798935, ]; expect(expectedValues).toEqual(en); expect(expectedValues.length).toEqual(en.length); done(); }); test("should return only 3 correct melBands values given a valid signal", (done) => { var en = melBands({ sampleRate: 44100, bufferSize: 512, ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, melFilterBank: utilities.createMelFilterBank(3, 44100, 512), }); expect(3).toEqual(en.length); done(); }); test("should return only 40 correct melBands values given a valid signal", (done) => { var en = melBands({ sampleRate: 44100, bufferSize: 512, ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, melFilterBank: utilities.createMelFilterBank(40, 44100, 512), }); expect(40).toEqual(en.length); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = melBands({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = melBands(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = melBands({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/mfcc.ts ================================================ import TestData from "../TestData"; var utilities = require("../../dist/node/utilities"); // Setup var mfcc = require("../../dist/node/extractors/mfcc"); describe("mfcc", () => { test("should return correct mfcc value given a valid signal", (done) => { var en = mfcc({ sampleRate: 44100, bufferSize: 512, ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, melFilterBank: utilities.createMelFilterBank(26, 44100, 512), }); const expectedValues = [ 3.0764786549843848, 2.5565860160012903, 1.864506100880325, 1.2335562677762721, 0.4988162523764804, 0.09087259136810752, -0.20585442699270234, -0.44269584674462054, -0.3253486567336908, -0.37584086978198183, -0.5572731218776171, -0.5245475651926765, -0.6215721667512493, ]; expect(expectedValues.length).toEqual(en.length); for (var index in en) { expect(Math.abs(en[index] - expectedValues[index])).toBeLessThanOrEqual( 1e-15 ); } done(); }); test("should return only 3 correct mfcc values given a valid signal", (done) => { var en = mfcc({ sampleRate: 44100, bufferSize: 512, ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, melFilterBank: utilities.createMelFilterBank(26, 44100, 512), numberOfMFCCCoefficients: 3, }); const expectedValues = [ 3.0764786549843848, 2.5565860160012903, 1.864506100880325, ]; expect(expectedValues.length).toEqual(en.length); for (var index in en) { expect(Math.abs(en[index] - expectedValues[index])).toBeLessThanOrEqual( 1e-15 ); } done(); }); test("should return only 40 correct mfcc values given a valid signal", (done) => { var en = mfcc({ sampleRate: 44100, bufferSize: 512, ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, melFilterBank: utilities.createMelFilterBank(40, 44100, 512), numberOfMFCCCoefficients: 40, }); const expectedValues = [ 3.162861616932787, 2.631774226264287, 1.9119808162845584, 1.2514199153407288, 0.486397957822833, 0.05257906181539599, -0.2520045416286077, -0.49585735294546857, -0.38466316958263563, -0.44818175405724836, -0.6672513607241057, -0.6686735919108686, -0.789241040586372, -0.855968554812388, -0.7559012649440329, -0.8343554237381223, -0.799337605151172, -0.7238357489234062, -0.8688463927736684, -0.8087429188034788, -0.6673245235771227, -0.6080509624742819, -0.3249701900706408, -0.08770548307506015, 0.06286020820571536, 0.29333780777697666, 0.2784715992409729, 0.23014381333962616, 0.3500576154282103, 0.33428294279172033, 0.40985070990105343, 0.6339035754249981, 0.7927495440032222, 1.1026760276121124, 1.364591123252153, 1.4136099189401947, 1.5027304491725944, 1.3659130982845602, 0.9699232061961626, 0.5762094772418701, ]; expect(expectedValues.length).toEqual(en.length); for (var index in en) { expect(Math.abs(en[index] - expectedValues[index])).toBeLessThanOrEqual( 1e-15 ); } done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = mfcc({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = mfcc(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = mfcc({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/perceptualSharpness.ts ================================================ import TestData from "../TestData"; // Setup var percSharp = require("../../dist/node/extractors/perceptualSharpness"); describe("percSharp", () => { test("should return percSharp value given a valid signal", (done) => { var en = percSharp({ signal: TestData.VALID_SIGNAL, ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, barkScale: TestData.VALID_BARK_SCALE, }); expect(en).toEqual(0.6469286541680944); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = percSharp({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = percSharp(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = percSharp({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/perceptualSpread.ts ================================================ import TestData from "../TestData"; // Setup var perceptualSpread = require("../../dist/node/extractors/perceptualSpread"); describe("perceptualSpread", () => { test("should return correct Spread value given valid signal", (done) => { var en = perceptualSpread({ signal: TestData.VALID_SIGNAL, ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, barkScale: TestData.VALID_BARK_SCALE, }); expect(en).toEqual(0.8947325916336791); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = perceptualSpread({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = perceptualSpread(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = perceptualSpread({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/powerSpectrum.ts ================================================ import TestData from "../TestData"; // Setup var powerSpectrum = require("../../dist/node/extractors/powerSpectrum"); describe("powerSpectrum", () => { test("should return correct Power Spectrum value", (done) => { var en = powerSpectrum({ ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, }); expect(en).toEqual(TestData.EXPECTED_POWER_SPECTRUM_OUTPUT); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = powerSpectrum({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = powerSpectrum(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = powerSpectrum({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/rms.ts ================================================ import TestData from "../TestData"; // Setup var rms = require("../../dist/node/extractors/rms"); describe("rms", () => { test("should return correct rms value given a valid signal", (done) => { var en = rms({ signal: TestData.VALID_SIGNAL, }); expect(en).toEqual(0.08470475751020153); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = rms({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = rms(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = rms({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/spectralCentroid.ts ================================================ import TestData from "../TestData"; // Setup var spectralCentroid = require("../../dist/node/extractors/spectralCentroid"); describe("spectralCentroid", () => { test("should return correct Spectral Centroid value", (done) => { var en = spectralCentroid({ ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, }); expect(en).toEqual(45.12823119078897); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = spectralCentroid({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = spectralCentroid(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = spectralCentroid({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/spectralCrest.ts ================================================ import TestData from "../TestData"; // Setup var spectralCrest = require("../../dist/node/extractors/spectralCrest"); describe("spectralCrest", () => { test("should return correct spectrla crest value", (done) => { var en = spectralCrest({ ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, }); expect(en).toEqual(10.35858484810692); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = spectralCrest({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = spectralCrest(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = spectralCrest({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/spectralFlatness.ts ================================================ import TestData from "../TestData"; // Setup var spectralFlatness = require("../../dist/node/extractors/spectralFlatness"); describe("spectralFlatness", () => { test("should return correct Spectral Flatness value", (done) => { var en = spectralFlatness({ ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, }); // Node 7 adds precision to Math.exp, we use Chai's approximate assertion // to account for the extra precision. expect(Math.abs(en - 0.4395908170404335)).toBeLessThanOrEqual(1e-16); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = spectralFlatness({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = spectralFlatness(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = spectralFlatness({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/spectralKurtosis.ts ================================================ import TestData from "../TestData"; // Setup var spectralKurtosis = require("../../dist/node/extractors/spectralKurtosis"); describe("spectralKurtosis", () => { test("should return correct Spectral Kurtosis value", (done) => { var en = spectralKurtosis({ ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, }); expect(Math.abs(en - 0.1511072674115075)).toBeLessThanOrEqual(1e-15); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = spectralKurtosis({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = spectralKurtosis(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = spectralKurtosis({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/spectralRolloff.ts ================================================ import TestData from "../TestData"; // Setup var spectralRolloff = require("../../dist/node/extractors/spectralRolloff"); describe("spectralRolloff", () => { test("should return correct Spectral Rolloff value", (done) => { var en = spectralRolloff({ ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, sampleRate: 44100, }); expect(en).toEqual(21012.35294117647); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = spectralRolloff({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = spectralRolloff(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = spectralRolloff({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/spectralSkewness.ts ================================================ import TestData from "../TestData"; // Setup var spectralSkewness = require("../../dist/node/extractors/spectralSkewness"); describe("spectralSkewness", () => { test("should return correct Spectral Skewness value", (done) => { var en = spectralSkewness({ ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, }); expect(en).toEqual(1.6950674362270297); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = spectralSkewness({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = spectralSkewness(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = spectralSkewness({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/spectralSlope.ts ================================================ import TestData from "../TestData"; // Setup var spectralSlope = require("../../dist/node/extractors/spectralSlope"); describe("spectralSlope", () => { test("should return correct Spectral Slope value", (done) => { var en = spectralSlope({ ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, sampleRate: 44100, bufferSize: 512, }); expect(en < 0.0000003).toEqual(true); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = spectralSlope({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = spectralSlope(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = spectralSlope({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/spectralSpread.ts ================================================ import TestData from "../TestData"; // Setup var spectralSpread = require("../../dist/node/extractors/spectralSpread"); describe("spectralSpread", () => { test("should return correct Spectral Spread value", (done) => { var en = spectralSpread({ ampSpectrum: TestData.VALID_AMPLITUDE_SPECTRUM, }); expect(en).toEqual(61.47230858577843); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = spectralSpread({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = spectralSpread(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = spectralSpread({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/extractors/zcr.ts ================================================ import TestData from "../TestData"; // Setup var zcr = require("../../dist/node/extractors/zcr"); describe("zcr", () => { test("should return correct zcr value", (done) => { var en = zcr({ signal: TestData.VALID_SIGNAL, }); expect(en).toEqual(35); done(); }); test("should throw an error when passed an empty object", (done) => { try { var en = zcr({}); } catch (e) { done(); } }); test("should throw an error when not passed anything", (done) => { try { var en = zcr(); } catch (e) { done(); } }); test("should throw an error when passed something invalid", (done) => { try { var en = zcr({ signal: "not a signal" }); } catch (e) { done(); } }); }); ================================================ FILE: __tests__/featureExtractors.ts ================================================ var fs = require("fs"); // Setup var featureExtractors = require("../dist/node/featureExtractors"); describe("featureExtractors", () => { test("should provide all of the feature extractors", () => { var featureExtractorsProvided = fs.readdirSync("./dist/node/extractors", { withFileTypes: true, }); featureExtractorsProvided = featureExtractorsProvided .filter((value) => value.isFile()) .map(function ({ name }) { return name.substr(0, name.lastIndexOf(".")) || name; }); featureExtractorsProvided.push("buffer"); featureExtractorsProvided.push("complexSpectrum"); featureExtractorsProvided.push("amplitudeSpectrum"); featureExtractorsProvided.splice( featureExtractorsProvided.indexOf("extractorUtilities"), 1 ); expect(new Set(Object.keys(featureExtractors))).toEqual( new Set(featureExtractorsProvided) ); }); }); ================================================ FILE: __tests__/main.ts ================================================ var meyda = require("../dist/node/main"); // trick ts into treating this file as a module export {}; describe("main", () => { test("should call an extractor when asked to", (done) => { done(); }); test("list feature extractors", () => { const availableFeatureExtractors = meyda.listAvailableFeatureExtractors(); expect(Array.isArray(availableFeatureExtractors)); availableFeatureExtractors.forEach((extractor) => { expect(typeof extractor).toBe("string"); }); }); }); ================================================ FILE: __tests__/utilities.ts ================================================ var util = require("../dist/node/utilities"); describe("isPowerOfTwo", () => { test("should validate all powers of two", (done) => { for (var i = 0; i < 1000; i++) { const result = util.isPowerOfTwo(Math.pow(2, i)); if (result !== true) { done(new Error("isPowerOfTwo failed for " + i)); } } done(); }); test("should fail for non-powers of two", (done) => { expect(util.isPowerOfTwo(3)).toBe(false); expect(util.isPowerOfTwo(348)).toBe(false); expect(util.isPowerOfTwo(29384)).toBe(false); expect(util.isPowerOfTwo(3489410)).toBe(false); done(); }); }); describe("error", () => { test("throws an error with the correct message", (done) => { var message = "Test Error Message"; expect(function () { util.error(message); }).toThrow(); done(); }); }); describe("pointwiseBufferMult", () => { test("multiplies two arrays correctly", (done) => { expect(util.pointwiseBufferMult([4, 5, 6], [0.5, 2, 2])).toEqual([ 2, 10, 12, ]); done(); }); test("handles differently sized arrays correctly", (done) => { expect(util.pointwiseBufferMult([4, 0.25, 0.7], [0.25, 2])).toEqual([ 1, 0.5, ]); done(); }); }); describe("applyWindow", () => { test("applies a windowing function to a buffer", (done) => { expect(util.applyWindow([1, 4, 6], "hanning")).toEqual([0, 4, 0]); done(); }); }); describe("frame", () => { test("returns the expected number of frames for hop size < buffer size", () => { const frames = util.frame(new Array(2048).fill(0), 1024, 512); expect(frames.length).toEqual(3); }); test("returns the expected number of frames for hop size === buffer size", () => { const frames = util.frame(new Array(2048).fill(0), 1024, 1024); expect(frames.length).toEqual(2); }); test("returns the expected number of frames where buffer size isn't a hop size multiple", () => { const frames = util.frame(new Array(2048).fill(0), 1024, 500); expect(frames.length).toEqual(3); }); }); ================================================ FILE: __tests__/windowing.ts ================================================ var windowing = require("../dist/node/windowing"); var blackman128 = require("./data/blackman128.json"); var blackman256 = require("./data/blackman256.json"); var blackman512 = require("./data/blackman512.json"); var blackman1024 = require("./data/blackman1024.json"); var blackman2048 = require("./data/blackman2048.json"); var hanning128 = require("./data/hanning128.json"); var hanning256 = require("./data/hanning256.json"); var hanning512 = require("./data/hanning512.json"); var hanning1024 = require("./data/hanning1024.json"); var hanning2048 = require("./data/hanning2048.json"); var hamming128 = require("./data/hamming128.json"); var hamming256 = require("./data/hamming256.json"); var hamming512 = require("./data/hamming512.json"); var hamming1024 = require("./data/hamming1024.json"); var hamming2048 = require("./data/hamming2048.json"); var sine128 = require("./data/sine128.json"); var sine256 = require("./data/sine256.json"); var sine512 = require("./data/sine512.json"); var sine1024 = require("./data/sine1024.json"); var sine2048 = require("./data/sine2048.json"); describe("windowing", () => { test("should generate a correct 128 bin blackman window", (done) => { expect(windowing.blackman(128)).toEqual(Float32Array.from(blackman128)); done(); }); test("should generate a correct 256 bin blackman window", (done) => { expect(windowing.blackman(256)).toEqual(Float32Array.from(blackman256)); done(); }); test("should generate a correct 512 bin blackman window", (done) => { expect(windowing.blackman(512)).toEqual(Float32Array.from(blackman512)); done(); }); test("should generate a correct 1024 bin blackman window", (done) => { expect(windowing.blackman(1024)).toEqual(Float32Array.from(blackman1024)); done(); }); test("should generate a correct 2048 bin blackman window", (done) => { expect(windowing.blackman(2048)).toEqual(Float32Array.from(blackman2048)); done(); }); test("should generate a correct 128 bin hanning window", (done) => { expect(windowing.hanning(128)).toEqual(Float32Array.from(hanning128)); done(); }); test("should generate a correct 256 bin hanning window", (done) => { expect(windowing.hanning(256)).toEqual(Float32Array.from(hanning256)); done(); }); test("should generate a correct 512 bin hanning window", (done) => { expect(windowing.hanning(512)).toEqual(Float32Array.from(hanning512)); done(); }); test("should generate a correct 1024 bin hanning window", (done) => { expect(windowing.hanning(1024)).toEqual(Float32Array.from(hanning1024)); done(); }); test("should generate a correct 2048 bin hanning window", (done) => { expect(windowing.hanning(2048)).toEqual(Float32Array.from(hanning2048)); done(); }); test("should generate a correct 128 bin hamming window", (done) => { expect(windowing.hamming(128)).toEqual(Float32Array.from(hamming128)); done(); }); test("should generate a correct 256 bin hamming window", (done) => { expect(windowing.hamming(256)).toEqual(Float32Array.from(hamming256)); done(); }); test("should generate a correct 512 bin hamming window", (done) => { expect(windowing.hamming(512)).toEqual(Float32Array.from(hamming512)); done(); }); test("should generate a correct 1024 bin hamming window", (done) => { expect(windowing.hamming(1024)).toEqual(Float32Array.from(hamming1024)); done(); }); test("should generate a correct 2048 bin hamming window", (done) => { expect(windowing.hamming(2048)).toEqual(Float32Array.from(hamming2048)); done(); }); test("should generate a correct 128 bin sine window", (done) => { expect(windowing.sine(128)).toEqual(Float32Array.from(sine128)); done(); }); test("should generate a correct 256 bin sine window", (done) => { expect(windowing.sine(256)).toEqual(Float32Array.from(sine256)); done(); }); test("should generate a correct 512 bin sine window", (done) => { expect(windowing.sine(512)).toEqual(Float32Array.from(sine512)); done(); }); test("should generate a correct 1024 bin sine window", (done) => { expect(windowing.sine(1024)).toEqual(Float32Array.from(sine1024)); done(); }); test("should generate a correct 2048 bin sine window", (done) => { expect(windowing.sine(2048)).toEqual(Float32Array.from(sine2048)); done(); }); }); ================================================ FILE: bin/cli.js ================================================ #! /usr/bin/env node (function () { "use strict"; var opt = require("node-getopt") .create([ [ "", "o[=OUTPUT_FILE]", "Path to output file (optional, if not specified prints to console", ], [ "", "bs[=BUFFER_SIZE]", "Buffer size in samples (optional, default is 512)", ], [ "", "mfcc[=MFCC_COEFFICIENTS]", "Number of MFCC co-efficients that the MFCC feature extractor should return (optional, default is 13)", ], [ "", "hs[=HOP_SIZE]", "Hop size in samples (optional, defaults to matching buffer size)", ], [ "", "w[=WINDOWING_FUNCTION]", "Windowing function (optional, default is hanning)", ], [ "", "format[=FORMAT_TYPE]", "Type of output file (optional, default is csv)", ], [ "p", "", "Disables some of the logging and outputs data to stdout, useful for piping", ], ["h", "help", "Display help"], ]) .bindHelp() .parseSystem(); if (!opt.argv.length) throw new Error("Input file was not specified."); else if (opt.argv.length < 2) throw new Error("No features specified."); else if (opt.options.p && opt.options.o) throw new Error("Please choose either -p or --o."); else if ( opt.options.format && opt.options.format != "json" && opt.options.format != "csv" ) throw new Error("Invalid output format. Please choose either json or csv."); var Meyda = require("../dist/node/main.js"); var WavLoader = require("./wav-loader.js"); var fs = require("fs"); var FRAME_SIZE = parseInt(opt.options.bs) || 512; var HOP_SIZE = parseInt(opt.options.hs) || FRAME_SIZE; var MFCC_COEFFICIENTS = parseInt(opt.options.mfcc) || 13; Meyda.bufferSize = FRAME_SIZE; Meyda.hopSize = HOP_SIZE; Meyda.windowingFunction = opt.options.w || "hanning"; Meyda.numberOfMFCCCoefficients = MFCC_COEFFICIENTS; var outputFormat = null; if (opt.options.o) { outputFormat = opt.options.format || "csv"; } var features = {}; var featuresToExtract = opt.argv.slice(1); for (var i = 0; i < featuresToExtract.length; i++) { features[featuresToExtract[i]] = []; } // utility to convert typed arrays to normal arrays function typedToArray(t) { return Array.prototype.slice.call(t); } // utility to convert arrays to typed F32 arrays function arrayToTyped(t) { return Float32Array.from(t); } function output(val) { if (!opt.options.o || opt.options.p) { process.stdout.write(val); } else { wstream.write(val); } } //helper method to extract features for this chunk function extractFeatures(chunk) { //make it a F32A for efficiency var frame = arrayToTyped(chunk); //run the extraction of selected features var fset = Meyda.extract(featuresToExtract, frame); for (let j = 0; j < featuresToExtract.length; j++) { const feature = fset[featuresToExtract[j]]; features[featuresToExtract[j]].push(feature); } } if (opt.options.o && !opt.options.p) { var wstream = fs.createWriteStream(opt.options.o); } //this is a buffer var buffer = []; var frameCount = 0; if (!opt.options.p) { //cosmetics console.log("\n=========\nMeyda CLI\n=========\n\n"); console.log("Buffer size: " + FRAME_SIZE); console.log("Hop size: " + HOP_SIZE); console.log("Windowing function: " + Meyda.windowingFunction); console.log("Will extract:"); //log features to extract featuresToExtract.forEach(function (f, i, a) { process.stdout.write(f + " "); }); process.stdout.write("\n\nStarting extraction...\n|"); } var wl = new WavLoader( function (config) { Meyda.sampleRate = config.sampleRate; if (!opt.options.p) { console.log("Sample rate recognized as: " + Meyda.sampleRate); } }, function (chunk) { //convert to normal array so we can concatenate var _chunk = typedToArray(chunk); buffer = buffer.concat(_chunk); //if we're long enough, splice the frame, and extract features on it while (buffer.length >= FRAME_SIZE) { extractFeatures(buffer.slice(0, FRAME_SIZE)); buffer.splice(0, HOP_SIZE); if (!opt.options.p) process.stdout.write("-"); frameCount++; } }, function (data) { //check if there's still something left in our buffer if (buffer.length) { //zero pad the buffer at the end so we get a full frame (needed for successful spectral analysis) for (let i = buffer.length; i < 2 * FRAME_SIZE - HOP_SIZE; i++) { buffer.push(0); } //extract features for zero-padded frame while (buffer.length >= FRAME_SIZE) { extractFeatures(buffer.slice(0, FRAME_SIZE)); buffer.splice(0, HOP_SIZE); if (!opt.options.p) process.stdout.write("-"); frameCount++; } } // only print out information if piping flag is disabled. if (!opt.options.p) { process.stdout.write("-|\nExtraction finished.\n\n"); console.log(frameCount + " frames analysed.\n"); } // if output to file is enabled. if (opt.options.o) { if (outputFormat == "json") { process.stdout.write("Writing to " + opt.options.o + "...\n"); output(JSON.stringify(features, null, 4)); } else if (outputFormat == "csv") { process.stdout.write("Writing to " + opt.options.o + "...\n"); for (let i = 0; i < featuresToExtract.length; i++) { output(featuresToExtract[i].toString()); output(i == featuresToExtract.length - 1 ? "" : ","); } output("\n"); for (let i = 0; i < frameCount; i++) { for (let j = 0; j < featuresToExtract.length; j++) { const feature = features[featuresToExtract[j]]; if (typeof feature[i] === "object") { for (let f = 0; f < Object.keys(feature[i]).length; f++) output(feature[i][f] + ","); output(j == featuresToExtract.length - 1 ? "" : ","); } else { output(feature[i].toString()); output(j == featuresToExtract.length - 1 ? "" : ","); } } output("\n"); } } console.log("Done."); wstream.end(); console.log(""); } else { // if there is no output flag, print to console. for (let j = 0; j < featuresToExtract.length; j++) { output( "\n*********" + featuresToExtract[j].toString() + "*********\n\n" ); for (let i = 0; i < frameCount; i++) { var feature = features[featuresToExtract[j]]; if (typeof feature[i] === "object") { var keys = Object.keys(feature[i]); for (let f = 0; f < keys.length; f++) { output(feature[i][keys[f]] + ""); output(f == keys.length - 1 ? "\n" : ","); } } else { output(feature[i].toString()); output("\n"); } } output("\n"); } } //get averages for (let j = 0; j < featuresToExtract.length; j++) { //check if this feature returns arrays if (typeof features[featuresToExtract[j]][0] != "object") //if not, calculate average console.log( "Average " + featuresToExtract[j] + ": " + features[featuresToExtract[j]].reduce(function ( previousValue, currentValue ) { return previousValue + currentValue; }) / features[featuresToExtract[j]].length ); } } ); wl.open(opt.argv[0]); })(); ================================================ FILE: bin/wav-loader.js ================================================ var WavManager = function (open_callback, data_callback, end_callback) { var source = new Buffer(1); var fs = require("fs"); var wav = require("wav"); var _dcb = data_callback; var _ecb = end_callback; var _bitDepth = 16; var _numBytesPerSample = 2; var _endian = "LE"; var _signed = false; var _format = "unknown"; var _channels = 1; var read_fun = "readUIntBE"; function int_res(signed, depth) { //if the fmt is signed int, the max absolute value is half the actual number of possible values return signed ? Math.pow(2, depth) / 2 : Math.pow(2, depth); } this.format = function () { return _format; }; this.open = function (path) { var file = fs.createReadStream(path); var source = new Buffer(1); //empty the current source if needed var reader = new wav.Reader(); reader.on("format", function (format) { //read wav headers open_callback({ sampleRate: format.sampleRate }); _bitDepth = format.bitDepth; _numBytesPerSample = _bitDepth / 8; _endian = format.endianness; _signed = format.signed; _channels = format.channels; _format = format; read_fun = (_signed ? "readInt" : "readUInt") + _endian; }); reader.on("data", function (_d) { source = Buffer.concat([source, _d], source.length + _d.length); var output = new Float32Array(_d.length / _numBytesPerSample); var source_pos = 0; var out_pos = 0; for ( ; source_pos < _d.length; source_pos += _numBytesPerSample, out_pos++ ) { output[out_pos] = _d[read_fun](source_pos, _numBytesPerSample) / int_res(_signed, _bitDepth); } if (_dcb) _dcb(output); }); reader.on("end", function () { var output = new Float32Array(source.length / _numBytesPerSample); var source_pos = 0; var out_pos = 0; //here we discard the last byte because we don't really need this anyway and it's quicker for ( ; source_pos < source.length - _numBytesPerSample; source_pos += _numBytesPerSample, out_pos++ ) { output[out_pos] = source[read_fun](source_pos, _numBytesPerSample) / int_res(_signed, _bitDepth); } if (_ecb) _ecb(output); }); file.pipe(reader); }; }; module.exports = WavManager; ================================================ FILE: docs/404.html ================================================ --- layout: default ---

404

Page not found :(

The requested page could not be found.

================================================ FILE: docs/CNAME ================================================ meyda.js.org ================================================ FILE: docs/Gemfile ================================================ source "https://rubygems.org" # Hello! This is where you manage which Jekyll version is used to run. # When you want to use a different version, change it below, save the # file and run `bundle install`. Run Jekyll with `bundle exec`, like so: # # bundle exec jekyll serve # # This will help ensure the proper Jekyll version is running. # Happy Jekylling! gem "jekyll", "~> 4.3.2" # This is the default theme for new Jekyll sites. You may change this to anything you like. gem "minima", "~> 2.5.1" # If you want to use GitHub Pages, remove the "gem "jekyll"" above and # uncomment the line below. To upgrade, run `bundle update github-pages`. # gem "github-pages", group: :jekyll_plugins # If you have any plugins, put them here! group :jekyll_plugins do gem "jekyll-feed", "~> 0.17.0" end # Windows does not include zoneinfo files, so bundle the tzinfo-data gem gem "tzinfo-data", platforms: [:mingw, :mswin, :x64_mingw, :jruby] # Performance-booster for watching directories on Windows gem "wdm", "~> 0.1.0" if Gem.win_platform? gem "webrick" ================================================ FILE: docs/README.md ================================================ ## Meyda reference docs Automatically generated reference documentation for the Meyda library. ## Usage To build the reference docs from the annotations in the source code, run the following command in the root directoroy of the project. ``` $ npm run generatereferencedocs ``` To build the Javascript demo of Meyda that runs in the docs folder, run ``` $ cd docs $ npm run build ``` To serve the docs locally ``` $ cd docs $ bundle install $ bundle exec jekyll serve ``` Make sure you're in the docs directory, have ruby and bundle installed on your machine, use bundle to install the dependencies (jekyll), and then use bundle to run jekyll's server. ================================================ FILE: docs/_config.yml ================================================ # Welcome to Jekyll! # # This config file is meant for settings that affect your whole blog, values # which you are expected to set up once and rarely edit after that. If you find # yourself editing this file very often, consider using Jekyll's data files # feature for the data you need to update frequently. # # For technical reasons, this file is *NOT* reloaded automatically when you use # 'bundle exec jekyll serve'. If you change this file, please restart the server process. # Site settings # These are used to personalize your new site. If you look in the HTML files, # you will see them accessed via {{ site.title }}, {{ site.email }}, and so on. # You can create any custom variable you would like, and they will be accessible # in the templates via {{ site.myvariable }}. title: "Meyda: Javascript Audio Feature Extraction" description: >- # this means to ignore newlines until "baseurl:" Meyda is a Javascript audio feature extraction library. Meyda supports both offline feature extraction as well as real-time feature extraction using the Web Audio API. baseurl: "" # the subpath of your site, e.g. /blog url: "" # the base hostname & protocol for your site, e.g. http://example.com # Build settings markdown: kramdown theme: minima plugins: - jekyll-feed # Exclude from processing. # The following items will not be processed, by default. Create a custom list # to override the default setting. exclude: - Gemfile - Gemfile.lock - node_modules - README.md - src # - vendor/bundle/ # - vendor/cache/ # - vendor/gems/ # - vendor/ruby/ ================================================ FILE: docs/_includes/contributors.html ================================================
Hugh Rawlinson
@hughrawlinson
Nevo Segal
@nevosegal
Jakub Fiala
@fiala__
Sam Wray
@_2xAA
================================================ FILE: docs/_includes/footer.html ================================================
================================================ FILE: docs/_includes/head.html ================================================ Meyda {%- seo -%} {%- feed_meta -%} {%- if jekyll.environment == 'production' and site.google_analytics -%} {%- include google-analytics.html -%} {%- endif -%} ================================================ FILE: docs/_includes/header.html ================================================

Meyda

Audio feature extraction for JavaScript.


{%- include nav.html -%}
================================================ FILE: docs/_includes/nav.html ================================================ ================================================ FILE: docs/_includes/showcase.html ================================================

Allow microphone access or play this audio file to see a demo.

Root Mean Squared (RMS)
Spectral Centroid
Spectral Rolloff

================================================ FILE: docs/_layouts/default.html ================================================ {%- include head.html -%}
{%- include header.html -%} {{ content }} {%- include footer.html -%}
Fork me on GitHub ================================================ FILE: docs/_layouts/homepage.html ================================================ --- layout: default --- {%- include showcase.html -%}
{{ content }}
{%- include contributors.html -%} ================================================ FILE: docs/assets/main.css ================================================ body { padding: 5rem 0; } canvas { width: 100%; height: auto; } audio { width:100%; } .key-item { font-size: small; text-align: center; display: inline-block; margin: 0 15px; vertical-align: middle; } .key-color { border: 1px solid; display: inline-block; width: 10px; height: 10px; margin: 0 5px 0 0; vertical-align: middle; } .key-text { display: inline-block; vertical-align: middle; } .key-color.pink { background-color: #ff00ff; } .key-color.yellow { background-color: #ffff00; } .key-color.blue { background-color: #0000ff; } div#legend { text-align: center; vertical-align: middle; } #showcase #chroma::before { content: 'Chroma bands:'; margin-right: 10px; display: inline-block; text-align: center; } #showcase #chroma { margin-top: 20px; display: flex; justify-content: center; align-items: center; } #showcase .chroma-band { flex: 0 1 28px; height: 28px; display: inline-block; text-align: center; padding-top: 7px; font-size: 10px; color: #ffffff; } #showcase #mfcc::before { content: 'MFCC bands:'; margin-right: 10px; display: inline-block; text-align: center; } #showcase #mfcc { margin-top: 20px; display: flex; justify-content: center; align-items: center; } #showcase .mfcc-band { flex: 0 1 28px; height: 28px; display: inline-block; text-align: center; padding-top: 7px; font-size: 10px; color: #ffffff; } #title-link { color:inherit; } #title-link:hover { text-decoration: none; } img { max-width: 100%; } ================================================ FILE: docs/assets/main.js ================================================ !function(){"use strict";"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;var t,e={exports:{}};e.exports=function(){var t=Object.freeze({__proto__:null,blackman:function(t){let e=new Float32Array(t),n=2*Math.PI/(t-1),i=2*n;for(let r=0;r0;n--)e[t-n]=e[n-1];return e},sine:function(t){let e=Math.PI/(t-1),n=new Float32Array(t);for(let i=0;i1;)t/=2;return 1===t}function i(n,i){if("rect"!==i){if(""!==i&&i||(i="hanning"),e[i]||(e[i]={}),!e[i][n.length])try{e[i][n.length]=t[i](n.length)}catch(t){throw new Error("Invalid windowing function")}n=function(t,e){let n=[];for(let i=0;it*function(t,e){return Math.log2(16*t/e)}(e*r/n,a)));l[0]=l[1]-1.5*t;var c,h,u,d=l.slice(1).map(((t,e)=>Math.max(t-l[e])),1).concat([1]),p=Math.round(t/2),m=new Array(t).fill(0).map(((e,n)=>l.map((e=>(10*t+p+e-n)%t-p)))),f=m.map(((t,e)=>t.map(((t,n)=>Math.exp(-.5*Math.pow(2*m[e][n]/d[n],2))))));if(h=(c=f)[0].map((()=>0)),u=c.reduce(((t,e)=>(e.forEach(((e,n)=>{t[n]+=Math.pow(e,2)})),t)),h).map(Math.sqrt),f=c.map(((t,e)=>t.map(((t,e)=>t/(u[e]||1))))),r){var g=l.map((e=>Math.exp(-.5*Math.pow((e/t-i)/r,2))));f=f.map((t=>t.map(((t,e)=>t*g[e]))))}return s&&(f=[...f.slice(3),...f.slice(0,3)]),f.map((t=>t.slice(0,o)))}function c(t,e){for(var n=0,i=0,r=0;ra;)s[o++]=n,a=o*t.barkScale[r.length-1]/e;s[24]=r.length-1;for(let t=0;tr&&s>=0;)n-=t[s],--s;return(s+1)*e},spectralFlatness:function(){if("object"!=typeof arguments[0].ampSpectrum)throw new TypeError;for(var t=0,e=0,n=0;n=0&&arguments[0].signal[e]<0||arguments[0].signal[e-1]<0&&arguments[0].signal[e]>=0)&&t++;return t},loudness:h,perceptualSpread:function(){if("object"!=typeof arguments[0].signal)throw new TypeError;for(var t=h(arguments[0]),e=0,n=0;ne&&(e=t.specific[n]);return Math.pow((t.total-e)/t.total,2)},perceptualSharpness:function(){if("object"!=typeof arguments[0].signal)throw new TypeError;for(var t=h(arguments[0]),e=t.specific,n=0,i=0;it.ampSpectrum.reduce(((t,n,i)=>t+n*e[i]),0))),n=Math.max(...e);return n?e.map((t=>t/n)):e},spectralFlux:function(t){if("object"!=typeof t.signal||"object"!=typeof t.previousSignal)throw new TypeError;let e=0;for(let n=-t.bufferSize/2;n{if(null!==this._m.inputData&&(this._m.previousInputData=this._m.inputData),this._m.inputData=t.inputBuffer.getChannelData(this._m.channel),this._m.previousInputData)(e=new Float32Array(this._m.previousInputData.length+this._m.inputData.length-this._m.hopSize)).set(this._m.previousInputData.slice(this._m.hopSize)),e.set(this._m.inputData,this._m.previousInputData.length-this._m.hopSize);else var e=this._m.inputData;(function(t,e,n){if(t.lengtht.slice(r*n,r*n+e)))})(e,this._m.bufferSize,this._m.hopSize).forEach((t=>{this._m.frame=t;var e=this._m.extract(this._m._featuresToExtract,this._m.frame,this._m.previousFrame);"function"==typeof this._m.callback&&this._m.EXTRACTION_STARTED&&this._m.callback(e),this._m.previousFrame=this._m.frame}))}}start(t){this._m._featuresToExtract=t||this._m._featuresToExtract,this._m.EXTRACTION_STARTED=!0}stop(){this._m.EXTRACTION_STARTED=!1}setSource(t){this._m.source&&this._m.source.disconnect(this._m.spn),this._m.source=t,this._m.source.connect(this._m.spn)}setChannel(t){t<=this._m.inputs?this._m.channel=t:console.error(`Channel ${t} does not exist. Make sure you've provided a value for 'inputs' that is greater than ${t} when instantiating the MeydaAnalyzer`)}get(t){return this._m.inputData?this._m.extract(t||this._m._featuresToExtract,this._m.inputData,this._m.previousInputData):null}}var M={audioContext:null,spn:null,bufferSize:512,sampleRate:44100,melBands:26,chromaBands:12,callback:null,windowingFunction:"hanning",featureExtractors:m,EXTRACTION_STARTED:!1,numberOfMFCCCoefficients:13,_featuresToExtract:[],windowing:i,_errors:{notPow2:new Error("Meyda: Buffer size must be a power of 2, e.g. 64 or 512"),featureUndef:new Error("Meyda: No features defined."),invalidFeatureFmt:new Error("Meyda: Invalid feature format"),invalidInput:new Error("Meyda: Invalid input."),noAC:new Error("Meyda: No AudioContext specified."),noSource:new Error("Meyda: No source node specified.")},createMeydaAnalyzer:function(t){return new w(t,Object.assign({},M))},listAvailableFeatureExtractors:function(){return Object.keys(this.featureExtractors)},extract:function(t,e,i){if(!e)throw this._errors.invalidInput;if("object"!=typeof e)throw this._errors.invalidInput;if(!t)throw this._errors.featureUndef;if(!n(e.length))throw this._errors.notPow2;void 0!==this.barkScale&&this.barkScale.length==this.bufferSize||(this.barkScale=r(this.bufferSize,this.sampleRate,this.bufferSize)),void 0!==this.melFilterBank&&this.barkScale.length==this.bufferSize&&this.melFilterBank.length==this.melBands||(this.melFilterBank=o(Math.max(this.melBands,this.numberOfMFCCCoefficients),this.sampleRate,this.bufferSize)),void 0!==this.chromaFilterBank&&this.chromaFilterBank.length==this.chromaBands||(this.chromaFilterBank=l(this.chromaBands,this.sampleRate,this.bufferSize)),void 0===e.buffer?this.signal=s(e):this.signal=e;let a=b(e,this.windowingFunction,this.bufferSize);if(this.signal=a.windowedSignal,this.complexSpectrum=a.complexSpectrum,this.ampSpectrum=a.ampSpectrum,i){let t=b(i,this.windowingFunction,this.bufferSize);this.previousSignal=t.windowedSignal,this.previousComplexSpectrum=t.complexSpectrum,this.previousAmpSpectrum=t.ampSpectrum}const c=t=>this.featureExtractors[t]({ampSpectrum:this.ampSpectrum,chromaFilterBank:this.chromaFilterBank,complexSpectrum:this.complexSpectrum,signal:this.signal,bufferSize:this.bufferSize,sampleRate:this.sampleRate,barkScale:this.barkScale,melFilterBank:this.melFilterBank,previousSignal:this.previousSignal,previousAmpSpectrum:this.previousAmpSpectrum,previousComplexSpectrum:this.previousComplexSpectrum,numberOfMFCCCoefficients:this.numberOfMFCCCoefficients});if("object"==typeof t)return t.reduce(((t,e)=>Object.assign({},t,{[e]:c(e)})),{});if("string"==typeof t)return c(t);throw this._errors.invalidFeatureFmt}},b=function(t,e,n){var r={};void 0===t.buffer?r.signal=s(t):r.signal=t,r.windowedSignal=i(r.signal,e),r.complexSpectrum=_(r.windowedSignal),r.ampSpectrum=new Float32Array(n/2);for(var a=0;a>8&255]+N[t>>16&255]+N[t>>24&255]+"-"+N[255&e]+N[e>>8&255]+"-"+N[e>>16&15|64]+N[e>>24&255]+"-"+N[63&n|128]+N[n>>8&255]+"-"+N[n>>16&255]+N[n>>24&255]+N[255&i]+N[i>>8&255]+N[i>>16&255]+N[i>>24&255]).toUpperCase()}function B(t,e,n){return Math.max(e,Math.min(n,t))}function U(t,e,n){return(1-n)*t+n*e}function H(t){return 0==(t&t-1)&&0!==t}function G(t){return Math.pow(2,Math.floor(Math.log(t)/Math.LN2))}class k{constructor(t=0,e=0){this.x=t,this.y=e}get width(){return this.x}set width(t){this.x=t}get height(){return this.y}set height(t){this.y=t}set(t,e){return this.x=t,this.y=e,this}setScalar(t){return this.x=t,this.y=t,this}setX(t){return this.x=t,this}setY(t){return this.y=t,this}setComponent(t,e){switch(t){case 0:this.x=e;break;case 1:this.y=e;break;default:throw new Error("index is out of range: "+t)}return this}getComponent(t){switch(t){case 0:return this.x;case 1:return this.y;default:throw new Error("index is out of range: "+t)}}clone(){return new this.constructor(this.x,this.y)}copy(t){return this.x=t.x,this.y=t.y,this}add(t,e){return void 0!==e?(console.warn("THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(t,e)):(this.x+=t.x,this.y+=t.y,this)}addScalar(t){return this.x+=t,this.y+=t,this}addVectors(t,e){return this.x=t.x+e.x,this.y=t.y+e.y,this}addScaledVector(t,e){return this.x+=t.x*e,this.y+=t.y*e,this}sub(t,e){return void 0!==e?(console.warn("THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(t,e)):(this.x-=t.x,this.y-=t.y,this)}subScalar(t){return this.x-=t,this.y-=t,this}subVectors(t,e){return this.x=t.x-e.x,this.y=t.y-e.y,this}multiply(t){return this.x*=t.x,this.y*=t.y,this}multiplyScalar(t){return this.x*=t,this.y*=t,this}divide(t){return this.x/=t.x,this.y/=t.y,this}divideScalar(t){return this.multiplyScalar(1/t)}applyMatrix3(t){const e=this.x,n=this.y,i=t.elements;return this.x=i[0]*e+i[3]*n+i[6],this.y=i[1]*e+i[4]*n+i[7],this}min(t){return this.x=Math.min(this.x,t.x),this.y=Math.min(this.y,t.y),this}max(t){return this.x=Math.max(this.x,t.x),this.y=Math.max(this.y,t.y),this}clamp(t,e){return this.x=Math.max(t.x,Math.min(e.x,this.x)),this.y=Math.max(t.y,Math.min(e.y,this.y)),this}clampScalar(t,e){return this.x=Math.max(t,Math.min(e,this.x)),this.y=Math.max(t,Math.min(e,this.y)),this}clampLength(t,e){const n=this.length();return this.divideScalar(n||1).multiplyScalar(Math.max(t,Math.min(e,n)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this}negate(){return this.x=-this.x,this.y=-this.y,this}dot(t){return this.x*t.x+this.y*t.y}cross(t){return this.x*t.y-this.y*t.x}lengthSq(){return this.x*this.x+this.y*this.y}length(){return Math.sqrt(this.x*this.x+this.y*this.y)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)}normalize(){return this.divideScalar(this.length()||1)}angle(){return Math.atan2(-this.y,-this.x)+Math.PI}distanceTo(t){return Math.sqrt(this.distanceToSquared(t))}distanceToSquared(t){const e=this.x-t.x,n=this.y-t.y;return e*e+n*n}manhattanDistanceTo(t){return Math.abs(this.x-t.x)+Math.abs(this.y-t.y)}setLength(t){return this.normalize().multiplyScalar(t)}lerp(t,e){return this.x+=(t.x-this.x)*e,this.y+=(t.y-this.y)*e,this}lerpVectors(t,e,n){return this.x=t.x+(e.x-t.x)*n,this.y=t.y+(e.y-t.y)*n,this}equals(t){return t.x===this.x&&t.y===this.y}fromArray(t,e=0){return this.x=t[e],this.y=t[e+1],this}toArray(t=[],e=0){return t[e]=this.x,t[e+1]=this.y,t}fromBufferAttribute(t,e,n){return void 0!==n&&console.warn("THREE.Vector2: offset has been removed from .fromBufferAttribute()."),this.x=t.getX(e),this.y=t.getY(e),this}rotateAround(t,e){const n=Math.cos(e),i=Math.sin(e),r=this.x-t.x,s=this.y-t.y;return this.x=r*n-s*i+t.x,this.y=r*i+s*n+t.y,this}random(){return this.x=Math.random(),this.y=Math.random(),this}}k.prototype.isVector2=!0;class V{constructor(){this.elements=[1,0,0,0,1,0,0,0,1],arguments.length>0&&console.error("THREE.Matrix3: the constructor no longer reads arguments. use .set() instead.")}set(t,e,n,i,r,s,a,o,l){const c=this.elements;return c[0]=t,c[1]=i,c[2]=a,c[3]=e,c[4]=r,c[5]=o,c[6]=n,c[7]=s,c[8]=l,this}identity(){return this.set(1,0,0,0,1,0,0,0,1),this}copy(t){const e=this.elements,n=t.elements;return e[0]=n[0],e[1]=n[1],e[2]=n[2],e[3]=n[3],e[4]=n[4],e[5]=n[5],e[6]=n[6],e[7]=n[7],e[8]=n[8],this}extractBasis(t,e,n){return t.setFromMatrix3Column(this,0),e.setFromMatrix3Column(this,1),n.setFromMatrix3Column(this,2),this}setFromMatrix4(t){const e=t.elements;return this.set(e[0],e[4],e[8],e[1],e[5],e[9],e[2],e[6],e[10]),this}multiply(t){return this.multiplyMatrices(this,t)}premultiply(t){return this.multiplyMatrices(t,this)}multiplyMatrices(t,e){const n=t.elements,i=e.elements,r=this.elements,s=n[0],a=n[3],o=n[6],l=n[1],c=n[4],h=n[7],u=n[2],d=n[5],p=n[8],m=i[0],f=i[3],g=i[6],v=i[1],y=i[4],x=i[7],_=i[2],w=i[5],M=i[8];return r[0]=s*m+a*v+o*_,r[3]=s*f+a*y+o*w,r[6]=s*g+a*x+o*M,r[1]=l*m+c*v+h*_,r[4]=l*f+c*y+h*w,r[7]=l*g+c*x+h*M,r[2]=u*m+d*v+p*_,r[5]=u*f+d*y+p*w,r[8]=u*g+d*x+p*M,this}multiplyScalar(t){const e=this.elements;return e[0]*=t,e[3]*=t,e[6]*=t,e[1]*=t,e[4]*=t,e[7]*=t,e[2]*=t,e[5]*=t,e[8]*=t,this}determinant(){const t=this.elements,e=t[0],n=t[1],i=t[2],r=t[3],s=t[4],a=t[5],o=t[6],l=t[7],c=t[8];return e*s*c-e*a*l-n*r*c+n*a*o+i*r*l-i*s*o}invert(){const t=this.elements,e=t[0],n=t[1],i=t[2],r=t[3],s=t[4],a=t[5],o=t[6],l=t[7],c=t[8],h=c*s-a*l,u=a*o-c*r,d=l*r-s*o,p=e*h+n*u+i*d;if(0===p)return this.set(0,0,0,0,0,0,0,0,0);const m=1/p;return t[0]=h*m,t[1]=(i*l-c*n)*m,t[2]=(a*n-i*s)*m,t[3]=u*m,t[4]=(c*e-i*o)*m,t[5]=(i*r-a*e)*m,t[6]=d*m,t[7]=(n*o-l*e)*m,t[8]=(s*e-n*r)*m,this}transpose(){let t;const e=this.elements;return t=e[1],e[1]=e[3],e[3]=t,t=e[2],e[2]=e[6],e[6]=t,t=e[5],e[5]=e[7],e[7]=t,this}getNormalMatrix(t){return this.setFromMatrix4(t).invert().transpose()}transposeIntoArray(t){const e=this.elements;return t[0]=e[0],t[1]=e[3],t[2]=e[6],t[3]=e[1],t[4]=e[4],t[5]=e[7],t[6]=e[2],t[7]=e[5],t[8]=e[8],this}setUvTransform(t,e,n,i,r,s,a){const o=Math.cos(r),l=Math.sin(r);return this.set(n*o,n*l,-n*(o*s+l*a)+s+t,-i*l,i*o,-i*(-l*s+o*a)+a+e,0,0,1),this}scale(t,e){const n=this.elements;return n[0]*=t,n[3]*=t,n[6]*=t,n[1]*=e,n[4]*=e,n[7]*=e,this}rotate(t){const e=Math.cos(t),n=Math.sin(t),i=this.elements,r=i[0],s=i[3],a=i[6],o=i[1],l=i[4],c=i[7];return i[0]=e*r+n*o,i[3]=e*s+n*l,i[6]=e*a+n*c,i[1]=-n*r+e*o,i[4]=-n*s+e*l,i[7]=-n*a+e*c,this}translate(t,e){const n=this.elements;return n[0]+=t*n[2],n[3]+=t*n[5],n[6]+=t*n[8],n[1]+=e*n[2],n[4]+=e*n[5],n[7]+=e*n[8],this}equals(t){const e=this.elements,n=t.elements;for(let t=0;t<9;t++)if(e[t]!==n[t])return!1;return!0}fromArray(t,e=0){for(let n=0;n<9;n++)this.elements[n]=t[n+e];return this}toArray(t=[],e=0){const n=this.elements;return t[e]=n[0],t[e+1]=n[1],t[e+2]=n[2],t[e+3]=n[3],t[e+4]=n[4],t[e+5]=n[5],t[e+6]=n[6],t[e+7]=n[7],t[e+8]=n[8],t}clone(){return(new this.constructor).fromArray(this.elements)}}let W;V.prototype.isMatrix3=!0;class j{static getDataURL(t){if(/^data:/i.test(t.src))return t.src;if("undefined"==typeof HTMLCanvasElement)return t.src;let e;if(t instanceof HTMLCanvasElement)e=t;else{void 0===W&&(W=document.createElementNS("http://www.w3.org/1999/xhtml","canvas")),W.width=t.width,W.height=t.height;const n=W.getContext("2d");t instanceof ImageData?n.putImageData(t,0,0):n.drawImage(t,0,0,t.width,t.height),e=W}return e.width>2048||e.height>2048?(console.warn("THREE.ImageUtils.getDataURL: Image converted to jpg for performance reasons",t),e.toDataURL("image/jpeg",.6)):e.toDataURL("image/png")}}let q=0;class X extends I{constructor(t=X.DEFAULT_IMAGE,e=X.DEFAULT_MAPPING,n=1001,i=1001,r=1006,s=1008,a=1023,o=1009,l=1,c=3e3){super(),Object.defineProperty(this,"id",{value:q++}),this.uuid=O(),this.name="",this.image=t,this.mipmaps=[],this.mapping=e,this.wrapS=n,this.wrapT=i,this.magFilter=r,this.minFilter=s,this.anisotropy=l,this.format=a,this.internalFormat=null,this.type=o,this.offset=new k(0,0),this.repeat=new k(1,1),this.center=new k(0,0),this.rotation=0,this.matrixAutoUpdate=!0,this.matrix=new V,this.generateMipmaps=!0,this.premultiplyAlpha=!1,this.flipY=!0,this.unpackAlignment=4,this.encoding=c,this.version=0,this.onUpdate=null}updateMatrix(){this.matrix.setUvTransform(this.offset.x,this.offset.y,this.repeat.x,this.repeat.y,this.rotation,this.center.x,this.center.y)}clone(){return(new this.constructor).copy(this)}copy(t){return this.name=t.name,this.image=t.image,this.mipmaps=t.mipmaps.slice(0),this.mapping=t.mapping,this.wrapS=t.wrapS,this.wrapT=t.wrapT,this.magFilter=t.magFilter,this.minFilter=t.minFilter,this.anisotropy=t.anisotropy,this.format=t.format,this.internalFormat=t.internalFormat,this.type=t.type,this.offset.copy(t.offset),this.repeat.copy(t.repeat),this.center.copy(t.center),this.rotation=t.rotation,this.matrixAutoUpdate=t.matrixAutoUpdate,this.matrix.copy(t.matrix),this.generateMipmaps=t.generateMipmaps,this.premultiplyAlpha=t.premultiplyAlpha,this.flipY=t.flipY,this.unpackAlignment=t.unpackAlignment,this.encoding=t.encoding,this}toJSON(t){const e=void 0===t||"string"==typeof t;if(!e&&void 0!==t.textures[this.uuid])return t.textures[this.uuid];const n={metadata:{version:4.5,type:"Texture",generator:"Texture.toJSON"},uuid:this.uuid,name:this.name,mapping:this.mapping,repeat:[this.repeat.x,this.repeat.y],offset:[this.offset.x,this.offset.y],center:[this.center.x,this.center.y],rotation:this.rotation,wrap:[this.wrapS,this.wrapT],format:this.format,type:this.type,encoding:this.encoding,minFilter:this.minFilter,magFilter:this.magFilter,anisotropy:this.anisotropy,flipY:this.flipY,premultiplyAlpha:this.premultiplyAlpha,unpackAlignment:this.unpackAlignment};if(void 0!==this.image){const i=this.image;if(void 0===i.uuid&&(i.uuid=O()),!e&&void 0===t.images[i.uuid]){let e;if(Array.isArray(i)){e=[];for(let t=0,n=i.length;t1)switch(this.wrapS){case r:t.x=t.x-Math.floor(t.x);break;case s:t.x=t.x<0?0:1;break;case a:1===Math.abs(Math.floor(t.x)%2)?t.x=Math.ceil(t.x)-t.x:t.x=t.x-Math.floor(t.x)}if(t.y<0||t.y>1)switch(this.wrapT){case r:t.y=t.y-Math.floor(t.y);break;case s:t.y=t.y<0?0:1;break;case a:1===Math.abs(Math.floor(t.y)%2)?t.y=Math.ceil(t.y)-t.y:t.y=t.y-Math.floor(t.y)}return this.flipY&&(t.y=1-t.y),t}set needsUpdate(t){!0===t&&this.version++}}function Y(t){return"undefined"!=typeof HTMLImageElement&&t instanceof HTMLImageElement||"undefined"!=typeof HTMLCanvasElement&&t instanceof HTMLCanvasElement||"undefined"!=typeof ImageBitmap&&t instanceof ImageBitmap?j.getDataURL(t):t.data?{data:Array.prototype.slice.call(t.data),width:t.width,height:t.height,type:t.data.constructor.name}:(console.warn("THREE.Texture: Unable to serialize Texture."),{})}X.DEFAULT_IMAGE=void 0,X.DEFAULT_MAPPING=300,X.prototype.isTexture=!0;class Z{constructor(t=0,e=0,n=0,i=1){this.x=t,this.y=e,this.z=n,this.w=i}get width(){return this.z}set width(t){this.z=t}get height(){return this.w}set height(t){this.w=t}set(t,e,n,i){return this.x=t,this.y=e,this.z=n,this.w=i,this}setScalar(t){return this.x=t,this.y=t,this.z=t,this.w=t,this}setX(t){return this.x=t,this}setY(t){return this.y=t,this}setZ(t){return this.z=t,this}setW(t){return this.w=t,this}setComponent(t,e){switch(t){case 0:this.x=e;break;case 1:this.y=e;break;case 2:this.z=e;break;case 3:this.w=e;break;default:throw new Error("index is out of range: "+t)}return this}getComponent(t){switch(t){case 0:return this.x;case 1:return this.y;case 2:return this.z;case 3:return this.w;default:throw new Error("index is out of range: "+t)}}clone(){return new this.constructor(this.x,this.y,this.z,this.w)}copy(t){return this.x=t.x,this.y=t.y,this.z=t.z,this.w=void 0!==t.w?t.w:1,this}add(t,e){return void 0!==e?(console.warn("THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(t,e)):(this.x+=t.x,this.y+=t.y,this.z+=t.z,this.w+=t.w,this)}addScalar(t){return this.x+=t,this.y+=t,this.z+=t,this.w+=t,this}addVectors(t,e){return this.x=t.x+e.x,this.y=t.y+e.y,this.z=t.z+e.z,this.w=t.w+e.w,this}addScaledVector(t,e){return this.x+=t.x*e,this.y+=t.y*e,this.z+=t.z*e,this.w+=t.w*e,this}sub(t,e){return void 0!==e?(console.warn("THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(t,e)):(this.x-=t.x,this.y-=t.y,this.z-=t.z,this.w-=t.w,this)}subScalar(t){return this.x-=t,this.y-=t,this.z-=t,this.w-=t,this}subVectors(t,e){return this.x=t.x-e.x,this.y=t.y-e.y,this.z=t.z-e.z,this.w=t.w-e.w,this}multiply(t){return this.x*=t.x,this.y*=t.y,this.z*=t.z,this.w*=t.w,this}multiplyScalar(t){return this.x*=t,this.y*=t,this.z*=t,this.w*=t,this}applyMatrix4(t){const e=this.x,n=this.y,i=this.z,r=this.w,s=t.elements;return this.x=s[0]*e+s[4]*n+s[8]*i+s[12]*r,this.y=s[1]*e+s[5]*n+s[9]*i+s[13]*r,this.z=s[2]*e+s[6]*n+s[10]*i+s[14]*r,this.w=s[3]*e+s[7]*n+s[11]*i+s[15]*r,this}divideScalar(t){return this.multiplyScalar(1/t)}setAxisAngleFromQuaternion(t){this.w=2*Math.acos(t.w);const e=Math.sqrt(1-t.w*t.w);return e<1e-4?(this.x=1,this.y=0,this.z=0):(this.x=t.x/e,this.y=t.y/e,this.z=t.z/e),this}setAxisAngleFromRotationMatrix(t){let e,n,i,r;const s=.01,a=.1,o=t.elements,l=o[0],c=o[4],h=o[8],u=o[1],d=o[5],p=o[9],m=o[2],f=o[6],g=o[10];if(Math.abs(c-u)o&&t>v?tv?o=0?1:-1,i=1-e*e;if(i>Number.EPSILON){const r=Math.sqrt(i),s=Math.atan2(r,e*n);t=Math.sin(t*s)/r,a=Math.sin(a*s)/r}const r=a*n;if(o=o*t+u*r,l=l*t+d*r,c=c*t+p*r,h=h*t+m*r,t===1-a){const t=1/Math.sqrt(o*o+l*l+c*c+h*h);o*=t,l*=t,c*=t,h*=t}}t[e]=o,t[e+1]=l,t[e+2]=c,t[e+3]=h}static multiplyQuaternionsFlat(t,e,n,i,r,s){const a=n[i],o=n[i+1],l=n[i+2],c=n[i+3],h=r[s],u=r[s+1],d=r[s+2],p=r[s+3];return t[e]=a*p+c*h+o*d-l*u,t[e+1]=o*p+c*u+l*h-a*d,t[e+2]=l*p+c*d+a*u-o*h,t[e+3]=c*p-a*h-o*u-l*d,t}get x(){return this._x}set x(t){this._x=t,this._onChangeCallback()}get y(){return this._y}set y(t){this._y=t,this._onChangeCallback()}get z(){return this._z}set z(t){this._z=t,this._onChangeCallback()}get w(){return this._w}set w(t){this._w=t,this._onChangeCallback()}set(t,e,n,i){return this._x=t,this._y=e,this._z=n,this._w=i,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._w)}copy(t){return this._x=t.x,this._y=t.y,this._z=t.z,this._w=t.w,this._onChangeCallback(),this}setFromEuler(t,e){if(!t||!t.isEuler)throw new Error("THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.");const n=t._x,i=t._y,r=t._z,s=t._order,a=Math.cos,o=Math.sin,l=a(n/2),c=a(i/2),h=a(r/2),u=o(n/2),d=o(i/2),p=o(r/2);switch(s){case"XYZ":this._x=u*c*h+l*d*p,this._y=l*d*h-u*c*p,this._z=l*c*p+u*d*h,this._w=l*c*h-u*d*p;break;case"YXZ":this._x=u*c*h+l*d*p,this._y=l*d*h-u*c*p,this._z=l*c*p-u*d*h,this._w=l*c*h+u*d*p;break;case"ZXY":this._x=u*c*h-l*d*p,this._y=l*d*h+u*c*p,this._z=l*c*p+u*d*h,this._w=l*c*h-u*d*p;break;case"ZYX":this._x=u*c*h-l*d*p,this._y=l*d*h+u*c*p,this._z=l*c*p-u*d*h,this._w=l*c*h+u*d*p;break;case"YZX":this._x=u*c*h+l*d*p,this._y=l*d*h+u*c*p,this._z=l*c*p-u*d*h,this._w=l*c*h-u*d*p;break;case"XZY":this._x=u*c*h-l*d*p,this._y=l*d*h-u*c*p,this._z=l*c*p+u*d*h,this._w=l*c*h+u*d*p;break;default:console.warn("THREE.Quaternion: .setFromEuler() encountered an unknown order: "+s)}return!1!==e&&this._onChangeCallback(),this}setFromAxisAngle(t,e){const n=e/2,i=Math.sin(n);return this._x=t.x*i,this._y=t.y*i,this._z=t.z*i,this._w=Math.cos(n),this._onChangeCallback(),this}setFromRotationMatrix(t){const e=t.elements,n=e[0],i=e[4],r=e[8],s=e[1],a=e[5],o=e[9],l=e[2],c=e[6],h=e[10],u=n+a+h;if(u>0){const t=.5/Math.sqrt(u+1);this._w=.25/t,this._x=(c-o)*t,this._y=(r-l)*t,this._z=(s-i)*t}else if(n>a&&n>h){const t=2*Math.sqrt(1+n-a-h);this._w=(c-o)/t,this._x=.25*t,this._y=(i+s)/t,this._z=(r+l)/t}else if(a>h){const t=2*Math.sqrt(1+a-n-h);this._w=(r-l)/t,this._x=(i+s)/t,this._y=.25*t,this._z=(o+c)/t}else{const t=2*Math.sqrt(1+h-n-a);this._w=(s-i)/t,this._x=(r+l)/t,this._y=(o+c)/t,this._z=.25*t}return this._onChangeCallback(),this}setFromUnitVectors(t,e){let n=t.dot(e)+1;return nMath.abs(t.z)?(this._x=-t.y,this._y=t.x,this._z=0,this._w=n):(this._x=0,this._y=-t.z,this._z=t.y,this._w=n)):(this._x=t.y*e.z-t.z*e.y,this._y=t.z*e.x-t.x*e.z,this._z=t.x*e.y-t.y*e.x,this._w=n),this.normalize()}angleTo(t){return 2*Math.acos(Math.abs(B(this.dot(t),-1,1)))}rotateTowards(t,e){const n=this.angleTo(t);if(0===n)return this;const i=Math.min(1,e/n);return this.slerp(t,i),this}identity(){return this.set(0,0,0,1)}invert(){return this.conjugate()}conjugate(){return this._x*=-1,this._y*=-1,this._z*=-1,this._onChangeCallback(),this}dot(t){return this._x*t._x+this._y*t._y+this._z*t._z+this._w*t._w}lengthSq(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w}length(){return Math.sqrt(this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w)}normalize(){let t=this.length();return 0===t?(this._x=0,this._y=0,this._z=0,this._w=1):(t=1/t,this._x=this._x*t,this._y=this._y*t,this._z=this._z*t,this._w=this._w*t),this._onChangeCallback(),this}multiply(t,e){return void 0!==e?(console.warn("THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead."),this.multiplyQuaternions(t,e)):this.multiplyQuaternions(this,t)}premultiply(t){return this.multiplyQuaternions(t,this)}multiplyQuaternions(t,e){const n=t._x,i=t._y,r=t._z,s=t._w,a=e._x,o=e._y,l=e._z,c=e._w;return this._x=n*c+s*a+i*l-r*o,this._y=i*c+s*o+r*a-n*l,this._z=r*c+s*l+n*o-i*a,this._w=s*c-n*a-i*o-r*l,this._onChangeCallback(),this}slerp(t,e){if(0===e)return this;if(1===e)return this.copy(t);const n=this._x,i=this._y,r=this._z,s=this._w;let a=s*t._w+n*t._x+i*t._y+r*t._z;if(a<0?(this._w=-t._w,this._x=-t._x,this._y=-t._y,this._z=-t._z,a=-a):this.copy(t),a>=1)return this._w=s,this._x=n,this._y=i,this._z=r,this;const o=1-a*a;if(o<=Number.EPSILON){const t=1-e;return this._w=t*s+e*this._w,this._x=t*n+e*this._x,this._y=t*i+e*this._y,this._z=t*r+e*this._z,this.normalize(),this._onChangeCallback(),this}const l=Math.sqrt(o),c=Math.atan2(l,a),h=Math.sin((1-e)*c)/l,u=Math.sin(e*c)/l;return this._w=s*h+this._w*u,this._x=n*h+this._x*u,this._y=i*h+this._y*u,this._z=r*h+this._z*u,this._onChangeCallback(),this}slerpQuaternions(t,e,n){this.copy(t).slerp(e,n)}equals(t){return t._x===this._x&&t._y===this._y&&t._z===this._z&&t._w===this._w}fromArray(t,e=0){return this._x=t[e],this._y=t[e+1],this._z=t[e+2],this._w=t[e+3],this._onChangeCallback(),this}toArray(t=[],e=0){return t[e]=this._x,t[e+1]=this._y,t[e+2]=this._z,t[e+3]=this._w,t}fromBufferAttribute(t,e){return this._x=t.getX(e),this._y=t.getY(e),this._z=t.getZ(e),this._w=t.getW(e),this}_onChange(t){return this._onChangeCallback=t,this}_onChangeCallback(){}}K.prototype.isQuaternion=!0;class ${constructor(t=0,e=0,n=0){this.x=t,this.y=e,this.z=n}set(t,e,n){return void 0===n&&(n=this.z),this.x=t,this.y=e,this.z=n,this}setScalar(t){return this.x=t,this.y=t,this.z=t,this}setX(t){return this.x=t,this}setY(t){return this.y=t,this}setZ(t){return this.z=t,this}setComponent(t,e){switch(t){case 0:this.x=e;break;case 1:this.y=e;break;case 2:this.z=e;break;default:throw new Error("index is out of range: "+t)}return this}getComponent(t){switch(t){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw new Error("index is out of range: "+t)}}clone(){return new this.constructor(this.x,this.y,this.z)}copy(t){return this.x=t.x,this.y=t.y,this.z=t.z,this}add(t,e){return void 0!==e?(console.warn("THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(t,e)):(this.x+=t.x,this.y+=t.y,this.z+=t.z,this)}addScalar(t){return this.x+=t,this.y+=t,this.z+=t,this}addVectors(t,e){return this.x=t.x+e.x,this.y=t.y+e.y,this.z=t.z+e.z,this}addScaledVector(t,e){return this.x+=t.x*e,this.y+=t.y*e,this.z+=t.z*e,this}sub(t,e){return void 0!==e?(console.warn("THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(t,e)):(this.x-=t.x,this.y-=t.y,this.z-=t.z,this)}subScalar(t){return this.x-=t,this.y-=t,this.z-=t,this}subVectors(t,e){return this.x=t.x-e.x,this.y=t.y-e.y,this.z=t.z-e.z,this}multiply(t,e){return void 0!==e?(console.warn("THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead."),this.multiplyVectors(t,e)):(this.x*=t.x,this.y*=t.y,this.z*=t.z,this)}multiplyScalar(t){return this.x*=t,this.y*=t,this.z*=t,this}multiplyVectors(t,e){return this.x=t.x*e.x,this.y=t.y*e.y,this.z=t.z*e.z,this}applyEuler(t){return t&&t.isEuler||console.error("THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order."),this.applyQuaternion(et.setFromEuler(t))}applyAxisAngle(t,e){return this.applyQuaternion(et.setFromAxisAngle(t,e))}applyMatrix3(t){const e=this.x,n=this.y,i=this.z,r=t.elements;return this.x=r[0]*e+r[3]*n+r[6]*i,this.y=r[1]*e+r[4]*n+r[7]*i,this.z=r[2]*e+r[5]*n+r[8]*i,this}applyNormalMatrix(t){return this.applyMatrix3(t).normalize()}applyMatrix4(t){const e=this.x,n=this.y,i=this.z,r=t.elements,s=1/(r[3]*e+r[7]*n+r[11]*i+r[15]);return this.x=(r[0]*e+r[4]*n+r[8]*i+r[12])*s,this.y=(r[1]*e+r[5]*n+r[9]*i+r[13])*s,this.z=(r[2]*e+r[6]*n+r[10]*i+r[14])*s,this}applyQuaternion(t){const e=this.x,n=this.y,i=this.z,r=t.x,s=t.y,a=t.z,o=t.w,l=o*e+s*i-a*n,c=o*n+a*e-r*i,h=o*i+r*n-s*e,u=-r*e-s*n-a*i;return this.x=l*o+u*-r+c*-a-h*-s,this.y=c*o+u*-s+h*-r-l*-a,this.z=h*o+u*-a+l*-s-c*-r,this}project(t){return this.applyMatrix4(t.matrixWorldInverse).applyMatrix4(t.projectionMatrix)}unproject(t){return this.applyMatrix4(t.projectionMatrixInverse).applyMatrix4(t.matrixWorld)}transformDirection(t){const e=this.x,n=this.y,i=this.z,r=t.elements;return this.x=r[0]*e+r[4]*n+r[8]*i,this.y=r[1]*e+r[5]*n+r[9]*i,this.z=r[2]*e+r[6]*n+r[10]*i,this.normalize()}divide(t){return this.x/=t.x,this.y/=t.y,this.z/=t.z,this}divideScalar(t){return this.multiplyScalar(1/t)}min(t){return this.x=Math.min(this.x,t.x),this.y=Math.min(this.y,t.y),this.z=Math.min(this.z,t.z),this}max(t){return this.x=Math.max(this.x,t.x),this.y=Math.max(this.y,t.y),this.z=Math.max(this.z,t.z),this}clamp(t,e){return this.x=Math.max(t.x,Math.min(e.x,this.x)),this.y=Math.max(t.y,Math.min(e.y,this.y)),this.z=Math.max(t.z,Math.min(e.z,this.z)),this}clampScalar(t,e){return this.x=Math.max(t,Math.min(e,this.x)),this.y=Math.max(t,Math.min(e,this.y)),this.z=Math.max(t,Math.min(e,this.z)),this}clampLength(t,e){const n=this.length();return this.divideScalar(n||1).multiplyScalar(Math.max(t,Math.min(e,n)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this.z=this.z<0?Math.ceil(this.z):Math.floor(this.z),this}negate(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this}dot(t){return this.x*t.x+this.y*t.y+this.z*t.z}lengthSq(){return this.x*this.x+this.y*this.y+this.z*this.z}length(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)}normalize(){return this.divideScalar(this.length()||1)}setLength(t){return this.normalize().multiplyScalar(t)}lerp(t,e){return this.x+=(t.x-this.x)*e,this.y+=(t.y-this.y)*e,this.z+=(t.z-this.z)*e,this}lerpVectors(t,e,n){return this.x=t.x+(e.x-t.x)*n,this.y=t.y+(e.y-t.y)*n,this.z=t.z+(e.z-t.z)*n,this}cross(t,e){return void 0!==e?(console.warn("THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead."),this.crossVectors(t,e)):this.crossVectors(this,t)}crossVectors(t,e){const n=t.x,i=t.y,r=t.z,s=e.x,a=e.y,o=e.z;return this.x=i*o-r*a,this.y=r*s-n*o,this.z=n*a-i*s,this}projectOnVector(t){const e=t.lengthSq();if(0===e)return this.set(0,0,0);const n=t.dot(this)/e;return this.copy(t).multiplyScalar(n)}projectOnPlane(t){return tt.copy(this).projectOnVector(t),this.sub(tt)}reflect(t){return this.sub(tt.copy(t).multiplyScalar(2*this.dot(t)))}angleTo(t){const e=Math.sqrt(this.lengthSq()*t.lengthSq());if(0===e)return Math.PI/2;const n=this.dot(t)/e;return Math.acos(B(n,-1,1))}distanceTo(t){return Math.sqrt(this.distanceToSquared(t))}distanceToSquared(t){const e=this.x-t.x,n=this.y-t.y,i=this.z-t.z;return e*e+n*n+i*i}manhattanDistanceTo(t){return Math.abs(this.x-t.x)+Math.abs(this.y-t.y)+Math.abs(this.z-t.z)}setFromSpherical(t){return this.setFromSphericalCoords(t.radius,t.phi,t.theta)}setFromSphericalCoords(t,e,n){const i=Math.sin(e)*t;return this.x=i*Math.sin(n),this.y=Math.cos(e)*t,this.z=i*Math.cos(n),this}setFromCylindrical(t){return this.setFromCylindricalCoords(t.radius,t.theta,t.y)}setFromCylindricalCoords(t,e,n){return this.x=t*Math.sin(e),this.y=n,this.z=t*Math.cos(e),this}setFromMatrixPosition(t){const e=t.elements;return this.x=e[12],this.y=e[13],this.z=e[14],this}setFromMatrixScale(t){const e=this.setFromMatrixColumn(t,0).length(),n=this.setFromMatrixColumn(t,1).length(),i=this.setFromMatrixColumn(t,2).length();return this.x=e,this.y=n,this.z=i,this}setFromMatrixColumn(t,e){return this.fromArray(t.elements,4*e)}setFromMatrix3Column(t,e){return this.fromArray(t.elements,3*e)}equals(t){return t.x===this.x&&t.y===this.y&&t.z===this.z}fromArray(t,e=0){return this.x=t[e],this.y=t[e+1],this.z=t[e+2],this}toArray(t=[],e=0){return t[e]=this.x,t[e+1]=this.y,t[e+2]=this.z,t}fromBufferAttribute(t,e,n){return void 0!==n&&console.warn("THREE.Vector3: offset has been removed from .fromBufferAttribute()."),this.x=t.getX(e),this.y=t.getY(e),this.z=t.getZ(e),this}random(){return this.x=Math.random(),this.y=Math.random(),this.z=Math.random(),this}}$.prototype.isVector3=!0;const tt=new $,et=new K;class nt{constructor(t=new $(1/0,1/0,1/0),e=new $(-1/0,-1/0,-1/0)){this.min=t,this.max=e}set(t,e){return this.min.copy(t),this.max.copy(e),this}setFromArray(t){let e=1/0,n=1/0,i=1/0,r=-1/0,s=-1/0,a=-1/0;for(let o=0,l=t.length;or&&(r=l),c>s&&(s=c),h>a&&(a=h)}return this.min.set(e,n,i),this.max.set(r,s,a),this}setFromBufferAttribute(t){let e=1/0,n=1/0,i=1/0,r=-1/0,s=-1/0,a=-1/0;for(let o=0,l=t.count;or&&(r=l),c>s&&(s=c),h>a&&(a=h)}return this.min.set(e,n,i),this.max.set(r,s,a),this}setFromPoints(t){this.makeEmpty();for(let e=0,n=t.length;ethis.max.x||t.ythis.max.y||t.zthis.max.z)}containsBox(t){return this.min.x<=t.min.x&&t.max.x<=this.max.x&&this.min.y<=t.min.y&&t.max.y<=this.max.y&&this.min.z<=t.min.z&&t.max.z<=this.max.z}getParameter(t,e){return e.set((t.x-this.min.x)/(this.max.x-this.min.x),(t.y-this.min.y)/(this.max.y-this.min.y),(t.z-this.min.z)/(this.max.z-this.min.z))}intersectsBox(t){return!(t.max.xthis.max.x||t.max.ythis.max.y||t.max.zthis.max.z)}intersectsSphere(t){return this.clampPoint(t.center,rt),rt.distanceToSquared(t.center)<=t.radius*t.radius}intersectsPlane(t){let e,n;return t.normal.x>0?(e=t.normal.x*this.min.x,n=t.normal.x*this.max.x):(e=t.normal.x*this.max.x,n=t.normal.x*this.min.x),t.normal.y>0?(e+=t.normal.y*this.min.y,n+=t.normal.y*this.max.y):(e+=t.normal.y*this.max.y,n+=t.normal.y*this.min.y),t.normal.z>0?(e+=t.normal.z*this.min.z,n+=t.normal.z*this.max.z):(e+=t.normal.z*this.max.z,n+=t.normal.z*this.min.z),e<=-t.constant&&n>=-t.constant}intersectsTriangle(t){if(this.isEmpty())return!1;this.getCenter(dt),pt.subVectors(this.max,dt),at.subVectors(t.a,dt),ot.subVectors(t.b,dt),lt.subVectors(t.c,dt),ct.subVectors(ot,at),ht.subVectors(lt,ot),ut.subVectors(at,lt);let e=[0,-ct.z,ct.y,0,-ht.z,ht.y,0,-ut.z,ut.y,ct.z,0,-ct.x,ht.z,0,-ht.x,ut.z,0,-ut.x,-ct.y,ct.x,0,-ht.y,ht.x,0,-ut.y,ut.x,0];return!!gt(e,at,ot,lt,pt)&&(e=[1,0,0,0,1,0,0,0,1],!!gt(e,at,ot,lt,pt)&&(mt.crossVectors(ct,ht),e=[mt.x,mt.y,mt.z],gt(e,at,ot,lt,pt)))}clampPoint(t,e){return e.copy(t).clamp(this.min,this.max)}distanceToPoint(t){return rt.copy(t).clamp(this.min,this.max).sub(t).length()}getBoundingSphere(t){return this.getCenter(t.center),t.radius=.5*this.getSize(rt).length(),t}intersect(t){return this.min.max(t.min),this.max.min(t.max),this.isEmpty()&&this.makeEmpty(),this}union(t){return this.min.min(t.min),this.max.max(t.max),this}applyMatrix4(t){return this.isEmpty()||(it[0].set(this.min.x,this.min.y,this.min.z).applyMatrix4(t),it[1].set(this.min.x,this.min.y,this.max.z).applyMatrix4(t),it[2].set(this.min.x,this.max.y,this.min.z).applyMatrix4(t),it[3].set(this.min.x,this.max.y,this.max.z).applyMatrix4(t),it[4].set(this.max.x,this.min.y,this.min.z).applyMatrix4(t),it[5].set(this.max.x,this.min.y,this.max.z).applyMatrix4(t),it[6].set(this.max.x,this.max.y,this.min.z).applyMatrix4(t),it[7].set(this.max.x,this.max.y,this.max.z).applyMatrix4(t),this.setFromPoints(it)),this}translate(t){return this.min.add(t),this.max.add(t),this}equals(t){return t.min.equals(this.min)&&t.max.equals(this.max)}}nt.prototype.isBox3=!0;const it=[new $,new $,new $,new $,new $,new $,new $,new $],rt=new $,st=new nt,at=new $,ot=new $,lt=new $,ct=new $,ht=new $,ut=new $,dt=new $,pt=new $,mt=new $,ft=new $;function gt(t,e,n,i,r){for(let s=0,a=t.length-3;s<=a;s+=3){ft.fromArray(t,s);const a=r.x*Math.abs(ft.x)+r.y*Math.abs(ft.y)+r.z*Math.abs(ft.z),o=e.dot(ft),l=n.dot(ft),c=i.dot(ft);if(Math.max(-Math.max(o,l,c),Math.min(o,l,c))>a)return!1}return!0}const vt=new nt,yt=new $,xt=new $,_t=new $;class wt{constructor(t=new $,e=-1){this.center=t,this.radius=e}set(t,e){return this.center.copy(t),this.radius=e,this}setFromPoints(t,e){const n=this.center;void 0!==e?n.copy(e):vt.setFromPoints(t).getCenter(n);let i=0;for(let e=0,r=t.length;ethis.radius*this.radius&&(e.sub(this.center).normalize(),e.multiplyScalar(this.radius).add(this.center)),e}getBoundingBox(t){return this.isEmpty()?(t.makeEmpty(),t):(t.set(this.center,this.center),t.expandByScalar(this.radius),t)}applyMatrix4(t){return this.center.applyMatrix4(t),this.radius=this.radius*t.getMaxScaleOnAxis(),this}translate(t){return this.center.add(t),this}expandByPoint(t){_t.subVectors(t,this.center);const e=_t.lengthSq();if(e>this.radius*this.radius){const t=Math.sqrt(e),n=.5*(t-this.radius);this.center.add(_t.multiplyScalar(n/t)),this.radius+=n}return this}union(t){return xt.subVectors(t.center,this.center).normalize().multiplyScalar(t.radius),this.expandByPoint(yt.copy(t.center).add(xt)),this.expandByPoint(yt.copy(t.center).sub(xt)),this}equals(t){return t.center.equals(this.center)&&t.radius===this.radius}clone(){return(new this.constructor).copy(this)}}const Mt=new $,bt=new $,St=new $,Tt=new $,Et=new $,At=new $,Lt=new $;class Ct{constructor(t=new $,e=new $(0,0,-1)){this.origin=t,this.direction=e}set(t,e){return this.origin.copy(t),this.direction.copy(e),this}copy(t){return this.origin.copy(t.origin),this.direction.copy(t.direction),this}at(t,e){return e.copy(this.direction).multiplyScalar(t).add(this.origin)}lookAt(t){return this.direction.copy(t).sub(this.origin).normalize(),this}recast(t){return this.origin.copy(this.at(t,Mt)),this}closestPointToPoint(t,e){e.subVectors(t,this.origin);const n=e.dot(this.direction);return n<0?e.copy(this.origin):e.copy(this.direction).multiplyScalar(n).add(this.origin)}distanceToPoint(t){return Math.sqrt(this.distanceSqToPoint(t))}distanceSqToPoint(t){const e=Mt.subVectors(t,this.origin).dot(this.direction);return e<0?this.origin.distanceToSquared(t):(Mt.copy(this.direction).multiplyScalar(e).add(this.origin),Mt.distanceToSquared(t))}distanceSqToSegment(t,e,n,i){bt.copy(t).add(e).multiplyScalar(.5),St.copy(e).sub(t).normalize(),Tt.copy(this.origin).sub(bt);const r=.5*t.distanceTo(e),s=-this.direction.dot(St),a=Tt.dot(this.direction),o=-Tt.dot(St),l=Tt.lengthSq(),c=Math.abs(1-s*s);let h,u,d,p;if(c>0)if(h=s*o-a,u=s*a-o,p=r*c,h>=0)if(u>=-p)if(u<=p){const t=1/c;h*=t,u*=t,d=h*(h+s*u+2*a)+u*(s*h+u+2*o)+l}else u=r,h=Math.max(0,-(s*u+a)),d=-h*h+u*(u+2*o)+l;else u=-r,h=Math.max(0,-(s*u+a)),d=-h*h+u*(u+2*o)+l;else u<=-p?(h=Math.max(0,-(-s*r+a)),u=h>0?-r:Math.min(Math.max(-r,-o),r),d=-h*h+u*(u+2*o)+l):u<=p?(h=0,u=Math.min(Math.max(-r,-o),r),d=u*(u+2*o)+l):(h=Math.max(0,-(s*r+a)),u=h>0?r:Math.min(Math.max(-r,-o),r),d=-h*h+u*(u+2*o)+l);else u=s>0?-r:r,h=Math.max(0,-(s*u+a)),d=-h*h+u*(u+2*o)+l;return n&&n.copy(this.direction).multiplyScalar(h).add(this.origin),i&&i.copy(St).multiplyScalar(u).add(bt),d}intersectSphere(t,e){Mt.subVectors(t.center,this.origin);const n=Mt.dot(this.direction),i=Mt.dot(Mt)-n*n,r=t.radius*t.radius;if(i>r)return null;const s=Math.sqrt(r-i),a=n-s,o=n+s;return a<0&&o<0?null:a<0?this.at(o,e):this.at(a,e)}intersectsSphere(t){return this.distanceSqToPoint(t.center)<=t.radius*t.radius}distanceToPlane(t){const e=t.normal.dot(this.direction);if(0===e)return 0===t.distanceToPoint(this.origin)?0:null;const n=-(this.origin.dot(t.normal)+t.constant)/e;return n>=0?n:null}intersectPlane(t,e){const n=this.distanceToPlane(t);return null===n?null:this.at(n,e)}intersectsPlane(t){const e=t.distanceToPoint(this.origin);if(0===e)return!0;return t.normal.dot(this.direction)*e<0}intersectBox(t,e){let n,i,r,s,a,o;const l=1/this.direction.x,c=1/this.direction.y,h=1/this.direction.z,u=this.origin;return l>=0?(n=(t.min.x-u.x)*l,i=(t.max.x-u.x)*l):(n=(t.max.x-u.x)*l,i=(t.min.x-u.x)*l),c>=0?(r=(t.min.y-u.y)*c,s=(t.max.y-u.y)*c):(r=(t.max.y-u.y)*c,s=(t.min.y-u.y)*c),n>s||r>i?null:((r>n||n!=n)&&(n=r),(s=0?(a=(t.min.z-u.z)*h,o=(t.max.z-u.z)*h):(a=(t.max.z-u.z)*h,o=(t.min.z-u.z)*h),n>o||a>i?null:((a>n||n!=n)&&(n=a),(o=0?n:i,e)))}intersectsBox(t){return null!==this.intersectBox(t,Mt)}intersectTriangle(t,e,n,i,r){Et.subVectors(e,t),At.subVectors(n,t),Lt.crossVectors(Et,At);let s,a=this.direction.dot(Lt);if(a>0){if(i)return null;s=1}else{if(!(a<0))return null;s=-1,a=-a}Tt.subVectors(this.origin,t);const o=s*this.direction.dot(At.crossVectors(Tt,At));if(o<0)return null;const l=s*this.direction.dot(Et.cross(Tt));if(l<0)return null;if(o+l>a)return null;const c=-s*Tt.dot(Lt);return c<0?null:this.at(c/a,r)}applyMatrix4(t){return this.origin.applyMatrix4(t),this.direction.transformDirection(t),this}equals(t){return t.origin.equals(this.origin)&&t.direction.equals(this.direction)}clone(){return(new this.constructor).copy(this)}}class Rt{constructor(){this.elements=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],arguments.length>0&&console.error("THREE.Matrix4: the constructor no longer reads arguments. use .set() instead.")}set(t,e,n,i,r,s,a,o,l,c,h,u,d,p,m,f){const g=this.elements;return g[0]=t,g[4]=e,g[8]=n,g[12]=i,g[1]=r,g[5]=s,g[9]=a,g[13]=o,g[2]=l,g[6]=c,g[10]=h,g[14]=u,g[3]=d,g[7]=p,g[11]=m,g[15]=f,this}identity(){return this.set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1),this}clone(){return(new Rt).fromArray(this.elements)}copy(t){const e=this.elements,n=t.elements;return e[0]=n[0],e[1]=n[1],e[2]=n[2],e[3]=n[3],e[4]=n[4],e[5]=n[5],e[6]=n[6],e[7]=n[7],e[8]=n[8],e[9]=n[9],e[10]=n[10],e[11]=n[11],e[12]=n[12],e[13]=n[13],e[14]=n[14],e[15]=n[15],this}copyPosition(t){const e=this.elements,n=t.elements;return e[12]=n[12],e[13]=n[13],e[14]=n[14],this}setFromMatrix3(t){const e=t.elements;return this.set(e[0],e[3],e[6],0,e[1],e[4],e[7],0,e[2],e[5],e[8],0,0,0,0,1),this}extractBasis(t,e,n){return t.setFromMatrixColumn(this,0),e.setFromMatrixColumn(this,1),n.setFromMatrixColumn(this,2),this}makeBasis(t,e,n){return this.set(t.x,e.x,n.x,0,t.y,e.y,n.y,0,t.z,e.z,n.z,0,0,0,0,1),this}extractRotation(t){const e=this.elements,n=t.elements,i=1/Pt.setFromMatrixColumn(t,0).length(),r=1/Pt.setFromMatrixColumn(t,1).length(),s=1/Pt.setFromMatrixColumn(t,2).length();return e[0]=n[0]*i,e[1]=n[1]*i,e[2]=n[2]*i,e[3]=0,e[4]=n[4]*r,e[5]=n[5]*r,e[6]=n[6]*r,e[7]=0,e[8]=n[8]*s,e[9]=n[9]*s,e[10]=n[10]*s,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,this}makeRotationFromEuler(t){t&&t.isEuler||console.error("THREE.Matrix4: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.");const e=this.elements,n=t.x,i=t.y,r=t.z,s=Math.cos(n),a=Math.sin(n),o=Math.cos(i),l=Math.sin(i),c=Math.cos(r),h=Math.sin(r);if("XYZ"===t.order){const t=s*c,n=s*h,i=a*c,r=a*h;e[0]=o*c,e[4]=-o*h,e[8]=l,e[1]=n+i*l,e[5]=t-r*l,e[9]=-a*o,e[2]=r-t*l,e[6]=i+n*l,e[10]=s*o}else if("YXZ"===t.order){const t=o*c,n=o*h,i=l*c,r=l*h;e[0]=t+r*a,e[4]=i*a-n,e[8]=s*l,e[1]=s*h,e[5]=s*c,e[9]=-a,e[2]=n*a-i,e[6]=r+t*a,e[10]=s*o}else if("ZXY"===t.order){const t=o*c,n=o*h,i=l*c,r=l*h;e[0]=t-r*a,e[4]=-s*h,e[8]=i+n*a,e[1]=n+i*a,e[5]=s*c,e[9]=r-t*a,e[2]=-s*l,e[6]=a,e[10]=s*o}else if("ZYX"===t.order){const t=s*c,n=s*h,i=a*c,r=a*h;e[0]=o*c,e[4]=i*l-n,e[8]=t*l+r,e[1]=o*h,e[5]=r*l+t,e[9]=n*l-i,e[2]=-l,e[6]=a*o,e[10]=s*o}else if("YZX"===t.order){const t=s*o,n=s*l,i=a*o,r=a*l;e[0]=o*c,e[4]=r-t*h,e[8]=i*h+n,e[1]=h,e[5]=s*c,e[9]=-a*c,e[2]=-l*c,e[6]=n*h+i,e[10]=t-r*h}else if("XZY"===t.order){const t=s*o,n=s*l,i=a*o,r=a*l;e[0]=o*c,e[4]=-h,e[8]=l*c,e[1]=t*h+r,e[5]=s*c,e[9]=n*h-i,e[2]=i*h-n,e[6]=a*c,e[10]=r*h+t}return e[3]=0,e[7]=0,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,this}makeRotationFromQuaternion(t){return this.compose(It,t,Nt)}lookAt(t,e,n){const i=this.elements;return Ot.subVectors(t,e),0===Ot.lengthSq()&&(Ot.z=1),Ot.normalize(),zt.crossVectors(n,Ot),0===zt.lengthSq()&&(1===Math.abs(n.z)?Ot.x+=1e-4:Ot.z+=1e-4,Ot.normalize(),zt.crossVectors(n,Ot)),zt.normalize(),Ft.crossVectors(Ot,zt),i[0]=zt.x,i[4]=Ft.x,i[8]=Ot.x,i[1]=zt.y,i[5]=Ft.y,i[9]=Ot.y,i[2]=zt.z,i[6]=Ft.z,i[10]=Ot.z,this}multiply(t,e){return void 0!==e?(console.warn("THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead."),this.multiplyMatrices(t,e)):this.multiplyMatrices(this,t)}premultiply(t){return this.multiplyMatrices(t,this)}multiplyMatrices(t,e){const n=t.elements,i=e.elements,r=this.elements,s=n[0],a=n[4],o=n[8],l=n[12],c=n[1],h=n[5],u=n[9],d=n[13],p=n[2],m=n[6],f=n[10],g=n[14],v=n[3],y=n[7],x=n[11],_=n[15],w=i[0],M=i[4],b=i[8],S=i[12],T=i[1],E=i[5],A=i[9],L=i[13],C=i[2],R=i[6],P=i[10],D=i[14],I=i[3],N=i[7],z=i[11],F=i[15];return r[0]=s*w+a*T+o*C+l*I,r[4]=s*M+a*E+o*R+l*N,r[8]=s*b+a*A+o*P+l*z,r[12]=s*S+a*L+o*D+l*F,r[1]=c*w+h*T+u*C+d*I,r[5]=c*M+h*E+u*R+d*N,r[9]=c*b+h*A+u*P+d*z,r[13]=c*S+h*L+u*D+d*F,r[2]=p*w+m*T+f*C+g*I,r[6]=p*M+m*E+f*R+g*N,r[10]=p*b+m*A+f*P+g*z,r[14]=p*S+m*L+f*D+g*F,r[3]=v*w+y*T+x*C+_*I,r[7]=v*M+y*E+x*R+_*N,r[11]=v*b+y*A+x*P+_*z,r[15]=v*S+y*L+x*D+_*F,this}multiplyScalar(t){const e=this.elements;return e[0]*=t,e[4]*=t,e[8]*=t,e[12]*=t,e[1]*=t,e[5]*=t,e[9]*=t,e[13]*=t,e[2]*=t,e[6]*=t,e[10]*=t,e[14]*=t,e[3]*=t,e[7]*=t,e[11]*=t,e[15]*=t,this}determinant(){const t=this.elements,e=t[0],n=t[4],i=t[8],r=t[12],s=t[1],a=t[5],o=t[9],l=t[13],c=t[2],h=t[6],u=t[10],d=t[14];return t[3]*(+r*o*h-i*l*h-r*a*u+n*l*u+i*a*d-n*o*d)+t[7]*(+e*o*d-e*l*u+r*s*u-i*s*d+i*l*c-r*o*c)+t[11]*(+e*l*h-e*a*d-r*s*h+n*s*d+r*a*c-n*l*c)+t[15]*(-i*a*c-e*o*h+e*a*u+i*s*h-n*s*u+n*o*c)}transpose(){const t=this.elements;let e;return e=t[1],t[1]=t[4],t[4]=e,e=t[2],t[2]=t[8],t[8]=e,e=t[6],t[6]=t[9],t[9]=e,e=t[3],t[3]=t[12],t[12]=e,e=t[7],t[7]=t[13],t[13]=e,e=t[11],t[11]=t[14],t[14]=e,this}setPosition(t,e,n){const i=this.elements;return t.isVector3?(i[12]=t.x,i[13]=t.y,i[14]=t.z):(i[12]=t,i[13]=e,i[14]=n),this}invert(){const t=this.elements,e=t[0],n=t[1],i=t[2],r=t[3],s=t[4],a=t[5],o=t[6],l=t[7],c=t[8],h=t[9],u=t[10],d=t[11],p=t[12],m=t[13],f=t[14],g=t[15],v=h*f*l-m*u*l+m*o*d-a*f*d-h*o*g+a*u*g,y=p*u*l-c*f*l-p*o*d+s*f*d+c*o*g-s*u*g,x=c*m*l-p*h*l+p*a*d-s*m*d-c*a*g+s*h*g,_=p*h*o-c*m*o-p*a*u+s*m*u+c*a*f-s*h*f,w=e*v+n*y+i*x+r*_;if(0===w)return this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);const M=1/w;return t[0]=v*M,t[1]=(m*u*r-h*f*r-m*i*d+n*f*d+h*i*g-n*u*g)*M,t[2]=(a*f*r-m*o*r+m*i*l-n*f*l-a*i*g+n*o*g)*M,t[3]=(h*o*r-a*u*r-h*i*l+n*u*l+a*i*d-n*o*d)*M,t[4]=y*M,t[5]=(c*f*r-p*u*r+p*i*d-e*f*d-c*i*g+e*u*g)*M,t[6]=(p*o*r-s*f*r-p*i*l+e*f*l+s*i*g-e*o*g)*M,t[7]=(s*u*r-c*o*r+c*i*l-e*u*l-s*i*d+e*o*d)*M,t[8]=x*M,t[9]=(p*h*r-c*m*r-p*n*d+e*m*d+c*n*g-e*h*g)*M,t[10]=(s*m*r-p*a*r+p*n*l-e*m*l-s*n*g+e*a*g)*M,t[11]=(c*a*r-s*h*r-c*n*l+e*h*l+s*n*d-e*a*d)*M,t[12]=_*M,t[13]=(c*m*i-p*h*i+p*n*u-e*m*u-c*n*f+e*h*f)*M,t[14]=(p*a*i-s*m*i-p*n*o+e*m*o+s*n*f-e*a*f)*M,t[15]=(s*h*i-c*a*i+c*n*o-e*h*o-s*n*u+e*a*u)*M,this}scale(t){const e=this.elements,n=t.x,i=t.y,r=t.z;return e[0]*=n,e[4]*=i,e[8]*=r,e[1]*=n,e[5]*=i,e[9]*=r,e[2]*=n,e[6]*=i,e[10]*=r,e[3]*=n,e[7]*=i,e[11]*=r,this}getMaxScaleOnAxis(){const t=this.elements,e=t[0]*t[0]+t[1]*t[1]+t[2]*t[2],n=t[4]*t[4]+t[5]*t[5]+t[6]*t[6],i=t[8]*t[8]+t[9]*t[9]+t[10]*t[10];return Math.sqrt(Math.max(e,n,i))}makeTranslation(t,e,n){return this.set(1,0,0,t,0,1,0,e,0,0,1,n,0,0,0,1),this}makeRotationX(t){const e=Math.cos(t),n=Math.sin(t);return this.set(1,0,0,0,0,e,-n,0,0,n,e,0,0,0,0,1),this}makeRotationY(t){const e=Math.cos(t),n=Math.sin(t);return this.set(e,0,n,0,0,1,0,0,-n,0,e,0,0,0,0,1),this}makeRotationZ(t){const e=Math.cos(t),n=Math.sin(t);return this.set(e,-n,0,0,n,e,0,0,0,0,1,0,0,0,0,1),this}makeRotationAxis(t,e){const n=Math.cos(e),i=Math.sin(e),r=1-n,s=t.x,a=t.y,o=t.z,l=r*s,c=r*a;return this.set(l*s+n,l*a-i*o,l*o+i*a,0,l*a+i*o,c*a+n,c*o-i*s,0,l*o-i*a,c*o+i*s,r*o*o+n,0,0,0,0,1),this}makeScale(t,e,n){return this.set(t,0,0,0,0,e,0,0,0,0,n,0,0,0,0,1),this}makeShear(t,e,n,i,r,s){return this.set(1,n,r,0,t,1,s,0,e,i,1,0,0,0,0,1),this}compose(t,e,n){const i=this.elements,r=e._x,s=e._y,a=e._z,o=e._w,l=r+r,c=s+s,h=a+a,u=r*l,d=r*c,p=r*h,m=s*c,f=s*h,g=a*h,v=o*l,y=o*c,x=o*h,_=n.x,w=n.y,M=n.z;return i[0]=(1-(m+g))*_,i[1]=(d+x)*_,i[2]=(p-y)*_,i[3]=0,i[4]=(d-x)*w,i[5]=(1-(u+g))*w,i[6]=(f+v)*w,i[7]=0,i[8]=(p+y)*M,i[9]=(f-v)*M,i[10]=(1-(u+m))*M,i[11]=0,i[12]=t.x,i[13]=t.y,i[14]=t.z,i[15]=1,this}decompose(t,e,n){const i=this.elements;let r=Pt.set(i[0],i[1],i[2]).length();const s=Pt.set(i[4],i[5],i[6]).length(),a=Pt.set(i[8],i[9],i[10]).length();this.determinant()<0&&(r=-r),t.x=i[12],t.y=i[13],t.z=i[14],Dt.copy(this);const o=1/r,l=1/s,c=1/a;return Dt.elements[0]*=o,Dt.elements[1]*=o,Dt.elements[2]*=o,Dt.elements[4]*=l,Dt.elements[5]*=l,Dt.elements[6]*=l,Dt.elements[8]*=c,Dt.elements[9]*=c,Dt.elements[10]*=c,e.setFromRotationMatrix(Dt),n.x=r,n.y=s,n.z=a,this}makePerspective(t,e,n,i,r,s){void 0===s&&console.warn("THREE.Matrix4: .makePerspective() has been redefined and has a new signature. Please check the docs.");const a=this.elements,o=2*r/(e-t),l=2*r/(n-i),c=(e+t)/(e-t),h=(n+i)/(n-i),u=-(s+r)/(s-r),d=-2*s*r/(s-r);return a[0]=o,a[4]=0,a[8]=c,a[12]=0,a[1]=0,a[5]=l,a[9]=h,a[13]=0,a[2]=0,a[6]=0,a[10]=u,a[14]=d,a[3]=0,a[7]=0,a[11]=-1,a[15]=0,this}makeOrthographic(t,e,n,i,r,s){const a=this.elements,o=1/(e-t),l=1/(n-i),c=1/(s-r),h=(e+t)*o,u=(n+i)*l,d=(s+r)*c;return a[0]=2*o,a[4]=0,a[8]=0,a[12]=-h,a[1]=0,a[5]=2*l,a[9]=0,a[13]=-u,a[2]=0,a[6]=0,a[10]=-2*c,a[14]=-d,a[3]=0,a[7]=0,a[11]=0,a[15]=1,this}equals(t){const e=this.elements,n=t.elements;for(let t=0;t<16;t++)if(e[t]!==n[t])return!1;return!0}fromArray(t,e=0){for(let n=0;n<16;n++)this.elements[n]=t[n+e];return this}toArray(t=[],e=0){const n=this.elements;return t[e]=n[0],t[e+1]=n[1],t[e+2]=n[2],t[e+3]=n[3],t[e+4]=n[4],t[e+5]=n[5],t[e+6]=n[6],t[e+7]=n[7],t[e+8]=n[8],t[e+9]=n[9],t[e+10]=n[10],t[e+11]=n[11],t[e+12]=n[12],t[e+13]=n[13],t[e+14]=n[14],t[e+15]=n[15],t}}Rt.prototype.isMatrix4=!0;const Pt=new $,Dt=new Rt,It=new $(0,0,0),Nt=new $(1,1,1),zt=new $,Ft=new $,Ot=new $,Bt=new Rt,Ut=new K;class Ht{constructor(t=0,e=0,n=0,i=Ht.DefaultOrder){this._x=t,this._y=e,this._z=n,this._order=i}get x(){return this._x}set x(t){this._x=t,this._onChangeCallback()}get y(){return this._y}set y(t){this._y=t,this._onChangeCallback()}get z(){return this._z}set z(t){this._z=t,this._onChangeCallback()}get order(){return this._order}set order(t){this._order=t,this._onChangeCallback()}set(t,e,n,i=this._order){return this._x=t,this._y=e,this._z=n,this._order=i,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._order)}copy(t){return this._x=t._x,this._y=t._y,this._z=t._z,this._order=t._order,this._onChangeCallback(),this}setFromRotationMatrix(t,e=this._order,n=!0){const i=t.elements,r=i[0],s=i[4],a=i[8],o=i[1],l=i[5],c=i[9],h=i[2],u=i[6],d=i[10];switch(e){case"XYZ":this._y=Math.asin(B(a,-1,1)),Math.abs(a)<.9999999?(this._x=Math.atan2(-c,d),this._z=Math.atan2(-s,r)):(this._x=Math.atan2(u,l),this._z=0);break;case"YXZ":this._x=Math.asin(-B(c,-1,1)),Math.abs(c)<.9999999?(this._y=Math.atan2(a,d),this._z=Math.atan2(o,l)):(this._y=Math.atan2(-h,r),this._z=0);break;case"ZXY":this._x=Math.asin(B(u,-1,1)),Math.abs(u)<.9999999?(this._y=Math.atan2(-h,d),this._z=Math.atan2(-s,l)):(this._y=0,this._z=Math.atan2(o,r));break;case"ZYX":this._y=Math.asin(-B(h,-1,1)),Math.abs(h)<.9999999?(this._x=Math.atan2(u,d),this._z=Math.atan2(o,r)):(this._x=0,this._z=Math.atan2(-s,l));break;case"YZX":this._z=Math.asin(B(o,-1,1)),Math.abs(o)<.9999999?(this._x=Math.atan2(-c,l),this._y=Math.atan2(-h,r)):(this._x=0,this._y=Math.atan2(a,d));break;case"XZY":this._z=Math.asin(-B(s,-1,1)),Math.abs(s)<.9999999?(this._x=Math.atan2(u,l),this._y=Math.atan2(a,r)):(this._x=Math.atan2(-c,d),this._y=0);break;default:console.warn("THREE.Euler: .setFromRotationMatrix() encountered an unknown order: "+e)}return this._order=e,!0===n&&this._onChangeCallback(),this}setFromQuaternion(t,e,n){return Bt.makeRotationFromQuaternion(t),this.setFromRotationMatrix(Bt,e,n)}setFromVector3(t,e=this._order){return this.set(t.x,t.y,t.z,e)}reorder(t){return Ut.setFromEuler(this),this.setFromQuaternion(Ut,t)}equals(t){return t._x===this._x&&t._y===this._y&&t._z===this._z&&t._order===this._order}fromArray(t){return this._x=t[0],this._y=t[1],this._z=t[2],void 0!==t[3]&&(this._order=t[3]),this._onChangeCallback(),this}toArray(t=[],e=0){return t[e]=this._x,t[e+1]=this._y,t[e+2]=this._z,t[e+3]=this._order,t}toVector3(t){return t?t.set(this._x,this._y,this._z):new $(this._x,this._y,this._z)}_onChange(t){return this._onChangeCallback=t,this}_onChangeCallback(){}}Ht.prototype.isEuler=!0,Ht.DefaultOrder="XYZ",Ht.RotationOrders=["XYZ","YZX","ZXY","XZY","YXZ","ZYX"];class Gt{constructor(){this.mask=1}set(t){this.mask=1<1){for(let t=0;t1){for(let t=0;t0){i.children=[];for(let e=0;e0){i.animations=[];for(let e=0;e0&&(n.geometries=e),i.length>0&&(n.materials=i),r.length>0&&(n.textures=r),a.length>0&&(n.images=a),o.length>0&&(n.shapes=o),l.length>0&&(n.skeletons=l),c.length>0&&(n.animations=c)}return n.object=i,n;function s(t){const e=[];for(const n in t){const i=t[n];delete i.metadata,e.push(i)}return e}}clone(t){return(new this.constructor).copy(this,t)}copy(t,e=!0){if(this.name=t.name,this.up.copy(t.up),this.position.copy(t.position),this.rotation.order=t.rotation.order,this.quaternion.copy(t.quaternion),this.scale.copy(t.scale),this.matrix.copy(t.matrix),this.matrixWorld.copy(t.matrixWorld),this.matrixAutoUpdate=t.matrixAutoUpdate,this.matrixWorldNeedsUpdate=t.matrixWorldNeedsUpdate,this.layers.mask=t.layers.mask,this.visible=t.visible,this.castShadow=t.castShadow,this.receiveShadow=t.receiveShadow,this.frustumCulled=t.frustumCulled,this.renderOrder=t.renderOrder,this.userData=JSON.parse(JSON.stringify(t.userData)),!0===e)for(let e=0;e0?i.multiplyScalar(1/Math.sqrt(r)):i.set(0,0,0)}static getBarycoord(t,e,n,i,r){ne.subVectors(i,e),ie.subVectors(n,e),re.subVectors(t,e);const s=ne.dot(ne),a=ne.dot(ie),o=ne.dot(re),l=ie.dot(ie),c=ie.dot(re),h=s*l-a*a;if(0===h)return r.set(-2,-1,-1);const u=1/h,d=(l*o-a*c)*u,p=(s*c-a*o)*u;return r.set(1-d-p,p,d)}static containsPoint(t,e,n,i){return this.getBarycoord(t,e,n,i,se),se.x>=0&&se.y>=0&&se.x+se.y<=1}static getUV(t,e,n,i,r,s,a,o){return this.getBarycoord(t,e,n,i,se),o.set(0,0),o.addScaledVector(r,se.x),o.addScaledVector(s,se.y),o.addScaledVector(a,se.z),o}static isFrontFacing(t,e,n,i){return ne.subVectors(n,e),ie.subVectors(t,e),ne.cross(ie).dot(i)<0}set(t,e,n){return this.a.copy(t),this.b.copy(e),this.c.copy(n),this}setFromPointsAndIndices(t,e,n,i){return this.a.copy(t[e]),this.b.copy(t[n]),this.c.copy(t[i]),this}clone(){return(new this.constructor).copy(this)}copy(t){return this.a.copy(t.a),this.b.copy(t.b),this.c.copy(t.c),this}getArea(){return ne.subVectors(this.c,this.b),ie.subVectors(this.a,this.b),.5*ne.cross(ie).length()}getMidpoint(t){return t.addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)}getNormal(t){return de.getNormal(this.a,this.b,this.c,t)}getPlane(t){return t.setFromCoplanarPoints(this.a,this.b,this.c)}getBarycoord(t,e){return de.getBarycoord(t,this.a,this.b,this.c,e)}getUV(t,e,n,i,r){return de.getUV(t,this.a,this.b,this.c,e,n,i,r)}containsPoint(t){return de.containsPoint(t,this.a,this.b,this.c)}isFrontFacing(t){return de.isFrontFacing(this.a,this.b,this.c,t)}intersectsBox(t){return t.intersectsTriangle(this)}closestPointToPoint(t,e){const n=this.a,i=this.b,r=this.c;let s,a;ae.subVectors(i,n),oe.subVectors(r,n),ce.subVectors(t,n);const o=ae.dot(ce),l=oe.dot(ce);if(o<=0&&l<=0)return e.copy(n);he.subVectors(t,i);const c=ae.dot(he),h=oe.dot(he);if(c>=0&&h<=c)return e.copy(i);const u=o*h-c*l;if(u<=0&&o>=0&&c<=0)return s=o/(o-c),e.copy(n).addScaledVector(ae,s);ue.subVectors(t,r);const d=ae.dot(ue),p=oe.dot(ue);if(p>=0&&d<=p)return e.copy(r);const m=d*l-o*p;if(m<=0&&l>=0&&p<=0)return a=l/(l-p),e.copy(n).addScaledVector(oe,a);const f=c*p-d*h;if(f<=0&&h-c>=0&&d-p>=0)return le.subVectors(r,i),a=(h-c)/(h-c+(d-p)),e.copy(i).addScaledVector(le,a);const g=1/(f+m+u);return s=m*g,a=u*g,e.copy(n).addScaledVector(ae,s).addScaledVector(oe,a)}equals(t){return t.a.equals(this.a)&&t.b.equals(this.b)&&t.c.equals(this.c)}}let pe=0;class me extends I{constructor(){super(),Object.defineProperty(this,"id",{value:pe++}),this.uuid=O(),this.name="",this.type="Material",this.fog=!0,this.blending=1,this.side=0,this.vertexColors=!1,this.opacity=1,this.transparent=!1,this.blendSrc=204,this.blendDst=205,this.blendEquation=i,this.blendSrcAlpha=null,this.blendDstAlpha=null,this.blendEquationAlpha=null,this.depthFunc=3,this.depthTest=!0,this.depthWrite=!0,this.stencilWriteMask=255,this.stencilFunc=519,this.stencilRef=0,this.stencilFuncMask=255,this.stencilFail=C,this.stencilZFail=C,this.stencilZPass=C,this.stencilWrite=!1,this.clippingPlanes=null,this.clipIntersection=!1,this.clipShadows=!1,this.shadowSide=null,this.colorWrite=!0,this.precision=null,this.polygonOffset=!1,this.polygonOffsetFactor=0,this.polygonOffsetUnits=0,this.dithering=!1,this.alphaTest=0,this.alphaToCoverage=!1,this.premultipliedAlpha=!1,this.visible=!0,this.toneMapped=!0,this.userData={},this.version=0}onBuild(){}onBeforeCompile(){}customProgramCacheKey(){return this.onBeforeCompile.toString()}setValues(t){if(void 0!==t)for(const e in t){const n=t[e];if(void 0===n){console.warn("THREE.Material: '"+e+"' parameter is undefined.");continue}if("shading"===e){console.warn("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead."),this.flatShading=1===n;continue}const i=this[e];void 0!==i?i&&i.isColor?i.set(n):i&&i.isVector3&&n&&n.isVector3?i.copy(n):this[e]=n:console.warn("THREE."+this.type+": '"+e+"' is not a property of this material.")}}toJSON(t){const e=void 0===t||"string"==typeof t;e&&(t={textures:{},images:{}});const n={metadata:{version:4.5,type:"Material",generator:"Material.toJSON"}};function i(t){const e=[];for(const n in t){const i=t[n];delete i.metadata,e.push(i)}return e}if(n.uuid=this.uuid,n.type=this.type,""!==this.name&&(n.name=this.name),this.color&&this.color.isColor&&(n.color=this.color.getHex()),void 0!==this.roughness&&(n.roughness=this.roughness),void 0!==this.metalness&&(n.metalness=this.metalness),this.sheen&&this.sheen.isColor&&(n.sheen=this.sheen.getHex()),this.emissive&&this.emissive.isColor&&(n.emissive=this.emissive.getHex()),this.emissiveIntensity&&1!==this.emissiveIntensity&&(n.emissiveIntensity=this.emissiveIntensity),this.specular&&this.specular.isColor&&(n.specular=this.specular.getHex()),void 0!==this.shininess&&(n.shininess=this.shininess),void 0!==this.clearcoat&&(n.clearcoat=this.clearcoat),void 0!==this.clearcoatRoughness&&(n.clearcoatRoughness=this.clearcoatRoughness),this.clearcoatMap&&this.clearcoatMap.isTexture&&(n.clearcoatMap=this.clearcoatMap.toJSON(t).uuid),this.clearcoatRoughnessMap&&this.clearcoatRoughnessMap.isTexture&&(n.clearcoatRoughnessMap=this.clearcoatRoughnessMap.toJSON(t).uuid),this.clearcoatNormalMap&&this.clearcoatNormalMap.isTexture&&(n.clearcoatNormalMap=this.clearcoatNormalMap.toJSON(t).uuid,n.clearcoatNormalScale=this.clearcoatNormalScale.toArray()),this.map&&this.map.isTexture&&(n.map=this.map.toJSON(t).uuid),this.matcap&&this.matcap.isTexture&&(n.matcap=this.matcap.toJSON(t).uuid),this.alphaMap&&this.alphaMap.isTexture&&(n.alphaMap=this.alphaMap.toJSON(t).uuid),this.lightMap&&this.lightMap.isTexture&&(n.lightMap=this.lightMap.toJSON(t).uuid,n.lightMapIntensity=this.lightMapIntensity),this.aoMap&&this.aoMap.isTexture&&(n.aoMap=this.aoMap.toJSON(t).uuid,n.aoMapIntensity=this.aoMapIntensity),this.bumpMap&&this.bumpMap.isTexture&&(n.bumpMap=this.bumpMap.toJSON(t).uuid,n.bumpScale=this.bumpScale),this.normalMap&&this.normalMap.isTexture&&(n.normalMap=this.normalMap.toJSON(t).uuid,n.normalMapType=this.normalMapType,n.normalScale=this.normalScale.toArray()),this.displacementMap&&this.displacementMap.isTexture&&(n.displacementMap=this.displacementMap.toJSON(t).uuid,n.displacementScale=this.displacementScale,n.displacementBias=this.displacementBias),this.roughnessMap&&this.roughnessMap.isTexture&&(n.roughnessMap=this.roughnessMap.toJSON(t).uuid),this.metalnessMap&&this.metalnessMap.isTexture&&(n.metalnessMap=this.metalnessMap.toJSON(t).uuid),this.emissiveMap&&this.emissiveMap.isTexture&&(n.emissiveMap=this.emissiveMap.toJSON(t).uuid),this.specularMap&&this.specularMap.isTexture&&(n.specularMap=this.specularMap.toJSON(t).uuid),this.envMap&&this.envMap.isTexture&&(n.envMap=this.envMap.toJSON(t).uuid,void 0!==this.combine&&(n.combine=this.combine)),void 0!==this.envMapIntensity&&(n.envMapIntensity=this.envMapIntensity),void 0!==this.reflectivity&&(n.reflectivity=this.reflectivity),void 0!==this.refractionRatio&&(n.refractionRatio=this.refractionRatio),this.gradientMap&&this.gradientMap.isTexture&&(n.gradientMap=this.gradientMap.toJSON(t).uuid),void 0!==this.transmission&&(n.transmission=this.transmission),this.transmissionMap&&this.transmissionMap.isTexture&&(n.transmissionMap=this.transmissionMap.toJSON(t).uuid),void 0!==this.thickness&&(n.thickness=this.thickness),this.thicknessMap&&this.thicknessMap.isTexture&&(n.thicknessMap=this.thicknessMap.toJSON(t).uuid),void 0!==this.attenuationDistance&&(n.attenuationDistance=this.attenuationDistance),void 0!==this.attenuationColor&&(n.attenuationColor=this.attenuationColor.getHex()),void 0!==this.size&&(n.size=this.size),null!==this.shadowSide&&(n.shadowSide=this.shadowSide),void 0!==this.sizeAttenuation&&(n.sizeAttenuation=this.sizeAttenuation),1!==this.blending&&(n.blending=this.blending),0!==this.side&&(n.side=this.side),this.vertexColors&&(n.vertexColors=!0),this.opacity<1&&(n.opacity=this.opacity),!0===this.transparent&&(n.transparent=this.transparent),n.depthFunc=this.depthFunc,n.depthTest=this.depthTest,n.depthWrite=this.depthWrite,n.colorWrite=this.colorWrite,n.stencilWrite=this.stencilWrite,n.stencilWriteMask=this.stencilWriteMask,n.stencilFunc=this.stencilFunc,n.stencilRef=this.stencilRef,n.stencilFuncMask=this.stencilFuncMask,n.stencilFail=this.stencilFail,n.stencilZFail=this.stencilZFail,n.stencilZPass=this.stencilZPass,this.rotation&&0!==this.rotation&&(n.rotation=this.rotation),!0===this.polygonOffset&&(n.polygonOffset=!0),0!==this.polygonOffsetFactor&&(n.polygonOffsetFactor=this.polygonOffsetFactor),0!==this.polygonOffsetUnits&&(n.polygonOffsetUnits=this.polygonOffsetUnits),this.linewidth&&1!==this.linewidth&&(n.linewidth=this.linewidth),void 0!==this.dashSize&&(n.dashSize=this.dashSize),void 0!==this.gapSize&&(n.gapSize=this.gapSize),void 0!==this.scale&&(n.scale=this.scale),!0===this.dithering&&(n.dithering=!0),this.alphaTest>0&&(n.alphaTest=this.alphaTest),!0===this.alphaToCoverage&&(n.alphaToCoverage=this.alphaToCoverage),!0===this.premultipliedAlpha&&(n.premultipliedAlpha=this.premultipliedAlpha),!0===this.wireframe&&(n.wireframe=this.wireframe),this.wireframeLinewidth>1&&(n.wireframeLinewidth=this.wireframeLinewidth),"round"!==this.wireframeLinecap&&(n.wireframeLinecap=this.wireframeLinecap),"round"!==this.wireframeLinejoin&&(n.wireframeLinejoin=this.wireframeLinejoin),!0===this.morphTargets&&(n.morphTargets=!0),!0===this.morphNormals&&(n.morphNormals=!0),!0===this.flatShading&&(n.flatShading=this.flatShading),!1===this.visible&&(n.visible=!1),!1===this.toneMapped&&(n.toneMapped=!1),"{}"!==JSON.stringify(this.userData)&&(n.userData=this.userData),e){const e=i(t.textures),r=i(t.images);e.length>0&&(n.textures=e),r.length>0&&(n.images=r)}return n}clone(){return(new this.constructor).copy(this)}copy(t){this.name=t.name,this.fog=t.fog,this.blending=t.blending,this.side=t.side,this.vertexColors=t.vertexColors,this.opacity=t.opacity,this.transparent=t.transparent,this.blendSrc=t.blendSrc,this.blendDst=t.blendDst,this.blendEquation=t.blendEquation,this.blendSrcAlpha=t.blendSrcAlpha,this.blendDstAlpha=t.blendDstAlpha,this.blendEquationAlpha=t.blendEquationAlpha,this.depthFunc=t.depthFunc,this.depthTest=t.depthTest,this.depthWrite=t.depthWrite,this.stencilWriteMask=t.stencilWriteMask,this.stencilFunc=t.stencilFunc,this.stencilRef=t.stencilRef,this.stencilFuncMask=t.stencilFuncMask,this.stencilFail=t.stencilFail,this.stencilZFail=t.stencilZFail,this.stencilZPass=t.stencilZPass,this.stencilWrite=t.stencilWrite;const e=t.clippingPlanes;let n=null;if(null!==e){const t=e.length;n=new Array(t);for(let i=0;i!==t;++i)n[i]=e[i].clone()}return this.clippingPlanes=n,this.clipIntersection=t.clipIntersection,this.clipShadows=t.clipShadows,this.shadowSide=t.shadowSide,this.colorWrite=t.colorWrite,this.precision=t.precision,this.polygonOffset=t.polygonOffset,this.polygonOffsetFactor=t.polygonOffsetFactor,this.polygonOffsetUnits=t.polygonOffsetUnits,this.dithering=t.dithering,this.alphaTest=t.alphaTest,this.alphaToCoverage=t.alphaToCoverage,this.premultipliedAlpha=t.premultipliedAlpha,this.visible=t.visible,this.toneMapped=t.toneMapped,this.userData=JSON.parse(JSON.stringify(t.userData)),this}dispose(){this.dispatchEvent({type:"dispose"})}set needsUpdate(t){!0===t&&this.version++}}me.prototype.isMaterial=!0;const fe={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074},ge={h:0,s:0,l:0},ve={h:0,s:0,l:0};function ye(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+6*(e-t)*(2/3-n):t}function xe(t){return t<.04045?.0773993808*t:Math.pow(.9478672986*t+.0521327014,2.4)}function _e(t){return t<.0031308?12.92*t:1.055*Math.pow(t,.41666)-.055}class we{constructor(t,e,n){return void 0===e&&void 0===n?this.set(t):this.setRGB(t,e,n)}set(t){return t&&t.isColor?this.copy(t):"number"==typeof t?this.setHex(t):"string"==typeof t&&this.setStyle(t),this}setScalar(t){return this.r=t,this.g=t,this.b=t,this}setHex(t){return t=Math.floor(t),this.r=(t>>16&255)/255,this.g=(t>>8&255)/255,this.b=(255&t)/255,this}setRGB(t,e,n){return this.r=t,this.g=e,this.b=n,this}setHSL(t,e,n){var i;if(t=(t%(i=1)+i)%i,e=B(e,0,1),n=B(n,0,1),0===e)this.r=this.g=this.b=n;else{const i=n<=.5?n*(1+e):n+e-n*e,r=2*n-i;this.r=ye(r,i,t+1/3),this.g=ye(r,i,t),this.b=ye(r,i,t-1/3)}return this}setStyle(t){function e(e){void 0!==e&&parseFloat(e)<1&&console.warn("THREE.Color: Alpha component of "+t+" will be ignored.")}let n;if(n=/^((?:rgb|hsl)a?)\(([^\)]*)\)/.exec(t)){let t;const i=n[1],r=n[2];switch(i){case"rgb":case"rgba":if(t=/^\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(r))return this.r=Math.min(255,parseInt(t[1],10))/255,this.g=Math.min(255,parseInt(t[2],10))/255,this.b=Math.min(255,parseInt(t[3],10))/255,e(t[4]),this;if(t=/^\s*(\d+)\%\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(r))return this.r=Math.min(100,parseInt(t[1],10))/100,this.g=Math.min(100,parseInt(t[2],10))/100,this.b=Math.min(100,parseInt(t[3],10))/100,e(t[4]),this;break;case"hsl":case"hsla":if(t=/^\s*(\d*\.?\d+)\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(r)){const n=parseFloat(t[1])/360,i=parseInt(t[2],10)/100,r=parseInt(t[3],10)/100;return e(t[4]),this.setHSL(n,i,r)}}}else if(n=/^\#([A-Fa-f\d]+)$/.exec(t)){const t=n[1],e=t.length;if(3===e)return this.r=parseInt(t.charAt(0)+t.charAt(0),16)/255,this.g=parseInt(t.charAt(1)+t.charAt(1),16)/255,this.b=parseInt(t.charAt(2)+t.charAt(2),16)/255,this;if(6===e)return this.r=parseInt(t.charAt(0)+t.charAt(1),16)/255,this.g=parseInt(t.charAt(2)+t.charAt(3),16)/255,this.b=parseInt(t.charAt(4)+t.charAt(5),16)/255,this}return t&&t.length>0?this.setColorName(t):this}setColorName(t){const e=fe[t.toLowerCase()];return void 0!==e?this.setHex(e):console.warn("THREE.Color: Unknown color "+t),this}clone(){return new this.constructor(this.r,this.g,this.b)}copy(t){return this.r=t.r,this.g=t.g,this.b=t.b,this}copyGammaToLinear(t,e=2){return this.r=Math.pow(t.r,e),this.g=Math.pow(t.g,e),this.b=Math.pow(t.b,e),this}copyLinearToGamma(t,e=2){const n=e>0?1/e:1;return this.r=Math.pow(t.r,n),this.g=Math.pow(t.g,n),this.b=Math.pow(t.b,n),this}convertGammaToLinear(t){return this.copyGammaToLinear(this,t),this}convertLinearToGamma(t){return this.copyLinearToGamma(this,t),this}copySRGBToLinear(t){return this.r=xe(t.r),this.g=xe(t.g),this.b=xe(t.b),this}copyLinearToSRGB(t){return this.r=_e(t.r),this.g=_e(t.g),this.b=_e(t.b),this}convertSRGBToLinear(){return this.copySRGBToLinear(this),this}convertLinearToSRGB(){return this.copyLinearToSRGB(this),this}getHex(){return 255*this.r<<16^255*this.g<<8^255*this.b<<0}getHexString(){return("000000"+this.getHex().toString(16)).slice(-6)}getHSL(t){const e=this.r,n=this.g,i=this.b,r=Math.max(e,n,i),s=Math.min(e,n,i);let a,o;const l=(s+r)/2;if(s===r)a=0,o=0;else{const t=r-s;switch(o=l<=.5?t/(r+s):t/(2-r-s),r){case e:a=(n-i)/t+(ne&&(e=t[n]);return e}let Re=0;const Pe=new Rt,De=new ee,Ie=new $,Ne=new nt,ze=new nt,Fe=new $;class Oe extends I{constructor(){super(),Object.defineProperty(this,"id",{value:Re++}),this.uuid=O(),this.name="",this.type="BufferGeometry",this.index=null,this.attributes={},this.morphAttributes={},this.morphTargetsRelative=!1,this.groups=[],this.boundingBox=null,this.boundingSphere=null,this.drawRange={start:0,count:1/0},this.userData={}}getIndex(){return this.index}setIndex(t){return Array.isArray(t)?this.index=new(Ce(t)>65535?Ae:Ee)(t,1):this.index=t,this}getAttribute(t){return this.attributes[t]}setAttribute(t,e){return this.attributes[t]=e,this}deleteAttribute(t){return delete this.attributes[t],this}hasAttribute(t){return void 0!==this.attributes[t]}addGroup(t,e,n=0){this.groups.push({start:t,count:e,materialIndex:n})}clearGroups(){this.groups=[]}setDrawRange(t,e){this.drawRange.start=t,this.drawRange.count=e}applyMatrix4(t){const e=this.attributes.position;void 0!==e&&(e.applyMatrix4(t),e.needsUpdate=!0);const n=this.attributes.normal;if(void 0!==n){const e=(new V).getNormalMatrix(t);n.applyNormalMatrix(e),n.needsUpdate=!0}const i=this.attributes.tangent;return void 0!==i&&(i.transformDirection(t),i.needsUpdate=!0),null!==this.boundingBox&&this.computeBoundingBox(),null!==this.boundingSphere&&this.computeBoundingSphere(),this}applyQuaternion(t){return Pe.makeRotationFromQuaternion(t),this.applyMatrix4(Pe),this}rotateX(t){return Pe.makeRotationX(t),this.applyMatrix4(Pe),this}rotateY(t){return Pe.makeRotationY(t),this.applyMatrix4(Pe),this}rotateZ(t){return Pe.makeRotationZ(t),this.applyMatrix4(Pe),this}translate(t,e,n){return Pe.makeTranslation(t,e,n),this.applyMatrix4(Pe),this}scale(t,e,n){return Pe.makeScale(t,e,n),this.applyMatrix4(Pe),this}lookAt(t){return De.lookAt(t),De.updateMatrix(),this.applyMatrix4(De.matrix),this}center(){return this.computeBoundingBox(),this.boundingBox.getCenter(Ie).negate(),this.translate(Ie.x,Ie.y,Ie.z),this}setFromPoints(t){const e=[];for(let n=0,i=t.length;n0&&(t.userData=this.userData),void 0!==this.parameters){const e=this.parameters;for(const n in e)void 0!==e[n]&&(t[n]=e[n]);return t}t.data={attributes:{}};const e=this.index;null!==e&&(t.data.index={type:e.array.constructor.name,array:Array.prototype.slice.call(e.array)});const n=this.attributes;for(const e in n){const i=n[e];t.data.attributes[e]=i.toJSON(t.data)}const i={};let r=!1;for(const e in this.morphAttributes){const n=this.morphAttributes[e],s=[];for(let e=0,i=n.length;e0&&(i[e]=s,r=!0)}r&&(t.data.morphAttributes=i,t.data.morphTargetsRelative=this.morphTargetsRelative);const s=this.groups;s.length>0&&(t.data.groups=JSON.parse(JSON.stringify(s)));const a=this.boundingSphere;return null!==a&&(t.data.boundingSphere={center:a.center.toArray(),radius:a.radius}),t}clone(){return(new Oe).copy(this)}copy(t){this.index=null,this.attributes={},this.morphAttributes={},this.groups=[],this.boundingBox=null,this.boundingSphere=null;const e={};this.name=t.name;const n=t.index;null!==n&&this.setIndex(n.clone(e));const i=t.attributes;for(const t in i){const n=i[t];this.setAttribute(t,n.clone(e))}const r=t.morphAttributes;for(const t in r){const n=[],i=r[t];for(let t=0,r=i.length;t0){const t=e[n[0]];if(void 0!==t){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let e=0,n=t.length;e0&&console.error("THREE.Mesh.updateMorphTargets() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")}}raycast(t,e){const n=this.geometry,i=this.material,r=this.matrixWorld;if(void 0===i)return;if(null===n.boundingSphere&&n.computeBoundingSphere(),He.copy(n.boundingSphere),He.applyMatrix4(r),!1===t.ray.intersectsSphere(He))return;if(Be.copy(r).invert(),Ue.copy(t.ray).applyMatrix4(Be),null!==n.boundingBox&&!1===Ue.intersectsBox(n.boundingBox))return;let s;if(n.isBufferGeometry){const r=n.index,a=n.attributes.position,o=n.morphAttributes.position,l=n.morphTargetsRelative,c=n.attributes.uv,h=n.attributes.uv2,u=n.groups,d=n.drawRange;if(null!==r)if(Array.isArray(i))for(let n=0,p=u.length;nn.far?null:{distance:c,point:tn.clone(),object:t}}(t,e,n,i,Ge,ke,Ve,$e);if(p){o&&(Je.fromBufferAttribute(o,c),Qe.fromBufferAttribute(o,h),Ke.fromBufferAttribute(o,u),p.uv=de.getUV($e,Ge,ke,Ve,Je,Qe,Ke,new k)),l&&(Je.fromBufferAttribute(l,c),Qe.fromBufferAttribute(l,h),Ke.fromBufferAttribute(l,u),p.uv2=de.getUV($e,Ge,ke,Ve,Je,Qe,Ke,new k));const t={a:c,b:h,c:u,normal:new $,materialIndex:0};de.getNormal(Ge,ke,Ve,t.normal),p.face=t}return p}en.prototype.isMesh=!0;class rn extends Oe{constructor(t=1,e=1,n=1,i=1,r=1,s=1){super(),this.type="BoxGeometry",this.parameters={width:t,height:e,depth:n,widthSegments:i,heightSegments:r,depthSegments:s};const a=this;i=Math.floor(i),r=Math.floor(r),s=Math.floor(s);const o=[],l=[],c=[],h=[];let u=0,d=0;function p(t,e,n,i,r,s,p,m,f,g,v){const y=s/f,x=p/g,_=s/2,w=p/2,M=m/2,b=f+1,S=g+1;let T=0,E=0;const A=new $;for(let s=0;s0?1:-1,c.push(A.x,A.y,A.z),h.push(o/f),h.push(1-s/g),T+=1}}for(let t=0;t0&&(e.defines=this.defines),e.vertexShader=this.vertexShader,e.fragmentShader=this.fragmentShader;const n={};for(const t in this.extensions)!0===this.extensions[t]&&(n[t]=!0);return Object.keys(n).length>0&&(e.extensions=n),e}}ln.prototype.isShaderMaterial=!0;class cn extends ee{constructor(){super(),this.type="Camera",this.matrixWorldInverse=new Rt,this.projectionMatrix=new Rt,this.projectionMatrixInverse=new Rt}copy(t,e){return super.copy(t,e),this.matrixWorldInverse.copy(t.matrixWorldInverse),this.projectionMatrix.copy(t.projectionMatrix),this.projectionMatrixInverse.copy(t.projectionMatrixInverse),this}getWorldDirection(t){this.updateWorldMatrix(!0,!1);const e=this.matrixWorld.elements;return t.set(-e[8],-e[9],-e[10]).normalize()}updateMatrixWorld(t){super.updateMatrixWorld(t),this.matrixWorldInverse.copy(this.matrixWorld).invert()}updateWorldMatrix(t,e){super.updateWorldMatrix(t,e),this.matrixWorldInverse.copy(this.matrixWorld).invert()}clone(){return(new this.constructor).copy(this)}}cn.prototype.isCamera=!0;class hn extends cn{constructor(t=50,e=1,n=.1,i=2e3){super(),this.type="PerspectiveCamera",this.fov=t,this.zoom=1,this.near=n,this.far=i,this.focus=10,this.aspect=e,this.view=null,this.filmGauge=35,this.filmOffset=0,this.updateProjectionMatrix()}copy(t,e){return super.copy(t,e),this.fov=t.fov,this.zoom=t.zoom,this.near=t.near,this.far=t.far,this.focus=t.focus,this.aspect=t.aspect,this.view=null===t.view?null:Object.assign({},t.view),this.filmGauge=t.filmGauge,this.filmOffset=t.filmOffset,this}setFocalLength(t){const e=.5*this.getFilmHeight()/t;this.fov=2*F*Math.atan(e),this.updateProjectionMatrix()}getFocalLength(){const t=Math.tan(.5*z*this.fov);return.5*this.getFilmHeight()/t}getEffectiveFOV(){return 2*F*Math.atan(Math.tan(.5*z*this.fov)/this.zoom)}getFilmWidth(){return this.filmGauge*Math.min(this.aspect,1)}getFilmHeight(){return this.filmGauge/Math.max(this.aspect,1)}setViewOffset(t,e,n,i,r,s){this.aspect=t/e,null===this.view&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=t,this.view.fullHeight=e,this.view.offsetX=n,this.view.offsetY=i,this.view.width=r,this.view.height=s,this.updateProjectionMatrix()}clearViewOffset(){null!==this.view&&(this.view.enabled=!1),this.updateProjectionMatrix()}updateProjectionMatrix(){const t=this.near;let e=t*Math.tan(.5*z*this.fov)/this.zoom,n=2*e,i=this.aspect*n,r=-.5*i;const s=this.view;if(null!==this.view&&this.view.enabled){const t=s.fullWidth,a=s.fullHeight;r+=s.offsetX*i/t,e-=s.offsetY*n/a,i*=s.width/t,n*=s.height/a}const a=this.filmOffset;0!==a&&(r+=t*a/this.getFilmWidth()),this.projectionMatrix.makePerspective(r,r+i,e,e-n,t,this.far),this.projectionMatrixInverse.copy(this.projectionMatrix).invert()}toJSON(t){const e=super.toJSON(t);return e.object.fov=this.fov,e.object.zoom=this.zoom,e.object.near=this.near,e.object.far=this.far,e.object.focus=this.focus,e.object.aspect=this.aspect,null!==this.view&&(e.object.view=Object.assign({},this.view)),e.object.filmGauge=this.filmGauge,e.object.filmOffset=this.filmOffset,e}}hn.prototype.isPerspectiveCamera=!0;const un=90;class dn extends ee{constructor(t,e,n){if(super(),this.type="CubeCamera",!0!==n.isWebGLCubeRenderTarget)return void console.error("THREE.CubeCamera: The constructor now expects an instance of WebGLCubeRenderTarget as third parameter.");this.renderTarget=n;const i=new hn(un,1,t,e);i.layers=this.layers,i.up.set(0,-1,0),i.lookAt(new $(1,0,0)),this.add(i);const r=new hn(un,1,t,e);r.layers=this.layers,r.up.set(0,-1,0),r.lookAt(new $(-1,0,0)),this.add(r);const s=new hn(un,1,t,e);s.layers=this.layers,s.up.set(0,0,1),s.lookAt(new $(0,1,0)),this.add(s);const a=new hn(un,1,t,e);a.layers=this.layers,a.up.set(0,0,-1),a.lookAt(new $(0,-1,0)),this.add(a);const o=new hn(un,1,t,e);o.layers=this.layers,o.up.set(0,-1,0),o.lookAt(new $(0,0,1)),this.add(o);const l=new hn(un,1,t,e);l.layers=this.layers,l.up.set(0,-1,0),l.lookAt(new $(0,0,-1)),this.add(l)}update(t,e){null===this.parent&&this.updateMatrixWorld();const n=this.renderTarget,[i,r,s,a,o,l]=this.children,c=t.xr.enabled,h=t.getRenderTarget();t.xr.enabled=!1;const u=n.texture.generateMipmaps;n.texture.generateMipmaps=!1,t.setRenderTarget(n,0),t.render(e,i),t.setRenderTarget(n,1),t.render(e,r),t.setRenderTarget(n,2),t.render(e,s),t.setRenderTarget(n,3),t.render(e,a),t.setRenderTarget(n,4),t.render(e,o),n.texture.generateMipmaps=u,t.setRenderTarget(n,5),t.render(e,l),t.setRenderTarget(h),t.xr.enabled=c}}class pn extends X{constructor(t,e,n,i,r,s,a,o,l,c){super(t=void 0!==t?t:[],e=void 0!==e?e:301,n,i,r,s,a=void 0!==a?a:g,o,l,c),this._needsFlipEnvMap=!0,this.flipY=!1}get images(){return this.image}set images(t){this.image=t}}pn.prototype.isCubeTexture=!0;class mn extends J{constructor(t,e,n){Number.isInteger(e)&&(console.warn("THREE.WebGLCubeRenderTarget: constructor signature is now WebGLCubeRenderTarget( size, options )"),e=n),super(t,t,e),e=e||{},this.texture=new pn(void 0,e.mapping,e.wrapS,e.wrapT,e.magFilter,e.minFilter,e.format,e.type,e.anisotropy,e.encoding),this.texture.generateMipmaps=void 0!==e.generateMipmaps&&e.generateMipmaps,this.texture.minFilter=void 0!==e.minFilter?e.minFilter:l,this.texture._needsFlipEnvMap=!1}fromEquirectangularTexture(t,e){this.texture.type=e.type,this.texture.format=v,this.texture.encoding=e.encoding,this.texture.generateMipmaps=e.generateMipmaps,this.texture.minFilter=e.minFilter,this.texture.magFilter=e.magFilter;const n={uniforms:{tEquirect:{value:null}},vertexShader:"\n\n\t\t\t\tvarying vec3 vWorldDirection;\n\n\t\t\t\tvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\n\t\t\t\t\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n\n\t\t\t\t}\n\n\t\t\t\tvoid main() {\n\n\t\t\t\t\tvWorldDirection = transformDirection( position, modelMatrix );\n\n\t\t\t\t\t#include \n\t\t\t\t\t#include \n\n\t\t\t\t}\n\t\t\t",fragmentShader:"\n\n\t\t\t\tuniform sampler2D tEquirect;\n\n\t\t\t\tvarying vec3 vWorldDirection;\n\n\t\t\t\t#include \n\n\t\t\t\tvoid main() {\n\n\t\t\t\t\tvec3 direction = normalize( vWorldDirection );\n\n\t\t\t\t\tvec2 sampleUV = equirectUv( direction );\n\n\t\t\t\t\tgl_FragColor = texture2D( tEquirect, sampleUV );\n\n\t\t\t\t}\n\t\t\t"},i=new rn(5,5,5),r=new ln({name:"CubemapFromEquirect",uniforms:sn(n.uniforms),vertexShader:n.vertexShader,fragmentShader:n.fragmentShader,side:1,blending:0});r.uniforms.tEquirect.value=e;const s=new en(i,r),a=e.minFilter;e.minFilter===c&&(e.minFilter=l);return new dn(1,10,this).update(t,s),e.minFilter=a,s.geometry.dispose(),s.material.dispose(),this}clear(t,e,n,i){const r=t.getRenderTarget();for(let r=0;r<6;r++)t.setRenderTarget(this,r),t.clear(e,n,i);t.setRenderTarget(r)}}mn.prototype.isWebGLCubeRenderTarget=!0;const fn=new $,gn=new $,vn=new V;class yn{constructor(t=new $(1,0,0),e=0){this.normal=t,this.constant=e}set(t,e){return this.normal.copy(t),this.constant=e,this}setComponents(t,e,n,i){return this.normal.set(t,e,n),this.constant=i,this}setFromNormalAndCoplanarPoint(t,e){return this.normal.copy(t),this.constant=-e.dot(this.normal),this}setFromCoplanarPoints(t,e,n){const i=fn.subVectors(n,e).cross(gn.subVectors(t,e)).normalize();return this.setFromNormalAndCoplanarPoint(i,t),this}copy(t){return this.normal.copy(t.normal),this.constant=t.constant,this}normalize(){const t=1/this.normal.length();return this.normal.multiplyScalar(t),this.constant*=t,this}negate(){return this.constant*=-1,this.normal.negate(),this}distanceToPoint(t){return this.normal.dot(t)+this.constant}distanceToSphere(t){return this.distanceToPoint(t.center)-t.radius}projectPoint(t,e){return e.copy(this.normal).multiplyScalar(-this.distanceToPoint(t)).add(t)}intersectLine(t,e){const n=t.delta(fn),i=this.normal.dot(n);if(0===i)return 0===this.distanceToPoint(t.start)?e.copy(t.start):null;const r=-(t.start.dot(this.normal)+this.constant)/i;return r<0||r>1?null:e.copy(n).multiplyScalar(r).add(t.start)}intersectsLine(t){const e=this.distanceToPoint(t.start),n=this.distanceToPoint(t.end);return e<0&&n>0||n<0&&e>0}intersectsBox(t){return t.intersectsPlane(this)}intersectsSphere(t){return t.intersectsPlane(this)}coplanarPoint(t){return t.copy(this.normal).multiplyScalar(-this.constant)}applyMatrix4(t,e){const n=e||vn.getNormalMatrix(t),i=this.coplanarPoint(fn).applyMatrix4(t),r=this.normal.applyMatrix3(n).normalize();return this.constant=-i.dot(r),this}translate(t){return this.constant-=t.dot(this.normal),this}equals(t){return t.normal.equals(this.normal)&&t.constant===this.constant}clone(){return(new this.constructor).copy(this)}}yn.prototype.isPlane=!0;const xn=new wt,_n=new $;class wn{constructor(t=new yn,e=new yn,n=new yn,i=new yn,r=new yn,s=new yn){this.planes=[t,e,n,i,r,s]}set(t,e,n,i,r,s){const a=this.planes;return a[0].copy(t),a[1].copy(e),a[2].copy(n),a[3].copy(i),a[4].copy(r),a[5].copy(s),this}copy(t){const e=this.planes;for(let n=0;n<6;n++)e[n].copy(t.planes[n]);return this}setFromProjectionMatrix(t){const e=this.planes,n=t.elements,i=n[0],r=n[1],s=n[2],a=n[3],o=n[4],l=n[5],c=n[6],h=n[7],u=n[8],d=n[9],p=n[10],m=n[11],f=n[12],g=n[13],v=n[14],y=n[15];return e[0].setComponents(a-i,h-o,m-u,y-f).normalize(),e[1].setComponents(a+i,h+o,m+u,y+f).normalize(),e[2].setComponents(a+r,h+l,m+d,y+g).normalize(),e[3].setComponents(a-r,h-l,m-d,y-g).normalize(),e[4].setComponents(a-s,h-c,m-p,y-v).normalize(),e[5].setComponents(a+s,h+c,m+p,y+v).normalize(),this}intersectsObject(t){const e=t.geometry;return null===e.boundingSphere&&e.computeBoundingSphere(),xn.copy(e.boundingSphere).applyMatrix4(t.matrixWorld),this.intersectsSphere(xn)}intersectsSprite(t){return xn.center.set(0,0,0),xn.radius=.7071067811865476,xn.applyMatrix4(t.matrixWorld),this.intersectsSphere(xn)}intersectsSphere(t){const e=this.planes,n=t.center,i=-t.radius;for(let t=0;t<6;t++){if(e[t].distanceToPoint(n)0?t.max.x:t.min.x,_n.y=i.normal.y>0?t.max.y:t.min.y,_n.z=i.normal.z>0?t.max.z:t.min.z,i.distanceToPoint(_n)<0)return!1}return!0}containsPoint(t){const e=this.planes;for(let n=0;n<6;n++)if(e[n].distanceToPoint(t)<0)return!1;return!0}clone(){return(new this.constructor).copy(this)}}function Mn(){let t=null,e=!1,n=null,i=null;function r(e,s){n(e,s),i=t.requestAnimationFrame(r)}return{start:function(){!0!==e&&null!==n&&(i=t.requestAnimationFrame(r),e=!0)},stop:function(){t.cancelAnimationFrame(i),e=!1},setAnimationLoop:function(t){n=t},setContext:function(e){t=e}}}function bn(t,e){const n=e.isWebGL2,i=new WeakMap;return{get:function(t){return t.isInterleavedBufferAttribute&&(t=t.data),i.get(t)},remove:function(e){e.isInterleavedBufferAttribute&&(e=e.data);const n=i.get(e);n&&(t.deleteBuffer(n.buffer),i.delete(e))},update:function(e,r){if(e.isGLBufferAttribute){const t=i.get(e);return void((!t||t.version 0.0 ) {\n\t\tdistanceFalloff *= pow2( saturate( 1.0 - pow4( lightDistance / cutoffDistance ) ) );\n\t}\n\treturn distanceFalloff;\n#else\n\tif( cutoffDistance > 0.0 && decayExponent > 0.0 ) {\n\t\treturn pow( saturate( -lightDistance / cutoffDistance + 1.0 ), decayExponent );\n\t}\n\treturn 1.0;\n#endif\n}\nvec3 BRDF_Diffuse_Lambert( const in vec3 diffuseColor ) {\n\treturn RECIPROCAL_PI * diffuseColor;\n}\nvec3 F_Schlick( const in vec3 specularColor, const in float dotVH ) {\n\tfloat fresnel = exp2( ( -5.55473 * dotVH - 6.98316 ) * dotVH );\n\treturn ( 1.0 - specularColor ) * fresnel + specularColor;\n}\nvec3 F_Schlick_RoughnessDependent( const in vec3 F0, const in float dotNV, const in float roughness ) {\n\tfloat fresnel = exp2( ( -5.55473 * dotNV - 6.98316 ) * dotNV );\n\tvec3 Fr = max( vec3( 1.0 - roughness ), F0 ) - F0;\n\treturn Fr * fresnel + F0;\n}\nfloat G_GGX_Smith( const in float alpha, const in float dotNL, const in float dotNV ) {\n\tfloat a2 = pow2( alpha );\n\tfloat gl = dotNL + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );\n\tfloat gv = dotNV + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );\n\treturn 1.0 / ( gl * gv );\n}\nfloat G_GGX_SmithCorrelated( const in float alpha, const in float dotNL, const in float dotNV ) {\n\tfloat a2 = pow2( alpha );\n\tfloat gv = dotNL * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );\n\tfloat gl = dotNV * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );\n\treturn 0.5 / max( gv + gl, EPSILON );\n}\nfloat D_GGX( const in float alpha, const in float dotNH ) {\n\tfloat a2 = pow2( alpha );\n\tfloat denom = pow2( dotNH ) * ( a2 - 1.0 ) + 1.0;\n\treturn RECIPROCAL_PI * a2 / pow2( denom );\n}\nvec3 BRDF_Specular_GGX( const in IncidentLight incidentLight, const in vec3 viewDir, const in vec3 normal, const in vec3 specularColor, const in float roughness ) {\n\tfloat alpha = pow2( roughness );\n\tvec3 halfDir = normalize( incidentLight.direction + viewDir );\n\tfloat dotNL = saturate( dot( normal, incidentLight.direction ) );\n\tfloat dotNV = saturate( dot( normal, viewDir ) );\n\tfloat dotNH = saturate( dot( normal, halfDir ) );\n\tfloat dotLH = saturate( dot( incidentLight.direction, halfDir ) );\n\tvec3 F = F_Schlick( specularColor, dotLH );\n\tfloat G = G_GGX_SmithCorrelated( alpha, dotNL, dotNV );\n\tfloat D = D_GGX( alpha, dotNH );\n\treturn F * ( G * D );\n}\nvec2 LTC_Uv( const in vec3 N, const in vec3 V, const in float roughness ) {\n\tconst float LUT_SIZE = 64.0;\n\tconst float LUT_SCALE = ( LUT_SIZE - 1.0 ) / LUT_SIZE;\n\tconst float LUT_BIAS = 0.5 / LUT_SIZE;\n\tfloat dotNV = saturate( dot( N, V ) );\n\tvec2 uv = vec2( roughness, sqrt( 1.0 - dotNV ) );\n\tuv = uv * LUT_SCALE + LUT_BIAS;\n\treturn uv;\n}\nfloat LTC_ClippedSphereFormFactor( const in vec3 f ) {\n\tfloat l = length( f );\n\treturn max( ( l * l + f.z ) / ( l + 1.0 ), 0.0 );\n}\nvec3 LTC_EdgeVectorFormFactor( const in vec3 v1, const in vec3 v2 ) {\n\tfloat x = dot( v1, v2 );\n\tfloat y = abs( x );\n\tfloat a = 0.8543985 + ( 0.4965155 + 0.0145206 * y ) * y;\n\tfloat b = 3.4175940 + ( 4.1616724 + y ) * y;\n\tfloat v = a / b;\n\tfloat theta_sintheta = ( x > 0.0 ) ? v : 0.5 * inversesqrt( max( 1.0 - x * x, 1e-7 ) ) - v;\n\treturn cross( v1, v2 ) * theta_sintheta;\n}\nvec3 LTC_Evaluate( const in vec3 N, const in vec3 V, const in vec3 P, const in mat3 mInv, const in vec3 rectCoords[ 4 ] ) {\n\tvec3 v1 = rectCoords[ 1 ] - rectCoords[ 0 ];\n\tvec3 v2 = rectCoords[ 3 ] - rectCoords[ 0 ];\n\tvec3 lightNormal = cross( v1, v2 );\n\tif( dot( lightNormal, P - rectCoords[ 0 ] ) < 0.0 ) return vec3( 0.0 );\n\tvec3 T1, T2;\n\tT1 = normalize( V - N * dot( V, N ) );\n\tT2 = - cross( N, T1 );\n\tmat3 mat = mInv * transposeMat3( mat3( T1, T2, N ) );\n\tvec3 coords[ 4 ];\n\tcoords[ 0 ] = mat * ( rectCoords[ 0 ] - P );\n\tcoords[ 1 ] = mat * ( rectCoords[ 1 ] - P );\n\tcoords[ 2 ] = mat * ( rectCoords[ 2 ] - P );\n\tcoords[ 3 ] = mat * ( rectCoords[ 3 ] - P );\n\tcoords[ 0 ] = normalize( coords[ 0 ] );\n\tcoords[ 1 ] = normalize( coords[ 1 ] );\n\tcoords[ 2 ] = normalize( coords[ 2 ] );\n\tcoords[ 3 ] = normalize( coords[ 3 ] );\n\tvec3 vectorFormFactor = vec3( 0.0 );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 0 ], coords[ 1 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 1 ], coords[ 2 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 2 ], coords[ 3 ] );\n\tvectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 3 ], coords[ 0 ] );\n\tfloat result = LTC_ClippedSphereFormFactor( vectorFormFactor );\n\treturn vec3( result );\n}\nvec3 BRDF_Specular_GGX_Environment( const in vec3 viewDir, const in vec3 normal, const in vec3 specularColor, const in float roughness ) {\n\tfloat dotNV = saturate( dot( normal, viewDir ) );\n\tvec2 brdf = integrateSpecularBRDF( dotNV, roughness );\n\treturn specularColor * brdf.x + brdf.y;\n}\nvoid BRDF_Specular_Multiscattering_Environment( const in GeometricContext geometry, const in vec3 specularColor, const in float roughness, inout vec3 singleScatter, inout vec3 multiScatter ) {\n\tfloat dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );\n\tvec3 F = F_Schlick_RoughnessDependent( specularColor, dotNV, roughness );\n\tvec2 brdf = integrateSpecularBRDF( dotNV, roughness );\n\tvec3 FssEss = F * brdf.x + brdf.y;\n\tfloat Ess = brdf.x + brdf.y;\n\tfloat Ems = 1.0 - Ess;\n\tvec3 Favg = specularColor + ( 1.0 - specularColor ) * 0.047619;\tvec3 Fms = FssEss * Favg / ( 1.0 - Ems * Favg );\n\tsingleScatter += FssEss;\n\tmultiScatter += Fms * Ems;\n}\nfloat G_BlinnPhong_Implicit( ) {\n\treturn 0.25;\n}\nfloat D_BlinnPhong( const in float shininess, const in float dotNH ) {\n\treturn RECIPROCAL_PI * ( shininess * 0.5 + 1.0 ) * pow( dotNH, shininess );\n}\nvec3 BRDF_Specular_BlinnPhong( const in IncidentLight incidentLight, const in GeometricContext geometry, const in vec3 specularColor, const in float shininess ) {\n\tvec3 halfDir = normalize( incidentLight.direction + geometry.viewDir );\n\tfloat dotNH = saturate( dot( geometry.normal, halfDir ) );\n\tfloat dotLH = saturate( dot( incidentLight.direction, halfDir ) );\n\tvec3 F = F_Schlick( specularColor, dotLH );\n\tfloat G = G_BlinnPhong_Implicit( );\n\tfloat D = D_BlinnPhong( shininess, dotNH );\n\treturn F * ( G * D );\n}\nfloat GGXRoughnessToBlinnExponent( const in float ggxRoughness ) {\n\treturn ( 2.0 / pow2( ggxRoughness + 0.0001 ) - 2.0 );\n}\nfloat BlinnExponentToGGXRoughness( const in float blinnExponent ) {\n\treturn sqrt( 2.0 / ( blinnExponent + 2.0 ) );\n}\n#if defined( USE_SHEEN )\nfloat D_Charlie(float roughness, float NoH) {\n\tfloat invAlpha = 1.0 / roughness;\n\tfloat cos2h = NoH * NoH;\n\tfloat sin2h = max(1.0 - cos2h, 0.0078125);\treturn (2.0 + invAlpha) * pow(sin2h, invAlpha * 0.5) / (2.0 * PI);\n}\nfloat V_Neubelt(float NoV, float NoL) {\n\treturn saturate(1.0 / (4.0 * (NoL + NoV - NoL * NoV)));\n}\nvec3 BRDF_Specular_Sheen( const in float roughness, const in vec3 L, const in GeometricContext geometry, vec3 specularColor ) {\n\tvec3 N = geometry.normal;\n\tvec3 V = geometry.viewDir;\n\tvec3 H = normalize( V + L );\n\tfloat dotNH = saturate( dot( N, H ) );\n\treturn specularColor * D_Charlie( roughness, dotNH ) * V_Neubelt( dot(N, V), dot(N, L) );\n}\n#endif",bumpmap_pars_fragment:"#ifdef USE_BUMPMAP\n\tuniform sampler2D bumpMap;\n\tuniform float bumpScale;\n\tvec2 dHdxy_fwd() {\n\t\tvec2 dSTdx = dFdx( vUv );\n\t\tvec2 dSTdy = dFdy( vUv );\n\t\tfloat Hll = bumpScale * texture2D( bumpMap, vUv ).x;\n\t\tfloat dBx = bumpScale * texture2D( bumpMap, vUv + dSTdx ).x - Hll;\n\t\tfloat dBy = bumpScale * texture2D( bumpMap, vUv + dSTdy ).x - Hll;\n\t\treturn vec2( dBx, dBy );\n\t}\n\tvec3 perturbNormalArb( vec3 surf_pos, vec3 surf_norm, vec2 dHdxy, float faceDirection ) {\n\t\tvec3 vSigmaX = vec3( dFdx( surf_pos.x ), dFdx( surf_pos.y ), dFdx( surf_pos.z ) );\n\t\tvec3 vSigmaY = vec3( dFdy( surf_pos.x ), dFdy( surf_pos.y ), dFdy( surf_pos.z ) );\n\t\tvec3 vN = surf_norm;\n\t\tvec3 R1 = cross( vSigmaY, vN );\n\t\tvec3 R2 = cross( vN, vSigmaX );\n\t\tfloat fDet = dot( vSigmaX, R1 ) * faceDirection;\n\t\tvec3 vGrad = sign( fDet ) * ( dHdxy.x * R1 + dHdxy.y * R2 );\n\t\treturn normalize( abs( fDet ) * surf_norm - vGrad );\n\t}\n#endif",clipping_planes_fragment:"#if NUM_CLIPPING_PLANES > 0\n\tvec4 plane;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < UNION_CLIPPING_PLANES; i ++ ) {\n\t\tplane = clippingPlanes[ i ];\n\t\tif ( dot( vClipPosition, plane.xyz ) > plane.w ) discard;\n\t}\n\t#pragma unroll_loop_end\n\t#if UNION_CLIPPING_PLANES < NUM_CLIPPING_PLANES\n\t\tbool clipped = true;\n\t\t#pragma unroll_loop_start\n\t\tfor ( int i = UNION_CLIPPING_PLANES; i < NUM_CLIPPING_PLANES; i ++ ) {\n\t\t\tplane = clippingPlanes[ i ];\n\t\t\tclipped = ( dot( vClipPosition, plane.xyz ) > plane.w ) && clipped;\n\t\t}\n\t\t#pragma unroll_loop_end\n\t\tif ( clipped ) discard;\n\t#endif\n#endif",clipping_planes_pars_fragment:"#if NUM_CLIPPING_PLANES > 0\n\tvarying vec3 vClipPosition;\n\tuniform vec4 clippingPlanes[ NUM_CLIPPING_PLANES ];\n#endif",clipping_planes_pars_vertex:"#if NUM_CLIPPING_PLANES > 0\n\tvarying vec3 vClipPosition;\n#endif",clipping_planes_vertex:"#if NUM_CLIPPING_PLANES > 0\n\tvClipPosition = - mvPosition.xyz;\n#endif",color_fragment:"#if defined( USE_COLOR_ALPHA )\n\tdiffuseColor *= vColor;\n#elif defined( USE_COLOR )\n\tdiffuseColor.rgb *= vColor;\n#endif",color_pars_fragment:"#if defined( USE_COLOR_ALPHA )\n\tvarying vec4 vColor;\n#elif defined( USE_COLOR )\n\tvarying vec3 vColor;\n#endif",color_pars_vertex:"#if defined( USE_COLOR_ALPHA )\n\tvarying vec4 vColor;\n#elif defined( USE_COLOR ) || defined( USE_INSTANCING_COLOR )\n\tvarying vec3 vColor;\n#endif",color_vertex:"#if defined( USE_COLOR_ALPHA )\n\tvColor = vec4( 1.0 );\n#elif defined( USE_COLOR ) || defined( USE_INSTANCING_COLOR )\n\tvColor = vec3( 1.0 );\n#endif\n#ifdef USE_COLOR\n\tvColor *= color;\n#endif\n#ifdef USE_INSTANCING_COLOR\n\tvColor.xyz *= instanceColor.xyz;\n#endif",common:"#define PI 3.141592653589793\n#define PI2 6.283185307179586\n#define PI_HALF 1.5707963267948966\n#define RECIPROCAL_PI 0.3183098861837907\n#define RECIPROCAL_PI2 0.15915494309189535\n#define EPSILON 1e-6\n#ifndef saturate\n#define saturate(a) clamp( a, 0.0, 1.0 )\n#endif\n#define whiteComplement(a) ( 1.0 - saturate( a ) )\nfloat pow2( const in float x ) { return x*x; }\nfloat pow3( const in float x ) { return x*x*x; }\nfloat pow4( const in float x ) { float x2 = x*x; return x2*x2; }\nfloat average( const in vec3 color ) { return dot( color, vec3( 0.3333 ) ); }\nhighp float rand( const in vec2 uv ) {\n\tconst highp float a = 12.9898, b = 78.233, c = 43758.5453;\n\thighp float dt = dot( uv.xy, vec2( a,b ) ), sn = mod( dt, PI );\n\treturn fract(sin(sn) * c);\n}\n#ifdef HIGH_PRECISION\n\tfloat precisionSafeLength( vec3 v ) { return length( v ); }\n#else\n\tfloat max3( vec3 v ) { return max( max( v.x, v.y ), v.z ); }\n\tfloat precisionSafeLength( vec3 v ) {\n\t\tfloat maxComponent = max3( abs( v ) );\n\t\treturn length( v / maxComponent ) * maxComponent;\n\t}\n#endif\nstruct IncidentLight {\n\tvec3 color;\n\tvec3 direction;\n\tbool visible;\n};\nstruct ReflectedLight {\n\tvec3 directDiffuse;\n\tvec3 directSpecular;\n\tvec3 indirectDiffuse;\n\tvec3 indirectSpecular;\n};\nstruct GeometricContext {\n\tvec3 position;\n\tvec3 normal;\n\tvec3 viewDir;\n#ifdef CLEARCOAT\n\tvec3 clearcoatNormal;\n#endif\n};\nvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n}\nvec3 inverseTransformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( vec4( dir, 0.0 ) * matrix ).xyz );\n}\nvec3 projectOnPlane(in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\tfloat distance = dot( planeNormal, point - pointOnPlane );\n\treturn - distance * planeNormal + point;\n}\nfloat sideOfPlane( in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\treturn sign( dot( point - pointOnPlane, planeNormal ) );\n}\nvec3 linePlaneIntersect( in vec3 pointOnLine, in vec3 lineDirection, in vec3 pointOnPlane, in vec3 planeNormal ) {\n\treturn lineDirection * ( dot( planeNormal, pointOnPlane - pointOnLine ) / dot( planeNormal, lineDirection ) ) + pointOnLine;\n}\nmat3 transposeMat3( const in mat3 m ) {\n\tmat3 tmp;\n\ttmp[ 0 ] = vec3( m[ 0 ].x, m[ 1 ].x, m[ 2 ].x );\n\ttmp[ 1 ] = vec3( m[ 0 ].y, m[ 1 ].y, m[ 2 ].y );\n\ttmp[ 2 ] = vec3( m[ 0 ].z, m[ 1 ].z, m[ 2 ].z );\n\treturn tmp;\n}\nfloat linearToRelativeLuminance( const in vec3 color ) {\n\tvec3 weights = vec3( 0.2126, 0.7152, 0.0722 );\n\treturn dot( weights, color.rgb );\n}\nbool isPerspectiveMatrix( mat4 m ) {\n\treturn m[ 2 ][ 3 ] == - 1.0;\n}\nvec2 equirectUv( in vec3 dir ) {\n\tfloat u = atan( dir.z, dir.x ) * RECIPROCAL_PI2 + 0.5;\n\tfloat v = asin( clamp( dir.y, - 1.0, 1.0 ) ) * RECIPROCAL_PI + 0.5;\n\treturn vec2( u, v );\n}",cube_uv_reflection_fragment:"#ifdef ENVMAP_TYPE_CUBE_UV\n\t#define cubeUV_maxMipLevel 8.0\n\t#define cubeUV_minMipLevel 4.0\n\t#define cubeUV_maxTileSize 256.0\n\t#define cubeUV_minTileSize 16.0\n\tfloat getFace( vec3 direction ) {\n\t\tvec3 absDirection = abs( direction );\n\t\tfloat face = - 1.0;\n\t\tif ( absDirection.x > absDirection.z ) {\n\t\t\tif ( absDirection.x > absDirection.y )\n\t\t\t\tface = direction.x > 0.0 ? 0.0 : 3.0;\n\t\t\telse\n\t\t\t\tface = direction.y > 0.0 ? 1.0 : 4.0;\n\t\t} else {\n\t\t\tif ( absDirection.z > absDirection.y )\n\t\t\t\tface = direction.z > 0.0 ? 2.0 : 5.0;\n\t\t\telse\n\t\t\t\tface = direction.y > 0.0 ? 1.0 : 4.0;\n\t\t}\n\t\treturn face;\n\t}\n\tvec2 getUV( vec3 direction, float face ) {\n\t\tvec2 uv;\n\t\tif ( face == 0.0 ) {\n\t\t\tuv = vec2( direction.z, direction.y ) / abs( direction.x );\n\t\t} else if ( face == 1.0 ) {\n\t\t\tuv = vec2( - direction.x, - direction.z ) / abs( direction.y );\n\t\t} else if ( face == 2.0 ) {\n\t\t\tuv = vec2( - direction.x, direction.y ) / abs( direction.z );\n\t\t} else if ( face == 3.0 ) {\n\t\t\tuv = vec2( - direction.z, direction.y ) / abs( direction.x );\n\t\t} else if ( face == 4.0 ) {\n\t\t\tuv = vec2( - direction.x, direction.z ) / abs( direction.y );\n\t\t} else {\n\t\t\tuv = vec2( direction.x, direction.y ) / abs( direction.z );\n\t\t}\n\t\treturn 0.5 * ( uv + 1.0 );\n\t}\n\tvec3 bilinearCubeUV( sampler2D envMap, vec3 direction, float mipInt ) {\n\t\tfloat face = getFace( direction );\n\t\tfloat filterInt = max( cubeUV_minMipLevel - mipInt, 0.0 );\n\t\tmipInt = max( mipInt, cubeUV_minMipLevel );\n\t\tfloat faceSize = exp2( mipInt );\n\t\tfloat texelSize = 1.0 / ( 3.0 * cubeUV_maxTileSize );\n\t\tvec2 uv = getUV( direction, face ) * ( faceSize - 1.0 );\n\t\tvec2 f = fract( uv );\n\t\tuv += 0.5 - f;\n\t\tif ( face > 2.0 ) {\n\t\t\tuv.y += faceSize;\n\t\t\tface -= 3.0;\n\t\t}\n\t\tuv.x += face * faceSize;\n\t\tif ( mipInt < cubeUV_maxMipLevel ) {\n\t\t\tuv.y += 2.0 * cubeUV_maxTileSize;\n\t\t}\n\t\tuv.y += filterInt * 2.0 * cubeUV_minTileSize;\n\t\tuv.x += 3.0 * max( 0.0, cubeUV_maxTileSize - 2.0 * faceSize );\n\t\tuv *= texelSize;\n\t\tvec3 tl = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tuv.x += texelSize;\n\t\tvec3 tr = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tuv.y += texelSize;\n\t\tvec3 br = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tuv.x -= texelSize;\n\t\tvec3 bl = envMapTexelToLinear( texture2D( envMap, uv ) ).rgb;\n\t\tvec3 tm = mix( tl, tr, f.x );\n\t\tvec3 bm = mix( bl, br, f.x );\n\t\treturn mix( tm, bm, f.y );\n\t}\n\t#define r0 1.0\n\t#define v0 0.339\n\t#define m0 - 2.0\n\t#define r1 0.8\n\t#define v1 0.276\n\t#define m1 - 1.0\n\t#define r4 0.4\n\t#define v4 0.046\n\t#define m4 2.0\n\t#define r5 0.305\n\t#define v5 0.016\n\t#define m5 3.0\n\t#define r6 0.21\n\t#define v6 0.0038\n\t#define m6 4.0\n\tfloat roughnessToMip( float roughness ) {\n\t\tfloat mip = 0.0;\n\t\tif ( roughness >= r1 ) {\n\t\t\tmip = ( r0 - roughness ) * ( m1 - m0 ) / ( r0 - r1 ) + m0;\n\t\t} else if ( roughness >= r4 ) {\n\t\t\tmip = ( r1 - roughness ) * ( m4 - m1 ) / ( r1 - r4 ) + m1;\n\t\t} else if ( roughness >= r5 ) {\n\t\t\tmip = ( r4 - roughness ) * ( m5 - m4 ) / ( r4 - r5 ) + m4;\n\t\t} else if ( roughness >= r6 ) {\n\t\t\tmip = ( r5 - roughness ) * ( m6 - m5 ) / ( r5 - r6 ) + m5;\n\t\t} else {\n\t\t\tmip = - 2.0 * log2( 1.16 * roughness );\t\t}\n\t\treturn mip;\n\t}\n\tvec4 textureCubeUV( sampler2D envMap, vec3 sampleDir, float roughness ) {\n\t\tfloat mip = clamp( roughnessToMip( roughness ), m0, cubeUV_maxMipLevel );\n\t\tfloat mipF = fract( mip );\n\t\tfloat mipInt = floor( mip );\n\t\tvec3 color0 = bilinearCubeUV( envMap, sampleDir, mipInt );\n\t\tif ( mipF == 0.0 ) {\n\t\t\treturn vec4( color0, 1.0 );\n\t\t} else {\n\t\t\tvec3 color1 = bilinearCubeUV( envMap, sampleDir, mipInt + 1.0 );\n\t\t\treturn vec4( mix( color0, color1, mipF ), 1.0 );\n\t\t}\n\t}\n#endif",defaultnormal_vertex:"vec3 transformedNormal = objectNormal;\n#ifdef USE_INSTANCING\n\tmat3 m = mat3( instanceMatrix );\n\ttransformedNormal /= vec3( dot( m[ 0 ], m[ 0 ] ), dot( m[ 1 ], m[ 1 ] ), dot( m[ 2 ], m[ 2 ] ) );\n\ttransformedNormal = m * transformedNormal;\n#endif\ntransformedNormal = normalMatrix * transformedNormal;\n#ifdef FLIP_SIDED\n\ttransformedNormal = - transformedNormal;\n#endif\n#ifdef USE_TANGENT\n\tvec3 transformedTangent = ( modelViewMatrix * vec4( objectTangent, 0.0 ) ).xyz;\n\t#ifdef FLIP_SIDED\n\t\ttransformedTangent = - transformedTangent;\n\t#endif\n#endif",displacementmap_pars_vertex:"#ifdef USE_DISPLACEMENTMAP\n\tuniform sampler2D displacementMap;\n\tuniform float displacementScale;\n\tuniform float displacementBias;\n#endif",displacementmap_vertex:"#ifdef USE_DISPLACEMENTMAP\n\ttransformed += normalize( objectNormal ) * ( texture2D( displacementMap, vUv ).x * displacementScale + displacementBias );\n#endif",emissivemap_fragment:"#ifdef USE_EMISSIVEMAP\n\tvec4 emissiveColor = texture2D( emissiveMap, vUv );\n\temissiveColor.rgb = emissiveMapTexelToLinear( emissiveColor ).rgb;\n\ttotalEmissiveRadiance *= emissiveColor.rgb;\n#endif",emissivemap_pars_fragment:"#ifdef USE_EMISSIVEMAP\n\tuniform sampler2D emissiveMap;\n#endif",encodings_fragment:"gl_FragColor = linearToOutputTexel( gl_FragColor );",encodings_pars_fragment:"\nvec4 LinearToLinear( in vec4 value ) {\n\treturn value;\n}\nvec4 GammaToLinear( in vec4 value, in float gammaFactor ) {\n\treturn vec4( pow( value.rgb, vec3( gammaFactor ) ), value.a );\n}\nvec4 LinearToGamma( in vec4 value, in float gammaFactor ) {\n\treturn vec4( pow( value.rgb, vec3( 1.0 / gammaFactor ) ), value.a );\n}\nvec4 sRGBToLinear( in vec4 value ) {\n\treturn vec4( mix( pow( value.rgb * 0.9478672986 + vec3( 0.0521327014 ), vec3( 2.4 ) ), value.rgb * 0.0773993808, vec3( lessThanEqual( value.rgb, vec3( 0.04045 ) ) ) ), value.a );\n}\nvec4 LinearTosRGB( in vec4 value ) {\n\treturn vec4( mix( pow( value.rgb, vec3( 0.41666 ) ) * 1.055 - vec3( 0.055 ), value.rgb * 12.92, vec3( lessThanEqual( value.rgb, vec3( 0.0031308 ) ) ) ), value.a );\n}\nvec4 RGBEToLinear( in vec4 value ) {\n\treturn vec4( value.rgb * exp2( value.a * 255.0 - 128.0 ), 1.0 );\n}\nvec4 LinearToRGBE( in vec4 value ) {\n\tfloat maxComponent = max( max( value.r, value.g ), value.b );\n\tfloat fExp = clamp( ceil( log2( maxComponent ) ), -128.0, 127.0 );\n\treturn vec4( value.rgb / exp2( fExp ), ( fExp + 128.0 ) / 255.0 );\n}\nvec4 RGBMToLinear( in vec4 value, in float maxRange ) {\n\treturn vec4( value.rgb * value.a * maxRange, 1.0 );\n}\nvec4 LinearToRGBM( in vec4 value, in float maxRange ) {\n\tfloat maxRGB = max( value.r, max( value.g, value.b ) );\n\tfloat M = clamp( maxRGB / maxRange, 0.0, 1.0 );\n\tM = ceil( M * 255.0 ) / 255.0;\n\treturn vec4( value.rgb / ( M * maxRange ), M );\n}\nvec4 RGBDToLinear( in vec4 value, in float maxRange ) {\n\treturn vec4( value.rgb * ( ( maxRange / 255.0 ) / value.a ), 1.0 );\n}\nvec4 LinearToRGBD( in vec4 value, in float maxRange ) {\n\tfloat maxRGB = max( value.r, max( value.g, value.b ) );\n\tfloat D = max( maxRange / maxRGB, 1.0 );\n\tD = clamp( floor( D ) / 255.0, 0.0, 1.0 );\n\treturn vec4( value.rgb * ( D * ( 255.0 / maxRange ) ), D );\n}\nconst mat3 cLogLuvM = mat3( 0.2209, 0.3390, 0.4184, 0.1138, 0.6780, 0.7319, 0.0102, 0.1130, 0.2969 );\nvec4 LinearToLogLuv( in vec4 value ) {\n\tvec3 Xp_Y_XYZp = cLogLuvM * value.rgb;\n\tXp_Y_XYZp = max( Xp_Y_XYZp, vec3( 1e-6, 1e-6, 1e-6 ) );\n\tvec4 vResult;\n\tvResult.xy = Xp_Y_XYZp.xy / Xp_Y_XYZp.z;\n\tfloat Le = 2.0 * log2(Xp_Y_XYZp.y) + 127.0;\n\tvResult.w = fract( Le );\n\tvResult.z = ( Le - ( floor( vResult.w * 255.0 ) ) / 255.0 ) / 255.0;\n\treturn vResult;\n}\nconst mat3 cLogLuvInverseM = mat3( 6.0014, -2.7008, -1.7996, -1.3320, 3.1029, -5.7721, 0.3008, -1.0882, 5.6268 );\nvec4 LogLuvToLinear( in vec4 value ) {\n\tfloat Le = value.z * 255.0 + value.w;\n\tvec3 Xp_Y_XYZp;\n\tXp_Y_XYZp.y = exp2( ( Le - 127.0 ) / 2.0 );\n\tXp_Y_XYZp.z = Xp_Y_XYZp.y / value.y;\n\tXp_Y_XYZp.x = value.x * Xp_Y_XYZp.z;\n\tvec3 vRGB = cLogLuvInverseM * Xp_Y_XYZp.rgb;\n\treturn vec4( max( vRGB, 0.0 ), 1.0 );\n}",envmap_fragment:"#ifdef USE_ENVMAP\n\t#ifdef ENV_WORLDPOS\n\t\tvec3 cameraToFrag;\n\t\tif ( isOrthographic ) {\n\t\t\tcameraToFrag = normalize( vec3( - viewMatrix[ 0 ][ 2 ], - viewMatrix[ 1 ][ 2 ], - viewMatrix[ 2 ][ 2 ] ) );\n\t\t} else {\n\t\t\tcameraToFrag = normalize( vWorldPosition - cameraPosition );\n\t\t}\n\t\tvec3 worldNormal = inverseTransformDirection( normal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvec3 reflectVec = reflect( cameraToFrag, worldNormal );\n\t\t#else\n\t\t\tvec3 reflectVec = refract( cameraToFrag, worldNormal, refractionRatio );\n\t\t#endif\n\t#else\n\t\tvec3 reflectVec = vReflect;\n\t#endif\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tvec4 envColor = textureCube( envMap, vec3( flipEnvMap * reflectVec.x, reflectVec.yz ) );\n\t#elif defined( ENVMAP_TYPE_CUBE_UV )\n\t\tvec4 envColor = textureCubeUV( envMap, reflectVec, 0.0 );\n\t#else\n\t\tvec4 envColor = vec4( 0.0 );\n\t#endif\n\t#ifndef ENVMAP_TYPE_CUBE_UV\n\t\tenvColor = envMapTexelToLinear( envColor );\n\t#endif\n\t#ifdef ENVMAP_BLENDING_MULTIPLY\n\t\toutgoingLight = mix( outgoingLight, outgoingLight * envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_MIX )\n\t\toutgoingLight = mix( outgoingLight, envColor.xyz, specularStrength * reflectivity );\n\t#elif defined( ENVMAP_BLENDING_ADD )\n\t\toutgoingLight += envColor.xyz * specularStrength * reflectivity;\n\t#endif\n#endif",envmap_common_pars_fragment:"#ifdef USE_ENVMAP\n\tuniform float envMapIntensity;\n\tuniform float flipEnvMap;\n\tuniform int maxMipLevel;\n\t#ifdef ENVMAP_TYPE_CUBE\n\t\tuniform samplerCube envMap;\n\t#else\n\t\tuniform sampler2D envMap;\n\t#endif\n\t\n#endif",envmap_pars_fragment:"#ifdef USE_ENVMAP\n\tuniform float reflectivity;\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )\n\t\t#define ENV_WORLDPOS\n\t#endif\n\t#ifdef ENV_WORLDPOS\n\t\tvarying vec3 vWorldPosition;\n\t\tuniform float refractionRatio;\n\t#else\n\t\tvarying vec3 vReflect;\n\t#endif\n#endif",envmap_pars_vertex:"#ifdef USE_ENVMAP\n\t#if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) ||defined( PHONG )\n\t\t#define ENV_WORLDPOS\n\t#endif\n\t#ifdef ENV_WORLDPOS\n\t\t\n\t\tvarying vec3 vWorldPosition;\n\t#else\n\t\tvarying vec3 vReflect;\n\t\tuniform float refractionRatio;\n\t#endif\n#endif",envmap_physical_pars_fragment:"#if defined( USE_ENVMAP )\n\t#ifdef ENVMAP_MODE_REFRACTION\n\t\tuniform float refractionRatio;\n\t#endif\n\tvec3 getLightProbeIndirectIrradiance( const in GeometricContext geometry, const in int maxMIPLevel ) {\n\t\tvec3 worldNormal = inverseTransformDirection( geometry.normal, viewMatrix );\n\t\t#ifdef ENVMAP_TYPE_CUBE\n\t\t\tvec3 queryVec = vec3( flipEnvMap * worldNormal.x, worldNormal.yz );\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = textureCubeLodEXT( envMap, queryVec, float( maxMIPLevel ) );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = textureCube( envMap, queryVec, float( maxMIPLevel ) );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#elif defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec4 envMapColor = textureCubeUV( envMap, worldNormal, 1.0 );\n\t\t#else\n\t\t\tvec4 envMapColor = vec4( 0.0 );\n\t\t#endif\n\t\treturn PI * envMapColor.rgb * envMapIntensity;\n\t}\n\tfloat getSpecularMIPLevel( const in float roughness, const in int maxMIPLevel ) {\n\t\tfloat maxMIPLevelScalar = float( maxMIPLevel );\n\t\tfloat sigma = PI * roughness * roughness / ( 1.0 + roughness );\n\t\tfloat desiredMIPLevel = maxMIPLevelScalar + log2( sigma );\n\t\treturn clamp( desiredMIPLevel, 0.0, maxMIPLevelScalar );\n\t}\n\tvec3 getLightProbeIndirectRadiance( const in vec3 viewDir, const in vec3 normal, const in float roughness, const in int maxMIPLevel ) {\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvec3 reflectVec = reflect( -viewDir, normal );\n\t\t\treflectVec = normalize( mix( reflectVec, normal, roughness * roughness) );\n\t\t#else\n\t\t\tvec3 reflectVec = refract( -viewDir, normal, refractionRatio );\n\t\t#endif\n\t\treflectVec = inverseTransformDirection( reflectVec, viewMatrix );\n\t\tfloat specularMIPLevel = getSpecularMIPLevel( roughness, maxMIPLevel );\n\t\t#ifdef ENVMAP_TYPE_CUBE\n\t\t\tvec3 queryReflectVec = vec3( flipEnvMap * reflectVec.x, reflectVec.yz );\n\t\t\t#ifdef TEXTURE_LOD_EXT\n\t\t\t\tvec4 envMapColor = textureCubeLodEXT( envMap, queryReflectVec, specularMIPLevel );\n\t\t\t#else\n\t\t\t\tvec4 envMapColor = textureCube( envMap, queryReflectVec, specularMIPLevel );\n\t\t\t#endif\n\t\t\tenvMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;\n\t\t#elif defined( ENVMAP_TYPE_CUBE_UV )\n\t\t\tvec4 envMapColor = textureCubeUV( envMap, reflectVec, roughness );\n\t\t#endif\n\t\treturn envMapColor.rgb * envMapIntensity;\n\t}\n#endif",envmap_vertex:"#ifdef USE_ENVMAP\n\t#ifdef ENV_WORLDPOS\n\t\tvWorldPosition = worldPosition.xyz;\n\t#else\n\t\tvec3 cameraToVertex;\n\t\tif ( isOrthographic ) {\n\t\t\tcameraToVertex = normalize( vec3( - viewMatrix[ 0 ][ 2 ], - viewMatrix[ 1 ][ 2 ], - viewMatrix[ 2 ][ 2 ] ) );\n\t\t} else {\n\t\t\tcameraToVertex = normalize( worldPosition.xyz - cameraPosition );\n\t\t}\n\t\tvec3 worldNormal = inverseTransformDirection( transformedNormal, viewMatrix );\n\t\t#ifdef ENVMAP_MODE_REFLECTION\n\t\t\tvReflect = reflect( cameraToVertex, worldNormal );\n\t\t#else\n\t\t\tvReflect = refract( cameraToVertex, worldNormal, refractionRatio );\n\t\t#endif\n\t#endif\n#endif",fog_vertex:"#ifdef USE_FOG\n\tfogDepth = - mvPosition.z;\n#endif",fog_pars_vertex:"#ifdef USE_FOG\n\tvarying float fogDepth;\n#endif",fog_fragment:"#ifdef USE_FOG\n\t#ifdef FOG_EXP2\n\t\tfloat fogFactor = 1.0 - exp( - fogDensity * fogDensity * fogDepth * fogDepth );\n\t#else\n\t\tfloat fogFactor = smoothstep( fogNear, fogFar, fogDepth );\n\t#endif\n\tgl_FragColor.rgb = mix( gl_FragColor.rgb, fogColor, fogFactor );\n#endif",fog_pars_fragment:"#ifdef USE_FOG\n\tuniform vec3 fogColor;\n\tvarying float fogDepth;\n\t#ifdef FOG_EXP2\n\t\tuniform float fogDensity;\n\t#else\n\t\tuniform float fogNear;\n\t\tuniform float fogFar;\n\t#endif\n#endif",gradientmap_pars_fragment:"#ifdef USE_GRADIENTMAP\n\tuniform sampler2D gradientMap;\n#endif\nvec3 getGradientIrradiance( vec3 normal, vec3 lightDirection ) {\n\tfloat dotNL = dot( normal, lightDirection );\n\tvec2 coord = vec2( dotNL * 0.5 + 0.5, 0.0 );\n\t#ifdef USE_GRADIENTMAP\n\t\treturn texture2D( gradientMap, coord ).rgb;\n\t#else\n\t\treturn ( coord.x < 0.7 ) ? vec3( 0.7 ) : vec3( 1.0 );\n\t#endif\n}",lightmap_fragment:"#ifdef USE_LIGHTMAP\n\tvec4 lightMapTexel= texture2D( lightMap, vUv2 );\n\treflectedLight.indirectDiffuse += PI * lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\n#endif",lightmap_pars_fragment:"#ifdef USE_LIGHTMAP\n\tuniform sampler2D lightMap;\n\tuniform float lightMapIntensity;\n#endif",lights_lambert_vertex:"vec3 diffuse = vec3( 1.0 );\nGeometricContext geometry;\ngeometry.position = mvPosition.xyz;\ngeometry.normal = normalize( transformedNormal );\ngeometry.viewDir = ( isOrthographic ) ? vec3( 0, 0, 1 ) : normalize( -mvPosition.xyz );\nGeometricContext backGeometry;\nbackGeometry.position = geometry.position;\nbackGeometry.normal = -geometry.normal;\nbackGeometry.viewDir = geometry.viewDir;\nvLightFront = vec3( 0.0 );\nvIndirectFront = vec3( 0.0 );\n#ifdef DOUBLE_SIDED\n\tvLightBack = vec3( 0.0 );\n\tvIndirectBack = vec3( 0.0 );\n#endif\nIncidentLight directLight;\nfloat dotNL;\nvec3 directLightColor_Diffuse;\nvIndirectFront += getAmbientLightIrradiance( ambientLightColor );\nvIndirectFront += getLightProbeIrradiance( lightProbe, geometry );\n#ifdef DOUBLE_SIDED\n\tvIndirectBack += getAmbientLightIrradiance( ambientLightColor );\n\tvIndirectBack += getLightProbeIrradiance( lightProbe, backGeometry );\n#endif\n#if NUM_POINT_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tgetPointDirectLightIrradiance( pointLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tgetSpotDirectLightIrradiance( spotLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if NUM_DIR_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tgetDirectionalDirectLightIrradiance( directionalLights[ i ], geometry, directLight );\n\t\tdotNL = dot( geometry.normal, directLight.direction );\n\t\tdirectLightColor_Diffuse = PI * directLight.color;\n\t\tvLightFront += saturate( dotNL ) * directLightColor_Diffuse;\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvLightBack += saturate( -dotNL ) * directLightColor_Diffuse;\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\tvIndirectFront += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );\n\t\t#ifdef DOUBLE_SIDED\n\t\t\tvIndirectBack += getHemisphereLightIrradiance( hemisphereLights[ i ], backGeometry );\n\t\t#endif\n\t}\n\t#pragma unroll_loop_end\n#endif",lights_pars_begin:"uniform bool receiveShadow;\nuniform vec3 ambientLightColor;\nuniform vec3 lightProbe[ 9 ];\nvec3 shGetIrradianceAt( in vec3 normal, in vec3 shCoefficients[ 9 ] ) {\n\tfloat x = normal.x, y = normal.y, z = normal.z;\n\tvec3 result = shCoefficients[ 0 ] * 0.886227;\n\tresult += shCoefficients[ 1 ] * 2.0 * 0.511664 * y;\n\tresult += shCoefficients[ 2 ] * 2.0 * 0.511664 * z;\n\tresult += shCoefficients[ 3 ] * 2.0 * 0.511664 * x;\n\tresult += shCoefficients[ 4 ] * 2.0 * 0.429043 * x * y;\n\tresult += shCoefficients[ 5 ] * 2.0 * 0.429043 * y * z;\n\tresult += shCoefficients[ 6 ] * ( 0.743125 * z * z - 0.247708 );\n\tresult += shCoefficients[ 7 ] * 2.0 * 0.429043 * x * z;\n\tresult += shCoefficients[ 8 ] * 0.429043 * ( x * x - y * y );\n\treturn result;\n}\nvec3 getLightProbeIrradiance( const in vec3 lightProbe[ 9 ], const in GeometricContext geometry ) {\n\tvec3 worldNormal = inverseTransformDirection( geometry.normal, viewMatrix );\n\tvec3 irradiance = shGetIrradianceAt( worldNormal, lightProbe );\n\treturn irradiance;\n}\nvec3 getAmbientLightIrradiance( const in vec3 ambientLightColor ) {\n\tvec3 irradiance = ambientLightColor;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\treturn irradiance;\n}\n#if NUM_DIR_LIGHTS > 0\n\tstruct DirectionalLight {\n\t\tvec3 direction;\n\t\tvec3 color;\n\t};\n\tuniform DirectionalLight directionalLights[ NUM_DIR_LIGHTS ];\n\tvoid getDirectionalDirectLightIrradiance( const in DirectionalLight directionalLight, const in GeometricContext geometry, out IncidentLight directLight ) {\n\t\tdirectLight.color = directionalLight.color;\n\t\tdirectLight.direction = directionalLight.direction;\n\t\tdirectLight.visible = true;\n\t}\n#endif\n#if NUM_POINT_LIGHTS > 0\n\tstruct PointLight {\n\t\tvec3 position;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t};\n\tuniform PointLight pointLights[ NUM_POINT_LIGHTS ];\n\tvoid getPointDirectLightIrradiance( const in PointLight pointLight, const in GeometricContext geometry, out IncidentLight directLight ) {\n\t\tvec3 lVector = pointLight.position - geometry.position;\n\t\tdirectLight.direction = normalize( lVector );\n\t\tfloat lightDistance = length( lVector );\n\t\tdirectLight.color = pointLight.color;\n\t\tdirectLight.color *= punctualLightIntensityToIrradianceFactor( lightDistance, pointLight.distance, pointLight.decay );\n\t\tdirectLight.visible = ( directLight.color != vec3( 0.0 ) );\n\t}\n#endif\n#if NUM_SPOT_LIGHTS > 0\n\tstruct SpotLight {\n\t\tvec3 position;\n\t\tvec3 direction;\n\t\tvec3 color;\n\t\tfloat distance;\n\t\tfloat decay;\n\t\tfloat coneCos;\n\t\tfloat penumbraCos;\n\t};\n\tuniform SpotLight spotLights[ NUM_SPOT_LIGHTS ];\n\tvoid getSpotDirectLightIrradiance( const in SpotLight spotLight, const in GeometricContext geometry, out IncidentLight directLight ) {\n\t\tvec3 lVector = spotLight.position - geometry.position;\n\t\tdirectLight.direction = normalize( lVector );\n\t\tfloat lightDistance = length( lVector );\n\t\tfloat angleCos = dot( directLight.direction, spotLight.direction );\n\t\tif ( angleCos > spotLight.coneCos ) {\n\t\t\tfloat spotEffect = smoothstep( spotLight.coneCos, spotLight.penumbraCos, angleCos );\n\t\t\tdirectLight.color = spotLight.color;\n\t\t\tdirectLight.color *= spotEffect * punctualLightIntensityToIrradianceFactor( lightDistance, spotLight.distance, spotLight.decay );\n\t\t\tdirectLight.visible = true;\n\t\t} else {\n\t\t\tdirectLight.color = vec3( 0.0 );\n\t\t\tdirectLight.visible = false;\n\t\t}\n\t}\n#endif\n#if NUM_RECT_AREA_LIGHTS > 0\n\tstruct RectAreaLight {\n\t\tvec3 color;\n\t\tvec3 position;\n\t\tvec3 halfWidth;\n\t\tvec3 halfHeight;\n\t};\n\tuniform sampler2D ltc_1;\tuniform sampler2D ltc_2;\n\tuniform RectAreaLight rectAreaLights[ NUM_RECT_AREA_LIGHTS ];\n#endif\n#if NUM_HEMI_LIGHTS > 0\n\tstruct HemisphereLight {\n\t\tvec3 direction;\n\t\tvec3 skyColor;\n\t\tvec3 groundColor;\n\t};\n\tuniform HemisphereLight hemisphereLights[ NUM_HEMI_LIGHTS ];\n\tvec3 getHemisphereLightIrradiance( const in HemisphereLight hemiLight, const in GeometricContext geometry ) {\n\t\tfloat dotNL = dot( geometry.normal, hemiLight.direction );\n\t\tfloat hemiDiffuseWeight = 0.5 * dotNL + 0.5;\n\t\tvec3 irradiance = mix( hemiLight.groundColor, hemiLight.skyColor, hemiDiffuseWeight );\n\t\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\t\tirradiance *= PI;\n\t\t#endif\n\t\treturn irradiance;\n\t}\n#endif",lights_toon_fragment:"ToonMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb;",lights_toon_pars_fragment:"varying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\nstruct ToonMaterial {\n\tvec3 diffuseColor;\n};\nvoid RE_Direct_Toon( const in IncidentLight directLight, const in GeometricContext geometry, const in ToonMaterial material, inout ReflectedLight reflectedLight ) {\n\tvec3 irradiance = getGradientIrradiance( geometry.normal, directLight.direction ) * directLight.color;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\treflectedLight.directDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectDiffuse_Toon( const in vec3 irradiance, const in GeometricContext geometry, const in ToonMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n}\n#define RE_Direct\t\t\t\tRE_Direct_Toon\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_Toon\n#define Material_LightProbeLOD( material )\t(0)",lights_phong_fragment:"BlinnPhongMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb;\nmaterial.specularColor = specular;\nmaterial.specularShininess = shininess;\nmaterial.specularStrength = specularStrength;",lights_phong_pars_fragment:"varying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\nstruct BlinnPhongMaterial {\n\tvec3 diffuseColor;\n\tvec3 specularColor;\n\tfloat specularShininess;\n\tfloat specularStrength;\n};\nvoid RE_Direct_BlinnPhong( const in IncidentLight directLight, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\tvec3 irradiance = dotNL * directLight.color;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\treflectedLight.directDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n\treflectedLight.directSpecular += irradiance * BRDF_Specular_BlinnPhong( directLight, geometry, material.specularColor, material.specularShininess ) * material.specularStrength;\n}\nvoid RE_IndirectDiffuse_BlinnPhong( const in vec3 irradiance, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n}\n#define RE_Direct\t\t\t\tRE_Direct_BlinnPhong\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_BlinnPhong\n#define Material_LightProbeLOD( material )\t(0)",lights_physical_fragment:"PhysicalMaterial material;\nmaterial.diffuseColor = diffuseColor.rgb * ( 1.0 - metalnessFactor );\nvec3 dxy = max( abs( dFdx( geometryNormal ) ), abs( dFdy( geometryNormal ) ) );\nfloat geometryRoughness = max( max( dxy.x, dxy.y ), dxy.z );\nmaterial.specularRoughness = max( roughnessFactor, 0.0525 );material.specularRoughness += geometryRoughness;\nmaterial.specularRoughness = min( material.specularRoughness, 1.0 );\n#ifdef REFLECTIVITY\n\tmaterial.specularColor = mix( vec3( MAXIMUM_SPECULAR_COEFFICIENT * pow2( reflectivity ) ), diffuseColor.rgb, metalnessFactor );\n#else\n\tmaterial.specularColor = mix( vec3( DEFAULT_SPECULAR_COEFFICIENT ), diffuseColor.rgb, metalnessFactor );\n#endif\n#ifdef CLEARCOAT\n\tmaterial.clearcoat = clearcoat;\n\tmaterial.clearcoatRoughness = clearcoatRoughness;\n\t#ifdef USE_CLEARCOATMAP\n\t\tmaterial.clearcoat *= texture2D( clearcoatMap, vUv ).x;\n\t#endif\n\t#ifdef USE_CLEARCOAT_ROUGHNESSMAP\n\t\tmaterial.clearcoatRoughness *= texture2D( clearcoatRoughnessMap, vUv ).y;\n\t#endif\n\tmaterial.clearcoat = saturate( material.clearcoat );\tmaterial.clearcoatRoughness = max( material.clearcoatRoughness, 0.0525 );\n\tmaterial.clearcoatRoughness += geometryRoughness;\n\tmaterial.clearcoatRoughness = min( material.clearcoatRoughness, 1.0 );\n#endif\n#ifdef USE_SHEEN\n\tmaterial.sheenColor = sheen;\n#endif",lights_physical_pars_fragment:"struct PhysicalMaterial {\n\tvec3 diffuseColor;\n\tfloat specularRoughness;\n\tvec3 specularColor;\n#ifdef CLEARCOAT\n\tfloat clearcoat;\n\tfloat clearcoatRoughness;\n#endif\n#ifdef USE_SHEEN\n\tvec3 sheenColor;\n#endif\n};\n#define MAXIMUM_SPECULAR_COEFFICIENT 0.16\n#define DEFAULT_SPECULAR_COEFFICIENT 0.04\nfloat clearcoatDHRApprox( const in float roughness, const in float dotNL ) {\n\treturn DEFAULT_SPECULAR_COEFFICIENT + ( 1.0 - DEFAULT_SPECULAR_COEFFICIENT ) * ( pow( 1.0 - dotNL, 5.0 ) * pow( 1.0 - roughness, 2.0 ) );\n}\n#if NUM_RECT_AREA_LIGHTS > 0\n\tvoid RE_Direct_RectArea_Physical( const in RectAreaLight rectAreaLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\t\tvec3 normal = geometry.normal;\n\t\tvec3 viewDir = geometry.viewDir;\n\t\tvec3 position = geometry.position;\n\t\tvec3 lightPos = rectAreaLight.position;\n\t\tvec3 halfWidth = rectAreaLight.halfWidth;\n\t\tvec3 halfHeight = rectAreaLight.halfHeight;\n\t\tvec3 lightColor = rectAreaLight.color;\n\t\tfloat roughness = material.specularRoughness;\n\t\tvec3 rectCoords[ 4 ];\n\t\trectCoords[ 0 ] = lightPos + halfWidth - halfHeight;\t\trectCoords[ 1 ] = lightPos - halfWidth - halfHeight;\n\t\trectCoords[ 2 ] = lightPos - halfWidth + halfHeight;\n\t\trectCoords[ 3 ] = lightPos + halfWidth + halfHeight;\n\t\tvec2 uv = LTC_Uv( normal, viewDir, roughness );\n\t\tvec4 t1 = texture2D( ltc_1, uv );\n\t\tvec4 t2 = texture2D( ltc_2, uv );\n\t\tmat3 mInv = mat3(\n\t\t\tvec3( t1.x, 0, t1.y ),\n\t\t\tvec3( 0, 1, 0 ),\n\t\t\tvec3( t1.z, 0, t1.w )\n\t\t);\n\t\tvec3 fresnel = ( material.specularColor * t2.x + ( vec3( 1.0 ) - material.specularColor ) * t2.y );\n\t\treflectedLight.directSpecular += lightColor * fresnel * LTC_Evaluate( normal, viewDir, position, mInv, rectCoords );\n\t\treflectedLight.directDiffuse += lightColor * material.diffuseColor * LTC_Evaluate( normal, viewDir, position, mat3( 1.0 ), rectCoords );\n\t}\n#endif\nvoid RE_Direct_Physical( const in IncidentLight directLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\tfloat dotNL = saturate( dot( geometry.normal, directLight.direction ) );\n\tvec3 irradiance = dotNL * directLight.color;\n\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\tirradiance *= PI;\n\t#endif\n\t#ifdef CLEARCOAT\n\t\tfloat ccDotNL = saturate( dot( geometry.clearcoatNormal, directLight.direction ) );\n\t\tvec3 ccIrradiance = ccDotNL * directLight.color;\n\t\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\t\tccIrradiance *= PI;\n\t\t#endif\n\t\tfloat clearcoatDHR = material.clearcoat * clearcoatDHRApprox( material.clearcoatRoughness, ccDotNL );\n\t\treflectedLight.directSpecular += ccIrradiance * material.clearcoat * BRDF_Specular_GGX( directLight, geometry.viewDir, geometry.clearcoatNormal, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearcoatRoughness );\n\t#else\n\t\tfloat clearcoatDHR = 0.0;\n\t#endif\n\t#ifdef USE_SHEEN\n\t\treflectedLight.directSpecular += ( 1.0 - clearcoatDHR ) * irradiance * BRDF_Specular_Sheen(\n\t\t\tmaterial.specularRoughness,\n\t\t\tdirectLight.direction,\n\t\t\tgeometry,\n\t\t\tmaterial.sheenColor\n\t\t);\n\t#else\n\t\treflectedLight.directSpecular += ( 1.0 - clearcoatDHR ) * irradiance * BRDF_Specular_GGX( directLight, geometry.viewDir, geometry.normal, material.specularColor, material.specularRoughness);\n\t#endif\n\treflectedLight.directDiffuse += ( 1.0 - clearcoatDHR ) * irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectDiffuse_Physical( const in vec3 irradiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {\n\treflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );\n}\nvoid RE_IndirectSpecular_Physical( const in vec3 radiance, const in vec3 irradiance, const in vec3 clearcoatRadiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight) {\n\t#ifdef CLEARCOAT\n\t\tfloat ccDotNV = saturate( dot( geometry.clearcoatNormal, geometry.viewDir ) );\n\t\treflectedLight.indirectSpecular += clearcoatRadiance * material.clearcoat * BRDF_Specular_GGX_Environment( geometry.viewDir, geometry.clearcoatNormal, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearcoatRoughness );\n\t\tfloat ccDotNL = ccDotNV;\n\t\tfloat clearcoatDHR = material.clearcoat * clearcoatDHRApprox( material.clearcoatRoughness, ccDotNL );\n\t#else\n\t\tfloat clearcoatDHR = 0.0;\n\t#endif\n\tfloat clearcoatInv = 1.0 - clearcoatDHR;\n\tvec3 singleScattering = vec3( 0.0 );\n\tvec3 multiScattering = vec3( 0.0 );\n\tvec3 cosineWeightedIrradiance = irradiance * RECIPROCAL_PI;\n\tBRDF_Specular_Multiscattering_Environment( geometry, material.specularColor, material.specularRoughness, singleScattering, multiScattering );\n\tvec3 diffuse = material.diffuseColor * ( 1.0 - ( singleScattering + multiScattering ) );\n\treflectedLight.indirectSpecular += clearcoatInv * radiance * singleScattering;\n\treflectedLight.indirectSpecular += multiScattering * cosineWeightedIrradiance;\n\treflectedLight.indirectDiffuse += diffuse * cosineWeightedIrradiance;\n}\n#define RE_Direct\t\t\t\tRE_Direct_Physical\n#define RE_Direct_RectArea\t\tRE_Direct_RectArea_Physical\n#define RE_IndirectDiffuse\t\tRE_IndirectDiffuse_Physical\n#define RE_IndirectSpecular\t\tRE_IndirectSpecular_Physical\nfloat computeSpecularOcclusion( const in float dotNV, const in float ambientOcclusion, const in float roughness ) {\n\treturn saturate( pow( dotNV + ambientOcclusion, exp2( - 16.0 * roughness - 1.0 ) ) - 1.0 + ambientOcclusion );\n}",lights_fragment_begin:"\nGeometricContext geometry;\ngeometry.position = - vViewPosition;\ngeometry.normal = normal;\ngeometry.viewDir = ( isOrthographic ) ? vec3( 0, 0, 1 ) : normalize( vViewPosition );\n#ifdef CLEARCOAT\n\tgeometry.clearcoatNormal = clearcoatNormal;\n#endif\nIncidentLight directLight;\n#if ( NUM_POINT_LIGHTS > 0 ) && defined( RE_Direct )\n\tPointLight pointLight;\n\t#if defined( USE_SHADOWMAP ) && NUM_POINT_LIGHT_SHADOWS > 0\n\tPointLightShadow pointLightShadow;\n\t#endif\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {\n\t\tpointLight = pointLights[ i ];\n\t\tgetPointDirectLightIrradiance( pointLight, geometry, directLight );\n\t\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_POINT_LIGHT_SHADOWS )\n\t\tpointLightShadow = pointLightShadows[ i ];\n\t\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getPointShadow( pointShadowMap[ i ], pointLightShadow.shadowMapSize, pointLightShadow.shadowBias, pointLightShadow.shadowRadius, vPointShadowCoord[ i ], pointLightShadow.shadowCameraNear, pointLightShadow.shadowCameraFar ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if ( NUM_SPOT_LIGHTS > 0 ) && defined( RE_Direct )\n\tSpotLight spotLight;\n\t#if defined( USE_SHADOWMAP ) && NUM_SPOT_LIGHT_SHADOWS > 0\n\tSpotLightShadow spotLightShadow;\n\t#endif\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {\n\t\tspotLight = spotLights[ i ];\n\t\tgetSpotDirectLightIrradiance( spotLight, geometry, directLight );\n\t\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_SPOT_LIGHT_SHADOWS )\n\t\tspotLightShadow = spotLightShadows[ i ];\n\t\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getShadow( spotShadowMap[ i ], spotLightShadow.shadowMapSize, spotLightShadow.shadowBias, spotLightShadow.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if ( NUM_DIR_LIGHTS > 0 ) && defined( RE_Direct )\n\tDirectionalLight directionalLight;\n\t#if defined( USE_SHADOWMAP ) && NUM_DIR_LIGHT_SHADOWS > 0\n\tDirectionalLightShadow directionalLightShadow;\n\t#endif\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {\n\t\tdirectionalLight = directionalLights[ i ];\n\t\tgetDirectionalDirectLightIrradiance( directionalLight, geometry, directLight );\n\t\t#if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_DIR_LIGHT_SHADOWS )\n\t\tdirectionalLightShadow = directionalLightShadows[ i ];\n\t\tdirectLight.color *= all( bvec2( directLight.visible, receiveShadow ) ) ? getShadow( directionalShadowMap[ i ], directionalLightShadow.shadowMapSize, directionalLightShadow.shadowBias, directionalLightShadow.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t\t#endif\n\t\tRE_Direct( directLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if ( NUM_RECT_AREA_LIGHTS > 0 ) && defined( RE_Direct_RectArea )\n\tRectAreaLight rectAreaLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_RECT_AREA_LIGHTS; i ++ ) {\n\t\trectAreaLight = rectAreaLights[ i ];\n\t\tRE_Direct_RectArea( rectAreaLight, geometry, material, reflectedLight );\n\t}\n\t#pragma unroll_loop_end\n#endif\n#if defined( RE_IndirectDiffuse )\n\tvec3 iblIrradiance = vec3( 0.0 );\n\tvec3 irradiance = getAmbientLightIrradiance( ambientLightColor );\n\tirradiance += getLightProbeIrradiance( lightProbe, geometry );\n\t#if ( NUM_HEMI_LIGHTS > 0 )\n\t\t#pragma unroll_loop_start\n\t\tfor ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {\n\t\t\tirradiance += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );\n\t\t}\n\t\t#pragma unroll_loop_end\n\t#endif\n#endif\n#if defined( RE_IndirectSpecular )\n\tvec3 radiance = vec3( 0.0 );\n\tvec3 clearcoatRadiance = vec3( 0.0 );\n#endif",lights_fragment_maps:"#if defined( RE_IndirectDiffuse )\n\t#ifdef USE_LIGHTMAP\n\t\tvec4 lightMapTexel= texture2D( lightMap, vUv2 );\n\t\tvec3 lightMapIrradiance = lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\n\t\t#ifndef PHYSICALLY_CORRECT_LIGHTS\n\t\t\tlightMapIrradiance *= PI;\n\t\t#endif\n\t\tirradiance += lightMapIrradiance;\n\t#endif\n\t#if defined( USE_ENVMAP ) && defined( STANDARD ) && defined( ENVMAP_TYPE_CUBE_UV )\n\t\tiblIrradiance += getLightProbeIndirectIrradiance( geometry, maxMipLevel );\n\t#endif\n#endif\n#if defined( USE_ENVMAP ) && defined( RE_IndirectSpecular )\n\tradiance += getLightProbeIndirectRadiance( geometry.viewDir, geometry.normal, material.specularRoughness, maxMipLevel );\n\t#ifdef CLEARCOAT\n\t\tclearcoatRadiance += getLightProbeIndirectRadiance( geometry.viewDir, geometry.clearcoatNormal, material.clearcoatRoughness, maxMipLevel );\n\t#endif\n#endif",lights_fragment_end:"#if defined( RE_IndirectDiffuse )\n\tRE_IndirectDiffuse( irradiance, geometry, material, reflectedLight );\n#endif\n#if defined( RE_IndirectSpecular )\n\tRE_IndirectSpecular( radiance, iblIrradiance, clearcoatRadiance, geometry, material, reflectedLight );\n#endif",logdepthbuf_fragment:"#if defined( USE_LOGDEPTHBUF ) && defined( USE_LOGDEPTHBUF_EXT )\n\tgl_FragDepthEXT = vIsPerspective == 0.0 ? gl_FragCoord.z : log2( vFragDepth ) * logDepthBufFC * 0.5;\n#endif",logdepthbuf_pars_fragment:"#if defined( USE_LOGDEPTHBUF ) && defined( USE_LOGDEPTHBUF_EXT )\n\tuniform float logDepthBufFC;\n\tvarying float vFragDepth;\n\tvarying float vIsPerspective;\n#endif",logdepthbuf_pars_vertex:"#ifdef USE_LOGDEPTHBUF\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvarying float vFragDepth;\n\t\tvarying float vIsPerspective;\n\t#else\n\t\tuniform float logDepthBufFC;\n\t#endif\n#endif",logdepthbuf_vertex:"#ifdef USE_LOGDEPTHBUF\n\t#ifdef USE_LOGDEPTHBUF_EXT\n\t\tvFragDepth = 1.0 + gl_Position.w;\n\t\tvIsPerspective = float( isPerspectiveMatrix( projectionMatrix ) );\n\t#else\n\t\tif ( isPerspectiveMatrix( projectionMatrix ) ) {\n\t\t\tgl_Position.z = log2( max( EPSILON, gl_Position.w + 1.0 ) ) * logDepthBufFC - 1.0;\n\t\t\tgl_Position.z *= gl_Position.w;\n\t\t}\n\t#endif\n#endif",map_fragment:"#ifdef USE_MAP\n\tvec4 texelColor = texture2D( map, vUv );\n\ttexelColor = mapTexelToLinear( texelColor );\n\tdiffuseColor *= texelColor;\n#endif",map_pars_fragment:"#ifdef USE_MAP\n\tuniform sampler2D map;\n#endif",map_particle_fragment:"#if defined( USE_MAP ) || defined( USE_ALPHAMAP )\n\tvec2 uv = ( uvTransform * vec3( gl_PointCoord.x, 1.0 - gl_PointCoord.y, 1 ) ).xy;\n#endif\n#ifdef USE_MAP\n\tvec4 mapTexel = texture2D( map, uv );\n\tdiffuseColor *= mapTexelToLinear( mapTexel );\n#endif\n#ifdef USE_ALPHAMAP\n\tdiffuseColor.a *= texture2D( alphaMap, uv ).g;\n#endif",map_particle_pars_fragment:"#if defined( USE_MAP ) || defined( USE_ALPHAMAP )\n\tuniform mat3 uvTransform;\n#endif\n#ifdef USE_MAP\n\tuniform sampler2D map;\n#endif\n#ifdef USE_ALPHAMAP\n\tuniform sampler2D alphaMap;\n#endif",metalnessmap_fragment:"float metalnessFactor = metalness;\n#ifdef USE_METALNESSMAP\n\tvec4 texelMetalness = texture2D( metalnessMap, vUv );\n\tmetalnessFactor *= texelMetalness.b;\n#endif",metalnessmap_pars_fragment:"#ifdef USE_METALNESSMAP\n\tuniform sampler2D metalnessMap;\n#endif",morphnormal_vertex:"#ifdef USE_MORPHNORMALS\n\tobjectNormal *= morphTargetBaseInfluence;\n\tobjectNormal += morphNormal0 * morphTargetInfluences[ 0 ];\n\tobjectNormal += morphNormal1 * morphTargetInfluences[ 1 ];\n\tobjectNormal += morphNormal2 * morphTargetInfluences[ 2 ];\n\tobjectNormal += morphNormal3 * morphTargetInfluences[ 3 ];\n#endif",morphtarget_pars_vertex:"#ifdef USE_MORPHTARGETS\n\tuniform float morphTargetBaseInfluence;\n\t#ifndef USE_MORPHNORMALS\n\t\tuniform float morphTargetInfluences[ 8 ];\n\t#else\n\t\tuniform float morphTargetInfluences[ 4 ];\n\t#endif\n#endif",morphtarget_vertex:"#ifdef USE_MORPHTARGETS\n\ttransformed *= morphTargetBaseInfluence;\n\ttransformed += morphTarget0 * morphTargetInfluences[ 0 ];\n\ttransformed += morphTarget1 * morphTargetInfluences[ 1 ];\n\ttransformed += morphTarget2 * morphTargetInfluences[ 2 ];\n\ttransformed += morphTarget3 * morphTargetInfluences[ 3 ];\n\t#ifndef USE_MORPHNORMALS\n\t\ttransformed += morphTarget4 * morphTargetInfluences[ 4 ];\n\t\ttransformed += morphTarget5 * morphTargetInfluences[ 5 ];\n\t\ttransformed += morphTarget6 * morphTargetInfluences[ 6 ];\n\t\ttransformed += morphTarget7 * morphTargetInfluences[ 7 ];\n\t#endif\n#endif",normal_fragment_begin:"float faceDirection = gl_FrontFacing ? 1.0 : - 1.0;\n#ifdef FLAT_SHADED\n\tvec3 fdx = vec3( dFdx( vViewPosition.x ), dFdx( vViewPosition.y ), dFdx( vViewPosition.z ) );\n\tvec3 fdy = vec3( dFdy( vViewPosition.x ), dFdy( vViewPosition.y ), dFdy( vViewPosition.z ) );\n\tvec3 normal = normalize( cross( fdx, fdy ) );\n#else\n\tvec3 normal = normalize( vNormal );\n\t#ifdef DOUBLE_SIDED\n\t\tnormal = normal * faceDirection;\n\t#endif\n\t#ifdef USE_TANGENT\n\t\tvec3 tangent = normalize( vTangent );\n\t\tvec3 bitangent = normalize( vBitangent );\n\t\t#ifdef DOUBLE_SIDED\n\t\t\ttangent = tangent * faceDirection;\n\t\t\tbitangent = bitangent * faceDirection;\n\t\t#endif\n\t\t#if defined( TANGENTSPACE_NORMALMAP ) || defined( USE_CLEARCOAT_NORMALMAP )\n\t\t\tmat3 vTBN = mat3( tangent, bitangent, normal );\n\t\t#endif\n\t#endif\n#endif\nvec3 geometryNormal = normal;",normal_fragment_maps:"#ifdef OBJECTSPACE_NORMALMAP\n\tnormal = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;\n\t#ifdef FLIP_SIDED\n\t\tnormal = - normal;\n\t#endif\n\t#ifdef DOUBLE_SIDED\n\t\tnormal = normal * faceDirection;\n\t#endif\n\tnormal = normalize( normalMatrix * normal );\n#elif defined( TANGENTSPACE_NORMALMAP )\n\tvec3 mapN = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;\n\tmapN.xy *= normalScale;\n\t#ifdef USE_TANGENT\n\t\tnormal = normalize( vTBN * mapN );\n\t#else\n\t\tnormal = perturbNormal2Arb( -vViewPosition, normal, mapN, faceDirection );\n\t#endif\n#elif defined( USE_BUMPMAP )\n\tnormal = perturbNormalArb( -vViewPosition, normal, dHdxy_fwd(), faceDirection );\n#endif",normalmap_pars_fragment:"#ifdef USE_NORMALMAP\n\tuniform sampler2D normalMap;\n\tuniform vec2 normalScale;\n#endif\n#ifdef OBJECTSPACE_NORMALMAP\n\tuniform mat3 normalMatrix;\n#endif\n#if ! defined ( USE_TANGENT ) && ( defined ( TANGENTSPACE_NORMALMAP ) || defined ( USE_CLEARCOAT_NORMALMAP ) )\n\tvec3 perturbNormal2Arb( vec3 eye_pos, vec3 surf_norm, vec3 mapN, float faceDirection ) {\n\t\tvec3 q0 = vec3( dFdx( eye_pos.x ), dFdx( eye_pos.y ), dFdx( eye_pos.z ) );\n\t\tvec3 q1 = vec3( dFdy( eye_pos.x ), dFdy( eye_pos.y ), dFdy( eye_pos.z ) );\n\t\tvec2 st0 = dFdx( vUv.st );\n\t\tvec2 st1 = dFdy( vUv.st );\n\t\tvec3 N = surf_norm;\n\t\tvec3 q1perp = cross( q1, N );\n\t\tvec3 q0perp = cross( N, q0 );\n\t\tvec3 T = q1perp * st0.x + q0perp * st1.x;\n\t\tvec3 B = q1perp * st0.y + q0perp * st1.y;\n\t\tfloat det = max( dot( T, T ), dot( B, B ) );\n\t\tfloat scale = ( det == 0.0 ) ? 0.0 : faceDirection * inversesqrt( det );\n\t\treturn normalize( T * ( mapN.x * scale ) + B * ( mapN.y * scale ) + N * mapN.z );\n\t}\n#endif",clearcoat_normal_fragment_begin:"#ifdef CLEARCOAT\n\tvec3 clearcoatNormal = geometryNormal;\n#endif",clearcoat_normal_fragment_maps:"#ifdef USE_CLEARCOAT_NORMALMAP\n\tvec3 clearcoatMapN = texture2D( clearcoatNormalMap, vUv ).xyz * 2.0 - 1.0;\n\tclearcoatMapN.xy *= clearcoatNormalScale;\n\t#ifdef USE_TANGENT\n\t\tclearcoatNormal = normalize( vTBN * clearcoatMapN );\n\t#else\n\t\tclearcoatNormal = perturbNormal2Arb( - vViewPosition, clearcoatNormal, clearcoatMapN, faceDirection );\n\t#endif\n#endif",clearcoat_pars_fragment:"#ifdef USE_CLEARCOATMAP\n\tuniform sampler2D clearcoatMap;\n#endif\n#ifdef USE_CLEARCOAT_ROUGHNESSMAP\n\tuniform sampler2D clearcoatRoughnessMap;\n#endif\n#ifdef USE_CLEARCOAT_NORMALMAP\n\tuniform sampler2D clearcoatNormalMap;\n\tuniform vec2 clearcoatNormalScale;\n#endif",packing:"vec3 packNormalToRGB( const in vec3 normal ) {\n\treturn normalize( normal ) * 0.5 + 0.5;\n}\nvec3 unpackRGBToNormal( const in vec3 rgb ) {\n\treturn 2.0 * rgb.xyz - 1.0;\n}\nconst float PackUpscale = 256. / 255.;const float UnpackDownscale = 255. / 256.;\nconst vec3 PackFactors = vec3( 256. * 256. * 256., 256. * 256., 256. );\nconst vec4 UnpackFactors = UnpackDownscale / vec4( PackFactors, 1. );\nconst float ShiftRight8 = 1. / 256.;\nvec4 packDepthToRGBA( const in float v ) {\n\tvec4 r = vec4( fract( v * PackFactors ), v );\n\tr.yzw -= r.xyz * ShiftRight8;\treturn r * PackUpscale;\n}\nfloat unpackRGBAToDepth( const in vec4 v ) {\n\treturn dot( v, UnpackFactors );\n}\nvec4 pack2HalfToRGBA( vec2 v ) {\n\tvec4 r = vec4( v.x, fract( v.x * 255.0 ), v.y, fract( v.y * 255.0 ));\n\treturn vec4( r.x - r.y / 255.0, r.y, r.z - r.w / 255.0, r.w);\n}\nvec2 unpackRGBATo2Half( vec4 v ) {\n\treturn vec2( v.x + ( v.y / 255.0 ), v.z + ( v.w / 255.0 ) );\n}\nfloat viewZToOrthographicDepth( const in float viewZ, const in float near, const in float far ) {\n\treturn ( viewZ + near ) / ( near - far );\n}\nfloat orthographicDepthToViewZ( const in float linearClipZ, const in float near, const in float far ) {\n\treturn linearClipZ * ( near - far ) - near;\n}\nfloat viewZToPerspectiveDepth( const in float viewZ, const in float near, const in float far ) {\n\treturn (( near + viewZ ) * far ) / (( far - near ) * viewZ );\n}\nfloat perspectiveDepthToViewZ( const in float invClipZ, const in float near, const in float far ) {\n\treturn ( near * far ) / ( ( far - near ) * invClipZ - far );\n}",premultiplied_alpha_fragment:"#ifdef PREMULTIPLIED_ALPHA\n\tgl_FragColor.rgb *= gl_FragColor.a;\n#endif",project_vertex:"vec4 mvPosition = vec4( transformed, 1.0 );\n#ifdef USE_INSTANCING\n\tmvPosition = instanceMatrix * mvPosition;\n#endif\nmvPosition = modelViewMatrix * mvPosition;\ngl_Position = projectionMatrix * mvPosition;",dithering_fragment:"#ifdef DITHERING\n\tgl_FragColor.rgb = dithering( gl_FragColor.rgb );\n#endif",dithering_pars_fragment:"#ifdef DITHERING\n\tvec3 dithering( vec3 color ) {\n\t\tfloat grid_position = rand( gl_FragCoord.xy );\n\t\tvec3 dither_shift_RGB = vec3( 0.25 / 255.0, -0.25 / 255.0, 0.25 / 255.0 );\n\t\tdither_shift_RGB = mix( 2.0 * dither_shift_RGB, -2.0 * dither_shift_RGB, grid_position );\n\t\treturn color + dither_shift_RGB;\n\t}\n#endif",roughnessmap_fragment:"float roughnessFactor = roughness;\n#ifdef USE_ROUGHNESSMAP\n\tvec4 texelRoughness = texture2D( roughnessMap, vUv );\n\troughnessFactor *= texelRoughness.g;\n#endif",roughnessmap_pars_fragment:"#ifdef USE_ROUGHNESSMAP\n\tuniform sampler2D roughnessMap;\n#endif",shadowmap_pars_fragment:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\t\tuniform sampler2D directionalShadowMap[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tstruct DirectionalLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform DirectionalLightShadow directionalLightShadows[ NUM_DIR_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\t\tuniform sampler2D spotShadowMap[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tstruct SpotLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform SpotLightShadow spotLightShadows[ NUM_SPOT_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\t\tuniform sampler2D pointShadowMap[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tstruct PointLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t\tfloat shadowCameraNear;\n\t\t\tfloat shadowCameraFar;\n\t\t};\n\t\tuniform PointLightShadow pointLightShadows[ NUM_POINT_LIGHT_SHADOWS ];\n\t#endif\n\tfloat texture2DCompare( sampler2D depths, vec2 uv, float compare ) {\n\t\treturn step( compare, unpackRGBAToDepth( texture2D( depths, uv ) ) );\n\t}\n\tvec2 texture2DDistribution( sampler2D shadow, vec2 uv ) {\n\t\treturn unpackRGBATo2Half( texture2D( shadow, uv ) );\n\t}\n\tfloat VSMShadow (sampler2D shadow, vec2 uv, float compare ){\n\t\tfloat occlusion = 1.0;\n\t\tvec2 distribution = texture2DDistribution( shadow, uv );\n\t\tfloat hard_shadow = step( compare , distribution.x );\n\t\tif (hard_shadow != 1.0 ) {\n\t\t\tfloat distance = compare - distribution.x ;\n\t\t\tfloat variance = max( 0.00000, distribution.y * distribution.y );\n\t\t\tfloat softness_probability = variance / (variance + distance * distance );\t\t\tsoftness_probability = clamp( ( softness_probability - 0.3 ) / ( 0.95 - 0.3 ), 0.0, 1.0 );\t\t\tocclusion = clamp( max( hard_shadow, softness_probability ), 0.0, 1.0 );\n\t\t}\n\t\treturn occlusion;\n\t}\n\tfloat getShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord ) {\n\t\tfloat shadow = 1.0;\n\t\tshadowCoord.xyz /= shadowCoord.w;\n\t\tshadowCoord.z += shadowBias;\n\t\tbvec4 inFrustumVec = bvec4 ( shadowCoord.x >= 0.0, shadowCoord.x <= 1.0, shadowCoord.y >= 0.0, shadowCoord.y <= 1.0 );\n\t\tbool inFrustum = all( inFrustumVec );\n\t\tbvec2 frustumTestVec = bvec2( inFrustum, shadowCoord.z <= 1.0 );\n\t\tbool frustumTest = all( frustumTestVec );\n\t\tif ( frustumTest ) {\n\t\t#if defined( SHADOWMAP_TYPE_PCF )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx0 = - texelSize.x * shadowRadius;\n\t\t\tfloat dy0 = - texelSize.y * shadowRadius;\n\t\t\tfloat dx1 = + texelSize.x * shadowRadius;\n\t\t\tfloat dy1 = + texelSize.y * shadowRadius;\n\t\t\tfloat dx2 = dx0 / 2.0;\n\t\t\tfloat dy2 = dy0 / 2.0;\n\t\t\tfloat dx3 = dx1 / 2.0;\n\t\t\tfloat dy3 = dy1 / 2.0;\n\t\t\tshadow = (\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, dy2 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy2 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, dy2 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, dy3 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy3 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, dy3 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy1 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy1 ), shadowCoord.z )\n\t\t\t) * ( 1.0 / 17.0 );\n\t\t#elif defined( SHADOWMAP_TYPE_PCF_SOFT )\n\t\t\tvec2 texelSize = vec2( 1.0 ) / shadowMapSize;\n\t\t\tfloat dx = texelSize.x;\n\t\t\tfloat dy = texelSize.y;\n\t\t\tvec2 uv = shadowCoord.xy;\n\t\t\tvec2 f = fract( uv * shadowMapSize + 0.5 );\n\t\t\tuv -= f * texelSize;\n\t\t\tshadow = (\n\t\t\t\ttexture2DCompare( shadowMap, uv, shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, uv + vec2( dx, 0.0 ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, uv + vec2( 0.0, dy ), shadowCoord.z ) +\n\t\t\t\ttexture2DCompare( shadowMap, uv + texelSize, shadowCoord.z ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( -dx, 0.0 ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, 0.0 ), shadowCoord.z ),\n\t\t\t\t\t f.x ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( -dx, dy ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, dy ), shadowCoord.z ),\n\t\t\t\t\t f.x ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( 0.0, -dy ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 0.0, 2.0 * dy ), shadowCoord.z ),\n\t\t\t\t\t f.y ) +\n\t\t\t\tmix( texture2DCompare( shadowMap, uv + vec2( dx, -dy ), shadowCoord.z ), \n\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( dx, 2.0 * dy ), shadowCoord.z ),\n\t\t\t\t\t f.y ) +\n\t\t\t\tmix( mix( texture2DCompare( shadowMap, uv + vec2( -dx, -dy ), shadowCoord.z ), \n\t\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, -dy ), shadowCoord.z ),\n\t\t\t\t\t\t f.x ),\n\t\t\t\t\t mix( texture2DCompare( shadowMap, uv + vec2( -dx, 2.0 * dy ), shadowCoord.z ), \n\t\t\t\t\t\t texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, 2.0 * dy ), shadowCoord.z ),\n\t\t\t\t\t\t f.x ),\n\t\t\t\t\t f.y )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#elif defined( SHADOWMAP_TYPE_VSM )\n\t\t\tshadow = VSMShadow( shadowMap, shadowCoord.xy, shadowCoord.z );\n\t\t#else\n\t\t\tshadow = texture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z );\n\t\t#endif\n\t\t}\n\t\treturn shadow;\n\t}\n\tvec2 cubeToUV( vec3 v, float texelSizeY ) {\n\t\tvec3 absV = abs( v );\n\t\tfloat scaleToCube = 1.0 / max( absV.x, max( absV.y, absV.z ) );\n\t\tabsV *= scaleToCube;\n\t\tv *= scaleToCube * ( 1.0 - 2.0 * texelSizeY );\n\t\tvec2 planar = v.xy;\n\t\tfloat almostATexel = 1.5 * texelSizeY;\n\t\tfloat almostOne = 1.0 - almostATexel;\n\t\tif ( absV.z >= almostOne ) {\n\t\t\tif ( v.z > 0.0 )\n\t\t\t\tplanar.x = 4.0 - v.x;\n\t\t} else if ( absV.x >= almostOne ) {\n\t\t\tfloat signX = sign( v.x );\n\t\t\tplanar.x = v.z * signX + 2.0 * signX;\n\t\t} else if ( absV.y >= almostOne ) {\n\t\t\tfloat signY = sign( v.y );\n\t\t\tplanar.x = v.x + 2.0 * signY + 2.0;\n\t\t\tplanar.y = v.z * signY - 2.0;\n\t\t}\n\t\treturn vec2( 0.125, 0.25 ) * planar + vec2( 0.375, 0.75 );\n\t}\n\tfloat getPointShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord, float shadowCameraNear, float shadowCameraFar ) {\n\t\tvec2 texelSize = vec2( 1.0 ) / ( shadowMapSize * vec2( 4.0, 2.0 ) );\n\t\tvec3 lightToPosition = shadowCoord.xyz;\n\t\tfloat dp = ( length( lightToPosition ) - shadowCameraNear ) / ( shadowCameraFar - shadowCameraNear );\t\tdp += shadowBias;\n\t\tvec3 bd3D = normalize( lightToPosition );\n\t\t#if defined( SHADOWMAP_TYPE_PCF ) || defined( SHADOWMAP_TYPE_PCF_SOFT ) || defined( SHADOWMAP_TYPE_VSM )\n\t\t\tvec2 offset = vec2( - 1, 1 ) * shadowRadius * texelSize.y;\n\t\t\treturn (\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxy, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxx, texelSize.y ), dp ) +\n\t\t\t\ttexture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxx, texelSize.y ), dp )\n\t\t\t) * ( 1.0 / 9.0 );\n\t\t#else\n\t\t\treturn texture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp );\n\t\t#endif\n\t}\n#endif",shadowmap_pars_vertex:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\t\tuniform mat4 directionalShadowMatrix[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tvarying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHT_SHADOWS ];\n\t\tstruct DirectionalLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform DirectionalLightShadow directionalLightShadows[ NUM_DIR_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\t\tuniform mat4 spotShadowMatrix[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHT_SHADOWS ];\n\t\tstruct SpotLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t};\n\t\tuniform SpotLightShadow spotLightShadows[ NUM_SPOT_LIGHT_SHADOWS ];\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\t\tuniform mat4 pointShadowMatrix[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tvarying vec4 vPointShadowCoord[ NUM_POINT_LIGHT_SHADOWS ];\n\t\tstruct PointLightShadow {\n\t\t\tfloat shadowBias;\n\t\t\tfloat shadowNormalBias;\n\t\t\tfloat shadowRadius;\n\t\t\tvec2 shadowMapSize;\n\t\t\tfloat shadowCameraNear;\n\t\t\tfloat shadowCameraFar;\n\t\t};\n\t\tuniform PointLightShadow pointLightShadows[ NUM_POINT_LIGHT_SHADOWS ];\n\t#endif\n#endif",shadowmap_vertex:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0 || NUM_SPOT_LIGHT_SHADOWS > 0 || NUM_POINT_LIGHT_SHADOWS > 0\n\t\tvec3 shadowWorldNormal = inverseTransformDirection( transformedNormal, viewMatrix );\n\t\tvec4 shadowWorldPosition;\n\t#endif\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHT_SHADOWS; i ++ ) {\n\t\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * directionalLightShadows[ i ].shadowNormalBias, 0 );\n\t\tvDirectionalShadowCoord[ i ] = directionalShadowMatrix[ i ] * shadowWorldPosition;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHT_SHADOWS; i ++ ) {\n\t\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * spotLightShadows[ i ].shadowNormalBias, 0 );\n\t\tvSpotShadowCoord[ i ] = spotShadowMatrix[ i ] * shadowWorldPosition;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHT_SHADOWS; i ++ ) {\n\t\tshadowWorldPosition = worldPosition + vec4( shadowWorldNormal * pointLightShadows[ i ].shadowNormalBias, 0 );\n\t\tvPointShadowCoord[ i ] = pointShadowMatrix[ i ] * shadowWorldPosition;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n#endif",shadowmask_pars_fragment:"float getShadowMask() {\n\tfloat shadow = 1.0;\n\t#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\tDirectionalLightShadow directionalLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHT_SHADOWS; i ++ ) {\n\t\tdirectionalLight = directionalLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\tSpotLightShadow spotLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHT_SHADOWS; i ++ ) {\n\t\tspotLight = spotLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\tPointLightShadow pointLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHT_SHADOWS; i ++ ) {\n\t\tpointLight = pointLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ], pointLight.shadowCameraNear, pointLight.shadowCameraFar ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#endif\n\treturn shadow;\n}",skinbase_vertex:"#ifdef USE_SKINNING\n\tmat4 boneMatX = getBoneMatrix( skinIndex.x );\n\tmat4 boneMatY = getBoneMatrix( skinIndex.y );\n\tmat4 boneMatZ = getBoneMatrix( skinIndex.z );\n\tmat4 boneMatW = getBoneMatrix( skinIndex.w );\n#endif",skinning_pars_vertex:"#ifdef USE_SKINNING\n\tuniform mat4 bindMatrix;\n\tuniform mat4 bindMatrixInverse;\n\t#ifdef BONE_TEXTURE\n\t\tuniform highp sampler2D boneTexture;\n\t\tuniform int boneTextureSize;\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tfloat j = i * 4.0;\n\t\t\tfloat x = mod( j, float( boneTextureSize ) );\n\t\t\tfloat y = floor( j / float( boneTextureSize ) );\n\t\t\tfloat dx = 1.0 / float( boneTextureSize );\n\t\t\tfloat dy = 1.0 / float( boneTextureSize );\n\t\t\ty = dy * ( y + 0.5 );\n\t\t\tvec4 v1 = texture2D( boneTexture, vec2( dx * ( x + 0.5 ), y ) );\n\t\t\tvec4 v2 = texture2D( boneTexture, vec2( dx * ( x + 1.5 ), y ) );\n\t\t\tvec4 v3 = texture2D( boneTexture, vec2( dx * ( x + 2.5 ), y ) );\n\t\t\tvec4 v4 = texture2D( boneTexture, vec2( dx * ( x + 3.5 ), y ) );\n\t\t\tmat4 bone = mat4( v1, v2, v3, v4 );\n\t\t\treturn bone;\n\t\t}\n\t#else\n\t\tuniform mat4 boneMatrices[ MAX_BONES ];\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tmat4 bone = boneMatrices[ int(i) ];\n\t\t\treturn bone;\n\t\t}\n\t#endif\n#endif",skinning_vertex:"#ifdef USE_SKINNING\n\tvec4 skinVertex = bindMatrix * vec4( transformed, 1.0 );\n\tvec4 skinned = vec4( 0.0 );\n\tskinned += boneMatX * skinVertex * skinWeight.x;\n\tskinned += boneMatY * skinVertex * skinWeight.y;\n\tskinned += boneMatZ * skinVertex * skinWeight.z;\n\tskinned += boneMatW * skinVertex * skinWeight.w;\n\ttransformed = ( bindMatrixInverse * skinned ).xyz;\n#endif",skinnormal_vertex:"#ifdef USE_SKINNING\n\tmat4 skinMatrix = mat4( 0.0 );\n\tskinMatrix += skinWeight.x * boneMatX;\n\tskinMatrix += skinWeight.y * boneMatY;\n\tskinMatrix += skinWeight.z * boneMatZ;\n\tskinMatrix += skinWeight.w * boneMatW;\n\tskinMatrix = bindMatrixInverse * skinMatrix * bindMatrix;\n\tobjectNormal = vec4( skinMatrix * vec4( objectNormal, 0.0 ) ).xyz;\n\t#ifdef USE_TANGENT\n\t\tobjectTangent = vec4( skinMatrix * vec4( objectTangent, 0.0 ) ).xyz;\n\t#endif\n#endif",specularmap_fragment:"float specularStrength;\n#ifdef USE_SPECULARMAP\n\tvec4 texelSpecular = texture2D( specularMap, vUv );\n\tspecularStrength = texelSpecular.r;\n#else\n\tspecularStrength = 1.0;\n#endif",specularmap_pars_fragment:"#ifdef USE_SPECULARMAP\n\tuniform sampler2D specularMap;\n#endif",tonemapping_fragment:"#if defined( TONE_MAPPING )\n\tgl_FragColor.rgb = toneMapping( gl_FragColor.rgb );\n#endif",tonemapping_pars_fragment:"#ifndef saturate\n#define saturate(a) clamp( a, 0.0, 1.0 )\n#endif\nuniform float toneMappingExposure;\nvec3 LinearToneMapping( vec3 color ) {\n\treturn toneMappingExposure * color;\n}\nvec3 ReinhardToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\treturn saturate( color / ( vec3( 1.0 ) + color ) );\n}\nvec3 OptimizedCineonToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\tcolor = max( vec3( 0.0 ), color - 0.004 );\n\treturn pow( ( color * ( 6.2 * color + 0.5 ) ) / ( color * ( 6.2 * color + 1.7 ) + 0.06 ), vec3( 2.2 ) );\n}\nvec3 RRTAndODTFit( vec3 v ) {\n\tvec3 a = v * ( v + 0.0245786 ) - 0.000090537;\n\tvec3 b = v * ( 0.983729 * v + 0.4329510 ) + 0.238081;\n\treturn a / b;\n}\nvec3 ACESFilmicToneMapping( vec3 color ) {\n\tconst mat3 ACESInputMat = mat3(\n\t\tvec3( 0.59719, 0.07600, 0.02840 ),\t\tvec3( 0.35458, 0.90834, 0.13383 ),\n\t\tvec3( 0.04823, 0.01566, 0.83777 )\n\t);\n\tconst mat3 ACESOutputMat = mat3(\n\t\tvec3( 1.60475, -0.10208, -0.00327 ),\t\tvec3( -0.53108, 1.10813, -0.07276 ),\n\t\tvec3( -0.07367, -0.00605, 1.07602 )\n\t);\n\tcolor *= toneMappingExposure / 0.6;\n\tcolor = ACESInputMat * color;\n\tcolor = RRTAndODTFit( color );\n\tcolor = ACESOutputMat * color;\n\treturn saturate( color );\n}\nvec3 CustomToneMapping( vec3 color ) { return color; }",transmission_fragment:"#ifdef USE_TRANSMISSION\n\tfloat transmissionFactor = transmission;\n\tfloat thicknessFactor = thickness;\n\t#ifdef USE_TRANSMISSIONMAP\n\t\ttransmissionFactor *= texture2D( transmissionMap, vUv ).r;\n\t#endif\n\t#ifdef USE_THICKNESSNMAP\n\t\tthicknessFactor *= texture2D( thicknessMap, vUv ).g;\n\t#endif\n\tvec3 pos = vWorldPosition.xyz / vWorldPosition.w;\n\tvec3 v = normalize( cameraPosition - pos );\n\tfloat ior = ( 1.0 + 0.4 * reflectivity ) / ( 1.0 - 0.4 * reflectivity );\n\tvec3 transmission = transmissionFactor * getIBLVolumeRefraction(\n\t\tnormal, v, roughnessFactor, material.diffuseColor, totalSpecular,\n\t\tpos, modelMatrix, viewMatrix, projectionMatrix, ior, thicknessFactor,\n\t\tattenuationColor, attenuationDistance );\n\ttotalDiffuse = mix( totalDiffuse, transmission, transmissionFactor );\n#endif",transmission_pars_fragment:"#ifdef USE_TRANSMISSION\n\t#ifdef USE_TRANSMISSIONMAP\n\t\tuniform sampler2D transmissionMap;\n\t#endif\n\t#ifdef USE_THICKNESSMAP\n\t\tuniform sampler2D thicknessMap;\n\t#endif\n\tuniform vec2 transmissionSamplerSize;\n\tuniform sampler2D transmissionSamplerMap;\n\tuniform mat4 modelMatrix;\n\tuniform mat4 projectionMatrix;\n\tvarying vec4 vWorldPosition;\n\tvec3 getVolumeTransmissionRay(vec3 n, vec3 v, float thickness, float ior, mat4 modelMatrix) {\n\t\tvec3 refractionVector = refract(-v, normalize(n), 1.0 / ior);\n\t\tvec3 modelScale;\n\t\tmodelScale.x = length(vec3(modelMatrix[0].xyz));\n\t\tmodelScale.y = length(vec3(modelMatrix[1].xyz));\n\t\tmodelScale.z = length(vec3(modelMatrix[2].xyz));\n\t\treturn normalize(refractionVector) * thickness * modelScale;\n\t}\n\tfloat applyIorToRoughness(float roughness, float ior) {\n\t\treturn roughness * clamp(ior * 2.0 - 2.0, 0.0, 1.0);\n\t}\n\tvec3 getTransmissionSample(vec2 fragCoord, float roughness, float ior) {\n\t\tfloat framebufferLod = log2(transmissionSamplerSize.x) * applyIorToRoughness(roughness, ior);\n\t\treturn texture2DLodEXT(transmissionSamplerMap, fragCoord.xy, framebufferLod).rgb;\n\t}\n\tvec3 applyVolumeAttenuation(vec3 radiance, float transmissionDistance, vec3 attenuationColor, float attenuationDistance) {\n\t\tif (attenuationDistance == 0.0) {\n\t\t\treturn radiance;\n\t\t} else {\n\t\t\tvec3 attenuationCoefficient = -log(attenuationColor) / attenuationDistance;\n\t\t\tvec3 transmittance = exp(-attenuationCoefficient * transmissionDistance);\t\t\treturn transmittance * radiance;\n\t\t}\n\t}\n\tvec3 getIBLVolumeRefraction(vec3 n, vec3 v, float perceptualRoughness, vec3 baseColor, vec3 specularColor,\n\t\tvec3 position, mat4 modelMatrix, mat4 viewMatrix, mat4 projMatrix, float ior, float thickness,\n\t\tvec3 attenuationColor, float attenuationDistance) {\n\t\tvec3 transmissionRay = getVolumeTransmissionRay(n, v, thickness, ior, modelMatrix);\n\t\tvec3 refractedRayExit = position + transmissionRay;\n\t\tvec4 ndcPos = projMatrix * viewMatrix * vec4(refractedRayExit, 1.0);\n\t\tvec2 refractionCoords = ndcPos.xy / ndcPos.w;\n\t\trefractionCoords += 1.0;\n\t\trefractionCoords /= 2.0;\n\t\tvec3 transmittedLight = getTransmissionSample(refractionCoords, perceptualRoughness, ior);\n\t\tvec3 attenuatedColor = applyVolumeAttenuation(transmittedLight, length(transmissionRay), attenuationColor, attenuationDistance);\n\t\treturn (1.0 - specularColor) * attenuatedColor * baseColor;\n\t}\n#endif",uv_pars_fragment:"#if ( defined( USE_UV ) && ! defined( UVS_VERTEX_ONLY ) )\n\tvarying vec2 vUv;\n#endif",uv_pars_vertex:"#ifdef USE_UV\n\t#ifdef UVS_VERTEX_ONLY\n\t\tvec2 vUv;\n\t#else\n\t\tvarying vec2 vUv;\n\t#endif\n\tuniform mat3 uvTransform;\n#endif",uv_vertex:"#ifdef USE_UV\n\tvUv = ( uvTransform * vec3( uv, 1 ) ).xy;\n#endif",uv2_pars_fragment:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvarying vec2 vUv2;\n#endif",uv2_pars_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tattribute vec2 uv2;\n\tvarying vec2 vUv2;\n\tuniform mat3 uv2Transform;\n#endif",uv2_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvUv2 = ( uv2Transform * vec3( uv2, 1 ) ).xy;\n#endif",worldpos_vertex:"#if defined( USE_ENVMAP ) || defined( DISTANCE ) || defined ( USE_SHADOWMAP ) || defined ( USE_TRANSMISSION )\n\tvec4 worldPosition = vec4( transformed, 1.0 );\n\t#ifdef USE_INSTANCING\n\t\tworldPosition = instanceMatrix * worldPosition;\n\t#endif\n\tworldPosition = modelMatrix * worldPosition;\n#endif",background_frag:"uniform sampler2D t2D;\nvarying vec2 vUv;\nvoid main() {\n\tvec4 texColor = texture2D( t2D, vUv );\n\tgl_FragColor = mapTexelToLinear( texColor );\n\t#include \n\t#include \n}",background_vert:"varying vec2 vUv;\nuniform mat3 uvTransform;\nvoid main() {\n\tvUv = ( uvTransform * vec3( uv, 1 ) ).xy;\n\tgl_Position = vec4( position.xy, 1.0, 1.0 );\n}",cube_frag:"#include \nuniform float opacity;\nvarying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvec3 vReflect = vWorldDirection;\n\t#include \n\tgl_FragColor = envColor;\n\tgl_FragColor.a *= opacity;\n\t#include \n\t#include \n}",cube_vert:"varying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvWorldDirection = transformDirection( position, modelMatrix );\n\t#include \n\t#include \n\tgl_Position.z = gl_Position.w;\n}",depth_frag:"#if DEPTH_PACKING == 3200\n\tuniform float opacity;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvarying vec2 vHighPrecisionZW;\nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( 1.0 );\n\t#if DEPTH_PACKING == 3200\n\t\tdiffuseColor.a = opacity;\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\tfloat fragCoordZ = 0.5 * vHighPrecisionZW[0] / vHighPrecisionZW[1] + 0.5;\n\t#if DEPTH_PACKING == 3200\n\t\tgl_FragColor = vec4( vec3( 1.0 - fragCoordZ ), opacity );\n\t#elif DEPTH_PACKING == 3201\n\t\tgl_FragColor = packDepthToRGBA( fragCoordZ );\n\t#endif\n}",depth_vert:"#include \n#include \n#include \n#include \n#include \n#include \n#include \nvarying vec2 vHighPrecisionZW;\nvoid main() {\n\t#include \n\t#include \n\t#ifdef USE_DISPLACEMENTMAP\n\t\t#include \n\t\t#include \n\t\t#include \n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvHighPrecisionZW = gl_Position.zw;\n}",distanceRGBA_frag:"#define DISTANCE\nuniform vec3 referencePosition;\nuniform float nearDistance;\nuniform float farDistance;\nvarying vec3 vWorldPosition;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main () {\n\t#include \n\tvec4 diffuseColor = vec4( 1.0 );\n\t#include \n\t#include \n\t#include \n\tfloat dist = length( vWorldPosition - referencePosition );\n\tdist = ( dist - nearDistance ) / ( farDistance - nearDistance );\n\tdist = saturate( dist );\n\tgl_FragColor = packDepthToRGBA( dist );\n}",distanceRGBA_vert:"#define DISTANCE\nvarying vec3 vWorldPosition;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#ifdef USE_DISPLACEMENTMAP\n\t\t#include \n\t\t#include \n\t\t#include \n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvWorldPosition = worldPosition.xyz;\n}",equirect_frag:"uniform sampler2D tEquirect;\nvarying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvec3 direction = normalize( vWorldDirection );\n\tvec2 sampleUV = equirectUv( direction );\n\tvec4 texColor = texture2D( tEquirect, sampleUV );\n\tgl_FragColor = mapTexelToLinear( texColor );\n\t#include \n\t#include \n}",equirect_vert:"varying vec3 vWorldDirection;\n#include \nvoid main() {\n\tvWorldDirection = transformDirection( position, modelMatrix );\n\t#include \n\t#include \n}",linedashed_frag:"uniform vec3 diffuse;\nuniform float opacity;\nuniform float dashSize;\nuniform float totalSize;\nvarying float vLineDistance;\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tif ( mod( vLineDistance, totalSize ) > dashSize ) {\n\t\tdiscard;\n\t}\n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}",linedashed_vert:"uniform float scale;\nattribute float lineDistance;\nvarying float vLineDistance;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\tvLineDistance = scale * lineDistance;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshbasic_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\t#ifdef USE_LIGHTMAP\n\t\n\t\tvec4 lightMapTexel= texture2D( lightMap, vUv2 );\n\t\treflectedLight.indirectDiffuse += lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;\n\t#else\n\t\treflectedLight.indirectDiffuse += vec3( 1.0 );\n\t#endif\n\t#include \n\treflectedLight.indirectDiffuse *= diffuseColor.rgb;\n\tvec3 outgoingLight = reflectedLight.indirectDiffuse;\n\t#include \n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshbasic_vert:"#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#ifdef USE_ENVMAP\n\t#include \n\t#include \n\t#include \n\t#include \n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshlambert_frag:"uniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float opacity;\nvarying vec3 vLightFront;\nvarying vec3 vIndirectFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n\tvarying vec3 vIndirectBack;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#ifdef DOUBLE_SIDED\n\t\treflectedLight.indirectDiffuse += ( gl_FrontFacing ) ? vIndirectFront : vIndirectBack;\n\t#else\n\t\treflectedLight.indirectDiffuse += vIndirectFront;\n\t#endif\n\t#include \n\treflectedLight.indirectDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb );\n\t#ifdef DOUBLE_SIDED\n\t\treflectedLight.directDiffuse = ( gl_FrontFacing ) ? vLightFront : vLightBack;\n\t#else\n\t\treflectedLight.directDiffuse = vLightFront;\n\t#endif\n\treflectedLight.directDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb ) * getShadowMask();\n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;\n\t#include \n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshlambert_vert:"#define LAMBERT\nvarying vec3 vLightFront;\nvarying vec3 vIndirectFront;\n#ifdef DOUBLE_SIDED\n\tvarying vec3 vLightBack;\n\tvarying vec3 vIndirectBack;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshmatcap_frag:"#define MATCAP\nuniform vec3 diffuse;\nuniform float opacity;\nuniform sampler2D matcap;\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 viewDir = normalize( vViewPosition );\n\tvec3 x = normalize( vec3( viewDir.z, 0.0, - viewDir.x ) );\n\tvec3 y = cross( viewDir, x );\n\tvec2 uv = vec2( dot( x, normal ), dot( y, normal ) ) * 0.495 + 0.5;\n\t#ifdef USE_MATCAP\n\t\tvec4 matcapColor = texture2D( matcap, uv );\n\t\tmatcapColor = matcapTexelToLinear( matcapColor );\n\t#else\n\t\tvec4 matcapColor = vec4( 1.0 );\n\t#endif\n\tvec3 outgoingLight = diffuseColor.rgb * matcapColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshmatcap_vert:"#define MATCAP\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#ifndef FLAT_SHADED\n\t\tvNormal = normalize( transformedNormal );\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n}",meshtoon_frag:"#define TOON\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshtoon_vert:"#define TOON\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n\t#include \n}",meshphong_frag:"#define PHONG\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform vec3 specular;\nuniform float shininess;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;\n\t#include \n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshphong_vert:"#define PHONG\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n\t#include \n\t#include \n}",meshphysical_frag:"#define STANDARD\n#ifdef PHYSICAL\n\t#define REFLECTIVITY\n\t#define CLEARCOAT\n#endif\nuniform vec3 diffuse;\nuniform vec3 emissive;\nuniform float roughness;\nuniform float metalness;\nuniform float opacity;\n#ifdef USE_TRANSMISSION\n\tuniform float transmission;\n\tuniform float thickness;\n\tuniform vec3 attenuationColor;\n\tuniform float attenuationDistance;\n#endif\n#ifdef REFLECTIVITY\n\tuniform float reflectivity;\n#endif\n#ifdef CLEARCOAT\n\tuniform float clearcoat;\n\tuniform float clearcoatRoughness;\n#endif\n#ifdef USE_SHEEN\n\tuniform vec3 sheen;\n#endif\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n\t#ifdef USE_TANGENT\n\t\tvarying vec3 vTangent;\n\t\tvarying vec3 vBitangent;\n\t#endif\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\tReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );\n\tvec3 totalEmissiveRadiance = emissive;\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvec3 totalDiffuse = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse;\n\tvec3 totalSpecular = reflectedLight.directSpecular + reflectedLight.indirectSpecular;\n\t#include \n\tvec3 outgoingLight = totalDiffuse + totalSpecular + totalEmissiveRadiance;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",meshphysical_vert:"#define STANDARD\nvarying vec3 vViewPosition;\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n\t#ifdef USE_TANGENT\n\t\tvarying vec3 vTangent;\n\t\tvarying vec3 vBitangent;\n\t#endif\n#endif\n#ifdef USE_TRANSMISSION\n\tvarying vec4 vWorldPosition;\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n\t#ifdef USE_TANGENT\n\t\tvTangent = normalize( transformedTangent );\n\t\tvBitangent = normalize( cross( vNormal, vTangent ) * tangent.w );\n\t#endif\n#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\tvViewPosition = - mvPosition.xyz;\n\t#include \n\t#include \n\t#include \n#ifdef USE_TRANSMISSION\n\tvWorldPosition = worldPosition;\n#endif\n}",normal_frag:"#define NORMAL\nuniform float opacity;\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n\t#ifdef USE_TANGENT\n\t\tvarying vec3 vTangent;\n\t\tvarying vec3 vBitangent;\n\t#endif\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\tgl_FragColor = vec4( packNormalToRGB( normal ), opacity );\n}",normal_vert:"#define NORMAL\n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\n\tvarying vec3 vViewPosition;\n#endif\n#ifndef FLAT_SHADED\n\tvarying vec3 vNormal;\n\t#ifdef USE_TANGENT\n\t\tvarying vec3 vTangent;\n\t\tvarying vec3 vBitangent;\n\t#endif\n#endif\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#ifndef FLAT_SHADED\n\tvNormal = normalize( transformedNormal );\n\t#ifdef USE_TANGENT\n\t\tvTangent = normalize( transformedTangent );\n\t\tvBitangent = normalize( cross( vNormal, vTangent ) * tangent.w );\n\t#endif\n#endif\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n#if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )\n\tvViewPosition = - mvPosition.xyz;\n#endif\n}",points_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n\t#include \n}",points_vert:"uniform float size;\nuniform float scale;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\tgl_PointSize = size;\n\t#ifdef USE_SIZEATTENUATION\n\t\tbool isPerspective = isPerspectiveMatrix( projectionMatrix );\n\t\tif ( isPerspective ) gl_PointSize *= ( scale / - mvPosition.z );\n\t#endif\n\t#include \n\t#include \n\t#include \n\t#include \n}",shadow_frag:"uniform vec3 color;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\tgl_FragColor = vec4( color, opacity * ( 1.0 - getShadowMask() ) );\n\t#include \n\t#include \n\t#include \n}",shadow_vert:"#include \n#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}",sprite_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n}",sprite_vert:"uniform float rotation;\nuniform vec2 center;\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 mvPosition = modelViewMatrix * vec4( 0.0, 0.0, 0.0, 1.0 );\n\tvec2 scale;\n\tscale.x = length( vec3( modelMatrix[ 0 ].x, modelMatrix[ 0 ].y, modelMatrix[ 0 ].z ) );\n\tscale.y = length( vec3( modelMatrix[ 1 ].x, modelMatrix[ 1 ].y, modelMatrix[ 1 ].z ) );\n\t#ifndef USE_SIZEATTENUATION\n\t\tbool isPerspective = isPerspectiveMatrix( projectionMatrix );\n\t\tif ( isPerspective ) scale *= - mvPosition.z;\n\t#endif\n\tvec2 alignedPosition = ( position.xy - ( center - vec2( 0.5 ) ) ) * scale;\n\tvec2 rotatedPosition;\n\trotatedPosition.x = cos( rotation ) * alignedPosition.x - sin( rotation ) * alignedPosition.y;\n\trotatedPosition.y = sin( rotation ) * alignedPosition.x + cos( rotation ) * alignedPosition.y;\n\tmvPosition.xy += rotatedPosition;\n\tgl_Position = projectionMatrix * mvPosition;\n\t#include \n\t#include \n\t#include \n}"},En={common:{diffuse:{value:new we(16777215)},opacity:{value:1},map:{value:null},uvTransform:{value:new V},uv2Transform:{value:new V},alphaMap:{value:null}},specularmap:{specularMap:{value:null}},envmap:{envMap:{value:null},flipEnvMap:{value:-1},reflectivity:{value:1},refractionRatio:{value:.98},maxMipLevel:{value:0}},aomap:{aoMap:{value:null},aoMapIntensity:{value:1}},lightmap:{lightMap:{value:null},lightMapIntensity:{value:1}},emissivemap:{emissiveMap:{value:null}},bumpmap:{bumpMap:{value:null},bumpScale:{value:1}},normalmap:{normalMap:{value:null},normalScale:{value:new k(1,1)}},displacementmap:{displacementMap:{value:null},displacementScale:{value:1},displacementBias:{value:0}},roughnessmap:{roughnessMap:{value:null}},metalnessmap:{metalnessMap:{value:null}},gradientmap:{gradientMap:{value:null}},fog:{fogDensity:{value:25e-5},fogNear:{value:1},fogFar:{value:2e3},fogColor:{value:new we(16777215)}},lights:{ambientLightColor:{value:[]},lightProbe:{value:[]},directionalLights:{value:[],properties:{direction:{},color:{}}},directionalLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{}}},directionalShadowMap:{value:[]},directionalShadowMatrix:{value:[]},spotLights:{value:[],properties:{color:{},position:{},direction:{},distance:{},coneCos:{},penumbraCos:{},decay:{}}},spotLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{}}},spotShadowMap:{value:[]},spotShadowMatrix:{value:[]},pointLights:{value:[],properties:{color:{},position:{},decay:{},distance:{}}},pointLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{},shadowCameraNear:{},shadowCameraFar:{}}},pointShadowMap:{value:[]},pointShadowMatrix:{value:[]},hemisphereLights:{value:[],properties:{direction:{},skyColor:{},groundColor:{}}},rectAreaLights:{value:[],properties:{color:{},position:{},width:{},height:{}}},ltc_1:{value:null},ltc_2:{value:null}},points:{diffuse:{value:new we(16777215)},opacity:{value:1},size:{value:1},scale:{value:1},map:{value:null},alphaMap:{value:null},uvTransform:{value:new V}},sprite:{diffuse:{value:new we(16777215)},opacity:{value:1},center:{value:new k(.5,.5)},rotation:{value:0},map:{value:null},alphaMap:{value:null},uvTransform:{value:new V}}},An={basic:{uniforms:an([En.common,En.specularmap,En.envmap,En.aomap,En.lightmap,En.fog]),vertexShader:Tn.meshbasic_vert,fragmentShader:Tn.meshbasic_frag},lambert:{uniforms:an([En.common,En.specularmap,En.envmap,En.aomap,En.lightmap,En.emissivemap,En.fog,En.lights,{emissive:{value:new we(0)}}]),vertexShader:Tn.meshlambert_vert,fragmentShader:Tn.meshlambert_frag},phong:{uniforms:an([En.common,En.specularmap,En.envmap,En.aomap,En.lightmap,En.emissivemap,En.bumpmap,En.normalmap,En.displacementmap,En.fog,En.lights,{emissive:{value:new we(0)},specular:{value:new we(1118481)},shininess:{value:30}}]),vertexShader:Tn.meshphong_vert,fragmentShader:Tn.meshphong_frag},standard:{uniforms:an([En.common,En.envmap,En.aomap,En.lightmap,En.emissivemap,En.bumpmap,En.normalmap,En.displacementmap,En.roughnessmap,En.metalnessmap,En.fog,En.lights,{emissive:{value:new we(0)},roughness:{value:1},metalness:{value:0},envMapIntensity:{value:1}}]),vertexShader:Tn.meshphysical_vert,fragmentShader:Tn.meshphysical_frag},toon:{uniforms:an([En.common,En.aomap,En.lightmap,En.emissivemap,En.bumpmap,En.normalmap,En.displacementmap,En.gradientmap,En.fog,En.lights,{emissive:{value:new we(0)}}]),vertexShader:Tn.meshtoon_vert,fragmentShader:Tn.meshtoon_frag},matcap:{uniforms:an([En.common,En.bumpmap,En.normalmap,En.displacementmap,En.fog,{matcap:{value:null}}]),vertexShader:Tn.meshmatcap_vert,fragmentShader:Tn.meshmatcap_frag},points:{uniforms:an([En.points,En.fog]),vertexShader:Tn.points_vert,fragmentShader:Tn.points_frag},dashed:{uniforms:an([En.common,En.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:Tn.linedashed_vert,fragmentShader:Tn.linedashed_frag},depth:{uniforms:an([En.common,En.displacementmap]),vertexShader:Tn.depth_vert,fragmentShader:Tn.depth_frag},normal:{uniforms:an([En.common,En.bumpmap,En.normalmap,En.displacementmap,{opacity:{value:1}}]),vertexShader:Tn.normal_vert,fragmentShader:Tn.normal_frag},sprite:{uniforms:an([En.sprite,En.fog]),vertexShader:Tn.sprite_vert,fragmentShader:Tn.sprite_frag},background:{uniforms:{uvTransform:{value:new V},t2D:{value:null}},vertexShader:Tn.background_vert,fragmentShader:Tn.background_frag},cube:{uniforms:an([En.envmap,{opacity:{value:1}}]),vertexShader:Tn.cube_vert,fragmentShader:Tn.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:Tn.equirect_vert,fragmentShader:Tn.equirect_frag},distanceRGBA:{uniforms:an([En.common,En.displacementmap,{referencePosition:{value:new $},nearDistance:{value:1},farDistance:{value:1e3}}]),vertexShader:Tn.distanceRGBA_vert,fragmentShader:Tn.distanceRGBA_frag},shadow:{uniforms:an([En.lights,En.fog,{color:{value:new we(0)},opacity:{value:1}}]),vertexShader:Tn.shadow_vert,fragmentShader:Tn.shadow_frag}};function Ln(t,e,n,i,r){const s=new we(0);let a,o,l=0,c=null,h=0,u=null;function d(t,e){n.buffers.color.setClear(t.r,t.g,t.b,e,r)}return{getClearColor:function(){return s},setClearColor:function(t,e=1){s.set(t),l=e,d(s,l)},getClearAlpha:function(){return l},setClearAlpha:function(t){l=t,d(s,l)},render:function(n,r){let p=!1,m=!0===r.isScene?r.background:null;m&&m.isTexture&&(m=e.get(m));const f=t.xr,g=f.getSession&&f.getSession();g&&"additive"===g.environmentBlendMode&&(m=null),null===m?d(s,l):m&&m.isColor&&(d(m,1),p=!0),(t.autoClear||p)&&t.clear(t.autoClearColor,t.autoClearDepth,t.autoClearStencil),m&&(m.isCubeTexture||306===m.mapping)?(void 0===o&&(o=new en(new rn(1,1,1),new ln({name:"BackgroundCubeMaterial",uniforms:sn(An.cube.uniforms),vertexShader:An.cube.vertexShader,fragmentShader:An.cube.fragmentShader,side:1,depthTest:!1,depthWrite:!1,fog:!1})),o.geometry.deleteAttribute("normal"),o.geometry.deleteAttribute("uv"),o.onBeforeRender=function(t,e,n){this.matrixWorld.copyPosition(n.matrixWorld)},Object.defineProperty(o.material,"envMap",{get:function(){return this.uniforms.envMap.value}}),i.update(o)),o.material.uniforms.envMap.value=m,o.material.uniforms.flipEnvMap.value=m.isCubeTexture&&m._needsFlipEnvMap?-1:1,c===m&&h===m.version&&u===t.toneMapping||(o.material.needsUpdate=!0,c=m,h=m.version,u=t.toneMapping),n.unshift(o,o.geometry,o.material,0,0,null)):m&&m.isTexture&&(void 0===a&&(a=new en(new Sn(2,2),new ln({name:"BackgroundMaterial",uniforms:sn(An.background.uniforms),vertexShader:An.background.vertexShader,fragmentShader:An.background.fragmentShader,side:0,depthTest:!1,depthWrite:!1,fog:!1})),a.geometry.deleteAttribute("normal"),Object.defineProperty(a.material,"map",{get:function(){return this.uniforms.t2D.value}}),i.update(a)),a.material.uniforms.t2D.value=m,!0===m.matrixAutoUpdate&&m.updateMatrix(),a.material.uniforms.uvTransform.value.copy(m.matrix),c===m&&h===m.version&&u===t.toneMapping||(a.material.needsUpdate=!0,c=m,h=m.version,u=t.toneMapping),n.unshift(a,a.geometry,a.material,0,0,null))}}}function Cn(t,e,n,i){const r=t.getParameter(34921),s=i.isWebGL2?null:e.get("OES_vertex_array_object"),a=i.isWebGL2||null!==s,o={},l=d(null);let c=l;function h(e){return i.isWebGL2?t.bindVertexArray(e):s.bindVertexArrayOES(e)}function u(e){return i.isWebGL2?t.deleteVertexArray(e):s.deleteVertexArrayOES(e)}function d(t){const e=[],n=[],i=[];for(let t=0;t=0){const s=l[e];if(void 0!==s){const e=s.normalized,r=s.itemSize,a=n.get(s);if(void 0===a)continue;const l=a.buffer,c=a.type,h=a.bytesPerElement;if(s.isInterleavedBufferAttribute){const n=s.data,a=n.stride,u=s.offset;n&&n.isInstancedInterleavedBuffer?(f(i,n.meshPerAttribute),void 0===o._maxInstanceCount&&(o._maxInstanceCount=n.meshPerAttribute*n.count)):m(i),t.bindBuffer(34962,l),v(i,r,c,e,a*h,u*h)}else s.isInstancedBufferAttribute?(f(i,s.meshPerAttribute),void 0===o._maxInstanceCount&&(o._maxInstanceCount=s.meshPerAttribute*s.count)):m(i),t.bindBuffer(34962,l),v(i,r,c,e,0,0)}else if("instanceMatrix"===e){const e=n.get(r.instanceMatrix);if(void 0===e)continue;const s=e.buffer,a=e.type;f(i+0,1),f(i+1,1),f(i+2,1),f(i+3,1),t.bindBuffer(34962,s),t.vertexAttribPointer(i+0,4,a,!1,64,0),t.vertexAttribPointer(i+1,4,a,!1,64,16),t.vertexAttribPointer(i+2,4,a,!1,64,32),t.vertexAttribPointer(i+3,4,a,!1,64,48)}else if("instanceColor"===e){const e=n.get(r.instanceColor);if(void 0===e)continue;const s=e.buffer,a=e.type;f(i,1),t.bindBuffer(34962,s),t.vertexAttribPointer(i,3,a,!1,12,0)}else if(void 0!==h){const n=h[e];if(void 0!==n)switch(n.length){case 2:t.vertexAttrib2fv(i,n);break;case 3:t.vertexAttrib3fv(i,n);break;case 4:t.vertexAttrib4fv(i,n);break;default:t.vertexAttrib1fv(i,n)}}}}g()}(r,l,u,y),null!==x&&t.bindBuffer(34963,n.get(x).buffer))},reset:y,resetDefaultState:x,dispose:function(){y();for(const t in o){const e=o[t];for(const t in e){const n=e[t];for(const t in n)u(n[t].object),delete n[t];delete e[t]}delete o[t]}},releaseStatesOfGeometry:function(t){if(void 0===o[t.id])return;const e=o[t.id];for(const t in e){const n=e[t];for(const t in n)u(n[t].object),delete n[t];delete e[t]}delete o[t.id]},releaseStatesOfProgram:function(t){for(const e in o){const n=o[e];if(void 0===n[t.id])continue;const i=n[t.id];for(const t in i)u(i[t].object),delete i[t];delete n[t.id]}},initAttributes:p,enableAttribute:m,disableUnusedAttributes:g}}function Rn(t,e,n,i){const r=i.isWebGL2;let s;this.setMode=function(t){s=t},this.render=function(e,i){t.drawArrays(s,e,i),n.update(i,s,1)},this.renderInstances=function(i,a,o){if(0===o)return;let l,c;if(r)l=t,c="drawArraysInstanced";else if(l=e.get("ANGLE_instanced_arrays"),c="drawArraysInstancedANGLE",null===l)return void console.error("THREE.WebGLBufferRenderer: using THREE.InstancedBufferGeometry but hardware does not support extension ANGLE_instanced_arrays.");l[c](s,i,a,o),n.update(a,s,o)}}function Pn(t,e,n){let i;function r(e){if("highp"===e){if(t.getShaderPrecisionFormat(35633,36338).precision>0&&t.getShaderPrecisionFormat(35632,36338).precision>0)return"highp";e="mediump"}return"mediump"===e&&t.getShaderPrecisionFormat(35633,36337).precision>0&&t.getShaderPrecisionFormat(35632,36337).precision>0?"mediump":"lowp"}const s="undefined"!=typeof WebGL2RenderingContext&&t instanceof WebGL2RenderingContext||"undefined"!=typeof WebGL2ComputeRenderingContext&&t instanceof WebGL2ComputeRenderingContext;let a=void 0!==n.precision?n.precision:"highp";const o=r(a);o!==a&&(console.warn("THREE.WebGLRenderer:",a,"not supported, using",o,"instead."),a=o);const l=s||e.has("WEBGL_draw_buffers"),c=!0===n.logarithmicDepthBuffer,h=t.getParameter(34930),u=t.getParameter(35660),d=t.getParameter(3379),p=t.getParameter(34076),m=t.getParameter(34921),f=t.getParameter(36347),g=t.getParameter(36348),v=t.getParameter(36349),y=u>0,x=s||e.has("OES_texture_float");return{isWebGL2:s,drawBuffers:l,getMaxAnisotropy:function(){if(void 0!==i)return i;if(!0===e.has("EXT_texture_filter_anisotropic")){const n=e.get("EXT_texture_filter_anisotropic");i=t.getParameter(n.MAX_TEXTURE_MAX_ANISOTROPY_EXT)}else i=0;return i},getMaxPrecision:r,precision:a,logarithmicDepthBuffer:c,maxTextures:h,maxVertexTextures:u,maxTextureSize:d,maxCubemapSize:p,maxAttributes:m,maxVertexUniforms:f,maxVaryings:g,maxFragmentUniforms:v,vertexTextures:y,floatFragmentTextures:x,floatVertexTextures:y&&x,maxSamples:s?t.getParameter(36183):0}}function Dn(t){const e=this;let n=null,i=0,r=!1,s=!1;const a=new yn,o=new V,l={value:null,needsUpdate:!1};function c(){l.value!==n&&(l.value=n,l.needsUpdate=i>0),e.numPlanes=i,e.numIntersection=0}function h(t,n,i,r){const s=null!==t?t.length:0;let c=null;if(0!==s){if(c=l.value,!0!==r||null===c){const e=i+4*s,r=n.matrixWorldInverse;o.getNormalMatrix(r),(null===c||c.length0){const a=t.getRenderTarget(),o=new mn(s.height/2);return o.fromEquirectangularTexture(t,r),e.set(r,o),t.setRenderTarget(a),r.addEventListener("dispose",i),n(o.texture,r.mapping)}return null}}}return r},dispose:function(){e=new WeakMap}}}function Nn(t){const e={};function n(n){if(void 0!==e[n])return e[n];let i;switch(n){case"WEBGL_depth_texture":i=t.getExtension("WEBGL_depth_texture")||t.getExtension("MOZ_WEBGL_depth_texture")||t.getExtension("WEBKIT_WEBGL_depth_texture");break;case"EXT_texture_filter_anisotropic":i=t.getExtension("EXT_texture_filter_anisotropic")||t.getExtension("MOZ_EXT_texture_filter_anisotropic")||t.getExtension("WEBKIT_EXT_texture_filter_anisotropic");break;case"WEBGL_compressed_texture_s3tc":i=t.getExtension("WEBGL_compressed_texture_s3tc")||t.getExtension("MOZ_WEBGL_compressed_texture_s3tc")||t.getExtension("WEBKIT_WEBGL_compressed_texture_s3tc");break;case"WEBGL_compressed_texture_pvrtc":i=t.getExtension("WEBGL_compressed_texture_pvrtc")||t.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc");break;default:i=t.getExtension(n)}return e[n]=i,i}return{has:function(t){return null!==n(t)},init:function(t){t.isWebGL2?n("EXT_color_buffer_float"):(n("WEBGL_depth_texture"),n("OES_texture_float"),n("OES_texture_half_float"),n("OES_texture_half_float_linear"),n("OES_standard_derivatives"),n("OES_element_index_uint"),n("OES_vertex_array_object"),n("ANGLE_instanced_arrays")),n("OES_texture_float_linear"),n("EXT_color_buffer_half_float")},get:function(t){const e=n(t);return null===e&&console.warn("THREE.WebGLRenderer: "+t+" extension not supported."),e}}}function zn(t,e,n,i){const r={},s=new WeakMap;function a(t){const o=t.target;null!==o.index&&e.remove(o.index);for(const t in o.attributes)e.remove(o.attributes[t]);o.removeEventListener("dispose",a),delete r[o.id];const l=s.get(o);l&&(e.remove(l),s.delete(o)),i.releaseStatesOfGeometry(o),!0===o.isInstancedBufferGeometry&&delete o._maxInstanceCount,n.memory.geometries--}function o(t){const n=[],i=t.index,r=t.attributes.position;let a=0;if(null!==i){const t=i.array;a=i.version;for(let e=0,i=t.length;e65535?Ae:Ee)(n,1);o.version=a;const l=s.get(t);l&&e.remove(l),s.set(t,o)}return{get:function(t,e){return!0===r[e.id]||(e.addEventListener("dispose",a),r[e.id]=!0,n.memory.geometries++),e},update:function(t){const n=t.attributes;for(const t in n)e.update(n[t],34962);const i=t.morphAttributes;for(const t in i){const n=i[t];for(let t=0,i=n.length;t0)return t;const r=e*n;let s=Yn[r];if(void 0===s&&(s=new Float32Array(r),Yn[r]=s),0!==e){i.toArray(s,0);for(let i=1,r=0;i!==e;++i)r+=n,t[i].toArray(s,r)}return s}function ti(t,e){if(t.length!==e.length)return!1;for(let n=0,i=t.length;n/gm;function ir(t){return t.replace(nr,rr)}function rr(t,e){const n=Tn[e];if(void 0===n)throw new Error("Can not resolve #include <"+e+">");return ir(n)}const sr=/#pragma unroll_loop[\s]+?for \( int i \= (\d+)\; i < (\d+)\; i \+\+ \) \{([\s\S]+?)(?=\})\}/g,ar=/#pragma unroll_loop_start\s+for\s*\(\s*int\s+i\s*=\s*(\d+)\s*;\s*i\s*<\s*(\d+)\s*;\s*i\s*\+\+\s*\)\s*{([\s\S]+?)}\s+#pragma unroll_loop_end/g;function or(t){return t.replace(ar,cr).replace(sr,lr)}function lr(t,e,n,i){return console.warn("WebGLProgram: #pragma unroll_loop shader syntax is deprecated. Please use #pragma unroll_loop_start syntax instead."),cr(t,e,n,i)}function cr(t,e,n,i){let r="";for(let t=parseInt(e);t0?t.gammaFactor:1,p=n.isWebGL2?"":function(t){return[t.extensionDerivatives||t.envMapCubeUV||t.bumpMap||t.tangentSpaceNormalMap||t.clearcoatNormalMap||t.flatShading||"physical"===t.shaderID?"#extension GL_OES_standard_derivatives : enable":"",(t.extensionFragDepth||t.logarithmicDepthBuffer)&&t.rendererExtensionFragDepth?"#extension GL_EXT_frag_depth : enable":"",t.extensionDrawBuffers&&t.rendererExtensionDrawBuffers?"#extension GL_EXT_draw_buffers : require":"",(t.extensionShaderTextureLOD||t.envMap||t.transmission>0)&&t.rendererExtensionShaderTextureLod?"#extension GL_EXT_shader_texture_lod : enable":""].filter($i).join("\n")}(n),m=function(t){const e=[];for(const n in t){const i=t[n];!1!==i&&e.push("#define "+n+" "+i)}return e.join("\n")}(s),f=r.createProgram();let g,v,y=n.glslVersion?"#version "+n.glslVersion+"\n":"";n.isRawShaderMaterial?(g=[m].filter($i).join("\n"),g.length>0&&(g+="\n"),v=[p,m].filter($i).join("\n"),v.length>0&&(v+="\n")):(g=[hr(n),"#define SHADER_NAME "+n.shaderName,m,n.instancing?"#define USE_INSTANCING":"",n.instancingColor?"#define USE_INSTANCING_COLOR":"",n.supportsVertexTextures?"#define VERTEX_TEXTURES":"","#define GAMMA_FACTOR "+d,"#define MAX_BONES "+n.maxBones,n.useFog&&n.fog?"#define USE_FOG":"",n.useFog&&n.fogExp2?"#define FOG_EXP2":"",n.map?"#define USE_MAP":"",n.envMap?"#define USE_ENVMAP":"",n.envMap?"#define "+h:"",n.lightMap?"#define USE_LIGHTMAP":"",n.aoMap?"#define USE_AOMAP":"",n.emissiveMap?"#define USE_EMISSIVEMAP":"",n.bumpMap?"#define USE_BUMPMAP":"",n.normalMap?"#define USE_NORMALMAP":"",n.normalMap&&n.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",n.normalMap&&n.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",n.clearcoatMap?"#define USE_CLEARCOATMAP":"",n.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",n.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",n.displacementMap&&n.supportsVertexTextures?"#define USE_DISPLACEMENTMAP":"",n.specularMap?"#define USE_SPECULARMAP":"",n.roughnessMap?"#define USE_ROUGHNESSMAP":"",n.metalnessMap?"#define USE_METALNESSMAP":"",n.alphaMap?"#define USE_ALPHAMAP":"",n.transmission?"#define USE_TRANSMISSION":"",n.transmissionMap?"#define USE_TRANSMISSIONMAP":"",n.thicknessMap?"#define USE_THICKNESSMAP":"",n.vertexTangents?"#define USE_TANGENT":"",n.vertexColors?"#define USE_COLOR":"",n.vertexAlphas?"#define USE_COLOR_ALPHA":"",n.vertexUvs?"#define USE_UV":"",n.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",n.flatShading?"#define FLAT_SHADED":"",n.skinning?"#define USE_SKINNING":"",n.useVertexTexture?"#define BONE_TEXTURE":"",n.morphTargets?"#define USE_MORPHTARGETS":"",n.morphNormals&&!1===n.flatShading?"#define USE_MORPHNORMALS":"",n.doubleSided?"#define DOUBLE_SIDED":"",n.flipSided?"#define FLIP_SIDED":"",n.shadowMapEnabled?"#define USE_SHADOWMAP":"",n.shadowMapEnabled?"#define "+l:"",n.sizeAttenuation?"#define USE_SIZEATTENUATION":"",n.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",n.logarithmicDepthBuffer&&n.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"","uniform mat4 modelMatrix;","uniform mat4 modelViewMatrix;","uniform mat4 projectionMatrix;","uniform mat4 viewMatrix;","uniform mat3 normalMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;","#ifdef USE_INSTANCING","\tattribute mat4 instanceMatrix;","#endif","#ifdef USE_INSTANCING_COLOR","\tattribute vec3 instanceColor;","#endif","attribute vec3 position;","attribute vec3 normal;","attribute vec2 uv;","#ifdef USE_TANGENT","\tattribute vec4 tangent;","#endif","#if defined( USE_COLOR_ALPHA )","\tattribute vec4 color;","#elif defined( USE_COLOR )","\tattribute vec3 color;","#endif","#ifdef USE_MORPHTARGETS","\tattribute vec3 morphTarget0;","\tattribute vec3 morphTarget1;","\tattribute vec3 morphTarget2;","\tattribute vec3 morphTarget3;","\t#ifdef USE_MORPHNORMALS","\t\tattribute vec3 morphNormal0;","\t\tattribute vec3 morphNormal1;","\t\tattribute vec3 morphNormal2;","\t\tattribute vec3 morphNormal3;","\t#else","\t\tattribute vec3 morphTarget4;","\t\tattribute vec3 morphTarget5;","\t\tattribute vec3 morphTarget6;","\t\tattribute vec3 morphTarget7;","\t#endif","#endif","#ifdef USE_SKINNING","\tattribute vec4 skinIndex;","\tattribute vec4 skinWeight;","#endif","\n"].filter($i).join("\n"),v=[p,hr(n),"#define SHADER_NAME "+n.shaderName,m,n.alphaTest?"#define ALPHATEST "+n.alphaTest+(n.alphaTest%1?"":".0"):"","#define GAMMA_FACTOR "+d,n.useFog&&n.fog?"#define USE_FOG":"",n.useFog&&n.fogExp2?"#define FOG_EXP2":"",n.map?"#define USE_MAP":"",n.matcap?"#define USE_MATCAP":"",n.envMap?"#define USE_ENVMAP":"",n.envMap?"#define "+c:"",n.envMap?"#define "+h:"",n.envMap?"#define "+u:"",n.lightMap?"#define USE_LIGHTMAP":"",n.aoMap?"#define USE_AOMAP":"",n.emissiveMap?"#define USE_EMISSIVEMAP":"",n.bumpMap?"#define USE_BUMPMAP":"",n.normalMap?"#define USE_NORMALMAP":"",n.normalMap&&n.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",n.normalMap&&n.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",n.clearcoatMap?"#define USE_CLEARCOATMAP":"",n.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",n.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",n.specularMap?"#define USE_SPECULARMAP":"",n.roughnessMap?"#define USE_ROUGHNESSMAP":"",n.metalnessMap?"#define USE_METALNESSMAP":"",n.alphaMap?"#define USE_ALPHAMAP":"",n.sheen?"#define USE_SHEEN":"",n.transmission?"#define USE_TRANSMISSION":"",n.transmissionMap?"#define USE_TRANSMISSIONMAP":"",n.thicknessMap?"#define USE_THICKNESSMAP":"",n.vertexTangents?"#define USE_TANGENT":"",n.vertexColors||n.instancingColor?"#define USE_COLOR":"",n.vertexAlphas?"#define USE_COLOR_ALPHA":"",n.vertexUvs?"#define USE_UV":"",n.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",n.gradientMap?"#define USE_GRADIENTMAP":"",n.flatShading?"#define FLAT_SHADED":"",n.doubleSided?"#define DOUBLE_SIDED":"",n.flipSided?"#define FLIP_SIDED":"",n.shadowMapEnabled?"#define USE_SHADOWMAP":"",n.shadowMapEnabled?"#define "+l:"",n.premultipliedAlpha?"#define PREMULTIPLIED_ALPHA":"",n.physicallyCorrectLights?"#define PHYSICALLY_CORRECT_LIGHTS":"",n.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",n.logarithmicDepthBuffer&&n.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"",(n.extensionShaderTextureLOD||n.envMap)&&n.rendererExtensionShaderTextureLod?"#define TEXTURE_LOD_EXT":"","uniform mat4 viewMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;",0!==n.toneMapping?"#define TONE_MAPPING":"",0!==n.toneMapping?Tn.tonemapping_pars_fragment:"",0!==n.toneMapping?Ki("toneMapping",n.toneMapping):"",n.dithering?"#define DITHERING":"",Tn.encodings_pars_fragment,n.map?Ji("mapTexelToLinear",n.mapEncoding):"",n.matcap?Ji("matcapTexelToLinear",n.matcapEncoding):"",n.envMap?Ji("envMapTexelToLinear",n.envMapEncoding):"",n.emissiveMap?Ji("emissiveMapTexelToLinear",n.emissiveMapEncoding):"",n.lightMap?Ji("lightMapTexelToLinear",n.lightMapEncoding):"",Qi("linearToOutputTexel",n.outputEncoding),n.depthPacking?"#define DEPTH_PACKING "+n.depthPacking:"","\n"].filter($i).join("\n")),a=ir(a),a=tr(a,n),a=er(a,n),o=ir(o),o=tr(o,n),o=er(o,n),a=or(a),o=or(o),n.isWebGL2&&!0!==n.isRawShaderMaterial&&(y="#version 300 es\n",g=["#define attribute in","#define varying out","#define texture2D texture"].join("\n")+"\n"+g,v=["#define varying in",n.glslVersion===D?"":"out highp vec4 pc_fragColor;",n.glslVersion===D?"":"#define gl_FragColor pc_fragColor","#define gl_FragDepthEXT gl_FragDepth","#define texture2D texture","#define textureCube texture","#define texture2DProj textureProj","#define texture2DLodEXT textureLod","#define texture2DProjLodEXT textureProjLod","#define textureCubeLodEXT textureLod","#define texture2DGradEXT textureGrad","#define texture2DProjGradEXT textureProjGrad","#define textureCubeGradEXT textureGrad"].join("\n")+"\n"+v);const x=y+v+o,_=qi(r,35633,y+g+a),w=qi(r,35632,x);if(r.attachShader(f,_),r.attachShader(f,w),void 0!==n.index0AttributeName?r.bindAttribLocation(f,0,n.index0AttributeName):!0===n.morphTargets&&r.bindAttribLocation(f,0,"position"),r.linkProgram(f),t.debug.checkShaderErrors){const t=r.getProgramInfoLog(f).trim(),e=r.getShaderInfoLog(_).trim(),n=r.getShaderInfoLog(w).trim();let i=!0,s=!0;if(!1===r.getProgramParameter(f,35714)){i=!1;const e=Zi(r,_,"vertex"),n=Zi(r,w,"fragment");console.error("THREE.WebGLProgram: shader error: ",r.getError(),"35715",r.getProgramParameter(f,35715),"gl.getProgramInfoLog",t,e,n)}else""!==t?console.warn("THREE.WebGLProgram: gl.getProgramInfoLog()",t):""!==e&&""!==n||(s=!1);s&&(this.diagnostics={runnable:i,programLog:t,vertexShader:{log:e,prefix:g},fragmentShader:{log:n,prefix:v}})}let M,b;return r.deleteShader(_),r.deleteShader(w),this.getUniforms=function(){return void 0===M&&(M=new ji(r,f)),M},this.getAttributes=function(){return void 0===b&&(b=function(t,e){const n={},i=t.getProgramParameter(e,35721);for(let r=0;r0,maxBones:M,useVertexTexture:c,morphTargets:r.morphTargets,morphNormals:r.morphNormals,numDirLights:a.directional.length,numPointLights:a.point.length,numSpotLights:a.spot.length,numRectAreaLights:a.rectArea.length,numHemiLights:a.hemi.length,numDirLightShadows:a.directionalShadowMap.length,numPointLightShadows:a.pointShadowMap.length,numSpotLightShadows:a.spotShadowMap.length,numClippingPlanes:s.numPlanes,numClipIntersection:s.numIntersection,dithering:r.dithering,shadowMapEnabled:t.shadowMap.enabled&&m.length>0,shadowMapType:t.shadowMap.type,toneMapping:r.toneMapped?t.toneMapping:0,physicallyCorrectLights:t.physicallyCorrectLights,premultipliedAlpha:r.premultipliedAlpha,alphaTest:r.alphaTest,doubleSided:2===r.side,flipSided:1===r.side,depthPacking:void 0!==r.depthPacking&&r.depthPacking,index0AttributeName:r.index0AttributeName,extensionDerivatives:r.extensions&&r.extensions.derivatives,extensionFragDepth:r.extensions&&r.extensions.fragDepth,extensionDrawBuffers:r.extensions&&r.extensions.drawBuffers,extensionShaderTextureLOD:r.extensions&&r.extensions.shaderTextureLOD,rendererExtensionFragDepth:o||n.has("EXT_frag_depth"),rendererExtensionDrawBuffers:o||n.has("WEBGL_draw_buffers"),rendererExtensionShaderTextureLod:o||n.has("EXT_shader_texture_lod"),customProgramCacheKey:r.customProgramCacheKey()}},getProgramCacheKey:function(e){const n=[];if(e.shaderID?n.push(e.shaderID):(n.push(e.fragmentShader),n.push(e.vertexShader)),void 0!==e.defines)for(const t in e.defines)n.push(t),n.push(e.defines[t]);if(!1===e.isRawShaderMaterial){for(let t=0;t0?r.push(h):!0===n.transparent?s.push(h):i.push(h)},unshift:function(t,e,n,a,l,c){const h=o(t,e,n,a,l,c);n.transmission>0?r.unshift(h):!0===n.transparent?s.unshift(h):i.unshift(h)},finish:function(){for(let t=n,i=e.length;t1&&i.sort(t||mr),r.length>1&&r.sort(e||fr),s.length>1&&s.sort(e||fr)}}}function vr(t){let e=new WeakMap;return{get:function(n,i){let r;return!1===e.has(n)?(r=new gr(t),e.set(n,[r])):i>=e.get(n).length?(r=new gr(t),e.get(n).push(r)):r=e.get(n)[i],r},dispose:function(){e=new WeakMap}}}function yr(){const t={};return{get:function(e){if(void 0!==t[e.id])return t[e.id];let n;switch(e.type){case"DirectionalLight":n={direction:new $,color:new we};break;case"SpotLight":n={position:new $,direction:new $,color:new we,distance:0,coneCos:0,penumbraCos:0,decay:0};break;case"PointLight":n={position:new $,color:new we,distance:0,decay:0};break;case"HemisphereLight":n={direction:new $,skyColor:new we,groundColor:new we};break;case"RectAreaLight":n={color:new we,position:new $,halfWidth:new $,halfHeight:new $}}return t[e.id]=n,n}}}let xr=0;function _r(t,e){return(e.castShadow?1:0)-(t.castShadow?1:0)}function wr(t,e){const n=new yr,i=function(){const t={};return{get:function(e){if(void 0!==t[e.id])return t[e.id];let n;switch(e.type){case"DirectionalLight":case"SpotLight":n={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new k};break;case"PointLight":n={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new k,shadowCameraNear:1,shadowCameraFar:1e3}}return t[e.id]=n,n}}}(),r={version:0,hash:{directionalLength:-1,pointLength:-1,spotLength:-1,rectAreaLength:-1,hemiLength:-1,numDirectionalShadows:-1,numPointShadows:-1,numSpotShadows:-1},ambient:[0,0,0],probe:[],directional:[],directionalShadow:[],directionalShadowMap:[],directionalShadowMatrix:[],spot:[],spotShadow:[],spotShadowMap:[],spotShadowMatrix:[],rectArea:[],rectAreaLTC1:null,rectAreaLTC2:null,point:[],pointShadow:[],pointShadowMap:[],pointShadowMatrix:[],hemi:[]};for(let t=0;t<9;t++)r.probe.push(new $);const s=new $,a=new Rt,o=new Rt;return{setup:function(s){let a=0,o=0,l=0;for(let t=0;t<9;t++)r.probe[t].set(0,0,0);let c=0,h=0,u=0,d=0,p=0,m=0,f=0,g=0;s.sort(_r);for(let t=0,e=s.length;t0&&(e.isWebGL2||!0===t.has("OES_texture_float_linear")?(r.rectAreaLTC1=En.LTC_FLOAT_1,r.rectAreaLTC2=En.LTC_FLOAT_2):!0===t.has("OES_texture_half_float_linear")?(r.rectAreaLTC1=En.LTC_HALF_1,r.rectAreaLTC2=En.LTC_HALF_2):console.error("THREE.WebGLRenderer: Unable to use RectAreaLight. Missing WebGL extensions.")),r.ambient[0]=a,r.ambient[1]=o,r.ambient[2]=l;const v=r.hash;v.directionalLength===c&&v.pointLength===h&&v.spotLength===u&&v.rectAreaLength===d&&v.hemiLength===p&&v.numDirectionalShadows===m&&v.numPointShadows===f&&v.numSpotShadows===g||(r.directional.length=c,r.spot.length=u,r.rectArea.length=d,r.point.length=h,r.hemi.length=p,r.directionalShadow.length=m,r.directionalShadowMap.length=m,r.pointShadow.length=f,r.pointShadowMap.length=f,r.spotShadow.length=g,r.spotShadowMap.length=g,r.directionalShadowMatrix.length=m,r.pointShadowMatrix.length=f,r.spotShadowMatrix.length=g,v.directionalLength=c,v.pointLength=h,v.spotLength=u,v.rectAreaLength=d,v.hemiLength=p,v.numDirectionalShadows=m,v.numPointShadows=f,v.numSpotShadows=g,r.version=xr++)},setupView:function(t,e){let n=0,i=0,l=0,c=0,h=0;const u=e.matrixWorldInverse;for(let e=0,d=t.length;e=n.get(i).length?(s=new Mr(t,e),n.get(i).push(s)):s=n.get(i)[r],s},dispose:function(){n=new WeakMap}}}class Sr extends me{constructor(t){super(),this.type="MeshDepthMaterial",this.depthPacking=3200,this.morphTargets=!1,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.setValues(t)}copy(t){return super.copy(t),this.depthPacking=t.depthPacking,this.morphTargets=t.morphTargets,this.map=t.map,this.alphaMap=t.alphaMap,this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this.wireframe=t.wireframe,this.wireframeLinewidth=t.wireframeLinewidth,this}}Sr.prototype.isMeshDepthMaterial=!0;class Tr extends me{constructor(t){super(),this.type="MeshDistanceMaterial",this.referencePosition=new $,this.nearDistance=1,this.farDistance=1e3,this.morphTargets=!1,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.fog=!1,this.setValues(t)}copy(t){return super.copy(t),this.referencePosition.copy(t.referencePosition),this.nearDistance=t.nearDistance,this.farDistance=t.farDistance,this.morphTargets=t.morphTargets,this.map=t.map,this.alphaMap=t.alphaMap,this.displacementMap=t.displacementMap,this.displacementScale=t.displacementScale,this.displacementBias=t.displacementBias,this}}Tr.prototype.isMeshDistanceMaterial=!0;function Er(t,e,n){let i=new wn;const r=new k,s=new k,a=new Z,c=[],h=[],u={},d=n.maxTextureSize,p={0:1,1:0,2:2},m=new ln({defines:{SAMPLE_RATE:2/8,HALF_SAMPLE_RATE:1/8},uniforms:{shadow_pass:{value:null},resolution:{value:new k},radius:{value:4}},vertexShader:"void main() {\n\tgl_Position = vec4( position, 1.0 );\n}",fragmentShader:"uniform sampler2D shadow_pass;\nuniform vec2 resolution;\nuniform float radius;\n#include \nvoid main() {\n\tfloat mean = 0.0;\n\tfloat squared_mean = 0.0;\n\tfloat depth = unpackRGBAToDepth( texture2D( shadow_pass, ( gl_FragCoord.xy ) / resolution ) );\n\tfor ( float i = -1.0; i < 1.0 ; i += SAMPLE_RATE) {\n\t\t#ifdef HORIZONTAL_PASS\n\t\t\tvec2 distribution = unpackRGBATo2Half( texture2D( shadow_pass, ( gl_FragCoord.xy + vec2( i, 0.0 ) * radius ) / resolution ) );\n\t\t\tmean += distribution.x;\n\t\t\tsquared_mean += distribution.y * distribution.y + distribution.x * distribution.x;\n\t\t#else\n\t\t\tfloat depth = unpackRGBAToDepth( texture2D( shadow_pass, ( gl_FragCoord.xy + vec2( 0.0, i ) * radius ) / resolution ) );\n\t\t\tmean += depth;\n\t\t\tsquared_mean += depth * depth;\n\t\t#endif\n\t}\n\tmean = mean * HALF_SAMPLE_RATE;\n\tsquared_mean = squared_mean * HALF_SAMPLE_RATE;\n\tfloat std_dev = sqrt( squared_mean - mean * mean );\n\tgl_FragColor = pack2HalfToRGBA( vec2( mean, std_dev ) );\n}"}),f=m.clone();f.defines.HORIZONTAL_PASS=1;const g=new Oe;g.setAttribute("position",new Te(new Float32Array([-1,-1,.5,3,-1,.5,-1,3,.5]),3));const y=new en(g,m),x=this;function _(n,i){const r=e.update(y);m.uniforms.shadow_pass.value=n.map.texture,m.uniforms.resolution.value=n.mapSize,m.uniforms.radius.value=n.radius,t.setRenderTarget(n.mapPass),t.clear(),t.renderBufferDirect(i,null,r,m,y,null),f.uniforms.shadow_pass.value=n.mapPass.texture,f.uniforms.resolution.value=n.mapSize,f.uniforms.radius.value=n.radius,t.setRenderTarget(n.map),t.clear(),t.renderBufferDirect(i,null,r,f,y,null)}function w(t){const e=t<<0;let n=c[e];return void 0===n&&(n=new Sr({depthPacking:3201,morphTargets:t}),c[e]=n),n}function M(t){const e=t<<0;let n=h[e];return void 0===n&&(n=new Tr({morphTargets:t}),h[e]=n),n}function b(e,n,i,r,s,a,o){let l=null,c=w,h=e.customDepthMaterial;if(!0===r.isPointLight&&(c=M,h=e.customDistanceMaterial),void 0===h){let t=!1;!0===i.morphTargets&&(t=n.morphAttributes&&n.morphAttributes.position&&n.morphAttributes.position.length>0),l=c(t)}else l=h;if(t.localClippingEnabled&&!0===i.clipShadows&&0!==i.clippingPlanes.length){const t=l.uuid,e=i.uuid;let n=u[t];void 0===n&&(n={},u[t]=n);let r=n[e];void 0===r&&(r=l.clone(),n[e]=r),l=r}return l.visible=i.visible,l.wireframe=i.wireframe,l.side=3===o?null!==i.shadowSide?i.shadowSide:i.side:null!==i.shadowSide?i.shadowSide:p[i.side],l.clipShadows=i.clipShadows,l.clippingPlanes=i.clippingPlanes,l.clipIntersection=i.clipIntersection,l.wireframeLinewidth=i.wireframeLinewidth,l.linewidth=i.linewidth,!0===r.isPointLight&&!0===l.isMeshDistanceMaterial&&(l.referencePosition.setFromMatrixPosition(r.matrixWorld),l.nearDistance=s,l.farDistance=a),l}function S(n,r,s,a,o){if(!1===n.visible)return;if(n.layers.test(r.layers)&&(n.isMesh||n.isLine||n.isPoints)&&(n.castShadow||n.receiveShadow&&3===o)&&(!n.frustumCulled||i.intersectsObject(n))){n.modelViewMatrix.multiplyMatrices(s.matrixWorldInverse,n.matrixWorld);const i=e.update(n),r=n.material;if(Array.isArray(r)){const e=i.groups;for(let l=0,c=e.length;ld||r.y>d)&&(r.x>d&&(s.x=Math.floor(d/f.x),r.x=s.x*f.x,p.mapSize.x=s.x),r.y>d&&(s.y=Math.floor(d/f.y),r.y=s.y*f.y,p.mapSize.y=s.y)),null===p.map&&!p.isPointLightShadow&&3===this.type){const t={minFilter:l,magFilter:l,format:v};p.map=new J(r.x,r.y,t),p.map.texture.name=u.name+".shadowMap",p.mapPass=new J(r.x,r.y,t),p.camera.updateProjectionMatrix()}if(null===p.map){const t={minFilter:o,magFilter:o,format:v};p.map=new J(r.x,r.y,t),p.map.texture.name=u.name+".shadowMap",p.camera.updateProjectionMatrix()}t.setRenderTarget(p.map),t.clear();const g=p.getViewportCount();for(let t=0;t=1):-1!==C.indexOf("OpenGL ES")&&(L=parseFloat(/^OpenGL ES (\d)/.exec(C)[1]),A=L>=2);let R=null,P={};const D=t.getParameter(3088),I=t.getParameter(2978),N=(new Z).fromArray(D),z=(new Z).fromArray(I);function F(e,n,i){const r=new Uint8Array(4),s=t.createTexture();t.bindTexture(e,s),t.texParameteri(e,10241,9728),t.texParameteri(e,10240,9728);for(let e=0;ei||t.height>i)&&(r=i/Math.max(t.width,t.height)),r<1||!0===e){if("undefined"!=typeof HTMLImageElement&&t instanceof HTMLImageElement||"undefined"!=typeof HTMLCanvasElement&&t instanceof HTMLCanvasElement||"undefined"!=typeof ImageBitmap&&t instanceof ImageBitmap){const i=e?G:Math.floor,s=i(r*t.width),a=i(r*t.height);void 0===L&&(L=R(s,a));const o=n?R(s,a):L;o.width=s,o.height=a;return o.getContext("2d").drawImage(t,0,0,s,a),console.warn("THREE.WebGLRenderer: Texture has been resized from ("+t.width+"x"+t.height+") to ("+s+"x"+a+")."),o}return"data"in t&&console.warn("THREE.WebGLRenderer: Image in DataTexture is too big ("+t.width+"x"+t.height+")."),t}return t}function D(t){return H(t.width)&&H(t.height)}function I(t,e){return t.generateMipmaps&&e&&t.minFilter!==o&&t.minFilter!==l}function N(e,n,r,s,a=1){t.generateMipmap(e);i.get(n).__maxMipLevel=Math.log2(Math.max(r,s,a))}function z(n,i,r){if(!1===M)return i;if(null!==n){if(void 0!==t[n])return t[n];console.warn("THREE.WebGLRenderer: Attempt to use non-existing WebGL internal format '"+n+"'")}let s=i;return 6403===i&&(5126===r&&(s=33326),5131===r&&(s=33325),5121===r&&(s=33321)),6407===i&&(5126===r&&(s=34837),5131===r&&(s=34843),5121===r&&(s=32849)),6408===i&&(5126===r&&(s=34836),5131===r&&(s=34842),5121===r&&(s=32856)),33325!==s&&33326!==s&&34842!==s&&34836!==s||e.get("EXT_color_buffer_float"),s}function F(t){return t===o||1004===t||1005===t?9728:9729}function O(e){const n=e.target;n.removeEventListener("dispose",O),function(e){const n=i.get(e);if(void 0===n.__webglInit)return;t.deleteTexture(n.__webglTexture),i.remove(e)}(n),n.isVideoTexture&&A.delete(n),w.memory.textures--}function B(e){const n=e.target;n.removeEventListener("dispose",B),function(e){const n=e.texture,r=i.get(e),s=i.get(n);if(!e)return;void 0!==s.__webglTexture&&(t.deleteTexture(s.__webglTexture),w.memory.textures--);e.depthTexture&&e.depthTexture.dispose();if(e.isWebGLCubeRenderTarget)for(let e=0;e<6;e++)t.deleteFramebuffer(r.__webglFramebuffer[e]),r.__webglDepthbuffer&&t.deleteRenderbuffer(r.__webglDepthbuffer[e]);else t.deleteFramebuffer(r.__webglFramebuffer),r.__webglDepthbuffer&&t.deleteRenderbuffer(r.__webglDepthbuffer),r.__webglMultisampledFramebuffer&&t.deleteFramebuffer(r.__webglMultisampledFramebuffer),r.__webglColorRenderbuffer&&t.deleteRenderbuffer(r.__webglColorRenderbuffer),r.__webglDepthRenderbuffer&&t.deleteRenderbuffer(r.__webglDepthRenderbuffer);if(e.isWebGLMultipleRenderTargets)for(let e=0,r=n.length;e0&&r.__version!==t.version){const n=t.image;if(void 0===n)console.warn("THREE.WebGLRenderer: Texture marked for update but image is undefined");else{if(!1!==n.complete)return void Y(r,t,e);console.warn("THREE.WebGLRenderer: Texture marked for update but image is incomplete")}}n.activeTexture(33984+e),n.bindTexture(3553,r.__webglTexture)}function V(e,r){const s=i.get(e);e.version>0&&s.__version!==e.version?function(e,i,r){if(6!==i.image.length)return;X(e,i),n.activeTexture(33984+r),n.bindTexture(34067,e.__webglTexture),t.pixelStorei(37440,i.flipY),t.pixelStorei(37441,i.premultiplyAlpha),t.pixelStorei(3317,i.unpackAlignment),t.pixelStorei(37443,0);const s=i&&(i.isCompressedTexture||i.image[0].isCompressedTexture),a=i.image[0]&&i.image[0].isDataTexture,o=[];for(let t=0;t<6;t++)o[t]=s||a?a?i.image[t].image:i.image[t]:P(i.image[t],!1,!0,S);const l=o[0],c=D(l)||M,h=x.convert(i.format),u=x.convert(i.type),d=z(i.internalFormat,h,u);let p;if(q(34067,i,c),s){for(let t=0;t<6;t++){p=o[t].mipmaps;for(let e=0;e1||i.get(r).__currentAnisotropy)&&(t.texParameterf(n,s.TEXTURE_MAX_ANISOTROPY_EXT,Math.min(r.anisotropy,h.getMaxAnisotropy())),i.get(r).__currentAnisotropy=r.anisotropy)}}function X(e,n){void 0===e.__webglInit&&(e.__webglInit=!0,n.addEventListener("dispose",O),e.__webglTexture=t.createTexture(),w.memory.textures++)}function Y(e,i,r){let a=3553;i.isDataTexture2DArray&&(a=35866),i.isDataTexture3D&&(a=32879),X(e,i),n.activeTexture(33984+r),n.bindTexture(a,e.__webglTexture),t.pixelStorei(37440,i.flipY),t.pixelStorei(37441,i.premultiplyAlpha),t.pixelStorei(3317,i.unpackAlignment),t.pixelStorei(37443,0);const c=function(t){return!M&&(t.wrapS!==s||t.wrapT!==s||t.minFilter!==o&&t.minFilter!==l)}(i)&&!1===D(i.image),h=P(i.image,c,!1,T),m=D(h)||M,w=x.convert(i.format);let b,S=x.convert(i.type),E=z(i.internalFormat,w,S);q(a,i,m);const A=i.mipmaps;if(i.isDepthTexture)E=6402,M?E=i.type===p?36012:i.type===d?33190:i.type===f?35056:33189:i.type===p&&console.error("WebGLRenderer: Floating point depth texture requires WebGL2."),i.format===y&&6402===E&&i.type!==u&&i.type!==d&&(console.warn("THREE.WebGLRenderer: Use UnsignedShortType or UnsignedIntType for DepthFormat DepthTexture."),i.type=u,S=x.convert(i.type)),i.format===_&&6402===E&&(E=34041,i.type!==f&&(console.warn("THREE.WebGLRenderer: Use UnsignedInt248Type for DepthStencilFormat DepthTexture."),i.type=f,S=x.convert(i.type))),n.texImage2D(3553,0,E,h.width,h.height,0,w,S,null);else if(i.isDataTexture)if(A.length>0&&m){for(let t=0,e=A.length;t0&&m){for(let t=0,e=A.length;t=b&&console.warn("THREE.WebGLTextures: Trying to use "+t+" texture units while this GPU supports only "+b),U+=1,t},this.resetTextureUnits=function(){U=0},this.setTexture2D=k,this.setTexture2DArray=function(t,e){const r=i.get(t);t.version>0&&r.__version!==t.version?Y(r,t,e):(n.activeTexture(33984+e),n.bindTexture(35866,r.__webglTexture))},this.setTexture3D=function(t,e){const r=i.get(t);t.version>0&&r.__version!==t.version?Y(r,t,e):(n.activeTexture(33984+e),n.bindTexture(32879,r.__webglTexture))},this.setTextureCube=V,this.setupRenderTarget=function(e){const r=e.texture,s=i.get(e),a=i.get(r);e.addEventListener("dispose",B),!0!==e.isWebGLMultipleRenderTargets&&(a.__webglTexture=t.createTexture(),a.__version=r.version,w.memory.textures++);const o=!0===e.isWebGLCubeRenderTarget,l=!0===e.isWebGLMultipleRenderTargets,c=!0===e.isWebGLMultisampleRenderTarget,u=r.isDataTexture3D||r.isDataTexture2DArray,d=D(e)||M;if(!M||r.format!==g||r.type!==p&&r.type!==m||(r.format=v,console.warn("THREE.WebGLRenderer: Rendering to textures with RGB format is not supported. Using RGBA format instead.")),o){s.__webglFramebuffer=[];for(let e=0;e<6;e++)s.__webglFramebuffer[e]=t.createFramebuffer()}else if(s.__webglFramebuffer=t.createFramebuffer(),l)if(h.drawBuffers){const n=e.texture;for(let e=0,r=n.length;eo+c?(l.inputState.pinching=!1,this.dispatchEvent({type:"pinchend",handedness:t.handedness,target:this})):!l.inputState.pinching&&a<=o-c&&(l.inputState.pinching=!0,this.dispatchEvent({type:"pinchstart",handedness:t.handedness,target:this}))}else null!==o&&t.gripSpace&&(r=e.getPose(t.gripSpace,n),null!==r&&(o.matrix.fromArray(r.transform.matrix),o.matrix.decompose(o.position,o.rotation,o.scale),r.linearVelocity?(o.hasLinearVelocity=!0,o.linearVelocity.copy(r.linearVelocity)):o.hasLinearVelocity=!1,r.angularVelocity?(o.hasAngularVelocity=!0,o.angularVelocity.copy(r.angularVelocity)):o.hasAngularVelocity=!1));return null!==a&&(a.visible=null!==i),null!==o&&(o.visible=null!==r),null!==l&&(l.visible=null!==s),this}}class Nr extends I{constructor(t,e){super();const n=this,i=t.state;let r=null,s=1,a=null,o="local-floor",l=null,c=null,h=null,u=null;const d=[],p=new Map,m=new hn;m.layers.enable(1),m.viewport=new Z;const f=new hn;f.layers.enable(2),f.viewport=new Z;const g=[m,f],v=new Rr;v.layers.enable(1),v.layers.enable(2);let y=null,x=null;function _(t){const e=p.get(t.inputSource);e&&e.dispatchEvent({type:t.type,data:t.inputSource})}function w(){p.forEach((function(t,e){t.disconnect(e)})),p.clear(),y=null,x=null,i.bindXRFramebuffer(null),t.setRenderTarget(t.getRenderTarget()),A.stop(),n.isPresenting=!1,n.dispatchEvent({type:"sessionend"})}function M(t){const e=r.inputSources;for(let t=0;t0&&(t.transmissionSamplerMap.value=i.texture,t.transmissionSamplerSize.value.set(i.width,i.height));t.thickness.value=e.thickness,e.thicknessMap&&(t.thicknessMap.value=e.thicknessMap);t.attenuationDistance.value=e.attenuationDistance,t.attenuationColor.value.copy(e.attenuationColor)}(t,i,a):n(t,i)):i.isMeshMatcapMaterial?(e(t,i),function(t,e){e.matcap&&(t.matcap.value=e.matcap);e.bumpMap&&(t.bumpMap.value=e.bumpMap,t.bumpScale.value=e.bumpScale,1===e.side&&(t.bumpScale.value*=-1));e.normalMap&&(t.normalMap.value=e.normalMap,t.normalScale.value.copy(e.normalScale),1===e.side&&t.normalScale.value.negate());e.displacementMap&&(t.displacementMap.value=e.displacementMap,t.displacementScale.value=e.displacementScale,t.displacementBias.value=e.displacementBias)}(t,i)):i.isMeshDepthMaterial?(e(t,i),function(t,e){e.displacementMap&&(t.displacementMap.value=e.displacementMap,t.displacementScale.value=e.displacementScale,t.displacementBias.value=e.displacementBias)}(t,i)):i.isMeshDistanceMaterial?(e(t,i),function(t,e){e.displacementMap&&(t.displacementMap.value=e.displacementMap,t.displacementScale.value=e.displacementScale,t.displacementBias.value=e.displacementBias);t.referencePosition.value.copy(e.referencePosition),t.nearDistance.value=e.nearDistance,t.farDistance.value=e.farDistance}(t,i)):i.isMeshNormalMaterial?(e(t,i),function(t,e){e.bumpMap&&(t.bumpMap.value=e.bumpMap,t.bumpScale.value=e.bumpScale,1===e.side&&(t.bumpScale.value*=-1));e.normalMap&&(t.normalMap.value=e.normalMap,t.normalScale.value.copy(e.normalScale),1===e.side&&t.normalScale.value.negate());e.displacementMap&&(t.displacementMap.value=e.displacementMap,t.displacementScale.value=e.displacementScale,t.displacementBias.value=e.displacementBias)}(t,i)):i.isLineBasicMaterial?(function(t,e){t.diffuse.value.copy(e.color),t.opacity.value=e.opacity}(t,i),i.isLineDashedMaterial&&function(t,e){t.dashSize.value=e.dashSize,t.totalSize.value=e.dashSize+e.gapSize,t.scale.value=e.scale}(t,i)):i.isPointsMaterial?function(t,e,n,i){t.diffuse.value.copy(e.color),t.opacity.value=e.opacity,t.size.value=e.size*n,t.scale.value=.5*i,e.map&&(t.map.value=e.map);e.alphaMap&&(t.alphaMap.value=e.alphaMap);let r;e.map?r=e.map:e.alphaMap&&(r=e.alphaMap);void 0!==r&&(!0===r.matrixAutoUpdate&&r.updateMatrix(),t.uvTransform.value.copy(r.matrix))}(t,i,r,s):i.isSpriteMaterial?function(t,e){t.diffuse.value.copy(e.color),t.opacity.value=e.opacity,t.rotation.value=e.rotation,e.map&&(t.map.value=e.map);e.alphaMap&&(t.alphaMap.value=e.alphaMap);let n;e.map?n=e.map:e.alphaMap&&(n=e.alphaMap);void 0!==n&&(!0===n.matrixAutoUpdate&&n.updateMatrix(),t.uvTransform.value.copy(n.matrix))}(t,i):i.isShadowMaterial?(t.color.value.copy(i.color),t.opacity.value=i.opacity):i.isShaderMaterial&&(i.uniformsNeedUpdate=!1)}}}function Fr(t={}){const e=void 0!==t.canvas?t.canvas:function(){const t=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");return t.style.display="block",t}(),n=void 0!==t.context?t.context:null,i=void 0!==t.alpha&&t.alpha,r=void 0===t.depth||t.depth,a=void 0===t.stencil||t.stencil,l=void 0!==t.antialias&&t.antialias,u=void 0===t.premultipliedAlpha||t.premultipliedAlpha,d=void 0!==t.preserveDrawingBuffer&&t.preserveDrawingBuffer,f=void 0!==t.powerPreference?t.powerPreference:"default",g=void 0!==t.failIfMajorPerformanceCaveat&&t.failIfMajorPerformanceCaveat;let y=null,x=null;const _=[],w=[];this.domElement=e,this.debug={checkShaderErrors:!0},this.autoClear=!0,this.autoClearColor=!0,this.autoClearDepth=!0,this.autoClearStencil=!0,this.sortObjects=!0,this.clippingPlanes=[],this.localClippingEnabled=!1,this.gammaFactor=2,this.outputEncoding=L,this.physicallyCorrectLights=!1,this.toneMapping=0,this.toneMappingExposure=1;const M=this;let b=!1,S=0,T=0,E=null,A=-1,C=null;const R=new Z,P=new Z;let D=null,I=e.width,N=e.height,z=1,F=null,O=null;const B=new Z(0,0,I,N),U=new Z(0,0,I,N);let H=!1;const G=[],k=new wn;let V=!1,W=!1,j=null;const q=new Rt,X=new $,Y={background:null,fog:null,environment:null,overrideMaterial:null,isScene:!0};function K(){return null===E?z:1}let tt,et,nt,it,rt,st,at,ot,lt,ct,ht,ut,dt,pt,mt,ft,gt,vt,yt,xt,_t,wt,Mt=n;function bt(t,n){for(let i=0;i0&&zt(i,t,e),r.length>0&&function(t,e,n,i){if(null===j){const t=!0===l&&!0===et.isWebGL2;j=new(t?Q:J)(1024,1024,{generateMipmaps:!0,type:null!==_t.convert(m)?m:h,minFilter:c,magFilter:o,wrapS:s,wrapT:s})}const r=M.getRenderTarget();M.setRenderTarget(j),M.clear();const a=M.toneMapping;M.toneMapping=0,zt(t,n,i),M.toneMapping=a,st.updateMultisampleRenderTarget(j),st.updateRenderTargetMipmap(j),M.setRenderTarget(r),zt(e,n,i)}(i,r,t,e),a.length>0&&zt(a,t,e),null!==E&&(st.updateMultisampleRenderTarget(E),st.updateRenderTargetMipmap(E)),!0===t.isScene&&t.onAfterRender(M,t,e),nt.buffers.depth.setTest(!0),nt.buffers.depth.setMask(!0),nt.buffers.color.setMask(!0),nt.setPolygonOffset(!1),wt.resetDefaultState(),A=-1,C=null,w.pop(),x=w.length>0?w[w.length-1]:null,_.pop(),y=_.length>0?_[_.length-1]:null},this.getActiveCubeFace=function(){return S},this.getActiveMipmapLevel=function(){return T},this.getRenderTarget=function(){return E},this.setRenderTarget=function(t,e=0,n=0){E=t,S=e,T=n,t&&void 0===rt.get(t).__webglFramebuffer&&st.setupRenderTarget(t);let i=null,r=!1,s=!1;if(t){const n=t.texture;(n.isDataTexture3D||n.isDataTexture2DArray)&&(s=!0);const a=rt.get(t).__webglFramebuffer;t.isWebGLCubeRenderTarget?(i=a[e],r=!0):i=t.isWebGLMultisampleRenderTarget?rt.get(t).__webglMultisampledFramebuffer:a,R.copy(t.viewport),P.copy(t.scissor),D=t.scissorTest}else R.copy(B).multiplyScalar(z).floor(),P.copy(U).multiplyScalar(z).floor(),D=H;if(nt.bindFramebuffer(36160,i)&&et.drawBuffers){let e=!1;if(t)if(t.isWebGLMultipleRenderTargets){const n=t.texture;if(G.length!==n.length||36064!==G[0]){for(let t=0,e=n.length;t=0&&e<=t.width-i&&n>=0&&n<=t.height-r&&Mt.readPixels(e,n,i,r,_t.convert(o),_t.convert(l),s):console.error("THREE.WebGLRenderer.readRenderTargetPixels: readPixels from renderTarget failed. Framebuffer not complete.")}finally{const t=null!==E?rt.get(E).__webglFramebuffer:null;nt.bindFramebuffer(36160,t)}}},this.copyFramebufferToTexture=function(t,e,n=0){const i=Math.pow(2,-n),r=Math.floor(e.image.width*i),s=Math.floor(e.image.height*i);let a=_t.convert(e.format);et.isWebGL2&&(6407===a&&(a=32849),6408===a&&(a=32856)),st.setTexture2D(e,0),Mt.copyTexImage2D(3553,n,a,t.x,t.y,r,s,0),nt.unbindTexture()},this.copyTextureToTexture=function(t,e,n,i=0){const r=e.image.width,s=e.image.height,a=_t.convert(n.format),o=_t.convert(n.type);st.setTexture2D(n,0),Mt.pixelStorei(37440,n.flipY),Mt.pixelStorei(37441,n.premultiplyAlpha),Mt.pixelStorei(3317,n.unpackAlignment),e.isDataTexture?Mt.texSubImage2D(3553,i,t.x,t.y,r,s,a,o,e.image.data):e.isCompressedTexture?Mt.compressedTexSubImage2D(3553,i,t.x,t.y,e.mipmaps[0].width,e.mipmaps[0].height,a,e.mipmaps[0].data):Mt.texSubImage2D(3553,i,t.x,t.y,a,o,e.image),0===i&&n.generateMipmaps&&Mt.generateMipmap(3553),nt.unbindTexture()},this.copyTextureToTexture3D=function(t,e,n,i,r=0){if(M.isWebGL1Renderer)return void console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: can only be used with WebGL2.");const s=t.max.x-t.min.x+1,a=t.max.y-t.min.y+1,o=t.max.z-t.min.z+1,l=_t.convert(i.format),c=_t.convert(i.type);let h;if(i.isDataTexture3D)st.setTexture3D(i,0),h=32879;else{if(!i.isDataTexture2DArray)return void console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: only supports THREE.DataTexture3D and THREE.DataTexture2DArray.");st.setTexture2DArray(i,0),h=35866}Mt.pixelStorei(37440,i.flipY),Mt.pixelStorei(37441,i.premultiplyAlpha),Mt.pixelStorei(3317,i.unpackAlignment);const u=Mt.getParameter(3314),d=Mt.getParameter(32878),p=Mt.getParameter(3316),m=Mt.getParameter(3315),f=Mt.getParameter(32877),g=n.isCompressedTexture?n.mipmaps[0]:n.image;Mt.pixelStorei(3314,g.width),Mt.pixelStorei(32878,g.height),Mt.pixelStorei(3316,t.min.x),Mt.pixelStorei(3315,t.min.y),Mt.pixelStorei(32877,t.min.z),n.isDataTexture||n.isDataTexture3D?Mt.texSubImage3D(h,r,e.x,e.y,e.z,s,a,o,l,c,g.data):n.isCompressedTexture?(console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: untested support for compressed srcTexture."),Mt.compressedTexSubImage3D(h,r,e.x,e.y,e.z,s,a,o,l,g.data)):Mt.texSubImage3D(h,r,e.x,e.y,e.z,s,a,o,l,c,g),Mt.pixelStorei(3314,u),Mt.pixelStorei(32878,d),Mt.pixelStorei(3316,p),Mt.pixelStorei(3315,m),Mt.pixelStorei(32877,f),0===r&&i.generateMipmaps&&Mt.generateMipmap(h),nt.unbindTexture()},this.initTexture=function(t){st.setTexture2D(t,0),nt.unbindTexture()},this.resetState=function(){S=0,T=0,E=null,nt.reset(),wt.reset()},"undefined"!=typeof __THREE_DEVTOOLS__&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}(class extends Fr{}).prototype.isWebGL1Renderer=!0;class Or extends ee{constructor(){super(),this.type="Scene",this.background=null,this.environment=null,this.fog=null,this.overrideMaterial=null,this.autoUpdate=!0,"undefined"!=typeof __THREE_DEVTOOLS__&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}copy(t,e){return super.copy(t,e),null!==t.background&&(this.background=t.background.clone()),null!==t.environment&&(this.environment=t.environment.clone()),null!==t.fog&&(this.fog=t.fog.clone()),null!==t.overrideMaterial&&(this.overrideMaterial=t.overrideMaterial.clone()),this.autoUpdate=t.autoUpdate,this.matrixAutoUpdate=t.matrixAutoUpdate,this}toJSON(t){const e=super.toJSON(t);return null!==this.fog&&(e.object.fog=this.fog.toJSON()),e}}Or.prototype.isScene=!0;class Br{constructor(t,e){this.array=t,this.stride=e,this.count=void 0!==t?t.length/e:0,this.usage=R,this.updateRange={offset:0,count:-1},this.version=0,this.uuid=O()}onUploadCallback(){}set needsUpdate(t){!0===t&&this.version++}setUsage(t){return this.usage=t,this}copy(t){return this.array=new t.array.constructor(t.array),this.count=t.count,this.stride=t.stride,this.usage=t.usage,this}copyAt(t,e,n){t*=this.stride,n*=e.stride;for(let i=0,r=this.stride;it.far||e.push({distance:o,point:Vr.clone(),uv:de.getUV(Vr,Zr,Jr,Qr,Kr,$r,ts,new k),face:null,object:this})}copy(t){return super.copy(t),void 0!==t.center&&this.center.copy(t.center),this.material=t.material,this}}).prototype.isSprite=!0;const ns=new $,is=new Z,rs=new Z,ss=new $,as=new Rt;class os extends en{constructor(t,e){super(t,e),this.type="SkinnedMesh",this.bindMode="attached",this.bindMatrix=new Rt,this.bindMatrixInverse=new Rt}copy(t){return super.copy(t),this.bindMode=t.bindMode,this.bindMatrix.copy(t.bindMatrix),this.bindMatrixInverse.copy(t.bindMatrixInverse),this.skeleton=t.skeleton,this}bind(t,e){this.skeleton=t,void 0===e&&(this.updateMatrixWorld(!0),this.skeleton.calculateInverses(),e=this.matrixWorld),this.bindMatrix.copy(e),this.bindMatrixInverse.copy(e).invert()}pose(){this.skeleton.pose()}normalizeSkinWeights(){const t=new Z,e=this.geometry.attributes.skinWeight;for(let n=0,i=e.count;no)continue;u.applyMatrix4(this.matrixWorld);const d=t.ray.origin.distanceTo(u);dt.far||e.push({distance:d,point:h.clone().applyMatrix4(this.matrixWorld),index:n,face:null,faceIndex:null,object:this})}}else{for(let n=Math.max(0,s.start),i=Math.min(r.count,s.start+s.count)-1;no)continue;u.applyMatrix4(this.matrixWorld);const i=t.ray.origin.distanceTo(u);it.far||e.push({distance:i,point:h.clone().applyMatrix4(this.matrixWorld),index:n,face:null,faceIndex:null,object:this})}}}else n.isGeometry&&console.error("THREE.Line.raycast() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")}updateMorphTargets(){const t=this.geometry;if(t.isBufferGeometry){const e=t.morphAttributes,n=Object.keys(e);if(n.length>0){const t=e[n[0]];if(void 0!==t){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let e=0,n=t.length;e0&&console.error("THREE.Line.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.")}}}ys.prototype.isLine=!0;const xs=new $,_s=new $;class ws extends ys{constructor(t,e){super(t,e),this.type="LineSegments"}computeLineDistances(){const t=this.geometry;if(t.isBufferGeometry)if(null===t.index){const e=t.attributes.position,n=[];for(let t=0,i=e.count;tr.far)return;s.push({distance:l,distanceToRay:Math.sqrt(o),point:n,index:e,face:null,object:a})}}(class extends ee{constructor(t=new Oe,e=new Ms){super(),this.type="Points",this.geometry=t,this.material=e,this.updateMorphTargets()}copy(t){return super.copy(t),this.material=t.material,this.geometry=t.geometry,this}raycast(t,e){const n=this.geometry,i=this.matrixWorld,r=t.params.Points.threshold,s=n.drawRange;if(null===n.boundingSphere&&n.computeBoundingSphere(),Ts.copy(n.boundingSphere),Ts.applyMatrix4(i),Ts.radius+=r,!1===t.ray.intersectsSphere(Ts))return;bs.copy(i).invert(),Ss.copy(t.ray).applyMatrix4(bs);const a=r/((this.scale.x+this.scale.y+this.scale.z)/3),o=a*a;if(n.isBufferGeometry){const r=n.index,a=n.attributes.position;if(null!==r){for(let n=Math.max(0,s.start),l=Math.min(r.count,s.start+s.count);n0){const t=e[n[0]];if(void 0!==t){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let e=0,n=t.length;e0&&console.error("THREE.Points.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.")}}}).prototype.isPoints=!0;(class extends X{constructor(t,e,n,i,r,s,a,o,c){super(t,e,n,i,r,s,a,o,c),this.format=void 0!==a?a:g,this.minFilter=void 0!==s?s:l,this.magFilter=void 0!==r?r:l,this.generateMipmaps=!1;const h=this;"requestVideoFrameCallback"in t&&t.requestVideoFrameCallback((function e(){h.needsUpdate=!0,t.requestVideoFrameCallback(e)}))}clone(){return new this.constructor(this.image).copy(this)}update(){const t=this.image;!1==="requestVideoFrameCallback"in t&&t.readyState>=t.HAVE_CURRENT_DATA&&(this.needsUpdate=!0)}}).prototype.isVideoTexture=!0;(class extends X{constructor(t,e,n,i,r,s,a,o,l,c,h,u){super(null,s,a,o,l,c,i,r,h,u),this.image={width:e,height:n},this.mipmaps=t,this.flipY=!1,this.generateMipmaps=!1}}).prototype.isCompressedTexture=!0;(class extends X{constructor(t,e,n,i,r,s,a,o,l){super(t,e,n,i,r,s,a,o,l),this.needsUpdate=!0}}).prototype.isCanvasTexture=!0;(class extends X{constructor(t,e,n,i,r,s,a,l,c,h){if((h=void 0!==h?h:y)!==y&&h!==_)throw new Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");void 0===n&&h===y&&(n=u),void 0===n&&h===_&&(n=f),super(null,i,r,s,a,l,h,n,c),this.image={width:t,height:e},this.magFilter=void 0!==a?a:o,this.minFilter=void 0!==l?l:o,this.flipY=!1,this.generateMipmaps=!1}}).prototype.isDepthTexture=!0;class Ls extends Oe{constructor(t=1,e=1,n=1,i=8,r=1,s=!1,a=0,o=2*Math.PI){super(),this.type="CylinderGeometry",this.parameters={radiusTop:t,radiusBottom:e,height:n,radialSegments:i,heightSegments:r,openEnded:s,thetaStart:a,thetaLength:o};const l=this;i=Math.floor(i),r=Math.floor(r);const c=[],h=[],u=[],d=[];let p=0;const m=[],f=n/2;let g=0;function v(n){const r=p,s=new k,m=new $;let v=0;const y=!0===n?t:e,x=!0===n?1:-1;for(let t=1;t<=i;t++)h.push(0,f*x,0),u.push(0,x,0),d.push(.5,.5),p++;const _=p;for(let t=0;t<=i;t++){const e=t/i*o+a,n=Math.cos(e),r=Math.sin(e);m.x=y*r,m.y=f*x,m.z=y*n,h.push(m.x,m.y,m.z),u.push(0,x,0),s.x=.5*n+.5,s.y=.5*r*x+.5,d.push(s.x,s.y),p++}for(let t=0;t0&&v(!0),e>0&&v(!1)),this.setIndex(c),this.setAttribute("position",new Le(h,3)),this.setAttribute("normal",new Le(u,3)),this.setAttribute("uv",new Le(d,2))}static fromJSON(t){return new Ls(t.radiusTop,t.radiusBottom,t.height,t.radialSegments,t.heightSegments,t.openEnded,t.thetaStart,t.thetaLength)}}new $,new $,new $,new de;class Cs{constructor(){this.type="Curve",this.arcLengthDivisions=200}getPoint(){return console.warn("THREE.Curve: .getPoint() not implemented."),null}getPointAt(t,e){const n=this.getUtoTmapping(t);return this.getPoint(n,e)}getPoints(t=5){const e=[];for(let n=0;n<=t;n++)e.push(this.getPoint(n/t));return e}getSpacedPoints(t=5){const e=[];for(let n=0;n<=t;n++)e.push(this.getPointAt(n/t));return e}getLength(){const t=this.getLengths();return t[t.length-1]}getLengths(t=this.arcLengthDivisions){if(this.cacheArcLengths&&this.cacheArcLengths.length===t+1&&!this.needsUpdate)return this.cacheArcLengths;this.needsUpdate=!1;const e=[];let n,i=this.getPoint(0),r=0;e.push(0);for(let s=1;s<=t;s++)n=this.getPoint(s/t),r+=n.distanceTo(i),e.push(r),i=n;return this.cacheArcLengths=e,e}updateArcLengths(){this.needsUpdate=!0,this.getLengths()}getUtoTmapping(t,e){const n=this.getLengths();let i=0;const r=n.length;let s;s=e||t*n[r-1];let a,o=0,l=r-1;for(;o<=l;)if(i=Math.floor(o+(l-o)/2),a=n[i]-s,a<0)o=i+1;else{if(!(a>0)){l=i;break}l=i-1}if(i=l,n[i]===s)return i/(r-1);const c=n[i];return(i+(s-c)/(n[i+1]-c))/(r-1)}getTangent(t,e){const n=1e-4;let i=t-n,r=t+n;i<0&&(i=0),r>1&&(r=1);const s=this.getPoint(i),a=this.getPoint(r),o=e||(s.isVector2?new k:new $);return o.copy(a).sub(s).normalize(),o}getTangentAt(t,e){const n=this.getUtoTmapping(t);return this.getTangent(n,e)}computeFrenetFrames(t,e){const n=new $,i=[],r=[],s=[],a=new $,o=new Rt;for(let e=0;e<=t;e++){const n=e/t;i[e]=this.getTangentAt(n,new $),i[e].normalize()}r[0]=new $,s[0]=new $;let l=Number.MAX_VALUE;const c=Math.abs(i[0].x),h=Math.abs(i[0].y),u=Math.abs(i[0].z);c<=l&&(l=c,n.set(1,0,0)),h<=l&&(l=h,n.set(0,1,0)),u<=l&&n.set(0,0,1),a.crossVectors(i[0],n).normalize(),r[0].crossVectors(i[0],a),s[0].crossVectors(i[0],r[0]);for(let e=1;e<=t;e++){if(r[e]=r[e-1].clone(),s[e]=s[e-1].clone(),a.crossVectors(i[e-1],i[e]),a.length()>Number.EPSILON){a.normalize();const t=Math.acos(B(i[e-1].dot(i[e]),-1,1));r[e].applyMatrix4(o.makeRotationAxis(a,t))}s[e].crossVectors(i[e],r[e])}if(!0===e){let e=Math.acos(B(r[0].dot(r[t]),-1,1));e/=t,i[0].dot(a.crossVectors(r[0],r[t]))>0&&(e=-e);for(let n=1;n<=t;n++)r[n].applyMatrix4(o.makeRotationAxis(i[n],e*n)),s[n].crossVectors(i[n],r[n])}return{tangents:i,normals:r,binormals:s}}clone(){return(new this.constructor).copy(this)}copy(t){return this.arcLengthDivisions=t.arcLengthDivisions,this}toJSON(){const t={metadata:{version:4.5,type:"Curve",generator:"Curve.toJSON"}};return t.arcLengthDivisions=this.arcLengthDivisions,t.type=this.type,t}fromJSON(t){return this.arcLengthDivisions=t.arcLengthDivisions,this}}class Rs extends Cs{constructor(t=0,e=0,n=1,i=1,r=0,s=2*Math.PI,a=!1,o=0){super(),this.type="EllipseCurve",this.aX=t,this.aY=e,this.xRadius=n,this.yRadius=i,this.aStartAngle=r,this.aEndAngle=s,this.aClockwise=a,this.aRotation=o}getPoint(t,e){const n=e||new k,i=2*Math.PI;let r=this.aEndAngle-this.aStartAngle;const s=Math.abs(r)i;)r-=i;r0?0:(Math.floor(Math.abs(l)/r)+1)*r:0===c&&l===r-1&&(l=r-2,c=1),this.closed||l>0?a=i[(l-1)%r]:(Is.subVectors(i[0],i[1]).add(i[0]),a=Is);const h=i[l%r],u=i[(l+1)%r];if(this.closed||l+2i.length-2?i.length-1:s+1],h=i[s>i.length-3?i.length-1:s+2];return n.set(Bs(a,o.x,l.x,c.x,h.x),Bs(a,o.y,l.y,c.y,h.y)),n}copy(t){super.copy(t),this.points=[];for(let e=0,n=t.points.length;e80*n){o=c=t[0],l=h=t[1];for(let e=n;ec&&(c=u),d>h&&(h=d);p=Math.max(c-o,h-l),p=0!==p?1/p:0}return Qs(s,a,n,o,l,p),a};function Zs(t,e,n,i,r){let s,a;if(r===function(t,e,n,i){let r=0;for(let s=e,a=n-i;s0)for(s=e;s=e;s-=i)a=ga(s,t[s],t[s+1],a);return a&&ha(a,a.next)&&(va(a),a=a.next),a}function Js(t,e){if(!t)return t;e||(e=t);let n,i=t;do{if(n=!1,i.steiner||!ha(i,i.next)&&0!==ca(i.prev,i,i.next))i=i.next;else{if(va(i),i=e=i.prev,i===i.next)break;n=!0}}while(n||i!==e);return e}function Qs(t,e,n,i,r,s,a){if(!t)return;!a&&s&&function(t,e,n,i){let r=t;do{null===r.z&&(r.z=sa(r.x,r.y,e,n,i)),r.prevZ=r.prev,r.nextZ=r.next,r=r.next}while(r!==t);r.prevZ.nextZ=null,r.prevZ=null,function(t){let e,n,i,r,s,a,o,l,c=1;do{for(n=t,t=null,s=null,a=0;n;){for(a++,i=n,o=0,e=0;e0||l>0&&i;)0!==o&&(0===l||!i||n.z<=i.z)?(r=n,n=n.nextZ,o--):(r=i,i=i.nextZ,l--),s?s.nextZ=r:t=r,r.prevZ=s,s=r;n=i}s.nextZ=null,c*=2}while(a>1)}(r)}(t,i,r,s);let o,l,c=t;for(;t.prev!==t.next;)if(o=t.prev,l=t.next,s?$s(t,i,r,s):Ks(t))e.push(o.i/n),e.push(t.i/n),e.push(l.i/n),va(t),t=l.next,c=l.next;else if((t=l)===c){a?1===a?Qs(t=ta(Js(t),e,n),e,n,i,r,s,2):2===a&&ea(t,e,n,i,r,s):Qs(Js(t),e,n,i,r,s,1);break}}function Ks(t){const e=t.prev,n=t,i=t.next;if(ca(e,n,i)>=0)return!1;let r=t.next.next;for(;r!==t.prev;){if(oa(e.x,e.y,n.x,n.y,i.x,i.y,r.x,r.y)&&ca(r.prev,r,r.next)>=0)return!1;r=r.next}return!0}function $s(t,e,n,i){const r=t.prev,s=t,a=t.next;if(ca(r,s,a)>=0)return!1;const o=r.xs.x?r.x>a.x?r.x:a.x:s.x>a.x?s.x:a.x,h=r.y>s.y?r.y>a.y?r.y:a.y:s.y>a.y?s.y:a.y,u=sa(o,l,e,n,i),d=sa(c,h,e,n,i);let p=t.prevZ,m=t.nextZ;for(;p&&p.z>=u&&m&&m.z<=d;){if(p!==t.prev&&p!==t.next&&oa(r.x,r.y,s.x,s.y,a.x,a.y,p.x,p.y)&&ca(p.prev,p,p.next)>=0)return!1;if(p=p.prevZ,m!==t.prev&&m!==t.next&&oa(r.x,r.y,s.x,s.y,a.x,a.y,m.x,m.y)&&ca(m.prev,m,m.next)>=0)return!1;m=m.nextZ}for(;p&&p.z>=u;){if(p!==t.prev&&p!==t.next&&oa(r.x,r.y,s.x,s.y,a.x,a.y,p.x,p.y)&&ca(p.prev,p,p.next)>=0)return!1;p=p.prevZ}for(;m&&m.z<=d;){if(m!==t.prev&&m!==t.next&&oa(r.x,r.y,s.x,s.y,a.x,a.y,m.x,m.y)&&ca(m.prev,m,m.next)>=0)return!1;m=m.nextZ}return!0}function ta(t,e,n){let i=t;do{const r=i.prev,s=i.next.next;!ha(r,s)&&ua(r,i,i.next,s)&&ma(r,s)&&ma(s,r)&&(e.push(r.i/n),e.push(i.i/n),e.push(s.i/n),va(i),va(i.next),i=t=s),i=i.next}while(i!==t);return Js(i)}function ea(t,e,n,i,r,s){let a=t;do{let t=a.next.next;for(;t!==a.prev;){if(a.i!==t.i&&la(a,t)){let o=fa(a,t);return a=Js(a,a.next),o=Js(o,o.next),Qs(a,e,n,i,r,s),void Qs(o,e,n,i,r,s)}t=t.next}a=a.next}while(a!==t)}function na(t,e){return t.x-e.x}function ia(t,e){if(e=function(t,e){let n=e;const i=t.x,r=t.y;let s,a=-1/0;do{if(r<=n.y&&r>=n.next.y&&n.next.y!==n.y){const t=n.x+(r-n.y)*(n.next.x-n.x)/(n.next.y-n.y);if(t<=i&&t>a){if(a=t,t===i){if(r===n.y)return n;if(r===n.next.y)return n.next}s=n.x=n.x&&n.x>=l&&i!==n.x&&oa(rs.x||n.x===s.x&&ra(s,n)))&&(s=n,u=h)),n=n.next}while(n!==o);return s}(t,e)){const n=fa(e,t);Js(e,e.next),Js(n,n.next)}}function ra(t,e){return ca(t.prev,t,e.prev)<0&&ca(e.next,t,t.next)<0}function sa(t,e,n,i,r){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=32767*(t-n)*r)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-i)*r)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function aa(t){let e=t,n=t;do{(e.x=0&&(t-a)*(i-o)-(n-a)*(e-o)>=0&&(n-a)*(s-o)-(r-a)*(i-o)>=0}function la(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!function(t,e){let n=t;do{if(n.i!==t.i&&n.next.i!==t.i&&n.i!==e.i&&n.next.i!==e.i&&ua(n,n.next,t,e))return!0;n=n.next}while(n!==t);return!1}(t,e)&&(ma(t,e)&&ma(e,t)&&function(t,e){let n=t,i=!1;const r=(t.x+e.x)/2,s=(t.y+e.y)/2;do{n.y>s!=n.next.y>s&&n.next.y!==n.y&&r<(n.next.x-n.x)*(s-n.y)/(n.next.y-n.y)+n.x&&(i=!i),n=n.next}while(n!==t);return i}(t,e)&&(ca(t.prev,t,e.prev)||ca(t,e.prev,e))||ha(t,e)&&ca(t.prev,t,t.next)>0&&ca(e.prev,e,e.next)>0)}function ca(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)}function ha(t,e){return t.x===e.x&&t.y===e.y}function ua(t,e,n,i){const r=pa(ca(t,e,n)),s=pa(ca(t,e,i)),a=pa(ca(n,i,t)),o=pa(ca(n,i,e));return r!==s&&a!==o||(!(0!==r||!da(t,n,e))||(!(0!==s||!da(t,i,e))||(!(0!==a||!da(n,t,i))||!(0!==o||!da(n,e,i)))))}function da(t,e,n){return e.x<=Math.max(t.x,n.x)&&e.x>=Math.min(t.x,n.x)&&e.y<=Math.max(t.y,n.y)&&e.y>=Math.min(t.y,n.y)}function pa(t){return t>0?1:t<0?-1:0}function ma(t,e){return ca(t.prev,t,t.next)<0?ca(t,e,t.next)>=0&&ca(t,t.prev,e)>=0:ca(t,e,t.prev)<0||ca(t,t.next,e)<0}function fa(t,e){const n=new ya(t.i,t.x,t.y),i=new ya(e.i,e.x,e.y),r=t.next,s=e.prev;return t.next=e,e.prev=t,n.next=r,r.prev=n,i.next=n,n.prev=i,s.next=i,i.prev=s,i}function ga(t,e,n,i){const r=new ya(t,e,n);return i?(r.next=i.next,r.prev=i,i.next.prev=r,i.next=r):(r.prev=r,r.next=r),r}function va(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function ya(t,e,n){this.i=t,this.x=e,this.y=n,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}class xa{static area(t){const e=t.length;let n=0;for(let i=e-1,r=0;r2&&t[e-1].equals(t[0])&&t.pop()}function wa(t,e){for(let n=0;nNumber.EPSILON){const u=Math.sqrt(h),d=Math.sqrt(l*l+c*c),p=e.x-o/u,m=e.y+a/u,f=((n.x-c/d-p)*c-(n.y+l/d-m)*l)/(a*c-o*l);i=p+a*f-t.x,r=m+o*f-t.y;const g=i*i+r*r;if(g<=2)return new k(i,r);s=Math.sqrt(g/2)}else{let t=!1;a>Number.EPSILON?l>Number.EPSILON&&(t=!0):a<-Number.EPSILON?l<-Number.EPSILON&&(t=!0):Math.sign(o)===Math.sign(c)&&(t=!0),t?(i=-o,r=a,s=Math.sqrt(h)):(i=a,r=o,s=Math.sqrt(h/2))}return new k(i/s,r/s)}const P=[];for(let t=0,e=E.length,n=e-1,i=t+1;t=0;t--){const e=t/p,n=h*Math.cos(e*Math.PI/2),i=u*Math.sin(e*Math.PI/2)+d;for(let t=0,e=E.length;t=0;){const i=n;let r=n-1;r<0&&(r=t.length-1);for(let t=0,n=o+2*p;t=i)){l.push(e.times[t]);for(let n=0;ns.tracks[t].times[0]&&(o=s.tracks[t].times[0]);for(let t=0;t=i.times[u]){const t=u*l+o,e=t+l-o;d=Ea.arraySlice(i.values,t,e)}else{const t=i.createInterpolant(),e=o,n=l-o;t.evaluate(s),d=Ea.arraySlice(t.resultBuffer,e,n)}if("quaternion"===r){(new K).fromArray(d).normalize().conjugate().toArray(d)}const p=a.times.length;for(let t=0;t=r)break t;{const a=e[1];t=r)break e}s=n,n=0}}for(;n>>1;te;)--s;if(++s,0!==r||s!==i){r>=s&&(s=Math.max(s,1),r=s-1);const t=this.getValueSize();this.times=Ea.arraySlice(n,r,s),this.values=Ea.arraySlice(this.values,r*t,s*t)}return this}validate(){let t=!0;const e=this.getValueSize();e-Math.floor(e)!=0&&(console.error("THREE.KeyframeTrack: Invalid value size in track.",this),t=!1);const n=this.times,i=this.values,r=n.length;0===r&&(console.error("THREE.KeyframeTrack: Track is empty.",this),t=!1);let s=null;for(let e=0;e!==r;e++){const i=n[e];if("number"==typeof i&&isNaN(i)){console.error("THREE.KeyframeTrack: Time is not a valid number.",this,e,i),t=!1;break}if(null!==s&&s>i){console.error("THREE.KeyframeTrack: Out of order keys.",this,e,i,s),t=!1;break}s=i}if(void 0!==i&&Ea.isTypedArray(i))for(let e=0,n=i.length;e!==n;++e){const n=i[e];if(isNaN(n)){console.error("THREE.KeyframeTrack: Value is not a valid number.",this,e,n),t=!1;break}}return t}optimize(){const t=Ea.arraySlice(this.times),e=Ea.arraySlice(this.values),n=this.getValueSize(),i=this.getInterpolation()===b,r=t.length-1;let s=1;for(let a=1;a0){t[s]=t[r];for(let t=r*n,i=s*n,a=0;a!==n;++a)e[i+a]=e[t+a];++s}return s!==t.length?(this.times=Ea.arraySlice(t,0,s),this.values=Ea.arraySlice(e,0,s*n)):(this.times=t,this.values=e),this}clone(){const t=Ea.arraySlice(this.times,0),e=Ea.arraySlice(this.values,0),n=new(0,this.constructor)(this.name,t,e);return n.createInterpolant=this.createInterpolant,n}}Pa.prototype.TimeBufferType=Float32Array,Pa.prototype.ValueBufferType=Float32Array,Pa.prototype.DefaultInterpolation=M;class Da extends Pa{}Da.prototype.ValueTypeName="bool",Da.prototype.ValueBufferType=Array,Da.prototype.DefaultInterpolation=w,Da.prototype.InterpolantFactoryMethodLinear=void 0,Da.prototype.InterpolantFactoryMethodSmooth=void 0;class Ia extends Pa{}Ia.prototype.ValueTypeName="color";class Na extends Pa{}Na.prototype.ValueTypeName="number";class za extends Aa{constructor(t,e,n,i){super(t,e,n,i)}interpolate_(t,e,n,i){const r=this.resultBuffer,s=this.sampleValues,a=this.valueSize,o=(n-e)/(i-e);let l=t*a;for(let t=l+a;l!==t;l+=4)K.slerpFlat(r,0,s,l-a,s,l,o);return r}}class Fa extends Pa{InterpolantFactoryMethodLinear(t){return new za(this.times,this.values,this.getValueSize(),t)}}Fa.prototype.ValueTypeName="quaternion",Fa.prototype.DefaultInterpolation=M,Fa.prototype.InterpolantFactoryMethodSmooth=void 0;class Oa extends Pa{}Oa.prototype.ValueTypeName="string",Oa.prototype.ValueBufferType=Array,Oa.prototype.DefaultInterpolation=w,Oa.prototype.InterpolantFactoryMethodLinear=void 0,Oa.prototype.InterpolantFactoryMethodSmooth=void 0;class Ba extends Pa{}Ba.prototype.ValueTypeName="vector";class Ua{constructor(t,e=-1,n,i=2500){this.name=t,this.tracks=n,this.duration=e,this.blendMode=i,this.uuid=O(),this.duration<0&&this.resetDuration()}static parse(t){const e=[],n=t.tracks,i=1/(t.fps||1);for(let t=0,r=n.length;t!==r;++t)e.push(Ha(n[t]).scale(i));const r=new this(t.name,t.duration,e,t.blendMode);return r.uuid=t.uuid,r}static toJSON(t){const e=[],n=t.tracks,i={name:t.name,duration:t.duration,tracks:e,uuid:t.uuid,blendMode:t.blendMode};for(let t=0,i=n.length;t!==i;++t)e.push(Pa.toJSON(n[t]));return i}static CreateFromMorphTargetSequence(t,e,n,i){const r=e.length,s=[];for(let t=0;t1){const t=s[1];let e=i[t];e||(i[t]=e=[]),e.push(n)}}const s=[];for(const t in i)s.push(this.CreateFromMorphTargetSequence(t,i[t],e,n));return s}static parseAnimation(t,e){if(!t)return console.error("THREE.AnimationClip: No animation in JSONLoader data."),null;const n=function(t,e,n,i,r){if(0!==n.length){const s=[],a=[];Ea.flattenJSON(n,s,a,i),0!==s.length&&r.push(new t(e,s,a))}},i=[],r=t.name||"default",s=t.fps||30,a=t.blendMode;let o=t.length||-1;const l=t.hierarchy||[];for(let t=0;t0||0===t.search(/^data\:image\/jpeg/);r.format=i?g:v,r.needsUpdate=!0,void 0!==e&&e(r)}),n,i),r}}class Za extends Cs{constructor(){super(),this.type="CurvePath",this.curves=[],this.autoClose=!1}add(t){this.curves.push(t)}closePath(){const t=this.curves[0].getPoint(0),e=this.curves[this.curves.length-1].getPoint(1);t.equals(e)||this.curves.push(new Vs(e,t))}getPoint(t){const e=t*this.getLength(),n=this.getCurveLengths();let i=0;for(;i=e){const t=n[i]-e,r=this.curves[i],s=r.getLength(),a=0===s?0:1-t/s;return r.getPointAt(a)}i++}return null}getLength(){const t=this.getCurveLengths();return t[t.length-1]}updateArcLengths(){this.needsUpdate=!0,this.cacheLengths=null,this.getCurveLengths()}getCurveLengths(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;const t=[];let e=0;for(let n=0,i=this.curves.length;n1&&!e[e.length-1].equals(e[0])&&e.push(e[0]),e}copy(t){super.copy(t),this.curves=[];for(let e=0,n=t.curves.length;e0){const t=l.getPoint(0);t.equals(this.currentPoint)||this.lineTo(t.x,t.y)}this.curves.push(l);const c=l.getPoint(1);return this.currentPoint.copy(c),this}copy(t){return super.copy(t),this.currentPoint.copy(t.currentPoint),this}toJSON(){const t=super.toJSON();return t.currentPoint=this.currentPoint.toArray(),t}fromJSON(t){return super.fromJSON(t),this.currentPoint.fromArray(t.currentPoint),this}}class Qa extends Ja{constructor(t){super(t),this.uuid=O(),this.type="Shape",this.holes=[]}getPointsHoles(t){const e=[];for(let n=0,i=this.holes.length;n0&&this._mixBufferRegionAdditive(n,i,this._addIndex*e,1,e);for(let t=e,r=e+e;t!==r;++t)if(n[t]!==n[t+e]){a.setValue(n,i);break}}saveOriginalState(){const t=this.binding,e=this.buffer,n=this.valueSize,i=n*this._origIndex;t.getValue(e,i);for(let t=n,r=i;t!==r;++t)e[t]=e[i+t%n];this._setIdentity(),this.cumulativeWeight=0,this.cumulativeWeightAdditive=0}restoreOriginalState(){const t=3*this.valueSize;this.binding.setValue(this.buffer,t)}_setAdditiveIdentityNumeric(){const t=this._addIndex*this.valueSize,e=t+this.valueSize;for(let n=t;n=.5)for(let i=0;i!==r;++i)t[e+i]=t[n+i]}_slerp(t,e,n,i){K.slerpFlat(t,e,t,e,t,n,i)}_slerpAdditive(t,e,n,i,r){const s=this._workIndex*r;K.multiplyQuaternionsFlat(t,s,t,e,t,n),K.slerpFlat(t,e,t,e,t,s,i)}_lerp(t,e,n,i,r){const s=1-i;for(let a=0;a!==r;++a){const r=e+a;t[r]=t[r]*s+t[n+a]*i}}_lerpAdditive(t,e,n,i,r){for(let s=0;s!==r;++s){const r=e+s;t[r]=t[r]+t[n+s]*i}}}const yo="\\[\\]\\.:\\/",xo=new RegExp("[\\[\\]\\.:\\/]","g"),_o="[^\\[\\]\\.:\\/]",wo="[^"+yo.replace("\\.","")+"]",Mo=/((?:WC+[\/:])*)/.source.replace("WC",_o),bo=/(WCOD+)?/.source.replace("WCOD",wo),So=/(?:\.(WC+)(?:\[(.+)\])?)?/.source.replace("WC",_o),To=/\.(WC+)(?:\[(.+)\])?/.source.replace("WC",_o),Eo=new RegExp("^"+Mo+bo+So+To+"$"),Ao=["material","materials","bones"];class Lo{constructor(t,e,n){this.path=e,this.parsedPath=n||Lo.parseTrackName(e),this.node=Lo.findNode(t,this.parsedPath.nodeName)||t,this.rootNode=t,this.getValue=this._getValue_unbound,this.setValue=this._setValue_unbound}static create(t,e,n){return t&&t.isAnimationObjectGroup?new Lo.Composite(t,e,n):new Lo(t,e,n)}static sanitizeNodeName(t){return t.replace(/\s/g,"_").replace(xo,"")}static parseTrackName(t){const e=Eo.exec(t);if(!e)throw new Error("PropertyBinding: Cannot parse trackName: "+t);const n={nodeName:e[2],objectName:e[3],objectIndex:e[4],propertyName:e[5],propertyIndex:e[6]},i=n.nodeName&&n.nodeName.lastIndexOf(".");if(void 0!==i&&-1!==i){const t=n.nodeName.substring(i+1);-1!==Ao.indexOf(t)&&(n.nodeName=n.nodeName.substring(0,i),n.objectName=t)}if(null===n.propertyName||0===n.propertyName.length)throw new Error("PropertyBinding: can not parse propertyName from trackName: "+t);return n}static findNode(t,e){if(!e||""===e||"."===e||-1===e||e===t.name||e===t.uuid)return t;if(t.skeleton){const n=t.skeleton.getBoneByName(e);if(void 0!==n)return n}if(t.children){const n=function(t){for(let i=0;i0){const t=this._interpolants,e=this._propertyBindings;switch(this.blendMode){case 2501:for(let n=0,i=t.length;n!==i;++n)t[n].evaluate(s),e[n].accumulateAdditive(a);break;case A:default:for(let n=0,r=t.length;n!==r;++n)t[n].evaluate(s),e[n].accumulate(i,a)}}}_updateWeight(t){let e=0;if(this.enabled){e=this.weight;const n=this._weightInterpolant;if(null!==n){const i=n.evaluate(t)[0];e*=i,t>n.parameterPositions[1]&&(this.stopFading(),0===i&&(this.enabled=!1))}}return this._effectiveWeight=e,e}_updateTimeScale(t){let e=0;if(!this.paused){e=this.timeScale;const n=this._timeScaleInterpolant;if(null!==n){e*=n.evaluate(t)[0],t>n.parameterPositions[1]&&(this.stopWarping(),0===e?this.paused=!0:this.timeScale=e)}}return this._effectiveTimeScale=e,e}_updateTime(t){const e=this._clip.duration,n=this.loop;let i=this.time+t,r=this._loopCount;const s=2202===n;if(0===t)return-1===r?i:s&&1==(1&r)?e-i:i;if(2200===n){-1===r&&(this._loopCount=0,this._setEndings(!0,!0,!1));t:{if(i>=e)i=e;else{if(!(i<0)){this.time=i;break t}i=0}this.clampWhenFinished?this.paused=!0:this.enabled=!1,this.time=i,this._mixer.dispatchEvent({type:"finished",action:this,direction:t<0?-1:1})}}else{if(-1===r&&(t>=0?(r=0,this._setEndings(!0,0===this.repetitions,s)):this._setEndings(0===this.repetitions,!0,s)),i>=e||i<0){const n=Math.floor(i/e);i-=e*n,r+=Math.abs(n);const a=this.repetitions-r;if(a<=0)this.clampWhenFinished?this.paused=!0:this.enabled=!1,i=t>0?e:0,this.time=i,this._mixer.dispatchEvent({type:"finished",action:this,direction:t>0?1:-1});else{if(1===a){const e=t<0;this._setEndings(e,!e,s)}else this._setEndings(!1,!1,s);this._loopCount=r,this.time=i,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:n})}}else this.time=i;if(s&&1==(1&r))return e-i}return i}_setEndings(t,e,n){const i=this._interpolantSettings;n?(i.endingStart=T,i.endingEnd=T):(i.endingStart=t?this.zeroSlopeAtStart?T:S:E,i.endingEnd=e?this.zeroSlopeAtEnd?T:S:E)}_scheduleFading(t,e,n){const i=this._mixer,r=i.time;let s=this._weightInterpolant;null===s&&(s=i._lendControlInterpolant(),this._weightInterpolant=s);const a=s.parameterPositions,o=s.sampleValues;return a[0]=r,o[0]=e,a[1]=r+t,o[1]=n,this}}(class extends I{constructor(t){super(),this._root=t,this._initMemoryManager(),this._accuIndex=0,this.time=0,this.timeScale=1}_bindAction(t,e){const n=t._localRoot||this._root,i=t._clip.tracks,r=i.length,s=t._propertyBindings,a=t._interpolants,o=n.uuid,l=this._bindingsByRootAndName;let c=l[o];void 0===c&&(c={},l[o]=c);for(let t=0;t!==r;++t){const r=i[t],l=r.name;let h=c[l];if(void 0!==h)s[t]=h;else{if(h=s[t],void 0!==h){null===h._cacheIndex&&(++h.referenceCount,this._addInactiveBinding(h,o,l));continue}const i=e&&e._propertyBindings[t].binding.parsedPath;h=new vo(Lo.create(n,l,i),r.ValueTypeName,r.getValueSize()),++h.referenceCount,this._addInactiveBinding(h,o,l),s[t]=h}a[t].resultBuffer=h.buffer}}_activateAction(t){if(!this._isActiveAction(t)){if(null===t._cacheIndex){const e=(t._localRoot||this._root).uuid,n=t._clip.uuid,i=this._actionsByClip[n];this._bindAction(t,i&&i.knownActions[0]),this._addInactiveAction(t,n,e)}const e=t._propertyBindings;for(let t=0,n=e.length;t!==n;++t){const n=e[t];0==n.useCount++&&(this._lendBinding(n),n.saveOriginalState())}this._lendAction(t)}}_deactivateAction(t){if(this._isActiveAction(t)){const e=t._propertyBindings;for(let t=0,n=e.length;t!==n;++t){const n=e[t];0==--n.useCount&&(n.restoreOriginalState(),this._takeBackBinding(n))}this._takeBackAction(t)}}_initMemoryManager(){this._actions=[],this._nActiveActions=0,this._actionsByClip={},this._bindings=[],this._nActiveBindings=0,this._bindingsByRootAndName={},this._controlInterpolants=[],this._nActiveControlInterpolants=0;const t=this;this.stats={actions:{get total(){return t._actions.length},get inUse(){return t._nActiveActions}},bindings:{get total(){return t._bindings.length},get inUse(){return t._nActiveBindings}},controlInterpolants:{get total(){return t._controlInterpolants.length},get inUse(){return t._nActiveControlInterpolants}}}}_isActiveAction(t){const e=t._cacheIndex;return null!==e&&e=0;--e)t[e].stop();return this}update(t){t*=this.timeScale;const e=this._actions,n=this._nActiveActions,i=this.time+=t,r=Math.sign(t),s=this._accuIndex^=1;for(let a=0;a!==n;++a){e[a]._update(i,t,r,s)}const a=this._bindings,o=this._nActiveBindings;for(let t=0;t!==o;++t)a[t].apply(s);return this}setTime(t){this.time=0;for(let t=0;t.99999)this.quaternion.set(0,0,0,1);else if(t.y<-.99999)this.quaternion.set(1,0,0,0);else{No.set(t.z,0,-t.x).normalize();const e=Math.acos(t.y);this.quaternion.setFromAxisAngle(No,e)}}setLength(t,e=.2*t,n=.2*e){this.line.scale.set(1,Math.max(1e-4,t-e),1),this.line.updateMatrix(),this.cone.scale.set(n,e,n),this.cone.position.y=t,this.cone.updateMatrix()}setColor(t){this.line.material.color.set(t),this.cone.material.color.set(t)}copy(t){return super.copy(t,!1),this.line.copy(t.line),this.cone.copy(t.cone),this}}const Bo=new Float32Array(1);new Int32Array(Bo.buffer);const Uo=new Me({side:1,depthWrite:!1,depthTest:!1});new en(new rn,Uo),Cs.create=function(t,e){return console.log("THREE.Curve.create() has been deprecated"),t.prototype=Object.create(Cs.prototype),t.prototype.constructor=t,t.prototype.getPoint=e,t},Ja.prototype.fromPoints=function(t){return console.warn("THREE.Path: .fromPoints() has been renamed to .setFromPoints()."),this.setFromPoints(t)},class extends ws{constructor(t=10,e=10,n=4473924,i=8947848){n=new we(n),i=new we(i);const r=e/2,s=t/e,a=t/2,o=[],l=[];for(let t=0,c=0,h=-a;t<=e;t++,h+=s){o.push(-a,0,h,a,0,h),o.push(h,0,-a,h,0,a);const e=t===r?n:i;e.toArray(l,c),c+=3,e.toArray(l,c),c+=3,e.toArray(l,c),c+=3,e.toArray(l,c),c+=3}const c=new Oe;c.setAttribute("position",new Le(o,3)),c.setAttribute("color",new Le(l,3));super(c,new ds({vertexColors:!0,toneMapped:!1})),this.type="GridHelper"}}.prototype.setColors=function(){console.error("THREE.GridHelper: setColors() has been deprecated, pass them in the constructor instead.")},class extends ws{constructor(t){const e=Io(t),n=new Oe,i=[],r=[],s=new we(0,0,1),a=new we(0,1,0);for(let t=0;t0){this.source.connect(this.filters[0]);for(let t=1,e=this.filters.length;t0){this.source.disconnect(this.filters[0]);for(let t=1,e=this.filters.length;t'+Ho[n]+""}),"")),ul&&cl.mfcc&&(ul.innerHTML=cl.mfcc.reduce((function(t,e,n){return t+'\n
'+n+"
"}),"")),qo.pop(),qo.unshift(cl.amplitudeSpectrum);for(var e=ko.meyda._m.signal,n=0;n ## Time-domain features ### RMS `rms` - _Description_: The root mean square of the waveform, that corresponds to its loudness. Corresponds to the ‘Energy’ feature in YAAFE, adapted from Loy’s Musimathics [1]. - _What Is It Used For_: Getting a rough idea about the loudness of a signal. - _Range_: RMS is a positive floating point number, bound only by the length and volume of the input signal. For more information, check out [the wikipedia entry](https://en.wikipedia.org/wiki/Root_mean_square). To use RMS in applications where you expect a ceiling on each audio feature, we suggest that you measure examples of audio that you will run feature extraction on, identify a reasonable "maximum" to clamp your max to, and apply the Math.min function to take either the current value of rms, or your maximum threshold, whichever is lower. ### ZCR `zcr` - _Description_: The number of times that the signal crosses the zero value in the buffer. - _What Is It Used For_: Helps differentiating between percussive and pitched sounds. Percussive sounds will have a random ZCR across buffers, where pitched sounds will return a more constant value. - _Range_: 0 - ((buffer size / 2) - 1). In Meyda, the default buffer size (`bufferSize`) is 512 and therefore the default ZCR range is `0 - 255`. ### Energy `energy` - _Description_: The infinite integral of the squared signal. According to Lathi [2]. - _What Is It Used For_: This is another indicator to the loudness of the signal. - _Range_: 0 - `bufferSize`, where `0.0` is very quiet and `bufferSize` is very loud.
## Spectral Features ### AmplitudeSpectrum `amplitudeSpectrum` - _Description_: This is also known as the magnitude spectrum. By calculating the Fast Fourier Transform (FFT), we get the signal represented in the frequency domain. The output is an array, where each index is a frequency bin (i.e. containing information about a range of frequencies) containing a complex value (real and imaginary). The amplitude spectrum takes this complex array and computes the amplitude of each index. The result is the distribution of frequencies in the signal along with their corresponding strength. If you want to learn more about Fourier Transform, and the differences between time-domain to frequency-domain analysis, [this article][mathworks-fourier] is a good place to start. - _What Is It Used For_: Very useful for any sort of audio analysis. In fact, many of the features extracted in Meyda are based on this :). - _Range_: An array half the size of the FFT, containing information about frequencies between 0 - half of the sampling rate. In Meyda the default sampling rate (`sampleRate`) is 44100Hz and the FFT size is equal to the buffer size (`bufferSize`) - with a default of 512. ### Power Spectrum `powerSpectrum` - _Description_: This is the `amplitudeSpectrum` squared. - _What Is It Used For_: This better emphasizes the differences between frequency bins, compared to the amplitude spectrum. - _Range_: An array half the size of the FFT, containing information about between frequencies 0 - half of the sampling rate. In Meyda the default sampling rate (`sampleRate`) is 44100Hz and the FFT size is equal to the buffer size (`bufferSize`) - with a default of 512. ### Spectral Centroid `spectralCentroid` - _Description_: An indicator of the "brightness" of a given sound, representing the spectral centre of gravity. If you were to take the spectrum, make a wooden block out of it and try to balance it on your finger (across the X axis), the spectral centroid would be the frequency that your finger "touches" when it successfully balances. - _What Is It Used For_: As mentioned, it's quantifying the "brightness" of a sound. This can be used for example to classify a bass guitar (low spectral centroid) from a trumpet (high spectral centroid). - _Range_: 0 - half of the FFT size. In Meyda the FFT size is equal to the buffer size (`bufferSize`) - with a default of 512. ### Spectral Flatness `spectralFlatness` - _Description_: The flatness of the spectrum. It is computed using the ratio between the geometric and arithmetic means. - _What Is It Used For_: Determining how noisy a sound is. For example a pure sine wave will have a flatness that approaches `0.0`, and white noise will have a flatness that approaches `1.0`. - _Range_: `0.0 - 1.0` where `0.0` is not flat and `1.0` is very flat. ### Spectral Flux `spectralFlux` - _Description_: A measure of how quickly the spectrum of a signal is changing. It is calculated by computing the difference between the current spectrum and that of the previous frame. - _What Is It Used For_: Often corresponds to perceptual "roughness" of a sound. Can be used for example, to determine the timbre of a sound. - _Range_: Starts at `0.0`. This has no upper range as it depends on the input signal. ### Spectral Slope `spectralSlope` - _Description_: A measure of how ‘inclined’ the shape of the spectrum is. Calculated by performing linear regression on the amplitude spectrum. - _What Is It Used For_: Can be used to differentiate between different voice qualities, such as hissing, breathing and regular speech. Closely relates to spectral centroid and spectral rolloff. - _Range_: `0.0 - 1.0` ### Spectral Rolloff `spectralRolloff` - _Description_: The frequency below which is contained 99% of the energy of the spectrum. - _What Is It Used For_: Can be used to approximate the maximum frequency in a signal. - _Range_: 0 - half of the sampling rate. In Meyda the default sampling rate (`sampleRate`) is 44100Hz. ### Spectral Spread `spectralSpread` - _Description_: Indicates how spread the frequency content is across the spectrum. Corresponds with the frequency bandwidth. - _What Is It Used For_: Can be used to differentiate between noisy (high spectral spread) and pitched sounds (low spectral spread). - _Range_: 0 - half of the FFT size. In Meyda the FFT size is equal to the buffer size (`bufferSize`) - with a default of 512. ### Spectral Skewness `spectralSkewness` - _Description_: Indicates whether or not the spectrum is skewed towards a particular range of values, relative to its mean. - _What Is It Used For_: Often used to get an idea about the timbre of a sound. - _Range_: Could be negative, positive, or 0. Where 0 is symmetric about the mean, negative indicates that the frequency content is skewed towards the right of the mean, and positive indicates that the frequency content is skewed towards the left of the mean. ### Spectral Kurtosis `spectralKurtosis` - _Description_: An indicator to how pointy the spectrum is. Can be viewed as the opposite of Spectral Flatness. - _What Is It Used For_: Often used to indicate "pitchiness / tonality" of a sound. - _Range_: `0.0 - 1.0`, where `0.0` is not tonal, and `1.0` is very tonal. ### Spectral Crest `spectralCrest` - _Description_: This is the ratio of the loudest magnitude over the RMS of the whole frame. A high number is an indication of a loud peak compared out to the overall curve of the spectrum. - _What Is It Used For_: If the spectrum you are analysing has peaks in it, it can help discern _how peaky_ it is. - _Range_: The range is arbitrary, with higher values indicating more extreme peaks in the spectrum. ### Chroma `chroma` - _Description_: Calculates the how much of each chromatic pitch class (C, C♯, D, D♯, E, F, F♯, G, G♯, A, A♯, B) exists in the signal. - _What Is It Used For_: Often used to analyse the harmonic content of recorded music, such as in chord or key detection. - _Range_: `0.0 - 1.0` for each pitch class.
## Perceptual features ### Loudness `loudness` - _Description_: Humans' perception of frequency is non-linear. The [Bark Scale][wikipedia-bark] was developed in order to have a scale on which equal distances correspond to equal distances of frequency perception. This feature outputs an object with two values: - The loudness of the input sound on each step (often referred to as bands) of this scale (`.specific`). There are 24 bands overall. - Total Loudness (`.total`), which is a sum of the 24 `.specific` loudness coefficients. - _What Is It Used For_: Can be used to construct filters that better correspond with the human perception of loudness. - _Range_: The loudness feature extractor uses a normalised spectrum to calculate the individual bark band energies, but the energies themselves are not normalised afterwards. If we were to normalize to the loudest possible sound, we would squash the range such that quiet values lose fidelity. Therefore, we leave normalization of this feature to the consumer of the value, since normalization approach depends on the use case. Realtime audio visualisers, for example, may choose to store the "loudest yet seen" value and normalize to that, whereas systems that are extracting audio features over a large corpus of audio will likely need a shared reference point for normalization, and should pick one suitable for their use case and dataset. Make sure you remember your normalization value and method though! We recommend experimenting and seeing what works for your use case. If you have ideas for how to improve the loudness feature, or any others, please [let us know]. ### Perceptual Spread `perceptualSpread` - _Description_: Computes the spread of the `.specific` loudness coefficients, over the bark scale. - _What Is It Used For_: An indicator of how "rich / full" a sound will be perceived. - _Range_: `0.0 - 1.0` where `0.0` is not "rich" and `1.0` is very "rich". ### Perceptual Sharpness `perceptualSharpness` - _Description_: Perceived "sharpness" of a sound, based the Bark loudness coefficients. - _What Is It Used For_: Detecting if an input sound is perceived as "sharp". Can be used, for example, for differentiating between snare-drum and bass-drum sounds. - _Range_: `0.0 - 1.0` where `0.0` is not "sharp" (e.g. bass-drum) and `1.0` very sharp (e.g. snare-drum). ### Mel-Frequency Cepstral Coefficients `mfcc` - _Description_: As humans don't interpret pitch in a linear manner, various scales of frequencies were devised to represent the way humans hear the distances between pitches. The [Mel scale][wikipedia-mel] is one of them, and it is now widely used for voice-related applications. The Meyda implementation was inspired by Huang [3], Davis [4], Grierson [5] and the [librosa](https://github.com/bmcfee/librosa) library. - _What Is It Used For_: Often used to perform voice activity detection (VAD) prior to automatic speech recognition (ASR). - _Range_: An array of values representing the intensity for each Mel band. The default size of the array is 13, but is configureable via `numberOfMFCCCoefficients`.
## Utility extractors ### Complex Spectrum `complexSpectrum` - _Description_: An array of complex values (`ComplexArray`) containing both the real and the imaginary parts of the FFT. - _What Is It Used For_: To create the `amplitudeSpectrum`. It is also used to do further signal processing, as it contains information about both the frequency the phase of the signal. - _Range_: An array half the size of the FFT, containing information about frequencies 0 - half of the sampling rate, and their corresponding phase values. In Meyda the default sampling rate (`sampleRate`) is 44100Hz and the FFT size is equal to the buffer size (`bufferSize`) - with a default of 512. ### Buffer `buffer` - _Description_: This is the raw audio that you get when reading an input from a microphone, a wav file, or any other input audio. It is encoded as a `Float32Array`. - _What Is It Used For_: All of the time-domain features in Meyda are extracted from this buffer. You can also use that to visualise the audio waveform. - _Range_: An array of size `bufferSize`, where each value can range between `-1.0 - 1.0`.
## Windowing functions Windowing functions are used during the conversion of a signal from the time domain (i.e. air pressure over time) to the frequency domain (the phase and intensity of each sine wave that comprises the signal); a prerequisite for many of the audio features described above. Windowing functions generate an envelope of numbers between 0 and 1, and multiply these numbers pointwise with each sample in the signal buffer, making the samples at the middle of the buffer relatively louder, and making the samples at either end of the buffer relatively quieter. This smooths out the result of the conversion to the frequency domain, which makes the final audio features more consistent and less jittery. Meyda supports 4 windowing functions, each with different characteristics. For more information on windowing, please consult [this article][wikipedia-windowing]. By default, Meyda applies the hanning window, not the rectangular window, to signals before converting them into the frequency domain. ### Hanning `Meyda.windowing(signalToBeWindowed, "hanning");` ### Hamming `Meyda.windowing(signalToBeWindowed, "hamming");` ### Blackman `Meyda.windowing(signalToBeWindowed, "blackman");` ### Sine `Meyda.windowing(signalToBeWindowed, "sine");` ### Rectangular (no window) `Meyda.windowing(signalToBeWindowed, "rect");`

--- [1] G. Loy, Musimathics: _The Mathematical Foundations of Music_, Volume 1. The MIT Press, 2006. [2] B. P. Lathi, _Modern Digital and Analog Communication Systems_ 3e Osece. Oxford University Press, 3rd ed., 1998. [3] X. Huang, A. Acero, and H.-W. Hon, _Spoken Language Processing: A Guide to Theory, Algorithm, and System Development._ Upper Saddle River, NJ, USA: Prentice Hall PTR, 1st ed., 2001. [4] S. Davis and P. Mermelstein, “Comparison of parametric representations for monosyllabic word recognition in continuously spoken sentences,” _Acoustics, Speech and Signal Processing, IEEE Transactions on_, vol. 28, pp. 357–366, Aug 1980. [5] M. Grierson, “Maximilian: A cross platform c++ audio synthesis library for artists learning to program.,” in _Proceedings of International Computer Music Conference,_ 2010. [wikipedia-windowing]: https://en.wikipedia.org/wiki/Window_function [wikipedia-mel]: https://en.wikipedia.org/wiki/Mel_scale [wikipedia-bark]: https://en.wikipedia.org/wiki/Bark_scale [mathworks-fourier]: https://www.mathworks.com/help/signal/examples/practical-introduction-to-frequency-domain-analysis.html [let us know]: https://github.com/meyda/meyda/issues ================================================ FILE: docs/getting-started.md ================================================ --- layout: default --- # Getting Started Meyda is a Javascript Library that can listen to audio and output a selection of statistics that describe it. Meyda has a variety of different applications, and environments it can be used in. Lets take a look at some. ## What can you do with Meyda? You can get audio analysis of - Audio playing in real time in your browser - Audio that's stored in buffers or arrays in your browser - Audio that's stored on disk as a wav file - Audio that you've loaded in Node.js You can use these analyses in - Real Time Audio Visualizations - Machine Learning - Visual Score Generation - Music Recommendation - ...and anything else you can think of! ## What's in these audio analyses? Meyda can calculate a wide variety of standard audio features, including loudness, spectral characteristics like brightness (spectral centroid) and noisiness (flatness) and much more. For a full list and explanation of the audio features Meyda supports, please see [our audio feature reference document] [audio-features]. ## Installation To install Meyda in a modern frontend project, use `npm`: `npm install --save meyda` For web use cases, Meyda bundles a browserified copy of itself that exposes a `Meyda` object on the `window` object. This can be used in situations where npm is not in use, and you need to include a html link to your dependency, like the jQuery days. To add Meyda to your web page, you can load it via [unpkg] as follows: ```html ` into your HTML. In most other projects, make sure you've installed Meyda using npm, and imported or required it into your Javascript file. ```js if (typeof Meyda === "undefined") { console.log("Meyda could not be found! Have you included it?"); } ``` Otherwise, we'll create a Meyda Analyzer and tell it to listen to our Audio Source Node. ```js // Create the Meyda Analyzer const analyzer = Meyda.createMeydaAnalyzer({ // Pass in the AudioContext so that Meyda knows which AudioContext Box to work with audioContext: audioContext, // Source is the audio node that is playing your audio. It could be any node, // but in this case, it's the MediaElementSourceNode corresponding to your // HTML 5 Audio Element with your audio in it. source: source, // Buffer Size tells Meyda how often to check the audio feature, and is // measured in Audio Samples. Usually there are 44100 Audio Samples in 1 // second, which means in this case Meyda will calculate the level about 86 // (44100/512) times per second. bufferSize: 512, // Here we're telling Meyda which audio features to calculate. While Meyda can // calculate a variety of audio features, in this case we only want to know // the "rms" (root mean square) of the audio signal, which corresponds to its // level featureExtractors: ["rms"], // Finally, we provide a function which Meyda will call every time it // calculates a new level. This function will be called around 86 times per // second. callback: (features) => { console.log(features); }, }); ``` Now that Meyda is hooked up to our Audio Source, we tell it to start calculating the level like this: ```js analyzer.start(); ``` When you run this code and play the audio in your HTML Audio Element, you should hear the audio, and see the level being printed to your browser console. ## 5. Show the audio analysis that Meyda returns to your user Only one more step! Now that Meyda is calculating the level of your audio in real time, you can show the level in your web app. While there are plenty of ways to visualize things, one of the simplest ways is to set the value of an html input element of type "range". Range is great because it displays as a slider in your web page. Lets add one in to our HTML: ```html ``` The level (root mean square) audio feature ranges between 0 and 1, so we set these as the min and max values of our range. Level is a continuous audio feature (as opposed to having a discrete set of possible values), so we set the step size of our range element to be very small, so that we don't lose too much precision when displaying it. Now that our HTML is in place, lets connect our Javascript. We've got to store a reference to our input element in our Javascript file, so we'll store it in a variable at the top of our file. If you get lost and don't know where to paste the code, don't worry - you can check out the finished code at the end of the tutorial. ```js const levelRangeElement = document.getElementById("levelRange"); ``` Finally, inside Meyda's callback (where you log the level), you should set the value of the range element to the value of the level that Meyda reported. ```js levelRangeElement.value = features.rms; ``` --- Well done! You built a website that shows the user the level of the audio that's playing! Have a look at our complete implementation of this site hosted on Glitch.com
Here are a few things you might like to try next: 1. Learn more about audio features 2. Learn more about Web Audio 3. Learn how to use Meyda in Node.js 4. Learn how to choose Meyda's parameters for your use case [webaudioapi]: https://github.com/WebAudio/web-audio-api [glitch]: https://glitch.com/ [freesound]: https://freesound.org [new-issue]: https://github.com/meyda/meyda/issues/new ================================================ FILE: docs/index.md ================================================ --- layout: homepage --- ## What is Meyda? Meyda is a JavaScript audio feature extraction library. It works with the Web Audio API (or plain old JavaScript arrays) to expose information about the timbre and perceived qualities of sound. Meyda supports both offline feature extraction as well as real-time feature extraction using the [Web Audio API][webaudioapi]. We wrote a paper about it, which is available [here][paper]. Would you like your Meyda project to be featured in our [user showcase]? [Please let us know!](https://github.com/meyda/meyda/issues/new?assignees=&labels=Showcase+Request&template=showcase-application.md&title=) Want to ask questions, or chat about Meyda? Check out our [slack channel] on the Web Audio Slack Team. You'll need to [sign up here][web-audio-slack-team-signup] before you can join. --- [paper]: https://wac.ircam.fr/pdf/wac15_submission_17.pdf [webaudioapi]: https://github.com/WebAudio/web-audio-api [wiki]: https://github.com/hughrawlinson/meyda/wiki/getting-started [slack channel]: https://web-audio.slack.com/messages/C51A03LBS/ [web-audio-slack-team-signup]: https://web-audio-slackin.herokuapp.com/ [user showcase]: https://meyda.js.org/showcase ================================================ FILE: docs/major-changes-policy.md ================================================ --- layout: default --- # Major changes Policy Early on in the development of Meyda, we had to contend with the issue of how to relate changes to audio feature extractors to semantic versioning. Specifically, the question was this: if a bug fix to an audio feature extractor causes the result of that extractor to differ between Meyda versions, should we consider that to be a breaking change. On the one hand, a correction to a feature extractor is a bug fix, and therefore should correspond to a semantic versioning patch number increment. But there were deeper considerations to take into account. Several applications that relate to audio feature extraction involve caching the results of feature extraction on some corpus, for use in lookup systems. For example, storing the audio features of known labelled sounds in a database such that at a later time the audio features of an unknown sound can be extracted and used with the [K Nearest Neighbors] algorithm for classification. When audio features are stored/cached on a corpus of sound for these lookup systems, a specific feature extractor algorithm was used. The same extractor (more accurately, an extractor that is an equivalent pure function of a given signal) must be used at the lookup stage on the unknown signal in order to provide comparable audio features on the new signal. Otherwise, the system would in effect be comparing apples to oranges. If Meyda were to change audio feature extractor implementations in such a way as to break extractor equivalency between patch versions, we would reduce the efficacy of systems that are sensitive to these changes. Specifically, publishing these changes as patch versions could cause issues in user projects that are particularly difficult to diagnose, since patch versions can be upgraded through version ranges with no code changes in the user's package. Therefore, we have decided that every change to the output of an audio feature extractor _including bugfixes_ are to be considered breaking changes. [k nearest neighbors]: https://en.wikipedia.org/wiki/K-nearest_neighbors_algorithm ================================================ FILE: docs/package.json ================================================ { "name": "meyda-showcase-site", "version": "1.0.0", "description": "A showcase site for Meyda", "main": "", "scripts": { "test": "echo 'No tests yet...'", "build": "rollup -c rollup.config.js" }, "repository": { "type": "git", "url": "git+https://github.com/hughrawlinson/meyda.git" }, "keywords": [ "meyda" ], "license": "MIT", "bugs": { "url": "https://github.com/hughrawlinson/meyda/issues" }, "homepage": "https://meyda.js.org/", "browserslist": "> 0.25%, not dead", "private": "true", "devDependencies": { "@types/meyda": "^4.3.8", "@types/three": "^0.163.0" }, "dependencies": { "meyda": "^5.6.2", "three": "^0.163.0" } } ================================================ FILE: docs/reference/.nojekyll ================================================ TypeDoc added this file to prevent GitHub Pages from using Jekyll. You can turn off this behavior by setting the `githubPages` option to false. ================================================ FILE: docs/reference/assets/highlight.css ================================================ :root { --light-hl-0: #0000FF; --dark-hl-0: #569CD6; --light-hl-1: #000000; --dark-hl-1: #D4D4D4; --light-hl-2: #0070C1; --dark-hl-2: #4FC1FF; --light-hl-3: #001080; --dark-hl-3: #9CDCFE; --light-hl-4: #795E26; --dark-hl-4: #DCDCAA; --light-hl-5: #A31515; --dark-hl-5: #CE9178; --light-hl-6: #098658; --dark-hl-6: #B5CEA8; --light-code-background: #FFFFFF; --dark-code-background: #1E1E1E; } @media (prefers-color-scheme: light) { :root { --hl-0: var(--light-hl-0); --hl-1: var(--light-hl-1); --hl-2: var(--light-hl-2); --hl-3: var(--light-hl-3); --hl-4: var(--light-hl-4); --hl-5: var(--light-hl-5); --hl-6: var(--light-hl-6); --code-background: var(--light-code-background); } } @media (prefers-color-scheme: dark) { :root { --hl-0: var(--dark-hl-0); --hl-1: var(--dark-hl-1); --hl-2: var(--dark-hl-2); --hl-3: var(--dark-hl-3); --hl-4: var(--dark-hl-4); --hl-5: var(--dark-hl-5); --hl-6: var(--dark-hl-6); --code-background: var(--dark-code-background); } } body.light { --hl-0: var(--light-hl-0); --hl-1: var(--light-hl-1); --hl-2: var(--light-hl-2); --hl-3: var(--light-hl-3); --hl-4: var(--light-hl-4); --hl-5: var(--light-hl-5); --hl-6: var(--light-hl-6); --code-background: var(--light-code-background); } body.dark { --hl-0: var(--dark-hl-0); --hl-1: var(--dark-hl-1); --hl-2: var(--dark-hl-2); --hl-3: var(--dark-hl-3); --hl-4: var(--dark-hl-4); --hl-5: var(--dark-hl-5); --hl-6: var(--dark-hl-6); --code-background: var(--dark-code-background); } .hl-0 { color: var(--hl-0); } .hl-1 { color: var(--hl-1); } .hl-2 { color: var(--hl-2); } .hl-3 { color: var(--hl-3); } .hl-4 { color: var(--hl-4); } .hl-5 { color: var(--hl-5); } .hl-6 { color: var(--hl-6); } pre, code { background: var(--code-background); } ================================================ FILE: docs/reference/assets/icons.css ================================================ .tsd-kind-icon { display: block; position: relative; padding-left: 20px; text-indent: -20px; } .tsd-kind-icon:before { content: ""; display: inline-block; vertical-align: middle; width: 17px; height: 17px; margin: 0 3px 2px 0; background-image: url(./icons.png); } @media (-webkit-min-device-pixel-ratio: 1.5), (min-resolution: 144dpi) { .tsd-kind-icon:before { background-image: url(./icons@2x.png); background-size: 238px 204px; } } .tsd-signature.tsd-kind-icon:before { background-position: 0 -153px; } .tsd-kind-object-literal > .tsd-kind-icon:before { background-position: 0px -17px; } .tsd-kind-object-literal.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -17px; } .tsd-kind-object-literal.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -17px; } .tsd-kind-class > .tsd-kind-icon:before { background-position: 0px -34px; } .tsd-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -34px; } .tsd-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -34px; } .tsd-kind-class.tsd-has-type-parameter > .tsd-kind-icon:before { background-position: 0px -51px; } .tsd-kind-class.tsd-has-type-parameter.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -51px; } .tsd-kind-class.tsd-has-type-parameter.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -51px; } .tsd-kind-interface > .tsd-kind-icon:before { background-position: 0px -68px; } .tsd-kind-interface.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -68px; } .tsd-kind-interface.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -68px; } .tsd-kind-interface.tsd-has-type-parameter > .tsd-kind-icon:before { background-position: 0px -85px; } .tsd-kind-interface.tsd-has-type-parameter.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -85px; } .tsd-kind-interface.tsd-has-type-parameter.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -85px; } .tsd-kind-namespace > .tsd-kind-icon:before { background-position: 0px -102px; } .tsd-kind-namespace.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -102px; } .tsd-kind-namespace.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -102px; } .tsd-kind-module > .tsd-kind-icon:before { background-position: 0px -102px; } .tsd-kind-module.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -102px; } .tsd-kind-module.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -102px; } .tsd-kind-enum > .tsd-kind-icon:before { background-position: 0px -119px; } .tsd-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -119px; } .tsd-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -119px; } .tsd-kind-enum-member > .tsd-kind-icon:before { background-position: 0px -136px; } .tsd-kind-enum-member.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -136px; } .tsd-kind-enum-member.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -136px; } .tsd-kind-signature > .tsd-kind-icon:before { background-position: 0px -153px; } .tsd-kind-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -153px; } .tsd-kind-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -153px; } .tsd-kind-type-alias > .tsd-kind-icon:before { background-position: 0px -170px; } .tsd-kind-type-alias.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -170px; } .tsd-kind-type-alias.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -170px; } .tsd-kind-type-alias.tsd-has-type-parameter > .tsd-kind-icon:before { background-position: 0px -187px; } .tsd-kind-type-alias.tsd-has-type-parameter.tsd-is-protected > .tsd-kind-icon:before { background-position: -17px -187px; } .tsd-kind-type-alias.tsd-has-type-parameter.tsd-is-private > .tsd-kind-icon:before { background-position: -34px -187px; } .tsd-kind-variable > .tsd-kind-icon:before { background-position: -136px -0px; } .tsd-kind-variable.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -0px; } .tsd-kind-variable.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; } .tsd-kind-variable.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -0px; } .tsd-kind-variable.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -0px; } .tsd-kind-variable.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -0px; } .tsd-kind-variable.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -0px; } .tsd-kind-variable.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; } .tsd-kind-variable.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -0px; } .tsd-kind-variable.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -0px; } .tsd-kind-variable.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; } .tsd-kind-variable.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -0px; } .tsd-kind-variable.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -0px; } .tsd-kind-property > .tsd-kind-icon:before { background-position: -136px -0px; } .tsd-kind-property.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -0px; } .tsd-kind-property.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; } .tsd-kind-property.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -0px; } .tsd-kind-property.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -0px; } .tsd-kind-property.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -0px; } .tsd-kind-property.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -0px; } .tsd-kind-property.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; } .tsd-kind-property.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -0px; } .tsd-kind-property.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -0px; } .tsd-kind-property.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -0px; } .tsd-kind-property.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -0px; } .tsd-kind-property.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -0px; } .tsd-kind-get-signature > .tsd-kind-icon:before { background-position: -136px -17px; } .tsd-kind-get-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -17px; } .tsd-kind-get-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -17px; } .tsd-kind-get-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -17px; } .tsd-kind-get-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -17px; } .tsd-kind-get-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -17px; } .tsd-kind-get-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -17px; } .tsd-kind-get-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -17px; } .tsd-kind-get-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -17px; } .tsd-kind-get-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -17px; } .tsd-kind-get-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -17px; } .tsd-kind-get-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -17px; } .tsd-kind-get-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -17px; } .tsd-kind-set-signature > .tsd-kind-icon:before { background-position: -136px -34px; } .tsd-kind-set-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -34px; } .tsd-kind-set-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -34px; } .tsd-kind-set-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -34px; } .tsd-kind-set-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -34px; } .tsd-kind-set-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -34px; } .tsd-kind-set-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -34px; } .tsd-kind-set-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -34px; } .tsd-kind-set-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -34px; } .tsd-kind-set-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -34px; } .tsd-kind-set-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -34px; } .tsd-kind-set-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -34px; } .tsd-kind-set-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -34px; } .tsd-kind-accessor > .tsd-kind-icon:before { background-position: -136px -51px; } .tsd-kind-accessor.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -51px; } .tsd-kind-accessor.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -51px; } .tsd-kind-accessor.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -51px; } .tsd-kind-accessor.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -51px; } .tsd-kind-accessor.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -51px; } .tsd-kind-accessor.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -51px; } .tsd-kind-accessor.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -51px; } .tsd-kind-accessor.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -51px; } .tsd-kind-accessor.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -51px; } .tsd-kind-accessor.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -51px; } .tsd-kind-accessor.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -51px; } .tsd-kind-accessor.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -51px; } .tsd-kind-function > .tsd-kind-icon:before { background-position: -136px -68px; } .tsd-kind-function.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -68px; } .tsd-kind-function.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; } .tsd-kind-function.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -68px; } .tsd-kind-function.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -68px; } .tsd-kind-function.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -68px; } .tsd-kind-function.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -68px; } .tsd-kind-function.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; } .tsd-kind-function.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -68px; } .tsd-kind-function.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -68px; } .tsd-kind-function.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; } .tsd-kind-function.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -68px; } .tsd-kind-function.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -68px; } .tsd-kind-method > .tsd-kind-icon:before { background-position: -136px -68px; } .tsd-kind-method.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -68px; } .tsd-kind-method.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; } .tsd-kind-method.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -68px; } .tsd-kind-method.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -68px; } .tsd-kind-method.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -68px; } .tsd-kind-method.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -68px; } .tsd-kind-method.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; } .tsd-kind-method.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -68px; } .tsd-kind-method.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -68px; } .tsd-kind-method.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; } .tsd-kind-method.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -68px; } .tsd-kind-method.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -68px; } .tsd-kind-call-signature > .tsd-kind-icon:before { background-position: -136px -68px; } .tsd-kind-call-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -68px; } .tsd-kind-call-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; } .tsd-kind-call-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -68px; } .tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -68px; } .tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -68px; } .tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -68px; } .tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; } .tsd-kind-call-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -68px; } .tsd-kind-call-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -68px; } .tsd-kind-call-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -68px; } .tsd-kind-call-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -68px; } .tsd-kind-call-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -68px; } .tsd-kind-function.tsd-has-type-parameter > .tsd-kind-icon:before { background-position: -136px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -85px; } .tsd-kind-function.tsd-has-type-parameter.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -85px; } .tsd-kind-method.tsd-has-type-parameter > .tsd-kind-icon:before { background-position: -136px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -85px; } .tsd-kind-method.tsd-has-type-parameter.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -85px; } .tsd-kind-constructor > .tsd-kind-icon:before { background-position: -136px -102px; } .tsd-kind-constructor.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -102px; } .tsd-kind-constructor.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; } .tsd-kind-constructor.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -102px; } .tsd-kind-constructor.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -102px; } .tsd-kind-constructor.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -102px; } .tsd-kind-constructor.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -102px; } .tsd-kind-constructor.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; } .tsd-kind-constructor.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -102px; } .tsd-kind-constructor.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -102px; } .tsd-kind-constructor.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; } .tsd-kind-constructor.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -102px; } .tsd-kind-constructor.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -102px; } .tsd-kind-constructor-signature > .tsd-kind-icon:before { background-position: -136px -102px; } .tsd-kind-constructor-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -102px; } .tsd-kind-constructor-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; } .tsd-kind-constructor-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -102px; } .tsd-kind-constructor-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -102px; } .tsd-kind-constructor-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -102px; } .tsd-kind-constructor-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -102px; } .tsd-kind-constructor-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; } .tsd-kind-constructor-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -102px; } .tsd-kind-constructor-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -102px; } .tsd-kind-constructor-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -102px; } .tsd-kind-constructor-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -102px; } .tsd-kind-constructor-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -102px; } .tsd-kind-index-signature > .tsd-kind-icon:before { background-position: -136px -119px; } .tsd-kind-index-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -119px; } .tsd-kind-index-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -119px; } .tsd-kind-index-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -119px; } .tsd-kind-index-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -119px; } .tsd-kind-index-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -119px; } .tsd-kind-index-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -119px; } .tsd-kind-index-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -119px; } .tsd-kind-index-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -119px; } .tsd-kind-index-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -119px; } .tsd-kind-index-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -119px; } .tsd-kind-index-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -119px; } .tsd-kind-index-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -119px; } .tsd-kind-event > .tsd-kind-icon:before { background-position: -136px -136px; } .tsd-kind-event.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -136px; } .tsd-kind-event.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -136px; } .tsd-kind-event.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -136px; } .tsd-kind-event.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -136px; } .tsd-kind-event.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -136px; } .tsd-kind-event.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -136px; } .tsd-kind-event.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -136px; } .tsd-kind-event.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -136px; } .tsd-kind-event.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -136px; } .tsd-kind-event.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -136px; } .tsd-kind-event.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -136px; } .tsd-kind-event.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -136px; } .tsd-is-static > .tsd-kind-icon:before { background-position: -136px -153px; } .tsd-is-static.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -153px; } .tsd-is-static.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -153px; } .tsd-is-static.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -153px; } .tsd-is-static.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -153px; } .tsd-is-static.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -153px; } .tsd-is-static.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -153px; } .tsd-is-static.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -153px; } .tsd-is-static.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -153px; } .tsd-is-static.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -153px; } .tsd-is-static.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -153px; } .tsd-is-static.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -153px; } .tsd-is-static.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -153px; } .tsd-is-static.tsd-kind-function > .tsd-kind-icon:before { background-position: -136px -170px; } .tsd-is-static.tsd-kind-function.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -170px; } .tsd-is-static.tsd-kind-function.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; } .tsd-is-static.tsd-kind-function.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -170px; } .tsd-is-static.tsd-kind-function.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -170px; } .tsd-is-static.tsd-kind-function.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -170px; } .tsd-is-static.tsd-kind-function.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -170px; } .tsd-is-static.tsd-kind-function.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; } .tsd-is-static.tsd-kind-function.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -170px; } .tsd-is-static.tsd-kind-function.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -170px; } .tsd-is-static.tsd-kind-function.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; } .tsd-is-static.tsd-kind-function.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -170px; } .tsd-is-static.tsd-kind-function.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -170px; } .tsd-is-static.tsd-kind-method > .tsd-kind-icon:before { background-position: -136px -170px; } .tsd-is-static.tsd-kind-method.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -170px; } .tsd-is-static.tsd-kind-method.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; } .tsd-is-static.tsd-kind-method.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -170px; } .tsd-is-static.tsd-kind-method.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -170px; } .tsd-is-static.tsd-kind-method.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -170px; } .tsd-is-static.tsd-kind-method.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -170px; } .tsd-is-static.tsd-kind-method.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; } .tsd-is-static.tsd-kind-method.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -170px; } .tsd-is-static.tsd-kind-method.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -170px; } .tsd-is-static.tsd-kind-method.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; } .tsd-is-static.tsd-kind-method.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -170px; } .tsd-is-static.tsd-kind-method.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -170px; } .tsd-is-static.tsd-kind-call-signature > .tsd-kind-icon:before { background-position: -136px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -170px; } .tsd-is-static.tsd-kind-call-signature.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -170px; } .tsd-is-static.tsd-kind-event > .tsd-kind-icon:before { background-position: -136px -187px; } .tsd-is-static.tsd-kind-event.tsd-is-protected > .tsd-kind-icon:before { background-position: -153px -187px; } .tsd-is-static.tsd-kind-event.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -187px; } .tsd-is-static.tsd-kind-event.tsd-parent-kind-class > .tsd-kind-icon:before { background-position: -51px -187px; } .tsd-is-static.tsd-kind-event.tsd-parent-kind-class.tsd-is-inherited > .tsd-kind-icon:before { background-position: -68px -187px; } .tsd-is-static.tsd-kind-event.tsd-parent-kind-class.tsd-is-protected > .tsd-kind-icon:before { background-position: -85px -187px; } .tsd-is-static.tsd-kind-event.tsd-parent-kind-class.tsd-is-protected.tsd-is-inherited > .tsd-kind-icon:before { background-position: -102px -187px; } .tsd-is-static.tsd-kind-event.tsd-parent-kind-class.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -187px; } .tsd-is-static.tsd-kind-event.tsd-parent-kind-enum > .tsd-kind-icon:before { background-position: -170px -187px; } .tsd-is-static.tsd-kind-event.tsd-parent-kind-enum.tsd-is-protected > .tsd-kind-icon:before { background-position: -187px -187px; } .tsd-is-static.tsd-kind-event.tsd-parent-kind-enum.tsd-is-private > .tsd-kind-icon:before { background-position: -119px -187px; } .tsd-is-static.tsd-kind-event.tsd-parent-kind-interface > .tsd-kind-icon:before { background-position: -204px -187px; } .tsd-is-static.tsd-kind-event.tsd-parent-kind-interface.tsd-is-inherited > .tsd-kind-icon:before { background-position: -221px -187px; } ================================================ FILE: docs/reference/assets/main.js ================================================ (()=>{var Ce=Object.create;var J=Object.defineProperty;var Pe=Object.getOwnPropertyDescriptor;var Oe=Object.getOwnPropertyNames;var Re=Object.getPrototypeOf,_e=Object.prototype.hasOwnProperty;var Me=t=>J(t,"__esModule",{value:!0});var Fe=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var De=(t,e,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of Oe(e))!_e.call(t,n)&&n!=="default"&&J(t,n,{get:()=>e[n],enumerable:!(r=Pe(e,n))||r.enumerable});return t},Ae=t=>De(Me(J(t!=null?Ce(Re(t)):{},"default",t&&t.__esModule&&"default"in t?{get:()=>t.default,enumerable:!0}:{value:t,enumerable:!0})),t);var de=Fe((ue,he)=>{(function(){var t=function(e){var r=new t.Builder;return r.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),r.searchPipeline.add(t.stemmer),e.call(r,r),r.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){return function(r){e.console&&console.warn&&console.warn(r)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var r=Object.create(null),n=Object.keys(e),i=0;i0){var h=t.utils.clone(r)||{};h.position=[a,l],h.index=s.length,s.push(new t.Token(n.slice(a,o),h))}a=o+1}}return s},t.tokenizer.separator=/[\s\-]+/;t.Pipeline=function(){this._stack=[]},t.Pipeline.registeredFunctions=Object.create(null),t.Pipeline.registerFunction=function(e,r){r in this.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+r),e.label=r,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){var r=e.label&&e.label in this.registeredFunctions;r||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index. `,e)},t.Pipeline.load=function(e){var r=new t.Pipeline;return e.forEach(function(n){var i=t.Pipeline.registeredFunctions[n];if(i)r.add(i);else throw new Error("Cannot load unregistered function: "+n)}),r},t.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach(function(r){t.Pipeline.warnIfFunctionNotRegistered(r),this._stack.push(r)},this)},t.Pipeline.prototype.after=function(e,r){t.Pipeline.warnIfFunctionNotRegistered(r);var n=this._stack.indexOf(e);if(n==-1)throw new Error("Cannot find existingFn");n=n+1,this._stack.splice(n,0,r)},t.Pipeline.prototype.before=function(e,r){t.Pipeline.warnIfFunctionNotRegistered(r);var n=this._stack.indexOf(e);if(n==-1)throw new Error("Cannot find existingFn");this._stack.splice(n,0,r)},t.Pipeline.prototype.remove=function(e){var r=this._stack.indexOf(e);r!=-1&&this._stack.splice(r,1)},t.Pipeline.prototype.run=function(e){for(var r=this._stack.length,n=0;n1&&(oe&&(n=s),o!=e);)i=n-r,s=r+Math.floor(i/2),o=this.elements[s*2];if(o==e||o>e)return s*2;if(oc?h+=2:a==c&&(r+=n[l+1]*i[h+1],l+=2,h+=2);return r},t.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},t.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),r=1,n=0;r0){var o=s.str.charAt(0),a;o in s.node.edges?a=s.node.edges[o]:(a=new t.TokenSet,s.node.edges[o]=a),s.str.length==1&&(a.final=!0),i.push({node:a,editsRemaining:s.editsRemaining,str:s.str.slice(1)})}if(s.editsRemaining!=0){if("*"in s.node.edges)var c=s.node.edges["*"];else{var c=new t.TokenSet;s.node.edges["*"]=c}if(s.str.length==0&&(c.final=!0),i.push({node:c,editsRemaining:s.editsRemaining-1,str:s.str}),s.str.length>1&&i.push({node:s.node,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)}),s.str.length==1&&(s.node.final=!0),s.str.length>=1){if("*"in s.node.edges)var l=s.node.edges["*"];else{var l=new t.TokenSet;s.node.edges["*"]=l}s.str.length==1&&(l.final=!0),i.push({node:l,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)})}if(s.str.length>1){var h=s.str.charAt(0),f=s.str.charAt(1),v;f in s.node.edges?v=s.node.edges[f]:(v=new t.TokenSet,s.node.edges[f]=v),s.str.length==1&&(v.final=!0),i.push({node:v,editsRemaining:s.editsRemaining-1,str:h+s.str.slice(2)})}}}return n},t.TokenSet.fromString=function(e){for(var r=new t.TokenSet,n=r,i=0,s=e.length;i=e;r--){var n=this.uncheckedNodes[r],i=n.child.toString();i in this.minimizedNodes?n.parent.edges[n.char]=this.minimizedNodes[i]:(n.child._str=i,this.minimizedNodes[i]=n.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(r){var n=new t.QueryParser(e,r);n.parse()})},t.Index.prototype.query=function(e){for(var r=new t.Query(this.fields),n=Object.create(null),i=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),c=0;c1?this._b=1:this._b=e},t.Builder.prototype.k1=function(e){this._k1=e},t.Builder.prototype.add=function(e,r){var n=e[this._ref],i=Object.keys(this._fields);this._documents[n]=r||{},this.documentCount+=1;for(var s=0;s=this.length)return t.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},t.QueryLexer.prototype.width=function(){return this.pos-this.start},t.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},t.QueryLexer.prototype.backup=function(){this.pos-=1},t.QueryLexer.prototype.acceptDigitRun=function(){var e,r;do e=this.next(),r=e.charCodeAt(0);while(r>47&&r<58);e!=t.QueryLexer.EOS&&this.backup()},t.QueryLexer.prototype.more=function(){return this.pos1&&(e.backup(),e.emit(t.QueryLexer.TERM)),e.ignore(),e.more())return t.QueryLexer.lexText},t.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.EDIT_DISTANCE),t.QueryLexer.lexText},t.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.BOOST),t.QueryLexer.lexText},t.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(t.QueryLexer.TERM)},t.QueryLexer.termSeparator=t.tokenizer.separator,t.QueryLexer.lexText=function(e){for(;;){var r=e.next();if(r==t.QueryLexer.EOS)return t.QueryLexer.lexEOS;if(r.charCodeAt(0)==92){e.escapeCharacter();continue}if(r==":")return t.QueryLexer.lexField;if(r=="~")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexEditDistance;if(r=="^")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexBoost;if(r=="+"&&e.width()===1||r=="-"&&e.width()===1)return e.emit(t.QueryLexer.PRESENCE),t.QueryLexer.lexText;if(r.match(t.QueryLexer.termSeparator))return t.QueryLexer.lexTerm}},t.QueryParser=function(e,r){this.lexer=new t.QueryLexer(e),this.query=r,this.currentClause={},this.lexemeIdx=0},t.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=t.QueryParser.parseClause;e;)e=e(this);return this.query},t.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},t.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},t.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},t.QueryParser.parseClause=function(e){var r=e.peekLexeme();if(r!=null)switch(r.type){case t.QueryLexer.PRESENCE:return t.QueryParser.parsePresence;case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var n="expected either a field or a term, found "+r.type;throw r.str.length>=1&&(n+=" with value '"+r.str+"'"),new t.QueryParseError(n,r.start,r.end)}},t.QueryParser.parsePresence=function(e){var r=e.consumeLexeme();if(r!=null){switch(r.str){case"-":e.currentClause.presence=t.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=t.Query.presence.REQUIRED;break;default:var n="unrecognised presence operator'"+r.str+"'";throw new t.QueryParseError(n,r.start,r.end)}var i=e.peekLexeme();if(i==null){var n="expecting term or field, found nothing";throw new t.QueryParseError(n,r.start,r.end)}switch(i.type){case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var n="expecting term or field, found '"+i.type+"'";throw new t.QueryParseError(n,i.start,i.end)}}},t.QueryParser.parseField=function(e){var r=e.consumeLexeme();if(r!=null){if(e.query.allFields.indexOf(r.str)==-1){var n=e.query.allFields.map(function(o){return"'"+o+"'"}).join(", "),i="unrecognised field '"+r.str+"', possible fields: "+n;throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.fields=[r.str];var s=e.peekLexeme();if(s==null){var i="expecting term, found nothing";throw new t.QueryParseError(i,r.start,r.end)}switch(s.type){case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var i="expecting term, found '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseTerm=function(e){var r=e.consumeLexeme();if(r!=null){e.currentClause.term=r.str.toLowerCase(),r.str.indexOf("*")!=-1&&(e.currentClause.usePipeline=!1);var n=e.peekLexeme();if(n==null){e.nextClause();return}switch(n.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+n.type+"'";throw new t.QueryParseError(i,n.start,n.end)}}},t.QueryParser.parseEditDistance=function(e){var r=e.consumeLexeme();if(r!=null){var n=parseInt(r.str,10);if(isNaN(n)){var i="edit distance must be numeric";throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.editDistance=n;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseBoost=function(e){var r=e.consumeLexeme();if(r!=null){var n=parseInt(r.str,10);if(isNaN(n)){var i="boost must be numeric";throw new t.QueryParseError(i,r.start,r.end)}e.currentClause.boost=n;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},function(e,r){typeof define=="function"&&define.amd?define(r):typeof ue=="object"?he.exports=r():e.lunr=r()}(this,function(){return t})})()});var le=[];function N(t,e){le.push({selector:e,constructor:t})}var X=class{constructor(){this.createComponents(document.body)}createComponents(e){le.forEach(r=>{e.querySelectorAll(r.selector).forEach(n=>{n.dataset.hasInstance||(new r.constructor({el:n}),n.dataset.hasInstance=String(!0))})})}};var Q=class{constructor(e){this.el=e.el}};var Z=class{constructor(){this.listeners={}}addEventListener(e,r){e in this.listeners||(this.listeners[e]=[]),this.listeners[e].push(r)}removeEventListener(e,r){if(!(e in this.listeners))return;let n=this.listeners[e];for(let i=0,s=n.length;i{let r=Date.now();return(...n)=>{r+e-Date.now()<0&&(t(...n),r=Date.now())}};var ee=class extends Z{constructor(){super();this.scrollTop=0;this.lastY=0;this.width=0;this.height=0;this.showToolbar=!0;this.toolbar=document.querySelector(".tsd-page-toolbar"),this.secondaryNav=document.querySelector(".tsd-navigation.secondary"),window.addEventListener("scroll",K(()=>this.onScroll(),10)),window.addEventListener("resize",K(()=>this.onResize(),10)),this.onResize(),this.onScroll()}triggerResize(){let e=new CustomEvent("resize",{detail:{width:this.width,height:this.height}});this.dispatchEvent(e)}onResize(){this.width=window.innerWidth||0,this.height=window.innerHeight||0;let e=new CustomEvent("resize",{detail:{width:this.width,height:this.height}});this.dispatchEvent(e)}onScroll(){this.scrollTop=window.scrollY||0;let e=new CustomEvent("scroll",{detail:{scrollTop:this.scrollTop}});this.dispatchEvent(e),this.hideShowToolbar()}hideShowToolbar(){let e=this.showToolbar;this.showToolbar=this.lastY>=this.scrollTop||this.scrollTop<=0,e!==this.showToolbar&&(this.toolbar.classList.toggle("tsd-page-toolbar--hide"),this.secondaryNav.classList.toggle("tsd-navigation--toolbar-hide")),this.lastY=this.scrollTop}},I=ee;I.instance=new ee;var te=class extends Q{constructor(e){super(e);this.anchors=[];this.index=-1;I.instance.addEventListener("resize",()=>this.onResize()),I.instance.addEventListener("scroll",r=>this.onScroll(r)),this.createAnchors()}createAnchors(){let e=window.location.href;e.indexOf("#")!=-1&&(e=e.substr(0,e.indexOf("#"))),this.el.querySelectorAll("a").forEach(r=>{let n=r.href;if(n.indexOf("#")==-1||n.substr(0,e.length)!=e)return;let i=n.substr(n.indexOf("#")+1),s=document.querySelector("a.tsd-anchor[name="+i+"]"),o=r.parentNode;!s||!o||this.anchors.push({link:o,anchor:s,position:0})}),this.onResize()}onResize(){let e;for(let n=0,i=this.anchors.length;nn.position-i.position);let r=new CustomEvent("scroll",{detail:{scrollTop:I.instance.scrollTop}});this.onScroll(r)}onScroll(e){let r=e.detail.scrollTop+5,n=this.anchors,i=n.length-1,s=this.index;for(;s>-1&&n[s].position>r;)s-=1;for(;s-1&&this.anchors[this.index].link.classList.remove("focus"),this.index=s,this.index>-1&&this.anchors[this.index].link.classList.add("focus"))}};var ce=(t,e=100)=>{let r;return(...n)=>{clearTimeout(r),r=setTimeout(()=>t(n),e)}};var pe=Ae(de());function fe(){let t=document.getElementById("tsd-search");if(!t)return;let e=document.getElementById("search-script");t.classList.add("loading"),e&&(e.addEventListener("error",()=>{t.classList.remove("loading"),t.classList.add("failure")}),e.addEventListener("load",()=>{t.classList.remove("loading"),t.classList.add("ready")}),window.searchData&&t.classList.remove("loading"));let r=document.querySelector("#tsd-search input"),n=document.querySelector("#tsd-search .results");if(!r||!n)throw new Error("The input field or the result list wrapper was not found");let i=!1;n.addEventListener("mousedown",()=>i=!0),n.addEventListener("mouseup",()=>{i=!1,t.classList.remove("has-focus")}),r.addEventListener("focus",()=>t.classList.add("has-focus")),r.addEventListener("blur",()=>{i||(i=!1,t.classList.remove("has-focus"))});let s={base:t.dataset.base+"/"};Ve(t,n,r,s)}function Ve(t,e,r,n){r.addEventListener("input",ce(()=>{ze(t,e,r,n)},200));let i=!1;r.addEventListener("keydown",s=>{i=!0,s.key=="Enter"?Ne(e,r):s.key=="Escape"?r.blur():s.key=="ArrowUp"?me(e,-1):s.key==="ArrowDown"?me(e,1):i=!1}),r.addEventListener("keypress",s=>{i&&s.preventDefault()}),document.body.addEventListener("keydown",s=>{s.altKey||s.ctrlKey||s.metaKey||!r.matches(":focus")&&s.key==="/"&&(r.focus(),s.preventDefault())})}function He(t,e){t.index||window.searchData&&(e.classList.remove("loading"),e.classList.add("ready"),t.data=window.searchData,t.index=pe.Index.load(window.searchData.index))}function ze(t,e,r,n){if(He(n,t),!n.index||!n.data)return;e.textContent="";let i=r.value.trim(),s=n.index.search(`*${i}*`);for(let o=0,a=Math.min(10,s.length);o${ve(c.parent,i)}.${l}`);let h=document.createElement("li");h.classList.value=c.classes;let f=document.createElement("a");f.href=n.base+c.url,f.classList.add("tsd-kind-icon"),f.innerHTML=l,h.append(f),e.appendChild(h)}}function me(t,e){let r=t.querySelector(".current");if(!r)r=t.querySelector(e==1?"li:first-child":"li:last-child"),r&&r.classList.add("current");else{let n=r;if(e===1)do n=n.nextElementSibling;while(n instanceof HTMLElement&&n.offsetParent==null);else do n=n.previousElementSibling;while(n instanceof HTMLElement&&n.offsetParent==null);n&&(r.classList.remove("current"),n.classList.add("current"))}}function Ne(t,e){let r=t.querySelector(".current");if(r||(r=t.querySelector("li:first-child")),r){let n=r.querySelector("a");n&&(window.location.href=n.href),e.blur()}}function ve(t,e){if(e==="")return t;let r=t.toLocaleLowerCase(),n=e.toLocaleLowerCase(),i=[],s=0,o=r.indexOf(n);for(;o!=-1;)i.push(re(t.substring(s,o)),`${re(t.substring(o,o+n.length))}`),s=o+n.length,o=r.indexOf(n,s);return i.push(re(t.substring(s))),i.join("")}var je={"&":"&","<":"<",">":">","'":"'",'"':"""};function re(t){return t.replace(/[&<>"'"]/g,e=>je[e])}var ge=class{constructor(e,r){this.signature=e,this.description=r}addClass(e){return this.signature.classList.add(e),this.description.classList.add(e),this}removeClass(e){return this.signature.classList.remove(e),this.description.classList.remove(e),this}},ne=class extends Q{constructor(e){super(e);this.groups=[];this.index=-1;this.createGroups(),this.container&&(this.el.classList.add("active"),Array.from(this.el.children).forEach(r=>{r.addEventListener("touchstart",n=>this.onClick(n)),r.addEventListener("click",n=>this.onClick(n))}),this.container.classList.add("active"),this.setIndex(0))}setIndex(e){if(e<0&&(e=0),e>this.groups.length-1&&(e=this.groups.length-1),this.index==e)return;let r=this.groups[e];if(this.index>-1){let n=this.groups[this.index];n.removeClass("current").addClass("fade-out"),r.addClass("current"),r.addClass("fade-in"),I.instance.triggerResize(),setTimeout(()=>{n.removeClass("fade-out"),r.removeClass("fade-in")},300)}else r.addClass("current"),I.instance.triggerResize();this.index=e}createGroups(){let e=this.el.children;if(e.length<2)return;this.container=this.el.nextElementSibling;let r=this.container.children;this.groups=[];for(let n=0;n{r.signature===e.currentTarget&&this.setIndex(n)})}};var C="mousedown",ye="mousemove",_="mouseup",G={x:0,y:0},xe=!1,ie=!1,Be=!1,A=!1,Le=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);document.documentElement.classList.add(Le?"is-mobile":"not-mobile");Le&&"ontouchstart"in document.documentElement&&(Be=!0,C="touchstart",ye="touchmove",_="touchend");document.addEventListener(C,t=>{ie=!0,A=!1;let e=C=="touchstart"?t.targetTouches[0]:t;G.y=e.pageY||0,G.x=e.pageX||0});document.addEventListener(ye,t=>{if(!!ie&&!A){let e=C=="touchstart"?t.targetTouches[0]:t,r=G.x-(e.pageX||0),n=G.y-(e.pageY||0);A=Math.sqrt(r*r+n*n)>10}});document.addEventListener(_,()=>{ie=!1});document.addEventListener("click",t=>{xe&&(t.preventDefault(),t.stopImmediatePropagation(),xe=!1)});var se=class extends Q{constructor(e){super(e);this.className=this.el.dataset.toggle||"",this.el.addEventListener(_,r=>this.onPointerUp(r)),this.el.addEventListener("click",r=>r.preventDefault()),document.addEventListener(C,r=>this.onDocumentPointerDown(r)),document.addEventListener(_,r=>this.onDocumentPointerUp(r))}setActive(e){if(this.active==e)return;this.active=e,document.documentElement.classList.toggle("has-"+this.className,e),this.el.classList.toggle("active",e);let r=(this.active?"to-has-":"from-has-")+this.className;document.documentElement.classList.add(r),setTimeout(()=>document.documentElement.classList.remove(r),500)}onPointerUp(e){A||(this.setActive(!0),e.preventDefault())}onDocumentPointerDown(e){if(this.active){if(e.target.closest(".col-menu, .tsd-filter-group"))return;this.setActive(!1)}}onDocumentPointerUp(e){if(!A&&this.active&&e.target.closest(".col-menu")){let r=e.target.closest("a");if(r){let n=window.location.href;n.indexOf("#")!=-1&&(n=n.substr(0,n.indexOf("#"))),r.href.substr(0,n.length)==n&&setTimeout(()=>this.setActive(!1),250)}}}};var oe=class{constructor(e,r){this.key=e,this.value=r,this.defaultValue=r,this.initialize(),window.localStorage[this.key]&&this.setValue(this.fromLocalStorage(window.localStorage[this.key]))}initialize(){}setValue(e){if(this.value==e)return;let r=this.value;this.value=e,window.localStorage[this.key]=this.toLocalStorage(e),this.handleValueChange(r,e)}},ae=class extends oe{initialize(){let e=document.querySelector("#tsd-filter-"+this.key);!e||(this.checkbox=e,this.checkbox.addEventListener("change",()=>{this.setValue(this.checkbox.checked)}))}handleValueChange(e,r){!this.checkbox||(this.checkbox.checked=this.value,document.documentElement.classList.toggle("toggle-"+this.key,this.value!=this.defaultValue))}fromLocalStorage(e){return e=="true"}toLocalStorage(e){return e?"true":"false"}},Ee=class extends oe{initialize(){document.documentElement.classList.add("toggle-"+this.key+this.value);let e=document.querySelector("#tsd-filter-"+this.key);if(!e)return;this.select=e;let r=()=>{this.select.classList.add("active")},n=()=>{this.select.classList.remove("active")};this.select.addEventListener(C,r),this.select.addEventListener("mouseover",r),this.select.addEventListener("mouseleave",n),this.select.querySelectorAll("li").forEach(i=>{i.addEventListener(_,s=>{e.classList.remove("active"),this.setValue(s.target.dataset.value||"")})}),document.addEventListener(C,i=>{this.select.contains(i.target)||this.select.classList.remove("active")})}handleValueChange(e,r){this.select.querySelectorAll("li.selected").forEach(s=>{s.classList.remove("selected")});let n=this.select.querySelector('li[data-value="'+r+'"]'),i=this.select.querySelector(".tsd-select-label");n&&i&&(n.classList.add("selected"),i.textContent=n.textContent),document.documentElement.classList.remove("toggle-"+e),document.documentElement.classList.add("toggle-"+r)}fromLocalStorage(e){return e}toLocalStorage(e){return e}},Y=class extends Q{constructor(e){super(e);this.optionVisibility=new Ee("visibility","private"),this.optionInherited=new ae("inherited",!0),this.optionExternals=new ae("externals",!0)}static isSupported(){try{return typeof window.localStorage!="undefined"}catch{return!1}}};function be(t){let e=localStorage.getItem("tsd-theme")||"os";t.value=e,we(e),t.addEventListener("change",()=>{localStorage.setItem("tsd-theme",t.value),we(t.value)})}function we(t){switch(t){case"os":document.body.classList.remove("light","dark");break;case"light":document.body.classList.remove("dark"),document.body.classList.add("light");break;case"dark":document.body.classList.remove("light"),document.body.classList.add("dark");break}}fe();N(te,".menu-highlight");N(ne,".tsd-signatures");N(se,"a[data-toggle]");Y.isSupported()?N(Y,"#tsd-filter"):document.documentElement.classList.add("no-filter");var Te=document.getElementById("theme");Te&&be(Te);var qe=new X;Object.defineProperty(window,"app",{value:qe});})(); /*! * lunr.Builder * Copyright (C) 2020 Oliver Nightingale */ /*! * lunr.Index * Copyright (C) 2020 Oliver Nightingale */ /*! * lunr.Pipeline * Copyright (C) 2020 Oliver Nightingale */ /*! * lunr.Set * Copyright (C) 2020 Oliver Nightingale */ /*! * lunr.TokenSet * Copyright (C) 2020 Oliver Nightingale */ /*! * lunr.Vector * Copyright (C) 2020 Oliver Nightingale */ /*! * lunr.stemmer * Copyright (C) 2020 Oliver Nightingale * Includes code from - http://tartarus.org/~martin/PorterStemmer/js.txt */ /*! * lunr.stopWordFilter * Copyright (C) 2020 Oliver Nightingale */ /*! * lunr.tokenizer * Copyright (C) 2020 Oliver Nightingale */ /*! * lunr.trimmer * Copyright (C) 2020 Oliver Nightingale */ /*! * lunr.utils * Copyright (C) 2020 Oliver Nightingale */ /** * lunr - http://lunrjs.com - A bit like Solr, but much smaller and not as bright - 2.3.9 * Copyright (C) 2020 Oliver Nightingale * @license MIT */ ================================================ FILE: docs/reference/assets/search.js ================================================ window.searchData = {"kinds":{"2":"Module","32":"Variable","128":"Class","256":"Interface","1024":"Property","2048":"Method","65536":"Type literal","4194304":"Type alias"},"rows":[{"id":0,"kind":2,"name":"meyda-wa","url":"modules/meyda_wa.html","classes":"tsd-kind-module"},{"id":1,"kind":256,"name":"MeydaAnalyzerOptions","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"meyda-wa"},{"id":2,"kind":1024,"name":"audioContext","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#audioContext","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":3,"kind":1024,"name":"source","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#source","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":4,"kind":1024,"name":"bufferSize","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#bufferSize","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":5,"kind":1024,"name":"hopSize","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#hopSize","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":6,"kind":1024,"name":"sampleRate","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#sampleRate","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":7,"kind":1024,"name":"startImmediately","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#startImmediately","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":8,"kind":1024,"name":"channel","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#channel","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":9,"kind":1024,"name":"windowingFunction","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#windowingFunction","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":10,"kind":1024,"name":"featureExtractors","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#featureExtractors","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":11,"kind":1024,"name":"inputs","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#inputs","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":12,"kind":1024,"name":"outputs","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#outputs","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":13,"kind":1024,"name":"numberOfMFCCCoefficients","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#numberOfMFCCCoefficients","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":14,"kind":1024,"name":"callback","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#callback","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":15,"kind":65536,"name":"__type","url":"interfaces/meyda_wa.MeydaAnalyzerOptions.html#__type","classes":"tsd-kind-type-literal tsd-parent-kind-interface","parent":"meyda-wa.MeydaAnalyzerOptions"},{"id":16,"kind":128,"name":"MeydaAnalyzer","url":"classes/meyda_wa.MeydaAnalyzer.html","classes":"tsd-kind-class tsd-parent-kind-module","parent":"meyda-wa"},{"id":17,"kind":2048,"name":"start","url":"classes/meyda_wa.MeydaAnalyzer.html#start","classes":"tsd-kind-method tsd-parent-kind-class","parent":"meyda-wa.MeydaAnalyzer"},{"id":18,"kind":2048,"name":"stop","url":"classes/meyda_wa.MeydaAnalyzer.html#stop","classes":"tsd-kind-method tsd-parent-kind-class","parent":"meyda-wa.MeydaAnalyzer"},{"id":19,"kind":2048,"name":"setSource","url":"classes/meyda_wa.MeydaAnalyzer.html#setSource","classes":"tsd-kind-method tsd-parent-kind-class","parent":"meyda-wa.MeydaAnalyzer"},{"id":20,"kind":2048,"name":"setChannel","url":"classes/meyda_wa.MeydaAnalyzer.html#setChannel","classes":"tsd-kind-method tsd-parent-kind-class","parent":"meyda-wa.MeydaAnalyzer"},{"id":21,"kind":2048,"name":"get","url":"classes/meyda_wa.MeydaAnalyzer.html#get","classes":"tsd-kind-method tsd-parent-kind-class","parent":"meyda-wa.MeydaAnalyzer"},{"id":22,"kind":2,"name":"Meyda","url":"modules/Meyda.html","classes":"tsd-kind-module"},{"id":23,"kind":256,"name":"MeydaFeaturesObject","url":"interfaces/Meyda.MeydaFeaturesObject.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"Meyda"},{"id":24,"kind":1024,"name":"amplitudeSpectrum","url":"interfaces/Meyda.MeydaFeaturesObject.html#amplitudeSpectrum","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":25,"kind":1024,"name":"buffer","url":"interfaces/Meyda.MeydaFeaturesObject.html#buffer","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":26,"kind":1024,"name":"chroma","url":"interfaces/Meyda.MeydaFeaturesObject.html#chroma","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":27,"kind":1024,"name":"complexSpectrum","url":"interfaces/Meyda.MeydaFeaturesObject.html#complexSpectrum","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":28,"kind":65536,"name":"__type","url":"interfaces/Meyda.MeydaFeaturesObject.html#__type","classes":"tsd-kind-type-literal tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":29,"kind":1024,"name":"real","url":"interfaces/Meyda.MeydaFeaturesObject.html#__type.real","classes":"tsd-kind-property tsd-parent-kind-type-literal","parent":"Meyda.MeydaFeaturesObject.__type"},{"id":30,"kind":1024,"name":"imag","url":"interfaces/Meyda.MeydaFeaturesObject.html#__type.imag","classes":"tsd-kind-property tsd-parent-kind-type-literal","parent":"Meyda.MeydaFeaturesObject.__type"},{"id":31,"kind":1024,"name":"energy","url":"interfaces/Meyda.MeydaFeaturesObject.html#energy","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":32,"kind":1024,"name":"loudness","url":"interfaces/Meyda.MeydaFeaturesObject.html#loudness","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":33,"kind":65536,"name":"__type","url":"interfaces/Meyda.MeydaFeaturesObject.html#__type-1","classes":"tsd-kind-type-literal tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":34,"kind":1024,"name":"specific","url":"interfaces/Meyda.MeydaFeaturesObject.html#__type-1.specific","classes":"tsd-kind-property tsd-parent-kind-type-literal","parent":"Meyda.MeydaFeaturesObject.__type"},{"id":35,"kind":1024,"name":"total","url":"interfaces/Meyda.MeydaFeaturesObject.html#__type-1.total","classes":"tsd-kind-property tsd-parent-kind-type-literal","parent":"Meyda.MeydaFeaturesObject.__type"},{"id":36,"kind":1024,"name":"mfcc","url":"interfaces/Meyda.MeydaFeaturesObject.html#mfcc","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":37,"kind":1024,"name":"perceptualSharpness","url":"interfaces/Meyda.MeydaFeaturesObject.html#perceptualSharpness","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":38,"kind":1024,"name":"perceptualSpread","url":"interfaces/Meyda.MeydaFeaturesObject.html#perceptualSpread","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":39,"kind":1024,"name":"powerSpectrum","url":"interfaces/Meyda.MeydaFeaturesObject.html#powerSpectrum","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":40,"kind":1024,"name":"rms","url":"interfaces/Meyda.MeydaFeaturesObject.html#rms","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":41,"kind":1024,"name":"spectralCentroid","url":"interfaces/Meyda.MeydaFeaturesObject.html#spectralCentroid","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":42,"kind":1024,"name":"spectralFlatness","url":"interfaces/Meyda.MeydaFeaturesObject.html#spectralFlatness","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":43,"kind":1024,"name":"spectralKurtosis","url":"interfaces/Meyda.MeydaFeaturesObject.html#spectralKurtosis","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":44,"kind":1024,"name":"spectralRolloff","url":"interfaces/Meyda.MeydaFeaturesObject.html#spectralRolloff","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":45,"kind":1024,"name":"spectralSkewness","url":"interfaces/Meyda.MeydaFeaturesObject.html#spectralSkewness","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":46,"kind":1024,"name":"spectralSlope","url":"interfaces/Meyda.MeydaFeaturesObject.html#spectralSlope","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":47,"kind":1024,"name":"spectralSpread","url":"interfaces/Meyda.MeydaFeaturesObject.html#spectralSpread","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":48,"kind":1024,"name":"zcr","url":"interfaces/Meyda.MeydaFeaturesObject.html#zcr","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.MeydaFeaturesObject"},{"id":49,"kind":4194304,"name":"MeydaWindowingFunction","url":"modules/Meyda.html#MeydaWindowingFunction","classes":"tsd-kind-type-alias tsd-parent-kind-module","parent":"Meyda"},{"id":50,"kind":4194304,"name":"MeydaAudioFeature","url":"modules/Meyda.html#MeydaAudioFeature","classes":"tsd-kind-type-alias tsd-parent-kind-module","parent":"Meyda"},{"id":51,"kind":4194304,"name":"MeydaSignal","url":"modules/Meyda.html#MeydaSignal","classes":"tsd-kind-type-alias tsd-parent-kind-module","parent":"Meyda"},{"id":52,"kind":256,"name":"SliceableArrayLike","url":"interfaces/Meyda.SliceableArrayLike.html","classes":"tsd-kind-interface tsd-parent-kind-module tsd-has-type-parameter","parent":"Meyda"},{"id":53,"kind":2048,"name":"slice","url":"interfaces/Meyda.SliceableArrayLike.html#slice","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"Meyda.SliceableArrayLike"},{"id":54,"kind":32,"name":"default","url":"modules/Meyda.html#default-1","classes":"tsd-kind-variable tsd-parent-kind-module","parent":"Meyda"},{"id":55,"kind":256,"name":"default","url":"interfaces/Meyda.default.html","classes":"tsd-kind-interface tsd-parent-kind-module","parent":"Meyda"},{"id":56,"kind":1024,"name":"audioContext","url":"interfaces/Meyda.default.html#audioContext","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.default"},{"id":57,"kind":1024,"name":"bufferSize","url":"interfaces/Meyda.default.html#bufferSize","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.default"},{"id":58,"kind":1024,"name":"sampleRate","url":"interfaces/Meyda.default.html#sampleRate","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.default"},{"id":59,"kind":1024,"name":"melBands","url":"interfaces/Meyda.default.html#melBands","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.default"},{"id":60,"kind":1024,"name":"chromaBands","url":"interfaces/Meyda.default.html#chromaBands","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.default"},{"id":61,"kind":1024,"name":"windowingFunction","url":"interfaces/Meyda.default.html#windowingFunction","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.default"},{"id":62,"kind":1024,"name":"featureExtractors","url":"interfaces/Meyda.default.html#featureExtractors","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.default"},{"id":63,"kind":1024,"name":"numberOfMFCCCoefficients","url":"interfaces/Meyda.default.html#numberOfMFCCCoefficients","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"Meyda.default"},{"id":64,"kind":2048,"name":"windowing","url":"interfaces/Meyda.default.html#windowing","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"Meyda.default"},{"id":65,"kind":2048,"name":"createMeydaAnalyzer","url":"interfaces/Meyda.default.html#createMeydaAnalyzer","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"Meyda.default"},{"id":66,"kind":2048,"name":"listAvailableFeatureExtractors","url":"interfaces/Meyda.default.html#listAvailableFeatureExtractors","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"Meyda.default"},{"id":67,"kind":2048,"name":"extract","url":"interfaces/Meyda.default.html#extract","classes":"tsd-kind-method tsd-parent-kind-interface","parent":"Meyda.default"}],"index":{"version":"2.3.9","fields":["name","parent"],"fieldVectors":[["name/0",[0,5.843,1,21.337]],["parent/0",[]],["name/1",[2,38.515]],["parent/1",[0,0.664,1,2.423]],["name/2",[3,33.376]],["parent/2",[0,0.664,4,1.268]],["name/3",[5,38.515]],["parent/3",[0,0.664,4,1.268]],["name/4",[6,33.376]],["parent/4",[0,0.664,4,1.268]],["name/5",[7,38.515]],["parent/5",[0,0.664,4,1.268]],["name/6",[8,33.376]],["parent/6",[0,0.664,4,1.268]],["name/7",[9,38.515]],["parent/7",[0,0.664,4,1.268]],["name/8",[10,38.515]],["parent/8",[0,0.664,4,1.268]],["name/9",[11,33.376]],["parent/9",[0,0.664,4,1.268]],["name/10",[12,33.376]],["parent/10",[0,0.664,4,1.268]],["name/11",[13,38.515]],["parent/11",[0,0.664,4,1.268]],["name/12",[14,38.515]],["parent/12",[0,0.664,4,1.268]],["name/13",[15,33.376]],["parent/13",[0,0.664,4,1.268]],["name/14",[16,38.515]],["parent/14",[0,0.664,4,1.268]],["name/15",[17,29.991]],["parent/15",[0,0.664,4,1.268]],["name/16",[18,38.515]],["parent/16",[0,0.664,1,2.423]],["name/17",[19,38.515]],["parent/17",[0,0.664,20,2.056]],["name/18",[21,38.515]],["parent/18",[0,0.664,20,2.056]],["name/19",[22,38.515]],["parent/19",[0,0.664,20,2.056]],["name/20",[23,38.515]],["parent/20",[0,0.664,20,2.056]],["name/21",[24,38.515]],["parent/21",[0,0.664,20,2.056]],["name/22",[0,8.212]],["parent/22",[]],["name/23",[25,38.515]],["parent/23",[0,0.896]],["name/24",[26,38.515]],["parent/24",[27,1.28]],["name/25",[28,38.515]],["parent/25",[27,1.28]],["name/26",[29,38.515]],["parent/26",[27,1.28]],["name/27",[30,38.515]],["parent/27",[27,1.28]],["name/28",[17,29.991]],["parent/28",[27,1.28]],["name/29",[31,38.515]],["parent/29",[32,2.998]],["name/30",[33,38.515]],["parent/30",[32,2.998]],["name/31",[34,38.515]],["parent/31",[27,1.28]],["name/32",[35,38.515]],["parent/32",[27,1.28]],["name/33",[17,29.991]],["parent/33",[27,1.28]],["name/34",[36,38.515]],["parent/34",[32,2.998]],["name/35",[37,38.515]],["parent/35",[32,2.998]],["name/36",[38,38.515]],["parent/36",[27,1.28]],["name/37",[39,38.515]],["parent/37",[27,1.28]],["name/38",[40,38.515]],["parent/38",[27,1.28]],["name/39",[41,38.515]],["parent/39",[27,1.28]],["name/40",[42,38.515]],["parent/40",[27,1.28]],["name/41",[43,38.515]],["parent/41",[27,1.28]],["name/42",[44,38.515]],["parent/42",[27,1.28]],["name/43",[45,38.515]],["parent/43",[27,1.28]],["name/44",[46,38.515]],["parent/44",[27,1.28]],["name/45",[47,38.515]],["parent/45",[27,1.28]],["name/46",[48,38.515]],["parent/46",[27,1.28]],["name/47",[49,38.515]],["parent/47",[27,1.28]],["name/48",[50,38.515]],["parent/48",[27,1.28]],["name/49",[51,38.515]],["parent/49",[0,0.896]],["name/50",[52,38.515]],["parent/50",[0,0.896]],["name/51",[53,38.515]],["parent/51",[0,0.896]],["name/52",[54,38.515]],["parent/52",[0,0.896]],["name/53",[55,38.515]],["parent/53",[56,4.204]],["name/54",[57,33.376]],["parent/54",[0,0.896]],["name/55",[57,33.376]],["parent/55",[0,0.896]],["name/56",[3,33.376]],["parent/56",[58,1.876]],["name/57",[6,33.376]],["parent/57",[58,1.876]],["name/58",[8,33.376]],["parent/58",[58,1.876]],["name/59",[59,38.515]],["parent/59",[58,1.876]],["name/60",[60,38.515]],["parent/60",[58,1.876]],["name/61",[11,33.376]],["parent/61",[58,1.876]],["name/62",[12,33.376]],["parent/62",[58,1.876]],["name/63",[15,33.376]],["parent/63",[58,1.876]],["name/64",[61,38.515]],["parent/64",[58,1.876]],["name/65",[62,38.515]],["parent/65",[58,1.876]],["name/66",[63,38.515]],["parent/66",[58,1.876]],["name/67",[64,38.515]],["parent/67",[58,1.876]]],"invertedIndex":[["__type",{"_index":17,"name":{"15":{},"28":{},"33":{}},"parent":{}}],["amplitudespectrum",{"_index":26,"name":{"24":{}},"parent":{}}],["audiocontext",{"_index":3,"name":{"2":{},"56":{}},"parent":{}}],["buffer",{"_index":28,"name":{"25":{}},"parent":{}}],["buffersize",{"_index":6,"name":{"4":{},"57":{}},"parent":{}}],["callback",{"_index":16,"name":{"14":{}},"parent":{}}],["channel",{"_index":10,"name":{"8":{}},"parent":{}}],["chroma",{"_index":29,"name":{"26":{}},"parent":{}}],["chromabands",{"_index":60,"name":{"60":{}},"parent":{}}],["complexspectrum",{"_index":30,"name":{"27":{}},"parent":{}}],["createmeydaanalyzer",{"_index":62,"name":{"65":{}},"parent":{}}],["default",{"_index":57,"name":{"54":{},"55":{}},"parent":{}}],["energy",{"_index":34,"name":{"31":{}},"parent":{}}],["extract",{"_index":64,"name":{"67":{}},"parent":{}}],["featureextractors",{"_index":12,"name":{"10":{},"62":{}},"parent":{}}],["get",{"_index":24,"name":{"21":{}},"parent":{}}],["hopsize",{"_index":7,"name":{"5":{}},"parent":{}}],["imag",{"_index":33,"name":{"30":{}},"parent":{}}],["inputs",{"_index":13,"name":{"11":{}},"parent":{}}],["listavailablefeatureextractors",{"_index":63,"name":{"66":{}},"parent":{}}],["loudness",{"_index":35,"name":{"32":{}},"parent":{}}],["melbands",{"_index":59,"name":{"59":{}},"parent":{}}],["meyda",{"_index":0,"name":{"0":{},"22":{}},"parent":{"1":{},"2":{},"3":{},"4":{},"5":{},"6":{},"7":{},"8":{},"9":{},"10":{},"11":{},"12":{},"13":{},"14":{},"15":{},"16":{},"17":{},"18":{},"19":{},"20":{},"21":{},"23":{},"49":{},"50":{},"51":{},"52":{},"54":{},"55":{}}}],["meyda.default",{"_index":58,"name":{},"parent":{"56":{},"57":{},"58":{},"59":{},"60":{},"61":{},"62":{},"63":{},"64":{},"65":{},"66":{},"67":{}}}],["meyda.meydafeaturesobject",{"_index":27,"name":{},"parent":{"24":{},"25":{},"26":{},"27":{},"28":{},"31":{},"32":{},"33":{},"36":{},"37":{},"38":{},"39":{},"40":{},"41":{},"42":{},"43":{},"44":{},"45":{},"46":{},"47":{},"48":{}}}],["meyda.meydafeaturesobject.__type",{"_index":32,"name":{},"parent":{"29":{},"30":{},"34":{},"35":{}}}],["meyda.sliceablearraylike",{"_index":56,"name":{},"parent":{"53":{}}}],["meydaanalyzer",{"_index":18,"name":{"16":{}},"parent":{}}],["meydaanalyzeroptions",{"_index":2,"name":{"1":{}},"parent":{}}],["meydaaudiofeature",{"_index":52,"name":{"50":{}},"parent":{}}],["meydafeaturesobject",{"_index":25,"name":{"23":{}},"parent":{}}],["meydasignal",{"_index":53,"name":{"51":{}},"parent":{}}],["meydawindowingfunction",{"_index":51,"name":{"49":{}},"parent":{}}],["mfcc",{"_index":38,"name":{"36":{}},"parent":{}}],["numberofmfcccoefficients",{"_index":15,"name":{"13":{},"63":{}},"parent":{}}],["outputs",{"_index":14,"name":{"12":{}},"parent":{}}],["perceptualsharpness",{"_index":39,"name":{"37":{}},"parent":{}}],["perceptualspread",{"_index":40,"name":{"38":{}},"parent":{}}],["powerspectrum",{"_index":41,"name":{"39":{}},"parent":{}}],["real",{"_index":31,"name":{"29":{}},"parent":{}}],["rms",{"_index":42,"name":{"40":{}},"parent":{}}],["samplerate",{"_index":8,"name":{"6":{},"58":{}},"parent":{}}],["setchannel",{"_index":23,"name":{"20":{}},"parent":{}}],["setsource",{"_index":22,"name":{"19":{}},"parent":{}}],["slice",{"_index":55,"name":{"53":{}},"parent":{}}],["sliceablearraylike",{"_index":54,"name":{"52":{}},"parent":{}}],["source",{"_index":5,"name":{"3":{}},"parent":{}}],["specific",{"_index":36,"name":{"34":{}},"parent":{}}],["spectralcentroid",{"_index":43,"name":{"41":{}},"parent":{}}],["spectralflatness",{"_index":44,"name":{"42":{}},"parent":{}}],["spectralkurtosis",{"_index":45,"name":{"43":{}},"parent":{}}],["spectralrolloff",{"_index":46,"name":{"44":{}},"parent":{}}],["spectralskewness",{"_index":47,"name":{"45":{}},"parent":{}}],["spectralslope",{"_index":48,"name":{"46":{}},"parent":{}}],["spectralspread",{"_index":49,"name":{"47":{}},"parent":{}}],["start",{"_index":19,"name":{"17":{}},"parent":{}}],["startimmediately",{"_index":9,"name":{"7":{}},"parent":{}}],["stop",{"_index":21,"name":{"18":{}},"parent":{}}],["total",{"_index":37,"name":{"35":{}},"parent":{}}],["wa",{"_index":1,"name":{"0":{}},"parent":{"1":{},"16":{}}}],["wa.meydaanalyzer",{"_index":20,"name":{},"parent":{"17":{},"18":{},"19":{},"20":{},"21":{}}}],["wa.meydaanalyzeroptions",{"_index":4,"name":{},"parent":{"2":{},"3":{},"4":{},"5":{},"6":{},"7":{},"8":{},"9":{},"10":{},"11":{},"12":{},"13":{},"14":{},"15":{}}}],["windowing",{"_index":61,"name":{"64":{}},"parent":{}}],["windowingfunction",{"_index":11,"name":{"9":{},"61":{}},"parent":{}}],["zcr",{"_index":50,"name":{"48":{}},"parent":{}}]],"pipeline":[]}} ================================================ FILE: docs/reference/assets/style.css ================================================ @import url("./icons.css"); :root { /* Light */ --light-color-background: #fcfcfc; --light-color-secondary-background: #fff; --light-color-text: #222; --light-color-text-aside: #707070; --light-color-link: #4da6ff; --light-color-menu-divider: #eee; --light-color-menu-divider-focus: #000; --light-color-menu-label: #707070; --light-color-panel: var(--light-color-secondary-background); --light-color-panel-divider: #eee; --light-color-comment-tag: #707070; --light-color-comment-tag-text: #fff; --light-color-ts: #9600ff; --light-color-ts-interface: #647f1b; --light-color-ts-enum: #937210; --light-color-ts-class: #0672de; --light-color-ts-private: #707070; --light-color-toolbar: #fff; --light-color-toolbar-text: #333; --light-icon-filter: invert(0); --light-external-icon: url("data:image/svg+xml;utf8,"); /* Dark */ --dark-color-background: #36393f; --dark-color-secondary-background: #2f3136; --dark-color-text: #ffffff; --dark-color-text-aside: #e6e4e4; --dark-color-link: #00aff4; --dark-color-menu-divider: #eee; --dark-color-menu-divider-focus: #000; --dark-color-menu-label: #707070; --dark-color-panel: var(--dark-color-secondary-background); --dark-color-panel-divider: #818181; --dark-color-comment-tag: #dcddde; --dark-color-comment-tag-text: #2f3136; --dark-color-ts: #c97dff; --dark-color-ts-interface: #9cbe3c; --dark-color-ts-enum: #d6ab29; --dark-color-ts-class: #3695f3; --dark-color-ts-private: #e2e2e2; --dark-color-toolbar: #34373c; --dark-color-toolbar-text: #ffffff; --dark-icon-filter: invert(1); --dark-external-icon: url("data:image/svg+xml;utf8,"); } @media (prefers-color-scheme: light) { :root { --color-background: var(--light-color-background); --color-secondary-background: var(--light-color-secondary-background); --color-text: var(--light-color-text); --color-text-aside: var(--light-color-text-aside); --color-link: var(--light-color-link); --color-menu-divider: var(--light-color-menu-divider); --color-menu-divider-focus: var(--light-color-menu-divider-focus); --color-menu-label: var(--light-color-menu-label); --color-panel: var(--light-color-panel); --color-panel-divider: var(--light-color-panel-divider); --color-comment-tag: var(--light-color-comment-tag); --color-comment-tag-text: var(--light-color-comment-tag-text); --color-ts: var(--light-color-ts); --color-ts-interface: var(--light-color-ts-interface); --color-ts-enum: var(--light-color-ts-enum); --color-ts-class: var(--light-color-ts-class); --color-ts-private: var(--light-color-ts-private); --color-toolbar: var(--light-color-toolbar); --color-toolbar-text: var(--light-color-toolbar-text); --icon-filter: var(--light-icon-filter); --external-icon: var(--light-external-icon); } } @media (prefers-color-scheme: dark) { :root { --color-background: var(--dark-color-background); --color-secondary-background: var(--dark-color-secondary-background); --color-text: var(--dark-color-text); --color-text-aside: var(--dark-color-text-aside); --color-link: var(--dark-color-link); --color-menu-divider: var(--dark-color-menu-divider); --color-menu-divider-focus: var(--dark-color-menu-divider-focus); --color-menu-label: var(--dark-color-menu-label); --color-panel: var(--dark-color-panel); --color-panel-divider: var(--dark-color-panel-divider); --color-comment-tag: var(--dark-color-comment-tag); --color-comment-tag-text: var(--dark-color-comment-tag-text); --color-ts: var(--dark-color-ts); --color-ts-interface: var(--dark-color-ts-interface); --color-ts-enum: var(--dark-color-ts-enum); --color-ts-class: var(--dark-color-ts-class); --color-ts-private: var(--dark-color-ts-private); --color-toolbar: var(--dark-color-toolbar); --color-toolbar-text: var(--dark-color-toolbar-text); --icon-filter: var(--dark-icon-filter); --external-icon: var(--dark-external-icon); } } body { margin: 0; } body.light { --color-background: var(--light-color-background); --color-secondary-background: var(--light-color-secondary-background); --color-text: var(--light-color-text); --color-text-aside: var(--light-color-text-aside); --color-link: var(--light-color-link); --color-menu-divider: var(--light-color-menu-divider); --color-menu-divider-focus: var(--light-color-menu-divider-focus); --color-menu-label: var(--light-color-menu-label); --color-panel: var(--light-color-panel); --color-panel-divider: var(--light-color-panel-divider); --color-comment-tag: var(--light-color-comment-tag); --color-comment-tag-text: var(--light-color-comment-tag-text); --color-ts: var(--light-color-ts); --color-ts-interface: var(--light-color-ts-interface); --color-ts-enum: var(--light-color-ts-enum); --color-ts-class: var(--light-color-ts-class); --color-ts-private: var(--light-color-ts-private); --color-toolbar: var(--light-color-toolbar); --color-toolbar-text: var(--light-color-toolbar-text); --icon-filter: var(--light-icon-filter); --external-icon: var(--light-external-icon); } body.dark { --color-background: var(--dark-color-background); --color-secondary-background: var(--dark-color-secondary-background); --color-text: var(--dark-color-text); --color-text-aside: var(--dark-color-text-aside); --color-link: var(--dark-color-link); --color-menu-divider: var(--dark-color-menu-divider); --color-menu-divider-focus: var(--dark-color-menu-divider-focus); --color-menu-label: var(--dark-color-menu-label); --color-panel: var(--dark-color-panel); --color-panel-divider: var(--dark-color-panel-divider); --color-comment-tag: var(--dark-color-comment-tag); --color-comment-tag-text: var(--dark-color-comment-tag-text); --color-ts: var(--dark-color-ts); --color-ts-interface: var(--dark-color-ts-interface); --color-ts-enum: var(--dark-color-ts-enum); --color-ts-class: var(--dark-color-ts-class); --color-ts-private: var(--dark-color-ts-private); --color-toolbar: var(--dark-color-toolbar); --color-toolbar-text: var(--dark-color-toolbar-text); --icon-filter: var(--dark-icon-filter); --external-icon: var(--dark-external-icon); } h1 { font-size: 2em; margin: 0.67em 0; } h2 { font-size: 1.5em; margin: 0.83em 0; } h3 { font-size: 1.17em; margin: 1em 0; } h4, .tsd-index-panel h3 { font-size: 1em; margin: 1.33em 0; } h5 { font-size: 0.83em; margin: 1.67em 0; } h6 { font-size: 0.67em; margin: 2.33em 0; } pre { white-space: pre; white-space: pre-wrap; word-wrap: break-word; } dl, menu, ol, ul { margin: 1em 0; } dd { margin: 0 0 0 40px; } .container { max-width: 1200px; margin: 0 auto; padding: 0 40px; } @media (max-width: 640px) { .container { padding: 0 20px; } } .container-main { padding-bottom: 200px; } .row { display: flex; position: relative; margin: 0 -10px; } .row:after { visibility: hidden; display: block; content: ""; clear: both; height: 0; } .col-4, .col-8 { box-sizing: border-box; float: left; padding: 0 10px; } .col-4 { width: 33.3333333333%; } .col-8 { width: 66.6666666667%; } ul.tsd-descriptions > li > :first-child, .tsd-panel > :first-child, .col-8 > :first-child, .col-4 > :first-child, ul.tsd-descriptions > li > :first-child > :first-child, .tsd-panel > :first-child > :first-child, .col-8 > :first-child > :first-child, .col-4 > :first-child > :first-child, ul.tsd-descriptions > li > :first-child > :first-child > :first-child, .tsd-panel > :first-child > :first-child > :first-child, .col-8 > :first-child > :first-child > :first-child, .col-4 > :first-child > :first-child > :first-child { margin-top: 0; } ul.tsd-descriptions > li > :last-child, .tsd-panel > :last-child, .col-8 > :last-child, .col-4 > :last-child, ul.tsd-descriptions > li > :last-child > :last-child, .tsd-panel > :last-child > :last-child, .col-8 > :last-child > :last-child, .col-4 > :last-child > :last-child, ul.tsd-descriptions > li > :last-child > :last-child > :last-child, .tsd-panel > :last-child > :last-child > :last-child, .col-8 > :last-child > :last-child > :last-child, .col-4 > :last-child > :last-child > :last-child { margin-bottom: 0; } @keyframes fade-in { from { opacity: 0; } to { opacity: 1; } } @keyframes fade-out { from { opacity: 1; visibility: visible; } to { opacity: 0; } } @keyframes fade-in-delayed { 0% { opacity: 0; } 33% { opacity: 0; } 100% { opacity: 1; } } @keyframes fade-out-delayed { 0% { opacity: 1; visibility: visible; } 66% { opacity: 0; } 100% { opacity: 0; } } @keyframes shift-to-left { from { transform: translate(0, 0); } to { transform: translate(-25%, 0); } } @keyframes unshift-to-left { from { transform: translate(-25%, 0); } to { transform: translate(0, 0); } } @keyframes pop-in-from-right { from { transform: translate(100%, 0); } to { transform: translate(0, 0); } } @keyframes pop-out-to-right { from { transform: translate(0, 0); visibility: visible; } to { transform: translate(100%, 0); } } body { background: var(--color-background); font-family: "Segoe UI", sans-serif; font-size: 16px; color: var(--color-text); } a { color: var(--color-link); text-decoration: none; } a:hover { text-decoration: underline; } a.external[target="_blank"] { background-image: var(--external-icon); background-position: top 3px right; background-repeat: no-repeat; padding-right: 13px; } code, pre { font-family: Menlo, Monaco, Consolas, "Courier New", monospace; padding: 0.2em; margin: 0; font-size: 14px; } pre { padding: 10px; } pre code { padding: 0; font-size: 100%; } blockquote { margin: 1em 0; padding-left: 1em; border-left: 4px solid gray; } .tsd-typography { line-height: 1.333em; } .tsd-typography ul { list-style: square; padding: 0 0 0 20px; margin: 0; } .tsd-typography h4, .tsd-typography .tsd-index-panel h3, .tsd-index-panel .tsd-typography h3, .tsd-typography h5, .tsd-typography h6 { font-size: 1em; margin: 0; } .tsd-typography h5, .tsd-typography h6 { font-weight: normal; } .tsd-typography p, .tsd-typography ul, .tsd-typography ol { margin: 1em 0; } @media (min-width: 901px) and (max-width: 1024px) { html .col-content { width: 72%; } html .col-menu { width: 28%; } html .tsd-navigation { padding-left: 10px; } } @media (max-width: 900px) { html .col-content { float: none; width: 100%; } html .col-menu { position: fixed !important; overflow: auto; -webkit-overflow-scrolling: touch; z-index: 1024; top: 0 !important; bottom: 0 !important; left: auto !important; right: 0 !important; width: 100%; padding: 20px 20px 0 0; max-width: 450px; visibility: hidden; background-color: var(--color-panel); transform: translate(100%, 0); } html .col-menu > *:last-child { padding-bottom: 20px; } html .overlay { content: ""; display: block; position: fixed; z-index: 1023; top: 0; left: 0; right: 0; bottom: 0; background-color: rgba(0, 0, 0, 0.75); visibility: hidden; } .to-has-menu .overlay { animation: fade-in 0.4s; } .to-has-menu :is(header, footer, .col-content) { animation: shift-to-left 0.4s; } .to-has-menu .col-menu { animation: pop-in-from-right 0.4s; } .from-has-menu .overlay { animation: fade-out 0.4s; } .from-has-menu :is(header, footer, .col-content) { animation: unshift-to-left 0.4s; } .from-has-menu .col-menu { animation: pop-out-to-right 0.4s; } .has-menu body { overflow: hidden; } .has-menu .overlay { visibility: visible; } .has-menu :is(header, footer, .col-content) { transform: translate(-25%, 0); } .has-menu .col-menu { visibility: visible; transform: translate(0, 0); display: grid; grid-template-rows: auto 1fr; max-height: 100vh; } .has-menu .tsd-navigation { max-height: 100%; } } .tsd-page-title { padding: 70px 0 20px 0; margin: 0 0 40px 0; background: var(--color-panel); box-shadow: 0 0 5px rgba(0, 0, 0, 0.35); } .tsd-page-title h1 { margin: 0; } .tsd-breadcrumb { margin: 0; padding: 0; color: var(--color-text-aside); } .tsd-breadcrumb a { color: var(--color-text-aside); text-decoration: none; } .tsd-breadcrumb a:hover { text-decoration: underline; } .tsd-breadcrumb li { display: inline; } .tsd-breadcrumb li:after { content: " / "; } dl.tsd-comment-tags { overflow: hidden; } dl.tsd-comment-tags dt { float: left; padding: 1px 5px; margin: 0 10px 0 0; border-radius: 4px; border: 1px solid var(--color-comment-tag); color: var(--color-comment-tag); font-size: 0.8em; font-weight: normal; } dl.tsd-comment-tags dd { margin: 0 0 10px 0; } dl.tsd-comment-tags dd:before, dl.tsd-comment-tags dd:after { display: table; content: " "; } dl.tsd-comment-tags dd pre, dl.tsd-comment-tags dd:after { clear: both; } dl.tsd-comment-tags p { margin: 0; } .tsd-panel.tsd-comment .lead { font-size: 1.1em; line-height: 1.333em; margin-bottom: 2em; } .tsd-panel.tsd-comment .lead:last-child { margin-bottom: 0; } .toggle-protected .tsd-is-private { display: none; } .toggle-public .tsd-is-private, .toggle-public .tsd-is-protected, .toggle-public .tsd-is-private-protected { display: none; } .toggle-inherited .tsd-is-inherited { display: none; } .toggle-externals .tsd-is-external { display: none; } #tsd-filter { position: relative; display: inline-block; height: 40px; vertical-align: bottom; } .no-filter #tsd-filter { display: none; } #tsd-filter .tsd-filter-group { display: inline-block; height: 40px; vertical-align: bottom; white-space: nowrap; } #tsd-filter input { display: none; } @media (max-width: 900px) { #tsd-filter .tsd-filter-group { display: block; position: absolute; top: 40px; right: 20px; height: auto; background-color: var(--color-panel); visibility: hidden; transform: translate(50%, 0); box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); } .has-options #tsd-filter .tsd-filter-group { visibility: visible; } .to-has-options #tsd-filter .tsd-filter-group { animation: fade-in 0.2s; } .from-has-options #tsd-filter .tsd-filter-group { animation: fade-out 0.2s; } #tsd-filter label, #tsd-filter .tsd-select { display: block; padding-right: 20px; } } footer { border-top: 1px solid var(--color-panel-divider); background-color: var(--color-panel); } footer:after { content: ""; display: table; } footer.with-border-bottom { border-bottom: 1px solid var(--color-panel-divider); } footer .tsd-legend-group { font-size: 0; } footer .tsd-legend { display: inline-block; width: 25%; padding: 0; font-size: 16px; list-style: none; line-height: 1.333em; vertical-align: top; } @media (max-width: 900px) { footer .tsd-legend { width: 50%; } } .tsd-hierarchy { list-style: square; padding: 0 0 0 20px; margin: 0; } .tsd-hierarchy .target { font-weight: bold; } .tsd-index-panel .tsd-index-content { margin-bottom: -30px !important; } .tsd-index-panel .tsd-index-section { margin-bottom: 30px !important; } .tsd-index-panel h3 { margin: 0 -20px 10px -20px; padding: 0 20px 10px 20px; border-bottom: 1px solid var(--color-panel-divider); } .tsd-index-panel ul.tsd-index-list { -webkit-column-count: 3; -moz-column-count: 3; -ms-column-count: 3; -o-column-count: 3; column-count: 3; -webkit-column-gap: 20px; -moz-column-gap: 20px; -ms-column-gap: 20px; -o-column-gap: 20px; column-gap: 20px; padding: 0; list-style: none; line-height: 1.333em; } @media (max-width: 900px) { .tsd-index-panel ul.tsd-index-list { -webkit-column-count: 1; -moz-column-count: 1; -ms-column-count: 1; -o-column-count: 1; column-count: 1; } } @media (min-width: 901px) and (max-width: 1024px) { .tsd-index-panel ul.tsd-index-list { -webkit-column-count: 2; -moz-column-count: 2; -ms-column-count: 2; -o-column-count: 2; column-count: 2; } } .tsd-index-panel ul.tsd-index-list li { -webkit-page-break-inside: avoid; -moz-page-break-inside: avoid; -ms-page-break-inside: avoid; -o-page-break-inside: avoid; page-break-inside: avoid; } .tsd-index-panel a, .tsd-index-panel .tsd-parent-kind-module a { color: var(--color-ts); } .tsd-index-panel .tsd-parent-kind-interface a { color: var(--color-ts-interface); } .tsd-index-panel .tsd-parent-kind-enum a { color: var(--color-ts-enum); } .tsd-index-panel .tsd-parent-kind-class a { color: var(--color-ts-class); } .tsd-index-panel .tsd-kind-module a { color: var(--color-ts); } .tsd-index-panel .tsd-kind-interface a { color: var(--color-ts-interface); } .tsd-index-panel .tsd-kind-enum a { color: var(--color-ts-enum); } .tsd-index-panel .tsd-kind-class a { color: var(--color-ts-class); } .tsd-index-panel .tsd-is-private a { color: var(--color-ts-private); } .tsd-flag { display: inline-block; padding: 1px 5px; border-radius: 4px; color: var(--color-comment-tag-text); background-color: var(--color-comment-tag); text-indent: 0; font-size: 14px; font-weight: normal; } .tsd-anchor { position: absolute; top: -100px; } .tsd-member { position: relative; } .tsd-member .tsd-anchor + h3 { margin-top: 0; margin-bottom: 0; border-bottom: none; } .tsd-member [data-tsd-kind] { color: var(--color-ts); } .tsd-member [data-tsd-kind="Interface"] { color: var(--color-ts-interface); } .tsd-member [data-tsd-kind="Enum"] { color: var(--color-ts-enum); } .tsd-member [data-tsd-kind="Class"] { color: var(--color-ts-class); } .tsd-member [data-tsd-kind="Private"] { color: var(--color-ts-private); } .tsd-navigation { margin: 0 0 0 40px; } .tsd-navigation a { display: block; padding-top: 2px; padding-bottom: 2px; border-left: 2px solid transparent; color: var(--color-text); text-decoration: none; transition: border-left-color 0.1s; } .tsd-navigation a:hover { text-decoration: underline; } .tsd-navigation ul { margin: 0; padding: 0; list-style: none; } .tsd-navigation li { padding: 0; } .tsd-navigation.primary { padding-bottom: 40px; } .tsd-navigation.primary a { display: block; padding-top: 6px; padding-bottom: 6px; } .tsd-navigation.primary ul li a { padding-left: 5px; } .tsd-navigation.primary ul li li a { padding-left: 25px; } .tsd-navigation.primary ul li li li a { padding-left: 45px; } .tsd-navigation.primary ul li li li li a { padding-left: 65px; } .tsd-navigation.primary ul li li li li li a { padding-left: 85px; } .tsd-navigation.primary ul li li li li li li a { padding-left: 105px; } .tsd-navigation.primary > ul { border-bottom: 1px solid var(--color-panel-divider); } .tsd-navigation.primary li { border-top: 1px solid var(--color-panel-divider); } .tsd-navigation.primary li.current > a { font-weight: bold; } .tsd-navigation.primary li.label span { display: block; padding: 20px 0 6px 5px; color: var(--color-menu-label); } .tsd-navigation.primary li.globals + li > span, .tsd-navigation.primary li.globals + li > a { padding-top: 20px; } .tsd-navigation.secondary { max-height: calc(100vh - 1rem - 40px); overflow: auto; position: sticky; top: calc(0.5rem + 40px); transition: 0.3s; } .tsd-navigation.secondary.tsd-navigation--toolbar-hide { max-height: calc(100vh - 1rem); top: 0.5rem; } .tsd-navigation.secondary ul { transition: opacity 0.2s; } .tsd-navigation.secondary ul li a { padding-left: 25px; } .tsd-navigation.secondary ul li li a { padding-left: 45px; } .tsd-navigation.secondary ul li li li a { padding-left: 65px; } .tsd-navigation.secondary ul li li li li a { padding-left: 85px; } .tsd-navigation.secondary ul li li li li li a { padding-left: 105px; } .tsd-navigation.secondary ul li li li li li li a { padding-left: 125px; } .tsd-navigation.secondary ul.current a { border-left-color: var(--color-panel-divider); } .tsd-navigation.secondary li.focus > a, .tsd-navigation.secondary ul.current li.focus > a { border-left-color: var(--color-menu-divider-focus); } .tsd-navigation.secondary li.current { margin-top: 20px; margin-bottom: 20px; border-left-color: var(--color-panel-divider); } .tsd-navigation.secondary li.current > a { font-weight: bold; } @media (min-width: 901px) { .menu-sticky-wrap { position: static; } } .tsd-panel { margin: 20px 0; padding: 20px; background-color: var(--color-panel); box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); } .tsd-panel:empty { display: none; } .tsd-panel > h1, .tsd-panel > h2, .tsd-panel > h3 { margin: 1.5em -20px 10px -20px; padding: 0 20px 10px 20px; border-bottom: 1px solid var(--color-panel-divider); } .tsd-panel > h1.tsd-before-signature, .tsd-panel > h2.tsd-before-signature, .tsd-panel > h3.tsd-before-signature { margin-bottom: 0; border-bottom: 0; } .tsd-panel table { display: block; width: 100%; overflow: auto; margin-top: 10px; word-break: normal; word-break: keep-all; border-collapse: collapse; } .tsd-panel table th { font-weight: bold; } .tsd-panel table th, .tsd-panel table td { padding: 6px 13px; border: 1px solid var(--color-panel-divider); } .tsd-panel table tr { background: var(--color-background); } .tsd-panel table tr:nth-child(even) { background: var(--color-secondary-background); } .tsd-panel-group { margin: 60px 0; } .tsd-panel-group > h1, .tsd-panel-group > h2, .tsd-panel-group > h3 { padding-left: 20px; padding-right: 20px; } #tsd-search { transition: background-color 0.2s; } #tsd-search .title { position: relative; z-index: 2; } #tsd-search .field { position: absolute; left: 0; top: 0; right: 40px; height: 40px; } #tsd-search .field input { box-sizing: border-box; position: relative; top: -50px; z-index: 1; width: 100%; padding: 0 10px; opacity: 0; outline: 0; border: 0; background: transparent; color: var(--color-text); } #tsd-search .field label { position: absolute; overflow: hidden; right: -40px; } #tsd-search .field input, #tsd-search .title { transition: opacity 0.2s; } #tsd-search .results { position: absolute; visibility: hidden; top: 40px; width: 100%; margin: 0; padding: 0; list-style: none; box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); } #tsd-search .results li { padding: 0 10px; background-color: var(--color-background); } #tsd-search .results li:nth-child(even) { background-color: var(--color-panel); } #tsd-search .results li.state { display: none; } #tsd-search .results li.current, #tsd-search .results li:hover { background-color: var(--color-panel-divider); } #tsd-search .results a { display: block; } #tsd-search .results a:before { top: 10px; } #tsd-search .results span.parent { color: var(--color-text-aside); font-weight: normal; } #tsd-search.has-focus { background-color: var(--color-panel-divider); } #tsd-search.has-focus .field input { top: 0; opacity: 1; } #tsd-search.has-focus .title { z-index: 0; opacity: 0; } #tsd-search.has-focus .results { visibility: visible; } #tsd-search.loading .results li.state.loading { display: block; } #tsd-search.failure .results li.state.failure { display: block; } .tsd-signature { margin: 0 0 1em 0; padding: 10px; border: 1px solid var(--color-panel-divider); font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 14px; overflow-x: auto; } .tsd-signature.tsd-kind-icon { padding-left: 30px; } .tsd-signature.tsd-kind-icon:before { top: 10px; left: 10px; } .tsd-panel > .tsd-signature { margin-left: -20px; margin-right: -20px; border-width: 1px 0; } .tsd-panel > .tsd-signature.tsd-kind-icon { padding-left: 40px; } .tsd-panel > .tsd-signature.tsd-kind-icon:before { left: 20px; } .tsd-signature-symbol { color: var(--color-text-aside); font-weight: normal; } .tsd-signature-type { font-style: italic; font-weight: normal; } .tsd-signatures { padding: 0; margin: 0 0 1em 0; border: 1px solid var(--color-panel-divider); } .tsd-signatures .tsd-signature { margin: 0; border-width: 1px 0 0 0; transition: background-color 0.1s; } .tsd-signatures .tsd-signature:first-child { border-top-width: 0; } .tsd-signatures .tsd-signature.current { background-color: var(--color-panel-divider); } .tsd-signatures.active > .tsd-signature { cursor: pointer; } .tsd-panel > .tsd-signatures { margin-left: -20px; margin-right: -20px; border-width: 1px 0; } .tsd-panel > .tsd-signatures .tsd-signature.tsd-kind-icon { padding-left: 40px; } .tsd-panel > .tsd-signatures .tsd-signature.tsd-kind-icon:before { left: 20px; } .tsd-panel > a.anchor + .tsd-signatures { border-top-width: 0; margin-top: -20px; } ul.tsd-descriptions { position: relative; overflow: hidden; padding: 0; list-style: none; } ul.tsd-descriptions.active > .tsd-description { display: none; } ul.tsd-descriptions.active > .tsd-description.current { display: block; } ul.tsd-descriptions.active > .tsd-description.fade-in { animation: fade-in-delayed 0.3s; } ul.tsd-descriptions.active > .tsd-description.fade-out { animation: fade-out-delayed 0.3s; position: absolute; display: block; top: 0; left: 0; right: 0; opacity: 0; visibility: hidden; } ul.tsd-descriptions h4, ul.tsd-descriptions .tsd-index-panel h3, .tsd-index-panel ul.tsd-descriptions h3 { font-size: 16px; margin: 1em 0 0.5em 0; } ul.tsd-parameters, ul.tsd-type-parameters { list-style: square; margin: 0; padding-left: 20px; } ul.tsd-parameters > li.tsd-parameter-signature, ul.tsd-type-parameters > li.tsd-parameter-signature { list-style: none; margin-left: -20px; } ul.tsd-parameters h5, ul.tsd-type-parameters h5 { font-size: 16px; margin: 1em 0 0.5em 0; } ul.tsd-parameters .tsd-comment, ul.tsd-type-parameters .tsd-comment { margin-top: -0.5em; } .tsd-sources { font-size: 14px; color: var(--color-text-aside); margin: 0 0 1em 0; } .tsd-sources a { color: var(--color-text-aside); text-decoration: underline; } .tsd-sources ul, .tsd-sources p { margin: 0 !important; } .tsd-sources ul { list-style: none; padding: 0; } .tsd-page-toolbar { position: fixed; z-index: 1; top: 0; left: 0; width: 100%; height: 40px; color: var(--color-toolbar-text); background: var(--color-toolbar); border-bottom: 1px solid var(--color-panel-divider); transition: transform 0.3s linear; } .tsd-page-toolbar a { color: var(--color-toolbar-text); text-decoration: none; } .tsd-page-toolbar a.title { font-weight: bold; } .tsd-page-toolbar a.title:hover { text-decoration: underline; } .tsd-page-toolbar .table-wrap { display: table; width: 100%; height: 40px; } .tsd-page-toolbar .table-cell { display: table-cell; position: relative; white-space: nowrap; line-height: 40px; } .tsd-page-toolbar .table-cell:first-child { width: 100%; } .tsd-page-toolbar--hide { transform: translateY(-100%); } .tsd-select .tsd-select-list li:before, .tsd-select .tsd-select-label:before, .tsd-widget:before { content: ""; display: inline-block; width: 40px; height: 40px; margin: 0 -8px 0 0; background-image: url(./widgets.png); background-repeat: no-repeat; text-indent: -1024px; vertical-align: bottom; filter: var(--icon-filter); } @media (-webkit-min-device-pixel-ratio: 1.5), (min-resolution: 144dpi) { .tsd-select .tsd-select-list li:before, .tsd-select .tsd-select-label:before, .tsd-widget:before { background-image: url(./widgets@2x.png); background-size: 320px 40px; } } .tsd-widget { display: inline-block; overflow: hidden; opacity: 0.8; height: 40px; transition: opacity 0.1s, background-color 0.2s; vertical-align: bottom; cursor: pointer; } .tsd-widget:hover { opacity: 0.9; } .tsd-widget.active { opacity: 1; background-color: var(--color-panel-divider); } .tsd-widget.no-caption { width: 40px; } .tsd-widget.no-caption:before { margin: 0; } .tsd-widget.search:before { background-position: 0 0; } .tsd-widget.menu:before { background-position: -40px 0; } .tsd-widget.options:before { background-position: -80px 0; } .tsd-widget.options, .tsd-widget.menu { display: none; } @media (max-width: 900px) { .tsd-widget.options, .tsd-widget.menu { display: inline-block; } } input[type="checkbox"] + .tsd-widget:before { background-position: -120px 0; } input[type="checkbox"]:checked + .tsd-widget:before { background-position: -160px 0; } .tsd-select { position: relative; display: inline-block; height: 40px; transition: opacity 0.1s, background-color 0.2s; vertical-align: bottom; cursor: pointer; } .tsd-select .tsd-select-label { opacity: 0.6; transition: opacity 0.2s; } .tsd-select .tsd-select-label:before { background-position: -240px 0; } .tsd-select.active .tsd-select-label { opacity: 0.8; } .tsd-select.active .tsd-select-list { visibility: visible; opacity: 1; transition-delay: 0s; } .tsd-select .tsd-select-list { position: absolute; visibility: hidden; top: 40px; left: 0; margin: 0; padding: 0; opacity: 0; list-style: none; box-shadow: 0 0 4px rgba(0, 0, 0, 0.25); transition: visibility 0s 0.2s, opacity 0.2s; } .tsd-select .tsd-select-list li { padding: 0 20px 0 0; background-color: var(--color-background); } .tsd-select .tsd-select-list li:before { background-position: 40px 0; } .tsd-select .tsd-select-list li:nth-child(even) { background-color: var(--color-panel); } .tsd-select .tsd-select-list li:hover { background-color: var(--color-panel-divider); } .tsd-select .tsd-select-list li.selected:before { background-position: -200px 0; } @media (max-width: 900px) { .tsd-select .tsd-select-list { top: 0; left: auto; right: 100%; margin-right: -5px; } .tsd-select .tsd-select-label:before { background-position: -280px 0; } } img { max-width: 100%; } ================================================ FILE: docs/reference/classes/meyda_wa.MeydaAnalyzer.html ================================================ MeydaAnalyzer | meyda
Options
All
  • Public
  • Public/Protected
  • All
Menu

Class MeydaAnalyzer

Meyda's interface to the Web Audio API. MeydaAnalyzer abstracts an API on top of the Web Audio API's ScriptProcessorNode, running the Meyda audio feature extractors inside that context.

MeydaAnalyzer's constructor should not be called directly - MeydaAnalyzer objects should be generated using the createMeydaAnalyzer factory function in the main Meyda class.

Options are of type MeydaAnalyzerOptions.

example
const analyzer = Meyda.createMeydaAnalyzer({
"audioContext": audioContext,
"source": source,
"bufferSize": 512,
"featureExtractors": ["rms"],
"inputs": 2,
"numberOfMFCCCoefficients": 20
"callback": features => {
levelRangeElement.value = features.rms;
}
});

Hierarchy

  • MeydaAnalyzer

Index

Methods

get

setChannel

  • setChannel(channel: number): void
  • Set the channel of the audio node for Meyda to listen to

    example
    analyzer.setChannel(0);
    

    Parameters

    • channel: number

      the index of the channel on the input audio node for Meyda to listen to.

    Returns void

setSource

  • setSource(source: AudioNode): void
  • Set the Audio Node for Meyda to listen to.

    example
    analyzer.setSource(audioSourceNode);
    

    Parameters

    • source: AudioNode

      The Audio Node for Meyda to listen to

    Returns void

start

  • Start feature extraction The audio features will be passed to the callback function that was defined in the MeydaOptions that were passed to the factory when constructing the MeydaAnalyzer.

    example
    analyzer.start('chroma');
    

    Parameters

    Returns void

stop

  • stop(): void

Legend

  • Variable
  • Type alias
  • Interface
  • Interface with type parameter
  • Class
  • Method

Settings

Theme

Generated using TypeDoc

================================================ FILE: docs/reference/index.html ================================================ meyda
Options
All
  • Public
  • Public/Protected
  • All
Menu

meyda

Legend

  • Variable
  • Type alias
  • Interface
  • Interface with type parameter
  • Class

Settings

Theme

Generated using TypeDoc

================================================ FILE: docs/reference/interfaces/Meyda.MeydaFeaturesObject.html ================================================ MeydaFeaturesObject | meyda
Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface MeydaFeaturesObject

Hierarchy

  • MeydaFeaturesObject

Index

Properties

amplitudeSpectrum

amplitudeSpectrum: Float32Array

buffer

buffer: number[]

chroma

chroma: number[]

complexSpectrum

complexSpectrum: { imag: number[]; real: number[] }

Type declaration

  • imag: number[]
  • real: number[]

energy

energy: number

loudness

loudness: { specific: Float32Array; total: number }

Type declaration

  • specific: Float32Array
  • total: number

mfcc

mfcc: number[]

perceptualSharpness

perceptualSharpness: number

perceptualSpread

perceptualSpread: number

powerSpectrum

powerSpectrum: Float32Array

rms

rms: number

spectralCentroid

spectralCentroid: number

spectralFlatness

spectralFlatness: number

spectralKurtosis

spectralKurtosis: number

spectralRolloff

spectralRolloff: number

spectralSkewness

spectralSkewness: number

spectralSlope

spectralSlope: number

spectralSpread

spectralSpread: number

zcr

zcr: number

Legend

  • Interface
  • Interface with type parameter
  • Property
  • Variable
  • Type alias
  • Class

Settings

Theme

Generated using TypeDoc

================================================ FILE: docs/reference/interfaces/Meyda.SliceableArrayLike.html ================================================ SliceableArrayLike | meyda
Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface SliceableArrayLike<T>

Type parameters

  • T

Hierarchy

  • ArrayLike<T>
    • SliceableArrayLike

Index

Properties

Methods

Properties

Readonly length

length: number

Methods

slice

Legend

  • Interface
  • Interface with type parameter
  • Method
  • Variable
  • Type alias
  • Class

Settings

Theme

Generated using TypeDoc

================================================ FILE: docs/reference/interfaces/Meyda.default.html ================================================ default | meyda
Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface default

Meyda is a library for extracting audio features from an audio signal.

The primary entry points are extract for audio feature extraction on raw signals you have in memory, and createMeydaAnalyzer, which provides a MeydaAnalyzer object that can be used to extract features on a Web Audio API AudioNode. The latter is only supported on web targets, though if you're using the Web Audio API in a non-web target, we'd love to hear from you.

We also expose listAvailableFeatureExtractors which returns a list of the available feature extractors, and windowing, which lets you apply a windowing function to your signal outside of Meyda.

We existed long before esmodules, so our backwards compatible API may seem unusual. We export a default object, with read/write fields that control various parameters of the audio feature extraction process. We're working on a new interface, check out #257 for more information.

Hierarchy

  • default

Index

Properties

audioContext

audioContext: null | AudioContext

Meyda stores a reference to the relevant audio context here for use inside the Web Audio API.

bufferSize

bufferSize: number

The length of each buffer that Meyda will extract audio on. When recieving input via the Web Audio API, the Script Processor Node chunks incoming audio into arrays of this length. Longer buffers allow for more precision in the frequency domain, but increase the amount of time it takes for Meyda to output a set of audio features for the buffer. You can calculate how many sets of audio features Meyda will output per second by dividing the buffer size by the sample rate. If you're using Meyda for visualisation, make sure that you're collecting audio features at a rate that's faster than or equal to the video frame rate you expect.

chromaBands

chromaBands: number

The number of bands to divide the spectrum into for the Chroma feature extractor. 12 is the standard number of semitones per octave in the western music tradition, but Meyda can use an arbitrary number of bands, which can be useful for microtonal music.

featureExtractors

featureExtractors: any

melBands

melBands: number

The number of Mel bands to use in the Mel Frequency Cepstral Co-efficients feature extractor

numberOfMFCCCoefficients

numberOfMFCCCoefficients: number

The number of MFCC co-efficients that the MFCC feature extractor should return

sampleRate

sampleRate: number

The number of samples per second of the incoming audio. This affects feature extraction outside of the context of the Web Audio API, and must be set accurately - otherwise calculations will be off.

windowingFunction

windowingFunction: string

Specify the windowing function to apply to the buffer before the transformation from the time domain to the frequency domain is performed

The default windowing function is the hanning window.

Methods

createMeydaAnalyzer

  • summary

    Create a MeydaAnalyzer

    A factory function for creating a MeydaAnalyzer, the interface for using Meyda in the context of Web Audio.

    example
    const analyzer = Meyda.createMeydaAnalyzer({
    "audioContext": audioContext,
    "source": source,
    "bufferSize": 512,
    "featureExtractors": ["rms"],
    "inputs": 2,
    "callback": features => {
    levelRangeElement.value = features.rms;
    }
    });

    Parameters

    • MeydaAnalyzerOptions: any

    Returns MeydaAnalyzer

extract

  • Extract an audio feature from a buffer

    Unless meyda.windowingFunction is set otherwise, extract will internally apply a hanning window to the buffer prior to conversion into the frequency domain.

    example
    meyda.bufferSize = 2048;
    const features = meyda.extract(['zcr', 'spectralCentroid'], signal);

    Aside: yes, you need to modify the value of a field of the default export of the package to change the buffer size. We realise this now seems not a good practice. See this issue to track our progress on implementing a more modern API.

    Parameters

    Returns null | Partial<MeydaFeaturesObject>

    Features

listAvailableFeatureExtractors

  • List available audio feature extractors. Return format provides the key to be used in selecting the extractor in the extract methods

    Returns MeydaAudioFeature[]

windowing

Legend

  • Interface
  • Interface with type parameter
  • Property
  • Method
  • Variable
  • Type alias
  • Class

Settings

Theme

Generated using TypeDoc

================================================ FILE: docs/reference/interfaces/meyda_wa.MeydaAnalyzerOptions.html ================================================ MeydaAnalyzerOptions | meyda
Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface MeydaAnalyzerOptions

MeydaAnalyzerOptions

Hierarchy

  • MeydaAnalyzerOptions

Index

Properties

audioContext

audioContext: AudioContext

The Audio Context for the MeydaAnalyzer to operate in.

bufferSize

bufferSize: number

The size of the buffer.

Optional callback

callback?: (features: Partial<MeydaFeaturesObject>) => void

Type declaration

    • The callback to receive your audio features. Will be called once for each buffer of input audio.

      Parameters

      Returns void

Optional channel

channel?: number

The channel from the input node to listen to

Optional featureExtractors

featureExtractors?: MeydaAudioFeature | readonly MeydaAudioFeature[]

What feature extractors to return to the callback.

Optional hopSize

hopSize?: number

The number of samples between the start of each buffer.

Optional inputs

inputs?: number

Optional numberOfMFCCCoefficients

numberOfMFCCCoefficients?: number

The number of mfcc coefficients to calculate for each buffer.

Optional outputs

outputs?: number

Optional sampleRate

sampleRate?: number

The number of samples per second in the audioContext.

source

source: AudioNode

The Audio Node for Meyda to listen to.

Optional startImmediately

startImmediately?: boolean

Pass true to start feature extraction immediately

Optional windowingFunction

windowingFunction?: MeydaWindowingFunction

The Windowing Function to apply to the signal before transformation to the frequency domain.

Legend

  • Interface
  • Interface with type parameter
  • Property
  • Variable
  • Type alias
  • Class

Settings

Theme

Generated using TypeDoc

================================================ FILE: docs/reference/modules/Meyda.html ================================================ Meyda | meyda
Options
All
  • Public
  • Public/Protected
  • All
Menu

Module Meyda

This file contains the default export for Meyda, you probably want to check out default

Index

Type aliases

MeydaAudioFeature

MeydaAudioFeature: "amplitudeSpectrum" | "chroma" | "complexSpectrum" | "energy" | "loudness" | "mfcc" | "perceptualSharpness" | "perceptualSpread" | "powerSpectrum" | "rms" | "spectralCentroid" | "spectralFlatness" | "spectralFlux" | "spectralKurtosis" | "spectralRolloff" | "spectralSkewness" | "spectralSlope" | "spectralSpread" | "zcr" | "buffer"

MeydaSignal

MeydaSignal: SliceableArrayLike<number> | Float32Array

A type representing an audio signal. In general it should be an array of numbers that is sliceable. Float32Array is assignable here, and we generally expect that most signals will be in this format.

MeydaWindowingFunction

MeydaWindowingFunction: "blackman" | "sine" | "hanning" | "hamming"

Variables

default

default: default

Legend

  • Variable
  • Type alias
  • Interface
  • Interface with type parameter
  • Class

Settings

Theme

Generated using TypeDoc

================================================ FILE: docs/reference/modules/meyda_wa.html ================================================ meyda-wa | meyda
Options
All
  • Public
  • Public/Protected
  • All
Menu

Module meyda-wa

Legend

  • Variable
  • Type alias
  • Interface
  • Interface with type parameter
  • Class

Settings

Theme

Generated using TypeDoc

================================================ FILE: docs/rollup.config.js ================================================ import nodePolyfills from "rollup-plugin-node-polyfills"; import { nodeResolve } from "@rollup/plugin-node-resolve"; import { terser } from "rollup-plugin-terser"; import commonjs from "@rollup/plugin-commonjs"; import typescript from "@rollup/plugin-typescript"; export default { input: "./src/main.ts", output: { file: "./assets/main.js", format: "iife", name: "meydaDemo", }, plugins: [ nodePolyfills(), nodeResolve({ browser: true, }), commonjs(), typescript(), terser(), ], }; ================================================ FILE: docs/showcase.md ================================================ --- layout: default --- Here's a list of examples of projects that use Meyda. Would you like your Meyda project to be featured in our user showcase? [Please let us know!](https://github.com/meyda/meyda/issues/new?assignees=&labels=Showcase+Request&template=showcase-application.md&title=) - [modV](https://github.com/2xAA/modV) by [Sam Wray/2xAA](https://twitter.com/_2xAA) > A real time music visualisation VJing platform for use in live-performance contexts. Great with some chiptune! - [audiotrainer-server](https://github.com/Number-42/audiotrainer-server) by [Number-42](https://github.com/Number-42). > A simple program meant to correlate increases in heart rate in ASD-diagnosed children to changes in the features of ambient sounds (both sets of data prerecorded over the same period of time) with the intent of optimizing a training program helping them cope with sounds abnormally stress-inducing to them. - [OSEM](https://uduk.org/osem/) by [@uduk](https://github.com/uduk) > A computer generated melody project, optionally users can plug-in their guitar and/or MIDI key controller to dictate input harmonic. Meyda.js is being used to extract audio signal features, such as beat dynamic and music segmentation in order to help OSEM to produce high-quality music melody. It is meant to answer the question: "Given an arbitrary backing track (format: wav, mp3) can computer compose?" - [Picognizer](https://github.com/qurihara/picognizer) by [@qurihara](https://github.com/qurihara) > Picognizer is the 100% JavaScript library for detecting synthesized sounds (e.g. sound effects of video games, replayed speech or music, and sound alerts of home appliances). You can run it on your web browser without any server-side systems. - [Kaos Logo Generator](https://lusion.co/work/kaos-logo-generator/) by [Lusion](https://lusion.co/) > A system that allows web users to generate their unique logos using their voices - [threejs-meydajs-fftspectrum](https://threejs-meydajs-fftspectrum.surge.sh/) by [Andrea Bovo/spleennooname](https://github.com/spleennooname) > A spectrum fft on steroids: picks up microphone from audio stream and drives the webgl effect. - [Fluid Corpus Manipulation](https://learn.flucoma.org/reference/chroma/) by [Fluid Corpus Manipulation (James Bradbury, Ted Moore, Owen Green, Pierre Alexandre Tremblay)](https://www.flucoma.org/) > The Fluid Corpus Manipulation project(FluCoMa)instigates new musical ways of exploiting ever-growing banks of sound and gestures within the digital composition process, by bringing breakthroughs of signal decomposition DSP and machine learning to the toolset of techno-fluent computer composers, creative coders and digital artists. ================================================ FILE: docs/src/audio.ts ================================================ import * as Meyda from "meyda"; var _this; const Audio = function (bufferSize) { if ( Object.prototype.hasOwnProperty.call(window, "webkitAudioContext") && !Object.prototype.hasOwnProperty.call(window, "AudioContext") ) { // @ts-ignore window.AudioContext = webkitAudioContext; } if ( Object.prototype.hasOwnProperty.call(navigator, "webkitGetUserMedia") && !Object.prototype.hasOwnProperty.call(navigator, "getUserMedia") ) { // @ts-ignore navigator.getUserMedia = webkitGetUserMedia; if ( !Object.prototype.hasOwnProperty.call( AudioContext.prototype, "createScriptProcessor" ) ) { AudioContext.prototype.createScriptProcessor = // @ts-ignore AudioContext.prototype.createJavaScriptNode; } } this.context = new AudioContext(); let elvis = document.getElementById("elvisSong"); let stream = this.context.createMediaElementSource(elvis); stream.connect(this.context.destination); this.meyda = Meyda.createMeydaAnalyzer({ audioContext: this.context, source: stream, bufferSize: bufferSize, windowingFunction: "blackman", }); // eslint-disable-next-line @typescript-eslint/no-this-alias _this = this; this.initializeMicrophoneSampling(); }; Audio.prototype.initializeMicrophoneSampling = function () { var errorCallback = function () { // We should fallback to an audio file here, but that's difficult on mobile if (_this.context.state === "suspended") { var resume = function () { _this.context.resume(); setTimeout(function () { if (_this.context.state === "running") { document.body.removeEventListener("touchend", resume, false); } }, 0); }; document.body.addEventListener("touchend", resume, false); } }; try { const getUserMedia = // @ts-ignore navigator.webkitGetUserMedia || // @ts-ignore navigator.getUserMedia || navigator.mediaDevices.getUserMedia; var constraints = { video: false, audio: true, }; var successCallback = function successCallback(mediaStream) { document.getElementById("audioControl")!.style.display = "none"; console.log("User allowed microphone access."); console.log("Initializing AudioNode from MediaStream"); var source = _this.context.createMediaStreamSource(mediaStream); console.log("Setting Meyda Source to Microphone"); _this.meyda.setSource(source); console.groupEnd(); }; console.log("Asking for permission..."); navigator.mediaDevices .getUserMedia({ audio: true, }) .then(successCallback) .catch(function (error) { console.log(error); getUserMedia( { audio: true, }, successCallback, function (e) { errorCallback(); } ); }); } catch (e) { errorCallback(); } }; Audio.prototype.get = function (features) { _this.context.resume(); return _this.meyda.get(features); }; export default Audio; ================================================ FILE: docs/src/main.ts ================================================ import Audio from "./audio"; import { Scene, PerspectiveCamera, LineBasicMaterial, WebGLRenderer, DirectionalLight, Vector3, ArrowHelper, Group, BufferAttribute, BufferGeometry, Line, } from "three"; var scale = ["C", "C#", "D", "Eb", "E", "F", "F#", "G", "G#", "A", "Bb", "B"]; const bufferSize = 1024; let a = new Audio(bufferSize); var aspectRatio = 16 / 10; var scene = new Scene(); var camera = new PerspectiveCamera(40, aspectRatio, 0.1, 1000); var initializeFFTs = function (number, pointCount) { var ffts: number[][] = []; for (var i = 0; i < number; i++) { ffts.push( // Array.apply(null, Array(pointCount)).map(Number.prototype.valueOf, 0) Array(pointCount).fill(0) ); } return ffts; }; var material = new LineBasicMaterial({ color: 0x00ff00, }); var yellowMaterial = new LineBasicMaterial({ color: 0x00ffff, }); var ffts = initializeFFTs(20, bufferSize); var buffer = null; var renderer = new WebGLRenderer({ canvas: document.querySelector("canvas")!, }); function resize() { renderer.domElement.style.width = "100%"; renderer.domElement.style.height = "auto"; var resolution = (renderer.domElement.clientWidth / 16) * 10; renderer.setPixelRatio(window.devicePixelRatio ? window.devicePixelRatio : 1); renderer.setSize(resolution * aspectRatio, resolution); renderer.domElement.style.width = "100%"; renderer.domElement.style.height = "auto"; camera.aspect = (resolution * aspectRatio) / resolution; camera.updateProjectionMatrix(); } resize(); window.addEventListener("resize", resize); var directionalLight = new DirectionalLight(0xffffff, 0.5); directionalLight.position.set(0, 1, 1); scene.add(directionalLight); camera.position.z = 5; // Unchanging variables const length = 1; const hex = 0xffff00; const dir = new Vector3(0, 1, 0); const rightDir = new Vector3(1, 0, 0); const origin = new Vector3(1, -6, -15); // Variables we update let centroidArrow = new ArrowHelper(dir, origin, length, hex); let rolloffArrow = new ArrowHelper(dir, origin, length, 0x0000ff); let rmsArrow = new ArrowHelper(rightDir, origin, length, 0xff00ff); let lines = new Group(); // Lets create a seperate group for our lines // let loudnessLines = new Group(); scene.add(centroidArrow); scene.add(rolloffArrow); scene.add(rmsArrow); // Render Spectrogram for (let i = 0; i < ffts.length; i++) { if (ffts[i]) { let geometry = new BufferGeometry(); // May be a way to reuse this let positions: ArrayLike = new Float32Array(ffts[i].length * 3); geometry.addAttribute("position", new BufferAttribute(positions, 3)); geometry.setDrawRange(0, ffts[i].length); let line = new Line(geometry, material); lines.add(line); positions = line.geometry.attributes.position.array; } } let bufferLineGeometry = new BufferGeometry(); let bufferLine = new Line(bufferLineGeometry, material); { let positions: ArrayLike = new Float32Array(bufferSize * 3); bufferLineGeometry.addAttribute( "position", new BufferAttribute(positions, 3) ); bufferLineGeometry.setDrawRange(0, bufferSize); positions = bufferLine.geometry.attributes.position.array; } scene.add(bufferLine); scene.add(lines); // scene.add(loudnessLines); let features: { [key: string]: any } | undefined = undefined; let chromaWrapper = document.querySelector("#chroma"); let mfccWrapper = document.querySelector("#mfcc"); function render() { features = a.get([ "amplitudeSpectrum", "spectralCentroid", "spectralRolloff", "loudness", "rms", "chroma", "mfcc", ]); if (features) { if (chromaWrapper && features.chroma) { chromaWrapper.innerHTML = features.chroma.reduce( (acc, v, i) => `${acc}
${scale[i]}
`, "" ); } if (mfccWrapper && features.mfcc) { mfccWrapper.innerHTML = features.mfcc.reduce( (acc, v, i) => `${acc}
${i}
`, "" ); } ffts.pop(); ffts.unshift(features.amplitudeSpectrum); const windowedSignalBuffer = a.meyda._m.signal; for (let i = 0; i < ffts.length; i++) { // @ts-ignore var positions = lines.children[i].geometry.attributes.position.array; var index = 0; for (var j = 0; j < ffts[i].length * 3; j++) { positions[index++] = 10.7 + 8 * Math.log10(j / ffts[i].length); positions[index++] = -5 + 0.1 * ffts[i][j]; positions[index++] = -15 - i; } // @ts-ignore lines.children[i].geometry.attributes.position.needsUpdate = true; } // Render Spectral Centroid Arrow if (features.spectralCentroid) { // SpectralCentroid is an awesome variable name // We're really just updating the x axis centroidArrow.position.set( 10.7 + 8 * Math.log10(features.spectralCentroid / (bufferSize / 2)), -6, -15 ); } // Render Spectral Rolloff Arrow if (features.spectralRolloff) { // We're really just updating the x axis var rolloff = features.spectralRolloff / 22050; rolloffArrow.position.set(10.7 + 8 * Math.log10(rolloff), -6, -15); } // Render RMS Arrow if (features.rms) { // We're really just updating the y axis rmsArrow.position.set(-11, -5 + 10 * features.rms, -15); } if (windowedSignalBuffer) { // Render Signal Buffer let positions = bufferLine.geometry.attributes.position.array; let index = 0; for (var i = 0; i < bufferSize; i++) { // @ts-ignore positions[index++] = -11 + (22 * i) / bufferSize; // @ts-ignore positions[index++] = 4 + windowedSignalBuffer[i] * 5; // @ts-ignore positions[index++] = -25; } bufferLine.geometry.attributes.position.needsUpdate = true; } // // Render loudness // if (features.loudness && features.loudness.specific) { // for (var i = 0; i < features.loudness.specific.length; i++) { // let geometry = new Geometry(); // geometry.vertices.push(new Vector3( // -11 + 22 * i / features.loudness.specific.length, // -6 + features.loudness.specific[i] * 3, // -15 // )); // geometry.vertices.push(new Vector3( // -11 + 22 * i / features.loudness.specific.length + 22 / // features.loudness.specific.length, // -6 + features.loudness.specific[i] * 3, // -15 // )); // loudnessLines.add(new Line(geometry, yellowMaterial)); // geometry.dispose(); // } // } // for (let c = 0; c < loudnessLines.children.length; c++) { // loudnessLines.remove(loudnessLines.children[c]); //forEach is slow // } } requestAnimationFrame(render); renderer.render(scene, camera); } render(); ================================================ FILE: package.json ================================================ { "name": "meyda", "version": "0.0.0-development", "description": "Real-time feature extraction for the web audio api", "main": "./dist/node/main.js", "browser": "./dist/web/meyda.min.js", "jsnext:main": "./dist/esm/main.js", "types": "./dist/esm/main.d.ts", "bin": { "meyda": "./bin/cli.js" }, "scripts": { "test": "jest", "build": "NODE_ENV=production; tsc && rollup -c rollup.config.mjs", "lint": "tsc --noEmit && eslint -f compact --ext .js,.jsx,.ts,.tsx src __tests__ docs/src bin", "generatereferencedocs": "typedoc src/meyda-wa.ts src/main.ts --out docs/reference --readme none", "semantic-release": "semantic-release", "prepare": "husky install" }, "repository": { "type": "git", "url": "https://github.com/meyda/meyda.git" }, "keywords": [ "audio", "feature", "extraction", "music", "sound", "information", "retrieval" ], "authors": [ "Hugh Rawlinson ", "Nevo Segal ", "Jakub Fiala", "Sam Wray " ], "license": "MIT", "bugs": { "url": "https://github.com/meyda/meyda/issues" }, "homepage": "https://github.com/meyda/meyda", "devDependencies": { "@commitlint/cli": "^17.8.1", "@commitlint/config-conventional": "^17.8.1", "@rollup/plugin-commonjs": "^25.0.7", "@rollup/plugin-terser": "^0.4.4", "@rollup/plugin-typescript": "^11.1.6", "@types/jest": "^29.5.12", "@typescript-eslint/eslint-plugin": "^5.62.0", "@typescript-eslint/parser": "^5.62.0", "commitizen": "^4.3.0", "eslint": "^8.57.0", "glob": "^10.3.12", "husky": "^8.0.3", "jest": "^29.7.0", "jest-environment-jsdom": "^29.7.0", "lint-staged": "^13.3.0", "prettier": "^2.8.8", "rollup": "^4.16.0", "semantic-release": "^21.1.2", "ts-jest": "^29.1.2", "tslib": "^2.6.2", "typedoc": "^0.25.13", "typescript": "^5.4.5" }, "dependencies": { "@rollup/plugin-node-resolve": "^15.2.3", "dct": "0.1.0", "fftjs": "0.0.4", "node-getopt": "^0.3.2", "wav": "^1.0.2" }, "jest": { "preset": "ts-jest", "testEnvironment": "node", "reporters": [ "default" ], "testPathIgnorePatterns": [ "__tests__/TestData.ts" ] }, "commitlint": { "extends": [ "@commitlint/config-conventional" ], "rules": { "body-max-line-length": [ 0, "always", 1000 ] } }, "eslintConfig": { "root": true, "parser": "@typescript-eslint/parser", "plugins": [ "@typescript-eslint" ], "rules": { "@typescript-eslint/explicit-module-boundary-types": 0, "@typescript-eslint/ban-ts-comment": 0, "@typescript-eslint/no-unused-vars": 0, "@typescript-eslint/no-var-requires": 0, "@typescript-eslint/no-explicit-any": 0, "@typescript-eslint/no-non-null-assertion": 0, "no-undef": 0, "no-var": 0, "prefer-const": 0 }, "extends": [ "eslint:recommended", "plugin:@typescript-eslint/recommended" ] }, "lint-staged": { "**/*": "prettier --write --ignore-unknown" }, "release": { "branches": [ { "name": "main" }, { "name": "v6", "channel": "v6", "prerelease": "beta" } ] }, "workspaces": [ "docs" ], "prettier": { "singleQuote": false, "semi": true, "useTabs": false, "tabWidth": 2, "bracketSpacing": true, "arrowParens": "always", "trailingComma": "es5" } } ================================================ FILE: rollup.config.mjs ================================================ /* eslint-env es2021 */ import terser from "@rollup/plugin-terser"; import commonjs from "@rollup/plugin-commonjs"; import typescript from "@rollup/plugin-typescript"; import nodeResolve from "@rollup/plugin-node-resolve"; import { glob } from "glob"; const plugins = [nodeResolve(), commonjs(), typescript()]; const SOURCE_FILES = glob .sync("src/**/*.ts") .filter((filename) => !filename.endsWith(".d.ts")); const config = { input: "src/main.ts", output: { file: "dist/web/meyda.js", format: "umd", name: "Meyda", sourcemap: true, }, plugins, }; function minified(config) { return Object.assign({}, config, { output: Object.assign({}, config.output, { file: config.output.file.replace(".js", ".min.js"), }), plugins: [...config.plugins, terser()], }); } const NODE_CONFIGS = SOURCE_FILES.map((sourcefile) => ({ input: sourcefile, output: { file: sourcefile.replace("src", "dist/node").replace(".ts", ".js"), format: "cjs", exports: "auto", }, plugins, })); export default [config, minified(config), ...NODE_CONFIGS]; ================================================ FILE: src/extractors/chroma.ts ================================================ export default function ({ ampSpectrum, chromaFilterBank, }: { ampSpectrum: Float32Array; chromaFilterBank: number[][]; }): number[] { if (typeof ampSpectrum !== "object") { throw new TypeError("Valid ampSpectrum is required to generate chroma"); } if (typeof chromaFilterBank !== "object") { throw new TypeError( "Valid chromaFilterBank is required to generate chroma" ); } var chromagram = chromaFilterBank.map((row, i) => ampSpectrum.reduce((acc, v, j) => acc + v * row[j], 0) ); var maxVal = Math.max(...chromagram); return maxVal ? chromagram.map((v) => v / maxVal) : chromagram; } ================================================ FILE: src/extractors/energy.ts ================================================ export default function ({ signal }: { signal: Float32Array }): number { if (typeof signal !== "object") { throw new TypeError(); } var energy = 0; for (var i = 0; i < signal.length; i++) { energy += Math.pow(Math.abs(signal[i]), 2); } return energy; } ================================================ FILE: src/extractors/extractorUtilities.ts ================================================ export function mu(i: number, amplitudeSpect: Float32Array): number { var numerator = 0; var denominator = 0; for (var k = 0; k < amplitudeSpect.length; k++) { numerator += Math.pow(k, i) * Math.abs(amplitudeSpect[k]); denominator += amplitudeSpect[k]; } return numerator / denominator; } ================================================ FILE: src/extractors/loudness.ts ================================================ export default function ({ ampSpectrum, barkScale, numberOfBarkBands = 24, }: { ampSpectrum: Float32Array; barkScale: Float32Array; numberOfBarkBands?: number; }): { specific: Float32Array; total: number; } { if (typeof ampSpectrum !== "object" || typeof barkScale !== "object") { throw new TypeError(); } var NUM_BARK_BANDS = numberOfBarkBands; var specific = new Float32Array(NUM_BARK_BANDS); var total = 0; var normalisedSpectrum = ampSpectrum; var bbLimits = new Int32Array(NUM_BARK_BANDS + 1); bbLimits[0] = 0; var currentBandEnd = barkScale[normalisedSpectrum.length - 1] / NUM_BARK_BANDS; var currentBand = 1; for (let i = 0; i < normalisedSpectrum.length; i++) { while (barkScale[i] > currentBandEnd) { bbLimits[currentBand++] = i; currentBandEnd = (currentBand * barkScale[normalisedSpectrum.length - 1]) / NUM_BARK_BANDS; } } bbLimits[NUM_BARK_BANDS] = normalisedSpectrum.length - 1; //process for (let i = 0; i < NUM_BARK_BANDS; i++) { let sum = 0; for (let j = bbLimits[i]; j < bbLimits[i + 1]; j++) { sum += normalisedSpectrum[j]; } specific[i] = Math.pow(sum, 0.23); } //get total loudness for (let i = 0; i < specific.length; i++) { total += specific[i]; } return { specific: specific, total: total, }; } ================================================ FILE: src/extractors/melBands.ts ================================================ import extractPowerSpectrum from "./powerSpectrum"; export default function ({ ampSpectrum, melFilterBank, bufferSize, }: { ampSpectrum: Float32Array; melFilterBank: number[][]; bufferSize: number; }): number[] { if (typeof ampSpectrum !== "object") { throw new TypeError("Valid ampSpectrum is required to generate melBands"); } if (typeof melFilterBank !== "object") { throw new TypeError("Valid melFilterBank is required to generate melBands"); } let powSpec = extractPowerSpectrum({ ampSpectrum }); let numFilters = melFilterBank.length; let filtered: Float32Array[] = Array(numFilters); let loggedMelBands: Float32Array = new Float32Array(numFilters); for (let i = 0; i < loggedMelBands.length; i++) { filtered[i] = new Float32Array(bufferSize / 2); loggedMelBands[i] = 0; for (let j = 0; j < bufferSize / 2; j++) { //point-wise multiplication between power spectrum and filterbanks. filtered[i][j] = melFilterBank[i][j] * powSpec[j]; //summing up all of the coefficients into one array loggedMelBands[i] += filtered[i][j]; } //log each coefficient. loggedMelBands[i] = Math.log(loggedMelBands[i] + 1); } return Array.prototype.slice.call(loggedMelBands); } ================================================ FILE: src/extractors/mfcc.ts ================================================ import extractMelBands from "./melBands"; import dct from "dct"; export default function ({ ampSpectrum, melFilterBank, numberOfMFCCCoefficients, bufferSize, }: { ampSpectrum: Float32Array; melFilterBank: number[][]; numberOfMFCCCoefficients: number; bufferSize: number; }): number[] { // Tutorial from: // http://practicalcryptography.com/miscellaneous/machine-learning // /guide-mel-frequency-cepstral-coefficients-mfccs/ // @ts-ignore let _numberOfMFCCCoefficients = Math.min( 40, Math.max(1, numberOfMFCCCoefficients || 13) ); let numFilters = melFilterBank.length; if (numFilters < _numberOfMFCCCoefficients) { throw new Error( "Insufficient filter bank for requested number of coefficients" ); } const loggedMelBandsArray = extractMelBands({ ampSpectrum, melFilterBank, bufferSize, }); let mfccs: number[] = dct(loggedMelBandsArray).slice( 0, _numberOfMFCCCoefficients ); return mfccs; } ================================================ FILE: src/extractors/perceptualSharpness.ts ================================================ import loudness from "./loudness"; export default function ({ ampSpectrum, barkScale, }: { ampSpectrum: Float32Array; barkScale: Float32Array; }): number { var loudnessValue = loudness({ ampSpectrum, barkScale }); var spec = loudnessValue.specific; var output = 0; for (var i = 0; i < spec.length; i++) { if (i < 15) { output += (i + 1) * spec[i + 1]; } else { output += 0.066 * Math.exp(0.171 * (i + 1)); } } output *= 0.11 / loudnessValue.total; return output; } ================================================ FILE: src/extractors/perceptualSpread.ts ================================================ import loudness from "./loudness"; export default function ({ ampSpectrum, barkScale, }: { ampSpectrum: Float32Array; barkScale: Float32Array; }): number { var loudnessValue = loudness({ ampSpectrum, barkScale }); var max = 0; for (var i = 0; i < loudnessValue.specific.length; i++) { if (loudnessValue.specific[i] > max) { max = loudnessValue.specific[i]; } } var spread = Math.pow((loudnessValue.total - max) / loudnessValue.total, 2); return spread; } ================================================ FILE: src/extractors/powerSpectrum.ts ================================================ export default function ({ ampSpectrum, }: { ampSpectrum: Float32Array; }): Float32Array { if (typeof ampSpectrum !== "object") { throw new TypeError(); } var powerSpectrum = new Float32Array(ampSpectrum.length); for (var i = 0; i < powerSpectrum.length; i++) { powerSpectrum[i] = Math.pow(ampSpectrum[i], 2); } return powerSpectrum; } ================================================ FILE: src/extractors/rms.ts ================================================ export default function ({ signal }: { signal: Float32Array }): number { // Keeping this bad runtime typecheck for consistency if (typeof signal !== "object") { throw new TypeError(); } var rms = 0; for (var i = 0; i < signal.length; i++) { rms += Math.pow(signal[i], 2); } rms = rms / signal.length; rms = Math.sqrt(rms); return rms; } ================================================ FILE: src/extractors/spectralCentroid.ts ================================================ import { mu } from "./extractorUtilities"; export default function ({ ampSpectrum, }: { ampSpectrum: Float32Array; }): number { if (typeof ampSpectrum !== "object") { throw new TypeError(); } return mu(1, ampSpectrum); } ================================================ FILE: src/extractors/spectralCrest.ts ================================================ export default function ({ ampSpectrum, }: { ampSpectrum: Float32Array; }): number { if (typeof ampSpectrum !== "object") { throw new TypeError(); } var rms = 0; var peak = -Infinity; ampSpectrum.forEach((x) => { rms += Math.pow(x, 2); peak = x > peak ? x : peak; }); rms = rms / ampSpectrum.length; rms = Math.sqrt(rms); return peak / rms; } ================================================ FILE: src/extractors/spectralFlatness.ts ================================================ export default function ({ ampSpectrum, }: { ampSpectrum: Float32Array; }): number { if (typeof ampSpectrum !== "object") { throw new TypeError(); } var numerator = 0; var denominator = 0; for (var i = 0; i < ampSpectrum.length; i++) { numerator += Math.log(ampSpectrum[i]); denominator += ampSpectrum[i]; } return ( (Math.exp(numerator / ampSpectrum.length) * ampSpectrum.length) / denominator ); } ================================================ FILE: src/extractors/spectralFlux.ts ================================================ // This file isn't being typechecked at all because there are major issues with it. // See #852 for details. Once that's merged, this file should be typechecked. // @ts-nocheck export default function ({ signal, previousSignal, bufferSize, }: { signal: Float32Array; previousSignal: Float32Array; bufferSize: number; }): number { if (typeof signal !== "object" || typeof previousSignal != "object") { throw new TypeError(); } let sf = 0; for (let i = -(bufferSize / 2); i < signal.length / 2 - 1; i++) { x = Math.abs(signal[i]) - Math.abs(previousSignal[i]); sf += (x + Math.abs(x)) / 2; } return sf; } ================================================ FILE: src/extractors/spectralKurtosis.ts ================================================ import { mu } from "./extractorUtilities"; export default function ({ ampSpectrum, }: { ampSpectrum: Float32Array; }): number { if (typeof ampSpectrum !== "object") { throw new TypeError(); } var ampspec = ampSpectrum; var mu1 = mu(1, ampspec); var mu2 = mu(2, ampspec); var mu3 = mu(3, ampspec); var mu4 = mu(4, ampspec); var numerator = -3 * Math.pow(mu1, 4) + 6 * mu1 * mu2 - 4 * mu1 * mu3 + mu4; var denominator = Math.pow(Math.sqrt(mu2 - Math.pow(mu1, 2)), 4); return numerator / denominator; } ================================================ FILE: src/extractors/spectralRolloff.ts ================================================ export default function ({ ampSpectrum, sampleRate, }: { ampSpectrum: Float32Array; sampleRate: number; }): number { if (typeof ampSpectrum !== "object") { throw new TypeError(); } var ampspec = ampSpectrum; //calculate nyquist bin var nyqBin = sampleRate / (2 * (ampspec.length - 1)); var ec = 0; for (var i = 0; i < ampspec.length; i++) { ec += ampspec[i]; } var threshold = 0.99 * ec; var n = ampspec.length - 1; while (ec > threshold && n >= 0) { ec -= ampspec[n]; --n; } return (n + 1) * nyqBin; } ================================================ FILE: src/extractors/spectralSkewness.ts ================================================ import { mu } from "./extractorUtilities"; export default function ({ ampSpectrum, }: { ampSpectrum: Float32Array; }): number { if (typeof ampSpectrum !== "object") { throw new TypeError(); } var mu1 = mu(1, ampSpectrum); var mu2 = mu(2, ampSpectrum); var mu3 = mu(3, ampSpectrum); var numerator = 2 * Math.pow(mu1, 3) - 3 * mu1 * mu2 + mu3; var denominator = Math.pow(Math.sqrt(mu2 - Math.pow(mu1, 2)), 3); return numerator / denominator; } ================================================ FILE: src/extractors/spectralSlope.ts ================================================ export default function ({ ampSpectrum, sampleRate, bufferSize, }: { ampSpectrum: Float32Array; sampleRate: number; bufferSize: number; }): number { if (typeof ampSpectrum !== "object") { throw new TypeError(); } //linear regression let ampSum = 0; let freqSum = 0; let freqs = new Float32Array(ampSpectrum.length); let powFreqSum = 0; let ampFreqSum = 0; for (var i = 0; i < ampSpectrum.length; i++) { ampSum += ampSpectrum[i]; let curFreq = (i * sampleRate) / bufferSize; freqs[i] = curFreq; powFreqSum += curFreq * curFreq; freqSum += curFreq; ampFreqSum += curFreq * ampSpectrum[i]; } return ( (ampSpectrum.length * ampFreqSum - freqSum * ampSum) / (ampSum * (powFreqSum - Math.pow(freqSum, 2))) ); } ================================================ FILE: src/extractors/spectralSpread.ts ================================================ import { mu } from "./extractorUtilities"; export default function ({ ampSpectrum, }: { ampSpectrum: Float32Array; }): number { if (typeof ampSpectrum !== "object") { throw new TypeError(); } return Math.sqrt(mu(2, ampSpectrum) - Math.pow(mu(1, ampSpectrum), 2)); } ================================================ FILE: src/extractors/zcr.ts ================================================ export default function ({ signal }: { signal: Float32Array }): number { if (typeof signal !== "object") { throw new TypeError(); } var zcr = 0; for (var i = 1; i < signal.length; i++) { if ( (signal[i - 1] >= 0 && signal[i] < 0) || (signal[i - 1] < 0 && signal[i] >= 0) ) { zcr++; } } return zcr; } ================================================ FILE: src/featureExtractors.ts ================================================ import rms from "./extractors/rms"; import energy from "./extractors/energy"; import spectralSlope from "./extractors/spectralSlope"; import spectralCentroid from "./extractors/spectralCentroid"; import spectralRolloff from "./extractors/spectralRolloff"; import spectralFlatness from "./extractors/spectralFlatness"; import spectralSpread from "./extractors/spectralSpread"; import spectralSkewness from "./extractors/spectralSkewness"; import spectralKurtosis from "./extractors/spectralKurtosis"; import zcr from "./extractors/zcr"; import loudness from "./extractors/loudness"; import perceptualSpread from "./extractors/perceptualSpread"; import perceptualSharpness from "./extractors/perceptualSharpness"; import mfcc from "./extractors/mfcc"; import chroma from "./extractors/chroma"; import powerSpectrum from "./extractors/powerSpectrum"; import spectralFlux from "./extractors/spectralFlux"; import spectralCrest from "./extractors/spectralCrest"; import melBands from "./extractors/melBands"; let buffer = function (args) { return args.signal; }; let complexSpectrum = function (args) { return args.complexSpectrum; }; let amplitudeSpectrum = function (args) { return args.ampSpectrum; }; export { buffer, rms, energy, complexSpectrum, spectralSlope, spectralCentroid, spectralRolloff, spectralFlatness, spectralSpread, spectralSkewness, spectralKurtosis, amplitudeSpectrum, zcr, loudness, perceptualSpread, perceptualSharpness, powerSpectrum, mfcc, chroma, spectralFlux, spectralCrest, melBands }; ================================================ FILE: src/main.ts ================================================ /** * This file contains the default export for Meyda, you probably want to check * out {@link default} * * @module Meyda */ import * as utilities from "./utilities"; import * as extractors from "./featureExtractors"; import { fft } from "fftjs"; import { MeydaAnalyzer, MeydaAnalyzerOptions } from "./meyda-wa"; export interface MeydaFeaturesObject { amplitudeSpectrum: Float32Array; buffer: number[]; chroma: number[]; complexSpectrum: { real: number[]; imag: number[]; }; energy: number; loudness: { specific: Float32Array; total: number; }; mfcc: number[]; perceptualSharpness: number; perceptualSpread: number; powerSpectrum: Float32Array; rms: number; spectralCentroid: number; spectralFlatness: number; spectralKurtosis: number; spectralRolloff: number; spectralSkewness: number; spectralSlope: number; spectralSpread: number; spectralCrest: number; zcr: number; } export type MeydaWindowingFunction = | "blackman" | "sine" | "hanning" | "hamming"; export type MeydaAudioFeature = | "amplitudeSpectrum" | "chroma" | "complexSpectrum" | "energy" | "loudness" | "mfcc" | "perceptualSharpness" | "perceptualSpread" | "powerSpectrum" | "rms" | "spectralCentroid" | "spectralFlatness" | "spectralFlux" | "spectralKurtosis" | "spectralRolloff" | "spectralSkewness" | "spectralSlope" | "spectralSpread" | "spectralCrest" | "zcr" | "buffer" | "melBands"; /** * A type representing an audio signal. In general it should be an array of * numbers that is sliceable. Float32Array is assignable here, and we generally * expect that most signals will be in this format. */ export type MeydaSignal = SliceableArrayLike | Float32Array; export interface SliceableArrayLike extends ArrayLike { slice(start: number, end: number): SliceableArrayLike; } /** * Meyda is a library for extracting audio features from an audio signal. * * The primary entry points are {@link extract} for audio feature extraction on * raw signals you have in memory, and {@link createMeydaAnalyzer}, which * provides a {@link MeydaAnalyzer} object that can be used to extract features * on a Web Audio API AudioNode. The latter is only supported on web targets, * though if you're using the Web Audio API in a non-web target, we'd love to * hear from you. * * We also expose {@link listAvailableFeatureExtractors} which returns a list of the * available feature extractors, and {@link windowing}, which lets you apply * a windowing function to your signal outside of Meyda. * * We existed long before esmodules, so our backwards compatible API may seem * unusual. We export a default object, with read/write fields that control * various parameters of the audio feature extraction process. We're working on * a new interface, check out [#257](https://github.com/meyda/meyda/issues/257) * for more information. */ interface Meyda { /** * Meyda stores a reference to the relevant audio context here for use inside * the Web Audio API. */ audioContext: AudioContext | null; /** * Meyda keeps an internal ScriptProcessorNode in which it runs audio feature * extraction. The ScriptProcessorNode is stored in this member variable. * @hidden */ spn: ScriptProcessorNode | null; /** * The length of each buffer that Meyda will extract audio on. When recieving * input via the Web Audio API, the Script Processor Node chunks incoming audio * into arrays of this length. Longer buffers allow for more precision in the * frequency domain, but increase the amount of time it takes for Meyda to * output a set of audio features for the buffer. You can calculate how many * sets of audio features Meyda will output per second by dividing the * buffer size by the sample rate. If you're using Meyda for visualisation, * make sure that you're collecting audio features at a rate that's faster * than or equal to the video frame rate you expect. */ bufferSize: number; /** * The number of samples per second of the incoming audio. This affects * feature extraction outside of the context of the Web Audio API, and must be * set accurately - otherwise calculations will be off. */ sampleRate: number; /** * The number of Mel bands to use in the Mel Frequency Cepstral Co-efficients * feature extractor */ melBands: number; /** * The number of bands to divide the spectrum into for the Chroma feature * extractor. 12 is the standard number of semitones per octave in the western * music tradition, but Meyda can use an arbitrary number of bands, which * can be useful for microtonal music. */ chromaBands: number; /** * A function you can provide that will be called for each buffer that Meyda * receives from its source node * @hidden */ callback: ((features: Partial) => void | null) | null; /** * Specify the windowing function to apply to the buffer before the * transformation from the time domain to the frequency domain is performed * * The default windowing function is the hanning window. */ windowingFunction: string; featureExtractors: any; /** @hidden */ EXTRACTION_STARTED: boolean; /** * The number of MFCC co-efficients that the MFCC feature extractor should return */ numberOfMFCCCoefficients: number; /** * The number of bark bands that the loudness feature extractor should return */ numberOfBarkBands: number; /** @hidden */ _featuresToExtract: string[]; /** * Apply a windowing function to a signal */ windowing: ( signal: MeydaSignal, windowname?: MeydaWindowingFunction ) => MeydaSignal; /** @hidden */ _errors: { [key: string]: Error }; /** * @summary * Create a MeydaAnalyzer * * A factory function for creating a MeydaAnalyzer, the interface for using * Meyda in the context of Web Audio. * * @example * ```javascript * const analyzer = Meyda.createMeydaAnalyzer({ * "audioContext": audioContext, * "source": source, * "bufferSize": 512, * "featureExtractors": ["rms"], * "inputs": 2, * "callback": features => { * levelRangeElement.value = features.rms; * } * }); * ``` */ createMeydaAnalyzer: (MeydaAnalyzerOptions) => MeydaAnalyzer; /** * List available audio feature extractors. Return format provides the key to * be used in selecting the extractor in the extract methods */ listAvailableFeatureExtractors: () => MeydaAudioFeature[]; /** * Extract an audio feature from a buffer * * Unless `meyda.windowingFunction` is set otherwise, `extract` will * internally apply a hanning window to the buffer prior to conversion into * the frequency domain. * * @param {(string|Array.)} feature - the feature you want to extract * @param {Array.} signal * An array of numbers that represents the signal. It should be of length * `meyda.bufferSize` * @param {Array.} [previousSignal] - the previous buffer * @returns {object} Features * @example * ```javascript * meyda.bufferSize = 2048; * const features = meyda.extract(['zcr', 'spectralCentroid'], signal); * ``` * * Aside: yes, you need to modify the value of a field of the default export * of the package to change the buffer size. We realise this now seems not * a good practice. See [this issue](https://github.com/meyda/meyda/issues/257) * to track our progress on implementing a more modern API. */ extract: ( feature: MeydaAudioFeature | MeydaAudioFeature[], signal: MeydaSignal, previousSignal?: MeydaSignal ) => Partial | null; } const Meyda: Meyda = { audioContext: null, spn: null, bufferSize: 512, sampleRate: 44100, melBands: 26, chromaBands: 12, callback: null, windowingFunction: "hanning", featureExtractors: extractors, EXTRACTION_STARTED: false, numberOfMFCCCoefficients: 13, numberOfBarkBands: 24, _featuresToExtract: [], windowing: utilities.applyWindow, /** @hidden */ _errors: { notPow2: new Error( "Meyda: Buffer size must be a power of 2, e.g. 64 or 512" ), featureUndef: new Error("Meyda: No features defined."), invalidFeatureFmt: new Error("Meyda: Invalid feature format"), invalidInput: new Error("Meyda: Invalid input."), noAC: new Error("Meyda: No AudioContext specified."), noSource: new Error("Meyda: No source node specified."), }, /** * @summary * Create a MeydaAnalyzer * * A factory function for creating a MeydaAnalyzer, the interface for using * Meyda in the context of Web Audio. * * ```javascript * const analyzer = Meyda.createMeydaAnalyzer({ * "audioContext": audioContext, * "source": source, * "bufferSize": 512, * "featureExtractors": ["rms"], * "inputs": 2, * "callback": features => { * levelRangeElement.value = features.rms; * } * }); * ``` */ createMeydaAnalyzer, /** * List available audio feature extractors. Return format provides the key to * be used in selecting the extractor in the extract methods */ listAvailableFeatureExtractors, /** * Extract an audio feature from a buffer * * Unless `meyda.windowingFunction` is set otherwise, `extract` will * internally apply a hanning window to the buffer prior to conversion into * the frequency domain. * * ```javascript * meyda.bufferSize = 2048; * const features = meyda.extract(['zcr', 'spectralCentroid'], signal); * ``` */ extract: function (feature, signal, previousSignal) { if (!signal) throw this._errors.invalidInput; else if (typeof signal != "object") throw this._errors.invalidInput; else if (!feature) throw this._errors.featureUndef; else if (!utilities.isPowerOfTwo(signal.length)) throw this._errors.notPow2; if ( typeof this.barkScale == "undefined" || this.barkScale.length != this.bufferSize ) { this.barkScale = utilities.createBarkScale( this.bufferSize, this.sampleRate, this.bufferSize ); } // Recalculate mel bank if buffer length changed if ( typeof this.melFilterBank == "undefined" || this.barkScale.length != this.bufferSize || this.melFilterBank.length != this.melBands ) { this.melFilterBank = utilities.createMelFilterBank( Math.max(this.melBands, this.numberOfMFCCCoefficients), this.sampleRate, this.bufferSize ); } // Recalculate chroma bank if buffer length changed if ( typeof this.chromaFilterBank == "undefined" || this.chromaFilterBank.length != this.chromaBands ) { this.chromaFilterBank = utilities.createChromaFilterBank( this.chromaBands, this.sampleRate, this.bufferSize ); } if ("buffer" in signal && typeof signal.buffer == "undefined") { //signal is a normal array, convert to F32A this.signal = utilities.arrayToTyped(signal); } else { this.signal = signal; } let preparedSignal = prepareSignalWithSpectrum( signal, this.windowingFunction, this.bufferSize ); this.signal = preparedSignal.windowedSignal; this.complexSpectrum = preparedSignal.complexSpectrum; this.ampSpectrum = preparedSignal.ampSpectrum; if (previousSignal) { let preparedSignal = prepareSignalWithSpectrum( previousSignal, this.windowingFunction, this.bufferSize ); this.previousSignal = preparedSignal.windowedSignal; this.previousComplexSpectrum = preparedSignal.complexSpectrum; this.previousAmpSpectrum = preparedSignal.ampSpectrum; } const extract = (feature) => { return this.featureExtractors[feature]({ ampSpectrum: this.ampSpectrum, chromaFilterBank: this.chromaFilterBank, complexSpectrum: this.complexSpectrum, signal: this.signal, bufferSize: this.bufferSize, sampleRate: this.sampleRate, barkScale: this.barkScale, melFilterBank: this.melFilterBank, previousSignal: this.previousSignal, previousAmpSpectrum: this.previousAmpSpectrum, previousComplexSpectrum: this.previousComplexSpectrum, numberOfMFCCCoefficients: this.numberOfMFCCCoefficients, numberOfBarkBands: this.numberOfBarkBands, }); }; if (typeof feature === "object") { return feature.reduce( (acc, el) => Object.assign({}, acc, { [el]: extract(el), }), {} ); } else if (typeof feature === "string") { return extract(feature); } else { throw this._errors.invalidFeatureFmt; } }, }; var prepareSignalWithSpectrum = function ( signal, windowingFunction, bufferSize ) { var preparedSignal: any = {}; if (typeof signal.buffer == "undefined") { //signal is a normal array, convert to F32A preparedSignal.signal = utilities.arrayToTyped(signal); } else { preparedSignal.signal = signal; } preparedSignal.windowedSignal = utilities.applyWindow( preparedSignal.signal, windowingFunction ); preparedSignal.complexSpectrum = fft(preparedSignal.windowedSignal); preparedSignal.ampSpectrum = new Float32Array(bufferSize / 2); for (var i = 0; i < bufferSize / 2; i++) { preparedSignal.ampSpectrum[i] = Math.sqrt( Math.pow(preparedSignal.complexSpectrum.real[i], 2) + Math.pow(preparedSignal.complexSpectrum.imag[i], 2) ); } return preparedSignal; }; export default Meyda; /** * List available audio feature extractors. Return format provides the key to * be used in selecting the extractor in the extract methods */ function listAvailableFeatureExtractors(): MeydaAudioFeature[] { return Object.keys(this.featureExtractors) as MeydaAudioFeature[]; } /** * Create a MeydaAnalyzer * * A factory function for creating a MeydaAnalyzer, the interface for using * Meyda in the context of Web Audio. * * ```javascript * const analyzer = Meyda.createMeydaAnalyzer({ * "audioContext": audioContext, * "source": source, * "bufferSize": 512, * "featureExtractors": ["rms"], * "inputs": 2, * "callback": features => { * levelRangeElement.value = features.rms; * } * }); * ``` */ function createMeydaAnalyzer(options) { return new MeydaAnalyzer(options, Object.assign({}, Meyda)); } /** * Apply a windowing function to a signal */ function windowing( signal: MeydaSignal, windowname: MeydaWindowingFunction ): MeydaSignal { return utilities.applyWindow(signal, windowname); } // @ts-ignore if (typeof window !== "undefined") window.Meyda = Meyda; ================================================ FILE: src/meyda-wa.ts ================================================ import * as utilities from "./utilities"; import * as featureExtractors from "./featureExtractors"; import type { MeydaAudioFeature, MeydaWindowingFunction, MeydaFeaturesObject, } from "./main"; /** * MeydaAnalyzerOptions */ export interface MeydaAnalyzerOptions { /** * The Audio Context for the MeydaAnalyzer to operate in. */ audioContext: AudioContext; /** * The Audio Node for Meyda to listen to. */ source: AudioNode; /** * The size of the buffer. */ bufferSize: number; /** * The number of samples between the start of each buffer. */ hopSize?: number | undefined; /** * The number of samples per second in the audioContext. */ sampleRate?: number | undefined; /** * Pass `true` to start feature extraction immediately */ startImmediately?: boolean | undefined; /** * The channel from the input node to listen to */ channel?: number | undefined; /** * The Windowing Function to apply to the signal before transformation to the frequency domain. */ windowingFunction?: MeydaWindowingFunction | undefined; /** * What feature extractors to return to the callback. */ featureExtractors?: | MeydaAudioFeature | ReadonlyArray | undefined; inputs?: number | undefined; outputs?: number | undefined; /** * The number of mfcc coefficients to calculate for each buffer. */ numberOfMFCCCoefficients?: number | undefined; /** * The number of bark bands to calculate for use in feature extractors. */ numberOfBarkBands?: number | undefined; /** * The callback to receive your audio features. Will be called once for each buffer of input audio. */ callback?: ((features: Partial) => void) | undefined; } /** * Meyda's interface to the Web Audio API. MeydaAnalyzer abstracts an API on * top of the Web Audio API's ScriptProcessorNode, running the Meyda audio * feature extractors inside that context. * * MeydaAnalyzer's constructor should not be called directly - MeydaAnalyzer * objects should be generated using the {@link createMeydaAnalyzer} * factory function in the main Meyda class. * * Options are of type {@link MeydaAnalyzerOptions}. * * @example * ```javascript * const analyzer = Meyda.createMeydaAnalyzer({ * "audioContext": audioContext, * "source": source, * "bufferSize": 512, * "featureExtractors": ["rms"], * "inputs": 2, * "numberOfMFCCCoefficients": 20 * "callback": features => { * levelRangeElement.value = features.rms; * } * }); * ``` */ export class MeydaAnalyzer { /** @hidden */ _m: any; /** @hidden */ constructor(options: MeydaAnalyzerOptions, _this) { this._m = _this; if (!options.audioContext) { throw this._m.errors.noAC; } else if ( options.bufferSize && !utilities.isPowerOfTwo(options.bufferSize) ) { throw this._m._errors.notPow2; } else if (!options.source) { throw this._m._errors.noSource; } this._m.audioContext = options.audioContext; // TODO: validate options this._m.bufferSize = options.bufferSize || this._m.bufferSize || 256; this._m.hopSize = options.hopSize || this._m.hopSize || this._m.bufferSize; this._m.sampleRate = options.sampleRate || this._m.audioContext.sampleRate || 44100; this._m.callback = options.callback; this._m.windowingFunction = options.windowingFunction || "hanning"; this._m.featureExtractors = featureExtractors; this._m.EXTRACTION_STARTED = options.startImmediately || false; this._m.channel = typeof options.channel === "number" ? options.channel : 0; this._m.inputs = options.inputs || 1; this._m.outputs = options.outputs || 1; this._m.numberOfMFCCCoefficients = options.numberOfMFCCCoefficients || this._m.numberOfMFCCCoefficients || 13; this._m.numberOfBarkBands = options.numberOfBarkBands || this._m.numberOfBarkBands || 24; //create nodes this._m.spn = this._m.audioContext.createScriptProcessor( this._m.bufferSize, this._m.inputs, this._m.outputs ); this._m.spn.connect(this._m.audioContext.destination); this._m._featuresToExtract = options.featureExtractors || []; //always recalculate BS and MFB when a new Meyda analyzer is created. this._m.barkScale = utilities.createBarkScale( this._m.bufferSize, this._m.sampleRate, this._m.bufferSize ); this._m.melFilterBank = utilities.createMelFilterBank( Math.max(this._m.melBands, this._m.numberOfMFCCCoefficients), this._m.sampleRate, this._m.bufferSize ); this._m.inputData = null; this._m.previousInputData = null; this._m.frame = null; this._m.previousFrame = null; this.setSource(options.source); this._m.spn.onaudioprocess = (e) => { var buffer; if (this._m.inputData !== null) { this._m.previousInputData = this._m.inputData; } this._m.inputData = e.inputBuffer.getChannelData(this._m.channel); if (!this._m.previousInputData) { buffer = this._m.inputData; } else { buffer = new Float32Array( this._m.previousInputData.length + this._m.inputData.length - this._m.hopSize ); buffer.set(this._m.previousInputData.slice(this._m.hopSize)); buffer.set( this._m.inputData, this._m.previousInputData.length - this._m.hopSize ); } var frames = utilities.frame(buffer, this._m.bufferSize, this._m.hopSize); frames.forEach((f) => { this._m.frame = f; var features = this._m.extract( this._m._featuresToExtract, this._m.frame, this._m.previousFrame ); // call callback if applicable if ( typeof this._m.callback === "function" && this._m.EXTRACTION_STARTED ) { this._m.callback(features); } this._m.previousFrame = this._m.frame; }); }; } /** * Start feature extraction * The audio features will be passed to the callback function that was defined * in the MeydaOptions that were passed to the factory when constructing the * MeydaAnalyzer. * @param {(string|Array.)} [features] * Change the features that Meyda is extracting. Defaults to the features that * were set upon construction in the options parameter. * @example * ```javascript * analyzer.start('chroma'); * ``` */ start(features?: MeydaAudioFeature | ReadonlyArray): void { this._m._featuresToExtract = features || this._m._featuresToExtract; this._m.EXTRACTION_STARTED = true; } /** * Stop feature extraction. * @example * ```javascript * analyzer.stop(); * ``` */ stop(): void { this._m.EXTRACTION_STARTED = false; } /** * Set the Audio Node for Meyda to listen to. * @param {AudioNode} source - The Audio Node for Meyda to listen to * @example * ```javascript * analyzer.setSource(audioSourceNode); * ``` */ setSource(source: AudioNode): void { this._m.source && this._m.source.disconnect(this._m.spn); this._m.source = source; this._m.source.connect(this._m.spn); } /** * Set the channel of the audio node for Meyda to listen to * @param {number} channel - the index of the channel on the input audio node * for Meyda to listen to. * @example * ```javascript * analyzer.setChannel(0); * ``` */ setChannel(channel: number) { if (channel <= this._m.inputs) { this._m.channel = channel; } else { console.error( `Channel ${channel} does not exist. Make sure you've provided a value for 'inputs' that is greater than ${channel} when instantiating the MeydaAnalyzer` ); } } /** * Get a set of features from the current frame. * @param {(string|Array.)} [features] * Change the features that Meyda is extracting * @example * ```javascript * analyzer.get('spectralFlatness'); * ``` */ get( features?: MeydaAudioFeature | ReadonlyArray ): Partial | null { if (this._m.inputData) { return this._m.extract( features || this._m._featuresToExtract, this._m.inputData, this._m.previousInputData ); } else { return null; } } } ================================================ FILE: src/utilities.ts ================================================ import * as windowing from "./windowing"; let windows = {}; export function isPowerOfTwo(num) { while (num % 2 === 0 && num > 1) { num /= 2; } return num === 1; } export function error(message) { throw new Error("Meyda: " + message); } export function pointwiseBufferMult(a, b) { let c: number[] = []; for (let i = 0; i < Math.min(a.length, b.length); i++) { c[i] = a[i] * b[i]; } return c; } export function applyWindow(signal, windowname) { if (windowname !== "rect") { if (windowname === "" || !windowname) windowname = "hanning"; if (!windows[windowname]) windows[windowname] = {}; if (!windows[windowname][signal.length]) { try { windows[windowname][signal.length] = windowing[windowname]( signal.length ); } catch (e) { throw new Error("Invalid windowing function"); } } signal = pointwiseBufferMult(signal, windows[windowname][signal.length]); } return signal; } export function createBarkScale(length, sampleRate, bufferSize): Float32Array { let barkScale = new Float32Array(length); for (var i = 0; i < barkScale.length; i++) { barkScale[i] = (i * sampleRate) / bufferSize; barkScale[i] = 13 * Math.atan(barkScale[i] / 1315.8) + 3.5 * Math.atan(Math.pow(barkScale[i] / 7518, 2)); } return barkScale; } export function typedToArray(t) { // utility to convert typed arrays to normal arrays return Array.prototype.slice.call(t); } export function arrayToTyped(t) { // utility to convert arrays to typed F32 arrays return Float32Array.from(t); } export function _normalize(num, range) { return num / range; } export function normalize(a, range) { return a.map(function (n) { return _normalize(n, range); }); } export function normalizeToOne(a) { var max = Math.max.apply(null, a); return a.map(function (n) { return n / max; }); } export function mean(a) { return ( a.reduce(function (prev, cur) { return prev + cur; }) / a.length ); } function _melToFreq(melValue) { var freqValue = 700 * (Math.exp(melValue / 1125) - 1); return freqValue; } function _freqToMel(freqValue) { var melValue = 1125 * Math.log(1 + freqValue / 700); return melValue; } export function melToFreq(mV) { return _melToFreq(mV); } export function freqToMel(fV) { return _freqToMel(fV); } export function createMelFilterBank( numFilters: number, sampleRate: number, bufferSize: number ): number[][] { //the +2 is the upper and lower limits let melValues = new Float32Array(numFilters + 2); let melValuesInFreq = new Float32Array(numFilters + 2); //Generate limits in Hz - from 0 to the nyquist. let lowerLimitFreq = 0; let upperLimitFreq = sampleRate / 2; //Convert the limits to Mel let lowerLimitMel = _freqToMel(lowerLimitFreq); let upperLimitMel = _freqToMel(upperLimitFreq); //Find the range let range = upperLimitMel - lowerLimitMel; //Find the range as part of the linear interpolation let valueToAdd = range / (numFilters + 1); let fftBinsOfFreq: number[] = new Array(numFilters + 2); for (let i = 0; i < melValues.length; i++) { // Initialising the mel frequencies // They're a linear interpolation between the lower and upper limits. melValues[i] = i * valueToAdd; // Convert back to Hz melValuesInFreq[i] = _melToFreq(melValues[i]); // Find the corresponding bins fftBinsOfFreq[i] = Math.floor( ((bufferSize + 1) * melValuesInFreq[i]) / sampleRate ); } var filterBank: number[][] = new Array(numFilters); for (let j = 0; j < filterBank.length; j++) { // Create a two dimensional array of size numFilters * (buffersize/2)+1 // pre-populating the arrays with 0s. filterBank[j] = new Array(bufferSize / 2 + 1).fill(0); //creating the lower and upper slopes for each bin for (let i = fftBinsOfFreq[j]; i < fftBinsOfFreq[j + 1]; i++) { filterBank[j][i] = (i - fftBinsOfFreq[j]) / (fftBinsOfFreq[j + 1] - fftBinsOfFreq[j]); } for (let i = fftBinsOfFreq[j + 1]; i < fftBinsOfFreq[j + 2]; i++) { filterBank[j][i] = (fftBinsOfFreq[j + 2] - i) / (fftBinsOfFreq[j + 2] - fftBinsOfFreq[j + 1]); } } return filterBank; } export function hzToOctaves(freq, A440) { return Math.log2((16 * freq) / A440); } export function normalizeByColumn(a) { var emptyRow = a[0].map(() => 0); var colDenominators = a .reduce((acc, row) => { row.forEach((cell, j) => { acc[j] += Math.pow(cell, 2); }); return acc; }, emptyRow) .map(Math.sqrt); return a.map((row, i) => row.map((v, j) => v / (colDenominators[j] || 1))); } export function createChromaFilterBank( numFilters, sampleRate, bufferSize, centerOctave = 5, octaveWidth = 2, baseC = true, A440 = 440 ) { var numOutputBins = Math.floor(bufferSize / 2) + 1; var frequencyBins = new Array(bufferSize) .fill(0) .map( (_, i) => numFilters * hzToOctaves((sampleRate * i) / bufferSize, A440) ); // Set a value for the 0 Hz bin that is 1.5 octaves below bin 1 // (so chroma is 50% rotated from bin 1, and bin width is broad) frequencyBins[0] = frequencyBins[1] - 1.5 * numFilters; var binWidthBins = frequencyBins .slice(1) .map((v, i) => Math.max(v - frequencyBins[i]), 1) .concat([1]); var halfNumFilters = Math.round(numFilters / 2); var filterPeaks = new Array(numFilters) .fill(0) .map((_, i) => frequencyBins.map( (frq) => ((10 * numFilters + halfNumFilters + frq - i) % numFilters) - halfNumFilters ) ); var weights = filterPeaks.map((row, i) => row.map((_, j) => Math.exp(-0.5 * Math.pow((2 * filterPeaks[i][j]) / binWidthBins[j], 2)) ) ); weights = normalizeByColumn(weights); if (octaveWidth) { var octaveWeights = frequencyBins.map((v) => Math.exp( -0.5 * Math.pow((v / numFilters - centerOctave) / octaveWidth, 2) ) ); weights = weights.map((row) => row.map((cell, j) => cell * octaveWeights[j]) ); } if (baseC) { weights = [...weights.slice(3), ...weights.slice(0, 3)]; } return weights.map((row) => row.slice(0, numOutputBins)); } export function frame(buffer, frameLength, hopLength) { if (buffer.length < frameLength) { throw new Error("Buffer is too short for frame length"); } if (hopLength < 1) { throw new Error("Hop length cannot be less that 1"); } if (frameLength < 1) { throw new Error("Frame length cannot be less that 1"); } const numFrames = 1 + Math.floor((buffer.length - frameLength) / hopLength); return new Array(numFrames) .fill(0) .map((_, i) => buffer.slice(i * hopLength, i * hopLength + frameLength)); } ================================================ FILE: src/windowing.ts ================================================ export function blackman(size) { let blackmanBuffer = new Float32Array(size); let coeff1 = (2 * Math.PI) / (size - 1); let coeff2 = 2 * coeff1; //According to http://uk.mathworks.com/help/signal/ref/blackman.html //first half of the window for (let i = 0; i < size / 2; i++) { blackmanBuffer[i] = 0.42 - 0.5 * Math.cos(i * coeff1) + 0.08 * Math.cos(i * coeff2); } //second half of the window for (let i = Math.ceil(size / 2); i > 0; i--) { blackmanBuffer[size - i] = blackmanBuffer[i - 1]; } return blackmanBuffer; } export function sine(size) { let coeff = Math.PI / (size - 1); let sineBuffer = new Float32Array(size); for (let i = 0; i < size; i++) { sineBuffer[i] = Math.sin(coeff * i); } return sineBuffer; } export function hanning(size) { let hanningBuffer = new Float32Array(size); for (let i = 0; i < size; i++) { // According to the R documentation // http://ugrad.stat.ubc.ca/R/library/e1071/html/hanning.window.html hanningBuffer[i] = 0.5 - 0.5 * Math.cos((2 * Math.PI * i) / (size - 1)); } return hanningBuffer; } export function hamming(size) { let hammingBuffer = new Float32Array(size); for (let i = 0; i < size; i++) { //According to http://uk.mathworks.com/help/signal/ref/hamming.html hammingBuffer[i] = 0.54 - 0.46 * Math.cos(2 * Math.PI * (i / size - 1)); } return hammingBuffer; } ================================================ FILE: tsconfig.json ================================================ { "exclude": ["./dist", "./docs", "./__tests__", "rollup.config.mjs", "./bin"], "compilerOptions": { "outDir": "./dist/esm", "declaration": true, "allowJs": true, "esModuleInterop": true, "skipLibCheck": true, "importHelpers": true, "moduleResolution": "node", "forceConsistentCasingInFileNames": true, "alwaysStrict": true, "strictNullChecks": true, "strictBindCallApply": true, "strictFunctionTypes": true, "strictPropertyInitialization": true, "noImplicitAny": false, "noImplicitThis": false, "rootDir": "./src", "module": "esnext" }, "$schema": "https://json.schemastore.org/tsconfig", "display": "Recommended" }