Saravanan666/pypi-org huggingface dataset:
Package: randaugment
pytorch-randaugmentUnofficial PyTorch Reimplementation of AutoAugment and RandAugment.Code taken fromhttps://github.com/DeepVoltaire/AutoAugmentandhttps://github.com/jizongFox/udaHow to install:pipinstallrandaugmentHow to use:fromautoaugmentimportRandAugment,ImageNetPolicydata=ImageFolder(rootdir,transform=transforms.Compose([transforms.RandomCrop(32,padding=4,fill=128),# fill parameter needs torchvision installed from sourcetransforms.RandomHorizontalFlip(),RandAugment(),#ImageNetPolicy(),transforms.ToTensor(),Cutout(size=16),# (https://github.com/uoguelph-mlrg/Cutout/blob/master/util/cutout.py)transforms.Normalize(...)]))loader=DataLoader(data,...)
Package: randbyrand
This module includes simple functions to retrieve and work with the digits ofA Million Random Digits with 100,000 Normal Deviatesby RAND Corporation.UsageGet all digitsimport randbyrand

# As a list
digits = randbyrand.get_digits()

# As a numpy array
digits = randbyrand.get_digits("numpy")

# As a Pandas DataFrame
digits = randbyrand.get_digits("pandas")Random number generatorimport randbyrand

random_digit = randbyrand.rand_digit().__next__()
Package: rand-convolve
This package provides the ability to run a random convolution on a given image.Main functions:rand_convolve:Returns a randomly convoluted image given an image path as input.Arguments:image: The image path for the convolution.ksize: The size of the 2 dimensional kernel. The shape of the kernel is: (size, size). (default: 3, must be an odd number.)knum: The number of random kernels to generate and use. (default: 20)int n>0: The number of kernels.-1: Use a new kernel for each pixel.ksign: The signs to be used for the kernels. (default: 0)0: All kernel values are positive.1: Kernel signs are randomly mixed between negative and positive.2: All kernel values are negative.Returns:A PIL.Image object of the convoluted image.Import with:fromrand_convolveimportrand_c... and use with:#To save the image as a file:rand_c.rand_convolve('image.png').save('new_image.png')#To store the image in a variable for further use:my_image=rand_c.rand_convolve('image.png')
Package: randcoor
randcoor BETAA basic Python library to generate random geographical coordinates with additional featuresInstallationThis module can quickly be installed with pippip install randcoorUsageGeographical coordinates are represented by a tuple with two decimal values (Example:(-73.1657655614035, 32.52677878350798))Functions that can generate random coordinates:randCoor(): Generates random coordinatesrandCoorByDist(position, distanceMax, distanceMin=0): Generates random coordinates by distancerandCoorByRule(rule, limit=None, showError=False): Generates random coordinates by checking if they follow the function rulerandCoorByArea(minCoor, maxCoor): Generates random coordinates that are between the coordinates of two pointsOther functions:calcDist(*coordinates): Calculates the distance between pointsroundCoor(coor, ndigits=0): Round the two coordinates of a positiondecimalToDMS(coor): Converts decimal notation to DMS notationDMSToDecimal(coor): Converts DMS notation to decimal notationIf you need more information about these functions, you can use the help functionExamplesfromrandcoorimport*coor=randCoor()print(coor)# (0.5682138386708715, 7.332646594327713)print(roundCoor(coor))# (1.0, 7.0)print(decimalToDMS(coor))# ((0, 34, 5), (7, 19, 57))randCoorByDist((0,0),10,5)# (0.0795066131324715, -0.02793806206797174)randCoorByArea((20,20),(50,50))# (32.66256834620321, 44.82375046671473)randCoorByArea((20,50),(50,20))# (24.12540072542634, 169.03115180655362)L=[randCoorByRule(lambdax,y:x>y)forxinrange(3)]print(L)# [(71.83324744299622, -27.090322185441806), (-31.870493778872586, -167.80562795747355), (17.87985263208857, -162.7185532945298)]calcDist(L)# 20565.48275832477Changelog0.3.0decimalToDMS()andDMSToDecimal()addedThe help function on randcoor itself works properly now0.2.0randCoorByArea()addedSmall changes for the case when longitude = -1800.1.1Small error inrandCoor()fixedroundCoor()added0.1.0First release
Package: randcrack
randcrack – Python random module cracker / predictorThis script is able to predict python'srandommodule random generated values.Script was tested against Python versions from3.5to3.10. Should work against other versions of Python as well, since the generator is pretty much the same in2.7.12. Enjoy!InstallationTo install randcrack, simply:$pipinstallrandcrackHow it worksThe generator is based uponMersenne Twister, which is able to generate numbers with excellent statistical properties(indistinguishable from truly random). However, this generator was not designed to be cryptographycally secure. You should NEVER use in critical applications as a PRNG for your crypto scheme.
You can learn more about this generatoron Wikipedia.This cracker works as the following way. It obtains first 624 32 bit numbers from the generator and obtains the most likely state of Mersenne Twister matrix, which is the internal state. From this point generator should be synchronized with the cracker.How to useIt isimportant to feed cracker exactly 32-bit integersgenerated by the generator due to the fact that they will be generated anyway, but dropped if you don't request for them.
As well, you must feed the cracker exactly after new seed is presented, or after 624*32 bits are generated since every 624 32-bit numbers generator shifts it's state and cracker is designed to be fed from the begining of some state.Implemented methodsCracker has one method for feeding:submit(n). After submitting 624 integers it won't take any more and will be ready for predicting new numbers.Cracker can predict new numbers with following methods, which work exactly the same as their siblings from therandommodule but withoutpredict_prefix. These are:predict_getrandbits,predict_randbelow,predict_randrange,predict_randint,predict_choiceandpredict_randomHere's an example usage:importrandom,timefromrandcrackimportRandCrackrandom.seed(time.time())rc=RandCrack()foriinrange(624):rc.submit(random.getrandbits(32))# Could be filled with random.randint(0,4294967294) or random.randrange(0,4294967294)print("Random result:{}\nCracker result:{}".format(random.randrange(0,4294967295),rc.predict_randrange(0,4294967295)))OutputRandom result: 127160928
Cracker result: 127160928
Package: randdate
|PyPI version| |randdate| |Total alerts| |Language grade: Python|
|deepcode|randdateGenerate a list of random dates (datetime objects).InstallationTheranddategit repo <http://github.com/kmedian/randdate>__ is
available asPyPi package <https://pypi.org/project/randdate>__::pip install randdateUsageCheck theexamples <examples>__ folder for notebooks.CommandsCheck syntax:flake8 --ignore=F401Remove.pycfiles:find . -type f -name "*.pyc" | xargs rmRemove__pycache__folders:find . -type d -name "__pycache__" | xargs rm -rfPublish.. code:: shpandoc README.md --from markdown --to rst -s -o README.rst
python setup.py sdist
twine upload -r pypi dist/*SupportPleaseopen an issue <https://github.com/kmedian/randdate/issues/new>__ for support.ContributingPlease contribute usingGithub Flow <https://guides.github.com/introduction/flow/>. Create a branch,
add commits, andopen a pull request <https://github.com/kmedian/randdate/compare/>... |PyPI version| image::https://badge.fury.io/py/randdate.svg:target:https://badge.fury.io/py/randdate.. |randdate| image::https://snyk.io/advisor/python/randdate/badge.svg:target:https://snyk.io/advisor/python/randdate.. |Total alerts| image::https://img.shields.io/lgtm/alerts/g/kmedian/randdate.svg?logo=lgtm&logoWidth=18:target:https://lgtm.com/projects/g/kmedian/randdate/alerts/.. |Language grade: Python| image::https://img.shields.io/lgtm/grade/python/g/kmedian/randdate.svg?logo=lgtm&logoWidth=18:target:https://lgtm.com/projects/g/kmedian/randdate/context:python.. |deepcode| image::https://www.deepcode.ai/api/gh/badge?key=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJwbGF0Zm9ybTEiOiJnaCIsIm93bmVyMSI6ImttZWRpYW4iLCJyZXBvMSI6InJhbmRkYXRlIiwiaW5jbHVkZUxpbnQiOmZhbHNlLCJhdXRob3JJZCI6Mjk0NTIsImlhdCI6MTYxOTU0MDM0N30.mqU-JDLOg9XOiZ0xoxHVsWFmm9sPiYnBGg49okrZzi8:target:https://www.deepcode.ai/app/gh/kmedian/randdate/_/dashboard?utm_content=gh%2Fkmedian%2Franddate
Package: randen
Randenis a minimal utility module for generating Pandas dataframes
It exposes a handful of methods to quickly generate big random dataframes.How to InstallRanden can be installed as like any other python module, via pippip install randenBasic UsageWithin the python script:from randen import DataFrameGenerator
dfg = DataFrameGenerator()
data_frame = dfg.get_dataframe(...)MotivationRecently, while benchmarking Pandas binary file format I/O for a project, I needed to
generate multiple big dataframes. Hence, publishing this utility as a package to reduce redundant ad-hoc workIf you need some enhancements in the package, feel free to raise a Pull request or drop
a note tovarskann993@gmail.comIf this isn’t what you need at all,
enjoy a trip to the originalRanden.
Package: randenc
The randenc package provides simple symmetric message encryption and
decryption functions with message packing, compression, cryptographic
hashes, and automatically rotated random keys.  It is designed for
short messages such as user ID tokens and browser cookies.  Usage
example:>>> from randenc import RandomEncryption
>>> import tempfile
>>> enc = RandomEncryption(tempfile.mkdtemp())
>>> code = enc.encrypt({u'message': u'Hello, world!'})
>>> len(code)
107
>>> enc.decrypt(code)
{u'message': u'Hello, world!'}The encryption key and signing key are produced automatically (using
os.urandom) and stored in the key directory.  Each key will be deleted
after one hour by default, invalidating all encrypted codes associated
with that key.The encrypt function packs the content using msgpack, compresses it using
zlib (unless the compressed version is larger than than the uncompressed
version), encrypts it using AES-128 (since AES-128 seems to be considered
more secure than AES-256), signs it using HMAC over SHA-256, and encodes
in URL-safe base 64 format.  The decrypt function reverses that operation.
If the code fails validation or has expired, the decrypt function raises
DecryptionError.This package is designed to be compatible with clusters.  The
keys may be stored on a shared volume using NFS or a FUSE-based filesystem.
With a little work, the keys could be stored in a key-value store such
as MongoDB.
Package: rand-engine
# Rand Engine ProjectThis projects has the goal to provide random data to supply Data Engineering LearningIt has to sub modules, batch and streaming. That bring us to the fact that in batch operations it’s possible to create vectorized ways to construct columns, being faster. The random data generation here has the paradigm of receive metadata for columns and so generate a dataframe or a table with ht passed number of rows.On the other hand, streaming data must be based on the line paradigm, and as a line or a message has many files and each of them has a type, it’s a little bit slower, creating a line (message) almost continuously.PS: Sorry about my english below. I will improve this README.md file as soon as possible.# Rand Engine Batch# Rand Engine Streaming
Package: randetect
RandetectRandetectis a Python-based text analysis tool that predicts whether a given string of text appears random or has a meaningful structure. The tool is based on a combination of heuristic measures, such as text entropy, and a pre-trained logistic regression model.FeaturesPredicts randomness of a given text string.Utilizes both heuristic measures and a machine learning model.Provides preprocessing tools to clean and prepare text for analysis.InstallationYou can easily installRandetectusingpip:pipinstallrandetectUsageTo useRandetect, you need to instantiate theTextAnalyzerclass and then call therandom_detect()method to evaluate a text string. Here's how you can do it:fromrandetectimportrandom_detectanalyzer=random_detect.TextAnalyzer()result,label=analyzer.random_detect('asdfasdf')print(f"'{result}' is{label}.")In addition to predicting randomness,Randetectprovides apreprocess_text()method to clean and prepare text:fromrandetectimportrandom_detectanalyzer=random_detect.TextAnalyzer()processed_text=analyzer.preprocess_text('text')print(processed_text)ContributionContributions are welcome! If you find a bug, have a feature request, or want to contribute to the code, please feel free to submit an issue or a pull request on theGitHub repository.LicenseThis project is licensed under the MIT License. See theLICENSE.mdfile for more details.
Package: randf
randfQuickly generate random pandas DataFrames with basic customisation.How to Userandf provides two functions:randec, which generates a random output ofdecimal.Decimalobjects in a
similar manner asnumpy.randomfunctions;randf, which generates a random pandas DataFrame given its shape.>>>fromrandfimportrandf>>>randf(5,3)abc00.7197660.8660840.81329110.8849560.6328480.42394120.9878470.9771580.06250730.4574990.3249800.66164540.0290680.2762540.638651randfprovides additional parameters to spice up these random DataFrames,
such as choosing a different type for the numerical data:>>>df=randf(5,2,ntype='decimal')>>>dfab0874.27800369.911941120.66222411.987842117.29952846.79798>>>df.iloc[0,0]Decimal('874.27800')You can also provide one or more discrete columns randomly populated to go
along with the data:>>>randf(3,3,dcols=['alpha','beta','gaga'])classabc0gaga0.2420800.1079860.5729611beta0.7758230.5108860.9320452beta0.4332140.5040530.911336>>>randf(5,1,dcols={'team':['corinthians','palmares','XVzão'],'cup':['paulista','brasileiro','copa do brasil']})teamcupa0palmarescopadobrasil0.7969301palmarespaulista0.0758912XVzãopaulista0.8297303palmaresbrasileiro0.6416584corinthianspaulista0.245822Changing the order of magnitude of the data is also simple:>>>randf(5,6,ntype='int',order=100000)abcdef0778441653797386174455072457718310329741998085664749798568092610993580295146710428746361583767729238221226887254841485949073685788178824623122231129And if you want to change the default names of the numerical columns, it is
possible to be customised through thenamesparameter:>>>randf(6,3,names=['alpha','beta','gaga'])alphabetagaga00.3988190.1495860.66132310.9512870.0295370.49345620.2877540.9595190.27624430.9956090.9253860.30997040.4914630.2529900.09050650.7480720.1111970.011898LicenceMITCopyright (c) 2021 Manoel Elpidio Pereira de Queiroz Filho.In case you haven't noticed by now, use of British English is the norm for this
project.RULE BRITANNIA
Package: randfacts
Randfacts is a Python module that generates random facts. You can userandfacts.get_fact()to return a random fun fact. Disclaimer: Facts are not guaranteed to be true.Installationrandfacts can either be installed via pip or via the AUR, whichever way you prefer.Installation via pip:$pip3installrandfactsInstallation via AUR:Via your AUR helper, like paru:$paru-Spython-randfactsOr manually$gitclonehttps://aur.archlinux.org/python-randfacts.git&&cdpython-randfacts
$makepkg-siUsage and examplesimportrandfactsx=randfacts.get_fact()print(x)The above example will print a random fact like:Penguins can't taste sweet or savory flavors, only sour and salty onesThis package has a filter option to filter out potentially inappropriate facts. The filter is on by default. To disable the filter, you can just set thefilter_enabledparameter toFalse.fromrandfactsimportget_factprint(get_fact(False))# orprint(get_fact(filter_enabled=False))get_factalso has a parameter that will make the function only return unsafe facts. This argument takes precedence over thefilter_enabledargument. For example:print(get_fact(only_unsafe=True))If you want to access the list of facts directly, you can just import thesafe_facts,unsafe_facts, orall_factslists from the randfacts module.Command line usagerandfacts can be executed via the command line with the following commands:Normal execution; only SFW (safe for work) facts$python3-mrandfactsThe unsafe argument can be supplied to provide only NSFW (not safe for work) facts$python3-mrandfacts--unsafeThe mixed argument can be provided to provide both SFW and NSFW facts.$python3-mrandfacts--mixedMore help.$python3-mrandfacts--help
Package: randfilter
randfilterThis tool reads files or stdin and outputs random lines.randfilter is tested with Python 2.6, 2.7, 3.2, 3.3.RequirementsPython 2.6 / 2.7 / 3.2 / 3.3 or higherdocopt==0.6.1schema==0.2.0InstallationInstall from pypieasy_install randfilterorpip install randfilterInstall from githubgit clone https://github.com/ton1517/randfilter.git
cd randfilter
python setup.py installUsagerandfilter

Usage:
    randfilter (-n <num> | -p <probability>) [-u | --unorder] [-i | --ignore-empty] [<files>...]
    randfilter -h | --help
    randfilter -v | --version

Options:
    <files>...          Choose and output lines at random in files. If omitted, use stdin.
    -n <num>            The choise number of lines.
    -p <probability>    The choise probability of lines. The value is 0.0 to 1.0.
    -u --unorder        Output lines are unordered.
    -i --ignore-empty   Ignore empty line.
    -h --help           Show this screen.
    -v --version        Show version.
Package: randfunc
randfuncA simple and easy to use collection of random python functions.InstallationFrom source (for the latest untested version)pip install git+https://github.com/Cu3t0m/randfunc.gitWith pippip install randfuncExample useCommentary>>> randfunc.commentary("Eat Grass")
'Eat Grass'This will be in grey.Clear>>> randfunc.clear()
''Warn>>> randfunc.string("I like Chicken")
'I like Chicken'This will be in red.Wait>>> randfunc.wait(10)
'10'This happens after 10 secondsClear>>> randfunc.clear()
'iDa7FZl7rW'String>>> randfunc.string(10)
'iDa7FZl7rW'Prascii>>> randfunc.prascii("hello")
 _            _  _        
| |__    ___ | || |  ___  
| '_ \  / _ \| || | / _ \ 
| | | ||  __/| || || (_) |
|_| |_| \___||_||_| \___/Integer>>> randfunc.integer(0, 100)
15Array>>> randfunc.array('123456789', 5)
['7', '5', '9', '3', '2']Datetimedatetime.datetime(2016, 5, 24, 16, 34, 2, 726892)
>>> randfunc.datetime(
... start=datetime.datetime(year=2016, month=1, day=1),
... end=datetime.datetime(year=2016, month=12, day=31))
datetime.datetime(2016, 2, 13, 21, 34, 58, 268978)Mail Address>>> randfunc.mail()
'iYpZpde@jslx4.com'MAC Address>>> randfunc.mac_address()
'fe:23:1d:1d:ec:be'It's also possible to define an own prefix.>>> randfunc.mac_address('02:00:00')
'02:00:00:84:62:3e'

>>> mac_address('02:00:00:00:00')
'02:00:00:00:00:63'IPv4 Address>>> randfunc.ipv4address()
'108.146.211.120'IPv6 Address>>> randfunc.ipv6address()
'7dd7:c3ee:b1b6:ba15:6bb6:c908:541a:efe4'ContributingPull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.Please make sure to update tests as appropriate.LicenseMIT
Package: randgen
py-random-generatorA Random Generator for Multiple ScenariosInstallationpython -m pip install randgenUsagegen_random_int(a: int, b: int) -> int: This function creates a random integer between a and bgen_random_bytes(nbytes: int = None) -> bytes: This function creates a random sequence of bytesgen_random_urlsafe_token(nbytes: int = None) -> str: This function creates a random string that is safe to use in URLsgen_random_single_digit() -> int: This function creates a random single digit between 0 and 9gen_random_true_or_false() -> bool: This function creates a random boolean value
Package: randgen-generator-bsp
randgen-generator-bspBSP random map generator for randgen.io.Free software: MIT licenseDocumentation:https://randgen-generator-bsp.readthedocs.io.FeaturesTODOCreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.1.0 (2016-08-30)First release on PyPI.
Package: randgen-generator-bsp2
randgen-generator-bsp2A BSP random map generator module for randgen.ioFree software: MIT licenseDocumentation:https://randgen-generator-bsp2.readthedocs.io.FeaturesTODOCreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.1.0 (2016-08-30)First release on PyPI.
Package: randgen_maptools
===============================randgen maptools===============================.. image:: https://img.shields.io/pypi/v/randgen_maptools.svg:target: https://pypi.python.org/pypi/randgen_maptools.. image:: https://img.shields.io/travis/lxndrdagreat/randgen_maptools.svg:target: https://travis-ci.org/lxndrdagreat/randgen_maptools.. image:: https://readthedocs.org/projects/randgen-maptools/badge/?version=latest:target: https://randgen-maptools.readthedocs.io/en/latest/?badge=latest:alt: Documentation Status.. image:: https://pyup.io/repos/github/lxndrdagreat/randgen_maptools/shield.svg:target: https://pyup.io/repos/github/lxndrdagreat/randgen_maptools/:alt: UpdatesCore map tools for randgen.io map generators.* Free software: MIT license* Documentation: https://randgen-maptools.readthedocs.io.Features--------* TODOCredits---------This package was created with Cookiecutter_ and the `audreyr/cookiecutter-pypackage`_ project template... _Cookiecutter: https://github.com/audreyr/cookiecutter.. _`audreyr/cookiecutter-pypackage`: https://github.com/audreyr/cookiecutter-pypackage=======History=======0.1.1 (2016-08-30)------------------* Figuring out this whole structure thing. Moving things to the`__init__.py` file.0.1.0 (2016-08-30)------------------* First release on PyPI.
Package: randhy
randhyHypothesis thesting with approximate randomisationApproximate randomisation is a significance testing approach suitable for NLP
problems.🤔 Why not a traditional t-test?While randomisation tests are just as good as analytical approaches such as thet-test, they are better when the assumptions of the latter are not met and
they are also quite simple to implement.🖥️ InstallationpipinstallrandhyReferencesWilliam Morgan, Statistical Hypothesis Tests for NLP - Stanford Computer Science (slides)Wassily Hoeffding. 1952. The Large-Sample Power of Tests Based on Permutations of Observations. Annals ofMathematical Statistics, 23, 169–192.Eric W. Noreen. 1989. Computer Intensive Methods forTesting Hypothesis. John Wiley & Sons