TensorFlow Tutorial Step 1: Set Up for THETA V

Craig Oda
Craig Oda
Nov 6, 2018 · 2 min read

First steps in modifying Tensorflow code to work inside the THETA V

Code for Makoto Shohara’s workshop is available on GitHub.

This is Step 1 of the workflow described in How to Build Tensorflow apps for RICOH THETA.

Note: if you want to run TensorFlow in the THETA first prior to working on the code, read Running Tensorflow on RICOH THETA V

Starting code (tag): WS_START_STEP1

Tags for Tutorial

Overview

  • We’re going to start at the point the “PPP” error sound stops when you first start the plug-in
  • Use the Camera API to modify the behavior

Fixing “PPP” Error Sound

  • Build the sample code and run it on the THETA V
  • The plug-in on the camera will stop with a “PPP” sound.
  • Use Vysor to set the permissions of the plug-in.
  • If the camera still stops with a “PPP” error sound, follow the comments in the code “Step 1” to end the error without opening the camera resource

Using Camera API

notificationCameraClose()

sendBroadcast(new Intent(“com.theta360.plugin.ACTION_MAIN_CAMERA_CLOSE”)

free the camera resources that is being used by the main camera application

The camera resource can only open one application

Camera Parameter Settings

parameters.set(“RIC_SHOOTING_MODE”, “RicMoviePreview1024”);

Set to camera operation mode. The default is RicStillCaptureStd

Depending on your requirements, you can change RIC_PROC_STITCHING settings as follows:

  • Static stitching (high speed): “RicStaticStitching”
  • Dynamic stitching (high precision): “RicDynamicStitchingAuto”
  • No stitching (Fish-eye): “RicNonStitching”

Using the Microphone

AudioManager am = (AudioManager) getSystemService(Context.AUDIO_SERVICE);

In order to do real time processing, you should use single channel mono audio.

When you use Ambisonic B-format (4-channel) audio, it will be recorded as a WAV file.

Next Step

TensorFlow Tutorial Step 2: Incorporating PluginLibrary

Related Articles

theta360.guide

Developer information for augmented reality, virtual…

Craig Oda

Written by

Craig Oda

open source advocate, writer, Python and JavaScript developer, father, husband, fly fisherman, surfer

theta360.guide

Developer information for augmented reality, virtual reality, 360 media, and the RICOH THETA camera

More From Medium

Also tagged TensorFlow

Top on Medium

Top on Medium

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade