AgX on the GPU displays incorrect Object texture coordinates #113220

Open
opened 2023-10-03 21:13:38 +02:00 by Jesse Yurkovich · 5 comments

System Information
Operating system: Windows-10-10.0.22621-SP0 64 Bits
Graphics card: NVIDIA GeForce RTX 4090/PCIe/SSE2 NVIDIA Corporation 4.6.0 NVIDIA 528.24

Blender Version
Broken: version: 4.1.0 Alpha, branch: main, commit date: 2023-10-02 08:29, hash: 7f7e1ab08842

Short description of error
AgX on the GPU differs from the CPU implementation for Object coordinates. This seems to only impact the visual, not the actual coordinates, but is fairly extreme.

Exact steps for others to reproduce the error

  • Load attached .blend
  • Switch to Viewport Render mode
  • Try to view the Object Texture Coordinates using Cycles CPU [1]
  • Now switch to Cycles GPU [2]

Addendum: An odd thing happens with Final renders. When trying F12 render in the attached file you'll get both outputs. The "Noisy Image" will be skewed, but the "Combined" image will be ok.

[1]
image

[2]
image

**System Information** Operating system: Windows-10-10.0.22621-SP0 64 Bits Graphics card: NVIDIA GeForce RTX 4090/PCIe/SSE2 NVIDIA Corporation 4.6.0 NVIDIA 528.24 **Blender Version** Broken: version: 4.1.0 Alpha, branch: main, commit date: 2023-10-02 08:29, hash: `7f7e1ab08842` **Short description of error** AgX on the GPU differs from the CPU implementation for Object coordinates. This seems to only impact the visual, not the actual coordinates, but is fairly extreme. **Exact steps for others to reproduce the error** - Load attached .blend - Switch to Viewport Render mode - Try to view the Object Texture Coordinates using Cycles CPU [1] - Now switch to Cycles GPU [2] Addendum: An odd thing happens with Final renders. When trying F12 render in the attached file you'll get both outputs. The "Noisy Image" will be skewed, but the "Combined" image will be ok. [1] ![image](/attachments/a140ec1a-c5bf-42a8-8d56-10fdb435b756) [2] ![image](/attachments/667aa0cb-4d40-418f-acd6-f5c7c99aa710)
Jesse Yurkovich added the
Type
Report
Priority
Normal
Status
Needs Triage
labels 2023-10-03 21:13:39 +02:00
Member

I think this is mostly due to it's using LUTs to display data channels... But it should not differ on CPU and GPU. Could you check if you could click on rendered image and see if the same position has the same rgb values?

I think this is mostly due to it's using LUTs to display data channels... But it should not differ on CPU and GPU. Could you check if you could click on rendered image and see if the same position has the same rgb values?
Author
Member

For final renders, where I can view the rgb values, the result is the same for CPU and GPU there; but as noted in the description things are still skewed for "Noisy Image" but seem ok for the "Combined" image.

For final renders, where I can view the rgb values, the result is the same for CPU and GPU there; but as noted in the description things are still skewed for "Noisy Image" but seem ok for the "Combined" image.
Member

I can confirm.
cc @Eary @nathanvegdahl

I can confirm. cc @Eary @nathanvegdahl
Pratik Borhade added
Module
Render & Cycles
Status
Confirmed
and removed
Status
Needs Triage
labels 2023-10-04 06:34:09 +02:00
Contributor

This is not a bug. First of all texture coordinate is not color, they are Generic Data, A.K.A Non-Color data. They have blue sockets, meaning they are vectors not colors. They are, as their name suggests, coordinate data to map a texture onto an object.

What happens if you send unbounded vectors to AgX? It thought they are wider gamut values! What else would AgX think they are?
image

EEVEE clips negative values all the time. Cycles CPU viewport has always clipped wider gamut values (this holds true even in Spectral branch), but end render after finished will display unclipped result. The denoiser will clip wider gamut values, it has always been the case, even in Spectral Cycles branch.

Here is what the denoiser has done to the above data:
image

So this is expected behavior of AgX treating negative values as wider gamut. And you just start noticing negative values getting clipped by different places of Blender, which we need to eventually deal with after Spectral Cycles becomes ready.

Not a bug here.

This is not a bug. First of all texture coordinate is not color, they are Generic Data, A.K.A Non-Color data. They have blue sockets, meaning they are vectors not colors. They are, as their name suggests, coordinate data to map a texture onto an object. What happens if you send unbounded vectors to AgX? It thought they are wider gamut values! What else would AgX think they are? ![image](/attachments/a5f562d2-7780-4a4e-a57a-19a0b5fda326) EEVEE clips negative values all the time. Cycles CPU viewport has always clipped wider gamut values (this holds true even in Spectral branch), but end render after finished will display unclipped result. The denoiser will clip wider gamut values, it has always been the case, even in Spectral Cycles branch. Here is what the denoiser has done to the above data: ![image](/attachments/c1cc7f78-c971-4750-b888-2d79f7549afe) So this is expected behavior of AgX treating negative values as wider gamut. And you just start noticing negative values getting clipped by different places of Blender, which we need to eventually deal with after Spectral Cycles becomes ready. Not a bug here.
702 KiB
551 KiB
Author
Member

Why the difference between Cycles CPU viewport and Cycles GPU viewport?

All in all this is good information to put in the Documentation - about the clamping and the negative values and the denoisers etc. You can even use the texture coordinate as a visual example to demonstrate. A half dozen people occupied their time on this issue the other day before I filed it on their behalf. It would be good to just have something written down that would describe the behavior they're seeing.

Why the difference between Cycles CPU viewport and Cycles GPU viewport? All in all this is good information to put in the Documentation - about the clamping and the negative values and the denoisers etc. You can even use the texture coordinate as a visual example to demonstrate. A half dozen people occupied their time on this issue the other day before I filed it on their behalf. It would be good to just have something written down that would describe the behavior they're seeing.
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
4 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#113220
No description provided.