November 27, 2019

[NOTE] Win10 - get the full message for "Unauthorized changes blocked"

Event Viewer > Application and Services > Microsoft > Windows > Windows Defender > Operational

Get the full message using PowerShell:

> Get-WinEvent -FilterHashtable @{logname=’Microsoft-Windows-Windows Defender/Operational’; id=1123} | Select-Object Message

November 9, 2019

[Quantum Computer] Getting Started: QISKit SDK

Qiskit is developed by IBM.
https://qiskit.org/

This note is to show how to install Qiskit on Win10, run the simulator locally.

Installation note
https://developer.ibm.com/code/2017/05/17/developers-guide-to-quantum-qiskit-sdk/
https://qiskit.org/documentation/install.html

Requirements:

  • Windows
  •  Anaconda

Create environment

> conda create --name qiskit python=3
> activate qiskit
> pip install -U pip


Install dependent packages

> conda install blas
> conda install mkl
> conda install scipy


Install Qiskit

> pip uninstall qiskit
> pip install qiskit
> pip install qiskit-terra[visualization]



Unlike QDK, Qiskit is Python, which is a big plus -- no need to learn new language.

November 8, 2019

[Quantum Computer] Getting Started: QDK

This is just a note on installing QDK, Python, Jupyter on Windows.

QDK is Microsoft Quantum Development Kit.
https://www.microsoft.com/en-us/quantum/development-kit

Installation steps are here, https://docs.microsoft.com/en-us/quantum/install-guide/

But I had some minor trouble installing it, so this is the note.

Requirements:
  • Win10
  • Anaconda

[1] Install .NET package, 2.2.0


First, check if you have DOT NET package installed.  Do where dotnet and see if dotnet command is available.

If not, go to this site and install 2.2.  It's Important that current QDK requires 2.2.x version.
https://dotnet.microsoft.com/download/dotnet-core

Check if you have the right version:

> dotnet --list-sdks
2.2.402 [C:\Program Files\dotnet\sdk]
3.0.100 [C:\Program Files\dotnet\sdk]

As shown above, I have 2.2.402 installed.

Now install .NET tools:

> dotnet tool install -g Microsoft.Quantum.IQSharp
> dotnet iqsharp install

[2] Anaconda + Python + Jupyter

Run Anaconda and create environment, 'qsharp':

> conda create --name qsharp
> conda activate qsharp

Create workspace directory

> cd /d e:\dev\code\
> mkdir qsharp
> cd qhsharp

And install jupyter and qsharp

> conda install jupyter
> pip install qsharp
> conda install ipykernel

Check if qsharp kernel is installed:

> jupyter kernelspec list
Available kernels:
  python3    C:\opt\Anaconda3\envs\qsharp\share\jupyter\kernels\python3
  iqsharp    C:\ProgramData\jupyter\kernels\iqsharp


Run jupyter notebook:

> jupyter notebook


This is just to show you installing QDK with right .NET version with Jupyter.  Jupyter can be utilize the notebook, but I don't see much benefit of using Jupyter in this case.  VS or VS code would be better choice as you still have to write the code in Q#.

There are a lot of docs and examples of Q# -- this is a big plus for learning.
Next time, I'll put some notes on VS, VS code and Q#.


November 3, 2019

[Quantum Computer] Getting Started: Microsoft LIQUi|>

There are several quantum computer simulators and programming environments.  I'm experimenting/learning with a few -- and this is a note on installation and learning resources.

For Microsoft LIQUi|>, I actually experiment with it a couple of years ago, back in 2017.  I'm going through my note and putting some information on this posting, before I put some note on other quantum computer simulation and programming tools I recently toying around with.

First read these pages,

[1] https://blogs.msdn.microsoft.com/uk_faculty_connection/2017/10/11/getting-started-with-liqui-and-quantum-computing/

[2] Microsoft LIQUi|> (Liquid), https://www.microsoft.com/en-us/research/project/language-integrated-quantum-operations-liqui/


Installation

On Windows, Visual Studio (community version works fine), and uses LIQUi|> own language and F#.  It also support Ubuntu and OSX, but I only tried on Windows 10.

See the installation steps here, http://stationq.github.io/Liquid/getting-started/

Essentially, just two installation steps:

Step 1, install VS community version, https://visualstudio.microsoft.com/vs/community/
Step 2, download ZIP from this GitHub, extract and run, https://github.com/StationQ/Liquid

My impression on this was -- installation and running were simple, but hard to learn, and not much learning resources.  I don't recommend using this.  Next posting, I'll post about other more recent simulators and SDKs that seems easier to learn.

REFERENCES

October 5, 2019

[NOTE] RAM disk on Win10

Purpose

Use portion of computer memory (RAM) as disk.  The usage is up to you, but I wouldn't use this to store browser cache or system temp.

Environment

  • Win10 Pro 64 bit, build version 1803
  • Memory 64 GB 

Download

Install

[1] Install ImDisk first

This application will give very basic RAM disk feature only.  Whatever it's written in RAM disk will not be saved and will be lost after restarting the machine.

Note: bring the old Windows Control Panel and you'll find "ImDisk Virtual Disk Driver"



[2] If you have ransomware protection on, disable it temporarily to allow ImDisk toolkit to make shortcuts on Desktop:
  1. Run "Windows Defender Security Center" > Virus & thread protection
  2. Click on "Ransomware protection" > turn it off
[3] Install ImDisk toolkit
This will create icons on desktop, that's the reason for step #2.

[4] Turn back on ransomware protection if you had this on before.
[4.1] Add these programs to "Allow an app through Controlled folder access":
  • C:\Windows\SysWOW64\imdisk.exe
  • C:\Windows\System32\imdisk.exe 
  • C:\Program Files\ImDisk\ImDisk-Dlg.exe
  • C:\Program Files\ImDisk\RamDiskUI.exe
  • C:\Windows\System32\format.com
[5] Create folder, example C:\RamDiskContentBackup

This is to back up and restore RAM disk content.

Configuration

Double click on "RamDisk Configuration", and set up like this:















References