Saravanan666/pypi-org huggingface dataset:
Package: camlipy
Unofficial Python client forCamlistore.This is a work in progress.Camlipy try to behave exactly the same way that the original Camlistore Go client.
It means you can download file uploaded withcamputor the web ui, and file uploaded with Camlipy works well with the ui and camget.Installation$ sudo pip install camlipyTODOHandle symlink/hard link (inode)Sharing supportHandle multi-claim inClaimCheck out Keep schemaCreate a C extension for the rolling checksum part.A read-only FUSE support?Getting StartedfromcamlipyimportCamlistorec=Camlistore('http://localhost:3179')# Basic put/getmy_blob='my blob'blob_ref=c.put_blob(my_blob)restored_blob=c.get_blob(blob_ref)# Retrieve a blobc.get_blob('sha1-0d31c43041edf303d9d136c918a1337abc9bde97')# Dump blobs without metadatac.put_blobs(['My Blob'])# orwithopen('/path/to/file','rb')asfh:c.put_blobs([fh])# Put/restore filesc.put_file('/path/to/myfile')# orc.put_file(fileobj=open('/path/to/myfile'),permanode=True)# Get as a fileobj (temporary file)c.get_file('sha1-0d31c43041edf303d9d136c918a1337abc9bde97')# Or get directly in a filewithopen('/path/to/restored_file','wb')asfh:c.get_file('sha1-0d31c43041edf303d9d136c918a1337abc9bde97',fh)# Put/restore directoriesblob_ref=c.put_directory('/path/to/my/dir')c.get_directory(blob_ref)# Search blobsc.search('tag:mytag')Working the command line toolCamlipy provide a basic command line utility, that let put/get blobs. It supports raw blob, file and directory.$camlipyconfighttps://mycamlistorehost.com$camlipyput/path/to/file$camlipyput/this/path--permanode$camlipygetsha1-0d31c43041edf303d9d136c918a1337abc9bde97$camlipygetsha1-0d31c43041edf303d9d136c918a1337abc9bde97--contents$echo'My Blob'|camlipyput-License (MIT)Copyright (c) 2013 Thomas SileoPermission 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: cam-motion-field
Cam_motion_fieldDescriptionThis package provides quick and easy way to compute camera motion field given
two consecutive images.Installpip install cam-motion-fieldUsagefromcam_motion_fieldimportget_cam_flowimportcv2image1_file="PATH/TO/THE/FIRST/IMAGE/FILE"image2_file="PATH/TO/THE/SECOND/IMAGE/FILE"ncol=10nrow=10grid_size=(ncol,nrow)img1=cv2.imread(image1_file,0)img2=cv2.imread(image2_file,0)# origins.shape = (10,10,2)# displacements.shape = (10,10,2)origins,displacements=get_cam_flow(img1,img2,grid_size[0],grid_size[1])The above example defines a 10x10 grid and returns 100 origins and
displacement points. Both origins and displacements are absolute coordinates!Parameters:Parameters
----------
image1 : numpy array
    image1 a grayscale image
image2 : numpy array
    image2 a grayscale image
n_rows : int
    number of rows in the grid
n_cols : int
    number of columns in the gridExampleExamples where generated using the example.py. This gif shows two images where either the camera moved forward or some zoom effect took placeThe resuts are:
5x5 Grid10x10 Grid20x20 GridNotice that 20x20 has many zero displacements. This happens when the grid is too fine and no good features are detected
in the cell.
Package: camo-client
A python client for Github’sCamo image proxy.InstallationThis package is available on pypi. Installation is as simple as:pip install camo-clientUsageFor individual urlsfromcamoimportCamoClientclient=CamoClient("https://mycamoinstance.com",key="my camo key")url=client.image_url("http://someothersite.com/path/to/image.png")For html snippetsfromcamoimportCamoClientclient=CamoClient("https://mycamoinstance.com",key="my camo key")html="""\<p>
    Here is a picture:
    <img src="http://someothersite.com/path/to/image.png" alt="It's a banana">
</p>
"""client.parse_html(html)For DjangoThis doesn’t directly ship with a django filter but you can simply add
the following snippet to you templatetagsfromcamoimportCamoClientfromdjangoimporttemplatefromdjango.utils.safestringimportmark_saferegister=template.Library()@register.filterdefproxy_images(text):client=CamoClient(settings.CAMO_URL,key=settings.CAMO_KEY)returnclient.parse_html(text)ContributingFork itCreate your feature branch (git checkout-bmy-new-feature)Ensure the tests pass (nosetests)Commit your changes (git commit-am'Add some feature')Push to the branch (git push originmy-new-feature)Create new Pull Request
Package: camocomp
What is itcamocompis a Python package that can stabilize videos, i.e. generate a
video copy in which the camera motion is compensated. This results in a video
where the fixed background (e.g. buildings, roads) appears to be static.What can it be used forCamera motion compensation is useful for a variety of tasks, includingstabilizing camera shakerecovering thecamera motionfor video and scene analysisdifferentiating between theforeground motion(e.g. of actors) and
the motion caused by the moving camera (formotion analysis)Where to get itThe source code is currently hosted on GitHub at:http://github.com/daien/camocompBinary installers for the latest released version are available at the Python
Package Index:http://pypi.python.org/pypi/camocomp/And viaeasy_installorpip:easy_install camocomp
pip install camocompDependenciesNumpy: 1.6.1 or higherHugin: a recent version (around 2012)FFmpeg: a recent version (around 2012)OpenCV: version 2.4.1 or higher
(fixes a bug of the ffmpeg wrapper)Note: this package relies on Hugin’s python scripting interface (HSI):http://wiki.panotools.org/Hugin_Scripting_InterfaceInstallation from sourcesIn thecamocompdirectory (same one where you found this file), execute:python setup.py installNote: this only works on Unix-like platforms.LicenseNew BSD LicenseHow to use itWe provide a utility script calledcamocomp_videothat can generate a
stabilized copy of a video.The videoexample_mocomp.aviin theexampledirectory contains a
stabilized video obtained with the command:camocomp_video -o example_mocomp.avi -c  -v p_y -f 40 example.aviDepending on your input videos, you might need to play around with the input
field of view parameter (-foption) and/or the variables to optimize
(‘v’iewpoint, ‘p’itch, ‘y’aw, and ‘r’oll).How does it workIt relies on image stitching techniques similar to the ones used to create
panoramas from multiple photos. This allows to compensate for a vast array of
time-varying camera motions (e.g. camera shake, pan, zoom, tilt).LimitationsThe stitching approach faces the following limitations:it assumes that a large part of each frame is the background;it also assumes that the background is textured (in order to detectcontrol pointson the background);the spatial extent of the camera motion must be rather limited (i.e.
restricted panning or translation, such that the background covered is
limited) in order to avoid an extravagantly large output resolution;some camera motions are problematic (e.g. rotation around the subject);finding the correct input field of view parameter might require some
trial and error;the stitching optimization step (using hugin’s autooptimizer) is VERY slow.
Package: camonline
camonlineMake your computer camera a monitorInstallpip install camonlineUsagedockerrun-d--restartalways\--namecamonline\--device=/dev/video0:/dev/video0\-v~/.camonline:/root/.camonline\wh1isper/camonlineDevelopInstall pre-commit before commitpip install pre-commit
pre-commit installInstall package locallypip install -e .[test]Run unit-test before PR,ensure that new features are covered by unit testspytest -v
Package: camo-sign
Camo signCreate signed URLs for use withcamo.Installationpip install camo-signExample usage>>>base_url='https://camo.example.com/'>>>secret_key=b'OMGWTFBBQ'>>>image_url='http://example.com/img.jpg'>>>create_signed_url(base_url,secret_key,image_url)https://camo.example.com/22fd0910eeefa6db9d4b105aa92c56d09bccf05f/687474703a2f2f6578616d706c652e636f6d2f696d672e6a7067'Changesv0.1Support generating signed URLs for camo.
Package: camote-queue
Camote Queue is aPythonimplementation of aqueueon top ofRedisthat supports introspecting a job’s position in the queue.Why another queue?I’ve tried a couple of existing queue implementation and none of them supports fetching the job’s position in the queue, hence Camote Queue was born.What’s with the name?Camote Queue is a snack I used to buy when I was a kid, its basically slices of fried sweet patato (Camote) covered with melted sugar and stacked (like a queue) in a stick.History0.1.16 (2012-09-06)Addedclearqueue method0.1.15 (2012-08-23)Addedpop_job_by_positionqueue method0.1.14 (2012-08-22)Added pubsub events on push and popAddedsubscribequeue method0.1.13 (2012-08-19)Addedsizequeue methodAdded method docstrings0.1.12 (2012-06-16)Addedget_job_by_positionqueue method0.1.11 (2012-06-14)Addedget_position_by_idqueue method
Package: campa
CAMPA is a framework for quantiative analysis of subcellular multi-channel imaging data.
It consists of a workflow that generates consistent subcellular landmarks (CSLs)
using conditional Variational Autoencoders (cVAE).
The output of the CAMPA workflow is ananndataobject that contains interpretable
per-cell features summarizing the molecular composition
and spatial arrangement of CSLs inside each cell.Visit ourdocumentationfor installation and usage examples.ManuscriptPlease see our preprint“Learning consistent subcellular landmarks to quantify changes in multiplexed protein maps”(Spitzer, Berry et al. (2022)) to learn more.InstallationCAMPA was developed for Python 3.9 and can be installed by running:pip install campaContributingWe are happy about any contributions! Before you start, check out ourcontributing guide.
Package: campbel
pypi: https://pypi.python.org/pypi/campbel/0.0.7便利モジュールです。現段階ではRDS、S3への接続のモジュールになります。セットアップpip install campbelチュートリアルdbに接続しようfrom campbel.AWS import Rds as rdsrds = rds.Rds(db_host = 'DBホスト',db_user = 'DBユーザー',db_password = 'DBパスワード',db_name = 'DB名',charset = 'utf-8',debug=False)これで接続完了！sql文を実行してみようsql = ''rds.sqlExecute(sql)rds.dbClosed()これで任意のsql文を実行できます！以下を使うと高速にかつ正確にsql文が実行できます。(内部ではsqlExecute()が実行されています。)インサートしよう辞書形式を配列にしましょう。data_list_array = [{'name':'ryu', age:27, 'massage':'こんにちは'},{'name':'koumei', age:26, 'massage':'game'},{'name':'hyuga', age:21, 'massage':'meshi'},{'name':'kenjo', age:20, 'massage':'study'},]r = rds.insertListExecute('user', data_list_array)これはINSERT INTO user (name,age,message) VALUES ("ryu",27,"こんにちは")INSERT INTO user (name,age,message) VALUES ("koumei",26,"game")INSERT INTO user (name,age,message) VALUES ("hyuga",21,"meshi")INSERT INTO user (name,age,message) VALUES ("kenjo",20,"study")と等価です。取得してみようr ＝ rds.insertListExecute('user', 'name', where='')data = r.fetchall()これはSELECT name FROM userと等価です。アップデートしてみようr = rds.updateListExecute('user', {'age':8, 'where':'name="ryu"'}, where='where')これはUPDATE user SET age=8 WHERE name="ryu"と等価です。なお、r._executedで実行した一番最後のsqlが確認できます。(複数まとめて実行した場合は一番最後のsqlの表示になります。)もしその都度確認したければ、インスタンスを作る段階でdebug=Trueとしてください。次はs3に接続してみよう！from campbel.AWS import S3 as s3s3 = spython setup.py register3.S3(access_key = 'アクセスキー',secret_access_key = 'シークレットアクセスキー',bucket_name = 'バケット名',)これで接続完了です。S3の/test/とディレクトリを作ろう。s3.createDir('test/')ローカルのa.txtをデータを入れよう！s3.uploadFileToS3(a.txt, 'test/a.txt')<!--  -->
Package: campbells
Campbells 🥫A condensed web scraping library.Install•ExamplesAdapted frombeautifulsoup4's inner package, then linted, refactored, reduced, and seasoned to taste.DevelopmentTo run pre-commit checks and tests:pre-commitrun--all-files&&pdmrunpython-mpytestExamplesTo parse a string as HTML, your reciple should call forCampbellsSoup:fromcampbellsimportCampbellsSouphtml_str="<html><body><p>Hello world!</p></body></html>"soup=CampbellsSoup(html_str)InstallationCampbellsis available on PyPi:pipinstallcampbellsThe dependencies needed to usehtml5libandlxmlparsers are not installed by default.
They can be installed with:pip install campbells[html5lib]to be able to usehtml5lib.Pros:closest to how browsers parses web pages, very lenient, creates valid HTML5.Cons:slowest parser.pip install campbells[lxml]to be able to uselxml.Pros:fastest parser.Cons:heavier dependency (C extension).
Package: campbx
AboutThis library provides python bindings for theCampBX bitcoin trading platform.
To obtain API access pleasesee the documenation at CampBX.Note:All endpoints that require authentication are using HTTPS.Installationpip install campbxDocumentationRead the full documentation onReadTheDocs.Quick UsageThe API does not require a username and password, however you will have limited access
to only the public endpoints.Initializing the API:from campbx import CampBX
c = CampBX('username', 'password')Getting market ticker:c.xticker()

{'Best Ask': '5.17', 'Best Bid': '5.07', 'Last Trade': '5.07'}Check your account balance:c.my_funds()

{'Liquid BTC': '0.00000000',
 'Liquid USD': '2.19',
 'Margin Account BTC': '0.00000000',
 'Margin Account USD': '0.00',
 'Total BTC': '15.00000000',
 'Total USD': '74.58'}Check your open orders:c.my_orders()

{'Buy': [{'Dark Pool': 'No',
   'Fill Type': 'Incremental',
   'Margin Percent': 'None',
   'Order Entered': '2012-04-10 08:59:51',
   'Order Expiry': '2012-05-11 00:00:00',
   'Order ID': '239801',
   'Order Type': 'Quick Buy',
   'Price': '4.50',
   'Quantity': '16.00000000',
   'Stop-loss': 'No'}],
 'Sell': [{'Dark Pool': 'No',
   'Fill Type': 'Incr',
   'Margin Percent': 'None',
   'Order Entered': '2012-04-05 22:07:05',
   'Order Expiry': '2012-05-06 00:00:00',
   'Order ID': '215603',
   'Order Type': 'Quick Sell',
   'Price': '5.20',
   'Quantity': '15.00000000',
   'Stop-loss': 'No'}]}LicenseMIT LicenseCopyright (c) 2011 Glen ZangirolamiPermission 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: campdown
# Campdown #Campdown is a utility that can be used to automate downloading of tracks and
albums from Bandcamp. It requires the Python interpreter, version 3.4+ and is
not platform specific.## PyPI ##Campdown has been added to the Python package index and can now be easily downloaded
and installed (as well as updated) using the following command.$ pip install campdown –upgrade## Setup ##Campdown can be installed allowing you to directly run thecampdowncommand.
This also installs any dependencies the script might have.$ python3 setup.py installIf you don’t want to use the setup but would like to still use the script
directly or intend to use it within your project you will have to still installrequests,mutagenanddocoptwhich you can download usingpip.$ pip install -r requirements.txtTo run Campdown simply execute the following command.$ campdown <Track, album or discography URL>If you want to use the CLI without the setup you can run thecampdown.pyscript in the project root directory. Make sure to have dependencies installed
beforehand.## Notice ##Campdown allows you to download tracks that are openly available on each of
Bandcamp’s sub-domains. Keep in mind that these can be accessed without using
any special tools. Campdown only automates the otherwise tedious process of
searching each page’s code for the link to the given file.This however also means that the downloaded tracks only come with a low bitrate
of 128kbit/s. This is probably to reduce traffic while viewing and listening to
the songs that are openly available.If you want the full quality of a given track you will have to buy it from
Bandcamp as you usually would. Also, if you like a song or album you should
probably think about supporting the artist/band.## License ##This repository is released under the MIT license. For more information please
refer to [LICENSE](https://github.com/catlinman/campdown/blob/master/LICENSE)
Package: campfire
A simplecampfire apiimplementation.ExamplesMentions notifications:importre# You can replace with growl.fromgi.repositoryimportNotifyTOKEN='xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'MENTIONS=re.compile('(?:marsam|all|everybody|help)',flags=re.IGNORECASE|re.UNICODE)campfire=Campfire('lucuma',TOKEN)Notify.init('Campfire mentions')formsgincampfire.stream('433622'):msg_body=msg['body']ifmsg_bodyandre.match(MENTIONS,msg_body):Notify.Notification.new(self.name,msg_body,'dialog-information').show()
Package: campfire-basic
This module includes several basic functions for asynchronouslycommunicatingwith Campfire server. It can also
receive push notifications. To learn what requests you can send, visithttps://github.com/ZeonXX/CampfireApi/tree/master/src/main/java/com/dzen/campfire/api/requestsInstallationUsingpipcommand:pip install campfire-basicOr, clone this repository usinggitcommand:git clone https://github.com/Camper-CoolDie/campfire-basicExamplesRequestingimportcampfireimportasyncioasyncdefmain():print(awaitcampfire.send("RProjectVersionGet"))# {'ABParams': {}, 'version': '1.290'}asyncio.run(main())The code above gets the current version of Campfire server and shows it.Log inCertain types of requests will raise an exception if you're not
logged in. To proceed with those requests, you need to authorize first.
In this module, this can be done via calling thelogin()function,
and to send the request as an authorized user, call thesend()method of
a returned object.importcampfireimportasyncioreq={"fandomId":10,"languageId":1}asyncdefmain():print(awaitcampfire.send("RFandomsGet",req))# ApiRequestException: Error occurred while processing request ("ERROR_UNAUTHORIZED")log=campfire.login("email","password")print(awaitlog.send("RFandomsGet",req))# {'fandom': {'subscribesCount': 1105, 'imageId'...asyncio.run(main())Receiving notificationsYou can receive every notification Campfire server sends
to you, or only a certain type.importcampfireimportasynciolog=campfire.login("email","password")# Generate GCM token, which contains a FCM token we needtoken=campfire.token()asyncdefmain():# Send the token to Campfire serverawaitlog.send("RAccountsAddNotificationsToken",{"token":token.fcm})# Listen to notificationsdefnotifi(n):print(notifi)# The "final point" where our program will continue listening to notifications# until we press Ctrl + C or some unexpected exception happens;# if you want to wait for a single notification, see the next exampleawaitcampfire.listen(token,notifi)asyncio.run(main())Or, wait for a notification:importcampfireimportasynciolog=campfire.login("email","password")token=campfire.token()asyncdefmain():awaitlog.send("RAccountsAddNotificationsToken",{"token":token.fcm})# Wait for a notificationasyncwithcampfire.wait(token)asn:print(n)# With filter (wait for a subscriber)asyncwithcampfire.wait(token,{"J_N_TYPE":4})asn:print(n["account"]["J_NAME"])# Timeout!try:asyncwithcampfire.wait(token,{},15.0)asn:print(n)exceptasyncio.TimeoutError:print("Time is out")asyncio.run(main())Getting a resourceYou can also request Campfire to get a picture or another sort of a
resource. This can be done almost the same way we request the main
server. To request Media server, if you prefer requesting using
Request class, just replace it with "RequestMedia". Or add a "server = 1"
argument to thesend()function. Returning value will be of typebytesifRResourcesGetrequest sent.importcampfireimportasyncioasyncdefmain():res=awaitcampfire.send("RResourceGet",{"resourceId":1},server=1)print(len(res))# The length of res will be printedasyncio.run(main())
Package: campie
CAMPIE 🥧Python APIs to simulate various CAMs
(Content Addressable Memory)
on GPUs at scale.InstallationExampleDocumentationExamplesContributingOverviewCAMPIE is a utility library that builds on top ofNumPyandCuPyfor fast and efficient simulation of CAM hardwares on CUDA GPUs.It implements custom CUDA kernels for ACAM (Analog CAM) and TCAM (Ternary Cam) simulation
and adjacent utility functionality accessible under a simple Python API.InstallationCAMPIE usesCuPyunder the hood,
which requires you to install a different package based on your CUDA version if you are using pip.The CUDA version that you are installing CAMPIE for is specified as anextralike below:pip install campie[cu11x]forPoetry, this would be:poetryadd-Ecu11xcampieThe available CUDA version extras are as follows:cu110,cu111,cu11x,cu12x.
You should only ever install one CUDA extra or you will cause conflicts.For more context, see theCuPy installation instructionsand
thepyproject.toml.Exampleimportcampieimportnumpyasnpx=np.nan# nan = don't care# cam_rows x columnscam=np.array([[0,0,1,0],[1,1,x,0],[0,0,0,0],[x,x,0,0],[0,0,1,1],])# input_rows x columnsinputs=np.array([[0,0,0,0],[0,1,0,0],[1,1,1,0],]).astype(np.float64)# this runs on the GPU, `matches` is still in GPU memorymatches=campie.tcam_match(inputs,cam)print(matches)# -> input_rows x cam_rowsarray([[0,0,1,1,0],# input 1 matches cam rows 3 and 4[0,0,0,1,0],# input 2 matches cam row 4[0,1,0,0,0],# input 3 matches cam row 2])For detailed information on all available APIs, visit thedocumentation.
Alternatively, see theexample notebookfor a practical introduction.ContributingDependency ManagementPython dependencies are managed viaPoetry:poetryinstall-Ecu11xPoetry is also used to publish the library to PyPI:poetrybuild
poetrypublishFormatting & LintingCAMPIE usesblackandisortto format Python source code.To format all Python files:black.
isort.Additionally, CAMPIE usesruffto lint Python source code.To lint all Python files:ruff.Finally, you can also use the script provided inscripts/format.pyto
format and lint everything at once.# installed into the virtual environment by poetryformat# or alternativelypythonscripts/format.pyReference Generationscripts/gen_reference.pyis used to extract doc comments from the source
code and generatesdocs/reference.md.To regenerate the reference:# installed into the virtual environment by poetrygen-reference# or alternativelypythonscripts/gen_reference.py
Package: campos
camposcampos can generate forms from your model objects or help you to easily create
them using fields as building blocks. Take a minute to check examples dir.RequirementsPython 3+QtPyYou need PyQt5, PyQt4 or PySide installed in your system to make use ofcampos. If several of these packages are found,PyQt5is used by
default unless you set theQT_APIenvironment variable.QT_APIcan take the following values:pyqt5 (to use PyQt5).pyqt or pyqt4 (to use PyQt4).pyside (to use PySide).InstallationYou can use pippip install camposor install it from the source packagepython setup.py installLicenseThis project is licensed under the MIT license.