In the film version of Harry Potter and the Prisoner of Azkaban, during the Quidditch match, we see a cloud formation which looks a great deal like The Grim or Sirius Black's animagus. Was that cloud formation of a dog related to Sirius Black in any way? i.e. did Black conjure it up as a sign to Harry, or was it just mere luck?
I have a different take on the answer, although it mixes canon, reference books, and movie canon. In Harry Potter and the Prisoner of Azkaban, the novel, Professor Trelawney specifically says that the Grim haunts churchyards:
‘The Grim, my dear, the Grim!’ cried Professor Trelawney, who looked shocked that Harry hadn’t understood. ‘The giant, spectral dog that haunts churchyards! My dear boy, it is an omen – the worst omen – of death!’
Prisoner of Azkaban - page 83 - Chapter 6, Talons and Tealeaves - Bloomsbury
Now, we all know Professor Trelawney is a bit of a windbag. The movie and book show us that representations of the Grim can be demonstrated outside of a churchyard, first in Harry's tea leaves in both the book and movie versions of Prisoner of Azkaban. However, the movie scene with the dog-like figure in the clouds in Prisoner of Azkaban, the movie* is not the Grim:
In Harry Potter and the Prisoner of Azkaban [the movie], Padfoot, who is mistaken for the Grim. was a computer-generated Animagus.
Harry Potter: The Creature Vault by Jody Revenson - page 104 - Chapter Five, Shape Shifters - Harper Collins
Let's put book canon aside. I'd suggest that, in the movie, Harry's paranoia of dying was so heightened that he mistakenly imagined a group of clouds as the image of the Grim. The quote from Harry Potter: The Creature Vault confirms that Sirius's Animagus form is mistaken for the Grim.
So, was the cloud formation in Prisoner of Azkaban related to Sirius Black?
No, it was not, because Harry Potter: The Creature Vault verifies that Sirius's Animagus form was not related to the Grim. Also, at the time that Harry supposedly saw "the Grim" in the movie Prisoner of Azkaban, Harry was completely unaware that Sirius is an Animagus
Representation of the Grim in one of Trelawney's teacups, in the movie Prisoner of Azkaban.
Representation of the Grim, as Harry sees it, in the movie Prisoner of Azkaban.
Sirius Black in his Animagus form -- originally mistaken for the Grim -- dragging Ron toward the Whomping Willow in the movie Prisoner of Azkaban.
I believe this is the scene you are referring to:
this scene was only added in the movie, probably for dramatic effect.
In the book what actually happens is that Harry sees a silhouette of Sirius (as a dog) at the top of the stands but he vanishes in the blink of an eye.
Instead of seeing Sirius in his Animagus form of the big, black dog sitting by the stands during his quidditch match like Harry does in the book, the film has Harry see a cloud in the shape of the Grim as he flies towards the snitch.
So this dog in the cloud can be said to be related to Sirius or not, based on how much you consider the movie a canon source