justaddcoffee/kg-emerging-viruses

View on GitHub
kg_covid_19/make_holdouts.py

Summary

Maintainability
B
4 hrs
Test Coverage
A
93%

File make_holdouts.py has 254 lines of code (exceeds 250 allowed). Consider refactoring.
Open

"""Functions for producing holdouts for graph ML."""

import logging
import os
import random
Severity: Minor
Found in kg_covid_19/make_holdouts.py - About 2 hrs to fix

    Function make_holdouts has 27 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    def make_holdouts(
        nodes: str,
        edges: str,
        output_dir: str,
        train_fraction: float,
    Severity: Minor
    Found in kg_covid_19/make_holdouts.py - About 1 hr to fix

      Function make_holdouts has 6 arguments (exceeds 4 allowed). Consider refactoring.
      Open

      def make_holdouts(
      Severity: Minor
      Found in kg_covid_19/make_holdouts.py - About 45 mins to fix

        Function _generate_negative_edges has 5 arguments (exceeds 4 allowed). Consider refactoring.
        Open

        def _generate_negative_edges(
        Severity: Minor
        Found in kg_covid_19/make_holdouts.py - About 35 mins to fix

          There are no issues that match your filters.

          Category
          Status