Skip to content

Instantly share code, notes, and snippets.

### Keybase proof
I hereby claim:
* I am dbgeek on github.
* I am ba78 (https://keybase.io/ba78) on keybase.
* I have a public key ASD1iieryV-t81s7VHXZ14zW7ATbxUkddFrGymnmYwVzPwo
To claim this, I am signing this object:
@dbgeek
dbgeek / asg_eventbus_stack.ts
Created November 16, 2019 12:08
aws cdk - asg eventbus lambda
import cdk = require('@aws-cdk/core');
import autoscaling = require('@aws-cdk/aws-autoscaling');
import ec2 = require('@aws-cdk/aws-ec2');
import eventBus = require('@aws-cdk/aws-events')
import lambda = require('@aws-cdk/aws-lambda')
import lambdTarget = require('@aws-cdk/aws-events-targets')
export class AsgEventbusStack extends cdk.Stack {
constructor(scope: cdk.Construct, id: string, props?: cdk.StackProps) {
super(scope, id, props);
def reward_function(params):
'''
Example of rewarding the agent to follow center line
'''
# Calculate 3 marks that are farther and father away from the center line
marker_1 = 0.1 * params['track_width']
marker_2 = 0.25 * params['track_width']
marker_3 = 0.5 * params['track_width']
speed = params['speed']
def reward_function(params):
'''
Example of rewarding the agent to follow center line
'''
# Calculate 3 marks that are farther and father away from the center line
marker_1 = 0.1 * params['track_width']
marker_2 = 0.25 * params['track_width']
marker_3 = 0.5 * params['track_width']
speed = params['speed']
@dbgeek
dbgeek / gist:59ad81e941afb416faf83698d03676fd
Created January 31, 2019 09:38
sample - prefetch_lob_size
package main
import (
"context"
"database/sql"
"fmt"
"log"
"os"
"time"
@dbgeek
dbgeek / prefetch_rows_clobs.go
Last active January 21, 2019 10:21
go-oci8 test case that show it doing fetch for each row if query as a clob in the query
/*
All these OS environment variables to specify how to connect.
* DB_USERNAME
* DB_PASSWORD
* DB_PORT
* DB_HOSTNAME
* DB_SERVICENAME
* DB_PREFETCHMEMORY
* DB_PREFETCHROWS
DB Privileges need
@dbgeek
dbgeek / prefetch_rows.go
Last active January 10, 2019 23:47
go-oci8 make fetch for each row
/*
All these OS environment variables to specify how to connect.
* DB_USERNAME
* DB_PASSWORD
* DB_PORT
* DB_HOSTNAME
* DB_SERVICENAME
* DB_PREFETCHMEMORY
* DB_PREFETCHROWS
DB Privileges need