mirror of
				https://github.com/ARM-software/workload-automation.git
				synced 2025-10-31 15:12:25 +00:00 
			
		
		
		
	util-fps: handle divide by zero possibility
This commit is contained in:
		| @@ -111,6 +111,7 @@ class FpsProcessor(object): | |||||||
|                 not_at_vsync = self.data.IntendedVsync - self.data.Vsync |                 not_at_vsync = self.data.IntendedVsync - self.data.Vsync | ||||||
|                 not_at_vsync = not_at_vsync[not_at_vsync != 0].count() |                 not_at_vsync = not_at_vsync[not_at_vsync != 0].count() | ||||||
|  |  | ||||||
|  |                 if frame_count > 1: | ||||||
|                     duration = self.data.Vsync.iloc[-1] - self.data.Vsync.iloc[0] |                     duration = self.data.Vsync.iloc[-1] - self.data.Vsync.iloc[0] | ||||||
|                     fps = (1e9 * frame_count) / float(duration) |                     fps = (1e9 * frame_count) / float(duration) | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user