Changeset 30913
- Timestamp:
- Mar 16, 2011, 9:03:53 AM (15 years ago)
- File:
-
- 1 edited
-
trunk/tools/czartool/CzarDb.pm (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/tools/czartool/CzarDb.pm
r30397 r30913 629 629 my ($derivProcessed, $derivPending, $derivFaults); 630 630 my $timestamp = undef; 631 631 my $positiveJump = 0; 632 632 633 $linearProcessed = 0; 633 634 my $someData = 0; … … 635 636 my ($thisTimestamp, $thisPending, $thisFaults, $thisProcessed) = @row; 636 637 637 # get linear values638 if ($showCleanup) {639 640 $linearProcessed = $thisProcessed - $minProcessed;641 }642 elsif($lastProcessed != -1 && $thisProcessed > $lastProcessed) {643 644 $linearProcessed = $linearProcessed + ($thisProcessed - $lastProcessed);645 }646 $linearPending = $thisPending;647 $linearFaults = $thisFaults;648 638 649 639 # get first derivative values … … 660 650 # $derivPending = abs($thisPending - $lastPending)/$timeDiff; 661 651 # $derivFaults = abs($thisFaults - $lastFaults)/$timeDiff; 652 653 # look for large positive jumps in processed, most likely a label added, and store value to subtract from linear value below 654 if ($derivProcessed > 0.3) { 655 656 $positiveJump = $thisProcessed - $lastProcessed; 657 #print "$derivProcessed at $thisTimestamp $positiveJump\n"; 658 } 659 else { 660 $positiveJump = 0; 661 } 662 662 } 663 663 else { … … 667 667 $derivFaults = 0; 668 668 } 669 670 # get linear values 671 if ($showCleanup) { 672 673 $linearProcessed = $thisProcessed - $minProcessed; 674 } 675 elsif($lastProcessed != -1 && $thisProcessed > $lastProcessed) { 676 677 $linearProcessed = $linearProcessed + ($thisProcessed - $lastProcessed) - $positiveJump; 678 } 679 $linearPending = $thisPending; 680 $linearFaults = $thisFaults; 669 681 670 682 # get log values
Note:
See TracChangeset
for help on using the changeset viewer.
