Compare commits
2 Commits
4c69ed777b
...
d80d0ea79d
Author | SHA1 | Date | |
---|---|---|---|
d80d0ea79d | |||
bdd70323a3 |
@ -5,4 +5,4 @@ from PytorchBoot.runners.trainer import DefaultTrainer
|
|||||||
class TrainApp:
|
class TrainApp:
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def start():
|
def start():
|
||||||
DefaultTrainer("configs/train_config.yaml").run()
|
DefaultTrainer("configs/server/train_config.yaml").run()
|
22
configs/server/split_dataset_config.yaml
Normal file
22
configs/server/split_dataset_config.yaml
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
|
||||||
|
runner:
|
||||||
|
general:
|
||||||
|
seed: 0
|
||||||
|
device: cpu
|
||||||
|
cuda_visible_devices: "0,1,2,3,4,5,6,7"
|
||||||
|
|
||||||
|
experiment:
|
||||||
|
name: debug
|
||||||
|
root_dir: "experiments"
|
||||||
|
|
||||||
|
split:
|
||||||
|
root_dir: "../data/sample_for_training/scenes"
|
||||||
|
type: "unseen_instance" # "unseen_category"
|
||||||
|
datasets:
|
||||||
|
OmniObject3d_train:
|
||||||
|
path: "../data/sample_for_training/OmniObject3d_train.txt"
|
||||||
|
ratio: 0.9
|
||||||
|
|
||||||
|
OmniObject3d_test:
|
||||||
|
path: "../data/sample_for_training/OmniObject3d_test.txt"
|
||||||
|
ratio: 0.1
|
@ -25,8 +25,8 @@ runner:
|
|||||||
datasets:
|
datasets:
|
||||||
OmniObject3d:
|
OmniObject3d:
|
||||||
#"/media/hofee/data/data/temp_output"
|
#"/media/hofee/data/data/temp_output"
|
||||||
root_dir: "/media/hofee/data/project/python/nbv_reconstruction/sample_for_training/scenes"
|
root_dir: "../data/sample_for_training/scenes"
|
||||||
model_dir: "/media/hofee/data/data/scaled_object_meshes"
|
model_dir: "../data/scaled_object_meshes"
|
||||||
#output_dir: "/media/hofee/data/data/label_output"
|
#output_dir: "/media/hofee/data/data/label_output"
|
||||||
|
|
||||||
|
|
@ -31,18 +31,18 @@ runner:
|
|||||||
|
|
||||||
dataset:
|
dataset:
|
||||||
OmniObject3d_train:
|
OmniObject3d_train:
|
||||||
root_dir: "/media/hofee/data/project/python/nbv_reconstruction/sample_for_training/scenes"
|
root_dir: "../data/sample_for_training/scenes"
|
||||||
source: nbv_reconstruction_dataset
|
source: nbv_reconstruction_dataset
|
||||||
split_file: "/media/hofee/data/project/python/nbv_reconstruction/sample_for_training/OmniObject3d_train.txt"
|
split_file: "../data/sample_for_training/OmniObject3d_train.txt"
|
||||||
ratio: 1.0
|
ratio: 1.0
|
||||||
batch_size: 1
|
batch_size: 1
|
||||||
num_workers: 12
|
num_workers: 12
|
||||||
pts_num: 4096
|
pts_num: 4096
|
||||||
|
|
||||||
OmniObject3d_test:
|
OmniObject3d_test:
|
||||||
root_dir: "/media/hofee/data/project/python/nbv_reconstruction/sample_for_training/scenes"
|
root_dir: "../data/sample_for_training/scenes"
|
||||||
source: nbv_reconstruction_dataset
|
source: nbv_reconstruction_dataset
|
||||||
split_file: "/media/hofee/data/project/python/nbv_reconstruction/sample_for_training/OmniObject3d_train.txt"
|
split_file: "../data/sample_for_training/OmniObject3d_train.txt"
|
||||||
eval_list:
|
eval_list:
|
||||||
- pose_diff
|
- pose_diff
|
||||||
ratio: 0.1
|
ratio: 0.1
|
||||||
@ -68,15 +68,15 @@ module:
|
|||||||
transformer_seq_encoder:
|
transformer_seq_encoder:
|
||||||
pts_embed_dim: 1024
|
pts_embed_dim: 1024
|
||||||
pose_embed_dim: 256
|
pose_embed_dim: 256
|
||||||
num_heads: 2 # 4
|
num_heads: 4
|
||||||
ffn_dim: 128 # 256
|
ffn_dim: 256
|
||||||
num_layers: 2 # 3
|
num_layers: 3
|
||||||
output_dim: 1024 # 2048
|
output_dim: 2048
|
||||||
|
|
||||||
gf_view_finder:
|
gf_view_finder:
|
||||||
t_feat_dim: 128
|
t_feat_dim: 128
|
||||||
pose_feat_dim: 256
|
pose_feat_dim: 256
|
||||||
main_feat_dim: 1024 # 2048
|
main_feat_dim: 2048
|
||||||
regression_head: Rx_Ry_and_T
|
regression_head: Rx_Ry_and_T
|
||||||
pose_mode: rot_matrix
|
pose_mode: rot_matrix
|
||||||
per_point_feature: False
|
per_point_feature: False
|
@ -7,9 +7,9 @@ runner:
|
|||||||
name: debug
|
name: debug
|
||||||
root_dir: experiments
|
root_dir: experiments
|
||||||
generate:
|
generate:
|
||||||
object_dir: /media/hofee/data/data/scaled_object_meshes
|
object_dir: ../data/scaled_object_meshes
|
||||||
table_model_path: /media/hofee/data/data/others/table.obj
|
table_model_path: ../data/others/table.obj
|
||||||
output_dir: /media/hofee/repository/nbv_reconstruction_data_512
|
output_dir: ../data/nbv_reconstruction_data_512
|
||||||
binocular_vision: true
|
binocular_vision: true
|
||||||
plane_size: 10
|
plane_size: 10
|
||||||
max_views: 512
|
max_views: 512
|
@ -1,22 +0,0 @@
|
|||||||
|
|
||||||
runner:
|
|
||||||
general:
|
|
||||||
seed: 0
|
|
||||||
device: cpu
|
|
||||||
cuda_visible_devices: "0,1,2,3,4,5,6,7"
|
|
||||||
|
|
||||||
experiment:
|
|
||||||
name: debug
|
|
||||||
root_dir: "experiments"
|
|
||||||
|
|
||||||
split:
|
|
||||||
root_dir: "/media/hofee/data/project/python/nbv_reconstruction/sample_for_training/scenes"
|
|
||||||
type: "unseen_instance" # "unseen_category"
|
|
||||||
datasets:
|
|
||||||
OmniObject3d_train:
|
|
||||||
path: "/media/hofee/data/project/python/nbv_reconstruction/sample_for_training/OmniObject3d_train.txt"
|
|
||||||
ratio: 0.9
|
|
||||||
|
|
||||||
OmniObject3d_test:
|
|
||||||
path: "/media/hofee/data/project/python/nbv_reconstruction/sample_for_training/OmniObject3d_test.txt"
|
|
||||||
ratio: 0.1
|
|
@ -3,9 +3,6 @@ from PytorchBoot.dataset import BaseDataset
|
|||||||
import PytorchBoot.stereotype as stereotype
|
import PytorchBoot.stereotype as stereotype
|
||||||
import torch
|
import torch
|
||||||
|
|
||||||
import sys
|
|
||||||
sys.path.append(r"/media/hofee/data/project/python/nbv_reconstruction/nbv_reconstruction")
|
|
||||||
|
|
||||||
from utils.data_load import DataLoadUtil
|
from utils.data_load import DataLoadUtil
|
||||||
from utils.pose import PoseUtil
|
from utils.pose import PoseUtil
|
||||||
from utils.pts import PtsUtil
|
from utils.pts import PtsUtil
|
||||||
|
@ -5,7 +5,7 @@ import PytorchBoot.stereotype as stereotype
|
|||||||
from PytorchBoot.factory.component_factory import ComponentFactory
|
from PytorchBoot.factory.component_factory import ComponentFactory
|
||||||
from PytorchBoot.utils import Log
|
from PytorchBoot.utils import Log
|
||||||
|
|
||||||
@stereotype.pipeline("nbv_reconstruction_pipeline", comment="should be tested")
|
@stereotype.pipeline("nbv_reconstruction_pipeline")
|
||||||
class NBVReconstructionPipeline(nn.Module):
|
class NBVReconstructionPipeline(nn.Module):
|
||||||
def __init__(self, config):
|
def __init__(self, config):
|
||||||
super(NBVReconstructionPipeline, self).__init__()
|
super(NBVReconstructionPipeline, self).__init__()
|
||||||
@ -72,7 +72,6 @@ class NBVReconstructionPipeline(nn.Module):
|
|||||||
pose_feat_seq_list = []
|
pose_feat_seq_list = []
|
||||||
|
|
||||||
for scanned_pts,scanned_n_to_1_pose_9d in zip(scanned_pts_batch,scanned_n_to_1_pose_9d_batch):
|
for scanned_pts,scanned_n_to_1_pose_9d in zip(scanned_pts_batch,scanned_n_to_1_pose_9d_batch):
|
||||||
print(scanned_n_to_1_pose_9d.shape)
|
|
||||||
scanned_pts = scanned_pts.to(best_to_1_pose_9d_batch.device)
|
scanned_pts = scanned_pts.to(best_to_1_pose_9d_batch.device)
|
||||||
scanned_n_to_1_pose_9d = scanned_n_to_1_pose_9d.to(best_to_1_pose_9d_batch.device)
|
scanned_n_to_1_pose_9d = scanned_n_to_1_pose_9d.to(best_to_1_pose_9d_batch.device)
|
||||||
pts_feat_seq_list.append(self.pts_encoder.encode_points(scanned_pts))
|
pts_feat_seq_list.append(self.pts_encoder.encode_points(scanned_pts))
|
||||||
|
@ -2,9 +2,6 @@ import torch
|
|||||||
import torch.nn as nn
|
import torch.nn as nn
|
||||||
import PytorchBoot.stereotype as stereotype
|
import PytorchBoot.stereotype as stereotype
|
||||||
|
|
||||||
import sys
|
|
||||||
sys.path.append(r"C:\Document\Local Project\nbv_rec\nbv_reconstruction")
|
|
||||||
|
|
||||||
from utils.pose import PoseUtil
|
from utils.pose import PoseUtil
|
||||||
import modules.module_lib as mlib
|
import modules.module_lib as mlib
|
||||||
import modules.func_lib as flib
|
import modules.func_lib as flib
|
||||||
|
Loading…
x
Reference in New Issue
Block a user