Skip to content

Instantly share code, notes, and snippets.

cmake_minimum_required( VERSION 2.8 )
project( Registration )
find_package( ITK REQUIRED )
include( ${ITK_USE_FILE} )
include_directories( ${CMAKE_CURRENT_SOURCE_DIR} )
add_executable( ${PROJECT_NAME} main.cpp )
#ifndef _Registration_hpp
#define _Registration_hpp
#include <iostream>
//#include "Types.hpp"
#include <itkImageRegistrationMethod.h>
#include <itkTranslationTransform.h>
#include <itkMeanSquaresImageToImageMetric.h>
#include <itkLinearInterpolateImageFunction.h>
@thewtex
thewtex / pydas-upload.py
Created February 26, 2014 18:41
A script to upload a folder recursively to Midas.
#!/usr/bin/env python
description = """
Upload binary data to Midas.
"""
import argparse
import hashlib
import os
import sys
@thewtex
thewtex / PlusLib svn diff
Created May 7, 2014 03:55
Plus IntersonSDKCxx
Index: src/DataCollection/CMakeLists.txt
===================================================================
--- src/DataCollection/CMakeLists.txt (revision 3305)
+++ src/DataCollection/CMakeLists.txt (working copy)
@@ -15,6 +15,7 @@
OPTION (PLUS_USE_VFW_VIDEO "Provide support for the Video-for-Windows video digitizer" OFF)
OPTION (PLUS_USE_EPIPHAN "Provide support for the Epiphan" OFF)
OPTION (PLUS_USE_INTERSON_VIDEO "Provide support Interson USB ultrasound probes" OFF)
+OPTION (PLUS_USE_INTERSONSDKCXX_VIDEO "Provide support Interson SDK 1.X with C++ Wrapper USB ultrasound probes" OFF)
OPTION(PLUS_USE_STEALTHLINK "Provide support for the Medtronick StealthLink Server" OFF)
@thewtex
thewtex / atom2rss.xsl
Last active August 29, 2015 14:01
RSS Feed Generator for the JIRA Issue Tracker
<?xml version="1.0" encoding="UTF-8" ?>
<!-- Released under CC lincense http://creativecommons.org/licenses/by/2.5/ -->
<!-- Feeds generated using this stylesheet (or it's derivatives) must put http://atom.geekhood.net in <generator> element -->
<x:stylesheet version="1.0"
exclude-result-prefixes="atom xhtml php"
xmlns:php="http://php.net/xsl"
xmlns:x="http://www.w3.org/1999/XSL/Transform"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:xhtml="http://www.w3.org/1999/xhtml">
@thewtex
thewtex / itk-gitinspector.sh
Last active August 29, 2015 14:01
Script that generates the output for http://itk.org/ITK/project/parti.html
#!/bin/sh
cd ~/src/ITKInspector
git checkout master
git pull
~/bin/gitinspector-venv/bin/gitinspector -HTlr --format=html --exclude=itkVersion.h --exclude=Modules/ThirdParty/ > /tmp/inspector.html
scp /tmp/inspector.html public:/projects/Insight/WWW/InsightWeb/files/ITK-gitinspector.html
@thewtex
thewtex / itkvs09.azure.ctest
Last active August 29, 2015 14:01
itkvs09.azure.ctest
# These variables define the system and should be set
# In the future CTest might be able to determine this automatically
set(CDASH_SITENAME "itkvs09.azure")
set(CDASH_SYSTEMNAME "Windows")
get_filename_component(_thisdir "${CMAKE_CURRENT_LIST_FILE}" PATH)
set(CDASH_SITE_CONFIG_FILE "${_thisdir}/itkvs09.azure.xml")
set(CDASH_TEMP_DIRECTORY "${_thisdir}/workspace/tmp")
set(CTEST_EXECUTABLE "C:/Program Files (x86)/CMake 2.8/bin/ctest")
set(CTEST_DROP_SITE "open.cdash.org")
set(CTEST_DROP_URL "/submit.php")
@thewtex
thewtex / itkvs09.azure.xml
Created May 21, 2014 03:36
itkvs09.azure.xml
<?xml "1.0" encoding="UTF-8"?>
<cdash>
<system>
<platform>Windows</platform>
<version>Unknown</version>
<bits>64</bits>
<basedirectory>C:/Dashboards/cdashclient_workspace/</basedirectory>
</system>
<compiler>
<name>cl</name>
@thewtex
thewtex / Dockerfile
Last active August 29, 2015 14:03
TubeTK Dockerfile - replicates Eternia dashboard build
FROM ubuntu:13.04
MAINTAINER Matt McCormick <matt.mccormick@kitware.com>
# Update
RUN apt-get update
# Build tools
RUN apt-get install -y build-essential
RUN apt-get install -y cmake-curses-gui
RUN apt-get install -y git
@thewtex
thewtex / create-blank-image.py
Created August 28, 2014 18:38
Create a blank SimpleITK image with specified image information.
#!/usr/bin/env python
import sys
import SimpleITK as sitk
if len(sys.argv) < 5:
print('Usage: ' + sys.argv[0] + ' size0,size1,size2 spacing0,spacing1,spacing2 origin0,origin1,origin2 OutputImage')
sys.exit(1)
size = [int(ss) for ss in sys.argv[1].split(',')]