aws / amazon-braket-ocean-plugin-python
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 27 units with 178 lines of code in units (40.0% of code).
    • 0 very long units (0 lines of code)
    • 0 long units (0 lines of code)
    • 2 medium size units (53 lines of code)
    • 3 small units (36 lines of code)
    • 22 very small units (89 lines of code)
0% | 0% | 29% | 20% | 50%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 0% | 29% | 20% | 50%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
src/braket/ocean_plugin0% | 0% | 29% | 20% | 50%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
def sample_qubo_quantum_task()
in src/braket/ocean_plugin/braket_sampler.py
32 9 5
def _result_to_response_hook()
in src/braket/ocean_plugin/braket_sampler.py
21 3 1
def parameters()
in src/braket/ocean_plugin/braket_dwave_sampler.py
13 4 1
def parameters()
in src/braket/ocean_plugin/braket_sampler.py
12 4 1
def _process_solver_kwargs()
in src/braket/ocean_plugin/braket_dwave_sampler.py
11 4 2
def _create_solver_kwargs()
in src/braket/ocean_plugin/braket_sampler.py
10 2 2
def properties()
in src/braket/ocean_plugin/braket_sampler.py
8 3 1
def properties()
in src/braket/ocean_plugin/braket_dwave_sampler.py
8 3 1
def __init__()
in src/braket/ocean_plugin/braket_sampler.py
6 1 5
def _access_optimized_edgelist()
in src/braket/ocean_plugin/braket_sampler.py
6 2 1
def __init__()
in src/braket/ocean_plugin/braket_dwave_sampler.py
6 1 5
def _vartype_from_problem_type()
in src/braket/ocean_plugin/braket_sampler.py
5 2 1
def edgelist()
in src/braket/ocean_plugin/braket_sampler.py
4 3 1
def sample_qubo()
in src/braket/ocean_plugin/braket_sampler.py
4 1 5
def _check_kwargs_solver()
in src/braket/ocean_plugin/braket_sampler.py
4 3 2
def get_metadata_by_arn()
in src/braket/ocean_plugin/braket_solver_metadata.py
4 2 1
def get_task_sample_set()
in src/braket/ocean_plugin/braket_sampler.py
3 1 2
def _process_solver_kwargs()
in src/braket/ocean_plugin/braket_sampler.py
3 1 2
def nodelist()
in src/braket/ocean_plugin/braket_sampler.py
2 1 1
def _access_optimized_nodelist()
in src/braket/ocean_plugin/braket_sampler.py
2 1 1