<commit_before>import Renderer from "./renderer.js";
import {SVG} from "../../core/svg.js";
import FeatureBinarySearchTree from "../feature-binary-search-tree.js";
import GenomeBrowserUtils from "../genome-browser-utils.js";
import GenomeBrowserConstants from "../genome-browser-constants.js";


export default class GeneRenderer extends Renderer {

    render(features, options) {
        (features || []).forEach((feature, index) => {

            // Prevent rendering a feature twice
            if (options.renderedFeatures.has(feature.id)) {
                return;
            }

            // Add this feature to the list of rendered features
            options.renderedFeatures.add(feature.id);
<commit_msg>gb: minor improvements in gene renderer #TASK-528<commit_after>import Renderer from "./renderer.js";
import {SVG} from "../../core/svg.js";
import FeatureBinarySearchTree from "../feature-binary-search-tree.js";
import GenomeBrowserUtils from "../genome-browser-utils.js";
import GenomeBrowserConstants from "../genome-browser-constants.js";


export default class GeneRenderer extends Renderer {

    render(features, options) {
        (features || []).forEach((feature, index) => {

            // Prevent rendering a feature twice
            if (options.renderedFeatures) {
                if (options.renderedFeatures.has(feature.id)) {
                    return;
                }
                options.renderedFeatures.add(feature.id);
            }

{'fraction_non_alphanumeric': 0.12449255751014884, 'fraction_numerical': 0.0020297699594046007, 'mean_word_length': 2.5898058252427183, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2226535', 'n_tokens_mistral': 385, 'n_tokens_neox': 361, 'n_words': 97}