Skip to content

Commit

Permalink
minor
Browse files Browse the repository at this point in the history
  • Loading branch information
aghaeifar committed Jul 13, 2024
1 parent b7b7d31 commit 54bd590
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 6 deletions.
3 changes: 3 additions & 0 deletions docs/source/create_phantom.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
##############
Create Phantom
##############
2 changes: 0 additions & 2 deletions docs/source/file format.rst

This file was deleted.

3 changes: 2 additions & 1 deletion docs/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,6 @@ Welcome to SpinWalk's documentation!

installation
tutorial
file format
io_file
create_phantom
View on GitHub <https://github.com/aghaeifar/SpinWalk>
3 changes: 3 additions & 0 deletions docs/source/io_file.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
###############
Data Structures
###############
3 changes: 2 additions & 1 deletion docs/source/tutorial.rst
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
########
Tutorial
*********
########
4 changes: 3 additions & 1 deletion src/shapes/cylinder.cu
Original file line number Diff line number Diff line change
Expand Up @@ -168,9 +168,10 @@ void cylinder::generate_mask_fieldmap()
int32_t cyl_rad_vox, cyl_pnt_vox[3];

std::cout<<"B0 direction: ["<<B0[0]<<", "<<B0[1]<<", "<<B0[2]<<"]\n";
std::cout<<"Allocating memory..."<<std::endl;
std::cout<<"Allocating memory...";
m_fieldmap.resize(m_calc_fieldmap ? res3:0, 0.f);
m_mask.resize(res3, 0);
std::cout<<"Done!\n";
float v_size = m_fov / m_resolution;

float cyl_dir[3] = {0.0, 0.0, 1.0};
Expand All @@ -181,6 +182,7 @@ void cylinder::generate_mask_fieldmap()
theta_c2 = theta_c * theta_c;
theta_s2 = 1. - theta_c2; // sin^2(theta)

std::cout<<"Generating...\n";
ProgressBar bar{option::ShowPercentage{true}, option::Start{"["}, option::Fill{"="}, option::Lead{">"}, option::End{"]"}};
auto start = std::chrono::high_resolution_clock::now();
for (size_t c = 0; c < m_cylinder_radii.size(); c++)
Expand Down
4 changes: 3 additions & 1 deletion src/shapes/sphere.cu
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,13 @@ void sphere::generate_mask_fieldmap()
int32_t x_min, x_max, y_min, y_max, z_min, z_max;
int32_t sph_rad_vox, sph_center_vox[3];

std::cout<<"Allocating memory..."<<std::endl;
std::cout<<"Allocating memory...";
m_fieldmap.resize(m_calc_fieldmap ? res3:0, 0.f);
m_mask.resize(res3, 0);
std::cout<<"Done!\n";
float v_size = m_fov / m_resolution;

std::cout << "Generating...\n";
ProgressBar bar{option::ShowPercentage{true}, option::Start{"["}, option::Fill{"="}, option::Lead{">"}, option::End{"]"}, option::FontStyles{std::vector<FontStyle>{FontStyle::bold}}};
auto start = std::chrono::high_resolution_clock::now();
for (size_t c = 0; c < m_sphere_radii.size(); c++)
Expand Down

0 comments on commit 54bd590

Please sign in to comment.