mirror of
https://github.com/alicevision/Meshroom.git
synced 2025-08-03 08:48:40 +02:00
reorder modules and packages
* meshroom package at root * use pep8 recommandation for import orders
This commit is contained in:
parent
9f176e6d78
commit
7488de782c
12 changed files with 28 additions and 44 deletions
6
compute.py → meshroom/compute.py
Executable file → Normal file
6
compute.py → meshroom/compute.py
Executable file → Normal file
|
@ -1,11 +1,7 @@
|
|||
#!/usr/bin/env python3
|
||||
import processGraph as pg
|
||||
|
||||
import os
|
||||
import sys
|
||||
|
||||
import argparse
|
||||
|
||||
from meshroom import processGraph as pg
|
||||
|
||||
parser = argparse.ArgumentParser(description='Execute a Graph of processes.')
|
||||
parser.add_argument('graphFile', metavar='GRAPHFILE.mg', type=str,
|
8
newNodeType.py → meshroom/newNodeType.py
Executable file → Normal file
8
newNodeType.py → meshroom/newNodeType.py
Executable file → Normal file
|
@ -1,12 +1,10 @@
|
|||
#!/usr/bin/env python3
|
||||
from __future__ import print_function
|
||||
|
||||
import processGraph as pg
|
||||
|
||||
import os
|
||||
import sys
|
||||
import re
|
||||
import argparse
|
||||
import os
|
||||
import re
|
||||
import sys
|
||||
|
||||
|
||||
def trim(s):
|
0
meshroom/nodes/__init__.py
Normal file
0
meshroom/nodes/__init__.py
Normal file
|
@ -1,4 +1,4 @@
|
|||
from processGraph import desc
|
||||
from meshroom.processGraph import desc
|
||||
|
||||
class AppendText(desc.CommandLineNode):
|
||||
commandLine = 'cat {inputValue} > {outputValue} && echo {inputTextValue} >> {outputValue}'
|
|
@ -1,4 +1,4 @@
|
|||
from processGraph import desc
|
||||
from meshroom.processGraph import desc
|
||||
|
||||
|
||||
class Ls(desc.CommandLineNode):
|
|
@ -1,12 +1,9 @@
|
|||
from .Graph import *
|
||||
from . import desc
|
||||
|
||||
import os
|
||||
import sys
|
||||
import re
|
||||
import inspect
|
||||
import importlib
|
||||
import json
|
||||
import inspect
|
||||
import re
|
||||
|
||||
from . import desc
|
||||
from .graph import * # TODO: remove this
|
||||
|
||||
cacheFolder = '/tmp/processGraphCache'
|
||||
nodesDesc = {}
|
|
@ -1,12 +1,18 @@
|
|||
from __future__ import print_function
|
||||
|
||||
import processGraph as pg
|
||||
|
||||
from collections import defaultdict
|
||||
import psutil
|
||||
import inspect
|
||||
from pprint import pprint
|
||||
import hashlib
|
||||
import json
|
||||
import os
|
||||
import psutil
|
||||
import subprocess
|
||||
import threading
|
||||
import time
|
||||
import uuid
|
||||
from collections import defaultdict
|
||||
from enum import Enum # available by default in python3. For python2: "pip install enum34"
|
||||
from pprint import pprint
|
||||
|
||||
from meshroom import processGraph as pg
|
||||
|
||||
# Replace default encoder to support Enums
|
||||
DefaultJSONEncoder = json.JSONEncoder # store the original one
|
||||
|
@ -17,16 +23,6 @@ class MyJSONEncoder(DefaultJSONEncoder): # declare a new one with Enum support
|
|||
return DefaultJSONEncoder.default(self, obj) # use the default one for all other types
|
||||
json.JSONEncoder = MyJSONEncoder # replace the default implementation with our new one
|
||||
|
||||
import time
|
||||
import os
|
||||
import uuid
|
||||
|
||||
import threading
|
||||
import subprocess
|
||||
import hashlib
|
||||
|
||||
from enum import Enum # available by default in python3. For python2: "pip install enum34"
|
||||
|
||||
|
||||
try:
|
||||
unicode = unicode
|
||||
|
@ -214,7 +210,6 @@ class Node:
|
|||
name = None
|
||||
graph = None
|
||||
|
||||
|
||||
def __init__(self, nodeDesc, **kwargs):
|
||||
self.nodeDesc = pg.nodesDesc[nodeDesc]()
|
||||
self.attributes = {}
|
7
status.py → meshroom/status.py
Executable file → Normal file
7
status.py → meshroom/status.py
Executable file → Normal file
|
@ -1,12 +1,9 @@
|
|||
#!/usr/bin/env python3
|
||||
import processGraph as pg
|
||||
|
||||
import os
|
||||
import sys
|
||||
|
||||
import argparse
|
||||
import os
|
||||
from pprint import pprint
|
||||
|
||||
from meshroom import processGraph as pg
|
||||
|
||||
parser = argparse.ArgumentParser(description='Query the status of nodes in a Graph of processes.')
|
||||
parser.add_argument('graphFile', metavar='GRAPHFILE.mg', type=str,
|
0
tests/__init__.py
Normal file
0
tests/__init__.py
Normal file
|
@ -1,6 +1,7 @@
|
|||
import processGraph as pg
|
||||
from nose.tools import *
|
||||
|
||||
from meshroom import processGraph as pg
|
||||
|
||||
|
||||
def test_depth():
|
||||
graph = pg.Graph('Tests tasks depth')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue