Helios-sdk

Latest version: v3.0.1

Safety actively analyzes 685670 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 3

2.2.0

Future breaking changes
* Configuration/authentication files moved to `~/.helios/`
* `~/.helios_auth` -> `~/.helios/credentials.json`
* `HELIOS_KEY_ID` -> `helios_client_id`
* `HELIOS_KEY_SECRET` -> `helios_client_secret`
* `HELIOS_API_URL` -> `helios_api_url`
* `~/helios_logger_config.json` -> `~/.helios/logger.json`
* A DeprecationWarning will be triggered when trying to use the file structure from previous versions.
* Refer to the readme or authentication section of the documentation for more information.

2.1.0

Overview

* Many docs improvements.
* Docs will be hosted soon.
* Data returned from SDK methods are much more user friendly.

Breaking Changes

* `Cameras.images_range()` removed.
* Functionality merged into `Cameras.images()`.
* `download_images()` removed from all core API.
* Download functionality merged into `show_image()` and `preview()`.
* See below for changes to the data returned from many methods.

New Features

* Effort to improve ease of use when dealing with returned data.
* An `Observations.index()` call would previously return a list of dictionaries. These dictionaries are formatted as GeoJSON feature collections. The user would have to parse this list of dictionaries to extract meaningful data.
* This call will now return an `IndexResult` instance. This is an iterator for the features returned in all feature collections. Important data will be automatically parsed and accessible to the user via convenience properties and iteration.
* Authentication is now deferred until after initial import.
* Introduced a `Session` class to contain authentication details.
* Can be started and reused for multiple core API instances.
* Creating instances of any core API will automatically start a `Session` using the stored credentials in a .helios_auth file or environment variables. This means there are no breaking changes.
* By allowing for dynamic authentication, rather than at import time, Python does not need to be restarted if your access token expires. A new `Session` or core API instance can be created instead.

`Session` example:

Python
import helios

Reuse session
sess = helios.Session()
obs_inst = helios.Observations(session=sess)
alerts_inst = helios.Alerts(session=sess)

Automatically create session within each instance.
obs_inst = helios.Observations()
alerts_inst = helios.Alerts()



Alerts

* The `index` method will return an instance of `IndexResults`
* The `show` method will return an instance of `ShowResults`

Cameras

* The `index` method will return an instance of `IndexResults`
* The `show_image` method will return an instance of `ShowImageResults`
* The `show` method will return an instance of `ShowResults`

Collections

* The `index` method will return an instance of `IndexResults`
* The `preview` method will return an instance of `PreviewResults`
* The `show` method will return an instance of `ShowResults`
* Added `delete` method.
* This will completely remove a collection that is empty.
* If the collection is not empty this will fail.
* Added `empty` method.
* Call this method to bulk delete up to 1000 images at a time from a collection.

Observations

* The `add_image` method will return an instance of `AddImageResults`
* The `index` method will return an instance of `IndexResults`
* The `remove_image` method will return an instance of `RemoveImageResults`
* The `show_image` method will return an instance of `ShowImageResults`
* The `show` method will return an instance of `ShowResults`
* `IndexResults` and `ShowResults` have a method called `sensors_to_dataframes`.
* Calling this method will extract important information associated with sensors and return Pandas DataFrame instances for each sensor.
* Extracted information: time, sensor name, value, previous value, ID, and previous ID.
* Optionally, data can be written to CSV files. (one file per sensor)

Example to show off some of the new functionality:

Python
import helios
obs_inst = helios.Observations()
index_results = obs_inst.index(state=='georgia')

index_results will be an IndexResults instance.
ids = [x.id for x in index_results] iterate over features.
ids_atlanta = [x.id for x in index_results if x.city == 'Atlanta'] Selective return from iteration.

or for convenience.
ids = index_results.id gather all IDs
cities = index_results.city gather all city data.

Gather important sensor data, write to CSV files, and return Pandas DataFrames.
sensor_data = index_results.sensors_to_dataframes(output_dir='/data')

Debug failed calls in batch jobs.
failed = index_results.failed

2.0.0

Major Breaking Change
* The `heliosSDK` package is now just `helios`
* Use `import helios`.
* __Do not__ use `import heliosSDK` anymore.

Additional Breaking changes
* With the PEP8 effort many name changes occurred.
* e.g. `addImage()` is now `add_image()`

Cameras
* `images`
* Returns list of times.
* `images_range`
* Returns list of times.

Collections
* `create`
* Returns new collection ID.
* `images`
* Returns list of image names.
* `add_image`
* Now follows the [official documentation](https://helios.earth/developers/api/collections/add-image).
* List of dictionaries as input containing the acceptable payloads.
* Returns any input data that failed.
* `remove_image`
* Returns any input data that failed.

Observations
* `preview`
* Returns list of urls.

Shared methods
* `show_image`
* Returns list of URLs.

Areas of improvement
* Effort to standardize to PEP8
* Line length is loosely followed.
* Stability improvements
* Added preliminary Sphinx documentation infrastructure.
* This will continue to improve and will be hosted in some way soon.
* The [helios-sdk](https://pypi.python.org/pypi/helios-sdk) is now available via PyPI.
* `pip install helios-sdk`
* From python use `import helios`

1.1.1

This release is a hotfix for Python 2 - Python 3.2 compatibility.

Multiprocessing Pool objects are not context manager in Python versions less than 3.3.

From the [Python 3 multiprocessing.Pool() documentation](https://docs.python.org/3/library/multiprocessing.htmlmodule-multiprocessing.pool):

1.1.0

Improvements
* Refactored to make use of Requests sessions
* RequestManager was overhauled as a result
* more consistent/logical error handling
* All http errors will be handled in RequestManager
* RequestManager now supports PATCH requests.
* Update method added to Collections. Refer to the [documentation](https://helios.earth/developers/api/collections/update) for more information.
* logging defaults to stdout and no longer writes to a rotating file
* bug fixes

Testing
* Added integration tests for:
* Alerts
* Cameras
* Observations
* TODO: Collections

1.0.0

First release of the heliosSDK.

* Batch jobs will no longer fail on HTTP errors.
* Threading via queues has been removed in favor of built-in thread pool capabilities. This improves reliability.
* Logging has been added
* Info+ levels written to log file
* Warnings+ levels written to stdout
* Core method extensions to support batch jobs have been removed.
* E.g. showImages() has now been merged into showImage()
* Methods such as this one will automatically use threading when a batch job is started.
* Method removal summary:
* previews()
* showImages()
* addImages()
* removeImages()

Page 2 of 3

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.