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
// VLP16.h | |
// Grabber Instance | |
boost::shared_ptr<pcl::VLPGrabber> mVlpGrabber; | |
// Connection instance for open and close | |
boost::signals2::connection mConnection; | |
// Save point cloud data into this pointer | |
pcl::PointCloud<PointType>::ConstPtr mCloud; | |
// Mutex | |
boost::mutex mVLPMutex; |
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
void PCLManager::edgeRmoveFilter(pcl::PointCloud<PointType>::Ptr cloud) { | |
pcl::PointCloud<PointNormalType>::Ptr normal = createNormals(cloud); | |
vector<int> removeIndex; | |
for (int i = 0; i < cloud->points.size(); i++) | |
{ | |
if (abs(normal->points[i].normal_x / normal->points[i].normal_z) > 0.1) | |
{ | |
removeIndex.push_back(i); | |
} |
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
// Copy for compute | |
pcl::PointCloud<PointType>::Ptr calcPoints(new pcl::PointCloud<PointType>()); | |
*calcPoints = *mCloud; | |
// Filter | |
float voxelVal = 0.01f; // Set Voxel size to 0.01m | |
voxelGridFilter(voxelVal, calcPoints); | |
statisticalOutlierFilter(calcPoints); | |
passThroughFilter(calcPoints, "x", -2.0, 2.0); //-2.0m to 2.0m | |
passThroughFilter(calcPoints, "y", 0.0, 2.0); //0.0m to 2.0m |
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
// Global or Class member | |
pcl::visualization::CloudViewer mVlpViewer("VLP"); | |
// at loop routine called every frame. | |
vlpViewer.showCloud(calcPoints); |
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
#pragma once | |
enum Edit_Mode { | |
Edit_Mode_None = 0, | |
Edit_Mode_X, | |
Edit_Mode_Y, | |
Edit_Mode_Z, | |
Edit_Mode_Pitch, | |
Edit_Mode_Yaw, |
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
#include "stdafx.h" | |
#include "Sensor.h" | |
#include "VisualizerManager.h" | |
using namespace std; | |
VisualizerManager::VisualizerManager() | |
{ | |
showCloud.reset(new pcl::PointCloud<PointType>()); | |
viewer.reset(new pcl::visualization::PCLVisualizer("VLP16 Viewer")); |
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
#include "VisualizerManager.h" | |
// Instance | |
VisualizerManager visualizer; | |
// Within looping routine | |
visualizer.updateVisualizer(calcPoints); |
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 PIL import Image, ImageDraw, ImageFilter | |
from pathlib import Path | |
import random | |
def getImage(path): | |
img = resizeImage(Image.open(path)) | |
return img | |
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
python create_tfrecord.py \ | |
--dataset_dir "/home/user_name/dataset" \ | |
--tfrecord_filename=mymodel \ | |
--validation_size=0.2 |
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
find . -name '.DS_Store' -type f -ls -delete |
OlderNewer