| 3604 | } |
| 3605 | |
| 3606 | static struct ggml_tensor * ggml_view_impl( |
| 3607 | struct ggml_context * ctx, |
| 3608 | struct ggml_tensor * a, |
| 3609 | int n_dims, |
| 3610 | const int64_t * ne, |
| 3611 | size_t offset) { |
| 3612 | struct ggml_tensor * result = ggml_new_tensor_impl(ctx, a->type, n_dims, ne, a, offset); |
| 3613 | ggml_format_name(result, "%s (view)", a->name); |
| 3614 | |
| 3615 | ggml_set_op_params(result, &offset, sizeof(offset)); |
| 3616 | |
| 3617 | result->op = GGML_OP_VIEW; |
| 3618 | result->src[0] = a; |
| 3619 | |
| 3620 | return result; |
| 3621 | } |
| 3622 | |
| 3623 | // ggml_view_1d |
| 3624 |
no test coverage detected