Saravanan666/pypi-org huggingface dataset:
Package: binfilepy
binfilepySoftware library to read and write binary file (.adibin format).Example to write a binary file:from binfilepy import BinFile
from binfilepy import CFWBINARY
from binfilepy import CFWBCHANNEL

with BinFile(filename, "w") as f:
    header = CFWBINARY()
    header.setValue(1.0 / 240.0, 2019, 1, 28, 8, 30, 0.0, 0.0, 2, 0)
    f.setHeader(header)
    channel1 = CFWBCHANNEL()
    channel1.setValue("I", "mmHg", 1.0, 0.0)
    f.addChannel(channel1)
    channel2 = CFWBCHANNEL("II", "mmHg", 1.0, 0.0)
    f.addChannel(channel2)
    chanData = []
    d1 = [1, 2, 3, 4, 5, 6, 7, 8, 8, 7, 6, 5, 4, 3, 2, 1]
    d2 = [8, 7, 6, 5, 4, 3, 2, 1, 1, 2, 3, 4, 5, 6, 7, 8]
    chanData.append(data1)
    chanData.append(data2)
    f.writeHeader()
    f.writeChannelData(chanData)
    f.updateSamplesPerChannel(16, True)Example to read a binary file:from binfilepy import BinFile

with BinFile(filename, "r") as f:
    # You must read header first before you can read channel data
    f.readHeader()
    # readChannelData() supports reading in random location (Ex: Read 10 secs of data at 1 min mark)
    data = f.readChannelData(offset=60, length=10, useSecForOffset=True, useSecForLength=True)File open modeCurrently, there are three modes to open a file:"w": For writing to a new file.  You need to make sure the file doesn't exist."r": For reading from an existing file.  You need to make sure the file exists."r+": For appending data to an existing file.  You need to make sure the file exists.You can use either syntax:with BinFile(filename, "w") as f:
    ...
    ...orf = BinFile(filename, "w")
f.open()
...
...
f.close()
Package: binformat
Binfmt is a binary exchange formatPermuatiouses a binary format called binformat.
This is a python implementation of said format.UsageThe module exports main 2 methodswrite_msgandread_msg, as well as their safe (non-exception throwing) counterpartssafe_write_msgandsafe_read_msg.Documentation:write_msgTakes 2 argumentssfile: a BufferedWriter that can have binary values write toobj: one of the types that binformat can represent, that will be writensafe_write_msgTakes 2 argument:filename: a filename that the file should be written to, should there not be issues with writing the valueobj: as in aboveIt also returns 1 value: EitherNoneorstrwhich is an error stringread_msgTakes 1 argument:file: a BufferedReader that can have binary values read fromIt also returns 1 value: an object that has been read from the file.safe_read_msgTakes 1 argument:filename: a filename that the file should be read fromIt also returns 1 value: an object that has been read from the file or an error.Exampleimportbinformatsafe_write_msg("hexxy",{1:b"Hello world",2:[1,2,3]})withopen("hexxy","rb")asf:print(read_msg(f))# { 1: b"Hello world", 2: [1, 2, 3] }TestingRuntests.py
Package: bingads
The Bing Ads Python Software Development Kit (SDK) Version 13.0 enhances the experience of developing Bing Ads applications
with the Python programming language.
The SDK includes proxy classes for all Bing Ads API web services and abstracts the low level details of authentication with OAuth.
You can also read and write bulk files with the SDK BulkFileReader and BulkFileWriter,
and use the high level BulkServiceManager interface to abstract and execute operations in the low level Bulk API. For more information, seeBing Ads Client Libraries.Getting StartedTo get started developing Bing Ads applications with Python, install the SDK and either start with theexamplesor follow one of the application walkthroughs. For more information, seeGetting Started Using Python with Bing Ads Services.External Dependenciessuds-communityrequestsenum34
Package: bingai
BingAI (ChatGPT)Bing AI API for ChatGPTInstallationpip install bingai --upgradeImportant Feature - No Manual Intervention Required100% Programmatic Run
Edge browser opens up and automatically fetches tokens, no manual intervention whatsoeverUsagefrom bingai import BingSession
session = BingSession(email, password)
session.run()Microsoft credentials for the account which has access to the Bing Chat feature
Package: bingart
🎨 bingartbingart is an unofficial 🤫 API wrapper for Bing Image Creator (based on DALL-E 3). It allows you to programmatically generate 🖼️ AI-powered images using Bing's image creation tool.⚠️Warning:The_Uauth cookie should be changed every 2-4 weeks for working.💡 DescriptionThis module uses web scraping and engineering techniques to interface with Bing's internal image creation APIs. It is not an official API client.🔑 Key Features🖼️Generate imagesby providing a text prompt📸Get image URLsup to 4 generated images🔐Authenticationvia saved Bing cookies or auto-fetched from browsers⚠️Custom exceptionsfor common issues💻 UsageImport and instantiate theBingArtclass with a valid_Ucookie value:frombingartimportBingArtbing_art=BingArt(auth_cookie_U='...')try:results=bing_art.generate_images('sunset')print(results)finally:bing_art.close_session()Sometimes an extra cookie calledKievRPSSecAuthis required for it to work properlybing_art=BingArt(auth_cookie_U='...',auth_cookie_KievRPSSecAuth='...')Also, you can try the auto cookie search featurebing_art=BingArt(auto=True)Callgenerate_images()with your query text:results=bing.generate_images("a cat painting in Picasso style")The return value contains image URLs and original prompt:{"images":[{"url":"https://..."}],"prompt":"a cat painting in Picasso style"}🚨 ExceptionsAuthCookieError: Invalid authentication cookiePromptRejectedError: Prompt rejected as unethical🤝 ContributingPull requests welcome! Please open an issue to discuss major changes.
Package: bingbong
PingPongPingPong is a simple library to manage pings(prompt) and pongs(response). The main purpose of this library is to manage histories and contexts in LLM applied applications such as ChatGPT.The basic motivations behind this project are:Abstract prompt and response so that any UIs and Prompt formats can be adoptedThere are a number of instruction-following finetuned language models, but they are fine-tuned with differently crafted datasets. For instance, the Alpaca dataset works when### Instruction:,### Response:, and### Input:are given while StackLLaMA works whenQuestion:andAnswer:are given even though the underlying pre-trained LLM is the same LLaMA.There are a number of UIs built to interact with language model such as Chatbot. Even with a single example of Chatbot, one could use Gradio while other could use JavaScript based tools, and they represents prompt histories in different data structure.Abstract context management strategies to apply any number of context managementsThere could be a number of strategies to effectively handle context due to the limit of the number of input tokens in language model(usually 4096). It is also possible to mix different strategies.Installation$pipinstallbingbongExample usagefrompingpongimportPingPongfrompingpong.gradioimportGradioAlpacaChatPPManagerfrompingpong.contextimportCtxAutoSummaryStrategyfrompingpong.contextimportCtxLastWindowStrategyfrompingpong.contextimportCtxSearchWindowStrategyppmanager=GradioAlpacaChatPPManager()strategies=[CtxAutoSummaryStrategy(2),CtxLastWindowStrategy(1),CtxSearchWindowStrategy(1)]foriinrange(3):ppmanager.add_pingpong(PingPong(f"ping-{i}",f"pong-{i}"))forstrategyinstrategies:ifisinstance(strategy,CtxAutoSummaryStrategy):sum_req,to_sum_prompt=strategy(ppmanager)ifsum_reqisTrue:# enough prompts are accumulated...elifisinstance(strategy,CtxLastWindowStrategy):last_convs=strategy(ppmanager)# I am only interested in the last 1 conversations...elifisinstance(strategy,CtxSearchWindowStrategy):forcur_wininstrategy(ppmanager):# looking the entire conversation through# a sliding window, size of 1# find out relevant history to the recent conversation...TodosAdd a working example with Gradio applicationMake the documentation more Beginner friendly
Package: bing-brush
One-line Image Generating Program Based on the Bing Image Createor (Powered by DALL·E 3)Credit: The solution of invoking Bing Image Creator API is fromhttps://github.com/acheong08/BingImageCreator.Installationpipinstallbing_brushObtain your cookieThe cookie of Bing.com is needed. You need to login to Bing.com first, then follow the steps below to write your cookie to a file (e.g.,cookie.txt):Step0:Visthttps://www.bing.com/images/createStep1:Press F12 to open dev tools, then refresh the web page to run all requests again:Select any rquest with type of xhr, then click the head of the requestStep2:In the detail of the request header, find theCookiesection, copy the value of it to your file (e.g., cookie.txt)Then your cookie for Bing.com has successfully be stored.UsageCLI# -c is short for --cookie, -p is short for --promptbing_brush-ccookie.txt-p'a cute panda eating bamboos'-ooutput_folderThis command will generate 4 pictures located inoutput_folder, example outputs:Python APIbrush=BingBrush(cookie='/path/to/cookie.txt')brush.process(prompt='a cute panda eating bamboos',out_folder='output_folder')TODOunit testsupport for obtaining cookie from os.envLogoLogo of this project is generated by Bing Image, prompt:A minimalist logo vector image, square-shaped, with a magical brush implemented in Python language in the center, colorful, digitial artContribution
Package: binge
Name:bingeWebsite:https://github.com/ceyzeriat/bingeAuthor:Guillaume SchworerVersion:0.1Lazy multi-process your callables in three extra charactersBuilt byGuillaume Schworer. Licensed under
the GNU General Public License v3 or later (GPLv3+) license (seeLICENSE).InstallationJust runpip install bingeto get the most recent stable version.UsageThe only entry point is thebinge.Bclasse. You’ll just use it like this:>importtime>frombingeimportB>deff(x,a=2):>time.sleep(1)>returnx*a# normal call>[f(x)forxinrange(4)][0,2,4,6]# takes 4 seconds to run# binged call, using 3 extra characters: `B`, `(`, and `)`>B(f)([xforxinrange(4)])[0,2,4,6]# takes 1 second to run on 4 CPUs# and if you're very lazy, you could even call>B(f)(range(4))# and what about the `a` parameter? - too easy>B(f)(range(4),3)[0,3,6,9]# and guess what also works?>B(f)(range(4),a=[1,2,3,6])[0,2,6,18]More usage details, seeexample.pyDocumentationAll the options are documented in the docstrings for theBclasses.
These can be viewed in a Python shell using:frombingeimportBprint(B.__doc__)or, in IPython using:frombingeimportBB?LicenseCopyright 2018 Guillaume Schworerbinge is free software made available under the GNU General
Public License v3 or later (GPLv3+) license (seeLICENSE).Changelog0.1.0 (2018-05-03)Initial release
Package: bin-generator
Bin generatorThis repo can now be installed with pip:pipinstallgit+https://gitlab.com/six-two/bin_generatorExample usageYou can see some example data in theexamplefolder of the source code repository.
To try them out, use the following command:src/bin-generatorexample/bins.yaml--dataexample/data.yamlKnown issuesInterrupting the script will delete the remaining files
Package: bingenetic
BinGeneticThis repository contains a simple python library to convert binary data (in digital form) to genetic codes and further genetic codes back to binary data.Author:Ravin KumarBinary Code to Genetic Code:importbingeneticgenetic_code=bingenetic.btg(["00011011"],"dna")# first parameter is binary code as a list, second parameter is the type of genetic code i.e. DNA, or RNAGenetic Code to Binary Code:importbingeneticbinary_code=bingenetic.gtb(["ACGT"],"dna")# first parameter is genetic code as a list, second parameter is the type of genetic code i.e. DNA, or RNAInstallation using pip:pip install bingeneticCopyright (c) 2020 Ravin Kumar
Website: https://mr-ravin.github.io

Permission 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.
Package: bing-hashing-image-downloader
Bing Hashing Image DownloaderPython library to download bulk of images from Bing.com.
The downloader will obtain a sha1 hash of each image as it downloads and compare it to a hash of previous
downloads before saving it to ensure no duplicate images are saved.This package uses async url, which makes it very fast while downloading.DisclaimerThis program lets you download tons of images from Bing.
Please do not download or use any image that violates its copyright terms.Installationgitclonehttps://github.com/korreckj328/bing_hashing_image_downloadercdbing_hashing_image_downloader
pipinstall.orpipinstallbing-hashing-image-downloaderUsagefrombing_hashing_image_downloaderimportdownloaderdownloader.download(query_string,limit=100,output_dir='dataset',adult_filter_off=True,timeout=60,size='none'verbose=True)query_string: String to be searched.limit: (optional, default is 100) Number of images to download.output_dir: (optional, default is 'dataset') Name of output dir.adult_filter_off: (optional, default is True) Enable of disable adult filteration.timeout: (optional, default is 60) timeout for connection in seconds.filter: (optional, default is "") filter, choose from [line, photo, clipart, gif, transparent]size: (optional, default is 'none') or a tuple can be entered to resize the image.verbose: (optional, default is True) Enable downloaded message.You can also test the programm by runnningtest.pyThanksThanks to the original author of this program.  It formed the base for these improvements that I made for my
own use.  You can see the original here:https://github.com/gurugaurav/bing_image_downloader
Package: bing-image-creator-api
bing_image_creator_apiThis repository was created using the code from these repositories:https://github.com/nociza/Bimghttps://github.com/acheong08/BingImageCreatorI am very thankful to the creators of these repos, they did an amazing job. I simplified the algorithm a lot and added a better (in my opinion) way to invoke the tool programmatically.What's not currently supportedUsing boosts for generationsInstallationpip install bing_image_creator_apiUsageAs a libraryimportbing_image_creator_apiimportasyncioimportwebbrowserfromgetpassimportgetpassasyncdefmain():client=bing_image_creator_api.Client(user_token=getpass("Enter your user token: "))urls=awaitclient.create("cute puppies")forurlinurls:webbrowser.open(url)asyncio.run(main())As a standalone programThe "token file" is a file containing tokens from one or more accounts, where each token is placed on a separate line. This file can have comments that start with "#". Empty lines are skipped too. Be aware that the first token from the list is used to check if the prompt will pass the filter, which may lead the account the token belongs to to be banned if the prompt is actually unsafe, so it will be mindful to use the token from an account you don't care about as the first token. Repeating tokens arenotremovedpython-mbing_image_creator_api-t'/path/to/token/file.txt'-n10-p"cute puppies"# Generate at least 10 images and then stoppython-mbing_image_creator_api-t'/path/to/token/file.txt'-p"cute puppies"# Generate images until killed (Ctrl+C)
Package: bing-image-downloader
Bing Image DownloaderPython library to download bulk of images form Bing.com.
This package uses async url, which makes it very fast while downloading.DisclaimerThis program lets you download tons of images from Bing.
Please do not download or use any image that violates its copyright terms.Installationpipinstallbing-image-downloaderorgitclonehttps://github.com/gurugaurav/bing_image_downloadercdbing_image_downloader
pipinstall.Usagefrombing_image_downloaderimportdownloaderdownloader.download(query_string,limit=100,output_dir='dataset',adult_filter_off=True,force_replace=False,timeout=60,verbose=True)query_string: String to be searched.limit: (optional, default is 100) Number of images to download.output_dir: (optional, default is 'dataset') Name of output dir.adult_filter_off: (optional, default is True) Enable of disable adult filteration.force_replace: (optional, default is False) Delete folder if present and start a fresh download.timeout: (optional, default is 60) timeout for connection in seconds.filter: (optional, default is "") filter, choose from [line, photo, clipart, gif, transparent]verbose: (optional, default is True) Enable downloaded message.You can also test the programm by runnningtest.py keywordPyPihttps://pypi.org/project/bing-image-downloader/DonateYou can buy me a coffee if this project was helpful to you.
Package: bing-image-urls
Bing-Image-UrlsFetch Bing image urls based on keywordsInstallationpip install bing-image-urlsUsagefrombing_image_urlsimportbing_image_urlsprint(bing_image_urls("bear",limit=2))# ['https://www.stgeorgeutah.com/wp-content/uploads/2017/01/blackbear.jpg',# 'http://www.cariboutrailoutfitters.com/wp-content/uploads/2017/03/saskatchewan-black-bear-hunting.jpg']The helper functionget_image_sizemay sometimes come handy if you need to know the size of the image.get_image_sizetakes a filename or a filelike object as input and outputs the width and height of the image. Hence the raw bytes of an image from the net can be wrapped in io.BytesIO and fed toget_image_size.importioimporthttpxfromlogzeroimportloggerfrombing_image_urlsimportget_image_sizeurl="https://www.stgeorgeutah.com/wp-content/uploads/2017/01/blackbear.jpg"try:resp=httpx.get(url)resp.raise_for_status()exceptExceptionasexc:raiseSystemExit(exc)print(get_image_size(io.BytesIO(resp.content)))# (1797, 2696)Most of the code inget_image_sizeis fromimagesize_py. As soon as thePRabout filelike object is merged to the main branch, theimagesize_pypackage will be included as a depdendant package.
Package: bingmaps
LinksThis package is a python implementation of retrieving the data from bing maps API servicesProject link:https://github.com/bharadwajyarlagadda/bingmapsBing Maps API services:https://msdn.microsoft.com/en-us/library/ff701713.aspxProject Documentation:http://bharadwajyarlagadda.github.io/bingmapsRelease 0.3.7Location API servicesFinds location by addressFinds location by pointFinds location by queryElevation API servicesListPolylineSeaLevelBoundsTraffic Incidents API services
Package: bingodb
Aquesa Bingo DB is a lightweight postgresql adapter written on top of psycopg2 module for flask developers to facilitate postgresql database connectivity in not less then 1 line, i.e., connecting to database is now only 1 line of code. In future versions, multiple databases connectivity possibility will be added.# Connection Example```import bingodbbingodb.BingoDB().db_connect(database=”database_name”, credentials={“USER”:’your username here’, “PASSWORD”:’your password here’})```# Operation Example```bingodb.BingoDB().db_operation(operationName=”insert”, tablename=”your tablename here”, columns=”list of your column name(s) here (only string(s))”, values=”list of your column value(s) here (only string(s))”])```# Command Example```bingodb.BingoDB().db_operation(command=”truncate table your_table_name;”)```
Package: bingoset
CLI Toolkit to quickly create image dataset using Bing Image Search APIWelcome to BingoSetInstallpip3installbingosetSet-upGet your Bingo Image Search API key and execute below commandbingosetset-api-keyYOUR_BING_API_KEY_HEREUsagebingosetqpikachuThis will download 250 (default) images of pikachu into a directory called dataset (default)Additional/Optional Configbingosetset-max-results100Change the maximum number of images per request by the Bing API, eg : 100
DEFAULT : 250bingosetset-group-size20Change the group size of images you want to download, eg : 100
groupsize is number of search results to return “per page”
DEFAULT : 50bingosetset-base-folder-namemydatastChange the base folder name
DEFAULT : dataset
Package: bingpaper
# bingpaper[![PyPI version](https://img.shields.io/pypi/v/bingpaper.svg)](https://pypi.python.org/pypi/bingpaper)[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fguptarohit%2Fbingpaper.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2Fguptarohit%2Fbingpaper?ref=badge_shield)[![License](https://img.shields.io/pypi/l/bingpaper.svg)](https://github.com/guptarohit/bingpaper/blob/master/LICENSE)[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/ambv/black)This program automatically sets [Bing](http://www.bing.com/)'s _photo of the day_ as your desktop's wallpaper. Available for Windows, macOS & Linux.Installation------------```$ pip install bingpaper```to install from the latest source use following command```$ pip install git+git://github.com/guptarohit/bingpaper.git```Usage-----To update the wallpaper simply run:```$ bingpaper```Contributing------------Feel free to make a pull request! :octocat:License-------[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fguptarohit%2Fbingpaper.svg?type=large)](https://app.fossa.io/projects/git%2Bgithub.com%2Fguptarohit%2Fbingpaper?ref=badge_large)
Package: bingqilin
BingqilinA collection of utilities that serve as syntactic ice cream for your FastAPI appDocumentation:https://a-huy.github.io/bingqilin/Source Code:https://github.com/a-huy/bingqilinFeaturesThis package contains some utilities for common actions and resources for your FastAPI app:Extended Settings Loading- Bingqilin provides additional pieces to enhance Pydantic'sBaseSettings:Add settings sources to enable loading from.yamlfiles or.inifilesAllow the option to add the settings model to the OpenAPI docs (/docs)A baseConfigModelderived from Pydantic'sBaseSettingsthat will allow configuring parts of your FastAPI app and Bingqilin's utilities via settingsProvides aSettingsManagerclass to attach your settings model to allow live reconfiguringReconfigurable Contexts- Provide constructs to declare shared connection objects (such as databases and third-party clients) that can be initialized from settings and can be enabled for live reconfiguring.Validation Error Logging- Add an exception handler forRequestValidationErrorthat emits a log.
Useful for troubleshooting routes that support a lot of different types of requests, such as
third-party callback handlers.RequirementsThis package is intended for use with any recent version of FastAPI (>=0.95.2).Installationpip install bingqilinLicenseThis project is licensed under the terms of the MIT license.