This file contains 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
#!/usr/bin/env python | |
from __future__ import print_function | |
#import ros packages | |
import roslib; roslib.load_manifest('carlaros_client') | |
import rospy | |
from sensor_msgs.msg import Joy | |
#self define ros msgs | |
from carla_msgs.msg import CarOdom |
This file contains 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
var accessLogs = sc.textFile("/data/spark/project/access/access.log.45.gz") | |
//Check whats in the RDD. Each record of accessLogs RDDs should be the line //from the files in folder | |
accessLogs.take(10) | |
//Keep only the lines which have IP | |
def containsIP(line:String):Boolean = return line matches "^([0-9\\.]+) .*$" | |
var ipaccesslogs = accessLogs.filter(containsIP) | |
//Extract only IP |
This file contains 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
from keras.models import Sequential | |
from keras.models import model_from_json | |
from keras import backend as K | |
import tensorflow as tf | |
from tensorflow.python.tools import freeze_graph | |
import os | |
# Load existing model. | |
with open("model.json",'r') as f: | |
modelJSON = f.read() |