The solution is:
Set A1=0, A2=0, B1=1, B2=0, C1=1, C2=1, D1=1 and D2=2. There is now only one way to complete the loop around the three 3's. The 2 at the bottom of col 3 can only be satisfied by being passed with a diagonal action, meaning there must be a loop segment along the bottom of the grid to its right. There is also only one way to satisfy the 1 on the top row:
In order for the three adjacent 1's to be satisfied, the loop must pass to the left of the leftmost one (or it ends up trapped in the corner) and there is only one way to satisfy the other two 1's in the group. The line can be extended further downwards to satisfy the 1 at the end of row 5, and there is also only one way to resolve the 1 in the bottom-right corner.
Next, note that there must be a segment to the right of the middle 2 in the bank of three 2's, as the topmost 2 must be bypassed diagonally and this is the only way to avoid forming two separate loops.
Then focus on the rightmost 3. If we had a line segment going right from it, we would end up unable to satisfy the 2's and avoid forming two separate loops, so instead the loop must go downwards from the 3. This forces the position of the loop round the 2 at the bottom of col 3.
Finally, there is only one way to resolve the 2 at the bottom of col 5, and the final segments are forced. So there you have it - an initial setup with only one logically deducible solution!
Remarks on setting the initial values:
Here I explain the thought processes that actually led me to settle on this combination of starting numbers. However, please also read @Retudin's answer as I think they've done a nice job of explaining this part diagrammatically...
Trivially, A1 and A2 must both be 0.
Since this then forces the loop down the left-hand side of the grid past the 3's, we can rule out D1 and D2 as some combination of 0 and 3, as this will be impossible to satisfy. Furthermore, D1=2 and D1=1 will not result in unique solutions, since the path could pass D1 in 2 different ways - thus we must have D1=1 and D2=2.
Crucially now to avoid this generating two possible solutions (thereby making the solution non-unique), we need some way to prevent the loop around D2 having two possible orientations. This means the loop must pass down from the rightmost 3 to use the top-right dot of D2 and continue on rightwards. This means we'll need to find a way to ensure that that pair of segments can't be positioned elsehow, being careful of ambiguities around the three 2's...
At this stage a little experimentation with the values of B1 and B2 (one of which must be 1 and the other 0) led me to deduce that B1=1 and B2=0, since if B2=1 the loop would have to go up past the 1 at the end of row 3 on the right-hand side, and then loop around and down between the other two 1's - but then this resulted in ambiguities among the 2's (previously mentioned as undesirable in the paragraph above) both when C1=1 and C2=1 and when C1=2 and C2=0 (the third combination of C1=0 and C2=2 makes it impossible to navigate the bottom right-hand corner of the grid in any situation). Thus B1=1 and B2=0, which in turn meant that C1 and C2 must both be 1, as any other arrangement for them is now impossible.