Helper static functions to construct parameters for XlaLocalLaunchBase constructor from OpKernelConstruction.
| 418 | // Helper static functions to construct parameters for |
| 419 | // XlaLocalLaunchBase constructor from OpKernelConstruction. |
| 420 | std::vector<int> ConstantsVector(OpKernelConstruction* ctx) { |
| 421 | DataTypeVector constant_types; |
| 422 | OP_REQUIRES_OK_RETURN(ctx, std::vector<int>(), |
| 423 | ctx->GetAttr("Tconstants", &constant_types)); |
| 424 | std::vector<int> constants(constant_types.size()); |
| 425 | std::iota(constants.begin(), constants.end(), 0); |
| 426 | return constants; |
| 427 | } |
| 428 | |
| 429 | std::vector<int> ResourcesVector(OpKernelConstruction* ctx) { |
| 430 | DataTypeVector constant_types; |
no test coverage detected