# packages

pkgId: df475ed2708f42a211da19c4e0de3f3c99c3b913084aa71f060cdb436f294be5
name: python-amazon-paapi5
arch: src
version: 1.1.2
epoch: 0
release: 1
summary: Amazon Product Advertising API 5.0 wrapper for Python
url: https://github.com/alefiori82/amazon-paapi5
rpm_license: GPL-3.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-paapi5-1.1.2-1.src.rpm
checksum_type: sha256
description:
  A simple Python wrapper for the last version of the Amazon Product Advertising API. This module allows to get product information from Amazon using the official API in an easier way.
  Like Bottlenose you can use cache reader and writer to limit the number of api calls.
  [![PyPI](https://img.shields.io/pypi/v/amazon-paapi5)](https://pypi.org/project/amazon-paapi5/)
  [![Python](https://img.shields.io/github/pipenv/locked/python-version/alefiori82/amazon-paapi5/master?label=python)](https://www.python.org/)
  [![License](https://img.shields.io/badge/License-GPL--3.0-%23e83633)](https://github.com/alefiori82/amazon-paapi5/blob/master/LICENSE)
  [![Support](https://img.shields.io/badge/Support-Good-brightgreen)](https://github.com/alefiori82/amazon-paapi5/issues)
  [![Amazon API](https://img.shields.io/badge/Amazon%20API-5.0-%23FD9B15)](https://webservices.amazon.com/paapi5/documentation/)
  ![](https://github.com/alefiori82/amazon-paapi5/workflows/Upload%20Python%20Package/badge.svg)
  ![](https://github.com/alefiori82/amazon-paapi5/workflows/Build%20package/badge.svg)
  ![PyPI - Wheel](https://img.shields.io/pypi/wheel/amazon-paapi5)
  [![Documentation Status](https://readthedocs.org/projects/amazon-paapi5/badge/?version=latest)](https://amazon-paapi5.readthedocs.io/en/latest/?badge=latest)


pkgId: 274ac110b7df524e0e7be5e52a0fd3c569e625e21fac8d5508ac160e653b713b
name: python-amazon-photos
arch: src
version: 0.0.97
epoch: 0
release: 1
summary: Amazon Photos API
url: https://github.com/trevorhobenshield/amazon_photos
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-photos-0.0.97-1.src.rpm
checksum_type: sha256
description:
  <!-- TOC -->

  * [Installation](#installation)
  * [Setup](#setup)
  * [Examples](#examples)
  * [Search](#search)
  * [Nodes](#nodes)
      * [Restrictions](#restrictions)
      * [Range Queries](#range-queries)
  * [Notes](#notes)
      * [Known File Types](#known-file-types)
  * [Custom Image Labeling (Optional)](#custom-image-labeling-optional)

  <!-- TOC -->

  > It is recommended to use this API in a [Jupyter Notebook](https://jupyter.org/install), as the results from most
  > endpoints
  > are a [DataFrame](https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.html#pandas.DataFrame)
  > which can be neatly displayed and efficiently manipulated with vectorized ops. This becomes
  > increasingly important if you have "large" amounts of data (e.g. >1 million photos/videos).



  ```bash
  pip install amazon-photos -U
  ```



  `ap.db`

  |   | dateTimeDigitized        | id                     | name              | ... | model             | apertureValue | focalLength | width | height |   size |
  |--:|:-------------------------|:-----------------------|:------------------|:----|:------------------|:--------------|:------------|------:|-------:|-------:|
  | 0 | 2019-07-06T18:22:00.000Z | HeMReF-vvJiTTkdPIeWuoP | 1694252973839.png | ... | iPhone XS         | 54823/32325   | 17/4        |  3024 |   4032 | 432777 |
  | 1 | 2023-01-18T09:36:22.000Z | z_HiIvASAKqWmdrkjWiqMZ | 1692626817154.jpg | ... | iPhone XS         | 54823/32325   | 17/4        |  3024 |   4032 | 234257 |
  | 2 | 2022-08-14T14:13:21.000Z | LKXEZbqoVrhrOYBezisGEQ | 1798219686789.jpg | ... | iPhone 11 Pro Max | 54823/32325   | 17/4        |  3024 |   4032 | 423987 |
  | 3 | 2020-06-28T19:32:30.000Z | EPUeciHtfKkGiYkfUyEuMa | 1593482220567.jpg | ... | iPhone XS         | 54823/32325   | 17/4        |  3024 |   4032 | 898957 |
  | 4 | 2021-07-07T17:12:55.000Z | fdfKzRJbEyoVeGcfCoJgE- | 1592299282720.png | ... | iPhone XR         | 54823/32325   | 17/4        |  3024 |   4032 | 432556 |
  | 5 | 2021-08-18T18:32:41.000Z | crskJSmKPFRhxbpfkivyLm | 1592902159105.png | ... | iPhone XR         | 54823/32325   | 17/4        |  3024 |   4032 | 123123 |
  | 6 | 2023-08-23T19:12:21.000Z | qkBFUlyIdkUwVVSaVWWKEF | 1598138358650.png | ... | iPhone 11         | 54823/32325   | 17/4        |  3024 |   4032 | 437887 |
  | 7 | 2021-06-19T17:14:13.000Z | TXKMKC-mHvSUrtRfwmtyDe | 1622199863606.jpg | ... | iPhone 12 Pro     | 14447/10653   | 21/5        |  1536 |   2048 | 758432 |
  | 8 | 2023-02-15T22:45:40.000Z | FRDvvjcZdpFWiwrIZfTNHO | 1581874518054.jpg | ... | iPhone 8 Plus     | 54823/32325   | 399/100     |  1348 |   2049 | 862883 |

  `ap.print_tree()`

  ```text
  ~
  ├── Documents
  ├── Pictures
  │   ├── iPhone
  │   └── Web
  │       ├── foo
  │       └── bar
  ├── Videos
  └── Backup
      ├── LAPTOP-XYZ
      │   └── Desktop
      └── DESKTOP-IJK
          └── Desktop
  ```



  > [Update] Jan 04 2024: To avoid confusion, setting env vars is no longer supported. One must pass cookies directly as
  > shown below.

  Log in to Amazon Photos and copy the following cookies:

  - `session-id`
  - `ubid`*
  - `at`*



  where `xx` is the TLD (top-level domain)

  - `ubid-acbxx`
  - `at-acbxx`



  - `ubid_main`
  - `at_main`

  E.g.

  ```python
  from amazon_photos import AmazonPhotos

  ap = AmazonPhotos(
      
      
      
      
      
      

      
      
      
      
      
      

      
      
      
      
      
      
  )
  ```



  > A database named `ap.parquet` will be created during the initial setup. This is mainly used to reduce upload conflicts
  > by checking your local file(s) md5 against the database before sending the request.

  ```python
  from amazon_photos import AmazonPhotos

  ap = AmazonPhotos(
      
      cookies={...},
      
      tmp='tmp',
      
      dtype_backend='pyarrow',
      engine='pyarrow',
  )


  ap.usage()


  nodes = ap.query("type:(PHOTOS OR VIDEOS)")


  nodes = ap.query("type:(PHOTOS OR VIDEOS) AND things:(plant AND beach OR moon) AND timeYear:(2023) AND timeMonth:(8) AND timeDay:(14) AND location:(CAN#BC#Vancouver)")


  node_ids = nodes.id[:10]


  ap.trash(node_ids)


  ap.trashed()


  ap.delete(node_ids)


  ap.restore(node_ids)


  ap.upload('path/to/files')


  ap.download(node_ids)


  ap.photos()


  ap.videos()


  ap.aggregations(category="all")


  ap.aggregations(category="location")
  ```



  *Undocumented API, current endpoints valid Dec 2023.*

  For valid **location** and **people** IDs, see the results from the `aggregations()` method.

  | name            | type | description                                                                                                                                                                                                                                               |
  |:----------------|:-----|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
  | ContentType     | str  | `"JSON"`                                                                                                                                                                                                                                                  |
  | _               | int  | `1690059771064`                                                                                                                                                                                                                                           |
  | asset           | str  | `"ALL"`<br/>`"MOBILE"`<br/>`"NONE`<br/>`"DESKTOP"`<br/><br/>default: `"ALL"`                                                                                                                                                                              |
  | filters         | str  | `"type:(PHOTOS OR VIDEOS) AND things:(plant AND beach OR moon) AND timeYear:(2019) AND timeMonth:(7) AND location:(CAN#BC#Vancouver) AND people:(CyChdySYdfj7DHsjdSHdy)"`<br/><br/>default: `"type:(PHOTOS OR VIDEOS)"`                                   |
  | groupByForTime  | str  | `"day"`<br/>`"month"`<br/>`"year"`                                                                                                                                                                                                                        |
  | limit           | int  | `200`                                                                                                                                                                                                                                                     |
  | lowResThumbnail | str  | `"true"`<br/>`"false"`<br/><br/>default: `"true"`                                                                                                                                                                                                         |
  | resourceVersion | str  | `"V2"`                                                                                                                                                                                                                                                    |
  | searchContext   | str  | `"customer"`<br/>`"all"`<br/>`"unknown"`<br/>`"family"`<br/>`"groups"`<br/><br/>default: `"customer"`                                                                                                                                                     |
  | sort            | str  | `"['contentProperties.contentDate DESC']"`<br/>`"['contentProperties.contentDate ASC']"`<br/>`"['createdDate DESC']"`<br/>`"['createdDate ASC']"`<br/>`"['name DESC']"`<br/>`"['name ASC']"`<br/><br/>default: `"['contentProperties.contentDate DESC']"` |
  | tempLink        | str  | `"false"`<br/>`"true"`<br/><br/>default: `"false"`                                                                                                                                                                                                        |             |



  *Docs last updated in 2015*

  | FieldName                     | FieldType                | Sort Allowed | Notes                                                                                                                                                                                                                                       |
  |-------------------------------|--------------------------|--------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
  | isRoot                        | Boolean                  |              | Only lower case `"true"` is supported.                                                                                                                                                                                                      |
  | name                          | String                   | Yes          | This field does an exact match on the name and prefix query. Consider `node1{ "name" : "sample" }` `node2 { "name" : "sample1" }` Query filter<br>`name:sample` will return node1<br>`name:sample*` will return node1 and node2             |
  | kind                          | String                   | Yes          | To search for all the nodes which contains kind as FILE `kind:FILE`                                                                                                                                                                         |
  | modifiedDate                  | Date (in ISO8601 Format) | Yes          | To Search for all the nodes which has modified from time `modifiedDate:{"2014-12-31T23:59:59.000Z" TO *]`                                                                                                                                   |
  | createdDate                   | Date (in ISO8601 Format) | Yes          | To Search for all the nodes created on  `createdDate:2014-12-31T23:59:59.000Z`                                                                                                                                                              |
  | labels                        | String Array             |              | Only Equality can be tested with arrays.<br>if labels contains `["name", "test", "sample"]`.<br>Label can be searched for name or combination of values.<br>To get all the labels which contain name and test<br>`labels: (name AND test)`  |
  | description                   | String                   |              | To Search all the nodes for description with value 'test'<br>`description:test`                                                                                                                                                             |
  | parents                       | String Array             |              | Only Equality can be tested with arrays.<br>if parents contains `["id1", "id2", "id3"]`.<br>Parent can be searched for name or combination of values.<br>To get all the parents which contains id1 and id2<br>`parents:id1 AND parents:id2` |
  | status                        | String                   | Yes          | For searching nodes with AVAILABLE status.<br>`status:AVAILABLE`                                                                                                                                                                            |
  | contentProperties.size        | Long                     | Yes          |                                                                                                                                                                                                                                             |
  | contentProperties.contentType | String                   | Yes          | If prefix query, only the major content-type (e.g. `image*`, `video*`, etc.) is supported as a prefix.                                                                                                                                      |
  | contentProperties.md5         | String                   |              |                                                                                                                                                                                                                                             |
  | contentProperties.contentDate | Date (in ISO8601 Format) | Yes          | RangeQueries and equals queries can be used with this field                                                                                                                                                                                 |
  | contentProperties.extension   | String                   | Yes          |                                                                                                                                                                                                                                             |



  > Max # of Filter Parameters Allowed is 8

  | Filter Type | Filters                                                                               |
  |:------------|:--------------------------------------------------------------------------------------|
  | Equality    | createdDate, description, isRoot, kind, labels, modifiedDate, name, parentIds, status |
  | Range       | contentProperties.contentDate, createdDate, modifiedDate                              |
  | Prefix      | contentProperties.contentType, name                                                   |



  | Operation            | Syntax                                                           |
  |----------------------|------------------------------------------------------------------|
  | GreaterThan          | `{"valueToBeTested" TO *}`                                       |
  | GreaterThan or Equal | `["ValueToBeTested" TO *]`                                       |
  | LessThan             | `{* TO "ValueToBeTested"}`                                       |
  | LessThan or Equal    | `{* TO "ValueToBeTested"]`                                       |
  | Between              | `["ValueToBeTested_LowerBound" TO "ValueToBeTested_UpperBound"]` |





  - This endpoint is called when downloading a batch of photos/videos in the web interface. It then returns a URL to
    download a zip file, then makes a request to that url to download the content.
    When making a request to download data for 1200 nodes (max batch size), it turns out to be much slower (~2.5 minutes)
    than asynchronously downloading 1200 photos/videos individually (~1 minute).



  | Extension | Category |
  |-----------|----------|
  | \.pdf     | pdf      |
  | \.doc     | doc      |
  | \.docx    | doc      |
  | \.docm    | doc      |
  | \.dot     | doc      |
  | \.dotx    | doc      |
  | \.dotm    | doc      |
  | \.asd     | doc      |
  | \.cnv     | doc      |
  | \.mp3     | mp3      |
  | \.m4a     | mp3      |
  | \.m4b     | mp3      |
  | \.m4p     | mp3      |
  | \.wav     | mp3      |
  | \.aac     | mp3      |
  | \.aif     | mp3      |
  | \.mpa     | mp3      |
  | \.wma     | mp3      |
  | \.flac    | mp3      |
  | \.mid     | mp3      |
  | \.ogg     | mp3      |
  | \.xls     | xls      |
  | \.xlm     | xls      |
  | \.xll     | xls      |
  | \.xlc     | xls      |
  | \.xar     | xls      |
  | \.xla     | xls      |
  | \.xlb     | xls      |
  | \.xlsb    | xls      |
  | \.xlsm    | xls      |
  | \.xlsx    | xls      |
  | \.xlt     | xls      |
  | \.xltm    | xls      |
  | \.xltx    | xls      |
  | \.xlw     | xls      |
  | \.ppt     | ppt      |
  | \.pptx    | ppt      |
  | \.ppa     | ppt      |
  | \.ppam    | ppt      |
  | \.pptm    | ppt      |
  | \.pps     | ppt      |
  | \.ppsm    | ppt      |
  | \.ppsx    | ppt      |
  | \.pot     | ppt      |
  | \.potm    | ppt      |
  | \.potx    | ppt      |
  | \.sldm    | ppt      |
  | \.sldx    | ppt      |
  | \.txt     | txt      |
  | \.text    | txt      |
  | \.rtf     | txt      |
  | \.xml     | markup   |
  | \.htm     | markup   |
  | \.html    | markup   |
  | \.zip     | zip      |
  | \.rar     | zip      |
  | \.7z      | zip      |
  | \.jpg     | img      |
  | \.jpeg    | img      |
  | \.png     | img      |
  | \.bmp     | img      |
  | \.gif     | img      |
  | \.tif     | img      |
  | \.svg     | img      |
  | \.mp4     | vid      |
  | \.m4v     | vid      |
  | \.qt      | vid      |
  | \.mov     | vid      |
  | \.mpg     | vid      |
  | \.mpeg    | vid      |
  | \.3g2     | vid      |
  | \.3gp     | vid      |
  | \.flv     | vid      |
  | \.f4v     | vid      |
  | \.asf     | vid      |
  | \.avi     | vid      |
  | \.wmv     | vid      |
  | \.swf     | exe      |
  | \.exe     | exe      |
  | \.dll     | exe      |
  | \.ax      | exe      |
  | \.ocx     | exe      |
  | \.rpm     | exe      |



  Categorize your images into folders using computer vision models.

  ```bash
  pip install amazon-photos[extras] -U
  ```

  See the [Model List](https://www.hobenshield.com/stats/bench/index.html) for a list of all available models.



  **Very Large**

  ```
  eva02_base_patch14_448.mim_in22k_ft_in22k_in1k
  ```

  **Large**

  ```
  eva02_large_patch14_448.mim_m38m_ft_in22k_in1k
  ```

  **Medium**

  ```
  eva02_small_patch14_336.mim_in22k_ft_in1k
  vit_base_patch16_clip_384.laion2b_ft_in12k_in1k
  vit_base_patch16_clip_384.openai_ft_in12k_in1k
  caformer_m36.sail_in22k_ft_in1k_384
  ```

  **Small**

  ```
  eva02_tiny_patch14_336.mim_in22k_ft_in1k
  tiny_vit_5m_224.dist_in22k_ft_in1k
  edgenext_small.usi_in1k
  xcit_tiny_12_p8_384.fb_dist_in1k
  ```

  ```python
  run(
      'eva02_base_patch14_448.mim_in22k_ft_in22k_in1k',
      path_in='images',
      path_out='labeled',
      thresh=0.0,  # threshold for predictions, 0.9 means you want very confident predictions only
      topk=5,
      
      exclude=lambda x: re.search('boat|ocean', x, flags=re.I),
      
      restrict=lambda x: re.search('sand|beach|sunset', x, flags=re.I),
      
      dataloader_options={
          'batch_size': 4,  # *** adjust ***
          'shuffle': False,
          'num_workers': psutil.cpu_count(logical=False),  # *** adjust ***
          'pin_memory': True,
      },
      accumulate=False,
      
      device='cuda',
      naming_style='name',  # use human-readable label names, optionally use the label index or synset
      debug=0,
  )
  ```


pkgId: 0828bb33daaa79d848308d57025c71af6561f055d5895bca508891a6270dc922
name: python-amazon-product-review-scraper
arch: src
version: 0.9
epoch: 0
release: 1
summary: Python package to scrape product review data from amazon
url: https://github.com/SinghalHarsh/amazon-product-review-scraper
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-product-review-scraper-0.9-1.src.rpm
checksum_type: sha256
description:
  Python package to scrape product review data from amazon



  ```
  pip install amazon-product-review-scraper
  ```

  ```
  from amazon_product_review_scraper import amazon_product_review_scraper
  review_scraper = amazon_product_review_scraper(amazon_site="amazon.in", product_asin="B07X6V2FR3")
  reviews_df = review_scraper.scrape()
  reviews_df.head(5)
  ```

  <kbd>
    <img src="https://github.com/SinghalHarsh/amazon-product-review-scraper/blob/master/tutorials/quickstart.png">
  </kbd>



  1. #### ```amazon_site```
     **Examples**: amazon.in, amazon.com, amazon.co.uk

  2. #### ```product_asin```
     Product ASIN [(Amazon Standard Identification Number)](https://www.nchannel.com/blog/amazon-asin-what-is-an-asin-number/)
     An ASIN is a 10-character alphanumeric unique identifier that is assigned to each product on amazon.

     **Examples**:
     * https<span>://ww</span>w.amazon.i<span>n/Grand-Theft-Auto-V-PS4/dp/<code><b><ins>B00L8XUDIC</ins></b></code>/ref=sr_1_1
     * http</span>s://ww<span>w.amazon.</span>in/Renewed-Sony-Cybershot-DSC-RX100-Digital/dp/<code><b><ins>B07XRVR9B9</ins></b></code>/ref=lp_20690678031_1_14?srs=20690678031&ie=UTF8&qid=1598553991&sr=8-14

  3. #### ```sleep_time``` (Optional)
     Number of seconds to wait before scraping the next page.
     (Amazon might intervene with CAPTCHA if receives too many requests in a small period of time)

  4. #### ```start_page``` (Optional)
  5. #### ```end_page``` (Optional)


pkgId: e5ec2873bd154abab9fefacad8d3c187c304f3847e3da64f7823e3d246025424
name: python-amazon-ses-template-editor
arch: src
version: 0.5.1
epoch: 0
release: 1
summary: A tool for editing, uploading and testing Amazon SES email templates
url: https://github.com/Short-cm/amazon-ses-template-editor
rpm_license: UNKNOWN
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-ses-template-editor-0.5.1-1.src.rpm
checksum_type: sha256
description:
  [![Maintainability](https://api.codeclimate.com/v1/badges/2c5997ebabeaf46de9d8/maintainability)](https://codeclimate.com/github/Short-cm/amazon-ses-template-editor/maintainability)

  Console command to edit, test and upload amazon SES templates

  Currently AWS SES has API endpoint to create email templates with handlebars syntax and API endpoint to send emails with template name and a dictionary with template variables.
  But it does not provide any UI to create and edit templates. This script allows you to manage your email templates from command line



  ```bash
  pip install amazon-ses-template-editor
  ```


  ```
  usage: amazon-ses-template-editor.py [-h] [-c CONFIG]
                                       {upload,test,preview} ...

  positional arguments:
    {upload,test,preview}
      upload              Uploads templates from configuration file to SES using
                          your system credentials
      upload_test         Uploads templates for testing purposes
      test                Sends emails to your email address so you can test
                          layout
      preview             Starts minimal http server for email template testing

  optional arguments:
    -h, --help            show this help message and exit
    -c CONFIG, --config CONFIG
                          Path to configuration file, default ./config.toml
  ```


  ```
  usage: amazon-ses-template-editor.py upload [-h] [-t TEMPLATE]

  optional arguments:
    -h, --help            show this help message and exit
    -t TEMPLATE, --template TEMPLATE
                          Uploads only one template with given name
  ```

  ```
  usage: amazon-ses-template-editor.py upload_test [-h] [-t TEMPLATE]

  optional arguments:
    -h, --help            show this help message and exit
    -t TEMPLATE, --template TEMPLATE
                          Uploads only one template with given name


  usage: amazon-ses-template-editor.py test [-h] [-t TEMPLATE]

  optional arguments:
    -h, --help            show this help message and exit
    -t TEMPLATE, --template TEMPLATE
                          Uploads only one template with given name
  ```





  ```toml
  [[templates]]
  name = 'weekly-email'
  html = "templates/weekly-email.hb2"
  title = 'Your links weekly report'

  [[templates]]
  name = 'confirmation-email'
  html = "templates/confirmation-email.hb2"
  title = 'Please verify your email'

  [partials]
  footer = 'partials/footer.hb2'

  [tests]
  from = 'andrii@short.cm'
  to = ['andrey@kostenko.name', 'someone_else@short.cm']

  [[test]]
  template = 'weekly-email'
      [test.data]
          encodedEmail = 'andrey@kostenko.name'
          [test.data.user]
          id = 12345
          name = 'Test test'
          [[test.data.domains]]
              [test.data.domains.domain]
              hostname = 'test.com'
              [test.data.domains.stats]
              links = 50
              clicks = 50
              humanClicks = 50
              [[test.data.domains.stats.device]]
              deviceName = "Desktop"
              score = 12345
  ```



  Andrii Kostenko, Short.cm Inc (https://short.cm)


pkgId: 107d61422d78b3feab060b1aebf60afd93b0f2ee5ae976bdef23ef478afb0124
name: python-amazon-sns-extended-client
arch: src
version: 1.0.0
epoch: 0
release: 1
summary: Python version of AWS SNS extended client to publish large payload message
url: https://github.com/awslabs/amazon-sns-python-extended-client-lib
rpm_license: Apache-2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-sns-extended-client-1.0.0-1.src.rpm
checksum_type: sha256
description:
  * **Sign up for AWS** -- Before you begin, you need an AWS account. For more information about creating an AWS account, see [create and activate aws account](https://aws.amazon.com/premiumsupport/knowledge-center/create-and-activate-aws-account/).
  * **Minimum requirements** -- Python 3.x (or later) and pip
  * **Download** -- Download the latest preview release or pick it up from pip:
  ```
  pip install amazon-sns-extended-client
  ```



  sns-extended-client allows for publishing large messages through SNS via S3. This is the same mechanism that the Amazon library
  [amazon-sns-java-extended-client-lib](https://github.com/awslabs/amazon-sns-java-extended-client-lib) provides.


  * large_payload_support -- the S3 bucket name that will store large messages.
  * use_legacy_attribute -- if `True`, then all published messages use the Legacy reserved message attribute (SQSLargePayloadSize) instead of the current reserved message attribute (ExtendedPayloadSize).
  * message_size_threshold -- the threshold for storing the message in the large messages bucket. Cannot be less than `0` or greater than `262144`. Defaults to `262144`.
  * always_through_s3 -- if `True`, then all messages will be serialized to S3. Defaults to `False`
  * s3 -- the boto3 S3 `resource` object to use to store objects to S3. Use this if you want to control the S3 resource (for example, custom S3 config or credentials). Defaults to `boto3.resource("s3")` on first use if not previously set.




  > The s3 bucket must already exist prior to usage, and be accessible by whatever credentials you have available



  ```python
  import boto3
  import sns_extended_client


  sns = boto3.client('sns')
  sns.large_payload_support = 'bucket-name'


  resource = boto3.resource('sns')
  topic = resource.Topic('topic-arn')


  topic = resource.create_topic(Name='topic-name')

  topic.large_payload_support = 'my-bucket-name'


  resource = boto3.resource('sns')
  platform_endpoint = resource.PlatformEndpoint('endpoint-arn')

  platform_endpoint.large_payload_support = 'my-bucket-name'
  ```


  ```python
  import boto3
  import sns_extended_client


  sns = boto3.client('sns')
  sns.large_payload_support = 'BUCKET-NAME'
  sns.message_size_threshold = 65536


  resource = boto3.resource('sns')
  topic = resource.Topic('topic-arn')


  topic = resource.create_topic('topic-name')

  topic.large_payload_support = 'bucket-name'
  topic.message_size_threshold = 65536


  resource = boto3.resource('sns')
  platform_endpoint = resource.PlatformEndpoint('endpoint-arn')

  platform_endpoint.large_payload_support = 'my-bucket-name'
  platform_endpoint.message_size_threshold = 65536
  ```

  ```python
  import boto3
  import sns_extended_client


  sns = boto3.client('sns')
  sns.large_payload_support = 'my-bucket-name'
  sns.always_through_s3 = True


  resource = boto3.resource('sns')
  topic = resource.Topic('topic-arn')


  topic = resource.create_topic(Name='topic-name')

  topic.large_payload_support = 'my-bucket-name'
  topic.always_through_s3 = True


  resource = boto3.resource('sns')
  platform_endpoint = resource.PlatformEndpoint('endpoint-arn')

  platform_endpoint.large_payload_support = 'my-bucket-name'
  platform_endpoint.always_through_s3 = True
  ```

  ```python
  import boto3
  from botocore.config import Config
  import sns_extended_client


  sns = boto3.client('sns')
  sns.large_payload_support = 'my-bucket-name'
  sns.s3 = boto3.resource(
    's3',
    config=Config(
      signature_version='s3v4',
      s3={
        "use_accelerate_endpoint": True
      }
    )
  )


  resource = boto3.resource('sns')
  topic = resource.Topic('topic-arn')


  topic = resource.topic(Name='topic-name')

  topic.large_payload_support = 'my-bucket-name'
  topic.s3 = boto3.resource(
    's3',
    config=Config(
      signature_version='s3v4',
      s3={
        "use_accelerate_endpoint": True
      }
    )
  )


  resource = boto3.resource('sns')
  platform_endpoint = resource.PlatformEndpoint('endpoint-arn')

  platform_endpoint.large_payload_support = 'my-bucket-name'
  platform_endpoint.s3 = boto3.resource(
    's3',
    config=Config(
      signature_version='s3v4',
      s3={
        "use_accelerate_endpoint": True
      }
    )
  )
  ```


  Publish Message Supports user defined S3 Key used to store objects in the specified Bucket.

  To use custom keys add the S3 key as a Message Attribute in the MessageAttributes argument with the MessageAttribute.

  **Key - "S3Key"**
  ```python
  sns.publish(
      Message="message",
      MessageAttributes={
          "S3Key": {
              "DataType": "String",
              "StringValue": "--S3--Key--",
          }
      },
  )
  ```


  Initial versions of the Java SNS Extended Client used 'SQSLargePayloadSize' as the reserved message attribute to determine that a message is an S3 message.

  In the later versions it was changed to use 'ExtendedPayloadSize'.

  To use the Legacy reserved message attribute set use_legacy_attribute parameter to `True`.

  ```python
  import boto3
  import sns_extended_client


  sns = boto3.client('sns')
  sns.large_payload_support = 'bucket-name'

  sns.use_legacy_attribute = True


  resource = boto3.resource('sns')
  topic = resource.Topic('topic-arn')


  topic = resource.create_topic(Name='topic-name')

  topic.large_payload_support = 'my-bucket-name'
  topic.use_legacy_attribute = True


  resource = boto3.resource('sns')
  platform_endpoint = resource.PlatformEndpoint('endpoint-arn')

  platform_endpoint.large_payload_support = 'my-bucket-name'
  platform_endpoint.use_legacy_attribute = True
  ```


  Here is an example of using the extended payload utility:

  Here we create an SNS Topic and SQS Queue, then subscribe the queue to the topic.

  We publish messages to the created Topic and print the published message from the queue along with the original message retrieved from S3.

  ```python
  import boto3
  from sns_extended_client import SNSExtendedClientSession
  from json import loads

  s3_extended_payload_bucket = "extended-client-bucket-store"  # S3 bucket with the given bucket name is a resource which is created and accessible with the given AWS credentials
  TOPIC_NAME = "---TOPIC-NAME---"
  QUEUE_NAME = "---QUEUE-NAME---"

  def get_msg_from_s3(body):
      """Handy Helper to fetch message from S3"""
      json_msg = loads(body)
      s3_client = boto3.client("s3")
      s3_object = s3_client.get_object(
          Bucket=json_msg[1].get("s3BucketName"), Key=json_msg[1].get("s3Key")
      )
      msg = s3_object.get("Body").read().decode()
      return msg


  def fetch_and_print_from_sqs(sqs, queue_url):
      message = sqs.receive_message(
          QueueUrl=queue_url, MessageAttributeNames=["All"], MaxNumberOfMessages=1
      ).get("Messages")[0]
      message_body = message.get("Body")
      print("Published Message: {}".format(message_body))
      print("Message Stored in S3 Bucket is: {}\n".format(get_msg_from_s3(message_body)))


  sns_extended_client = boto3.client("sns", region_name="us-east-1")
  create_topic_response = sns_extended_client.create_topic(Name=TOPIC_NAME)
  demo_topic_arn = create_topic_response.get("TopicArn")


  sqs = boto3.client("sqs")
  demo_queue_url = sqs.create_queue(QueueName=QUEUE_NAME).get("QueueUrl")
  demo_queue_arn = sqs.get_queue_attributes(
      QueueUrl=demo_queue_url, AttributeNames=["QueueArn"]
  )["Attributes"].get("QueueArn")



  sns_extended_client.subscribe(TopicArn=demo_topic_arn, Protocol="sqs",
  Endpoint=demo_queue_arn, Attributes={"RawMessageDelivery":"true"})


  sns_extended_client.large_payload_support = s3_extended_payload_bucket
  sns_extended_client.always_through_s3 = True
  sns_extended_client.publish(
      TopicArn=demo_topic_arn, Message="This message should be published to S3"
  )
  print("\n\nPublished using SNS extended client:")
  fetch_and_print_from_sqs(sqs, demo_queue_url)  # Prints message stored in s3


  print("\nUsing decreased message size threshold:")

  sns_extended_client.always_through_s3 = False
  sns_extended_client.message_size_threshold = 32
  sns_extended_client.publish(
      TopicArn=demo_topic_arn,
      Message="This message should be published to S3 as it exceeds the limit of the 32 bytes",
  )

  fetch_and_print_from_sqs(sqs, demo_queue_url)  # Prints message stored in s3



  sns_extended_client_resource = SNSExtendedClientSession().resource(
      "sns", region_name="us-east-1"
  )

  topic = sns_extended_client_resource.Topic(demo_topic_arn)
  topic.large_payload_support = s3_extended_payload_bucket
  topic.always_through_s3 = True

  topic.publish(
      Message="This message should be published to S3 using the topic resource",
      MessageAttributes={
          "S3Key": {
              "DataType": "String",
              "StringValue": "347c11c4-a22c-42e4-a6a2-9b5af5b76587",
          }
      },
  )
  print("\nPublished using Topic Resource:")
  fetch_and_print_from_sqs(sqs, demo_queue_url)
  ```

  PRODUCED OUTPUT:
  ```
  Published using SNS extended client:
  Published Message: ["software.amazon.payloadoffloading.PayloadS3Pointer", {"s3BucketName": "extended-client-bucket-store", "s3Key": "465d51ea-2c85-4cf8-9ff7-f0a20636ac54"}]
  Message Stored in S3 Bucket is: This message should be published to S3


  Using decreased message size threshold:
  Published Message: ["software.amazon.payloadoffloading.PayloadS3Pointer", {"s3BucketName": "extended-client-bucket-store", "s3Key": "4e32bc6c-e67e-4e09-982b-66dfbe0c588a"}]
  Message Stored in S3 Bucket is: This message should be published to S3 as it exceeds the limit of the 32 bytes


  Published using Topic Resource:
  Published Message: ["software.amazon.payloadoffloading.PayloadS3Pointer", {"s3BucketName": "extended-client-bucket-store", "s3Key": "347c11c4-a22c-42e4-a6a2-9b5af5b76587"}]
  Message Stored in S3 Bucket is: This message should be published to S3 using the topic resource
  ```



  We have built-in Makefile to run test, format check or fix in one command. Please check [Makefile](Makefile) for more information.

  Just run below command, and it will do format check and run unit test:
  ```
  make ci
  ```



  See [CONTRIBUTING](CONTRIBUTING.md#security-issue-notifications) for more information.



  This project is licensed under the Apache-2.0 License.


pkgId: 7abb2662774caec0cf075a3ba3d0e57b4c8eecc5423516f44fc861b6452d66a4
name: python-amazon-sp-api-clients
arch: src
version: 1.9.2
epoch: 0
release: 1
summary: Amazon selling partner api clients.
url: https://pypi.org/project/amazon-sp-api-clients/
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-sp-api-clients-1.9.2-1.src.rpm
checksum_type: sha256
description:
  This is a package generated from amazon selling partner open api models.

  The package is tested in many situations, with fully type hint supported. Enjoy it!

  ![typehint 1](./docs/source/typehint1.png)

  ![typehint 2](./docs/source/typehint2.png)

  ![typehint 3](./docs/source/typehint3.png)



  V1.0.0 changes many api, compared with v0.x.x!

  注意！V1.0.0相较于v0.x.x更改了大量的API！



  * ready to use;
  * provide code to generate clients, in case that amazon update models;
  * type hint;
  * orders api, feed api, report api, and all other apis;
  * automatically manage tokens.



  ```shell
  pip install amazon-sp-api-clients
  ```



  For technical support, please contact [panhaoyu.china@outlook.com](mailto:panhaoyu.china@outlook.com).

  Previously this lib is only open access but not open source, and now it's time to make it public to serve more developers.

  If there's any bug, please fell free to open an issue or send a pr.



  For saving time, I just paste part of my test code here as a demo.

  For better understanding, all the fields are the same length of actual fields, and some readable information are kept.

  ```python
  from datetime import datetime
  import amazon_sp_api_clients
  endpoint = "https://sellingpartnerapi-eu.amazon.com"
  marketplace_id = "XXXXXXXXXXXXXX"
  refresh_token = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
  "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
  "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
  "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
  role_arn = "arn:aws:iam::123456789012:role/xxxxxx"
  aws_access_key = 'XXXXXXXXXXXXXXXXXXXX'
  aws_secret_key = "XXXXX/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
  client_id = 'amzn1.application-oa2-client.xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'
  client_secret = 'xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'
  client_config = dict(
      role_arn=role_arn,
      endpoint=endpoint,
      marketplace_id=marketplace_id,
      refresh_token=refresh_token,
      aws_access_key=aws_access_key,
      aws_secret_key=aws_secret_key,
      lwa_client_key=client_id,
      lwa_client_secret=client_secret,
  )
  clients = amazon_sp_api_clients.AmazonSpApiClients(**client_config)
  orders = clients.orders_v0.getOrders(
      MarketplaceIds=[marketplace_id],
      CreatedAfter=datetime(2000, 1, 1).isoformat()
  ).payload.Orders
  for order in orders:
      print(order.AmazonOrderId, order.LastUpdateDate)
  ```



  The client configuration can be set both at the initiation and as environment variables.

  * SP_API_ROLE_ARN
  * SP_API_ENDPOINT
  * SP_API_REGION
  * SP_API_MARKETPLACE_ID
  * SP_API_REFRESH_TOKEN
  * SP_API_AWS_ACCESS_KEY
  * SP_API_AWS_SECRET_KEY
  * SP_API_LWA_CLIENT_KEY
  * SP_API_LWA_CLIENT_SECRET



  The client is generated in the following steps:

  1. download amazon open api repository;
  1. copy open api 2 json files from the amazon repository to a single directory;
  1. convert open api 2 json files to open api 3 json files;
  1. convert open api 3 json files to py clients.

  The main script of generation is the `test_main` python file.

  When convert open api to py clients, I separated the process into 6 steps, which are defined in
  the `swager_client_generator.stages` module.

  If my build is not suitable for your demand, or amazon api model updates but my build do not follow, you can clone this
  repo, modify the `api.pyt` template and build it by yourself, and please push a PR, thanks!



  The auth method is partially from
  [python-amazon-sp-api](https://github.com/saleweaver/python-amazon-sp-api).



  If this library helps you, please give me a star, thanks!

  如果这个库对您有用，请为我点亮Star，谢谢！


pkgId: 05282984c56a70d03fe5fbaa2eeeb12322e862d79921de039acbc8a62943f05f
name: python-amazon-sqs-extended-client
arch: src
version: 1.0.1
epoch: 0
release: 1
summary: Python version of AWS SQS extended client
url: https://github.com/awslabs/amazon-sqs-python-extended-client-lib
rpm_license: Apache-2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-sqs-extended-client-1.0.1-1.src.rpm
checksum_type: sha256
description:
  The Amazon SQS Extended Client allows clients to manage Amazon SQS message payloads that exceed the 256 KB message size limit, up to a size of 2 GB. In the event of publishing such large messages, the client accomplishes this feat by storing the actual payload in a S3 bucket and by storing the reference of the stored object in the SQS queue. Similarly, the extended-client is also used for retrieving and dereferencing these references of message objects stored in S3. Thus, the library is used for the following purposes:


  1. Specify whether payloads are always stored in Amazon S3 or only when a payload's size exceeds 256 KB.
  2. Send a message that references a single message object stored in an Amazon S3 bucket.
  3. Get the corresponding payload object from an Amazon S3 bucket.
  4. Delete the corresponding payload object from an Amazon S3 bucket.



  The SQS Extended Client makes use of several additional message attributes which helps it to handle large message payloads. This section shall outline the various attributes present:

  1. ```large_payload_support``` : This consists of the S3 Bucket name that is responsible for storing large messages
  2. ```always_through_s3```: This decides if all the message should be serialized to the S3 bucket. If set to `False`, messages smaller than `256 KB` will not be serialized to the s3 bucket.
  3. ```use_legacy_attribute```: This message attribute is present in the header for a message structure and is important for consumers to understand the name of the key in the dictionary which contains the information of the large message payload. If True, then all published messages use the Legacy reserved message attribute (```SQSLargePayloadSize```) instead of the current reserved message attribute (```ExtendedPayloadSize```).



  1. ```MESSAGE_POINTER_CLASS```: The value held by this global variable, or by ```LEGACY_MESSAGE_POINTER_CLASS```, is critical to the functioning of the client as it holds the class name of the pointer that stored the original payload in a S3 bucket.
  2. ```MAX_ALLOWED_ATTRIBUTES```: The value held by this global variable denotes the constraint of having a maximum of 10 message attributes for each large message payload.
  3. ```S3_KEY_ATTRIBUTE_NAME```: The value held by this global variable denotes the S3 Key, if present, which would be used to store the large message payload.
  3. ```DEFAULT_MESSAGE_SIZE_THRESHOLD```: This states the threshold for the size of the messages in the S3 bucket and it cannot be less than 0 or more than 262144 (default value).
  4. ```RESERVED_ATTRIBUTE_NAME```: The value held by this global variable, or by ```LEGACY_RESERVED_ATTRIBUTE_NAME```, denotes the attribute name which will be reserved for the purpose of handling large message payloads.



  * **Sign up for AWS** -- Before you begin, you need an AWS account. For more information about creating an AWS account, see [create and activate aws account](https://aws.amazon.com/premiumsupport/knowledge-center/create-and-activate-aws-account/).
  * **Minimum requirements** -- Python 3.x (or later) and pip
  * **Download** -- Download the latest preview release or pick it up from pip:
  ```
  pip install amazon-sqs-extended-client
  ```




  Ensure that the package has been imported in the file you want to run your code from, by doing:



  ```
  import boto3
  import sqs_extended_client

  sqs_extended_client = boto3.client("sqs", region_name="us-east-1")
  sqs_extended_client.large_payload_support = "BUCKET_NAME_HERE"
  sqs_extended_client.use_legacy_attribute = False


  queue = sqs_extended_client.create_queue(
      QueueName = "DemoPreparationQueue"
  )
  queue_url = sqs_extended_client.get_queue_url(
      QueueName = "DemoPreparationQueue"
  )['QueueUrl']


  sqs_extended_client.s3_client.create_bucket(Bucket=sqs_extended_client.large_payload_support)
  ```




  ```


  large_message = small_message * 300000 # Shall cross the limit of 256 KB

  send_message_response = sqs_extended_client.send_message(
      QueueUrl=queue_url,
      MessageBody=large_message
  )
  assert send_message_response['ResponseMetadata']['HTTPStatusCode'] == 200
  ```

  ```


  receive_message_response = sqs_extended_client.receive_message(
      QueueUrl=queue_url,
      MessageAttributeNames=['All']
  )
  assert receive_message_response['Messages'][0]['Body'] == large_message
  receipt_handle = receive_message_response['Messages'][0]['ReceiptHandle']
  ```

  ```



  sqs_extended_client.delete_payload_from_s3 = True
  delete_message_response = sqs_extended_client.delete_message(
      QueueUrl=queue_url,
      ReceiptHandle=receipt_handle
  )

  assert delete_message_response['ResponseMetadata']['HTTPStatusCode'] == 200
  ```

  ```


  delete_queue_response = sqs_extended_client.delete_queue(
      QueueUrl=queue_url
  )

  assert delete_queue_response['ResponseMetadata']['HTTPStatusCode'] == 200
  ```



  See [CONTRIBUTING](CONTRIBUTING.md#security-issue-notifications) for more information.



  This project is licensed under the Apache-2.0 License.


pkgId: 69a2ce42368a4d40f96aa6458d2d0fdc43f04a523e1e2e7db9a4330a53d46fb8
name: python-amazon-textract-caller
arch: src
version: 0.2.4
epoch: 0
release: 1
summary: Amazon Textract Caller tools
url: https://github.com/aws-samples/amazon-textract-textractor/tree/master/caller
rpm_license: Apache License Version 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-textract-caller-0.2.4-1.src.rpm
checksum_type: sha256
description:
  amazon-textract-caller provides a collection of ready to use functions and sample implementations to speed up the evaluation and development for any project using Amazon Textract.

  Making it easy to call Amazon Textract regardless of file type and location.



  ```bash
  > python -m pip install amazon-textract-caller
  ```



  ```python
  from textractcaller import call_textract
  def call_textract(input_document: Union[str, bytes],
                    features: Optional[List[Textract_Features]] = None,
                    queries_config: Optional[QueriesConfig] = None,
                    output_config: Optional[OutputConfig] = None,
                    adapters_config: Optional[AdaptersConfig] = None,
                    kms_key_id: str = "",
                    job_tag: str = "",
                    notification_channel: Optional[NotificationChannel] = None,
                    client_request_token: str = "",
                    return_job_id: bool = False,
                    force_async_api: bool = False,
                    call_mode: Textract_Call_Mode = Textract_Call_Mode.DEFAULT,
                    boto3_textract_client=None,
                    job_done_polling_interval=1) -> dict:
  ```

  Also useful when receiving the JSON response from an asynchronous job (start_document_text_detection or start_document_analysis)

  ```python
  from textractcaller import get_full_json
  def get_full_json(job_id: str = None,
                    textract_api: Textract_API = Textract_API.DETECT,
                    boto3_textract_client=None)->dict:
  ```

  And when receiving the JSON from the OutputConfig location, this method is useful as well.

  ```python
  from textractcaller import get_full_json_from_output_config
  def get_full_json_from_output_config(output_config: OutputConfig = None,
                                       job_id: str = None,
                                       s3_client = None)->dict:
  ```





  ```python
  textract_json = call_textract(input_document="/folder/local-filesystem-file.png")
  ```



  (needs trp dependency through ```python -m pip install amazon-textract-response-parser```)

  ```python
  import json
  from trp import Document
  from textractcaller import call_textract

  textract_json = call_textract(input_document="/folder/local-filesystem-file.png")
  d = Document(textract_json)
  ```



  sample also uses the amazon-textract-response-parser

  ```
  python -m pip install amazon-textract-caller amazon-textract-response-parser
  ```

  ```python
  import textractcaller as tc
  import trp.trp2 as t2
  import boto3

  textract = boto3.client('textract', region_name="us-east-2")
  q1 = tc.Query(text="What is the employee SSN?", alias="SSN", pages=["1"])
  q2 = tc.Query(text="What is YTD gross pay?", alias="GROSS_PAY", pages=["2"])
  textract_json = tc.call_textract(
      input_document="s3://amazon-textract-public-content/blogs/2-pager.pdf",
      queries_config=tc.QueriesConfig(queries=[q1, q2]),
      features=[tc.Textract_Features.QUERIES],
      force_async_api=True,
      boto3_textract_client=textract)
  t_doc: t2.TDocument = t2.TDocumentSchema().load(textract_json)  # type: ignore
  for page in t_doc.pages:
      query_answers = t_doc.get_query_answers(page=page)
      for x in query_answers:
          print(f"{x[1]},{x[2]}")
  ```



  sample also uses the amazon-textract-response-parser

  ```
  python -m pip install amazon-textract-caller amazon-textract-response-parser
  ```

  ```python
  import textractcaller as tc
  import trp.trp2 as t2
  import boto3

  textract = boto3.client('textract', region_name="us-east-2")
  q1 = tc.Query(text="What is the employee SSN?", alias="SSN", pages=["1"])
  q2 = tc.Query(text="What is YTD gross pay?", alias="GROSS_PAY", pages=["2"])
  adapter1 = tc.Adapter(adapter_id="2e9bf1c4aa31", version="1", pages=["1"])
  textract_json = tc.call_textract(
      input_document="s3://amazon-textract-public-content/blogs/2-pager.pdf",
      queries_config=tc.QueriesConfig(queries=[q1, q2]),
      adapters_config=tc.AdaptersConfig(adapters=[adapter1])
      features=[tc.Textract_Features.QUERIES],
      force_async_api=True,
      boto3_textract_client=textract)
  t_doc: t2.TDocument = t2.TDocumentSchema().load(textract_json)  # type: ignore
  for page in t_doc.pages:
      query_answers = t_doc.get_query_answers(page=page)
      for x in query_answers:
          print(f"{x[1]},{x[2]}")
  ```




  ```python
  from textractcaller import call_textract, Textract_Features
  features = [Textract_Features.TABLES]
  response = call_textract(
      input_document="/folder/local-filesystem-file.png", features=features)
  ```



  ```python
  from textractcaller import call_textract
  response = call_textract(input_document="s3://some-bucket/w2-example.png", force_async_api=True)
  ```



  ```python
  from textractcaller import call_textract
  from textractcaller import OutputConfig, Textract_Features
  output_config = OutputConfig(s3_bucket="somebucket-encrypted", s3_prefix="output/")
  response = call_textract(input_document="s3://someprefix/somefile.png",
                            force_async_api=True,
                            output_config=output_config,
                            kms_key_id="arn:aws:kms:us-east-1:12345678901:key/some-key-id-ref-erence",
                            return_job_id=False,
                            job_tag="sometag",
                            client_request_token="sometoken")

  ```



  ```python
  from textractcaller import call_textract
  response = call_textract(input_document="s3://some-bucket/some-document.pdf", return_job_id=True)
  job_id = response['JobId']
  ```


pkgId: f3b693921af045149edd83c41eebdb9321f492863d84e48f86ea985572f9762f
name: python-amazon-textract-geofinder
arch: src
version: 0.0.8
epoch: 0
release: 1
summary: Amazon Textract package to easier access data through geometric information
url: https://github.com/aws-samples/amazon-textract-textractor/tpipelinegeofinder
rpm_license: Apache License Version 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-textract-geofinder-0.0.8-1.src.rpm
checksum_type: sha256
description:
  Provides functions to use geometric information to extract information.

  Use cases include:
  * Give context to key/value pairs from the Amazon Textract AnalyzeDocument API for FORMS
  * Find values in specific areas



  ```bash
  > python -m pip install amazon-textract-geofinder
  ```

  Make sure your environment is setup with AWS credentials through configuration files or environment variables or an attached role. (https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html)



  To find information in a document based on geometry with this library the main advantage over defining x,y coordinates where the expected value should be is the concept of an area.

  An area is ultimately defined by a box with x_min, y_min, x_max, y_max coordinates but can be defined by finding words/phrases in the document and then use to create the area.

  From there functions to parse the information in the area help to extract the information. E. g. by defining the area based on the question like 'Did you feel fever or feverish lately?' we can associate the answers to it and create a new key/value pair specific to this question.






  Sample image:

  <img src="./tests/data/patient_intake_form_sample.jpg" width=300>

  The Amazon Textract AnalyzeDocument API with the FORMS feature returns the following keys:

  | Key                                          | Value          |
  |----------------------------------------------|----------------|
  | First Name:                                  | ALEJANDRO      |
  | First Name:                                  | CARLOS         |
  | Relationship to Patient:                     | BROTHER        |
  | First Name:                                  | JANE           |
  | Marital Status:                              | MARRIED        |
  | Phone:                                       | 646-555-0111   |
  | Last Name:                                   | SALAZAR        |
  | Phone:                                       | 212-555-0150   |
  | Relationship to Patient:                     | FRIEND         |
  | Last Name:                                   | ROSALEZ        |
  | City:                                        | ANYTOWN        |
  | Phone:                                       | 650-555-0123   |
  | Address:                                     | 123 ANY STREET |
  | Yes                                          | SELECTED       |
  | Yes                                          | NOT_SELECTED   |
  | Date of Birth:                               | 10/10/1982     |
  | Last Name:                                   | DOE            |
  | Sex:                                         | M              |
  | Yes                                          | NOT_SELECTED   |
  | Yes                                          | NOT_SELECTED   |
  | Yes                                          | NOT_SELECTED   |
  | State:                                       | CA             |
  | Zip Code:                                    | 12345          |
  | Email Address:                               |                |
  | No                                           | NOT_SELECTED   |
  | No                                           | SELECTED       |
  | No                                           | NOT_SELECTED   |
  | Yes                                          | SELECTED       |
  | No                                           | SELECTED       |
  | No                                           | SELECTED       |
  | No                                           | SELECTED       |


  But the information to which section of the document the individual keys belong is not obvious. Most keys appear multiple times and we want to give them context to associate them with the 'Patient', 'Emergency Contact 1', 'Emergency Contact 2' or specific questions.


  This Jupyter notebook that walks through the sample: [sample notebook](./geofinder-sample-notebook.ipynb)
  Make sure to have AWS credentials setup when starting the notebook locally or use a SageMaker notebook with a role including permissions for Amazon Textract.

  This code snippet is take from the notebook.

  ```bash
  python -m pip install amazon-textract-helper amazon-textract-geofinder
  ```

  ```python
  from textractgeofinder.ocrdb import AreaSelection
  from textractgeofinder.tgeofinder import KeyValue, TGeoFinder, AreaSelection, SelectionElement
  from textractprettyprinter.t_pretty_print import get_forms_string
  from textractcaller import call_textract
  from textractcaller.t_call import Textract_Features

  import trp.trp2 as t2

  image_filename='./tests/data/patient_intake_form_sample.jpg'

  j = call_textract(input_document=image_filename, features=[Textract_Features.FORMS])


  t_document = t2.TDocumentSchema().load(j)
  doc_height = 1000
  doc_width = 1000
  geofinder_doc = TGeoFinder(j, doc_height=doc_height, doc_width=doc_width)

  def set_hierarchy_kv(list_kv: list[KeyValue], t_document: t2.TDocument, page_block: t2.TBlock, prefix="BORROWER"):
      for x in list_kv:
          t_document.add_virtual_key_for_existing_key(key_name=f"{prefix}_{x.key.text}",
                                                      existing_key=t_document.get_block_by_id(x.key.id),
                                                      page_block=page_block)

  patient_information = geofinder_doc.find_phrase_on_page("patient information")[0]
  emergency_contact_1 = geofinder_doc.find_phrase_on_page("emergency contact 1:", min_textdistance=0.99)[0]
  top_left = t2.TPoint(y=patient_information.ymax, x=0)
  lower_right = t2.TPoint(y=emergency_contact_1.ymin, x=doc_width)
  form_fields = geofinder_doc.get_form_fields_in_area(
      area_selection=AreaSelection(top_left=top_left, lower_right=lower_right))
  set_hierarchy_kv(list_kv=form_fields, t_document=t_document, prefix='PATIENT', page_block=t_document.pages[0])

  set_hierarchy_kv(list_kv=form_fields, t_document=t_document, prefix='PATIENT', page_block=t_document.pages[0])

  print(get_forms_string(t2.TDocumentSchema().dump(t_document)))
  ```

  | Key                     | Value          |
  |-------------------------|----------------|
  | ...                     | ...            |
  | PATIENT_first name:     | ALEJANDRO      |
  | PATIENT_address:        | 123 ANY STREET |
  | PATIENT_sex:            | M              |
  | PATIENT_state:          | CA             |
  | PATIENT_zip code:       | 12345          |
  | PATIENT_marital status: | MARRIED        |
  | PATIENT_last name:      | ROSALEZ        |
  | PATIENT_phone:          | 646-555-0111   |
  | PATIENT_email address:  |                |
  | PATIENT_city:           | ANYTOWN        |
  | PATIENT_date of birth:  | 10/10/1982     |



  This will show the full result, like the notebook.

  ```bash
  > python -m pip install amazon-textract-helper amazon-textract-geofinder
  > cat tests/data/patient_intake_form_sample.json| bin/amazon-textract-geofinder | amazon-textract --stdin --pretty-print FORMS
  ```

  | Key                     | Value          |
  |-------------------------|----------------|
  | First Name:                                  | ALEJANDRO      |
  | First Name:                                  | CARLOS         |
  | Relationship to Patient:                     | BROTHER        |
  | First Name:                                  | JANE           |
  | Marital Status:                              | MARRIED        |
  | Phone:                                       | 646-555-0111   |
  | Last Name:                                   | SALAZAR        |
  | Phone:                                       | 212-555-0150   |
  | Relationship to Patient:                     | FRIEND         |
  | Last Name:                                   | ROSALEZ        |
  | City:                                        | ANYTOWN        |
  | Phone:                                       | 650-555-0123   |
  | Address:                                     | 123 ANY STREET |
  | Yes                                          | SELECTED       |
  | Yes                                          | NOT_SELECTED   |
  | Date of Birth:                               | 10/10/1982     |
  | Last Name:                                   | DOE            |
  | Sex:                                         | M              |
  | Yes                                          | NOT_SELECTED   |
  | Yes                                          | NOT_SELECTED   |
  | Yes                                          | NOT_SELECTED   |
  | State:                                       | CA             |
  | Zip Code:                                    | 12345          |
  | Email Address:                               |                |
  | No                                           | NOT_SELECTED   |
  | No                                           | SELECTED       |
  | No                                           | NOT_SELECTED   |
  | Yes                                          | SELECTED       |
  | No                                           | SELECTED       |
  | No                                           | SELECTED       |
  | No                                           | SELECTED       |
  | PATIENT_first name:                          | ALEJANDRO      |
  | PATIENT_address:                             | 123 ANY STREET |
  | PATIENT_sex:                                 | M              |
  | PATIENT_state:                               | CA             |
  | PATIENT_zip code:                            | 12345          |
  | PATIENT_marital status:                      | MARRIED        |
  | PATIENT_last name:                           | ROSALEZ        |
  | PATIENT_phone:                               | 646-555-0111   |
  | PATIENT_email address:                       |                |
  | PATIENT_city:                                | ANYTOWN        |
  | PATIENT_date of birth:                       | 10/10/1982     |
  | EMERGENCY_CONTACT_1_first name:              | CARLOS         |
  | EMERGENCY_CONTACT_1_phone:                   | 212-555-0150   |
  | EMERGENCY_CONTACT_1_relationship to patient: | BROTHER        |
  | EMERGENCY_CONTACT_1_last name:               | SALAZAR        |
  | EMERGENCY_CONTACT_2_first name:              | JANE           |
  | EMERGENCY_CONTACT_2_phone:                   | 650-555-0123   |
  | EMERGENCY_CONTACT_2_last name:               | DOE            |
  | EMERGENCY_CONTACT_2_relationship to patient: | FRIEND         |
  | FEVER->YES                                   | SELECTED       |
  | FEVER->NO                                    | NOT_SELECTED   |
  | SHORTNESS->YES                               | NOT_SELECTED   |
  | SHORTNESS->NO                                | SELECTED       |
  | COUGH->YES                                   | NOT_SELECTED   |
  | COUGH->NO                                    | SELECTED       |
  | LOSS_OF_TASTE->YES                           | NOT_SELECTED   |
  | LOSS_OF_TASTE->NO                            | SELECTED       |
  | COVID_CONTACT->YES                           | SELECTED       |
  | COVID_CONTACT->NO                            | NOT_SELECTED   |
  | TRAVEL->YES                                  | NOT_SELECTED   |
  | TRAVEL->NO                                   | SELECTED       |


pkgId: 508ce6dc35e4053cfc5234ddd9747d4176bf683ae0a9a92bc9f1d55958ee91fd
name: python-amazon-textract-helper
arch: src
version: 0.0.35
epoch: 0
release: 1
summary: Amazon Textract Helper tools
url: https://github.com/aws-samples/amazon-textract-textractor/tree/master/helper
rpm_license: Apache License Version 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-textract-helper-0.0.35-1.src.rpm
checksum_type: sha256
description:
  amazon-textract-helper provides a collection of ready to use functions and sample implementations to speed up the evaluation and development for any project using Amazon Textract.
  It installs a command line tool called ```amazon-textract```




  ```bash
  > python -m pip install amazon-textract-helper
  ```

  Make sure your environment is setup with AWS credentials through configuration files or environment variables or an attached role. (https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html)



  ```bash
  > amazon-textract --help
  usage: amazon-textract [-h] (--input-document INPUT_DOCUMENT | --example | --stdin) [--features {FORMS,TABLES} [{FORMS,TABLES} ...]]
                         [--pretty-print {WORDS,LINES,FORMS,TABLES} [{WORDS,LINES,FORMS,TABLES} ...]]
                         [--pretty-print-table-format {csv,plain,simple,github,grid,fancy_grid,pipe,orgtbl,jira,presto,pretty,psql,rst,medi
  awiki,moinmoin,youtrack,html,unsafehtml,latex,latex_raw,latex_booktabs,latex_longtable,textile,tsv}]
                         [--overlay {WORD,LINE,FORM,KEY,VALUE,TABLE,CELL} [{WORD,LINE,FORM,KEY,VALUE,TABLE,CELL} ...]]
                         [--pop-up-overlay-output] [--overlay-output-folder OVERLAY_OUTPUT_FOLDER] [--version] [--no-stdout] [-v | -vv]

  optional arguments:
    -h, --help            show this help message and exit
    --input-document INPUT_DOCUMENT
                          s3 object (s3://) or file from local filesystem
    --example             using the example document to call Textract
    --stdin               receive JSON from stdin
    --features {FORMS,TABLES} [{FORMS,TABLES} ...]
                          features to call Textract with. Will trigger call to AnalyzeDocument instead of DetectDocumentText
    --pretty-print {WORDS,LINES,FORMS,TABLES} [{WORDS,LINES,FORMS,TABLES} ...]
    --pretty-print-table-format {csv,plain,simple,github,grid,fancy_grid,pipe,orgtbl,jira,presto,pretty,psql,rst,mediawiki,moinmoin,youtrac
  k,html,unsafehtml,latex,latex_raw,latex_booktabs,latex_longtable,textile,tsv}
                          which format to output the pretty print information to. Only effects FORMS and TABLES
    --overlay {WORD,LINE,FORM,KEY,VALUE,TABLE,CELL} [{WORD,LINE,FORM,KEY,VALUE,TABLE,CELL} ...]
                          defines what bounding boxes to draw on the output
    --pop-up-overlay-output
                          shows image with overlay
    --overlay-text        shows image with WORD or LINE text overlay. When both WORD and LINE overlay are specified, WORD text will be overlayed
    --overlay-confidence  shows image with confidence overlay
    --overlay-output-folder OVERLAY_OUTPUT_FOLDER
                          output with bounding boxes to folder
    --version             print version information
    --no-stdout           no output to stdout
    -v                    >=INFO level logging output to stderr
    -vv                   >=DEBUG level logging output to stderr
  ```





  ```bash
  > amazon-textract --example
  ```

  this will run the examples document using the DetectDocumentText API.
  Output will be printed to stdout and look similar to this:

  ```json
  {"DocumentMetadata": {"Pages": 1}, "Blocks": [{"BlockType": "PAGE", "Geometry": {"BoundingBox": {"Width": 1.0, "Height": 1.0, "Left": 0.0
  , "Top": 0.0}, "Polygon": [{"X": 9.33321120033382e-17, "Y": 0.0}, {"X": 1.0, "Y": 1.6069064689339292e-16}, {"X": 1.0, "Y": 1.0}],
  "HTTPHeaders": {"x-amzn-requestid": "12345678-1234-1234-1234-123456789012", "content-type": "a
  pplication/x-amz-json-1.1", "content-length": "48177", "date": "Thu, 01 Apr 2021 21:50:29 GMT"}, "RetryAttempts": 0}}
  ```

  It is working.



  ```bash
  > amazon-textract --input-document "s3://somebucket/someprefix/someobjectname.png"
  ```

  Output similar to Easy Start



  ```bash
  > amazon-textract --input-document "./somepath/somefilename.png"
  ```

  Output similar to Easy Start

  We will continue to use the ```--example``` parameter to keep it simple and easy to reproduce. S3 and local files work the same way, just instead of --example use --input-document <location>.



  ```bash

  amazon-textract --example > example.json

  cat example.json | amazon-textract --stdin -pretty-print LINES
  ```



  ```bash
  > amazon-textract --example --features FORMS TABLES
  ```

  This will call the [AnalyzeDocument API] (https://docs.aws.amazon.com/textract/latest/dg/API_AnalyzeDocument.html) and output will include
  Output will look similar to "Easy Start" but include FORMS and TABLES information



  Pretty print outputs nicely formatted information for words, lines, forms or tables.

  For example to print the tables identified by Amazon Textract to stdout, use

  ```bash
  > amazon-textract --example --features TABLES --pretty-print TABLES
  ```

  Output will look like this:

  ```text
  |------------|-----------|---------------------|-----------------|-----------------------|
  |            |           | Previous Employment | History         |                       |
  | Start Date | End Date  | Employer Name       | Position Held   | Reason for leaving    |
  | 1/15/2009  | 6/30/2011 | Any Company         | Assistant Baker | Family relocated      |
  | 7/1/2011   | 8/10/2013 | Best Corp.          | Baker           | Better opportunity    |
  | 8/15/2013  | present   | Example Corp.       | Head Baker      | N/A, current employer |

  ```

  to pretty print both, FORMS and TABLES:

  ```bash
  > amazon-textract --example --features FORMS TABLES --pretty-print FORMS TABLES
  ```

  will output

  ```text
  Phone Number:: 555-0100
  Home Address:: 123 Any Street, Any Town, USA
  Full Name:: Jane Doe
  Mailing Address:: same as home address
  |------------|-----------|---------------------|-----------------|-----------------------|
  |            |           | Previous Employment | History         |                       |
  | Start Date | End Date  | Employer Name       | Position Held   | Reason for leaving    |
  | 1/15/2009  | 6/30/2011 | Any Company         | Assistant Baker | Family relocated      |
  | 7/1/2011   | 8/10/2013 | Best Corp.          | Baker           | Better opportunity    |
  | 8/15/2013  | present   | Example Corp.       | Head Baker      | N/A, current employer |
  ```



  **At the moment overlay only works with images, we will add support for PDF soon.**

  The following command runs DetectDocumentText, pretty prints the WORDS in the document to stdout and draws bounding boxes around each WORD and displays the result in a popup window and stores it to a folder called 'overlay-output-folder-name'.

  ```bash
  amazon-textract --example --pretty-print WORDS --overlay WORD --pop-up-overlay-output --overlay-output-folder overlay-output-folder-name
  ```

  <img src="https://github.com/aws-samples/amazon-textract-textractor/blob/master/helper/docs/employmentapp_boxed_WORD_.png" alt="Sample overlay WORD" width="50%" height="50%" border="1">


  The following command runs AnalyzeDocument for FORMS and TABLES, pretty prints FORMS and TABLES to  to stdout and draws bounding boxes around each TABLE-CELL and FORM KEY/VALUE and displays the result in a popup window and stores it to a folder called 'overlay-output-folder-name'.

  ```bash
  > amazon-textract --example --features TABLES FORMS --pretty-print FORMS TABLES --overlay FORM CELL --pop-up-overlay-output --overlay-output-folder ../mywonderfuloutputfolderfordocs/
  ```


  <img src="https://github.com/aws-samples/amazon-textract-textractor/blob/master/helper/docs/employmentapp_boxed_FORM_CELL_.png" alt="Sample overlay FORM CELL" width="50%" height="50%" border="1">


  The following command draws bounding boxes around each WORD, overlays the detected WORD text, and displays the result in a popup window and stores it to a folder called 'overlay-output-folder-name'.

  ```bash
  > amazon-textract --example --overlay WORD --overlay-text --pop-up-overlay-output --overlay-output-folder overlay-output-folder-name
  ```


  <img src="https://github.com/aws-samples/amazon-textract-textractor/blob/master/helper/docs/employmentapp_boxed_WORD_TEXT_OVERLAY.png" alt="Sample overlay LINE with overlay text and confidence percentage" width="50%" height="50%" border="1">


  The following command draws bounding boxes around each LINE, overlays LINE text along with percentage confidence of the detected LINE text, and displays the result in a popup window and stores it to a folder called 'overlay-output-folder-name'.

  ```bash
  > amazon-textract --example --overlay LINE --overlay-text --overlay-confidence --pop-up-overlay-output --overlay-output-folder overlay-output-folder-name
  ```


  <img src="https://github.com/aws-samples/amazon-textract-textractor/blob/master/helper/docs/employmentapp_boxed_LINE_TEXT_OVERLAY.png" alt="Sample overlay LINE with overlay text and confidence percentage" width="50%" height="50%" border="1">


pkgId: 58b35908b5c2cf74f78034af66a62d1f7cd88bad223fe790fd92bac4cdd74ef0
name: python-amazon-textract-idp-cdk-constructs
arch: src
version: 0.0.43
epoch: 0
release: 1
summary: amazon-textract-idp-cdk-constructs
url: https://github.com/aws-samples/amazon-textract-idp-cdk-constructs.git
rpm_license: MIT-0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-textract-idp-cdk-constructs-0.0.43-1.src.rpm
checksum_type: sha256
description:
  <!--END STABILITY BANNER-->

  This CDK Construct can be used as Step Function task and call Textract in Asynchonous mode for DetectText and AnalyzeDocument APIs.
  For samples on usage, look at [Amazon Textact IDP CDK Stack Samples](https://github.com/aws-samples/amazon-textract-idp-cdk-stack-samples)

  Expects a Manifest JSON at 'Payload'.
  Manifest description: https://pypi.org/project/schadem-tidp-manifest/
  Example call in Python
  ```python
          textract_async_task = t_async.TextractGenericAsyncSfnTask(
              self,
              "textract-async-task",
              s3_output_bucket=s3_output_bucket,
              s3_temp_output_prefix=s3_temp_output_prefix,
              integration_pattern=sfn.IntegrationPattern.WAIT_FOR_TASK_TOKEN,
              lambda_log_level="DEBUG",
              timeout=Duration.hours(24),
              input=sfn.TaskInput.from_object({
                  "Token":
                  sfn.JsonPath.task_token,
                  "ExecutionId":
                  sfn.JsonPath.string_at('$$.Execution.Id'),
                  "Payload":
                  sfn.JsonPath.entire_payload,
              }),
              result_path="$.textract_result")
  ```

  Example:
  ```python
              input=sfn.TaskInput.from_object({
                  "Token":
                  sfn.JsonPath.task_token,
                  "ExecutionId":
                  sfn.JsonPath.string_at('$$.Execution.Id'),
                  "Payload":
                  sfn.JsonPath.entire_payload,
                  "Query": [
                             {
                                  'Text': 'string',
                                  'Alias': 'string',
                                  'Pages': [
                                      'string',
                                  ]
                              },
                                  {
                                  "Text": "What is the name of the realestate company",
                                  "Alias": "APP_COMPANY_NAME"
                              },
                              {
                                  "Text": "What is the name of the applicant or the prospective tenant",
                                  "Alias": "APP_APPLICANT_NAME"
                              },
                  ]
              }),
  ```
  Documentation: https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/textract/client/start_document_analysis.html
  To add a query parameter to the Manifest JSON, we are going to leverage the 'convert_manifest_queries_config_to_caller'. It transforms a list of Query objects (as indicated by the type hint List[tm.Query]) into a QueriesConfig object (as indicated by the return type tc.QueriesConfig).
  The function expects a list of Query objects as input. Each Query object should have the following attributes:
  * text (required)
  * alias (opt)
  * pages (opt)
  The function creates a new QueriesConfig object. If the input list is not empty, it creates a list comprehension that generates a new Query object for each Query object in the input list, maintaining the same text, alias, and pages values. If the input list is empty, it simply creates a QueriesConfig object with an empty queries list.

  Adds the "TextractTempOutputJsonPath" to the Step Function ResultPath. At this location the Textract output is stored as individual JSON files. Use the CDK Construct schadem-cdk-construct-sfn-textract-output-config-to-json to combine them to one single JSON file.
  example with ResultPath = textract_result (like configured above):
  ```
  "textract_result": {
      "TextractTempOutputJsonPath": "s3://schademcdkstackpaystuban-schademcdkidpstackpaystu-bt0j5wq0zftu/textract-temp-output/c6e141e8f4e93f68321c17dcbc6bf7291d0c8cdaeb4869758604c387ce91a480"
    }
  ```

  Expect a Spacy textcat model at the root of the directory. Call the script <TO_INSERT) to copy a public one which classifies Paystub and W2.
  aws s3 cp s3://amazon-textract-public-content/constructs/en_textcat_demo-0.0.0.tar.gz .

  In order to demonstrate this functionality, I have used below architecture where once the inbound email is delivered to your Amazon workmail inbox and if the pattern/s matches, it will invoke the rule action which is inovocation of a lambda function in this case. You can use my sample code to fetch the inbound email message body and parse it properly as text.
  ![architecture](./images/Workmail_Lambda.png)

  1. As I have used Python 3.6 as my Lambda function runtime hence some knowledge of python 3 version is required.

  1. First setup an Amazon workmail site, setup an organization and create a user access by following steps mentioned in 'Getting Started' document [here](https://docs.aws.amazon.com/workmail/latest/adminguide/howto-start.html). Once above setup process is done, you will have access to https://*your Organization*.awsapps.com/mail webmail url and you can login using your created user's username / password to access your emails.
  2. Now we will create a lambda function which will be invoked once inbound email reaches the inbox and email flow rule pattern is matched (more on this in below steps). You can use the sample lambda python(3.6) code ( lambda_function.py) provided in the 'code' folder for the same. It will fetch the inbound email message body and then parse it properly to get the message body as text. Once you get it as text you can perform various operations on it.
  3. Inbound email flow rules, also called rule actions, automatically apply to all email messages sent to anyone inside of the Amazon WorkMail organization. This differs from email rules for individual mailboxes. Now we will set up email flow rules to handle email flows based on email addresses or domains. Email flow rules are based on both the sender's and recipient's email addresses or domains.
  To create an email flow rule, we need to specify a rule action to apply to an email when a specified pattern is matched. Follow the documenttion link [here](https://docs.aws.amazon.com/workmail/latest/adminguide/email-flows.html#email-flows-rule-actions) to create email flow rule for your organization which you created in step #1 above. you have to select Action=Run Lambda for your rule. Below is the email flow rule created by me:
  ![Email Flow Rule](./images/email_rule_1.png)
  you can now follow documentation link [here](https://docs.aws.amazon.com/workmail/latest/adminguide/email-flows.html#email-flows-patterns) to create pattern/s which need to be satisfied first in order to invoke the rule action (in this case it will invoke our lambda function). For this sample code functionality I have used my email address as pattern in 'origns' and my domain as pattern in 'destinations'. so in this case the lambda function will only be invoke if inbound email sender is my email address and destination is my domain only but you can set patterns as per your requirements. Below screen shots depicts my patterns:
  ![Origin pattern](./images/email_rule_2.png)
  ![Destnation pattern](./images/email_rule_3.png)


pkgId: fc4ae17969b1ecbce24c6ebc0f9507543811bc5dacaf6bbfb64e2f0321fdd6d3
name: python-amazon-textract-overlayer
arch: src
version: 0.0.12
epoch: 0
release: 1
summary: Amazon Textract Overlay tools
url: https://github.com/aws-samples/amazon-textract-textractor/tree/master/overlayer
rpm_license: Apache License Version 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-textract-overlayer-0.0.12-1.src.rpm
checksum_type: sha256
description:
  amazon-textract-overlayer provides functions to help overlay bounding boxes on documents.



  ```bash
  > python -m pip install amazon-textract-overlayer
  ```

  Make sure your environment is setup with AWS credentials through configuration files or environment variables or an attached role. (https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html)



  Primary method provided is get_bounding_boxes which returns bounding boxes based on the Textract_Type passed in.
  Mostly taken from the ```amazon-textract``` command from the package ```amazon-textract-helper```.

  This will return the bounding boxes for WORD and CELL data types.

  ```python
  from textractoverlayer.t_overlay import DocumentDimensions, get_bounding_boxes
  from textractcaller.t_call import Textract_Features, Textract_Types, call_textract

  doc = call_textract(input_document=input_document, features=features)

  document_dimension:DocumentDimensions = DocumentDimensions(doc_width=image.size[0], doc_height=image.size[1])
  overlay=[Textract_Types.WORD, Textract_Types.CELL]

  bounding_box_list = get_bounding_boxes(textract_json=doc, document_dimensions=document_dimension, overlay_features=overlay)
  ```

  The actual overlay drawing of bounding boxes for images is in the ```amazon-textract``` command from the package ```amazon-textract-helper``` and looks like this:

  ```python
  from PIL import Image, ImageDraw

  image = Image.open(input_document)
  rgb_im = image.convert('RGB')
  draw = ImageDraw.Draw(rgb_im)


  for bbox in bounding_box_list:
      draw.rectangle(xy=[bbox.xmin, bbox.ymin, bbox.xmax, bbox.ymax], outline=(128, 128, 0), width=2)

  rgb_im.show()
  ```

  The draw bounding boxes within PDF documents the following code can be used:

  ```python
  import fitz


  file_path = "<<replace with the local path to your pdf file>>"
  doc = fitz.open(file_path)




  for p, page in enumerate(doc):
      p += 1
      for bbox in bounding_box_list:
          if bbox.page_number == p:
              page.draw_rect(
                  [bbox.xmin, bbox.ymin, bbox.xmax, bbox.ymax], color=(0, 1, 0), width=2
              )


  doc.save("<<local path for output file>>")

  ```


pkgId: 329b02e5cfa77f0e5c6b7f24c51a3c9d18bcc63696441a442e195c8eac8d1994
name: python-amazon-textract-pipeline-pagedimensions
arch: src
version: 0.0.9
epoch: 0
release: 1
summary: Amazon Textract Pipeline Component to add page dimensions to page block types
url: https://github.com/aws-samples/amazon-textract-textractor/tree/master/tpipelinepagedimensions
rpm_license: Apache License Version 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-textract-pipeline-pagedimensions-0.0.9-1.src.rpm
checksum_type: sha256
description:
  Provides functions to add page dimensions with doc_width and doc_height to the Textract JSON schema for the PAGE blocks under the custom attribute in the form of:

  e. g.

  ```
  {'PageDimension': {'doc_width': 1549.0, 'doc_height': 370.0} }
  ```



  ```bash
  > python -m pip install amazon-textract-pipeline-pagedimensions
  ```

  Make sure your environment is setup with AWS credentials through configuration files or environment variables or an attached role. (https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html)





  sample uses amazon-textract-caller amazon-textract-pipeline-pagedimensions

  ```bash
  python -m pip install amazon-textract-caller
  ```

  ```python
  from textractpagedimensions.t_pagedimensions import add_page_dimensions
  from textractcaller.t_call import call_textract
  from trp.trp2 import TDocument, TDocumentSchema

  j = call_textract(input_document='<path to some image file>')
  t_document: TDocument = TDocumentSchema().load(j)
  add_page_dimensions(t_document=t_document, input_document=input_file)
  print(t_document.pages[0].custom['PageDimension'])





  ```



  Together with the Amazon Textract Helper and Amazon Textract Response Parser, we can build a pipeline that includes information about PageDimension and Orientation of pages
  as a short demonstration on the information that is added to the Textract JSON.

  ```bash
  > python -m pip install amazon-textract-helper amazon-textract-response-parser amazon-textract-pipeline-pagedimensions
  > amazon-textract --input-document "s3://amazon-textract-public-content/blogs/2-pager-different-dimensions.pdf" | amazon-textract-pipeline-pagedimensions --input-document "s3://amazon-textract-public-content/blogs/2-pager-different-dimensions.pdf"  | amazon-textract-pipeline --components add_page_orientation | jq '.Blocks[] | select(.BlockType=="PAGE") | .Custom'

  {
    "PageDimension": {
      "doc_width": 1549,
      "doc_height": 370
    },
    "Orientation": 0
  }
  {
    "PageDimension": {
      "doc_width": 1079,
      "doc_height": 505
    },
    "Orientation": 0
  }
  ```


pkgId: f16c2d9fa1cddbd149be6f5b4a24ba84824ccdebeaa007093820f373d450ee77
name: python-amazon-textract-prettyprinter
arch: src
version: 0.1.10
epoch: 0
release: 1
summary: Amazon Textract Helper tools for pretty printing
url: https://github.com/aws-samples/amazon-textract-textractor/tree/master/prettyprinter
rpm_license: Apache License Version 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-textract-prettyprinter-0.1.10-1.src.rpm
checksum_type: sha256
description:
  Provides functions to format the output received from Textract in more easily consumable formats incl. CSV or Markdown.
  amazon-textract-prettyprinter



  ```bash
  > python -m pip install amazon-textract-prettyprinter
  ```

  Make sure your environment is setup with AWS credentials through configuration files or environment variables or an attached role. (https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html)






  ```python
  from textractcaller.t_call import call_textract, Textract_Features
  from textractprettyprinter.t_pretty_print import Pretty_Print_Table_Format, Textract_Pretty_Print, get_string

  textract_json = call_textract(input_document=input_document, features=[Textract_Features.FORMS, Textract_Features.TABLES])
  print(get_string(textract_json=textract_json,
                 table_format=Pretty_Print_Table_Format.csv,
                 output_type=[Textract_Pretty_Print.TABLES, Textract_Pretty_Print.FORMS]))
  ```



  ```python
  from textractcaller.t_call import call_textract, Textract_Features
  from textractprettyprinter.t_pretty_print import Textract_Pretty_Print, get_string

  textract_json = call_textract(input_document=input_document, features=[Textract_Features.TABLES])
  get_string(textract_json=textract_json, output_type=Textract_Pretty_Print.TABLES)
  ```



  ```python
  from textractcaller.t_call import call_textract, Textract_Features
  from textractprettyprinter.t_pretty_print import Textract_Pretty_Print, get_string

  textract_json = call_textract(input_document=input_document, features=[Textract_Features.FORMS, Textract_Features.TABLES])
  get_tables_string(textract_json=textract_json, table_format=Pretty_Print_Table_Format.latex)
  ```



  Generates a dictionary of linearized text from the Textract JSON response with LAYOUT, and optionally writes linearized plain text files to local file system or Amazon S3. It can take either per page JSON from AnalyzeDocument API, or a single combined JSON with all the pages created from StartDocumentAnalysis output JSONs.

  ```python
  from textractcaller.t_call import call_textract, Textract_Features
  from textractprettyprinter.t_pretty_print import get_text_from_layout_json

  textract_json = call_textract(input_document=input_document, features=[Textract_Features.LAYOUT, Textract_Features.TABLES])
  layout = get_text_from_layout_json(textract_json=textract_json)

  full_text = layout[1]
  print(full_text)
  ```

  In addition to `textract_json`, the `get_text_from_layout_json` function can take the following additional parameters

  - `table_format` (str, optional): Format of tables within the document. Supports all python-tabulate table formats. See [tabulate](https://github.com/gregbanks/python-tabulate) for supported table formats. Defaults to `grid`.
  - `exclude_figure_text` (bool, optional): If set to True, excludes text extracted from figures in the document. Defaults to `False`.
  - `exclude_page_header` (bool, optional): If set to True, excludes the page header from the linearized text. Defaults to `False`.
  - `exclude_page_footer` (bool, optional): If set to True, excludes the page footer from the linearized text. Defaults to `False`.
  - `exclude_page_number` (bool, optional): If set to True, excludes the page number from the linearized text. Defaults to `False`.
  - `skip_table` (bool, optional): If set to True, skips including the table in the linearized text. Defaults to `False`.
  - `save_txt_path` (str, optional): Path to save the output linearized text to files. Either a local file system path or Amazon S3 path can be specified in `s3://bucket_name/prefix/` format. Files will be saved with `<page_number>.txt` naming convention.
  - `generate_markdown` (bool, optional): If set to `True`, generates markdown formatted linearized text. Defaults to `False`.




  Customers asked for the abilility to generate the layout.csv format, which can be downloaded when testing documents in the AWS Web Console.
  The method ``get_layout_csv_from_trp2```` generates for each page a list of the entries:

  'Page number,'Layout,'Text,'Reading Order,'Confidence score
  * Page number: starting at 1, incrementing for eac page
  * Layout: the BlockType + a number indicating the sequence for this BlockType starting at 1 and for LAYOUT_LIST elements the string:  "- part of LAYOUT_LIST (index)" is added
  * Text: except for LAYOUT_LIST and LAYOUT_FIGURE the underlying text
  * Reading Order: increasing int for each LAYOUT element starting with 0
  * Confidence score: confidence in this being a LAYOUT element

  this can be used to generate a CSV (or another format). Below a sample how to generate a CSV.

  ```python


  from textractprettyprinter import get_layout_csv_from_trp2

  with open(<some_test_file>) as input_fp:
      trp2_doc: TDocument = TDocumentSchema().load(json.load(input_fp))
      layout_csv = get_layout_csv_from_trp2(trp2_doc)
      csv_output = io.StringIO()
      csv_writer = csv.writer(csv_output, delimiter=",", quotechar='"', quoting=csv.QUOTE_MINIMAL)
      for page in layout_csv:
          csv_writer.writerows(page)
      print(csv_output)
  ```

  Sample output
  |Page number|Layout|Text|Reading Order|BlockType|Confidence score|
  | - | -------------------------------------- | --------------------------------- | -- | --------------------- | ------------ |
  | 1 | LAYOUT_SECTION_HEADER 1                | Amazing Headline!...              | 0  | LAYOUT_SECTION_HEADER | 81.25        |
  | 1 | LAYOUT_TEXT 1                          | Lorem ipsum dolor sit amet, co... | 1  | LAYOUT_TEXT           | 99.755859375 |
  | 1 | LAYOUT_SECTION_HEADER 2                | Unbelievable stuff...             | 2  | LAYOUT_SECTION_HEADER | 90.478515625 |
  | 1 | LAYOUT_TEXT 2                          | Ut ultrices felis vel mi susci... | 3  | LAYOUT_TEXT           | 98.486328125 |
  | 1 | LAYOUT_LIST 1                          |                                   | 4  | LAYOUT_LIST           | 97.16796875  |
  | 1 | LAYOUT_TEXT 3 - part of LAYOUT_LIST 1  | Priority list item 1...           | 5  | LAYOUT_TEXT           | 97.8515625   |
  | 1 | LAYOUT_TEXT 4 - part of LAYOUT_LIST 1  | Priority list item 2...           | 6  | LAYOUT_TEXT           | 98.095703125 |
  | 1 | LAYOUT_TEXT 5 - part of LAYOUT_LIST 1  | Another list item 3...            | 7  | LAYOUT_TEXT           | 98.095703125 |
  | 1 | LAYOUT_TEXT 6 - part of LAYOUT_LIST 1  | And a total optional list item... | 8  | LAYOUT_TEXT           | 98.73046875  |
  | 1 | LAYOUT_LIST 2                          |                                   | 9  | LAYOUT_LIST           | 69.53125     |
  | 1 | LAYOUT_TEXT 7 - part of LAYOUT_LIST 2  | 1. But we...                      | 10 | LAYOUT_TEXT           | 95.751953125 |
  | 1 | LAYOUT_TEXT 8 - part of LAYOUT_LIST 2  | 2. can also...                    | 11 | LAYOUT_TEXT           | 96.923828125 |
  | 1 | LAYOUT_TEXT 9 - part of LAYOUT_LIST 2  | 3. do numbered...                 | 12 | LAYOUT_TEXT           | 97.36328125  |
  | 1 | LAYOUT_TEXT 10 - part of LAYOUT_LIST 2 | 4. lists...                       | 13 | LAYOUT_TEXT           | 96.6796875   |
  | 1 | LAYOUT_TEXT 11                         | congue ac. Phasellus mollis co... | 14 | LAYOUT_TEXT           | 96.044921875 |
  | 1 | LAYOUT_TEXT 12                         | Quisque a elementum diam. Null... | 15 | LAYOUT_TEXT           | 96.484375    |
  | 1 | LAYOUT_TEXT 13                         | Table Caption 1...                | 16 | LAYOUT_TEXT           | 86.865234375 |
  | 1 | LAYOUT_TABLE 1                         | Date Description Amount 12-12-... | 17 | LAYOUT_TABLE          | 96.435546875 |
  | 1 | LAYOUT_TEXT 14                         | Quisque dapibus varius ipsum, ... | 18 | LAYOUT_TEXT           | 93.06640625  |
  | 1 | LAYOUT_FIGURE 1                        |                                   | 19 | LAYOUT_FIGURE         | 94.3359375   |
  | 1 | LAYOUT_TEXT 15                         | Figure Caption 1...               | 20 | LAYOUT_TEXT           | 63.18359375  |


pkgId: 8658d3ee5cfd03e89631bc66313834facf4100ddaf27055bc0c7b75c26810cdb
name: python-amazon-textract-response-parser
arch: src
version: 1.0.3
epoch: 0
release: 1
summary: Easily parse JSON returned by Amazon Textract.
url: https://github.com/aws-samples/amazon-textract-response-parser
rpm_license: Apache License Version 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-textract-response-parser-1.0.3-1.src.rpm
checksum_type: sha256
description:
  You can use Textract response parser library to easily parser JSON returned by Amazon Textract. Library parses JSON and provides programming language specific constructs to work with different parts of the document. [textractor](https://github.com/aws-samples/amazon-textract-textractor) is an example of PoC batch processing tool that takes advantage of Textract response parser library and generate output in multiple formats.



  ```
  python -m pip install amazon-textract-response-parser
  ```





  Based on the [marshmallow](https://marshmallow.readthedocs.io/en/stable/) framework, the serializer/deserializer allows for creating an object represenation of the Textract JSON response.


  ```python

  from trp.trp2 import TDocument, TDocumentSchema
  t_doc = TDocumentSchema().load(j)
  ```


  ```python
  from trp.trp2 import TDocument, TDocumentSchema
  t_doc = TDocumentSchema().dump(t_doc)
  ```


  ```python

  from trp.trp2_analyzeid import TAnalyzeIdDocument, TAnalyzeIdDocumentSchema
  t_doc = TAnalyzeIdDocumentSchema().load(json.loads(j))
  ```

  ```python
  from trp.trp2_analyzeid import TAnalyzeIdDocument, TAnalyzeIdDocumentSchema
  t_doc = TAnalyzeIdDocumentSchema().dump(t_doc)
  ```




  We added some commonly requested features as easily consumable components that modify the Textract JSON Schema and ideally don't require big changes to any  existing workflow.



  By default Textract does not put the elements identified in an order in the JSON response.

  The sample implementation ```order_blocks_by_geo``` of a function using the Serializer/Deserializer shows how to change the structure and order the elements while maintaining the schema. This way no change is necessary to integrate with existing processing.

  ```bash

  python -m pip install amazon-textract-caller
  ```

  ```python
  from textractcaller.t_call import call_textract, Textract_Features
  from trp.trp2 import TDocument, TDocumentSchema
  from trp.t_pipeline import order_blocks_by_geo
  import trp
  import json

  j = call_textract(input_document="path_to_some_document (PDF, JPEG, PNG)", features=[Textract_Features.FORMS, Textract_Features.TABLES])

  t_doc = TDocumentSchema().load(j)

  ordered_doc = order_blocks_by_geo(t_doc)

  trp_doc = trp.Document(TDocumentSchema().dump(ordered_doc))
  ```



  Amazon Textract supports all in-plane document rotations. However the response does not include a single number for the degree, but instead each word and line does have polygon points which can be used to calculate the degree of rotation. The following code adds this information as a custom field to Amazon Textract JSON response.

  ```python
  from trp.t_pipeline import add_page_orientation
  import trp.trp2 as t2
  import trp as t1


  j = <call_textract(input_document="path_to_some_document (PDF, JPEG, PNG)") or your JSON dict>
  t_document: t2.TDocument = t2.TDocumentSchema().load(j)
  t_document = add_page_orientation(t_document)

  doc = t1.Document(t2.TDocumentSchema().dump(t_document))

  for page in doc.pages:
      print(page.custom['PageOrientationBasedOnWords'])
  ```



  The amazon-textract-response-parser package also includes a command line tool to test pipeline components like the add_page_orientation or the order_blocks_by_geo.

  Here is one example of the usage (in combination with the ```amazon-textract``` command from amazon-textract-helper and the ```jq``` tool (https://stedolan.github.io/jq/))

  ```bash
  > amazon-textract --input-document "s3://somebucket/some-multi-page-pdf.pdf" | amazon-textract-pipeline --components add_page_orientation | jq '.Blocks[] | select(.BlockType=="PAGE") | .Custom'm

  {
    "Orientation": 7
  }
  {
    "Orientation": 11
  }
  ...
  {
    "Orientation": -7
  }
  {
    "Orientation": 0
  }
  ```




  Sometimes tables start on one page and continue across the next page or pages. This component identifies if that is the case based on the number of columns and if a header is present on the subsequent table and can modify the output Textract JSON schema for down-stream processing. Other custom-logic is possible to develop for specific use cases.

  The MergeOptions.MERGE combines the tables and makes them appear as one for post processing, with the drawback that the geometry information is not accuracy any longer. So overlaying with bounding boxes will not be accuracy.

  The MergeOptions.LINK maintains the geometric structure and enriches the table information with links between the table elements. There is a custom['previus_table'] and custom['next_table'] attribute added to the TABLE blocks in the Textract JSON schema.

  Usage is simple

  ```python
  from trp.t_pipeline import pipeline_merge_tables
  import trp.trp2 as t2

  j = <call_textract(input_document="path_to_some_document (PDF, JPEG, PNG)") or your JSON dict>
  t_document: t2.TDocument = t2.TDocumentSchema().load(j)
  t_document = pipeline_merge_tables(t_document, MergeOptions.MERGE, None, HeaderFooterType.NONE)
  ```

  Using from command line example

  ```bash

  cat src-python/tests/data/gib_multi_page_table_merge.json | amazon-textract-pipeline --components merge_tables | amazon-textract --stdin --pretty-print TABLES

  ```



  It can be useful for some use cases to validate the confidence score for a given KEY or the VALUE from an Analyze action with FORMS feature result.

  The Confidence property of a BlockType 'KEY_VALUE_SET' expresses the confidence in this particular prediction being a KEY or a VALUE, but not the confidence of the underlying text value.

  Simplified example:

  ```json
  {
      "Confidence": 95.5,
      "Geometry": {<...>},
      "Id": "v1",
      "Relationships": [{"Type": "CHILD", "Ids": ["c1"]}],
      "EntityTypes": ["VALUE"],
      "BlockType": "KEY_VALUE_SET"
  },
  {
      "Confidence": 99.2610092163086,
      "TextType": "PRINTED",
      "Geometry": {<...>},
      "Id": "c1",
      "Text": "2021-Apr-08",
      "BlockType": "WORD"
  },
  ```

  In this example the confidence in the prediction of the VALUE to be an actual value in a key/value relationship is 95.5.

  The confidence in the actual text representation is 99.2610092163086.
  For simplicity in this example the value consists of just one word, but is not limited to that and could contain multiple words.

  The KV_OCR_Confidence pipeline component adds confidence scores for the underlying OCR to the JSON. After executing the example JSON will look like this:

  ```json
  {
      "Confidence": 95.5,
      "Geometry": {<...>},
      "Id": "v1",
      "Relationships": [{"Type": "CHILD", "Ids": ["c1"]}],
      "EntityTypes": ["VALUE"],
      "BlockType": "KEY_VALUE_SET",
      "Custom": {"OCRConfidence": {"mean": 99.2610092163086, "min": 99.2610092163086}}
  },
  {
      "Confidence": 99.2610092163086,
      "TextType": "PRINTED",
      "Geometry": {<...>},
      "Id": "c1",
      "Text": "2021-Apr-08",
      "BlockType": "WORD"
  },
  ```

  Usage is simple

  ```python
  from trp.t_pipeline import add_kv_ocr_confidence
  import trp.trp2 as t2

  j = <call_textract(input_document="path_to_some_document (PDF, JPEG, PNG)") or your JSON dict>
  t_document: t2.TDocument = t2.TDocumentSchema().load(j)
  t_document = add_kv_ocr_confidence(t_document)

  ```

  Using from command line example and validating the output:

  ```bash

  cat "src-python/tests/data/employment-application.json" | amazon-textract-pipeline --components kv_ocr_confidence | jq '.Blocks[] | select(.BlockType=="KEY_VALUE_SET") '
  ```



  ```python
  from trp import Document
  doc = Document(response)


  for page in doc.pages:
      
      for line in page.lines:
          print("Line: {}--{}".format(line.text, line.confidence))
          for word in line.words:
              print("Word: {}--{}".format(word.text, word.confidence))

      
      for table in page.tables:
          for r, row in enumerate(table.rows):
              for c, cell in enumerate(row.cells):
                  print("Table[{}][{}] = {}-{}".format(r, c, cell.text, cell.confidence))

      
      for field in page.form.fields:
          print("Field: Key: {}, Value: {}".format(field.key.text, field.value.text))

      
      key = "Phone Number:"
      field = page.form.getFieldByKey(key)
      if(field):
          print("Field: Key: {}, Value: {}".format(field.key, field.value))

      
      key = "address"
      fields = page.form.searchFieldsByKey(key)
      for field in fields:
          print("Field: Key: {}, Value: {}".format(field.key, field.value))

  ```



  - Clone the repo and run pytest

  ```bash
  git clone https://github.com/aws-samples/amazon-textract-response-parser.git
  cd amazon-textract-response-parser
  python -m venv virtualenv
  virtualenv/bin/activate

  python -m pip install --upgrade pip setuptools
  python -m pip install -e .[dev]
  pytest
  ```





  - [Large scale document processing with Amazon Textract - Reference Architecture](https://github.com/aws-samples/amazon-textract-serverless-large-scale-document-processing)
  - [Batch processing tool](https://github.com/aws-samples/amazon-textract-textractor)
  - [Code samples](https://github.com/aws-samples/amazon-textract-code-samples)



  This sample code is made available under the Apache License Version 2.0. See the LICENSE file.


pkgId: a37f9b41d2904da1cc33ddc84401e87bdcd45f7ace9b35282ebf252f033d7a6c
name: python-amazon-textract-textractor
arch: src
version: 1.8.3
epoch: 0
release: 1
summary: A package to use AWS Textract services.
url: https://github.com/aws-samples/amazon-textract-textractor
rpm_license: Apache 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-textract-textractor-1.8.3-1.src.rpm
checksum_type: sha256
description:
  ![Textractor](https://raw.githubusercontent.com/aws-samples/amazon-textract-textractor/5716c52e8a39c063f43e058e1637e4984a4b2da4/docs/source/textractor_cropped.png)

  [![Tests](https://github.com/aws-samples/amazon-textract-textractor/actions/workflows/tests.yml/badge.svg)](https://github.com/aws-samples/amazon-textract-textractor/actions/workflows/tests.yml) [![Documentation](https://github.com/aws-samples/amazon-textract-textractor/actions/workflows/documentation.yml/badge.svg)](https://aws-samples.github.io/amazon-textract-textractor/) [![PyPI version](https://badge.fury.io/py/amazon-textract-textractor.svg)](https://pypi.org/project/amazon-textract-textractor/) [![Downloads](https://static.pepy.tech/badge/amazon-textract-textractor/month)](https://pepy.tech/project/amazon-textract-textractor) [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)

  **Textractor** is a python package created to seamlessly work with [Amazon Textract](https://docs.aws.amazon.com/textract/latest/dg/what-is.html) a document intelligence service offering text recognition, table extraction, form processing, and much more. Whether you are making a one-off script or a complex distributed document processing pipeline, Textractor makes it easy to use Textract.

  If you are looking for the other amazon-textract-* packages, you can find them using the links below:

  - [amazon-textract-caller](https://github.com/aws-samples/amazon-textract-textractor/tree/master/caller) (to simplify calling Amazon Textract without additional dependencies)
  - [amazon-textract-response-parser](https://pypi.org/project/amazon-textract-response-parser/) (to parse the JSON response returned by Textract APIs)
  - [amazon-textract-overlayer](https://github.com/aws-samples/amazon-textract-textractor/tree/master/overlayer) (to draw bounding boxes around the document entities on the document image)
  - [amazon-textract-prettyprinter](https://github.com/aws-samples/amazon-textract-textractor/tree/master/prettyprinter) (convert Amazon Textract response to CSV, text, markdown, ...)
  - [amazon-textract-geofinder](https://github.com/aws-samples/amazon-textract-textractor/tree/master/tpipelinegeofinder) (extract specific information from document with methods that help navigate the document using geometry and relations, e. g. hierarchical key/value pairs)



  Textractor is available on PyPI and can be installed with `pip install amazon-textract-textractor`. By default this will install the minimal version of Textractor which is suitable for lambda execution. The following extras can be used to add features:

  - `pandas` (`pip install "amazon-textract-textractor[pandas]"`) installs pandas which is used to enable DataFrame and CSV exports.
  - `pdfium` (`pip install amazon-textract-textractor[pdfium]`) includes `pypdfium2` and is the recommended way to enable PDF rasterization in Textractor. Note that this is **not** necessary to call Textract with a PDF file.
  - `pdf` (`pip install amazon-textract-textractor[pdf]`) includes `pdf2image` and is an additional way to enable PDF rasterization in Textractor. Note that this is **not** necessary to call Textract with a PDF file.
  - `torch` (`pip install "amazon-textract-textractor[torch]"`) includes `sentence_transformers` for better word search and matching. This will work on CPU but be noticeably slower than non-machine learning based approaches.
  - `dev` (`pip install "amazon-textract-textractor[dev]"`) includes all the dependencies above and everything else needed to test the code.

  You can pick several extras by separating the labels with commas like this `pip install "amazon-textract-textractor[pdf,torch]"`.



  Generated documentation for the latest released version can be accessed here: [aws-samples.github.io/amazon-textract-textractor/](https://aws-samples.github.io/amazon-textract-textractor/)



  While a collection of simplistic examples is presented here, the documentation has a much [larger collection of examples](https://aws-samples.github.io/amazon-textract-textractor/examples.html) with specific case studies that will help you get started.



  These two lines are all you need to use Textract. The Textractor instance can be reused across multiple requests for both synchronous and asynchronous requests.

  ```py
  from textractor import Textractor

  extractor = Textractor(profile_name="default")
  ```



  ```py

  document = extractor.detect_document_text(file_source="tests/fixtures/single-page-1.png")
  print(document.lines)

  ```



  ```py
  from textractor.data.constants import TextractFeatures

  document = extractor.analyze_document(
  	file_source="tests/fixtures/form.png",
  	features=[TextractFeatures.TABLES]
  )

  document.tables[0].to_excel("output.xlsx")
  ```



  ```py
  from textractor.data.constants import TextractFeatures

  document = extractor.analyze_document(
  	file_source="tests/fixtures/form.png",
  	features=[TextractFeatures.FORMS]
  )

  document.get("email")

  ```



  ```py
  document = extractor.analyze_id(file_source="tests/fixtures/fake_id.png")
  print(document.identity_documents[0].get("FIRST_NAME"))

  ```



  ```py
  document = extractor.analyze_expense(file_source="tests/fixtures/receipt.jpg")
  print(document.expense_documents[0].summary_fields.get("TOTAL")[0].text)

  ```

  If your use case was not covered here or if you are looking for asynchronous usage examples, see [our collection of examples](https://aws-samples.github.io/amazon-textract-textractor/examples.html).



  Textractor also comes with the `textractor` script, which supports calling, printing and overlaying directly in the terminal.

  `textractor analyze-document tests/fixtures/amzn_q2.png output.json --features TABLES --overlay TABLES`

  ![overlay_example](images/amzn.png)

  See [the documentation](https://aws-samples.github.io/amazon-textract-textractor/commandline.html) for more examples.



  The package comes with tests that call the production Textract APIs. Running the tests will incur charges to your AWS account.



  This library was made possible by the work of Srividhya Radhakrishna ([@srividh-r](https://github.com/srividh-r)).



  See [CONTRIBUTING.md](CONTRIBUTING.md)



  Textractor can be cited using:

  ```
  @software{amazontextractor,
    author = {Belval, Edouard and Delteil, Thomas and Schade, Martin and Radhakrishna, Srividhya},
    title = {{Amazon Textractor}},
    url = {https://github.com/aws-samples/amazon-textract-textractor},
    version = {1.8.3},
    year = {2024}
  }
  ```

  Or using the CITATION.cff file.



  This library is licensed under the Apache 2.0 License.

  <sub><sup>Excavator image by macrovector on Freepik</sub></sup>


pkgId: ba8370999e7ec61b53559dbd65be15dac24757c8486d0d6de16cced30d218b5d
name: python-amazon-textract-textractor
arch: src
version: 1.8.4
epoch: 0
release: 1
summary: A package to use AWS Textract services.
url: https://github.com/aws-samples/amazon-textract-textractor
rpm_license: Apache 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-textract-textractor-1.8.4-1.src.rpm
checksum_type: sha256
description:
  ![Textractor](https://raw.githubusercontent.com/aws-samples/amazon-textract-textractor/5716c52e8a39c063f43e058e1637e4984a4b2da4/docs/source/textractor_cropped.png)

  [![Tests](https://github.com/aws-samples/amazon-textract-textractor/actions/workflows/tests.yml/badge.svg)](https://github.com/aws-samples/amazon-textract-textractor/actions/workflows/tests.yml) [![Documentation](https://github.com/aws-samples/amazon-textract-textractor/actions/workflows/documentation.yml/badge.svg)](https://aws-samples.github.io/amazon-textract-textractor/) [![PyPI version](https://badge.fury.io/py/amazon-textract-textractor.svg)](https://pypi.org/project/amazon-textract-textractor/) [![Downloads](https://static.pepy.tech/badge/amazon-textract-textractor/month)](https://pepy.tech/project/amazon-textract-textractor) [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)

  **Textractor** is a python package created to seamlessly work with [Amazon Textract](https://docs.aws.amazon.com/textract/latest/dg/what-is.html) a document intelligence service offering text recognition, table extraction, form processing, and much more. Whether you are making a one-off script or a complex distributed document processing pipeline, Textractor makes it easy to use Textract.

  If you are looking for the other amazon-textract-* packages, you can find them using the links below:

  - [amazon-textract-caller](https://github.com/aws-samples/amazon-textract-textractor/tree/master/caller) (to simplify calling Amazon Textract without additional dependencies)
  - [amazon-textract-response-parser](https://pypi.org/project/amazon-textract-response-parser/) (to parse the JSON response returned by Textract APIs)
  - [amazon-textract-overlayer](https://github.com/aws-samples/amazon-textract-textractor/tree/master/overlayer) (to draw bounding boxes around the document entities on the document image)
  - [amazon-textract-prettyprinter](https://github.com/aws-samples/amazon-textract-textractor/tree/master/prettyprinter) (convert Amazon Textract response to CSV, text, markdown, ...)
  - [amazon-textract-geofinder](https://github.com/aws-samples/amazon-textract-textractor/tree/master/tpipelinegeofinder) (extract specific information from document with methods that help navigate the document using geometry and relations, e. g. hierarchical key/value pairs)



  Textractor is available on PyPI and can be installed with `pip install amazon-textract-textractor`. By default this will install the minimal version of Textractor which is suitable for lambda execution. The following extras can be used to add features:

  - `pandas` (`pip install "amazon-textract-textractor[pandas]"`) installs pandas which is used to enable DataFrame and CSV exports.
  - `pdfium` (`pip install amazon-textract-textractor[pdfium]`) includes `pypdfium2` and is the recommended way to enable PDF rasterization in Textractor. Note that this is **not** necessary to call Textract with a PDF file.
  - `pdf` (`pip install amazon-textract-textractor[pdf]`) includes `pdf2image` and is an additional way to enable PDF rasterization in Textractor. Note that this is **not** necessary to call Textract with a PDF file.
  - `torch` (`pip install "amazon-textract-textractor[torch]"`) includes `sentence_transformers` for better word search and matching. This will work on CPU but be noticeably slower than non-machine learning based approaches.
  - `dev` (`pip install "amazon-textract-textractor[dev]"`) includes all the dependencies above and everything else needed to test the code.

  You can pick several extras by separating the labels with commas like this `pip install "amazon-textract-textractor[pdf,torch]"`.



  Generated documentation for the latest released version can be accessed here: [aws-samples.github.io/amazon-textract-textractor/](https://aws-samples.github.io/amazon-textract-textractor/)



  While a collection of simplistic examples is presented here, the documentation has a much [larger collection of examples](https://aws-samples.github.io/amazon-textract-textractor/examples.html) with specific case studies that will help you get started.



  These two lines are all you need to use Textract. The Textractor instance can be reused across multiple requests for both synchronous and asynchronous requests.

  ```py
  from textractor import Textractor

  extractor = Textractor(profile_name="default")
  ```



  ```py

  document = extractor.detect_document_text(file_source="tests/fixtures/single-page-1.png")
  print(document.lines)

  ```



  ```py
  from textractor.data.constants import TextractFeatures

  document = extractor.analyze_document(
  	file_source="tests/fixtures/form.png",
  	features=[TextractFeatures.TABLES]
  )

  document.tables[0].to_excel("output.xlsx")
  ```



  ```py
  from textractor.data.constants import TextractFeatures

  document = extractor.analyze_document(
  	file_source="tests/fixtures/form.png",
  	features=[TextractFeatures.FORMS]
  )

  document.get("email")

  ```



  ```py
  document = extractor.analyze_id(file_source="tests/fixtures/fake_id.png")
  print(document.identity_documents[0].get("FIRST_NAME"))

  ```



  ```py
  document = extractor.analyze_expense(file_source="tests/fixtures/receipt.jpg")
  print(document.expense_documents[0].summary_fields.get("TOTAL")[0].text)

  ```

  If your use case was not covered here or if you are looking for asynchronous usage examples, see [our collection of examples](https://aws-samples.github.io/amazon-textract-textractor/examples.html).



  Textractor also comes with the `textractor` script, which supports calling, printing and overlaying directly in the terminal.

  `textractor analyze-document tests/fixtures/amzn_q2.png output.json --features TABLES --overlay TABLES`

  ![overlay_example](images/amzn.png)

  See [the documentation](https://aws-samples.github.io/amazon-textract-textractor/commandline.html) for more examples.



  The package comes with tests that call the production Textract APIs. Running the tests will incur charges to your AWS account.



  This library was made possible by the work of Srividhya Radhakrishna ([@srividh-r](https://github.com/srividh-r)).



  See [CONTRIBUTING.md](CONTRIBUTING.md)



  Textractor can be cited using:

  ```
  @software{amazontextractor,
    author = {Belval, Edouard and Delteil, Thomas and Schade, Martin and Radhakrishna, Srividhya},
    title = {{Amazon Textractor}},
    url = {https://github.com/aws-samples/amazon-textract-textractor},
    version = {1.8.4},
    year = {2024}
  }
  ```

  Or using the CITATION.cff file.



  This library is licensed under the Apache 2.0 License.

  <sub><sup>Excavator image by macrovector on Freepik</sub></sup>


pkgId: bbd96686c89f86867826e7b480de8b1b60b56da96ba753e60d9418ae203b060e
name: python-amazon-textract-textractor
arch: src
version: 1.8.5
epoch: 0
release: 1
summary: A package to use AWS Textract services.
url: https://github.com/aws-samples/amazon-textract-textractor
rpm_license: Apache 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-textract-textractor-1.8.5-1.src.rpm
checksum_type: sha256
description:
  ![Textractor](https://raw.githubusercontent.com/aws-samples/amazon-textract-textractor/5716c52e8a39c063f43e058e1637e4984a4b2da4/docs/source/textractor_cropped.png)

  [![Tests](https://github.com/aws-samples/amazon-textract-textractor/actions/workflows/tests.yml/badge.svg)](https://github.com/aws-samples/amazon-textract-textractor/actions/workflows/tests.yml) [![Documentation](https://github.com/aws-samples/amazon-textract-textractor/actions/workflows/documentation.yml/badge.svg)](https://aws-samples.github.io/amazon-textract-textractor/) [![PyPI version](https://badge.fury.io/py/amazon-textract-textractor.svg)](https://pypi.org/project/amazon-textract-textractor/) [![Downloads](https://static.pepy.tech/badge/amazon-textract-textractor/month)](https://pepy.tech/project/amazon-textract-textractor) [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)

  **Textractor** is a python package created to seamlessly work with [Amazon Textract](https://docs.aws.amazon.com/textract/latest/dg/what-is.html) a document intelligence service offering text recognition, table extraction, form processing, and much more. Whether you are making a one-off script or a complex distributed document processing pipeline, Textractor makes it easy to use Textract.

  If you are looking for the other amazon-textract-* packages, you can find them using the links below:

  - [amazon-textract-caller](https://github.com/aws-samples/amazon-textract-textractor/tree/master/caller) (to simplify calling Amazon Textract without additional dependencies)
  - [amazon-textract-response-parser](https://pypi.org/project/amazon-textract-response-parser/) (to parse the JSON response returned by Textract APIs)
  - [amazon-textract-overlayer](https://github.com/aws-samples/amazon-textract-textractor/tree/master/overlayer) (to draw bounding boxes around the document entities on the document image)
  - [amazon-textract-prettyprinter](https://github.com/aws-samples/amazon-textract-textractor/tree/master/prettyprinter) (convert Amazon Textract response to CSV, text, markdown, ...)
  - [amazon-textract-geofinder](https://github.com/aws-samples/amazon-textract-textractor/tree/master/tpipelinegeofinder) (extract specific information from document with methods that help navigate the document using geometry and relations, e. g. hierarchical key/value pairs)



  Textractor is available on PyPI and can be installed with `pip install amazon-textract-textractor`. By default this will install the minimal version of Textractor which is suitable for lambda execution. The following extras can be used to add features:

  - `pandas` (`pip install "amazon-textract-textractor[pandas]"`) installs pandas which is used to enable DataFrame and CSV exports.
  - `pdfium` (`pip install amazon-textract-textractor[pdfium]`) includes `pypdfium2` and is the recommended way to enable PDF rasterization in Textractor. Note that this is **not** necessary to call Textract with a PDF file.
  - `pdf` (`pip install amazon-textract-textractor[pdf]`) includes `pdf2image` and is an additional way to enable PDF rasterization in Textractor. Note that this is **not** necessary to call Textract with a PDF file.
  - `torch` (`pip install "amazon-textract-textractor[torch]"`) includes `sentence_transformers` for better word search and matching. This will work on CPU but be noticeably slower than non-machine learning based approaches.
  - `dev` (`pip install "amazon-textract-textractor[dev]"`) includes all the dependencies above and everything else needed to test the code.

  You can pick several extras by separating the labels with commas like this `pip install "amazon-textract-textractor[pdf,torch]"`.



  Generated documentation for the latest released version can be accessed here: [aws-samples.github.io/amazon-textract-textractor/](https://aws-samples.github.io/amazon-textract-textractor/)



  While a collection of simplistic examples is presented here, the documentation has a much [larger collection of examples](https://aws-samples.github.io/amazon-textract-textractor/examples.html) with specific case studies that will help you get started.



  These two lines are all you need to use Textract. The Textractor instance can be reused across multiple requests for both synchronous and asynchronous requests.

  ```py
  from textractor import Textractor

  extractor = Textractor(profile_name="default")
  ```



  ```py

  document = extractor.detect_document_text(file_source="tests/fixtures/single-page-1.png")
  print(document.lines)

  ```



  ```py
  from textractor.data.constants import TextractFeatures

  document = extractor.analyze_document(
  	file_source="tests/fixtures/form.png",
  	features=[TextractFeatures.TABLES]
  )

  document.tables[0].to_excel("output.xlsx")
  ```



  ```py
  from textractor.data.constants import TextractFeatures

  document = extractor.analyze_document(
  	file_source="tests/fixtures/form.png",
  	features=[TextractFeatures.FORMS]
  )

  document.get("email")

  ```



  ```py
  document = extractor.analyze_id(file_source="tests/fixtures/fake_id.png")
  print(document.identity_documents[0].get("FIRST_NAME"))

  ```



  ```py
  document = extractor.analyze_expense(file_source="tests/fixtures/receipt.jpg")
  print(document.expense_documents[0].summary_fields.get("TOTAL")[0].text)

  ```

  If your use case was not covered here or if you are looking for asynchronous usage examples, see [our collection of examples](https://aws-samples.github.io/amazon-textract-textractor/examples.html).



  Textractor also comes with the `textractor` script, which supports calling, printing and overlaying directly in the terminal.

  `textractor analyze-document tests/fixtures/amzn_q2.png output.json --features TABLES --overlay TABLES`

  ![overlay_example](images/amzn.png)

  See [the documentation](https://aws-samples.github.io/amazon-textract-textractor/commandline.html) for more examples.



  The package comes with tests that call the production Textract APIs. Running the tests will incur charges to your AWS account.



  This library was made possible by the work of Srividhya Radhakrishna ([@srividh-r](https://github.com/srividh-r)).



  See [CONTRIBUTING.md](CONTRIBUTING.md)



  Textractor can be cited using:

  ```
  @software{amazontextractor,
    author = {Belval, Edouard and Delteil, Thomas and Schade, Martin and Radhakrishna, Srividhya},
    title = {{Amazon Textractor}},
    url = {https://github.com/aws-samples/amazon-textract-textractor},
    version = {1.8.5},
    year = {2024}
  }
  ```

  Or using the CITATION.cff file.



  This library is licensed under the Apache 2.0 License.

  <sub><sup>Excavator image by macrovector on Freepik</sub></sup>


pkgId: 20ad0c57400e4b68b1e0e3de3bea15533df171a213b641b43f3b369e643637dd
name: python-amazon-transcribe
arch: src
version: 0.6.2
epoch: 0
release: 1
summary: Async Python SDK for Amazon Transcribe Streaming
url: https://github.com/awslabs/amazon-transcribe-streaming-sdk
rpm_license: Apache License 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-transcribe-0.6.2-1.src.rpm
checksum_type: sha256
description:
  The Amazon Transcribe Streaming SDK allows users to directly interface with
  the Amazon Transcribe Streaming service and their Python programs. The goal of
  the project is to enable users to integrate directly with Amazon Transcribe
  without needing anything more than a stream of audio bytes and a basic handler.

  This project is still in early alpha so the interface is still subject to change
  and may see rapid iteration. It's highly advised to pin to strict dependencies
  if using this outside of local testing. Please note awscrt is a dependency shared
  with botocore (the core module of AWS CLI and boto3). You may need to keep
  amazon-transcribe at the latest version when installed in the same environment.




  To install from pip:
  ````bash
  python -m pip install amazon-transcribe
  ````

  To install from Github:
  ````bash
  git clone https://github.com/awslabs/amazon-transcribe-streaming-sdk.git
  cd amazon-transcribe-streaming-sdk
  python -m pip install .
  ````

  To use from your Python application, add `amazon-transcribe` as a dependency in your `requirements.txt` file.

  NOTE: This SDK is built on top of the
  [AWS Common Runtime (CRT)](https://github.com/awslabs/aws-crt-python), a collection of
  C libraries we interact with through bindings. The CRT is available on PyPI
  ([awscrt](https://pypi.org/project/awscrt/)) as precompiled wheels for common platforms
  (Linux, macOS, Windows). Non-standard operating systems may need to compile these
  libraries themselves.




  If you don't already have local credentials setup for your AWS account, you can follow
  this [guide](https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html)
  for configuring them using the AWS CLI.

  In essence you'll need one of these authentication configurations setup in order for
  the SDK to successfully resolve your API keys:

  1. Set the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY` and optionally the
  `AWS_SESSION_TOKEN` environment variables
  2. Set the `AWS_PROFILE` pointing to your AWS profile directory
  3. Configure the `[default]` profile in `~/.aws/credentials`

  For more details on the AWS shared configuration file and credential provider
  usage, check the following developer guides:

  * [Shared Config Overview](https://docs.aws.amazon.com/sdkref/latest/guide/creds-config-files.html)
  * [Shared Config Format](https://docs.aws.amazon.com/sdkref/latest/guide/file-format.html)
  * [Example Credential Setups](https://docs.aws.amazon.com/sdkref/latest/guide/usage-examples.html)


  Setup for this SDK will require either live or prerecorded audio. Full details
  on the audio input requirements can be found in the [Amazon Transcribe Streaming
  documentation](https://docs.aws.amazon.com/transcribe/latest/dg/streaming.html).


  Here's an example app to get started:
  ```python
  import asyncio




  import aiofile

  from amazon_transcribe.client import TranscribeStreamingClient
  from amazon_transcribe.handlers import TranscriptResultStreamHandler
  from amazon_transcribe.model import TranscriptEvent
  from amazon_transcribe.utils import apply_realtime_delay

  """
  Here's an example of a custom event handler you can extend to
  process the returned transcription results as needed. This
  handler will simply print the text out to your interpreter.
  """


  SAMPLE_RATE = 16000
  BYTES_PER_SAMPLE = 2
  CHANNEL_NUMS = 1


  AUDIO_PATH = "tests/integration/assets/test.wav"
  CHUNK_SIZE = 1024 * 8
  REGION = "us-west-2"


  class MyEventHandler(TranscriptResultStreamHandler):
      async def handle_transcript_event(self, transcript_event: TranscriptEvent):
          
          
          results = transcript_event.transcript.results
          for result in results:
              for alt in result.alternatives:
                  print(alt.transcript)


  async def basic_transcribe():
      
      client = TranscribeStreamingClient(region=REGION)

      
      stream = await client.start_stream_transcription(
          language_code="en-US",
          media_sample_rate_hz=SAMPLE_RATE,
          media_encoding="pcm",
      )

      async def write_chunks():
          
          
          
          async with aiofile.AIOFile(AUDIO_PATH, "rb") as afp:
              reader = aiofile.Reader(afp, chunk_size=CHUNK_SIZE)
              await apply_realtime_delay(
                  stream, reader, BYTES_PER_SAMPLE, SAMPLE_RATE, CHANNEL_NUMS
              )
          await stream.input_stream.end_stream()

      
      handler = MyEventHandler(stream.output_stream)
      await asyncio.gather(write_chunks(), handler.handle_events())


  loop = asyncio.get_event_loop()
  loop.run_until_complete(basic_transcribe())
  loop.close()
  ```



  See [CONTRIBUTING](CONTRIBUTING.md#security-issue-notifications) for more information.



  This project is licensed under the Apache-2.0 License.


pkgId: 3893532c84d78c21cb66e39b8376f3fdd7480b0ee5c10df1fc418a5b936e7ac6
name: python-amazon-wishlist-exporter
arch: src
version: 0.11.0
epoch: 0
release: 1
summary: Export Amazon wishlist metadata to JSON
url: https://github.com/nateify/amazon-wishlist-exporter
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-wishlist-exporter-0.11.0-1.src.rpm
checksum_type: sha256
description:
  amazon-wishlist-exporter.py - Scrapes Amazon wishlist data to JSON format

      usage: amazon_wishlist_exporter.py [-h] (-u URL | -f HTML_FILE) [-t STORE_TLD] [-l STORE_LOCALE] [-p] [-d] [-s SORT_KEYS] [-c] [-y] [-o OUTPUT_FILE] [--debug]

      options:
        -h, --help            show this help message and exit
        -u URL, --url URL     Amazon wishlist URL
        -f HTML_FILE, --html-file HTML_FILE
                              Amazon wishlist HTML file
        -t STORE_TLD, --store-tld STORE_TLD
                              Amazon store TLD
        -l STORE_LOCALE, --store-locale STORE_LOCALE, --locale STORE_LOCALE
                              Amazon store locale
        -p, --priority-is-localized
                              Return localized priority text instead of numeric value
        -d, --iso8601         Convert localized date strings to ISO 8601 format
        -s SORT_KEYS, --sort-keys SORT_KEYS
                              Sort key(s) for JSON output
        -c, --compact-json    Write compacted JSON
        -y, --force           Overwrite existing output file without asking
        -o OUTPUT_FILE, --output-file OUTPUT_FILE
                              Output JSON file
        --debug               Print debug messages



  Install with pip:

      pip install amazon-wishlist-exporter

  [uv](https://docs.astral.sh/uv/) is recommended to install the package in a managed environment:

      uv tool install amazon-wishlist-exporter

  For improved sorting of non-Latin or mixed scripts with the Unicode Collation Algorithm, install with the optional `icu` dependency:

      uv tool install amazon-wishlist-exporter[icu]

  PyICU may need to be built separately: https://gitlab.pyicu.org/main/pyicu#installing-pyicu

  Windows users can use pre-built wheels from here: https://github.com/cgohlke/pyicu-build/releases

  Utilizing uv:

      uv tool install amazon-wishlist-exporter --python 3.11 --with https://github.com/cgohlke/pyicu-build/releases/download/v2.13/PyICU-2.13-cp311-cp311-win_amd64.whl



  * Python >= 3.9
  * amazoncaptcha
  * babel
  * curl_cffi
  * dateparser
  * selectolax
  * price_parser
  * tenacity
  * PyICU (optional)



  * `--url`: Alternative to the above, allows whole wishlist URL as input - may need to be quoted
  * `--html`: For HTML files generated via below instructions
  * `--store-tld`: Optional for `--html`, will be guessed from filename
  * `--store-locale`: Optional - Store locale such as en_US, en_GB, de_DE, etc.
    * Not all stores support all locales.
    * If not specified, the default locale for that store will be chosen.
    * This is required for HTML files if the locale is not in the file name
  * `--sort-keys`: Optional - A single key or comma separated list of key names to sort the wishlist items by. Example `priority,name` sorts first by priority value highest to lowest, then sorts by name
    * Numeric values (such as priority, rating) are sorted largest to smallest
    * String values (such as name, comment) are sorted using the specified locale - when the package is installed with PyICU, the Unicode Collation Algorithm for the locale is used






  Excessive scraping in a short time frame will cause Amazon to serve HTTP 403 errors to the session, but will clear on its own after some time.



  This program is not capable of scraping private lists or authentication. Additionally, the "date added" field is only visible when you are authenticated (except for some old lists).

  To scrape these lists, you must use the bookmarklet provided in the below section, which will download an HTML file you can pass to the program with the `--html-file` argument.



  Using "Save As" in the browser will not create a usable HTML file for this program.

  To work around this, I created a bookmarklet which you can save and then open on any wishlist page. It will continuously scroll to the bottom until the list is fully loaded, and then save the rendered DOM to an HTML file with a filename understood by this program.

  Create a blank/dummy bookmark in your browser and replace the URL with this value:

      javascript:(function()%7Bif(window.location.host.startsWith(%22www.amazon.%22))var%20previousCount%3D-1%2CunchangedCount%3D0%2CcheckExist%3DsetInterval(function()%7Bvar%20e%3Ddocument.querySelectorAll(%22.g-item-sortable%22)%3Bif(document.getElementById(%22endOfListMarker%22)%7C%7CunchangedCount%3E%3D3)%7BclearInterval(checkExist)%3Blet%20t%3Ddocument.createElement(%22a%22)%2Cn%3Dnew%20Blob(%5Bdocument.getElementById(%22wishlist-page%22).outerHTML%5D%2C%7Btype%3A%22text%2Fhtml%22%7D)%3Bvar%20o%3Dwindow.location.host%2B%22_%22%2Bdocument.getElementById(%22listId%22).value%2B%22_%22%2Bopts.language%2B%22.html%22%3Bt.href%3DURL.createObjectURL(n)%2Ct.download%3Do%2Ct.click()%2CURL.revokeObjectURL(t.href)%7Delse%20e.length%3D%3D%3DpreviousCount%3FunchangedCount%2B%2B%3AunchangedCount%3D0%2CpreviousCount%3De.length%2C(last%3De%5Be.length-1%5D).scrollIntoView()%7D%2C2e3)%3Belse%20alert(%22This%20bookmarklet%20must%20be%20run%20on%20an%20Amazon%20site!%22)%3B%7D)()%3B

  Alternatively, you can open a console using your browser's development tools, and then run the code that way:

  ```javascript
  if(window.location.host.startsWith("www.amazon."))var previousCount=-1,unchangedCount=0,checkExist=setInterval(function(){var e=document.querySelectorAll(".g-item-sortable");if(document.getElementById("endOfListMarker")||unchangedCount>=3){clearInterval(checkExist);let t=document.createElement("a"),n=new Blob([document.getElementById("wishlist-page").outerHTML],{type:"text/html"});var o=window.location.host+"_"+document.getElementById("listId").value+"_"+opts.language+".html";t.href=URL.createObjectURL(n),t.download=o,t.click(),URL.revokeObjectURL(t.href)}else e.length===previousCount?unchangedCount++:unchangedCount=0,previousCount=e.length,(last=e[e.length-1]).scrollIntoView()},2e3);else alert("This bookmarklet must be run on an Amazon site!");
  ```

rpm_license:
  MIT License  Copyright (c) 2024 nateify  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


pkgId: 7236c0ab6e68015c76911e3f227cdd766a24f846075716da1adb2aac2b14bf0f
name: python-amazon-wishlist-exporter
arch: src
version: 0.8.0
epoch: 0
release: 1
summary: Export Amazon wishlist metadata to JSON
url: https://github.com/nateify/amazon-wishlist-exporter
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-wishlist-exporter-0.8.0-1.src.rpm
checksum_type: sha256
description:
  amazon-wishlist-exporter.py - Scrapes Amazon wishlist data to JSON format

      usage: amazon_wishlist_exporter.py [-h] (-u URL | -f HTML_FILE) [-t STORE_TLD] [-l STORE_LOCALE] [-p] [-d] [-s SORT_KEYS] [-c] [-y] [-o OUTPUT_FILE] [--debug]

      options:
        -h, --help            show this help message and exit
        -u URL, --url URL     Amazon wishlist URL
        -f HTML_FILE, --html-file HTML_FILE
                              Amazon wishlist HTML file
        -t STORE_TLD, --store-tld STORE_TLD
                              Amazon store TLD
        -l STORE_LOCALE, --store-locale STORE_LOCALE, --locale STORE_LOCALE
                              Amazon store locale
        -p, --priority-is-localized
                              Return localized priority text instead of numeric value
        -d, --iso8601         Convert localized date strings to ISO 8601 format
        -s SORT_KEYS, --sort-keys SORT_KEYS
                              Sort key(s) for JSON output
        -c, --compact-json    Write compacted JSON
        -y, --force           Overwrite existing output file without asking
        -o OUTPUT_FILE, --output-file OUTPUT_FILE
                              Output JSON file
        --debug               Print debug messages



  Install with pip:

      pip install amazon-wishlist-exporter

  [uv](https://docs.astral.sh/uv/) is recommended to install the package in a managed environment:

      uv tool install amazon-wishlist-exporter

  For improved sorting of non-Latin or mixed scripts with the Unicode Collation Algorithm, install with the optional `icu` dependency:

      uv tool install amazon-wishlist-exporter[icu]

  PyICU may need to be built separately: https://gitlab.pyicu.org/main/pyicu#installing-pyicu

  Windows users can use pre-built wheels from here: https://github.com/cgohlke/pyicu-build/releases

  Utilizing uv:

      uv tool install amazon-wishlist-exporter --python 3.11 --with https://github.com/cgohlke/pyicu-build/releases/download/v2.13/PyICU-2.13-cp311-cp311-win_amd64.whl



  * Python >= 3.9
  * amazoncaptcha
  * babel
  * curl_cffi
  * dateparser
  * selectolax
  * price_parser
  * PyICU (optional)



  * `--url`: Alternative to the above, allows whole wishlist URL as input - may need to be quoted
  * `--html`: For HTML files generated via below instructions
  * `--store-tld`: Optional for `--html`, will be guessed from filename
  * `--store-locale`: Optional - Store locale such as en_US, en_GB, de_DE, etc.
    * Not all stores support all locales.
    * If not specified, the default locale for that store will be chosen.
    * This is required for HTML files if the locale is not in the file name
  * `--sort-keys`: Optional - A single key or comma separated list of key names to sort the wishlist items by. Example `priority,name` sorts first by priority value highest to lowest, then sorts by name
    * Numeric values (such as priority, rating) are sorted largest to smallest
    * String values (such as name, comment) are sorted using the specified locale - when the package is installed with PyICU, the Unicode Collation Algorithm for the locale is used






  Excessive scraping in a short time frame will cause Amazon to serve HTTP 403 errors to the session, but will clear on its own after some time.



  This program is not capable of scraping private lists or authentication. Additionally, the "date added" field is only visible when you are authenticated (except for some old lists).

  To scrape these lists, you must use the bookmarklet provided in the below section, which will download an HTML file you can pass to the program with the `--html-file` argument.



  Using "Save As" in the browser will not create a usable HTML file for this program.

  To work around this, I created a bookmarklet which you can save and then open on any wishlist page. It will continuously scroll to the bottom until the list is fully loaded, and then save the rendered DOM to an HTML file with a filename understood by this program.

  Create a blank/dummy bookmark in your browser and replace the URL with this value:

      javascript:(function()%7Bif(window.location.host.startsWith(%22www.amazon.%22))var%20previousCount%3D-1%2CunchangedCount%3D0%2CcheckExist%3DsetInterval(function()%7Bvar%20e%3Ddocument.querySelectorAll(%22.g-item-sortable%22)%3Bif(document.getElementById(%22endOfListMarker%22)%7C%7CunchangedCount%3E%3D3)%7BclearInterval(checkExist)%3Blet%20t%3Ddocument.createElement(%22a%22)%2Cn%3Dnew%20Blob(%5Bdocument.getElementById(%22wishlist-page%22).outerHTML%5D%2C%7Btype%3A%22text%2Fhtml%22%7D)%3Bvar%20o%3Dwindow.location.host%2B%22_%22%2Bdocument.getElementById(%22listId%22).value%2B%22_%22%2Bopts.language%2B%22.html%22%3Bt.href%3DURL.createObjectURL(n)%2Ct.download%3Do%2Ct.click()%2CURL.revokeObjectURL(t.href)%7Delse%20e.length%3D%3D%3DpreviousCount%3FunchangedCount%2B%2B%3AunchangedCount%3D0%2CpreviousCount%3De.length%2C(last%3De%5Be.length-1%5D).scrollIntoView()%7D%2C2e3)%3Belse%20alert(%22This%20bookmarklet%20must%20be%20run%20on%20an%20Amazon%20site!%22)%3B%7D)()%3B

  Alternatively, you can open a console using your browser's development tools, and then run the code that way:

  ```javascript
  if(window.location.host.startsWith("www.amazon."))var previousCount=-1,unchangedCount=0,checkExist=setInterval(function(){var e=document.querySelectorAll(".g-item-sortable");if(document.getElementById("endOfListMarker")||unchangedCount>=3){clearInterval(checkExist);let t=document.createElement("a"),n=new Blob([document.getElementById("wishlist-page").outerHTML],{type:"text/html"});var o=window.location.host+"_"+document.getElementById("listId").value+"_"+opts.language+".html";t.href=URL.createObjectURL(n),t.download=o,t.click(),URL.revokeObjectURL(t.href)}else e.length===previousCount?unchangedCount++:unchangedCount=0,previousCount=e.length,(last=e[e.length-1]).scrollIntoView()},2e3);else alert("This bookmarklet must be run on an Amazon site!");
  ```

rpm_license:
  MIT License  Copyright (c) 2024 nateify  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


pkgId: c8e4917c7f202394ee8e5aac10aa135eb59432e80608ab4dc482c96fd55e7222
name: python-amazon-wishlist-exporter
arch: src
version: 2024.12.7
epoch: 0
release: 1
summary: Export Amazon wishlist metadata to JSON
url: https://github.com/nateify/amazon-wishlist-exporter
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazon-wishlist-exporter-2024.12.7-1.src.rpm
checksum_type: sha256
description:
  amazon-wishlist-exporter.py - Scrapes Amazon wishlist data to JSON format

      usage: amazon_wishlist_exporter.py [-h] (-u URL | -f HTML_FILE) [-t STORE_TLD] [-l STORE_LOCALE] [-p] [-d] [-s SORT_KEYS] [-c] [-y] [-o OUTPUT_FILE] [--debug]

      options:
        -h, --help            show this help message and exit
        -u URL, --url URL     Amazon wishlist URL
        -f HTML_FILE, --html-file HTML_FILE
                              Amazon wishlist HTML file
        -t STORE_TLD, --store-tld STORE_TLD
                              Amazon store TLD
        -l STORE_LOCALE, --store-locale STORE_LOCALE, --locale STORE_LOCALE
                              Amazon store locale
        -p, --priority-is-localized
                              Return localized priority text instead of numeric value
        -d, --iso8601         Convert localized date strings to ISO 8601 format
        -s SORT_KEYS, --sort-keys SORT_KEYS
                              Sort key(s) for JSON output
        -c, --compact-json    Write compacted JSON
        -y, --force           Overwrite existing output file without asking
        -o OUTPUT_FILE, --output-file OUTPUT_FILE
                              Output JSON file
        --debug               Print debug messages



  Due to an upstream dependency, this package can only be installed with pip for Python 3.9, 3.10, and 3.11.

      pip install amazon-wishlist-exporter

  [uv](https://docs.astral.sh/uv/) is recommended to install the package in a managed environment:

      uv tool install -p 3.11 amazon-wishlist-exporter

  For improved sorting of non-Latin or mixed scripts with the Unicode Collation Algorithm, install with the optional `icu` dependency:

      uv tool install -p 3.11 amazon-wishlist-exporter[icu]

  PyICU may need to be built separately: https://gitlab.pyicu.org/main/pyicu#installing-pyicu

  Windows users can use pre-built wheels from here: https://github.com/cgohlke/pyicu-build/releases

  Example:

      uv tool install -p 3.11 amazon-wishlist-exporter --with https://github.com/cgohlke/pyicu-build/releases/download/v2.13/PyICU-2.13-cp311-cp311-win_amd64.whl



  uv can be used to override the Pillow dependency which has been tested up to Pillow 11.0 on Python 3.13:

      uv tool install -p 3.13 amazon-wishlist-exporter --overrides overrides.txt

  The above uses the `overrides.txt` found in this repository.



  * Python >= 3.9
  * amazoncaptcha
  * babel
  * curl_cffi
  * dateparser
  * selectolax
  * price_parser
  * tenacity
  * PyICU (optional)



  * `--url`: Alternative to the above, allows whole wishlist URL as input - may need to be quoted
  * `--html`: For HTML files generated via below instructions
  * `--store-tld`: Optional for `--html`, will be guessed from filename
  * `--store-locale`: Optional - Store locale such as en_US, en_GB, de_DE, etc.
    * Not all stores support all locales.
    * If not specified, the default locale for that store will be chosen.
    * This is required for HTML files if the locale is not in the file name
  * `--sort-keys`: Optional - A single key or comma separated list of key names to sort the wishlist items by. Example `priority,name` sorts first by priority value highest to lowest, then sorts by name
    * Numeric values (such as priority, rating) are sorted largest to smallest
    * String values (such as name, comment) are sorted using the specified locale - when the package is installed with PyICU, the Unicode Collation Algorithm for the locale is used






  Excessive scraping in a short time frame will cause Amazon to serve HTTP 403 errors to the session, but will clear on its own after some time.



  This program is not capable of scraping private lists or authentication. Additionally, the "date added" field is only visible when you are authenticated (except for some old lists).

  To scrape these lists, you must use the bookmarklet provided in the below section, which will download an HTML file you can pass to the program with the `--html-file` argument.



  Using "Save As" in the browser will not create a usable HTML file for this program.

  To work around this, I created a bookmarklet which you can save and then open on any wishlist page. It will continuously scroll to the bottom until the list is fully loaded, and then save the rendered DOM to an HTML file with a filename understood by this program.

  Create a blank/dummy bookmark in your browser and replace the URL with this value:

      javascript:(function()%7Bif(window.location.host.startsWith(%22www.amazon.%22))var%20previousCount%3D-1%2CunchangedCount%3D0%2CcheckExist%3DsetInterval(function()%7Bvar%20e%3Ddocument.querySelectorAll(%22.g-item-sortable%22)%3Bif(document.getElementById(%22endOfListMarker%22)%7C%7CunchangedCount%3E%3D3)%7BclearInterval(checkExist)%3Blet%20t%3Ddocument.createElement(%22a%22)%2Cn%3Dnew%20Blob(%5Bdocument.getElementById(%22wishlist-page%22).outerHTML%5D%2C%7Btype%3A%22text%2Fhtml%22%7D)%3Bvar%20o%3Dwindow.location.host%2B%22_%22%2Bdocument.getElementById(%22listId%22).value%2B%22_%22%2Bopts.language%2B%22.html%22%3Bt.href%3DURL.createObjectURL(n)%2Ct.download%3Do%2Ct.click()%2CURL.revokeObjectURL(t.href)%7Delse%20e.length%3D%3D%3DpreviousCount%3FunchangedCount%2B%2B%3AunchangedCount%3D0%2CpreviousCount%3De.length%2C(last%3De%5Be.length-1%5D).scrollIntoView()%7D%2C2e3)%3Belse%20alert(%22This%20bookmarklet%20must%20be%20run%20on%20an%20Amazon%20site!%22)%3B%7D)()%3B

  Alternatively, you can open a console using your browser's development tools, and then run the code that way:

  ```javascript
  if(window.location.host.startsWith("www.amazon."))var previousCount=-1,unchangedCount=0,checkExist=setInterval(function(){var e=document.querySelectorAll(".g-item-sortable");if(document.getElementById("endOfListMarker")||unchangedCount>=3){clearInterval(checkExist);let t=document.createElement("a"),n=new Blob([document.getElementById("wishlist-page").outerHTML],{type:"text/html"});var o=window.location.host+"_"+document.getElementById("listId").value+"_"+opts.language+".html";t.href=URL.createObjectURL(n),t.download=o,t.click(),URL.revokeObjectURL(t.href)}else e.length===previousCount?unchangedCount++:unchangedCount=0,previousCount=e.length,(last=e[e.length-1]).scrollIntoView()},2e3);else alert("This bookmarklet must be run on an Amazon site!");
  ```

rpm_license:
[cell repeats an earlier one in this file: 1063 characters]


pkgId: f037ef1cd72003d2807a8eeb3a10c22c15198588c187d11a9a75face0a6a5f33
name: python-amazoncaptcha
arch: src
version: 0.5.11
epoch: 0
release: 1
summary: "Pure Python, lightweight, Pillow-based solver for the Amazon text captcha."
url: https://github.com/a-maliarov/amazoncaptcha
rpm_license: MIT License
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazoncaptcha-0.5.11-1.src.rpm
checksum_type: sha256
description:
  Pure Python, lightweight, [Pillow](https://github.com/python-pillow/Pillow)-based solver for [Amazon's text captcha](https://www.amazon.com/errors/validateCaptcha).
  [![Accuracy](https://img.shields.io/badge/success%20rate-99.9%25-success)](https://github.com/a-maliarov/amazoncaptcha/blob/master/ext/accuracy.log)
  ![Timing](https://img.shields.io/badge/response%20time-0.2s-success)
  [![Size](https://img.shields.io/badge/wheel%20size-0.9%20MB-informational)](https://pypi.org/project/amazoncaptcha/)
  [![Version](https://img.shields.io/pypi/v/amazoncaptcha?color=informational)](https://pypi.org/project/amazoncaptcha/)
  [![Python version](https://img.shields.io/badge/python-3.7%2B-informational)](https://pypi.org/project/amazoncaptcha/)
  [![Downloads](https://img.shields.io/pypi/dm/amazoncaptcha?color=success)](https://pypi.org/project/amazoncaptcha/)

  + *May 5, 2023*: tested and approved compatibility with Pillow 9.5.0
  + *January 25, 2022*: tested and approved compatibility with Python 3.10
  + *January 25, 2022*: dropped support for Python 3.6

  You can simply install the library from [PyPi](https://pypi.org/project/amazoncaptcha/) using **pip**. For more methods check the [docs](https://amazoncaptcha.readthedocs.io/en/latest/installation.html).
  ```bash
  pip install amazoncaptcha
  ```

  An example of the constructor usage. Scroll a bit down to see some tasty class methods. **For consistency across different devices, it is highly recommended to use `fromlink` class method**.
  ```python
  from amazoncaptcha import AmazonCaptcha
  captcha = AmazonCaptcha('captcha.jpg')
  solution = captcha.solve()

  ```

  [![Status](https://img.shields.io/pypi/status/amazoncaptcha)](https://pypi.org/project/amazoncaptcha/)
  [![Build Status](https://img.shields.io/circleci/build/github/a-maliarov/amazoncaptcha)](https://app.circleci.com/pipelines/github/a-maliarov/amazoncaptcha)
  [![Documentation Status](https://readthedocs.org/projects/amazoncaptcha/badge/?version=latest)](https://amazoncaptcha.readthedocs.io/en/latest/)
  [![Code Coverage](https://img.shields.io/codecov/c/gh/a-maliarov/amazoncaptcha?label=code%20coverage)](https://codecov.io/gh/a-maliarov/amazoncaptcha)
  [![CodeFactor Grade](https://img.shields.io/codefactor/grade/github/a-maliarov/amazoncaptcha/master)](https://www.codefactor.io/repository/github/a-maliarov/amazoncaptcha/overview/master)

  Browsing Amazon using `selenium` and stuck on captcha? The class method below will do all the dirty work of extracting an image from the webpage for you. Practically, it takes a screenshot from your webdriver, crops the captcha and stores it into bytes array which is then used to create an `AmazonCaptcha` instance. This also means avoiding any local savings. **For consistency across different devices, it is highly recommended to use `fromlink` class method instead of `fromdriver`**.
  ```python
  from amazoncaptcha import AmazonCaptcha
  from selenium import webdriver
  driver = webdriver.Chrome() # This is a simplified example
  driver.get('https://www.amazon.com/errors/validateCaptcha')
  captcha = AmazonCaptcha.fromdriver(driver)
  solution = captcha.solve()
  ```
  If you are not using `selenium` or the previous method is not just the case for you, it is possible to use a captcha link directly. This class method will request the url, check the content type and store the response content into bytes array to create an instance of `AmazonCaptcha`.
  ```python
  from amazoncaptcha import AmazonCaptcha
  link = 'https://images-na.ssl-images-amazon.com/captcha/usvmgloq/Captcha_kwrrnqwkph.jpg'
  captcha = AmazonCaptcha.fromlink(link)
  solution = captcha.solve()
  ```
  In addition, if you are a machine learning or neural network developer and are looking for some training data, check [this](https://github.com/a-maliarov/amazon-captcha-database) repository, which was created to store images and other non-script data for the solver.

  If you are willing to help the development, consider setting `keep_logs` argument of the `solve` method to `True`. Here is the example, if you are using `fromdriver` class method. If set to `True`, all the links of the unsolved captcha will be stored so that later you can [open the issue and send the logs](https://github.com/a-maliarov/amazoncaptcha/issues/new?assignees=a-maliarov&labels=training+data&template=send_logs.md&title=Add+training+data).
  ```python
  from amazoncaptcha import AmazonCaptcha
  from selenium import webdriver
  driver = webdriver.Chrome() # This is a simplified example
  driver.get('https://www.amazon.com/errors/validateCaptcha')
  captcha = AmazonCaptcha.fromdriver(driver)
  solution = captcha.solve(keep_logs=True)
  ```
  If you have any suggestions or ideas of additional instances and methods, which you would like to see in this library, please, feel free to contact the owner via email or fork'n'pull to repository. Any contribution is highly appreciated!
  [!["Buy Me A Coffee"](https://www.buymeacoffee.com/assets/img/custom_images/orange_img.png)](https://www.buymeacoffee.com/amaliarov)

  + If you want to see the [**History of Changes**](https://github.com/a-maliarov/amazoncaptcha/blob/master/HISTORY.md), [**Code of Conduct**](https://github.com/a-maliarov/amazoncaptcha/blob/master/.github/CODE_OF_CONDUCT.md), [**Contributing Policy**](https://github.com/a-maliarov/amazoncaptcha/blob/master/.github/CONTRIBUTING.md), or [**License**](https://github.com/a-maliarov/amazoncaptcha/blob/master/LICENSE), use these inline links to navigate based on your needs.
  + If you are facing any errors, please, report your situation via an issue.
  + This project is for educational and research purposes only. Any actions and/or activities related to the material contained on this GitHub Repository is solely your responsibility. The author will not be held responsible in the event any criminal charges be brought against any individuals misusing the information in this GitHub Repository to break the law.
  + Amazon is the registered trademark of Amazon.com, Inc. Amazon name used in this project is for identification purposes only. The project is not associated in any way with Amazon.com, Inc. and is not an official solution of Amazon.com, Inc.


pkgId: f1b9b8bf0ca2110a687c1d3495048e38787426774fd94a59969f163515ae8e15
name: python-amazondata
arch: src
version: 0.1.3
epoch: 0
release: 1
url: https://github.com/AnupKumarPanwar/amazondata
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazondata-0.1.3-1.src.rpm
checksum_type: sha256
summary:
  A python package to get amazon product and search data in json form. The package does not require any API keys as it works by scraping the amazon page.

description:
  [![PyPI version](https://badge.fury.io/py/amazondata.svg)](https://badge.fury.io/py/amazondata)

  A python package to get amazon product and search data in json form. The package does not require any API keys as it works by scraping the amazon page.

  Reference: [How To Scrape Amazon Product Details and Pricing using Python](https://medium.com/scrapehero/tutorial-how-to-scrape-amazon-product-details-using-python-56d40e7503b7)



  ```
  pip install amazondata
  ```



  To get Amazon product details from the url, use the following function.



  ```python
  from amazondata.product_details_extractor import ProductDetailsExtractor

  product_details_extractor = ProductDetailsExtractor()

  data = product_details_extractor.get_product_from_url('https://www.amazon.in/dp/B09JSYVNZ2')

  print(data)
  ```

  To get Amazon product details from the ASIN (Amazon Standard Identification Number) code, use the following function.



  ```python
  from amazondata.product_details_extractor import ProductDetailsExtractor

  product_details_extractor = ProductDetailsExtractor()

  data = product_details_extractor.get_product_from_asin_code('B09JSYVNZ2')

  print(data)
  ```

  To get the list of products from search query use the following function



  ```python
  from amazondata.search_result_extractor import SearchResultExtractor

  search_result_extractor = SearchResultExtractor()

  data = search_result_extractor.search('perfume for men', 3)

  print(data)

  ```

  NOTE: Optionally, you can pass custom `headers` to all these functions. The default headers value is:

  ```python
  headers = {
              "Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8",
              "Sec-Fetch-Site": "none",
              "Host": "www.amazon.in",
              "Accept-Language": "en-IN,en-GB;q=0.9,en;q=0.8",
              "Sec-Fetch-Mode": "navigate",
              "Accept-Encoding": "gzip, deflate, br",
              "User-Agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.0 Safari/605.1.15",
              "Connection": "keep-alive",
              "Upgrade-Insecure-Requests": "1",
              "Sec-Fetch-Dest": "document",
              "Priority": "u=0, i",
          }
  ```

  In case the the scraper gets blocked from Amazon, you can fetch the html code using selenium and pass the html code to the following function

  ```python
  data = extract_search_results(html_code)
  ```

  ```python
  data = extract_product_details(html_code)
  ```


pkgId: 9739e7b5cff287e146ac1fe7669180f6bbb6153548bb73b38b1a20ba4cc09fca
name: python-amazonian
arch: src
version: 2022.5.27
epoch: 0
release: 1
summary: Python library for working with Amazon Web Services such as Redshift and S3
url: https://github.com/idin/amazonian
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amazonian-2022.5.27-1.src.rpm
checksum_type: sha256
description:
  *Amazonian* is a *Python* library for interacting easily with Amazon S3 and Redshift.


  `pip install amazonian`





  ```python
  from amazonian import S3

  s3 = S3(key=None, secret=None, iam_role=None, root='s3://', spark=spark)


  s3.ls(path='s3://bucket/directory/subdirectory')


  s3.tree(path='s3://bucket/directory/subdirectory')


  s3.get_size(path='some_file')


  s3.save_parquet(data=my_data, path='s3://bucket/directory/subdirectory/name.parquet')


  my_data = s3.load_parquet(path='s3://bucket/directory/subdirectory/name.parquet')
  ```


pkgId: 3c2d016dc3e3fc9c3ee17b8f04cde9c872459bde3dc39030e7c8dc86febfc2ce
name: python-amba-event-stream
arch: src
version: 1.0.3
epoch: 0
release: 1
summary: amba-event-stream for kafka
url: https://pypi.org/project/amba-event-stream/
rpm_license: MIT License
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amba-event-stream-1.0.3-1.src.rpm
checksum_type: sha256
description:
  [![PyPI][]][1]

    [PyPI]: https://img.shields.io/pypi/v/amba-event-stream
    [1]: https://pypi.org/project/amba-event-stream/

  The Amba Analysis Streams package is used as a Kafka connection wrapper to abstract from infrastructure implementation details by providing functions to connect to Kafka and PostgreSQL. It defines the event model used in the streaming platform and provides base consumer and producer classes. The package is implemented as a python package that is hosted on pypi.org, and documented with mkdocs.

  The consumer and producer are capable of running in multiple processes to allow for parallel processing to better utilize modern CPUs. Both have built in monitoring capabilities: a counter shared by all processes is updated for each processed event. A thread running a function every few seconds is checking the counter and resetting it. If no data is processed over a defined period of time (meaning multiple consecutive check function runs), the container is restarted automatically by closing all python processed. This heart beat function ensures that even unforeseeable errors, such as container crashes or blockings are resolved by restarting the container and providing a clean system state.

  more Information can be found [here](https://github.com/ambalytics/amba-analysis-streams/blob/fce56afbd7d8207b847c270ffa2c6e025dcc1950/docs/Recognition-of-Scholarly-Publication-Trends-based-on-Social-Data-Stream-Processing_Lukas-Jesche.pdf)



  ``` bash
  pip install amba-event-stream
  ```



  Releases are published automatically when a tag is pushed to GitHub.

  ``` bash

  export RELEASE=x.x.x


  git commit --allow-empty -m "Release $RELEASE"
  git tag -a $RELEASE -m "Version $RELEASE"


  git push upstream --tags
  ```


pkgId: 0f7482bdb9ea66738b9b5206cd43500deeff97cf87e3ddf375f24d6efdc31409
name: python-amber-electric
arch: src
version: 0.0.17
epoch: 0
release: 1
summary: Unofficial Amber Electric API Library
url: https://github.com/troykelly/python-amber-electric
rpm_license: cc0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amber-electric-0.0.17-1.src.rpm
checksum_type: sha256
description:
  ![PyPI](https://github.com/troykelly/python-amber-electric/workflows/Publish%20Python%20%F0%9F%90%8D%20distributions%20%F0%9F%93%A6%20to%20PyPI%20and%20TestPyPI/badge.svg?branch=main) [![GitHub issues](https://img.shields.io/github/issues/troykelly/python-amber-electric?style=plastic)](https://github.com/troykelly/python-amber-electric/issues) [![GitHub forks](https://img.shields.io/github/forks/troykelly/python-amber-electric?style=plastic)](https://github.com/troykelly/python-amber-electric/network) [![GitHub stars](https://img.shields.io/github/stars/troykelly/python-amber-electric?style=plastic)](https://github.com/troykelly/python-amber-electric/stargazers) [![GitHub license](https://img.shields.io/github/license/troykelly/python-amber-electric?style=plastic)](https://github.com/troykelly/python-amber-electric/blob/main/LICENSE.txt) [![Twitter](https://img.shields.io/twitter/url?style=social&url=https%3A%2F%2Fgithub.com%2Ftroykelly%2Fpython-amber-electric)](https://twitter.com/intent/tweet?url=https%3A%2F%2Fgithub.com%2Ftroykelly%2Fpython-amber-electric&via=troykelly&text=Access%20the%20Constellix%20DNS%20API%20From%20Python&hashtags=%23python%20%23devops%20%23dns%20%23api)



  Connects to the [Amber Electric API](https://amberelectric.com.au) and retrieves market, usage and pricing information



  This is in no way affiliated with Amber Electric.



  I don't know what the usage data for an account looks like at the moment.
  Until I have an account with active usage data - this part of the API is going to be very light.



  This library uses `logging` just set the log level and format you need.



  The examples below may look a little complex - because this library relies on functions like `.auth()` and `.update()` being `await`ed.



  ```python
  import asyncio
  from amber_electric import AmberElectric

  api = AmberElectric(
          latitude=-37.828690,
          longitude=144.997460,
      )

  async def display_market_pricing():
      await api.market.update()
      print(api.market)

  asyncio.get_event_loop().run_until_complete(display_market_pricing())
  ```



  ```python
  import asyncio
  from amber_electric import AmberElectric

  api = AmberElectric(
          latitude=-37.828690,
          longitude=144.997460,
  		username="family@example.com",
  		password="secret"
      )

  async def get_account_pricing():
      await api.auth()
      await api.price.update()
      print(api.price)

  asyncio.get_event_loop().run_until_complete(get_account_pricing())
  ```



  ```python
  import asyncio
  from amber_electric import AmberElectric

  api = AmberElectric(
          latitude=-37.828690,
          longitude=144.997460,
  		username="family@example.com",
  		password="secret"
      )

  async def get_account_pricing():
      await api.auth()
      await api.usage.update()
      print(api.usage)

  asyncio.get_event_loop().run_until_complete(get_account_pricing())
  ```



  <a href="https://www.buymeacoffee.com/troykelly" target="_blank"><img src="https://cdn.buymeacoffee.com/buttons/v2/default-yellow.png" alt="Buy Me A Coffee" style="height: 60px !important;width: 217px !important;" ></a>


pkgId: a2c9fb211721d40a3c47aca1deb1a631ffd75b9eecdca9de09152138a0ea0a68
name: python-amberelectric
arch: src
version: 2.0.1
epoch: 0
release: 1
summary: Amber Electric Public API
url: https://github.com/madpilot/amberelectric.py
rpm_license: Apache Software License
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amberelectric-2.0.1-1.src.rpm
checksum_type: sha256
description:
      Amber is an Australian-based electricity retailer that pass through the real-time wholesale price of energy.  Because of Amber&#39;s wholesale power prices, you can save hundreds of dollars a year by automating high power devices like air-conditioners, heat pumps and pool pumps.  This Python library provides an interface to the API, allowing you to react to current and forecast prices, as well as download your historic usage.


pkgId: ff2aeb21375d50a6dff08f5d10f9c57111d98250b7468817a2b19174ea11a5a6
name: python-amberelectric
arch: src
version: 2.0.12
epoch: 0
release: 1
summary: Amber Electric Public API
url: https://github.com/madpilot/amberelectric.py
rpm_license: Apache-2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amberelectric-2.0.12-1.src.rpm
checksum_type: sha256
description:
  *AmberApi* | [**get_current_prices**](docs/AmberApi.md#get_current_prices) | **GET** /sites/{siteId}/prices/current |
  *AmberApi* | [**get_current_renewables**](docs/AmberApi.md#get_current_renewables) | **GET** /state/{state}/renewables/current |
  *AmberApi* | [**get_prices**](docs/AmberApi.md#get_prices) | **GET** /sites/{siteId}/prices |
  *AmberApi* | [**get_sites**](docs/AmberApi.md#get_sites) | **GET** /sites |
  *AmberApi* | [**get_usage**](docs/AmberApi.md#get_usage) | **GET** /sites/{siteId}/usage |

   - [ActualInterval](docs/ActualInterval.md)
   - [ActualRenewable](docs/ActualRenewable.md)
   - [AdvancedPrice](docs/AdvancedPrice.md)
   - [BaseInterval](docs/BaseInterval.md)
   - [BaseRenewable](docs/BaseRenewable.md)
   - [Channel](docs/Channel.md)
   - [ChannelType](docs/ChannelType.md)
   - [CurrentInterval](docs/CurrentInterval.md)
   - [CurrentRenewable](docs/CurrentRenewable.md)
   - [ForecastInterval](docs/ForecastInterval.md)
   - [ForecastRenewable](docs/ForecastRenewable.md)
   - [Interval](docs/Interval.md)
   - [PriceDescriptor](docs/PriceDescriptor.md)
   - [Range](docs/Range.md)
   - [Renewable](docs/Renewable.md)
   - [RenewableDescriptor](docs/RenewableDescriptor.md)
   - [Site](docs/Site.md)
   - [SiteStatus](docs/SiteStatus.md)
   - [SpikeStatus](docs/SpikeStatus.md)
   - [TariffInformation](docs/TariffInformation.md)
   - [Usage](docs/Usage.md)
  <a id="documentation-for-authorization"></a>

  Authentication schemes defined for the API:
  <a id="apiKey"></a>

  - **Type**: Bearer authentication

  dev@amber.com.au


pkgId: 1edf38fa04987ee08086750c8d38bcc814536ee574dfbae7a7efbbb2f84d0ce7
name: python-amberflo-metering-python
arch: src
version: 3.1.0
epoch: 0
release: 1
summary: Integrate Amberflo into any Python 3 application.
url: https://github.com/amberflo/metering-python
rpm_license: MIT License
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amberflo-metering-python-3.1.0-1.src.rpm
checksum_type: sha256
description:
  <p>
      <a href="https://github.com/amberflo/metering-python/actions">
          <img alt="CI Status" src="https://github.com/amberflo/metering-python/actions/workflows/tests.yml/badge.svg?branch=main">
      </a>
      <a href="https://pypi.org/project/amberflo-metering-python/">
          <img alt="PyPI" src="https://img.shields.io/pypi/v/amberflo-metering-python">
      </a>
  </p>

  [Amberflo](https://amberflo.io) is the simplest way to integrate metering into your application.

  This is the official Python 3 client that wraps the [Amberflo REST API](https://docs.amberflo.io/docs).



  - Add and update customers
  - Assign and update product plans to customers
  - List invoices of a customer
  - Get a new customer portal session for a customer
  - Add and list prepaid orders to customers
  - Send meter events
      - In asynchronous batches for high throughput (with optional flush on demand)
      - Or synchronously
      - Using the Amberflo API or the Amberflo supplied AWS S3 bucket
  - Query usage
  - Fine grained logging control



  1. [Sign up for free](https://ui.amberflo.io/) and get an API key.

  2. Install the SDK

  ```
  pip install amberflo-metering-python
  ```

  3. Create a customer

  ```python
  import os
  from metering.customer import CustomerApiClient, create_customer_payload

  client = CustomerApiClient(os.environ.get("API_KEY"))

  message = create_customer_payload(
      customer_id="sample-customer-123",
      customer_email="customer-123@sample.com",
      customer_name="Sample Customer",
      traits={
          "region": "us-east-1",
      },
  )
  customer = client.add_or_update(message)
  ```

  4. Ingest meter events

  ```python
  import os
  from time import time
  from metering.ingest import create_ingest_client

  client = create_ingest_client(api_key=os.environ["API_KEY"])

  dimensions = {"region": "us-east-1"}
  customer_id = "sample-customer-123"

  client.meter(
      meter_api_name="sample-meter",
      meter_value=5,
      meter_time_in_millis=int(time() * 1000),
      customer_id=customer_id,
      dimensions=dimensions,
  )
  ```

  5. Query usage

  ```python
  import os
  from time import time
  from metering.usage import (AggregationType, Take, TimeGroupingInterval,
                              TimeRange, UsageApiClient, create_usage_query)

  client = UsageApiClient(os.environ.get("API_KEY"))

  since_two_days_ago = TimeRange(int(time()) - 60 * 60 * 24 * 2)

  query = create_usage_query(
      meter_api_name="my_meter",
      aggregation=AggregationType.SUM,
      time_grouping_interval=TimeGroupingInterval.DAY,
      time_range=since_two_days_ago,
      group_by=["customerId"],
      usage_filter={"customerId": ["some-customer-321", "sample-customer-123"]},
      take=Take(limit=10, is_ascending=False),
  )
  report = client.get(query)
  ```



  Amberflo.io libraries are built to support high throughput environments. That
  means you can safely send hundreds of meter records per second. For example,
  you can chose to deploy it on a web server that is serving hundreds of requests
  per second.

  However, every call does not result in a HTTP request, but is queued in memory
  instead. Messages are batched and flushed in the background, allowing for much
  faster operation. The size of batch and rate of flush can be customized.

  **Flush on demand:** For example, at the end of your program, you'll want to
  flush to make sure there's nothing left in the queue. Calling this method will
  block the calling thread until there are no messages left in the queue. So,
  you'll want to use it as part of your cleanup scripts and avoid using it as
  part of the request lifecycle.

  **Error handling:** The SDK allows you to set up a `on_error` callback function
  for handling errors when trying to send a batch.

  Here is a complete example, showing the default values of all options:

  ```python
  def on_error_callback(error, batch):
      ...

  client = create_ingest_client(
      api_key=API_KEY,
      max_queue_size=100000,  # max number of items in the queue before rejecting new items
      threads=2,  # number of worker threads doing the sending
      retries=2,  # max number of retries after failures
      batch_size=100,  # max number of meter records in a batch
      send_interval_in_secs=0.5,  # wait time before sending an incomplete batch
      sleep_interval_in_secs=0.1,  # wait time after failure to send or queue empty
      on_error=on_error_callback,  # handle failures to send a batch
  )

  ...

  client.meter(...)

  client.flush()  # block and make sure all messages are sent
  ```



  If the module detects that it can't flush faster than it's receiving messages,
  it'll simply stop accepting new messages. This allows your program to
  continually run without ever crashing due to a backed up metering queue.



  The SDK provides a `metering.ingest.IngestS3Client` so you can send your meter
  records to us via the S3 bucket.

  Use of this feature is enabled if you install the library with the `s3` option:
  ```
  pip install amberflo-metering-python[s3]
  ```

  Just pass the S3 bucket credentials to the factory function:
  ```python
  client = create_ingest_client(
      bucket_name=os.environ.get("BUCKET_NAME"),
      access_key=os.environ.get("ACCESS_KEY"),
      secret_key=os.environ.get("SECRET_KEY"),
  )
  ```



  General documentation on how to use Amberflo is available at [Product Walkthrough](https://docs.amberflo.io/docs/product-walkthrough).

  The full REST API documentation is available at [API Reference](https://docs.amberflo.io/reference).



  Code samples covering different scenarios are available in the [./samples](https://github.com/amberflo/metering-python/blob/main/samples/README.md) folder.



  Feel free to open issues and send a pull request.

  Also, check out [CONTRIBUTING.md](https://github.com/amberflo/metering-python/blob/main/CONTRIBUTING.md).







  ```python
  from metering.ingest import (
      create_ingest_payload,
      create_ingest_client,
  )
  ```



  ```python
  from metering.customer import (
      CustomerApiClient,
      create_customer_payload,
  )
  ```



  ```python
  from metering.usage import (
      AggregationType,
      Take,
      TimeGroupingInterval,
      TimeRange,
      UsageApiClient,
      create_usage_query,
      create_all_usage_query,
  )
  ```



  ```python
  from metering.customer_portal_session import (
      CustomerPortalSessionApiClient,
      create_customer_portal_session_payload,
  )
  ```



  ```python
  from metering.customer_prepaid_order import (
      BillingPeriod,
      BillingPeriodUnit,
      CustomerPrepaidOrderApiClient,
      create_customer_prepaid_order_payload,
  )
  ```



  ```python
  from metering.customer_product_invoice import (
      CustomerProductInvoiceApiClient,
      create_all_invoices_query,
      create_latest_invoice_query,
      create_invoice_query,
  )
  ```



  ```python
  from metering.customer_product_plan import (
      CustomerProductPlanApiClient,
      create_customer_product_plan_payload,
  )
  ```



  ```python
  from metering.exceptions import ApiError
  ```



  `amberflo-metering-python` uses the standard Python logging framework. By
  default, logging is and set at the `WARNING` level.

  The following loggers are used:

  - `metering.ingest.producer`
  - `metering.ingest.s3_client`
  - `metering.ingest.consumer`
  - `metering.session.ingest_session`
  - `metering.session.api_session`


pkgId: 74eee8d5b1b453b91ee1d331ce0c4cdbe003dc65de4f5a4e65c89521574fad35
name: python-amberpdf
arch: src
version: 0.1.0
epoch: 0
release: 1
summary: Una librería para extraer texto de PDFs usando AWS Textract
url: https://github.com/tuusuario/amberpdf
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amberpdf-0.1.0-1.src.rpm
checksum_type: sha256
description:
  Una librerÃ­a para extraer texto de PDFs usando AWS Textract.



  pip install amberpdf



  import amberpdf


  amberpdf.credentials('tu_access_key_id', 'tu_secret_access_key')


  text = amberpdf.process_pdf('ruta/al/archivo.pdf')
  print(text)


pkgId: 83d4ccf2a4262ae314cc32a1e7caa2f21a0e5e4cbc2a0b474817d8d3eb825601
name: python-amberpdf
arch: src
version: 0.1.2
epoch: 0
release: 1
summary: Librería que procesa un PDF mixto (texto e imágenes/tablas) y extrae el contenido en orden
url: https://github.com/amberpdf
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amberpdf-0.1.2-1.src.rpm
checksum_type: sha256
description:
  Una librerÃ­a que procesa un PDF mixto (texto e imÃ¡genes/tablas) y extrae el contenido en orden.



  pip install amberpdf



  import amberpdf


  amberpdf.credentials('tu_access_key_id', 'tu_secret_access_key')


  text = amberpdf.process_pdf('ruta/al/archivo.pdf', pages = 0)   #"pages" es el nÃºmero de pÃ¡ginas que analizarÃ¡, inicia desde la primera pÃ¡gina

  print(text)


pkgId: 74d2274dc732caf4db787506dc4feebd1487f5ac7772528ac6788bcba667933f
name: python-ambhas
arch: src
version: 1.1.0
epoch: 0
release: 1
summary: A library for data science in water
url: https://github.com/tomersk/ambhas
rpm_license: GNU Library or Lesser General Public License (LGPL)
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ambhas-1.1.0-1.src.rpm
checksum_type: sha256
description:
  Ambhas python library



  Installing ambhas can be done by downloading source file (ambhas--<version>.tar.gz), and after unpacking issuing the command::

      python setup.py install

  This requires the usual Distutils options available.

  Or, download the ambhas--<version>.tar.gz file and issue the command::

     pip install /path/to/ambhas--<version>.tar.gz

  Or, directly using the pip::

     pip install ambhas




  Import required modules::

      import numpy as np
      from ambhas.errlib import rmse, correlation

  Generate some random numbers::

      x = np.random.normal(size=100)
      y = np.random.normal(size=100)
      rmse(x,y)
      correlation(x,y)



  Sat Kumar Tomer
  satkumartomer at gmail dot com



  0.1.0
  * Initial version

  0.1.1
  * Minor corrections in setup.py files

  0.2.0
  * few packages added

  0.3.0
  * groundwater, sun_rise_set, soil texture module, etc. added

  0.3.1
  * manifest.in file edited

  0.3.2
  * extract_gis_data, richards, risat added

  0.4.0
  * extract_gis_data, richards, risat added

  1.0.0
  * Updated for Python3
  * Removed copula from this and is available now only as a seperate library



  If you have any comment/suggestion/question,
  please feel free to write me at satkumartomer@gmail.com

  You may go through https://github.com/tomersk/learn-python to see the examples.


pkgId: 074cc4e1e9adc0be6e0ec475f12446b41cf063f2871594013f4a417a0286d520
name: python-ambient-api
arch: src
version: 1.5.7
epoch: 0
release: 1
summary: A Python class for accessing the Ambient Weather API.
url: https://github.com/avryhof/ambient_api
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ambient-api-1.5.7-1.src.rpm
checksum_type: sha256
description:
  Python Module to access the Ambient Weather API

  ```bash
  pip install ambient_api
  ```

  ```bash
  AMBIENT_ENDPOINT=https://rt.ambientweather.net/v1
  AMBIENT_API_KEY='your-api-key-here'
  AMBIENT_APPLICATION_KEY='your-application-key-here'
  ```
  Get these values by following [these instructions](https://ambientweather.docs.apiary.io/#introduction/authentication).
  Still struggling, check out the [Authentication](https://github.com/avryhof/ambient_api_postman_collection#authentication) documentation in my [Postman Collection](https://github.com/avryhof/ambient_api_postman_collection) repo.

  There are two classes implemented in this module.

  This is the base API that you initialize in your code.
  ```python
  from ambient_api.ambientapi import AmbientAPI
  import time
  api = AmbientAPI()
  ```
  This class takes care of authenticating to, and sending calls to the API.  It can be expanded as needed in the future.

  This class represents a single Weather Station.  When you ask AmbientAPI for a list of devices,
  it returns a list of AmbientWeatherStations, and from this class, you can query the weather station itself.
  ```python
  devices = api.get_devices()
  device = devices[0]
  time.sleep(1) #pause for a second to avoid API limits
  print(device.get_data())
  ```
  Learn more about the Ambient Weather API at the [Ambient Weather API Documentation](https://ambientweather.docs.apiary.io/#).

  * [Ambient APRS](https://github.com/avryhof/ambient_aprs)
  * Not into Python?  Stuck on something with the Ambient Weather API and need more info?  Check out the repo for my [Postman Collection](https://github.com/avryhof/ambient_api_postman_collection)


pkgId: 2b144999655996ee3681a605eecab4c3035ad70ecf5e215ba15015b09e9c2cdc
name: python-ambient-base-plugin
arch: src
version: 1.2.3
epoch: 0
release: 1
summary: An abstract base class for Ambient platform plugins.
url: https://pypi.org/project/ambient-base-plugin/
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ambient-base-plugin-1.2.3-1.src.rpm
checksum_type: sha256
description:
  `ambient_base_plugin` provides an abstract base class (`BasePlugin`) for creating plugins in the Ambient platform. This base class defines the core interface that all plugins must implement, making it easy to build and integrate new functionality into the Ambient system.



  - Abstract base class (`BasePlugin`) to create plugins.
  - Event-driven architecture with `handle_event` method.
  - Easy configuration using the `configure` method.
  - Compatible with both in-process and containerized plugin models.



  You can install `ambient_base_plugin` via pip:

  ```bash
  pip install ambient-base-plugin
  ```


pkgId: 8b09c1ac1ed4c81188415f9eacddab8e458a9f84b4b37e3f1a666d96669dde52
name: python-ambient-toolbox
arch: src
version: 11.5.2
epoch: 0
release: 1
summary: Python toolbox of Ambient Digital containing an abundance of useful tools and gadgets.
url: https://github.com/ambient-innovation/ambient-toolbox/
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ambient-toolbox-11.5.2-1.src.rpm
checksum_type: sha256
description:
  [![PyPI release](https://img.shields.io/pypi/v/ambient-toolbox.svg)](https://pypi.org/project/ambient-toolbox/)
  [![Downloads](https://static.pepy.tech/badge/ambient-toolbox)](https://pepy.tech/project/ambient-toolbox)
  [![Coverage](https://img.shields.io/badge/Coverage-68.21%25-success)](https://github.com/ambient-innovation/ambient-toolbox/actions?workflow=CI)
  [![Linting](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
  [![Coding Style](https://img.shields.io/badge/code%20style-Ruff-000000.svg)](https://github.com/astral-sh/ruff)
  [![Documentation Status](https://readthedocs.org/projects/ambient-toolbox/badge/?version=latest)](https://ambient-toolbox.readthedocs.io/en/latest/?badge=latest)

  Python toolbox of Ambient Digital containing an abundance of useful tools and gadgets.

  * [PyPI](https://pypi.org/project/ambient-toolbox/)
  * [GitHub](https://github.com/ambient-innovation/ambient-toolbox)
  * [Full documentation](https://ambient-toolbox.readthedocs.io/en/latest/index.html)
  * Creator & Maintainer: [Ambient Digital](https://ambient.digital/)




  * Useful classes and mixins for Django admin
  * Coverage script for GitLab
  * Extensions for DRF and GraphQL
  * Mailing backends for Django
  * Management commands for validating a projects test structure
  * Object ownership tracking with timestamping
  * Pattern for improved workflow with Django ORM
  * Helper and util functions for many different use-cases
  * Sentry plugins
  * django-scrubber wrapper class
  * Mixins and test classes for django (class-based) views



  This package was previously known as [ai_django_core](https://pypi.org/project/ai-django-core/). Due to the
  misleading nature of the name, we chose to rename it with something more meaningful.

  The migration is really simple, just:

  * Install ambient-toolbox and remove the dependency to ai-django-core
  * Search and replace all usages of `from ai_django_core...` to `from ambient_toolbox...`
  * The class-based mail functionality was moved to a separate package called
  [django-pony-express](https://pypi.org/project/django-pony-express/).



  - Install the package via pip:

    `pip install ambient_toolbox`

    or via pipenv:

    `pipenv install ambient_toolbox`

  - Add module to `INSTALLED_APPS` within the main django `settings.py`:

      ````
      INSTALLED_APPS = (
          ...
          'ambient_toolbox',
      )
       ````


  - Apply migrations by running:

    `python ./manage.py migrate`






  - Create a Python virtualenv and activate it
  - Install "pip-tools" with `pip install -U pip-tools`
  - Compile the requirements with `pip-compile --extra dev,drf,graphql,bleacher,sentry,view-layer, -o requirements.txt pyproject.toml --resolver=backtracking`
  - Sync the dependencies with your virtualenv with `pip-sync`



  - Create a new branch for your feature
  - Change the dependency in your requirements.txt to a local (editable) one that points to your local file system:
    `-e /Users/workspace/ambient-toolbox` or via pip  `pip install -e /Users/workspace/ambient-toolbox`
  - Ensure the code passes the tests
  - Create a pull request



  - Run tests
    ````
    pytest --ds settings tests
    ````

  - Check coverage
    ````
    coverage run -m pytest --ds settings tests
    coverage report -m
    ````



  We use pre-push hooks to ensure that only linted code reaches our remote repository and pipelines aren't triggered in
  vain.

  To enable the configured pre-push hooks, you need to [install](https://pre-commit.com/) pre-commit and run once:

      pre-commit install -t pre-push -t pre-commit --install-hooks

  This will permanently install the git hooks for both, frontend and backend, in your local
  [`.git/hooks`](./.git/hooks) folder.
  The hooks are configured in the [`.pre-commit-config.yaml`](templates/.pre-commit-config.yaml.tpl).

  You can check whether hooks work as intended using the [run](https://pre-commit.com/#pre-commit-run) command:

      pre-commit run [hook-id] [options]

  Example: run single hook

      pre-commit run ruff --all-files --hook-stage push

  Example: run all hooks of pre-push stage

      pre-commit run --all-files --hook-stage push



  - To build the documentation, run: `sphinx-build docs/ docs/_build/html/`.
  - Open `docs/_build/html/index.html` to see the documentation.




  If you have added custom text, make sure to wrap it in `_()` where `_` is
  gettext_lazy (`from django.utils.translation import gettext_lazy as _`).

  How to create translation file:

  * Navigate to `ambient-toolbox`
  * `python manage.py makemessages -l de`
  * Have a look at the new/changed files within `ambient_toolbox/locale`

  How to compile translation files:

  * Navigate to `ambient-toolbox`
  * `python manage.py compilemessages`
  * Have a look at the new/changed files within `ambient_toolbox/locale`




  - Fetch the latest changes in GitHub mirror and push them
  - Trigger new build at ReadTheDocs.io (follow instructions in admin panel at RTD) if the GitHub webhook is not yet set
    up.



  - Update documentation about new/changed functionality

  - Update the `Changelog`

  - Increment version in main `__init__.py`

  - Create pull request / merge to master

  - This project uses the flit package to publish to PyPI. Thus publishing should be as easy as running:
    ```
    flit publish
    ```

    To publish to TestPyPI use the following ensure that you have set up your .pypirc as
    shown [here](https://flit.readthedocs.io/en/latest/upload.html#using-pypirc) and use the following command:

    ```
    flit publish --repository testpypi
    ```



  Please note that this package supports the [ambient-package-update](https://pypi.org/project/ambient-package-update/).
  So you don't have to worry about the maintenance of this package. All important configuration and setup files are
  being rendered by this updater. It works similar to well-known updaters like `pyupgrade` or `django-upgrade`.

  To run an update, refer to the [documentation page](https://pypi.org/project/ambient-package-update/)
  of the "ambient-package-update".


pkgId: 6aba61018bced65f260ef83b69611b90a881a7e01ecc23b8fca99148415a2fc4
name: python-ambient-toolbox
arch: src
version: 11.5.5
epoch: 0
release: 1
summary: Python toolbox of Ambient Digital containing an abundance of useful tools and gadgets.
url: https://github.com/ambient-innovation/ambient-toolbox/
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ambient-toolbox-11.5.5-1.src.rpm
checksum_type: sha256
description:
  [![PyPI release](https://img.shields.io/pypi/v/ambient-toolbox.svg)](https://pypi.org/project/ambient-toolbox/)
  [![Downloads](https://static.pepy.tech/badge/ambient-toolbox)](https://pepy.tech/project/ambient-toolbox)
  [![Coverage](https://img.shields.io/badge/Coverage-68.21%25-success)](https://github.com/ambient-innovation/ambient-toolbox/actions?workflow=CI)
  [![Linting](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
  [![Coding Style](https://img.shields.io/badge/code%20style-Ruff-000000.svg)](https://github.com/astral-sh/ruff)
  [![Documentation Status](https://readthedocs.org/projects/ambient-toolbox/badge/?version=latest)](https://ambient-toolbox.readthedocs.io/en/latest/?badge=latest)

  Python toolbox of Ambient Digital containing an abundance of useful tools and gadgets.

  * [PyPI](https://pypi.org/project/ambient-toolbox/)
  * [GitHub](https://github.com/ambient-innovation/ambient-toolbox)
  * [Full documentation](https://ambient-toolbox.readthedocs.io/en/latest/index.html)
  * Creator & Maintainer: [Ambient Digital](https://ambient.digital/)




  * Useful classes and mixins for Django admin
  * Coverage script for GitLab
  * Extensions for DRF and GraphQL
  * Mailing backends for Django
  * Management commands for validating a projects test structure
  * Object ownership tracking with timestamping
  * Pattern for improved workflow with Django ORM
  * Helper and util functions for many different use-cases
  * Sentry plugins
  * django-scrubber wrapper class
  * Mixins and test classes for django (class-based) views



  This package was previously known as [ai_django_core](https://pypi.org/project/ai-django-core/). Due to the
  misleading nature of the name, we chose to rename it with something more meaningful.

  The migration is really simple, just:

  * Install ambient-toolbox and remove the dependency to ai-django-core
  * Search and replace all usages of `from ai_django_core...` to `from ambient_toolbox...`
  * The class-based mail functionality was moved to a separate package called
  [django-pony-express](https://pypi.org/project/django-pony-express/).



  - Install the package via pip:

    `pip install ambient-toolbox`

    or via pipenv:

    `pipenv install ambient-toolbox`

  - Add module to `INSTALLED_APPS` within the main django `settings.py`:

      ```python
      INSTALLED_APPS = (
          
          "ambient_toolbox",
      )
      ```


  - Apply migrations by running:

    `python ./manage.py migrate`






  - Create a Python virtualenv and activate it
  - Install "pip-tools" with `pip install -U pip-tools`
  - Compile the requirements with `pip-compile --extra dev,drf,graphql,bleacher,sentry,view-layer, -o requirements.txt pyproject.toml --resolver=backtracking`
  - Sync the dependencies with your virtualenv with `pip-sync`



  - Create a new branch for your feature
  - Change the dependency in your requirements.txt to a local (editable) one that points to your local file system:
    `-e /Users/workspace/ambient-toolbox` or via pip  `pip install -e /Users/workspace/ambient-toolbox`
  - Ensure the code passes the tests
  - Create a pull request



  - Run tests
    ````
    pytest --ds settings tests
    ````

  - Check coverage
    ````
    coverage run -m pytest --ds settings tests
    coverage report -m
    ````



  We use pre-push hooks to ensure that only linted code reaches our remote repository and pipelines aren't triggered in
  vain.

  To enable the configured pre-push hooks, you need to [install](https://pre-commit.com/) pre-commit and run once:

      pre-commit install -t pre-push -t pre-commit --install-hooks

  This will permanently install the git hooks for both, frontend and backend, in your local
  [`.git/hooks`](./.git/hooks) folder.
  The hooks are configured in the [`.pre-commit-config.yaml`](templates/.pre-commit-config.yaml.tpl).

  You can check whether hooks work as intended using the [run](https://pre-commit.com/#pre-commit-run) command:

      pre-commit run [hook-id] [options]

  Example: run single hook

      pre-commit run ruff --all-files --hook-stage push

  Example: run all hooks of pre-push stage

      pre-commit run --all-files --hook-stage push



  - To build the documentation, run: `sphinx-build docs/ docs/_build/html/`.
  - Open `docs/_build/html/index.html` to see the documentation.




  If you have added custom text, make sure to wrap it in `_()` where `_` is
  gettext_lazy (`from django.utils.translation import gettext_lazy as _`).

  How to create translation file:

  * Navigate to `ambient-toolbox`
  * `python manage.py makemessages -l de`
  * Have a look at the new/changed files within `ambient_toolbox/locale`

  How to compile translation files:

  * Navigate to `ambient-toolbox`
  * `python manage.py compilemessages`
  * Have a look at the new/changed files within `ambient_toolbox/locale`




  - Fetch the latest changes in GitHub mirror and push them
  - Trigger new build at ReadTheDocs.io (follow instructions in admin panel at RTD) if the GitHub webhook is not yet set
    up.



  - Update documentation about new/changed functionality

  - Update the `Changelog`

  - Increment version in main `__init__.py`

  - Create pull request / merge to master

  - This project uses the flit package to publish to PyPI. Thus, publishing should be as easy as running:
    ```
    flit publish
    ```

    To publish to TestPyPI use the following to ensure that you have set up your .pypirc as
    shown [here](https://flit.readthedocs.io/en/latest/upload.html#using-pypirc) and use the following command:

    ```
    flit publish --repository testpypi
    ```



  Please note that this package supports the [ambient-package-update](https://pypi.org/project/ambient-package-update/).
  So you don't have to worry about the maintenance of this package. This updater is rendering all important
  configuration and setup files. It works similar to well-known updaters like `pyupgrade` or `django-upgrade`.

  To run an update, refer to the [documentation page](https://pypi.org/project/ambient-package-update/)
  of the "ambient-package-update".


pkgId: 07d2c001647ec3940790d221866378bf7f3440d917522246a5b6476cddf4fd68
name: python-ambientika_py
arch: src
version: 0.0.5
epoch: 0
release: 1
summary: An API wrapper for Ambientika smart devices
url: https://github.com/wingertge/ambientika-py
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ambientika_py-0.0.5-1.src.rpm
checksum_type: sha256
description:
  A simple API wrapper for the smart home air conditioning device(s) sold as Ambientika.
  Probably incomplete because it is reverse engineered from a single device.


pkgId: b176ce57787e7c5ad2447ddcd13153e50129d24d75ee53d650c86bb507c98be4
name: python-ambio
arch: src
version: 0.5.2
epoch: 0
release: 1
summary: A lightweight Bioinformatics library
url: https://github.com/albertomosconi/ambio
rpm_license: GNU General Public License v3 (GPLv3)
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ambio-0.5.2-1.src.rpm
checksum_type: sha256
description:
  A light-weight bioinformatics library written in Python. It contains a variety of algorithms and functions that deal with strings.



  The complete documentation can be found on [ambio.readthedocs.io](https://ambio.readthedocs.io/)



  Run the following command in a terminal to install:

  ```bash
  $ pip install ambio
  ```



  To install `ambio`, along with the tools you need to develop and run tests, run the following command:

  ```bash
  $ pip install -e .
  ```


pkgId: 95bc40c1b623180cdd0320b0d253742aaa643d79e5a31df7e77e138f678f0bf6
name: python-ambit-fe
arch: src
version: 1.2.9
epoch: 0
release: 1
summary: A FEniCS-based cardiovascular multi-physics solver
url: https://github.com/marchirschvogel/ambit
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ambit-fe-1.2.9-1.src.rpm
checksum_type: sha256
description:
  [![DOI](https://joss.theoj.org/papers/10.21105/joss.05744/status.svg)](https://doi.org/10.21105/joss.05744)

  Ambit is an open-source multi-physics finite element solver written in Python, supporting solid and fluid mechanics, fluid-structure interaction (FSI), and lumped-parameter models.
  It is tailored towards solving problems in cardiac mechanics, but may also be used for more general nonlinear finite element analysis. It uses the finite element backend FEniCSx and
  linear algebra library PETSc.

  https://github.com/marchirschvogel/ambit/assets/52761273/a438ff55-9b37-4572-a1c5-499dd3cfba73

  **Heart cycle simulation of a generic bi-ventricular heart model coupled to a closed-loop circulation model.**

  https://github.com/marchirschvogel/ambit/assets/52761273/8e681cb6-7a4f-4d1f-b34a-cefb642f44b7

  **FSI simulation (Turek benchmark, FSI2 case) of an elastic flag in incompressible channel flow.**

  The following is supported:

  * Solid mechanics
    - Finite strain elastodynamics, implementing a range of hyperelastic isotropic and anisotropic as well as viscous constitutive laws
    - Active stress for modeling of cardiac contraction mechanics
    - Quasi-static, generalized-alpha, or one-step theta time integration
    - Nearly incompressible as well as fully incompressible formulations (latter using pressure dofs)
    - Prestressing using MULF method in displacement formulation
    - Volumetric growth & remodeling
  * Fluid dynamics
    - Incompressible Navier-Stokes/Stokes equations, either in nonconservative or conservative formulation
    - Navier-Stokes/Stokes flow in an Arbitrary Lagrangian Eulerian (ALE) reference frame
    - One-step theta, or generalized-alpha time integration
    - SUPG/PSPG stabilization for equal-order approximations of velocity and pressure
  * Lumped (0D) models
    - Systemic and pulmonary circulation flow models
    - 2-element as well as 4-element Windkessel models
    - Signalling network model
  * Coupling of different physics:
    - Fluid-solid interaction (FSI): Monolithic FSI in ALE formulation using Lagrange multiplier
    - Monolithic coupling of 3D solid/fluid/ALE-fluid with lumped 0D flow models
    - Multiscale-in-time analysis of growth & remodeling (staggered solution of 3D-0D coupled solid-flow0d and G&R solid problem)
  * Fluid-reduced-solid interaction (FrSI)
    - Boundary subspace-projected physics-reduced solid model (incl. hyperelastic, viscous, and active parts) in an ALE fluid reference frame
  * POD-based model order reduction (MOR)
    - Projection-based model order reduction applicable to main fluid or solid field (also in a coupled problem), by either projecting
      the full problem or a boundary to a lower dimensional subspace spanned by POD modes

  - author: Dr.-Ing. Marc Hirschvogel, marc.hirschvogel@ambit.net

  Still experimental / to-do:

  - Finite strain plasticity
  - Electrophysiology/scalar transport
  - ... whatever might be wanted in some future ...



  Documentation can be viewed at https://ambit.readthedocs.io



  In order to use Ambit, you need to [install FEniCSx](https://github.com/FEniCS/dolfinx#installation)

  Latest Ambit-compatible dolfinx release version: v0.8.0\
  Latest tested Ambit-compatible dolfinx development version dating to 28 Aug 2024

  Ambit can then be installed using pip, either the current release
  ```
  python3 -m pip install ambit-fe
  ```

  or latest development version:
  ```
  python3 -m pip install git+https://github.com/marchirschvogel/ambit.git
  ```

  Alternatively, you can pull a pre-built Docker image with FEniCSx and Ambit installed:
  ```
  docker pull ghcr.io/marchirschvogel/ambit:latest
  ```

  If a Docker image for development is desired, the following image contains all dependencies needed to install and run Ambit (including the dolfinx mixed branch):
  ```
  docker pull ghcr.io/marchirschvogel/ambit:devenv
  ```



  Check out the examples for the basic problem types in demos to quickly get started running solid, fluid, or 0D model problems. Further, you can have a look
  at input files in ambit/tests and the file ambit_template.py in the main folder as example of all available input options.


  Best, check if all testcases run and pass, by navigating to ambit/tests and executing
  ```
  ./runtests.py
  ```

  Build your input file and run it with the command
  ```
  mpiexec -n <NUMBER_OF_CORES> python3 your_file.py
  ```

rpm_license:
  MIT License  Copyright (c) 2024 Marc Hirschvogel  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


pkgId: 5f7e29fc96ecd049149bc55404f5866a75627b61b97f8a3eac9cd494c4d2b16e
name: python-ambit-fe
arch: src
version: 1.3
epoch: 0
release: 1
summary: A FEniCS-based cardiovascular multi-physics solver
url: https://github.com/marchirschvogel/ambit
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ambit-fe-1.3-1.src.rpm
checksum_type: sha256
description:
  [![DOI](https://joss.theoj.org/papers/10.21105/joss.05744/status.svg)](https://doi.org/10.21105/joss.05744)

  Ambit is an open-source multi-physics finite element solver written in Python, supporting solid and fluid mechanics, fluid-structure interaction (FSI), and lumped-parameter models.
  It is tailored towards solving problems in cardiac mechanics, but may also be used for more general nonlinear finite element analysis. It uses the finite element backend FEniCSx and
  linear algebra library PETSc.

  https://github.com/marchirschvogel/ambit/assets/52761273/a438ff55-9b37-4572-a1c5-499dd3cfba73

  **Heart cycle simulation of a generic bi-ventricular heart model coupled to a closed-loop circulation model.**

  https://github.com/marchirschvogel/ambit/assets/52761273/8e681cb6-7a4f-4d1f-b34a-cefb642f44b7

  **FSI simulation (Turek benchmark, FSI2 case) of an elastic flag in incompressible channel flow.**

  The following is supported:

  * Solid mechanics
    - Finite strain elastodynamics, implementing a range of hyperelastic isotropic and anisotropic as well as viscous constitutive laws
    - Active stress for modeling of cardiac contraction mechanics
    - Quasi-static, generalized-alpha, or one-step theta time integration
    - Nearly incompressible as well as fully incompressible formulations (latter using pressure dofs)
    - Prestressing using MULF method in displacement formulation
    - Volumetric growth & remodeling
  * Fluid dynamics
    - Incompressible Navier-Stokes/Stokes equations, either in nonconservative or conservative formulation
    - Navier-Stokes/Stokes flow in an Arbitrary Lagrangian Eulerian (ALE) reference frame
    - One-step theta, or generalized-alpha time integration
    - SUPG/PSPG stabilization for equal-order approximations of velocity and pressure
  * Lumped (0D) models
    - Systemic and pulmonary circulation flow models
    - 2-element as well as 4-element Windkessel models
    - Signalling network model
  * Coupling of different physics:
    - Fluid-solid interaction (FSI): Monolithic FSI in ALE formulation using Lagrange multiplier
    - Monolithic coupling of 3D solid/fluid/ALE-fluid with lumped 0D flow models
    - Multiscale-in-time analysis of growth & remodeling (staggered solution of 3D-0D coupled solid-flow0d and G&R solid problem)
  * Fluid-reduced-solid interaction (FrSI)
    - Boundary subspace-projected physics-reduced solid model (incl. hyperelastic, viscous, and active parts) in an ALE fluid reference frame
  * POD-based model order reduction (MOR)
    - Projection-based model order reduction applicable to main fluid or solid field (also in a coupled problem), by either projecting
      the full problem or a boundary to a lower dimensional subspace spanned by POD modes

  - author: Dr.-Ing. Marc Hirschvogel, marc.hirschvogel@ambit.net

  Still experimental / to-do:

  - Finite strain plasticity
  - Electrophysiology/scalar transport
  - ... whatever might be wanted in some future ...



  Documentation can be viewed at https://ambit.readthedocs.io



  In order to use Ambit, you need to [install FEniCSx](https://github.com/FEniCS/dolfinx#installation)

  Latest Ambit-compatible dolfinx release version: N/A\
  Latest tested Ambit-compatible dolfinx development version dating to 29 Nov 2024

  Ambit can then be installed using pip, either the current release
  ```
  python3 -m pip install ambit-fe
  ```

  or latest development version:
  ```
  python3 -m pip install git+https://github.com/marchirschvogel/ambit.git
  ```

  Alternatively, you can pull a pre-built Docker image with FEniCSx and Ambit installed:
  ```
  docker pull ghcr.io/marchirschvogel/ambit:latest
  ```

  If a Docker image for development is desired, the following image contains all dependencies needed to install and run Ambit:
  ```
  docker pull ghcr.io/marchirschvogel/ambit:devenv
  ```



  Check out the examples for the basic problem types in demos to quickly get started running solid, fluid, or 0D model problems. Further, you can have a look
  at input files in ambit/tests and the file ambit_template.py in the main folder as example of all available input options.


  Best, check if all testcases run and pass, by navigating to ambit/tests and executing
  ```
  ./runtests.py
  ```

  Build your input file and run it with the command
  ```
  mpiexec -n <NUMBER_OF_CORES> python3 your_file.py
  ```



  Software paper:

  * Hirschvogel M. **Ambit – A FEniCS-based cardiovascular multi-physics solver.** *Journal of Open Source Software,* 9(93), 2024, DOI: 10.21105/joss.05744

  Papers explicitly using and citing Ambit:

  * Hirschvogel M, Bonini M, Balmus M, Nordsletten D. **Effective Block Preconditioners for Fluid Dynamics Coupled to Reduced Models of a Non-Local Nature.** *Computer Methods in Applied Mechanics and Engineering,* 2024, *Accepted*
  * Aróstica R, Nolte D, Brown A, Gebauer A, Karabelas E, Jilberto J, Salvador M, Bucelli M, Piersanti R, Osouli K, Augustin C, Finsberg H, Shi L, Hirschvogel M, Pfaller M, Africa PC, Gsell M, Marsden A, Nordsletten D, Regazzoni F, Plank G, Sundnes J, Dede' L, Peirlinck M, Vedula V, Wall WA, Bertoglio C. **A software benchmark for cardiac elastodynamics.** *Computer Methods in Applied Mechanics and Engineering,* 2024, *Accepted*

rpm_license:
  MIT License  Copyright (c) 2024 Marc Hirschvogel  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


pkgId: b93b1a8000d0db06702f48435a9244ad2d42a41a0d2be49a9481c1a767c63456
name: python-amclient
arch: src
version: 1.3.0
epoch: 0
release: 1
summary: Archivematica API client library.
url: https://pypi.org/project/amclient/
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amclient-1.3.0-1.src.rpm
checksum_type: sha256
description:
  [![GitHub CI](https://github.com/artefactual-labs/amclient/actions/workflows/test.yml/badge.svg)](https://github.com/artefactual-labs/amclient/actions/workflows/test.yml)
  [![codecov](https://codecov.io/gh/artefactual-labs/amclient/branch/master/graph/badge.svg?token=hJLGYzoJUo)](https://codecov.io/gh/artefactual-labs/amclient)



  AMClient is an Archivematica API client library and Python package for making
  it easier to talk to Archivematica from your Python scripts. AMClient also acts
  as a command line application which can easily be combined with shell-scripts
  to perform the same functions as a Python script might.

  AMClient brings together the majority of the functionality of the two primary
  Archivematica components:

  * [Archivematica API][archivematica-api]
  * [Storage Service API][storage-service-api]

  Basic usage:
      `amclient.py <subcommand> [optional arguments] <positional argument(s)>`

    E.g.:
    ```bash
      amclient.py close-completed-transfers \
          --am-user-name test 234deffdf89d887a7023546e6bc0031167cedf6
    ```

  To see a list of all commands and how they are used, then run `amclient.py`
  without any arguments.

  To understand how to use an individual subcommand, simply run:
  `amclient.py <subcommand>`, the output will describe the input parameters for
  that command:

    E.g.:
    ```bash
      usage: amclient extract-file [-h] [--ss-user-name USERNAME] [--ss-url URL]
                                   [--directory DIR]
                                   [--saveas-filename SAVEASFILENAME]
                                   ss_api_key package_uuid relative_path
    ```

  Calling the module from Python:

    E.g.:
  ```python
      Python 3.6.7 (default, Oct 22 2018, 11:32:17)
      [GCC 8.2.0] on linux
      Type "help", "copyright", "credits" or "license" for more information.
      >>> from amclient import AMClient
      >>> am = AMClient()
      >>> am.ss_url = "http://127.0.0.1:62081"
      >>> am.ss_user_name = "test"
      >>> am.ss_api_key = "test"
      >>> am.list_storage_locations()
      ...json is output here...
  ```



  For information about contributing to this project please see the AMClient
  [CONTRIBUTING.md][contributing]

  [archivematica-api]: https://wiki.archivematica.org/Archivematica_API
  [storage-service-api]: https://wiki.archivematica.org/Storage_Service_API
  [contributing]: CONTRIBUTING.md

rpm_license:
  GNU AFFERO GENERAL PUBLIC LICENSE Version 3, 19 November 2007  Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/> Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.  Preamble  The GNU Affero General Public License is a free, copyleft license for software and other kinds of works, specifically designed to ensure cooperation with the community in the case of network server software.  The licenses for most software and other practical works are designed to take away your freedom to share and change the works.  By contrast, our General Public Licenses are intended to guarantee your freedom to share and change all versions of a program--to make sure it remains free software for all its users.  When we speak of free software, we are referring to freedom, not price.  Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things.  Developers that use our General Public Licenses protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License which gives you legal permission to copy, distribute and/or modify the software.  A secondary benefit of defending all users' freedom is that improvements made in alternate versions of the program, if they receive widespread use, become available for other developers to incorporate.  Many developers of free software are heartened and encouraged by the resulting cooperation.  However, in the case of software used on network servers, this result may fail to come about. The GNU General Public License permits making a modified version and letting the public access it on a server without ever releasing its source code to the public.  The GNU Affero General Public License is designed specifically to ensure that, in such cases, the modified source code becomes available to the community.  It requires the operator of a network server to provide the source code of the modified version running there to the users of that server.  Therefore, public use of a modified version, on a publicly accessible server, gives the public access to the source code of the modified version.  An older license, called the Affero General Public License and published by Affero, was designed to accomplish similar goals.  This is a different license, not a version of the Affero GPL, but Affero has released a new version of the Affero GPL which permits relicensing under this license.  The precise terms and conditions for copying, distribution and modification follow.  TERMS AND CONDITIONS  0. Definitions.  "This License" refers to version 3 of the GNU Affero General Public License.  "Copyright" also means copyright-like laws that apply to other kinds of works, such as semiconductor masks.  "The Program" refers to any copyrightable work licensed under this License.  Each licensee is addressed as "you".  "Licensees" and "recipients" may be individuals or organizations.  To "modify" a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the making of an exact copy.  The resulting work is called a "modified version" of the earlier work or a work "based on" the earlier work.  A "covered work" means either the unmodified Program or a work based on the Program.  To "propagate" a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy.  Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well.  To "convey" a work means any kind of propagation that enables other parties to make or receive copies.  Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying.  An interactive user interface displays "Appropriate Legal Notices" to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the work under this License, and how to view a copy of this License.  If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion.  1. Source Code.  The "source code" for a work means the preferred form of the work for making modifications to it.  "Object code" means any non-source form of a work.  A "Standard Interface" means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language.  The "System Libraries" of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form.  A "Major Component", in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it.  The "Corresponding Source" for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities.  However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work.  For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those subprograms and other parts of the work.  The Corresponding Source need not include anything that users can regenerate automatically from other parts of the Corresponding Source.  The Corresponding Source for a work in source code form is that same work.  2. Basic Permissions.  All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated conditions are met.  This License explicitly affirms your unlimited permission to run the unmodified Program.  The output from running a covered work is covered by this License only if the output, given its content, constitutes a covered work.  This License acknowledges your rights of fair use or other equivalent, as provided by copyright law.  You may make, run and propagate covered works that you do not convey, without conditions so long as your license otherwise remains in force.  You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works, provided that you comply with the terms of this License in conveying all material for which you do not control copyright.  Those thus making or running the covered works for you must do so exclusively on your behalf, under your direction and control, on terms that prohibit them from making any copies of your copyrighted material outside their relationship with you.  Conveying under any other circumstances is permitted solely under the conditions stated below.  Sublicensing is not allowed; section 10 makes it unnecessary.  3. Protecting Users' Legal Rights From Anti-Circumvention Law.  No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures.  When you convey a covered work, you waive any legal power to forbid circumvention of technological measures to the extent such circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures.  4. Conveying Verbatim Copies.  You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program.  You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee.  5. Conveying Modified Source Versions.  You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the terms of section 4, provided that you also meet all of these conditions:  a) The work must carry prominent notices stating that you modified it, and giving a relevant date.  b) The work must carry prominent notices stating that it is released under this License and any conditions added under section 7.  This requirement modifies the requirement in section 4 to "keep intact all notices".  c) You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy.  This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, regardless of how they are packaged.  This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it.  d) If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so.  A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an "aggregate" if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users beyond what the individual works permit.  Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate.  6. Conveying Non-Source Forms.  You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways:  a) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange.  b) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product model, to give anyone who possesses the object code either (1) a copy of the Corresponding Source for all the software in the product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this conveying of source, or (2) access to copy the Corresponding Source from a network server at no charge.  c) Convey individual copies of the object code with a copy of the written offer to provide the Corresponding Source.  This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b.  d) Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge.  You need not require recipients to copy the Corresponding Source along with the object code.  If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source.  Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements.  e) Convey the object code using peer-to-peer transmission, provided you inform other peers where the object code and Corresponding Source of the work are being offered to the general public at no charge under subsection 6d.  A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work.  A "User Product" is either (1) a "consumer product", which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling.  In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage.  For a particular product received by a particular user, "normally used" refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product.  A product is a consumer product regardless of whether the product has substantial commercial, industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product.  "Installation Information" for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source.  The information must suffice to ensure that the continued functioning of the modified object code is in no case prevented or interfered with solely because modification has been made.  If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied by the Installation Information.  But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM).  The requirement to provide Installation Information does not include a requirement to continue to provide support service, warranty, or updates for a work that has been modified or installed by the recipient, or for the User Product in which it has been modified or installed.  Access to a network may be denied when the modification itself materially and adversely affects the operation of the network or violates the rules and protocols for communication across the network.  Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying.  7. Additional Terms.  "Additional permissions" are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent that they are valid under applicable law.  If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions.  When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of it.  (Additional permissions may be written to require their own removal in certain cases when you modify the work.)  You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission.  Notwithstanding any other provision of this License, for material you add to a covered work, you may (if authorized by the copyright holders of that material) supplement the terms of this License with terms:  a) Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or  b) Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or  c) Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version; or  d) Limiting the use for publicity purposes of names of licensors or authors of the material; or  e) Declining to grant rights under trademark law for use of some trade names, trademarks, or service marks; or  f) Requiring indemnification of licensors and authors of that material by anyone who conveys the material (or modified versions of it) with contractual assumptions of liability to the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors.  All other non-permissive additional terms are considered "further restrictions" within the meaning of section 10.  If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term.  If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying.  If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms.  Additional terms, permissive or non-permissive, may be stated in the form of a separately written license, or stated as exceptions; the above requirements apply either way.  8. Termination.  You may not propagate or modify a covered work except as expressly provided under this License.  Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11).  However, if you cease all violation of this License, then your license from a particular copyright holder is reinstated (a) provisionally, unless and until the copyright holder explicitly and finally terminates your license, and (b) permanently, if the copyright holder fails to notify you of the violation by some reasonable means prior to 60 days after the cessation.  Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice.  Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under this License.  If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10.  9. Acceptance Not Required for Having Copies.  You are not required to accept this License in order to receive or run a copy of the Program.  Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission to receive a copy likewise does not require acceptance.  However, nothing other than this License grants you permission to propagate or modify any covered work.  These actions infringe copyright if you do not accept this License.  Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so.  10. Automatic Licensing of Downstream Recipients.  Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and propagate that work, subject to this License.  You are not responsible for enforcing compliance by third parties with this License.  An "entity transaction" is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations.  If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts.  You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License.  For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it.  11. Patents.  A "contributor" is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based.  The work thus licensed is called the contributor's "contributor version".  A contributor's "essential patent claims" are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the contributor version.  For purposes of this definition, "control" includes the right to grant patent sublicenses in a manner consistent with the requirements of this License.  Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version.  In the following three paragraphs, a "patent license" is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to sue for patent infringement).  To "grant" such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party.  If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent license to downstream recipients.  "Knowingly relying" means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid.  If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it.  A patent license is "discriminatory" if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License.  You may not convey a covered work if you are a party to an arrangement with a third party that is in the business of distributing software, under which you make payment to the third party based on the extent of your activity of conveying the work, and under which the third party grants, to any of the parties who would receive the covered work from you, a discriminatory patent license (a) in connection with copies of the covered work conveyed by you (or copies made from those copies), or (b) primarily for and in connection with specific products or compilations that contain the covered work, unless you entered into that arrangement, or that patent license was granted, prior to 28 March 2007.  Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law.  12. No Surrender of Others' Freedom.  If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License.  If you cannot convey a covered work so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not convey it at all.  For example, if you agree to terms that obligate you to collect a royalty for further conveying from those to whom you convey the Program, the only way you could satisfy both those terms and this License would be to refrain entirely from conveying the Program.  13. Remote Network Interaction; Use with the GNU General Public License.  Notwithstanding any other provision of this License, if you modify the Program, your modified version must prominently offer all users interacting with it remotely through a computer network (if your version supports such interaction) an opportunity to receive the Corresponding Source of your version by providing access to the Corresponding Source from a network server at no charge, through some standard or customary means of facilitating copying of software.  This Corresponding Source shall include the Corresponding Source for any work covered by version 3 of the GNU General Public License that is incorporated pursuant to the following paragraph.  Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU General Public License into a single combined work, and to convey the resulting work.  The terms of this License will continue to apply to the part which is the covered work, but the work with which it is combined will remain governed by version 3 of the GNU General Public License.  14. Revised Versions of this License.  The Free Software Foundation may publish revised and/or new versions of the GNU Affero General Public License from time to time.  Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns.  Each version is given a distinguishing version number.  If the Program specifies that a certain numbered version of the GNU Affero General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation.  If the Program does not specify a version number of the GNU Affero General Public License, you may choose any version ever published by the Free Software Foundation.  If the Program specifies that a proxy can decide which future versions of the GNU Affero General Public License can be used, that proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program.  Later license versions may give you additional or different permissions.  However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version.  15. Disclaimer of Warranty.  THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.  16. Limitation of Liability.  IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.  17. Interpretation of Sections 15 and 16.  If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee.  END OF TERMS AND CONDITIONS  How to Apply These Terms to Your New Programs  If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms.  To do so, attach the following notices to the program.  It is safest to attach them to the start of each source file to most effectively state the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found.  <one line to give the program's name and a brief idea of what it does.> Copyright (C) <year>  <name of author>  This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero 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 Affero General Public License for more details.  You should have received a copy of the GNU Affero General Public License along with this program.  If not, see <https://www.gnu.org/licenses/>.  Also add information on how to contact you by electronic and paper mail.  If your software can interact with users remotely through a computer network, you should also make sure that it provides a way for users to get its source.  For example, if your program is a web application, its interface could display a "Source" link that leads users to an archive of the code.  There are many ways you could offer source, and different solutions will be better for different programs; see section 13 for the specific requirements.  You should also get your employer (if you work as a programmer) or school, if any, to sign a "copyright disclaimer" for the program, if necessary. For more information on this, and how to apply and follow the GNU AGPL, see <https://www.gnu.org/licenses/>.


pkgId: 2a52d60d7187606b816b6247c9baaa9c7370dbd5af9ee9f20d1beb60b61949b9
name: python-amdfan
arch: src
version: 0.2.3
epoch: 0
release: 1
summary: Fan monitor and controller for AMD gpus in Linux
url: https://mcgillij.dev/pages/amdfan.html
rpm_license: GPL-2.0-only
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amdfan-0.2.3-1.src.rpm
checksum_type: sha256
description:
  ![Python package](https://github.com/mcgillij/amdfan/workflows/Python%20package/badge.svg)
  [![Downloads](https://static.pepy.tech/personalized-badge/amdfan?period=total&units=international_system&left_color=blue&right_color=green&left_text=PyPi%20Downloads)](https://pepy.tech/project/amdfan)

  Is a fork of amdgpu-fan, with security updates and added functionality.
  This is intended for stand-alone GPU's and not integrated APU's.



  * alternatives abandoned
  * lacking required features
  * security fixes not addressed
  * basic functionality not working



  As of a couple years ago, and is no longer applying any security fixes to their project or improvements. There were also some bugs that bothered me with the project when I tried to get it up and running.
  Features missing

  There are a number of features that I wanted, but were not available.

  * Thresholds allow temperature range before changing fan speed
  * Frequency setting to allow better control
  * Monitoring to be able to see real-time fan speeds and temperature



  There are some un-addressed pull requests for some recent YAML vulnerabilities that are still present in the old amdgpu_fan project, that I’ve addressed in this fork.



  Setting the card to system managed using the amdgpu_fan pegs your GPU fan at 100%, instead of allowing the system to manage the fan settings. I fixed that bug as well in this release.

  These are all addressed in Amdfan, and as long as I’ve still got some AMD cards I intend to at least maintain this for myself. And anyone’s able to help out since this is open source. I would have liked to just contribute these fixes to the main project, but it’s now inactive.



  ```help
  Usage: amdfan [OPTIONS] COMMAND [ARGS]...

  Options:
    -v, --version  Show the version and exit.
    --help         Show this message and exit.

  Commands:
    daemon         Run the controller as a service
    manage         Run the fan controller
    monitor        View the current temperature and speed
    print-default  Convenient defaults
    set            Manually override the fan speed
  ```

  Each subcommand supports `--help` too, to get more details.



  There are two ways to control your fans with Amdfan. Note that in order to control the fans, you will likely need to run either approach as root.

  The recommended way is through a system service started at boot. This will control the fans based on the detected temperature at a given interval.

  In case you don't want to use a service, you may also control the fans manually. While this is only advised to do when first setting up your configuration, keep in mind you can also use it to temporarily take control away from the daemon until you revert the fan speed back to `auto`.

  ![screenshot](https://raw.githubusercontent.com/mcgillij/amdfan/main/images/manual.png)




  You can use Amdfan to monitor your AMD video cards using the `monitor` flag. This does not require root privileges, usually.

  ![screenshot](https://raw.githubusercontent.com/mcgillij/amdfan/main/images/screenshot.png)




  Running `amdfan print-default --configuration` will dump out the default configuration that would get generated for `/etc/amdfan.yml` when you first run it as a service. If a value is not specified, it will use a default value if possible.

  The following config is probably a reasonable setup:
  ``` bash
  speed_matrix:
  - [4, 4]
  - [30, 33]
  - [45, 50]
  - [60, 66]
  - [65, 69]
  - [70, 75]
  - [75, 89]
  - [80, 100]

  threshold: 4
  frequency: 5



  ```

  If a configuration file is not found, a default one will be generated. If you want to make any changes to the default config before running the daemon, run `amdfan print-default --configuration | sudo tee /etc/amdfan.yml` and do your changes from there.

  - `speed_matrix` (required): a list of thresholds `[temperature, speed]` which are interpolated to calculate the fan speed.
  - `threshold` (default `0`): allows for some leeway in temperatures, as to not constantly change fan speed
  - `frequency` (default `5`): how often (in seconds) we wait between updates
  - `cards` (required): a list of card names (from `/sys/class/drm`) which we want to control.

  Note! You can send a **SIGHUP** signal to the daemon to request a reload of the config without restarting the whole service. Additionally, if you're using a pidfile, you can send a signal to reload the config with `amdfan daemon --signal=reload`



  Users: Use your package manager to install the package. It's available on Arch Linux and Gentoo. For other distributions, please request a maintainer to bring the package to your system, or read the installation notes at your own warranty.

  Maintainers: Check the [installation notes](INSTALL.md).


pkgId: dc382add6e95287e82e953f0ed14c473e2886f056abaf3e02c569279a9d28b49
name: python-amdgpu-fan
arch: src
version: 0.0.22.post1556022696
epoch: 0
release: 1
summary: amdgpu fan controller
url: https://github.com/chestm007/amdgpu-fan
rpm_license: GPL-2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amdgpu-fan-0.0.22.post1556022696-1.src.rpm
checksum_type: sha256
description:
  [![CircleCI](https://circleci.com/gh/chestm007/amdgpu-fan.svg?style=svg)](https://circleci.com/gh/chestm007/amdgpu-fan)



  If you experience problems please create an issue.



  `sudo pip3 install .`


  Available in the aur as `amdgpu-fan`


  `sudo amdgpu-fan`


  ```



  speed_matrix:  # -[temp(*C), speed(0-100%)]
  - [0, 0]
  - [40, 30]
  - [60, 50]
  - [80, 100]





  ```


pkgId: 33d40c0b11366c6d01b383405c3aa7af95a7ef65e6d92375dd91cbbf9698396d
name: python-amdgpu-stats
arch: src
version: 0.1.24
epoch: 0
release: 1
summary: A module/TUI for AMD GPU statistics
url: https://github.com/joshlay/amdgpu_stats
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amdgpu-stats-0.1.24-1.src.rpm
checksum_type: sha256
description:
  ValueError: Invalid card: 'card0'. Must be one of: ['card1']
  ```
  For more information on what the module provides, please see:
  - [ReadTheDocs](https://amdgpu-stats.readthedocs.io/en/latest/)
  - `help('amdgpu_stats.utils')` in your interpreter
  - [The module source](https://github.com/joshlay/amdgpu_stats/blob/master/src/amdgpu_stats/utils.py)


pkgId: 4f293f2ad3bf0c878ffb124eb52771e981a2945903655531e5b0b4a91a89f738
name: python-amendment-forecast
arch: src
version: 1.5.4
epoch: 0
release: 1
summary: A forecaster for sales data
url: https://github.com/amendmentai/forecast_models
rpm_license: UNKNOWN
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amendment-forecast-1.5.4-1.src.rpm
checksum_type: sha256
description:
  forecast_ensemble combines multiple models into a single forecast and returns a combined package of models, their
  evaluated results including a composite score



  The forecast is run using `main.py` with the following options



  The required input format is a JSON with the following fields:

  Required:

  - `data_filepath`: filepath of the time series data to run the ensemble on
  - `target_column`: name of the input column
  - `aggregate_operation`: string operation to apply to target_column to create the time series
  - `output_directory`: directory to return the result JSON to


pkgId: e77d2c7e2c00af78dcd7748388745fd8f3b9e2226ce012a0ffe78d3c952868e4
name: python-americansouth
arch: src
version: 0.1.0
epoch: 0
release: 1
summary: Monitor internet data usage to avoid overage charges
url: https://github.com/gkwa/americansouth
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-americansouth-0.1.0-1.src.rpm
checksum_type: sha256
description:
          61GB         16GB         61GB          338GB      400GB Sat Nov 09 11:58 pm 2024
           5GB         17GB         66GB          333GB      400GB Mon Nov 11 07:49 am 2024
           5GB         17GB         71GB          328GB      400GB Mon Nov 11 09:12 pm 2024
           7GB         18GB         79GB          320GB      400GB Tue Nov 12 10:41 pm 2024
           6GB         18GB         85GB          314GB      400GB Wed Nov 13 08:07 pm 2024
           8GB         19GB         93GB          306GB      400GB Thu Nov 14 04:25 pm 2024
          14GB         19GB        107GB          292GB      400GB Fri Nov 15 08:17 am 2024
          12GB         20GB        120GB          279GB      400GB Sun Nov 17 07:59 am 2024
           7GB         22GB        127GB          272GB      400GB Mon Nov 18 07:52 am 2024
           5GB         23GB        133GB          266GB      400GB Tue Nov 19 07:37 am 2024
          14GB         22GB        147GB          252GB      400GB Tue Nov 19 01:43 pm 2024
  ```
  The output shows:
  - Daily data usage
  - Recommended daily budget to stay within monthly limit
  - Total data used so far
  - Remaining monthly budget
  - Total monthly allocation
  - Timestamp of when data was fetched


pkgId: 24ae3eed1e092ef202e8b9442ab31b371e694067cf94444eefe58697f692eba5
name: python-ameriopt
arch: src
version: 0.1.5
epoch: 0
release: 1
summary: This is a package for pricing American options using reinforcement learning
url: https://github.com/Peymankor/AmeriOpt
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ameriopt-0.1.5-1.src.rpm
checksum_type: sha256
description:
  A Python Package for Pricing American Option using Reinforcement Learning.

  The full documentation of paper can be found in  [https://www.mdpi.com/1999-4893/17/9/400](https://www.mdpi.com/1999-4893/17/9/400)

  ![image info](https://raw.githubusercontent.com/Peymankor/AmeriOpt/main/example_mainimage.png)

  To use package, you need to follwo the following steps:


  ```bash
  pip install ameriopt
  ```




  ```python

  from ameriopt.rl_policy import RLPolicy
  ```




  - Number of Laguerre polynomials to be used in the RL model

  ```python
  NUM_LAGUERRE = 5
  ```

  - Number of training iterations for the RL algorithm

  ```python
  TRAINING_ITERS = 3
  ```

  - Small constant for numerical stability in the RL algorithm

  ```python
  EPSILON = 1e-5
  ```

  - Strike price of the option

  ```python
  STRIKE_PRICE = 40
  ```

  - Time to expiration (in years)

  ```python
  EXPIRY_TIME = 1.0
  ```

  - Risk-free interest rate

  ```python
  INTEREST_RATE = 0.06
  ```

  - Number of time intervals

  ```python
  NUM_INTERVALS = 50
  ```

  - Number of simulations for generating training data

  ```python
  NUM_SIMULATIONS_TRAIN = 5000
  ```

  - Number of simulations for testing the RL policy

  ```python
  NUM_SIMULATIONS_TEST = 10000
  ```

  - Spot price of the underlying asset at the start of the simulation

  ```python
  SPOT_PRICE = 36.0
  ```

  - Volatility of the underlying asset (annualized)

  ```python
  VOLATILITY = 0.2
  ```





  ```python
  training_data = simulate_GBM_training(
      expiry_time=EXPIRY_TIME,
      num_intervals=NUM_INTERVALS,
      num_simulations=NUM_SIMULATIONS_TRAIN,
      spot_price=SPOT_PRICE,
      interest_rate=INTEREST_RATE,
      volatility=VOLATILITY
  )
  ```



  ```python
  rl_policy = RLPolicy(
      num_laguerre=NUM_LAGUERRE,
      strike_price=STRIKE_PRICE,
      expiry=EXPIRY_TIME,
      interest_rate=INTEREST_RATE,
      num_steps=NUM_INTERVALS,
      training_iters=TRAINING_ITERS,
      epsilon=EPSILON
  )
  ```




  ```python
  weights = rl_policy.get_weights(training_data=training_data)
  ```



  ```python
  paths_test = scoring_sim_data(
      expiry_time=EXPIRY_TIME,
      num_intervals=NUM_INTERVALS,
      num_simulations_test=NUM_SIMULATIONS_TEST,
      spot_price=SPOT_PRICE,
      interest_rate=INTEREST_RATE,
      volatility=VOLATILITY
  )
  ```



  ```python
  option_price = rl_policy.calculate_option_price(stock_paths=paths_test)
  ```



  ```python
  print("Option Price using RL Method:", option_price)
  ```


pkgId: b64e1fee9467bc6c192709afcf24ef766fb37c7e6af8b5860975674cc71a0136
name: python-amfiprot
arch: src
version: 0.1.11
epoch: 0
release: 1
summary: Core library for Amfiprot
url: https://pypi.org/project/amfiprot/
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amfiprot-0.1.11-1.src.rpm
checksum_type: sha256
description:
  Amfiprot is a communication protocol for embedded devices used and developed by Amfitech. The protocol can be extended with plugins for specific devices implementing the Amfiprot protocol (e.g. the AmfiTrack).



  - Python 3.6 or higher.



  Install (or update) `amfiprot` with `pip`:

  ```shell
  pip install -U amfiprot
  ```



  The basic workflow when using the library is:

  1. Create a `Connection` to a device connected directly to the host machine (we call this the "root node").
  2. Search for `Node`s on the `Connection` (i.e. nodes connected through the root node)
  3. Create a `Device` using one of the discovered `Node`s.
  4. Start the `Connection`.
  5. Communicate with the `Device`.

  Example:

  ```python
  import amfiprot

  VENDOR_ID = 0xC17
  PRODUCT_ID = 0xD12

  if __name__ == "__main__":
      conn = amfiprot.USBConnection(VENDOR_ID, PRODUCT_ID)
      nodes = conn.find_nodes()

      print(f"Found {len(nodes)} node(s).")
      for node in nodes:
          print(f"[{node.tx_id}] {node.name}")

      dev = amfiprot.Device(nodes[0])
      conn.start()

      cfg = dev.config.read_all()

      while True:
          if dev.packet_available():
              print(dev.get_packet())
  ```

  The following sections provide a more in-depth explanation.



  After attaching a device to your host machine, you can scan for connected devices (e.g. connected via USB) with:

  ```python
  phys_devs = amfiprot.USBConnection.discover()

  for dev in phys_devs:
      print(dev)
  ```

  A connection can then be created using a specific physical device:

  ```python
  conn = amfiprot.USBConnection(dev['vid'], dev['pid'], dev['serial_number'])
  ```

  Using `serial_number` is optional. If none is given, the first device matching the given vendor and product ID is used.



  After creating a connection, we can search for nodes that are connected to the root node (e.g. via RF or UART):

  ```python
  nodes = conn.find_nodes()
  ```

  `find_nodes()` returns a list of `Node` instances. A `Node` provides a low-level interface to the physical device and can be used to retrieve the `uuid`, `tx_id` and `name` of the device, and send/receive raw packets. It is not recommended to use the `Node` directly, but rather attach it to a `Device` instance.



  A `Device` is an abstraction layer on top of a `Node` and is created by injecting a `Node` in the constructor:

  ```python
  dev = amfiprot.Device(node)
  ```

  The `Device` provides a higher-level interface allowing the user to easily:

  - Update the firmware
  - Reboot the device
  - Read/write configurations
  - Read decoded packets

  We are still able to access the `Node` through the `Device` if necessary:

  ```python
  tx_id = dev.node.tx_id
  ```



  Before interacting with the `Device`, the `Connection` must be started:

  ```python
  conn.start()
  ```

  This creates a child process that asynchronously sends and receives packets on the specified interface. We can now interact with the `Device` in the main process without worrying about blocking:

  ```python
  device_name = dev.name()
  print(f"Reading packets from {device_name}...")

  while True:
  	if dev.packet_available():
  		print(dev.get_packet())
  ```

  We can access the device configuration through a `Configurator` instance which is automatically created as a member (`dev.config`) of the `Device`:

  ```python

  cfg = dev.config.read_all()


  for category in cfg:
      print(f"CATEGORY: {category['name']}")
      for parameter in category['parameters']:
          print(parameter)
  ```

  The configuration can be easily saved to and loaded from a `.json` file:

  ```python
  import json


  with open("config.json", "w") as outfile:
  	json.dump(cfg, outfile, indent=4)


  with open("config.json", "r") as infile:
      new_cfg = json.load(infile)
      dev.config.write_all(new_cfg)
  ```



  The Amfiprot Python package is open-source and the source code can be found on our [Github repository](https://github.com/amfitech/amfiprot). Contributions can be made through pull requests to the `development` branch. Bug reports and feature requests can be created in the [Issues](https://github.com/amfitech/amfiprot/issues) tab.


pkgId: 5671d9e5a085171b04e5c178426df8dc352321c3c4c87392dde79defb741f8c8
name: python-amfiprot-amfitrack
arch: src
version: 0.0.1a14
epoch: 0
release: 1
summary: AmfiTrack extension for Amfiprot
url: https://pypi.org/project/amfiprot-amfitrack/
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amfiprot-amfitrack-0.0.1a14-1.src.rpm
checksum_type: sha256
description:
  AmfiTrack extensions for the [Amfiprot](https://pypi.org/project/amfiprot/) package.


  Install (or update) with `pip`:

  ```shell
  pip install -U amfiprot-amfitrack
  ```


  Instead of creating a generic `amfiprot.Device`, create an `amfitrack.Device` to get access to AmfiTrack specific functionality and payload interpretation:

  ```python
  import amfiprot
  import amfiprot_amfitrack as amfitrack

  VENDOR_ID = 0xC17
  PRODUCT_ID_SENSOR = 0xD12
  PRODUCT_ID_SOURCE = 0xD01

  if __name__ == "__main__":
      conn = None
      try:
          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).")
      for node in nodes:
          print(f"[{node.tx_id}] {node.name}")

      dev = amfitrack.Device(nodes[0])
      conn.start()

      cfg = dev.config.read_all()
      dev.calibrate()

      while True:
          if dev.packet_available():
              packet = dev.get_packet()
              if type(packet.payload) == amfitrack.payload.EmfImuFrameIdPayload:
                  payload: amfitrack.payload.EmfImuFrameIdPayload = packet.payload
                  print(payload.emf)
              else:
                  print(packet)
  ```


pkgId: a6cfa19f7dfa8257c654901e12112e5d667eab88dca4d2706fa0e2d51677a04c
name: python-amg-player
arch: src
version: 2024.3.12.0
epoch: 0
release: 1
summary: Browse & play embedded tracks from Angry Metal Guy music reviews
url: https://github.com/desbma/amg-player
rpm_license: GNU General Public License v3 (GPLv3)
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amg-player-2024.3.12.0-1.src.rpm
checksum_type: sha256
description:
  [![Latest version](https://img.shields.io/pypi/v/amg-player.svg?style=flat)](https://pypi.python.org/pypi/amg-player/)
  [![Tests status](https://github.com/desbma/amg-player/actions/workflows/ci.yml/badge.svg)](https://github.com/desbma/amg-player/actions)
  [![Coverage](https://img.shields.io/coveralls/desbma/amg-player/master.svg?style=flat)](https://coveralls.io/github/desbma/amg-player?branch=master)
  [![Lines of code](https://tokei.rs/b1/github/desbma/amg-player)](https://github.com/desbma/amg-player)
  [![Supported Python versions](https://img.shields.io/pypi/pyversions/amg-player.svg?style=flat)](https://pypi.python.org/pypi/amg-player/)
  [![License](https://img.shields.io/github/license/desbma/amg-player.svg?style=flat)](https://pypi.python.org/pypi/amg/)

  Angry Metal Guy Player (AMG Player) is a Python multi platform console tool to automatically play or download tracks from [Angry Metal Guy](https://www.angrymetalguy.com/) reviews.

  I created this because:

  - I like Angry Metal Guy, and discovered great music (both metal and totally non-metal) thanks to their reviews
  - I often disagree with their ratings (in fact I disagree more often than I agree), both for overrating and underrating
  - Even when I disagree, I like reading their reviews
  - I want to listen to the music **before** I read the review, to avoid getting influenced
  - To be efficient, I want to listen to the tracks like a radio, and read the review to learn more only when I like something



  - Can work either in interactive mode (manually select tracks) or totally automatic (play new tracks like a radio)
  - Supports embedded tracks from: YouTube, Bandcamp, SoundCloud, ReverbNation
  - Plays 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 later



  Selection screen:
  [![selection image](https://i.imgur.com/Ijrjd0Am.png)](https://i.imgur.com/Ijrjd0A.png)

  Playing a track:
  [![playing image](https://i.imgur.com/pXUScj2m.png)](https://i.imgur.com/pXUScj2.png)



  Angry Metal Guy Player requires [Python](https://www.python.org/downloads/) >= 3.7.
  Some features are only available if [FFmpeg](https://ffmpeg.org/download.html) >= 2.8 is installed.



  1. If you don't already have it, [install pip](https://pip.pypa.io/en/stable/installing/) for Python 3
  2. Install Angry Metal Guy Player: `pip3 install amg-player`



  1. If you don't already have it, [install setuptools](https://pypi.python.org/pypi/setuptools#installation-instructions) for Python 3
  2. Clone this repository: `git clone https://github.com/desbma/amg-player`
  3. Install Angry Metal Guy Player: `python3 setup.py install`

  **Angry Metal Guy Player only supports [MPV player](https://mpv.io/) for now.**



  Run `amg -h` to get full command line reference.



  - Browse and play interactively last 50 reviews:

    `amg -c 50`

  - Choose the first track to play, then play all tracks in chronological order:

    `amg -m radio`

  - Play last 20 tracks in chronological order, skipping those already played:

    `amg -c 20 -m discover`



  [GPLv3](https://www.gnu.org/licenses/gpl-3.0-standalone.html)


pkgId: 5a751ec903157f337af22f2181da2cad6b12f35ce40e523d6315ef67782cf521
name: python-amino.api
arch: src
version: 0.2.5.6
epoch: 0
release: 1
summary: Library for creating amino bots and scripts.
url: https://github.com/xXxCLOTIxXx/amino.py
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amino.api-0.2.5.6-1.src.rpm
checksum_type: sha256
description:
  <body>
  	<table align="center">
  		<tr> <th colspan="3">Library Information</th> </tr>
  		<tr>
  			<td>
  				<a href='#'><img src="https://pbs.twimg.com/profile_images/525686734760067072/OhsWgbsr_400x400.png" height="30px">
  				 Library Documentation</a>
  			</td>
  			<td>
  				<a href='https://github.com/xXxCLOTIxXx/amino.py'><img src="https://upload.wikimedia.org/wikipedia/commons/9/91/Octicons-mark-github.svg" height="60px">
  				 Library in github</a>
  			</td>
  	</table>
  	<table align="center">
  		</tr>
  		<tr> <th colspan="3">More info</th> </tr>
  		<tr>
  			<td>
  				<a href="https://t.me/amino_api"><img src="https://upload.wikimedia.org/wikipedia/commons/8/82/Telegram_logo.svg" height="30px">
  				 Telegram Channel</a>
  			</td>
  			<td>
  				<a href="https://www.youtube.com/channel/UCNKEgQmAvt6dD7jeMLpte9Q"><img src="https://upload.wikimedia.org/wikipedia/commons/0/09/YouTube_full-color_icon_%282017%29.svg" height="30px">
  				 YouTube channel</a>
  			</td>
  			<td>
  				<a href="https://discord.gg/GtpUnsHHT4"><img src="https://www.svgrepo.com/show/353655/discord-icon.svg" height="30px">
  				 Discord Server</a>
  			</td>
  		</tr>
  	</table>
  <p align="center">Library for working with aminoapps servers, below you will see code examples, for more examples see the documentation or the examples folder</p>
  <h1 align="center">Login example</h1>

  ```python
  import amino

  client = amino.Client()
  client.login(email='email', password='password')
  ```

  </body>


pkgId: 277c9358900ea70675e5346217bc8892cbf02b450a37b32739d6a4b9f77b7815
name: python-amino.fix
arch: src
version: 2.3.6.1
epoch: 0
release: 1
summary: Library for Amino. Discord - https://discord.gg/Bf3dpBRJHj
url: https://github.com/Minori100/Amino.fix
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amino.fix-2.3.6.1-1.src.rpm
checksum_type: sha256
description:
  `https://discord.gg/Bf3dpBRJHj`

  `Fix Amino.py 1.2.17`

  `pip install amino.fix`

  [Read the Docs Link](https://aminopy.readthedocs.io/en/latest/)


pkgId: 31af1e8cabef30568cb33dbd436d7dea429931d08c5ed0016c7f32b3b326a34f
name: python-amira
arch: src
version: 2.0.3
epoch: 0
release: 1
summary: Automated Malware Incident Response and Analysis
url: https://github.com/Yelp/amira
rpm_license: The MIT License (MIT)
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amira-2.0.3-1.src.rpm
checksum_type: sha256
description:
  ![amira](https://raw.githubusercontent.com/Yelp/amira/master/amira_github_banner.png)

  [![PyPI](https://img.shields.io/pypi/v/amira.svg)](https://pypi.python.org/pypi/amira)
  [![Build Status](https://github.com/Yelp/amira/actions/workflows/build.yaml/badge.svg)](https://github.com/Yelp/amira/actions/workflows/build.yaml)



  AMIRA is a service for automatically running the analysis on the
  [OSXCollector](https://github.com/Yelp/osxcollector) output files.
  The automated analysis is performed via
  [OSXCollector Output Filters](https://github.com/Yelp/osxcollector_output_filters),
  in particular *The One Filter to Rule Them All*: the
  [Analyze Filter](https://github.com/Yelp/osxcollector_output_filters#analyzefilter---the-one-filter-to-rule-them-all).
  AMIRA takes care of retrieving the output files from an S3 bucket,
  running the Analyze Filter and then uploading the results
  of the analysis back to S3 (although one could envision as well
  attaching them to the related JIRA ticket).





  The following steps assume you have [tox](http://tox.readthedocs.org/)
  installed on your machine.

  If this is not the case, please run:
  ```bash
  $ sudo pip install tox
  ```



  AMIRA uses OSXCollector Output Filters to do the actual analysis,
  so you will need to have a valid `osxcollector.yaml`
  configuration file in the working directory.
  The example configuration file can be found in the
  [OSXCollector Output Filters](https://github.com/Yelp/osxcollector_output_filters/blob/master/osxcollector.yaml.example).

  The configuration file mentions the location of the file hash and the domain
  blacklists.
  Make sure that the blacklist locations mentioned in the configuration file are
  also available when running AMIRA.



  AMIRA uses boto3 to interface with AWS.
  You can supply credentials using either of the possible
  [configuration options](https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html).

  The credentials should allow reading and deleting SQS messages
  from the SQS queue specified in the AMIRA config as well as
  the read access to the objects in the S3 bucket where the OSXCollector
  output files are stored.
  To be able to upload the analysis results back to the S3 bucket
  specified in the AMIRA configuration file, the credentials should
  also allow write access to this bucket.



  The service uses the
  [S3 bucket event notifications](http://docs.aws.amazon.com/AmazonS3/latest/dev/NotificationHowTo.html)
  to trigger the analysis.
  You will need to configure an S3 bucket for the OSXCollector output files,
  so that when a file is added there the notification will be sent to an SQS queue
  (`AmiraS3EventNotifications` in the picture below).
  AMIRA periodically checks the queue for any new messages
  and upon receiving one it will fetch the OSXCollector output file from the S3
  bucket.
  It will then run the Analyze Filter on the retrieved file.

  The Analyze Filter runs all the filters contained in the OSXCollector Output
  Filters package sequentially. Some of them communicate with the external
  resources, like domain and hashes blacklists (or whitelists) and threat intel
  APIs, e.g. [VirusTotal](https://github.com/Yelp/threat_intel#virustotal-api),
  [OpenDNS Investigate](https://github.com/Yelp/threat_intel#opendns-investigate-api)
  or [ShadowServer](https://github.com/Yelp/threat_intel#shadowserver-api).
  The original OSXCollector output is extended with all of this information and
  the very last filter run by the Analyze Filter summarizes all of the findings
  into a human-readable form. After the filter finishes running, the results of
  the analysis will be uploaded to the Analysis Results S3 bucket.

  The overview of the whole process and the system components involved in it are
  depicted below:

  ![component diagram](https://github.com/Yelp/amira/raw/master/doc/component_diagram.png "Component Diagram")



  The main entry point to AMIRA is in the `amira/amira.py` module.
  You will first need to create an instance of AMIRA class by providing the AWS
  region name, where the SQS queue with the event notifications for the
  OSXCollector output bucket is, and the SQS queue name:

  ```python
  from amira.amira import AMIRA

  amira = AMIRA('us-west-1', 'AmiraS3EventNotifications')
  ```

  Then you can register the analysis results uploader, e.g. the S3 results
  uploader:

  ```python
  from amira.s3 import S3ResultsUploader

  s3_results_uploader = S3ResultsUploader('amira-results-bucket')
  amira.register_results_uploader(s3_results_uploader)
  ```

  Finally, run AMIRA:
  ```python
  amira.run()
  ```

  Go get some coffee, sit back, relax and wait till the analysis results pop up
  in the S3 bucket!


pkgId: a0b1e910b18c294da76d7eee8e45f6770a6e22572b6310b4759ebc30205839ab
name: python-amira-amr
arch: src
version: 0.3.1
epoch: 0
release: 1
summary: Amira
url: https://github.com/Danderson123/amira
rpm_license: Apache-2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amira-amr-0.3.1-1.src.rpm
checksum_type: sha256
description:
  Amira is an AMR gene detection tool designed to work directly from bacterial long read sequences. Amira makes it easy to reliably identify the AMR genes in a bacterial sample, reduces the time taken to get meaningful results and allows more accurate detection of AMR genes than assembly.



  Amira leverages the full length of long read sequences to differentiate multi-copy genes by their local genomic context. This is done by first identifying the genes on each sequencing read and using the gene calls to construct a *de Bruijn* graph (DBG) in gene space. Following error correction, the reads containing different copies of multi-copy AMR genes can be clustered together based on their path in the graph, then assembled to obtain the nucleotide sequence.



  Amira requires Python and three additional non-Python tools for optimal functionality:

  - **Python >=3.9,<3.13**.
  - **Poetry** to manage the Python dependencies.
  - **Pandora** to identify the genes on each sequencing read.
  - **minimap2** for sequence alignment.
  - **racon** for allele polishing.



  Follow these steps to install Amira and its dependencies.





  Open a terminal and run the following command to clone the repository and navigate into it:
  ```bash
  git clone https://github.com/Danderson123/Amira && cd Amira
  ```

  Amira’s dependencies are managed with Poetry. Install Poetry by running:
  ```bash
  pip install poetry
  ```

  Once Poetry is installed, use it to set up Amira’s dependencies:

  ```bash
  poetry install
  ```

  Amira requires Pandora, minimap2 and racon. Follow the links below for instructions on building binaries for each tool:

  - [Pandora Installation Guide](https://github.com/iqbal-lab-org/pandora?tab=readme-ov-file#installation)
  - [minimap2 Installation Guide](https://github.com/lh3/minimap2)
  - [racon Installation Guide](https://github.com/isovic/racon)

  After installation, make a note of the paths to these binaries as they will be required when running Amira.



  Amira can be installed from PyPI by running:
  ```bash
  pip install amira-amr
  ```
  Amira can then be run with:
  ```bash
  amira --help
  ```

  Amira can be run on the output of Pandora directly, or from JSON files listing the genes and gene positions on each sequencing read. Below are instructions and an example command for running Amira with the JSON files.


  To run Amira from the JSON files, you can use this command. You will need to replace `<PATH TO RACON BINARY>` with the absolute path to the racon binary you made earlier and replace `<PATH TO MINIMAP2 BINARY>` with the path to the minimap2 binary.
  ```
  python3 amira/__main__.py --pandoraJSON <PATH TO GENE CALL JSON> --gene-positions <PATH TO GENE POSITION JSON> --pandoraConsensus <PATH TO PANDORA CONSENSUS FASTQ> --readfile <PATH TO READ FASTQ> --output <OUTPUT DIRECTORY> --gene-path <AMR GENE REFERENCE FASTA> --phenotypes <ALLELE-PHENOTYPE MAPPING JSON> --racon-path <PATH TO RACON BINARY> --minimap2-path <PATH TO MINIMAP2 BINARY> --debug --cores <CPUS> --sample-reads --filter-contaminants
  ```



  Some example JSON data can be downloaded from [here](https://drive.google.com/drive/folders/1mQ8JmzVhFiNkgRy5_1iFQrqV2TLNnlQ4). Amira can then be run using this command:
  ```
  python3 amira/__main__.py --pandoraJSON test_data/gene_calls_with_gene_filtering.json --gene-positions test_data/gene_positions_with_gene_filtering.json --pandoraConsensus test_data/pandora.consensus.fq.gz --readfile test_data/SRR23044220_1.fastq.gz --output amira_output --gene-path AMR_alleles_unified.fa --phenotypes AMR_calls.json --racon-path <PATH TO RACON BINARY> --minimap2-path <PATH TO MINIMAP2 BINARY> --debug --cores <CPUS> --sample-reads --filter-contaminants
  ```


  [Pandora](https://github.com/iqbal-lab-org/pandora) uses species-specific reference pan-genomes (panRGs) to identify the genes on each sequencing read. For *Escherichia coli*, a pre-built panRG can be downloaded from [here](https://drive.google.com/file/d/15uyl7iQei3Ikd2d6oI_XbARXiKmxl-2d/view). After installing Pandora, you can call the genes on your sequencing reads using this command:
  ```bash
  pandora map -t <THREADS> --min-gene-coverage-proportion 0.5 --max-covg 10000 -o pandora_map_output <PANRG PATH> <PATH TO READ FASTQ>
  ```
  Amira can then be run directly on the output of Pandora using this command:
  ```bash
  python3 amira/__main__.py --pandoraSam pandora_map_output/*.sam --pandoraConsensus pandora_map_output/pandora.consensus.fq.gz --readfile <PATH TO READ FASTQ> --output amira_output --gene-path AMR_alleles_unified.fa --minimum-length-proportion 0.5 --maximum-length-proportion 1.5 --cores <CPUS> --phenotypes AMR_calls.json --filter-contaminants --sample-reads
   ```


  For additional options and configurations, run:
  ```bash
  python3 amira/__main__.py --help
  ```

  TBD


  If you’d like to contribute to Amira, please follow these steps:

  1. Fork the repository.
  2. Create a new branch for your feature or bugfix (git checkout -b feature-name).
  3. Commit your changes (git commit -m "Description of feature").
  4. Push to the branch (git push origin feature-name).
  5. Submit a pull request.


  This project is licensed under the Apache License 2.0 License. See the LICENSE file for details.


  For questions, feedback, or issues, please open an issue on GitHub or contact [Daniel Anderson](<mailto:dander@ebi.ac.uk>).


  * [Pandora Documentation](https://github.com/iqbal-lab-org/pandora/wiki/Usage)


pkgId: 5aa5d0750d39b91069ef200d5394f24879baf0f2d486b5db695cf704b664c143
name: python-amirispy
arch: src
version: 2.2.1
epoch: 0
release: 1
summary: Python tools for the electricity market model AMIRIS
url: https://dlr-ve.gitlab.io/esy/amiris/home/
rpm_license: Apache-2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amirispy-2.2.1-1.src.rpm
checksum_type: sha256
description:
  <!-- SPDX-FileCopyrightText: 2024 German Aerospace Center <amiris@dlr.de>

  SPDX-License-Identifier: Apache-2.0 -->

  [![PyPI version](https://badge.fury.io/py/amirispy.svg)](https://badge.fury.io/py/amirispy)
  [![PyPI license](https://img.shields.io/pypi/l/amirispy.svg)](https://badge.fury.io/py/amirispy)
  [![pipeline status](https://gitlab.com/dlr-ve/esy/amiris/amiris-py/badges/main/pipeline.svg)](https://gitlab.com/dlr-ve/esy/amiris/amiris-py/commits/main)



  Python tools for the electricity market model [AMIRIS](https://dlr-ve.gitlab.io/esy/amiris/home/).



      pip install amirispy

  You may also use `pipx`. For detailed information please refer to the
  official `pipx` [documentation](https://github.com/pypa/pipx).

      pipx install amirispy




  In order to execute all commands provided by `amirispy`, you also require a Java Development Kit (JDK).
  JDK must be installed and accessible via your console in which you run `amirispy`.

  To test, run `java --version` which should show your JDK version (required: 11 or above).
  If `java` command is not found or relates to a Java Runtime Environment (JRE), please download and install JDK (e.g.
  from [Adoptium](https://adoptium.net/de/temurin/releases/?version=17))


  Currently, there are three distinct commands available:

  - `amiris install`: installation of the [latest AMIRIS version](https://gitlab.com/dlr-ve/esy/amiris/amiris)
    and [examples](https://gitlab.com/dlr-ve/esy/amiris/examples) to your computer
  - `amiris run`: perform a full workflow by compiling the `.pb` file from your `scenario.yaml`, executing AMIRIS, and
    converting results
  - `amiris batch`: perform multiple runs each with scenario compilation, AMIRIS execution, and results extraction
  - `amiris comparison`: compare the results of two different AMIRIS runs to check them for their equivalence

  You may also use the arguments as a list of strings in your script directly, e.g.

  ```python
  from amirispy.scripts import amiris_cli

  amiris_cli(["install", "-m", "model"])
  ```


  Downloads and installs the latest open access AMIRIS instance and accompanying examples.

  | Option             | Action                                                                                                                                                       |
  |--------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------|
  | `-u` or `--url`    | URL to download AMIRIS from (default: latest AMIRIS artifact from [https://gitlab.com/dlr-ve/esy/amiris/amiris](https://gitlab.com/dlr-ve/esy/amiris/amiris) |
  | `-t` or `--target` | Folder to install `amiris-core_<version>-jar-with-dependencies.jar` to (default: `./`)                                                                       |
  | `-f` or `--force`  | Force install which may overwrites existing AMIRIS installation of same version and existing examples (default: False)                                       |
  | `-m` or `--mode`   | Option to install model and examples `all` (default), only `model`, or only `examples`                                                                       |


  Compile scenario, execute AMIRIS, and extract results.

  | Option                      | Action                                                                                                                                                            |
  |-----------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------|
  | `-j` or `--jar`             | Path to `amiris-core_<version>-jar-with-dependencies.jar`                                                                                                         |
  | `-s` or `--scenario`        | Path to a scenario yaml-file                                                                                                                                      |
  | `-o` or `--output`          | Directory to write output to, defaults to "./results"                                                                                                             |
  | `-oo` or `--output-options` | Optional arguments to override default output [conversion arguments of fameio](https://gitlab.com/fame-framework/fame-io/-/blob/main/README.md#read-fame-results) |
  | `-nc` or `--no-checks`      | Skip checks for Java installation and correct version to increase speed                                                                                           |


  Perform multiple runs - each with scenario compilation, AMIRIS execution, and results extraction

  | Option                 | Action                                                                        |
  |------------------------|-------------------------------------------------------------------------------|
  | `-j` or `--jar`        | Path to `amiris-core_<version>-jar-with-dependencies.jar`                     |
  | `-s` or `--scenarios`  | Path to single or list of: scenario yaml-files or their enclosing directories |
  | `-o` or `--output`     | Directory to write output to                                                  |
  | `-r` or `--recursive`  | Option to recursively search in provided Path for scenario (default: False)   |
  | `-p` or `--pattern`    | Optional name pattern that scenario files searched for must match             |
  | `-nc` or `--no-checks` | Skip checks for Java installation and correct version to increase speed       |


  Compare if results of two AMIRIS runs and equivalent.

  | Option               | Action                                                            |
  |----------------------|-------------------------------------------------------------------|
  | `-e` or `--expected` | Path to folder with expected result .csv files                    |
  | `-t` or `--test`     | Path to folder with results files (.csv) to test  for equivalence |
  | `-i` or `--ignore`   | Optional list of file names not to be compared                    |



  You reach the help menu at any point using `-h` or `--help` which gives you a list of all available options, e.g.:

  `amiris --help`



  You may define a logging level or optional log file as **first** arguments in your workflow using any of the following
  arguments:

  | Option               | Action                                                                                                           |
  |----------------------|------------------------------------------------------------------------------------------------------------------|
  | `-l` or `--log`      | Sets the logging level. Default is `error`. Options are `debug`, `info`, `warning`, `warn`, `error`, `critical`. |
  | `-lf` or `--logfile` | Sets the logging file. Default is `None`. If `None` is provided, all logs get only printed to the console.       |

  Example: `amiris --log debug --logfile my/log/file.txt install`


  If you use AMIRIS-Py for academic work, please cite:

  Christoph Schimeczek, Kristina Nienhaus, Ulrich Frey, Evelyn Sperber, Seyedfarzad Sarfarazi, Felix Nitsch, Johannes
  Kochems & A. Achraf El Ghazi (2023). AMIRIS: Agent-based Market model for the Investigation of Renewable and Integrated
  energy Systems. Journal of Open Source Software. doi: [10.21105/joss.05041](https://doi.org/10.21105/joss.05041)


  Please see [CONTRIBUTING](CONTRIBUTING.md).


  This is a purely scientific project by (at the moment) one research group.
  Thus, there is no paid technical support available.

  If you experience any trouble with AMIRIS, you may contact the developers at
  the [openMod-Forum](https://forum.openmod.org/tag/amiris) or via [amiris@dlr.de](mailto:amiris@dlr.de).
  Please report bugs and make feature requests by filing issues following the provided templates (see
  also [CONTRIBUTING](CONTRIBUTING.md)).
  For substantial enhancements, we recommend that you contact us via [amiris@dlr.de](mailto:amiris@dlr.de) for working
  together on the code in common projects or towards common publications and thus further develop AMIRIS.


  Work on AMIRIS-Py was financed by the Helmholtz Association's Energy System Design research programme.


pkgId: 40b73a3fc315d202c19dee08dd1c6659c25ada7202aa78968eeeed3b068efaff
name: python-amis-python
arch: src
version: 1.0.8.post2
epoch: 0
release: 1
summary: 基于百度amis前端框架的python pydantic模型封装。
url: https://github.com/CMHopeSunshine/amis-py
rpm_license: Apache-2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amis-python-1.0.8.post2-1.src.rpm
checksum_type: sha256
description:
  <p align="center">
      <a href="https://cdn.jsdelivr.net/gh/CMHopeSunshine/amis-python@master/LICENSE"><img src="https://img.shields.io/github/license/CMHopeSunshine/amis-python" alt="license"></a>
      <img src="https://img.shields.io/badge/Python-3.7+-yellow" alt="python">
      <img src="https://img.shields.io/pypi/v/amis-python" alt="version">
  </p>

  基于 [百度amis](https://github.com/baidu/amis) 前端框架的python pydantic模型封装。

  由于[原版本](https://github.com/amisadmin/fastapi_amis_admin/tree/master/fastapi_amis_admin/amis)缺少大量amis新版本的组件或配置，因此本项目在其版本的基础上进行了扩充。

  相比fastapi-amis-admin的版本：
  - 涵盖amis截至3.1.0版本的所有组件
  - 使用jinja2模板
  - 支持修改主题

  ```
  pip install amis-python
  ```

  ```python
  from amis.components import Page

  page = Page(title='新页面', body='Hello World')

  print(page.to_dict())

  print(page.to_json())

  print(page.render())

  with open('HelloWorld.html', 'w', encoding='utf-8') as f:
      f.write(page.render())
  ```


  详见[amis官方文档](https://aisuda.bce.baidu.com/amis/zh-CN/docs/index)


  - [amis](https://github.com/baidu/amis)
  - [fastapi-amis-admin](https://github.com/amisadmin/fastapi_amis_admin/tree/master/fastapi_amis_admin/amis)


pkgId: ed19655dab3959003d72ee1c8e9b50766d1358afc41dc2a9f9f169f2aaccb3cf
name: python-amisrsynthdata
arch: src
version: 1.1.7
epoch: 0
release: 1
summary: Tool for generating synthetic AMISR data files.
url: https://github.com/amisr/amisrsynthdata
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amisrsynthdata-1.1.7-1.src.rpm
checksum_type: sha256
description:
  This module provides tools to create synthetic data files for the AMISR (Advanced Module Incoherent Scatter Radar) systems.  The files are based on both a specified ionospheric state and a radar configuration.  This can be used to generate synthetic data in the "SRI data format" both for the three existing AMISRs and for hypothetical future "AMISR-like" systems.  Primarily, it was designed to help test the functionality of various inversion algorithms that attempt to create a complete picture of ionospheric state parameters from discrete measurements by creating a way to check the output of these algorithms against known "truth" data.  Please note that this module does NOT attempt to simulate any aspect of fundamental ISR theory.

rpm_license:
[cell repeats an earlier one in this file: 34486 characters]


pkgId: 2edbbea14fef00d3b0012a16a5bd88ac6eec1f8934ca1cf005af15de83aa8890
name: python-amlaidatatests
arch: src
version: 0.1.11
epoch: 0
release: 1
summary: Data tests for Google AML AI
url: https://amlaidatatests.readthedocs.io/en/latest/
rpm_license: Apache-2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amlaidatatests-0.1.11-1.src.rpm
checksum_type: sha256
description:
  User guide and documentation for amlaidatatests are located at https://amlaidatatests.readthedocs.io/en/latest/.

  To build the docs:
  1. `sphinx-autobuild docs docs/_build/html`



  Please raise any issues with amlaidatatests at on [github](https://github.com/ground-truth-ai/amlaidatatests/issues).


pkgId: 2a2cdea260c161818985ce23b51460bf7f11be21222336dff73313cb9c9e14f2
name: python-amlpp
arch: src
version: 0.1.9.7
epoch: 0
release: 1
summary: Wrapper for ml library
url: https://github.com/Asirg/amlpp
rpm_license: MIT License
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amlpp-0.1.9.7-1.src.rpm
checksum_type: sha256
description:
  library wrapper for ml libraries.


  The main class is a conveyor as an analogue of a pipeline. There is a partial interchangeability. The focus is on expanding built-in capabilities such as auto-typing predictive models, feature importance inference, scores, and various future features. There are also adapted transformers, classes for customizing the structure of projects.


  At the moment, the functionality is not wide, designed for expansion in the future


pkgId: c0ee8667b175baa34d5144304b257cd8023906c3a432be9bb780032e2dded64b
name: python-amltk
arch: src
version: 1.12.1
epoch: 0
release: 1
summary: AutoML Toolkit: a toolkit for building automl system
url: https://pypi.org/project/amltk/
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amltk-1.12.1-1.src.rpm
checksum_type: sha256
description:
  [![image](https://img.shields.io/pypi/v/amltk.svg)](https://pypi.python.org/pypi/amltk)
  [![image](https://img.shields.io/pypi/l/amltk.svg)](https://pypi.python.org/pypi/amltk)
  [![image](https://img.shields.io/pypi/pyversions/amltk.svg)](https://pypi.python.org/pypi/amltk)
  [![Actions](https://github.com/automl/amltk/actions/workflows/test.yml/badge.svg)](https://github.com/automl/amltk/actions)
  [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)


  A framework for building an AutoML System. The toolkit is designed to be modular and extensible, allowing you to
  easily swap out components and integrate your own. The toolkit is designed to be used in a variety of different
  ways, whether for research purposes, building your own AutoML Tool or educational purposes.

  We focus on building complex parametrized pipelines easily, providing tools to optimize these pipeline parameters and
  lastly, providing tools to schedule compute tasks on a variety of different compute backends, without the need to
  refactor everything, once you swap out any one of these.

  The goal of this toolkit is to drive innovation for AutoML Systems by:
  1. Allowing concise research artifacts that can study different design decisions in AutoML.
  2. Enabling simple prototypes to scale to the compute you have available.
  3. Providing a framework for building real and robust AutoML Systems that are extensible by design.

  Please check out our documentation for more:
  * [Documentation](https://automl.github.io/amltk/) - The homepage
  * [Guides](https://automl.github.io/amltk/latest/guides) - How to use the `Pipelines`, `Optimizers` and `Schedulers` in
    a walkthrough fashion.
  * [Reference](https://automl.github.io/amltk/latest/reference) - A short-overview reference for the various components
    of the toolkit.
  * [Examples](https://automl.github.io/amltk/latest/examples) - A collection of examples for using the toolkit in
    different ways.
  * [API](https://automl.github.io/amltk/latest/api) - The full API reference for the toolkit.


  To install AutoML Toolkit (`amltk`), you can simply use `pip`:

  ```bash
  pip install amltk
  ```

  > [!TIP]
  > We also provide a list of optional dependencies which you can install if you intend to use them.
  > This allows the toolkit to be as lightweight as possible and play nicely with the tools you use.
  > * `pip install amltk[notebook]` - For usage in a notebook
  > * `pip install amltk[sklearn]` - For usage with scikit-learn
  > * `pip install amltk[smac]` - For using SMAC as an optimizer
  > * `pip install amltk[optuna]` - For using Optuna as an optimizer
  > * `pip install amltk[pynisher,  threadpoolctl, wandb]` - Various plugins for running compute tasks
  > * `pip install amltk[cluster, dask, loky]` - Different compute backends to run from


  To install from source, you can clone this repo and install with `pip`:

  ```bash
  git clone git@github.com:automl/amltk.git
  pip install -e amltk  # -e for editable mode
  ```

  If planning to contribute, you can install the development dependencies but we
  highly recommend checking out our [contributing guide](https://automl.github.io/amltk/latest/contributing) for more.

  ```bash
  pip install -e "amltk[dev]"
  ```



  Here's a brief overview of 3 of the core components from the toolkit:


  Define **parametrized** machine learning pipelines using a fluid API:
  ```python
  from sklearn.ensemble import RandomForestClassifier
  from sklearn.impute import SimpleImputer
  from sklearn.preprocessing import OneHotEncoder
  from sklearn.svm import SVC

  from amltk.pipeline import Choice, Component, Sequential

  pipeline = (
      Sequential(name="my_pipeline")
      >> Component(SimpleImputer, space={"strategy": ["mean", "median"]})  # Choose either mean or median
      >> OneHotEncoder(drop="first")  # No parametrization, no problem
      >> Choice(
          
          Component(
              RandomForestClassifier,
              space={"n_estimators": (10, 100), "criterion": ["gini", "log_loss"]},
              config={"max_depth": 3},
          ),
          Component(SVC, space={"kernel": ["linear", "rbf", "poly"]}),
          name="estimator",
      )
  )


  search_space = pipeline.search_space(parser="configspace")
  config = search_space.sample_configuration()


  configured_pipeline = pipeline.configure(config)


  model = configured_pipeline.build(builder="sklearn")
  ```


  Optimize your pipelines using a variety of different optimizers, with a unified API and
  a suite of utility for recording and taking control of the optimization loop:

  ```python
  from amltk.optimization import Trial, Metric, History

  pipeline = ...
  accuracy = Metric("accuracy", maximize=True, bounds=(0. 1))
  inference_time = Metric("inference_time", maximize=False)

  def evaluate(trial: Trial) -> Trial.Report:
      model = pipeline.configure(trial.config).build("sklearn")

      try:
          
          with trial.profile("fit"):
              model.fit(...)

      except Exception as e:
          
          return trial.fail(exception=e)

      
      trial.summary["model_size"] = ...

      
      trial.store({"model.pkl": model, "predictions.npy": predictions}),
      return trial.success(accuracy=0.8, inference_time=...)


  from amltk.optimization.optimizers.smac import SMACOptimizer
  from amltk.optimization.optimizers.smac import OptunaOptimizer
  import random

  Optimizer = random.choice([SMACOptimizer, OptunaOptimizer])
  smac_optimizer = Optimizer(space=pipeline, metrics=[accuracy, inference_time], bucket="results")



  history = History()
  for _ in range(10):
      trial = optimizer.ask()
      report = evaluate(trial)
      history.add(report)
      optimizer.tell(report)

  print(history.df())
  ```

  > [!TIP]
  > Check out our [integrated optimizers](https://automl.github.io/amltk/latest/reference/optimization/optimizers) or integrate your own using the very
  > same API we use!


  Schedule your optimization jobs or AutoML tasks on a variety of different compute backends. By leveraging
  compute workers and asyncio, you can easily scale your compute needs, react to events as they happen and
  swap backends, without needing to modify your code!

  ```python
  from amltk.scheduling import Scheduler


  scheduler = Scheduler.with_processes(4)





  def expensive_function(x: int) -> float:
      return (2 ** x) / x

  task = scheduler.task(expensive_function)

  numbers = range(-5, 5)
  results = []


  @scheduler.on_start(repeat=4)
  def on_start():
      n = next(numbers)
      task.submit(n)


  @task.on_result
  def on_result(_, result: float):
      results.append(result)


  @task.on_result
  def launch_next(_, result: float):
      if (n := next(numbers, None)) is not None:
          task.submit(n)


  @task.on_exception
  def stop_something_went_wrong(_, exception: Exception):
      scheduler.stop()


  scheduler.run(timeout=10)


  ```

  > [!TIP]
  > Check out our [integrated compute backends](https://automl.github.io/amltk/latest/reference/scheduling/executors) or use your own!



  * [AutoML Fall School 2023 Colab](https://colab.research.google.com/drive/1aMfNhHDTXs-x8sxWtvX13vML9cytxeF1#forceEdit=true&sandboxMode=true)

rpm_license:
  Copyright 2023 AutoML-Freiburg-Hannover-Tübingen  Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.  3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.


pkgId: 52be87b7cd2341eec6cc5d23217f8029cb7d7f44a47282af00b59e1ca34635ee
name: python-ammar-filter-post
arch: src
version: 0.6.0
epoch: 0
release: 1
summary: A package to retrieve and sort DynamoDB posts by likes.
url: https://github.com/iammuhammadahmad/filteration
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ammar-filter-post-0.6.0-1.src.rpm
checksum_type: sha256
description:
  A Python package to retrieve all posts from a DynamoDB table and return them sorted by likes in descending order.


  ßßß


  - Install `twine` and `wheel` `setuptools`:

    ```bash
    pip install twine wheel setuptools


  In the root directory (ammar_filter_post/), run:

  ```bash
      python setup.py sdist bdist_wheel
  ```

  Upload to PyPI First, create an account on PyPI if you haven't already.

  ```bash
      twine upload dist/*
  ```
  You will be prompted to enter your PyPI username and password.


  ```bash
  pip install ammar_filter_post
  ```


  ```bash
      import boto3
      from ammar_filter_post.ammar_filter_post import get_posts_sorted_by_likes

      
      dynamodb = boto3.resource('dynamodb', region_name='your-region')
      table = dynamodb.Table('YourTableName')

      sorted_posts = get_posts_sorted_by_likes(table)

      for post in sorted_posts:
          print(post)
  ```


pkgId: 3c636493859cff1931b1e4bd6d3d8e4d91dce49bee8a76492e32db8107b43b3b
name: python-amo2kinto
arch: src
version: 4.0.2
epoch: 0
release: 1
summary: Generate a blocklists.xml file from the Kinto collections.
url: https://github.com/mozilla-services/amo2kinto
rpm_license: Apache License (2.0)
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amo2kinto-4.0.2-1.src.rpm
checksum_type: sha256
description:
  To install the release::
      pip install amo2kinto
  To install the development environment::
      make install


pkgId: 112e1e1f0d785886d457b3867c2647a8987e23e8931176ecef72f40501297dcb
name: python-amocrm-api-wrapper
arch: src
version: 0.0.18
epoch: 0
release: 1
summary: Amocrm api wrapper v4
url: https://github.com/bzdvdn/amocrm-api-wrapper
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amocrm-api-wrapper-0.0.18-1.src.rpm
checksum_type: sha256
description:
  ```python
  from amocrm_api import AmoLegacyClient # for login password auth
  from amocrm_api import AmoOAuthClient # for oauth
  from datetime import datetime
  client = AmoLegacyClient('<login>', '<password>', '<crm_url>')
  client = AmoOAuthClient('<access_token>', '<refresh_token>', '<crm_url>', '<client_id>', '<client_secret>', '<redirect_uri>')
  dt = datetime.datetime.today().strftime("%a, %d %b %Y %H-%m-%d")
  date_time = f"{dt} UTC"

  headers = {
      "IF-MODIFIED-SINCE": f"{date_time}",
      "Content-Type": "application/json",
  }
  client.update_session_params(headers)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/account-info
  - params:
  |          name          | type | default value |
  | :--------------------: | :--: | :-----------: |
  |     with_amojo_id      | bool |     False     |
  |   with_amojo_rights    | bool |     False     |
  |   with_users_groups    | bool |     False     |
  |    with_task_types     | bool |     False     |
  |      with_version      | bool |     False     |
  |   with_ventity_names   | bool |     False     |
  | with_datetime_settings | bool |     False     |
  ```python
  account_info = client.get_account_info()
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads-api#leads-add
  - params:
  |  name   | type | default value |
  | :-----: | :--: | :-----------: |
  | objects | list |       -       |
  ```python
  objects = [
      {
          "name": "Сделка для примера 1",
          "created_by": 0,
          "price": 20000,
          "custom_fields_values": [
              {
                  "field_id": 294471,
                  "values": [
                      {
                          "value": "Наш первый клиент"
                      }
                  ]
              }
          ]
      },
      {
          "name": "Сделка для примера 2",
          "price": 10000,
          "_embedded": {
              "tags": [
                  {
                      "id": 2719
                  }
              ]
          }
      }
  ]
  result = client.create_leads(objects)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads-api#leads-edit
  - params:
  |  name   | type | default value |
  | :-----: | :--: | :-----------: |
  | objects | list |       -       |
  ```python
  objects = [
      {
          "id": 54886,
          "pipeline_id": 47521,
          "status_id": 143,
          "date_close": 1589297221,
          "loss_reason_id": 7323,
          "updated_by": 0
      },
      {
          "id": 54884,
          "price": 50000,
          "pipeline_id": 47521,
          "status_id": 525743,
          "_embedded": {
              "tags": None
          }
      }
  ]
  result = client.update_leads(objects)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads-api#lead-detail
  - params:
  |  name   | type | default value |
  | :-----: | :--: | :-----------: |
  | lead_id | int  |       -       |
  ```python
  lead = client.get_lead(123)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads-api#leads-list
  - params:
  |    name     |      type      | default value |
  | :---------: | :------------: | :-----------: |
  |    limit    |      int       |      250      |
  |    page     |      int       |       1       |
  | with_params | Optional[list] |     None      |
  |   filters   | Optional[dict] |     None      |
  |    order    | Optional[dict] |     None      |
  ```python
  leads = client.get_leads(limit=10, page=3, filters={'updated_at__from': '<timestamp>', 'updated_at__to': '<timestamp>'})

  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/unsorted-api#unsorted-list
  - params:
  |         name          |          type          | default value |
  | :-------------------: | :--------------------: | :-----------: |
  |         limit         |          int           |      250      |
  |         page          |          int           |       1       |
  |    filter_by_uids     | Union[str, list, None] |     None      |
  | filter_by_pipeline_id | Union[str, list, None] |     None      |
  |  filter_by_category   | Union[str, list, None] |     None      |
  |       order_by        |     Optional[dict]     |     None      |
  ```python
  unsorted_leads = client.get_unsorted_leads(limit=10, page=3, filter_by_pipeline_id=[1, 2310, 8751035])
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/unsorted-api#unsorted-detail
  - params:
  | name | type | default value |
  | :--: | :--: | :-----------: |
  | uid  | str  |       -       |
  ```python
  unsorted_lead = client.get_unsorted_by_uid('ufsigkgdjlk13igmd')
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/unsorted-api#unsorted-add-sip
  - params:
  |    name     |     type      | default value |
  | :---------: | :-----------: | :-----------: |
  | source_uid  |      str      |       -       |
  | source_name |      str      |       -       |
  |  metadata   |     dict      |       -       |
  |  conctact   |     dict      |       -       |
  |    lead     |     dict      |       -       |
  |  comapany   |     dict      |       -       |
  | pipeline_id | Optional[int] |     None      |
  | created_at  | Optional[int] |     None      |
  | request_id  | Optional[int] |     None      |
  ```python
  unsorted_lead = {
          "request_id": "123",
          "source_name": "ОАО Коспромсервис",
          "source_uid": "a1fee7c0fc436088e64ba2e8822ba2b3",
          "pipeline_id": 2194576,
          "created_at": 1510261200,
          "leads": {
                  "name": "Тех обслуживание",
                  "price": 5000,
                  "custom_fields_values": [
                      {
                          "field_id": 284785,
                          "values": [
                              {
                                  "value": "Кастомное поле"
                              }
                          ]
                      }
                  ],
                  "_embedded": {
                      "tags": [
                          {
                              "id": 263809
                          }
                      ]
                  }
              }
          ],
          "contacts":
              {
                  "name": "Контакт для примера"
              }
          "companies":
              {
                  "name": "ОАО Коспромсервис"
              }
          },
          "metadata": {
              "is_call_event_needed": True,
              "uniq": "a1fe231cc88e64ba2e8822ba2b3ewrw",
              "duration": 54,
              "service_code": "CkAvbEwPam6sad",
              "link": "https://example.com",
              "phone": 79998888888,
              "called_at": 1510261200,
              "from": "onlinePBX"
          }
      }
  result = client.create_unsorted_by_sip(**unsorted_lead)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/unsorted-api#unsorted-add-form
  - params:
  |    name     |     type      | default value |
  | :---------: | :-----------: | :-----------: |
  | source_uid  |      str      |       -       |
  | source_name |      str      |       -       |
  |  metadata   |     dict      |       -       |
  |  conctact   |     dict      |       -       |
  |    lead     |     dict      |       -       |
  |  comapany   |     dict      |       -       |
  | pipeline_id | Optional[int] |     None      |
  | created_at  | Optional[int] |     None      |
  | request_id  | Optional[int] |     None      |
  ```python
  unsorted_lead = {
          "request_id": "123",
          "source_name": "ОАО Коспромсервис",
          "source_uid": "a1fee7c0fc436088e64ba2e8822ba2b3",
          "pipeline_id": 2194576,
          "created_at": 1590830520,
          "leads": {
              "name": "Тех обслуживание",
              "visitor_uid": "5692210d-58d0-468c-acb2-dce7f93eef87",
              "price": 5000,
              "custom_fields_values": [
                  {
                      "field_id": 284785,
                      "values": [
                          {
                              "value": "Дополнительное поле"
                          }
                      ]
                  }
              ],
              "_embedded": {
                  "tags": [
                      {
                          "name": "Тег для примера"
                      }
                  ]
              }
          },
          "contacts":
              {
                  "name": 234,
                  "first_name": "123213",
                  "last_name": 234,
                  "custom_fields_values": [
                      {
                          "field_code": "PHONE",
                          "values": [
                              {
                                  "value": "+7912321323"
                              }
                          ]
                      }
                  ]
              },
          "companies": {
              "name": "ОАО Коспромсервис"
          },
          "metadata": {
              "ip": "123.222.2.22",
              "form_id": "a1fee7c0fc436088e64ba2e8822ba2b3ewrw",
              "form_sent_at": 1590830520,
              "form_name": "Форма заявки для полёта в космос",
              "form_page": "https://example.com",
              "referer": "https://www.google.com/search?&q=elon+musk"
          }
      }
  result = client.create_unsorted_by_form(**unsorted_lead)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/unsorted-api#unsorted-accept
  - params:
  |   name    | type | default value |
  | :-------: | :--: | :-----------: |
  |    uid    | str  |       -       |
  |  user_id  | int  |       -       |
  | status_id | int  |       -       |
  ```python
  result = client.accept_unsorted('jkjsoijg2321kgkdu2', 2310, 4444)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/unsorted-api#unsorted-decline
  - params:
  |  name   | type | default value |
  | :-----: | :--: | :-----------: |
  |   uid   | str  |       -       |
  | user_id | int  |       -       |
  ```python
  result = client.decline_unsorted('jkjsoijg2321kgkdu2', 2310,)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/unsorted-api#unsorted-link
  - params:
  |  name   | type | default value |
  | :-----: | :--: | :-----------: |
  |   uid   | str  |       -       |
  | user_id | int  |       -       |
  |  link   | dict |       -       |
  ```python
  result = client.link_unsorted('jkjsoijg2321kgkdu2', 2310, link={
      "entity_id": 93144801,
      "entity_type": "leads"
  })
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/unsorted-api#unsorted-summary
  - params:
  |        name        |          type          | default value |
  | :----------------: | :--------------------: | :-----------: |
  |        uid         | Union[str, list, None] |     None      |
  | created_at\_\_from |     Optional[str]      |     None      |
  |  created_at\_\_to  |     Optional[str]      |     None      |
  |    pipeline_id     | Union[str, list, None] |     None      |
  ```python
  summary_unsorted = client.get_summary_unsorted()
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads_pipelines#pipelines-list
  ```python
  pipelines = client.get_pipelines()
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads_pipelines#pipelines-add
  - params:
  |      name      |     type      | default value |
  | :------------: | :-----------: | :-----------: |
  |      name      |      str      |       -       |
  |      sort      |      int      |       -       |
  |    is_main     |     bool      |       -       |
  |    statuses    |     list      |       -       |
  | is_unsorted_on |     bool      |     False     |
  |   request_id   | Optional[str] |     None      |
  ```python
  pipeline = {
      "name": "Воронка доп продаж",
      "is_main": False,
      "is_unsorted_on": True,
      "sort": 20,
      "request_id": "123",
      "statuses": [
          {
              "id": 142,
              "name": "Мое название для успешных сделок"
          },
          {
              "name": "Первичный контакт",
              "sort": 10,
              "color": "#fffeb2"
          }
      ]
  }
  result = client.create_pipeline(**pipeline)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads_pipelines#pipelines-add
  - params:
  |      name      | type | default value |
  | :------------: | :--: | :-----------: |
  |  pipeline_id   | int  |       -       |
  |      name      | str  |       -       |
  |      sort      | int  |       -       |
  |    is_main     | bool |       -       |
  | is_unsorted_on | bool |     False     |
  ```python
  pipeline = {
      "pipeline_id": 2310,
      "name": "Новое название для воронки",
      "is_main": False,
      "is_unsorted_on": False,
      "sort": 100
  }
  result = client.edit_pipeline(**pipeline)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads_pipelines#pipeline-delete
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | pipeline_id | int  |       -       |
  ```python
  result = client.delete_pipeline(2310)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads_pipelines#statuses-list
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | pipeline_id | int  |       -       |
  ```python
  pipeline_statuses = client.get_pipeline_statuses(2310)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads_pipelines#status-detail
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | pipeline_id | int  |       -       |
  |  status_id  | int  |       -       |
  ```python
  pipeline_status = client.get_pipeline_status(2310, 123)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads_pipelines#statuses-add
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | pipeline_id | int  |       -       |
  |  statuses   | list |       -       |
  ```python
  statuses = [
      {
          "name": "Новый этап",
          "sort": 100,
          "color": "#fffeb2"
      },
      {
          "name": "Новый этап 2",
          "sort": 200,
          "color": "#fffeb2"
      }
  ]
  result = client.add_statuses_to_pipeline(2310, statuses)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads_pipelines#statuses-add
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | pipeline_id | int  |       -       |
  |  status_id  | int  |       -       |
  |    name     | str  |       -       |
  |    sort     | int  |       -       |
  |    color    | str  |       -       |
  ```python
  result = client.edit_pipeline_status(2310, 123, 'Новый Этап', sort=500, color="#fffeb2")
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/leads_pipelines#status-delete
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | pipeline_id | int  |       -       |
  |  status_id  | int  |       -       |
  ```python
  result = client.delete_status_from_pipeline(2310, 123)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/contacts-api#contacts-list
  - params:
  |    name     |      type      | default value |
  | :---------: | :------------: | :-----------: |
  |    limit    |      int       |      250      |
  |    page     |      int       |       1       |
  | with_params | Optional[list] |     None      |
  |   filters   | Optional[dict] |     None      |
  |    order    | Optional[dict] |     None      |
  ```python
  contacts = client.get_contacts(limit=10, page=3, filters={'updated_at__from': '<timestamp>', 'updated_at__to': '<timestamp>'})

  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/contacts-api#contact-detail
  - params:
  |    name    | type | default value |
  | :--------: | :--: | :-----------: |
  | contact_id | int  |       -       |
  ```python
  contact = client.get_contact(123989)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/contacts-api#contacts-add
  - params:
  |   name   | type | default value |
  | :------: | :--: | :-----------: |
  | contacts | list |       -       |
  ```python
  conctacts = [
      {
          "first_name": "Петр",
          "last_name": "Смирнов",
          "custom_fields_values": [
              {
                  "field_id": 271316,
                  "values": [
                      {
                          "value": "Директор"
                      }
                  ]
              }
          ]
      },
      {
          "name": "Владимир Смирнов",
          "created_by": 47272
      }
  ]
  result = client.create_contacts(contacts)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/contacts-api#contacts-edit
  - params:
  |   name   | type | default value |
  | :------: | :--: | :-----------: |
  | contacts | list |       -       |
  ```python
  conctacts = [
      {
          "id": 3,
          "first_name": "Иван",
          "last_name": "Иванов",
          "custom_fields_values": [
              {
                  "field_id": 66192,
                  "field_name": "Телефон",
                  "values": [
                      {
                          "value": "79999999999",
                          "enum_code": "WORK"
                      }
                  ]
              }
         ]
      }
  ]
  result = client.update_contacts(contacts)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/companies-api#companies-list
  - params:
  |    name     |      type      | default value |
  | :---------: | :------------: | :-----------: |
  |    limit    |      int       |      250      |
  |    page     |      int       |       1       |
  | with_params | Optional[list] |     None      |
  |   filters   | Optional[dict] |     None      |
  |    order    | Optional[dict] |     None      |
  ```python
  companies = client.get_companies(limit=10, page=3, filters={'updated_at__from': '<timestamp>', 'updated_at__to': '<timestamp>'})

  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/companies-api#company-detail
  - params:
  |    name    | type | default value |
  | :--------: | :--: | :-----------: |
  | company_id | int  |       -       |
  ```python
  company = client.get_company(9988)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/companies-api#companies-add
  - params:
  |   name    | type | default value |
  | :-------: | :--: | :-----------: |
  | companies | list |       -       |
  ```python
  companies = [
      {
          "name": "АО Рога и Копыта",
          "custom_fields_values": [
              {
                  "field_code": "PHONE",
                  "values": [
                      {
                          "value": "+7912322222",
                          "enum_code": "WORK"
                      }
                  ]
              }
          ]
      }
  ]
  result = client.create_companies(companies)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/companies-api#companies-edit
  - params:
  |   name    | type | default value |
  | :-------: | :--: | :-----------: |
  | companies | list |       -       |
  ```python
  companies = [
      {
          "id": 11090825,
          "name": "Новое название компании",
          "custom_fields_values": [
              {
                  "field_code": "EMAIL",
                  "values": [
                      {
                          "value": "test@example.com",
                          "enum_code": "WORK"
                      }
                  ]
              }
         ]
      }
  ]
  result = client.update_companies(companies)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/catalogs-api#lists-list
  - params:
  | name  | type | default value |
  | :---: | :--: | :-----------: |
  | page  | int  |       1       |
  | limit | int  |      250      |
  ```python
  catalogs = client.get_catalogs(page=1, limit=5)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/catalogs-api#list-detail
  - params:
  |    name    | type | default value |
  | :--------: | :--: | :-----------: |
  | catalog_id | int  |       1       |
  ```python
  catalog = client.get_catalog(12319)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/catalogs-api#lists-add
  - params:
  |   name   | type | default value |
  | :------: | :--: | :-----------: |
  | catalogs | list |       -       |
  ```python
  catalogs = [
      {
          "name": "Тестовый список",
          "can_add_elements": True,
          "can_link_multiple": False,
          "request_id": "123"
      }
  ]}
  ]
  result = client.create_catalogs(catalogs)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/catalogs-api#lists-edit
  - params:
  |   name   | type | default value |
  | :------: | :--: | :-----------: |
  | catalogs | list |       -       |
  ```python
  catalogs = [
      {
          "id": 5787,
          "name": "Новое имя списка",
          "can_add_elements": True,
          "can_link_multiple": False
      }
  ]
  result = client.update_catalogs(catalogs)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/catalogs-api#list-elements-list
  - params:
  |    name     |      type      | default value |
  | :---------: | :------------: | :-----------: |
  | catalogs_id |      int       |       -       |
  |    page     |      int       |       1       |
  |    limit    |      int       |      250      |
  |   filters   | Optional[dict] |     None      |
  ```python
  elements = client.get_catalog_elements(5787, page=3, limit=8)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/catalogs-api#list-elements-detail
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | catalogs_id | int  |       -       |
  | element_id  | int  |       -       |
  ```python
  element = client.get_catalog_element(5787, 2301)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/catalogs-api#list-elements-add
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | catalogs_id | int  |       -       |
  |  elements   | list |       -       |
  ```python
  elements = [
      {
          "name": "Новый элемент списка",
          "custom_fields_values": [
              {
                  "field_id": 14263,
                  "values": [
                      {
                          "value": 1000
                      }
                  ]
              }
          ]
      }
  ]
  result = client.add_elements_to_catalog(5787, elements)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/catalogs-api#list-elements-edit
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | catalogs_id | int  |       -       |
  |  elements   | list |       -       |
  ```python
  elements = [
      {
          "id": 986757,
          "name": "Новое имя элемента"
      },
      {
          "id": 986753,
          "name": "Новое имя элемента 2"
      }
  ]
  result = client.update_elements_in_catalog(5787, elements)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/users-api#users-list
  - params:
  |    name    | type | default value |
  | :--------: | :--: | :-----------: |
  |    page    | int  |       1       |
  |   limit    | list |      250      |
  | with_role  | bool |     False     |
  | with_group | bool |     False     |
  ```python
  users = client.get_users(page=1, limit=250)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/users-api#user-detail
  - params:
  |    name    | type | default value |
  | :--------: | :--: | :-----------: |
  |  user_id   | int  |       1       |
  | with_role  | bool |     False     |
  | with_group | bool |     False     |
  ```python
  user = client.get_user(2222, with_role=True, with_group=True)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/webhooks-api#webhooks-list
  - params:
  |    name    |     type      | default value |
  | :--------: | :-----------: | :-----------: |
  | distansion | Optional[str] |     None      |
  ```python
  webhooks = client.get_webhooks()
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/webhooks-api#webhook-subscribe
  - params:
  |    name    | type | default value |
  | :--------: | :--: | :-----------: |
  | distansion | str  |       -       |
  |  settings  | list |       -       |
  ```python
  result = client.subscribe_webhook(destination="https://example.test", settings=["add_lead"])
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/widgets-api#widgets-list
  - params:
  | name  | type | default value |
  | :---: | :--: | :-----------: |
  | page  | int  |       1       |
  | limit | int  |      250      |
  ```python
  widgets = client.get_widgets(page=3, limit=22)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/widgets-api#widget-detail
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | widget_code | str  |       -       |
  ```python
  widget = client.get_widget('<widget_code>')
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/widgets-api#widget-install
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | widget_code | str  |       -       |
  | \*\*kwargs  | str  |       -       |
  ```python
  example ={
      "login": "example",
      "password": "eXaMp1E",
      "phones": {
          504141: "1039"
      },
      "script_path": "https://example.com/"
  }
  result = client.install_widget('<widget_code>', **example)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/widgets-api#widget-uninstall
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | widget_code | str  |       -       |
  ```python
  result = client.uninstall_widget('<widget_code>')
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/tasks-api#tasks-list
  - params:
  |  name   |      type      | default value |
  | :-----: | :------------: | :-----------: |
  |  page   |      int       |       1       |
  |  limit  |      int       |      250      |
  | filters | Optional[dict] |     None      |
  |  order  | Optional[dict] |     None      |
  ```python
  tasks = client.get_tasks(page=1, limit=10, filters={'updated_at__from': '<timestamp>', 'updated_at__to': '<timestamp>'})

  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/tasks-api#task-detail
  - params:
  |  name   | type | default value |
  | :-----: | :--: | :-----------: |
  | task_id | int  |       -       |
  ```python
  task = client.get_task(1288)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/tasks-api#tasks-add
  - params:
  | name  | type | default value |
  | :---: | :--: | :-----------: |
  | tasks | list |       -       |
  ```python
  tasks = [
      {
          "task_type_id": 1,
          "text": "Встретиться с клиентом Иван Иванов",
          "complete_till": 1588885140,
          "entity_id": 9785993,
          "entity_type": "leads",
          "request_id": "example"
      }
  ]
  result = client.add_tasks(tasks=tasks)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/tasks-api#tasks-edit
  - params:
  | name  | type | default value |
  | :---: | :--: | :-----------: |
  | tasks | list |       -       |
  ```python
  tasks = [
      {
          "id": 4745251,
          "task_type_id": 2,
          "text": "Новое название для задачи",
          "complete_till": 1588885140
      },
      {
          "id": 4747929,
          "task_type_id": 1,
          "text": "Новое название для задачи 2",
          "complete_till": 1588885140
      }
  ]
  result = client.update_tasks(tasks=tasks)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/tasks-api#tasks-complete
  - params:
  |     name     | type | default value |
  | :----------: | :--: | :-----------: |
  |   task_id    | int  |       -       |
  | is_completed | bool |       -       |
  |    result    | str  |       -       |
  ```python
  result = client.execution_task(1288, is_completed=True, result="Удалось связаться с клиентом")
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/tags-api#tags-list
  - params:
  |    name     |      type      | default value |
  | :---------: | :------------: | :-----------: |
  | entity_type |      str       |       -       |
  |    page     |      int       |       1       |
  |    limit    |      int       |      250      |
  |   filters   | Optional[dict] |     None      |
  ```python
  tags = client.get_tags_by_entity_type('leads', page=1, limit=10)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/tags-api#tags-add
  - params:
  |    name     | type | default value |
  | :---------: | :--: | :-----------: |
  | entity_type | str  |       -       |
  |    tags     | list |       -       |
  ```python
  tags = [
      {
          "name": "Tag 1"
      },
      {
          "name": "Tag 2",
          "request_id": "my_request_id"
      },
      {
          "name": "Tag 3"
      }
  ]
  tags = client.add_tags_for_entity_type('leads', tags=tags)
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/custom-fields#common-info
  ```python
  contacts_cf = client.get_contacts_custom_fields()
  leads_cf = client.get_leads_custom_fields()
  companies_cf = client.get_companies_custom_fields()
  customers_cf = client.get_customers_custom_fields()
  customer_segments_cf = client.get_customer_segments_custom_fields()
  customer_segments_cf = client.get_customer_segments_custom_fields()
  get_catalog_custom_fields = client.get_customer_segments_custom_fields('<catalog_id>')
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/custom-fields#custom-field-detail
  ```python
  contacts_cf = client.get_contacts_custom_field('<id>')
  leads_cf = client.get_leads_custom_field('<id>')
  companies_cf = client.get_companies_custom_field('<id>')
  customers_cf = client.get_customers_custom_field('<id>')
  customer_segments_cf = client.get_customer_segments_custom_field('<id>')
  get_catalog_custom_fields = client.get_catalog_custom_field('<catalog_id>', '<id>')
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/custom-fields#custom-fields-add
  ```python
  contacts_cf = client.create_contacts_custom_field(['<cf>'])
  leads_cf = client.create_leads_custom_field(['<cf>'])
  companies_cf = client.create_companies_custom_field(['<cf>'])
  customers_cf = client.create_customers_custom_field(['<cf>'])
  customer_segments_cf = client.create_customer_segments_custom_field(['<cf>'])
  get_catalog_custom_fields = client.create_catalog_custom_field('<catalog_id>', ['<cf>'])
  ```

  - doc - https://www.amocrm.ru/developers/content/crm_platform/custom-fields#custom-fields-edit
  ```python
  contacts_cf = client.update_contacts_custom_field(['<cf>'])
  leads_cf = client.update_leads_custom_field(['<cf>'])
  companies_cf = client.update_companies_custom_field(['<cf>'])
  customers_cf = client.update_customers_custom_field(['<cf>'])
  customer_segments_cf = client.update_customer_segments_custom_field(['<cf>'])
  get_catalog_custom_fields = client.update_catalog_custom_field('<catalog_id>', ['<cf>'])
  ```

  - 0.0.12 - add entity notes methods, rename updatecustomers_segments_custom_fields -> update_customers_segments_custom_fields


pkgId: 1061bdb64f895e116af7d3ef9327a97fabfb02ecf83796dc35305e05df0b24aa
name: python-amoni
arch: src
version: 0.0.13
epoch: 0
release: 1
summary: A tool to manage local development of Anvil applications
url: https://pypi.org/project/amoni/
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amoni-0.0.13-1.src.rpm
checksum_type: sha256
description:
  A command line utility for local development of [Anvil](https://anvil.works) apps.

  Amoni gives you:

  * A simple command to start a new project and create all the necessary files and folders:

      ```amoni init```

  * Pre-configured docker containers for the anvil app server and postgresql database
  server to run your app
  * Simple commands to start and stop those servers:

      ```
      amoni start

      amoni stop
      ```

  * Your app available in your browser at port 3030 on your local machine
  * Your database server available on port 5432 on your local machine

  * A pre-configured docker container and a simple command to run your test suite:

      ```amoni test```

  * Commands to fetch anvil apps and add them to your project as the main app or as
  dependencies:

      ```
      amoni install app

      amoni install dependency
      ```

  * [Stub files](https://mypy.readthedocs.io/en/stable/stubs.html) that allow your
  autocompleter to see what tables are included in your app


  [Read the Documentation](https://amoni.readthedocs.io/en/latest/)

  [Ask a Question](https://github.com/anvilistas/amoni/discussions)

  [Chat with the team](https://matrix.to/#/#anvilistas_community:gitter.im?via=gitter.im&via=matrix.org)


pkgId: 25c3f199a847fa89c02e4ed1db1afc42408cec1427337ce32d89464ad36b2c7c
name: python-amortization
arch: src
version: 2.4.0
epoch: 0
release: 1
summary: Python library for calculating amortizations and generating amortization schedules
url: https://github.com/roniemartinez/amortization
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amortization-2.4.0-1.src.rpm
checksum_type: sha256
description:
  1           4,840.08    1,250.00     3,590.08  146,409.92
  2           4,840.08    1,220.08     3,620.00  142,789.92
  3           4,840.08    1,189.92     3,650.16  139,139.76
  4           4,840.08    1,159.50     3,680.58  135,459.18
  5           4,840.08    1,128.83     3,711.25  131,747.93
  6           4,840.08    1,097.90     3,742.18  128,005.75
  7           4,840.08    1,066.71     3,773.37  124,232.38
  8           4,840.08    1,035.27     3,804.81  120,427.57
  9           4,840.08    1,003.56     3,836.52  116,591.05
  10          4,840.08      971.59     3,868.49  112,722.56
  11          4,840.08      939.35     3,900.73  108,821.83
  12          4,840.08      906.85     3,933.23  104,888.60
  13          4,840.08      874.07     3,966.01  100,922.59
  14          4,840.08      841.02     3,999.06   96,923.53
  15          4,840.08      807.70     4,032.38   92,891.15
  16          4,840.08      774.09     4,065.99   88,825.16
  17          4,840.08      740.21     4,099.87   84,725.29
  18          4,840.08      706.04     4,134.04   80,591.25
  19          4,840.08      671.59     4,168.49   76,422.76
  20          4,840.08      636.86     4,203.22   72,219.54
  21          4,840.08      601.83     4,238.25   67,981.29
  22          4,840.08      566.51     4,273.57   63,707.72
  23          4,840.08      530.90     4,309.18   59,398.54
  24          4,840.08      494.99     4,345.09   55,053.45
  25          4,840.08      458.78     4,381.30   50,672.15
  26          4,840.08      422.27     4,417.81   46,254.34
  27          4,840.08      385.45     4,454.63   41,799.71
  28          4,840.08      348.33     4,491.75   37,307.96
  29          4,840.08      310.90     4,529.18   32,778.78
  30          4,840.08      273.16     4,566.92   28,211.86
  31          4,840.08      235.10     4,604.98   23,606.88
  32          4,840.08      196.72     4,643.36   18,963.52
  33          4,840.08      158.03     4,682.05   14,281.47
  34          4,840.08      119.01     4,721.07    9,560.40
  35          4,840.08       79.67     4,760.41    4,799.99
  36          4,839.99       40.00     4,799.99        0.00
  Totals    174,242.79   24,242.79   150,000.00
  ```

  [tabulate](https://bitbucket.org/astanin/python-tabulate)

  [Ronie Martinez](mailto:ronmarti18@gmail.com)

  - [Amortization Calculation Formula](https://www.vertex42.com/ExcelArticles/amortization-calculation.html)
  - [Amortization Period Formula](https://math.stackexchange.com/a/3185904)


pkgId: e6b984040164620ceff1677d4fe077857c09780d298213c67fdf085b6e72431a
name: python-amounts
arch: src
version: 4.2
epoch: 0
release: 1
summary: Generate a wordlist to fuzz amounts or any other numerical values.
url: https://github.com/ivan-sincek/amounts
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amounts-4.2-1.src.rpm
checksum_type: sha256
description:
  Generate a wordlist to fuzz amounts or any other numerical values. Based on [Common Security Issues in Financially-Oriented Web Applications](https://soroush.me/downloadable/common-security-issues-in-financially-orientated-web-applications.pdf).

  Bypass minimum and maximum restrictions, cause an unintended behavior and errors, etc.

  Works with integer and float numerical values.

  Tests:

  * Grouping and separating digits using separators such as space, comma, and dot.
  * Adding leading zeros and trailing decimal zeros using separators such as space and comma.
  * Prepending and appending negative and positive scope.
  * Prepending fiat currency symbols such as `$`, `£`, and `€` with and without negative and positive scope.
  * Adding brackets such as `()`, `[]`, and `{}` and extending the inner elements.
  * Testing overflows, underflows, and infinite values.
  * Testing binary and hexadecimal representations, exponential notations, and byte and Unicode escape sequences.
  * Testing boolean, empty, integer minimum, integer maximum, and other special values.
  * Testing lengths.

  Pre-generated wordlists can be found in [/src/wordlists/](https://github.com/ivan-sincek/amounts/tree/main/src/wordlists) and also a part of [/danielmiessler/SecLists/tree/master/Fuzzing/Amounts](https://github.com/danielmiessler/SecLists/tree/master/Fuzzing/Amounts).

  Complimentary wordlists:

  * [/danielmiessler/SecLists/blob/master/Fuzzing/JSON.Fuzzing.txt](https://github.com/danielmiessler/SecLists/blob/master/Fuzzing/JSON.Fuzzing.txt)

  Tested on Kali Linux v2024.2 (64-bit).

  Made for educational purposes. I hope it will help!



  * [How to Install](#how-to-install)
  	* [Standard Install](#standard-install)
  	* [Build and Install From the Source](#build-and-install-from-the-source)
  * [Generate Amounts](#generate-amounts)
  * [Usage](#usage)





  ```fundamental
  pip3 install --upgrade amounts
  ```



  ```fundamental
  git clone https://github.com/ivan-sincek/amounts && cd amounts

  python3 -m pip install --upgrade build

  python3 -m build

  python3 -m pip install dist/amounts-4.2-py3-none-any.whl
  ```



  ```fundamental
  amounts -min 1 -max 10000 -mid 2200 -o amounts.txt
  ```

  Generate wordlist:

  ```fundamental
  2 200
  2,200
  2.200
  002200
  2200,00
  2200.00
  -2200
  2200-
  +2200
  2200+
  2200
  $-2200
  -$2200
  $+2200
  +$2200
  $2200
  €-2200
  -€2200
  €+2200
  +€2200
  €2200
  £-2200
  -£2200
  £+2200
  +£2200
  £2200
  ()
  (,,)
  (2200)
  ("2200")
  (2200,2199)
  ("2200","2199")
  []
  [,,]
  [2200]
  ["2200"]
  [2200,2199]
  ["2200","2199"]
  {}
  {,,}
  {2200}
  {"2200"}
  {2200,2199}
  {"2200","2199"}
  0
  10001
  -NaN
  -Infinity
  -inf
  NaN
  Infinity
  inf
  0b100010011000
  0x898
  \x32\x32\x30\x30
  \u0032\u0032\u0030\u0030
  2200e0
  2200e-50
  0.00000000000000000000000000000000000000000000002200
  1e-1
  10000e1
  &h00
  &hff
  2,,2,,0,,0
  %20%092200
  2200%20%00%00
  true
  false
  -1
  +1
  -0
  +0
  0e-1
  0e1
  null
  None
  nil
  An Array
  -2147483648
  2147483647
  -2147483649
  2147483648
  4294967295
  4294967296
  99999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999
  9999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999
  999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999
  -9999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999
  -999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999
  -99999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999
  1
  ```



  ```fundamental
  Amounts v4.2 ( github.com/ivan-sincek/amounts )

  Usage:   amounts [-min minimum] [-max maximum] -mid middle -o out         [-q quotes]
  Example: amounts [-min 1      ] [-max 1000   ] -mid 20     -o amounts.txt [-q double]

  DESCRIPTION
      Generate a wordlist to fuzz amounts or any other numerical values
  MINIMUM
      Minimum amount allowed
      -min, --minimum = 1 | etc.
  MAXIMUM
      Maximum amount allowed
      -max, --maximum = 1000 | etc.
  MIDDLE
      Preferably, a multi-digit amount greater than the minimum, lesser than the maximum, and not equal to zero
      -mid, --middle = 20 | etc.
  QUOTES
      Quotes for enclosing the amounts
      Use comma-separated values
      Default: none
      -q, --quotes = none | single | double | backtick | all
  IGNORE
      Ignore hardcoded values
      -i, --ignore
  OUT
      Output file
      -o, --out = amounts.txt | etc.
  ```


pkgId: 6584b2f1a231dc5d3f138440f9645c4f862d348b1c8d4930e17acc9e59534fe5
name: python-amp-renderer
arch: src
version: 2.0.1
epoch: 0
release: 1
summary: Unofficial Python port of server-side rendering from AMP Optimizer
url: https://github.com/chasefinch/amp-renderer
rpm_license: Apache Software License
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amp-renderer-2.0.1-1.src.rpm
checksum_type: sha256
description:
  ![Python 3.6+](https://img.shields.io/badge/python-3.6%2B-blue) [![Build Status](https://travis-ci.com/chasefinch/amp-renderer.svg?branch=main)](https://travis-ci.com/chasefinch/amp-renderer) ![Coverage](https://img.shields.io/badge/coverage-90%25-brightgreen)

  Unofficial Python port of [server-side rendering](https://amp.dev/documentation/guides-and-tutorials/optimize-and-measure/amp-optimizer-guide/explainer/?format=websites) from [AMP Optimizer](https://github.com/ampproject/amp-toolbox/tree/main/packages/optimizer). Supports Python 3.6 and above.

  AMP Renderer performs the following optimizations:
  1. Inject the specific layout markup into each AMP element
  2. Insert the AMP runtime styles into the document
  3. Remove the AMP boilerplate styles, if possible
  4. Mark the document as “transformed” with the appropriate tags on the `html` element
  5. Insert `img` tags for images with the data-hero attribute

  It also makes these formatting updates:
  1. Remove empty `class` and `style` tags for AMP HTML elements
  2. Convert tag names and attribute names to lowercase
  3. Convert numerical attribute values to strings
  4. Use double quotes ("") for attributes, and escape double quotes inside attribute values
  5. Remove whitespace between html attributes
  6. If desired, removes comments (disabled by default)
  7. If desired, trims whitespace around HTML attribute values (disabled by default, and not always a good idea)

  AMPRenderer can be used on a block of arbitrary HTML, but when used on a full document, it will insert the AMP runtime styles and, if possible, remove the AMP boilerplate styles.

  Boilerplate styles can be removed except in these cases:
  - An AMP element uses an unsupported value for the `layout` attribute
  - `amp-audio` is used
  - There is at least one `amp-experiment` active
  - Transformation fails for one or more elements due to an invalid attribute value for `media`, `sizes`, or `heights`
  - Any render-delaying extension is used. Currently this means:
    - `amp-dynamic-css-classes`
    - `amp-story`

  If boilerplate styles can’t be removed, the attribute `no_boilerplate` will be set to `True` after calling `render`; otherwise it will be `False`. Until `render` runs, the `no_boilerplate` attribute isn’t set at all.



  If using Django, you can use the [Django AMP Renderer middleware](https://github.com/chasefinch/django-amp-renderer).

  Otherwise, install via PyPI:

  	pip install amp-renderer

  Minimal usage:

  	from amp_renderer import AMPRenderer

  	...

  	RUNTIME_VERSION = "012345678" /* Current AMP runtime version number */
  	RUNTIME_STYLES = "..." /* Current contents of https://cdn.ampproject.org/v0.css */

  	renderer = AMPRenderer(
  		runtime_version=RUNTIME_VERSION,
  		runtime_styles=RUNTIME_STYLES)

  	original_html = """
  	    <!doctype html>
  	    <html ⚡>
  	      ...
  	    </html>
  	"""

  	result = renderer.render(original_html)

  	print(result)


  Remove comments and/or trim attributes:

  	renderer.should_strip_comments = True
  	renderer.should_trim_attributes = True
  	result = renderer.render(original_html)

  	print(result)


  The AMPRenderer class inherits from [HTMLParser](https://docs.python.org/3/library/html.parser.html), and can be similarly extended.



  Install requrements:

  	make install

  Sort imports (Requires Python >= 3.8):

  	make format

  Lint (Requires Python >= 3.8):

  	make lint

  Test:

  	make test



  There are still some aspects of the official AMP Optimizer implementation that haven’t been addressed yet. PRs welcome.


  - [x] ~Tested against AMP Optimizer’s ServerSideRendering spec~
  - [ ] Automatic runtime version management


  - [x] ~Support `sizes`, `media`, and `heights` via CSS injection~
  - [x] ~Group CSS injections for `media` attributes by shared media queries to reduce necessary bytes~
  - [ ] Support percent values in `heights`
  - [ ] Warn or fail if CSS injection puts the `amp-custom` element over the byte limit


  - [x] ~Inject `img` tag for `amp-img`s with the `data-hero` attribute~
  - [ ] Enforce 2-image limit on `data-hero`
  - [ ] Autodetect hero images
  - [ ] Support hero image functionality for `amp-iframe`, `amp-video`, and `amp-video-iframe`



  The Python AMP Renderer does not insert `preload` links into the `head` of the DOM object for hero images; This can be done by hand for more control over the critical path.

  <!--

  Since AMPRenderer adds the `amp-runtime` styles to the document, you can also use the [AMP Module Build](https://amp.dev/documentation/guides-and-tutorials/optimize-and-measure/amp-optimizer-guide/explainer/?format=websites#amp-module-build-(coming-soon)) by hand. To take advantage of this, rewrite the import scripts such that imports like this:

  	<script async src="https://cdn.ampproject.org/v0.js"></script>

  ...become 2-part imports based on [Javascript Modules](https://v8.dev/features/modules#browser), like this:

  	<script type="module" async src="https://cdn.ampproject.org/v0.mjs"></script>
  	<script nomodule async src="https://cdn.ampproject.org/v0.js"></script>

  -->


pkgId: 55e29c09680c790d881461c828ab93e2030cabdbadcba639caa29c08e0f1c164
name: python-ampapi
arch: src
version: 1.3.20
epoch: 0
release: 1
summary: An API that allows you to communicate with AMP installations from within Python.
url: https://github.com/p0t4t0sandwich/ampapi-py
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ampapi-1.3.20-1.src.rpm
checksum_type: sha256
description:
  [![License](https://img.shields.io/github/license/p0t4t0sandwich/ampapi-py?color=blue)](https://img.shields.io/github/downloads/p0t4t0sandwich/ampapi-py/LICENSE)
  [![Github](https://img.shields.io/github/stars/p0t4t0sandwich/ampapi-py)](https://github.com/p0t4t0sandwich/ampapi-py)
  [![Github Issues](https://img.shields.io/github/issues/p0t4t0sandwich/ampapi-py?label=Issues)](https://github.com/p0t4t0sandwich/ampapi-py/issues)
  [![Discord](https://img.shields.io/discord/1067482396246683708?color=7289da&logo=discord&logoColor=white)](https://discord.neuralnexus.dev)
  [![wakatime](https://wakatime.com/badge/github/p0t4t0sandwich/ampapi-py.svg)](https://wakatime.com/badge/github/p0t4t0sandwich/ampapi-py)

  [![Github Releases](https://img.shields.io/github/downloads/p0t4t0sandwich/ampapi-py/total?label=Github&logo=github&color=181717)](https://github.com/p0t4t0sandwich/ampapi-py/releases)
  [![PyPI](https://img.shields.io/pypi/v/ampapi?label=PyPI&logo=pypi&color=3775A9)](https://pypi.org/project/ampapi/)
  [![PyPI - Downloads](https://img.shields.io/pypi/dm/ampapi?label=PyPI%20Downloads&logo=pypi&color=3775A9)](https://pypi.org/project/ampapi/)
  [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/ampapi?label=Python&logo=python&color=3775A9)](https://pypi.org/project/ampapi/)
  [![PyPI - Wheel](https://img.shields.io/pypi/wheel/ampapi?label=Wheel&logo=python&color=3775A9)](https://pypi.org/project/ampapi/)

  An API that allows you to communicate with AMP installations from within Python.

  Documentation for available API calls can be found by appending /API to the URL of any existing AMP installation.

  Support:

  - Ping `@thepotatoking3452` in the `#development` channel of the [AMP Discord](https://discord.gg/cubecoders)
  - My own [development Discord](https://discord.neuralnexus.dev/)



  ```bash
  pip install ampapi
  ```

  or

  ```bash
  pip install 'ampapi @ git+https://github.com/p0t4t0sandwich/ampapi-py.git'
  ```

  You also need the following packages installed:

  ```bash
  pip install requests aiohttp json
  ```



  I've redone the return types, most should work, but if you find any that don't, please let me know.





  ```python
  from ampapi.modules.CommonAPI import CommonAPI

  def main():
      
      API = CommonAPI("http://localhost:8080/", "admin", "myfancypassword123")
      API.Login()

      
      API.Core.SendConsoleMessage("say Hello Everyone, this message was sent from the Python API!")

      currentStatus = API.Core.GetStatus()
      CPUUsagePercent = currentStatus.Metrics["CPU Usage"].Percent

      print(f"Current CPU usage is: {CPUUsagePercent}%")

  main()
  ```



  ```python
  import asyncio
  from ampapi.modules.CommonAPI import CommonAPI

  async def main():
      
      API = CommonAPI("http://localhost:8080/", "admin", "myfancypassword123")
      await API.LoginAsync()

      
      await API.Core.SendConsoleMessageAsync("say Hello Everyone, this message was sent from the Python API!")

      currentStatus = await API.Core.GetStatusAsync()
      CPUUsagePercent = currentStatus.Metrics["CPU Usage"].Percent

      print(f"Current CPU usage is: {CPUUsagePercent}%")

  asyncio.run(main())
  ```



  ```python
  from ampapi.modules.ADS import ADS

  API = ADS("http://localhost:8080/", "admin", "myfancypassword123")
  API.Login()


  targets = API.ADSModule.GetInstances()



  target = targets[1]

  hub_instance_id = ""


  instances = target.AvailableInstances
  for instance in instances:
      
      if instance.InstanceName == "Hub":
          hub_instance_id = instance.InstanceID
          break


  Hub = API.InstanceLogin(hub_instance_id, "Minecraft")


  currentStatus = Hub.Core.GetStatus()
  CPUUsagePercent = currentStatus.Metrics["CPU Usage"].Percent


  Hub.Core.SendConsoleMessage(f"say Current CPU usage is {CPUUsagePercent}%")
  ```



  ```python
  from ampapi.modules.CommonAPI import CommonAPI

  try:
      API = CommonAPI("http://localhost:8080/")

      
      loginResult = API.Core.Login("admin", "myfancypassword123", "", False)

      if loginResult.success:
          print("Login successful")
          API.sessionId = loginResult.sessionID
          API.Core.sessionId = loginResult.sessionID

          
          API.Core.SendConsoleMessage("say Hello Everyone, this message was sent from the Python API!")
          currentStatus = API.Core.GetStatus()
          CPUUsagePercent = currentStatus.Metrics["CPU Usage"].Percent
          print(f"Current CPU usage is: {CPUUsagePercent}%")

      else:
          print("Login failed")
          print(loginResult)

  except Exception as err:
      
      raise Exception(err)
  ```


pkgId: 4bbf8c42feb9318d6566e07fc78a95672b93b8f75d937c187b45aadf4b75e5b3
name: python-ampapi
arch: src
version: 2604.4.2
epoch: 0
release: 1
summary: An API that allows you to communicate with AMP installations from within Python.
url: https://github.com/p0t4t0sandwich/ampapi
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ampapi-2604.4.2-1.src.rpm
checksum_type: sha256
description:
  [![License](https://img.shields.io/github/license/p0t4t0sandwich/ampapi?color=blue)](https://img.shields.io/github/downloads/p0t4t0sandwich/ampapi/LICENSE.md)
  [![Github](https://img.shields.io/github/stars/p0t4t0sandwich/ampapi)](https://github.com/p0t4t0sandwich/ampapi)
  [![Github Issues](https://img.shields.io/github/issues/p0t4t0sandwich/ampapi?label=Issues)](https://github.com/p0t4t0sandwich/ampapi/issues)
  [![Discord](https://img.shields.io/discord/1067482396246683708?color=7289da&logo=discord&logoColor=white)](https://discord.neuralnexus.dev)
  [![wakatime](https://wakatime.com/badge/github/p0t4t0sandwich/ampapi.svg)](https://wakatime.com/badge/github/p0t4t0sandwich/ampapi)

  [![Github Releases](https://img.shields.io/github/downloads/p0t4t0sandwich/ampapi/total?label=Github&logo=github&color=181717)](https://github.com/p0t4t0sandwich/ampapi/releases)
  [![PyPI](https://img.shields.io/pypi/v/ampapi?label=PyPI&logo=pypi&color=3775A9)](https://pypi.org/project/ampapi/)
  [![PyPI - Downloads](https://img.shields.io/pypi/dm/ampapi?label=PyPI%20Downloads&logo=pypi&color=3775A9)](https://pypi.org/project/ampapi/)
  [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/ampapi?label=Python&logo=python&color=3775A9)](https://pypi.org/project/ampapi/)
  [![PyPI - Wheel](https://img.shields.io/pypi/wheel/ampapi?label=Wheel&logo=python&color=3775A9)](https://pypi.org/project/ampapi/)

  An API that allows you to communicate with AMP installations from within Python.

  Documentation for available API calls can be found by appending /API to the URL of any existing AMP installation.

  Support:

  - Ping `@thepotatoking3452` in the `#development` channel of the [AMP Discord](https://discord.gg/cubecoders)
  - My own [development Discord](https://discord.neuralnexus.dev/)



  ```bash
  pip install ampapi
  ```

  You also need the following packages installed:

  ```bash
  pip install requests aiohttp json dataclass_wizard
  ```



  **NOTE: THESE ARE CURRENTLY OUTDATED AFTER THE REWRITE**



  ```python
  from ampapi.modules.CommonAPI import CommonAPI

  def main():
      
      API = CommonAPI("http://localhost:8080/", "admin", "myfancypassword123")
      API.Login()

      
      API.Core.SendConsoleMessage("say Hello Everyone, this message was sent from the Python API!")

      currentStatus = API.Core.GetStatus()
      CPUUsagePercent = currentStatus.Metrics["CPU Usage"].Percent

      print(f"Current CPU usage is: {CPUUsagePercent}%")

  main()
  ```



  ```python
  import asyncio
  from ampapi.modules.CommonAPI import CommonAPI

  async def main():
      
      API = CommonAPI("http://localhost:8080/", "admin", "myfancypassword123")
      await API.LoginAsync()

      
      await API.Core.SendConsoleMessageAsync("say Hello Everyone, this message was sent from the Python API!")

      currentStatus = await API.Core.GetStatusAsync()
      CPUUsagePercent = currentStatus.Metrics["CPU Usage"].Percent

      print(f"Current CPU usage is: {CPUUsagePercent}%")

  asyncio.run(main())
  ```



  ```python
  from ampapi.modules.ADS import ADS

  API = ADS("http://localhost:8080/", "admin", "myfancypassword123")
  API.Login()


  targets = API.ADSModule.GetInstances()



  target = targets[1]

  hub_instance_id = ""


  instances = target.AvailableInstances
  for instance in instances:
      
      if instance.InstanceName == "Hub":
          hub_instance_id = instance.InstanceID
          break


  Hub = API.InstanceLogin(hub_instance_id, "Minecraft")


  currentStatus = Hub.Core.GetStatus()
  CPUUsagePercent = currentStatus.Metrics["CPU Usage"].Percent


  Hub.Core.SendConsoleMessage(f"say Current CPU usage is {CPUUsagePercent}%")
  ```



  ```python
  from ampapi.modules.CommonAPI import CommonAPI

  try:
      API = CommonAPI("http://localhost:8080/")

      
      loginResult = API.Core.Login("admin", "myfancypassword123", "", False)

      if loginResult.success:
          print("Login successful")
          API.sessionId = loginResult.sessionID
          API.Core.sessionId = loginResult.sessionID

          
          API.Core.SendConsoleMessage("say Hello Everyone, this message was sent from the Python API!")
          currentStatus = API.Core.GetStatus()
          CPUUsagePercent = currentStatus.Metrics["CPU Usage"].Percent
          print(f"Current CPU usage is: {CPUUsagePercent}%")

      else:
          print("Login failed")
          print(loginResult)

  except Exception as err:
      
      raise Exception(err)
  ```


pkgId: bca1facdbfb4b19a515c13f55e25bc90201265ae247ad818369037496a503439
name: python-ampel-alerts
arch: src
version: 0.10.1
epoch: 0
release: 1
summary: Alert support for the Ampel system
url: https://ampelproject.github.io
rpm_license: BSD-3-Clause
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ampel-alerts-0.10.1-1.src.rpm
checksum_type: sha256
description:
  <img align="left" src="https://user-images.githubusercontent.com/17532220/213289600-aa1757d2-44ba-4de2-b12d-520ddb5d39ff.png" width="150" height="150"/>
  <br>



  <br><br>

  Enables the processing of _alerts_ by AMPEL.

  The central class of this repository, `ampel.alert.AlertConsumer`,
  is capable of loading, filtering and "ingesting" these alerts.

  - The loading part involves instrument specific classes.
  - The optional filtering part allows the selection of events based on pre-defined rules.
  High-throughput systems, such as ZTF or LSST in astronomy, rely on such filters.
  - During _ingestion_, the content of alerts is saved into the AMPEL database, possibly together with other different documents which can be created according to pre-defined directives.

  <p align="center">
    <img src="https://desycloud.desy.de/index.php/s/fiLRCFZtbTkeCtj/preview" width="40%" />
    <img src="https://desycloud.desy.de/index.php/s/EBacs5bbApzpwDr/preview" width="40%" />
  </p>

  <p align="center">
    The <i>AlertConsumer</i> operates on the first three tiers of AMPEL: T0, T1 and T2.
  </p>




  Performed by subclasses of `ampel.abstract.AbsAlertSupplier`.

  Concrete implementation examples: `ampel.ztf.alert.ZiAlertSupplier`

  Actions break-down:

  - Load bytes (tar, network, ...)
  - Deserialize (avro, bson, json, ...)
  - First shape (instrument specific): morph into `AmpelAlert` or `PhotoAlert` Purpose: having a common format that the `AlertConsumer` and alert filters understand. A `PhotoAlert` typically contains two distinct flat sequences, one for photopoints and one for upperlimits. The associated object ID, such as the ZTF name, is converted into nummerical ampel IDs. This is necessary for all alerts (rejected one as well) since "autocomplete" is based on true Ampel IDs.




  Alerts filtering is performed per channel, by subclasses of `ampel.abstract.AbsAlertFilter`.
  An `AlertConsumer` instance can handle multiple filters.
  Alert filters methods provided by user units are called by the class `FilterBlock`,
  that handles associated operations (what happens to rejected alerts ? what about auto-complete, etc...)
  `FilterBlock` instances are themselves embedded in `FilterBlocksHandler`

  Filters can return:
    - `False` or `None` to reject an alert.
    - `True` to accept the alert and create all t1/t2 documents defined in the alert processor directive
    - An `int` number to accept the alert and create only the t1/t2 documents associated with this group id (as defined in the alert processor directive)



  If any channel accepts a given alert, DB updates need to occur.
  v0.7 brought many updates regarding how ingestion happens.
  Class: `ampel.alert.ChainedIngestionHandler`, `ampel.abstract.AbsDocIngester`

  More details later


  Nesting is chaining



  Alerts that pass any T0 filter are further shaped in order to fullfill
  some requirements for DB storage and easy later retrieval.
  Among other things, individual datapoints can be tagged during this step.
  For ZTF, upper limits do not feature a unique ID, so we have to build our own.
  Each datapoint is shaped into a `ampel.content.DataPoint` structure.

  Implementation example: `ampel.ztf.ingest.ZiDataPointShaper`


  Optimize the number of created documents


  Create and upserts documents into the DB


pkgId: 2d63d91fb205bd19fd8d49c1bc3a7fdcec6f9c880f27953c3f3bf390b5cd1957
name: python-ampel-core
arch: src
version: 0.10.1
epoch: 0
release: 1
summary: Alice in Modular Provenance-Enabled Land
url: https://ampelproject.github.io
rpm_license: BSD-3-Clause
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ampel-core-0.10.1-1.src.rpm
checksum_type: sha256
description:
  <img align="left" src="https://user-images.githubusercontent.com/17532220/213287939-c3f2db40-9c43-4d4c-8d55-68531cddcad7.png" width="150" height="150"/>
  <br>


  <br><br>


pkgId: 399e0e3ca54f9230687993c804d81c77d21caa32c95e23b70330f8350825cc77
name: python-ampel-interface
arch: src
version: 0.10.1.post0
epoch: 0
release: 1
summary: Base classes for the Ampel analysis platform
url: https://ampelproject.github.io
rpm_license: BSD-3-Clause
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ampel-interface-0.10.1.post0-1.src.rpm
checksum_type: sha256
description:
  `ampel-interface` provides type-hinted abstract base classes for [Ampel](https://ampelproject.github.io).


pkgId: 891b0ef2951d9890700705d2a1f5c5d7d82a76866b8a38420f73f2c3a6dcd63a
name: python-ampel-lsst
arch: src
version: 0.8.6
epoch: 0
release: 1
summary: Legacy Survey of Space and Time support for the Ampel system
url: https://ampelproject.github.io
rpm_license: BSD-3-Clause
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ampel-lsst-0.8.6-1.src.rpm
checksum_type: sha256
description:
  <img align="left" src="https://desycloud.desy.de/index.php/s/25EwEzgpyFMd2bC/preview" width="150" height="150"/>
  <br>



  <br><br>
  LSST-specific implementations for Ampel such as:

  - An _AlertSupplier_ compatible with plasticc generated alerts
  - Shaper classes for ingestion


pkgId: c7547e207068612b33e07faf06507d1fd79254c059bf103c69e61861fbeca6bc
name: python-ampel-ztf
arch: src
version: 0.10.2
epoch: 0
release: 1
summary: Zwicky Transient Facility support for the Ampel system
url: https://ampelproject.github.io
rpm_license: BSD-3-Clause
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ampel-ztf-0.10.2-1.src.rpm
checksum_type: sha256
description:
  <img align="left" src="https://desycloud.desy.de/index.php/s/6gJs9bYBG3tWFDz/preview" width="150" height="150"/>
  <br>



  <br><br>
  ZTF-specific implementations for Ampel such as:

  - An _AlertSupplier_ compatible with IPAC generated alerts
  - Shaper classes for ingestion
  - Encoding utilities for ZTF names (AMPEL requires integer ids)
  - Classes for archiving alerts


pkgId: e3581eaa018338570c6380adc4af3a37cf5db5e4061ed15562ee11ec2f0021a2
name: python-ampform
arch: src
version: 0.15.4
epoch: 0
release: 1
summary: Automatically generate symbolic amplitude models for Partial Wave Analysis
url: https://pypi.org/project/ampform/
rpm_license: GPLv3 or later
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-ampform-0.15.4-1.src.rpm
checksum_type: sha256
description:
  [![10.5281/zenodo.5526648](https://zenodo.org/badge/doi/10.5281/zenodo.5526648.svg)](https://doi.org/10.5281/zenodo.5526648)
  [![GPLv3+ license](https://img.shields.io/badge/License-GPLv3+-blue.svg)](https://www.gnu.org/licenses/gpl-3.0-standalone.html)

  [![PyPI package](https://badge.fury.io/py/ampform.svg)](https://pypi.org/project/ampform)
  [![Conda package](https://anaconda.org/conda-forge/ampform/badges/version.svg)](https://anaconda.org/conda-forge/ampform)
  [![Supported Python versions](https://img.shields.io/pypi/pyversions/ampform)](https://pypi.org/project/ampform)

  [![Binder](https://static.mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/ComPWA/ampform/stable?filepath=docs/usage)
  [![Google Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/ComPWA/ampform/blob/stable)
  [![Open in Visual Studio Code](https://img.shields.io/badge/vscode-open-blue?logo=visualstudiocode)](https://open.vscode.dev/ComPWA/ampform)
  [![GitPod](https://img.shields.io/badge/gitpod-open-blue?logo=gitpod)](https://gitpod.io/#https://github.com/ComPWA/ampform)

  [![Documentation build status](https://readthedocs.org/projects/ampform/badge/?version=latest)](https://ampform.readthedocs.io)
  [![pre-commit.ci status](https://results.pre-commit.ci/badge/github/ComPWA/ampform/main.svg)](https://results.pre-commit.ci/latest/github/ComPWA/ampform/main)
  [![pytest](https://github.com/ComPWA/ampform/workflows/pytest/badge.svg)](https://github.com/ComPWA/ampform/actions?query=branch%3Amain+workflow%3Apytest)
  [![Checked with mypy](http://www.mypy-lang.org/static/mypy_badge.svg)](https://mypy.readthedocs.io)
  [![Test coverage](https://codecov.io/gh/ComPWA/ampform/branch/main/graph/badge.svg)](https://codecov.io/gh/ComPWA/ampform)
  [![Codacy Badge](https://api.codacy.com/project/badge/Grade/70fc5fb0f3954a9d82d142efeff4df31)](https://www.codacy.com/gh/ComPWA/ampform)
  [![Spelling checked](https://img.shields.io/badge/cspell-checked-brightgreen.svg)](https://github.com/streetsidesoftware/cspell/tree/master/packages/cspell)
  [![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier)
  [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)

  AmpForm is a Python library of spin formalisms and dynamics with which you can
  automatically formulate symbolic amplitude models for Partial Wave Analysis. The
  resulting amplitude models are formulated with
  [SymPy](https://www.sympy.org/en/index.html) (a Computer Algebra System). This not only
  makes it easy to inspect and visualize the resulting amplitude models, but also means
  the amplitude models can be used as templates for faster computational back-ends (see
  [TensorWaves](https://github.com/ComPWA/tensorwaves))!

  Visit [ampform.rtfd.io](https://ampform.readthedocs.io) for several usage examples. For
  an overview of **upcoming releases and planned functionality**, see
  [here](https://github.com/ComPWA/ampform/milestones?direction=asc&sort=title&state=open).



  - **Automatic amplitude model building**<br /> Convert state transition graphs from
    [QRules](https://github.com/ComPWA/qrules) to an amplitude model that is
    _mathematically expressed_ with [SymPy](https://docs.sympy.org) and can be _converted
    to any backend_ (see [TensorWaves](https://tensorwaves.rtfd.io)).
  - **Spin formalisms**
    - [Helicity formalism](https://ampform.readthedocs.io/en/stable/usage/helicity/formalism.html)
    - Canonical formalism
    - [Spin alignment](https://ampform.readthedocs.io/en/stable/usage/helicity/spin-alignment.html)
      for generic, multi-body decays that feature different decay topologies
  - **Dynamics**
    - [Relativistic Breit-Wigner](https://ampform.readthedocs.io/en/stable/api/ampform.dynamics.html#ampform.dynamics.relativistic_breit_wigner_with_ff),
      optionally with form factors and/or
      [energy-dependent width](https://ampform.readthedocs.io/en/stable/api/ampform.dynamics.html#ampform.dynamics.EnergyDependentWidth)
    - [Symbolic _K_-matrix](https://ampform.readthedocs.io/en/stable/usage/dynamics/k-matrix.html#non-relativistic-k-matrix)
      for an arbitrary number of poles and channels
    - [Symbolic _P_-vector](https://ampform.readthedocs.io/en/stable/usage/dynamics/k-matrix.html#p-vector)
      for an arbitrary number of poles and channels



  See [`CONTRIBUTING.md`](./CONTRIBUTING.md)


pkgId: b6c2b643f735dce4493cf7232460cfb87b527fc042d63f38866f281204684e06
name: python-amphi
arch: src
version: 1.0.15
epoch: 0
release: 1
summary: MoviePy OOP wrapper
url: https://github.com/rmaniego/amphi
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amphi-1.0.15-1.src.rpm
checksum_type: sha256
description:
  MoviePy OOP wrapper


   - ImageMagick binary file
   - Matplotlib
   - OpenCV


  ```python
  from amphi import Amphi

  movie = Amphi()

  movie.new_audio("music", "<path/to/audio/file>")
  movie.new_video("video1", "<path/to/audio/file>")
  movie.new_video("video2", "<path/to/audio/file>")
  movie.new_video("video3", "<path/to/audio/file>", stabilize=True)
  movie.new_text("title", "My Video", font="Arial", fontsize=100, duration=4)



  print("Processing media resources...")
  movie.video("video1").subclip(0, 5).keep("video1a")
  movie.video("video2").subclip(0, 2).keep("video2a")
  movie.video("video3").subclip(2).keep("video3a")

  movie.video("video1a").composite("title").keep("intro")
  movie.concatenate_by_video_id(["intro", "video2a", "video3a"])
  movie.set_audio("music")
  movie.render()

  if movie.save("my-movie.mp4", fps=30, bitrate="16000k"):
      print("The video has been successfully saved.")

  ```


pkgId: 399a099ce9a7212945c989894d233edbb049394878eccc365c2b3b90d0b2157f
name: python-amphipathic
arch: src
version: 1.0.11
epoch: 0
release: 1
url: https://github.com/ecolell/amphipathic
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amphipathic-1.0.11-1.src.rpm
checksum_type: sha256
summary:
  This is a library to evaluate an aminoacid sequence and determine an amphipathic index for each alpha helix or beta sheet.

description:
  [![License](https://img.shields.io/pypi/l/amphipathic.svg)](https://raw.githubusercontent.com/ecolell/amphipathic/master/LICENSE) [![Downloads](https://img.shields.io/pypi/dm/amphipathic.svg)](https://pypi.python.org/pypi/amphipathic/) [![Build Status](https://travis-ci.org/ecolell/amphipathic.svg?branch=master)](https://travis-ci.org/ecolell/amphipathic) [![Coverage Status](https://coveralls.io/repos/ecolell/amphipathic/badge.png)](https://coveralls.io/r/ecolell/amphipathic) [![PyPI version](https://badge.fury.io/py/amphipathic.svg)](http://badge.fury.io/py/amphipathic)
  This library can analyze an aminoacid sequence and gives a list of secondary structures with the respective hydrophobicity mean[1] and amphipathic index[1].
  When it is useful to calculate this measurements on a secondary structure?
  By looking into this measurements for an alpha helix, you can test some hiphotesis related with:
  1. the context of a **globular soluble protein**:
      - **hydrofobic core**, it will be no amphipathic and hydrophobic
      - **interface between core and the superficial region**, it will be amphiphatic
      - **superficial region**, it will be no amphipathic and hydrophilic
  2. the interactions of a **trans-membrane protein**:
      - **on lipids interaction**, it will be not amphipathic and hidrophobic
      - **on multiple trans-membrane helix interacion** (homomeric or heteromeric), it will be amphipathic building like an *ionic channel*.


pkgId: 485e321fd7ef991f8e5dd1e580a122a775f078449bfbef4e784f9d948122f2dc
name: python-amplabs
arch: src
version: 0.2.1
epoch: 0
release: 1
summary: One of the AmpLabs product to create high end plots for your data
url: https://pypi.org/project/amplabs/
rpm_license: None
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amplabs-0.2.1-1.src.rpm
checksum_type: sha256
description:
  AmpLabs is a open source platform which provides easy way of data visualisation.




  Built on top of Plotly.js, Dash, Pandas and Flask, AmpLabs ties modern UI elements like dropdowns and graphs directly to analytical Python code.


  Method provided -

  | Method | Description | Parameter | Return value |
  | ------ | ----------- | --------- | ------------ |
  | open_dashboard | method to open dashboard on local server | None | None |




  - Website to upload and plot data on cloud [www.app.amplabs.ai]
  - Desktop Application to visual data locally


pkgId: b7df472b2fefb9b77d338b417ee77a00d5f9188b5800aa35cde97f6c12ddd049
name: python-amplify-aws-utils
arch: src
version: 0.5.2
epoch: 0
release: 1
summary: Utility functions for working with AWS resources
url: https://github.com/amplify-education/amplify_aws_utils/
rpm_license: MIT
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amplify-aws-utils-0.5.2-1.src.rpm
checksum_type: sha256
description:
  [![Codacy Badge](https://api.codacy.com/project/badge/Grade/9f6400386de74fe0b86acd6a081f3302)](https://www.codacy.com/app/amplify-education/amplify_aws_utils?utm_source=github.com&utm_medium=referral&utm_content=amplify-education/amplify_aws_utils&utm_campaign=Badge_Grade)
  [![Codacy Badge](https://api.codacy.com/project/badge/Coverage/9f6400386de74fe0b86acd6a081f3302)](https://www.codacy.com/app/amplify-education/amplify_aws_utils?utm_source=github.com&utm_medium=referral&utm_content=amplify-education/amplify_aws_utils&utm_campaign=Badge_Coverage)
  [![Build Status](https://travis-ci.org/amplify-education/amplify_aws_utils.svg?branch=master)](https://travis-ci.org/amplify-education/amplify_aws_utils)
  [![PyPI](https://img.shields.io/pypi/v/amplify-aws-utils.svg)](https://pypi.org/project/amplify-aws-utils/)
  [![Python Versions](https://img.shields.io/pypi/pyversions/amplify-aws-utils.svg)](https://pypi.python.org/pypi/amplify-aws-utils)
  [![Downloads](https://img.shields.io/pypi/dm/amplify_aws_utils.svg)](https://pypistats.org/api/packages/amplify-aws-utils/recent)



  Utility functions for working with AWS resources though Boto3 with less hiccups.



  Amplify builds innovative and compelling digital educational products that empower teachers and students across the
  country. We have a long history as the leading innovator in K-12 education - and have been described as the best tech
  company in education and the best education company in tech. While others try to shrink the learning experience into the
  technology, we use technology to expand what is possible in real classrooms with real students and teachers.





  amplify_aws_utils requires the following to be installed:

  ```text
  python >= 3.8
  ```



  This package can be installed using `pip`

  `pip install amplify_aws_utils`



  For development, `tox>=2.9.1` is recommended.

  Python package can be built as follows:

  `python setup.py sdist`

  This creates a package in `dist` directory.



  `amplify_aws_utils` uses `tox`. You will need to install tox with `pip install tox`.
  Running `tox` will automatically execute linters as well as the unit tests. You can also run them individually with
  the -e argument.

  For example, `tox -e lint,py38-unit` will run the linters, and then the unit tests in python 3.8

  To see all the available options, run `tox -l`.



  Deployment is done with Travis.

  Package is built as described above, and is uploaded to PyPI repo using `devpi-client`



  Functions provided by this package can be imported after package has been installed.

  Example:

  `from amplify_aws_utils.resource_helper import throttled_call`


pkgId: f2f302089817503342e5e467f0ac84c92dc4d930e0678bc3479ee4ddb57efd79
name: python-amplitude-analytics
arch: src
version: 1.1.4
epoch: 0
release: 1
summary: The official Amplitude backend Python SDK for server-side instrumentation.
url: https://github.com/amplitude/Amplitude-Python
rpm_license: MIT License
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amplitude-analytics-1.1.4-1.src.rpm
checksum_type: sha256
description:
  <p align="center">
    <a href="https://amplitude.com" target="_blank" align="center">
      <img src="https://static.amplitude.com/lightning/46c85bfd91905de8047f1ee65c7c93d6fa9ee6ea/static/media/amplitude-logo-with-text.4fb9e463.svg" width="280">
    </a>
    <br />
  </p>



  [![PyPI version](https://badge.fury.io/py/amplitude-analytics.svg)](https://badge.fury.io/py/amplitude-analytics)

  The official Amplitude backend Python SDK for server-side instrumentation.



  Refer to `examples/README.md`.



  ```
  python3 -m unittest discover -s ./src -p 'test_*.py'
  ```


  ```
  pip3 install --user tox
  python3 -m tox -e py
  ```


  [Ampli SDK](https://www.docs.developers.amplitude.com/data/ampli/) is autogenerated library based on your pre-defined [tracking plan](https://developers.data.amplitude.com/what-is-a-tracking-plan). The Ampli Wrapper, is a lightweight wrapper over the Amplitude SDK that provides type-safety, supports linting, and enables features like input validation. The code replicates the spec in the Tracking Plan and enforces its rules and requirements. This repository is about **Amplitude SDK**. To learn more about Ampli Wrapper, please refer to the [Ampli Python](https://www.docs.developers.amplitude.com/data/sdks/python/ampli/) and [examples](https://github.com/amplitude/ampli-examples).


  Please visit the [Developer Center](https://docs.developers.amplitude.com/data/sdks/python/) for instructions on installing and using our the SDK.


  View the [releases here](https://github.com/amplitude/Amplitude-Python/releases).


  If you have any issues using our SDK, feel free to [create a GitHub issue](https://github.com/amplitude/Amplitude-Python/issues/new) or submit a request on [Amplitude Help](https://help.amplitude.com/hc/en-us/requests/new).


pkgId: 003b61d77bb23c40044e1582dcdf2065fb7a159098fa9256281da0fa9af8950d
name: python-amplitude-data-wrapper
arch: src
version: 0.5.0
epoch: 0
release: 1
summary: python wrapper for using the amplitude analytics and taxonomy APIs
url: https://github.com/navikt/amplitude-data-wrapper
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amplitude-data-wrapper-0.5.0-1.src.rpm
checksum_type: sha256
description:
  [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)

  This is a wrapper for [Amplitude](https://amplitude.com/) APIs. You can use it to query and export data from your account and use the taxonomy API.

  Built with [requests](https://requests.readthedocs.io/en/latest/) and [tqdm](https://github.com/tqdm/tqdm)

  **Why use this package instead of other wrappers?**

  This package supports regions and so you can use it with Amplitude accounts in the EU and USA.

  This package also supports using a proxy so you can keep your project API keys and API secrets confidential.



  - [Amplitude data wrapper](#amplitude-data-wrapper)
    - [Supported Amplitude APIs and docs](#supported-amplitude-apis-and-docs)
      - [Dashboard Rest API](#dashboard-rest-api)
      - [Privacy API](#privacy-api)
      - [Cohort API](#cohort-api)
      - [Export API](#export-api)
      - [Taxonomy API](#taxonomy-api)

  See examples below and in [example.py](example.py)

  Install with

  ```
  pip install amplitude-data-wrapper
  ```



  [Results from an existing chart](https://developers.amplitude.com/docs/dashboard-rest-api#results-from-an-existing-chart)

  Get data from EU account by setting `region=1`.

  ```python
  import amplitude_data_wrapper.analytics_api as amp


  r = amp.get_chart(
      api_key=api_key, secret=api_secret, chart_id=chart_id_eu, region=1
  )  # region 1 is EU
  r.status_code
  r.json() # returns data as json
  ```

  Get data from US account by setting `region=2`.

  ```python
  r = amp.get_chart(
      api_key=api_key, secret=api_secret, chart_id=chart_id_eu, region=2
  )  # region 2 is USA
  r.json() # returns data as json
  ```

  Get data from EU account with a proxy by setting region and proxy using a dictionary.

  ```python


  proxies = {"http": "http://myproxy.example.org/method"}
  r = amp.get_chart(api_key, api_secret, chart_id_eu, region=1, proxy=proxies)
  r.status_code  # print status code
  ```

  [Event segmentation](https://developers.amplitude.com/docs/dashboard-rest-api#event-segmentation) lets you export events with segments and filters.

  ```python
  our_event_dict = {
      "event_type": "pageview",
      "group_by": [{"type": "event", "value": "app"}, {"type": "event", "value": "team"}],
  }
  data = amp.get_event_segmentation(
      api_key=api_key,
      secret=api_secret,
      start="20220601",
      end="20220602",
      event=our_event_dict,
      metrics="uniques",
      interval=1,
      limit=1000,
  )
  ```

  [User search](https://developers.amplitude.com/docs/dashboard-rest-api#user-search) lets you search for a user with a specific Amplitude ID, Device ID, User ID, or User ID prefix.

  ```python
  user = amp.find_user(
      user=example_id_eu,
      api_key=api_key,
      secret=api_secret,
      region=1)
  ```



  Delete user data with a [deletion job](https://developers.amplitude.com/docs/user-deletion#deletion-job)

  ```python
  deleteme = amp.delete_user_data(
      user["matches"][0]["amplitude_id"],
      email=email,
      api_key=api_key,
      secret=api_secret,
      region=1,
      ignore_invalid_id=True,
      delete_from_org=False,
  )
  ```

  [Get a list of deletion jobs](https://developers.amplitude.com/docs/user-deletion#get)

  ```python
  tobe_deleted = amp.get_deletion_jobs(
      start="2022-06-01",
      end="2022-07-01",
      api_key=api_key,
      secret=api_secret,
      region=1,
  )
  ```



  [Getting one cohort](https://developers.amplitude.com/docs/behavioral-cohorts-api#getting-one-cohort)

  ```python
  proxies = {"http": "http://myproxy.domain.org/path"}
  file_path = "path-to/cohortdata.csv"
  kull = amp.get_cohort(
      api_key,
      api_secret,
      cohort_id,
      filename=file_path,
      props=1,
      region=1,
      proxy=proxies,
  )
  ```



  [Export API - Export your project's event data](https://developers.amplitude.com/docs/export-api#export-api---export-your-projects-event-data)

  ```python
  start = "20220601T00"
  end = "20220601T01"
  data = amp.export_project_data(
      start=start,
      end=end,
      api_key=api_key,
      secret=api_secret,
      filename="path-to/projectdata_eu.zip",
      region=1,
  )
  ```



  [Get all event types](https://developers.amplitude.com/docs/taxonomy-api#get-all-event-types)

  ```python
  types = amp.get_all_event_types(
      api_key=api_key,
      secret=api_secret,
      region=1)
  ```

rpm_license:
  MIT License  Copyright (c) 2022 NAV IT  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


pkgId: 366e7f5a1391cf162fb73eb46f05a47adba05829bd0825cfe92d708664706929
name: python-amplitude-python
arch: src
version: 0.13
epoch: 0
release: 1
summary: please add a summary manually as the author left a blank one
url: https://github.com/atveit/amplitude-python
rpm_license: Apache License 2.0
rpm_group: Unspecified
rpm_buildhost: localhost
location_href: Packages/python-amplitude-python-0.13-1.src.rpm
checksum_type: sha256
description:
  [CircleCI]



  AMPLITUDE-PYTHON


  Python API for Amplitude Analytics Logging - https://amplitude.com

  This API is a simple (unofficial) wrapper for the Amplitude HTTP API


  1. Install amplitude-python

  Potential preparation before installing: create and activate virtualenv or conda environment

  1.1 Install from pypi with conda or pip

      pip install amplitude-python

  1.2 Install from github

      $ git clone https://github.com/atveit/amplitude-python.git
      $ cd amplitude-python
      $ python setup.py instal


  2. Logging to Amplitude with amplitude-python

  Recommend having a look at Amplitude HTTP API Documentation before start logging.

      import amplitude

      
      amplitude_logger = amplitude.AmplitudeLogger(api_key = "SOME_API_KEY_STRING")

      
      event_args = {"device_id":"somedeviceid", "event_type":"justtesting",
                    "event_properties":{"property1":"somevalue", "propertyN":"anothervalue"}
      event = amplitude_logger.create_event(**event_args)

      
      amplitude_logger.log_event(event)


  3. Test amplitude-python module

      python setup.py test


