#31 2011-11-27 10:37

SafetyCar
Senior Member
Registered: 2008-04-28
Posts: 446
Website

Re: MSI files are detected as ppt/xls/doc files

Just a minimal change that I have is WideExtractBaseName(FileName) replaced with WideStripExtension(FileName), to respect if the name contains folder paths.

Also we sholud point out for other people that TrID Script v6 only works above ReNamer 5.60+ Beta 10


If this software has helped you, consider getting your pro version. :)

Offline

#32 2011-11-27 13:24

den4b
Administrator
From: den4b.com
Registered: 2006-04-06
Posts: 3,379

Re: MSI files are detected as ppt/xls/doc files

Thumbs up on the SafetyCar's suggestion. Use either WideStripExtension or WideChangeFileExt instead, because they will maintain the path/directory component of the new name.

Offline

#33 2011-11-27 13:46

den4b
Administrator
From: den4b.com
Registered: 2006-04-06
Posts: 3,379

Re: MSI files are detected as ppt/xls/doc files

I've added it to the Wiki: wiki/ReNamer:Scripts:TrID

P.S. Also changed the function used to change the extension to WideStripExtension.

Offline

#34 2011-11-27 14:31

Andrew
Senior Member
Registered: 2008-05-22
Posts: 542

Re: MSI files are detected as ppt/xls/doc files

Cool, thanks to everyone involved! smile

BTW, the subtle difference between WideExtractBaseName and WideStripExtension should be mentioned on the http://www.den4b.com/wiki/ReNamer:Pasca … _Utilities page.

Offline

#35 2011-11-28 03:01

narayan
Senior Member
Registered: 2009-02-08
Posts: 470

Re: MSI files are detected as ppt/xls/doc files

I second the vote of thanks!

Now I launch ReNamer with a preset that has the extension-finder script as the first rule.
I noticed that it still cannot find mp4 files downloaded from the YouTube (a very common case).
The ReNamer suggests three different extensions (m4v, m4r, 3g2), but does NOT suggest "mp4".

Offline

#36 2011-11-28 06:09

Andrew
Senior Member
Registered: 2008-05-22
Posts: 542

Re: MSI files are detected as ppt/xls/doc files

@narayan: Please see this post for a detailed explanation of this very issue. I've explained in some detail how exactly TrID works, and in what format it returns its results.

.M4V (MPEG-4 Video), .M4R (iPhone Ringtone, which is simply a renamed .M4A) and .3G2 (very similar to MPEG-4 Part 14 i.e. MP4) are all basically the same container format. If you see the values returned by TrID for the file I tested in that post, the confidence threshold for .MP4 (Generic MP4 container) is just 1.5%, since it tries its level best to identify specific types first, and thus generic types (.MP4 is a generic title for all these similar formats) are reported last. Since the script has a cutoff defined of 20% (that you can change easily), it obviously doesn't include .MP4 in the list of possible extensions. As for what you can do about it, if you're sure you want to classify the file as an .MP4, then either reduce the cutoff percentage below 20% (in which case you'll start getting rubbish results for other files), or else set a replace rule to replace .M4A, .M4V etc. with the generic .MP4.

This is not an exact science by any means, and for similar filetypes it comes down to guesswork really after a point. If you find an erroneous detection however, you can always correct the definition and send it in to Marco for inclusion in the next iteration of the .TRD file. How to do this using TrIDScan is mentioned in that thread as well.

P.S. What does DUBS return for the same file?

Last edited by Andrew (2011-11-28 06:13)

Offline

#37 2011-11-28 10:10

narayan
Senior Member
Registered: 2009-02-08
Posts: 470

Re: MSI files are detected as ppt/xls/doc files

Hi Andrew,

Thanks for that explanation. Yes, I remember this now, from what I read up on TrID...

What's DUBS?

Offline

#38 2011-11-28 11:46

eR@SeR
Senior Member
From: Земун, Србија
Registered: 2008-01-23
Posts: 353

Re: MSI files are detected as ppt/xls/doc files

What's DUBS?

Abbreviation of "Detect using binary signature" (Dubs)... It is explained here  big_smile


TRUTH, FREEDOM, JUSTICE and FATHERLAND are the highest morale values which human is born, lives and dies for!

Offline

Board footer

Powered by FluxBB