Taking this song as example,From the beginning of the song, I was thinking that it must be a Bm, since the songs also end in a Bm. But after looking up the score, it was actually written in D major. So, how do you recognize since the song also starts in Bm (the 6th scale degree of D as you can see in the numbered musical notation). Besides, there's also a #4, which is G#. Is it because of raising the G in B melodic minor? Or it's just little key change to A major? The song also ends in Bm. How can you know the composer's intention whether it's in minor or major since the song could be lingering a lot in minor and occasionally go back to the major key? In short, is it aurally possible to get the "real" key when dealing with such situation?
If a piece is written In a particular key, it will have that particular key signature. It can't be helped that every major key has a relative minor, using the exact same notes - sometimes.
Purpose of a key sig. is to avoid having to write in each # or b as it would occur virtually every time - in Bm/D every C# and F# would need putting in with 'accidentals'.
In minor keys, there are sometimes (as hinted earlier) extra notes which need to get changed, and taking Bm, probably more often than not, A# will be found. Some composers in the past (Debussi??) have actually used key sigs that look odd - in Bm for example, F#, C# A#, or bizarrely, in Dm, Bb and C#. Which, in reality wasn't be a bad idea. It just never caught on.
In any written music, listening to it will determine whether it's major or minor (or even modal), but a lot of pieces will sort of modulate in and out of the relatives quite naturally, so it could be said that a piece ostensibly in Bm has passages firmly in D major.
Sadly, the version you post isn't in standard Western manuscript form, and is therefore unintelligible to me, and I suspect, a lot of other posters. But, if the key sig. was indeed F# C#, that would not necessarily denote D major any more than Bm. Last (and often first) notes/harmonies are always a good clue. Bear in mind that with 2#, it could have been in E Dorian...