facebookresearch / pytext
Components & Dependencies

An overview of source code logical components.

Intro

Logical decomposition is a representation of the organization of the main source code, where every and each file is put in exactly one logical component.

  • A software system can have one or more logical decompositions.
  • A logical decomposition can be defined in two ways in Sokrates.
  • First approach is based on the folders structure. Components are mapped to folders at defined folder depth relative to the source code root.
  • Second approach is based on explicit definition of each component. In such explicit definitions, components are explicitly named and their files are selected based on explicitly defined path and content filters.
  • A logical decomposition is considered invalid if a file is selected into two or more components.This constraint is introduced in order to facilitate measuring of dependencies among components.
  • Files not assigned to any component are put into a special "Unclassified" component.
Learn more...
Logical Decompositions Overview

Analyzed system has 1 logical decomposition:

  • primary (18 components)

Logical Decomposition #1: PRIMARY

The decompositions is based on the folder structure (relative to the source code root), with automatically defined folder depth to have at least 10 components.

Bubble Chart | Tree Map
Components
The "primary" logical decomposition has 18 components.
  • 321 files, 44,432 lines of code (100.0% vs. main code).
  • "pytext/models" is biggest, containing 31.64% of code.
  • "pytext/resources" is smallest, containing 0.03% of code.


pytext/models14057 LOC (31%) 123 files
pytext/data8027 LOC (18%) 40 files
pytext/torchscript3868 LOC (8%) 22 files
pytext/metric_reporters3321 LOC (7%) 21 files
pytext/legacy2443 LOC (5%) 20 files
pytext/optimizer2427 LOC (5%) 14 files
pytext/config1923 LOC (4%) 12 files
pytext/metrics1622 LOC (3%) 8 files
pytext/utils1454 LOC (3%) 23 files
pytext/task1346 LOC (3%) 8 files
pytext1161 LOC (2%) 4 files
pytext/loss853 LOC (1%) 5 files
pytext/trainers684 LOC (1%) 5 files
pytext/fields644 LOC (1%) 6 files
pytext/common303 LOC (<1%) 3 files
pytext/exporters263 LOC (<1%) 3 files
ROOT24 LOC (<1%) 2 files
pytext/resources12 LOC (<1%) 2 files
Dependencies
Dependencies among components are static code dependencies among files in different components.

No component dependencies found.



2022-01-25 19:35