Git Product home page Git Product logo

realisticluminanceinvr's Introduction

This repository contains our Matlab demo code converting RGB pixel data to luminance, following the steps in our paper:

Realistic Luminance in VR Nathan Matsuda*, Alexandre Chapiro*, Yang Zhao, Clinton Smith, Romain Bachy, Douglas Lanman Meta, USA Conference track of SIGGRAPH Asia 2022

The code generates the plots in the paper, and can be easily modified to use a different camera or observer type. If you use this code in your research, please cite our paper above.

Installation

First, save the following to the "data" directory:

Then, download the Southampton-York Natural Scenes dataset to the from its authors' website before running the SYNS_RGB_to_luminance demo: https://syns.soton.ac.uk/browse

The scenes used in our work were the following:

9 indoor scenes:

  • Indoor Lecture Hall #81
  • Indoor Office #82
  • Indoor Classroom #83
  • Indoor Office #85
  • Indoor Living Room #86
  • Indoor Foyer #88
  • Indoor Lecture Hall #89
  • Indoor Cafe #90
  • Indoor Living Room #92

10 outdoor scenes:

  • Outdoor Urban #1
  • Outdoor Suburban #2
  • Outdoor Retail #3
  • Outdoor Forest #4
  • Outdoor Wetlands #5
  • Outdoor Forest #6
  • Outdoor Forest #26
  • Outdoor Glass Houses #31
  • Outdoor Beach #37
  • Outdoor Forest #71

The folder structure is set up as in the examples below for indoor scene #81. The top path is for the .hdr image containing the image capture we will use to extract the luminance information. The second path is for the metadata file that has the camera exposure, ISO, and f values we need to compute luminance. SYNSData -> indoor -> SYNS_scene_81_indoor_Lecturehall -> SYNSData -> 81 -> rep1.hdr SYNSData -> indoor -> SYNS_scene_81_indoor_Lecturehall -> SYNSData -> 81 -> I_25_81.txt

The same is repeated for e.g. outdoor scene #1: SYNSData -> outdoor -> SYNS_scene_1_outdoor_Urban -> SYNSData -> 1 -> rep1.hdr SYNSData -> outdoor -> SYNS_scene_1_outdoor_Urban -> SYNSData -> 1 -> O_1_14.txt

Usage

There are 3 top-level Matlab scripts used to generate the plots in our paper:

  • "spectral_demo.m" uses the camera's spectral response function and standard observer CMFs to generate an RGB to XYZ matrix using MIM/MIMP. It generates the plots in Figures 2 and 3 of the paper.
  • "SpheronCharacterization2022_luminancePrediction.m" uses the ground truth luminance data collected by us in the lab (Fig. 4) and the EV formula to convert XYZ Y values obtained the using matrix T from the previous demo into luminance in nits. This code generates the plot in Figure 5 of the paper.
  • "SYNS_RGB_to_luminance.m" converts the 360 immersive images from the SYNS dataset into luminance values. Before running this code, please download the SYNS dataset following the instructions in the SYNSData folder.

Contact

Please feel free to reach out to Alex Chapiro ([email protected]) and Nathan Matsuda ([email protected]) with any questions or comments, we love hearing about folk using our code!

LICENSE

Shield: CC BY-NC-SA 4.0

This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

CC BY-NC-SA 4.0

realisticluminanceinvr's People

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.