(in *pb.QuantizationProgressRequest, stream pb.Backend_QuantizationProgressServer)
| 816 | } |
| 817 | |
| 818 | func (s *server) QuantizationProgress(in *pb.QuantizationProgressRequest, stream pb.Backend_QuantizationProgressServer) error { |
| 819 | if s.llm.Locking() { |
| 820 | s.llm.Lock() |
| 821 | defer s.llm.Unlock() |
| 822 | } |
| 823 | updateChan := make(chan *pb.QuantizationProgressUpdate) |
| 824 | |
| 825 | done := make(chan bool) |
| 826 | go func() { |
| 827 | for update := range updateChan { |
| 828 | stream.Send(update) |
| 829 | } |
| 830 | done <- true |
| 831 | }() |
| 832 | |
| 833 | err := s.llm.QuantizationProgress(in, updateChan) |
| 834 | <-done |
| 835 | |
| 836 | return err |
| 837 | } |
| 838 | |
| 839 | func (s *server) StopQuantization(ctx context.Context, in *pb.QuantizationStopRequest) (*pb.Result, error) { |
| 840 | if s.llm.Locking() { |
nothing calls this directly
no test coverage detected