Saravanan666/pypi-org huggingface dataset:
Package: harmoni
HARMomic miNImization (Harmoni)A tool for removing harmonic for MEEG connectivityHARMONIHARMONI is an open-source Python package for eliminating/suppressing the spurious phase synchronization due to the non-sinusoidal shape of the neuronal oscillations. It can be used in connectivity pipelines for investigating within- and cross-frequency phase synchronization with electrophysiological data.CitationHarmoni: a Novel Method for Eliminating Spurious Neuronal Interactions due to the Harmonic Components in Neuronal Data
Mina Jamshidi Idaji, Juanli Zhang, Tilman Stephani, Guido Nolte, Klaus-Robert Mueller, Arno Villringer, Vadim V. Nikulinhttps://doi.org/10.1101/2021.10.06.463319InstallingIn order to install the latest version of HARMONI:$pipinstall-UharmoniDependenciesHARMONI is only dependent on Numpy and Scipy:Python >= 3.6NumPy >= 1.10SciPy >= 0.1LicensingHARMONI isBSD-licenced(3 clause):Copyright (c) 2021, Mina Jamshidi Idaji
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this
   list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice,
   this list of conditions and the following disclaimer in the documentation
   and/or other materials provided with the distribution.

3. Neither the name of the copyright holder nor the names of its
   contributors may be used to endorse or promote products derived from
   this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Package: harmonic
Python package to efficiently compute the learnt harmonic mean estimator of the Bayesian evidenceharmonicis an open source, well tested and documented Python implementation of thelearnt harmonic mean estimator(McEwen et al. 2021) to compute the marginal likelihood (Bayesian evidence), required for Bayesian model selection.Whileharmonicrequires only posterior samples, and so is agnostic to the technique used to perform Markov chain Monte Carlo (MCMC) sampling,harmonicworks exceptionally well with MCMC sampling techniques that naturally provide samples from multiple chains by their ensemble nature, such as affine invariant ensemble samplers.  We therefore advocate use ofharmonicwith the popularemceecode implementing the affine invariant sampler ofGoodman & Weare (2010).Basic usage is highlighted in thisinteractive demo.DocumentationComprehensivedocumentation for harmonicis available.AttributionPlease citeMcEwen et al. (2021)if this code package has been of use in your project.A BibTeX entry for the paper is:@article{harmonic,
   author = {Jason~D.~McEwen and Christopher~G.~R.~Wallis and Matthew~A.~Price and Matthew~M.~Docherty},
    title = {Machine learning assisted {B}ayesian model comparison: learnt harmonic mean estimator},
  journal = {ArXiv},
   eprint = {arXiv:2111.12720},
     year = 2021
}PleasealsociteSpurio Mancini et al. (2022)if this code has been of use in a simulation-based inference project.A BibTeX entry for the paper is:@article{spurio-mancini:harmonic_sbi,
   author   = {A.~Spurio Mancini and M.~M.~Docherty and M.~A.~Price and J.~D.~McEwen},
   doi      = {10.1093/rasti/rzad051},
   eprint   = {arXiv:2207.04037},
   journal  = {{RASTI}, in press},
   title    = {{B}ayesian model comparison for simulation-based inference},
   year     = {2023}
}@inproceedings{polanska:harmonic_nfs_maxent,
   author    = {A.~Polanska and M.~A.~Price and A.~Spurio Mancini and J.~D.~McEwen},
   booktitle = {International Workshop on Bayesian Inference and Maximum Entropy Methods in Science and Engineering},
   eprint    = {arXiv:2307.00048},
   title     = {Learned harmonic mean estimation of the marginal likelihood with normalizing flows},
   year      = {2023}
}Licenseharmonicis released under the GPL-3 license (seeLICENSE.txt), subject to
the non-commercial use condition (seeLICENSE_EXT.txt)harmonic
Copyright (C) 2021 Jason D. McEwen, Christopher G. R. Wallis,
Matthew A. Price, Matthew M. Docherty, Alessio Spurio Mancini,
Alicja Polanska & contributors

This program is released under the GPL-3 license (see LICENSE.txt),
subject to a non-commercial use condition (see LICENSE_EXT.txt).

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Package: harmonica
Processing and modelling gravity and magnetic dataDocumentation(latest)•Documentation(main branch)•Contributing•ContactPart of theFatiando a TerraprojectAboutHarmonicais a Python library for processing and modeling gravity and
magnetic data. It includes common processing steps, like calculation of Bouguer
and terrain corrections, reduction to the pole, upward continuation, equivalent
sources, and more. There are forward modeling functions for basic geometric
shapes, like point sources, prisms and tesseroids. The inversion methods are
implemented as classes with an interface inspired by scikit-learn (likeVerde).Project goalsThese are the long-term goals for Harmonica:Efficient, well designed, and fully tested code for gravity and
magnetic data.Cover the entire data life-cycle: from raw data to 3D Earth model.Focus on best-practices to discourage misuse of methods,
particularly inversion.Easily extended code to enable research on the development of new
methods.See theGitHub milestonesfor short-term goals.Things that willnotbe covered in Harmonica:Multi-physics partial differential equation solvers. UseSimPEGorPyGIMLiinstead.Generic grid processing methods (like horizontal derivatives and FFT). We'll
rely onVerde,xrftandxarrayfor those.Data visualization.GUI applications.Project status🚨Harmonica is in early stages of design and implementation.🚨We welcome any feedback and ideas! Let us know by submittingissues on GitHuborjoining our community.Getting involved🗨️Contact us:Find out more about how to reach us atfatiando.org/contact.👩🏾‍💻Contributing to project development:Please read ourContributing Guideto see how you can help and give feedback.🧑🏾‍🤝‍🧑🏼Code of conduct:This project is released with aCode of Conduct.
By participating in this project you agree to abide by its terms.Imposter syndrome disclaimer:We want your help.No, really.There may be a little voice inside your
head that is telling you that you're not ready, that you aren't skilled
enough to contribute. We assure you that the little voice in your head is
wrong. Most importantly,there are many valuable ways to contribute besides
writing code.This disclaimer was adapted from theMetPy project.LicenseThis is free software: you can redistribute it and/or modify it under the terms
of theBSD 3-clause License. A copy of this license is provided inLICENSE.txt.
Package: harmonique
# IntroductionA sad little static blog generator. Nothing fancy.## InstallationRun:` pip install harmonique `## Example blog projectClone/download this repository and check out theexampledirectory.## Commands### Compile everything, including drafts`bash harmonique dev `### Compile published, skip drafts`bash harmonique prod `Appendserveon the commands above to run the local server that
serves the output files atlocalhost:8889. The server also watches
for file changes and rebuilds. Works with bothdevandprodmodes.
Package: harmonize
Create and synchronize transcoded copies of audio folders.Transcodes FLAC files to MP3 or Opus with tagsCopies everything else as-isParallelizedAdditional runs synchronize changes since the initial runConfigurable encodersHistoryMy audio library is a comprised of FLAC’s, MP3’s, cover images, and various
metadata files - totaling roughly 500GB. This is not a problem when I’m on my
desktop - wired into the same network as my server. However, my laptop and
phone use often suffers from poor connectivity and limit storage capacities.
Further, lossless audio often is a waste as the my laptop and phone used in
less-than-ideal environments and equipment. Thus, I decided to use only MP3’s
on those devices.Previously, I was solving this with a combination ofmp3fsandrsync. This
served me well for a number of years, but had a few drawbacks for my uses.Only MP3- Cannot experiment with formats like Opus without implementing
support in mp3fs’s C codebase.Only CBR MP3- LAME’s V0 often is indistinguishable from 320 CBR while
reducing the file size by ~15%.Uses FUSE- Makes containerization and portability more complicated.Not Parallelized- On a system with eight logical cores and competent
disk speeds, encoding a one file at a time is a gross inefficiency.Harmonize transcodes to LAME V0, has no dependency on FUSE, and supports
parallel copying and transcoding. While it currently only transcodes to MP3,
it’s written in Python. This is far more accessible to modification for a
Pythonista like myself.InstallationArch LinuxDockerPyPIIf installing fromPyPIor using the script directly, ensure the following
are installed:Python 3.6+FLACLAME (when using mp3)opusenc (when using opus)Usageusage: harmonize [-h] [--codec {mp3,opus}] [-n NUM_PROCESSES] [-q] [--version]
                 source target

positional arguments:
  source              Source directory
  target              Target directory

optional arguments:
  -h, --help          show this help message and exit
  --codec {mp3,opus}  codec to output as. encoder configuration may be
                      specified as additional arguments to harmonize
  -n NUM_PROCESSES    Number of processes to use
  -q, --quiet         suppress informational output
  --version           show program's version number and exit
Package: harmonized
HarmonizedWhen developing prototypes with Python conversion and casting can be time consuming and challeging. With harmonized we try to ease this process by providing ready to use helper scripts and tools.hexcolorWorking with colors in RGB space. Converting between hex strings like #FF4470, RGB normed floats [0.0 - 1.0] and HSV normed floats. Quickstart ...Create color:from harmonized import hexcolor
color = hexcolor.HexColor("#FF4470")Get color values:# get RGB values
print(color.r, color.g, color.b)

# get HSV values
print(color.h, color.s, color.v)

# get HexColor string
print(color)Set via rgb or hsv floats:# set red via rgb
color.set_from_hsv(0, 1, 1)

# set red via rgb
color.set_from_rgb(1, 0, 0)inoutSimplified handling of loading and writing files. Making reading from file or HTTP exchangable with local file reading. Local caching possible.
Package: harmonizer
HARMONIZERThis library helps you toconvert,normalize,enrichandvalidateyour music library.
It fullfills the need we have atimr.partyto harmonize the music library of our webradio.The library comes shipped with a CLI tools which allow you to process audio files in a directory to create normalized mp3 versions of all files, enrich their metadata from various sources (Discogs, Spotify).What it doesAudio conversion: Converts FLAC, MP3, AAC (m4a) to MP3 (128k, 192k, 320k).Audio normalization: Peak normalize your input audio. Normalization is expressed in headroom ratio (0.1 means max peak will me 90% of the maximum volume).Metadata extraction:Audio tags:  extracted from the audio and written to the JSON metadata results.Audio fingerprinting:Chromaprintfingerprinting extracted from the audio and written to the JSON metadata results.Metadata enrichment:Use Discogs API to find the releases related to the audio track. Get your tokenshereUse Spotify API to find the audio track in their catalog. Get your API secretshereCovert Art extraction (MP3 only): extract the covert art to an image file.Validation: run various integrity check to assert the input audio respects the rules you defined in the your config.Minimum input bit rate (MP3 only)Mandatory audio tagsAccepted input mime typesOutputsAll file processing will create 2 or 3 files :The mp3 converted and normalized audio version of the input audio file.A metadata json file (checkmetadata_output.json)A cover art image file if present in the original fileInstallSystem dependencyffmpeg:OS X :$ brew install ffmpegLinux:$ sudo apt install ffmpeglibmagic:OS X :$ brew install libmagicLinux:$ sudo apt install libmagic-devfpcalc:InstallChromaprintand add the executable to your path.Pip$ pip install harmonizerCLI usageUsage:cli.py[OPTIONS]AUDIO_INPUT_DIRAUDIO_OUTPUT_DIRCONFPleaseprovideanaudio_input_dirpathandanaudio_output_dirpathtolaunchharmonizationofyourfiles.

Options:--json-outDIRECTORYPathtodirectorytowhichJSONmetadatawillbewrittento.--img-outDIRECTORYPathtodirectorytowhichextractedcoverartswillbewrittento.--helpShowthismessageandexit.Config file structureCheckoutexample_config.yml.Test$ python setup.py testTODO:DocstringsMore documentationBetter discogs search and match algorithmMore pipeline control through the config
Package: harmonoid-module
harmonoid-moduleA Python wrapper around harmonoid-service server code published to PyPIInstall it from PyPI usingpip install harmonoid-moduleIt is perfect for usage in ASGI (asynchronous) applications & is fully asynchronousDownload songimport harmonoidmodule as hm
import asyncio

async def trackDownload(trackName):
    return await hm.trackDownload(trackName=trackName)

loop = asyncio.get_event_loop()
loop.run_until_complete(trackDownload("save your tears"))
loop.close()
Package: harmony-auth
Harmony AuthDiscord OAuth2 Implicit Grant thingy for FastAPI.Tokens are cached in Redis with the user's information & guilds (if enabled)Yes. I know this is a mess. :)Server Usagefromharmony_authimportHarmonyAuthfromfastapiimportFastAPI,Dependsauth=HarmonyAuth()app=FastAPI()@app.get('/secure')asyncdefsecure_route(user=Depends(auth)):returnuserClient UsageRequest an implicit grant access token from DiscordPass receivedaccess_tokento any endpoint with the Harmony Auth dependency to login and access resources.curl-XGET--location"http://127.0.0.1:8000/secure"\-H"Accept: application/json"\-H"Authorization: Bearer {{access_token}}"Reload User DataIf you need to reload the user's data in the cache (if they joined a guild, for example), callget_user(token, force_fetch=True)Example:@app.get("/refresh")asyncdefrefresh_user_data(token:str=Depends(auth.token)):user=awaitauth.get_user(token,force_fetch=True)...This will update the cache and return the user.Log Out / Revoke tokenUserevoke_token(token)to remove user data from the cache. This removes all the cached user information.If you specify aclient_idandclient_secret,Harmony Authwill request that Discord revokes the token.Q: How do I log in?A: You don't need to log in. Just provide a valid access token.Rate limit protectionsI personally don't want to handle this, so I am usingtwilight-http-proxy.TODO: Create fork to add OAuth2 routes to twilight http proxy.
Package: harmony-connect-client
Harmony Connect ClientHarmony Connect is your fast lane to the blockchain. Add blockchain capabilities to any software without needing to wrestle with currencies, wallets, or blockchain nodes. Instead, you get easy read and write access to the Factom blockchain. Connect will also track your data’s path to immutability and will notify you along the way.RequirementsPython 2.7 and 3.4+Installation & Usagepip installYou can install the package hosted on PyPi by using pip:pip install harmony_connect_clientThen import the package:import harmony_connect_clientYou can also install the Harmony Connect client directly from Githubpip installgit+https://github.com/FactomProject/factom-harmony-connect-python-client.git(you may need to runpipwith root permission:sudo pip install git+https://github.com/FactomProject/factom-harmony-connect-python-client.git)SetuptoolsInstall viaSetuptools.python setup.py install--user(orsudo python setup.py installto install the package for all users)Then import the package:import harmony_connect_clientHarmony Connect DocumentationThis client is built to communicate with Factom Harmony Connect. For more information about using this API, please visit the Harmony Connectdocumentation.You can create a free account atFactom.com.
Package: harmonypy
harmonypyHarmony is an algorithm for integrating multiple high-dimensional datasets.harmonypy is a port of theharmonyR package byIlya Korsunsky.ExampleThis animation shows the Harmony alignment of three single-cell RNA-seq datasets from different donors.→ How to make this animation.InstallationThis package has been tested with Python 3.7.Usepipto install:pipinstallharmonypyUsageHere is a brief example using the data that comes with the R package:# Load dataimportpandasaspdmeta_data=pd.read_csv("data/meta.tsv.gz",sep="\t")vars_use=['dataset']# meta_data##                  cell_id dataset  nGene  percent_mito cell_type# 0    half_TGAAATTGGTCTAG    half   3664      0.017722    jurkat# 1    half_GCGATATGCTGATG    half   3858      0.029228      t293# 2    half_ATTTCTCTCACTAG    half   4049      0.015966    jurkat# 3    half_CGTAACGACGAGAG    half   3443      0.020379    jurkat# 4    half_ACGCCTTGTTTACC    half   2813      0.024774      t293# ..                   ...     ...    ...           ...       ...# 295  t293_TTACGTACGACACT    t293   4152      0.033997      t293# 296  t293_TAGAATTGTTGGTG    t293   3097      0.021769      t293# 297  t293_CGGATAACACCACA    t293   3157      0.020411      t293# 298  t293_GGTACTGAGTCGAT    t293   2685      0.027846      t293# 299  t293_ACGCTGCTTCTTAC    t293   3513      0.021240      t293data_mat=pd.read_csv("data/pcs.tsv.gz",sep="\t")data_mat=np.array(data_mat)# data_mat[:5,:5]## array([[ 0.0071695 , -0.00552724, -0.0036281 , -0.00798025,  0.00028931],#        [-0.011333  ,  0.00022233, -0.00073589, -0.00192452,  0.0032624 ],#        [ 0.0091214 , -0.00940727, -0.00106816, -0.0042749 , -0.00029096],#        [ 0.00866286, -0.00514987, -0.0008989 , -0.00821785, -0.00126997],#        [-0.00953977,  0.00222714, -0.00374373, -0.00028554,  0.00063737]])# meta_data.shape # 300 cells, 5 variables# (300, 5)## data_mat.shape  # 300 cells, 20 PCs# (300, 20)# Run Harmonyimportharmonypyashmho=hm.run_harmony(data_mat,meta_data,vars_use)# Write the adjusted PCs to a new file.res=pd.DataFrame(ho.Z_corr)res.columns=['X{}'.format(i+1)foriinrange(res.shape[1])]res.to_csv("data/adj.tsv.gz",sep="\t",index=False)
Package: harmony-pytorch
This is a Pytorch implementation of Harmony algorithm on single-cell sequencing data integration. Please seeIlya Korsunsky et al., 2019for details.InstallationThis package is published on PyPI:pip install harmony-pytorchUsageGeneral CaseGiven an embeddingXas a N-by-d matrix in numpy array structure (N for number of cells, d for embedding components) and cell attributes as a Data Framedf_metadata, use Harmony for data integration as the following:from harmony import harmonize
Z = harmonize(X, df_metadata, batch_key = 'Channel')whereChannelis the attribute indf_metadatafor batches.Alternatively, if there are multiple attributes for batches, write:Z = harmonize(X, df_metadata, batch_key = ['Lab', 'Date'])Input as MultimodalData ObjectIt’s easy for Harmony-pytorch to work with count matrix data structure fromPegasusIOpackage. Letdatabe a MultimodalData object in Python:from harmony import harmonize
Z = harmonize(data.obsm['X_pca'], data.obs, batch_key = 'Channel')
data.obsm['X_pca_harmony'] = ZThis will calculate the harmonized PCA matrix for the default UnimodalData ofdata.Given a UnimodalData objectunidata, you can also use the code above to perform Harmony algorithm: simply substituteunidatafordatathere.Input as AnnData ObjectIt’s easy for Harmony-pytorch to work with annotated count matrix data structure fromanndatapackage. Letadatabe an AnnData object in Python:from harmony import harmonize
Z = harmonize(adata.obsm['X_pca'], adata.obs, batch_key = '<your-batch-key>')
adata.obsm['X_harmony'] = Zwhere<your-batch-key>should be replaced by the actual batch key attribute name in your data.For details aboutAnnDatadata structure, please refer to itsdocumentation.
Package: harmonyqt
Temporary READMETested on Void Linux 4.18.14 x64 with Qt 5.10.1, Python 3.6.6, PyQt5 5.11.3Install olm/olm-devel from your distro's package manager,
or manually fromhere.
Make sure Qt 5.x is installedIf no wheel is available for your platform, a working C compiler and the
Python headers are needed.On Void Linux:sudoxpbs-install-Sgccpython3-develqt5olm-develsudopip3installharmonyqtharmonyqt
Package: harmonysite
Harmony SiteHarmonySiteprovides management AND a website for your choir, orchestra etc.This package simplifies use of theHarmony Site API,
from python.  It was originally built forLondon Welsh Rugby Club Choir.  If you have access to a harmony site and the appropriate permissions, you can get started (and check you have the basics working);
all the information on how to do that ishere.SetupDO NOT use your ordinary credentials for access!  Get a specific login set up.This needs to be done by a website admin.Note that at present, I find it easier to create a new login than duplicate an existing one.It's OK to select "Not Specified" for "member"; members and logins are separate things.Use "Data Administration Access" - and specifiy ONLY the tables you need.Obviously, set a good password.  Use least 16 characters, and a random password generator.NotesThe API is, at present, read only.you canbook the world-famous London Welsh Rugby Club Choir for your eventor come along andjoin us.Where to get itThe source code is currently hosted on GitHub at:https://github.com/jonjump/harmonysiteBinary installers for the latest released version is available at the Python Package Index (PyPI).pip install pandasGetting Startedfrom harmonysite import HarmonySite

hs = HarmonySite.build("<your api url>", "<username>", "<password>")
for record in hs.browse("a table name"):
    print (record)With Pandas And ColabA nice way to make use of the API is usingGoogle's Colab.
That way you don't have to install anything locally, and you can keep notebooks in a google drive.
You may well wish to use pandas to access the API - this provides a nice way of performing operations on data tables,
and works very well, particularly with colab.  In order to avoid this small package pulling in a large dependency,
panda code is not included, but a very simple way to do it is this ...# get the package (because it's not in the default google colab runtime)
!pip install harmonysite

from harmonysite import HarmonySite
import pandas as pd

hs = HarmonySite.build("<your api url>", "<username>", "<password>")
def dataframe(table_name, filterColumns=None, idColumn='id'):
    df = pd.DataFrame.from_records(
         hs.browse(table_name, page_number=0, page_size=9999999),
         index=idColumn
    )
    if filterColumns:
        return df.filter(filterColumns)
    return df

dataframe('<a table name>')Don't ForgetSupport theLondon Welsh Rugby Club Choir
Package: harmony-tools
Harmony toolsLibrary with musical harmony objects with basic cliModulesguitar- Quick way to see gamma layout on guitargammas- Some tools for gammasnotes- Some tools for notespentatonics- Some tools for pentatonicsInstallationClone this repository and run$pipinstallharmony_toolsCONTRIBUTINGFeel free to create PRLICENSEMIT