-
Notifications
You must be signed in to change notification settings - Fork 347
Open
Description
Is this the behavior one wants?
from unittest import TestCase
from qcodes.instrument.parameter import ManualParameter
from qcodes.utils.validators import Numbers
class TestSweepValues(TestCase):
def setUp(self):
self.c0 = ManualParameter('c0', vals=Numbers(-10, 10))
def test_slicing(self):
c0 = self.c0
self.assertEquals(list(c0[1:2:1]), list(c0.sweep(1,2,1)))Run tests
>>>AssertionError: Lists differ: [1] != [1.0, 2.0]- The types are different (it's python so meh, but hella confusing none the less)
- The sweep values one gets are very different
@alexcjohnson maybe it's by design (or I am sure it's by design, given the fact that it's almost clone of numpy.arange) ?
Reactions are currently unavailable