platform_hardware_interfaces/neuralnetworks/1.1
Michael Butler a685c3dbf4 Create conversions to/from NNAPI canonical types
This CL creates the following primary sets of functions:
* V1_X::utils::convert(<canonical_type>) -- Converts a canonical type
  to the corresponding HAL version type.
* nn::convert(<V1_X_HAL_type>) -- Converts a HAL version type to the
  corresponding canonical type.
* neuralnetworks::utils::hasNoPointerData -- Indicates if the object
  contains no pointer-based data that could be relocated to shared
  memory.
* neuralnetworks::utils::flushDataFromPointerToShared -- Relocate
  pointer-based data to shared memory.
* neuralnetworks::utils::unflushDataFromSharedToPointer -- Undoes
  `flushDataFromPointerToShared` on a Request object. More
  specifically, `unflushDataFromSharedToPointer` copies the output
  shared memory data from the transformed Request object back to the
  output pointer-based memory in the original Request object.

It also introduces some other minor utility code, including
makeQuantized8PerformanceConsistentWithP, countNumberOfConsumers,
validate, valid, and validatedConvertToCanonical.

Bug: 160667419
Test: mma
Change-Id: I0732e658c1f4ed40cd122f1ca8581fb40b056757
2020-10-01 11:32:53 -07:00
..
utils Create conversions to/from NNAPI canonical types 2020-10-01 11:32:53 -07:00
vts Suppress gtest error for tests without any instance 2020-07-28 15:12:32 -07:00
Android.bp update hidl .bp 2020-07-07 16:22:36 +09:00
IDevice.hal NNAPI: Add execution preference to prepareModel (HAL) 2018-04-18 19:08:24 +00:00
types.hal NNAPI: Clarify behaviour of ops that reduce dimensions 2020-05-19 13:39:26 -07:00
types.t Replace sync_enums_to_hal.py with generate_api.{py,sh} and regenerate */types.hal 2019-10-09 14:18:06 +01:00