Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
H
HYH.APSJ
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
佟礼
HYH.APSJ
Commits
020c7dd2
Commit
020c7dd2
authored
Dec 29, 2025
by
Tong Li
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
遗传算法-优化编译逻辑
parent
9389ef11
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
3 deletions
+5
-3
GeneticAlgorithm.java
...main/java/com/aps/service/Algorithm/GeneticAlgorithm.java
+2
-2
PlanResultService.java
src/main/java/com/aps/service/plan/PlanResultService.java
+3
-1
No files found.
src/main/java/com/aps/service/Algorithm/GeneticAlgorithm.java
View file @
020c7dd2
...
...
@@ -68,7 +68,7 @@ public class GeneticAlgorithm {
orderMaterials
=
materialRequirementService
.
buildMultiLevelRequirementNetwork
(
param
.
getBaseTime
());
}
LocalDateTime
starttime
=
LocalDateTime
.
now
();
FileHelper
.
writeLogFile
(
"排产-----------开始-----------"
);
FileHelper
.
writeLogFile
(
"排产-----------开始-----------"
+
allOperations
.
get
(
0
).
getSceneId
()
);
Initialization
initialization
=
new
Initialization
(
_GlobalParam
,
allOperations
,
orders
,
machines
);
...
...
@@ -76,7 +76,7 @@ public class GeneticAlgorithm {
// 预生成全局工序列表(所有初始化方法共享同一顺序)
List
<
GlobalOperationInfo
>
globalOpList
=
initialization
.
generateGlobalOpList
();
FileHelper
.
writeLogFile
(
"初始化种群-----------开始-------"
+
allOperations
.
get
(
0
).
getSceneId
()
);
FileHelper
.
writeLogFile
(
"初始化种群-----------开始-------"
);
// 步骤1:初始化种群
List
<
Chromosome
>
population
=
initialization
.
generateInitialPopulation
(
param
,
globalOpList
);
...
...
src/main/java/com/aps/service/plan/PlanResultService.java
View file @
020c7dd2
...
...
@@ -598,6 +598,8 @@ order.setDueDate(LocalDateTime.of(2025, 12, 1,0,0,0));
public
Chromosome
schedule
(
String
SceneId
)
{
try
{
FileHelper
.
writeLogFile
(
"schedule-----------开始-----------"
+
SceneId
);
ScheduleParams
param
=
InitScheduleParams
();
...
...
@@ -649,7 +651,7 @@ order.setDueDate(LocalDateTime.of(2025, 12, 1,0,0,0));
_sceneService
.
saveChromosomeToFile
(
chromosomes
,
SceneId
);
// Chromosomes.forEach(this::WriteScheduleSummary);
FileHelper
.
writeLogFile
(
"schedule-----------结束-----------"
+
SceneId
);
return
chromosomes
;
}
catch
(
Exception
e
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment