Saravanan666/pypi-org huggingface dataset:
Package: mne-nirs
MNE-NIRSis anMNE-Pythoncompatible near-infrared spectroscopy processing package.MNE-Python provides support for fNIRS analysis, this package extends that functionality and adds GLM analysis, helper functions, additional algorithms, data quality metrics, plotting, and file format support.DocumentationDocumentation for this project is hostedhere.You can find a list ofexamples within the documentation.FeaturesMNE-NIRS and MNE-Python provide a wide variety of tools to use when processing fNIRS data including:Loading data from awide variety of devices, includingSNIRF files.Apply 3D sensor locationsfrom common digitisation systems such as Polhemus.Standard preprocessing includingoptical density calculation and Beer-Lambert Law conversion, filtering, etc.Data quality metrics includingscalp coupling indexandpeak power.GLM analysis with a wide variety of customisation includingincluding FIRorcanonical HRFanalysis, higher orderautoregressive noise models,short channel regression, region of interest analysis, etc.Visualisation tools for all stages of processing from raw data to processed waveforms, GLM result visualisation, including both sensor and cortical surface projections.Data cleaning functions including popular short channel techniques and negative correlation enhancement.Group level analysis using(robust) linear mixed effects modelsandwaveform averaging.And much more! Check out the documentationexamplesand the APIfor more details.ContributingContributions are welcome (more than welcome!). Contributions can be feature requests, improved documentation, bug reports, code improvements, new code, etc. Anything will be appreciated.Note: this package adheres to the same contributionstandards as MNE.AcknowledgementsThis package is built on top of many other great packages. If you use MNE-NIRS you should also acknowledge these packages.MNE-Python:https://mne.tools/dev/overview/cite.htmlNilearn:http://nilearn.github.io/authors.html#citingstatsmodels:https://www.statsmodels.org/stable/index.html#citationUntil there is a journal article specifically on MNE-NIRS, please citethis article.DockerTo start a jupyter lab server with a specified MNE-NIRS version, and mount a local directory on a mac or nix computer use:docker run -p 8888:8888 -v `pwd`:/home/mne_user ghcr.io/mne-tools/mne-nirs:v0.1.2 jupyter-lab --ip="*"Or on windows:docker run -p 8888:8888 -v %cd%:/home/mne_user ghcr.io/mne-tools/mne-nirs:v0.1.2 jupyter-lab --ip="*"
Package: mneprep
MNEprepGraphical user interface (GUI) for EEG/MEG preprocessing and visualisation with MNE, a Python-based toolbox for neuroimaging data analysis.Installing MNEprep:You can install MNEprep by using pip in a terminal:python3 -m pip install mneprepNote that MNEPrep requires Python 3.6 or higher.Dependencies:MNEprep requires the following Python packages, which will be automatically installed when MNEprep is installed:autoreject >= 0.2matplotlib >= 3.2.0, <3.3.0mne >= 0.20.0numpy >= 1.19.0PyQt5 >= 5.10.0python-picard >= 0.4.0QtPy >= 1.9.0scikit-learn >= 0.23.0scipy >= 1.5.0
Package: mne-qt-browser
mne-qt-browserA new backend based on pyqtgraph for the 2D-Data-Browser in MNE-Python.This repository hosts the code for an alternative backend for plotting 2D-Data withMNE-Python.The backend is based onpyqtgraphwhich uses Qt'sGraphics View Frameworkfor the plotting.
Development started as a2021's Google Summer of Code Project.InstallationInstallfull MNE-Python version 1.0 or greaterwith the instructions providedhereor installminimal MNE-Pythonwithpippip install "mne>=1.0" matplotlib mne-qt-browserorcondaconda install -c conda-forge mne-base matplotlib mne-qt-browserUsageThe backend supports plotting for the following MNE-Python methods:mne.io.Raw.plot()mne.Epochs.plot()mne.preprocessing.ICA.plot_sources(raw)mne.preprocessing.ICA.plot_sources(epochs)In the following example, we'll read M/EEG raw data from the MNEsampledataset
and plot it using theqt-backend.
(For mne-version >= 1.0 theqt-backend will be the default)frompathlibimportPathimportmnesample_dir=mne.datasets.sample.data_path()raw_path=Path(sample_dir)/'MEG'/'sample'/'sample_audvis_raw.fif'raw=mne.io.read_raw(raw_path)mne.viz.set_browser_backend('qt')# Enable mne-qt-browser backend if mne < 1.0raw.plot(block=True)If the plot is not showing, search for solutions in thetroubleshootingsection below.This will use themne-qt-browserfor the current Python session. If you
want to make this change permanent, so you don't have to use theset_browser_backend()each time after restarting Python, run the following
line to modify your MNE configuration file:importmnemne.set_config('MNE_BROWSER_BACKEND','qt')TroubleshootingRunning from a scriptIf you are running a script containingraw.plot()likepython example_script.pythe plot will not stay open when the script is done.To solve this either changeraw.plot()toraw.plot(block=True)or run the script with the interactive flagpython -i example_script.pyIPythonIf the integration of the Qt event loop is not activated for IPython, a plot withraw.plot()will freeze.
Do avoid that either changeraw.plot()toraw.plot(block=True)or activate the integration of the event loop with%guiqt5Report Bugs & Feature RequestsPlease report bugs and feature requests in theissuesof this repository.Development and testingYou can run a benchmark locally with:pytest -m benchmark mne_qt_browserTo run the PyQtGraph tests you have to run:pytest mne_qt_browser/tests/test_pg_specific.pyAdditionally, clone mne-python, and then run:pytest -m pgtest ../mne-python/mne/viz/testsIf you do not have OpenGL installed, this will currently raise errors, and
you'll need to add this line tomne/conftest.pyafter theerror::line:ignore:.*PyOpenGL was not found.*:RuntimeWarning
Package: mne-realtime
MNE-realtime[!WARNING]
This project is discontinued in favor ofMNE-LSL.
At the moment,MNE-LSLreplaces theLSLClientand does not yet support the FieldTrip buffer.This is a package for realtime analysis of MEG/EEG data with MNE.
The documentation can be found here:ExamplesAPIDependenciesnumpyscipyMNEInstallationWe recommend the Anaconda Python distribution. We require that you use Python 3.
You may choose to install mne-realtime via pip.Besidesnumpyandscipy(which are included in the standard Anaconda
installation), you will need to install the most recent version ofMNEusing thepiptool:$ pip install -U mneThen installmne-realtime:$ pip install https://api.github.com/repos/mne-tools/mne-realtime/zipball/mainThesepipcommands also work if you want to upgrade if a newer version ofmne-realtimeis available. If you do not have administrator privileges on the
computer, use the--userflag withpip.Quickstartinfo = mne.io.read_info(op.join(data_path, 'MEG', 'sample',
                        'sample_audvis_raw.fif'))
with FieldTripClient(host='localhost', port=1972,
                     tmax=30, wait_max=5, info=info) as rt_client:
    rt_epochs = RtEpochs(rt_client, event_id, tmin, tmax, ...)
    rt_epochs.start()
    for ev in rt_epochs.iter_evoked():
        epoch_data = ev.data

    # or alternatively, get last n_samples
    rt_epoch = rt_client.get_data_as_epoch(n_samples=500)
    continuous_data = rt_epoch.get_data()TheFieldTripClientsupportsmultiple vendors through the FieldTrip buffer.
It can be replaced with other clients such asLSLClient.
SeeAPIfor a list of clients.Bug reportsUse thegithub issue trackerto report bugs.
Package: mne-vision
MNE_VisionMNE Vision is a open source software mainly based onMNE_PythonWe propose here a graphical interface for MNE, able to perform some of the most common tasks in EEG analysis and processing and available in MNE, while also proposing other tools.The main objective is to propose a free alternative toEEGLABwhich requires aMATLABlicense to fully work.DocumentationMNE_Vision documentationis available inside the project files on this github.Installing and using MNE_VisionTo use MNE_Vision, you will first need to install his dependencies.
To do so you can you can open a terminal in the directory where MNE_Vision is stored and type :$pipinstallrequirements.txtThis requires Python to be installed, if you don’t have python installed you can download it fromhere.Then, MNE Vision can be launch in a terminal from the directory “pathtoMNE_VISION" and type :$python3src/main.pyNote : Depending on how python is installed, python3 might need to be replaced by python if python3 is not reconised.DependenciesThe required dependencies to run MNE-Python are:Python >= 3.9.13eeglabio >= 0.0.1.post7keras >= 2.9.0matplotlib >= 3.5.2mne >= 1.0.3mne_connectivity >= 0.3numpy >= 1.22.4pymatreader >= 0.0.30PyQt5 >= 5.15.6PyQt5-stubs >= 5.15.6.0pyriemann >= 0.2.7pyvista >= 0.34.1pyvistaqt >= 0.9.0scikit_learn >= 1.1.1scipy >= 1.8.1seaborn >= 0.11.2tensorflow >= 2.9.1LicensingMNE_Vision isGNU-licenced, for more information please read the GNU General Public License v3.0.
Package: mnfinder
MN UNet segmenterA package for segmenting micronuclei in micrographs.Usagefrom mnfinder import MNModel
import numpy as np
from tifffile import TiffFile

trained_model = MNModel.get_model()

image = TiffFile.imread('path/to/image.tiff').asarray()
nuclei_labels, mn_labels, mn_raw = trained_model.predict_field(image)
Package: mnfy
mnfy— minify/obfuscate Python 3 source codeContentsmnfy— minify/obfuscate Python 3 source codeWeb PagesWhat the heck is mnfy for?UsageA note about version numbers and Python version compatibilityCommand-line UsageWeb PagesDocumentationProject site(issue tracker)PyPI/CheeseshopWhat the heck is mnfy for?The mnfy project was created for two reasons:To show that shipping bytecode files without source, as a form of obfuscation,
is not the best option availableProvide a minification of Python source code when total byte size of source
code is paramountWhen people ship Python code as only bytecode files (i.e. only.pyofiles
and no.pyfiles), there are couple drawbacks. First and foremost, it
prevents users from using your code with all available Python interpreters such
asJythonandIronPython. Another drawback is that it is a poor form of
obfuscation as projects likeMetaallow you to take bytecode and
reverse-engineer the original source code as enough details are kept that the
only details missing are single-line comments.When the total number of bytes used to ship Python code is paramount, then
you want to minify the source code. Bytecode files actually contain so much
detail that the space savings can be miniscule (e.g. thedecimalmodule from
Python’s standard libary, which is the largest single file in the stdlib, has a
bytecode file that is only 5% smaller than its original source code).UsageA note about version numbers and Python version compatibilityThe version number for mnfy isPEP 386compliant, taking the form ofPPP.FFF.BBB. TheFFF.BBBrepresents the feature and bugfix version
numbers of mnfy itself. ThePPPportion of the version number represents the
Python version that mnfy is compatible with:'{}{}'.format(*sys.version_info[:2]).The Python version that mnfy is compatible with is directly embedded in the version
number as Python’s AST is not guaranteed to be backwards-compatible. This means
that you should use each version of mnfy with a specific version of Python.
Since mnfy works with source code and not bytecode you can safely use
mnfy on code that must be backwards-compatible with older versions of Python,
just make sure the interpreter you use with mnfy is correct and can parse the
source code (e.g. just because
the latest version of mnfy only works with Python 3.3 does not mean you cannot
use that release against source code that must work with Python 3.2, just make
sure to use a Python 3.3 interpreter with mnfy and that the source code can be
read by a Python 3.3 interpreter).Command-line UsageTL;DR: pass the file you want to minify as an argument to mnfy and it will
print to stdout the source code minified such that the AST isexactlythe
same as the original source code. To get transformations that will change the
AST to varying degrees you will need to specificy various flags.See the help message for the project for full instructions on usage:python3 -m mnfy -h
python3 mnfy.py -h
Package: mni2mz3
mni2mz3Converts a file from MNI polygonal surface mesh format (.obj*) or
vertex-wise data (e.g. curvature, cortical thickness,*.txt)
toSurf-Ice MZ3 (.mz3).
Useful for visualizing surfaces usingSurf-IceorNiiVue.[!WARNING]
*Not to be confused with Wavefront .obj, which is a different spec but with the same file extension.InstallationThere are many ways to install and usemni2mz3. Linux, Mac, and Windows are supported.UsingChRISThe easiest way to runmni2mz3is onChRIS, no installation needed.
Simply upload your data to a feed inhttps://app.chrisproject.org, then runpl-mni2common.Using Apptainerpl-mni2commonis aChRISplugin wrapper formni2mz3, which means you can
use its container image to runmni2mz3.apptainerrundocker://ghcr.io/fnndsc/pl-mni2common:latestmni2mz3input.objoutput.mz3Call the wrapper scriptmni2mz3instead to do bulk processing on an input directory.apptainerrundocker://ghcr.io/fnndsc/pl-mni2common:latestmni2mz3inputdir/outputdir/Usingcargo-binstallcargobinstallmni2mz3Using pippipinstallmni2mz3Manual DownloadSelect and download the right binary for your architecture and OS from GitHub Releases:https://github.com/FNNDSC/mni2mz3/releases/latestCompile From SourceInstallRust, then runcargoinstallmni2mz3Usage# convert meshmni2mz3surface_81920.objsurface.mz3# convert datamni2mz3thickness.txtthickness.mz3To do bulk conversions, use theChRISplugin wrapper.DetailsOutput file will be gzip compressed.For surfaces, only triangle meshes are supported.For data, only 32-bit single-precision "float" is supported.TestingIt is recommended to installcargo-nextest.cargonextestrun
Package: mniml
Copyright (c) 2017 Geoffrey A. ReedPermission 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.
Description: Not for use
Keywords: sample setuptools development
Platform: UNKNOWN
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Topic :: Software Development :: Build Tools
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.7
Requires-Python: >=3.7
Description-Content-Type: text/markdown
Package: mnisq
PAGE UNDER CONSTRUCTIONquantum circuit dataset - this repository will be soon completed===> dataset is already accessible!There is already the dataset and qml experiments, some guide can be found in doc/sourcesMNISQ-quantum-circuit-datasetThis library provides machine learning datasets as a Qulacs's QuantumCircuit instance.How To Installpypipip install mnisqsource installpip install git+https://github.com/FujiiLabCollaboration/MNISQ-quantum-circuit-dataset.gitDirectory structuredoc/source/notebooksprovides sample usage of this library.mnisqandtestscontains python code.generator_scriptscontains scripts used to generate datasets.ContributorThis project was developed by:Koki Aoyama(@kotamanegi)Hayata MorisakiKouki Kawamura(@KowerKoint)Toshio Mori(@forest1040)Leonardo Placidi(@Gruntrexpewrus)Ryuichiro HatayaKosuke MitaraiKeisuke Fujii
Package: mnist
The MNIST database is available athttp://yann.lecun.com/exdb/mnist/The MNIST database is a dataset of handwritten digits. It has 60,000
training samples, and 10,000 test samples. Each image is represented
by 28x28 pixels, each containing a value 0 - 255 with its grayscale value.It is a subset of a larger set available from NIST. The digits have been
size-normalized and centered in a fixed-size image.It is a good database for people who want to try learning techniques and
pattern recognition methods on real-world data while spending minimal
efforts on preprocessing and formatting.There are four files available, which contain separately train and test,
and images and labels.Thanks to Yann LeCun, Corinna Cortes, Christopher J.C. Burges.mnist makes it easier to download and parse MNIST files.
Package: mnist-classifier
M-NIST classification algorithm comparisonInstallationYou can just usepipinstallmnist-classifierDocumentationYou can find all the information you need on thedocumentation pageMotivation for projectThis project was realised in the scope of a course in Artificial Intelligence offered byUniDistanceand theIdiap research InstituteThe hypothesis motivating the development of this package is the following:Random Forests can give similar resulting prediction models to MLP Neural Networks on the M-NIST digit dataset in significantly less time.With the code in this repository, we show that indeed, Random Forestscanin fact produce similar (if not better) results with training times orders of magnitude smaller.LicenseMITAuthors@sandrich - Christian Sandrini
@bigskapinsky - Calixte Mayoraz
Package: mnist-py
mnist-pyLazily loads from/tmp/mnist/and caches the resulting numpy arrays. Downloads any missing MNIST files first.Installationpipinstallmnist-pyUsagefrommnistimportMNISTmnist=MNIST()# Train set is lazily loaded into memory and cached afterwardmnist.train_set.images# (60000, 784)mnist.train_set.labels# (60000, 10)# Test set is lazily loaded into memory and cached afterwardmnist.test_set.images# (10000, 784)mnist.test_set.labels# (10000, 10)# Yield minibatches from the shuffled train setforimages,labelsinmnist.train_set.minibatches(batch_size=256):passImage dataImages are rows, each of length 784, and with pixel values scaled to the range zero through one.Label dataLables are one-hot rows each of length ten.[001...0]# 3[000...1]# 9Example: Softmax RegressionimportnumpyasnpfrommnistimportMNISTdefsoftmax(x:np.array)->np.array:"""Apply softmax independently to each row."""z=np.exp(x-x.max(1)[:,None])returnz/z.sum(1)[:,None]defmain():learning_rate=0.01batch_size=256n_epochs=4mnist=MNIST()weights=np.random.randn(784,10)*np.sqrt(2/784)for_inrange(n_epochs):forimages,labelsinmnist.train_set.minibatches(batch_size):preds=softmax(images.dot(weights))error=images.T.dot(preds-labels)weights-=learning_rate*erroracc=np.mean(preds.argmax(1)==labels.argmax(1))print(f'Train acc:{acc}')if__name__=='__main__':main()
Package: mnistusps
Splits for MNIST-USPS domain adaptation experimentsThis repository contains the revised split protocol for creating splits for few shot domain adaptation on the MNIST-USPS datasets.Contrary to often seen splits, we define an independent test split here and only let the train-val split vary according to a user-defined random seed.Installationpipinstallmnist-uspsUsageGetting the splits is a simple as:frommnistuspsimportmnistuspstrain,val,test=mnistusps(source_name="mnist",target_name="usps",seed=1,num_source_per_class=200,num_target_per_class=3,same_to_diff_class_ratio=3,image_resize=(240,240),group_in_out=True,# groups data: ((img_s, img_t), (lbl_s, _lbl_t))framework_conversion="tensorflow",data_path=None,# downloads to "~/data" per default)The function automatically downloads and unpacks the data using Torchvision internally. It then creates the splits using theDataset Ops library.
Depending on your choice of machine learning library, the dataset can be converted to Tensorflow or PyTorch (assuming either is pre-installed) using Dataset Ops.
Package: mnist-utils
MNIST UtilsThis is a simple package for working with MNIST Images. If you have a physical mnist style gz file, you can use this package to load the images from the file.This is useful for when you want to run a trained model for example and provide a PNG to the model. The model likely is trained on a numpy array -> this just handles the conversion from PNG to grayscale numpy array.To get the latest version:pip install mnist-utilsWorking on the projectTo build:python setup.py sdist bdist_wheelTo upload:python -m twine upload dist/*(Token name: pypi_all_purpose)
Package: mni-to-atlas
mni-to-atlasA simple Python-based tool for finding brain atlas regions based on MNI coordinates, with basic plotting abilities to show the sagittal, coronal, and axial views of the coordinates on the atlas.The following atlases are currently supported:Automated anatomical labelling atlas[1]Automated anatomical labelling 3 atlas (1mm3voxel version)[2]Human Connectome Project extended parcellation atlas[3]If there is an atlas you would like to see added, please open anissue.Example screenshot of the plotting:Requirements:See here for the list of requirements.Use Example:Install the package into the desired environment using pippip install mni-to-atlas.Import theAtlasBrowserclass into your workspace.Create an instance of theAtlasBrowserclass and specify an atlas to use (can be "AAL", "AAL3", or "HCPEx").Provide MNI coordinates to theAtlasBrowserobject to find the corresponding atlas regions. The brain regions for these coordinates are then returned as a list of strings.The coordinates should be an (n x 3) array, where each row contains an x-, y-, and z-axis MNI coordinate.By default, plotting the coordinates is not performed, however this can be changed by settingplot = Truein thefind_regionsmethod. In this case, a figure will be generated for each set of coordinates.# Import the AtlasBrowser classfrommni_to_atlasimportAtlasBrowser# Instantiate the AtlasBrowser class and specify the atlas to useatlas=AtlasBrowser("AAL3")# Provide MNI coordinates as an (n x 3) arraycoordinates=np.array([[-24,-53,73],[-25,20,78]])# Find the brain regions at the MNI coordinates (plotting is optional)regions=atlas.find_regions(coordinates,plot=True)References:Tzourio-Mazoyeret al.(2002) DOI:10.1006/nimg.2001.0978Rollset al.(2020) DOI:10.1016/j.neuroimage.2019.116189Huanget al.(2022) DOI:10.1007/s00429-021-02421-6
Package: mnk-persian-words
Name:PersianWordsVersion: 0.1.6Summary:This library gives you some random words and paragraphs in persian language.Words list is very expensive and has a lot of different type of some words and how they are written.You can use this two methods to get required data:from mnk_persian_words.persian_words import get_random_persian_paragraph, get_random_persian_wordimport package and functions (because size of python file is large , some IDEs can not find functions in code completion.Also, if you see any errors in finding functions , just ignore it , or useprint(dir(persian_words))to see functions names.)get_random_persian_word(words_count: int =1)Get a random words or as many as you want (less than 240,000!) as a string containing words seperated by space(" ") without trailing dot(".")get_random_persian_paragraph(words_count: int = 5, paragraphs: int = 1)Get a paragraph or as many as you want with each paragraph containing as many words as you want (less than 240,000!) as a string whichwords seperated by space(" ")and every paragraph before last paragraph has anBreakLine("\n") at the endalso there isno trailing dot(".")Home-page:https://github.com/masoudnk/PersianWordsLibAuthor: Masoud Najafzadeh KalatAuthor-email:masoudnk2@gmail.comLicense: MIT LicenseWords used in this library supported:http://khodam.altervista.org/%D9%84%DB%8C%D8%B3%D8%AA-%D9%87%D9%85%D9%87-%DA%A9%D9%84%D9%85%D8%A7%D8%AA-%D9%81%D8%A7%D8%B1%D8%B3%DB%8C-%D9%85%D8%AC%D9%85%D9%88%D8%B9%D9%87-%DA%A9%D8%A7%D9%85%D9%84/