References
args = parser.parse_args()
module-attribute
napari_ui = 'napari' in params['general'].get('ui', '')
module-attribute
params = yaml.safe_load(file)
module-attribute
parser = argparse.ArgumentParser(description=f'multiview-stitcher')
module-attribute
pipeline = Pipeline(params, viewer)
module-attribute
viewer = napari.Viewer()
module-attribute
MVSRegistration
MVSRegistration
Source code in src\MVSRegistration.py
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 | |
logging_dask = params_logging.get('dask', False)
instance-attribute
logging_time = params_logging.get('time', False)
instance-attribute
mpl_ui = 'mpl' in self.ui or 'plot' in self.ui
instance-attribute
napari_ui = 'napari' in self.ui
instance-attribute
params_general = params_general
instance-attribute
reg_transform_key = 'registered'
instance-attribute
source_transform_key = 'source_metadata'
instance-attribute
transition_transform_key = 'transition'
instance-attribute
ui = self.params_general.get('ui', '')
instance-attribute
verbose = params_logging.get('verbose', False)
instance-attribute
__init__(params_general)
Source code in src\MVSRegistration.py
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | |
calc_metrics(results, labels)
Source code in src\MVSRegistration.py
733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 | |
calc_overlap_metrics(results)
Source code in src\MVSRegistration.py
671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 | |
fuse(sims, transform_key=None)
Source code in src\MVSRegistration.py
596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 | |
get_overlap_images(sims, transform_key)
Source code in src\MVSRegistration.py
692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 | |
init_sims(target_scale=None)
Source code in src\MVSRegistration.py
237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 | |
preprocess(sims, params)
Source code in src\MVSRegistration.py
393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 | |
register(sims, register_sims, indices, params)
Source code in src\MVSRegistration.py
439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 | |
run_operation(fileset_label, filenames, params, global_rotation=None, global_center=None)
Source code in src\MVSRegistration.py
48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 | |
save_thumbnail(output_filename, nom_sims=None, transform_key=None)
Source code in src\MVSRegistration.py
650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 | |
save_video(output, sims, fused_image)
Source code in src\MVSRegistration.py
790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 | |
validate_overlap(sims, labels, is_stack=False, expect_large_overlap=False)
Source code in src\MVSRegistration.py
359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 | |
apply_transform(points, transform)
Source code in src\util.py
371 372 373 374 375 376 377 378 379 | |
blur_image(image, sigma)
Source code in src\image\util.py
432 433 434 435 436 437 438 439 440 | |
blur_image_single(image, sigma)
Source code in src\image\util.py
428 429 | |
calc_foreground_map(sims)
Source code in src\image\util.py
564 565 566 567 568 569 570 571 572 573 574 575 576 577 | |
calc_images_median(images)
Source code in src\image\util.py
443 444 445 446 | |
calc_images_quantiles(images, quantiles)
Source code in src\image\util.py
449 450 451 | |
calc_output_properties(sims, transform_key, z_scale=None)
Source code in src\image\util.py
627 628 629 630 631 632 633 634 635 636 637 | |
calc_pyramid(xyzct, npyramid_add=0, pyramid_downsample=2, volumetric_resize=False)
Source code in src\image\util.py
193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
check_round_significants(a, significant_digits)
Source code in src\util.py
113 114 115 116 117 118 119 120 121 | |
color_image(image)
Source code in src\image\util.py
42 43 44 45 46 47 | |
combine_transforms(transforms)
Source code in src\image\util.py
709 710 711 712 713 714 715 716 | |
convert_image_sign_type(image, target_dtype)
Source code in src\image\util.py
97 98 99 100 101 102 103 104 105 106 107 | |
convert_rational_value(value)
Source code in src\util.py
321 322 323 324 325 326 327 | |
convert_to_um(value, unit)
Source code in src\util.py
310 311 312 313 314 315 316 317 318 | |
create_compression_filter(compression)
Source code in src\image\util.py
399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 | |
create_transform(center, angle, matrix_size=3)
Source code in src\util.py
356 357 358 359 360 361 362 363 364 365 366 367 368 | |
create_transform0(center=(0, 0), angle=0, scale=1, translate=(0, 0))
Source code in src\util.py
348 349 350 351 352 353 | |
desc_to_dict(desc)
Source code in src\util.py
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | |
detect_area_points(image)
Source code in src\image\util.py
517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 | |
dict_to_xyz(dct, keys='xyz')
Source code in src\util.py
452 453 | |
dir_regex(pattern)
Source code in src\util.py
141 142 143 144 145 146 | |
draw_edge_filter(bounds)
Source code in src\util.py
496 497 498 499 500 501 502 503 504 | |
draw_keypoints(image, points, color=(255, 0, 0))
Source code in src\image\util.py
279 280 281 282 283 284 | |
draw_keypoints_matches(image1, points1, image2, points2, matches=None, inliers=None, points_color='black', match_color='red', inlier_color='lime', show_plot=True, output_filename=None)
Source code in src\image\util.py
348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 | |
draw_keypoints_matches_cv(image1, points1, image2, points2, matches=None, inliers=None, color=(255, 0, 0), inlier_color=(0, 255, 0), radius=15, thickness=2)
Source code in src\image\util.py
287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 | |
draw_keypoints_matches_sk(image1, points1, image2, points2, matches=None, show_plot=True, output_filename=None)
Source code in src\image\util.py
323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 | |
ensure_list(x)
Source code in src\util.py
18 19 20 21 22 23 24 | |
ensure_unsigned_image(image)
Source code in src\image\util.py
85 86 87 88 89 90 91 92 93 94 | |
ensure_unsigned_type(dtype)
Source code in src\image\util.py
78 79 80 81 82 | |
eval_context(data, key, default_value, context)
Source code in src\util.py
266 267 268 269 270 271 272 273 274 275 276 277 | |
export_csv(filename, data, header=None)
Source code in src\util.py
602 603 604 605 606 607 608 | |
export_json(filename, data)
Source code in src\util.py
591 592 593 | |
filter_dict(dict0)
Source code in src\util.py
38 39 40 41 42 43 44 45 46 47 48 49 50 | |
filter_edge_points(points, bounds, filter_factor=0.1, threshold=0.5)
Source code in src\util.py
487 488 489 490 491 492 493 | |
filter_noise_images(images)
Source code in src\image\util.py
508 509 510 511 512 513 514 | |
find_all_numbers(text)
Source code in src\util.py
149 150 | |
float2int_image(image, target_dtype=np.dtype(np.uint8))
Source code in src\image\util.py
59 60 61 62 63 64 65 | |
get_center(data, offset=(0, 0))
Source code in src\util.py
339 340 341 342 343 344 345 | |
get_center_from_transform(transform)
Source code in src\util.py
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 | |
get_data_mapping(data, transform_key=None, transform=None, translation0=None, rotation=None)
Source code in src\image\util.py
674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 | |
get_default(x, default)
Source code in src\util.py
14 15 | |
get_filetitle(filename)
Source code in src\util.py
135 136 137 138 | |
get_image_quantile(image, quantile, axis=None)
Source code in src\image\util.py
454 455 456 | |
get_image_size_info(sizes_xyzct, pixel_nbytes, pixel_type, channels)
Source code in src\image\util.py
152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 | |
get_image_window(image, low=0.01, high=0.99)
Source code in src\image\util.py
459 460 461 462 463 464 | |
get_max_downsamples(shape, npyramid_add, pyramid_downsample)
Source code in src\image\util.py
498 499 500 501 502 503 504 505 | |
get_mean_nn_distance(points1, points2)
Source code in src\util.py
483 484 | |
get_moments(data, offset=(0, 0))
Source code in src\util.py
330 331 332 | |
get_moments_center(moments, offset=(0, 0))
Source code in src\util.py
335 336 | |
get_nn_distance(points0)
Source code in src\util.py
472 473 474 475 476 477 478 479 480 | |
get_numpy_slicing(dimension_order, **slicing)
Source code in src\image\util.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 | |
get_orthogonal_pairs(origins, image_size_um)
Get pairs of orthogonal neighbors from a list of tiles. Tiles don't have to be placed on a regular grid.
Source code in src\util.py
507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 | |
get_properties_from_transform(transform, invert=False)
Source code in src\image\util.py
660 661 662 663 664 665 666 667 668 669 670 671 | |
get_rotation_from_transform(transform)
Source code in src\util.py
427 428 429 | |
get_scale_from_transform(transform)
Source code in src\util.py
397 398 399 | |
get_sim_physical_size(sim, invert=False)
Source code in src\image\util.py
620 621 622 623 624 | |
get_sim_position_final(sim)
Source code in src\image\util.py
540 541 542 543 544 545 | |
get_sim_shape_2d(sim, transform_key=None)
Source code in src\image\util.py
640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 | |
get_translation_from_transform(transform)
Source code in src\util.py
402 403 404 405 406 | |
get_unique_file_labels(filenames)
Source code in src\util.py
179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
get_value_units_micrometer(value_units0)
Source code in src\util.py
280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 | |
grayscale_image(image)
Source code in src\image\util.py
32 33 34 35 36 37 38 39 | |
group_sims_by_z(sims)
Source code in src\image\util.py
548 549 550 551 552 553 554 555 556 557 558 559 560 561 | |
image_reshape(image, target_size)
Source code in src\image\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 | |
image_resize(image, target_size0, dimension_order='yxc')
Source code in src\image\util.py
232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 | |
import_csv(filename)
Source code in src\util.py
596 597 598 599 | |
import_json(filename)
Source code in src\util.py
585 586 587 588 | |
import_metadata(content, fields=None, input_path=None)
Source code in src\util.py
568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 | |
int2float_image(image)
Source code in src\image\util.py
50 51 52 53 54 55 56 | |
norm_image_quantiles(image0, quantile=0.99)
Source code in src\image\util.py
484 485 486 487 488 489 490 491 492 493 494 495 | |
norm_image_variance(image0)
Source code in src\image\util.py
472 473 474 475 476 477 478 479 480 481 | |
normalise(sims, transform_key, use_global=True)
Source code in src\image\util.py
580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 | |
normalise_rotated_positions(positions0, rotations0, size, center)
Source code in src\util.py
456 457 458 459 460 461 462 463 464 465 466 467 468 469 | |
normalise_rotation(rotation)
Normalise rotation to be in the range [-180, 180].
Source code in src\util.py
432 433 434 435 436 437 438 439 440 | |
normalise_values(image, min_value, max_value)
Source code in src\image\util.py
467 468 469 | |
pilmode_to_pixelinfo(mode)
Source code in src\image\util.py
171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 | |
points_to_3d(points)
Source code in src\util.py
443 444 | |
precise_resize(image, factors)
Source code in src\image\util.py
272 273 274 275 276 | |
print_dict(dct, indent=0)
Source code in src\util.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | |
print_hbytes(nbytes)
Source code in src\util.py
98 99 100 101 102 103 104 105 106 107 108 109 110 | |
redimension_data(data, old_order, new_order, **indices)
Source code in src\image\util.py
110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 | |
reorder(items, old_order, new_order, default_value=0)
Source code in src\util.py
27 28 29 30 31 32 33 34 35 | |
resize_image(image, new_size)
Source code in src\image\util.py
224 225 226 227 228 229 | |
retuple(chunks, shape)
Expand chunks to match shape.
E.g. if chunks is (64, 64) and shape is (3, 4, 5, 1028, 1028) return (3, 4, 5, 64, 64)
If chunks is an integer, it is applied to all dimensions, to match the behaviour of zarr-python.
Source code in src\util.py
549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 | |
round_significants(a, significant_digits)
Source code in src\util.py
124 125 126 127 128 | |
show_image(image, title='', cmap=None)
Source code in src\image\util.py
22 23 24 25 26 27 28 29 | |
split_num_text(text)
Source code in src\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 | |
split_numeric(text)
Source code in src\util.py
153 154 155 156 157 158 159 160 | |
split_numeric_dict(text)
Source code in src\util.py
163 164 165 166 167 168 169 170 171 172 173 174 175 176 | |
split_path(path)
Source code in src\util.py
131 132 | |
split_value_unit_list(text)
Source code in src\util.py
238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 | |
uint8_image(image)
Source code in src\image\util.py
68 69 70 71 72 73 74 75 | |
validate_transform(transform, max_rotation=None)
Source code in src\util.py
382 383 384 385 386 387 388 389 390 391 392 393 394 | |
xyz_to_dict(xyz, axes='xyz')
Source code in src\util.py
447 448 449 | |
MVSRegistrationNapari
MVSRegistrationNapari
Bases: MVSRegistration, QObject
Source code in src\MVSRegistrationNapari.py
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | |
update_napari_signal = Signal(str, list, list)
class-attribute
instance-attribute
viewer = viewer
instance-attribute
__init__(params_general, viewer)
Source code in src\MVSRegistrationNapari.py
9 10 11 12 | |
update_napari(layer_name, shapes, labels)
Source code in src\MVSRegistrationNapari.py
14 15 16 17 18 19 20 | |
Pipeline
Pipeline
Bases: Thread
Source code in src\Pipeline.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 | |
mvs_registration = MVSRegistrationNapari(self.params_general, self.viewer)
instance-attribute
params = params
instance-attribute
params_general = params['general']
instance-attribute
viewer = viewer
instance-attribute
__init__(params, viewer=None)
Source code in src\Pipeline.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | |
init_logging()
Source code in src\Pipeline.py
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | |
run()
Source code in src\Pipeline.py
62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 | |
run_operation(params)
Source code in src\Pipeline.py
80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 | |
Timer
Timer
Bases: object
Source code in src\Timer.py
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | |
auto_unit = auto_unit
instance-attribute
title = title
instance-attribute
verbose = verbose
instance-attribute
__enter__()
Source code in src\Timer.py
13 14 15 | |
__exit__(type, value, traceback)
Source code in src\Timer.py
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | |
__init__(title, auto_unit=True, verbose=True)
Source code in src\Timer.py
8 9 10 11 | |
constants
tiff_extension = '.ome.tiff'
module-attribute
version = '0.2.10'
module-attribute
zarr_extension = '.ome.zarr'
module-attribute
image
DaskSource
DaskSource
Source code in src\image\DaskSource.py
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | |
channels = []
instance-attribute
default_physical_unit = 'µm'
class-attribute
instance-attribute
dimension_order = ''
instance-attribute
dtype = None
instance-attribute
filename = filename
instance-attribute
is_rgb = False
instance-attribute
pixel_size = {}
instance-attribute
pixel_sizes = []
instance-attribute
position = {}
instance-attribute
positions = []
instance-attribute
rotation = 0
instance-attribute
scales = []
instance-attribute
shape = []
instance-attribute
shapes = []
instance-attribute
__init__(filename, source_metadata=None)
Source code in src\image\DaskSource.py
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | |
fix_metadata(source_metadata=None)
Source code in src\image\DaskSource.py
29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 | |
get_channels()
Source code in src\image\DaskSource.py
97 98 99 100 101 102 103 | |
get_data(level=0)
Source code in src\image\DaskSource.py
105 106 | |
get_nchannels()
Source code in src\image\DaskSource.py
94 95 | |
get_physical_size()
Source code in src\image\DaskSource.py
78 79 80 81 | |
get_pixel_size(level=0)
Source code in src\image\DaskSource.py
68 69 70 71 72 73 74 75 76 | |
get_position(level=0)
Source code in src\image\DaskSource.py
83 84 85 86 87 88 | |
get_rotation()
Source code in src\image\DaskSource.py
90 91 92 | |
get_shape(level=0)
Source code in src\image\DaskSource.py
60 61 62 | |
get_size(level=0)
Source code in src\image\DaskSource.py
64 65 66 | |
init_metadata()
Source code in src\image\DaskSource.py
26 27 | |
TiffDaskSource
TiffDaskSource
Bases: DaskSource
Source code in src\image\TiffDaskSource.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 | |
get_data(level=0)
Source code in src\image\TiffDaskSource.py
104 105 106 107 | |
init_metadata()
Source code in src\image\TiffDaskSource.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 | |
Video
Video
Source code in src\image\Video.py
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | |
filename = filename
instance-attribute
fps = fps
instance-attribute
min = 0
instance-attribute
range = 1
instance-attribute
scale = scale
instance-attribute
size = size
instance-attribute
vidwriter = None
instance-attribute
__init__(filename, fps=1, scale=1, size=None)
Source code in src\image\Video.py
8 9 10 11 12 13 14 15 | |
close()
Source code in src\image\Video.py
29 30 31 | |
write(frame)
Source code in src\image\Video.py
17 18 19 20 21 22 23 24 25 26 27 | |
apply_transform(points, transform)
Source code in src\util.py
371 372 373 374 375 376 377 378 379 | |
blur_image(image, sigma)
Source code in src\image\util.py
432 433 434 435 436 437 438 439 440 | |
blur_image_single(image, sigma)
Source code in src\image\util.py
428 429 | |
calc_foreground_map(sims)
Source code in src\image\util.py
564 565 566 567 568 569 570 571 572 573 574 575 576 577 | |
calc_images_median(images)
Source code in src\image\util.py
443 444 445 446 | |
calc_images_quantiles(images, quantiles)
Source code in src\image\util.py
449 450 451 | |
calc_output_properties(sims, transform_key, z_scale=None)
Source code in src\image\util.py
627 628 629 630 631 632 633 634 635 636 637 | |
calc_pyramid(xyzct, npyramid_add=0, pyramid_downsample=2, volumetric_resize=False)
Source code in src\image\util.py
193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
check_round_significants(a, significant_digits)
Source code in src\util.py
113 114 115 116 117 118 119 120 121 | |
color_image(image)
Source code in src\image\util.py
42 43 44 45 46 47 | |
combine_transforms(transforms)
Source code in src\image\util.py
709 710 711 712 713 714 715 716 | |
convert_image_sign_type(image, target_dtype)
Source code in src\image\util.py
97 98 99 100 101 102 103 104 105 106 107 | |
convert_rational_value(value)
Source code in src\util.py
321 322 323 324 325 326 327 | |
convert_to_um(value, unit)
Source code in src\util.py
310 311 312 313 314 315 316 317 318 | |
create_compression_filter(compression)
Source code in src\image\util.py
399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 | |
create_transform(center, angle, matrix_size=3)
Source code in src\util.py
356 357 358 359 360 361 362 363 364 365 366 367 368 | |
create_transform0(center=(0, 0), angle=0, scale=1, translate=(0, 0))
Source code in src\util.py
348 349 350 351 352 353 | |
desc_to_dict(desc)
Source code in src\util.py
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | |
detect_area_points(image)
Source code in src\image\util.py
517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 | |
dict_to_xyz(dct, keys='xyz')
Source code in src\util.py
452 453 | |
dir_regex(pattern)
Source code in src\util.py
141 142 143 144 145 146 | |
draw_edge_filter(bounds)
Source code in src\util.py
496 497 498 499 500 501 502 503 504 | |
draw_keypoints(image, points, color=(255, 0, 0))
Source code in src\image\util.py
279 280 281 282 283 284 | |
draw_keypoints_matches(image1, points1, image2, points2, matches=None, inliers=None, points_color='black', match_color='red', inlier_color='lime', show_plot=True, output_filename=None)
Source code in src\image\util.py
348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 | |
draw_keypoints_matches_cv(image1, points1, image2, points2, matches=None, inliers=None, color=(255, 0, 0), inlier_color=(0, 255, 0), radius=15, thickness=2)
Source code in src\image\util.py
287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 | |
draw_keypoints_matches_sk(image1, points1, image2, points2, matches=None, show_plot=True, output_filename=None)
Source code in src\image\util.py
323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 | |
ensure_list(x)
Source code in src\util.py
18 19 20 21 22 23 24 | |
ensure_unsigned_image(image)
Source code in src\image\util.py
85 86 87 88 89 90 91 92 93 94 | |
ensure_unsigned_type(dtype)
Source code in src\image\util.py
78 79 80 81 82 | |
eval_context(data, key, default_value, context)
Source code in src\util.py
266 267 268 269 270 271 272 273 274 275 276 277 | |
export_csv(filename, data, header=None)
Source code in src\util.py
602 603 604 605 606 607 608 | |
export_json(filename, data)
Source code in src\util.py
591 592 593 | |
filter_dict(dict0)
Source code in src\util.py
38 39 40 41 42 43 44 45 46 47 48 49 50 | |
filter_edge_points(points, bounds, filter_factor=0.1, threshold=0.5)
Source code in src\util.py
487 488 489 490 491 492 493 | |
filter_noise_images(images)
Source code in src\image\util.py
508 509 510 511 512 513 514 | |
find_all_numbers(text)
Source code in src\util.py
149 150 | |
float2int_image(image, target_dtype=np.dtype(np.uint8))
Source code in src\image\util.py
59 60 61 62 63 64 65 | |
get_center(data, offset=(0, 0))
Source code in src\util.py
339 340 341 342 343 344 345 | |
get_center_from_transform(transform)
Source code in src\util.py
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 | |
get_data_mapping(data, transform_key=None, transform=None, translation0=None, rotation=None)
Source code in src\image\util.py
674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 | |
get_default(x, default)
Source code in src\util.py
14 15 | |
get_filetitle(filename)
Source code in src\util.py
135 136 137 138 | |
get_image_quantile(image, quantile, axis=None)
Source code in src\image\util.py
454 455 456 | |
get_image_size_info(sizes_xyzct, pixel_nbytes, pixel_type, channels)
Source code in src\image\util.py
152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 | |
get_image_window(image, low=0.01, high=0.99)
Source code in src\image\util.py
459 460 461 462 463 464 | |
get_max_downsamples(shape, npyramid_add, pyramid_downsample)
Source code in src\image\util.py
498 499 500 501 502 503 504 505 | |
get_mean_nn_distance(points1, points2)
Source code in src\util.py
483 484 | |
get_moments(data, offset=(0, 0))
Source code in src\util.py
330 331 332 | |
get_moments_center(moments, offset=(0, 0))
Source code in src\util.py
335 336 | |
get_nn_distance(points0)
Source code in src\util.py
472 473 474 475 476 477 478 479 480 | |
get_numpy_slicing(dimension_order, **slicing)
Source code in src\image\util.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 | |
get_orthogonal_pairs(origins, image_size_um)
Get pairs of orthogonal neighbors from a list of tiles. Tiles don't have to be placed on a regular grid.
Source code in src\util.py
507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 | |
get_properties_from_transform(transform, invert=False)
Source code in src\image\util.py
660 661 662 663 664 665 666 667 668 669 670 671 | |
get_rotation_from_transform(transform)
Source code in src\util.py
427 428 429 | |
get_scale_from_transform(transform)
Source code in src\util.py
397 398 399 | |
get_sim_physical_size(sim, invert=False)
Source code in src\image\util.py
620 621 622 623 624 | |
get_sim_position_final(sim)
Source code in src\image\util.py
540 541 542 543 544 545 | |
get_sim_shape_2d(sim, transform_key=None)
Source code in src\image\util.py
640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 | |
get_translation_from_transform(transform)
Source code in src\util.py
402 403 404 405 406 | |
get_unique_file_labels(filenames)
Source code in src\util.py
179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
get_value_units_micrometer(value_units0)
Source code in src\util.py
280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 | |
grayscale_image(image)
Source code in src\image\util.py
32 33 34 35 36 37 38 39 | |
group_sims_by_z(sims)
Source code in src\image\util.py
548 549 550 551 552 553 554 555 556 557 558 559 560 561 | |
image_reshape(image, target_size)
Source code in src\image\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 | |
image_resize(image, target_size0, dimension_order='yxc')
Source code in src\image\util.py
232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 | |
import_csv(filename)
Source code in src\util.py
596 597 598 599 | |
import_json(filename)
Source code in src\util.py
585 586 587 588 | |
import_metadata(content, fields=None, input_path=None)
Source code in src\util.py
568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 | |
int2float_image(image)
Source code in src\image\util.py
50 51 52 53 54 55 56 | |
norm_image_quantiles(image0, quantile=0.99)
Source code in src\image\util.py
484 485 486 487 488 489 490 491 492 493 494 495 | |
norm_image_variance(image0)
Source code in src\image\util.py
472 473 474 475 476 477 478 479 480 481 | |
normalise(sims, transform_key, use_global=True)
Source code in src\image\util.py
580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 | |
normalise_rotated_positions(positions0, rotations0, size, center)
Source code in src\util.py
456 457 458 459 460 461 462 463 464 465 466 467 468 469 | |
normalise_rotation(rotation)
Normalise rotation to be in the range [-180, 180].
Source code in src\util.py
432 433 434 435 436 437 438 439 440 | |
normalise_values(image, min_value, max_value)
Source code in src\image\util.py
467 468 469 | |
pilmode_to_pixelinfo(mode)
Source code in src\image\util.py
171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 | |
points_to_3d(points)
Source code in src\util.py
443 444 | |
precise_resize(image, factors)
Source code in src\image\util.py
272 273 274 275 276 | |
print_dict(dct, indent=0)
Source code in src\util.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | |
print_hbytes(nbytes)
Source code in src\util.py
98 99 100 101 102 103 104 105 106 107 108 109 110 | |
redimension_data(data, old_order, new_order, **indices)
Source code in src\image\util.py
110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 | |
reorder(items, old_order, new_order, default_value=0)
Source code in src\util.py
27 28 29 30 31 32 33 34 35 | |
resize_image(image, new_size)
Source code in src\image\util.py
224 225 226 227 228 229 | |
retuple(chunks, shape)
Expand chunks to match shape.
E.g. if chunks is (64, 64) and shape is (3, 4, 5, 1028, 1028) return (3, 4, 5, 64, 64)
If chunks is an integer, it is applied to all dimensions, to match the behaviour of zarr-python.
Source code in src\util.py
549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 | |
round_significants(a, significant_digits)
Source code in src\util.py
124 125 126 127 128 | |
show_image(image, title='', cmap=None)
Source code in src\image\util.py
22 23 24 25 26 27 28 29 | |
split_num_text(text)
Source code in src\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 | |
split_numeric(text)
Source code in src\util.py
153 154 155 156 157 158 159 160 | |
split_numeric_dict(text)
Source code in src\util.py
163 164 165 166 167 168 169 170 171 172 173 174 175 176 | |
split_path(path)
Source code in src\util.py
131 132 | |
split_value_unit_list(text)
Source code in src\util.py
238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 | |
uint8_image(image)
Source code in src\image\util.py
68 69 70 71 72 73 74 75 | |
validate_transform(transform, max_rotation=None)
Source code in src\util.py
382 383 384 385 386 387 388 389 390 391 392 393 394 | |
xyz_to_dict(xyz, axes='xyz')
Source code in src\util.py
447 448 449 | |
ZarrDaskSource
ZarrDaskSource
Bases: DaskSource
Source code in src\image\ZarrDaskSource.py
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 | |
get_data(level=0)
Source code in src\image\ZarrDaskSource.py
65 66 | |
init_metadata()
Source code in src\image\ZarrDaskSource.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 | |
color_conversion
hexrgb_to_rgba(hexrgb)
Source code in src\image\color_conversion.py
21 22 23 | |
int_to_rgba(intrgba)
Source code in src\image\color_conversion.py
3 4 5 6 7 8 | |
rgba_to_hexrgb(rgba)
Source code in src\image\color_conversion.py
16 17 18 | |
rgba_to_int(rgba)
Source code in src\image\color_conversion.py
11 12 13 | |
flatfield
apply_flatfield_correction(sims, transform_key, quantiles, quantile_images)
Source code in src\image\flatfield.py
45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 | |
apply_transform(points, transform)
Source code in src\util.py
371 372 373 374 375 376 377 378 379 | |
blur_image(image, sigma)
Source code in src\image\util.py
432 433 434 435 436 437 438 439 440 | |
blur_image_single(image, sigma)
Source code in src\image\util.py
428 429 | |
calc_flatfield_images(sims, quantiles, foreground_map=None)
Source code in src\image\flatfield.py
33 34 35 36 37 38 39 40 41 42 | |
calc_foreground_map(sims)
Source code in src\image\util.py
564 565 566 567 568 569 570 571 572 573 574 575 576 577 | |
calc_images_median(images)
Source code in src\image\util.py
443 444 445 446 | |
calc_images_quantiles(images, quantiles)
Source code in src\image\util.py
449 450 451 | |
calc_output_properties(sims, transform_key, z_scale=None)
Source code in src\image\util.py
627 628 629 630 631 632 633 634 635 636 637 | |
calc_pyramid(xyzct, npyramid_add=0, pyramid_downsample=2, volumetric_resize=False)
Source code in src\image\util.py
193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
check_round_significants(a, significant_digits)
Source code in src\util.py
113 114 115 116 117 118 119 120 121 | |
color_image(image)
Source code in src\image\util.py
42 43 44 45 46 47 | |
combine_transforms(transforms)
Source code in src\image\util.py
709 710 711 712 713 714 715 716 | |
convert_image_sign_type(image, target_dtype)
Source code in src\image\util.py
97 98 99 100 101 102 103 104 105 106 107 | |
convert_rational_value(value)
Source code in src\util.py
321 322 323 324 325 326 327 | |
convert_to_um(value, unit)
Source code in src\util.py
310 311 312 313 314 315 316 317 318 | |
create_compression_filter(compression)
Source code in src\image\util.py
399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 | |
create_transform(center, angle, matrix_size=3)
Source code in src\util.py
356 357 358 359 360 361 362 363 364 365 366 367 368 | |
create_transform0(center=(0, 0), angle=0, scale=1, translate=(0, 0))
Source code in src\util.py
348 349 350 351 352 353 | |
desc_to_dict(desc)
Source code in src\util.py
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | |
detect_area_points(image)
Source code in src\image\util.py
517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 | |
dict_to_xyz(dct, keys='xyz')
Source code in src\util.py
452 453 | |
dir_regex(pattern)
Source code in src\util.py
141 142 143 144 145 146 | |
draw_edge_filter(bounds)
Source code in src\util.py
496 497 498 499 500 501 502 503 504 | |
draw_keypoints(image, points, color=(255, 0, 0))
Source code in src\image\util.py
279 280 281 282 283 284 | |
draw_keypoints_matches(image1, points1, image2, points2, matches=None, inliers=None, points_color='black', match_color='red', inlier_color='lime', show_plot=True, output_filename=None)
Source code in src\image\util.py
348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 | |
draw_keypoints_matches_cv(image1, points1, image2, points2, matches=None, inliers=None, color=(255, 0, 0), inlier_color=(0, 255, 0), radius=15, thickness=2)
Source code in src\image\util.py
287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 | |
draw_keypoints_matches_sk(image1, points1, image2, points2, matches=None, show_plot=True, output_filename=None)
Source code in src\image\util.py
323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 | |
ensure_list(x)
Source code in src\util.py
18 19 20 21 22 23 24 | |
ensure_unsigned_image(image)
Source code in src\image\util.py
85 86 87 88 89 90 91 92 93 94 | |
ensure_unsigned_type(dtype)
Source code in src\image\util.py
78 79 80 81 82 | |
eval_context(data, key, default_value, context)
Source code in src\util.py
266 267 268 269 270 271 272 273 274 275 276 277 | |
export_csv(filename, data, header=None)
Source code in src\util.py
602 603 604 605 606 607 608 | |
export_json(filename, data)
Source code in src\util.py
591 592 593 | |
filter_dict(dict0)
Source code in src\util.py
38 39 40 41 42 43 44 45 46 47 48 49 50 | |
filter_edge_points(points, bounds, filter_factor=0.1, threshold=0.5)
Source code in src\util.py
487 488 489 490 491 492 493 | |
filter_noise_images(images)
Source code in src\image\util.py
508 509 510 511 512 513 514 | |
find_all_numbers(text)
Source code in src\util.py
149 150 | |
flatfield_correction(sims, transform_key, quantiles, foreground_map=None, cache_location=None)
Source code in src\image\flatfield.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | |
float2int_image(image, target_dtype=np.dtype(np.uint8))
Source code in src\image\util.py
59 60 61 62 63 64 65 | |
get_center(data, offset=(0, 0))
Source code in src\util.py
339 340 341 342 343 344 345 | |
get_center_from_transform(transform)
Source code in src\util.py
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 | |
get_data_mapping(data, transform_key=None, transform=None, translation0=None, rotation=None)
Source code in src\image\util.py
674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 | |
get_default(x, default)
Source code in src\util.py
14 15 | |
get_filetitle(filename)
Source code in src\util.py
135 136 137 138 | |
get_image_quantile(image, quantile, axis=None)
Source code in src\image\util.py
454 455 456 | |
get_image_size_info(sizes_xyzct, pixel_nbytes, pixel_type, channels)
Source code in src\image\util.py
152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 | |
get_image_window(image, low=0.01, high=0.99)
Source code in src\image\util.py
459 460 461 462 463 464 | |
get_max_downsamples(shape, npyramid_add, pyramid_downsample)
Source code in src\image\util.py
498 499 500 501 502 503 504 505 | |
get_mean_nn_distance(points1, points2)
Source code in src\util.py
483 484 | |
get_moments(data, offset=(0, 0))
Source code in src\util.py
330 331 332 | |
get_moments_center(moments, offset=(0, 0))
Source code in src\util.py
335 336 | |
get_nn_distance(points0)
Source code in src\util.py
472 473 474 475 476 477 478 479 480 | |
get_numpy_slicing(dimension_order, **slicing)
Source code in src\image\util.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 | |
get_orthogonal_pairs(origins, image_size_um)
Get pairs of orthogonal neighbors from a list of tiles. Tiles don't have to be placed on a regular grid.
Source code in src\util.py
507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 | |
get_properties_from_transform(transform, invert=False)
Source code in src\image\util.py
660 661 662 663 664 665 666 667 668 669 670 671 | |
get_quantile_filename(cache_location, quantile)
Source code in src\image\flatfield.py
28 29 30 | |
get_rotation_from_transform(transform)
Source code in src\util.py
427 428 429 | |
get_scale_from_transform(transform)
Source code in src\util.py
397 398 399 | |
get_sim_physical_size(sim, invert=False)
Source code in src\image\util.py
620 621 622 623 624 | |
get_sim_position_final(sim)
Source code in src\image\util.py
540 541 542 543 544 545 | |
get_sim_shape_2d(sim, transform_key=None)
Source code in src\image\util.py
640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 | |
get_translation_from_transform(transform)
Source code in src\util.py
402 403 404 405 406 | |
get_unique_file_labels(filenames)
Source code in src\util.py
179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
get_value_units_micrometer(value_units0)
Source code in src\util.py
280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 | |
grayscale_image(image)
Source code in src\image\util.py
32 33 34 35 36 37 38 39 | |
group_sims_by_z(sims)
Source code in src\image\util.py
548 549 550 551 552 553 554 555 556 557 558 559 560 561 | |
image_flatfield_correction(image0, dark, bright_dark_range, mean_bright_dark, clip=True)
Source code in src\image\flatfield.py
88 89 90 91 92 93 94 95 96 97 98 | |
image_reshape(image, target_size)
Source code in src\image\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 | |
image_resize(image, target_size0, dimension_order='yxc')
Source code in src\image\util.py
232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 | |
import_csv(filename)
Source code in src\util.py
596 597 598 599 | |
import_json(filename)
Source code in src\util.py
585 586 587 588 | |
import_metadata(content, fields=None, input_path=None)
Source code in src\util.py
568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 | |
int2float_image(image)
Source code in src\image\util.py
50 51 52 53 54 55 56 | |
norm_image_quantiles(image0, quantile=0.99)
Source code in src\image\util.py
484 485 486 487 488 489 490 491 492 493 494 495 | |
norm_image_variance(image0)
Source code in src\image\util.py
472 473 474 475 476 477 478 479 480 481 | |
normalise(sims, transform_key, use_global=True)
Source code in src\image\util.py
580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 | |
normalise_rotated_positions(positions0, rotations0, size, center)
Source code in src\util.py
456 457 458 459 460 461 462 463 464 465 466 467 468 469 | |
normalise_rotation(rotation)
Normalise rotation to be in the range [-180, 180].
Source code in src\util.py
432 433 434 435 436 437 438 439 440 | |
normalise_values(image, min_value, max_value)
Source code in src\image\util.py
467 468 469 | |
pilmode_to_pixelinfo(mode)
Source code in src\image\util.py
171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 | |
points_to_3d(points)
Source code in src\util.py
443 444 | |
precise_resize(image, factors)
Source code in src\image\util.py
272 273 274 275 276 | |
print_dict(dct, indent=0)
Source code in src\util.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | |
print_hbytes(nbytes)
Source code in src\util.py
98 99 100 101 102 103 104 105 106 107 108 109 110 | |
redimension_data(data, old_order, new_order, **indices)
Source code in src\image\util.py
110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 | |
reorder(items, old_order, new_order, default_value=0)
Source code in src\util.py
27 28 29 30 31 32 33 34 35 | |
resize_image(image, new_size)
Source code in src\image\util.py
224 225 226 227 228 229 | |
retuple(chunks, shape)
Expand chunks to match shape.
E.g. if chunks is (64, 64) and shape is (3, 4, 5, 1028, 1028) return (3, 4, 5, 64, 64)
If chunks is an integer, it is applied to all dimensions, to match the behaviour of zarr-python.
Source code in src\util.py
549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 | |
round_significants(a, significant_digits)
Source code in src\util.py
124 125 126 127 128 | |
show_image(image, title='', cmap=None)
Source code in src\image\util.py
22 23 24 25 26 27 28 29 | |
split_num_text(text)
Source code in src\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 | |
split_numeric(text)
Source code in src\util.py
153 154 155 156 157 158 159 160 | |
split_numeric_dict(text)
Source code in src\util.py
163 164 165 166 167 168 169 170 171 172 173 174 175 176 | |
split_path(path)
Source code in src\util.py
131 132 | |
split_value_unit_list(text)
Source code in src\util.py
238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 | |
uint8_image(image)
Source code in src\image\util.py
68 69 70 71 72 73 74 75 | |
validate_transform(transform, max_rotation=None)
Source code in src\util.py
382 383 384 385 386 387 388 389 390 391 392 393 394 | |
xyz_to_dict(xyz, axes='xyz')
Source code in src\util.py
447 448 449 | |
ome_helper
apply_transform(points, transform)
Source code in src\util.py
371 372 373 374 375 376 377 378 379 | |
blur_image(image, sigma)
Source code in src\image\util.py
432 433 434 435 436 437 438 439 440 | |
blur_image_single(image, sigma)
Source code in src\image\util.py
428 429 | |
calc_foreground_map(sims)
Source code in src\image\util.py
564 565 566 567 568 569 570 571 572 573 574 575 576 577 | |
calc_images_median(images)
Source code in src\image\util.py
443 444 445 446 | |
calc_images_quantiles(images, quantiles)
Source code in src\image\util.py
449 450 451 | |
calc_output_properties(sims, transform_key, z_scale=None)
Source code in src\image\util.py
627 628 629 630 631 632 633 634 635 636 637 | |
calc_pyramid(xyzct, npyramid_add=0, pyramid_downsample=2, volumetric_resize=False)
Source code in src\image\util.py
193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
check_round_significants(a, significant_digits)
Source code in src\util.py
113 114 115 116 117 118 119 120 121 | |
color_image(image)
Source code in src\image\util.py
42 43 44 45 46 47 | |
combine_transforms(transforms)
Source code in src\image\util.py
709 710 711 712 713 714 715 716 | |
convert_image_sign_type(image, target_dtype)
Source code in src\image\util.py
97 98 99 100 101 102 103 104 105 106 107 | |
convert_rational_value(value)
Source code in src\util.py
321 322 323 324 325 326 327 | |
convert_to_um(value, unit)
Source code in src\util.py
310 311 312 313 314 315 316 317 318 | |
create_compression_filter(compression)
Source code in src\image\util.py
399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 | |
create_transform(center, angle, matrix_size=3)
Source code in src\util.py
356 357 358 359 360 361 362 363 364 365 366 367 368 | |
create_transform0(center=(0, 0), angle=0, scale=1, translate=(0, 0))
Source code in src\util.py
348 349 350 351 352 353 | |
desc_to_dict(desc)
Source code in src\util.py
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | |
detect_area_points(image)
Source code in src\image\util.py
517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 | |
dict_to_xyz(dct, keys='xyz')
Source code in src\util.py
452 453 | |
dir_regex(pattern)
Source code in src\util.py
141 142 143 144 145 146 | |
draw_edge_filter(bounds)
Source code in src\util.py
496 497 498 499 500 501 502 503 504 | |
draw_keypoints(image, points, color=(255, 0, 0))
Source code in src\image\util.py
279 280 281 282 283 284 | |
draw_keypoints_matches(image1, points1, image2, points2, matches=None, inliers=None, points_color='black', match_color='red', inlier_color='lime', show_plot=True, output_filename=None)
Source code in src\image\util.py
348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 | |
draw_keypoints_matches_cv(image1, points1, image2, points2, matches=None, inliers=None, color=(255, 0, 0), inlier_color=(0, 255, 0), radius=15, thickness=2)
Source code in src\image\util.py
287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 | |
draw_keypoints_matches_sk(image1, points1, image2, points2, matches=None, show_plot=True, output_filename=None)
Source code in src\image\util.py
323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 | |
ensure_list(x)
Source code in src\util.py
18 19 20 21 22 23 24 | |
ensure_unsigned_image(image)
Source code in src\image\util.py
85 86 87 88 89 90 91 92 93 94 | |
ensure_unsigned_type(dtype)
Source code in src\image\util.py
78 79 80 81 82 | |
eval_context(data, key, default_value, context)
Source code in src\util.py
266 267 268 269 270 271 272 273 274 275 276 277 | |
exists_output_image(path, output_format)
Source code in src\image\ome_helper.py
52 53 54 55 56 57 58 | |
export_csv(filename, data, header=None)
Source code in src\util.py
602 603 604 605 606 607 608 | |
export_json(filename, data)
Source code in src\util.py
591 592 593 | |
filter_dict(dict0)
Source code in src\util.py
38 39 40 41 42 43 44 45 46 47 48 49 50 | |
filter_edge_points(points, bounds, filter_factor=0.1, threshold=0.5)
Source code in src\util.py
487 488 489 490 491 492 493 | |
filter_noise_images(images)
Source code in src\image\util.py
508 509 510 511 512 513 514 | |
find_all_numbers(text)
Source code in src\util.py
149 150 | |
float2int_image(image, target_dtype=np.dtype(np.uint8))
Source code in src\image\util.py
59 60 61 62 63 64 65 | |
get_center(data, offset=(0, 0))
Source code in src\util.py
339 340 341 342 343 344 345 | |
get_center_from_transform(transform)
Source code in src\util.py
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 | |
get_data_mapping(data, transform_key=None, transform=None, translation0=None, rotation=None)
Source code in src\image\util.py
674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 | |
get_default(x, default)
Source code in src\util.py
14 15 | |
get_filetitle(filename)
Source code in src\util.py
135 136 137 138 | |
get_image_quantile(image, quantile, axis=None)
Source code in src\image\util.py
454 455 456 | |
get_image_size_info(sizes_xyzct, pixel_nbytes, pixel_type, channels)
Source code in src\image\util.py
152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 | |
get_image_window(image, low=0.01, high=0.99)
Source code in src\image\util.py
459 460 461 462 463 464 | |
get_max_downsamples(shape, npyramid_add, pyramid_downsample)
Source code in src\image\util.py
498 499 500 501 502 503 504 505 | |
get_mean_nn_distance(points1, points2)
Source code in src\util.py
483 484 | |
get_moments(data, offset=(0, 0))
Source code in src\util.py
330 331 332 | |
get_moments_center(moments, offset=(0, 0))
Source code in src\util.py
335 336 | |
get_nn_distance(points0)
Source code in src\util.py
472 473 474 475 476 477 478 479 480 | |
get_numpy_slicing(dimension_order, **slicing)
Source code in src\image\util.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 | |
get_orthogonal_pairs(origins, image_size_um)
Get pairs of orthogonal neighbors from a list of tiles. Tiles don't have to be placed on a regular grid.
Source code in src\util.py
507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 | |
get_properties_from_transform(transform, invert=False)
Source code in src\image\util.py
660 661 662 663 664 665 666 667 668 669 670 671 | |
get_rotation_from_transform(transform)
Source code in src\util.py
427 428 429 | |
get_scale_from_transform(transform)
Source code in src\util.py
397 398 399 | |
get_sim_physical_size(sim, invert=False)
Source code in src\image\util.py
620 621 622 623 624 | |
get_sim_position_final(sim)
Source code in src\image\util.py
540 541 542 543 544 545 | |
get_sim_shape_2d(sim, transform_key=None)
Source code in src\image\util.py
640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 | |
get_translation_from_transform(transform)
Source code in src\util.py
402 403 404 405 406 | |
get_unique_file_labels(filenames)
Source code in src\util.py
179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
get_value_units_micrometer(value_units0)
Source code in src\util.py
280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 | |
grayscale_image(image)
Source code in src\image\util.py
32 33 34 35 36 37 38 39 | |
group_sims_by_z(sims)
Source code in src\image\util.py
548 549 550 551 552 553 554 555 556 557 558 559 560 561 | |
image_reshape(image, target_size)
Source code in src\image\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 | |
image_resize(image, target_size0, dimension_order='yxc')
Source code in src\image\util.py
232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 | |
import_csv(filename)
Source code in src\util.py
596 597 598 599 | |
import_json(filename)
Source code in src\util.py
585 586 587 588 | |
import_metadata(content, fields=None, input_path=None)
Source code in src\util.py
568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 | |
int2float_image(image)
Source code in src\image\util.py
50 51 52 53 54 55 56 | |
norm_image_quantiles(image0, quantile=0.99)
Source code in src\image\util.py
484 485 486 487 488 489 490 491 492 493 494 495 | |
norm_image_variance(image0)
Source code in src\image\util.py
472 473 474 475 476 477 478 479 480 481 | |
normalise(sims, transform_key, use_global=True)
Source code in src\image\util.py
580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 | |
normalise_rotated_positions(positions0, rotations0, size, center)
Source code in src\util.py
456 457 458 459 460 461 462 463 464 465 466 467 468 469 | |
normalise_rotation(rotation)
Normalise rotation to be in the range [-180, 180].
Source code in src\util.py
432 433 434 435 436 437 438 439 440 | |
normalise_values(image, min_value, max_value)
Source code in src\image\util.py
467 468 469 | |
pilmode_to_pixelinfo(mode)
Source code in src\image\util.py
171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 | |
points_to_3d(points)
Source code in src\util.py
443 444 | |
precise_resize(image, factors)
Source code in src\image\util.py
272 273 274 275 276 | |
print_dict(dct, indent=0)
Source code in src\util.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | |
print_hbytes(nbytes)
Source code in src\util.py
98 99 100 101 102 103 104 105 106 107 108 109 110 | |
redimension_data(data, old_order, new_order, **indices)
Source code in src\image\util.py
110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 | |
reorder(items, old_order, new_order, default_value=0)
Source code in src\util.py
27 28 29 30 31 32 33 34 35 | |
resize_image(image, new_size)
Source code in src\image\util.py
224 225 226 227 228 229 | |
retuple(chunks, shape)
Expand chunks to match shape.
E.g. if chunks is (64, 64) and shape is (3, 4, 5, 1028, 1028) return (3, 4, 5, 64, 64)
If chunks is an integer, it is applied to all dimensions, to match the behaviour of zarr-python.
Source code in src\util.py
549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 | |
round_significants(a, significant_digits)
Source code in src\util.py
124 125 126 127 128 | |
save_image(filename, output_format, sim, transform_key=None, channels=None, translation0=None, params={})
Source code in src\image\ome_helper.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 | |
show_image(image, title='', cmap=None)
Source code in src\image\util.py
22 23 24 25 26 27 28 29 | |
split_num_text(text)
Source code in src\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 | |
split_numeric(text)
Source code in src\util.py
153 154 155 156 157 158 159 160 | |
split_numeric_dict(text)
Source code in src\util.py
163 164 165 166 167 168 169 170 171 172 173 174 175 176 | |
split_path(path)
Source code in src\util.py
131 132 | |
split_value_unit_list(text)
Source code in src\util.py
238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 | |
uint8_image(image)
Source code in src\image\util.py
68 69 70 71 72 73 74 75 | |
validate_transform(transform, max_rotation=None)
Source code in src\util.py
382 383 384 385 386 387 388 389 390 391 392 393 394 | |
xyz_to_dict(xyz, axes='xyz')
Source code in src\util.py
447 448 449 | |
ome_ngff_helper
save_ome_ngff(filename, sim, channels=None, translation=None, rotation=None, compression=None, pyramid_downsample=2)
Source code in src\image\ome_ngff_helper.py
4 5 6 7 8 9 10 11 12 13 | |
ome_tiff_helper
apply_transform(points, transform)
Source code in src\util.py
371 372 373 374 375 376 377 378 379 | |
check_round_significants(a, significant_digits)
Source code in src\util.py
113 114 115 116 117 118 119 120 121 | |
convert_rational_value(value)
Source code in src\util.py
321 322 323 324 325 326 327 | |
convert_to_um(value, unit)
Source code in src\util.py
310 311 312 313 314 315 316 317 318 | |
create_tiff_metadata(pixel_size, dimension_order=None, channels=[], positions=[], rotation=None, is_ome=False)
Source code in src\image\ome_tiff_helper.py
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | |
create_transform(center, angle, matrix_size=3)
Source code in src\util.py
356 357 358 359 360 361 362 363 364 365 366 367 368 | |
create_transform0(center=(0, 0), angle=0, scale=1, translate=(0, 0))
Source code in src\util.py
348 349 350 351 352 353 | |
desc_to_dict(desc)
Source code in src\util.py
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | |
dict_to_xyz(dct, keys='xyz')
Source code in src\util.py
452 453 | |
dir_regex(pattern)
Source code in src\util.py
141 142 143 144 145 146 | |
draw_edge_filter(bounds)
Source code in src\util.py
496 497 498 499 500 501 502 503 504 | |
ensure_list(x)
Source code in src\util.py
18 19 20 21 22 23 24 | |
eval_context(data, key, default_value, context)
Source code in src\util.py
266 267 268 269 270 271 272 273 274 275 276 277 | |
export_csv(filename, data, header=None)
Source code in src\util.py
602 603 604 605 606 607 608 | |
export_json(filename, data)
Source code in src\util.py
591 592 593 | |
filter_dict(dict0)
Source code in src\util.py
38 39 40 41 42 43 44 45 46 47 48 49 50 | |
filter_edge_points(points, bounds, filter_factor=0.1, threshold=0.5)
Source code in src\util.py
487 488 489 490 491 492 493 | |
find_all_numbers(text)
Source code in src\util.py
149 150 | |
get_center(data, offset=(0, 0))
Source code in src\util.py
339 340 341 342 343 344 345 | |
get_center_from_transform(transform)
Source code in src\util.py
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 | |
get_default(x, default)
Source code in src\util.py
14 15 | |
get_filetitle(filename)
Source code in src\util.py
135 136 137 138 | |
get_mean_nn_distance(points1, points2)
Source code in src\util.py
483 484 | |
get_moments(data, offset=(0, 0))
Source code in src\util.py
330 331 332 | |
get_moments_center(moments, offset=(0, 0))
Source code in src\util.py
335 336 | |
get_nn_distance(points0)
Source code in src\util.py
472 473 474 475 476 477 478 479 480 | |
get_orthogonal_pairs(origins, image_size_um)
Get pairs of orthogonal neighbors from a list of tiles. Tiles don't have to be placed on a regular grid.
Source code in src\util.py
507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 | |
get_rotation_from_transform(transform)
Source code in src\util.py
427 428 429 | |
get_scale_from_transform(transform)
Source code in src\util.py
397 398 399 | |
get_translation_from_transform(transform)
Source code in src\util.py
402 403 404 405 406 | |
get_unique_file_labels(filenames)
Source code in src\util.py
179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
get_value_units_micrometer(value_units0)
Source code in src\util.py
280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 | |
import_csv(filename)
Source code in src\util.py
596 597 598 599 | |
import_json(filename)
Source code in src\util.py
585 586 587 588 | |
import_metadata(content, fields=None, input_path=None)
Source code in src\util.py
568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 | |
load_tiff(filename)
Source code in src\image\ome_tiff_helper.py
7 8 | |
normalise_rotated_positions(positions0, rotations0, size, center)
Source code in src\util.py
456 457 458 459 460 461 462 463 464 465 466 467 468 469 | |
normalise_rotation(rotation)
Normalise rotation to be in the range [-180, 180].
Source code in src\util.py
432 433 434 435 436 437 438 439 440 | |
points_to_3d(points)
Source code in src\util.py
443 444 | |
print_dict(dct, indent=0)
Source code in src\util.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | |
print_hbytes(nbytes)
Source code in src\util.py
98 99 100 101 102 103 104 105 106 107 108 109 110 | |
reorder(items, old_order, new_order, default_value=0)
Source code in src\util.py
27 28 29 30 31 32 33 34 35 | |
retuple(chunks, shape)
Expand chunks to match shape.
E.g. if chunks is (64, 64) and shape is (3, 4, 5, 1028, 1028) return (3, 4, 5, 64, 64)
If chunks is an integer, it is applied to all dimensions, to match the behaviour of zarr-python.
Source code in src\util.py
549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 | |
round_significants(a, significant_digits)
Source code in src\util.py
124 125 126 127 128 | |
save_ome_tiff(filename, data, dimension_order, pixel_size, channels=[], positions=[], rotation=None, tile_size=None, compression=None, scaler=None)
Source code in src\image\ome_tiff_helper.py
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 | |
save_tiff(filename, data, dimension_order=None, pixel_size=None, tile_size=(1024, 1024), compression='LZW')
Source code in src\image\ome_tiff_helper.py
11 12 13 14 | |
split_num_text(text)
Source code in src\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 | |
split_numeric(text)
Source code in src\util.py
153 154 155 156 157 158 159 160 | |
split_numeric_dict(text)
Source code in src\util.py
163 164 165 166 167 168 169 170 171 172 173 174 175 176 | |
split_path(path)
Source code in src\util.py
131 132 | |
split_value_unit_list(text)
Source code in src\util.py
238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 | |
validate_transform(transform, max_rotation=None)
Source code in src\util.py
382 383 384 385 386 387 388 389 390 391 392 393 394 | |
xyz_to_dict(xyz, axes='xyz')
Source code in src\util.py
447 448 449 | |
ome_zarr_helper
save_ome_zarr(filename, data, dimension_order, pixel_size, channels, translation, rotation, compression=None, scaler=None, zarr_version=2, ome_version='0.4')
Source code in src\image\ome_zarr_helper.py
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 | |
ome_zarr_util
create_axes_metadata(dimension_order)
Source code in src\image\ome_zarr_util.py
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | |
create_channel_metadata(source, ome_version)
Source code in src\image\ome_zarr_util.py
62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 | |
create_channel_ome_metadata(data, dimension_order, channels, ome_version)
Source code in src\image\ome_zarr_util.py
87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 | |
create_transformation_metadata(dimension_order, pixel_size_um, scale, translation_um=[], rotation=None)
Source code in src\image\ome_zarr_util.py
26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 | |
get_channel_window(data, dimension_order, channeli)
Source code in src\image\ome_zarr_util.py
116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 | |
hexrgb_to_rgba(hexrgb)
Source code in src\image\color_conversion.py
21 22 23 | |
int_to_rgba(intrgba)
Source code in src\image\color_conversion.py
3 4 5 6 7 8 | |
rgba_to_hexrgb(rgba)
Source code in src\image\color_conversion.py
16 17 18 | |
rgba_to_int(rgba)
Source code in src\image\color_conversion.py
11 12 13 | |
scale_dimensions_dict(shape0, scale)
Source code in src\image\ome_zarr_util.py
145 146 147 148 149 150 151 152 153 | |
scale_dimensions_xy(shape0, dimension_order, scale)
Source code in src\image\ome_zarr_util.py
134 135 136 137 138 139 140 141 142 | |
reg_util
aligned_path = 'D:/slides/12193/aligned_hpc/mappings.json'
module-attribute
aligned_transforms = import_json(aligned_path)
module-attribute
output_path = 'aligned_stitched_mappings1.json'
module-attribute
stitched_filenames = dir_regex(stitched_path)
module-attribute
stitched_path = 'D:/slides/12193/stitched_hpc/S???/mappings.json'
module-attribute
stitched_transforms = {('S' + split_numeric_dict(filename)['S']): (import_json(filename))for filename in stitched_filenames}
module-attribute
transforms2 = make_z_transforms(get_composite_transforms(stitched_transforms, aligned_transforms), to3d=True)
module-attribute
get_composite_transforms(transforms, global_transforms)
Source code in src\image\reg_util.py
7 8 9 10 11 12 13 14 15 | |
make_z_transforms(transforms, to3d=False)
Source code in src\image\reg_util.py
18 19 20 21 22 23 24 25 26 27 | |
source_helper
create_dask_data(filename, level=0)
Source code in src\image\source_helper.py
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | |
create_dask_source(filename, source_metadata=None)
Source code in src\image\source_helper.py
37 38 39 40 41 42 43 44 45 | |
get_images_metadata(filenames, source_metadata=None)
Source code in src\image\source_helper.py
48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 | |
util
apply_transform(points, transform)
Source code in src\util.py
371 372 373 374 375 376 377 378 379 | |
blur_image(image, sigma)
Source code in src\image\util.py
432 433 434 435 436 437 438 439 440 | |
blur_image_single(image, sigma)
Source code in src\image\util.py
428 429 | |
calc_foreground_map(sims)
Source code in src\image\util.py
564 565 566 567 568 569 570 571 572 573 574 575 576 577 | |
calc_images_median(images)
Source code in src\image\util.py
443 444 445 446 | |
calc_images_quantiles(images, quantiles)
Source code in src\image\util.py
449 450 451 | |
calc_output_properties(sims, transform_key, z_scale=None)
Source code in src\image\util.py
627 628 629 630 631 632 633 634 635 636 637 | |
calc_pyramid(xyzct, npyramid_add=0, pyramid_downsample=2, volumetric_resize=False)
Source code in src\image\util.py
193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
check_round_significants(a, significant_digits)
Source code in src\util.py
113 114 115 116 117 118 119 120 121 | |
color_image(image)
Source code in src\image\util.py
42 43 44 45 46 47 | |
combine_transforms(transforms)
Source code in src\image\util.py
709 710 711 712 713 714 715 716 | |
convert_image_sign_type(image, target_dtype)
Source code in src\image\util.py
97 98 99 100 101 102 103 104 105 106 107 | |
convert_rational_value(value)
Source code in src\util.py
321 322 323 324 325 326 327 | |
convert_to_um(value, unit)
Source code in src\util.py
310 311 312 313 314 315 316 317 318 | |
create_compression_filter(compression)
Source code in src\image\util.py
399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 | |
create_transform(center, angle, matrix_size=3)
Source code in src\util.py
356 357 358 359 360 361 362 363 364 365 366 367 368 | |
create_transform0(center=(0, 0), angle=0, scale=1, translate=(0, 0))
Source code in src\util.py
348 349 350 351 352 353 | |
desc_to_dict(desc)
Source code in src\util.py
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | |
detect_area_points(image)
Source code in src\image\util.py
517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 | |
dict_to_xyz(dct, keys='xyz')
Source code in src\util.py
452 453 | |
dir_regex(pattern)
Source code in src\util.py
141 142 143 144 145 146 | |
draw_edge_filter(bounds)
Source code in src\util.py
496 497 498 499 500 501 502 503 504 | |
draw_keypoints(image, points, color=(255, 0, 0))
Source code in src\image\util.py
279 280 281 282 283 284 | |
draw_keypoints_matches(image1, points1, image2, points2, matches=None, inliers=None, points_color='black', match_color='red', inlier_color='lime', show_plot=True, output_filename=None)
Source code in src\image\util.py
348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 | |
draw_keypoints_matches_cv(image1, points1, image2, points2, matches=None, inliers=None, color=(255, 0, 0), inlier_color=(0, 255, 0), radius=15, thickness=2)
Source code in src\image\util.py
287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 | |
draw_keypoints_matches_sk(image1, points1, image2, points2, matches=None, show_plot=True, output_filename=None)
Source code in src\image\util.py
323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 | |
ensure_list(x)
Source code in src\util.py
18 19 20 21 22 23 24 | |
ensure_unsigned_image(image)
Source code in src\image\util.py
85 86 87 88 89 90 91 92 93 94 | |
ensure_unsigned_type(dtype)
Source code in src\image\util.py
78 79 80 81 82 | |
eval_context(data, key, default_value, context)
Source code in src\util.py
266 267 268 269 270 271 272 273 274 275 276 277 | |
export_csv(filename, data, header=None)
Source code in src\util.py
602 603 604 605 606 607 608 | |
export_json(filename, data)
Source code in src\util.py
591 592 593 | |
filter_dict(dict0)
Source code in src\util.py
38 39 40 41 42 43 44 45 46 47 48 49 50 | |
filter_edge_points(points, bounds, filter_factor=0.1, threshold=0.5)
Source code in src\util.py
487 488 489 490 491 492 493 | |
filter_noise_images(images)
Source code in src\image\util.py
508 509 510 511 512 513 514 | |
find_all_numbers(text)
Source code in src\util.py
149 150 | |
float2int_image(image, target_dtype=np.dtype(np.uint8))
Source code in src\image\util.py
59 60 61 62 63 64 65 | |
get_center(data, offset=(0, 0))
Source code in src\util.py
339 340 341 342 343 344 345 | |
get_center_from_transform(transform)
Source code in src\util.py
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 | |
get_data_mapping(data, transform_key=None, transform=None, translation0=None, rotation=None)
Source code in src\image\util.py
674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 | |
get_default(x, default)
Source code in src\util.py
14 15 | |
get_filetitle(filename)
Source code in src\util.py
135 136 137 138 | |
get_image_quantile(image, quantile, axis=None)
Source code in src\image\util.py
454 455 456 | |
get_image_size_info(sizes_xyzct, pixel_nbytes, pixel_type, channels)
Source code in src\image\util.py
152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 | |
get_image_window(image, low=0.01, high=0.99)
Source code in src\image\util.py
459 460 461 462 463 464 | |
get_max_downsamples(shape, npyramid_add, pyramid_downsample)
Source code in src\image\util.py
498 499 500 501 502 503 504 505 | |
get_mean_nn_distance(points1, points2)
Source code in src\util.py
483 484 | |
get_moments(data, offset=(0, 0))
Source code in src\util.py
330 331 332 | |
get_moments_center(moments, offset=(0, 0))
Source code in src\util.py
335 336 | |
get_nn_distance(points0)
Source code in src\util.py
472 473 474 475 476 477 478 479 480 | |
get_numpy_slicing(dimension_order, **slicing)
Source code in src\image\util.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 | |
get_orthogonal_pairs(origins, image_size_um)
Get pairs of orthogonal neighbors from a list of tiles. Tiles don't have to be placed on a regular grid.
Source code in src\util.py
507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 | |
get_properties_from_transform(transform, invert=False)
Source code in src\image\util.py
660 661 662 663 664 665 666 667 668 669 670 671 | |
get_rotation_from_transform(transform)
Source code in src\util.py
427 428 429 | |
get_scale_from_transform(transform)
Source code in src\util.py
397 398 399 | |
get_sim_physical_size(sim, invert=False)
Source code in src\image\util.py
620 621 622 623 624 | |
get_sim_position_final(sim)
Source code in src\image\util.py
540 541 542 543 544 545 | |
get_sim_shape_2d(sim, transform_key=None)
Source code in src\image\util.py
640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 | |
get_translation_from_transform(transform)
Source code in src\util.py
402 403 404 405 406 | |
get_unique_file_labels(filenames)
Source code in src\util.py
179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
get_value_units_micrometer(value_units0)
Source code in src\util.py
280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 | |
grayscale_image(image)
Source code in src\image\util.py
32 33 34 35 36 37 38 39 | |
group_sims_by_z(sims)
Source code in src\image\util.py
548 549 550 551 552 553 554 555 556 557 558 559 560 561 | |
image_reshape(image, target_size)
Source code in src\image\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 | |
image_resize(image, target_size0, dimension_order='yxc')
Source code in src\image\util.py
232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 | |
import_csv(filename)
Source code in src\util.py
596 597 598 599 | |
import_json(filename)
Source code in src\util.py
585 586 587 588 | |
import_metadata(content, fields=None, input_path=None)
Source code in src\util.py
568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 | |
int2float_image(image)
Source code in src\image\util.py
50 51 52 53 54 55 56 | |
norm_image_quantiles(image0, quantile=0.99)
Source code in src\image\util.py
484 485 486 487 488 489 490 491 492 493 494 495 | |
norm_image_variance(image0)
Source code in src\image\util.py
472 473 474 475 476 477 478 479 480 481 | |
normalise(sims, transform_key, use_global=True)
Source code in src\image\util.py
580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 | |
normalise_rotated_positions(positions0, rotations0, size, center)
Source code in src\util.py
456 457 458 459 460 461 462 463 464 465 466 467 468 469 | |
normalise_rotation(rotation)
Normalise rotation to be in the range [-180, 180].
Source code in src\util.py
432 433 434 435 436 437 438 439 440 | |
normalise_values(image, min_value, max_value)
Source code in src\image\util.py
467 468 469 | |
pilmode_to_pixelinfo(mode)
Source code in src\image\util.py
171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 | |
points_to_3d(points)
Source code in src\util.py
443 444 | |
precise_resize(image, factors)
Source code in src\image\util.py
272 273 274 275 276 | |
print_dict(dct, indent=0)
Source code in src\util.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | |
print_hbytes(nbytes)
Source code in src\util.py
98 99 100 101 102 103 104 105 106 107 108 109 110 | |
redimension_data(data, old_order, new_order, **indices)
Source code in src\image\util.py
110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 | |
reorder(items, old_order, new_order, default_value=0)
Source code in src\util.py
27 28 29 30 31 32 33 34 35 | |
resize_image(image, new_size)
Source code in src\image\util.py
224 225 226 227 228 229 | |
retuple(chunks, shape)
Expand chunks to match shape.
E.g. if chunks is (64, 64) and shape is (3, 4, 5, 1028, 1028) return (3, 4, 5, 64, 64)
If chunks is an integer, it is applied to all dimensions, to match the behaviour of zarr-python.
Source code in src\util.py
549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 | |
round_significants(a, significant_digits)
Source code in src\util.py
124 125 126 127 128 | |
show_image(image, title='', cmap=None)
Source code in src\image\util.py
22 23 24 25 26 27 28 29 | |
split_num_text(text)
Source code in src\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 | |
split_numeric(text)
Source code in src\util.py
153 154 155 156 157 158 159 160 | |
split_numeric_dict(text)
Source code in src\util.py
163 164 165 166 167 168 169 170 171 172 173 174 175 176 | |
split_path(path)
Source code in src\util.py
131 132 | |
split_value_unit_list(text)
Source code in src\util.py
238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 | |
uint8_image(image)
Source code in src\image\util.py
68 69 70 71 72 73 74 75 | |
validate_transform(transform, max_rotation=None)
Source code in src\util.py
382 383 384 385 386 387 388 389 390 391 392 393 394 | |
xyz_to_dict(xyz, axes='xyz')
Source code in src\util.py
447 448 449 | |
metrics
calc_frc(image1, image2)
Source code in src\metrics.py
100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 | |
calc_match_metrics(points1, points2, transform, threshold, lowe_ratio=None)
Source code in src\metrics.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | |
calc_ncc(image1, image2)
Source code in src\metrics.py
63 64 65 66 67 68 69 70 71 | |
calc_ncc2(image1, image2)
Source code in src\metrics.py
74 75 76 77 78 79 80 81 82 83 84 | |
calc_ssim(image1, image2)
Source code in src\metrics.py
87 88 89 90 91 92 93 94 95 96 97 | |
registration_methods
RegistrationMethod
RegistrationMethod
Bases: ABC
Source code in src\registration_methods\RegistrationMethod.py
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | |
count = 0
instance-attribute
debug = debug
instance-attribute
full_size = si_utils.get_shape_from_sim(source, asarray=True)
instance-attribute
ndims = 2 + int('z' in source.dims)
instance-attribute
params = params
instance-attribute
source_type = source.dtype
instance-attribute
__init__(source, params, debug=False)
Source code in src\registration_methods\RegistrationMethod.py
8 9 10 11 12 13 14 15 16 17 18 | |
convert_data_to_float(data)
Source code in src\registration_methods\RegistrationMethod.py
20 21 22 | |
registration(fixed_data, moving_data, **kwargs)
abstractmethod
Source code in src\registration_methods\RegistrationMethod.py
24 25 26 27 28 29 30 31 32 | |
RegistrationMethodANTs3Din2D
RegistrationMethodANTs3Din2D
Bases: RegistrationMethod
Source code in src\registration_methods\RegistrationMethodANTs3Din2D.py
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | |
__init__(source, params, debug)
Source code in src\registration_methods\RegistrationMethodANTs3Din2D.py
8 9 | |
registration(fixed_data, moving_data, *, fixed_origin, moving_origin, fixed_spacing, moving_spacing, initial_affine, transform_types=None, **ants_registration_kwargs)
Register two 3d sims by projecting them to 2d and using 2d registration. The z component of the resulting affine matrix is set to identity.
Source code in src\registration_methods\RegistrationMethodANTs3Din2D.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | |
RegistrationMethodCPD
RegistrationMethodCPD
Bases: RegistrationMethod
Source code in src\registration_methods\RegistrationMethodCPD.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | |
detect_points(data0)
Source code in src\registration_methods\RegistrationMethodCPD.py
13 14 15 16 17 | |
registration(fixed_data, moving_data, **kwargs)
Source code in src\registration_methods\RegistrationMethodCPD.py
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | |
apply_transform(points, transform)
Source code in src\util.py
371 372 373 374 375 376 377 378 379 | |
blur_image(image, sigma)
Source code in src\image\util.py
432 433 434 435 436 437 438 439 440 | |
blur_image_single(image, sigma)
Source code in src\image\util.py
428 429 | |
calc_foreground_map(sims)
Source code in src\image\util.py
564 565 566 567 568 569 570 571 572 573 574 575 576 577 | |
calc_images_median(images)
Source code in src\image\util.py
443 444 445 446 | |
calc_images_quantiles(images, quantiles)
Source code in src\image\util.py
449 450 451 | |
calc_output_properties(sims, transform_key, z_scale=None)
Source code in src\image\util.py
627 628 629 630 631 632 633 634 635 636 637 | |
calc_pyramid(xyzct, npyramid_add=0, pyramid_downsample=2, volumetric_resize=False)
Source code in src\image\util.py
193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
check_round_significants(a, significant_digits)
Source code in src\util.py
113 114 115 116 117 118 119 120 121 | |
color_image(image)
Source code in src\image\util.py
42 43 44 45 46 47 | |
combine_transforms(transforms)
Source code in src\image\util.py
709 710 711 712 713 714 715 716 | |
convert_image_sign_type(image, target_dtype)
Source code in src\image\util.py
97 98 99 100 101 102 103 104 105 106 107 | |
convert_rational_value(value)
Source code in src\util.py
321 322 323 324 325 326 327 | |
convert_to_um(value, unit)
Source code in src\util.py
310 311 312 313 314 315 316 317 318 | |
create_compression_filter(compression)
Source code in src\image\util.py
399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 | |
create_transform(center, angle, matrix_size=3)
Source code in src\util.py
356 357 358 359 360 361 362 363 364 365 366 367 368 | |
create_transform0(center=(0, 0), angle=0, scale=1, translate=(0, 0))
Source code in src\util.py
348 349 350 351 352 353 | |
desc_to_dict(desc)
Source code in src\util.py
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | |
detect_area_points(image)
Source code in src\image\util.py
517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 | |
dict_to_xyz(dct, keys='xyz')
Source code in src\util.py
452 453 | |
dir_regex(pattern)
Source code in src\util.py
141 142 143 144 145 146 | |
draw_edge_filter(bounds)
Source code in src\util.py
496 497 498 499 500 501 502 503 504 | |
draw_keypoints(image, points, color=(255, 0, 0))
Source code in src\image\util.py
279 280 281 282 283 284 | |
draw_keypoints_matches(image1, points1, image2, points2, matches=None, inliers=None, points_color='black', match_color='red', inlier_color='lime', show_plot=True, output_filename=None)
Source code in src\image\util.py
348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 | |
draw_keypoints_matches_cv(image1, points1, image2, points2, matches=None, inliers=None, color=(255, 0, 0), inlier_color=(0, 255, 0), radius=15, thickness=2)
Source code in src\image\util.py
287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 | |
draw_keypoints_matches_sk(image1, points1, image2, points2, matches=None, show_plot=True, output_filename=None)
Source code in src\image\util.py
323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 | |
ensure_list(x)
Source code in src\util.py
18 19 20 21 22 23 24 | |
ensure_unsigned_image(image)
Source code in src\image\util.py
85 86 87 88 89 90 91 92 93 94 | |
ensure_unsigned_type(dtype)
Source code in src\image\util.py
78 79 80 81 82 | |
eval_context(data, key, default_value, context)
Source code in src\util.py
266 267 268 269 270 271 272 273 274 275 276 277 | |
export_csv(filename, data, header=None)
Source code in src\util.py
602 603 604 605 606 607 608 | |
export_json(filename, data)
Source code in src\util.py
591 592 593 | |
filter_dict(dict0)
Source code in src\util.py
38 39 40 41 42 43 44 45 46 47 48 49 50 | |
filter_edge_points(points, bounds, filter_factor=0.1, threshold=0.5)
Source code in src\util.py
487 488 489 490 491 492 493 | |
filter_noise_images(images)
Source code in src\image\util.py
508 509 510 511 512 513 514 | |
find_all_numbers(text)
Source code in src\util.py
149 150 | |
float2int_image(image, target_dtype=np.dtype(np.uint8))
Source code in src\image\util.py
59 60 61 62 63 64 65 | |
get_center(data, offset=(0, 0))
Source code in src\util.py
339 340 341 342 343 344 345 | |
get_center_from_transform(transform)
Source code in src\util.py
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 | |
get_data_mapping(data, transform_key=None, transform=None, translation0=None, rotation=None)
Source code in src\image\util.py
674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 | |
get_default(x, default)
Source code in src\util.py
14 15 | |
get_filetitle(filename)
Source code in src\util.py
135 136 137 138 | |
get_image_quantile(image, quantile, axis=None)
Source code in src\image\util.py
454 455 456 | |
get_image_size_info(sizes_xyzct, pixel_nbytes, pixel_type, channels)
Source code in src\image\util.py
152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 | |
get_image_window(image, low=0.01, high=0.99)
Source code in src\image\util.py
459 460 461 462 463 464 | |
get_max_downsamples(shape, npyramid_add, pyramid_downsample)
Source code in src\image\util.py
498 499 500 501 502 503 504 505 | |
get_mean_nn_distance(points1, points2)
Source code in src\util.py
483 484 | |
get_moments(data, offset=(0, 0))
Source code in src\util.py
330 331 332 | |
get_moments_center(moments, offset=(0, 0))
Source code in src\util.py
335 336 | |
get_nn_distance(points0)
Source code in src\util.py
472 473 474 475 476 477 478 479 480 | |
get_numpy_slicing(dimension_order, **slicing)
Source code in src\image\util.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 | |
get_orthogonal_pairs(origins, image_size_um)
Get pairs of orthogonal neighbors from a list of tiles. Tiles don't have to be placed on a regular grid.
Source code in src\util.py
507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 | |
get_properties_from_transform(transform, invert=False)
Source code in src\image\util.py
660 661 662 663 664 665 666 667 668 669 670 671 | |
get_rotation_from_transform(transform)
Source code in src\util.py
427 428 429 | |
get_scale_from_transform(transform)
Source code in src\util.py
397 398 399 | |
get_sim_physical_size(sim, invert=False)
Source code in src\image\util.py
620 621 622 623 624 | |
get_sim_position_final(sim)
Source code in src\image\util.py
540 541 542 543 544 545 | |
get_sim_shape_2d(sim, transform_key=None)
Source code in src\image\util.py
640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 | |
get_translation_from_transform(transform)
Source code in src\util.py
402 403 404 405 406 | |
get_unique_file_labels(filenames)
Source code in src\util.py
179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
get_value_units_micrometer(value_units0)
Source code in src\util.py
280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 | |
grayscale_image(image)
Source code in src\image\util.py
32 33 34 35 36 37 38 39 | |
group_sims_by_z(sims)
Source code in src\image\util.py
548 549 550 551 552 553 554 555 556 557 558 559 560 561 | |
image_reshape(image, target_size)
Source code in src\image\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 | |
image_resize(image, target_size0, dimension_order='yxc')
Source code in src\image\util.py
232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 | |
import_csv(filename)
Source code in src\util.py
596 597 598 599 | |
import_json(filename)
Source code in src\util.py
585 586 587 588 | |
import_metadata(content, fields=None, input_path=None)
Source code in src\util.py
568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 | |
int2float_image(image)
Source code in src\image\util.py
50 51 52 53 54 55 56 | |
norm_image_quantiles(image0, quantile=0.99)
Source code in src\image\util.py
484 485 486 487 488 489 490 491 492 493 494 495 | |
norm_image_variance(image0)
Source code in src\image\util.py
472 473 474 475 476 477 478 479 480 481 | |
normalise(sims, transform_key, use_global=True)
Source code in src\image\util.py
580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 | |
normalise_rotated_positions(positions0, rotations0, size, center)
Source code in src\util.py
456 457 458 459 460 461 462 463 464 465 466 467 468 469 | |
normalise_rotation(rotation)
Normalise rotation to be in the range [-180, 180].
Source code in src\util.py
432 433 434 435 436 437 438 439 440 | |
normalise_values(image, min_value, max_value)
Source code in src\image\util.py
467 468 469 | |
pilmode_to_pixelinfo(mode)
Source code in src\image\util.py
171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 | |
precise_resize(image, factors)
Source code in src\image\util.py
272 273 274 275 276 | |
print_dict(dct, indent=0)
Source code in src\util.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | |
print_hbytes(nbytes)
Source code in src\util.py
98 99 100 101 102 103 104 105 106 107 108 109 110 | |
redimension_data(data, old_order, new_order, **indices)
Source code in src\image\util.py
110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 | |
reorder(items, old_order, new_order, default_value=0)
Source code in src\util.py
27 28 29 30 31 32 33 34 35 | |
resize_image(image, new_size)
Source code in src\image\util.py
224 225 226 227 228 229 | |
retuple(chunks, shape)
Expand chunks to match shape.
E.g. if chunks is (64, 64) and shape is (3, 4, 5, 1028, 1028) return (3, 4, 5, 64, 64)
If chunks is an integer, it is applied to all dimensions, to match the behaviour of zarr-python.
Source code in src\util.py
549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 | |
round_significants(a, significant_digits)
Source code in src\util.py
124 125 126 127 128 | |
show_image(image, title='', cmap=None)
Source code in src\image\util.py
22 23 24 25 26 27 28 29 | |
split_num_text(text)
Source code in src\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 | |
split_numeric(text)
Source code in src\util.py
153 154 155 156 157 158 159 160 | |
split_numeric_dict(text)
Source code in src\util.py
163 164 165 166 167 168 169 170 171 172 173 174 175 176 | |
split_path(path)
Source code in src\util.py
131 132 | |
split_value_unit_list(text)
Source code in src\util.py
238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 | |
uint8_image(image)
Source code in src\image\util.py
68 69 70 71 72 73 74 75 | |
validate_transform(transform, max_rotation=None)
Source code in src\util.py
382 383 384 385 386 387 388 389 390 391 392 393 394 | |
xyz_to_dict(xyz, axes='xyz')
Source code in src\util.py
447 448 449 | |
RegistrationMethodCvFeatures
RegistrationMethodCvFeatures
Bases: RegistrationMethod
Source code in src\registration_methods\RegistrationMethodCvFeatures.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 | |
detect_features(data0)
Source code in src\registration_methods\RegistrationMethodCvFeatures.py
14 15 16 17 18 19 20 21 22 23 24 | |
registration(fixed_data, moving_data, **kwargs)
Source code in src\registration_methods\RegistrationMethodCvFeatures.py
26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 | |
RegistrationMethodDummy
RegistrationMethodDummy
Bases: RegistrationMethod
Source code in src\registration_methods\RegistrationMethodDummy.py
8 9 10 11 12 13 14 15 16 17 | |
registration(fixed_data, moving_data, **kwargs)
Source code in src\registration_methods\RegistrationMethodDummy.py
9 10 11 12 13 14 15 16 17 | |
RegistrationMethodSkFeatures
RegistrationMethodSkFeatures
Bases: RegistrationMethod
Source code in src\registration_methods\RegistrationMethodSkFeatures.py
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 | |
cross_check = params.get('cross_check', True)
instance-attribute
downscale_factor = params.get('downscale_factor', params.get('downscale', np.sqrt(2)))
instance-attribute
full_size_gaussian_sigma = params.get('gaussian_sigma', params.get('sigma', 1))
instance-attribute
inlier_threshold_factor = params.get('inlier_threshold_factor', 0.05)
instance-attribute
lowe_ratio = params.get('lowe_ratio', 0.92)
instance-attribute
max_rotation = 10
instance-attribute
max_trails = params.get('max_trials', 100)
instance-attribute
method = params.get('name', 'sift').lower()
instance-attribute
min_matches = params.get('min_matches', 10)
instance-attribute
nkeypoints = params.get('nkeypoints', 5000)
instance-attribute
ransac_iterations = params.get('ransac_iterations', 10)
instance-attribute
transform_type = AffineTransform
instance-attribute
__init__(source, params, debug=False)
Source code in src\registration_methods\RegistrationMethodSkFeatures.py
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | |
detect_features(data0, gaussian_sigma=None)
Source code in src\registration_methods\RegistrationMethodSkFeatures.py
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 | |
match(fixed_points, fixed_desc, moving_points, moving_desc, min_matches, cross_check, lowe_ratio, inlier_threshold, mean_size_dist)
Source code in src\registration_methods\RegistrationMethodSkFeatures.py
90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 | |
registration(fixed_data, moving_data, **kwargs)
Source code in src\registration_methods\RegistrationMethodSkFeatures.py
160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 | |
registration_physical_space(fixed_data, moving_data, *, fixed_origin, moving_origin, fixed_spacing, moving_spacing, initial_affine, transform_types=None, **ants_registration_kwargs)
Source code in src\registration_methods\RegistrationMethodSkFeatures.py
141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 | |
apply_transform(points, transform)
Source code in src\util.py
371 372 373 374 375 376 377 378 379 | |
blur_image(image, sigma)
Source code in src\image\util.py
432 433 434 435 436 437 438 439 440 | |
blur_image_single(image, sigma)
Source code in src\image\util.py
428 429 | |
calc_foreground_map(sims)
Source code in src\image\util.py
564 565 566 567 568 569 570 571 572 573 574 575 576 577 | |
calc_images_median(images)
Source code in src\image\util.py
443 444 445 446 | |
calc_images_quantiles(images, quantiles)
Source code in src\image\util.py
449 450 451 | |
calc_output_properties(sims, transform_key, z_scale=None)
Source code in src\image\util.py
627 628 629 630 631 632 633 634 635 636 637 | |
calc_pyramid(xyzct, npyramid_add=0, pyramid_downsample=2, volumetric_resize=False)
Source code in src\image\util.py
193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
check_round_significants(a, significant_digits)
Source code in src\util.py
113 114 115 116 117 118 119 120 121 | |
color_image(image)
Source code in src\image\util.py
42 43 44 45 46 47 | |
combine_transforms(transforms)
Source code in src\image\util.py
709 710 711 712 713 714 715 716 | |
convert_image_sign_type(image, target_dtype)
Source code in src\image\util.py
97 98 99 100 101 102 103 104 105 106 107 | |
convert_rational_value(value)
Source code in src\util.py
321 322 323 324 325 326 327 | |
convert_to_um(value, unit)
Source code in src\util.py
310 311 312 313 314 315 316 317 318 | |
create_compression_filter(compression)
Source code in src\image\util.py
399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 | |
create_transform(center, angle, matrix_size=3)
Source code in src\util.py
356 357 358 359 360 361 362 363 364 365 366 367 368 | |
create_transform0(center=(0, 0), angle=0, scale=1, translate=(0, 0))
Source code in src\util.py
348 349 350 351 352 353 | |
desc_to_dict(desc)
Source code in src\util.py
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | |
detect_area_points(image)
Source code in src\image\util.py
517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 | |
dict_to_xyz(dct, keys='xyz')
Source code in src\util.py
452 453 | |
dir_regex(pattern)
Source code in src\util.py
141 142 143 144 145 146 | |
draw_edge_filter(bounds)
Source code in src\util.py
496 497 498 499 500 501 502 503 504 | |
draw_keypoints(image, points, color=(255, 0, 0))
Source code in src\image\util.py
279 280 281 282 283 284 | |
draw_keypoints_matches(image1, points1, image2, points2, matches=None, inliers=None, points_color='black', match_color='red', inlier_color='lime', show_plot=True, output_filename=None)
Source code in src\image\util.py
348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 | |
draw_keypoints_matches_cv(image1, points1, image2, points2, matches=None, inliers=None, color=(255, 0, 0), inlier_color=(0, 255, 0), radius=15, thickness=2)
Source code in src\image\util.py
287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 | |
draw_keypoints_matches_sk(image1, points1, image2, points2, matches=None, show_plot=True, output_filename=None)
Source code in src\image\util.py
323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 | |
ensure_list(x)
Source code in src\util.py
18 19 20 21 22 23 24 | |
ensure_unsigned_image(image)
Source code in src\image\util.py
85 86 87 88 89 90 91 92 93 94 | |
ensure_unsigned_type(dtype)
Source code in src\image\util.py
78 79 80 81 82 | |
eval_context(data, key, default_value, context)
Source code in src\util.py
266 267 268 269 270 271 272 273 274 275 276 277 | |
export_csv(filename, data, header=None)
Source code in src\util.py
602 603 604 605 606 607 608 | |
export_json(filename, data)
Source code in src\util.py
591 592 593 | |
filter_dict(dict0)
Source code in src\util.py
38 39 40 41 42 43 44 45 46 47 48 49 50 | |
filter_edge_points(points, bounds, filter_factor=0.1, threshold=0.5)
Source code in src\util.py
487 488 489 490 491 492 493 | |
filter_noise_images(images)
Source code in src\image\util.py
508 509 510 511 512 513 514 | |
find_all_numbers(text)
Source code in src\util.py
149 150 | |
float2int_image(image, target_dtype=np.dtype(np.uint8))
Source code in src\image\util.py
59 60 61 62 63 64 65 | |
get_center(data, offset=(0, 0))
Source code in src\util.py
339 340 341 342 343 344 345 | |
get_center_from_transform(transform)
Source code in src\util.py
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 | |
get_data_mapping(data, transform_key=None, transform=None, translation0=None, rotation=None)
Source code in src\image\util.py
674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 | |
get_default(x, default)
Source code in src\util.py
14 15 | |
get_filetitle(filename)
Source code in src\util.py
135 136 137 138 | |
get_image_quantile(image, quantile, axis=None)
Source code in src\image\util.py
454 455 456 | |
get_image_size_info(sizes_xyzct, pixel_nbytes, pixel_type, channels)
Source code in src\image\util.py
152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 | |
get_image_window(image, low=0.01, high=0.99)
Source code in src\image\util.py
459 460 461 462 463 464 | |
get_max_downsamples(shape, npyramid_add, pyramid_downsample)
Source code in src\image\util.py
498 499 500 501 502 503 504 505 | |
get_mean_nn_distance(points1, points2)
Source code in src\util.py
483 484 | |
get_moments(data, offset=(0, 0))
Source code in src\util.py
330 331 332 | |
get_moments_center(moments, offset=(0, 0))
Source code in src\util.py
335 336 | |
get_nn_distance(points0)
Source code in src\util.py
472 473 474 475 476 477 478 479 480 | |
get_numpy_slicing(dimension_order, **slicing)
Source code in src\image\util.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 | |
get_orthogonal_pairs(origins, image_size_um)
Get pairs of orthogonal neighbors from a list of tiles. Tiles don't have to be placed on a regular grid.
Source code in src\util.py
507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 | |
get_properties_from_transform(transform, invert=False)
Source code in src\image\util.py
660 661 662 663 664 665 666 667 668 669 670 671 | |
get_rotation_from_transform(transform)
Source code in src\util.py
427 428 429 | |
get_scale_from_transform(transform)
Source code in src\util.py
397 398 399 | |
get_sim_physical_size(sim, invert=False)
Source code in src\image\util.py
620 621 622 623 624 | |
get_sim_position_final(sim)
Source code in src\image\util.py
540 541 542 543 544 545 | |
get_sim_shape_2d(sim, transform_key=None)
Source code in src\image\util.py
640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 | |
get_translation_from_transform(transform)
Source code in src\util.py
402 403 404 405 406 | |
get_unique_file_labels(filenames)
Source code in src\util.py
179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
get_value_units_micrometer(value_units0)
Source code in src\util.py
280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 | |
grayscale_image(image)
Source code in src\image\util.py
32 33 34 35 36 37 38 39 | |
group_sims_by_z(sims)
Source code in src\image\util.py
548 549 550 551 552 553 554 555 556 557 558 559 560 561 | |
image_reshape(image, target_size)
Source code in src\image\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 | |
image_resize(image, target_size0, dimension_order='yxc')
Source code in src\image\util.py
232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 | |
import_csv(filename)
Source code in src\util.py
596 597 598 599 | |
import_json(filename)
Source code in src\util.py
585 586 587 588 | |
import_metadata(content, fields=None, input_path=None)
Source code in src\util.py
568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 | |
int2float_image(image)
Source code in src\image\util.py
50 51 52 53 54 55 56 | |
norm_image_quantiles(image0, quantile=0.99)
Source code in src\image\util.py
484 485 486 487 488 489 490 491 492 493 494 495 | |
norm_image_variance(image0)
Source code in src\image\util.py
472 473 474 475 476 477 478 479 480 481 | |
normalise(sims, transform_key, use_global=True)
Source code in src\image\util.py
580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 | |
normalise_rotated_positions(positions0, rotations0, size, center)
Source code in src\util.py
456 457 458 459 460 461 462 463 464 465 466 467 468 469 | |
normalise_rotation(rotation)
Normalise rotation to be in the range [-180, 180].
Source code in src\util.py
432 433 434 435 436 437 438 439 440 | |
normalise_values(image, min_value, max_value)
Source code in src\image\util.py
467 468 469 | |
pilmode_to_pixelinfo(mode)
Source code in src\image\util.py
171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 | |
points_to_3d(points)
Source code in src\util.py
443 444 | |
precise_resize(image, factors)
Source code in src\image\util.py
272 273 274 275 276 | |
print_dict(dct, indent=0)
Source code in src\util.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | |
print_hbytes(nbytes)
Source code in src\util.py
98 99 100 101 102 103 104 105 106 107 108 109 110 | |
redimension_data(data, old_order, new_order, **indices)
Source code in src\image\util.py
110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 | |
reorder(items, old_order, new_order, default_value=0)
Source code in src\util.py
27 28 29 30 31 32 33 34 35 | |
resize_image(image, new_size)
Source code in src\image\util.py
224 225 226 227 228 229 | |
retuple(chunks, shape)
Expand chunks to match shape.
E.g. if chunks is (64, 64) and shape is (3, 4, 5, 1028, 1028) return (3, 4, 5, 64, 64)
If chunks is an integer, it is applied to all dimensions, to match the behaviour of zarr-python.
Source code in src\util.py
549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 | |
round_significants(a, significant_digits)
Source code in src\util.py
124 125 126 127 128 | |
show_image(image, title='', cmap=None)
Source code in src\image\util.py
22 23 24 25 26 27 28 29 | |
split_num_text(text)
Source code in src\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 | |
split_numeric(text)
Source code in src\util.py
153 154 155 156 157 158 159 160 | |
split_numeric_dict(text)
Source code in src\util.py
163 164 165 166 167 168 169 170 171 172 173 174 175 176 | |
split_path(path)
Source code in src\util.py
131 132 | |
split_value_unit_list(text)
Source code in src\util.py
238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 | |
uint8_image(image)
Source code in src\image\util.py
68 69 70 71 72 73 74 75 | |
validate_transform(transform, max_rotation=None)
Source code in src\util.py
382 383 384 385 386 387 388 389 390 391 392 393 394 | |
xyz_to_dict(xyz, axes='xyz')
Source code in src\util.py
447 448 449 | |
RegistrationMetrics
RegistrationMetrics
Bases: RegistrationMethod
Source code in src\registration_methods\RegistrationMetrics.py
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | |
nccs = []
instance-attribute
reg_function = reg_function
instance-attribute
ssims = []
instance-attribute
__init__(source_type, reg_function)
Source code in src\registration_methods\RegistrationMetrics.py
8 9 10 11 12 | |
registration(fixed_data, moving_data, **kwargs)
Source code in src\registration_methods\RegistrationMetrics.py
14 15 16 17 18 19 20 21 22 23 | |
util
apply_transform(points, transform)
Source code in src\util.py
371 372 373 374 375 376 377 378 379 | |
check_round_significants(a, significant_digits)
Source code in src\util.py
113 114 115 116 117 118 119 120 121 | |
convert_rational_value(value)
Source code in src\util.py
321 322 323 324 325 326 327 | |
convert_to_um(value, unit)
Source code in src\util.py
310 311 312 313 314 315 316 317 318 | |
create_transform(center, angle, matrix_size=3)
Source code in src\util.py
356 357 358 359 360 361 362 363 364 365 366 367 368 | |
create_transform0(center=(0, 0), angle=0, scale=1, translate=(0, 0))
Source code in src\util.py
348 349 350 351 352 353 | |
desc_to_dict(desc)
Source code in src\util.py
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | |
dict_to_xyz(dct, keys='xyz')
Source code in src\util.py
452 453 | |
dir_regex(pattern)
Source code in src\util.py
141 142 143 144 145 146 | |
draw_edge_filter(bounds)
Source code in src\util.py
496 497 498 499 500 501 502 503 504 | |
ensure_list(x)
Source code in src\util.py
18 19 20 21 22 23 24 | |
eval_context(data, key, default_value, context)
Source code in src\util.py
266 267 268 269 270 271 272 273 274 275 276 277 | |
export_csv(filename, data, header=None)
Source code in src\util.py
602 603 604 605 606 607 608 | |
export_json(filename, data)
Source code in src\util.py
591 592 593 | |
filter_dict(dict0)
Source code in src\util.py
38 39 40 41 42 43 44 45 46 47 48 49 50 | |
filter_edge_points(points, bounds, filter_factor=0.1, threshold=0.5)
Source code in src\util.py
487 488 489 490 491 492 493 | |
find_all_numbers(text)
Source code in src\util.py
149 150 | |
get_center(data, offset=(0, 0))
Source code in src\util.py
339 340 341 342 343 344 345 | |
get_center_from_transform(transform)
Source code in src\util.py
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 | |
get_default(x, default)
Source code in src\util.py
14 15 | |
get_filetitle(filename)
Source code in src\util.py
135 136 137 138 | |
get_mean_nn_distance(points1, points2)
Source code in src\util.py
483 484 | |
get_moments(data, offset=(0, 0))
Source code in src\util.py
330 331 332 | |
get_moments_center(moments, offset=(0, 0))
Source code in src\util.py
335 336 | |
get_nn_distance(points0)
Source code in src\util.py
472 473 474 475 476 477 478 479 480 | |
get_orthogonal_pairs(origins, image_size_um)
Get pairs of orthogonal neighbors from a list of tiles. Tiles don't have to be placed on a regular grid.
Source code in src\util.py
507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 | |
get_rotation_from_transform(transform)
Source code in src\util.py
427 428 429 | |
get_scale_from_transform(transform)
Source code in src\util.py
397 398 399 | |
get_translation_from_transform(transform)
Source code in src\util.py
402 403 404 405 406 | |
get_unique_file_labels(filenames)
Source code in src\util.py
179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
get_value_units_micrometer(value_units0)
Source code in src\util.py
280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 | |
import_csv(filename)
Source code in src\util.py
596 597 598 599 | |
import_json(filename)
Source code in src\util.py
585 586 587 588 | |
import_metadata(content, fields=None, input_path=None)
Source code in src\util.py
568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 | |
normalise_rotated_positions(positions0, rotations0, size, center)
Source code in src\util.py
456 457 458 459 460 461 462 463 464 465 466 467 468 469 | |
normalise_rotation(rotation)
Normalise rotation to be in the range [-180, 180].
Source code in src\util.py
432 433 434 435 436 437 438 439 440 | |
points_to_3d(points)
Source code in src\util.py
443 444 | |
print_dict(dct, indent=0)
Source code in src\util.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | |
print_hbytes(nbytes)
Source code in src\util.py
98 99 100 101 102 103 104 105 106 107 108 109 110 | |
reorder(items, old_order, new_order, default_value=0)
Source code in src\util.py
27 28 29 30 31 32 33 34 35 | |
retuple(chunks, shape)
Expand chunks to match shape.
E.g. if chunks is (64, 64) and shape is (3, 4, 5, 1028, 1028) return (3, 4, 5, 64, 64)
If chunks is an integer, it is applied to all dimensions, to match the behaviour of zarr-python.
Source code in src\util.py
549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 | |
round_significants(a, significant_digits)
Source code in src\util.py
124 125 126 127 128 | |
split_num_text(text)
Source code in src\util.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 | |
split_numeric(text)
Source code in src\util.py
153 154 155 156 157 158 159 160 | |
split_numeric_dict(text)
Source code in src\util.py
163 164 165 166 167 168 169 170 171 172 173 174 175 176 | |
split_path(path)
Source code in src\util.py
131 132 | |
split_value_unit_list(text)
Source code in src\util.py
238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 | |
validate_transform(transform, max_rotation=None)
Source code in src\util.py
382 383 384 385 386 387 388 389 390 391 392 393 394 | |
xyz_to_dict(xyz, axes='xyz')
Source code in src\util.py
447 448 449 | |