This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Object tracking annotations are returned as a objectAnnotations list. | |
| { | |
| "name": "projects/PROJECT_NUMBER/locations/LOCATION_ID/operations/OPERATION_ID", | |
| "metadata": { | |
| "@type": "type.googleapis.com/google.cloud.videointelligence.v1.AnnotateVideoProgress", | |
| "annotationProgress": [ | |
| { | |
| "inputUri": "/cloud-ml-sandbox/video/chicago.mp4", | |
| "progressPercent": 100, | |
| "startTime": "2019-12-21T16:56:46.755199Z", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # this is where call session is started from but the parameter hash does | |
| # contain the required key / values | |
| def startCallSession(data) | |
| @current_call.callSessionId = data['sessionId'] | |
| updateCallStatus('call started') | |
| callScreen = InCallScreen.new(nav_bar: false, modal: true) | |
| callScreen.connectWith(data['sessionId'], andToken: data['token']) | |
| callScreen.client_time_available = data['fromSecondsAvailable'] | |
| App.delegate.presentModal(callScreen) | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # this goes into config/initializers/fog.rb | |
| CONN = Fog::Storage.new({ | |
| :provider => 'AWS', | |
| :aws_access_key_id => 'ACCESS_KEY', | |
| :aws_secret_access_key => 'SECRET_KEY_HERE' | |
| }) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class CategoriesController < ApplicationController | |
| respond_to :html, :json | |
| before_filter :find, :only => [:edit, :update, :destroy] | |
| def index | |
| parent = load_node_from_params | |
| @nodes = parent.descendants.categories.sort | |
| respond_with @nodes.to_a, :api_template => :basic | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class DevicesController < ApplicationController | |
| before_filter :authenticate_user! | |
| def create | |
| @device = current_user.app.devices.new(registration_id: params[:registration_id]) | |
| if params[:platform] && params[:platform].upcase == 'IOS' | |
| @device.os = :ios | |
| end | |
| if @device.save |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo gem install rails |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo apt-get install sqlite3 libsqlite3-dev | |
| sudo gem install sqlite3-ruby |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| cd ~ | |
| mkdir gems | |
| cd gems | |
| wget http://production.cf.rubygems.org/rubygems/rubygems-1.5.1.tgz | |
| tar -xf rubygems-1.5.1.tgz | |
| cd rubygems-1.5.1 | |
| sudo ruby setup.rb | |
| sudo ln -s /usr/bin/gem1.8 /usr/bin/gem |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo apt-get install ruby ri rdoc irb ruby-dev libruby libreadline-ruby libopenssl-ruby mysql-client mysql-server libmysql-ruby libmysqlclient-dev |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo apt-get install build-essential |
NewerOlder