Cycles Smoke/Fire render procudes NAN pixels #48383

Closed
opened 2016-05-09 01:48:39 +02:00 by Thomas Dinges · 16 comments

System Information
Ubuntu Linux 16.04
Geforce 730
Core i5 3570 (so it's the AVX kernel).

Blender Version
Broken: current Master

Short description of error

  • Switch to Cycles, execute "Quick Smoke" (Smoke + Fire).
  • Alt+A to bake some frames
  • Render with F12 (CPU render)

I can see a lot of NAN pixels there. This does not happen when rendering with GPU.

smoke.blend
smoke.png

**System Information** Ubuntu Linux 16.04 Geforce 730 Core i5 3570 (so it's the AVX kernel). **Blender Version** Broken: current Master **Short description of error** * Switch to Cycles, execute "Quick Smoke" (Smoke + Fire). * Alt+A to bake some frames * Render with F12 (CPU render) I can see a lot of NAN pixels there. This does not happen when rendering with GPU. [smoke.blend](https://archive.blender.org/developer/F309830/smoke.blend) ![smoke.png](https://archive.blender.org/developer/F309831/smoke.png)
Author
Owner

Changed status to: 'Open'

Changed status to: 'Open'
Sergey Sharybin was assigned by Thomas Dinges 2016-05-09 01:48:39 +02:00
Author
Owner

Added subscriber: @ThomasDinges

Added subscriber: @ThomasDinges
Author
Owner

The builds from Buildbot are fine, only happens with my self compiled build.

I did a full clean build, did not fix it. Attaching my system-info here, no idea whats wrong. system-info.txt

The builds from Buildbot are fine, only happens with my self compiled build. I did a full clean build, did not fix it. Attaching my system-info here, no idea whats wrong. [system-info.txt](https://archive.blender.org/developer/F309867/system-info.txt)

Check if it's a regression since some previous release (checkout to a previous releases, compile them and see). If so you can bisect what revision caused the issue.

I'm on very similar setup to the buildbot and release environment and can't reproduce the issue, so unlikely to help here.

Check if it's a regression since some previous release (checkout to a previous releases, compile them and see). If so you can bisect what revision caused the issue. I'm on very similar setup to the buildbot and release environment and can't reproduce the issue, so unlikely to help here.
Member

Added subscriber: @LukasTonne

Added subscriber: @LukasTonne
Member

I get kernel_assert failures relating to the emission part of the L_sum here:
https://developer.blender.org/diffusion/B/browse/master/intern/cycles/kernel/kernel_accumulate.h$450

@Sergey: It only happens after enough time into the simulation, presumably when the smoke starts intersecting the domain box.

I get `kernel_assert` failures relating to the emission part of the `L_sum` here: https://developer.blender.org/diffusion/B/browse/master/intern/cycles/kernel/kernel_accumulate.h$450 @Sergey: It only happens after enough time into the simulation, presumably when the smoke starts intersecting the domain box.

@LukasTonne, any particular frame number i am to render to see that? What frame you rendered anyway? :)

@LukasTonne, any particular frame number i am to render to see that? What frame you rendered anyway? :)
Member

Frame 26 for example (after rerunning the sim from the start).

Frame 26 for example (after rerunning the sim from the start).
Member

Added subscriber: @LukasStockner

Added subscriber: @LukasStockner
Member

I get the non-finite assert as well, but it happens way less often than in @ThomasDinges's screenshot, so the NaNs I get might actually be unrelated to the bug here.
Anyways, by enabling floating point exceptions (P356), I already found two areas that might cause trouble:

  • intern/cycles/kernel/kernel_volume.h:294 may divide by zero if full_transmittance is one (which I guess is quite common) - mathematically, that makes sense since distance-based sampling is impossible in fully transparent volumes. However, I guess detecting that case and not using MIS in that case would be the more stable solution.
  • intern/cycles/kernel/kernel_volume.h:629 may overflow when ray->t is FLT_MAX and the step size is lower than 1 - generally, the conversion to an integer might overflow here. The more stable approach would be to compare ray->t to global_max_steps*step_size and set max_steps to global_max_steps if it's larger, only doing the divide and cast otherwise.

I can just go ahead and handle these two points, but maybe they're known and actually fine?

I get the non-finite assert as well, but it happens way less often than in @ThomasDinges's screenshot, so the NaNs I get might actually be unrelated to the bug here. Anyways, by enabling floating point exceptions ([P356](https://archive.blender.org/developer/P356.txt)), I already found two areas that might cause trouble: - intern/cycles/kernel/kernel_volume.h:294 may divide by zero if full_transmittance is one (which I guess is quite common) - mathematically, that makes sense since distance-based sampling is impossible in fully transparent volumes. However, I guess detecting that case and not using MIS in that case would be the more stable solution. - intern/cycles/kernel/kernel_volume.h:629 may overflow when ray->t is FLT_MAX and the step size is lower than 1 - generally, the conversion to an integer might overflow here. The more stable approach would be to compare ray->t to global_max_steps*step_size and set max_steps to global_max_steps if it's larger, only doing the divide and cast otherwise. I can just go ahead and handle these two points, but maybe they're known and actually fine?

@LukasStockner, think those two would be safer to address those two points. Please go ahead.

@LukasStockner, think those two would be safer to address those two points. Please go ahead.
Sergey Sharybin removed their assignment 2016-05-10 13:34:29 +02:00
Lukas Stockner was assigned by Sergey Sharybin 2016-05-10 13:34:29 +02:00

Added subscriber: @Sergey

Added subscriber: @Sergey

Lukas, if you still want to look into please go ahead. Otherwise re-assign back to me.

Lukas, if you still want to look into please go ahead. Otherwise re-assign back to me.

This issue was referenced by 654019fa01

This issue was referenced by 654019fa01c858ce49595bb95d189e5e60b7e6cc
Member

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'

This issue was referenced by blender/cycles@6d257d5e30

This issue was referenced by blender/cycles@6d257d5e305d3e56fecd61f3ca359cd23857de0b
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
5 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#48383
No description provided.