aboutsummaryrefslogtreecommitdiff
path: root/applications
AgeCommit message (Collapse)Author
2024-03-15Add INT64 support to inference_parsermasterJonny Svärd
Change-Id: I2462632f3b87df193c69b277b0944eb4d5d0efac Signed-off-by: Jonny Svärd <jonny.svaerd@arm.com>
2023-08-07Fix parser not always null-terminating model desc23.08-rc223.08-rc123.08Mikael Olsson
The inference parser copies the description from the model using strncpy, which will only add a null-terminator if the source string is shorter than the destination. Otherwise, if the bytes copied are not null-terminated, the destination is left without one. To ensure that the description is always null-terminated, the last byte of the description is now always overwritten with one. Change-Id: I49c23acd12d661e1f5c37088dba2e37935f25fa5 Signed-off-by: Mikael Olsson <mikael.olsson@arm.com>
2023-06-20Replace AllOpsResolver usage with new solutionLedion Daja
AllOpsResolver is no longer available. Create a new similar fallback solution that is based on a MicroMutableOpResolver instance instead. Change-Id: I398d0d99c4d0a5230ab1435796e1e1c6dea47f8f
2023-04-27inference_process: Replace deprecated function callJonny Svärd
Replace deprecated Length() call in Flatbuffers with size(), as suggested by the deprecation warning. Change-Id: If28f85547120598860e3606b3983dc4607247bb0
2023-04-26Make inference process reusableMåns Nilsson
Private members are protected and run job is virtual to make it more flexible to customize running jobs. Change-Id: I2e4a0760000a451eead062ef758b467ea248dffe
2023-04-04Inference app: Call external context after allocate tensorsMåns Nilsson
TFLM now mandates to set external context during prepare or invoke state. Change-Id: I87d3f386aac5c47b71a7abfb9a8c48ff0255fc67
2023-03-14Fix SEI CERT coding standard warningsLedion Daja
Change-Id: I831e4546832aeae22c48b92cd2e8adfac797e704
2023-01-12Reinsert INFERENCE_PROCESS_OPS_RESOLVERKristofer Jonsson
Reinsert INFERENCE_PROCESS_OPS_RESOLVER that was accidentally removed in previous commit. Change-Id: I56b84aadc44b2a5f3c9e35e1fce8ce51036048ba
2022-12-15Remove ethosu_core and ethosu_applicationsKristofer Jonsson
Interface libraries ethosu_core and ethosu_applications are removed. Each application shall depend directly on the libraries they need. Change-Id: I4d37c6c50aa276beaa8e2681a63cea90977477ce
2022-11-30Extend inference_process library to use MicroMutableOpResolverLedion Daja
Added compilation flag to allow the inference_process library to use a MicroMutableOpResolver as an alternative to AllOpsResolver. This allows to only make use of the needed operators instead of the complete list of operators, reducing thus the memory footprint of the application. Change-Id: If1d6751b12e8aa301bb466e3ffae92406200eab4
2022-11-23Use Tensorflow MicroPrintfKristofer Jonsson
Change-Id: I01bbafc45ca2a56759d7d5afbbbacefb40fd9a26
2022-10-20Remove MicroErrorReporter from inference process testMåns Nilsson
MicroErrorReporter has been removed from TFLM. Change-Id: I8acb14eff2bc5d4b05d0d50f0d2a44db846e160f
2022-09-29Profilers inherit MicroProfilerInterface instead of MicroProfilerMåns Nilsson
This will decrease current stack usage requirement and memory footprint. Change-Id: I8ac314238efcdf1622cdcafd479c6cc1a8580509
2022-09-13Log ofm data base64 encodedFredrik Svedberg
Added base64 encoded printing of ofm data to speed up logging of large ofms. Change-Id: Ibebd0a3557396eb68d69789f2c016161e085e64a
2022-08-30Remove path to TFLM make download folderKristofer Jonsson
Change-Id: Iaf22f1d7ad3e732f9163702cc08c8c2a3bb3a69d
2022-08-22Check the validity of the buffer before parsing the modelDavide Grohmann
If the buffer does not point to a well defined flatbuffer the parsing segfaults. Change-Id: Icb8dfef37dc28b2b7a22c6d3804851be8198aa9d
2022-06-14Refactor performance measurementsJonny Svärd
Change 'Inference runtime' to measure CPU cycles for the Tensorflow Lite Micro interpreter.Invoke() call. Add 'Operator(s) runtime' print that prints a summary for cycles spent on all operators during an inference. (This is equivalent to the old reported 'Inference runtime') Move prints out of the EndEvent() function in ArmProfiler as it otherwise interferes with the inference cycle measurement. Change-Id: Ie11b5abb5b12a3bcf5a67841f04834d05dfd796d
2022-04-12Add inference parsing to inference process libraryDavide Grohmann
Change-Id: If90ebe17cc33b8fef9e6a4ebae43a2e5749d8a37
2022-03-21Add size of data in bytes to output tensor printHenrik Hoglind
The printing of the output tensor can be truncated, by adding the original size of the output in bytes the included data can be checked for completeness. The dims will tell the number of elements of the output tensor and is not useful for this purpose as the element size can vary. Change-Id: Ied5447e34416a8c6668eeae5c01a5474f103023f
2022-02-10Increase GetTotalTicks() to uint64_t22.02-rc222.02-rc1Kristofer Jonsson
For larger networks the GetTotalTicks() might overflow if the function returns int32_t. GetTotalTicks() is a non virtual function that can be overridden with a different return type in the implementation class. Change-Id: I8dd2e448fd13e0823fe1e5f9cc335998d2806416
2022-02-10Break out the Crc class to its own libraryJonny Svärd
Change-Id: Iefa21223b9157e25e11f88873541b39292d12872
2022-02-09Do not set external context if NULLDavide Grohmann
This avoids a warning in TFLu Change-Id: I90f6d6cefbe69c720d3c65c550d7f65e727c48fb
2022-01-31Set TFLu external contextKristofer Jonsson
Remove PMU configuration from the InferenceJob struct and add an external context parameter intead. The external context is passed to the TFLu interpreter and will be returned in the ethosu_inference_begin() and ethosu_inference_end() callbacks. Change-Id: I6dab04c0ab5088b1325be365d77d65d1182e7441
2022-01-27Inference process updateKristofer Jonsson
Split runJob() into smaller functions to make the code easier to read and maintain. Correct return type of Layer By Layer profiler GetTotalTicks(). Change-Id: Ie414522017b3b6c6da9a09182439dbe4b2efdb1f
2022-01-14Remove unused functionsKristofer Jonsson
Change-Id: Idffa9b21385451883795412076ea48218d6c74ba
2021-12-22Use lbl-profiler to setup PMU and PMU eventsJonny Svärd
Adapt layer-by-layer profiler to handle PMU event configuration, PMU setup and retrieving PMU counter values. Adapt the inference process application to support the lbl-profiler PMU setup and retrieve/save PMU counter values in the InferenceJob struct. Change-Id: I1667a5b11c43c54e7d28232b594dd118bf3f79a8
2021-12-08Add crc32 of output to inference_runnerHenrik Hoglind
Change-Id: I7cd561d96bf88fa24c1e3dc5f3b30403bfacafb8
2021-11-18Remove new line from log messages21.11-rc2Kristofer Jonsson
Remove new line from log messages to allow the log makros to format the output. Removing 'message process'. It has been replaced by the 'message handler' application in core platform. Change-Id: Ie97063680c25a33844a8e52e7d39f042da0493e1
2021-09-09Update call to MicroInterpreter to be in line with upstreamJens Elofsson
Change-Id: Ib69b8c0a9af482408f2108ea13c682afabb9f0c7
2021-08-30Exporting define for layer by layer profiler21.08-rc321.08Kristofer Jonsson
Libraries that link the layer_by_layer_profiler interface library will also get the LAYER_BY_LAYER_PROFILE define appending to the build arguments. This allows the preprocessor to select which profiler to use. Change-Id: I85fec66d2dd9949fd7fe395fb44e49bda1539925
2021-08-17Layer-by-layer logging bugAnton Moberg
The tflu_debug_log should be controlled by tflu and not the core_software. Thus changing LOG_DEBUG -> LOG shifts control from core_software to tflu. Change-Id: I3507366cee8c971b1242434ea73f405a8abc5f83
2021-08-16Fix wrong output data json format when compiling with GCC21.08-rc1Davide Grohmann
This change works around an issue when compiling with GCC where by printing only a '\n' the produced global output is wrong. What happens is that new lines are actually printed before the content in the precedent fprintf calls. Hence the generated json is unparsable. Note also that replacing the LOG macros with direct calls to fprintf does _not_ solve the issue. Change-Id: I2d97703cbe7703aae94def1943e2ac693945ab31
2021-08-12Do not expose device specific info in capabilitiesDavide Grohmann
Change-Id: Id43be4f899610e9b0ef96790fbff330f3c8537c1
2021-07-15Improved Logging - Core SoftwareAnton Moberg
Logging macros: Added ethosu_logging.h as a lib, containing logging macros controlled by a parameter ETHOSU_LOG_SEVERITY set in core_software CMakeLists.txt Updated inference_process: Updated inference_process to include ethosu_logging and use the logging macros rather than printf() Updated message_process: Updated message_process to include ethosu_logging and use the logging macros rather than printf() Updated ethosu_monitor: Updated ethosu_monitor to include ethosu_logging and use the logging macros rather than printf() Updated layer_by_layer_profiler: Updated layer_by_layer_profiler to include ethosu_logging and use the logging macros rather than printf() Updated mhu_v2: Updated mhu_v2 to include ethosu_logging and use the logging macros rather than printf() Change-Id: I5d6fd80b7645b3e0af5b494eea6dbb7755f02122
2021-06-29Removing profiler defineKristofer Jonsson
Removing define that is no longer needed now that the profiler classes have been implemented. Updating .gitignore. Change-Id: Idc1eab268a4f4d1ff9460671f8547c1fcb209f82
2021-06-15Switch to the new tflite-micro repo.Jens Elofsson
Change-Id: I19b806e94207580ab548e8cd4ddada32debf0639
2021-06-10Add support for fetching ethosu capabilitiesDavide Grohmann
Change-Id: I5507b42a66649ab04f7a5932777830d105b3123b
2021-05-27Add Event Recorder ProfilingJens Elofsson
* Add event recorded profiling to ethosu_profiler. * Rename ethosu_profiler to layer_by_layer_profiler. Change-Id: Ie39c29845b2d1eb6d9d72e3fce68bf373e9dc888
2021-05-21Remove the PMU event register handling from EthosuProfiler.Jens Elofsson
Change-Id: I8d303043806e081238067e5773e4d4125bc64cfa
2021-05-21Add EthosuProfiler to perform layer-by-layer profiling on Ethos-U.Jens Elofsson
Change-Id: Idae34fd8ab6b17b0bc21db658fff135a5ddf5461
2021-03-31Update license headersAnton Moberg
Update all license headers to the correct years Change-Id: I638a854b39b4afe8db6a4a76ca6dcb89c126e3c1
2021-03-26Handle empty pmuConfigs in InferenceJob for runJobPer Åstrand
Verify that the size of the pmueventconfig argument is the expected size before accessing the vector and set up the pmu counters to be ETHOSU_PMU_NO_EVENT if it's not. Change-Id: Icfcf5255e7e99fd3bcae6535d54f8c18e89e24f2
2021-02-25Fix misleading log messages21.02Per Åstrand
Change-Id: I2f0a7c9ec9e59b2a076bfd873e5a997189c67e11
2021-02-24Tensorflow rebaseKristofer Jonsson
The interface to the MicroProfiler has changed in the latest revision of TFLu. Updating core software to fix the compilation errors. Change-Id: Ief8cc17859c9abcb9455110c660c0de56d938fe5
2021-02-23Assembly supportKristofer Jonsson
Update the Arm Clang toolchain file to support assembly files. Removing cmsis_core dependency. Applications that depend on CMSIS should add that dependency manually. Change-Id: I42d68e6734acc88aef8f9af124b5e76079b839b5
2021-02-23Use ethosu namespace for core interfacePer Åstrand
Change-Id: I832b8d7b502ae501e39f1a795d4192506d47fa55
2021-02-12core_software - Move TensorArena21.02-rc2Anton Moberg
Moved TensorArena in inference_process.ccp to application level. InferenceProcess class now takes TensorArena pointer and TensorArenaSize as parameters. Needs to be set by application before runJob() is called. Change-Id: I530b96039868305fa903ae7f93419d9d00f9c16f
2021-02-01Missing cache maintenanceKristofer Jonsson
Add missing cache invalidate before queue header is checked for available messages. Change-Id: Iba1238dddcf6b9771d17c9b9edab3f7594ee59af
2021-01-27Improve mailbox msg handling for MessageProcessJonny Svärd
Send/verify 32b message magic Add version response support In case an error occurs with the messaging, send an error response and effectively reset/empty the queue. Add support for error response Fix a couple of bugs where mailbox interrupts were sent even when a previous error occured. Change-Id: I6a1fdefd0d6eb68c9b22123c156ff820ce9c0399
2021-01-13Rename cplusplus files for consistencyPer Åstrand
Change-Id: I908ea337ffb7229a33af3364b5374209c7e9df54