Skip to content

Instantly share code, notes, and snippets.

Chris Turchin turchinc

Block or report user

Report or block turchinc

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@turchinc
turchinc / NexStar Named Star List.xml
Created Nov 18, 2018
list of named stars in the NexStar handset in the APT import format
View NexStar Named Star List.xml
<?xml version="1.0"?>
<Objects>
<Obj>
<Object>Acamar</Object>
<NameNotes>NexStar Named Star List</NameNotes>
<Type>S</Type>
<Const>Eri</Const>
<Mag>3.2</Mag>
<Size></Size>
<RA>02:58:16.0</RA>
@turchinc
turchinc / test-debayer-fits.py
Created Oct 22, 2018
test various debayer patterns on images from DSV-IV camera (COLOR_BayerGB2BGR and COLOR_BayerGR2RGB worked for me)
View test-debayer-fits.py
# https://docs.opencv.org/3.1.0/d7/d1b/group__imgproc__misc.html#gga4e0972be5de079fed4e3a10e24ef5ef0a353a4b8db9040165db4dacb5bcefb6ea
import cv2
# http://docs.astropy.org/en/v0.2.3/io/fits/index.html
from astropy.io import fits
image_file = 'c:/temp/tree-nocolortype.fit'
image_data = fits.getdata(image_file, ext=0)
cv2.imwrite('c:/temp/COLOR_BayerGB2BGR.png', cv2.cvtColor(image_data, cv2.COLOR_BayerGB2BGR ))
cv2.imwrite('c:/temp/COLOR_BayerBG2BGR.png', cv2.cvtColor(image_data, cv2.COLOR_BayerBG2BGR ))
@turchinc
turchinc / LangInFrames.vbs
Created Mar 24, 2014
VBA macro to change the language of all text frames on slides in a PowerPoint presentation.
View LangInFrames.vbs
Sub LangInFrames()
scount = ActivePresentation.Slides.Count
For j = 1 To scount
fcount = ActivePresentation.Slides(j).Shapes.Count
For k = 1 To fcount
If ActivePresentation.Slides(j).Shapes(k).HasTextFrame Then
ActivePresentation.Slides(j).Shapes(k).TextFrame.TextRange _
.LanguageID = msoLanguageIDEnglishUK
End If
Next k
You can’t perform that action at this time.