Saravanan666/pypi-org huggingface dataset:
Package: mdat
# MDAT## Medical Decision Aid Tool[![Build Status](https://travis-ci.org/ctsit/mdat.svg?branch=master)](https://travis-ci.org/ctsit/mdat)[![Build Status](https://travis-ci.org/ctsit/mdat.svg?branch=develop)](https://travis-ci.org/ctsit/mdat)The MDAT is a set of software libraries to implement a _medical decision aid_.  These libraries are designed to select the best of two or more alternatives given responses to a list of criteria.## InstallationTo install from source, use setup.pypython setup.py install## Usage Instructions_mdat --help_ provides current usage instructions:usage: mdat [-h] [-i {json}] [-o {json,brief,csv,csvnoheader}][infile] [outfile]Select the best of two or more alternatives given responses to a list ofcriteriapositional arguments:infileoutfileoptional arguments:-h, --help            show this help message and exit-i {json}, --input {json}Specify the file type used as input. Valid types: json-o {json,brief,csv,csvnoheader}, --output {json,brief,csv,csvnoheader}Specify the file type used as input. Valid types:json, brief, csv, csvnoheader## Input dataSample input data should be a json file with two or more labeled alternatives, one or more labeled criteria, and the numeric responses to each criteria for each alternative.  This example input file shows response data for 4 criteria that could be used to determine the preferred type of colorectal cancer screening:{"Accuracy": {"Fecal Immunochemical Test": 0.1,"Flexible Sigmoidoscopy": 0.2,"Colonoscopy": 0.3},"Amount of colon examined": {"Fecal Immunochemical Test": 0.5,"Flexible Sigmoidoscopy": 0.7,"Colonoscopy": 0.8},"Complications": {"Fecal Immunochemical Test": 0.2,"Flexible Sigmoidoscopy": 0.1,"Colonoscopy": 0.9},"Cost": {"Fecal Immunochemical Test": 0.4,"Flexible Sigmoidoscopy": 0.8,"Colonoscopy": 0.9},"Discomfort": {"Fecal Immunochemical Test": 0.1,"Flexible Sigmoidoscopy": 0.3,"Colonoscopy": 0.9},"Sedation": {"Fecal Immunochemical Test": 1.0,"Flexible Sigmoidoscopy": 0.8,"Colonoscopy": 0.9},"Test Preparation": {"Fecal Immunochemical Test": 0.1,"Flexible Sigmoidoscopy": 0.2,"Colonoscopy": 1.0}}## Output datamdat can output data in three formats.$ mdat sample_data/test.jsonColonoscopy$ mdat -o csv sample_data/test.jsonFecal Immunochemical Test,Flexible Sigmoidoscopy,Colonoscopy0.4403085839715581,0.4472662851726272,0.887231735365237$ mdat -o json sample_data/test.json{"best_alternative": "Colonoscopy", "choquet_scores": {"Fecal Immunochemical Test": 0.43414030720240016, "Flexible Sigmoidoscopy": 0.4729342460226981, "Colonoscopy": 0.9068722937866821}}## RequirementsThis project requires Python 2.7 or greater.This project uses Travis CI for automated testing. Please revise the .travis.yml to reflect any changes in required libraries as changes are made to the software.## ContributionsThe MDAT Team welcomes contributions to this project. Please fork and send pull requests with your revisions. Any code changes must be accompanied by corresponding unit tests to be accepted. Please configure your account at https://travis-ci.org to test your commits to your fork so you get quick feedback on any issues created by your changes.
Package: mdata
This is the official machine data format package.It supports csv importing, exporting and format compliance checking.
Machine data files can be parsed into a python object that provides typed views on the contained measurement and event timeseries.Some examples:validation.pyinfiles/input/extension_testingfrommdata.coreimportas_v2frommdata.ioimportwrite_machine_data_v2,read_machine_data_zip,write_machine_data_zipfrommdata.io.utilimportHeaderFileFormats,mk_canon_filenames_v2# md = read_machine_data_v2(mk_canon_filenames_v2(header_format=HeaderFileFormats.YAML))md=read_machine_data_zip('md.zip',header_format=HeaderFileFormats.YAML)write_machine_data_zip('md_test.zip',md,header_format=HeaderFileFormats.YAML)write_machine_data_v2(mk_canon_filenames_v2('test/',header_format=HeaderFileFormats.YAML),md,header_format=HeaderFileFormats.YAML)as_v2(md)print(md.event_specs)print(md.measurement_specs)print(md.segment_specs)print(md.segment_data_specs)print()print(md.observation_index)print(md.segments.df)
Package: mdatagen
mdatagen: A Python Library for the Generation of Artificial Missing DataThis package has been developed to address a gap in machine learning research, specifically the artificial generation of missing data. Santos et al. (2019) provided a survey that presents various strategies for both univariate and multivariate scenarios, but the Python community still needs implementations of these strategies. Besides, Pereira et al. (2023) proposed new benchmark strategies for Missing Not At Random (MNAR), and these novel methods also need to be implemented in Python. Hence,missing-data-generator(mdatagen) is a Python package that implements methods for generating missing values ​​for data, including Missing At Random (MAR), Missing Not At Random (MNAR), and Missing Completly At Random (MCAR) mechanisms in both univariate and multivariate scenarios.This Python package is a collaboration between researchers at the Aeronautics Institute of Technologies (Brazil) and the University of Coimbra (Portugal).User GuidePlease refer to theunivariate docsormultivariate docsfor more details.InstallationTo install the package, please use thepipinstallation as follows:pipinstallmdatagenUsage examplesFor examples on how to use the mdatagen package, from basic examples that generate artificial missing data under a mechanism to complete examples using Multiple Imputation by Chained Equations (MICE) from scikit-learn for imputation, follow thisexamples.ContribuitionsContributions are welcome! Feel free to open issues, submit pull requests, or provide feedback.CitationIf you usemdatagenin your research, please cite themdatagen paperBibtex entry:@article{mdatagen2024,author={ArthurDMangussiandFilipeLoyolaLopesandMiriamSeoneSantosandRicardoCardosoPereiraandAnaCarolinaLorenaandPedroHenriquesAbreu},title={mdatagen:APythonLibraryfortheGenerationofArtificialMissingData},journal={JournalofMachineLearningResearch},year={2024},volume={24},pages={1--6},}AcknowledgementsThe authors gratefully acknowledge the Brazilian funding agencies FAPESP (Fundação Amparo à Pesquisa do Estado de São Paulo) under grants 2022/10553-6, and 2021/06870-3. Moreover, this research was supported in part by the Coordenação de Aperfeiçoamento de Pessoalde Nível Superior - Brasil (CAPES) - Finance Code 001, and Portuguese Recovery and Resilience Plan (PRR) through project C645008882-00000055 Center for Responsable AI.
Package: mdataio
mdataioWhat it isIt is a software package that abstracts the representation of the raw CT patient data (e.g. dicom, mhd, niffty etc.), and provides  unified and clean approaches to  manipulate the image together with the corresponding segmentation mask, including data loading, saving and visualization.What it containsVisualizationDataSaverCommonHow to install$pipinstallmdataioVisualizationThis module contains functions for interactive 2D/3D image visualization. It is useful for  1. overlaying mask onto image 2. comparing across a series of images 3. showing the difference of image pairs.keyboard shortcuts.: next slice
,: last slice
esc: quit#to visualize prep study in /mnt/SSD_2/final_seg/leftheart_ct_ali_annotation2_cleaned_boundaries/0#volshow* is to visualize volumes with shape NxHxWfrommdataio.visualizationimportvolshow,volshowpair,volshowlistimg=np.load('0_img.npy')seg=np.load('0_seg.npy')volshow(img)volshowpair(img,seg)volshowlist([img,img])#imshow is to visualize 2d images with shape HxW (gray scale image) or shape HxWx3 (RGB image)
from mdataio.visualization import imshow
imshow(img[0,:,:])#another 2 useful functions are overlay_image and diff_image, which reflect the 2 most common procedures in debugging:
1. overlaying mask on top of image
2. comparing the difference of two images

from mdataio.visualization import overlay_image, diff_image
img_overlay = overlay_image(img[0,:,:], seg[0,:,:]) # can display the seg as mask (default) or contour (method='contour')
img_diff = diff_image(img[0,:,:], img[20,:,:])
imshow(img_overlay)
imshow(img_diff)
imshowlist([img_overlay, img_diff], title_list=['overylay', 'difference']) 
#all 3 functions support landmarksDataLoad raw image data, currently only supports dicom, niffty, mdh and save to dicoms so that it can be loaded into any dicom image viewerfrommdataio.dataimportPatientDicom,PatientNifty,PatientMhd#dicompfile=PatientDicom("parent folder path of your dicom images")#nifftypfile=PatientNifty("path of your .nii file")#mdh#note that the file ending in .mhd is only the ASCII header information.#the file ended in .raw/.mha contains the actual voxel data and should be put together with the .mhd filepfile=PatientMhd("path of your .mdh file")img,spacing=pd.get_data()pfile.save_as_dicom("path where you want to save the converted dicoms")SaverA class that wrapps up the video saving functionalityformss.saverimportVideoSavervs=VideoSaver([[img[i,:,:],img[i,:,:]]foriinrange(img.shape[0])])vs.to_video('/home/xin/tmp/test.mp4')Common
Package: mdatapipe
RequirementsPython 3.6+ (currently tested with 3.6)Installationpipinstallhttps://github.com/mdatapipe/mdatapipe/archive/master.zipExamplesmdatapiperunpipeline.yamlBugs and Feature RequestsBug reports and feature requests are happily accepted via theGitHub
Issue Tracker. Pull
requests are welcome. Issues that don’t have an accompanying pull
request will be worked on as my time and priority allows.GuidelinesTestingTesting is done viapytest, driven bytox.Testing is as simple as:pipinstalltoxtoxRelease Checklist
Package: m-data-science-helpers
Data Science HelpersAWS HandlerAWSHandler es un wrapper para funcionalidades de aws. Autentica automaticamente tomando las credenciales desde el clipboard (solo tienen que copiarlas desde Get credentials --> Command Line or Programatic Access --> Copy Credentials) y luego borra el clipboardInstalacion!pipinstallm-data-science-helpersEjemplo de usofromm_data_science_helpers.aws_utilsimportAWSHandler# Con las credenciales en clipboard, crear una instancia de AWSHandler (podes obtenerlas desde desde Command Line or Programatic Access)aws_handler=AWSHandler()Consultar datos usando Athenasql="SELECT * FROM mi_base_de_datos.mi_tabla LIMIT 10"database="mi_base_de_datos"result_df=aws_handler.query(sql,database)print(result_df)Listar tablas y vistas en una base de datosdatabase_info=aws_handler.list_tables("mi_base_de_datos")print(database_info)Listar todas las bases de datosdatabases=aws_handler.list_data_sources()print(databases)Guardar un DataFrame en S3aws_handler.save_df(df,'mi_bucket','filename.parquet',file_format='parquet')Cargar un DataFrame desde S3loaded_df=aws_handler.load_df('mi_bucket','filename.parquet')print(loaded_df)Listar todos los buckets disponiblesaws_handler.list_all_buckets()Listar objetos en una carpeta específica de un bucket de S3aws_handler.list_bucket("mi_bucket","prefijo_carpeta/")
Package: mdatasets
Introducing Mdataset (/em-dataset/): a comprehensive solution tailored for researchers and students seeking a streamlined approach to compiling high-quality datasets and processing.Why is it necessary?Dataset compilation and processing can be a formidable challenge in various fields utilizing big data. The complexities lie in either navigating unfamiliar data banks or grappling with the intricacies of downloading specific datasets. Mdataset addresses these hurdles, providing an all-encompassing solution that equips users with the essential tools and methods needed to download existing datasets from renowned sources like Kaggle and Hugging Face. The only limiting factor is your computational power.What do we offer?Mdataset delivers a set of wrappers and functions, either wrapping existing tools developed by researchers or providing our solutions. With a simple three-line command, users can effortlessly download and compile datasets while also performing various processing tasks. Our offerings include:Downloading datasets from high-quality sourcesVideo transcriptionText-to-audio conversionUser-friendly web scraping toolsSecure local-to-internet file transfer on demandScraping popular image boardsSynthetic generation of tabular and text dataSecure one-on-one interview method for data extraction by researchersYouTube video and audio downloadPowerful Optical Character Recognition for extracting data from PDFsUnrestricted on-terminal search engineTor route circuits for secure communicationChoose Mdataset for a comprehensive and efficient solution to your dataset compilation and processing needs.Quickstartpip install mdatasetfrommdatasetimportscrape_dataurl="www.example.com'wanted_list=['What'sthedataca?']scrape_data(url,wanted_list)
Package: mdatpy
poetry_pypi_templateA minimal template for creating a pypi package using poetry and github actionsThis template allows the creation of python projects managed by poetry to be submitted to PyPi. All the github actions have been setup too. The github actions run tests on every push and also creates and new pacakage and pushes to the pypi when a merge happens to the release branch.Just follow the seteps below for an hassle free setup of the project.Create from the Project TemplateClick hereto create a new repo (you need to be logged in to GitHub for this link to work), and follow the instructions to create a new repo from this template.git cloneyour new repoInstall Poetry in your Environmentactivate your environment.install poetrypython -m  pip install poetryUpdate the Project TomlInsert/Update the values in thepyproject.tomlundertool.poetryDont forget to update the desired python version under thetool.poetry.dependenciesDont forget to modify the release branch undertool.semantic_release(assumption ismainis the release branch)add project dependancies. eg - if you wantnumpyas an dependancy simply runpoetry add numpyinstall the dependancies by runningpoetry installMore information on setting up aproject with poetryWrite Code for your python packageCreate a project folder. eg.hapi_pypihereadd all the code/implemenations in the folder.Implement the TestsCheck the functionality of the project folder by implementing tests.Implement tests in thetestsfolder.All the tests should pass when you run the commandpoetry run pytest tests/Details on how to implementtests with pytest.Github Actions Configurationall the github actions are defined in the.github/workflowsfoldersetup thetest.yml. Update the env variables according to the project setup before. The default coverage limit is set to 90% ie the test will fail below the coverage of 90.env:PYTHON_VERSION:"3.8.5"PROJECT_FOLDER:hapy_pypiTEST_FOLDER:testsCOVERAGE_LIMIT:90setup the similar env variables inrelease.ymlas well.Setup SecretsPypi CredsThese secrets are used to push releases to the pypi repository.Generate a pypiapi tokenSet Repo SecretsAddPYPI_USERas__token__AddPYPI_TOKENas the token from above step including thepypi-prefixGithub TokenThis secret is required to generate theCHANGELOG.MDand update the version by SemRel.Generate agithub tokenSet Repo SecretsAddGH_TOKENas the token from github.
Package: mda-tui
MDAnalysis TUIA textual user interface (TUI) for MDAnalysis trajectory transformationshttps://github.com/p-j-smith/mda-tui/assets/29753790/b73c1a7e-ca97-41cd-b7a2-09899ecf1cb3Latest releaseStatusCommunityWarningMDanalysis TUI is alpha software and may change without warning.InstallationWhen installing MDAnalysis TUI, we highly recommend using virtual environments.
If possible, we strongly recommend that you useMambaforgeas your package manager.First ensure that you havemambainstalled.Create a virtual environment and activate it:mamba create --name mda-tui -c conda-forge python=3.10 pip
mamba activate mda-tuiThen install MDAnalysis TUI:python -m pip install mda-tuiAnd when you are finished, you can exit the virtual environment with:mamba deactivateTo use conda instead, replace allmambacommands withconda.Installation from sourceTo build MDAnalysis TUI from source, follow the above steps for creating a virtual environment, clone this repository:git clone https://github.com/p-j-smith/mda-tui.gitThen inside your virtual environment type:python -m pip install .If you want to create a development environment, you can
install MDAnalysis TUI in editible mode along with
the dependencies required for running tests and and building docs with
the following command:python -m pip install -e ".[dev]"Code of conductMDAnalysis TUI is bound by aCode of Conduct.CopyrightThe MDAnalysis TUI source code is hosted athttps://github.com/p-j-smith/mda-tuiand is available under the GNU General Public License, version 2 (see the fileLICENSE).Copyright (c) 2023, Paul SmithAcknowledgementsProject based on theMDAnalysis Cookiecutterversion 0.1.
Please citeMDAnalysiswhen using MDAnalysis TUI in published work.
Package: mda-xdrlib
mda_xdrlibA stand-alone XDRLIB module extracted from cpython 3.10.8Why does this package exist?The xdrlib package has historically been a feature of the core python library.
However, as of Python 3.11, the module was deemed to no longer be widely used
and has been deprecated, with a target removal version of Python 3.13.Several of the MDAnalysis projects rely on the xdrlib module for their
functionality, specifically for parsing GROMACS TPR and EDR files. To
avoid a need to vendor in the xdrlib functionality in multiple projects,
we take the approach of creating this stand-alone module which contains
the python 3.10.8 xdrlib code and its relevant tests.Changes from the cpython implementationThe majority of this code is copied from the 3.10.8 release of cpython.
Any modifications of the code are mostly cosmetic. A full copy of these
modifications can found in theCHANGESfile.LicenseBeing taken from the cpython 3.10.8 release, the code within this repository
falls under the Python Software Foundation License Version 2. Any
documentation is also dual licensed with both the PSF License Version 2 and
the zero-clause BSD license. More information can be found in
theLICENSEfile.
Package: mdbackup
Backups utilitySmall but customizable utility to create backups and store them in cloud storage providers.How to installDownload from releases the latestwheelpackage and install it. It is recommended to use a virtual environment to do that. We will show you this way.What do yo need?:Any OS with Python support and POSIX-like (e.g.: Linux, macOS, *BSD...)Python 3.6 or higherFirst select a folder where all the needed files will be stored. It is important not to move (or rename) this folder after installation.Run one of those commands. If both fail, try to installpython3-virtualenv(debian based) orpip3 install virtualenv(on macOS).python3-mvenv.venv
python3-mvirtualenv.venvWhen you have the virtual environment created, you have to activate it. With this, you can run python commands and everything you do, will alter the virtual env, not the real one (and so, you don't needsudoto do things)...venv/bin/activate
pipinstall--upgradesetuptoolswheel

pipinstallmdbackupNow you can run the utility (only if you have enabled the virtual env) withmdbackup. In this folder it is recommended to store theconfigfolder.Note:to be able to use some of the cloud storage and secrets backends, you will be requested to install some packages. Go to the documentation to see what is needed.DocumentationCan be found atmdbackup.majorcadevs.comor at the docs folder.To make the documentation, install the requirements indocs/requirements.txtand runmkdocs serve.
Package: mdbase
MDBASEMDBASE joins and processes data from multiple XLSX databases.The XLSX databases:MS Excel files with similar structure.Similar structure = the same columns names.The processing of joined databases:Correlations: statistical plots + correlation coefficients and p-values.Comparisons: boxplots + statistical significance of different groups.Example of usage and more details:Polymers15 (2023) 568.https://doi.org/10.3390/polym15030568If you use MDBASE in your research,please citethe publication above.Quick startTODO; at the moment, you can seeGitHub Pages.Installation, documentation and examplesPyPIrepository.GitHubrepository.GitHub pageswithdocumentation.Versions of MDBASEVersion 0.1 = complete, working, but without documentationVersion 0.2 = several minor improvements + basic documentationVersion 0.3 = further improvements in both code and documentation
Package: mdb-bp
mdb-bpTable of ContentsRequirementsInstallationDocumentationExampleThis package contains a pure-Python MDB client library.RequirementsPython >= 3.9.0MDB>= 1.0InstallationPackage is uploaded onPyPI.Install with pip:$ python3 -m pip install mdb-bpDocumentationbSQL documentation is available online:https://bsql.org/For support, please refer toStackOverflow.ExampleThe following example makes use of a simple blockchain, inserts a value, and reads that value.frommdb_bpimportdriver# Connect to the databaseconn=driver.connect(username="user",password="password",connection_protocol="tcp",server_address="216.27.61.137",server_port=8080,database_name="master",parameters={"interpolateParams":True},)# Prepare a statementstmt=conn.prepare("CREATE BLOCKCHAIN user TRADITIONAL ("+"id uint64 PRIMARY KEY AUTO INCREMENT,"+" first_name string size = 25 PACKED,"+" last_name string size = 50 PACKED,"+" age uint8,"+" username string size=30 PACKED UNIQUE)")# Execute the statement.resp=stmt.exec()print(resp)# Run an insertion and handle errorxact=conn.begin()# Insert a value non-atomicallytry:result=xact.exec("INSERT user (first_name, last_name, age, username) "+"VALUES (\"it's NOT CHABOY\",\"Smith\", 45,\"NOT CHABOY\")")print(result)xact.commit()exceptExceptionaserr:# Rollback the transaction if there was a failureprint(err)xact.rollback()# Query from the blockchainrows=conn.query("SELECT * FROM user")# Print the rowsitr=iter(rows)forrowinitr:print(row)# Store a filestore_file_resp=conn.store_file("space","test_files/space.png","png")print(store_file_resp)# Export a fileexport_file_resp=conn.export_file("space","test_files/out_space.png","png")print(export_file_resp)ResourcesbSQL documentation:https://bsql.org/DB-API 2.0:https://www.python.org/dev/peps/pep-0249/
Package: mdb-codegen
mdb-codegenA static file generator to create Django model definitions and Pydantic BaseModels from an MS Access database.This reads data from an Access file usingmdbtools, see theinstallationinstructions on how to install for your os.HowtoThis parser is based on different classes to determine the Django model name, Pydantic "BaseModel" name, and the fields for Django and/or Pydantic.There is a command line tool to generate files,mdb-codegen.pyRunpoetry installThen runcd mdb_codegenThen run./mdb-codegen.py path_to_your_db