:py:mod:`alhambra.sensitivitynew`
=================================

.. py:module:: alhambra.sensitivitynew


Module Contents
---------------

Classes
~~~~~~~

.. autoapisummary::

   alhambra.sensitivitynew.FakeSingle
   alhambra.sensitivitynew.CounterSet
   alhambra.sensitivitynew.SetSet
   alhambra.sensitivitynew.PathSet



Functions
~~~~~~~~~

.. autoapisummary::

   alhambra.sensitivitynew._fakesingle
   alhambra.sensitivitynew._fakesingles
   alhambra.sensitivitynew.sensitivity_classes



Attributes
~~~~~~~~~~

.. autoapisummary::

   alhambra.sensitivitynew._rev


.. py:class:: FakeSingle(edges: Optional[Iterable[alhambra.glues.Glue | str]] = None, name: Optional[str] = None, color: Optional[Color] = None, stoic: Optional[float] = None, note: Optional[str | dict[str, Any]] = None, use: Sequence[alhambra.glues.Use | int | str] | None = None, fake: bool = False, uses: Sequence[Sequence[alhambra.glues.Use | int | str]] | None = None)


   Bases: :py:obj:`alhambra.tiles.Tile`

   Base class for a tile.


.. py:class:: CounterSet(iterable=None, /, **kwds)


   Bases: :py:obj:`collections.Counter`

   Dict subclass for counting hashable items.  Sometimes called a bag
   or multiset.  Elements are stored as dictionary keys and their counts
   are stored as dictionary values.

   >>> c = Counter('abcdeabcdabcaba')  # count elements from a string

   >>> c.most_common(3)                # three most common elements
   [('a', 5), ('b', 4), ('c', 3)]
   >>> sorted(c)                       # list all unique elements
   ['a', 'b', 'c', 'd', 'e']
   >>> ''.join(sorted(c.elements()))   # list elements with repetitions
   'aaaaabbbbcccdde'
   >>> sum(c.values())                 # total of all counts
   15

   >>> c['a']                          # count of letter 'a'
   5
   >>> for elem in 'shazam':           # update counts from an iterable
   ...     c[elem] += 1                # by adding 1 to each element's count
   >>> c['a']                          # now there are seven 'a'
   7
   >>> del c['b']                      # remove all 'b'
   >>> c['b']                          # now there are zero 'b'
   0

   >>> d = Counter('simsalabim')       # make another counter
   >>> c.update(d)                     # add in the second counter
   >>> c['a']                          # now there are nine 'a'
   9

   >>> c.clear()                       # empty the counter
   >>> c
   Counter()

   Note:  If a count is set to zero or reduced to zero, it will remain
   in the counter until the entry is deleted or the counter is cleared:

   >>> c = Counter('aaabbc')
   >>> c['b'] -= 2                     # reduce the count of 'b' by two
   >>> c.most_common()                 # 'b' is still in, but its count is zero
   [('a', 3), ('c', 1), ('b', 0)]


   .. py:method:: add(val, valthrowaway)



.. py:class:: SetSet


   Bases: :py:obj:`set`

   set() -> new empty set object
   set(iterable) -> new set object

   Build an unordered collection of unique elements.

   .. py:method:: add(val, valthrowaway)

      Add an element to a set.

      This has no effect if the element is already present.



.. py:class:: PathSet


   Bases: :py:obj:`dict`

   dict() -> new empty dictionary
   dict(mapping) -> new dictionary initialized from a mapping object's
       (key, value) pairs
   dict(iterable) -> new dictionary initialized as if via:
       d = {}
       for k, v in iterable:
           d[k] = v
   dict(**kwargs) -> new dictionary initialized with the name=value pairs
       in the keyword argument list.  For example:  dict(one=1, two=2)

   .. py:method:: add(key, val)



.. py:function:: _fakesingle(tile: alhambra.tiles.Tile)


.. py:function:: _fakesingles(tiles)


.. py:data:: _rev
   :value: [2, 3, 0, 1]

   

.. py:function:: sensitivity_classes(tileset, count=False, _maxorder=2)


