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
#!/bin/bash | |
for i in *.avi | |
do | |
mplayer `echo $i` -vo gif89a:fps=15:output=`echo $i | sed 's/.avi/.gif/g'` | |
echo $i "succeed" | |
done |
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
<html> | |
<head> | |
<title>檢查證明書</title> | |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> | |
</head> | |
<body> | |
<table style="border: 5px double rgb(0,0,0)"> | |
<tr> |
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
Persantin and side effect | |
======================================================== | |
author: mcdlee | |
date: 2013-12 | |
Background of patients | |
======================================================== | |
```{r echo=FALSE} | |
library(ggplot2) | |
library(knitr) |
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
Demo in NUK (2013-12-12) | |
======================================================== | |
```{r} | |
data <- read.csv("fake.csv") | |
data | |
attach(data) | |
``` |
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
import dicom | |
import pylab | |
ds = dicom.read_file("img.dcm") # read a dicom of pre-reconstructed SPECT | |
array = ds.pixel_array | |
y30 = array[:,30,:] | |
pylab.imshow(y30) |
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
import dicom | |
from skimage.transform import iradon | |
import pylab | |
import numpy | |
ds = dicom.read_file("img.dcm") # read a dicom of pre-reconstructed SPECT | |
array = ds.pixel_array | |
y36 = numpy.transpose(array[:,36,:]) #important!! |
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
import dicom | |
from skimage.transform import iradon, iradon_sart | |
import pylab | |
import numpy | |
ds = dicom.read_file("img.dcm") # read a dicom of pre-reconstructed SPECT | |
array = ds.pixel_array | |
recon_3d = numpy.zeros((64,64,64)) |
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
import dicom | |
from skimage.transform import iradon, iradon_sart | |
import numpy | |
import pylab | |
# readind data | |
ds = dicom.read_file("img.dcm") # read a dicom of pre-reconstructed SPECT | |
pixel_size= ds.PixelSpacing[1]/10 # read pixel size from header of dicom | |
print("Pixel size =", pixel_size, "cm") | |
pixel_volume= pixel_size**3 |
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
import dicom | |
import os | |
import numpy | |
import pylab | |
# readind data | |
ds = dicom.read_file("DICOMDIR") # read a dicomdir of PET/CT | |
# collect pixel_volume and resolution |
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
# -*- coding: utf-8 -*- | |
""" | |
Created on Sun Jan 26 15:46:19 2014 | |
@author: mcdlee | |
""" | |
from lxml import etree | |
import urllib2 | |
import unicodedata |
OlderNewer