Connecting Microsoft Kinect To Mac

For the second part of my thesis, after messing around with various background subtraction algorithms in in openCV, I thought about what else I could do to add some value to this open ended research. I managed to get my hands on a Microsoft Kinect Camera which incorporated a normal camera and an infra-red camera.

The first issue I had, the Microsoft Kinect Camera I got wasn’t the developer version and it had a proprietary connector which doesn’t connect straight to a usb port. Good thing in this modern age is finding cheap adapters off ebay, but cheap sometimes also means waiting a while before I got the adapter and sometimes they don’t work… Fortunately, it wasn’t a complete waste as I needed part of the cable and following this guide I managed to make my own complete adapter.

The second issue was that I was trying to use the Kinect camera in MacOS with Python so it wasn’t natively supported as it would under Windows, but fortunately, the Libfreenect library¬†provided drivers and wrappers to use make the Kinect work. Simply downloading the directory and navigating to the python folder in the wrappers folder and installing the files with

python setup.py install

To ensure that it is installed,

pip list

If libfreenect is listed then it is installed.

Mounting NTFS Drives on Mac for Free

I had trouble writing to ntfs drives since upgrading to Sierra. In order to write to it:

  • get the name of the drive(replacing all spaces with “\040”)
  • open terminal and enter sudo nano /etc/fstab
  • copy LABEL=disk none ntfs rw,auto,nobrowse (replace disk with name of hard drive)
  • ctrl+o to save,enter,ctrl+x to exit
  • unmount and mount drive and you should not be able to see it in your finder
  • but navigate to \Volumes via the finder options Go->Go to folder… will let you see the drive.

MacOS Useful Tips

  • Remove the “All My Files” tab from the sidebar in finder to prevent accidentally manipulating all your files.
  • Turning on “Reduce Transparency” in Settings-> Accessibility saves a bit of cpu usage.
  • Using “Scaled Effect” instead of “Genie Effect” in Settings->Dock saves a bit of cpu usage.
  • Unticking “Correct spelling automatically” and “Capitalise words Automatically” in Settings->Keyboard->Text makes it easier to touch type.
  • Selecting “App Store and identified developers” in Settings->Security&Privacy->General allows you to install apps outside of app store
  • Turning off FileVault in Settings->Security&Privacy apparently causes less problems for your Mac in the future.
  • Adding your Mac startup disk to Settings->Spotlight->Privacy saves your Mac from overheating when trying to index all your newly added files.
  • Entering¬†defaults write com.apple.dock scroll-to-open -bool TRUE; killall Dock into terminal allows you to scroll on dock icons to see open windows

Resetting Up My Macbook

I accidentally installed wireshark-chmodbpf and can’t uninstall it. Also needed to clean up my macbook pro and what better way is there to do it then completely reinstalling MacOS. Here is my attempt to make it as easy as possible for myself.

Step 1: Make a backup of all my important files.

Step 2: Make a list of all my installed apps. Get script here!

Step 3: Press Command-R To delete current startup drive and then reinstall MacOS.

Step 4: Set up Mac and go through all settings.

Step 5: Reinstall apps from App Store.

Step 6: Install Homebrew with

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

and tap into brew cask with

brew cask tap

Step 7: Reinstall apps through brew cask.

 

Posted in Mac

Free Useful Mac Apps

From the App Store:

  • Duplicate Photo Finder: finds duplicate photos in the Photo App and moves them to a delete folder.
  • The Duplicate Finder: simple drag and drop folders or entire hard drive devices to find duplicate files to delete.
  • Taurine:lets you keep your macbook on for a set period without having to change energy saving settings.
  • Memory Cleaner:allows you to monitor RAM usage and free memory when desired.
  • Decompressor: simple app for extracting files from common archive files.
  • Battery Monitor:allows you to monitor Battery usage and wear and tear.

From Brew:

  • smcFanControl: allows you to control your macbook fanspeed and monitor cpu temperatures.
  • Spectacle:allows you to manipulate window size and location through customisable shortcuts.
  • DisableMonitor:allows you to completely turn off your macbook display and gives more resolution levels.
  • HyperDock:imitates Windows ability to display open windows when hovering mouse over docked app.
  • HyperSwitch:imitates Windows ability to switch between apps and windows.
  • VLC: very versatile video and audio player.

Setting up OpenCV3 with Python on MacOS

OpenCV is an open source library with many useful functions for manipulating images and arrays. For my thesis, I had to research of Background Subtraction techniques, a category within Computer vision which forms the basis for detecting objects in video streams. In order to complete my research, I had to test the performance and complexity of various Background Subtraction techniques. My initial attempts involved using MATLAB to complete my research, but after learning about this useful API, I decided to test it out but it would have been way too time consuming to set OpenCV with more traditional programming languages like C so I decided to test it out with python… Continue reading “Setting up OpenCV3 with Python on MacOS”