facebookresearch / tacto
Source Code Overview

Analysis scope, overview of main, test, generated, deployment, build, and other code.

Source Code Analysis Scope
Files includes and excluded from analyses
DAE
urdf
txt
obj
xacro
mtl
rviz
  • 16 extensions are included in analyses: py, DAE, urdf, yaml, txt, md, obj, yml, xml, xacro, mtl, gitignore, rviz, svg, sh, json
  • 4 criteria are used to exclude files from analysis:
    • exclude files with path like ".*/[.][a-zA-Z0-9_]+.*" (Hidden files and folders) (4 files).
    • exclude files with path like ".*/git[-]history[.]txt" (Git history) (1 file).
    • exclude files with path like ".*/git[-][a-zA-Z0-9_]+[.]txt" (Git data exports for sokrates analyses) (0 files).
    • exclude files with path like ".*[.]txt" (Text files) (5 files).
Overview of Analyzed Files
Basic stats on analyzed files
Intro
For analysis purposes we separate files in scope into several categories: main, test, generated, deployment and build, and other.

  • The main category contains all manually created source code files that are being used in the production.
  • Files in the main category are used as input for other analyses: logical decomposition, concerns, duplication, file size, unit size, and conditional complexity.
  • Test source code files are used only for testing of the product. These files are normally not deployed to production.
  • Build and deployment source code files are used to configure or support build and deployment process.
  • Generated source code files are automatically generated files that have not been manually changed after generation.
  • While a source code folder may contain a number of files, we are primarily interested in the source code files that are being written and maintained by developers.
  • Files containing binaries, documentation, or third-party libraries, for instance, are excluded from analysis. The exception are third-party libraries that have been changed by developers.

main6822 LOC (45%) 28 files
test83 LOC (<1%) 4 files
generated0 LOC (0%) 0 files
build and deployment0 LOC (0%) 0 files
other8140 LOC (54%) 41 files
Main Code
All manually created or maintained source code that defines logic of the product that is run in a production environment.
obj
urdf
mtl
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*".
  • 28 files match defined criteria (6,822 lines of code, 100.0% vs. main code):
    • 2 *.obj files (3,767 lines of code)
    • 15 *.py files (1,722 lines of code)
    • 7 *.urdf files (1,191 lines of code)
    • 3 *.yml files (132 lines of code)
    • 1 *.mtl files (10 lines of code)
  • " *.obj" is biggest, containing 55.22% of code.
  • " *.mtl" is smallest, containing 0.15% of code.


*.obj3767 LOC (55%) 2 files
*.py1722 LOC (25%) 15 files
*.urdf1191 LOC (17%) 7 files
*.yml132 LOC (1%) 3 files
*.mtl10 LOC (<1%) 1 files
Test Code
Used only for testing of the product. Normally not deployed in a production environment.
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*/[Tt]ests/.*".
    • files with paths like ".*/test_.*".
  • 4 files match defined criteria (83 lines of code, 1.2% vs. main code). All matches are in *.py files.


*.py83 LOC (100%) 4 files
Other Code
obj
urdf
xacro
mtl
Explore:   circles  |  sunburst
  • The following criteria are used to filter files:
    • files with paths like ".*[.]md".
    • files with paths like ".*/README[.][a-z0-9]+".
    • files with paths like ".*[.]txt".
    • files with paths like ".*/[.]gitignore".
    • files with paths like ".*/[Ee]xamples/.*".
    • files with paths like ".*[.](xml|xsd|robot|sql|pgsql|dashboard|profile|ipynb|raml|avsc|al)".
  • 41 files match defined criteria (8,140 lines of code, 119.3% vs. main code):
    • 2 *.obj files (3,767 lines of code)
    • 7 *.urdf files (2,447 lines of code)
    • 3 *.xacro files (917 lines of code)
    • 11 *.py files (543 lines of code)
    • 6 *.md files (177 lines of code)
    • 7 *.yaml files (173 lines of code)
    • 3 *.xml files (66 lines of code)
    • 1 *.sh files (40 lines of code)
    • 1 *.mtl files (10 lines of code)
  • " *.obj" is biggest, containing 46.28% of code.
  • " *.mtl" is smallest, containing 0.12% of code.


*.obj3767 LOC (46%) 2 files
*.urdf2447 LOC (30%) 7 files
*.xacro917 LOC (11%) 3 files
*.py543 LOC (6%) 11 files
*.md177 LOC (2%) 6 files
*.yaml173 LOC (2%) 7 files
*.xml66 LOC (<1%) 3 files
*.sh40 LOC (<1%) 1 files
*.mtl10 LOC (<1%) 1 files
Analyzers
Info about analyzers used for source code examinations.
  • *.obj files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.py files are analyzed with PythonAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • Unit size analysis
    • Conditional complexity analysis
    • Basic heuristic dependency analysis
  • *.urdf files are analyzed with XmlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.yml files are analyzed with YamlAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Advanced code cleaning (empty lines and comments removed for LOC calculations, additional cleaning for duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis
  • *.mtl files are analyzed with DefaultLanguageAnalyzer:
    • All basic standard analyses supported (source code overview, duplication, file size, concerns, findings, metrics, controls)
    • Basic code cleaning (empty lines removed for LOC calculations and duplication calculations)
    • No unit size analysis
    • No conditional complexity analysis
    • No dependency analysis


2022-01-25 20:05