Reporter > Getting started with UNICOM Intelligence Reporter > Opening a survey data file > Performance considerations when working with Quanvert projects
 
Performance considerations when working with Quanvert projects
UNICOM Intelligence Reporter Desktop Edition provides the functions for opening Quanvert project files (PKD). Unlike the Desktop Edition, the Server Edition is designed to move most processing to the server side. As a result, performance when opening PKD file might be impacted by numerous defined elements. It is necessary to understand when a PKD file can be used in UNICOM Intelligence Reporter Server Edition (with acceptable performance).
Determining when PKD performance is acceptable
The following script includes the CountElement() subroutine, which provides a short-cut for counting the number of elements that exist in a specific PKD file. The script passes the file Source.pkd, and generates a total element number count.
CountElement("Source.pkd")

Sub CountElement(PkdFileName)
  Dim MDM, DSC, DSCs, ElementCount, MDMField
  ' Create the Data source component Collection
  Set DSCs = CreateObject("MRDSCReg.Components")

  ' Find the Quanvert DSC
  Set DSC = DSCs["mrQvDsc"]
  ' Create an MDM Document from the Quanvert database
  Set MDM = DSC.Metadata.Open(PkdFileName)
  ElementCount = 0
  For each MDMField in MDM.Fields.Expanded
    ElementCount = ElementCount + MDMField.Categories.Count
  Next
  debug.log("There are " + CText(ElementCount) +
            " elements in PKD " + PkdFileName + ".")
End Sub
The following figure shows the UNICOM Intelligence Reporter Server Edition loading time trends when the element numbers increase.
The vertical axis is the time usage (in seconds); the horizontal axis is the element count. The figure is based on benchmark results from a server with the following specifications:
Hardware: Intel Core i7-3720QM CPU @2.6GHz, 2 GB memory
Software: Windows 2008 R2 64 bit, SQL Server 2008 R2, UNICOM Intelligence 6.0.1 FP3 with ECM00204364 optimization
As the figure illustrates, overall performance becomes increasingly unacceptable when the element count increases to more than 40,000.
Solution for increased PKD loading times
Using the metadata file (MDD) directly helps to improve performance when it is not possible to control the element count in a PKD file. The steps are as follows:
1 Generate an MDD file from the PKD file. There are several ways to generate an MDD file, such as opening the PKD file in UNICOM Intelligence MDM Explorer and saving as an *.mdd, or by using the script directly. For example, the following script imports the Source.pkd file with mrQvDsc then writes the metadata to the Output.mddfile.
Dim DSCs, DSC, MDM
' Create the Data source component Collection
Set DSCs = CreateObject("MRDSCReg.Components")
Set DSC = DSCs["mrQvDsc"]

' Create an MDM Document from the Quanvert database
Set MDM = DSC.Metadata.Open("Source.pkd")
MDM.Save("Output.mdd")
2 Create a project in UNICOM Intelligence Interviewer - Server Admin (with the type Analyze existing data), upload the MDD file as metadata, and specify the PKD file as the case data.
3 Open UNICOM Intelligence Reporter Server Edition from Interviewer Server Administration.
By employing this solution, the PKD loading times decrease, as is illustrated in the following figure.
See also
Opening a survey data file