mirror of
				https://github.com/ggml-org/llama.cpp.git
				synced 2025-11-03 09:22:01 +00:00 
			
		
		
		
	ggml : fix YARN + add tests + add asserts (#7617)
* tests : add rope tests ggml-ci * ggml : fixes (hopefully) ggml-ci * tests : add non-cont tests ggml-ci * cuda : add asserts for rope/norm + fix DS2 ggml-ci * ggml : assert contiguousness * tests : reduce RoPE tests ggml-ci
This commit is contained in:
		@@ -170,6 +170,8 @@ void ggml_cuda_op_norm(ggml_backend_cuda_context & ctx, ggml_tensor * dst) {
 | 
			
		||||
    float * dst_d = (float *)dst->data;
 | 
			
		||||
    cudaStream_t stream = ctx.stream();
 | 
			
		||||
 | 
			
		||||
    GGML_ASSERT(ggml_is_contiguous(src0));
 | 
			
		||||
 | 
			
		||||
    GGML_ASSERT(src0->type == GGML_TYPE_F32);
 | 
			
		||||
    GGML_ASSERT( dst->type == GGML_TYPE_F32);
 | 
			
		||||
 | 
			
		||||
@@ -188,6 +190,8 @@ void ggml_cuda_op_group_norm(ggml_backend_cuda_context & ctx, ggml_tensor * dst)
 | 
			
		||||
    float * dst_d = (float *)dst->data;
 | 
			
		||||
    cudaStream_t stream = ctx.stream();
 | 
			
		||||
 | 
			
		||||
    GGML_ASSERT(ggml_is_contiguous(src0));
 | 
			
		||||
 | 
			
		||||
    GGML_ASSERT(src0->type == GGML_TYPE_F32);
 | 
			
		||||
    GGML_ASSERT( dst->type == GGML_TYPE_F32);
 | 
			
		||||
 | 
			
		||||
@@ -202,6 +206,8 @@ void ggml_cuda_op_rms_norm(ggml_backend_cuda_context & ctx, ggml_tensor * dst) {
 | 
			
		||||
    float * dst_d = (float *)dst->data;
 | 
			
		||||
    cudaStream_t stream = ctx.stream();
 | 
			
		||||
 | 
			
		||||
    GGML_ASSERT(ggml_is_contiguous(src0));
 | 
			
		||||
 | 
			
		||||
    GGML_ASSERT(src0->type == GGML_TYPE_F32);
 | 
			
		||||
    GGML_ASSERT( dst->type == GGML_TYPE_F32);
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user