criterion 0.8.1.0 → 1.0.0.0
raw patch · 48 files changed
+13172/−1285 lines, 48 filesdep +HUnitdep +QuickCheckdep +ansi-wl-pprintdep ~aesondep ~basedep ~binarynew-component:exe:criterionbinary-added
Dependencies added: HUnit, QuickCheck, ansi-wl-pprint, cassava, criterion, either, optparse-applicative, test-framework, test-framework-hunit, test-framework-quickcheck2
Dependency ranges changed: aeson, base, binary, bytestring, statistics, vector
Files
- Criterion.hs +41/−10
- Criterion/Analysis.hs +142/−40
- Criterion/Analysis/Types.hs +0/−96
- Criterion/Config.hs +0/−146
- Criterion/Environment.hs +0/−63
- Criterion/IO.hs +38/−21
- Criterion/IO/Printf.hs +18/−16
- Criterion/Internal.hs +109/−178
- Criterion/Main.hs +68/−177
- Criterion/Main/Options.hs +184/−0
- Criterion/Measurement.hs +169/−42
- Criterion/Monad.hs +53/−16
- Criterion/Monad/Internal.hs +41/−0
- Criterion/Report.hs +57/−39
- Criterion/Types.hs +549/−94
- LICENSE +4/−0
- app/App.hs +5/−0
- cbits/cycles.c +8/−0
- cbits/time-osx.c +35/−0
- cbits/time-posix.c +24/−0
- cbits/time-windows.c +80/−0
- criterion.cabal +75/−16
- examples/BadReadFile.hs +17/−0
- examples/ConduitVsPipes.hs +34/−0
- examples/Fibber.hs +11/−36
- examples/GoodReadFile.hs +12/−0
- examples/Judy.hs +1/−2
- examples/Maps.hs +90/−0
- examples/Overhead.hs +28/−0
- examples/Tiny.hs +0/−28
- examples/criterion-examples.cabal +83/−0
- examples/fibber.html +726/−0
- examples/maps.html +552/−0
- js-src/flot-0.8.3.zip binary
- js-src/jquery-2.1.1.js +9190/−0
- templates/criterion.css +2/−2
- templates/default.tpl +335/−0
- templates/default2.tpl +296/−0
- templates/js/excanvas-r3.min.js +0/−1
- templates/js/jquery-1.6.4.min.js +0/−4
- templates/js/jquery-2.1.1.min.js +4/−0
- templates/js/jquery.criterion.js +26/−23
- templates/js/jquery.flot-0.7.min.js +0/−6
- templates/js/jquery.flot-0.8.3.min.js +8/−0
- templates/json.tpl +1/−0
- templates/report.tpl +0/−229
- tests/Sanity.hs +48/−0
- tests/Tests.hs +8/−0
Criterion.hs view
@@ -1,7 +1,7 @@ {-# LANGUAGE RecordWildCards #-} -- | -- Module : Criterion--- Copyright : (c) 2009, 2010, 2011 Bryan O'Sullivan+-- Copyright : (c) 2009-2014 Bryan O'Sullivan -- -- License : BSD-style -- Maintainer : bos@serpentine.com@@ -12,20 +12,51 @@ module Criterion (- Benchmarkable(..)+ -- * Benchmarkable code+ Benchmarkable(run)+ -- * Creating a benchmark suite , Benchmark- , Pure+ , env+ , bench+ , bgroup+ -- ** Running a benchmark , nf , whnf , nfIO , whnfIO- , bench- , bcompare- , bgroup- , runBenchmark- , runAndAnalyse- , runNotAnalyse+ -- * For interactive use+ , benchmark+ , benchmarkWith+ , benchmark'+ , benchmarkWith' ) where -import Criterion.Internal+import Control.Monad (void)+import Criterion.IO.Printf (note)+import Criterion.Internal (runAndAnalyseOne)+import Criterion.Main.Options (defaultConfig)+import Criterion.Measurement (initializeTime)+import Criterion.Monad (withConfig) import Criterion.Types++-- | Run a benchmark interactively, and analyse its performance.+benchmark :: Benchmarkable -> IO ()+benchmark bm = void $ benchmark' bm++-- | Run a benchmark interactively, analyse its performance, and+-- return the analysis.+benchmark' :: Benchmarkable -> IO Report+benchmark' = benchmarkWith' defaultConfig++-- | Run a benchmark interactively, and analyse its performance.+benchmarkWith :: Config -> Benchmarkable -> IO ()+benchmarkWith cfg bm = void $ benchmarkWith' cfg bm++-- | Run a benchmark interactively, analyse its performance, and+-- return the analysis.+benchmarkWith' :: Config -> Benchmarkable -> IO Report+benchmarkWith' cfg bm = do+ initializeTime+ withConfig cfg $ do+ _ <- note "benchmarking...\n"+ runAndAnalyseOne 0 "function" bm
Criterion/Analysis.hs view
@@ -1,7 +1,7 @@-{-# LANGUAGE DeriveDataTypeable, RecordWildCards, UnboxedTuples #-}+{-# LANGUAGE BangPatterns, DeriveDataTypeable, RecordWildCards #-} -- | -- Module : Criterion.Analysis--- Copyright : (c) 2009, 2010, 2011 Bryan O'Sullivan+-- Copyright : (c) 2009-2014 Bryan O'Sullivan -- -- License : BSD-style -- Maintainer : bos@serpentine.com@@ -12,7 +12,7 @@ module Criterion.Analysis (- Outliers (..)+ Outliers(..) , OutlierEffect(..) , OutlierVariance(..) , SampleAnalysis(..)@@ -23,21 +23,35 @@ , classifyOutliers , noteOutliers , outlierVariance+ , resolveAccessors+ , validateAccessors+ , regress ) where -import Control.Monad (when)-import Criterion.Analysis.Types-import Criterion.IO.Printf (note)-import Criterion.Measurement (secs)-import Criterion.Monad (Criterion)+import Control.Arrow (second)+import Control.Monad (unless, when)+import Control.Monad.Reader (ask)+import Control.Monad.Trans+import Control.Monad.Trans.Either+import Criterion.IO.Printf (note, prolix)+import Criterion.Measurement (secs, threshold)+import Criterion.Monad (Criterion, getGen, getOverhead)+import Criterion.Types import Data.Int (Int64)+import Data.Maybe (fromJust) import Data.Monoid (Monoid(..)) import Statistics.Function (sort) import Statistics.Quantile (weightedAvg)-import Statistics.Resampling (Resample, resample)+import Statistics.Regression (bootstrapRegress, olsRegress)+import Statistics.Resampling (resample) import Statistics.Sample (mean)+import Statistics.Sample.KernelDensity (kde) import Statistics.Types (Estimator(..), Sample)-import System.Random.MWC (withSystemRandom)+import System.Random.MWC (GenIO)+import qualified Data.List as List+import qualified Data.Map as Map+import qualified Data.Vector as V+import qualified Data.Vector.Generic as G import qualified Data.Vector.Unboxed as U import qualified Statistics.Resampling.Bootstrap as B @@ -46,20 +60,19 @@ classifyOutliers sa = U.foldl' ((. outlier) . mappend) mempty ssa where outlier e = Outliers { samplesSeen = 1- , lowSevere = if e <= loS then 1 else 0+ , lowSevere = if e <= loS && e < hiM then 1 else 0 , lowMild = if e > loS && e <= loM then 1 else 0 , highMild = if e >= hiM && e < hiS then 1 else 0- , highSevere = if e >= hiS then 1 else 0+ , highSevere = if e >= hiS && e > loM then 1 else 0 }- loS = q1 - (iqr * 3)- loM = q1 - (iqr * 1.5)- hiM = q3 + (iqr * 1.5)- hiS = q3 + (iqr * 3)- q1 = weightedAvg 1 4 ssa- q3 = weightedAvg 3 4 ssa- ssa = sort sa- iqr = q3 - q1-{-# INLINE classifyOutliers #-}+ !loS = q1 - (iqr * 3)+ !loM = q1 - (iqr * 1.5)+ !hiM = q3 + (iqr * 1.5)+ !hiS = q3 + (iqr * 3)+ q1 = weightedAvg 1 4 ssa+ q3 = weightedAvg 3 4 ssa+ ssa = sort sa+ iqr = q3 - q1 -- | Compute the extent to which outliers in the sample data affect -- the sample mean and standard deviation.@@ -70,10 +83,10 @@ -> OutlierVariance outlierVariance µ σ a = OutlierVariance effect desc varOutMin where- (# effect, desc #) | varOutMin < 0.01 = (# Unaffected, "no" #)- | varOutMin < 0.1 = (# Slight, "slight" #)- | varOutMin < 0.5 = (# Moderate, "moderate" #)- | otherwise = (# Severe, "severe" #)+ ( effect, desc ) | varOutMin < 0.01 = (Unaffected, "no")+ | varOutMin < 0.1 = (Slight, "slight")+ | varOutMin < 0.5 = (Moderate, "moderate")+ | otherwise = (Severe, "severe") varOutMin = (minBy varOut 1 (minBy cMax 0 µgMin)) / σb2 varOut c = (ac / a) * (σb2 - ac * σg2) where ac = a - c σb = B.estPoint σ@@ -117,23 +130,112 @@ , anStdDev = B.scale f anStdDev } --- | Perform a bootstrap analysis of a non-parametric sample.-analyseSample :: Double -- ^ Confidence interval (between 0 and 1).- -> Sample -- ^ Sample data.- -> Int -- ^ Number of resamples to perform- -- when bootstrapping.- -> IO SampleAnalysis-analyseSample ci samples numResamples = do- let ests = [Mean,StdDev]- resamples <- withSystemRandom $ \gen ->- resample gen ests numResamples samples :: IO [Resample]- let [estMean,estStdDev] = B.bootstrapBCA ci samples ests resamples- ov = outlierVariance estMean estStdDev (fromIntegral $ U.length samples)- return SampleAnalysis {- anMean = estMean- , anStdDev = estStdDev+-- | Perform an analysis of a measurement.+analyseSample :: Int -- ^ Experiment number.+ -> String -- ^ Experiment name.+ -> V.Vector Measured -- ^ Sample data.+ -> EitherT String Criterion Report+analyseSample i name meas = do+ Config{..} <- ask+ overhead <- lift getOverhead+ let ests = [Mean,StdDev]+ -- The use of filter here throws away very-low-quality+ -- measurements when bootstrapping the mean and standard+ -- deviations. Without this, the numbers look nonsensical when+ -- very brief actions are measured.+ stime = measure (measTime . rescale) .+ G.filter ((>= threshold) . measTime) . G.map fixTime .+ G.tail $ meas+ fixTime m = m { measTime = measTime m - overhead / 2 }+ n = G.length meas+ s = G.length stime+ _ <- lift $ prolix "bootstrapping with %d of %d samples (%d%%)\n"+ s n ((s * 100) `quot` n)+ gen <- lift getGen+ rs <- mapM (\(ps,r) -> regress gen ps r meas) $+ ((["iters"],"time"):regressions)+ resamps <- liftIO $ resample gen ests resamples stime+ let [estMean,estStdDev] = B.bootstrapBCA confInterval stime ests resamps+ ov = outlierVariance estMean estStdDev (fromIntegral n)+ an = SampleAnalysis {+ anRegress = rs+ , anOverhead = overhead+ , anMean = estMean+ , anStdDev = estStdDev , anOutlierVar = ov }+ return Report {+ reportNumber = i+ , reportName = name+ , reportKeys = measureKeys+ , reportMeasured = meas+ , reportAnalysis = an+ , reportOutliers = classifyOutliers stime+ , reportKDEs = [uncurry (KDE "time") (kde 128 stime)]+ }++-- | Regress the given predictors against the responder.+--+-- Errors may be returned under various circumstances, such as invalid+-- names or lack of needed data.+--+-- See 'olsRegress' for details of the regression performed.+regress :: GenIO+ -> [String] -- ^ Predictor names.+ -> String -- ^ Responder name.+ -> V.Vector Measured+ -> EitherT String Criterion Regression+regress gen predNames respName meas = do+ when (G.null meas) $+ left "no measurements"+ accs <- hoistEither $ validateAccessors predNames respName+ let unmeasured = [n | (n, Nothing) <- map (second ($ G.head meas)) accs]+ unless (null unmeasured) $+ left $ "no data available for " ++ renderNames unmeasured+ let (r:ps) = map ((`measure` meas) . (fromJust .) . snd) accs+ Config{..} <- ask+ (coeffs,r2) <- liftIO $+ bootstrapRegress gen resamples confInterval olsRegress ps r+ return Regression {+ regResponder = respName+ , regCoeffs = Map.fromList (zip (predNames ++ ["y"]) (G.toList coeffs))+ , regRSquare = r2+ }++singleton :: [a] -> Bool+singleton [_] = True+singleton _ = False++-- | Given a list of accessor names (see 'measureKeys'), return either+-- a mapping from accessor name to function or an error message if+-- any names are wrong.+resolveAccessors :: [String]+ -> Either String [(String, Measured -> Maybe Double)]+resolveAccessors names =+ case unresolved of+ [] -> Right [(n, a) | (n, Just (a,_)) <- accessors]+ _ -> Left $ "unknown metric " ++ renderNames unresolved+ where+ unresolved = [n | (n, Nothing) <- accessors]+ accessors = flip map names $ \n -> (n, Map.lookup n measureAccessors)++-- | Given predictor and responder names, do some basic validation,+-- then hand back the relevant accessors.+validateAccessors :: [String] -- ^ Predictor names.+ -> String -- ^ Responder name.+ -> Either String [(String, Measured -> Maybe Double)]+validateAccessors predNames respName = do+ when (null predNames) $+ Left "no predictors specified"+ let names = respName:predNames+ dups = map head . filter (not . singleton) .+ List.group . List.sort $ names+ unless (null dups) $+ Left $ "duplicated metric " ++ renderNames dups+ resolveAccessors names++renderNames :: [String] -> String+renderNames = List.intercalate ", " . map show -- | Display a report of the 'Outliers' present in a 'Sample'. noteOutliers :: Outliers -> Criterion ()
− Criterion/Analysis/Types.hs
@@ -1,96 +0,0 @@-{-# LANGUAGE DeriveDataTypeable, DeriveGeneric, OverloadedStrings,- RecordWildCards #-}--- |--- Module : Criterion.Analysis.Types--- Copyright : (c) 2011 Bryan O'Sullivan------ License : BSD-style--- Maintainer : bos@serpentine.com--- Stability : experimental--- Portability : GHC------ Analysis types.--module Criterion.Analysis.Types- (- Outliers (..)- , OutlierEffect(..)- , OutlierVariance(..)- , SampleAnalysis(..)- ) where--import Control.DeepSeq (NFData(rnf))-import Data.Binary (Binary)-import Data.Data (Data, Typeable)-import Data.Int (Int64)-import Data.Monoid (Monoid(..))-import GHC.Generics (Generic)-import qualified Statistics.Resampling.Bootstrap as B---- | Outliers from sample data, calculated using the boxplot--- technique.-data Outliers = Outliers {- samplesSeen :: {-# UNPACK #-} !Int64- , lowSevere :: {-# UNPACK #-} !Int64- -- ^ More than 3 times the interquartile range (IQR) below the- -- first quartile.- , lowMild :: {-# UNPACK #-} !Int64- -- ^ Between 1.5 and 3 times the IQR below the first quartile.- , highMild :: {-# UNPACK #-} !Int64- -- ^ Between 1.5 and 3 times the IQR above the third quartile.- , highSevere :: {-# UNPACK #-} !Int64- -- ^ More than 3 times the IQR above the third quartile.- } deriving (Eq, Read, Show, Typeable, Data, Generic)--instance Binary Outliers-instance NFData Outliers---- | A description of the extent to which outliers in the sample data--- affect the sample mean and standard deviation.-data OutlierEffect = Unaffected -- ^ Less than 1% effect.- | Slight -- ^ Between 1% and 10%.- | Moderate -- ^ Between 10% and 50%.- | Severe -- ^ Above 50% (i.e. measurements- -- are useless).- deriving (Eq, Ord, Read, Show, Typeable, Data, Generic)--instance Binary OutlierEffect-instance NFData OutlierEffect--instance Monoid Outliers where- mempty = Outliers 0 0 0 0 0- mappend = addOutliers--addOutliers :: Outliers -> Outliers -> Outliers-addOutliers (Outliers s a b c d) (Outliers t w x y z) =- Outliers (s+t) (a+w) (b+x) (c+y) (d+z)-{-# INLINE addOutliers #-}---- | Analysis of the extent to which outliers in a sample affect its--- standard deviation (and to some extent, its mean).-data OutlierVariance = OutlierVariance {- ovEffect :: OutlierEffect- -- ^ Qualitative description of effect.- , ovDesc :: String- -- ^ Brief textual description of effect.- , ovFraction :: Double- -- ^ Quantitative description of effect (a fraction between 0 and 1).- } deriving (Eq, Read, Show, Typeable, Data, Generic)--instance Binary OutlierVariance--instance NFData OutlierVariance where- rnf OutlierVariance{..} = rnf ovEffect `seq` rnf ovDesc `seq` rnf ovFraction---- | Result of a bootstrap analysis of a non-parametric sample.-data SampleAnalysis = SampleAnalysis {- anMean :: B.Estimate- , anStdDev :: B.Estimate- , anOutlierVar :: OutlierVariance- } deriving (Eq, Read, Show, Typeable, Data, Generic)--instance Binary SampleAnalysis--instance NFData SampleAnalysis where- rnf SampleAnalysis{..} =- rnf anMean `seq` rnf anStdDev `seq` rnf anOutlierVar
− Criterion/Config.hs
@@ -1,146 +0,0 @@-{-# LANGUAGE DeriveDataTypeable, DeriveGeneric #-}---- |--- Module : Criterion.Config--- Copyright : (c) 2009, 2010 Bryan O'Sullivan------ License : BSD-style--- Maintainer : bos@serpentine.com--- Stability : experimental--- Portability : GHC------ Benchmarking configuration.--module Criterion.Config- (- Config(..)- , PrintExit(..)- , MatchType(..)- , Verbosity(..)- , defaultConfig- , fromLJ- , ljust- ) where--import Data.Data (Data, Typeable)-import Data.Function (on)-import Data.Monoid (Monoid(..), Last(..))-import GHC.Generics (Generic)--data MatchType = Prefix | Glob- deriving (Eq, Ord, Bounded, Enum, Read, Show, Typeable, Data,- Generic)---- | Control the amount of information displayed.-data Verbosity = Quiet- | Normal- | Verbose- deriving (Eq, Ord, Bounded, Enum, Read, Show, Typeable, Data,- Generic)---- | Print some information and exit, without running any benchmarks.-data PrintExit = Nada -- ^ Do not actually print-and-exit. (Default.)- | List -- ^ Print a list of known benchmarks.- | Version -- ^ Print version information (if known).- | Help -- ^ Print a help\/usaage message.- deriving (Eq, Ord, Bounded, Enum, Read, Show, Typeable, Data,- Generic)--instance Monoid PrintExit where- mempty = Nada- mappend = max---- | Top-level program configuration.-data Config = Config {- cfgBanner :: Last String -- ^ The \"version\" banner to print.- , cfgConfInterval :: Last Double -- ^ Confidence interval to use.- , cfgMatchType :: Last MatchType -- ^ Kind of matching to use for benchmark names.- , cfgPerformGC :: Last Bool -- ^ Whether to run the GC between passes.- , cfgPrintExit :: PrintExit -- ^ Whether to print information and exit.- , cfgResamples :: Last Int -- ^ Number of resamples to perform.- , cfgResults :: Last FilePath -- ^ File to write raw results to.- , cfgReport :: Last FilePath -- ^ Filename of report.- , cfgSamples :: Last Int -- ^ Number of samples to collect.- , cfgSummaryFile :: Last FilePath -- ^ Filename of summary CSV.- , cfgCompareFile :: Last FilePath -- ^ Filename of the comparison CSV.- , cfgTemplate :: Last FilePath -- ^ Filename of report template.- , cfgVerbosity :: Last Verbosity -- ^ Whether to run verbosely.- , cfgJUnitFile :: Last FilePath -- ^ Filename of JUnit report.- , cfgMeasure :: Last Bool -- ^ Whether to do any measurement.- } deriving (Eq, Read, Show, Typeable, Generic)--instance Monoid Config where- mempty = emptyConfig- mappend = appendConfig---- | A configuration with sensible defaults.-defaultConfig :: Config-defaultConfig = Config {- cfgBanner = ljust "I don't know what version I am."- , cfgConfInterval = ljust 0.95- , cfgMatchType = ljust Prefix- , cfgPerformGC = ljust True- , cfgPrintExit = Nada- , cfgResamples = ljust (100 * 1000)- , cfgResults = mempty- , cfgReport = mempty- , cfgSamples = ljust 100- , cfgSummaryFile = mempty- , cfgCompareFile = mempty- , cfgTemplate = ljust "report.tpl"- , cfgVerbosity = ljust Normal- , cfgJUnitFile = mempty- , cfgMeasure = ljust True- }---- | Constructor for 'Last' values.-ljust :: a -> Last a-ljust = Last . Just---- | Deconstructor for 'Last' values.-fromLJ :: (Config -> Last a) -- ^ Field to access.- -> Config -- ^ Default to use.- -> a-fromLJ f cfg = case f cfg of- Last Nothing -> fromLJ f defaultConfig- Last (Just a) -> a--emptyConfig :: Config-emptyConfig = Config {- cfgBanner = mempty- , cfgConfInterval = mempty- , cfgMatchType = mempty- , cfgPerformGC = mempty- , cfgPrintExit = mempty- , cfgReport = mempty- , cfgResamples = mempty- , cfgResults = mempty- , cfgSamples = mempty- , cfgSummaryFile = mempty- , cfgCompareFile = mempty- , cfgTemplate = mempty- , cfgVerbosity = mempty- , cfgJUnitFile = mempty- , cfgMeasure = mempty- }--appendConfig :: Config -> Config -> Config-appendConfig a b =- Config {- cfgBanner = app cfgBanner a b- , cfgConfInterval = app cfgConfInterval a b- , cfgMatchType = app cfgMatchType a b- , cfgPerformGC = app cfgPerformGC a b- , cfgPrintExit = app cfgPrintExit a b- , cfgReport = app cfgReport a b- , cfgResamples = app cfgResamples a b- , cfgResults = app cfgResults a b- , cfgSamples = app cfgSamples a b- , cfgSummaryFile = app cfgSummaryFile a b- , cfgCompareFile = app cfgCompareFile a b- , cfgTemplate = app cfgTemplate a b- , cfgVerbosity = app cfgVerbosity a b- , cfgJUnitFile = app cfgJUnitFile a b- , cfgMeasure = app cfgMeasure a b- }- where app f = mappend `on` f
− Criterion/Environment.hs
@@ -1,63 +0,0 @@-{-# LANGUAGE DeriveDataTypeable, DeriveGeneric, TypeOperators #-}---- |--- Module : Criterion.Environment--- Copyright : (c) 2009, 2010 Bryan O'Sullivan------ License : BSD-style--- Maintainer : bos@serpentine.com--- Stability : experimental--- Portability : GHC------ Code for measuring and characterising the execution environment.--module Criterion.Environment- (- Environment(..)- , measureEnvironment- ) where--import Control.Monad (replicateM_)-import Control.Monad.Trans (liftIO)-import Criterion.Analysis (analyseMean)-import Criterion.IO.Printf (note)-import Criterion.Measurement (getTime, runForAtLeast, time_)-import Criterion.Monad (Criterion)-import qualified Data.Vector.Unboxed as U-import Data.Data (Data, Typeable)-import GHC.Generics (Generic)---- | Measured aspects of the execution environment.-data Environment = Environment {- envClockResolution :: {-# UNPACK #-} !Double- -- ^ Clock resolution (in seconds).- , envClockCost :: {-# UNPACK #-} !Double- -- ^ The cost of a single clock call (in seconds).- } deriving (Eq, Read, Show, Typeable, Data, Generic)---- | Measure the execution environment.-measureEnvironment :: Criterion Environment-measureEnvironment = do- _ <- note "warming up\n"- (_, seed, _) <- liftIO $ runForAtLeast 0.1 10000 resolution- _ <- note "estimating clock resolution...\n"- clockRes <- thd3 `fmap` liftIO (runForAtLeast 0.5 seed resolution) >>=- uncurry analyseMean- _ <- note "estimating cost of a clock call...\n"- clockCost <- cost (min (100000 * clockRes) 1) >>= uncurry analyseMean- return $ Environment {- envClockResolution = clockRes- , envClockCost = clockCost- }- where- resolution k = do- times <- U.replicateM (k+1) getTime- return (U.tail . U.filter (>=0) . U.zipWith (-) (U.tail times) $ times,- U.length times)- cost timeLimit = liftIO $ do- let timeClock k = time_ (replicateM_ k getTime)- _ <- timeClock 1- (_, iters, elapsed) <- runForAtLeast 0.01 10000 timeClock- times <- U.replicateM (ceiling (timeLimit / elapsed)) $ timeClock iters- return (U.map (/ fromIntegral iters) times, U.length times)- thd3 (_, _, c) = c
Criterion/IO.hs view
@@ -1,7 +1,7 @@-{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE CPP, OverloadedStrings #-} -- | -- Module : Criterion.IO--- Copyright : (c) 2009, 2010 Bryan O'Sullivan+-- Copyright : (c) 2009-2014 Bryan O'Sullivan -- -- License : BSD-style -- Maintainer : bos@serpentine.com@@ -13,15 +13,19 @@ module Criterion.IO ( header- , hGetResults- , hPutResults- , readResults- , writeResults+ , hGetReports+ , hPutReports+ , readReports+ , writeReports ) where -import Criterion.Types (ResultForest, ResultTree(..))+import Criterion.Types (Report(..)) import Data.Binary (Binary(..), encode)+#if MIN_VERSION_binary(0, 6, 3) import Data.Binary.Get (runGetOrFail)+#else+import Data.Binary.Get (runGetState)+#endif import Data.Binary.Put (putByteString, putWord16be, runPut) import Data.ByteString.Char8 () import Data.Version (Version(..))@@ -29,34 +33,37 @@ import System.IO (Handle, IOMode(..), withFile) import qualified Data.ByteString.Lazy as L +-- | The header identifies a criterion data file. This contains+-- version information; there is no expectation of cross-version+-- compatibility. header :: L.ByteString header = runPut $ do putByteString "criterio" mapM_ (putWord16be . fromIntegral) (versionBranch version) -hGetResults :: Handle -> IO (Either String ResultForest)-hGetResults handle = do- let fixup = reverse . nukem . reverse- nukem (Compare k _ : rs) = let (cs, rs') = splitAt k rs- in Compare k (fixup (reverse cs)) : nukem rs'- nukem (r : rs) = r : nukem rs- nukem _ = []+-- | Read all reports from the given 'Handle'.+hGetReports :: Handle -> IO (Either String [Report])+hGetReports handle = do bs <- L.hGet handle (fromIntegral (L.length header)) if bs == header- then (Right . fixup) `fmap` readAll handle+ then Right `fmap` readAll handle else return $ Left "unexpected header" -hPutResults :: Handle -> ResultForest -> IO ()-hPutResults handle rs = do+-- | Write reports to the given 'Handle'.+hPutReports :: Handle -> [Report] -> IO ()+hPutReports handle rs = do L.hPut handle header mapM_ (L.hPut handle . encode) rs -readResults :: FilePath -> IO (Either String ResultForest)-readResults path = withFile path ReadMode hGetResults+-- | Read all reports from the given file.+readReports :: FilePath -> IO (Either String [Report])+readReports path = withFile path ReadMode hGetReports -writeResults :: FilePath -> ResultForest -> IO ()-writeResults path rs = withFile path WriteMode (flip hPutResults rs)+-- | Write reports to the given file.+writeReports :: FilePath -> [Report] -> IO ()+writeReports path rs = withFile path WriteMode (flip hPutReports rs) +#if MIN_VERSION_binary(0, 6, 3) readAll :: Binary a => Handle -> IO [a] readAll handle = do let go bs@@ -65,3 +72,13 @@ Left (_, _, err) -> fail err Right (bs', _, a) -> (a:) `fmap` go bs' go =<< L.hGetContents handle+#else+readAll :: Binary a => Handle -> IO [a]+readAll handle = do+ let go i bs+ | L.null bs = return []+ | otherwise =+ let (a, bs', i') = runGetState get bs i+ in (a:) `fmap` go i' bs'+ go 0 =<< L.hGetContents handle+#endif
Criterion/IO/Printf.hs view
@@ -1,6 +1,6 @@ -- | -- Module : Criterion.IO.Printf--- Copyright : (c) 2009, 2010 Bryan O'Sullivan+-- Copyright : (c) 2009-2014 Bryan O'Sullivan -- -- License : BSD-style -- Maintainer : bos@serpentine.com@@ -16,17 +16,20 @@ , note , printError , prolix- , summary+ , writeCsv ) where import Control.Monad (when)+import Control.Monad.Reader (ask, asks) import Control.Monad.Trans (liftIO)-import Criterion.Config (Config, Verbosity(..), cfgSummaryFile, cfgVerbosity, fromLJ)-import Criterion.Monad (Criterion, getConfig, getConfigItem)-import Data.Monoid (getLast)+import Criterion.Monad (Criterion)+import Criterion.Types (Config(csvFile, verbosity), Verbosity(..))+import Data.Foldable (forM_) import System.IO (Handle, stderr, stdout)-import qualified Text.Printf (HPrintfType, hPrintf) import Text.Printf (PrintfArg)+import qualified Data.ByteString.Lazy as B+import qualified Data.Csv as Csv+import qualified Text.Printf (HPrintfType, hPrintf) -- First item is the action to print now, given all the arguments -- gathered together so far. The second item is the function that@@ -43,7 +46,7 @@ instance CritHPrintfType (Criterion a) where chPrintfImpl check (PrintfCont final _)- = do x <- getConfig+ = do x <- ask when (check x) (liftIO final) return undefined @@ -80,20 +83,19 @@ -- | Print a \"normal\" note. note :: (CritHPrintfType r) => String -> r-note = chPrintf ((> Quiet) . fromLJ cfgVerbosity) stdout+note = chPrintf ((> Quiet) . verbosity) stdout -- | Print verbose output. prolix :: (CritHPrintfType r) => String -> r-prolix = chPrintf ((== Verbose) . fromLJ cfgVerbosity) stdout+prolix = chPrintf ((== Verbose) . verbosity) stdout -- | Print an error message. printError :: (CritHPrintfType r) => String -> r printError = chPrintf (const True) stderr --- | Add to summary CSV (if applicable)-summary :: String -> Criterion ()-summary msg- = do sumOpt <- getConfigItem (getLast . cfgSummaryFile)- case sumOpt of- Just fn -> liftIO $ appendFile fn msg- Nothing -> return ()+-- | Write a record to a CSV file.+writeCsv :: Csv.ToRecord a => a -> Criterion ()+writeCsv val = do+ csv <- asks csvFile+ forM_ csv $ \fn ->+ liftIO . B.appendFile fn . Csv.encode $ [val]
Criterion/Internal.hs view
@@ -1,7 +1,7 @@ {-# LANGUAGE BangPatterns, RecordWildCards #-} -- | -- Module : Criterion--- Copyright : (c) 2009, 2010, 2011 Bryan O'Sullivan+-- Copyright : (c) 2009-2014 Bryan O'Sullivan -- -- License : BSD-style -- Maintainer : bos@serpentine.com@@ -12,117 +12,95 @@ module Criterion.Internal (- runBenchmark- , runAndAnalyse+ runAndAnalyse+ , runAndAnalyseOne , runNotAnalyse- , prefix+ , addPrefix ) where -import Control.Monad (foldM, replicateM_, when, mplus)+import Control.DeepSeq (rnf)+import Control.Exception (evaluate)+import Control.Monad (foldM, forM_, void, when)+import Control.Monad.Reader (ask, asks) import Control.Monad.Trans (liftIO)+import Control.Monad.Trans.Either import Data.Binary (encode)+import Data.Int (Int64) import qualified Data.ByteString.Lazy as L-import Criterion.Analysis (Outliers(..), OutlierEffect(..), OutlierVariance(..),- SampleAnalysis(..), analyseSample,- classifyOutliers, noteOutliers)-import Criterion.Config (Config(..), Verbosity(..), fromLJ)-import Criterion.Environment (Environment(..))-import Criterion.IO (header, hGetResults)-import Criterion.IO.Printf (note, prolix, summary)-import Criterion.Measurement (getTime, runForAtLeast, secs, time_)-import Criterion.Monad (Criterion, getConfig, getConfigItem)-import Criterion.Report (Report(..), report)-import Criterion.Types (Benchmark(..), Benchmarkable(..),- Result(..), ResultForest, ResultTree(..))-import qualified Data.Vector.Unboxed as U-import Data.Monoid (getLast)+import Criterion.Analysis (analyseSample, noteOutliers)+import Criterion.IO (header, hGetReports)+import Criterion.IO.Printf (note, printError, prolix, writeCsv)+import Criterion.Measurement (runBenchmark, secs)+import Criterion.Monad (Criterion)+import Criterion.Report (report)+import Criterion.Types hiding (measure)+import qualified Data.Map as Map import Statistics.Resampling.Bootstrap (Estimate(..))-import Statistics.Types (Sample) import System.Directory (getTemporaryDirectory, removeFile) import System.IO (IOMode(..), SeekMode(..), hClose, hSeek, openBinaryFile, openBinaryTempFile)-import System.Mem (performGC) import Text.Printf (printf) --- | Run a single benchmark, and return timings measured when--- executing it.-runBenchmark :: Benchmarkable b => Environment -> b -> Criterion Sample-runBenchmark env b = do- _ <- liftIO $ runForAtLeast 0.1 10000 (`replicateM_` getTime)- let minTime = envClockResolution env * 1000- (testTime, testIters, _) <- liftIO $ runForAtLeast (min minTime 0.1) 1 (run b)- _ <- prolix "ran %d iterations in %s\n" testIters (secs testTime)- cfg <- getConfig- let newIters = ceiling $ minTime * testItersD / testTime- sampleCount = fromLJ cfgSamples cfg- newItersD = fromIntegral newIters- testItersD = fromIntegral testIters- estTime = (fromIntegral sampleCount * newItersD *- testTime / testItersD)- when (fromLJ cfgVerbosity cfg > Normal || estTime > 5) $- note "collecting %d samples, %d iterations each, in estimated %s\n"- sampleCount newIters (secs estTime)- -- Run the GC to make sure garabage created by previous benchmarks- -- don't affect this benchmark.- liftIO performGC- times <- liftIO . fmap (U.map ((/ newItersD) . subtract (envClockCost env))) .- U.replicateM sampleCount $ do- when (fromLJ cfgPerformGC cfg) $ performGC- time_ (run b newIters)- return times- -- | Run a single benchmark and analyse its performance.-runAndAnalyseOne :: Benchmarkable b => Environment -> String -> b- -> Criterion (Sample,SampleAnalysis,Outliers)-runAndAnalyseOne env _desc b = do- times <- runBenchmark env b- ci <- getConfigItem $ fromLJ cfgConfInterval- numResamples <- getConfigItem $ fromLJ cfgResamples- _ <- prolix "analysing with %d resamples\n" numResamples- an@SampleAnalysis{..} <- liftIO $ analyseSample ci times numResamples- let OutlierVariance{..} = anOutlierVar- let wibble = case ovEffect of- Unaffected -> "unaffected" :: String- Slight -> "slightly inflated"- Moderate -> "moderately inflated"- Severe -> "severely inflated"- bs "mean" anMean- summary ","- bs "std dev" anStdDev- summary "\n"- vrb <- getConfigItem $ fromLJ cfgVerbosity- let out = classifyOutliers times- when (vrb == Verbose || (ovEffect > Unaffected && vrb > Quiet)) $ do- noteOutliers out- _ <- note "variance introduced by outliers: %.3f%%\n" (ovFraction * 100)- _ <- note "variance is %s by outliers\n" wibble- return ()- return (times,an,out)- where bs :: String -> Estimate -> Criterion ()- bs d e = do _ <- note "%s: %s, lb %s, ub %s, ci %.3f\n" d- (secs $ estPoint e)- (secs $ estLowerBound e) (secs $ estUpperBound e)- (estConfidenceLevel e)- summary $ printf "%g,%g,%g"- (estPoint e)- (estLowerBound e) (estUpperBound e)+runAndAnalyseOne :: Int -> String -> Benchmarkable -> Criterion Report+runAndAnalyseOne i desc bm = do+ Config{..} <- ask+ (meas,timeTaken) <- liftIO $ runBenchmark bm timeLimit+ when (timeTaken > timeLimit * 1.25) .+ void $ prolix "measurement took %s\n" (secs timeTaken)+ _ <- prolix "analysing with %d resamples\n" resamples+ erp <- runEitherT $ analyseSample i desc meas+ case erp of+ Left err -> printError "*** Error: %s\n" err+ Right rpt@Report{..} -> do+ let SampleAnalysis{..} = reportAnalysis+ OutlierVariance{..} = anOutlierVar+ wibble = case ovEffect of+ Unaffected -> "unaffected" :: String+ Slight -> "slightly inflated"+ Moderate -> "moderately inflated"+ Severe -> "severely inflated"+ (builtin, others) = splitAt 1 anRegress+ let r2 n = printf "%.3f R\178" n+ forM_ builtin $ \Regression{..} ->+ case Map.lookup "iters" regCoeffs of+ Nothing -> return ()+ Just t -> bs secs "time" t >> bs r2 "" regRSquare+ bs secs "mean" anMean+ bs secs "std dev" anStdDev+ forM_ others $ \Regression{..} -> do+ _ <- bs r2 (regResponder ++ ":") regRSquare+ forM_ (Map.toList regCoeffs) $ \(prd,val) ->+ bs (printf "%.3g") (" " ++ prd) val+ writeCsv (desc,+ estPoint anMean, estLowerBound anMean, estUpperBound anMean,+ estPoint anStdDev, estLowerBound anStdDev,+ estUpperBound anStdDev)+ when (verbosity == Verbose || (ovEffect > Slight && verbosity > Quiet)) $ do+ when (verbosity == Verbose) $ noteOutliers reportOutliers+ _ <- note "variance introduced by outliers: %d%% (%s)\n"+ (round (ovFraction * 100) :: Int) wibble+ return ()+ _ <- note "\n"+ return rpt+ where bs :: (Double -> String) -> String -> Estimate -> Criterion ()+ bs f metric Estimate{..} =+ note "%-20s %-10s (%s .. %s%s)\n" metric+ (f estPoint) (f estLowerBound) (f estUpperBound)+ (if estConfidenceLevel == 0.95 then ""+ else printf ", ci %.3f" estConfidenceLevel) -plotAll :: [Result] -> Criterion ()-plotAll descTimes = do- report (zipWith (\n (Result d t a o) -> Report n d t a o) [0..] descTimes)- -- | Run, and analyse, one or more benchmarks. runAndAnalyse :: (String -> Bool) -- ^ A predicate that chooses -- whether to run a benchmark by its -- name.- -> Environment -> Benchmark -> Criterion ()-runAndAnalyse p env bs' = do- mbResultFile <- getConfigItem $ getLast . cfgResults- (resultFile, handle) <- liftIO $- case mbResultFile of+runAndAnalyse p bs' = do+ mbRawFile <- asks rawDataFile+ (rawFile, handle) <- liftIO $+ case mbRawFile of Nothing -> do tmpDir <- getTemporaryDirectory openBinaryTempFile tmpDir "criterion.dat"@@ -131,116 +109,69 @@ return (file, handle) liftIO $ L.hPut handle header - let go !k (pfx, Benchmark desc b)- | p desc' = do _ <- note "\nbenchmarking %s\n" desc'- summary (show desc' ++ ",") -- String will be quoted- (x,an,out) <- runAndAnalyseOne env desc' b- let result = Single $ Result desc' x an out- liftIO $ L.hPut handle (encode result)+ let go !k (pfx, Environment mkenv mkbench) = do+ e <- liftIO $ do+ ee <- mkenv+ evaluate (rnf ee)+ return ee+ go k (pfx, mkbench e)+ go !k (pfx, Benchmark desc b)+ | p desc' = do _ <- note "benchmarking %s\n" desc'+ rpt <- runAndAnalyseOne k desc' b+ liftIO $ L.hPut handle (encode rpt) return $! k + 1 | otherwise = return (k :: Int)- where desc' = prefix pfx desc+ where desc' = addPrefix pfx desc go !k (pfx, BenchGroup desc bs) =- foldM go k [(prefix pfx desc, b) | b <- bs]- go !k (pfx, BenchCompare bs) = do- l <- foldM go 0 [(pfx, b) | b <- bs]- let result = Compare l []- liftIO $ L.hPut handle (encode result)- return $! l + k+ foldM go k [(addPrefix pfx desc, b) | b <- bs] _ <- go 0 ("", bs') - rts <- (either fail return =<<) . liftIO $ do+ rpts <- (either fail return =<<) . liftIO $ do hSeek handle AbsoluteSeek 0- rs <- hGetResults handle+ rs <- hGetReports handle hClose handle- case mbResultFile of+ case mbRawFile of Just _ -> return rs- _ -> removeFile resultFile >> return rs-- mbCompareFile <- getConfigItem $ getLast . cfgCompareFile- case mbCompareFile of- Nothing -> return ()- Just compareFile -> do- liftIO $ writeFile compareFile $ resultForestToCSV rts+ _ -> removeFile rawFile >> return rs - let rs = flatten rts- plotAll rs- junit rs+ report rpts+ junit rpts -runNotAnalyse :: (String -> Bool) -- ^ A predicate that chooses+-- | Run a benchmark without analysing its performance.+runNotAnalyse :: Int64 -- ^ Number of loop iterations to run.+ -> (String -> Bool) -- ^ A predicate that chooses -- whether to run a benchmark by its -- name. -> Benchmark -> Criterion ()-runNotAnalyse p bs' = goQuickly "" bs'+runNotAnalyse iters p bs' = goQuickly "" bs' where goQuickly :: String -> Benchmark -> Criterion ()+ goQuickly pfx (Environment mkenv mkbench) = do+ e <- liftIO mkenv+ goQuickly pfx (mkbench e) goQuickly pfx (Benchmark desc b) | p desc' = do _ <- note "benchmarking %s\n" desc' runOne b | otherwise = return ()- where desc' = prefix pfx desc+ where desc' = addPrefix pfx desc goQuickly pfx (BenchGroup desc bs) =- mapM_ (goQuickly (prefix pfx desc)) bs- goQuickly pfx (BenchCompare bs) = mapM_ (goQuickly pfx) bs-- runOne b = do- samples <- getConfigItem $ fromLJ cfgSamples- liftIO $ run b samples--prefix :: String -> String -> String-prefix "" desc = desc-prefix pfx desc = pfx ++ '/' : desc--flatten :: ResultForest -> [Result]-flatten [] = []-flatten (Single r : rs) = r : flatten rs-flatten (Compare _ crs : rs) = flatten crs ++ flatten rs--resultForestToCSV :: ResultForest -> String-resultForestToCSV = unlines- . ("Reference,Name,% faster than reference" :)- . map (\(ref, n, p) -> printf "%s,%s,%.0f" ref n p)- . top- where- top :: ResultForest -> [(String, String, Double)]- top [] = []- top (Single _ : rts) = top rts- top (Compare _ rts' : rts) = cmpRT rts' ++ top rts-- cmpRT :: ResultForest -> [(String, String, Double)]- cmpRT [] = []- cmpRT (Single r : rts) = cmpWith r rts- cmpRT (Compare _ rts' : rts) = case getReference rts' of- Nothing -> cmpRT rts- Just r -> cmpRT rts' ++ cmpWith r rts-- cmpWith :: Result -> ResultForest -> [(String, String, Double)]- cmpWith _ [] = []- cmpWith ref (Single r : rts) = cmp ref r : cmpWith ref rts- cmpWith ref (Compare _ rts' : rts) = cmpRT rts' ++- cmpWith ref rts' ++- cmpWith ref rts-- getReference :: ResultForest -> Maybe Result- getReference [] = Nothing- getReference (Single r : _) = Just r- getReference (Compare _ rts' : rts) = getReference rts' `mplus`- getReference rts--cmp :: Result -> Result -> (String, String, Double)-cmp ref r = (description ref, description r, percentFaster)- where- percentFaster = (meanRef - meanR) / meanRef * 100+ mapM_ (goQuickly (addPrefix pfx desc)) bs - meanRef = mean ref- meanR = mean r+ runOne (Benchmarkable run) = liftIO (run iters) - mean = estPoint . anMean . sampleAnalysis+-- | Add the given prefix to a name. If the prefix is empty, the name+-- is returned unmodified. Otherwise, the prefix and name are+-- separated by a @\'\/\'@ character.+addPrefix :: String -- ^ Prefix.+ -> String -- ^ Name.+ -> String+addPrefix "" desc = desc+addPrefix pfx desc = pfx ++ '/' : desc -- | Write summary JUnit file (if applicable)-junit :: [Result] -> Criterion ()+junit :: [Report] -> Criterion () junit rs- = do junitOpt <- getConfigItem (getLast . cfgJUnitFile)+ = do junitOpt <- asks junitFile case junitOpt of Just fn -> liftIO $ writeFile fn msg Nothing -> return ()@@ -250,8 +181,8 @@ (length rs) ++ concatMap single rs ++ "</testsuite>\n"- single r = printf " <testcase name=\"%s\" time=\"%f\" />\n"- (attrEsc $ description r) (estPoint $ anMean $ sampleAnalysis r)+ single Report{..} = printf " <testcase name=\"%s\" time=\"%f\" />\n"+ (attrEsc reportName) (estPoint $ anMean $ reportAnalysis) attrEsc = concatMap esc where esc '\'' = "'"
Criterion/Main.hs view
@@ -1,6 +1,6 @@ -- | -- Module : Criterion.Main--- Copyright : (c) 2009, 2010, 2011 Bryan O'Sullivan+-- Copyright : (c) 2009-2014 Bryan O'Sullivan -- -- License : BSD-style -- Maintainer : bos@serpentine.com@@ -25,151 +25,41 @@ -- $rnf -- * Types- Benchmarkable(..)+ Benchmarkable(run) , Benchmark- , Pure- -- * Constructing benchmarks+ -- * Creating a benchmark suite+ , env , bench , bgroup- , bcompare+ -- ** Running a benchmark , nf , whnf , nfIO , whnfIO- -- * Running benchmarks+ -- * Turning a suite of benchmarks into a program , defaultMain , defaultMainWith+ , defaultConfig -- * Other useful code , makeMatcher- , defaultOptions- , parseArgs ) where import Control.Monad (unless) import Control.Monad.Trans (liftIO)-import Criterion.Internal (runAndAnalyse, runNotAnalyse, prefix)-import Criterion.Config-import Criterion.Environment (measureEnvironment)-import Criterion.IO.Printf (note, printError)-import Criterion.Monad (Criterion, withConfig)-import Criterion.Types (Benchmarkable(..), Benchmark(..), Pure, bench,- benchNames, bgroup, bcompare, nf, nfIO, whnf, whnfIO)-import Data.Char (toLower)+import Criterion.IO.Printf (printError, writeCsv)+import Criterion.Internal (runAndAnalyse, runNotAnalyse, addPrefix)+import Criterion.Main.Options (MatchType(..), Mode(..), defaultConfig, describe,+ versionInfo)+import Criterion.Measurement (initializeTime)+import Criterion.Monad (withConfig)+import Criterion.Types import Data.List (isPrefixOf, sort, stripPrefix) import Data.Maybe (fromMaybe)-import Data.Monoid (Monoid(..), Last(..))-import System.Console.GetOpt-import System.Environment (getArgs, getProgName)+import Options.Applicative (execParser)+import System.Environment (getProgName) import System.Exit (ExitCode(..), exitWith) import System.FilePath.Glob --- | Parse a confidence interval.-ci :: String -> IO Config-ci s = case reads s' of- [(d,"%")] -> check (d/100)- [(d,"")] -> check d- _ -> parseError "invalid confidence interval provided"- where s' = case s of- ('.':_) -> '0':s- _ -> s- check d | d <= 0 = parseError "confidence interval is negative"- | d >= 1 = parseError "confidence interval is greater than 1"- | otherwise = return mempty { cfgConfInterval = ljust d }--matchType :: String -> IO Config-matchType s = case map toLower s of- "prefix" -> return mempty { cfgMatchType = ljust Prefix }- "glob" -> return mempty { cfgMatchType = ljust Glob }- _ -> parseError "match type is not 'glob' or 'prefix'"---- | Parse a positive number.-pos :: (Num a, Ord a, Read a) =>- String -> (Last a -> Config) -> String -> IO Config-pos q f s =- case reads s of- [(n,"")] | n > 0 -> return . f $ ljust n- | otherwise -> parseError $ q ++ " must be positive"- _ -> parseError $ "invalid " ++ q ++ " provided"--noArg :: Config -> ArgDescr (IO Config)-noArg = NoArg . return---- | The standard options accepted on the command line.-defaultOptions :: [OptDescr (IO Config)]-defaultOptions = [- Option ['h','?'] ["help"] (noArg mempty { cfgPrintExit = Help })- "print help, then exit"- , Option ['G'] ["no-gc"] (noArg mempty { cfgPerformGC = ljust False })- "do not collect garbage between iterations"- , Option ['g'] ["gc"] (noArg mempty { cfgPerformGC = ljust True })- "collect garbage between iterations (default)"- , Option ['I'] ["ci"] (ReqArg ci "CI")- "bootstrap confidence interval"- , Option ['l'] ["list"] (noArg mempty { cfgPrintExit = List })- "print only a list of benchmark names"- , Option ['m'] ["match"] (ReqArg matchType "MATCH")- "how to match benchmark names (prefix|glob)"- , Option ['o'] ["output"]- (ReqArg (\t -> return $ mempty { cfgReport = ljust t }) "FILENAME")- "report file to write to"- , Option ['q'] ["quiet"] (noArg mempty { cfgVerbosity = ljust Quiet })- "print less output"- , Option [] ["resamples"]- (ReqArg (pos "resample count"$ \n -> mempty { cfgResamples = n }) "N")- "number of bootstrap resamples to perform"- , Option [] ["results"]- (ReqArg (\n -> return $ mempty { cfgResults = ljust n }) "FILENAME")- "file to write raw results to"- , Option ['s'] ["samples"]- (ReqArg (pos "sample count" $ \n -> mempty { cfgSamples = n }) "N")- "number of samples to collect"- , Option ['t'] ["template"]- (ReqArg (\t -> return $ mempty { cfgTemplate = ljust t }) "FILENAME")- "template file to use"- , Option ['u'] ["summary"] (ReqArg (\s -> return $ mempty { cfgSummaryFile = ljust s }) "FILENAME")- "produce a summary CSV file of all results"- , Option ['r'] ["compare"] (ReqArg (\s -> return $ mempty { cfgCompareFile = ljust s }) "FILENAME")- "produce a CSV file of comparisons\nagainst reference benchmarks\n\- \(see the bcompare combinator)"- , Option ['n'] ["no-measurements"] (noArg mempty { cfgMeasure = ljust False })- "don't do any measurements"- , Option ['V'] ["version"] (noArg mempty { cfgPrintExit = Version })- "display version, then exit"- , Option ['v'] ["verbose"] (noArg mempty { cfgVerbosity = ljust Verbose })- "print more output"- , Option [] ["junit"] (ReqArg (\s -> return $ mempty { cfgJUnitFile = ljust s }) "FILENAME")- "produce a JUnit report file of all results"- ]--printBanner :: Config -> IO ()-printBanner cfg = withConfig cfg $- case cfgBanner cfg of- Last (Just b) -> note "%s\n" b- _ -> note "Hey, nobody told me what version I am!\n"--printUsage :: [OptDescr (IO Config)] -> ExitCode -> IO a-printUsage options exitCode = do- p <- getProgName- putStr (usageInfo ("Usage: " ++ p ++ " [OPTIONS] [BENCHMARKS]") options)- putStrLn "If no benchmark names are given, all are run\n\- \Otherwise, benchmarks are chosen by prefix or zsh-style pattern \- \match\n\- \(use --match to specify how to match the benchmarks to run)"- exitWith exitCode---- | Parse command line options.-parseArgs :: Config -> [OptDescr (IO Config)] -> [String]- -> IO (Config, [String])-parseArgs defCfg options args =- case getOpt Permute options args of- (_, _, (err:_)) -> parseError err- (opts, rest, _) -> do- cfg <- (mappend defCfg . mconcat) `fmap` sequence opts- case cfgPrintExit cfg of- Help -> printBanner cfg >> printUsage options ExitSuccess- Version -> printBanner cfg >> exitWith ExitSuccess- _ -> return (cfg, rest)- -- | An entry point that can be used as a @main@ function. -- -- > import Criterion.Main@@ -186,9 +76,14 @@ -- > ] -- > ] defaultMain :: [Benchmark] -> IO ()-defaultMain = defaultMainWith defaultConfig (return ())+defaultMain = defaultMainWith defaultConfig -makeMatcher :: MatchType -> [String] -> Either String (String -> Bool)+-- | Create a function that can tell if a name given on the command+-- line matches a benchmark.+makeMatcher :: MatchType+ -> [String]+ -- ^ Command line arguments.+ -> Either String (String -> Bool) makeMatcher matchKind args = case matchKind of Prefix -> Right $ \b -> null args || any (`isPrefixOf` b) args@@ -199,20 +94,30 @@ errMsg Right ps -> Right $ \b -> null ps || any (`match` b) ps +selectBenches :: MatchType -> [String] -> Benchmark -> IO (String -> Bool)+selectBenches matchType benches bsgroup = do+ let go pfx (Environment _ b) = go pfx (b undefined)+ go pfx (BenchGroup pfx' bms) = concatMap (go (addPrefix pfx pfx')) bms+ go pfx (Benchmark desc _) = [addPrefix pfx desc]+ toRun <- either parseError return . makeMatcher matchType $ benches+ unless (null benches || any toRun (go "" bsgroup)) $+ parseError "none of the specified names matches a benchmark"+ return toRun+ -- | An entry point that can be used as a @main@ function, with -- configurable defaults. -- -- Example: ----- > import Criterion.Config+-- > import Criterion.Main.Options -- > import Criterion.Main -- > -- > myConfig = defaultConfig {--- > -- Always GC between runs.--- > cfgPerformGC = ljust True+-- > -- Do not GC between runs.+-- > forceGC = False -- > } -- >--- > main = defaultMainWith myConfig (return ()) [+-- > main = defaultMainWith myConfig [ -- > bench "fib 30" $ whnf fib 30 -- > ] --@@ -224,37 +129,25 @@ -- Run @\"Fib --help\"@ on the command line to get a list of command -- line options. defaultMainWith :: Config- -> Criterion () -- ^ Prepare data prior to executing the first benchmark. -> [Benchmark] -> IO ()-defaultMainWith defCfg prep bs = do- (cfg, args) <- parseArgs defCfg defaultOptions =<< getArgs- shouldRun <- either parseError return .- makeMatcher (fromMaybe Prefix . getLast . cfgMatchType $ cfg) $- args- unless (null args || any shouldRun (names bsgroup)) $- parseError "none of the specified names matches a benchmark"- withConfig cfg $- if not $ fromLJ cfgMeasure cfg- then runNotAnalyse shouldRun bsgroup- else do- if cfgPrintExit cfg == List- then do- _ <- note "Benchmarks:\n"- mapM_ (note " %s\n") (sort $ concatMap benchNames bs)- else do- case getLast $ cfgSummaryFile cfg of- Just fn -> liftIO $ writeFile fn "Name,Mean,MeanLB,MeanUB,Stddev,StddevLB,StddevUB\n"- Nothing -> return ()- env <- measureEnvironment- prep- runAndAnalyse shouldRun env bsgroup- where- bsgroup = BenchGroup "" bs- names = go ""- where go pfx (BenchGroup pfx' bms) = concatMap (go (prefix pfx pfx')) bms- go pfx (Benchmark desc _) = [prefix pfx desc]- go _ (BenchCompare _) = []+defaultMainWith defCfg bs = do+ wat <- execParser (describe defCfg)+ let bsgroup = BenchGroup "" bs+ case wat of+ List -> mapM_ putStrLn . sort . concatMap benchNames $ bs+ Version -> putStrLn versionInfo+ OnlyRun iters matchType benches -> do+ shouldRun <- selectBenches matchType benches bsgroup+ withConfig defaultConfig $+ runNotAnalyse iters shouldRun bsgroup+ Run cfg matchType benches -> do+ shouldRun <- selectBenches matchType benches bsgroup+ withConfig cfg $ do+ writeCsv ("Name","Mean","MeanLB","MeanUB","Stddev","StddevLB",+ "StddevUB")+ liftIO initializeTime+ runAndAnalyse shouldRun bsgroup -- | Display an error message from a command line parsing failure, and -- exit.@@ -266,9 +159,10 @@ -- $bench ----- The 'Benchmarkable' typeclass represents the class of all code that--- can be benchmarked. Every instance must run a benchmark a given--- number of times. We are most interested in benchmarking two things:+-- The 'Benchmarkable' type is a container for code that can be+-- benchmarked. The value inside must run a benchmark the given+-- number of times. We are most interested in benchmarking two+-- things: -- -- * 'IO' actions. Any 'IO' action can be benchmarked directly. --@@ -294,22 +188,21 @@ -- only be evaluated once, for which all but the first iteration of -- the timing loop will be timing the cost of doing nothing. ----- To work around this, we provide a special type, 'Pure', for--- benchmarking pure code. Values of this type are constructed using--- one of two functions.+-- To work around this, we provide two functions for benchmarking pure+-- code. ----- The first is a function which will cause results to be evaluated to--- head normal form (NF):+-- The first will cause results to be fully evaluated to normal form+-- (NF): -- -- @--- 'nf' :: 'NFData' b => (a -> b) -> a -> 'Pure'+-- 'nf' :: 'NFData' b => (a -> b) -> a -> 'Benchmarkable' -- @ -- -- The second will cause results to be evaluated to weak head normal -- form (the Haskell default): -- -- @--- 'whnf' :: (a -> b) -> a -> 'Pure'+-- 'whnf' :: (a -> b) -> a -> 'Benchmarkable' -- @ -- -- As both of these types suggest, when you want to benchmark a@@ -333,9 +226,6 @@ -- @ -- 'nf' firstN 1000 -- @------ The compiler will correctly infer that the number 1000 must have--- the type 'Int', and the type of the expression is 'Pure'. -- $rnf --@@ -352,6 +242,7 @@ -- 'whnf' firstN 1000 -- @ ----- Because in this case the result will only be forced until it--- reaches WHNF, what this would /actually/ benchmark is merely the--- production of the first list element!+-- Since we are using 'whnf', in this case the result will only be+-- forced until it reaches WHNF, so what this would /actually/+-- benchmark is merely how long it takes to produce the first list+-- element!
+ Criterion/Main/Options.hs view
@@ -0,0 +1,184 @@+{-# LANGUAGE DeriveDataTypeable, DeriveGeneric, RecordWildCards #-}++-- |+-- Module : Criterion.Main.Options+-- Copyright : (c) 2014 Bryan O'Sullivan+--+-- License : BSD-style+-- Maintainer : bos@serpentine.com+-- Stability : experimental+-- Portability : GHC+--+-- Benchmarking command-line configuration.++module Criterion.Main.Options+ (+ Mode(..)+ , MatchType(..)+ , defaultConfig+ , parseWith+ , describe+ , versionInfo+ ) where++import Control.Monad (when)+import Criterion.Analysis (validateAccessors)+import Criterion.Types (Config(..), Verbosity(..), measureAccessors,+ measureKeys)+import Data.Char (isSpace, toLower)+import Data.Data (Data, Typeable)+import Data.Int (Int64)+import Data.List (isPrefixOf)+import Data.Monoid (mempty)+import Data.Version (showVersion)+import GHC.Generics (Generic)+import Options.Applicative+import Options.Applicative.Help (Chunk(..), tabulate)+import Options.Applicative.Help.Pretty ((.$.))+import Options.Applicative.Types+import Paths_criterion (version)+import Text.PrettyPrint.ANSI.Leijen (Doc, text)+import qualified Data.Map as M++-- | How to match a benchmark name.+data MatchType = Prefix+ -- ^ Match by prefix. For example, a prefix of+ -- @\"foo\"@ will match @\"foobar\"@.+ | Glob+ -- ^ Match by Unix-style glob pattern.+ deriving (Eq, Ord, Bounded, Enum, Read, Show, Typeable, Data,+ Generic)++-- | Execution mode for a benchmark program.+data Mode = List+ -- ^ List all benchmarks.+ | Version+ -- ^ Print the version.+ | OnlyRun Int64 MatchType [String]+ -- ^ Run the given benchmarks, without collecting or+ -- analysing performance numbers.+ | Run Config MatchType [String]+ -- ^ Run and analyse the given benchmarks.+ deriving (Eq, Read, Show, Typeable, Data, Generic)++-- | Default benchmarking configuration.+defaultConfig :: Config+defaultConfig = Config {+ confInterval = 0.95+ , forceGC = True+ , timeLimit = 5+ , resamples = 1000+ , regressions = []+ , rawDataFile = Nothing+ , reportFile = Nothing+ , csvFile = Nothing+ , junitFile = Nothing+ , verbosity = Normal+ , template = "default"+ }++-- | Parse a command line.+parseWith :: Config+ -- ^ Default configuration to use if options are not+ -- explicitly specified.+ -> Parser Mode+parseWith cfg =+ (matchNames (Run <$> config cfg)) <|>+ onlyRun <|>+ (List <$ switch (long "list" <> short 'l' <> help "list benchmarks")) <|>+ (Version <$ switch (long "version" <> help "show version info"))+ where+ onlyRun = matchNames $+ OnlyRun <$> option (long "only-run" <> short 'n' <> metavar "ITERS" <>+ help "run benchmarks, don't analyse")+ matchNames wat = wat+ <*> option (long "match" <> short 'm' <> metavar "MATCH" <>+ value Prefix <> reader match <>+ help "how to match benchmark names")+ <*> many (argument str (metavar "NAME..."))++config :: Config -> Parser Config+config Config{..} = Config+ <$> option (long "ci" <> short 'I' <> metavar "CI" <> value confInterval <>+ reader (range 0.001 0.999) <>+ help "confidence interval")+ <*> (not <$> switch (long "no-gc" <> short 'G' <>+ help "do not collect garbage between iterations"))+ <*> option (long "time-limit" <> short 'L' <> metavar "SECS" <>+ value timeLimit <> reader (range 0.1 86400) <>+ help "time limit to run a benchmark")+ <*> option (long "resamples" <> metavar "COUNT" <> value resamples <>+ reader (range 1 1000000) <>+ help "number of bootstrap resamples to perform")+ <*> many (option (long "regress" <> metavar "RESP:PRED.." <>+ reader regressParams <>+ help "regressions to perform"))+ <*> outputOption rawDataFile (long "raw" <>+ help "file to write raw data to")+ <*> outputOption reportFile (long "output" <> short 'o' <>+ help "file to write report to")+ <*> outputOption csvFile (long "csv" <>+ help "file to write CSV summary to")+ <*> outputOption junitFile (long "junit" <>+ help "file to write JUnit summary to")+ <*> (toEnum <$> option (long "verbosity" <> short 'v' <> metavar "LEVEL" <>+ value (fromEnum verbosity) <> reader (range 0 2) <>+ help "verbosity level"))+ <*> strOption (long "template" <> short 't' <> metavar "FILE" <>+ value template <>+ help "template to use for report")++outputOption :: Maybe String -> Mod OptionFields String -> Parser (Maybe String)+outputOption file m =+ optional (strOption (m <> metavar "FILE" <> maybe mempty value file))++range :: (Show a, Read a, Ord a) => a -> a -> String -> ReadM a+range lo hi s =+ case reads s of+ [(i, "")]+ | i >= lo && i <= hi -> return i+ | otherwise -> readerError $ show i ++ " is outside range " +++ show (lo,hi)+ _ -> readerError $ show s ++ " is not a number"++match :: String -> ReadM MatchType+match m+ | mm `isPrefixOf` "pfx" = return Prefix+ | mm `isPrefixOf` "prefix" = return Prefix+ | mm `isPrefixOf` "glob" = return Glob+ | otherwise = readerError $+ show m ++ " is not a known match type"+ where mm = map toLower m++regressParams :: String -> ReadM ([String], String)+regressParams m = do+ let repl ',' = ' '+ repl c = c+ tidy = reverse . dropWhile isSpace . reverse . dropWhile isSpace+ (r,ps) = break (==':') m+ when (null r) $+ readerError "no responder specified"+ when (null ps) $+ readerError "no predictors specified"+ let ret = (words . map repl . drop 1 $ ps, tidy r)+ either readerError (ReadM . Right . const ()) $ uncurry validateAccessors ret+ return ret++-- | Flesh out a command line parser.+describe :: Config -> ParserInfo Mode+describe cfg = info (helper <*> parseWith cfg) $+ header ("Microbenchmark suite - " <> versionInfo) <>+ fullDesc <>+ footerDoc (unChunk regressionHelp)++-- | A string describing the version of this benchmark (really, the+-- version of criterion that was used to build it).+versionInfo :: String+versionInfo = "built with criterion " <> showVersion version++-- We sort not by name, but by likely frequency of use.+regressionHelp :: Chunk Doc+regressionHelp =+ fmap (text "Regression metrics (for use with --regress):" .$.) $+ tabulate [(text n,text d) | (n,(_,d)) <- map f measureKeys]+ where f k = (k, measureAccessors M.! k)
Criterion/Measurement.hs view
@@ -1,8 +1,8 @@-{-# LANGUAGE BangPatterns, ScopedTypeVariables, TypeOperators #-}+{-# LANGUAGE BangPatterns, ForeignFunctionInterface, ScopedTypeVariables #-} -- | -- Module : Criterion.Measurement--- Copyright : (c) 2009, 2010 Bryan O'Sullivan+-- Copyright : (c) 2009-2014 Bryan O'Sullivan -- -- License : BSD-style -- Maintainer : bos@serpentine.com@@ -13,62 +13,189 @@ module Criterion.Measurement (- getTime- , runForAtLeast+ initializeTime+ , getTime+ , getCPUTime+ , getCycles+ , getGCStats , secs- , time- , time_+ , measure+ , runBenchmark+ , measured+ , applyGCStats+ , threshold ) where -import Control.Monad (when)-import Data.Time.Clock.POSIX (getPOSIXTime)+import Criterion.Types (Benchmarkable(..), Measured(..))+import Data.Int (Int64)+import Data.List (unfoldr)+import Data.Word (Word64)+import GHC.Stats (GCStats(..))+import System.Mem (performGC) import Text.Printf (printf)+import qualified Control.Exception as Exc+import qualified Data.Vector as V+import qualified GHC.Stats as Stats -time :: IO a -> IO (Double, a)-time act = do- start <- getTime- result <- act- end <- getTime- let !delta = end - start- return (delta, result)+-- | Try to get GC statistics, bearing in mind that the GHC runtime+-- will throw an exception if statistics collection was not enabled+-- using \"@+RTS -T@\".+getGCStats :: IO (Maybe GCStats)+getGCStats =+ (Just `fmap` Stats.getGCStats) `Exc.catch` \(_::Exc.SomeException) ->+ return Nothing -time_ :: IO a -> IO Double-time_ act = do- start <- getTime- _ <- act- end <- getTime- return $! end - start+-- | Measure the execution of a benchmark a given number of times.+measure :: Benchmarkable -- ^ Operation to benchmark.+ -> Int64 -- ^ Number of iterations.+ -> IO (Measured, Double)+measure (Benchmarkable run) iters = do+ startStats <- getGCStats+ startTime <- getTime+ startCpuTime <- getCPUTime+ startCycles <- getCycles+ run iters+ endTime <- getTime+ endCpuTime <- getCPUTime+ endCycles <- getCycles+ endStats <- getGCStats+ let !m = applyGCStats endStats startStats $ measured {+ measTime = max 0 (endTime - startTime)+ , measCpuTime = max 0 (endCpuTime - startCpuTime)+ , measCycles = max 0 (fromIntegral (endCycles - startCycles))+ , measIters = iters+ }+ return (m, endTime)+{-# INLINE measure #-} -getTime :: IO Double-getTime = realToFrac `fmap` getPOSIXTime+-- | The amount of time a benchmark must run for in order for us to+-- have some trust in the raw measurement.+--+-- We set this threshold so that we can generate enough data to later+-- perform meaningful statistical analyses.+--+-- The threshold is 30 milliseconds. One use of 'runBenchmark' must+-- accumulate more than 300 milliseconds of total measurements above+-- this threshold before it will finish.+threshold :: Double+threshold = 0.03+{-# INLINE threshold #-} -runForAtLeast :: Double -> Int -> (Int -> IO a) -> IO (Double, Int, a)-runForAtLeast howLong initSeed act = loop initSeed (0::Int) =<< getTime- where- loop !seed !iters initTime = do- now <- getTime- when (now - initTime > howLong * 10) $- fail (printf "took too long to run: seed %d, iters %d" seed iters)- (elapsed,result) <- time (act seed)- if elapsed < howLong- then loop (seed * 2) (iters+1) initTime- else return (elapsed, seed, result)+-- | Run a single benchmark, and return measurements collected while+-- executing it, along with the amount of time the measurement process+-- took.+runBenchmark :: Benchmarkable+ -> Double+ -- ^ Lower bound on how long the benchmarking process+ -- should take. In practice, this time limit may be+ -- exceeded in order to generate enough data to perform+ -- meaningful statistical analyses.+ -> IO (V.Vector Measured, Double)+runBenchmark bm@(Benchmarkable run) timeLimit = do+ run 1+ start <- performGC >> getTime+ let loop [] !_ !_ _ = error "unpossible!"+ loop (iters:niters) prev count acc = do+ (m, endTime) <- measure bm iters+ let overThresh = max 0 (measTime m - threshold) + prev+ -- We try to honour the time limit, but we also have more+ -- important constraints:+ --+ -- We must generate enough data that bootstrapping won't+ -- simply crash.+ --+ -- We need to generate enough measurements that have long+ -- spans of execution to outweigh the (rather high) cost of+ -- measurement.+ if endTime - start >= timeLimit &&+ overThresh > threshold * 10 &&+ count >= (4 :: Int)+ then do+ let !v = V.reverse (V.fromList acc)+ return (v, endTime - start)+ else loop niters overThresh (count+1) (m:acc)+ loop (squish (unfoldr series 1)) 0 0 [] +-- Our series starts its growth very slowly when we begin at 1, so we+-- eliminate repeated values.+squish :: (Eq a) => [a] -> [a]+squish ys = foldr go [] ys+ where go x xs = x : dropWhile (==x) xs++series :: Double -> Maybe (Int64, Double)+series k = Just (truncate l, l)+ where l = k * 1.05++-- | An empty structure.+measured :: Measured+measured = Measured {+ measTime = 0+ , measCpuTime = 0+ , measCycles = 0+ , measIters = 0++ , measAllocated = minBound+ , measNumGcs = minBound+ , measBytesCopied = minBound+ , measMutatorWallSeconds = bad+ , measMutatorCpuSeconds = bad+ , measGcWallSeconds = bad+ , measGcCpuSeconds = bad+ } where bad = -1/0++-- | Apply the difference between two sets of GC statistics to a+-- measurement.+applyGCStats :: Maybe GCStats+ -- ^ Statistics gathered at the __end__ of a run.+ -> Maybe GCStats+ -- ^ Statistics gathered at the __beginning__ of a run.+ -> Measured+ -- ^ Value to \"modify\".+ -> Measured+applyGCStats (Just end) (Just start) m = m {+ measAllocated = diff bytesAllocated+ , measNumGcs = diff numGcs+ , measBytesCopied = diff bytesCopied+ , measMutatorWallSeconds = diff mutatorWallSeconds+ , measMutatorCpuSeconds = diff mutatorCpuSeconds+ , measGcWallSeconds = diff gcWallSeconds+ , measGcCpuSeconds = diff gcCpuSeconds+ } where diff f = f end - f start+applyGCStats _ _ m = m++-- | Convert a number of seconds to a string. The string will consist+-- of four decimal places, followed by a short description of the time+-- units. secs :: Double -> String secs k | k < 0 = '-' : secs (-k) | k >= 1 = k `with` "s" | k >= 1e-3 = (k*1e3) `with` "ms"- | k >= 1e-6 = (k*1e6) `with` "us"+ | k >= 1e-6 = (k*1e6) `with` "μs" | k >= 1e-9 = (k*1e9) `with` "ns" | k >= 1e-12 = (k*1e12) `with` "ps"+ | k >= 1e-15 = (k*1e15) `with` "fs"+ | k >= 1e-18 = (k*1e18) `with` "as" | otherwise = printf "%g s" k where with (t :: Double) (u :: String) | t >= 1e9 = printf "%.4g %s" t u- | t >= 1e6 = printf "%.0f %s" t u- | t >= 1e5 = printf "%.1f %s" t u- | t >= 1e4 = printf "%.2f %s" t u- | t >= 1e3 = printf "%.3f %s" t u- | t >= 1e2 = printf "%.4f %s" t u- | t >= 1e1 = printf "%.5f %s" t u- | otherwise = printf "%.6f %s" t u+ | t >= 1e3 = printf "%.0f %s" t u+ | t >= 1e2 = printf "%.1f %s" t u+ | t >= 1e1 = printf "%.2f %s" t u+ | otherwise = printf "%.3f %s" t u++-- | Set up time measurement.+foreign import ccall unsafe "criterion_inittime" initializeTime :: IO ()++-- | Read the CPU cycle counter.+foreign import ccall unsafe "criterion_rdtsc" getCycles :: IO Word64++-- | Return the current wallclock time, in seconds since some+-- arbitrary time.+--+-- You /must/ call 'initializeTime' once before calling this function!+foreign import ccall unsafe "criterion_gettime" getTime :: IO Double++-- | Return the amount of elapsed CPU time, combining user and kernel+-- (system) time into a single measure.+foreign import ccall unsafe "criterion_getcputime" getCPUTime :: IO Double
Criterion/Monad.hs view
@@ -1,4 +1,3 @@-{-# LANGUAGE GeneralizedNewtypeDeriving #-} -- | -- Module : Criterion.Monad -- Copyright : (c) 2009 Neil Brown@@ -12,25 +11,63 @@ module Criterion.Monad ( Criterion- , getConfig- , getConfigItem , withConfig+ , getGen+ , getOverhead ) where -import Control.Monad.Reader (MonadReader, ReaderT, ask, runReaderT)-import Control.Monad.Trans (MonadIO)-import Criterion.Config (Config)+import Control.Monad.Reader (asks, runReaderT)+import Control.Monad.Trans (liftIO)+import Control.Monad (when)+import Criterion.Measurement (measure, runBenchmark, secs)+import Criterion.Monad.Internal (Criterion(..), Crit(..))+import Criterion.Types hiding (measure)+import Data.IORef (IORef, newIORef, readIORef, writeIORef)+import Statistics.Regression (olsRegress)+import System.Random.MWC (GenIO, createSystemRandom)+import qualified Data.Vector.Generic as G --- | The monad in which most criterion code executes.-newtype Criterion a = Criterion {- runCriterion :: ReaderT Config IO a- } deriving (Functor, Monad, MonadReader Config, MonadIO)+-- | Run a 'Criterion' action with the given 'Config'.+withConfig :: Config -> Criterion a -> IO a+withConfig cfg (Criterion act) = do+ g <- newIORef Nothing+ o <- newIORef Nothing+ runReaderT act (Crit cfg g o) -getConfig :: Criterion Config-getConfig = ask+-- | Return a random number generator, creating one if necessary.+--+-- This is not currently thread-safe, but in a harmless way (we might+-- call 'createSystemRandom' more than once if multiple threads race).+getGen :: Criterion GenIO+getGen = memoise gen createSystemRandom -getConfigItem :: (Config -> a) -> Criterion a-getConfigItem f = f `fmap` getConfig+-- | Return an estimate of the measurement overhead.+getOverhead :: Criterion Double+getOverhead = do+ verbose <- asks ((== Verbose) . verbosity)+ memoise overhead $ do+ (meas,_) <- runBenchmark (whnfIO $ measure (whnfIO $ return ()) 1) 1+ let metric get = G.convert . G.map get $ meas+ let o = G.head . fst $+ olsRegress [metric (fromIntegral . measIters)] (metric measTime)+ when verbose . liftIO $+ putStrLn $ "measurement overhead " ++ secs o+ return o -withConfig :: Config -> Criterion a -> IO a-withConfig = flip (runReaderT . runCriterion)+-- | Memoise the result of an 'IO' action.+--+-- This is not currently thread-safe, but hopefully in a harmless way.+-- We might call the given action more than once if multiple threads+-- race, so our caller's job is to write actions that can be run+-- multiple times safely.+memoise :: (Crit -> IORef (Maybe a)) -> IO a -> Criterion a+memoise ref generate = do+ r <- Criterion $ asks ref+ liftIO $ do+ mv <- readIORef r+ case mv of+ Just rv -> return rv+ Nothing -> do+ rv <- generate+ writeIORef r (Just rv)+ return rv
+ Criterion/Monad/Internal.hs view
@@ -0,0 +1,41 @@+{-# LANGUAGE GeneralizedNewtypeDeriving, MultiParamTypeClasses #-}+{-# OPTIONS_GHC -funbox-strict-fields #-}++-- |+-- Module : Criterion.Monad.Internal+-- Copyright : (c) 2009 Neil Brown+--+-- License : BSD-style+-- Maintainer : bos@serpentine.com+-- Stability : experimental+-- Portability : GHC+--+-- The environment in which most criterion code executes.+module Criterion.Monad.Internal+ (+ Criterion(..)+ , Crit(..)+ ) where++import Control.Applicative (Applicative)+import Control.Monad.Reader (MonadReader(..), ReaderT)+import Control.Monad.Trans (MonadIO)+import Criterion.Types (Config)+import Data.IORef (IORef)+import System.Random.MWC (GenIO)++data Crit = Crit {+ config :: !Config+ , gen :: !(IORef (Maybe GenIO))+ , overhead :: !(IORef (Maybe Double))+ }++-- | The monad in which most criterion code executes.+newtype Criterion a = Criterion {+ runCriterion :: ReaderT Crit IO a+ } deriving (Functor, Applicative, Monad, MonadIO)++instance MonadReader Config Criterion where+ ask = config `fmap` Criterion ask+ local f = Criterion . local fconfig . runCriterion+ where fconfig c = c { config = f (config c) }
Criterion/Report.hs view
@@ -3,7 +3,7 @@ -- | -- Module : Criterion.Report--- Copyright : (c) 2011 Bryan O'Sullivan+-- Copyright : (c) 2009-2014 Bryan O'Sullivan -- -- License : BSD-style -- Maintainer : bos@serpentine.com@@ -14,14 +14,14 @@ module Criterion.Report (- Report(..)- , formatReport+ formatReport , report+ , tidyTails -- * Rendering helper functions , TemplateException(..) , loadTemplate , includeFile- , templateDir+ , getTemplateDir , vector , vector2 ) where@@ -29,53 +29,56 @@ import Control.Exception (Exception, IOException, throwIO) import Control.Monad (mplus) import Control.Monad.IO.Class (MonadIO(liftIO))-import Criterion.Analysis (Outliers(..), SampleAnalysis(..))-import Criterion.Config (cfgReport, cfgTemplate, fromLJ)-import Criterion.Monad (Criterion, getConfig)+import Control.Monad.Reader (ask)+import Criterion.Monad (Criterion)+import Criterion.Types+import Data.Aeson.Encode (encodeToTextBuilder)+import Data.Aeson.Types (toJSON) import Data.Data (Data, Typeable)-import Data.Monoid (Last(..))+import Data.Foldable (forM_) import GHC.Generics (Generic) import Paths_criterion (getDataFileName)-import Statistics.Sample.KernelDensity (kde)-import Statistics.Types (Sample)+import Statistics.Function (minMax) import System.Directory (doesFileExist)-import System.FilePath ((</>), isPathSeparator)-import System.IO.Unsafe (unsafePerformIO)+import System.FilePath ((</>), (<.>), isPathSeparator) import Text.Hastache (MuType(..)) import Text.Hastache.Context (mkGenericContext, mkStrContext, mkStrContextM) import qualified Control.Exception as E import qualified Data.Text as T import qualified Data.Text.IO as T import qualified Data.Text.Lazy as TL+import qualified Data.Text.Lazy.Builder as TL import qualified Data.Text.Lazy.IO as TL import qualified Data.Vector.Generic as G import qualified Data.Vector.Unboxed as U import qualified Text.Hastache as H -data Report = Report {- reportNumber :: Int- , reportName :: String- , reportTimes :: Sample- , reportAnalysis :: SampleAnalysis- , reportOutliers :: Outliers- } deriving (Eq, Read, Show, Typeable, Data, Generic)+-- | Trim long flat tails from a KDE plot.+tidyTails :: KDE -> KDE+tidyTails KDE{..} = KDE { kdeType = kdeType+ , kdeValues = G.slice front winSize kdeValues+ , kdePDF = G.slice front winSize kdePDF+ }+ where tiny = uncurry subtract (minMax kdePDF) * 0.005+ omitTiny = G.length . G.takeWhile ((<= tiny) . abs)+ front = omitTiny kdePDF+ back = omitTiny . G.reverse $ kdePDF+ winSize = G.length kdePDF - front - back --- | The path to the template and other files used for generating--- reports.-templateDir :: FilePath-templateDir = unsafePerformIO $ getDataFileName "templates"-{-# NOINLINE templateDir #-}+-- | Return the path to the template and other files used for+-- generating reports.+getTemplateDir :: IO FilePath+getTemplateDir = getDataFileName "templates" -- | Write out a series of 'Report' values to a single file, if -- configured to do so. report :: [Report] -> Criterion () report reports = do- cfg <- getConfig- case cfgReport cfg of- Last Nothing -> return ()- Last (Just name) -> liftIO $ do- tpl <- loadTemplate [".",templateDir] (fromLJ cfgTemplate cfg)- TL.writeFile name =<< formatReport reports tpl+ Config{..} <- ask+ forM_ reportFile $ \name -> liftIO $ do+ td <- getTemplateDir+ tpl <- loadTemplate [td,"."] template+ TL.writeFile name =<< formatReport reports tpl -- | Format a series of 'Report' values using the given Hastache -- template.@@ -83,23 +86,38 @@ -> T.Text -- ^ Hastache template. -> IO TL.Text formatReport reports template = do+ templates <- getTemplateDir let context "report" = return $ MuList $ map inner reports- context "include" = return $ MuLambdaM $ includeFile [templateDir]+ context "json" = return $ MuVariable (encode reports)+ context "include" = return $ MuLambdaM $ includeFile [templates] context _ = return $ MuNothing- inner Report{..} = mkStrContextM $ \nym ->+ encode v = TL.toLazyText . encodeToTextBuilder . toJSON $ v+ inner r@Report{..} = mkStrContextM $ \nym -> case nym of- "name" -> return $ MuVariable reportName+ "name" -> return . MuVariable . H.htmlEscape .+ TL.pack $ reportName+ "json" -> return $ MuVariable (encode r) "number" -> return $ MuVariable reportNumber- "times" -> return $ vector "x" reportTimes- "kdetimes" -> return $ vector "x" kdeTimes+ "iters" -> return $ vector "x" iters+ "times" -> return $ vector "x" times+ "cycles" -> return $ vector "x" cycles+ "kdetimes" -> return $ vector "x" kdeValues "kdepdf" -> return $ vector "x" kdePDF- "kde" -> return $ vector2 "time" "pdf" kdeTimes kdePDF+ "kde" -> return $ vector2 "time" "pdf" kdeValues kdePDF ('a':'n':_)-> mkGenericContext reportAnalysis $ H.encodeStr nym _ -> mkGenericContext reportOutliers $ H.encodeStr nym- where (kdeTimes,kdePDF) = kde 128 reportTimes- H.hastacheStr H.defaultConfig template context+ where [KDE{..}] = reportKDEs+ iters = measure measIters reportMeasured+ times = measure measTime reportMeasured+ cycles = measure measCycles reportMeasured+ config = H.defaultConfig {+ H.muEscapeFunc = H.emptyEscape+ , H.muTemplateFileDir = Just templates+ , H.muTemplateFileExt = Just ".tpl"+ }+ H.hastacheStr config template context -- | Render the elements of a vector. --@@ -184,7 +202,7 @@ | any isPathSeparator name = T.readFile name | otherwise = go Nothing paths where go me (p:ps) = do- let cur = p </> name+ let cur = p </> name <.> "tpl" x <- doesFileExist cur if x then T.readFile cur `E.catch` \e -> go (me `mplus` Just e) ps
Criterion/Types.hs view
@@ -1,10 +1,9 @@-{-# LANGUAGE DeriveDataTypeable, DeriveGeneric, ExistentialQuantification,- FlexibleInstances, GADTs #-}-{-# OPTIONS_GHC -fno-warn-incomplete-patterns #-}+{-# LANGUAGE DeriveDataTypeable, DeriveGeneric, GADTs, RecordWildCards #-}+{-# OPTIONS_GHC -funbox-strict-fields #-} -- | -- Module : Criterion.Types--- Copyright : (c) 2009, 2010 Bryan O'Sullivan+-- Copyright : (c) 2009-2014 Bryan O'Sullivan -- -- License : BSD-style -- Maintainer : bos@serpentine.com@@ -13,116 +12,411 @@ -- -- Types for benchmarking. ----- The core class is 'Benchmarkable', which admits both pure functions+-- The core type is 'Benchmarkable', which admits both pure functions -- and 'IO' actions. -- -- For a pure function of type @a -> b@, the benchmarking harness--- calls this function repeatedly, each time with a different 'Int'--- argument, and reduces the result the function returns to weak head--- normal form. If you need the result reduced to normal form, that--- is your responsibility.+-- calls this function repeatedly, each time with a different 'Int64'+-- argument (the number of times to run the function in a loop), and+-- reduces the result the function returns to weak head normal form. -- -- For an action of type @IO a@, the benchmarking harness calls the -- action repeatedly, but does not reduce the result. module Criterion.Types (+ -- * Configuration+ Config(..)+ , Verbosity(..) -- * Benchmark descriptions- Benchmarkable(..)+ , Benchmarkable(..) , Benchmark(..)- , Pure+ -- * Measurements+ , Measured(..)+ , fromInt+ , toInt+ , fromDouble+ , toDouble+ , measureAccessors+ , measureKeys+ , measure+ , rescale+ -- * Benchmark construction+ , env+ , bench+ , bgroup+ , benchNames+ -- ** Evaluation control , whnf , nf , nfIO , whnfIO- , bench- , bgroup- , bcompare- , benchNames -- * Result types- , Result(..)- , ResultForest- , ResultTree(..)+ , Outliers(..)+ , OutlierEffect(..)+ , OutlierVariance(..)+ , Regression(..)+ , KDE(..)+ , Report(..)+ , SampleAnalysis(..) ) where -import Control.DeepSeq (NFData, rnf)+import Control.Applicative ((<$>), (<*>))+import Control.DeepSeq (NFData(rnf)) import Control.Exception (evaluate)-import Criterion.Analysis.Types (Outliers(..), SampleAnalysis(..))-import Data.Binary (Binary)+import Data.Aeson (FromJSON(..), ToJSON(..))+import Data.Binary (Binary(..), putWord8, getWord8) import Data.Data (Data, Typeable)+import Data.Int (Int64)+import Data.Map (Map, fromList)+import Data.Monoid (Monoid(..)) import GHC.Generics (Generic)-import Statistics.Types (Sample)+import qualified Data.Vector as V+import qualified Data.Vector.Unboxed as U+import qualified Statistics.Resampling.Bootstrap as B --- | A benchmarkable function or action.-class Benchmarkable a where- -- | Run a function or action the specified number of times.- run :: a -- ^ The function or action to benchmark.- -> Int -- ^ The number of times to run or evaluate it.- -> IO ()+-- | Control the amount of information displayed.+data Verbosity = Quiet+ | Normal+ | Verbose+ deriving (Eq, Ord, Bounded, Enum, Read, Show, Typeable, Data,+ Generic) --- | A container for a pure function to benchmark, and an argument to--- supply to it each time it is evaluated.-data Pure where- WHNF :: (a -> b) -> a -> Pure- NF :: NFData b => (a -> b) -> a -> Pure+-- | Top-level benchmarking configuration.+data Config = Config {+ confInterval :: Double+ -- ^ Confidence interval for bootstrap estimation (greater than+ -- 0, less than 1).+ , forceGC :: Bool+ -- ^ Force garbage collection between every benchmark run. This+ -- leads to more stable results.+ , timeLimit :: Double+ -- ^ Number of seconds to run a single benchmark. (In practice,+ -- execution time will very slightly exceed this limit.)+ , resamples :: Int+ -- ^ Number of resamples to perform when bootstrapping.+ , regressions :: [([String], String)]+ -- ^ Regressions to perform.+ , rawDataFile :: Maybe FilePath+ -- ^ File to write binary measurement and analysis data to. If+ -- not specified, this will be a temporary file.+ , reportFile :: Maybe FilePath+ -- ^ File to write report output to, with template expanded.+ , csvFile :: Maybe FilePath+ -- ^ File to write CSV summary to.+ , junitFile :: Maybe FilePath+ -- ^ File to write JUnit-compatible XML results to.+ , verbosity :: Verbosity+ -- ^ Verbosity level to use when running and analysing+ -- benchmarks.+ , template :: FilePath+ -- ^ Template file to use if writing a report.+ } deriving (Eq, Read, Show, Typeable, Data, Generic) +-- | A pure function or impure action that can be benchmarked. The+-- 'Int64' parameter indicates the number of times to run the given+-- function or action.+newtype Benchmarkable = Benchmarkable (Int64 -> IO ())++-- | A collection of measurements made while benchmarking.+--+-- Measurements related to garbage collection are tagged with __GC__.+-- They will only be available if a benchmark is run with @\"+RTS+-- -T\"@.+--+-- __Packed storage.__ When GC statistics cannot be collected, GC+-- values will be set to huge negative values. If a field is labeled+-- with \"__GC__\" below, use 'fromInt' and 'fromDouble' to safely+-- convert to \"real\" values.+data Measured = Measured {+ measTime :: !Double+ -- ^ Total wall-clock time elapsed, in seconds.+ , measCpuTime :: !Double+ -- ^ Total CPU time elapsed, in seconds. Includes both user and+ -- kernel (system) time.+ , measCycles :: !Int64+ -- ^ Cycles, in unspecified units that may be CPU cycles. (On+ -- i386 and x86_64, this is measured using the @rdtsc@+ -- instruction.)+ , measIters :: !Int64+ -- ^ Number of loop iterations measured.++ , measAllocated :: !Int64+ -- ^ __(GC)__ Number of bytes allocated. Access using 'fromInt'.+ , measNumGcs :: !Int64+ -- ^ __(GC)__ Number of garbage collections performed. Access+ -- using 'fromInt'.+ , measBytesCopied :: !Int64+ -- ^ __(GC)__ Number of bytes copied during garbage collection.+ -- Access using 'fromInt'.+ , measMutatorWallSeconds :: !Double+ -- ^ __(GC)__ Wall-clock time spent doing real work+ -- (\"mutation\"), as distinct from garbage collection. Access+ -- using 'fromDouble'.+ , measMutatorCpuSeconds :: !Double+ -- ^ __(GC)__ CPU time spent doing real work (\"mutation\"), as+ -- distinct from garbage collection. Access using 'fromDouble'.+ , measGcWallSeconds :: !Double+ -- ^ __(GC)__ Wall-clock time spent doing garbage collection.+ -- Access using 'fromDouble'.+ , measGcCpuSeconds :: !Double+ -- ^ __(GC)__ CPU time spent doing garbage collection. Access+ -- using 'fromDouble'.+ } deriving (Eq, Read, Show, Typeable, Data, Generic)++instance FromJSON Measured where+ parseJSON v = do+ (a,b,c,d,e,f,g,h,i,j,k) <- parseJSON v+ return $ Measured a b c d e f g h i j k++instance ToJSON Measured where+ toJSON Measured{..} = toJSON+ (measTime, measCpuTime, measCycles, measIters,+ i measAllocated, i measNumGcs, i measBytesCopied,+ d measMutatorWallSeconds, d measMutatorCpuSeconds,+ d measGcWallSeconds, d measMutatorCpuSeconds)+ where i = fromInt; d = fromDouble++instance NFData Measured where+ rnf Measured{} = ()++-- THIS MUST REFLECT THE ORDER OF FIELDS IN THE DATA TYPE.+--+-- The ordering is used by Javascript code to pick out the correct+-- index into the vector that represents a Measured value in that+-- world.+measureAccessors_ :: [(String, (Measured -> Maybe Double, String))]+measureAccessors_ = [+ ("time", (Just . measTime,+ "wall-clock time"))+ , ("cpuTime", (Just . measCpuTime,+ "CPU time"))+ , ("cycles", (Just . fromIntegral . measCycles,+ "CPU cycles"))+ , ("iters", (Just . fromIntegral . measIters,+ "loop iterations"))+ , ("allocated", (fmap fromIntegral . fromInt . measAllocated,+ "(+RTS -T) bytes allocated"))+ , ("numGcs", (fmap fromIntegral . fromInt . measNumGcs,+ "(+RTS -T) number of garbage collections"))+ , ("bytesCopied", (fmap fromIntegral . fromInt . measBytesCopied,+ "(+RTS -T) number of bytes copied during GC"))+ , ("mutatorWallSeconds", (fromDouble . measMutatorWallSeconds,+ "(+RTS -T) wall-clock time for mutator threads"))+ , ("mutatorCpuSeconds", (fromDouble . measMutatorCpuSeconds,+ "(+RTS -T) CPU time spent running mutator threads"))+ , ("gcWallSeconds", (fromDouble . measGcWallSeconds,+ "(+RTS -T) wall-clock time spent doing GC"))+ , ("gcCpuSeconds", (fromDouble . measGcCpuSeconds,+ "(+RTS -T) CPU time spent doing GC"))+ ]++-- | Field names in a 'Measured' record, in the order in which they+-- appear.+measureKeys :: [String]+measureKeys = map fst measureAccessors_++-- | Field names and accessors for a 'Measured' record.+measureAccessors :: Map String (Measured -> Maybe Double, String)+measureAccessors = fromList measureAccessors_++-- | Normalise every measurement as if 'measIters' was 1.+--+-- ('measIters' itself is left unaffected.)+rescale :: Measured -> Measured+rescale m@Measured{..} = m {+ measTime = d measTime+ , measCpuTime = d measCpuTime+ , measCycles = i measCycles+ -- skip measIters+ , measNumGcs = i measNumGcs+ , measBytesCopied = i measBytesCopied+ , measMutatorWallSeconds = d measMutatorWallSeconds+ , measMutatorCpuSeconds = d measMutatorCpuSeconds+ , measGcWallSeconds = d measGcWallSeconds+ , measGcCpuSeconds = d measGcCpuSeconds+ } where+ d k = maybe k (/ iters) (fromDouble k)+ i k = maybe k (round . (/ iters)) (fromIntegral <$> fromInt k)+ iters = fromIntegral measIters :: Double++-- | Convert a (possibly unavailable) GC measurement to a true value.+-- If the measurement is a huge negative number that corresponds to+-- \"no data\", this will return 'Nothing'.+fromInt :: Int64 -> Maybe Int64+fromInt i | i == minBound = Nothing+ | otherwise = Just i++-- | Convert from a true value back to the packed representation used+-- for GC measurements.+toInt :: Maybe Int64 -> Int64+toInt Nothing = minBound+toInt (Just i) = i++-- | Convert a (possibly unavailable) GC measurement to a true value.+-- If the measurement is a huge negative number that corresponds to+-- \"no data\", this will return 'Nothing'.+fromDouble :: Double -> Maybe Double+fromDouble d | isInfinite d || isNaN d = Nothing+ | otherwise = Just d++-- | Convert from a true value back to the packed representation used+-- for GC measurements.+toDouble :: Maybe Double -> Double+toDouble Nothing = -1/0+toDouble (Just d) = d++instance Binary Measured where+ put Measured{..} = do+ put measTime; put measCpuTime; put measCycles; put measIters+ put measAllocated; put measNumGcs; put measBytesCopied+ put measMutatorWallSeconds; put measMutatorCpuSeconds+ put measGcWallSeconds; put measGcCpuSeconds+ get = Measured <$> get <*> get <*> get <*> get+ <*> get <*> get <*> get <*> get <*> get <*> get <*> get+ -- | Apply an argument to a function, and evaluate the result to weak -- head normal form (WHNF).-whnf :: (a -> b) -> a -> Pure-whnf = WHNF+whnf :: (a -> b) -> a -> Benchmarkable+whnf = pureFunc id {-# INLINE whnf #-} -- | Apply an argument to a function, and evaluate the result to head -- normal form (NF).-nf :: NFData b => (a -> b) -> a -> Pure-nf = NF+nf :: NFData b => (a -> b) -> a -> Benchmarkable+nf = pureFunc rnf {-# INLINE nf #-} +pureFunc :: (b -> c) -> (a -> b) -> a -> Benchmarkable+pureFunc reduce f0 x0 = Benchmarkable $ go f0 x0+ where go f x n+ | n <= 0 = return ()+ | otherwise = evaluate (reduce (f x)) >> go f x (n-1)+{-# INLINE pureFunc #-}+ -- | Perform an action, then evaluate its result to head normal form.--- This is particularly useful for forcing a lazy IO action to be+-- This is particularly useful for forcing a lazy 'IO' action to be -- completely performed.-nfIO :: NFData a => IO a -> IO ()-nfIO a = evaluate . rnf =<< a+nfIO :: NFData a => IO a -> Benchmarkable+nfIO = impure rnf {-# INLINE nfIO #-} -- | Perform an action, then evaluate its result to weak head normal--- form (WHNF). This is useful for forcing an IO action whose result+-- form (WHNF). This is useful for forcing an 'IO' action whose result -- is an expression to be evaluated down to a more useful value.-whnfIO :: IO a -> IO ()-whnfIO a = a >>= evaluate >> return ()+whnfIO :: IO a -> Benchmarkable+whnfIO = impure id {-# INLINE whnfIO #-} -instance Benchmarkable Pure where- run p@(WHNF _ _) = go p- where- go fx@(WHNF f x) n- | n <= 0 = return ()- | otherwise = evaluate (f x) >> go fx (n-1)- run p@(NF _ _) = go p- where- go fx@(NF f x) n- | n <= 0 = return ()- | otherwise = evaluate (rnf (f x)) >> go fx (n-1)- {-# INLINE run #-}--instance Benchmarkable (IO a) where- run a n- | n <= 0 = return ()- | otherwise = a >> run a (n-1)- {-# INLINE run #-}+impure :: (a -> b) -> IO a -> Benchmarkable+impure strategy a = Benchmarkable go+ where go n+ | n <= 0 = return ()+ | otherwise = a >>= (evaluate . strategy) >> go (n-1)+{-# INLINE impure #-} --- | A benchmark may consist of either a single 'Benchmarkable' item--- with a name, created with 'bench', or a (possibly nested) group of--- 'Benchmark's, created with 'bgroup'.+-- | Specification of a collection of benchmarks and environments. A+-- benchmark may consist of:+--+-- * An environment that creates input data for benchmarks, created+-- with 'env'.+--+-- * A single 'Benchmarkable' item with a name, created with 'bench'.+--+-- * A (possibly nested) group of 'Benchmark's, created with 'bgroup'. data Benchmark where- Benchmark :: Benchmarkable b => String -> b -> Benchmark+ Environment :: NFData env => IO env -> (env -> Benchmark) -> Benchmark+ Benchmark :: String -> Benchmarkable -> Benchmark BenchGroup :: String -> [Benchmark] -> Benchmark- BenchCompare :: [Benchmark] -> Benchmark +-- | Run a benchmark (or collection of benchmarks) in the given+-- environment. The purpose of an environment is to lazily create+-- input data to pass to the functions that will be benchmarked.+--+-- A common example of environment data is input that is read from a+-- file. Another is a large data structure constructed in-place.+--+-- __Motivation.__ In earlier versions of criterion, all benchmark+-- inputs were always created when a program started running. By+-- deferring the creation of an environment when its associated+-- benchmarks need the its, we avoid two problems that this strategy+-- caused:+--+-- * Memory pressure distorted the results of unrelated benchmarks.+-- If one benchmark needed e.g. a gigabyte-sized input, it would+-- force the garbage collector to do extra work when running some+-- other benchmark that had no use for that input. Since the data+-- created by an environment is only available when it is in scope,+-- it should be garbage collected before other benchmarks are run.+--+-- * The time cost of generating all needed inputs could be+-- significant in cases where no inputs (or just a few) were really+-- needed. This occurred often, for instance when just one out of a+-- large suite of benchmarks was run, or when a user would list the+-- collection of benchmarks without running any.+--+-- __Creation.__ An environment is created right before its related+-- benchmarks are run. The 'IO' action that creates the environment+-- is run, then the newly created environment is evaluated to normal+-- form (hence the 'NFData' constraint) before being passed to the+-- function that receives the environment.+--+-- __Complex environments.__ If you need to create an environment that+-- contains multiple values, simply pack the values into a tuple.+--+-- __Lazy pattern matching.__ In situations where a \"real\"+-- environment is not needed, e.g. if a list of benchmark names is+-- being generated, @undefined@ will be passed to the function that+-- receives the environment. This avoids the overhead of generating+-- an environment that will not actually be used.+--+-- The function that receives the environment must use lazy pattern+-- matching to deconstruct the tuple, as use of strict pattern+-- matching will cause a crash if @undefined@ is passed in.+--+-- __Example.__ This program runs benchmarks in an environment that+-- contains two values. The first value is the contents of a text+-- file; the second is a string. Pay attention to the use of a lazy+-- pattern to deconstruct the tuple in the function that returns the+-- benchmarks to be run.+--+-- > setupEnv = do+-- > let small = replicate 1000 1+-- > big <- readFile "/usr/dict/words"+-- > return (small, big)+-- >+-- > main = defaultMain [+-- > -- notice the lazy pattern match here!+-- > env setupEnv $ \ ~(small,big) ->+-- > bgroup "small" [+-- > bench "length" $ whnf length small+-- > , bench "length . filter" $ whnf (length . filter (==1)) small+-- > ]+-- > , bgroup "big" [+-- > bench "length" $ whnf length big+-- > , bench "length . filter" $ whnf (length . filter (==1)) big+-- > ]+-- > ]+--+-- __Discussion.__ The environment created in the example above is+-- intentionally /not/ ideal. As Haskell's scoping rules suggest, the+-- variable @big@ is in scope for the benchmarks that use only+-- @small@. It would be better to create a separate environment for+-- @big@, so that it will not be kept alive while the unrelated+-- benchmarks are being run.+env :: NFData env =>+ IO env+ -- ^ Create the environment. The environment will be evaluated to+ -- normal form before being passed to the benchmark.+ -> (env -> Benchmark)+ -- ^ Take the newly created environment and make it available to+ -- the given benchmarks.+ -> Benchmark+env = Environment+ -- | Create a single benchmark.-bench :: Benchmarkable b =>- String -- ^ A name to identify the benchmark.- -> b+bench :: String -- ^ A name to identify the benchmark.+ -> Benchmarkable -- ^ An activity to be benchmarked. -> Benchmark bench = Benchmark @@ -132,40 +426,201 @@ -> Benchmark bgroup = BenchGroup --- | Compare benchmarks against a reference benchmark--- (The first 'bench' in the given list).------ The results of the comparisons are written to a CSV file specified using the--- @-r@ command line flag. The CSV file uses the following format:------ @Reference,Name,% faster than the reference@-bcompare :: [Benchmark] -> Benchmark-bcompare = BenchCompare- -- | Retrieve the names of all benchmarks. Grouped benchmarks are -- prefixed with the name of the group they're in. benchNames :: Benchmark -> [String]+benchNames (Environment _ b) = benchNames (b undefined) benchNames (Benchmark d _) = [d] benchNames (BenchGroup d bs) = map ((d ++ "/") ++) . concatMap benchNames $ bs-benchNames (BenchCompare bs) = concatMap benchNames $ bs instance Show Benchmark where- show (Benchmark d _) = ("Benchmark " ++ show d)- show (BenchGroup d _) = ("BenchGroup " ++ show d)- show (BenchCompare _) = ("BenchCompare")+ show (Environment _ b) = "Environment _ " ++ show (b undefined)+ show (Benchmark d _) = "Benchmark " ++ show d+ show (BenchGroup d _) = "BenchGroup " ++ show d -data Result = Result {- description :: String- , sample :: Sample- , sampleAnalysis :: SampleAnalysis- , outliers :: Outliers+measure :: (U.Unbox a) => (Measured -> a) -> V.Vector Measured -> U.Vector a+measure f v = U.convert . V.map f $ v++-- | Outliers from sample data, calculated using the boxplot+-- technique.+data Outliers = Outliers {+ samplesSeen :: !Int64+ , lowSevere :: !Int64+ -- ^ More than 3 times the interquartile range (IQR) below the+ -- first quartile.+ , lowMild :: !Int64+ -- ^ Between 1.5 and 3 times the IQR below the first quartile.+ , highMild :: !Int64+ -- ^ Between 1.5 and 3 times the IQR above the third quartile.+ , highSevere :: !Int64+ -- ^ More than 3 times the IQR above the third quartile. } deriving (Eq, Read, Show, Typeable, Data, Generic) -instance Binary Result+instance FromJSON Outliers+instance ToJSON Outliers -type ResultForest = [ResultTree]-data ResultTree = Single Result- | Compare !Int ResultForest- deriving (Eq, Read, Show, Typeable, Data, Generic)+instance Binary Outliers where+ put (Outliers v w x y z) = put v >> put w >> put x >> put y >> put z+ get = Outliers <$> get <*> get <*> get <*> get <*> get+instance NFData Outliers -instance Binary ResultTree+-- | A description of the extent to which outliers in the sample data+-- affect the sample mean and standard deviation.+data OutlierEffect = Unaffected -- ^ Less than 1% effect.+ | Slight -- ^ Between 1% and 10%.+ | Moderate -- ^ Between 10% and 50%.+ | Severe -- ^ Above 50% (i.e. measurements+ -- are useless).+ deriving (Eq, Ord, Read, Show, Typeable, Data, Generic)++instance FromJSON OutlierEffect+instance ToJSON OutlierEffect++instance Binary OutlierEffect where+ put Unaffected = putWord8 0+ put Slight = putWord8 1+ put Moderate = putWord8 2+ put Severe = putWord8 3+ get = do+ i <- getWord8+ case i of+ 0 -> return Unaffected+ 1 -> return Slight+ 2 -> return Moderate+ 3 -> return Severe+ _ -> fail $ "get for OutlierEffect: unexpected " ++ show i+instance NFData OutlierEffect++instance Monoid Outliers where+ mempty = Outliers 0 0 0 0 0+ mappend = addOutliers++addOutliers :: Outliers -> Outliers -> Outliers+addOutliers (Outliers s a b c d) (Outliers t w x y z) =+ Outliers (s+t) (a+w) (b+x) (c+y) (d+z)+{-# INLINE addOutliers #-}++-- | Analysis of the extent to which outliers in a sample affect its+-- standard deviation (and to some extent, its mean).+data OutlierVariance = OutlierVariance {+ ovEffect :: OutlierEffect+ -- ^ Qualitative description of effect.+ , ovDesc :: String+ -- ^ Brief textual description of effect.+ , ovFraction :: Double+ -- ^ Quantitative description of effect (a fraction between 0 and 1).+ } deriving (Eq, Read, Show, Typeable, Data, Generic)++instance FromJSON OutlierVariance+instance ToJSON OutlierVariance++instance Binary OutlierVariance where+ put (OutlierVariance x y z) = put x >> put y >> put z+ get = OutlierVariance <$> get <*> get <*> get++instance NFData OutlierVariance where+ rnf OutlierVariance{..} = rnf ovEffect `seq` rnf ovDesc `seq` rnf ovFraction++-- | Results of a linear regression.+data Regression = Regression {+ regResponder :: String+ -- ^ Name of the responding variable.+ , regCoeffs :: Map String B.Estimate+ -- ^ Map from name to value of predictor coefficients.+ , regRSquare :: B.Estimate+ -- ^ R² goodness-of-fit estimate.+ } deriving (Eq, Read, Show, Typeable, Data, Generic)++instance FromJSON Regression+instance ToJSON Regression++instance Binary Regression where+ put Regression{..} =+ put regResponder >> put regCoeffs >> put regRSquare++instance NFData Regression where+ rnf Regression{..} =+ rnf regResponder `seq` rnf regCoeffs `seq` rnf regRSquare++-- | Result of a bootstrap analysis of a non-parametric sample.+data SampleAnalysis = SampleAnalysis {+ anRegress :: [Regression]+ -- ^ Estimates calculated via linear regression.+ , anOverhead :: Double+ -- ^ Estimated measurement overhead, in seconds. Estimation is+ -- performed via linear regression.+ , anMean :: B.Estimate+ -- ^ Estimated mean.+ , anStdDev :: B.Estimate+ -- ^ Estimated standard deviation.+ , anOutlierVar :: OutlierVariance+ -- ^ Description of the effects of outliers on the estimated+ -- variance.+ } deriving (Eq, Read, Show, Typeable, Data, Generic)++instance FromJSON SampleAnalysis+instance ToJSON SampleAnalysis++instance Binary SampleAnalysis where+ put SampleAnalysis{..} = do+ put anRegress; put anOverhead; put anMean; put anStdDev; put anOutlierVar+ get = SampleAnalysis <$> get <*> get <*> get <*> get <*> get++instance NFData SampleAnalysis where+ rnf SampleAnalysis{..} =+ rnf anRegress `seq` rnf anOverhead `seq` rnf anMean `seq`+ rnf anStdDev `seq` rnf anOutlierVar++-- | Data for a KDE chart of performance.+data KDE = KDE {+ kdeType :: String+ , kdeValues :: U.Vector Double+ , kdePDF :: U.Vector Double+ } deriving (Eq, Read, Show, Typeable, Data, Generic)++instance FromJSON KDE+instance ToJSON KDE++instance Binary KDE where+ put KDE{..} = put kdeType >> put kdeValues >> put kdePDF+ get = KDE <$> get <*> get <*> get++instance NFData KDE where+ rnf KDE{..} = rnf kdeType `seq` rnf kdeValues `seq` rnf kdePDF++-- | Report of a sample analysis.+data Report = Report {+ reportNumber :: Int+ -- ^ A simple index indicating that this is the /n/th report.+ , reportName :: String+ -- ^ The name of this report.+ , reportKeys :: [String]+ -- ^ See 'measureKeys'.+ , reportMeasured :: V.Vector Measured+ -- ^ Raw measurements. These are /not/ corrected for the+ -- estimated measurement overhead that can be found via the+ -- 'anOverhead' field of 'reportAnalysis'.+ , reportAnalysis :: SampleAnalysis+ -- ^ Report analysis.+ , reportOutliers :: Outliers+ -- ^ Analysis of outliers.+ , reportKDEs :: [KDE]+ -- ^ Data for a KDE of times.+ } deriving (Eq, Read, Show, Typeable, Data, Generic)++instance FromJSON Report+instance ToJSON Report++instance Binary Report where+ put Report{..} =+ put reportNumber >> put reportName >> put reportKeys >>+ put reportMeasured >> put reportAnalysis >> put reportOutliers >>+ put reportKDEs++ get = Report <$> get <*> get <*> get <*> get <*> get <*> get <*> get++instance NFData Report where+ rnf Report{..} =+ rnf reportNumber `seq` rnf reportName `seq` rnf reportKeys `seq`+ rnf reportMeasured `seq` rnf reportAnalysis `seq` rnf reportOutliers `seq`+ rnf reportKDEs
LICENSE view
@@ -24,3 +24,7 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.+++Some files in templates/js have their own copyright and license, please+refer to the corresponding sources in js-src/.
+ app/App.hs view
@@ -0,0 +1,5 @@+module Main (main) where++main :: IO ()+main = do+ return ()
+ cbits/cycles.c view
@@ -0,0 +1,8 @@+#include "Rts.h"++StgWord64 criterion_rdtsc(void)+{+ StgWord32 hi, lo;+ __asm__ __volatile__ ("rdtsc" : "=a"(lo), "=d"(hi));+ return ((StgWord64) lo) | (((StgWord64) hi)<<32);+}
+ cbits/time-osx.c view
@@ -0,0 +1,35 @@+#include <mach/mach.h>+#include <mach/mach_time.h>++static mach_timebase_info_data_t timebase_info;+static double timebase_recip;++void criterion_inittime(void)+{+ if (timebase_recip == 0) {+ mach_timebase_info(&timebase_info);+ timebase_recip = (timebase_info.denom / timebase_info.numer) / 1e9;+ }+}++double criterion_gettime(void)+{+ return mach_absolute_time() * timebase_recip;+}++static double to_double(time_value_t time)+{+ return time.seconds + time.microseconds / 1e6;+}++double criterion_getcputime(void)+{+ struct task_thread_times_info thread_info_data;+ mach_msg_type_number_t thread_info_count = TASK_THREAD_TIMES_INFO_COUNT;+ kern_return_t kr = task_info(mach_task_self(),+ TASK_THREAD_TIMES_INFO,+ (task_info_t) &thread_info_data,+ &thread_info_count);+ return (to_double(thread_info_data.user_time) ++ to_double(thread_info_data.system_time));+}
+ cbits/time-posix.c view
@@ -0,0 +1,24 @@+#include <time.h>++void criterion_inittime(void)+{+}++double criterion_gettime(void)+{+ struct timespec ts;++ clock_gettime(CLOCK_MONOTONIC, &ts);++ return ts.tv_sec + ts.tv_nsec * 1e-9;+}+++double criterion_getcputime(void)+{+ struct timespec ts;++ clock_gettime(CLOCK_PROCESS_CPUTIME_ID, &ts);++ return ts.tv_sec + ts.tv_nsec * 1e-9;+}
+ cbits/time-windows.c view
@@ -0,0 +1,80 @@+/*+ * Windows has the most amazingly cretinous time measurement APIs you+ * can possibly imagine.+ *+ * Our first possibility is GetSystemTimeAsFileTime, which updates at+ * roughly 60Hz, and is hence worthless - we'd have to run a+ * computation for tens or hundreds of seconds to get a trustworthy+ * number.+ *+ * Alternatively, we can use QueryPerformanceCounter, which has+ * undefined behaviour under almost all interesting circumstances+ * (e.g. multicore systems, CPU frequency changes). But at least it+ * increments reasonably often.+ */++#include <windows.h>++#if 0++void criterion_inittime(void)+{+}++double criterion_gettime(void)+{+ FILETIME ft;+ ULARGE_INTEGER li;++ GetSystemTimeAsFileTime(&ft);+ li.LowPart = ft.dwLowDateTime;+ li.HighPart = ft.dwHighDateTime;++ return (li.QuadPart - 130000000000000000ull) * 1e-7;+}++#else++static double freq_recip;+static LARGE_INTEGER firstClock;++void criterion_inittime(void)+{+ LARGE_INTEGER freq;++ if (freq_recip == 0) {+ QueryPerformanceFrequency(&freq);+ QueryPerformanceCounter(&firstClock);+ freq_recip = 1.0 / freq.QuadPart;+ }+}++double criterion_gettime(void)+{+ LARGE_INTEGER li;++ QueryPerformanceCounter(&li);++ return ((double) (li.QuadPart - firstClock.QuadPart)) * freq_recip;+}++#endif++static ULONGLONG to_quad_100ns(FILETIME ft)+{+ ULARGE_INTEGER li;+ li.LowPart = ft.dwLowDateTime;+ li.HighPart = ft.dwHighDateTime;+ return li.QuadPart;+}++double criterion_getcputime(void)+{+ FILETIME creation, exit, kernel, user;+ ULONGLONG time;++ GetProcessTimes(GetCurrentProcess(), &creation, &exit, &kernel, &user);++ time = to_quad_100ns(user_time) + to_quad_100ns(kernel_time);+ return time / 1e7;+}
criterion.cabal view
@@ -1,28 +1,30 @@ name: criterion-version: 0.8.1.0+version: 1.0.0.0 synopsis: Robust, reliable performance measurement and analysis license: BSD3 license-file: LICENSE author: Bryan O'Sullivan <bos@serpentine.com> maintainer: Bryan O'Sullivan <bos@serpentine.com>-copyright: 2009-2013 Bryan O'Sullivan+copyright: 2009-2014 Bryan O'Sullivan category: Development, Performance, Testing, Benchmarking-homepage: https://github.com/bos/criterion+homepage: http://www.serpentine.com/criterion bug-reports: https://github.com/bos/criterion/issues build-type: Simple-cabal-version: >= 1.6+cabal-version: >= 1.8 extra-source-files: README.markdown+ examples/*.cabal examples/*.hs examples/*.html+ js-src/flot-0.8.3.zip+ js-src/jquery-2.1.1.js data-files:- templates/js/excanvas-r3.min.js- templates/js/jquery-1.6.4.min.js- templates/js/jquery.criterion.js- templates/js/jquery.flot-0.7.min.js templates/*.css templates/*.tpl+ templates/js/jquery-2.1.1.min.js+ templates/js/jquery.criterion.js+ templates/js/jquery.flot-0.8.3.min.js description: This library provides a powerful but simple way to measure software@@ -40,36 +42,51 @@ exposed-modules: Criterion Criterion.Analysis- Criterion.Analysis.Types- Criterion.Config- Criterion.Environment Criterion.IO Criterion.IO.Printf+ Criterion.Internal Criterion.Main+ Criterion.Main.Options Criterion.Measurement Criterion.Monad Criterion.Report Criterion.Types other-modules:- Criterion.Internal+ Criterion.Monad.Internal++ c-sources: cbits/cycles.c+ if os(darwin)+ c-sources: cbits/time-osx.c+ else {+ if os(windows)+ c-sources: cbits/time-windows.c+ else+ c-sources: cbits/time-posix.c+ }++ other-modules: Paths_criterion build-depends:- aeson >= 0.3.2.12,- base < 5,- binary >= 0.6.3.0,+ aeson >= 0.8,+ ansi-wl-pprint,+ base >= 4.5 && < 5,+ binary >= 0.5.1.0, bytestring >= 0.9 && < 1.0,+ cassava >= 0.3.0.0, containers, deepseq >= 1.1.0.0, directory,+ either, filepath, Glob >= 0.7.2, hastache >= 0.6.0, mtl >= 2, mwc-random >= 0.8.0.3,+ optparse-applicative, parsec >= 3.1.0,- statistics >= 0.11,+ statistics >= 0.13.2.1, text >= 0.11, time, transformers,@@ -82,6 +99,48 @@ ghc-options: -O2 -Wall -funbox-strict-fields if impl(ghc >= 6.8) ghc-options: -fwarn-tabs++executable criterion+ buildable: False+ hs-source-dirs: app+ main-is: App.hs++ ghc-options:+ -Wall -threaded -rtsopts++ build-depends:+ base,+ criterion++test-suite sanity+ type: exitcode-stdio-1.0+ hs-source-dirs: tests+ main-is: Sanity.hs+ ghc-options: -O2 -Wall -rtsopts+ build-depends:+ HUnit,+ base,+ bytestring,+ criterion,+ test-framework,+ test-framework-hunit++test-suite tests+ type: exitcode-stdio-1.0+ hs-source-dirs: tests+ main-is: Tests.hs++ ghc-options:+ -Wall -threaded -O0 -rtsopts++ build-depends:+ QuickCheck >= 2.4,+ base,+ criterion,+ statistics,+ test-framework >= 0.4,+ test-framework-quickcheck2 >= 0.2,+ vector source-repository head type: git
+ examples/BadReadFile.hs view
@@ -0,0 +1,17 @@+-- This example demonstrates the peril of trying to benchmark a+-- function that performs lazy I/O.++import Criterion.Main++main :: IO ()+main = defaultMain [+ -- By using whnfIO, when the benchmark loop goes through an+ -- iteration, we inspect only the first constructor returned after+ -- the file is opened. Since the entire file must be read in+ -- order for it to be closed, this causes file handles to leak,+ -- and our benchmark will probably crash while running with an+ -- error like this:+ --+ -- openFile: resource exhausted (Too many open files)+ bench "whnfIO readFile" $ whnfIO (readFile "BadReadFile.hs")+ ]
+ examples/ConduitVsPipes.hs view
@@ -0,0 +1,34 @@+-- Contributed by Gabriel Gonzales as a test case for+-- https://github.com/bos/criterion/issues/35+--+-- The numbers reported by this benchmark can be made "more correct"+-- by compiling with the -fno-full-laziness option.++import Criterion.Main (bench, bgroup, defaultMain, nfIO, whnf)+import Data.Conduit (($=), ($$))+import Data.Functor.Identity (Identity(..))+import Pipes ((>->), discard, each, for, runEffect)+import qualified Data.Conduit.List as C+import qualified Pipes.Prelude as P++criterion :: Int -> IO ()+criterion n = defaultMain+ [ bgroup "IO"+ [ -- This will appear to run in just a few nanoseconds.+ bench "pipes" $ nfIO (pipes n)+ -- In contrast, this should take ~10 microseconds. Which is+ -- also wrong, as it happens.+ , bench "conduit" $ nfIO (conduit n)+ ]+ , bgroup "Identity"+ [ bench "pipes" $ whnf (runIdentity . pipes ) n+ , bench "conduit" $ whnf (runIdentity . conduit) n+ ]+ ]++pipes, conduit :: (Monad m) => Int -> m ()+pipes n = runEffect $ for (each [1..n] >-> P.map (+1) >-> P.filter even) discard+conduit n = C.sourceList [1..n] $= C.map (+1) $= C.filter even $$ C.sinkNull++main :: IO ()+main = criterion 10000
examples/Fibber.hs view
@@ -1,45 +1,20 @@-{-# LANGUAGE ScopedTypeVariables #-}+-- The simplest/silliest of all benchmarks! import Criterion.Main -fib :: Int -> Int-fib n | n < 0 = error "negative!"- | otherwise = go (fromIntegral n)+fib :: Integer -> Integer+fib m | m < 0 = error "negative!"+ | otherwise = go m where go 0 = 0 go 1 = 1 go n = go (n-1) + go (n-2) -fact :: Int -> Integer-fact n | n < 0 = error "negative!"- | otherwise = go (fromIntegral n)- where go 0 = 1- go i = i * go (i-1)--fio :: Int -> IO Integer-fio n | n < 0 = error "negative!"- | otherwise = go (fromIntegral n)- where go i | i == 0 = return 1- | otherwise = do- j <- go (i-1)- return $! i * j-+main :: IO () main = defaultMain [- bgroup "tiny" [ bench "fib 10" $ whnf fib 10- , bench "fib 15" $ whnf fib 15- , bench "fib 20" $ whnf fib 20- , bench "fib 25" $ whnf fib 25- ],- bgroup "fib" [ bench "fib 10" $ whnf fib 10- , bench "fib 35" $ whnf fib 35- , bench "fib 37" $ whnf fib 37- ],- bgroup "fact" [ bench "fact 100" $ whnf fact 100- , bench "fact 1000" $ whnf fact 1000- , bench "fact 3000" $ whnf fact 3000- ],- bgroup "fio" [ bench "fio 100" (fio 100)- , bench "fio 1000" (fio 1000)- , bench "fio 3000" (fio 3000)- ]- ]+ bgroup "fib" [ bench "1" $ whnf fib 1+ , bench "5" $ whnf fib 5+ , bench "9" $ whnf fib 9+ , bench "11" $ whnf fib 11+ ]+ ]
+ examples/GoodReadFile.hs view
@@ -0,0 +1,12 @@+-- This example demonstrates how to correctly benchmark a function+-- that performs lazy I/O.++import Criterion.Main++main :: IO ()+main = defaultMain [+ -- Because we are using nfIO here, the entire file will be read on+ -- each benchmark loop iteration. This will cause the associated+ -- file handle to be eagerly closed every time.+ bench "nfIO readFile" $ nfIO (readFile "GoodReadFile.hs")+ ]
examples/Judy.hs view
@@ -13,8 +13,7 @@ import qualified Data.IntMap as I import Data.List (foldl') --- Work around the fact that the GC won't run finalizers aggressively--- enough for us.+-- An example of how to specify a configuration value. myConfig = defaultConfig { cfgPerformGC = ljust True } main = defaultMainWith myConfig (return ()) [
+ examples/Maps.hs view
@@ -0,0 +1,90 @@+-- Benchmark the cost of creating various types of map.++{-# LANGUAGE FlexibleContexts, ScopedTypeVariables #-}++import Criterion.Main+import Data.ByteString (ByteString, pack)+import Data.Hashable (Hashable)+import System.Random.MWC+import qualified Data.CritBit.Map.Lazy as C+import qualified Data.HashMap.Lazy as H+import qualified Data.IntMap as I+import qualified Data.Map as M+import qualified Data.Vector as V+import qualified Data.Vector.Algorithms.Intro as I+import qualified Data.Vector.Generic as G+import qualified Data.Vector.Unboxed as U++type V = U.Vector Int+type B = V.Vector ByteString++numbers :: IO (V, V, V)+numbers = do+ random <- withSystemRandom . asGenIO $ \gen -> uniformVector gen 40000+ let sorted = G.modify I.sort random+ revsorted = G.reverse sorted+ return (random, sorted, revsorted)++strings :: IO (B, B, B)+strings = do+ random <- withSystemRandom . asGenIO $ \gen ->+ V.replicateM 10000 $+ (pack . U.toList) `fmap` (uniformVector gen =<< uniformR (1,16) gen)+ let sorted = G.modify I.sort random+ revsorted = G.reverse sorted+ return (random, sorted, revsorted)++main :: IO ()+main = defaultMain [+ env numbers $ \ ~(random,sorted,revsorted) ->+ bgroup "Int" [+ bgroup "IntMap" [+ bench "sorted" $ whnf intmap sorted+ , bench "random" $ whnf intmap random+ , bench "revsorted" $ whnf intmap revsorted+ ]+ , bgroup "Map" [+ bench "sorted" $ whnf mmap sorted+ , bench "random" $ whnf mmap random+ , bench "revsorted" $ whnf mmap revsorted+ ]+ , bgroup "HashMap" [+ bench "sorted" $ whnf hashmap sorted+ , bench "random" $ whnf hashmap random+ , bench "revsorted" $ whnf hashmap revsorted+ ]+ ]+ , env strings $ \ ~(random,sorted,revsorted) ->+ bgroup "ByteString" [+ bgroup "Map" [+ bench "sorted" $ whnf mmap sorted+ , bench "random" $ whnf mmap random+ , bench "revsorted" $ whnf mmap revsorted+ ]+ , bgroup "HashMap" [+ bench "sorted" $ whnf hashmap sorted+ , bench "random" $ whnf hashmap random+ , bench "revsorted" $ whnf hashmap revsorted+ ]+ , bgroup "CritBit" [+ bench "sorted" $ whnf critbit sorted+ , bench "random" $ whnf critbit random+ , bench "revsorted" $ whnf critbit revsorted+ ]+ ]+ ]++critbit :: (G.Vector v k, C.CritBitKey k) => v k -> C.CritBit k Int+critbit xs = G.foldl' (\m k -> C.insert k value m) C.empty xs++hashmap :: (G.Vector v k, Hashable k, Eq k) => v k -> H.HashMap k Int+hashmap xs = G.foldl' (\m k -> H.insert k value m) H.empty xs++intmap :: G.Vector v Int => v Int -> I.IntMap Int+intmap xs = G.foldl' (\m k -> I.insert k value m) I.empty xs++mmap :: (G.Vector v k, Ord k) => v k -> M.Map k Int+mmap xs = G.foldl' (\m k -> M.insert k value m) M.empty xs++value :: Int+value = 31337
+ examples/Overhead.hs view
@@ -0,0 +1,28 @@+-- This benchmark measures the timing overhead added by the various+-- functions we use to measure performance.++{-# LANGUAGE CPP #-}++module Main (main) where++import Criterion.Main+import Criterion.Measurement as M+import GHC.Stats as GHC++main :: IO ()+main = do+ statsEnabled <- getGCStatsEnabled+ defaultMain $ [+ bench "measure" $ whnfIO (M.measure (whnfIO $ return ()) 1)+ , bench "getTime" $ whnfIO M.getTime+ , bench "getCPUTime" $ whnfIO M.getCPUTime+ , bench "getCycles" $ whnfIO M.getCycles+ , bench "M.getGCStats" $ whnfIO M.getGCStats+ ] ++ if statsEnabled+ then [bench "GHC.getGCStats" $ whnfIO GHC.getGCStats]+ else []++#if !MIN_VERSION_base(4,6,0)+getGCStatsEnabled :: IO Bool+getGCStatsEnabled = return False+#endif
− examples/Tiny.hs
@@ -1,28 +0,0 @@-{-# LANGUAGE ScopedTypeVariables #-}--import Criterion.Main-import Control.Parallel-import qualified Data.IntMap as I-import Data.List (foldl')-import Criterion.Config--main = defaultMainWith defaultConfig (return ()) [- bgroup "fib" [- bench "fib 10" $ whnf fib 10- , bench "fib 20" $ whnf fib 20- , bench "fib 30" $ whnf fib 30- ],- bgroup "intmap" [- bench "intmap 25k" $ whnf intmap 25000- , bench "intmap 50k" $ whnf intmap 50000- , bench "intmap 75k" $ whnf intmap 75000- ]- ]- -fib :: Int -> Int-fib 0 = 0-fib 1 = 1-fib n = fib (n-1) + fib (n-2)--intmap :: Int -> I.IntMap Int-intmap n = foldl' (\m k -> I.insert k 33 m) I.empty [0..n]
+ examples/criterion-examples.cabal view
@@ -0,0 +1,83 @@+name: criterion-examples+version: 0+synopsis: Examples for the criterion benchmarking system+description: Examples for the criterion benchmarking system+homepage: https://github.com/bos/criterion+license: BSD3+license-file: ../LICENSE+author: Bryan O'Sullivan <bos@serpentine.com>+maintainer: Bryan O'Sullivan <bos@serpentine.com>+category: Benchmarks+build-type: Simple+cabal-version: >=1.8++executable fibber+ main-is: Fibber.hs++ ghc-options: -Wall -rtsopts+ build-depends:+ base == 4.*,+ criterion++executable conduit-vs-pipes+ main-is: ConduitVsPipes.hs++ ghc-options: -Wall -rtsopts+ build-depends:+ base == 4.*,+ conduit >= 1.1,+ criterion,+ pipes >= 4.1,+ transformers++executable maps+ main-is: Maps.hs++ ghc-options: -Wall -rtsopts+ build-depends:+ base == 4.*,+ bytestring,+ containers,+ critbit,+ criterion,+ hashable,+ mwc-random,+ unordered-containers,+ vector,+ vector-algorithms++executable overhead+ main-is: Overhead.hs++ ghc-options: -Wall -rtsopts+ build-depends:+ base == 4.*,+ criterion++executable bad-read-file+ main-is: BadReadFile.hs++ ghc-options: -Wall -rtsopts+ build-depends:+ base == 4.*,+ criterion++executable good-read-file+ main-is: GoodReadFile.hs++ ghc-options: -Wall -rtsopts+ build-depends:+ base == 4.*,+ criterion++-- Cannot uncomment due to https://github.com/haskell/cabal/issues/1725+--+-- executable judy+-- main-is: Judy.hs+--+-- buildable: False+-- ghc-options: -Wall -rtsopts+-- build-depends:+-- base == 4.*,+-- criterion,+-- judy
+ examples/fibber.html view
@@ -0,0 +1,726 @@+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">+<html>+ <head>+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8">+ <title>criterion report</title>+ <script language="javascript" type="text/javascript">+ /*! jQuery v2.1.1 | (c) 2005, 2014 jQuery Foundation, Inc. | jquery.org/license */+!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=c.slice,e=c.concat,f=c.push,g=c.indexOf,h={},i=h.toString,j=h.hasOwnProperty,k={},l=a.document,m="2.1.1",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return d.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:d.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a,b){return n.each(this,a,b)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(d.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:f,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(a=arguments[h]))for(b in a)c=g[b],d=a[b],g!==d&&(j&&d&&(n.isPlainObject(d)||(e=n.isArray(d)))?(e?(e=!1,f=c&&n.isArray(c)?c:[]):f=c&&n.isPlainObject(c)?c:{},g[b]=n.extend(j,f,d)):void 0!==d&&(g[b]=d));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray,isWindow:function(a){return null!=a&&a===a.window},isNumeric:function(a){return!n.isArray(a)&&a-parseFloat(a)>=0},isPlainObject:function(a){return"object"!==n.type(a)||a.nodeType||n.isWindow(a)?!1:a.constructor&&!j.call(a.constructor.prototype,"isPrototypeOf")?!1:!0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?h[i.call(a)]||"object":typeof a},globalEval:function(a){var b,c=eval;a=n.trim(a),a&&(1===a.indexOf("use strict")?(b=l.createElement("script"),b.text=a,l.head.appendChild(b).parentNode.removeChild(b)):c(a))},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b,c){var d,e=0,f=a.length,g=s(a);if(c){if(g){for(;f>e;e++)if(d=b.apply(a[e],c),d===!1)break}else for(e in a)if(d=b.apply(a[e],c),d===!1)break}else if(g){for(;f>e;e++)if(d=b.call(a[e],e,a[e]),d===!1)break}else for(e in a)if(d=b.call(a[e],e,a[e]),d===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):f.call(c,a)),c},inArray:function(a,b,c){return null==b?-1:g.call(b,a,c)},merge:function(a,b){for(var c=+b.length,d=0,e=a.length;c>d;d++)a[e++]=b[d];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,f=0,g=a.length,h=s(a),i=[];if(h)for(;g>f;f++)d=b(a[f],f,c),null!=d&&i.push(d);else for(f in a)d=b(a[f],f,c),null!=d&&i.push(d);return e.apply([],i)},guid:1,proxy:function(a,b){var c,e,f;return"string"==typeof b&&(c=a[b],b=a,a=c),n.isFunction(a)?(e=d.call(arguments,2),f=function(){return a.apply(b||this,e.concat(d.call(arguments)))},f.guid=a.guid=a.guid||n.guid++,f):void 0},now:Date.now,support:k}),n.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(a,b){h["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:1===a.nodeType&&b?!0:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+-new Date,v=a.document,w=0,x=0,y=gb(),z=gb(),A=gb(),B=function(a,b){return a===b&&(l=!0),0},C="undefined",D=1<<31,E={}.hasOwnProperty,F=[],G=F.pop,H=F.push,I=F.push,J=F.slice,K=F.indexOf||function(a){for(var b=0,c=this.length;c>b;b++)if(this[b]===a)return b;return-1},L="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",N="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",O=N.replace("w","w#"),P="\\["+M+"*("+N+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+O+"))|)"+M+"*\\]",Q=":("+N+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+P+")*)|.*)\\)|)",R=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),S=new RegExp("^"+M+"*,"+M+"*"),T=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),U=new RegExp("="+M+"*([^\\]'\"]*?)"+M+"*\\]","g"),V=new RegExp(Q),W=new RegExp("^"+O+"$"),X={ID:new RegExp("^#("+N+")"),CLASS:new RegExp("^\\.("+N+")"),TAG:new RegExp("^("+N.replace("w","w*")+")"),ATTR:new RegExp("^"+P),PSEUDO:new RegExp("^"+Q),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+L+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/^(?:input|select|textarea|button)$/i,Z=/^h\d$/i,$=/^[^{]+\{\s*\[native \w/,_=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ab=/[+~]/,bb=/'|\\/g,cb=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),db=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)};try{I.apply(F=J.call(v.childNodes),v.childNodes),F[v.childNodes.length].nodeType}catch(eb){I={apply:F.length?function(a,b){H.apply(a,J.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function fb(a,b,d,e){var f,h,j,k,l,o,r,s,w,x;if((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,d=d||[],!a||"string"!=typeof a)return d;if(1!==(k=b.nodeType)&&9!==k)return[];if(p&&!e){if(f=_.exec(a))if(j=f[1]){if(9===k){if(h=b.getElementById(j),!h||!h.parentNode)return d;if(h.id===j)return d.push(h),d}else if(b.ownerDocument&&(h=b.ownerDocument.getElementById(j))&&t(b,h)&&h.id===j)return d.push(h),d}else{if(f[2])return I.apply(d,b.getElementsByTagName(a)),d;if((j=f[3])&&c.getElementsByClassName&&b.getElementsByClassName)return I.apply(d,b.getElementsByClassName(j)),d}if(c.qsa&&(!q||!q.test(a))){if(s=r=u,w=b,x=9===k&&a,1===k&&"object"!==b.nodeName.toLowerCase()){o=g(a),(r=b.getAttribute("id"))?s=r.replace(bb,"\\$&"):b.setAttribute("id",s),s="[id='"+s+"'] ",l=o.length;while(l--)o[l]=s+qb(o[l]);w=ab.test(a)&&ob(b.parentNode)||b,x=o.join(",")}if(x)try{return I.apply(d,w.querySelectorAll(x)),d}catch(y){}finally{r||b.removeAttribute("id")}}}return i(a.replace(R,"$1"),b,d,e)}function gb(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function hb(a){return a[u]=!0,a}function ib(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function jb(a,b){var c=a.split("|"),e=a.length;while(e--)d.attrHandle[c[e]]=b}function kb(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||D)-(~a.sourceIndex||D);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function lb(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function mb(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function nb(a){return hb(function(b){return b=+b,hb(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function ob(a){return a&&typeof a.getElementsByTagName!==C&&a}c=fb.support={},f=fb.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=fb.setDocument=function(a){var b,e=a?a.ownerDocument||a:v,g=e.defaultView;return e!==n&&9===e.nodeType&&e.documentElement?(n=e,o=e.documentElement,p=!f(e),g&&g!==g.top&&(g.addEventListener?g.addEventListener("unload",function(){m()},!1):g.attachEvent&&g.attachEvent("onunload",function(){m()})),c.attributes=ib(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ib(function(a){return a.appendChild(e.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=$.test(e.getElementsByClassName)&&ib(function(a){return a.innerHTML="<div class='a'></div><div class='a i'></div>",a.firstChild.className="i",2===a.getElementsByClassName("i").length}),c.getById=ib(function(a){return o.appendChild(a).id=u,!e.getElementsByName||!e.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if(typeof b.getElementById!==C&&p){var c=b.getElementById(a);return c&&c.parentNode?[c]:[]}},d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){var c=typeof a.getAttributeNode!==C&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return typeof b.getElementsByTagName!==C?b.getElementsByTagName(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return typeof b.getElementsByClassName!==C&&p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=$.test(e.querySelectorAll))&&(ib(function(a){a.innerHTML="<select msallowclip=''><option selected=''></option></select>",a.querySelectorAll("[msallowclip^='']").length&&q.push("[*^$]="+M+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+M+"*(?:value|"+L+")"),a.querySelectorAll(":checked").length||q.push(":checked")}),ib(function(a){var b=e.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+M+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=$.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ib(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",Q)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=$.test(o.compareDocumentPosition),t=b||$.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===e||a.ownerDocument===v&&t(v,a)?-1:b===e||b.ownerDocument===v&&t(v,b)?1:k?K.call(k,a)-K.call(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,f=a.parentNode,g=b.parentNode,h=[a],i=[b];if(!f||!g)return a===e?-1:b===e?1:f?-1:g?1:k?K.call(k,a)-K.call(k,b):0;if(f===g)return kb(a,b);c=a;while(c=c.parentNode)h.unshift(c);c=b;while(c=c.parentNode)i.unshift(c);while(h[d]===i[d])d++;return d?kb(h[d],i[d]):h[d]===v?-1:i[d]===v?1:0},e):n},fb.matches=function(a,b){return fb(a,null,null,b)},fb.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(U,"='$1']"),!(!c.matchesSelector||!p||r&&r.test(b)||q&&q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return fb(b,n,null,[a]).length>0},fb.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},fb.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&E.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},fb.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},fb.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=fb.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=fb.selectors={cacheLength:50,createPseudo:hb,match:X,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(cb,db),a[3]=(a[3]||a[4]||a[5]||"").replace(cb,db),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||fb.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&fb.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return X.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&V.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(cb,db).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+M+")"+a+"("+M+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||typeof a.getAttribute!==C&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=fb.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h;if(q){if(f){while(p){l=b;while(l=l[p])if(h?l.nodeName.toLowerCase()===r:1===l.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){k=q[u]||(q[u]={}),j=k[a]||[],n=j[0]===w&&j[1],m=j[0]===w&&j[2],l=n&&q.childNodes[n];while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if(1===l.nodeType&&++m&&l===b){k[a]=[w,n,m];break}}else if(s&&(j=(b[u]||(b[u]={}))[a])&&j[0]===w)m=j[1];else while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if((h?l.nodeName.toLowerCase()===r:1===l.nodeType)&&++m&&(s&&((l[u]||(l[u]={}))[a]=[w,m]),l===b))break;return m-=e,m===d||m%d===0&&m/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||fb.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?hb(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=K.call(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:hb(function(a){var b=[],c=[],d=h(a.replace(R,"$1"));return d[u]?hb(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),!c.pop()}}),has:hb(function(a){return function(b){return fb(a,b).length>0}}),contains:hb(function(a){return function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:hb(function(a){return W.test(a||"")||fb.error("unsupported lang: "+a),a=a.replace(cb,db).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Z.test(a.nodeName)},input:function(a){return Y.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:nb(function(){return[0]}),last:nb(function(a,b){return[b-1]}),eq:nb(function(a,b,c){return[0>c?c+b:c]}),even:nb(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:nb(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:nb(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:nb(function(a,b,c){for(var d=0>c?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=lb(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=mb(b);function pb(){}pb.prototype=d.filters=d.pseudos,d.setFilters=new pb,g=fb.tokenize=function(a,b){var c,e,f,g,h,i,j,k=z[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){(!c||(e=S.exec(h)))&&(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=T.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(R," ")}),h=h.slice(c.length));for(g in d.filter)!(e=X[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?fb.error(a):z(a,i).slice(0)};function qb(a){for(var b=0,c=a.length,d="";c>b;b++)d+=a[b].value;return d}function rb(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(i=b[u]||(b[u]={}),(h=i[d])&&h[0]===w&&h[1]===f)return j[2]=h[2];if(i[d]=j,j[2]=a(b,c,g))return!0}}}function sb(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function tb(a,b,c){for(var d=0,e=b.length;e>d;d++)fb(a,b[d],c);return c}function ub(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(!c||c(f,d,e))&&(g.push(f),j&&b.push(h));return g}function vb(a,b,c,d,e,f){return d&&!d[u]&&(d=vb(d)),e&&!e[u]&&(e=vb(e,f)),hb(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||tb(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:ub(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=ub(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?K.call(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=ub(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):I.apply(g,r)})}function wb(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=rb(function(a){return a===b},h,!0),l=rb(function(a){return K.call(b,a)>-1},h,!0),m=[function(a,c,d){return!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d))}];f>i;i++)if(c=d.relative[a[i].type])m=[rb(sb(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return vb(i>1&&sb(m),i>1&&qb(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(R,"$1"),c,e>i&&wb(a.slice(i,e)),f>e&&wb(a=a.slice(e)),f>e&&qb(a))}m.push(c)}return sb(m)}function xb(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,m,o,p=0,q="0",r=f&&[],s=[],t=j,u=f||e&&d.find.TAG("*",k),v=w+=null==t?1:Math.random()||.1,x=u.length;for(k&&(j=g!==n&&g);q!==x&&null!=(l=u[q]);q++){if(e&&l){m=0;while(o=a[m++])if(o(l,g,h)){i.push(l);break}k&&(w=v)}c&&((l=!o&&l)&&p--,f&&r.push(l))}if(p+=q,c&&q!==p){m=0;while(o=b[m++])o(r,s,g,h);if(f){if(p>0)while(q--)r[q]||s[q]||(s[q]=G.call(i));s=ub(s)}I.apply(i,s),k&&!f&&s.length>0&&p+b.length>1&&fb.uniqueSort(i)}return k&&(w=v,j=t),r};return c?hb(f):f}return h=fb.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=wb(b[c]),f[u]?d.push(f):e.push(f);f=A(a,xb(e,d)),f.selector=a}return f},i=fb.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(cb,db),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=X.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(cb,db),ab.test(j[0].type)&&ob(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&qb(j),!a)return I.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,ab.test(a)&&ob(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ib(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ib(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||jb("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ib(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||jb("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ib(function(a){return null==a.getAttribute("disabled")})||jb(L,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),fb}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=n.expr.match.needsContext,v=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,w=/^.[^:#\[\.,]*$/;function x(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(w.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return g.call(b,a)>=0!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=this.length,d=[],e=this;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;c>b;b++)if(n.contains(e[b],this))return!0}));for(b=0;c>b;b++)n.find(a,e[b],d);return d=this.pushStack(c>1?n.unique(d):d),d.selector=this.selector?this.selector+" "+a:a,d},filter:function(a){return this.pushStack(x(this,a||[],!1))},not:function(a){return this.pushStack(x(this,a||[],!0))},is:function(a){return!!x(this,"string"==typeof a&&u.test(a)?n(a):a||[],!1).length}});var y,z=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,A=n.fn.init=function(a,b){var c,d;if(!a)return this;if("string"==typeof a){if(c="<"===a[0]&&">"===a[a.length-1]&&a.length>=3?[null,a,null]:z.exec(a),!c||!c[1]&&b)return!b||b.jquery?(b||y).find(a):this.constructor(b).find(a);if(c[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(c[1],b&&b.nodeType?b.ownerDocument||b:l,!0)),v.test(c[1])&&n.isPlainObject(b))for(c in b)n.isFunction(this[c])?this[c](b[c]):this.attr(c,b[c]);return this}return d=l.getElementById(c[2]),d&&d.parentNode&&(this.length=1,this[0]=d),this.context=l,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?"undefined"!=typeof y.ready?y.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};A.prototype=n.fn,y=n(l);var B=/^(?:parents|prev(?:Until|All))/,C={children:!0,contents:!0,next:!0,prev:!0};n.extend({dir:function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},sibling:function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c}}),n.fn.extend({has:function(a){var b=n(a,this),c=b.length;return this.filter(function(){for(var a=0;c>a;a++)if(n.contains(this,b[a]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=u.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.unique(f):f)},index:function(a){return a?"string"==typeof a?g.call(n(a),this[0]):g.call(this,a.jquery?a[0]:a):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.unique(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function D(a,b){while((a=a[b])&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return n.dir(a,"parentNode")},parentsUntil:function(a,b,c){return n.dir(a,"parentNode",c)},next:function(a){return D(a,"nextSibling")},prev:function(a){return D(a,"previousSibling")},nextAll:function(a){return n.dir(a,"nextSibling")},prevAll:function(a){return n.dir(a,"previousSibling")},nextUntil:function(a,b,c){return n.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return n.dir(a,"previousSibling",c)},siblings:function(a){return n.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return n.sibling(a.firstChild)},contents:function(a){return a.contentDocument||n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(C[a]||n.unique(e),B.test(a)&&e.reverse()),this.pushStack(e)}});var E=/\S+/g,F={};function G(a){var b=F[a]={};return n.each(a.match(E)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?F[a]||G(a):n.extend({},a);var b,c,d,e,f,g,h=[],i=!a.once&&[],j=function(l){for(b=a.memory&&l,c=!0,g=e||0,e=0,f=h.length,d=!0;h&&f>g;g++)if(h[g].apply(l[0],l[1])===!1&&a.stopOnFalse){b=!1;break}d=!1,h&&(i?i.length&&j(i.shift()):b?h=[]:k.disable())},k={add:function(){if(h){var c=h.length;!function g(b){n.each(b,function(b,c){var d=n.type(c);"function"===d?a.unique&&k.has(c)||h.push(c):c&&c.length&&"string"!==d&&g(c)})}(arguments),d?f=h.length:b&&(e=c,j(b))}return this},remove:function(){return h&&n.each(arguments,function(a,b){var c;while((c=n.inArray(b,h,c))>-1)h.splice(c,1),d&&(f>=c&&f--,g>=c&&g--)}),this},has:function(a){return a?n.inArray(a,h)>-1:!(!h||!h.length)},empty:function(){return h=[],f=0,this},disable:function(){return h=i=b=void 0,this},disabled:function(){return!h},lock:function(){return i=void 0,b||k.disable(),this},locked:function(){return!i},fireWith:function(a,b){return!h||c&&!i||(b=b||[],b=[a,b.slice?b.slice():b],d?i.push(b):j(b)),this},fire:function(){return k.fireWith(this,arguments),this},fired:function(){return!!c}};return k},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=d.call(arguments),e=c.length,f=1!==e||a&&n.isFunction(a.promise)?e:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(e){b[a]=this,c[a]=arguments.length>1?d.call(arguments):e,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(e>1)for(i=new Array(e),j=new Array(e),k=new Array(e);e>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().done(h(b,k,c)).fail(g.reject).progress(h(b,j,i)):--f;return f||g.resolveWith(k,c),g.promise()}});var H;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){(a===!0?--n.readyWait:n.isReady)||(n.isReady=!0,a!==!0&&--n.readyWait>0||(H.resolveWith(l,[n]),n.fn.triggerHandler&&(n(l).triggerHandler("ready"),n(l).off("ready"))))}});function I(){l.removeEventListener("DOMContentLoaded",I,!1),a.removeEventListener("load",I,!1),n.ready()}n.ready.promise=function(b){return H||(H=n.Deferred(),"complete"===l.readyState?setTimeout(n.ready):(l.addEventListener("DOMContentLoaded",I,!1),a.addEventListener("load",I,!1))),H.promise(b)},n.ready.promise();var J=n.access=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===n.type(c)){e=!0;for(h in c)n.access(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,n.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(n(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f};n.acceptData=function(a){return 1===a.nodeType||9===a.nodeType||!+a.nodeType};function K(){Object.defineProperty(this.cache={},0,{get:function(){return{}}}),this.expando=n.expando+Math.random()}K.uid=1,K.accepts=n.acceptData,K.prototype={key:function(a){if(!K.accepts(a))return 0;var b={},c=a[this.expando];if(!c){c=K.uid++;try{b[this.expando]={value:c},Object.defineProperties(a,b)}catch(d){b[this.expando]=c,n.extend(a,b)}}return this.cache[c]||(this.cache[c]={}),c},set:function(a,b,c){var d,e=this.key(a),f=this.cache[e];if("string"==typeof b)f[b]=c;else if(n.isEmptyObject(f))n.extend(this.cache[e],b);else for(d in b)f[d]=b[d];return f},get:function(a,b){var c=this.cache[this.key(a)];return void 0===b?c:c[b]},access:function(a,b,c){var d;return void 0===b||b&&"string"==typeof b&&void 0===c?(d=this.get(a,b),void 0!==d?d:this.get(a,n.camelCase(b))):(this.set(a,b,c),void 0!==c?c:b)},remove:function(a,b){var c,d,e,f=this.key(a),g=this.cache[f];if(void 0===b)this.cache[f]={};else{n.isArray(b)?d=b.concat(b.map(n.camelCase)):(e=n.camelCase(b),b in g?d=[b,e]:(d=e,d=d in g?[d]:d.match(E)||[])),c=d.length;while(c--)delete g[d[c]]}},hasData:function(a){return!n.isEmptyObject(this.cache[a[this.expando]]||{})},discard:function(a){a[this.expando]&&delete this.cache[a[this.expando]]}};var L=new K,M=new K,N=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function P(a,b,c){var d;if(void 0===c&&1===a.nodeType)if(d="data-"+b.replace(O,"-$1").toLowerCase(),c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:N.test(c)?n.parseJSON(c):c}catch(e){}M.set(a,b,c)}else c=void 0;return c}n.extend({hasData:function(a){return M.hasData(a)||L.hasData(a)},data:function(a,b,c){return M.access(a,b,c)},removeData:function(a,b){M.remove(a,b)+},_data:function(a,b,c){return L.access(a,b,c)},_removeData:function(a,b){L.remove(a,b)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=M.get(f),1===f.nodeType&&!L.get(f,"hasDataAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),P(f,d,e[d])));L.set(f,"hasDataAttrs",!0)}return e}return"object"==typeof a?this.each(function(){M.set(this,a)}):J(this,function(b){var c,d=n.camelCase(a);if(f&&void 0===b){if(c=M.get(f,a),void 0!==c)return c;if(c=M.get(f,d),void 0!==c)return c;if(c=P(f,d,void 0),void 0!==c)return c}else this.each(function(){var c=M.get(this,d);M.set(this,d,b),-1!==a.indexOf("-")&&void 0!==c&&M.set(this,a,b)})},null,b,arguments.length>1,null,!0)},removeData:function(a){return this.each(function(){M.remove(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=L.get(a,b),c&&(!d||n.isArray(c)?d=L.access(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return L.get(a,c)||L.access(a,c,{empty:n.Callbacks("once memory").add(function(){L.remove(a,[b+"queue",c])})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?n.queue(this[0],a):void 0===b?this:this.each(function(){var c=n.queue(this,a,b);n._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&n.dequeue(this,a)})},dequeue:function(a){return this.each(function(){n.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=n.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=L.get(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}});var Q=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,R=["Top","Right","Bottom","Left"],S=function(a,b){return a=b||a,"none"===n.css(a,"display")||!n.contains(a.ownerDocument,a)},T=/^(?:checkbox|radio)$/i;!function(){var a=l.createDocumentFragment(),b=a.appendChild(l.createElement("div")),c=l.createElement("input");c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),b.appendChild(c),k.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,b.innerHTML="<textarea>x</textarea>",k.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue}();var U="undefined";k.focusinBubbles="onfocusin"in a;var V=/^key/,W=/^(?:mouse|pointer|contextmenu)|click/,X=/^(?:focusinfocus|focusoutblur)$/,Y=/^([^.]*)(?:\.(.+)|)$/;function Z(){return!0}function $(){return!1}function _(){try{return l.activeElement}catch(a){}}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.get(a);if(r){c.handler&&(f=c,c=f.handler,e=f.selector),c.guid||(c.guid=n.guid++),(i=r.events)||(i=r.events={}),(g=r.handle)||(g=r.handle=function(b){return typeof n!==U&&n.event.triggered!==b.type?n.event.dispatch.apply(a,arguments):void 0}),b=(b||"").match(E)||[""],j=b.length;while(j--)h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o&&(l=n.event.special[o]||{},o=(e?l.delegateType:l.bindType)||o,l=n.event.special[o]||{},k=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},f),(m=i[o])||(m=i[o]=[],m.delegateCount=0,l.setup&&l.setup.call(a,d,p,g)!==!1||a.addEventListener&&a.addEventListener(o,g,!1)),l.add&&(l.add.call(a,k),k.handler.guid||(k.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,k):m.push(k),n.event.global[o]=!0)}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.hasData(a)&&L.get(a);if(r&&(i=r.events)){b=(b||"").match(E)||[""],j=b.length;while(j--)if(h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=i[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),g=f=m.length;while(f--)k=m[f],!e&&q!==k.origType||c&&c.guid!==k.guid||h&&!h.test(k.namespace)||d&&d!==k.selector&&("**"!==d||!k.selector)||(m.splice(f,1),k.selector&&m.delegateCount--,l.remove&&l.remove.call(a,k));g&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete i[o])}else for(o in i)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(i)&&(delete r.handle,L.remove(a,"events"))}},trigger:function(b,c,d,e){var f,g,h,i,k,m,o,p=[d||l],q=j.call(b,"type")?b.type:b,r=j.call(b,"namespace")?b.namespace.split("."):[];if(g=h=d=d||l,3!==d.nodeType&&8!==d.nodeType&&!X.test(q+n.event.triggered)&&(q.indexOf(".")>=0&&(r=q.split("."),q=r.shift(),r.sort()),k=q.indexOf(":")<0&&"on"+q,b=b[n.expando]?b:new n.Event(q,"object"==typeof b&&b),b.isTrigger=e?2:3,b.namespace=r.join("."),b.namespace_re=b.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=d),c=null==c?[b]:n.makeArray(c,[b]),o=n.event.special[q]||{},e||!o.trigger||o.trigger.apply(d,c)!==!1)){if(!e&&!o.noBubble&&!n.isWindow(d)){for(i=o.delegateType||q,X.test(i+q)||(g=g.parentNode);g;g=g.parentNode)p.push(g),h=g;h===(d.ownerDocument||l)&&p.push(h.defaultView||h.parentWindow||a)}f=0;while((g=p[f++])&&!b.isPropagationStopped())b.type=f>1?i:o.bindType||q,m=(L.get(g,"events")||{})[b.type]&&L.get(g,"handle"),m&&m.apply(g,c),m=k&&g[k],m&&m.apply&&n.acceptData(g)&&(b.result=m.apply(g,c),b.result===!1&&b.preventDefault());return b.type=q,e||b.isDefaultPrevented()||o._default&&o._default.apply(p.pop(),c)!==!1||!n.acceptData(d)||k&&n.isFunction(d[q])&&!n.isWindow(d)&&(h=d[k],h&&(d[k]=null),n.event.triggered=q,d[q](),n.event.triggered=void 0,h&&(d[k]=h)),b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,e,f,g,h=[],i=d.call(arguments),j=(L.get(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())(!a.namespace_re||a.namespace_re.test(g.namespace))&&(a.handleObj=g,a.data=g.data,e=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==e&&(a.result=e)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&(!a.button||"click"!==a.type))for(;i!==this;i=i.parentNode||this)if(i.disabled!==!0||"click"!==a.type){for(d=[],c=0;h>c;c++)f=b[c],e=f.selector+" ",void 0===d[e]&&(d[e]=f.needsContext?n(e,this).index(i)>=0:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h<b.length&&g.push({elem:this,handlers:b.slice(h)}),g},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,b){var c,d,e,f=b.button;return null==a.pageX&&null!=b.clientX&&(c=a.target.ownerDocument||l,d=c.documentElement,e=c.body,a.pageX=b.clientX+(d&&d.scrollLeft||e&&e.scrollLeft||0)-(d&&d.clientLeft||e&&e.clientLeft||0),a.pageY=b.clientY+(d&&d.scrollTop||e&&e.scrollTop||0)-(d&&d.clientTop||e&&e.clientTop||0)),a.which||void 0===f||(a.which=1&f?1:2&f?3:4&f?2:0),a}},fix:function(a){if(a[n.expando])return a;var b,c,d,e=a.type,f=a,g=this.fixHooks[e];g||(this.fixHooks[e]=g=W.test(e)?this.mouseHooks:V.test(e)?this.keyHooks:{}),d=g.props?this.props.concat(g.props):this.props,a=new n.Event(f),b=d.length;while(b--)c=d[b],a[c]=f[c];return a.target||(a.target=l),3===a.target.nodeType&&(a.target=a.target.parentNode),g.filter?g.filter(a,f):a},special:{load:{noBubble:!0},focus:{trigger:function(){return this!==_()&&this.focus?(this.focus(),!1):void 0},delegateType:"focusin"},blur:{trigger:function(){return this===_()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return"checkbox"===this.type&&this.click&&n.nodeName(this,"input")?(this.click(),!1):void 0},_default:function(a){return n.nodeName(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&a.originalEvent&&(a.originalEvent.returnValue=a.result)}}},simulate:function(a,b,c,d){var e=n.extend(new n.Event,c,{type:a,isSimulated:!0,originalEvent:{}});d?n.event.trigger(e,null,b):n.event.dispatch.call(b,e),e.isDefaultPrevented()&&c.preventDefault()}},n.removeEvent=function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)},n.Event=function(a,b){return this instanceof n.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&a.returnValue===!1?Z:$):this.type=a,b&&n.extend(this,b),this.timeStamp=a&&a.timeStamp||n.now(),void(this[n.expando]=!0)):new n.Event(a,b)},n.Event.prototype={isDefaultPrevented:$,isPropagationStopped:$,isImmediatePropagationStopped:$,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=Z,a&&a.preventDefault&&a.preventDefault()},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=Z,a&&a.stopPropagation&&a.stopPropagation()},stopImmediatePropagation:function(){var a=this.originalEvent;this.isImmediatePropagationStopped=Z,a&&a.stopImmediatePropagation&&a.stopImmediatePropagation(),this.stopPropagation()}},n.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(a,b){n.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return(!e||e!==d&&!n.contains(d,e))&&(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),k.focusinBubbles||n.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){n.event.simulate(b,a.target,n.event.fix(a),!0)};n.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=L.access(d,b);e||d.addEventListener(a,c,!0),L.access(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=L.access(d,b)-1;e?L.access(d,b,e):(d.removeEventListener(a,c,!0),L.remove(d,b))}}}),n.fn.extend({on:function(a,b,c,d,e){var f,g;if("object"==typeof a){"string"!=typeof b&&(c=c||b,b=void 0);for(g in a)this.on(g,b,c,a[g],e);return this}if(null==c&&null==d?(d=b,c=b=void 0):null==d&&("string"==typeof b?(d=c,c=void 0):(d=c,c=b,b=void 0)),d===!1)d=$;else if(!d)return this;return 1===e&&(f=d,d=function(a){return n().off(a),f.apply(this,arguments)},d.guid=f.guid||(f.guid=n.guid++)),this.each(function(){n.event.add(this,a,d,c,b)})},one:function(a,b,c,d){return this.on(a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,n(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return(b===!1||"function"==typeof b)&&(c=b,b=void 0),c===!1&&(c=$),this.each(function(){n.event.remove(this,a,c,b)})},trigger:function(a,b){return this.each(function(){n.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];return c?n.event.trigger(a,b,c,!0):void 0}});var ab=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,bb=/<([\w:]+)/,cb=/<|&#?\w+;/,db=/<(?:script|style|link)/i,eb=/checked\s*(?:[^=]|=\s*.checked.)/i,fb=/^$|\/(?:java|ecma)script/i,gb=/^true\/(.*)/,hb=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,ib={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};ib.optgroup=ib.option,ib.tbody=ib.tfoot=ib.colgroup=ib.caption=ib.thead,ib.th=ib.td;function jb(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function kb(a){return a.type=(null!==a.getAttribute("type"))+"/"+a.type,a}function lb(a){var b=gb.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function mb(a,b){for(var c=0,d=a.length;d>c;c++)L.set(a[c],"globalEval",!b||L.get(b[c],"globalEval"))}function nb(a,b){var c,d,e,f,g,h,i,j;if(1===b.nodeType){if(L.hasData(a)&&(f=L.access(a),g=L.set(b,f),j=f.events)){delete g.handle,g.events={};for(e in j)for(c=0,d=j[e].length;d>c;c++)n.event.add(b,e,j[e][c])}M.hasData(a)&&(h=M.access(a),i=n.extend({},h),M.set(b,i))}}function ob(a,b){var c=a.getElementsByTagName?a.getElementsByTagName(b||"*"):a.querySelectorAll?a.querySelectorAll(b||"*"):[];return void 0===b||b&&n.nodeName(a,b)?n.merge([a],c):c}function pb(a,b){var c=b.nodeName.toLowerCase();"input"===c&&T.test(a.type)?b.checked=a.checked:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}n.extend({clone:function(a,b,c){var d,e,f,g,h=a.cloneNode(!0),i=n.contains(a.ownerDocument,a);if(!(k.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(g=ob(h),f=ob(a),d=0,e=f.length;e>d;d++)pb(f[d],g[d]);if(b)if(c)for(f=f||ob(a),g=g||ob(h),d=0,e=f.length;e>d;d++)nb(f[d],g[d]);else nb(a,h);return g=ob(h,"script"),g.length>0&&mb(g,!i&&ob(a,"script")),h},buildFragment:function(a,b,c,d){for(var e,f,g,h,i,j,k=b.createDocumentFragment(),l=[],m=0,o=a.length;o>m;m++)if(e=a[m],e||0===e)if("object"===n.type(e))n.merge(l,e.nodeType?[e]:e);else if(cb.test(e)){f=f||k.appendChild(b.createElement("div")),g=(bb.exec(e)||["",""])[1].toLowerCase(),h=ib[g]||ib._default,f.innerHTML=h[1]+e.replace(ab,"<$1></$2>")+h[2],j=h[0];while(j--)f=f.lastChild;n.merge(l,f.childNodes),f=k.firstChild,f.textContent=""}else l.push(b.createTextNode(e));k.textContent="",m=0;while(e=l[m++])if((!d||-1===n.inArray(e,d))&&(i=n.contains(e.ownerDocument,e),f=ob(k.appendChild(e),"script"),i&&mb(f),c)){j=0;while(e=f[j++])fb.test(e.type||"")&&c.push(e)}return k},cleanData:function(a){for(var b,c,d,e,f=n.event.special,g=0;void 0!==(c=a[g]);g++){if(n.acceptData(c)&&(e=c[L.expando],e&&(b=L.cache[e]))){if(b.events)for(d in b.events)f[d]?n.event.remove(c,d):n.removeEvent(c,d,b.handle);L.cache[e]&&delete L.cache[e]}delete M.cache[c[M.expando]]}}}),n.fn.extend({text:function(a){return J(this,function(a){return void 0===a?n.text(this):this.empty().each(function(){(1===this.nodeType||11===this.nodeType||9===this.nodeType)&&(this.textContent=a)})},null,a,arguments.length)},append:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=jb(this,a);b.appendChild(a)}})},prepend:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=jb(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},remove:function(a,b){for(var c,d=a?n.filter(a,this):this,e=0;null!=(c=d[e]);e++)b||1!==c.nodeType||n.cleanData(ob(c)),c.parentNode&&(b&&n.contains(c.ownerDocument,c)&&mb(ob(c,"script")),c.parentNode.removeChild(c));return this},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)1===a.nodeType&&(n.cleanData(ob(a,!1)),a.textContent="");return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return J(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a&&1===b.nodeType)return b.innerHTML;if("string"==typeof a&&!db.test(a)&&!ib[(bb.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(ab,"<$1></$2>");try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(ob(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=arguments[0];return this.domManip(arguments,function(b){a=this.parentNode,n.cleanData(ob(this)),a&&a.replaceChild(b,this)}),a&&(a.length||a.nodeType)?this:this.remove()},detach:function(a){return this.remove(a,!0)},domManip:function(a,b){a=e.apply([],a);var c,d,f,g,h,i,j=0,l=this.length,m=this,o=l-1,p=a[0],q=n.isFunction(p);if(q||l>1&&"string"==typeof p&&!k.checkClone&&eb.test(p))return this.each(function(c){var d=m.eq(c);q&&(a[0]=p.call(this,c,d.html())),d.domManip(a,b)});if(l&&(c=n.buildFragment(a,this[0].ownerDocument,!1,this),d=c.firstChild,1===c.childNodes.length&&(c=d),d)){for(f=n.map(ob(c,"script"),kb),g=f.length;l>j;j++)h=c,j!==o&&(h=n.clone(h,!0,!0),g&&n.merge(f,ob(h,"script"))),b.call(this[j],h,j);if(g)for(i=f[f.length-1].ownerDocument,n.map(f,lb),j=0;g>j;j++)h=f[j],fb.test(h.type||"")&&!L.access(h,"globalEval")&&n.contains(i,h)&&(h.src?n._evalUrl&&n._evalUrl(h.src):n.globalEval(h.textContent.replace(hb,"")))}return this}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=[],e=n(a),g=e.length-1,h=0;g>=h;h++)c=h===g?this:this.clone(!0),n(e[h])[b](c),f.apply(d,c.get());return this.pushStack(d)}});var qb,rb={};function sb(b,c){var d,e=n(c.createElement(b)).appendTo(c.body),f=a.getDefaultComputedStyle&&(d=a.getDefaultComputedStyle(e[0]))?d.display:n.css(e[0],"display");return e.detach(),f}function tb(a){var b=l,c=rb[a];return c||(c=sb(a,b),"none"!==c&&c||(qb=(qb||n("<iframe frameborder='0' width='0' height='0'/>")).appendTo(b.documentElement),b=qb[0].contentDocument,b.write(),b.close(),c=sb(a,b),qb.detach()),rb[a]=c),c}var ub=/^margin/,vb=new RegExp("^("+Q+")(?!px)[a-z%]+$","i"),wb=function(a){return a.ownerDocument.defaultView.getComputedStyle(a,null)};function xb(a,b,c){var d,e,f,g,h=a.style;return c=c||wb(a),c&&(g=c.getPropertyValue(b)||c[b]),c&&(""!==g||n.contains(a.ownerDocument,a)||(g=n.style(a,b)),vb.test(g)&&ub.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f)),void 0!==g?g+"":g}function yb(a,b){return{get:function(){return a()?void delete this.get:(this.get=b).apply(this,arguments)}}}!function(){var b,c,d=l.documentElement,e=l.createElement("div"),f=l.createElement("div");if(f.style){f.style.backgroundClip="content-box",f.cloneNode(!0).style.backgroundClip="",k.clearCloneStyle="content-box"===f.style.backgroundClip,e.style.cssText="border:0;width:0;height:0;top:0;left:-9999px;margin-top:1px;position:absolute",e.appendChild(f);function g(){f.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",f.innerHTML="",d.appendChild(e);var g=a.getComputedStyle(f,null);b="1%"!==g.top,c="4px"===g.width,d.removeChild(e)}a.getComputedStyle&&n.extend(k,{pixelPosition:function(){return g(),b},boxSizingReliable:function(){return null==c&&g(),c},reliableMarginRight:function(){var b,c=f.appendChild(l.createElement("div"));return c.style.cssText=f.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",c.style.marginRight=c.style.width="0",f.style.width="1px",d.appendChild(e),b=!parseFloat(a.getComputedStyle(c,null).marginRight),d.removeChild(e),b}})}}(),n.swap=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e};var zb=/^(none|table(?!-c[ea]).+)/,Ab=new RegExp("^("+Q+")(.*)$","i"),Bb=new RegExp("^([+-])=("+Q+")","i"),Cb={position:"absolute",visibility:"hidden",display:"block"},Db={letterSpacing:"0",fontWeight:"400"},Eb=["Webkit","O","Moz","ms"];function Fb(a,b){if(b in a)return b;var c=b[0].toUpperCase()+b.slice(1),d=b,e=Eb.length;while(e--)if(b=Eb[e]+c,b in a)return b;return d}function Gb(a,b,c){var d=Ab.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function Hb(a,b,c,d,e){for(var f=c===(d?"border":"content")?4:"width"===b?1:0,g=0;4>f;f+=2)"margin"===c&&(g+=n.css(a,c+R[f],!0,e)),d?("content"===c&&(g-=n.css(a,"padding"+R[f],!0,e)),"margin"!==c&&(g-=n.css(a,"border"+R[f]+"Width",!0,e))):(g+=n.css(a,"padding"+R[f],!0,e),"padding"!==c&&(g+=n.css(a,"border"+R[f]+"Width",!0,e)));return g}function Ib(a,b,c){var d=!0,e="width"===b?a.offsetWidth:a.offsetHeight,f=wb(a),g="border-box"===n.css(a,"boxSizing",!1,f);if(0>=e||null==e){if(e=xb(a,b,f),(0>e||null==e)&&(e=a.style[b]),vb.test(e))return e;d=g&&(k.boxSizingReliable()||e===a.style[b]),e=parseFloat(e)||0}return e+Hb(a,b,c||(g?"border":"content"),d,f)+"px"}function Jb(a,b){for(var c,d,e,f=[],g=0,h=a.length;h>g;g++)d=a[g],d.style&&(f[g]=L.get(d,"olddisplay"),c=d.style.display,b?(f[g]||"none"!==c||(d.style.display=""),""===d.style.display&&S(d)&&(f[g]=L.access(d,"olddisplay",tb(d.nodeName)))):(e=S(d),"none"===c&&e||L.set(d,"olddisplay",e?c:n.css(d,"display"))));for(g=0;h>g;g++)d=a[g],d.style&&(b&&"none"!==d.style.display&&""!==d.style.display||(d.style.display=b?f[g]||"":"none"));return a}n.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=xb(a,"opacity");return""===c?"1":c}}}},cssNumber:{columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":"cssFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=n.camelCase(b),i=a.style;return b=n.cssProps[h]||(n.cssProps[h]=Fb(i,h)),g=n.cssHooks[b]||n.cssHooks[h],void 0===c?g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:i[b]:(f=typeof c,"string"===f&&(e=Bb.exec(c))&&(c=(e[1]+1)*e[2]+parseFloat(n.css(a,b)),f="number"),null!=c&&c===c&&("number"!==f||n.cssNumber[h]||(c+="px"),k.clearCloneStyle||""!==c||0!==b.indexOf("background")||(i[b]="inherit"),g&&"set"in g&&void 0===(c=g.set(a,c,d))||(i[b]=c)),void 0)}},css:function(a,b,c,d){var e,f,g,h=n.camelCase(b);return b=n.cssProps[h]||(n.cssProps[h]=Fb(a.style,h)),g=n.cssHooks[b]||n.cssHooks[h],g&&"get"in g&&(e=g.get(a,!0,c)),void 0===e&&(e=xb(a,b,d)),"normal"===e&&b in Db&&(e=Db[b]),""===c||c?(f=parseFloat(e),c===!0||n.isNumeric(f)?f||0:e):e}}),n.each(["height","width"],function(a,b){n.cssHooks[b]={get:function(a,c,d){return c?zb.test(n.css(a,"display"))&&0===a.offsetWidth?n.swap(a,Cb,function(){return Ib(a,b,d)}):Ib(a,b,d):void 0},set:function(a,c,d){var e=d&&wb(a);return Gb(a,c,d?Hb(a,b,d,"border-box"===n.css(a,"boxSizing",!1,e),e):0)}}}),n.cssHooks.marginRight=yb(k.reliableMarginRight,function(a,b){return b?n.swap(a,{display:"inline-block"},xb,[a,"marginRight"]):void 0}),n.each({margin:"",padding:"",border:"Width"},function(a,b){n.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];4>d;d++)e[a+R[d]+b]=f[d]||f[d-2]||f[0];return e}},ub.test(a)||(n.cssHooks[a+b].set=Gb)}),n.fn.extend({css:function(a,b){return J(this,function(a,b,c){var d,e,f={},g=0;if(n.isArray(b)){for(d=wb(a),e=b.length;e>g;g++)f[b[g]]=n.css(a,b[g],!1,d);return f}return void 0!==c?n.style(a,b,c):n.css(a,b)},a,b,arguments.length>1)},show:function(){return Jb(this,!0)},hide:function(){return Jb(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){S(this)?n(this).show():n(this).hide()})}});function Kb(a,b,c,d,e){return new Kb.prototype.init(a,b,c,d,e)}n.Tween=Kb,Kb.prototype={constructor:Kb,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||"swing",this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(n.cssNumber[c]?"":"px")},cur:function(){var a=Kb.propHooks[this.prop];return a&&a.get?a.get(this):Kb.propHooks._default.get(this)},run:function(a){var b,c=Kb.propHooks[this.prop];return this.pos=b=this.options.duration?n.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):Kb.propHooks._default.set(this),this}},Kb.prototype.init.prototype=Kb.prototype,Kb.propHooks={_default:{get:function(a){var b;return null==a.elem[a.prop]||a.elem.style&&null!=a.elem.style[a.prop]?(b=n.css(a.elem,a.prop,""),b&&"auto"!==b?b:0):a.elem[a.prop]},set:function(a){n.fx.step[a.prop]?n.fx.step[a.prop](a):a.elem.style&&(null!=a.elem.style[n.cssProps[a.prop]]||n.cssHooks[a.prop])?n.style(a.elem,a.prop,a.now+a.unit):a.elem[a.prop]=a.now}}},Kb.propHooks.scrollTop=Kb.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},n.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2}},n.fx=Kb.prototype.init,n.fx.step={};var Lb,Mb,Nb=/^(?:toggle|show|hide)$/,Ob=new RegExp("^(?:([+-])=|)("+Q+")([a-z%]*)$","i"),Pb=/queueHooks$/,Qb=[Vb],Rb={"*":[function(a,b){var c=this.createTween(a,b),d=c.cur(),e=Ob.exec(b),f=e&&e[3]||(n.cssNumber[a]?"":"px"),g=(n.cssNumber[a]||"px"!==f&&+d)&&Ob.exec(n.css(c.elem,a)),h=1,i=20;if(g&&g[3]!==f){f=f||g[3],e=e||[],g=+d||1;do h=h||".5",g/=h,n.style(c.elem,a,g+f);while(h!==(h=c.cur()/d)&&1!==h&&--i)}return e&&(g=c.start=+g||+d||0,c.unit=f,c.end=e[1]?g+(e[1]+1)*e[2]:+e[2]),c}]};function Sb(){return setTimeout(function(){Lb=void 0}),Lb=n.now()}function Tb(a,b){var c,d=0,e={height:a};for(b=b?1:0;4>d;d+=2-b)c=R[d],e["margin"+c]=e["padding"+c]=a;return b&&(e.opacity=e.width=a),e}function Ub(a,b,c){for(var d,e=(Rb[b]||[]).concat(Rb["*"]),f=0,g=e.length;g>f;f++)if(d=e[f].call(c,b,a))return d}function Vb(a,b,c){var d,e,f,g,h,i,j,k,l=this,m={},o=a.style,p=a.nodeType&&S(a),q=L.get(a,"fxshow");c.queue||(h=n._queueHooks(a,"fx"),null==h.unqueued&&(h.unqueued=0,i=h.empty.fire,h.empty.fire=function(){h.unqueued||i()}),h.unqueued++,l.always(function(){l.always(function(){h.unqueued--,n.queue(a,"fx").length||h.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[o.overflow,o.overflowX,o.overflowY],j=n.css(a,"display"),k="none"===j?L.get(a,"olddisplay")||tb(a.nodeName):j,"inline"===k&&"none"===n.css(a,"float")&&(o.display="inline-block")),c.overflow&&(o.overflow="hidden",l.always(function(){o.overflow=c.overflow[0],o.overflowX=c.overflow[1],o.overflowY=c.overflow[2]}));for(d in b)if(e=b[d],Nb.exec(e)){if(delete b[d],f=f||"toggle"===e,e===(p?"hide":"show")){if("show"!==e||!q||void 0===q[d])continue;p=!0}m[d]=q&&q[d]||n.style(a,d)}else j=void 0;if(n.isEmptyObject(m))"inline"===("none"===j?tb(a.nodeName):j)&&(o.display=j);else{q?"hidden"in q&&(p=q.hidden):q=L.access(a,"fxshow",{}),f&&(q.hidden=!p),p?n(a).show():l.done(function(){n(a).hide()}),l.done(function(){var b;L.remove(a,"fxshow");for(b in m)n.style(a,b,m[b])});for(d in m)g=Ub(p?q[d]:0,d,l),d in q||(q[d]=g.start,p&&(g.end=g.start,g.start="width"===d||"height"===d?1:0))}}function Wb(a,b){var c,d,e,f,g;for(c in a)if(d=n.camelCase(c),e=b[d],f=a[c],n.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=n.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function Xb(a,b,c){var d,e,f=0,g=Qb.length,h=n.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=Lb||Sb(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;i>g;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),1>f&&i?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:n.extend({},b),opts:n.extend(!0,{specialEasing:{}},c),originalProperties:b,originalOptions:c,startTime:Lb||Sb(),duration:c.duration,tweens:[],createTween:function(b,c){var d=n.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;d>c;c++)j.tweens[c].run(1);return b?h.resolveWith(a,[j,b]):h.rejectWith(a,[j,b]),this}}),k=j.props;for(Wb(k,j.opts.specialEasing);g>f;f++)if(d=Qb[f].call(j,a,k,j.opts))return d;return n.map(k,Ub,j),n.isFunction(j.opts.start)&&j.opts.start.call(a,j),n.fx.timer(n.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}n.Animation=n.extend(Xb,{tweener:function(a,b){n.isFunction(a)?(b=a,a=["*"]):a=a.split(" ");for(var c,d=0,e=a.length;e>d;d++)c=a[d],Rb[c]=Rb[c]||[],Rb[c].unshift(b)},prefilter:function(a,b){b?Qb.unshift(a):Qb.push(a)}}),n.speed=function(a,b,c){var d=a&&"object"==typeof a?n.extend({},a):{complete:c||!c&&b||n.isFunction(a)&&a,duration:a,easing:c&&b||b&&!n.isFunction(b)&&b};return d.duration=n.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in n.fx.speeds?n.fx.speeds[d.duration]:n.fx.speeds._default,(null==d.queue||d.queue===!0)&&(d.queue="fx"),d.old=d.complete,d.complete=function(){n.isFunction(d.old)&&d.old.call(this),d.queue&&n.dequeue(this,d.queue)},d},n.fn.extend({fadeTo:function(a,b,c,d){return this.filter(S).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=n.isEmptyObject(a),f=n.speed(b,c,d),g=function(){var b=Xb(this,n.extend({},a),f);(e||L.get(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=n.timers,g=L.get(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&Pb.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));(b||!c)&&n.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=L.get(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=n.timers,g=d?d.length:0;for(c.finish=!0,n.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;g>b;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),n.each(["toggle","show","hide"],function(a,b){var c=n.fn[b];n.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(Tb(b,!0),a,d,e)}}),n.each({slideDown:Tb("show"),slideUp:Tb("hide"),slideToggle:Tb("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){n.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),n.timers=[],n.fx.tick=function(){var a,b=0,c=n.timers;for(Lb=n.now();b<c.length;b++)a=c[b],a()||c[b]!==a||c.splice(b--,1);c.length||n.fx.stop(),Lb=void 0},n.fx.timer=function(a){n.timers.push(a),a()?n.fx.start():n.timers.pop()},n.fx.interval=13,n.fx.start=function(){Mb||(Mb=setInterval(n.fx.tick,n.fx.interval))},n.fx.stop=function(){clearInterval(Mb),Mb=null},n.fx.speeds={slow:600,fast:200,_default:400},n.fn.delay=function(a,b){return a=n.fx?n.fx.speeds[a]||a:a,b=b||"fx",this.queue(b,function(b,c){var d=setTimeout(b,a);c.stop=function(){clearTimeout(d)}})},function(){var a=l.createElement("input"),b=l.createElement("select"),c=b.appendChild(l.createElement("option"));a.type="checkbox",k.checkOn=""!==a.value,k.optSelected=c.selected,b.disabled=!0,k.optDisabled=!c.disabled,a=l.createElement("input"),a.value="t",a.type="radio",k.radioValue="t"===a.value}();var Yb,Zb,$b=n.expr.attrHandle;n.fn.extend({attr:function(a,b){return J(this,n.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){n.removeAttr(this,a)})}}),n.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(a&&3!==f&&8!==f&&2!==f)return typeof a.getAttribute===U?n.prop(a,b,c):(1===f&&n.isXMLDoc(a)||(b=b.toLowerCase(),d=n.attrHooks[b]||(n.expr.match.bool.test(b)?Zb:Yb)),void 0===c?d&&"get"in d&&null!==(e=d.get(a,b))?e:(e=n.find.attr(a,b),null==e?void 0:e):null!==c?d&&"set"in d&&void 0!==(e=d.set(a,c,b))?e:(a.setAttribute(b,c+""),c):void n.removeAttr(a,b))+},removeAttr:function(a,b){var c,d,e=0,f=b&&b.match(E);if(f&&1===a.nodeType)while(c=f[e++])d=n.propFix[c]||c,n.expr.match.bool.test(c)&&(a[d]=!1),a.removeAttribute(c)},attrHooks:{type:{set:function(a,b){if(!k.radioValue&&"radio"===b&&n.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}}}),Zb={set:function(a,b,c){return b===!1?n.removeAttr(a,c):a.setAttribute(c,c),c}},n.each(n.expr.match.bool.source.match(/\w+/g),function(a,b){var c=$b[b]||n.find.attr;$b[b]=function(a,b,d){var e,f;return d||(f=$b[b],$b[b]=e,e=null!=c(a,b,d)?b.toLowerCase():null,$b[b]=f),e}});var _b=/^(?:input|select|textarea|button)$/i;n.fn.extend({prop:function(a,b){return J(this,n.prop,a,b,arguments.length>1)},removeProp:function(a){return this.each(function(){delete this[n.propFix[a]||a]})}}),n.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(a,b,c){var d,e,f,g=a.nodeType;if(a&&3!==g&&8!==g&&2!==g)return f=1!==g||!n.isXMLDoc(a),f&&(b=n.propFix[b]||b,e=n.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){return a.hasAttribute("tabindex")||_b.test(a.nodeName)||a.href?a.tabIndex:-1}}}}),k.optSelected||(n.propHooks.selected={get:function(a){var b=a.parentNode;return b&&b.parentNode&&b.parentNode.selectedIndex,null}}),n.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){n.propFix[this.toLowerCase()]=this});var ac=/[\t\r\n\f]/g;n.fn.extend({addClass:function(a){var b,c,d,e,f,g,h="string"==typeof a&&a,i=0,j=this.length;if(n.isFunction(a))return this.each(function(b){n(this).addClass(a.call(this,b,this.className))});if(h)for(b=(a||"").match(E)||[];j>i;i++)if(c=this[i],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(ac," "):" ")){f=0;while(e=b[f++])d.indexOf(" "+e+" ")<0&&(d+=e+" ");g=n.trim(d),c.className!==g&&(c.className=g)}return this},removeClass:function(a){var b,c,d,e,f,g,h=0===arguments.length||"string"==typeof a&&a,i=0,j=this.length;if(n.isFunction(a))return this.each(function(b){n(this).removeClass(a.call(this,b,this.className))});if(h)for(b=(a||"").match(E)||[];j>i;i++)if(c=this[i],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(ac," "):"")){f=0;while(e=b[f++])while(d.indexOf(" "+e+" ")>=0)d=d.replace(" "+e+" "," ");g=a?n.trim(d):"",c.className!==g&&(c.className=g)}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):this.each(n.isFunction(a)?function(c){n(this).toggleClass(a.call(this,c,this.className,b),b)}:function(){if("string"===c){var b,d=0,e=n(this),f=a.match(E)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else(c===U||"boolean"===c)&&(this.className&&L.set(this,"__className__",this.className),this.className=this.className||a===!1?"":L.get(this,"__className__")||"")})},hasClass:function(a){for(var b=" "+a+" ",c=0,d=this.length;d>c;c++)if(1===this[c].nodeType&&(" "+this[c].className+" ").replace(ac," ").indexOf(b)>=0)return!0;return!1}});var bc=/\r/g;n.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=n.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,n(this).val()):a,null==e?e="":"number"==typeof e?e+="":n.isArray(e)&&(e=n.map(e,function(a){return null==a?"":a+""})),b=n.valHooks[this.type]||n.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=n.valHooks[e.type]||n.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(bc,""):null==c?"":c)}}}),n.extend({valHooks:{option:{get:function(a){var b=n.find.attr(a,"value");return null!=b?b:n.trim(n.text(a))}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||0>e,g=f?null:[],h=f?e+1:d.length,i=0>e?h:f?e:0;h>i;i++)if(c=d[i],!(!c.selected&&i!==e||(k.optDisabled?c.disabled:null!==c.getAttribute("disabled"))||c.parentNode.disabled&&n.nodeName(c.parentNode,"optgroup"))){if(b=n(c).val(),f)return b;g.push(b)}return g},set:function(a,b){var c,d,e=a.options,f=n.makeArray(b),g=e.length;while(g--)d=e[g],(d.selected=n.inArray(d.value,f)>=0)&&(c=!0);return c||(a.selectedIndex=-1),f}}}}),n.each(["radio","checkbox"],function(){n.valHooks[this]={set:function(a,b){return n.isArray(b)?a.checked=n.inArray(n(a).val(),b)>=0:void 0}},k.checkOn||(n.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})}),n.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){n.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),n.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)},bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}});var cc=n.now(),dc=/\?/;n.parseJSON=function(a){return JSON.parse(a+"")},n.parseXML=function(a){var b,c;if(!a||"string"!=typeof a)return null;try{c=new DOMParser,b=c.parseFromString(a,"text/xml")}catch(d){b=void 0}return(!b||b.getElementsByTagName("parsererror").length)&&n.error("Invalid XML: "+a),b};var ec,fc,gc=/#.*$/,hc=/([?&])_=[^&]*/,ic=/^(.*?):[ \t]*([^\r\n]*)$/gm,jc=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,kc=/^(?:GET|HEAD)$/,lc=/^\/\//,mc=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,nc={},oc={},pc="*/".concat("*");try{fc=location.href}catch(qc){fc=l.createElement("a"),fc.href="",fc=fc.href}ec=mc.exec(fc.toLowerCase())||[];function rc(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(E)||[];if(n.isFunction(c))while(d=f[e++])"+"===d[0]?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function sc(a,b,c,d){var e={},f=a===oc;function g(h){var i;return e[h]=!0,n.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function tc(a,b){var c,d,e=n.ajaxSettings.flatOptions||{};for(c in b)void 0!==b[c]&&((e[c]?a:d||(d={}))[c]=b[c]);return d&&n.extend(!0,a,d),a}function uc(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===d&&(d=a.mimeType||b.getResponseHeader("Content-Type"));if(d)for(e in h)if(h[e]&&h[e].test(d)){i.unshift(e);break}if(i[0]in c)f=i[0];else{for(e in c){if(!i[0]||a.converters[e+" "+i[0]]){f=e;break}g||(g=e)}f=f||g}return f?(f!==i[0]&&i.unshift(f),c[f]):void 0}function vc(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}n.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:fc,type:"GET",isLocal:jc.test(ec[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":pc,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":n.parseJSON,"text xml":n.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?tc(tc(a,n.ajaxSettings),b):tc(n.ajaxSettings,a)},ajaxPrefilter:rc(nc),ajaxTransport:rc(oc),ajax:function(a,b){"object"==typeof a&&(b=a,a=void 0),b=b||{};var c,d,e,f,g,h,i,j,k=n.ajaxSetup({},b),l=k.context||k,m=k.context&&(l.nodeType||l.jquery)?n(l):n.event,o=n.Deferred(),p=n.Callbacks("once memory"),q=k.statusCode||{},r={},s={},t=0,u="canceled",v={readyState:0,getResponseHeader:function(a){var b;if(2===t){if(!f){f={};while(b=ic.exec(e))f[b[1].toLowerCase()]=b[2]}b=f[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return 2===t?e:null},setRequestHeader:function(a,b){var c=a.toLowerCase();return t||(a=s[c]=s[c]||a,r[a]=b),this},overrideMimeType:function(a){return t||(k.mimeType=a),this},statusCode:function(a){var b;if(a)if(2>t)for(b in a)q[b]=[q[b],a[b]];else v.always(a[v.status]);return this},abort:function(a){var b=a||u;return c&&c.abort(b),x(0,b),this}};if(o.promise(v).complete=p.add,v.success=v.done,v.error=v.fail,k.url=((a||k.url||fc)+"").replace(gc,"").replace(lc,ec[1]+"//"),k.type=b.method||b.type||k.method||k.type,k.dataTypes=n.trim(k.dataType||"*").toLowerCase().match(E)||[""],null==k.crossDomain&&(h=mc.exec(k.url.toLowerCase()),k.crossDomain=!(!h||h[1]===ec[1]&&h[2]===ec[2]&&(h[3]||("http:"===h[1]?"80":"443"))===(ec[3]||("http:"===ec[1]?"80":"443")))),k.data&&k.processData&&"string"!=typeof k.data&&(k.data=n.param(k.data,k.traditional)),sc(nc,k,b,v),2===t)return v;i=k.global,i&&0===n.active++&&n.event.trigger("ajaxStart"),k.type=k.type.toUpperCase(),k.hasContent=!kc.test(k.type),d=k.url,k.hasContent||(k.data&&(d=k.url+=(dc.test(d)?"&":"?")+k.data,delete k.data),k.cache===!1&&(k.url=hc.test(d)?d.replace(hc,"$1_="+cc++):d+(dc.test(d)?"&":"?")+"_="+cc++)),k.ifModified&&(n.lastModified[d]&&v.setRequestHeader("If-Modified-Since",n.lastModified[d]),n.etag[d]&&v.setRequestHeader("If-None-Match",n.etag[d])),(k.data&&k.hasContent&&k.contentType!==!1||b.contentType)&&v.setRequestHeader("Content-Type",k.contentType),v.setRequestHeader("Accept",k.dataTypes[0]&&k.accepts[k.dataTypes[0]]?k.accepts[k.dataTypes[0]]+("*"!==k.dataTypes[0]?", "+pc+"; q=0.01":""):k.accepts["*"]);for(j in k.headers)v.setRequestHeader(j,k.headers[j]);if(k.beforeSend&&(k.beforeSend.call(l,v,k)===!1||2===t))return v.abort();u="abort";for(j in{success:1,error:1,complete:1})v[j](k[j]);if(c=sc(oc,k,b,v)){v.readyState=1,i&&m.trigger("ajaxSend",[v,k]),k.async&&k.timeout>0&&(g=setTimeout(function(){v.abort("timeout")},k.timeout));try{t=1,c.send(r,x)}catch(w){if(!(2>t))throw w;x(-1,w)}}else x(-1,"No Transport");function x(a,b,f,h){var j,r,s,u,w,x=b;2!==t&&(t=2,g&&clearTimeout(g),c=void 0,e=h||"",v.readyState=a>0?4:0,j=a>=200&&300>a||304===a,f&&(u=uc(k,v,f)),u=vc(k,u,v,j),j?(k.ifModified&&(w=v.getResponseHeader("Last-Modified"),w&&(n.lastModified[d]=w),w=v.getResponseHeader("etag"),w&&(n.etag[d]=w)),204===a||"HEAD"===k.type?x="nocontent":304===a?x="notmodified":(x=u.state,r=u.data,s=u.error,j=!s)):(s=x,(a||!x)&&(x="error",0>a&&(a=0))),v.status=a,v.statusText=(b||x)+"",j?o.resolveWith(l,[r,x,v]):o.rejectWith(l,[v,x,s]),v.statusCode(q),q=void 0,i&&m.trigger(j?"ajaxSuccess":"ajaxError",[v,k,j?r:s]),p.fireWith(l,[v,x]),i&&(m.trigger("ajaxComplete",[v,k]),--n.active||n.event.trigger("ajaxStop")))}return v},getJSON:function(a,b,c){return n.get(a,b,c,"json")},getScript:function(a,b){return n.get(a,void 0,b,"script")}}),n.each(["get","post"],function(a,b){n[b]=function(a,c,d,e){return n.isFunction(c)&&(e=e||d,d=c,c=void 0),n.ajax({url:a,type:b,dataType:e,data:c,success:d})}}),n.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){n.fn[b]=function(a){return this.on(b,a)}}),n._evalUrl=function(a){return n.ajax({url:a,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},n.fn.extend({wrapAll:function(a){var b;return n.isFunction(a)?this.each(function(b){n(this).wrapAll(a.call(this,b))}):(this[0]&&(b=n(a,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstElementChild)a=a.firstElementChild;return a}).append(this)),this)},wrapInner:function(a){return this.each(n.isFunction(a)?function(b){n(this).wrapInner(a.call(this,b))}:function(){var b=n(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=n.isFunction(a);return this.each(function(c){n(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){n.nodeName(this,"body")||n(this).replaceWith(this.childNodes)}).end()}}),n.expr.filters.hidden=function(a){return a.offsetWidth<=0&&a.offsetHeight<=0},n.expr.filters.visible=function(a){return!n.expr.filters.hidden(a)};var wc=/%20/g,xc=/\[\]$/,yc=/\r?\n/g,zc=/^(?:submit|button|image|reset|file)$/i,Ac=/^(?:input|select|textarea|keygen)/i;function Bc(a,b,c,d){var e;if(n.isArray(b))n.each(b,function(b,e){c||xc.test(a)?d(a,e):Bc(a+"["+("object"==typeof e?b:"")+"]",e,c,d)});else if(c||"object"!==n.type(b))d(a,b);else for(e in b)Bc(a+"["+e+"]",b[e],c,d)}n.param=function(a,b){var c,d=[],e=function(a,b){b=n.isFunction(b)?b():null==b?"":b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(void 0===b&&(b=n.ajaxSettings&&n.ajaxSettings.traditional),n.isArray(a)||a.jquery&&!n.isPlainObject(a))n.each(a,function(){e(this.name,this.value)});else for(c in a)Bc(c,a[c],b,e);return d.join("&").replace(wc,"+")},n.fn.extend({serialize:function(){return n.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=n.prop(this,"elements");return a?n.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!n(this).is(":disabled")&&Ac.test(this.nodeName)&&!zc.test(a)&&(this.checked||!T.test(a))}).map(function(a,b){var c=n(this).val();return null==c?null:n.isArray(c)?n.map(c,function(a){return{name:b.name,value:a.replace(yc,"\r\n")}}):{name:b.name,value:c.replace(yc,"\r\n")}}).get()}}),n.ajaxSettings.xhr=function(){try{return new XMLHttpRequest}catch(a){}};var Cc=0,Dc={},Ec={0:200,1223:204},Fc=n.ajaxSettings.xhr();a.ActiveXObject&&n(a).on("unload",function(){for(var a in Dc)Dc[a]()}),k.cors=!!Fc&&"withCredentials"in Fc,k.ajax=Fc=!!Fc,n.ajaxTransport(function(a){var b;return k.cors||Fc&&!a.crossDomain?{send:function(c,d){var e,f=a.xhr(),g=++Cc;if(f.open(a.type,a.url,a.async,a.username,a.password),a.xhrFields)for(e in a.xhrFields)f[e]=a.xhrFields[e];a.mimeType&&f.overrideMimeType&&f.overrideMimeType(a.mimeType),a.crossDomain||c["X-Requested-With"]||(c["X-Requested-With"]="XMLHttpRequest");for(e in c)f.setRequestHeader(e,c[e]);b=function(a){return function(){b&&(delete Dc[g],b=f.onload=f.onerror=null,"abort"===a?f.abort():"error"===a?d(f.status,f.statusText):d(Ec[f.status]||f.status,f.statusText,"string"==typeof f.responseText?{text:f.responseText}:void 0,f.getAllResponseHeaders()))}},f.onload=b(),f.onerror=b("error"),b=Dc[g]=b("abort");try{f.send(a.hasContent&&a.data||null)}catch(h){if(b)throw h}},abort:function(){b&&b()}}:void 0}),n.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(a){return n.globalEval(a),a}}}),n.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET")}),n.ajaxTransport("script",function(a){if(a.crossDomain){var b,c;return{send:function(d,e){b=n("<script>").prop({async:!0,charset:a.scriptCharset,src:a.url}).on("load error",c=function(a){b.remove(),c=null,a&&e("error"===a.type?404:200,a.type)}),l.head.appendChild(b[0])},abort:function(){c&&c()}}}});var Gc=[],Hc=/(=)\?(?=&|$)|\?\?/;n.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=Gc.pop()||n.expando+"_"+cc++;return this[a]=!0,a}}),n.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(Hc.test(b.url)?"url":"string"==typeof b.data&&!(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&Hc.test(b.data)&&"data");return h||"jsonp"===b.dataTypes[0]?(e=b.jsonpCallback=n.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(Hc,"$1"+e):b.jsonp!==!1&&(b.url+=(dc.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||n.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,Gc.push(e)),g&&n.isFunction(f)&&f(g[0]),g=f=void 0}),"script"):void 0}),n.parseHTML=function(a,b,c){if(!a||"string"!=typeof a)return null;"boolean"==typeof b&&(c=b,b=!1),b=b||l;var d=v.exec(a),e=!c&&[];return d?[b.createElement(d[1])]:(d=n.buildFragment([a],b,e),e&&e.length&&n(e).remove(),n.merge([],d.childNodes))};var Ic=n.fn.load;n.fn.load=function(a,b,c){if("string"!=typeof a&&Ic)return Ic.apply(this,arguments);var d,e,f,g=this,h=a.indexOf(" ");return h>=0&&(d=n.trim(a.slice(h)),a=a.slice(0,h)),n.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(e="POST"),g.length>0&&n.ajax({url:a,type:e,dataType:"html",data:b}).done(function(a){f=arguments,g.html(d?n("<div>").append(n.parseHTML(a)).find(d):a)}).complete(c&&function(a,b){g.each(c,f||[a.responseText,b,a])}),this},n.expr.filters.animated=function(a){return n.grep(n.timers,function(b){return a===b.elem}).length};var Jc=a.document.documentElement;function Kc(a){return n.isWindow(a)?a:9===a.nodeType&&a.defaultView}n.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=n.css(a,"position"),l=n(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=n.css(a,"top"),i=n.css(a,"left"),j=("absolute"===k||"fixed"===k)&&(f+i).indexOf("auto")>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),n.isFunction(b)&&(b=b.call(a,c,h)),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},n.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){n.offset.setOffset(this,a,b)});var b,c,d=this[0],e={top:0,left:0},f=d&&d.ownerDocument;if(f)return b=f.documentElement,n.contains(b,d)?(typeof d.getBoundingClientRect!==U&&(e=d.getBoundingClientRect()),c=Kc(f),{top:e.top+c.pageYOffset-b.clientTop,left:e.left+c.pageXOffset-b.clientLeft}):e},position:function(){if(this[0]){var a,b,c=this[0],d={top:0,left:0};return"fixed"===n.css(c,"position")?b=c.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),n.nodeName(a[0],"html")||(d=a.offset()),d.top+=n.css(a[0],"borderTopWidth",!0),d.left+=n.css(a[0],"borderLeftWidth",!0)),{top:b.top-d.top-n.css(c,"marginTop",!0),left:b.left-d.left-n.css(c,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||Jc;while(a&&!n.nodeName(a,"html")&&"static"===n.css(a,"position"))a=a.offsetParent;return a||Jc})}}),n.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(b,c){var d="pageYOffset"===c;n.fn[b]=function(e){return J(this,function(b,e,f){var g=Kc(b);return void 0===f?g?g[c]:b[e]:void(g?g.scrollTo(d?a.pageXOffset:f,d?f:a.pageYOffset):b[e]=f)},b,e,arguments.length,null)}}),n.each(["top","left"],function(a,b){n.cssHooks[b]=yb(k.pixelPosition,function(a,c){return c?(c=xb(a,b),vb.test(c)?n(a).position()[b]+"px":c):void 0})}),n.each({Height:"height",Width:"width"},function(a,b){n.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){n.fn[d]=function(d,e){var f=arguments.length&&(c||"boolean"!=typeof d),g=c||(d===!0||e===!0?"margin":"border");return J(this,function(b,c,d){var e;return n.isWindow(b)?b.document.documentElement["client"+a]:9===b.nodeType?(e=b.documentElement,Math.max(b.body["scroll"+a],e["scroll"+a],b.body["offset"+a],e["offset"+a],e["client"+a])):void 0===d?n.css(b,c,g):n.style(b,c,d,g)},b,f?d:void 0,f,null)}})}),n.fn.size=function(){return this.length},n.fn.andSelf=n.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return n});var Lc=a.jQuery,Mc=a.$;return n.noConflict=function(b){return a.$===n&&(a.$=Mc),b&&a.jQuery===n&&(a.jQuery=Lc),n},typeof b===U&&(a.jQuery=a.$=n),n});++ </script>+ <script language="javascript" type="text/javascript">+ /* Javascript plotting library for jQuery, version 0.8.3.++Copyright (c) 2007-2014 IOLA and Ole Laursen.+Licensed under the MIT license.++*/+(function($){$.color={};$.color.make=function(r,g,b,a){var o={};o.r=r||0;o.g=g||0;o.b=b||0;o.a=a!=null?a:1;o.add=function(c,d){for(var i=0;i<c.length;++i)o[c.charAt(i)]+=d;return o.normalize()};o.scale=function(c,f){for(var i=0;i<c.length;++i)o[c.charAt(i)]*=f;return o.normalize()};o.toString=function(){if(o.a>=1){return"rgb("+[o.r,o.g,o.b].join(",")+")"}else{return"rgba("+[o.r,o.g,o.b,o.a].join(",")+")"}};o.normalize=function(){function clamp(min,value,max){return value<min?min:value>max?max:value}o.r=clamp(0,parseInt(o.r),255);o.g=clamp(0,parseInt(o.g),255);o.b=clamp(0,parseInt(o.b),255);o.a=clamp(0,o.a,1);return o};o.clone=function(){return $.color.make(o.r,o.b,o.g,o.a)};return o.normalize()};$.color.extract=function(elem,css){var c;do{c=elem.css(css).toLowerCase();if(c!=""&&c!="transparent")break;elem=elem.parent()}while(elem.length&&!$.nodeName(elem.get(0),"body"));if(c=="rgba(0, 0, 0, 0)")c="transparent";return $.color.parse(c)};$.color.parse=function(str){var res,m=$.color.make;if(res=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(str))return m(parseInt(res[1],10),parseInt(res[2],10),parseInt(res[3],10));if(res=/rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]+(?:\.[0-9]+)?)\s*\)/.exec(str))return m(parseInt(res[1],10),parseInt(res[2],10),parseInt(res[3],10),parseFloat(res[4]));if(res=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(str))return m(parseFloat(res[1])*2.55,parseFloat(res[2])*2.55,parseFloat(res[3])*2.55);if(res=/rgba\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\s*\)/.exec(str))return m(parseFloat(res[1])*2.55,parseFloat(res[2])*2.55,parseFloat(res[3])*2.55,parseFloat(res[4]));if(res=/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(str))return m(parseInt(res[1],16),parseInt(res[2],16),parseInt(res[3],16));if(res=/#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(str))return m(parseInt(res[1]+res[1],16),parseInt(res[2]+res[2],16),parseInt(res[3]+res[3],16));var name=$.trim(str).toLowerCase();if(name=="transparent")return m(255,255,255,0);else{res=lookupColors[name]||[0,0,0];return m(res[0],res[1],res[2])}};var lookupColors={aqua:[0,255,255],azure:[240,255,255],beige:[245,245,220],black:[0,0,0],blue:[0,0,255],brown:[165,42,42],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgrey:[169,169,169],darkgreen:[0,100,0],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkviolet:[148,0,211],fuchsia:[255,0,255],gold:[255,215,0],green:[0,128,0],indigo:[75,0,130],khaki:[240,230,140],lightblue:[173,216,230],lightcyan:[224,255,255],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightyellow:[255,255,224],lime:[0,255,0],magenta:[255,0,255],maroon:[128,0,0],navy:[0,0,128],olive:[128,128,0],orange:[255,165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0]}})(jQuery);(function($){var hasOwnProperty=Object.prototype.hasOwnProperty;if(!$.fn.detach){$.fn.detach=function(){return this.each(function(){if(this.parentNode){this.parentNode.removeChild(this)}})}}function Canvas(cls,container){var element=container.children("."+cls)[0];if(element==null){element=document.createElement("canvas");element.className=cls;$(element).css({direction:"ltr",position:"absolute",left:0,top:0}).appendTo(container);if(!element.getContext){if(window.G_vmlCanvasManager){element=window.G_vmlCanvasManager.initElement(element)}else{throw new Error("Canvas is not available. If you're using IE with a fall-back such as Excanvas, then there's either a mistake in your conditional include, or the page has no DOCTYPE and is rendering in Quirks Mode.")}}}this.element=element;var context=this.context=element.getContext("2d");var devicePixelRatio=window.devicePixelRatio||1,backingStoreRatio=context.webkitBackingStorePixelRatio||context.mozBackingStorePixelRatio||context.msBackingStorePixelRatio||context.oBackingStorePixelRatio||context.backingStorePixelRatio||1;this.pixelRatio=devicePixelRatio/backingStoreRatio;this.resize(container.width(),container.height());this.textContainer=null;this.text={};this._textCache={}}Canvas.prototype.resize=function(width,height){if(width<=0||height<=0){throw new Error("Invalid dimensions for plot, width = "+width+", height = "+height)}var element=this.element,context=this.context,pixelRatio=this.pixelRatio;if(this.width!=width){element.width=width*pixelRatio;element.style.width=width+"px";this.width=width}if(this.height!=height){element.height=height*pixelRatio;element.style.height=height+"px";this.height=height}context.restore();context.save();context.scale(pixelRatio,pixelRatio)};Canvas.prototype.clear=function(){this.context.clearRect(0,0,this.width,this.height)};Canvas.prototype.render=function(){var cache=this._textCache;for(var layerKey in cache){if(hasOwnProperty.call(cache,layerKey)){var layer=this.getTextLayer(layerKey),layerCache=cache[layerKey];layer.hide();for(var styleKey in layerCache){if(hasOwnProperty.call(layerCache,styleKey)){var styleCache=layerCache[styleKey];for(var key in styleCache){if(hasOwnProperty.call(styleCache,key)){var positions=styleCache[key].positions;for(var i=0,position;position=positions[i];i++){if(position.active){if(!position.rendered){layer.append(position.element);position.rendered=true}}else{positions.splice(i--,1);if(position.rendered){position.element.detach()}}}if(positions.length==0){delete styleCache[key]}}}}}layer.show()}}};Canvas.prototype.getTextLayer=function(classes){var layer=this.text[classes];if(layer==null){if(this.textContainer==null){this.textContainer=$("<div class='flot-text'></div>").css({position:"absolute",top:0,left:0,bottom:0,right:0,"font-size":"smaller",color:"#545454"}).insertAfter(this.element)}layer=this.text[classes]=$("<div></div>").addClass(classes).css({position:"absolute",top:0,left:0,bottom:0,right:0}).appendTo(this.textContainer)}return layer};Canvas.prototype.getTextInfo=function(layer,text,font,angle,width){var textStyle,layerCache,styleCache,info;text=""+text;if(typeof font==="object"){textStyle=font.style+" "+font.variant+" "+font.weight+" "+font.size+"px/"+font.lineHeight+"px "+font.family}else{textStyle=font}layerCache=this._textCache[layer];if(layerCache==null){layerCache=this._textCache[layer]={}}styleCache=layerCache[textStyle];if(styleCache==null){styleCache=layerCache[textStyle]={}}info=styleCache[text];if(info==null){var element=$("<div></div>").html(text).css({position:"absolute","max-width":width,top:-9999}).appendTo(this.getTextLayer(layer));if(typeof font==="object"){element.css({font:textStyle,color:font.color})}else if(typeof font==="string"){element.addClass(font)}info=styleCache[text]={width:element.outerWidth(true),height:element.outerHeight(true),element:element,positions:[]};element.detach()}return info};Canvas.prototype.addText=function(layer,x,y,text,font,angle,width,halign,valign){var info=this.getTextInfo(layer,text,font,angle,width),positions=info.positions;if(halign=="center"){x-=info.width/2}else if(halign=="right"){x-=info.width}if(valign=="middle"){y-=info.height/2}else if(valign=="bottom"){y-=info.height}for(var i=0,position;position=positions[i];i++){if(position.x==x&&position.y==y){position.active=true;return}}position={active:true,rendered:false,element:positions.length?info.element.clone():info.element,x:x,y:y};positions.push(position);position.element.css({top:Math.round(y),left:Math.round(x),"text-align":halign})};Canvas.prototype.removeText=function(layer,x,y,text,font,angle){if(text==null){var layerCache=this._textCache[layer];if(layerCache!=null){for(var styleKey in layerCache){if(hasOwnProperty.call(layerCache,styleKey)){var styleCache=layerCache[styleKey];for(var key in styleCache){if(hasOwnProperty.call(styleCache,key)){var positions=styleCache[key].positions;for(var i=0,position;position=positions[i];i++){position.active=false}}}}}}}else{var positions=this.getTextInfo(layer,text,font,angle).positions;for(var i=0,position;position=positions[i];i++){if(position.x==x&&position.y==y){position.active=false}}}};function Plot(placeholder,data_,options_,plugins){var series=[],options={colors:["#edc240","#afd8f8","#cb4b4b","#4da74d","#9440ed"],legend:{show:true,noColumns:1,labelFormatter:null,labelBoxBorderColor:"#ccc",container:null,position:"ne",margin:5,backgroundColor:null,backgroundOpacity:.85,sorted:null},xaxis:{show:null,position:"bottom",mode:null,font:null,color:null,tickColor:null,transform:null,inverseTransform:null,min:null,max:null,autoscaleMargin:null,ticks:null,tickFormatter:null,labelWidth:null,labelHeight:null,reserveSpace:null,tickLength:null,alignTicksWithAxis:null,tickDecimals:null,tickSize:null,minTickSize:null},yaxis:{autoscaleMargin:.02,position:"left"},xaxes:[],yaxes:[],series:{points:{show:false,radius:3,lineWidth:2,fill:true,fillColor:"#ffffff",symbol:"circle"},lines:{lineWidth:2,fill:false,fillColor:null,steps:false},bars:{show:false,lineWidth:2,barWidth:1,fill:true,fillColor:null,align:"left",horizontal:false,zero:true},shadowSize:3,highlightColor:null},grid:{show:true,aboveData:false,color:"#545454",backgroundColor:null,borderColor:null,tickColor:null,margin:0,labelMargin:5,axisMargin:8,borderWidth:2,minBorderMargin:null,markings:null,markingsColor:"#f4f4f4",markingsLineWidth:2,clickable:false,hoverable:false,autoHighlight:true,mouseActiveRadius:10},interaction:{redrawOverlayInterval:1e3/60},hooks:{}},surface=null,overlay=null,eventHolder=null,ctx=null,octx=null,xaxes=[],yaxes=[],plotOffset={left:0,right:0,top:0,bottom:0},plotWidth=0,plotHeight=0,hooks={processOptions:[],processRawData:[],processDatapoints:[],processOffset:[],drawBackground:[],drawSeries:[],draw:[],bindEvents:[],drawOverlay:[],shutdown:[]},plot=this;plot.setData=setData;plot.setupGrid=setupGrid;plot.draw=draw;plot.getPlaceholder=function(){return placeholder};plot.getCanvas=function(){return surface.element};plot.getPlotOffset=function(){return plotOffset};plot.width=function(){return plotWidth};plot.height=function(){return plotHeight};plot.offset=function(){var o=eventHolder.offset();o.left+=plotOffset.left;o.top+=plotOffset.top;return o};plot.getData=function(){return series};plot.getAxes=function(){var res={},i;$.each(xaxes.concat(yaxes),function(_,axis){if(axis)res[axis.direction+(axis.n!=1?axis.n:"")+"axis"]=axis});return res};plot.getXAxes=function(){return xaxes};plot.getYAxes=function(){return yaxes};plot.c2p=canvasToAxisCoords;plot.p2c=axisToCanvasCoords;plot.getOptions=function(){return options};plot.highlight=highlight;plot.unhighlight=unhighlight;plot.triggerRedrawOverlay=triggerRedrawOverlay;plot.pointOffset=function(point){return{left:parseInt(xaxes[axisNumber(point,"x")-1].p2c(+point.x)+plotOffset.left,10),top:parseInt(yaxes[axisNumber(point,"y")-1].p2c(+point.y)+plotOffset.top,10)}};plot.shutdown=shutdown;plot.destroy=function(){shutdown();placeholder.removeData("plot").empty();series=[];options=null;surface=null;overlay=null;eventHolder=null;ctx=null;octx=null;xaxes=[];yaxes=[];hooks=null;highlights=[];plot=null};plot.resize=function(){var width=placeholder.width(),height=placeholder.height();surface.resize(width,height);overlay.resize(width,height)};plot.hooks=hooks;initPlugins(plot);parseOptions(options_);setupCanvases();setData(data_);setupGrid();draw();bindEvents();function executeHooks(hook,args){args=[plot].concat(args);for(var i=0;i<hook.length;++i)hook[i].apply(this,args)}function initPlugins(){var classes={Canvas:Canvas};for(var i=0;i<plugins.length;++i){var p=plugins[i];p.init(plot,classes);if(p.options)$.extend(true,options,p.options)}}function parseOptions(opts){$.extend(true,options,opts);if(opts&&opts.colors){options.colors=opts.colors}if(options.xaxis.color==null)options.xaxis.color=$.color.parse(options.grid.color).scale("a",.22).toString();if(options.yaxis.color==null)options.yaxis.color=$.color.parse(options.grid.color).scale("a",.22).toString();if(options.xaxis.tickColor==null)options.xaxis.tickColor=options.grid.tickColor||options.xaxis.color;if(options.yaxis.tickColor==null)options.yaxis.tickColor=options.grid.tickColor||options.yaxis.color;if(options.grid.borderColor==null)options.grid.borderColor=options.grid.color;if(options.grid.tickColor==null)options.grid.tickColor=$.color.parse(options.grid.color).scale("a",.22).toString();var i,axisOptions,axisCount,fontSize=placeholder.css("font-size"),fontSizeDefault=fontSize?+fontSize.replace("px",""):13,fontDefaults={style:placeholder.css("font-style"),size:Math.round(.8*fontSizeDefault),variant:placeholder.css("font-variant"),weight:placeholder.css("font-weight"),family:placeholder.css("font-family")};axisCount=options.xaxes.length||1;for(i=0;i<axisCount;++i){axisOptions=options.xaxes[i];if(axisOptions&&!axisOptions.tickColor){axisOptions.tickColor=axisOptions.color}axisOptions=$.extend(true,{},options.xaxis,axisOptions);options.xaxes[i]=axisOptions;if(axisOptions.font){axisOptions.font=$.extend({},fontDefaults,axisOptions.font);if(!axisOptions.font.color){axisOptions.font.color=axisOptions.color}if(!axisOptions.font.lineHeight){axisOptions.font.lineHeight=Math.round(axisOptions.font.size*1.15)}}}axisCount=options.yaxes.length||1;for(i=0;i<axisCount;++i){axisOptions=options.yaxes[i];if(axisOptions&&!axisOptions.tickColor){axisOptions.tickColor=axisOptions.color}axisOptions=$.extend(true,{},options.yaxis,axisOptions);options.yaxes[i]=axisOptions;if(axisOptions.font){axisOptions.font=$.extend({},fontDefaults,axisOptions.font);if(!axisOptions.font.color){axisOptions.font.color=axisOptions.color}if(!axisOptions.font.lineHeight){axisOptions.font.lineHeight=Math.round(axisOptions.font.size*1.15)}}}if(options.xaxis.noTicks&&options.xaxis.ticks==null)options.xaxis.ticks=options.xaxis.noTicks;if(options.yaxis.noTicks&&options.yaxis.ticks==null)options.yaxis.ticks=options.yaxis.noTicks;if(options.x2axis){options.xaxes[1]=$.extend(true,{},options.xaxis,options.x2axis);options.xaxes[1].position="top";if(options.x2axis.min==null){options.xaxes[1].min=null}if(options.x2axis.max==null){options.xaxes[1].max=null}}if(options.y2axis){options.yaxes[1]=$.extend(true,{},options.yaxis,options.y2axis);options.yaxes[1].position="right";if(options.y2axis.min==null){options.yaxes[1].min=null}if(options.y2axis.max==null){options.yaxes[1].max=null}}if(options.grid.coloredAreas)options.grid.markings=options.grid.coloredAreas;if(options.grid.coloredAreasColor)options.grid.markingsColor=options.grid.coloredAreasColor;if(options.lines)$.extend(true,options.series.lines,options.lines);if(options.points)$.extend(true,options.series.points,options.points);if(options.bars)$.extend(true,options.series.bars,options.bars);if(options.shadowSize!=null)options.series.shadowSize=options.shadowSize;if(options.highlightColor!=null)options.series.highlightColor=options.highlightColor;for(i=0;i<options.xaxes.length;++i)getOrCreateAxis(xaxes,i+1).options=options.xaxes[i];for(i=0;i<options.yaxes.length;++i)getOrCreateAxis(yaxes,i+1).options=options.yaxes[i];for(var n in hooks)if(options.hooks[n]&&options.hooks[n].length)hooks[n]=hooks[n].concat(options.hooks[n]);executeHooks(hooks.processOptions,[options])}function setData(d){series=parseData(d);fillInSeriesOptions();processData()}function parseData(d){var res=[];for(var i=0;i<d.length;++i){var s=$.extend(true,{},options.series);if(d[i].data!=null){s.data=d[i].data;delete d[i].data;$.extend(true,s,d[i]);d[i].data=s.data}else s.data=d[i];res.push(s)}return res}function axisNumber(obj,coord){var a=obj[coord+"axis"];if(typeof a=="object")a=a.n;if(typeof a!="number")a=1;return a}function allAxes(){return $.grep(xaxes.concat(yaxes),function(a){return a})}function canvasToAxisCoords(pos){var res={},i,axis;for(i=0;i<xaxes.length;++i){axis=xaxes[i];if(axis&&axis.used)res["x"+axis.n]=axis.c2p(pos.left)}for(i=0;i<yaxes.length;++i){axis=yaxes[i];if(axis&&axis.used)res["y"+axis.n]=axis.c2p(pos.top)}if(res.x1!==undefined)res.x=res.x1;if(res.y1!==undefined)res.y=res.y1;return res}function axisToCanvasCoords(pos){var res={},i,axis,key;for(i=0;i<xaxes.length;++i){axis=xaxes[i];if(axis&&axis.used){key="x"+axis.n;if(pos[key]==null&&axis.n==1)key="x";if(pos[key]!=null){res.left=axis.p2c(pos[key]);break}}}for(i=0;i<yaxes.length;++i){axis=yaxes[i];if(axis&&axis.used){key="y"+axis.n;if(pos[key]==null&&axis.n==1)key="y";if(pos[key]!=null){res.top=axis.p2c(pos[key]);break}}}return res}function getOrCreateAxis(axes,number){if(!axes[number-1])axes[number-1]={n:number,direction:axes==xaxes?"x":"y",options:$.extend(true,{},axes==xaxes?options.xaxis:options.yaxis)};return axes[number-1]}function fillInSeriesOptions(){var neededColors=series.length,maxIndex=-1,i;for(i=0;i<series.length;++i){var sc=series[i].color;if(sc!=null){neededColors--;if(typeof sc=="number"&&sc>maxIndex){maxIndex=sc}}}if(neededColors<=maxIndex){neededColors=maxIndex+1}var c,colors=[],colorPool=options.colors,colorPoolSize=colorPool.length,variation=0;for(i=0;i<neededColors;i++){c=$.color.parse(colorPool[i%colorPoolSize]||"#666");if(i%colorPoolSize==0&&i){if(variation>=0){if(variation<.5){variation=-variation-.2}else variation=0}else variation=-variation}colors[i]=c.scale("rgb",1+variation)}var colori=0,s;for(i=0;i<series.length;++i){s=series[i];if(s.color==null){s.color=colors[colori].toString();++colori}else if(typeof s.color=="number")s.color=colors[s.color].toString();if(s.lines.show==null){var v,show=true;for(v in s)if(s[v]&&s[v].show){show=false;break}if(show)s.lines.show=true}if(s.lines.zero==null){s.lines.zero=!!s.lines.fill}s.xaxis=getOrCreateAxis(xaxes,axisNumber(s,"x"));s.yaxis=getOrCreateAxis(yaxes,axisNumber(s,"y"))}}function processData(){var topSentry=Number.POSITIVE_INFINITY,bottomSentry=Number.NEGATIVE_INFINITY,fakeInfinity=Number.MAX_VALUE,i,j,k,m,length,s,points,ps,x,y,axis,val,f,p,data,format;function updateAxis(axis,min,max){if(min<axis.datamin&&min!=-fakeInfinity)axis.datamin=min;if(max>axis.datamax&&max!=fakeInfinity)axis.datamax=max}$.each(allAxes(),function(_,axis){axis.datamin=topSentry;axis.datamax=bottomSentry;axis.used=false});for(i=0;i<series.length;++i){s=series[i];s.datapoints={points:[]};executeHooks(hooks.processRawData,[s,s.data,s.datapoints])}for(i=0;i<series.length;++i){s=series[i];data=s.data;format=s.datapoints.format;if(!format){format=[];format.push({x:true,number:true,required:true});format.push({y:true,number:true,required:true});if(s.bars.show||s.lines.show&&s.lines.fill){var autoscale=!!(s.bars.show&&s.bars.zero||s.lines.show&&s.lines.zero);format.push({y:true,number:true,required:false,defaultValue:0,autoscale:autoscale});if(s.bars.horizontal){delete format[format.length-1].y;format[format.length-1].x=true}}s.datapoints.format=format}if(s.datapoints.pointsize!=null)continue;s.datapoints.pointsize=format.length;ps=s.datapoints.pointsize;points=s.datapoints.points;var insertSteps=s.lines.show&&s.lines.steps;s.xaxis.used=s.yaxis.used=true;for(j=k=0;j<data.length;++j,k+=ps){p=data[j];var nullify=p==null;if(!nullify){for(m=0;m<ps;++m){val=p[m];f=format[m];if(f){if(f.number&&val!=null){val=+val;if(isNaN(val))val=null;else if(val==Infinity)val=fakeInfinity;else if(val==-Infinity)val=-fakeInfinity}if(val==null){if(f.required)nullify=true;if(f.defaultValue!=null)val=f.defaultValue}}points[k+m]=val}}if(nullify){for(m=0;m<ps;++m){val=points[k+m];if(val!=null){f=format[m];if(f.autoscale!==false){if(f.x){updateAxis(s.xaxis,val,val)}if(f.y){updateAxis(s.yaxis,val,val)}}}points[k+m]=null}}else{if(insertSteps&&k>0&&points[k-ps]!=null&&points[k-ps]!=points[k]&&points[k-ps+1]!=points[k+1]){for(m=0;m<ps;++m)points[k+ps+m]=points[k+m];points[k+1]=points[k-ps+1];k+=ps}}}}for(i=0;i<series.length;++i){s=series[i];executeHooks(hooks.processDatapoints,[s,s.datapoints])}for(i=0;i<series.length;++i){s=series[i];points=s.datapoints.points;ps=s.datapoints.pointsize;format=s.datapoints.format;var xmin=topSentry,ymin=topSentry,xmax=bottomSentry,ymax=bottomSentry;for(j=0;j<points.length;j+=ps){if(points[j]==null)continue;for(m=0;m<ps;++m){val=points[j+m];f=format[m];if(!f||f.autoscale===false||val==fakeInfinity||val==-fakeInfinity)continue;if(f.x){if(val<xmin)xmin=val;if(val>xmax)xmax=val}if(f.y){if(val<ymin)ymin=val;if(val>ymax)ymax=val}}}if(s.bars.show){var delta;switch(s.bars.align){case"left":delta=0;break;case"right":delta=-s.bars.barWidth;break;default:delta=-s.bars.barWidth/2}if(s.bars.horizontal){ymin+=delta;ymax+=delta+s.bars.barWidth}else{xmin+=delta;xmax+=delta+s.bars.barWidth}}updateAxis(s.xaxis,xmin,xmax);updateAxis(s.yaxis,ymin,ymax)}$.each(allAxes(),function(_,axis){if(axis.datamin==topSentry)axis.datamin=null;if(axis.datamax==bottomSentry)axis.datamax=null})}function setupCanvases(){placeholder.css("padding",0).children().filter(function(){return!$(this).hasClass("flot-overlay")&&!$(this).hasClass("flot-base")}).remove();if(placeholder.css("position")=="static")placeholder.css("position","relative");surface=new Canvas("flot-base",placeholder);overlay=new Canvas("flot-overlay",placeholder);ctx=surface.context;octx=overlay.context;eventHolder=$(overlay.element).unbind();var existing=placeholder.data("plot");if(existing){existing.shutdown();overlay.clear()}placeholder.data("plot",plot)}function bindEvents(){if(options.grid.hoverable){eventHolder.mousemove(onMouseMove);eventHolder.bind("mouseleave",onMouseLeave)}if(options.grid.clickable)eventHolder.click(onClick);executeHooks(hooks.bindEvents,[eventHolder])}function shutdown(){if(redrawTimeout)clearTimeout(redrawTimeout);eventHolder.unbind("mousemove",onMouseMove);eventHolder.unbind("mouseleave",onMouseLeave);eventHolder.unbind("click",onClick);executeHooks(hooks.shutdown,[eventHolder])}function setTransformationHelpers(axis){function identity(x){return x}var s,m,t=axis.options.transform||identity,it=axis.options.inverseTransform;if(axis.direction=="x"){s=axis.scale=plotWidth/Math.abs(t(axis.max)-t(axis.min));m=Math.min(t(axis.max),t(axis.min))}else{s=axis.scale=plotHeight/Math.abs(t(axis.max)-t(axis.min));s=-s;m=Math.max(t(axis.max),t(axis.min))}if(t==identity)axis.p2c=function(p){return(p-m)*s};else axis.p2c=function(p){return(t(p)-m)*s};if(!it)axis.c2p=function(c){return m+c/s};else axis.c2p=function(c){return it(m+c/s)}}function measureTickLabels(axis){var opts=axis.options,ticks=axis.ticks||[],labelWidth=opts.labelWidth||0,labelHeight=opts.labelHeight||0,maxWidth=labelWidth||(axis.direction=="x"?Math.floor(surface.width/(ticks.length||1)):null),legacyStyles=axis.direction+"Axis "+axis.direction+axis.n+"Axis",layer="flot-"+axis.direction+"-axis flot-"+axis.direction+axis.n+"-axis "+legacyStyles,font=opts.font||"flot-tick-label tickLabel";for(var i=0;i<ticks.length;++i){var t=ticks[i];if(!t.label)continue;var info=surface.getTextInfo(layer,t.label,font,null,maxWidth);labelWidth=Math.max(labelWidth,info.width);labelHeight=Math.max(labelHeight,info.height)}axis.labelWidth=opts.labelWidth||labelWidth;axis.labelHeight=opts.labelHeight||labelHeight}function allocateAxisBoxFirstPhase(axis){var lw=axis.labelWidth,lh=axis.labelHeight,pos=axis.options.position,isXAxis=axis.direction==="x",tickLength=axis.options.tickLength,axisMargin=options.grid.axisMargin,padding=options.grid.labelMargin,innermost=true,outermost=true,first=true,found=false;$.each(isXAxis?xaxes:yaxes,function(i,a){if(a&&(a.show||a.reserveSpace)){if(a===axis){found=true}else if(a.options.position===pos){if(found){outermost=false}else{innermost=false}}if(!found){first=false}}});if(outermost){axisMargin=0}if(tickLength==null){tickLength=first?"full":5}if(!isNaN(+tickLength))padding+=+tickLength;if(isXAxis){lh+=padding;if(pos=="bottom"){plotOffset.bottom+=lh+axisMargin;axis.box={top:surface.height-plotOffset.bottom,height:lh}}else{axis.box={top:plotOffset.top+axisMargin,height:lh};plotOffset.top+=lh+axisMargin}}else{lw+=padding;if(pos=="left"){axis.box={left:plotOffset.left+axisMargin,width:lw};plotOffset.left+=lw+axisMargin}else{plotOffset.right+=lw+axisMargin;axis.box={left:surface.width-plotOffset.right,width:lw}}}axis.position=pos;axis.tickLength=tickLength;axis.box.padding=padding;axis.innermost=innermost}function allocateAxisBoxSecondPhase(axis){if(axis.direction=="x"){axis.box.left=plotOffset.left-axis.labelWidth/2;axis.box.width=surface.width-plotOffset.left-plotOffset.right+axis.labelWidth}else{axis.box.top=plotOffset.top-axis.labelHeight/2;axis.box.height=surface.height-plotOffset.bottom-plotOffset.top+axis.labelHeight}}function adjustLayoutForThingsStickingOut(){var minMargin=options.grid.minBorderMargin,axis,i;if(minMargin==null){minMargin=0;for(i=0;i<series.length;++i)minMargin=Math.max(minMargin,2*(series[i].points.radius+series[i].points.lineWidth/2))}var margins={left:minMargin,right:minMargin,top:minMargin,bottom:minMargin};$.each(allAxes(),function(_,axis){if(axis.reserveSpace&&axis.ticks&&axis.ticks.length){if(axis.direction==="x"){margins.left=Math.max(margins.left,axis.labelWidth/2);margins.right=Math.max(margins.right,axis.labelWidth/2)}else{margins.bottom=Math.max(margins.bottom,axis.labelHeight/2);margins.top=Math.max(margins.top,axis.labelHeight/2)}}});plotOffset.left=Math.ceil(Math.max(margins.left,plotOffset.left));plotOffset.right=Math.ceil(Math.max(margins.right,plotOffset.right));plotOffset.top=Math.ceil(Math.max(margins.top,plotOffset.top));plotOffset.bottom=Math.ceil(Math.max(margins.bottom,plotOffset.bottom))}function setupGrid(){var i,axes=allAxes(),showGrid=options.grid.show;for(var a in plotOffset){var margin=options.grid.margin||0;plotOffset[a]=typeof margin=="number"?margin:margin[a]||0}executeHooks(hooks.processOffset,[plotOffset]);for(var a in plotOffset){if(typeof options.grid.borderWidth=="object"){plotOffset[a]+=showGrid?options.grid.borderWidth[a]:0}else{plotOffset[a]+=showGrid?options.grid.borderWidth:0}}$.each(axes,function(_,axis){var axisOpts=axis.options;axis.show=axisOpts.show==null?axis.used:axisOpts.show;axis.reserveSpace=axisOpts.reserveSpace==null?axis.show:axisOpts.reserveSpace;setRange(axis)});if(showGrid){var allocatedAxes=$.grep(axes,function(axis){return axis.show||axis.reserveSpace});$.each(allocatedAxes,function(_,axis){setupTickGeneration(axis);setTicks(axis);snapRangeToTicks(axis,axis.ticks);measureTickLabels(axis)});for(i=allocatedAxes.length-1;i>=0;--i)allocateAxisBoxFirstPhase(allocatedAxes[i]);adjustLayoutForThingsStickingOut();$.each(allocatedAxes,function(_,axis){allocateAxisBoxSecondPhase(axis)})}plotWidth=surface.width-plotOffset.left-plotOffset.right;plotHeight=surface.height-plotOffset.bottom-plotOffset.top;$.each(axes,function(_,axis){setTransformationHelpers(axis)});if(showGrid){drawAxisLabels()}insertLegend()}function setRange(axis){var opts=axis.options,min=+(opts.min!=null?opts.min:axis.datamin),max=+(opts.max!=null?opts.max:axis.datamax),delta=max-min;if(delta==0){var widen=max==0?1:.01;if(opts.min==null)min-=widen;if(opts.max==null||opts.min!=null)max+=widen}else{var margin=opts.autoscaleMargin;if(margin!=null){if(opts.min==null){min-=delta*margin;if(min<0&&axis.datamin!=null&&axis.datamin>=0)min=0}if(opts.max==null){max+=delta*margin;if(max>0&&axis.datamax!=null&&axis.datamax<=0)max=0}}}axis.min=min;axis.max=max}function setupTickGeneration(axis){var opts=axis.options;var noTicks;if(typeof opts.ticks=="number"&&opts.ticks>0)noTicks=opts.ticks;else noTicks=.3*Math.sqrt(axis.direction=="x"?surface.width:surface.height);var delta=(axis.max-axis.min)/noTicks,dec=-Math.floor(Math.log(delta)/Math.LN10),maxDec=opts.tickDecimals;if(maxDec!=null&&dec>maxDec){dec=maxDec}var magn=Math.pow(10,-dec),norm=delta/magn,size;if(norm<1.5){size=1}else if(norm<3){size=2;if(norm>2.25&&(maxDec==null||dec+1<=maxDec)){size=2.5;++dec}}else if(norm<7.5){size=5}else{size=10}size*=magn;if(opts.minTickSize!=null&&size<opts.minTickSize){size=opts.minTickSize}axis.delta=delta;axis.tickDecimals=Math.max(0,maxDec!=null?maxDec:dec);axis.tickSize=opts.tickSize||size;if(opts.mode=="time"&&!axis.tickGenerator){throw new Error("Time mode requires the flot.time plugin.")}if(!axis.tickGenerator){axis.tickGenerator=function(axis){var ticks=[],start=floorInBase(axis.min,axis.tickSize),i=0,v=Number.NaN,prev;do{prev=v;v=start+i*axis.tickSize;ticks.push(v);++i}while(v<axis.max&&v!=prev);return ticks};axis.tickFormatter=function(value,axis){var factor=axis.tickDecimals?Math.pow(10,axis.tickDecimals):1;var formatted=""+Math.round(value*factor)/factor;if(axis.tickDecimals!=null){var decimal=formatted.indexOf(".");var precision=decimal==-1?0:formatted.length-decimal-1;if(precision<axis.tickDecimals){return(precision?formatted:formatted+".")+(""+factor).substr(1,axis.tickDecimals-precision)}}return formatted}}if($.isFunction(opts.tickFormatter))axis.tickFormatter=function(v,axis){return""+opts.tickFormatter(v,axis)};if(opts.alignTicksWithAxis!=null){var otherAxis=(axis.direction=="x"?xaxes:yaxes)[opts.alignTicksWithAxis-1];if(otherAxis&&otherAxis.used&&otherAxis!=axis){var niceTicks=axis.tickGenerator(axis);if(niceTicks.length>0){if(opts.min==null)axis.min=Math.min(axis.min,niceTicks[0]);if(opts.max==null&&niceTicks.length>1)axis.max=Math.max(axis.max,niceTicks[niceTicks.length-1])}axis.tickGenerator=function(axis){var ticks=[],v,i;for(i=0;i<otherAxis.ticks.length;++i){v=(otherAxis.ticks[i].v-otherAxis.min)/(otherAxis.max-otherAxis.min);v=axis.min+v*(axis.max-axis.min);ticks.push(v)}return ticks};if(!axis.mode&&opts.tickDecimals==null){var extraDec=Math.max(0,-Math.floor(Math.log(axis.delta)/Math.LN10)+1),ts=axis.tickGenerator(axis);if(!(ts.length>1&&/\..*0$/.test((ts[1]-ts[0]).toFixed(extraDec))))axis.tickDecimals=extraDec}}}}function setTicks(axis){var oticks=axis.options.ticks,ticks=[];if(oticks==null||typeof oticks=="number"&&oticks>0)ticks=axis.tickGenerator(axis);else if(oticks){if($.isFunction(oticks))ticks=oticks(axis);else ticks=oticks}var i,v;axis.ticks=[];for(i=0;i<ticks.length;++i){var label=null;var t=ticks[i];if(typeof t=="object"){v=+t[0];if(t.length>1)label=t[1]}else v=+t;if(label==null)label=axis.tickFormatter(v,axis);if(!isNaN(v))axis.ticks.push({v:v,label:label})}}function snapRangeToTicks(axis,ticks){if(axis.options.autoscaleMargin&&ticks.length>0){if(axis.options.min==null)axis.min=Math.min(axis.min,ticks[0].v);if(axis.options.max==null&&ticks.length>1)axis.max=Math.max(axis.max,ticks[ticks.length-1].v)}}function draw(){surface.clear();executeHooks(hooks.drawBackground,[ctx]);var grid=options.grid;if(grid.show&&grid.backgroundColor)drawBackground();if(grid.show&&!grid.aboveData){drawGrid()}for(var i=0;i<series.length;++i){executeHooks(hooks.drawSeries,[ctx,series[i]]);drawSeries(series[i])}executeHooks(hooks.draw,[ctx]);if(grid.show&&grid.aboveData){drawGrid()}surface.render();triggerRedrawOverlay()}function extractRange(ranges,coord){var axis,from,to,key,axes=allAxes();for(var i=0;i<axes.length;++i){axis=axes[i];if(axis.direction==coord){key=coord+axis.n+"axis";if(!ranges[key]&&axis.n==1)key=coord+"axis";if(ranges[key]){from=ranges[key].from;to=ranges[key].to;break}}}if(!ranges[key]){axis=coord=="x"?xaxes[0]:yaxes[0];from=ranges[coord+"1"];to=ranges[coord+"2"]}if(from!=null&&to!=null&&from>to){var tmp=from;from=to;to=tmp}return{from:from,to:to,axis:axis}}function drawBackground(){ctx.save();ctx.translate(plotOffset.left,plotOffset.top);ctx.fillStyle=getColorOrGradient(options.grid.backgroundColor,plotHeight,0,"rgba(255, 255, 255, 0)");ctx.fillRect(0,0,plotWidth,plotHeight);ctx.restore()}function drawGrid(){var i,axes,bw,bc;ctx.save();ctx.translate(plotOffset.left,plotOffset.top);var markings=options.grid.markings;if(markings){if($.isFunction(markings)){axes=plot.getAxes();axes.xmin=axes.xaxis.min;axes.xmax=axes.xaxis.max;axes.ymin=axes.yaxis.min;axes.ymax=axes.yaxis.max;markings=markings(axes)}for(i=0;i<markings.length;++i){var m=markings[i],xrange=extractRange(m,"x"),yrange=extractRange(m,"y");if(xrange.from==null)xrange.from=xrange.axis.min;if(xrange.to==null)xrange.to=xrange.axis.max;+if(yrange.from==null)yrange.from=yrange.axis.min;if(yrange.to==null)yrange.to=yrange.axis.max;if(xrange.to<xrange.axis.min||xrange.from>xrange.axis.max||yrange.to<yrange.axis.min||yrange.from>yrange.axis.max)continue;xrange.from=Math.max(xrange.from,xrange.axis.min);xrange.to=Math.min(xrange.to,xrange.axis.max);yrange.from=Math.max(yrange.from,yrange.axis.min);yrange.to=Math.min(yrange.to,yrange.axis.max);var xequal=xrange.from===xrange.to,yequal=yrange.from===yrange.to;if(xequal&&yequal){continue}xrange.from=Math.floor(xrange.axis.p2c(xrange.from));xrange.to=Math.floor(xrange.axis.p2c(xrange.to));yrange.from=Math.floor(yrange.axis.p2c(yrange.from));yrange.to=Math.floor(yrange.axis.p2c(yrange.to));if(xequal||yequal){var lineWidth=m.lineWidth||options.grid.markingsLineWidth,subPixel=lineWidth%2?.5:0;ctx.beginPath();ctx.strokeStyle=m.color||options.grid.markingsColor;ctx.lineWidth=lineWidth;if(xequal){ctx.moveTo(xrange.to+subPixel,yrange.from);ctx.lineTo(xrange.to+subPixel,yrange.to)}else{ctx.moveTo(xrange.from,yrange.to+subPixel);ctx.lineTo(xrange.to,yrange.to+subPixel)}ctx.stroke()}else{ctx.fillStyle=m.color||options.grid.markingsColor;ctx.fillRect(xrange.from,yrange.to,xrange.to-xrange.from,yrange.from-yrange.to)}}}axes=allAxes();bw=options.grid.borderWidth;for(var j=0;j<axes.length;++j){var axis=axes[j],box=axis.box,t=axis.tickLength,x,y,xoff,yoff;if(!axis.show||axis.ticks.length==0)continue;ctx.lineWidth=1;if(axis.direction=="x"){x=0;if(t=="full")y=axis.position=="top"?0:plotHeight;else y=box.top-plotOffset.top+(axis.position=="top"?box.height:0)}else{y=0;if(t=="full")x=axis.position=="left"?0:plotWidth;else x=box.left-plotOffset.left+(axis.position=="left"?box.width:0)}if(!axis.innermost){ctx.strokeStyle=axis.options.color;ctx.beginPath();xoff=yoff=0;if(axis.direction=="x")xoff=plotWidth+1;else yoff=plotHeight+1;if(ctx.lineWidth==1){if(axis.direction=="x"){y=Math.floor(y)+.5}else{x=Math.floor(x)+.5}}ctx.moveTo(x,y);ctx.lineTo(x+xoff,y+yoff);ctx.stroke()}ctx.strokeStyle=axis.options.tickColor;ctx.beginPath();for(i=0;i<axis.ticks.length;++i){var v=axis.ticks[i].v;xoff=yoff=0;if(isNaN(v)||v<axis.min||v>axis.max||t=="full"&&(typeof bw=="object"&&bw[axis.position]>0||bw>0)&&(v==axis.min||v==axis.max))continue;if(axis.direction=="x"){x=axis.p2c(v);yoff=t=="full"?-plotHeight:t;if(axis.position=="top")yoff=-yoff}else{y=axis.p2c(v);xoff=t=="full"?-plotWidth:t;if(axis.position=="left")xoff=-xoff}if(ctx.lineWidth==1){if(axis.direction=="x")x=Math.floor(x)+.5;else y=Math.floor(y)+.5}ctx.moveTo(x,y);ctx.lineTo(x+xoff,y+yoff)}ctx.stroke()}if(bw){bc=options.grid.borderColor;if(typeof bw=="object"||typeof bc=="object"){if(typeof bw!=="object"){bw={top:bw,right:bw,bottom:bw,left:bw}}if(typeof bc!=="object"){bc={top:bc,right:bc,bottom:bc,left:bc}}if(bw.top>0){ctx.strokeStyle=bc.top;ctx.lineWidth=bw.top;ctx.beginPath();ctx.moveTo(0-bw.left,0-bw.top/2);ctx.lineTo(plotWidth,0-bw.top/2);ctx.stroke()}if(bw.right>0){ctx.strokeStyle=bc.right;ctx.lineWidth=bw.right;ctx.beginPath();ctx.moveTo(plotWidth+bw.right/2,0-bw.top);ctx.lineTo(plotWidth+bw.right/2,plotHeight);ctx.stroke()}if(bw.bottom>0){ctx.strokeStyle=bc.bottom;ctx.lineWidth=bw.bottom;ctx.beginPath();ctx.moveTo(plotWidth+bw.right,plotHeight+bw.bottom/2);ctx.lineTo(0,plotHeight+bw.bottom/2);ctx.stroke()}if(bw.left>0){ctx.strokeStyle=bc.left;ctx.lineWidth=bw.left;ctx.beginPath();ctx.moveTo(0-bw.left/2,plotHeight+bw.bottom);ctx.lineTo(0-bw.left/2,0);ctx.stroke()}}else{ctx.lineWidth=bw;ctx.strokeStyle=options.grid.borderColor;ctx.strokeRect(-bw/2,-bw/2,plotWidth+bw,plotHeight+bw)}}ctx.restore()}function drawAxisLabels(){$.each(allAxes(),function(_,axis){var box=axis.box,legacyStyles=axis.direction+"Axis "+axis.direction+axis.n+"Axis",layer="flot-"+axis.direction+"-axis flot-"+axis.direction+axis.n+"-axis "+legacyStyles,font=axis.options.font||"flot-tick-label tickLabel",tick,x,y,halign,valign;surface.removeText(layer);if(!axis.show||axis.ticks.length==0)return;for(var i=0;i<axis.ticks.length;++i){tick=axis.ticks[i];if(!tick.label||tick.v<axis.min||tick.v>axis.max)continue;if(axis.direction=="x"){halign="center";x=plotOffset.left+axis.p2c(tick.v);if(axis.position=="bottom"){y=box.top+box.padding}else{y=box.top+box.height-box.padding;valign="bottom"}}else{valign="middle";y=plotOffset.top+axis.p2c(tick.v);if(axis.position=="left"){x=box.left+box.width-box.padding;halign="right"}else{x=box.left+box.padding}}surface.addText(layer,x,y,tick.label,font,null,null,halign,valign)}})}function drawSeries(series){if(series.lines.show)drawSeriesLines(series);if(series.bars.show)drawSeriesBars(series);if(series.points.show)drawSeriesPoints(series)}function drawSeriesLines(series){function plotLine(datapoints,xoffset,yoffset,axisx,axisy){var points=datapoints.points,ps=datapoints.pointsize,prevx=null,prevy=null;ctx.beginPath();for(var i=ps;i<points.length;i+=ps){var x1=points[i-ps],y1=points[i-ps+1],x2=points[i],y2=points[i+1];if(x1==null||x2==null)continue;if(y1<=y2&&y1<axisy.min){if(y2<axisy.min)continue;x1=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.min}else if(y2<=y1&&y2<axisy.min){if(y1<axisy.min)continue;x2=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.min}if(y1>=y2&&y1>axisy.max){if(y2>axisy.max)continue;x1=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.max}else if(y2>=y1&&y2>axisy.max){if(y1>axisy.max)continue;x2=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.max}if(x1<=x2&&x1<axisx.min){if(x2<axisx.min)continue;y1=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.min}else if(x2<=x1&&x2<axisx.min){if(x1<axisx.min)continue;y2=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.min}if(x1>=x2&&x1>axisx.max){if(x2>axisx.max)continue;y1=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.max}else if(x2>=x1&&x2>axisx.max){if(x1>axisx.max)continue;y2=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.max}if(x1!=prevx||y1!=prevy)ctx.moveTo(axisx.p2c(x1)+xoffset,axisy.p2c(y1)+yoffset);prevx=x2;prevy=y2;ctx.lineTo(axisx.p2c(x2)+xoffset,axisy.p2c(y2)+yoffset)}ctx.stroke()}function plotLineArea(datapoints,axisx,axisy){var points=datapoints.points,ps=datapoints.pointsize,bottom=Math.min(Math.max(0,axisy.min),axisy.max),i=0,top,areaOpen=false,ypos=1,segmentStart=0,segmentEnd=0;while(true){if(ps>0&&i>points.length+ps)break;i+=ps;var x1=points[i-ps],y1=points[i-ps+ypos],x2=points[i],y2=points[i+ypos];if(areaOpen){if(ps>0&&x1!=null&&x2==null){segmentEnd=i;ps=-ps;ypos=2;continue}if(ps<0&&i==segmentStart+ps){ctx.fill();areaOpen=false;ps=-ps;ypos=1;i=segmentStart=segmentEnd+ps;continue}}if(x1==null||x2==null)continue;if(x1<=x2&&x1<axisx.min){if(x2<axisx.min)continue;y1=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.min}else if(x2<=x1&&x2<axisx.min){if(x1<axisx.min)continue;y2=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.min}if(x1>=x2&&x1>axisx.max){if(x2>axisx.max)continue;y1=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.max}else if(x2>=x1&&x2>axisx.max){if(x1>axisx.max)continue;y2=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.max}if(!areaOpen){ctx.beginPath();ctx.moveTo(axisx.p2c(x1),axisy.p2c(bottom));areaOpen=true}if(y1>=axisy.max&&y2>=axisy.max){ctx.lineTo(axisx.p2c(x1),axisy.p2c(axisy.max));ctx.lineTo(axisx.p2c(x2),axisy.p2c(axisy.max));continue}else if(y1<=axisy.min&&y2<=axisy.min){ctx.lineTo(axisx.p2c(x1),axisy.p2c(axisy.min));ctx.lineTo(axisx.p2c(x2),axisy.p2c(axisy.min));continue}var x1old=x1,x2old=x2;if(y1<=y2&&y1<axisy.min&&y2>=axisy.min){x1=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.min}else if(y2<=y1&&y2<axisy.min&&y1>=axisy.min){x2=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.min}if(y1>=y2&&y1>axisy.max&&y2<=axisy.max){x1=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.max}else if(y2>=y1&&y2>axisy.max&&y1<=axisy.max){x2=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.max}if(x1!=x1old){ctx.lineTo(axisx.p2c(x1old),axisy.p2c(y1))}ctx.lineTo(axisx.p2c(x1),axisy.p2c(y1));ctx.lineTo(axisx.p2c(x2),axisy.p2c(y2));if(x2!=x2old){ctx.lineTo(axisx.p2c(x2),axisy.p2c(y2));ctx.lineTo(axisx.p2c(x2old),axisy.p2c(y2))}}}ctx.save();ctx.translate(plotOffset.left,plotOffset.top);ctx.lineJoin="round";var lw=series.lines.lineWidth,sw=series.shadowSize;if(lw>0&&sw>0){ctx.lineWidth=sw;ctx.strokeStyle="rgba(0,0,0,0.1)";var angle=Math.PI/18;plotLine(series.datapoints,Math.sin(angle)*(lw/2+sw/2),Math.cos(angle)*(lw/2+sw/2),series.xaxis,series.yaxis);ctx.lineWidth=sw/2;plotLine(series.datapoints,Math.sin(angle)*(lw/2+sw/4),Math.cos(angle)*(lw/2+sw/4),series.xaxis,series.yaxis)}ctx.lineWidth=lw;ctx.strokeStyle=series.color;var fillStyle=getFillStyle(series.lines,series.color,0,plotHeight);if(fillStyle){ctx.fillStyle=fillStyle;plotLineArea(series.datapoints,series.xaxis,series.yaxis)}if(lw>0)plotLine(series.datapoints,0,0,series.xaxis,series.yaxis);ctx.restore()}function drawSeriesPoints(series){function plotPoints(datapoints,radius,fillStyle,offset,shadow,axisx,axisy,symbol){var points=datapoints.points,ps=datapoints.pointsize;for(var i=0;i<points.length;i+=ps){var x=points[i],y=points[i+1];if(x==null||x<axisx.min||x>axisx.max||y<axisy.min||y>axisy.max)continue;ctx.beginPath();x=axisx.p2c(x);y=axisy.p2c(y)+offset;if(symbol=="circle")ctx.arc(x,y,radius,0,shadow?Math.PI:Math.PI*2,false);else symbol(ctx,x,y,radius,shadow);ctx.closePath();if(fillStyle){ctx.fillStyle=fillStyle;ctx.fill()}ctx.stroke()}}ctx.save();ctx.translate(plotOffset.left,plotOffset.top);var lw=series.points.lineWidth,sw=series.shadowSize,radius=series.points.radius,symbol=series.points.symbol;if(lw==0)lw=1e-4;if(lw>0&&sw>0){var w=sw/2;ctx.lineWidth=w;ctx.strokeStyle="rgba(0,0,0,0.1)";plotPoints(series.datapoints,radius,null,w+w/2,true,series.xaxis,series.yaxis,symbol);ctx.strokeStyle="rgba(0,0,0,0.2)";plotPoints(series.datapoints,radius,null,w/2,true,series.xaxis,series.yaxis,symbol)}ctx.lineWidth=lw;ctx.strokeStyle=series.color;plotPoints(series.datapoints,radius,getFillStyle(series.points,series.color),0,false,series.xaxis,series.yaxis,symbol);ctx.restore()}function drawBar(x,y,b,barLeft,barRight,fillStyleCallback,axisx,axisy,c,horizontal,lineWidth){var left,right,bottom,top,drawLeft,drawRight,drawTop,drawBottom,tmp;if(horizontal){drawBottom=drawRight=drawTop=true;drawLeft=false;left=b;right=x;top=y+barLeft;bottom=y+barRight;if(right<left){tmp=right;right=left;left=tmp;drawLeft=true;drawRight=false}}else{drawLeft=drawRight=drawTop=true;drawBottom=false;left=x+barLeft;right=x+barRight;bottom=b;top=y;if(top<bottom){tmp=top;top=bottom;bottom=tmp;drawBottom=true;drawTop=false}}if(right<axisx.min||left>axisx.max||top<axisy.min||bottom>axisy.max)return;if(left<axisx.min){left=axisx.min;drawLeft=false}if(right>axisx.max){right=axisx.max;drawRight=false}if(bottom<axisy.min){bottom=axisy.min;drawBottom=false}if(top>axisy.max){top=axisy.max;drawTop=false}left=axisx.p2c(left);bottom=axisy.p2c(bottom);right=axisx.p2c(right);top=axisy.p2c(top);if(fillStyleCallback){c.fillStyle=fillStyleCallback(bottom,top);c.fillRect(left,top,right-left,bottom-top)}if(lineWidth>0&&(drawLeft||drawRight||drawTop||drawBottom)){c.beginPath();c.moveTo(left,bottom);if(drawLeft)c.lineTo(left,top);else c.moveTo(left,top);if(drawTop)c.lineTo(right,top);else c.moveTo(right,top);if(drawRight)c.lineTo(right,bottom);else c.moveTo(right,bottom);if(drawBottom)c.lineTo(left,bottom);else c.moveTo(left,bottom);c.stroke()}}function drawSeriesBars(series){function plotBars(datapoints,barLeft,barRight,fillStyleCallback,axisx,axisy){var points=datapoints.points,ps=datapoints.pointsize;for(var i=0;i<points.length;i+=ps){if(points[i]==null)continue;drawBar(points[i],points[i+1],points[i+2],barLeft,barRight,fillStyleCallback,axisx,axisy,ctx,series.bars.horizontal,series.bars.lineWidth)}}ctx.save();ctx.translate(plotOffset.left,plotOffset.top);ctx.lineWidth=series.bars.lineWidth;ctx.strokeStyle=series.color;var barLeft;switch(series.bars.align){case"left":barLeft=0;break;case"right":barLeft=-series.bars.barWidth;break;default:barLeft=-series.bars.barWidth/2}var fillStyleCallback=series.bars.fill?function(bottom,top){return getFillStyle(series.bars,series.color,bottom,top)}:null;plotBars(series.datapoints,barLeft,barLeft+series.bars.barWidth,fillStyleCallback,series.xaxis,series.yaxis);ctx.restore()}function getFillStyle(filloptions,seriesColor,bottom,top){var fill=filloptions.fill;if(!fill)return null;if(filloptions.fillColor)return getColorOrGradient(filloptions.fillColor,bottom,top,seriesColor);var c=$.color.parse(seriesColor);c.a=typeof fill=="number"?fill:.4;c.normalize();return c.toString()}function insertLegend(){if(options.legend.container!=null){$(options.legend.container).html("")}else{placeholder.find(".legend").remove()}if(!options.legend.show){return}var fragments=[],entries=[],rowStarted=false,lf=options.legend.labelFormatter,s,label;for(var i=0;i<series.length;++i){s=series[i];if(s.label){label=lf?lf(s.label,s):s.label;if(label){entries.push({label:label,color:s.color})}}}if(options.legend.sorted){if($.isFunction(options.legend.sorted)){entries.sort(options.legend.sorted)}else if(options.legend.sorted=="reverse"){entries.reverse()}else{var ascending=options.legend.sorted!="descending";entries.sort(function(a,b){return a.label==b.label?0:a.label<b.label!=ascending?1:-1})}}for(var i=0;i<entries.length;++i){var entry=entries[i];if(i%options.legend.noColumns==0){if(rowStarted)fragments.push("</tr>");fragments.push("<tr>");rowStarted=true}fragments.push('<td class="legendColorBox"><div style="border:1px solid '+options.legend.labelBoxBorderColor+';padding:1px"><div style="width:4px;height:0;border:5px solid '+entry.color+';overflow:hidden"></div></div></td>'+'<td class="legendLabel">'+entry.label+"</td>")}if(rowStarted)fragments.push("</tr>");if(fragments.length==0)return;var table='<table style="font-size:smaller;color:'+options.grid.color+'">'+fragments.join("")+"</table>";if(options.legend.container!=null)$(options.legend.container).html(table);else{var pos="",p=options.legend.position,m=options.legend.margin;if(m[0]==null)m=[m,m];if(p.charAt(0)=="n")pos+="top:"+(m[1]+plotOffset.top)+"px;";else if(p.charAt(0)=="s")pos+="bottom:"+(m[1]+plotOffset.bottom)+"px;";if(p.charAt(1)=="e")pos+="right:"+(m[0]+plotOffset.right)+"px;";else if(p.charAt(1)=="w")pos+="left:"+(m[0]+plotOffset.left)+"px;";var legend=$('<div class="legend">'+table.replace('style="','style="position:absolute;'+pos+";")+"</div>").appendTo(placeholder);if(options.legend.backgroundOpacity!=0){var c=options.legend.backgroundColor;if(c==null){c=options.grid.backgroundColor;if(c&&typeof c=="string")c=$.color.parse(c);else c=$.color.extract(legend,"background-color");c.a=1;c=c.toString()}var div=legend.children();$('<div style="position:absolute;width:'+div.width()+"px;height:"+div.height()+"px;"+pos+"background-color:"+c+';"> </div>').prependTo(legend).css("opacity",options.legend.backgroundOpacity)}}}var highlights=[],redrawTimeout=null;function findNearbyItem(mouseX,mouseY,seriesFilter){var maxDistance=options.grid.mouseActiveRadius,smallestDistance=maxDistance*maxDistance+1,item=null,foundPoint=false,i,j,ps;for(i=series.length-1;i>=0;--i){if(!seriesFilter(series[i]))continue;var s=series[i],axisx=s.xaxis,axisy=s.yaxis,points=s.datapoints.points,mx=axisx.c2p(mouseX),my=axisy.c2p(mouseY),maxx=maxDistance/axisx.scale,maxy=maxDistance/axisy.scale;ps=s.datapoints.pointsize;if(axisx.options.inverseTransform)maxx=Number.MAX_VALUE;if(axisy.options.inverseTransform)maxy=Number.MAX_VALUE;if(s.lines.show||s.points.show){for(j=0;j<points.length;j+=ps){var x=points[j],y=points[j+1];if(x==null)continue;if(x-mx>maxx||x-mx<-maxx||y-my>maxy||y-my<-maxy)continue;var dx=Math.abs(axisx.p2c(x)-mouseX),dy=Math.abs(axisy.p2c(y)-mouseY),dist=dx*dx+dy*dy;if(dist<smallestDistance){smallestDistance=dist;item=[i,j/ps]}}}if(s.bars.show&&!item){var barLeft,barRight;switch(s.bars.align){case"left":barLeft=0;break;case"right":barLeft=-s.bars.barWidth;break;default:barLeft=-s.bars.barWidth/2}barRight=barLeft+s.bars.barWidth;for(j=0;j<points.length;j+=ps){var x=points[j],y=points[j+1],b=points[j+2];if(x==null)continue;if(series[i].bars.horizontal?mx<=Math.max(b,x)&&mx>=Math.min(b,x)&&my>=y+barLeft&&my<=y+barRight:mx>=x+barLeft&&mx<=x+barRight&&my>=Math.min(b,y)&&my<=Math.max(b,y))item=[i,j/ps]}}}if(item){i=item[0];j=item[1];ps=series[i].datapoints.pointsize;return{datapoint:series[i].datapoints.points.slice(j*ps,(j+1)*ps),dataIndex:j,series:series[i],seriesIndex:i}}return null}function onMouseMove(e){if(options.grid.hoverable)triggerClickHoverEvent("plothover",e,function(s){return s["hoverable"]!=false})}function onMouseLeave(e){if(options.grid.hoverable)triggerClickHoverEvent("plothover",e,function(s){return false})}function onClick(e){triggerClickHoverEvent("plotclick",e,function(s){return s["clickable"]!=false})}function triggerClickHoverEvent(eventname,event,seriesFilter){var offset=eventHolder.offset(),canvasX=event.pageX-offset.left-plotOffset.left,canvasY=event.pageY-offset.top-plotOffset.top,pos=canvasToAxisCoords({left:canvasX,top:canvasY});pos.pageX=event.pageX;pos.pageY=event.pageY;var item=findNearbyItem(canvasX,canvasY,seriesFilter);if(item){item.pageX=parseInt(item.series.xaxis.p2c(item.datapoint[0])+offset.left+plotOffset.left,10);item.pageY=parseInt(item.series.yaxis.p2c(item.datapoint[1])+offset.top+plotOffset.top,10)}if(options.grid.autoHighlight){for(var i=0;i<highlights.length;++i){var h=highlights[i];if(h.auto==eventname&&!(item&&h.series==item.series&&h.point[0]==item.datapoint[0]&&h.point[1]==item.datapoint[1]))unhighlight(h.series,h.point)}if(item)highlight(item.series,item.datapoint,eventname)}placeholder.trigger(eventname,[pos,item])}function triggerRedrawOverlay(){var t=options.interaction.redrawOverlayInterval;if(t==-1){drawOverlay();return}if(!redrawTimeout)redrawTimeout=setTimeout(drawOverlay,t)}function drawOverlay(){redrawTimeout=null;octx.save();overlay.clear();octx.translate(plotOffset.left,plotOffset.top);var i,hi;for(i=0;i<highlights.length;++i){hi=highlights[i];if(hi.series.bars.show)drawBarHighlight(hi.series,hi.point);else drawPointHighlight(hi.series,hi.point)}octx.restore();executeHooks(hooks.drawOverlay,[octx])}function highlight(s,point,auto){if(typeof s=="number")s=series[s];if(typeof point=="number"){var ps=s.datapoints.pointsize;point=s.datapoints.points.slice(ps*point,ps*(point+1))}var i=indexOfHighlight(s,point);if(i==-1){highlights.push({series:s,point:point,auto:auto});triggerRedrawOverlay()}else if(!auto)highlights[i].auto=false}function unhighlight(s,point){if(s==null&&point==null){highlights=[];triggerRedrawOverlay();return}if(typeof s=="number")s=series[s];if(typeof point=="number"){var ps=s.datapoints.pointsize;point=s.datapoints.points.slice(ps*point,ps*(point+1))}var i=indexOfHighlight(s,point);if(i!=-1){highlights.splice(i,1);triggerRedrawOverlay()}}function indexOfHighlight(s,p){for(var i=0;i<highlights.length;++i){var h=highlights[i];if(h.series==s&&h.point[0]==p[0]&&h.point[1]==p[1])return i}return-1}function drawPointHighlight(series,point){var x=point[0],y=point[1],axisx=series.xaxis,axisy=series.yaxis,highlightColor=typeof series.highlightColor==="string"?series.highlightColor:$.color.parse(series.color).scale("a",.5).toString();if(x<axisx.min||x>axisx.max||y<axisy.min||y>axisy.max)return;var pointRadius=series.points.radius+series.points.lineWidth/2;octx.lineWidth=pointRadius;octx.strokeStyle=highlightColor;var radius=1.5*pointRadius;x=axisx.p2c(x);y=axisy.p2c(y);octx.beginPath();if(series.points.symbol=="circle")octx.arc(x,y,radius,0,2*Math.PI,false);else series.points.symbol(octx,x,y,radius,false);octx.closePath();octx.stroke()}function drawBarHighlight(series,point){var highlightColor=typeof series.highlightColor==="string"?series.highlightColor:$.color.parse(series.color).scale("a",.5).toString(),fillStyle=highlightColor,barLeft;switch(series.bars.align){case"left":barLeft=0;break;case"right":barLeft=-series.bars.barWidth;break;default:barLeft=-series.bars.barWidth/2}octx.lineWidth=series.bars.lineWidth;octx.strokeStyle=highlightColor;drawBar(point[0],point[1],point[2]||0,barLeft,barLeft+series.bars.barWidth,function(){return fillStyle},series.xaxis,series.yaxis,octx,series.bars.horizontal,series.bars.lineWidth)}function getColorOrGradient(spec,bottom,top,defaultColor){if(typeof spec=="string")return spec;else{var gradient=ctx.createLinearGradient(0,top,0,bottom);for(var i=0,l=spec.colors.length;i<l;++i){var c=spec.colors[i];if(typeof c!="string"){var co=$.color.parse(defaultColor);if(c.brightness!=null)co=co.scale("rgb",c.brightness);if(c.opacity!=null)co.a*=c.opacity;c=co.toString()}gradient.addColorStop(i/(l-1),c)}return gradient}}}$.plot=function(placeholder,data,options){var plot=new Plot($(placeholder),data,options,$.plot.plugins);return plot};$.plot.version="0.8.3";$.plot.plugins=[];$.fn.plot=function(data,options){return this.each(function(){$.plot(this,data,options)})};function floorInBase(n,base){return base*Math.floor(n/base)}})(jQuery);+ </script>+ <script language="javascript" type="text/javascript">+ (function ($) {+ $.zip = function(a,b) {+ var x = Math.min(a.length,b.length);+ var c = new Array(x);+ for (var i = 0; i < x; i++)+ c[i] = [a[i],b[i]];+ return c;+ };++ $.mean = function(ary) {+ var m = 0, i = 0;++ while (i < ary.length) {+ var j = i++;+ m += (ary[j] - m) / i;+ }++ return m;+ };++ $.timeUnits = function(secs) {+ if (secs < 0) return $.timeUnits(-secs);+ else if (secs >= 1e9) return [1e-9, "Gs"];+ else if (secs >= 1e6) return [1e-6, "Ms"];+ else if (secs >= 1) return [1, "s"];+ else if (secs >= 1e-3) return [1e3, "ms"];+ else if (secs >= 1e-6) return [1e6, "\u03bcs"];+ else if (secs >= 1e-9) return [1e9, "ns"];+ else if (secs >= 1e-12) return [1e12, "ps"];+ return [1, "s"];+ };++ $.scaleTimes = function(ary) {+ var s = $.timeUnits($.mean(ary));+ return [$.scaleBy(s[0], ary), s[0]];+ };++ $.prepareTime = function(secs) {+ var units = $.timeUnits(secs);+ var scaled = secs * units[0];+ var s = scaled.toPrecision(3);+ var t = scaled.toString();+ return [t.length < s.length ? t : s, units[1]];+ };++ $.scaleBy = function(x, ary) {+ var nary = new Array(ary.length);+ for (var i = 0; i < ary.length; i++)+ nary[i] = ary[i] * x;+ return nary;+ };++ $.renderTime = function(secs) {+ var x = $.prepareTime(secs);+ return x[0] + ' ' + x[1];+ };++ $.unitFormatter = function(scale) {+ var labelname;+ return function(secs,axis) {+ var x = $.prepareTime(secs / scale);+ if (labelname === x[1])+ return x[0];+ else {+ labelname = x[1];+ return x[0] + ' ' + x[1];+ }+ };+ };++ $.addTooltip = function(name, renderText) {+ function showTooltip(x, y, contents) {+ $('<div id="tooltip">' + contents + '</div>').css( {+ position: 'absolute',+ display: 'none',+ top: y + 5,+ left: x + 5,+ border: '1px solid #fdd',+ padding: '2px',+ 'background-color': '#fee',+ opacity: 0.80+ }).appendTo("body").fadeIn(200);+ };+ var pp = null;+ $(name).bind("plothover", function (event, pos, item) {+ $("#x").text(pos.x.toFixed(2));+ $("#y").text(pos.y.toFixed(2));++ if (item) {+ if (pp != item.dataIndex) {+ pp = item.dataIndex;++ $("#tooltip").remove();+ var x = item.datapoint[0],+ y = item.datapoint[1];++ showTooltip(item.pageX, item.pageY, renderText(x,y));+ }+ }+ else {+ $("#tooltip").remove();+ pp = null;+ }+ });+ };+})(jQuery);++ </script>+ <style type="text/css">+html, body {+ height: 100%;+ margin: 0;+}++#wrap {+ min-height: 100%;+}++#main {+ overflow: auto;+ padding-bottom: 180px; /* must be same height as the footer */+}++#footer {+ position: relative;+ margin-top: -180px; /* negative value of footer height */+ height: 180px;+ clear: both;+ background: #888;+ margin: 40px 0 0;+ color: white;+ font-size: larger;+ font-weight: 300;+}++body:before {+ /* Opera fix */+ content: "";+ height: 100%;+ float: left;+ width: 0;+ margin-top: -32767px;+}++body {+ font: 14px Helvetica Neue;+ text-rendering: optimizeLegibility;+ margin-top: 1em;+}++a:link {+ color: steelblue;+ text-decoration: none;+}++a:visited {+ color: #4a743b;+ text-decoration: none;+}++#footer a {+ color: white;+ text-decoration: underline;+}++.hover {+ color: steelblue;+ text-decoration: none;+}++.body {+ width: 960px;+ margin: auto;+}++.footfirst {+ position: relative;+ top: 30px;+}++th {+ font-weight: 500;+ opacity: 0.8;+}++th.cibound {+ opacity: 0.4;+}++.confinterval {+ opacity: 0.5;+}++h1 {+ font-size: 36px;+ font-weight: 300;+ margin-bottom: .3em;+}++h2 {+ font-size: 30px;+ font-weight: 300;+ margin-bottom: .3em;+}++.meanlegend {+ color: #404040;+ background-color: #ffffff;+ opacity: 0.6;+ font-size: smaller;+}++ </style>+ <!--[if !IE 7]>+ <style type="text/css">+ #wrap {display:table;height:100%}+ </style>+ <![endif]-->+ </head>+ <body>+ <div id="wrap">+ <div id="main" class="body">+ <h1>criterion performance measurements</h1>++<h2>overview</h2>++<p><a href="#grokularation">want to understand this report?</a></p>++<div id="overview" class="ovchart" style="width:900px;height:100px;"></div>++<h2><a name="b0">fib/1</a></h2>+ <table width="100%">+ <tbody>+ <tr>+ <td><div id="kde0" class="kdechart"+ style="width:450px;height:278px;"></div></td>+ <td><div id="time0" class="timechart"+ style="width:450px;height:278px;"></div></td>+<!--+ <td><div id="cycle0" class="cyclechart"+ style="width:300px;height:278px;"></div></td>+-->+ </tr>+ </tbody>+ </table>++ <table>+ <thead class="analysis">+ <th></th>+ <th class="cibound"+ title="0.95 confidence level">lower bound</th>+ <th>estimate</th>+ <th class="cibound"+ title="0.95 confidence level">upper bound</th>+ </thead>+ <tbody>+ <tr>+ <td>OLS regression</td>+ <td><span class="confinterval olstimelb0">xxx</span></td>+ <td><span class="olstimept0">xxx</span></td>+ <td><span class="confinterval olstimeub0">xxx</span></td>+ </tr>+ <tr>+ <td>R² goodness-of-fit</td>+ <td><span class="confinterval olsr2lb0">xxx</span></td>+ <td><span class="olsr2pt0">xxx</span></td>+ <td><span class="confinterval olsr2ub0">xxx</span></td>+ </tr>+ <tr>+ <td>Mean execution time</td>+ <td><span class="confinterval citime">2.31459993168433e-8</span></td>+ <td><span class="time">2.374225969306158e-8</span></td>+ <td><span class="confinterval citime">2.4336041431094957e-8</span></td>+ </tr>+ <tr>+ <td>Standard deviation</td>+ <td><span class="confinterval citime">1.7147402747620926e-9</span></td>+ <td><span class="time">1.984234308811127e-9</span></td>+ <td><span class="confinterval citime">2.3435359738948246e-9</span></td>+ </tr>+ </tbody>+ </table>++ <span class="outliers">+ <p>Outlying measurements have severe+ (<span class="percent">0.8827515417826841</span>%)+ effect on estimated standard deviation.</p>+ </span>+<h2><a name="b1">fib/5</a></h2>+ <table width="100%">+ <tbody>+ <tr>+ <td><div id="kde1" class="kdechart"+ style="width:450px;height:278px;"></div></td>+ <td><div id="time1" class="timechart"+ style="width:450px;height:278px;"></div></td>+<!--+ <td><div id="cycle1" class="cyclechart"+ style="width:300px;height:278px;"></div></td>+-->+ </tr>+ </tbody>+ </table>++ <table>+ <thead class="analysis">+ <th></th>+ <th class="cibound"+ title="0.95 confidence level">lower bound</th>+ <th>estimate</th>+ <th class="cibound"+ title="0.95 confidence level">upper bound</th>+ </thead>+ <tbody>+ <tr>+ <td>OLS regression</td>+ <td><span class="confinterval olstimelb1">xxx</span></td>+ <td><span class="olstimept1">xxx</span></td>+ <td><span class="confinterval olstimeub1">xxx</span></td>+ </tr>+ <tr>+ <td>R² goodness-of-fit</td>+ <td><span class="confinterval olsr2lb1">xxx</span></td>+ <td><span class="olsr2pt1">xxx</span></td>+ <td><span class="confinterval olsr2ub1">xxx</span></td>+ </tr>+ <tr>+ <td>Mean execution time</td>+ <td><span class="confinterval citime">3.640686812141915e-7</span></td>+ <td><span class="time">3.7647973827317373e-7</span></td>+ <td><span class="confinterval citime">3.8862828356384757e-7</span></td>+ </tr>+ <tr>+ <td>Standard deviation</td>+ <td><span class="confinterval citime">3.5904833037515274e-8</span></td>+ <td><span class="time">4.150785932735141e-8</span></td>+ <td><span class="confinterval citime">4.81505001531474e-8</span></td>+ </tr>+ </tbody>+ </table>++ <span class="outliers">+ <p>Outlying measurements have severe+ (<span class="percent">0.917699613099007</span>%)+ effect on estimated standard deviation.</p>+ </span>+<h2><a name="b2">fib/9</a></h2>+ <table width="100%">+ <tbody>+ <tr>+ <td><div id="kde2" class="kdechart"+ style="width:450px;height:278px;"></div></td>+ <td><div id="time2" class="timechart"+ style="width:450px;height:278px;"></div></td>+<!--+ <td><div id="cycle2" class="cyclechart"+ style="width:300px;height:278px;"></div></td>+-->+ </tr>+ </tbody>+ </table>++ <table>+ <thead class="analysis">+ <th></th>+ <th class="cibound"+ title="0.95 confidence level">lower bound</th>+ <th>estimate</th>+ <th class="cibound"+ title="0.95 confidence level">upper bound</th>+ </thead>+ <tbody>+ <tr>+ <td>OLS regression</td>+ <td><span class="confinterval olstimelb2">xxx</span></td>+ <td><span class="olstimept2">xxx</span></td>+ <td><span class="confinterval olstimeub2">xxx</span></td>+ </tr>+ <tr>+ <td>R² goodness-of-fit</td>+ <td><span class="confinterval olsr2lb2">xxx</span></td>+ <td><span class="olsr2pt2">xxx</span></td>+ <td><span class="confinterval olsr2ub2">xxx</span></td>+ </tr>+ <tr>+ <td>Mean execution time</td>+ <td><span class="confinterval citime">2.5489390737084626e-6</span></td>+ <td><span class="time">2.614524699113428e-6</span></td>+ <td><span class="confinterval citime">2.700766045605913e-6</span></td>+ </tr>+ <tr>+ <td>Standard deviation</td>+ <td><span class="confinterval citime">2.0893167057513842e-7</span></td>+ <td><span class="time">2.4922772413717383e-7</span></td>+ <td><span class="confinterval citime">3.0480780278156827e-7</span></td>+ </tr>+ </tbody>+ </table>++ <span class="outliers">+ <p>Outlying measurements have severe+ (<span class="percent">0.86814310186276</span>%)+ effect on estimated standard deviation.</p>+ </span>+<h2><a name="b3">fib/11</a></h2>+ <table width="100%">+ <tbody>+ <tr>+ <td><div id="kde3" class="kdechart"+ style="width:450px;height:278px;"></div></td>+ <td><div id="time3" class="timechart"+ style="width:450px;height:278px;"></div></td>+<!--+ <td><div id="cycle3" class="cyclechart"+ style="width:300px;height:278px;"></div></td>+-->+ </tr>+ </tbody>+ </table>++ <table>+ <thead class="analysis">+ <th></th>+ <th class="cibound"+ title="0.95 confidence level">lower bound</th>+ <th>estimate</th>+ <th class="cibound"+ title="0.95 confidence level">upper bound</th>+ </thead>+ <tbody>+ <tr>+ <td>OLS regression</td>+ <td><span class="confinterval olstimelb3">xxx</span></td>+ <td><span class="olstimept3">xxx</span></td>+ <td><span class="confinterval olstimeub3">xxx</span></td>+ </tr>+ <tr>+ <td>R² goodness-of-fit</td>+ <td><span class="confinterval olsr2lb3">xxx</span></td>+ <td><span class="olsr2pt3">xxx</span></td>+ <td><span class="confinterval olsr2ub3">xxx</span></td>+ </tr>+ <tr>+ <td>Mean execution time</td>+ <td><span class="confinterval citime">6.347714383730146e-6</span></td>+ <td><span class="time">6.496202868182492e-6</span></td>+ <td><span class="confinterval citime">6.668634037917654e-6</span></td>+ </tr>+ <tr>+ <td>Standard deviation</td>+ <td><span class="confinterval citime">4.0420784296930194e-7</span></td>+ <td><span class="time">4.919233380857326e-7</span></td>+ <td><span class="confinterval citime">6.202125623223447e-7</span></td>+ </tr>+ </tbody>+ </table>++ <span class="outliers">+ <p>Outlying measurements have severe+ (<span class="percent">0.7876656352417168</span>%)+ effect on estimated standard deviation.</p>+ </span>++ <h2><a name="grokularation">understanding this report</a></h2>++ <p>In this report, each function benchmarked by criterion is assigned+ a section of its own. The charts in each section are active; if+ you hover your mouse over data points and annotations, you will see+ more details.</p>++ <ul>+ <li>The chart on the left is a+ <a href="http://en.wikipedia.org/wiki/Kernel_density_estimation">kernel+ density estimate</a> (also known as a KDE) of time+ measurements. This graphs the probability of any given time+ measurement occurring. A spike indicates that a measurement of a+ particular time occurred; its height indicates how often that+ measurement was repeated.</li>++ <li>The chart on the right is the raw data from which the kernel+ density estimate is built. The <i>x</i> axis indicates the+ number of loop iterations, while the <i>y</i> axis shows measured+ execution time for the given number of loop iterations. The+ line behind the values is the linear regression prediction of+ execution time for a given number of iterations. Ideally, all+ measurements will be on (or very near) this line.</li>+ </ul>++ <p>Under the charts is a small table.+ The first two rows are the results of a linear regression run+ on the measurements displayed in the right-hand chart.</p>++ <ul>+ <li><i>OLS regression</i> indicates the+ time estimated for a single loop iteration using an ordinary+ least-squares regression model. This number is more accurate+ than the <i>mean</i> estimate below it, as it more effectively+ eliminates measurement overhead and other constant factors.</li>+ <li><i>R² goodness-of-fit</i> is a measure of how+ accurately the linear regression model fits the observed+ measurements. If the measurements are not too noisy, R²+ should lie between 0.99 and 1, indicating an excellent fit. If+ the number is below 0.99, something is confounding the accuracy+ of the linear model.</li>+ <li><i>Mean execution time</i> and <i>standard deviation</i> are+ statistics calculated from execution time+ divided by number of iterations.</li>+ </ul>++ <p>We use a statistical technique called+ the <a href="http://en.wikipedia.org/wiki/Bootstrapping_(statistics)">bootstrap</a>+ to provide confidence intervals on our estimates. The+ bootstrap-derived upper and lower bounds on estimates let you see+ how accurate we believe those estimates to be. (Hover the mouse+ over the table headers to see the confidence levels.)</p>++ <p>A noisy benchmarking environment can cause some or many+ measurements to fall far from the mean. These outlying+ measurements can have a significant inflationary effect on the+ estimate of the standard deviation. We calculate and display an+ estimate of the extent to which the standard deviation has been+ inflated by outliers.</p>++<script type="text/javascript">+$(function () {+ function mangulate(rpt) {+ var measured = function(key) {+ var idx = rpt.reportKeys.indexOf(key);+ return rpt.reportMeasured.map(function(r) { return r[idx]; });+ };+ var number = rpt.reportNumber;+ var name = rpt.reportName;+ var mean = rpt.reportAnalysis.anMean.estPoint;+ var iters = measured("iters");+ var times = measured("time");+ var kdetimes = rpt.reportKDEs[0].kdeValues;+ var kdepdf = rpt.reportKDEs[0].kdePDF;++ var meanSecs = mean;+ var units = $.timeUnits(mean);+ var rgrs = rpt.reportAnalysis.anRegress[0];+ var scale = units[0];+ var olsTime = rgrs.regCoeffs.iters;+ $(".olstimept" + number).text(function() {+ return $.renderTime(olsTime.estPoint);+ });+ $(".olstimelb" + number).text(function() {+ return $.renderTime(olsTime.estLowerBound);+ });+ $(".olstimeub" + number).text(function() {+ return $.renderTime(olsTime.estUpperBound);+ });+ $(".olsr2pt" + number).text(function() {+ return rgrs.regRSquare.estPoint.toFixed(3);+ });+ $(".olsr2lb" + number).text(function() {+ return rgrs.regRSquare.estLowerBound.toFixed(3);+ });+ $(".olsr2ub" + number).text(function() {+ return rgrs.regRSquare.estUpperBound.toFixed(3);+ });+ mean *= scale;+ kdetimes = $.scaleBy(scale, kdetimes);+ var kq = $("#kde" + number);+ var k = $.plot(kq,+ [{ label: name + " time densities",+ data: $.zip(kdetimes, kdepdf),+ }],+ { xaxis: { tickFormatter: $.unitFormatter(scale) },+ yaxis: { ticks: false },+ grid: { borderColor: "#777",+ hoverable: true, markings: [ { color: '#6fd3fb',+ lineWidth: 1.5, xaxis: { from: mean, to: mean } } ] },+ });+ var o = k.pointOffset({ x: mean, y: 0});+ kq.append('<div class="meanlegend" title="' + $.renderTime(meanSecs) ++ '" style="position:absolute;left:' + (o.left + 4) ++ 'px;bottom:139px;">mean</div>');+ $.addTooltip("#kde" + number,+ function(secs) { return $.renderTime(secs / scale); });+ var timepairs = new Array(times.length);+ var lastiter = iters[iters.length-1];+ var olspairs = [[0,0], [lastiter, lastiter * scale * olsTime.estPoint]];+ for (var i = 0; i < times.length; i++)+ timepairs[i] = [iters[i],times[i]*scale];+ iterFormatter = function() {+ var denom = 0;+ return function(iters) {+ if (iters == 0)+ return '';+ if (denom > 0)+ return (iters / denom).toFixed();+ var power;+ if (iters >= 1e9) {+ denom = '1e9'; power = '⁹';+ }+ if (iters >= 1e6) {+ denom = '1e6'; power = '⁶';+ }+ else if (iters >= 1e3) {+ denom = '1e3'; power = '³';+ }+ else denom = 1;+ if (denom > 1) {+ iters = (iters / denom).toFixed();+ iters += '×10' + power + ' iters';+ } else {+ iters += ' iters';+ }+ return iters;+ };+ };+ $.plot($("#time" + number),+ [{ label: "regression", data: olspairs,+ lines: { show: true } },+ { label: name + " times", data: timepairs,+ points: { show: true } }],+ { grid: { borderColor: "#777", hoverable: true },+ xaxis: { tickFormatter: iterFormatter() },+ yaxis: { tickFormatter: $.unitFormatter(scale) } });+ $.addTooltip("#time" + number,+ function(iters,secs) {+ return ($.renderTime(secs / scale) + ' / ' ++ iters.toLocaleString() + ' iters');+ });+ if (0) {+ var cyclepairs = new Array(cycles.length);+ for (var i = 0; i < cycles.length; i++)+ cyclepairs[i] = [cycles[i],i];+ $.plot($("#cycle" + number),+ [{ label: name + " cycles",+ data: cyclepairs }],+ { points: { show: true },+ grid: { borderColor: "#777", hoverable: true },+ xaxis: { tickFormatter:+ function(cycles,axis) { return cycles + ' cycles'; }},+ yaxis: { ticks: false },+ });+ $.addTooltip("#cycles" + number, function(x,y) { return x + ' cycles'; });+ }+ };+ var reports = [{"reportAnalysis":{"anMean":{"estUpperBound":2.4336041431094957e-8,"estLowerBound":2.31459993168433e-8,"estPoint":2.374225969306158e-8,"estConfidenceLevel":0.95},"anRegress":[{"regRSquare":{"estUpperBound":0.9968607334095598,"estLowerBound":0.9931281346179867,"estPoint":0.9952316835320134,"estConfidenceLevel":0.95},"regResponder":"time","regCoeffs":{"y":{"estUpperBound":-3.425955804843936e-4,"estLowerBound":-7.654756798125064e-4,"estPoint":-5.600471908843124e-4,"estConfidenceLevel":0.95},"iters":{"estUpperBound":2.5046637898223406e-8,"estLowerBound":2.3842309287675006e-8,"estPoint":2.452217275933509e-8,"estConfidenceLevel":0.95}}}],"anStdDev":{"estUpperBound":2.3435359738948246e-9,"estLowerBound":1.7147402747620926e-9,"estPoint":1.984234308811127e-9,"estConfidenceLevel":0.95},"anOutlierVar":{"ovFraction":0.8827515417826841,"ovDesc":"severe","ovEffect":"Severe"},"anOverhead":3.161534180001628e-6},"reportKDEs":[{"kdeValues":[1.989878208361153e-8,1.9968424229205795e-8,2.003806637480006e-8,2.0107708520394325e-8,2.0177350665988587e-8,2.024699281158285e-8,2.0316634957177116e-8,2.038627710277138e-8,2.0455919248365646e-8,2.052556139395991e-8,2.0595203539554173e-8,2.0664845685148438e-8,2.0734487830742702e-8,2.0804129976336967e-8,2.0873772121931232e-8,2.0943414267525497e-8,2.1013056413119762e-8,2.1082698558714023e-8,2.1152340704308288e-8,2.1221982849902553e-8,2.1291624995496818e-8,2.1361267141091083e-8,2.1430909286685348e-8,2.150055143227961e-8,2.1570193577873874e-8,2.163983572346814e-8,2.1709477869062404e-8,2.177912001465667e-8,2.1848762160250934e-8,2.1918404305845195e-8,2.198804645143946e-8,2.2057688597033725e-8,2.212733074262799e-8,2.2196972888222255e-8,2.226661503381652e-8,2.2336257179410785e-8,2.2405899325005046e-8,2.247554147059931e-8,2.2545183616193576e-8,2.261482576178784e-8,2.2684467907382106e-8,2.275411005297637e-8,2.2823752198570635e-8,2.2893394344164897e-8,2.2963036489759162e-8,2.3032678635353427e-8,2.310232078094769e-8,2.3171962926541956e-8,2.3241605072136218e-8,2.3311247217730483e-8,2.3380889363324748e-8,2.3450531508919013e-8,2.3520173654513278e-8,2.3589815800107542e-8,2.3659457945701807e-8,2.372910009129607e-8,2.3798742236890334e-8,2.38683843824846e-8,2.3938026528078863e-8,2.4007668673673128e-8,2.407731081926739e-8,2.4146952964861658e-8,2.421659511045592e-8,2.4286237256050185e-8,2.435587940164445e-8,2.4425521547238714e-8,2.449516369283298e-8,2.456480583842724e-8,2.463444798402151e-8,2.470409012961577e-8,2.4773732275210035e-8,2.48433744208043e-8,2.4913016566398565e-8,2.498265871199283e-8,2.505230085758709e-8,2.5121943003181356e-8,2.519158514877562e-8,2.5261227294369886e-8,2.533086943996415e-8,2.5400511585558416e-8,2.547015373115268e-8,2.5539795876746942e-8,2.5609438022341207e-8,2.5679080167935472e-8,2.5748722313529737e-8,2.5818364459124002e-8,2.5888006604718263e-8,2.595764875031253e-8,2.6027290895906793e-8,2.6096933041501058e-8,2.6166575187095323e-8,2.6236217332689588e-8,2.6305859478283853e-8,2.6375501623878114e-8,2.644514376947238e-8,2.6514785915066644e-8,2.658442806066091e-8,2.6654070206255174e-8,2.672371235184944e-8,2.6793354497443703e-8,2.6862996643037965e-8,2.693263878863223e-8,2.7002280934226495e-8,2.707192307982076e-8,2.7141565225415025e-8,2.7211207371009286e-8,2.7280849516603554e-8,2.7350491662197816e-8,2.742013380779208e-8,2.7489775953386346e-8,2.755941809898061e-8,2.7629060244574875e-8,2.7698702390169137e-8,2.7768344535763405e-8,2.7837986681357667e-8,2.790762882695193e-8,2.7977270972546196e-8,2.8046913118140458e-8,2.8116555263734726e-8,2.8186197409328988e-8,2.8255839554923253e-8,2.8325481700517517e-8,2.8395123846111782e-8,2.8464765991706047e-8,2.853440813730031e-8,2.8604050282894577e-8,2.867369242848884e-8,2.8743334574083103e-8],"kdeType":"time","kdePDF":[1.1395895337002747e8,1.1399586448390599e8,1.1406966699669889e8,1.141803208709782e8,1.143277645338929e8,1.1451191306306463e8,1.1473265577838261e8,1.1498985325011694e8,1.152833337379588e8,1.1561288908069459e8,1.1597827006230259e8,1.1637918128730445e8,1.1681527560615641e8,1.1728614814018439e8,1.1779132996487482e8,1.1833028151996909e8,1.1890238582449803e8,1.1950694158429071e8,1.201431562882586e8,1.2081013939751814e8,1.2150689573782589e8,1.2223231921050385e8,1.2298518693974209e8,1.2376415397459902e8,1.2456774866200176e8,1.2539436880242184e8,1.2624227869264197e8,1.2710960715014195e8,1.2799434660125354e8,1.2889435330055325e8,1.2980734873227204e8,1.3073092222615018e8,1.3166253480058819e8,1.3259952422560526e8,1.3353911127754031e8,1.3447840713714716e8,1.3541442186329383e8,1.3634407385640383e8,1.372642002095804e8,1.381715678314893e8,1.3906288521393478e8,1.3993481470897296e8,1.4078398517559382e8,1.4160700485461792e8,1.4240047433251885e8,1.4316099946035716e8,1.4388520410270315e8,1.4456974260309508e8,1.4521131186685443e8,1.458066629785387e8,1.463526122894414e8,1.468460519298112e8,1.4728395972024703e8,1.476634084764515e8,1.479815747205615e8,1.4823574683005878e8,1.4842333267122668e8,1.4854186677778667e8,1.4858901714627486e8,1.485625917275835e8,1.4846054469862348e8,1.482809825991286e8,1.4802217041616246e8,1.4768253769297192e8,1.4726068472961387e8,1.4675538893053663e8,1.4616561133936232e8,1.4549050338394704e8,1.4472941383586738e8,1.4388189596837926e8,1.4294771487617913e8,1.419268548996135e8,1.408195270759097e8,1.3962617652117708e8,1.383474896298825e8,1.3698440096379948e8,1.3553809969048512e8,1.3401003542258318e8,1.3240192330394386e8,1.3071574818694907e8,1.2895376774760398e8,1.2711851439096606e8,1.2521279580920233e8,1.2323969406786159e8,1.2120256311251064e8,1.1910502460740013e8,1.1695096203983772e8,1.1474451304800186e8,1.1249005995546557e8,1.1019221852217361e8,1.0785582494841896e8,1.0548592119492327e8,1.0308773870783295e8,1.0066668066176452e8,9.822830285641795e7,9.577829342227527e7,9.332245150807737e7,9.086666513679452e7,8.841688842738897e7,8.597911838663742e7,8.355937147851193e7,8.116366017811044e7,7.87979697129248e7,7.646823518650009e7,7.418031926847933e7,7.193999062095061e7,6.975290321426049e7,6.76245766664537e7,6.5560377719679065e7,6.356550294477145e7,6.164496274226723e7,5.9803566684867114e7,5.804591022332826e7,5.637636275545833e7,5.479905703675971e7,5.331787989178828e7,5.19364641678301e7,5.0658181857415326e7,4.9486138303759255e7,4.842316739367089e7,4.74718276359435e7,4.663439901982578e7,4.591288054786622e7,4.530898834016642e7,4.4824154212732054e7,4.44595246409754e7,4.421596003023277e7,4.409403422810118e7]}],"reportKeys":["time","cpuTime","cycles","iters","allocated","numGcs","bytesCopied","mutatorWallSeconds","mutatorCpuSeconds","gcWallSeconds","gcCpuSeconds"],"reportNumber":0,"reportName":"fib/1","reportOutliers":{"highSevere":0,"highMild":0,"lowMild":0,"samplesSeen":41,"lowSevere":0},"reportMeasured":[[7.638998795300722e-6,6.000000000000796e-6,4658,1,null,null,null,null,null,null,null],[2.0030129235237837e-6,2.0000000000002655e-6,3978,2,null,null,null,null,null,null,null],[1.601001713424921e-6,9.999999999992654e-7,3144,3,null,null,null,null,null,null,null],[1.5189871191978455e-6,9.999999999975306e-7,3118,4,null,null,null,null,null,null,null],[1.4929973985999823e-6,9.999999999992654e-7,3084,5,null,null,null,null,null,null,null],[1.447013346478343e-6,2.0000000000002655e-6,3018,6,null,null,null,null,null,null,null],[1.4870020095258951e-6,9.999999999992654e-7,3126,7,null,null,null,null,null,null,null],[1.5980040188878775e-6,1.9999999999985307e-6,3436,8,null,null,null,null,null,null,null],[1.5170080587267876e-6,9.999999999992654e-7,3234,9,null,null,null,null,null,null,null],[1.561013050377369e-6,1.000000000001e-6,3362,10,null,null,null,null,null,null,null],[1.6170088201761246e-6,2.0000000000002655e-6,3464,11,null,null,null,null,null,null,null],[1.6060075722634792e-6,9.999999999992654e-7,3308,12,null,null,null,null,null,null,null],[1.620996044948697e-6,2.999999999999531e-6,3336,13,null,null,null,null,null,null,null],[1.5929981600493193e-6,9.999999999992654e-7,3450,14,null,null,null,null,null,null,null],[1.6530102584511042e-6,2.0000000000002655e-6,3582,15,null,null,null,null,null,null,null],[1.66997779160738e-6,3.0000000000012655e-6,3634,16,null,null,null,null,null,null,null],[1.6599951777607203e-6,1.000000000001e-6,3480,17,null,null,null,null,null,null,null],[1.7060083337128162e-6,1.9999999999985307e-6,3622,18,null,null,null,null,null,null,null],[1.7429993022233248e-6,9.999999999992654e-7,3750,19,null,null,null,null,null,null,null],[1.7330166883766651e-6,2.0000000000002655e-6,3690,20,null,null,null,null,null,null,null],[1.7400016076862812e-6,1.000000000001e-6,3700,21,null,null,null,null,null,null,null],[1.7929996829479933e-6,1.9999999999985307e-6,3744,22,null,null,null,null,null,null,null],[1.8269929569214582e-6,9.999999999975306e-7,3856,23,null,null,null,null,null,null,null],[1.9319995772093534e-6,1.9999999999985307e-6,4000,25,null,null,null,null,null,null,null],[1.8299906514585018e-6,2.0000000000002655e-6,4004,26,null,null,null,null,null,null,null],[2.001994289457798e-6,1.9999999999985307e-6,4084,27,null,null,null,null,null,null,null],[1.9379949662834406e-6,2.0000000000002655e-6,4032,28,null,null,null,null,null,null,null],[1.9339786376804113e-6,2.0000000000002655e-6,4132,30,null,null,null,null,null,null,null],[2.001004759222269e-6,2.0000000000002655e-6,4260,31,null,null,null,null,null,null,null],[1.99698843061924e-6,2.0000000000002655e-6,4264,33,null,null,null,null,null,null,null],[2.0099978428333998e-6,2.0000000000002655e-6,4332,35,null,null,null,null,null,null,null],[2.1180021576583385e-6,2.0000000000002655e-6,4468,36,null,null,null,null,null,null,null],[2.0809820853173733e-6,2.000000000002e-6,4422,38,null,null,null,null,null,null,null],[2.2199819795787334e-6,2.000000000002e-6,4714,40,null,null,null,null,null,null,null],[2.173997927457094e-6,1.9999999999985307e-6,4662,42,null,null,null,null,null,null,null],[2.2099993657320738e-6,1.9999999999985307e-6,4772,44,null,null,null,null,null,null,null],[2.2700114641338587e-6,1.9999999999985307e-6,4926,47,null,null,null,null,null,null,null],[2.3389875423163176e-6,2.000000000002e-6,5104,49,null,null,null,null,null,null,null],[2.3679749574512243e-6,4.000000000000531e-6,5072,52,null,null,null,null,null,null,null],[2.521992428228259e-6,2.999999999999531e-6,5520,54,null,null,null,null,null,null,null],[2.4710025172680616e-6,2.000000000002e-6,5356,57,null,null,null,null,null,null,null],[2.5459739845246077e-6,2.000000000002e-6,5598,60,null,null,null,null,null,null,null],[2.6070047169923782e-6,3.0000000000012655e-6,5578,63,null,null,null,null,null,null,null],[2.7070054784417152e-6,2.999999999999531e-6,5796,66,null,null,null,null,null,null,null],[2.7520000003278255e-6,2.999999999999531e-6,5938,69,null,null,null,null,null,null,null],[2.820015652105212e-6,2.999999999999531e-6,6094,73,null,null,null,null,null,null,null],[2.903980202972889e-6,2.999999999999531e-6,6318,76,null,null,null,null,null,null,null],[3.0809896998107433e-6,3.0000000000012655e-6,6580,80,null,null,null,null,null,null,null],[3.022985765710473e-6,3.0000000000012655e-6,6520,84,null,null,null,null,null,null,null],[3.1730160117149353e-6,2.999999999999531e-6,6874,89,null,null,null,null,null,null,null],[3.281020326539874e-6,2.999999999999531e-6,7098,93,null,null,null,null,null,null,null],[3.390974598005414e-6,4.000000000000531e-6,7286,98,null,null,null,null,null,null,null],[3.4409749787300825e-6,3.999999999998796e-6,7480,103,null,null,null,null,null,null,null],[3.568013198673725e-6,3.0000000000012655e-6,7696,108,null,null,null,null,null,null,null],[3.6860001273453236e-6,4.000000000002266e-6,7956,113,null,null,null,null,null,null,null],[3.816006937995553e-6,4.000000000000531e-6,8276,119,null,null,null,null,null,null,null],[3.908004146069288e-6,4.000000000000531e-6,8570,125,null,null,null,null,null,null,null],[4.076020559296012e-6,3.999999999998796e-6,8784,131,null,null,null,null,null,null,null],[4.16202237829566e-6,4.999999999999796e-6,9164,138,null,null,null,null,null,null,null],[4.309986252337694e-6,4.999999999999796e-6,9398,144,null,null,null,null,null,null,null],[4.4630141928792e-6,4.999999999999796e-6,9746,152,null,null,null,null,null,null,null],[4.6009954530745745e-6,4.000000000000531e-6,10108,159,null,null,null,null,null,null,null],[4.8349902499467134e-6,4.999999999999796e-6,10498,167,null,null,null,null,null,null,null],[4.989997250959277e-6,4.9999999999980616e-6,10970,176,null,null,null,null,null,null,null],[5.174020770937204e-6,4.999999999999796e-6,11270,185,null,null,null,null,null,null,null],[5.331996362656355e-6,6.000000000000796e-6,11654,194,null,null,null,null,null,null,null],[5.553010851144791e-6,6.000000000000796e-6,12124,204,null,null,null,null,null,null,null],[5.785987013950944e-6,5.000000000001531e-6,12610,214,null,null,null,null,null,null,null],[5.962996510788798e-6,5.999999999999062e-6,13048,224,null,null,null,null,null,null,null],[6.223010132089257e-6,5.999999999999062e-6,13574,236,null,null,null,null,null,null,null],[6.432994268834591e-6,5.999999999999062e-6,14166,247,null,null,null,null,null,null,null],[6.759015377610922e-6,7.000000000000062e-6,14820,260,null,null,null,null,null,null,null],[7.066992111504078e-6,6.999999999998327e-6,15352,273,null,null,null,null,null,null,null],[9.720999514684081e-6,9.999999999999593e-6,22118,287,null,null,null,null,null,null,null],[2.340899663977325e-5,2.5000000000000716e-5,52294,301,null,null,null,null,null,null,null],[1.178999082185328e-5,1.1999999999999858e-5,26130,316,null,null,null,null,null,null,null],[1.2989010429009795e-5,1.3000000000000858e-5,28826,332,null,null,null,null,null,null,null],[1.3224984286352992e-5,1.2999999999999123e-5,29304,348,null,null,null,null,null,null,null],[1.3598008081316948e-5,1.2999999999999123e-5,30028,366,null,null,null,null,null,null,null],[1.3850018149241805e-5,1.2999999999999123e-5,30792,384,null,null,null,null,null,null,null],[1.4401011867448688e-5,1.4000000000001858e-5,31864,403,null,null,null,null,null,null,null],[1.6610982129350305e-5,1.6000000000002124e-5,36708,424,null,null,null,null,null,null,null],[1.5012978110462427e-5,1.5000000000001124e-5,33002,445,null,null,null,null,null,null,null],[1.7034995835274458e-5,1.8000000000000654e-5,37708,467,null,null,null,null,null,null,null],[1.7721002222970128e-5,1.8999999999998185e-5,39234,490,null,null,null,null,null,null,null],[1.8552993424236774e-5,1.799999999999892e-5,41084,515,null,null,null,null,null,null,null],[1.917898771353066e-5,1.9999999999999185e-5,42286,541,null,null,null,null,null,null,null],[2.1567975636571646e-5,2.1000000000000185e-5,47586,568,null,null,null,null,null,null,null],[2.230500103905797e-5,2.300000000000045e-5,49198,596,null,null,null,null,null,null,null],[2.272101119160652e-5,2.1999999999997716e-5,50234,626,null,null,null,null,null,null,null],[2.3773027351126075e-5,2.3000000000002185e-5,52362,657,null,null,null,null,null,null,null],[2.4245004169642925e-5,2.2999999999998716e-5,53572,690,null,null,null,null,null,null,null],[7.000000914558768e-5,6.899999999999962e-5,155598,725,null,null,null,null,null,null,null],[1.7465994460508227e-5,1.6999999999999654e-5,38168,761,null,null,null,null,null,null,null],[1.807598164305091e-5,1.800000000000239e-5,39576,799,null,null,null,null,null,null,null],[1.8852995708584785e-5,1.899999999999992e-5,41516,839,null,null,null,null,null,null,null],[1.9677012460306287e-5,2.000000000000092e-5,43246,881,null,null,null,null,null,null,null],[2.064098953269422e-5,2.1000000000000185e-5,45474,925,null,null,null,null,null,null,null],[2.1629995899274945e-5,2.1999999999997716e-5,47668,972,null,null,null,null,null,null,null],[2.2616994101554155e-5,2.199999999999945e-5,49674,1020,null,null,null,null,null,null,null],[2.367299748584628e-5,2.3999999999999716e-5,52114,1071,null,null,null,null,null,null,null],[2.4829001631587744e-5,2.5000000000000716e-5,54638,1125,null,null,null,null,null,null,null],[2.5999004719778895e-5,2.6000000000001716e-5,57144,1181,null,null,null,null,null,null,null],[2.7219997718930244e-5,2.8000000000000247e-5,59942,1240,null,null,null,null,null,null,null],[2.84140114672482e-5,2.9000000000001247e-5,62510,1302,null,null,null,null,null,null,null],[2.97880033031106e-5,3.0000000000000512e-5,65500,1367,null,null,null,null,null,null,null],[3.1288014724850655e-5,3.100000000000325e-5,68730,1436,null,null,null,null,null,null,null],[5.5037991842254996e-5,5.4999999999999494e-5,123386,1507,null,null,null,null,null,null,null],[3.455500700511038e-5,3.399999999999931e-5,75988,1583,null,null,null,null,null,null,null],[3.6003009881824255e-5,3.600000000000131e-5,79164,1662,null,null,null,null,null,null,null],[3.75809904653579e-5,3.7000000000000574e-5,82780,1745,null,null,null,null,null,null,null],[3.95399983972311e-5,4.0000000000000105e-5,87250,1832,null,null,null,null,null,null,null],[4.142100806348026e-5,4.1999999999998636e-5,91228,1924,null,null,null,null,null,null,null],[4.3387000914663076e-5,4.300000000000137e-5,95434,2020,null,null,null,null,null,null,null],[4.5455992221832275e-5,4.5000000000001636e-5,100018,2121,null,null,null,null,null,null,null],[4.7684996388852596e-5,4.800000000000117e-5,104906,2227,null,null,null,null,null,null,null],[6.012499216012657e-5,5.9999999999997555e-5,134302,2339,null,null,null,null,null,null,null],[5.268098902888596e-5,5.299999999999923e-5,115720,2456,null,null,null,null,null,null,null],[5.501997657120228e-5,5.499999999999776e-5,121068,2579,null,null,null,null,null,null,null],[5.776798934675753e-5,5.8000000000002494e-5,127190,2708,null,null,null,null,null,null,null],[6.043800385668874e-5,5.9999999999997555e-5,133086,2843,null,null,null,null,null,null,null],[6.345799192786217e-5,6.399999999999982e-5,139680,2985,null,null,null,null,null,null,null],[7.470298442058265e-5,7.599999999999794e-5,166252,3134,null,null,null,null,null,null,null],[7.000300684012473e-5,7.099999999999988e-5,153946,3291,null,null,null,null,null,null,null],[7.332497625611722e-5,7.300000000000015e-5,161342,3456,null,null,null,null,null,null,null],[7.68770114518702e-5,7.700000000000068e-5,169196,3629,null,null,null,null,null,null,null],[8.789999992586672e-5,8.800000000000127e-5,195306,3810,null,null,null,null,null,null,null],[8.4783008787781e-5,8.500000000000174e-5,186656,4001,null,null,null,null,null,null,null],[9.577898890711367e-5,9.500000000000133e-5,211296,4201,null,null,null,null,null,null,null],[9.035100811161101e-5,8.99999999999998e-5,198964,4411,null,null,null,null,null,null,null],[1.0181200923398137e-4,1.010000000000004e-4,225996,4631,null,null,null,null,null,null,null],[9.956801659427583e-5,1.0000000000000113e-4,219136,4863,null,null,null,null,null,null,null],[1.0437800665386021e-4,1.0399999999999993e-4,229882,5106,null,null,null,null,null,null,null],[1.0967502021230757e-4,1.1000000000000072e-4,241698,5361,null,null,null,null,null,null,null],[1.2155799777247012e-4,1.2099999999999958e-4,269352,5629,null,null,null,null,null,null,null],[1.2099900050088763e-4,1.2099999999999958e-4,266588,5911,null,null,null,null,null,null,null],[1.3303197920322418e-4,1.3300000000000117e-4,294804,6207,null,null,null,null,null,null,null],[1.3285200111567974e-4,1.329999999999977e-4,292868,6517,null,null,null,null,null,null,null],[1.3966701226308942e-4,1.389999999999985e-4,307730,6843,null,null,null,null,null,null,null],[1.5285800327546895e-4,1.5399999999999962e-4,338356,7185,null,null,null,null,null,null,null],[1.5347101725637913e-4,1.529999999999969e-4,338348,7544,null,null,null,null,null,null,null],[1.7099297838285565e-4,1.7099999999999754e-4,378212,7921,null,null,null,null,null,null,null],[1.6930900164879858e-4,1.6900000000000248e-4,373386,8318,null,null,null,null,null,null,null],[1.8411502242088318e-4,1.8400000000000014e-4,407206,8733,null,null,null,null,null,null,null],[1.8637199536897242e-4,1.8599999999999867e-4,411072,9170,null,null,null,null,null,null,null],[2.0187799236737192e-4,2.020000000000008e-4,446386,9629,null,null,null,null,null,null,null],[2.1173301502130926e-4,2.1200000000000038e-4,467928,10110,null,null,null,null,null,null,null],[2.1559098968282342e-4,2.160000000000009e-4,475428,10616,null,null,null,null,null,null,null],[2.3239498841576278e-4,2.319999999999961e-4,513402,11146,null,null,null,null,null,null,null],[2.44259019382298e-4,2.4500000000000216e-4,539124,11704,null,null,null,null,null,null,null],[2.492629864718765e-4,2.489999999999992e-4,549330,12289,null,null,null,null,null,null,null],[2.82555993180722e-4,2.82000000000001e-4,624162,12903,null,null,null,null,null,null,null],[2.8090798878110945e-4,2.8100000000000347e-4,620318,13549,null,null,null,null,null,null,null],[2.944830048363656e-4,2.930000000000016e-4,650136,14226,null,null,null,null,null,null,null],[3.088400117121637e-4,3.080000000000027e-4,681592,14937,null,null,null,null,null,null,null],[3.238749923184514e-4,3.2400000000000137e-4,714594,15684,null,null,null,null,null,null,null],[3.3987200004048645e-4,3.4e-4,749894,16469,null,null,null,null,null,null,null],[3.563780046533793e-4,3.559999999999987e-4,786214,17292,null,null,null,null,null,null,null],[4.0503000491298735e-4,4.0699999999999764e-4,895990,18157,null,null,null,null,null,null,null],[4.414169816300273e-4,4.4199999999999795e-4,974388,19065,null,null,null,null,null,null,null],[4.2447098530828953e-4,4.2400000000000423e-4,936334,20018,null,null,null,null,null,null,null],[4.500439972616732e-4,4.51e-4,992578,21019,null,null,null,null,null,null,null],[4.667970060836524e-4,4.6700000000000214e-4,1029200,22070,null,null,null,null,null,null,null],[4.899000050500035e-4,4.889999999999999e-4,1080112,23173,null,null,null,null,null,null,null],[5.225820059422404e-4,5.229999999999992e-4,1152140,24332,null,null,null,null,null,null,null],[5.391960148699582e-4,5.400000000000023e-4,1188648,25549,null,null,null,null,null,null,null],[5.743170040659606e-4,5.740000000000016e-4,1266130,26826,null,null,null,null,null,null,null],[5.809750000480562e-4,5.809999999999982e-4,1280390,28167,null,null,null,null,null,null,null],[6.298729858826846e-4,6.289999999999976e-4,1388260,29576,null,null,null,null,null,null,null],[6.868740019854158e-4,6.869999999999966e-4,1514256,31054,null,null,null,null,null,null,null],[7.230019837152213e-4,7.229999999999945e-4,1594024,32607,null,null,null,null,null,null,null],[7.784049957990646e-4,7.779999999999974e-4,1714886,34238,null,null,null,null,null,null,null],[8.11128003988415e-4,8.109999999999992e-4,1786850,35950,null,null,null,null,null,null,null],[8.511709747835994e-4,8.509999999999976e-4,1875110,37747,null,null,null,null,null,null,null],[8.898660016711801e-4,8.900000000000019e-4,1976686,39634,null,null,null,null,null,null,null],[8.725879888515919e-4,8.719999999999978e-4,1922566,41616,null,null,null,null,null,null,null],[8.982520084828138e-4,8.97999999999996e-4,1978524,43697,null,null,null,null,null,null,null],[9.415860113222152e-4,9.419999999999984e-4,2074326,45882,null,null,null,null,null,null,null],[1.089650992071256e-3,1.0899999999999938e-3,2401026,48176,null,null,null,null,null,null,null],[1.155370002379641e-3,1.1560000000000042e-3,2545742,50585,null,null,null,null,null,null,null],[1.2148630048613995e-3,1.2150000000000077e-3,2675642,53114,null,null,null,null,null,null,null],[1.25666699022986e-3,1.2560000000000002e-3,2767644,55770,null,null,null,null,null,null,null],[1.2689899886026978e-3,1.2689999999999924e-3,2794018,58558,null,null,null,null,null,null,null],[1.4192250091582537e-3,1.4199999999999977e-3,3125966,61486,null,null,null,null,null,null,null],[1.5777479857206345e-3,1.577999999999996e-3,3473718,64561,null,null,null,null,null,null,null],[1.4964360161684453e-3,1.4969999999999983e-3,3294886,67789,null,null,null,null,null,null,null],[1.4829070132691413e-3,1.4830000000000051e-3,3264914,71178,null,null,null,null,null,null,null],[1.5313519979827106e-3,1.5309999999999976e-3,3371910,74737,null,null,null,null,null,null,null],[1.6075279854703695e-3,1.6079999999999983e-3,3539220,78474,null,null,null,null,null,null,null],[1.6870959952939302e-3,1.687000000000008e-3,3714218,82398,null,null,null,null,null,null,null],[1.8756950157694519e-3,1.8759999999999957e-3,4129704,86518,null,null,null,null,null,null,null],[1.919757982250303e-3,1.919999999999998e-3,4226354,90843,null,null,null,null,null,null,null],[1.976150000700727e-3,1.9769999999999996e-3,4349974,95386,null,null,null,null,null,null,null],[2.0716410072054714e-3,2.0709999999999965e-3,4560514,100155,null,null,null,null,null,null,null],[2.1728879946749657e-3,2.1729999999999944e-3,4783340,105163,null,null,null,null,null,null,null],[2.286808012286201e-3,2.2869999999999974e-3,5034188,110421,null,null,null,null,null,null,null],[2.3727250227238983e-3,2.373e-3,5222436,115942,null,null,null,null,null,null,null],[2.495694992830977e-3,2.4949999999999972e-3,5493168,121739,null,null,null,null,null,null,null],[2.7471980138216168e-3,2.7469999999999994e-3,6047056,127826,null,null,null,null,null,null,null],[2.9708640067838132e-3,2.9710000000000014e-3,6539236,134217,null,null,null,null,null,null,null],[3.0153070110827684e-3,3.016000000000005e-3,6636142,140928,null,null,null,null,null,null,null],[3.028059989446774e-3,3.027000000000002e-3,6664360,147975,null,null,null,null,null,null,null],[3.2062279933597893e-3,3.2070000000000015e-3,7056602,155373,null,null,null,null,null,null,null],[3.3923529845196754e-3,3.393000000000007e-3,7465758,163142,null,null,null,null,null,null,null],[3.5456200130283833e-3,3.5460000000000075e-3,7803386,171299,null,null,null,null,null,null,null],[3.8079770165495574e-3,3.808999999999993e-3,8381172,179864,null,null,null,null,null,null,null],[3.976773004978895e-3,3.976999999999994e-3,8751452,188858,null,null,null,null,null,null,null],[4.079878999618813e-3,4.08e-3,8978542,198300,null,null,null,null,null,null,null],[4.3269150191918015e-3,4.3269999999999975e-3,9522152,208215,null,null,null,null,null,null,null],[4.470001003937796e-3,4.470000000000002e-3,9836662,218626,null,null,null,null,null,null,null],[4.872428020462394e-3,4.874000000000003e-3,10722288,229558,null,null,null,null,null,null,null],[4.940767015796155e-3,4.941000000000001e-3,10872264,241036,null,null,null,null,null,null,null],[5.223240004852414e-3,5.224000000000006e-3,11494206,253087,null,null,null,null,null,null,null],[5.434965016320348e-3,5.435000000000009e-3,11959708,265742,null,null,null,null,null,null,null],[5.797476973384619e-3,5.79799999999997e-3,12757506,279029,null,null,null,null,null,null,null],[6.133104005130008e-3,6.1340000000000006e-3,13495790,292980,null,null,null,null,null,null,null],[6.2913899892009795e-3,6.291999999999992e-3,13843824,307629,null,null,null,null,null,null,null],[6.648398994002491e-3,6.648000000000015e-3,14629490,323011,null,null,null,null,null,null,null],[7.0558839943259954e-3,7.055999999999979e-3,15526346,339161,null,null,null,null,null,null,null],[7.4249439931008965e-3,7.424999999999987e-3,16337978,356119,null,null,null,null,null,null,null],[7.7092179853934795e-3,7.709000000000021e-3,16963194,373925,null,null,null,null,null,null,null],[8.290446014143527e-3,8.289999999999992e-3,18241776,392622,null,null,null,null,null,null,null],[8.620255015557632e-3,8.619999999999989e-3,18967682,412253,null,null,null,null,null,null,null],[9.032543981447816e-3,9.033000000000013e-3,19874458,432866,null,null,null,null,null,null,null],[9.349416999612004e-3,9.348999999999968e-3,20571820,454509,null,null,null,null,null,null,null],[9.808922972297296e-3,9.808000000000011e-3,21582660,477234,null,null,null,null,null,null,null],[1.4454930002102628e-2,1.4447999999999989e-2,31815998,501096,null,null,null,null,null,null,null],[1.3374889007536694e-2,1.3374999999999998e-2,29425932,526151,null,null,null,null,null,null,null],[1.1378950002836064e-2,1.1378e-2,25036198,552458,null,null,null,null,null,null,null],[1.2026454991428182e-2,1.2026999999999954e-2,26461024,580081,null,null,null,null,null,null,null],[1.2654685007873923e-2,1.2656e-2,27843028,609086,null,null,null,null,null,null,null],[1.3459802023135126e-2,1.3460000000000027e-2,29614906,639540,null,null,null,null,null,null,null],[1.3948107982287183e-2,1.3949000000000045e-2,30688776,671517,null,null,null,null,null,null,null],[1.4484102983260527e-2,1.4485000000000026e-2,31867994,705093,null,null,null,null,null,null,null],[1.5333485003793612e-2,1.5334000000000014e-2,33736424,740347,null,null,null,null,null,null,null],[1.6279800998745486e-2,1.6279000000000043e-2,35818594,777365,null,null,null,null,null,null,null],[1.6825338010676205e-2,1.6825999999999952e-2,37018508,816233,null,null,null,null,null,null,null],[1.7766479984857142e-2,1.7766999999999977e-2,39089300,857045,null,null,null,null,null,null,null],[1.9011694006621838e-2,1.899799999999996e-2,41829334,899897,null,null,null,null,null,null,null],[1.9658203003928065e-2,1.9659000000000038e-2,43250748,944892,null,null,null,null,null,null,null],[2.077190301497467e-2,2.0770999999999984e-2,45700954,992136,null,null,null,null,null,null,null],[2.1526272990740836e-2,2.152599999999999e-2,47360568,1041743,null,null,null,null,null,null,null],[2.2623244993155822e-2,2.261799999999997e-2,49774154,1093831,null,null,null,null,null,null,null],[3.0359007010702044e-2,3.03520000000001e-2,66795244,1148522,null,null,null,null,null,null,null],[2.5625045003835112e-2,2.5626000000000038e-2,56378776,1205948,null,null,null,null,null,null,null],[2.6170302007813007e-2,2.6164999999999994e-2,57577900,1266246,null,null,null,null,null,null,null],[2.7586374984821305e-2,2.7567000000000008e-2,60693648,1329558,null,null,null,null,null,null,null],[2.9113661992596462e-2,2.9113999999999862e-2,64053750,1396036,null,null,null,null,null,null,null],[3.726070001721382e-2,3.7235999999999936e-2,81980104,1465838,null,null,null,null,null,null,null],[3.196953600854613e-2,3.1969000000000025e-2,70336336,1539130,null,null,null,null,null,null,null],[3.3439661987358704e-2,3.3440000000000025e-2,73569820,1616086,null,null,null,null,null,null,null],[4.189192899502814e-2,4.1834999999999845e-2,92168110,1696890,null,null,null,null,null,null,null],[3.732375398976728e-2,3.732399999999991e-2,82115028,1781735,null,null,null,null,null,null,null],[4.544095299206674e-2,4.5420000000000016e-2,99976162,1870822,null,null,null,null,null,null,null],[4.053783800918609e-2,4.0537000000000045e-2,89185944,1964363,null,null,null,null,null,null,null],[4.283254500478506e-2,4.2825e-2,94234986,2062581,null,null,null,null,null,null,null],[5.1143154996680096e-2,5.1068e-2,112521528,2165710,null,null,null,null,null,null,null],[4.755784600274637e-2,4.755800000000021e-2,104629812,2273996,null,null,null,null,null,null,null],[6.301521099521779e-2,6.298800000000027e-2,138641518,2387695,null,null,null,null,null,null,null],[5.287269200198352e-2,5.287300000000017e-2,116322382,2507080,null,null,null,null,null,null,null],[6.673756099189632e-2,6.672800000000012e-2,146835154,2632434,null,null,null,null,null,null,null],[5.9425461979117244e-2,5.942599999999998e-2,130736546,2764056,null,null,null,null,null,null,null],[6.1144414998125285e-2,6.1146000000000145e-2,134521030,2902259,null,null,null,null,null,null,null],[7.016911800019443e-2,7.013800000000026e-2,154379522,3047372,null,null,null,null,null,null,null],[7.348234299570322e-2,7.343800000000034e-2,161669210,3199740,null,null,null,null,null,null,null],[7.894127900362946e-2,7.891399999999993e-2,173681688,3359727,null,null,null,null,null,null,null],[8.066519201383926e-2,8.066199999999979e-2,177468588,3527714,null,null,null,null,null,null,null],[8.884616900468245e-2,8.877899999999994e-2,195467954,3704100,null,null,null,null,null,null,null],[9.39299640012905e-2,9.388999999999981e-2,206653246,3889305,null,null,null,null,null,null,null],[0.10612100997241214,0.10600399999999977,233471288,4083770,null,null,null,null,null,null,null],[0.10183990598306991,0.10175899999999993,224053108,4287958,null,null,null,null,null,null,null],[0.12609586198232137,0.12599300000000024,277420728,4502356,null,null,null,null,null,null,null],[0.10524546899250709,0.10519399999999957,231546430,4727474,null,null,null,null,null,null,null],[0.12472607701784,0.12464599999999981,274402494,4963848,null,null,null,null,null,null,null],[0.12209953300771303,0.12206000000000028,268624580,5212040,null,null,null,null,null,null,null],[0.12803200600319542,0.12799800000000072,281679486,5472642,null,null,null,null,null,null,null],[0.15328322601271793,0.15318900000000024,337230312,5746274,null,null,null,null,null,null,null],[0.14087599600316025,0.14085499999999973,309934058,6033588,null,null,null,null,null,null,null],[0.16443824200541712,0.16430899999999982,361779142,6335268,null,null,null,null,null,null,null],[0.1509496500075329,0.15083299999999955,332103010,6652031,null,null,null,null,null,null,null],[0.15568390398402698,0.15551799999999982,342513570,6984633,null,null,null,null,null,null,null],[0.18309666001005098,0.18303699999999967,402818630,7333864,null,null,null,null,null,null,null],[0.20358702598605305,0.20342700000000002,447898432,7700558,null,null,null,null,null,null,null],[0.18658072702237405,0.18645500000000004,410484044,8085585,null,null,null,null,null,null,null],[0.2140501549874898,0.21389099999999983,470920822,8489865,null,null,null,null,null,null,null],[0.22377065499313176,0.22362600000000032,492300598,8914358,null,null,null,null,null,null,null],[0.23815473800641485,0.23797100000000082,523946830,9360076,null,null,null,null,null,null,null],[0.24803585300105624,0.24782299999999946,545691436,9828080,null,null,null,null,null,null,null]]},{"reportAnalysis":{"anMean":{"estUpperBound":3.8862828356384757e-7,"estLowerBound":3.640686812141915e-7,"estPoint":3.7647973827317373e-7,"estConfidenceLevel":0.95},"anRegress":[{"regRSquare":{"estUpperBound":0.9947907586534039,"estLowerBound":0.9882157738679797,"estPoint":0.9918810346067727,"estConfidenceLevel":0.95},"regResponder":"time","regCoeffs":{"y":{"estUpperBound":2.1544673115009752e-4,"estLowerBound":-3.722560375174092e-4,"estPoint":-6.581833358806193e-5,"estConfidenceLevel":0.95},"iters":{"estUpperBound":3.803164118615079e-7,"estLowerBound":3.59832105979452e-7,"estPoint":3.6979215726516167e-7,"estConfidenceLevel":0.95}}}],"anStdDev":{"estUpperBound":4.81505001531474e-8,"estLowerBound":3.5904833037515274e-8,"estPoint":4.150785932735141e-8,"estConfidenceLevel":0.95},"anOutlierVar":{"ovFraction":0.917699613099007,"ovDesc":"severe","ovEffect":"Severe"},"anOverhead":3.161534180001628e-6},"reportKDEs":[{"kdeValues":[2.9454013709295896e-7,2.9586601888556503e-7,2.9719190067817115e-7,2.985177824707772e-7,2.9984366426338333e-7,3.011695460559894e-7,3.0249542784859546e-7,3.0382130964120157e-7,3.0514719143380764e-7,3.0647307322641375e-7,3.077989550190198e-7,3.091248368116259e-7,3.10450718604232e-7,3.1177660039683806e-7,3.1310248218944413e-7,3.1442836398205025e-7,3.157542457746563e-7,3.1708012756726243e-7,3.184060093598685e-7,3.1973189115247456e-7,3.2105777294508067e-7,3.2238365473768674e-7,3.2370953653029285e-7,3.250354183228989e-7,3.26361300115505e-7,3.276871819081111e-7,3.2901306370071716e-7,3.303389454933233e-7,3.3166482728592935e-7,3.329907090785354e-7,3.3431659087114153e-7,3.356424726637476e-7,3.369683544563537e-7,3.3829423624895977e-7,3.3962011804156584e-7,3.4094599983417195e-7,3.42271881626778e-7,3.4359776341938414e-7,3.449236452119902e-7,3.4624952700459626e-7,3.475754087972024e-7,3.4890129058980845e-7,3.5022717238241456e-7,3.5155305417502063e-7,3.528789359676267e-7,3.542048177602328e-7,3.5553069955283887e-7,3.56856581345445e-7,3.5818246313805105e-7,3.595083449306571e-7,3.6083422672326324e-7,3.621601085158693e-7,3.634859903084754e-7,3.648118721010815e-7,3.6613775389368755e-7,3.6746363568629366e-7,3.6878951747889973e-7,3.7011539927150584e-7,3.714412810641119e-7,3.7276716285671797e-7,3.740930446493241e-7,3.7541892644193015e-7,3.7674480823453627e-7,3.7807069002714234e-7,3.793965718197484e-7,3.807224536123545e-7,3.820483354049606e-7,3.833742171975667e-7,3.8470009899017276e-7,3.8602598078277883e-7,3.873518625753849e-7,3.88677744367991e-7,3.900036261605971e-7,3.913295079532032e-7,3.9265538974580925e-7,3.939812715384153e-7,3.9530715333102144e-7,3.9663303512362755e-7,3.979589169162336e-7,3.992847987088397e-7,4.0061068050144575e-7,4.0193656229405186e-7,4.0326244408665793e-7,4.0458832587926404e-7,4.059142076718701e-7,4.0724008946447617e-7,4.085659712570823e-7,4.0989185304968835e-7,4.1121773484229447e-7,4.1254361663490054e-7,4.138694984275066e-7,4.151953802201127e-7,4.1652126201271883e-7,4.178471438053249e-7,4.1917302559793096e-7,4.2049890739053703e-7,4.2182478918314314e-7,4.2315067097574926e-7,4.244765527683553e-7,4.258024345609614e-7,4.2712831635356745e-7,4.2845419814617357e-7,4.2978007993877964e-7,4.3110596173138575e-7,4.324318435239918e-7,4.337577253165979e-7,4.35083607109204e-7,4.3640948890181006e-7,4.377353706944162e-7,4.3906125248702224e-7,4.403871342796283e-7,4.417130160722344e-7,4.430388978648405e-7,4.443647796574466e-7,4.4569066145005267e-7,4.4701654324265873e-7,4.4834242503526485e-7,4.496683068278709e-7,4.5099418862047703e-7,4.523200704130831e-7,4.5364595220568916e-7,4.549718339982952e-7,4.5629771579090134e-7,4.5762359758350746e-7,4.589494793761135e-7,4.602753611687196e-7,4.6160124296132565e-7,4.6292712475393177e-7],"kdeType":"time","kdePDF":[5530282.79787247,5531627.570567824,5534313.856943901,5538335.146921076,5543681.695225951,5550340.545128092,5558295.559958689,5567527.462300351,5578013.880710751,5589729.403817111,5602645.64159373,5616731.293610986,5631952.224021834,5648271.543030547,5665649.6945689395,5684044.549887086,5703411.5067493785,5723703.593912107,5744871.580546299,5766864.090258815,5789627.719356318,5813107.158990226,5837245.320816616,5861983.465802875,5887261.33581322,5913017.28760732,5939188.428890887,5965710.7560635675,5992519.293318077,6019548.232754992,6046731.075189981,6074000.771344183,6101289.863124023,6128530.624713533,6155655.203220348,6182595.75863547,6209284.602886581,6235654.337784862,6261637.991685717,6287169.154704143,6312182.112345636,6336611.977433017,6360394.820228376,6383467.796666892,6405769.274635612,6427238.95824502,6447818.010054028,6467449.171219864,6486076.87955295,6503647.38546292,6520108.865785552,6535411.535481214,6549507.757193478,6562352.148651839,6573901.687894676,6584115.816278271,6592956.539224207,6600388.524641618,6606379.1989420485,6610898.840543817,6613920.6707395995,6615420.9417758295,6615379.021965917,6613777.477631168,6610602.151634376,6605842.238241498,6599490.354017121,6591542.604429947,6581998.645815822,6570861.742318254,6558138.817400361,6543840.499498445,6527981.161365914,6510578.952638195,6491655.8251342,6471237.550399075,6449353.728986118,6426037.790973625,6401326.98721521,6375262.370830091,6347888.768453294,6319254.740784746,6289412.532000962,6258418.007623806,6226330.580477014,6193213.124403678,6159131.875465549,6124156.32039861,6088359.072157964,6051815.732448713,6014604.741207736,5976807.213073708,5938506.760958669,5899789.306913838,5860742.880564037,5821457.40546895,5782024.473854384,5742537.110242375,5703089.524594396,5663776.855666542,5624694.905358429,5585939.8649180895,5547608.03394246,5509795.53318646,5472598.012262378,5436110.353374675,5400426.3722926285,5365638.517813899,5331837.571015424,5299112.3456237465,5267549.390864068,5237232.698166044,5208243.413113945,5180659.55402919,5154555.738564125,5130002.919667374,5107068.132252829,5085814.251866729,5066299.766600234,5048578.563438857,5032699.730175207,5018707.373938342,5006640.457311918,4996532.652924924,4988412.2173037175,4982301.884672987,4978218.781286921,4976174.360761089]}],"reportKeys":["time","cpuTime","cycles","iters","allocated","numGcs","bytesCopied","mutatorWallSeconds","mutatorCpuSeconds","gcWallSeconds","gcCpuSeconds"],"reportNumber":1,"reportName":"fib/5","reportOutliers":{"highSevere":0,"highMild":0,"lowMild":0,"samplesSeen":41,"lowSevere":0},"reportMeasured":[[6.3689949456602335e-6,4.999999999810711e-6,5118,1,null,null,null,null,null,null,null],[2.195010893046856e-6,2.9999999995311555e-6,4562,2,null,null,null,null,null,null,null],[2.315995516255498e-6,2.000000000279556e-6,4954,3,null,null,null,null,null,null,null],[2.7059868443757296e-6,2.000000000279556e-6,5880,4,null,null,null,null,null,null,null],[2.815009793266654e-6,2.9999999995311555e-6,6058,5,null,null,null,null,null,null,null],[3.1939998734742403e-6,3.000000000419334e-6,6908,6,null,null,null,null,null,null,null],[3.410998033359647e-6,2.9999999995311555e-6,7406,7,null,null,null,null,null,null,null],[3.9000005926936865e-6,4.000000000559112e-6,8644,8,null,null,null,null,null,null,null],[4.108005668967962e-6,3.9999999996709334e-6,8862,9,null,null,null,null,null,null,null],[4.387024091556668e-6,4.999999999810711e-6,9552,10,null,null,null,null,null,null,null],[4.6800123527646065e-6,4.999999999810711e-6,10282,11,null,null,null,null,null,null,null],[4.945992259308696e-6,4.999999999810711e-6,10844,12,null,null,null,null,null,null,null],[5.252019036561251e-6,5.999999999062311e-6,11528,13,null,null,null,null,null,null,null],[5.651992978528142e-6,6.000000000838668e-6,12330,14,null,null,null,null,null,null,null],[5.803012754768133e-6,6.000000000838668e-6,12848,15,null,null,null,null,null,null,null],[6.2800245359539986e-6,5.999999999950489e-6,13764,16,null,null,null,null,null,null,null],[6.430986104533076e-6,6.999999999202089e-6,14066,17,null,null,null,null,null,null,null],[6.895978003740311e-6,7.000000000090267e-6,15020,18,null,null,null,null,null,null,null],[7.040012860670686e-6,7.000000000090267e-6,15400,19,null,null,null,null,null,null,null],[7.291993824765086e-6,7.000000000978446e-6,16156,20,null,null,null,null,null,null,null],[7.642986020073295e-6,7.000000000978446e-6,16806,21,null,null,null,null,null,null,null],[7.983006071299314e-6,8.000000000230045e-6,17478,22,null,null,null,null,null,null,null],[8.310016710311174e-6,8.000000001118224e-6,18172,23,null,null,null,null,null,null,null],[9.011011570692062e-6,8.999999999481645e-6,19702,25,null,null,null,null,null,null,null],[9.112991392612457e-6,9.000000000369823e-6,20052,26,null,null,null,null,null,null,null],[9.556999430060387e-6,1.000000000139778e-5,20914,27,null,null,null,null,null,null,null],[9.766023140400648e-6,9.000000000369823e-6,21306,28,null,null,null,null,null,null,null],[1.0325980838388205e-5,1.0000000000509601e-5,22790,30,null,null,null,null,null,null,null],[1.0646996088325977e-5,1.100000000064938e-5,23420,31,null,null,null,null,null,null,null],[1.1280004400759935e-5,1.09999999997612e-5,24804,33,null,null,null,null,null,null,null],[1.1775991879403591e-5,1.100000000064938e-5,26022,35,null,null,null,null,null,null,null],[1.2259988579899073e-5,1.2000000000789157e-5,26904,36,null,null,null,null,null,null,null],[1.2822012649849057e-5,1.3000000000928935e-5,28158,38,null,null,null,null,null,null,null],[1.3329990906640887e-5,1.3000000000928935e-5,29300,40,null,null,null,null,null,null,null],[1.3923970982432365e-5,1.4000000000180535e-5,30616,42,null,null,null,null,null,null,null],[1.45800004247576e-5,1.5000000000320313e-5,32086,44,null,null,null,null,null,null,null],[1.5372002962976694e-5,1.5000000000320313e-5,33826,47,null,null,null,null,null,null,null],[1.6106991097331047e-5,1.5999999999571912e-5,35566,49,null,null,null,null,null,null,null],[1.7026002751663327e-5,1.700000000059987e-5,37452,52,null,null,null,null,null,null,null],[1.7587997717782855e-5,1.700000000059987e-5,38766,54,null,null,null,null,null,null,null],[1.8515012925490737e-5,1.7999999999851468e-5,40918,57,null,null,null,null,null,null,null],[1.9400002202019095e-5,1.9999999999242846e-5,42726,60,null,null,null,null,null,null,null],[2.024698187597096e-5,2.1000000000270802e-5,44548,63,null,null,null,null,null,null,null],[2.1146988729014993e-5,2.19999999995224e-5,46470,66,null,null,null,null,null,null,null],[2.213899279013276e-5,2.200000000129876e-5,48666,69,null,null,null,null,null,null,null],[2.3361993953585625e-5,2.3999999999801958e-5,51572,73,null,null,null,null,null,null,null],[2.4236011086031795e-5,2.5000000000829914e-5,53334,76,null,null,null,null,null,null,null],[3.775898949243128e-5,3.7999999999094314e-5,85106,80,null,null,null,null,null,null,null],[2.6788009563460946e-5,2.700000000022129e-5,58730,84,null,null,null,null,null,null,null],[2.8058013413101435e-5,2.7999999998584713e-5,61706,89,null,null,null,null,null,null,null],[2.925400622189045e-5,2.9000000000500847e-5,64460,93,null,null,null,null,null,null,null],[3.086499054916203e-5,2.9999999999752447e-5,67964,98,null,null,null,null,null,null,null],[3.23129934258759e-5,3.300000000017178e-5,71208,103,null,null,null,null,null,null,null],[3.3881020499393344e-5,3.400000000031156e-5,74558,108,null,null,null,null,null,null,null],[3.8439000491052866e-5,3.7999999999094314e-5,85440,113,null,null,null,null,null,null,null],[3.7393998354673386e-5,3.799999999998249e-5,82384,119,null,null,null,null,null,null,null],[4.6891014790162444e-5,4.7000000000352316e-5,103600,125,null,null,null,null,null,null,null],[7.765999180264771e-5,7.399999999968543e-5,182542,131,null,null,null,null,null,null,null],[4.910500138066709e-5,4.900000000063187e-5,107362,138,null,null,null,null,null,null,null],[4.986301064491272e-5,4.999999999988347e-5,109630,144,null,null,null,null,null,null,null],[1.7505697906017303e-4,1.760000000006201e-4,404307,152,null,null,null,null,null,null,null],[1.4888800797052681e-4,1.4800000000025904e-4,326376,159,null,null,null,null,null,null,null],[1.554769987706095e-4,1.550000000003493e-4,341968,167,null,null,null,null,null,null,null],[1.6353401588276029e-4,1.6300000000057935e-4,360360,176,null,null,null,null,null,null,null],[1.7213099636137486e-4,1.72000000000061e-4,379104,185,null,null,null,null,null,null,null],[1.7929900786839426e-4,1.7900000000103944e-4,394680,194,null,null,null,null,null,null,null],[1.8859998090192676e-4,1.8900000000066086e-4,415088,204,null,null,null,null,null,null,null],[2.2280000848695636e-4,2.2199999999994446e-4,496200,214,null,null,null,null,null,null,null],[2.0609100465662777e-4,2.0599999999948437e-4,453848,224,null,null,null,null,null,null,null],[2.1693098824471235e-4,2.1699999999924557e-4,477056,236,null,null,null,null,null,null,null],[2.2712702048011124e-4,2.2699999999975518e-4,500136,247,null,null,null,null,null,null,null],[2.3897801293060184e-4,2.3999999999890775e-4,526520,260,null,null,null,null,null,null,null],[2.5460097822360694e-4,2.5500000000011624e-4,561624,273,null,null,null,null,null,null,null],[2.0890400628559291e-4,2.0900000000079189e-4,463179,287,null,null,null,null,null,null,null],[2.0243300241418183e-4,2.0199999999981344e-4,445642,301,null,null,null,null,null,null,null],[2.121889847330749e-4,2.1200000000032304e-4,467333,316,null,null,null,null,null,null,null],[2.2302701836451888e-4,2.2300000000008424e-4,491113,332,null,null,null,null,null,null,null],[2.3343501379713416e-4,2.3299999999970566e-4,514013,348,null,null,null,null,null,null,null],[2.6055998750962317e-4,2.5999999999992696e-4,577594,366,null,null,null,null,null,null,null],[2.5778301642276347e-4,2.579999999987592e-4,568035,384,null,null,null,null,null,null,null],[2.698470198083669e-4,2.699999999995484e-4,594402,403,null,null,null,null,null,null,null],[2.981330035254359e-4,2.9799999999990945e-4,660166,424,null,null,null,null,null,null,null],[2.9759801691398025e-4,2.9799999999990945e-4,655610,445,null,null,null,null,null,null,null],[3.1254399800673127e-4,3.119999999992018e-4,687896,467,null,null,null,null,null,null,null],[3.421930014155805e-4,3.4199999999984243e-4,757280,490,null,null,null,null,null,null,null],[3.441110020503402e-4,3.4500000000026176e-4,758779,515,null,null,null,null,null,null,null],[3.618090122472495e-4,3.6100000000072185e-4,812698,541,null,null,null,null,null,null,null],[3.2865701359696686e-4,3.289999999989135e-4,724444,568,null,null,null,null,null,null,null],[3.142349887639284e-4,3.1400000000036954e-4,692452,596,null,null,null,null,null,null,null],[3.4050201065838337e-4,3.4000000000133923e-4,752628,626,null,null,null,null,null,null,null],[3.458599967416376e-4,3.4600000000040154e-4,762084,657,null,null,null,null,null,null,null],[3.742059925571084e-4,3.7399999999987443e-4,826628,690,null,null,null,null,null,null,null],[3.813380026258528e-4,3.809999999999647e-4,840620,725,null,null,null,null,null,null,null],[4.1083700489252806e-4,4.110000000006053e-4,907316,761,null,null,null,null,null,null,null],[4.203400167170912e-4,4.2100000000022675e-4,926228,799,null,null,null,null,null,null,null],[4.6467300853691995e-4,4.660000000002995e-4,1028484,839,null,null,null,null,null,null,null],[4.632420022971928e-4,4.629999999998802e-4,1020872,881,null,null,null,null,null,null,null],[4.6159399789758027e-4,4.609999999996006e-4,1019450,925,null,null,null,null,null,null,null],[4.5108600170351565e-4,4.50999999999091e-4,995256,972,null,null,null,null,null,null,null],[4.6271400060504675e-4,4.629999999998802e-4,1019532,1020,null,null,null,null,null,null,null],[4.946360131725669e-4,4.940000000006606e-4,1091864,1071,null,null,null,null,null,null,null],[5.189549992792308e-4,5.189999999997141e-4,1144964,1125,null,null,null,null,null,null,null],[4.7801301116123796e-4,4.770000000000607e-4,1053288,1181,null,null,null,null,null,null,null],[4.250619967933744e-4,4.249999999998977e-4,937190,1240,null,null,null,null,null,null,null],[3.9984099566936493e-4,3.9999999999995595e-4,881704,1302,null,null,null,null,null,null,null],[4.1914102621376514e-4,4.18999999999059e-4,924266,1367,null,null,null,null,null,null,null],[4.39752999227494e-4,4.40000000000218e-4,969548,1436,null,null,null,null,null,null,null],[4.6121698687784374e-4,4.610000000004888e-4,1016798,1507,null,null,null,null,null,null,null],[4.838879976887256e-4,4.839999999992628e-4,1066732,1583,null,null,null,null,null,null,null],[5.075119843240827e-4,5.079999999990648e-4,1118646,1662,null,null,null,null,null,null,null],[5.32345991814509e-4,5.310000000005033e-4,1173464,1745,null,null,null,null,null,null,null],[5.587530031334609e-4,5.589999999999762e-4,1232000,1832,null,null,null,null,null,null,null],[5.909939936827868e-4,5.9099999999912e-4,1302372,1924,null,null,null,null,null,null,null],[6.154190050438046e-4,6.159999999999499e-4,1356354,2020,null,null,null,null,null,null,null],[6.507150246761739e-4,6.509999999995131e-4,1433628,2121,null,null,null,null,null,null,null],[7.044719823170453e-4,7.039999999998159e-4,1553214,2227,null,null,null,null,null,null,null],[7.164400012698025e-4,7.159999999997169e-4,1578436,2339,null,null,null,null,null,null,null],[7.520189974457026e-4,7.52000000000308e-4,1656730,2456,null,null,null,null,null,null,null],[7.830010144971311e-4,7.830000000002002e-4,1725056,2579,null,null,null,null,null,null,null],[8.44385998789221e-4,8.449999999990965e-4,1860492,2708,null,null,null,null,null,null,null],[9.220920037478209e-4,9.209999999999496e-4,2032332,2843,null,null,null,null,null,null,null],[1.001694006845355e-3,1.0009999999995856e-3,2207206,2985,null,null,null,null,null,null,null],[1.0566590062808245e-3,1.0570000000003077e-3,2327146,3134,null,null,null,null,null,null,null],[1.1031169851776212e-3,1.1030000000005202e-3,2429542,3291,null,null,null,null,null,null,null],[1.1072819761466235e-3,1.108000000000331e-3,2438996,3456,null,null,null,null,null,null,null],[1.1441060050856322e-3,1.1450000000001737e-3,2519502,3629,null,null,null,null,null,null,null],[2.4604839854873717e-3,2.431000000000516e-3,5432386,3810,null,null,null,null,null,null,null],[2.3727179795969278e-3,2.3719999999993746e-3,5223568,4001,null,null,null,null,null,null,null],[2.2258640092331916e-3,2.227000000000423e-3,4901340,4201,null,null,null,null,null,null,null],[2.14928001514636e-3,2.1500000000003183e-3,4732212,4411,null,null,null,null,null,null,null],[2.1714959875680506e-3,2.1589999999998e-3,4788574,4631,null,null,null,null,null,null,null],[1.9050459959544241e-3,1.9059999999999633e-3,4193858,4863,null,null,null,null,null,null,null],[1.6448509995825589e-3,1.6439999999997568e-3,3620986,5106,null,null,null,null,null,null,null],[1.681102003203705e-3,1.6809999999995995e-3,3701036,5361,null,null,null,null,null,null,null],[1.7672579851932824e-3,1.7680000000002138e-3,3890840,5629,null,null,null,null,null,null,null],[1.8800500256475061e-3,1.8799999999998818e-3,4138754,5911,null,null,null,null,null,null,null],[1.9469289982225746e-3,1.946999999999477e-3,4286054,6207,null,null,null,null,null,null,null],[2.046756009804085e-3,2.0459999999999923e-3,4505718,6517,null,null,null,null,null,null,null],[2.135255024768412e-3,2.1339999999998582e-3,4700226,6843,null,null,null,null,null,null,null],[2.2248120221775025e-3,2.2240000000000038e-3,4897478,7185,null,null,null,null,null,null,null],[2.3560289992019534e-3,2.350999999999992e-3,5190712,7544,null,null,null,null,null,null,null],[2.4483460001647472e-3,2.4479999999993396e-3,5389322,7921,null,null,null,null,null,null,null],[2.567640010965988e-3,2.566999999999986e-3,5651898,8318,null,null,null,null,null,null,null],[2.706719998968765e-3,2.7060000000007634e-3,5957824,8733,null,null,null,null,null,null,null],[2.855366008589044e-3,2.8519999999989665e-3,6285228,9170,null,null,null,null,null,null,null],[2.9326770163606852e-3,2.9320000000003787e-3,6454914,9629,null,null,null,null,null,null,null],[3.124053997453302e-3,3.1249999999998224e-3,6876206,10110,null,null,null,null,null,null,null],[3.2666409970261157e-3,3.26300000000046e-3,7189740,10616,null,null,null,null,null,null,null],[3.391978010768071e-3,3.3919999999998396e-3,7464764,11146,null,null,null,null,null,null,null],[3.592653985833749e-3,3.5929999999995132e-3,7906906,11704,null,null,null,null,null,null,null],[3.7787689943797886e-3,3.778000000000503e-3,8316456,12289,null,null,null,null,null,null,null],[3.925159020582214e-3,3.924999999999734e-3,8637816,12903,null,null,null,null,null,null,null],[4.118347977055237e-3,4.118999999999318e-3,9063018,13549,null,null,null,null,null,null,null],[4.509021004196256e-3,4.50900000000054e-3,9923458,14226,null,null,null,null,null,null,null],[4.594772995915264e-3,4.595000000000127e-3,10111498,14937,null,null,null,null,null,null,null],[4.79835900478065e-3,4.79900000000022e-3,10559422,15684,null,null,null,null,null,null,null],[5.006429011700675e-3,5.006999999999984e-3,11017090,16469,null,null,null,null,null,null,null],[5.4624910117127e-3,5.463000000000662e-3,12021000,17292,null,null,null,null,null,null,null],[5.522830004338175e-3,5.522000000000027e-3,12152918,18157,null,null,null,null,null,null,null],[5.868509993888438e-3,5.86799999999954e-3,12913532,19065,null,null,null,null,null,null,null],[6.239559996174648e-3,6.240999999999275e-3,13729958,20018,null,null,null,null,null,null,null],[6.510671984869987e-3,6.511000000001488e-3,14326438,21019,null,null,null,null,null,null,null],[6.7655949969775975e-3,6.746999999998948e-3,14887816,22070,null,null,null,null,null,null,null],[1.0109009017469361e-2,1.0075999999999752e-2,22259863,23173,null,null,null,null,null,null,null],[1.1043214006349444e-2,1.1044000000000054e-2,24294013,24332,null,null,null,null,null,null,null],[1.2775884009897709e-2,1.2745999999999924e-2,28121738,25549,null,null,null,null,null,null,null],[1.0466584993992e-2,1.0438999999999865e-2,23030743,26826,null,null,null,null,null,null,null],[8.821894996799529e-3,8.82200000000033e-3,19410134,28167,null,null,null,null,null,null,null],[9.05839999904856e-3,9.058000000001343e-3,19931424,29576,null,null,null,null,null,null,null],[9.607458981918171e-3,9.608999999999313e-3,21139722,31054,null,null,null,null,null,null,null],[9.998121997341514e-3,9.997999999999507e-3,21998966,32607,null,null,null,null,null,null,null],[1.0649275995092466e-2,1.0650000000000048e-2,23431704,34238,null,null,null,null,null,null,null],[1.1351645982358605e-2,1.1351999999998696e-2,24976566,35950,null,null,null,null,null,null,null],[1.1748192977393046e-2,1.1749999999999261e-2,25849330,37747,null,null,null,null,null,null,null],[1.6361854010028765e-2,1.6332999999999487e-2,36011226,39634,null,null,null,null,null,null,null],[1.6450644005089998e-2,1.6443999999999903e-2,36194242,41616,null,null,null,null,null,null,null],[1.3593344017863274e-2,1.3594000000001216e-2,29909028,43697,null,null,null,null,null,null,null],[1.4143528998829424e-2,1.4113999999999294e-2,31119100,45882,null,null,null,null,null,null,null],[2.1857529995031655e-2,2.181999999999995e-2,48101196,48176,null,null,null,null,null,null,null],[1.6666358016664162e-2,1.6666000000000736e-2,36666800,50585,null,null,null,null,null,null,null],[1.6369702003430575e-2,1.6370000000000218e-2,36016148,53114,null,null,null,null,null,null,null],[1.7189422011142597e-2,1.719000000000115e-2,37820368,55770,null,null,null,null,null,null,null],[2.0977567008230835e-2,2.0973999999998938e-2,46168823,58558,null,null,null,null,null,null,null],[2.280742398579605e-2,2.2807000000000244e-2,50175534,61486,null,null,null,null,null,null,null],[2.6561063015833497e-2,2.6531000000000304e-2,58442066,64561,null,null,null,null,null,null,null],[2.0786434004548937e-2,2.078600000000108e-2,45732858,67789,null,null,null,null,null,null,null],[2.2607160004554316e-2,2.2606999999998934e-2,49739118,71178,null,null,null,null,null,null,null],[2.336564500001259e-2,2.3365999999999332e-2,51407526,74737,null,null,null,null,null,null,null],[2.4193908990127966e-2,2.4194999999998856e-2,53229650,78474,null,null,null,null,null,null,null],[3.541715198662132e-2,3.5367000000000814e-2,77930312,82398,null,null,null,null,null,null,null],[2.9687178001040593e-2,2.9654999999999987e-2,65318758,86518,null,null,null,null,null,null,null],[3.573231800692156e-2,3.5645999999999844e-2,78617846,90843,null,null,null,null,null,null,null],[2.9777010990073904e-2,2.9748999999998915e-2,65513348,95386,null,null,null,null,null,null,null],[3.896774398162961e-2,3.893199999999908e-2,85736820,100155,null,null,null,null,null,null,null],[4.55451890011318e-2,4.551700000000025e-2,100204946,105163,null,null,null,null,null,null,null],[3.915400800178759e-2,3.91269999999988e-2,86150618,110421,null,null,null,null,null,null,null],[3.71866789937485e-2,3.7173999999998486e-2,81811878,115942,null,null,null,null,null,null,null],[3.7619426992023364e-2,3.76189999999994e-2,82765836,121739,null,null,null,null,null,null,null],[4.603989899624139e-2,4.599900000000012e-2,101293428,127826,null,null,null,null,null,null,null],[5.9948230016743764e-2,5.9899999999998954e-2,131891262,134217,null,null,null,null,null,null,null],[4.348806999041699e-2,4.3489000000001e-2,95676348,140928,null,null,null,null,null,null,null],[6.642680001095869e-2,6.633599999999973e-2,146145502,147975,null,null,null,null,null,null,null],[4.823095098254271e-2,4.823099999999947e-2,106110788,155373,null,null,null,null,null,null,null],[6.95042010047473e-2,6.944900000000054e-2,152915870,163142,null,null,null,null,null,null,null],[6.719720401451923e-2,6.715100000000085e-2,147839372,171299,null,null,null,null,null,null,null],[6.829725802526809e-2,6.825900000000118e-2,150264508,179864,null,null,null,null,null,null,null],[5.856280602165498e-2,5.856300000000125e-2,128839958,188858,null,null,null,null,null,null,null],[8.231437799986452e-2,8.224300000000007e-2,181098420,198300,null,null,null,null,null,null,null],[9.07866460038349e-2,9.072600000000008e-2,199737670,208215,null,null,null,null,null,null,null],[8.800584901473485e-2,8.791100000000007e-2,193619266,218626,null,null,null,null,null,null,null],[9.816788000171073e-2,9.807200000000016e-2,215981134,229558,null,null,null,null,null,null,null],[8.16791650140658e-2,8.161899999999811e-2,179699402,241036,null,null,null,null,null,null,null],[9.940655599348247e-2,9.933800000000126e-2,218718298,253087,null,null,null,null,null,null,null],[0.11120138401747681,0.11112700000000153,244654144,265742,null,null,null,null,null,null,null],[9.786622298997827e-2,9.785500000000091e-2,215306887,279029,null,null,null,null,null,null,null],[0.11794480800745077,0.11783100000000069,259484402,292980,null,null,null,null,null,null,null],[0.10283540200907737,0.1027769999999979,226244166,307629,null,null,null,null,null,null,null],[0.11402164501487277,0.11388900000000035,250853314,323011,null,null,null,null,null,null,null],[0.13191826498950832,0.1318179999999991,290228042,339161,null,null,null,null,null,null,null],[0.14718902899767272,0.14705699999999844,323822326,356119,null,null,null,null,null,null,null],[0.11646585201378912,0.11646599999999907,256227484,373925,null,null,null,null,null,null,null],[0.130337740003597,0.13032800000000044,286750526,392622,null,null,null,null,null,null,null],[0.14089532700018026,0.14082400000000028,309976950,412253,null,null,null,null,null,null,null],[0.15498050500173122,0.15486699999999942,340962370,432866,null,null,null,null,null,null,null],[0.18791693201637827,0.18770999999999916,413426726,454509,null,null,null,null,null,null,null],[0.17427672201301903,0.17420499999999883,383416370,477234,null,null,null,null,null,null,null],[0.19600536601501517,0.19590900000000033,431217902,501096,null,null,null,null,null,null,null],[0.19916906699654646,0.1989959999999975,438191168,526151,null,null,null,null,null,null,null],[0.21339729498140514,0.21320400000000106,469476594,552458,null,null,null,null,null,null,null],[0.21181727599469014,0.21171000000000006,466004624,580081,null,null,null,null,null,null,null],[0.21616315699066035,0.21574699999999858,475566004,609086,null,null,null,null,null,null,null],[0.22467806399799883,0.22451699999999875,494296310,639540,null,null,null,null,null,null,null]]},{"reportAnalysis":{"anMean":{"estUpperBound":2.700766045605913e-6,"estLowerBound":2.5489390737084626e-6,"estPoint":2.614524699113428e-6,"estConfidenceLevel":0.95},"anRegress":[{"regRSquare":{"estUpperBound":0.9963158112849326,"estLowerBound":0.9813766955405638,"estPoint":0.9888135706759168,"estConfidenceLevel":0.95},"regResponder":"time","regCoeffs":{"y":{"estUpperBound":3.36336946581968e-4,"estLowerBound":-5.759459124098816e-4,"estPoint":-1.0139218770465428e-4,"estConfidenceLevel":0.95},"iters":{"estUpperBound":2.7027537748864712e-6,"estLowerBound":2.4813442295249526e-6,"estPoint":2.586203298978693e-6,"estConfidenceLevel":0.95}}}],"anStdDev":{"estUpperBound":3.0480780278156827e-7,"estLowerBound":2.0893167057513842e-7,"estPoint":2.4922772413717383e-7,"estConfidenceLevel":0.95},"anOutlierVar":{"ovFraction":0.86814310186276,"ovDesc":"severe","ovEffect":"Severe"},"anOverhead":3.161534180001628e-6},"reportKDEs":[{"kdeValues":[2.0686914544928066e-6,2.078425810377499e-6,2.0881601662621917e-6,2.097894522146884e-6,2.1076288780315764e-6,2.117363233916269e-6,2.1270975898009615e-6,2.136831945685654e-6,2.1465663015703466e-6,2.156300657455039e-6,2.1660350133397313e-6,2.1757693692244237e-6,2.1855037251091164e-6,2.1952380809938088e-6,2.204972436878501e-6,2.214706792763194e-6,2.224441148647886e-6,2.2341755045325785e-6,2.2439098604172713e-6,2.2536442163019636e-6,2.263378572186656e-6,2.2731129280713487e-6,2.282847283956041e-6,2.2925816398407334e-6,2.302315995725426e-6,2.3120503516101185e-6,2.321784707494811e-6,2.3315190633795036e-6,2.341253419264196e-6,2.3509877751488883e-6,2.3607221310335807e-6,2.3704564869182734e-6,2.3801908428029658e-6,2.3899251986876585e-6,2.399659554572351e-6,2.409393910457043e-6,2.4191282663417355e-6,2.4288626222264283e-6,2.4385969781111206e-6,2.448331333995813e-6,2.4580656898805057e-6,2.467800045765198e-6,2.4775344016498904e-6,2.487268757534583e-6,2.4970031134192755e-6,2.506737469303968e-6,2.5164718251886606e-6,2.526206181073353e-6,2.5359405369580453e-6,2.5456748928427377e-6,2.5554092487274304e-6,2.5651436046121228e-6,2.5748779604968155e-6,2.584612316381508e-6,2.5943466722662e-6,2.6040810281508925e-6,2.6138153840355853e-6,2.6235497399202776e-6,2.63328409580497e-6,2.6430184516896628e-6,2.652752807574355e-6,2.6624871634590474e-6,2.6722215193437398e-6,2.6819558752284325e-6,2.691690231113125e-6,2.7014245869978176e-6,2.71115894288251e-6,2.7208932987672023e-6,2.7306276546518947e-6,2.7403620105365874e-6,2.7500963664212798e-6,2.7598307223059725e-6,2.769565078190665e-6,2.779299434075357e-6,2.7890337899600495e-6,2.7987681458447423e-6,2.8085025017294347e-6,2.818236857614127e-6,2.8279712134988198e-6,2.837705569383512e-6,2.8474399252682044e-6,2.857174281152897e-6,2.8669086370375895e-6,2.876642992922282e-6,2.8863773488069746e-6,2.896111704691667e-6,2.9058460605763593e-6,2.9155804164610517e-6,2.9253147723457444e-6,2.9350491282304368e-6,2.9447834841151295e-6,2.954517839999822e-6,2.9642521958845142e-6,2.9739865517692066e-6,2.9837209076538993e-6,2.9934552635385917e-6,3.0031896194232844e-6,3.0129239753079768e-6,3.022658331192669e-6,3.0323926870773614e-6,3.0421270429620538e-6,3.0518613988467465e-6,3.0615957547314393e-6,3.0713301106161316e-6,3.081064466500824e-6,3.0907988223855163e-6,3.1005331782702087e-6,3.1102675341549014e-6,3.1200018900395938e-6,3.1297362459242865e-6,3.139470601808979e-6,3.1492049576936712e-6,3.1589393135783636e-6,3.1686736694630563e-6,3.1784080253477487e-6,3.1881423812324414e-6,3.1978767371171338e-6,3.207611093001826e-6,3.2173454488865184e-6,3.2270798047712108e-6,3.2368141606559035e-6,3.2465485165405963e-6,3.2562828724252887e-6,3.266017228309981e-6,3.2757515841946733e-6,3.2854859400793657e-6,3.2952202959640584e-6,3.3049546518487508e-6],"kdeType":"time","kdePDF":[193348.37411608477,195787.67943903586,200648.0496875539,207894.41662626184,217477.60419800878,229338.15351163864,243410.9677847057,259630.43054229204,277935.6139420204,298275.18537864153,320611.6398482463,344924.53108626854,371212.4423769799,399493.52259140834,429804.5076097088,462198.2442885739,496739.825945078,533501.5279305208,572556.7934448962,613973.5591982311,657807.2258694681,704093.5698718495,752841.8633543929,804028.423417068,857590.7556605608,913422.3989961696,971368.5260191171,1031222.3136045334,1092722.077741481,1155549.1687915262,1219326.6492767837,1283618.823578413,1347931.751733892,1411714.9488659068,1474364.5361848872,1535228.156119902,1593611.9801298883,1648790.111994119,1700016.6141146778,1746540.2567119885,1787621.9129084416,1822554.3062876717,1850683.577654195,1871431.8957836279,1884320.1178163385,1888989.3344663668,1885220.0373355097,1872947.6393742985,1852273.176346929,1823468.2188309694,1786973.3219293838,1743389.7140752703,1693464.3485281398,1638068.8763004115,1578173.5091379452,1514817.0885404367,1449074.929314927,1382026.1399994812,1314722.1250739216,1248157.8452578573,1183247.1651551079,1120803.2761352921,1061524.779434515,1005987.5879317212,954642.3939246824,907817.0905308761,865723.2555393736,828465.6287808041,796053.4465428785,768412.5370811877,745397.2172074204,726801.240050196,712367.3012671213,701794.8854026187,694746.4963903147,690852.5404979753,689715.2962463385,690912.501385636,694001.1074337641,698521.7011127233,704003.9798254858,709973.5110583926,715959.8226072633,721505.6823087626,726177.2520467232,729574.6579264199,731342.4192055991,731179.130356173,728845.7957563065,724172.2722737687,717061.374495603,707490.3305671671,695509.431627356,681237.8821337967,664857.019906639,646601.2227881057,626746.9446837859,605600.4209590345,583484.6475728014,560726.2679896798,537642.9967931723,514532.170629574,491660.9485854966,469258.589399586,447511.11703277455,426558.55489788984,406494.7690173883,387369.8186463004,369194.576933432,351947.26151982555,335581.4127689706,320034.7819557119,305238.5482667463,291126.27516166767,277642.04462878616,264747.27087790414,252425.78935354357,240686.93668799847,229566.47453294246,219125.35597781054,209446.47769778976,200629.6943643561,192785.48527776,186027.7491541602,180466.2559729677,176199.30150793327,173307.08984033504,171846.31345863192]}],"reportKeys":["time","cpuTime","cycles","iters","allocated","numGcs","bytesCopied","mutatorWallSeconds","mutatorCpuSeconds","gcWallSeconds","gcCpuSeconds"],"reportNumber":2,"reportName":"fib/9","reportOutliers":{"highSevere":0,"highMild":0,"lowMild":0,"samplesSeen":43,"lowSevere":0},"reportMeasured":[[9.025010513141751e-6,9.000000000369823e-6,10070,1,null,null,null,null,null,null,null],[6.454007234424353e-6,6.9999999983139105e-6,14026,2,null,null,null,null,null,null,null],[8.56400583870709e-6,7.999999999341867e-6,18698,3,null,null,null,null,null,null,null],[1.0866002412512898e-5,1.0999999998873022e-5,23874,4,null,null,null,null,null,null,null],[1.3115000911056995e-5,1.2999999999152578e-5,28860,5,null,null,null,null,null,null,null],[1.559098018333316e-5,1.5999999998683734e-5,34492,6,null,null,null,null,null,null,null],[1.771599636413157e-5,1.699999999971169e-5,38994,7,null,null,null,null,null,null,null],[2.0154984667897224e-5,2.100000000204716e-5,44484,8,null,null,null,null,null,null,null],[2.247901284135878e-5,2.19999999995224e-5,49484,9,null,null,null,null,null,null,null],[2.4684995878487825e-5,2.4999999999053557e-5,54322,10,null,null,null,null,null,null,null],[2.7000001864507794e-5,2.6000000000081513e-5,59580,11,null,null,null,null,null,null,null],[2.9360002372413874e-5,3.0000000000640625e-5,64772,12,null,null,null,null,null,null,null],[3.161598579026759e-5,3.1999999999143824e-5,69726,13,null,null,null,null,null,null,null],[3.410899080336094e-5,3.400000000119974e-5,75208,14,null,null,null,null,null,null,null],[3.648200072348118e-5,3.600000000147929e-5,80404,15,null,null,null,null,null,null,null],[3.861100412905216e-5,3.899999999923409e-5,85242,16,null,null,null,null,null,null,null],[4.0942017221823335e-5,4.2000000000541604e-5,90026,17,null,null,null,null,null,null,null],[4.3231004383414984e-5,4.300000000156956e-5,95256,18,null,null,null,null,null,null,null],[4.5541994040831923e-5,4.599999999932436e-5,100604,19,null,null,null,null,null,null,null],[6.048599607311189e-5,6.100000000053285e-5,135170,20,null,null,null,null,null,null,null],[5.038900417275727e-5,5.100000000091143e-5,110876,21,null,null,null,null,null,null,null],[5.247999797575176e-5,5.2000000001939384e-5,115660,22,null,null,null,null,null,null,null],[5.473001510836184e-5,5.499999999969418e-5,120400,23,null,null,null,null,null,null,null],[5.947801400907338e-5,6.000000000128125e-5,130906,25,null,null,null,null,null,null,null],[6.179101183079183e-5,6.20000000015608e-5,136292,26,null,null,null,null,null,null,null],[6.399900303222239e-5,6.400000000184036e-5,140834,27,null,null,null,null,null,null,null],[6.636200123466551e-5,6.699999999959516e-5,146108,28,null,null,null,null,null,null,null],[8.053000783547759e-5,7.999999999874774e-5,197550,30,null,null,null,null,null,null,null],[7.612298941239715e-5,7.600000000174134e-5,167449,31,null,null,null,null,null,null,null],[1.3218598905950785e-4,1.3199999999891077e-4,291486,33,null,null,null,null,null,null,null],[8.550498750992119e-5,8.600000000136276e-5,188223,35,null,null,null,null,null,null,null],[8.784799138084054e-5,8.79999999980896e-5,193612,36,null,null,null,null,null,null,null],[9.27560031414032e-5,9.300000000145303e-5,204376,38,null,null,null,null,null,null,null],[1.0629199096001685e-4,1.0599999999882925e-4,236083,40,null,null,null,null,null,null,null],[1.0212001507170498e-4,1.029999999992981e-4,224758,42,null,null,null,null,null,null,null],[1.0692101204767823e-4,1.0699999999808085e-4,235573,44,null,null,null,null,null,null,null],[1.1425901902839541e-4,1.1399999999994748e-4,251653,47,null,null,null,null,null,null,null],[1.2689499999396503e-4,1.2699999999910005e-4,281569,49,null,null,null,null,null,null,null],[1.262580044567585e-4,1.259999999980721e-4,278153,52,null,null,null,null,null,null,null],[1.7646601190790534e-4,1.7800000000001148e-4,389226,54,null,null,null,null,null,null,null],[1.4653097605332732e-4,1.459999999990913e-4,323374,57,null,null,null,null,null,null,null],[1.5397000242955983e-4,1.5499999999946112e-4,341224,60,null,null,null,null,null,null,null],[1.528009888716042e-4,1.5200000000170633e-4,336943,63,null,null,null,null,null,null,null],[1.598570088390261e-4,1.600000000010482e-4,352477,66,null,null,null,null,null,null,null],[1.7703999765217304e-4,1.7700000000075988e-4,392036,69,null,null,null,null,null,null,null],[1.7054399359039962e-4,1.7000000000066962e-4,376114,73,null,null,null,null,null,null,null],[1.7806902178563178e-4,1.7800000000001148e-4,392362,76,null,null,null,null,null,null,null],[1.936939952429384e-4,1.9300000000121997e-4,428626,80,null,null,null,null,null,null,null],[1.9629302551038563e-4,1.9600000000075113e-4,432900,84,null,null,null,null,null,null,null],[2.1560300956480205e-4,2.1599999999999397e-4,476902,89,null,null,null,null,null,null,null],[2.1720101358368993e-4,2.1700000000102193e-4,478940,93,null,null,null,null,null,null,null],[2.3577900719828904e-4,2.3600000000101318e-4,521462,98,null,null,null,null,null,null,null],[2.4000598932616413e-4,2.3999999999979593e-4,529060,103,null,null,null,null,null,null,null],[2.689130196813494e-4,2.6899999999763224e-4,595922,108,null,null,null,null,null,null,null],[2.6383798103779554e-4,2.6500000000062585e-4,581164,113,null,null,null,null,null,null,null],[2.848590083885938e-4,2.849999999998687e-4,629544,119,null,null,null,null,null,null,null],[2.9143900610506535e-4,2.90999999998931e-4,642830,125,null,null,null,null,null,null,null],[3.314010100439191e-4,3.32000000000221e-4,732346,131,null,null,null,null,null,null,null],[3.408030024729669e-4,3.409999999988145e-4,752136,138,null,null,null,null,null,null,null],[3.719259984791279e-4,3.7200000000048306e-4,838015,144,null,null,null,null,null,null,null],[3.3201402402482927e-4,3.3200000000199736e-4,732194,152,null,null,null,null,null,null,null],[3.535610157996416e-4,3.5400000000151977e-4,780606,159,null,null,null,null,null,null,null],[3.8795600994490087e-4,3.879999999991668e-4,856874,167,null,null,null,null,null,null,null],[4.030359850730747e-4,4.029999999985989e-4,888754,176,null,null,null,null,null,null,null],[4.101049853488803e-4,4.089999999994376e-4,904480,185,null,null,null,null,null,null,null],[4.5459700049832463e-4,4.5499999999876195e-4,1002900,194,null,null,null,null,null,null,null],[4.5129001955501735e-4,4.509999999999792e-4,995144,204,null,null,null,null,null,null,null],[4.8493797658011317e-4,4.849999999994026e-4,1070060,214,null,null,null,null,null,null,null],[5.080150149296969e-4,5.079999999981766e-4,1120512,224,null,null,null,null,null,null,null],[5.283710197545588e-4,5.289999999984474e-4,1165972,236,null,null,null,null,null,null,null],[5.59504987904802e-4,5.60000000000116e-4,1233404,247,null,null,null,null,null,null,null],[5.874079943168908e-4,5.870000000012254e-4,1295364,260,null,null,null,null,null,null,null],[6.147419917397201e-4,6.140000000005585e-4,1354582,273,null,null,null,null,null,null,null],[6.551709957420826e-4,6.559999999993238e-4,1444154,287,null,null,null,null,null,null,null],[6.678270001430064e-4,6.679999999992248e-4,1472302,301,null,null,null,null,null,null,null],[8.210859959945083e-4,7.880000000000109e-4,1813802,316,null,null,null,null,null,null,null],[7.803000044077635e-4,7.809999999999206e-4,1719170,332,null,null,null,null,null,null,null],[8.215210109483451e-4,8.219999999994343e-4,1810584,348,null,null,null,null,null,null,null],[8.625930058769882e-4,8.620000000014727e-4,1900320,366,null,null,null,null,null,null,null],[9.034019894897938e-4,9.0299999999921e-4,1989990,384,null,null,null,null,null,null,null],[9.107229998335242e-4,9.109999999985519e-4,2006526,403,null,null,null,null,null,null,null],[9.354469948448241e-4,9.350000000019065e-4,2060650,424,null,null,null,null,null,null,null],[9.821320127230138e-4,9.830000000015104e-4,2163700,445,null,null,null,null,null,null,null],[1.0278359986841679e-3,1.0279999999998068e-3,2264884,467,null,null,null,null,null,null,null],[1.083791023120284e-3,1.084000000000529e-3,2387530,490,null,null,null,null,null,null,null],[1.1553829826880246e-3,1.1560000000017112e-3,2546456,515,null,null,null,null,null,null,null],[1.285703998291865e-3,1.2860000000003424e-3,2833710,541,null,null,null,null,null,null,null],[1.3429950049612671e-3,1.3430000000003162e-3,2957990,568,null,null,null,null,null,null,null],[1.407958014169708e-3,1.4079999999996318e-3,3103416,596,null,null,null,null,null,null,null],[1.47148099495098e-3,1.4720000000014721e-3,3242800,626,null,null,null,null,null,null,null],[1.5448569902218878e-3,1.5459999999993812e-3,3402196,657,null,null,null,null,null,null,null],[1.6275400121230632e-3,1.6280000000001849e-3,3584376,690,null,null,null,null,null,null,null],[1.7233329999726266e-3,1.7250000000004206e-3,3797122,725,null,null,null,null,null,null,null],[1.676952000707388e-3,1.6770000000008167e-3,3692250,761,null,null,null,null,null,null,null],[1.8132149998564273e-3,1.8129999999985102e-3,3992996,799,null,null,null,null,null,null,null],[1.8865060119424015e-3,1.8860000000007204e-3,4153276,839,null,null,null,null,null,null,null],[2.0333520078565925e-3,2.0329999999990633e-3,4477530,881,null,null,null,null,null,null,null],[2.186147990869358e-3,2.1860000000000213e-3,4812700,925,null,null,null,null,null,null,null],[2.234531013527885e-3,2.2349999999988768e-3,4920346,972,null,null,null,null,null,null,null],[2.2437220031861216e-3,2.2439999999992466e-3,4939532,1020,null,null,null,null,null,null,null],[2.3632259981241077e-3,2.3640000000000327e-3,5202712,1071,null,null,null,null,null,null,null],[2.4740290245972574e-3,2.473999999999421e-3,5446956,1125,null,null,null,null,null,null,null],[2.6580050180200487e-3,2.658999999999523e-3,5854054,1181,null,null,null,null,null,null,null],[2.760325005510822e-3,2.7609999999995694e-3,6078928,1240,null,null,null,null,null,null,null],[2.889148978283629e-3,2.888999999997921e-3,6368080,1302,null,null,null,null,null,null,null],[3.0587739893235266e-3,3.059000000000367e-3,6741256,1367,null,null,null,null,null,null,null],[3.172787983203307e-3,3.1740000000013424e-3,6991352,1436,null,null,null,null,null,null,null],[3.3469090121798217e-3,3.3479999999990184e-3,7374200,1507,null,null,null,null,null,null,null],[3.7601999938488007e-3,3.76000000000154e-3,8290968,1583,null,null,null,null,null,null,null],[3.717967978445813e-3,3.71900000000025e-3,8198438,1662,null,null,null,null,null,null,null],[3.8702079909853637e-3,3.871000000001956e-3,8531532,1745,null,null,null,null,null,null,null],[4.957520985044539e-3,4.925000000000068e-3,10914740,1832,null,null,null,null,null,null,null],[4.731969995191321e-3,4.732999999999876e-3,10417106,1924,null,null,null,null,null,null,null],[6.260136986384168e-3,6.259000000001791e-3,13773342,2020,null,null,null,null,null,null,null],[4.586497001582757e-3,4.585999999999757e-3,10093508,2121,null,null,null,null,null,null,null],[4.863178008235991e-3,4.862999999998507e-3,10702212,2227,null,null,null,null,null,null,null],[5.051475978689268e-3,5.051999999999168e-3,11116046,2339,null,null,null,null,null,null,null],[5.2665589901153e-3,5.266999999999911e-3,11589664,2456,null,null,null,null,null,null,null],[5.532464012503624e-3,5.532000000002313e-3,12173910,2579,null,null,null,null,null,null,null],[1.221357801114209e-2,1.2194000000000926e-2,26883372,2708,null,null,null,null,null,null,null],[7.677442015847191e-3,7.676999999999268e-3,16891160,2843,null,null,null,null,null,null,null],[6.515315995784476e-3,6.5099999999986835e-3,14338932,2985,null,null,null,null,null,null,null],[6.838730012532324e-3,6.838999999999373e-3,15048110,3134,null,null,null,null,null,null,null],[7.074805005686358e-3,7.0750000000003865e-3,15568760,3291,null,null,null,null,null,null,null],[7.407514000078663e-3,7.407999999999859e-3,16299468,3456,null,null,null,null,null,null,null],[1.2365557020530105e-2,1.2347000000000108e-2,27218076,3629,null,null,null,null,null,null,null],[1.487063302192837e-2,1.4864000000001099e-2,32717934,3810,null,null,null,null,null,null,null],[8.677542995428666e-3,8.677999999999741e-3,19093038,4001,null,null,null,null,null,null,null],[1.3501470995834097e-2,1.3498999999997707e-2,29716954,4201,null,null,null,null,null,null,null],[1.6902139992453158e-2,1.689500000000166e-2,37186708,4411,null,null,null,null,null,null,null],[1.009635700029321e-2,1.0097999999999274e-2,22214776,4631,null,null,null,null,null,null,null],[1.03957150131464e-2,1.0395999999998295e-2,22873830,4863,null,null,null,null,null,null,null],[1.0963571985485032e-2,1.0964999999998781e-2,24122952,5106,null,null,null,null,null,null,null],[1.8303408025531098e-2,1.829900000000073e-2,40274822,5361,null,null,null,null,null,null,null],[1.2116741010686383e-2,1.2115999999998905e-2,26659714,5629,null,null,null,null,null,null,null],[1.27997369854711e-2,1.2799000000001115e-2,28162698,5911,null,null,null,null,null,null,null],[1.3315553980646655e-2,1.3314999999998633e-2,29297156,6207,null,null,null,null,null,null,null],[1.400301099056378e-2,1.3990999999998976e-2,30810540,6517,null,null,null,null,null,null,null],[2.1235216001514345e-2,2.1203999999999112e-2,46723796,6843,null,null,null,null,null,null,null],[2.221076699788682e-2,2.2181999999999036e-2,48871974,7185,null,null,null,null,null,null,null],[1.670748699689284e-2,1.666799999999924e-2,36761724,7544,null,null,null,null,null,null,null],[2.1554483013460413e-2,2.1551000000000542e-2,47434276,7921,null,null,null,null,null,null,null],[2.0073012012289837e-2,2.0073000000000008e-2,44161128,8318,null,null,null,null,null,null,null],[1.8873328022891656e-2,1.887299999999925e-2,41524274,8733,null,null,null,null,null,null,null],[1.968980100355111e-2,1.9689999999998875e-2,43320782,9170,null,null,null,null,null,null,null],[2.0864435995463282e-2,2.086399999999955e-2,45904880,9629,null,null,null,null,null,null,null],[2.207880499190651e-2,2.2078999999999738e-2,48576264,10110,null,null,null,null,null,null,null],[2.6395068009151146e-2,2.6391000000000275e-2,58089377,10616,null,null,null,null,null,null,null],[2.7240916999289766e-2,2.7240999999998294e-2,59929207,11146,null,null,null,null,null,null,null],[3.516917198430747e-2,3.511600000000037e-2,77384600,11704,null,null,null,null,null,null,null],[3.7458534992765635e-2,3.742699999999921e-2,82416984,12289,null,null,null,null,null,null,null],[3.291460601030849e-2,3.2906000000000546e-2,72423722,12903,null,null,null,null,null,null,null],[3.6155059991870075e-2,3.614899999999821e-2,79543576,13549,null,null,null,null,null,null,null],[4.1628117993241176e-2,4.156500000000207e-2,91594268,14226,null,null,null,null,null,null,null],[3.4839631989598274e-2,3.483499999999928e-2,76648000,14937,null,null,null,null,null,null,null],[4.0510771999834105e-2,4.0502000000001814e-2,89145186,15684,null,null,null,null,null,null,null],[4.9066898005548865e-2,4.8993000000001174e-2,107970840,16469,null,null,null,null,null,null,null],[4.996129099163227e-2,4.992999999999981e-2,109914860,17292,null,null,null,null,null,null,null],[4.562150500714779e-2,4.5588000000000406e-2,100373992,18157,null,null,null,null,null,null,null],[5.468654099968262e-2,5.462799999999923e-2,120316508,19065,null,null,null,null,null,null,null],[5.1227504009148106e-2,5.1217999999998653e-2,112706366,20018,null,null,null,null,null,null,null],[6.129929900635034e-2,6.123000000000012e-2,134874875,21019,null,null,null,null,null,null,null],[5.15769770136103e-2,5.157200000000195e-2,113468473,22070,null,null,null,null,null,null,null],[5.767232697689906e-2,5.761500000000197e-2,126885276,23173,null,null,null,null,null,null,null],[6.247224801336415e-2,6.2433999999999656e-2,137444260,24332,null,null,null,null,null,null,null],[7.516540100914426e-2,7.508400000000037e-2,165396430,25549,null,null,null,null,null,null,null],[7.343321599182673e-2,7.339199999999835e-2,161552540,26826,null,null,null,null,null,null,null],[6.830699602141976e-2,6.825999999999866e-2,150281128,28167,null,null,null,null,null,null,null],[7.023733499227092e-2,7.02039999999986e-2,154528280,29576,null,null,null,null,null,null,null],[8.683017798466608e-2,8.651099999999978e-2,191040034,31054,null,null,null,null,null,null,null],[7.274429200333543e-2,7.274400000000014e-2,160039058,32607,null,null,null,null,null,null,null],[8.211532200220972e-2,8.206700000000033e-2,180662670,34238,null,null,null,null,null,null,null],[8.70943600020837e-2,8.707700000000074e-2,191615170,35950,null,null,null,null,null,null,null],[8.197724600904621e-2,8.196399999999926e-2,180354382,37747,null,null,null,null,null,null,null],[9.827196502010338e-2,9.818399999999983e-2,216206122,39634,null,null,null,null,null,null,null],[0.10549629898741841,0.10542699999999883,232110622,41616,null,null,null,null,null,null,null],[0.1122115509933792,0.11212699999999742,246868720,43697,null,null,null,null,null,null,null],[0.11293111098348163,0.11289100000000118,248455058,45882,null,null,null,null,null,null,null],[0.12375319001148455,0.12366899999999958,272265397,48176,null,null,null,null,null,null,null],[0.13845999402110465,0.138423999999997,304616934,50585,null,null,null,null,null,null,null],[0.133371153002372,0.1332810000000002,293422502,53114,null,null,null,null,null,null,null],[0.14320144298835658,0.14300400000000124,315050006,55770,null,null,null,null,null,null,null],[0.14068631900590844,0.14066700000000054,309516856,58558,null,null,null,null,null,null,null],[0.1589633270050399,0.15887000000000384,349725216,61486,null,null,null,null,null,null,null],[0.2067215590213891,0.2065960000000011,454803626,64561,null,null,null,null,null,null,null],[0.21341353200841695,0.21326900000000037,469514302,67789,null,null,null,null,null,null,null],[0.1625783139897976,0.16252099999999814,357677982,71178,null,null,null,null,null,null,null],[0.18611083400901407,0.18606000000000122,409451766,74737,null,null,null,null,null,null,null],[0.19076346699148417,0.1907389999999971,419684952,78474,null,null,null,null,null,null,null],[0.2057581989793107,0.20567599999999686,452674120,82398,null,null,null,null,null,null,null],[0.23152257202309556,0.231344,509357080,86518,null,null,null,null,null,null,null],[0.23171886400086805,0.23154100000000355,509788352,90843,null,null,null,null,null,null,null]]},{"reportAnalysis":{"anMean":{"estUpperBound":6.668634037917654e-6,"estLowerBound":6.347714383730146e-6,"estPoint":6.496202868182492e-6,"estConfidenceLevel":0.95},"anRegress":[{"regRSquare":{"estUpperBound":0.9955136915306878,"estLowerBound":0.9915361738646395,"estPoint":0.9933084622105373,"estConfidenceLevel":0.95},"regResponder":"time","regCoeffs":{"y":{"estUpperBound":1.604926501967662e-4,"estLowerBound":-8.528224619350055e-4,"estPoint":-3.893843475459815e-4,"estConfidenceLevel":0.95},"iters":{"estUpperBound":6.807397769730118e-6,"estLowerBound":6.364300170847571e-6,"estPoint":6.615936525692066e-6,"estConfidenceLevel":0.95}}}],"anStdDev":{"estUpperBound":6.202125623223447e-7,"estLowerBound":4.0420784296930194e-7,"estPoint":4.919233380857326e-7,"estConfidenceLevel":0.95},"anOutlierVar":{"ovFraction":0.7876656352417168,"ovDesc":"severe","ovEffect":"Severe"},"anOverhead":3.161534180001628e-6},"reportKDEs":[{"kdeValues":[5.516456561449886e-6,5.536462667632315e-6,5.556468773814743e-6,5.576474879997171e-6,5.5964809861796e-6,5.616487092362028e-6,5.636493198544457e-6,5.6564993047268855e-6,5.676505410909314e-6,5.696511517091742e-6,5.7165176232741705e-6,5.736523729456599e-6,5.756529835639028e-6,5.776535941821456e-6,5.796542048003884e-6,5.816548154186313e-6,5.836554260368741e-6,5.85656036655117e-6,5.876566472733598e-6,5.896572578916027e-6,5.916578685098455e-6,5.936584791280883e-6,5.956590897463312e-6,5.9765970036457406e-6,5.996603109828169e-6,6.016609216010597e-6,6.0366153221930255e-6,6.056621428375454e-6,6.076627534557883e-6,6.096633640740311e-6,6.11663974692274e-6,6.136645853105168e-6,6.156651959287596e-6,6.176658065470025e-6,6.1966641716524534e-6,6.216670277834882e-6,6.23667638401731e-6,6.256682490199738e-6,6.276688596382167e-6,6.2966947025645956e-6,6.316700808747024e-6,6.336706914929453e-6,6.356713021111881e-6,6.376719127294309e-6,6.396725233476738e-6,6.416731339659166e-6,6.436737445841595e-6,6.456743552024023e-6,6.476749658206451e-6,6.49675576438888e-6,6.5167618705713085e-6,6.536767976753737e-6,6.556774082936166e-6,6.576780189118594e-6,6.596786295301022e-6,6.616792401483451e-6,6.636798507665879e-6,6.656804613848308e-6,6.6768107200307355e-6,6.696816826213164e-6,6.716822932395593e-6,6.736829038578021e-6,6.75683514476045e-6,6.7768412509428785e-6,6.796847357125307e-6,6.816853463307735e-6,6.8368595694901635e-6,6.856865675672592e-6,6.876871781855021e-6,6.896877888037448e-6,6.916883994219877e-6,6.936890100402306e-6,6.956896206584734e-6,6.976902312767163e-6,6.996908418949591e-6,7.01691452513202e-6,7.036920631314448e-6,7.056926737496876e-6,7.076932843679305e-6,7.0969389498617335e-6,7.116945056044161e-6,7.13695116222659e-6,7.1569572684090185e-6,7.176963374591447e-6,7.196969480773876e-6,7.216975586956304e-6,7.236981693138733e-6,7.256987799321161e-6,7.276993905503589e-6,7.297000011686018e-6,7.317006117868446e-6,7.337012224050875e-6,7.357018330233303e-6,7.377024436415731e-6,7.39703054259816e-6,7.4170366487805886e-6,7.437042754963017e-6,7.457048861145446e-6,7.477054967327874e-6,7.497061073510302e-6,7.517067179692731e-6,7.537073285875159e-6,7.557079392057587e-6,7.577085498240016e-6,7.597091604422444e-6,7.617097710604873e-6,7.637103816787301e-6,7.65710992296973e-6,7.677116029152159e-6,7.697122135334587e-6,7.717128241517016e-6,7.737134347699443e-6,7.757140453881873e-6,7.7771465600643e-6,7.797152666246729e-6,7.817158772429157e-6,7.837164878611586e-6,7.857170984794014e-6,7.877177090976443e-6,7.897183197158872e-6,7.9171893033413e-6,7.937195409523729e-6,7.957201515706156e-6,7.977207621888586e-6,7.997213728071013e-6,8.017219834253441e-6,8.03722594043587e-6,8.057232046618299e-6],"kdeType":"time","kdePDF":[365084.64335106785,365955.49000460893,367690.6797673853,370277.2877736251,373696.1305380558,377922.0056999675,382924.0037781107,388665.8854552148,395106.51664555265,402200.35255211394,409897.9611181589,418146.57573942543,426890.6668376662,436072.5219040203,445632.82389391947,455511.2183772528,465646.8605945285,475978.9345112456,486447.1370630893,496992.1220043202,507555.89906917716,518082.1854886137,528516.7082305428,538807.4566113031,548904.8861232334,558762.0754064709,568334.8392364082,577581.8011816988,586464.4301979609,594947.0458525838,602996.7971260689,610583.6198109,617680.1774414472,624261.7904538356,630306.3579130819,635794.2756787611,640708.3543346924,645033.7396079227,648757.8373728646,651870.244701885,654362.6878061797,656228.967130115,657464.909335084,658068.3254487243,658038.9740719376,657378.5282359902,656090.544288011,654180.4310554129,651655.4174951238,648524.517066855,644798.4871735352,640489.7821779322,635612.4987223883,630182.3123382808,624216.4046224251,617733.3805687939,610753.1759651479,603296.9550859929,595386.9992264116,587046.5869177949,578299.8669386071,569171.7254748241,559687.6489895955,549873.5845255502,539755.7992817654,529360.7413781392,518714.9037404172,507844.6930087706,496776.3052914023,485535.61045374046,474148.0464555006,462638.52502635546,451031.34971078974,439350.14702059305,427617.81111647346,415856.46210739476,404087.4177165369,392331.17772676033,380607.4202962133,368935.0089371603,357332.0086879874,345815.7097894398,334402.65700934996,323108.68265251216,311948.94124848803,300937.94393305253,290089.59062884044,279417.1982857856,268933.5236574748,258650.77935900452,248580.6422662301,238734.2536648964,229122.21092871844,219754.55088508682,210640.72540199192,201789.57008667773,193209.26731245476,184907.30507346542,176890.4333977947,169164.62021918147,161735.00871083967,154605.878118388,147780.61009186218,141261.66241126214,135050.55183037923,129147.84753638429,123553.1764462819,118265.24124583355,113281.851732915,108599.96966709575,104215.76696218607,100124.69669994565,96321.57610163518,92800.68027911366,89555.84530677927,86580.5789163404,83868.17692294557,81411.84334669443,79204.81209937707,77240.46806235048,75512.46538622786,74014.84089396993,72742.1205624549,71689.41718959752,70852.51751998924,70227.95729717045,69813.08293027095,69606.09870228493]}],"reportKeys":["time","cpuTime","cycles","iters","allocated","numGcs","bytesCopied","mutatorWallSeconds","mutatorCpuSeconds","gcWallSeconds","gcCpuSeconds"],"reportNumber":3,"reportName":"fib/11","reportOutliers":{"highSevere":0,"highMild":0,"lowMild":0,"samplesSeen":42,"lowSevere":0},"reportMeasured":[[1.19420001283288e-5,1.100000000064938e-5,16944,1,null,null,null,null,null,null,null],[1.2820994015783072e-5,1.4000000003733248e-5,28392,2,null,null,null,null,null,null,null],[1.8277991330251098e-5,1.8000000000739647e-5,39682,3,null,null,null,null,null,null,null],[2.3559987312182784e-5,2.3000000002326715e-5,51722,4,null,null,null,null,null,null,null],[2.9238988645374775e-5,2.9000000001389026e-5,64328,5,null,null,null,null,null,null,null],[3.453998942859471e-5,3.499999999689862e-5,76036,6,null,null,null,null,null,null,null],[4.0396000258624554e-5,4.0000000002038405e-5,88826,7,null,null,null,null,null,null,null],[4.578699008561671e-5,4.500000000007276e-5,100714,8,null,null,null,null,null,null,null],[5.118001718074083e-5,5.200000000371574e-5,112756,9,null,null,null,null,null,null,null],[5.6882010539993644e-5,5.699999999819738e-5,125390,10,null,null,null,null,null,null,null],[6.255999323911965e-5,6.199999999623174e-5,137390,11,null,null,null,null,null,null,null],[7.794398698024452e-5,7.799999999846818e-5,173504,12,null,null,null,null,null,null,null],[7.340399315580726e-5,7.299999999688112e-5,161570,13,null,null,null,null,null,null,null],[7.913200533948839e-5,7.899999999949614e-5,174244,14,null,null,null,null,null,null,null],[8.437101496383548e-5,8.39999999975305e-5,185760,15,null,null,null,null,null,null,null],[9.023700840771198e-5,9.000000000014552e-5,198712,16,null,null,null,null,null,null,null],[1.033990120049566e-4,1.0400000000032605e-4,229586,17,null,null,null,null,null,null,null],[1.11757981358096e-4,1.1300000000247223e-4,246470,18,null,null,null,null,null,null,null],[1.0994198964908719e-4,1.0899999999836041e-4,241928,19,null,null,null,null,null,null,null],[1.1555801029317081e-4,1.1600000000200339e-4,254432,20,null,null,null,null,null,null,null],[1.28689018310979e-4,1.2899999999760325e-4,284934,21,null,null,null,null,null,null,null],[1.2716499622911215e-4,1.2699999999910005e-4,280038,22,null,null,null,null,null,null,null],[1.3242900604382157e-4,1.3200000000068712e-4,291694,23,null,null,null,null,null,null,null],[1.4399300562217832e-4,1.44999999996287e-4,317112,25,null,null,null,null,null,null,null],[1.5634798910468817e-4,1.5600000000048908e-4,346348,26,null,null,null,null,null,null,null],[1.554309856146574e-4,1.5499999999946112e-4,342524,27,null,null,null,null,null,null,null],[1.6803698963485658e-4,1.679999999986137e-4,371502,28,null,null,null,null,null,null,null],[1.7268001101911068e-4,1.7199999999917281e-4,380334,30,null,null,null,null,null,null,null],[1.779469894245267e-4,1.7799999999823513e-4,392058,31,null,null,null,null,null,null,null],[1.9628097652457654e-4,1.9700000000000273e-4,433818,33,null,null,null,null,null,null,null],[2.0092999329790473e-4,1.9999999999953388e-4,442772,35,null,null,null,null,null,null,null],[2.1330598974600434e-4,2.1399999999971442e-4,471262,36,null,null,null,null,null,null,null],[2.1800599643029273e-4,2.1799999999672082e-4,480482,38,null,null,null,null,null,null,null],[2.3897402570582926e-4,2.3900000000054433e-4,528306,40,null,null,null,null,null,null,null],[2.4080401635728776e-4,2.420000000036282e-4,530676,42,null,null,null,null,null,null,null],[2.5893800193443894e-4,2.589999999997872e-4,571768,44,null,null,null,null,null,null,null],[2.997240226250142e-4,3.010000000003288e-4,663250,47,null,null,null,null,null,null,null],[3.089199890382588e-4,3.090000000049997e-4,682012,49,null,null,null,null,null,null,null],[3.097500011790544e-4,3.109999999999502e-4,683756,52,null,null,null,null,null,null,null],[3.156309830956161e-4,3.149999999969566e-4,696594,54,null,null,null,null,null,null,null],[3.2612000359222293e-4,3.260000000011587e-4,718494,57,null,null,null,null,null,null,null],[3.49440990248695e-4,3.4899999999638e-4,771438,60,null,null,null,null,null,null,null],[3.667880082502961e-4,3.660000000031971e-4,809170,63,null,null,null,null,null,null,null],[3.8382000639103353e-4,3.85000000001412e-4,846746,66,null,null,null,null,null,null,null],[4.006630042567849e-4,4.010000000000957e-4,883716,69,null,null,null,null,null,null,null],[4.2386798304505646e-4,4.230000000013945e-4,934500,73,null,null,null,null,null,null,null],[4.405810032039881e-4,4.409999999985814e-4,971460,76,null,null,null,null,null,null,null],[4.6515799476765096e-4,4.6599999999941133e-4,1025564,80,null,null,null,null,null,null,null],[4.7230199561454356e-4,4.7199999999847364e-4,1041266,84,null,null,null,null,null,null,null],[4.991129972040653e-4,5.000000000023874e-4,1100296,89,null,null,null,null,null,null,null],[5.213140102569014e-4,5.210000000026582e-4,1149148,93,null,null,null,null,null,null,null],[5.576809926424176e-4,5.5799999999806e-4,1229902,98,null,null,null,null,null,null,null],[5.952950159553438e-4,5.950000000005673e-4,1311972,103,null,null,null,null,null,null,null],[6.037959828972816e-4,6.040000000027135e-4,1330994,108,null,null,null,null,null,null,null],[6.543149938806891e-4,6.540000000008206e-4,1441638,113,null,null,null,null,null,null,null],[6.645909743383527e-4,6.649999999979173e-4,1464412,119,null,null,null,null,null,null,null],[7.063759840093553e-4,7.070000000020116e-4,1556890,125,null,null,null,null,null,null,null],[7.781200110912323e-4,7.780000000003895e-4,1715126,131,null,null,null,null,null,null,null],[7.939600036479533e-4,7.939999999990732e-4,1749020,138,null,null,null,null,null,null,null],[8.328559924848378e-4,8.330000000036364e-4,1835106,144,null,null,null,null,null,null,null],[9.031660156324506e-4,9.040000000020143e-4,1989646,152,null,null,null,null,null,null,null],[8.91278003109619e-4,8.92000000000337e-4,1963454,159,null,null,null,null,null,null,null],[9.401720017194748e-4,9.400000000034936e-4,2070960,167,null,null,null,null,null,null,null],[1.0015619918704033e-3,1.0019999999997253e-3,2206250,176,null,null,null,null,null,null,null],[1.0348139912821352e-3,1.0349999999981208e-3,2279112,185,null,null,null,null,null,null,null],[1.0906099923886359e-3,1.089999999997815e-3,2402064,194,null,null,null,null,null,null,null],[1.1836999910883605e-3,1.1849999999995475e-3,2606210,204,null,null,null,null,null,null,null],[1.2615190062206239e-3,1.2590000000010093e-3,2786174,214,null,null,null,null,null,null,null],[2.7388250164221972e-3,2.7400000000028513e-3,6037129,224,null,null,null,null,null,null,null],[2.820530004100874e-3,2.8200000000033754e-3,6210580,236,null,null,null,null,null,null,null],[2.4992660037241876e-3,2.4989999999966983e-3,5502115,247,null,null,null,null,null,null,null],[2.5506530073471367e-3,2.549999999999386e-3,5616196,260,null,null,null,null,null,null,null],[2.2970070131123066e-3,2.2969999999986612e-3,5057468,273,null,null,null,null,null,null,null],[1.6899800102692097e-3,1.6899999999999693e-3,3719422,287,null,null,null,null,null,null,null],[1.6853169945534319e-3,1.685000000001935e-3,3710062,301,null,null,null,null,null,null,null],[1.7685160273686051e-3,1.7689999999959127e-3,3893132,316,null,null,null,null,null,null,null],[1.8841699929907918e-3,1.8840000000039936e-3,4148350,332,null,null,null,null,null,null,null],[1.967624993994832e-3,1.968000000001524e-3,4331382,348,null,null,null,null,null,null,null],[2.070051006739959e-3,2.071000000000822e-3,4557810,366,null,null,null,null,null,null,null],[2.2437869920395315e-3,2.244000000001023e-3,4939180,384,null,null,null,null,null,null,null],[2.3195589892566204e-3,2.3200000000045407e-3,5105946,403,null,null,null,null,null,null,null],[2.407151012448594e-3,2.4070000000016023e-3,5299018,424,null,null,null,null,null,null,null],[2.4934629909694195e-3,2.493999999998664e-3,5488202,445,null,null,null,null,null,null,null],[2.6152189821004868e-3,2.6149999999987017e-3,5756172,467,null,null,null,null,null,null,null],[2.7877530083060265e-3,2.7879999999989025e-3,6135626,490,null,null,null,null,null,null,null],[2.930979011580348e-3,2.9309999999966863e-3,6451144,515,null,null,null,null,null,null,null],[3.0264430097304285e-3,3.026999999999447e-3,6660530,541,null,null,null,null,null,null,null],[3.2948110019788146e-3,3.294000000000352e-3,7251814,568,null,null,null,null,null,null,null],[6.4053990063257515e-3,6.394000000000233e-3,14112053,596,null,null,null,null,null,null,null],[6.478453986346722e-3,6.478999999998791e-3,14255058,626,null,null,null,null,null,null,null],[4.399085009936243e-3,4.400000000000404e-3,9679508,657,null,null,null,null,null,null,null],[3.958804998546839e-3,3.9589999999982695e-3,8695766,690,null,null,null,null,null,null,null],[4.216228990117088e-3,4.216999999997029e-3,9279334,725,null,null,null,null,null,null,null],[4.354687000159174e-3,4.35399999999575e-3,9582880,761,null,null,null,null,null,null,null],[4.501119983615354e-3,4.5010000000011985e-3,9905912,799,null,null,null,null,null,null,null],[4.693536990089342e-3,4.694000000000642e-3,10328432,839,null,null,null,null,null,null,null],[5.079226975794882e-3,5.079000000002054e-3,11177696,881,null,null,null,null,null,null,null],[5.232052004430443e-3,5.232000000003012e-3,11513176,925,null,null,null,null,null,null,null],[5.49678600509651e-3,5.4970000000018615e-3,12096228,972,null,null,null,null,null,null,null],[5.7394739997107536e-3,5.738999999998384e-3,12629984,1020,null,null,null,null,null,null,null],[1.1832910007797182e-2,1.1796000000003914e-2,26047836,1071,null,null,null,null,null,null,null],[8.19906999822706e-3,8.198999999997625e-3,18038404,1125,null,null,null,null,null,null,null],[1.2609456985956058e-2,1.2579999999999814e-2,27754164,1181,null,null,null,null,null,null,null],[7.599675009259954e-3,7.600000000000051e-3,16720070,1240,null,null,null,null,null,null,null],[1.6028228012146428e-2,1.601399999999842e-2,35279046,1302,null,null,null,null,null,null,null],[1.1054695001803339e-2,1.1053999999997899e-2,24319994,1367,null,null,null,null,null,null,null],[8.091145980870351e-3,8.091000000000292e-3,17803348,1436,null,null,null,null,null,null,null],[8.520992007106543e-3,8.49099999999936e-3,18749474,1507,null,null,null,null,null,null,null],[8.926548005547374e-3,8.926999999996355e-3,19641570,1583,null,null,null,null,null,null,null],[9.448324999539182e-3,9.426000000001267e-3,20790340,1662,null,null,null,null,null,null,null],[9.836914017796516e-3,9.837000000000984e-3,21644446,1745,null,null,null,null,null,null,null],[1.0448998975334689e-2,1.044899999999771e-2,22991020,1832,null,null,null,null,null,null,null],[1.1087464983575046e-2,1.1088000000000875e-2,24395736,1924,null,null,null,null,null,null,null],[1.1767855001380667e-2,1.1768999999997476e-2,25892502,2020,null,null,null,null,null,null,null],[1.8973044003359973e-2,1.8944999999998657e-2,41748136,2121,null,null,null,null,null,null,null],[1.3305653992574662e-2,1.3276999999998651e-2,29280832,2227,null,null,null,null,null,null,null],[1.4363627997227013e-2,1.4362999999995907e-2,31603222,2339,null,null,null,null,null,null,null],[1.5047146996948868e-2,1.5046999999995592e-2,33106548,2456,null,null,null,null,null,null,null],[1.5299685997888446e-2,1.5298999999998841e-2,33663090,2579,null,null,null,null,null,null,null],[1.625170899205841e-2,1.6251999999997935e-2,35756926,2708,null,null,null,null,null,null,null],[1.6641148016788065e-2,1.6639999999998878e-2,36613858,2843,null,null,null,null,null,null,null],[2.9095820005750284e-2,2.9052999999997553e-2,64018498,2985,null,null,null,null,null,null,null],[1.782830199226737e-2,1.7825000000001978e-2,39229460,3134,null,null,null,null,null,null,null],[1.8584322009701282e-2,1.8580999999997516e-2,40888542,3291,null,null,null,null,null,null,null],[1.9624890002887696e-2,1.9597000000000975e-2,43178448,3456,null,null,null,null,null,null,null],[2.060321602039039e-2,2.0603999999998734e-2,45331722,3629,null,null,null,null,null,null,null],[2.4888608983019367e-2,2.4851000000001733e-2,54775375,3810,null,null,null,null,null,null,null],[2.6372749009169638e-2,2.6371999999998508e-2,58019509,4001,null,null,null,null,null,null,null],[2.4860880977939814e-2,2.48609999999978e-2,54697508,4201,null,null,null,null,null,null,null],[3.230335199623369e-2,3.2272999999999996e-2,71075466,4411,null,null,null,null,null,null,null],[2.7945836016442627e-2,2.7947000000001054e-2,61483632,4631,null,null,null,null,null,null,null],[2.8607924992684275e-2,2.8607999999998412e-2,62941524,4863,null,null,null,null,null,null,null],[3.784891200484708e-2,3.781399999999735e-2,83274606,5106,null,null,null,null,null,null,null],[3.114457501214929e-2,3.114400000000117e-2,68520162,5361,null,null,null,null,null,null,null],[3.81150130124297e-2,3.8105999999999085e-2,83865052,5629,null,null,null,null,null,null,null],[4.0344114997424185e-2,4.028300000000229e-2,88766724,5911,null,null,null,null,null,null,null],[4.1936466994229704e-2,4.193100000000172e-2,92265938,6207,null,null,null,null,null,null,null],[3.819815398310311e-2,3.8198000000001286e-2,84039102,6517,null,null,null,null,null,null,null],[4.4795522990170866e-2,4.479100000000358e-2,98561988,6843,null,null,null,null,null,null,null],[4.483502599759959e-2,4.4818999999996834e-2,98638784,7185,null,null,null,null,null,null,null],[4.459751900867559e-2,4.459800000000058e-2,98118968,7544,null,null,null,null,null,null,null],[5.219911300810054e-2,5.216699999999719e-2,114848494,7921,null,null,null,null,null,null,null],[4.9044923012843356e-2,4.9045999999997036e-2,107901480,8318,null,null,null,null,null,null,null],[5.627081400598399e-2,5.623899999999793e-2,123803358,8733,null,null,null,null,null,null,null],[5.9109914989676327e-2,5.908600000000064e-2,130050316,9170,null,null,null,null,null,null,null],[5.6396361003862694e-2,5.639699999999692e-2,124075160,9629,null,null,null,null,null,null,null],[6.598068098537624e-2,6.595199999999934e-2,145164160,10110,null,null,null,null,null,null,null],[6.0812023002654314e-2,6.081299999999601e-2,133789582,10616,null,null,null,null,null,null,null],[7.374249398708344e-2,7.368299999999905e-2,162239292,11146,null,null,null,null,null,null,null],[6.807770600426011e-2,6.807900000000444e-2,149773732,11704,null,null,null,null,null,null,null],[7.960463801282458e-2,7.95600000000043e-2,175137678,12289,null,null,null,null,null,null,null],[0.10123207702417858,0.10112399999999866,222717630,12903,null,null,null,null,null,null,null],[8.555627497844398e-2,8.551399999999987e-2,188229906,13549,null,null,null,null,null,null,null],[9.03350849985145e-2,9.030399999999972e-2,198744208,14226,null,null,null,null,null,null,null],[9.294863900868222e-2,9.287099999999882e-2,204500974,14937,null,null,null,null,null,null,null],[0.1069848730112426,0.10691300000000226,235371716,15684,null,null,null,null,null,null,null],[0.10382141199079342,0.10372500000000073,228413170,16469,null,null,null,null,null,null,null],[0.11392678300035186,0.11385299999999887,250646416,17292,null,null,null,null,null,null,null],[0.11803226202027872,0.11797100000000071,259677136,18157,null,null,null,null,null,null,null],[0.11511843200423755,0.11508900000000111,253276939,19065,null,null,null,null,null,null,null],[0.12226728399400599,0.12199500000000185,268993077,20018,null,null,null,null,null,null,null],[0.13388311900780536,0.133782999999994,294549236,21019,null,null,null,null,null,null,null],[0.15753770200535655,0.15747500000000159,346590682,22070,null,null,null,null,null,null,null],[0.15844429598655552,0.15832499999999783,348586922,23173,null,null,null,null,null,null,null],[0.14716985099948943,0.14712199999999598,323779030,24332,null,null,null,null,null,null,null],[0.1584885419870261,0.1583970000000008,348684024,25549,null,null,null,null,null,null,null],[0.18314656100119464,0.1830260000000017,402931052,26826,null,null,null,null,null,null,null],[0.17360069099231623,0.17351400000000083,381927764,28167,null,null,null,null,null,null,null],[0.21337309398222715,0.21314599999999828,469427278,29576,null,null,null,null,null,null,null],[0.22101753499009646,0.2208749999999995,486249474,31054,null,null,null,null,null,null,null],[0.19837291300063953,0.19831999999999894,436431460,32607,null,null,null,null,null,null,null],[0.2344874179980252,0.23431000000000068,515879454,34238,null,null,null,null,null,null,null],[0.25332475802861154,0.2530089999999987,557328324,35950,null,null,null,null,null,null,null]]}];+ reports.map(mangulate);++ var benches = ["fib/1","fib/5","fib/9","fib/11",];+ var ylabels = [[-0,'<a href="#b0">fib/1</a>'],[-1,'<a href="#b1">fib/5</a>'],[-2,'<a href="#b2">fib/9</a>'],[-3,'<a href="#b3">fib/11</a>'],];+ var means = $.scaleTimes([2.374225969306158e-8,3.7647973827317373e-7,2.614524699113428e-6,6.496202868182492e-6,]);+ var xs = [];+ var prev = null;+ for (var i = 0; i < means[0].length; i++) {+ var name = benches[i].split(/\//);+ name.pop();+ name = name.join('/');+ if (name != prev) {+ xs.push({ label: name, data: [[means[0][i], -i]]});+ prev = name;+ }+ else+ xs[xs.length-1].data.push([means[0][i],-i]);+ }+ var oq = $("#overview");+ o = $.plot(oq, xs, { bars: { show: true, horizontal: true,+ barWidth: 0.75, align: "center" },+ grid: { borderColor: "#777", hoverable: true },+ legend: { show: xs.length > 1 },+ xaxis: { max: Math.max.apply(undefined,means[0]) * 1.02 },+ yaxis: { ticks: ylabels, tickColor: '#ffffff' } });+ if (benches.length > 3)+ o.getPlaceholder().height(28*benches.length);+ o.resize();+ o.setupGrid();+ o.draw();+ $.addTooltip("#overview", function(x,y) { return $.renderTime(x / means[1]); });+});+$(document).ready(function () {+ $(".time").text(function(_, text) {+ return $.renderTime(text);+ });+ $(".citime").text(function(_, text) {+ return $.renderTime(text);+ });+ $(".percent").text(function(_, text) {+ return (text*100).toFixed(1);+ });+ });+</script>++ </div>+ </div>+ <div id="footer">+ <div class="body">+ <div class="footfirst">+ <h2>colophon</h2>+ <p>This report was created using the+ <a href="http://hackage.haskell.org/package/criterion">criterion</a>+ benchmark execution and performance analysis tool.</p>+ <p>Criterion is developed and maintained+ by <a href="http://www.serpentine.com/blog/">Bryan O'Sullivan</a>.</p>+ </div>+ </div>+ </div>+ </body>+</html>
+ examples/maps.html view
@@ -0,0 +1,552 @@+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">+<html>+ <head>+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8">+ <title>criterion report</title>+ <script language="javascript" type="text/javascript">+ /*! jQuery v2.1.1 | (c) 2005, 2014 jQuery Foundation, Inc. | jquery.org/license */+!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=c.slice,e=c.concat,f=c.push,g=c.indexOf,h={},i=h.toString,j=h.hasOwnProperty,k={},l=a.document,m="2.1.1",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return d.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:d.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a,b){return n.each(this,a,b)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(d.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:f,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(a=arguments[h]))for(b in a)c=g[b],d=a[b],g!==d&&(j&&d&&(n.isPlainObject(d)||(e=n.isArray(d)))?(e?(e=!1,f=c&&n.isArray(c)?c:[]):f=c&&n.isPlainObject(c)?c:{},g[b]=n.extend(j,f,d)):void 0!==d&&(g[b]=d));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray,isWindow:function(a){return null!=a&&a===a.window},isNumeric:function(a){return!n.isArray(a)&&a-parseFloat(a)>=0},isPlainObject:function(a){return"object"!==n.type(a)||a.nodeType||n.isWindow(a)?!1:a.constructor&&!j.call(a.constructor.prototype,"isPrototypeOf")?!1:!0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?h[i.call(a)]||"object":typeof a},globalEval:function(a){var b,c=eval;a=n.trim(a),a&&(1===a.indexOf("use strict")?(b=l.createElement("script"),b.text=a,l.head.appendChild(b).parentNode.removeChild(b)):c(a))},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b,c){var d,e=0,f=a.length,g=s(a);if(c){if(g){for(;f>e;e++)if(d=b.apply(a[e],c),d===!1)break}else for(e in a)if(d=b.apply(a[e],c),d===!1)break}else if(g){for(;f>e;e++)if(d=b.call(a[e],e,a[e]),d===!1)break}else for(e in a)if(d=b.call(a[e],e,a[e]),d===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):f.call(c,a)),c},inArray:function(a,b,c){return null==b?-1:g.call(b,a,c)},merge:function(a,b){for(var c=+b.length,d=0,e=a.length;c>d;d++)a[e++]=b[d];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,f=0,g=a.length,h=s(a),i=[];if(h)for(;g>f;f++)d=b(a[f],f,c),null!=d&&i.push(d);else for(f in a)d=b(a[f],f,c),null!=d&&i.push(d);return e.apply([],i)},guid:1,proxy:function(a,b){var c,e,f;return"string"==typeof b&&(c=a[b],b=a,a=c),n.isFunction(a)?(e=d.call(arguments,2),f=function(){return a.apply(b||this,e.concat(d.call(arguments)))},f.guid=a.guid=a.guid||n.guid++,f):void 0},now:Date.now,support:k}),n.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(a,b){h["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:1===a.nodeType&&b?!0:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+-new Date,v=a.document,w=0,x=0,y=gb(),z=gb(),A=gb(),B=function(a,b){return a===b&&(l=!0),0},C="undefined",D=1<<31,E={}.hasOwnProperty,F=[],G=F.pop,H=F.push,I=F.push,J=F.slice,K=F.indexOf||function(a){for(var b=0,c=this.length;c>b;b++)if(this[b]===a)return b;return-1},L="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",N="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",O=N.replace("w","w#"),P="\\["+M+"*("+N+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+O+"))|)"+M+"*\\]",Q=":("+N+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+P+")*)|.*)\\)|)",R=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),S=new RegExp("^"+M+"*,"+M+"*"),T=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),U=new RegExp("="+M+"*([^\\]'\"]*?)"+M+"*\\]","g"),V=new RegExp(Q),W=new RegExp("^"+O+"$"),X={ID:new RegExp("^#("+N+")"),CLASS:new RegExp("^\\.("+N+")"),TAG:new RegExp("^("+N.replace("w","w*")+")"),ATTR:new RegExp("^"+P),PSEUDO:new RegExp("^"+Q),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+L+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/^(?:input|select|textarea|button)$/i,Z=/^h\d$/i,$=/^[^{]+\{\s*\[native \w/,_=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ab=/[+~]/,bb=/'|\\/g,cb=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),db=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)};try{I.apply(F=J.call(v.childNodes),v.childNodes),F[v.childNodes.length].nodeType}catch(eb){I={apply:F.length?function(a,b){H.apply(a,J.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function fb(a,b,d,e){var f,h,j,k,l,o,r,s,w,x;if((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,d=d||[],!a||"string"!=typeof a)return d;if(1!==(k=b.nodeType)&&9!==k)return[];if(p&&!e){if(f=_.exec(a))if(j=f[1]){if(9===k){if(h=b.getElementById(j),!h||!h.parentNode)return d;if(h.id===j)return d.push(h),d}else if(b.ownerDocument&&(h=b.ownerDocument.getElementById(j))&&t(b,h)&&h.id===j)return d.push(h),d}else{if(f[2])return I.apply(d,b.getElementsByTagName(a)),d;if((j=f[3])&&c.getElementsByClassName&&b.getElementsByClassName)return I.apply(d,b.getElementsByClassName(j)),d}if(c.qsa&&(!q||!q.test(a))){if(s=r=u,w=b,x=9===k&&a,1===k&&"object"!==b.nodeName.toLowerCase()){o=g(a),(r=b.getAttribute("id"))?s=r.replace(bb,"\\$&"):b.setAttribute("id",s),s="[id='"+s+"'] ",l=o.length;while(l--)o[l]=s+qb(o[l]);w=ab.test(a)&&ob(b.parentNode)||b,x=o.join(",")}if(x)try{return I.apply(d,w.querySelectorAll(x)),d}catch(y){}finally{r||b.removeAttribute("id")}}}return i(a.replace(R,"$1"),b,d,e)}function gb(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function hb(a){return a[u]=!0,a}function ib(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function jb(a,b){var c=a.split("|"),e=a.length;while(e--)d.attrHandle[c[e]]=b}function kb(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||D)-(~a.sourceIndex||D);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function lb(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function mb(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function nb(a){return hb(function(b){return b=+b,hb(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function ob(a){return a&&typeof a.getElementsByTagName!==C&&a}c=fb.support={},f=fb.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=fb.setDocument=function(a){var b,e=a?a.ownerDocument||a:v,g=e.defaultView;return e!==n&&9===e.nodeType&&e.documentElement?(n=e,o=e.documentElement,p=!f(e),g&&g!==g.top&&(g.addEventListener?g.addEventListener("unload",function(){m()},!1):g.attachEvent&&g.attachEvent("onunload",function(){m()})),c.attributes=ib(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ib(function(a){return a.appendChild(e.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=$.test(e.getElementsByClassName)&&ib(function(a){return a.innerHTML="<div class='a'></div><div class='a i'></div>",a.firstChild.className="i",2===a.getElementsByClassName("i").length}),c.getById=ib(function(a){return o.appendChild(a).id=u,!e.getElementsByName||!e.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if(typeof b.getElementById!==C&&p){var c=b.getElementById(a);return c&&c.parentNode?[c]:[]}},d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){var c=typeof a.getAttributeNode!==C&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return typeof b.getElementsByTagName!==C?b.getElementsByTagName(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return typeof b.getElementsByClassName!==C&&p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=$.test(e.querySelectorAll))&&(ib(function(a){a.innerHTML="<select msallowclip=''><option selected=''></option></select>",a.querySelectorAll("[msallowclip^='']").length&&q.push("[*^$]="+M+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+M+"*(?:value|"+L+")"),a.querySelectorAll(":checked").length||q.push(":checked")}),ib(function(a){var b=e.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+M+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=$.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ib(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",Q)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=$.test(o.compareDocumentPosition),t=b||$.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===e||a.ownerDocument===v&&t(v,a)?-1:b===e||b.ownerDocument===v&&t(v,b)?1:k?K.call(k,a)-K.call(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,f=a.parentNode,g=b.parentNode,h=[a],i=[b];if(!f||!g)return a===e?-1:b===e?1:f?-1:g?1:k?K.call(k,a)-K.call(k,b):0;if(f===g)return kb(a,b);c=a;while(c=c.parentNode)h.unshift(c);c=b;while(c=c.parentNode)i.unshift(c);while(h[d]===i[d])d++;return d?kb(h[d],i[d]):h[d]===v?-1:i[d]===v?1:0},e):n},fb.matches=function(a,b){return fb(a,null,null,b)},fb.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(U,"='$1']"),!(!c.matchesSelector||!p||r&&r.test(b)||q&&q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return fb(b,n,null,[a]).length>0},fb.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},fb.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&E.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},fb.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},fb.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=fb.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=fb.selectors={cacheLength:50,createPseudo:hb,match:X,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(cb,db),a[3]=(a[3]||a[4]||a[5]||"").replace(cb,db),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||fb.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&fb.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return X.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&V.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(cb,db).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+M+")"+a+"("+M+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||typeof a.getAttribute!==C&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=fb.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h;if(q){if(f){while(p){l=b;while(l=l[p])if(h?l.nodeName.toLowerCase()===r:1===l.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){k=q[u]||(q[u]={}),j=k[a]||[],n=j[0]===w&&j[1],m=j[0]===w&&j[2],l=n&&q.childNodes[n];while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if(1===l.nodeType&&++m&&l===b){k[a]=[w,n,m];break}}else if(s&&(j=(b[u]||(b[u]={}))[a])&&j[0]===w)m=j[1];else while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if((h?l.nodeName.toLowerCase()===r:1===l.nodeType)&&++m&&(s&&((l[u]||(l[u]={}))[a]=[w,m]),l===b))break;return m-=e,m===d||m%d===0&&m/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||fb.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?hb(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=K.call(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:hb(function(a){var b=[],c=[],d=h(a.replace(R,"$1"));return d[u]?hb(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),!c.pop()}}),has:hb(function(a){return function(b){return fb(a,b).length>0}}),contains:hb(function(a){return function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:hb(function(a){return W.test(a||"")||fb.error("unsupported lang: "+a),a=a.replace(cb,db).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Z.test(a.nodeName)},input:function(a){return Y.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:nb(function(){return[0]}),last:nb(function(a,b){return[b-1]}),eq:nb(function(a,b,c){return[0>c?c+b:c]}),even:nb(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:nb(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:nb(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:nb(function(a,b,c){for(var d=0>c?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=lb(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=mb(b);function pb(){}pb.prototype=d.filters=d.pseudos,d.setFilters=new pb,g=fb.tokenize=function(a,b){var c,e,f,g,h,i,j,k=z[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){(!c||(e=S.exec(h)))&&(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=T.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(R," ")}),h=h.slice(c.length));for(g in d.filter)!(e=X[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?fb.error(a):z(a,i).slice(0)};function qb(a){for(var b=0,c=a.length,d="";c>b;b++)d+=a[b].value;return d}function rb(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(i=b[u]||(b[u]={}),(h=i[d])&&h[0]===w&&h[1]===f)return j[2]=h[2];if(i[d]=j,j[2]=a(b,c,g))return!0}}}function sb(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function tb(a,b,c){for(var d=0,e=b.length;e>d;d++)fb(a,b[d],c);return c}function ub(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(!c||c(f,d,e))&&(g.push(f),j&&b.push(h));return g}function vb(a,b,c,d,e,f){return d&&!d[u]&&(d=vb(d)),e&&!e[u]&&(e=vb(e,f)),hb(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||tb(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:ub(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=ub(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?K.call(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=ub(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):I.apply(g,r)})}function wb(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=rb(function(a){return a===b},h,!0),l=rb(function(a){return K.call(b,a)>-1},h,!0),m=[function(a,c,d){return!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d))}];f>i;i++)if(c=d.relative[a[i].type])m=[rb(sb(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return vb(i>1&&sb(m),i>1&&qb(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(R,"$1"),c,e>i&&wb(a.slice(i,e)),f>e&&wb(a=a.slice(e)),f>e&&qb(a))}m.push(c)}return sb(m)}function xb(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,m,o,p=0,q="0",r=f&&[],s=[],t=j,u=f||e&&d.find.TAG("*",k),v=w+=null==t?1:Math.random()||.1,x=u.length;for(k&&(j=g!==n&&g);q!==x&&null!=(l=u[q]);q++){if(e&&l){m=0;while(o=a[m++])if(o(l,g,h)){i.push(l);break}k&&(w=v)}c&&((l=!o&&l)&&p--,f&&r.push(l))}if(p+=q,c&&q!==p){m=0;while(o=b[m++])o(r,s,g,h);if(f){if(p>0)while(q--)r[q]||s[q]||(s[q]=G.call(i));s=ub(s)}I.apply(i,s),k&&!f&&s.length>0&&p+b.length>1&&fb.uniqueSort(i)}return k&&(w=v,j=t),r};return c?hb(f):f}return h=fb.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=wb(b[c]),f[u]?d.push(f):e.push(f);f=A(a,xb(e,d)),f.selector=a}return f},i=fb.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(cb,db),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=X.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(cb,db),ab.test(j[0].type)&&ob(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&qb(j),!a)return I.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,ab.test(a)&&ob(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ib(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ib(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||jb("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ib(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||jb("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ib(function(a){return null==a.getAttribute("disabled")})||jb(L,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),fb}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=n.expr.match.needsContext,v=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,w=/^.[^:#\[\.,]*$/;function x(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(w.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return g.call(b,a)>=0!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=this.length,d=[],e=this;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;c>b;b++)if(n.contains(e[b],this))return!0}));for(b=0;c>b;b++)n.find(a,e[b],d);return d=this.pushStack(c>1?n.unique(d):d),d.selector=this.selector?this.selector+" "+a:a,d},filter:function(a){return this.pushStack(x(this,a||[],!1))},not:function(a){return this.pushStack(x(this,a||[],!0))},is:function(a){return!!x(this,"string"==typeof a&&u.test(a)?n(a):a||[],!1).length}});var y,z=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,A=n.fn.init=function(a,b){var c,d;if(!a)return this;if("string"==typeof a){if(c="<"===a[0]&&">"===a[a.length-1]&&a.length>=3?[null,a,null]:z.exec(a),!c||!c[1]&&b)return!b||b.jquery?(b||y).find(a):this.constructor(b).find(a);if(c[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(c[1],b&&b.nodeType?b.ownerDocument||b:l,!0)),v.test(c[1])&&n.isPlainObject(b))for(c in b)n.isFunction(this[c])?this[c](b[c]):this.attr(c,b[c]);return this}return d=l.getElementById(c[2]),d&&d.parentNode&&(this.length=1,this[0]=d),this.context=l,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?"undefined"!=typeof y.ready?y.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};A.prototype=n.fn,y=n(l);var B=/^(?:parents|prev(?:Until|All))/,C={children:!0,contents:!0,next:!0,prev:!0};n.extend({dir:function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},sibling:function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c}}),n.fn.extend({has:function(a){var b=n(a,this),c=b.length;return this.filter(function(){for(var a=0;c>a;a++)if(n.contains(this,b[a]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=u.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.unique(f):f)},index:function(a){return a?"string"==typeof a?g.call(n(a),this[0]):g.call(this,a.jquery?a[0]:a):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.unique(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function D(a,b){while((a=a[b])&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return n.dir(a,"parentNode")},parentsUntil:function(a,b,c){return n.dir(a,"parentNode",c)},next:function(a){return D(a,"nextSibling")},prev:function(a){return D(a,"previousSibling")},nextAll:function(a){return n.dir(a,"nextSibling")},prevAll:function(a){return n.dir(a,"previousSibling")},nextUntil:function(a,b,c){return n.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return n.dir(a,"previousSibling",c)},siblings:function(a){return n.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return n.sibling(a.firstChild)},contents:function(a){return a.contentDocument||n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(C[a]||n.unique(e),B.test(a)&&e.reverse()),this.pushStack(e)}});var E=/\S+/g,F={};function G(a){var b=F[a]={};return n.each(a.match(E)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?F[a]||G(a):n.extend({},a);var b,c,d,e,f,g,h=[],i=!a.once&&[],j=function(l){for(b=a.memory&&l,c=!0,g=e||0,e=0,f=h.length,d=!0;h&&f>g;g++)if(h[g].apply(l[0],l[1])===!1&&a.stopOnFalse){b=!1;break}d=!1,h&&(i?i.length&&j(i.shift()):b?h=[]:k.disable())},k={add:function(){if(h){var c=h.length;!function g(b){n.each(b,function(b,c){var d=n.type(c);"function"===d?a.unique&&k.has(c)||h.push(c):c&&c.length&&"string"!==d&&g(c)})}(arguments),d?f=h.length:b&&(e=c,j(b))}return this},remove:function(){return h&&n.each(arguments,function(a,b){var c;while((c=n.inArray(b,h,c))>-1)h.splice(c,1),d&&(f>=c&&f--,g>=c&&g--)}),this},has:function(a){return a?n.inArray(a,h)>-1:!(!h||!h.length)},empty:function(){return h=[],f=0,this},disable:function(){return h=i=b=void 0,this},disabled:function(){return!h},lock:function(){return i=void 0,b||k.disable(),this},locked:function(){return!i},fireWith:function(a,b){return!h||c&&!i||(b=b||[],b=[a,b.slice?b.slice():b],d?i.push(b):j(b)),this},fire:function(){return k.fireWith(this,arguments),this},fired:function(){return!!c}};return k},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=d.call(arguments),e=c.length,f=1!==e||a&&n.isFunction(a.promise)?e:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(e){b[a]=this,c[a]=arguments.length>1?d.call(arguments):e,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(e>1)for(i=new Array(e),j=new Array(e),k=new Array(e);e>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().done(h(b,k,c)).fail(g.reject).progress(h(b,j,i)):--f;return f||g.resolveWith(k,c),g.promise()}});var H;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){(a===!0?--n.readyWait:n.isReady)||(n.isReady=!0,a!==!0&&--n.readyWait>0||(H.resolveWith(l,[n]),n.fn.triggerHandler&&(n(l).triggerHandler("ready"),n(l).off("ready"))))}});function I(){l.removeEventListener("DOMContentLoaded",I,!1),a.removeEventListener("load",I,!1),n.ready()}n.ready.promise=function(b){return H||(H=n.Deferred(),"complete"===l.readyState?setTimeout(n.ready):(l.addEventListener("DOMContentLoaded",I,!1),a.addEventListener("load",I,!1))),H.promise(b)},n.ready.promise();var J=n.access=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===n.type(c)){e=!0;for(h in c)n.access(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,n.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(n(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f};n.acceptData=function(a){return 1===a.nodeType||9===a.nodeType||!+a.nodeType};function K(){Object.defineProperty(this.cache={},0,{get:function(){return{}}}),this.expando=n.expando+Math.random()}K.uid=1,K.accepts=n.acceptData,K.prototype={key:function(a){if(!K.accepts(a))return 0;var b={},c=a[this.expando];if(!c){c=K.uid++;try{b[this.expando]={value:c},Object.defineProperties(a,b)}catch(d){b[this.expando]=c,n.extend(a,b)}}return this.cache[c]||(this.cache[c]={}),c},set:function(a,b,c){var d,e=this.key(a),f=this.cache[e];if("string"==typeof b)f[b]=c;else if(n.isEmptyObject(f))n.extend(this.cache[e],b);else for(d in b)f[d]=b[d];return f},get:function(a,b){var c=this.cache[this.key(a)];return void 0===b?c:c[b]},access:function(a,b,c){var d;return void 0===b||b&&"string"==typeof b&&void 0===c?(d=this.get(a,b),void 0!==d?d:this.get(a,n.camelCase(b))):(this.set(a,b,c),void 0!==c?c:b)},remove:function(a,b){var c,d,e,f=this.key(a),g=this.cache[f];if(void 0===b)this.cache[f]={};else{n.isArray(b)?d=b.concat(b.map(n.camelCase)):(e=n.camelCase(b),b in g?d=[b,e]:(d=e,d=d in g?[d]:d.match(E)||[])),c=d.length;while(c--)delete g[d[c]]}},hasData:function(a){return!n.isEmptyObject(this.cache[a[this.expando]]||{})},discard:function(a){a[this.expando]&&delete this.cache[a[this.expando]]}};var L=new K,M=new K,N=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function P(a,b,c){var d;if(void 0===c&&1===a.nodeType)if(d="data-"+b.replace(O,"-$1").toLowerCase(),c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:N.test(c)?n.parseJSON(c):c}catch(e){}M.set(a,b,c)}else c=void 0;return c}n.extend({hasData:function(a){return M.hasData(a)||L.hasData(a)},data:function(a,b,c){return M.access(a,b,c)},removeData:function(a,b){M.remove(a,b)+},_data:function(a,b,c){return L.access(a,b,c)},_removeData:function(a,b){L.remove(a,b)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=M.get(f),1===f.nodeType&&!L.get(f,"hasDataAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),P(f,d,e[d])));L.set(f,"hasDataAttrs",!0)}return e}return"object"==typeof a?this.each(function(){M.set(this,a)}):J(this,function(b){var c,d=n.camelCase(a);if(f&&void 0===b){if(c=M.get(f,a),void 0!==c)return c;if(c=M.get(f,d),void 0!==c)return c;if(c=P(f,d,void 0),void 0!==c)return c}else this.each(function(){var c=M.get(this,d);M.set(this,d,b),-1!==a.indexOf("-")&&void 0!==c&&M.set(this,a,b)})},null,b,arguments.length>1,null,!0)},removeData:function(a){return this.each(function(){M.remove(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=L.get(a,b),c&&(!d||n.isArray(c)?d=L.access(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return L.get(a,c)||L.access(a,c,{empty:n.Callbacks("once memory").add(function(){L.remove(a,[b+"queue",c])})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?n.queue(this[0],a):void 0===b?this:this.each(function(){var c=n.queue(this,a,b);n._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&n.dequeue(this,a)})},dequeue:function(a){return this.each(function(){n.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=n.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=L.get(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}});var Q=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,R=["Top","Right","Bottom","Left"],S=function(a,b){return a=b||a,"none"===n.css(a,"display")||!n.contains(a.ownerDocument,a)},T=/^(?:checkbox|radio)$/i;!function(){var a=l.createDocumentFragment(),b=a.appendChild(l.createElement("div")),c=l.createElement("input");c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),b.appendChild(c),k.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,b.innerHTML="<textarea>x</textarea>",k.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue}();var U="undefined";k.focusinBubbles="onfocusin"in a;var V=/^key/,W=/^(?:mouse|pointer|contextmenu)|click/,X=/^(?:focusinfocus|focusoutblur)$/,Y=/^([^.]*)(?:\.(.+)|)$/;function Z(){return!0}function $(){return!1}function _(){try{return l.activeElement}catch(a){}}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.get(a);if(r){c.handler&&(f=c,c=f.handler,e=f.selector),c.guid||(c.guid=n.guid++),(i=r.events)||(i=r.events={}),(g=r.handle)||(g=r.handle=function(b){return typeof n!==U&&n.event.triggered!==b.type?n.event.dispatch.apply(a,arguments):void 0}),b=(b||"").match(E)||[""],j=b.length;while(j--)h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o&&(l=n.event.special[o]||{},o=(e?l.delegateType:l.bindType)||o,l=n.event.special[o]||{},k=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},f),(m=i[o])||(m=i[o]=[],m.delegateCount=0,l.setup&&l.setup.call(a,d,p,g)!==!1||a.addEventListener&&a.addEventListener(o,g,!1)),l.add&&(l.add.call(a,k),k.handler.guid||(k.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,k):m.push(k),n.event.global[o]=!0)}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.hasData(a)&&L.get(a);if(r&&(i=r.events)){b=(b||"").match(E)||[""],j=b.length;while(j--)if(h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=i[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),g=f=m.length;while(f--)k=m[f],!e&&q!==k.origType||c&&c.guid!==k.guid||h&&!h.test(k.namespace)||d&&d!==k.selector&&("**"!==d||!k.selector)||(m.splice(f,1),k.selector&&m.delegateCount--,l.remove&&l.remove.call(a,k));g&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete i[o])}else for(o in i)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(i)&&(delete r.handle,L.remove(a,"events"))}},trigger:function(b,c,d,e){var f,g,h,i,k,m,o,p=[d||l],q=j.call(b,"type")?b.type:b,r=j.call(b,"namespace")?b.namespace.split("."):[];if(g=h=d=d||l,3!==d.nodeType&&8!==d.nodeType&&!X.test(q+n.event.triggered)&&(q.indexOf(".")>=0&&(r=q.split("."),q=r.shift(),r.sort()),k=q.indexOf(":")<0&&"on"+q,b=b[n.expando]?b:new n.Event(q,"object"==typeof b&&b),b.isTrigger=e?2:3,b.namespace=r.join("."),b.namespace_re=b.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=d),c=null==c?[b]:n.makeArray(c,[b]),o=n.event.special[q]||{},e||!o.trigger||o.trigger.apply(d,c)!==!1)){if(!e&&!o.noBubble&&!n.isWindow(d)){for(i=o.delegateType||q,X.test(i+q)||(g=g.parentNode);g;g=g.parentNode)p.push(g),h=g;h===(d.ownerDocument||l)&&p.push(h.defaultView||h.parentWindow||a)}f=0;while((g=p[f++])&&!b.isPropagationStopped())b.type=f>1?i:o.bindType||q,m=(L.get(g,"events")||{})[b.type]&&L.get(g,"handle"),m&&m.apply(g,c),m=k&&g[k],m&&m.apply&&n.acceptData(g)&&(b.result=m.apply(g,c),b.result===!1&&b.preventDefault());return b.type=q,e||b.isDefaultPrevented()||o._default&&o._default.apply(p.pop(),c)!==!1||!n.acceptData(d)||k&&n.isFunction(d[q])&&!n.isWindow(d)&&(h=d[k],h&&(d[k]=null),n.event.triggered=q,d[q](),n.event.triggered=void 0,h&&(d[k]=h)),b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,e,f,g,h=[],i=d.call(arguments),j=(L.get(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())(!a.namespace_re||a.namespace_re.test(g.namespace))&&(a.handleObj=g,a.data=g.data,e=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==e&&(a.result=e)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&(!a.button||"click"!==a.type))for(;i!==this;i=i.parentNode||this)if(i.disabled!==!0||"click"!==a.type){for(d=[],c=0;h>c;c++)f=b[c],e=f.selector+" ",void 0===d[e]&&(d[e]=f.needsContext?n(e,this).index(i)>=0:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h<b.length&&g.push({elem:this,handlers:b.slice(h)}),g},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,b){var c,d,e,f=b.button;return null==a.pageX&&null!=b.clientX&&(c=a.target.ownerDocument||l,d=c.documentElement,e=c.body,a.pageX=b.clientX+(d&&d.scrollLeft||e&&e.scrollLeft||0)-(d&&d.clientLeft||e&&e.clientLeft||0),a.pageY=b.clientY+(d&&d.scrollTop||e&&e.scrollTop||0)-(d&&d.clientTop||e&&e.clientTop||0)),a.which||void 0===f||(a.which=1&f?1:2&f?3:4&f?2:0),a}},fix:function(a){if(a[n.expando])return a;var b,c,d,e=a.type,f=a,g=this.fixHooks[e];g||(this.fixHooks[e]=g=W.test(e)?this.mouseHooks:V.test(e)?this.keyHooks:{}),d=g.props?this.props.concat(g.props):this.props,a=new n.Event(f),b=d.length;while(b--)c=d[b],a[c]=f[c];return a.target||(a.target=l),3===a.target.nodeType&&(a.target=a.target.parentNode),g.filter?g.filter(a,f):a},special:{load:{noBubble:!0},focus:{trigger:function(){return this!==_()&&this.focus?(this.focus(),!1):void 0},delegateType:"focusin"},blur:{trigger:function(){return this===_()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return"checkbox"===this.type&&this.click&&n.nodeName(this,"input")?(this.click(),!1):void 0},_default:function(a){return n.nodeName(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&a.originalEvent&&(a.originalEvent.returnValue=a.result)}}},simulate:function(a,b,c,d){var e=n.extend(new n.Event,c,{type:a,isSimulated:!0,originalEvent:{}});d?n.event.trigger(e,null,b):n.event.dispatch.call(b,e),e.isDefaultPrevented()&&c.preventDefault()}},n.removeEvent=function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)},n.Event=function(a,b){return this instanceof n.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&a.returnValue===!1?Z:$):this.type=a,b&&n.extend(this,b),this.timeStamp=a&&a.timeStamp||n.now(),void(this[n.expando]=!0)):new n.Event(a,b)},n.Event.prototype={isDefaultPrevented:$,isPropagationStopped:$,isImmediatePropagationStopped:$,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=Z,a&&a.preventDefault&&a.preventDefault()},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=Z,a&&a.stopPropagation&&a.stopPropagation()},stopImmediatePropagation:function(){var a=this.originalEvent;this.isImmediatePropagationStopped=Z,a&&a.stopImmediatePropagation&&a.stopImmediatePropagation(),this.stopPropagation()}},n.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(a,b){n.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return(!e||e!==d&&!n.contains(d,e))&&(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),k.focusinBubbles||n.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){n.event.simulate(b,a.target,n.event.fix(a),!0)};n.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=L.access(d,b);e||d.addEventListener(a,c,!0),L.access(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=L.access(d,b)-1;e?L.access(d,b,e):(d.removeEventListener(a,c,!0),L.remove(d,b))}}}),n.fn.extend({on:function(a,b,c,d,e){var f,g;if("object"==typeof a){"string"!=typeof b&&(c=c||b,b=void 0);for(g in a)this.on(g,b,c,a[g],e);return this}if(null==c&&null==d?(d=b,c=b=void 0):null==d&&("string"==typeof b?(d=c,c=void 0):(d=c,c=b,b=void 0)),d===!1)d=$;else if(!d)return this;return 1===e&&(f=d,d=function(a){return n().off(a),f.apply(this,arguments)},d.guid=f.guid||(f.guid=n.guid++)),this.each(function(){n.event.add(this,a,d,c,b)})},one:function(a,b,c,d){return this.on(a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,n(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return(b===!1||"function"==typeof b)&&(c=b,b=void 0),c===!1&&(c=$),this.each(function(){n.event.remove(this,a,c,b)})},trigger:function(a,b){return this.each(function(){n.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];return c?n.event.trigger(a,b,c,!0):void 0}});var ab=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,bb=/<([\w:]+)/,cb=/<|&#?\w+;/,db=/<(?:script|style|link)/i,eb=/checked\s*(?:[^=]|=\s*.checked.)/i,fb=/^$|\/(?:java|ecma)script/i,gb=/^true\/(.*)/,hb=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,ib={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};ib.optgroup=ib.option,ib.tbody=ib.tfoot=ib.colgroup=ib.caption=ib.thead,ib.th=ib.td;function jb(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function kb(a){return a.type=(null!==a.getAttribute("type"))+"/"+a.type,a}function lb(a){var b=gb.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function mb(a,b){for(var c=0,d=a.length;d>c;c++)L.set(a[c],"globalEval",!b||L.get(b[c],"globalEval"))}function nb(a,b){var c,d,e,f,g,h,i,j;if(1===b.nodeType){if(L.hasData(a)&&(f=L.access(a),g=L.set(b,f),j=f.events)){delete g.handle,g.events={};for(e in j)for(c=0,d=j[e].length;d>c;c++)n.event.add(b,e,j[e][c])}M.hasData(a)&&(h=M.access(a),i=n.extend({},h),M.set(b,i))}}function ob(a,b){var c=a.getElementsByTagName?a.getElementsByTagName(b||"*"):a.querySelectorAll?a.querySelectorAll(b||"*"):[];return void 0===b||b&&n.nodeName(a,b)?n.merge([a],c):c}function pb(a,b){var c=b.nodeName.toLowerCase();"input"===c&&T.test(a.type)?b.checked=a.checked:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}n.extend({clone:function(a,b,c){var d,e,f,g,h=a.cloneNode(!0),i=n.contains(a.ownerDocument,a);if(!(k.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(g=ob(h),f=ob(a),d=0,e=f.length;e>d;d++)pb(f[d],g[d]);if(b)if(c)for(f=f||ob(a),g=g||ob(h),d=0,e=f.length;e>d;d++)nb(f[d],g[d]);else nb(a,h);return g=ob(h,"script"),g.length>0&&mb(g,!i&&ob(a,"script")),h},buildFragment:function(a,b,c,d){for(var e,f,g,h,i,j,k=b.createDocumentFragment(),l=[],m=0,o=a.length;o>m;m++)if(e=a[m],e||0===e)if("object"===n.type(e))n.merge(l,e.nodeType?[e]:e);else if(cb.test(e)){f=f||k.appendChild(b.createElement("div")),g=(bb.exec(e)||["",""])[1].toLowerCase(),h=ib[g]||ib._default,f.innerHTML=h[1]+e.replace(ab,"<$1></$2>")+h[2],j=h[0];while(j--)f=f.lastChild;n.merge(l,f.childNodes),f=k.firstChild,f.textContent=""}else l.push(b.createTextNode(e));k.textContent="",m=0;while(e=l[m++])if((!d||-1===n.inArray(e,d))&&(i=n.contains(e.ownerDocument,e),f=ob(k.appendChild(e),"script"),i&&mb(f),c)){j=0;while(e=f[j++])fb.test(e.type||"")&&c.push(e)}return k},cleanData:function(a){for(var b,c,d,e,f=n.event.special,g=0;void 0!==(c=a[g]);g++){if(n.acceptData(c)&&(e=c[L.expando],e&&(b=L.cache[e]))){if(b.events)for(d in b.events)f[d]?n.event.remove(c,d):n.removeEvent(c,d,b.handle);L.cache[e]&&delete L.cache[e]}delete M.cache[c[M.expando]]}}}),n.fn.extend({text:function(a){return J(this,function(a){return void 0===a?n.text(this):this.empty().each(function(){(1===this.nodeType||11===this.nodeType||9===this.nodeType)&&(this.textContent=a)})},null,a,arguments.length)},append:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=jb(this,a);b.appendChild(a)}})},prepend:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=jb(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},remove:function(a,b){for(var c,d=a?n.filter(a,this):this,e=0;null!=(c=d[e]);e++)b||1!==c.nodeType||n.cleanData(ob(c)),c.parentNode&&(b&&n.contains(c.ownerDocument,c)&&mb(ob(c,"script")),c.parentNode.removeChild(c));return this},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)1===a.nodeType&&(n.cleanData(ob(a,!1)),a.textContent="");return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return J(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a&&1===b.nodeType)return b.innerHTML;if("string"==typeof a&&!db.test(a)&&!ib[(bb.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(ab,"<$1></$2>");try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(ob(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=arguments[0];return this.domManip(arguments,function(b){a=this.parentNode,n.cleanData(ob(this)),a&&a.replaceChild(b,this)}),a&&(a.length||a.nodeType)?this:this.remove()},detach:function(a){return this.remove(a,!0)},domManip:function(a,b){a=e.apply([],a);var c,d,f,g,h,i,j=0,l=this.length,m=this,o=l-1,p=a[0],q=n.isFunction(p);if(q||l>1&&"string"==typeof p&&!k.checkClone&&eb.test(p))return this.each(function(c){var d=m.eq(c);q&&(a[0]=p.call(this,c,d.html())),d.domManip(a,b)});if(l&&(c=n.buildFragment(a,this[0].ownerDocument,!1,this),d=c.firstChild,1===c.childNodes.length&&(c=d),d)){for(f=n.map(ob(c,"script"),kb),g=f.length;l>j;j++)h=c,j!==o&&(h=n.clone(h,!0,!0),g&&n.merge(f,ob(h,"script"))),b.call(this[j],h,j);if(g)for(i=f[f.length-1].ownerDocument,n.map(f,lb),j=0;g>j;j++)h=f[j],fb.test(h.type||"")&&!L.access(h,"globalEval")&&n.contains(i,h)&&(h.src?n._evalUrl&&n._evalUrl(h.src):n.globalEval(h.textContent.replace(hb,"")))}return this}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=[],e=n(a),g=e.length-1,h=0;g>=h;h++)c=h===g?this:this.clone(!0),n(e[h])[b](c),f.apply(d,c.get());return this.pushStack(d)}});var qb,rb={};function sb(b,c){var d,e=n(c.createElement(b)).appendTo(c.body),f=a.getDefaultComputedStyle&&(d=a.getDefaultComputedStyle(e[0]))?d.display:n.css(e[0],"display");return e.detach(),f}function tb(a){var b=l,c=rb[a];return c||(c=sb(a,b),"none"!==c&&c||(qb=(qb||n("<iframe frameborder='0' width='0' height='0'/>")).appendTo(b.documentElement),b=qb[0].contentDocument,b.write(),b.close(),c=sb(a,b),qb.detach()),rb[a]=c),c}var ub=/^margin/,vb=new RegExp("^("+Q+")(?!px)[a-z%]+$","i"),wb=function(a){return a.ownerDocument.defaultView.getComputedStyle(a,null)};function xb(a,b,c){var d,e,f,g,h=a.style;return c=c||wb(a),c&&(g=c.getPropertyValue(b)||c[b]),c&&(""!==g||n.contains(a.ownerDocument,a)||(g=n.style(a,b)),vb.test(g)&&ub.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f)),void 0!==g?g+"":g}function yb(a,b){return{get:function(){return a()?void delete this.get:(this.get=b).apply(this,arguments)}}}!function(){var b,c,d=l.documentElement,e=l.createElement("div"),f=l.createElement("div");if(f.style){f.style.backgroundClip="content-box",f.cloneNode(!0).style.backgroundClip="",k.clearCloneStyle="content-box"===f.style.backgroundClip,e.style.cssText="border:0;width:0;height:0;top:0;left:-9999px;margin-top:1px;position:absolute",e.appendChild(f);function g(){f.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",f.innerHTML="",d.appendChild(e);var g=a.getComputedStyle(f,null);b="1%"!==g.top,c="4px"===g.width,d.removeChild(e)}a.getComputedStyle&&n.extend(k,{pixelPosition:function(){return g(),b},boxSizingReliable:function(){return null==c&&g(),c},reliableMarginRight:function(){var b,c=f.appendChild(l.createElement("div"));return c.style.cssText=f.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",c.style.marginRight=c.style.width="0",f.style.width="1px",d.appendChild(e),b=!parseFloat(a.getComputedStyle(c,null).marginRight),d.removeChild(e),b}})}}(),n.swap=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e};var zb=/^(none|table(?!-c[ea]).+)/,Ab=new RegExp("^("+Q+")(.*)$","i"),Bb=new RegExp("^([+-])=("+Q+")","i"),Cb={position:"absolute",visibility:"hidden",display:"block"},Db={letterSpacing:"0",fontWeight:"400"},Eb=["Webkit","O","Moz","ms"];function Fb(a,b){if(b in a)return b;var c=b[0].toUpperCase()+b.slice(1),d=b,e=Eb.length;while(e--)if(b=Eb[e]+c,b in a)return b;return d}function Gb(a,b,c){var d=Ab.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function Hb(a,b,c,d,e){for(var f=c===(d?"border":"content")?4:"width"===b?1:0,g=0;4>f;f+=2)"margin"===c&&(g+=n.css(a,c+R[f],!0,e)),d?("content"===c&&(g-=n.css(a,"padding"+R[f],!0,e)),"margin"!==c&&(g-=n.css(a,"border"+R[f]+"Width",!0,e))):(g+=n.css(a,"padding"+R[f],!0,e),"padding"!==c&&(g+=n.css(a,"border"+R[f]+"Width",!0,e)));return g}function Ib(a,b,c){var d=!0,e="width"===b?a.offsetWidth:a.offsetHeight,f=wb(a),g="border-box"===n.css(a,"boxSizing",!1,f);if(0>=e||null==e){if(e=xb(a,b,f),(0>e||null==e)&&(e=a.style[b]),vb.test(e))return e;d=g&&(k.boxSizingReliable()||e===a.style[b]),e=parseFloat(e)||0}return e+Hb(a,b,c||(g?"border":"content"),d,f)+"px"}function Jb(a,b){for(var c,d,e,f=[],g=0,h=a.length;h>g;g++)d=a[g],d.style&&(f[g]=L.get(d,"olddisplay"),c=d.style.display,b?(f[g]||"none"!==c||(d.style.display=""),""===d.style.display&&S(d)&&(f[g]=L.access(d,"olddisplay",tb(d.nodeName)))):(e=S(d),"none"===c&&e||L.set(d,"olddisplay",e?c:n.css(d,"display"))));for(g=0;h>g;g++)d=a[g],d.style&&(b&&"none"!==d.style.display&&""!==d.style.display||(d.style.display=b?f[g]||"":"none"));return a}n.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=xb(a,"opacity");return""===c?"1":c}}}},cssNumber:{columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":"cssFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=n.camelCase(b),i=a.style;return b=n.cssProps[h]||(n.cssProps[h]=Fb(i,h)),g=n.cssHooks[b]||n.cssHooks[h],void 0===c?g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:i[b]:(f=typeof c,"string"===f&&(e=Bb.exec(c))&&(c=(e[1]+1)*e[2]+parseFloat(n.css(a,b)),f="number"),null!=c&&c===c&&("number"!==f||n.cssNumber[h]||(c+="px"),k.clearCloneStyle||""!==c||0!==b.indexOf("background")||(i[b]="inherit"),g&&"set"in g&&void 0===(c=g.set(a,c,d))||(i[b]=c)),void 0)}},css:function(a,b,c,d){var e,f,g,h=n.camelCase(b);return b=n.cssProps[h]||(n.cssProps[h]=Fb(a.style,h)),g=n.cssHooks[b]||n.cssHooks[h],g&&"get"in g&&(e=g.get(a,!0,c)),void 0===e&&(e=xb(a,b,d)),"normal"===e&&b in Db&&(e=Db[b]),""===c||c?(f=parseFloat(e),c===!0||n.isNumeric(f)?f||0:e):e}}),n.each(["height","width"],function(a,b){n.cssHooks[b]={get:function(a,c,d){return c?zb.test(n.css(a,"display"))&&0===a.offsetWidth?n.swap(a,Cb,function(){return Ib(a,b,d)}):Ib(a,b,d):void 0},set:function(a,c,d){var e=d&&wb(a);return Gb(a,c,d?Hb(a,b,d,"border-box"===n.css(a,"boxSizing",!1,e),e):0)}}}),n.cssHooks.marginRight=yb(k.reliableMarginRight,function(a,b){return b?n.swap(a,{display:"inline-block"},xb,[a,"marginRight"]):void 0}),n.each({margin:"",padding:"",border:"Width"},function(a,b){n.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];4>d;d++)e[a+R[d]+b]=f[d]||f[d-2]||f[0];return e}},ub.test(a)||(n.cssHooks[a+b].set=Gb)}),n.fn.extend({css:function(a,b){return J(this,function(a,b,c){var d,e,f={},g=0;if(n.isArray(b)){for(d=wb(a),e=b.length;e>g;g++)f[b[g]]=n.css(a,b[g],!1,d);return f}return void 0!==c?n.style(a,b,c):n.css(a,b)},a,b,arguments.length>1)},show:function(){return Jb(this,!0)},hide:function(){return Jb(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){S(this)?n(this).show():n(this).hide()})}});function Kb(a,b,c,d,e){return new Kb.prototype.init(a,b,c,d,e)}n.Tween=Kb,Kb.prototype={constructor:Kb,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||"swing",this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(n.cssNumber[c]?"":"px")},cur:function(){var a=Kb.propHooks[this.prop];return a&&a.get?a.get(this):Kb.propHooks._default.get(this)},run:function(a){var b,c=Kb.propHooks[this.prop];return this.pos=b=this.options.duration?n.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):Kb.propHooks._default.set(this),this}},Kb.prototype.init.prototype=Kb.prototype,Kb.propHooks={_default:{get:function(a){var b;return null==a.elem[a.prop]||a.elem.style&&null!=a.elem.style[a.prop]?(b=n.css(a.elem,a.prop,""),b&&"auto"!==b?b:0):a.elem[a.prop]},set:function(a){n.fx.step[a.prop]?n.fx.step[a.prop](a):a.elem.style&&(null!=a.elem.style[n.cssProps[a.prop]]||n.cssHooks[a.prop])?n.style(a.elem,a.prop,a.now+a.unit):a.elem[a.prop]=a.now}}},Kb.propHooks.scrollTop=Kb.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},n.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2}},n.fx=Kb.prototype.init,n.fx.step={};var Lb,Mb,Nb=/^(?:toggle|show|hide)$/,Ob=new RegExp("^(?:([+-])=|)("+Q+")([a-z%]*)$","i"),Pb=/queueHooks$/,Qb=[Vb],Rb={"*":[function(a,b){var c=this.createTween(a,b),d=c.cur(),e=Ob.exec(b),f=e&&e[3]||(n.cssNumber[a]?"":"px"),g=(n.cssNumber[a]||"px"!==f&&+d)&&Ob.exec(n.css(c.elem,a)),h=1,i=20;if(g&&g[3]!==f){f=f||g[3],e=e||[],g=+d||1;do h=h||".5",g/=h,n.style(c.elem,a,g+f);while(h!==(h=c.cur()/d)&&1!==h&&--i)}return e&&(g=c.start=+g||+d||0,c.unit=f,c.end=e[1]?g+(e[1]+1)*e[2]:+e[2]),c}]};function Sb(){return setTimeout(function(){Lb=void 0}),Lb=n.now()}function Tb(a,b){var c,d=0,e={height:a};for(b=b?1:0;4>d;d+=2-b)c=R[d],e["margin"+c]=e["padding"+c]=a;return b&&(e.opacity=e.width=a),e}function Ub(a,b,c){for(var d,e=(Rb[b]||[]).concat(Rb["*"]),f=0,g=e.length;g>f;f++)if(d=e[f].call(c,b,a))return d}function Vb(a,b,c){var d,e,f,g,h,i,j,k,l=this,m={},o=a.style,p=a.nodeType&&S(a),q=L.get(a,"fxshow");c.queue||(h=n._queueHooks(a,"fx"),null==h.unqueued&&(h.unqueued=0,i=h.empty.fire,h.empty.fire=function(){h.unqueued||i()}),h.unqueued++,l.always(function(){l.always(function(){h.unqueued--,n.queue(a,"fx").length||h.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[o.overflow,o.overflowX,o.overflowY],j=n.css(a,"display"),k="none"===j?L.get(a,"olddisplay")||tb(a.nodeName):j,"inline"===k&&"none"===n.css(a,"float")&&(o.display="inline-block")),c.overflow&&(o.overflow="hidden",l.always(function(){o.overflow=c.overflow[0],o.overflowX=c.overflow[1],o.overflowY=c.overflow[2]}));for(d in b)if(e=b[d],Nb.exec(e)){if(delete b[d],f=f||"toggle"===e,e===(p?"hide":"show")){if("show"!==e||!q||void 0===q[d])continue;p=!0}m[d]=q&&q[d]||n.style(a,d)}else j=void 0;if(n.isEmptyObject(m))"inline"===("none"===j?tb(a.nodeName):j)&&(o.display=j);else{q?"hidden"in q&&(p=q.hidden):q=L.access(a,"fxshow",{}),f&&(q.hidden=!p),p?n(a).show():l.done(function(){n(a).hide()}),l.done(function(){var b;L.remove(a,"fxshow");for(b in m)n.style(a,b,m[b])});for(d in m)g=Ub(p?q[d]:0,d,l),d in q||(q[d]=g.start,p&&(g.end=g.start,g.start="width"===d||"height"===d?1:0))}}function Wb(a,b){var c,d,e,f,g;for(c in a)if(d=n.camelCase(c),e=b[d],f=a[c],n.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=n.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function Xb(a,b,c){var d,e,f=0,g=Qb.length,h=n.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=Lb||Sb(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;i>g;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),1>f&&i?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:n.extend({},b),opts:n.extend(!0,{specialEasing:{}},c),originalProperties:b,originalOptions:c,startTime:Lb||Sb(),duration:c.duration,tweens:[],createTween:function(b,c){var d=n.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;d>c;c++)j.tweens[c].run(1);return b?h.resolveWith(a,[j,b]):h.rejectWith(a,[j,b]),this}}),k=j.props;for(Wb(k,j.opts.specialEasing);g>f;f++)if(d=Qb[f].call(j,a,k,j.opts))return d;return n.map(k,Ub,j),n.isFunction(j.opts.start)&&j.opts.start.call(a,j),n.fx.timer(n.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}n.Animation=n.extend(Xb,{tweener:function(a,b){n.isFunction(a)?(b=a,a=["*"]):a=a.split(" ");for(var c,d=0,e=a.length;e>d;d++)c=a[d],Rb[c]=Rb[c]||[],Rb[c].unshift(b)},prefilter:function(a,b){b?Qb.unshift(a):Qb.push(a)}}),n.speed=function(a,b,c){var d=a&&"object"==typeof a?n.extend({},a):{complete:c||!c&&b||n.isFunction(a)&&a,duration:a,easing:c&&b||b&&!n.isFunction(b)&&b};return d.duration=n.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in n.fx.speeds?n.fx.speeds[d.duration]:n.fx.speeds._default,(null==d.queue||d.queue===!0)&&(d.queue="fx"),d.old=d.complete,d.complete=function(){n.isFunction(d.old)&&d.old.call(this),d.queue&&n.dequeue(this,d.queue)},d},n.fn.extend({fadeTo:function(a,b,c,d){return this.filter(S).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=n.isEmptyObject(a),f=n.speed(b,c,d),g=function(){var b=Xb(this,n.extend({},a),f);(e||L.get(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=n.timers,g=L.get(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&Pb.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));(b||!c)&&n.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=L.get(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=n.timers,g=d?d.length:0;for(c.finish=!0,n.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;g>b;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),n.each(["toggle","show","hide"],function(a,b){var c=n.fn[b];n.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(Tb(b,!0),a,d,e)}}),n.each({slideDown:Tb("show"),slideUp:Tb("hide"),slideToggle:Tb("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){n.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),n.timers=[],n.fx.tick=function(){var a,b=0,c=n.timers;for(Lb=n.now();b<c.length;b++)a=c[b],a()||c[b]!==a||c.splice(b--,1);c.length||n.fx.stop(),Lb=void 0},n.fx.timer=function(a){n.timers.push(a),a()?n.fx.start():n.timers.pop()},n.fx.interval=13,n.fx.start=function(){Mb||(Mb=setInterval(n.fx.tick,n.fx.interval))},n.fx.stop=function(){clearInterval(Mb),Mb=null},n.fx.speeds={slow:600,fast:200,_default:400},n.fn.delay=function(a,b){return a=n.fx?n.fx.speeds[a]||a:a,b=b||"fx",this.queue(b,function(b,c){var d=setTimeout(b,a);c.stop=function(){clearTimeout(d)}})},function(){var a=l.createElement("input"),b=l.createElement("select"),c=b.appendChild(l.createElement("option"));a.type="checkbox",k.checkOn=""!==a.value,k.optSelected=c.selected,b.disabled=!0,k.optDisabled=!c.disabled,a=l.createElement("input"),a.value="t",a.type="radio",k.radioValue="t"===a.value}();var Yb,Zb,$b=n.expr.attrHandle;n.fn.extend({attr:function(a,b){return J(this,n.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){n.removeAttr(this,a)})}}),n.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(a&&3!==f&&8!==f&&2!==f)return typeof a.getAttribute===U?n.prop(a,b,c):(1===f&&n.isXMLDoc(a)||(b=b.toLowerCase(),d=n.attrHooks[b]||(n.expr.match.bool.test(b)?Zb:Yb)),void 0===c?d&&"get"in d&&null!==(e=d.get(a,b))?e:(e=n.find.attr(a,b),null==e?void 0:e):null!==c?d&&"set"in d&&void 0!==(e=d.set(a,c,b))?e:(a.setAttribute(b,c+""),c):void n.removeAttr(a,b))+},removeAttr:function(a,b){var c,d,e=0,f=b&&b.match(E);if(f&&1===a.nodeType)while(c=f[e++])d=n.propFix[c]||c,n.expr.match.bool.test(c)&&(a[d]=!1),a.removeAttribute(c)},attrHooks:{type:{set:function(a,b){if(!k.radioValue&&"radio"===b&&n.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}}}),Zb={set:function(a,b,c){return b===!1?n.removeAttr(a,c):a.setAttribute(c,c),c}},n.each(n.expr.match.bool.source.match(/\w+/g),function(a,b){var c=$b[b]||n.find.attr;$b[b]=function(a,b,d){var e,f;return d||(f=$b[b],$b[b]=e,e=null!=c(a,b,d)?b.toLowerCase():null,$b[b]=f),e}});var _b=/^(?:input|select|textarea|button)$/i;n.fn.extend({prop:function(a,b){return J(this,n.prop,a,b,arguments.length>1)},removeProp:function(a){return this.each(function(){delete this[n.propFix[a]||a]})}}),n.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(a,b,c){var d,e,f,g=a.nodeType;if(a&&3!==g&&8!==g&&2!==g)return f=1!==g||!n.isXMLDoc(a),f&&(b=n.propFix[b]||b,e=n.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){return a.hasAttribute("tabindex")||_b.test(a.nodeName)||a.href?a.tabIndex:-1}}}}),k.optSelected||(n.propHooks.selected={get:function(a){var b=a.parentNode;return b&&b.parentNode&&b.parentNode.selectedIndex,null}}),n.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){n.propFix[this.toLowerCase()]=this});var ac=/[\t\r\n\f]/g;n.fn.extend({addClass:function(a){var b,c,d,e,f,g,h="string"==typeof a&&a,i=0,j=this.length;if(n.isFunction(a))return this.each(function(b){n(this).addClass(a.call(this,b,this.className))});if(h)for(b=(a||"").match(E)||[];j>i;i++)if(c=this[i],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(ac," "):" ")){f=0;while(e=b[f++])d.indexOf(" "+e+" ")<0&&(d+=e+" ");g=n.trim(d),c.className!==g&&(c.className=g)}return this},removeClass:function(a){var b,c,d,e,f,g,h=0===arguments.length||"string"==typeof a&&a,i=0,j=this.length;if(n.isFunction(a))return this.each(function(b){n(this).removeClass(a.call(this,b,this.className))});if(h)for(b=(a||"").match(E)||[];j>i;i++)if(c=this[i],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(ac," "):"")){f=0;while(e=b[f++])while(d.indexOf(" "+e+" ")>=0)d=d.replace(" "+e+" "," ");g=a?n.trim(d):"",c.className!==g&&(c.className=g)}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):this.each(n.isFunction(a)?function(c){n(this).toggleClass(a.call(this,c,this.className,b),b)}:function(){if("string"===c){var b,d=0,e=n(this),f=a.match(E)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else(c===U||"boolean"===c)&&(this.className&&L.set(this,"__className__",this.className),this.className=this.className||a===!1?"":L.get(this,"__className__")||"")})},hasClass:function(a){for(var b=" "+a+" ",c=0,d=this.length;d>c;c++)if(1===this[c].nodeType&&(" "+this[c].className+" ").replace(ac," ").indexOf(b)>=0)return!0;return!1}});var bc=/\r/g;n.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=n.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,n(this).val()):a,null==e?e="":"number"==typeof e?e+="":n.isArray(e)&&(e=n.map(e,function(a){return null==a?"":a+""})),b=n.valHooks[this.type]||n.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=n.valHooks[e.type]||n.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(bc,""):null==c?"":c)}}}),n.extend({valHooks:{option:{get:function(a){var b=n.find.attr(a,"value");return null!=b?b:n.trim(n.text(a))}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||0>e,g=f?null:[],h=f?e+1:d.length,i=0>e?h:f?e:0;h>i;i++)if(c=d[i],!(!c.selected&&i!==e||(k.optDisabled?c.disabled:null!==c.getAttribute("disabled"))||c.parentNode.disabled&&n.nodeName(c.parentNode,"optgroup"))){if(b=n(c).val(),f)return b;g.push(b)}return g},set:function(a,b){var c,d,e=a.options,f=n.makeArray(b),g=e.length;while(g--)d=e[g],(d.selected=n.inArray(d.value,f)>=0)&&(c=!0);return c||(a.selectedIndex=-1),f}}}}),n.each(["radio","checkbox"],function(){n.valHooks[this]={set:function(a,b){return n.isArray(b)?a.checked=n.inArray(n(a).val(),b)>=0:void 0}},k.checkOn||(n.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})}),n.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){n.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),n.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)},bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}});var cc=n.now(),dc=/\?/;n.parseJSON=function(a){return JSON.parse(a+"")},n.parseXML=function(a){var b,c;if(!a||"string"!=typeof a)return null;try{c=new DOMParser,b=c.parseFromString(a,"text/xml")}catch(d){b=void 0}return(!b||b.getElementsByTagName("parsererror").length)&&n.error("Invalid XML: "+a),b};var ec,fc,gc=/#.*$/,hc=/([?&])_=[^&]*/,ic=/^(.*?):[ \t]*([^\r\n]*)$/gm,jc=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,kc=/^(?:GET|HEAD)$/,lc=/^\/\//,mc=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,nc={},oc={},pc="*/".concat("*");try{fc=location.href}catch(qc){fc=l.createElement("a"),fc.href="",fc=fc.href}ec=mc.exec(fc.toLowerCase())||[];function rc(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(E)||[];if(n.isFunction(c))while(d=f[e++])"+"===d[0]?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function sc(a,b,c,d){var e={},f=a===oc;function g(h){var i;return e[h]=!0,n.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function tc(a,b){var c,d,e=n.ajaxSettings.flatOptions||{};for(c in b)void 0!==b[c]&&((e[c]?a:d||(d={}))[c]=b[c]);return d&&n.extend(!0,a,d),a}function uc(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===d&&(d=a.mimeType||b.getResponseHeader("Content-Type"));if(d)for(e in h)if(h[e]&&h[e].test(d)){i.unshift(e);break}if(i[0]in c)f=i[0];else{for(e in c){if(!i[0]||a.converters[e+" "+i[0]]){f=e;break}g||(g=e)}f=f||g}return f?(f!==i[0]&&i.unshift(f),c[f]):void 0}function vc(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}n.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:fc,type:"GET",isLocal:jc.test(ec[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":pc,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":n.parseJSON,"text xml":n.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?tc(tc(a,n.ajaxSettings),b):tc(n.ajaxSettings,a)},ajaxPrefilter:rc(nc),ajaxTransport:rc(oc),ajax:function(a,b){"object"==typeof a&&(b=a,a=void 0),b=b||{};var c,d,e,f,g,h,i,j,k=n.ajaxSetup({},b),l=k.context||k,m=k.context&&(l.nodeType||l.jquery)?n(l):n.event,o=n.Deferred(),p=n.Callbacks("once memory"),q=k.statusCode||{},r={},s={},t=0,u="canceled",v={readyState:0,getResponseHeader:function(a){var b;if(2===t){if(!f){f={};while(b=ic.exec(e))f[b[1].toLowerCase()]=b[2]}b=f[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return 2===t?e:null},setRequestHeader:function(a,b){var c=a.toLowerCase();return t||(a=s[c]=s[c]||a,r[a]=b),this},overrideMimeType:function(a){return t||(k.mimeType=a),this},statusCode:function(a){var b;if(a)if(2>t)for(b in a)q[b]=[q[b],a[b]];else v.always(a[v.status]);return this},abort:function(a){var b=a||u;return c&&c.abort(b),x(0,b),this}};if(o.promise(v).complete=p.add,v.success=v.done,v.error=v.fail,k.url=((a||k.url||fc)+"").replace(gc,"").replace(lc,ec[1]+"//"),k.type=b.method||b.type||k.method||k.type,k.dataTypes=n.trim(k.dataType||"*").toLowerCase().match(E)||[""],null==k.crossDomain&&(h=mc.exec(k.url.toLowerCase()),k.crossDomain=!(!h||h[1]===ec[1]&&h[2]===ec[2]&&(h[3]||("http:"===h[1]?"80":"443"))===(ec[3]||("http:"===ec[1]?"80":"443")))),k.data&&k.processData&&"string"!=typeof k.data&&(k.data=n.param(k.data,k.traditional)),sc(nc,k,b,v),2===t)return v;i=k.global,i&&0===n.active++&&n.event.trigger("ajaxStart"),k.type=k.type.toUpperCase(),k.hasContent=!kc.test(k.type),d=k.url,k.hasContent||(k.data&&(d=k.url+=(dc.test(d)?"&":"?")+k.data,delete k.data),k.cache===!1&&(k.url=hc.test(d)?d.replace(hc,"$1_="+cc++):d+(dc.test(d)?"&":"?")+"_="+cc++)),k.ifModified&&(n.lastModified[d]&&v.setRequestHeader("If-Modified-Since",n.lastModified[d]),n.etag[d]&&v.setRequestHeader("If-None-Match",n.etag[d])),(k.data&&k.hasContent&&k.contentType!==!1||b.contentType)&&v.setRequestHeader("Content-Type",k.contentType),v.setRequestHeader("Accept",k.dataTypes[0]&&k.accepts[k.dataTypes[0]]?k.accepts[k.dataTypes[0]]+("*"!==k.dataTypes[0]?", "+pc+"; q=0.01":""):k.accepts["*"]);for(j in k.headers)v.setRequestHeader(j,k.headers[j]);if(k.beforeSend&&(k.beforeSend.call(l,v,k)===!1||2===t))return v.abort();u="abort";for(j in{success:1,error:1,complete:1})v[j](k[j]);if(c=sc(oc,k,b,v)){v.readyState=1,i&&m.trigger("ajaxSend",[v,k]),k.async&&k.timeout>0&&(g=setTimeout(function(){v.abort("timeout")},k.timeout));try{t=1,c.send(r,x)}catch(w){if(!(2>t))throw w;x(-1,w)}}else x(-1,"No Transport");function x(a,b,f,h){var j,r,s,u,w,x=b;2!==t&&(t=2,g&&clearTimeout(g),c=void 0,e=h||"",v.readyState=a>0?4:0,j=a>=200&&300>a||304===a,f&&(u=uc(k,v,f)),u=vc(k,u,v,j),j?(k.ifModified&&(w=v.getResponseHeader("Last-Modified"),w&&(n.lastModified[d]=w),w=v.getResponseHeader("etag"),w&&(n.etag[d]=w)),204===a||"HEAD"===k.type?x="nocontent":304===a?x="notmodified":(x=u.state,r=u.data,s=u.error,j=!s)):(s=x,(a||!x)&&(x="error",0>a&&(a=0))),v.status=a,v.statusText=(b||x)+"",j?o.resolveWith(l,[r,x,v]):o.rejectWith(l,[v,x,s]),v.statusCode(q),q=void 0,i&&m.trigger(j?"ajaxSuccess":"ajaxError",[v,k,j?r:s]),p.fireWith(l,[v,x]),i&&(m.trigger("ajaxComplete",[v,k]),--n.active||n.event.trigger("ajaxStop")))}return v},getJSON:function(a,b,c){return n.get(a,b,c,"json")},getScript:function(a,b){return n.get(a,void 0,b,"script")}}),n.each(["get","post"],function(a,b){n[b]=function(a,c,d,e){return n.isFunction(c)&&(e=e||d,d=c,c=void 0),n.ajax({url:a,type:b,dataType:e,data:c,success:d})}}),n.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){n.fn[b]=function(a){return this.on(b,a)}}),n._evalUrl=function(a){return n.ajax({url:a,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},n.fn.extend({wrapAll:function(a){var b;return n.isFunction(a)?this.each(function(b){n(this).wrapAll(a.call(this,b))}):(this[0]&&(b=n(a,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstElementChild)a=a.firstElementChild;return a}).append(this)),this)},wrapInner:function(a){return this.each(n.isFunction(a)?function(b){n(this).wrapInner(a.call(this,b))}:function(){var b=n(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=n.isFunction(a);return this.each(function(c){n(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){n.nodeName(this,"body")||n(this).replaceWith(this.childNodes)}).end()}}),n.expr.filters.hidden=function(a){return a.offsetWidth<=0&&a.offsetHeight<=0},n.expr.filters.visible=function(a){return!n.expr.filters.hidden(a)};var wc=/%20/g,xc=/\[\]$/,yc=/\r?\n/g,zc=/^(?:submit|button|image|reset|file)$/i,Ac=/^(?:input|select|textarea|keygen)/i;function Bc(a,b,c,d){var e;if(n.isArray(b))n.each(b,function(b,e){c||xc.test(a)?d(a,e):Bc(a+"["+("object"==typeof e?b:"")+"]",e,c,d)});else if(c||"object"!==n.type(b))d(a,b);else for(e in b)Bc(a+"["+e+"]",b[e],c,d)}n.param=function(a,b){var c,d=[],e=function(a,b){b=n.isFunction(b)?b():null==b?"":b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(void 0===b&&(b=n.ajaxSettings&&n.ajaxSettings.traditional),n.isArray(a)||a.jquery&&!n.isPlainObject(a))n.each(a,function(){e(this.name,this.value)});else for(c in a)Bc(c,a[c],b,e);return d.join("&").replace(wc,"+")},n.fn.extend({serialize:function(){return n.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=n.prop(this,"elements");return a?n.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!n(this).is(":disabled")&&Ac.test(this.nodeName)&&!zc.test(a)&&(this.checked||!T.test(a))}).map(function(a,b){var c=n(this).val();return null==c?null:n.isArray(c)?n.map(c,function(a){return{name:b.name,value:a.replace(yc,"\r\n")}}):{name:b.name,value:c.replace(yc,"\r\n")}}).get()}}),n.ajaxSettings.xhr=function(){try{return new XMLHttpRequest}catch(a){}};var Cc=0,Dc={},Ec={0:200,1223:204},Fc=n.ajaxSettings.xhr();a.ActiveXObject&&n(a).on("unload",function(){for(var a in Dc)Dc[a]()}),k.cors=!!Fc&&"withCredentials"in Fc,k.ajax=Fc=!!Fc,n.ajaxTransport(function(a){var b;return k.cors||Fc&&!a.crossDomain?{send:function(c,d){var e,f=a.xhr(),g=++Cc;if(f.open(a.type,a.url,a.async,a.username,a.password),a.xhrFields)for(e in a.xhrFields)f[e]=a.xhrFields[e];a.mimeType&&f.overrideMimeType&&f.overrideMimeType(a.mimeType),a.crossDomain||c["X-Requested-With"]||(c["X-Requested-With"]="XMLHttpRequest");for(e in c)f.setRequestHeader(e,c[e]);b=function(a){return function(){b&&(delete Dc[g],b=f.onload=f.onerror=null,"abort"===a?f.abort():"error"===a?d(f.status,f.statusText):d(Ec[f.status]||f.status,f.statusText,"string"==typeof f.responseText?{text:f.responseText}:void 0,f.getAllResponseHeaders()))}},f.onload=b(),f.onerror=b("error"),b=Dc[g]=b("abort");try{f.send(a.hasContent&&a.data||null)}catch(h){if(b)throw h}},abort:function(){b&&b()}}:void 0}),n.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(a){return n.globalEval(a),a}}}),n.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET")}),n.ajaxTransport("script",function(a){if(a.crossDomain){var b,c;return{send:function(d,e){b=n("<script>").prop({async:!0,charset:a.scriptCharset,src:a.url}).on("load error",c=function(a){b.remove(),c=null,a&&e("error"===a.type?404:200,a.type)}),l.head.appendChild(b[0])},abort:function(){c&&c()}}}});var Gc=[],Hc=/(=)\?(?=&|$)|\?\?/;n.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=Gc.pop()||n.expando+"_"+cc++;return this[a]=!0,a}}),n.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(Hc.test(b.url)?"url":"string"==typeof b.data&&!(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&Hc.test(b.data)&&"data");return h||"jsonp"===b.dataTypes[0]?(e=b.jsonpCallback=n.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(Hc,"$1"+e):b.jsonp!==!1&&(b.url+=(dc.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||n.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,Gc.push(e)),g&&n.isFunction(f)&&f(g[0]),g=f=void 0}),"script"):void 0}),n.parseHTML=function(a,b,c){if(!a||"string"!=typeof a)return null;"boolean"==typeof b&&(c=b,b=!1),b=b||l;var d=v.exec(a),e=!c&&[];return d?[b.createElement(d[1])]:(d=n.buildFragment([a],b,e),e&&e.length&&n(e).remove(),n.merge([],d.childNodes))};var Ic=n.fn.load;n.fn.load=function(a,b,c){if("string"!=typeof a&&Ic)return Ic.apply(this,arguments);var d,e,f,g=this,h=a.indexOf(" ");return h>=0&&(d=n.trim(a.slice(h)),a=a.slice(0,h)),n.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(e="POST"),g.length>0&&n.ajax({url:a,type:e,dataType:"html",data:b}).done(function(a){f=arguments,g.html(d?n("<div>").append(n.parseHTML(a)).find(d):a)}).complete(c&&function(a,b){g.each(c,f||[a.responseText,b,a])}),this},n.expr.filters.animated=function(a){return n.grep(n.timers,function(b){return a===b.elem}).length};var Jc=a.document.documentElement;function Kc(a){return n.isWindow(a)?a:9===a.nodeType&&a.defaultView}n.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=n.css(a,"position"),l=n(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=n.css(a,"top"),i=n.css(a,"left"),j=("absolute"===k||"fixed"===k)&&(f+i).indexOf("auto")>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),n.isFunction(b)&&(b=b.call(a,c,h)),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},n.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){n.offset.setOffset(this,a,b)});var b,c,d=this[0],e={top:0,left:0},f=d&&d.ownerDocument;if(f)return b=f.documentElement,n.contains(b,d)?(typeof d.getBoundingClientRect!==U&&(e=d.getBoundingClientRect()),c=Kc(f),{top:e.top+c.pageYOffset-b.clientTop,left:e.left+c.pageXOffset-b.clientLeft}):e},position:function(){if(this[0]){var a,b,c=this[0],d={top:0,left:0};return"fixed"===n.css(c,"position")?b=c.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),n.nodeName(a[0],"html")||(d=a.offset()),d.top+=n.css(a[0],"borderTopWidth",!0),d.left+=n.css(a[0],"borderLeftWidth",!0)),{top:b.top-d.top-n.css(c,"marginTop",!0),left:b.left-d.left-n.css(c,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||Jc;while(a&&!n.nodeName(a,"html")&&"static"===n.css(a,"position"))a=a.offsetParent;return a||Jc})}}),n.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(b,c){var d="pageYOffset"===c;n.fn[b]=function(e){return J(this,function(b,e,f){var g=Kc(b);return void 0===f?g?g[c]:b[e]:void(g?g.scrollTo(d?a.pageXOffset:f,d?f:a.pageYOffset):b[e]=f)},b,e,arguments.length,null)}}),n.each(["top","left"],function(a,b){n.cssHooks[b]=yb(k.pixelPosition,function(a,c){return c?(c=xb(a,b),vb.test(c)?n(a).position()[b]+"px":c):void 0})}),n.each({Height:"height",Width:"width"},function(a,b){n.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){n.fn[d]=function(d,e){var f=arguments.length&&(c||"boolean"!=typeof d),g=c||(d===!0||e===!0?"margin":"border");return J(this,function(b,c,d){var e;return n.isWindow(b)?b.document.documentElement["client"+a]:9===b.nodeType?(e=b.documentElement,Math.max(b.body["scroll"+a],e["scroll"+a],b.body["offset"+a],e["offset"+a],e["client"+a])):void 0===d?n.css(b,c,g):n.style(b,c,d,g)},b,f?d:void 0,f,null)}})}),n.fn.size=function(){return this.length},n.fn.andSelf=n.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return n});var Lc=a.jQuery,Mc=a.$;return n.noConflict=function(b){return a.$===n&&(a.$=Mc),b&&a.jQuery===n&&(a.jQuery=Lc),n},typeof b===U&&(a.jQuery=a.$=n),n});++ </script>+ <script language="javascript" type="text/javascript">+ /* Javascript plotting library for jQuery, version 0.8.3.++Copyright (c) 2007-2014 IOLA and Ole Laursen.+Licensed under the MIT license.++*/+(function($){$.color={};$.color.make=function(r,g,b,a){var o={};o.r=r||0;o.g=g||0;o.b=b||0;o.a=a!=null?a:1;o.add=function(c,d){for(var i=0;i<c.length;++i)o[c.charAt(i)]+=d;return o.normalize()};o.scale=function(c,f){for(var i=0;i<c.length;++i)o[c.charAt(i)]*=f;return o.normalize()};o.toString=function(){if(o.a>=1){return"rgb("+[o.r,o.g,o.b].join(",")+")"}else{return"rgba("+[o.r,o.g,o.b,o.a].join(",")+")"}};o.normalize=function(){function clamp(min,value,max){return value<min?min:value>max?max:value}o.r=clamp(0,parseInt(o.r),255);o.g=clamp(0,parseInt(o.g),255);o.b=clamp(0,parseInt(o.b),255);o.a=clamp(0,o.a,1);return o};o.clone=function(){return $.color.make(o.r,o.b,o.g,o.a)};return o.normalize()};$.color.extract=function(elem,css){var c;do{c=elem.css(css).toLowerCase();if(c!=""&&c!="transparent")break;elem=elem.parent()}while(elem.length&&!$.nodeName(elem.get(0),"body"));if(c=="rgba(0, 0, 0, 0)")c="transparent";return $.color.parse(c)};$.color.parse=function(str){var res,m=$.color.make;if(res=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(str))return m(parseInt(res[1],10),parseInt(res[2],10),parseInt(res[3],10));if(res=/rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]+(?:\.[0-9]+)?)\s*\)/.exec(str))return m(parseInt(res[1],10),parseInt(res[2],10),parseInt(res[3],10),parseFloat(res[4]));if(res=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(str))return m(parseFloat(res[1])*2.55,parseFloat(res[2])*2.55,parseFloat(res[3])*2.55);if(res=/rgba\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\s*\)/.exec(str))return m(parseFloat(res[1])*2.55,parseFloat(res[2])*2.55,parseFloat(res[3])*2.55,parseFloat(res[4]));if(res=/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(str))return m(parseInt(res[1],16),parseInt(res[2],16),parseInt(res[3],16));if(res=/#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(str))return m(parseInt(res[1]+res[1],16),parseInt(res[2]+res[2],16),parseInt(res[3]+res[3],16));var name=$.trim(str).toLowerCase();if(name=="transparent")return m(255,255,255,0);else{res=lookupColors[name]||[0,0,0];return m(res[0],res[1],res[2])}};var lookupColors={aqua:[0,255,255],azure:[240,255,255],beige:[245,245,220],black:[0,0,0],blue:[0,0,255],brown:[165,42,42],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgrey:[169,169,169],darkgreen:[0,100,0],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkviolet:[148,0,211],fuchsia:[255,0,255],gold:[255,215,0],green:[0,128,0],indigo:[75,0,130],khaki:[240,230,140],lightblue:[173,216,230],lightcyan:[224,255,255],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightyellow:[255,255,224],lime:[0,255,0],magenta:[255,0,255],maroon:[128,0,0],navy:[0,0,128],olive:[128,128,0],orange:[255,165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0]}})(jQuery);(function($){var hasOwnProperty=Object.prototype.hasOwnProperty;if(!$.fn.detach){$.fn.detach=function(){return this.each(function(){if(this.parentNode){this.parentNode.removeChild(this)}})}}function Canvas(cls,container){var element=container.children("."+cls)[0];if(element==null){element=document.createElement("canvas");element.className=cls;$(element).css({direction:"ltr",position:"absolute",left:0,top:0}).appendTo(container);if(!element.getContext){if(window.G_vmlCanvasManager){element=window.G_vmlCanvasManager.initElement(element)}else{throw new Error("Canvas is not available. If you're using IE with a fall-back such as Excanvas, then there's either a mistake in your conditional include, or the page has no DOCTYPE and is rendering in Quirks Mode.")}}}this.element=element;var context=this.context=element.getContext("2d");var devicePixelRatio=window.devicePixelRatio||1,backingStoreRatio=context.webkitBackingStorePixelRatio||context.mozBackingStorePixelRatio||context.msBackingStorePixelRatio||context.oBackingStorePixelRatio||context.backingStorePixelRatio||1;this.pixelRatio=devicePixelRatio/backingStoreRatio;this.resize(container.width(),container.height());this.textContainer=null;this.text={};this._textCache={}}Canvas.prototype.resize=function(width,height){if(width<=0||height<=0){throw new Error("Invalid dimensions for plot, width = "+width+", height = "+height)}var element=this.element,context=this.context,pixelRatio=this.pixelRatio;if(this.width!=width){element.width=width*pixelRatio;element.style.width=width+"px";this.width=width}if(this.height!=height){element.height=height*pixelRatio;element.style.height=height+"px";this.height=height}context.restore();context.save();context.scale(pixelRatio,pixelRatio)};Canvas.prototype.clear=function(){this.context.clearRect(0,0,this.width,this.height)};Canvas.prototype.render=function(){var cache=this._textCache;for(var layerKey in cache){if(hasOwnProperty.call(cache,layerKey)){var layer=this.getTextLayer(layerKey),layerCache=cache[layerKey];layer.hide();for(var styleKey in layerCache){if(hasOwnProperty.call(layerCache,styleKey)){var styleCache=layerCache[styleKey];for(var key in styleCache){if(hasOwnProperty.call(styleCache,key)){var positions=styleCache[key].positions;for(var i=0,position;position=positions[i];i++){if(position.active){if(!position.rendered){layer.append(position.element);position.rendered=true}}else{positions.splice(i--,1);if(position.rendered){position.element.detach()}}}if(positions.length==0){delete styleCache[key]}}}}}layer.show()}}};Canvas.prototype.getTextLayer=function(classes){var layer=this.text[classes];if(layer==null){if(this.textContainer==null){this.textContainer=$("<div class='flot-text'></div>").css({position:"absolute",top:0,left:0,bottom:0,right:0,"font-size":"smaller",color:"#545454"}).insertAfter(this.element)}layer=this.text[classes]=$("<div></div>").addClass(classes).css({position:"absolute",top:0,left:0,bottom:0,right:0}).appendTo(this.textContainer)}return layer};Canvas.prototype.getTextInfo=function(layer,text,font,angle,width){var textStyle,layerCache,styleCache,info;text=""+text;if(typeof font==="object"){textStyle=font.style+" "+font.variant+" "+font.weight+" "+font.size+"px/"+font.lineHeight+"px "+font.family}else{textStyle=font}layerCache=this._textCache[layer];if(layerCache==null){layerCache=this._textCache[layer]={}}styleCache=layerCache[textStyle];if(styleCache==null){styleCache=layerCache[textStyle]={}}info=styleCache[text];if(info==null){var element=$("<div></div>").html(text).css({position:"absolute","max-width":width,top:-9999}).appendTo(this.getTextLayer(layer));if(typeof font==="object"){element.css({font:textStyle,color:font.color})}else if(typeof font==="string"){element.addClass(font)}info=styleCache[text]={width:element.outerWidth(true),height:element.outerHeight(true),element:element,positions:[]};element.detach()}return info};Canvas.prototype.addText=function(layer,x,y,text,font,angle,width,halign,valign){var info=this.getTextInfo(layer,text,font,angle,width),positions=info.positions;if(halign=="center"){x-=info.width/2}else if(halign=="right"){x-=info.width}if(valign=="middle"){y-=info.height/2}else if(valign=="bottom"){y-=info.height}for(var i=0,position;position=positions[i];i++){if(position.x==x&&position.y==y){position.active=true;return}}position={active:true,rendered:false,element:positions.length?info.element.clone():info.element,x:x,y:y};positions.push(position);position.element.css({top:Math.round(y),left:Math.round(x),"text-align":halign})};Canvas.prototype.removeText=function(layer,x,y,text,font,angle){if(text==null){var layerCache=this._textCache[layer];if(layerCache!=null){for(var styleKey in layerCache){if(hasOwnProperty.call(layerCache,styleKey)){var styleCache=layerCache[styleKey];for(var key in styleCache){if(hasOwnProperty.call(styleCache,key)){var positions=styleCache[key].positions;for(var i=0,position;position=positions[i];i++){position.active=false}}}}}}}else{var positions=this.getTextInfo(layer,text,font,angle).positions;for(var i=0,position;position=positions[i];i++){if(position.x==x&&position.y==y){position.active=false}}}};function Plot(placeholder,data_,options_,plugins){var series=[],options={colors:["#edc240","#afd8f8","#cb4b4b","#4da74d","#9440ed"],legend:{show:true,noColumns:1,labelFormatter:null,labelBoxBorderColor:"#ccc",container:null,position:"ne",margin:5,backgroundColor:null,backgroundOpacity:.85,sorted:null},xaxis:{show:null,position:"bottom",mode:null,font:null,color:null,tickColor:null,transform:null,inverseTransform:null,min:null,max:null,autoscaleMargin:null,ticks:null,tickFormatter:null,labelWidth:null,labelHeight:null,reserveSpace:null,tickLength:null,alignTicksWithAxis:null,tickDecimals:null,tickSize:null,minTickSize:null},yaxis:{autoscaleMargin:.02,position:"left"},xaxes:[],yaxes:[],series:{points:{show:false,radius:3,lineWidth:2,fill:true,fillColor:"#ffffff",symbol:"circle"},lines:{lineWidth:2,fill:false,fillColor:null,steps:false},bars:{show:false,lineWidth:2,barWidth:1,fill:true,fillColor:null,align:"left",horizontal:false,zero:true},shadowSize:3,highlightColor:null},grid:{show:true,aboveData:false,color:"#545454",backgroundColor:null,borderColor:null,tickColor:null,margin:0,labelMargin:5,axisMargin:8,borderWidth:2,minBorderMargin:null,markings:null,markingsColor:"#f4f4f4",markingsLineWidth:2,clickable:false,hoverable:false,autoHighlight:true,mouseActiveRadius:10},interaction:{redrawOverlayInterval:1e3/60},hooks:{}},surface=null,overlay=null,eventHolder=null,ctx=null,octx=null,xaxes=[],yaxes=[],plotOffset={left:0,right:0,top:0,bottom:0},plotWidth=0,plotHeight=0,hooks={processOptions:[],processRawData:[],processDatapoints:[],processOffset:[],drawBackground:[],drawSeries:[],draw:[],bindEvents:[],drawOverlay:[],shutdown:[]},plot=this;plot.setData=setData;plot.setupGrid=setupGrid;plot.draw=draw;plot.getPlaceholder=function(){return placeholder};plot.getCanvas=function(){return surface.element};plot.getPlotOffset=function(){return plotOffset};plot.width=function(){return plotWidth};plot.height=function(){return plotHeight};plot.offset=function(){var o=eventHolder.offset();o.left+=plotOffset.left;o.top+=plotOffset.top;return o};plot.getData=function(){return series};plot.getAxes=function(){var res={},i;$.each(xaxes.concat(yaxes),function(_,axis){if(axis)res[axis.direction+(axis.n!=1?axis.n:"")+"axis"]=axis});return res};plot.getXAxes=function(){return xaxes};plot.getYAxes=function(){return yaxes};plot.c2p=canvasToAxisCoords;plot.p2c=axisToCanvasCoords;plot.getOptions=function(){return options};plot.highlight=highlight;plot.unhighlight=unhighlight;plot.triggerRedrawOverlay=triggerRedrawOverlay;plot.pointOffset=function(point){return{left:parseInt(xaxes[axisNumber(point,"x")-1].p2c(+point.x)+plotOffset.left,10),top:parseInt(yaxes[axisNumber(point,"y")-1].p2c(+point.y)+plotOffset.top,10)}};plot.shutdown=shutdown;plot.destroy=function(){shutdown();placeholder.removeData("plot").empty();series=[];options=null;surface=null;overlay=null;eventHolder=null;ctx=null;octx=null;xaxes=[];yaxes=[];hooks=null;highlights=[];plot=null};plot.resize=function(){var width=placeholder.width(),height=placeholder.height();surface.resize(width,height);overlay.resize(width,height)};plot.hooks=hooks;initPlugins(plot);parseOptions(options_);setupCanvases();setData(data_);setupGrid();draw();bindEvents();function executeHooks(hook,args){args=[plot].concat(args);for(var i=0;i<hook.length;++i)hook[i].apply(this,args)}function initPlugins(){var classes={Canvas:Canvas};for(var i=0;i<plugins.length;++i){var p=plugins[i];p.init(plot,classes);if(p.options)$.extend(true,options,p.options)}}function parseOptions(opts){$.extend(true,options,opts);if(opts&&opts.colors){options.colors=opts.colors}if(options.xaxis.color==null)options.xaxis.color=$.color.parse(options.grid.color).scale("a",.22).toString();if(options.yaxis.color==null)options.yaxis.color=$.color.parse(options.grid.color).scale("a",.22).toString();if(options.xaxis.tickColor==null)options.xaxis.tickColor=options.grid.tickColor||options.xaxis.color;if(options.yaxis.tickColor==null)options.yaxis.tickColor=options.grid.tickColor||options.yaxis.color;if(options.grid.borderColor==null)options.grid.borderColor=options.grid.color;if(options.grid.tickColor==null)options.grid.tickColor=$.color.parse(options.grid.color).scale("a",.22).toString();var i,axisOptions,axisCount,fontSize=placeholder.css("font-size"),fontSizeDefault=fontSize?+fontSize.replace("px",""):13,fontDefaults={style:placeholder.css("font-style"),size:Math.round(.8*fontSizeDefault),variant:placeholder.css("font-variant"),weight:placeholder.css("font-weight"),family:placeholder.css("font-family")};axisCount=options.xaxes.length||1;for(i=0;i<axisCount;++i){axisOptions=options.xaxes[i];if(axisOptions&&!axisOptions.tickColor){axisOptions.tickColor=axisOptions.color}axisOptions=$.extend(true,{},options.xaxis,axisOptions);options.xaxes[i]=axisOptions;if(axisOptions.font){axisOptions.font=$.extend({},fontDefaults,axisOptions.font);if(!axisOptions.font.color){axisOptions.font.color=axisOptions.color}if(!axisOptions.font.lineHeight){axisOptions.font.lineHeight=Math.round(axisOptions.font.size*1.15)}}}axisCount=options.yaxes.length||1;for(i=0;i<axisCount;++i){axisOptions=options.yaxes[i];if(axisOptions&&!axisOptions.tickColor){axisOptions.tickColor=axisOptions.color}axisOptions=$.extend(true,{},options.yaxis,axisOptions);options.yaxes[i]=axisOptions;if(axisOptions.font){axisOptions.font=$.extend({},fontDefaults,axisOptions.font);if(!axisOptions.font.color){axisOptions.font.color=axisOptions.color}if(!axisOptions.font.lineHeight){axisOptions.font.lineHeight=Math.round(axisOptions.font.size*1.15)}}}if(options.xaxis.noTicks&&options.xaxis.ticks==null)options.xaxis.ticks=options.xaxis.noTicks;if(options.yaxis.noTicks&&options.yaxis.ticks==null)options.yaxis.ticks=options.yaxis.noTicks;if(options.x2axis){options.xaxes[1]=$.extend(true,{},options.xaxis,options.x2axis);options.xaxes[1].position="top";if(options.x2axis.min==null){options.xaxes[1].min=null}if(options.x2axis.max==null){options.xaxes[1].max=null}}if(options.y2axis){options.yaxes[1]=$.extend(true,{},options.yaxis,options.y2axis);options.yaxes[1].position="right";if(options.y2axis.min==null){options.yaxes[1].min=null}if(options.y2axis.max==null){options.yaxes[1].max=null}}if(options.grid.coloredAreas)options.grid.markings=options.grid.coloredAreas;if(options.grid.coloredAreasColor)options.grid.markingsColor=options.grid.coloredAreasColor;if(options.lines)$.extend(true,options.series.lines,options.lines);if(options.points)$.extend(true,options.series.points,options.points);if(options.bars)$.extend(true,options.series.bars,options.bars);if(options.shadowSize!=null)options.series.shadowSize=options.shadowSize;if(options.highlightColor!=null)options.series.highlightColor=options.highlightColor;for(i=0;i<options.xaxes.length;++i)getOrCreateAxis(xaxes,i+1).options=options.xaxes[i];for(i=0;i<options.yaxes.length;++i)getOrCreateAxis(yaxes,i+1).options=options.yaxes[i];for(var n in hooks)if(options.hooks[n]&&options.hooks[n].length)hooks[n]=hooks[n].concat(options.hooks[n]);executeHooks(hooks.processOptions,[options])}function setData(d){series=parseData(d);fillInSeriesOptions();processData()}function parseData(d){var res=[];for(var i=0;i<d.length;++i){var s=$.extend(true,{},options.series);if(d[i].data!=null){s.data=d[i].data;delete d[i].data;$.extend(true,s,d[i]);d[i].data=s.data}else s.data=d[i];res.push(s)}return res}function axisNumber(obj,coord){var a=obj[coord+"axis"];if(typeof a=="object")a=a.n;if(typeof a!="number")a=1;return a}function allAxes(){return $.grep(xaxes.concat(yaxes),function(a){return a})}function canvasToAxisCoords(pos){var res={},i,axis;for(i=0;i<xaxes.length;++i){axis=xaxes[i];if(axis&&axis.used)res["x"+axis.n]=axis.c2p(pos.left)}for(i=0;i<yaxes.length;++i){axis=yaxes[i];if(axis&&axis.used)res["y"+axis.n]=axis.c2p(pos.top)}if(res.x1!==undefined)res.x=res.x1;if(res.y1!==undefined)res.y=res.y1;return res}function axisToCanvasCoords(pos){var res={},i,axis,key;for(i=0;i<xaxes.length;++i){axis=xaxes[i];if(axis&&axis.used){key="x"+axis.n;if(pos[key]==null&&axis.n==1)key="x";if(pos[key]!=null){res.left=axis.p2c(pos[key]);break}}}for(i=0;i<yaxes.length;++i){axis=yaxes[i];if(axis&&axis.used){key="y"+axis.n;if(pos[key]==null&&axis.n==1)key="y";if(pos[key]!=null){res.top=axis.p2c(pos[key]);break}}}return res}function getOrCreateAxis(axes,number){if(!axes[number-1])axes[number-1]={n:number,direction:axes==xaxes?"x":"y",options:$.extend(true,{},axes==xaxes?options.xaxis:options.yaxis)};return axes[number-1]}function fillInSeriesOptions(){var neededColors=series.length,maxIndex=-1,i;for(i=0;i<series.length;++i){var sc=series[i].color;if(sc!=null){neededColors--;if(typeof sc=="number"&&sc>maxIndex){maxIndex=sc}}}if(neededColors<=maxIndex){neededColors=maxIndex+1}var c,colors=[],colorPool=options.colors,colorPoolSize=colorPool.length,variation=0;for(i=0;i<neededColors;i++){c=$.color.parse(colorPool[i%colorPoolSize]||"#666");if(i%colorPoolSize==0&&i){if(variation>=0){if(variation<.5){variation=-variation-.2}else variation=0}else variation=-variation}colors[i]=c.scale("rgb",1+variation)}var colori=0,s;for(i=0;i<series.length;++i){s=series[i];if(s.color==null){s.color=colors[colori].toString();++colori}else if(typeof s.color=="number")s.color=colors[s.color].toString();if(s.lines.show==null){var v,show=true;for(v in s)if(s[v]&&s[v].show){show=false;break}if(show)s.lines.show=true}if(s.lines.zero==null){s.lines.zero=!!s.lines.fill}s.xaxis=getOrCreateAxis(xaxes,axisNumber(s,"x"));s.yaxis=getOrCreateAxis(yaxes,axisNumber(s,"y"))}}function processData(){var topSentry=Number.POSITIVE_INFINITY,bottomSentry=Number.NEGATIVE_INFINITY,fakeInfinity=Number.MAX_VALUE,i,j,k,m,length,s,points,ps,x,y,axis,val,f,p,data,format;function updateAxis(axis,min,max){if(min<axis.datamin&&min!=-fakeInfinity)axis.datamin=min;if(max>axis.datamax&&max!=fakeInfinity)axis.datamax=max}$.each(allAxes(),function(_,axis){axis.datamin=topSentry;axis.datamax=bottomSentry;axis.used=false});for(i=0;i<series.length;++i){s=series[i];s.datapoints={points:[]};executeHooks(hooks.processRawData,[s,s.data,s.datapoints])}for(i=0;i<series.length;++i){s=series[i];data=s.data;format=s.datapoints.format;if(!format){format=[];format.push({x:true,number:true,required:true});format.push({y:true,number:true,required:true});if(s.bars.show||s.lines.show&&s.lines.fill){var autoscale=!!(s.bars.show&&s.bars.zero||s.lines.show&&s.lines.zero);format.push({y:true,number:true,required:false,defaultValue:0,autoscale:autoscale});if(s.bars.horizontal){delete format[format.length-1].y;format[format.length-1].x=true}}s.datapoints.format=format}if(s.datapoints.pointsize!=null)continue;s.datapoints.pointsize=format.length;ps=s.datapoints.pointsize;points=s.datapoints.points;var insertSteps=s.lines.show&&s.lines.steps;s.xaxis.used=s.yaxis.used=true;for(j=k=0;j<data.length;++j,k+=ps){p=data[j];var nullify=p==null;if(!nullify){for(m=0;m<ps;++m){val=p[m];f=format[m];if(f){if(f.number&&val!=null){val=+val;if(isNaN(val))val=null;else if(val==Infinity)val=fakeInfinity;else if(val==-Infinity)val=-fakeInfinity}if(val==null){if(f.required)nullify=true;if(f.defaultValue!=null)val=f.defaultValue}}points[k+m]=val}}if(nullify){for(m=0;m<ps;++m){val=points[k+m];if(val!=null){f=format[m];if(f.autoscale!==false){if(f.x){updateAxis(s.xaxis,val,val)}if(f.y){updateAxis(s.yaxis,val,val)}}}points[k+m]=null}}else{if(insertSteps&&k>0&&points[k-ps]!=null&&points[k-ps]!=points[k]&&points[k-ps+1]!=points[k+1]){for(m=0;m<ps;++m)points[k+ps+m]=points[k+m];points[k+1]=points[k-ps+1];k+=ps}}}}for(i=0;i<series.length;++i){s=series[i];executeHooks(hooks.processDatapoints,[s,s.datapoints])}for(i=0;i<series.length;++i){s=series[i];points=s.datapoints.points;ps=s.datapoints.pointsize;format=s.datapoints.format;var xmin=topSentry,ymin=topSentry,xmax=bottomSentry,ymax=bottomSentry;for(j=0;j<points.length;j+=ps){if(points[j]==null)continue;for(m=0;m<ps;++m){val=points[j+m];f=format[m];if(!f||f.autoscale===false||val==fakeInfinity||val==-fakeInfinity)continue;if(f.x){if(val<xmin)xmin=val;if(val>xmax)xmax=val}if(f.y){if(val<ymin)ymin=val;if(val>ymax)ymax=val}}}if(s.bars.show){var delta;switch(s.bars.align){case"left":delta=0;break;case"right":delta=-s.bars.barWidth;break;default:delta=-s.bars.barWidth/2}if(s.bars.horizontal){ymin+=delta;ymax+=delta+s.bars.barWidth}else{xmin+=delta;xmax+=delta+s.bars.barWidth}}updateAxis(s.xaxis,xmin,xmax);updateAxis(s.yaxis,ymin,ymax)}$.each(allAxes(),function(_,axis){if(axis.datamin==topSentry)axis.datamin=null;if(axis.datamax==bottomSentry)axis.datamax=null})}function setupCanvases(){placeholder.css("padding",0).children().filter(function(){return!$(this).hasClass("flot-overlay")&&!$(this).hasClass("flot-base")}).remove();if(placeholder.css("position")=="static")placeholder.css("position","relative");surface=new Canvas("flot-base",placeholder);overlay=new Canvas("flot-overlay",placeholder);ctx=surface.context;octx=overlay.context;eventHolder=$(overlay.element).unbind();var existing=placeholder.data("plot");if(existing){existing.shutdown();overlay.clear()}placeholder.data("plot",plot)}function bindEvents(){if(options.grid.hoverable){eventHolder.mousemove(onMouseMove);eventHolder.bind("mouseleave",onMouseLeave)}if(options.grid.clickable)eventHolder.click(onClick);executeHooks(hooks.bindEvents,[eventHolder])}function shutdown(){if(redrawTimeout)clearTimeout(redrawTimeout);eventHolder.unbind("mousemove",onMouseMove);eventHolder.unbind("mouseleave",onMouseLeave);eventHolder.unbind("click",onClick);executeHooks(hooks.shutdown,[eventHolder])}function setTransformationHelpers(axis){function identity(x){return x}var s,m,t=axis.options.transform||identity,it=axis.options.inverseTransform;if(axis.direction=="x"){s=axis.scale=plotWidth/Math.abs(t(axis.max)-t(axis.min));m=Math.min(t(axis.max),t(axis.min))}else{s=axis.scale=plotHeight/Math.abs(t(axis.max)-t(axis.min));s=-s;m=Math.max(t(axis.max),t(axis.min))}if(t==identity)axis.p2c=function(p){return(p-m)*s};else axis.p2c=function(p){return(t(p)-m)*s};if(!it)axis.c2p=function(c){return m+c/s};else axis.c2p=function(c){return it(m+c/s)}}function measureTickLabels(axis){var opts=axis.options,ticks=axis.ticks||[],labelWidth=opts.labelWidth||0,labelHeight=opts.labelHeight||0,maxWidth=labelWidth||(axis.direction=="x"?Math.floor(surface.width/(ticks.length||1)):null),legacyStyles=axis.direction+"Axis "+axis.direction+axis.n+"Axis",layer="flot-"+axis.direction+"-axis flot-"+axis.direction+axis.n+"-axis "+legacyStyles,font=opts.font||"flot-tick-label tickLabel";for(var i=0;i<ticks.length;++i){var t=ticks[i];if(!t.label)continue;var info=surface.getTextInfo(layer,t.label,font,null,maxWidth);labelWidth=Math.max(labelWidth,info.width);labelHeight=Math.max(labelHeight,info.height)}axis.labelWidth=opts.labelWidth||labelWidth;axis.labelHeight=opts.labelHeight||labelHeight}function allocateAxisBoxFirstPhase(axis){var lw=axis.labelWidth,lh=axis.labelHeight,pos=axis.options.position,isXAxis=axis.direction==="x",tickLength=axis.options.tickLength,axisMargin=options.grid.axisMargin,padding=options.grid.labelMargin,innermost=true,outermost=true,first=true,found=false;$.each(isXAxis?xaxes:yaxes,function(i,a){if(a&&(a.show||a.reserveSpace)){if(a===axis){found=true}else if(a.options.position===pos){if(found){outermost=false}else{innermost=false}}if(!found){first=false}}});if(outermost){axisMargin=0}if(tickLength==null){tickLength=first?"full":5}if(!isNaN(+tickLength))padding+=+tickLength;if(isXAxis){lh+=padding;if(pos=="bottom"){plotOffset.bottom+=lh+axisMargin;axis.box={top:surface.height-plotOffset.bottom,height:lh}}else{axis.box={top:plotOffset.top+axisMargin,height:lh};plotOffset.top+=lh+axisMargin}}else{lw+=padding;if(pos=="left"){axis.box={left:plotOffset.left+axisMargin,width:lw};plotOffset.left+=lw+axisMargin}else{plotOffset.right+=lw+axisMargin;axis.box={left:surface.width-plotOffset.right,width:lw}}}axis.position=pos;axis.tickLength=tickLength;axis.box.padding=padding;axis.innermost=innermost}function allocateAxisBoxSecondPhase(axis){if(axis.direction=="x"){axis.box.left=plotOffset.left-axis.labelWidth/2;axis.box.width=surface.width-plotOffset.left-plotOffset.right+axis.labelWidth}else{axis.box.top=plotOffset.top-axis.labelHeight/2;axis.box.height=surface.height-plotOffset.bottom-plotOffset.top+axis.labelHeight}}function adjustLayoutForThingsStickingOut(){var minMargin=options.grid.minBorderMargin,axis,i;if(minMargin==null){minMargin=0;for(i=0;i<series.length;++i)minMargin=Math.max(minMargin,2*(series[i].points.radius+series[i].points.lineWidth/2))}var margins={left:minMargin,right:minMargin,top:minMargin,bottom:minMargin};$.each(allAxes(),function(_,axis){if(axis.reserveSpace&&axis.ticks&&axis.ticks.length){if(axis.direction==="x"){margins.left=Math.max(margins.left,axis.labelWidth/2);margins.right=Math.max(margins.right,axis.labelWidth/2)}else{margins.bottom=Math.max(margins.bottom,axis.labelHeight/2);margins.top=Math.max(margins.top,axis.labelHeight/2)}}});plotOffset.left=Math.ceil(Math.max(margins.left,plotOffset.left));plotOffset.right=Math.ceil(Math.max(margins.right,plotOffset.right));plotOffset.top=Math.ceil(Math.max(margins.top,plotOffset.top));plotOffset.bottom=Math.ceil(Math.max(margins.bottom,plotOffset.bottom))}function setupGrid(){var i,axes=allAxes(),showGrid=options.grid.show;for(var a in plotOffset){var margin=options.grid.margin||0;plotOffset[a]=typeof margin=="number"?margin:margin[a]||0}executeHooks(hooks.processOffset,[plotOffset]);for(var a in plotOffset){if(typeof options.grid.borderWidth=="object"){plotOffset[a]+=showGrid?options.grid.borderWidth[a]:0}else{plotOffset[a]+=showGrid?options.grid.borderWidth:0}}$.each(axes,function(_,axis){var axisOpts=axis.options;axis.show=axisOpts.show==null?axis.used:axisOpts.show;axis.reserveSpace=axisOpts.reserveSpace==null?axis.show:axisOpts.reserveSpace;setRange(axis)});if(showGrid){var allocatedAxes=$.grep(axes,function(axis){return axis.show||axis.reserveSpace});$.each(allocatedAxes,function(_,axis){setupTickGeneration(axis);setTicks(axis);snapRangeToTicks(axis,axis.ticks);measureTickLabels(axis)});for(i=allocatedAxes.length-1;i>=0;--i)allocateAxisBoxFirstPhase(allocatedAxes[i]);adjustLayoutForThingsStickingOut();$.each(allocatedAxes,function(_,axis){allocateAxisBoxSecondPhase(axis)})}plotWidth=surface.width-plotOffset.left-plotOffset.right;plotHeight=surface.height-plotOffset.bottom-plotOffset.top;$.each(axes,function(_,axis){setTransformationHelpers(axis)});if(showGrid){drawAxisLabels()}insertLegend()}function setRange(axis){var opts=axis.options,min=+(opts.min!=null?opts.min:axis.datamin),max=+(opts.max!=null?opts.max:axis.datamax),delta=max-min;if(delta==0){var widen=max==0?1:.01;if(opts.min==null)min-=widen;if(opts.max==null||opts.min!=null)max+=widen}else{var margin=opts.autoscaleMargin;if(margin!=null){if(opts.min==null){min-=delta*margin;if(min<0&&axis.datamin!=null&&axis.datamin>=0)min=0}if(opts.max==null){max+=delta*margin;if(max>0&&axis.datamax!=null&&axis.datamax<=0)max=0}}}axis.min=min;axis.max=max}function setupTickGeneration(axis){var opts=axis.options;var noTicks;if(typeof opts.ticks=="number"&&opts.ticks>0)noTicks=opts.ticks;else noTicks=.3*Math.sqrt(axis.direction=="x"?surface.width:surface.height);var delta=(axis.max-axis.min)/noTicks,dec=-Math.floor(Math.log(delta)/Math.LN10),maxDec=opts.tickDecimals;if(maxDec!=null&&dec>maxDec){dec=maxDec}var magn=Math.pow(10,-dec),norm=delta/magn,size;if(norm<1.5){size=1}else if(norm<3){size=2;if(norm>2.25&&(maxDec==null||dec+1<=maxDec)){size=2.5;++dec}}else if(norm<7.5){size=5}else{size=10}size*=magn;if(opts.minTickSize!=null&&size<opts.minTickSize){size=opts.minTickSize}axis.delta=delta;axis.tickDecimals=Math.max(0,maxDec!=null?maxDec:dec);axis.tickSize=opts.tickSize||size;if(opts.mode=="time"&&!axis.tickGenerator){throw new Error("Time mode requires the flot.time plugin.")}if(!axis.tickGenerator){axis.tickGenerator=function(axis){var ticks=[],start=floorInBase(axis.min,axis.tickSize),i=0,v=Number.NaN,prev;do{prev=v;v=start+i*axis.tickSize;ticks.push(v);++i}while(v<axis.max&&v!=prev);return ticks};axis.tickFormatter=function(value,axis){var factor=axis.tickDecimals?Math.pow(10,axis.tickDecimals):1;var formatted=""+Math.round(value*factor)/factor;if(axis.tickDecimals!=null){var decimal=formatted.indexOf(".");var precision=decimal==-1?0:formatted.length-decimal-1;if(precision<axis.tickDecimals){return(precision?formatted:formatted+".")+(""+factor).substr(1,axis.tickDecimals-precision)}}return formatted}}if($.isFunction(opts.tickFormatter))axis.tickFormatter=function(v,axis){return""+opts.tickFormatter(v,axis)};if(opts.alignTicksWithAxis!=null){var otherAxis=(axis.direction=="x"?xaxes:yaxes)[opts.alignTicksWithAxis-1];if(otherAxis&&otherAxis.used&&otherAxis!=axis){var niceTicks=axis.tickGenerator(axis);if(niceTicks.length>0){if(opts.min==null)axis.min=Math.min(axis.min,niceTicks[0]);if(opts.max==null&&niceTicks.length>1)axis.max=Math.max(axis.max,niceTicks[niceTicks.length-1])}axis.tickGenerator=function(axis){var ticks=[],v,i;for(i=0;i<otherAxis.ticks.length;++i){v=(otherAxis.ticks[i].v-otherAxis.min)/(otherAxis.max-otherAxis.min);v=axis.min+v*(axis.max-axis.min);ticks.push(v)}return ticks};if(!axis.mode&&opts.tickDecimals==null){var extraDec=Math.max(0,-Math.floor(Math.log(axis.delta)/Math.LN10)+1),ts=axis.tickGenerator(axis);if(!(ts.length>1&&/\..*0$/.test((ts[1]-ts[0]).toFixed(extraDec))))axis.tickDecimals=extraDec}}}}function setTicks(axis){var oticks=axis.options.ticks,ticks=[];if(oticks==null||typeof oticks=="number"&&oticks>0)ticks=axis.tickGenerator(axis);else if(oticks){if($.isFunction(oticks))ticks=oticks(axis);else ticks=oticks}var i,v;axis.ticks=[];for(i=0;i<ticks.length;++i){var label=null;var t=ticks[i];if(typeof t=="object"){v=+t[0];if(t.length>1)label=t[1]}else v=+t;if(label==null)label=axis.tickFormatter(v,axis);if(!isNaN(v))axis.ticks.push({v:v,label:label})}}function snapRangeToTicks(axis,ticks){if(axis.options.autoscaleMargin&&ticks.length>0){if(axis.options.min==null)axis.min=Math.min(axis.min,ticks[0].v);if(axis.options.max==null&&ticks.length>1)axis.max=Math.max(axis.max,ticks[ticks.length-1].v)}}function draw(){surface.clear();executeHooks(hooks.drawBackground,[ctx]);var grid=options.grid;if(grid.show&&grid.backgroundColor)drawBackground();if(grid.show&&!grid.aboveData){drawGrid()}for(var i=0;i<series.length;++i){executeHooks(hooks.drawSeries,[ctx,series[i]]);drawSeries(series[i])}executeHooks(hooks.draw,[ctx]);if(grid.show&&grid.aboveData){drawGrid()}surface.render();triggerRedrawOverlay()}function extractRange(ranges,coord){var axis,from,to,key,axes=allAxes();for(var i=0;i<axes.length;++i){axis=axes[i];if(axis.direction==coord){key=coord+axis.n+"axis";if(!ranges[key]&&axis.n==1)key=coord+"axis";if(ranges[key]){from=ranges[key].from;to=ranges[key].to;break}}}if(!ranges[key]){axis=coord=="x"?xaxes[0]:yaxes[0];from=ranges[coord+"1"];to=ranges[coord+"2"]}if(from!=null&&to!=null&&from>to){var tmp=from;from=to;to=tmp}return{from:from,to:to,axis:axis}}function drawBackground(){ctx.save();ctx.translate(plotOffset.left,plotOffset.top);ctx.fillStyle=getColorOrGradient(options.grid.backgroundColor,plotHeight,0,"rgba(255, 255, 255, 0)");ctx.fillRect(0,0,plotWidth,plotHeight);ctx.restore()}function drawGrid(){var i,axes,bw,bc;ctx.save();ctx.translate(plotOffset.left,plotOffset.top);var markings=options.grid.markings;if(markings){if($.isFunction(markings)){axes=plot.getAxes();axes.xmin=axes.xaxis.min;axes.xmax=axes.xaxis.max;axes.ymin=axes.yaxis.min;axes.ymax=axes.yaxis.max;markings=markings(axes)}for(i=0;i<markings.length;++i){var m=markings[i],xrange=extractRange(m,"x"),yrange=extractRange(m,"y");if(xrange.from==null)xrange.from=xrange.axis.min;if(xrange.to==null)xrange.to=xrange.axis.max;+if(yrange.from==null)yrange.from=yrange.axis.min;if(yrange.to==null)yrange.to=yrange.axis.max;if(xrange.to<xrange.axis.min||xrange.from>xrange.axis.max||yrange.to<yrange.axis.min||yrange.from>yrange.axis.max)continue;xrange.from=Math.max(xrange.from,xrange.axis.min);xrange.to=Math.min(xrange.to,xrange.axis.max);yrange.from=Math.max(yrange.from,yrange.axis.min);yrange.to=Math.min(yrange.to,yrange.axis.max);var xequal=xrange.from===xrange.to,yequal=yrange.from===yrange.to;if(xequal&&yequal){continue}xrange.from=Math.floor(xrange.axis.p2c(xrange.from));xrange.to=Math.floor(xrange.axis.p2c(xrange.to));yrange.from=Math.floor(yrange.axis.p2c(yrange.from));yrange.to=Math.floor(yrange.axis.p2c(yrange.to));if(xequal||yequal){var lineWidth=m.lineWidth||options.grid.markingsLineWidth,subPixel=lineWidth%2?.5:0;ctx.beginPath();ctx.strokeStyle=m.color||options.grid.markingsColor;ctx.lineWidth=lineWidth;if(xequal){ctx.moveTo(xrange.to+subPixel,yrange.from);ctx.lineTo(xrange.to+subPixel,yrange.to)}else{ctx.moveTo(xrange.from,yrange.to+subPixel);ctx.lineTo(xrange.to,yrange.to+subPixel)}ctx.stroke()}else{ctx.fillStyle=m.color||options.grid.markingsColor;ctx.fillRect(xrange.from,yrange.to,xrange.to-xrange.from,yrange.from-yrange.to)}}}axes=allAxes();bw=options.grid.borderWidth;for(var j=0;j<axes.length;++j){var axis=axes[j],box=axis.box,t=axis.tickLength,x,y,xoff,yoff;if(!axis.show||axis.ticks.length==0)continue;ctx.lineWidth=1;if(axis.direction=="x"){x=0;if(t=="full")y=axis.position=="top"?0:plotHeight;else y=box.top-plotOffset.top+(axis.position=="top"?box.height:0)}else{y=0;if(t=="full")x=axis.position=="left"?0:plotWidth;else x=box.left-plotOffset.left+(axis.position=="left"?box.width:0)}if(!axis.innermost){ctx.strokeStyle=axis.options.color;ctx.beginPath();xoff=yoff=0;if(axis.direction=="x")xoff=plotWidth+1;else yoff=plotHeight+1;if(ctx.lineWidth==1){if(axis.direction=="x"){y=Math.floor(y)+.5}else{x=Math.floor(x)+.5}}ctx.moveTo(x,y);ctx.lineTo(x+xoff,y+yoff);ctx.stroke()}ctx.strokeStyle=axis.options.tickColor;ctx.beginPath();for(i=0;i<axis.ticks.length;++i){var v=axis.ticks[i].v;xoff=yoff=0;if(isNaN(v)||v<axis.min||v>axis.max||t=="full"&&(typeof bw=="object"&&bw[axis.position]>0||bw>0)&&(v==axis.min||v==axis.max))continue;if(axis.direction=="x"){x=axis.p2c(v);yoff=t=="full"?-plotHeight:t;if(axis.position=="top")yoff=-yoff}else{y=axis.p2c(v);xoff=t=="full"?-plotWidth:t;if(axis.position=="left")xoff=-xoff}if(ctx.lineWidth==1){if(axis.direction=="x")x=Math.floor(x)+.5;else y=Math.floor(y)+.5}ctx.moveTo(x,y);ctx.lineTo(x+xoff,y+yoff)}ctx.stroke()}if(bw){bc=options.grid.borderColor;if(typeof bw=="object"||typeof bc=="object"){if(typeof bw!=="object"){bw={top:bw,right:bw,bottom:bw,left:bw}}if(typeof bc!=="object"){bc={top:bc,right:bc,bottom:bc,left:bc}}if(bw.top>0){ctx.strokeStyle=bc.top;ctx.lineWidth=bw.top;ctx.beginPath();ctx.moveTo(0-bw.left,0-bw.top/2);ctx.lineTo(plotWidth,0-bw.top/2);ctx.stroke()}if(bw.right>0){ctx.strokeStyle=bc.right;ctx.lineWidth=bw.right;ctx.beginPath();ctx.moveTo(plotWidth+bw.right/2,0-bw.top);ctx.lineTo(plotWidth+bw.right/2,plotHeight);ctx.stroke()}if(bw.bottom>0){ctx.strokeStyle=bc.bottom;ctx.lineWidth=bw.bottom;ctx.beginPath();ctx.moveTo(plotWidth+bw.right,plotHeight+bw.bottom/2);ctx.lineTo(0,plotHeight+bw.bottom/2);ctx.stroke()}if(bw.left>0){ctx.strokeStyle=bc.left;ctx.lineWidth=bw.left;ctx.beginPath();ctx.moveTo(0-bw.left/2,plotHeight+bw.bottom);ctx.lineTo(0-bw.left/2,0);ctx.stroke()}}else{ctx.lineWidth=bw;ctx.strokeStyle=options.grid.borderColor;ctx.strokeRect(-bw/2,-bw/2,plotWidth+bw,plotHeight+bw)}}ctx.restore()}function drawAxisLabels(){$.each(allAxes(),function(_,axis){var box=axis.box,legacyStyles=axis.direction+"Axis "+axis.direction+axis.n+"Axis",layer="flot-"+axis.direction+"-axis flot-"+axis.direction+axis.n+"-axis "+legacyStyles,font=axis.options.font||"flot-tick-label tickLabel",tick,x,y,halign,valign;surface.removeText(layer);if(!axis.show||axis.ticks.length==0)return;for(var i=0;i<axis.ticks.length;++i){tick=axis.ticks[i];if(!tick.label||tick.v<axis.min||tick.v>axis.max)continue;if(axis.direction=="x"){halign="center";x=plotOffset.left+axis.p2c(tick.v);if(axis.position=="bottom"){y=box.top+box.padding}else{y=box.top+box.height-box.padding;valign="bottom"}}else{valign="middle";y=plotOffset.top+axis.p2c(tick.v);if(axis.position=="left"){x=box.left+box.width-box.padding;halign="right"}else{x=box.left+box.padding}}surface.addText(layer,x,y,tick.label,font,null,null,halign,valign)}})}function drawSeries(series){if(series.lines.show)drawSeriesLines(series);if(series.bars.show)drawSeriesBars(series);if(series.points.show)drawSeriesPoints(series)}function drawSeriesLines(series){function plotLine(datapoints,xoffset,yoffset,axisx,axisy){var points=datapoints.points,ps=datapoints.pointsize,prevx=null,prevy=null;ctx.beginPath();for(var i=ps;i<points.length;i+=ps){var x1=points[i-ps],y1=points[i-ps+1],x2=points[i],y2=points[i+1];if(x1==null||x2==null)continue;if(y1<=y2&&y1<axisy.min){if(y2<axisy.min)continue;x1=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.min}else if(y2<=y1&&y2<axisy.min){if(y1<axisy.min)continue;x2=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.min}if(y1>=y2&&y1>axisy.max){if(y2>axisy.max)continue;x1=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.max}else if(y2>=y1&&y2>axisy.max){if(y1>axisy.max)continue;x2=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.max}if(x1<=x2&&x1<axisx.min){if(x2<axisx.min)continue;y1=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.min}else if(x2<=x1&&x2<axisx.min){if(x1<axisx.min)continue;y2=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.min}if(x1>=x2&&x1>axisx.max){if(x2>axisx.max)continue;y1=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.max}else if(x2>=x1&&x2>axisx.max){if(x1>axisx.max)continue;y2=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.max}if(x1!=prevx||y1!=prevy)ctx.moveTo(axisx.p2c(x1)+xoffset,axisy.p2c(y1)+yoffset);prevx=x2;prevy=y2;ctx.lineTo(axisx.p2c(x2)+xoffset,axisy.p2c(y2)+yoffset)}ctx.stroke()}function plotLineArea(datapoints,axisx,axisy){var points=datapoints.points,ps=datapoints.pointsize,bottom=Math.min(Math.max(0,axisy.min),axisy.max),i=0,top,areaOpen=false,ypos=1,segmentStart=0,segmentEnd=0;while(true){if(ps>0&&i>points.length+ps)break;i+=ps;var x1=points[i-ps],y1=points[i-ps+ypos],x2=points[i],y2=points[i+ypos];if(areaOpen){if(ps>0&&x1!=null&&x2==null){segmentEnd=i;ps=-ps;ypos=2;continue}if(ps<0&&i==segmentStart+ps){ctx.fill();areaOpen=false;ps=-ps;ypos=1;i=segmentStart=segmentEnd+ps;continue}}if(x1==null||x2==null)continue;if(x1<=x2&&x1<axisx.min){if(x2<axisx.min)continue;y1=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.min}else if(x2<=x1&&x2<axisx.min){if(x1<axisx.min)continue;y2=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.min}if(x1>=x2&&x1>axisx.max){if(x2>axisx.max)continue;y1=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.max}else if(x2>=x1&&x2>axisx.max){if(x1>axisx.max)continue;y2=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.max}if(!areaOpen){ctx.beginPath();ctx.moveTo(axisx.p2c(x1),axisy.p2c(bottom));areaOpen=true}if(y1>=axisy.max&&y2>=axisy.max){ctx.lineTo(axisx.p2c(x1),axisy.p2c(axisy.max));ctx.lineTo(axisx.p2c(x2),axisy.p2c(axisy.max));continue}else if(y1<=axisy.min&&y2<=axisy.min){ctx.lineTo(axisx.p2c(x1),axisy.p2c(axisy.min));ctx.lineTo(axisx.p2c(x2),axisy.p2c(axisy.min));continue}var x1old=x1,x2old=x2;if(y1<=y2&&y1<axisy.min&&y2>=axisy.min){x1=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.min}else if(y2<=y1&&y2<axisy.min&&y1>=axisy.min){x2=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.min}if(y1>=y2&&y1>axisy.max&&y2<=axisy.max){x1=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.max}else if(y2>=y1&&y2>axisy.max&&y1<=axisy.max){x2=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.max}if(x1!=x1old){ctx.lineTo(axisx.p2c(x1old),axisy.p2c(y1))}ctx.lineTo(axisx.p2c(x1),axisy.p2c(y1));ctx.lineTo(axisx.p2c(x2),axisy.p2c(y2));if(x2!=x2old){ctx.lineTo(axisx.p2c(x2),axisy.p2c(y2));ctx.lineTo(axisx.p2c(x2old),axisy.p2c(y2))}}}ctx.save();ctx.translate(plotOffset.left,plotOffset.top);ctx.lineJoin="round";var lw=series.lines.lineWidth,sw=series.shadowSize;if(lw>0&&sw>0){ctx.lineWidth=sw;ctx.strokeStyle="rgba(0,0,0,0.1)";var angle=Math.PI/18;plotLine(series.datapoints,Math.sin(angle)*(lw/2+sw/2),Math.cos(angle)*(lw/2+sw/2),series.xaxis,series.yaxis);ctx.lineWidth=sw/2;plotLine(series.datapoints,Math.sin(angle)*(lw/2+sw/4),Math.cos(angle)*(lw/2+sw/4),series.xaxis,series.yaxis)}ctx.lineWidth=lw;ctx.strokeStyle=series.color;var fillStyle=getFillStyle(series.lines,series.color,0,plotHeight);if(fillStyle){ctx.fillStyle=fillStyle;plotLineArea(series.datapoints,series.xaxis,series.yaxis)}if(lw>0)plotLine(series.datapoints,0,0,series.xaxis,series.yaxis);ctx.restore()}function drawSeriesPoints(series){function plotPoints(datapoints,radius,fillStyle,offset,shadow,axisx,axisy,symbol){var points=datapoints.points,ps=datapoints.pointsize;for(var i=0;i<points.length;i+=ps){var x=points[i],y=points[i+1];if(x==null||x<axisx.min||x>axisx.max||y<axisy.min||y>axisy.max)continue;ctx.beginPath();x=axisx.p2c(x);y=axisy.p2c(y)+offset;if(symbol=="circle")ctx.arc(x,y,radius,0,shadow?Math.PI:Math.PI*2,false);else symbol(ctx,x,y,radius,shadow);ctx.closePath();if(fillStyle){ctx.fillStyle=fillStyle;ctx.fill()}ctx.stroke()}}ctx.save();ctx.translate(plotOffset.left,plotOffset.top);var lw=series.points.lineWidth,sw=series.shadowSize,radius=series.points.radius,symbol=series.points.symbol;if(lw==0)lw=1e-4;if(lw>0&&sw>0){var w=sw/2;ctx.lineWidth=w;ctx.strokeStyle="rgba(0,0,0,0.1)";plotPoints(series.datapoints,radius,null,w+w/2,true,series.xaxis,series.yaxis,symbol);ctx.strokeStyle="rgba(0,0,0,0.2)";plotPoints(series.datapoints,radius,null,w/2,true,series.xaxis,series.yaxis,symbol)}ctx.lineWidth=lw;ctx.strokeStyle=series.color;plotPoints(series.datapoints,radius,getFillStyle(series.points,series.color),0,false,series.xaxis,series.yaxis,symbol);ctx.restore()}function drawBar(x,y,b,barLeft,barRight,fillStyleCallback,axisx,axisy,c,horizontal,lineWidth){var left,right,bottom,top,drawLeft,drawRight,drawTop,drawBottom,tmp;if(horizontal){drawBottom=drawRight=drawTop=true;drawLeft=false;left=b;right=x;top=y+barLeft;bottom=y+barRight;if(right<left){tmp=right;right=left;left=tmp;drawLeft=true;drawRight=false}}else{drawLeft=drawRight=drawTop=true;drawBottom=false;left=x+barLeft;right=x+barRight;bottom=b;top=y;if(top<bottom){tmp=top;top=bottom;bottom=tmp;drawBottom=true;drawTop=false}}if(right<axisx.min||left>axisx.max||top<axisy.min||bottom>axisy.max)return;if(left<axisx.min){left=axisx.min;drawLeft=false}if(right>axisx.max){right=axisx.max;drawRight=false}if(bottom<axisy.min){bottom=axisy.min;drawBottom=false}if(top>axisy.max){top=axisy.max;drawTop=false}left=axisx.p2c(left);bottom=axisy.p2c(bottom);right=axisx.p2c(right);top=axisy.p2c(top);if(fillStyleCallback){c.fillStyle=fillStyleCallback(bottom,top);c.fillRect(left,top,right-left,bottom-top)}if(lineWidth>0&&(drawLeft||drawRight||drawTop||drawBottom)){c.beginPath();c.moveTo(left,bottom);if(drawLeft)c.lineTo(left,top);else c.moveTo(left,top);if(drawTop)c.lineTo(right,top);else c.moveTo(right,top);if(drawRight)c.lineTo(right,bottom);else c.moveTo(right,bottom);if(drawBottom)c.lineTo(left,bottom);else c.moveTo(left,bottom);c.stroke()}}function drawSeriesBars(series){function plotBars(datapoints,barLeft,barRight,fillStyleCallback,axisx,axisy){var points=datapoints.points,ps=datapoints.pointsize;for(var i=0;i<points.length;i+=ps){if(points[i]==null)continue;drawBar(points[i],points[i+1],points[i+2],barLeft,barRight,fillStyleCallback,axisx,axisy,ctx,series.bars.horizontal,series.bars.lineWidth)}}ctx.save();ctx.translate(plotOffset.left,plotOffset.top);ctx.lineWidth=series.bars.lineWidth;ctx.strokeStyle=series.color;var barLeft;switch(series.bars.align){case"left":barLeft=0;break;case"right":barLeft=-series.bars.barWidth;break;default:barLeft=-series.bars.barWidth/2}var fillStyleCallback=series.bars.fill?function(bottom,top){return getFillStyle(series.bars,series.color,bottom,top)}:null;plotBars(series.datapoints,barLeft,barLeft+series.bars.barWidth,fillStyleCallback,series.xaxis,series.yaxis);ctx.restore()}function getFillStyle(filloptions,seriesColor,bottom,top){var fill=filloptions.fill;if(!fill)return null;if(filloptions.fillColor)return getColorOrGradient(filloptions.fillColor,bottom,top,seriesColor);var c=$.color.parse(seriesColor);c.a=typeof fill=="number"?fill:.4;c.normalize();return c.toString()}function insertLegend(){if(options.legend.container!=null){$(options.legend.container).html("")}else{placeholder.find(".legend").remove()}if(!options.legend.show){return}var fragments=[],entries=[],rowStarted=false,lf=options.legend.labelFormatter,s,label;for(var i=0;i<series.length;++i){s=series[i];if(s.label){label=lf?lf(s.label,s):s.label;if(label){entries.push({label:label,color:s.color})}}}if(options.legend.sorted){if($.isFunction(options.legend.sorted)){entries.sort(options.legend.sorted)}else if(options.legend.sorted=="reverse"){entries.reverse()}else{var ascending=options.legend.sorted!="descending";entries.sort(function(a,b){return a.label==b.label?0:a.label<b.label!=ascending?1:-1})}}for(var i=0;i<entries.length;++i){var entry=entries[i];if(i%options.legend.noColumns==0){if(rowStarted)fragments.push("</tr>");fragments.push("<tr>");rowStarted=true}fragments.push('<td class="legendColorBox"><div style="border:1px solid '+options.legend.labelBoxBorderColor+';padding:1px"><div style="width:4px;height:0;border:5px solid '+entry.color+';overflow:hidden"></div></div></td>'+'<td class="legendLabel">'+entry.label+"</td>")}if(rowStarted)fragments.push("</tr>");if(fragments.length==0)return;var table='<table style="font-size:smaller;color:'+options.grid.color+'">'+fragments.join("")+"</table>";if(options.legend.container!=null)$(options.legend.container).html(table);else{var pos="",p=options.legend.position,m=options.legend.margin;if(m[0]==null)m=[m,m];if(p.charAt(0)=="n")pos+="top:"+(m[1]+plotOffset.top)+"px;";else if(p.charAt(0)=="s")pos+="bottom:"+(m[1]+plotOffset.bottom)+"px;";if(p.charAt(1)=="e")pos+="right:"+(m[0]+plotOffset.right)+"px;";else if(p.charAt(1)=="w")pos+="left:"+(m[0]+plotOffset.left)+"px;";var legend=$('<div class="legend">'+table.replace('style="','style="position:absolute;'+pos+";")+"</div>").appendTo(placeholder);if(options.legend.backgroundOpacity!=0){var c=options.legend.backgroundColor;if(c==null){c=options.grid.backgroundColor;if(c&&typeof c=="string")c=$.color.parse(c);else c=$.color.extract(legend,"background-color");c.a=1;c=c.toString()}var div=legend.children();$('<div style="position:absolute;width:'+div.width()+"px;height:"+div.height()+"px;"+pos+"background-color:"+c+';"> </div>').prependTo(legend).css("opacity",options.legend.backgroundOpacity)}}}var highlights=[],redrawTimeout=null;function findNearbyItem(mouseX,mouseY,seriesFilter){var maxDistance=options.grid.mouseActiveRadius,smallestDistance=maxDistance*maxDistance+1,item=null,foundPoint=false,i,j,ps;for(i=series.length-1;i>=0;--i){if(!seriesFilter(series[i]))continue;var s=series[i],axisx=s.xaxis,axisy=s.yaxis,points=s.datapoints.points,mx=axisx.c2p(mouseX),my=axisy.c2p(mouseY),maxx=maxDistance/axisx.scale,maxy=maxDistance/axisy.scale;ps=s.datapoints.pointsize;if(axisx.options.inverseTransform)maxx=Number.MAX_VALUE;if(axisy.options.inverseTransform)maxy=Number.MAX_VALUE;if(s.lines.show||s.points.show){for(j=0;j<points.length;j+=ps){var x=points[j],y=points[j+1];if(x==null)continue;if(x-mx>maxx||x-mx<-maxx||y-my>maxy||y-my<-maxy)continue;var dx=Math.abs(axisx.p2c(x)-mouseX),dy=Math.abs(axisy.p2c(y)-mouseY),dist=dx*dx+dy*dy;if(dist<smallestDistance){smallestDistance=dist;item=[i,j/ps]}}}if(s.bars.show&&!item){var barLeft,barRight;switch(s.bars.align){case"left":barLeft=0;break;case"right":barLeft=-s.bars.barWidth;break;default:barLeft=-s.bars.barWidth/2}barRight=barLeft+s.bars.barWidth;for(j=0;j<points.length;j+=ps){var x=points[j],y=points[j+1],b=points[j+2];if(x==null)continue;if(series[i].bars.horizontal?mx<=Math.max(b,x)&&mx>=Math.min(b,x)&&my>=y+barLeft&&my<=y+barRight:mx>=x+barLeft&&mx<=x+barRight&&my>=Math.min(b,y)&&my<=Math.max(b,y))item=[i,j/ps]}}}if(item){i=item[0];j=item[1];ps=series[i].datapoints.pointsize;return{datapoint:series[i].datapoints.points.slice(j*ps,(j+1)*ps),dataIndex:j,series:series[i],seriesIndex:i}}return null}function onMouseMove(e){if(options.grid.hoverable)triggerClickHoverEvent("plothover",e,function(s){return s["hoverable"]!=false})}function onMouseLeave(e){if(options.grid.hoverable)triggerClickHoverEvent("plothover",e,function(s){return false})}function onClick(e){triggerClickHoverEvent("plotclick",e,function(s){return s["clickable"]!=false})}function triggerClickHoverEvent(eventname,event,seriesFilter){var offset=eventHolder.offset(),canvasX=event.pageX-offset.left-plotOffset.left,canvasY=event.pageY-offset.top-plotOffset.top,pos=canvasToAxisCoords({left:canvasX,top:canvasY});pos.pageX=event.pageX;pos.pageY=event.pageY;var item=findNearbyItem(canvasX,canvasY,seriesFilter);if(item){item.pageX=parseInt(item.series.xaxis.p2c(item.datapoint[0])+offset.left+plotOffset.left,10);item.pageY=parseInt(item.series.yaxis.p2c(item.datapoint[1])+offset.top+plotOffset.top,10)}if(options.grid.autoHighlight){for(var i=0;i<highlights.length;++i){var h=highlights[i];if(h.auto==eventname&&!(item&&h.series==item.series&&h.point[0]==item.datapoint[0]&&h.point[1]==item.datapoint[1]))unhighlight(h.series,h.point)}if(item)highlight(item.series,item.datapoint,eventname)}placeholder.trigger(eventname,[pos,item])}function triggerRedrawOverlay(){var t=options.interaction.redrawOverlayInterval;if(t==-1){drawOverlay();return}if(!redrawTimeout)redrawTimeout=setTimeout(drawOverlay,t)}function drawOverlay(){redrawTimeout=null;octx.save();overlay.clear();octx.translate(plotOffset.left,plotOffset.top);var i,hi;for(i=0;i<highlights.length;++i){hi=highlights[i];if(hi.series.bars.show)drawBarHighlight(hi.series,hi.point);else drawPointHighlight(hi.series,hi.point)}octx.restore();executeHooks(hooks.drawOverlay,[octx])}function highlight(s,point,auto){if(typeof s=="number")s=series[s];if(typeof point=="number"){var ps=s.datapoints.pointsize;point=s.datapoints.points.slice(ps*point,ps*(point+1))}var i=indexOfHighlight(s,point);if(i==-1){highlights.push({series:s,point:point,auto:auto});triggerRedrawOverlay()}else if(!auto)highlights[i].auto=false}function unhighlight(s,point){if(s==null&&point==null){highlights=[];triggerRedrawOverlay();return}if(typeof s=="number")s=series[s];if(typeof point=="number"){var ps=s.datapoints.pointsize;point=s.datapoints.points.slice(ps*point,ps*(point+1))}var i=indexOfHighlight(s,point);if(i!=-1){highlights.splice(i,1);triggerRedrawOverlay()}}function indexOfHighlight(s,p){for(var i=0;i<highlights.length;++i){var h=highlights[i];if(h.series==s&&h.point[0]==p[0]&&h.point[1]==p[1])return i}return-1}function drawPointHighlight(series,point){var x=point[0],y=point[1],axisx=series.xaxis,axisy=series.yaxis,highlightColor=typeof series.highlightColor==="string"?series.highlightColor:$.color.parse(series.color).scale("a",.5).toString();if(x<axisx.min||x>axisx.max||y<axisy.min||y>axisy.max)return;var pointRadius=series.points.radius+series.points.lineWidth/2;octx.lineWidth=pointRadius;octx.strokeStyle=highlightColor;var radius=1.5*pointRadius;x=axisx.p2c(x);y=axisy.p2c(y);octx.beginPath();if(series.points.symbol=="circle")octx.arc(x,y,radius,0,2*Math.PI,false);else series.points.symbol(octx,x,y,radius,false);octx.closePath();octx.stroke()}function drawBarHighlight(series,point){var highlightColor=typeof series.highlightColor==="string"?series.highlightColor:$.color.parse(series.color).scale("a",.5).toString(),fillStyle=highlightColor,barLeft;switch(series.bars.align){case"left":barLeft=0;break;case"right":barLeft=-series.bars.barWidth;break;default:barLeft=-series.bars.barWidth/2}octx.lineWidth=series.bars.lineWidth;octx.strokeStyle=highlightColor;drawBar(point[0],point[1],point[2]||0,barLeft,barLeft+series.bars.barWidth,function(){return fillStyle},series.xaxis,series.yaxis,octx,series.bars.horizontal,series.bars.lineWidth)}function getColorOrGradient(spec,bottom,top,defaultColor){if(typeof spec=="string")return spec;else{var gradient=ctx.createLinearGradient(0,top,0,bottom);for(var i=0,l=spec.colors.length;i<l;++i){var c=spec.colors[i];if(typeof c!="string"){var co=$.color.parse(defaultColor);if(c.brightness!=null)co=co.scale("rgb",c.brightness);if(c.opacity!=null)co.a*=c.opacity;c=co.toString()}gradient.addColorStop(i/(l-1),c)}return gradient}}}$.plot=function(placeholder,data,options){var plot=new Plot($(placeholder),data,options,$.plot.plugins);return plot};$.plot.version="0.8.3";$.plot.plugins=[];$.fn.plot=function(data,options){return this.each(function(){$.plot(this,data,options)})};function floorInBase(n,base){return base*Math.floor(n/base)}})(jQuery);+ </script>+ <script language="javascript" type="text/javascript">+ (function ($) {+ $.zip = function(a,b) {+ var x = Math.min(a.length,b.length);+ var c = new Array(x);+ for (var i = 0; i < x; i++)+ c[i] = [a[i],b[i]];+ return c;+ };++ $.mean = function(ary) {+ var m = 0, i = 0;++ while (i < ary.length) {+ var j = i++;+ m += (ary[j] - m) / i;+ }++ return m;+ };++ $.timeUnits = function(secs) {+ if (secs < 0) return $.timeUnits(-secs);+ else if (secs >= 1e9) return [1e-9, "Gs"];+ else if (secs >= 1e6) return [1e-6, "Ms"];+ else if (secs >= 1) return [1, "s"];+ else if (secs >= 1e-3) return [1e3, "ms"];+ else if (secs >= 1e-6) return [1e6, "\u03bcs"];+ else if (secs >= 1e-9) return [1e9, "ns"];+ else if (secs >= 1e-12) return [1e12, "ps"];+ return [1, "s"];+ };++ $.scaleTimes = function(ary) {+ var s = $.timeUnits($.mean(ary));+ return [$.scaleBy(s[0], ary), s[0]];+ };++ $.prepareTime = function(secs) {+ var units = $.timeUnits(secs);+ var scaled = secs * units[0];+ var s = scaled.toPrecision(3);+ var t = scaled.toString();+ return [t.length < s.length ? t : s, units[1]];+ };++ $.scaleBy = function(x, ary) {+ var nary = new Array(ary.length);+ for (var i = 0; i < ary.length; i++)+ nary[i] = ary[i] * x;+ return nary;+ };++ $.renderTime = function(secs) {+ var x = $.prepareTime(secs);+ return x[0] + ' ' + x[1];+ };++ $.unitFormatter = function(scale) {+ var labelname;+ return function(secs,axis) {+ var x = $.prepareTime(secs / scale);+ if (labelname === x[1])+ return x[0];+ else {+ labelname = x[1];+ return x[0] + ' ' + x[1];+ }+ };+ };++ $.addTooltip = function(name, renderText) {+ function showTooltip(x, y, contents) {+ $('<div id="tooltip">' + contents + '</div>').css( {+ position: 'absolute',+ display: 'none',+ top: y + 5,+ left: x + 5,+ border: '1px solid #fdd',+ padding: '2px',+ 'background-color': '#fee',+ opacity: 0.80+ }).appendTo("body").fadeIn(200);+ };+ var pp = null;+ $(name).bind("plothover", function (event, pos, item) {+ $("#x").text(pos.x.toFixed(2));+ $("#y").text(pos.y.toFixed(2));++ if (item) {+ if (pp != item.dataIndex) {+ pp = item.dataIndex;++ $("#tooltip").remove();+ var x = item.datapoint[0],+ y = item.datapoint[1];++ showTooltip(item.pageX, item.pageY, renderText(x,y));+ }+ }+ else {+ $("#tooltip").remove();+ pp = null;+ }+ });+ };+})(jQuery);++ </script>+ <style type="text/css">+html, body {+ height: 100%;+ margin: 0;+}++#wrap {+ min-height: 100%;+}++#main {+ overflow: auto;+ padding-bottom: 180px; /* must be same height as the footer */+}++#footer {+ position: relative;+ margin-top: -180px; /* negative value of footer height */+ height: 180px;+ clear: both;+ background: #888;+ margin: 40px 0 0;+ color: white;+ font-size: larger;+ font-weight: 300;+}++body:before {+ /* Opera fix */+ content: "";+ height: 100%;+ float: left;+ width: 0;+ margin-top: -32767px;+}++body {+ font: 14px Helvetica Neue;+ text-rendering: optimizeLegibility;+ margin-top: 1em;+}++a:link {+ color: steelblue;+ text-decoration: none;+}++a:visited {+ color: #4a743b;+ text-decoration: none;+}++#footer a {+ color: white;+ text-decoration: underline;+}++.hover {+ color: steelblue;+ text-decoration: none;+}++.body {+ width: 960px;+ margin: auto;+}++.footfirst {+ position: relative;+ top: 30px;+}++th {+ font-weight: 500;+ opacity: 0.8;+}++th.cibound {+ opacity: 0.4;+}++.confinterval {+ opacity: 0.5;+}++h1 {+ font-size: 36px;+ font-weight: 300;+ margin-bottom: .3em;+}++h2 {+ font-size: 30px;+ font-weight: 300;+ margin-bottom: .3em;+}++.meanlegend {+ color: #404040;+ background-color: #ffffff;+ opacity: 0.6;+ font-size: smaller;+}++ </style>+ <!--[if !IE 7]>+ <style type="text/css">+ #wrap {display:table;height:100%}+ </style>+ <![endif]-->+ </head>+ <body>+ <div id="wrap">+ <div id="main" class="body">+ <h1>criterion performance measurements</h1>++<h2>overview</h2>++<p><a href="#grokularation">want to understand this report?</a></p>++<div id="overview" class="ovchart" style="width:900px;height:100px;"></div>++<h2><a name="b0">ByteString/HashMap/random</a></h2>+ <table width="100%">+ <tbody>+ <tr>+ <td><div id="kde0" class="kdechart"+ style="width:450px;height:278px;"></div></td>+ <td><div id="time0" class="timechart"+ style="width:450px;height:278px;"></div></td>+<!--+ <td><div id="cycle0" class="cyclechart"+ style="width:300px;height:278px;"></div></td>+-->+ </tr>+ </tbody>+ </table>++ <table>+ <thead class="analysis">+ <th></th>+ <th class="cibound"+ title="0.95 confidence level">lower bound</th>+ <th>estimate</th>+ <th class="cibound"+ title="0.95 confidence level">upper bound</th>+ </thead>+ <tbody>+ <tr>+ <td>OLS regression</td>+ <td><span class="confinterval olstimelb0">xxx</span></td>+ <td><span class="olstimept0">xxx</span></td>+ <td><span class="confinterval olstimeub0">xxx</span></td>+ </tr>+ <tr>+ <td>R² goodness-of-fit</td>+ <td><span class="confinterval olsr2lb0">xxx</span></td>+ <td><span class="olsr2pt0">xxx</span></td>+ <td><span class="confinterval olsr2ub0">xxx</span></td>+ </tr>+ <tr>+ <td>Mean execution time</td>+ <td><span class="confinterval citime">5.54613319607341e-3</span></td>+ <td><span class="time">5.621667703915931e-3</span></td>+ <td><span class="confinterval citime">5.713526073454561e-3</span></td>+ </tr>+ <tr>+ <td>Standard deviation</td>+ <td><span class="confinterval citime">1.972562820146363e-4</span></td>+ <td><span class="time">2.494938876886024e-4</span></td>+ <td><span class="confinterval citime">3.1487131555210624e-4</span></td>+ </tr>+ </tbody>+ </table>++ <span class="outliers">+ <p>Outlying measurements have moderate+ (<span class="percent">0.21993690418913867</span>%)+ effect on estimated standard deviation.</p>+ </span>++ <h2><a name="grokularation">understanding this report</a></h2>++ <p>In this report, each function benchmarked by criterion is assigned+ a section of its own. The charts in each section are active; if+ you hover your mouse over data points and annotations, you will see+ more details.</p>++ <ul>+ <li>The chart on the left is a+ <a href="http://en.wikipedia.org/wiki/Kernel_density_estimation">kernel+ density estimate</a> (also known as a KDE) of time+ measurements. This graphs the probability of any given time+ measurement occurring. A spike indicates that a measurement of a+ particular time occurred; its height indicates how often that+ measurement was repeated.</li>++ <li>The chart on the right is the raw data from which the kernel+ density estimate is built. The <i>x</i> axis indicates the+ number of loop iterations, while the <i>y</i> axis shows measured+ execution time for the given number of loop iterations. The+ line behind the values is the linear regression prediction of+ execution time for a given number of iterations. Ideally, all+ measurements will be on (or very near) this line.</li>+ </ul>++ <p>Under the charts is a small table.+ The first two rows are the results of a linear regression run+ on the measurements displayed in the right-hand chart.</p>++ <ul>+ <li><i>OLS regression</i> indicates the+ time estimated for a single loop iteration using an ordinary+ least-squares regression model. This number is more accurate+ than the <i>mean</i> estimate below it, as it more effectively+ eliminates measurement overhead and other constant factors.</li>+ <li><i>R² goodness-of-fit</i> is a measure of how+ accurately the linear regression model fits the observed+ measurements. If the measurements are not too noisy, R²+ should lie between 0.99 and 1, indicating an excellent fit. If+ the number is below 0.99, something is confounding the accuracy+ of the linear model.</li>+ <li><i>Mean execution time</i> and <i>standard deviation</i> are+ statistics calculated from execution time+ divided by number of iterations.</li>+ </ul>++ <p>We use a statistical technique called+ the <a href="http://en.wikipedia.org/wiki/Bootstrapping_(statistics)">bootstrap</a>+ to provide confidence intervals on our estimates. The+ bootstrap-derived upper and lower bounds on estimates let you see+ how accurate we believe those estimates to be. (Hover the mouse+ over the table headers to see the confidence levels.)</p>++ <p>A noisy benchmarking environment can cause some or many+ measurements to fall far from the mean. These outlying+ measurements can have a significant inflationary effect on the+ estimate of the standard deviation. We calculate and display an+ estimate of the extent to which the standard deviation has been+ inflated by outliers.</p>++<script type="text/javascript">+$(function () {+ function mangulate(rpt) {+ var measured = function(key) {+ var idx = rpt.reportKeys.indexOf(key);+ return rpt.reportMeasured.map(function(r) { return r[idx]; });+ };+ var number = rpt.reportNumber;+ var name = rpt.reportName;+ var mean = rpt.reportAnalysis.anMean.estPoint;+ var iters = measured("iters");+ var times = measured("time");+ var kdetimes = rpt.reportKDEs[0].kdeValues;+ var kdepdf = rpt.reportKDEs[0].kdePDF;++ var meanSecs = mean;+ var units = $.timeUnits(mean);+ var rgrs = rpt.reportAnalysis.anRegress[0];+ var scale = units[0];+ var olsTime = rgrs.regCoeffs.iters;+ $(".olstimept" + number).text(function() {+ return $.renderTime(olsTime.estPoint);+ });+ $(".olstimelb" + number).text(function() {+ return $.renderTime(olsTime.estLowerBound);+ });+ $(".olstimeub" + number).text(function() {+ return $.renderTime(olsTime.estUpperBound);+ });+ $(".olsr2pt" + number).text(function() {+ return rgrs.regRSquare.estPoint.toFixed(3);+ });+ $(".olsr2lb" + number).text(function() {+ return rgrs.regRSquare.estLowerBound.toFixed(3);+ });+ $(".olsr2ub" + number).text(function() {+ return rgrs.regRSquare.estUpperBound.toFixed(3);+ });+ mean *= scale;+ kdetimes = $.scaleBy(scale, kdetimes);+ var kq = $("#kde" + number);+ var k = $.plot(kq,+ [{ label: name + " time densities",+ data: $.zip(kdetimes, kdepdf),+ }],+ { xaxis: { tickFormatter: $.unitFormatter(scale) },+ yaxis: { ticks: false },+ grid: { borderColor: "#777",+ hoverable: true, markings: [ { color: '#6fd3fb',+ lineWidth: 1.5, xaxis: { from: mean, to: mean } } ] },+ });+ var o = k.pointOffset({ x: mean, y: 0});+ kq.append('<div class="meanlegend" title="' + $.renderTime(meanSecs) ++ '" style="position:absolute;left:' + (o.left + 4) ++ 'px;bottom:139px;">mean</div>');+ $.addTooltip("#kde" + number,+ function(secs) { return $.renderTime(secs / scale); });+ var timepairs = new Array(times.length);+ var lastiter = iters[iters.length-1];+ var olspairs = [[0,0], [lastiter, lastiter * scale * olsTime.estPoint]];+ for (var i = 0; i < times.length; i++)+ timepairs[i] = [iters[i],times[i]*scale];+ iterFormatter = function() {+ var denom = 0;+ return function(iters) {+ if (iters == 0)+ return '';+ if (denom > 0)+ return (iters / denom).toFixed();+ var power;+ if (iters >= 1e9) {+ denom = '1e9'; power = '⁹';+ }+ if (iters >= 1e6) {+ denom = '1e6'; power = '⁶';+ }+ else if (iters >= 1e3) {+ denom = '1e3'; power = '³';+ }+ else denom = 1;+ if (denom > 1) {+ iters = (iters / denom).toFixed();+ iters += '×10' + power + ' iters';+ } else {+ iters += ' iters';+ }+ return iters;+ };+ };+ $.plot($("#time" + number),+ [{ label: "regression", data: olspairs,+ lines: { show: true } },+ { label: name + " times", data: timepairs,+ points: { show: true } }],+ { grid: { borderColor: "#777", hoverable: true },+ xaxis: { tickFormatter: iterFormatter() },+ yaxis: { tickFormatter: $.unitFormatter(scale) } });+ $.addTooltip("#time" + number,+ function(iters,secs) {+ return ($.renderTime(secs / scale) + ' / ' ++ iters.toLocaleString() + ' iters');+ });+ if (0) {+ var cyclepairs = new Array(cycles.length);+ for (var i = 0; i < cycles.length; i++)+ cyclepairs[i] = [cycles[i],i];+ $.plot($("#cycle" + number),+ [{ label: name + " cycles",+ data: cyclepairs }],+ { points: { show: true },+ grid: { borderColor: "#777", hoverable: true },+ xaxis: { tickFormatter:+ function(cycles,axis) { return cycles + ' cycles'; }},+ yaxis: { ticks: false },+ });+ $.addTooltip("#cycles" + number, function(x,y) { return x + ' cycles'; });+ }+ };+ var reports = [{"reportAnalysis":{"anMean":{"estUpperBound":5.713526073454561e-3,"estLowerBound":5.54613319607341e-3,"estPoint":5.621667703915931e-3,"estConfidenceLevel":0.95},"anRegress":[{"regRSquare":{"estUpperBound":0.9981729010272332,"estLowerBound":0.9933906306034458,"estPoint":0.9962485177728473,"estConfidenceLevel":0.95},"regResponder":"time","regCoeffs":{"y":{"estUpperBound":1.73831239286272e-3,"estLowerBound":-2.6907153863794868e-3,"estPoint":-5.701833877751966e-4,"estConfidenceLevel":0.95},"iters":{"estUpperBound":5.78662208554795e-3,"estLowerBound":5.560561655965624e-3,"estPoint":5.671235930328669e-3,"estConfidenceLevel":0.95}}}],"anStdDev":{"estUpperBound":3.1487131555210624e-4,"estLowerBound":1.972562820146363e-4,"estPoint":2.494938876886024e-4,"estConfidenceLevel":0.95},"anOutlierVar":{"ovFraction":0.21993690418913867,"ovDesc":"moderate","ovEffect":"Moderate"},"anOverhead":2.7511337567346434e-6},"reportKDEs":[{"kdeValues":[5.119598999459214e-3,5.128773133785027e-3,5.137947268110841e-3,5.1471214024366545e-3,5.156295536762469e-3,5.165469671088282e-3,5.174643805414095e-3,5.1838179397399094e-3,5.192992074065723e-3,5.202166208391536e-3,5.21134034271735e-3,5.2205144770431635e-3,5.229688611368978e-3,5.238862745694791e-3,5.248036880020604e-3,5.2572110143464185e-3,5.266385148672232e-3,5.275559282998045e-3,5.284733417323859e-3,5.293907551649673e-3,5.303081685975487e-3,5.3122558203013e-3,5.321429954627113e-3,5.3306040889529276e-3,5.339778223278741e-3,5.348952357604554e-3,5.358126491930368e-3,5.367300626256182e-3,5.376474760581996e-3,5.385648894907809e-3,5.3948230292336224e-3,5.403997163559437e-3,5.41317129788525e-3,5.422345432211064e-3,5.431519566536877e-3,5.440693700862691e-3,5.449867835188505e-3,5.459041969514318e-3,5.4682161038401315e-3,5.477390238165946e-3,5.486564372491759e-3,5.495738506817573e-3,5.5049126411433865e-3,5.5140867754692e-3,5.523260909795014e-3,5.532435044120827e-3,5.541609178446641e-3,5.550783312772455e-3,5.559957447098268e-3,5.569131581424082e-3,5.5783057157498955e-3,5.587479850075709e-3,5.596653984401523e-3,5.605828118727336e-3,5.6150022530531505e-3,5.624176387378964e-3,5.633350521704777e-3,5.642524656030591e-3,5.651698790356405e-3,5.660872924682218e-3,5.670047059008032e-3,5.679221193333845e-3,5.688395327659659e-3,5.697569461985473e-3,5.706743596311286e-3,5.7159177306371e-3,5.725091864962914e-3,5.734265999288727e-3,5.743440133614541e-3,5.7526142679403544e-3,5.761788402266169e-3,5.770962536591982e-3,5.780136670917795e-3,5.789310805243609e-3,5.798484939569423e-3,5.807659073895236e-3,5.81683320822105e-3,5.8260073425468635e-3,5.835181476872677e-3,5.844355611198491e-3,5.853529745524304e-3,5.8627038798501185e-3,5.871878014175932e-3,5.881052148501745e-3,5.890226282827559e-3,5.8994004171533726e-3,5.908574551479187e-3,5.917748685805e-3,5.926922820130813e-3,5.9360969544566275e-3,5.945271088782441e-3,5.954445223108255e-3,5.963619357434068e-3,5.972793491759882e-3,5.981967626085696e-3,5.991141760411509e-3,6.000315894737322e-3,6.009490029063137e-3,6.01866416338895e-3,6.027838297714763e-3,6.037012432040577e-3,6.046186566366391e-3,6.055360700692205e-3,6.064534835018018e-3,6.0737089693438315e-3,6.082883103669646e-3,6.092057237995459e-3,6.101231372321273e-3,6.1104055066470864e-3,6.1195796409729e-3,6.128753775298714e-3,6.137927909624527e-3,6.147102043950341e-3,6.156276178276155e-3,6.165450312601968e-3,6.174624446927781e-3,6.1837985812535955e-3,6.192972715579409e-3,6.202146849905223e-3,6.211320984231036e-3,6.22049511855685e-3,6.229669252882664e-3,6.238843387208477e-3,6.248017521534291e-3,6.2571916558601046e-3,6.266365790185918e-3,6.275539924511732e-3,6.284714058837545e-3],"kdeType":"time","kdePDF":[545.3406018643898,547.7604964408598,552.5835234544184,559.7762994995815,569.2891013325717,581.0562871577982,594.9968565868016,611.0151474314513,629.0016666408812,648.8340516123199,670.3781567871325,693.4892588878535,718.0133723788433,743.7886647772734,770.646959352757,798.4153105965786,826.9176356903382,855.9763831421388,885.414217874883,915.0557004354534,944.7289367329893,974.2671738896564,1003.5103174688135,1032.3063455895392,1060.5125962828472,1087.9969059134382,1114.638578580714,1140.3291691007228,1164.9730654118175,1188.4878599745812,1210.804503865528,1231.8672416915,1251.6333300617102,1270.0725470211678,1287.166504442057,1302.9077797566918,1317.2988874695457,1330.3511144872584,1342.0832463483428,1352.5202138285747,1361.6916910736854,1369.630677319676,1376.372094378115,1381.9514313884627,1386.4034668948157,1389.7610961362368,1392.0542886142364,1393.3091976024104,1393.5474393905565,1392.7855558190963,1391.0346691763316,1388.3003339216605,1384.5825850817816,1379.8761786596651,1374.1710151048017,1367.4527329151629,1359.703455859914,1350.9026741969292,1341.028237663689,1330.057435982098,1317.9681411582083,1304.739984983345,1290.35554484537,1274.801511217554,1258.0698109758134,1240.1586619629556,1221.0735359229834,1200.8280090176215,1179.4444815546556,1156.9547512468462,1133.4004272230616,1108.8331750741968,1083.314786380294,1056.9170693808599,1029.7215606678844,1001.8190609552112,973.309001064742,944.2986472297946,914.9021576099989,885.2395045052625,855.4352791137583,825.6173977689432,795.9157303818314,766.4606732786749,737.3816897331639,708.8058422221862,680.8563407630685,653.6511316010611,627.3015499956838,601.9110598974106,577.5741019124631,554.3750691326807,532.3874281777079,511.6730001869569,492.2814135481128,474.24973690783065,457.6022975395997,442.35068651491076,428.4939484168154,416.0189496374037,404.9009157051916,395.1041246902782,386.58274062916485,379.28176818856923,373.1381075322609,368.08168664034343,364.03664721565093,360.9225598393534,358.6556442299356,357.1499713174148,356.31862534611537,356.0748063195876,356.3328557329458,357.00919161294235,358.0231422981528,359.29767202005786,360.7599950594725,362.34207891564233,363.98104040137895,365.61944173689216,367.2054964387313,368.6931969866561,370.04237781945346,371.21872810527947,372.19376892518954,372.9448090019323,373.45489193123836,373.7127460898599]}],"reportKeys":["time","cpuTime","cycles","iters","allocated","numGcs","bytesCopied","mutatorWallSeconds","mutatorCpuSeconds","gcWallSeconds","gcCpuSeconds"],"reportNumber":0,"reportName":"ByteString/HashMap/random","reportOutliers":{"highSevere":0,"highMild":0,"lowMild":0,"samplesSeen":34,"lowSevere":0},"reportMeasured":[[4.97827198705636e-3,4.97199999999999e-3,10935260,1,null,null,null,null,null,null,null],[1.0848715988686308e-2,1.0847999999999997e-2,23877636,2,null,null,null,null,null,null,null],[1.7607376008527353e-2,1.7608e-2,38752116,3,null,null,null,null,null,null,null],[2.2017084003891796e-2,2.201800000000001e-2,48451954,4,null,null,null,null,null,null,null],[2.8329552995273843e-2,2.8330000000000022e-2,62340584,5,null,null,null,null,null,null,null],[3.288370498921722e-2,3.2885e-2,72359180,6,null,null,null,null,null,null,null],[3.651821901439689e-2,3.6518999999999996e-2,80349114,7,null,null,null,null,null,null,null],[4.358184800366871e-2,4.358200000000001e-2,95888910,8,null,null,null,null,null,null,null],[4.937931601307355e-2,4.937999999999998e-2,108645950,9,null,null,null,null,null,null,null],[5.358721798984334e-2,5.3586999999999996e-2,117903888,10,null,null,null,null,null,null,null],[5.955264199292287e-2,5.9538000000000035e-2,131027266,11,null,null,null,null,null,null,null],[6.518080999376252e-2,6.518099999999993e-2,143410836,12,null,null,null,null,null,null,null],[7.247712599928491e-2,7.247799999999993e-2,159464728,13,null,null,null,null,null,null,null],[8.270343899494037e-2,8.269899999999997e-2,181965766,14,null,null,null,null,null,null,null],[9.246958102448843e-2,9.240900000000007e-2,203443998,15,null,null,null,null,null,null,null],[9.887698100646958e-2,9.882600000000019e-2,217539578,16,null,null,null,null,null,null,null],[9.008563501993194e-2,9.0086e-2,198198564,17,null,null,null,null,null,null,null],[9.605592401931062e-2,9.605600000000003e-2,211332948,18,null,null,null,null,null,null,null],[0.1098186599847395,0.10976399999999997,241619440,19,null,null,null,null,null,null,null],[0.11373145499965176,0.11368299999999998,250220460,20,null,null,null,null,null,null,null],[0.11196174900396727,0.11196300000000003,246324226,21,null,null,null,null,null,null,null],[0.11884062600438483,0.11883500000000025,261465680,22,null,null,null,null,null,null,null],[0.1309775369882118,0.13096599999999992,288160116,23,null,null,null,null,null,null,null],[0.15469190399744548,0.15454900000000027,340335528,25,null,null,null,null,null,null,null],[0.149413135019131,0.14938300000000004,328727582,26,null,null,null,null,null,null,null],[0.15268685299088247,0.1526869999999998,335924804,27,null,null,null,null,null,null,null],[0.16147131499019451,0.16141300000000003,355254128,28,null,null,null,null,null,null,null],[0.16141338399029337,0.16139899999999985,355124102,30,null,null,null,null,null,null,null],[0.1728718529921025,0.17285800000000018,380334180,31,null,null,null,null,null,null,null],[0.1909069080138579,0.1908850000000002,420007910,33,null,null,null,null,null,null,null],[0.2043934800021816,0.20432799999999984,449680454,35,null,null,null,null,null,null,null],[0.20723143400391564,0.2070940000000001,455922034,36,null,null,null,null,null,null,null],[0.21014673498575576,0.21012200000000014,462335922,38,null,null,null,null,null,null,null],[0.22118496999610215,0.22116299999999978,486620020,40,null,null,null,null,null,null,null],[0.23701548800454475,0.23698700000000006,521448894,42,null,null,null,null,null,null,null],[0.23784394899848849,0.2378,523268016,44,null,null,null,null,null,null,null],[0.26553260401124135,0.26552299999999995,584189408,47,null,null,null,null,null,null,null],[0.28692550500272773,0.28688300000000044,631256144,49,null,null,null,null,null,null,null],[0.29316152300452814,0.29309600000000025,644973614,52,null,null,null,null,null,null,null]]}];+ reports.map(mangulate);++ var benches = ["ByteString/HashMap/random",];+ var ylabels = [[-0,'<a href="#b0">ByteString/HashMap/random</a>'],];+ var means = $.scaleTimes([5.621667703915931e-3,]);+ var xs = [];+ var prev = null;+ for (var i = 0; i < means[0].length; i++) {+ var name = benches[i].split(/\//);+ name.pop();+ name = name.join('/');+ if (name != prev) {+ xs.push({ label: name, data: [[means[0][i], -i]]});+ prev = name;+ }+ else+ xs[xs.length-1].data.push([means[0][i],-i]);+ }+ var oq = $("#overview");+ o = $.plot(oq, xs, { bars: { show: true, horizontal: true,+ barWidth: 0.75, align: "center" },+ grid: { borderColor: "#777", hoverable: true },+ legend: { show: xs.length > 1 },+ xaxis: { max: Math.max.apply(undefined,means[0]) * 1.02 },+ yaxis: { ticks: ylabels, tickColor: '#ffffff' } });+ if (benches.length > 3)+ o.getPlaceholder().height(28*benches.length);+ o.resize();+ o.setupGrid();+ o.draw();+ $.addTooltip("#overview", function(x,y) { return $.renderTime(x / means[1]); });+});+$(document).ready(function () {+ $(".time").text(function(_, text) {+ return $.renderTime(text);+ });+ $(".citime").text(function(_, text) {+ return $.renderTime(text);+ });+ $(".percent").text(function(_, text) {+ return (text*100).toFixed(1);+ });+ });+</script>++ </div>+ </div>+ <div id="footer">+ <div class="body">+ <div class="footfirst">+ <h2>colophon</h2>+ <p>This report was created using the+ <a href="http://hackage.haskell.org/package/criterion">criterion</a>+ benchmark execution and performance analysis tool.</p>+ <p>Criterion is developed and maintained+ by <a href="http://www.serpentine.com/blog/">Bryan O'Sullivan</a>.</p>+ </div>+ </div>+ </div>+ </body>+</html>
+ js-src/flot-0.8.3.zip view
binary file changed (absent → 649913 bytes)
+ js-src/jquery-2.1.1.js view
@@ -0,0 +1,9190 @@+/*!+ * jQuery JavaScript Library v2.1.1+ * http://jquery.com/+ *+ * Includes Sizzle.js+ * http://sizzlejs.com/+ *+ * Copyright 2005, 2014 jQuery Foundation, Inc. and other contributors+ * Released under the MIT license+ * http://jquery.org/license+ *+ * Date: 2014-05-01T17:11Z+ */++(function( global, factory ) {++ if ( typeof module === "object" && typeof module.exports === "object" ) {+ // For CommonJS and CommonJS-like environments where a proper window is present,+ // execute the factory and get jQuery+ // For environments that do not inherently posses a window with a document+ // (such as Node.js), expose a jQuery-making factory as module.exports+ // This accentuates the need for the creation of a real window+ // e.g. var jQuery = require("jquery")(window);+ // See ticket #14549 for more info+ module.exports = global.document ?+ factory( global, true ) :+ function( w ) {+ if ( !w.document ) {+ throw new Error( "jQuery requires a window with a document" );+ }+ return factory( w );+ };+ } else {+ factory( global );+ }++// Pass this if window is not defined yet+}(typeof window !== "undefined" ? window : this, function( window, noGlobal ) {++// Can't do this because several apps including ASP.NET trace+// the stack via arguments.caller.callee and Firefox dies if+// you try to trace through "use strict" call chains. (#13335)+// Support: Firefox 18++//++var arr = [];++var slice = arr.slice;++var concat = arr.concat;++var push = arr.push;++var indexOf = arr.indexOf;++var class2type = {};++var toString = class2type.toString;++var hasOwn = class2type.hasOwnProperty;++var support = {};++++var+ // Use the correct document accordingly with window argument (sandbox)+ document = window.document,++ version = "2.1.1",++ // Define a local copy of jQuery+ jQuery = function( selector, context ) {+ // The jQuery object is actually just the init constructor 'enhanced'+ // Need init if jQuery is called (just allow error to be thrown if not included)+ return new jQuery.fn.init( selector, context );+ },++ // Support: Android<4.1+ // Make sure we trim BOM and NBSP+ rtrim = /^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,++ // Matches dashed string for camelizing+ rmsPrefix = /^-ms-/,+ rdashAlpha = /-([\da-z])/gi,++ // Used by jQuery.camelCase as callback to replace()+ fcamelCase = function( all, letter ) {+ return letter.toUpperCase();+ };++jQuery.fn = jQuery.prototype = {+ // The current version of jQuery being used+ jquery: version,++ constructor: jQuery,++ // Start with an empty selector+ selector: "",++ // The default length of a jQuery object is 0+ length: 0,++ toArray: function() {+ return slice.call( this );+ },++ // Get the Nth element in the matched element set OR+ // Get the whole matched element set as a clean array+ get: function( num ) {+ return num != null ?++ // Return just the one element from the set+ ( num < 0 ? this[ num + this.length ] : this[ num ] ) :++ // Return all the elements in a clean array+ slice.call( this );+ },++ // Take an array of elements and push it onto the stack+ // (returning the new matched element set)+ pushStack: function( elems ) {++ // Build a new jQuery matched element set+ var ret = jQuery.merge( this.constructor(), elems );++ // Add the old object onto the stack (as a reference)+ ret.prevObject = this;+ ret.context = this.context;++ // Return the newly-formed element set+ return ret;+ },++ // Execute a callback for every element in the matched set.+ // (You can seed the arguments with an array of args, but this is+ // only used internally.)+ each: function( callback, args ) {+ return jQuery.each( this, callback, args );+ },++ map: function( callback ) {+ return this.pushStack( jQuery.map(this, function( elem, i ) {+ return callback.call( elem, i, elem );+ }));+ },++ slice: function() {+ return this.pushStack( slice.apply( this, arguments ) );+ },++ first: function() {+ return this.eq( 0 );+ },++ last: function() {+ return this.eq( -1 );+ },++ eq: function( i ) {+ var len = this.length,+ j = +i + ( i < 0 ? len : 0 );+ return this.pushStack( j >= 0 && j < len ? [ this[j] ] : [] );+ },++ end: function() {+ return this.prevObject || this.constructor(null);+ },++ // For internal use only.+ // Behaves like an Array's method, not like a jQuery method.+ push: push,+ sort: arr.sort,+ splice: arr.splice+};++jQuery.extend = jQuery.fn.extend = function() {+ var options, name, src, copy, copyIsArray, clone,+ target = arguments[0] || {},+ i = 1,+ length = arguments.length,+ deep = false;++ // Handle a deep copy situation+ if ( typeof target === "boolean" ) {+ deep = target;++ // skip the boolean and the target+ target = arguments[ i ] || {};+ i++;+ }++ // Handle case when target is a string or something (possible in deep copy)+ if ( typeof target !== "object" && !jQuery.isFunction(target) ) {+ target = {};+ }++ // extend jQuery itself if only one argument is passed+ if ( i === length ) {+ target = this;+ i--;+ }++ for ( ; i < length; i++ ) {+ // Only deal with non-null/undefined values+ if ( (options = arguments[ i ]) != null ) {+ // Extend the base object+ for ( name in options ) {+ src = target[ name ];+ copy = options[ name ];++ // Prevent never-ending loop+ if ( target === copy ) {+ continue;+ }++ // Recurse if we're merging plain objects or arrays+ if ( deep && copy && ( jQuery.isPlainObject(copy) || (copyIsArray = jQuery.isArray(copy)) ) ) {+ if ( copyIsArray ) {+ copyIsArray = false;+ clone = src && jQuery.isArray(src) ? src : [];++ } else {+ clone = src && jQuery.isPlainObject(src) ? src : {};+ }++ // Never move original objects, clone them+ target[ name ] = jQuery.extend( deep, clone, copy );++ // Don't bring in undefined values+ } else if ( copy !== undefined ) {+ target[ name ] = copy;+ }+ }+ }+ }++ // Return the modified object+ return target;+};++jQuery.extend({+ // Unique for each copy of jQuery on the page+ expando: "jQuery" + ( version + Math.random() ).replace( /\D/g, "" ),++ // Assume jQuery is ready without the ready module+ isReady: true,++ error: function( msg ) {+ throw new Error( msg );+ },++ noop: function() {},++ // See test/unit/core.js for details concerning isFunction.+ // Since version 1.3, DOM methods and functions like alert+ // aren't supported. They return false on IE (#2968).+ isFunction: function( obj ) {+ return jQuery.type(obj) === "function";+ },++ isArray: Array.isArray,++ isWindow: function( obj ) {+ return obj != null && obj === obj.window;+ },++ isNumeric: function( obj ) {+ // parseFloat NaNs numeric-cast false positives (null|true|false|"")+ // ...but misinterprets leading-number strings, particularly hex literals ("0x...")+ // subtraction forces infinities to NaN+ return !jQuery.isArray( obj ) && obj - parseFloat( obj ) >= 0;+ },++ isPlainObject: function( obj ) {+ // Not plain objects:+ // - Any object or value whose internal [[Class]] property is not "[object Object]"+ // - DOM nodes+ // - window+ if ( jQuery.type( obj ) !== "object" || obj.nodeType || jQuery.isWindow( obj ) ) {+ return false;+ }++ if ( obj.constructor &&+ !hasOwn.call( obj.constructor.prototype, "isPrototypeOf" ) ) {+ return false;+ }++ // If the function hasn't returned already, we're confident that+ // |obj| is a plain object, created by {} or constructed with new Object+ return true;+ },++ isEmptyObject: function( obj ) {+ var name;+ for ( name in obj ) {+ return false;+ }+ return true;+ },++ type: function( obj ) {+ if ( obj == null ) {+ return obj + "";+ }+ // Support: Android < 4.0, iOS < 6 (functionish RegExp)+ return typeof obj === "object" || typeof obj === "function" ?+ class2type[ toString.call(obj) ] || "object" :+ typeof obj;+ },++ // Evaluates a script in a global context+ globalEval: function( code ) {+ var script,+ indirect = eval;++ code = jQuery.trim( code );++ if ( code ) {+ // If the code includes a valid, prologue position+ // strict mode pragma, execute code by injecting a+ // script tag into the document.+ if ( code.indexOf("use strict") === 1 ) {+ script = document.createElement("script");+ script.text = code;+ document.head.appendChild( script ).parentNode.removeChild( script );+ } else {+ // Otherwise, avoid the DOM node creation, insertion+ // and removal by using an indirect global eval+ indirect( code );+ }+ }+ },++ // Convert dashed to camelCase; used by the css and data modules+ // Microsoft forgot to hump their vendor prefix (#9572)+ camelCase: function( string ) {+ return string.replace( rmsPrefix, "ms-" ).replace( rdashAlpha, fcamelCase );+ },++ nodeName: function( elem, name ) {+ return elem.nodeName && elem.nodeName.toLowerCase() === name.toLowerCase();+ },++ // args is for internal usage only+ each: function( obj, callback, args ) {+ var value,+ i = 0,+ length = obj.length,+ isArray = isArraylike( obj );++ if ( args ) {+ if ( isArray ) {+ for ( ; i < length; i++ ) {+ value = callback.apply( obj[ i ], args );++ if ( value === false ) {+ break;+ }+ }+ } else {+ for ( i in obj ) {+ value = callback.apply( obj[ i ], args );++ if ( value === false ) {+ break;+ }+ }+ }++ // A special, fast, case for the most common use of each+ } else {+ if ( isArray ) {+ for ( ; i < length; i++ ) {+ value = callback.call( obj[ i ], i, obj[ i ] );++ if ( value === false ) {+ break;+ }+ }+ } else {+ for ( i in obj ) {+ value = callback.call( obj[ i ], i, obj[ i ] );++ if ( value === false ) {+ break;+ }+ }+ }+ }++ return obj;+ },++ // Support: Android<4.1+ trim: function( text ) {+ return text == null ?+ "" :+ ( text + "" ).replace( rtrim, "" );+ },++ // results is for internal usage only+ makeArray: function( arr, results ) {+ var ret = results || [];++ if ( arr != null ) {+ if ( isArraylike( Object(arr) ) ) {+ jQuery.merge( ret,+ typeof arr === "string" ?+ [ arr ] : arr+ );+ } else {+ push.call( ret, arr );+ }+ }++ return ret;+ },++ inArray: function( elem, arr, i ) {+ return arr == null ? -1 : indexOf.call( arr, elem, i );+ },++ merge: function( first, second ) {+ var len = +second.length,+ j = 0,+ i = first.length;++ for ( ; j < len; j++ ) {+ first[ i++ ] = second[ j ];+ }++ first.length = i;++ return first;+ },++ grep: function( elems, callback, invert ) {+ var callbackInverse,+ matches = [],+ i = 0,+ length = elems.length,+ callbackExpect = !invert;++ // Go through the array, only saving the items+ // that pass the validator function+ for ( ; i < length; i++ ) {+ callbackInverse = !callback( elems[ i ], i );+ if ( callbackInverse !== callbackExpect ) {+ matches.push( elems[ i ] );+ }+ }++ return matches;+ },++ // arg is for internal usage only+ map: function( elems, callback, arg ) {+ var value,+ i = 0,+ length = elems.length,+ isArray = isArraylike( elems ),+ ret = [];++ // Go through the array, translating each of the items to their new values+ if ( isArray ) {+ for ( ; i < length; i++ ) {+ value = callback( elems[ i ], i, arg );++ if ( value != null ) {+ ret.push( value );+ }+ }++ // Go through every key on the object,+ } else {+ for ( i in elems ) {+ value = callback( elems[ i ], i, arg );++ if ( value != null ) {+ ret.push( value );+ }+ }+ }++ // Flatten any nested arrays+ return concat.apply( [], ret );+ },++ // A global GUID counter for objects+ guid: 1,++ // Bind a function to a context, optionally partially applying any+ // arguments.+ proxy: function( fn, context ) {+ var tmp, args, proxy;++ if ( typeof context === "string" ) {+ tmp = fn[ context ];+ context = fn;+ fn = tmp;+ }++ // Quick check to determine if target is callable, in the spec+ // this throws a TypeError, but we will just return undefined.+ if ( !jQuery.isFunction( fn ) ) {+ return undefined;+ }++ // Simulated bind+ args = slice.call( arguments, 2 );+ proxy = function() {+ return fn.apply( context || this, args.concat( slice.call( arguments ) ) );+ };++ // Set the guid of unique handler to the same of original handler, so it can be removed+ proxy.guid = fn.guid = fn.guid || jQuery.guid++;++ return proxy;+ },++ now: Date.now,++ // jQuery.support is not used in Core but other projects attach their+ // properties to it so it needs to exist.+ support: support+});++// Populate the class2type map+jQuery.each("Boolean Number String Function Array Date RegExp Object Error".split(" "), function(i, name) {+ class2type[ "[object " + name + "]" ] = name.toLowerCase();+});++function isArraylike( obj ) {+ var length = obj.length,+ type = jQuery.type( obj );++ if ( type === "function" || jQuery.isWindow( obj ) ) {+ return false;+ }++ if ( obj.nodeType === 1 && length ) {+ return true;+ }++ return type === "array" || length === 0 ||+ typeof length === "number" && length > 0 && ( length - 1 ) in obj;+}+var Sizzle =+/*!+ * Sizzle CSS Selector Engine v1.10.19+ * http://sizzlejs.com/+ *+ * Copyright 2013 jQuery Foundation, Inc. and other contributors+ * Released under the MIT license+ * http://jquery.org/license+ *+ * Date: 2014-04-18+ */+(function( window ) {++var i,+ support,+ Expr,+ getText,+ isXML,+ tokenize,+ compile,+ select,+ outermostContext,+ sortInput,+ hasDuplicate,++ // Local document vars+ setDocument,+ document,+ docElem,+ documentIsHTML,+ rbuggyQSA,+ rbuggyMatches,+ matches,+ contains,++ // Instance-specific data+ expando = "sizzle" + -(new Date()),+ preferredDoc = window.document,+ dirruns = 0,+ done = 0,+ classCache = createCache(),+ tokenCache = createCache(),+ compilerCache = createCache(),+ sortOrder = function( a, b ) {+ if ( a === b ) {+ hasDuplicate = true;+ }+ return 0;+ },++ // General-purpose constants+ strundefined = typeof undefined,+ MAX_NEGATIVE = 1 << 31,++ // Instance methods+ hasOwn = ({}).hasOwnProperty,+ arr = [],+ pop = arr.pop,+ push_native = arr.push,+ push = arr.push,+ slice = arr.slice,+ // Use a stripped-down indexOf if we can't use a native one+ indexOf = arr.indexOf || function( elem ) {+ var i = 0,+ len = this.length;+ for ( ; i < len; i++ ) {+ if ( this[i] === elem ) {+ return i;+ }+ }+ return -1;+ },++ booleans = "checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",++ // Regular expressions++ // Whitespace characters http://www.w3.org/TR/css3-selectors/#whitespace+ whitespace = "[\\x20\\t\\r\\n\\f]",+ // http://www.w3.org/TR/css3-syntax/#characters+ characterEncoding = "(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",++ // Loosely modeled on CSS identifier characters+ // An unquoted value should be a CSS identifier http://www.w3.org/TR/css3-selectors/#attribute-selectors+ // Proper syntax: http://www.w3.org/TR/CSS21/syndata.html#value-def-identifier+ identifier = characterEncoding.replace( "w", "w#" ),++ // Attribute selectors: http://www.w3.org/TR/selectors/#attribute-selectors+ attributes = "\\[" + whitespace + "*(" + characterEncoding + ")(?:" + whitespace ++ // Operator (capture 2)+ "*([*^$|!~]?=)" + whitespace ++ // "Attribute values must be CSS identifiers [capture 5] or strings [capture 3 or capture 4]"+ "*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|(" + identifier + "))|)" + whitespace ++ "*\\]",++ pseudos = ":(" + characterEncoding + ")(?:\\((" ++ // To reduce the number of selectors needing tokenize in the preFilter, prefer arguments:+ // 1. quoted (capture 3; capture 4 or capture 5)+ "('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|" ++ // 2. simple (capture 6)+ "((?:\\\\.|[^\\\\()[\\]]|" + attributes + ")*)|" ++ // 3. anything else (capture 2)+ ".*" ++ ")\\)|)",++ // Leading and non-escaped trailing whitespace, capturing some non-whitespace characters preceding the latter+ rtrim = new RegExp( "^" + whitespace + "+|((?:^|[^\\\\])(?:\\\\.)*)" + whitespace + "+$", "g" ),++ rcomma = new RegExp( "^" + whitespace + "*," + whitespace + "*" ),+ rcombinators = new RegExp( "^" + whitespace + "*([>+~]|" + whitespace + ")" + whitespace + "*" ),++ rattributeQuotes = new RegExp( "=" + whitespace + "*([^\\]'\"]*?)" + whitespace + "*\\]", "g" ),++ rpseudo = new RegExp( pseudos ),+ ridentifier = new RegExp( "^" + identifier + "$" ),++ matchExpr = {+ "ID": new RegExp( "^#(" + characterEncoding + ")" ),+ "CLASS": new RegExp( "^\\.(" + characterEncoding + ")" ),+ "TAG": new RegExp( "^(" + characterEncoding.replace( "w", "w*" ) + ")" ),+ "ATTR": new RegExp( "^" + attributes ),+ "PSEUDO": new RegExp( "^" + pseudos ),+ "CHILD": new RegExp( "^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\(" + whitespace ++ "*(even|odd|(([+-]|)(\\d*)n|)" + whitespace + "*(?:([+-]|)" + whitespace ++ "*(\\d+)|))" + whitespace + "*\\)|)", "i" ),+ "bool": new RegExp( "^(?:" + booleans + ")$", "i" ),+ // For use in libraries implementing .is()+ // We use this for POS matching in `select`+ "needsContext": new RegExp( "^" + whitespace + "*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\(" ++ whitespace + "*((?:-\\d)?\\d*)" + whitespace + "*\\)|)(?=[^-]|$)", "i" )+ },++ rinputs = /^(?:input|select|textarea|button)$/i,+ rheader = /^h\d$/i,++ rnative = /^[^{]+\{\s*\[native \w/,++ // Easily-parseable/retrievable ID or TAG or CLASS selectors+ rquickExpr = /^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,++ rsibling = /[+~]/,+ rescape = /'|\\/g,++ // CSS escapes http://www.w3.org/TR/CSS21/syndata.html#escaped-characters+ runescape = new RegExp( "\\\\([\\da-f]{1,6}" + whitespace + "?|(" + whitespace + ")|.)", "ig" ),+ funescape = function( _, escaped, escapedWhitespace ) {+ var high = "0x" + escaped - 0x10000;+ // NaN means non-codepoint+ // Support: Firefox<24+ // Workaround erroneous numeric interpretation of +"0x"+ return high !== high || escapedWhitespace ?+ escaped :+ high < 0 ?+ // BMP codepoint+ String.fromCharCode( high + 0x10000 ) :+ // Supplemental Plane codepoint (surrogate pair)+ String.fromCharCode( high >> 10 | 0xD800, high & 0x3FF | 0xDC00 );+ };++// Optimize for push.apply( _, NodeList )+try {+ push.apply(+ (arr = slice.call( preferredDoc.childNodes )),+ preferredDoc.childNodes+ );+ // Support: Android<4.0+ // Detect silently failing push.apply+ arr[ preferredDoc.childNodes.length ].nodeType;+} catch ( e ) {+ push = { apply: arr.length ?++ // Leverage slice if possible+ function( target, els ) {+ push_native.apply( target, slice.call(els) );+ } :++ // Support: IE<9+ // Otherwise append directly+ function( target, els ) {+ var j = target.length,+ i = 0;+ // Can't trust NodeList.length+ while ( (target[j++] = els[i++]) ) {}+ target.length = j - 1;+ }+ };+}++function Sizzle( selector, context, results, seed ) {+ var match, elem, m, nodeType,+ // QSA vars+ i, groups, old, nid, newContext, newSelector;++ if ( ( context ? context.ownerDocument || context : preferredDoc ) !== document ) {+ setDocument( context );+ }++ context = context || document;+ results = results || [];++ if ( !selector || typeof selector !== "string" ) {+ return results;+ }++ if ( (nodeType = context.nodeType) !== 1 && nodeType !== 9 ) {+ return [];+ }++ if ( documentIsHTML && !seed ) {++ // Shortcuts+ if ( (match = rquickExpr.exec( selector )) ) {+ // Speed-up: Sizzle("#ID")+ if ( (m = match[1]) ) {+ if ( nodeType === 9 ) {+ elem = context.getElementById( m );+ // Check parentNode to catch when Blackberry 4.6 returns+ // nodes that are no longer in the document (jQuery #6963)+ if ( elem && elem.parentNode ) {+ // Handle the case where IE, Opera, and Webkit return items+ // by name instead of ID+ if ( elem.id === m ) {+ results.push( elem );+ return results;+ }+ } else {+ return results;+ }+ } else {+ // Context is not a document+ if ( context.ownerDocument && (elem = context.ownerDocument.getElementById( m )) &&+ contains( context, elem ) && elem.id === m ) {+ results.push( elem );+ return results;+ }+ }++ // Speed-up: Sizzle("TAG")+ } else if ( match[2] ) {+ push.apply( results, context.getElementsByTagName( selector ) );+ return results;++ // Speed-up: Sizzle(".CLASS")+ } else if ( (m = match[3]) && support.getElementsByClassName && context.getElementsByClassName ) {+ push.apply( results, context.getElementsByClassName( m ) );+ return results;+ }+ }++ // QSA path+ if ( support.qsa && (!rbuggyQSA || !rbuggyQSA.test( selector )) ) {+ nid = old = expando;+ newContext = context;+ newSelector = nodeType === 9 && selector;++ // qSA works strangely on Element-rooted queries+ // We can work around this by specifying an extra ID on the root+ // and working up from there (Thanks to Andrew Dupont for the technique)+ // IE 8 doesn't work on object elements+ if ( nodeType === 1 && context.nodeName.toLowerCase() !== "object" ) {+ groups = tokenize( selector );++ if ( (old = context.getAttribute("id")) ) {+ nid = old.replace( rescape, "\\$&" );+ } else {+ context.setAttribute( "id", nid );+ }+ nid = "[id='" + nid + "'] ";++ i = groups.length;+ while ( i-- ) {+ groups[i] = nid + toSelector( groups[i] );+ }+ newContext = rsibling.test( selector ) && testContext( context.parentNode ) || context;+ newSelector = groups.join(",");+ }++ if ( newSelector ) {+ try {+ push.apply( results,+ newContext.querySelectorAll( newSelector )+ );+ return results;+ } catch(qsaError) {+ } finally {+ if ( !old ) {+ context.removeAttribute("id");+ }+ }+ }+ }+ }++ // All others+ return select( selector.replace( rtrim, "$1" ), context, results, seed );+}++/**+ * Create key-value caches of limited size+ * @returns {Function(string, Object)} Returns the Object data after storing it on itself with+ * property name the (space-suffixed) string and (if the cache is larger than Expr.cacheLength)+ * deleting the oldest entry+ */+function createCache() {+ var keys = [];++ function cache( key, value ) {+ // Use (key + " ") to avoid collision with native prototype properties (see Issue #157)+ if ( keys.push( key + " " ) > Expr.cacheLength ) {+ // Only keep the most recent entries+ delete cache[ keys.shift() ];+ }+ return (cache[ key + " " ] = value);+ }+ return cache;+}++/**+ * Mark a function for special use by Sizzle+ * @param {Function} fn The function to mark+ */+function markFunction( fn ) {+ fn[ expando ] = true;+ return fn;+}++/**+ * Support testing using an element+ * @param {Function} fn Passed the created div and expects a boolean result+ */+function assert( fn ) {+ var div = document.createElement("div");++ try {+ return !!fn( div );+ } catch (e) {+ return false;+ } finally {+ // Remove from its parent by default+ if ( div.parentNode ) {+ div.parentNode.removeChild( div );+ }+ // release memory in IE+ div = null;+ }+}++/**+ * Adds the same handler for all of the specified attrs+ * @param {String} attrs Pipe-separated list of attributes+ * @param {Function} handler The method that will be applied+ */+function addHandle( attrs, handler ) {+ var arr = attrs.split("|"),+ i = attrs.length;++ while ( i-- ) {+ Expr.attrHandle[ arr[i] ] = handler;+ }+}++/**+ * Checks document order of two siblings+ * @param {Element} a+ * @param {Element} b+ * @returns {Number} Returns less than 0 if a precedes b, greater than 0 if a follows b+ */+function siblingCheck( a, b ) {+ var cur = b && a,+ diff = cur && a.nodeType === 1 && b.nodeType === 1 &&+ ( ~b.sourceIndex || MAX_NEGATIVE ) -+ ( ~a.sourceIndex || MAX_NEGATIVE );++ // Use IE sourceIndex if available on both nodes+ if ( diff ) {+ return diff;+ }++ // Check if b follows a+ if ( cur ) {+ while ( (cur = cur.nextSibling) ) {+ if ( cur === b ) {+ return -1;+ }+ }+ }++ return a ? 1 : -1;+}++/**+ * Returns a function to use in pseudos for input types+ * @param {String} type+ */+function createInputPseudo( type ) {+ return function( elem ) {+ var name = elem.nodeName.toLowerCase();+ return name === "input" && elem.type === type;+ };+}++/**+ * Returns a function to use in pseudos for buttons+ * @param {String} type+ */+function createButtonPseudo( type ) {+ return function( elem ) {+ var name = elem.nodeName.toLowerCase();+ return (name === "input" || name === "button") && elem.type === type;+ };+}++/**+ * Returns a function to use in pseudos for positionals+ * @param {Function} fn+ */+function createPositionalPseudo( fn ) {+ return markFunction(function( argument ) {+ argument = +argument;+ return markFunction(function( seed, matches ) {+ var j,+ matchIndexes = fn( [], seed.length, argument ),+ i = matchIndexes.length;++ // Match elements found at the specified indexes+ while ( i-- ) {+ if ( seed[ (j = matchIndexes[i]) ] ) {+ seed[j] = !(matches[j] = seed[j]);+ }+ }+ });+ });+}++/**+ * Checks a node for validity as a Sizzle context+ * @param {Element|Object=} context+ * @returns {Element|Object|Boolean} The input node if acceptable, otherwise a falsy value+ */+function testContext( context ) {+ return context && typeof context.getElementsByTagName !== strundefined && context;+}++// Expose support vars for convenience+support = Sizzle.support = {};++/**+ * Detects XML nodes+ * @param {Element|Object} elem An element or a document+ * @returns {Boolean} True iff elem is a non-HTML XML node+ */+isXML = Sizzle.isXML = function( elem ) {+ // documentElement is verified for cases where it doesn't yet exist+ // (such as loading iframes in IE - #4833)+ var documentElement = elem && (elem.ownerDocument || elem).documentElement;+ return documentElement ? documentElement.nodeName !== "HTML" : false;+};++/**+ * Sets document-related variables once based on the current document+ * @param {Element|Object} [doc] An element or document object to use to set the document+ * @returns {Object} Returns the current document+ */+setDocument = Sizzle.setDocument = function( node ) {+ var hasCompare,+ doc = node ? node.ownerDocument || node : preferredDoc,+ parent = doc.defaultView;++ // If no document and documentElement is available, return+ if ( doc === document || doc.nodeType !== 9 || !doc.documentElement ) {+ return document;+ }++ // Set our document+ document = doc;+ docElem = doc.documentElement;++ // Support tests+ documentIsHTML = !isXML( doc );++ // Support: IE>8+ // If iframe document is assigned to "document" variable and if iframe has been reloaded,+ // IE will throw "permission denied" error when accessing "document" variable, see jQuery #13936+ // IE6-8 do not support the defaultView property so parent will be undefined+ if ( parent && parent !== parent.top ) {+ // IE11 does not have attachEvent, so all must suffer+ if ( parent.addEventListener ) {+ parent.addEventListener( "unload", function() {+ setDocument();+ }, false );+ } else if ( parent.attachEvent ) {+ parent.attachEvent( "onunload", function() {+ setDocument();+ });+ }+ }++ /* Attributes+ ---------------------------------------------------------------------- */++ // Support: IE<8+ // Verify that getAttribute really returns attributes and not properties (excepting IE8 booleans)+ support.attributes = assert(function( div ) {+ div.className = "i";+ return !div.getAttribute("className");+ });++ /* getElement(s)By*+ ---------------------------------------------------------------------- */++ // Check if getElementsByTagName("*") returns only elements+ support.getElementsByTagName = assert(function( div ) {+ div.appendChild( doc.createComment("") );+ return !div.getElementsByTagName("*").length;+ });++ // Check if getElementsByClassName can be trusted+ support.getElementsByClassName = rnative.test( doc.getElementsByClassName ) && assert(function( div ) {+ div.innerHTML = "<div class='a'></div><div class='a i'></div>";++ // Support: Safari<4+ // Catch class over-caching+ div.firstChild.className = "i";+ // Support: Opera<10+ // Catch gEBCN failure to find non-leading classes+ return div.getElementsByClassName("i").length === 2;+ });++ // Support: IE<10+ // Check if getElementById returns elements by name+ // The broken getElementById methods don't pick up programatically-set names,+ // so use a roundabout getElementsByName test+ support.getById = assert(function( div ) {+ docElem.appendChild( div ).id = expando;+ return !doc.getElementsByName || !doc.getElementsByName( expando ).length;+ });++ // ID find and filter+ if ( support.getById ) {+ Expr.find["ID"] = function( id, context ) {+ if ( typeof context.getElementById !== strundefined && documentIsHTML ) {+ var m = context.getElementById( id );+ // Check parentNode to catch when Blackberry 4.6 returns+ // nodes that are no longer in the document #6963+ return m && m.parentNode ? [ m ] : [];+ }+ };+ Expr.filter["ID"] = function( id ) {+ var attrId = id.replace( runescape, funescape );+ return function( elem ) {+ return elem.getAttribute("id") === attrId;+ };+ };+ } else {+ // Support: IE6/7+ // getElementById is not reliable as a find shortcut+ delete Expr.find["ID"];++ Expr.filter["ID"] = function( id ) {+ var attrId = id.replace( runescape, funescape );+ return function( elem ) {+ var node = typeof elem.getAttributeNode !== strundefined && elem.getAttributeNode("id");+ return node && node.value === attrId;+ };+ };+ }++ // Tag+ Expr.find["TAG"] = support.getElementsByTagName ?+ function( tag, context ) {+ if ( typeof context.getElementsByTagName !== strundefined ) {+ return context.getElementsByTagName( tag );+ }+ } :+ function( tag, context ) {+ var elem,+ tmp = [],+ i = 0,+ results = context.getElementsByTagName( tag );++ // Filter out possible comments+ if ( tag === "*" ) {+ while ( (elem = results[i++]) ) {+ if ( elem.nodeType === 1 ) {+ tmp.push( elem );+ }+ }++ return tmp;+ }+ return results;+ };++ // Class+ Expr.find["CLASS"] = support.getElementsByClassName && function( className, context ) {+ if ( typeof context.getElementsByClassName !== strundefined && documentIsHTML ) {+ return context.getElementsByClassName( className );+ }+ };++ /* QSA/matchesSelector+ ---------------------------------------------------------------------- */++ // QSA and matchesSelector support++ // matchesSelector(:active) reports false when true (IE9/Opera 11.5)+ rbuggyMatches = [];++ // qSa(:focus) reports false when true (Chrome 21)+ // We allow this because of a bug in IE8/9 that throws an error+ // whenever `document.activeElement` is accessed on an iframe+ // So, we allow :focus to pass through QSA all the time to avoid the IE error+ // See http://bugs.jquery.com/ticket/13378+ rbuggyQSA = [];++ if ( (support.qsa = rnative.test( doc.querySelectorAll )) ) {+ // Build QSA regex+ // Regex strategy adopted from Diego Perini+ assert(function( div ) {+ // Select is set to empty string on purpose+ // This is to test IE's treatment of not explicitly+ // setting a boolean content attribute,+ // since its presence should be enough+ // http://bugs.jquery.com/ticket/12359+ div.innerHTML = "<select msallowclip=''><option selected=''></option></select>";++ // Support: IE8, Opera 11-12.16+ // Nothing should be selected when empty strings follow ^= or $= or *=+ // The test attribute must be unknown in Opera but "safe" for WinRT+ // http://msdn.microsoft.com/en-us/library/ie/hh465388.aspx#attribute_section+ if ( div.querySelectorAll("[msallowclip^='']").length ) {+ rbuggyQSA.push( "[*^$]=" + whitespace + "*(?:''|\"\")" );+ }++ // Support: IE8+ // Boolean attributes and "value" are not treated correctly+ if ( !div.querySelectorAll("[selected]").length ) {+ rbuggyQSA.push( "\\[" + whitespace + "*(?:value|" + booleans + ")" );+ }++ // Webkit/Opera - :checked should return selected option elements+ // http://www.w3.org/TR/2011/REC-css3-selectors-20110929/#checked+ // IE8 throws error here and will not see later tests+ if ( !div.querySelectorAll(":checked").length ) {+ rbuggyQSA.push(":checked");+ }+ });++ assert(function( div ) {+ // Support: Windows 8 Native Apps+ // The type and name attributes are restricted during .innerHTML assignment+ var input = doc.createElement("input");+ input.setAttribute( "type", "hidden" );+ div.appendChild( input ).setAttribute( "name", "D" );++ // Support: IE8+ // Enforce case-sensitivity of name attribute+ if ( div.querySelectorAll("[name=d]").length ) {+ rbuggyQSA.push( "name" + whitespace + "*[*^$|!~]?=" );+ }++ // FF 3.5 - :enabled/:disabled and hidden elements (hidden elements are still enabled)+ // IE8 throws error here and will not see later tests+ if ( !div.querySelectorAll(":enabled").length ) {+ rbuggyQSA.push( ":enabled", ":disabled" );+ }++ // Opera 10-11 does not throw on post-comma invalid pseudos+ div.querySelectorAll("*,:x");+ rbuggyQSA.push(",.*:");+ });+ }++ if ( (support.matchesSelector = rnative.test( (matches = docElem.matches ||+ docElem.webkitMatchesSelector ||+ docElem.mozMatchesSelector ||+ docElem.oMatchesSelector ||+ docElem.msMatchesSelector) )) ) {++ assert(function( div ) {+ // Check to see if it's possible to do matchesSelector+ // on a disconnected node (IE 9)+ support.disconnectedMatch = matches.call( div, "div" );++ // This should fail with an exception+ // Gecko does not error, returns false instead+ matches.call( div, "[s!='']:x" );+ rbuggyMatches.push( "!=", pseudos );+ });+ }++ rbuggyQSA = rbuggyQSA.length && new RegExp( rbuggyQSA.join("|") );+ rbuggyMatches = rbuggyMatches.length && new RegExp( rbuggyMatches.join("|") );++ /* Contains+ ---------------------------------------------------------------------- */+ hasCompare = rnative.test( docElem.compareDocumentPosition );++ // Element contains another+ // Purposefully does not implement inclusive descendent+ // As in, an element does not contain itself+ contains = hasCompare || rnative.test( docElem.contains ) ?+ function( a, b ) {+ var adown = a.nodeType === 9 ? a.documentElement : a,+ bup = b && b.parentNode;+ return a === bup || !!( bup && bup.nodeType === 1 && (+ adown.contains ?+ adown.contains( bup ) :+ a.compareDocumentPosition && a.compareDocumentPosition( bup ) & 16+ ));+ } :+ function( a, b ) {+ if ( b ) {+ while ( (b = b.parentNode) ) {+ if ( b === a ) {+ return true;+ }+ }+ }+ return false;+ };++ /* Sorting+ ---------------------------------------------------------------------- */++ // Document order sorting+ sortOrder = hasCompare ?+ function( a, b ) {++ // Flag for duplicate removal+ if ( a === b ) {+ hasDuplicate = true;+ return 0;+ }++ // Sort on method existence if only one input has compareDocumentPosition+ var compare = !a.compareDocumentPosition - !b.compareDocumentPosition;+ if ( compare ) {+ return compare;+ }++ // Calculate position if both inputs belong to the same document+ compare = ( a.ownerDocument || a ) === ( b.ownerDocument || b ) ?+ a.compareDocumentPosition( b ) :++ // Otherwise we know they are disconnected+ 1;++ // Disconnected nodes+ if ( compare & 1 ||+ (!support.sortDetached && b.compareDocumentPosition( a ) === compare) ) {++ // Choose the first element that is related to our preferred document+ if ( a === doc || a.ownerDocument === preferredDoc && contains(preferredDoc, a) ) {+ return -1;+ }+ if ( b === doc || b.ownerDocument === preferredDoc && contains(preferredDoc, b) ) {+ return 1;+ }++ // Maintain original order+ return sortInput ?+ ( indexOf.call( sortInput, a ) - indexOf.call( sortInput, b ) ) :+ 0;+ }++ return compare & 4 ? -1 : 1;+ } :+ function( a, b ) {+ // Exit early if the nodes are identical+ if ( a === b ) {+ hasDuplicate = true;+ return 0;+ }++ var cur,+ i = 0,+ aup = a.parentNode,+ bup = b.parentNode,+ ap = [ a ],+ bp = [ b ];++ // Parentless nodes are either documents or disconnected+ if ( !aup || !bup ) {+ return a === doc ? -1 :+ b === doc ? 1 :+ aup ? -1 :+ bup ? 1 :+ sortInput ?+ ( indexOf.call( sortInput, a ) - indexOf.call( sortInput, b ) ) :+ 0;++ // If the nodes are siblings, we can do a quick check+ } else if ( aup === bup ) {+ return siblingCheck( a, b );+ }++ // Otherwise we need full lists of their ancestors for comparison+ cur = a;+ while ( (cur = cur.parentNode) ) {+ ap.unshift( cur );+ }+ cur = b;+ while ( (cur = cur.parentNode) ) {+ bp.unshift( cur );+ }++ // Walk down the tree looking for a discrepancy+ while ( ap[i] === bp[i] ) {+ i++;+ }++ return i ?+ // Do a sibling check if the nodes have a common ancestor+ siblingCheck( ap[i], bp[i] ) :++ // Otherwise nodes in our document sort first+ ap[i] === preferredDoc ? -1 :+ bp[i] === preferredDoc ? 1 :+ 0;+ };++ return doc;+};++Sizzle.matches = function( expr, elements ) {+ return Sizzle( expr, null, null, elements );+};++Sizzle.matchesSelector = function( elem, expr ) {+ // Set document vars if needed+ if ( ( elem.ownerDocument || elem ) !== document ) {+ setDocument( elem );+ }++ // Make sure that attribute selectors are quoted+ expr = expr.replace( rattributeQuotes, "='$1']" );++ if ( support.matchesSelector && documentIsHTML &&+ ( !rbuggyMatches || !rbuggyMatches.test( expr ) ) &&+ ( !rbuggyQSA || !rbuggyQSA.test( expr ) ) ) {++ try {+ var ret = matches.call( elem, expr );++ // IE 9's matchesSelector returns false on disconnected nodes+ if ( ret || support.disconnectedMatch ||+ // As well, disconnected nodes are said to be in a document+ // fragment in IE 9+ elem.document && elem.document.nodeType !== 11 ) {+ return ret;+ }+ } catch(e) {}+ }++ return Sizzle( expr, document, null, [ elem ] ).length > 0;+};++Sizzle.contains = function( context, elem ) {+ // Set document vars if needed+ if ( ( context.ownerDocument || context ) !== document ) {+ setDocument( context );+ }+ return contains( context, elem );+};++Sizzle.attr = function( elem, name ) {+ // Set document vars if needed+ if ( ( elem.ownerDocument || elem ) !== document ) {+ setDocument( elem );+ }++ var fn = Expr.attrHandle[ name.toLowerCase() ],+ // Don't get fooled by Object.prototype properties (jQuery #13807)+ val = fn && hasOwn.call( Expr.attrHandle, name.toLowerCase() ) ?+ fn( elem, name, !documentIsHTML ) :+ undefined;++ return val !== undefined ?+ val :+ support.attributes || !documentIsHTML ?+ elem.getAttribute( name ) :+ (val = elem.getAttributeNode(name)) && val.specified ?+ val.value :+ null;+};++Sizzle.error = function( msg ) {+ throw new Error( "Syntax error, unrecognized expression: " + msg );+};++/**+ * Document sorting and removing duplicates+ * @param {ArrayLike} results+ */+Sizzle.uniqueSort = function( results ) {+ var elem,+ duplicates = [],+ j = 0,+ i = 0;++ // Unless we *know* we can detect duplicates, assume their presence+ hasDuplicate = !support.detectDuplicates;+ sortInput = !support.sortStable && results.slice( 0 );+ results.sort( sortOrder );++ if ( hasDuplicate ) {+ while ( (elem = results[i++]) ) {+ if ( elem === results[ i ] ) {+ j = duplicates.push( i );+ }+ }+ while ( j-- ) {+ results.splice( duplicates[ j ], 1 );+ }+ }++ // Clear input after sorting to release objects+ // See https://github.com/jquery/sizzle/pull/225+ sortInput = null;++ return results;+};++/**+ * Utility function for retrieving the text value of an array of DOM nodes+ * @param {Array|Element} elem+ */+getText = Sizzle.getText = function( elem ) {+ var node,+ ret = "",+ i = 0,+ nodeType = elem.nodeType;++ if ( !nodeType ) {+ // If no nodeType, this is expected to be an array+ while ( (node = elem[i++]) ) {+ // Do not traverse comment nodes+ ret += getText( node );+ }+ } else if ( nodeType === 1 || nodeType === 9 || nodeType === 11 ) {+ // Use textContent for elements+ // innerText usage removed for consistency of new lines (jQuery #11153)+ if ( typeof elem.textContent === "string" ) {+ return elem.textContent;+ } else {+ // Traverse its children+ for ( elem = elem.firstChild; elem; elem = elem.nextSibling ) {+ ret += getText( elem );+ }+ }+ } else if ( nodeType === 3 || nodeType === 4 ) {+ return elem.nodeValue;+ }+ // Do not include comment or processing instruction nodes++ return ret;+};++Expr = Sizzle.selectors = {++ // Can be adjusted by the user+ cacheLength: 50,++ createPseudo: markFunction,++ match: matchExpr,++ attrHandle: {},++ find: {},++ relative: {+ ">": { dir: "parentNode", first: true },+ " ": { dir: "parentNode" },+ "+": { dir: "previousSibling", first: true },+ "~": { dir: "previousSibling" }+ },++ preFilter: {+ "ATTR": function( match ) {+ match[1] = match[1].replace( runescape, funescape );++ // Move the given value to match[3] whether quoted or unquoted+ match[3] = ( match[3] || match[4] || match[5] || "" ).replace( runescape, funescape );++ if ( match[2] === "~=" ) {+ match[3] = " " + match[3] + " ";+ }++ return match.slice( 0, 4 );+ },++ "CHILD": function( match ) {+ /* matches from matchExpr["CHILD"]+ 1 type (only|nth|...)+ 2 what (child|of-type)+ 3 argument (even|odd|\d*|\d*n([+-]\d+)?|...)+ 4 xn-component of xn+y argument ([+-]?\d*n|)+ 5 sign of xn-component+ 6 x of xn-component+ 7 sign of y-component+ 8 y of y-component+ */+ match[1] = match[1].toLowerCase();++ if ( match[1].slice( 0, 3 ) === "nth" ) {+ // nth-* requires argument+ if ( !match[3] ) {+ Sizzle.error( match[0] );+ }++ // numeric x and y parameters for Expr.filter.CHILD+ // remember that false/true cast respectively to 0/1+ match[4] = +( match[4] ? match[5] + (match[6] || 1) : 2 * ( match[3] === "even" || match[3] === "odd" ) );+ match[5] = +( ( match[7] + match[8] ) || match[3] === "odd" );++ // other types prohibit arguments+ } else if ( match[3] ) {+ Sizzle.error( match[0] );+ }++ return match;+ },++ "PSEUDO": function( match ) {+ var excess,+ unquoted = !match[6] && match[2];++ if ( matchExpr["CHILD"].test( match[0] ) ) {+ return null;+ }++ // Accept quoted arguments as-is+ if ( match[3] ) {+ match[2] = match[4] || match[5] || "";++ // Strip excess characters from unquoted arguments+ } else if ( unquoted && rpseudo.test( unquoted ) &&+ // Get excess from tokenize (recursively)+ (excess = tokenize( unquoted, true )) &&+ // advance to the next closing parenthesis+ (excess = unquoted.indexOf( ")", unquoted.length - excess ) - unquoted.length) ) {++ // excess is a negative index+ match[0] = match[0].slice( 0, excess );+ match[2] = unquoted.slice( 0, excess );+ }++ // Return only captures needed by the pseudo filter method (type and argument)+ return match.slice( 0, 3 );+ }+ },++ filter: {++ "TAG": function( nodeNameSelector ) {+ var nodeName = nodeNameSelector.replace( runescape, funescape ).toLowerCase();+ return nodeNameSelector === "*" ?+ function() { return true; } :+ function( elem ) {+ return elem.nodeName && elem.nodeName.toLowerCase() === nodeName;+ };+ },++ "CLASS": function( className ) {+ var pattern = classCache[ className + " " ];++ return pattern ||+ (pattern = new RegExp( "(^|" + whitespace + ")" + className + "(" + whitespace + "|$)" )) &&+ classCache( className, function( elem ) {+ return pattern.test( typeof elem.className === "string" && elem.className || typeof elem.getAttribute !== strundefined && elem.getAttribute("class") || "" );+ });+ },++ "ATTR": function( name, operator, check ) {+ return function( elem ) {+ var result = Sizzle.attr( elem, name );++ if ( result == null ) {+ return operator === "!=";+ }+ if ( !operator ) {+ return true;+ }++ result += "";++ return operator === "=" ? result === check :+ operator === "!=" ? result !== check :+ operator === "^=" ? check && result.indexOf( check ) === 0 :+ operator === "*=" ? check && result.indexOf( check ) > -1 :+ operator === "$=" ? check && result.slice( -check.length ) === check :+ operator === "~=" ? ( " " + result + " " ).indexOf( check ) > -1 :+ operator === "|=" ? result === check || result.slice( 0, check.length + 1 ) === check + "-" :+ false;+ };+ },++ "CHILD": function( type, what, argument, first, last ) {+ var simple = type.slice( 0, 3 ) !== "nth",+ forward = type.slice( -4 ) !== "last",+ ofType = what === "of-type";++ return first === 1 && last === 0 ?++ // Shortcut for :nth-*(n)+ function( elem ) {+ return !!elem.parentNode;+ } :++ function( elem, context, xml ) {+ var cache, outerCache, node, diff, nodeIndex, start,+ dir = simple !== forward ? "nextSibling" : "previousSibling",+ parent = elem.parentNode,+ name = ofType && elem.nodeName.toLowerCase(),+ useCache = !xml && !ofType;++ if ( parent ) {++ // :(first|last|only)-(child|of-type)+ if ( simple ) {+ while ( dir ) {+ node = elem;+ while ( (node = node[ dir ]) ) {+ if ( ofType ? node.nodeName.toLowerCase() === name : node.nodeType === 1 ) {+ return false;+ }+ }+ // Reverse direction for :only-* (if we haven't yet done so)+ start = dir = type === "only" && !start && "nextSibling";+ }+ return true;+ }++ start = [ forward ? parent.firstChild : parent.lastChild ];++ // non-xml :nth-child(...) stores cache data on `parent`+ if ( forward && useCache ) {+ // Seek `elem` from a previously-cached index+ outerCache = parent[ expando ] || (parent[ expando ] = {});+ cache = outerCache[ type ] || [];+ nodeIndex = cache[0] === dirruns && cache[1];+ diff = cache[0] === dirruns && cache[2];+ node = nodeIndex && parent.childNodes[ nodeIndex ];++ while ( (node = ++nodeIndex && node && node[ dir ] ||++ // Fallback to seeking `elem` from the start+ (diff = nodeIndex = 0) || start.pop()) ) {++ // When found, cache indexes on `parent` and break+ if ( node.nodeType === 1 && ++diff && node === elem ) {+ outerCache[ type ] = [ dirruns, nodeIndex, diff ];+ break;+ }+ }++ // Use previously-cached element index if available+ } else if ( useCache && (cache = (elem[ expando ] || (elem[ expando ] = {}))[ type ]) && cache[0] === dirruns ) {+ diff = cache[1];++ // xml :nth-child(...) or :nth-last-child(...) or :nth(-last)?-of-type(...)+ } else {+ // Use the same loop as above to seek `elem` from the start+ while ( (node = ++nodeIndex && node && node[ dir ] ||+ (diff = nodeIndex = 0) || start.pop()) ) {++ if ( ( ofType ? node.nodeName.toLowerCase() === name : node.nodeType === 1 ) && ++diff ) {+ // Cache the index of each encountered element+ if ( useCache ) {+ (node[ expando ] || (node[ expando ] = {}))[ type ] = [ dirruns, diff ];+ }++ if ( node === elem ) {+ break;+ }+ }+ }+ }++ // Incorporate the offset, then check against cycle size+ diff -= last;+ return diff === first || ( diff % first === 0 && diff / first >= 0 );+ }+ };+ },++ "PSEUDO": function( pseudo, argument ) {+ // pseudo-class names are case-insensitive+ // http://www.w3.org/TR/selectors/#pseudo-classes+ // Prioritize by case sensitivity in case custom pseudos are added with uppercase letters+ // Remember that setFilters inherits from pseudos+ var args,+ fn = Expr.pseudos[ pseudo ] || Expr.setFilters[ pseudo.toLowerCase() ] ||+ Sizzle.error( "unsupported pseudo: " + pseudo );++ // The user may use createPseudo to indicate that+ // arguments are needed to create the filter function+ // just as Sizzle does+ if ( fn[ expando ] ) {+ return fn( argument );+ }++ // But maintain support for old signatures+ if ( fn.length > 1 ) {+ args = [ pseudo, pseudo, "", argument ];+ return Expr.setFilters.hasOwnProperty( pseudo.toLowerCase() ) ?+ markFunction(function( seed, matches ) {+ var idx,+ matched = fn( seed, argument ),+ i = matched.length;+ while ( i-- ) {+ idx = indexOf.call( seed, matched[i] );+ seed[ idx ] = !( matches[ idx ] = matched[i] );+ }+ }) :+ function( elem ) {+ return fn( elem, 0, args );+ };+ }++ return fn;+ }+ },++ pseudos: {+ // Potentially complex pseudos+ "not": markFunction(function( selector ) {+ // Trim the selector passed to compile+ // to avoid treating leading and trailing+ // spaces as combinators+ var input = [],+ results = [],+ matcher = compile( selector.replace( rtrim, "$1" ) );++ return matcher[ expando ] ?+ markFunction(function( seed, matches, context, xml ) {+ var elem,+ unmatched = matcher( seed, null, xml, [] ),+ i = seed.length;++ // Match elements unmatched by `matcher`+ while ( i-- ) {+ if ( (elem = unmatched[i]) ) {+ seed[i] = !(matches[i] = elem);+ }+ }+ }) :+ function( elem, context, xml ) {+ input[0] = elem;+ matcher( input, null, xml, results );+ return !results.pop();+ };+ }),++ "has": markFunction(function( selector ) {+ return function( elem ) {+ return Sizzle( selector, elem ).length > 0;+ };+ }),++ "contains": markFunction(function( text ) {+ return function( elem ) {+ return ( elem.textContent || elem.innerText || getText( elem ) ).indexOf( text ) > -1;+ };+ }),++ // "Whether an element is represented by a :lang() selector+ // is based solely on the element's language value+ // being equal to the identifier C,+ // or beginning with the identifier C immediately followed by "-".+ // The matching of C against the element's language value is performed case-insensitively.+ // The identifier C does not have to be a valid language name."+ // http://www.w3.org/TR/selectors/#lang-pseudo+ "lang": markFunction( function( lang ) {+ // lang value must be a valid identifier+ if ( !ridentifier.test(lang || "") ) {+ Sizzle.error( "unsupported lang: " + lang );+ }+ lang = lang.replace( runescape, funescape ).toLowerCase();+ return function( elem ) {+ var elemLang;+ do {+ if ( (elemLang = documentIsHTML ?+ elem.lang :+ elem.getAttribute("xml:lang") || elem.getAttribute("lang")) ) {++ elemLang = elemLang.toLowerCase();+ return elemLang === lang || elemLang.indexOf( lang + "-" ) === 0;+ }+ } while ( (elem = elem.parentNode) && elem.nodeType === 1 );+ return false;+ };+ }),++ // Miscellaneous+ "target": function( elem ) {+ var hash = window.location && window.location.hash;+ return hash && hash.slice( 1 ) === elem.id;+ },++ "root": function( elem ) {+ return elem === docElem;+ },++ "focus": function( elem ) {+ return elem === document.activeElement && (!document.hasFocus || document.hasFocus()) && !!(elem.type || elem.href || ~elem.tabIndex);+ },++ // Boolean properties+ "enabled": function( elem ) {+ return elem.disabled === false;+ },++ "disabled": function( elem ) {+ return elem.disabled === true;+ },++ "checked": function( elem ) {+ // In CSS3, :checked should return both checked and selected elements+ // http://www.w3.org/TR/2011/REC-css3-selectors-20110929/#checked+ var nodeName = elem.nodeName.toLowerCase();+ return (nodeName === "input" && !!elem.checked) || (nodeName === "option" && !!elem.selected);+ },++ "selected": function( elem ) {+ // Accessing this property makes selected-by-default+ // options in Safari work properly+ if ( elem.parentNode ) {+ elem.parentNode.selectedIndex;+ }++ return elem.selected === true;+ },++ // Contents+ "empty": function( elem ) {+ // http://www.w3.org/TR/selectors/#empty-pseudo+ // :empty is negated by element (1) or content nodes (text: 3; cdata: 4; entity ref: 5),+ // but not by others (comment: 8; processing instruction: 7; etc.)+ // nodeType < 6 works because attributes (2) do not appear as children+ for ( elem = elem.firstChild; elem; elem = elem.nextSibling ) {+ if ( elem.nodeType < 6 ) {+ return false;+ }+ }+ return true;+ },++ "parent": function( elem ) {+ return !Expr.pseudos["empty"]( elem );+ },++ // Element/input types+ "header": function( elem ) {+ return rheader.test( elem.nodeName );+ },++ "input": function( elem ) {+ return rinputs.test( elem.nodeName );+ },++ "button": function( elem ) {+ var name = elem.nodeName.toLowerCase();+ return name === "input" && elem.type === "button" || name === "button";+ },++ "text": function( elem ) {+ var attr;+ return elem.nodeName.toLowerCase() === "input" &&+ elem.type === "text" &&++ // Support: IE<8+ // New HTML5 attribute values (e.g., "search") appear with elem.type === "text"+ ( (attr = elem.getAttribute("type")) == null || attr.toLowerCase() === "text" );+ },++ // Position-in-collection+ "first": createPositionalPseudo(function() {+ return [ 0 ];+ }),++ "last": createPositionalPseudo(function( matchIndexes, length ) {+ return [ length - 1 ];+ }),++ "eq": createPositionalPseudo(function( matchIndexes, length, argument ) {+ return [ argument < 0 ? argument + length : argument ];+ }),++ "even": createPositionalPseudo(function( matchIndexes, length ) {+ var i = 0;+ for ( ; i < length; i += 2 ) {+ matchIndexes.push( i );+ }+ return matchIndexes;+ }),++ "odd": createPositionalPseudo(function( matchIndexes, length ) {+ var i = 1;+ for ( ; i < length; i += 2 ) {+ matchIndexes.push( i );+ }+ return matchIndexes;+ }),++ "lt": createPositionalPseudo(function( matchIndexes, length, argument ) {+ var i = argument < 0 ? argument + length : argument;+ for ( ; --i >= 0; ) {+ matchIndexes.push( i );+ }+ return matchIndexes;+ }),++ "gt": createPositionalPseudo(function( matchIndexes, length, argument ) {+ var i = argument < 0 ? argument + length : argument;+ for ( ; ++i < length; ) {+ matchIndexes.push( i );+ }+ return matchIndexes;+ })+ }+};++Expr.pseudos["nth"] = Expr.pseudos["eq"];++// Add button/input type pseudos+for ( i in { radio: true, checkbox: true, file: true, password: true, image: true } ) {+ Expr.pseudos[ i ] = createInputPseudo( i );+}+for ( i in { submit: true, reset: true } ) {+ Expr.pseudos[ i ] = createButtonPseudo( i );+}++// Easy API for creating new setFilters+function setFilters() {}+setFilters.prototype = Expr.filters = Expr.pseudos;+Expr.setFilters = new setFilters();++tokenize = Sizzle.tokenize = function( selector, parseOnly ) {+ var matched, match, tokens, type,+ soFar, groups, preFilters,+ cached = tokenCache[ selector + " " ];++ if ( cached ) {+ return parseOnly ? 0 : cached.slice( 0 );+ }++ soFar = selector;+ groups = [];+ preFilters = Expr.preFilter;++ while ( soFar ) {++ // Comma and first run+ if ( !matched || (match = rcomma.exec( soFar )) ) {+ if ( match ) {+ // Don't consume trailing commas as valid+ soFar = soFar.slice( match[0].length ) || soFar;+ }+ groups.push( (tokens = []) );+ }++ matched = false;++ // Combinators+ if ( (match = rcombinators.exec( soFar )) ) {+ matched = match.shift();+ tokens.push({+ value: matched,+ // Cast descendant combinators to space+ type: match[0].replace( rtrim, " " )+ });+ soFar = soFar.slice( matched.length );+ }++ // Filters+ for ( type in Expr.filter ) {+ if ( (match = matchExpr[ type ].exec( soFar )) && (!preFilters[ type ] ||+ (match = preFilters[ type ]( match ))) ) {+ matched = match.shift();+ tokens.push({+ value: matched,+ type: type,+ matches: match+ });+ soFar = soFar.slice( matched.length );+ }+ }++ if ( !matched ) {+ break;+ }+ }++ // Return the length of the invalid excess+ // if we're just parsing+ // Otherwise, throw an error or return tokens+ return parseOnly ?+ soFar.length :+ soFar ?+ Sizzle.error( selector ) :+ // Cache the tokens+ tokenCache( selector, groups ).slice( 0 );+};++function toSelector( tokens ) {+ var i = 0,+ len = tokens.length,+ selector = "";+ for ( ; i < len; i++ ) {+ selector += tokens[i].value;+ }+ return selector;+}++function addCombinator( matcher, combinator, base ) {+ var dir = combinator.dir,+ checkNonElements = base && dir === "parentNode",+ doneName = done++;++ return combinator.first ?+ // Check against closest ancestor/preceding element+ function( elem, context, xml ) {+ while ( (elem = elem[ dir ]) ) {+ if ( elem.nodeType === 1 || checkNonElements ) {+ return matcher( elem, context, xml );+ }+ }+ } :++ // Check against all ancestor/preceding elements+ function( elem, context, xml ) {+ var oldCache, outerCache,+ newCache = [ dirruns, doneName ];++ // We can't set arbitrary data on XML nodes, so they don't benefit from dir caching+ if ( xml ) {+ while ( (elem = elem[ dir ]) ) {+ if ( elem.nodeType === 1 || checkNonElements ) {+ if ( matcher( elem, context, xml ) ) {+ return true;+ }+ }+ }+ } else {+ while ( (elem = elem[ dir ]) ) {+ if ( elem.nodeType === 1 || checkNonElements ) {+ outerCache = elem[ expando ] || (elem[ expando ] = {});+ if ( (oldCache = outerCache[ dir ]) &&+ oldCache[ 0 ] === dirruns && oldCache[ 1 ] === doneName ) {++ // Assign to newCache so results back-propagate to previous elements+ return (newCache[ 2 ] = oldCache[ 2 ]);+ } else {+ // Reuse newcache so results back-propagate to previous elements+ outerCache[ dir ] = newCache;++ // A match means we're done; a fail means we have to keep checking+ if ( (newCache[ 2 ] = matcher( elem, context, xml )) ) {+ return true;+ }+ }+ }+ }+ }+ };+}++function elementMatcher( matchers ) {+ return matchers.length > 1 ?+ function( elem, context, xml ) {+ var i = matchers.length;+ while ( i-- ) {+ if ( !matchers[i]( elem, context, xml ) ) {+ return false;+ }+ }+ return true;+ } :+ matchers[0];+}++function multipleContexts( selector, contexts, results ) {+ var i = 0,+ len = contexts.length;+ for ( ; i < len; i++ ) {+ Sizzle( selector, contexts[i], results );+ }+ return results;+}++function condense( unmatched, map, filter, context, xml ) {+ var elem,+ newUnmatched = [],+ i = 0,+ len = unmatched.length,+ mapped = map != null;++ for ( ; i < len; i++ ) {+ if ( (elem = unmatched[i]) ) {+ if ( !filter || filter( elem, context, xml ) ) {+ newUnmatched.push( elem );+ if ( mapped ) {+ map.push( i );+ }+ }+ }+ }++ return newUnmatched;+}++function setMatcher( preFilter, selector, matcher, postFilter, postFinder, postSelector ) {+ if ( postFilter && !postFilter[ expando ] ) {+ postFilter = setMatcher( postFilter );+ }+ if ( postFinder && !postFinder[ expando ] ) {+ postFinder = setMatcher( postFinder, postSelector );+ }+ return markFunction(function( seed, results, context, xml ) {+ var temp, i, elem,+ preMap = [],+ postMap = [],+ preexisting = results.length,++ // Get initial elements from seed or context+ elems = seed || multipleContexts( selector || "*", context.nodeType ? [ context ] : context, [] ),++ // Prefilter to get matcher input, preserving a map for seed-results synchronization+ matcherIn = preFilter && ( seed || !selector ) ?+ condense( elems, preMap, preFilter, context, xml ) :+ elems,++ matcherOut = matcher ?+ // If we have a postFinder, or filtered seed, or non-seed postFilter or preexisting results,+ postFinder || ( seed ? preFilter : preexisting || postFilter ) ?++ // ...intermediate processing is necessary+ [] :++ // ...otherwise use results directly+ results :+ matcherIn;++ // Find primary matches+ if ( matcher ) {+ matcher( matcherIn, matcherOut, context, xml );+ }++ // Apply postFilter+ if ( postFilter ) {+ temp = condense( matcherOut, postMap );+ postFilter( temp, [], context, xml );++ // Un-match failing elements by moving them back to matcherIn+ i = temp.length;+ while ( i-- ) {+ if ( (elem = temp[i]) ) {+ matcherOut[ postMap[i] ] = !(matcherIn[ postMap[i] ] = elem);+ }+ }+ }++ if ( seed ) {+ if ( postFinder || preFilter ) {+ if ( postFinder ) {+ // Get the final matcherOut by condensing this intermediate into postFinder contexts+ temp = [];+ i = matcherOut.length;+ while ( i-- ) {+ if ( (elem = matcherOut[i]) ) {+ // Restore matcherIn since elem is not yet a final match+ temp.push( (matcherIn[i] = elem) );+ }+ }+ postFinder( null, (matcherOut = []), temp, xml );+ }++ // Move matched elements from seed to results to keep them synchronized+ i = matcherOut.length;+ while ( i-- ) {+ if ( (elem = matcherOut[i]) &&+ (temp = postFinder ? indexOf.call( seed, elem ) : preMap[i]) > -1 ) {++ seed[temp] = !(results[temp] = elem);+ }+ }+ }++ // Add elements to results, through postFinder if defined+ } else {+ matcherOut = condense(+ matcherOut === results ?+ matcherOut.splice( preexisting, matcherOut.length ) :+ matcherOut+ );+ if ( postFinder ) {+ postFinder( null, results, matcherOut, xml );+ } else {+ push.apply( results, matcherOut );+ }+ }+ });+}++function matcherFromTokens( tokens ) {+ var checkContext, matcher, j,+ len = tokens.length,+ leadingRelative = Expr.relative[ tokens[0].type ],+ implicitRelative = leadingRelative || Expr.relative[" "],+ i = leadingRelative ? 1 : 0,++ // The foundational matcher ensures that elements are reachable from top-level context(s)+ matchContext = addCombinator( function( elem ) {+ return elem === checkContext;+ }, implicitRelative, true ),+ matchAnyContext = addCombinator( function( elem ) {+ return indexOf.call( checkContext, elem ) > -1;+ }, implicitRelative, true ),+ matchers = [ function( elem, context, xml ) {+ return ( !leadingRelative && ( xml || context !== outermostContext ) ) || (+ (checkContext = context).nodeType ?+ matchContext( elem, context, xml ) :+ matchAnyContext( elem, context, xml ) );+ } ];++ for ( ; i < len; i++ ) {+ if ( (matcher = Expr.relative[ tokens[i].type ]) ) {+ matchers = [ addCombinator(elementMatcher( matchers ), matcher) ];+ } else {+ matcher = Expr.filter[ tokens[i].type ].apply( null, tokens[i].matches );++ // Return special upon seeing a positional matcher+ if ( matcher[ expando ] ) {+ // Find the next relative operator (if any) for proper handling+ j = ++i;+ for ( ; j < len; j++ ) {+ if ( Expr.relative[ tokens[j].type ] ) {+ break;+ }+ }+ return setMatcher(+ i > 1 && elementMatcher( matchers ),+ i > 1 && toSelector(+ // If the preceding token was a descendant combinator, insert an implicit any-element `*`+ tokens.slice( 0, i - 1 ).concat({ value: tokens[ i - 2 ].type === " " ? "*" : "" })+ ).replace( rtrim, "$1" ),+ matcher,+ i < j && matcherFromTokens( tokens.slice( i, j ) ),+ j < len && matcherFromTokens( (tokens = tokens.slice( j )) ),+ j < len && toSelector( tokens )+ );+ }+ matchers.push( matcher );+ }+ }++ return elementMatcher( matchers );+}++function matcherFromGroupMatchers( elementMatchers, setMatchers ) {+ var bySet = setMatchers.length > 0,+ byElement = elementMatchers.length > 0,+ superMatcher = function( seed, context, xml, results, outermost ) {+ var elem, j, matcher,+ matchedCount = 0,+ i = "0",+ unmatched = seed && [],+ setMatched = [],+ contextBackup = outermostContext,+ // We must always have either seed elements or outermost context+ elems = seed || byElement && Expr.find["TAG"]( "*", outermost ),+ // Use integer dirruns iff this is the outermost matcher+ dirrunsUnique = (dirruns += contextBackup == null ? 1 : Math.random() || 0.1),+ len = elems.length;++ if ( outermost ) {+ outermostContext = context !== document && context;+ }++ // Add elements passing elementMatchers directly to results+ // Keep `i` a string if there are no elements so `matchedCount` will be "00" below+ // Support: IE<9, Safari+ // Tolerate NodeList properties (IE: "length"; Safari: <number>) matching elements by id+ for ( ; i !== len && (elem = elems[i]) != null; i++ ) {+ if ( byElement && elem ) {+ j = 0;+ while ( (matcher = elementMatchers[j++]) ) {+ if ( matcher( elem, context, xml ) ) {+ results.push( elem );+ break;+ }+ }+ if ( outermost ) {+ dirruns = dirrunsUnique;+ }+ }++ // Track unmatched elements for set filters+ if ( bySet ) {+ // They will have gone through all possible matchers+ if ( (elem = !matcher && elem) ) {+ matchedCount--;+ }++ // Lengthen the array for every element, matched or not+ if ( seed ) {+ unmatched.push( elem );+ }+ }+ }++ // Apply set filters to unmatched elements+ matchedCount += i;+ if ( bySet && i !== matchedCount ) {+ j = 0;+ while ( (matcher = setMatchers[j++]) ) {+ matcher( unmatched, setMatched, context, xml );+ }++ if ( seed ) {+ // Reintegrate element matches to eliminate the need for sorting+ if ( matchedCount > 0 ) {+ while ( i-- ) {+ if ( !(unmatched[i] || setMatched[i]) ) {+ setMatched[i] = pop.call( results );+ }+ }+ }++ // Discard index placeholder values to get only actual matches+ setMatched = condense( setMatched );+ }++ // Add matches to results+ push.apply( results, setMatched );++ // Seedless set matches succeeding multiple successful matchers stipulate sorting+ if ( outermost && !seed && setMatched.length > 0 &&+ ( matchedCount + setMatchers.length ) > 1 ) {++ Sizzle.uniqueSort( results );+ }+ }++ // Override manipulation of globals by nested matchers+ if ( outermost ) {+ dirruns = dirrunsUnique;+ outermostContext = contextBackup;+ }++ return unmatched;+ };++ return bySet ?+ markFunction( superMatcher ) :+ superMatcher;+}++compile = Sizzle.compile = function( selector, match /* Internal Use Only */ ) {+ var i,+ setMatchers = [],+ elementMatchers = [],+ cached = compilerCache[ selector + " " ];++ if ( !cached ) {+ // Generate a function of recursive functions that can be used to check each element+ if ( !match ) {+ match = tokenize( selector );+ }+ i = match.length;+ while ( i-- ) {+ cached = matcherFromTokens( match[i] );+ if ( cached[ expando ] ) {+ setMatchers.push( cached );+ } else {+ elementMatchers.push( cached );+ }+ }++ // Cache the compiled function+ cached = compilerCache( selector, matcherFromGroupMatchers( elementMatchers, setMatchers ) );++ // Save selector and tokenization+ cached.selector = selector;+ }+ return cached;+};++/**+ * A low-level selection function that works with Sizzle's compiled+ * selector functions+ * @param {String|Function} selector A selector or a pre-compiled+ * selector function built with Sizzle.compile+ * @param {Element} context+ * @param {Array} [results]+ * @param {Array} [seed] A set of elements to match against+ */+select = Sizzle.select = function( selector, context, results, seed ) {+ var i, tokens, token, type, find,+ compiled = typeof selector === "function" && selector,+ match = !seed && tokenize( (selector = compiled.selector || selector) );++ results = results || [];++ // Try to minimize operations if there is no seed and only one group+ if ( match.length === 1 ) {++ // Take a shortcut and set the context if the root selector is an ID+ tokens = match[0] = match[0].slice( 0 );+ if ( tokens.length > 2 && (token = tokens[0]).type === "ID" &&+ support.getById && context.nodeType === 9 && documentIsHTML &&+ Expr.relative[ tokens[1].type ] ) {++ context = ( Expr.find["ID"]( token.matches[0].replace(runescape, funescape), context ) || [] )[0];+ if ( !context ) {+ return results;++ // Precompiled matchers will still verify ancestry, so step up a level+ } else if ( compiled ) {+ context = context.parentNode;+ }++ selector = selector.slice( tokens.shift().value.length );+ }++ // Fetch a seed set for right-to-left matching+ i = matchExpr["needsContext"].test( selector ) ? 0 : tokens.length;+ while ( i-- ) {+ token = tokens[i];++ // Abort if we hit a combinator+ if ( Expr.relative[ (type = token.type) ] ) {+ break;+ }+ if ( (find = Expr.find[ type ]) ) {+ // Search, expanding context for leading sibling combinators+ if ( (seed = find(+ token.matches[0].replace( runescape, funescape ),+ rsibling.test( tokens[0].type ) && testContext( context.parentNode ) || context+ )) ) {++ // If seed is empty or no tokens remain, we can return early+ tokens.splice( i, 1 );+ selector = seed.length && toSelector( tokens );+ if ( !selector ) {+ push.apply( results, seed );+ return results;+ }++ break;+ }+ }+ }+ }++ // Compile and execute a filtering function if one is not provided+ // Provide `match` to avoid retokenization if we modified the selector above+ ( compiled || compile( selector, match ) )(+ seed,+ context,+ !documentIsHTML,+ results,+ rsibling.test( selector ) && testContext( context.parentNode ) || context+ );+ return results;+};++// One-time assignments++// Sort stability+support.sortStable = expando.split("").sort( sortOrder ).join("") === expando;++// Support: Chrome<14+// Always assume duplicates if they aren't passed to the comparison function+support.detectDuplicates = !!hasDuplicate;++// Initialize against the default document+setDocument();++// Support: Webkit<537.32 - Safari 6.0.3/Chrome 25 (fixed in Chrome 27)+// Detached nodes confoundingly follow *each other*+support.sortDetached = assert(function( div1 ) {+ // Should return 1, but returns 4 (following)+ return div1.compareDocumentPosition( document.createElement("div") ) & 1;+});++// Support: IE<8+// Prevent attribute/property "interpolation"+// http://msdn.microsoft.com/en-us/library/ms536429%28VS.85%29.aspx+if ( !assert(function( div ) {+ div.innerHTML = "<a href='#'></a>";+ return div.firstChild.getAttribute("href") === "#" ;+}) ) {+ addHandle( "type|href|height|width", function( elem, name, isXML ) {+ if ( !isXML ) {+ return elem.getAttribute( name, name.toLowerCase() === "type" ? 1 : 2 );+ }+ });+}++// Support: IE<9+// Use defaultValue in place of getAttribute("value")+if ( !support.attributes || !assert(function( div ) {+ div.innerHTML = "<input/>";+ div.firstChild.setAttribute( "value", "" );+ return div.firstChild.getAttribute( "value" ) === "";+}) ) {+ addHandle( "value", function( elem, name, isXML ) {+ if ( !isXML && elem.nodeName.toLowerCase() === "input" ) {+ return elem.defaultValue;+ }+ });+}++// Support: IE<9+// Use getAttributeNode to fetch booleans when getAttribute lies+if ( !assert(function( div ) {+ return div.getAttribute("disabled") == null;+}) ) {+ addHandle( booleans, function( elem, name, isXML ) {+ var val;+ if ( !isXML ) {+ return elem[ name ] === true ? name.toLowerCase() :+ (val = elem.getAttributeNode( name )) && val.specified ?+ val.value :+ null;+ }+ });+}++return Sizzle;++})( window );++++jQuery.find = Sizzle;+jQuery.expr = Sizzle.selectors;+jQuery.expr[":"] = jQuery.expr.pseudos;+jQuery.unique = Sizzle.uniqueSort;+jQuery.text = Sizzle.getText;+jQuery.isXMLDoc = Sizzle.isXML;+jQuery.contains = Sizzle.contains;++++var rneedsContext = jQuery.expr.match.needsContext;++var rsingleTag = (/^<(\w+)\s*\/?>(?:<\/\1>|)$/);++++var risSimple = /^.[^:#\[\.,]*$/;++// Implement the identical functionality for filter and not+function winnow( elements, qualifier, not ) {+ if ( jQuery.isFunction( qualifier ) ) {+ return jQuery.grep( elements, function( elem, i ) {+ /* jshint -W018 */+ return !!qualifier.call( elem, i, elem ) !== not;+ });++ }++ if ( qualifier.nodeType ) {+ return jQuery.grep( elements, function( elem ) {+ return ( elem === qualifier ) !== not;+ });++ }++ if ( typeof qualifier === "string" ) {+ if ( risSimple.test( qualifier ) ) {+ return jQuery.filter( qualifier, elements, not );+ }++ qualifier = jQuery.filter( qualifier, elements );+ }++ return jQuery.grep( elements, function( elem ) {+ return ( indexOf.call( qualifier, elem ) >= 0 ) !== not;+ });+}++jQuery.filter = function( expr, elems, not ) {+ var elem = elems[ 0 ];++ if ( not ) {+ expr = ":not(" + expr + ")";+ }++ return elems.length === 1 && elem.nodeType === 1 ?+ jQuery.find.matchesSelector( elem, expr ) ? [ elem ] : [] :+ jQuery.find.matches( expr, jQuery.grep( elems, function( elem ) {+ return elem.nodeType === 1;+ }));+};++jQuery.fn.extend({+ find: function( selector ) {+ var i,+ len = this.length,+ ret = [],+ self = this;++ if ( typeof selector !== "string" ) {+ return this.pushStack( jQuery( selector ).filter(function() {+ for ( i = 0; i < len; i++ ) {+ if ( jQuery.contains( self[ i ], this ) ) {+ return true;+ }+ }+ }) );+ }++ for ( i = 0; i < len; i++ ) {+ jQuery.find( selector, self[ i ], ret );+ }++ // Needed because $( selector, context ) becomes $( context ).find( selector )+ ret = this.pushStack( len > 1 ? jQuery.unique( ret ) : ret );+ ret.selector = this.selector ? this.selector + " " + selector : selector;+ return ret;+ },+ filter: function( selector ) {+ return this.pushStack( winnow(this, selector || [], false) );+ },+ not: function( selector ) {+ return this.pushStack( winnow(this, selector || [], true) );+ },+ is: function( selector ) {+ return !!winnow(+ this,++ // If this is a positional/relative selector, check membership in the returned set+ // so $("p:first").is("p:last") won't return true for a doc with two "p".+ typeof selector === "string" && rneedsContext.test( selector ) ?+ jQuery( selector ) :+ selector || [],+ false+ ).length;+ }+});+++// Initialize a jQuery object+++// A central reference to the root jQuery(document)+var rootjQuery,++ // A simple way to check for HTML strings+ // Prioritize #id over <tag> to avoid XSS via location.hash (#9521)+ // Strict HTML recognition (#11290: must start with <)+ rquickExpr = /^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,++ init = jQuery.fn.init = function( selector, context ) {+ var match, elem;++ // HANDLE: $(""), $(null), $(undefined), $(false)+ if ( !selector ) {+ return this;+ }++ // Handle HTML strings+ if ( typeof selector === "string" ) {+ if ( selector[0] === "<" && selector[ selector.length - 1 ] === ">" && selector.length >= 3 ) {+ // Assume that strings that start and end with <> are HTML and skip the regex check+ match = [ null, selector, null ];++ } else {+ match = rquickExpr.exec( selector );+ }++ // Match html or make sure no context is specified for #id+ if ( match && (match[1] || !context) ) {++ // HANDLE: $(html) -> $(array)+ if ( match[1] ) {+ context = context instanceof jQuery ? context[0] : context;++ // scripts is true for back-compat+ // Intentionally let the error be thrown if parseHTML is not present+ jQuery.merge( this, jQuery.parseHTML(+ match[1],+ context && context.nodeType ? context.ownerDocument || context : document,+ true+ ) );++ // HANDLE: $(html, props)+ if ( rsingleTag.test( match[1] ) && jQuery.isPlainObject( context ) ) {+ for ( match in context ) {+ // Properties of context are called as methods if possible+ if ( jQuery.isFunction( this[ match ] ) ) {+ this[ match ]( context[ match ] );++ // ...and otherwise set as attributes+ } else {+ this.attr( match, context[ match ] );+ }+ }+ }++ return this;++ // HANDLE: $(#id)+ } else {+ elem = document.getElementById( match[2] );++ // Check parentNode to catch when Blackberry 4.6 returns+ // nodes that are no longer in the document #6963+ if ( elem && elem.parentNode ) {+ // Inject the element directly into the jQuery object+ this.length = 1;+ this[0] = elem;+ }++ this.context = document;+ this.selector = selector;+ return this;+ }++ // HANDLE: $(expr, $(...))+ } else if ( !context || context.jquery ) {+ return ( context || rootjQuery ).find( selector );++ // HANDLE: $(expr, context)+ // (which is just equivalent to: $(context).find(expr)+ } else {+ return this.constructor( context ).find( selector );+ }++ // HANDLE: $(DOMElement)+ } else if ( selector.nodeType ) {+ this.context = this[0] = selector;+ this.length = 1;+ return this;++ // HANDLE: $(function)+ // Shortcut for document ready+ } else if ( jQuery.isFunction( selector ) ) {+ return typeof rootjQuery.ready !== "undefined" ?+ rootjQuery.ready( selector ) :+ // Execute immediately if ready is not present+ selector( jQuery );+ }++ if ( selector.selector !== undefined ) {+ this.selector = selector.selector;+ this.context = selector.context;+ }++ return jQuery.makeArray( selector, this );+ };++// Give the init function the jQuery prototype for later instantiation+init.prototype = jQuery.fn;++// Initialize central reference+rootjQuery = jQuery( document );+++var rparentsprev = /^(?:parents|prev(?:Until|All))/,+ // methods guaranteed to produce a unique set when starting from a unique set+ guaranteedUnique = {+ children: true,+ contents: true,+ next: true,+ prev: true+ };++jQuery.extend({+ dir: function( elem, dir, until ) {+ var matched = [],+ truncate = until !== undefined;++ while ( (elem = elem[ dir ]) && elem.nodeType !== 9 ) {+ if ( elem.nodeType === 1 ) {+ if ( truncate && jQuery( elem ).is( until ) ) {+ break;+ }+ matched.push( elem );+ }+ }+ return matched;+ },++ sibling: function( n, elem ) {+ var matched = [];++ for ( ; n; n = n.nextSibling ) {+ if ( n.nodeType === 1 && n !== elem ) {+ matched.push( n );+ }+ }++ return matched;+ }+});++jQuery.fn.extend({+ has: function( target ) {+ var targets = jQuery( target, this ),+ l = targets.length;++ return this.filter(function() {+ var i = 0;+ for ( ; i < l; i++ ) {+ if ( jQuery.contains( this, targets[i] ) ) {+ return true;+ }+ }+ });+ },++ closest: function( selectors, context ) {+ var cur,+ i = 0,+ l = this.length,+ matched = [],+ pos = rneedsContext.test( selectors ) || typeof selectors !== "string" ?+ jQuery( selectors, context || this.context ) :+ 0;++ for ( ; i < l; i++ ) {+ for ( cur = this[i]; cur && cur !== context; cur = cur.parentNode ) {+ // Always skip document fragments+ if ( cur.nodeType < 11 && (pos ?+ pos.index(cur) > -1 :++ // Don't pass non-elements to Sizzle+ cur.nodeType === 1 &&+ jQuery.find.matchesSelector(cur, selectors)) ) {++ matched.push( cur );+ break;+ }+ }+ }++ return this.pushStack( matched.length > 1 ? jQuery.unique( matched ) : matched );+ },++ // Determine the position of an element within+ // the matched set of elements+ index: function( elem ) {++ // No argument, return index in parent+ if ( !elem ) {+ return ( this[ 0 ] && this[ 0 ].parentNode ) ? this.first().prevAll().length : -1;+ }++ // index in selector+ if ( typeof elem === "string" ) {+ return indexOf.call( jQuery( elem ), this[ 0 ] );+ }++ // Locate the position of the desired element+ return indexOf.call( this,++ // If it receives a jQuery object, the first element is used+ elem.jquery ? elem[ 0 ] : elem+ );+ },++ add: function( selector, context ) {+ return this.pushStack(+ jQuery.unique(+ jQuery.merge( this.get(), jQuery( selector, context ) )+ )+ );+ },++ addBack: function( selector ) {+ return this.add( selector == null ?+ this.prevObject : this.prevObject.filter(selector)+ );+ }+});++function sibling( cur, dir ) {+ while ( (cur = cur[dir]) && cur.nodeType !== 1 ) {}+ return cur;+}++jQuery.each({+ parent: function( elem ) {+ var parent = elem.parentNode;+ return parent && parent.nodeType !== 11 ? parent : null;+ },+ parents: function( elem ) {+ return jQuery.dir( elem, "parentNode" );+ },+ parentsUntil: function( elem, i, until ) {+ return jQuery.dir( elem, "parentNode", until );+ },+ next: function( elem ) {+ return sibling( elem, "nextSibling" );+ },+ prev: function( elem ) {+ return sibling( elem, "previousSibling" );+ },+ nextAll: function( elem ) {+ return jQuery.dir( elem, "nextSibling" );+ },+ prevAll: function( elem ) {+ return jQuery.dir( elem, "previousSibling" );+ },+ nextUntil: function( elem, i, until ) {+ return jQuery.dir( elem, "nextSibling", until );+ },+ prevUntil: function( elem, i, until ) {+ return jQuery.dir( elem, "previousSibling", until );+ },+ siblings: function( elem ) {+ return jQuery.sibling( ( elem.parentNode || {} ).firstChild, elem );+ },+ children: function( elem ) {+ return jQuery.sibling( elem.firstChild );+ },+ contents: function( elem ) {+ return elem.contentDocument || jQuery.merge( [], elem.childNodes );+ }+}, function( name, fn ) {+ jQuery.fn[ name ] = function( until, selector ) {+ var matched = jQuery.map( this, fn, until );++ if ( name.slice( -5 ) !== "Until" ) {+ selector = until;+ }++ if ( selector && typeof selector === "string" ) {+ matched = jQuery.filter( selector, matched );+ }++ if ( this.length > 1 ) {+ // Remove duplicates+ if ( !guaranteedUnique[ name ] ) {+ jQuery.unique( matched );+ }++ // Reverse order for parents* and prev-derivatives+ if ( rparentsprev.test( name ) ) {+ matched.reverse();+ }+ }++ return this.pushStack( matched );+ };+});+var rnotwhite = (/\S+/g);++++// String to Object options format cache+var optionsCache = {};++// Convert String-formatted options into Object-formatted ones and store in cache+function createOptions( options ) {+ var object = optionsCache[ options ] = {};+ jQuery.each( options.match( rnotwhite ) || [], function( _, flag ) {+ object[ flag ] = true;+ });+ return object;+}++/*+ * Create a callback list using the following parameters:+ *+ * options: an optional list of space-separated options that will change how+ * the callback list behaves or a more traditional option object+ *+ * By default a callback list will act like an event callback list and can be+ * "fired" multiple times.+ *+ * Possible options:+ *+ * once: will ensure the callback list can only be fired once (like a Deferred)+ *+ * memory: will keep track of previous values and will call any callback added+ * after the list has been fired right away with the latest "memorized"+ * values (like a Deferred)+ *+ * unique: will ensure a callback can only be added once (no duplicate in the list)+ *+ * stopOnFalse: interrupt callings when a callback returns false+ *+ */+jQuery.Callbacks = function( options ) {++ // Convert options from String-formatted to Object-formatted if needed+ // (we check in cache first)+ options = typeof options === "string" ?+ ( optionsCache[ options ] || createOptions( options ) ) :+ jQuery.extend( {}, options );++ var // Last fire value (for non-forgettable lists)+ memory,+ // Flag to know if list was already fired+ fired,+ // Flag to know if list is currently firing+ firing,+ // First callback to fire (used internally by add and fireWith)+ firingStart,+ // End of the loop when firing+ firingLength,+ // Index of currently firing callback (modified by remove if needed)+ firingIndex,+ // Actual callback list+ list = [],+ // Stack of fire calls for repeatable lists+ stack = !options.once && [],+ // Fire callbacks+ fire = function( data ) {+ memory = options.memory && data;+ fired = true;+ firingIndex = firingStart || 0;+ firingStart = 0;+ firingLength = list.length;+ firing = true;+ for ( ; list && firingIndex < firingLength; firingIndex++ ) {+ if ( list[ firingIndex ].apply( data[ 0 ], data[ 1 ] ) === false && options.stopOnFalse ) {+ memory = false; // To prevent further calls using add+ break;+ }+ }+ firing = false;+ if ( list ) {+ if ( stack ) {+ if ( stack.length ) {+ fire( stack.shift() );+ }+ } else if ( memory ) {+ list = [];+ } else {+ self.disable();+ }+ }+ },+ // Actual Callbacks object+ self = {+ // Add a callback or a collection of callbacks to the list+ add: function() {+ if ( list ) {+ // First, we save the current length+ var start = list.length;+ (function add( args ) {+ jQuery.each( args, function( _, arg ) {+ var type = jQuery.type( arg );+ if ( type === "function" ) {+ if ( !options.unique || !self.has( arg ) ) {+ list.push( arg );+ }+ } else if ( arg && arg.length && type !== "string" ) {+ // Inspect recursively+ add( arg );+ }+ });+ })( arguments );+ // Do we need to add the callbacks to the+ // current firing batch?+ if ( firing ) {+ firingLength = list.length;+ // With memory, if we're not firing then+ // we should call right away+ } else if ( memory ) {+ firingStart = start;+ fire( memory );+ }+ }+ return this;+ },+ // Remove a callback from the list+ remove: function() {+ if ( list ) {+ jQuery.each( arguments, function( _, arg ) {+ var index;+ while ( ( index = jQuery.inArray( arg, list, index ) ) > -1 ) {+ list.splice( index, 1 );+ // Handle firing indexes+ if ( firing ) {+ if ( index <= firingLength ) {+ firingLength--;+ }+ if ( index <= firingIndex ) {+ firingIndex--;+ }+ }+ }+ });+ }+ return this;+ },+ // Check if a given callback is in the list.+ // If no argument is given, return whether or not list has callbacks attached.+ has: function( fn ) {+ return fn ? jQuery.inArray( fn, list ) > -1 : !!( list && list.length );+ },+ // Remove all callbacks from the list+ empty: function() {+ list = [];+ firingLength = 0;+ return this;+ },+ // Have the list do nothing anymore+ disable: function() {+ list = stack = memory = undefined;+ return this;+ },+ // Is it disabled?+ disabled: function() {+ return !list;+ },+ // Lock the list in its current state+ lock: function() {+ stack = undefined;+ if ( !memory ) {+ self.disable();+ }+ return this;+ },+ // Is it locked?+ locked: function() {+ return !stack;+ },+ // Call all callbacks with the given context and arguments+ fireWith: function( context, args ) {+ if ( list && ( !fired || stack ) ) {+ args = args || [];+ args = [ context, args.slice ? args.slice() : args ];+ if ( firing ) {+ stack.push( args );+ } else {+ fire( args );+ }+ }+ return this;+ },+ // Call all the callbacks with the given arguments+ fire: function() {+ self.fireWith( this, arguments );+ return this;+ },+ // To know if the callbacks have already been called at least once+ fired: function() {+ return !!fired;+ }+ };++ return self;+};+++jQuery.extend({++ Deferred: function( func ) {+ var tuples = [+ // action, add listener, listener list, final state+ [ "resolve", "done", jQuery.Callbacks("once memory"), "resolved" ],+ [ "reject", "fail", jQuery.Callbacks("once memory"), "rejected" ],+ [ "notify", "progress", jQuery.Callbacks("memory") ]+ ],+ state = "pending",+ promise = {+ state: function() {+ return state;+ },+ always: function() {+ deferred.done( arguments ).fail( arguments );+ return this;+ },+ then: function( /* fnDone, fnFail, fnProgress */ ) {+ var fns = arguments;+ return jQuery.Deferred(function( newDefer ) {+ jQuery.each( tuples, function( i, tuple ) {+ var fn = jQuery.isFunction( fns[ i ] ) && fns[ i ];+ // deferred[ done | fail | progress ] for forwarding actions to newDefer+ deferred[ tuple[1] ](function() {+ var returned = fn && fn.apply( this, arguments );+ if ( returned && jQuery.isFunction( returned.promise ) ) {+ returned.promise()+ .done( newDefer.resolve )+ .fail( newDefer.reject )+ .progress( newDefer.notify );+ } else {+ newDefer[ tuple[ 0 ] + "With" ]( this === promise ? newDefer.promise() : this, fn ? [ returned ] : arguments );+ }+ });+ });+ fns = null;+ }).promise();+ },+ // Get a promise for this deferred+ // If obj is provided, the promise aspect is added to the object+ promise: function( obj ) {+ return obj != null ? jQuery.extend( obj, promise ) : promise;+ }+ },+ deferred = {};++ // Keep pipe for back-compat+ promise.pipe = promise.then;++ // Add list-specific methods+ jQuery.each( tuples, function( i, tuple ) {+ var list = tuple[ 2 ],+ stateString = tuple[ 3 ];++ // promise[ done | fail | progress ] = list.add+ promise[ tuple[1] ] = list.add;++ // Handle state+ if ( stateString ) {+ list.add(function() {+ // state = [ resolved | rejected ]+ state = stateString;++ // [ reject_list | resolve_list ].disable; progress_list.lock+ }, tuples[ i ^ 1 ][ 2 ].disable, tuples[ 2 ][ 2 ].lock );+ }++ // deferred[ resolve | reject | notify ]+ deferred[ tuple[0] ] = function() {+ deferred[ tuple[0] + "With" ]( this === deferred ? promise : this, arguments );+ return this;+ };+ deferred[ tuple[0] + "With" ] = list.fireWith;+ });++ // Make the deferred a promise+ promise.promise( deferred );++ // Call given func if any+ if ( func ) {+ func.call( deferred, deferred );+ }++ // All done!+ return deferred;+ },++ // Deferred helper+ when: function( subordinate /* , ..., subordinateN */ ) {+ var i = 0,+ resolveValues = slice.call( arguments ),+ length = resolveValues.length,++ // the count of uncompleted subordinates+ remaining = length !== 1 || ( subordinate && jQuery.isFunction( subordinate.promise ) ) ? length : 0,++ // the master Deferred. If resolveValues consist of only a single Deferred, just use that.+ deferred = remaining === 1 ? subordinate : jQuery.Deferred(),++ // Update function for both resolve and progress values+ updateFunc = function( i, contexts, values ) {+ return function( value ) {+ contexts[ i ] = this;+ values[ i ] = arguments.length > 1 ? slice.call( arguments ) : value;+ if ( values === progressValues ) {+ deferred.notifyWith( contexts, values );+ } else if ( !( --remaining ) ) {+ deferred.resolveWith( contexts, values );+ }+ };+ },++ progressValues, progressContexts, resolveContexts;++ // add listeners to Deferred subordinates; treat others as resolved+ if ( length > 1 ) {+ progressValues = new Array( length );+ progressContexts = new Array( length );+ resolveContexts = new Array( length );+ for ( ; i < length; i++ ) {+ if ( resolveValues[ i ] && jQuery.isFunction( resolveValues[ i ].promise ) ) {+ resolveValues[ i ].promise()+ .done( updateFunc( i, resolveContexts, resolveValues ) )+ .fail( deferred.reject )+ .progress( updateFunc( i, progressContexts, progressValues ) );+ } else {+ --remaining;+ }+ }+ }++ // if we're not waiting on anything, resolve the master+ if ( !remaining ) {+ deferred.resolveWith( resolveContexts, resolveValues );+ }++ return deferred.promise();+ }+});+++// The deferred used on DOM ready+var readyList;++jQuery.fn.ready = function( fn ) {+ // Add the callback+ jQuery.ready.promise().done( fn );++ return this;+};++jQuery.extend({+ // Is the DOM ready to be used? Set to true once it occurs.+ isReady: false,++ // A counter to track how many items to wait for before+ // the ready event fires. See #6781+ readyWait: 1,++ // Hold (or release) the ready event+ holdReady: function( hold ) {+ if ( hold ) {+ jQuery.readyWait++;+ } else {+ jQuery.ready( true );+ }+ },++ // Handle when the DOM is ready+ ready: function( wait ) {++ // Abort if there are pending holds or we're already ready+ if ( wait === true ? --jQuery.readyWait : jQuery.isReady ) {+ return;+ }++ // Remember that the DOM is ready+ jQuery.isReady = true;++ // If a normal DOM Ready event fired, decrement, and wait if need be+ if ( wait !== true && --jQuery.readyWait > 0 ) {+ return;+ }++ // If there are functions bound, to execute+ readyList.resolveWith( document, [ jQuery ] );++ // Trigger any bound ready events+ if ( jQuery.fn.triggerHandler ) {+ jQuery( document ).triggerHandler( "ready" );+ jQuery( document ).off( "ready" );+ }+ }+});++/**+ * The ready event handler and self cleanup method+ */+function completed() {+ document.removeEventListener( "DOMContentLoaded", completed, false );+ window.removeEventListener( "load", completed, false );+ jQuery.ready();+}++jQuery.ready.promise = function( obj ) {+ if ( !readyList ) {++ readyList = jQuery.Deferred();++ // Catch cases where $(document).ready() is called after the browser event has already occurred.+ // we once tried to use readyState "interactive" here, but it caused issues like the one+ // discovered by ChrisS here: http://bugs.jquery.com/ticket/12282#comment:15+ if ( document.readyState === "complete" ) {+ // Handle it asynchronously to allow scripts the opportunity to delay ready+ setTimeout( jQuery.ready );++ } else {++ // Use the handy event callback+ document.addEventListener( "DOMContentLoaded", completed, false );++ // A fallback to window.onload, that will always work+ window.addEventListener( "load", completed, false );+ }+ }+ return readyList.promise( obj );+};++// Kick off the DOM ready check even if the user does not+jQuery.ready.promise();+++++// Multifunctional method to get and set values of a collection+// The value/s can optionally be executed if it's a function+var access = jQuery.access = function( elems, fn, key, value, chainable, emptyGet, raw ) {+ var i = 0,+ len = elems.length,+ bulk = key == null;++ // Sets many values+ if ( jQuery.type( key ) === "object" ) {+ chainable = true;+ for ( i in key ) {+ jQuery.access( elems, fn, i, key[i], true, emptyGet, raw );+ }++ // Sets one value+ } else if ( value !== undefined ) {+ chainable = true;++ if ( !jQuery.isFunction( value ) ) {+ raw = true;+ }++ if ( bulk ) {+ // Bulk operations run against the entire set+ if ( raw ) {+ fn.call( elems, value );+ fn = null;++ // ...except when executing function values+ } else {+ bulk = fn;+ fn = function( elem, key, value ) {+ return bulk.call( jQuery( elem ), value );+ };+ }+ }++ if ( fn ) {+ for ( ; i < len; i++ ) {+ fn( elems[i], key, raw ? value : value.call( elems[i], i, fn( elems[i], key ) ) );+ }+ }+ }++ return chainable ?+ elems :++ // Gets+ bulk ?+ fn.call( elems ) :+ len ? fn( elems[0], key ) : emptyGet;+};+++/**+ * Determines whether an object can have data+ */+jQuery.acceptData = function( owner ) {+ // Accepts only:+ // - Node+ // - Node.ELEMENT_NODE+ // - Node.DOCUMENT_NODE+ // - Object+ // - Any+ /* jshint -W018 */+ return owner.nodeType === 1 || owner.nodeType === 9 || !( +owner.nodeType );+};+++function Data() {+ // Support: Android < 4,+ // Old WebKit does not have Object.preventExtensions/freeze method,+ // return new empty object instead with no [[set]] accessor+ Object.defineProperty( this.cache = {}, 0, {+ get: function() {+ return {};+ }+ });++ this.expando = jQuery.expando + Math.random();+}++Data.uid = 1;+Data.accepts = jQuery.acceptData;++Data.prototype = {+ key: function( owner ) {+ // We can accept data for non-element nodes in modern browsers,+ // but we should not, see #8335.+ // Always return the key for a frozen object.+ if ( !Data.accepts( owner ) ) {+ return 0;+ }++ var descriptor = {},+ // Check if the owner object already has a cache key+ unlock = owner[ this.expando ];++ // If not, create one+ if ( !unlock ) {+ unlock = Data.uid++;++ // Secure it in a non-enumerable, non-writable property+ try {+ descriptor[ this.expando ] = { value: unlock };+ Object.defineProperties( owner, descriptor );++ // Support: Android < 4+ // Fallback to a less secure definition+ } catch ( e ) {+ descriptor[ this.expando ] = unlock;+ jQuery.extend( owner, descriptor );+ }+ }++ // Ensure the cache object+ if ( !this.cache[ unlock ] ) {+ this.cache[ unlock ] = {};+ }++ return unlock;+ },+ set: function( owner, data, value ) {+ var prop,+ // There may be an unlock assigned to this node,+ // if there is no entry for this "owner", create one inline+ // and set the unlock as though an owner entry had always existed+ unlock = this.key( owner ),+ cache = this.cache[ unlock ];++ // Handle: [ owner, key, value ] args+ if ( typeof data === "string" ) {+ cache[ data ] = value;++ // Handle: [ owner, { properties } ] args+ } else {+ // Fresh assignments by object are shallow copied+ if ( jQuery.isEmptyObject( cache ) ) {+ jQuery.extend( this.cache[ unlock ], data );+ // Otherwise, copy the properties one-by-one to the cache object+ } else {+ for ( prop in data ) {+ cache[ prop ] = data[ prop ];+ }+ }+ }+ return cache;+ },+ get: function( owner, key ) {+ // Either a valid cache is found, or will be created.+ // New caches will be created and the unlock returned,+ // allowing direct access to the newly created+ // empty data object. A valid owner object must be provided.+ var cache = this.cache[ this.key( owner ) ];++ return key === undefined ?+ cache : cache[ key ];+ },+ access: function( owner, key, value ) {+ var stored;+ // In cases where either:+ //+ // 1. No key was specified+ // 2. A string key was specified, but no value provided+ //+ // Take the "read" path and allow the get method to determine+ // which value to return, respectively either:+ //+ // 1. The entire cache object+ // 2. The data stored at the key+ //+ if ( key === undefined ||+ ((key && typeof key === "string") && value === undefined) ) {++ stored = this.get( owner, key );++ return stored !== undefined ?+ stored : this.get( owner, jQuery.camelCase(key) );+ }++ // [*]When the key is not a string, or both a key and value+ // are specified, set or extend (existing objects) with either:+ //+ // 1. An object of properties+ // 2. A key and value+ //+ this.set( owner, key, value );++ // Since the "set" path can have two possible entry points+ // return the expected data based on which path was taken[*]+ return value !== undefined ? value : key;+ },+ remove: function( owner, key ) {+ var i, name, camel,+ unlock = this.key( owner ),+ cache = this.cache[ unlock ];++ if ( key === undefined ) {+ this.cache[ unlock ] = {};++ } else {+ // Support array or space separated string of keys+ if ( jQuery.isArray( key ) ) {+ // If "name" is an array of keys...+ // When data is initially created, via ("key", "val") signature,+ // keys will be converted to camelCase.+ // Since there is no way to tell _how_ a key was added, remove+ // both plain key and camelCase key. #12786+ // This will only penalize the array argument path.+ name = key.concat( key.map( jQuery.camelCase ) );+ } else {+ camel = jQuery.camelCase( key );+ // Try the string as a key before any manipulation+ if ( key in cache ) {+ name = [ key, camel ];+ } else {+ // If a key with the spaces exists, use it.+ // Otherwise, create an array by matching non-whitespace+ name = camel;+ name = name in cache ?+ [ name ] : ( name.match( rnotwhite ) || [] );+ }+ }++ i = name.length;+ while ( i-- ) {+ delete cache[ name[ i ] ];+ }+ }+ },+ hasData: function( owner ) {+ return !jQuery.isEmptyObject(+ this.cache[ owner[ this.expando ] ] || {}+ );+ },+ discard: function( owner ) {+ if ( owner[ this.expando ] ) {+ delete this.cache[ owner[ this.expando ] ];+ }+ }+};+var data_priv = new Data();++var data_user = new Data();++++/*+ Implementation Summary++ 1. Enforce API surface and semantic compatibility with 1.9.x branch+ 2. Improve the module's maintainability by reducing the storage+ paths to a single mechanism.+ 3. Use the same single mechanism to support "private" and "user" data.+ 4. _Never_ expose "private" data to user code (TODO: Drop _data, _removeData)+ 5. Avoid exposing implementation details on user objects (eg. expando properties)+ 6. Provide a clear path for implementation upgrade to WeakMap in 2014+*/+var rbrace = /^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,+ rmultiDash = /([A-Z])/g;++function dataAttr( elem, key, data ) {+ var name;++ // If nothing was found internally, try to fetch any+ // data from the HTML5 data-* attribute+ if ( data === undefined && elem.nodeType === 1 ) {+ name = "data-" + key.replace( rmultiDash, "-$1" ).toLowerCase();+ data = elem.getAttribute( name );++ if ( typeof data === "string" ) {+ try {+ data = data === "true" ? true :+ data === "false" ? false :+ data === "null" ? null :+ // Only convert to a number if it doesn't change the string+ +data + "" === data ? +data :+ rbrace.test( data ) ? jQuery.parseJSON( data ) :+ data;+ } catch( e ) {}++ // Make sure we set the data so it isn't changed later+ data_user.set( elem, key, data );+ } else {+ data = undefined;+ }+ }+ return data;+}++jQuery.extend({+ hasData: function( elem ) {+ return data_user.hasData( elem ) || data_priv.hasData( elem );+ },++ data: function( elem, name, data ) {+ return data_user.access( elem, name, data );+ },++ removeData: function( elem, name ) {+ data_user.remove( elem, name );+ },++ // TODO: Now that all calls to _data and _removeData have been replaced+ // with direct calls to data_priv methods, these can be deprecated.+ _data: function( elem, name, data ) {+ return data_priv.access( elem, name, data );+ },++ _removeData: function( elem, name ) {+ data_priv.remove( elem, name );+ }+});++jQuery.fn.extend({+ data: function( key, value ) {+ var i, name, data,+ elem = this[ 0 ],+ attrs = elem && elem.attributes;++ // Gets all values+ if ( key === undefined ) {+ if ( this.length ) {+ data = data_user.get( elem );++ if ( elem.nodeType === 1 && !data_priv.get( elem, "hasDataAttrs" ) ) {+ i = attrs.length;+ while ( i-- ) {++ // Support: IE11++ // The attrs elements can be null (#14894)+ if ( attrs[ i ] ) {+ name = attrs[ i ].name;+ if ( name.indexOf( "data-" ) === 0 ) {+ name = jQuery.camelCase( name.slice(5) );+ dataAttr( elem, name, data[ name ] );+ }+ }+ }+ data_priv.set( elem, "hasDataAttrs", true );+ }+ }++ return data;+ }++ // Sets multiple values+ if ( typeof key === "object" ) {+ return this.each(function() {+ data_user.set( this, key );+ });+ }++ return access( this, function( value ) {+ var data,+ camelKey = jQuery.camelCase( key );++ // The calling jQuery object (element matches) is not empty+ // (and therefore has an element appears at this[ 0 ]) and the+ // `value` parameter was not undefined. An empty jQuery object+ // will result in `undefined` for elem = this[ 0 ] which will+ // throw an exception if an attempt to read a data cache is made.+ if ( elem && value === undefined ) {+ // Attempt to get data from the cache+ // with the key as-is+ data = data_user.get( elem, key );+ if ( data !== undefined ) {+ return data;+ }++ // Attempt to get data from the cache+ // with the key camelized+ data = data_user.get( elem, camelKey );+ if ( data !== undefined ) {+ return data;+ }++ // Attempt to "discover" the data in+ // HTML5 custom data-* attrs+ data = dataAttr( elem, camelKey, undefined );+ if ( data !== undefined ) {+ return data;+ }++ // We tried really hard, but the data doesn't exist.+ return;+ }++ // Set the data...+ this.each(function() {+ // First, attempt to store a copy or reference of any+ // data that might've been store with a camelCased key.+ var data = data_user.get( this, camelKey );++ // For HTML5 data-* attribute interop, we have to+ // store property names with dashes in a camelCase form.+ // This might not apply to all properties...*+ data_user.set( this, camelKey, value );++ // *... In the case of properties that might _actually_+ // have dashes, we need to also store a copy of that+ // unchanged property.+ if ( key.indexOf("-") !== -1 && data !== undefined ) {+ data_user.set( this, key, value );+ }+ });+ }, null, value, arguments.length > 1, null, true );+ },++ removeData: function( key ) {+ return this.each(function() {+ data_user.remove( this, key );+ });+ }+});+++jQuery.extend({+ queue: function( elem, type, data ) {+ var queue;++ if ( elem ) {+ type = ( type || "fx" ) + "queue";+ queue = data_priv.get( elem, type );++ // Speed up dequeue by getting out quickly if this is just a lookup+ if ( data ) {+ if ( !queue || jQuery.isArray( data ) ) {+ queue = data_priv.access( elem, type, jQuery.makeArray(data) );+ } else {+ queue.push( data );+ }+ }+ return queue || [];+ }+ },++ dequeue: function( elem, type ) {+ type = type || "fx";++ var queue = jQuery.queue( elem, type ),+ startLength = queue.length,+ fn = queue.shift(),+ hooks = jQuery._queueHooks( elem, type ),+ next = function() {+ jQuery.dequeue( elem, type );+ };++ // If the fx queue is dequeued, always remove the progress sentinel+ if ( fn === "inprogress" ) {+ fn = queue.shift();+ startLength--;+ }++ if ( fn ) {++ // Add a progress sentinel to prevent the fx queue from being+ // automatically dequeued+ if ( type === "fx" ) {+ queue.unshift( "inprogress" );+ }++ // clear up the last queue stop function+ delete hooks.stop;+ fn.call( elem, next, hooks );+ }++ if ( !startLength && hooks ) {+ hooks.empty.fire();+ }+ },++ // not intended for public consumption - generates a queueHooks object, or returns the current one+ _queueHooks: function( elem, type ) {+ var key = type + "queueHooks";+ return data_priv.get( elem, key ) || data_priv.access( elem, key, {+ empty: jQuery.Callbacks("once memory").add(function() {+ data_priv.remove( elem, [ type + "queue", key ] );+ })+ });+ }+});++jQuery.fn.extend({+ queue: function( type, data ) {+ var setter = 2;++ if ( typeof type !== "string" ) {+ data = type;+ type = "fx";+ setter--;+ }++ if ( arguments.length < setter ) {+ return jQuery.queue( this[0], type );+ }++ return data === undefined ?+ this :+ this.each(function() {+ var queue = jQuery.queue( this, type, data );++ // ensure a hooks for this queue+ jQuery._queueHooks( this, type );++ if ( type === "fx" && queue[0] !== "inprogress" ) {+ jQuery.dequeue( this, type );+ }+ });+ },+ dequeue: function( type ) {+ return this.each(function() {+ jQuery.dequeue( this, type );+ });+ },+ clearQueue: function( type ) {+ return this.queue( type || "fx", [] );+ },+ // Get a promise resolved when queues of a certain type+ // are emptied (fx is the type by default)+ promise: function( type, obj ) {+ var tmp,+ count = 1,+ defer = jQuery.Deferred(),+ elements = this,+ i = this.length,+ resolve = function() {+ if ( !( --count ) ) {+ defer.resolveWith( elements, [ elements ] );+ }+ };++ if ( typeof type !== "string" ) {+ obj = type;+ type = undefined;+ }+ type = type || "fx";++ while ( i-- ) {+ tmp = data_priv.get( elements[ i ], type + "queueHooks" );+ if ( tmp && tmp.empty ) {+ count++;+ tmp.empty.add( resolve );+ }+ }+ resolve();+ return defer.promise( obj );+ }+});+var pnum = (/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/).source;++var cssExpand = [ "Top", "Right", "Bottom", "Left" ];++var isHidden = function( elem, el ) {+ // isHidden might be called from jQuery#filter function;+ // in that case, element will be second argument+ elem = el || elem;+ return jQuery.css( elem, "display" ) === "none" || !jQuery.contains( elem.ownerDocument, elem );+ };++var rcheckableType = (/^(?:checkbox|radio)$/i);++++(function() {+ var fragment = document.createDocumentFragment(),+ div = fragment.appendChild( document.createElement( "div" ) ),+ input = document.createElement( "input" );++ // #11217 - WebKit loses check when the name is after the checked attribute+ // Support: Windows Web Apps (WWA)+ // `name` and `type` need .setAttribute for WWA+ input.setAttribute( "type", "radio" );+ input.setAttribute( "checked", "checked" );+ input.setAttribute( "name", "t" );++ div.appendChild( input );++ // Support: Safari 5.1, iOS 5.1, Android 4.x, Android 2.3+ // old WebKit doesn't clone checked state correctly in fragments+ support.checkClone = div.cloneNode( true ).cloneNode( true ).lastChild.checked;++ // Make sure textarea (and checkbox) defaultValue is properly cloned+ // Support: IE9-IE11++ div.innerHTML = "<textarea>x</textarea>";+ support.noCloneChecked = !!div.cloneNode( true ).lastChild.defaultValue;+})();+var strundefined = typeof undefined;++++support.focusinBubbles = "onfocusin" in window;+++var+ rkeyEvent = /^key/,+ rmouseEvent = /^(?:mouse|pointer|contextmenu)|click/,+ rfocusMorph = /^(?:focusinfocus|focusoutblur)$/,+ rtypenamespace = /^([^.]*)(?:\.(.+)|)$/;++function returnTrue() {+ return true;+}++function returnFalse() {+ return false;+}++function safeActiveElement() {+ try {+ return document.activeElement;+ } catch ( err ) { }+}++/*+ * Helper functions for managing events -- not part of the public interface.+ * Props to Dean Edwards' addEvent library for many of the ideas.+ */+jQuery.event = {++ global: {},++ add: function( elem, types, handler, data, selector ) {++ var handleObjIn, eventHandle, tmp,+ events, t, handleObj,+ special, handlers, type, namespaces, origType,+ elemData = data_priv.get( elem );++ // Don't attach events to noData or text/comment nodes (but allow plain objects)+ if ( !elemData ) {+ return;+ }++ // Caller can pass in an object of custom data in lieu of the handler+ if ( handler.handler ) {+ handleObjIn = handler;+ handler = handleObjIn.handler;+ selector = handleObjIn.selector;+ }++ // Make sure that the handler has a unique ID, used to find/remove it later+ if ( !handler.guid ) {+ handler.guid = jQuery.guid++;+ }++ // Init the element's event structure and main handler, if this is the first+ if ( !(events = elemData.events) ) {+ events = elemData.events = {};+ }+ if ( !(eventHandle = elemData.handle) ) {+ eventHandle = elemData.handle = function( e ) {+ // Discard the second event of a jQuery.event.trigger() and+ // when an event is called after a page has unloaded+ return typeof jQuery !== strundefined && jQuery.event.triggered !== e.type ?+ jQuery.event.dispatch.apply( elem, arguments ) : undefined;+ };+ }++ // Handle multiple events separated by a space+ types = ( types || "" ).match( rnotwhite ) || [ "" ];+ t = types.length;+ while ( t-- ) {+ tmp = rtypenamespace.exec( types[t] ) || [];+ type = origType = tmp[1];+ namespaces = ( tmp[2] || "" ).split( "." ).sort();++ // There *must* be a type, no attaching namespace-only handlers+ if ( !type ) {+ continue;+ }++ // If event changes its type, use the special event handlers for the changed type+ special = jQuery.event.special[ type ] || {};++ // If selector defined, determine special event api type, otherwise given type+ type = ( selector ? special.delegateType : special.bindType ) || type;++ // Update special based on newly reset type+ special = jQuery.event.special[ type ] || {};++ // handleObj is passed to all event handlers+ handleObj = jQuery.extend({+ type: type,+ origType: origType,+ data: data,+ handler: handler,+ guid: handler.guid,+ selector: selector,+ needsContext: selector && jQuery.expr.match.needsContext.test( selector ),+ namespace: namespaces.join(".")+ }, handleObjIn );++ // Init the event handler queue if we're the first+ if ( !(handlers = events[ type ]) ) {+ handlers = events[ type ] = [];+ handlers.delegateCount = 0;++ // Only use addEventListener if the special events handler returns false+ if ( !special.setup || special.setup.call( elem, data, namespaces, eventHandle ) === false ) {+ if ( elem.addEventListener ) {+ elem.addEventListener( type, eventHandle, false );+ }+ }+ }++ if ( special.add ) {+ special.add.call( elem, handleObj );++ if ( !handleObj.handler.guid ) {+ handleObj.handler.guid = handler.guid;+ }+ }++ // Add to the element's handler list, delegates in front+ if ( selector ) {+ handlers.splice( handlers.delegateCount++, 0, handleObj );+ } else {+ handlers.push( handleObj );+ }++ // Keep track of which events have ever been used, for event optimization+ jQuery.event.global[ type ] = true;+ }++ },++ // Detach an event or set of events from an element+ remove: function( elem, types, handler, selector, mappedTypes ) {++ var j, origCount, tmp,+ events, t, handleObj,+ special, handlers, type, namespaces, origType,+ elemData = data_priv.hasData( elem ) && data_priv.get( elem );++ if ( !elemData || !(events = elemData.events) ) {+ return;+ }++ // Once for each type.namespace in types; type may be omitted+ types = ( types || "" ).match( rnotwhite ) || [ "" ];+ t = types.length;+ while ( t-- ) {+ tmp = rtypenamespace.exec( types[t] ) || [];+ type = origType = tmp[1];+ namespaces = ( tmp[2] || "" ).split( "." ).sort();++ // Unbind all events (on this namespace, if provided) for the element+ if ( !type ) {+ for ( type in events ) {+ jQuery.event.remove( elem, type + types[ t ], handler, selector, true );+ }+ continue;+ }++ special = jQuery.event.special[ type ] || {};+ type = ( selector ? special.delegateType : special.bindType ) || type;+ handlers = events[ type ] || [];+ tmp = tmp[2] && new RegExp( "(^|\\.)" + namespaces.join("\\.(?:.*\\.|)") + "(\\.|$)" );++ // Remove matching events+ origCount = j = handlers.length;+ while ( j-- ) {+ handleObj = handlers[ j ];++ if ( ( mappedTypes || origType === handleObj.origType ) &&+ ( !handler || handler.guid === handleObj.guid ) &&+ ( !tmp || tmp.test( handleObj.namespace ) ) &&+ ( !selector || selector === handleObj.selector || selector === "**" && handleObj.selector ) ) {+ handlers.splice( j, 1 );++ if ( handleObj.selector ) {+ handlers.delegateCount--;+ }+ if ( special.remove ) {+ special.remove.call( elem, handleObj );+ }+ }+ }++ // Remove generic event handler if we removed something and no more handlers exist+ // (avoids potential for endless recursion during removal of special event handlers)+ if ( origCount && !handlers.length ) {+ if ( !special.teardown || special.teardown.call( elem, namespaces, elemData.handle ) === false ) {+ jQuery.removeEvent( elem, type, elemData.handle );+ }++ delete events[ type ];+ }+ }++ // Remove the expando if it's no longer used+ if ( jQuery.isEmptyObject( events ) ) {+ delete elemData.handle;+ data_priv.remove( elem, "events" );+ }+ },++ trigger: function( event, data, elem, onlyHandlers ) {++ var i, cur, tmp, bubbleType, ontype, handle, special,+ eventPath = [ elem || document ],+ type = hasOwn.call( event, "type" ) ? event.type : event,+ namespaces = hasOwn.call( event, "namespace" ) ? event.namespace.split(".") : [];++ cur = tmp = elem = elem || document;++ // Don't do events on text and comment nodes+ if ( elem.nodeType === 3 || elem.nodeType === 8 ) {+ return;+ }++ // focus/blur morphs to focusin/out; ensure we're not firing them right now+ if ( rfocusMorph.test( type + jQuery.event.triggered ) ) {+ return;+ }++ if ( type.indexOf(".") >= 0 ) {+ // Namespaced trigger; create a regexp to match event type in handle()+ namespaces = type.split(".");+ type = namespaces.shift();+ namespaces.sort();+ }+ ontype = type.indexOf(":") < 0 && "on" + type;++ // Caller can pass in a jQuery.Event object, Object, or just an event type string+ event = event[ jQuery.expando ] ?+ event :+ new jQuery.Event( type, typeof event === "object" && event );++ // Trigger bitmask: & 1 for native handlers; & 2 for jQuery (always true)+ event.isTrigger = onlyHandlers ? 2 : 3;+ event.namespace = namespaces.join(".");+ event.namespace_re = event.namespace ?+ new RegExp( "(^|\\.)" + namespaces.join("\\.(?:.*\\.|)") + "(\\.|$)" ) :+ null;++ // Clean up the event in case it is being reused+ event.result = undefined;+ if ( !event.target ) {+ event.target = elem;+ }++ // Clone any incoming data and prepend the event, creating the handler arg list+ data = data == null ?+ [ event ] :+ jQuery.makeArray( data, [ event ] );++ // Allow special events to draw outside the lines+ special = jQuery.event.special[ type ] || {};+ if ( !onlyHandlers && special.trigger && special.trigger.apply( elem, data ) === false ) {+ return;+ }++ // Determine event propagation path in advance, per W3C events spec (#9951)+ // Bubble up to document, then to window; watch for a global ownerDocument var (#9724)+ if ( !onlyHandlers && !special.noBubble && !jQuery.isWindow( elem ) ) {++ bubbleType = special.delegateType || type;+ if ( !rfocusMorph.test( bubbleType + type ) ) {+ cur = cur.parentNode;+ }+ for ( ; cur; cur = cur.parentNode ) {+ eventPath.push( cur );+ tmp = cur;+ }++ // Only add window if we got to document (e.g., not plain obj or detached DOM)+ if ( tmp === (elem.ownerDocument || document) ) {+ eventPath.push( tmp.defaultView || tmp.parentWindow || window );+ }+ }++ // Fire handlers on the event path+ i = 0;+ while ( (cur = eventPath[i++]) && !event.isPropagationStopped() ) {++ event.type = i > 1 ?+ bubbleType :+ special.bindType || type;++ // jQuery handler+ handle = ( data_priv.get( cur, "events" ) || {} )[ event.type ] && data_priv.get( cur, "handle" );+ if ( handle ) {+ handle.apply( cur, data );+ }++ // Native handler+ handle = ontype && cur[ ontype ];+ if ( handle && handle.apply && jQuery.acceptData( cur ) ) {+ event.result = handle.apply( cur, data );+ if ( event.result === false ) {+ event.preventDefault();+ }+ }+ }+ event.type = type;++ // If nobody prevented the default action, do it now+ if ( !onlyHandlers && !event.isDefaultPrevented() ) {++ if ( (!special._default || special._default.apply( eventPath.pop(), data ) === false) &&+ jQuery.acceptData( elem ) ) {++ // Call a native DOM method on the target with the same name name as the event.+ // Don't do default actions on window, that's where global variables be (#6170)+ if ( ontype && jQuery.isFunction( elem[ type ] ) && !jQuery.isWindow( elem ) ) {++ // Don't re-trigger an onFOO event when we call its FOO() method+ tmp = elem[ ontype ];++ if ( tmp ) {+ elem[ ontype ] = null;+ }++ // Prevent re-triggering of the same event, since we already bubbled it above+ jQuery.event.triggered = type;+ elem[ type ]();+ jQuery.event.triggered = undefined;++ if ( tmp ) {+ elem[ ontype ] = tmp;+ }+ }+ }+ }++ return event.result;+ },++ dispatch: function( event ) {++ // Make a writable jQuery.Event from the native event object+ event = jQuery.event.fix( event );++ var i, j, ret, matched, handleObj,+ handlerQueue = [],+ args = slice.call( arguments ),+ handlers = ( data_priv.get( this, "events" ) || {} )[ event.type ] || [],+ special = jQuery.event.special[ event.type ] || {};++ // Use the fix-ed jQuery.Event rather than the (read-only) native event+ args[0] = event;+ event.delegateTarget = this;++ // Call the preDispatch hook for the mapped type, and let it bail if desired+ if ( special.preDispatch && special.preDispatch.call( this, event ) === false ) {+ return;+ }++ // Determine handlers+ handlerQueue = jQuery.event.handlers.call( this, event, handlers );++ // Run delegates first; they may want to stop propagation beneath us+ i = 0;+ while ( (matched = handlerQueue[ i++ ]) && !event.isPropagationStopped() ) {+ event.currentTarget = matched.elem;++ j = 0;+ while ( (handleObj = matched.handlers[ j++ ]) && !event.isImmediatePropagationStopped() ) {++ // Triggered event must either 1) have no namespace, or+ // 2) have namespace(s) a subset or equal to those in the bound event (both can have no namespace).+ if ( !event.namespace_re || event.namespace_re.test( handleObj.namespace ) ) {++ event.handleObj = handleObj;+ event.data = handleObj.data;++ ret = ( (jQuery.event.special[ handleObj.origType ] || {}).handle || handleObj.handler )+ .apply( matched.elem, args );++ if ( ret !== undefined ) {+ if ( (event.result = ret) === false ) {+ event.preventDefault();+ event.stopPropagation();+ }+ }+ }+ }+ }++ // Call the postDispatch hook for the mapped type+ if ( special.postDispatch ) {+ special.postDispatch.call( this, event );+ }++ return event.result;+ },++ handlers: function( event, handlers ) {+ var i, matches, sel, handleObj,+ handlerQueue = [],+ delegateCount = handlers.delegateCount,+ cur = event.target;++ // Find delegate handlers+ // Black-hole SVG <use> instance trees (#13180)+ // Avoid non-left-click bubbling in Firefox (#3861)+ if ( delegateCount && cur.nodeType && (!event.button || event.type !== "click") ) {++ for ( ; cur !== this; cur = cur.parentNode || this ) {++ // Don't process clicks on disabled elements (#6911, #8165, #11382, #11764)+ if ( cur.disabled !== true || event.type !== "click" ) {+ matches = [];+ for ( i = 0; i < delegateCount; i++ ) {+ handleObj = handlers[ i ];++ // Don't conflict with Object.prototype properties (#13203)+ sel = handleObj.selector + " ";++ if ( matches[ sel ] === undefined ) {+ matches[ sel ] = handleObj.needsContext ?+ jQuery( sel, this ).index( cur ) >= 0 :+ jQuery.find( sel, this, null, [ cur ] ).length;+ }+ if ( matches[ sel ] ) {+ matches.push( handleObj );+ }+ }+ if ( matches.length ) {+ handlerQueue.push({ elem: cur, handlers: matches });+ }+ }+ }+ }++ // Add the remaining (directly-bound) handlers+ if ( delegateCount < handlers.length ) {+ handlerQueue.push({ elem: this, handlers: handlers.slice( delegateCount ) });+ }++ return handlerQueue;+ },++ // Includes some event props shared by KeyEvent and MouseEvent+ props: "altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),++ fixHooks: {},++ keyHooks: {+ props: "char charCode key keyCode".split(" "),+ filter: function( event, original ) {++ // Add which for key events+ if ( event.which == null ) {+ event.which = original.charCode != null ? original.charCode : original.keyCode;+ }++ return event;+ }+ },++ mouseHooks: {+ props: "button buttons clientX clientY offsetX offsetY pageX pageY screenX screenY toElement".split(" "),+ filter: function( event, original ) {+ var eventDoc, doc, body,+ button = original.button;++ // Calculate pageX/Y if missing and clientX/Y available+ if ( event.pageX == null && original.clientX != null ) {+ eventDoc = event.target.ownerDocument || document;+ doc = eventDoc.documentElement;+ body = eventDoc.body;++ event.pageX = original.clientX + ( doc && doc.scrollLeft || body && body.scrollLeft || 0 ) - ( doc && doc.clientLeft || body && body.clientLeft || 0 );+ event.pageY = original.clientY + ( doc && doc.scrollTop || body && body.scrollTop || 0 ) - ( doc && doc.clientTop || body && body.clientTop || 0 );+ }++ // Add which for click: 1 === left; 2 === middle; 3 === right+ // Note: button is not normalized, so don't use it+ if ( !event.which && button !== undefined ) {+ event.which = ( button & 1 ? 1 : ( button & 2 ? 3 : ( button & 4 ? 2 : 0 ) ) );+ }++ return event;+ }+ },++ fix: function( event ) {+ if ( event[ jQuery.expando ] ) {+ return event;+ }++ // Create a writable copy of the event object and normalize some properties+ var i, prop, copy,+ type = event.type,+ originalEvent = event,+ fixHook = this.fixHooks[ type ];++ if ( !fixHook ) {+ this.fixHooks[ type ] = fixHook =+ rmouseEvent.test( type ) ? this.mouseHooks :+ rkeyEvent.test( type ) ? this.keyHooks :+ {};+ }+ copy = fixHook.props ? this.props.concat( fixHook.props ) : this.props;++ event = new jQuery.Event( originalEvent );++ i = copy.length;+ while ( i-- ) {+ prop = copy[ i ];+ event[ prop ] = originalEvent[ prop ];+ }++ // Support: Cordova 2.5 (WebKit) (#13255)+ // All events should have a target; Cordova deviceready doesn't+ if ( !event.target ) {+ event.target = document;+ }++ // Support: Safari 6.0+, Chrome < 28+ // Target should not be a text node (#504, #13143)+ if ( event.target.nodeType === 3 ) {+ event.target = event.target.parentNode;+ }++ return fixHook.filter ? fixHook.filter( event, originalEvent ) : event;+ },++ special: {+ load: {+ // Prevent triggered image.load events from bubbling to window.load+ noBubble: true+ },+ focus: {+ // Fire native event if possible so blur/focus sequence is correct+ trigger: function() {+ if ( this !== safeActiveElement() && this.focus ) {+ this.focus();+ return false;+ }+ },+ delegateType: "focusin"+ },+ blur: {+ trigger: function() {+ if ( this === safeActiveElement() && this.blur ) {+ this.blur();+ return false;+ }+ },+ delegateType: "focusout"+ },+ click: {+ // For checkbox, fire native event so checked state will be right+ trigger: function() {+ if ( this.type === "checkbox" && this.click && jQuery.nodeName( this, "input" ) ) {+ this.click();+ return false;+ }+ },++ // For cross-browser consistency, don't fire native .click() on links+ _default: function( event ) {+ return jQuery.nodeName( event.target, "a" );+ }+ },++ beforeunload: {+ postDispatch: function( event ) {++ // Support: Firefox 20++ // Firefox doesn't alert if the returnValue field is not set.+ if ( event.result !== undefined && event.originalEvent ) {+ event.originalEvent.returnValue = event.result;+ }+ }+ }+ },++ simulate: function( type, elem, event, bubble ) {+ // Piggyback on a donor event to simulate a different one.+ // Fake originalEvent to avoid donor's stopPropagation, but if the+ // simulated event prevents default then we do the same on the donor.+ var e = jQuery.extend(+ new jQuery.Event(),+ event,+ {+ type: type,+ isSimulated: true,+ originalEvent: {}+ }+ );+ if ( bubble ) {+ jQuery.event.trigger( e, null, elem );+ } else {+ jQuery.event.dispatch.call( elem, e );+ }+ if ( e.isDefaultPrevented() ) {+ event.preventDefault();+ }+ }+};++jQuery.removeEvent = function( elem, type, handle ) {+ if ( elem.removeEventListener ) {+ elem.removeEventListener( type, handle, false );+ }+};++jQuery.Event = function( src, props ) {+ // Allow instantiation without the 'new' keyword+ if ( !(this instanceof jQuery.Event) ) {+ return new jQuery.Event( src, props );+ }++ // Event object+ if ( src && src.type ) {+ this.originalEvent = src;+ this.type = src.type;++ // Events bubbling up the document may have been marked as prevented+ // by a handler lower down the tree; reflect the correct value.+ this.isDefaultPrevented = src.defaultPrevented ||+ src.defaultPrevented === undefined &&+ // Support: Android < 4.0+ src.returnValue === false ?+ returnTrue :+ returnFalse;++ // Event type+ } else {+ this.type = src;+ }++ // Put explicitly provided properties onto the event object+ if ( props ) {+ jQuery.extend( this, props );+ }++ // Create a timestamp if incoming event doesn't have one+ this.timeStamp = src && src.timeStamp || jQuery.now();++ // Mark it as fixed+ this[ jQuery.expando ] = true;+};++// jQuery.Event is based on DOM3 Events as specified by the ECMAScript Language Binding+// http://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/ecma-script-binding.html+jQuery.Event.prototype = {+ isDefaultPrevented: returnFalse,+ isPropagationStopped: returnFalse,+ isImmediatePropagationStopped: returnFalse,++ preventDefault: function() {+ var e = this.originalEvent;++ this.isDefaultPrevented = returnTrue;++ if ( e && e.preventDefault ) {+ e.preventDefault();+ }+ },+ stopPropagation: function() {+ var e = this.originalEvent;++ this.isPropagationStopped = returnTrue;++ if ( e && e.stopPropagation ) {+ e.stopPropagation();+ }+ },+ stopImmediatePropagation: function() {+ var e = this.originalEvent;++ this.isImmediatePropagationStopped = returnTrue;++ if ( e && e.stopImmediatePropagation ) {+ e.stopImmediatePropagation();+ }++ this.stopPropagation();+ }+};++// Create mouseenter/leave events using mouseover/out and event-time checks+// Support: Chrome 15++jQuery.each({+ mouseenter: "mouseover",+ mouseleave: "mouseout",+ pointerenter: "pointerover",+ pointerleave: "pointerout"+}, function( orig, fix ) {+ jQuery.event.special[ orig ] = {+ delegateType: fix,+ bindType: fix,++ handle: function( event ) {+ var ret,+ target = this,+ related = event.relatedTarget,+ handleObj = event.handleObj;++ // For mousenter/leave call the handler if related is outside the target.+ // NB: No relatedTarget if the mouse left/entered the browser window+ if ( !related || (related !== target && !jQuery.contains( target, related )) ) {+ event.type = handleObj.origType;+ ret = handleObj.handler.apply( this, arguments );+ event.type = fix;+ }+ return ret;+ }+ };+});++// Create "bubbling" focus and blur events+// Support: Firefox, Chrome, Safari+if ( !support.focusinBubbles ) {+ jQuery.each({ focus: "focusin", blur: "focusout" }, function( orig, fix ) {++ // Attach a single capturing handler on the document while someone wants focusin/focusout+ var handler = function( event ) {+ jQuery.event.simulate( fix, event.target, jQuery.event.fix( event ), true );+ };++ jQuery.event.special[ fix ] = {+ setup: function() {+ var doc = this.ownerDocument || this,+ attaches = data_priv.access( doc, fix );++ if ( !attaches ) {+ doc.addEventListener( orig, handler, true );+ }+ data_priv.access( doc, fix, ( attaches || 0 ) + 1 );+ },+ teardown: function() {+ var doc = this.ownerDocument || this,+ attaches = data_priv.access( doc, fix ) - 1;++ if ( !attaches ) {+ doc.removeEventListener( orig, handler, true );+ data_priv.remove( doc, fix );++ } else {+ data_priv.access( doc, fix, attaches );+ }+ }+ };+ });+}++jQuery.fn.extend({++ on: function( types, selector, data, fn, /*INTERNAL*/ one ) {+ var origFn, type;++ // Types can be a map of types/handlers+ if ( typeof types === "object" ) {+ // ( types-Object, selector, data )+ if ( typeof selector !== "string" ) {+ // ( types-Object, data )+ data = data || selector;+ selector = undefined;+ }+ for ( type in types ) {+ this.on( type, selector, data, types[ type ], one );+ }+ return this;+ }++ if ( data == null && fn == null ) {+ // ( types, fn )+ fn = selector;+ data = selector = undefined;+ } else if ( fn == null ) {+ if ( typeof selector === "string" ) {+ // ( types, selector, fn )+ fn = data;+ data = undefined;+ } else {+ // ( types, data, fn )+ fn = data;+ data = selector;+ selector = undefined;+ }+ }+ if ( fn === false ) {+ fn = returnFalse;+ } else if ( !fn ) {+ return this;+ }++ if ( one === 1 ) {+ origFn = fn;+ fn = function( event ) {+ // Can use an empty set, since event contains the info+ jQuery().off( event );+ return origFn.apply( this, arguments );+ };+ // Use same guid so caller can remove using origFn+ fn.guid = origFn.guid || ( origFn.guid = jQuery.guid++ );+ }+ return this.each( function() {+ jQuery.event.add( this, types, fn, data, selector );+ });+ },+ one: function( types, selector, data, fn ) {+ return this.on( types, selector, data, fn, 1 );+ },+ off: function( types, selector, fn ) {+ var handleObj, type;+ if ( types && types.preventDefault && types.handleObj ) {+ // ( event ) dispatched jQuery.Event+ handleObj = types.handleObj;+ jQuery( types.delegateTarget ).off(+ handleObj.namespace ? handleObj.origType + "." + handleObj.namespace : handleObj.origType,+ handleObj.selector,+ handleObj.handler+ );+ return this;+ }+ if ( typeof types === "object" ) {+ // ( types-object [, selector] )+ for ( type in types ) {+ this.off( type, selector, types[ type ] );+ }+ return this;+ }+ if ( selector === false || typeof selector === "function" ) {+ // ( types [, fn] )+ fn = selector;+ selector = undefined;+ }+ if ( fn === false ) {+ fn = returnFalse;+ }+ return this.each(function() {+ jQuery.event.remove( this, types, fn, selector );+ });+ },++ trigger: function( type, data ) {+ return this.each(function() {+ jQuery.event.trigger( type, data, this );+ });+ },+ triggerHandler: function( type, data ) {+ var elem = this[0];+ if ( elem ) {+ return jQuery.event.trigger( type, data, elem, true );+ }+ }+});+++var+ rxhtmlTag = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,+ rtagName = /<([\w:]+)/,+ rhtml = /<|&#?\w+;/,+ rnoInnerhtml = /<(?:script|style|link)/i,+ // checked="checked" or checked+ rchecked = /checked\s*(?:[^=]|=\s*.checked.)/i,+ rscriptType = /^$|\/(?:java|ecma)script/i,+ rscriptTypeMasked = /^true\/(.*)/,+ rcleanScript = /^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,++ // We have to close these tags to support XHTML (#13200)+ wrapMap = {++ // Support: IE 9+ option: [ 1, "<select multiple='multiple'>", "</select>" ],++ thead: [ 1, "<table>", "</table>" ],+ col: [ 2, "<table><colgroup>", "</colgroup></table>" ],+ tr: [ 2, "<table><tbody>", "</tbody></table>" ],+ td: [ 3, "<table><tbody><tr>", "</tr></tbody></table>" ],++ _default: [ 0, "", "" ]+ };++// Support: IE 9+wrapMap.optgroup = wrapMap.option;++wrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead;+wrapMap.th = wrapMap.td;++// Support: 1.x compatibility+// Manipulating tables requires a tbody+function manipulationTarget( elem, content ) {+ return jQuery.nodeName( elem, "table" ) &&+ jQuery.nodeName( content.nodeType !== 11 ? content : content.firstChild, "tr" ) ?++ elem.getElementsByTagName("tbody")[0] ||+ elem.appendChild( elem.ownerDocument.createElement("tbody") ) :+ elem;+}++// Replace/restore the type attribute of script elements for safe DOM manipulation+function disableScript( elem ) {+ elem.type = (elem.getAttribute("type") !== null) + "/" + elem.type;+ return elem;+}+function restoreScript( elem ) {+ var match = rscriptTypeMasked.exec( elem.type );++ if ( match ) {+ elem.type = match[ 1 ];+ } else {+ elem.removeAttribute("type");+ }++ return elem;+}++// Mark scripts as having already been evaluated+function setGlobalEval( elems, refElements ) {+ var i = 0,+ l = elems.length;++ for ( ; i < l; i++ ) {+ data_priv.set(+ elems[ i ], "globalEval", !refElements || data_priv.get( refElements[ i ], "globalEval" )+ );+ }+}++function cloneCopyEvent( src, dest ) {+ var i, l, type, pdataOld, pdataCur, udataOld, udataCur, events;++ if ( dest.nodeType !== 1 ) {+ return;+ }++ // 1. Copy private data: events, handlers, etc.+ if ( data_priv.hasData( src ) ) {+ pdataOld = data_priv.access( src );+ pdataCur = data_priv.set( dest, pdataOld );+ events = pdataOld.events;++ if ( events ) {+ delete pdataCur.handle;+ pdataCur.events = {};++ for ( type in events ) {+ for ( i = 0, l = events[ type ].length; i < l; i++ ) {+ jQuery.event.add( dest, type, events[ type ][ i ] );+ }+ }+ }+ }++ // 2. Copy user data+ if ( data_user.hasData( src ) ) {+ udataOld = data_user.access( src );+ udataCur = jQuery.extend( {}, udataOld );++ data_user.set( dest, udataCur );+ }+}++function getAll( context, tag ) {+ var ret = context.getElementsByTagName ? context.getElementsByTagName( tag || "*" ) :+ context.querySelectorAll ? context.querySelectorAll( tag || "*" ) :+ [];++ return tag === undefined || tag && jQuery.nodeName( context, tag ) ?+ jQuery.merge( [ context ], ret ) :+ ret;+}++// Support: IE >= 9+function fixInput( src, dest ) {+ var nodeName = dest.nodeName.toLowerCase();++ // Fails to persist the checked state of a cloned checkbox or radio button.+ if ( nodeName === "input" && rcheckableType.test( src.type ) ) {+ dest.checked = src.checked;++ // Fails to return the selected option to the default selected state when cloning options+ } else if ( nodeName === "input" || nodeName === "textarea" ) {+ dest.defaultValue = src.defaultValue;+ }+}++jQuery.extend({+ clone: function( elem, dataAndEvents, deepDataAndEvents ) {+ var i, l, srcElements, destElements,+ clone = elem.cloneNode( true ),+ inPage = jQuery.contains( elem.ownerDocument, elem );++ // Support: IE >= 9+ // Fix Cloning issues+ if ( !support.noCloneChecked && ( elem.nodeType === 1 || elem.nodeType === 11 ) &&+ !jQuery.isXMLDoc( elem ) ) {++ // We eschew Sizzle here for performance reasons: http://jsperf.com/getall-vs-sizzle/2+ destElements = getAll( clone );+ srcElements = getAll( elem );++ for ( i = 0, l = srcElements.length; i < l; i++ ) {+ fixInput( srcElements[ i ], destElements[ i ] );+ }+ }++ // Copy the events from the original to the clone+ if ( dataAndEvents ) {+ if ( deepDataAndEvents ) {+ srcElements = srcElements || getAll( elem );+ destElements = destElements || getAll( clone );++ for ( i = 0, l = srcElements.length; i < l; i++ ) {+ cloneCopyEvent( srcElements[ i ], destElements[ i ] );+ }+ } else {+ cloneCopyEvent( elem, clone );+ }+ }++ // Preserve script evaluation history+ destElements = getAll( clone, "script" );+ if ( destElements.length > 0 ) {+ setGlobalEval( destElements, !inPage && getAll( elem, "script" ) );+ }++ // Return the cloned set+ return clone;+ },++ buildFragment: function( elems, context, scripts, selection ) {+ var elem, tmp, tag, wrap, contains, j,+ fragment = context.createDocumentFragment(),+ nodes = [],+ i = 0,+ l = elems.length;++ for ( ; i < l; i++ ) {+ elem = elems[ i ];++ if ( elem || elem === 0 ) {++ // Add nodes directly+ if ( jQuery.type( elem ) === "object" ) {+ // Support: QtWebKit+ // jQuery.merge because push.apply(_, arraylike) throws+ jQuery.merge( nodes, elem.nodeType ? [ elem ] : elem );++ // Convert non-html into a text node+ } else if ( !rhtml.test( elem ) ) {+ nodes.push( context.createTextNode( elem ) );++ // Convert html into DOM nodes+ } else {+ tmp = tmp || fragment.appendChild( context.createElement("div") );++ // Deserialize a standard representation+ tag = ( rtagName.exec( elem ) || [ "", "" ] )[ 1 ].toLowerCase();+ wrap = wrapMap[ tag ] || wrapMap._default;+ tmp.innerHTML = wrap[ 1 ] + elem.replace( rxhtmlTag, "<$1></$2>" ) + wrap[ 2 ];++ // Descend through wrappers to the right content+ j = wrap[ 0 ];+ while ( j-- ) {+ tmp = tmp.lastChild;+ }++ // Support: QtWebKit+ // jQuery.merge because push.apply(_, arraylike) throws+ jQuery.merge( nodes, tmp.childNodes );++ // Remember the top-level container+ tmp = fragment.firstChild;++ // Fixes #12346+ // Support: Webkit, IE+ tmp.textContent = "";+ }+ }+ }++ // Remove wrapper from fragment+ fragment.textContent = "";++ i = 0;+ while ( (elem = nodes[ i++ ]) ) {++ // #4087 - If origin and destination elements are the same, and this is+ // that element, do not do anything+ if ( selection && jQuery.inArray( elem, selection ) !== -1 ) {+ continue;+ }++ contains = jQuery.contains( elem.ownerDocument, elem );++ // Append to fragment+ tmp = getAll( fragment.appendChild( elem ), "script" );++ // Preserve script evaluation history+ if ( contains ) {+ setGlobalEval( tmp );+ }++ // Capture executables+ if ( scripts ) {+ j = 0;+ while ( (elem = tmp[ j++ ]) ) {+ if ( rscriptType.test( elem.type || "" ) ) {+ scripts.push( elem );+ }+ }+ }+ }++ return fragment;+ },++ cleanData: function( elems ) {+ var data, elem, type, key,+ special = jQuery.event.special,+ i = 0;++ for ( ; (elem = elems[ i ]) !== undefined; i++ ) {+ if ( jQuery.acceptData( elem ) ) {+ key = elem[ data_priv.expando ];++ if ( key && (data = data_priv.cache[ key ]) ) {+ if ( data.events ) {+ for ( type in data.events ) {+ if ( special[ type ] ) {+ jQuery.event.remove( elem, type );++ // This is a shortcut to avoid jQuery.event.remove's overhead+ } else {+ jQuery.removeEvent( elem, type, data.handle );+ }+ }+ }+ if ( data_priv.cache[ key ] ) {+ // Discard any remaining `private` data+ delete data_priv.cache[ key ];+ }+ }+ }+ // Discard any remaining `user` data+ delete data_user.cache[ elem[ data_user.expando ] ];+ }+ }+});++jQuery.fn.extend({+ text: function( value ) {+ return access( this, function( value ) {+ return value === undefined ?+ jQuery.text( this ) :+ this.empty().each(function() {+ if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {+ this.textContent = value;+ }+ });+ }, null, value, arguments.length );+ },++ append: function() {+ return this.domManip( arguments, function( elem ) {+ if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {+ var target = manipulationTarget( this, elem );+ target.appendChild( elem );+ }+ });+ },++ prepend: function() {+ return this.domManip( arguments, function( elem ) {+ if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {+ var target = manipulationTarget( this, elem );+ target.insertBefore( elem, target.firstChild );+ }+ });+ },++ before: function() {+ return this.domManip( arguments, function( elem ) {+ if ( this.parentNode ) {+ this.parentNode.insertBefore( elem, this );+ }+ });+ },++ after: function() {+ return this.domManip( arguments, function( elem ) {+ if ( this.parentNode ) {+ this.parentNode.insertBefore( elem, this.nextSibling );+ }+ });+ },++ remove: function( selector, keepData /* Internal Use Only */ ) {+ var elem,+ elems = selector ? jQuery.filter( selector, this ) : this,+ i = 0;++ for ( ; (elem = elems[i]) != null; i++ ) {+ if ( !keepData && elem.nodeType === 1 ) {+ jQuery.cleanData( getAll( elem ) );+ }++ if ( elem.parentNode ) {+ if ( keepData && jQuery.contains( elem.ownerDocument, elem ) ) {+ setGlobalEval( getAll( elem, "script" ) );+ }+ elem.parentNode.removeChild( elem );+ }+ }++ return this;+ },++ empty: function() {+ var elem,+ i = 0;++ for ( ; (elem = this[i]) != null; i++ ) {+ if ( elem.nodeType === 1 ) {++ // Prevent memory leaks+ jQuery.cleanData( getAll( elem, false ) );++ // Remove any remaining nodes+ elem.textContent = "";+ }+ }++ return this;+ },++ clone: function( dataAndEvents, deepDataAndEvents ) {+ dataAndEvents = dataAndEvents == null ? false : dataAndEvents;+ deepDataAndEvents = deepDataAndEvents == null ? dataAndEvents : deepDataAndEvents;++ return this.map(function() {+ return jQuery.clone( this, dataAndEvents, deepDataAndEvents );+ });+ },++ html: function( value ) {+ return access( this, function( value ) {+ var elem = this[ 0 ] || {},+ i = 0,+ l = this.length;++ if ( value === undefined && elem.nodeType === 1 ) {+ return elem.innerHTML;+ }++ // See if we can take a shortcut and just use innerHTML+ if ( typeof value === "string" && !rnoInnerhtml.test( value ) &&+ !wrapMap[ ( rtagName.exec( value ) || [ "", "" ] )[ 1 ].toLowerCase() ] ) {++ value = value.replace( rxhtmlTag, "<$1></$2>" );++ try {+ for ( ; i < l; i++ ) {+ elem = this[ i ] || {};++ // Remove element nodes and prevent memory leaks+ if ( elem.nodeType === 1 ) {+ jQuery.cleanData( getAll( elem, false ) );+ elem.innerHTML = value;+ }+ }++ elem = 0;++ // If using innerHTML throws an exception, use the fallback method+ } catch( e ) {}+ }++ if ( elem ) {+ this.empty().append( value );+ }+ }, null, value, arguments.length );+ },++ replaceWith: function() {+ var arg = arguments[ 0 ];++ // Make the changes, replacing each context element with the new content+ this.domManip( arguments, function( elem ) {+ arg = this.parentNode;++ jQuery.cleanData( getAll( this ) );++ if ( arg ) {+ arg.replaceChild( elem, this );+ }+ });++ // Force removal if there was no new content (e.g., from empty arguments)+ return arg && (arg.length || arg.nodeType) ? this : this.remove();+ },++ detach: function( selector ) {+ return this.remove( selector, true );+ },++ domManip: function( args, callback ) {++ // Flatten any nested arrays+ args = concat.apply( [], args );++ var fragment, first, scripts, hasScripts, node, doc,+ i = 0,+ l = this.length,+ set = this,+ iNoClone = l - 1,+ value = args[ 0 ],+ isFunction = jQuery.isFunction( value );++ // We can't cloneNode fragments that contain checked, in WebKit+ if ( isFunction ||+ ( l > 1 && typeof value === "string" &&+ !support.checkClone && rchecked.test( value ) ) ) {+ return this.each(function( index ) {+ var self = set.eq( index );+ if ( isFunction ) {+ args[ 0 ] = value.call( this, index, self.html() );+ }+ self.domManip( args, callback );+ });+ }++ if ( l ) {+ fragment = jQuery.buildFragment( args, this[ 0 ].ownerDocument, false, this );+ first = fragment.firstChild;++ if ( fragment.childNodes.length === 1 ) {+ fragment = first;+ }++ if ( first ) {+ scripts = jQuery.map( getAll( fragment, "script" ), disableScript );+ hasScripts = scripts.length;++ // Use the original fragment for the last item instead of the first because it can end up+ // being emptied incorrectly in certain situations (#8070).+ for ( ; i < l; i++ ) {+ node = fragment;++ if ( i !== iNoClone ) {+ node = jQuery.clone( node, true, true );++ // Keep references to cloned scripts for later restoration+ if ( hasScripts ) {+ // Support: QtWebKit+ // jQuery.merge because push.apply(_, arraylike) throws+ jQuery.merge( scripts, getAll( node, "script" ) );+ }+ }++ callback.call( this[ i ], node, i );+ }++ if ( hasScripts ) {+ doc = scripts[ scripts.length - 1 ].ownerDocument;++ // Reenable scripts+ jQuery.map( scripts, restoreScript );++ // Evaluate executable scripts on first document insertion+ for ( i = 0; i < hasScripts; i++ ) {+ node = scripts[ i ];+ if ( rscriptType.test( node.type || "" ) &&+ !data_priv.access( node, "globalEval" ) && jQuery.contains( doc, node ) ) {++ if ( node.src ) {+ // Optional AJAX dependency, but won't run scripts if not present+ if ( jQuery._evalUrl ) {+ jQuery._evalUrl( node.src );+ }+ } else {+ jQuery.globalEval( node.textContent.replace( rcleanScript, "" ) );+ }+ }+ }+ }+ }+ }++ return this;+ }+});++jQuery.each({+ appendTo: "append",+ prependTo: "prepend",+ insertBefore: "before",+ insertAfter: "after",+ replaceAll: "replaceWith"+}, function( name, original ) {+ jQuery.fn[ name ] = function( selector ) {+ var elems,+ ret = [],+ insert = jQuery( selector ),+ last = insert.length - 1,+ i = 0;++ for ( ; i <= last; i++ ) {+ elems = i === last ? this : this.clone( true );+ jQuery( insert[ i ] )[ original ]( elems );++ // Support: QtWebKit+ // .get() because push.apply(_, arraylike) throws+ push.apply( ret, elems.get() );+ }++ return this.pushStack( ret );+ };+});+++var iframe,+ elemdisplay = {};++/**+ * Retrieve the actual display of a element+ * @param {String} name nodeName of the element+ * @param {Object} doc Document object+ */+// Called only from within defaultDisplay+function actualDisplay( name, doc ) {+ var style,+ elem = jQuery( doc.createElement( name ) ).appendTo( doc.body ),++ // getDefaultComputedStyle might be reliably used only on attached element+ display = window.getDefaultComputedStyle && ( style = window.getDefaultComputedStyle( elem[ 0 ] ) ) ?++ // Use of this method is a temporary fix (more like optmization) until something better comes along,+ // since it was removed from specification and supported only in FF+ style.display : jQuery.css( elem[ 0 ], "display" );++ // We don't have any data stored on the element,+ // so use "detach" method as fast way to get rid of the element+ elem.detach();++ return display;+}++/**+ * Try to determine the default display value of an element+ * @param {String} nodeName+ */+function defaultDisplay( nodeName ) {+ var doc = document,+ display = elemdisplay[ nodeName ];++ if ( !display ) {+ display = actualDisplay( nodeName, doc );++ // If the simple way fails, read from inside an iframe+ if ( display === "none" || !display ) {++ // Use the already-created iframe if possible+ iframe = (iframe || jQuery( "<iframe frameborder='0' width='0' height='0'/>" )).appendTo( doc.documentElement );++ // Always write a new HTML skeleton so Webkit and Firefox don't choke on reuse+ doc = iframe[ 0 ].contentDocument;++ // Support: IE+ doc.write();+ doc.close();++ display = actualDisplay( nodeName, doc );+ iframe.detach();+ }++ // Store the correct default display+ elemdisplay[ nodeName ] = display;+ }++ return display;+}+var rmargin = (/^margin/);++var rnumnonpx = new RegExp( "^(" + pnum + ")(?!px)[a-z%]+$", "i" );++var getStyles = function( elem ) {+ return elem.ownerDocument.defaultView.getComputedStyle( elem, null );+ };++++function curCSS( elem, name, computed ) {+ var width, minWidth, maxWidth, ret,+ style = elem.style;++ computed = computed || getStyles( elem );++ // Support: IE9+ // getPropertyValue is only needed for .css('filter') in IE9, see #12537+ if ( computed ) {+ ret = computed.getPropertyValue( name ) || computed[ name ];+ }++ if ( computed ) {++ if ( ret === "" && !jQuery.contains( elem.ownerDocument, elem ) ) {+ ret = jQuery.style( elem, name );+ }++ // Support: iOS < 6+ // A tribute to the "awesome hack by Dean Edwards"+ // iOS < 6 (at least) returns percentage for a larger set of values, but width seems to be reliably pixels+ // this is against the CSSOM draft spec: http://dev.w3.org/csswg/cssom/#resolved-values+ if ( rnumnonpx.test( ret ) && rmargin.test( name ) ) {++ // Remember the original values+ width = style.width;+ minWidth = style.minWidth;+ maxWidth = style.maxWidth;++ // Put in the new values to get a computed value out+ style.minWidth = style.maxWidth = style.width = ret;+ ret = computed.width;++ // Revert the changed values+ style.width = width;+ style.minWidth = minWidth;+ style.maxWidth = maxWidth;+ }+ }++ return ret !== undefined ?+ // Support: IE+ // IE returns zIndex value as an integer.+ ret + "" :+ ret;+}+++function addGetHookIf( conditionFn, hookFn ) {+ // Define the hook, we'll check on the first run if it's really needed.+ return {+ get: function() {+ if ( conditionFn() ) {+ // Hook not needed (or it's not possible to use it due to missing dependency),+ // remove it.+ // Since there are no other hooks for marginRight, remove the whole object.+ delete this.get;+ return;+ }++ // Hook needed; redefine it so that the support test is not executed again.++ return (this.get = hookFn).apply( this, arguments );+ }+ };+}+++(function() {+ var pixelPositionVal, boxSizingReliableVal,+ docElem = document.documentElement,+ container = document.createElement( "div" ),+ div = document.createElement( "div" );++ if ( !div.style ) {+ return;+ }++ div.style.backgroundClip = "content-box";+ div.cloneNode( true ).style.backgroundClip = "";+ support.clearCloneStyle = div.style.backgroundClip === "content-box";++ container.style.cssText = "border:0;width:0;height:0;top:0;left:-9999px;margin-top:1px;" ++ "position:absolute";+ container.appendChild( div );++ // Executing both pixelPosition & boxSizingReliable tests require only one layout+ // so they're executed at the same time to save the second computation.+ function computePixelPositionAndBoxSizingReliable() {+ div.style.cssText =+ // Support: Firefox<29, Android 2.3+ // Vendor-prefix box-sizing+ "-webkit-box-sizing:border-box;-moz-box-sizing:border-box;" ++ "box-sizing:border-box;display:block;margin-top:1%;top:1%;" ++ "border:1px;padding:1px;width:4px;position:absolute";+ div.innerHTML = "";+ docElem.appendChild( container );++ var divStyle = window.getComputedStyle( div, null );+ pixelPositionVal = divStyle.top !== "1%";+ boxSizingReliableVal = divStyle.width === "4px";++ docElem.removeChild( container );+ }++ // Support: node.js jsdom+ // Don't assume that getComputedStyle is a property of the global object+ if ( window.getComputedStyle ) {+ jQuery.extend( support, {+ pixelPosition: function() {+ // This test is executed only once but we still do memoizing+ // since we can use the boxSizingReliable pre-computing.+ // No need to check if the test was already performed, though.+ computePixelPositionAndBoxSizingReliable();+ return pixelPositionVal;+ },+ boxSizingReliable: function() {+ if ( boxSizingReliableVal == null ) {+ computePixelPositionAndBoxSizingReliable();+ }+ return boxSizingReliableVal;+ },+ reliableMarginRight: function() {+ // Support: Android 2.3+ // Check if div with explicit width and no margin-right incorrectly+ // gets computed margin-right based on width of container. (#3333)+ // WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right+ // This support function is only executed once so no memoizing is needed.+ var ret,+ marginDiv = div.appendChild( document.createElement( "div" ) );++ // Reset CSS: box-sizing; display; margin; border; padding+ marginDiv.style.cssText = div.style.cssText =+ // Support: Firefox<29, Android 2.3+ // Vendor-prefix box-sizing+ "-webkit-box-sizing:content-box;-moz-box-sizing:content-box;" ++ "box-sizing:content-box;display:block;margin:0;border:0;padding:0";+ marginDiv.style.marginRight = marginDiv.style.width = "0";+ div.style.width = "1px";+ docElem.appendChild( container );++ ret = !parseFloat( window.getComputedStyle( marginDiv, null ).marginRight );++ docElem.removeChild( container );++ return ret;+ }+ });+ }+})();+++// A method for quickly swapping in/out CSS properties to get correct calculations.+jQuery.swap = function( elem, options, callback, args ) {+ var ret, name,+ old = {};++ // Remember the old values, and insert the new ones+ for ( name in options ) {+ old[ name ] = elem.style[ name ];+ elem.style[ name ] = options[ name ];+ }++ ret = callback.apply( elem, args || [] );++ // Revert the old values+ for ( name in options ) {+ elem.style[ name ] = old[ name ];+ }++ return ret;+};+++var+ // swappable if display is none or starts with table except "table", "table-cell", or "table-caption"+ // see here for display values: https://developer.mozilla.org/en-US/docs/CSS/display+ rdisplayswap = /^(none|table(?!-c[ea]).+)/,+ rnumsplit = new RegExp( "^(" + pnum + ")(.*)$", "i" ),+ rrelNum = new RegExp( "^([+-])=(" + pnum + ")", "i" ),++ cssShow = { position: "absolute", visibility: "hidden", display: "block" },+ cssNormalTransform = {+ letterSpacing: "0",+ fontWeight: "400"+ },++ cssPrefixes = [ "Webkit", "O", "Moz", "ms" ];++// return a css property mapped to a potentially vendor prefixed property+function vendorPropName( style, name ) {++ // shortcut for names that are not vendor prefixed+ if ( name in style ) {+ return name;+ }++ // check for vendor prefixed names+ var capName = name[0].toUpperCase() + name.slice(1),+ origName = name,+ i = cssPrefixes.length;++ while ( i-- ) {+ name = cssPrefixes[ i ] + capName;+ if ( name in style ) {+ return name;+ }+ }++ return origName;+}++function setPositiveNumber( elem, value, subtract ) {+ var matches = rnumsplit.exec( value );+ return matches ?+ // Guard against undefined "subtract", e.g., when used as in cssHooks+ Math.max( 0, matches[ 1 ] - ( subtract || 0 ) ) + ( matches[ 2 ] || "px" ) :+ value;+}++function augmentWidthOrHeight( elem, name, extra, isBorderBox, styles ) {+ var i = extra === ( isBorderBox ? "border" : "content" ) ?+ // If we already have the right measurement, avoid augmentation+ 4 :+ // Otherwise initialize for horizontal or vertical properties+ name === "width" ? 1 : 0,++ val = 0;++ for ( ; i < 4; i += 2 ) {+ // both box models exclude margin, so add it if we want it+ if ( extra === "margin" ) {+ val += jQuery.css( elem, extra + cssExpand[ i ], true, styles );+ }++ if ( isBorderBox ) {+ // border-box includes padding, so remove it if we want content+ if ( extra === "content" ) {+ val -= jQuery.css( elem, "padding" + cssExpand[ i ], true, styles );+ }++ // at this point, extra isn't border nor margin, so remove border+ if ( extra !== "margin" ) {+ val -= jQuery.css( elem, "border" + cssExpand[ i ] + "Width", true, styles );+ }+ } else {+ // at this point, extra isn't content, so add padding+ val += jQuery.css( elem, "padding" + cssExpand[ i ], true, styles );++ // at this point, extra isn't content nor padding, so add border+ if ( extra !== "padding" ) {+ val += jQuery.css( elem, "border" + cssExpand[ i ] + "Width", true, styles );+ }+ }+ }++ return val;+}++function getWidthOrHeight( elem, name, extra ) {++ // Start with offset property, which is equivalent to the border-box value+ var valueIsBorderBox = true,+ val = name === "width" ? elem.offsetWidth : elem.offsetHeight,+ styles = getStyles( elem ),+ isBorderBox = jQuery.css( elem, "boxSizing", false, styles ) === "border-box";++ // some non-html elements return undefined for offsetWidth, so check for null/undefined+ // svg - https://bugzilla.mozilla.org/show_bug.cgi?id=649285+ // MathML - https://bugzilla.mozilla.org/show_bug.cgi?id=491668+ if ( val <= 0 || val == null ) {+ // Fall back to computed then uncomputed css if necessary+ val = curCSS( elem, name, styles );+ if ( val < 0 || val == null ) {+ val = elem.style[ name ];+ }++ // Computed unit is not pixels. Stop here and return.+ if ( rnumnonpx.test(val) ) {+ return val;+ }++ // we need the check for style in case a browser which returns unreliable values+ // for getComputedStyle silently falls back to the reliable elem.style+ valueIsBorderBox = isBorderBox &&+ ( support.boxSizingReliable() || val === elem.style[ name ] );++ // Normalize "", auto, and prepare for extra+ val = parseFloat( val ) || 0;+ }++ // use the active box-sizing model to add/subtract irrelevant styles+ return ( val ++ augmentWidthOrHeight(+ elem,+ name,+ extra || ( isBorderBox ? "border" : "content" ),+ valueIsBorderBox,+ styles+ )+ ) + "px";+}++function showHide( elements, show ) {+ var display, elem, hidden,+ values = [],+ index = 0,+ length = elements.length;++ for ( ; index < length; index++ ) {+ elem = elements[ index ];+ if ( !elem.style ) {+ continue;+ }++ values[ index ] = data_priv.get( elem, "olddisplay" );+ display = elem.style.display;+ if ( show ) {+ // Reset the inline display of this element to learn if it is+ // being hidden by cascaded rules or not+ if ( !values[ index ] && display === "none" ) {+ elem.style.display = "";+ }++ // Set elements which have been overridden with display: none+ // in a stylesheet to whatever the default browser style is+ // for such an element+ if ( elem.style.display === "" && isHidden( elem ) ) {+ values[ index ] = data_priv.access( elem, "olddisplay", defaultDisplay(elem.nodeName) );+ }+ } else {+ hidden = isHidden( elem );++ if ( display !== "none" || !hidden ) {+ data_priv.set( elem, "olddisplay", hidden ? display : jQuery.css( elem, "display" ) );+ }+ }+ }++ // Set the display of most of the elements in a second loop+ // to avoid the constant reflow+ for ( index = 0; index < length; index++ ) {+ elem = elements[ index ];+ if ( !elem.style ) {+ continue;+ }+ if ( !show || elem.style.display === "none" || elem.style.display === "" ) {+ elem.style.display = show ? values[ index ] || "" : "none";+ }+ }++ return elements;+}++jQuery.extend({+ // Add in style property hooks for overriding the default+ // behavior of getting and setting a style property+ cssHooks: {+ opacity: {+ get: function( elem, computed ) {+ if ( computed ) {+ // We should always get a number back from opacity+ var ret = curCSS( elem, "opacity" );+ return ret === "" ? "1" : ret;+ }+ }+ }+ },++ // Don't automatically add "px" to these possibly-unitless properties+ cssNumber: {+ "columnCount": true,+ "fillOpacity": true,+ "flexGrow": true,+ "flexShrink": true,+ "fontWeight": true,+ "lineHeight": true,+ "opacity": true,+ "order": true,+ "orphans": true,+ "widows": true,+ "zIndex": true,+ "zoom": true+ },++ // Add in properties whose names you wish to fix before+ // setting or getting the value+ cssProps: {+ // normalize float css property+ "float": "cssFloat"+ },++ // Get and set the style property on a DOM Node+ style: function( elem, name, value, extra ) {+ // Don't set styles on text and comment nodes+ if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 || !elem.style ) {+ return;+ }++ // Make sure that we're working with the right name+ var ret, type, hooks,+ origName = jQuery.camelCase( name ),+ style = elem.style;++ name = jQuery.cssProps[ origName ] || ( jQuery.cssProps[ origName ] = vendorPropName( style, origName ) );++ // gets hook for the prefixed version+ // followed by the unprefixed version+ hooks = jQuery.cssHooks[ name ] || jQuery.cssHooks[ origName ];++ // Check if we're setting a value+ if ( value !== undefined ) {+ type = typeof value;++ // convert relative number strings (+= or -=) to relative numbers. #7345+ if ( type === "string" && (ret = rrelNum.exec( value )) ) {+ value = ( ret[1] + 1 ) * ret[2] + parseFloat( jQuery.css( elem, name ) );+ // Fixes bug #9237+ type = "number";+ }++ // Make sure that null and NaN values aren't set. See: #7116+ if ( value == null || value !== value ) {+ return;+ }++ // If a number was passed in, add 'px' to the (except for certain CSS properties)+ if ( type === "number" && !jQuery.cssNumber[ origName ] ) {+ value += "px";+ }++ // Fixes #8908, it can be done more correctly by specifying setters in cssHooks,+ // but it would mean to define eight (for every problematic property) identical functions+ if ( !support.clearCloneStyle && value === "" && name.indexOf( "background" ) === 0 ) {+ style[ name ] = "inherit";+ }++ // If a hook was provided, use that value, otherwise just set the specified value+ if ( !hooks || !("set" in hooks) || (value = hooks.set( elem, value, extra )) !== undefined ) {+ style[ name ] = value;+ }++ } else {+ // If a hook was provided get the non-computed value from there+ if ( hooks && "get" in hooks && (ret = hooks.get( elem, false, extra )) !== undefined ) {+ return ret;+ }++ // Otherwise just get the value from the style object+ return style[ name ];+ }+ },++ css: function( elem, name, extra, styles ) {+ var val, num, hooks,+ origName = jQuery.camelCase( name );++ // Make sure that we're working with the right name+ name = jQuery.cssProps[ origName ] || ( jQuery.cssProps[ origName ] = vendorPropName( elem.style, origName ) );++ // gets hook for the prefixed version+ // followed by the unprefixed version+ hooks = jQuery.cssHooks[ name ] || jQuery.cssHooks[ origName ];++ // If a hook was provided get the computed value from there+ if ( hooks && "get" in hooks ) {+ val = hooks.get( elem, true, extra );+ }++ // Otherwise, if a way to get the computed value exists, use that+ if ( val === undefined ) {+ val = curCSS( elem, name, styles );+ }++ //convert "normal" to computed value+ if ( val === "normal" && name in cssNormalTransform ) {+ val = cssNormalTransform[ name ];+ }++ // Return, converting to number if forced or a qualifier was provided and val looks numeric+ if ( extra === "" || extra ) {+ num = parseFloat( val );+ return extra === true || jQuery.isNumeric( num ) ? num || 0 : val;+ }+ return val;+ }+});++jQuery.each([ "height", "width" ], function( i, name ) {+ jQuery.cssHooks[ name ] = {+ get: function( elem, computed, extra ) {+ if ( computed ) {+ // certain elements can have dimension info if we invisibly show them+ // however, it must have a current display style that would benefit from this+ return rdisplayswap.test( jQuery.css( elem, "display" ) ) && elem.offsetWidth === 0 ?+ jQuery.swap( elem, cssShow, function() {+ return getWidthOrHeight( elem, name, extra );+ }) :+ getWidthOrHeight( elem, name, extra );+ }+ },++ set: function( elem, value, extra ) {+ var styles = extra && getStyles( elem );+ return setPositiveNumber( elem, value, extra ?+ augmentWidthOrHeight(+ elem,+ name,+ extra,+ jQuery.css( elem, "boxSizing", false, styles ) === "border-box",+ styles+ ) : 0+ );+ }+ };+});++// Support: Android 2.3+jQuery.cssHooks.marginRight = addGetHookIf( support.reliableMarginRight,+ function( elem, computed ) {+ if ( computed ) {+ // WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right+ // Work around by temporarily setting element display to inline-block+ return jQuery.swap( elem, { "display": "inline-block" },+ curCSS, [ elem, "marginRight" ] );+ }+ }+);++// These hooks are used by animate to expand properties+jQuery.each({+ margin: "",+ padding: "",+ border: "Width"+}, function( prefix, suffix ) {+ jQuery.cssHooks[ prefix + suffix ] = {+ expand: function( value ) {+ var i = 0,+ expanded = {},++ // assumes a single number if not a string+ parts = typeof value === "string" ? value.split(" ") : [ value ];++ for ( ; i < 4; i++ ) {+ expanded[ prefix + cssExpand[ i ] + suffix ] =+ parts[ i ] || parts[ i - 2 ] || parts[ 0 ];+ }++ return expanded;+ }+ };++ if ( !rmargin.test( prefix ) ) {+ jQuery.cssHooks[ prefix + suffix ].set = setPositiveNumber;+ }+});++jQuery.fn.extend({+ css: function( name, value ) {+ return access( this, function( elem, name, value ) {+ var styles, len,+ map = {},+ i = 0;++ if ( jQuery.isArray( name ) ) {+ styles = getStyles( elem );+ len = name.length;++ for ( ; i < len; i++ ) {+ map[ name[ i ] ] = jQuery.css( elem, name[ i ], false, styles );+ }++ return map;+ }++ return value !== undefined ?+ jQuery.style( elem, name, value ) :+ jQuery.css( elem, name );+ }, name, value, arguments.length > 1 );+ },+ show: function() {+ return showHide( this, true );+ },+ hide: function() {+ return showHide( this );+ },+ toggle: function( state ) {+ if ( typeof state === "boolean" ) {+ return state ? this.show() : this.hide();+ }++ return this.each(function() {+ if ( isHidden( this ) ) {+ jQuery( this ).show();+ } else {+ jQuery( this ).hide();+ }+ });+ }+});+++function Tween( elem, options, prop, end, easing ) {+ return new Tween.prototype.init( elem, options, prop, end, easing );+}+jQuery.Tween = Tween;++Tween.prototype = {+ constructor: Tween,+ init: function( elem, options, prop, end, easing, unit ) {+ this.elem = elem;+ this.prop = prop;+ this.easing = easing || "swing";+ this.options = options;+ this.start = this.now = this.cur();+ this.end = end;+ this.unit = unit || ( jQuery.cssNumber[ prop ] ? "" : "px" );+ },+ cur: function() {+ var hooks = Tween.propHooks[ this.prop ];++ return hooks && hooks.get ?+ hooks.get( this ) :+ Tween.propHooks._default.get( this );+ },+ run: function( percent ) {+ var eased,+ hooks = Tween.propHooks[ this.prop ];++ if ( this.options.duration ) {+ this.pos = eased = jQuery.easing[ this.easing ](+ percent, this.options.duration * percent, 0, 1, this.options.duration+ );+ } else {+ this.pos = eased = percent;+ }+ this.now = ( this.end - this.start ) * eased + this.start;++ if ( this.options.step ) {+ this.options.step.call( this.elem, this.now, this );+ }++ if ( hooks && hooks.set ) {+ hooks.set( this );+ } else {+ Tween.propHooks._default.set( this );+ }+ return this;+ }+};++Tween.prototype.init.prototype = Tween.prototype;++Tween.propHooks = {+ _default: {+ get: function( tween ) {+ var result;++ if ( tween.elem[ tween.prop ] != null &&+ (!tween.elem.style || tween.elem.style[ tween.prop ] == null) ) {+ return tween.elem[ tween.prop ];+ }++ // passing an empty string as a 3rd parameter to .css will automatically+ // attempt a parseFloat and fallback to a string if the parse fails+ // so, simple values such as "10px" are parsed to Float.+ // complex values such as "rotate(1rad)" are returned as is.+ result = jQuery.css( tween.elem, tween.prop, "" );+ // Empty strings, null, undefined and "auto" are converted to 0.+ return !result || result === "auto" ? 0 : result;+ },+ set: function( tween ) {+ // use step hook for back compat - use cssHook if its there - use .style if its+ // available and use plain properties where available+ if ( jQuery.fx.step[ tween.prop ] ) {+ jQuery.fx.step[ tween.prop ]( tween );+ } else if ( tween.elem.style && ( tween.elem.style[ jQuery.cssProps[ tween.prop ] ] != null || jQuery.cssHooks[ tween.prop ] ) ) {+ jQuery.style( tween.elem, tween.prop, tween.now + tween.unit );+ } else {+ tween.elem[ tween.prop ] = tween.now;+ }+ }+ }+};++// Support: IE9+// Panic based approach to setting things on disconnected nodes++Tween.propHooks.scrollTop = Tween.propHooks.scrollLeft = {+ set: function( tween ) {+ if ( tween.elem.nodeType && tween.elem.parentNode ) {+ tween.elem[ tween.prop ] = tween.now;+ }+ }+};++jQuery.easing = {+ linear: function( p ) {+ return p;+ },+ swing: function( p ) {+ return 0.5 - Math.cos( p * Math.PI ) / 2;+ }+};++jQuery.fx = Tween.prototype.init;++// Back Compat <1.8 extension point+jQuery.fx.step = {};+++++var+ fxNow, timerId,+ rfxtypes = /^(?:toggle|show|hide)$/,+ rfxnum = new RegExp( "^(?:([+-])=|)(" + pnum + ")([a-z%]*)$", "i" ),+ rrun = /queueHooks$/,+ animationPrefilters = [ defaultPrefilter ],+ tweeners = {+ "*": [ function( prop, value ) {+ var tween = this.createTween( prop, value ),+ target = tween.cur(),+ parts = rfxnum.exec( value ),+ unit = parts && parts[ 3 ] || ( jQuery.cssNumber[ prop ] ? "" : "px" ),++ // Starting value computation is required for potential unit mismatches+ start = ( jQuery.cssNumber[ prop ] || unit !== "px" && +target ) &&+ rfxnum.exec( jQuery.css( tween.elem, prop ) ),+ scale = 1,+ maxIterations = 20;++ if ( start && start[ 3 ] !== unit ) {+ // Trust units reported by jQuery.css+ unit = unit || start[ 3 ];++ // Make sure we update the tween properties later on+ parts = parts || [];++ // Iteratively approximate from a nonzero starting point+ start = +target || 1;++ do {+ // If previous iteration zeroed out, double until we get *something*+ // Use a string for doubling factor so we don't accidentally see scale as unchanged below+ scale = scale || ".5";++ // Adjust and apply+ start = start / scale;+ jQuery.style( tween.elem, prop, start + unit );++ // Update scale, tolerating zero or NaN from tween.cur()+ // And breaking the loop if scale is unchanged or perfect, or if we've just had enough+ } while ( scale !== (scale = tween.cur() / target) && scale !== 1 && --maxIterations );+ }++ // Update tween properties+ if ( parts ) {+ start = tween.start = +start || +target || 0;+ tween.unit = unit;+ // If a +=/-= token was provided, we're doing a relative animation+ tween.end = parts[ 1 ] ?+ start + ( parts[ 1 ] + 1 ) * parts[ 2 ] :+ +parts[ 2 ];+ }++ return tween;+ } ]+ };++// Animations created synchronously will run synchronously+function createFxNow() {+ setTimeout(function() {+ fxNow = undefined;+ });+ return ( fxNow = jQuery.now() );+}++// Generate parameters to create a standard animation+function genFx( type, includeWidth ) {+ var which,+ i = 0,+ attrs = { height: type };++ // if we include width, step value is 1 to do all cssExpand values,+ // if we don't include width, step value is 2 to skip over Left and Right+ includeWidth = includeWidth ? 1 : 0;+ for ( ; i < 4 ; i += 2 - includeWidth ) {+ which = cssExpand[ i ];+ attrs[ "margin" + which ] = attrs[ "padding" + which ] = type;+ }++ if ( includeWidth ) {+ attrs.opacity = attrs.width = type;+ }++ return attrs;+}++function createTween( value, prop, animation ) {+ var tween,+ collection = ( tweeners[ prop ] || [] ).concat( tweeners[ "*" ] ),+ index = 0,+ length = collection.length;+ for ( ; index < length; index++ ) {+ if ( (tween = collection[ index ].call( animation, prop, value )) ) {++ // we're done with this property+ return tween;+ }+ }+}++function defaultPrefilter( elem, props, opts ) {+ /* jshint validthis: true */+ var prop, value, toggle, tween, hooks, oldfire, display, checkDisplay,+ anim = this,+ orig = {},+ style = elem.style,+ hidden = elem.nodeType && isHidden( elem ),+ dataShow = data_priv.get( elem, "fxshow" );++ // handle queue: false promises+ if ( !opts.queue ) {+ hooks = jQuery._queueHooks( elem, "fx" );+ if ( hooks.unqueued == null ) {+ hooks.unqueued = 0;+ oldfire = hooks.empty.fire;+ hooks.empty.fire = function() {+ if ( !hooks.unqueued ) {+ oldfire();+ }+ };+ }+ hooks.unqueued++;++ anim.always(function() {+ // doing this makes sure that the complete handler will be called+ // before this completes+ anim.always(function() {+ hooks.unqueued--;+ if ( !jQuery.queue( elem, "fx" ).length ) {+ hooks.empty.fire();+ }+ });+ });+ }++ // height/width overflow pass+ if ( elem.nodeType === 1 && ( "height" in props || "width" in props ) ) {+ // Make sure that nothing sneaks out+ // Record all 3 overflow attributes because IE9-10 do not+ // change the overflow attribute when overflowX and+ // overflowY are set to the same value+ opts.overflow = [ style.overflow, style.overflowX, style.overflowY ];++ // Set display property to inline-block for height/width+ // animations on inline elements that are having width/height animated+ display = jQuery.css( elem, "display" );++ // Test default display if display is currently "none"+ checkDisplay = display === "none" ?+ data_priv.get( elem, "olddisplay" ) || defaultDisplay( elem.nodeName ) : display;++ if ( checkDisplay === "inline" && jQuery.css( elem, "float" ) === "none" ) {+ style.display = "inline-block";+ }+ }++ if ( opts.overflow ) {+ style.overflow = "hidden";+ anim.always(function() {+ style.overflow = opts.overflow[ 0 ];+ style.overflowX = opts.overflow[ 1 ];+ style.overflowY = opts.overflow[ 2 ];+ });+ }++ // show/hide pass+ for ( prop in props ) {+ value = props[ prop ];+ if ( rfxtypes.exec( value ) ) {+ delete props[ prop ];+ toggle = toggle || value === "toggle";+ if ( value === ( hidden ? "hide" : "show" ) ) {++ // If there is dataShow left over from a stopped hide or show and we are going to proceed with show, we should pretend to be hidden+ if ( value === "show" && dataShow && dataShow[ prop ] !== undefined ) {+ hidden = true;+ } else {+ continue;+ }+ }+ orig[ prop ] = dataShow && dataShow[ prop ] || jQuery.style( elem, prop );++ // Any non-fx value stops us from restoring the original display value+ } else {+ display = undefined;+ }+ }++ if ( !jQuery.isEmptyObject( orig ) ) {+ if ( dataShow ) {+ if ( "hidden" in dataShow ) {+ hidden = dataShow.hidden;+ }+ } else {+ dataShow = data_priv.access( elem, "fxshow", {} );+ }++ // store state if its toggle - enables .stop().toggle() to "reverse"+ if ( toggle ) {+ dataShow.hidden = !hidden;+ }+ if ( hidden ) {+ jQuery( elem ).show();+ } else {+ anim.done(function() {+ jQuery( elem ).hide();+ });+ }+ anim.done(function() {+ var prop;++ data_priv.remove( elem, "fxshow" );+ for ( prop in orig ) {+ jQuery.style( elem, prop, orig[ prop ] );+ }+ });+ for ( prop in orig ) {+ tween = createTween( hidden ? dataShow[ prop ] : 0, prop, anim );++ if ( !( prop in dataShow ) ) {+ dataShow[ prop ] = tween.start;+ if ( hidden ) {+ tween.end = tween.start;+ tween.start = prop === "width" || prop === "height" ? 1 : 0;+ }+ }+ }++ // If this is a noop like .hide().hide(), restore an overwritten display value+ } else if ( (display === "none" ? defaultDisplay( elem.nodeName ) : display) === "inline" ) {+ style.display = display;+ }+}++function propFilter( props, specialEasing ) {+ var index, name, easing, value, hooks;++ // camelCase, specialEasing and expand cssHook pass+ for ( index in props ) {+ name = jQuery.camelCase( index );+ easing = specialEasing[ name ];+ value = props[ index ];+ if ( jQuery.isArray( value ) ) {+ easing = value[ 1 ];+ value = props[ index ] = value[ 0 ];+ }++ if ( index !== name ) {+ props[ name ] = value;+ delete props[ index ];+ }++ hooks = jQuery.cssHooks[ name ];+ if ( hooks && "expand" in hooks ) {+ value = hooks.expand( value );+ delete props[ name ];++ // not quite $.extend, this wont overwrite keys already present.+ // also - reusing 'index' from above because we have the correct "name"+ for ( index in value ) {+ if ( !( index in props ) ) {+ props[ index ] = value[ index ];+ specialEasing[ index ] = easing;+ }+ }+ } else {+ specialEasing[ name ] = easing;+ }+ }+}++function Animation( elem, properties, options ) {+ var result,+ stopped,+ index = 0,+ length = animationPrefilters.length,+ deferred = jQuery.Deferred().always( function() {+ // don't match elem in the :animated selector+ delete tick.elem;+ }),+ tick = function() {+ if ( stopped ) {+ return false;+ }+ var currentTime = fxNow || createFxNow(),+ remaining = Math.max( 0, animation.startTime + animation.duration - currentTime ),+ // archaic crash bug won't allow us to use 1 - ( 0.5 || 0 ) (#12497)+ temp = remaining / animation.duration || 0,+ percent = 1 - temp,+ index = 0,+ length = animation.tweens.length;++ for ( ; index < length ; index++ ) {+ animation.tweens[ index ].run( percent );+ }++ deferred.notifyWith( elem, [ animation, percent, remaining ]);++ if ( percent < 1 && length ) {+ return remaining;+ } else {+ deferred.resolveWith( elem, [ animation ] );+ return false;+ }+ },+ animation = deferred.promise({+ elem: elem,+ props: jQuery.extend( {}, properties ),+ opts: jQuery.extend( true, { specialEasing: {} }, options ),+ originalProperties: properties,+ originalOptions: options,+ startTime: fxNow || createFxNow(),+ duration: options.duration,+ tweens: [],+ createTween: function( prop, end ) {+ var tween = jQuery.Tween( elem, animation.opts, prop, end,+ animation.opts.specialEasing[ prop ] || animation.opts.easing );+ animation.tweens.push( tween );+ return tween;+ },+ stop: function( gotoEnd ) {+ var index = 0,+ // if we are going to the end, we want to run all the tweens+ // otherwise we skip this part+ length = gotoEnd ? animation.tweens.length : 0;+ if ( stopped ) {+ return this;+ }+ stopped = true;+ for ( ; index < length ; index++ ) {+ animation.tweens[ index ].run( 1 );+ }++ // resolve when we played the last frame+ // otherwise, reject+ if ( gotoEnd ) {+ deferred.resolveWith( elem, [ animation, gotoEnd ] );+ } else {+ deferred.rejectWith( elem, [ animation, gotoEnd ] );+ }+ return this;+ }+ }),+ props = animation.props;++ propFilter( props, animation.opts.specialEasing );++ for ( ; index < length ; index++ ) {+ result = animationPrefilters[ index ].call( animation, elem, props, animation.opts );+ if ( result ) {+ return result;+ }+ }++ jQuery.map( props, createTween, animation );++ if ( jQuery.isFunction( animation.opts.start ) ) {+ animation.opts.start.call( elem, animation );+ }++ jQuery.fx.timer(+ jQuery.extend( tick, {+ elem: elem,+ anim: animation,+ queue: animation.opts.queue+ })+ );++ // attach callbacks from options+ return animation.progress( animation.opts.progress )+ .done( animation.opts.done, animation.opts.complete )+ .fail( animation.opts.fail )+ .always( animation.opts.always );+}++jQuery.Animation = jQuery.extend( Animation, {++ tweener: function( props, callback ) {+ if ( jQuery.isFunction( props ) ) {+ callback = props;+ props = [ "*" ];+ } else {+ props = props.split(" ");+ }++ var prop,+ index = 0,+ length = props.length;++ for ( ; index < length ; index++ ) {+ prop = props[ index ];+ tweeners[ prop ] = tweeners[ prop ] || [];+ tweeners[ prop ].unshift( callback );+ }+ },++ prefilter: function( callback, prepend ) {+ if ( prepend ) {+ animationPrefilters.unshift( callback );+ } else {+ animationPrefilters.push( callback );+ }+ }+});++jQuery.speed = function( speed, easing, fn ) {+ var opt = speed && typeof speed === "object" ? jQuery.extend( {}, speed ) : {+ complete: fn || !fn && easing ||+ jQuery.isFunction( speed ) && speed,+ duration: speed,+ easing: fn && easing || easing && !jQuery.isFunction( easing ) && easing+ };++ opt.duration = jQuery.fx.off ? 0 : typeof opt.duration === "number" ? opt.duration :+ opt.duration in jQuery.fx.speeds ? jQuery.fx.speeds[ opt.duration ] : jQuery.fx.speeds._default;++ // normalize opt.queue - true/undefined/null -> "fx"+ if ( opt.queue == null || opt.queue === true ) {+ opt.queue = "fx";+ }++ // Queueing+ opt.old = opt.complete;++ opt.complete = function() {+ if ( jQuery.isFunction( opt.old ) ) {+ opt.old.call( this );+ }++ if ( opt.queue ) {+ jQuery.dequeue( this, opt.queue );+ }+ };++ return opt;+};++jQuery.fn.extend({+ fadeTo: function( speed, to, easing, callback ) {++ // show any hidden elements after setting opacity to 0+ return this.filter( isHidden ).css( "opacity", 0 ).show()++ // animate to the value specified+ .end().animate({ opacity: to }, speed, easing, callback );+ },+ animate: function( prop, speed, easing, callback ) {+ var empty = jQuery.isEmptyObject( prop ),+ optall = jQuery.speed( speed, easing, callback ),+ doAnimation = function() {+ // Operate on a copy of prop so per-property easing won't be lost+ var anim = Animation( this, jQuery.extend( {}, prop ), optall );++ // Empty animations, or finishing resolves immediately+ if ( empty || data_priv.get( this, "finish" ) ) {+ anim.stop( true );+ }+ };+ doAnimation.finish = doAnimation;++ return empty || optall.queue === false ?+ this.each( doAnimation ) :+ this.queue( optall.queue, doAnimation );+ },+ stop: function( type, clearQueue, gotoEnd ) {+ var stopQueue = function( hooks ) {+ var stop = hooks.stop;+ delete hooks.stop;+ stop( gotoEnd );+ };++ if ( typeof type !== "string" ) {+ gotoEnd = clearQueue;+ clearQueue = type;+ type = undefined;+ }+ if ( clearQueue && type !== false ) {+ this.queue( type || "fx", [] );+ }++ return this.each(function() {+ var dequeue = true,+ index = type != null && type + "queueHooks",+ timers = jQuery.timers,+ data = data_priv.get( this );++ if ( index ) {+ if ( data[ index ] && data[ index ].stop ) {+ stopQueue( data[ index ] );+ }+ } else {+ for ( index in data ) {+ if ( data[ index ] && data[ index ].stop && rrun.test( index ) ) {+ stopQueue( data[ index ] );+ }+ }+ }++ for ( index = timers.length; index--; ) {+ if ( timers[ index ].elem === this && (type == null || timers[ index ].queue === type) ) {+ timers[ index ].anim.stop( gotoEnd );+ dequeue = false;+ timers.splice( index, 1 );+ }+ }++ // start the next in the queue if the last step wasn't forced+ // timers currently will call their complete callbacks, which will dequeue+ // but only if they were gotoEnd+ if ( dequeue || !gotoEnd ) {+ jQuery.dequeue( this, type );+ }+ });+ },+ finish: function( type ) {+ if ( type !== false ) {+ type = type || "fx";+ }+ return this.each(function() {+ var index,+ data = data_priv.get( this ),+ queue = data[ type + "queue" ],+ hooks = data[ type + "queueHooks" ],+ timers = jQuery.timers,+ length = queue ? queue.length : 0;++ // enable finishing flag on private data+ data.finish = true;++ // empty the queue first+ jQuery.queue( this, type, [] );++ if ( hooks && hooks.stop ) {+ hooks.stop.call( this, true );+ }++ // look for any active animations, and finish them+ for ( index = timers.length; index--; ) {+ if ( timers[ index ].elem === this && timers[ index ].queue === type ) {+ timers[ index ].anim.stop( true );+ timers.splice( index, 1 );+ }+ }++ // look for any animations in the old queue and finish them+ for ( index = 0; index < length; index++ ) {+ if ( queue[ index ] && queue[ index ].finish ) {+ queue[ index ].finish.call( this );+ }+ }++ // turn off finishing flag+ delete data.finish;+ });+ }+});++jQuery.each([ "toggle", "show", "hide" ], function( i, name ) {+ var cssFn = jQuery.fn[ name ];+ jQuery.fn[ name ] = function( speed, easing, callback ) {+ return speed == null || typeof speed === "boolean" ?+ cssFn.apply( this, arguments ) :+ this.animate( genFx( name, true ), speed, easing, callback );+ };+});++// Generate shortcuts for custom animations+jQuery.each({+ slideDown: genFx("show"),+ slideUp: genFx("hide"),+ slideToggle: genFx("toggle"),+ fadeIn: { opacity: "show" },+ fadeOut: { opacity: "hide" },+ fadeToggle: { opacity: "toggle" }+}, function( name, props ) {+ jQuery.fn[ name ] = function( speed, easing, callback ) {+ return this.animate( props, speed, easing, callback );+ };+});++jQuery.timers = [];+jQuery.fx.tick = function() {+ var timer,+ i = 0,+ timers = jQuery.timers;++ fxNow = jQuery.now();++ for ( ; i < timers.length; i++ ) {+ timer = timers[ i ];+ // Checks the timer has not already been removed+ if ( !timer() && timers[ i ] === timer ) {+ timers.splice( i--, 1 );+ }+ }++ if ( !timers.length ) {+ jQuery.fx.stop();+ }+ fxNow = undefined;+};++jQuery.fx.timer = function( timer ) {+ jQuery.timers.push( timer );+ if ( timer() ) {+ jQuery.fx.start();+ } else {+ jQuery.timers.pop();+ }+};++jQuery.fx.interval = 13;++jQuery.fx.start = function() {+ if ( !timerId ) {+ timerId = setInterval( jQuery.fx.tick, jQuery.fx.interval );+ }+};++jQuery.fx.stop = function() {+ clearInterval( timerId );+ timerId = null;+};++jQuery.fx.speeds = {+ slow: 600,+ fast: 200,+ // Default speed+ _default: 400+};+++// Based off of the plugin by Clint Helfers, with permission.+// http://blindsignals.com/index.php/2009/07/jquery-delay/+jQuery.fn.delay = function( time, type ) {+ time = jQuery.fx ? jQuery.fx.speeds[ time ] || time : time;+ type = type || "fx";++ return this.queue( type, function( next, hooks ) {+ var timeout = setTimeout( next, time );+ hooks.stop = function() {+ clearTimeout( timeout );+ };+ });+};+++(function() {+ var input = document.createElement( "input" ),+ select = document.createElement( "select" ),+ opt = select.appendChild( document.createElement( "option" ) );++ input.type = "checkbox";++ // Support: iOS 5.1, Android 4.x, Android 2.3+ // Check the default checkbox/radio value ("" on old WebKit; "on" elsewhere)+ support.checkOn = input.value !== "";++ // Must access the parent to make an option select properly+ // Support: IE9, IE10+ support.optSelected = opt.selected;++ // Make sure that the options inside disabled selects aren't marked as disabled+ // (WebKit marks them as disabled)+ select.disabled = true;+ support.optDisabled = !opt.disabled;++ // Check if an input maintains its value after becoming a radio+ // Support: IE9, IE10+ input = document.createElement( "input" );+ input.value = "t";+ input.type = "radio";+ support.radioValue = input.value === "t";+})();+++var nodeHook, boolHook,+ attrHandle = jQuery.expr.attrHandle;++jQuery.fn.extend({+ attr: function( name, value ) {+ return access( this, jQuery.attr, name, value, arguments.length > 1 );+ },++ removeAttr: function( name ) {+ return this.each(function() {+ jQuery.removeAttr( this, name );+ });+ }+});++jQuery.extend({+ attr: function( elem, name, value ) {+ var hooks, ret,+ nType = elem.nodeType;++ // don't get/set attributes on text, comment and attribute nodes+ if ( !elem || nType === 3 || nType === 8 || nType === 2 ) {+ return;+ }++ // Fallback to prop when attributes are not supported+ if ( typeof elem.getAttribute === strundefined ) {+ return jQuery.prop( elem, name, value );+ }++ // All attributes are lowercase+ // Grab necessary hook if one is defined+ if ( nType !== 1 || !jQuery.isXMLDoc( elem ) ) {+ name = name.toLowerCase();+ hooks = jQuery.attrHooks[ name ] ||+ ( jQuery.expr.match.bool.test( name ) ? boolHook : nodeHook );+ }++ if ( value !== undefined ) {++ if ( value === null ) {+ jQuery.removeAttr( elem, name );++ } else if ( hooks && "set" in hooks && (ret = hooks.set( elem, value, name )) !== undefined ) {+ return ret;++ } else {+ elem.setAttribute( name, value + "" );+ return value;+ }++ } else if ( hooks && "get" in hooks && (ret = hooks.get( elem, name )) !== null ) {+ return ret;++ } else {+ ret = jQuery.find.attr( elem, name );++ // Non-existent attributes return null, we normalize to undefined+ return ret == null ?+ undefined :+ ret;+ }+ },++ removeAttr: function( elem, value ) {+ var name, propName,+ i = 0,+ attrNames = value && value.match( rnotwhite );++ if ( attrNames && elem.nodeType === 1 ) {+ while ( (name = attrNames[i++]) ) {+ propName = jQuery.propFix[ name ] || name;++ // Boolean attributes get special treatment (#10870)+ if ( jQuery.expr.match.bool.test( name ) ) {+ // Set corresponding property to false+ elem[ propName ] = false;+ }++ elem.removeAttribute( name );+ }+ }+ },++ attrHooks: {+ type: {+ set: function( elem, value ) {+ if ( !support.radioValue && value === "radio" &&+ jQuery.nodeName( elem, "input" ) ) {+ // Setting the type on a radio button after the value resets the value in IE6-9+ // Reset value to default in case type is set after value during creation+ var val = elem.value;+ elem.setAttribute( "type", value );+ if ( val ) {+ elem.value = val;+ }+ return value;+ }+ }+ }+ }+});++// Hooks for boolean attributes+boolHook = {+ set: function( elem, value, name ) {+ if ( value === false ) {+ // Remove boolean attributes when set to false+ jQuery.removeAttr( elem, name );+ } else {+ elem.setAttribute( name, name );+ }+ return name;+ }+};+jQuery.each( jQuery.expr.match.bool.source.match( /\w+/g ), function( i, name ) {+ var getter = attrHandle[ name ] || jQuery.find.attr;++ attrHandle[ name ] = function( elem, name, isXML ) {+ var ret, handle;+ if ( !isXML ) {+ // Avoid an infinite loop by temporarily removing this function from the getter+ handle = attrHandle[ name ];+ attrHandle[ name ] = ret;+ ret = getter( elem, name, isXML ) != null ?+ name.toLowerCase() :+ null;+ attrHandle[ name ] = handle;+ }+ return ret;+ };+});+++++var rfocusable = /^(?:input|select|textarea|button)$/i;++jQuery.fn.extend({+ prop: function( name, value ) {+ return access( this, jQuery.prop, name, value, arguments.length > 1 );+ },++ removeProp: function( name ) {+ return this.each(function() {+ delete this[ jQuery.propFix[ name ] || name ];+ });+ }+});++jQuery.extend({+ propFix: {+ "for": "htmlFor",+ "class": "className"+ },++ prop: function( elem, name, value ) {+ var ret, hooks, notxml,+ nType = elem.nodeType;++ // don't get/set properties on text, comment and attribute nodes+ if ( !elem || nType === 3 || nType === 8 || nType === 2 ) {+ return;+ }++ notxml = nType !== 1 || !jQuery.isXMLDoc( elem );++ if ( notxml ) {+ // Fix name and attach hooks+ name = jQuery.propFix[ name ] || name;+ hooks = jQuery.propHooks[ name ];+ }++ if ( value !== undefined ) {+ return hooks && "set" in hooks && (ret = hooks.set( elem, value, name )) !== undefined ?+ ret :+ ( elem[ name ] = value );++ } else {+ return hooks && "get" in hooks && (ret = hooks.get( elem, name )) !== null ?+ ret :+ elem[ name ];+ }+ },++ propHooks: {+ tabIndex: {+ get: function( elem ) {+ return elem.hasAttribute( "tabindex" ) || rfocusable.test( elem.nodeName ) || elem.href ?+ elem.tabIndex :+ -1;+ }+ }+ }+});++// Support: IE9++// Selectedness for an option in an optgroup can be inaccurate+if ( !support.optSelected ) {+ jQuery.propHooks.selected = {+ get: function( elem ) {+ var parent = elem.parentNode;+ if ( parent && parent.parentNode ) {+ parent.parentNode.selectedIndex;+ }+ return null;+ }+ };+}++jQuery.each([+ "tabIndex",+ "readOnly",+ "maxLength",+ "cellSpacing",+ "cellPadding",+ "rowSpan",+ "colSpan",+ "useMap",+ "frameBorder",+ "contentEditable"+], function() {+ jQuery.propFix[ this.toLowerCase() ] = this;+});+++++var rclass = /[\t\r\n\f]/g;++jQuery.fn.extend({+ addClass: function( value ) {+ var classes, elem, cur, clazz, j, finalValue,+ proceed = typeof value === "string" && value,+ i = 0,+ len = this.length;++ if ( jQuery.isFunction( value ) ) {+ return this.each(function( j ) {+ jQuery( this ).addClass( value.call( this, j, this.className ) );+ });+ }++ if ( proceed ) {+ // The disjunction here is for better compressibility (see removeClass)+ classes = ( value || "" ).match( rnotwhite ) || [];++ for ( ; i < len; i++ ) {+ elem = this[ i ];+ cur = elem.nodeType === 1 && ( elem.className ?+ ( " " + elem.className + " " ).replace( rclass, " " ) :+ " "+ );++ if ( cur ) {+ j = 0;+ while ( (clazz = classes[j++]) ) {+ if ( cur.indexOf( " " + clazz + " " ) < 0 ) {+ cur += clazz + " ";+ }+ }++ // only assign if different to avoid unneeded rendering.+ finalValue = jQuery.trim( cur );+ if ( elem.className !== finalValue ) {+ elem.className = finalValue;+ }+ }+ }+ }++ return this;+ },++ removeClass: function( value ) {+ var classes, elem, cur, clazz, j, finalValue,+ proceed = arguments.length === 0 || typeof value === "string" && value,+ i = 0,+ len = this.length;++ if ( jQuery.isFunction( value ) ) {+ return this.each(function( j ) {+ jQuery( this ).removeClass( value.call( this, j, this.className ) );+ });+ }+ if ( proceed ) {+ classes = ( value || "" ).match( rnotwhite ) || [];++ for ( ; i < len; i++ ) {+ elem = this[ i ];+ // This expression is here for better compressibility (see addClass)+ cur = elem.nodeType === 1 && ( elem.className ?+ ( " " + elem.className + " " ).replace( rclass, " " ) :+ ""+ );++ if ( cur ) {+ j = 0;+ while ( (clazz = classes[j++]) ) {+ // Remove *all* instances+ while ( cur.indexOf( " " + clazz + " " ) >= 0 ) {+ cur = cur.replace( " " + clazz + " ", " " );+ }+ }++ // only assign if different to avoid unneeded rendering.+ finalValue = value ? jQuery.trim( cur ) : "";+ if ( elem.className !== finalValue ) {+ elem.className = finalValue;+ }+ }+ }+ }++ return this;+ },++ toggleClass: function( value, stateVal ) {+ var type = typeof value;++ if ( typeof stateVal === "boolean" && type === "string" ) {+ return stateVal ? this.addClass( value ) : this.removeClass( value );+ }++ if ( jQuery.isFunction( value ) ) {+ return this.each(function( i ) {+ jQuery( this ).toggleClass( value.call(this, i, this.className, stateVal), stateVal );+ });+ }++ return this.each(function() {+ if ( type === "string" ) {+ // toggle individual class names+ var className,+ i = 0,+ self = jQuery( this ),+ classNames = value.match( rnotwhite ) || [];++ while ( (className = classNames[ i++ ]) ) {+ // check each className given, space separated list+ if ( self.hasClass( className ) ) {+ self.removeClass( className );+ } else {+ self.addClass( className );+ }+ }++ // Toggle whole class name+ } else if ( type === strundefined || type === "boolean" ) {+ if ( this.className ) {+ // store className if set+ data_priv.set( this, "__className__", this.className );+ }++ // If the element has a class name or if we're passed "false",+ // then remove the whole classname (if there was one, the above saved it).+ // Otherwise bring back whatever was previously saved (if anything),+ // falling back to the empty string if nothing was stored.+ this.className = this.className || value === false ? "" : data_priv.get( this, "__className__" ) || "";+ }+ });+ },++ hasClass: function( selector ) {+ var className = " " + selector + " ",+ i = 0,+ l = this.length;+ for ( ; i < l; i++ ) {+ if ( this[i].nodeType === 1 && (" " + this[i].className + " ").replace(rclass, " ").indexOf( className ) >= 0 ) {+ return true;+ }+ }++ return false;+ }+});+++++var rreturn = /\r/g;++jQuery.fn.extend({+ val: function( value ) {+ var hooks, ret, isFunction,+ elem = this[0];++ if ( !arguments.length ) {+ if ( elem ) {+ hooks = jQuery.valHooks[ elem.type ] || jQuery.valHooks[ elem.nodeName.toLowerCase() ];++ if ( hooks && "get" in hooks && (ret = hooks.get( elem, "value" )) !== undefined ) {+ return ret;+ }++ ret = elem.value;++ return typeof ret === "string" ?+ // handle most common string cases+ ret.replace(rreturn, "") :+ // handle cases where value is null/undef or number+ ret == null ? "" : ret;+ }++ return;+ }++ isFunction = jQuery.isFunction( value );++ return this.each(function( i ) {+ var val;++ if ( this.nodeType !== 1 ) {+ return;+ }++ if ( isFunction ) {+ val = value.call( this, i, jQuery( this ).val() );+ } else {+ val = value;+ }++ // Treat null/undefined as ""; convert numbers to string+ if ( val == null ) {+ val = "";++ } else if ( typeof val === "number" ) {+ val += "";++ } else if ( jQuery.isArray( val ) ) {+ val = jQuery.map( val, function( value ) {+ return value == null ? "" : value + "";+ });+ }++ hooks = jQuery.valHooks[ this.type ] || jQuery.valHooks[ this.nodeName.toLowerCase() ];++ // If set returns undefined, fall back to normal setting+ if ( !hooks || !("set" in hooks) || hooks.set( this, val, "value" ) === undefined ) {+ this.value = val;+ }+ });+ }+});++jQuery.extend({+ valHooks: {+ option: {+ get: function( elem ) {+ var val = jQuery.find.attr( elem, "value" );+ return val != null ?+ val :+ // Support: IE10-11++ // option.text throws exceptions (#14686, #14858)+ jQuery.trim( jQuery.text( elem ) );+ }+ },+ select: {+ get: function( elem ) {+ var value, option,+ options = elem.options,+ index = elem.selectedIndex,+ one = elem.type === "select-one" || index < 0,+ values = one ? null : [],+ max = one ? index + 1 : options.length,+ i = index < 0 ?+ max :+ one ? index : 0;++ // Loop through all the selected options+ for ( ; i < max; i++ ) {+ option = options[ i ];++ // IE6-9 doesn't update selected after form reset (#2551)+ if ( ( option.selected || i === index ) &&+ // Don't return options that are disabled or in a disabled optgroup+ ( support.optDisabled ? !option.disabled : option.getAttribute( "disabled" ) === null ) &&+ ( !option.parentNode.disabled || !jQuery.nodeName( option.parentNode, "optgroup" ) ) ) {++ // Get the specific value for the option+ value = jQuery( option ).val();++ // We don't need an array for one selects+ if ( one ) {+ return value;+ }++ // Multi-Selects return an array+ values.push( value );+ }+ }++ return values;+ },++ set: function( elem, value ) {+ var optionSet, option,+ options = elem.options,+ values = jQuery.makeArray( value ),+ i = options.length;++ while ( i-- ) {+ option = options[ i ];+ if ( (option.selected = jQuery.inArray( option.value, values ) >= 0) ) {+ optionSet = true;+ }+ }++ // force browsers to behave consistently when non-matching value is set+ if ( !optionSet ) {+ elem.selectedIndex = -1;+ }+ return values;+ }+ }+ }+});++// Radios and checkboxes getter/setter+jQuery.each([ "radio", "checkbox" ], function() {+ jQuery.valHooks[ this ] = {+ set: function( elem, value ) {+ if ( jQuery.isArray( value ) ) {+ return ( elem.checked = jQuery.inArray( jQuery(elem).val(), value ) >= 0 );+ }+ }+ };+ if ( !support.checkOn ) {+ jQuery.valHooks[ this ].get = function( elem ) {+ // Support: Webkit+ // "" is returned instead of "on" if a value isn't specified+ return elem.getAttribute("value") === null ? "on" : elem.value;+ };+ }+});+++++// Return jQuery for attributes-only inclusion+++jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblclick " ++ "mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave " ++ "change select submit keydown keypress keyup error contextmenu").split(" "), function( i, name ) {++ // Handle event binding+ jQuery.fn[ name ] = function( data, fn ) {+ return arguments.length > 0 ?+ this.on( name, null, data, fn ) :+ this.trigger( name );+ };+});++jQuery.fn.extend({+ hover: function( fnOver, fnOut ) {+ return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver );+ },++ bind: function( types, data, fn ) {+ return this.on( types, null, data, fn );+ },+ unbind: function( types, fn ) {+ return this.off( types, null, fn );+ },++ delegate: function( selector, types, data, fn ) {+ return this.on( types, selector, data, fn );+ },+ undelegate: function( selector, types, fn ) {+ // ( namespace ) or ( selector, types [, fn] )+ return arguments.length === 1 ? this.off( selector, "**" ) : this.off( types, selector || "**", fn );+ }+});+++var nonce = jQuery.now();++var rquery = (/\?/);++++// Support: Android 2.3+// Workaround failure to string-cast null input+jQuery.parseJSON = function( data ) {+ return JSON.parse( data + "" );+};+++// Cross-browser xml parsing+jQuery.parseXML = function( data ) {+ var xml, tmp;+ if ( !data || typeof data !== "string" ) {+ return null;+ }++ // Support: IE9+ try {+ tmp = new DOMParser();+ xml = tmp.parseFromString( data, "text/xml" );+ } catch ( e ) {+ xml = undefined;+ }++ if ( !xml || xml.getElementsByTagName( "parsererror" ).length ) {+ jQuery.error( "Invalid XML: " + data );+ }+ return xml;+};+++var+ // Document location+ ajaxLocParts,+ ajaxLocation,++ rhash = /#.*$/,+ rts = /([?&])_=[^&]*/,+ rheaders = /^(.*?):[ \t]*([^\r\n]*)$/mg,+ // #7653, #8125, #8152: local protocol detection+ rlocalProtocol = /^(?:about|app|app-storage|.+-extension|file|res|widget):$/,+ rnoContent = /^(?:GET|HEAD)$/,+ rprotocol = /^\/\//,+ rurl = /^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,++ /* Prefilters+ * 1) They are useful to introduce custom dataTypes (see ajax/jsonp.js for an example)+ * 2) These are called:+ * - BEFORE asking for a transport+ * - AFTER param serialization (s.data is a string if s.processData is true)+ * 3) key is the dataType+ * 4) the catchall symbol "*" can be used+ * 5) execution will start with transport dataType and THEN continue down to "*" if needed+ */+ prefilters = {},++ /* Transports bindings+ * 1) key is the dataType+ * 2) the catchall symbol "*" can be used+ * 3) selection will start with transport dataType and THEN go to "*" if needed+ */+ transports = {},++ // Avoid comment-prolog char sequence (#10098); must appease lint and evade compression+ allTypes = "*/".concat("*");++// #8138, IE may throw an exception when accessing+// a field from window.location if document.domain has been set+try {+ ajaxLocation = location.href;+} catch( e ) {+ // Use the href attribute of an A element+ // since IE will modify it given document.location+ ajaxLocation = document.createElement( "a" );+ ajaxLocation.href = "";+ ajaxLocation = ajaxLocation.href;+}++// Segment location into parts+ajaxLocParts = rurl.exec( ajaxLocation.toLowerCase() ) || [];++// Base "constructor" for jQuery.ajaxPrefilter and jQuery.ajaxTransport+function addToPrefiltersOrTransports( structure ) {++ // dataTypeExpression is optional and defaults to "*"+ return function( dataTypeExpression, func ) {++ if ( typeof dataTypeExpression !== "string" ) {+ func = dataTypeExpression;+ dataTypeExpression = "*";+ }++ var dataType,+ i = 0,+ dataTypes = dataTypeExpression.toLowerCase().match( rnotwhite ) || [];++ if ( jQuery.isFunction( func ) ) {+ // For each dataType in the dataTypeExpression+ while ( (dataType = dataTypes[i++]) ) {+ // Prepend if requested+ if ( dataType[0] === "+" ) {+ dataType = dataType.slice( 1 ) || "*";+ (structure[ dataType ] = structure[ dataType ] || []).unshift( func );++ // Otherwise append+ } else {+ (structure[ dataType ] = structure[ dataType ] || []).push( func );+ }+ }+ }+ };+}++// Base inspection function for prefilters and transports+function inspectPrefiltersOrTransports( structure, options, originalOptions, jqXHR ) {++ var inspected = {},+ seekingTransport = ( structure === transports );++ function inspect( dataType ) {+ var selected;+ inspected[ dataType ] = true;+ jQuery.each( structure[ dataType ] || [], function( _, prefilterOrFactory ) {+ var dataTypeOrTransport = prefilterOrFactory( options, originalOptions, jqXHR );+ if ( typeof dataTypeOrTransport === "string" && !seekingTransport && !inspected[ dataTypeOrTransport ] ) {+ options.dataTypes.unshift( dataTypeOrTransport );+ inspect( dataTypeOrTransport );+ return false;+ } else if ( seekingTransport ) {+ return !( selected = dataTypeOrTransport );+ }+ });+ return selected;+ }++ return inspect( options.dataTypes[ 0 ] ) || !inspected[ "*" ] && inspect( "*" );+}++// A special extend for ajax options+// that takes "flat" options (not to be deep extended)+// Fixes #9887+function ajaxExtend( target, src ) {+ var key, deep,+ flatOptions = jQuery.ajaxSettings.flatOptions || {};++ for ( key in src ) {+ if ( src[ key ] !== undefined ) {+ ( flatOptions[ key ] ? target : ( deep || (deep = {}) ) )[ key ] = src[ key ];+ }+ }+ if ( deep ) {+ jQuery.extend( true, target, deep );+ }++ return target;+}++/* Handles responses to an ajax request:+ * - finds the right dataType (mediates between content-type and expected dataType)+ * - returns the corresponding response+ */+function ajaxHandleResponses( s, jqXHR, responses ) {++ var ct, type, finalDataType, firstDataType,+ contents = s.contents,+ dataTypes = s.dataTypes;++ // Remove auto dataType and get content-type in the process+ while ( dataTypes[ 0 ] === "*" ) {+ dataTypes.shift();+ if ( ct === undefined ) {+ ct = s.mimeType || jqXHR.getResponseHeader("Content-Type");+ }+ }++ // Check if we're dealing with a known content-type+ if ( ct ) {+ for ( type in contents ) {+ if ( contents[ type ] && contents[ type ].test( ct ) ) {+ dataTypes.unshift( type );+ break;+ }+ }+ }++ // Check to see if we have a response for the expected dataType+ if ( dataTypes[ 0 ] in responses ) {+ finalDataType = dataTypes[ 0 ];+ } else {+ // Try convertible dataTypes+ for ( type in responses ) {+ if ( !dataTypes[ 0 ] || s.converters[ type + " " + dataTypes[0] ] ) {+ finalDataType = type;+ break;+ }+ if ( !firstDataType ) {+ firstDataType = type;+ }+ }+ // Or just use first one+ finalDataType = finalDataType || firstDataType;+ }++ // If we found a dataType+ // We add the dataType to the list if needed+ // and return the corresponding response+ if ( finalDataType ) {+ if ( finalDataType !== dataTypes[ 0 ] ) {+ dataTypes.unshift( finalDataType );+ }+ return responses[ finalDataType ];+ }+}++/* Chain conversions given the request and the original response+ * Also sets the responseXXX fields on the jqXHR instance+ */+function ajaxConvert( s, response, jqXHR, isSuccess ) {+ var conv2, current, conv, tmp, prev,+ converters = {},+ // Work with a copy of dataTypes in case we need to modify it for conversion+ dataTypes = s.dataTypes.slice();++ // Create converters map with lowercased keys+ if ( dataTypes[ 1 ] ) {+ for ( conv in s.converters ) {+ converters[ conv.toLowerCase() ] = s.converters[ conv ];+ }+ }++ current = dataTypes.shift();++ // Convert to each sequential dataType+ while ( current ) {++ if ( s.responseFields[ current ] ) {+ jqXHR[ s.responseFields[ current ] ] = response;+ }++ // Apply the dataFilter if provided+ if ( !prev && isSuccess && s.dataFilter ) {+ response = s.dataFilter( response, s.dataType );+ }++ prev = current;+ current = dataTypes.shift();++ if ( current ) {++ // There's only work to do if current dataType is non-auto+ if ( current === "*" ) {++ current = prev;++ // Convert response if prev dataType is non-auto and differs from current+ } else if ( prev !== "*" && prev !== current ) {++ // Seek a direct converter+ conv = converters[ prev + " " + current ] || converters[ "* " + current ];++ // If none found, seek a pair+ if ( !conv ) {+ for ( conv2 in converters ) {++ // If conv2 outputs current+ tmp = conv2.split( " " );+ if ( tmp[ 1 ] === current ) {++ // If prev can be converted to accepted input+ conv = converters[ prev + " " + tmp[ 0 ] ] ||+ converters[ "* " + tmp[ 0 ] ];+ if ( conv ) {+ // Condense equivalence converters+ if ( conv === true ) {+ conv = converters[ conv2 ];++ // Otherwise, insert the intermediate dataType+ } else if ( converters[ conv2 ] !== true ) {+ current = tmp[ 0 ];+ dataTypes.unshift( tmp[ 1 ] );+ }+ break;+ }+ }+ }+ }++ // Apply converter (if not an equivalence)+ if ( conv !== true ) {++ // Unless errors are allowed to bubble, catch and return them+ if ( conv && s[ "throws" ] ) {+ response = conv( response );+ } else {+ try {+ response = conv( response );+ } catch ( e ) {+ return { state: "parsererror", error: conv ? e : "No conversion from " + prev + " to " + current };+ }+ }+ }+ }+ }+ }++ return { state: "success", data: response };+}++jQuery.extend({++ // Counter for holding the number of active queries+ active: 0,++ // Last-Modified header cache for next request+ lastModified: {},+ etag: {},++ ajaxSettings: {+ url: ajaxLocation,+ type: "GET",+ isLocal: rlocalProtocol.test( ajaxLocParts[ 1 ] ),+ global: true,+ processData: true,+ async: true,+ contentType: "application/x-www-form-urlencoded; charset=UTF-8",+ /*+ timeout: 0,+ data: null,+ dataType: null,+ username: null,+ password: null,+ cache: null,+ throws: false,+ traditional: false,+ headers: {},+ */++ accepts: {+ "*": allTypes,+ text: "text/plain",+ html: "text/html",+ xml: "application/xml, text/xml",+ json: "application/json, text/javascript"+ },++ contents: {+ xml: /xml/,+ html: /html/,+ json: /json/+ },++ responseFields: {+ xml: "responseXML",+ text: "responseText",+ json: "responseJSON"+ },++ // Data converters+ // Keys separate source (or catchall "*") and destination types with a single space+ converters: {++ // Convert anything to text+ "* text": String,++ // Text to html (true = no transformation)+ "text html": true,++ // Evaluate text as a json expression+ "text json": jQuery.parseJSON,++ // Parse text as xml+ "text xml": jQuery.parseXML+ },++ // For options that shouldn't be deep extended:+ // you can add your own custom options here if+ // and when you create one that shouldn't be+ // deep extended (see ajaxExtend)+ flatOptions: {+ url: true,+ context: true+ }+ },++ // Creates a full fledged settings object into target+ // with both ajaxSettings and settings fields.+ // If target is omitted, writes into ajaxSettings.+ ajaxSetup: function( target, settings ) {+ return settings ?++ // Building a settings object+ ajaxExtend( ajaxExtend( target, jQuery.ajaxSettings ), settings ) :++ // Extending ajaxSettings+ ajaxExtend( jQuery.ajaxSettings, target );+ },++ ajaxPrefilter: addToPrefiltersOrTransports( prefilters ),+ ajaxTransport: addToPrefiltersOrTransports( transports ),++ // Main method+ ajax: function( url, options ) {++ // If url is an object, simulate pre-1.5 signature+ if ( typeof url === "object" ) {+ options = url;+ url = undefined;+ }++ // Force options to be an object+ options = options || {};++ var transport,+ // URL without anti-cache param+ cacheURL,+ // Response headers+ responseHeadersString,+ responseHeaders,+ // timeout handle+ timeoutTimer,+ // Cross-domain detection vars+ parts,+ // To know if global events are to be dispatched+ fireGlobals,+ // Loop variable+ i,+ // Create the final options object+ s = jQuery.ajaxSetup( {}, options ),+ // Callbacks context+ callbackContext = s.context || s,+ // Context for global events is callbackContext if it is a DOM node or jQuery collection+ globalEventContext = s.context && ( callbackContext.nodeType || callbackContext.jquery ) ?+ jQuery( callbackContext ) :+ jQuery.event,+ // Deferreds+ deferred = jQuery.Deferred(),+ completeDeferred = jQuery.Callbacks("once memory"),+ // Status-dependent callbacks+ statusCode = s.statusCode || {},+ // Headers (they are sent all at once)+ requestHeaders = {},+ requestHeadersNames = {},+ // The jqXHR state+ state = 0,+ // Default abort message+ strAbort = "canceled",+ // Fake xhr+ jqXHR = {+ readyState: 0,++ // Builds headers hashtable if needed+ getResponseHeader: function( key ) {+ var match;+ if ( state === 2 ) {+ if ( !responseHeaders ) {+ responseHeaders = {};+ while ( (match = rheaders.exec( responseHeadersString )) ) {+ responseHeaders[ match[1].toLowerCase() ] = match[ 2 ];+ }+ }+ match = responseHeaders[ key.toLowerCase() ];+ }+ return match == null ? null : match;+ },++ // Raw string+ getAllResponseHeaders: function() {+ return state === 2 ? responseHeadersString : null;+ },++ // Caches the header+ setRequestHeader: function( name, value ) {+ var lname = name.toLowerCase();+ if ( !state ) {+ name = requestHeadersNames[ lname ] = requestHeadersNames[ lname ] || name;+ requestHeaders[ name ] = value;+ }+ return this;+ },++ // Overrides response content-type header+ overrideMimeType: function( type ) {+ if ( !state ) {+ s.mimeType = type;+ }+ return this;+ },++ // Status-dependent callbacks+ statusCode: function( map ) {+ var code;+ if ( map ) {+ if ( state < 2 ) {+ for ( code in map ) {+ // Lazy-add the new callback in a way that preserves old ones+ statusCode[ code ] = [ statusCode[ code ], map[ code ] ];+ }+ } else {+ // Execute the appropriate callbacks+ jqXHR.always( map[ jqXHR.status ] );+ }+ }+ return this;+ },++ // Cancel the request+ abort: function( statusText ) {+ var finalText = statusText || strAbort;+ if ( transport ) {+ transport.abort( finalText );+ }+ done( 0, finalText );+ return this;+ }+ };++ // Attach deferreds+ deferred.promise( jqXHR ).complete = completeDeferred.add;+ jqXHR.success = jqXHR.done;+ jqXHR.error = jqXHR.fail;++ // Remove hash character (#7531: and string promotion)+ // Add protocol if not provided (prefilters might expect it)+ // Handle falsy url in the settings object (#10093: consistency with old signature)+ // We also use the url parameter if available+ s.url = ( ( url || s.url || ajaxLocation ) + "" ).replace( rhash, "" )+ .replace( rprotocol, ajaxLocParts[ 1 ] + "//" );++ // Alias method option to type as per ticket #12004+ s.type = options.method || options.type || s.method || s.type;++ // Extract dataTypes list+ s.dataTypes = jQuery.trim( s.dataType || "*" ).toLowerCase().match( rnotwhite ) || [ "" ];++ // A cross-domain request is in order when we have a protocol:host:port mismatch+ if ( s.crossDomain == null ) {+ parts = rurl.exec( s.url.toLowerCase() );+ s.crossDomain = !!( parts &&+ ( parts[ 1 ] !== ajaxLocParts[ 1 ] || parts[ 2 ] !== ajaxLocParts[ 2 ] ||+ ( parts[ 3 ] || ( parts[ 1 ] === "http:" ? "80" : "443" ) ) !==+ ( ajaxLocParts[ 3 ] || ( ajaxLocParts[ 1 ] === "http:" ? "80" : "443" ) ) )+ );+ }++ // Convert data if not already a string+ if ( s.data && s.processData && typeof s.data !== "string" ) {+ s.data = jQuery.param( s.data, s.traditional );+ }++ // Apply prefilters+ inspectPrefiltersOrTransports( prefilters, s, options, jqXHR );++ // If request was aborted inside a prefilter, stop there+ if ( state === 2 ) {+ return jqXHR;+ }++ // We can fire global events as of now if asked to+ fireGlobals = s.global;++ // Watch for a new set of requests+ if ( fireGlobals && jQuery.active++ === 0 ) {+ jQuery.event.trigger("ajaxStart");+ }++ // Uppercase the type+ s.type = s.type.toUpperCase();++ // Determine if request has content+ s.hasContent = !rnoContent.test( s.type );++ // Save the URL in case we're toying with the If-Modified-Since+ // and/or If-None-Match header later on+ cacheURL = s.url;++ // More options handling for requests with no content+ if ( !s.hasContent ) {++ // If data is available, append data to url+ if ( s.data ) {+ cacheURL = ( s.url += ( rquery.test( cacheURL ) ? "&" : "?" ) + s.data );+ // #9682: remove data so that it's not used in an eventual retry+ delete s.data;+ }++ // Add anti-cache in url if needed+ if ( s.cache === false ) {+ s.url = rts.test( cacheURL ) ?++ // If there is already a '_' parameter, set its value+ cacheURL.replace( rts, "$1_=" + nonce++ ) :++ // Otherwise add one to the end+ cacheURL + ( rquery.test( cacheURL ) ? "&" : "?" ) + "_=" + nonce++;+ }+ }++ // Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.+ if ( s.ifModified ) {+ if ( jQuery.lastModified[ cacheURL ] ) {+ jqXHR.setRequestHeader( "If-Modified-Since", jQuery.lastModified[ cacheURL ] );+ }+ if ( jQuery.etag[ cacheURL ] ) {+ jqXHR.setRequestHeader( "If-None-Match", jQuery.etag[ cacheURL ] );+ }+ }++ // Set the correct header, if data is being sent+ if ( s.data && s.hasContent && s.contentType !== false || options.contentType ) {+ jqXHR.setRequestHeader( "Content-Type", s.contentType );+ }++ // Set the Accepts header for the server, depending on the dataType+ jqXHR.setRequestHeader(+ "Accept",+ s.dataTypes[ 0 ] && s.accepts[ s.dataTypes[0] ] ?+ s.accepts[ s.dataTypes[0] ] + ( s.dataTypes[ 0 ] !== "*" ? ", " + allTypes + "; q=0.01" : "" ) :+ s.accepts[ "*" ]+ );++ // Check for headers option+ for ( i in s.headers ) {+ jqXHR.setRequestHeader( i, s.headers[ i ] );+ }++ // Allow custom headers/mimetypes and early abort+ if ( s.beforeSend && ( s.beforeSend.call( callbackContext, jqXHR, s ) === false || state === 2 ) ) {+ // Abort if not done already and return+ return jqXHR.abort();+ }++ // aborting is no longer a cancellation+ strAbort = "abort";++ // Install callbacks on deferreds+ for ( i in { success: 1, error: 1, complete: 1 } ) {+ jqXHR[ i ]( s[ i ] );+ }++ // Get transport+ transport = inspectPrefiltersOrTransports( transports, s, options, jqXHR );++ // If no transport, we auto-abort+ if ( !transport ) {+ done( -1, "No Transport" );+ } else {+ jqXHR.readyState = 1;++ // Send global event+ if ( fireGlobals ) {+ globalEventContext.trigger( "ajaxSend", [ jqXHR, s ] );+ }+ // Timeout+ if ( s.async && s.timeout > 0 ) {+ timeoutTimer = setTimeout(function() {+ jqXHR.abort("timeout");+ }, s.timeout );+ }++ try {+ state = 1;+ transport.send( requestHeaders, done );+ } catch ( e ) {+ // Propagate exception as error if not done+ if ( state < 2 ) {+ done( -1, e );+ // Simply rethrow otherwise+ } else {+ throw e;+ }+ }+ }++ // Callback for when everything is done+ function done( status, nativeStatusText, responses, headers ) {+ var isSuccess, success, error, response, modified,+ statusText = nativeStatusText;++ // Called once+ if ( state === 2 ) {+ return;+ }++ // State is "done" now+ state = 2;++ // Clear timeout if it exists+ if ( timeoutTimer ) {+ clearTimeout( timeoutTimer );+ }++ // Dereference transport for early garbage collection+ // (no matter how long the jqXHR object will be used)+ transport = undefined;++ // Cache response headers+ responseHeadersString = headers || "";++ // Set readyState+ jqXHR.readyState = status > 0 ? 4 : 0;++ // Determine if successful+ isSuccess = status >= 200 && status < 300 || status === 304;++ // Get response data+ if ( responses ) {+ response = ajaxHandleResponses( s, jqXHR, responses );+ }++ // Convert no matter what (that way responseXXX fields are always set)+ response = ajaxConvert( s, response, jqXHR, isSuccess );++ // If successful, handle type chaining+ if ( isSuccess ) {++ // Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.+ if ( s.ifModified ) {+ modified = jqXHR.getResponseHeader("Last-Modified");+ if ( modified ) {+ jQuery.lastModified[ cacheURL ] = modified;+ }+ modified = jqXHR.getResponseHeader("etag");+ if ( modified ) {+ jQuery.etag[ cacheURL ] = modified;+ }+ }++ // if no content+ if ( status === 204 || s.type === "HEAD" ) {+ statusText = "nocontent";++ // if not modified+ } else if ( status === 304 ) {+ statusText = "notmodified";++ // If we have data, let's convert it+ } else {+ statusText = response.state;+ success = response.data;+ error = response.error;+ isSuccess = !error;+ }+ } else {+ // We extract error from statusText+ // then normalize statusText and status for non-aborts+ error = statusText;+ if ( status || !statusText ) {+ statusText = "error";+ if ( status < 0 ) {+ status = 0;+ }+ }+ }++ // Set data for the fake xhr object+ jqXHR.status = status;+ jqXHR.statusText = ( nativeStatusText || statusText ) + "";++ // Success/Error+ if ( isSuccess ) {+ deferred.resolveWith( callbackContext, [ success, statusText, jqXHR ] );+ } else {+ deferred.rejectWith( callbackContext, [ jqXHR, statusText, error ] );+ }++ // Status-dependent callbacks+ jqXHR.statusCode( statusCode );+ statusCode = undefined;++ if ( fireGlobals ) {+ globalEventContext.trigger( isSuccess ? "ajaxSuccess" : "ajaxError",+ [ jqXHR, s, isSuccess ? success : error ] );+ }++ // Complete+ completeDeferred.fireWith( callbackContext, [ jqXHR, statusText ] );++ if ( fireGlobals ) {+ globalEventContext.trigger( "ajaxComplete", [ jqXHR, s ] );+ // Handle the global AJAX counter+ if ( !( --jQuery.active ) ) {+ jQuery.event.trigger("ajaxStop");+ }+ }+ }++ return jqXHR;+ },++ getJSON: function( url, data, callback ) {+ return jQuery.get( url, data, callback, "json" );+ },++ getScript: function( url, callback ) {+ return jQuery.get( url, undefined, callback, "script" );+ }+});++jQuery.each( [ "get", "post" ], function( i, method ) {+ jQuery[ method ] = function( url, data, callback, type ) {+ // shift arguments if data argument was omitted+ if ( jQuery.isFunction( data ) ) {+ type = type || callback;+ callback = data;+ data = undefined;+ }++ return jQuery.ajax({+ url: url,+ type: method,+ dataType: type,+ data: data,+ success: callback+ });+ };+});++// Attach a bunch of functions for handling common AJAX events+jQuery.each( [ "ajaxStart", "ajaxStop", "ajaxComplete", "ajaxError", "ajaxSuccess", "ajaxSend" ], function( i, type ) {+ jQuery.fn[ type ] = function( fn ) {+ return this.on( type, fn );+ };+});+++jQuery._evalUrl = function( url ) {+ return jQuery.ajax({+ url: url,+ type: "GET",+ dataType: "script",+ async: false,+ global: false,+ "throws": true+ });+};+++jQuery.fn.extend({+ wrapAll: function( html ) {+ var wrap;++ if ( jQuery.isFunction( html ) ) {+ return this.each(function( i ) {+ jQuery( this ).wrapAll( html.call(this, i) );+ });+ }++ if ( this[ 0 ] ) {++ // The elements to wrap the target around+ wrap = jQuery( html, this[ 0 ].ownerDocument ).eq( 0 ).clone( true );++ if ( this[ 0 ].parentNode ) {+ wrap.insertBefore( this[ 0 ] );+ }++ wrap.map(function() {+ var elem = this;++ while ( elem.firstElementChild ) {+ elem = elem.firstElementChild;+ }++ return elem;+ }).append( this );+ }++ return this;+ },++ wrapInner: function( html ) {+ if ( jQuery.isFunction( html ) ) {+ return this.each(function( i ) {+ jQuery( this ).wrapInner( html.call(this, i) );+ });+ }++ return this.each(function() {+ var self = jQuery( this ),+ contents = self.contents();++ if ( contents.length ) {+ contents.wrapAll( html );++ } else {+ self.append( html );+ }+ });+ },++ wrap: function( html ) {+ var isFunction = jQuery.isFunction( html );++ return this.each(function( i ) {+ jQuery( this ).wrapAll( isFunction ? html.call(this, i) : html );+ });+ },++ unwrap: function() {+ return this.parent().each(function() {+ if ( !jQuery.nodeName( this, "body" ) ) {+ jQuery( this ).replaceWith( this.childNodes );+ }+ }).end();+ }+});+++jQuery.expr.filters.hidden = function( elem ) {+ // Support: Opera <= 12.12+ // Opera reports offsetWidths and offsetHeights less than zero on some elements+ return elem.offsetWidth <= 0 && elem.offsetHeight <= 0;+};+jQuery.expr.filters.visible = function( elem ) {+ return !jQuery.expr.filters.hidden( elem );+};+++++var r20 = /%20/g,+ rbracket = /\[\]$/,+ rCRLF = /\r?\n/g,+ rsubmitterTypes = /^(?:submit|button|image|reset|file)$/i,+ rsubmittable = /^(?:input|select|textarea|keygen)/i;++function buildParams( prefix, obj, traditional, add ) {+ var name;++ if ( jQuery.isArray( obj ) ) {+ // Serialize array item.+ jQuery.each( obj, function( i, v ) {+ if ( traditional || rbracket.test( prefix ) ) {+ // Treat each array item as a scalar.+ add( prefix, v );++ } else {+ // Item is non-scalar (array or object), encode its numeric index.+ buildParams( prefix + "[" + ( typeof v === "object" ? i : "" ) + "]", v, traditional, add );+ }+ });++ } else if ( !traditional && jQuery.type( obj ) === "object" ) {+ // Serialize object item.+ for ( name in obj ) {+ buildParams( prefix + "[" + name + "]", obj[ name ], traditional, add );+ }++ } else {+ // Serialize scalar item.+ add( prefix, obj );+ }+}++// Serialize an array of form elements or a set of+// key/values into a query string+jQuery.param = function( a, traditional ) {+ var prefix,+ s = [],+ add = function( key, value ) {+ // If value is a function, invoke it and return its value+ value = jQuery.isFunction( value ) ? value() : ( value == null ? "" : value );+ s[ s.length ] = encodeURIComponent( key ) + "=" + encodeURIComponent( value );+ };++ // Set traditional to true for jQuery <= 1.3.2 behavior.+ if ( traditional === undefined ) {+ traditional = jQuery.ajaxSettings && jQuery.ajaxSettings.traditional;+ }++ // If an array was passed in, assume that it is an array of form elements.+ if ( jQuery.isArray( a ) || ( a.jquery && !jQuery.isPlainObject( a ) ) ) {+ // Serialize the form elements+ jQuery.each( a, function() {+ add( this.name, this.value );+ });++ } else {+ // If traditional, encode the "old" way (the way 1.3.2 or older+ // did it), otherwise encode params recursively.+ for ( prefix in a ) {+ buildParams( prefix, a[ prefix ], traditional, add );+ }+ }++ // Return the resulting serialization+ return s.join( "&" ).replace( r20, "+" );+};++jQuery.fn.extend({+ serialize: function() {+ return jQuery.param( this.serializeArray() );+ },+ serializeArray: function() {+ return this.map(function() {+ // Can add propHook for "elements" to filter or add form elements+ var elements = jQuery.prop( this, "elements" );+ return elements ? jQuery.makeArray( elements ) : this;+ })+ .filter(function() {+ var type = this.type;++ // Use .is( ":disabled" ) so that fieldset[disabled] works+ return this.name && !jQuery( this ).is( ":disabled" ) &&+ rsubmittable.test( this.nodeName ) && !rsubmitterTypes.test( type ) &&+ ( this.checked || !rcheckableType.test( type ) );+ })+ .map(function( i, elem ) {+ var val = jQuery( this ).val();++ return val == null ?+ null :+ jQuery.isArray( val ) ?+ jQuery.map( val, function( val ) {+ return { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };+ }) :+ { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };+ }).get();+ }+});+++jQuery.ajaxSettings.xhr = function() {+ try {+ return new XMLHttpRequest();+ } catch( e ) {}+};++var xhrId = 0,+ xhrCallbacks = {},+ xhrSuccessStatus = {+ // file protocol always yields status code 0, assume 200+ 0: 200,+ // Support: IE9+ // #1450: sometimes IE returns 1223 when it should be 204+ 1223: 204+ },+ xhrSupported = jQuery.ajaxSettings.xhr();++// Support: IE9+// Open requests must be manually aborted on unload (#5280)+if ( window.ActiveXObject ) {+ jQuery( window ).on( "unload", function() {+ for ( var key in xhrCallbacks ) {+ xhrCallbacks[ key ]();+ }+ });+}++support.cors = !!xhrSupported && ( "withCredentials" in xhrSupported );+support.ajax = xhrSupported = !!xhrSupported;++jQuery.ajaxTransport(function( options ) {+ var callback;++ // Cross domain only allowed if supported through XMLHttpRequest+ if ( support.cors || xhrSupported && !options.crossDomain ) {+ return {+ send: function( headers, complete ) {+ var i,+ xhr = options.xhr(),+ id = ++xhrId;++ xhr.open( options.type, options.url, options.async, options.username, options.password );++ // Apply custom fields if provided+ if ( options.xhrFields ) {+ for ( i in options.xhrFields ) {+ xhr[ i ] = options.xhrFields[ i ];+ }+ }++ // Override mime type if needed+ if ( options.mimeType && xhr.overrideMimeType ) {+ xhr.overrideMimeType( options.mimeType );+ }++ // X-Requested-With header+ // For cross-domain requests, seeing as conditions for a preflight are+ // akin to a jigsaw puzzle, we simply never set it to be sure.+ // (it can always be set on a per-request basis or even using ajaxSetup)+ // For same-domain requests, won't change header if already provided.+ if ( !options.crossDomain && !headers["X-Requested-With"] ) {+ headers["X-Requested-With"] = "XMLHttpRequest";+ }++ // Set headers+ for ( i in headers ) {+ xhr.setRequestHeader( i, headers[ i ] );+ }++ // Callback+ callback = function( type ) {+ return function() {+ if ( callback ) {+ delete xhrCallbacks[ id ];+ callback = xhr.onload = xhr.onerror = null;++ if ( type === "abort" ) {+ xhr.abort();+ } else if ( type === "error" ) {+ complete(+ // file: protocol always yields status 0; see #8605, #14207+ xhr.status,+ xhr.statusText+ );+ } else {+ complete(+ xhrSuccessStatus[ xhr.status ] || xhr.status,+ xhr.statusText,+ // Support: IE9+ // Accessing binary-data responseText throws an exception+ // (#11426)+ typeof xhr.responseText === "string" ? {+ text: xhr.responseText+ } : undefined,+ xhr.getAllResponseHeaders()+ );+ }+ }+ };+ };++ // Listen to events+ xhr.onload = callback();+ xhr.onerror = callback("error");++ // Create the abort callback+ callback = xhrCallbacks[ id ] = callback("abort");++ try {+ // Do send the request (this may raise an exception)+ xhr.send( options.hasContent && options.data || null );+ } catch ( e ) {+ // #14683: Only rethrow if this hasn't been notified as an error yet+ if ( callback ) {+ throw e;+ }+ }+ },++ abort: function() {+ if ( callback ) {+ callback();+ }+ }+ };+ }+});+++++// Install script dataType+jQuery.ajaxSetup({+ accepts: {+ script: "text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"+ },+ contents: {+ script: /(?:java|ecma)script/+ },+ converters: {+ "text script": function( text ) {+ jQuery.globalEval( text );+ return text;+ }+ }+});++// Handle cache's special case and crossDomain+jQuery.ajaxPrefilter( "script", function( s ) {+ if ( s.cache === undefined ) {+ s.cache = false;+ }+ if ( s.crossDomain ) {+ s.type = "GET";+ }+});++// Bind script tag hack transport+jQuery.ajaxTransport( "script", function( s ) {+ // This transport only deals with cross domain requests+ if ( s.crossDomain ) {+ var script, callback;+ return {+ send: function( _, complete ) {+ script = jQuery("<script>").prop({+ async: true,+ charset: s.scriptCharset,+ src: s.url+ }).on(+ "load error",+ callback = function( evt ) {+ script.remove();+ callback = null;+ if ( evt ) {+ complete( evt.type === "error" ? 404 : 200, evt.type );+ }+ }+ );+ document.head.appendChild( script[ 0 ] );+ },+ abort: function() {+ if ( callback ) {+ callback();+ }+ }+ };+ }+});+++++var oldCallbacks = [],+ rjsonp = /(=)\?(?=&|$)|\?\?/;++// Default jsonp settings+jQuery.ajaxSetup({+ jsonp: "callback",+ jsonpCallback: function() {+ var callback = oldCallbacks.pop() || ( jQuery.expando + "_" + ( nonce++ ) );+ this[ callback ] = true;+ return callback;+ }+});++// Detect, normalize options and install callbacks for jsonp requests+jQuery.ajaxPrefilter( "json jsonp", function( s, originalSettings, jqXHR ) {++ var callbackName, overwritten, responseContainer,+ jsonProp = s.jsonp !== false && ( rjsonp.test( s.url ) ?+ "url" :+ typeof s.data === "string" && !( s.contentType || "" ).indexOf("application/x-www-form-urlencoded") && rjsonp.test( s.data ) && "data"+ );++ // Handle iff the expected data type is "jsonp" or we have a parameter to set+ if ( jsonProp || s.dataTypes[ 0 ] === "jsonp" ) {++ // Get callback name, remembering preexisting value associated with it+ callbackName = s.jsonpCallback = jQuery.isFunction( s.jsonpCallback ) ?+ s.jsonpCallback() :+ s.jsonpCallback;++ // Insert callback into url or form data+ if ( jsonProp ) {+ s[ jsonProp ] = s[ jsonProp ].replace( rjsonp, "$1" + callbackName );+ } else if ( s.jsonp !== false ) {+ s.url += ( rquery.test( s.url ) ? "&" : "?" ) + s.jsonp + "=" + callbackName;+ }++ // Use data converter to retrieve json after script execution+ s.converters["script json"] = function() {+ if ( !responseContainer ) {+ jQuery.error( callbackName + " was not called" );+ }+ return responseContainer[ 0 ];+ };++ // force json dataType+ s.dataTypes[ 0 ] = "json";++ // Install callback+ overwritten = window[ callbackName ];+ window[ callbackName ] = function() {+ responseContainer = arguments;+ };++ // Clean-up function (fires after converters)+ jqXHR.always(function() {+ // Restore preexisting value+ window[ callbackName ] = overwritten;++ // Save back as free+ if ( s[ callbackName ] ) {+ // make sure that re-using the options doesn't screw things around+ s.jsonpCallback = originalSettings.jsonpCallback;++ // save the callback name for future use+ oldCallbacks.push( callbackName );+ }++ // Call if it was a function and we have a response+ if ( responseContainer && jQuery.isFunction( overwritten ) ) {+ overwritten( responseContainer[ 0 ] );+ }++ responseContainer = overwritten = undefined;+ });++ // Delegate to script+ return "script";+ }+});+++++// data: string of html+// context (optional): If specified, the fragment will be created in this context, defaults to document+// keepScripts (optional): If true, will include scripts passed in the html string+jQuery.parseHTML = function( data, context, keepScripts ) {+ if ( !data || typeof data !== "string" ) {+ return null;+ }+ if ( typeof context === "boolean" ) {+ keepScripts = context;+ context = false;+ }+ context = context || document;++ var parsed = rsingleTag.exec( data ),+ scripts = !keepScripts && [];++ // Single tag+ if ( parsed ) {+ return [ context.createElement( parsed[1] ) ];+ }++ parsed = jQuery.buildFragment( [ data ], context, scripts );++ if ( scripts && scripts.length ) {+ jQuery( scripts ).remove();+ }++ return jQuery.merge( [], parsed.childNodes );+};+++// Keep a copy of the old load method+var _load = jQuery.fn.load;++/**+ * Load a url into a page+ */+jQuery.fn.load = function( url, params, callback ) {+ if ( typeof url !== "string" && _load ) {+ return _load.apply( this, arguments );+ }++ var selector, type, response,+ self = this,+ off = url.indexOf(" ");++ if ( off >= 0 ) {+ selector = jQuery.trim( url.slice( off ) );+ url = url.slice( 0, off );+ }++ // If it's a function+ if ( jQuery.isFunction( params ) ) {++ // We assume that it's the callback+ callback = params;+ params = undefined;++ // Otherwise, build a param string+ } else if ( params && typeof params === "object" ) {+ type = "POST";+ }++ // If we have elements to modify, make the request+ if ( self.length > 0 ) {+ jQuery.ajax({+ url: url,++ // if "type" variable is undefined, then "GET" method will be used+ type: type,+ dataType: "html",+ data: params+ }).done(function( responseText ) {++ // Save response for use in complete callback+ response = arguments;++ self.html( selector ?++ // If a selector was specified, locate the right elements in a dummy div+ // Exclude scripts to avoid IE 'Permission Denied' errors+ jQuery("<div>").append( jQuery.parseHTML( responseText ) ).find( selector ) :++ // Otherwise use the full result+ responseText );++ }).complete( callback && function( jqXHR, status ) {+ self.each( callback, response || [ jqXHR.responseText, status, jqXHR ] );+ });+ }++ return this;+};+++++jQuery.expr.filters.animated = function( elem ) {+ return jQuery.grep(jQuery.timers, function( fn ) {+ return elem === fn.elem;+ }).length;+};+++++var docElem = window.document.documentElement;++/**+ * Gets a window from an element+ */+function getWindow( elem ) {+ return jQuery.isWindow( elem ) ? elem : elem.nodeType === 9 && elem.defaultView;+}++jQuery.offset = {+ setOffset: function( elem, options, i ) {+ var curPosition, curLeft, curCSSTop, curTop, curOffset, curCSSLeft, calculatePosition,+ position = jQuery.css( elem, "position" ),+ curElem = jQuery( elem ),+ props = {};++ // Set position first, in-case top/left are set even on static elem+ if ( position === "static" ) {+ elem.style.position = "relative";+ }++ curOffset = curElem.offset();+ curCSSTop = jQuery.css( elem, "top" );+ curCSSLeft = jQuery.css( elem, "left" );+ calculatePosition = ( position === "absolute" || position === "fixed" ) &&+ ( curCSSTop + curCSSLeft ).indexOf("auto") > -1;++ // Need to be able to calculate position if either top or left is auto and position is either absolute or fixed+ if ( calculatePosition ) {+ curPosition = curElem.position();+ curTop = curPosition.top;+ curLeft = curPosition.left;++ } else {+ curTop = parseFloat( curCSSTop ) || 0;+ curLeft = parseFloat( curCSSLeft ) || 0;+ }++ if ( jQuery.isFunction( options ) ) {+ options = options.call( elem, i, curOffset );+ }++ if ( options.top != null ) {+ props.top = ( options.top - curOffset.top ) + curTop;+ }+ if ( options.left != null ) {+ props.left = ( options.left - curOffset.left ) + curLeft;+ }++ if ( "using" in options ) {+ options.using.call( elem, props );++ } else {+ curElem.css( props );+ }+ }+};++jQuery.fn.extend({+ offset: function( options ) {+ if ( arguments.length ) {+ return options === undefined ?+ this :+ this.each(function( i ) {+ jQuery.offset.setOffset( this, options, i );+ });+ }++ var docElem, win,+ elem = this[ 0 ],+ box = { top: 0, left: 0 },+ doc = elem && elem.ownerDocument;++ if ( !doc ) {+ return;+ }++ docElem = doc.documentElement;++ // Make sure it's not a disconnected DOM node+ if ( !jQuery.contains( docElem, elem ) ) {+ return box;+ }++ // If we don't have gBCR, just use 0,0 rather than error+ // BlackBerry 5, iOS 3 (original iPhone)+ if ( typeof elem.getBoundingClientRect !== strundefined ) {+ box = elem.getBoundingClientRect();+ }+ win = getWindow( doc );+ return {+ top: box.top + win.pageYOffset - docElem.clientTop,+ left: box.left + win.pageXOffset - docElem.clientLeft+ };+ },++ position: function() {+ if ( !this[ 0 ] ) {+ return;+ }++ var offsetParent, offset,+ elem = this[ 0 ],+ parentOffset = { top: 0, left: 0 };++ // Fixed elements are offset from window (parentOffset = {top:0, left: 0}, because it is its only offset parent+ if ( jQuery.css( elem, "position" ) === "fixed" ) {+ // We assume that getBoundingClientRect is available when computed position is fixed+ offset = elem.getBoundingClientRect();++ } else {+ // Get *real* offsetParent+ offsetParent = this.offsetParent();++ // Get correct offsets+ offset = this.offset();+ if ( !jQuery.nodeName( offsetParent[ 0 ], "html" ) ) {+ parentOffset = offsetParent.offset();+ }++ // Add offsetParent borders+ parentOffset.top += jQuery.css( offsetParent[ 0 ], "borderTopWidth", true );+ parentOffset.left += jQuery.css( offsetParent[ 0 ], "borderLeftWidth", true );+ }++ // Subtract parent offsets and element margins+ return {+ top: offset.top - parentOffset.top - jQuery.css( elem, "marginTop", true ),+ left: offset.left - parentOffset.left - jQuery.css( elem, "marginLeft", true )+ };+ },++ offsetParent: function() {+ return this.map(function() {+ var offsetParent = this.offsetParent || docElem;++ while ( offsetParent && ( !jQuery.nodeName( offsetParent, "html" ) && jQuery.css( offsetParent, "position" ) === "static" ) ) {+ offsetParent = offsetParent.offsetParent;+ }++ return offsetParent || docElem;+ });+ }+});++// Create scrollLeft and scrollTop methods+jQuery.each( { scrollLeft: "pageXOffset", scrollTop: "pageYOffset" }, function( method, prop ) {+ var top = "pageYOffset" === prop;++ jQuery.fn[ method ] = function( val ) {+ return access( this, function( elem, method, val ) {+ var win = getWindow( elem );++ if ( val === undefined ) {+ return win ? win[ prop ] : elem[ method ];+ }++ if ( win ) {+ win.scrollTo(+ !top ? val : window.pageXOffset,+ top ? val : window.pageYOffset+ );++ } else {+ elem[ method ] = val;+ }+ }, method, val, arguments.length, null );+ };+});++// Add the top/left cssHooks using jQuery.fn.position+// Webkit bug: https://bugs.webkit.org/show_bug.cgi?id=29084+// getComputedStyle returns percent when specified for top/left/bottom/right+// rather than make the css module depend on the offset module, we just check for it here+jQuery.each( [ "top", "left" ], function( i, prop ) {+ jQuery.cssHooks[ prop ] = addGetHookIf( support.pixelPosition,+ function( elem, computed ) {+ if ( computed ) {+ computed = curCSS( elem, prop );+ // if curCSS returns percentage, fallback to offset+ return rnumnonpx.test( computed ) ?+ jQuery( elem ).position()[ prop ] + "px" :+ computed;+ }+ }+ );+});+++// Create innerHeight, innerWidth, height, width, outerHeight and outerWidth methods+jQuery.each( { Height: "height", Width: "width" }, function( name, type ) {+ jQuery.each( { padding: "inner" + name, content: type, "": "outer" + name }, function( defaultExtra, funcName ) {+ // margin is only for outerHeight, outerWidth+ jQuery.fn[ funcName ] = function( margin, value ) {+ var chainable = arguments.length && ( defaultExtra || typeof margin !== "boolean" ),+ extra = defaultExtra || ( margin === true || value === true ? "margin" : "border" );++ return access( this, function( elem, type, value ) {+ var doc;++ if ( jQuery.isWindow( elem ) ) {+ // As of 5/8/2012 this will yield incorrect results for Mobile Safari, but there+ // isn't a whole lot we can do. See pull request at this URL for discussion:+ // https://github.com/jquery/jquery/pull/764+ return elem.document.documentElement[ "client" + name ];+ }++ // Get document width or height+ if ( elem.nodeType === 9 ) {+ doc = elem.documentElement;++ // Either scroll[Width/Height] or offset[Width/Height] or client[Width/Height],+ // whichever is greatest+ return Math.max(+ elem.body[ "scroll" + name ], doc[ "scroll" + name ],+ elem.body[ "offset" + name ], doc[ "offset" + name ],+ doc[ "client" + name ]+ );+ }++ return value === undefined ?+ // Get width or height on the element, requesting but not forcing parseFloat+ jQuery.css( elem, type, extra ) :++ // Set width or height on the element+ jQuery.style( elem, type, value, extra );+ }, type, chainable ? margin : undefined, chainable, null );+ };+ });+});+++// The number of elements contained in the matched element set+jQuery.fn.size = function() {+ return this.length;+};++jQuery.fn.andSelf = jQuery.fn.addBack;+++++// Register as a named AMD module, since jQuery can be concatenated with other+// files that may use define, but not via a proper concatenation script that+// understands anonymous AMD modules. A named AMD is safest and most robust+// way to register. Lowercase jquery is used because AMD module names are+// derived from file names, and jQuery is normally delivered in a lowercase+// file name. Do this after creating the global so that if an AMD module wants+// to call noConflict to hide this version of jQuery, it will work.++// Note that for maximum portability, libraries that are not jQuery should+// declare themselves as anonymous modules, and avoid setting a global if an+// AMD loader is present. jQuery is a special case. For more information, see+// https://github.com/jrburke/requirejs/wiki/Updating-existing-libraries#wiki-anon++if ( typeof define === "function" && define.amd ) {+ define( "jquery", [], function() {+ return jQuery;+ });+}+++++var+ // Map over jQuery in case of overwrite+ _jQuery = window.jQuery,++ // Map over the $ in case of overwrite+ _$ = window.$;++jQuery.noConflict = function( deep ) {+ if ( window.$ === jQuery ) {+ window.$ = _$;+ }++ if ( deep && window.jQuery === jQuery ) {+ window.jQuery = _jQuery;+ }++ return jQuery;+};++// Expose jQuery and $ identifiers, even in+// AMD (#7102#comment:10, https://github.com/jquery/jquery/pull/557)+// and CommonJS for browser emulators (#13566)+if ( typeof noGlobal === strundefined ) {+ window.jQuery = window.$ = jQuery;+}+++++return jQuery;++}));
templates/criterion.css view
@@ -22,7 +22,7 @@ color: white; font-size: larger; font-weight: 300;-} +} body:before { /* Opera fix */@@ -78,7 +78,7 @@ opacity: 0.4; } -.citime {+.confinterval { opacity: 0.5; }
+ templates/default.tpl view
@@ -0,0 +1,335 @@+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">+<html>+ <head>+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8">+ <title>criterion report</title>+ <script language="javascript" type="text/javascript">+ {{#include}}js/jquery-2.1.1.min.js{{/include}}+ </script>+ <script language="javascript" type="text/javascript">+ {{#include}}js/jquery.flot-0.8.3.min.js{{/include}}+ </script>+ <script language="javascript" type="text/javascript">+ {{#include}}js/jquery.criterion.js{{/include}}+ </script>+ <style type="text/css">+{{#include}}criterion.css{{/include}}+ </style>+ <!--[if !IE 7]>+ <style type="text/css">+ #wrap {display:table;height:100%}+ </style>+ <![endif]-->+ </head>+ <body>+ <div id="wrap">+ <div id="main" class="body">+ <h1>criterion performance measurements</h1>++<h2>overview</h2>++<p><a href="#grokularation">want to understand this report?</a></p>++<div id="overview" class="ovchart" style="width:900px;height:100px;"></div>++{{#report}}+<h2><a name="b{{number}}">{{name}}</a></h2>+ <table width="100%">+ <tbody>+ <tr>+ <td><div id="kde{{number}}" class="kdechart"+ style="width:450px;height:278px;"></div></td>+ <td><div id="time{{number}}" class="timechart"+ style="width:450px;height:278px;"></div></td>+<!--+ <td><div id="cycle{{number}}" class="cyclechart"+ style="width:300px;height:278px;"></div></td>+-->+ </tr>+ </tbody>+ </table>++ <table>+ <thead class="analysis">+ <th></th>+ <th class="cibound"+ title="{{anMean.estConfidenceLevel}} confidence level">lower bound</th>+ <th>estimate</th>+ <th class="cibound"+ title="{{anMean.estConfidenceLevel}} confidence level">upper bound</th>+ </thead>+ <tbody>+ <tr>+ <td>OLS regression</td>+ <td><span class="confinterval olstimelb{{number}}">xxx</span></td>+ <td><span class="olstimept{{number}}">xxx</span></td>+ <td><span class="confinterval olstimeub{{number}}">xxx</span></td>+ </tr>+ <tr>+ <td>R² goodness-of-fit</td>+ <td><span class="confinterval olsr2lb{{number}}">xxx</span></td>+ <td><span class="olsr2pt{{number}}">xxx</span></td>+ <td><span class="confinterval olsr2ub{{number}}">xxx</span></td>+ </tr>+ <tr>+ <td>Mean execution time</td>+ <td><span class="confinterval citime">{{anMean.estLowerBound}}</span></td>+ <td><span class="time">{{anMean.estPoint}}</span></td>+ <td><span class="confinterval citime">{{anMean.estUpperBound}}</span></td>+ </tr>+ <tr>+ <td>Standard deviation</td>+ <td><span class="confinterval citime">{{anStdDev.estLowerBound}}</span></td>+ <td><span class="time">{{anStdDev.estPoint}}</span></td>+ <td><span class="confinterval citime">{{anStdDev.estUpperBound}}</span></td>+ </tr>+ </tbody>+ </table>++ <span class="outliers">+ <p>Outlying measurements have {{anOutlierVar.ovDesc}}+ (<span class="percent">{{anOutlierVar.ovFraction}}</span>%)+ effect on estimated standard deviation.</p>+ </span>+{{/report}}++ <h2><a name="grokularation">understanding this report</a></h2>++ <p>In this report, each function benchmarked by criterion is assigned+ a section of its own. The charts in each section are active; if+ you hover your mouse over data points and annotations, you will see+ more details.</p>++ <ul>+ <li>The chart on the left is a+ <a href="http://en.wikipedia.org/wiki/Kernel_density_estimation">kernel+ density estimate</a> (also known as a KDE) of time+ measurements. This graphs the probability of any given time+ measurement occurring. A spike indicates that a measurement of a+ particular time occurred; its height indicates how often that+ measurement was repeated.</li>++ <li>The chart on the right is the raw data from which the kernel+ density estimate is built. The <i>x</i> axis indicates the+ number of loop iterations, while the <i>y</i> axis shows measured+ execution time for the given number of loop iterations. The+ line behind the values is the linear regression prediction of+ execution time for a given number of iterations. Ideally, all+ measurements will be on (or very near) this line.</li>+ </ul>++ <p>Under the charts is a small table.+ The first two rows are the results of a linear regression run+ on the measurements displayed in the right-hand chart.</p>++ <ul>+ <li><i>OLS regression</i> indicates the+ time estimated for a single loop iteration using an ordinary+ least-squares regression model. This number is more accurate+ than the <i>mean</i> estimate below it, as it more effectively+ eliminates measurement overhead and other constant factors.</li>+ <li><i>R² goodness-of-fit</i> is a measure of how+ accurately the linear regression model fits the observed+ measurements. If the measurements are not too noisy, R²+ should lie between 0.99 and 1, indicating an excellent fit. If+ the number is below 0.99, something is confounding the accuracy+ of the linear model.</li>+ <li><i>Mean execution time</i> and <i>standard deviation</i> are+ statistics calculated from execution time+ divided by number of iterations.</li>+ </ul>++ <p>We use a statistical technique called+ the <a href="http://en.wikipedia.org/wiki/Bootstrapping_(statistics)">bootstrap</a>+ to provide confidence intervals on our estimates. The+ bootstrap-derived upper and lower bounds on estimates let you see+ how accurate we believe those estimates to be. (Hover the mouse+ over the table headers to see the confidence levels.)</p>++ <p>A noisy benchmarking environment can cause some or many+ measurements to fall far from the mean. These outlying+ measurements can have a significant inflationary effect on the+ estimate of the standard deviation. We calculate and display an+ estimate of the extent to which the standard deviation has been+ inflated by outliers.</p>++<script type="text/javascript">+$(function () {+ function mangulate(rpt) {+ var measured = function(key) {+ var idx = rpt.reportKeys.indexOf(key);+ return rpt.reportMeasured.map(function(r) { return r[idx]; });+ };+ var number = rpt.reportNumber;+ var name = rpt.reportName;+ var mean = rpt.reportAnalysis.anMean.estPoint;+ var iters = measured("iters");+ var times = measured("time");+ var kdetimes = rpt.reportKDEs[0].kdeValues;+ var kdepdf = rpt.reportKDEs[0].kdePDF;++ var meanSecs = mean;+ var units = $.timeUnits(mean);+ var rgrs = rpt.reportAnalysis.anRegress[0];+ var scale = units[0];+ var olsTime = rgrs.regCoeffs.iters;+ $(".olstimept" + number).text(function() {+ return $.renderTime(olsTime.estPoint);+ });+ $(".olstimelb" + number).text(function() {+ return $.renderTime(olsTime.estLowerBound);+ });+ $(".olstimeub" + number).text(function() {+ return $.renderTime(olsTime.estUpperBound);+ });+ $(".olsr2pt" + number).text(function() {+ return rgrs.regRSquare.estPoint.toFixed(3);+ });+ $(".olsr2lb" + number).text(function() {+ return rgrs.regRSquare.estLowerBound.toFixed(3);+ });+ $(".olsr2ub" + number).text(function() {+ return rgrs.regRSquare.estUpperBound.toFixed(3);+ });+ mean *= scale;+ kdetimes = $.scaleBy(scale, kdetimes);+ var kq = $("#kde" + number);+ var k = $.plot(kq,+ [{ label: name + " time densities",+ data: $.zip(kdetimes, kdepdf),+ }],+ { xaxis: { tickFormatter: $.unitFormatter(scale) },+ yaxis: { ticks: false },+ grid: { borderColor: "#777",+ hoverable: true, markings: [ { color: '#6fd3fb',+ lineWidth: 1.5, xaxis: { from: mean, to: mean } } ] },+ });+ var o = k.pointOffset({ x: mean, y: 0});+ kq.append('<div class="meanlegend" title="' + $.renderTime(meanSecs) ++ '" style="position:absolute;left:' + (o.left + 4) ++ 'px;bottom:139px;">mean</div>');+ $.addTooltip("#kde" + number,+ function(secs) { return $.renderTime(secs / scale); });+ var timepairs = new Array(times.length);+ var lastiter = iters[iters.length-1];+ var olspairs = [[0,0], [lastiter, lastiter * scale * olsTime.estPoint]];+ for (var i = 0; i < times.length; i++)+ timepairs[i] = [iters[i],times[i]*scale];+ iterFormatter = function() {+ var denom = 0;+ return function(iters) {+ if (iters == 0)+ return '';+ if (denom > 0)+ return (iters / denom).toFixed();+ var power;+ if (iters >= 1e9) {+ denom = '1e9'; power = '⁹';+ }+ if (iters >= 1e6) {+ denom = '1e6'; power = '⁶';+ }+ else if (iters >= 1e3) {+ denom = '1e3'; power = '³';+ }+ else denom = 1;+ if (denom > 1) {+ iters = (iters / denom).toFixed();+ iters += '×10' + power + ' iters';+ } else {+ iters += ' iters';+ }+ return iters;+ };+ };+ $.plot($("#time" + number),+ [{ label: "regression", data: olspairs,+ lines: { show: true } },+ { label: name + " times", data: timepairs,+ points: { show: true } }],+ { grid: { borderColor: "#777", hoverable: true },+ xaxis: { tickFormatter: iterFormatter() },+ yaxis: { tickFormatter: $.unitFormatter(scale) } });+ $.addTooltip("#time" + number,+ function(iters,secs) {+ return ($.renderTime(secs / scale) + ' / ' ++ iters.toLocaleString() + ' iters');+ });+ if (0) {+ var cyclepairs = new Array(cycles.length);+ for (var i = 0; i < cycles.length; i++)+ cyclepairs[i] = [cycles[i],i];+ $.plot($("#cycle" + number),+ [{ label: name + " cycles",+ data: cyclepairs }],+ { points: { show: true },+ grid: { borderColor: "#777", hoverable: true },+ xaxis: { tickFormatter:+ function(cycles,axis) { return cycles + ' cycles'; }},+ yaxis: { ticks: false },+ });+ $.addTooltip("#cycles" + number, function(x,y) { return x + ' cycles'; });+ }+ };+ var reports = {{json}};+ reports.map(mangulate);++ var benches = [{{#report}}"{{name}}",{{/report}}];+ var ylabels = [{{#report}}[-{{number}},'<a href="#b{{number}}">{{name}}</a>'],{{/report}}];+ var means = $.scaleTimes([{{#report}}{{anMean.estPoint}},{{/report}}]);+ var xs = [];+ var prev = null;+ for (var i = 0; i < means[0].length; i++) {+ var name = benches[i].split(/\//);+ name.pop();+ name = name.join('/');+ if (name != prev) {+ xs.push({ label: name, data: [[means[0][i], -i]]});+ prev = name;+ }+ else+ xs[xs.length-1].data.push([means[0][i],-i]);+ }+ var oq = $("#overview");+ o = $.plot(oq, xs, { bars: { show: true, horizontal: true,+ barWidth: 0.75, align: "center" },+ grid: { borderColor: "#777", hoverable: true },+ legend: { show: xs.length > 1 },+ xaxis: { max: Math.max.apply(undefined,means[0]) * 1.02 },+ yaxis: { ticks: ylabels, tickColor: '#ffffff' } });+ if (benches.length > 3)+ o.getPlaceholder().height(28*benches.length);+ o.resize();+ o.setupGrid();+ o.draw();+ $.addTooltip("#overview", function(x,y) { return $.renderTime(x / means[1]); });+});+$(document).ready(function () {+ $(".time").text(function(_, text) {+ return $.renderTime(text);+ });+ $(".citime").text(function(_, text) {+ return $.renderTime(text);+ });+ $(".percent").text(function(_, text) {+ return (text*100).toFixed(1);+ });+ });+</script>++ </div>+ </div>+ <div id="footer">+ <div class="body">+ <div class="footfirst">+ <h2>colophon</h2>+ <p>This report was created using the+ <a href="http://hackage.haskell.org/package/criterion">criterion</a>+ benchmark execution and performance analysis tool.</p>+ <p>Criterion is developed and maintained+ by <a href="http://www.serpentine.com/blog/">Bryan O'Sullivan</a>.</p>+ </div>+ </div>+ </div>+ </body>+</html>
+ templates/default2.tpl view
@@ -0,0 +1,296 @@+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">+<html>+ <head>+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8">+ <title>criterion report</title>+ <!--[if lte IE 8]>+ <script language="javascript" type="text/javascript">+ {{#include}}js/excanvas-r3.min.js{{/include}}+ </script>+ <![endif]-->+ <script language="javascript" type="text/javascript">+ {{#include}}js/jquery-1.6.4.min.js{{/include}}+ </script>+ <script language="javascript" type="text/javascript">+ {{#include}}js/jquery.flot-0.7.min.js{{/include}}+ </script>+ <script language="javascript" type="text/javascript">+ {{#include}}js/jquery.criterion.js{{/include}}+ </script>+ <style type="text/css">+{{#include}}criterion.css{{/include}}+ </style>+ <!--[if !IE 7]>+ <style type="text/css">+ #wrap {display:table;height:100%}+ </style>+ <![endif]-->+ </head>+ <body>+ <div id="wrap">+ <div id="main" class="body">+ <h1>criterion performance measurements</h1>++<h2>overview</h2>++<p><a href="#grokularation">want to understand this report?</a></p>++<div id="overview" class="ovchart" style="width:900px;height:100px;"></div>++{{#report}}+<h2><a name="b{{number}}">{{name}}</a></h2>+ <table width="100%">+ <tbody>+ <tr>+ <td><div id="kde{{number}}" class="kdechart"+ style="width:450px;height:278px;"></div></td>+ <td><div id="time{{number}}" class="timechart"+ style="width:450px;height:278px;"></div></td>+<!--+ <td><div id="cycle{{number}}" class="cyclechart"+ style="width:300px;height:278px;"></div></td>+-->+ </tr>+ </tbody>+ </table>+ <table>+ <thead class="analysis">+ <th></th>+ <th class="cibound"+ title="{{anMean.estConfidenceLevel}} confidence level">lower bound</th>+ <th>estimate</th>+ <th class="cibound"+ title="{{anMean.estConfidenceLevel}} confidence level">upper bound</th>+ </thead>+ <tbody>+ <tr>+ <td>Mean execution time</td>+ <td><span class="citime">{{anMean.estLowerBound}}</span></td>+ <td><span class="time">{{anMean.estPoint}}</span></td>+ <td><span class="citime">{{anMean.estUpperBound}}</span></td>+ </tr>+ <tr>+ <td>Standard deviation</td>+ <td><span class="citime">{{anStdDev.estLowerBound}}</span></td>+ <td><span class="time">{{anStdDev.estPoint}}</span></td>+ <td><span class="citime">{{anStdDev.estUpperBound}}</span></td>+ </tr>+ </tbody>+ </table>++ <span class="outliers">+ <p>Outlying measurements have {{anOutlierVar.ovDesc}}+ (<span class="percent">{{anOutlierVar.ovFraction}}</span>%)+ effect on estimated standard deviation.</p>+ </span>+{{/report}}++ <h2><a name="grokularation">understanding this report</a></h2>++ <p>In this report, each function benchmarked by criterion is assigned+ a section of its own. In each section, we display two charts, each+ with an <i>x</i> axis that represents measured execution time.+ These charts are active; if you hover your mouse over data points+ and annotations, you will see more details.</p>++ <ul>+ <li>The chart on the left is a+ <a href="http://en.wikipedia.org/wiki/Kernel_density_estimation">kernel+ density estimate</a> (also known as a KDE) of time+ measurements. This graphs the probability of any given time+ measurement occurring. A spike indicates that a measurement of a+ particular time occurred; its height indicates how often that+ measurement was repeated.</li>++ <li>The chart on the right is the raw data from which the kernel+ density estimate is built. Measurements are displayed on+ the <i>x</i> axis in the order in which they occurred. The+ number of iterations of the measurement loop increases with each+ successive measurement.</li>+ </ul>++ <p>Under the charts is a small table displaying the mean and standard+ deviation of the measurements. We use a statistical technique+ called+ the <a href="http://en.wikipedia.org/wiki/Bootstrapping_(statistics)">bootstrap</a>+ to provide confidence intervals on our estimates of these values.+ The bootstrap-derived upper and lower bounds on the mean and+ standard deviation let you see how accurate we believe those+ estimates to be. (Hover the mouse over the table headers to see+ the confidence levels.)</p>++ <p>A noisy benchmarking environment can cause some or many+ measurements to fall far from the mean. These outlying+ measurements can have a significant inflationary effect on the+ estimate of the standard deviation. We calculate and display an+ estimate of the extent to which the standard deviation has been+ inflated by outliers.</p>++<script type="text/javascript">+$(function () {+/*+ function mangulate(number, name, mean, iters, times, cycles,+ kdetimes, kdepdf) */+ function mangulate(rpt) {+ var number = rpt.reportNumber;+ var name = rpt.reportName;+ var mean = rpt.reportAnalysis.anMean.estPoint;+ var measured = function(key) {+ var idx = rpt.reportKeys.indexOf(key);+ return rpt.reportMeasured.map(function(r) { return r[idx]; });+ };+ var iters = measured("iters");+ var times = measured("times");+ var meanSecs = mean;+ var units = $.timeUnits(mean);+ var scale = units[0];+ mean *= scale;+ kdetimes = $.scaleBy(scale, kdetimes);+ var kq = $("#kde" + number);+ var k = $.plot(kq,+ [{ label: name + " time densities",+ data: $.zip(kdetimes, kdepdf),+ }],+ { xaxis: { tickFormatter: $.unitFormatter(scale) },+ yaxis: { ticks: false },+ grid: { borderColor: "#777",+ hoverable: true, markings: [ { color: '#6fd3fb',+ lineWidth: 1.5, xaxis: { from: mean, to: mean } } ] },+ });+ var o = k.pointOffset({ x: mean, y: 0});+ kq.append('<div class="meanlegend" title="' + $.renderTime(meanSecs) ++ '" style="position:absolute;left:' + (o.left + 4) ++ 'px;bottom:139px;">mean</div>');+ $.addTooltip("#kde" + number,+ function(secs) { return $.renderTime(secs / scale); });+ var timepairs = new Array(times.length);+ for (var i = 0; i < times.length; i++)+ timepairs[i] = [iters[i],times[i]*scale];+ iterFormatter = function() {+ var denom = 0;+ return function(iters) {+ if (iters == 0)+ return '';+ if (denom > 0)+ return (iters / denom).toFixed();+ var exp;+ if (iters >= 1e9) {+ denom = '1e9'; exp = 9;+ }+ if (iters >= 1e6) {+ denom = '1e6'; exp = 6;+ }+ else if (iters >= 1e3) {+ denom = '1e3'; exp = 3;+ }+ else denom = 1;+ if (denom > 1) {+ iters = (iters / denom).toFixed();+ iters += '×10<sup>' + exp + '</sup> iters';+ } else {+ iters += ' iters';+ }+ return iters;+ };+ };+ $.plot($("#time" + number),+ [{ label: name + " times",+ data: timepairs }],+ { points: { show: true },+ grid: { borderColor: "#777", hoverable: true },+ xaxis: { tickFormatter: iterFormatter() },+ yaxis: { tickFormatter: $.unitFormatter(scale) },+ });+ $.addTooltip("#time" + number,+ function(iters,secs) {+ return ($.renderTime(secs / scale) + ' / ' ++ iters.toLocaleString() + ' iters');+ });+ if (0) {+ var cyclepairs = new Array(cycles.length);+ for (var i = 0; i < cycles.length; i++)+ cyclepairs[i] = [cycles[i],i];+ $.plot($("#cycle" + number),+ [{ label: name + " cycles",+ data: cyclepairs }],+ { points: { show: true },+ grid: { borderColor: "#777", hoverable: true },+ xaxis: { tickFormatter:+ function(cycles,axis) { return cycles + ' cycles'; }},+ yaxis: { ticks: false },+ });+ $.addTooltip("#cycles" + number, function(x,y) { return x + ' cycles'; });+ }+ };+ var reports = {{json}};+ reports.map(mangulate);+ {{#report}}+ mangulate(/* report number */ {{number}},+ /* report name */ "{{name}}",+ /* estimated mean */ {{anMean.estPoint}},+ /* iterations */ [{{#iters}}{{x}},{{/iters}}],+ /* measured times */ [{{#times}}{{x}},{{/times}}],+ /* measured cycles */ [{{#cycles}}{{x}},{{/cycles}}],+ /* kde times */ [{{#kdetimes}}{{x}},{{/kdetimes}}],+ /* kde pdf */ [{{#kdepdf}}{{x}},{{/kdepdf}}]);+ {{/report}}++ var benches = [{{#report}}"{{name}}",{{/report}}];+ var ylabels = [{{#report}}[-{{number}},'<a href="#b{{number}}">{{name}}</a>'],{{/report}}];+ var means = $.scaleTimes([{{#report}}{{anMean.estPoint}},{{/report}}]);+ var xs = [];+ var prev = null;+ for (var i = 0; i < means[0].length; i++) {+ var name = benches[i].split(/\//);+ name.pop();+ name = name.join('/');+ if (name != prev) {+ xs.push({ label: name, data: [[means[0][i], -i]]});+ prev = name;+ }+ else+ xs[xs.length-1].data.push([means[0][i],-i]);+ }+ var oq = $("#overview");+ o = $.plot(oq, xs, { bars: { show: true, horizontal: true,+ barWidth: 0.75, align: "center" },+ grid: { borderColor: "#777", hoverable: true },+ legend: { show: xs.length > 1 },+ xaxis: { max: Math.max.apply(undefined,means[0]) * 1.02 },+ yaxis: { ticks: ylabels, tickColor: '#ffffff' } });+ if (benches.length > 3)+ o.getPlaceholder().height(28*benches.length);+ o.resize();+ o.setupGrid();+ o.draw();+ $.addTooltip("#overview", function(x,y) { return $.renderTime(x / means[1]); });+});+$(document).ready(function () {+ $(".time").text(function(_, text) {+ return $.renderTime(text);+ });+ $(".citime").text(function(_, text) {+ return $.renderTime(text);+ });+ $(".percent").text(function(_, text) {+ return (text*100).toFixed(1);+ });+ });+</script>++ </div>+ </div>+ <div id="footer">+ <div class="body">+ <div class="footfirst">+ <h2>colophon</h2>+ <p>This report was created using the+ <a href="http://hackage.haskell.org/package/criterion">criterion</a>+ benchmark execution and performance analysis tool.</p>+ <p>Criterion is developed and maintained+ by <a href="http://www.serpentine.com/blog/">Bryan O'Sullivan</a>.</p>+ </div>+ </div>+ </div>+ </body>+</html>
− templates/js/excanvas-r3.min.js
@@ -1,1 +0,0 @@-if(!document.createElement("canvas").getContext){(function(){var z=Math;var K=z.round;var J=z.sin;var U=z.cos;var b=z.abs;var k=z.sqrt;var D=10;var F=D/2;function T(){return this.context_||(this.context_=new W(this))}var O=Array.prototype.slice;function G(i,j,m){var Z=O.call(arguments,2);return function(){return i.apply(j,Z.concat(O.call(arguments)))}}function AD(Z){return String(Z).replace(/&/g,"&").replace(/"/g,""")}function r(i){if(!i.namespaces.g_vml_){i.namespaces.add("g_vml_","urn:schemas-microsoft-com:vml","#default#VML")}if(!i.namespaces.g_o_){i.namespaces.add("g_o_","urn:schemas-microsoft-com:office:office","#default#VML")}if(!i.styleSheets.ex_canvas_){var Z=i.createStyleSheet();Z.owningElement.id="ex_canvas_";Z.cssText="canvas{display:inline-block;overflow:hidden;text-align:left;width:300px;height:150px}"}}r(document);var E={init:function(Z){if(/MSIE/.test(navigator.userAgent)&&!window.opera){var i=Z||document;i.createElement("canvas");i.attachEvent("onreadystatechange",G(this.init_,this,i))}},init_:function(m){var j=m.getElementsByTagName("canvas");for(var Z=0;Z<j.length;Z++){this.initElement(j[Z])}},initElement:function(i){if(!i.getContext){i.getContext=T;r(i.ownerDocument);i.innerHTML="";i.attachEvent("onpropertychange",S);i.attachEvent("onresize",w);var Z=i.attributes;if(Z.width&&Z.width.specified){i.style.width=Z.width.nodeValue+"px"}else{i.width=i.clientWidth}if(Z.height&&Z.height.specified){i.style.height=Z.height.nodeValue+"px"}else{i.height=i.clientHeight}}return i}};function S(i){var Z=i.srcElement;switch(i.propertyName){case"width":Z.getContext().clearRect();Z.style.width=Z.attributes.width.nodeValue+"px";Z.firstChild.style.width=Z.clientWidth+"px";break;case"height":Z.getContext().clearRect();Z.style.height=Z.attributes.height.nodeValue+"px";Z.firstChild.style.height=Z.clientHeight+"px";break}}function w(i){var Z=i.srcElement;if(Z.firstChild){Z.firstChild.style.width=Z.clientWidth+"px";Z.firstChild.style.height=Z.clientHeight+"px"}}E.init();var I=[];for(var AC=0;AC<16;AC++){for(var AB=0;AB<16;AB++){I[AC*16+AB]=AC.toString(16)+AB.toString(16)}}function V(){return[[1,0,0],[0,1,0],[0,0,1]]}function d(m,j){var i=V();for(var Z=0;Z<3;Z++){for(var AF=0;AF<3;AF++){var p=0;for(var AE=0;AE<3;AE++){p+=m[Z][AE]*j[AE][AF]}i[Z][AF]=p}}return i}function Q(i,Z){Z.fillStyle=i.fillStyle;Z.lineCap=i.lineCap;Z.lineJoin=i.lineJoin;Z.lineWidth=i.lineWidth;Z.miterLimit=i.miterLimit;Z.shadowBlur=i.shadowBlur;Z.shadowColor=i.shadowColor;Z.shadowOffsetX=i.shadowOffsetX;Z.shadowOffsetY=i.shadowOffsetY;Z.strokeStyle=i.strokeStyle;Z.globalAlpha=i.globalAlpha;Z.font=i.font;Z.textAlign=i.textAlign;Z.textBaseline=i.textBaseline;Z.arcScaleX_=i.arcScaleX_;Z.arcScaleY_=i.arcScaleY_;Z.lineScale_=i.lineScale_}var B={aliceblue:"#F0F8FF",antiquewhite:"#FAEBD7",aquamarine:"#7FFFD4",azure:"#F0FFFF",beige:"#F5F5DC",bisque:"#FFE4C4",black:"#000000",blanchedalmond:"#FFEBCD",blueviolet:"#8A2BE2",brown:"#A52A2A",burlywood:"#DEB887",cadetblue:"#5F9EA0",chartreuse:"#7FFF00",chocolate:"#D2691E",coral:"#FF7F50",cornflowerblue:"#6495ED",cornsilk:"#FFF8DC",crimson:"#DC143C",cyan:"#00FFFF",darkblue:"#00008B",darkcyan:"#008B8B",darkgoldenrod:"#B8860B",darkgray:"#A9A9A9",darkgreen:"#006400",darkgrey:"#A9A9A9",darkkhaki:"#BDB76B",darkmagenta:"#8B008B",darkolivegreen:"#556B2F",darkorange:"#FF8C00",darkorchid:"#9932CC",darkred:"#8B0000",darksalmon:"#E9967A",darkseagreen:"#8FBC8F",darkslateblue:"#483D8B",darkslategray:"#2F4F4F",darkslategrey:"#2F4F4F",darkturquoise:"#00CED1",darkviolet:"#9400D3",deeppink:"#FF1493",deepskyblue:"#00BFFF",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1E90FF",firebrick:"#B22222",floralwhite:"#FFFAF0",forestgreen:"#228B22",gainsboro:"#DCDCDC",ghostwhite:"#F8F8FF",gold:"#FFD700",goldenrod:"#DAA520",grey:"#808080",greenyellow:"#ADFF2F",honeydew:"#F0FFF0",hotpink:"#FF69B4",indianred:"#CD5C5C",indigo:"#4B0082",ivory:"#FFFFF0",khaki:"#F0E68C",lavender:"#E6E6FA",lavenderblush:"#FFF0F5",lawngreen:"#7CFC00",lemonchiffon:"#FFFACD",lightblue:"#ADD8E6",lightcoral:"#F08080",lightcyan:"#E0FFFF",lightgoldenrodyellow:"#FAFAD2",lightgreen:"#90EE90",lightgrey:"#D3D3D3",lightpink:"#FFB6C1",lightsalmon:"#FFA07A",lightseagreen:"#20B2AA",lightskyblue:"#87CEFA",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#B0C4DE",lightyellow:"#FFFFE0",limegreen:"#32CD32",linen:"#FAF0E6",magenta:"#FF00FF",mediumaquamarine:"#66CDAA",mediumblue:"#0000CD",mediumorchid:"#BA55D3",mediumpurple:"#9370DB",mediumseagreen:"#3CB371",mediumslateblue:"#7B68EE",mediumspringgreen:"#00FA9A",mediumturquoise:"#48D1CC",mediumvioletred:"#C71585",midnightblue:"#191970",mintcream:"#F5FFFA",mistyrose:"#FFE4E1",moccasin:"#FFE4B5",navajowhite:"#FFDEAD",oldlace:"#FDF5E6",olivedrab:"#6B8E23",orange:"#FFA500",orangered:"#FF4500",orchid:"#DA70D6",palegoldenrod:"#EEE8AA",palegreen:"#98FB98",paleturquoise:"#AFEEEE",palevioletred:"#DB7093",papayawhip:"#FFEFD5",peachpuff:"#FFDAB9",peru:"#CD853F",pink:"#FFC0CB",plum:"#DDA0DD",powderblue:"#B0E0E6",rosybrown:"#BC8F8F",royalblue:"#4169E1",saddlebrown:"#8B4513",salmon:"#FA8072",sandybrown:"#F4A460",seagreen:"#2E8B57",seashell:"#FFF5EE",sienna:"#A0522D",skyblue:"#87CEEB",slateblue:"#6A5ACD",slategray:"#708090",slategrey:"#708090",snow:"#FFFAFA",springgreen:"#00FF7F",steelblue:"#4682B4",tan:"#D2B48C",thistle:"#D8BFD8",tomato:"#FF6347",turquoise:"#40E0D0",violet:"#EE82EE",wheat:"#F5DEB3",whitesmoke:"#F5F5F5",yellowgreen:"#9ACD32"};function g(i){var m=i.indexOf("(",3);var Z=i.indexOf(")",m+1);var j=i.substring(m+1,Z).split(",");if(j.length==4&&i.substr(3,1)=="a"){alpha=Number(j[3])}else{j[3]=1}return j}function C(Z){return parseFloat(Z)/100}function N(i,j,Z){return Math.min(Z,Math.max(j,i))}function c(AF){var j,i,Z;h=parseFloat(AF[0])/360%360;if(h<0){h++}s=N(C(AF[1]),0,1);l=N(C(AF[2]),0,1);if(s==0){j=i=Z=l}else{var m=l<0.5?l*(1+s):l+s-l*s;var AE=2*l-m;j=A(AE,m,h+1/3);i=A(AE,m,h);Z=A(AE,m,h-1/3)}return"#"+I[Math.floor(j*255)]+I[Math.floor(i*255)]+I[Math.floor(Z*255)]}function A(i,Z,j){if(j<0){j++}if(j>1){j--}if(6*j<1){return i+(Z-i)*6*j}else{if(2*j<1){return Z}else{if(3*j<2){return i+(Z-i)*(2/3-j)*6}else{return i}}}}function Y(Z){var AE,p=1;Z=String(Z);if(Z.charAt(0)=="#"){AE=Z}else{if(/^rgb/.test(Z)){var m=g(Z);var AE="#",AF;for(var j=0;j<3;j++){if(m[j].indexOf("%")!=-1){AF=Math.floor(C(m[j])*255)}else{AF=Number(m[j])}AE+=I[N(AF,0,255)]}p=m[3]}else{if(/^hsl/.test(Z)){var m=g(Z);AE=c(m);p=m[3]}else{AE=B[Z]||Z}}}return{color:AE,alpha:p}}var L={style:"normal",variant:"normal",weight:"normal",size:10,family:"sans-serif"};var f={};function X(Z){if(f[Z]){return f[Z]}var m=document.createElement("div");var j=m.style;try{j.font=Z}catch(i){}return f[Z]={style:j.fontStyle||L.style,variant:j.fontVariant||L.variant,weight:j.fontWeight||L.weight,size:j.fontSize||L.size,family:j.fontFamily||L.family}}function P(j,i){var Z={};for(var AF in j){Z[AF]=j[AF]}var AE=parseFloat(i.currentStyle.fontSize),m=parseFloat(j.size);if(typeof j.size=="number"){Z.size=j.size}else{if(j.size.indexOf("px")!=-1){Z.size=m}else{if(j.size.indexOf("em")!=-1){Z.size=AE*m}else{if(j.size.indexOf("%")!=-1){Z.size=(AE/100)*m}else{if(j.size.indexOf("pt")!=-1){Z.size=m/0.75}else{Z.size=AE}}}}}Z.size*=0.981;return Z}function AA(Z){return Z.style+" "+Z.variant+" "+Z.weight+" "+Z.size+"px "+Z.family}function t(Z){switch(Z){case"butt":return"flat";case"round":return"round";case"square":default:return"square"}}function W(i){this.m_=V();this.mStack_=[];this.aStack_=[];this.currentPath_=[];this.strokeStyle="#000";this.fillStyle="#000";this.lineWidth=1;this.lineJoin="miter";this.lineCap="butt";this.miterLimit=D*1;this.globalAlpha=1;this.font="10px sans-serif";this.textAlign="left";this.textBaseline="alphabetic";this.canvas=i;var Z=i.ownerDocument.createElement("div");Z.style.width=i.clientWidth+"px";Z.style.height=i.clientHeight+"px";Z.style.overflow="hidden";Z.style.position="absolute";i.appendChild(Z);this.element_=Z;this.arcScaleX_=1;this.arcScaleY_=1;this.lineScale_=1}var M=W.prototype;M.clearRect=function(){if(this.textMeasureEl_){this.textMeasureEl_.removeNode(true);this.textMeasureEl_=null}this.element_.innerHTML=""};M.beginPath=function(){this.currentPath_=[]};M.moveTo=function(i,Z){var j=this.getCoords_(i,Z);this.currentPath_.push({type:"moveTo",x:j.x,y:j.y});this.currentX_=j.x;this.currentY_=j.y};M.lineTo=function(i,Z){var j=this.getCoords_(i,Z);this.currentPath_.push({type:"lineTo",x:j.x,y:j.y});this.currentX_=j.x;this.currentY_=j.y};M.bezierCurveTo=function(j,i,AI,AH,AG,AE){var Z=this.getCoords_(AG,AE);var AF=this.getCoords_(j,i);var m=this.getCoords_(AI,AH);e(this,AF,m,Z)};function e(Z,m,j,i){Z.currentPath_.push({type:"bezierCurveTo",cp1x:m.x,cp1y:m.y,cp2x:j.x,cp2y:j.y,x:i.x,y:i.y});Z.currentX_=i.x;Z.currentY_=i.y}M.quadraticCurveTo=function(AG,j,i,Z){var AF=this.getCoords_(AG,j);var AE=this.getCoords_(i,Z);var AH={x:this.currentX_+2/3*(AF.x-this.currentX_),y:this.currentY_+2/3*(AF.y-this.currentY_)};var m={x:AH.x+(AE.x-this.currentX_)/3,y:AH.y+(AE.y-this.currentY_)/3};e(this,AH,m,AE)};M.arc=function(AJ,AH,AI,AE,i,j){AI*=D;var AN=j?"at":"wa";var AK=AJ+U(AE)*AI-F;var AM=AH+J(AE)*AI-F;var Z=AJ+U(i)*AI-F;var AL=AH+J(i)*AI-F;if(AK==Z&&!j){AK+=0.125}var m=this.getCoords_(AJ,AH);var AG=this.getCoords_(AK,AM);var AF=this.getCoords_(Z,AL);this.currentPath_.push({type:AN,x:m.x,y:m.y,radius:AI,xStart:AG.x,yStart:AG.y,xEnd:AF.x,yEnd:AF.y})};M.rect=function(j,i,Z,m){this.moveTo(j,i);this.lineTo(j+Z,i);this.lineTo(j+Z,i+m);this.lineTo(j,i+m);this.closePath()};M.strokeRect=function(j,i,Z,m){var p=this.currentPath_;this.beginPath();this.moveTo(j,i);this.lineTo(j+Z,i);this.lineTo(j+Z,i+m);this.lineTo(j,i+m);this.closePath();this.stroke();this.currentPath_=p};M.fillRect=function(j,i,Z,m){var p=this.currentPath_;this.beginPath();this.moveTo(j,i);this.lineTo(j+Z,i);this.lineTo(j+Z,i+m);this.lineTo(j,i+m);this.closePath();this.fill();this.currentPath_=p};M.createLinearGradient=function(i,m,Z,j){var p=new v("gradient");p.x0_=i;p.y0_=m;p.x1_=Z;p.y1_=j;return p};M.createRadialGradient=function(m,AE,j,i,p,Z){var AF=new v("gradientradial");AF.x0_=m;AF.y0_=AE;AF.r0_=j;AF.x1_=i;AF.y1_=p;AF.r1_=Z;return AF};M.drawImage=function(AO,j){var AH,AF,AJ,AV,AM,AK,AQ,AX;var AI=AO.runtimeStyle.width;var AN=AO.runtimeStyle.height;AO.runtimeStyle.width="auto";AO.runtimeStyle.height="auto";var AG=AO.width;var AT=AO.height;AO.runtimeStyle.width=AI;AO.runtimeStyle.height=AN;if(arguments.length==3){AH=arguments[1];AF=arguments[2];AM=AK=0;AQ=AJ=AG;AX=AV=AT}else{if(arguments.length==5){AH=arguments[1];AF=arguments[2];AJ=arguments[3];AV=arguments[4];AM=AK=0;AQ=AG;AX=AT}else{if(arguments.length==9){AM=arguments[1];AK=arguments[2];AQ=arguments[3];AX=arguments[4];AH=arguments[5];AF=arguments[6];AJ=arguments[7];AV=arguments[8]}else{throw Error("Invalid number of arguments")}}}var AW=this.getCoords_(AH,AF);var m=AQ/2;var i=AX/2;var AU=[];var Z=10;var AE=10;AU.push(" <g_vml_:group",' coordsize="',D*Z,",",D*AE,'"',' coordorigin="0,0"',' style="width:',Z,"px;height:",AE,"px;position:absolute;");if(this.m_[0][0]!=1||this.m_[0][1]||this.m_[1][1]!=1||this.m_[1][0]){var p=[];p.push("M11=",this.m_[0][0],",","M12=",this.m_[1][0],",","M21=",this.m_[0][1],",","M22=",this.m_[1][1],",","Dx=",K(AW.x/D),",","Dy=",K(AW.y/D),"");var AS=AW;var AR=this.getCoords_(AH+AJ,AF);var AP=this.getCoords_(AH,AF+AV);var AL=this.getCoords_(AH+AJ,AF+AV);AS.x=z.max(AS.x,AR.x,AP.x,AL.x);AS.y=z.max(AS.y,AR.y,AP.y,AL.y);AU.push("padding:0 ",K(AS.x/D),"px ",K(AS.y/D),"px 0;filter:progid:DXImageTransform.Microsoft.Matrix(",p.join(""),", sizingmethod='clip');")}else{AU.push("top:",K(AW.y/D),"px;left:",K(AW.x/D),"px;")}AU.push(' ">','<g_vml_:image src="',AO.src,'"',' style="width:',D*AJ,"px;"," height:",D*AV,'px"',' cropleft="',AM/AG,'"',' croptop="',AK/AT,'"',' cropright="',(AG-AM-AQ)/AG,'"',' cropbottom="',(AT-AK-AX)/AT,'"'," />","</g_vml_:group>");this.element_.insertAdjacentHTML("BeforeEnd",AU.join(""))};M.stroke=function(AM){var m=10;var AN=10;var AE=5000;var AG={x:null,y:null};var AL={x:null,y:null};for(var AH=0;AH<this.currentPath_.length;AH+=AE){var AK=[];var AF=false;AK.push("<g_vml_:shape",' filled="',!!AM,'"',' style="position:absolute;width:',m,"px;height:",AN,'px;"',' coordorigin="0,0"',' coordsize="',D*m,",",D*AN,'"',' stroked="',!AM,'"',' path="');var AO=false;for(var AI=AH;AI<Math.min(AH+AE,this.currentPath_.length);AI++){if(AI%AE==0&&AI>0){AK.push(" m ",K(this.currentPath_[AI-1].x),",",K(this.currentPath_[AI-1].y))}var Z=this.currentPath_[AI];var AJ;switch(Z.type){case"moveTo":AJ=Z;AK.push(" m ",K(Z.x),",",K(Z.y));break;case"lineTo":AK.push(" l ",K(Z.x),",",K(Z.y));break;case"close":AK.push(" x ");Z=null;break;case"bezierCurveTo":AK.push(" c ",K(Z.cp1x),",",K(Z.cp1y),",",K(Z.cp2x),",",K(Z.cp2y),",",K(Z.x),",",K(Z.y));break;case"at":case"wa":AK.push(" ",Z.type," ",K(Z.x-this.arcScaleX_*Z.radius),",",K(Z.y-this.arcScaleY_*Z.radius)," ",K(Z.x+this.arcScaleX_*Z.radius),",",K(Z.y+this.arcScaleY_*Z.radius)," ",K(Z.xStart),",",K(Z.yStart)," ",K(Z.xEnd),",",K(Z.yEnd));break}if(Z){if(AG.x==null||Z.x<AG.x){AG.x=Z.x}if(AL.x==null||Z.x>AL.x){AL.x=Z.x}if(AG.y==null||Z.y<AG.y){AG.y=Z.y}if(AL.y==null||Z.y>AL.y){AL.y=Z.y}}}AK.push(' ">');if(!AM){R(this,AK)}else{a(this,AK,AG,AL)}AK.push("</g_vml_:shape>");this.element_.insertAdjacentHTML("beforeEnd",AK.join(""))}};function R(j,AE){var i=Y(j.strokeStyle);var m=i.color;var p=i.alpha*j.globalAlpha;var Z=j.lineScale_*j.lineWidth;if(Z<1){p*=Z}AE.push("<g_vml_:stroke",' opacity="',p,'"',' joinstyle="',j.lineJoin,'"',' miterlimit="',j.miterLimit,'"',' endcap="',t(j.lineCap),'"',' weight="',Z,'px"',' color="',m,'" />')}function a(AO,AG,Ah,AP){var AH=AO.fillStyle;var AY=AO.arcScaleX_;var AX=AO.arcScaleY_;var Z=AP.x-Ah.x;var m=AP.y-Ah.y;if(AH instanceof v){var AL=0;var Ac={x:0,y:0};var AU=0;var AK=1;if(AH.type_=="gradient"){var AJ=AH.x0_/AY;var j=AH.y0_/AX;var AI=AH.x1_/AY;var Aj=AH.y1_/AX;var Ag=AO.getCoords_(AJ,j);var Af=AO.getCoords_(AI,Aj);var AE=Af.x-Ag.x;var p=Af.y-Ag.y;AL=Math.atan2(AE,p)*180/Math.PI;if(AL<0){AL+=360}if(AL<0.000001){AL=0}}else{var Ag=AO.getCoords_(AH.x0_,AH.y0_);Ac={x:(Ag.x-Ah.x)/Z,y:(Ag.y-Ah.y)/m};Z/=AY*D;m/=AX*D;var Aa=z.max(Z,m);AU=2*AH.r0_/Aa;AK=2*AH.r1_/Aa-AU}var AS=AH.colors_;AS.sort(function(Ak,i){return Ak.offset-i.offset});var AN=AS.length;var AR=AS[0].color;var AQ=AS[AN-1].color;var AW=AS[0].alpha*AO.globalAlpha;var AV=AS[AN-1].alpha*AO.globalAlpha;var Ab=[];for(var Ae=0;Ae<AN;Ae++){var AM=AS[Ae];Ab.push(AM.offset*AK+AU+" "+AM.color)}AG.push('<g_vml_:fill type="',AH.type_,'"',' method="none" focus="100%"',' color="',AR,'"',' color2="',AQ,'"',' colors="',Ab.join(","),'"',' opacity="',AV,'"',' g_o_:opacity2="',AW,'"',' angle="',AL,'"',' focusposition="',Ac.x,",",Ac.y,'" />')}else{if(AH instanceof u){if(Z&&m){var AF=-Ah.x;var AZ=-Ah.y;AG.push("<g_vml_:fill",' position="',AF/Z*AY*AY,",",AZ/m*AX*AX,'"',' type="tile"',' src="',AH.src_,'" />')}}else{var Ai=Y(AO.fillStyle);var AT=Ai.color;var Ad=Ai.alpha*AO.globalAlpha;AG.push('<g_vml_:fill color="',AT,'" opacity="',Ad,'" />')}}}M.fill=function(){this.stroke(true)};M.closePath=function(){this.currentPath_.push({type:"close"})};M.getCoords_=function(j,i){var Z=this.m_;return{x:D*(j*Z[0][0]+i*Z[1][0]+Z[2][0])-F,y:D*(j*Z[0][1]+i*Z[1][1]+Z[2][1])-F}};M.save=function(){var Z={};Q(this,Z);this.aStack_.push(Z);this.mStack_.push(this.m_);this.m_=d(V(),this.m_)};M.restore=function(){if(this.aStack_.length){Q(this.aStack_.pop(),this);this.m_=this.mStack_.pop()}};function H(Z){return isFinite(Z[0][0])&&isFinite(Z[0][1])&&isFinite(Z[1][0])&&isFinite(Z[1][1])&&isFinite(Z[2][0])&&isFinite(Z[2][1])}function y(i,Z,j){if(!H(Z)){return }i.m_=Z;if(j){var p=Z[0][0]*Z[1][1]-Z[0][1]*Z[1][0];i.lineScale_=k(b(p))}}M.translate=function(j,i){var Z=[[1,0,0],[0,1,0],[j,i,1]];y(this,d(Z,this.m_),false)};M.rotate=function(i){var m=U(i);var j=J(i);var Z=[[m,j,0],[-j,m,0],[0,0,1]];y(this,d(Z,this.m_),false)};M.scale=function(j,i){this.arcScaleX_*=j;this.arcScaleY_*=i;var Z=[[j,0,0],[0,i,0],[0,0,1]];y(this,d(Z,this.m_),true)};M.transform=function(p,m,AF,AE,i,Z){var j=[[p,m,0],[AF,AE,0],[i,Z,1]];y(this,d(j,this.m_),true)};M.setTransform=function(AE,p,AG,AF,j,i){var Z=[[AE,p,0],[AG,AF,0],[j,i,1]];y(this,Z,true)};M.drawText_=function(AK,AI,AH,AN,AG){var AM=this.m_,AQ=1000,i=0,AP=AQ,AF={x:0,y:0},AE=[];var Z=P(X(this.font),this.element_);var j=AA(Z);var AR=this.element_.currentStyle;var p=this.textAlign.toLowerCase();switch(p){case"left":case"center":case"right":break;case"end":p=AR.direction=="ltr"?"right":"left";break;case"start":p=AR.direction=="rtl"?"right":"left";break;default:p="left"}switch(this.textBaseline){case"hanging":case"top":AF.y=Z.size/1.75;break;case"middle":break;default:case null:case"alphabetic":case"ideographic":case"bottom":AF.y=-Z.size/2.25;break}switch(p){case"right":i=AQ;AP=0.05;break;case"center":i=AP=AQ/2;break}var AO=this.getCoords_(AI+AF.x,AH+AF.y);AE.push('<g_vml_:line from="',-i,' 0" to="',AP,' 0.05" ',' coordsize="100 100" coordorigin="0 0"',' filled="',!AG,'" stroked="',!!AG,'" style="position:absolute;width:1px;height:1px;">');if(AG){R(this,AE)}else{a(this,AE,{x:-i,y:0},{x:AP,y:Z.size})}var AL=AM[0][0].toFixed(3)+","+AM[1][0].toFixed(3)+","+AM[0][1].toFixed(3)+","+AM[1][1].toFixed(3)+",0,0";var AJ=K(AO.x/D)+","+K(AO.y/D);AE.push('<g_vml_:skew on="t" matrix="',AL,'" ',' offset="',AJ,'" origin="',i,' 0" />','<g_vml_:path textpathok="true" />','<g_vml_:textpath on="true" string="',AD(AK),'" style="v-text-align:',p,";font:",AD(j),'" /></g_vml_:line>');this.element_.insertAdjacentHTML("beforeEnd",AE.join(""))};M.fillText=function(j,Z,m,i){this.drawText_(j,Z,m,i,false)};M.strokeText=function(j,Z,m,i){this.drawText_(j,Z,m,i,true)};M.measureText=function(j){if(!this.textMeasureEl_){var Z='<span style="position:absolute;top:-20000px;left:0;padding:0;margin:0;border:none;white-space:pre;"></span>';this.element_.insertAdjacentHTML("beforeEnd",Z);this.textMeasureEl_=this.element_.lastChild}var i=this.element_.ownerDocument;this.textMeasureEl_.innerHTML="";this.textMeasureEl_.style.font=this.font;this.textMeasureEl_.appendChild(i.createTextNode(j));return{width:this.textMeasureEl_.offsetWidth}};M.clip=function(){};M.arcTo=function(){};M.createPattern=function(i,Z){return new u(i,Z)};function v(Z){this.type_=Z;this.x0_=0;this.y0_=0;this.r0_=0;this.x1_=0;this.y1_=0;this.r1_=0;this.colors_=[]}v.prototype.addColorStop=function(i,Z){Z=Y(Z);this.colors_.push({offset:i,color:Z.color,alpha:Z.alpha})};function u(i,Z){q(i);switch(Z){case"repeat":case null:case"":this.repetition_="repeat";break;case"repeat-x":case"repeat-y":case"no-repeat":this.repetition_=Z;break;default:n("SYNTAX_ERR")}this.src_=i.src;this.width_=i.width;this.height_=i.height}function n(Z){throw new o(Z)}function q(Z){if(!Z||Z.nodeType!=1||Z.tagName!="IMG"){n("TYPE_MISMATCH_ERR")}if(Z.readyState!="complete"){n("INVALID_STATE_ERR")}}function o(Z){this.code=this[Z];this.message=Z+": DOM Exception "+this.code}var x=o.prototype=new Error;x.INDEX_SIZE_ERR=1;x.DOMSTRING_SIZE_ERR=2;x.HIERARCHY_REQUEST_ERR=3;x.WRONG_DOCUMENT_ERR=4;x.INVALID_CHARACTER_ERR=5;x.NO_DATA_ALLOWED_ERR=6;x.NO_MODIFICATION_ALLOWED_ERR=7;x.NOT_FOUND_ERR=8;x.NOT_SUPPORTED_ERR=9;x.INUSE_ATTRIBUTE_ERR=10;x.INVALID_STATE_ERR=11;x.SYNTAX_ERR=12;x.INVALID_MODIFICATION_ERR=13;x.NAMESPACE_ERR=14;x.INVALID_ACCESS_ERR=15;x.VALIDATION_ERR=16;x.TYPE_MISMATCH_ERR=17;G_vmlCanvasManager=E;CanvasRenderingContext2D=W;CanvasGradient=v;CanvasPattern=u;DOMException=o})()};
− templates/js/jquery-1.6.4.min.js
@@ -1,4 +0,0 @@-/*! jQuery v1.6.4 http://jquery.com/ | http://jquery.org/license */-(function(a,b){function cu(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cr(a){if(!cg[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){ch||(ch=c.createElement("iframe"),ch.frameBorder=ch.width=ch.height=0),b.appendChild(ch);if(!ci||!ch.createElement)ci=(ch.contentWindow||ch.contentDocument).document,ci.write((c.compatMode==="CSS1Compat"?"<!doctype html>":"")+"<html><body>"),ci.close();d=ci.createElement(a),ci.body.appendChild(d),e=f.css(d,"display"),b.removeChild(ch)}cg[a]=e}return cg[a]}function cq(a,b){var c={};f.each(cm.concat.apply([],cm.slice(0,b)),function(){c[this]=a});return c}function cp(){cn=b}function co(){setTimeout(cp,0);return cn=f.now()}function cf(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function ce(){try{return new a.XMLHttpRequest}catch(b){}}function b$(a,c){a.dataFilter&&(c=a.dataFilter(c,a.dataType));var d=a.dataTypes,e={},g,h,i=d.length,j,k=d[0],l,m,n,o,p;for(g=1;g<i;g++){if(g===1)for(h in a.converters)typeof h=="string"&&(e[h.toLowerCase()]=a.converters[h]);l=k,k=d[g];if(k==="*")k=l;else if(l!=="*"&&l!==k){m=l+" "+k,n=e[m]||e["* "+k];if(!n){p=b;for(o in e){j=o.split(" ");if(j[0]===l||j[0]==="*"){p=e[j[1]+" "+k];if(p){o=e[o],o===!0?n=p:p===!0&&(n=o);break}}}}!n&&!p&&f.error("No conversion from "+m.replace(" "," to ")),n!==!0&&(c=n?n(c):p(o(c)))}}return c}function bZ(a,c,d){var e=a.contents,f=a.dataTypes,g=a.responseFields,h,i,j,k;for(i in g)i in d&&(c[g[i]]=d[i]);while(f[0]==="*")f.shift(),h===b&&(h=a.mimeType||c.getResponseHeader("content-type"));if(h)for(i in e)if(e[i]&&e[i].test(h)){f.unshift(i);break}if(f[0]in d)j=f[0];else{for(i in d){if(!f[0]||a.converters[i+" "+f[0]]){j=i;break}k||(k=i)}j=j||k}if(j){j!==f[0]&&f.unshift(j);return d[j]}}function bY(a,b,c,d){if(f.isArray(b))f.each(b,function(b,e){c||bA.test(a)?d(a,e):bY(a+"["+(typeof e=="object"||f.isArray(e)?b:"")+"]",e,c,d)});else if(!c&&b!=null&&typeof b=="object")for(var e in b)bY(a+"["+e+"]",b[e],c,d);else d(a,b)}function bX(a,c){var d,e,g=f.ajaxSettings.flatOptions||{};for(d in c)c[d]!==b&&((g[d]?a:e||(e={}))[d]=c[d]);e&&f.extend(!0,a,e)}function bW(a,c,d,e,f,g){f=f||c.dataTypes[0],g=g||{},g[f]=!0;var h=a[f],i=0,j=h?h.length:0,k=a===bP,l;for(;i<j&&(k||!l);i++)l=h[i](c,d,e),typeof l=="string"&&(!k||g[l]?l=b:(c.dataTypes.unshift(l),l=bW(a,c,d,e,l,g)));(k||!l)&&!g["*"]&&(l=bW(a,c,d,e,"*",g));return l}function bV(a){return function(b,c){typeof b!="string"&&(c=b,b="*");if(f.isFunction(c)){var d=b.toLowerCase().split(bL),e=0,g=d.length,h,i,j;for(;e<g;e++)h=d[e],j=/^\+/.test(h),j&&(h=h.substr(1)||"*"),i=a[h]=a[h]||[],i[j?"unshift":"push"](c)}}}function by(a,b,c){var d=b==="width"?a.offsetWidth:a.offsetHeight,e=b==="width"?bt:bu;if(d>0){c!=="border"&&f.each(e,function(){c||(d-=parseFloat(f.css(a,"padding"+this))||0),c==="margin"?d+=parseFloat(f.css(a,c+this))||0:d-=parseFloat(f.css(a,"border"+this+"Width"))||0});return d+"px"}d=bv(a,b,b);if(d<0||d==null)d=a.style[b]||0;d=parseFloat(d)||0,c&&f.each(e,function(){d+=parseFloat(f.css(a,"padding"+this))||0,c!=="padding"&&(d+=parseFloat(f.css(a,"border"+this+"Width"))||0),c==="margin"&&(d+=parseFloat(f.css(a,c+this))||0)});return d+"px"}function bl(a,b){b.src?f.ajax({url:b.src,async:!1,dataType:"script"}):f.globalEval((b.text||b.textContent||b.innerHTML||"").replace(bd,"/*$0*/")),b.parentNode&&b.parentNode.removeChild(b)}function bk(a){f.nodeName(a,"input")?bj(a):"getElementsByTagName"in a&&f.grep(a.getElementsByTagName("input"),bj)}function bj(a){if(a.type==="checkbox"||a.type==="radio")a.defaultChecked=a.checked}function bi(a){return"getElementsByTagName"in a?a.getElementsByTagName("*"):"querySelectorAll"in a?a.querySelectorAll("*"):[]}function bh(a,b){var c;if(b.nodeType===1){b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase();if(c==="object")b.outerHTML=a.outerHTML;else if(c!=="input"||a.type!=="checkbox"&&a.type!=="radio"){if(c==="option")b.selected=a.defaultSelected;else if(c==="input"||c==="textarea")b.defaultValue=a.defaultValue}else a.checked&&(b.defaultChecked=b.checked=a.checked),b.value!==a.value&&(b.value=a.value);b.removeAttribute(f.expando)}}function bg(a,b){if(b.nodeType===1&&!!f.hasData(a)){var c=f.expando,d=f.data(a),e=f.data(b,d);if(d=d[c]){var g=d.events;e=e[c]=f.extend({},d);if(g){delete e.handle,e.events={};for(var h in g)for(var i=0,j=g[h].length;i<j;i++)f.event.add(b,h+(g[h][i].namespace?".":"")+g[h][i].namespace,g[h][i],g[h][i].data)}}}}function bf(a,b){return f.nodeName(a,"table")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function V(a,b,c){b=b||0;if(f.isFunction(b))return f.grep(a,function(a,d){var e=!!b.call(a,d,a);return e===c});if(b.nodeType)return f.grep(a,function(a,d){return a===b===c});if(typeof b=="string"){var d=f.grep(a,function(a){return a.nodeType===1});if(Q.test(b))return f.filter(b,d,!c);b=f.filter(b,d)}return f.grep(a,function(a,d){return f.inArray(a,b)>=0===c})}function U(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function M(a,b){return(a&&a!=="*"?a+".":"")+b.replace(y,"`").replace(z,"&")}function L(a){var b,c,d,e,g,h,i,j,k,l,m,n,o,p=[],q=[],r=f._data(this,"events");if(!(a.liveFired===this||!r||!r.live||a.target.disabled||a.button&&a.type==="click")){a.namespace&&(n=new RegExp("(^|\\.)"+a.namespace.split(".").join("\\.(?:.*\\.)?")+"(\\.|$)")),a.liveFired=this;var s=r.live.slice(0);for(i=0;i<s.length;i++)g=s[i],g.origType.replace(w,"")===a.type?q.push(g.selector):s.splice(i--,1);e=f(a.target).closest(q,a.currentTarget);for(j=0,k=e.length;j<k;j++){m=e[j];for(i=0;i<s.length;i++){g=s[i];if(m.selector===g.selector&&(!n||n.test(g.namespace))&&!m.elem.disabled){h=m.elem,d=null;if(g.preType==="mouseenter"||g.preType==="mouseleave")a.type=g.preType,d=f(a.relatedTarget).closest(g.selector)[0],d&&f.contains(h,d)&&(d=h);(!d||d!==h)&&p.push({elem:h,handleObj:g,level:m.level})}}}for(j=0,k=p.length;j<k;j++){e=p[j];if(c&&e.level>c)break;a.currentTarget=e.elem,a.data=e.handleObj.data,a.handleObj=e.handleObj,o=e.handleObj.origHandler.apply(e.elem,arguments);if(o===!1||a.isPropagationStopped()){c=e.level,o===!1&&(b=!1);if(a.isImmediatePropagationStopped())break}}return b}}function J(a,c,d){var e=f.extend({},d[0]);e.type=a,e.originalEvent={},e.liveFired=b,f.event.handle.call(c,e),e.isDefaultPrevented()&&d[0].preventDefault()}function D(){return!0}function C(){return!1}function m(a,c,d){var e=c+"defer",g=c+"queue",h=c+"mark",i=f.data(a,e,b,!0);i&&(d==="queue"||!f.data(a,g,b,!0))&&(d==="mark"||!f.data(a,h,b,!0))&&setTimeout(function(){!f.data(a,g,b,!0)&&!f.data(a,h,b,!0)&&(f.removeData(a,e,!0),i.resolve())},0)}function l(a){for(var b in a)if(b!=="toJSON")return!1;return!0}function k(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(j,"-$1").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:f.isNaN(d)?i.test(d)?f.parseJSON(d):d:parseFloat(d)}catch(g){}f.data(a,c,d)}else d=b}return d}var c=a.document,d=a.navigator,e=a.location,f=function(){function K(){if(!e.isReady){try{c.documentElement.doScroll("left")}catch(a){setTimeout(K,1);return}e.ready()}}var e=function(a,b){return new e.fn.init(a,b,h)},f=a.jQuery,g=a.$,h,i=/^(?:[^#<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,j=/\S/,k=/^\s+/,l=/\s+$/,m=/\d/,n=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,o=/^[\],:{}\s]*$/,p=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,q=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,r=/(?:^|:|,)(?:\s*\[)+/g,s=/(webkit)[ \/]([\w.]+)/,t=/(opera)(?:.*version)?[ \/]([\w.]+)/,u=/(msie) ([\w.]+)/,v=/(mozilla)(?:.*? rv:([\w.]+))?/,w=/-([a-z]|[0-9])/ig,x=/^-ms-/,y=function(a,b){return(b+"").toUpperCase()},z=d.userAgent,A,B,C,D=Object.prototype.toString,E=Object.prototype.hasOwnProperty,F=Array.prototype.push,G=Array.prototype.slice,H=String.prototype.trim,I=Array.prototype.indexOf,J={};e.fn=e.prototype={constructor:e,init:function(a,d,f){var g,h,j,k;if(!a)return this;if(a.nodeType){this.context=this[0]=a,this.length=1;return this}if(a==="body"&&!d&&c.body){this.context=c,this[0]=c.body,this.selector=a,this.length=1;return this}if(typeof a=="string"){a.charAt(0)!=="<"||a.charAt(a.length-1)!==">"||a.length<3?g=i.exec(a):g=[null,a,null];if(g&&(g[1]||!d)){if(g[1]){d=d instanceof e?d[0]:d,k=d?d.ownerDocument||d:c,j=n.exec(a),j?e.isPlainObject(d)?(a=[c.createElement(j[1])],e.fn.attr.call(a,d,!0)):a=[k.createElement(j[1])]:(j=e.buildFragment([g[1]],[k]),a=(j.cacheable?e.clone(j.fragment):j.fragment).childNodes);return e.merge(this,a)}h=c.getElementById(g[2]);if(h&&h.parentNode){if(h.id!==g[2])return f.find(a);this.length=1,this[0]=h}this.context=c,this.selector=a;return this}return!d||d.jquery?(d||f).find(a):this.constructor(d).find(a)}if(e.isFunction(a))return f.ready(a);a.selector!==b&&(this.selector=a.selector,this.context=a.context);return e.makeArray(a,this)},selector:"",jquery:"1.6.4",length:0,size:function(){return this.length},toArray:function(){return G.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=this.constructor();e.isArray(a)?F.apply(d,a):e.merge(d,a),d.prevObject=this,d.context=this.context,b==="find"?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")");return d},each:function(a,b){return e.each(this,a,b)},ready:function(a){e.bindReady(),B.done(a);return this},eq:function(a){return a===-1?this.slice(a):this.slice(a,+a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(G.apply(this,arguments),"slice",G.call(arguments).join(","))},map:function(a){return this.pushStack(e.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:F,sort:[].sort,splice:[].splice},e.fn.init.prototype=e.fn,e.extend=e.fn.extend=function(){var a,c,d,f,g,h,i=arguments[0]||{},j=1,k=arguments.length,l=!1;typeof i=="boolean"&&(l=i,i=arguments[1]||{},j=2),typeof i!="object"&&!e.isFunction(i)&&(i={}),k===j&&(i=this,--j);for(;j<k;j++)if((a=arguments[j])!=null)for(c in a){d=i[c],f=a[c];if(i===f)continue;l&&f&&(e.isPlainObject(f)||(g=e.isArray(f)))?(g?(g=!1,h=d&&e.isArray(d)?d:[]):h=d&&e.isPlainObject(d)?d:{},i[c]=e.extend(l,h,f)):f!==b&&(i[c]=f)}return i},e.extend({noConflict:function(b){a.$===e&&(a.$=g),b&&a.jQuery===e&&(a.jQuery=f);return e},isReady:!1,readyWait:1,holdReady:function(a){a?e.readyWait++:e.ready(!0)},ready:function(a){if(a===!0&&!--e.readyWait||a!==!0&&!e.isReady){if(!c.body)return setTimeout(e.ready,1);e.isReady=!0;if(a!==!0&&--e.readyWait>0)return;B.resolveWith(c,[e]),e.fn.trigger&&e(c).trigger("ready").unbind("ready")}},bindReady:function(){if(!B){B=e._Deferred();if(c.readyState==="complete")return setTimeout(e.ready,1);if(c.addEventListener)c.addEventListener("DOMContentLoaded",C,!1),a.addEventListener("load",e.ready,!1);else if(c.attachEvent){c.attachEvent("onreadystatechange",C),a.attachEvent("onload",e.ready);var b=!1;try{b=a.frameElement==null}catch(d){}c.documentElement.doScroll&&b&&K()}}},isFunction:function(a){return e.type(a)==="function"},isArray:Array.isArray||function(a){return e.type(a)==="array"},isWindow:function(a){return a&&typeof a=="object"&&"setInterval"in a},isNaN:function(a){return a==null||!m.test(a)||isNaN(a)},type:function(a){return a==null?String(a):J[D.call(a)]||"object"},isPlainObject:function(a){if(!a||e.type(a)!=="object"||a.nodeType||e.isWindow(a))return!1;try{if(a.constructor&&!E.call(a,"constructor")&&!E.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||E.call(a,d)},isEmptyObject:function(a){for(var b in a)return!1;return!0},error:function(a){throw a},parseJSON:function(b){if(typeof b!="string"||!b)return null;b=e.trim(b);if(a.JSON&&a.JSON.parse)return a.JSON.parse(b);if(o.test(b.replace(p,"@").replace(q,"]").replace(r,"")))return(new Function("return "+b))();e.error("Invalid JSON: "+b)},parseXML:function(c){var d,f;try{a.DOMParser?(f=new DOMParser,d=f.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(g){d=b}(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&e.error("Invalid XML: "+c);return d},noop:function(){},globalEval:function(b){b&&j.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(x,"ms-").replace(w,y)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,c,d){var f,g=0,h=a.length,i=h===b||e.isFunction(a);if(d){if(i){for(f in a)if(c.apply(a[f],d)===!1)break}else for(;g<h;)if(c.apply(a[g++],d)===!1)break}else if(i){for(f in a)if(c.call(a[f],f,a[f])===!1)break}else for(;g<h;)if(c.call(a[g],g,a[g++])===!1)break;return a},trim:H?function(a){return a==null?"":H.call(a)}:function(a){return a==null?"":(a+"").replace(k,"").replace(l,"")},makeArray:function(a,b){var c=b||[];if(a!=null){var d=e.type(a);a.length==null||d==="string"||d==="function"||d==="regexp"||e.isWindow(a)?F.call(c,a):e.merge(c,a)}return c},inArray:function(a,b){if(!b)return-1;if(I)return I.call(b,a);for(var c=0,d=b.length;c<d;c++)if(b[c]===a)return c;return-1},merge:function(a,c){var d=a.length,e=0;if(typeof c.length=="number")for(var f=c.length;e<f;e++)a[d++]=c[e];else while(c[e]!==b)a[d++]=c[e++];a.length=d;return a},grep:function(a,b,c){var d=[],e;c=!!c;for(var f=0,g=a.length;f<g;f++)e=!!b(a[f],f),c!==e&&d.push(a[f]);return d},map:function(a,c,d){var f,g,h=[],i=0,j=a.length,k=a instanceof e||j!==b&&typeof j=="number"&&(j>0&&a[0]&&a[j-1]||j===0||e.isArray(a));if(k)for(;i<j;i++)f=c(a[i],i,d),f!=null&&(h[h.length]=f);else for(g in a)f=c(a[g],g,d),f!=null&&(h[h.length]=f);return h.concat.apply([],h)},guid:1,proxy:function(a,c){if(typeof c=="string"){var d=a[c];c=a,a=d}if(!e.isFunction(a))return b;var f=G.call(arguments,2),g=function(){return a.apply(c,f.concat(G.call(arguments)))};g.guid=a.guid=a.guid||g.guid||e.guid++;return g},access:function(a,c,d,f,g,h){var i=a.length;if(typeof c=="object"){for(var j in c)e.access(a,j,c[j],f,g,d);return a}if(d!==b){f=!h&&f&&e.isFunction(d);for(var k=0;k<i;k++)g(a[k],c,f?d.call(a[k],k,g(a[k],c)):d,h);return a}return i?g(a[0],c):b},now:function(){return(new Date).getTime()},uaMatch:function(a){a=a.toLowerCase();var b=s.exec(a)||t.exec(a)||u.exec(a)||a.indexOf("compatible")<0&&v.exec(a)||[];return{browser:b[1]||"",version:b[2]||"0"}},sub:function(){function a(b,c){return new a.fn.init(b,c)}e.extend(!0,a,this),a.superclass=this,a.fn=a.prototype=this(),a.fn.constructor=a,a.sub=this.sub,a.fn.init=function(d,f){f&&f instanceof e&&!(f instanceof a)&&(f=a(f));return e.fn.init.call(this,d,f,b)},a.fn.init.prototype=a.fn;var b=a(c);return a},browser:{}}),e.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(a,b){J["[object "+b+"]"]=b.toLowerCase()}),A=e.uaMatch(z),A.browser&&(e.browser[A.browser]=!0,e.browser.version=A.version),e.browser.webkit&&(e.browser.safari=!0),j.test(" ")&&(k=/^[\s\xA0]+/,l=/[\s\xA0]+$/),h=e(c),c.addEventListener?C=function(){c.removeEventListener("DOMContentLoaded",C,!1),e.ready()}:c.attachEvent&&(C=function(){c.readyState==="complete"&&(c.detachEvent("onreadystatechange",C),e.ready())});return e}(),g="done fail isResolved isRejected promise then always pipe".split(" "),h=[].slice;f.extend({_Deferred:function(){var a=[],b,c,d,e={done:function(){if(!d){var c=arguments,g,h,i,j,k;b&&(k=b,b=0);for(g=0,h=c.length;g<h;g++)i=c[g],j=f.type(i),j==="array"?e.done.apply(e,i):j==="function"&&a.push(i);k&&e.resolveWith(k[0],k[1])}return this},resolveWith:function(e,f){if(!d&&!b&&!c){f=f||[],c=1;try{while(a[0])a.shift().apply(e,f)}finally{b=[e,f],c=0}}return this},resolve:function(){e.resolveWith(this,arguments);return this},isResolved:function(){return!!c||!!b},cancel:function(){d=1,a=[];return this}};return e},Deferred:function(a){var b=f._Deferred(),c=f._Deferred(),d;f.extend(b,{then:function(a,c){b.done(a).fail(c);return this},always:function(){return b.done.apply(b,arguments).fail.apply(this,arguments)},fail:c.done,rejectWith:c.resolveWith,reject:c.resolve,isRejected:c.isResolved,pipe:function(a,c){return f.Deferred(function(d){f.each({done:[a,"resolve"],fail:[c,"reject"]},function(a,c){var e=c[0],g=c[1],h;f.isFunction(e)?b[a](function(){h=e.apply(this,arguments),h&&f.isFunction(h.promise)?h.promise().then(d.resolve,d.reject):d[g+"With"](this===b?d:this,[h])}):b[a](d[g])})}).promise()},promise:function(a){if(a==null){if(d)return d;d=a={}}var c=g.length;while(c--)a[g[c]]=b[g[c]];return a}}),b.done(c.cancel).fail(b.cancel),delete b.cancel,a&&a.call(b,b);return b},when:function(a){function i(a){return function(c){b[a]=arguments.length>1?h.call(arguments,0):c,--e||g.resolveWith(g,h.call(b,0))}}var b=arguments,c=0,d=b.length,e=d,g=d<=1&&a&&f.isFunction(a.promise)?a:f.Deferred();if(d>1){for(;c<d;c++)b[c]&&f.isFunction(b[c].promise)?b[c].promise().then(i(c),g.reject):--e;e||g.resolveWith(g,b)}else g!==a&&g.resolveWith(g,d?[a]:[]);return g.promise()}}),f.support=function(){var a=c.createElement("div"),b=c.documentElement,d,e,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u;a.setAttribute("className","t"),a.innerHTML=" <link/><table></table><a href='/a' style='top:1px;float:left;opacity:.55;'>a</a><input type='checkbox'/>",d=a.getElementsByTagName("*"),e=a.getElementsByTagName("a")[0];if(!d||!d.length||!e)return{};g=c.createElement("select"),h=g.appendChild(c.createElement("option")),i=a.getElementsByTagName("input")[0],k={leadingWhitespace:a.firstChild.nodeType===3,tbody:!a.getElementsByTagName("tbody").length,htmlSerialize:!!a.getElementsByTagName("link").length,style:/top/.test(e.getAttribute("style")),hrefNormalized:e.getAttribute("href")==="/a",opacity:/^0.55$/.test(e.style.opacity),cssFloat:!!e.style.cssFloat,checkOn:i.value==="on",optSelected:h.selected,getSetAttribute:a.className!=="t",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0},i.checked=!0,k.noCloneChecked=i.cloneNode(!0).checked,g.disabled=!0,k.optDisabled=!h.disabled;try{delete a.test}catch(v){k.deleteExpando=!1}!a.addEventListener&&a.attachEvent&&a.fireEvent&&(a.attachEvent("onclick",function(){k.noCloneEvent=!1}),a.cloneNode(!0).fireEvent("onclick")),i=c.createElement("input"),i.value="t",i.setAttribute("type","radio"),k.radioValue=i.value==="t",i.setAttribute("checked","checked"),a.appendChild(i),l=c.createDocumentFragment(),l.appendChild(a.firstChild),k.checkClone=l.cloneNode(!0).cloneNode(!0).lastChild.checked,a.innerHTML="",a.style.width=a.style.paddingLeft="1px",m=c.getElementsByTagName("body")[0],o=c.createElement(m?"div":"body"),p={visibility:"hidden",width:0,height:0,border:0,margin:0,background:"none"},m&&f.extend(p,{position:"absolute",left:"-1000px",top:"-1000px"});for(t in p)o.style[t]=p[t];o.appendChild(a),n=m||b,n.insertBefore(o,n.firstChild),k.appendChecked=i.checked,k.boxModel=a.offsetWidth===2,"zoom"in a.style&&(a.style.display="inline",a.style.zoom=1,k.inlineBlockNeedsLayout=a.offsetWidth===2,a.style.display="",a.innerHTML="<div style='width:4px;'></div>",k.shrinkWrapBlocks=a.offsetWidth!==2),a.innerHTML="<table><tr><td style='padding:0;border:0;display:none'></td><td>t</td></tr></table>",q=a.getElementsByTagName("td"),u=q[0].offsetHeight===0,q[0].style.display="",q[1].style.display="none",k.reliableHiddenOffsets=u&&q[0].offsetHeight===0,a.innerHTML="",c.defaultView&&c.defaultView.getComputedStyle&&(j=c.createElement("div"),j.style.width="0",j.style.marginRight="0",a.appendChild(j),k.reliableMarginRight=(parseInt((c.defaultView.getComputedStyle(j,null)||{marginRight:0}).marginRight,10)||0)===0),o.innerHTML="",n.removeChild(o);if(a.attachEvent)for(t in{submit:1,change:1,focusin:1})s="on"+t,u=s in a,u||(a.setAttribute(s,"return;"),u=typeof a[s]=="function"),k[t+"Bubbles"]=u;o=l=g=h=m=j=a=i=null;return k}(),f.boxModel=f.support.boxModel;var i=/^(?:\{.*\}|\[.*\])$/,j=/([A-Z])/g;f.extend({cache:{},uuid:0,expando:"jQuery"+(f.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){a=a.nodeType?f.cache[a[f.expando]]:a[f.expando];return!!a&&!l(a)},data:function(a,c,d,e){if(!!f.acceptData(a)){var g,h,i=f.expando,j=typeof c=="string",k=a.nodeType,l=k?f.cache:a,m=k?a[f.expando]:a[f.expando]&&f.expando;if((!m||e&&m&&l[m]&&!l[m][i])&&j&&d===b)return;m||(k?a[f.expando]=m=++f.uuid:m=f.expando),l[m]||(l[m]={},k||(l[m].toJSON=f.noop));if(typeof c=="object"||typeof c=="function")e?l[m][i]=f.extend(l[m][i],c):l[m]=f.extend(l[m],c);g=l[m],e&&(g[i]||(g[i]={}),g=g[i]),d!==b&&(g[f.camelCase(c)]=d);if(c==="events"&&!g[c])return g[i]&&g[i].events;j?(h=g[c],h==null&&(h=g[f.camelCase(c)])):h=g;return h}},removeData:function(a,b,c){if(!!f.acceptData(a)){var d,e=f.expando,g=a.nodeType,h=g?f.cache:a,i=g?a[f.expando]:f.expando;if(!h[i])return;if(b){d=c?h[i][e]:h[i];if(d){d[b]||(b=f.camelCase(b)),delete d[b];if(!l(d))return}}if(c){delete h[i][e];if(!l(h[i]))return}var j=h[i][e];f.support.deleteExpando||!h.setInterval?delete h[i]:h[i]=null,j?(h[i]={},g||(h[i].toJSON=f.noop),h[i][e]=j):g&&(f.support.deleteExpando?delete a[f.expando]:a.removeAttribute?a.removeAttribute(f.expando):a[f.expando]=null)}},_data:function(a,b,c){return f.data(a,b,c,!0)},acceptData:function(a){if(a.nodeName){var b=f.noData[a.nodeName.toLowerCase()];if(b)return b!==!0&&a.getAttribute("classid")===b}return!0}}),f.fn.extend({data:function(a,c){var d=null;if(typeof a=="undefined"){if(this.length){d=f.data(this[0]);if(this[0].nodeType===1){var e=this[0].attributes,g;for(var h=0,i=e.length;h<i;h++)g=e[h].name,g.indexOf("data-")===0&&(g=f.camelCase(g.substring(5)),k(this[0],g,d[g]))}}return d}if(typeof a=="object")return this.each(function(){f.data(this,a)});var j=a.split(".");j[1]=j[1]?"."+j[1]:"";if(c===b){d=this.triggerHandler("getData"+j[1]+"!",[j[0]]),d===b&&this.length&&(d=f.data(this[0],a),d=k(this[0],a,d));return d===b&&j[1]?this.data(j[0]):d}return this.each(function(){var b=f(this),d=[j[0],c];b.triggerHandler("setData"+j[1]+"!",d),f.data(this,a,c),b.triggerHandler("changeData"+j[1]+"!",d)})},removeData:function(a){return this.each(function(){f.removeData(this,a)})}}),f.extend({_mark:function(a,c){a&&(c=(c||"fx")+"mark",f.data(a,c,(f.data(a,c,b,!0)||0)+1,!0))},_unmark:function(a,c,d){a!==!0&&(d=c,c=a,a=!1);if(c){d=d||"fx";var e=d+"mark",g=a?0:(f.data(c,e,b,!0)||1)-1;g?f.data(c,e,g,!0):(f.removeData(c,e,!0),m(c,d,"mark"))}},queue:function(a,c,d){if(a){c=(c||"fx")+"queue";var e=f.data(a,c,b,!0);d&&(!e||f.isArray(d)?e=f.data(a,c,f.makeArray(d),!0):e.push(d));return e||[]}},dequeue:function(a,b){b=b||"fx";var c=f.queue(a,b),d=c.shift(),e;d==="inprogress"&&(d=c.shift()),d&&(b==="fx"&&c.unshift("inprogress"),d.call(a,function(){f.dequeue(a,b)})),c.length||(f.removeData(a,b+"queue",!0),m(a,b,"queue"))}}),f.fn.extend({queue:function(a,c){typeof a!="string"&&(c=a,a="fx");if(c===b)return f.queue(this[0],a);return this.each(function(){var b=f.queue(this,a,c);a==="fx"&&b[0]!=="inprogress"&&f.dequeue(this,a)})},dequeue:function(a){return this.each(function(){f.dequeue(this,a)})},delay:function(a,b){a=f.fx?f.fx.speeds[a]||a:a,b=b||"fx";return this.queue(b,function(){var c=this;setTimeout(function(){f.dequeue(c,b)},a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,c){function m(){--h||d.resolveWith(e,[e])}typeof a!="string"&&(c=a,a=b),a=a||"fx";var d=f.Deferred(),e=this,g=e.length,h=1,i=a+"defer",j=a+"queue",k=a+"mark",l;while(g--)if(l=f.data(e[g],i,b,!0)||(f.data(e[g],j,b,!0)||f.data(e[g],k,b,!0))&&f.data(e[g],i,f._Deferred(),!0))h++,l.done(m);m();return d.promise()}});var n=/[\n\t\r]/g,o=/\s+/,p=/\r/g,q=/^(?:button|input)$/i,r=/^(?:button|input|object|select|textarea)$/i,s=/^a(?:rea)?$/i,t=/^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,u,v;f.fn.extend({attr:function(a,b){return f.access(this,a,b,!0,f.attr)},removeAttr:function(a){return this.each(function(){f.removeAttr(this,a)})},prop:function(a,b){return f.access(this,a,b,!0,f.prop)},removeProp:function(a){a=f.propFix[a]||a;return this.each(function(){try{this[a]=b,delete this[a]}catch(c){}})},addClass:function(a){var b,c,d,e,g,h,i;if(f.isFunction(a))return this.each(function(b){f(this).addClass(a.call(this,b,this.className))});if(a&&typeof a=="string"){b=a.split(o);for(c=0,d=this.length;c<d;c++){e=this[c];if(e.nodeType===1)if(!e.className&&b.length===1)e.className=a;else{g=" "+e.className+" ";for(h=0,i=b.length;h<i;h++)~g.indexOf(" "+b[h]+" ")||(g+=b[h]+" ");e.className=f.trim(g)}}}return this},removeClass:function(a){var c,d,e,g,h,i,j;if(f.isFunction(a))return this.each(function(b){f(this).removeClass(a.call(this,b,this.className))});if(a&&typeof a=="string"||a===b){c=(a||"").split(o);for(d=0,e=this.length;d<e;d++){g=this[d];if(g.nodeType===1&&g.className)if(a){h=(" "+g.className+" ").replace(n," ");for(i=0,j=c.length;i<j;i++)h=h.replace(" "+c[i]+" "," ");g.className=f.trim(h)}else g.className=""}}return this},toggleClass:function(a,b){var c=typeof a,d=typeof b=="boolean";if(f.isFunction(a))return this.each(function(c){f(this).toggleClass(a.call(this,c,this.className,b),b)});return this.each(function(){if(c==="string"){var e,g=0,h=f(this),i=b,j=a.split(o);while(e=j[g++])i=d?i:!h.hasClass(e),h[i?"addClass":"removeClass"](e)}else if(c==="undefined"||c==="boolean")this.className&&f._data(this,"__className__",this.className),this.className=this.className||a===!1?"":f._data(this,"__className__")||""})},hasClass:function(a){var b=" "+a+" ";for(var c=0,d=this.length;c<d;c++)if(this[c].nodeType===1&&(" "+this[c].className+" ").replace(n," ").indexOf(b)>-1)return!0;return!1},val:function(a){var c,d,e=this[0];if(!arguments.length){if(e){c=f.valHooks[e.nodeName.toLowerCase()]||f.valHooks[e.type];if(c&&"get"in c&&(d=c.get(e,"value"))!==b)return d;d=e.value;return typeof d=="string"?d.replace(p,""):d==null?"":d}return b}var g=f.isFunction(a);return this.each(function(d){var e=f(this),h;if(this.nodeType===1){g?h=a.call(this,d,e.val()):h=a,h==null?h="":typeof h=="number"?h+="":f.isArray(h)&&(h=f.map(h,function(a){return a==null?"":a+""})),c=f.valHooks[this.nodeName.toLowerCase()]||f.valHooks[this.type];if(!c||!("set"in c)||c.set(this,h,"value")===b)this.value=h}})}}),f.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){var b,c=a.selectedIndex,d=[],e=a.options,g=a.type==="select-one";if(c<0)return null;for(var h=g?c:0,i=g?c+1:e.length;h<i;h++){var j=e[h];if(j.selected&&(f.support.optDisabled?!j.disabled:j.getAttribute("disabled")===null)&&(!j.parentNode.disabled||!f.nodeName(j.parentNode,"optgroup"))){b=f(j).val();if(g)return b;d.push(b)}}if(g&&!d.length&&e.length)return f(e[c]).val();return d},set:function(a,b){var c=f.makeArray(b);f(a).find("option").each(function(){this.selected=f.inArray(f(this).val(),c)>=0}),c.length||(a.selectedIndex=-1);return c}}},attrFn:{val:!0,css:!0,html:!0,text:!0,data:!0,width:!0,height:!0,offset:!0},attrFix:{tabindex:"tabIndex"},attr:function(a,c,d,e){var g=a.nodeType;if(!a||g===3||g===8||g===2)return b;if(e&&c in f.attrFn)return f(a)[c](d);if(!("getAttribute"in a))return f.prop(a,c,d);var h,i,j=g!==1||!f.isXMLDoc(a);j&&(c=f.attrFix[c]||c,i=f.attrHooks[c],i||(t.test(c)?i=v:u&&(i=u)));if(d!==b){if(d===null){f.removeAttr(a,c);return b}if(i&&"set"in i&&j&&(h=i.set(a,d,c))!==b)return h;a.setAttribute(c,""+d);return d}if(i&&"get"in i&&j&&(h=i.get(a,c))!==null)return h;h=a.getAttribute(c);return h===null?b:h},removeAttr:function(a,b){var c;a.nodeType===1&&(b=f.attrFix[b]||b,f.attr(a,b,""),a.removeAttribute(b),t.test(b)&&(c=f.propFix[b]||b)in a&&(a[c]=!1))},attrHooks:{type:{set:function(a,b){if(q.test(a.nodeName)&&a.parentNode)f.error("type property can't be changed");else if(!f.support.radioValue&&b==="radio"&&f.nodeName(a,"input")){var c=a.value;a.setAttribute("type",b),c&&(a.value=c);return b}}},value:{get:function(a,b){if(u&&f.nodeName(a,"button"))return u.get(a,b);return b in a?a.value:null},set:function(a,b,c){if(u&&f.nodeName(a,"button"))return u.set(a,b,c);a.value=b}}},propFix:{tabindex:"tabIndex",readonly:"readOnly","for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},prop:function(a,c,d){var e=a.nodeType;if(!a||e===3||e===8||e===2)return b;var g,h,i=e!==1||!f.isXMLDoc(a);i&&(c=f.propFix[c]||c,h=f.propHooks[c]);return d!==b?h&&"set"in h&&(g=h.set(a,d,c))!==b?g:a[c]=d:h&&"get"in h&&(g=h.get(a,c))!==null?g:a[c]},propHooks:{tabIndex:{get:function(a){var c=a.getAttributeNode("tabindex");return c&&c.specified?parseInt(c.value,10):r.test(a.nodeName)||s.test(a.nodeName)&&a.href?0:b}}}}),f.attrHooks.tabIndex=f.propHooks.tabIndex,v={get:function(a,c){var d;return f.prop(a,c)===!0||(d=a.getAttributeNode(c))&&d.nodeValue!==!1?c.toLowerCase():b},set:function(a,b,c){var d;b===!1?f.removeAttr(a,c):(d=f.propFix[c]||c,d in a&&(a[d]=!0),a.setAttribute(c,c.toLowerCase()));return c}},f.support.getSetAttribute||(u=f.valHooks.button={get:function(a,c){var d;d=a.getAttributeNode(c);return d&&d.nodeValue!==""?d.nodeValue:b},set:function(a,b,d){var e=a.getAttributeNode(d);e||(e=c.createAttribute(d),a.setAttributeNode(e));return e.nodeValue=b+""}},f.each(["width","height"],function(a,b){f.attrHooks[b]=f.extend(f.attrHooks[b],{set:function(a,c){if(c===""){a.setAttribute(b,"auto");return c}}})})),f.support.hrefNormalized||f.each(["href","src","width","height"],function(a,c){f.attrHooks[c]=f.extend(f.attrHooks[c],{get:function(a){var d=a.getAttribute(c,2);return d===null?b:d}})}),f.support.style||(f.attrHooks.style={get:function(a){return a.style.cssText.toLowerCase()||b},set:function(a,b){return a.style.cssText=""+b}}),f.support.optSelected||(f.propHooks.selected=f.extend(f.propHooks.selected,{get:function(a){var b=a.parentNode;b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex);return null}})),f.support.checkOn||f.each(["radio","checkbox"],function(){f.valHooks[this]={get:function(a){return a.getAttribute("value")===null?"on":a.value}}}),f.each(["radio","checkbox"],function(){f.valHooks[this]=f.extend(f.valHooks[this],{set:function(a,b){if(f.isArray(b))return a.checked=f.inArray(f(a).val(),b)>=0}})});var w=/\.(.*)$/,x=/^(?:textarea|input|select)$/i,y=/\./g,z=/ /g,A=/[^\w\s.|`]/g,B=function(a){return a.replace(A,"\\$&")};f.event={add:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){if(d===!1)d=C;else if(!d)return;var g,h;d.handler&&(g=d,d=g.handler),d.guid||(d.guid=f.guid++);var i=f._data(a);if(!i)return;var j=i.events,k=i.handle;j||(i.events=j={}),k||(i.handle=k=function(a){return typeof f!="undefined"&&(!a||f.event.triggered!==a.type)?f.event.handle.apply(k.elem,arguments):b}),k.elem=a,c=c.split(" ");var l,m=0,n;while(l=c[m++]){h=g?f.extend({},g):{handler:d,data:e},l.indexOf(".")>-1?(n=l.split("."),l=n.shift(),h.namespace=n.slice(0).sort().join(".")):(n=[],h.namespace=""),h.type=l,h.guid||(h.guid=d.guid);var o=j[l],p=f.event.special[l]||{};if(!o){o=j[l]=[];if(!p.setup||p.setup.call(a,e,n,k)===!1)a.addEventListener?a.addEventListener(l,k,!1):a.attachEvent&&a.attachEvent("on"+l,k)}p.add&&(p.add.call(a,h),h.handler.guid||(h.handler.guid=d.guid)),o.push(h),f.event.global[l]=!0}a=null}},global:{},remove:function(a,c,d,e){if(a.nodeType!==3&&a.nodeType!==8){d===!1&&(d=C);var g,h,i,j,k=0,l,m,n,o,p,q,r,s=f.hasData(a)&&f._data(a),t=s&&s.events;if(!s||!t)return;c&&c.type&&(d=c.handler,c=c.type);if(!c||typeof c=="string"&&c.charAt(0)==="."){c=c||"";for(h in t)f.event.remove(a,h+c);return}c=c.split(" ");while(h=c[k++]){r=h,q=null,l=h.indexOf(".")<0,m=[],l||(m=h.split("."),h=m.shift(),n=new RegExp("(^|\\.)"+f.map(m.slice(0).sort(),B).join("\\.(?:.*\\.)?")+"(\\.|$)")),p=t[h];if(!p)continue;if(!d){for(j=0;j<p.length;j++){q=p[j];if(l||n.test(q.namespace))f.event.remove(a,r,q.handler,j),p.splice(j--,1)}continue}o=f.event.special[h]||{};for(j=e||0;j<p.length;j++){q=p[j];if(d.guid===q.guid){if(l||n.test(q.namespace))e==null&&p.splice(j--,1),o.remove&&o.remove.call(a,q);if(e!=null)break}}if(p.length===0||e!=null&&p.length===1)(!o.teardown||o.teardown.call(a,m)===!1)&&f.removeEvent(a,h,s.handle),g=null,delete -t[h]}if(f.isEmptyObject(t)){var u=s.handle;u&&(u.elem=null),delete s.events,delete s.handle,f.isEmptyObject(s)&&f.removeData(a,b,!0)}}},customEvent:{getData:!0,setData:!0,changeData:!0},trigger:function(c,d,e,g){var h=c.type||c,i=[],j;h.indexOf("!")>=0&&(h=h.slice(0,-1),j=!0),h.indexOf(".")>=0&&(i=h.split("."),h=i.shift(),i.sort());if(!!e&&!f.event.customEvent[h]||!!f.event.global[h]){c=typeof c=="object"?c[f.expando]?c:new f.Event(h,c):new f.Event(h),c.type=h,c.exclusive=j,c.namespace=i.join("."),c.namespace_re=new RegExp("(^|\\.)"+i.join("\\.(?:.*\\.)?")+"(\\.|$)");if(g||!e)c.preventDefault(),c.stopPropagation();if(!e){f.each(f.cache,function(){var a=f.expando,b=this[a];b&&b.events&&b.events[h]&&f.event.trigger(c,d,b.handle.elem)});return}if(e.nodeType===3||e.nodeType===8)return;c.result=b,c.target=e,d=d!=null?f.makeArray(d):[],d.unshift(c);var k=e,l=h.indexOf(":")<0?"on"+h:"";do{var m=f._data(k,"handle");c.currentTarget=k,m&&m.apply(k,d),l&&f.acceptData(k)&&k[l]&&k[l].apply(k,d)===!1&&(c.result=!1,c.preventDefault()),k=k.parentNode||k.ownerDocument||k===c.target.ownerDocument&&a}while(k&&!c.isPropagationStopped());if(!c.isDefaultPrevented()){var n,o=f.event.special[h]||{};if((!o._default||o._default.call(e.ownerDocument,c)===!1)&&(h!=="click"||!f.nodeName(e,"a"))&&f.acceptData(e)){try{l&&e[h]&&(n=e[l],n&&(e[l]=null),f.event.triggered=h,e[h]())}catch(p){}n&&(e[l]=n),f.event.triggered=b}}return c.result}},handle:function(c){c=f.event.fix(c||a.event);var d=((f._data(this,"events")||{})[c.type]||[]).slice(0),e=!c.exclusive&&!c.namespace,g=Array.prototype.slice.call(arguments,0);g[0]=c,c.currentTarget=this;for(var h=0,i=d.length;h<i;h++){var j=d[h];if(e||c.namespace_re.test(j.namespace)){c.handler=j.handler,c.data=j.data,c.handleObj=j;var k=j.handler.apply(this,g);k!==b&&(c.result=k,k===!1&&(c.preventDefault(),c.stopPropagation()));if(c.isImmediatePropagationStopped())break}}return c.result},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode layerX layerY metaKey newValue offsetX offsetY pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),fix:function(a){if(a[f.expando])return a;var d=a;a=f.Event(d);for(var e=this.props.length,g;e;)g=this.props[--e],a[g]=d[g];a.target||(a.target=a.srcElement||c),a.target.nodeType===3&&(a.target=a.target.parentNode),!a.relatedTarget&&a.fromElement&&(a.relatedTarget=a.fromElement===a.target?a.toElement:a.fromElement);if(a.pageX==null&&a.clientX!=null){var h=a.target.ownerDocument||c,i=h.documentElement,j=h.body;a.pageX=a.clientX+(i&&i.scrollLeft||j&&j.scrollLeft||0)-(i&&i.clientLeft||j&&j.clientLeft||0),a.pageY=a.clientY+(i&&i.scrollTop||j&&j.scrollTop||0)-(i&&i.clientTop||j&&j.clientTop||0)}a.which==null&&(a.charCode!=null||a.keyCode!=null)&&(a.which=a.charCode!=null?a.charCode:a.keyCode),!a.metaKey&&a.ctrlKey&&(a.metaKey=a.ctrlKey),!a.which&&a.button!==b&&(a.which=a.button&1?1:a.button&2?3:a.button&4?2:0);return a},guid:1e8,proxy:f.proxy,special:{ready:{setup:f.bindReady,teardown:f.noop},live:{add:function(a){f.event.add(this,M(a.origType,a.selector),f.extend({},a,{handler:L,guid:a.handler.guid}))},remove:function(a){f.event.remove(this,M(a.origType,a.selector),a)}},beforeunload:{setup:function(a,b,c){f.isWindow(this)&&(this.onbeforeunload=c)},teardown:function(a,b){this.onbeforeunload===b&&(this.onbeforeunload=null)}}}},f.removeEvent=c.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)}:function(a,b,c){a.detachEvent&&a.detachEvent("on"+b,c)},f.Event=function(a,b){if(!this.preventDefault)return new f.Event(a,b);a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||a.returnValue===!1||a.getPreventDefault&&a.getPreventDefault()?D:C):this.type=a,b&&f.extend(this,b),this.timeStamp=f.now(),this[f.expando]=!0},f.Event.prototype={preventDefault:function(){this.isDefaultPrevented=D;var a=this.originalEvent;!a||(a.preventDefault?a.preventDefault():a.returnValue=!1)},stopPropagation:function(){this.isPropagationStopped=D;var a=this.originalEvent;!a||(a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=D,this.stopPropagation()},isDefaultPrevented:C,isPropagationStopped:C,isImmediatePropagationStopped:C};var E=function(a){var b=a.relatedTarget,c=!1,d=a.type;a.type=a.data,b!==this&&(b&&(c=f.contains(this,b)),c||(f.event.handle.apply(this,arguments),a.type=d))},F=function(a){a.type=a.data,f.event.handle.apply(this,arguments)};f.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){f.event.special[a]={setup:function(c){f.event.add(this,b,c&&c.selector?F:E,a)},teardown:function(a){f.event.remove(this,b,a&&a.selector?F:E)}}}),f.support.submitBubbles||(f.event.special.submit={setup:function(a,b){if(!f.nodeName(this,"form"))f.event.add(this,"click.specialSubmit",function(a){var b=a.target,c=f.nodeName(b,"input")||f.nodeName(b,"button")?b.type:"";(c==="submit"||c==="image")&&f(b).closest("form").length&&J("submit",this,arguments)}),f.event.add(this,"keypress.specialSubmit",function(a){var b=a.target,c=f.nodeName(b,"input")||f.nodeName(b,"button")?b.type:"";(c==="text"||c==="password")&&f(b).closest("form").length&&a.keyCode===13&&J("submit",this,arguments)});else return!1},teardown:function(a){f.event.remove(this,".specialSubmit")}});if(!f.support.changeBubbles){var G,H=function(a){var b=f.nodeName(a,"input")?a.type:"",c=a.value;b==="radio"||b==="checkbox"?c=a.checked:b==="select-multiple"?c=a.selectedIndex>-1?f.map(a.options,function(a){return a.selected}).join("-"):"":f.nodeName(a,"select")&&(c=a.selectedIndex);return c},I=function(c){var d=c.target,e,g;if(!!x.test(d.nodeName)&&!d.readOnly){e=f._data(d,"_change_data"),g=H(d),(c.type!=="focusout"||d.type!=="radio")&&f._data(d,"_change_data",g);if(e===b||g===e)return;if(e!=null||g)c.type="change",c.liveFired=b,f.event.trigger(c,arguments[1],d)}};f.event.special.change={filters:{focusout:I,beforedeactivate:I,click:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(c==="radio"||c==="checkbox"||f.nodeName(b,"select"))&&I.call(this,a)},keydown:function(a){var b=a.target,c=f.nodeName(b,"input")?b.type:"";(a.keyCode===13&&!f.nodeName(b,"textarea")||a.keyCode===32&&(c==="checkbox"||c==="radio")||c==="select-multiple")&&I.call(this,a)},beforeactivate:function(a){var b=a.target;f._data(b,"_change_data",H(b))}},setup:function(a,b){if(this.type==="file")return!1;for(var c in G)f.event.add(this,c+".specialChange",G[c]);return x.test(this.nodeName)},teardown:function(a){f.event.remove(this,".specialChange");return x.test(this.nodeName)}},G=f.event.special.change.filters,G.focus=G.beforeactivate}f.support.focusinBubbles||f.each({focus:"focusin",blur:"focusout"},function(a,b){function e(a){var c=f.event.fix(a);c.type=b,c.originalEvent={},f.event.trigger(c,null,c.target),c.isDefaultPrevented()&&a.preventDefault()}var d=0;f.event.special[b]={setup:function(){d++===0&&c.addEventListener(a,e,!0)},teardown:function(){--d===0&&c.removeEventListener(a,e,!0)}}}),f.each(["bind","one"],function(a,c){f.fn[c]=function(a,d,e){var g;if(typeof a=="object"){for(var h in a)this[c](h,d,a[h],e);return this}if(arguments.length===2||d===!1)e=d,d=b;c==="one"?(g=function(a){f(this).unbind(a,g);return e.apply(this,arguments)},g.guid=e.guid||f.guid++):g=e;if(a==="unload"&&c!=="one")this.one(a,d,e);else for(var i=0,j=this.length;i<j;i++)f.event.add(this[i],a,g,d);return this}}),f.fn.extend({unbind:function(a,b){if(typeof a=="object"&&!a.preventDefault)for(var c in a)this.unbind(c,a[c]);else for(var d=0,e=this.length;d<e;d++)f.event.remove(this[d],a,b);return this},delegate:function(a,b,c,d){return this.live(b,c,d,a)},undelegate:function(a,b,c){return arguments.length===0?this.unbind("live"):this.die(b,null,c,a)},trigger:function(a,b){return this.each(function(){f.event.trigger(a,b,this)})},triggerHandler:function(a,b){if(this[0])return f.event.trigger(a,b,this[0],!0)},toggle:function(a){var b=arguments,c=a.guid||f.guid++,d=0,e=function(c){var e=(f.data(this,"lastToggle"+a.guid)||0)%d;f.data(this,"lastToggle"+a.guid,e+1),c.preventDefault();return b[e].apply(this,arguments)||!1};e.guid=c;while(d<b.length)b[d++].guid=c;return this.click(e)},hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}});var K={focus:"focusin",blur:"focusout",mouseenter:"mouseover",mouseleave:"mouseout"};f.each(["live","die"],function(a,c){f.fn[c]=function(a,d,e,g){var h,i=0,j,k,l,m=g||this.selector,n=g?this:f(this.context);if(typeof a=="object"&&!a.preventDefault){for(var o in a)n[c](o,d,a[o],m);return this}if(c==="die"&&!a&&g&&g.charAt(0)==="."){n.unbind(g);return this}if(d===!1||f.isFunction(d))e=d||C,d=b;a=(a||"").split(" ");while((h=a[i++])!=null){j=w.exec(h),k="",j&&(k=j[0],h=h.replace(w,""));if(h==="hover"){a.push("mouseenter"+k,"mouseleave"+k);continue}l=h,K[h]?(a.push(K[h]+k),h=h+k):h=(K[h]||h)+k;if(c==="live")for(var p=0,q=n.length;p<q;p++)f.event.add(n[p],"live."+M(h,m),{data:d,selector:m,handler:e,origType:h,origHandler:e,preType:l});else n.unbind("live."+M(h,m),e)}return this}}),f.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error".split(" "),function(a,b){f.fn[b]=function(a,c){c==null&&(c=a,a=null);return arguments.length>0?this.bind(b,a,c):this.trigger(b)},f.attrFn&&(f.attrFn[b]=!0)}),function(){function u(a,b,c,d,e,f){for(var g=0,h=d.length;g<h;g++){var i=d[g];if(i){var j=!1;i=i[a];while(i){if(i.sizcache===c){j=d[i.sizset];break}if(i.nodeType===1){f||(i.sizcache=c,i.sizset=g);if(typeof b!="string"){if(i===b){j=!0;break}}else if(k.filter(b,[i]).length>0){j=i;break}}i=i[a]}d[g]=j}}}function t(a,b,c,d,e,f){for(var g=0,h=d.length;g<h;g++){var i=d[g];if(i){var j=!1;i=i[a];while(i){if(i.sizcache===c){j=d[i.sizset];break}i.nodeType===1&&!f&&(i.sizcache=c,i.sizset=g);if(i.nodeName.toLowerCase()===b){j=i;break}i=i[a]}d[g]=j}}}var a=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,d=0,e=Object.prototype.toString,g=!1,h=!0,i=/\\/g,j=/\W/;[0,0].sort(function(){h=!1;return 0});var k=function(b,d,f,g){f=f||[],d=d||c;var h=d;if(d.nodeType!==1&&d.nodeType!==9)return[];if(!b||typeof b!="string")return f;var i,j,n,o,q,r,s,t,u=!0,w=k.isXML(d),x=[],y=b;do{a.exec(""),i=a.exec(y);if(i){y=i[3],x.push(i[1]);if(i[2]){o=i[3];break}}}while(i);if(x.length>1&&m.exec(b))if(x.length===2&&l.relative[x[0]])j=v(x[0]+x[1],d);else{j=l.relative[x[0]]?[d]:k(x.shift(),d);while(x.length)b=x.shift(),l.relative[b]&&(b+=x.shift()),j=v(b,j)}else{!g&&x.length>1&&d.nodeType===9&&!w&&l.match.ID.test(x[0])&&!l.match.ID.test(x[x.length-1])&&(q=k.find(x.shift(),d,w),d=q.expr?k.filter(q.expr,q.set)[0]:q.set[0]);if(d){q=g?{expr:x.pop(),set:p(g)}:k.find(x.pop(),x.length===1&&(x[0]==="~"||x[0]==="+")&&d.parentNode?d.parentNode:d,w),j=q.expr?k.filter(q.expr,q.set):q.set,x.length>0?n=p(j):u=!1;while(x.length)r=x.pop(),s=r,l.relative[r]?s=x.pop():r="",s==null&&(s=d),l.relative[r](n,s,w)}else n=x=[]}n||(n=j),n||k.error(r||b);if(e.call(n)==="[object Array]")if(!u)f.push.apply(f,n);else if(d&&d.nodeType===1)for(t=0;n[t]!=null;t++)n[t]&&(n[t]===!0||n[t].nodeType===1&&k.contains(d,n[t]))&&f.push(j[t]);else for(t=0;n[t]!=null;t++)n[t]&&n[t].nodeType===1&&f.push(j[t]);else p(n,f);o&&(k(o,h,f,g),k.uniqueSort(f));return f};k.uniqueSort=function(a){if(r){g=h,a.sort(r);if(g)for(var b=1;b<a.length;b++)a[b]===a[b-1]&&a.splice(b--,1)}return a},k.matches=function(a,b){return k(a,null,null,b)},k.matchesSelector=function(a,b){return k(b,null,null,[a]).length>0},k.find=function(a,b,c){var d;if(!a)return[];for(var e=0,f=l.order.length;e<f;e++){var g,h=l.order[e];if(g=l.leftMatch[h].exec(a)){var j=g[1];g.splice(1,1);if(j.substr(j.length-1)!=="\\"){g[1]=(g[1]||"").replace(i,""),d=l.find[h](g,b,c);if(d!=null){a=a.replace(l.match[h],"");break}}}}d||(d=typeof b.getElementsByTagName!="undefined"?b.getElementsByTagName("*"):[]);return{set:d,expr:a}},k.filter=function(a,c,d,e){var f,g,h=a,i=[],j=c,m=c&&c[0]&&k.isXML(c[0]);while(a&&c.length){for(var n in l.filter)if((f=l.leftMatch[n].exec(a))!=null&&f[2]){var o,p,q=l.filter[n],r=f[1];g=!1,f.splice(1,1);if(r.substr(r.length-1)==="\\")continue;j===i&&(i=[]);if(l.preFilter[n]){f=l.preFilter[n](f,j,d,i,e,m);if(!f)g=o=!0;else if(f===!0)continue}if(f)for(var s=0;(p=j[s])!=null;s++)if(p){o=q(p,f,s,j);var t=e^!!o;d&&o!=null?t?g=!0:j[s]=!1:t&&(i.push(p),g=!0)}if(o!==b){d||(j=i),a=a.replace(l.match[n],"");if(!g)return[];break}}if(a===h)if(g==null)k.error(a);else break;h=a}return j},k.error=function(a){throw"Syntax error, unrecognized expression: "+a};var l=k.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,CLASS:/\.((?:[\w\u00c0-\uFFFF\-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF\-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF\-]|\\.)+)\s*(?:(\S?=)\s*(?:(['"])(.*?)\3|(#?(?:[\w\u00c0-\uFFFF\-]|\\.)*)|)|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*\-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\(\s*(even|odd|(?:[+\-]?\d+|(?:[+\-]?\d*)?n\s*(?:[+\-]\s*\d+)?))\s*\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^\-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF\-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/},leftMatch:{},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(a){return a.getAttribute("href")},type:function(a){return a.getAttribute("type")}},relative:{"+":function(a,b){var c=typeof b=="string",d=c&&!j.test(b),e=c&&!d;d&&(b=b.toLowerCase());for(var f=0,g=a.length,h;f<g;f++)if(h=a[f]){while((h=h.previousSibling)&&h.nodeType!==1);a[f]=e||h&&h.nodeName.toLowerCase()===b?h||!1:h===b}e&&k.filter(b,a,!0)},">":function(a,b){var c,d=typeof b=="string",e=0,f=a.length;if(d&&!j.test(b)){b=b.toLowerCase();for(;e<f;e++){c=a[e];if(c){var g=c.parentNode;a[e]=g.nodeName.toLowerCase()===b?g:!1}}}else{for(;e<f;e++)c=a[e],c&&(a[e]=d?c.parentNode:c.parentNode===b);d&&k.filter(b,a,!0)}},"":function(a,b,c){var e,f=d++,g=u;typeof b=="string"&&!j.test(b)&&(b=b.toLowerCase(),e=b,g=t),g("parentNode",b,f,a,e,c)},"~":function(a,b,c){var e,f=d++,g=u;typeof b=="string"&&!j.test(b)&&(b=b.toLowerCase(),e=b,g=t),g("previousSibling",b,f,a,e,c)}},find:{ID:function(a,b,c){if(typeof b.getElementById!="undefined"&&!c){var d=b.getElementById(a[1]);return d&&d.parentNode?[d]:[]}},NAME:function(a,b){if(typeof b.getElementsByName!="undefined"){var c=[],d=b.getElementsByName(a[1]);for(var e=0,f=d.length;e<f;e++)d[e].getAttribute("name")===a[1]&&c.push(d[e]);return c.length===0?null:c}},TAG:function(a,b){if(typeof b.getElementsByTagName!="undefined")return b.getElementsByTagName(a[1])}},preFilter:{CLASS:function(a,b,c,d,e,f){a=" "+a[1].replace(i,"")+" ";if(f)return a;for(var g=0,h;(h=b[g])!=null;g++)h&&(e^(h.className&&(" "+h.className+" ").replace(/[\t\n\r]/g," ").indexOf(a)>=0)?c||d.push(h):c&&(b[g]=!1));return!1},ID:function(a){return a[1].replace(i,"")},TAG:function(a,b){return a[1].replace(i,"").toLowerCase()},CHILD:function(a){if(a[1]==="nth"){a[2]||k.error(a[0]),a[2]=a[2].replace(/^\+|\s*/g,"");var b=/(-?)(\d*)(?:n([+\-]?\d*))?/.exec(a[2]==="even"&&"2n"||a[2]==="odd"&&"2n+1"||!/\D/.test(a[2])&&"0n+"+a[2]||a[2]);a[2]=b[1]+(b[2]||1)-0,a[3]=b[3]-0}else a[2]&&k.error(a[0]);a[0]=d++;return a},ATTR:function(a,b,c,d,e,f){var g=a[1]=a[1].replace(i,"");!f&&l.attrMap[g]&&(a[1]=l.attrMap[g]),a[4]=(a[4]||a[5]||"").replace(i,""),a[2]==="~="&&(a[4]=" "+a[4]+" ");return a},PSEUDO:function(b,c,d,e,f){if(b[1]==="not")if((a.exec(b[3])||"").length>1||/^\w/.test(b[3]))b[3]=k(b[3],null,null,c);else{var g=k.filter(b[3],c,d,!0^f);d||e.push.apply(e,g);return!1}else if(l.match.POS.test(b[0])||l.match.CHILD.test(b[0]))return!0;return b},POS:function(a){a.unshift(!0);return a}},filters:{enabled:function(a){return a.disabled===!1&&a.type!=="hidden"},disabled:function(a){return a.disabled===!0},checked:function(a){return a.checked===!0},selected:function(a){a.parentNode&&a.parentNode.selectedIndex;return a.selected===!0},parent:function(a){return!!a.firstChild},empty:function(a){return!a.firstChild},has:function(a,b,c){return!!k(c[3],a).length},header:function(a){return/h\d/i.test(a.nodeName)},text:function(a){var b=a.getAttribute("type"),c=a.type;return a.nodeName.toLowerCase()==="input"&&"text"===c&&(b===c||b===null)},radio:function(a){return a.nodeName.toLowerCase()==="input"&&"radio"===a.type},checkbox:function(a){return a.nodeName.toLowerCase()==="input"&&"checkbox"===a.type},file:function(a){return a.nodeName.toLowerCase()==="input"&&"file"===a.type},password:function(a){return a.nodeName.toLowerCase()==="input"&&"password"===a.type},submit:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"submit"===a.type},image:function(a){return a.nodeName.toLowerCase()==="input"&&"image"===a.type},reset:function(a){var b=a.nodeName.toLowerCase();return(b==="input"||b==="button")&&"reset"===a.type},button:function(a){var b=a.nodeName.toLowerCase();return b==="input"&&"button"===a.type||b==="button"},input:function(a){return/input|select|textarea|button/i.test(a.nodeName)},focus:function(a){return a===a.ownerDocument.activeElement}},setFilters:{first:function(a,b){return b===0},last:function(a,b,c,d){return b===d.length-1},even:function(a,b){return b%2===0},odd:function(a,b){return b%2===1},lt:function(a,b,c){return b<c[3]-0},gt:function(a,b,c){return b>c[3]-0},nth:function(a,b,c){return c[3]-0===b},eq:function(a,b,c){return c[3]-0===b}},filter:{PSEUDO:function(a,b,c,d){var e=b[1],f=l.filters[e];if(f)return f(a,c,b,d);if(e==="contains")return(a.textContent||a.innerText||k.getText([a])||"").indexOf(b[3])>=0;if(e==="not"){var g=b[3];for(var h=0,i=g.length;h<i;h++)if(g[h]===a)return!1;return!0}k.error(e)},CHILD:function(a,b){var c=b[1],d=a;switch(c){case"only":case"first":while(d=d.previousSibling)if(d.nodeType===1)return!1;if(c==="first")return!0;d=a;case"last":while(d=d.nextSibling)if(d.nodeType===1)return!1;return!0;case"nth":var e=b[2],f=b[3];if(e===1&&f===0)return!0;var g=b[0],h=a.parentNode;if(h&&(h.sizcache!==g||!a.nodeIndex)){var i=0;for(d=h.firstChild;d;d=d.nextSibling)d.nodeType===1&&(d.nodeIndex=++i);h.sizcache=g}var j=a.nodeIndex-f;return e===0?j===0:j%e===0&&j/e>=0}},ID:function(a,b){return a.nodeType===1&&a.getAttribute("id")===b},TAG:function(a,b){return b==="*"&&a.nodeType===1||a.nodeName.toLowerCase()===b},CLASS:function(a,b){return(" "+(a.className||a.getAttribute("class"))+" ").indexOf(b)>-1},ATTR:function(a,b){var c=b[1],d=l.attrHandle[c]?l.attrHandle[c](a):a[c]!=null?a[c]:a.getAttribute(c),e=d+"",f=b[2],g=b[4];return d==null?f==="!=":f==="="?e===g:f==="*="?e.indexOf(g)>=0:f==="~="?(" "+e+" ").indexOf(g)>=0:g?f==="!="?e!==g:f==="^="?e.indexOf(g)===0:f==="$="?e.substr(e.length-g.length)===g:f==="|="?e===g||e.substr(0,g.length+1)===g+"-":!1:e&&d!==!1},POS:function(a,b,c,d){var e=b[2],f=l.setFilters[e];if(f)return f(a,c,b,d)}}},m=l.match.POS,n=function(a,b){return"\\"+(b-0+1)};for(var o in l.match)l.match[o]=new RegExp(l.match[o].source+/(?![^\[]*\])(?![^\(]*\))/.source),l.leftMatch[o]=new RegExp(/(^(?:.|\r|\n)*?)/.source+l.match[o].source.replace(/\\(\d+)/g,n));var p=function(a,b){a=Array.prototype.slice.call(a,0);if(b){b.push.apply(b,a);return b}return a};try{Array.prototype.slice.call(c.documentElement.childNodes,0)[0].nodeType}catch(q){p=function(a,b){var c=0,d=b||[];if(e.call(a)==="[object Array]")Array.prototype.push.apply(d,a);else if(typeof a.length=="number")for(var f=a.length;c<f;c++)d.push(a[c]);else for(;a[c];c++)d.push(a[c]);return d}}var r,s;c.documentElement.compareDocumentPosition?r=function(a,b){if(a===b){g=!0;return 0}if(!a.compareDocumentPosition||!b.compareDocumentPosition)return a.compareDocumentPosition?-1:1;return a.compareDocumentPosition(b)&4?-1:1}:(r=function(a,b){if(a===b){g=!0;return 0}if(a.sourceIndex&&b.sourceIndex)return a.sourceIndex-b.sourceIndex;var c,d,e=[],f=[],h=a.parentNode,i=b.parentNode,j=h;if(h===i)return s(a,b);if(!h)return-1;if(!i)return 1;while(j)e.unshift(j),j=j.parentNode;j=i;while(j)f.unshift(j),j=j.parentNode;c=e.length,d=f.length;for(var k=0;k<c&&k<d;k++)if(e[k]!==f[k])return s(e[k],f[k]);return k===c?s(a,f[k],-1):s(e[k],b,1)},s=function(a,b,c){if(a===b)return c;var d=a.nextSibling;while(d){if(d===b)return-1;d=d.nextSibling}return 1}),k.getText=function(a){var b="",c;for(var d=0;a[d];d++)c=a[d],c.nodeType===3||c.nodeType===4?b+=c.nodeValue:c.nodeType!==8&&(b+=k.getText(c.childNodes));return b},function(){var a=c.createElement("div"),d="script"+(new Date).getTime(),e=c.documentElement;a.innerHTML="<a name='"+d+"'/>",e.insertBefore(a,e.firstChild),c.getElementById(d)&&(l.find.ID=function(a,c,d){if(typeof c.getElementById!="undefined"&&!d){var e=c.getElementById(a[1]);return e?e.id===a[1]||typeof e.getAttributeNode!="undefined"&&e.getAttributeNode("id").nodeValue===a[1]?[e]:b:[]}},l.filter.ID=function(a,b){var c=typeof a.getAttributeNode!="undefined"&&a.getAttributeNode("id");return a.nodeType===1&&c&&c.nodeValue===b}),e.removeChild(a),e=a=null}(),function(){var a=c.createElement("div");a.appendChild(c.createComment("")),a.getElementsByTagName("*").length>0&&(l.find.TAG=function(a,b){var c=b.getElementsByTagName(a[1]);if(a[1]==="*"){var d=[];for(var e=0;c[e];e++)c[e].nodeType===1&&d.push(c[e]);c=d}return c}),a.innerHTML="<a href='#'></a>",a.firstChild&&typeof a.firstChild.getAttribute!="undefined"&&a.firstChild.getAttribute("href")!=="#"&&(l.attrHandle.href=function(a){return a.getAttribute("href",2)}),a=null}(),c.querySelectorAll&&function(){var a=k,b=c.createElement("div"),d="__sizzle__";b.innerHTML="<p class='TEST'></p>";if(!b.querySelectorAll||b.querySelectorAll(".TEST").length!==0){k=function(b,e,f,g){e=e||c;if(!g&&!k.isXML(e)){var h=/^(\w+$)|^\.([\w\-]+$)|^#([\w\-]+$)/.exec(b);if(h&&(e.nodeType===1||e.nodeType===9)){if(h[1])return p(e.getElementsByTagName(b),f);if(h[2]&&l.find.CLASS&&e.getElementsByClassName)return p(e.getElementsByClassName(h[2]),f)}if(e.nodeType===9){if(b==="body"&&e.body)return p([e.body],f);if(h&&h[3]){var i=e.getElementById(h[3]);if(!i||!i.parentNode)return p([],f);if(i.id===h[3])return p([i],f)}try{return p(e.querySelectorAll(b),f)}catch(j){}}else if(e.nodeType===1&&e.nodeName.toLowerCase()!=="object"){var m=e,n=e.getAttribute("id"),o=n||d,q=e.parentNode,r=/^\s*[+~]/.test(b);n?o=o.replace(/'/g,"\\$&"):e.setAttribute("id",o),r&&q&&(e=e.parentNode);try{if(!r||q)return p(e.querySelectorAll("[id='"+o+"'] "+b),f)}catch(s){}finally{n||m.removeAttribute("id")}}}return a(b,e,f,g)};for(var e in a)k[e]=a[e];b=null}}(),function(){var a=c.documentElement,b=a.matchesSelector||a.mozMatchesSelector||a.webkitMatchesSelector||a.msMatchesSelector;if(b){var d=!b.call(c.createElement("div"),"div"),e=!1;try{b.call(c.documentElement,"[test!='']:sizzle")}catch(f){e=!0}k.matchesSelector=function(a,c){c=c.replace(/\=\s*([^'"\]]*)\s*\]/g,"='$1']");if(!k.isXML(a))try{if(e||!l.match.PSEUDO.test(c)&&!/!=/.test(c)){var f=b.call(a,c);if(f||!d||a.document&&a.document.nodeType!==11)return f}}catch(g){}return k(c,null,null,[a]).length>0}}}(),function(){var a=c.createElement("div");a.innerHTML="<div class='test e'></div><div class='test'></div>";if(!!a.getElementsByClassName&&a.getElementsByClassName("e").length!==0){a.lastChild.className="e";if(a.getElementsByClassName("e").length===1)return;l.order.splice(1,0,"CLASS"),l.find.CLASS=function(a,b,c){if(typeof b.getElementsByClassName!="undefined"&&!c)return b.getElementsByClassName(a[1])},a=null}}(),c.documentElement.contains?k.contains=function(a,b){return a!==b&&(a.contains?a.contains(b):!0)}:c.documentElement.compareDocumentPosition?k.contains=function(a,b){return!!(a.compareDocumentPosition(b)&16)}:k.contains=function(){return!1},k.isXML=function(a){var b=(a?a.ownerDocument||a:0).documentElement;return b?b.nodeName!=="HTML":!1};var v=function(a,b){var c,d=[],e="",f=b.nodeType?[b]:b;while(c=l.match.PSEUDO.exec(a))e+=c[0],a=a.replace(l.match.PSEUDO,"");a=l.relative[a]?a+"*":a;for(var g=0,h=f.length;g<h;g++)k(a,f[g],d);return k.filter(e,d)};f.find=k,f.expr=k.selectors,f.expr[":"]=f.expr.filters,f.unique=k.uniqueSort,f.text=k.getText,f.isXMLDoc=k.isXML,f.contains=k.contains}();var N=/Until$/,O=/^(?:parents|prevUntil|prevAll)/,P=/,/,Q=/^.[^:#\[\.,]*$/,R=Array.prototype.slice,S=f.expr.match.POS,T={children:!0,contents:!0,next:!0,prev:!0};f.fn.extend({find:function(a){var b=this,c,d;if(typeof a!="string")return f(a).filter(function(){for(c=0,d=b.length;c<d;c++)if(f.contains(b[c],this))return!0});var e=this.pushStack("","find",a),g,h,i;for(c=0,d=this.length;c<d;c++){g=e.length,f.find(a,this[c],e);if(c>0)for(h=g;h<e.length;h++)for(i=0;i<g;i++)if(e[i]===e[h]){e.splice(h--,1);break}}return e},has:function(a){var b=f(a);return this.filter(function(){for(var a=0,c=b.length;a<c;a++)if(f.contains(this,b[a]))return!0})},not:function(a){return this.pushStack(V(this,a,!1),"not",a)},filter:function(a){return this.pushStack(V(this,a,!0),"filter",a)},is:function(a){return!!a&&(typeof a=="string"?f.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c=[],d,e,g=this[0];if(f.isArray(a)){var h,i,j={},k=1;if(g&&a.length){for(d=0,e=a.length;d<e;d++)i=a[d],j[i]||(j[i]=S.test(i)?f(i,b||this.context):i);while(g&&g.ownerDocument&&g!==b){for(i in j)h=j[i],(h.jquery?h.index(g)>-1:f(g).is(h))&&c.push({selector:i,elem:g,level:k});g=g.parentNode,k++}}return c}var l=S.test(a)||typeof a!="string"?f(a,b||this.context):0;for(d=0,e=this.length;d<e;d++){g=this[d];while(g){if(l?l.index(g)>-1:f.find.matchesSelector(g,a)){c.push(g);break}g=g.parentNode;if(!g||!g.ownerDocument||g===b||g.nodeType===11)break}}c=c.length>1?f.unique(c):c;return this.pushStack(c,"closest",a)},index:function(a){if(!a)return this[0]&&this[0].parentNode?this.prevAll().length:-1;if(typeof a=="string")return f.inArray(this[0],f(a));return f.inArray(a.jquery?a[0]:a,this)},add:function(a,b){var c=typeof a=="string"?f(a,b):f.makeArray(a&&a.nodeType?[a]:a),d=f.merge(this.get(),c);return this.pushStack(U(c[0])||U(d[0])?d:f.unique(d))},andSelf:function(){return this.add(this.prevObject)}}),f.each({parent:function(a){var b=a.parentNode;return b&&b.nodeType!==11?b:null},parents:function(a){return f.dir(a,"parentNode")},parentsUntil:function(a,b,c){return f.dir(a,"parentNode",c)},next:function(a){return f.nth(a,2,"nextSibling")},prev:function(a){return f.nth(a,2,"previousSibling")},nextAll:function(a){return f.dir(a,"nextSibling")},prevAll:function(a){return f.dir(a,"previousSibling")},nextUntil:function(a,b,c){return f.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return f.dir(a,"previousSibling",c)},siblings:function(a){return f.sibling(a.parentNode.firstChild,a)},children:function(a){return f.sibling(a.firstChild)},contents:function(a){return f.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:f.makeArray(a.childNodes)}},function(a,b){f.fn[a]=function(c,d){var e=f.map(this,b,c),g=R.call(arguments);N.test(a)||(d=c),d&&typeof d=="string"&&(e=f.filter(d,e)),e=this.length>1&&!T[a]?f.unique(e):e,(this.length>1||P.test(d))&&O.test(a)&&(e=e.reverse());return this.pushStack(e,a,g.join(","))}}),f.extend({filter:function(a,b,c){c&&(a=":not("+a+")");return b.length===1?f.find.matchesSelector(b[0],a)?[b[0]]:[]:f.find.matches(a,b)},dir:function(a,c,d){var e=[],g=a[c];while(g&&g.nodeType!==9&&(d===b||g.nodeType!==1||!f(g).is(d)))g.nodeType===1&&e.push(g),g=g[c];return e},nth:function(a,b,c,d){b=b||1;var e=0;for(;a;a=a[c])if(a.nodeType===1&&++e===b)break;return a},sibling:function(a,b){var c=[];for(;a;a=a.nextSibling)a.nodeType===1&&a!==b&&c.push(a);return c}});var W=/ jQuery\d+="(?:\d+|null)"/g,X=/^\s+/,Y=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,Z=/<([\w:]+)/,$=/<tbody/i,_=/<|&#?\w+;/,ba=/<(?:script|object|embed|option|style)/i,bb=/checked\s*(?:[^=]|=\s*.checked.)/i,bc=/\/(java|ecma)script/i,bd=/^\s*<!(?:\[CDATA\[|\-\-)/,be={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],area:[1,"<map>","</map>"],_default:[0,"",""]};be.optgroup=be.option,be.tbody=be.tfoot=be.colgroup=be.caption=be.thead,be.th=be.td,f.support.htmlSerialize||(be._default=[1,"div<div>","</div>"]),f.fn.extend({text:function(a){if(f.isFunction(a))return this.each(function(b){var c=f(this);c.text(a.call(this,b,c.text()))});if(typeof a!="object"&&a!==b)return this.empty().append((this[0]&&this[0].ownerDocument||c).createTextNode(a));return f.text(this)},wrapAll:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapAll(a.call(this,b))});if(this[0]){var b=f(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&a.firstChild.nodeType===1)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){if(f.isFunction(a))return this.each(function(b){f(this).wrapInner(a.call(this,b))});return this.each(function(){var b=f(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){return this.each(function(){f(this).wrapAll(a)})},unwrap:function(){return this.parent().each(function(){f.nodeName(this,"body")||f(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,!0,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this)});if(arguments.length){var a=f(arguments[0]);a.push.apply(a,this.toArray());return this.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this.nextSibling)});if(arguments.length){var a=this.pushStack(this,"after",arguments);a.push.apply(a,f(arguments[0]).toArray());return a}},remove:function(a,b){for(var c=0,d;(d=this[c])!=null;c++)if(!a||f.filter(a,[d]).length)!b&&d.nodeType===1&&(f.cleanData(d.getElementsByTagName("*")),f.cleanData([d])),d.parentNode&&d.parentNode.removeChild(d);return this},empty:function(){for(var a=0,b;(b=this[a])!=null;a++){b.nodeType===1&&f.cleanData(b.getElementsByTagName("*"));while(b.firstChild)b.removeChild(b.firstChild)}return this},clone:function(a,b){a=a==null?!1:a,b=b==null?a:b;return this.map(function(){return f.clone(this,a,b)})},html:function(a){if(a===b)return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(W,""):null;if(typeof a=="string"&&!ba.test(a)&&(f.support.leadingWhitespace||!X.test(a))&&!be[(Z.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Y,"<$1></$2>");try{for(var c=0,d=this.length;c<d;c++)this[c].nodeType===1&&(f.cleanData(this[c].getElementsByTagName("*")),this[c].innerHTML=a)}catch(e){this.empty().append(a)}}else f.isFunction(a)?this.each(function(b){var c=f(this);c.html(a.call(this,b,c.html()))}):this.empty().append(a);return this},replaceWith:function(a){if(this[0]&&this[0].parentNode){if(f.isFunction(a))return this.each(function(b){var c=f(this),d=c.html();c.replaceWith(a.call(this,b,d))});typeof a!="string"&&(a=f(a).detach());return this.each(function(){var b=this.nextSibling,c=this.parentNode;f(this).remove(),b?f(b).before(a):f(c).append(a)})}return this.length?this.pushStack(f(f.isFunction(a)?a():a),"replaceWith",a):this},detach:function(a){return this.remove(a,!0)},domManip:function(a,c,d){var e,g,h,i,j=a[0],k=[];if(!f.support.checkClone&&arguments.length===3&&typeof j=="string"&&bb.test(j))return this.each(function(){f(this).domManip(a,c,d,!0)});if(f.isFunction(j))return this.each(function(e){var g=f(this);a[0]=j.call(this,e,c?g.html():b),g.domManip(a,c,d)});if(this[0]){i=j&&j.parentNode,f.support.parentNode&&i&&i.nodeType===11&&i.childNodes.length===this.length?e={fragment:i}:e=f.buildFragment(a,this,k),h=e.fragment,h.childNodes.length===1?g=h=h.firstChild:g=h.firstChild;if(g){c=c&&f.nodeName(g,"tr");for(var l=0,m=this.length,n=m-1;l<m;l++)d.call(c?bf(this[l],g):this[l],e.cacheable||m>1&&l<n?f.clone(h,!0,!0):h)}k.length&&f.each(k,bl)}return this}}),f.buildFragment=function(a,b,d){var e,g,h,i;b&&b[0]&&(i=b[0].ownerDocument||b[0]),i.createDocumentFragment||(i=c),a.length===1&&typeof a[0]=="string"&&a[0].length<512&&i===c&&a[0].charAt(0)==="<"&&!ba.test(a[0])&&(f.support.checkClone||!bb.test(a[0]))&&(g=!0,h=f.fragments[a[0]],h&&h!==1&&(e=h)),e||(e=i.createDocumentFragment(),f.clean-(a,i,e,d)),g&&(f.fragments[a[0]]=h?e:1);return{fragment:e,cacheable:g}},f.fragments={},f.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){f.fn[a]=function(c){var d=[],e=f(c),g=this.length===1&&this[0].parentNode;if(g&&g.nodeType===11&&g.childNodes.length===1&&e.length===1){e[b](this[0]);return this}for(var h=0,i=e.length;h<i;h++){var j=(h>0?this.clone(!0):this).get();f(e[h])[b](j),d=d.concat(j)}return this.pushStack(d,a,e.selector)}}),f.extend({clone:function(a,b,c){var d=a.cloneNode(!0),e,g,h;if((!f.support.noCloneEvent||!f.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!f.isXMLDoc(a)){bh(a,d),e=bi(a),g=bi(d);for(h=0;e[h];++h)g[h]&&bh(e[h],g[h])}if(b){bg(a,d);if(c){e=bi(a),g=bi(d);for(h=0;e[h];++h)bg(e[h],g[h])}}e=g=null;return d},clean:function(a,b,d,e){var g;b=b||c,typeof b.createElement=="undefined"&&(b=b.ownerDocument||b[0]&&b[0].ownerDocument||c);var h=[],i;for(var j=0,k;(k=a[j])!=null;j++){typeof k=="number"&&(k+="");if(!k)continue;if(typeof k=="string")if(!_.test(k))k=b.createTextNode(k);else{k=k.replace(Y,"<$1></$2>");var l=(Z.exec(k)||["",""])[1].toLowerCase(),m=be[l]||be._default,n=m[0],o=b.createElement("div");o.innerHTML=m[1]+k+m[2];while(n--)o=o.lastChild;if(!f.support.tbody){var p=$.test(k),q=l==="table"&&!p?o.firstChild&&o.firstChild.childNodes:m[1]==="<table>"&&!p?o.childNodes:[];for(i=q.length-1;i>=0;--i)f.nodeName(q[i],"tbody")&&!q[i].childNodes.length&&q[i].parentNode.removeChild(q[i])}!f.support.leadingWhitespace&&X.test(k)&&o.insertBefore(b.createTextNode(X.exec(k)[0]),o.firstChild),k=o.childNodes}var r;if(!f.support.appendChecked)if(k[0]&&typeof (r=k.length)=="number")for(i=0;i<r;i++)bk(k[i]);else bk(k);k.nodeType?h.push(k):h=f.merge(h,k)}if(d){g=function(a){return!a.type||bc.test(a.type)};for(j=0;h[j];j++)if(e&&f.nodeName(h[j],"script")&&(!h[j].type||h[j].type.toLowerCase()==="text/javascript"))e.push(h[j].parentNode?h[j].parentNode.removeChild(h[j]):h[j]);else{if(h[j].nodeType===1){var s=f.grep(h[j].getElementsByTagName("script"),g);h.splice.apply(h,[j+1,0].concat(s))}d.appendChild(h[j])}}return h},cleanData:function(a){var b,c,d=f.cache,e=f.expando,g=f.event.special,h=f.support.deleteExpando;for(var i=0,j;(j=a[i])!=null;i++){if(j.nodeName&&f.noData[j.nodeName.toLowerCase()])continue;c=j[f.expando];if(c){b=d[c]&&d[c][e];if(b&&b.events){for(var k in b.events)g[k]?f.event.remove(j,k):f.removeEvent(j,k,b.handle);b.handle&&(b.handle.elem=null)}h?delete j[f.expando]:j.removeAttribute&&j.removeAttribute(f.expando),delete d[c]}}}});var bm=/alpha\([^)]*\)/i,bn=/opacity=([^)]*)/,bo=/([A-Z]|^ms)/g,bp=/^-?\d+(?:px)?$/i,bq=/^-?\d/,br=/^([\-+])=([\-+.\de]+)/,bs={position:"absolute",visibility:"hidden",display:"block"},bt=["Left","Right"],bu=["Top","Bottom"],bv,bw,bx;f.fn.css=function(a,c){if(arguments.length===2&&c===b)return this;return f.access(this,a,c,!0,function(a,c,d){return d!==b?f.style(a,c,d):f.css(a,c)})},f.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=bv(a,"opacity","opacity");return c===""?"1":c}return a.style.opacity}}},cssNumber:{fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":f.support.cssFloat?"cssFloat":"styleFloat"},style:function(a,c,d,e){if(!!a&&a.nodeType!==3&&a.nodeType!==8&&!!a.style){var g,h,i=f.camelCase(c),j=a.style,k=f.cssHooks[i];c=f.cssProps[i]||i;if(d===b){if(k&&"get"in k&&(g=k.get(a,!1,e))!==b)return g;return j[c]}h=typeof d,h==="string"&&(g=br.exec(d))&&(d=+(g[1]+1)*+g[2]+parseFloat(f.css(a,c)),h="number");if(d==null||h==="number"&&isNaN(d))return;h==="number"&&!f.cssNumber[i]&&(d+="px");if(!k||!("set"in k)||(d=k.set(a,d))!==b)try{j[c]=d}catch(l){}}},css:function(a,c,d){var e,g;c=f.camelCase(c),g=f.cssHooks[c],c=f.cssProps[c]||c,c==="cssFloat"&&(c="float");if(g&&"get"in g&&(e=g.get(a,!0,d))!==b)return e;if(bv)return bv(a,c)},swap:function(a,b,c){var d={};for(var e in b)d[e]=a.style[e],a.style[e]=b[e];c.call(a);for(e in b)a.style[e]=d[e]}}),f.curCSS=f.css,f.each(["height","width"],function(a,b){f.cssHooks[b]={get:function(a,c,d){var e;if(c){if(a.offsetWidth!==0)return by(a,b,d);f.swap(a,bs,function(){e=by(a,b,d)});return e}},set:function(a,b){if(!bp.test(b))return b;b=parseFloat(b);if(b>=0)return b+"px"}}}),f.support.opacity||(f.cssHooks.opacity={get:function(a,b){return bn.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?parseFloat(RegExp.$1)/100+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle,e=f.isNaN(b)?"":"alpha(opacity="+b*100+")",g=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&f.trim(g.replace(bm,""))===""){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=bm.test(g)?g.replace(bm,e):g+" "+e}}),f(function(){f.support.reliableMarginRight||(f.cssHooks.marginRight={get:function(a,b){var c;f.swap(a,{display:"inline-block"},function(){b?c=bv(a,"margin-right","marginRight"):c=a.style.marginRight});return c}})}),c.defaultView&&c.defaultView.getComputedStyle&&(bw=function(a,c){var d,e,g;c=c.replace(bo,"-$1").toLowerCase();if(!(e=a.ownerDocument.defaultView))return b;if(g=e.getComputedStyle(a,null))d=g.getPropertyValue(c),d===""&&!f.contains(a.ownerDocument.documentElement,a)&&(d=f.style(a,c));return d}),c.documentElement.currentStyle&&(bx=function(a,b){var c,d=a.currentStyle&&a.currentStyle[b],e=a.runtimeStyle&&a.runtimeStyle[b],f=a.style;!bp.test(d)&&bq.test(d)&&(c=f.left,e&&(a.runtimeStyle.left=a.currentStyle.left),f.left=b==="fontSize"?"1em":d||0,d=f.pixelLeft+"px",f.left=c,e&&(a.runtimeStyle.left=e));return d===""?"auto":d}),bv=bw||bx,f.expr&&f.expr.filters&&(f.expr.filters.hidden=function(a){var b=a.offsetWidth,c=a.offsetHeight;return b===0&&c===0||!f.support.reliableHiddenOffsets&&(a.style.display||f.css(a,"display"))==="none"},f.expr.filters.visible=function(a){return!f.expr.filters.hidden(a)});var bz=/%20/g,bA=/\[\]$/,bB=/\r?\n/g,bC=/#.*$/,bD=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,bE=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,bF=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,bG=/^(?:GET|HEAD)$/,bH=/^\/\//,bI=/\?/,bJ=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,bK=/^(?:select|textarea)/i,bL=/\s+/,bM=/([?&])_=[^&]*/,bN=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+))?)?/,bO=f.fn.load,bP={},bQ={},bR,bS,bT=["*/"]+["*"];try{bR=e.href}catch(bU){bR=c.createElement("a"),bR.href="",bR=bR.href}bS=bN.exec(bR.toLowerCase())||[],f.fn.extend({load:function(a,c,d){if(typeof a!="string"&&bO)return bO.apply(this,arguments);if(!this.length)return this;var e=a.indexOf(" ");if(e>=0){var g=a.slice(e,a.length);a=a.slice(0,e)}var h="GET";c&&(f.isFunction(c)?(d=c,c=b):typeof c=="object"&&(c=f.param(c,f.ajaxSettings.traditional),h="POST"));var i=this;f.ajax({url:a,type:h,dataType:"html",data:c,complete:function(a,b,c){c=a.responseText,a.isResolved()&&(a.done(function(a){c=a}),i.html(g?f("<div>").append(c.replace(bJ,"")).find(g):c)),d&&i.each(d,[c,b,a])}});return this},serialize:function(){return f.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?f.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||bK.test(this.nodeName)||bE.test(this.type))}).map(function(a,b){var c=f(this).val();return c==null?null:f.isArray(c)?f.map(c,function(a,c){return{name:b.name,value:a.replace(bB,"\r\n")}}):{name:b.name,value:c.replace(bB,"\r\n")}}).get()}}),f.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){f.fn[b]=function(a){return this.bind(b,a)}}),f.each(["get","post"],function(a,c){f[c]=function(a,d,e,g){f.isFunction(d)&&(g=g||e,e=d,d=b);return f.ajax({type:c,url:a,data:d,success:e,dataType:g})}}),f.extend({getScript:function(a,c){return f.get(a,b,c,"script")},getJSON:function(a,b,c){return f.get(a,b,c,"json")},ajaxSetup:function(a,b){b?bX(a,f.ajaxSettings):(b=a,a=f.ajaxSettings),bX(a,b);return a},ajaxSettings:{url:bR,isLocal:bF.test(bS[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":bT},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":a.String,"text html":!0,"text json":f.parseJSON,"text xml":f.parseXML},flatOptions:{context:!0,url:!0}},ajaxPrefilter:bV(bP),ajaxTransport:bV(bQ),ajax:function(a,c){function w(a,c,l,m){if(s!==2){s=2,q&&clearTimeout(q),p=b,n=m||"",v.readyState=a>0?4:0;var o,r,u,w=c,x=l?bZ(d,v,l):b,y,z;if(a>=200&&a<300||a===304){if(d.ifModified){if(y=v.getResponseHeader("Last-Modified"))f.lastModified[k]=y;if(z=v.getResponseHeader("Etag"))f.etag[k]=z}if(a===304)w="notmodified",o=!0;else try{r=b$(d,x),w="success",o=!0}catch(A){w="parsererror",u=A}}else{u=w;if(!w||a)w="error",a<0&&(a=0)}v.status=a,v.statusText=""+(c||w),o?h.resolveWith(e,[r,w,v]):h.rejectWith(e,[v,w,u]),v.statusCode(j),j=b,t&&g.trigger("ajax"+(o?"Success":"Error"),[v,d,o?r:u]),i.resolveWith(e,[v,w]),t&&(g.trigger("ajaxComplete",[v,d]),--f.active||f.event.trigger("ajaxStop"))}}typeof a=="object"&&(c=a,a=b),c=c||{};var d=f.ajaxSetup({},c),e=d.context||d,g=e!==d&&(e.nodeType||e instanceof f)?f(e):f.event,h=f.Deferred(),i=f._Deferred(),j=d.statusCode||{},k,l={},m={},n,o,p,q,r,s=0,t,u,v={readyState:0,setRequestHeader:function(a,b){if(!s){var c=a.toLowerCase();a=m[c]=m[c]||a,l[a]=b}return this},getAllResponseHeaders:function(){return s===2?n:null},getResponseHeader:function(a){var c;if(s===2){if(!o){o={};while(c=bD.exec(n))o[c[1].toLowerCase()]=c[2]}c=o[a.toLowerCase()]}return c===b?null:c},overrideMimeType:function(a){s||(d.mimeType=a);return this},abort:function(a){a=a||"abort",p&&p.abort(a),w(0,a);return this}};h.promise(v),v.success=v.done,v.error=v.fail,v.complete=i.done,v.statusCode=function(a){if(a){var b;if(s<2)for(b in a)j[b]=[j[b],a[b]];else b=a[v.status],v.then(b,b)}return this},d.url=((a||d.url)+"").replace(bC,"").replace(bH,bS[1]+"//"),d.dataTypes=f.trim(d.dataType||"*").toLowerCase().split(bL),d.crossDomain==null&&(r=bN.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]==bS[1]&&r[2]==bS[2]&&(r[3]||(r[1]==="http:"?80:443))==(bS[3]||(bS[1]==="http:"?80:443)))),d.data&&d.processData&&typeof d.data!="string"&&(d.data=f.param(d.data,d.traditional)),bW(bP,d,c,v);if(s===2)return!1;t=d.global,d.type=d.type.toUpperCase(),d.hasContent=!bG.test(d.type),t&&f.active++===0&&f.event.trigger("ajaxStart");if(!d.hasContent){d.data&&(d.url+=(bI.test(d.url)?"&":"?")+d.data,delete d.data),k=d.url;if(d.cache===!1){var x=f.now(),y=d.url.replace(bM,"$1_="+x);d.url=y+(y===d.url?(bI.test(d.url)?"&":"?")+"_="+x:"")}}(d.data&&d.hasContent&&d.contentType!==!1||c.contentType)&&v.setRequestHeader("Content-Type",d.contentType),d.ifModified&&(k=k||d.url,f.lastModified[k]&&v.setRequestHeader("If-Modified-Since",f.lastModified[k]),f.etag[k]&&v.setRequestHeader("If-None-Match",f.etag[k])),v.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+(d.dataTypes[0]!=="*"?", "+bT+"; q=0.01":""):d.accepts["*"]);for(u in d.headers)v.setRequestHeader(u,d.headers[u]);if(d.beforeSend&&(d.beforeSend.call(e,v,d)===!1||s===2)){v.abort();return!1}for(u in{success:1,error:1,complete:1})v[u](d[u]);p=bW(bQ,d,c,v);if(!p)w(-1,"No Transport");else{v.readyState=1,t&&g.trigger("ajaxSend",[v,d]),d.async&&d.timeout>0&&(q=setTimeout(function(){v.abort("timeout")},d.timeout));try{s=1,p.send(l,w)}catch(z){s<2?w(-1,z):f.error(z)}}return v},param:function(a,c){var d=[],e=function(a,b){b=f.isFunction(b)?b():b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};c===b&&(c=f.ajaxSettings.traditional);if(f.isArray(a)||a.jquery&&!f.isPlainObject(a))f.each(a,function(){e(this.name,this.value)});else for(var g in a)bY(g,a[g],c,e);return d.join("&").replace(bz,"+")}}),f.extend({active:0,lastModified:{},etag:{}});var b_=f.now(),ca=/(\=)\?(&|$)|\?\?/i;f.ajaxSetup({jsonp:"callback",jsonpCallback:function(){return f.expando+"_"+b_++}}),f.ajaxPrefilter("json jsonp",function(b,c,d){var e=b.contentType==="application/x-www-form-urlencoded"&&typeof b.data=="string";if(b.dataTypes[0]==="jsonp"||b.jsonp!==!1&&(ca.test(b.url)||e&&ca.test(b.data))){var g,h=b.jsonpCallback=f.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,i=a[h],j=b.url,k=b.data,l="$1"+h+"$2";b.jsonp!==!1&&(j=j.replace(ca,l),b.url===j&&(e&&(k=k.replace(ca,l)),b.data===k&&(j+=(/\?/.test(j)?"&":"?")+b.jsonp+"="+h))),b.url=j,b.data=k,a[h]=function(a){g=[a]},d.always(function(){a[h]=i,g&&f.isFunction(i)&&a[h](g[0])}),b.converters["script json"]=function(){g||f.error(h+" was not called");return g[0]},b.dataTypes[0]="json";return"script"}}),f.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(a){f.globalEval(a);return a}}}),f.ajaxPrefilter("script",function(a){a.cache===b&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),f.ajaxTransport("script",function(a){if(a.crossDomain){var d,e=c.head||c.getElementsByTagName("head")[0]||c.documentElement;return{send:function(f,g){d=c.createElement("script"),d.async="async",a.scriptCharset&&(d.charset=a.scriptCharset),d.src=a.url,d.onload=d.onreadystatechange=function(a,c){if(c||!d.readyState||/loaded|complete/.test(d.readyState))d.onload=d.onreadystatechange=null,e&&d.parentNode&&e.removeChild(d),d=b,c||g(200,"success")},e.insertBefore(d,e.firstChild)},abort:function(){d&&d.onload(0,1)}}}});var cb=a.ActiveXObject?function(){for(var a in cd)cd[a](0,1)}:!1,cc=0,cd;f.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&ce()||cf()}:ce,function(a){f.extend(f.support,{ajax:!!a,cors:!!a&&"withCredentials"in a})}(f.ajaxSettings.xhr()),f.support.ajax&&f.ajaxTransport(function(c){if(!c.crossDomain||f.support.cors){var d;return{send:function(e,g){var h=c.xhr(),i,j;c.username?h.open(c.type,c.url,c.async,c.username,c.password):h.open(c.type,c.url,c.async);if(c.xhrFields)for(j in c.xhrFields)h[j]=c.xhrFields[j];c.mimeType&&h.overrideMimeType&&h.overrideMimeType(c.mimeType),!c.crossDomain&&!e["X-Requested-With"]&&(e["X-Requested-With"]="XMLHttpRequest");try{for(j in e)h.setRequestHeader(j,e[j])}catch(k){}h.send(c.hasContent&&c.data||null),d=function(a,e){var j,k,l,m,n;try{if(d&&(e||h.readyState===4)){d=b,i&&(h.onreadystatechange=f.noop,cb&&delete cd[i]);if(e)h.readyState!==4&&h.abort();else{j=h.status,l=h.getAllResponseHeaders(),m={},n=h.responseXML,n&&n.documentElement&&(m.xml=n),m.text=h.responseText;try{k=h.statusText}catch(o){k=""}!j&&c.isLocal&&!c.crossDomain?j=m.text?200:404:j===1223&&(j=204)}}}catch(p){e||g(-1,p)}m&&g(j,k,m,l)},!c.async||h.readyState===4?d():(i=++cc,cb&&(cd||(cd={},f(a).unload(cb)),cd[i]=d),h.onreadystatechange=d)},abort:function(){d&&d(0,1)}}}});var cg={},ch,ci,cj=/^(?:toggle|show|hide)$/,ck=/^([+\-]=)?([\d+.\-]+)([a-z%]*)$/i,cl,cm=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]],cn;f.fn.extend({show:function(a,b,c){var d,e;if(a||a===0)return this.animate(cq("show",3),a,b,c);for(var g=0,h=this.length;g<h;g++)d=this[g],d.style&&(e=d.style.display,!f._data(d,"olddisplay")&&e==="none"&&(e=d.style.display=""),e===""&&f.css(d,"display")==="none"&&f._data(d,"olddisplay",cr(d.nodeName)));for(g=0;g<h;g++){d=this[g];if(d.style){e=d.style.display;if(e===""||e==="none")d.style.display=f._data(d,"olddisplay")||""}}return this},hide:function(a,b,c){if(a||a===0)return this.animate(cq("hide",3),a,b,c);for(var d=0,e=this.length;d<e;d++)if(this[d].style){var g=f.css(this[d],"display");g!=="none"&&!f._data(this[d],"olddisplay")&&f._data(this[d],"olddisplay",g)}for(d=0;d<e;d++)this[d].style&&(this[d].style.display="none");return this},_toggle:f.fn.toggle,toggle:function(a,b,c){var d=typeof a=="boolean";f.isFunction(a)&&f.isFunction(b)?this._toggle.apply(this,arguments):a==null||d?this.each(function(){var b=d?a:f(this).is(":hidden");f(this)[b?"show":"hide"]()}):this.animate(cq("toggle",3),a,b,c);return this},fadeTo:function(a,b,c,d){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=f.speed(b,c,d);if(f.isEmptyObject(a))return this.each(e.complete,[!1]);a=f.extend({},a);return this[e.queue===!1?"each":"queue"](function(){e.queue===!1&&f._mark(this);var b=f.extend({},e),c=this.nodeType===1,d=c&&f(this).is(":hidden"),g,h,i,j,k,l,m,n,o;b.animatedProperties={};for(i in a){g=f.camelCase(i),i!==g&&(a[g]=a[i],delete a[i]),h=a[g],f.isArray(h)?(b.animatedProperties[g]=h[1],h=a[g]=h[0]):b.animatedProperties[g]=b.specialEasing&&b.specialEasing[g]||b.easing||"swing";if(h==="hide"&&d||h==="show"&&!d)return b.complete.call(this);c&&(g==="height"||g==="width")&&(b.overflow=[this.style.overflow,this.style.overflowX,this.style.overflowY],f.css(this,"display")==="inline"&&f.css(this,"float")==="none"&&(f.support.inlineBlockNeedsLayout?(j=cr(this.nodeName),j==="inline"?this.style.display="inline-block":(this.style.display="inline",this.style.zoom=1)):this.style.display="inline-block"))}b.overflow!=null&&(this.style.overflow="hidden");for(i in a)k=new f.fx(this,b,i),h=a[i],cj.test(h)?k[h==="toggle"?d?"show":"hide":h]():(l=ck.exec(h),m=k.cur(),l?(n=parseFloat(l[2]),o=l[3]||(f.cssNumber[i]?"":"px"),o!=="px"&&(f.style(this,i,(n||1)+o),m=(n||1)/k.cur()*m,f.style(this,i,m+o)),l[1]&&(n=(l[1]==="-="?-1:1)*n+m),k.custom(m,n,o)):k.custom(m,h,""));return!0})},stop:function(a,b){a&&this.queue([]),this.each(function(){var a=f.timers,c=a.length;b||f._unmark(!0,this);while(c--)a[c].elem===this&&(b&&a[c](!0),a.splice(c,1))}),b||this.dequeue();return this}}),f.each({slideDown:cq("show",1),slideUp:cq("hide",1),slideToggle:cq("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){f.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),f.extend({speed:function(a,b,c){var d=a&&typeof a=="object"?f.extend({},a):{complete:c||!c&&b||f.isFunction(a)&&a,duration:a,easing:c&&b||b&&!f.isFunction(b)&&b};d.duration=f.fx.off?0:typeof d.duration=="number"?d.duration:d.duration in f.fx.speeds?f.fx.speeds[d.duration]:f.fx.speeds._default,d.old=d.complete,d.complete=function(a){f.isFunction(d.old)&&d.old.call(this),d.queue!==!1?f.dequeue(this):a!==!1&&f._unmark(this)};return d},easing:{linear:function(a,b,c,d){return c+d*a},swing:function(a,b,c,d){return(-Math.cos(a*Math.PI)/2+.5)*d+c}},timers:[],fx:function(a,b,c){this.options=b,this.elem=a,this.prop=c,b.orig=b.orig||{}}}),f.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this),(f.fx.step[this.prop]||f.fx.step._default)(this)},cur:function(){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null))return this.elem[this.prop];var a,b=f.css(this.elem,this.prop);return isNaN(a=parseFloat(b))?!b||b==="auto"?0:b:a},custom:function(a,b,c){function g(a){return d.step(a)}var d=this,e=f.fx;this.startTime=cn||co(),this.start=a,this.end=b,this.unit=c||this.unit||(f.cssNumber[this.prop]?"":"px"),this.now=this.start,this.pos=this.state=0,g.elem=this.elem,g()&&f.timers.push(g)&&!cl&&(cl=setInterval(e.tick,e.interval))},show:function(){this.options.orig[this.prop]=f.style(this.elem,this.prop),this.options.show=!0,this.custom(this.prop==="width"||this.prop==="height"?1:0,this.cur()),f(this.elem).show()},hide:function(){this.options.orig[this.prop]=f.style(this.elem,this.prop),this.options.hide=!0,this.custom(this.cur(),0)},step:function(a){var b=cn||co(),c=!0,d=this.elem,e=this.options,g,h;if(a||b>=e.duration+this.startTime){this.now=this.end,this.pos=this.state=1,this.update(),e.animatedProperties[this.prop]=!0;for(g in e.animatedProperties)e.animatedProperties[g]!==!0&&(c=!1);if(c){e.overflow!=null&&!f.support.shrinkWrapBlocks&&f.each(["","X","Y"],function(a,b){d.style["overflow"+b]=e.overflow[a]}),e.hide&&f(d).hide();if(e.hide||e.show)for(var i in e.animatedProperties)f.style(d,i,e.orig[i]);e.complete.call(d)}return!1}e.duration==Infinity?this.now=b:(h=b-this.startTime,this.state=h/e.duration,this.pos=f.easing[e.animatedProperties[this.prop]](this.state,h,0,1,e.duration),this.now=this.start+(this.end-this.start)*this.pos),this.update();return!0}},f.extend(f.fx,{tick:function(){for(var a=f.timers,b=0;b<a.length;++b)a[b]()||a.splice(b--,1);a.length||f.fx.stop()},interval:13,stop:function(){clearInterval(cl),cl=null},speeds:{slow:600,fast:200,_default:400},step:{opacity:function(a){f.style(a.elem,"opacity",a.now)},_default:function(a){a.elem.style&&a.elem.style[a.prop]!=null?a.elem.style[a.prop]=(a.prop==="width"||a.prop==="height"?Math.max(0,a.now):a.now)+a.unit:a.elem[a.prop]=a.now}}}),f.expr&&f.expr.filters&&(f.expr.filters.animated=function(a){return f.grep(f.timers,function(b){return a===b.elem}).length});var cs=/^t(?:able|d|h)$/i,ct=/^(?:body|html)$/i;"getBoundingClientRect"in c.documentElement?f.fn.offset=function(a){var b=this[0],c;if(a)return this.each(function(b){f.offset.setOffset(this,a,b)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return f.offset.bodyOffset(b);try{c=b.getBoundingClientRect()}catch(d){}var e=b.ownerDocument,g=e.documentElement;if(!c||!f.contains(g,b))return c?{top:c.top,left:c.left}:{top:0,left:0};var h=e.body,i=cu(e),j=g.clientTop||h.clientTop||0,k=g.clientLeft||h.clientLeft||0,l=i.pageYOffset||f.support.boxModel&&g.scrollTop||h.scrollTop,m=i.pageXOffset||f.support.boxModel&&g.scrollLeft||h.scrollLeft,n=c.top+l-j,o=c.left+m-k;return{top:n,left:o}}:f.fn.offset=function(a){var b=this[0];if(a)return this.each(function(b){f.offset.setOffset(this,a,b)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return f.offset.bodyOffset(b);f.offset.initialize();var c,d=b.offsetParent,e=b,g=b.ownerDocument,h=g.documentElement,i=g.body,j=g.defaultView,k=j?j.getComputedStyle(b,null):b.currentStyle,l=b.offsetTop,m=b.offsetLeft;while((b=b.parentNode)&&b!==i&&b!==h){if(f.offset.supportsFixedPosition&&k.position==="fixed")break;c=j?j.getComputedStyle(b,null):b.currentStyle,l-=b.scrollTop,m-=b.scrollLeft,b===d&&(l+=b.offsetTop,m+=b.offsetLeft,f.offset.doesNotAddBorder&&(!f.offset.doesAddBorderForTableAndCells||!cs.test(b.nodeName))&&(l+=parseFloat(c.borderTopWidth)||0,m+=parseFloat(c.borderLeftWidth)||0),e=d,d=b.offsetParent),f.offset.subtractsBorderForOverflowNotVisible&&c.overflow!=="visible"&&(l+=parseFloat(c.borderTopWidth)||0,m+=parseFloat(c.borderLeftWidth)||0),k=c}if(k.position==="relative"||k.position==="static")l+=i.offsetTop,m+=i.offsetLeft;f.offset.supportsFixedPosition&&k.position==="fixed"&&(l+=Math.max(h.scrollTop,i.scrollTop),m+=Math.max(h.scrollLeft,i.scrollLeft));return{top:l,left:m}},f.offset={initialize:function(){var a=c.body,b=c.createElement("div"),d,e,g,h,i=parseFloat(f.css(a,"marginTop"))||0,j="<div style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;'><div></div></div><table style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;' cellpadding='0' cellspacing='0'><tr><td></td></tr></table>";f.extend(b.style,{position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"}),b.innerHTML=j,a.insertBefore(b,a.firstChild),d=b.firstChild,e=d.firstChild,h=d.nextSibling.firstChild.firstChild,this.doesNotAddBorder=e.offsetTop!==5,this.doesAddBorderForTableAndCells=h.offsetTop===5,e.style.position="fixed",e.style.top="20px",this.supportsFixedPosition=e.offsetTop===20||e.offsetTop===15,e.style.position=e.style.top="",d.style.overflow="hidden",d.style.position="relative",this.subtractsBorderForOverflowNotVisible=e.offsetTop===-5,this.doesNotIncludeMarginInBodyOffset=a.offsetTop!==i,a.removeChild(b),f.offset.initialize=f.noop},bodyOffset:function(a){var b=a.offsetTop,c=a.offsetLeft;f.offset.initialize(),f.offset.doesNotIncludeMarginInBodyOffset&&(b+=parseFloat(f.css(a,"marginTop"))||0,c+=parseFloat(f.css(a,"marginLeft"))||0);return{top:b,left:c}},setOffset:function(a,b,c){var d=f.css(a,"position");d==="static"&&(a.style.position="relative");var e=f(a),g=e.offset(),h=f.css(a,"top"),i=f.css(a,"left"),j=(d==="absolute"||d==="fixed")&&f.inArray("auto",[h,i])>-1,k={},l={},m,n;j?(l=e.position(),m=l.top,n=l.left):(m=parseFloat(h)||0,n=parseFloat(i)||0),f.isFunction(b)&&(b=b.call(a,c,g)),b.top!=null&&(k.top=b.top-g.top+m),b.left!=null&&(k.left=b.left-g.left+n),"using"in b?b.using.call(a,k):e.css(k)}},f.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),c=this.offset(),d=ct.test(b[0].nodeName)?{top:0,left:0}:b.offset();c.top-=parseFloat(f.css(a,"marginTop"))||0,c.left-=parseFloat(f.css(a,"marginLeft"))||0,d.top+=parseFloat(f.css(b[0],"borderTopWidth"))||0,d.left+=parseFloat(f.css(b[0],"borderLeftWidth"))||0;return{top:c.top-d.top,left:c.left-d.left}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||c.body;while(a&&!ct.test(a.nodeName)&&f.css(a,"position")==="static")a=a.offsetParent;return a})}}),f.each(["Left","Top"],function(a,c){var d="scroll"+c;f.fn[d]=function(c){var e,g;if(c===b){e=this[0];if(!e)return null;g=cu(e);return g?"pageXOffset"in g?g[a?"pageYOffset":"pageXOffset"]:f.support.boxModel&&g.document.documentElement[d]||g.document.body[d]:e[d]}return this.each(function(){g=cu(this),g?g.scrollTo(a?f(g).scrollLeft():c,a?c:f(g).scrollTop()):this[d]=c})}}),f.each(["Height","Width"],function(a,c){var d=c.toLowerCase();f.fn["inner"+c]=function(){var a=this[0];return a&&a.style?parseFloat(f.css(a,d,"padding")):null},f.fn["outer"+c]=function(a){var b=this[0];return b&&b.style?parseFloat(f.css(b,d,a?"margin":"border")):null},f.fn[d]=function(a){var e=this[0];if(!e)return a==null?null:this;if(f.isFunction(a))return this.each(function(b){var c=f(this);c[d](a.call(this,b,c[d]()))});if(f.isWindow(e)){var g=e.document.documentElement["client"+c],h=e.document.body;return e.document.compatMode==="CSS1Compat"&&g||h&&h["client"+c]||g}if(e.nodeType===9)return Math.max(e.documentElement["client"+c],e.body["scroll"+c],e.documentElement["scroll"+c],e.body["offset"+c],e.documentElement["offset"+c]);if(a===b){var i=f.css(e,d),j=parseFloat(i);return f.isNaN(j)?i:j}return this.css(d,typeof a=="string"?a:a+"px")}}),a.jQuery=a.$=f})(window);
+ templates/js/jquery-2.1.1.min.js view
@@ -0,0 +1,4 @@+/*! jQuery v2.1.1 | (c) 2005, 2014 jQuery Foundation, Inc. | jquery.org/license */+!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=c.slice,e=c.concat,f=c.push,g=c.indexOf,h={},i=h.toString,j=h.hasOwnProperty,k={},l=a.document,m="2.1.1",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return d.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:d.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a,b){return n.each(this,a,b)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(d.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:f,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(a=arguments[h]))for(b in a)c=g[b],d=a[b],g!==d&&(j&&d&&(n.isPlainObject(d)||(e=n.isArray(d)))?(e?(e=!1,f=c&&n.isArray(c)?c:[]):f=c&&n.isPlainObject(c)?c:{},g[b]=n.extend(j,f,d)):void 0!==d&&(g[b]=d));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray,isWindow:function(a){return null!=a&&a===a.window},isNumeric:function(a){return!n.isArray(a)&&a-parseFloat(a)>=0},isPlainObject:function(a){return"object"!==n.type(a)||a.nodeType||n.isWindow(a)?!1:a.constructor&&!j.call(a.constructor.prototype,"isPrototypeOf")?!1:!0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?h[i.call(a)]||"object":typeof a},globalEval:function(a){var b,c=eval;a=n.trim(a),a&&(1===a.indexOf("use strict")?(b=l.createElement("script"),b.text=a,l.head.appendChild(b).parentNode.removeChild(b)):c(a))},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b,c){var d,e=0,f=a.length,g=s(a);if(c){if(g){for(;f>e;e++)if(d=b.apply(a[e],c),d===!1)break}else for(e in a)if(d=b.apply(a[e],c),d===!1)break}else if(g){for(;f>e;e++)if(d=b.call(a[e],e,a[e]),d===!1)break}else for(e in a)if(d=b.call(a[e],e,a[e]),d===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):f.call(c,a)),c},inArray:function(a,b,c){return null==b?-1:g.call(b,a,c)},merge:function(a,b){for(var c=+b.length,d=0,e=a.length;c>d;d++)a[e++]=b[d];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,f=0,g=a.length,h=s(a),i=[];if(h)for(;g>f;f++)d=b(a[f],f,c),null!=d&&i.push(d);else for(f in a)d=b(a[f],f,c),null!=d&&i.push(d);return e.apply([],i)},guid:1,proxy:function(a,b){var c,e,f;return"string"==typeof b&&(c=a[b],b=a,a=c),n.isFunction(a)?(e=d.call(arguments,2),f=function(){return a.apply(b||this,e.concat(d.call(arguments)))},f.guid=a.guid=a.guid||n.guid++,f):void 0},now:Date.now,support:k}),n.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(a,b){h["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:1===a.nodeType&&b?!0:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+-new Date,v=a.document,w=0,x=0,y=gb(),z=gb(),A=gb(),B=function(a,b){return a===b&&(l=!0),0},C="undefined",D=1<<31,E={}.hasOwnProperty,F=[],G=F.pop,H=F.push,I=F.push,J=F.slice,K=F.indexOf||function(a){for(var b=0,c=this.length;c>b;b++)if(this[b]===a)return b;return-1},L="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",N="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",O=N.replace("w","w#"),P="\\["+M+"*("+N+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+O+"))|)"+M+"*\\]",Q=":("+N+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+P+")*)|.*)\\)|)",R=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),S=new RegExp("^"+M+"*,"+M+"*"),T=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),U=new RegExp("="+M+"*([^\\]'\"]*?)"+M+"*\\]","g"),V=new RegExp(Q),W=new RegExp("^"+O+"$"),X={ID:new RegExp("^#("+N+")"),CLASS:new RegExp("^\\.("+N+")"),TAG:new RegExp("^("+N.replace("w","w*")+")"),ATTR:new RegExp("^"+P),PSEUDO:new RegExp("^"+Q),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+L+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/^(?:input|select|textarea|button)$/i,Z=/^h\d$/i,$=/^[^{]+\{\s*\[native \w/,_=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ab=/[+~]/,bb=/'|\\/g,cb=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),db=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)};try{I.apply(F=J.call(v.childNodes),v.childNodes),F[v.childNodes.length].nodeType}catch(eb){I={apply:F.length?function(a,b){H.apply(a,J.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function fb(a,b,d,e){var f,h,j,k,l,o,r,s,w,x;if((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,d=d||[],!a||"string"!=typeof a)return d;if(1!==(k=b.nodeType)&&9!==k)return[];if(p&&!e){if(f=_.exec(a))if(j=f[1]){if(9===k){if(h=b.getElementById(j),!h||!h.parentNode)return d;if(h.id===j)return d.push(h),d}else if(b.ownerDocument&&(h=b.ownerDocument.getElementById(j))&&t(b,h)&&h.id===j)return d.push(h),d}else{if(f[2])return I.apply(d,b.getElementsByTagName(a)),d;if((j=f[3])&&c.getElementsByClassName&&b.getElementsByClassName)return I.apply(d,b.getElementsByClassName(j)),d}if(c.qsa&&(!q||!q.test(a))){if(s=r=u,w=b,x=9===k&&a,1===k&&"object"!==b.nodeName.toLowerCase()){o=g(a),(r=b.getAttribute("id"))?s=r.replace(bb,"\\$&"):b.setAttribute("id",s),s="[id='"+s+"'] ",l=o.length;while(l--)o[l]=s+qb(o[l]);w=ab.test(a)&&ob(b.parentNode)||b,x=o.join(",")}if(x)try{return I.apply(d,w.querySelectorAll(x)),d}catch(y){}finally{r||b.removeAttribute("id")}}}return i(a.replace(R,"$1"),b,d,e)}function gb(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function hb(a){return a[u]=!0,a}function ib(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function jb(a,b){var c=a.split("|"),e=a.length;while(e--)d.attrHandle[c[e]]=b}function kb(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||D)-(~a.sourceIndex||D);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function lb(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function mb(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function nb(a){return hb(function(b){return b=+b,hb(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function ob(a){return a&&typeof a.getElementsByTagName!==C&&a}c=fb.support={},f=fb.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=fb.setDocument=function(a){var b,e=a?a.ownerDocument||a:v,g=e.defaultView;return e!==n&&9===e.nodeType&&e.documentElement?(n=e,o=e.documentElement,p=!f(e),g&&g!==g.top&&(g.addEventListener?g.addEventListener("unload",function(){m()},!1):g.attachEvent&&g.attachEvent("onunload",function(){m()})),c.attributes=ib(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ib(function(a){return a.appendChild(e.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=$.test(e.getElementsByClassName)&&ib(function(a){return a.innerHTML="<div class='a'></div><div class='a i'></div>",a.firstChild.className="i",2===a.getElementsByClassName("i").length}),c.getById=ib(function(a){return o.appendChild(a).id=u,!e.getElementsByName||!e.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if(typeof b.getElementById!==C&&p){var c=b.getElementById(a);return c&&c.parentNode?[c]:[]}},d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){var c=typeof a.getAttributeNode!==C&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return typeof b.getElementsByTagName!==C?b.getElementsByTagName(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return typeof b.getElementsByClassName!==C&&p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=$.test(e.querySelectorAll))&&(ib(function(a){a.innerHTML="<select msallowclip=''><option selected=''></option></select>",a.querySelectorAll("[msallowclip^='']").length&&q.push("[*^$]="+M+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+M+"*(?:value|"+L+")"),a.querySelectorAll(":checked").length||q.push(":checked")}),ib(function(a){var b=e.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+M+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=$.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ib(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",Q)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=$.test(o.compareDocumentPosition),t=b||$.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===e||a.ownerDocument===v&&t(v,a)?-1:b===e||b.ownerDocument===v&&t(v,b)?1:k?K.call(k,a)-K.call(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,f=a.parentNode,g=b.parentNode,h=[a],i=[b];if(!f||!g)return a===e?-1:b===e?1:f?-1:g?1:k?K.call(k,a)-K.call(k,b):0;if(f===g)return kb(a,b);c=a;while(c=c.parentNode)h.unshift(c);c=b;while(c=c.parentNode)i.unshift(c);while(h[d]===i[d])d++;return d?kb(h[d],i[d]):h[d]===v?-1:i[d]===v?1:0},e):n},fb.matches=function(a,b){return fb(a,null,null,b)},fb.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(U,"='$1']"),!(!c.matchesSelector||!p||r&&r.test(b)||q&&q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return fb(b,n,null,[a]).length>0},fb.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},fb.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&E.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},fb.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},fb.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=fb.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=fb.selectors={cacheLength:50,createPseudo:hb,match:X,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(cb,db),a[3]=(a[3]||a[4]||a[5]||"").replace(cb,db),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||fb.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&fb.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return X.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&V.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(cb,db).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+M+")"+a+"("+M+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||typeof a.getAttribute!==C&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=fb.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h;if(q){if(f){while(p){l=b;while(l=l[p])if(h?l.nodeName.toLowerCase()===r:1===l.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){k=q[u]||(q[u]={}),j=k[a]||[],n=j[0]===w&&j[1],m=j[0]===w&&j[2],l=n&&q.childNodes[n];while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if(1===l.nodeType&&++m&&l===b){k[a]=[w,n,m];break}}else if(s&&(j=(b[u]||(b[u]={}))[a])&&j[0]===w)m=j[1];else while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if((h?l.nodeName.toLowerCase()===r:1===l.nodeType)&&++m&&(s&&((l[u]||(l[u]={}))[a]=[w,m]),l===b))break;return m-=e,m===d||m%d===0&&m/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||fb.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?hb(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=K.call(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:hb(function(a){var b=[],c=[],d=h(a.replace(R,"$1"));return d[u]?hb(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),!c.pop()}}),has:hb(function(a){return function(b){return fb(a,b).length>0}}),contains:hb(function(a){return function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:hb(function(a){return W.test(a||"")||fb.error("unsupported lang: "+a),a=a.replace(cb,db).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Z.test(a.nodeName)},input:function(a){return Y.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:nb(function(){return[0]}),last:nb(function(a,b){return[b-1]}),eq:nb(function(a,b,c){return[0>c?c+b:c]}),even:nb(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:nb(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:nb(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:nb(function(a,b,c){for(var d=0>c?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=lb(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=mb(b);function pb(){}pb.prototype=d.filters=d.pseudos,d.setFilters=new pb,g=fb.tokenize=function(a,b){var c,e,f,g,h,i,j,k=z[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){(!c||(e=S.exec(h)))&&(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=T.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(R," ")}),h=h.slice(c.length));for(g in d.filter)!(e=X[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?fb.error(a):z(a,i).slice(0)};function qb(a){for(var b=0,c=a.length,d="";c>b;b++)d+=a[b].value;return d}function rb(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(i=b[u]||(b[u]={}),(h=i[d])&&h[0]===w&&h[1]===f)return j[2]=h[2];if(i[d]=j,j[2]=a(b,c,g))return!0}}}function sb(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function tb(a,b,c){for(var d=0,e=b.length;e>d;d++)fb(a,b[d],c);return c}function ub(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(!c||c(f,d,e))&&(g.push(f),j&&b.push(h));return g}function vb(a,b,c,d,e,f){return d&&!d[u]&&(d=vb(d)),e&&!e[u]&&(e=vb(e,f)),hb(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||tb(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:ub(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=ub(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?K.call(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=ub(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):I.apply(g,r)})}function wb(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=rb(function(a){return a===b},h,!0),l=rb(function(a){return K.call(b,a)>-1},h,!0),m=[function(a,c,d){return!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d))}];f>i;i++)if(c=d.relative[a[i].type])m=[rb(sb(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return vb(i>1&&sb(m),i>1&&qb(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(R,"$1"),c,e>i&&wb(a.slice(i,e)),f>e&&wb(a=a.slice(e)),f>e&&qb(a))}m.push(c)}return sb(m)}function xb(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,m,o,p=0,q="0",r=f&&[],s=[],t=j,u=f||e&&d.find.TAG("*",k),v=w+=null==t?1:Math.random()||.1,x=u.length;for(k&&(j=g!==n&&g);q!==x&&null!=(l=u[q]);q++){if(e&&l){m=0;while(o=a[m++])if(o(l,g,h)){i.push(l);break}k&&(w=v)}c&&((l=!o&&l)&&p--,f&&r.push(l))}if(p+=q,c&&q!==p){m=0;while(o=b[m++])o(r,s,g,h);if(f){if(p>0)while(q--)r[q]||s[q]||(s[q]=G.call(i));s=ub(s)}I.apply(i,s),k&&!f&&s.length>0&&p+b.length>1&&fb.uniqueSort(i)}return k&&(w=v,j=t),r};return c?hb(f):f}return h=fb.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=wb(b[c]),f[u]?d.push(f):e.push(f);f=A(a,xb(e,d)),f.selector=a}return f},i=fb.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(cb,db),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=X.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(cb,db),ab.test(j[0].type)&&ob(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&qb(j),!a)return I.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,ab.test(a)&&ob(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ib(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ib(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||jb("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ib(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||jb("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ib(function(a){return null==a.getAttribute("disabled")})||jb(L,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),fb}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=n.expr.match.needsContext,v=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,w=/^.[^:#\[\.,]*$/;function x(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(w.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return g.call(b,a)>=0!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=this.length,d=[],e=this;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;c>b;b++)if(n.contains(e[b],this))return!0}));for(b=0;c>b;b++)n.find(a,e[b],d);return d=this.pushStack(c>1?n.unique(d):d),d.selector=this.selector?this.selector+" "+a:a,d},filter:function(a){return this.pushStack(x(this,a||[],!1))},not:function(a){return this.pushStack(x(this,a||[],!0))},is:function(a){return!!x(this,"string"==typeof a&&u.test(a)?n(a):a||[],!1).length}});var y,z=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,A=n.fn.init=function(a,b){var c,d;if(!a)return this;if("string"==typeof a){if(c="<"===a[0]&&">"===a[a.length-1]&&a.length>=3?[null,a,null]:z.exec(a),!c||!c[1]&&b)return!b||b.jquery?(b||y).find(a):this.constructor(b).find(a);if(c[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(c[1],b&&b.nodeType?b.ownerDocument||b:l,!0)),v.test(c[1])&&n.isPlainObject(b))for(c in b)n.isFunction(this[c])?this[c](b[c]):this.attr(c,b[c]);return this}return d=l.getElementById(c[2]),d&&d.parentNode&&(this.length=1,this[0]=d),this.context=l,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?"undefined"!=typeof y.ready?y.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};A.prototype=n.fn,y=n(l);var B=/^(?:parents|prev(?:Until|All))/,C={children:!0,contents:!0,next:!0,prev:!0};n.extend({dir:function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},sibling:function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c}}),n.fn.extend({has:function(a){var b=n(a,this),c=b.length;return this.filter(function(){for(var a=0;c>a;a++)if(n.contains(this,b[a]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=u.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.unique(f):f)},index:function(a){return a?"string"==typeof a?g.call(n(a),this[0]):g.call(this,a.jquery?a[0]:a):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.unique(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function D(a,b){while((a=a[b])&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return n.dir(a,"parentNode")},parentsUntil:function(a,b,c){return n.dir(a,"parentNode",c)},next:function(a){return D(a,"nextSibling")},prev:function(a){return D(a,"previousSibling")},nextAll:function(a){return n.dir(a,"nextSibling")},prevAll:function(a){return n.dir(a,"previousSibling")},nextUntil:function(a,b,c){return n.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return n.dir(a,"previousSibling",c)},siblings:function(a){return n.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return n.sibling(a.firstChild)},contents:function(a){return a.contentDocument||n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(C[a]||n.unique(e),B.test(a)&&e.reverse()),this.pushStack(e)}});var E=/\S+/g,F={};function G(a){var b=F[a]={};return n.each(a.match(E)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?F[a]||G(a):n.extend({},a);var b,c,d,e,f,g,h=[],i=!a.once&&[],j=function(l){for(b=a.memory&&l,c=!0,g=e||0,e=0,f=h.length,d=!0;h&&f>g;g++)if(h[g].apply(l[0],l[1])===!1&&a.stopOnFalse){b=!1;break}d=!1,h&&(i?i.length&&j(i.shift()):b?h=[]:k.disable())},k={add:function(){if(h){var c=h.length;!function g(b){n.each(b,function(b,c){var d=n.type(c);"function"===d?a.unique&&k.has(c)||h.push(c):c&&c.length&&"string"!==d&&g(c)})}(arguments),d?f=h.length:b&&(e=c,j(b))}return this},remove:function(){return h&&n.each(arguments,function(a,b){var c;while((c=n.inArray(b,h,c))>-1)h.splice(c,1),d&&(f>=c&&f--,g>=c&&g--)}),this},has:function(a){return a?n.inArray(a,h)>-1:!(!h||!h.length)},empty:function(){return h=[],f=0,this},disable:function(){return h=i=b=void 0,this},disabled:function(){return!h},lock:function(){return i=void 0,b||k.disable(),this},locked:function(){return!i},fireWith:function(a,b){return!h||c&&!i||(b=b||[],b=[a,b.slice?b.slice():b],d?i.push(b):j(b)),this},fire:function(){return k.fireWith(this,arguments),this},fired:function(){return!!c}};return k},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=d.call(arguments),e=c.length,f=1!==e||a&&n.isFunction(a.promise)?e:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(e){b[a]=this,c[a]=arguments.length>1?d.call(arguments):e,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(e>1)for(i=new Array(e),j=new Array(e),k=new Array(e);e>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().done(h(b,k,c)).fail(g.reject).progress(h(b,j,i)):--f;return f||g.resolveWith(k,c),g.promise()}});var H;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){(a===!0?--n.readyWait:n.isReady)||(n.isReady=!0,a!==!0&&--n.readyWait>0||(H.resolveWith(l,[n]),n.fn.triggerHandler&&(n(l).triggerHandler("ready"),n(l).off("ready"))))}});function I(){l.removeEventListener("DOMContentLoaded",I,!1),a.removeEventListener("load",I,!1),n.ready()}n.ready.promise=function(b){return H||(H=n.Deferred(),"complete"===l.readyState?setTimeout(n.ready):(l.addEventListener("DOMContentLoaded",I,!1),a.addEventListener("load",I,!1))),H.promise(b)},n.ready.promise();var J=n.access=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===n.type(c)){e=!0;for(h in c)n.access(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,n.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(n(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f};n.acceptData=function(a){return 1===a.nodeType||9===a.nodeType||!+a.nodeType};function K(){Object.defineProperty(this.cache={},0,{get:function(){return{}}}),this.expando=n.expando+Math.random()}K.uid=1,K.accepts=n.acceptData,K.prototype={key:function(a){if(!K.accepts(a))return 0;var b={},c=a[this.expando];if(!c){c=K.uid++;try{b[this.expando]={value:c},Object.defineProperties(a,b)}catch(d){b[this.expando]=c,n.extend(a,b)}}return this.cache[c]||(this.cache[c]={}),c},set:function(a,b,c){var d,e=this.key(a),f=this.cache[e];if("string"==typeof b)f[b]=c;else if(n.isEmptyObject(f))n.extend(this.cache[e],b);else for(d in b)f[d]=b[d];return f},get:function(a,b){var c=this.cache[this.key(a)];return void 0===b?c:c[b]},access:function(a,b,c){var d;return void 0===b||b&&"string"==typeof b&&void 0===c?(d=this.get(a,b),void 0!==d?d:this.get(a,n.camelCase(b))):(this.set(a,b,c),void 0!==c?c:b)},remove:function(a,b){var c,d,e,f=this.key(a),g=this.cache[f];if(void 0===b)this.cache[f]={};else{n.isArray(b)?d=b.concat(b.map(n.camelCase)):(e=n.camelCase(b),b in g?d=[b,e]:(d=e,d=d in g?[d]:d.match(E)||[])),c=d.length;while(c--)delete g[d[c]]}},hasData:function(a){return!n.isEmptyObject(this.cache[a[this.expando]]||{})},discard:function(a){a[this.expando]&&delete this.cache[a[this.expando]]}};var L=new K,M=new K,N=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function P(a,b,c){var d;if(void 0===c&&1===a.nodeType)if(d="data-"+b.replace(O,"-$1").toLowerCase(),c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:N.test(c)?n.parseJSON(c):c}catch(e){}M.set(a,b,c)}else c=void 0;return c}n.extend({hasData:function(a){return M.hasData(a)||L.hasData(a)},data:function(a,b,c){return M.access(a,b,c)},removeData:function(a,b){M.remove(a,b)+},_data:function(a,b,c){return L.access(a,b,c)},_removeData:function(a,b){L.remove(a,b)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=M.get(f),1===f.nodeType&&!L.get(f,"hasDataAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),P(f,d,e[d])));L.set(f,"hasDataAttrs",!0)}return e}return"object"==typeof a?this.each(function(){M.set(this,a)}):J(this,function(b){var c,d=n.camelCase(a);if(f&&void 0===b){if(c=M.get(f,a),void 0!==c)return c;if(c=M.get(f,d),void 0!==c)return c;if(c=P(f,d,void 0),void 0!==c)return c}else this.each(function(){var c=M.get(this,d);M.set(this,d,b),-1!==a.indexOf("-")&&void 0!==c&&M.set(this,a,b)})},null,b,arguments.length>1,null,!0)},removeData:function(a){return this.each(function(){M.remove(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=L.get(a,b),c&&(!d||n.isArray(c)?d=L.access(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return L.get(a,c)||L.access(a,c,{empty:n.Callbacks("once memory").add(function(){L.remove(a,[b+"queue",c])})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?n.queue(this[0],a):void 0===b?this:this.each(function(){var c=n.queue(this,a,b);n._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&n.dequeue(this,a)})},dequeue:function(a){return this.each(function(){n.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=n.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=L.get(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}});var Q=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,R=["Top","Right","Bottom","Left"],S=function(a,b){return a=b||a,"none"===n.css(a,"display")||!n.contains(a.ownerDocument,a)},T=/^(?:checkbox|radio)$/i;!function(){var a=l.createDocumentFragment(),b=a.appendChild(l.createElement("div")),c=l.createElement("input");c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),b.appendChild(c),k.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,b.innerHTML="<textarea>x</textarea>",k.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue}();var U="undefined";k.focusinBubbles="onfocusin"in a;var V=/^key/,W=/^(?:mouse|pointer|contextmenu)|click/,X=/^(?:focusinfocus|focusoutblur)$/,Y=/^([^.]*)(?:\.(.+)|)$/;function Z(){return!0}function $(){return!1}function _(){try{return l.activeElement}catch(a){}}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.get(a);if(r){c.handler&&(f=c,c=f.handler,e=f.selector),c.guid||(c.guid=n.guid++),(i=r.events)||(i=r.events={}),(g=r.handle)||(g=r.handle=function(b){return typeof n!==U&&n.event.triggered!==b.type?n.event.dispatch.apply(a,arguments):void 0}),b=(b||"").match(E)||[""],j=b.length;while(j--)h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o&&(l=n.event.special[o]||{},o=(e?l.delegateType:l.bindType)||o,l=n.event.special[o]||{},k=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},f),(m=i[o])||(m=i[o]=[],m.delegateCount=0,l.setup&&l.setup.call(a,d,p,g)!==!1||a.addEventListener&&a.addEventListener(o,g,!1)),l.add&&(l.add.call(a,k),k.handler.guid||(k.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,k):m.push(k),n.event.global[o]=!0)}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=L.hasData(a)&&L.get(a);if(r&&(i=r.events)){b=(b||"").match(E)||[""],j=b.length;while(j--)if(h=Y.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=i[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),g=f=m.length;while(f--)k=m[f],!e&&q!==k.origType||c&&c.guid!==k.guid||h&&!h.test(k.namespace)||d&&d!==k.selector&&("**"!==d||!k.selector)||(m.splice(f,1),k.selector&&m.delegateCount--,l.remove&&l.remove.call(a,k));g&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete i[o])}else for(o in i)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(i)&&(delete r.handle,L.remove(a,"events"))}},trigger:function(b,c,d,e){var f,g,h,i,k,m,o,p=[d||l],q=j.call(b,"type")?b.type:b,r=j.call(b,"namespace")?b.namespace.split("."):[];if(g=h=d=d||l,3!==d.nodeType&&8!==d.nodeType&&!X.test(q+n.event.triggered)&&(q.indexOf(".")>=0&&(r=q.split("."),q=r.shift(),r.sort()),k=q.indexOf(":")<0&&"on"+q,b=b[n.expando]?b:new n.Event(q,"object"==typeof b&&b),b.isTrigger=e?2:3,b.namespace=r.join("."),b.namespace_re=b.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=d),c=null==c?[b]:n.makeArray(c,[b]),o=n.event.special[q]||{},e||!o.trigger||o.trigger.apply(d,c)!==!1)){if(!e&&!o.noBubble&&!n.isWindow(d)){for(i=o.delegateType||q,X.test(i+q)||(g=g.parentNode);g;g=g.parentNode)p.push(g),h=g;h===(d.ownerDocument||l)&&p.push(h.defaultView||h.parentWindow||a)}f=0;while((g=p[f++])&&!b.isPropagationStopped())b.type=f>1?i:o.bindType||q,m=(L.get(g,"events")||{})[b.type]&&L.get(g,"handle"),m&&m.apply(g,c),m=k&&g[k],m&&m.apply&&n.acceptData(g)&&(b.result=m.apply(g,c),b.result===!1&&b.preventDefault());return b.type=q,e||b.isDefaultPrevented()||o._default&&o._default.apply(p.pop(),c)!==!1||!n.acceptData(d)||k&&n.isFunction(d[q])&&!n.isWindow(d)&&(h=d[k],h&&(d[k]=null),n.event.triggered=q,d[q](),n.event.triggered=void 0,h&&(d[k]=h)),b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,e,f,g,h=[],i=d.call(arguments),j=(L.get(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())(!a.namespace_re||a.namespace_re.test(g.namespace))&&(a.handleObj=g,a.data=g.data,e=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==e&&(a.result=e)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&(!a.button||"click"!==a.type))for(;i!==this;i=i.parentNode||this)if(i.disabled!==!0||"click"!==a.type){for(d=[],c=0;h>c;c++)f=b[c],e=f.selector+" ",void 0===d[e]&&(d[e]=f.needsContext?n(e,this).index(i)>=0:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h<b.length&&g.push({elem:this,handlers:b.slice(h)}),g},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,b){var c,d,e,f=b.button;return null==a.pageX&&null!=b.clientX&&(c=a.target.ownerDocument||l,d=c.documentElement,e=c.body,a.pageX=b.clientX+(d&&d.scrollLeft||e&&e.scrollLeft||0)-(d&&d.clientLeft||e&&e.clientLeft||0),a.pageY=b.clientY+(d&&d.scrollTop||e&&e.scrollTop||0)-(d&&d.clientTop||e&&e.clientTop||0)),a.which||void 0===f||(a.which=1&f?1:2&f?3:4&f?2:0),a}},fix:function(a){if(a[n.expando])return a;var b,c,d,e=a.type,f=a,g=this.fixHooks[e];g||(this.fixHooks[e]=g=W.test(e)?this.mouseHooks:V.test(e)?this.keyHooks:{}),d=g.props?this.props.concat(g.props):this.props,a=new n.Event(f),b=d.length;while(b--)c=d[b],a[c]=f[c];return a.target||(a.target=l),3===a.target.nodeType&&(a.target=a.target.parentNode),g.filter?g.filter(a,f):a},special:{load:{noBubble:!0},focus:{trigger:function(){return this!==_()&&this.focus?(this.focus(),!1):void 0},delegateType:"focusin"},blur:{trigger:function(){return this===_()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return"checkbox"===this.type&&this.click&&n.nodeName(this,"input")?(this.click(),!1):void 0},_default:function(a){return n.nodeName(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&a.originalEvent&&(a.originalEvent.returnValue=a.result)}}},simulate:function(a,b,c,d){var e=n.extend(new n.Event,c,{type:a,isSimulated:!0,originalEvent:{}});d?n.event.trigger(e,null,b):n.event.dispatch.call(b,e),e.isDefaultPrevented()&&c.preventDefault()}},n.removeEvent=function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)},n.Event=function(a,b){return this instanceof n.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&a.returnValue===!1?Z:$):this.type=a,b&&n.extend(this,b),this.timeStamp=a&&a.timeStamp||n.now(),void(this[n.expando]=!0)):new n.Event(a,b)},n.Event.prototype={isDefaultPrevented:$,isPropagationStopped:$,isImmediatePropagationStopped:$,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=Z,a&&a.preventDefault&&a.preventDefault()},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=Z,a&&a.stopPropagation&&a.stopPropagation()},stopImmediatePropagation:function(){var a=this.originalEvent;this.isImmediatePropagationStopped=Z,a&&a.stopImmediatePropagation&&a.stopImmediatePropagation(),this.stopPropagation()}},n.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(a,b){n.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return(!e||e!==d&&!n.contains(d,e))&&(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),k.focusinBubbles||n.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){n.event.simulate(b,a.target,n.event.fix(a),!0)};n.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=L.access(d,b);e||d.addEventListener(a,c,!0),L.access(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=L.access(d,b)-1;e?L.access(d,b,e):(d.removeEventListener(a,c,!0),L.remove(d,b))}}}),n.fn.extend({on:function(a,b,c,d,e){var f,g;if("object"==typeof a){"string"!=typeof b&&(c=c||b,b=void 0);for(g in a)this.on(g,b,c,a[g],e);return this}if(null==c&&null==d?(d=b,c=b=void 0):null==d&&("string"==typeof b?(d=c,c=void 0):(d=c,c=b,b=void 0)),d===!1)d=$;else if(!d)return this;return 1===e&&(f=d,d=function(a){return n().off(a),f.apply(this,arguments)},d.guid=f.guid||(f.guid=n.guid++)),this.each(function(){n.event.add(this,a,d,c,b)})},one:function(a,b,c,d){return this.on(a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,n(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return(b===!1||"function"==typeof b)&&(c=b,b=void 0),c===!1&&(c=$),this.each(function(){n.event.remove(this,a,c,b)})},trigger:function(a,b){return this.each(function(){n.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];return c?n.event.trigger(a,b,c,!0):void 0}});var ab=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,bb=/<([\w:]+)/,cb=/<|&#?\w+;/,db=/<(?:script|style|link)/i,eb=/checked\s*(?:[^=]|=\s*.checked.)/i,fb=/^$|\/(?:java|ecma)script/i,gb=/^true\/(.*)/,hb=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,ib={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};ib.optgroup=ib.option,ib.tbody=ib.tfoot=ib.colgroup=ib.caption=ib.thead,ib.th=ib.td;function jb(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function kb(a){return a.type=(null!==a.getAttribute("type"))+"/"+a.type,a}function lb(a){var b=gb.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function mb(a,b){for(var c=0,d=a.length;d>c;c++)L.set(a[c],"globalEval",!b||L.get(b[c],"globalEval"))}function nb(a,b){var c,d,e,f,g,h,i,j;if(1===b.nodeType){if(L.hasData(a)&&(f=L.access(a),g=L.set(b,f),j=f.events)){delete g.handle,g.events={};for(e in j)for(c=0,d=j[e].length;d>c;c++)n.event.add(b,e,j[e][c])}M.hasData(a)&&(h=M.access(a),i=n.extend({},h),M.set(b,i))}}function ob(a,b){var c=a.getElementsByTagName?a.getElementsByTagName(b||"*"):a.querySelectorAll?a.querySelectorAll(b||"*"):[];return void 0===b||b&&n.nodeName(a,b)?n.merge([a],c):c}function pb(a,b){var c=b.nodeName.toLowerCase();"input"===c&&T.test(a.type)?b.checked=a.checked:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}n.extend({clone:function(a,b,c){var d,e,f,g,h=a.cloneNode(!0),i=n.contains(a.ownerDocument,a);if(!(k.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(g=ob(h),f=ob(a),d=0,e=f.length;e>d;d++)pb(f[d],g[d]);if(b)if(c)for(f=f||ob(a),g=g||ob(h),d=0,e=f.length;e>d;d++)nb(f[d],g[d]);else nb(a,h);return g=ob(h,"script"),g.length>0&&mb(g,!i&&ob(a,"script")),h},buildFragment:function(a,b,c,d){for(var e,f,g,h,i,j,k=b.createDocumentFragment(),l=[],m=0,o=a.length;o>m;m++)if(e=a[m],e||0===e)if("object"===n.type(e))n.merge(l,e.nodeType?[e]:e);else if(cb.test(e)){f=f||k.appendChild(b.createElement("div")),g=(bb.exec(e)||["",""])[1].toLowerCase(),h=ib[g]||ib._default,f.innerHTML=h[1]+e.replace(ab,"<$1></$2>")+h[2],j=h[0];while(j--)f=f.lastChild;n.merge(l,f.childNodes),f=k.firstChild,f.textContent=""}else l.push(b.createTextNode(e));k.textContent="",m=0;while(e=l[m++])if((!d||-1===n.inArray(e,d))&&(i=n.contains(e.ownerDocument,e),f=ob(k.appendChild(e),"script"),i&&mb(f),c)){j=0;while(e=f[j++])fb.test(e.type||"")&&c.push(e)}return k},cleanData:function(a){for(var b,c,d,e,f=n.event.special,g=0;void 0!==(c=a[g]);g++){if(n.acceptData(c)&&(e=c[L.expando],e&&(b=L.cache[e]))){if(b.events)for(d in b.events)f[d]?n.event.remove(c,d):n.removeEvent(c,d,b.handle);L.cache[e]&&delete L.cache[e]}delete M.cache[c[M.expando]]}}}),n.fn.extend({text:function(a){return J(this,function(a){return void 0===a?n.text(this):this.empty().each(function(){(1===this.nodeType||11===this.nodeType||9===this.nodeType)&&(this.textContent=a)})},null,a,arguments.length)},append:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=jb(this,a);b.appendChild(a)}})},prepend:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=jb(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},remove:function(a,b){for(var c,d=a?n.filter(a,this):this,e=0;null!=(c=d[e]);e++)b||1!==c.nodeType||n.cleanData(ob(c)),c.parentNode&&(b&&n.contains(c.ownerDocument,c)&&mb(ob(c,"script")),c.parentNode.removeChild(c));return this},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)1===a.nodeType&&(n.cleanData(ob(a,!1)),a.textContent="");return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return J(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a&&1===b.nodeType)return b.innerHTML;if("string"==typeof a&&!db.test(a)&&!ib[(bb.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(ab,"<$1></$2>");try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(ob(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=arguments[0];return this.domManip(arguments,function(b){a=this.parentNode,n.cleanData(ob(this)),a&&a.replaceChild(b,this)}),a&&(a.length||a.nodeType)?this:this.remove()},detach:function(a){return this.remove(a,!0)},domManip:function(a,b){a=e.apply([],a);var c,d,f,g,h,i,j=0,l=this.length,m=this,o=l-1,p=a[0],q=n.isFunction(p);if(q||l>1&&"string"==typeof p&&!k.checkClone&&eb.test(p))return this.each(function(c){var d=m.eq(c);q&&(a[0]=p.call(this,c,d.html())),d.domManip(a,b)});if(l&&(c=n.buildFragment(a,this[0].ownerDocument,!1,this),d=c.firstChild,1===c.childNodes.length&&(c=d),d)){for(f=n.map(ob(c,"script"),kb),g=f.length;l>j;j++)h=c,j!==o&&(h=n.clone(h,!0,!0),g&&n.merge(f,ob(h,"script"))),b.call(this[j],h,j);if(g)for(i=f[f.length-1].ownerDocument,n.map(f,lb),j=0;g>j;j++)h=f[j],fb.test(h.type||"")&&!L.access(h,"globalEval")&&n.contains(i,h)&&(h.src?n._evalUrl&&n._evalUrl(h.src):n.globalEval(h.textContent.replace(hb,"")))}return this}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=[],e=n(a),g=e.length-1,h=0;g>=h;h++)c=h===g?this:this.clone(!0),n(e[h])[b](c),f.apply(d,c.get());return this.pushStack(d)}});var qb,rb={};function sb(b,c){var d,e=n(c.createElement(b)).appendTo(c.body),f=a.getDefaultComputedStyle&&(d=a.getDefaultComputedStyle(e[0]))?d.display:n.css(e[0],"display");return e.detach(),f}function tb(a){var b=l,c=rb[a];return c||(c=sb(a,b),"none"!==c&&c||(qb=(qb||n("<iframe frameborder='0' width='0' height='0'/>")).appendTo(b.documentElement),b=qb[0].contentDocument,b.write(),b.close(),c=sb(a,b),qb.detach()),rb[a]=c),c}var ub=/^margin/,vb=new RegExp("^("+Q+")(?!px)[a-z%]+$","i"),wb=function(a){return a.ownerDocument.defaultView.getComputedStyle(a,null)};function xb(a,b,c){var d,e,f,g,h=a.style;return c=c||wb(a),c&&(g=c.getPropertyValue(b)||c[b]),c&&(""!==g||n.contains(a.ownerDocument,a)||(g=n.style(a,b)),vb.test(g)&&ub.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f)),void 0!==g?g+"":g}function yb(a,b){return{get:function(){return a()?void delete this.get:(this.get=b).apply(this,arguments)}}}!function(){var b,c,d=l.documentElement,e=l.createElement("div"),f=l.createElement("div");if(f.style){f.style.backgroundClip="content-box",f.cloneNode(!0).style.backgroundClip="",k.clearCloneStyle="content-box"===f.style.backgroundClip,e.style.cssText="border:0;width:0;height:0;top:0;left:-9999px;margin-top:1px;position:absolute",e.appendChild(f);function g(){f.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",f.innerHTML="",d.appendChild(e);var g=a.getComputedStyle(f,null);b="1%"!==g.top,c="4px"===g.width,d.removeChild(e)}a.getComputedStyle&&n.extend(k,{pixelPosition:function(){return g(),b},boxSizingReliable:function(){return null==c&&g(),c},reliableMarginRight:function(){var b,c=f.appendChild(l.createElement("div"));return c.style.cssText=f.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",c.style.marginRight=c.style.width="0",f.style.width="1px",d.appendChild(e),b=!parseFloat(a.getComputedStyle(c,null).marginRight),d.removeChild(e),b}})}}(),n.swap=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e};var zb=/^(none|table(?!-c[ea]).+)/,Ab=new RegExp("^("+Q+")(.*)$","i"),Bb=new RegExp("^([+-])=("+Q+")","i"),Cb={position:"absolute",visibility:"hidden",display:"block"},Db={letterSpacing:"0",fontWeight:"400"},Eb=["Webkit","O","Moz","ms"];function Fb(a,b){if(b in a)return b;var c=b[0].toUpperCase()+b.slice(1),d=b,e=Eb.length;while(e--)if(b=Eb[e]+c,b in a)return b;return d}function Gb(a,b,c){var d=Ab.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function Hb(a,b,c,d,e){for(var f=c===(d?"border":"content")?4:"width"===b?1:0,g=0;4>f;f+=2)"margin"===c&&(g+=n.css(a,c+R[f],!0,e)),d?("content"===c&&(g-=n.css(a,"padding"+R[f],!0,e)),"margin"!==c&&(g-=n.css(a,"border"+R[f]+"Width",!0,e))):(g+=n.css(a,"padding"+R[f],!0,e),"padding"!==c&&(g+=n.css(a,"border"+R[f]+"Width",!0,e)));return g}function Ib(a,b,c){var d=!0,e="width"===b?a.offsetWidth:a.offsetHeight,f=wb(a),g="border-box"===n.css(a,"boxSizing",!1,f);if(0>=e||null==e){if(e=xb(a,b,f),(0>e||null==e)&&(e=a.style[b]),vb.test(e))return e;d=g&&(k.boxSizingReliable()||e===a.style[b]),e=parseFloat(e)||0}return e+Hb(a,b,c||(g?"border":"content"),d,f)+"px"}function Jb(a,b){for(var c,d,e,f=[],g=0,h=a.length;h>g;g++)d=a[g],d.style&&(f[g]=L.get(d,"olddisplay"),c=d.style.display,b?(f[g]||"none"!==c||(d.style.display=""),""===d.style.display&&S(d)&&(f[g]=L.access(d,"olddisplay",tb(d.nodeName)))):(e=S(d),"none"===c&&e||L.set(d,"olddisplay",e?c:n.css(d,"display"))));for(g=0;h>g;g++)d=a[g],d.style&&(b&&"none"!==d.style.display&&""!==d.style.display||(d.style.display=b?f[g]||"":"none"));return a}n.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=xb(a,"opacity");return""===c?"1":c}}}},cssNumber:{columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":"cssFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=n.camelCase(b),i=a.style;return b=n.cssProps[h]||(n.cssProps[h]=Fb(i,h)),g=n.cssHooks[b]||n.cssHooks[h],void 0===c?g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:i[b]:(f=typeof c,"string"===f&&(e=Bb.exec(c))&&(c=(e[1]+1)*e[2]+parseFloat(n.css(a,b)),f="number"),null!=c&&c===c&&("number"!==f||n.cssNumber[h]||(c+="px"),k.clearCloneStyle||""!==c||0!==b.indexOf("background")||(i[b]="inherit"),g&&"set"in g&&void 0===(c=g.set(a,c,d))||(i[b]=c)),void 0)}},css:function(a,b,c,d){var e,f,g,h=n.camelCase(b);return b=n.cssProps[h]||(n.cssProps[h]=Fb(a.style,h)),g=n.cssHooks[b]||n.cssHooks[h],g&&"get"in g&&(e=g.get(a,!0,c)),void 0===e&&(e=xb(a,b,d)),"normal"===e&&b in Db&&(e=Db[b]),""===c||c?(f=parseFloat(e),c===!0||n.isNumeric(f)?f||0:e):e}}),n.each(["height","width"],function(a,b){n.cssHooks[b]={get:function(a,c,d){return c?zb.test(n.css(a,"display"))&&0===a.offsetWidth?n.swap(a,Cb,function(){return Ib(a,b,d)}):Ib(a,b,d):void 0},set:function(a,c,d){var e=d&&wb(a);return Gb(a,c,d?Hb(a,b,d,"border-box"===n.css(a,"boxSizing",!1,e),e):0)}}}),n.cssHooks.marginRight=yb(k.reliableMarginRight,function(a,b){return b?n.swap(a,{display:"inline-block"},xb,[a,"marginRight"]):void 0}),n.each({margin:"",padding:"",border:"Width"},function(a,b){n.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];4>d;d++)e[a+R[d]+b]=f[d]||f[d-2]||f[0];return e}},ub.test(a)||(n.cssHooks[a+b].set=Gb)}),n.fn.extend({css:function(a,b){return J(this,function(a,b,c){var d,e,f={},g=0;if(n.isArray(b)){for(d=wb(a),e=b.length;e>g;g++)f[b[g]]=n.css(a,b[g],!1,d);return f}return void 0!==c?n.style(a,b,c):n.css(a,b)},a,b,arguments.length>1)},show:function(){return Jb(this,!0)},hide:function(){return Jb(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){S(this)?n(this).show():n(this).hide()})}});function Kb(a,b,c,d,e){return new Kb.prototype.init(a,b,c,d,e)}n.Tween=Kb,Kb.prototype={constructor:Kb,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||"swing",this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(n.cssNumber[c]?"":"px")},cur:function(){var a=Kb.propHooks[this.prop];return a&&a.get?a.get(this):Kb.propHooks._default.get(this)},run:function(a){var b,c=Kb.propHooks[this.prop];return this.pos=b=this.options.duration?n.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):Kb.propHooks._default.set(this),this}},Kb.prototype.init.prototype=Kb.prototype,Kb.propHooks={_default:{get:function(a){var b;return null==a.elem[a.prop]||a.elem.style&&null!=a.elem.style[a.prop]?(b=n.css(a.elem,a.prop,""),b&&"auto"!==b?b:0):a.elem[a.prop]},set:function(a){n.fx.step[a.prop]?n.fx.step[a.prop](a):a.elem.style&&(null!=a.elem.style[n.cssProps[a.prop]]||n.cssHooks[a.prop])?n.style(a.elem,a.prop,a.now+a.unit):a.elem[a.prop]=a.now}}},Kb.propHooks.scrollTop=Kb.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},n.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2}},n.fx=Kb.prototype.init,n.fx.step={};var Lb,Mb,Nb=/^(?:toggle|show|hide)$/,Ob=new RegExp("^(?:([+-])=|)("+Q+")([a-z%]*)$","i"),Pb=/queueHooks$/,Qb=[Vb],Rb={"*":[function(a,b){var c=this.createTween(a,b),d=c.cur(),e=Ob.exec(b),f=e&&e[3]||(n.cssNumber[a]?"":"px"),g=(n.cssNumber[a]||"px"!==f&&+d)&&Ob.exec(n.css(c.elem,a)),h=1,i=20;if(g&&g[3]!==f){f=f||g[3],e=e||[],g=+d||1;do h=h||".5",g/=h,n.style(c.elem,a,g+f);while(h!==(h=c.cur()/d)&&1!==h&&--i)}return e&&(g=c.start=+g||+d||0,c.unit=f,c.end=e[1]?g+(e[1]+1)*e[2]:+e[2]),c}]};function Sb(){return setTimeout(function(){Lb=void 0}),Lb=n.now()}function Tb(a,b){var c,d=0,e={height:a};for(b=b?1:0;4>d;d+=2-b)c=R[d],e["margin"+c]=e["padding"+c]=a;return b&&(e.opacity=e.width=a),e}function Ub(a,b,c){for(var d,e=(Rb[b]||[]).concat(Rb["*"]),f=0,g=e.length;g>f;f++)if(d=e[f].call(c,b,a))return d}function Vb(a,b,c){var d,e,f,g,h,i,j,k,l=this,m={},o=a.style,p=a.nodeType&&S(a),q=L.get(a,"fxshow");c.queue||(h=n._queueHooks(a,"fx"),null==h.unqueued&&(h.unqueued=0,i=h.empty.fire,h.empty.fire=function(){h.unqueued||i()}),h.unqueued++,l.always(function(){l.always(function(){h.unqueued--,n.queue(a,"fx").length||h.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[o.overflow,o.overflowX,o.overflowY],j=n.css(a,"display"),k="none"===j?L.get(a,"olddisplay")||tb(a.nodeName):j,"inline"===k&&"none"===n.css(a,"float")&&(o.display="inline-block")),c.overflow&&(o.overflow="hidden",l.always(function(){o.overflow=c.overflow[0],o.overflowX=c.overflow[1],o.overflowY=c.overflow[2]}));for(d in b)if(e=b[d],Nb.exec(e)){if(delete b[d],f=f||"toggle"===e,e===(p?"hide":"show")){if("show"!==e||!q||void 0===q[d])continue;p=!0}m[d]=q&&q[d]||n.style(a,d)}else j=void 0;if(n.isEmptyObject(m))"inline"===("none"===j?tb(a.nodeName):j)&&(o.display=j);else{q?"hidden"in q&&(p=q.hidden):q=L.access(a,"fxshow",{}),f&&(q.hidden=!p),p?n(a).show():l.done(function(){n(a).hide()}),l.done(function(){var b;L.remove(a,"fxshow");for(b in m)n.style(a,b,m[b])});for(d in m)g=Ub(p?q[d]:0,d,l),d in q||(q[d]=g.start,p&&(g.end=g.start,g.start="width"===d||"height"===d?1:0))}}function Wb(a,b){var c,d,e,f,g;for(c in a)if(d=n.camelCase(c),e=b[d],f=a[c],n.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=n.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function Xb(a,b,c){var d,e,f=0,g=Qb.length,h=n.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=Lb||Sb(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;i>g;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),1>f&&i?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:n.extend({},b),opts:n.extend(!0,{specialEasing:{}},c),originalProperties:b,originalOptions:c,startTime:Lb||Sb(),duration:c.duration,tweens:[],createTween:function(b,c){var d=n.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;d>c;c++)j.tweens[c].run(1);return b?h.resolveWith(a,[j,b]):h.rejectWith(a,[j,b]),this}}),k=j.props;for(Wb(k,j.opts.specialEasing);g>f;f++)if(d=Qb[f].call(j,a,k,j.opts))return d;return n.map(k,Ub,j),n.isFunction(j.opts.start)&&j.opts.start.call(a,j),n.fx.timer(n.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}n.Animation=n.extend(Xb,{tweener:function(a,b){n.isFunction(a)?(b=a,a=["*"]):a=a.split(" ");for(var c,d=0,e=a.length;e>d;d++)c=a[d],Rb[c]=Rb[c]||[],Rb[c].unshift(b)},prefilter:function(a,b){b?Qb.unshift(a):Qb.push(a)}}),n.speed=function(a,b,c){var d=a&&"object"==typeof a?n.extend({},a):{complete:c||!c&&b||n.isFunction(a)&&a,duration:a,easing:c&&b||b&&!n.isFunction(b)&&b};return d.duration=n.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in n.fx.speeds?n.fx.speeds[d.duration]:n.fx.speeds._default,(null==d.queue||d.queue===!0)&&(d.queue="fx"),d.old=d.complete,d.complete=function(){n.isFunction(d.old)&&d.old.call(this),d.queue&&n.dequeue(this,d.queue)},d},n.fn.extend({fadeTo:function(a,b,c,d){return this.filter(S).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=n.isEmptyObject(a),f=n.speed(b,c,d),g=function(){var b=Xb(this,n.extend({},a),f);(e||L.get(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=n.timers,g=L.get(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&Pb.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));(b||!c)&&n.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=L.get(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=n.timers,g=d?d.length:0;for(c.finish=!0,n.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;g>b;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),n.each(["toggle","show","hide"],function(a,b){var c=n.fn[b];n.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(Tb(b,!0),a,d,e)}}),n.each({slideDown:Tb("show"),slideUp:Tb("hide"),slideToggle:Tb("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){n.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),n.timers=[],n.fx.tick=function(){var a,b=0,c=n.timers;for(Lb=n.now();b<c.length;b++)a=c[b],a()||c[b]!==a||c.splice(b--,1);c.length||n.fx.stop(),Lb=void 0},n.fx.timer=function(a){n.timers.push(a),a()?n.fx.start():n.timers.pop()},n.fx.interval=13,n.fx.start=function(){Mb||(Mb=setInterval(n.fx.tick,n.fx.interval))},n.fx.stop=function(){clearInterval(Mb),Mb=null},n.fx.speeds={slow:600,fast:200,_default:400},n.fn.delay=function(a,b){return a=n.fx?n.fx.speeds[a]||a:a,b=b||"fx",this.queue(b,function(b,c){var d=setTimeout(b,a);c.stop=function(){clearTimeout(d)}})},function(){var a=l.createElement("input"),b=l.createElement("select"),c=b.appendChild(l.createElement("option"));a.type="checkbox",k.checkOn=""!==a.value,k.optSelected=c.selected,b.disabled=!0,k.optDisabled=!c.disabled,a=l.createElement("input"),a.value="t",a.type="radio",k.radioValue="t"===a.value}();var Yb,Zb,$b=n.expr.attrHandle;n.fn.extend({attr:function(a,b){return J(this,n.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){n.removeAttr(this,a)})}}),n.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(a&&3!==f&&8!==f&&2!==f)return typeof a.getAttribute===U?n.prop(a,b,c):(1===f&&n.isXMLDoc(a)||(b=b.toLowerCase(),d=n.attrHooks[b]||(n.expr.match.bool.test(b)?Zb:Yb)),void 0===c?d&&"get"in d&&null!==(e=d.get(a,b))?e:(e=n.find.attr(a,b),null==e?void 0:e):null!==c?d&&"set"in d&&void 0!==(e=d.set(a,c,b))?e:(a.setAttribute(b,c+""),c):void n.removeAttr(a,b))+},removeAttr:function(a,b){var c,d,e=0,f=b&&b.match(E);if(f&&1===a.nodeType)while(c=f[e++])d=n.propFix[c]||c,n.expr.match.bool.test(c)&&(a[d]=!1),a.removeAttribute(c)},attrHooks:{type:{set:function(a,b){if(!k.radioValue&&"radio"===b&&n.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}}}),Zb={set:function(a,b,c){return b===!1?n.removeAttr(a,c):a.setAttribute(c,c),c}},n.each(n.expr.match.bool.source.match(/\w+/g),function(a,b){var c=$b[b]||n.find.attr;$b[b]=function(a,b,d){var e,f;return d||(f=$b[b],$b[b]=e,e=null!=c(a,b,d)?b.toLowerCase():null,$b[b]=f),e}});var _b=/^(?:input|select|textarea|button)$/i;n.fn.extend({prop:function(a,b){return J(this,n.prop,a,b,arguments.length>1)},removeProp:function(a){return this.each(function(){delete this[n.propFix[a]||a]})}}),n.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(a,b,c){var d,e,f,g=a.nodeType;if(a&&3!==g&&8!==g&&2!==g)return f=1!==g||!n.isXMLDoc(a),f&&(b=n.propFix[b]||b,e=n.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){return a.hasAttribute("tabindex")||_b.test(a.nodeName)||a.href?a.tabIndex:-1}}}}),k.optSelected||(n.propHooks.selected={get:function(a){var b=a.parentNode;return b&&b.parentNode&&b.parentNode.selectedIndex,null}}),n.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){n.propFix[this.toLowerCase()]=this});var ac=/[\t\r\n\f]/g;n.fn.extend({addClass:function(a){var b,c,d,e,f,g,h="string"==typeof a&&a,i=0,j=this.length;if(n.isFunction(a))return this.each(function(b){n(this).addClass(a.call(this,b,this.className))});if(h)for(b=(a||"").match(E)||[];j>i;i++)if(c=this[i],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(ac," "):" ")){f=0;while(e=b[f++])d.indexOf(" "+e+" ")<0&&(d+=e+" ");g=n.trim(d),c.className!==g&&(c.className=g)}return this},removeClass:function(a){var b,c,d,e,f,g,h=0===arguments.length||"string"==typeof a&&a,i=0,j=this.length;if(n.isFunction(a))return this.each(function(b){n(this).removeClass(a.call(this,b,this.className))});if(h)for(b=(a||"").match(E)||[];j>i;i++)if(c=this[i],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(ac," "):"")){f=0;while(e=b[f++])while(d.indexOf(" "+e+" ")>=0)d=d.replace(" "+e+" "," ");g=a?n.trim(d):"",c.className!==g&&(c.className=g)}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):this.each(n.isFunction(a)?function(c){n(this).toggleClass(a.call(this,c,this.className,b),b)}:function(){if("string"===c){var b,d=0,e=n(this),f=a.match(E)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else(c===U||"boolean"===c)&&(this.className&&L.set(this,"__className__",this.className),this.className=this.className||a===!1?"":L.get(this,"__className__")||"")})},hasClass:function(a){for(var b=" "+a+" ",c=0,d=this.length;d>c;c++)if(1===this[c].nodeType&&(" "+this[c].className+" ").replace(ac," ").indexOf(b)>=0)return!0;return!1}});var bc=/\r/g;n.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=n.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,n(this).val()):a,null==e?e="":"number"==typeof e?e+="":n.isArray(e)&&(e=n.map(e,function(a){return null==a?"":a+""})),b=n.valHooks[this.type]||n.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=n.valHooks[e.type]||n.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(bc,""):null==c?"":c)}}}),n.extend({valHooks:{option:{get:function(a){var b=n.find.attr(a,"value");return null!=b?b:n.trim(n.text(a))}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||0>e,g=f?null:[],h=f?e+1:d.length,i=0>e?h:f?e:0;h>i;i++)if(c=d[i],!(!c.selected&&i!==e||(k.optDisabled?c.disabled:null!==c.getAttribute("disabled"))||c.parentNode.disabled&&n.nodeName(c.parentNode,"optgroup"))){if(b=n(c).val(),f)return b;g.push(b)}return g},set:function(a,b){var c,d,e=a.options,f=n.makeArray(b),g=e.length;while(g--)d=e[g],(d.selected=n.inArray(d.value,f)>=0)&&(c=!0);return c||(a.selectedIndex=-1),f}}}}),n.each(["radio","checkbox"],function(){n.valHooks[this]={set:function(a,b){return n.isArray(b)?a.checked=n.inArray(n(a).val(),b)>=0:void 0}},k.checkOn||(n.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})}),n.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){n.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),n.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)},bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}});var cc=n.now(),dc=/\?/;n.parseJSON=function(a){return JSON.parse(a+"")},n.parseXML=function(a){var b,c;if(!a||"string"!=typeof a)return null;try{c=new DOMParser,b=c.parseFromString(a,"text/xml")}catch(d){b=void 0}return(!b||b.getElementsByTagName("parsererror").length)&&n.error("Invalid XML: "+a),b};var ec,fc,gc=/#.*$/,hc=/([?&])_=[^&]*/,ic=/^(.*?):[ \t]*([^\r\n]*)$/gm,jc=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,kc=/^(?:GET|HEAD)$/,lc=/^\/\//,mc=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,nc={},oc={},pc="*/".concat("*");try{fc=location.href}catch(qc){fc=l.createElement("a"),fc.href="",fc=fc.href}ec=mc.exec(fc.toLowerCase())||[];function rc(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(E)||[];if(n.isFunction(c))while(d=f[e++])"+"===d[0]?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function sc(a,b,c,d){var e={},f=a===oc;function g(h){var i;return e[h]=!0,n.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function tc(a,b){var c,d,e=n.ajaxSettings.flatOptions||{};for(c in b)void 0!==b[c]&&((e[c]?a:d||(d={}))[c]=b[c]);return d&&n.extend(!0,a,d),a}function uc(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===d&&(d=a.mimeType||b.getResponseHeader("Content-Type"));if(d)for(e in h)if(h[e]&&h[e].test(d)){i.unshift(e);break}if(i[0]in c)f=i[0];else{for(e in c){if(!i[0]||a.converters[e+" "+i[0]]){f=e;break}g||(g=e)}f=f||g}return f?(f!==i[0]&&i.unshift(f),c[f]):void 0}function vc(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}n.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:fc,type:"GET",isLocal:jc.test(ec[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":pc,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":n.parseJSON,"text xml":n.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?tc(tc(a,n.ajaxSettings),b):tc(n.ajaxSettings,a)},ajaxPrefilter:rc(nc),ajaxTransport:rc(oc),ajax:function(a,b){"object"==typeof a&&(b=a,a=void 0),b=b||{};var c,d,e,f,g,h,i,j,k=n.ajaxSetup({},b),l=k.context||k,m=k.context&&(l.nodeType||l.jquery)?n(l):n.event,o=n.Deferred(),p=n.Callbacks("once memory"),q=k.statusCode||{},r={},s={},t=0,u="canceled",v={readyState:0,getResponseHeader:function(a){var b;if(2===t){if(!f){f={};while(b=ic.exec(e))f[b[1].toLowerCase()]=b[2]}b=f[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return 2===t?e:null},setRequestHeader:function(a,b){var c=a.toLowerCase();return t||(a=s[c]=s[c]||a,r[a]=b),this},overrideMimeType:function(a){return t||(k.mimeType=a),this},statusCode:function(a){var b;if(a)if(2>t)for(b in a)q[b]=[q[b],a[b]];else v.always(a[v.status]);return this},abort:function(a){var b=a||u;return c&&c.abort(b),x(0,b),this}};if(o.promise(v).complete=p.add,v.success=v.done,v.error=v.fail,k.url=((a||k.url||fc)+"").replace(gc,"").replace(lc,ec[1]+"//"),k.type=b.method||b.type||k.method||k.type,k.dataTypes=n.trim(k.dataType||"*").toLowerCase().match(E)||[""],null==k.crossDomain&&(h=mc.exec(k.url.toLowerCase()),k.crossDomain=!(!h||h[1]===ec[1]&&h[2]===ec[2]&&(h[3]||("http:"===h[1]?"80":"443"))===(ec[3]||("http:"===ec[1]?"80":"443")))),k.data&&k.processData&&"string"!=typeof k.data&&(k.data=n.param(k.data,k.traditional)),sc(nc,k,b,v),2===t)return v;i=k.global,i&&0===n.active++&&n.event.trigger("ajaxStart"),k.type=k.type.toUpperCase(),k.hasContent=!kc.test(k.type),d=k.url,k.hasContent||(k.data&&(d=k.url+=(dc.test(d)?"&":"?")+k.data,delete k.data),k.cache===!1&&(k.url=hc.test(d)?d.replace(hc,"$1_="+cc++):d+(dc.test(d)?"&":"?")+"_="+cc++)),k.ifModified&&(n.lastModified[d]&&v.setRequestHeader("If-Modified-Since",n.lastModified[d]),n.etag[d]&&v.setRequestHeader("If-None-Match",n.etag[d])),(k.data&&k.hasContent&&k.contentType!==!1||b.contentType)&&v.setRequestHeader("Content-Type",k.contentType),v.setRequestHeader("Accept",k.dataTypes[0]&&k.accepts[k.dataTypes[0]]?k.accepts[k.dataTypes[0]]+("*"!==k.dataTypes[0]?", "+pc+"; q=0.01":""):k.accepts["*"]);for(j in k.headers)v.setRequestHeader(j,k.headers[j]);if(k.beforeSend&&(k.beforeSend.call(l,v,k)===!1||2===t))return v.abort();u="abort";for(j in{success:1,error:1,complete:1})v[j](k[j]);if(c=sc(oc,k,b,v)){v.readyState=1,i&&m.trigger("ajaxSend",[v,k]),k.async&&k.timeout>0&&(g=setTimeout(function(){v.abort("timeout")},k.timeout));try{t=1,c.send(r,x)}catch(w){if(!(2>t))throw w;x(-1,w)}}else x(-1,"No Transport");function x(a,b,f,h){var j,r,s,u,w,x=b;2!==t&&(t=2,g&&clearTimeout(g),c=void 0,e=h||"",v.readyState=a>0?4:0,j=a>=200&&300>a||304===a,f&&(u=uc(k,v,f)),u=vc(k,u,v,j),j?(k.ifModified&&(w=v.getResponseHeader("Last-Modified"),w&&(n.lastModified[d]=w),w=v.getResponseHeader("etag"),w&&(n.etag[d]=w)),204===a||"HEAD"===k.type?x="nocontent":304===a?x="notmodified":(x=u.state,r=u.data,s=u.error,j=!s)):(s=x,(a||!x)&&(x="error",0>a&&(a=0))),v.status=a,v.statusText=(b||x)+"",j?o.resolveWith(l,[r,x,v]):o.rejectWith(l,[v,x,s]),v.statusCode(q),q=void 0,i&&m.trigger(j?"ajaxSuccess":"ajaxError",[v,k,j?r:s]),p.fireWith(l,[v,x]),i&&(m.trigger("ajaxComplete",[v,k]),--n.active||n.event.trigger("ajaxStop")))}return v},getJSON:function(a,b,c){return n.get(a,b,c,"json")},getScript:function(a,b){return n.get(a,void 0,b,"script")}}),n.each(["get","post"],function(a,b){n[b]=function(a,c,d,e){return n.isFunction(c)&&(e=e||d,d=c,c=void 0),n.ajax({url:a,type:b,dataType:e,data:c,success:d})}}),n.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){n.fn[b]=function(a){return this.on(b,a)}}),n._evalUrl=function(a){return n.ajax({url:a,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},n.fn.extend({wrapAll:function(a){var b;return n.isFunction(a)?this.each(function(b){n(this).wrapAll(a.call(this,b))}):(this[0]&&(b=n(a,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstElementChild)a=a.firstElementChild;return a}).append(this)),this)},wrapInner:function(a){return this.each(n.isFunction(a)?function(b){n(this).wrapInner(a.call(this,b))}:function(){var b=n(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=n.isFunction(a);return this.each(function(c){n(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){n.nodeName(this,"body")||n(this).replaceWith(this.childNodes)}).end()}}),n.expr.filters.hidden=function(a){return a.offsetWidth<=0&&a.offsetHeight<=0},n.expr.filters.visible=function(a){return!n.expr.filters.hidden(a)};var wc=/%20/g,xc=/\[\]$/,yc=/\r?\n/g,zc=/^(?:submit|button|image|reset|file)$/i,Ac=/^(?:input|select|textarea|keygen)/i;function Bc(a,b,c,d){var e;if(n.isArray(b))n.each(b,function(b,e){c||xc.test(a)?d(a,e):Bc(a+"["+("object"==typeof e?b:"")+"]",e,c,d)});else if(c||"object"!==n.type(b))d(a,b);else for(e in b)Bc(a+"["+e+"]",b[e],c,d)}n.param=function(a,b){var c,d=[],e=function(a,b){b=n.isFunction(b)?b():null==b?"":b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(void 0===b&&(b=n.ajaxSettings&&n.ajaxSettings.traditional),n.isArray(a)||a.jquery&&!n.isPlainObject(a))n.each(a,function(){e(this.name,this.value)});else for(c in a)Bc(c,a[c],b,e);return d.join("&").replace(wc,"+")},n.fn.extend({serialize:function(){return n.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=n.prop(this,"elements");return a?n.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!n(this).is(":disabled")&&Ac.test(this.nodeName)&&!zc.test(a)&&(this.checked||!T.test(a))}).map(function(a,b){var c=n(this).val();return null==c?null:n.isArray(c)?n.map(c,function(a){return{name:b.name,value:a.replace(yc,"\r\n")}}):{name:b.name,value:c.replace(yc,"\r\n")}}).get()}}),n.ajaxSettings.xhr=function(){try{return new XMLHttpRequest}catch(a){}};var Cc=0,Dc={},Ec={0:200,1223:204},Fc=n.ajaxSettings.xhr();a.ActiveXObject&&n(a).on("unload",function(){for(var a in Dc)Dc[a]()}),k.cors=!!Fc&&"withCredentials"in Fc,k.ajax=Fc=!!Fc,n.ajaxTransport(function(a){var b;return k.cors||Fc&&!a.crossDomain?{send:function(c,d){var e,f=a.xhr(),g=++Cc;if(f.open(a.type,a.url,a.async,a.username,a.password),a.xhrFields)for(e in a.xhrFields)f[e]=a.xhrFields[e];a.mimeType&&f.overrideMimeType&&f.overrideMimeType(a.mimeType),a.crossDomain||c["X-Requested-With"]||(c["X-Requested-With"]="XMLHttpRequest");for(e in c)f.setRequestHeader(e,c[e]);b=function(a){return function(){b&&(delete Dc[g],b=f.onload=f.onerror=null,"abort"===a?f.abort():"error"===a?d(f.status,f.statusText):d(Ec[f.status]||f.status,f.statusText,"string"==typeof f.responseText?{text:f.responseText}:void 0,f.getAllResponseHeaders()))}},f.onload=b(),f.onerror=b("error"),b=Dc[g]=b("abort");try{f.send(a.hasContent&&a.data||null)}catch(h){if(b)throw h}},abort:function(){b&&b()}}:void 0}),n.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(a){return n.globalEval(a),a}}}),n.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET")}),n.ajaxTransport("script",function(a){if(a.crossDomain){var b,c;return{send:function(d,e){b=n("<script>").prop({async:!0,charset:a.scriptCharset,src:a.url}).on("load error",c=function(a){b.remove(),c=null,a&&e("error"===a.type?404:200,a.type)}),l.head.appendChild(b[0])},abort:function(){c&&c()}}}});var Gc=[],Hc=/(=)\?(?=&|$)|\?\?/;n.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=Gc.pop()||n.expando+"_"+cc++;return this[a]=!0,a}}),n.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(Hc.test(b.url)?"url":"string"==typeof b.data&&!(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&Hc.test(b.data)&&"data");return h||"jsonp"===b.dataTypes[0]?(e=b.jsonpCallback=n.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(Hc,"$1"+e):b.jsonp!==!1&&(b.url+=(dc.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||n.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,Gc.push(e)),g&&n.isFunction(f)&&f(g[0]),g=f=void 0}),"script"):void 0}),n.parseHTML=function(a,b,c){if(!a||"string"!=typeof a)return null;"boolean"==typeof b&&(c=b,b=!1),b=b||l;var d=v.exec(a),e=!c&&[];return d?[b.createElement(d[1])]:(d=n.buildFragment([a],b,e),e&&e.length&&n(e).remove(),n.merge([],d.childNodes))};var Ic=n.fn.load;n.fn.load=function(a,b,c){if("string"!=typeof a&&Ic)return Ic.apply(this,arguments);var d,e,f,g=this,h=a.indexOf(" ");return h>=0&&(d=n.trim(a.slice(h)),a=a.slice(0,h)),n.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(e="POST"),g.length>0&&n.ajax({url:a,type:e,dataType:"html",data:b}).done(function(a){f=arguments,g.html(d?n("<div>").append(n.parseHTML(a)).find(d):a)}).complete(c&&function(a,b){g.each(c,f||[a.responseText,b,a])}),this},n.expr.filters.animated=function(a){return n.grep(n.timers,function(b){return a===b.elem}).length};var Jc=a.document.documentElement;function Kc(a){return n.isWindow(a)?a:9===a.nodeType&&a.defaultView}n.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=n.css(a,"position"),l=n(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=n.css(a,"top"),i=n.css(a,"left"),j=("absolute"===k||"fixed"===k)&&(f+i).indexOf("auto")>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),n.isFunction(b)&&(b=b.call(a,c,h)),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},n.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){n.offset.setOffset(this,a,b)});var b,c,d=this[0],e={top:0,left:0},f=d&&d.ownerDocument;if(f)return b=f.documentElement,n.contains(b,d)?(typeof d.getBoundingClientRect!==U&&(e=d.getBoundingClientRect()),c=Kc(f),{top:e.top+c.pageYOffset-b.clientTop,left:e.left+c.pageXOffset-b.clientLeft}):e},position:function(){if(this[0]){var a,b,c=this[0],d={top:0,left:0};return"fixed"===n.css(c,"position")?b=c.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),n.nodeName(a[0],"html")||(d=a.offset()),d.top+=n.css(a[0],"borderTopWidth",!0),d.left+=n.css(a[0],"borderLeftWidth",!0)),{top:b.top-d.top-n.css(c,"marginTop",!0),left:b.left-d.left-n.css(c,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||Jc;while(a&&!n.nodeName(a,"html")&&"static"===n.css(a,"position"))a=a.offsetParent;return a||Jc})}}),n.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(b,c){var d="pageYOffset"===c;n.fn[b]=function(e){return J(this,function(b,e,f){var g=Kc(b);return void 0===f?g?g[c]:b[e]:void(g?g.scrollTo(d?a.pageXOffset:f,d?f:a.pageYOffset):b[e]=f)},b,e,arguments.length,null)}}),n.each(["top","left"],function(a,b){n.cssHooks[b]=yb(k.pixelPosition,function(a,c){return c?(c=xb(a,b),vb.test(c)?n(a).position()[b]+"px":c):void 0})}),n.each({Height:"height",Width:"width"},function(a,b){n.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){n.fn[d]=function(d,e){var f=arguments.length&&(c||"boolean"!=typeof d),g=c||(d===!0||e===!0?"margin":"border");return J(this,function(b,c,d){var e;return n.isWindow(b)?b.document.documentElement["client"+a]:9===b.nodeType?(e=b.documentElement,Math.max(b.body["scroll"+a],e["scroll"+a],b.body["offset"+a],e["offset"+a],e["client"+a])):void 0===d?n.css(b,c,g):n.style(b,c,d,g)},b,f?d:void 0,f,null)}})}),n.fn.size=function(){return this.length},n.fn.andSelf=n.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return n});var Lc=a.jQuery,Mc=a.$;return n.noConflict=function(b){return a.$===n&&(a.$=Mc),b&&a.jQuery===n&&(a.jQuery=Lc),n},typeof b===U&&(a.jQuery=a.$=n),n});
templates/js/jquery.criterion.js view
@@ -19,7 +19,7 @@ }; $.timeUnits = function(secs) {- if (secs < 0) return timeUnits(-secs);+ if (secs < 0) return $.timeUnits(-secs); else if (secs >= 1e9) return [1e-9, "Gs"]; else if (secs >= 1e6) return [1e-6, "Ms"]; else if (secs >= 1) return [1, "s"];@@ -27,13 +27,22 @@ else if (secs >= 1e-6) return [1e6, "\u03bcs"]; else if (secs >= 1e-9) return [1e9, "ns"]; else if (secs >= 1e-12) return [1e12, "ps"];+ return [1, "s"]; }; $.scaleTimes = function(ary) { var s = $.timeUnits($.mean(ary));- return [$.scaleBy(s[0], ary), s[1]];+ return [$.scaleBy(s[0], ary), s[0]]; }; + $.prepareTime = function(secs) {+ var units = $.timeUnits(secs);+ var scaled = secs * units[0];+ var s = scaled.toPrecision(3);+ var t = scaled.toString();+ return [t.length < s.length ? t : s, units[1]];+ };+ $.scaleBy = function(x, ary) { var nary = new Array(ary.length); for (var i = 0; i < ary.length; i++)@@ -41,27 +50,21 @@ return nary; }; - $.renderTime = function(text) {- var x = parseFloat(text);- var t = $.timeUnits(x);- x *= t[0];- if (x >= 1000 || x <= -1000) return x.toFixed() + " " + t[1];- var prec = 5;- if (x < 0) prec++;-- return x.toString().substring(0,prec) + " " + t[1];+ $.renderTime = function(secs) {+ var x = $.prepareTime(secs);+ return x[0] + ' ' + x[1]; }; - $.unitFormatter = function(units) {- var ticked = 0;- return function(val,axis) {- var s = val.toFixed(axis.tickDecimals);- if (ticked > 1)- return s;+ $.unitFormatter = function(scale) {+ var labelname;+ return function(secs,axis) {+ var x = $.prepareTime(secs / scale);+ if (labelname === x[1])+ return x[0]; else {- ticked++;- return s + ' ' + units;- }+ labelname = x[1];+ return x[0] + ' ' + x[1];+ } }; }; @@ -88,15 +91,15 @@ pp = item.dataIndex; $("#tooltip").remove();- var x = item.datapoint[0].toFixed(2),- y = item.datapoint[1].toFixed(2);+ var x = item.datapoint[0],+ y = item.datapoint[1]; showTooltip(item.pageX, item.pageY, renderText(x,y)); } } else { $("#tooltip").remove();- pp = null; + pp = null; } }); };
− templates/js/jquery.flot-0.7.min.js
@@ -1,6 +0,0 @@-/* Javascript plotting library for jQuery, v. 0.7.- *- * Released under the MIT license by IOLA, December 2007.- *- */-(function(b){b.color={};b.color.make=function(d,e,g,f){var c={};c.r=d||0;c.g=e||0;c.b=g||0;c.a=f!=null?f:1;c.add=function(h,j){for(var k=0;k<h.length;++k){c[h.charAt(k)]+=j}return c.normalize()};c.scale=function(h,j){for(var k=0;k<h.length;++k){c[h.charAt(k)]*=j}return c.normalize()};c.toString=function(){if(c.a>=1){return"rgb("+[c.r,c.g,c.b].join(",")+")"}else{return"rgba("+[c.r,c.g,c.b,c.a].join(",")+")"}};c.normalize=function(){function h(k,j,l){return j<k?k:(j>l?l:j)}c.r=h(0,parseInt(c.r),255);c.g=h(0,parseInt(c.g),255);c.b=h(0,parseInt(c.b),255);c.a=h(0,c.a,1);return c};c.clone=function(){return b.color.make(c.r,c.b,c.g,c.a)};return c.normalize()};b.color.extract=function(d,e){var c;do{c=d.css(e).toLowerCase();if(c!=""&&c!="transparent"){break}d=d.parent()}while(!b.nodeName(d.get(0),"body"));if(c=="rgba(0, 0, 0, 0)"){c="transparent"}return b.color.parse(c)};b.color.parse=function(c){var d,f=b.color.make;if(d=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(c)){return f(parseInt(d[1],10),parseInt(d[2],10),parseInt(d[3],10))}if(d=/rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]+(?:\.[0-9]+)?)\s*\)/.exec(c)){return f(parseInt(d[1],10),parseInt(d[2],10),parseInt(d[3],10),parseFloat(d[4]))}if(d=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(c)){return f(parseFloat(d[1])*2.55,parseFloat(d[2])*2.55,parseFloat(d[3])*2.55)}if(d=/rgba\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\s*\)/.exec(c)){return f(parseFloat(d[1])*2.55,parseFloat(d[2])*2.55,parseFloat(d[3])*2.55,parseFloat(d[4]))}if(d=/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(c)){return f(parseInt(d[1],16),parseInt(d[2],16),parseInt(d[3],16))}if(d=/#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(c)){return f(parseInt(d[1]+d[1],16),parseInt(d[2]+d[2],16),parseInt(d[3]+d[3],16))}var e=b.trim(c).toLowerCase();if(e=="transparent"){return f(255,255,255,0)}else{d=a[e]||[0,0,0];return f(d[0],d[1],d[2])}};var a={aqua:[0,255,255],azure:[240,255,255],beige:[245,245,220],black:[0,0,0],blue:[0,0,255],brown:[165,42,42],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgrey:[169,169,169],darkgreen:[0,100,0],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkviolet:[148,0,211],fuchsia:[255,0,255],gold:[255,215,0],green:[0,128,0],indigo:[75,0,130],khaki:[240,230,140],lightblue:[173,216,230],lightcyan:[224,255,255],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightyellow:[255,255,224],lime:[0,255,0],magenta:[255,0,255],maroon:[128,0,0],navy:[0,0,128],olive:[128,128,0],orange:[255,165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0]}})(jQuery);(function(c){function b(av,ai,J,af){var Q=[],O={colors:["#edc240","#afd8f8","#cb4b4b","#4da74d","#9440ed"],legend:{show:true,noColumns:1,labelFormatter:null,labelBoxBorderColor:"#ccc",container:null,position:"ne",margin:5,backgroundColor:null,backgroundOpacity:0.85},xaxis:{show:null,position:"bottom",mode:null,color:null,tickColor:null,transform:null,inverseTransform:null,min:null,max:null,autoscaleMargin:null,ticks:null,tickFormatter:null,labelWidth:null,labelHeight:null,reserveSpace:null,tickLength:null,alignTicksWithAxis:null,tickDecimals:null,tickSize:null,minTickSize:null,monthNames:null,timeformat:null,twelveHourClock:false},yaxis:{autoscaleMargin:0.02,position:"left"},xaxes:[],yaxes:[],series:{points:{show:false,radius:3,lineWidth:2,fill:true,fillColor:"#ffffff",symbol:"circle"},lines:{lineWidth:2,fill:false,fillColor:null,steps:false},bars:{show:false,lineWidth:2,barWidth:1,fill:true,fillColor:null,align:"left",horizontal:false},shadowSize:3},grid:{show:true,aboveData:false,color:"#545454",backgroundColor:null,borderColor:null,tickColor:null,labelMargin:5,axisMargin:8,borderWidth:2,minBorderMargin:null,markings:null,markingsColor:"#f4f4f4",markingsLineWidth:2,clickable:false,hoverable:false,autoHighlight:true,mouseActiveRadius:10},hooks:{}},az=null,ad=null,y=null,H=null,A=null,p=[],aw=[],q={left:0,right:0,top:0,bottom:0},G=0,I=0,h=0,w=0,ak={processOptions:[],processRawData:[],processDatapoints:[],drawSeries:[],draw:[],bindEvents:[],drawOverlay:[],shutdown:[]},aq=this;aq.setData=aj;aq.setupGrid=t;aq.draw=W;aq.getPlaceholder=function(){return av};aq.getCanvas=function(){return az};aq.getPlotOffset=function(){return q};aq.width=function(){return h};aq.height=function(){return w};aq.offset=function(){var aB=y.offset();aB.left+=q.left;aB.top+=q.top;return aB};aq.getData=function(){return Q};aq.getAxes=function(){var aC={},aB;c.each(p.concat(aw),function(aD,aE){if(aE){aC[aE.direction+(aE.n!=1?aE.n:"")+"axis"]=aE}});return aC};aq.getXAxes=function(){return p};aq.getYAxes=function(){return aw};aq.c2p=C;aq.p2c=ar;aq.getOptions=function(){return O};aq.highlight=x;aq.unhighlight=T;aq.triggerRedrawOverlay=f;aq.pointOffset=function(aB){return{left:parseInt(p[aA(aB,"x")-1].p2c(+aB.x)+q.left),top:parseInt(aw[aA(aB,"y")-1].p2c(+aB.y)+q.top)}};aq.shutdown=ag;aq.resize=function(){B();g(az);g(ad)};aq.hooks=ak;F(aq);Z(J);X();aj(ai);t();W();ah();function an(aD,aB){aB=[aq].concat(aB);for(var aC=0;aC<aD.length;++aC){aD[aC].apply(this,aB)}}function F(){for(var aB=0;aB<af.length;++aB){var aC=af[aB];aC.init(aq);if(aC.options){c.extend(true,O,aC.options)}}}function Z(aC){var aB;c.extend(true,O,aC);if(O.xaxis.color==null){O.xaxis.color=O.grid.color}if(O.yaxis.color==null){O.yaxis.color=O.grid.color}if(O.xaxis.tickColor==null){O.xaxis.tickColor=O.grid.tickColor}if(O.yaxis.tickColor==null){O.yaxis.tickColor=O.grid.tickColor}if(O.grid.borderColor==null){O.grid.borderColor=O.grid.color}if(O.grid.tickColor==null){O.grid.tickColor=c.color.parse(O.grid.color).scale("a",0.22).toString()}for(aB=0;aB<Math.max(1,O.xaxes.length);++aB){O.xaxes[aB]=c.extend(true,{},O.xaxis,O.xaxes[aB])}for(aB=0;aB<Math.max(1,O.yaxes.length);++aB){O.yaxes[aB]=c.extend(true,{},O.yaxis,O.yaxes[aB])}if(O.xaxis.noTicks&&O.xaxis.ticks==null){O.xaxis.ticks=O.xaxis.noTicks}if(O.yaxis.noTicks&&O.yaxis.ticks==null){O.yaxis.ticks=O.yaxis.noTicks}if(O.x2axis){O.xaxes[1]=c.extend(true,{},O.xaxis,O.x2axis);O.xaxes[1].position="top"}if(O.y2axis){O.yaxes[1]=c.extend(true,{},O.yaxis,O.y2axis);O.yaxes[1].position="right"}if(O.grid.coloredAreas){O.grid.markings=O.grid.coloredAreas}if(O.grid.coloredAreasColor){O.grid.markingsColor=O.grid.coloredAreasColor}if(O.lines){c.extend(true,O.series.lines,O.lines)}if(O.points){c.extend(true,O.series.points,O.points)}if(O.bars){c.extend(true,O.series.bars,O.bars)}if(O.shadowSize!=null){O.series.shadowSize=O.shadowSize}for(aB=0;aB<O.xaxes.length;++aB){V(p,aB+1).options=O.xaxes[aB]}for(aB=0;aB<O.yaxes.length;++aB){V(aw,aB+1).options=O.yaxes[aB]}for(var aD in ak){if(O.hooks[aD]&&O.hooks[aD].length){ak[aD]=ak[aD].concat(O.hooks[aD])}}an(ak.processOptions,[O])}function aj(aB){Q=Y(aB);ax();z()}function Y(aE){var aC=[];for(var aB=0;aB<aE.length;++aB){var aD=c.extend(true,{},O.series);if(aE[aB].data!=null){aD.data=aE[aB].data;delete aE[aB].data;c.extend(true,aD,aE[aB]);aE[aB].data=aD.data}else{aD.data=aE[aB]}aC.push(aD)}return aC}function aA(aC,aD){var aB=aC[aD+"axis"];if(typeof aB=="object"){aB=aB.n}if(typeof aB!="number"){aB=1}return aB}function m(){return c.grep(p.concat(aw),function(aB){return aB})}function C(aE){var aC={},aB,aD;for(aB=0;aB<p.length;++aB){aD=p[aB];if(aD&&aD.used){aC["x"+aD.n]=aD.c2p(aE.left)}}for(aB=0;aB<aw.length;++aB){aD=aw[aB];if(aD&&aD.used){aC["y"+aD.n]=aD.c2p(aE.top)}}if(aC.x1!==undefined){aC.x=aC.x1}if(aC.y1!==undefined){aC.y=aC.y1}return aC}function ar(aF){var aD={},aC,aE,aB;for(aC=0;aC<p.length;++aC){aE=p[aC];if(aE&&aE.used){aB="x"+aE.n;if(aF[aB]==null&&aE.n==1){aB="x"}if(aF[aB]!=null){aD.left=aE.p2c(aF[aB]);break}}}for(aC=0;aC<aw.length;++aC){aE=aw[aC];if(aE&&aE.used){aB="y"+aE.n;if(aF[aB]==null&&aE.n==1){aB="y"}if(aF[aB]!=null){aD.top=aE.p2c(aF[aB]);break}}}return aD}function V(aC,aB){if(!aC[aB-1]){aC[aB-1]={n:aB,direction:aC==p?"x":"y",options:c.extend(true,{},aC==p?O.xaxis:O.yaxis)}}return aC[aB-1]}function ax(){var aG;var aM=Q.length,aB=[],aE=[];for(aG=0;aG<Q.length;++aG){var aJ=Q[aG].color;if(aJ!=null){--aM;if(typeof aJ=="number"){aE.push(aJ)}else{aB.push(c.color.parse(Q[aG].color))}}}for(aG=0;aG<aE.length;++aG){aM=Math.max(aM,aE[aG]+1)}var aC=[],aF=0;aG=0;while(aC.length<aM){var aI;if(O.colors.length==aG){aI=c.color.make(100,100,100)}else{aI=c.color.parse(O.colors[aG])}var aD=aF%2==1?-1:1;aI.scale("rgb",1+aD*Math.ceil(aF/2)*0.2);aC.push(aI);++aG;if(aG>=O.colors.length){aG=0;++aF}}var aH=0,aN;for(aG=0;aG<Q.length;++aG){aN=Q[aG];if(aN.color==null){aN.color=aC[aH].toString();++aH}else{if(typeof aN.color=="number"){aN.color=aC[aN.color].toString()}}if(aN.lines.show==null){var aL,aK=true;for(aL in aN){if(aN[aL]&&aN[aL].show){aK=false;break}}if(aK){aN.lines.show=true}}aN.xaxis=V(p,aA(aN,"x"));aN.yaxis=V(aw,aA(aN,"y"))}}function z(){var aO=Number.POSITIVE_INFINITY,aI=Number.NEGATIVE_INFINITY,aB=Number.MAX_VALUE,aU,aS,aR,aN,aD,aJ,aT,aP,aH,aG,aC,a0,aX,aL;function aF(a3,a2,a1){if(a2<a3.datamin&&a2!=-aB){a3.datamin=a2}if(a1>a3.datamax&&a1!=aB){a3.datamax=a1}}c.each(m(),function(a1,a2){a2.datamin=aO;a2.datamax=aI;a2.used=false});for(aU=0;aU<Q.length;++aU){aJ=Q[aU];aJ.datapoints={points:[]};an(ak.processRawData,[aJ,aJ.data,aJ.datapoints])}for(aU=0;aU<Q.length;++aU){aJ=Q[aU];var aZ=aJ.data,aW=aJ.datapoints.format;if(!aW){aW=[];aW.push({x:true,number:true,required:true});aW.push({y:true,number:true,required:true});if(aJ.bars.show||(aJ.lines.show&&aJ.lines.fill)){aW.push({y:true,number:true,required:false,defaultValue:0});if(aJ.bars.horizontal){delete aW[aW.length-1].y;aW[aW.length-1].x=true}}aJ.datapoints.format=aW}if(aJ.datapoints.pointsize!=null){continue}aJ.datapoints.pointsize=aW.length;aP=aJ.datapoints.pointsize;aT=aJ.datapoints.points;insertSteps=aJ.lines.show&&aJ.lines.steps;aJ.xaxis.used=aJ.yaxis.used=true;for(aS=aR=0;aS<aZ.length;++aS,aR+=aP){aL=aZ[aS];var aE=aL==null;if(!aE){for(aN=0;aN<aP;++aN){a0=aL[aN];aX=aW[aN];if(aX){if(aX.number&&a0!=null){a0=+a0;if(isNaN(a0)){a0=null}else{if(a0==Infinity){a0=aB}else{if(a0==-Infinity){a0=-aB}}}}if(a0==null){if(aX.required){aE=true}if(aX.defaultValue!=null){a0=aX.defaultValue}}}aT[aR+aN]=a0}}if(aE){for(aN=0;aN<aP;++aN){a0=aT[aR+aN];if(a0!=null){aX=aW[aN];if(aX.x){aF(aJ.xaxis,a0,a0)}if(aX.y){aF(aJ.yaxis,a0,a0)}}aT[aR+aN]=null}}else{if(insertSteps&&aR>0&&aT[aR-aP]!=null&&aT[aR-aP]!=aT[aR]&&aT[aR-aP+1]!=aT[aR+1]){for(aN=0;aN<aP;++aN){aT[aR+aP+aN]=aT[aR+aN]}aT[aR+1]=aT[aR-aP+1];aR+=aP}}}}for(aU=0;aU<Q.length;++aU){aJ=Q[aU];an(ak.processDatapoints,[aJ,aJ.datapoints])}for(aU=0;aU<Q.length;++aU){aJ=Q[aU];aT=aJ.datapoints.points,aP=aJ.datapoints.pointsize;var aK=aO,aQ=aO,aM=aI,aV=aI;for(aS=0;aS<aT.length;aS+=aP){if(aT[aS]==null){continue}for(aN=0;aN<aP;++aN){a0=aT[aS+aN];aX=aW[aN];if(!aX||a0==aB||a0==-aB){continue}if(aX.x){if(a0<aK){aK=a0}if(a0>aM){aM=a0}}if(aX.y){if(a0<aQ){aQ=a0}if(a0>aV){aV=a0}}}}if(aJ.bars.show){var aY=aJ.bars.align=="left"?0:-aJ.bars.barWidth/2;if(aJ.bars.horizontal){aQ+=aY;aV+=aY+aJ.bars.barWidth}else{aK+=aY;aM+=aY+aJ.bars.barWidth}}aF(aJ.xaxis,aK,aM);aF(aJ.yaxis,aQ,aV)}c.each(m(),function(a1,a2){if(a2.datamin==aO){a2.datamin=null}if(a2.datamax==aI){a2.datamax=null}})}function j(aB,aC){var aD=document.createElement("canvas");aD.className=aC;aD.width=G;aD.height=I;if(!aB){c(aD).css({position:"absolute",left:0,top:0})}c(aD).appendTo(av);if(!aD.getContext){aD=window.G_vmlCanvasManager.initElement(aD)}aD.getContext("2d").save();return aD}function B(){G=av.width();I=av.height();if(G<=0||I<=0){throw"Invalid dimensions for plot, width = "+G+", height = "+I}}function g(aC){if(aC.width!=G){aC.width=G}if(aC.height!=I){aC.height=I}var aB=aC.getContext("2d");aB.restore();aB.save()}function X(){var aC,aB=av.children("canvas.base"),aD=av.children("canvas.overlay");if(aB.length==0||aD==0){av.html("");av.css({padding:0});if(av.css("position")=="static"){av.css("position","relative")}B();az=j(true,"base");ad=j(false,"overlay");aC=false}else{az=aB.get(0);ad=aD.get(0);aC=true}H=az.getContext("2d");A=ad.getContext("2d");y=c([ad,az]);if(aC){av.data("plot").shutdown();aq.resize();A.clearRect(0,0,G,I);y.unbind();av.children().not([az,ad]).remove()}av.data("plot",aq)}function ah(){if(O.grid.hoverable){y.mousemove(aa);y.mouseleave(l)}if(O.grid.clickable){y.click(R)}an(ak.bindEvents,[y])}function ag(){if(M){clearTimeout(M)}y.unbind("mousemove",aa);y.unbind("mouseleave",l);y.unbind("click",R);an(ak.shutdown,[y])}function r(aG){function aC(aH){return aH}var aF,aB,aD=aG.options.transform||aC,aE=aG.options.inverseTransform;if(aG.direction=="x"){aF=aG.scale=h/Math.abs(aD(aG.max)-aD(aG.min));aB=Math.min(aD(aG.max),aD(aG.min))}else{aF=aG.scale=w/Math.abs(aD(aG.max)-aD(aG.min));aF=-aF;aB=Math.max(aD(aG.max),aD(aG.min))}if(aD==aC){aG.p2c=function(aH){return(aH-aB)*aF}}else{aG.p2c=function(aH){return(aD(aH)-aB)*aF}}if(!aE){aG.c2p=function(aH){return aB+aH/aF}}else{aG.c2p=function(aH){return aE(aB+aH/aF)}}}function L(aD){var aB=aD.options,aF,aJ=aD.ticks||[],aI=[],aE,aK=aB.labelWidth,aG=aB.labelHeight,aC;function aH(aM,aL){return c('<div style="position:absolute;top:-10000px;'+aL+'font-size:smaller"><div class="'+aD.direction+"Axis "+aD.direction+aD.n+'Axis">'+aM.join("")+"</div></div>").appendTo(av)}if(aD.direction=="x"){if(aK==null){aK=Math.floor(G/(aJ.length>0?aJ.length:1))}if(aG==null){aI=[];for(aF=0;aF<aJ.length;++aF){aE=aJ[aF].label;if(aE){aI.push('<div class="tickLabel" style="float:left;width:'+aK+'px">'+aE+"</div>")}}if(aI.length>0){aI.push('<div style="clear:left"></div>');aC=aH(aI,"width:10000px;");aG=aC.height();aC.remove()}}}else{if(aK==null||aG==null){for(aF=0;aF<aJ.length;++aF){aE=aJ[aF].label;if(aE){aI.push('<div class="tickLabel">'+aE+"</div>")}}if(aI.length>0){aC=aH(aI,"");if(aK==null){aK=aC.children().width()}if(aG==null){aG=aC.find("div.tickLabel").height()}aC.remove()}}}if(aK==null){aK=0}if(aG==null){aG=0}aD.labelWidth=aK;aD.labelHeight=aG}function au(aD){var aC=aD.labelWidth,aL=aD.labelHeight,aH=aD.options.position,aF=aD.options.tickLength,aG=O.grid.axisMargin,aJ=O.grid.labelMargin,aK=aD.direction=="x"?p:aw,aE;var aB=c.grep(aK,function(aN){return aN&&aN.options.position==aH&&aN.reserveSpace});if(c.inArray(aD,aB)==aB.length-1){aG=0}if(aF==null){aF="full"}var aI=c.grep(aK,function(aN){return aN&&aN.reserveSpace});var aM=c.inArray(aD,aI)==0;if(!aM&&aF=="full"){aF=5}if(!isNaN(+aF)){aJ+=+aF}if(aD.direction=="x"){aL+=aJ;if(aH=="bottom"){q.bottom+=aL+aG;aD.box={top:I-q.bottom,height:aL}}else{aD.box={top:q.top+aG,height:aL};q.top+=aL+aG}}else{aC+=aJ;if(aH=="left"){aD.box={left:q.left+aG,width:aC};q.left+=aC+aG}else{q.right+=aC+aG;aD.box={left:G-q.right,width:aC}}}aD.position=aH;aD.tickLength=aF;aD.box.padding=aJ;aD.innermost=aM}function U(aB){if(aB.direction=="x"){aB.box.left=q.left;aB.box.width=h}else{aB.box.top=q.top;aB.box.height=w}}function t(){var aC,aE=m();c.each(aE,function(aF,aG){aG.show=aG.options.show;if(aG.show==null){aG.show=aG.used}aG.reserveSpace=aG.show||aG.options.reserveSpace;n(aG)});allocatedAxes=c.grep(aE,function(aF){return aF.reserveSpace});q.left=q.right=q.top=q.bottom=0;if(O.grid.show){c.each(allocatedAxes,function(aF,aG){S(aG);P(aG);ap(aG,aG.ticks);L(aG)});for(aC=allocatedAxes.length-1;aC>=0;--aC){au(allocatedAxes[aC])}var aD=O.grid.minBorderMargin;if(aD==null){aD=0;for(aC=0;aC<Q.length;++aC){aD=Math.max(aD,Q[aC].points.radius+Q[aC].points.lineWidth/2)}}for(var aB in q){q[aB]+=O.grid.borderWidth;q[aB]=Math.max(aD,q[aB])}}h=G-q.left-q.right;w=I-q.bottom-q.top;c.each(aE,function(aF,aG){r(aG)});if(O.grid.show){c.each(allocatedAxes,function(aF,aG){U(aG)});k()}o()}function n(aE){var aF=aE.options,aD=+(aF.min!=null?aF.min:aE.datamin),aB=+(aF.max!=null?aF.max:aE.datamax),aH=aB-aD;if(aH==0){var aC=aB==0?1:0.01;if(aF.min==null){aD-=aC}if(aF.max==null||aF.min!=null){aB+=aC}}else{var aG=aF.autoscaleMargin;if(aG!=null){if(aF.min==null){aD-=aH*aG;if(aD<0&&aE.datamin!=null&&aE.datamin>=0){aD=0}}if(aF.max==null){aB+=aH*aG;if(aB>0&&aE.datamax!=null&&aE.datamax<=0){aB=0}}}}aE.min=aD;aE.max=aB}function S(aG){var aM=aG.options;var aH;if(typeof aM.ticks=="number"&&aM.ticks>0){aH=aM.ticks}else{aH=0.3*Math.sqrt(aG.direction=="x"?G:I)}var aT=(aG.max-aG.min)/aH,aO,aB,aN,aR,aS,aQ,aI;if(aM.mode=="time"){var aJ={second:1000,minute:60*1000,hour:60*60*1000,day:24*60*60*1000,month:30*24*60*60*1000,year:365.2425*24*60*60*1000};var aK=[[1,"second"],[2,"second"],[5,"second"],[10,"second"],[30,"second"],[1,"minute"],[2,"minute"],[5,"minute"],[10,"minute"],[30,"minute"],[1,"hour"],[2,"hour"],[4,"hour"],[8,"hour"],[12,"hour"],[1,"day"],[2,"day"],[3,"day"],[0.25,"month"],[0.5,"month"],[1,"month"],[2,"month"],[3,"month"],[6,"month"],[1,"year"]];var aC=0;if(aM.minTickSize!=null){if(typeof aM.tickSize=="number"){aC=aM.tickSize}else{aC=aM.minTickSize[0]*aJ[aM.minTickSize[1]]}}for(var aS=0;aS<aK.length-1;++aS){if(aT<(aK[aS][0]*aJ[aK[aS][1]]+aK[aS+1][0]*aJ[aK[aS+1][1]])/2&&aK[aS][0]*aJ[aK[aS][1]]>=aC){break}}aO=aK[aS][0];aN=aK[aS][1];if(aN=="year"){aQ=Math.pow(10,Math.floor(Math.log(aT/aJ.year)/Math.LN10));aI=(aT/aJ.year)/aQ;if(aI<1.5){aO=1}else{if(aI<3){aO=2}else{if(aI<7.5){aO=5}else{aO=10}}}aO*=aQ}aG.tickSize=aM.tickSize||[aO,aN];aB=function(aX){var a2=[],a0=aX.tickSize[0],a3=aX.tickSize[1],a1=new Date(aX.min);var aW=a0*aJ[a3];if(a3=="second"){a1.setUTCSeconds(a(a1.getUTCSeconds(),a0))}if(a3=="minute"){a1.setUTCMinutes(a(a1.getUTCMinutes(),a0))}if(a3=="hour"){a1.setUTCHours(a(a1.getUTCHours(),a0))}if(a3=="month"){a1.setUTCMonth(a(a1.getUTCMonth(),a0))}if(a3=="year"){a1.setUTCFullYear(a(a1.getUTCFullYear(),a0))}a1.setUTCMilliseconds(0);if(aW>=aJ.minute){a1.setUTCSeconds(0)}if(aW>=aJ.hour){a1.setUTCMinutes(0)}if(aW>=aJ.day){a1.setUTCHours(0)}if(aW>=aJ.day*4){a1.setUTCDate(1)}if(aW>=aJ.year){a1.setUTCMonth(0)}var a5=0,a4=Number.NaN,aY;do{aY=a4;a4=a1.getTime();a2.push(a4);if(a3=="month"){if(a0<1){a1.setUTCDate(1);var aV=a1.getTime();a1.setUTCMonth(a1.getUTCMonth()+1);var aZ=a1.getTime();a1.setTime(a4+a5*aJ.hour+(aZ-aV)*a0);a5=a1.getUTCHours();a1.setUTCHours(0)}else{a1.setUTCMonth(a1.getUTCMonth()+a0)}}else{if(a3=="year"){a1.setUTCFullYear(a1.getUTCFullYear()+a0)}else{a1.setTime(a4+aW)}}}while(a4<aX.max&&a4!=aY);return a2};aR=function(aV,aY){var a0=new Date(aV);if(aM.timeformat!=null){return c.plot.formatDate(a0,aM.timeformat,aM.monthNames)}var aW=aY.tickSize[0]*aJ[aY.tickSize[1]];var aX=aY.max-aY.min;var aZ=(aM.twelveHourClock)?" %p":"";if(aW<aJ.minute){fmt="%h:%M:%S"+aZ}else{if(aW<aJ.day){if(aX<2*aJ.day){fmt="%h:%M"+aZ}else{fmt="%b %d %h:%M"+aZ}}else{if(aW<aJ.month){fmt="%b %d"}else{if(aW<aJ.year){if(aX<aJ.year){fmt="%b"}else{fmt="%b %y"}}else{fmt="%y"}}}}return c.plot.formatDate(a0,fmt,aM.monthNames)}}else{var aU=aM.tickDecimals;var aP=-Math.floor(Math.log(aT)/Math.LN10);if(aU!=null&&aP>aU){aP=aU}aQ=Math.pow(10,-aP);aI=aT/aQ;if(aI<1.5){aO=1}else{if(aI<3){aO=2;if(aI>2.25&&(aU==null||aP+1<=aU)){aO=2.5;++aP}}else{if(aI<7.5){aO=5}else{aO=10}}}aO*=aQ;if(aM.minTickSize!=null&&aO<aM.minTickSize){aO=aM.minTickSize}aG.tickDecimals=Math.max(0,aU!=null?aU:aP);aG.tickSize=aM.tickSize||aO;aB=function(aX){var aZ=[];var a0=a(aX.min,aX.tickSize),aW=0,aV=Number.NaN,aY;do{aY=aV;aV=a0+aW*aX.tickSize;aZ.push(aV);++aW}while(aV<aX.max&&aV!=aY);return aZ};aR=function(aV,aW){return aV.toFixed(aW.tickDecimals)}}if(aM.alignTicksWithAxis!=null){var aF=(aG.direction=="x"?p:aw)[aM.alignTicksWithAxis-1];if(aF&&aF.used&&aF!=aG){var aL=aB(aG);if(aL.length>0){if(aM.min==null){aG.min=Math.min(aG.min,aL[0])}if(aM.max==null&&aL.length>1){aG.max=Math.max(aG.max,aL[aL.length-1])}}aB=function(aX){var aY=[],aV,aW;for(aW=0;aW<aF.ticks.length;++aW){aV=(aF.ticks[aW].v-aF.min)/(aF.max-aF.min);aV=aX.min+aV*(aX.max-aX.min);aY.push(aV)}return aY};if(aG.mode!="time"&&aM.tickDecimals==null){var aE=Math.max(0,-Math.floor(Math.log(aT)/Math.LN10)+1),aD=aB(aG);if(!(aD.length>1&&/\..*0$/.test((aD[1]-aD[0]).toFixed(aE)))){aG.tickDecimals=aE}}}}aG.tickGenerator=aB;if(c.isFunction(aM.tickFormatter)){aG.tickFormatter=function(aV,aW){return""+aM.tickFormatter(aV,aW)}}else{aG.tickFormatter=aR}}function P(aF){var aH=aF.options.ticks,aG=[];if(aH==null||(typeof aH=="number"&&aH>0)){aG=aF.tickGenerator(aF)}else{if(aH){if(c.isFunction(aH)){aG=aH({min:aF.min,max:aF.max})}else{aG=aH}}}var aE,aB;aF.ticks=[];for(aE=0;aE<aG.length;++aE){var aC=null;var aD=aG[aE];if(typeof aD=="object"){aB=+aD[0];if(aD.length>1){aC=aD[1]}}else{aB=+aD}if(aC==null){aC=aF.tickFormatter(aB,aF)}if(!isNaN(aB)){aF.ticks.push({v:aB,label:aC})}}}function ap(aB,aC){if(aB.options.autoscaleMargin&&aC.length>0){if(aB.options.min==null){aB.min=Math.min(aB.min,aC[0].v)}if(aB.options.max==null&&aC.length>1){aB.max=Math.max(aB.max,aC[aC.length-1].v)}}}function W(){H.clearRect(0,0,G,I);var aC=O.grid;if(aC.show&&aC.backgroundColor){N()}if(aC.show&&!aC.aboveData){ac()}for(var aB=0;aB<Q.length;++aB){an(ak.drawSeries,[H,Q[aB]]);d(Q[aB])}an(ak.draw,[H]);if(aC.show&&aC.aboveData){ac()}}function D(aB,aI){var aE,aH,aG,aD,aF=m();for(i=0;i<aF.length;++i){aE=aF[i];if(aE.direction==aI){aD=aI+aE.n+"axis";if(!aB[aD]&&aE.n==1){aD=aI+"axis"}if(aB[aD]){aH=aB[aD].from;aG=aB[aD].to;break}}}if(!aB[aD]){aE=aI=="x"?p[0]:aw[0];aH=aB[aI+"1"];aG=aB[aI+"2"]}if(aH!=null&&aG!=null&&aH>aG){var aC=aH;aH=aG;aG=aC}return{from:aH,to:aG,axis:aE}}function N(){H.save();H.translate(q.left,q.top);H.fillStyle=am(O.grid.backgroundColor,w,0,"rgba(255, 255, 255, 0)");H.fillRect(0,0,h,w);H.restore()}function ac(){var aF;H.save();H.translate(q.left,q.top);var aH=O.grid.markings;if(aH){if(c.isFunction(aH)){var aK=aq.getAxes();aK.xmin=aK.xaxis.min;aK.xmax=aK.xaxis.max;aK.ymin=aK.yaxis.min;aK.ymax=aK.yaxis.max;aH=aH(aK)}for(aF=0;aF<aH.length;++aF){var aD=aH[aF],aC=D(aD,"x"),aI=D(aD,"y");if(aC.from==null){aC.from=aC.axis.min}if(aC.to==null){aC.to=aC.axis.max}if(aI.from==null){aI.from=aI.axis.min}if(aI.to==null){aI.to=aI.axis.max}if(aC.to<aC.axis.min||aC.from>aC.axis.max||aI.to<aI.axis.min||aI.from>aI.axis.max){continue}aC.from=Math.max(aC.from,aC.axis.min);aC.to=Math.min(aC.to,aC.axis.max);aI.from=Math.max(aI.from,aI.axis.min);aI.to=Math.min(aI.to,aI.axis.max);if(aC.from==aC.to&&aI.from==aI.to){continue}aC.from=aC.axis.p2c(aC.from);aC.to=aC.axis.p2c(aC.to);aI.from=aI.axis.p2c(aI.from);aI.to=aI.axis.p2c(aI.to);if(aC.from==aC.to||aI.from==aI.to){H.beginPath();H.strokeStyle=aD.color||O.grid.markingsColor;H.lineWidth=aD.lineWidth||O.grid.markingsLineWidth;H.moveTo(aC.from,aI.from);H.lineTo(aC.to,aI.to);H.stroke()}else{H.fillStyle=aD.color||O.grid.markingsColor;H.fillRect(aC.from,aI.to,aC.to-aC.from,aI.from-aI.to)}}}var aK=m(),aM=O.grid.borderWidth;for(var aE=0;aE<aK.length;++aE){var aB=aK[aE],aG=aB.box,aQ=aB.tickLength,aN,aL,aP,aJ;if(!aB.show||aB.ticks.length==0){continue}H.strokeStyle=aB.options.tickColor||c.color.parse(aB.options.color).scale("a",0.22).toString();H.lineWidth=1;if(aB.direction=="x"){aN=0;if(aQ=="full"){aL=(aB.position=="top"?0:w)}else{aL=aG.top-q.top+(aB.position=="top"?aG.height:0)}}else{aL=0;if(aQ=="full"){aN=(aB.position=="left"?0:h)}else{aN=aG.left-q.left+(aB.position=="left"?aG.width:0)}}if(!aB.innermost){H.beginPath();aP=aJ=0;if(aB.direction=="x"){aP=h}else{aJ=w}if(H.lineWidth==1){aN=Math.floor(aN)+0.5;aL=Math.floor(aL)+0.5}H.moveTo(aN,aL);H.lineTo(aN+aP,aL+aJ);H.stroke()}H.beginPath();for(aF=0;aF<aB.ticks.length;++aF){var aO=aB.ticks[aF].v;aP=aJ=0;if(aO<aB.min||aO>aB.max||(aQ=="full"&&aM>0&&(aO==aB.min||aO==aB.max))){continue}if(aB.direction=="x"){aN=aB.p2c(aO);aJ=aQ=="full"?-w:aQ;if(aB.position=="top"){aJ=-aJ}}else{aL=aB.p2c(aO);aP=aQ=="full"?-h:aQ;if(aB.position=="left"){aP=-aP}}if(H.lineWidth==1){if(aB.direction=="x"){aN=Math.floor(aN)+0.5}else{aL=Math.floor(aL)+0.5}}H.moveTo(aN,aL);H.lineTo(aN+aP,aL+aJ)}H.stroke()}if(aM){H.lineWidth=aM;H.strokeStyle=O.grid.borderColor;H.strokeRect(-aM/2,-aM/2,h+aM,w+aM)}H.restore()}function k(){av.find(".tickLabels").remove();var aG=['<div class="tickLabels" style="font-size:smaller">'];var aJ=m();for(var aD=0;aD<aJ.length;++aD){var aC=aJ[aD],aF=aC.box;if(!aC.show){continue}aG.push('<div class="'+aC.direction+"Axis "+aC.direction+aC.n+'Axis" style="color:'+aC.options.color+'">');for(var aE=0;aE<aC.ticks.length;++aE){var aH=aC.ticks[aE];if(!aH.label||aH.v<aC.min||aH.v>aC.max){continue}var aK={},aI;if(aC.direction=="x"){aI="center";aK.left=Math.round(q.left+aC.p2c(aH.v)-aC.labelWidth/2);if(aC.position=="bottom"){aK.top=aF.top+aF.padding}else{aK.bottom=I-(aF.top+aF.height-aF.padding)}}else{aK.top=Math.round(q.top+aC.p2c(aH.v)-aC.labelHeight/2);if(aC.position=="left"){aK.right=G-(aF.left+aF.width-aF.padding);aI="right"}else{aK.left=aF.left+aF.padding;aI="left"}}aK.width=aC.labelWidth;var aB=["position:absolute","text-align:"+aI];for(var aL in aK){aB.push(aL+":"+aK[aL]+"px")}aG.push('<div class="tickLabel" style="'+aB.join(";")+'">'+aH.label+"</div>")}aG.push("</div>")}aG.push("</div>");av.append(aG.join(""))}function d(aB){if(aB.lines.show){at(aB)}if(aB.bars.show){e(aB)}if(aB.points.show){ao(aB)}}function at(aE){function aD(aP,aQ,aI,aU,aT){var aV=aP.points,aJ=aP.pointsize,aN=null,aM=null;H.beginPath();for(var aO=aJ;aO<aV.length;aO+=aJ){var aL=aV[aO-aJ],aS=aV[aO-aJ+1],aK=aV[aO],aR=aV[aO+1];if(aL==null||aK==null){continue}if(aS<=aR&&aS<aT.min){if(aR<aT.min){continue}aL=(aT.min-aS)/(aR-aS)*(aK-aL)+aL;aS=aT.min}else{if(aR<=aS&&aR<aT.min){if(aS<aT.min){continue}aK=(aT.min-aS)/(aR-aS)*(aK-aL)+aL;aR=aT.min}}if(aS>=aR&&aS>aT.max){if(aR>aT.max){continue}aL=(aT.max-aS)/(aR-aS)*(aK-aL)+aL;aS=aT.max}else{if(aR>=aS&&aR>aT.max){if(aS>aT.max){continue}aK=(aT.max-aS)/(aR-aS)*(aK-aL)+aL;aR=aT.max}}if(aL<=aK&&aL<aU.min){if(aK<aU.min){continue}aS=(aU.min-aL)/(aK-aL)*(aR-aS)+aS;aL=aU.min}else{if(aK<=aL&&aK<aU.min){if(aL<aU.min){continue}aR=(aU.min-aL)/(aK-aL)*(aR-aS)+aS;aK=aU.min}}if(aL>=aK&&aL>aU.max){if(aK>aU.max){continue}aS=(aU.max-aL)/(aK-aL)*(aR-aS)+aS;aL=aU.max}else{if(aK>=aL&&aK>aU.max){if(aL>aU.max){continue}aR=(aU.max-aL)/(aK-aL)*(aR-aS)+aS;aK=aU.max}}if(aL!=aN||aS!=aM){H.moveTo(aU.p2c(aL)+aQ,aT.p2c(aS)+aI)}aN=aK;aM=aR;H.lineTo(aU.p2c(aK)+aQ,aT.p2c(aR)+aI)}H.stroke()}function aF(aI,aQ,aP){var aW=aI.points,aV=aI.pointsize,aN=Math.min(Math.max(0,aP.min),aP.max),aX=0,aU,aT=false,aM=1,aL=0,aR=0;while(true){if(aV>0&&aX>aW.length+aV){break}aX+=aV;var aZ=aW[aX-aV],aK=aW[aX-aV+aM],aY=aW[aX],aJ=aW[aX+aM];if(aT){if(aV>0&&aZ!=null&&aY==null){aR=aX;aV=-aV;aM=2;continue}if(aV<0&&aX==aL+aV){H.fill();aT=false;aV=-aV;aM=1;aX=aL=aR+aV;continue}}if(aZ==null||aY==null){continue}if(aZ<=aY&&aZ<aQ.min){if(aY<aQ.min){continue}aK=(aQ.min-aZ)/(aY-aZ)*(aJ-aK)+aK;aZ=aQ.min}else{if(aY<=aZ&&aY<aQ.min){if(aZ<aQ.min){continue}aJ=(aQ.min-aZ)/(aY-aZ)*(aJ-aK)+aK;aY=aQ.min}}if(aZ>=aY&&aZ>aQ.max){if(aY>aQ.max){continue}aK=(aQ.max-aZ)/(aY-aZ)*(aJ-aK)+aK;aZ=aQ.max}else{if(aY>=aZ&&aY>aQ.max){if(aZ>aQ.max){continue}aJ=(aQ.max-aZ)/(aY-aZ)*(aJ-aK)+aK;aY=aQ.max}}if(!aT){H.beginPath();H.moveTo(aQ.p2c(aZ),aP.p2c(aN));aT=true}if(aK>=aP.max&&aJ>=aP.max){H.lineTo(aQ.p2c(aZ),aP.p2c(aP.max));H.lineTo(aQ.p2c(aY),aP.p2c(aP.max));continue}else{if(aK<=aP.min&&aJ<=aP.min){H.lineTo(aQ.p2c(aZ),aP.p2c(aP.min));H.lineTo(aQ.p2c(aY),aP.p2c(aP.min));continue}}var aO=aZ,aS=aY;if(aK<=aJ&&aK<aP.min&&aJ>=aP.min){aZ=(aP.min-aK)/(aJ-aK)*(aY-aZ)+aZ;aK=aP.min}else{if(aJ<=aK&&aJ<aP.min&&aK>=aP.min){aY=(aP.min-aK)/(aJ-aK)*(aY-aZ)+aZ;aJ=aP.min}}if(aK>=aJ&&aK>aP.max&&aJ<=aP.max){aZ=(aP.max-aK)/(aJ-aK)*(aY-aZ)+aZ;aK=aP.max}else{if(aJ>=aK&&aJ>aP.max&&aK<=aP.max){aY=(aP.max-aK)/(aJ-aK)*(aY-aZ)+aZ;aJ=aP.max}}if(aZ!=aO){H.lineTo(aQ.p2c(aO),aP.p2c(aK))}H.lineTo(aQ.p2c(aZ),aP.p2c(aK));H.lineTo(aQ.p2c(aY),aP.p2c(aJ));if(aY!=aS){H.lineTo(aQ.p2c(aY),aP.p2c(aJ));H.lineTo(aQ.p2c(aS),aP.p2c(aJ))}}}H.save();H.translate(q.left,q.top);H.lineJoin="round";var aG=aE.lines.lineWidth,aB=aE.shadowSize;if(aG>0&&aB>0){H.lineWidth=aB;H.strokeStyle="rgba(0,0,0,0.1)";var aH=Math.PI/18;aD(aE.datapoints,Math.sin(aH)*(aG/2+aB/2),Math.cos(aH)*(aG/2+aB/2),aE.xaxis,aE.yaxis);H.lineWidth=aB/2;aD(aE.datapoints,Math.sin(aH)*(aG/2+aB/4),Math.cos(aH)*(aG/2+aB/4),aE.xaxis,aE.yaxis)}H.lineWidth=aG;H.strokeStyle=aE.color;var aC=ae(aE.lines,aE.color,0,w);if(aC){H.fillStyle=aC;aF(aE.datapoints,aE.xaxis,aE.yaxis)}if(aG>0){aD(aE.datapoints,0,0,aE.xaxis,aE.yaxis)}H.restore()}function ao(aE){function aH(aN,aM,aU,aK,aS,aT,aQ,aJ){var aR=aN.points,aI=aN.pointsize;for(var aL=0;aL<aR.length;aL+=aI){var aP=aR[aL],aO=aR[aL+1];if(aP==null||aP<aT.min||aP>aT.max||aO<aQ.min||aO>aQ.max){continue}H.beginPath();aP=aT.p2c(aP);aO=aQ.p2c(aO)+aK;if(aJ=="circle"){H.arc(aP,aO,aM,0,aS?Math.PI:Math.PI*2,false)}else{aJ(H,aP,aO,aM,aS)}H.closePath();if(aU){H.fillStyle=aU;H.fill()}H.stroke()}}H.save();H.translate(q.left,q.top);var aG=aE.points.lineWidth,aC=aE.shadowSize,aB=aE.points.radius,aF=aE.points.symbol;if(aG>0&&aC>0){var aD=aC/2;H.lineWidth=aD;H.strokeStyle="rgba(0,0,0,0.1)";aH(aE.datapoints,aB,null,aD+aD/2,true,aE.xaxis,aE.yaxis,aF);H.strokeStyle="rgba(0,0,0,0.2)";aH(aE.datapoints,aB,null,aD/2,true,aE.xaxis,aE.yaxis,aF)}H.lineWidth=aG;H.strokeStyle=aE.color;aH(aE.datapoints,aB,ae(aE.points,aE.color),0,false,aE.xaxis,aE.yaxis,aF);H.restore()}function E(aN,aM,aV,aI,aQ,aF,aD,aL,aK,aU,aR,aC){var aE,aT,aJ,aP,aG,aB,aO,aH,aS;if(aR){aH=aB=aO=true;aG=false;aE=aV;aT=aN;aP=aM+aI;aJ=aM+aQ;if(aT<aE){aS=aT;aT=aE;aE=aS;aG=true;aB=false}}else{aG=aB=aO=true;aH=false;aE=aN+aI;aT=aN+aQ;aJ=aV;aP=aM;if(aP<aJ){aS=aP;aP=aJ;aJ=aS;aH=true;aO=false}}if(aT<aL.min||aE>aL.max||aP<aK.min||aJ>aK.max){return}if(aE<aL.min){aE=aL.min;aG=false}if(aT>aL.max){aT=aL.max;aB=false}if(aJ<aK.min){aJ=aK.min;aH=false}if(aP>aK.max){aP=aK.max;aO=false}aE=aL.p2c(aE);aJ=aK.p2c(aJ);aT=aL.p2c(aT);aP=aK.p2c(aP);if(aD){aU.beginPath();aU.moveTo(aE,aJ);aU.lineTo(aE,aP);aU.lineTo(aT,aP);aU.lineTo(aT,aJ);aU.fillStyle=aD(aJ,aP);aU.fill()}if(aC>0&&(aG||aB||aO||aH)){aU.beginPath();aU.moveTo(aE,aJ+aF);if(aG){aU.lineTo(aE,aP+aF)}else{aU.moveTo(aE,aP+aF)}if(aO){aU.lineTo(aT,aP+aF)}else{aU.moveTo(aT,aP+aF)}if(aB){aU.lineTo(aT,aJ+aF)}else{aU.moveTo(aT,aJ+aF)}if(aH){aU.lineTo(aE,aJ+aF)}else{aU.moveTo(aE,aJ+aF)}aU.stroke()}}function e(aD){function aC(aJ,aI,aL,aG,aK,aN,aM){var aO=aJ.points,aF=aJ.pointsize;for(var aH=0;aH<aO.length;aH+=aF){if(aO[aH]==null){continue}E(aO[aH],aO[aH+1],aO[aH+2],aI,aL,aG,aK,aN,aM,H,aD.bars.horizontal,aD.bars.lineWidth)}}H.save();H.translate(q.left,q.top);H.lineWidth=aD.bars.lineWidth;H.strokeStyle=aD.color;var aB=aD.bars.align=="left"?0:-aD.bars.barWidth/2;var aE=aD.bars.fill?function(aF,aG){return ae(aD.bars,aD.color,aF,aG)}:null;aC(aD.datapoints,aB,aB+aD.bars.barWidth,0,aE,aD.xaxis,aD.yaxis);H.restore()}function ae(aD,aB,aC,aF){var aE=aD.fill;if(!aE){return null}if(aD.fillColor){return am(aD.fillColor,aC,aF,aB)}var aG=c.color.parse(aB);aG.a=typeof aE=="number"?aE:0.4;aG.normalize();return aG.toString()}function o(){av.find(".legend").remove();if(!O.legend.show){return}var aH=[],aF=false,aN=O.legend.labelFormatter,aM,aJ;for(var aE=0;aE<Q.length;++aE){aM=Q[aE];aJ=aM.label;if(!aJ){continue}if(aE%O.legend.noColumns==0){if(aF){aH.push("</tr>")}aH.push("<tr>");aF=true}if(aN){aJ=aN(aJ,aM)}aH.push('<td class="legendColorBox"><div style="border:1px solid '+O.legend.labelBoxBorderColor+';padding:1px"><div style="width:4px;height:0;border:5px solid '+aM.color+';overflow:hidden"></div></div></td><td class="legendLabel">'+aJ+"</td>")}if(aF){aH.push("</tr>")}if(aH.length==0){return}var aL='<table style="font-size:smaller;color:'+O.grid.color+'">'+aH.join("")+"</table>";if(O.legend.container!=null){c(O.legend.container).html(aL)}else{var aI="",aC=O.legend.position,aD=O.legend.margin;if(aD[0]==null){aD=[aD,aD]}if(aC.charAt(0)=="n"){aI+="top:"+(aD[1]+q.top)+"px;"}else{if(aC.charAt(0)=="s"){aI+="bottom:"+(aD[1]+q.bottom)+"px;"}}if(aC.charAt(1)=="e"){aI+="right:"+(aD[0]+q.right)+"px;"}else{if(aC.charAt(1)=="w"){aI+="left:"+(aD[0]+q.left)+"px;"}}var aK=c('<div class="legend">'+aL.replace('style="','style="position:absolute;'+aI+";")+"</div>").appendTo(av);if(O.legend.backgroundOpacity!=0){var aG=O.legend.backgroundColor;if(aG==null){aG=O.grid.backgroundColor;if(aG&&typeof aG=="string"){aG=c.color.parse(aG)}else{aG=c.color.extract(aK,"background-color")}aG.a=1;aG=aG.toString()}var aB=aK.children();c('<div style="position:absolute;width:'+aB.width()+"px;height:"+aB.height()+"px;"+aI+"background-color:"+aG+';"> </div>').prependTo(aK).css("opacity",O.legend.backgroundOpacity)}}}var ab=[],M=null;function K(aI,aG,aD){var aO=O.grid.mouseActiveRadius,a0=aO*aO+1,aY=null,aR=false,aW,aU;for(aW=Q.length-1;aW>=0;--aW){if(!aD(Q[aW])){continue}var aP=Q[aW],aH=aP.xaxis,aF=aP.yaxis,aV=aP.datapoints.points,aT=aP.datapoints.pointsize,aQ=aH.c2p(aI),aN=aF.c2p(aG),aC=aO/aH.scale,aB=aO/aF.scale;if(aH.options.inverseTransform){aC=Number.MAX_VALUE}if(aF.options.inverseTransform){aB=Number.MAX_VALUE}if(aP.lines.show||aP.points.show){for(aU=0;aU<aV.length;aU+=aT){var aK=aV[aU],aJ=aV[aU+1];if(aK==null){continue}if(aK-aQ>aC||aK-aQ<-aC||aJ-aN>aB||aJ-aN<-aB){continue}var aM=Math.abs(aH.p2c(aK)-aI),aL=Math.abs(aF.p2c(aJ)-aG),aS=aM*aM+aL*aL;if(aS<a0){a0=aS;aY=[aW,aU/aT]}}}if(aP.bars.show&&!aY){var aE=aP.bars.align=="left"?0:-aP.bars.barWidth/2,aX=aE+aP.bars.barWidth;for(aU=0;aU<aV.length;aU+=aT){var aK=aV[aU],aJ=aV[aU+1],aZ=aV[aU+2];if(aK==null){continue}if(Q[aW].bars.horizontal?(aQ<=Math.max(aZ,aK)&&aQ>=Math.min(aZ,aK)&&aN>=aJ+aE&&aN<=aJ+aX):(aQ>=aK+aE&&aQ<=aK+aX&&aN>=Math.min(aZ,aJ)&&aN<=Math.max(aZ,aJ))){aY=[aW,aU/aT]}}}}if(aY){aW=aY[0];aU=aY[1];aT=Q[aW].datapoints.pointsize;return{datapoint:Q[aW].datapoints.points.slice(aU*aT,(aU+1)*aT),dataIndex:aU,series:Q[aW],seriesIndex:aW}}return null}function aa(aB){if(O.grid.hoverable){u("plothover",aB,function(aC){return aC.hoverable!=false})}}function l(aB){if(O.grid.hoverable){u("plothover",aB,function(aC){return false})}}function R(aB){u("plotclick",aB,function(aC){return aC.clickable!=false})}function u(aC,aB,aD){var aE=y.offset(),aH=aB.pageX-aE.left-q.left,aF=aB.pageY-aE.top-q.top,aJ=C({left:aH,top:aF});aJ.pageX=aB.pageX;aJ.pageY=aB.pageY;var aK=K(aH,aF,aD);if(aK){aK.pageX=parseInt(aK.series.xaxis.p2c(aK.datapoint[0])+aE.left+q.left);aK.pageY=parseInt(aK.series.yaxis.p2c(aK.datapoint[1])+aE.top+q.top)}if(O.grid.autoHighlight){for(var aG=0;aG<ab.length;++aG){var aI=ab[aG];if(aI.auto==aC&&!(aK&&aI.series==aK.series&&aI.point[0]==aK.datapoint[0]&&aI.point[1]==aK.datapoint[1])){T(aI.series,aI.point)}}if(aK){x(aK.series,aK.datapoint,aC)}}av.trigger(aC,[aJ,aK])}function f(){if(!M){M=setTimeout(s,30)}}function s(){M=null;A.save();A.clearRect(0,0,G,I);A.translate(q.left,q.top);var aC,aB;for(aC=0;aC<ab.length;++aC){aB=ab[aC];if(aB.series.bars.show){v(aB.series,aB.point)}else{ay(aB.series,aB.point)}}A.restore();an(ak.drawOverlay,[A])}function x(aD,aB,aF){if(typeof aD=="number"){aD=Q[aD]}if(typeof aB=="number"){var aE=aD.datapoints.pointsize;aB=aD.datapoints.points.slice(aE*aB,aE*(aB+1))}var aC=al(aD,aB);if(aC==-1){ab.push({series:aD,point:aB,auto:aF});f()}else{if(!aF){ab[aC].auto=false}}}function T(aD,aB){if(aD==null&&aB==null){ab=[];f()}if(typeof aD=="number"){aD=Q[aD]}if(typeof aB=="number"){aB=aD.data[aB]}var aC=al(aD,aB);if(aC!=-1){ab.splice(aC,1);f()}}function al(aD,aE){for(var aB=0;aB<ab.length;++aB){var aC=ab[aB];if(aC.series==aD&&aC.point[0]==aE[0]&&aC.point[1]==aE[1]){return aB}}return -1}function ay(aE,aD){var aC=aD[0],aI=aD[1],aH=aE.xaxis,aG=aE.yaxis;if(aC<aH.min||aC>aH.max||aI<aG.min||aI>aG.max){return}var aF=aE.points.radius+aE.points.lineWidth/2;A.lineWidth=aF;A.strokeStyle=c.color.parse(aE.color).scale("a",0.5).toString();var aB=1.5*aF,aC=aH.p2c(aC),aI=aG.p2c(aI);A.beginPath();if(aE.points.symbol=="circle"){A.arc(aC,aI,aB,0,2*Math.PI,false)}else{aE.points.symbol(A,aC,aI,aB,false)}A.closePath();A.stroke()}function v(aE,aB){A.lineWidth=aE.bars.lineWidth;A.strokeStyle=c.color.parse(aE.color).scale("a",0.5).toString();var aD=c.color.parse(aE.color).scale("a",0.5).toString();var aC=aE.bars.align=="left"?0:-aE.bars.barWidth/2;E(aB[0],aB[1],aB[2]||0,aC,aC+aE.bars.barWidth,0,function(){return aD},aE.xaxis,aE.yaxis,A,aE.bars.horizontal,aE.bars.lineWidth)}function am(aJ,aB,aH,aC){if(typeof aJ=="string"){return aJ}else{var aI=H.createLinearGradient(0,aH,0,aB);for(var aE=0,aD=aJ.colors.length;aE<aD;++aE){var aF=aJ.colors[aE];if(typeof aF!="string"){var aG=c.color.parse(aC);if(aF.brightness!=null){aG=aG.scale("rgb",aF.brightness)}if(aF.opacity!=null){aG.a*=aF.opacity}aF=aG.toString()}aI.addColorStop(aE/(aD-1),aF)}return aI}}}c.plot=function(g,e,d){var f=new b(c(g),e,d,c.plot.plugins);return f};c.plot.version="0.7";c.plot.plugins=[];c.plot.formatDate=function(l,f,h){var o=function(d){d=""+d;return d.length==1?"0"+d:d};var e=[];var p=false,j=false;var n=l.getUTCHours();var k=n<12;if(h==null){h=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]}if(f.search(/%p|%P/)!=-1){if(n>12){n=n-12}else{if(n==0){n=12}}}for(var g=0;g<f.length;++g){var m=f.charAt(g);if(p){switch(m){case"h":m=""+n;break;case"H":m=o(n);break;case"M":m=o(l.getUTCMinutes());break;case"S":m=o(l.getUTCSeconds());break;case"d":m=""+l.getUTCDate();break;case"m":m=""+(l.getUTCMonth()+1);break;case"y":m=""+l.getUTCFullYear();break;case"b":m=""+h[l.getUTCMonth()];break;case"p":m=(k)?("am"):("pm");break;case"P":m=(k)?("AM"):("PM");break;case"0":m="";j=true;break}if(m&&j){m=o(m);j=false}e.push(m);if(!j){p=false}}else{if(m=="%"){p=true}else{e.push(m)}}}return e.join("")};function a(e,d){return d*Math.floor(e/d)}})(jQuery);
+ templates/js/jquery.flot-0.8.3.min.js view
@@ -0,0 +1,8 @@+/* Javascript plotting library for jQuery, version 0.8.3.++Copyright (c) 2007-2014 IOLA and Ole Laursen.+Licensed under the MIT license.++*/+(function($){$.color={};$.color.make=function(r,g,b,a){var o={};o.r=r||0;o.g=g||0;o.b=b||0;o.a=a!=null?a:1;o.add=function(c,d){for(var i=0;i<c.length;++i)o[c.charAt(i)]+=d;return o.normalize()};o.scale=function(c,f){for(var i=0;i<c.length;++i)o[c.charAt(i)]*=f;return o.normalize()};o.toString=function(){if(o.a>=1){return"rgb("+[o.r,o.g,o.b].join(",")+")"}else{return"rgba("+[o.r,o.g,o.b,o.a].join(",")+")"}};o.normalize=function(){function clamp(min,value,max){return value<min?min:value>max?max:value}o.r=clamp(0,parseInt(o.r),255);o.g=clamp(0,parseInt(o.g),255);o.b=clamp(0,parseInt(o.b),255);o.a=clamp(0,o.a,1);return o};o.clone=function(){return $.color.make(o.r,o.b,o.g,o.a)};return o.normalize()};$.color.extract=function(elem,css){var c;do{c=elem.css(css).toLowerCase();if(c!=""&&c!="transparent")break;elem=elem.parent()}while(elem.length&&!$.nodeName(elem.get(0),"body"));if(c=="rgba(0, 0, 0, 0)")c="transparent";return $.color.parse(c)};$.color.parse=function(str){var res,m=$.color.make;if(res=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(str))return m(parseInt(res[1],10),parseInt(res[2],10),parseInt(res[3],10));if(res=/rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]+(?:\.[0-9]+)?)\s*\)/.exec(str))return m(parseInt(res[1],10),parseInt(res[2],10),parseInt(res[3],10),parseFloat(res[4]));if(res=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(str))return m(parseFloat(res[1])*2.55,parseFloat(res[2])*2.55,parseFloat(res[3])*2.55);if(res=/rgba\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\s*\)/.exec(str))return m(parseFloat(res[1])*2.55,parseFloat(res[2])*2.55,parseFloat(res[3])*2.55,parseFloat(res[4]));if(res=/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(str))return m(parseInt(res[1],16),parseInt(res[2],16),parseInt(res[3],16));if(res=/#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(str))return m(parseInt(res[1]+res[1],16),parseInt(res[2]+res[2],16),parseInt(res[3]+res[3],16));var name=$.trim(str).toLowerCase();if(name=="transparent")return m(255,255,255,0);else{res=lookupColors[name]||[0,0,0];return m(res[0],res[1],res[2])}};var lookupColors={aqua:[0,255,255],azure:[240,255,255],beige:[245,245,220],black:[0,0,0],blue:[0,0,255],brown:[165,42,42],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgrey:[169,169,169],darkgreen:[0,100,0],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkviolet:[148,0,211],fuchsia:[255,0,255],gold:[255,215,0],green:[0,128,0],indigo:[75,0,130],khaki:[240,230,140],lightblue:[173,216,230],lightcyan:[224,255,255],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightyellow:[255,255,224],lime:[0,255,0],magenta:[255,0,255],maroon:[128,0,0],navy:[0,0,128],olive:[128,128,0],orange:[255,165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0]}})(jQuery);(function($){var hasOwnProperty=Object.prototype.hasOwnProperty;if(!$.fn.detach){$.fn.detach=function(){return this.each(function(){if(this.parentNode){this.parentNode.removeChild(this)}})}}function Canvas(cls,container){var element=container.children("."+cls)[0];if(element==null){element=document.createElement("canvas");element.className=cls;$(element).css({direction:"ltr",position:"absolute",left:0,top:0}).appendTo(container);if(!element.getContext){if(window.G_vmlCanvasManager){element=window.G_vmlCanvasManager.initElement(element)}else{throw new Error("Canvas is not available. If you're using IE with a fall-back such as Excanvas, then there's either a mistake in your conditional include, or the page has no DOCTYPE and is rendering in Quirks Mode.")}}}this.element=element;var context=this.context=element.getContext("2d");var devicePixelRatio=window.devicePixelRatio||1,backingStoreRatio=context.webkitBackingStorePixelRatio||context.mozBackingStorePixelRatio||context.msBackingStorePixelRatio||context.oBackingStorePixelRatio||context.backingStorePixelRatio||1;this.pixelRatio=devicePixelRatio/backingStoreRatio;this.resize(container.width(),container.height());this.textContainer=null;this.text={};this._textCache={}}Canvas.prototype.resize=function(width,height){if(width<=0||height<=0){throw new Error("Invalid dimensions for plot, width = "+width+", height = "+height)}var element=this.element,context=this.context,pixelRatio=this.pixelRatio;if(this.width!=width){element.width=width*pixelRatio;element.style.width=width+"px";this.width=width}if(this.height!=height){element.height=height*pixelRatio;element.style.height=height+"px";this.height=height}context.restore();context.save();context.scale(pixelRatio,pixelRatio)};Canvas.prototype.clear=function(){this.context.clearRect(0,0,this.width,this.height)};Canvas.prototype.render=function(){var cache=this._textCache;for(var layerKey in cache){if(hasOwnProperty.call(cache,layerKey)){var layer=this.getTextLayer(layerKey),layerCache=cache[layerKey];layer.hide();for(var styleKey in layerCache){if(hasOwnProperty.call(layerCache,styleKey)){var styleCache=layerCache[styleKey];for(var key in styleCache){if(hasOwnProperty.call(styleCache,key)){var positions=styleCache[key].positions;for(var i=0,position;position=positions[i];i++){if(position.active){if(!position.rendered){layer.append(position.element);position.rendered=true}}else{positions.splice(i--,1);if(position.rendered){position.element.detach()}}}if(positions.length==0){delete styleCache[key]}}}}}layer.show()}}};Canvas.prototype.getTextLayer=function(classes){var layer=this.text[classes];if(layer==null){if(this.textContainer==null){this.textContainer=$("<div class='flot-text'></div>").css({position:"absolute",top:0,left:0,bottom:0,right:0,"font-size":"smaller",color:"#545454"}).insertAfter(this.element)}layer=this.text[classes]=$("<div></div>").addClass(classes).css({position:"absolute",top:0,left:0,bottom:0,right:0}).appendTo(this.textContainer)}return layer};Canvas.prototype.getTextInfo=function(layer,text,font,angle,width){var textStyle,layerCache,styleCache,info;text=""+text;if(typeof font==="object"){textStyle=font.style+" "+font.variant+" "+font.weight+" "+font.size+"px/"+font.lineHeight+"px "+font.family}else{textStyle=font}layerCache=this._textCache[layer];if(layerCache==null){layerCache=this._textCache[layer]={}}styleCache=layerCache[textStyle];if(styleCache==null){styleCache=layerCache[textStyle]={}}info=styleCache[text];if(info==null){var element=$("<div></div>").html(text).css({position:"absolute","max-width":width,top:-9999}).appendTo(this.getTextLayer(layer));if(typeof font==="object"){element.css({font:textStyle,color:font.color})}else if(typeof font==="string"){element.addClass(font)}info=styleCache[text]={width:element.outerWidth(true),height:element.outerHeight(true),element:element,positions:[]};element.detach()}return info};Canvas.prototype.addText=function(layer,x,y,text,font,angle,width,halign,valign){var info=this.getTextInfo(layer,text,font,angle,width),positions=info.positions;if(halign=="center"){x-=info.width/2}else if(halign=="right"){x-=info.width}if(valign=="middle"){y-=info.height/2}else if(valign=="bottom"){y-=info.height}for(var i=0,position;position=positions[i];i++){if(position.x==x&&position.y==y){position.active=true;return}}position={active:true,rendered:false,element:positions.length?info.element.clone():info.element,x:x,y:y};positions.push(position);position.element.css({top:Math.round(y),left:Math.round(x),"text-align":halign})};Canvas.prototype.removeText=function(layer,x,y,text,font,angle){if(text==null){var layerCache=this._textCache[layer];if(layerCache!=null){for(var styleKey in layerCache){if(hasOwnProperty.call(layerCache,styleKey)){var styleCache=layerCache[styleKey];for(var key in styleCache){if(hasOwnProperty.call(styleCache,key)){var positions=styleCache[key].positions;for(var i=0,position;position=positions[i];i++){position.active=false}}}}}}}else{var positions=this.getTextInfo(layer,text,font,angle).positions;for(var i=0,position;position=positions[i];i++){if(position.x==x&&position.y==y){position.active=false}}}};function Plot(placeholder,data_,options_,plugins){var series=[],options={colors:["#edc240","#afd8f8","#cb4b4b","#4da74d","#9440ed"],legend:{show:true,noColumns:1,labelFormatter:null,labelBoxBorderColor:"#ccc",container:null,position:"ne",margin:5,backgroundColor:null,backgroundOpacity:.85,sorted:null},xaxis:{show:null,position:"bottom",mode:null,font:null,color:null,tickColor:null,transform:null,inverseTransform:null,min:null,max:null,autoscaleMargin:null,ticks:null,tickFormatter:null,labelWidth:null,labelHeight:null,reserveSpace:null,tickLength:null,alignTicksWithAxis:null,tickDecimals:null,tickSize:null,minTickSize:null},yaxis:{autoscaleMargin:.02,position:"left"},xaxes:[],yaxes:[],series:{points:{show:false,radius:3,lineWidth:2,fill:true,fillColor:"#ffffff",symbol:"circle"},lines:{lineWidth:2,fill:false,fillColor:null,steps:false},bars:{show:false,lineWidth:2,barWidth:1,fill:true,fillColor:null,align:"left",horizontal:false,zero:true},shadowSize:3,highlightColor:null},grid:{show:true,aboveData:false,color:"#545454",backgroundColor:null,borderColor:null,tickColor:null,margin:0,labelMargin:5,axisMargin:8,borderWidth:2,minBorderMargin:null,markings:null,markingsColor:"#f4f4f4",markingsLineWidth:2,clickable:false,hoverable:false,autoHighlight:true,mouseActiveRadius:10},interaction:{redrawOverlayInterval:1e3/60},hooks:{}},surface=null,overlay=null,eventHolder=null,ctx=null,octx=null,xaxes=[],yaxes=[],plotOffset={left:0,right:0,top:0,bottom:0},plotWidth=0,plotHeight=0,hooks={processOptions:[],processRawData:[],processDatapoints:[],processOffset:[],drawBackground:[],drawSeries:[],draw:[],bindEvents:[],drawOverlay:[],shutdown:[]},plot=this;plot.setData=setData;plot.setupGrid=setupGrid;plot.draw=draw;plot.getPlaceholder=function(){return placeholder};plot.getCanvas=function(){return surface.element};plot.getPlotOffset=function(){return plotOffset};plot.width=function(){return plotWidth};plot.height=function(){return plotHeight};plot.offset=function(){var o=eventHolder.offset();o.left+=plotOffset.left;o.top+=plotOffset.top;return o};plot.getData=function(){return series};plot.getAxes=function(){var res={},i;$.each(xaxes.concat(yaxes),function(_,axis){if(axis)res[axis.direction+(axis.n!=1?axis.n:"")+"axis"]=axis});return res};plot.getXAxes=function(){return xaxes};plot.getYAxes=function(){return yaxes};plot.c2p=canvasToAxisCoords;plot.p2c=axisToCanvasCoords;plot.getOptions=function(){return options};plot.highlight=highlight;plot.unhighlight=unhighlight;plot.triggerRedrawOverlay=triggerRedrawOverlay;plot.pointOffset=function(point){return{left:parseInt(xaxes[axisNumber(point,"x")-1].p2c(+point.x)+plotOffset.left,10),top:parseInt(yaxes[axisNumber(point,"y")-1].p2c(+point.y)+plotOffset.top,10)}};plot.shutdown=shutdown;plot.destroy=function(){shutdown();placeholder.removeData("plot").empty();series=[];options=null;surface=null;overlay=null;eventHolder=null;ctx=null;octx=null;xaxes=[];yaxes=[];hooks=null;highlights=[];plot=null};plot.resize=function(){var width=placeholder.width(),height=placeholder.height();surface.resize(width,height);overlay.resize(width,height)};plot.hooks=hooks;initPlugins(plot);parseOptions(options_);setupCanvases();setData(data_);setupGrid();draw();bindEvents();function executeHooks(hook,args){args=[plot].concat(args);for(var i=0;i<hook.length;++i)hook[i].apply(this,args)}function initPlugins(){var classes={Canvas:Canvas};for(var i=0;i<plugins.length;++i){var p=plugins[i];p.init(plot,classes);if(p.options)$.extend(true,options,p.options)}}function parseOptions(opts){$.extend(true,options,opts);if(opts&&opts.colors){options.colors=opts.colors}if(options.xaxis.color==null)options.xaxis.color=$.color.parse(options.grid.color).scale("a",.22).toString();if(options.yaxis.color==null)options.yaxis.color=$.color.parse(options.grid.color).scale("a",.22).toString();if(options.xaxis.tickColor==null)options.xaxis.tickColor=options.grid.tickColor||options.xaxis.color;if(options.yaxis.tickColor==null)options.yaxis.tickColor=options.grid.tickColor||options.yaxis.color;if(options.grid.borderColor==null)options.grid.borderColor=options.grid.color;if(options.grid.tickColor==null)options.grid.tickColor=$.color.parse(options.grid.color).scale("a",.22).toString();var i,axisOptions,axisCount,fontSize=placeholder.css("font-size"),fontSizeDefault=fontSize?+fontSize.replace("px",""):13,fontDefaults={style:placeholder.css("font-style"),size:Math.round(.8*fontSizeDefault),variant:placeholder.css("font-variant"),weight:placeholder.css("font-weight"),family:placeholder.css("font-family")};axisCount=options.xaxes.length||1;for(i=0;i<axisCount;++i){axisOptions=options.xaxes[i];if(axisOptions&&!axisOptions.tickColor){axisOptions.tickColor=axisOptions.color}axisOptions=$.extend(true,{},options.xaxis,axisOptions);options.xaxes[i]=axisOptions;if(axisOptions.font){axisOptions.font=$.extend({},fontDefaults,axisOptions.font);if(!axisOptions.font.color){axisOptions.font.color=axisOptions.color}if(!axisOptions.font.lineHeight){axisOptions.font.lineHeight=Math.round(axisOptions.font.size*1.15)}}}axisCount=options.yaxes.length||1;for(i=0;i<axisCount;++i){axisOptions=options.yaxes[i];if(axisOptions&&!axisOptions.tickColor){axisOptions.tickColor=axisOptions.color}axisOptions=$.extend(true,{},options.yaxis,axisOptions);options.yaxes[i]=axisOptions;if(axisOptions.font){axisOptions.font=$.extend({},fontDefaults,axisOptions.font);if(!axisOptions.font.color){axisOptions.font.color=axisOptions.color}if(!axisOptions.font.lineHeight){axisOptions.font.lineHeight=Math.round(axisOptions.font.size*1.15)}}}if(options.xaxis.noTicks&&options.xaxis.ticks==null)options.xaxis.ticks=options.xaxis.noTicks;if(options.yaxis.noTicks&&options.yaxis.ticks==null)options.yaxis.ticks=options.yaxis.noTicks;if(options.x2axis){options.xaxes[1]=$.extend(true,{},options.xaxis,options.x2axis);options.xaxes[1].position="top";if(options.x2axis.min==null){options.xaxes[1].min=null}if(options.x2axis.max==null){options.xaxes[1].max=null}}if(options.y2axis){options.yaxes[1]=$.extend(true,{},options.yaxis,options.y2axis);options.yaxes[1].position="right";if(options.y2axis.min==null){options.yaxes[1].min=null}if(options.y2axis.max==null){options.yaxes[1].max=null}}if(options.grid.coloredAreas)options.grid.markings=options.grid.coloredAreas;if(options.grid.coloredAreasColor)options.grid.markingsColor=options.grid.coloredAreasColor;if(options.lines)$.extend(true,options.series.lines,options.lines);if(options.points)$.extend(true,options.series.points,options.points);if(options.bars)$.extend(true,options.series.bars,options.bars);if(options.shadowSize!=null)options.series.shadowSize=options.shadowSize;if(options.highlightColor!=null)options.series.highlightColor=options.highlightColor;for(i=0;i<options.xaxes.length;++i)getOrCreateAxis(xaxes,i+1).options=options.xaxes[i];for(i=0;i<options.yaxes.length;++i)getOrCreateAxis(yaxes,i+1).options=options.yaxes[i];for(var n in hooks)if(options.hooks[n]&&options.hooks[n].length)hooks[n]=hooks[n].concat(options.hooks[n]);executeHooks(hooks.processOptions,[options])}function setData(d){series=parseData(d);fillInSeriesOptions();processData()}function parseData(d){var res=[];for(var i=0;i<d.length;++i){var s=$.extend(true,{},options.series);if(d[i].data!=null){s.data=d[i].data;delete d[i].data;$.extend(true,s,d[i]);d[i].data=s.data}else s.data=d[i];res.push(s)}return res}function axisNumber(obj,coord){var a=obj[coord+"axis"];if(typeof a=="object")a=a.n;if(typeof a!="number")a=1;return a}function allAxes(){return $.grep(xaxes.concat(yaxes),function(a){return a})}function canvasToAxisCoords(pos){var res={},i,axis;for(i=0;i<xaxes.length;++i){axis=xaxes[i];if(axis&&axis.used)res["x"+axis.n]=axis.c2p(pos.left)}for(i=0;i<yaxes.length;++i){axis=yaxes[i];if(axis&&axis.used)res["y"+axis.n]=axis.c2p(pos.top)}if(res.x1!==undefined)res.x=res.x1;if(res.y1!==undefined)res.y=res.y1;return res}function axisToCanvasCoords(pos){var res={},i,axis,key;for(i=0;i<xaxes.length;++i){axis=xaxes[i];if(axis&&axis.used){key="x"+axis.n;if(pos[key]==null&&axis.n==1)key="x";if(pos[key]!=null){res.left=axis.p2c(pos[key]);break}}}for(i=0;i<yaxes.length;++i){axis=yaxes[i];if(axis&&axis.used){key="y"+axis.n;if(pos[key]==null&&axis.n==1)key="y";if(pos[key]!=null){res.top=axis.p2c(pos[key]);break}}}return res}function getOrCreateAxis(axes,number){if(!axes[number-1])axes[number-1]={n:number,direction:axes==xaxes?"x":"y",options:$.extend(true,{},axes==xaxes?options.xaxis:options.yaxis)};return axes[number-1]}function fillInSeriesOptions(){var neededColors=series.length,maxIndex=-1,i;for(i=0;i<series.length;++i){var sc=series[i].color;if(sc!=null){neededColors--;if(typeof sc=="number"&&sc>maxIndex){maxIndex=sc}}}if(neededColors<=maxIndex){neededColors=maxIndex+1}var c,colors=[],colorPool=options.colors,colorPoolSize=colorPool.length,variation=0;for(i=0;i<neededColors;i++){c=$.color.parse(colorPool[i%colorPoolSize]||"#666");if(i%colorPoolSize==0&&i){if(variation>=0){if(variation<.5){variation=-variation-.2}else variation=0}else variation=-variation}colors[i]=c.scale("rgb",1+variation)}var colori=0,s;for(i=0;i<series.length;++i){s=series[i];if(s.color==null){s.color=colors[colori].toString();++colori}else if(typeof s.color=="number")s.color=colors[s.color].toString();if(s.lines.show==null){var v,show=true;for(v in s)if(s[v]&&s[v].show){show=false;break}if(show)s.lines.show=true}if(s.lines.zero==null){s.lines.zero=!!s.lines.fill}s.xaxis=getOrCreateAxis(xaxes,axisNumber(s,"x"));s.yaxis=getOrCreateAxis(yaxes,axisNumber(s,"y"))}}function processData(){var topSentry=Number.POSITIVE_INFINITY,bottomSentry=Number.NEGATIVE_INFINITY,fakeInfinity=Number.MAX_VALUE,i,j,k,m,length,s,points,ps,x,y,axis,val,f,p,data,format;function updateAxis(axis,min,max){if(min<axis.datamin&&min!=-fakeInfinity)axis.datamin=min;if(max>axis.datamax&&max!=fakeInfinity)axis.datamax=max}$.each(allAxes(),function(_,axis){axis.datamin=topSentry;axis.datamax=bottomSentry;axis.used=false});for(i=0;i<series.length;++i){s=series[i];s.datapoints={points:[]};executeHooks(hooks.processRawData,[s,s.data,s.datapoints])}for(i=0;i<series.length;++i){s=series[i];data=s.data;format=s.datapoints.format;if(!format){format=[];format.push({x:true,number:true,required:true});format.push({y:true,number:true,required:true});if(s.bars.show||s.lines.show&&s.lines.fill){var autoscale=!!(s.bars.show&&s.bars.zero||s.lines.show&&s.lines.zero);format.push({y:true,number:true,required:false,defaultValue:0,autoscale:autoscale});if(s.bars.horizontal){delete format[format.length-1].y;format[format.length-1].x=true}}s.datapoints.format=format}if(s.datapoints.pointsize!=null)continue;s.datapoints.pointsize=format.length;ps=s.datapoints.pointsize;points=s.datapoints.points;var insertSteps=s.lines.show&&s.lines.steps;s.xaxis.used=s.yaxis.used=true;for(j=k=0;j<data.length;++j,k+=ps){p=data[j];var nullify=p==null;if(!nullify){for(m=0;m<ps;++m){val=p[m];f=format[m];if(f){if(f.number&&val!=null){val=+val;if(isNaN(val))val=null;else if(val==Infinity)val=fakeInfinity;else if(val==-Infinity)val=-fakeInfinity}if(val==null){if(f.required)nullify=true;if(f.defaultValue!=null)val=f.defaultValue}}points[k+m]=val}}if(nullify){for(m=0;m<ps;++m){val=points[k+m];if(val!=null){f=format[m];if(f.autoscale!==false){if(f.x){updateAxis(s.xaxis,val,val)}if(f.y){updateAxis(s.yaxis,val,val)}}}points[k+m]=null}}else{if(insertSteps&&k>0&&points[k-ps]!=null&&points[k-ps]!=points[k]&&points[k-ps+1]!=points[k+1]){for(m=0;m<ps;++m)points[k+ps+m]=points[k+m];points[k+1]=points[k-ps+1];k+=ps}}}}for(i=0;i<series.length;++i){s=series[i];executeHooks(hooks.processDatapoints,[s,s.datapoints])}for(i=0;i<series.length;++i){s=series[i];points=s.datapoints.points;ps=s.datapoints.pointsize;format=s.datapoints.format;var xmin=topSentry,ymin=topSentry,xmax=bottomSentry,ymax=bottomSentry;for(j=0;j<points.length;j+=ps){if(points[j]==null)continue;for(m=0;m<ps;++m){val=points[j+m];f=format[m];if(!f||f.autoscale===false||val==fakeInfinity||val==-fakeInfinity)continue;if(f.x){if(val<xmin)xmin=val;if(val>xmax)xmax=val}if(f.y){if(val<ymin)ymin=val;if(val>ymax)ymax=val}}}if(s.bars.show){var delta;switch(s.bars.align){case"left":delta=0;break;case"right":delta=-s.bars.barWidth;break;default:delta=-s.bars.barWidth/2}if(s.bars.horizontal){ymin+=delta;ymax+=delta+s.bars.barWidth}else{xmin+=delta;xmax+=delta+s.bars.barWidth}}updateAxis(s.xaxis,xmin,xmax);updateAxis(s.yaxis,ymin,ymax)}$.each(allAxes(),function(_,axis){if(axis.datamin==topSentry)axis.datamin=null;if(axis.datamax==bottomSentry)axis.datamax=null})}function setupCanvases(){placeholder.css("padding",0).children().filter(function(){return!$(this).hasClass("flot-overlay")&&!$(this).hasClass("flot-base")}).remove();if(placeholder.css("position")=="static")placeholder.css("position","relative");surface=new Canvas("flot-base",placeholder);overlay=new Canvas("flot-overlay",placeholder);ctx=surface.context;octx=overlay.context;eventHolder=$(overlay.element).unbind();var existing=placeholder.data("plot");if(existing){existing.shutdown();overlay.clear()}placeholder.data("plot",plot)}function bindEvents(){if(options.grid.hoverable){eventHolder.mousemove(onMouseMove);eventHolder.bind("mouseleave",onMouseLeave)}if(options.grid.clickable)eventHolder.click(onClick);executeHooks(hooks.bindEvents,[eventHolder])}function shutdown(){if(redrawTimeout)clearTimeout(redrawTimeout);eventHolder.unbind("mousemove",onMouseMove);eventHolder.unbind("mouseleave",onMouseLeave);eventHolder.unbind("click",onClick);executeHooks(hooks.shutdown,[eventHolder])}function setTransformationHelpers(axis){function identity(x){return x}var s,m,t=axis.options.transform||identity,it=axis.options.inverseTransform;if(axis.direction=="x"){s=axis.scale=plotWidth/Math.abs(t(axis.max)-t(axis.min));m=Math.min(t(axis.max),t(axis.min))}else{s=axis.scale=plotHeight/Math.abs(t(axis.max)-t(axis.min));s=-s;m=Math.max(t(axis.max),t(axis.min))}if(t==identity)axis.p2c=function(p){return(p-m)*s};else axis.p2c=function(p){return(t(p)-m)*s};if(!it)axis.c2p=function(c){return m+c/s};else axis.c2p=function(c){return it(m+c/s)}}function measureTickLabels(axis){var opts=axis.options,ticks=axis.ticks||[],labelWidth=opts.labelWidth||0,labelHeight=opts.labelHeight||0,maxWidth=labelWidth||(axis.direction=="x"?Math.floor(surface.width/(ticks.length||1)):null),legacyStyles=axis.direction+"Axis "+axis.direction+axis.n+"Axis",layer="flot-"+axis.direction+"-axis flot-"+axis.direction+axis.n+"-axis "+legacyStyles,font=opts.font||"flot-tick-label tickLabel";for(var i=0;i<ticks.length;++i){var t=ticks[i];if(!t.label)continue;var info=surface.getTextInfo(layer,t.label,font,null,maxWidth);labelWidth=Math.max(labelWidth,info.width);labelHeight=Math.max(labelHeight,info.height)}axis.labelWidth=opts.labelWidth||labelWidth;axis.labelHeight=opts.labelHeight||labelHeight}function allocateAxisBoxFirstPhase(axis){var lw=axis.labelWidth,lh=axis.labelHeight,pos=axis.options.position,isXAxis=axis.direction==="x",tickLength=axis.options.tickLength,axisMargin=options.grid.axisMargin,padding=options.grid.labelMargin,innermost=true,outermost=true,first=true,found=false;$.each(isXAxis?xaxes:yaxes,function(i,a){if(a&&(a.show||a.reserveSpace)){if(a===axis){found=true}else if(a.options.position===pos){if(found){outermost=false}else{innermost=false}}if(!found){first=false}}});if(outermost){axisMargin=0}if(tickLength==null){tickLength=first?"full":5}if(!isNaN(+tickLength))padding+=+tickLength;if(isXAxis){lh+=padding;if(pos=="bottom"){plotOffset.bottom+=lh+axisMargin;axis.box={top:surface.height-plotOffset.bottom,height:lh}}else{axis.box={top:plotOffset.top+axisMargin,height:lh};plotOffset.top+=lh+axisMargin}}else{lw+=padding;if(pos=="left"){axis.box={left:plotOffset.left+axisMargin,width:lw};plotOffset.left+=lw+axisMargin}else{plotOffset.right+=lw+axisMargin;axis.box={left:surface.width-plotOffset.right,width:lw}}}axis.position=pos;axis.tickLength=tickLength;axis.box.padding=padding;axis.innermost=innermost}function allocateAxisBoxSecondPhase(axis){if(axis.direction=="x"){axis.box.left=plotOffset.left-axis.labelWidth/2;axis.box.width=surface.width-plotOffset.left-plotOffset.right+axis.labelWidth}else{axis.box.top=plotOffset.top-axis.labelHeight/2;axis.box.height=surface.height-plotOffset.bottom-plotOffset.top+axis.labelHeight}}function adjustLayoutForThingsStickingOut(){var minMargin=options.grid.minBorderMargin,axis,i;if(minMargin==null){minMargin=0;for(i=0;i<series.length;++i)minMargin=Math.max(minMargin,2*(series[i].points.radius+series[i].points.lineWidth/2))}var margins={left:minMargin,right:minMargin,top:minMargin,bottom:minMargin};$.each(allAxes(),function(_,axis){if(axis.reserveSpace&&axis.ticks&&axis.ticks.length){if(axis.direction==="x"){margins.left=Math.max(margins.left,axis.labelWidth/2);margins.right=Math.max(margins.right,axis.labelWidth/2)}else{margins.bottom=Math.max(margins.bottom,axis.labelHeight/2);margins.top=Math.max(margins.top,axis.labelHeight/2)}}});plotOffset.left=Math.ceil(Math.max(margins.left,plotOffset.left));plotOffset.right=Math.ceil(Math.max(margins.right,plotOffset.right));plotOffset.top=Math.ceil(Math.max(margins.top,plotOffset.top));plotOffset.bottom=Math.ceil(Math.max(margins.bottom,plotOffset.bottom))}function setupGrid(){var i,axes=allAxes(),showGrid=options.grid.show;for(var a in plotOffset){var margin=options.grid.margin||0;plotOffset[a]=typeof margin=="number"?margin:margin[a]||0}executeHooks(hooks.processOffset,[plotOffset]);for(var a in plotOffset){if(typeof options.grid.borderWidth=="object"){plotOffset[a]+=showGrid?options.grid.borderWidth[a]:0}else{plotOffset[a]+=showGrid?options.grid.borderWidth:0}}$.each(axes,function(_,axis){var axisOpts=axis.options;axis.show=axisOpts.show==null?axis.used:axisOpts.show;axis.reserveSpace=axisOpts.reserveSpace==null?axis.show:axisOpts.reserveSpace;setRange(axis)});if(showGrid){var allocatedAxes=$.grep(axes,function(axis){return axis.show||axis.reserveSpace});$.each(allocatedAxes,function(_,axis){setupTickGeneration(axis);setTicks(axis);snapRangeToTicks(axis,axis.ticks);measureTickLabels(axis)});for(i=allocatedAxes.length-1;i>=0;--i)allocateAxisBoxFirstPhase(allocatedAxes[i]);adjustLayoutForThingsStickingOut();$.each(allocatedAxes,function(_,axis){allocateAxisBoxSecondPhase(axis)})}plotWidth=surface.width-plotOffset.left-plotOffset.right;plotHeight=surface.height-plotOffset.bottom-plotOffset.top;$.each(axes,function(_,axis){setTransformationHelpers(axis)});if(showGrid){drawAxisLabels()}insertLegend()}function setRange(axis){var opts=axis.options,min=+(opts.min!=null?opts.min:axis.datamin),max=+(opts.max!=null?opts.max:axis.datamax),delta=max-min;if(delta==0){var widen=max==0?1:.01;if(opts.min==null)min-=widen;if(opts.max==null||opts.min!=null)max+=widen}else{var margin=opts.autoscaleMargin;if(margin!=null){if(opts.min==null){min-=delta*margin;if(min<0&&axis.datamin!=null&&axis.datamin>=0)min=0}if(opts.max==null){max+=delta*margin;if(max>0&&axis.datamax!=null&&axis.datamax<=0)max=0}}}axis.min=min;axis.max=max}function setupTickGeneration(axis){var opts=axis.options;var noTicks;if(typeof opts.ticks=="number"&&opts.ticks>0)noTicks=opts.ticks;else noTicks=.3*Math.sqrt(axis.direction=="x"?surface.width:surface.height);var delta=(axis.max-axis.min)/noTicks,dec=-Math.floor(Math.log(delta)/Math.LN10),maxDec=opts.tickDecimals;if(maxDec!=null&&dec>maxDec){dec=maxDec}var magn=Math.pow(10,-dec),norm=delta/magn,size;if(norm<1.5){size=1}else if(norm<3){size=2;if(norm>2.25&&(maxDec==null||dec+1<=maxDec)){size=2.5;++dec}}else if(norm<7.5){size=5}else{size=10}size*=magn;if(opts.minTickSize!=null&&size<opts.minTickSize){size=opts.minTickSize}axis.delta=delta;axis.tickDecimals=Math.max(0,maxDec!=null?maxDec:dec);axis.tickSize=opts.tickSize||size;if(opts.mode=="time"&&!axis.tickGenerator){throw new Error("Time mode requires the flot.time plugin.")}if(!axis.tickGenerator){axis.tickGenerator=function(axis){var ticks=[],start=floorInBase(axis.min,axis.tickSize),i=0,v=Number.NaN,prev;do{prev=v;v=start+i*axis.tickSize;ticks.push(v);++i}while(v<axis.max&&v!=prev);return ticks};axis.tickFormatter=function(value,axis){var factor=axis.tickDecimals?Math.pow(10,axis.tickDecimals):1;var formatted=""+Math.round(value*factor)/factor;if(axis.tickDecimals!=null){var decimal=formatted.indexOf(".");var precision=decimal==-1?0:formatted.length-decimal-1;if(precision<axis.tickDecimals){return(precision?formatted:formatted+".")+(""+factor).substr(1,axis.tickDecimals-precision)}}return formatted}}if($.isFunction(opts.tickFormatter))axis.tickFormatter=function(v,axis){return""+opts.tickFormatter(v,axis)};if(opts.alignTicksWithAxis!=null){var otherAxis=(axis.direction=="x"?xaxes:yaxes)[opts.alignTicksWithAxis-1];if(otherAxis&&otherAxis.used&&otherAxis!=axis){var niceTicks=axis.tickGenerator(axis);if(niceTicks.length>0){if(opts.min==null)axis.min=Math.min(axis.min,niceTicks[0]);if(opts.max==null&&niceTicks.length>1)axis.max=Math.max(axis.max,niceTicks[niceTicks.length-1])}axis.tickGenerator=function(axis){var ticks=[],v,i;for(i=0;i<otherAxis.ticks.length;++i){v=(otherAxis.ticks[i].v-otherAxis.min)/(otherAxis.max-otherAxis.min);v=axis.min+v*(axis.max-axis.min);ticks.push(v)}return ticks};if(!axis.mode&&opts.tickDecimals==null){var extraDec=Math.max(0,-Math.floor(Math.log(axis.delta)/Math.LN10)+1),ts=axis.tickGenerator(axis);if(!(ts.length>1&&/\..*0$/.test((ts[1]-ts[0]).toFixed(extraDec))))axis.tickDecimals=extraDec}}}}function setTicks(axis){var oticks=axis.options.ticks,ticks=[];if(oticks==null||typeof oticks=="number"&&oticks>0)ticks=axis.tickGenerator(axis);else if(oticks){if($.isFunction(oticks))ticks=oticks(axis);else ticks=oticks}var i,v;axis.ticks=[];for(i=0;i<ticks.length;++i){var label=null;var t=ticks[i];if(typeof t=="object"){v=+t[0];if(t.length>1)label=t[1]}else v=+t;if(label==null)label=axis.tickFormatter(v,axis);if(!isNaN(v))axis.ticks.push({v:v,label:label})}}function snapRangeToTicks(axis,ticks){if(axis.options.autoscaleMargin&&ticks.length>0){if(axis.options.min==null)axis.min=Math.min(axis.min,ticks[0].v);if(axis.options.max==null&&ticks.length>1)axis.max=Math.max(axis.max,ticks[ticks.length-1].v)}}function draw(){surface.clear();executeHooks(hooks.drawBackground,[ctx]);var grid=options.grid;if(grid.show&&grid.backgroundColor)drawBackground();if(grid.show&&!grid.aboveData){drawGrid()}for(var i=0;i<series.length;++i){executeHooks(hooks.drawSeries,[ctx,series[i]]);drawSeries(series[i])}executeHooks(hooks.draw,[ctx]);if(grid.show&&grid.aboveData){drawGrid()}surface.render();triggerRedrawOverlay()}function extractRange(ranges,coord){var axis,from,to,key,axes=allAxes();for(var i=0;i<axes.length;++i){axis=axes[i];if(axis.direction==coord){key=coord+axis.n+"axis";if(!ranges[key]&&axis.n==1)key=coord+"axis";if(ranges[key]){from=ranges[key].from;to=ranges[key].to;break}}}if(!ranges[key]){axis=coord=="x"?xaxes[0]:yaxes[0];from=ranges[coord+"1"];to=ranges[coord+"2"]}if(from!=null&&to!=null&&from>to){var tmp=from;from=to;to=tmp}return{from:from,to:to,axis:axis}}function drawBackground(){ctx.save();ctx.translate(plotOffset.left,plotOffset.top);ctx.fillStyle=getColorOrGradient(options.grid.backgroundColor,plotHeight,0,"rgba(255, 255, 255, 0)");ctx.fillRect(0,0,plotWidth,plotHeight);ctx.restore()}function drawGrid(){var i,axes,bw,bc;ctx.save();ctx.translate(plotOffset.left,plotOffset.top);var markings=options.grid.markings;if(markings){if($.isFunction(markings)){axes=plot.getAxes();axes.xmin=axes.xaxis.min;axes.xmax=axes.xaxis.max;axes.ymin=axes.yaxis.min;axes.ymax=axes.yaxis.max;markings=markings(axes)}for(i=0;i<markings.length;++i){var m=markings[i],xrange=extractRange(m,"x"),yrange=extractRange(m,"y");if(xrange.from==null)xrange.from=xrange.axis.min;if(xrange.to==null)xrange.to=xrange.axis.max;+if(yrange.from==null)yrange.from=yrange.axis.min;if(yrange.to==null)yrange.to=yrange.axis.max;if(xrange.to<xrange.axis.min||xrange.from>xrange.axis.max||yrange.to<yrange.axis.min||yrange.from>yrange.axis.max)continue;xrange.from=Math.max(xrange.from,xrange.axis.min);xrange.to=Math.min(xrange.to,xrange.axis.max);yrange.from=Math.max(yrange.from,yrange.axis.min);yrange.to=Math.min(yrange.to,yrange.axis.max);var xequal=xrange.from===xrange.to,yequal=yrange.from===yrange.to;if(xequal&&yequal){continue}xrange.from=Math.floor(xrange.axis.p2c(xrange.from));xrange.to=Math.floor(xrange.axis.p2c(xrange.to));yrange.from=Math.floor(yrange.axis.p2c(yrange.from));yrange.to=Math.floor(yrange.axis.p2c(yrange.to));if(xequal||yequal){var lineWidth=m.lineWidth||options.grid.markingsLineWidth,subPixel=lineWidth%2?.5:0;ctx.beginPath();ctx.strokeStyle=m.color||options.grid.markingsColor;ctx.lineWidth=lineWidth;if(xequal){ctx.moveTo(xrange.to+subPixel,yrange.from);ctx.lineTo(xrange.to+subPixel,yrange.to)}else{ctx.moveTo(xrange.from,yrange.to+subPixel);ctx.lineTo(xrange.to,yrange.to+subPixel)}ctx.stroke()}else{ctx.fillStyle=m.color||options.grid.markingsColor;ctx.fillRect(xrange.from,yrange.to,xrange.to-xrange.from,yrange.from-yrange.to)}}}axes=allAxes();bw=options.grid.borderWidth;for(var j=0;j<axes.length;++j){var axis=axes[j],box=axis.box,t=axis.tickLength,x,y,xoff,yoff;if(!axis.show||axis.ticks.length==0)continue;ctx.lineWidth=1;if(axis.direction=="x"){x=0;if(t=="full")y=axis.position=="top"?0:plotHeight;else y=box.top-plotOffset.top+(axis.position=="top"?box.height:0)}else{y=0;if(t=="full")x=axis.position=="left"?0:plotWidth;else x=box.left-plotOffset.left+(axis.position=="left"?box.width:0)}if(!axis.innermost){ctx.strokeStyle=axis.options.color;ctx.beginPath();xoff=yoff=0;if(axis.direction=="x")xoff=plotWidth+1;else yoff=plotHeight+1;if(ctx.lineWidth==1){if(axis.direction=="x"){y=Math.floor(y)+.5}else{x=Math.floor(x)+.5}}ctx.moveTo(x,y);ctx.lineTo(x+xoff,y+yoff);ctx.stroke()}ctx.strokeStyle=axis.options.tickColor;ctx.beginPath();for(i=0;i<axis.ticks.length;++i){var v=axis.ticks[i].v;xoff=yoff=0;if(isNaN(v)||v<axis.min||v>axis.max||t=="full"&&(typeof bw=="object"&&bw[axis.position]>0||bw>0)&&(v==axis.min||v==axis.max))continue;if(axis.direction=="x"){x=axis.p2c(v);yoff=t=="full"?-plotHeight:t;if(axis.position=="top")yoff=-yoff}else{y=axis.p2c(v);xoff=t=="full"?-plotWidth:t;if(axis.position=="left")xoff=-xoff}if(ctx.lineWidth==1){if(axis.direction=="x")x=Math.floor(x)+.5;else y=Math.floor(y)+.5}ctx.moveTo(x,y);ctx.lineTo(x+xoff,y+yoff)}ctx.stroke()}if(bw){bc=options.grid.borderColor;if(typeof bw=="object"||typeof bc=="object"){if(typeof bw!=="object"){bw={top:bw,right:bw,bottom:bw,left:bw}}if(typeof bc!=="object"){bc={top:bc,right:bc,bottom:bc,left:bc}}if(bw.top>0){ctx.strokeStyle=bc.top;ctx.lineWidth=bw.top;ctx.beginPath();ctx.moveTo(0-bw.left,0-bw.top/2);ctx.lineTo(plotWidth,0-bw.top/2);ctx.stroke()}if(bw.right>0){ctx.strokeStyle=bc.right;ctx.lineWidth=bw.right;ctx.beginPath();ctx.moveTo(plotWidth+bw.right/2,0-bw.top);ctx.lineTo(plotWidth+bw.right/2,plotHeight);ctx.stroke()}if(bw.bottom>0){ctx.strokeStyle=bc.bottom;ctx.lineWidth=bw.bottom;ctx.beginPath();ctx.moveTo(plotWidth+bw.right,plotHeight+bw.bottom/2);ctx.lineTo(0,plotHeight+bw.bottom/2);ctx.stroke()}if(bw.left>0){ctx.strokeStyle=bc.left;ctx.lineWidth=bw.left;ctx.beginPath();ctx.moveTo(0-bw.left/2,plotHeight+bw.bottom);ctx.lineTo(0-bw.left/2,0);ctx.stroke()}}else{ctx.lineWidth=bw;ctx.strokeStyle=options.grid.borderColor;ctx.strokeRect(-bw/2,-bw/2,plotWidth+bw,plotHeight+bw)}}ctx.restore()}function drawAxisLabels(){$.each(allAxes(),function(_,axis){var box=axis.box,legacyStyles=axis.direction+"Axis "+axis.direction+axis.n+"Axis",layer="flot-"+axis.direction+"-axis flot-"+axis.direction+axis.n+"-axis "+legacyStyles,font=axis.options.font||"flot-tick-label tickLabel",tick,x,y,halign,valign;surface.removeText(layer);if(!axis.show||axis.ticks.length==0)return;for(var i=0;i<axis.ticks.length;++i){tick=axis.ticks[i];if(!tick.label||tick.v<axis.min||tick.v>axis.max)continue;if(axis.direction=="x"){halign="center";x=plotOffset.left+axis.p2c(tick.v);if(axis.position=="bottom"){y=box.top+box.padding}else{y=box.top+box.height-box.padding;valign="bottom"}}else{valign="middle";y=plotOffset.top+axis.p2c(tick.v);if(axis.position=="left"){x=box.left+box.width-box.padding;halign="right"}else{x=box.left+box.padding}}surface.addText(layer,x,y,tick.label,font,null,null,halign,valign)}})}function drawSeries(series){if(series.lines.show)drawSeriesLines(series);if(series.bars.show)drawSeriesBars(series);if(series.points.show)drawSeriesPoints(series)}function drawSeriesLines(series){function plotLine(datapoints,xoffset,yoffset,axisx,axisy){var points=datapoints.points,ps=datapoints.pointsize,prevx=null,prevy=null;ctx.beginPath();for(var i=ps;i<points.length;i+=ps){var x1=points[i-ps],y1=points[i-ps+1],x2=points[i],y2=points[i+1];if(x1==null||x2==null)continue;if(y1<=y2&&y1<axisy.min){if(y2<axisy.min)continue;x1=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.min}else if(y2<=y1&&y2<axisy.min){if(y1<axisy.min)continue;x2=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.min}if(y1>=y2&&y1>axisy.max){if(y2>axisy.max)continue;x1=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.max}else if(y2>=y1&&y2>axisy.max){if(y1>axisy.max)continue;x2=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.max}if(x1<=x2&&x1<axisx.min){if(x2<axisx.min)continue;y1=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.min}else if(x2<=x1&&x2<axisx.min){if(x1<axisx.min)continue;y2=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.min}if(x1>=x2&&x1>axisx.max){if(x2>axisx.max)continue;y1=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.max}else if(x2>=x1&&x2>axisx.max){if(x1>axisx.max)continue;y2=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.max}if(x1!=prevx||y1!=prevy)ctx.moveTo(axisx.p2c(x1)+xoffset,axisy.p2c(y1)+yoffset);prevx=x2;prevy=y2;ctx.lineTo(axisx.p2c(x2)+xoffset,axisy.p2c(y2)+yoffset)}ctx.stroke()}function plotLineArea(datapoints,axisx,axisy){var points=datapoints.points,ps=datapoints.pointsize,bottom=Math.min(Math.max(0,axisy.min),axisy.max),i=0,top,areaOpen=false,ypos=1,segmentStart=0,segmentEnd=0;while(true){if(ps>0&&i>points.length+ps)break;i+=ps;var x1=points[i-ps],y1=points[i-ps+ypos],x2=points[i],y2=points[i+ypos];if(areaOpen){if(ps>0&&x1!=null&&x2==null){segmentEnd=i;ps=-ps;ypos=2;continue}if(ps<0&&i==segmentStart+ps){ctx.fill();areaOpen=false;ps=-ps;ypos=1;i=segmentStart=segmentEnd+ps;continue}}if(x1==null||x2==null)continue;if(x1<=x2&&x1<axisx.min){if(x2<axisx.min)continue;y1=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.min}else if(x2<=x1&&x2<axisx.min){if(x1<axisx.min)continue;y2=(axisx.min-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.min}if(x1>=x2&&x1>axisx.max){if(x2>axisx.max)continue;y1=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x1=axisx.max}else if(x2>=x1&&x2>axisx.max){if(x1>axisx.max)continue;y2=(axisx.max-x1)/(x2-x1)*(y2-y1)+y1;x2=axisx.max}if(!areaOpen){ctx.beginPath();ctx.moveTo(axisx.p2c(x1),axisy.p2c(bottom));areaOpen=true}if(y1>=axisy.max&&y2>=axisy.max){ctx.lineTo(axisx.p2c(x1),axisy.p2c(axisy.max));ctx.lineTo(axisx.p2c(x2),axisy.p2c(axisy.max));continue}else if(y1<=axisy.min&&y2<=axisy.min){ctx.lineTo(axisx.p2c(x1),axisy.p2c(axisy.min));ctx.lineTo(axisx.p2c(x2),axisy.p2c(axisy.min));continue}var x1old=x1,x2old=x2;if(y1<=y2&&y1<axisy.min&&y2>=axisy.min){x1=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.min}else if(y2<=y1&&y2<axisy.min&&y1>=axisy.min){x2=(axisy.min-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.min}if(y1>=y2&&y1>axisy.max&&y2<=axisy.max){x1=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y1=axisy.max}else if(y2>=y1&&y2>axisy.max&&y1<=axisy.max){x2=(axisy.max-y1)/(y2-y1)*(x2-x1)+x1;y2=axisy.max}if(x1!=x1old){ctx.lineTo(axisx.p2c(x1old),axisy.p2c(y1))}ctx.lineTo(axisx.p2c(x1),axisy.p2c(y1));ctx.lineTo(axisx.p2c(x2),axisy.p2c(y2));if(x2!=x2old){ctx.lineTo(axisx.p2c(x2),axisy.p2c(y2));ctx.lineTo(axisx.p2c(x2old),axisy.p2c(y2))}}}ctx.save();ctx.translate(plotOffset.left,plotOffset.top);ctx.lineJoin="round";var lw=series.lines.lineWidth,sw=series.shadowSize;if(lw>0&&sw>0){ctx.lineWidth=sw;ctx.strokeStyle="rgba(0,0,0,0.1)";var angle=Math.PI/18;plotLine(series.datapoints,Math.sin(angle)*(lw/2+sw/2),Math.cos(angle)*(lw/2+sw/2),series.xaxis,series.yaxis);ctx.lineWidth=sw/2;plotLine(series.datapoints,Math.sin(angle)*(lw/2+sw/4),Math.cos(angle)*(lw/2+sw/4),series.xaxis,series.yaxis)}ctx.lineWidth=lw;ctx.strokeStyle=series.color;var fillStyle=getFillStyle(series.lines,series.color,0,plotHeight);if(fillStyle){ctx.fillStyle=fillStyle;plotLineArea(series.datapoints,series.xaxis,series.yaxis)}if(lw>0)plotLine(series.datapoints,0,0,series.xaxis,series.yaxis);ctx.restore()}function drawSeriesPoints(series){function plotPoints(datapoints,radius,fillStyle,offset,shadow,axisx,axisy,symbol){var points=datapoints.points,ps=datapoints.pointsize;for(var i=0;i<points.length;i+=ps){var x=points[i],y=points[i+1];if(x==null||x<axisx.min||x>axisx.max||y<axisy.min||y>axisy.max)continue;ctx.beginPath();x=axisx.p2c(x);y=axisy.p2c(y)+offset;if(symbol=="circle")ctx.arc(x,y,radius,0,shadow?Math.PI:Math.PI*2,false);else symbol(ctx,x,y,radius,shadow);ctx.closePath();if(fillStyle){ctx.fillStyle=fillStyle;ctx.fill()}ctx.stroke()}}ctx.save();ctx.translate(plotOffset.left,plotOffset.top);var lw=series.points.lineWidth,sw=series.shadowSize,radius=series.points.radius,symbol=series.points.symbol;if(lw==0)lw=1e-4;if(lw>0&&sw>0){var w=sw/2;ctx.lineWidth=w;ctx.strokeStyle="rgba(0,0,0,0.1)";plotPoints(series.datapoints,radius,null,w+w/2,true,series.xaxis,series.yaxis,symbol);ctx.strokeStyle="rgba(0,0,0,0.2)";plotPoints(series.datapoints,radius,null,w/2,true,series.xaxis,series.yaxis,symbol)}ctx.lineWidth=lw;ctx.strokeStyle=series.color;plotPoints(series.datapoints,radius,getFillStyle(series.points,series.color),0,false,series.xaxis,series.yaxis,symbol);ctx.restore()}function drawBar(x,y,b,barLeft,barRight,fillStyleCallback,axisx,axisy,c,horizontal,lineWidth){var left,right,bottom,top,drawLeft,drawRight,drawTop,drawBottom,tmp;if(horizontal){drawBottom=drawRight=drawTop=true;drawLeft=false;left=b;right=x;top=y+barLeft;bottom=y+barRight;if(right<left){tmp=right;right=left;left=tmp;drawLeft=true;drawRight=false}}else{drawLeft=drawRight=drawTop=true;drawBottom=false;left=x+barLeft;right=x+barRight;bottom=b;top=y;if(top<bottom){tmp=top;top=bottom;bottom=tmp;drawBottom=true;drawTop=false}}if(right<axisx.min||left>axisx.max||top<axisy.min||bottom>axisy.max)return;if(left<axisx.min){left=axisx.min;drawLeft=false}if(right>axisx.max){right=axisx.max;drawRight=false}if(bottom<axisy.min){bottom=axisy.min;drawBottom=false}if(top>axisy.max){top=axisy.max;drawTop=false}left=axisx.p2c(left);bottom=axisy.p2c(bottom);right=axisx.p2c(right);top=axisy.p2c(top);if(fillStyleCallback){c.fillStyle=fillStyleCallback(bottom,top);c.fillRect(left,top,right-left,bottom-top)}if(lineWidth>0&&(drawLeft||drawRight||drawTop||drawBottom)){c.beginPath();c.moveTo(left,bottom);if(drawLeft)c.lineTo(left,top);else c.moveTo(left,top);if(drawTop)c.lineTo(right,top);else c.moveTo(right,top);if(drawRight)c.lineTo(right,bottom);else c.moveTo(right,bottom);if(drawBottom)c.lineTo(left,bottom);else c.moveTo(left,bottom);c.stroke()}}function drawSeriesBars(series){function plotBars(datapoints,barLeft,barRight,fillStyleCallback,axisx,axisy){var points=datapoints.points,ps=datapoints.pointsize;for(var i=0;i<points.length;i+=ps){if(points[i]==null)continue;drawBar(points[i],points[i+1],points[i+2],barLeft,barRight,fillStyleCallback,axisx,axisy,ctx,series.bars.horizontal,series.bars.lineWidth)}}ctx.save();ctx.translate(plotOffset.left,plotOffset.top);ctx.lineWidth=series.bars.lineWidth;ctx.strokeStyle=series.color;var barLeft;switch(series.bars.align){case"left":barLeft=0;break;case"right":barLeft=-series.bars.barWidth;break;default:barLeft=-series.bars.barWidth/2}var fillStyleCallback=series.bars.fill?function(bottom,top){return getFillStyle(series.bars,series.color,bottom,top)}:null;plotBars(series.datapoints,barLeft,barLeft+series.bars.barWidth,fillStyleCallback,series.xaxis,series.yaxis);ctx.restore()}function getFillStyle(filloptions,seriesColor,bottom,top){var fill=filloptions.fill;if(!fill)return null;if(filloptions.fillColor)return getColorOrGradient(filloptions.fillColor,bottom,top,seriesColor);var c=$.color.parse(seriesColor);c.a=typeof fill=="number"?fill:.4;c.normalize();return c.toString()}function insertLegend(){if(options.legend.container!=null){$(options.legend.container).html("")}else{placeholder.find(".legend").remove()}if(!options.legend.show){return}var fragments=[],entries=[],rowStarted=false,lf=options.legend.labelFormatter,s,label;for(var i=0;i<series.length;++i){s=series[i];if(s.label){label=lf?lf(s.label,s):s.label;if(label){entries.push({label:label,color:s.color})}}}if(options.legend.sorted){if($.isFunction(options.legend.sorted)){entries.sort(options.legend.sorted)}else if(options.legend.sorted=="reverse"){entries.reverse()}else{var ascending=options.legend.sorted!="descending";entries.sort(function(a,b){return a.label==b.label?0:a.label<b.label!=ascending?1:-1})}}for(var i=0;i<entries.length;++i){var entry=entries[i];if(i%options.legend.noColumns==0){if(rowStarted)fragments.push("</tr>");fragments.push("<tr>");rowStarted=true}fragments.push('<td class="legendColorBox"><div style="border:1px solid '+options.legend.labelBoxBorderColor+';padding:1px"><div style="width:4px;height:0;border:5px solid '+entry.color+';overflow:hidden"></div></div></td>'+'<td class="legendLabel">'+entry.label+"</td>")}if(rowStarted)fragments.push("</tr>");if(fragments.length==0)return;var table='<table style="font-size:smaller;color:'+options.grid.color+'">'+fragments.join("")+"</table>";if(options.legend.container!=null)$(options.legend.container).html(table);else{var pos="",p=options.legend.position,m=options.legend.margin;if(m[0]==null)m=[m,m];if(p.charAt(0)=="n")pos+="top:"+(m[1]+plotOffset.top)+"px;";else if(p.charAt(0)=="s")pos+="bottom:"+(m[1]+plotOffset.bottom)+"px;";if(p.charAt(1)=="e")pos+="right:"+(m[0]+plotOffset.right)+"px;";else if(p.charAt(1)=="w")pos+="left:"+(m[0]+plotOffset.left)+"px;";var legend=$('<div class="legend">'+table.replace('style="','style="position:absolute;'+pos+";")+"</div>").appendTo(placeholder);if(options.legend.backgroundOpacity!=0){var c=options.legend.backgroundColor;if(c==null){c=options.grid.backgroundColor;if(c&&typeof c=="string")c=$.color.parse(c);else c=$.color.extract(legend,"background-color");c.a=1;c=c.toString()}var div=legend.children();$('<div style="position:absolute;width:'+div.width()+"px;height:"+div.height()+"px;"+pos+"background-color:"+c+';"> </div>').prependTo(legend).css("opacity",options.legend.backgroundOpacity)}}}var highlights=[],redrawTimeout=null;function findNearbyItem(mouseX,mouseY,seriesFilter){var maxDistance=options.grid.mouseActiveRadius,smallestDistance=maxDistance*maxDistance+1,item=null,foundPoint=false,i,j,ps;for(i=series.length-1;i>=0;--i){if(!seriesFilter(series[i]))continue;var s=series[i],axisx=s.xaxis,axisy=s.yaxis,points=s.datapoints.points,mx=axisx.c2p(mouseX),my=axisy.c2p(mouseY),maxx=maxDistance/axisx.scale,maxy=maxDistance/axisy.scale;ps=s.datapoints.pointsize;if(axisx.options.inverseTransform)maxx=Number.MAX_VALUE;if(axisy.options.inverseTransform)maxy=Number.MAX_VALUE;if(s.lines.show||s.points.show){for(j=0;j<points.length;j+=ps){var x=points[j],y=points[j+1];if(x==null)continue;if(x-mx>maxx||x-mx<-maxx||y-my>maxy||y-my<-maxy)continue;var dx=Math.abs(axisx.p2c(x)-mouseX),dy=Math.abs(axisy.p2c(y)-mouseY),dist=dx*dx+dy*dy;if(dist<smallestDistance){smallestDistance=dist;item=[i,j/ps]}}}if(s.bars.show&&!item){var barLeft,barRight;switch(s.bars.align){case"left":barLeft=0;break;case"right":barLeft=-s.bars.barWidth;break;default:barLeft=-s.bars.barWidth/2}barRight=barLeft+s.bars.barWidth;for(j=0;j<points.length;j+=ps){var x=points[j],y=points[j+1],b=points[j+2];if(x==null)continue;if(series[i].bars.horizontal?mx<=Math.max(b,x)&&mx>=Math.min(b,x)&&my>=y+barLeft&&my<=y+barRight:mx>=x+barLeft&&mx<=x+barRight&&my>=Math.min(b,y)&&my<=Math.max(b,y))item=[i,j/ps]}}}if(item){i=item[0];j=item[1];ps=series[i].datapoints.pointsize;return{datapoint:series[i].datapoints.points.slice(j*ps,(j+1)*ps),dataIndex:j,series:series[i],seriesIndex:i}}return null}function onMouseMove(e){if(options.grid.hoverable)triggerClickHoverEvent("plothover",e,function(s){return s["hoverable"]!=false})}function onMouseLeave(e){if(options.grid.hoverable)triggerClickHoverEvent("plothover",e,function(s){return false})}function onClick(e){triggerClickHoverEvent("plotclick",e,function(s){return s["clickable"]!=false})}function triggerClickHoverEvent(eventname,event,seriesFilter){var offset=eventHolder.offset(),canvasX=event.pageX-offset.left-plotOffset.left,canvasY=event.pageY-offset.top-plotOffset.top,pos=canvasToAxisCoords({left:canvasX,top:canvasY});pos.pageX=event.pageX;pos.pageY=event.pageY;var item=findNearbyItem(canvasX,canvasY,seriesFilter);if(item){item.pageX=parseInt(item.series.xaxis.p2c(item.datapoint[0])+offset.left+plotOffset.left,10);item.pageY=parseInt(item.series.yaxis.p2c(item.datapoint[1])+offset.top+plotOffset.top,10)}if(options.grid.autoHighlight){for(var i=0;i<highlights.length;++i){var h=highlights[i];if(h.auto==eventname&&!(item&&h.series==item.series&&h.point[0]==item.datapoint[0]&&h.point[1]==item.datapoint[1]))unhighlight(h.series,h.point)}if(item)highlight(item.series,item.datapoint,eventname)}placeholder.trigger(eventname,[pos,item])}function triggerRedrawOverlay(){var t=options.interaction.redrawOverlayInterval;if(t==-1){drawOverlay();return}if(!redrawTimeout)redrawTimeout=setTimeout(drawOverlay,t)}function drawOverlay(){redrawTimeout=null;octx.save();overlay.clear();octx.translate(plotOffset.left,plotOffset.top);var i,hi;for(i=0;i<highlights.length;++i){hi=highlights[i];if(hi.series.bars.show)drawBarHighlight(hi.series,hi.point);else drawPointHighlight(hi.series,hi.point)}octx.restore();executeHooks(hooks.drawOverlay,[octx])}function highlight(s,point,auto){if(typeof s=="number")s=series[s];if(typeof point=="number"){var ps=s.datapoints.pointsize;point=s.datapoints.points.slice(ps*point,ps*(point+1))}var i=indexOfHighlight(s,point);if(i==-1){highlights.push({series:s,point:point,auto:auto});triggerRedrawOverlay()}else if(!auto)highlights[i].auto=false}function unhighlight(s,point){if(s==null&&point==null){highlights=[];triggerRedrawOverlay();return}if(typeof s=="number")s=series[s];if(typeof point=="number"){var ps=s.datapoints.pointsize;point=s.datapoints.points.slice(ps*point,ps*(point+1))}var i=indexOfHighlight(s,point);if(i!=-1){highlights.splice(i,1);triggerRedrawOverlay()}}function indexOfHighlight(s,p){for(var i=0;i<highlights.length;++i){var h=highlights[i];if(h.series==s&&h.point[0]==p[0]&&h.point[1]==p[1])return i}return-1}function drawPointHighlight(series,point){var x=point[0],y=point[1],axisx=series.xaxis,axisy=series.yaxis,highlightColor=typeof series.highlightColor==="string"?series.highlightColor:$.color.parse(series.color).scale("a",.5).toString();if(x<axisx.min||x>axisx.max||y<axisy.min||y>axisy.max)return;var pointRadius=series.points.radius+series.points.lineWidth/2;octx.lineWidth=pointRadius;octx.strokeStyle=highlightColor;var radius=1.5*pointRadius;x=axisx.p2c(x);y=axisy.p2c(y);octx.beginPath();if(series.points.symbol=="circle")octx.arc(x,y,radius,0,2*Math.PI,false);else series.points.symbol(octx,x,y,radius,false);octx.closePath();octx.stroke()}function drawBarHighlight(series,point){var highlightColor=typeof series.highlightColor==="string"?series.highlightColor:$.color.parse(series.color).scale("a",.5).toString(),fillStyle=highlightColor,barLeft;switch(series.bars.align){case"left":barLeft=0;break;case"right":barLeft=-series.bars.barWidth;break;default:barLeft=-series.bars.barWidth/2}octx.lineWidth=series.bars.lineWidth;octx.strokeStyle=highlightColor;drawBar(point[0],point[1],point[2]||0,barLeft,barLeft+series.bars.barWidth,function(){return fillStyle},series.xaxis,series.yaxis,octx,series.bars.horizontal,series.bars.lineWidth)}function getColorOrGradient(spec,bottom,top,defaultColor){if(typeof spec=="string")return spec;else{var gradient=ctx.createLinearGradient(0,top,0,bottom);for(var i=0,l=spec.colors.length;i<l;++i){var c=spec.colors[i];if(typeof c!="string"){var co=$.color.parse(defaultColor);if(c.brightness!=null)co=co.scale("rgb",c.brightness);if(c.opacity!=null)co.a*=c.opacity;c=co.toString()}gradient.addColorStop(i/(l-1),c)}return gradient}}}$.plot=function(placeholder,data,options){var plot=new Plot($(placeholder),data,options,$.plot.plugins);return plot};$.plot.version="0.8.3";$.plot.plugins=[];$.fn.plot=function(data,options){return this.each(function(){$.plot(this,data,options)})};function floorInBase(n,base){return base*Math.floor(n/base)}})(jQuery);
+ templates/json.tpl view
@@ -0,0 +1,1 @@+{{json}}
− templates/report.tpl
@@ -1,229 +0,0 @@-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">-<html>- <head>- <meta http-equiv="Content-Type" content="text/html; charset=utf-8">- <title>criterion report</title>- <!--[if lte IE 8]>- <script language="javascript" type="text/javascript">- {{#include}}js/excanvas-r3.min.js{{/include}}- </script>- <![endif]-->- <script language="javascript" type="text/javascript">- {{#include}}js/jquery-1.6.4.min.js{{/include}}- </script>- <script language="javascript" type="text/javascript">- {{#include}}js/jquery.flot-0.7.min.js{{/include}}- </script>- <script language="javascript" type="text/javascript">- {{#include}}js/jquery.criterion.js{{/include}}- </script>- <style type="text/css">-{{#include}}criterion.css{{/include}}- </style>- <!--[if !IE 7]>- <style type="text/css">- #wrap {display:table;height:100%}- </style>- <![endif]-->- </head>- <body>- <div id="wrap">- <div id="main" class="body">- <h1>criterion performance measurements</h1>--<h2>overview</h2>--<p><a href="#grokularation">want to understand this report?</a></p>--<div id="overview" class="ovchart" style="width:900px;height:100px;"></div>--{{#report}}-<h2><a name="b{{number}}">{{name}}</a></h2>- <table width="100%">- <tbody>- <tr>- <td><div id="kde{{number}}" class="kdechart"- style="width:450px;height:278px;"></div></td>- <td><div id="time{{number}}" class="timechart"- style="width:450px;height:278px;"></div></td>- </tr>- </tbody>- </table>- <table>- <thead class="analysis">- <th></th>- <th class="cibound"- title="{{anMean.estConfidenceLevel}} confidence level">lower bound</th>- <th>estimate</th>- <th class="cibound"- title="{{anMean.estConfidenceLevel}} confidence level">upper bound</th>- </thead>- <tbody>- <tr>- <td>Mean execution time</td>- <td><span class="citime">{{anMean.estLowerBound}}</span></td>- <td><span class="time">{{anMean.estPoint}}</span></td>- <td><span class="citime">{{anMean.estUpperBound}}</span></td>- </tr>- <tr>- <td>Standard deviation</td>- <td><span class="citime">{{anStdDev.estLowerBound}}</span></td>- <td><span class="time">{{anStdDev.estPoint}}</span></td>- <td><span class="citime">{{anStdDev.estUpperBound}}</span></td>- </tr>- </tbody>- </table>-- <span class="outliers">- <p>Outlying measurements have {{anOutlierVar.ovDesc}}- (<span class="percent">{{anOutlierVar.ovFraction}}</span>%)- effect on estimated standard deviation.</p>- </span>-{{/report}}-- <h2><a name="grokularation">understanding this report</a></h2>-- <p>In this report, each function benchmarked by criterion is assigned- a section of its own. In each section, we display two charts, each- with an <i>x</i> axis that represents measured execution time.- These charts are active; if you hover your mouse over data points- and annotations, you will see more details.</p>-- <ul>- <li>The chart on the left is a- <a href="http://en.wikipedia.org/wiki/Kernel_density_estimation">kernel- density estimate</a> (also known as a KDE) of time- measurements. This graphs the probability of any given time- measurement occurring. A spike indicates that a measurement of a- particular time occurred; its height indicates how often that- measurement was repeated.</li>-- <li>The chart on the right is the raw data from which the kernel- density estimate is built. Measurements are displayed on- the <i>y</i> axis in the order in which they occurred.</li>- </ul>- - <p>Under the charts is a small table displaying the mean and standard- deviation of the measurements. We use a statistical technique- called- the <a href="http://en.wikipedia.org/wiki/Bootstrapping_(statistics)">bootstrap</a>- to provide confidence intervals on our estimates of these values.- The bootstrap-derived upper and lower bounds on the mean and- standard deviation let you see how accurate we believe those- estimates to be. (Hover the mouse over the table headers to see- the confidence levels.)</p>- - <p>A noisy benchmarking environment can cause some or many- measurements to fall far from the mean. These outlying- measurements can have a significant inflationary effect on the- estimate of the standard deviation. We calculate and display an- estimate of the extent to which the standard deviation has been- inflated by outliers.</p>--<script type="text/javascript">-$(function () {- function mangulate(number, name, mean, times, kdetimes, kdepdf) {- var meanSecs = mean;- var units = $.timeUnits(mean);- var scale = units[0];- units = units[1];- mean *= scale;- kdetimes = $.scaleBy(scale, kdetimes);- var ts = $.scaleBy(scale, times);- var kq = $("#kde" + number);- var k = $.plot(kq,- [{ label: name + " time densities",- data: $.zip(kdetimes, kdepdf),- }],- { xaxis: { tickFormatter: $.unitFormatter(units) },- yaxis: { ticks: false },- grid: { borderColor: "#777",- hoverable: true, markings: [ { color: '#6fd3fb',- lineWidth: 1.5, xaxis: { from: mean, to: mean } } ] },- });- var o = k.pointOffset({ x: mean, y: 0});- kq.append('<div class="meanlegend" title="' + $.renderTime(meanSecs) +- '" style="position:absolute;left:' + (o.left + 4) +- 'px;bottom:139px;">mean</div>');- var timepairs = new Array(ts.length);- for (var i = 0; i < ts.length; i++)- timepairs[i] = [ts[i],i];- $.plot($("#time" + number),- [{ label: name + " times",- data: timepairs }],- { points: { show: true },- grid: { borderColor: "#777", hoverable: true },- xaxis: { min: kdetimes[0], max: kdetimes[kdetimes.length-1],- tickFormatter: $.unitFormatter(units) },- yaxis: { ticks: false },- });- $.addTooltip("#kde" + number, function(x,y) { return x + ' ' + units; });- $.addTooltip("#time" + number, function(x,y) { return x + ' ' + units; });- };- {{#report}}- mangulate({{number}}, "{{name}}",- {{anMean.estPoint}},- [{{#times}}{{x}},{{/times}}],- [{{#kdetimes}}{{x}},{{/kdetimes}}],- [{{#kdepdf}}{{x}},{{/kdepdf}}]);- {{/report}}-- var benches = [{{#report}}"{{name}}",{{/report}}];- var ylabels = [{{#report}}[-{{number}},'<a href="#b{{number}}">{{name}}</a>'],{{/report}}];- var means = $.scaleTimes([{{#report}}{{anMean.estPoint}},{{/report}}]);- var xs = [];- var prev = null;- for (var i = 0; i < means[0].length; i++) {- var name = benches[i].split(/\//);- name.pop();- name = name.join('/');- if (name != prev) {- xs.push({ label: name, data: [[means[0][i], -i]]});- prev = name;- }- else- xs[xs.length-1].data.push([means[0][i],-i]);- }- var oq = $("#overview");- o = $.plot(oq, xs, { bars: { show: true, horizontal: true,- barWidth: 0.75, align: "center" },- grid: { borderColor: "#777", hoverable: true },- legend: { show: xs.length > 1 },- xaxis: { max: Math.max.apply(undefined,means[0]) * 1.02 },- yaxis: { ticks: ylabels, tickColor: '#ffffff' } });- if (benches.length > 3)- o.getPlaceholder().height(28*benches.length);- o.resize();- o.setupGrid();- o.draw();- $.addTooltip("#overview", function(x,y) { return x + ' ' + means[1]; });-});-$(document).ready(function () {- $(".time").text(function(_, text) {- return $.renderTime(text);- });- $(".citime").text(function(_, text) {- return $.renderTime(text);- });- $(".percent").text(function(_, text) {- return (text*100).toFixed(1);- });- });-</script>-- </div>- </div>- <div id="footer">- <div class="body">- <div class="footfirst">- <h2>colophon</h2>- <p>This report was created using the- <a href="http://hackage.haskell.org/package/criterion">criterion</a>- benchmark execution and performance analysis tool.</p>- <p>Criterion is developed and maintained- by <a href="http://www.serpentine.com/blog/">Bryan O'Sullivan</a>.</p>- </div>- </div>- </div>- </body>-</html>
+ tests/Sanity.hs view
@@ -0,0 +1,48 @@+{-# LANGUAGE ScopedTypeVariables #-}++import Criterion.Main (bench, bgroup, env, whnf)+import System.Environment (getEnv, withArgs)+import System.Timeout (timeout)+import Test.Framework (defaultMain)+import Test.Framework.Providers.HUnit (testCase)+import Test.HUnit (Assertion, assertFailure)+import qualified Criterion.Main as C+import qualified Control.Exception as E+import qualified Data.ByteString as B++fib :: Int -> Int+fib = sum . go+ where go 0 = [0]+ go 1 = [1]+ go n = go (n-1) ++ go (n-2)++sanity :: Assertion+sanity = do+ args <- getArgEnv+ withArgs args $ do+ let tooLong = 30+ wat <- timeout (tooLong * 1000000) $+ C.defaultMain [+ bgroup "fib" [+ bench "fib 10" $ whnf fib 10+ , bench "fib 22" $ whnf fib 22+ ]+ , env (return (replicate 1024 0)) $ \xs ->+ bgroup "length . filter" [+ bench "string" $ whnf (length . filter (==0)) xs+ , env (return (B.pack xs)) $ \bs ->+ bench "bytestring" $ whnf (B.length . B.filter (==0)) bs+ ]+ ]+ case wat of+ Just () -> return ()+ Nothing -> assertFailure $ "killed for running longer than " +++ show tooLong ++ " seconds!"++main :: IO ()+main = defaultMain [testCase "sanity" sanity]++getArgEnv :: IO [String]+getArgEnv =+ fmap words (getEnv "ARGS") `E.catch`+ \(_ :: E.SomeException) -> return []
+ tests/Tests.hs view
@@ -0,0 +1,8 @@+module Main (main) where++import Test.Framework (defaultMain)++import Properties++main :: IO ()+main = defaultMain [Properties.tests]