@@ -21,6 +21,19 | |||||
21 | --bx-shadow: 0 2px 5px 0 var(--bs-nav); |
|
21 | --bx-shadow: 0 2px 5px 0 var(--bs-nav); | |
22 | } |
|
22 | } | |
23 |
|
23 | |||
|
24 | label { | |||
|
25 | display: inline-block; | |||
|
26 | max-width: 100%; | |||
|
27 | margin-bottom: 5px; | |||
|
28 | font-weight: bold; | |||
|
29 | } | |||
|
30 | ||||
|
31 | .form-check-input { | |||
|
32 | position: relative; | |||
|
33 | margin-top: .3rem; | |||
|
34 | margin-left: .3rem; | |||
|
35 | } | |||
|
36 | ||||
24 | body { |
|
37 | body { | |
25 | color: #444; |
|
38 | color: #444; | |
26 | font-family: "Helvetica Neue",Helvetica,Arial,sans-serif; |
|
39 | font-family: "Helvetica Neue",Helvetica,Arial,sans-serif; |
@@ -849,6 +849,8 def experiment_mix(request, id_exp): | |||||
849 | mix.save() |
|
849 | mix.save() | |
850 |
|
850 | |||
851 | line_type = RCLineType.objects.get(name='mix') |
|
851 | line_type = RCLineType.objects.get(name='mix') | |
|
852 | print("VIew obteniendo len getlines") | |||
|
853 | print(len(rc_confs[0].get_lines())) | |||
852 | for i in range(len(rc_confs[0].get_lines())): |
|
854 | for i in range(len(rc_confs[0].get_lines())): | |
853 | line = RCLine(rc_configuration=mix, line_type=line_type, channel=i) |
|
855 | line = RCLine(rc_configuration=mix, line_type=line_type, channel=i) | |
854 | line.save() |
|
856 | line.save() |
@@ -347,8 +347,10 class RCConfiguration(Configuration): | |||||
347 | return '\n'.join(['{}'.format(x) for x in data]) |
|
347 | return '\n'.join(['{}'.format(x) for x in data]) | |
348 |
|
348 | |||
349 | def update_pulses(self): |
|
349 | def update_pulses(self): | |
350 |
|
350 | contador = 0 | ||
351 | for line in self.get_lines(): |
|
351 | for line in self.get_lines(): | |
|
352 | contador=contador+1 | |||
|
353 | print(contador) | |||
352 | line.update_pulses() |
|
354 | line.update_pulses() | |
353 |
|
355 | |||
354 | def plot_pulses2(self, km=False): |
|
356 | def plot_pulses2(self, km=False): | |
@@ -918,8 +920,15 class RCLine(models.Model): | |||||
918 | ops = [value.split('|')[2] for value in values] |
|
920 | ops = [value.split('|')[2] for value in values] | |
919 | delays = [value.split('|')[3] for value in values] |
|
921 | delays = [value.split('|')[3] for value in values] | |
920 | masks = [value.split('|')[4] for value in values] |
|
922 | masks = [value.split('|')[4] for value in values] | |
|
923 | print("masks") | |||
|
924 | print(masks) | |||
|
925 | print('{:8b}'.format(int(masks[0]))) | |||
921 | mask = list('{:8b}'.format(int(masks[0]))) |
|
926 | mask = list('{:8b}'.format(int(masks[0]))) | |
|
927 | print("mask") | |||
|
928 | print(mask) | |||
922 | mask.reverse() |
|
929 | mask.reverse() | |
|
930 | print("mask reverse") | |||
|
931 | print(mask) | |||
923 | if mask[self.channel] in ('0', '', ' '): |
|
932 | if mask[self.channel] in ('0', '', ' '): | |
924 | y = np.zeros(confs[0].total_units, dtype=np.int8) |
|
933 | y = np.zeros(confs[0].total_units, dtype=np.int8) | |
925 | else: |
|
934 | else: |
@@ -300,7 +300,7 class HCheckboxSelectMultiple(forms.CheckboxSelectMultiple): | |||||
300 |
|
300 | |||
301 | if value is None: value = [] |
|
301 | if value is None: value = [] | |
302 | has_id = attrs and 'id' in attrs |
|
302 | has_id = attrs and 'id' in attrs | |
303 |
final_attrs = self.build_attrs(attrs, name |
|
303 | final_attrs = self.build_attrs(attrs, {'name': name}) | |
304 | output = [u'<br><ul>'] |
|
304 | output = [u'<br><ul>'] | |
305 | # Normalize to strings |
|
305 | # Normalize to strings | |
306 | str_values = set([force_text(v) for v in value]) |
|
306 | str_values = set([force_text(v) for v in value]) |
@@ -21,6 +21,19 | |||||
21 | --bx-shadow: 0 2px 5px 0 var(--bs-nav); |
|
21 | --bx-shadow: 0 2px 5px 0 var(--bs-nav); | |
22 | } |
|
22 | } | |
23 |
|
23 | |||
|
24 | label { | |||
|
25 | display: inline-block; | |||
|
26 | max-width: 100%; | |||
|
27 | margin-bottom: 5px; | |||
|
28 | font-weight: bold; | |||
|
29 | } | |||
|
30 | ||||
|
31 | .form-check-input { | |||
|
32 | position: relative; | |||
|
33 | margin-top: .3rem; | |||
|
34 | margin-left: .3rem; | |||
|
35 | } | |||
|
36 | ||||
24 | body { |
|
37 | body { | |
25 | color: #444; |
|
38 | color: #444; | |
26 | font-family: "Helvetica Neue",Helvetica,Arial,sans-serif; |
|
39 | font-family: "Helvetica Neue",Helvetica,Arial,sans-serif; |
General Comments 0
You need to be logged in to leave comments.
Login now