scoretaskrun

package module
v0.0.0-...-80cc18a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 2, 2025 License: GPL-3.0 Imports: 19 Imported by: 0

README

This is a component of the BusGraphs Access Analyzer. Matt Laquidara is the author.

Bug reports and suggestions are welcome. Email is the most reliable way to reach me: <matt@publictransitanalytics.com>.

The follow notice applies to all source files in this repository:

> This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
> This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
> You should have received a copy of the GNU General Public License along with this program. If not, see <https://www.gnu.org/licenses/>.

For licensing under different terms, please contact me.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Reporter_name = map[int32]string{
		0: "SECTOR_COUNT",
		1: "SEAT_COUNT",
		2: "FULL_DATA",
		3: "PATH_COUNT",
		4: "ROUTE_COUNT",
		5: "TIME_COUNT",
		6: "SEGMENT_JOURNEYS",
	}
	Reporter_value = map[string]int32{
		"SECTOR_COUNT":     0,
		"SEAT_COUNT":       1,
		"FULL_DATA":        2,
		"PATH_COUNT":       3,
		"ROUTE_COUNT":      4,
		"TIME_COUNT":       5,
		"SEGMENT_JOURNEYS": 6,
	}
)

Enum value maps for Reporter.

View Source
var (
	Direction_name = map[int32]string{
		0: "FORWARD",
		1: "BACKWARD",
	}
	Direction_value = map[string]int32{
		"FORWARD":  0,
		"BACKWARD": 1,
	}
)

Enum value maps for Direction.

View Source
var (
	ModeTypeTransmission_name = map[int32]string{
		0: "NONE",
		1: "WALKING",
		2: "TRANSIT",
	}
	ModeTypeTransmission_value = map[string]int32{
		"NONE":    0,
		"WALKING": 1,
		"TRANSIT": 2,
	}
)

Enum value maps for ModeTypeTransmission.

View Source
var File_calculation_transmission_proto protoreflect.FileDescriptor
View Source
var File_direction_proto protoreflect.FileDescriptor
View Source
var File_task_request_transmission_proto protoreflect.FileDescriptor
View Source
var File_task_result_batch_proto protoreflect.FileDescriptor
View Source
var File_task_result_locator_proto protoreflect.FileDescriptor

Functions

func ConvertToOrcDirection

func ConvertToOrcDirection(direction bool) int

func CreateBasis

func CreateBasis(calculation *Calculation) *scoretaskguts.Basis

func NewFullDataReporter

func NewFullDataReporter(bucket string, s3Client *s3.Client,
	partitionReaches int, calculationId string) scoretaskguts.Reporter

func NewNSeatRideReporter

func NewNSeatRideReporter(bucket string,
	s3Client *s3.Client, calculationId string, sectorCount int, firstSectorIndex int) scoretaskguts.Reporter

func NewPathBasedReporter

func NewPathBasedReporter(
	s3Client *s3.Client, calculationId string, routeCount int, sectorCount int,
	firstSectorIndex int, routeIndexForTrip []int, durations []int,
	modules []PathBasedReporterModule) scoretaskguts.Reporter

func NewProgressReporter

func NewProgressReporter(sizeBucket string, s3Client *s3.Client,
	calculationId string, timeCount int) scoretaskguts.Reporter

func NewSectorCountReporter

func NewSectorCountReporter(reachCountBucket string,
	s3Client *s3.Client, calculationId string, sectorCount int,
	firstSectorIndex int, durations []int) scoretaskguts.Reporter

func NewTimeCountReporter

func NewTimeCountReporter(timeCountBucket string,
	s3Client *s3.Client, calculationId string, sectorCount int, times []int,
	firstSectorIndex int, durations []int) scoretaskguts.Reporter

func Run

func Run(request *Request, basis *scoretaskguts.Basis,
	progressReporter scoretaskguts.Reporter, reporters []scoretaskguts.Reporter, algorithm scoretaskguts.Algorithm) error

Types

type Adjacency

type Adjacency struct {
	TimeSeconds uint32 `protobuf:"varint,1,opt,name=time_seconds,json=timeSeconds,proto3" json:"time_seconds,omitempty"`
	Origin      uint32 `protobuf:"varint,2,opt,name=origin,proto3" json:"origin,omitempty"`
	Destination uint32 `protobuf:"varint,3,opt,name=destination,proto3" json:"destination,omitempty"`
	// contains filtered or unexported fields
}

func (*Adjacency) Descriptor deprecated

func (*Adjacency) Descriptor() ([]byte, []int)

Deprecated: Use Adjacency.ProtoReflect.Descriptor instead.

func (*Adjacency) GetDestination

func (x *Adjacency) GetDestination() uint32

func (*Adjacency) GetOrigin

func (x *Adjacency) GetOrigin() uint32

func (*Adjacency) GetTimeSeconds

func (x *Adjacency) GetTimeSeconds() uint32

func (*Adjacency) ProtoMessage

func (*Adjacency) ProtoMessage()

func (*Adjacency) ProtoReflect

func (x *Adjacency) ProtoReflect() protoreflect.Message

func (*Adjacency) Reset

func (x *Adjacency) Reset()

func (*Adjacency) String

func (x *Adjacency) String() string

type Batch

type Batch struct {
	BatchId     string        `protobuf:"bytes,1,opt,name=batchId,proto3" json:"batchId,omitempty"`
	Result      []*TaskResult `protobuf:"bytes,2,rep,name=result,proto3" json:"result,omitempty"`
	Fingerprint uint64        `protobuf:"fixed64,3,opt,name=fingerprint,proto3" json:"fingerprint,omitempty"`
	Reporter    string        `protobuf:"bytes,4,opt,name=reporter,proto3" json:"reporter,omitempty"`
	// contains filtered or unexported fields
}

func (*Batch) Descriptor deprecated

func (*Batch) Descriptor() ([]byte, []int)

Deprecated: Use Batch.ProtoReflect.Descriptor instead.

func (*Batch) GetBatchId

func (x *Batch) GetBatchId() string

func (*Batch) GetFingerprint

func (x *Batch) GetFingerprint() uint64

func (*Batch) GetReporter

func (x *Batch) GetReporter() string

func (*Batch) GetResult

func (x *Batch) GetResult() []*TaskResult

func (*Batch) ProtoMessage

func (*Batch) ProtoMessage()

func (*Batch) ProtoReflect

func (x *Batch) ProtoReflect() protoreflect.Message

func (*Batch) Reset

func (x *Batch) Reset()

func (*Batch) String

func (x *Batch) String() string

type Calculation

type Calculation struct {
	CalculationId       string                 `protobuf:"bytes,1,opt,name=calculationId,proto3" json:"calculationId,omitempty"`
	Durations           []uint32               `protobuf:"varint,2,rep,packed,name=durations,proto3" json:"durations,omitempty"`
	ComputeTimes        []uint32               `protobuf:"varint,3,rep,packed,name=compute_times,json=computeTimes,proto3" json:"compute_times,omitempty"`
	Network             *Network               `protobuf:"bytes,4,opt,name=network,proto3" json:"network,omitempty"`
	Adjacencies         []*Adjacency           `protobuf:"bytes,5,rep,name=adjacencies,proto3" json:"adjacencies,omitempty"`
	LocationCount       uint32                 `protobuf:"varint,6,opt,name=location_count,json=locationCount,proto3" json:"location_count,omitempty"`
	LocationSectors     map[uint32]*SectorList `` /* 181-byte string literal not displayed */
	Exhaustive          bool                   `protobuf:"varint,8,opt,name=exhaustive,proto3" json:"exhaustive,omitempty"`
	SectorCount         uint32                 `protobuf:"varint,9,opt,name=sector_count,json=sectorCount,proto3" json:"sector_count,omitempty"`
	StopCount           uint32                 `protobuf:"varint,10,opt,name=stop_count,json=stopCount,proto3" json:"stop_count,omitempty"`
	Reporters           []Reporter             `protobuf:"varint,11,rep,packed,name=reporters,proto3,enum=Reporter" json:"reporters,omitempty"`
	RouteIndexForTrip   []uint32               `protobuf:"varint,12,rep,packed,name=routeIndexForTrip,proto3" json:"routeIndexForTrip,omitempty"`
	RouteCount          uint32                 `protobuf:"varint,13,opt,name=route_count,json=routeCount,proto3" json:"route_count,omitempty"`
	RoutingIndexForTrip []uint32               `protobuf:"varint,14,rep,packed,name=routingIndexForTrip,proto3" json:"routingIndexForTrip,omitempty"`
	// contains filtered or unexported fields
}

func (*Calculation) Descriptor deprecated

func (*Calculation) Descriptor() ([]byte, []int)

Deprecated: Use Calculation.ProtoReflect.Descriptor instead.

func (*Calculation) GetAdjacencies

func (x *Calculation) GetAdjacencies() []*Adjacency

func (*Calculation) GetCalculationId

func (x *Calculation) GetCalculationId() string

func (*Calculation) GetComputeTimes

func (x *Calculation) GetComputeTimes() []uint32

func (*Calculation) GetDurations

func (x *Calculation) GetDurations() []uint32

func (*Calculation) GetExhaustive

func (x *Calculation) GetExhaustive() bool

func (*Calculation) GetLocationCount

func (x *Calculation) GetLocationCount() uint32

func (*Calculation) GetLocationSectors

func (x *Calculation) GetLocationSectors() map[uint32]*SectorList

func (*Calculation) GetNetwork

func (x *Calculation) GetNetwork() *Network

func (*Calculation) GetReporters

func (x *Calculation) GetReporters() []Reporter

func (*Calculation) GetRouteCount

func (x *Calculation) GetRouteCount() uint32

func (*Calculation) GetRouteIndexForTrip

func (x *Calculation) GetRouteIndexForTrip() []uint32

func (*Calculation) GetRoutingIndexForTrip

func (x *Calculation) GetRoutingIndexForTrip() []uint32

func (*Calculation) GetSectorCount

func (x *Calculation) GetSectorCount() uint32

func (*Calculation) GetStopCount

func (x *Calculation) GetStopCount() uint32

func (*Calculation) ProtoMessage

func (*Calculation) ProtoMessage()

func (*Calculation) ProtoReflect

func (x *Calculation) ProtoReflect() protoreflect.Message

func (*Calculation) Reset

func (x *Calculation) Reset()

func (*Calculation) String

func (x *Calculation) String() string

type Direction

type Direction int32
const (
	Direction_FORWARD  Direction = 0
	Direction_BACKWARD Direction = 1
)

func ConvertToFullDataDirection

func ConvertToFullDataDirection(direction bool) Direction

func (Direction) Descriptor

func (Direction) Descriptor() protoreflect.EnumDescriptor

func (Direction) Enum

func (x Direction) Enum() *Direction

func (Direction) EnumDescriptor deprecated

func (Direction) EnumDescriptor() ([]byte, []int)

Deprecated: Use Direction.Descriptor instead.

func (Direction) Number

func (x Direction) Number() protoreflect.EnumNumber

func (Direction) String

func (x Direction) String() string

func (Direction) Type

type FullDataReporter

type FullDataReporter struct {
	// contains filtered or unexported fields
}

func (*FullDataReporter) Flush

func (r *FullDataReporter) Flush(errorChannel chan error)

func (*FullDataReporter) Report

func (r *FullDataReporter) Report(timeIndex int, time int,
	locationState []scoretaskguts.Record, errorChannel chan error)

func (*FullDataReporter) SetUpTask

func (r *FullDataReporter) SetUpTask(center []int,
	centerSectors []int) error

type Locator

type Locator struct {
	CalculationId string `protobuf:"bytes,1,opt,name=calculationId,proto3" json:"calculationId,omitempty"`
	Bucket        string `protobuf:"bytes,2,opt,name=bucket,proto3" json:"bucket,omitempty"`
	Key           string `protobuf:"bytes,3,opt,name=key,proto3" json:"key,omitempty"`
	// contains filtered or unexported fields
}

func (*Locator) Descriptor deprecated

func (*Locator) Descriptor() ([]byte, []int)

Deprecated: Use Locator.ProtoReflect.Descriptor instead.

func (*Locator) GetBucket

func (x *Locator) GetBucket() string

func (*Locator) GetCalculationId

func (x *Locator) GetCalculationId() string

func (*Locator) GetKey

func (x *Locator) GetKey() string

func (*Locator) ProtoMessage

func (*Locator) ProtoMessage()

func (*Locator) ProtoReflect

func (x *Locator) ProtoReflect() protoreflect.Message

func (*Locator) Reset

func (x *Locator) Reset()

func (*Locator) String

func (x *Locator) String() string

type ModeTypeTransmission

type ModeTypeTransmission int32
const (
	ModeTypeTransmission_NONE    ModeTypeTransmission = 0
	ModeTypeTransmission_WALKING ModeTypeTransmission = 1
	ModeTypeTransmission_TRANSIT ModeTypeTransmission = 2
)

func (ModeTypeTransmission) Descriptor

func (ModeTypeTransmission) Enum

func (ModeTypeTransmission) EnumDescriptor deprecated

func (ModeTypeTransmission) EnumDescriptor() ([]byte, []int)

Deprecated: Use ModeTypeTransmission.Descriptor instead.

func (ModeTypeTransmission) Number

func (ModeTypeTransmission) String

func (x ModeTypeTransmission) String() string

func (ModeTypeTransmission) Type

type NSeatRideReporter

type NSeatRideReporter struct {
	// contains filtered or unexported fields
}

func (*NSeatRideReporter) Flush

func (r *NSeatRideReporter) Flush(errorChannel chan error)

func (*NSeatRideReporter) Report

func (r *NSeatRideReporter) Report(timeIndex int, time int,
	locationState []scoretaskguts.Record,
	errorChannel chan error)

func (*NSeatRideReporter) SetUpTask

func (r *NSeatRideReporter) SetUpTask(center []int,
	centerSectors []int) error

type Network

type Network struct {
	Trips     []*Trip     `protobuf:"bytes,1,rep,name=trips,proto3" json:"trips,omitempty"`
	Schedules []*Schedule `protobuf:"bytes,2,rep,name=schedules,proto3" json:"schedules,omitempty"`
	Routings  []*Routing  `protobuf:"bytes,3,rep,name=routings,proto3" json:"routings,omitempty"`
	// contains filtered or unexported fields
}

func (*Network) Descriptor deprecated

func (*Network) Descriptor() ([]byte, []int)

Deprecated: Use Network.ProtoReflect.Descriptor instead.

func (*Network) GetRoutings

func (x *Network) GetRoutings() []*Routing

func (*Network) GetSchedules

func (x *Network) GetSchedules() []*Schedule

func (*Network) GetTrips

func (x *Network) GetTrips() []*Trip

func (*Network) ProtoMessage

func (*Network) ProtoMessage()

func (*Network) ProtoReflect

func (x *Network) ProtoReflect() protoreflect.Message

func (*Network) Reset

func (x *Network) Reset()

func (*Network) String

func (x *Network) String() string

type PathBasedReporter

type PathBasedReporter struct {
	// contains filtered or unexported fields
}

func (*PathBasedReporter) Flush

func (r *PathBasedReporter) Flush(errorChannel chan error)

func (*PathBasedReporter) Report

func (r *PathBasedReporter) Report(timeIndex int, time int, locationState []scoretaskguts.Record, errorChannel chan error)

func (*PathBasedReporter) SetUpTask

func (r *PathBasedReporter) SetUpTask(center []int, centerSectors []int) error

type PathBasedReporterModule

type PathBasedReporterModule interface {
	SetUp() error
	ProcessPath(sector int, path []*scoretaskguts.Record, durationIndex int)
	Flush(fingerprint int64,
		centerSectors []int, send SendCallback) error
}

func NewPathCountModule

func NewPathCountModule(bucket string, sectorCount int, durations []int, routeIndexForTrip []int) PathBasedReporterModule

func NewRouteCountModule

func NewRouteCountModule(bucket string, routeCount int, durations []int, routeIndexForTrip []int) PathBasedReporterModule

func NewSegmentCountModule

func NewSegmentCountModule(bucket string, routingSegmentCounts []int,
	durations []int, routingIndexForTrip []int) PathBasedReporterModule

type PathCountReporterModule

type PathCountReporterModule struct {
	// contains filtered or unexported fields
}

func (*PathCountReporterModule) Flush

func (r *PathCountReporterModule) Flush(
	fingerprint int64, centerSectors []int, send SendCallback) error

func (*PathCountReporterModule) ProcessPath

func (r *PathCountReporterModule) ProcessPath(sector int, path []*scoretaskguts.Record, durationIndex int)

func (*PathCountReporterModule) SetUp

func (r *PathCountReporterModule) SetUp() error

type ProgressReporter

type ProgressReporter struct {
	// contains filtered or unexported fields
}

func (*ProgressReporter) Flush

func (r *ProgressReporter) Flush(errorChannel chan error)

func (*ProgressReporter) Report

func (r *ProgressReporter) Report(timeIndex int, time int,
	state []scoretaskguts.Record, errorChannel chan error)

func (*ProgressReporter) SetUpTask

func (r *ProgressReporter) SetUpTask(center []int,
	centerSectors []int) error

type Reach

type Reach struct {
	Location            uint32               `protobuf:"varint,1,opt,name=location,proto3" json:"location,omitempty"`
	TimeOffset          uint32               `protobuf:"varint,2,opt,name=timeOffset,proto3" json:"timeOffset,omitempty"`
	PredecessorLocation uint32               `protobuf:"varint,3,opt,name=predecessorLocation,proto3" json:"predecessorLocation,omitempty"`
	TripIndex           uint32               `protobuf:"varint,4,opt,name=tripIndex,proto3" json:"tripIndex,omitempty"`
	ModeType            ModeTypeTransmission `protobuf:"varint,5,opt,name=modeType,proto3,enum=ModeTypeTransmission" json:"modeType,omitempty"`
	// contains filtered or unexported fields
}

func (*Reach) Descriptor deprecated

func (*Reach) Descriptor() ([]byte, []int)

Deprecated: Use Reach.ProtoReflect.Descriptor instead.

func (*Reach) GetLocation

func (x *Reach) GetLocation() uint32

func (*Reach) GetModeType

func (x *Reach) GetModeType() ModeTypeTransmission

func (*Reach) GetPredecessorLocation

func (x *Reach) GetPredecessorLocation() uint32

func (*Reach) GetTimeOffset

func (x *Reach) GetTimeOffset() uint32

func (*Reach) GetTripIndex

func (x *Reach) GetTripIndex() uint32

func (*Reach) ProtoMessage

func (*Reach) ProtoMessage()

func (*Reach) ProtoReflect

func (x *Reach) ProtoReflect() protoreflect.Message

func (*Reach) Reset

func (x *Reach) Reset()

func (*Reach) String

func (x *Reach) String() string

type Reporter

type Reporter int32
const (
	Reporter_SECTOR_COUNT     Reporter = 0
	Reporter_SEAT_COUNT       Reporter = 1
	Reporter_FULL_DATA        Reporter = 2
	Reporter_PATH_COUNT       Reporter = 3
	Reporter_ROUTE_COUNT      Reporter = 4
	Reporter_TIME_COUNT       Reporter = 5
	Reporter_SEGMENT_JOURNEYS Reporter = 6
)

func (Reporter) Descriptor

func (Reporter) Descriptor() protoreflect.EnumDescriptor

func (Reporter) Enum

func (x Reporter) Enum() *Reporter

func (Reporter) EnumDescriptor deprecated

func (Reporter) EnumDescriptor() ([]byte, []int)

Deprecated: Use Reporter.Descriptor instead.

func (Reporter) Number

func (x Reporter) Number() protoreflect.EnumNumber

func (Reporter) String

func (x Reporter) String() string

func (Reporter) Type

type Request

type Request struct {
	CalculationId string   `protobuf:"bytes,1,opt,name=calculationId,proto3" json:"calculationId,omitempty"`
	Centers       []uint32 `protobuf:"varint,2,rep,packed,name=centers,proto3" json:"centers,omitempty"`
	Sectors       []uint32 `protobuf:"varint,3,rep,packed,name=sectors,proto3" json:"sectors,omitempty"`
	// contains filtered or unexported fields
}

func (*Request) Descriptor deprecated

func (*Request) Descriptor() ([]byte, []int)

Deprecated: Use Request.ProtoReflect.Descriptor instead.

func (*Request) GetCalculationId

func (x *Request) GetCalculationId() string

func (*Request) GetCenters

func (x *Request) GetCenters() []uint32

func (*Request) GetSectors

func (x *Request) GetSectors() []uint32

func (*Request) ProtoMessage

func (*Request) ProtoMessage()

func (*Request) ProtoReflect

func (x *Request) ProtoReflect() protoreflect.Message

func (*Request) Reset

func (x *Request) Reset()

func (*Request) String

func (x *Request) String() string

type RouteCountReporterModule

type RouteCountReporterModule struct {
	// contains filtered or unexported fields
}

func (*RouteCountReporterModule) Flush

func (r *RouteCountReporterModule) Flush(fingerprint int64,
	centerSectors []int, send SendCallback) error

func (*RouteCountReporterModule) ProcessPath

func (r *RouteCountReporterModule) ProcessPath(sector int, path []*scoretaskguts.Record, durationIndex int)

func (*RouteCountReporterModule) SetUp

func (r *RouteCountReporterModule) SetUp() error

type Routing

type Routing struct {
	RoutingId uint32   `protobuf:"varint,1,opt,name=routing_id,json=routingId,proto3" json:"routing_id,omitempty"`
	Stops     []uint32 `protobuf:"varint,2,rep,packed,name=stops,proto3" json:"stops,omitempty"`
	// contains filtered or unexported fields
}

func (*Routing) Descriptor deprecated

func (*Routing) Descriptor() ([]byte, []int)

Deprecated: Use Routing.ProtoReflect.Descriptor instead.

func (*Routing) GetRoutingId

func (x *Routing) GetRoutingId() uint32

func (*Routing) GetStops

func (x *Routing) GetStops() []uint32

func (*Routing) ProtoMessage

func (*Routing) ProtoMessage()

func (*Routing) ProtoReflect

func (x *Routing) ProtoReflect() protoreflect.Message

func (*Routing) Reset

func (x *Routing) Reset()

func (*Routing) String

func (x *Routing) String() string

type Schedule

type Schedule struct {
	ScheduleId uint32    `protobuf:"varint,1,opt,name=schedule_id,json=scheduleId,proto3" json:"schedule_id,omitempty"`
	RoutingId  uint32    `protobuf:"varint,2,opt,name=routing_id,json=routingId,proto3" json:"routing_id,omitempty"`
	Timing     []*Timing `protobuf:"bytes,3,rep,name=timing,proto3" json:"timing,omitempty"`
	// contains filtered or unexported fields
}

func (*Schedule) Descriptor deprecated

func (*Schedule) Descriptor() ([]byte, []int)

Deprecated: Use Schedule.ProtoReflect.Descriptor instead.

func (*Schedule) GetRoutingId

func (x *Schedule) GetRoutingId() uint32

func (*Schedule) GetScheduleId

func (x *Schedule) GetScheduleId() uint32

func (*Schedule) GetTiming

func (x *Schedule) GetTiming() []*Timing

func (*Schedule) ProtoMessage

func (*Schedule) ProtoMessage()

func (*Schedule) ProtoReflect

func (x *Schedule) ProtoReflect() protoreflect.Message

func (*Schedule) Reset

func (x *Schedule) Reset()

func (*Schedule) String

func (x *Schedule) String() string

type SectorCountReporter

type SectorCountReporter struct {
	// contains filtered or unexported fields
}

func (*SectorCountReporter) Flush

func (r *SectorCountReporter) Flush(errorChannel chan error)

func (*SectorCountReporter) Report

func (r *SectorCountReporter) Report(timeIndex int, time int, locationState []scoretaskguts.Record, errorChannel chan error)

func (*SectorCountReporter) SetUpTask

func (r *SectorCountReporter) SetUpTask(center []int, centerSectors []int) error

type SectorList

type SectorList struct {
	Sectors []uint32 `protobuf:"varint,1,rep,packed,name=sectors,proto3" json:"sectors,omitempty"`
	// contains filtered or unexported fields
}

func (*SectorList) Descriptor deprecated

func (*SectorList) Descriptor() ([]byte, []int)

Deprecated: Use SectorList.ProtoReflect.Descriptor instead.

func (*SectorList) GetSectors

func (x *SectorList) GetSectors() []uint32

func (*SectorList) ProtoMessage

func (*SectorList) ProtoMessage()

func (*SectorList) ProtoReflect

func (x *SectorList) ProtoReflect() protoreflect.Message

func (*SectorList) Reset

func (x *SectorList) Reset()

func (*SectorList) String

func (x *SectorList) String() string

type Sectors

type Sectors struct {
	Sectors []uint32 `protobuf:"varint,1,rep,packed,name=sectors,proto3" json:"sectors,omitempty"`
	// contains filtered or unexported fields
}

func (*Sectors) Descriptor deprecated

func (*Sectors) Descriptor() ([]byte, []int)

Deprecated: Use Sectors.ProtoReflect.Descriptor instead.

func (*Sectors) GetSectors

func (x *Sectors) GetSectors() []uint32

func (*Sectors) ProtoMessage

func (*Sectors) ProtoMessage()

func (*Sectors) ProtoReflect

func (x *Sectors) ProtoReflect() protoreflect.Message

func (*Sectors) Reset

func (x *Sectors) Reset()

func (*Sectors) String

func (x *Sectors) String() string

type SegmentCountReporterModule

type SegmentCountReporterModule struct {
	// contains filtered or unexported fields
}

func (*SegmentCountReporterModule) Flush

func (r *SegmentCountReporterModule) Flush(fingerprint int64,
	centerSectors []int, send SendCallback) error

func (*SegmentCountReporterModule) ProcessPath

func (r *SegmentCountReporterModule) ProcessPath(sector int, path []*scoretaskguts.Record, durationIndex int)

func (*SegmentCountReporterModule) SetUp

func (r *SegmentCountReporterModule) SetUp() error

type SendCallback

type SendCallback func(bucket string, f *os.File, durationIndex int, durationString string, fingerprint int64) error

type TaskResult

type TaskResult struct {
	TimeOffset uint32   `protobuf:"varint,1,opt,name=timeOffset,proto3" json:"timeOffset,omitempty"`
	Centers    []uint32 `protobuf:"varint,2,rep,packed,name=centers,proto3" json:"centers,omitempty"`
	Reach      []*Reach `protobuf:"bytes,3,rep,name=reach,proto3" json:"reach,omitempty"`
	Sectors    []uint32 `protobuf:"varint,4,rep,packed,name=sectors,proto3" json:"sectors,omitempty"`
	IsForward  bool     `protobuf:"varint,5,opt,name=is_forward,json=isForward,proto3" json:"is_forward,omitempty"`
	// contains filtered or unexported fields
}

func (*TaskResult) Descriptor deprecated

func (*TaskResult) Descriptor() ([]byte, []int)

Deprecated: Use TaskResult.ProtoReflect.Descriptor instead.

func (*TaskResult) GetCenters

func (x *TaskResult) GetCenters() []uint32

func (*TaskResult) GetIsForward

func (x *TaskResult) GetIsForward() bool

func (*TaskResult) GetReach

func (x *TaskResult) GetReach() []*Reach

func (*TaskResult) GetSectors

func (x *TaskResult) GetSectors() []uint32

func (*TaskResult) GetTimeOffset

func (x *TaskResult) GetTimeOffset() uint32

func (*TaskResult) ProtoMessage

func (*TaskResult) ProtoMessage()

func (*TaskResult) ProtoReflect

func (x *TaskResult) ProtoReflect() protoreflect.Message

func (*TaskResult) Reset

func (x *TaskResult) Reset()

func (*TaskResult) String

func (x *TaskResult) String() string

type TimeCountReporter

type TimeCountReporter struct {
	// contains filtered or unexported fields
}

func (*TimeCountReporter) Flush

func (r *TimeCountReporter) Flush(errorChannel chan error)

func (*TimeCountReporter) Report

func (r *TimeCountReporter) Report(timeIndex int, time int, locationState []scoretaskguts.Record, errorChannel chan error)

func (*TimeCountReporter) SetUpTask

func (r *TimeCountReporter) SetUpTask(center []int, centerSectors []int) error

type Timing

type Timing struct {
	ArrivalCummulative   uint32 `protobuf:"varint,1,opt,name=arrival_cummulative,json=arrivalCummulative,proto3" json:"arrival_cummulative,omitempty"`
	DepartureCummulative uint32 `protobuf:"varint,2,opt,name=departure_cummulative,json=departureCummulative,proto3" json:"departure_cummulative,omitempty"`
	// contains filtered or unexported fields
}

func (*Timing) Descriptor deprecated

func (*Timing) Descriptor() ([]byte, []int)

Deprecated: Use Timing.ProtoReflect.Descriptor instead.

func (*Timing) GetArrivalCummulative

func (x *Timing) GetArrivalCummulative() uint32

func (*Timing) GetDepartureCummulative

func (x *Timing) GetDepartureCummulative() uint32

func (*Timing) ProtoMessage

func (*Timing) ProtoMessage()

func (*Timing) ProtoReflect

func (x *Timing) ProtoReflect() protoreflect.Message

func (*Timing) Reset

func (x *Timing) Reset()

func (*Timing) String

func (x *Timing) String() string

type Trip

type Trip struct {
	TripId uint32 `protobuf:"varint,1,opt,name=trip_id,json=tripId,proto3" json:"trip_id,omitempty"`
	// Allow to be negative since some trips start before the earliest time
	Offset     int32  `protobuf:"varint,2,opt,name=offset,proto3" json:"offset,omitempty"`
	ScheduleId uint32 `protobuf:"varint,3,opt,name=schedule_id,json=scheduleId,proto3" json:"schedule_id,omitempty"`
	// contains filtered or unexported fields
}

func (*Trip) Descriptor deprecated

func (*Trip) Descriptor() ([]byte, []int)

Deprecated: Use Trip.ProtoReflect.Descriptor instead.

func (*Trip) GetOffset

func (x *Trip) GetOffset() int32

func (*Trip) GetScheduleId

func (x *Trip) GetScheduleId() uint32

func (*Trip) GetTripId

func (x *Trip) GetTripId() uint32

func (*Trip) ProtoMessage

func (*Trip) ProtoMessage()

func (*Trip) ProtoReflect

func (x *Trip) ProtoReflect() protoreflect.Message

func (*Trip) Reset

func (x *Trip) Reset()

func (*Trip) String

func (x *Trip) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL