Kfjjdjdjdhdhd commited on
Commit
ef673b7
·
verified ·
1 Parent(s): c663b8c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +14 -8
app.py CHANGED
@@ -106,15 +106,21 @@ async function runDemo() {
106
  })
107
  .catch(error => {
108
  console.error("Error initializing LlmInference:", error);
109
- errorMessageDiv.textContent = `Failed to initialize the task due to WebGPU limitations. Details: ${error} <br><br>` +
110
  `**Troubleshooting Steps:**<br>` +
111
- `- **Ensure you are using a WebGPU-compatible browser:** Chrome or Edge (latest versions recommended).<br>` +
112
- `- **Update your browser to the latest version.**<br>` +
113
- `- **Update your GPU drivers to the latest version.** Visit NVIDIA, AMD, or Intel websites.<br>` +
114
- `- **Restart your computer.**<br>` +
115
- `- **Try a different WebGPU-compatible browser (Chrome or Edge).**<br>` +
116
- `- **Check if WebGPU is enabled in your browser settings/flags.**<br>` +
117
- `- **Your GPU or browser may have limitations for running this specific LLM model in WebGPU.**`;
 
 
 
 
 
 
118
  submit.disabled = true;
119
  submit.value = 'Failed to load model';
120
  });
 
106
  })
107
  .catch(error => {
108
  console.error("Error initializing LlmInference:", error);
109
+ errorMessageDiv.innerHTML = `Failed to initialize the task due to WebGPU limitations. Details: ${error} <br><br>` +
110
  `**Troubleshooting Steps:**<br>` +
111
+ `1. **Verify WebGPU Support:**<br>` +
112
+ ` - **Browser:** Use **Google Chrome** or **Microsoft Edge (latest versions).**<br>` +
113
+ ` - **Check chrome://gpu (or edge://gpu):** In your browser address bar, type \`chrome://gpu\` (or \`edge://gpu\`) and press Enter. Look for "WebGPU" section. <br>` +
114
+ ` - **Status:** Should say "Hardware accelerated". If disabled or "Software only", WebGPU is not working correctly.<br>` +
115
+ ` - **maxStorageBufferBindingSize:** Verify the reported value. If it's very low, your GPU/browser might be too limited.<br>` +
116
+ ` - **Enable WebGPU Flags (if needed):** In chrome://flags (or edge://flags), search for "WebGPU" and try enabling flags like \`#enable-unsafe-webgpu\` and restart browser.<br><br>` +
117
+ `2. **Update Browser and GPU Drivers:**<br>` +
118
+ ` - **Browser:** Update Chrome/Edge to the latest version.<br>` +
119
+ ` - **GPU Drivers:** Download and install the latest drivers from NVIDIA, AMD, or Intel websites for your specific GPU and operating system. **Restart your computer after driver install.**<br><br>` +
120
+ `3. **Restart Your Computer:** A simple restart can resolve temporary issues.<br><br>` +
121
+ `4. **Try a Different Browser/Computer:** Test with a different WebGPU-compatible browser (Chrome/Edge) or on a different computer with a more capable GPU if possible.<br><br>` +
122
+ `5. **Check GPU Compatibility:** Older or very low-end GPUs might have limited WebGPU support.<br><br>` +
123
+ `If the issue persists after these steps, your GPU or browser may have inherent limitations for running this LLM demo in WebGPU.`;
124
  submit.disabled = true;
125
  submit.value = 'Failed to load model';
126
  });