Skip to content

Instantly share code, notes, and snippets.

@thewtex
thewtex / Dockerfile
Created August 25, 2015 22:02
Jupyter Notebook start with Docker CMD -- Python kernel crashes
FROM jupyter/notebook:latest
EXPOSE 8889
CMD ["jupyter", "notebook", "--port=8889", "--no-browser", "--ip=*"]
@thewtex
thewtex / Dockerfile
Created August 25, 2015 22:12
Jupyter Notebook start with Docker CMD
FROM jupyter/notebook:latest
EXPOSE 8889
CMD ["sh", "-c", "jupyter notebook --port=8889 --no-browser --ip=*"]
@thewtex
thewtex / AffineTtransformParameterOrder.cxx
Created January 30, 2014 16:15
Affine Transform Parameter Order
#include "itkAffineTransform.h"
#include "itkTransformFileWriter.h"
int main( int argc, char * argv[] )
{
if( argc < 2 )
{
std::cerr << "Usage: "
<< argv[0]
<< " outputTransform"
cmake \
-DITK_BUILD_DEFAULT_MODULES:BOOL=OFF \
-DBUILD_TESTING:BOOL=OFF \
-DBUILD_EXAMPLES:BOOL=OFF \
-DITKGroup_Core:BOOL=OFF \
-DModule_ITKCommon:BOOL=ON \
-DCMAKE_SIZEOF_UNSIGNED_SHORT=2   \
-DCMAKE_TOOLCHAIN_FILE=/home/ibanez/src/emscripten/cmake/Platform/Emscripten.cmake -DCMAKE_BUILD_TYPE=Debug -G "Unix Makefiles"  ~/src/ITK
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