microsoft / onnxruntime-genai

Generative AI extensions for onnxruntime
MIT License
321 stars 72 forks source link

[DML] [iGPU] [AMD] [Intel] GPU command exception #667

Open tjtanaa opened 1 week ago

tjtanaa commented 1 week ago

I encounter the following error:

2024-07-02 17:22:22.977 | INFO     | embeddedllm.engine:generate:359 - Generation Request Prompt length: 970, New tokens: 50
2024-07-02 17:22:26.036 | ERROR    | embeddedllm.engine:generate:432 - D:\a\_work\1\onnxruntime-genai\src\dml\dml_command_recorder.cpp(143)\onnxruntime_genai.cp310-win_amd64.pyd!00007FFAA661D3A3: (caller: 00007FFAA66112A5) Exception(1) tid(638e0) 887A0006 The GPU will not respond to more commands, most likely because of an invalid command passed by the calling application.

Platform (AMD)

  1. AMD Radeon 780M Graphics
  2. 8GB Dedicated GPU memory
  3. 27.9GB Shared GPU memory
  4. Model: https://huggingface.co/microsoft/Phi-3-mini-4k-instruct-onnx/tree/main/directml/directml-int4-awq-block-128

Platform (Intel)

  1. Intel(R) Arc(TM) Graphics
  2. 31.7GB Shared GPU memory
  3. Model: https://huggingface.co/microsoft/Phi-3-mini-4k-instruct-onnx/tree/main/directml/directml-int4-awq-block-128

Step to reproduce

  1. conda create -n onnxdml python=3.10
  2. conda activate onnxdml
  3. pip install onnxruntime-genai-directml
  4. Follow the example at https://onnxruntime.ai/docs/genai/tutorials/phi3-python.html#run-with-directml .

Params:

do_sample: True
temperature: 0.1
top_k: 1,
top_p: 0.1
output_tokens: 50

Input Prompt

Summarize the following text:  Sea turtles superfamily Chelonioidea sometimes called marine turtles3 are reptiles of the order Testudines and of the suborder Cryptodira The seven existing species of sea turtles are the flatback green hawksbill leatherback loggerhead Kemps ridley and olive ridley45 Six of the seven sea turtle species all but the flatback are present in US waters and are listed as endangered andor threatened under the Endangered Species Act6 All but the flatback turtle are listed as threatened with extinction globally on the IUCN Red List of Threatened Species The flatback turtle is found only in the waters of Australia Papua New Guinea and Indonesia76  Sea turtles can be categorized as hardshelled cheloniid or leatheryshelled dermochelyid8 The only dermochelyid species of sea turtle is the leatherback8  Description For each of the seven species of sea turtles females and males are the same size As adults it is possible to tell male turtles from female turtles by their long tails with a cloacal opening near the tip Adult female sea turtles have shorter tails with a cloacal opening near the base Hatchling and subadult turtles do not exhibit sexual dimorphism it is not possible to determine their sex by looking at them9  In general sea turtles have a more fusiform body plan than their terrestrial or freshwater counterparts This tapering at both ends reduces volume and means that sea turtles cannot retract their head and limbs into their shells for protection unlike many other turtles and tortoises10 However the streamlined body plan reduces friction and drag in the water and allows sea turtles to swim more easily and swiftly  The leatherback sea turtle is the largest sea turtle reaching 14 to more than 18 m 46 to 59 ft in length and weighing between 300 and 640 kg 661 to 1411 lbs11 Other sea turtle species are smaller ranging from as little as 60 cm 2 ft long in the case of the Kemps ridley which is the smallest sea turtle species to 120 cm 39 ft long in the case of the green turtle the second largest512  The skulls of sea turtles have cheek regions that are enclosed in bone1314 Although this condition appears to resemble that found in the earliest known fossil reptiles anapsids it is possible it is a more recently evolved trait in sea turtles placing them outside the anapsids1513  Taxonomy and evolution Sea turtles along with other turtles and tortoises are part of the order Testudines All species except the leatherback sea turtle are in the family Cheloniidae The superfamily name Chelonioidea and family name Cheloniidae are based on the Ancient Greek word for tortoise  khelone16 The leatherback sea turtle is the only extant member of the family Dermochelyidae  Fossil evidence of marine turtles goes back to the Late Jurassic 150 million years ago with genera such as Plesiochelys from Europe In Africa the first marine turtle is Angolachelys from the Turonian of Angola17 A lineage of unrelated marine testudines the pleurodire sidenecked bothremydids also survived well into the Cenozoic Other pleurodires are also thought to have lived at sea such as Araripemys18 and extinct pelomedusids19 Modern sea turtles are not descended from more than one of the groups of seagoing turtles that have existed in the past they instead constitute a single radiation that became distinct from all other turtles at least 110 million years ago202122 Their closest extant relatives are in fact the snapping turtles Chelydridae musk turtles Kinosternidae and hickatee Dermatemyidae of the Americas which alongside the sea turtles constitute the clade Americhelydia23
natke commented 6 days ago

Thank you for reporting this issue. We are looking into it.