Saravanan666/pypi-org huggingface dataset:
Package: ibge-parser
IBGE ParserVisão GeralIBGE Parseré uma biblioteca para a linguagem Python que tem por objetivo coletar os microdados do censo do IBGE - Instituto Brasileiro de Geografia e Estatística, disponibilizado emMicrodados IBGEe convertê-los em arquivos CSV, facilitando o manuseio dos dados.Instalaçãopip install ibge-parserExemplos de usoImportando a bibliotecaimport ibgeparserObter os dados# import da classe principalfromibgeparser.microdadosimportMicrodados# import dos enums para facilitar as buscasfromibgeparser.enumsimportAnos,Estados,Modalidadesif__name__=="__main__":# usando os unumsano=Anos.DEZestados=[Estados.SANTA_CATARINA,Estados.RONDONIA]modalidades=[Modalidades.EMIGRACAO]# instanciando a classeibgeparser=Microdados()# obeter dadosibgeparser.obter_dados_ibge(ano,estados,modalidades)O métodoobter_dados_ibgeretorna os dados do censo no formato.csvdas modalidades e estados solicitados. Utitlize osenumspara selecionar corretamente as opções desejadas. Os arquivoscsvsão salvos na pastamicrodados-ibgedentro do projeto.Parâmetrosano: Enum.Anoestados: list(Enum.Estados)modalidades: list(Enum.Modalidades)(opcional: True) header: boolObter especificação das colunas# import da classe principalfromibgeparser.microdadosimportMicrodados# import dos enums para facilitar as buscasfromibgeparser.enumsimportModalidadesif__name__=="__main__":# usando os unumsmodalidades=[Modalidades.EMIGRACAO]# instanciando a classeibgeparser=Microdados()# especificação de colunaibgeparser.obter_especificacao_coluna('palavra-chave',modalidades)O métodoobter_especificacao_colunaretorna a especificação da coluna das modalidades solicitadas. Utitlize osenumspara selecionar corretamente as opções desejadas.Parâmetrospalavra_de_busca: strmodalidades: list(Enum.Modalidades)ContribuindoO projeto IBGE Parser é mantido pela Senior Sistemas e disponibilizado como código-aberto à comunidade, estando sob a licença Apache 2.0.RequisitosGitPython 3ConfiguraçãoConfigurar aPython VirtualEnve instalar as bibliotecas necessárias com o comando abaixo:pip install -r requirements.txtMais informações sobre contribuição, como criação depull requests, abertura deissues, etc. consultaraqui.
Package: ibge-utils
IBGE-Utilsibge-utilsé uma API Python com funções utilitárias para manipulação e extração de dados georeferenciados, de acordo com os padrões do IBGE.DadosOs dados da API foram extraídos dasTabelas da Divisão Territorial Brasileira 2022do IBGE, e estão distribuídos nas tabelas do arquivoibge.duckdbno seguinte esquema:Macrorregiõesfromibge.brasilimportMacrorregiaonorte=Macrorregiao(geocodigo=1)# OUnorte=Macrorregiao(nome="norte")norte.estados# Estados do Norte# Ouput:# [Rondônia, Acre, Amazonas, Roraima, Pará, Amapá, Tocantins]norte.mesorregioes# Mesorregiões do Nortenorte.microrregioes# Microrregiões do Nortenorte.municipios# Todos os municípios do NorteEstadosfromibge.brasilimportEstadorondonia=Estado(geocodigo=11)# OUrondonia=Estado(uf="RO")rondonia.macrorregiao# Norterondonia.mesorregioes# [Leste Rondoniense, Madeira-Guaporé]rondonia.microrregioes# Microrregiões de Rondôniarondonia.municipios# Todos os municípios de RondôniaMunicípiosfromibge.brasilimportMunicipiocerejeiras=Municipio(geocodigo=1100056)cerejeiras.macrorregiao# Nortecerejeiras.estado# Rondôniacerejeiras.mesorregiao# Leste Rondoniensecerejeiras.microrregiao# Colorado do Oestecerejeiras.info# Output:# {'latitude': -13.187,# 'longitude': -60.8168,# 'fuso_horario': 'America/Porto_Velho'}
Package: ibicus
ibicus provides a flexible and user-friendly toolkit for the bias correction of climate models and associated evaluation.ibicus implements a variety of methods for bias correction (8 currently) published in peer-reviewed literature, including ISIMIP (Lange 2019) and CDFt (Michelangeli et al. 2009) and provides a unified interface for their usage.
The package enables the user to modify and refine their behavior with settings and parameters, and provides an evaluation framework to assess marginal, temporal, spatial, and multivariate properties of the bias corrected climate model.Given future climate model data to debias (cm_future), climate model data during a reference period (cm_hist) and observational or reanalysis data during the same reference period (obs) running a debiaser is as easy as:>>> from ibicus import CDFt
>>> debiaser = CDFt.from_variable("pr")
>>> debiased_cm_future = debiaser.apply(obs, cm_hist, cm_future)Evaluating dry spell length can be as easy as:>>> from ibicus.evaluate.metrics import dry_days
>>> spell_length = dry_days.calculate_spell_length(minimum_length: 4, obs = obs, raw = cm_future, ISIMIP = debiased_cm_future)For more information on the usage have a look atour docs.Installibicus releases are available via PyPI. Just write:pip install ibicusFor more information about installation and requirements see theinstall documentationin the docs.How to citeIf you are using the package, please consider citing:Spuler, F. R., Wessel, J. B., Comyn-Platt, E., Varndell, J., and Cagnazzo, C.: ibicus: a new open-source Python package and comprehensive interface for statistical bias adjustment and evaluation in climate modelling (v1.0.1), EGUsphere [preprint],https://doi.org/10.5194/egusphere-2023-1481, 2023.ContactIf you have feedback on the package, suggestions for additions, questions you’d like to ask or would like to contribute, please contact us underibicus.py@gmail.com.
Similarly should you encounter bugs or issues using the package pleaseopen an issue. or write to us using the email adress above.
Package: ibidem-util
ibidem.util.workpoolA simple, generic threaded workpool. When creating the pool, you specify how many workers should be started.
When adding work orders to the pool queue, the next available worker will pick up the order and execute it.
Allows subclassing to create specialized workers. Allows the user to supply the queue instead of letting the
pool create it.ibidem.util.downloaderA work order foribidem.util.workpoolto download arbitrary URLs in an efficient manner. Allows specifying
callbacks to handle the file completed downloads, and to update progress.
Package: ibims
Intermediate BO4E MIgration Models (ibims)A data model for migrating data from one system to another.
The package name is "ibims".InstallationIt's alsoavailable on pypi.pipinstallibimsDocumentationThere is a (very early stage) documentation of this repository onreadthedocs.How to use this Repository on Your MachineFollow the instructions in ourPython template repository.ContributeYou are very welcome to contribute to this template repository by opening a pull request against the main branch.
Package: ib-insync
IntroductionThe goal of the IB-insync library is to make working with theTrader Workstation APIfrom Interactive Brokers as easy as possible.The main features are:An easy to use linear style of programming;AnIB componentthat automatically keeps in sync with the TWS or IB Gateway application;A fully asynchonous framework based onasyncioandeventkitfor advanced users;Interactive operation with live data in Jupyter notebooks.Be sure to take a look at thenotebooks,
therecipesand theAPI docs.Installationpip install ib_insyncRequirements:Python 3.6 or higher;A running TWS or IB Gateway application (version 1023 or higher).
Make sure theAPI port is enabledand ‘Download open orders on connection’ is checked.The ibapi package from IB is not needed.ExampleThis is a complete script to download historical data:fromib_insyncimport*# util.startLoop()  # uncomment this line when in a notebookib=IB()ib.connect('127.0.0.1',7497,clientId=1)contract=Forex('EURUSD')bars=ib.reqHistoricalData(contract,endDateTime='',durationStr='30 D',barSizeSetting='1 hour',whatToShow='MIDPOINT',useRTH=True)# convert to pandas dataframe (pandas needs to be installed):df=util.df(bars)print(df)Output:date      open      high       low     close  volume  \
0   2019-11-19 23:15:00  1.107875  1.108050  1.107725  1.107825      -1
1   2019-11-20 00:00:00  1.107825  1.107925  1.107675  1.107825      -1
2   2019-11-20 01:00:00  1.107825  1.107975  1.107675  1.107875      -1
3   2019-11-20 02:00:00  1.107875  1.107975  1.107025  1.107225      -1
4   2019-11-20 03:00:00  1.107225  1.107725  1.107025  1.107525      -1
..                  ...       ...       ...       ...       ...     ...
705 2020-01-02 14:00:00  1.119325  1.119675  1.119075  1.119225      -1DocumentationThe completeAPI documentation.Changelog.DiscussionTheinsync user groupis the place to discuss
IB-insync and anything related to it.DisclaimerThe software is provided on the conditions of the simplified BSD license.This project is not affiliated with Interactive Brokers Group, Inc.’s.Good luck and enjoy,author:Ewald de Wit <ewald.de.wit@gmail.com>
Package: ibires
Building blocks to write an SMS service with infobip from scratch with simulator for TDD.Write the test.Get your function right until the test passes.Remove@responses.activateandsms_server(**connection)to put your script live.While you get your stuff right, you don’t risk to send any real SMS.
You don’t even need a connection to the web.When you switch your code to live there’s no reason to worry now either.
Your test assures you that the very first real SMS will be delivered (presuming your login and balance allow).Documentation
Package: ibis
A template engine for people who enjoy the simpler things in life.Features:Django/Jinja-style syntax.Supports looping, conditionals, filters, template inheritance.Extensible. Easily add custom template tags and filters.Self-contained, no dependencies. Use as a drop-in component in any project.Public domain code. No license compatibility issues.Sample syntax:<ul>
    {% for post in posts %}
        <li><a href="{{ post.url }}">{{ post.title }}</a></li>
    {% endfor %}
</ul>See thepackage documentationor the
project’sGithub homepagefor
further details.
Package: ibis-bigquery
This package provides aBigQuerybackend
forIbis.InstallationSupported Python VersionsPython >= 3.7, < 3.11Unsupported Python VersionsPython < 3.7Install with conda:conda install -c conda-forge ibis-bigqueryInstall with pip:pip install ibis-bigqueryUsageConnecting to BigQueryRecommended usage (Ibis 2.x, only):importibisconn=ibis.bigquery.connect(project_id=YOUR_PROJECT_ID,dataset_id='bigquery-public-data.stackoverflow')Using this library directly:importibisimportibis_bigqueryconn=ibis_bigquery.connect(project_id=YOUR_PROJECT_ID,dataset_id='bigquery-public-data.stackoverflow')Running a queryedu_table=conn.table('international_education',database='bigquery-public-data.world_bank_intl_education')edu_table=edu_table['value','year','country_code','indicator_code']country_table=conn.table('country_code_iso',database='bigquery-public-data.utility_us')country_table=country_table['country_name','alpha_3_code']expression=edu_table.join(country_table,[edu_table.country_code==country_table.alpha_3_code])print(conn.execute(expression[edu_table.year==2016]# Adult literacy rate.[edu_table.indicator_code=='SE.ADT.LITR.ZS'].sort_by([ibis.desc(edu_table.value)]).limit(20)))
Package: ibis-datasette
ibis-datasetteprovides adatasettebackend foribis. This lets you query
anydatasetteserver using a familiar dataframe-like API (rather than SQL).Installationibis-datasetteis available onpypi:$ pip install ibis-datasetteUsageOnce installed, you can connect to anydatasetteserver using theibis.datasette.connectfunction. This takes thefull URL to a databaseFor example, to connect to thelegislators database.In[1]:importibisIn[2]:con=ibis.datasette.connect("https://congress-legislators.datasettes.com/legislators")Once connected, you can interact with tables usingibisjust as you would a
localsqlitedatabase:In[3]:ibis.options.interactive=True# enable interactive modeIn[4]:con.list_tables()Out[4]:['executive_terms','executives','legislator_terms','legislators','offices','social_media']In[5]:t=con.tables.legislators# access the `legislators` tableIn[6]:t.name_first.topk(5)# top 5 first names for legislatorsOut[6]:name_firstcount0John12731William10242James7213Thomas4574Charles442LICENSENew BSD. See theLicense File.
Package: ibis-heavyai
Ibis HeavyDB backendIbisis a Python framework to write data analytics
code, in a similar way topandas. Ibis can
execute the queries not only in memory (as pandas does), but in different
backends, including SQL databases, and analytics databases, likeHeavyDB.HeavyDBis SQL-based,
relational, columnar and specifically developed to harness the massive
parallelism of modern CPU and GPU hardware. HeavyDB can query up to billions
of rows in milliseconds, and is capable of unprecedented ingestion speeds,
making it the ideal SQL engine for the era of big, high-velocity data.InstallYou can installibis-heavyaiviapiporconda:Install with pip:pipinstallibis-heavyaiInstall with conda:condainstall-cconda-forgeibis-heavyaiDocumentationThe ibis-heavyai documentation can be foundhere.
Package: ibisml
IbisMLibismlis awork-in-progresslibrary for developing Machine Learning
feature engineering pipelines usingibis. These
pipelines can then be used to transform and feed data to other machine learning
libraries likexgboostorscikit-learn.importibisimportibismlasml# Load some training and testing datatrain=ibis.read_csv("training.csv")test=ibis.read_csv("testing.csv")# A recipe for a feature engineering pipeline that:# - imputes missing values in numeric columns with their mean# - applies standard scaling to all numeric columns# - one-hot-encodes all nominal columnsrecipe=ml.Recipe(ml.ImputeMean(ml.numeric()),ml.ScaleStandard(ml.numeric()),ml.OneHotEncode(ml.nominal()),)# Fit the recipe against the training datatransform=recipe.fit(train,outcomes=["outcome_col"])# Transform the training data and train a scikit-learn modelfromsklearn.svmimportLinearSVCmodel=LinearSVC()df_train=transform(train).to_pandas()X=df_train[transform.features]y=df_train[transform.outcomes]model.fit(X,y)# Transform the testing data and use the model to predict resultsdf_test=transform(test).to_pandas()X=df_test[transform.features]y=df_test[transform.outcomes]y_pred=model.predict(X)By usingibisfor preprocessing and feature engineering, feature engineering
pipelines may be compiled to SQL and executed on a wide range ofperformant
and scalable backends. No more need
to rewrite code for production deployments, pipelines may be developed locally
(against e.g.duckdb) and deployed to production (against e.g.spark) with
only a single line of code change.Help Wanted!ibismlis a work-in-progress. If you're interested in getting involved
(whether through feature requests, PRs, or just sharing opinions), we'd love to
hear from you.
Package: ibis-mssql
IBIS Microsoft SQL BackendReleasingThis project uses Rever and GitHub actions for releasing a new package version.Make sure your current environment hasreverinstalled. You can create an environment just for the package releasing:condaenvcreate-nibis-mssql-release--fileenvs/release.yamlActivate your new environment:condaactivateibis-mssql-releaseRunrever checkto check yourreverconfiguration is correct.revercheckDelete the rever folder to start a clean release.rm-rfrever/Lets start the releasing process!Note: Maybe you want to have a fresh clone just for releasing.Note: For releasing, you probably want to clone directly from the upstream repository.Note: Ensure you have permissions to push changes to the repository.Ensure you are using the latest version of the master branch:gitfetch--all# if the repository is set as origingitcheckoutorigin/master# or, if the repository is set as upstreamgitcheckoutupstream/masterNow, if you want to release the version0.1.5(please, first check the latest version released), run:rever0.1.5After that, you can push the changes to upstream:gitpush
Package: ibis-mssqlops
Ibis-mssqlopsO que é o  Ibis-mssqlops ?Ibis-mssqlops é uma biblioteca python que adiciona funções, que são nativas doSQL SERVERmais não existem na bibliotecaibis-frameworkÉ uma extensão ao backendMSSQLda bibliotecaibis-frameworkInstalaçãopipinstallibis-mssqlopsComo usar ?>>>fromibis_mssqlopsimport*>>>tbl=ibis.table(dict(nome='string',datas='date'))>>>tbl.nome.trim()>>>tbl.datas.datefromparts(day=1)Apartir da importação as funções já ficam disponíveis para utilização- o modo interativo do ibis vem habilitado+ para desabilitar usar! ibis.options.interactive = FalseConexãoPara se conectar ao banco de dados basta passar os parâmetros de conexãoou uma url a classemssql_connectque é um invólucro sobreo conector padrão doibis-framework>>>url=f'mssql+pymssql://{servidor}/{banco}'>>>con=mssql_connect(url=url)>>>tbl=con.table('NOME_DA_TABELA')O driver padrão agora é opyodbc, mais ainda suporta opymssqlFunções adicionadasDATEFROMPARTSDATEADDDATEDIFFDATEPARTCONVERTFORMATTRIMREPLICATECOLLATELATIN(Retira acentuação gráfica)ISNUMERIC
Package: ibis-omniscidb
Ibis OmniSciDB backendIbisis a Python framework to write data analytics
code, in a similar way topandas. Ibis can
execute the queries not only in memory (as pandas does), but in different
backends, including SQL databases, and analytics databases, likeOmniSciDB.OmniSciDBis SQL-based,
relational, columnar and specifically developed to harness the massive
parallelism of modern CPU and GPU hardware. OmniSciDB can query up to billions
of rows in milliseconds, and is capable of unprecedented ingestion speeds,
making it the ideal SQL engine for the era of big, high-velocity data.InstallYou can installibis-omniscidbviapiporconda:Install with pip:pipinstallibis-omniscidbInstall with conda:condainstall-cconda-forgeibis-omniscidbDocumentationTheibis-omniscidbdocumentation can be found in theIbis website.
Package: ibis-singlestoredb
Ibis backend for SingleStoreDBThis project contains anIbisbackend
for the SingleStore database. This allows you to access and manipulate your
data using a DataFrame-like API.InstallThis package can be installed from PyPI usingpip:pip install ibis-singlestoredbUsageConnections to the SingleStoreDB database are made using URLs that specify
the connection driver package, server hostname, server port, and user
credentials.import ibis

# Connect using the default connector
conn = ibis.singlestoredb.connect('user:password@host:3306/db_name')

# Get an Ibis DataFrame object that points to the 'employees' table
employees = conn.table('employees')

# Apply DataFrame-like operations (lazily)
res = employees[employees.name.like('Smith')][employees.deptId > 1]

# Execute the operations
res.execute()Connecting to the HTTP API is done as follows:# Use the HTTP API connector
conn = ibis.singlestoredb.connect('http://user:password@host:8080/db_name')ExamplesThere are some example Jupyter notebooks in theexamplesdirectory.LicenseThis library is licensed under theApache 2.0 License.ResourcesSingleStoreIbisPythonUser agreementSINGLESTORE, INC. ("SINGLESTORE") AGREES TO GRANT YOU AND YOUR COMPANY ACCESS TO THIS OPEN SOURCE SOFTWARE CONNECTOR ONLY IF (A) YOU AND YOUR COMPANY REPRESENT AND WARRANT THAT YOU, ON BEHALF OF YOUR COMPANY, HAVE THE AUTHORITY TO LEGALLY BIND YOUR COMPANY AND (B) YOU, ON BEHALF OF YOUR COMPANY ACCEPT AND AGREE TO BE BOUND BY ALL OF THE OPEN SOURCE TERMS AND CONDITIONS APPLICABLE TO THIS OPEN SOURCE CONNECTOR AS SET FORTH BELOW (THIS “AGREEMENT”), WHICH SHALL BE DEFINITIVELY EVIDENCED BY ANY ONE OF THE FOLLOWING MEANS: YOU, ON BEHALF OF YOUR COMPANY, CLICKING THE “DOWNLOAD, “ACCEPTANCE” OR “CONTINUE” BUTTON, AS APPLICABLE OR COMPANY’S INSTALLATION, ACCESS OR USE OF THE OPEN SOURCE CONNECTOR AND SHALL BE EFFECTIVE ON THE EARLIER OF THE DATE ON WHICH THE DOWNLOAD, ACCESS, COPY OR INSTALL OF THE CONNECTOR OR USE ANY SERVICES (INCLUDING ANY UPDATES OR UPGRADES) PROVIDED BY SINGLESTORE.
BETA SOFTWARE CONNECTORCustomer Understands and agrees that it is  being granted access to pre-release or “beta” versions of SingleStore’s open source software connector (“Beta Software Connector”) for the limited purposes of non-production testing and evaluation of such Beta Software Connector. Customer acknowledges that SingleStore shall have no obligation to release a generally available version of such Beta Software Connector or to provide support or warranty for such versions of the Beta Software Connector  for any production or non-evaluation use.NOTWITHSTANDING ANYTHING TO THE CONTRARY IN ANY DOCUMENTATION,  AGREEMENT OR IN ANY ORDER DOCUMENT, SINGLESTORE WILL HAVE NO WARRANTY, INDEMNITY, SUPPORT, OR SERVICE LEVEL, OBLIGATIONS WITH
RESPECT TO THIS BETA SOFTWARE CONNECTOR (INCLUDING TOOLS AND UTILITIES).APPLICABLE OPEN SOURCE LICENSE: Apache 2.0IF YOU OR YOUR COMPANY DO NOT AGREE TO THESE TERMS AND CONDITIONS, DO NOT CHECK THE ACCEPTANCE BOX, AND DO NOT DOWNLOAD, ACCESS, COPY, INSTALL OR USE THE SOFTWARE OR THE SERVICES.
Package: ibis-substrait
Ibis+SubstraitThis repo houses the Substrait compiler for ibis.We're just getting started here, so stay tuned!Usage>>>importibis>>>t=ibis.table([("a","string"),("b","float"),("c","int32"),("d","int64"),("e","int64")],"t",)>>>expr=t.group_by(["a","b"]).aggregate([t.c.sum().name("sum")]).select("b","sum")>>>exprr0:=UnboundTable:tastringbfloat64cint32dint64eint64r1:=Aggregation[r0]metrics:sum:Sum(r0.c)by:a:r0.ab:r0.bSelection[r1]selections:b:r1.bsum:r1.sum>>>ibis.show_sql(expr)SELECTt0.b,t0.sumFROM(SELECTt1.aASa,t1.bASb,SUM(t1.c)ASsumFROMtASt1GROUPBYt1.a,t1.b)ASt0>>>fromibis_substrait.compiler.coreimportSubstraitCompiler>>>compiler=SubstraitCompiler()>>>proto=compiler.compile(expr)
Package: ibkrbox
ibkrboxConstructs a Box Spread combo order for SPX or ES futures option, only required arguments are amount you want to lend or borrow , and for how many months.This utility will automatically look up current treasury rates, and add .30 to get the yield rate. This will be used to calculate limit price. rate or limit price can be overridden as needed.It can also automatically calculate the right strikes and spread, with approximate expiry for given duration. All of these can be overridden as needed.This utility is easy to install and use with existing IBKR TWS or gateway session. Just make sure to enable API access in the GUI of IBKR TWS or gateway.Please file a issue if you notice any problem(s).Installationpip install ibkrboxUsageibkrbox -h1. construct a combo SPX Box Spread lending for 50K, duration 4 months (use "--execute" option to send the order to IBKR)This will not execute the order, so you can safely run this.ibkrbox -a 50000 -m 42. same as above but using Options on ES Futures (use "--execute" option to send the order to IBKR)This will not execute the order, so you can safely run this.ibkrbox -a 50000 -m 4 --es3. construct a combo SPX Box Spread borrowing for 50K, duration 4 months (use "--execute" option to send the order to IBKR)This will not execute the order, so you can safely run this.ibkrbox -a 50000 -m 4 --short