Saravanan666/pypi-org huggingface dataset:
Package: headline-style
This filter changes a given text to Title Caps, and attempts to be clever
about SMALL words like a/an/the in the input.
The list of "SMALL words" which are not capped comes from the New York
Times Manual of Style, plus some others like 'vs' and 'v'.The filter employs some heuristics to guess abbreviations that don't need conversion.Example
... 'this is a text' is converted to 'This Is The Text'.More examples and expected behavior for corner cases are available in the package test suite.Issues, updates, pull requests, etc should be directed to github.InstallationThe easiest method is to simply use pip:(sudo) pip install headline_styleUsageheadline_style provides only one function, simply:>>> from headLineStyle import headLineStyle
>>> headLineStyle('a thing')
'A Thing'A callback function may also be supplied, which will be called for every word:>>> def abbreviations(word, **kwargs):
...   if word.upper() in ('TCP', 'UDP'):
...     return word.upper()
...
>>> headLineStyle.headLineStyle('a simple tcp and udp wrapper', callback=abbreviations)
'A Simple TCP and UDP Wrapper'The callback function is supplied with anall_capskeyword argument, indicating
whether the entire line of text was entirely capitalized. ReturningNonefrom
the callback function will allow headLineStyle to process the word as normal.Command Line UsageheadLineStyle also provides a command line utilityheadLineStyle:>>>  $ headLineStyle make me a title
... Make Me a Title
... $ echo "Can pipe and/or whatever else" | headLineStyle
... Can Pipe and/or Whatever Else
... # Or read/write files:
... $ headLineStyle -f infile -o outfileIn addition, commonly used acronyms can be kept in a local file
at~/.headLineStyle.txt. This file contains one acronym per line.
The acronym will be maintained in the title as it is provided.
Once there is e.g. one line sayingTCP, then it will be automatically
used when used from the command line.>>> $ headLineStyle I LOVE TCP
>>> I Love TCPLimitationsThis is a best-effort library that uses regexes to try to do intelligent
things, but will have limitations. For example, it does not have the contextual
awareness to distinguish acronyms from words: us (we) versus US (United States).The regexes and titlecasing rules were written for American English. While
there is basic support for Unicode characters, such that something like
"El Niño" will work, it is likely that accents or non-English phrases will
not be handled correctly.If anyone has concrete solutions to improve these or other shortcomings of the
library, pull requests are very welcome!LicenseCopyright [2022] [Vinod Baste]Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License athttp://www.apache.org/licenses/LICENSE-2.0Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Package: headlock
Headlock - Python/C Bridge for UnittestingAboutThis is an adapter for testing C code via tests written in python.
When being combined i.e. with pytest it provides a very powerful and
convinient way of writing (unit-/integration-) tests for C code.In contrary to other C/Python bridges (like ctypes, cffi, swing, ...)
the goals of this projects are:Run (and Compile) a piece of C code (Module Under Test)
out of the box with as less lines of Python code as possible.
No need to create Makefile, no need to run extra build steps.Provide a simple, intuitive API for accessing C objectsAllow to quickly:mock the underlying C modules in Pythonwork with different binaries of a Module Under Test at
the same time.testing a Module Under Test with binaries compiled with
different preprocessor definesRun the C code in a separate Address Space to avoid that a crashing
Module Under Test crashes also the testing python code
(Not implemented yet!).Especially make it work with embedded systems, so thatC code can be run onreal hardwarewhile python tests run on PC.
(Mainly useful for integration tests)
This is not implemented yet!C code can be run on PC instead of embedded environment.
(Mainly useful for unittests)Explicitly Non-Goals Are:Supporting C++ is not plannedPerformance has a very low priority. This does not mean that it is
slow. But if speed conflicts with one of the goals of this project,
there will be no compromises in favour of speed.Being self-contained is not planned. A C-compiler is required
to be installed. Furthermore currently LLVM has to be installed
at it is used for parsing the file.Python < 3.6 will never be supportedSampleThis piece of C-code contains a macros, a struct a function
implementation and a function that is relying on
(which should be mocked):#include"underlying_module.h"structops_t{inta,b;};#define MACRO_2   (MACRO_1 + 1)intfunc(structops_t*p){returnunderlying_func(p->a+p->b+MACRO_1);}You can access it from python throughheadlocklike:fromheadlock.testsetupimportTestSetup,CModule@CModule('dummy.c',MACRO_1=1)classTSSample(TestSetup):defunderlying_func_mock(self,param):returnparam.val+4000withTSSample()asts:ops=ts.struct.ops_t(a=ts.MACRO_2,b=20)assertts.func(ops.ptr).val==4021This demonstrates how:You can handle different binaries of the same C-source per .py file
(as each one is a TestSetup derived class instead of a module)Every binary can be compiled with other parameters
(PY_MACRO can be set differently per testsetup)structures/unions/enums/typedefs can be accessed from Python without
extra declarations (struct ops_tin this case).You can access C-functions from Python without extra declarations
(funcin this case)You can access C-macros from Python without extra declarations
(C_MACROin this case)You can call python-methods from C (=mocking C functions that are
not part of the Module Under Test;underlying_funcin this case). It is even possible to
dynamicially replace mocks (i.e. by unittest.mock.Mock())StatusCurrently this is alpha.For a list of planned but not yet implemented features please refer toDevelopment Status
Package: headloop
HeadloopPackage for designing headloop primers to use in headloop suppression PCR to
suppress amplification of a known haplotype.
Copyright (C) July 2020, Gareth T. PowellLicenseThis program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.You should have received a copy of the GNU General Public License
along with this program.  If not, seehttps://www.gnu.org/licenses/.DescriptionFunction designs tags from guide sequence provided by the user, with frameshifting
to minimise Tm differences between the tags and the PCR primers, then adds the 'best'
tags to the correct PCR primer provided by the user, depending upon strand orientation
of the guide sequence relative to the PCR primers e.g. if the guide sequence in on the
same strand as the sense primer, a reverse complement tag is added to the sense
primer and an offset tag is added to the antisense primer.For further details of headloop suppression PCR, see the paper at eLife:Kroll, F., Powell, G.T. et al (2021) eLife 10:e59683, doi: 10.7554/eLife.59683
https://doi.org/10.7554/eLife.59683Installationpip install headloopThis package uses 'melting' from Erik Clarke [https://github.com/eclarke/melt] to
calculate Tm of primers and headloop tags, and Seq & SeqRecord from Biopython
[https://biopython.org/wiki/Seq] for reverse complementation and object input/output.UsageTo use this package, the user needs to provide four variables:sense_oligo     #string containing the sense primer
antisense_oligo #string containing the antisense primer
guide_context   #string containing guide sequence and >= 15 bp forward context
orientation     #is the guide in the same strand as the 'sense' primer or 'antisense' primer?Example (tbx16_AA):from headloop.designer import design

design('CTGGTCCAGTGCGTTATTGG', 'AGCCAAATGCTTCTTGCTCTTTT', 
       'CTACAGGACGTACCTGCACCCGGATTCACCAGCGCCCG', 'antisense')Returns:
Two primers as SeqRecord objects, with comments on Tm matching in the descriptionCCTGCACCCGGATTCACCAGCTGGTCCAGTGCGTTATTGG
WARNING: Could not optimise sense headloop tag (Tm difference > 3°C) 

GGTGCAGGTACGTCCTGTAGAGCCAAATGCTTCTTGCTCTTTT
Tm difference < 3°C

(Gives a warning flag if the Tm difference between the headloop tag and the 
 base primer is calculated to be > 3C)
Package: headmouse
HeadmouseThe HeadMouse module provides an interface by opening the web camera anddetecting the user's face to control the mouse by tilting the head,
using the tip of the nose as reference point.
It can also be customized to trigger different functions instead of a mouse click when the user winks.
To use the module it's necessary to have the file shape_predictor_68_face_landmarks.dat.Compressed:http://dlib.net/files/shape_predictor_68_face_landmarks.dat.bz2Uncompressed:https://github.com/rfontalva/dlib_shape_predictor_68_face_landmarks/tree/master'FeaturesSingle user (closest one) detection.
Detection of right and left eyes' wink.
Detection of mouth's right corner movement.
Improved nose threshold to avoid unvoluntary movement.An opensource project developed in UTN-FRBA by Ramiro Fontalva.Run demofromheadmouseimportHeadmouseimportcv2if__name__=="__main__":predictor_path="/path/to/shape_predictor_68_face_landmarks.dat"h=Headmouse(predictor_path=predictor_path)whileTrue:h.refresh()h.show_image()key=cv2.waitKey(1)ifkey==27:#press escapeh.destroy_window()h.quit()breakifkey==32:#press spacebarh.calibrate()print("calibrated")
Package: headnode-notifier
headnode notifierSimple script for sending emails.Usage examplesusage: headnode_notifier [address] [OPTION]

Simple script for email notifications. Uses gmail by default.

positional arguments:
                    Recipient address

optional arguments:
  -h, --help        show this help message and exit
  -v, --version     show program's version number and exit
  --subject         Message subject
  --body            Message body
  --attach          Attachment
  --serv-addr       Server address. Default <smtp.gmail.com>
  --port            Server's port. Default: <587>
  --from-addr       Account address.
  --password-file   Read password from exeternal file. Prevents hard-coding
                    password anywhere in this script. IMPORTANT! Password is
                    stored as plain text! Do NOT use with your personal
                    account!Let's assume you are using default account and you have password file in a proper placeYou can specify the message subject, content and attach a file.headnode_notifier.py recipient@domain.com --subject 'Important message' --body 'Hello there!' --attach ./some/file.zipYou can also send just blank message, onlyrecipient@domain.comis truly obligatory if using default values for the rest.You can specify server, port and else if you wish with--serv-addr smpt.provider.com --port 42 --from-addr my.address@provider.comConfig handlingIf an option is not specified in the CLI, it is read from the headnode_notifier.config file. It is meant to facilitate the usage by setting default values for:Server address.Port.Mailbox address/path/to/password_fileConfig content:[server]
address = smtp.gmail.com
port = 587

[mailbox]
address =
password_file =Config location:$HOMEConfig name:.headnode_notifier.configPassword handlingIn order to avoid storing the password anywhere in the script, it is read from file. You can specify the path using--password-file /path/to/fileor in the config file. Remember that thepassword file is plain textso use the script with caution.Using gmailRemember to allowless secure appsto connect if using gmail. You can set it ongoogle account security page
Package: headpose
PurposeThis package offers classes and methods for pose estimation on images. This can be done either with deep learning
based facial landmark detection or by detecting ArUco markers.InstallationGet the latest published version:pip install headposeor install directly from GitHub:pip install git+https://github.com/OleBialas/headpose.gitTo use landmark detection you additionally have to installpytorch and torchvisionExampleimportcv2fromheadpose.detectimportPoseEstimatorest=PoseEstimator()#load the model# take an image using the webcam (alternatively, you could load an image)cam=cv2.VideoCapture(0)foriinrange(cv2.CAP_PROP_FRAME_COUNT):cam.grab()ret,image=cam.retrieve()image=cv2.cvtColor(image,cv2.COLOR_BGR2GRAY)cam.release()est.detect_landmarks(image,plot=True)# plot the result of landmark detectionroll,pitch,yawn=est.pose_from_image(image)# estimate the head poseSources & Further ReadingThisblog postnicely explained the concepts
and mathematics behind pose estimation and thistutorialwalks through the single steps of detecting facial landmarks with pytorch
Package: headpose-detection
State of art the Head Pose Estimation in Tensorflow2This repository includes:"WHENet: Real-time Fine-Grained Estimation for Wide Range Head Pose" (BMVC 2020).adapted from theoriginal source code.RetinaFace: Single-stage Dense Face Localisation in the Wildadapted fromhttps://github.com/StanislasBertrand/RetinaFace-tf2.InstallYou can install this repository with pip (requires python>=3.6);pip install headpose_estimationpipinstallgit+https://github.com/geekysethi/headpose_estimationYou can also install with thesetup.pyWith Face DetectionTo perform detection you can simple use the following lines:importcv2fromheadpose_estimationimportHeadposeheadpose=Headpose()img=cv2.imread("path_to_im.jpg")detections,image=headpose.run(img)This will return a list of dictionary which looks like this[{'bbox': [xmin, ymin, xmax, ymax], 'yaw': yaw_value, 'pitch': pitch_value, 'roll': roll_value}Without Face DetectionTo perform detection you can simple use the following lines:importcv2fromheadpose_estimationimportHeadposeheadpose=Headpose(face_detection=False)imgcrop=cv2.imread("path_to_im.jpg")detections,image=headpose.run(imgcrop)In this case it will return a list of dictionary which looks like this[{'yaw': yaw_value, 'pitch': pitch_value, 'roll': roll_value}DependnciesEfficientNethttps://github.com/qubvel/efficientnet
Package: heads-up
heads_upheadsup is a Python library for getting local and remote alerts about your code execution process.https://github.com/heads-up-org/heads-upInstallationUse the package managerpipto install heads-up.pipinstallheads-upUsage# localfromheadsup.localimportheadsupheadsup()# remotefromheadsup.remoteimportwatch,notifywatch_code=watch()## ...## Here comes your long-running code## ...notify(watch_code,"Success!!")ContributingPull requests are welcome. For major changes, contact the project owner.License[GNU General Public License v3.0]
Package: head-switcher
head_switcher: Flask Single Page App Frontend Packaging ToolThis package simplifies the process of packaging and loading frontend assets for your headless flask app.
In another word, this package install and switchheadfor yourheadlessflask apps.UsageYou need to package your single page app (SPA) frontend assets into a.frontendfile using our cli tool, and then you
can ship the.frontendfile with your python packages or simply load it from the file system.Package frontendAssuming you are using create-react-app(CRA), and are using the default build configurations.npmrunbuild# This will create a `build/` folder for the product build.build-frontend-packbuild/-opath-to-frontend.frontendHow to ship frontend assets with your python projectThe following guide assumes that you are using a similar setup with thistutorial: Packaging Python ProjectsAnd we assume your package is calledexample_package.After using the cli tool to package your frontend assets,
i.e.build-frontend-pack build/ -o spa_ui.frontend, you can save thespa_ui.frontendfile to the
following locationsrc/example_package/assets/ui.frontend, and create an empty
filesrc/example_package/assets/__init__.py.In yourpyproject.tomlfile, undertool.hatch.buildsection, make sure the artifacts field contains the
entry"*.frontend"[tool.hatch.build]artifacts=["*.frontend"]Now in your application, you can load the front assets
usingload_from_package_resources('example_package.assets', 'ui.frontend').fromhead_switcherimportinstall_to_flask,load_from_package_resourcesfromflaskimportFlaskassets=load_from_package_resources('example_package.assets','ui.frontend')app=Flask(__name__)install_to_flask(assets,app)Install frontend from a fileIf you choose to load frontend from a file, you can do it like this.fromhead_switcherimportinstall_to_flask,load_from_file_pathfromflaskimportFlaskassets=load_from_file_path('path-to-frontend.frontend')app=Flask(__name__)install_to_flask(assets,app)
Package: headtailx
Mitchell P. Krawiec-ThayerThis library providesheadxandtailxcommands which behave similarly to theheadandtailcommands, extended with support for binary data formats.Supported file types include:Feather filesPickle filesParquet filesHDF5 filesXLSXExampleLet’s compareheadandheadxfor a Feather file. Here’s the standardheadcommand:$headtest.feather-n4ARROW1����HThe above output is binary data, which is not very useful. Now let’s tryheadx:$headx-n4data.feathertimestampflavorcolorfoobar10strangered920upblue830charmNone7InstallationTo installheadtailx, simply run:pipinstallheadtailxUseSimply replaceheadwithheadx(and likewisetail->tailx) when previewing binary data formats. For exampleheadx <filename>-n3would show the first 3  lines.LicenseThis project is licensed under the MIT License. See the LICENSE file for more information.
Package: headwaters
headwatersSimple stream sources for event-driven application development.InstallFromPypi:After creating a virtual environment, on the cli:>>> pip install -U headwatersthen start the default streaming server from the cli:>>> hwThe CLI output shows the location of the server and ui.Streams can be connected to at the server:http://127.0.0.1:5555/api/v0To control the streams, use the ui running athttp://127.0.0.1:5555/uiSimple as that.While headwaters is runningyou can see and adjust the behaviour of your stream:start and stop the stream;adjust the frequency of the events emitted by the stream;trigger a burst mode to send a flurry of events, with configurable frequency and volume.:)
Package: heakl-reader
Real Python Feed ReaderThe Real Python Feed Reader is a basicweb feedreader that can download the latest Real Python tutorials from theReal Python feed.For more information see the tutorialHow to Publish an Open-Source Python Package to PyPIon Real Python.InstallationYou can install the Real Python Feed Reader fromPyPI:python -m pip install realpython-readerThe reader is supported on Python 3.7 and above. Older versions of Python, including Python 2.7, are supported by version 1.0.0 of the reader.How to useThe Real Python Feed Reader is a command line application, namedrealpython. To see a list of thelatest Real Python tutorials, call the program without any arguments:$ realpython
The latest tutorials from Real Python (https://realpython.com/)
 0 How to Publish an Open-Source Python Package to PyPI
 1 Python "while" Loops (Indefinite Iteration)
 2 Writing Comments in Python (Guide)
 3 Setting Up Python for Machine Learning on Windows
 4 Python Community Interview With Michael Kennedy
 5 Practical Text Classification With Python and Keras
 6 Getting Started With Testing in Python
 7 Python, Boto3, and AWS S3: Demystified
 8 Python's range() Function (Guide)
 9 Python Community Interview With Mike Grouchy
10 How to Round Numbers in Python
11 Building and Documenting Python REST APIs With Flask and Connexion – Part 2
12 Splitting, Concatenating, and Joining Strings in Python
13 Image Segmentation Using Color Spaces in OpenCV + Python
14 Python Community Interview With Mahdi Yusuf
15 Absolute vs Relative Imports in Python
16 Top 10 Must-Watch PyCon Talks
17 Logging in Python
18 The Best Python Books
19 Conditional Statements in PythonTo read one particular tutorial, call the program with the numerical ID of the tutorial as a parameter:$ realpython 0
# How to Publish an Open-Source Python Package to PyPI

Python is famous for coming with batteries included. Sophisticated
capabilities are available in the standard library. You can find modules for
working with sockets, parsing CSV, JSON, and XML files, and working with
files and file paths.

However great the packages included with Python are, there are many
fantastic projects available outside the standard library. These are most
often hosted at the Python Packaging Index (PyPI), historically known as the
Cheese Shop. At PyPI, you can find everything from Hello World to advanced
deep learning libraries.

[... The full text of the article ...]You can also call the Real Python Feed Reader in your own Python code, by importing from thereaderpackage:>>> from reader import feed
>>> feed.get_titles()
['How to Publish an Open-Source Python Package to PyPI', ...]
Package: healdata-utils
HEAL Data UtilitiesThe HEAL Data Utilities python package provides data packaging tools for the HEAL Data Ecosystem to facilitate data discovery, sharing, and harmonization on theHEAL Platform.Currently, the focus of this repository is generating standardized variable level metadata (VLMD) in the form of data dictionaries. See the documentationhereHowever, in the future, this will be expanded for all HEAL-specific data packaging functions (e.g., study- and file-level metadata and data).PrerequisitesPythonWhile the HEAL Data Utilities should be compatible with most versions of Python, you can download the latest version of Pythonhereand install it on your local computer. We recommend installing Python version 3.10.InstallationTo install the latest official release of healdata-utils, from your computer's command prompt, run:pip install healdata-utilsOR for the most up-to-date unreleased version run:pip install git+https://github.com/heal/healdata-utils.git!!! noteInstalling the unreleased version requires having [`git` software
installed](https://git-scm.com/downloads).