Skip to content

Conversation

@hayakawa16
Copy link
Member

I don't plan to push this branch to master. I created PR so that I could see code changes I made.

…unit tests to check writing. Currently code is reading and writing to a local folder. Need to change that in the future.
…se to use the constructs already in place for reading PhotonDatabase. Reading appears to be working. Writing is a problem because the header is not written which has different format than ZRDRayDataPoint. Unit tests pass right now.
…onstructs like ZRDDatabaseWriterController, ZRDRayDataPointSerializer, DatabaseWriterFactory, DatabaseExtensionMethods and modified MonteCarloSimulation to use these new constructs to write a ZRDRayDataPoint to a binary file with the appropriate header so that Zemax can import it. Wrote associated unit tests.
…t, also wrote segment number to match output. Removed commented out code.
# Conflicts:
#	src/Vts.Desktop.Test/Vts.Desktop.Test.csproj
#	src/Vts.Desktop/Vts.Desktop.csproj
#	src/Vts.sln
#	src/Vts/MonteCarlo/MonteCarloSimulation.cs
# Conflicts:
#	src/Vts.Desktop.Test/Vts.Desktop.Test.csproj
#	src/Vts.Desktop/Vts.Desktop.csproj
#	src/Vts/Vts.csproj
…ts below.

# Conflicts:
#	src/Vts/MonteCarlo/Types/TallyType.cs
#	src/Vts/Vts.csproj
…vate and creating a property that encapsulates it.
# Conflicts:
#	src/Vts/MonteCarlo/Types/DatabaseType.cs
…t Position, Direction and Weight (may not use these Vts classes in future). Move all Zemax related code to "Zemax" folder. Applications that do the translation to/from ZRD file to MCCL ray database may still need Vts.dll. Everything compiles but many unit tests failing.
… database infile. Need LM to review Vts.sln in this commit.
…oject. Moved prior unit tests that tested ZRD files, ZRDRayDatabaseTests, to Test project. Now all tests pass except for those in Vts.MonteCarlo.ZemaxDatabaseConverter.Test. Cleaned up RayDatabaseTests, tests that check if reading/writing to MCCL database works.
…r app. All unit tests in solution currently passing.
…er Program tests sometimes pass, sometimes fail, 2) straggler testraydatabase, testraydatabase.txt not cleaned up but can't tell which test is leaving them, 3) I would like to test reading in actual Zemax ZRD file, however one I have is 389KB and not sure I should put in resources.
hayakawa16 and others added 28 commits September 26, 2022 19:16
…, changed to "var" in locations, "readonly" and "static" additions, method rename from DPBelongsToSurfaceVirtualBoundary to DpBelongsToSurfaceBounday, comment spelling corrections.
…xDatabaseConverter progam and modified unit test accordingly.
…and cleaned up code unique to branch.

# Conflicts:	src/Vts/MonteCarlo/Factories/DatabaseWriterFactory.cs
…ts solely in some csproj files related to updated NuGet packages.
…cts:

#	src/Vts/MonteCarlo/MonteCarloSimulation.cs
…cts in src/Vts.sln regarding VS version and Benchmark using Release not Debug.
…ts in:

src/Vts/MonteCarlo/DataStructures/SimulationInputProvider.cs,  src/Vts/MonteCarlo/Factories/DetectorControllerFactory.cs, src/Vts/MonteCarlo/Factories/VirtualBoundaryFactory.cs and src/Vts/MonteCarlo/MonteCarloSimulation.cs
…in SimulationInputProvider.cs and cleaned up and added code so that dbWriter and enumerator closed so that test cleanup doesn't think file is still open.
…ts in:

#	src/Vts/MonteCarlo/DataStructures/SimulationInputProvider.cs
@sonarqubecloud
Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
1 Security Hotspot

See analysis details on SonarQube Cloud

@hayakawa16 hayakawa16 marked this pull request as draft November 4, 2025 22:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants