| 538 | } |
| 539 | |
| 540 | void Layer::SerializeLayerParameters(ParameterStringifyFunction& fn) const |
| 541 | { |
| 542 | std::string guid = std::to_string(m_Guid); |
| 543 | std::string layerType = GetLayerTypeAsCString(m_Type); |
| 544 | std::string backendId = std::string(m_BackendId); |
| 545 | if (!(guid.compare("") == 0) && !guid.empty()) |
| 546 | { |
| 547 | fn("Guid", guid); |
| 548 | } |
| 549 | if(!(m_LayerName.compare("") == 0) && !m_LayerName.empty()) |
| 550 | { |
| 551 | fn("LayerName",m_LayerName); |
| 552 | } |
| 553 | if(!(layerType.compare("") == 0) && !layerType.empty()) |
| 554 | { |
| 555 | fn("LayerType",layerType); |
| 556 | } |
| 557 | if(!(backendId.compare("") == 0) && !backendId.empty()) |
| 558 | { |
| 559 | fn("BackendID",backendId); |
| 560 | } |
| 561 | std::shared_ptr<ActivationDescriptor> |
| 562 | activationDescPtr = GetAdditionalInformation<ActivationDescriptor>(); |
| 563 | |
| 564 | if (activationDescPtr) |
| 565 | { |
| 566 | StringifyLayerParameters<ActivationDescriptor>::Serialize(fn, *activationDescPtr.get()); |
| 567 | } |
| 568 | } |
| 569 | |
| 570 | // default implementation of ExecuteStrategy |
| 571 | void Layer::ExecuteStrategy(IStrategy& strategy) const |
no test coverage detected