Skip to content

Commit

Permalink
Update:
Browse files Browse the repository at this point in the history
- output ply mesh (from opt. vertex pos.)
- optimize vertex normals
- customized clamp values for grid_volume_to_optimizer_pattern
- rework on updating learning rates
- updatable spp (only for custom grid_vol_optimizer)
- update multi sensor bunny scene/images/mesh/vols.
- update grid volume generato
  • Loading branch information
sapo17 committed Apr 5, 2023
1 parent ebebfa0 commit ad4295d
Show file tree
Hide file tree
Showing 55 changed files with 371 additions and 95 deletions.
Binary file modified blender/multi-cam-object-extended.blend
Binary file not shown.
Binary file modified blender/multi-cam-object-extended.blend1
Binary file not shown.
Binary file added images/references/bunny_multi_cam/bunny_s0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/references/bunny_multi_cam/bunny_s1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/references/bunny_multi_cam/bunny_s2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/references/bunny_multi_cam/bunny_s3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/references/bunny_multi_cam/bunny_s4.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/references/bunny_multi_cam/bunny_s5.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/references/bunny_multi_cam/bunny_s6.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/references/bunny_multi_cam/bunny_s7.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,239 @@
<scene version="2.1.0">

<!-- Defaults, these can be set via the command line: -Darg=value -->

<default name="spp" value="4096" />
<default name="integrator" value="path"/>
<default name="rr_depth" value="5"/>
<default name="resx" value="512"/>
<default name="resy" value="512"/>
<default name="max_depth" value="-1"/>
<default name="sample_border" value="true"/>

<!-- Camera and Rendering Parameters -->

<integrator type="$integrator">
<integer name="max_depth" value="$max_depth"/>
</integrator>
<sensor type="perspective">
<string name="fov_axis" value="x"/>
<float name="fov" value="28.841546"/>
<float name="principal_point_offset_x" value="0.000000"/>
<float name="principal_point_offset_y" value="-0.000000"/>
<float name="near_clip" value="0.100000"/>
<float name="far_clip" value="1000.000000"/>
<transform name="to_world">
<rotate x="1" angle="179.999991348578"/>
<rotate y="1" angle="5.008956130975331e-06"/>
<rotate z="1" angle="180.00000500895632"/>
<translate value="0.000000 2.000000 10.000000"/>
</transform>
<sampler type="independent">
<integer name="sample_count" value="$spp"/>
</sampler>
<film type="hdrfilm">
<integer name="width" value="$resx"/>
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>

</film>
</sensor>
<sensor type="perspective">
<string name="fov_axis" value="x"/>
<float name="fov" value="39.597755"/>
<float name="principal_point_offset_x" value="0.000000"/>
<float name="principal_point_offset_y" value="-0.000000"/>
<float name="near_clip" value="0.100000"/>
<float name="far_clip" value="1000.000000"/>
<transform name="to_world">
<rotate x="1" angle="-2.5044780654876655e-06"/>
<rotate y="1" angle="4.785270367996859e-21"/>
<rotate z="1" angle="2.1894845052756264e-13"/>
<translate value="0.000000 2.000000 -10.000000"/>
</transform>
<sampler type="independent">
<integer name="sample_count" value="$spp"/>
</sampler>
<film type="hdrfilm">
<integer name="width" value="$resx"/>
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>

</film>
</sensor>
<sensor type="perspective">
<string name="fov_axis" value="x"/>
<float name="fov" value="39.597755"/>
<float name="principal_point_offset_x" value="0.000000"/>
<float name="principal_point_offset_y" value="-0.000000"/>
<float name="near_clip" value="0.100000"/>
<float name="far_clip" value="1000.000000"/>
<transform name="to_world">
<rotate x="1" angle="360.00001001791264"/>
<rotate y="1" angle="-90.00000250447816"/>
<translate value="10.000000 2.000000 0.000000"/>
</transform>
<sampler type="independent">
<integer name="sample_count" value="$spp"/>
</sampler>
<film type="hdrfilm">
<integer name="width" value="$resx"/>
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>

</film>
</sensor>
<sensor type="perspective">
<string name="fov_axis" value="x"/>
<float name="fov" value="39.597755"/>
<float name="principal_point_offset_x" value="0.000000"/>
<float name="principal_point_offset_y" value="-0.000000"/>
<float name="near_clip" value="0.100000"/>
<float name="far_clip" value="1000.000000"/>
<transform name="to_world">
<rotate x="1" angle="-2.504477861932166e-06"/>
<rotate y="1" angle="90.00000250447816"/>
<translate value="-10.000000 2.000000 0.000000"/>
</transform>
<sampler type="independent">
<integer name="sample_count" value="$spp"/>
</sampler>
<film type="hdrfilm">
<integer name="width" value="$resx"/>
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>

</film>
</sensor>
<sensor type="perspective">
<string name="fov_axis" value="x"/>
<float name="fov" value="39.597755"/>
<float name="principal_point_offset_x" value="0.000000"/>
<float name="principal_point_offset_y" value="-0.000000"/>
<float name="near_clip" value="0.100000"/>
<float name="far_clip" value="1000.000000"/>
<transform name="to_world">
<rotate x="1" angle="179.999991348578"/>
<rotate y="1" angle="45.00000125223908"/>
<rotate z="1" angle="180.00000500895632"/>
<translate value="-7.071068 2.000000 7.071068"/>
</transform>
<sampler type="independent">
<integer name="sample_count" value="$spp"/>
</sampler>
<film type="hdrfilm">
<integer name="width" value="$resx"/>
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>

</film>
</sensor>
<sensor type="perspective">
<string name="fov_axis" value="x"/>
<float name="fov" value="39.597755"/>
<float name="principal_point_offset_x" value="0.000000"/>
<float name="principal_point_offset_y" value="-0.000000"/>
<float name="near_clip" value="0.100000"/>
<float name="far_clip" value="1000.000000"/>
<transform name="to_world">
<rotate x="1" angle="179.999991348578"/>
<rotate y="1" angle="-44.9999978371445"/>
<rotate z="1" angle="180.00000500895632"/>
<translate value="7.071068 2.000000 7.071068"/>
</transform>
<sampler type="independent">
<integer name="sample_count" value="$spp"/>
</sampler>
<film type="hdrfilm">
<integer name="width" value="$resx"/>
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>

</film>
</sensor>
<sensor type="perspective">
<string name="fov_axis" value="x"/>
<float name="fov" value="43.602821"/>
<float name="principal_point_offset_x" value="0.000000"/>
<float name="principal_point_offset_y" value="-0.000000"/>
<float name="near_clip" value="0.100000"/>
<float name="far_clip" value="1000.000000"/>
<transform name="to_world">
<rotate x="1" angle="-2.504478472598665e-06"/>
<rotate y="1" angle="-45.00000125223908"/>
<rotate z="1" angle="2.8649197175398515e-13"/>
<translate value="7.071068 2.000000 -7.071068"/>
</transform>
<sampler type="independent">
<integer name="sample_count" value="$spp"/>
</sampler>
<film type="hdrfilm">
<integer name="width" value="$resx"/>
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>

</film>
</sensor>
<sensor type="perspective">
<string name="fov_axis" value="x"/>
<float name="fov" value="43.602821"/>
<float name="principal_point_offset_x" value="0.000000"/>
<float name="principal_point_offset_y" value="-0.000000"/>
<float name="near_clip" value="0.100000"/>
<float name="far_clip" value="1000.000000"/>
<transform name="to_world">
<rotate x="1" angle="-2.504477861932166e-06"/>
<rotate y="1" angle="45.00000125223908"/>
<rotate z="1" angle="4.885666566289089e-13"/>
<translate value="-7.071068 2.000000 -7.071068"/>
</transform>
<sampler type="independent">
<integer name="sample_count" value="$spp"/>
</sampler>
<film type="hdrfilm">
<integer name="width" value="$resx"/>
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>

</film>
</sensor>

<!-- Materials -->

<bsdf type="twosided" id="mat-PlaneBsdf">
<bsdf type="diffuse">
<ref name="reflectance" id="texture-checkerboard" />
</bsdf>
</bsdf>
<bsdf type="principled" id="mat-ObjectBsdf">
<rgb name="base_color" value="0.01, 0.01, 0.01"/>
<float name="roughness" value="0.5"/>
<float name="spec_trans" value="0.02"/>
<float name="eta" value="1.54"/>
</bsdf>
<texture type="checkerboard" id="texture-checkerboard">
<rgb name="color0" value="0.4" />
<rgb name="color1" value="0.2" />
<transform name="to_uv">
<scale x="8.000000" y="8.000000" />
</transform>
</texture>

<!-- Emitters -->
<emitter type="envmap" id="emitter-envmap">
<string name="filename" value="scenes\material-preview\textures\envmap.exr" />
</emitter>

<!-- Shapes -->

<shape type="ply">
<string name="filename" value="meshes/Plane.ply"/>
<boolean name="face_normals" value="true"/>
<ref id="mat-PlaneBsdf" name="bsdf"/>
</shape>
<shape type="ply" id="bunny-rec">
<string name="filename" value="meshes/bunny_rec_446.ply"/>
<boolean name="face_normals" value="true"/>
<ref id="mat-ObjectBsdf" name="bsdf"/>
</shape>
</scene>
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>
<rfilter type="gaussian">
<float name="stddev" value="3"/>
<float name="stddev" value="1"/>
</rfilter>
</film>
</sensor>
Expand All @@ -61,7 +61,7 @@
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>
<rfilter type="gaussian">
<float name="stddev" value="3"/>
<float name="stddev" value="1"/>
</rfilter>
</film>
</sensor>
Expand All @@ -85,7 +85,7 @@
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>
<rfilter type="gaussian">
<float name="stddev" value="3"/>
<float name="stddev" value="1"/>
</rfilter>
</film>
</sensor>
Expand All @@ -109,7 +109,7 @@
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>
<rfilter type="gaussian">
<float name="stddev" value="3"/>
<float name="stddev" value="1"/>
</rfilter>
</film>
</sensor>
Expand All @@ -134,7 +134,7 @@
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>
<rfilter type="gaussian">
<float name="stddev" value="3"/>
<float name="stddev" value="1"/>
</rfilter>
</film>
</sensor>
Expand All @@ -158,6 +158,9 @@
<integer name="width" value="$resx"/>
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>
<rfilter type="gaussian">
<float name="stddev" value="1"/>
</rfilter>
</film>
</sensor>
<sensor type="perspective">
Expand All @@ -181,7 +184,7 @@
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>
<rfilter type="gaussian">
<float name="stddev" value="3"/>
<float name="stddev" value="1"/>
</rfilter>
</film>
</sensor>
Expand All @@ -206,7 +209,7 @@
<integer name="height" value="$resy"/>
<boolean name="sample_border" value="$sample_border"/>
<rfilter type="gaussian">
<float name="stddev" value="3"/>
<float name="stddev" value="1"/>
</rfilter>
</film>
</sensor>
Expand All @@ -219,9 +222,7 @@
</bsdf>
</bsdf>
<bsdf type="principled" id="mat-ObjectBsdf">
<texture name="base_color" type="bitmap">
<string name="filename" value="scenes\material-preview\textures\init-texture-720x480.png"/>
</texture>
<rgb name="base_color" value="0.1, 0.1, 0.1"/>
<float name="roughness" value="0.7"/>
<float name="spec_trans" value="0.1"/>
<float name="eta" value="1.64"/>
Expand All @@ -247,7 +248,7 @@
<ref id="mat-PlaneBsdf" name="bsdf"/>
</shape>
<shape type="ply" id="bunny-rec">
<string name="filename" value="meshes/bunny_rec_2.ply"/>
<string name="filename" value="meshes/bunny_rec_128.ply"/>
<ref id="mat-ObjectBsdf" name="bsdf"/>
</shape>
</scene>
6 changes: 3 additions & 3 deletions scripts/grid_volume_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

mi.set_variant("cuda_ad_rgb")

grid_res = 256
grid_res = 4

mi.VolumeGrid(
dr.full(mi.TensorXf, 1, (grid_res, grid_res, grid_res, 1))
).write("full_volume.vol")
dr.full(mi.TensorXf, 0.002, (grid_res, grid_res, grid_res, 1))
).write("empty.vol")
Loading

0 comments on commit ad4295d

Please sign in to comment.