pyerualjetwork 4.3.9b2__py3-none-any.whl → 4.3.9b4__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- __version__ = "4.3.9b2"
1
+ __version__ = "4.3.9b4"
2
2
  __update__ = "* Changes: https://github.com/HCB06/PyerualJetwork/blob/main/CHANGES\n* PyerualJetwork Homepage: https://github.com/HCB06/PyerualJetwork/tree/main\n* PyerualJetwork document: https://github.com/HCB06/PyerualJetwork/blob/main/Welcome_to_PyerualJetwork/PYERUALJETWORK_USER_MANUEL_AND_LEGAL_INFORMATION(EN).pdf\n* YouTube tutorials: https://www.youtube.com/@HasanCanBeydili"
3
3
 
4
4
  def print_version(__version__):
pyerualjetwork/plan.py CHANGED
@@ -188,12 +188,6 @@ def learner(x_train, y_train, optimizer, fit_start, strategy='accuracy', gen=Non
188
188
  # Initialize visualization components
189
189
  viz_objects = initialize_visualization_for_learner(show_history, neurons_history, neural_web_history, x_train, y_train)
190
190
 
191
- # Initialize progress bar
192
- if batch_size == 1:
193
- ncols = 78
194
- else:
195
- ncols = 49
196
-
197
191
  # Initialize variables
198
192
  best_acc = 0
199
193
  best_f1 = 0
@@ -204,7 +198,7 @@ def learner(x_train, y_train, optimizer, fit_start, strategy='accuracy', gen=Non
204
198
  loss_list = []
205
199
  target_pop = []
206
200
 
207
- progress = initialize_loading_bar(total=activation_potentiation_len, desc="", ncols=ncols, bar_format=bar_format_learner)
201
+ progress = initialize_loading_bar(total=activation_potentiation_len, desc="", ncols=78, bar_format=bar_format_learner)
208
202
 
209
203
  if fit_start is False or pop_size > activation_potentiation_len:
210
204
  weight_pop, act_pop = define_genomes(input_shape=len(x_train[0]), output_shape=len(y_train[0]), population_size=pop_size, dtype=dtype)
@@ -357,9 +351,6 @@ def learner(x_train, y_train, optimizer, fit_start, strategy='accuracy', gen=Non
357
351
 
358
352
  progress.update(1)
359
353
 
360
- best_acc_per_gen_list.append(best_acc)
361
- loss_list.append(best_loss)
362
-
363
354
  if batch_size != 1:
364
355
  train_model = evaluate(x_train, y_train, best_weights, final_activations)
365
356
 
@@ -373,6 +364,13 @@ def learner(x_train, y_train, optimizer, fit_start, strategy='accuracy', gen=Non
373
364
  postfix_dict[f"{data} Accuracy"] = np.round(train_model[get_acc()], 4)
374
365
  postfix_dict[f"{data} Loss"] = np.round(train_loss, 4)
375
366
  progress.set_postfix(postfix_dict)
367
+
368
+ best_acc_per_gen_list.append(train_model[get_acc()])
369
+ loss_list.append(train_loss)
370
+
371
+ else:
372
+ best_acc_per_gen_list.append(best_acc)
373
+ loss_list.append(best_loss)
376
374
 
377
375
  weight_pop, act_pop = optimizer(np.array(weight_pop, copy=False, dtype=dtype), act_pop, i, np.array(target_pop, dtype=dtype, copy=False), bar_status=False)
378
376
  target_pop = []
@@ -196,12 +196,6 @@ def learner(x_train, y_train, optimizer, fit_start, strategy='accuracy', gen=Non
196
196
  # Initialize visualization components
197
197
  viz_objects = initialize_visualization_for_learner(show_history, neurons_history, neural_web_history, x_train, y_train)
198
198
 
199
- # Initialize progress bar
200
- if batch_size == 1:
201
- ncols = 76
202
- else:
203
- ncols = 49
204
-
205
199
  # Initialize variables
206
200
  best_acc = 0
207
201
  best_f1 = 0
@@ -212,7 +206,7 @@ def learner(x_train, y_train, optimizer, fit_start, strategy='accuracy', gen=Non
212
206
  loss_list = []
213
207
  target_pop = []
214
208
 
215
- progress = initialize_loading_bar(total=activation_potentiation_len, desc="", ncols=ncols, bar_format=bar_format_learner)
209
+ progress = initialize_loading_bar(total=activation_potentiation_len, desc="", ncols=78, bar_format=bar_format_learner)
216
210
 
217
211
  if fit_start is False or pop_size > activation_potentiation_len:
218
212
  weight_pop, act_pop = define_genomes(input_shape=len(x_train[0]), output_shape=len(y_train[0]), population_size=pop_size, dtype=dtype)
@@ -367,22 +361,26 @@ def learner(x_train, y_train, optimizer, fit_start, strategy='accuracy', gen=Non
367
361
  return best_weights, best_model[get_preds()], best_acc, final_activations
368
362
 
369
363
  progress.update(1)
370
-
371
- best_acc_per_gen_list.append(best_acc)
372
- loss_list.append(best_loss)
373
364
 
374
365
  if batch_size != 1:
375
366
  train_model = evaluate(x_train, y_train, best_weights, final_activations)
376
367
 
377
368
  if loss == 'categorical_crossentropy':
378
- train_loss = categorical_crossentropy(y_true_batch=transfer_to_gpu(y_train_batch, dtype=y_train_batch.dtype), y_pred_batch=train_model[get_preds_softmax()])
369
+ train_loss = categorical_crossentropy(y_true_batch=transfer_to_gpu(y_train, dtype=y_train.dtype), y_pred_batch=train_model[get_preds_softmax()])
379
370
  else:
380
- train_loss = binary_crossentropy(y_true_batch=transfer_to_gpu(y_train_batch, dtype=y_train_batch.dtype), y_pred_batch=train_model[get_preds_softmax()])
371
+ train_loss = binary_crossentropy(y_true_batch=transfer_to_gpu(y_train, dtype=y_train.dtype), y_pred_batch=train_model[get_preds_softmax()])
381
372
 
382
373
  postfix_dict[f"{data} Accuracy"] = cp.round(train_model[get_acc()], 4)
383
374
  postfix_dict[f"{data} Loss"] = cp.round(train_loss, 4)
384
375
  progress.set_postfix(postfix_dict)
385
376
 
377
+ best_acc_per_gen_list.append(train_model[get_acc()])
378
+ loss_list.append(train_loss)
379
+
380
+ else:
381
+ best_acc_per_gen_list.append(best_acc)
382
+ loss_list.append(best_loss)
383
+
386
384
  weight_pop, act_pop = optimizer(cp.array(weight_pop, copy=False, dtype=dtype), act_pop, i, cp.array(target_pop, dtype=dtype, copy=False), bar_status=False)
387
385
  target_pop = []
388
386
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pyerualjetwork
3
- Version: 4.3.9b2
3
+ Version: 4.3.9b4
4
4
  Summary: PyerualJetwork is a machine learning library supported with GPU(CUDA) acceleration written in Python for professionals and researchers including with PLAN algorithm, PLANEAT algorithm (genetic optimization). Also includes data pre-process and memory manegament
5
5
  Author: Hasan Can Beydili
6
6
  Author-email: tchasancan@gmail.com
@@ -1,4 +1,4 @@
1
- pyerualjetwork/__init__.py,sha256=Xq17ymoPeZ0UU0jM2XmXY2oG85-nGR6-4scDvbFco4I,641
1
+ pyerualjetwork/__init__.py,sha256=i1UoaTGfwx70UIzWUX_-6AfbU-_k7Gvd086YS6rPJ08,641
2
2
  pyerualjetwork/activation_functions.py,sha256=bKf00lsuuLJNO-4vVp4OqBi4zJ-qZ8L3v-vl52notkY,7721
3
3
  pyerualjetwork/activation_functions_cuda.py,sha256=5y1Ti3GDfDteQDCUmODwe7tAyDAUlDTKmIikChQ8d6g,7772
4
4
  pyerualjetwork/data_operations.py,sha256=Flteouu6rfSo2uHMqBHuzO02dXmbNa-I5qWmUpGTZ5Y,14760
@@ -11,14 +11,14 @@ pyerualjetwork/metrics.py,sha256=q7MkhnZDRbCjFBDDfUgrl8lBYnUT_1ro1LxeBq105pI,607
11
11
  pyerualjetwork/metrics_cuda.py,sha256=73h9GC7XwmnFCVzFEEiPQfF8CwHIz2wsCbxpZrJtYgw,5061
12
12
  pyerualjetwork/model_operations.py,sha256=MCSCNYiiICRVZITobtS3ZIWmH5Q9gjyELuH32sAdgg4,12649
13
13
  pyerualjetwork/model_operations_cuda.py,sha256=NT01BK5nrDYE7H1x3KnSI8gmx0QTGGB0mP_LqEb1uuU,13157
14
- pyerualjetwork/plan.py,sha256=yqtiPUTpvO-Ty8SRJd5RFdbIKMgGGGkMVxdgbVHhfjQ,23503
15
- pyerualjetwork/plan_cuda.py,sha256=4_AXa1IvDcqvHiK7CKbQXJBlO-UP6eVtK-ubDHmLGWk,24395
14
+ pyerualjetwork/plan.py,sha256=uK-7GRXqH0ETIajOW6_B6pSyktKmHg1NE4COD7z1f7E,23536
15
+ pyerualjetwork/plan_cuda.py,sha256=tNez_xvK6yuUiwotopqtERAJUCc7RiLx7W8VEG7RoQY,24392
16
16
  pyerualjetwork/planeat.py,sha256=Lq5R0aMS4UIdZdbUKsKDv5g0WLwYryomR3IQYb8vAa4,37573
17
17
  pyerualjetwork/planeat_cuda.py,sha256=SG7Oq1F2m3lJBbG9cgmu7q_ApmwSn2SvTpcbtEVAoDE,37630
18
18
  pyerualjetwork/ui.py,sha256=wu2BhU1k-w3Kcho5Jtq4SEKe68ftaUeRGneUOSCVDjU,575
19
19
  pyerualjetwork/visualizations.py,sha256=08O5uEewuYiovZRX1uHWEHjn19LcnhndWYvqVN74xs0,28290
20
20
  pyerualjetwork/visualizations_cuda.py,sha256=PYRqj4QYUbuYMYcNwO8yaTPB-jK7E6kZHhTrAi0lwPU,28749
21
- pyerualjetwork-4.3.9b2.dist-info/METADATA,sha256=AQn9V-32uZrqHfQXYB0DBx47o_K5-dBBhGzCKysiKgw,7476
22
- pyerualjetwork-4.3.9b2.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
23
- pyerualjetwork-4.3.9b2.dist-info/top_level.txt,sha256=BRyt62U_r3ZmJpj-wXNOoA345Bzamrj6RbaWsyW4tRg,15
24
- pyerualjetwork-4.3.9b2.dist-info/RECORD,,
21
+ pyerualjetwork-4.3.9b4.dist-info/METADATA,sha256=KAOOz0a3m7sBMQ4Y2n6Ki_4ZU_eT-HN2oZF_T-9jMJU,7476
22
+ pyerualjetwork-4.3.9b4.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
23
+ pyerualjetwork-4.3.9b4.dist-info/top_level.txt,sha256=BRyt62U_r3ZmJpj-wXNOoA345Bzamrj6RbaWsyW4tRg,15
24
+ pyerualjetwork-4.3.9b4.dist-info/RECORD,,