Ignore:
Timestamp:
Apr 27, 2012, 2:56:29 AM (7 years ago)
Author:
ksherdy
Message:

Added div2 support wte length greater than or equal to 17.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/symbol_table/div2_group_strms.py

    r2043 r2054  
    55        starts = 0
    66        ends = 0
    7         ends_1_2 = 0
    8         ends_3_4 = 0
    9         ends_5_6 = 0
    10         ends_7_8 = 0
    11         ends_9_10 = 0
    12         ends_11_12 = 0
    13         ends_13_14 = 0
    14         ends_15_16 = 0
     7        ends_2 = 0
     8        ends_4 = 0
     9        ends_6 = 0
     10        ends_8 = 0
     11        ends_10 = 0
     12        ends_12 = 0
     13        ends_14 = 0
     14        ends_16 = 0
    1515        ends_gte_17 = 0
    1616
     
    2323        # Group symbols of length 1 and length 2
    2424        cursor = pablo.Advance(pablo.Advance(cursor))
    25         groups.ends_1_2 = cursor & shift_or_ends
    26         temp = temp &~ groups.ends_1_2
     25        groups.ends_2 = cursor & shift_or_ends
     26        temp = temp &~ groups.ends_2
    2727
    2828        # Group symbols of length 3 and length 4
    29         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    30         groups.ends_3_4 = cursor & shift_or_ends
    31         temp = temp &~ groups.ends_3_4
     29        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
     30        groups.ends_4 = cursor & shift_or_ends
     31        temp = temp &~ groups.ends_4
    3232
    3333        # Group symbols of length 5 and length 6
    34         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    35         groups.ends_5_6 = cursor & shift_or_ends
    36         temp = temp &~ groups.ends_5_6
     34        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
     35        groups.ends_6 = cursor & shift_or_ends
     36        temp = temp &~ groups.ends_6
    3737
    3838        # Group symbols of length 7 and length 8
    39         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    40         groups.ends_7_8 = cursor & shift_or_ends
    41         temp = temp &~ groups.ends_7_8
     39        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
     40        groups.ends_8 = cursor & shift_or_ends
     41        temp = temp &~ groups.ends_8
    4242
    4343        # Group symbols of length 9 and length 10
    44         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    45         groups.ends_9_10 = cursor & shift_or_ends
    46         temp = temp &~ groups.ends_9_10
     44        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
     45        groups.ends_10 = cursor & shift_or_ends
     46        temp = temp &~ groups.ends_10
    4747
    4848        # Group symbols of length 11 and length 12
    49         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    50         groups.ends_11_12 = cursor & shift_or_ends
    51         temp = temp &~ groups.ends_11_12
     49        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
     50        groups.ends_12 = cursor & shift_or_ends
     51        temp = temp &~ groups.ends_12
    5252
    5353        # Group symbols of length 13 and length 14
    54         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    55         groups.ends_13_14 = cursor & shift_or_ends
    56         temp = temp &~ groups.ends_13_14
     54        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
     55        groups.ends_14 = cursor & shift_or_ends
     56        temp = temp &~ groups.ends_14
    5757
    5858        # Group symbols of length 15 and length 16
    59         cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
    60         groups.ends_15_16 = cursor & shift_or_ends
    61         temp = temp &~ groups.ends_15_16
     59        cursor = pablo.Advance(pablo.Advance(cursor &~ shift_or_ends))
     60        groups.ends_16 = cursor & shift_or_ends
     61        temp = temp &~ groups.ends_16
    6262
    6363        # Group symbols of length greater than equal to 17
Note: See TracChangeset for help on using the changeset viewer.