<commit_before>#!/usr/bin/env python3
from ..models import Searchable
from ..models import Location, Stop, POI, Address
from ..models import TimeAndPlace, Platform, RealtimeTime
from ..models import Trip, Ride, RideSegment, Coordinates, TicketList, TicketData
from ..models import Line, LineType, LineTypes, Way, WayType, WayEvent
from datetime import datetime, timedelta
import xml.etree.ElementTree as ET
from .base import API
import requests
import re
import math


class EFA(API):
    name = 'efa'
    base_url = None
    country_by_id = ()
    ifopt_platforms = False
    place_id_safe_stop_id_prefix = None
    train_station_suffixes = {}
    train_station_lines = LineTypes(('train', 'urban'))
    encoding = 'ISO-8859-1'
    replace_in_full_name = {
        'Hauptbahnhof$': 'Hbf',
        'Bahnhof$': '',
        'S$': ''
    }

    def __init__(self, *args, **kwargs):
        super().__init__(*args, **kwargs)

    def _get_location(self, location):
        if not isinstance(location, Stop):
            raise NotImplementedError<commit_msg>fix for replace_in_full_name<commit_after>#!/usr/bin/env python3
from ..models import Searchable
from ..models import Location, Stop, POI, Address
from ..models import TimeAndPlace, Platform, RealtimeTime
from ..models import Trip, Ride, RideSegment, Coordinates, TicketList, TicketData
from ..models import Line, LineType, LineTypes, Way, WayType, WayEvent
from datetime import datetime, timedelta
import xml.etree.ElementTree as ET
from .base import API
import requests
import re
import math


class EFA(API):
    name = 'efa'
    base_url = None
    country_by_id = ()
    ifopt_platforms = False
    place_id_safe_stop_id_prefix = None
    train_station_suffixes = {}
    train_station_lines = LineTypes(('train', 'urban'))
    encoding = 'ISO-8859-1'
    replace_in_full_name = {
        ' Hauptbahnhof$': ' Hbf',
        ' Bahnhof$': '',
        ' Bf$': '',
        ' S$': ''
    }

    def __init__(self, *args, **kwargs):
        super().__init__(*args, **kwargs)

    def _get_location(self, location):
        if not isinstance(location, Stop):
            raise NotImplementedError
{'fraction_non_alphanumeric': 0.11048951048951049, 'fraction_numerical': 0.005594405594405594, 'mean_word_length': 3.489539748953975, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, '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': '2046290', 'n_tokens_mistral': 681, 'n_tokens_neox': 658, 'n_words': 188}