Saravanan666/pypi-org huggingface dataset:
Package: ai71
Developers building Python 3.8+ apps can now interact seamlessly with the AI71 API thanks to the ai71 Python library. It includes built-in type checking for both requests and responses, and provides both synchronous and asynchronous HTTP clients powered by httpx.DocumentationThe API documentation can be foundhere.Installationpip install ai71UsageDefineAI71_API_KEYenvironment variable or provideapi_keyinAI71andAsyncAI71.import os
from ai71 import AI71

client = AI71()

chat_completion = client.chat.completions.create(
    messages=[{"role": "user", "content": "What is your name?"}],
    model="tiiuae/falcon-180B-chat",
)Async Usageimport asyncio

from ai71 import AsyncAI71

client = AsyncAI71()


async def main():
    stream = await client.chat.completions.create(
        messages=[{"role": "user", "content": "What is your name?"}],
        model="tiiuae/falcon-180B-chat",
        stream=True,
    )
    async for chunk in stream:
        print(chunk.choices[0].delta.content or "", end="")


asyncio.run(main())
Package: aiacc-nccl
AIACC-NCCLOptimized primitives for inter-GPU communication on Aliyun machines.IntroductionAIACC-NCCL is an AI-Accelerator communication framework for NVIDIA-NCCL.
It implements optimized all-reduce, all-gather, reduce, broadcast, reduce-scatter, all-to-all, as well as any send/receive based communication pattern.
It has been optimized to achieve high bandwidth on aliyun machines using PCIe, NVLink, NVswitch, as well as networking using InfiniBand Verbs, eRDMA or TCP/IP sockets.InstallTo install AIACC NCCL on the system, create a package then install it as root as follow two methods:method1: rpm/deb (Recommended)# Centos:wgethttp://mirrors.aliyun.com/aiacc/aiacc-nccl/aiacc_nccl-1.0.rpm
rpm-iaiacc-nccl-1.0.rpm# Ubuntu:wgethttp://mirrors.aliyun.com/aiacc/aiacc-nccl/aiacc_nccl-1.0.deb
dpkg-iaiacc-nccl-1.0.debmethod2: python-offlinewgethttp://mirrors.aliyun.com/aiacc/aiacc-nccl/aiacc_nccl-2.0.0.tar.gz
pipinstallaiacc_nccl-2.0.0.tar.gz# notes: must download and then pip install, cannot merge in oneline `pip install aiacc_xxx_url`# Both method1 and method2 can run concurrently.method3: python-pypipipinstallaiacc_nccl==2.0UsageAfter install aiacc-nccl package, you need do nothing to change code!EnvironmentAIACC_FASTTUNING: Enable Fasttuning for LLMs, default=1 is to enable.NCCL_AIACC_ALLREDUCE_DISABLE: Disable allreduce algo, default=0 is to enable.NCCL_AIACC_ALLGATHER_DISABLE: Disable allgather algo, default=0 is to enable.NCCL_AIACC_REDUCE_SCATTER_DISABLE: Disable reduce_scatter algo, default=0 is to enable.AIACC_UPDATE_ALGO_DISABLE: Disable update aiacc nccl algo from aiacc-sql-server, default=0 is to enable.PerformanceAIACC-NCCL can speedup the nccl performance on aliyun EGS(GPU machine), for example instance type 'ecs.ebmgn7ex.32xlarge' is A100 x 8 GPU and using network eRdma.GPU(EGS)CollectiveNodesNetworkSpeedup(nccl-tests)A100 x 8all_gather2-10VPC/eRdma30%+A100 x 8reduce_scatter2-10VPC/eRdma30%+A100 x 8all_reduce2-10VPC/eRdma20%V100 x 8all_reduce2-20VPC60%+A10  x 8all_reduce1-20%CopyrightAll source code and accompanying documentation is copyright (c) 2015-2020, NVIDIA CORPORATION. All rights reserved.
All modifications are copyright (c) 2020-2024, ALIYUN CORPORATION. All rights reserved.
Package: aiacc-nccl-cu11
AIACC-2.0 ACSpeed means AIACC communication Compiler Speeding.
AIACC-2.0 AGSpeed means AIACC compute Graph SPEEDing.
This is a distributed training framework plugin for PyTorch and aiacc nccl communication plugin for many deeplearning framworks including TensorFlow, PyTorch, MXNet and Caffe.
This project is to create a uniform distributed training framework plugin tool for major frameworks,
and make the distributed training as easy as possible and as fast as possible on Alibaba Cloud.
Package: aiacc-nccl-plugin
AIACC-NCCL-PLUGINOptimized socket/rdma for inter-GPU communication on Aliyun machines.IntroductionAIACC-NCCL-PLUGIN is an AI-Accelerator communication framework plugin for NVIDIA-NCCL.
It has been optimized to achieve high bandwidth on aliyun machines using InfiniBand Verbs, eRDMA or TCP/IP sockets.InstallTo install AIACC NCCL PLUGIN on the system, create a package then install it as root as follow two methods:method1: rpm/deb (Recommended)# Centos:wgethttp://mirrors.aliyun.com/aiacc/aiacc-nccl-plugin/aiacc-nccl-plugin-1.1.0.rpm
rpm-iaiacc-nccl-plugin-1.1.0.rpm# Ubuntu:wgethttp://mirrors.aliyun.com/aiacc/aiacc-nccl-plugin/aiacc-nccl-plugin-1.1.0.deb
dpkg-iaiacc-nccl-plugin-1.1.0.debmethod2: python-pypipipinstallaiacc_nccl_pluginUsageAfter install aiacc-nccl-plugin package, you need do nothing to change code!CopyrightAll source code and accompanying documentation is copyright (c) 2015-2020, NVIDIA CORPORATION. All rights reserved.
All modifications are copyright (c) 2020-2024, ALIYUN CORPORATION. All rights reserved.
Package: aia-chaser
AIA ChaserThis package provides authority information access (AIA) chasing
from a host/leaf certificate to complete its chain of trust and
generate an SSL context to establish a secure connection.OverviewAIA, an extension of the X509 standard inRFC 5280,
points a client towards two types of endpoints:CA Issuers: To fetch theissuercertificate.OSCP: To check the certificate's revocation status.Thanks to this information, it is possible to complete the chain of trust
of a certificate. Without AIA chasing, some HTTPS requests may fail if
the endpoint does not provide all the certificates of its chain of trust.You may have experienced that already when some HTTPS URL works on your
browser but fail when usingcurlorPython+requests. Then this
package could be of help to you :guide_dog:.ExamplesThe following examples showcase how to use this library with some typical
Python HTTP libraries.Standard library'surlopen:fromurllib.requestimporturlopenfromaia_chaserimportAiaChaserurl="https://..."chaser=AiaChaser()context=chaser.make_ssl_context_for_url(url)response=urlopen(url,context=context)UsingRequests: HTTP for Humans:importrequestsfromaia_chaserimportAiaChaserchaser=AiaChaser()url="https://..."context=chaser.make_ssl_context_for_url(url)ca_data=chaser.fetch_ca_chain_for_url(url)withtempfile.NamedTemporaryFile("wt")aspem_file:pem_file.write(ca_data.to_pem())pem_file.flush()response=requests.get(url,verify=pem_file.name)Usingurllib3:importurllib3fromaia_chaserimportAiaChaserurl="https://..."chaser=AiaChaser()context=chaser.make_ssl_context_for_url(url)withurllib3.PoolManager(ssl_context=context)aspool:respone=pool.request("GET",url)DevelopmentFirst of all, you must have the following tools installed and on
your$PATH.PyenvPoetryMakeThen, open a terminal on the project's directory and run:make initAcknowledgmentsThis project is based onaia.
Package: aiadv
aiadvA small helper library to download the datasets that are used in our training programs at AiAdventures.Installpip install aiadvHow to useThere is only two things that you need to knowURLsclassThis class saves the id and file name of all the available datasetsURLs.MOVIE_LENS_SAMPLE{'id': '1k2y0qC0E3oHeGA5a427hRgfbW7hnQBgF', 'fname': 'movie_lens_sample.zip'}untar_datafunctionThis function will download the dataset for you and will return the path.untar_data(URLs.YELP_REIVEWS)That's it!
Package: aianalytics-client
This project enables quering the Application Insights Analytics API while parsing the results for furthur processing in a simple manner.Application Insights Analyticsis a powerful search feature of Application Insights, which allows to query your Applciation Insights telemetry.
This module is meant to be used with other data analysis packages, such asnumpyandmatplotlib. The query result are numpy arrays.Note: this package is not for sending telemetry to the Application Insights serivce. For that you can use theofficial python sdk repo.RequirementsThis module was tested on Python 2.7 and Python 3.5. Older versions of Python 3 probably work as well.For opening the project in Microsoft Visual Studio you will needPython Tools for Visual Studio.InstallationTo install the latest release you can usepip.$ pip install aianalytics-clientUsageOnce installed, you can query your Application Insights telemetry. Here are a few samples.Query exceptions from the last 24 hours and print themfromanalytics.clientimportAnalyticsClientclient=AnalyticsClient('<Your app id goes here>','<You app key goes here>')result=client.query('exceptions | where timestamp > ago(24h) | project timestamp, type, outerMessage')forrowinresult.row_iterator():print("at{0}there was an exception of type{1}with message{2}".format(row['timestamp'],row['type'],row['outerMessage']))# Indexes can also be used instead of column names, e.g.:print("at{0}there was an exception of type{1}with message{2}".format(row[0],row[1],row[2]))Query average request duration from the last week and plot using matplotlibfromanalytics.clientimportAnalyticsClientclient=AnalyticsClient('<Your app id goes here>','<You app key goes here>')result=client.query('requests | where timestamp > ago(7d) | summarize Duration = avg(duration/1000) by bin(timestamp, 1h) | order by timestamp asc')importmatplotlib.pyplotaspltplt.plot(result["timestamp"],result["Duration"])plt.show()
Package: aiandml
MACHINE LEARNING LABORATORY
[As per Choice Based Credit System (CBCS) scheme] (Effective from the academic year 2018 - 2019) SEMESTER â€“ VII
Subject Code	18CSL76	CIE Marks	40
Course Learning Objectives: This course (18CSL76) will enable students to:
Implement and evaluate AI and ML algorithms in and Python programming language.
Descriptions (if any):
Programs List:Implement A* Search algorithm.Implement AO* Search algorithm.For a given set of training data examples stored in a .CSV file, implement and demonstrate the
Candidate-Elimination algorithm to output a description of the set of all hypotheses consistent with the training examples.Write a program to demonstrate the working of the decision tree based ID3 algorithm. Use an appropriate data set for building the decision tree and apply this knowledge to classify a new sample.Build an Artificial Neural Network by implementing the Back propagation algorithm and
test the same using appropriate data sets.Write a program to implement the naive Bayesian classifier for a sample training data set stored as a .CSV file. Compute the accuracy of the classifier, considering few test data sets.Apply EM algorithm to cluster a set of data stored in a .CSV file. Use the same data set for clustering using k-Means algorithm. Compare the results of these two algorithms and comment on the quality of clustering. You can add Java/Python ML library classes/API in the program.Write a program to implement k-Nearest Neighbour algorithm to classify the iris data set. Print both correct and wrong predictions. Java/Python ML library classes can be used for this
problem.Implement the non-parametric Locally Weighted Regression algorithm in order to fit data points. Select appropriate data set for your experiment.
Package: ai-api-client-sdk
SAP AI API Client SDKThe AI API client SDK is a Python-based SDK that enables you to access the AI API using Python methods and data structures. You can use the Client SDK to test AI API.The client SDK can be used with any implementation of AI API. Because it is independent of the runtime implementation, it doesn't provide access to runtime-specific APIs. For example, maintaining object store secrets is specific to SAP AI Core and is therefore not included in the AI API client SDK. Check for SDK offerings for your runtime that let you access any runtime-specific APIs. For more information on SAP AI Core SDK seehttps://pypi.org/project/ai-core-sdk/.For more information on the AI API specification, SAP AI Core and related topics, please refer tohttps://help.sap.com/docs/AI_CORE?version=CLOUD.Example Usagefromai_api_client_sdk.ai_api_v2_clientimportAIAPIV2Client# Instantiate the clientclient=AIAPIV2Client(base_url=AI_API_URL,auth_url=AUTH_URL,client_id=CLIENT_ID,client_secret=CLIENT_SECRET,resource_group=RESOURCE_GROUP)# Make some queries, e.g.scenarios=client.scenario.query()forscenarioinscenarios.resources:print(scenario.id)# Find a deployable executables in scenario 1111executables=client.executable.query(scenario_id="1111")forexecutableinexecutables.resources:ifexecutable.deployable==False:breakprint(executable.id)# Inspect the required parameters for the executableforparameterinexecutable.parameters:print("Parameter:{}, Type:{}".format(parameter.name,parameter.type))# Create a configurationparameter_epochs=ParameterBinding(key="training-epochs",value="1")myConfiguration=client.configuration.create(name="test",scenario_id="1111"executable_id="argo-mnist-0.2.1",parameter_bindings=[parameter_epochs])
Package: aiapy
aiapyis a Python package for analyzing data from the Atmospheric Imaging Assembly (AIA) instrument onboard NASA’s Solar Dynamics Observatory (SDO) spacecraft.
For more information, see theaiapy documentation.
For some examples of using aiapy, seeour gallery.CitingIf you useaiapyin your scientific work, we would appreciate you citing it in your publications.
The latest citation information can be found in thedocumentation, or obtained withaiapy.__citation__.Contributingaiapyis open source software, built on top of other open source software, and we’d love to have you contributePlease checkout thecontributing guidefor more information on how to contribute to aiapy.
Package: aiarena-gym
AI Arena Python EnvironmentTo get started with our python environment you can run thetraining.pyfile.This file shows you how to do a few things in our environment:Initialize a new modelImport a pretrained modelSet up the game environmentRun training with one-sided and selfplay reinforcement learningSave your model in the format that works with our researcher platformWe have set you up with a starter model in thestarter_modeldirectory. This is a simple Policy Gradient that implements a version of theREINFORCEalgorithm. We encourage you to replace this with your own models!Additionally, we set up some basic training loops in thesimulation_methods.pyfile. Feel free to change these up and make them your own!NOTE:There are two variables in thetraining.pyfile which you should not change because our game requires these to be constant:n_features: This is the dimensionality of the staten_actions: This is the dimensionality of the policyLastly, we have included the rules-based agentagent_sihing.py(the researcher platform benchmark) in case you want to train specifically against it. But be careful about overfitting because we will introduce more benchmarks which require generalization...
Package: ai-artist
I. INTRODUCTIONai_artistmade generating images easy using the Stable Diffusion AI model.II. HOW TO USE THIS PROJECT2.1. Install this packageUsing pip to install the pre-built package on Pypippip install ai_artistIf you want to use the latestai_artistversion instead of the stable one, you can install it from the source with the following command:pip install git+https://github.com/thinh-vu/ai_artist.git@main(*) You might need to insert a!before your command when running terminal commands on Google Colab.2.2. Set up your projectImport the whole package to your project:from ai_artist import *Install dependencies:!pip install transformersSet up the environment:initialize()Save Huggingface login info to use the pre-trained model:login('YOUR_HUGGINGFACE_KEY')Set up the pipeline:pipe = pipegen()2.3. Start generating imagesProvide your image description to the prompt:image_gen("YOUR_IMAGE_DESCRIPTION", pipe)III. RERERENCES3.1. Get HuggingFace API keyGenerate a token keywithreadpermission. Read the dochereAbout HuggingfaceHuggingfaceis a community and data science platform that provides:Tools that enable users to build, train and deploy ML models based on open source (OS) code and technologies.A place where a broad community of data scientists, researchers, and ML engineers can come together and share ideas, get support and contribute to open source projects.3.2. Google Colab and GPU runtime are highly recommendedGo to the Google Colab menu: SelectRuntime>Change runtime typeand make sure thatGPUhas been chosen. You can run this AI model way faster with GPU on Google Colab than the normal CPU or your personal computer.Stable Diffusion & StabilityAIStable Diffusion on Github:hereStable Diffusion prompt guide and exampleshereIV. 🙋‍♂️ CONTACT INFORMATIONIf you want to support my open-source projects, you can "buy me a coffee" viaPatreonor Momo e-wallet (VN). Your support will help to maintain my blog hosting fee & to develop high-quality content.Momo QR
Package: ai-assignment-marker
WhatThis is a test of creating an AI marker for first year programming assignments.The parituclar assignment example is a simple converter that takes in either binary or decimal numbers and converts them to the other.WhyIn later papers using unit testing frameworks and giving out grades based on this can be done sucsessfully as the students are more confident with programming and can handle having to write a program with exact output. However in first year the focus is still on programming itself and so the challenge of the assignment is with the logic of the program and not the exact format of the output (Unless that is part of the logic!).This would mean that for example the program could output "Converting binary to decimal answer is 10" or "Converting to decimal: 10" and both would be completely acceptable.HowThe goal of the AI marker is to be able to take in a set of test cases and then run the students program against various unit tests however the grading and marking of these unit tests will be done with a LLMs.
Package: ai-assist
A command-line AI assist that can do math, search, run Python and shell command.Under experiment. Use at your own risks.Installpip install ai-assistSetupYou will need put the following environment variables in a.envfile in your home directory.# used for calling OpenAI's API
OPENAI_API_KEY=...

# used for calling Google Search API
GOOGLE_API_KEY=...
GOOGLE_CSE_ID=...You can generate/get keys from links below:OPENAI_API_KEYfromhttps://platform.openai.com/account/api-keysGOOGLE_API_KEYfromhttps://console.cloud.google.com/apis/credentialsGOOGLE_CSE_IDfromhttps://programmablesearchengine.google.com/controlpanel/allUsage$ai

WelcometotheAI.
Idomath,search,runpython/bashandmore.
Type'exit'toquit.[USER]<<What'sthelargestprimenumberlessthan1000?
...[AI]>>997
Package: aib2ofx
aib2ofx...or how to grab transaction data out of AIB's online interface, and format it
intoOFXfile.NOTE:Last AIB login update (Feb' 2021) made me realise how brittle the
overall machinery here is. The code that works around Web Storage API use is
ugly and likely to break. The most likely road forward for this project is to
decouple it intoofxstatementplugin
and (maybe) Selenium-powered CSV acquisition script. The former will be easy,
the latter will most likely be a nightmare to maintain and install, unless you
enjoy having your banking details pipe through an arbitrary docker image.Time will tell.Installationpython3 -mvenv aib2ofx
source aib2ofx/bin/activate
pip3 install aib2ofxThis will create a virtualenv foraib2ofx, fetch its code then install it with
all dependencies. Once that completes, you'll findaib2ofxexecutable in thebindirectory of this new virtualenv.UsageCreate a~/.aib2ofx.jsonfile, with AIB login details.
Set the permission bits to 0600 to prevent other system users from reading it.touch ~/.aib2ofx.json
chmod 0600 ~/.aib2ofx.jsonIt has a JSON format, single object with one key per AIB login you want to use.{
    "bradmajors": {
        "regNumber": "12345678",
        "pin": "12345"
    }
}The fields are as follows:regNumberYour AIB registered number.pinYour five digit PIN.You can put more than one set of credentials in the file; the script
will download data for all accounts for all logins.{
    "bradmajors": {
        "regNumber": "12345678",
        "pin": "12345"
    },
    "janetweiss": {
        "regNumber": "87654321",
        "pin": "54321"
    }
}Note that there's no comma after the last account details.Once you've prepared that config file, run:aib2ofx -d /output/directoryThe script should connect to AIB, log in using provided credentials,
iterate through all accounts, and save each of those to a separate
file located in/output/directory.GuaranteeThere is none.I've written that script with my best intentions, it's not malicious,
it's not sending the data anywhere, it's not doing anything nasty. I'm
using it day to day to get data about my AIB accounts into a financial
program that I use. It should work for you as good as it works for
me. See theLICENSEfile for more details.Developmentaib2ofx works only with python 3.In order to set up a dev environment clone the repository, getpoetryand runpoetry install. This will create a virtualenv with all
dependencies installed. You can activate it withpoetry shell.
Package: aibase
简介提供基础方法调用，规范代码风格结构介绍aibase
        common # 通用
        middleware # 中间件相关
        utils # 工具
    README.md   # 说明文档
    setup.py # 构建打包上传环境安装python -m pip install --user --upgrade setuptools wheel
python -m pip install --user --upgrade twine打包python setup.py sdist bdist_wheel上传python -m twine upload  dist/*
Package: aibasics
AI UncoveredAI Uncovered: A Comprehensive Guide to AI Basics and ApplicationsDocumentation:https://aibasics.halla.aiGitHub:https://github.com/chu-aie/aibasicsPyPI:https://pypi.org/project/aibasicsAI Uncovered is a 15-week, beginner-friendly course in Korean, designed to provide a comprehensive introduction to artificial intelligence (AI) and its real-world applications. Students will explore various AI concepts and techniques, such as machine learning, deep learning, natural language processing, and object detection. The course includes hands-on lab sessions using Google Colab, allowing students to practice what they've learned. By the end, students will have a solid understanding of AI fundamentals and be prepared for an AI-driven future.ChangelogSee theCHANGELOGfor more information.ContributingContributions are welcome! Please see thecontributing guidelinesfor more information.LicenseThis project is released under theCC-BY-4.0 License.