This repository was archived by the owner on Jun 3, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +36
-0
lines changed
tests/deepsparse/transformers/pipelines Expand file tree Collapse file tree 1 file changed +36
-0
lines changed Original file line number Diff line number Diff line change
1
+ # Copyright (c) 2021 - present / Neuralmagic, Inc. All Rights Reserved.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing,
10
+ # software distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ import pytest
16
+ from deepsparse import Pipeline
17
+
18
+
19
+ @pytest .fixture (scope = "session" )
20
+ def model_stub ():
21
+ return (
22
+ "zoo:nlg/text_generation/codegen_mono-350m/pytorch/"
23
+ "huggingface/bigpython_bigquery_thepile/base-none"
24
+ )
25
+
26
+
27
+ @pytest .mark .smoke
28
+ def test_aggregation_strategy ():
29
+ pipeline = Pipeline .create (
30
+ task = "text_generation" ,
31
+ model_path = model_stub ,
32
+ max_generated_tokens = 32 ,
33
+ prompt_processing_sequence_length = 1 ,
34
+ )
35
+
36
+ pipeline (sequences = "def fib():" )
You can’t perform that action at this time.
0 commit comments