Saravanan666/pypi-org huggingface dataset:
Package: ameise
AMEISE DatasetDev-Kit forProject AMEISErecords:DescriptionThe ameise-dataset is a development kit for the AMEISE dataset. It provides functionalities to unpack AMEISE record
files and extract meta information and frames. The core functionality revolves around handling AMEISE record files
with the .4mse extension.InstallationTo install the ameise-dataset, you can use pip:pip install ameiseGetting StartedTo get started with the dataset, you can refer to theGettingStarted.ipynbnotebook provided in the repository.
This notebook will guide you through the basic functionalities and usage of the dataset.
Package: amendment-forecast
forecast_ensembleforecast_ensemble combines multiple models into a single forecast and returns a combined package of models, their
evaluated results including a composite scoreUsageThe forecast is run usingmain.pywith the following optionsRequest RequirementsThe required input format is a JSON with the following fields:Required:data_filepath: filepath of the time series data to run the ensemble ontarget_column: name of the input columnaggregate_operation: string operation to apply to target_column to create the time seriesoutput_directory: directory to return the result JSON to
Package: amenu
````pythonamenuThis is a menu plugins for DjangoCMS. It provides 4 different kinds of menu plugins.1. Menu Below Current Page2. Breadcrumb3. Generic Menu4. Selective MenuInstallationDownload the package$ pip install amenuRegister it to the INSTALLED_APPSFor standard DjangoCMS project settingINSTALLED_APPS = ('amenu',)For "Djangocms Foundation"[https://github.com/ludbek/djangocms-foundation]DJANGO_CMS_APPS = ('amenu',)Migrate the plugin$ python manage.py migrate amenu````
Package: amenukit
This module is in its infancy and as it’s goals are very ambitious there is no
guarantee that it will survive.  The following are the goals of the project not
a statement of achievement.  At the moment it should be considered ‘vapourware’This module will simplify the specification, creation, and
dynamic manipulation of gui menus. Menus systems written with this module will
work without modification on all supported gui’s.The kit supplies wrappers for four common python gui’s:tkinter    [tkmenukit.py]pygtk      [gtkmenukit.py]pyqt       [qtmenukit.py]wxPython   [wxmenukit.py]Menus are represented by python objects linked together in a tree structure. The
python objects can be inactive, or active.  Active menus are connected to real
menus in the gui and changes made to the python structure will be reflected in
the gui.Menus (and menu fragments) can be built up using normal python methods for
manipulating data structures or from lists of python strings or from data
formats such as XML, jason, yaml etc. Python menu structures, however
constructed, can be converted easily into any of these formats.Porting a menu system from one gui to another, simply involves importing a
different wrapper module. Everything else will work exactly the same.
Package: american-options
American Options LibraryThe Library that is using various methods to price the variety of options of american type.Installationpip install american_optionsGet startedHow to obtain option price with this library:fromamerican_optionsimportOption,Underlying#Set up your parametersn_sims=10000T=1sigma1=0.4sigma2=0.8r=0.06N=255spot1=100spot2=120K1=100K2=110First you need to create assets you want to write options on. You can do this in following way:# Instantiate an Underlying objectasset1=Underlying(spot_price=100,r=0.07)asset2=Underlying(spot_price=120,r=0.07)Next step is to calibrate assets for the use of different models.# Calibrate created assetsasset1.calibrate_GBM(sigma=0.4,values_per_year_GBM=N)asset1.calibrate_JD(sigma=0.4,jump_intensity=1/3)asset2.calibrate_GBM(sigma=0.4,values_per_year_GBM=N)asset2.calibrate_JD(sigma=0.2,jump_intensity=1/2)Now create options, for that we need payoff functions as well. You can import some of them from payoffs module:fromamerican_options.payoffsimport*option1=Option(underlyings=asset1,payoff_func=lambdatrajectory:payoff_creator_1d(trajectory,Call_Payoff,K=100,barrier=True,barrier_level=140),T=1)option2=Option(underlyings=(asset1,asset2),payoff_func=lambdatrajectories:double_max_put(trajectories,100),T=1)And finally obtaining a price!# Pricing with state space partitioning methodoption1.ssp(n_sims=10000,mode='JD')option2.ssp(n_sims=10000,mode='GBM')# pPricing with Longstaff-Schwartz methodoption1.LS(n_sims=10000,mode='JD')option2.ssp(n_sims=10000,mode='GBM')
Package: amerikana
☕ amerikana:kerasprediction decoder forimagenet-simple-labelsa simpler, more human readable imagenet synset for keras.comparison:IDImageNetKerasSimple (this repo)87African grey, African gray, Psittacus erithacusAfrican_greygrey parrot97drakedrakeduck913wreckwreckshipwreck930French loafFrench_loafbaguettequickstart:should be used as a drop in replacement fortf.keras.applications.imagenet_utils.decode_predictionsinstall with pip:pip install amerikanaimport:from amerikana import decode_predictionsinstead of:from tensorflow.keras.applications.imagenet_utils import decode_predictionsexample use:predictions = model.predict(processed_image)
labels = decode_predictions(predictions)
print(labels)credit:simplified labels list:imagenet-simple-labels. see information and comparison for simplified labels there.the module code used in this project is a derivative of tf.kerasimagenet_utils.enjoy!
Package: ameritrade-python
ameritrade-pythonThis is a simple and lightweight async api wrapper for Ameritrade's API.The official docs for the Ameritrade API can be foundhere.The first time authentication will require utilizing the callback URL/redirect URI to obtain your tokens.
This package will generate an auth url to enter into a web browser, you can then paste the resulting url from the
redirect url in order to obtain a pair of tokens.fromosimportenvironfromameritradeimportauthtest_redirect_uri=environ.get("callback_url")consumer_key=environ.get("consumer_key")test_auth=auth.Auth(redirect_uri=test_redirect_uri,consumer_key=consumer_key)defmain():"""Sets the access and refresh tokens by following terminal prompts."""awaittest_auth.manual_auth()Simple usage using an existing refresh token:importasynciofromosimportenvironfromameritradeimportauth,stocktest_redirect_uri=environ.get("callback_url")consumer_key=environ.get("consumer_key")refresh_token=environ.get("refresh_token")test_auth=auth.Auth(redirect_uri=test_redirect_uri,consumer_key=consumer_key,refresh_token=refresh_token)asyncdefmain():"""Gets new tokens, then gets a single stock quote for 'KO'/coca-cola."""awaittest_auth.refresh_token_auth()# Gets fresh tokenstest_stock=stock.Stock(auth_class=test_auth,symbol="ko")# creates stock object for KOawaittest_stock.get_quote()# Makes the quote requestprint(test_stock.quote)loop=asyncio.get_event_loop()# Creates the event looploop.run_until_complete(main())# Runs the event loopEnvironmentI suggest utilizing a .env file to store private/sensitive information.If you are not providing a refresh token, it is recommended that you use auth.Auth.manual_auth() in order to use
Ameritrade's front end auth tools, you can follow the on-screen instructions for this.You may choose to save your refresh token in a secure location/format, if using a previous refresh token, you only
need to provide these to your auth class:consumer_keyrefresh_tokenDevelopemntInstall dependencies with poetrypoetry install.Building Locallypoetry build
Package: amersham
AmershamAmersham:The name of a London Underground station which alliterates with "argument parser"MotivationEvery CLI application wants two things:Sanitized user inputDescriptive usage and help messagesAmersham implements both with minimal boilerplate.Quick StartInstallpip3 install amershamImportimportsysfromamershamimportParserCreate a parser and commandparser=Parser("app")@parser.command()defcommand(parameter,flag=None):passRun the parserif__name__=="__main__":parser.run(sys.argv[1:])Run your programuser:~$ python3 app.py --help
usage
  app.py [--help] [--flag] PARAMETER

flags
  --help  -h  displays this message
  --flag

parameters
  PARAMETER  stringAdvanced UsageMore Descriptive Help MessagesAdd some context to our command and argumentsoverrides={"description":"a command","parameter":{"description":"a parameter",},"flag":{"description":"a flag","alias":"f",}}@parser.command(**overrides)defcommand(parameter,flag=""):passAnd see the resultsuser:~$ python3 app.py --help
usage
  app.py [--help] [--flag] PARAMETER

description
  a command

flags
  --help  -h          displays this message
  --flag      string  a flag

parameters
  PARAMETER  string  a parameter
Package: amey-ml
amey_mlOverviewamey_ml is a versatile Python machine learning package providing a range of algorithms for different kinds of data processing and machine learning tasks. It includes implementations of popular algorithms such as Naive Bayes, Linear Regression, Neural Networks using Keras, Decision Trees, K-Nearest Neighbors, and K-Means Clustering. This package is designed to be user-friendly, efficient, and easily integrable into data analysis pipelines.InstallationTo install amey_ml, simply run the following command:pipinstallamey_mlFeaturesamey_ml includes the following modules and functions:Naive Bayes (naive_bayes.py)output(training_file, test_file): Perform Naive Bayes classification.Linear Regression (linear_regression.py)output(training_file, test_file, degree, lambda1): Perform regularized linear regression.Neural Networks with Keras (nn_keras.py)output(directory, dataset, layers, units_per_layer, epochs): Train and evaluate neural network models.Decision Trees (decision_tree.py)output(train_path, test_path, model_type, threshold): Train decision trees or random forests.K-Nearest Neighbors (knn_classify.py)output(training_file, test_file, k): Implement K-nearest neighbors classification.K-Means Clustering (k_means.py)output(data_file, K, initialization): Perform K-means clustering on a dataset.Each function is designed to be straightforward to use, requiring only the necessary parameters for each specific algorithm.Installing this package will install scikit-learn, tensorflow, pandas, scikit-learn, and keras by default.UsageTo use amey_ml, first import the required function from the package and then call it with the necessary parameters. Here are some example usages:fromamey_mlimportnaive_bayes,linear_regression,nn_kerasfromamey_mlimportdecision_tree,knn_classify,k_means# Naive Bayesnaive_bayes.output('training_data.csv','test_data.csv')# Linear Regressionlinear_regression.output('train.csv','test.csv',2,0.01)# Neural Networks using Kerasnn_keras.output('data_directory/','dataset_name',3,64,10)# Decision Treesdecision_tree.output('train_data.csv','test_data.csv','optimized',0.05)# K-Nearest Neighborsknn_classify.output('train.csv','test.csv',5)# K-Means Clusteringk_means.output('data.csv',3,'random')DocumentationEach function in the amey_ml package comes with detailed docstrings explaining the functionality,parameters, and return types. For more detailed documentation, refer to the docstrings within each function.ContributingContributions to amey_ml are welcome! If you'd like to contribute, please contact me atamey.shinde@bizzencecollab.com. Please fork the repository and use afeature branch. Pull requests are warmly welcome.LicensingThe code in this project is licensed under MIT license.GitHubhttps://github.com/Pistonamey/amey_ml/
Package: amfiprot-amfitrack
AmfiTrack extensions for theAmfiprotpackage.InstallationInstall (or update) withpip:pipinstall-Uamfiprot-amfitrackUsage exampleInstead of creating a genericamfiprot.Device, create anamfitrack.Deviceto get access to AmfiTrack specific functionality and payload interpretation:importamfiprotimportamfiprot_amfitrackasamfitrackVENDOR_ID=0xC17PRODUCT_ID_SENSOR=0xD12PRODUCT_ID_SOURCE=0xD01if__name__=="__main__":conn=Nonetry:conn=amfiprot.USBConnection(VENDOR_ID,PRODUCT_ID_SENSOR)except:try:conn=amfiprot.USBConnection(VENDOR_ID,PRODUCT_ID_SOURCE)except:print("No Amfitrack device found")exit()nodes=conn.find_nodes()print(f"Found{len(nodes)}node(s).")fornodeinnodes:print(f"[{node.tx_id}]{node.name}")dev=amfitrack.Device(nodes[0])conn.start()cfg=dev.config.read_all()dev.calibrate()whileTrue:ifdev.packet_available():packet=dev.get_packet()iftype(packet.payload)==amfitrack.payload.EmfImuFrameIdPayload:payload:amfitrack.payload.EmfImuFrameIdPayload=packet.payloadprint(payload.emf)else:print(packet)
Package: amfpy
# amfpyamfpy provides Action Message Format(AMF) support for python3.### AMF SpecificationAMF 0 Specification: [pdf](http://wwwimages.adobe.com/content/dam/Adobe/en/devnet/amf/pdf/amf0-file-format-specification.pdf)AMF 3 Specification: [pdf](http://wwwimages.adobe.com/content/dam/Adobe/en/devnet/amf/pdf/amf-file-format-spec.pdf)
Package: amf-rotary-valve
amf-rotary-valveThis Python package provides control ofAMF rotary valves.Installation$pipinstallamf-rotary-valve# List available devices$python-mamf_rotary_valveUsagefromamf_rotary_valveimportAMFDevicedevice=AMFDevice(address="COM3")device=AMFDevice(address="/dev/tty.usbmodem1101")asyncwithdevice:awaitdevice.home()valve_count=awaitdevice.get_valve_count()current_valve=awaitdevice.get_valve()# Rotate to the next valveawaitdevice.rotate(current_valve%valve_count+1)forinfoinAMFDevice.list():asyncwithinfo.create()asdevice:print(awaitdevice.get_unique_id())
Package: amg-player
Angry Metal Guy PlayerAngry Metal Guy Player (AMG Player) is a Python multi platform console tool to automatically play or download tracks fromAngry Metal Guyreviews.I created this because:I like Angry Metal Guy, and discovered great music (both metal and totally non-metal) thanks to their reviewsI often disagree with their ratings (in fact I disagree more often than I agree), both for overrating and underratingEven when I disagree, I like reading their reviewsI want to listen to the musicbeforeI read the review, to avoid getting influencedTo be efficient, I want to listen to the tracks like a radio, and read the review to learn more only when I like somethingFeaturesCan work either in interactive mode (manually select tracks) or totally automatic (play new tracks like a radio)Supports embedded tracks from: YouTube, Bandcamp, SoundCloud, ReverbNationPlays YouTube video if available, or generates a video on the fly with the cover image + audio track(s) (requires FFmpeg)Can download tracks (with embedded album art) to play laterScreenshotsSelection screen:Playing a track:InstallationAngry Metal Guy Player requiresPython>= 3.7.
Some features are only available ifFFmpeg>= 2.8 is installed.From PyPI (with PIP)If you don't already have it,install pipfor Python 3Install Angry Metal Guy Player:pip3 install amg-playerFrom sourceIf you don't already have it,install setuptoolsfor Python 3Clone this repository:git clone https://github.com/desbma/amg-playerInstall Angry Metal Guy Player:python3 setup.py installAngry Metal Guy Player only supportsMPV playerfor now.Command line usageRunamg -hto get full command line reference.ExamplesBrowse and play interactively last 50 reviews:amg -c 50Choose the first track to play, then play all tracks in chronological order:amg -m radioPlay last 20 tracks in chronological order, skipping those already played:amg -c 20 -m discoverLicenseGPLv3
Package: amharic-keyboard
Amharic-keyboardThis is a simple python package that lets you type Amharic letters using Latin alphabet.It will analyze the given Latin text for consonants + vowels and converts those words in to the equaivalent of Amharic words.It follws the same pattern used for typing Amharic words when texting.Installation:pip install amharic-keyboardor simply grab keyboard.py and import that.usageimport amharic_keyboard as ak

print(ak.type("selam nachihu?"))  

#prints:
     ሰላም ናችሁ?
Package: ami2py
ami2pyPython Package for reading and writing from and to an amibroker database.This package is using construct for defining the binary structures used to access the amibroker database,
seeConstruct documentation.The specification of the binary structure was taken from the official amibroker C++ sdk api documentation.However, this is not an official amibroker database api.Therefore, no warranty is given and handle with care.Improvement requests are always welcome.This module can be used to create a database and write symbol data to that.However, it seems to be a good idea to use the official quote downloader program for productive usage.ExamplesCreating a Database from scratch and adding symbol data to the database.
To use the underlying constructs in compiled form, use_compiled can be set to True within theAmiDataBase constructor. This is a more or less experimental feature.>>> from ami2py import AmiDataBase, SymbolEntry
>>> db = AmiDataBase(db_folder)
>>> db.add_symbol("AAPL")    
>>> db.append_data_to_symbol(
        "AAPL",
        SymbolEntry(
            Close=200.0,
            High=230.0,
            Low=190.0,
            Open=210.0,
            Volume=200003122.0,
            Month=12,
            Year=2020,
            Day=17,
        ),
    )
>>> db.write_database()Reading a list of symbols contained in the database.>>> symbols = db.get_symbols()
>>> symbols
["AAPL"]Getting values for a symbol in a pandas compatible dicitonary format.>>> db.get_dict_for_symbol("SPCE")
{
    "Open": [20.0,....],
    "Close": [200.0,....],
    "High": [230.0,.....],
    "Low": [190.0,.....],
    "Open": [210.0,.......],
    "Volume": [200003122.0,.....],
    "Month": [12,.......],
    "Year": [2020,.......],
    "Day": [17,........],
}Using a list container facade for fast reading of symbol data.
The previous mentioned methods to read symbol data from the database use construct to
convert the binary array into a hierarchical object structure.
Creating those objects during the load process, causes high delay during loading.
Therefore a symbol facade called AmiSymbolDataFacade was created to read data only in case
it is necessary.>>> data = db.get_fast_symbol_data("SPCE")
 >>> data[0]
 {'Year': 2017, 
  'Month': 9, 
  'Day': 29, 
  'Hour': 10, 
  'Minute': 63, 
  'Second': 63, 
  'MilliSec': 258, 
  'MicroSec': 255, 
  'Reserved': 1,  
  'Isfut': 1,  
  'Close': 10.100000381469727, 
  'Open': 10.5, 
  'High': 10.5, 
  'Low': 10.0, 
  'Volume': 212769.0, 
  'AUX1': 0.0, 
  'AUX2': 0.0,  
  'TERMINATOR': 0.0
 }
 >>> newslice=data[0:10] 
 >>> newslice[0]
 {'Year': 2017,
  'Month': 9,
  ......
 }
 >>> newslice[1]
 {'Year': 2017,
  'Month': 10,
   ......
 }TodosWrite tests for intraday data, currently data structures is able to handle intraday data.
But no tests had been written, until now.
This is considered mandatory to reach version 1.0.0Add docstrings to the source code. This seems to be a minor task.
Package: ami2rabbitmq
AMI2RabbitMQOverviewIs a consumer of events produced by the Asterisk Manager Interface, where it organizes endpoints, bridges and queues into entities, persisting the last state on a redis server and producing an event for a queue on a RabbitMQ server.The generated data is persisted on the Redis Server with keys starting with the prefixOnline:< SUFIX >.DependenciesIt is necessary to have Redis, RabbitMQ, Asterisk installed and configured to use the lib.Installing AMI2RabbitMQ and Supported VersionsAMI2RabbitMQ is available on PyPI:$ python -m pip install ami2rabbitmqAMI2RabbitMQ officially supports Python 3.8+.Cloning the repositoryhttps://github.com/tatianno/ami2rabbitmq.gitExamplesSimple producer applicationfrom ami2rabbitmq import AMI2RabbitMQ


AMI_SETTINGS = {
    'host' : 'localhost',
    'user' : 'user',
    'password' : 'password'
}

RABBITMQ_SETTINGS = RABBITMQ_SETTINGS = {
    'host' : 'localhost',
    'user' : 'user',
    'password' : 'password',
    'queuename' : 'online'
}

producer = AMI2RabbitMQ(
    ami_settings = AMI_SETTINGS,
    rabbitmq_settings = RABBITMQ_SETTINGS,
)

producer.run()Advanced producer applicationfrom ami2rabbitmq import AMI2RabbitMQ


AMI_SETTINGS = {
    'host' : 'localhost',
    'user' : 'user',
    'password' : 'password'
}

RABBITMQ_SETTINGS = RABBITMQ_SETTINGS = {
    'host' : 'localhost',
    'user' : 'user',
    'password' : 'password',
    'queuename' : 'online'
}


class CustomProducerApp(AMI2RabbitMQ):

    def update_events(self):
        '''
        The change_entities variable receives a list containing the entities that received state change events.

        Entities can be of the type:

        - Bridge : Call established between two endpoints
        - QueueCaller : Call waiting in a queue
        - Endpoint : Can be an extension or trunk
        - QueueMember : Member of a queue
        - Queue : Service queue

        Entities are available for import:

        import from ami2rabbitmq.entities import Bridge, Endpoint, QueueCaller, QueueMember, Queue
        '''
        change_entities = self._pabx.update(self.last_events)
        self._send_change_to_broker(change_entities)


custom_producer = CustomProducerApp(
    ami_settings = AMI_SETTINGS,
    rabbitmq_settings = RABBITMQ_SETTINGS,
)

custom_producer.run()
Package: amiami
Amiami APIA simple api wrapper around the amiami site.Simple usage can be something likeimportamiamiresults=amiami.search("fumofumo plush")foriteminresults.items:print("{},{}".format(item.productName,item.availability))Sometimes items tend to result in an unknown status because the flag -> state parsing is a bit rough. These items will be added to the list with a status ofUnknown status?. They will also print out a message with the flags and item code. Good to check your log and see what's going on.
Package: amical
(ApertureMaskingInterferometryCalibration andAnalysisLibrary)Installation$python3-mpipinstallamicalWhat can AMICAL do for you ?AMICAL is developed to provide an easy-to-use solution to processApertureMaskingInterferometry (AMI) data from major existing
facilities:NIRISSon the JWST (first scientific interferometer operating in space),SPHEREandVISIRfrom
the European Very Large Telescope (VLT) andVAMPIRESfrom SUBARU telescope (and more to come).We focused our efforts to propose a user-friendly interface, though different
sub-classes allowing to (1)Cleanthe reduced datacube from the standard
instrument pipelines, (2)Extractthe interferometrical quantities
(visibilities and closure phases) using a Fourier sampling approach and (3)Calibratethose quantities to remove the instrumental biases.In addition (4), we include two external packages calledCANDIDandPymasktoanalysethe final
outputs obtained from a binary-like sources (star-star or star-planet). We
interfaced these stand-alone packages with AMICAL to quickly estimate our
scientific results (e.g., separation, position angle, contrast ratio, contrast
limits, etc.) using different approaches (chi2 grid, MCMC, seeexample_analysis.pyfor details).Getting startedLooking for a quickstart into AMICAL? You can go through ourtutorialexplaining
how to use its different features.You can also have a look to the example scripts
made forNIRISSandSPHEREor get details about the CANDID/Pymask uses withexample_analysis.py.⚡ Last updates (08/2022) : New example script for IFS-SPHERE data is now availablehere.Use policy and reference publicationIf you use AMICAL in a publication, we encourage you to properly cite the
reference paper published during the 2020 SPIE conference:The James Webb Space
Telescope aperture masking
interferometer.
The library explanation is part of a broader description of the interferometric
mode of NIRISS, so feel free to have a look at the exciting possibilities of
AMI!AcknowledgementsThis work is mainly a modern Python translation of the very well known (and old)
IDL pipeline used to process and analyze Sparse Aperture Masking data. This
pipeline, called "Sydney code", was developed by a lot of people over many
years. Credit goes to the major developers, including Peter Tuthill, Mike
Ireland and John Monnier. Many forks exist across the web and the last IDL
version can be foundhere.